summaryrefslogtreecommitdiff
path: root/scripts/headers_install.sh
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2020-06-17 17:33:13 +0900
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-07-10 14:50:51 +0200
commit04aaca197f16aff608e19ee98b1e55f535d746be (patch)
tree92de1d3fc0964c264c03fe882c4198f8c2f822f6 /scripts/headers_install.sh
parent51d501e540e6edd6737c0f1383b7789232595c13 (diff)
downloadlwn-04aaca197f16aff608e19ee98b1e55f535d746be.tar.gz
lwn-04aaca197f16aff608e19ee98b1e55f535d746be.zip
char: raw: do not leak CONFIG_MAX_RAW_DEVS to userspace
include/uapi/linux/raw.h leaks CONFIG_MAX_RAW_DEVS to userspace. Userspace programs cannot use MAX_RAW_MINORS since CONFIG_MAX_RAW_DEVS is not available anyway. Remove the MAX_RAW_MINORS definition from the exported header, and use CONFIG_MAX_RAW_DEVS in drivers/char/raw.c While I was here, I converted printk(KERN_WARNING ...) to pr_warn(...) and stretched the warning message. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Link: https://lore.kernel.org/r/20200617083313.183184-1-masahiroy@kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts/headers_install.sh')
-rwxr-xr-xscripts/headers_install.sh1
1 files changed, 0 insertions, 1 deletions
diff --git a/scripts/headers_install.sh b/scripts/headers_install.sh
index 224f51012b6e..cdd66038818c 100755
--- a/scripts/headers_install.sh
+++ b/scripts/headers_install.sh
@@ -90,7 +90,6 @@ include/uapi/linux/elfcore.h:CONFIG_BINFMT_ELF_FDPIC
include/uapi/linux/eventpoll.h:CONFIG_PM_SLEEP
include/uapi/linux/hw_breakpoint.h:CONFIG_HAVE_MIXED_BREAKPOINTS_REGS
include/uapi/linux/pktcdvd.h:CONFIG_CDROM_PKTCDVD_WCACHE
-include/uapi/linux/raw.h:CONFIG_MAX_RAW_DEVS
"
for c in $configs