diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2014-05-28 06:20:35 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2014-05-28 06:21:07 +0000 |
commit | 430da292454219c5adecd9fc5f4c052ff94bf76d (patch) | |
tree | 9f4ccd87151aab2ca103ce7125ef6f766fb8dee1 | |
parent | 81b342cdfc3e518771cb9383769cb6d51091a2fa (diff) | |
download | aports-430da292454219c5adecd9fc5f4c052ff94bf76d.tar.bz2 aports-430da292454219c5adecd9fc5f4c052ff94bf76d.tar.xz |
main/linux-grsec: upgrade to grsecurity-3.0-3.14.4-201405271114
-rw-r--r-- | main/linux-grsec/APKBUILD | 28 | ||||
-rw-r--r-- | main/linux-grsec/grsecurity-3.0-3.14.4-201405271114.patch (renamed from main/linux-grsec/grsecurity-3.0-3.14.4-201405131205.patch) | 868 | ||||
-rw-r--r-- | main/linux-grsec/kernelconfig.armhf | 3 | ||||
-rw-r--r-- | main/linux-grsec/kernelconfig.x86 | 3 | ||||
-rw-r--r-- | main/linux-grsec/kernelconfig.x86_64 | 3 |
5 files changed, 701 insertions, 204 deletions
diff --git a/main/linux-grsec/APKBUILD b/main/linux-grsec/APKBUILD index c165a3930..49d3b4ace 100644 --- a/main/linux-grsec/APKBUILD +++ b/main/linux-grsec/APKBUILD @@ -7,7 +7,7 @@ case $pkgver in *.*.*) _kernver=${pkgver%.*};; *.*) _kernver=${pkgver};; esac -pkgrel=0 +pkgrel=1 pkgdesc="Linux kernel with grsecurity" url=http://grsecurity.net depends="mkinitfs linux-firmware" @@ -17,7 +17,7 @@ _config=${config:-kernelconfig.${CARCH}} install= source="http://ftp.kernel.org/pub/linux/kernel/v3.x/linux-$_kernver.tar.xz http://ftp.kernel.org/pub/linux/kernel/v3.x/patch-$pkgver.xz - grsecurity-3.0-3.14.4-201405131205.patch + grsecurity-3.0-3.14.4-201405271114.patch fix-memory-map-for-PIE-applications.patch imx6q-no-unclocked-sleep.patch @@ -166,25 +166,25 @@ dev() { md5sums="b621207b3f6ecbb67db18b13258f8ea8 linux-3.14.tar.xz 116f27cf17c3522716b6678b17516067 patch-3.14.4.xz -6982685dd709f6fb9f256161c1af1af2 grsecurity-3.0-3.14.4-201405131205.patch +60e4f370c3543eb4634c84c24009b92d grsecurity-3.0-3.14.4-201405271114.patch c6a4ae7e8ca6159e1631545515805216 fix-memory-map-for-PIE-applications.patch 1a307fc1d63231bf01d22493a4f14378 imx6q-no-unclocked-sleep.patch -68efadc03ab0d14a4ac1549f77a07bb9 kernelconfig.x86 -0765de8921029ddcead8a430a26fb1ee kernelconfig.x86_64 -6da9d80a834790fa94f06d1ac3e9c6d5 kernelconfig.armhf" +b780cabb3c188419b1a3d8f794a1768e kernelconfig.x86 +b300269e60b2dd901543d8bc8952513b kernelconfig.x86_64 +727688e12e37262437fc9ca9c1fbd215 kernelconfig.armhf" sha256sums="61558aa490855f42b6340d1a1596be47454909629327c49a5e4e10268065dffa linux-3.14.tar.xz af640ea64e923d525a8238832e8452381e6dc76a3bf28046411cadd67c408114 patch-3.14.4.xz -d5a84246d0401cc9d79abde2cef6b83732eb0b5d3d745c015d25544e8cc1ad62 grsecurity-3.0-3.14.4-201405131205.patch +76daa7e437ab5fedc51c1fec3a84b7e6901a073b083a94e3a55671bca9e67d34 grsecurity-3.0-3.14.4-201405271114.patch 500f3577310be52e87b9fecdc2e9c4ca43210fd97d69089f9005d484563f74c7 fix-memory-map-for-PIE-applications.patch 21179fbb22a5b74af0a609350ae1a170e232908572b201d02e791d2ce0a685d3 imx6q-no-unclocked-sleep.patch -9081bc214794934170813ac4c88ec62db503c270a4f2a6c36a4bcdc695b32809 kernelconfig.x86 -239513012483b28902951077c6aa4cea70be32e760c5a10cc9a3811fe5e92f06 kernelconfig.x86_64 -0422a2a80edb9c6de1a97f4ac9a08ad03097d59970d18387ba499f714b402d67 kernelconfig.armhf" +d8b2d8ef8369a1df10763e5476efe8f9f500fd9d604e3452eb2ddee6b78d7e3e kernelconfig.x86 +1d271876621133eba10c83d1aefbe248dca333038e42054f5dc0222edc954731 kernelconfig.x86_64 +00fc74f27931d161ecc1c26e5cd000d9aeaf6ebea6e0e1293ecde14a64d80467 kernelconfig.armhf" sha512sums="5730d83a7a81134c1e77c0bf89e42dee4f8251ad56c1ac2be20c59e26fdfaa7bea55f277e7af156b637f22e1584914a46089af85039177cb43485089c74ac26e linux-3.14.tar.xz 61eca26d57f7d7caa78d157582d4b98fbba1c85af73f1773fb51eab3db4381de53f4fbfbc202083e45297c0b4487bc58880a518e7ee9c0d616cddf0b3909b303 patch-3.14.4.xz -9b4ae932c145d0cd0b32c9bfc7c21a8ea25c29d3beed3c34b91fe5a3ec30a487f002f51d9b0c1bf5a64e0dd9baa0b19cce3ce1cfb3b236129e83dd8472f8fef7 grsecurity-3.0-3.14.4-201405131205.patch +4276c7f2d533b62074180efb069047f562336647078cd47b8a0abb70123fe05f3b2d30c3a212358bfde9897f8b5592d63057f66c2b47718691474cbc77f09d5a grsecurity-3.0-3.14.4-201405271114.patch 4665c56ae1bbac311f9205d64918e84ee8b01d47d6e2396ff6b8adfb10aada7f7254531ce62e31edbb65c2a54a830f09ad05d314dfcd75d6272f4068945ad7c7 fix-memory-map-for-PIE-applications.patch 87d1ad59732f265a5b0db54490dc1762c14ea4b868e7eb1aedc3ce57b48046de7bbc08cf5cfcf6f1380fa84063b0edb16ba3d5e3c5670be9bbb229275c88b221 imx6q-no-unclocked-sleep.patch -a4c3d9e2683e92354c38c0a2b63322b27fb6c1eaa57adea603b522e9b9eed21678f9fcf0afa3f8e9b089e85f31295a89b469c924b458defbd3540a086f3b9ba5 kernelconfig.x86 -9e399c2f4bc3f7b6342ce4e79d6e35dbe0bdf77c2ff8cc8ba9f0f4c9ca72f3d4298052dc3d0e05cae2fcd0000bb349172f329ef37b3ae8cacac55ae578196de6 kernelconfig.x86_64 -7479ef9c83988800bb5621c057d57d1a23787ab4514df2816709d885633e2d71c0e2f9a401cd25c5e56f8e4c1990549351496402c767952188715d9245002c01 kernelconfig.armhf" +841a301668cc23daec38585c2c76af5195c38638ffce314ca03a16f8a842e3229c933bd52d0e83209f340d2871cf4ccb0864b9662f8ea9f608c2b2aa0a0eea3f kernelconfig.x86 +37ed9ad11a8b05c26bfbe03ef6fb639cc126daa127479b74ba1c4608f3faef7013adfe6ff1009410466c6981a031c660a3cedc67843a343a00384150f2958395 kernelconfig.x86_64 +84cf8bf558d3fa98a46a2dc1bdd5ddbe4b36b210282d939a47123d889a47240469e7b37f1351854a396c58f4366b8267e1e7990fb91be23bc8ddd9f2a33a6257 kernelconfig.armhf" diff --git a/main/linux-grsec/grsecurity-3.0-3.14.4-201405131205.patch b/main/linux-grsec/grsecurity-3.0-3.14.4-201405271114.patch index 9a8e53a50..3537db839 100644 --- a/main/linux-grsec/grsecurity-3.0-3.14.4-201405131205.patch +++ b/main/linux-grsec/grsecurity-3.0-3.14.4-201405271114.patch @@ -287,7 +287,7 @@ index 7116fda..d8ed6e8 100644 pcd. [PARIDE] diff --git a/Makefile b/Makefile -index d7c07fd..d6d4bfa 100644 +index d7c07fd..1ad8228 100644 --- a/Makefile +++ b/Makefile @@ -244,8 +244,9 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \ @@ -445,17 +445,19 @@ index d7c07fd..d6d4bfa 100644 # Target to install modules PHONY += modules_install -@@ -1072,7 +1146,8 @@ MRPROPER_FILES += .config .config.old .version .old_version $(version_h) \ +@@ -1072,7 +1146,10 @@ MRPROPER_FILES += .config .config.old .version .old_version $(version_h) \ Module.symvers tags TAGS cscope* GPATH GTAGS GRTAGS GSYMS \ signing_key.priv signing_key.x509 x509.genkey \ extra_certificates signing_key.x509.keyid \ - signing_key.x509.signer -+ signing_key.x509.signer tools/gcc/size_overflow_hash.h \ ++ signing_key.x509.signer \ ++ tools/gcc/size_overflow_plugin/size_overflow_hash_aux.h \ ++ tools/gcc/size_overflow_plugin/size_overflow_hash.h \ + tools/gcc/randomize_layout_seed.h # clean - Delete most, but leave enough to build external modules # -@@ -1112,6 +1187,7 @@ distclean: mrproper +@@ -1112,6 +1189,7 @@ distclean: mrproper \( -name '*.orig' -o -name '*.rej' -o -name '*~' \ -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \ -o -name '.*.rej' \ @@ -463,7 +465,7 @@ index d7c07fd..d6d4bfa 100644 -o -name '*%' -o -name '.*.cmd' -o -name 'core' \) \ -type f -print | xargs rm -f -@@ -1273,6 +1349,8 @@ PHONY += $(module-dirs) modules +@@ -1273,6 +1351,8 @@ PHONY += $(module-dirs) modules $(module-dirs): crmodverdir $(objtree)/Module.symvers $(Q)$(MAKE) $(build)=$(patsubst _module_%,%,$@) @@ -472,7 +474,7 @@ index d7c07fd..d6d4bfa 100644 modules: $(module-dirs) @$(kecho) ' Building modules, stage 2.'; $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost -@@ -1412,17 +1490,21 @@ else +@@ -1412,17 +1492,21 @@ else target-dir = $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@)) endif @@ -498,7 +500,7 @@ index d7c07fd..d6d4bfa 100644 $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) %.symtypes: %.c prepare scripts FORCE $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) -@@ -1432,11 +1514,15 @@ endif +@@ -1432,11 +1516,15 @@ endif $(cmd_crmodverdir) $(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \ $(build)=$(build-dir) @@ -12667,10 +12669,10 @@ index 321a52c..3d51a5e 100644 This option helps catch unintended modifications to loadable kernel module's text and read-only data. It also prevents execution diff --git a/arch/x86/Makefile b/arch/x86/Makefile -index 0dd99ea..e893775 100644 +index 0dd99ea..4a63d82 100644 --- a/arch/x86/Makefile +++ b/arch/x86/Makefile -@@ -71,15 +71,12 @@ ifeq ($(CONFIG_X86_32),y) +@@ -71,9 +71,6 @@ ifeq ($(CONFIG_X86_32),y) # CPU-specific tuning. Anything which can be shared with UML should go here. include $(srctree)/arch/x86/Makefile_32.cpu KBUILD_CFLAGS += $(cflags-y) @@ -12680,13 +12682,6 @@ index 0dd99ea..e893775 100644 else BITS := 64 UTS_MACHINE := x86_64 - CHECKFLAGS += -D__x86_64__ -m64 - -- biarch := -m64 -+ biarch := $(call cc-option,-m64) - KBUILD_AFLAGS += -m64 - KBUILD_CFLAGS += -m64 - @@ -112,6 +109,9 @@ else KBUILD_CFLAGS += -maccumulate-outgoing-args endif @@ -16975,6 +16970,18 @@ index b4c1f54..e290c08 100644 pagefault_enable(); +diff --git a/arch/x86/include/asm/hugetlb.h b/arch/x86/include/asm/hugetlb.h +index a809121..68c0539 100644 +--- a/arch/x86/include/asm/hugetlb.h ++++ b/arch/x86/include/asm/hugetlb.h +@@ -52,6 +52,7 @@ static inline pte_t huge_ptep_get_and_clear(struct mm_struct *mm, + static inline void huge_ptep_clear_flush(struct vm_area_struct *vma, + unsigned long addr, pte_t *ptep) + { ++ ptep_clear_flush(vma, addr, ptep); + } + + static inline int huge_pte_none(pte_t pte) diff --git a/arch/x86/include/asm/hw_irq.h b/arch/x86/include/asm/hw_irq.h index 67d69b8..50e4b77 100644 --- a/arch/x86/include/asm/hw_irq.h @@ -25826,10 +25833,19 @@ index c2bedae..25e7ab6 100644 .name = "data", .mode = S_IRUGO, diff --git a/arch/x86/kernel/ldt.c b/arch/x86/kernel/ldt.c -index af1d14a..37b8776 100644 +index af1d14a..81ae763 100644 --- a/arch/x86/kernel/ldt.c +++ b/arch/x86/kernel/ldt.c -@@ -66,13 +66,13 @@ static int alloc_ldt(mm_context_t *pc, int mincount, int reload) +@@ -20,6 +20,8 @@ + #include <asm/mmu_context.h> + #include <asm/syscalls.h> + ++int sysctl_ldt16 = 0; ++ + #ifdef CONFIG_SMP + static void flush_ldt(void *current_mm) + { +@@ -66,13 +68,13 @@ static int alloc_ldt(mm_context_t *pc, int mincount, int reload) if (reload) { #ifdef CONFIG_SMP preempt_disable(); @@ -25845,7 +25861,7 @@ index af1d14a..37b8776 100644 #endif } if (oldsize) { -@@ -94,7 +94,7 @@ static inline int copy_ldt(mm_context_t *new, mm_context_t *old) +@@ -94,7 +96,7 @@ static inline int copy_ldt(mm_context_t *new, mm_context_t *old) return err; for (i = 0; i < old->size; i++) @@ -25854,7 +25870,7 @@ index af1d14a..37b8776 100644 return 0; } -@@ -115,6 +115,24 @@ int init_new_context(struct task_struct *tsk, struct mm_struct *mm) +@@ -115,6 +117,24 @@ int init_new_context(struct task_struct *tsk, struct mm_struct *mm) retval = copy_ldt(&mm->context, &old_mm->context); mutex_unlock(&old_mm->context.lock); } @@ -25879,7 +25895,7 @@ index af1d14a..37b8776 100644 return retval; } -@@ -229,6 +247,13 @@ static int write_ldt(void __user *ptr, unsigned long bytecount, int oldmode) +@@ -229,12 +249,19 @@ static int write_ldt(void __user *ptr, unsigned long bytecount, int oldmode) } } @@ -25893,6 +25909,13 @@ index af1d14a..37b8776 100644 /* * On x86-64 we do not support 16-bit segments due to * IRET leaking the high bits of the kernel stack address. + */ + #ifdef CONFIG_X86_64 +- if (!ldt_info.seg_32bit) { ++ if (!ldt_info.seg_32bit && !sysctl_ldt16) { + error = -EINVAL; + goto out_unlock; + } diff --git a/arch/x86/kernel/machine_kexec_32.c b/arch/x86/kernel/machine_kexec_32.c index 1667b1d..16492c5 100644 --- a/arch/x86/kernel/machine_kexec_32.c @@ -26193,7 +26216,7 @@ index bbb6c73..24a58ef 100644 .lock_spinning = __PV_IS_CALLEE_SAVE(paravirt_nop), .unlock_kick = paravirt_nop, diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c -index 1b10af8..0b58cbc 100644 +index 1b10af8..45bfbec 100644 --- a/arch/x86/kernel/paravirt.c +++ b/arch/x86/kernel/paravirt.c @@ -55,6 +55,9 @@ u64 _paravirt_ident_64(u64 x) @@ -26206,11 +26229,13 @@ index 1b10af8..0b58cbc 100644 void __init default_banner(void) { -@@ -142,15 +145,19 @@ unsigned paravirt_patch_default(u8 type, u16 clobbers, void *insnbuf, +@@ -141,16 +144,20 @@ unsigned paravirt_patch_default(u8 type, u16 clobbers, void *insnbuf, + if (opfunc == NULL) /* If there's no function, patch it with a ud2a (BUG) */ - ret = paravirt_patch_insns(insnbuf, len, ud2a, ud2a+sizeof(ud2a)); +- ret = paravirt_patch_insns(insnbuf, len, ud2a, ud2a+sizeof(ud2a)); - else if (opfunc == _paravirt_nop) ++ ret = paravirt_patch_insns(insnbuf, len, ktva_ktla(ud2a), ud2a+sizeof(ud2a)); + else if (opfunc == (void *)_paravirt_nop) /* If the operation is a nop, then nop the callsite */ ret = paravirt_patch_nop(); @@ -27788,7 +27813,7 @@ index 1c113db..287b42e 100644 static int trace_irq_vector_refcount; static DEFINE_MUTEX(irq_vector_mutex); diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c -index 57409f6..e2c17e1 100644 +index 57409f6..b505597 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c @@ -66,7 +66,7 @@ @@ -27867,7 +27892,19 @@ index 57409f6..e2c17e1 100644 regs->ip, regs->sp, error_code); print_vma_addr(" in ", regs->ip); pr_cont("\n"); -@@ -273,7 +285,7 @@ do_general_protection(struct pt_regs *regs, long error_code) +@@ -251,6 +263,11 @@ dotraplinkage void do_double_fault(struct pt_regs *regs, long error_code) + tsk->thread.error_code = error_code; + tsk->thread.trap_nr = X86_TRAP_DF; + ++#ifdef CONFIG_GRKERNSEC_KSTACKOVERFLOW ++ if ((unsigned long)tsk->stack - regs->sp <= PAGE_SIZE) ++ die("grsec: kernel stack overflow detected", regs, error_code); ++#endif ++ + #ifdef CONFIG_DOUBLEFAULT + df_debug(regs, error_code); + #endif +@@ -273,7 +290,7 @@ do_general_protection(struct pt_regs *regs, long error_code) conditional_sti(regs); #ifdef CONFIG_X86_32 @@ -27876,7 +27913,7 @@ index 57409f6..e2c17e1 100644 local_irq_enable(); handle_vm86_fault((struct kernel_vm86_regs *) regs, error_code); goto exit; -@@ -281,18 +293,42 @@ do_general_protection(struct pt_regs *regs, long error_code) +@@ -281,18 +298,42 @@ do_general_protection(struct pt_regs *regs, long error_code) #endif tsk = current; @@ -27921,7 +27958,7 @@ index 57409f6..e2c17e1 100644 tsk->thread.error_code = error_code; tsk->thread.trap_nr = X86_TRAP_GP; -@@ -453,7 +489,7 @@ dotraplinkage void __kprobes do_debug(struct pt_regs *regs, long error_code) +@@ -453,7 +494,7 @@ dotraplinkage void __kprobes do_debug(struct pt_regs *regs, long error_code) /* It's safe to allow irq's after DR6 has been saved */ preempt_conditional_sti(regs); @@ -27930,7 +27967,7 @@ index 57409f6..e2c17e1 100644 handle_vm86_trap((struct kernel_vm86_regs *) regs, error_code, X86_TRAP_DB); preempt_conditional_cli(regs); -@@ -468,7 +504,7 @@ dotraplinkage void __kprobes do_debug(struct pt_regs *regs, long error_code) +@@ -468,7 +509,7 @@ dotraplinkage void __kprobes do_debug(struct pt_regs *regs, long error_code) * We already checked v86 mode above, so we can check for kernel mode * by just checking the CPL of CS. */ @@ -27939,7 +27976,7 @@ index 57409f6..e2c17e1 100644 tsk->thread.debugreg6 &= ~DR_STEP; set_tsk_thread_flag(tsk, TIF_SINGLESTEP); regs->flags &= ~X86_EFLAGS_TF; -@@ -500,7 +536,7 @@ void math_error(struct pt_regs *regs, int error_code, int trapnr) +@@ -500,7 +541,7 @@ void math_error(struct pt_regs *regs, int error_code, int trapnr) return; conditional_sti(regs); @@ -35603,7 +35640,7 @@ index fd14be1..e3c79c0 100644 # diff --git a/arch/x86/vdso/vdso32-setup.c b/arch/x86/vdso/vdso32-setup.c -index d6bfb87..876ee18 100644 +index d6bfb87..a75c5f7 100644 --- a/arch/x86/vdso/vdso32-setup.c +++ b/arch/x86/vdso/vdso32-setup.c @@ -25,6 +25,7 @@ @@ -35614,7 +35651,15 @@ index d6bfb87..876ee18 100644 enum { VDSO_DISABLED = 0, -@@ -226,7 +227,7 @@ static inline void map_compat_vdso(int map) +@@ -41,6 +42,7 @@ enum { + #ifdef CONFIG_X86_64 + #define vdso_enabled sysctl_vsyscall32 + #define arch_setup_additional_pages syscall32_setup_pages ++extern int sysctl_ldt16; + #endif + + /* +@@ -226,7 +228,7 @@ static inline void map_compat_vdso(int map) void enable_sep_cpu(void) { int cpu = get_cpu(); @@ -35623,7 +35668,7 @@ index d6bfb87..876ee18 100644 if (!boot_cpu_has(X86_FEATURE_SEP)) { put_cpu(); -@@ -249,7 +250,7 @@ static int __init gate_vma_init(void) +@@ -249,7 +251,7 @@ static int __init gate_vma_init(void) gate_vma.vm_start = FIXADDR_USER_START; gate_vma.vm_end = FIXADDR_USER_END; gate_vma.vm_flags = VM_READ | VM_MAYREAD | VM_EXEC | VM_MAYEXEC; @@ -35632,7 +35677,7 @@ index d6bfb87..876ee18 100644 return 0; } -@@ -330,14 +331,14 @@ int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp) +@@ -330,14 +332,14 @@ int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp) if (compat) addr = VDSO_HIGH_BASE; else { @@ -35649,7 +35694,7 @@ index d6bfb87..876ee18 100644 if (compat_uses_vma || !compat) { /* -@@ -353,11 +354,11 @@ int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp) +@@ -353,11 +355,11 @@ int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp) } current_thread_info()->sysenter_return = @@ -35663,7 +35708,21 @@ index d6bfb87..876ee18 100644 up_write(&mm->mmap_sem); -@@ -404,8 +405,14 @@ __initcall(ia32_binfmt_init); +@@ -380,6 +382,13 @@ static struct ctl_table abi_table2[] = { + .mode = 0644, + .proc_handler = proc_dointvec + }, ++ { ++ .procname = "ldt16", ++ .data = &sysctl_ldt16, ++ .maxlen = sizeof(int), ++ .mode = 0644, ++ .proc_handler = proc_dointvec ++ }, + {} + }; + +@@ -404,8 +413,14 @@ __initcall(ia32_binfmt_init); const char *arch_vma_name(struct vm_area_struct *vma) { @@ -35679,7 +35738,7 @@ index d6bfb87..876ee18 100644 return NULL; } -@@ -415,7 +422,7 @@ struct vm_area_struct *get_gate_vma(struct mm_struct *mm) +@@ -415,7 +430,7 @@ struct vm_area_struct *get_gate_vma(struct mm_struct *mm) * Check to see if the corresponding task was created in compat vdso * mode. */ @@ -58779,7 +58838,7 @@ index e4141f2..d8263e8 100644 i += packet_length_size; if (copy_to_user(&buf[i], msg_ctx->msg, msg_ctx->msg_size)) diff --git a/fs/exec.c b/fs/exec.c -index 3d78fcc..460e2a0 100644 +index 3d78fcc..cd4f983 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -55,8 +55,20 @@ @@ -59088,7 +59147,15 @@ index 3d78fcc..460e2a0 100644 set_fs(old_fs); return result; } -@@ -1258,7 +1336,7 @@ static void check_unsafe_exec(struct linux_binprm *bprm) +@@ -846,6 +924,7 @@ static int exec_mmap(struct mm_struct *mm) + tsk->mm = mm; + tsk->active_mm = mm; + activate_mm(active_mm, mm); ++ populate_stack(); + task_unlock(tsk); + if (old_mm) { + up_read(&old_mm->mmap_sem); +@@ -1258,7 +1337,7 @@ static void check_unsafe_exec(struct linux_binprm *bprm) } rcu_read_unlock(); @@ -59097,7 +59164,7 @@ index 3d78fcc..460e2a0 100644 bprm->unsafe |= LSM_UNSAFE_SHARE; else p->fs->in_exec = 1; -@@ -1434,6 +1512,31 @@ static int exec_binprm(struct linux_binprm *bprm) +@@ -1434,6 +1513,31 @@ static int exec_binprm(struct linux_binprm *bprm) return ret; } @@ -59129,7 +59196,7 @@ index 3d78fcc..460e2a0 100644 /* * sys_execve() executes a new program. */ -@@ -1441,6 +1544,11 @@ static int do_execve_common(struct filename *filename, +@@ -1441,6 +1545,11 @@ static int do_execve_common(struct filename *filename, struct user_arg_ptr argv, struct user_arg_ptr envp) { @@ -59141,7 +59208,7 @@ index 3d78fcc..460e2a0 100644 struct linux_binprm *bprm; struct file *file; struct files_struct *displaced; -@@ -1449,6 +1557,8 @@ static int do_execve_common(struct filename *filename, +@@ -1449,6 +1558,8 @@ static int do_execve_common(struct filename *filename, if (IS_ERR(filename)) return PTR_ERR(filename); @@ -59150,7 +59217,7 @@ index 3d78fcc..460e2a0 100644 /* * We move the actual failure in case of RLIMIT_NPROC excess from * set*uid() to execve() because too many poorly written programs -@@ -1486,11 +1596,21 @@ static int do_execve_common(struct filename *filename, +@@ -1486,11 +1597,21 @@ static int do_execve_common(struct filename *filename, if (IS_ERR(file)) goto out_unmark; @@ -59172,7 +59239,7 @@ index 3d78fcc..460e2a0 100644 retval = bprm_mm_init(bprm); if (retval) goto out_unmark; -@@ -1507,24 +1627,70 @@ static int do_execve_common(struct filename *filename, +@@ -1507,24 +1628,70 @@ static int do_execve_common(struct filename *filename, if (retval < 0) goto out; @@ -59247,7 +59314,7 @@ index 3d78fcc..460e2a0 100644 current->fs->in_exec = 0; current->in_execve = 0; acct_update_integrals(current); -@@ -1535,6 +1701,14 @@ static int do_execve_common(struct filename *filename, +@@ -1535,6 +1702,14 @@ static int do_execve_common(struct filename *filename, put_files_struct(displaced); return retval; @@ -59262,7 +59329,7 @@ index 3d78fcc..460e2a0 100644 out: if (bprm->mm) { acct_arg_size(bprm, 0); -@@ -1626,3 +1800,296 @@ asmlinkage long compat_sys_execve(const char __user * filename, +@@ -1626,3 +1801,296 @@ asmlinkage long compat_sys_execve(const char __user * filename, return compat_do_execve(getname(filename), argv, envp); } #endif @@ -65603,6 +65670,25 @@ index ee0d761..b346c58 100644 return PTR_ERR(kn); } +diff --git a/fs/sysfs/file.c b/fs/sysfs/file.c +index 810cf6e..5fd2bf1 100644 +--- a/fs/sysfs/file.c ++++ b/fs/sysfs/file.c +@@ -47,12 +47,13 @@ static int sysfs_kf_seq_show(struct seq_file *sf, void *v) + ssize_t count; + char *buf; + +- /* acquire buffer and ensure that it's >= PAGE_SIZE */ ++ /* acquire buffer and ensure that it's >= PAGE_SIZE and clear */ + count = seq_get_buf(sf, &buf); + if (count < PAGE_SIZE) { + seq_commit(sf, -1); + return 0; + } ++ memset(buf, 0, PAGE_SIZE); + + /* + * Invoke show(). Control may reach here via seq file lseek even diff --git a/fs/sysv/sysv.h b/fs/sysv/sysv.h index 69d4889..a810bd4 100644 --- a/fs/sysv/sysv.h @@ -65887,10 +65973,10 @@ index bcfe612..aa399c0 100644 diff --git a/grsecurity/Kconfig b/grsecurity/Kconfig new file mode 100644 -index 0000000..3abaf02 +index 0000000..a14eb52 --- /dev/null +++ b/grsecurity/Kconfig -@@ -0,0 +1,1161 @@ +@@ -0,0 +1,1174 @@ +# +# grecurity configuration +# @@ -66029,6 +66115,19 @@ index 0000000..3abaf02 + If you use PaX it is essential that you say Y here as it closes up + several holes that make full ASLR useless locally. + ++ ++config GRKERNSEC_KSTACKOVERFLOW ++ bool "Prevent kernel stack overflows" ++ default y if GRKERNSEC_CONFIG_AUTO ++ depends on !IA64 && 64BIT ++ help ++ If you say Y here, the kernel's process stacks will be allocated ++ with vmalloc instead of the kernel's default allocator. This ++ introduces guard pages that in combination with the alloca checking ++ of the STACKLEAK feature prevents all forms of kernel process stack ++ overflow abuse. Note that this is different from kernel stack ++ buffer overflows. ++ +config GRKERNSEC_BRUTE + bool "Deter exploit bruteforcing" + default y if GRKERNSEC_CONFIG_AUTO @@ -82007,7 +82106,7 @@ index b66c211..13d2915 100644 static inline void anon_vma_merge(struct vm_area_struct *vma, struct vm_area_struct *next) diff --git a/include/linux/sched.h b/include/linux/sched.h -index a781dec..be1d2a3 100644 +index a781dec..2c03225 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -129,6 +129,7 @@ struct fs_struct; @@ -82243,7 +82342,33 @@ index a781dec..be1d2a3 100644 { return tsk->pid; } -@@ -2112,7 +2223,9 @@ void yield(void); +@@ -1988,6 +2099,25 @@ extern u64 sched_clock_cpu(int cpu); + + extern void sched_clock_init(void); + ++#ifdef CONFIG_GRKERNSEC_KSTACKOVERFLOW ++static inline void populate_stack(void) ++{ ++ struct task_struct *curtask = current; ++ int c; ++ int *ptr = curtask->stack; ++ int *end = curtask->stack + THREAD_SIZE; ++ ++ while (ptr < end) { ++ c = *(volatile int *)ptr; ++ ptr += PAGE_SIZE/sizeof(int); ++ } ++} ++#else ++static inline void populate_stack(void) ++{ ++} ++#endif ++ + #ifndef CONFIG_HAVE_UNSTABLE_SCHED_CLOCK + static inline void sched_clock_tick(void) + { +@@ -2112,7 +2242,9 @@ void yield(void); extern struct exec_domain default_exec_domain; union thread_union { @@ -82253,7 +82378,7 @@ index a781dec..be1d2a3 100644 unsigned long stack[THREAD_SIZE/sizeof(long)]; }; -@@ -2145,6 +2258,7 @@ extern struct pid_namespace init_pid_ns; +@@ -2145,6 +2277,7 @@ extern struct pid_namespace init_pid_ns; */ extern struct task_struct *find_task_by_vpid(pid_t nr); @@ -82261,7 +82386,7 @@ index a781dec..be1d2a3 100644 extern struct task_struct *find_task_by_pid_ns(pid_t nr, struct pid_namespace *ns); -@@ -2307,7 +2421,7 @@ extern void __cleanup_sighand(struct sighand_struct *); +@@ -2307,7 +2440,7 @@ extern void __cleanup_sighand(struct sighand_struct *); extern void exit_itimers(struct signal_struct *); extern void flush_itimer_signals(void); @@ -82270,7 +82395,7 @@ index a781dec..be1d2a3 100644 extern int allow_signal(int); extern int disallow_signal(int); -@@ -2508,9 +2622,9 @@ static inline unsigned long *end_of_stack(struct task_struct *p) +@@ -2508,9 +2641,9 @@ static inline unsigned long *end_of_stack(struct task_struct *p) #endif @@ -83236,7 +83361,7 @@ index 502073a..a7de024 100644 #endif #endif /* _LINUX_VGA_SWITCHEROO_H_ */ diff --git a/include/linux/vmalloc.h b/include/linux/vmalloc.h -index 4b8a891..cb8df6e 100644 +index 4b8a891..05f2361 100644 --- a/include/linux/vmalloc.h +++ b/include/linux/vmalloc.h @@ -16,6 +16,11 @@ struct vm_area_struct; /* vma defining user mapping in mm_types.h */ @@ -83251,7 +83376,15 @@ index 4b8a891..cb8df6e 100644 /* bits [20..32] reserved for arch specific ioremap internals */ /* -@@ -142,7 +147,7 @@ extern void free_vm_area(struct vm_struct *area); +@@ -72,6 +77,7 @@ extern void *vzalloc_node(unsigned long size, int node); + extern void *vmalloc_exec(unsigned long size); + extern void *vmalloc_32(unsigned long size); + extern void *vmalloc_32_user(unsigned long size); ++extern void *vmalloc_stack(int node); + extern void *__vmalloc(unsigned long size, gfp_t gfp_mask, pgprot_t prot); + extern void *__vmalloc_node_range(unsigned long size, unsigned long align, + unsigned long start, unsigned long end, gfp_t gfp_mask, +@@ -142,7 +148,7 @@ extern void free_vm_area(struct vm_struct *area); /* for /dev/kmem */ extern long vread(char *buf, char *addr, unsigned long count); @@ -86352,10 +86485,49 @@ index 81b3d67..ef189a4 100644 { struct signal_struct *sig = current->signal; diff --git a/kernel/fork.c b/kernel/fork.c -index a17621c..b77fef8 100644 +index a17621c..d9e4b37 100644 --- a/kernel/fork.c +++ b/kernel/fork.c -@@ -319,7 +319,7 @@ static struct task_struct *dup_task_struct(struct task_struct *orig) +@@ -137,6 +137,18 @@ void __weak arch_release_thread_info(struct thread_info *ti) + { + } + ++#ifdef CONFIG_GRKERNSEC_KSTACKOVERFLOW ++static struct thread_info *alloc_thread_info_node(struct task_struct *tsk, ++ int node) ++{ ++ return vmalloc_stack(node); ++} ++ ++static inline void free_thread_info(struct thread_info *ti) ++{ ++ vfree(ti); ++} ++#else + #ifndef CONFIG_ARCH_THREAD_INFO_ALLOCATOR + + /* +@@ -179,6 +191,7 @@ void thread_info_cache_init(void) + } + # endif + #endif ++#endif + + /* SLAB cache for signal_struct structures (tsk->signal) */ + static struct kmem_cache *signal_cachep; +@@ -200,9 +213,11 @@ static struct kmem_cache *mm_cachep; + + static void account_kernel_stack(struct thread_info *ti, int account) + { ++#ifndef CONFIG_GRKERNSEC_KSTACKOVERFLOW + struct zone *zone = page_zone(virt_to_page(ti)); + + mod_zone_page_state(zone, NR_KERNEL_STACK, account); ++#endif + } + + void free_task(struct task_struct *tsk) +@@ -319,7 +334,7 @@ static struct task_struct *dup_task_struct(struct task_struct *orig) *stackend = STACK_END_MAGIC; /* for overflow detection */ #ifdef CONFIG_CC_STACKPROTECTOR @@ -86364,7 +86536,7 @@ index a17621c..b77fef8 100644 #endif /* -@@ -345,12 +345,80 @@ free_tsk: +@@ -345,12 +360,80 @@ free_tsk: } #ifdef CONFIG_MMU @@ -86447,7 +86619,7 @@ index a17621c..b77fef8 100644 uprobe_start_dup_mmap(); down_write(&oldmm->mmap_sem); -@@ -379,55 +447,15 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) +@@ -379,55 +462,15 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) prev = NULL; for (mpnt = oldmm->mmap; mpnt; mpnt = mpnt->vm_next) { @@ -86507,7 +86679,7 @@ index a17621c..b77fef8 100644 } /* -@@ -459,6 +487,31 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) +@@ -459,6 +502,31 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) if (retval) goto out; } @@ -86539,7 +86711,7 @@ index a17621c..b77fef8 100644 /* a new mm has just been created */ arch_dup_mmap(oldmm, mm); retval = 0; -@@ -468,14 +521,6 @@ out: +@@ -468,14 +536,6 @@ out: up_write(&oldmm->mmap_sem); uprobe_end_dup_mmap(); return retval; @@ -86554,7 +86726,7 @@ index a17621c..b77fef8 100644 } static inline int mm_alloc_pgd(struct mm_struct *mm) -@@ -689,8 +734,8 @@ struct mm_struct *mm_access(struct task_struct *task, unsigned int mode) +@@ -689,8 +749,8 @@ struct mm_struct *mm_access(struct task_struct *task, unsigned int mode) return ERR_PTR(err); mm = get_task_mm(task); @@ -86565,7 +86737,7 @@ index a17621c..b77fef8 100644 mmput(mm); mm = ERR_PTR(-EACCES); } -@@ -906,13 +951,20 @@ static int copy_fs(unsigned long clone_flags, struct task_struct *tsk) +@@ -906,13 +966,20 @@ static int copy_fs(unsigned long clone_flags, struct task_struct *tsk) spin_unlock(&fs->lock); return -EAGAIN; } @@ -86587,7 +86759,7 @@ index a17621c..b77fef8 100644 return 0; } -@@ -1130,7 +1182,7 @@ init_task_pid(struct task_struct *task, enum pid_type type, struct pid *pid) +@@ -1130,7 +1197,7 @@ init_task_pid(struct task_struct *task, enum pid_type type, struct pid *pid) * parts of the process environment (as per the clone * flags). The actual kick-off is left to the caller. */ @@ -86596,7 +86768,7 @@ index a17621c..b77fef8 100644 unsigned long stack_start, unsigned long stack_size, int __user *child_tidptr, -@@ -1202,6 +1254,9 @@ static struct task_struct *copy_process(unsigned long clone_flags, +@@ -1202,6 +1269,9 @@ static struct task_struct *copy_process(unsigned long clone_flags, DEBUG_LOCKS_WARN_ON(!p->softirqs_enabled); #endif retval = -EAGAIN; @@ -86606,7 +86778,7 @@ index a17621c..b77fef8 100644 if (atomic_read(&p->real_cred->user->processes) >= task_rlimit(p, RLIMIT_NPROC)) { if (p->real_cred->user != INIT_USER && -@@ -1449,6 +1504,11 @@ static struct task_struct *copy_process(unsigned long clone_flags, +@@ -1449,6 +1519,11 @@ static struct task_struct *copy_process(unsigned long clone_flags, goto bad_fork_free_pid; } @@ -86618,7 +86790,7 @@ index a17621c..b77fef8 100644 if (likely(p->pid)) { ptrace_init_task(p, (clone_flags & CLONE_PTRACE) || trace); -@@ -1537,6 +1597,8 @@ bad_fork_cleanup_count: +@@ -1537,6 +1612,8 @@ bad_fork_cleanup_count: bad_fork_free: free_task(p); fork_out: @@ -86627,7 +86799,7 @@ index a17621c..b77fef8 100644 return ERR_PTR(retval); } -@@ -1598,6 +1660,7 @@ long do_fork(unsigned long clone_flags, +@@ -1598,6 +1675,7 @@ long do_fork(unsigned long clone_flags, p = copy_process(clone_flags, stack_start, stack_size, child_tidptr, NULL, trace); @@ -86635,7 +86807,7 @@ index a17621c..b77fef8 100644 /* * Do this prior waking up the new thread - the thread pointer * might get invalid after that point, if the thread exits quickly. -@@ -1612,6 +1675,8 @@ long do_fork(unsigned long clone_flags, +@@ -1612,6 +1690,8 @@ long do_fork(unsigned long clone_flags, if (clone_flags & CLONE_PARENT_SETTID) put_user(nr, parent_tidptr); @@ -86644,7 +86816,7 @@ index a17621c..b77fef8 100644 if (clone_flags & CLONE_VFORK) { p->vfork_done = &vfork; init_completion(&vfork); -@@ -1728,7 +1793,7 @@ void __init proc_caches_init(void) +@@ -1728,7 +1808,7 @@ void __init proc_caches_init(void) mm_cachep = kmem_cache_create("mm_struct", sizeof(struct mm_struct), ARCH_MIN_MMSTRUCT_ALIGN, SLAB_HWCACHE_ALIGN|SLAB_PANIC|SLAB_NOTRACK, NULL); @@ -86653,7 +86825,7 @@ index a17621c..b77fef8 100644 mmap_init(); nsproxy_cache_init(); } -@@ -1768,7 +1833,7 @@ static int unshare_fs(unsigned long unshare_flags, struct fs_struct **new_fsp) +@@ -1768,7 +1848,7 @@ static int unshare_fs(unsigned long unshare_flags, struct fs_struct **new_fsp) return 0; /* don't need lock here; in the worst case we'll do useless copy */ @@ -86662,7 +86834,7 @@ index a17621c..b77fef8 100644 return 0; *new_fsp = copy_fs_struct(fs); -@@ -1875,7 +1940,8 @@ SYSCALL_DEFINE1(unshare, unsigned long, unshare_flags) +@@ -1875,7 +1955,8 @@ SYSCALL_DEFINE1(unshare, unsigned long, unshare_flags) fs = current->fs; spin_lock(&fs->lock); current->fs = new_fs; @@ -89740,7 +89912,7 @@ index a63f4dc..349bbb0 100644 unsigned long timeout) { diff --git a/kernel/sched/core.c b/kernel/sched/core.c -index f5c6635..ab9f223 100644 +index f5c6635..7133356 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c @@ -1775,7 +1775,7 @@ void set_numabalancing_state(bool enabled) @@ -89752,7 +89924,19 @@ index f5c6635..ab9f223 100644 int err; int state = numabalancing_enabled; -@@ -3049,6 +3049,8 @@ int can_nice(const struct task_struct *p, const int nice) +@@ -2251,8 +2251,10 @@ context_switch(struct rq *rq, struct task_struct *prev, + next->active_mm = oldmm; + atomic_inc(&oldmm->mm_count); + enter_lazy_tlb(oldmm, next); +- } else ++ } else { + switch_mm(oldmm, mm, next); ++ populate_stack(); ++ } + + if (!prev->mm) { + prev->active_mm = NULL; +@@ -3049,6 +3051,8 @@ int can_nice(const struct task_struct *p, const int nice) /* convert nice value [19,-20] to rlimit style value [1,40] */ int nice_rlim = 20 - nice; @@ -89761,7 +89945,7 @@ index f5c6635..ab9f223 100644 return (nice_rlim <= task_rlimit(p, RLIMIT_NICE) || capable(CAP_SYS_NICE)); } -@@ -3082,7 +3084,8 @@ SYSCALL_DEFINE1(nice, int, increment) +@@ -3082,7 +3086,8 @@ SYSCALL_DEFINE1(nice, int, increment) if (nice > 19) nice = 19; @@ -89771,7 +89955,7 @@ index f5c6635..ab9f223 100644 return -EPERM; retval = security_task_setnice(current, nice); -@@ -3332,6 +3335,7 @@ recheck: +@@ -3332,6 +3337,7 @@ recheck: if (policy != p->policy && !rlim_rtprio) return -EPERM; @@ -89779,7 +89963,19 @@ index f5c6635..ab9f223 100644 /* can't increase priority */ if (attr->sched_priority > p->rt_priority && attr->sched_priority > rlim_rtprio) -@@ -4781,7 +4785,7 @@ static void migrate_tasks(unsigned int dead_cpu) +@@ -4702,8 +4708,10 @@ void idle_task_exit(void) + + BUG_ON(cpu_online(smp_processor_id())); + +- if (mm != &init_mm) ++ if (mm != &init_mm) { + switch_mm(mm, &init_mm, current); ++ populate_stack(); ++ } + mmdrop(mm); + } + +@@ -4781,7 +4789,7 @@ static void migrate_tasks(unsigned int dead_cpu) #if defined(CONFIG_SCHED_DEBUG) && defined(CONFIG_SYSCTL) @@ -89788,7 +89984,7 @@ index f5c6635..ab9f223 100644 { .procname = "sched_domain", .mode = 0555, -@@ -4798,17 +4802,17 @@ static struct ctl_table sd_ctl_root[] = { +@@ -4798,17 +4806,17 @@ static struct ctl_table sd_ctl_root[] = { {} }; @@ -89810,7 +90006,7 @@ index f5c6635..ab9f223 100644 /* * In the intermediate directories, both the child directory and -@@ -4816,22 +4820,25 @@ static void sd_free_ctl_entry(struct ctl_table **tablep) +@@ -4816,22 +4824,25 @@ static void sd_free_ctl_entry(struct ctl_table **tablep) * will always be set. In the lowest directory the names are * static strings and all have proc handlers. */ @@ -89842,7 +90038,7 @@ index f5c6635..ab9f223 100644 const char *procname, void *data, int maxlen, umode_t mode, proc_handler *proc_handler, bool load_idx) -@@ -4851,7 +4858,7 @@ set_table_entry(struct ctl_table *entry, +@@ -4851,7 +4862,7 @@ set_table_entry(struct ctl_table *entry, static struct ctl_table * sd_alloc_ctl_domain_table(struct sched_domain *sd) { @@ -89851,7 +90047,7 @@ index f5c6635..ab9f223 100644 if (table == NULL) return NULL; -@@ -4886,9 +4893,9 @@ sd_alloc_ctl_domain_table(struct sched_domain *sd) +@@ -4886,9 +4897,9 @@ sd_alloc_ctl_domain_table(struct sched_domain *sd) return table; } @@ -89863,7 +90059,7 @@ index f5c6635..ab9f223 100644 struct sched_domain *sd; int domain_num = 0, i; char buf[32]; -@@ -4915,11 +4922,13 @@ static struct ctl_table_header *sd_sysctl_header; +@@ -4915,11 +4926,13 @@ static struct ctl_table_header *sd_sysctl_header; static void register_sched_domain_sysctl(void) { int i, cpu_num = num_possible_cpus(); @@ -89878,7 +90074,7 @@ index f5c6635..ab9f223 100644 if (entry == NULL) return; -@@ -4942,8 +4951,12 @@ static void unregister_sched_domain_sysctl(void) +@@ -4942,8 +4955,12 @@ static void unregister_sched_domain_sysctl(void) if (sd_sysctl_header) unregister_sysctl_table(sd_sysctl_header); sd_sysctl_header = NULL; @@ -92175,10 +92371,24 @@ index 09d9591..165bb75 100644 bdi_destroy(bdi); return err; diff --git a/mm/filemap.c b/mm/filemap.c -index 7a13f6a..e52e841 100644 +index 7a13f6a..e31738b 100644 --- a/mm/filemap.c +++ b/mm/filemap.c -@@ -1766,7 +1766,7 @@ int generic_file_mmap(struct file * file, struct vm_area_struct * vma) +@@ -192,9 +192,11 @@ static int filemap_check_errors(struct address_space *mapping) + { + int ret = 0; + /* Check for outstanding write errors */ +- if (test_and_clear_bit(AS_ENOSPC, &mapping->flags)) ++ if (test_bit(AS_ENOSPC, &mapping->flags) && ++ test_and_clear_bit(AS_ENOSPC, &mapping->flags)) + ret = -ENOSPC; +- if (test_and_clear_bit(AS_EIO, &mapping->flags)) ++ if (test_bit(AS_EIO, &mapping->flags) && ++ test_and_clear_bit(AS_EIO, &mapping->flags)) + ret = -EIO; + return ret; + } +@@ -1766,7 +1768,7 @@ int generic_file_mmap(struct file * file, struct vm_area_struct * vma) struct address_space *mapping = file->f_mapping; if (!mapping->a_ops->readpage) @@ -92187,7 +92397,7 @@ index 7a13f6a..e52e841 100644 file_accessed(file); vma->vm_ops = &generic_file_vm_ops; return 0; -@@ -1948,7 +1948,7 @@ static size_t __iovec_copy_from_user_inatomic(char *vaddr, +@@ -1948,7 +1950,7 @@ static size_t __iovec_copy_from_user_inatomic(char *vaddr, while (bytes) { char __user *buf = iov->iov_base + base; @@ -92196,7 +92406,7 @@ index 7a13f6a..e52e841 100644 base = 0; left = __copy_from_user_inatomic(vaddr, buf, copy); -@@ -1977,7 +1977,7 @@ size_t iov_iter_copy_from_user_atomic(struct page *page, +@@ -1977,7 +1979,7 @@ size_t iov_iter_copy_from_user_atomic(struct page *page, BUG_ON(!in_atomic()); kaddr = kmap_atomic(page); if (likely(i->nr_segs == 1)) { @@ -92205,7 +92415,7 @@ index 7a13f6a..e52e841 100644 char __user *buf = i->iov->iov_base + i->iov_offset; left = __copy_from_user_inatomic(kaddr + offset, buf, bytes); copied = bytes - left; -@@ -2005,7 +2005,7 @@ size_t iov_iter_copy_from_user(struct page *page, +@@ -2005,7 +2007,7 @@ size_t iov_iter_copy_from_user(struct page *page, kaddr = kmap(page); if (likely(i->nr_segs == 1)) { @@ -92214,7 +92424,7 @@ index 7a13f6a..e52e841 100644 char __user *buf = i->iov->iov_base + i->iov_offset; left = __copy_from_user(kaddr + offset, buf, bytes); copied = bytes - left; -@@ -2035,7 +2035,7 @@ void iov_iter_advance(struct iov_iter *i, size_t bytes) +@@ -2035,7 +2037,7 @@ void iov_iter_advance(struct iov_iter *i, size_t bytes) * zero-length segments (without overruning the iovec). */ while (bytes || unlikely(i->count && !iov->iov_len)) { @@ -92223,7 +92433,7 @@ index 7a13f6a..e52e841 100644 copy = min(bytes, iov->iov_len - base); BUG_ON(!i->count || i->count < copy); -@@ -2106,6 +2106,7 @@ inline int generic_write_checks(struct file *file, loff_t *pos, size_t *count, i +@@ -2106,6 +2108,7 @@ inline int generic_write_checks(struct file *file, loff_t *pos, size_t *count, i *pos = i_size_read(inode); if (limit != RLIM_INFINITY) { @@ -96333,7 +96543,7 @@ index 4bf8809..98a6914 100644 EXPORT_SYMBOL(kmem_cache_free); diff --git a/mm/slub.c b/mm/slub.c -index 25f14ad..ff4d0b7 100644 +index 25f14ad..c904f6f 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -207,7 +207,7 @@ struct track { @@ -96492,7 +96702,19 @@ index 25f14ad..ff4d0b7 100644 static int count_inuse(struct page *page) { return page->inuse; -@@ -4268,12 +4333,12 @@ static void resiliency_test(void) +@@ -4163,7 +4228,11 @@ static int list_locations(struct kmem_cache *s, char *buf, + len += sprintf(buf + len, "%7ld ", l->count); + + if (l->addr) ++#ifdef CONFIG_GRKERNSEC_HIDESYM ++ len += sprintf(buf + len, "%pS", NULL); ++#else + len += sprintf(buf + len, "%pS", (void *)l->addr); ++#endif + else + len += sprintf(buf + len, "<not-available>"); + +@@ -4268,12 +4337,12 @@ static void resiliency_test(void) validate_slab_cache(kmalloc_caches[9]); } #else @@ -96507,7 +96729,17 @@ index 25f14ad..ff4d0b7 100644 enum slab_stat_type { SL_ALL, /* All slabs */ SL_PARTIAL, /* Only partially allocated slabs */ -@@ -4519,7 +4584,7 @@ SLAB_ATTR_RO(ctor); +@@ -4513,13 +4582,17 @@ static ssize_t ctor_show(struct kmem_cache *s, char *buf) + { + if (!s->ctor) + return 0; ++#ifdef CONFIG_GRKERNSEC_HIDESYM ++ return sprintf(buf, "%pS\n", NULL); ++#else + return sprintf(buf, "%pS\n", s->ctor); ++#endif + } + SLAB_ATTR_RO(ctor); static ssize_t aliases_show(struct kmem_cache *s, char *buf) { @@ -96516,7 +96748,7 @@ index 25f14ad..ff4d0b7 100644 } SLAB_ATTR_RO(aliases); -@@ -4607,6 +4672,14 @@ static ssize_t cache_dma_show(struct kmem_cache *s, char *buf) +@@ -4607,6 +4680,14 @@ static ssize_t cache_dma_show(struct kmem_cache *s, char *buf) SLAB_ATTR_RO(cache_dma); #endif @@ -96531,7 +96763,7 @@ index 25f14ad..ff4d0b7 100644 static ssize_t destroy_by_rcu_show(struct kmem_cache *s, char *buf) { return sprintf(buf, "%d\n", !!(s->flags & SLAB_DESTROY_BY_RCU)); -@@ -4941,6 +5014,9 @@ static struct attribute *slab_attrs[] = { +@@ -4941,6 +5022,9 @@ static struct attribute *slab_attrs[] = { #ifdef CONFIG_ZONE_DMA &cache_dma_attr.attr, #endif @@ -96541,7 +96773,7 @@ index 25f14ad..ff4d0b7 100644 #ifdef CONFIG_NUMA &remote_node_defrag_ratio_attr.attr, #endif -@@ -5173,6 +5249,7 @@ static char *create_unique_id(struct kmem_cache *s) +@@ -5173,6 +5257,7 @@ static char *create_unique_id(struct kmem_cache *s) return name; } @@ -96549,7 +96781,7 @@ index 25f14ad..ff4d0b7 100644 static int sysfs_slab_add(struct kmem_cache *s) { int err; -@@ -5230,6 +5307,7 @@ static void sysfs_slab_remove(struct kmem_cache *s) +@@ -5230,6 +5315,7 @@ static void sysfs_slab_remove(struct kmem_cache *s) kobject_del(&s->kobj); kobject_put(&s->kobj); } @@ -96557,7 +96789,7 @@ index 25f14ad..ff4d0b7 100644 /* * Need to buffer aliases during bootup until sysfs becomes -@@ -5243,6 +5321,7 @@ struct saved_alias { +@@ -5243,6 +5329,7 @@ struct saved_alias { static struct saved_alias *alias_list; @@ -96565,7 +96797,7 @@ index 25f14ad..ff4d0b7 100644 static int sysfs_slab_alias(struct kmem_cache *s, const char *name) { struct saved_alias *al; -@@ -5265,6 +5344,7 @@ static int sysfs_slab_alias(struct kmem_cache *s, const char *name) +@@ -5265,6 +5352,7 @@ static int sysfs_slab_alias(struct kmem_cache *s, const char *name) alias_list = al; return 0; } @@ -96698,7 +96930,7 @@ index a24aa22..a0d41ae 100644 } #endif diff --git a/mm/vmalloc.c b/mm/vmalloc.c -index 0fdf968..d6686e8 100644 +index 0fdf968..2183ba3 100644 --- a/mm/vmalloc.c +++ b/mm/vmalloc.c @@ -59,8 +59,19 @@ static void vunmap_pte_range(pmd_t *pmd, unsigned long addr, unsigned long end) @@ -96844,7 +97076,20 @@ index 0fdf968..d6686e8 100644 area = __get_vm_area_node(size, align, VM_ALLOC | VM_UNINITIALIZED, start, end, node, gfp_mask, caller); if (!area) -@@ -1810,10 +1868,9 @@ EXPORT_SYMBOL(vzalloc_node); +@@ -1701,6 +1759,12 @@ static inline void *__vmalloc_node_flags(unsigned long size, + node, __builtin_return_address(0)); + } + ++void *vmalloc_stack(int node) ++{ ++ return __vmalloc_node(THREAD_SIZE, THREAD_SIZE, THREADINFO_GFP, PAGE_KERNEL, ++ node, __builtin_return_address(0)); ++} ++ + /** + * vmalloc - allocate virtually contiguous memory + * @size: allocation size +@@ -1810,10 +1874,9 @@ EXPORT_SYMBOL(vzalloc_node); * For tight control over page level allocator and protection flags * use __vmalloc() instead. */ @@ -96856,7 +97101,7 @@ index 0fdf968..d6686e8 100644 NUMA_NO_NODE, __builtin_return_address(0)); } -@@ -2120,6 +2177,8 @@ int remap_vmalloc_range_partial(struct vm_area_struct *vma, unsigned long uaddr, +@@ -2120,6 +2183,8 @@ int remap_vmalloc_range_partial(struct vm_area_struct *vma, unsigned long uaddr, { struct vm_struct *area; @@ -96865,7 +97110,7 @@ index 0fdf968..d6686e8 100644 size = PAGE_ALIGN(size); if (!PAGE_ALIGNED(uaddr) || !PAGE_ALIGNED(kaddr)) -@@ -2602,7 +2661,11 @@ static int s_show(struct seq_file *m, void *p) +@@ -2602,7 +2667,11 @@ static int s_show(struct seq_file *m, void *p) v->addr, v->addr + v->size, v->size); if (v->caller) @@ -106316,11 +106561,12 @@ index 7778b8e..3d619fc 100644 diff --git a/tools/gcc/.gitignore b/tools/gcc/.gitignore new file mode 100644 -index 0000000..de92ed9 +index 0000000..60e7af2 --- /dev/null +++ b/tools/gcc/.gitignore -@@ -0,0 +1 @@ +@@ -0,0 +1,2 @@ +randomize_layout_seed.h ++randomize_layout_hash.h diff --git a/tools/gcc/Makefile b/tools/gcc/Makefile new file mode 100644 index 0000000..7b8921f @@ -109866,7 +110112,7 @@ index 0000000..12b1e3b +exit 0 diff --git a/tools/gcc/size_overflow_plugin/insert_size_overflow_asm.c b/tools/gcc/size_overflow_plugin/insert_size_overflow_asm.c new file mode 100644 -index 0000000..f8ac5c6 +index 0000000..3e8148c --- /dev/null +++ b/tools/gcc/size_overflow_plugin/insert_size_overflow_asm.c @@ -0,0 +1,790 @@ @@ -110262,7 +110508,7 @@ index 0000000..f8ac5c6 + mark_str = convert_mark_to_str(mark); + asm_comment = create_asm_comment(argnum, stmt, mark_str); + -+ create_asm_stmt(asm_comment, build_string(2, "rm"), NULL, asm_data); ++ create_asm_stmt(asm_comment, build_string(3, "rm"), NULL, asm_data); + free(asm_comment); + asm_data->input = NULL_TREE; + break; @@ -110308,7 +110554,7 @@ index 0000000..f8ac5c6 + + mark_str = convert_mark_to_str(mark); + asm_comment = create_asm_comment(argnum, stmt, mark_str); -+ create_asm_stmt(asm_comment, build_string(1, "0"), build_string(3, "=rm"), &asm_data); ++ create_asm_stmt(asm_comment, build_string(2, "0"), build_string(4, "=rm"), &asm_data); + free(asm_comment); +} + @@ -110338,14 +110584,14 @@ index 0000000..f8ac5c6 + if (is_gimple_constant(asm_data.input)) + return false; + asm_data.output = NULL; -+ create_asm_stmt(asm_str, build_string(2, "rm"), NULL, &asm_data); ++ create_asm_stmt(asm_str, build_string(3, "rm"), NULL, &asm_data); + return true; + } + + create_asm_input(stmt, 0, &asm_data); + gcc_assert(asm_data.input != NULL_TREE); + -+ create_asm_stmt(asm_str, build_string(1, "0"), build_string(3, "=rm"), &asm_data); ++ create_asm_stmt(asm_str, build_string(2, "0"), build_string(4, "=rm"), &asm_data); + return true; +} + @@ -110662,10 +110908,10 @@ index 0000000..f8ac5c6 +} diff --git a/tools/gcc/size_overflow_plugin/insert_size_overflow_check_core.c b/tools/gcc/size_overflow_plugin/insert_size_overflow_check_core.c new file mode 100644 -index 0000000..0e36bd3 +index 0000000..88469e9 --- /dev/null +++ b/tools/gcc/size_overflow_plugin/insert_size_overflow_check_core.c -@@ -0,0 +1,889 @@ +@@ -0,0 +1,902 @@ +/* + * Copyright 2011-2014 by Emese Revfy <re.emese@gmail.com> + * Licensed under the GPL v2, or (at your option) v3 @@ -110715,7 +110961,7 @@ index 0000000..0e36bd3 + break; + case DImode: + if (LONG_TYPE_SIZE == GET_MODE_BITSIZE(SImode)) -+ new_type = TYPE_UNSIGNED(type) ? unsigned_intDI_type_node : size_overflow_type_DI; ++ new_type = TYPE_UNSIGNED(type) ? unsigned_intDI_type_node : intDI_type_node; + else + new_type = size_overflow_type_TI; + break; @@ -111353,8 +111599,13 @@ index 0000000..0e36bd3 + return create_assign(visited, def_stmt, lhs, AFTER_STMT); + + switch (TREE_CODE(rhs1)) { -+ case SSA_NAME: -+ return handle_unary_rhs(visited, caller_node, def_stmt); ++ case SSA_NAME: { ++ tree ret = handle_unary_rhs(visited, caller_node, def_stmt); ++ ++ if (gimple_assign_cast_p(stmt)) ++ unsigned_signed_cast_intentional_overflow(visited, stmt); ++ return ret; ++ } + case ARRAY_REF: + case BIT_FIELD_REF: + case ADDR_EXPR: @@ -111386,6 +111637,7 @@ index 0000000..0e36bd3 + +static tree handle_binary_ops(struct visited *visited, struct cgraph_node *caller_node, tree lhs) +{ ++ enum intentional_overflow_type res; + tree rhs1, rhs2, new_lhs; + gimple def_stmt = get_def_stmt(lhs); + tree new_rhs1 = NULL_TREE; @@ -111422,9 +111674,16 @@ index 0000000..0e36bd3 + if (TREE_CODE(rhs2) == SSA_NAME) + new_rhs2 = expand(visited, caller_node, rhs2); + ++ res = add_mul_intentional_overflow(def_stmt); ++ if (res != NO_INTENTIONAL_OVERFLOW) { ++ new_lhs = dup_assign(visited, def_stmt, lhs, new_rhs1, new_rhs2, NULL_TREE); ++ insert_cast_expr(visited, get_def_stmt(new_lhs), res); ++ return new_lhs; ++ } ++ + if (skip_expr_on_double_type(def_stmt)) { + new_lhs = dup_assign(visited, def_stmt, lhs, new_rhs1, new_rhs2, NULL_TREE); -+ insert_cast_expr(visited, get_def_stmt(new_lhs)); ++ insert_cast_expr(visited, get_def_stmt(new_lhs), NO_INTENTIONAL_OVERFLOW); + return new_lhs; + } + @@ -112696,10 +112955,10 @@ index 0000000..f8f5dd5 + diff --git a/tools/gcc/size_overflow_plugin/intentional_overflow.c b/tools/gcc/size_overflow_plugin/intentional_overflow.c new file mode 100644 -index 0000000..742cd52 +index 0000000..38904bc --- /dev/null +++ b/tools/gcc/size_overflow_plugin/intentional_overflow.c -@@ -0,0 +1,568 @@ +@@ -0,0 +1,733 @@ +/* + * Copyright 2011-2014 by Emese Revfy <re.emese@gmail.com> + * Licensed under the GPL v2, or (at your option) v3 @@ -112959,21 +113218,29 @@ index 0000000..742cd52 + return true; +} + -+static bool no_uses(tree node) ++static unsigned int uses_num(tree node) +{ + imm_use_iterator imm_iter; + use_operand_p use_p; ++ unsigned int num = 0; + + FOR_EACH_IMM_USE_FAST(use_p, imm_iter, node) { -+ const_gimple use_stmt = USE_STMT(use_p); ++ gimple use_stmt = USE_STMT(use_p); + + if (use_stmt == NULL) -+ return true; ++ return num; + if (is_gimple_debug(use_stmt)) + continue; -+ return false; ++ if (gimple_assign_cast_p(use_stmt) && is_size_overflow_type(gimple_assign_lhs(use_stmt))) ++ continue; ++ num++; + } -+ return true; ++ return num; ++} ++ ++static bool no_uses(tree node) ++{ ++ return !uses_num(node); +} + +// 3.8.5 mm/page-writeback.c __ilog2_u64(): ret, uint + uintmax; uint -> int; int max @@ -113268,12 +113535,169 @@ index 0000000..742cd52 + return true; +} + ++/* e.g., drivers/acpi/acpica/utids.c acpi_ut_execute_CID() ++ * ((count - 1) * sizeof(struct acpi_pnp_dee_id_list) -> (count + fffffff) * 16 ++ * fffffff * 16 > signed max -> truncate ++ */ ++static bool look_for_mult_and_add(const_gimple stmt) ++{ ++ const_tree res; ++ tree rhs1, rhs2, def_rhs1, def_rhs2, const_rhs, def_const_rhs; ++ const_gimple def_stmt; ++ ++ if (!stmt || gimple_code(stmt) == GIMPLE_NOP) ++ return false; ++ if (!is_gimple_assign(stmt)) ++ return false; ++ if (gimple_assign_rhs_code(stmt) != MULT_EXPR) ++ return false; ++ ++ rhs1 = gimple_assign_rhs1(stmt); ++ rhs2 = gimple_assign_rhs2(stmt); ++ if (is_gimple_constant(rhs1)) { ++ const_rhs = rhs1; ++ def_stmt = get_def_stmt(rhs2); ++ } else if (is_gimple_constant(rhs2)) { ++ const_rhs = rhs2; ++ def_stmt = get_def_stmt(rhs1); ++ } else ++ return false; ++ ++ if (gimple_assign_rhs_code(def_stmt) != PLUS_EXPR && gimple_assign_rhs_code(def_stmt) != MINUS_EXPR) ++ return false; ++ ++ def_rhs1 = gimple_assign_rhs1(def_stmt); ++ def_rhs2 = gimple_assign_rhs2(def_stmt); ++ if (is_gimple_constant(def_rhs1)) ++ def_const_rhs = def_rhs1; ++ else if (is_gimple_constant(def_rhs2)) ++ def_const_rhs = def_rhs2; ++ else ++ return false; ++ ++ res = fold_binary_loc(gimple_location(def_stmt), MULT_EXPR, TREE_TYPE(const_rhs), const_rhs, def_const_rhs); ++ if (is_lt_signed_type_max(res) && is_gt_zero(res)) ++ return false; ++ return true; ++} ++ ++enum intentional_overflow_type add_mul_intentional_overflow(const_gimple stmt) ++{ ++ const_gimple def_stmt_1, def_stmt_2; ++ const_tree rhs1, rhs2; ++ bool add_mul_rhs1, add_mul_rhs2; ++ ++ rhs1 = gimple_assign_rhs1(stmt); ++ def_stmt_1 = get_def_stmt(rhs1); ++ add_mul_rhs1 = look_for_mult_and_add(def_stmt_1); ++ ++ rhs2 = gimple_assign_rhs2(stmt); ++ def_stmt_2 = get_def_stmt(rhs2); ++ add_mul_rhs2 = look_for_mult_and_add(def_stmt_2); ++ ++ if (add_mul_rhs1) ++ return RHS1_INTENTIONAL_OVERFLOW; ++ if (add_mul_rhs2) ++ return RHS2_INTENTIONAL_OVERFLOW; ++ return NO_INTENTIONAL_OVERFLOW; ++} ++ ++static gimple get_dup_stmt(struct visited *visited, gimple stmt) ++{ ++ gimple my_stmt; ++ gimple_stmt_iterator gsi = gsi_for_stmt(stmt); ++ ++ gsi_next(&gsi); ++ my_stmt = gsi_stmt(gsi); ++ ++ gcc_assert(pointer_set_contains(visited->my_stmts, my_stmt)); ++ gcc_assert(gimple_assign_rhs_code(stmt) == gimple_assign_rhs_code(my_stmt)); ++ ++ return my_stmt; ++} ++ ++/* unsigned type -> unary or binary assign (rhs1 or rhs2 is constant) ++ * unsigned type cast to signed type, unsigned type: no more uses ++ * e.g., lib/vsprintf.c:simple_strtol() ++ * _10 = (unsigned long int) _9 ++ * _11 = -_10; ++ * _12 = (long int) _11; (_11_ no more uses) ++ */ ++static bool is_call_or_cast(gimple stmt) ++{ ++ return gimple_assign_cast_p(stmt) || is_gimple_call(stmt); ++} ++ ++static bool is_unsigned_cast_or_call_def_stmt(const_tree node) ++{ ++ const_tree rhs; ++ gimple def_stmt; ++ ++ if (node == NULL_TREE) ++ return true; ++ if (is_gimple_constant(node)) ++ return true; ++ ++ def_stmt = get_def_stmt(node); ++ if (!def_stmt) ++ return false; ++ ++ if (is_call_or_cast(def_stmt)) ++ return true; ++ ++ if (!is_gimple_assign(def_stmt) || gimple_num_ops(def_stmt) != 2) ++ return false; ++ rhs = gimple_assign_rhs1(def_stmt); ++ def_stmt = get_def_stmt(rhs); ++ if (!def_stmt) ++ return false; ++ return is_call_or_cast(def_stmt); ++} ++ ++void unsigned_signed_cast_intentional_overflow(struct visited *visited, gimple stmt) ++{ ++ unsigned int use_num; ++ gimple so_stmt; ++ const_gimple def_stmt; ++ const_tree rhs1, rhs2; ++ tree rhs = gimple_assign_rhs1(stmt); ++ tree lhs_type = TREE_TYPE(gimple_assign_lhs(stmt)); ++ const_tree rhs_type = TREE_TYPE(rhs); ++ ++ if (!(TYPE_UNSIGNED(rhs_type) && !TYPE_UNSIGNED(lhs_type))) ++ return; ++ if (GET_MODE_BITSIZE(TYPE_MODE(rhs_type)) != GET_MODE_BITSIZE(TYPE_MODE(lhs_type))) ++ return; ++ use_num = uses_num(rhs); ++ if (use_num != 1) ++ return; ++ ++ def_stmt = get_def_stmt(rhs); ++ if (!def_stmt) ++ return; ++ if (!is_gimple_assign(def_stmt)) ++ return; ++ ++ rhs1 = gimple_assign_rhs1(def_stmt); ++ if (!is_unsigned_cast_or_call_def_stmt(rhs1)) ++ return; ++ ++ rhs2 = gimple_assign_rhs2(def_stmt); ++ if (!is_unsigned_cast_or_call_def_stmt(rhs2)) ++ return; ++ if (gimple_num_ops(def_stmt) == 3 && !is_gimple_constant(rhs1) && !is_gimple_constant(rhs2)) ++ return; ++ ++ so_stmt = get_dup_stmt(visited, stmt); ++ create_up_and_down_cast(visited, so_stmt, lhs_type, gimple_assign_rhs1(so_stmt)); ++} ++ diff --git a/tools/gcc/size_overflow_plugin/misc.c b/tools/gcc/size_overflow_plugin/misc.c new file mode 100644 -index 0000000..ca4def3 +index 0000000..4bddad2 --- /dev/null +++ b/tools/gcc/size_overflow_plugin/misc.c -@@ -0,0 +1,180 @@ +@@ -0,0 +1,203 @@ +/* + * Copyright 2011-2014 by Emese Revfy <re.emese@gmail.com> + * Licensed under the GPL v2, or (at your option) v3 @@ -113454,12 +113878,35 @@ index 0000000..ca4def3 + return assign; +} + ++bool is_size_overflow_type(const_tree var) ++{ ++ const char *name; ++ const_tree type_name, type; ++ ++ if (var == NULL_TREE) ++ return false; ++ ++ type = TREE_TYPE(var); ++ type_name = TYPE_NAME(type); ++ if (type_name == NULL_TREE) ++ return false; ++ ++ if (DECL_P(type_name)) ++ name = DECL_NAME_POINTER(type_name); ++ else ++ name = IDENTIFIER_POINTER(type_name); ++ ++ if (!strncmp(name, "size_overflow_type", 18)) ++ return true; ++ return false; ++} ++ diff --git a/tools/gcc/size_overflow_plugin/remove_unnecessary_dup.c b/tools/gcc/size_overflow_plugin/remove_unnecessary_dup.c new file mode 100644 -index 0000000..10cb20e +index 0000000..7c9e6d1 --- /dev/null +++ b/tools/gcc/size_overflow_plugin/remove_unnecessary_dup.c -@@ -0,0 +1,151 @@ +@@ -0,0 +1,138 @@ +/* + * Copyright 2011-2014 by Emese Revfy <re.emese@gmail.com> + * Licensed under the GPL v2, or (at your option) v3 @@ -113504,30 +113951,7 @@ index 0000000..10cb20e + } +} + -+static bool is_size_overflow_type(const_tree var) -+{ -+ const char *name; -+ const_tree type_name, type; -+ -+ if (var == NULL_TREE) -+ return false; -+ -+ type = TREE_TYPE(var); -+ type_name = TYPE_NAME(type); -+ if (type_name == NULL_TREE) -+ return false; -+ -+ if (DECL_P(type_name)) -+ name = DECL_NAME_POINTER(type_name); -+ else -+ name = IDENTIFIER_POINTER(type_name); -+ -+ if (!strncmp(name, "size_overflow_type", 18)) -+ return true; -+ return false; -+} -+ -+static void create_up_and_down_cast(struct visited *visited, gimple use_stmt, tree orig_type, tree rhs) ++void create_up_and_down_cast(struct visited *visited, gimple use_stmt, tree orig_type, tree rhs) +{ + const_tree orig_rhs1; + tree down_lhs, new_lhs, dup_type = TREE_TYPE(rhs); @@ -113598,25 +114022,35 @@ index 0000000..10cb20e + create_up_and_down_cast(visited, stmt, type, rhs); +} + -+void insert_cast_expr(struct visited *visited, gimple stmt) ++static void insert_cast(struct visited *visited, gimple stmt, tree rhs) +{ -+ tree rhs1, rhs2; ++ if (LONG_TYPE_SIZE == GET_MODE_BITSIZE(SImode) && !is_size_overflow_type(rhs)) ++ return; ++ gcc_assert(is_size_overflow_type(rhs)); ++ insert_cast_rhs(visited, stmt, rhs); ++} + -+ gcc_assert(skip_expr_on_double_type(stmt)); ++void insert_cast_expr(struct visited *visited, gimple stmt, enum intentional_overflow_type type) ++{ ++ tree rhs1, rhs2; + -+ rhs1 = gimple_assign_rhs1(stmt); -+ insert_cast_rhs(visited, stmt, rhs1); ++ if (type == NO_INTENTIONAL_OVERFLOW || type == RHS1_INTENTIONAL_OVERFLOW) { ++ rhs1 = gimple_assign_rhs1(stmt); ++ insert_cast(visited, stmt, rhs1); ++ } + -+ rhs2 = gimple_assign_rhs2(stmt); -+ insert_cast_rhs(visited, stmt, rhs2); ++ if (type == NO_INTENTIONAL_OVERFLOW || type == RHS2_INTENTIONAL_OVERFLOW) { ++ rhs2 = gimple_assign_rhs2(stmt); ++ insert_cast(visited, stmt, rhs2); ++ } +} + diff --git a/tools/gcc/size_overflow_plugin/size_overflow.h b/tools/gcc/size_overflow_plugin/size_overflow.h new file mode 100644 -index 0000000..040f0f6 +index 0000000..e5b4e50 --- /dev/null +++ b/tools/gcc/size_overflow_plugin/size_overflow.h -@@ -0,0 +1,119 @@ +@@ -0,0 +1,127 @@ +#ifndef SIZE_OVERFLOW_H +#define SIZE_OVERFLOW_H + @@ -113634,6 +114068,10 @@ index 0000000..040f0f6 + MARK_NO, MARK_YES, MARK_NOT_INTENTIONAL, MARK_TURN_OFF +}; + ++enum intentional_overflow_type { ++ NO_INTENTIONAL_OVERFLOW, RHS1_INTENTIONAL_OVERFLOW, RHS2_INTENTIONAL_OVERFLOW ++}; ++ +struct visited { + struct pointer_set_t *stmts; + struct pointer_set_t *my_stmts; @@ -113700,6 +114138,8 @@ index 0000000..040f0f6 +extern tree handle_intentional_overflow(struct visited *visited, struct cgraph_node *caller_node, bool check_overflow, gimple stmt, tree change_rhs, tree new_rhs2); +extern tree handle_integer_truncation(struct visited *visited, struct cgraph_node *caller_node, const_tree lhs); +extern bool is_a_neg_overflow(const_gimple stmt, const_tree rhs); ++extern enum intentional_overflow_type add_mul_intentional_overflow(const_gimple def_stmt); ++extern void unsigned_signed_cast_intentional_overflow(struct visited *visited, gimple stmt); + + +// insert_size_overflow_check_ipa.c @@ -113721,6 +114161,7 @@ index 0000000..040f0f6 +extern gimple build_cast_stmt(struct visited *visited, tree dst_type, tree rhs, tree lhs, gimple_stmt_iterator *gsi, bool before, bool force); +extern bool skip_types(const_tree var); +extern tree cast_a_tree(tree type, tree var); ++extern bool is_size_overflow_type(const_tree var); + + +// insert_size_overflow_check_core.c @@ -113732,8 +114173,9 @@ index 0000000..040f0f6 + +// remove_unnecessary_dup.c +extern struct opt_pass *make_remove_unnecessary_dup_pass(void); -+extern void insert_cast_expr(struct visited *visited, gimple stmt); ++extern void insert_cast_expr(struct visited *visited, gimple stmt, enum intentional_overflow_type type); +extern bool skip_expr_on_double_type(const_gimple stmt); ++extern void create_up_and_down_cast(struct visited *visited, gimple use_stmt, tree orig_type, tree rhs); + +#endif diff --git a/tools/gcc/size_overflow_plugin/size_overflow_debug.c b/tools/gcc/size_overflow_plugin/size_overflow_debug.c @@ -113860,10 +114302,10 @@ index 0000000..4378111 +} diff --git a/tools/gcc/size_overflow_plugin/size_overflow_hash.data b/tools/gcc/size_overflow_plugin/size_overflow_hash.data new file mode 100644 -index 0000000..41777a8 +index 0000000..72e9c0e --- /dev/null +++ b/tools/gcc/size_overflow_plugin/size_overflow_hash.data -@@ -0,0 +1,5934 @@ +@@ -0,0 +1,5986 @@ +intel_fake_agp_alloc_by_type_1 intel_fake_agp_alloc_by_type 1 1 NULL +ocfs2_get_refcount_tree_3 ocfs2_get_refcount_tree 0 3 NULL +storvsc_connect_to_vsp_22 storvsc_connect_to_vsp 2 22 NULL @@ -113907,6 +114349,7 @@ index 0000000..41777a8 +zlib_deflate_workspacesize_537 zlib_deflate_workspacesize 0-1-2 537 NULL +iwl_dbgfs_wowlan_sram_read_540 iwl_dbgfs_wowlan_sram_read 3 540 NULL +sco_sock_setsockopt_552 sco_sock_setsockopt 5 552 NULL ++lpfc_nlp_state_name_556 lpfc_nlp_state_name 2 556 NULL +snd_aw2_saa7146_get_hw_ptr_playback_558 snd_aw2_saa7146_get_hw_ptr_playback 0 558 NULL +start_isoc_chain_565 start_isoc_chain 2 565 NULL nohasharray +dev_hard_header_565 dev_hard_header 0 565 &start_isoc_chain_565 @@ -113922,7 +114365,7 @@ index 0000000..41777a8 +unlink_queued_645 unlink_queued 4 645 NULL +dtim_interval_read_654 dtim_interval_read 3 654 NULL +mem_rx_free_mem_blks_read_675 mem_rx_free_mem_blks_read 3 675 NULL -+persistent_ram_vmap_709 persistent_ram_vmap 2-1 709 NULL ++persistent_ram_vmap_709 persistent_ram_vmap 1-2 709 NULL +xfs_bmap_eof_728 xfs_bmap_eof 0 728 NULL +sctp_setsockopt_peer_addr_params_734 sctp_setsockopt_peer_addr_params 3 734 NULL +dvb_video_write_754 dvb_video_write 3 754 NULL @@ -113936,6 +114379,7 @@ index 0000000..41777a8 +snd_pcm_action_single_905 snd_pcm_action_single 0 905 NULL +carl9170_cmd_buf_950 carl9170_cmd_buf 3 950 NULL +__nodes_weight_956 __nodes_weight 2-0 956 NULL ++bnx2x_fill_fw_str_968 bnx2x_fill_fw_str 3 968 NULL +mnt_want_write_975 mnt_want_write 0 975 NULL +usnic_ib_qp_grp_dump_hdr_989 usnic_ib_qp_grp_dump_hdr 2 989 NULL +memcmp_990 memcmp 0 990 NULL @@ -113990,6 +114434,7 @@ index 0000000..41777a8 +ath6kl_init_get_fwcaps_1557 ath6kl_init_get_fwcaps 3 1557 NULL +ffs_mutex_lock_1564 ffs_mutex_lock 0 1564 NULL +ieee80211_if_read_dot11MeshHWMPnetDiameterTraversalTime_1589 ieee80211_if_read_dot11MeshHWMPnetDiameterTraversalTime 3 1589 NULL ++ipath_ht_handle_hwerrors_1592 ipath_ht_handle_hwerrors 3 1592 NULL +packet_buffer_init_1607 packet_buffer_init 2 1607 NULL +btmrvl_hscmd_read_1614 btmrvl_hscmd_read 3 1614 NULL +v9fs_fid_xattr_get_1618 v9fs_fid_xattr_get 0 1618 NULL @@ -114312,6 +114757,7 @@ index 0000000..41777a8 +blk_rq_sectors_5091 blk_rq_sectors 0 5091 &get_random_bytes_5091 +sound_write_5102 sound_write 3 5102 NULL +i40e_dbg_netdev_ops_write_5117 i40e_dbg_netdev_ops_write 3 5117 NULL ++qib_7220_handle_hwerrors_5142 qib_7220_handle_hwerrors 3 5142 NULL +__uwb_addr_print_5161 __uwb_addr_print 2 5161 NULL +iwl_dbgfs_status_read_5171 iwl_dbgfs_status_read 3 5171 NULL +acpi_pcc_get_sqty_5176 acpi_pcc_get_sqty 0 5176 NULL @@ -114472,6 +114918,7 @@ index 0000000..41777a8 +beacon_interval_read_7091 beacon_interval_read 3 7091 NULL +pipeline_enc_rx_stat_fifo_int_read_7107 pipeline_enc_rx_stat_fifo_int_read 3 7107 NULL +osc_resend_count_seq_write_7120 osc_resend_count_seq_write 3 7120 NULL ++qib_format_hwerrors_7133 qib_format_hwerrors 5 7133 NULL +kvm_mmu_notifier_test_young_7139 kvm_mmu_notifier_test_young 3 7139 NULL +__alloc_objio_seg_7203 __alloc_objio_seg 1 7203 NULL +hdlc_loop_7255 hdlc_loop 0 7255 NULL @@ -114690,6 +115137,7 @@ index 0000000..41777a8 +crypt_status_9492 crypt_status 5 9492 NULL +lbs_threshold_write_9502 lbs_threshold_write 5 9502 NULL +lp_write_9511 lp_write 3 9511 NULL ++mext_calc_swap_extents_9517 mext_calc_swap_extents 4 9517 NULL +scsi_tgt_kspace_exec_9522 scsi_tgt_kspace_exec 8 9522 NULL +ll_max_read_ahead_whole_mb_seq_write_9528 ll_max_read_ahead_whole_mb_seq_write 3 9528 NULL +read_file_dma_9530 read_file_dma 3 9530 NULL @@ -114740,6 +115188,7 @@ index 0000000..41777a8 +bm_register_write_9893 bm_register_write 3 9893 &snd_midi_event_new_9893 +snd_gf1_pcm_playback_copy_9895 snd_gf1_pcm_playback_copy 5-3 9895 NULL +nonpaging_page_fault_9908 nonpaging_page_fault 2 9908 NULL ++root_nfs_parse_options_9937 root_nfs_parse_options 3 9937 NULL +pstore_ftrace_knob_read_9947 pstore_ftrace_knob_read 3 9947 NULL +read_file_misc_9948 read_file_misc 3 9948 NULL +csum_partial_copy_fromiovecend_9957 csum_partial_copy_fromiovecend 3-4 9957 NULL @@ -114843,8 +115292,8 @@ index 0000000..41777a8 +kvm_write_guest_cached_11106 kvm_write_guest_cached 4 11106 NULL +tw_change_queue_depth_11116 tw_change_queue_depth 2 11116 NULL +page_offset_11120 page_offset 0 11120 NULL -+tracing_buffers_read_11124 tracing_buffers_read 3 11124 NULL nohasharray -+cea_db_payload_len_11124 cea_db_payload_len 0 11124 &tracing_buffers_read_11124 ++cea_db_payload_len_11124 cea_db_payload_len 0 11124 NULL nohasharray ++tracing_buffers_read_11124 tracing_buffers_read 3 11124 &cea_db_payload_len_11124 +snd_gf1_pcm_playback_silence_11172 snd_gf1_pcm_playback_silence 4-3 11172 NULL +il_dbgfs_rx_queue_read_11221 il_dbgfs_rx_queue_read 3 11221 NULL +comedi_alloc_spriv_11234 comedi_alloc_spriv 2 11234 NULL @@ -114859,7 +115308,7 @@ index 0000000..41777a8 +construct_key_11329 construct_key 3 11329 NULL nohasharray +__kfifo_out_peek_11329 __kfifo_out_peek 0-3 11329 &construct_key_11329 +next_segment_11330 next_segment 0-2-1 11330 NULL -+persistent_ram_buffer_map_11332 persistent_ram_buffer_map 1-2 11332 NULL ++persistent_ram_buffer_map_11332 persistent_ram_buffer_map 2-1 11332 NULL +ext4_get_inline_size_11349 ext4_get_inline_size 0 11349 NULL +sel_write_create_11353 sel_write_create 3 11353 NULL nohasharray +nl80211_send_mgmt_11353 nl80211_send_mgmt 7 11353 &sel_write_create_11353 @@ -115084,6 +115533,7 @@ index 0000000..41777a8 +packet_snd_13634 packet_snd 3 13634 NULL +blk_msg_write_13655 blk_msg_write 3 13655 NULL +cache_downcall_13666 cache_downcall 3 13666 NULL ++ext3_xattr_list_entries_13682 ext3_xattr_list_entries 0 13682 NULL +usb_get_string_13693 usb_get_string 0 13693 NULL +fw_iso_buffer_alloc_13704 fw_iso_buffer_alloc 2 13704 NULL +audit_unpack_string_13748 audit_unpack_string 3 13748 NULL @@ -115156,6 +115606,7 @@ index 0000000..41777a8 +ath6kl_regdump_read_14393 ath6kl_regdump_read 3 14393 NULL +smk_write_onlycap_14400 smk_write_onlycap 3 14400 NULL +mtd_concat_create_14416 mtd_concat_create 2 14416 NULL ++get_kcore_size_14425 get_kcore_size 0 14425 NULL +_iwl_dbgfs_sram_write_14439 _iwl_dbgfs_sram_write 3 14439 NULL +block_size_14443 block_size 0 14443 NULL +lmv_user_md_size_14456 lmv_user_md_size 0-1 14456 NULL @@ -115187,6 +115638,7 @@ index 0000000..41777a8 +persistent_ram_ecc_string_14704 persistent_ram_ecc_string 0 14704 NULL +u_audio_playback_14709 u_audio_playback 3 14709 NULL +rtw_cbuf_alloc_14710 rtw_cbuf_alloc 1 14710 NULL ++cgroup_path_14713 cgroup_path 3 14713 NULL +vfd_write_14717 vfd_write 3 14717 NULL +__blk_end_request_14729 __blk_end_request 3 14729 NULL +raid1_resize_14740 raid1_resize 2 14740 NULL @@ -115200,6 +115652,7 @@ index 0000000..41777a8 +__kfifo_in_14797 __kfifo_in 3-0 14797 NULL +hpet_readl_14801 hpet_readl 0 14801 NULL nohasharray +snd_als300_gcr_read_14801 snd_als300_gcr_read 0 14801 &hpet_readl_14801 ++security_inode_rename_14805 security_inode_rename 0 14805 NULL +xfs_btree_kill_iroot_14824 xfs_btree_kill_iroot 0 14824 NULL +mrp_attr_create_14853 mrp_attr_create 3 14853 NULL +lcd_write_14857 lcd_write 3 14857 NULL @@ -115468,6 +115921,7 @@ index 0000000..41777a8 +gnttab_max_grant_frames_17993 gnttab_max_grant_frames 0 17993 NULL +pvr2_v4l2_read_18006 pvr2_v4l2_read 3 18006 NULL +alloc_rx_desc_ring_18016 alloc_rx_desc_ring 2 18016 NULL ++cpufreq_add_dev_symlink_18028 cpufreq_add_dev_symlink 0 18028 NULL +o2hb_highest_node_18034 o2hb_highest_node 0 18034 NULL +cryptd_alloc_instance_18048 cryptd_alloc_instance 2-3 18048 NULL +__btrfs_drop_extents_18049 __btrfs_drop_extents 5 18049 NULL @@ -115657,22 +116111,25 @@ index 0000000..41777a8 +iwl_dbgfs_rx_queue_read_19943 iwl_dbgfs_rx_queue_read 3 19943 NULL +cfg80211_rx_assoc_resp_19944 cfg80211_rx_assoc_resp 4 19944 NULL +ll_xattr_cache_list_19954 ll_xattr_cache_list 0 19954 NULL ++get_jack_mode_name_19976 get_jack_mode_name 4 19976 NULL +attach_hdlc_protocol_19986 attach_hdlc_protocol 3 19986 NULL +rtw_set_wps_probe_resp_19989 rtw_set_wps_probe_resp 3 19989 NULL +diva_um_idi_read_20003 diva_um_idi_read 0 20003 NULL -+event_trigger_write_20009 event_trigger_write 3 20009 NULL nohasharray -+lov_stripe_md_size_20009 lov_stripe_md_size 0-1 20009 &event_trigger_write_20009 ++lov_stripe_md_size_20009 lov_stripe_md_size 0-1 20009 NULL nohasharray ++event_trigger_write_20009 event_trigger_write 3 20009 &lov_stripe_md_size_20009 +tree_mod_log_eb_move_20011 tree_mod_log_eb_move 5 20011 NULL +SYSC_fgetxattr_20027 SYSC_fgetxattr 4 20027 NULL +split_scan_timeout_read_20029 split_scan_timeout_read 3 20029 NULL +alloc_ieee80211_20063 alloc_ieee80211 1 20063 NULL +iwl_mvm_power_mac_dbgfs_read_20067 iwl_mvm_power_mac_dbgfs_read 4 20067 NULL ++target_message_20072 target_message 2 20072 NULL +rawv6_sendmsg_20080 rawv6_sendmsg 4 20080 NULL +fuse_conn_limit_read_20084 fuse_conn_limit_read 3 20084 NULL +aat2870_reg_write_file_20086 aat2870_reg_write_file 3 20086 NULL +team_options_register_20091 team_options_register 3 20091 NULL +qla2x00_adjust_sdev_qdepth_up_20097 qla2x00_adjust_sdev_qdepth_up 2 20097 NULL +xfs_qm_dqget_20103 xfs_qm_dqget 0 20103 NULL ++root_nfs_copy_20111 root_nfs_copy 3 20111 NULL +hptiop_adjust_disk_queue_depth_20122 hptiop_adjust_disk_queue_depth 2 20122 NULL +tomoyo_commit_ok_20167 tomoyo_commit_ok 2 20167 NULL +read_flush_pipefs_20171 read_flush_pipefs 3 20171 NULL @@ -115743,6 +116200,7 @@ index 0000000..41777a8 +uvc_alloc_entity_20836 uvc_alloc_entity 4-3 20836 NULL +p9_tag_alloc_20845 p9_tag_alloc 3 20845 NULL +nvme_trans_supported_vpd_pages_20847 nvme_trans_supported_vpd_pages 4 20847 NULL ++get_name_20855 get_name 4 20855 NULL +iwl_dbgfs_pm_params_read_20866 iwl_dbgfs_pm_params_read 3 20866 NULL +snd_pcm_capture_avail_20867 snd_pcm_capture_avail 0 20867 NULL +srq_free_res_20868 srq_free_res 5 20868 NULL @@ -115768,6 +116226,7 @@ index 0000000..41777a8 +lbs_threshold_read_21046 lbs_threshold_read 5 21046 NULL +reiserfs_direct_IO_21051 reiserfs_direct_IO 4 21051 NULL +proc_fault_inject_write_21058 proc_fault_inject_write 3 21058 NULL ++qdisc_get_default_21072 qdisc_get_default 2 21072 NULL +event_calibration_read_21083 event_calibration_read 3 21083 NULL +bl_add_page_to_bio_21094 bl_add_page_to_bio 2 21094 NULL nohasharray +multipath_status_21094 multipath_status 5 21094 &bl_add_page_to_bio_21094 @@ -116024,8 +116483,8 @@ index 0000000..41777a8 +bin_to_hex_dup_23853 bin_to_hex_dup 2 23853 NULL +ocfs2_xattr_get_clusters_23857 ocfs2_xattr_get_clusters 0 23857 NULL +ieee80211_if_read_dot11MeshMaxPeerLinks_23878 ieee80211_if_read_dot11MeshMaxPeerLinks 3 23878 NULL -+writeback_single_inode_23881 writeback_single_inode 0 23881 NULL nohasharray -+nouveau_clock_create__23881 nouveau_clock_create_ 5 23881 &writeback_single_inode_23881 ++nouveau_clock_create__23881 nouveau_clock_create_ 5 23881 NULL nohasharray ++writeback_single_inode_23881 writeback_single_inode 0 23881 &nouveau_clock_create__23881 +tipc_snprintf_23893 tipc_snprintf 2-0 23893 NULL +add_new_gdb_meta_bg_23911 add_new_gdb_meta_bg 3 23911 NULL nohasharray +ieee80211_if_read_hw_queues_23911 ieee80211_if_read_hw_queues 3 23911 &add_new_gdb_meta_bg_23911 @@ -116135,8 +116594,8 @@ index 0000000..41777a8 +__vxge_hw_vp_initialize_24885 __vxge_hw_vp_initialize 2 24885 NULL +xfs_qm_dqattach_24898 xfs_qm_dqattach 0 24898 NULL +codec_list_read_file_24910 codec_list_read_file 3 24910 NULL -+__btrfs_free_extent_24927 __btrfs_free_extent 7 24927 NULL nohasharray -+v4l2_ctrl_new_24927 v4l2_ctrl_new 7 24927 &__btrfs_free_extent_24927 ++v4l2_ctrl_new_24927 v4l2_ctrl_new 7 24927 NULL nohasharray ++__btrfs_free_extent_24927 __btrfs_free_extent 7 24927 &v4l2_ctrl_new_24927 +ocfs2_fiemap_24949 ocfs2_fiemap 4-3 24949 NULL +packet_sendmsg_24954 packet_sendmsg 4 24954 NULL +twl_i2c_write_u8_24976 twl_i2c_write_u8 3 24976 NULL @@ -116152,6 +116611,7 @@ index 0000000..41777a8 +ll_track_pid_seq_write_25068 ll_track_pid_seq_write 3 25068 NULL +SYSC_listxattr_25072 SYSC_listxattr 3 25072 NULL +ima_appraise_measurement_25093 ima_appraise_measurement 6 25093 NULL ++blkg_path_25099 blkg_path 3 25099 NULL +snd_rawmidi_kernel_write_25106 snd_rawmidi_kernel_write 3 25106 NULL +gfs2_quota_check_25130 gfs2_quota_check 0 25130 NULL +ipath_init_qp_table_25167 ipath_init_qp_table 2 25167 NULL @@ -116173,6 +116633,7 @@ index 0000000..41777a8 +dai_list_read_file_25421 dai_list_read_file 3 25421 NULL +xfs_qm_dqtobp_25448 xfs_qm_dqtobp 0 25448 NULL +generic_file_buffered_write_25464 generic_file_buffered_write 4-0-7 25464 NULL ++ipath_decode_err_25468 ipath_decode_err 3 25468 NULL +crypto_hash_digestsize_25469 crypto_hash_digestsize 0 25469 NULL +ivtv_buf_copy_from_user_25502 ivtv_buf_copy_from_user 4-0 25502 NULL +snd_pcm_plugin_build_25505 snd_pcm_plugin_build 5 25505 NULL @@ -116372,8 +116833,10 @@ index 0000000..41777a8 +sky2_pci_read16_27863 sky2_pci_read16 0 27863 NULL +ieee80211_if_read_dot11MeshHWMProotInterval_27873 ieee80211_if_read_dot11MeshHWMProotInterval 3 27873 NULL +unix_seqpacket_sendmsg_27893 unix_seqpacket_sendmsg 4 27893 NULL -+tracing_clock_write_27961 tracing_clock_write 3 27961 NULL nohasharray -+bio_next_split_27961 bio_next_split 2 27961 &tracing_clock_write_27961 ++check_mapped_name_27943 check_mapped_name 3 27943 NULL ++bio_next_split_27961 bio_next_split 2 27961 NULL nohasharray ++tracing_clock_write_27961 tracing_clock_write 3 27961 &bio_next_split_27961 ++security_path_chown_27966 security_path_chown 0 27966 NULL +tipc_media_addr_printf_27971 tipc_media_addr_printf 2 27971 NULL +device_register_27972 device_register 0 27972 NULL nohasharray +mic_rx_pkts_read_27972 mic_rx_pkts_read 3 27972 &device_register_27972 @@ -116414,6 +116877,7 @@ index 0000000..41777a8 +kstrtos16_from_user_28300 kstrtos16_from_user 2 28300 NULL +nouveau_compat_ioctl_28305 nouveau_compat_ioctl 2 28305 NULL +snd_pcm_oss_read_28317 snd_pcm_oss_read 3 28317 NULL ++security_inode_link_28327 security_inode_link 0 28327 NULL +generic_write_checks_28329 generic_write_checks 0 28329 NULL +bm_entry_write_28338 bm_entry_write 3 28338 NULL +tcp_copy_to_iovec_28344 tcp_copy_to_iovec 3 28344 NULL @@ -116446,6 +116910,7 @@ index 0000000..41777a8 +kfifo_unused_28612 kfifo_unused 0 28612 NULL +snd_nm256_capture_copy_28622 snd_nm256_capture_copy 5-3 28622 NULL +setup_usemap_28636 setup_usemap 3-4 28636 NULL ++qib_handle_6120_hwerrors_28642 qib_handle_6120_hwerrors 3 28642 NULL +xfs_bmap_finish_28644 xfs_bmap_finish 0 28644 NULL +p9_fcall_alloc_28652 p9_fcall_alloc 1 28652 NULL +read_nic_io_byte_28654 read_nic_io_byte 0 28654 NULL @@ -116529,6 +116994,7 @@ index 0000000..41777a8 +leaf_dealloc_29566 leaf_dealloc 3 29566 NULL +kvm_read_guest_virt_system_29569 kvm_read_guest_virt_system 4-2 29569 NULL +lbs_lowsnr_read_29571 lbs_lowsnr_read 3 29571 NULL ++security_path_chmod_29578 security_path_chmod 0 29578 NULL +iwl_dbgfs_missed_beacon_write_29586 iwl_dbgfs_missed_beacon_write 3 29586 NULL +pvr2_hdw_report_unlocked_29589 pvr2_hdw_report_unlocked 4-0 29589 NULL +dio_set_defer_completion_29599 dio_set_defer_completion 0 29599 NULL @@ -116683,6 +117149,7 @@ index 0000000..41777a8 +uvc_simplify_fraction_31303 uvc_simplify_fraction 3 31303 NULL +sisusbcon_scroll_31315 sisusbcon_scroll 5-2-3 31315 NULL +command_file_write_31318 command_file_write 3 31318 NULL ++hwerr_crcbits_31334 hwerr_crcbits 4 31334 NULL +radix_tree_insert_31336 radix_tree_insert 0 31336 NULL +em28xx_init_usb_xfer_31337 em28xx_init_usb_xfer 4-6 31337 NULL +outlen_write_31358 outlen_write 3 31358 NULL @@ -117025,6 +117492,7 @@ index 0000000..41777a8 +btrfs_super_chunk_root_34925 btrfs_super_chunk_root 0 34925 NULL nohasharray +__inode_permission_34925 __inode_permission 0 34925 &btrfs_super_chunk_root_34925 +ceph_aio_write_34930 ceph_aio_write 4 34930 NULL ++sec_flags2str_34933 sec_flags2str 3 34933 NULL +snd_info_entry_read_34938 snd_info_entry_read 3 34938 NULL +i2c_transfer_34958 i2c_transfer 0 34958 NULL +do_add_page_to_bio_34974 do_add_page_to_bio 2-10 34974 NULL @@ -117247,7 +117715,8 @@ index 0000000..41777a8 +ext3_direct_IO_37308 ext3_direct_IO 4 37308 NULL +jffs2_write_dirent_37311 jffs2_write_dirent 5 37311 NULL +send_msg_37323 send_msg 4 37323 NULL -+l2cap_create_connless_pdu_37327 l2cap_create_connless_pdu 3 37327 NULL ++l2cap_create_connless_pdu_37327 l2cap_create_connless_pdu 3 37327 NULL nohasharray ++bnx2x_vf_fill_fw_str_37327 bnx2x_vf_fill_fw_str 3 37327 &l2cap_create_connless_pdu_37327 +scsi_mode_select_37330 scsi_mode_select 6 37330 NULL +rxrpc_server_sendmsg_37331 rxrpc_server_sendmsg 4 37331 NULL +xfs_iomap_write_allocate_37336 xfs_iomap_write_allocate 0 37336 NULL @@ -117418,8 +117887,9 @@ index 0000000..41777a8 +qcam_read_bytes_39205 qcam_read_bytes 0 39205 NULL +ivtv_v4l2_write_39226 ivtv_v4l2_write 3 39226 NULL +posix_acl_to_xattr_39237 posix_acl_to_xattr 0 39237 NULL -+pwr_cont_miss_bcns_spread_read_39250 pwr_cont_miss_bcns_spread_read 3 39250 NULL nohasharray -+r128_compat_ioctl_39250 r128_compat_ioctl 2 39250 &pwr_cont_miss_bcns_spread_read_39250 ++snd_pcm_capture_forward_39248 snd_pcm_capture_forward 2 39248 NULL ++r128_compat_ioctl_39250 r128_compat_ioctl 2 39250 NULL nohasharray ++pwr_cont_miss_bcns_spread_read_39250 pwr_cont_miss_bcns_spread_read 3 39250 &r128_compat_ioctl_39250 +i915_error_state_read_39254 i915_error_state_read 3 39254 NULL +rx_filter_protection_filter_read_39282 rx_filter_protection_filter_read 3 39282 NULL +_iwl_dbgfs_pm_params_write_39325 _iwl_dbgfs_pm_params_write 3 39325 NULL @@ -117483,6 +117953,7 @@ index 0000000..41777a8 +broadsheetfb_write_39976 broadsheetfb_write 3 39976 NULL +mthca_array_init_39987 mthca_array_init 2 39987 NULL +fw_device_op_read_39990 fw_device_op_read 3 39990 NULL ++server_name2svname_39998 server_name2svname 4 39998 NULL +xen_hvm_config_40018 xen_hvm_config 2 40018 NULL +ivtvfb_write_40023 ivtvfb_write 3 40023 NULL +disc_pwup_write_40027 disc_pwup_write 3 40027 NULL @@ -117552,7 +118023,7 @@ index 0000000..41777a8 +pg_write_40766 pg_write 3 40766 NULL +kernfs_fop_read_40770 kernfs_fop_read 3 40770 NULL +show_list_40775 show_list 3-0 40775 NULL -+kfifo_out_copy_r_40784 kfifo_out_copy_r 0-3 40784 NULL ++kfifo_out_copy_r_40784 kfifo_out_copy_r 3-0 40784 NULL +bitmap_weight_40791 bitmap_weight 0-2 40791 NULL +pyra_sysfs_read_40795 pyra_sysfs_read 6 40795 NULL +add_action_40811 add_action 4 40811 NULL @@ -117636,6 +118107,7 @@ index 0000000..41777a8 +rx_rx_pre_complt_read_41653 rx_rx_pre_complt_read 3 41653 NULL +get_std_timing_41654 get_std_timing 0 41654 NULL +ieee80211_if_fmt_bssid_41677 ieee80211_if_fmt_bssid 3 41677 NULL ++fill_pcm_stream_name_41685 fill_pcm_stream_name 2 41685 NULL +lov_unpackmd_41701 lov_unpackmd 4 41701 NULL +apei_exec_for_each_entry_41717 apei_exec_for_each_entry 0 41717 NULL +fillonedir_41746 fillonedir 3 41746 NULL @@ -117805,6 +118277,7 @@ index 0000000..41777a8 +tx_frag_failed_read_43540 tx_frag_failed_read 3 43540 NULL +request_resource_43548 request_resource 0 43548 NULL +rpc_malloc_43573 rpc_malloc 2 43573 NULL ++handle_frequent_errors_43599 handle_frequent_errors 4 43599 NULL +lpfc_idiag_drbacc_read_reg_43606 lpfc_idiag_drbacc_read_reg 0-3 43606 NULL +proc_read_43614 proc_read 3 43614 NULL +disable_dma_on_even_43618 disable_dma_on_even 0 43618 NULL @@ -117874,6 +118347,7 @@ index 0000000..41777a8 +rts_threshold_read_44384 rts_threshold_read 3 44384 NULL +mtip_hw_read_flags_44396 mtip_hw_read_flags 3 44396 NULL +aoedev_flush_44398 aoedev_flush 2 44398 NULL ++strlcpy_44400 strlcpy 3 44400 NULL +drm_buffer_alloc_44405 drm_buffer_alloc 2 44405 NULL +osst_do_scsi_44410 osst_do_scsi 4 44410 NULL +ieee80211_if_read_rc_rateidx_mcs_mask_5ghz_44423 ieee80211_if_read_rc_rateidx_mcs_mask_5ghz 3 44423 NULL @@ -117986,7 +118460,8 @@ index 0000000..41777a8 +unix_dgram_sendmsg_45699 unix_dgram_sendmsg 4 45699 NULL nohasharray +bscnl_emit_45699 bscnl_emit 2-5-0 45699 &unix_dgram_sendmsg_45699 +sg_proc_write_adio_45704 sg_proc_write_adio 3 45704 NULL -+snd_cs46xx_io_read_45734 snd_cs46xx_io_read 5 45734 NULL ++snd_cs46xx_io_read_45734 snd_cs46xx_io_read 5 45734 NULL nohasharray ++task_cgroup_path_45734 task_cgroup_path 3 45734 &snd_cs46xx_io_read_45734 +rw_copy_check_uvector_45748 rw_copy_check_uvector 3-0 45748 NULL nohasharray +v4l2_ctrl_new_std_45748 v4l2_ctrl_new_std 5 45748 &rw_copy_check_uvector_45748 +lkdtm_debugfs_read_45752 lkdtm_debugfs_read 3 45752 NULL @@ -118065,7 +118540,7 @@ index 0000000..41777a8 +snd_compr_write_data_46592 snd_compr_write_data 3 46592 NULL +il3945_stats_flag_46606 il3945_stats_flag 0-3 46606 NULL +vscnprintf_46617 vscnprintf 0-2 46617 NULL -+__kfifo_out_r_46623 __kfifo_out_r 0-3 46623 NULL ++__kfifo_out_r_46623 __kfifo_out_r 3-0 46623 NULL +request_key_async_with_auxdata_46624 request_key_async_with_auxdata 4 46624 NULL +pci_enable_device_46642 pci_enable_device 0 46642 NULL +vfs_getxattr_alloc_46649 vfs_getxattr_alloc 0 46649 NULL @@ -118100,12 +118575,14 @@ index 0000000..41777a8 +SYSC_poll_46965 SYSC_poll 2 46965 NULL +crypto_tfm_alg_alignmask_46971 crypto_tfm_alg_alignmask 0 46971 NULL +mgmt_pending_add_46976 mgmt_pending_add 5 46976 NULL ++strlcat_46985 strlcat 3 46985 NULL +bitmap_file_clear_bit_46990 bitmap_file_clear_bit 2 46990 NULL +sel_write_bool_46996 sel_write_bool 3 46996 NULL +blk_rq_map_kern_47004 blk_rq_map_kern 4 47004 NULL +cx231xx_init_bulk_47024 cx231xx_init_bulk 3-2-4 47024 NULL +fs_path_len_47060 fs_path_len 0 47060 NULL +event_trigger_regex_write_47067 event_trigger_regex_write 3 47067 NULL ++ext4_xattr_list_entries_47070 ext4_xattr_list_entries 0 47070 NULL +pipeline_dec_packet_in_read_47076 pipeline_dec_packet_in_read 3 47076 NULL +scsi_deactivate_tcq_47086 scsi_deactivate_tcq 2 47086 NULL +iwl_dump_nic_event_log_47089 iwl_dump_nic_event_log 0 47089 NULL @@ -118160,7 +118637,8 @@ index 0000000..41777a8 +twl4030_clear_set_47624 twl4030_clear_set 4 47624 NULL +ccp_sha_setkey_47633 ccp_sha_setkey 3 47633 NULL +get_size_47644 get_size 1-2 47644 NULL -+packet_recvmsg_47700 packet_recvmsg 4 47700 NULL ++packet_recvmsg_47700 packet_recvmsg 4 47700 NULL nohasharray ++ipath_format_hwmsg_47700 ipath_format_hwmsg 2 47700 &packet_recvmsg_47700 +save_microcode_47717 save_microcode 3 47717 NULL +bits_to_user_47733 bits_to_user 2-3 47733 NULL +carl9170_debugfs_read_47738 carl9170_debugfs_read 3 47738 NULL @@ -118181,6 +118659,7 @@ index 0000000..41777a8 +cfs_percpt_alloc_47918 cfs_percpt_alloc 2 47918 NULL +comedi_write_47926 comedi_write 3 47926 NULL +nvme_trans_get_blk_desc_len_47946 nvme_trans_get_blk_desc_len 0-2 47946 NULL ++gether_get_ifname_47972 gether_get_ifname 3 47972 NULL +mempool_resize_47983 mempool_resize 2 47983 NULL nohasharray +iwl_dbgfs_ucode_tracing_read_47983 iwl_dbgfs_ucode_tracing_read 3 47983 &mempool_resize_47983 +dbg_port_buf_47990 dbg_port_buf 2 47990 NULL @@ -118233,6 +118712,7 @@ index 0000000..41777a8 +print_filtered_48442 print_filtered 2-0 48442 NULL +tun_recvmsg_48463 tun_recvmsg 4 48463 NULL +compat_SyS_preadv64_48469 compat_SyS_preadv64 3 48469 NULL ++ipath_format_hwerrors_48487 ipath_format_hwerrors 5 48487 NULL +r8712_usbctrl_vendorreq_48489 r8712_usbctrl_vendorreq 6 48489 NULL +send_control_msg_48498 send_control_msg 6 48498 NULL +count_masked_bytes_48507 count_masked_bytes 0-1 48507 NULL @@ -118299,6 +118779,7 @@ index 0000000..41777a8 +ath6kl_bgscan_int_write_49178 ath6kl_bgscan_int_write 3 49178 NULL +dvb_dvr_ioctl_49182 dvb_dvr_ioctl 2 49182 NULL +print_queue_49191 print_queue 4-0 49191 NULL ++root_nfs_cat_49192 root_nfs_cat 3 49192 NULL +iwl_dbgfs_ucode_general_stats_read_49199 iwl_dbgfs_ucode_general_stats_read 3 49199 NULL +il4965_rs_sta_dbgfs_stats_table_read_49206 il4965_rs_sta_dbgfs_stats_table_read 3 49206 NULL +do_jffs2_getxattr_49210 do_jffs2_getxattr 0 49210 NULL @@ -118379,6 +118860,7 @@ index 0000000..41777a8 +ioread8_50049 ioread8 0 50049 NULL +fuse_conn_max_background_write_50061 fuse_conn_max_background_write 3 50061 NULL +__kfifo_dma_in_prepare_50081 __kfifo_dma_in_prepare 4 50081 NULL ++dev_set_alias_50084 dev_set_alias 3 50084 NULL +libcfs_ioctl_popdata_50087 libcfs_ioctl_popdata 3 50087 NULL +sock_setsockopt_50088 sock_setsockopt 5 50088 NULL +altera_swap_dr_50090 altera_swap_dr 2 50090 NULL @@ -118597,6 +119079,7 @@ index 0000000..41777a8 +mdiobus_alloc_size_52259 mdiobus_alloc_size 1 52259 NULL +shrink_slab_52261 shrink_slab 2 52261 NULL +sisusbcon_do_font_op_52271 sisusbcon_do_font_op 9 52271 NULL ++handle_supp_msgs_52284 handle_supp_msgs 4 52284 NULL +kobject_set_name_vargs_52309 kobject_set_name_vargs 0 52309 NULL +read_file_reset_52310 read_file_reset 3 52310 NULL +request_asymmetric_key_52317 request_asymmetric_key 2-4 52317 NULL @@ -118656,6 +119139,7 @@ index 0000000..41777a8 +lb_alloc_ep_req_52837 lb_alloc_ep_req 2 52837 NULL +mon_bin_get_event_52863 mon_bin_get_event 4-6 52863 NULL +twl6030_gpadc_write_52867 twl6030_gpadc_write 1 52867 NULL ++qib_decode_6120_err_52876 qib_decode_6120_err 3 52876 NULL +twlreg_write_52880 twlreg_write 3 52880 NULL +pvr2_ctrl_value_to_sym_internal_52881 pvr2_ctrl_value_to_sym_internal 5 52881 NULL +cache_read_procfs_52882 cache_read_procfs 3 52882 NULL @@ -118881,7 +119365,7 @@ index 0000000..41777a8 +dbAllocDmap_55227 dbAllocDmap 0 55227 NULL +memcpy_fromiovec_55247 memcpy_fromiovec 3 55247 NULL +lbs_failcount_write_55276 lbs_failcount_write 3 55276 NULL -+persistent_ram_new_55286 persistent_ram_new 1-2 55286 NULL ++persistent_ram_new_55286 persistent_ram_new 2-1 55286 NULL +rx_streaming_interval_read_55291 rx_streaming_interval_read 3 55291 NULL +lov_get_stripecnt_55297 lov_get_stripecnt 0-3 55297 NULL +gsm_control_modem_55303 gsm_control_modem 3 55303 NULL @@ -119037,12 +119521,14 @@ index 0000000..41777a8 +debug_debug3_read_56894 debug_debug3_read 3 56894 NULL +batadv_tt_update_changes_56895 batadv_tt_update_changes 3 56895 NULL +hfsplus_find_cat_56899 hfsplus_find_cat 0 56899 NULL ++strcspn_56913 strcspn 0 56913 NULL +__kfifo_out_56927 __kfifo_out 0-3 56927 NULL +journal_init_revoke_56933 journal_init_revoke 2 56933 NULL +xfs_alloc_ag_vextent_56943 xfs_alloc_ag_vextent 0 56943 NULL +nouveau_xtensa_create__56952 nouveau_xtensa_create_ 8 56952 NULL +diva_get_driver_info_56967 diva_get_driver_info 0 56967 NULL +nouveau_device_create__56984 nouveau_device_create_ 6 56984 NULL ++sptlrpc_secflags2str_56995 sptlrpc_secflags2str 3 56995 NULL +vlsi_alloc_ring_57003 vlsi_alloc_ring 3-4 57003 NULL +btrfs_super_csum_size_57004 btrfs_super_csum_size 0 57004 NULL +aircable_process_packet_57027 aircable_process_packet 4 57027 NULL @@ -119054,6 +119540,7 @@ index 0000000..41777a8 +sca3000_read_data_57064 sca3000_read_data 4 57064 NULL +pcmcia_replace_cis_57066 pcmcia_replace_cis 3 57066 NULL +tracing_set_trace_write_57096 tracing_set_trace_write 3 57096 NULL ++altera_get_note_57099 altera_get_note 6 57099 NULL +hpfs_readpages_57106 hpfs_readpages 4 57106 NULL +crypto_compress_ctxsize_57109 crypto_compress_ctxsize 0 57109 NULL +cipso_v4_gentag_loc_57119 cipso_v4_gentag_loc 0 57119 NULL @@ -119067,7 +119554,7 @@ index 0000000..41777a8 +rx_hw_stuck_read_57179 rx_hw_stuck_read 3 57179 NULL +hash_netnet6_expire_57191 hash_netnet6_expire 4 57191 NULL +tt3650_ci_msg_57219 tt3650_ci_msg 4 57219 NULL -+dma_fifo_alloc_57236 dma_fifo_alloc 2-3-5 57236 NULL ++dma_fifo_alloc_57236 dma_fifo_alloc 5-3-2 57236 NULL +flush_space_57241 flush_space 0 57241 NULL +rsxx_cram_write_57244 rsxx_cram_write 3 57244 NULL +ieee80211_if_fmt_tsf_57249 ieee80211_if_fmt_tsf 3 57249 NULL @@ -119128,6 +119615,7 @@ index 0000000..41777a8 +ieee80211_if_fmt_dot11MeshHWMPpreqMinInterval_57762 ieee80211_if_fmt_dot11MeshHWMPpreqMinInterval 3 57762 NULL +SYSC_process_vm_writev_57776 SYSC_process_vm_writev 3-5 57776 NULL +apei_exec_collect_resources_57788 apei_exec_collect_resources 0 57788 NULL ++security_inode_unlink_57791 security_inode_unlink 0 57791 NULL +ld2_57794 ld2 0 57794 NULL +ivtv_read_57796 ivtv_read 3 57796 NULL +ion_test_ioctl_57799 ion_test_ioctl 2 57799 NULL @@ -119197,6 +119685,7 @@ index 0000000..41777a8 +rndis_add_response_58544 rndis_add_response 2 58544 NULL +wep_decrypt_fail_read_58567 wep_decrypt_fail_read 3 58567 NULL +scnprint_mac_oui_58578 scnprint_mac_oui 3-0 58578 NULL ++get_rhf_errstring_58582 get_rhf_errstring 3 58582 NULL +ea_read_inline_58589 ea_read_inline 0 58589 NULL +isku_sysfs_read_keys_thumbster_58590 isku_sysfs_read_keys_thumbster 6 58590 NULL +xip_file_read_58592 xip_file_read 3 58592 NULL @@ -119251,6 +119740,7 @@ index 0000000..41777a8 +ocfs2_move_extent_59187 ocfs2_move_extent 2-5 59187 NULL +xfs_ialloc_next_rec_59193 xfs_ialloc_next_rec 0 59193 NULL +xfs_iext_realloc_indirect_59211 xfs_iext_realloc_indirect 2 59211 NULL ++check_mapped_selector_name_59216 check_mapped_selector_name 5 59216 NULL +dt3155_read_59226 dt3155_read 3 59226 NULL +paging64_gpte_to_gfn_lvl_59229 paging64_gpte_to_gfn_lvl 0-1-2 59229 NULL +nla_len_59258 nla_len 0 59258 NULL @@ -119427,7 +119917,8 @@ index 0000000..41777a8 +smk_read_ambient_61220 smk_read_ambient 3 61220 NULL +v9fs_mmap_file_read_61262 v9fs_mmap_file_read 3 61262 NULL +btrfs_bio_alloc_61270 btrfs_bio_alloc 3 61270 NULL nohasharray -+find_get_pages_tag_61270 find_get_pages_tag 0 61270 &btrfs_bio_alloc_61270 ++find_get_pages_tag_61270 find_get_pages_tag 0 61270 &btrfs_bio_alloc_61270 nohasharray ++ifalias_store_61270 ifalias_store 4 61270 &find_get_pages_tag_61270 +vortex_adbdma_getlinearpos_61283 vortex_adbdma_getlinearpos 0 61283 NULL nohasharray +hfsplus_getxattr_finder_info_61283 hfsplus_getxattr_finder_info 0 61283 &vortex_adbdma_getlinearpos_61283 +nvme_trans_copy_to_user_61288 nvme_trans_copy_to_user 3 61288 NULL @@ -119464,6 +119955,7 @@ index 0000000..41777a8 +resize_stripes_61650 resize_stripes 2 61650 NULL +ttm_page_pool_free_61661 ttm_page_pool_free 2-0 61661 NULL +insert_one_name_61668 insert_one_name 7 61668 NULL ++qib_format_hwmsg_61679 qib_format_hwmsg 2 61679 NULL +lock_loop_61681 lock_loop 1 61681 NULL +filter_read_61692 filter_read 3 61692 NULL +iov_length_61716 iov_length 0 61716 NULL @@ -119614,6 +120106,7 @@ index 0000000..41777a8 +si5351_bulk_write_63468 si5351_bulk_write 2-3 63468 NULL +snd_info_entry_write_63474 snd_info_entry_write 3 63474 NULL +reada_find_extent_63486 reada_find_extent 2 63486 NULL ++read_kcore_63488 read_kcore 3 63488 NULL +snd_pcm_plug_write_transfer_63503 snd_pcm_plug_write_transfer 0-3 63503 NULL +efx_mcdi_rpc_async_63529 efx_mcdi_rpc_async 4-5 63529 NULL +ubi_more_leb_change_data_63534 ubi_more_leb_change_data 4 63534 NULL nohasharray @@ -119760,6 +120253,7 @@ index 0000000..41777a8 +suspend_dtim_interval_read_64971 suspend_dtim_interval_read 3 64971 NULL +crypto_ahash_digestsize_65014 crypto_ahash_digestsize 0 65014 NULL +insert_dent_65034 insert_dent 7 65034 NULL ++snd_hda_get_pin_label_65035 snd_hda_get_pin_label 5 65035 NULL +ext4_ind_trans_blocks_65053 ext4_ind_trans_blocks 0-2 65053 NULL +pcibios_enable_device_65059 pcibios_enable_device 0 65059 NULL +__alloc_bootmem_node_high_65076 __alloc_bootmem_node_high 2 65076 NULL @@ -119898,7 +120392,7 @@ index 0000000..560cd7b +zpios_read_64734 zpios_read 3 64734 NULL diff --git a/tools/gcc/size_overflow_plugin/size_overflow_plugin.c b/tools/gcc/size_overflow_plugin/size_overflow_plugin.c new file mode 100644 -index 0000000..900661b +index 0000000..e6fe17b --- /dev/null +++ b/tools/gcc/size_overflow_plugin/size_overflow_plugin.c @@ -0,0 +1,259 @@ @@ -119934,7 +120428,7 @@ index 0000000..900661b +tree size_overflow_type_TI; + +static struct plugin_info size_overflow_plugin_info = { -+ .version = "20140430", ++ .version = "20140517", + .help = "no-size-overflow\tturn off size overflow checking\n", +}; + diff --git a/main/linux-grsec/kernelconfig.armhf b/main/linux-grsec/kernelconfig.armhf index b3e4d6b13..3e11e1a42 100644 --- a/main/linux-grsec/kernelconfig.armhf +++ b/main/linux-grsec/kernelconfig.armhf @@ -1,6 +1,6 @@ # # Automatically generated file; DO NOT EDIT. -# Linux/arm 3.14.2 Kernel Configuration +# Linux/arm 3.14.4 Kernel Configuration # CONFIG_ARM=y CONFIG_MIGHT_HAVE_PCI=y @@ -4584,6 +4584,7 @@ CONFIG_GRKERNSEC_KMEM=y CONFIG_GRKERNSEC_PERF_HARDEN=y # CONFIG_GRKERNSEC_RAND_THREADSTACK is not set CONFIG_GRKERNSEC_PROC_MEMMAP=y +CONFIG_GRKERNSEC_KSTACKOVERFLOW=y CONFIG_GRKERNSEC_BRUTE=y # CONFIG_GRKERNSEC_MODHARDEN is not set # CONFIG_GRKERNSEC_HIDESYM is not set diff --git a/main/linux-grsec/kernelconfig.x86 b/main/linux-grsec/kernelconfig.x86 index 1b5e8569f..170392057 100644 --- a/main/linux-grsec/kernelconfig.x86 +++ b/main/linux-grsec/kernelconfig.x86 @@ -1,6 +1,6 @@ # # Automatically generated file; DO NOT EDIT. -# Linux/x86 3.14.2 Kernel Configuration +# Linux/x86 3.14.4 Kernel Configuration # # CONFIG_64BIT is not set CONFIG_X86_32=y @@ -5799,6 +5799,7 @@ CONFIG_GRKERNSEC_KMEM=y CONFIG_GRKERNSEC_PERF_HARDEN=y # CONFIG_GRKERNSEC_RAND_THREADSTACK is not set CONFIG_GRKERNSEC_PROC_MEMMAP=y +CONFIG_GRKERNSEC_KSTACKOVERFLOW=y CONFIG_GRKERNSEC_BRUTE=y # CONFIG_GRKERNSEC_MODHARDEN is not set # CONFIG_GRKERNSEC_HIDESYM is not set diff --git a/main/linux-grsec/kernelconfig.x86_64 b/main/linux-grsec/kernelconfig.x86_64 index d221dba39..aa8936589 100644 --- a/main/linux-grsec/kernelconfig.x86_64 +++ b/main/linux-grsec/kernelconfig.x86_64 @@ -1,6 +1,6 @@ # # Automatically generated file; DO NOT EDIT. -# Linux/x86 3.14.2 Kernel Configuration +# Linux/x86 3.14.4 Kernel Configuration # CONFIG_64BIT=y CONFIG_X86_64=y @@ -5651,6 +5651,7 @@ CONFIG_GRKERNSEC_JIT_HARDEN=y CONFIG_GRKERNSEC_PERF_HARDEN=y # CONFIG_GRKERNSEC_RAND_THREADSTACK is not set CONFIG_GRKERNSEC_PROC_MEMMAP=y +CONFIG_GRKERNSEC_KSTACKOVERFLOW=y CONFIG_GRKERNSEC_BRUTE=y # CONFIG_GRKERNSEC_MODHARDEN is not set # CONFIG_GRKERNSEC_HIDESYM is not set |