linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/3] mm: add include files so that function definitions have a prototype
@ 2018-12-04  5:14 Adeodato Simó
  2018-12-04  5:14 ` [PATCH 2/3] mm: move two private functions to static linkage Adeodato Simó
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Adeodato Simó @ 2018-12-04  5:14 UTC (permalink / raw)
  To: linux-mm; +Cc: kernel-janitors

Previously, rodata_test(), usercopy_warn(), and usercopy_abort() were
defined without a matching prototype. Detected by -Wmissing-prototypes
GCC flag.

Signed-off-by: Adeodato Simó <dato@net.com.org.es>
---
I started poking at this after kernel-janitors got the suggestion[1]
to look into the -Wmissing-prototypes warnings.

Thanks for considering!

[1]: https://www.spinics.net/lists/linux-kernel-janitors/msg43981.html

 mm/rodata_test.c | 1 +
 mm/usercopy.c    | 1 +
 2 files changed, 2 insertions(+)

diff --git a/mm/rodata_test.c b/mm/rodata_test.c
index d908c8769b48..01306defbd1b 100644
--- a/mm/rodata_test.c
+++ b/mm/rodata_test.c
@@ -11,6 +11,7 @@
  */
 #define pr_fmt(fmt) "rodata_test: " fmt
 
+#include <linux/rodata_test.h>
 #include <linux/uaccess.h>
 #include <asm/sections.h>
 
diff --git a/mm/usercopy.c b/mm/usercopy.c
index 852eb4e53f06..f487ba4888df 100644
--- a/mm/usercopy.c
+++ b/mm/usercopy.c
@@ -20,6 +20,7 @@
 #include <linux/sched/task.h>
 #include <linux/sched/task_stack.h>
 #include <linux/thread_info.h>
+#include <linux/uaccess.h>
 #include <linux/atomic.h>
 #include <linux/jump_label.h>
 #include <asm/sections.h>
-- 
2.19.2

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

end of thread, other threads:[~2019-01-17 10:36 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-04  5:14 [PATCH 1/3] mm: add include files so that function definitions have a prototype Adeodato Simó
2018-12-04  5:14 ` [PATCH 2/3] mm: move two private functions to static linkage Adeodato Simó
2018-12-04  7:48   ` Mike Rapoport
2018-12-04  5:14 ` [PATCH 3/3] mm: add missing declaration of memmap_init in linux/mm.h Adeodato Simó
2018-12-04  7:48   ` Mike Rapoport
2018-12-04  7:47 ` [PATCH 1/3] mm: add include files so that function definitions have a prototype Mike Rapoport
2019-01-17 10:36 ` Adeodato Simó

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