sparse: remove uneffective sparse disabling
PATCH 1/1 sparse: remove uneffective sparse disabling
Sparse checking used to be disabled on init/do_mounts.c and a few related files because "Many of the syscalls used in this file expect some of the arguments to be __user pointers not __kernel pointers".
However since commit 28128c61e ("kconfig.h: Include compiler types to avoid missed struct attributes") the checks are, in fact, not disabled anymore because of the more early include of "linux/compiler_types.h"
So remove the now uneffective #undefery that was done to disable these warnings, as well as the associated comment.
Signed-off-by Luc Van Oostenryck <[email protected]>
--- init/do_mounts.c | 10 ---------- init/do_mounts_initrd.c | 10 ---------- init/do_mounts_md.c | 10 ---------- init/do_mounts_rd.c | 10 ---------- init/initramfs.c | 10 ---------- 5 files changed, 50 deletions(-)
init/do_mounts.c +0 -10
@@ -1,13 +1,3 @@ -/* -* Many of the syscalls used in this file expect some of the arguments -* to be __user pointers not __kernel pointers. To limit the sparse -* noise, turn off sparse checking for this file. -*/ -#ifdef __CHECKER__ -#undef __CHECKER__ -#warning "Sparse checking disabled for this file" -#endif -#include <linux/module.h> #include <linux/sched.h> #include <linux/ctype.h>
init/do_mounts_initrd.c +0 -10
@@ -1,14 +1,4 @@// SPDX-License-Identifier: GPL-2.0 -/* -* Many of the syscalls used in this file expect some of the arguments -* to be __user pointers not __kernel pointers. To limit the sparse -* noise, turn off sparse checking for this file. -*/ -#ifdef __CHECKER__ -#undef __CHECKER__ -#warning "Sparse checking disabled for this file" -#endif -#include <linux/unistd.h> #include <linux/kernel.h> #include <linux/fs.h>
init/do_mounts_md.c +0 -10
@@ -1,14 +1,4 @@// SPDX-License-Identifier: GPL-2.0 -/* -* Many of the syscalls used in this file expect some of the arguments -* to be __user pointers not __kernel pointers. To limit the sparse -* noise, turn off sparse checking for this file. -*/ -#ifdef __CHECKER__ -#undef __CHECKER__ -#warning "Sparse checking disabled for this file" -#endif -#include <linux/delay.h> #include <linux/raid/md_u.h> #include <linux/raid/md_p.h>
init/do_mounts_rd.c +0 -10
@@ -1,14 +1,4 @@// SPDX-License-Identifier: GPL-2.0 -/* -* Many of the syscalls used in this file expect some of the arguments -* to be __user pointers not __kernel pointers. To limit the sparse -* noise, turn off sparse checking for this file. -*/ -#ifdef __CHECKER__ -#undef __CHECKER__ -#warning "Sparse checking disabled for this file" -#endif -#include <linux/kernel.h> #include <linux/fs.h> #include <linux/minix_fs.h>
init/initramfs.c +0 -10
@@ -1,14 +1,4 @@// SPDX-License-Identifier: GPL-2.0 -/* -* Many of the syscalls used in this file expect some of the arguments -* to be __user pointers not __kernel pointers. To limit the sparse -* noise, turn off sparse checking for this file. -*/ -#ifdef __CHECKER__ -#undef __CHECKER__ -#warning "Sparse checking disabled for this file" -#endif -#include <linux/init.h> #include <linux/fs.h> #include <linux/slab.h>
Signature · 1 line
2.17.1