Commit e585e47031751f4e393e10ffd922885508b958dd
Committed by
Linus Torvalds
1 parent
22c4e3084e
Exists in
master
and in
7 other branches
[PATCH] tiny: Make *[ug]id16 support optional
Configurable 16-bit UID and friends support This allows turning off the legacy 16 bit UID interfaces on embedded platforms. text data bss dec hex filename 3330172 529036 190556 4049764 3dcb64 vmlinux-baseline 3328268 529040 190556 4047864 3dc3f8 vmlinux From: Adrian Bunk <bunk@stusta.de> UID16 was accidentially disabled for !EMBEDDED. Signed-off-by: Matt Mackall <mpm@selenic.com> Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Showing 19 changed files with 28 additions and 65 deletions Side-by-side Diff
- arch/alpha/Kconfig
- arch/arm/Kconfig
- arch/arm26/Kconfig
- arch/cris/Kconfig
- arch/h8300/Kconfig
- arch/i386/Kconfig
- arch/m68k/Kconfig
- arch/m68knommu/Kconfig
- arch/parisc/Kconfig
- arch/powerpc/Kconfig
- arch/ppc/Kconfig
- arch/sh/Kconfig
- arch/sparc/Kconfig
- arch/sparc64/Kconfig
- arch/um/Kconfig
- arch/v850/Kconfig
- arch/x86_64/Kconfig
- init/Kconfig
- kernel/sys_ni.c
arch/alpha/Kconfig
arch/arm/Kconfig
arch/arm26/Kconfig
arch/cris/Kconfig
arch/h8300/Kconfig
arch/i386/Kconfig
arch/m68k/Kconfig
arch/m68knommu/Kconfig
arch/parisc/Kconfig
arch/powerpc/Kconfig
arch/ppc/Kconfig
arch/sh/Kconfig
arch/sparc/Kconfig
arch/sparc64/Kconfig
arch/um/Kconfig
arch/v850/Kconfig
arch/x86_64/Kconfig
init/Kconfig
... | ... | @@ -228,6 +228,15 @@ |
228 | 228 | |
229 | 229 | source "usr/Kconfig" |
230 | 230 | |
231 | +config UID16 | |
232 | + bool "Enable 16-bit UID system calls" if EMBEDDED | |
233 | + depends !ALPHA && !PPC && !PPC64 && !PARISC && !V850 && !ARCH_S390X | |
234 | + depends !X86_64 || IA32_EMULATION | |
235 | + depends !SPARC64 || SPARC32_COMPAT | |
236 | + default y | |
237 | + help | |
238 | + This enables the legacy 16-bit UID syscall wrappers. | |
239 | + | |
231 | 240 | config CC_OPTIMIZE_FOR_SIZE |
232 | 241 | bool "Optimize for size (Look out for broken compilers!)" |
233 | 242 | default y |
kernel/sys_ni.c
... | ... | @@ -83,6 +83,25 @@ |
83 | 83 | cond_syscall(sys_inotify_add_watch); |
84 | 84 | cond_syscall(sys_inotify_rm_watch); |
85 | 85 | cond_syscall(sys_migrate_pages); |
86 | +cond_syscall(sys_chown16); | |
87 | +cond_syscall(sys_fchown16); | |
88 | +cond_syscall(sys_getegid16); | |
89 | +cond_syscall(sys_geteuid16); | |
90 | +cond_syscall(sys_getgid16); | |
91 | +cond_syscall(sys_getgroups16); | |
92 | +cond_syscall(sys_getresgid16); | |
93 | +cond_syscall(sys_getresuid16); | |
94 | +cond_syscall(sys_getuid16); | |
95 | +cond_syscall(sys_lchown16); | |
96 | +cond_syscall(sys_setfsgid16); | |
97 | +cond_syscall(sys_setfsuid16); | |
98 | +cond_syscall(sys_setgid16); | |
99 | +cond_syscall(sys_setgroups16); | |
100 | +cond_syscall(sys_setregid16); | |
101 | +cond_syscall(sys_setresgid16); | |
102 | +cond_syscall(sys_setresuid16); | |
103 | +cond_syscall(sys_setreuid16); | |
104 | +cond_syscall(sys_setuid16); | |
86 | 105 | |
87 | 106 | /* arch-specific weak syscall entries */ |
88 | 107 | cond_syscall(sys_pciconfig_read); |