All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] kcov: add missing #include <linux/sched.h>
@ 2016-12-06  6:56 Kefeng Wang
  2016-12-06 11:09 ` Mark Rutland
  0 siblings, 1 reply; 3+ messages in thread
From: Kefeng Wang @ 2016-12-06  6:56 UTC (permalink / raw)
  To: linux-kernel
  Cc: Dmitry Vyukov, Andrey Ryabinin, Mark Rutland, James Morse,
	Andrew Morton, Kefeng Wang

It is needed by struct task_struct, fixes the following build problem
with old gcc:

../kernel/kcov.c: In function ‘__sanitizer_cov_trace_pc’:
../kernel/kcov.c:66: error: dereferencing pointer to incomplete type
	......
../kernel/kcov.c:239: error: dereferencing pointer to incomplete type

Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
---

note:
- Build error occurred when I backported kcov to an old kernel version
  with an old gcc

 kernel/kcov.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/kernel/kcov.c b/kernel/kcov.c
index 30e6d05..3cbb0c8 100644
--- a/kernel/kcov.c
+++ b/kernel/kcov.c
@@ -7,6 +7,7 @@
 #include <linux/fs.h>
 #include <linux/mm.h>
 #include <linux/printk.h>
+#include <linux/sched.h>
 #include <linux/slab.h>
 #include <linux/spinlock.h>
 #include <linux/vmalloc.h>
-- 
1.7.12.4

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

end of thread, other threads:[~2016-12-08  2:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-12-06  6:56 [PATCH] kcov: add missing #include <linux/sched.h> Kefeng Wang
2016-12-06 11:09 ` Mark Rutland
2016-12-08  2:13   ` [PATCH] kcov: add more missing include Kefeng Wang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.