mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] tools/resolve_btfids: Include linux/types.h
@ 2024-03-15  9:14 Dmitrii Bundin
  2024-03-15 15:41 ` Alexei Starovoitov
  0 siblings, 1 reply; 6+ messages in thread
From: Dmitrii Bundin @ 2024-03-15  9:14 UTC (permalink / raw)
  To: linux-kernel; +Cc: dxu, dmitrii.bundin.a, vmalik, ast, andrii, ndesaulniers

When compiling the kernel there's no type definition for u32 within the
translation unit causing compilation errors of the following format:

btf_ids.h:7:2: error: unknown type name ‘u32’

To avoid such errors it's possible to include the common header file
linux/types.h containing the required definition.

Signed-off-by: Dmitrii Bundin <dmitrii.bundin.a@gmail.com>
---
 tools/include/linux/btf_ids.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tools/include/linux/btf_ids.h b/tools/include/linux/btf_ids.h
index 72535f00572f..7969607efe0d 100644
--- a/tools/include/linux/btf_ids.h
+++ b/tools/include/linux/btf_ids.h
@@ -3,6 +3,8 @@
 #ifndef _LINUX_BTF_IDS_H
 #define _LINUX_BTF_IDS_H
 
+#include <linux/types.h>
+
 struct btf_id_set {
 	u32 cnt;
 	u32 ids[];
-- 
2.17.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-04-02 21:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-15  9:14 [PATCH] tools/resolve_btfids: Include linux/types.h Dmitrii Bundin
2024-03-15 15:41 ` Alexei Starovoitov
2024-03-15 17:04   ` Dmitrii Bundin
2024-03-18 16:55     ` Khazhy Kumykov
2024-03-21 19:50       ` Dmitrii Bundin
2024-04-02 21:09         ` Khazhy Kumykov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®