Skip to contentSkip to conversation

headers_check: asm-*/hw_breakpoint.h is not exported

PATCH In review Geert Uytterhoeven 2 participants 3 messages Dec 6, 2009 – Dec 8, 2009 perf events

lore
Share & tools
lore
#0 lore raw

`make headers_check' now complains:

usr/include/linux/perf_event.h:22: included file
'asm-m68k/hw_breakpoint.h' is not exported

although CONFIG_HAVE_HW_BREAKPOINT is not set.

As <asm/hw_breakpoint.h> exists for x86 only, I guess every one else is suffering from this.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds

#1 lore raw

PATCH 1/1 don't include asm/hw_breakpoint.h in user space

asm/hw_breakpoint.h is evidently a kernel internal file and should not be included globally, not even under an #ifdef.

---

Quoted 9 lines · Geert Uytterhoeven

`make headers_check' now complains:

usr/include/linux/perf_event.h:22: included file
'asm-m68k/hw_breakpoint.h' is not exported

although CONFIG_HAVE_HW_BREAKPOINT is not set.

As <asm/hw_breakpoint.h> exists for x86 only, I guess every one else is suffering from this.

Even on x86, that header is not exported.

include/linux/perf_event.h +4 -4
@@ -18,10 +18,6 @@
 #include <linux/ioctl.h>
 #include <asm/byteorder.h>
 
-#ifdef CONFIG_HAVE_HW_BREAKPOINT
-#include <asm/hw_breakpoint.h>
-#endif
-
 /*
  * User-space ABI bits:
  */
@@ -451,6 +447,10 @@ enum perf_callchain_context {
 # include <asm/perf_event.h>
 #endif
 
+#ifdef CONFIG_HAVE_HW_BREAKPOINT
+#include <asm/hw_breakpoint.h>
+#endif
+
 #include <linux/list.h>
 #include <linux/mutex.h>
 #include <linux/rculist.h>
#2 lore raw

[tip:perf/urgent] perf events: hw_breakpoints: Don't include asm/hw_breakpoint.h in user space

Commit-ID:  2ff6cfd70720780234fdfea636218c2a62b31287
Gitweb:     http://git.kernel.org/tip/2ff6cfd70720780234fdfea636218c2a62b31287
Author:     Arnd Bergmann <[email protected]>
AuthorDate: Mon, 7 Dec 2009 17:12:58 +0100
Committer:  Ingo Molnar <[email protected]>
CommitDate: Tue, 8 Dec 2009 02:58:40 +0100

perf events: hw_breakpoints: Don't include asm/hw_breakpoint.h in user space

asm/hw_breakpoint.h is evidently a kernel internal file and should not be included globally, not even under an #ifdef.

LKML-Reference: <[email protected]>

---
 include/linux/perf_event.h |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
include/linux/perf_event.h +4 -4
index 89098e3..bf33294 100644
@@ -18,10 +18,6 @@
 #include <linux/ioctl.h>
 #include <asm/byteorder.h>
 
-#ifdef CONFIG_HAVE_HW_BREAKPOINT
-#include <asm/hw_breakpoint.h>
-#endif
-
 /*
  * User-space ABI bits:
  */
@@ -451,6 +447,10 @@ enum perf_callchain_context {
 # include <asm/perf_event.h>
 #endif
 
+#ifdef CONFIG_HAVE_HW_BREAKPOINT
+#include <asm/hw_breakpoint.h>
+#endif
+
 #include <linux/list.h>
 #include <linux/mutex.h>
 #include <linux/rculist.h>