Thread (2 messages) 2 messages, 2 authors, 2025-06-12

Re: [PATCH] x86: Fix build warnings about export.h

From: Naman Jain <hidden>
Date: 2025-06-12 09:58:15
Also in: linux-acpi, linux-crypto, linux-efi, linux-kbuild, linux-pci, linux-perf-users, lkml


On 6/12/2025 3:00 PM, Zhenghan Cheng wrote:
After commit a934a57a42f64a4 ("scripts/misc-check:
check missing #include <linux/export.h> when W=1")
and commit 7d95680d64ac8e836c ("scripts/misc-check:
check unnecessary #include <linux/export.h> when W=1"),
we get some build warnings with W=1,such as:

arch/x86/coco/sev/core.c: warning: EXPORT_SYMBOL() is used, but #include <linux/export.h> is missing
arch/x86/crypto/aria_aesni_avx2_glue.c: warning: EXPORT_SYMBOL() is used, but #include <linux/export.h> is missing
arch/x86/kernel/unwind_orc.c: warning: EXPORT_SYMBOL() is used, but #include <linux/export.h> is missing
arch/x86/kvm/hyperv.c: warning: EXPORT_SYMBOL() is used, but #include <linux/export.h> is missing
arch/x86/events/intel/core.c: warning: EXPORT_SYMBOL() is not used, but #include <linux/export.h> is present
arch/x86/events/zhaoxin/core.c: warning: EXPORT_SYMBOL() is not used, but #include <linux/export.h> is present
arch/x86/kernel/crash.c: warning: EXPORT_SYMBOL() is not used, but #include <linux/export.h> is present
arch/x86/kernel/devicetree.c: warning: EXPORT_SYMBOL() is not used, but #include <linux/export.h> is present

so fix these build warnings for x86.

Signed-off-by: "Zhenghan Cheng" <redacted>
Suggested-by: "Huacai Chen" <redacted>

Thanks for sharing.

FYI, I sent a patch to fix these warnings in Hyper-V related drivers
here:
https://lore.kernel.org/all/20250611100459.92900-1-namjain@linux.microsoft.com/ (local)

Some of the files are common to the ones in your patch.

Regards,
Naman

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help