From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1RYHyH-0003JG-Ua for garchives@archives.gentoo.org; Wed, 07 Dec 2011 13:58:02 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 5811821C1B0; Wed, 7 Dec 2011 13:55:33 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id CF94B21C1B0 for ; Wed, 7 Dec 2011 13:55:26 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 078BD1B400F for ; Wed, 7 Dec 2011 13:55:25 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 1C73680037 for ; Wed, 7 Dec 2011 13:55:24 +0000 (UTC) From: "Anthony G. Basile" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Anthony G. Basile" Message-ID: Subject: [gentoo-commits] proj/hardened-patchset:master commit in: 2.6.32/, 3.1.4/ X-VCS-Repository: proj/hardened-patchset X-VCS-Files: 2.6.32/0000_README 2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201111292107.patch 2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201112041811.patch 3.1.4/0000_README 3.1.4/4420_grsecurity-2.2.2-3.1.4-201112021740.patch 3.1.4/4420_grsecurity-2.2.2-3.1.4-201112041811.patch X-VCS-Directories: 2.6.32/ 3.1.4/ X-VCS-Committer: blueness X-VCS-Committer-Name: Anthony G. Basile X-VCS-Revision: d5dad4d1e8525930f6556cfb19b360770cb54eda Date: Wed, 7 Dec 2011 13:55:24 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: 6cf9b3fd-caf0-42e1-9fcc-988b05009757 X-Archives-Hash: 15c94452140c8ea97552647230bab86c commit: d5dad4d1e8525930f6556cfb19b360770cb54eda Author: Anthony G. Basile gentoo org> AuthorDate: Wed Dec 7 13:55:05 2011 +0000 Commit: Anthony G. Basile gentoo org> CommitDate: Wed Dec 7 13:55:05 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/hardened-patc= hset.git;a=3Dcommit;h=3Dd5dad4d1 Grsec/PaX: 2.2.2-2.6.32.49-201112041811 + 2.2.2-3.1.4-201112041811 --- 2.6.32/0000_README | 2 +- ..._grsecurity-2.2.2-2.6.32.49-201112041811.patch} |30517 +++++++++++---= ------ 3.1.4/0000_README | 2 +- ...4420_grsecurity-2.2.2-3.1.4-201112041811.patch} |28356 ++++++++++----= ----- 4 files changed, 31574 insertions(+), 27303 deletions(-) diff --git a/2.6.32/0000_README b/2.6.32/0000_README index 5ce8a2a..fd7832e 100644 --- a/2.6.32/0000_README +++ b/2.6.32/0000_README @@ -3,7 +3,7 @@ README =20 Individual Patch Descriptions: ------------------------------------------------------------------------= ----- -Patch: 4420_grsecurity-2.2.2-2.6.32.49-201111292107.patch +Patch: 4420_grsecurity-2.2.2-2.6.32.49-201112041811.patch From: http://www.grsecurity.net Desc: hardened-sources base patch from upstream grsecurity =20 diff --git a/2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201111292107.patch b/= 2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201112041811.patch similarity index 79% rename from 2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201111292107.patch rename to 2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201112041811.patch index d13b039..dce7335 100644 --- a/2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201111292107.patch +++ b/2.6.32/4420_grsecurity-2.2.2-2.6.32.49-201112041811.patch @@ -1,7 +1,407 @@ -diff -urNp linux-2.6.32.49/arch/alpha/include/asm/elf.h linux-2.6.32.49/= arch/alpha/include/asm/elf.h ---- linux-2.6.32.49/arch/alpha/include/asm/elf.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/alpha/include/asm/elf.h 2011-11-15 19:59:42.000= 000000 -0500 -@@ -91,6 +91,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_N +diff --git a/Documentation/dontdiff b/Documentation/dontdiff +index e1efc40..47f0daf 100644 +--- a/Documentation/dontdiff ++++ b/Documentation/dontdiff +@@ -1,15 +1,19 @@ + *.a + *.aux + *.bin ++*.cis + *.cpio + *.csp ++*.dbg + *.dsp + *.dvi + *.elf + *.eps + *.fw ++*.gcno + *.gen.S + *.gif ++*.gmo + *.grep + *.grp + *.gz +@@ -38,8 +42,10 @@ + *.tab.h + *.tex + *.ver ++*.vim + *.xml + *_MODULES ++*_reg_safe.h + *_vga16.c + *~ + *.9 +@@ -49,11 +55,16 @@ + 53c700_d.h + CVS + ChangeSet ++GPATH ++GRTAGS ++GSYMS ++GTAGS + Image + Kerntypes + Module.markers + Module.symvers + PENDING ++PERF* + SCCS + System.map* + TAGS +@@ -76,7 +87,11 @@ btfixupprep + build + bvmlinux + bzImage* ++capability_names.h ++capflags.c + classlist.h* ++clut_vga16.c ++common-cmds.h + comp*.log + compile.h* + conf +@@ -84,6 +99,8 @@ config + config-* + config_data.h* + config_data.gz* ++config.c ++config.tmp + conmakehash + consolemap_deftbl.c* + cpustr.h +@@ -97,19 +114,23 @@ elfconfig.h* + fixdep + fore200e_mkfirm + fore200e_pca_fw.c* ++gate.lds + gconf + gen-devlist + gen_crc32table + gen_init_cpio + genksyms + *_gray256.c ++hash ++hid-example + ihex2fw + ikconfig.h* + initramfs_data.cpio ++initramfs_data.cpio.bz2 + initramfs_data.cpio.gz + initramfs_list + kallsyms +-kconfig ++kern_constants.h + keywords.c + ksym.c* + ksym.h* +@@ -127,13 +148,16 @@ machtypes.h + map + maui_boot.h + mconf ++mdp + miboot* + mk_elfconfig + mkboot + mkbugboot + mkcpustr + mkdep ++mkpiggy + mkprep ++mkregtable + mktables + mktree + modpost +@@ -149,6 +173,7 @@ patches* + pca200e.bin + pca200e_ecd.bin2 + piggy.gz ++piggy.S + piggyback + pnmtologo + ppc_defs.h* +@@ -157,12 +182,15 @@ qconf + raid6altivec*.c + raid6int*.c + raid6tables.c ++regdb.c + relocs ++rlim_names.h + series + setup + setup.bin + setup.elf + sImage ++slabinfo + sm_tbl* + split-include + syscalltab.h +@@ -171,6 +199,7 @@ tftpboot.img + timeconst.h + times.h* + trix_boot.h ++user_constants.h + utsrelease.h* + vdso-syms.lds + vdso.lds +@@ -186,14 +215,20 @@ version.h* + vmlinux + vmlinux-* + vmlinux.aout ++vmlinux.bin.all ++vmlinux.bin.bz2 + vmlinux.lds ++vmlinux.relocs ++voffset.h + vsyscall.lds + vsyscall_32.lds + wanxlfw.inc + uImage + unifdef ++utsrelease.h + wakeup.bin + wakeup.elf + wakeup.lds + zImage* + zconf.hash.c ++zoffset.h +diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-= parameters.txt +index c840e7d..f4c451c 100644 +--- a/Documentation/kernel-parameters.txt ++++ b/Documentation/kernel-parameters.txt +@@ -1837,6 +1837,13 @@ and is between 256 and 4096 characters. It is def= ined in the file + the specified number of seconds. This is to be used if + your oopses keep scrolling off the screen. +=20 ++ pax_nouderef [X86] disables UDEREF. Most likely needed under certain ++ virtualization environments that don't cope well with the ++ expand down segment used by UDEREF on X86-32 or the frequent ++ page table updates on X86-64. ++ ++ pax_softmode=3D 0/1 to disable/enable PaX softmode on boot already. ++ + pcbit=3D [HW,ISDN] +=20 + pcd. [PARIDE] +diff --git a/Makefile b/Makefile +index a19b0e8..f773d59 100644 +--- a/Makefile ++++ b/Makefile +@@ -221,8 +221,9 @@ CONFIG_SHELL :=3D $(shell if [ -x "$$BASH" ]; then e= cho $$BASH; \ +=20 + HOSTCC =3D gcc + HOSTCXX =3D g++ +-HOSTCFLAGS =3D -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fo= mit-frame-pointer +-HOSTCXXFLAGS =3D -O2 ++HOSTCFLAGS =3D -Wall -W -Wmissing-prototypes -Wstrict-prototypes -Wno= -unused-parameter -Wno-missing-field-initializers -O2 -fomit-frame-pointe= r -fno-delete-null-pointer-checks ++HOSTCFLAGS +=3D $(call cc-option, -Wno-empty-body) ++HOSTCXXFLAGS =3D -O2 -Wall -W -fno-delete-null-pointer-checks +=20 + # Decide whether to build built-in, modular, or both. + # Normally, just do built-in. +@@ -376,8 +377,8 @@ export RCS_TAR_IGNORE :=3D --exclude SCCS --exclude = BitKeeper --exclude .svn --exc + # Rules shared between *config targets and build targets +=20 + # Basic helpers built in scripts/ +-PHONY +=3D scripts_basic +-scripts_basic: ++PHONY +=3D scripts_basic gcc-plugins ++scripts_basic: gcc-plugins + $(Q)$(MAKE) $(build)=3Dscripts/basic +=20 + # To avoid any implicit rule to kick in, define an empty command. +@@ -403,7 +404,7 @@ endif + # of make so .config is not included in this case either (for *config). +=20 + no-dot-config-targets :=3D clean mrproper distclean \ +- cscope TAGS tags help %docs check% \ ++ cscope gtags TAGS tags help %docs check% \ + include/linux/version.h headers_% \ + kernelrelease kernelversion +=20 +@@ -526,6 +527,42 @@ else + KBUILD_CFLAGS +=3D -O2 + endif +=20 ++ifndef DISABLE_PAX_PLUGINS ++ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-plugin.sh "$(HOSTC= C)" "$(CC)"), y) ++ifndef DISABLE_PAX_CONSTIFY_PLUGIN ++CONSTIFY_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/constify_plugin.so= -DCONSTIFY_PLUGIN ++endif ++ifdef CONFIG_PAX_MEMORY_STACKLEAK ++STACKLEAK_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/stackleak_plugin.= so -DSTACKLEAK_PLUGIN ++STACKLEAK_PLUGIN +=3D -fplugin-arg-stackleak_plugin-track-lowest-sp=3D1= 00 ++endif ++ifdef CONFIG_KALLOCSTAT_PLUGIN ++KALLOCSTAT_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kallocstat_plugi= n.so ++endif ++ifdef CONFIG_PAX_KERNEXEC_PLUGIN ++KERNEXEC_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kernexec_plugin.so ++KERNEXEC_PLUGIN +=3D -fplugin-arg-kernexec_plugin-method=3D$(CONFIG_PAX= _KERNEXEC_PLUGIN_METHOD) ++endif ++ifdef CONFIG_CHECKER_PLUGIN ++ifeq ($(call cc-ifversion, -ge, 0406, y), y) ++CHECKER_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/checker_plugin.so -= DCHECKER_PLUGIN ++endif ++endif ++GCC_PLUGINS :=3D $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN) $(KALLOCSTAT_PL= UGIN) $(KERNEXEC_PLUGIN) $(CHECKER_PLUGIN) ++export CONSTIFY_PLUGIN STACKLEAK_PLUGIN KERNEXEC_PLUGIN CHECKER_PLUGIN ++gcc-plugins: ++ $(Q)$(MAKE) $(build)=3Dtools/gcc ++else ++gcc-plugins: ++ifeq ($(call cc-ifversion, -ge, 0405, y), y) ++ $(error Your gcc installation does not support plugins. If the necess= ary headers for plugin support are missing, they should be installed. On= Debian, apt-get install gcc--plugin-dev. If you choose to ignore t= his error and lessen the improvements provided by this patch, re-run make= with the DISABLE_PAX_PLUGINS=3Dy argument.)) ++else ++ $(Q)echo "warning, your gcc version does not support plugins, you shou= ld upgrade it to gcc 4.5 at least" ++endif ++ $(Q)echo "PAX_MEMORY_STACKLEAK and constification will be less secure" ++endif ++endif ++ + include $(srctree)/arch/$(SRCARCH)/Makefile +=20 + ifneq ($(CONFIG_FRAME_WARN),0) +@@ -647,7 +684,7 @@ export mod_strip_cmd +=20 +=20 + ifeq ($(KBUILD_EXTMOD),) +-core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ ++core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ +=20 + vmlinux-dirs :=3D $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ + $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ +@@ -868,6 +905,7 @@ vmlinux.o: $(modpost-init) $(vmlinux-main) FORCE +=20 + # The actual objects are generated when descending,=20 + # make sure no implicit rule kicks in ++$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): KBUILD_CFLAGS += =3D $(GCC_PLUGINS) + $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): $(vmlinux-dirs)= ; +=20 + # Handle descending into subdirectories listed in $(vmlinux-dirs) +@@ -877,7 +915,7 @@ $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-ld= s): $(vmlinux-dirs) ; + # Error messages still appears in the original language +=20 + PHONY +=3D $(vmlinux-dirs) +-$(vmlinux-dirs): prepare scripts ++$(vmlinux-dirs): gcc-plugins prepare scripts + $(Q)$(MAKE) $(build)=3D$@ +=20 + # Build the kernel release string +@@ -986,6 +1024,7 @@ prepare0: archprepare FORCE + $(Q)$(MAKE) $(build)=3D. missing-syscalls +=20 + # All the preparing.. ++prepare: KBUILD_CFLAGS :=3D $(filter-out $(GCC_PLUGINS),$(KBUILD_CFLAGS= )) + prepare: prepare0 +=20 + # The asm symlink changes when $(ARCH) changes. +@@ -1127,6 +1166,7 @@ all: modules + # using awk while concatenating to the final file. +=20 + PHONY +=3D modules ++modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) + modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) + $(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=3D$(objtree)/%/modules.order) = > $(objtree)/modules.order + @$(kecho) ' Building modules, stage 2.'; +@@ -1136,7 +1176,7 @@ modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vm= linux) +=20 + # Target to prepare building external modules + PHONY +=3D modules_prepare +-modules_prepare: prepare scripts ++modules_prepare: gcc-plugins prepare scripts +=20 + # Target to install modules + PHONY +=3D modules_install +@@ -1201,7 +1241,7 @@ MRPROPER_FILES +=3D .config .config.old include/as= m .version .old_version \ + include/linux/autoconf.h include/linux/version.h = \ + include/linux/utsrelease.h = \ + include/linux/bounds.h include/asm*/asm-offsets.h = \ +- Module.symvers Module.markers tags TAGS cscope* ++ Module.symvers Module.markers tags TAGS cscope* GPATH GTAGS GRTAGS = GSYMS +=20 + # clean - Delete most, but leave enough to build external modules + # +@@ -1245,7 +1285,7 @@ distclean: mrproper + @find $(srctree) $(RCS_FIND_IGNORE) \ + \( -name '*.orig' -o -name '*.rej' -o -name '*~' \ + -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \ +- -o -name '.*.rej' -o -size 0 \ ++ -o -name '.*.rej' -o -name '*.so' -o -size 0 \ + -o -name '*%' -o -name '.*.cmd' -o -name 'core' \) \ + -type f -print | xargs rm -f +=20 +@@ -1292,6 +1332,7 @@ help: + @echo ' modules_prepare - Set up for building external modules' + @echo ' tags/TAGS - Generate tags file for editors' + @echo ' cscope - Generate cscope index' ++ @echo ' gtags - Generate GNU GLOBAL index' + @echo ' kernelrelease - Output the release version string' + @echo ' kernelversion - Output the version stored in Makefile' + @echo ' headers_install - Install sanitised kernel headers to INSTAL= L_HDR_PATH'; \ +@@ -1393,6 +1434,7 @@ PHONY +=3D $(module-dirs) modules + $(module-dirs): crmodverdir $(objtree)/Module.symvers + $(Q)$(MAKE) $(build)=3D$(patsubst _module_%,%,$@) +=20 ++modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) + modules: $(module-dirs) + @$(kecho) ' Building modules, stage 2.'; + $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost +@@ -1448,7 +1490,7 @@ endif # KBUILD_EXTMOD + quiet_cmd_tags =3D GEN $@ + cmd_tags =3D $(CONFIG_SHELL) $(srctree)/scripts/tags.sh $@ +=20 +-tags TAGS cscope: FORCE ++tags TAGS cscope gtags: FORCE + $(call cmd,tags) +=20 + # Scripts to check various things for consistency +@@ -1513,17 +1555,19 @@ else + target-dir =3D $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@)) + endif +=20 +-%.s: %.c prepare scripts FORCE ++%.s: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%.s: %.c gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) + %.i: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +-%.o: %.c prepare scripts FORCE ++%.o: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%.o: %.c gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) + %.lst: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +-%.s: %.S prepare scripts FORCE ++%.s: %.S gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +-%.o: %.S prepare scripts FORCE ++%.o: %.S gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) + %.symtypes: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +@@ -1533,11 +1577,13 @@ endif + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ + $(build)=3D$(build-dir) +-%/: prepare scripts FORCE ++%/: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%/: gcc-plugins prepare scripts FORCE + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ + $(build)=3D$(build-dir) +-%.ko: prepare scripts FORCE ++%.ko: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%.ko: gcc-plugins prepare scripts FORCE + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ + $(build)=3D$(build-dir) $(@:.ko=3D.o) +diff --git a/arch/alpha/include/asm/elf.h b/arch/alpha/include/asm/elf.h +index 5c75c1b..c82f878 100644 +--- a/arch/alpha/include/asm/elf.h ++++ b/arch/alpha/include/asm/elf.h +@@ -91,6 +91,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; =20 #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x1000000) =20 @@ -15,9 +415,10 @@ diff -urNp linux-2.6.32.49/arch/alpha/include/asm/elf= .h linux-2.6.32.49/arch/alp /* $0 is set by ld.so to a pointer to a function which might be=20 registered using atexit. This provides a mean for the dynamic linker to call DT_FINI functions for shared libraries that have -diff -urNp linux-2.6.32.49/arch/alpha/include/asm/pgtable.h linux-2.6.32= .49/arch/alpha/include/asm/pgtable.h ---- linux-2.6.32.49/arch/alpha/include/asm/pgtable.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/alpha/include/asm/pgtable.h 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/alpha/include/asm/pgtable.h b/arch/alpha/include/asm/p= gtable.h +index 3f0c59f..cf1e100 100644 +--- a/arch/alpha/include/asm/pgtable.h ++++ b/arch/alpha/include/asm/pgtable.h @@ -101,6 +101,17 @@ struct vm_area_struct; #define PAGE_SHARED __pgprot(_PAGE_VALID | __ACCESS_BITS) #define PAGE_COPY __pgprot(_PAGE_VALID | __ACCESS_BITS | _PAGE_FOW) @@ -36,10 +437,11 @@ diff -urNp linux-2.6.32.49/arch/alpha/include/asm/pg= table.h linux-2.6.32.49/arch #define PAGE_KERNEL __pgprot(_PAGE_VALID | _PAGE_ASM | _PAGE_KRE | _PAG= E_KWE) =20 #define _PAGE_NORMAL(x) __pgprot(_PAGE_VALID | __ACCESS_BITS | (x)) -diff -urNp linux-2.6.32.49/arch/alpha/kernel/module.c linux-2.6.32.49/ar= ch/alpha/kernel/module.c ---- linux-2.6.32.49/arch/alpha/kernel/module.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/alpha/kernel/module.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -182,7 +182,7 @@ apply_relocate_add(Elf64_Shdr *sechdrs,=20 +diff --git a/arch/alpha/kernel/module.c b/arch/alpha/kernel/module.c +index ebc3c89..20cfa63 100644 +--- a/arch/alpha/kernel/module.c ++++ b/arch/alpha/kernel/module.c +@@ -182,7 +182,7 @@ apply_relocate_add(Elf64_Shdr *sechdrs, const char *= strtab, =20 /* The small sections were sorted to the end of the segment. The following should definitely cover them. */ @@ -48,10 +450,11 @@ diff -urNp linux-2.6.32.49/arch/alpha/kernel/module.= c linux-2.6.32.49/arch/alpha got =3D sechdrs[me->arch.gotsecindex].sh_addr; =20 for (i =3D 0; i < n; i++) { -diff -urNp linux-2.6.32.49/arch/alpha/kernel/osf_sys.c linux-2.6.32.49/a= rch/alpha/kernel/osf_sys.c ---- linux-2.6.32.49/arch/alpha/kernel/osf_sys.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/alpha/kernel/osf_sys.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -1172,7 +1172,7 @@ arch_get_unmapped_area_1(unsigned long a +diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c +index a94e49c..d71dd44 100644 +--- a/arch/alpha/kernel/osf_sys.c ++++ b/arch/alpha/kernel/osf_sys.c +@@ -1172,7 +1172,7 @@ arch_get_unmapped_area_1(unsigned long addr, unsig= ned long len, /* At this point: (!vma || addr < vma->vm_end). */ if (limit - len < addr) return -ENOMEM; @@ -60,7 +463,7 @@ diff -urNp linux-2.6.32.49/arch/alpha/kernel/osf_sys.c= linux-2.6.32.49/arch/alph return addr; addr =3D vma->vm_end; vma =3D vma->vm_next; -@@ -1208,6 +1208,10 @@ arch_get_unmapped_area(struct file *filp +@@ -1208,6 +1208,10 @@ arch_get_unmapped_area(struct file *filp, unsigne= d long addr, merely specific addresses, but regions of memory -- perhaps this feature should be incorporated into all ports? */ =20 @@ -71,7 +474,7 @@ diff -urNp linux-2.6.32.49/arch/alpha/kernel/osf_sys.c= linux-2.6.32.49/arch/alph if (addr) { addr =3D arch_get_unmapped_area_1 (PAGE_ALIGN(addr), len, limit); if (addr !=3D (unsigned long) -ENOMEM) -@@ -1215,8 +1219,8 @@ arch_get_unmapped_area(struct file *filp +@@ -1215,8 +1219,8 @@ arch_get_unmapped_area(struct file *filp, unsigned= long addr, } =20 /* Next, try allocating at TASK_UNMAPPED_BASE. */ @@ -82,10 +485,11 @@ diff -urNp linux-2.6.32.49/arch/alpha/kernel/osf_sys= .c linux-2.6.32.49/arch/alph if (addr !=3D (unsigned long) -ENOMEM) return addr; =20 -diff -urNp linux-2.6.32.49/arch/alpha/mm/fault.c linux-2.6.32.49/arch/al= pha/mm/fault.c ---- linux-2.6.32.49/arch/alpha/mm/fault.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/alpha/mm/fault.c 2011-11-18 18:01:52.000000000 = -0500 -@@ -54,6 +54,124 @@ __load_new_mm_context(struct mm_struct * +diff --git a/arch/alpha/mm/fault.c b/arch/alpha/mm/fault.c +index 00a31de..2ded0f2 100644 +--- a/arch/alpha/mm/fault.c ++++ b/arch/alpha/mm/fault.c +@@ -54,6 +54,124 @@ __load_new_mm_context(struct mm_struct *next_mm) __reload_thread(pcb); } =20 @@ -210,7 +614,7 @@ diff -urNp linux-2.6.32.49/arch/alpha/mm/fault.c linu= x-2.6.32.49/arch/alpha/mm/f =20 /* * This routine handles page faults. It determines the address, -@@ -131,8 +249,29 @@ do_page_fault(unsigned long address, uns +@@ -131,8 +249,29 @@ do_page_fault(unsigned long address, unsigned long = mmcsr, good_area: si_code =3D SEGV_ACCERR; if (cause < 0) { @@ -241,10 +645,11 @@ diff -urNp linux-2.6.32.49/arch/alpha/mm/fault.c li= nux-2.6.32.49/arch/alpha/mm/f } else if (!cause) { /* Allow reads even for write-only mappings */ if (!(vma->vm_flags & (VM_READ | VM_WRITE))) -diff -urNp linux-2.6.32.49/arch/arm/include/asm/elf.h linux-2.6.32.49/ar= ch/arm/include/asm/elf.h ---- linux-2.6.32.49/arch/arm/include/asm/elf.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/arm/include/asm/elf.h 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -109,7 +109,14 @@ int dump_task_regs(struct task_struct *t +diff --git a/arch/arm/include/asm/elf.h b/arch/arm/include/asm/elf.h +index 6aac3f5..265536b 100644 +--- a/arch/arm/include/asm/elf.h ++++ b/arch/arm/include/asm/elf.h +@@ -109,7 +109,14 @@ int dump_task_regs(struct task_struct *t, elf_gregs= et_t *elfregs); the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ =20 @@ -260,9 +665,10 @@ diff -urNp linux-2.6.32.49/arch/arm/include/asm/elf.= h linux-2.6.32.49/arch/arm/i =20 /* When the program starts, a1 contains a pointer to a function to be=20 registered with atexit, as per the SVR4 ABI. A value of 0 means we=20 -diff -urNp linux-2.6.32.49/arch/arm/include/asm/kmap_types.h linux-2.6.3= 2.49/arch/arm/include/asm/kmap_types.h ---- linux-2.6.32.49/arch/arm/include/asm/kmap_types.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/arm/include/asm/kmap_types.h 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/arm/include/asm/kmap_types.h b/arch/arm/include/asm/km= ap_types.h +index c019949..388fdd1 100644 +--- a/arch/arm/include/asm/kmap_types.h ++++ b/arch/arm/include/asm/kmap_types.h @@ -19,6 +19,7 @@ enum km_type { KM_SOFTIRQ0, KM_SOFTIRQ1, @@ -271,9 +677,10 @@ diff -urNp linux-2.6.32.49/arch/arm/include/asm/kmap= _types.h linux-2.6.32.49/arc KM_TYPE_NR }; =20 -diff -urNp linux-2.6.32.49/arch/arm/include/asm/uaccess.h linux-2.6.32.4= 9/arch/arm/include/asm/uaccess.h ---- linux-2.6.32.49/arch/arm/include/asm/uaccess.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/arm/include/asm/uaccess.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/arm/include/asm/uaccess.h b/arch/arm/include/asm/uacce= ss.h +index 1d6bd40..fba0cb9 100644 +--- a/arch/arm/include/asm/uaccess.h ++++ b/arch/arm/include/asm/uaccess.h @@ -22,6 +22,8 @@ #define VERIFY_READ 0 #define VERIFY_WRITE 1 @@ -309,7 +716,7 @@ diff -urNp linux-2.6.32.49/arch/arm/include/asm/uacce= ss.h linux-2.6.32.49/arch/a extern unsigned long __must_check __copy_to_user_std(void __user *to, c= onst void *from, unsigned long n); extern unsigned long __must_check __clear_user(void __user *addr, unsig= ned long n); extern unsigned long __must_check __clear_user_std(void __user *addr, u= nsigned long n); -@@ -403,6 +420,9 @@ extern unsigned long __must_check __strn +@@ -403,6 +420,9 @@ extern unsigned long __must_check __strnlen_user(con= st char __user *s, long n); =20 static inline unsigned long __must_check copy_from_user(void *to, const= void __user *from, unsigned long n) { @@ -319,7 +726,7 @@ diff -urNp linux-2.6.32.49/arch/arm/include/asm/uacce= ss.h linux-2.6.32.49/arch/a if (access_ok(VERIFY_READ, from, n)) n =3D __copy_from_user(to, from, n); else /* security hole - plug it */ -@@ -412,6 +432,9 @@ static inline unsigned long __must_check +@@ -412,6 +432,9 @@ static inline unsigned long __must_check copy_from_u= ser(void *to, const void __u =20 static inline unsigned long __must_check copy_to_user(void __user *to, = const void *from, unsigned long n) { @@ -329,9 +736,10 @@ diff -urNp linux-2.6.32.49/arch/arm/include/asm/uacc= ess.h linux-2.6.32.49/arch/a if (access_ok(VERIFY_WRITE, to, n)) n =3D __copy_to_user(to, from, n); return n; -diff -urNp linux-2.6.32.49/arch/arm/kernel/armksyms.c linux-2.6.32.49/ar= ch/arm/kernel/armksyms.c ---- linux-2.6.32.49/arch/arm/kernel/armksyms.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/arm/kernel/armksyms.c 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/arm/kernel/armksyms.c b/arch/arm/kernel/armksyms.c +index 0e62770..e2c2cd6 100644 +--- a/arch/arm/kernel/armksyms.c ++++ b/arch/arm/kernel/armksyms.c @@ -118,8 +118,8 @@ EXPORT_SYMBOL(__strncpy_from_user); #ifdef CONFIG_MMU EXPORT_SYMBOL(copy_page); @@ -343,9 +751,10 @@ diff -urNp linux-2.6.32.49/arch/arm/kernel/armksyms.= c linux-2.6.32.49/arch/arm/k EXPORT_SYMBOL(__clear_user); =20 EXPORT_SYMBOL(__get_user_1); -diff -urNp linux-2.6.32.49/arch/arm/kernel/kgdb.c linux-2.6.32.49/arch/a= rm/kernel/kgdb.c ---- linux-2.6.32.49/arch/arm/kernel/kgdb.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/arm/kernel/kgdb.c 2011-11-15 19:59:42.000000000= -0500 +diff --git a/arch/arm/kernel/kgdb.c b/arch/arm/kernel/kgdb.c +index ba8ccfe..2dc34dc 100644 +--- a/arch/arm/kernel/kgdb.c ++++ b/arch/arm/kernel/kgdb.c @@ -190,7 +190,7 @@ void kgdb_arch_exit(void) * and we handle the normal undef case within the do_undefinstr * handler. @@ -355,10 +764,11 @@ diff -urNp linux-2.6.32.49/arch/arm/kernel/kgdb.c l= inux-2.6.32.49/arch/arm/kerne #ifndef __ARMEB__ .gdb_bpt_instr =3D {0xfe, 0xde, 0xff, 0xe7} #else /* ! __ARMEB__ */ -diff -urNp linux-2.6.32.49/arch/arm/kernel/traps.c linux-2.6.32.49/arch/= arm/kernel/traps.c ---- linux-2.6.32.49/arch/arm/kernel/traps.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/arm/kernel/traps.c 2011-11-15 19:59:42.00000000= 0 -0500 -@@ -247,6 +247,8 @@ static void __die(const char *str, int e +diff --git a/arch/arm/kernel/traps.c b/arch/arm/kernel/traps.c +index 3f361a7..6e806e1 100644 +--- a/arch/arm/kernel/traps.c ++++ b/arch/arm/kernel/traps.c +@@ -247,6 +247,8 @@ static void __die(const char *str, int err, struct t= hread_info *thread, struct p =20 DEFINE_SPINLOCK(die_lock); =20 @@ -367,7 +777,7 @@ diff -urNp linux-2.6.32.49/arch/arm/kernel/traps.c li= nux-2.6.32.49/arch/arm/kern /* * This function is protected against re-entrancy. */ -@@ -271,6 +273,8 @@ NORET_TYPE void die(const char *str, str +@@ -271,6 +273,8 @@ NORET_TYPE void die(const char *str, struct pt_regs = *regs, int err) if (panic_on_oops) panic("Fatal exception"); =20 @@ -376,9 +786,10 @@ diff -urNp linux-2.6.32.49/arch/arm/kernel/traps.c l= inux-2.6.32.49/arch/arm/kern do_exit(SIGSEGV); } =20 -diff -urNp linux-2.6.32.49/arch/arm/lib/copy_from_user.S linux-2.6.32.49= /arch/arm/lib/copy_from_user.S ---- linux-2.6.32.49/arch/arm/lib/copy_from_user.S 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/arm/lib/copy_from_user.S 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/arm/lib/copy_from_user.S b/arch/arm/lib/copy_from_user= .S +index e4fe124..0fc246b 100644 +--- a/arch/arm/lib/copy_from_user.S ++++ b/arch/arm/lib/copy_from_user.S @@ -16,7 +16,7 @@ /* * Prototype: @@ -402,9 +813,10 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/copy_from_us= er.S linux-2.6.32.49/arch/ar =20 .section .fixup,"ax" .align 0 -diff -urNp linux-2.6.32.49/arch/arm/lib/copy_to_user.S linux-2.6.32.49/a= rch/arm/lib/copy_to_user.S ---- linux-2.6.32.49/arch/arm/lib/copy_to_user.S 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/arm/lib/copy_to_user.S 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/arm/lib/copy_to_user.S b/arch/arm/lib/copy_to_user.S +index 1a71e15..ac7b258 100644 +--- a/arch/arm/lib/copy_to_user.S ++++ b/arch/arm/lib/copy_to_user.S @@ -16,7 +16,7 @@ /* * Prototype: @@ -428,9 +840,10 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/copy_to_user= .S linux-2.6.32.49/arch/arm/ =20 .section .fixup,"ax" .align 0 -diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess.S linux-2.6.32.49/arch/a= rm/lib/uaccess.S ---- linux-2.6.32.49/arch/arm/lib/uaccess.S 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/arm/lib/uaccess.S 2011-11-15 19:59:42.000000000= -0500 +diff --git a/arch/arm/lib/uaccess.S b/arch/arm/lib/uaccess.S +index ffdd274..91017b6 100644 +--- a/arch/arm/lib/uaccess.S ++++ b/arch/arm/lib/uaccess.S @@ -19,7 +19,7 @@ =20 #define PAGE_SHIFT 12 @@ -440,7 +853,7 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess.S lin= ux-2.6.32.49/arch/arm/lib/u * Purpose : copy a block to user memory from kernel memory * Params : to - user memory * : from - kernel memory -@@ -39,7 +39,7 @@ USER( strgtbt r3, [r0], #1) @ May fau +@@ -39,7 +39,7 @@ USER( strgtbt r3, [r0], #1) @ May fault sub r2, r2, ip b .Lc2u_dest_aligned =20 @@ -449,7 +862,7 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess.S lin= ux-2.6.32.49/arch/arm/lib/u stmfd sp!, {r2, r4 - r7, lr} cmp r2, #4 blt .Lc2u_not_enough -@@ -277,14 +277,14 @@ USER( strgebt r3, [r0], #1) @ May fau +@@ -277,14 +277,14 @@ USER( strgebt r3, [r0], #1) @ May fault ldrgtb r3, [r1], #0 USER( strgtbt r3, [r0], #1) @ May fault b .Lc2u_finished @@ -466,7 +879,7 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess.S lin= ux-2.6.32.49/arch/arm/lib/u * Purpose : copy a block from user memory to kernel memory * Params : to - kernel memory * : from - user memory -@@ -303,7 +303,7 @@ USER( ldrgtbt r3, [r1], #1) @ May fau +@@ -303,7 +303,7 @@ USER( ldrgtbt r3, [r1], #1) @ May fault sub r2, r2, ip b .Lcfu_dest_aligned =20 @@ -475,7 +888,7 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess.S lin= ux-2.6.32.49/arch/arm/lib/u stmfd sp!, {r0, r2, r4 - r7, lr} cmp r2, #4 blt .Lcfu_not_enough -@@ -543,7 +543,7 @@ USER( ldrgebt r3, [r1], #1) @ May fau +@@ -543,7 +543,7 @@ USER( ldrgebt r3, [r1], #1) @ May fault USER( ldrgtbt r3, [r1], #1) @ May fault strgtb r3, [r0], #1 b .Lcfu_finished @@ -484,9 +897,10 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess.S li= nux-2.6.32.49/arch/arm/lib/u =20 .section .fixup,"ax" .align 0 -diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess_with_memcpy.c linux-2.6.= 32.49/arch/arm/lib/uaccess_with_memcpy.c ---- linux-2.6.32.49/arch/arm/lib/uaccess_with_memcpy.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/arm/lib/uaccess_with_memcpy.c 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/arm/lib/uaccess_with_memcpy.c b/arch/arm/lib/uaccess_w= ith_memcpy.c +index 6b967ff..67d5b2b 100644 +--- a/arch/arm/lib/uaccess_with_memcpy.c ++++ b/arch/arm/lib/uaccess_with_memcpy.c @@ -97,7 +97,7 @@ out: } =20 @@ -496,9 +910,10 @@ diff -urNp linux-2.6.32.49/arch/arm/lib/uaccess_with= _memcpy.c linux-2.6.32.49/ar { /* * This test is stubbed out of the main function above to keep -diff -urNp linux-2.6.32.49/arch/arm/mach-at91/pm.c linux-2.6.32.49/arch/= arm/mach-at91/pm.c ---- linux-2.6.32.49/arch/arm/mach-at91/pm.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/arm/mach-at91/pm.c 2011-11-15 19:59:42.00000000= 0 -0500 +diff --git a/arch/arm/mach-at91/pm.c b/arch/arm/mach-at91/pm.c +index 4028724..beec230 100644 +--- a/arch/arm/mach-at91/pm.c ++++ b/arch/arm/mach-at91/pm.c @@ -348,7 +348,7 @@ static void at91_pm_end(void) } =20 @@ -508,10 +923,11 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-at91/pm.c = linux-2.6.32.49/arch/arm/mach .valid =3D at91_pm_valid_state, .begin =3D at91_pm_begin, .enter =3D at91_pm_enter, -diff -urNp linux-2.6.32.49/arch/arm/mach-omap1/pm.c linux-2.6.32.49/arch= /arm/mach-omap1/pm.c ---- linux-2.6.32.49/arch/arm/mach-omap1/pm.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/arm/mach-omap1/pm.c 2011-11-15 19:59:42.0000000= 00 -0500 -@@ -647,7 +647,7 @@ static struct irqaction omap_wakeup_irq=20 +diff --git a/arch/arm/mach-omap1/pm.c b/arch/arm/mach-omap1/pm.c +index 5218943..0a34552 100644 +--- a/arch/arm/mach-omap1/pm.c ++++ b/arch/arm/mach-omap1/pm.c +@@ -647,7 +647,7 @@ static struct irqaction omap_wakeup_irq =3D { =20 =20 =20 @@ -520,9 +936,10 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-omap1/pm.c = linux-2.6.32.49/arch/arm/mac .prepare =3D omap_pm_prepare, .enter =3D omap_pm_enter, .finish =3D omap_pm_finish, -diff -urNp linux-2.6.32.49/arch/arm/mach-omap2/pm24xx.c linux-2.6.32.49/= arch/arm/mach-omap2/pm24xx.c ---- linux-2.6.32.49/arch/arm/mach-omap2/pm24xx.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/arm/mach-omap2/pm24xx.c 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/arm/mach-omap2/pm24xx.c b/arch/arm/mach-omap2/pm24xx.c +index bff5c4e..d4c649b 100644 +--- a/arch/arm/mach-omap2/pm24xx.c ++++ b/arch/arm/mach-omap2/pm24xx.c @@ -326,7 +326,7 @@ static void omap2_pm_finish(void) enable_hlt(); } @@ -532,9 +949,10 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-omap2/pm24x= x.c linux-2.6.32.49/arch/arm .prepare =3D omap2_pm_prepare, .enter =3D omap2_pm_enter, .finish =3D omap2_pm_finish, -diff -urNp linux-2.6.32.49/arch/arm/mach-omap2/pm34xx.c linux-2.6.32.49/= arch/arm/mach-omap2/pm34xx.c ---- linux-2.6.32.49/arch/arm/mach-omap2/pm34xx.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/arm/mach-omap2/pm34xx.c 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/arm/mach-omap2/pm34xx.c b/arch/arm/mach-omap2/pm34xx.c +index 8946319..7d3e661 100644 +--- a/arch/arm/mach-omap2/pm34xx.c ++++ b/arch/arm/mach-omap2/pm34xx.c @@ -401,7 +401,7 @@ static void omap3_pm_end(void) return; } @@ -544,10 +962,11 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-omap2/pm34= xx.c linux-2.6.32.49/arch/arm .begin =3D omap3_pm_begin, .end =3D omap3_pm_end, .prepare =3D omap3_pm_prepare, -diff -urNp linux-2.6.32.49/arch/arm/mach-pnx4008/pm.c linux-2.6.32.49/ar= ch/arm/mach-pnx4008/pm.c ---- linux-2.6.32.49/arch/arm/mach-pnx4008/pm.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/arm/mach-pnx4008/pm.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -116,7 +116,7 @@ static int pnx4008_pm_valid(suspend_stat +diff --git a/arch/arm/mach-pnx4008/pm.c b/arch/arm/mach-pnx4008/pm.c +index b3d8d53..6e68ebc 100644 +--- a/arch/arm/mach-pnx4008/pm.c ++++ b/arch/arm/mach-pnx4008/pm.c +@@ -116,7 +116,7 @@ static int pnx4008_pm_valid(suspend_state_t state) (state =3D=3D PM_SUSPEND_MEM); } =20 @@ -556,9 +975,10 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-pnx4008/pm.= c linux-2.6.32.49/arch/arm/m .enter =3D pnx4008_pm_enter, .valid =3D pnx4008_pm_valid, }; -diff -urNp linux-2.6.32.49/arch/arm/mach-pxa/pm.c linux-2.6.32.49/arch/a= rm/mach-pxa/pm.c ---- linux-2.6.32.49/arch/arm/mach-pxa/pm.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/arm/mach-pxa/pm.c 2011-11-15 19:59:42.000000000= -0500 +diff --git a/arch/arm/mach-pxa/pm.c b/arch/arm/mach-pxa/pm.c +index 7693355..9beb00a 100644 +--- a/arch/arm/mach-pxa/pm.c ++++ b/arch/arm/mach-pxa/pm.c @@ -95,7 +95,7 @@ void pxa_pm_finish(void) pxa_cpu_pm_fns->finish(); } @@ -568,10 +988,11 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-pxa/pm.c l= inux-2.6.32.49/arch/arm/mach- .valid =3D pxa_pm_valid, .enter =3D pxa_pm_enter, .prepare =3D pxa_pm_prepare, -diff -urNp linux-2.6.32.49/arch/arm/mach-pxa/sharpsl_pm.c linux-2.6.32.4= 9/arch/arm/mach-pxa/sharpsl_pm.c ---- linux-2.6.32.49/arch/arm/mach-pxa/sharpsl_pm.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/arm/mach-pxa/sharpsl_pm.c 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -891,7 +891,7 @@ static void sharpsl_apm_get_power_status +diff --git a/arch/arm/mach-pxa/sharpsl_pm.c b/arch/arm/mach-pxa/sharpsl_= pm.c +index 629e05d..06be589 100644 +--- a/arch/arm/mach-pxa/sharpsl_pm.c ++++ b/arch/arm/mach-pxa/sharpsl_pm.c +@@ -891,7 +891,7 @@ static void sharpsl_apm_get_power_status(struct apm_= power_info *info) } =20 #ifdef CONFIG_PM @@ -580,9 +1001,10 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-pxa/sharps= l_pm.c linux-2.6.32.49/arch/a .prepare =3D pxa_pm_prepare, .finish =3D pxa_pm_finish, .enter =3D corgi_pxa_pm_enter, -diff -urNp linux-2.6.32.49/arch/arm/mach-sa1100/pm.c linux-2.6.32.49/arc= h/arm/mach-sa1100/pm.c ---- linux-2.6.32.49/arch/arm/mach-sa1100/pm.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/arm/mach-sa1100/pm.c 2011-11-15 19:59:42.000000= 000 -0500 +diff --git a/arch/arm/mach-sa1100/pm.c b/arch/arm/mach-sa1100/pm.c +index c83fdc8..ab9fc44 100644 +--- a/arch/arm/mach-sa1100/pm.c ++++ b/arch/arm/mach-sa1100/pm.c @@ -120,7 +120,7 @@ unsigned long sleep_phys_sp(void *sp) return virt_to_phys(sp); } @@ -592,10 +1014,11 @@ diff -urNp linux-2.6.32.49/arch/arm/mach-sa1100/pm= .c linux-2.6.32.49/arch/arm/ma .enter =3D sa11x0_pm_enter, .valid =3D suspend_valid_only_mem, }; -diff -urNp linux-2.6.32.49/arch/arm/mm/fault.c linux-2.6.32.49/arch/arm/= mm/fault.c ---- linux-2.6.32.49/arch/arm/mm/fault.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/arm/mm/fault.c 2011-11-18 18:01:52.000000000 -0= 500 -@@ -166,6 +166,13 @@ __do_user_fault(struct task_struct *tsk, +diff --git a/arch/arm/mm/fault.c b/arch/arm/mm/fault.c +index 3191cd6..c0739db 100644 +--- a/arch/arm/mm/fault.c ++++ b/arch/arm/mm/fault.c +@@ -166,6 +166,13 @@ __do_user_fault(struct task_struct *tsk, unsigned l= ong addr, } #endif =20 @@ -609,7 +1032,7 @@ diff -urNp linux-2.6.32.49/arch/arm/mm/fault.c linux= -2.6.32.49/arch/arm/mm/fault tsk->thread.address =3D addr; tsk->thread.error_code =3D fsr; tsk->thread.trap_no =3D 14; -@@ -357,6 +364,33 @@ do_page_fault(unsigned long addr, unsign +@@ -357,6 +364,33 @@ do_page_fault(unsigned long addr, unsigned int fsr,= struct pt_regs *regs) } #endif /* CONFIG_MMU */ =20 @@ -643,10 +1066,11 @@ diff -urNp linux-2.6.32.49/arch/arm/mm/fault.c lin= ux-2.6.32.49/arch/arm/mm/fault /* * First Level Translation Fault Handler * -diff -urNp linux-2.6.32.49/arch/arm/mm/mmap.c linux-2.6.32.49/arch/arm/m= m/mmap.c ---- linux-2.6.32.49/arch/arm/mm/mmap.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/arm/mm/mmap.c 2011-11-15 19:59:42.000000000 -05= 00 -@@ -63,6 +63,10 @@ arch_get_unmapped_area(struct file *filp +diff --git a/arch/arm/mm/mmap.c b/arch/arm/mm/mmap.c +index f5abc51..7ec524c 100644 +--- a/arch/arm/mm/mmap.c ++++ b/arch/arm/mm/mmap.c +@@ -63,6 +63,10 @@ arch_get_unmapped_area(struct file *filp, unsigned lo= ng addr, if (len > TASK_SIZE) return -ENOMEM; =20 @@ -657,7 +1081,7 @@ diff -urNp linux-2.6.32.49/arch/arm/mm/mmap.c linux-= 2.6.32.49/arch/arm/mm/mmap.c if (addr) { if (do_align) addr =3D COLOUR_ALIGN(addr, pgoff); -@@ -70,15 +74,14 @@ arch_get_unmapped_area(struct file *filp +@@ -70,15 +74,14 @@ arch_get_unmapped_area(struct file *filp, unsigned l= ong addr, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -695,9 +1119,10 @@ diff -urNp linux-2.6.32.49/arch/arm/mm/mmap.c linux= -2.6.32.49/arch/arm/mm/mmap.c /* * Remember the place where we stopped the search: */ -diff -urNp linux-2.6.32.49/arch/arm/plat-s3c/pm.c linux-2.6.32.49/arch/a= rm/plat-s3c/pm.c ---- linux-2.6.32.49/arch/arm/plat-s3c/pm.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/arm/plat-s3c/pm.c 2011-11-15 19:59:42.000000000= -0500 +diff --git a/arch/arm/plat-s3c/pm.c b/arch/arm/plat-s3c/pm.c +index 8d97db2..b66cfa5 100644 +--- a/arch/arm/plat-s3c/pm.c ++++ b/arch/arm/plat-s3c/pm.c @@ -355,7 +355,7 @@ static void s3c_pm_finish(void) s3c_pm_check_cleanup(); } @@ -707,10 +1132,11 @@ diff -urNp linux-2.6.32.49/arch/arm/plat-s3c/pm.c = linux-2.6.32.49/arch/arm/plat- .enter =3D s3c_pm_enter, .prepare =3D s3c_pm_prepare, .finish =3D s3c_pm_finish, -diff -urNp linux-2.6.32.49/arch/avr32/include/asm/elf.h linux-2.6.32.49/= arch/avr32/include/asm/elf.h ---- linux-2.6.32.49/arch/avr32/include/asm/elf.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/avr32/include/asm/elf.h 2011-11-15 19:59:42.000= 000000 -0500 -@@ -85,8 +85,14 @@ typedef struct user_fpu_struct elf_fpreg +diff --git a/arch/avr32/include/asm/elf.h b/arch/avr32/include/asm/elf.h +index d5d1d41..856e2ed 100644 +--- a/arch/avr32/include/asm/elf.h ++++ b/arch/avr32/include/asm/elf.h +@@ -85,8 +85,14 @@ typedef struct user_fpu_struct elf_fpregset_t; the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ =20 @@ -726,9 +1152,10 @@ diff -urNp linux-2.6.32.49/arch/avr32/include/asm/e= lf.h linux-2.6.32.49/arch/avr =20 /* This yields a mask that user programs can use to figure out what instruction set this CPU supports. This could be done in user space= , -diff -urNp linux-2.6.32.49/arch/avr32/include/asm/kmap_types.h linux-2.6= .32.49/arch/avr32/include/asm/kmap_types.h ---- linux-2.6.32.49/arch/avr32/include/asm/kmap_types.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/avr32/include/asm/kmap_types.h 2011-11-15 19:59= :42.000000000 -0500 +diff --git a/arch/avr32/include/asm/kmap_types.h b/arch/avr32/include/as= m/kmap_types.h +index b7f5c68..556135c 100644 +--- a/arch/avr32/include/asm/kmap_types.h ++++ b/arch/avr32/include/asm/kmap_types.h @@ -22,7 +22,8 @@ D(10) KM_IRQ0, D(11) KM_IRQ1, D(12) KM_SOFTIRQ0, @@ -739,9 +1166,10 @@ diff -urNp linux-2.6.32.49/arch/avr32/include/asm/k= map_types.h linux-2.6.32.49/a }; =20 #undef D -diff -urNp linux-2.6.32.49/arch/avr32/mach-at32ap/pm.c linux-2.6.32.49/a= rch/avr32/mach-at32ap/pm.c ---- linux-2.6.32.49/arch/avr32/mach-at32ap/pm.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/avr32/mach-at32ap/pm.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/avr32/mach-at32ap/pm.c b/arch/avr32/mach-at32ap/pm.c +index f021edf..32d680e 100644 +--- a/arch/avr32/mach-at32ap/pm.c ++++ b/arch/avr32/mach-at32ap/pm.c @@ -176,7 +176,7 @@ out: return 0; } @@ -751,10 +1179,11 @@ diff -urNp linux-2.6.32.49/arch/avr32/mach-at32ap/= pm.c linux-2.6.32.49/arch/avr3 .valid =3D avr32_pm_valid_state, .enter =3D avr32_pm_enter, }; -diff -urNp linux-2.6.32.49/arch/avr32/mm/fault.c linux-2.6.32.49/arch/av= r32/mm/fault.c ---- linux-2.6.32.49/arch/avr32/mm/fault.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/avr32/mm/fault.c 2011-11-18 18:01:52.000000000 = -0500 -@@ -41,6 +41,23 @@ static inline int notify_page_fault(stru +diff --git a/arch/avr32/mm/fault.c b/arch/avr32/mm/fault.c +index b61d86d..e292c7f 100644 +--- a/arch/avr32/mm/fault.c ++++ b/arch/avr32/mm/fault.c +@@ -41,6 +41,23 @@ static inline int notify_page_fault(struct pt_regs *r= egs, int trap) =20 int exception_trace =3D 1; =20 @@ -795,10 +1224,11 @@ diff -urNp linux-2.6.32.49/arch/avr32/mm/fault.c l= inux-2.6.32.49/arch/avr32/mm/f if (exception_trace && printk_ratelimit()) printk("%s%s[%d]: segfault at %08lx pc %08lx " "sp %08lx ecr %lu\n", -diff -urNp linux-2.6.32.49/arch/blackfin/kernel/kgdb.c linux-2.6.32.49/a= rch/blackfin/kernel/kgdb.c ---- linux-2.6.32.49/arch/blackfin/kernel/kgdb.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/blackfin/kernel/kgdb.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -428,7 +428,7 @@ int kgdb_arch_handle_exception(int vecto +diff --git a/arch/blackfin/kernel/kgdb.c b/arch/blackfin/kernel/kgdb.c +index cce79d0..c406c85 100644 +--- a/arch/blackfin/kernel/kgdb.c ++++ b/arch/blackfin/kernel/kgdb.c +@@ -428,7 +428,7 @@ int kgdb_arch_handle_exception(int vector, int signo= , return -1; /* this means that we do not want to exit from the handler= */ } =20 @@ -807,10 +1237,11 @@ diff -urNp linux-2.6.32.49/arch/blackfin/kernel/kg= db.c linux-2.6.32.49/arch/blac .gdb_bpt_instr =3D {0xa1}, #ifdef CONFIG_SMP .flags =3D KGDB_HW_BREAKPOINT|KGDB_THR_PROC_SWAP, -diff -urNp linux-2.6.32.49/arch/blackfin/mach-common/pm.c linux-2.6.32.4= 9/arch/blackfin/mach-common/pm.c ---- linux-2.6.32.49/arch/blackfin/mach-common/pm.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/blackfin/mach-common/pm.c 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -255,7 +255,7 @@ static int bfin_pm_enter(suspend_state_t +diff --git a/arch/blackfin/mach-common/pm.c b/arch/blackfin/mach-common/= pm.c +index 8837be4..b2fb413 100644 +--- a/arch/blackfin/mach-common/pm.c ++++ b/arch/blackfin/mach-common/pm.c +@@ -255,7 +255,7 @@ static int bfin_pm_enter(suspend_state_t state) return 0; } =20 @@ -819,9 +1250,10 @@ diff -urNp linux-2.6.32.49/arch/blackfin/mach-commo= n/pm.c linux-2.6.32.49/arch/b .enter =3D bfin_pm_enter, .valid =3D bfin_pm_valid, }; -diff -urNp linux-2.6.32.49/arch/frv/include/asm/kmap_types.h linux-2.6.3= 2.49/arch/frv/include/asm/kmap_types.h ---- linux-2.6.32.49/arch/frv/include/asm/kmap_types.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/frv/include/asm/kmap_types.h 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/frv/include/asm/kmap_types.h b/arch/frv/include/asm/km= ap_types.h +index f8e16b2..c73ff79 100644 +--- a/arch/frv/include/asm/kmap_types.h ++++ b/arch/frv/include/asm/kmap_types.h @@ -23,6 +23,7 @@ enum km_type { KM_IRQ1, KM_SOFTIRQ0, @@ -830,10 +1262,11 @@ diff -urNp linux-2.6.32.49/arch/frv/include/asm/km= ap_types.h linux-2.6.32.49/arc KM_TYPE_NR }; =20 -diff -urNp linux-2.6.32.49/arch/frv/mm/elf-fdpic.c linux-2.6.32.49/arch/= frv/mm/elf-fdpic.c ---- linux-2.6.32.49/arch/frv/mm/elf-fdpic.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/frv/mm/elf-fdpic.c 2011-11-15 19:59:42.00000000= 0 -0500 -@@ -73,8 +73,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/frv/mm/elf-fdpic.c b/arch/frv/mm/elf-fdpic.c +index 385fd30..6c3d97e 100644 +--- a/arch/frv/mm/elf-fdpic.c ++++ b/arch/frv/mm/elf-fdpic.c +@@ -73,8 +73,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi if (addr) { addr =3D PAGE_ALIGN(addr); vma =3D find_vma(current->mm, addr); @@ -843,7 +1276,7 @@ diff -urNp linux-2.6.32.49/arch/frv/mm/elf-fdpic.c l= inux-2.6.32.49/arch/frv/mm/e goto success; } =20 -@@ -89,7 +88,7 @@ unsigned long arch_get_unmapped_area(str +@@ -89,7 +88,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi for (; vma; vma =3D vma->vm_next) { if (addr > limit) break; @@ -852,7 +1285,7 @@ diff -urNp linux-2.6.32.49/arch/frv/mm/elf-fdpic.c l= inux-2.6.32.49/arch/frv/mm/e goto success; addr =3D vma->vm_end; } -@@ -104,7 +103,7 @@ unsigned long arch_get_unmapped_area(str +@@ -104,7 +103,7 @@ unsigned long arch_get_unmapped_area(struct file *fi= lp, unsigned long addr, unsi for (; vma; vma =3D vma->vm_next) { if (addr > limit) break; @@ -861,9 +1294,10 @@ diff -urNp linux-2.6.32.49/arch/frv/mm/elf-fdpic.c = linux-2.6.32.49/arch/frv/mm/e goto success; addr =3D vma->vm_end; } -diff -urNp linux-2.6.32.49/arch/ia64/hp/common/hwsw_iommu.c linux-2.6.32= .49/arch/ia64/hp/common/hwsw_iommu.c ---- linux-2.6.32.49/arch/ia64/hp/common/hwsw_iommu.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/ia64/hp/common/hwsw_iommu.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/ia64/hp/common/hwsw_iommu.c b/arch/ia64/hp/common/hwsw= _iommu.c +index e4a80d8..11a7ea1 100644 +--- a/arch/ia64/hp/common/hwsw_iommu.c ++++ b/arch/ia64/hp/common/hwsw_iommu.c @@ -17,7 +17,7 @@ #include #include @@ -873,7 +1307,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/hp/common/hwsw_= iommu.c linux-2.6.32.49/arch =20 /* swiotlb declarations & definitions: */ extern int swiotlb_late_init_with_default_size (size_t size); -@@ -33,7 +33,7 @@ static inline int use_swiotlb(struct dev +@@ -33,7 +33,7 @@ static inline int use_swiotlb(struct device *dev) !sba_dma_ops.dma_supported(dev, *dev->dma_mask); } =20 @@ -882,10 +1316,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/hp/common/hws= w_iommu.c linux-2.6.32.49/arch { if (use_swiotlb(dev)) return &swiotlb_dma_ops; -diff -urNp linux-2.6.32.49/arch/ia64/hp/common/sba_iommu.c linux-2.6.32.= 49/arch/ia64/hp/common/sba_iommu.c ---- linux-2.6.32.49/arch/ia64/hp/common/sba_iommu.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/ia64/hp/common/sba_iommu.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -2097,7 +2097,7 @@ static struct acpi_driver acpi_sba_ioc_d +diff --git a/arch/ia64/hp/common/sba_iommu.c b/arch/ia64/hp/common/sba_i= ommu.c +index 01ae69b..35752fd 100644 +--- a/arch/ia64/hp/common/sba_iommu.c ++++ b/arch/ia64/hp/common/sba_iommu.c +@@ -2097,7 +2097,7 @@ static struct acpi_driver acpi_sba_ioc_driver =3D = { }, }; =20 @@ -903,10 +1338,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/hp/common/sba= _iommu.c linux-2.6.32.49/arch/ .alloc_coherent =3D sba_alloc_coherent, .free_coherent =3D sba_free_coherent, .map_page =3D sba_map_page, -diff -urNp linux-2.6.32.49/arch/ia64/ia32/binfmt_elf32.c linux-2.6.32.49= /arch/ia64/ia32/binfmt_elf32.c ---- linux-2.6.32.49/arch/ia64/ia32/binfmt_elf32.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/ia64/ia32/binfmt_elf32.c 2011-11-15 19:59:42.00= 0000000 -0500 -@@ -45,6 +45,13 @@ randomize_stack_top(unsigned long stack_ +diff --git a/arch/ia64/ia32/binfmt_elf32.c b/arch/ia64/ia32/binfmt_elf32= .c +index c69552b..c7122f4 100644 +--- a/arch/ia64/ia32/binfmt_elf32.c ++++ b/arch/ia64/ia32/binfmt_elf32.c +@@ -45,6 +45,13 @@ randomize_stack_top(unsigned long stack_top); =20 #define elf_read_implies_exec(ex, have_pt_gnu_stack) (!(have_pt_gnu_sta= ck)) =20 @@ -920,9 +1356,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/ia32/binfmt_el= f32.c linux-2.6.32.49/arch/ia /* Ugly but avoids duplication */ #include "../../../fs/binfmt_elf.c" =20 -diff -urNp linux-2.6.32.49/arch/ia64/ia32/ia32priv.h linux-2.6.32.49/arc= h/ia64/ia32/ia32priv.h ---- linux-2.6.32.49/arch/ia64/ia32/ia32priv.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/ia64/ia32/ia32priv.h 2011-11-15 19:59:42.000000= 000 -0500 +diff --git a/arch/ia64/ia32/ia32priv.h b/arch/ia64/ia32/ia32priv.h +index 0f15349..26b3429 100644 +--- a/arch/ia64/ia32/ia32priv.h ++++ b/arch/ia64/ia32/ia32priv.h @@ -296,7 +296,14 @@ typedef struct compat_siginfo { #define ELF_DATA ELFDATA2LSB #define ELF_ARCH EM_386 @@ -939,9 +1376,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/ia32/ia32priv.= h linux-2.6.32.49/arch/ia64/i #define IA32_GATE_OFFSET IA32_PAGE_OFFSET #define IA32_GATE_END IA32_PAGE_OFFSET + PAGE_SIZE =20 -diff -urNp linux-2.6.32.49/arch/ia64/include/asm/dma-mapping.h linux-2.6= .32.49/arch/ia64/include/asm/dma-mapping.h ---- linux-2.6.32.49/arch/ia64/include/asm/dma-mapping.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/ia64/include/asm/dma-mapping.h 2011-11-15 19:59= :42.000000000 -0500 +diff --git a/arch/ia64/include/asm/dma-mapping.h b/arch/ia64/include/asm= /dma-mapping.h +index 8d3c79c..71b3af6 100644 +--- a/arch/ia64/include/asm/dma-mapping.h ++++ b/arch/ia64/include/asm/dma-mapping.h @@ -12,7 +12,7 @@ =20 #define ARCH_HAS_DMA_GET_REQUIRED_MASK @@ -951,7 +1389,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/dma= -mapping.h linux-2.6.32.49/a extern struct ia64_machine_vector ia64_mv; extern void set_iommu_machvec(void); =20 -@@ -24,7 +24,7 @@ extern void machvec_dma_sync_sg(struct d +@@ -24,7 +24,7 @@ extern void machvec_dma_sync_sg(struct device *, struc= t scatterlist *, int, static inline void *dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *daddr, gfp_t gfp) { @@ -960,7 +1398,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/dma= -mapping.h linux-2.6.32.49/a void *caddr; =20 caddr =3D ops->alloc_coherent(dev, size, daddr, gfp); -@@ -35,7 +35,7 @@ static inline void *dma_alloc_coherent(s +@@ -35,7 +35,7 @@ static inline void *dma_alloc_coherent(struct device *= dev, size_t size, static inline void dma_free_coherent(struct device *dev, size_t size, void *caddr, dma_addr_t daddr) { @@ -969,7 +1407,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/dma= -mapping.h linux-2.6.32.49/a debug_dma_free_coherent(dev, size, caddr, daddr); ops->free_coherent(dev, size, caddr, daddr); } -@@ -49,13 +49,13 @@ static inline void dma_free_coherent(str +@@ -49,13 +49,13 @@ static inline void dma_free_coherent(struct device *= dev, size_t size, =20 static inline int dma_mapping_error(struct device *dev, dma_addr_t dadd= r) { @@ -985,9 +1423,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/dm= a-mapping.h linux-2.6.32.49/a return ops->dma_supported(dev, mask); } =20 -diff -urNp linux-2.6.32.49/arch/ia64/include/asm/elf.h linux-2.6.32.49/a= rch/ia64/include/asm/elf.h ---- linux-2.6.32.49/arch/ia64/include/asm/elf.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/ia64/include/asm/elf.h 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/ia64/include/asm/elf.h b/arch/ia64/include/asm/elf.h +index 86eddee..b116bb4 100644 +--- a/arch/ia64/include/asm/elf.h ++++ b/arch/ia64/include/asm/elf.h @@ -43,6 +43,13 @@ */ #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x800000000UL) @@ -1002,10 +1441,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/= elf.h linux-2.6.32.49/arch/ia64 #define PT_IA_64_UNWIND 0x70000001 =20 /* IA-64 relocations: */ -diff -urNp linux-2.6.32.49/arch/ia64/include/asm/machvec.h linux-2.6.32.= 49/arch/ia64/include/asm/machvec.h ---- linux-2.6.32.49/arch/ia64/include/asm/machvec.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/ia64/include/asm/machvec.h 2011-11-15 19:59:42.= 000000000 -0500 -@@ -45,7 +45,7 @@ typedef void ia64_mv_kernel_launch_event +diff --git a/arch/ia64/include/asm/machvec.h b/arch/ia64/include/asm/mac= hvec.h +index 367d299..9ad4279 100644 +--- a/arch/ia64/include/asm/machvec.h ++++ b/arch/ia64/include/asm/machvec.h +@@ -45,7 +45,7 @@ typedef void ia64_mv_kernel_launch_event_t(void); /* DMA-mapping interface: */ typedef void ia64_mv_dma_init (void); typedef u64 ia64_mv_dma_get_required_mask (struct device *); @@ -1014,7 +1454,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/ma= chvec.h linux-2.6.32.49/arch/ =20 /* * WARNING: The legacy I/O space is _architected_. Platforms are -@@ -251,7 +251,7 @@ extern void machvec_init_from_cmdline(co +@@ -251,7 +251,7 @@ extern void machvec_init_from_cmdline(const char *cm= dline); # endif /* CONFIG_IA64_GENERIC */ =20 extern void swiotlb_dma_init(void); @@ -1023,9 +1463,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/m= achvec.h linux-2.6.32.49/arch/ =20 /* * Define default versions so we can extend machvec for new platforms w= ithout having -diff -urNp linux-2.6.32.49/arch/ia64/include/asm/pgtable.h linux-2.6.32.= 49/arch/ia64/include/asm/pgtable.h ---- linux-2.6.32.49/arch/ia64/include/asm/pgtable.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/ia64/include/asm/pgtable.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/ia64/include/asm/pgtable.h b/arch/ia64/include/asm/pgt= able.h +index 8840a69..cdb63d9 100644 +--- a/arch/ia64/include/asm/pgtable.h ++++ b/arch/ia64/include/asm/pgtable.h @@ -12,7 +12,7 @@ * David Mosberger-Tang */ @@ -1053,10 +1494,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/= pgtable.h linux-2.6.32.49/arch/ #define PAGE_GATE __pgprot(__ACCESS_BITS | _PAGE_PL_0 | _PAGE_AR_X_RX) #define PAGE_KERNEL __pgprot(__DIRTY_BITS | _PAGE_PL_0 | _PAGE_AR_RWX) #define PAGE_KERNELRX __pgprot(__ACCESS_BITS | _PAGE_PL_0 | _PAGE_AR_RX= ) -diff -urNp linux-2.6.32.49/arch/ia64/include/asm/spinlock.h linux-2.6.32= .49/arch/ia64/include/asm/spinlock.h ---- linux-2.6.32.49/arch/ia64/include/asm/spinlock.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/ia64/include/asm/spinlock.h 2011-11-15 19:59:42= .000000000 -0500 -@@ -72,7 +72,7 @@ static __always_inline void __ticket_spi +diff --git a/arch/ia64/include/asm/spinlock.h b/arch/ia64/include/asm/sp= inlock.h +index 239ecdc..f94170e 100644 +--- a/arch/ia64/include/asm/spinlock.h ++++ b/arch/ia64/include/asm/spinlock.h +@@ -72,7 +72,7 @@ static __always_inline void __ticket_spin_unlock(raw_s= pinlock_t *lock) unsigned short *p =3D (unsigned short *)&lock->lock + 1, tmp; =20 asm volatile ("ld2.bias %0=3D[%1]" : "=3Dr"(tmp) : "r"(p)); @@ -1065,10 +1507,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/= spinlock.h linux-2.6.32.49/arch } =20 static __always_inline void __ticket_spin_unlock_wait(raw_spinlock_t *l= ock) -diff -urNp linux-2.6.32.49/arch/ia64/include/asm/uaccess.h linux-2.6.32.= 49/arch/ia64/include/asm/uaccess.h ---- linux-2.6.32.49/arch/ia64/include/asm/uaccess.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/ia64/include/asm/uaccess.h 2011-11-15 19:59:42.= 000000000 -0500 -@@ -257,7 +257,7 @@ __copy_from_user (void *to, const void _ +diff --git a/arch/ia64/include/asm/uaccess.h b/arch/ia64/include/asm/uac= cess.h +index 449c8c0..432a3d2 100644 +--- a/arch/ia64/include/asm/uaccess.h ++++ b/arch/ia64/include/asm/uaccess.h +@@ -257,7 +257,7 @@ __copy_from_user (void *to, const void __user *from,= unsigned long count) const void *__cu_from =3D (from); \ long __cu_len =3D (n); \ \ @@ -1077,7 +1520,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/ua= ccess.h linux-2.6.32.49/arch/ __cu_len =3D __copy_user(__cu_to, (__force void __user *) __cu_from, = __cu_len); \ __cu_len; \ }) -@@ -269,7 +269,7 @@ __copy_from_user (void *to, const void _ +@@ -269,7 +269,7 @@ __copy_from_user (void *to, const void __user *from,= unsigned long count) long __cu_len =3D (n); \ \ __chk_user_ptr(__cu_from); \ @@ -1086,9 +1529,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/include/asm/u= access.h linux-2.6.32.49/arch/ __cu_len =3D __copy_user((__force void __user *) __cu_to, __cu_from, = __cu_len); \ __cu_len; \ }) -diff -urNp linux-2.6.32.49/arch/ia64/kernel/dma-mapping.c linux-2.6.32.4= 9/arch/ia64/kernel/dma-mapping.c ---- linux-2.6.32.49/arch/ia64/kernel/dma-mapping.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/ia64/kernel/dma-mapping.c 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/ia64/kernel/dma-mapping.c b/arch/ia64/kernel/dma-mappi= ng.c +index f2c1600..969398a 100644 +--- a/arch/ia64/kernel/dma-mapping.c ++++ b/arch/ia64/kernel/dma-mapping.c @@ -3,7 +3,7 @@ /* Set this to 1 if there is a HW IOMMU in the system */ int iommu_detected __read_mostly; @@ -1107,9 +1551,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/dma-ma= pping.c linux-2.6.32.49/arch/i { return dma_ops; } -diff -urNp linux-2.6.32.49/arch/ia64/kernel/module.c linux-2.6.32.49/arc= h/ia64/kernel/module.c ---- linux-2.6.32.49/arch/ia64/kernel/module.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/ia64/kernel/module.c 2011-11-15 19:59:42.000000= 000 -0500 +diff --git a/arch/ia64/kernel/module.c b/arch/ia64/kernel/module.c +index 1481b0a..e7d38ff 100644 +--- a/arch/ia64/kernel/module.c ++++ b/arch/ia64/kernel/module.c @@ -315,8 +315,7 @@ module_alloc (unsigned long size) void module_free (struct module *mod, void *module_region) @@ -1120,7 +1565,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/module.= c linux-2.6.32.49/arch/ia64/k unw_remove_unwind_table(mod->arch.init_unw_table); mod->arch.init_unw_table =3D NULL; } -@@ -502,15 +501,39 @@ module_frob_arch_sections (Elf_Ehdr *ehd +@@ -502,15 +501,39 @@ module_frob_arch_sections (Elf_Ehdr *ehdr, Elf_Shd= r *sechdrs, char *secstrings, } =20 static inline int @@ -1162,7 +1607,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/module.= c linux-2.6.32.49/arch/ia64/k } =20 static inline int -@@ -693,7 +716,14 @@ do_reloc (struct module *mod, uint8_t r_ +@@ -693,7 +716,14 @@ do_reloc (struct module *mod, uint8_t r_type, Elf64= _Sym *sym, uint64_t addend, break; =20 case RV_BDREL: @@ -1178,7 +1623,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/module.= c linux-2.6.32.49/arch/ia64/k break; =20 case RV_LTV: -@@ -828,15 +858,15 @@ apply_relocate_add (Elf64_Shdr *sechdrs, +@@ -828,15 +858,15 @@ apply_relocate_add (Elf64_Shdr *sechdrs, const cha= r *strtab, unsigned int symind * addresses have been selected... */ uint64_t gp; @@ -1198,9 +1643,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/module= .c linux-2.6.32.49/arch/ia64/k mod->arch.gp =3D gp; DEBUGP("%s: placing gp at 0x%lx\n", __func__, gp); } -diff -urNp linux-2.6.32.49/arch/ia64/kernel/pci-dma.c linux-2.6.32.49/ar= ch/ia64/kernel/pci-dma.c ---- linux-2.6.32.49/arch/ia64/kernel/pci-dma.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/ia64/kernel/pci-dma.c 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/ia64/kernel/pci-dma.c b/arch/ia64/kernel/pci-dma.c +index f6b1ff0..de773fb 100644 +--- a/arch/ia64/kernel/pci-dma.c ++++ b/arch/ia64/kernel/pci-dma.c @@ -43,7 +43,7 @@ struct device fallback_dev =3D { .dma_mask =3D &fallback_dev.coherent_dma_mask, }; @@ -1210,7 +1656,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/pci-dma= .c linux-2.6.32.49/arch/ia64/ =20 static int __init pci_iommu_init(void) { -@@ -96,15 +96,34 @@ int iommu_dma_supported(struct device *d +@@ -96,15 +96,34 @@ int iommu_dma_supported(struct device *dev, u64 mask= ) } EXPORT_SYMBOL(iommu_dma_supported); =20 @@ -1252,10 +1698,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/pci-d= ma.c linux-2.6.32.49/arch/ia64/ =20 /* * The order of these functions is important for -diff -urNp linux-2.6.32.49/arch/ia64/kernel/pci-swiotlb.c linux-2.6.32.4= 9/arch/ia64/kernel/pci-swiotlb.c ---- linux-2.6.32.49/arch/ia64/kernel/pci-swiotlb.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/ia64/kernel/pci-swiotlb.c 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -21,7 +21,7 @@ static void *ia64_swiotlb_alloc_coherent +diff --git a/arch/ia64/kernel/pci-swiotlb.c b/arch/ia64/kernel/pci-swiot= lb.c +index 285aae8..61dbab6 100644 +--- a/arch/ia64/kernel/pci-swiotlb.c ++++ b/arch/ia64/kernel/pci-swiotlb.c +@@ -21,7 +21,7 @@ static void *ia64_swiotlb_alloc_coherent(struct device= *dev, size_t size, return swiotlb_alloc_coherent(dev, size, dma_handle, gfp); } =20 @@ -1264,10 +1711,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/pci-s= wiotlb.c linux-2.6.32.49/arch/i .alloc_coherent =3D ia64_swiotlb_alloc_coherent, .free_coherent =3D swiotlb_free_coherent, .map_page =3D swiotlb_map_page, -diff -urNp linux-2.6.32.49/arch/ia64/kernel/sys_ia64.c linux-2.6.32.49/a= rch/ia64/kernel/sys_ia64.c ---- linux-2.6.32.49/arch/ia64/kernel/sys_ia64.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/ia64/kernel/sys_ia64.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -43,6 +43,13 @@ arch_get_unmapped_area (struct file *fil +diff --git a/arch/ia64/kernel/sys_ia64.c b/arch/ia64/kernel/sys_ia64.c +index 609d500..7dde2a8 100644 +--- a/arch/ia64/kernel/sys_ia64.c ++++ b/arch/ia64/kernel/sys_ia64.c +@@ -43,6 +43,13 @@ arch_get_unmapped_area (struct file *filp, unsigned l= ong addr, unsigned long len if (REGION_NUMBER(addr) =3D=3D RGN_HPAGE) addr =3D 0; #endif @@ -1281,7 +1729,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/sys_ia6= 4.c linux-2.6.32.49/arch/ia64 if (!addr) addr =3D mm->free_area_cache; =20 -@@ -61,14 +68,14 @@ arch_get_unmapped_area (struct file *fil +@@ -61,14 +68,14 @@ arch_get_unmapped_area (struct file *filp, unsigned = long addr, unsigned long len for (vma =3D find_vma(mm, addr); ; vma =3D vma->vm_next) { /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr || RGN_MAP_LIMIT - len < REGION_OFFSET(add= r)) { @@ -1299,10 +1747,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/sys_i= a64.c linux-2.6.32.49/arch/ia64 /* Remember the address where we stopped this search: */ mm->free_area_cache =3D addr + len; return addr; -diff -urNp linux-2.6.32.49/arch/ia64/kernel/topology.c linux-2.6.32.49/a= rch/ia64/kernel/topology.c ---- linux-2.6.32.49/arch/ia64/kernel/topology.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/ia64/kernel/topology.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -282,7 +282,7 @@ static ssize_t cache_show(struct kobject +diff --git a/arch/ia64/kernel/topology.c b/arch/ia64/kernel/topology.c +index 8f06035..b3a5818 100644 +--- a/arch/ia64/kernel/topology.c ++++ b/arch/ia64/kernel/topology.c +@@ -282,7 +282,7 @@ static ssize_t cache_show(struct kobject * kobj, str= uct attribute * attr, char * return ret; } =20 @@ -1311,9 +1760,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/topolo= gy.c linux-2.6.32.49/arch/ia64 .show =3D cache_show }; =20 -diff -urNp linux-2.6.32.49/arch/ia64/kernel/vmlinux.lds.S linux-2.6.32.4= 9/arch/ia64/kernel/vmlinux.lds.S ---- linux-2.6.32.49/arch/ia64/kernel/vmlinux.lds.S 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/ia64/kernel/vmlinux.lds.S 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/ia64/kernel/vmlinux.lds.S b/arch/ia64/kernel/vmlinux.l= ds.S +index 0a0c77b..8e55a81 100644 +--- a/arch/ia64/kernel/vmlinux.lds.S ++++ b/arch/ia64/kernel/vmlinux.lds.S @@ -190,7 +190,7 @@ SECTIONS /* Per-cpu data: */ . =3D ALIGN(PERCPU_PAGE_SIZE); @@ -1323,10 +1773,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/kernel/vmlin= ux.lds.S linux-2.6.32.49/arch/i . =3D __phys_per_cpu_start + PERCPU_PAGE_SIZE; /* ensure percpu data = fits * into percpu page size */ -diff -urNp linux-2.6.32.49/arch/ia64/mm/fault.c linux-2.6.32.49/arch/ia6= 4/mm/fault.c ---- linux-2.6.32.49/arch/ia64/mm/fault.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/arch/ia64/mm/fault.c 2011-11-18 18:01:52.000000000 -= 0500 -@@ -72,6 +72,23 @@ mapped_kernel_page_is_present (unsigned=20 +diff --git a/arch/ia64/mm/fault.c b/arch/ia64/mm/fault.c +index 19261a9..1611b7a 100644 +--- a/arch/ia64/mm/fault.c ++++ b/arch/ia64/mm/fault.c +@@ -72,6 +72,23 @@ mapped_kernel_page_is_present (unsigned long address) return pte_present(pte); } =20 @@ -1350,7 +1801,7 @@ diff -urNp linux-2.6.32.49/arch/ia64/mm/fault.c lin= ux-2.6.32.49/arch/ia64/mm/fau void __kprobes ia64_do_page_fault (unsigned long address, unsigned long isr, struct pt= _regs *regs) { -@@ -145,9 +162,23 @@ ia64_do_page_fault (unsigned long addres +@@ -145,9 +162,23 @@ ia64_do_page_fault (unsigned long address, unsigned= long isr, struct pt_regs *re mask =3D ( (((isr >> IA64_ISR_X_BIT) & 1UL) << VM_EXEC_BIT) | (((isr >> IA64_ISR_W_BIT) & 1UL) << VM_WRITE_BIT)); =20 @@ -1375,10 +1826,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/mm/fault.c l= inux-2.6.32.49/arch/ia64/mm/fau survive: /* * If for any reason at all we couldn't handle the fault, make -diff -urNp linux-2.6.32.49/arch/ia64/mm/hugetlbpage.c linux-2.6.32.49/ar= ch/ia64/mm/hugetlbpage.c ---- linux-2.6.32.49/arch/ia64/mm/hugetlbpage.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/ia64/mm/hugetlbpage.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -172,7 +172,7 @@ unsigned long hugetlb_get_unmapped_area( +diff --git a/arch/ia64/mm/hugetlbpage.c b/arch/ia64/mm/hugetlbpage.c +index b0f6157..a082bbc 100644 +--- a/arch/ia64/mm/hugetlbpage.c ++++ b/arch/ia64/mm/hugetlbpage.c +@@ -172,7 +172,7 @@ unsigned long hugetlb_get_unmapped_area(struct file = *file, unsigned long addr, u /* At this point: (!vmm || addr < vmm->vm_end). */ if (REGION_OFFSET(addr) + len > RGN_MAP_LIMIT) return -ENOMEM; @@ -1387,9 +1839,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/mm/hugetlbpag= e.c linux-2.6.32.49/arch/ia64/ return addr; addr =3D ALIGN(vmm->vm_end, HPAGE_SIZE); } -diff -urNp linux-2.6.32.49/arch/ia64/mm/init.c linux-2.6.32.49/arch/ia64= /mm/init.c ---- linux-2.6.32.49/arch/ia64/mm/init.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/ia64/mm/init.c 2011-11-15 19:59:42.000000000 -0= 500 +diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c +index 1857766..05cc6a3 100644 +--- a/arch/ia64/mm/init.c ++++ b/arch/ia64/mm/init.c @@ -122,6 +122,19 @@ ia64_init_addr_space (void) vma->vm_start =3D current->thread.rbs_bot & PAGE_MASK; vma->vm_end =3D vma->vm_start + PAGE_SIZE; @@ -1410,10 +1863,11 @@ diff -urNp linux-2.6.32.49/arch/ia64/mm/init.c li= nux-2.6.32.49/arch/ia64/mm/init vma->vm_page_prot =3D vm_get_page_prot(vma->vm_flags); down_write(¤t->mm->mmap_sem); if (insert_vm_struct(current->mm, vma)) { -diff -urNp linux-2.6.32.49/arch/ia64/sn/pci/pci_dma.c linux-2.6.32.49/ar= ch/ia64/sn/pci/pci_dma.c ---- linux-2.6.32.49/arch/ia64/sn/pci/pci_dma.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/ia64/sn/pci/pci_dma.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -464,7 +464,7 @@ int sn_pci_legacy_write(struct pci_bus * +diff --git a/arch/ia64/sn/pci/pci_dma.c b/arch/ia64/sn/pci/pci_dma.c +index 98b6849..8046766 100644 +--- a/arch/ia64/sn/pci/pci_dma.c ++++ b/arch/ia64/sn/pci/pci_dma.c +@@ -464,7 +464,7 @@ int sn_pci_legacy_write(struct pci_bus *bus, u16 por= t, u32 val, u8 size) return ret; } =20 @@ -1422,9 +1876,10 @@ diff -urNp linux-2.6.32.49/arch/ia64/sn/pci/pci_dm= a.c linux-2.6.32.49/arch/ia64/ .alloc_coherent =3D sn_dma_alloc_coherent, .free_coherent =3D sn_dma_free_coherent, .map_page =3D sn_dma_map_page, -diff -urNp linux-2.6.32.49/arch/m32r/lib/usercopy.c linux-2.6.32.49/arch= /m32r/lib/usercopy.c ---- linux-2.6.32.49/arch/m32r/lib/usercopy.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/m32r/lib/usercopy.c 2011-11-15 19:59:42.0000000= 00 -0500 +diff --git a/arch/m32r/lib/usercopy.c b/arch/m32r/lib/usercopy.c +index 82abd15..d95ae5d 100644 +--- a/arch/m32r/lib/usercopy.c ++++ b/arch/m32r/lib/usercopy.c @@ -14,6 +14,9 @@ unsigned long __generic_copy_to_user(void __user *to, const void *from, unsigned long= n) @@ -1435,7 +1890,7 @@ diff -urNp linux-2.6.32.49/arch/m32r/lib/usercopy.c= linux-2.6.32.49/arch/m32r/li prefetch(from); if (access_ok(VERIFY_WRITE, to, n)) __copy_user(to,from,n); -@@ -23,6 +26,9 @@ __generic_copy_to_user(void __user *to,=20 +@@ -23,6 +26,9 @@ __generic_copy_to_user(void __user *to, const void *fr= om, unsigned long n) unsigned long __generic_copy_from_user(void *to, const void __user *from, unsigned lo= ng n) { @@ -1445,9 +1900,23 @@ diff -urNp linux-2.6.32.49/arch/m32r/lib/usercopy.= c linux-2.6.32.49/arch/m32r/li prefetchw(to); if (access_ok(VERIFY_READ, from, n)) __copy_user_zeroing(to,from,n); -diff -urNp linux-2.6.32.49/arch/mips/alchemy/devboards/pm.c linux-2.6.32= .49/arch/mips/alchemy/devboards/pm.c ---- linux-2.6.32.49/arch/mips/alchemy/devboards/pm.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/mips/alchemy/devboards/pm.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/mips/Makefile b/arch/mips/Makefile +index 77f5021..2b1db8a 100644 +--- a/arch/mips/Makefile ++++ b/arch/mips/Makefile +@@ -51,6 +51,8 @@ endif + cflags-y :=3D -ffunction-sections + cflags-y +=3D $(call cc-option, -mno-check-zero-division) +=20 ++cflags-y +=3D -Wno-sign-compare -Wno-extra ++ + ifdef CONFIG_32BIT + ld-emul =3D $(32bit-emul) + vmlinux-32 =3D vmlinux +diff --git a/arch/mips/alchemy/devboards/pm.c b/arch/mips/alchemy/devboa= rds/pm.c +index 632f986..fd0378d 100644 +--- a/arch/mips/alchemy/devboards/pm.c ++++ b/arch/mips/alchemy/devboards/pm.c @@ -78,7 +78,7 @@ static void db1x_pm_end(void) =20 } @@ -1457,10 +1926,11 @@ diff -urNp linux-2.6.32.49/arch/mips/alchemy/devb= oards/pm.c linux-2.6.32.49/arch .valid =3D suspend_valid_only_mem, .begin =3D db1x_pm_begin, .enter =3D db1x_pm_enter, -diff -urNp linux-2.6.32.49/arch/mips/include/asm/elf.h linux-2.6.32.49/a= rch/mips/include/asm/elf.h ---- linux-2.6.32.49/arch/mips/include/asm/elf.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/mips/include/asm/elf.h 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -368,4 +368,11 @@ extern int dump_task_fpu(struct task_str +diff --git a/arch/mips/include/asm/elf.h b/arch/mips/include/asm/elf.h +index 7990694..4e93acf 100644 +--- a/arch/mips/include/asm/elf.h ++++ b/arch/mips/include/asm/elf.h +@@ -368,4 +368,11 @@ extern int dump_task_fpu(struct task_struct *, elf_= fpregset_t *); #define ELF_ET_DYN_BASE (TASK_SIZE / 3 * 2) #endif =20 @@ -1472,10 +1942,11 @@ diff -urNp linux-2.6.32.49/arch/mips/include/asm/= elf.h linux-2.6.32.49/arch/mips +#endif + #endif /* _ASM_ELF_H */ -diff -urNp linux-2.6.32.49/arch/mips/include/asm/page.h linux-2.6.32.49/= arch/mips/include/asm/page.h ---- linux-2.6.32.49/arch/mips/include/asm/page.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/mips/include/asm/page.h 2011-11-15 19:59:42.000= 000000 -0500 -@@ -93,7 +93,7 @@ extern void copy_user_highpage(struct pa +diff --git a/arch/mips/include/asm/page.h b/arch/mips/include/asm/page.h +index f266295..627cfff 100644 +--- a/arch/mips/include/asm/page.h ++++ b/arch/mips/include/asm/page.h +@@ -93,7 +93,7 @@ extern void copy_user_highpage(struct page *to, struct= page *from, #ifdef CONFIG_CPU_MIPS32 typedef struct { unsigned long pte_low, pte_high; } pte_t; #define pte_val(x) ((x).pte_low | ((unsigned long long)(x).pte_h= igh << 32)) @@ -1484,9 +1955,10 @@ diff -urNp linux-2.6.32.49/arch/mips/include/asm/p= age.h linux-2.6.32.49/arch/mip #else typedef struct { unsigned long long pte; } pte_t; #define pte_val(x) ((x).pte) -diff -urNp linux-2.6.32.49/arch/mips/include/asm/reboot.h linux-2.6.32.4= 9/arch/mips/include/asm/reboot.h ---- linux-2.6.32.49/arch/mips/include/asm/reboot.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/mips/include/asm/reboot.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/mips/include/asm/reboot.h b/arch/mips/include/asm/rebo= ot.h +index e48c0bf..f3acf65 100644 +--- a/arch/mips/include/asm/reboot.h ++++ b/arch/mips/include/asm/reboot.h @@ -9,7 +9,7 @@ #ifndef _ASM_REBOOT_H #define _ASM_REBOOT_H @@ -1497,9 +1969,10 @@ diff -urNp linux-2.6.32.49/arch/mips/include/asm/r= eboot.h linux-2.6.32.49/arch/m +extern void (*__noreturn _machine_halt)(void); =20 #endif /* _ASM_REBOOT_H */ -diff -urNp linux-2.6.32.49/arch/mips/include/asm/system.h linux-2.6.32.4= 9/arch/mips/include/asm/system.h ---- linux-2.6.32.49/arch/mips/include/asm/system.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/mips/include/asm/system.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/mips/include/asm/system.h b/arch/mips/include/asm/syst= em.h +index 83b5509..9fa24a23 100644 +--- a/arch/mips/include/asm/system.h ++++ b/arch/mips/include/asm/system.h @@ -230,6 +230,6 @@ extern void per_cpu_trap_init(void); */ #define __ARCH_WANT_UNLOCKED_CTXSW @@ -1508,10 +1981,11 @@ diff -urNp linux-2.6.32.49/arch/mips/include/asm/= system.h linux-2.6.32.49/arch/m +#define arch_align_stack(x) ((x) & ~0xfUL) =20 #endif /* _ASM_SYSTEM_H */ -diff -urNp linux-2.6.32.49/arch/mips/kernel/binfmt_elfn32.c linux-2.6.32= .49/arch/mips/kernel/binfmt_elfn32.c ---- linux-2.6.32.49/arch/mips/kernel/binfmt_elfn32.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/mips/kernel/binfmt_elfn32.c 2011-11-15 19:59:42= .000000000 -0500 -@@ -50,6 +50,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_N +diff --git a/arch/mips/kernel/binfmt_elfn32.c b/arch/mips/kernel/binfmt_= elfn32.c +index 9fdd8bc..fcf9d68 100644 +--- a/arch/mips/kernel/binfmt_elfn32.c ++++ b/arch/mips/kernel/binfmt_elfn32.c +@@ -50,6 +50,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; #undef ELF_ET_DYN_BASE #define ELF_ET_DYN_BASE (TASK32_SIZE / 3 * 2) =20 @@ -1525,10 +1999,11 @@ diff -urNp linux-2.6.32.49/arch/mips/kernel/binfm= t_elfn32.c linux-2.6.32.49/arch #include #include #include -diff -urNp linux-2.6.32.49/arch/mips/kernel/binfmt_elfo32.c linux-2.6.32= .49/arch/mips/kernel/binfmt_elfo32.c ---- linux-2.6.32.49/arch/mips/kernel/binfmt_elfo32.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/mips/kernel/binfmt_elfo32.c 2011-11-15 19:59:42= .000000000 -0500 -@@ -52,6 +52,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_N +diff --git a/arch/mips/kernel/binfmt_elfo32.c b/arch/mips/kernel/binfmt_= elfo32.c +index ff44823..cf0b48a 100644 +--- a/arch/mips/kernel/binfmt_elfo32.c ++++ b/arch/mips/kernel/binfmt_elfo32.c +@@ -52,6 +52,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; #undef ELF_ET_DYN_BASE #define ELF_ET_DYN_BASE (TASK32_SIZE / 3 * 2) =20 @@ -1542,10 +2017,11 @@ diff -urNp linux-2.6.32.49/arch/mips/kernel/binfm= t_elfo32.c linux-2.6.32.49/arch #include =20 /* -diff -urNp linux-2.6.32.49/arch/mips/kernel/kgdb.c linux-2.6.32.49/arch/= mips/kernel/kgdb.c ---- linux-2.6.32.49/arch/mips/kernel/kgdb.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/mips/kernel/kgdb.c 2011-11-15 19:59:42.00000000= 0 -0500 -@@ -245,6 +245,7 @@ int kgdb_arch_handle_exception(int vecto +diff --git a/arch/mips/kernel/kgdb.c b/arch/mips/kernel/kgdb.c +index 50c9bb8..efdd5f8 100644 +--- a/arch/mips/kernel/kgdb.c ++++ b/arch/mips/kernel/kgdb.c +@@ -245,6 +245,7 @@ int kgdb_arch_handle_exception(int vector, int signo= , int err_code, return -1; } =20 @@ -1553,10 +2029,11 @@ diff -urNp linux-2.6.32.49/arch/mips/kernel/kgdb.= c linux-2.6.32.49/arch/mips/ker struct kgdb_arch arch_kgdb_ops; =20 /* -diff -urNp linux-2.6.32.49/arch/mips/kernel/process.c linux-2.6.32.49/ar= ch/mips/kernel/process.c ---- linux-2.6.32.49/arch/mips/kernel/process.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/mips/kernel/process.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -470,15 +470,3 @@ unsigned long get_wchan(struct task_stru +diff --git a/arch/mips/kernel/process.c b/arch/mips/kernel/process.c +index f3d73e1..bb3f57a 100644 +--- a/arch/mips/kernel/process.c ++++ b/arch/mips/kernel/process.c +@@ -470,15 +470,3 @@ unsigned long get_wchan(struct task_struct *task) out: return pc; } @@ -1572,9 +2049,10 @@ diff -urNp linux-2.6.32.49/arch/mips/kernel/proces= s.c linux-2.6.32.49/arch/mips/ - - return sp & ALMASK; -} -diff -urNp linux-2.6.32.49/arch/mips/kernel/reset.c linux-2.6.32.49/arch= /mips/kernel/reset.c ---- linux-2.6.32.49/arch/mips/kernel/reset.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/mips/kernel/reset.c 2011-11-15 19:59:42.0000000= 00 -0500 +diff --git a/arch/mips/kernel/reset.c b/arch/mips/kernel/reset.c +index 060563a..7fbf310 100644 +--- a/arch/mips/kernel/reset.c ++++ b/arch/mips/kernel/reset.c @@ -19,8 +19,8 @@ * So handle all using function pointers to machine specific * functions. @@ -1606,10 +2084,11 @@ diff -urNp linux-2.6.32.49/arch/mips/kernel/reset= .c linux-2.6.32.49/arch/mips/ke pm_power_off(); + BUG(); } -diff -urNp linux-2.6.32.49/arch/mips/kernel/syscall.c linux-2.6.32.49/ar= ch/mips/kernel/syscall.c ---- linux-2.6.32.49/arch/mips/kernel/syscall.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/mips/kernel/syscall.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -102,17 +102,21 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/mips/kernel/syscall.c b/arch/mips/kernel/syscall.c +index 3f7f466..3abe0b5 100644 +--- a/arch/mips/kernel/syscall.c ++++ b/arch/mips/kernel/syscall.c +@@ -102,17 +102,21 @@ unsigned long arch_get_unmapped_area(struct file *= filp, unsigned long addr, do_color_align =3D 0; if (filp || (flags & MAP_SHARED)) do_color_align =3D 1; @@ -1634,7 +2113,7 @@ diff -urNp linux-2.6.32.49/arch/mips/kernel/syscall= .c linux-2.6.32.49/arch/mips/ if (do_color_align) addr =3D COLOUR_ALIGN(addr, pgoff); else -@@ -122,7 +126,7 @@ unsigned long arch_get_unmapped_area(str +@@ -122,7 +126,7 @@ unsigned long arch_get_unmapped_area(struct file *fi= lp, unsigned long addr, /* At this point: (!vmm || addr < vmm->vm_end). */ if (task_size - len < addr) return -ENOMEM; @@ -1643,21 +2122,10 @@ diff -urNp linux-2.6.32.49/arch/mips/kernel/sysca= ll.c linux-2.6.32.49/arch/mips/ return addr; addr =3D vmm->vm_end; if (do_color_align) -diff -urNp linux-2.6.32.49/arch/mips/Makefile linux-2.6.32.49/arch/mips/= Makefile ---- linux-2.6.32.49/arch/mips/Makefile 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/mips/Makefile 2011-11-15 19:59:42.000000000 -05= 00 -@@ -51,6 +51,8 @@ endif - cflags-y :=3D -ffunction-sections - cflags-y +=3D $(call cc-option, -mno-check-zero-division) -=20 -+cflags-y +=3D -Wno-sign-compare -Wno-extra -+ - ifdef CONFIG_32BIT - ld-emul =3D $(32bit-emul) - vmlinux-32 =3D vmlinux -diff -urNp linux-2.6.32.49/arch/mips/mm/fault.c linux-2.6.32.49/arch/mip= s/mm/fault.c ---- linux-2.6.32.49/arch/mips/mm/fault.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/arch/mips/mm/fault.c 2011-11-18 18:01:52.000000000 -= 0500 +diff --git a/arch/mips/mm/fault.c b/arch/mips/mm/fault.c +index e97a7a2..f18f5b0 100644 +--- a/arch/mips/mm/fault.c ++++ b/arch/mips/mm/fault.c @@ -26,6 +26,23 @@ #include #include /* For VMALLOC_END */ @@ -1682,10 +2150,11 @@ diff -urNp linux-2.6.32.49/arch/mips/mm/fault.c l= inux-2.6.32.49/arch/mips/mm/fau /* * This routine handles page faults. It determines the address, * and the problem, and then passes it off to one of the appropriate -diff -urNp linux-2.6.32.49/arch/parisc/include/asm/elf.h linux-2.6.32.49= /arch/parisc/include/asm/elf.h ---- linux-2.6.32.49/arch/parisc/include/asm/elf.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/parisc/include/asm/elf.h 2011-11-15 19:59:42.00= 0000000 -0500 -@@ -343,6 +343,13 @@ struct pt_regs; /* forward declaration.. +diff --git a/arch/parisc/include/asm/elf.h b/arch/parisc/include/asm/elf= .h +index 9c802eb..0592e41 100644 +--- a/arch/parisc/include/asm/elf.h ++++ b/arch/parisc/include/asm/elf.h +@@ -343,6 +343,13 @@ struct pt_regs; /* forward declaration... */ =20 #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x01000000) =20 @@ -1699,9 +2168,10 @@ diff -urNp linux-2.6.32.49/arch/parisc/include/asm= /elf.h linux-2.6.32.49/arch/pa /* This yields a mask that user programs can use to figure out what instruction set this CPU supports. This could be done in user space= , but it's not easy, and we've already done it here. */ -diff -urNp linux-2.6.32.49/arch/parisc/include/asm/pgtable.h linux-2.6.3= 2.49/arch/parisc/include/asm/pgtable.h ---- linux-2.6.32.49/arch/parisc/include/asm/pgtable.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/parisc/include/asm/pgtable.h 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/parisc/include/asm/pgtable.h b/arch/parisc/include/asm= /pgtable.h +index a27d2e2..18fd845 100644 +--- a/arch/parisc/include/asm/pgtable.h ++++ b/arch/parisc/include/asm/pgtable.h @@ -207,6 +207,17 @@ #define PAGE_EXECREAD __pgprot(_PAGE_PRESENT | _PAGE_USER | _PAGE_REA= D | _PAGE_EXEC |_PAGE_ACCESSED) #define PAGE_COPY PAGE_EXECREAD @@ -1720,9 +2190,10 @@ diff -urNp linux-2.6.32.49/arch/parisc/include/asm= /pgtable.h linux-2.6.32.49/arc #define PAGE_KERNEL __pgprot(_PAGE_KERNEL) #define PAGE_KERNEL_RO __pgprot(_PAGE_KERNEL & ~_PAGE_WRITE) #define PAGE_KERNEL_UNC __pgprot(_PAGE_KERNEL | _PAGE_NO_CACHE) -diff -urNp linux-2.6.32.49/arch/parisc/kernel/module.c linux-2.6.32.49/a= rch/parisc/kernel/module.c ---- linux-2.6.32.49/arch/parisc/kernel/module.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/parisc/kernel/module.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/parisc/kernel/module.c b/arch/parisc/kernel/module.c +index 2120746..8d70a5e 100644 +--- a/arch/parisc/kernel/module.c ++++ b/arch/parisc/kernel/module.c @@ -95,16 +95,38 @@ =20 /* three functions to determine where in the module core @@ -1766,28 +2237,27 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/mod= ule.c linux-2.6.32.49/arch/pari } =20 static inline int in_local(struct module *me, void *loc) -@@ -364,13 +386,13 @@ int module_frob_arch_sections(CONST Elf_ +@@ -364,13 +386,13 @@ int module_frob_arch_sections(CONST Elf_Ehdr *hdr, } =20 /* align things a bit */ - me->core_size =3D ALIGN(me->core_size, 16); - me->arch.got_offset =3D me->core_size; - me->core_size +=3D gots * sizeof(struct got_entry); -- -- me->core_size =3D ALIGN(me->core_size, 16); -- me->arch.fdesc_offset =3D me->core_size; -- me->core_size +=3D fdescs * sizeof(Elf_Fdesc); + me->core_size_rw =3D ALIGN(me->core_size_rw, 16); + me->arch.got_offset =3D me->core_size_rw; + me->core_size_rw +=3D gots * sizeof(struct got_entry); -+ +=20 +- me->core_size =3D ALIGN(me->core_size, 16); +- me->arch.fdesc_offset =3D me->core_size; +- me->core_size +=3D fdescs * sizeof(Elf_Fdesc); + me->core_size_rw =3D ALIGN(me->core_size_rw, 16); + me->arch.fdesc_offset =3D me->core_size_rw; + me->core_size_rw +=3D fdescs * sizeof(Elf_Fdesc); =20 me->arch.got_max =3D gots; me->arch.fdesc_max =3D fdescs; -@@ -388,7 +410,7 @@ static Elf64_Word get_got(struct module=20 +@@ -388,7 +410,7 @@ static Elf64_Word get_got(struct module *me, unsigne= d long value, long addend) =20 BUG_ON(value =3D=3D 0); =20 @@ -1796,7 +2266,7 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/modul= e.c linux-2.6.32.49/arch/pari for (i =3D 0; got[i].addr; i++) if (got[i].addr =3D=3D value) goto out; -@@ -406,7 +428,7 @@ static Elf64_Word get_got(struct module=20 +@@ -406,7 +428,7 @@ static Elf64_Word get_got(struct module *me, unsigne= d long value, long addend) #ifdef CONFIG_64BIT static Elf_Addr get_fdesc(struct module *me, unsigned long value) { @@ -1805,7 +2275,7 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/modul= e.c linux-2.6.32.49/arch/pari =20 if (!value) { printk(KERN_ERR "%s: zero OPD requested!\n", me->name); -@@ -424,7 +446,7 @@ static Elf_Addr get_fdesc(struct module=20 +@@ -424,7 +446,7 @@ static Elf_Addr get_fdesc(struct module *me, unsigne= d long value) =20 /* Create new one */ fdesc->addr =3D value; @@ -1823,10 +2293,11 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/mod= ule.c linux-2.6.32.49/arch/pari =20 DEBUGP("register_unwind_table(), sect =3D %d at 0x%p - 0x%p (gp=3D0x%l= x)\n", me->arch.unwind_section, table, end, gp); -diff -urNp linux-2.6.32.49/arch/parisc/kernel/sys_parisc.c linux-2.6.32.= 49/arch/parisc/kernel/sys_parisc.c ---- linux-2.6.32.49/arch/parisc/kernel/sys_parisc.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/parisc/kernel/sys_parisc.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -43,7 +43,7 @@ static unsigned long get_unshared_area(u +diff --git a/arch/parisc/kernel/sys_parisc.c b/arch/parisc/kernel/sys_pa= risc.c +index 9147391..f3d949a 100644 +--- a/arch/parisc/kernel/sys_parisc.c ++++ b/arch/parisc/kernel/sys_parisc.c +@@ -43,7 +43,7 @@ static unsigned long get_unshared_area(unsigned long a= ddr, unsigned long len) /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1835,7 +2306,7 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/sys_p= arisc.c linux-2.6.32.49/arch/ return addr; addr =3D vma->vm_end; } -@@ -79,7 +79,7 @@ static unsigned long get_shared_area(str +@@ -79,7 +79,7 @@ static unsigned long get_shared_area(struct address_sp= ace *mapping, /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1844,7 +2315,7 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/sys_p= arisc.c linux-2.6.32.49/arch/ return addr; addr =3D DCACHE_ALIGN(vma->vm_end - offset) + offset; if (addr < vma->vm_end) /* handle wraparound */ -@@ -98,7 +98,7 @@ unsigned long arch_get_unmapped_area(str +@@ -98,7 +98,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, if (flags & MAP_FIXED) return addr; if (!addr) @@ -1853,10 +2324,11 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/sys= _parisc.c linux-2.6.32.49/arch/ =20 if (filp) { addr =3D get_shared_area(filp->f_mapping, addr, len, pgoff); -diff -urNp linux-2.6.32.49/arch/parisc/kernel/traps.c linux-2.6.32.49/ar= ch/parisc/kernel/traps.c ---- linux-2.6.32.49/arch/parisc/kernel/traps.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/parisc/kernel/traps.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -733,9 +733,7 @@ void notrace handle_interruption(int cod +diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c +index 8b58bf0..7afff03 100644 +--- a/arch/parisc/kernel/traps.c ++++ b/arch/parisc/kernel/traps.c +@@ -733,9 +733,7 @@ void notrace handle_interruption(int code, struct pt= _regs *regs) =20 down_read(¤t->mm->mmap_sem); vma =3D find_vma(current->mm,regs->iaoq[0]); @@ -1867,9 +2339,10 @@ diff -urNp linux-2.6.32.49/arch/parisc/kernel/trap= s.c linux-2.6.32.49/arch/paris fault_address =3D regs->iaoq[0]; fault_space =3D regs->iasq[0]; =20 -diff -urNp linux-2.6.32.49/arch/parisc/mm/fault.c linux-2.6.32.49/arch/p= arisc/mm/fault.c ---- linux-2.6.32.49/arch/parisc/mm/fault.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/parisc/mm/fault.c 2011-11-18 18:01:52.000000000= -0500 +diff --git a/arch/parisc/mm/fault.c b/arch/parisc/mm/fault.c +index c6afbfc..c5839f6 100644 +--- a/arch/parisc/mm/fault.c ++++ b/arch/parisc/mm/fault.c @@ -15,6 +15,7 @@ #include #include @@ -1878,7 +2351,7 @@ diff -urNp linux-2.6.32.49/arch/parisc/mm/fault.c l= inux-2.6.32.49/arch/parisc/mm =20 #include #include -@@ -52,7 +53,7 @@ DEFINE_PER_CPU(struct exception_data, ex +@@ -52,7 +53,7 @@ DEFINE_PER_CPU(struct exception_data, exception_data); static unsigned long parisc_acctyp(unsigned long code, unsigned int inst) { @@ -1887,7 +2360,7 @@ diff -urNp linux-2.6.32.49/arch/parisc/mm/fault.c l= inux-2.6.32.49/arch/parisc/mm return VM_EXEC; =20 switch (inst & 0xf0000000) { -@@ -138,6 +139,116 @@ parisc_acctyp(unsigned long code, unsign +@@ -138,6 +139,116 @@ parisc_acctyp(unsigned long code, unsigned int ins= t) } #endif =20 @@ -2039,9 +2512,23 @@ diff -urNp linux-2.6.32.49/arch/parisc/mm/fault.c = linux-2.6.32.49/arch/parisc/mm =20 /* * If for any reason at all we couldn't handle the fault, make -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/device.h linux-2.6.3= 2.49/arch/powerpc/include/asm/device.h ---- linux-2.6.32.49/arch/powerpc/include/asm/device.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/device.h 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile +index c107b74..409dc0f 100644 +--- a/arch/powerpc/Makefile ++++ b/arch/powerpc/Makefile +@@ -74,6 +74,8 @@ KBUILD_AFLAGS +=3D -Iarch/$(ARCH) + KBUILD_CFLAGS +=3D -msoft-float -pipe -Iarch/$(ARCH) $(CFLAGS-y) + CPP =3D $(CC) -E $(KBUILD_CFLAGS) +=20 ++cflags-y +=3D -Wno-sign-compare -Wno-extra ++ + CHECKFLAGS +=3D -m$(CONFIG_WORD_SIZE) -D__powerpc__ -D__powerpc$(CONFIG= _WORD_SIZE)__ +=20 + ifeq ($(CONFIG_PPC64),y) +diff --git a/arch/powerpc/include/asm/device.h b/arch/powerpc/include/as= m/device.h +index 6d94d27..50d4cad 100644 +--- a/arch/powerpc/include/asm/device.h ++++ b/arch/powerpc/include/asm/device.h @@ -14,7 +14,7 @@ struct dev_archdata { struct device_node *of_node; =20 @@ -2051,10 +2538,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/device.h linux-2.6.32.49/arc =20 /* * When an iommu is in use, dma_data is used as a ptr to the base of t= he -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/dma-mapping.h linux-= 2.6.32.49/arch/powerpc/include/asm/dma-mapping.h ---- linux-2.6.32.49/arch/powerpc/include/asm/dma-mapping.h 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/dma-mapping.h 2011-11-15 19= :59:42.000000000 -0500 -@@ -69,9 +69,9 @@ static inline unsigned long device_to_ma +diff --git a/arch/powerpc/include/asm/dma-mapping.h b/arch/powerpc/inclu= de/asm/dma-mapping.h +index e281dae..2b8a784 100644 +--- a/arch/powerpc/include/asm/dma-mapping.h ++++ b/arch/powerpc/include/asm/dma-mapping.h +@@ -69,9 +69,9 @@ static inline unsigned long device_to_mask(struct devi= ce *dev) #ifdef CONFIG_PPC64 extern struct dma_map_ops dma_iommu_ops; #endif @@ -2066,7 +2554,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /dma-mapping.h linux-2.6.32.4 { /* We don't handle the NULL dev case for ISA for now. We could * do it via an out of line call but it is not needed for now. The -@@ -84,7 +84,7 @@ static inline struct dma_map_ops *get_dm +@@ -84,7 +84,7 @@ static inline struct dma_map_ops *get_dma_ops(struct d= evice *dev) return dev->archdata.dma_ops; } =20 @@ -2075,7 +2563,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /dma-mapping.h linux-2.6.32.4 { dev->archdata.dma_ops =3D ops; } -@@ -118,7 +118,7 @@ static inline void set_dma_offset(struct +@@ -118,7 +118,7 @@ static inline void set_dma_offset(struct device *dev= , dma_addr_t off) =20 static inline int dma_supported(struct device *dev, u64 mask) { @@ -2084,7 +2572,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /dma-mapping.h linux-2.6.32.4 =20 if (unlikely(dma_ops =3D=3D NULL)) return 0; -@@ -132,7 +132,7 @@ static inline int dma_supported(struct d +@@ -132,7 +132,7 @@ static inline int dma_supported(struct device *dev, = u64 mask) =20 static inline int dma_set_mask(struct device *dev, u64 dma_mask) { @@ -2093,7 +2581,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /dma-mapping.h linux-2.6.32.4 =20 if (unlikely(dma_ops =3D=3D NULL)) return -EIO; -@@ -147,7 +147,7 @@ static inline int dma_set_mask(struct de +@@ -147,7 +147,7 @@ static inline int dma_set_mask(struct device *dev, u= 64 dma_mask) static inline void *dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *dma_handle, gfp_t flag) { @@ -2102,7 +2590,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /dma-mapping.h linux-2.6.32.4 void *cpu_addr; =20 BUG_ON(!dma_ops); -@@ -162,7 +162,7 @@ static inline void *dma_alloc_coherent(s +@@ -162,7 +162,7 @@ static inline void *dma_alloc_coherent(struct device= *dev, size_t size, static inline void dma_free_coherent(struct device *dev, size_t size, void *cpu_addr, dma_addr_t dma_handle) { @@ -2111,7 +2599,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /dma-mapping.h linux-2.6.32.4 =20 BUG_ON(!dma_ops); =20 -@@ -173,7 +173,7 @@ static inline void dma_free_coherent(str +@@ -173,7 +173,7 @@ static inline void dma_free_coherent(struct device *= dev, size_t size, =20 static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_= addr) { @@ -2120,10 +2608,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/dma-mapping.h linux-2.6.32.4 =20 if (dma_ops->mapping_error) return dma_ops->mapping_error(dev, dma_addr); -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/elf.h linux-2.6.32.4= 9/arch/powerpc/include/asm/elf.h ---- linux-2.6.32.49/arch/powerpc/include/asm/elf.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/elf.h 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -179,8 +179,19 @@ typedef elf_fpreg_t elf_vsrreghalf_t32[E +diff --git a/arch/powerpc/include/asm/elf.h b/arch/powerpc/include/asm/e= lf.h +index 5698502..5db093c 100644 +--- a/arch/powerpc/include/asm/elf.h ++++ b/arch/powerpc/include/asm/elf.h +@@ -179,8 +179,19 @@ typedef elf_fpreg_t elf_vsrreghalf_t32[ELF_NVSRHALF= REG]; the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ =20 @@ -2145,7 +2634,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /elf.h linux-2.6.32.49/arch/p =20 /* * Our registers are always unsigned longs, whether we're a 32 bit -@@ -275,9 +286,6 @@ extern int arch_setup_additional_pages(s +@@ -275,9 +286,6 @@ extern int arch_setup_additional_pages(struct linux_= binprm *bprm, (0x7ff >> (PAGE_SHIFT - 12)) : \ (0x3ffff >> (PAGE_SHIFT - 12))) =20 @@ -2155,10 +2644,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/elf.h linux-2.6.32.49/arch/p #endif /* __KERNEL__ */ =20 /* -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/iommu.h linux-2.6.32= .49/arch/powerpc/include/asm/iommu.h ---- linux-2.6.32.49/arch/powerpc/include/asm/iommu.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/iommu.h 2011-11-15 19:59:42= .000000000 -0500 -@@ -116,6 +116,9 @@ extern void iommu_init_early_iSeries(voi +diff --git a/arch/powerpc/include/asm/iommu.h b/arch/powerpc/include/asm= /iommu.h +index edfc980..1766f59 100644 +--- a/arch/powerpc/include/asm/iommu.h ++++ b/arch/powerpc/include/asm/iommu.h +@@ -116,6 +116,9 @@ extern void iommu_init_early_iSeries(void); extern void iommu_init_early_dart(void); extern void iommu_init_early_pasemi(void); =20 @@ -2168,9 +2658,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/as= m/iommu.h linux-2.6.32.49/arch #ifdef CONFIG_PCI extern void pci_iommu_init(void); extern void pci_direct_iommu_init(void); -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/kmap_types.h linux-2= .6.32.49/arch/powerpc/include/asm/kmap_types.h ---- linux-2.6.32.49/arch/powerpc/include/asm/kmap_types.h 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/kmap_types.h 2011-11-15 19:= 59:42.000000000 -0500 +diff --git a/arch/powerpc/include/asm/kmap_types.h b/arch/powerpc/includ= e/asm/kmap_types.h +index 9163695..5a00112 100644 +--- a/arch/powerpc/include/asm/kmap_types.h ++++ b/arch/powerpc/include/asm/kmap_types.h @@ -26,6 +26,7 @@ enum km_type { KM_SOFTIRQ1, KM_PPC_SYNC_PAGE, @@ -2179,33 +2670,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/kmap_types.h linux-2.6.32.49 KM_TYPE_NR }; =20 -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/page_64.h linux-2.6.= 32.49/arch/powerpc/include/asm/page_64.h ---- linux-2.6.32.49/arch/powerpc/include/asm/page_64.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/page_64.h 2011-11-15 19:59:= 42.000000000 -0500 -@@ -180,15 +180,18 @@ do { \ - * stack by default, so in the absense of a PT_GNU_STACK program header - * we turn execute permission off. - */ --#define VM_STACK_DEFAULT_FLAGS32 (VM_READ | VM_WRITE | VM_EXEC | \ -- VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) -+#define VM_STACK_DEFAULT_FLAGS32 \ -+ (((current->personality & READ_IMPLIES_EXEC) ? VM_EXEC : 0) | \ -+ VM_READ | VM_WRITE | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) -=20 - #define VM_STACK_DEFAULT_FLAGS64 (VM_READ | VM_WRITE | \ - VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) -=20 -+#ifndef CONFIG_PAX_PAGEEXEC - #define VM_STACK_DEFAULT_FLAGS \ - (test_thread_flag(TIF_32BIT) ? \ - VM_STACK_DEFAULT_FLAGS32 : VM_STACK_DEFAULT_FLAGS64) -+#endif -=20 - #include -=20 -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/page.h linux-2.6.32.= 49/arch/powerpc/include/asm/page.h ---- linux-2.6.32.49/arch/powerpc/include/asm/page.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/page.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/powerpc/include/asm/page.h b/arch/powerpc/include/asm/= page.h +index ff24254..fe45b21 100644 +--- a/arch/powerpc/include/asm/page.h ++++ b/arch/powerpc/include/asm/page.h @@ -116,8 +116,9 @@ extern phys_addr_t kernstart_addr; * and needs to be executable. This means the whole heap ends * up being executable. @@ -2228,10 +2696,36 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/page.h linux-2.6.32.49/arch/ #ifndef __ASSEMBLY__ =20 #undef STRICT_MM_TYPECHECKS -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/pci.h linux-2.6.32.4= 9/arch/powerpc/include/asm/pci.h ---- linux-2.6.32.49/arch/powerpc/include/asm/pci.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/pci.h 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -65,8 +65,8 @@ static inline int pci_get_legacy_ide_irq +diff --git a/arch/powerpc/include/asm/page_64.h b/arch/powerpc/include/a= sm/page_64.h +index 3f17b83..1f9e766 100644 +--- a/arch/powerpc/include/asm/page_64.h ++++ b/arch/powerpc/include/asm/page_64.h +@@ -180,15 +180,18 @@ do { \ + * stack by default, so in the absense of a PT_GNU_STACK program header + * we turn execute permission off. + */ +-#define VM_STACK_DEFAULT_FLAGS32 (VM_READ | VM_WRITE | VM_EXEC | \ +- VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) ++#define VM_STACK_DEFAULT_FLAGS32 \ ++ (((current->personality & READ_IMPLIES_EXEC) ? VM_EXEC : 0) | \ ++ VM_READ | VM_WRITE | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) +=20 + #define VM_STACK_DEFAULT_FLAGS64 (VM_READ | VM_WRITE | \ + VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) +=20 ++#ifndef CONFIG_PAX_PAGEEXEC + #define VM_STACK_DEFAULT_FLAGS \ + (test_thread_flag(TIF_32BIT) ? \ + VM_STACK_DEFAULT_FLAGS32 : VM_STACK_DEFAULT_FLAGS64) ++#endif +=20 + #include +=20 +diff --git a/arch/powerpc/include/asm/pci.h b/arch/powerpc/include/asm/p= ci.h +index b5ea626..4030822 100644 +--- a/arch/powerpc/include/asm/pci.h ++++ b/arch/powerpc/include/asm/pci.h +@@ -65,8 +65,8 @@ static inline int pci_get_legacy_ide_irq(struct pci_de= v *dev, int channel) } =20 #ifdef CONFIG_PCI @@ -2242,9 +2736,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/as= m/pci.h linux-2.6.32.49/arch/p #else /* CONFIG_PCI */ #define set_pci_dma_ops(d) #define get_pci_dma_ops() NULL -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/pgtable.h linux-2.6.= 32.49/arch/powerpc/include/asm/pgtable.h ---- linux-2.6.32.49/arch/powerpc/include/asm/pgtable.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/pgtable.h 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/powerpc/include/asm/pgtable.h b/arch/powerpc/include/a= sm/pgtable.h +index 2a5da06..d65bea2 100644 +--- a/arch/powerpc/include/asm/pgtable.h ++++ b/arch/powerpc/include/asm/pgtable.h @@ -2,6 +2,7 @@ #define _ASM_POWERPC_PGTABLE_H #ifdef __KERNEL__ @@ -2253,9 +2748,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/as= m/pgtable.h linux-2.6.32.49/ar #ifndef __ASSEMBLY__ #include /* For TASK_SIZE */ #include -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/pte-hash32.h linux-2= .6.32.49/arch/powerpc/include/asm/pte-hash32.h ---- linux-2.6.32.49/arch/powerpc/include/asm/pte-hash32.h 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/pte-hash32.h 2011-11-15 19:= 59:42.000000000 -0500 +diff --git a/arch/powerpc/include/asm/pte-hash32.h b/arch/powerpc/includ= e/asm/pte-hash32.h +index 4aad413..85d86bf 100644 +--- a/arch/powerpc/include/asm/pte-hash32.h ++++ b/arch/powerpc/include/asm/pte-hash32.h @@ -21,6 +21,7 @@ #define _PAGE_FILE 0x004 /* when !present: nonlinear file mapping */ #define _PAGE_USER 0x004 /* usermode access allowed */ @@ -2264,10 +2760,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/pte-hash32.h linux-2.6.32.49 #define _PAGE_COHERENT 0x010 /* M: enforce memory coherence (SMP system= s) */ #define _PAGE_NO_CACHE 0x020 /* I: cache inhibit */ #define _PAGE_WRITETHRU 0x040 /* W: cache write-through */ -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/ptrace.h linux-2.6.3= 2.49/arch/powerpc/include/asm/ptrace.h ---- linux-2.6.32.49/arch/powerpc/include/asm/ptrace.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/ptrace.h 2011-11-15 19:59:4= 2.000000000 -0500 -@@ -103,7 +103,7 @@ extern unsigned long profile_pc(struct p +diff --git a/arch/powerpc/include/asm/ptrace.h b/arch/powerpc/include/as= m/ptrace.h +index 8c34149..78f425a 100644 +--- a/arch/powerpc/include/asm/ptrace.h ++++ b/arch/powerpc/include/asm/ptrace.h +@@ -103,7 +103,7 @@ extern unsigned long profile_pc(struct pt_regs *regs= ); } while(0) =20 struct task_struct; @@ -2276,9 +2773,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/as= m/ptrace.h linux-2.6.32.49/arc extern int ptrace_put_reg(struct task_struct *task, int regno, unsigned long data); =20 -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/reg.h linux-2.6.32.4= 9/arch/powerpc/include/asm/reg.h ---- linux-2.6.32.49/arch/powerpc/include/asm/reg.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/reg.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/r= eg.h +index 32a7c30..be3a8bb 100644 +--- a/arch/powerpc/include/asm/reg.h ++++ b/arch/powerpc/include/asm/reg.h @@ -191,6 +191,7 @@ #define SPRN_DBCR 0x136 /* e300 Data Breakpoint Control Reg */ #define SPRN_DSISR 0x012 /* Data Storage Interrupt Status Register */ @@ -2287,9 +2785,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/as= m/reg.h linux-2.6.32.49/arch/p #define DSISR_PROTFAULT 0x08000000 /* protection fault */ #define DSISR_ISSTORE 0x02000000 /* access was a store */ #define DSISR_DABRMATCH 0x00400000 /* hit data breakpoint */ -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/swiotlb.h linux-2.6.= 32.49/arch/powerpc/include/asm/swiotlb.h ---- linux-2.6.32.49/arch/powerpc/include/asm/swiotlb.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/swiotlb.h 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/powerpc/include/asm/swiotlb.h b/arch/powerpc/include/a= sm/swiotlb.h +index 8979d4c..d2fd0d3 100644 +--- a/arch/powerpc/include/asm/swiotlb.h ++++ b/arch/powerpc/include/asm/swiotlb.h @@ -13,7 +13,7 @@ =20 #include @@ -2299,10 +2798,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/swiotlb.h linux-2.6.32.49/ar =20 static inline void dma_mark_clean(void *addr, size_t size) {} =20 -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/system.h linux-2.6.3= 2.49/arch/powerpc/include/asm/system.h ---- linux-2.6.32.49/arch/powerpc/include/asm/system.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/system.h 2011-11-15 19:59:4= 2.000000000 -0500 -@@ -531,7 +531,7 @@ __cmpxchg_local(volatile void *ptr, unsi +diff --git a/arch/powerpc/include/asm/system.h b/arch/powerpc/include/as= m/system.h +index 094a12a..877a60a 100644 +--- a/arch/powerpc/include/asm/system.h ++++ b/arch/powerpc/include/asm/system.h +@@ -531,7 +531,7 @@ __cmpxchg_local(volatile void *ptr, unsigned long ol= d, unsigned long new, #define cmpxchg64_local(ptr, o, n) __cmpxchg64_local_generic((ptr), (o)= , (n)) #endif =20 @@ -2311,9 +2811,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/as= m/system.h linux-2.6.32.49/arc =20 /* Used in very early kernel initialization. */ extern unsigned long reloc_offset(void); -diff -urNp linux-2.6.32.49/arch/powerpc/include/asm/uaccess.h linux-2.6.= 32.49/arch/powerpc/include/asm/uaccess.h ---- linux-2.6.32.49/arch/powerpc/include/asm/uaccess.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/include/asm/uaccess.h 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/powerpc/include/asm/uaccess.h b/arch/powerpc/include/a= sm/uaccess.h +index bd0fb84..a42a14b 100644 +--- a/arch/powerpc/include/asm/uaccess.h ++++ b/arch/powerpc/include/asm/uaccess.h @@ -13,6 +13,8 @@ #define VERIFY_READ 0 #define VERIFY_WRITE 1 @@ -2376,7 +2877,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /uaccess.h linux-2.6.32.49/ar static inline unsigned long __copy_from_user_inatomic(void *to, const void __user *from, unsigned long n) { -@@ -396,6 +352,10 @@ static inline unsigned long __copy_from_ +@@ -396,6 +352,10 @@ static inline unsigned long __copy_from_user_inatom= ic(void *to, if (ret =3D=3D 0) return 0; } @@ -2387,7 +2888,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /uaccess.h linux-2.6.32.49/ar return __copy_tofrom_user((__force void __user *)to, from, n); } =20 -@@ -422,6 +382,10 @@ static inline unsigned long __copy_to_us +@@ -422,6 +382,10 @@ static inline unsigned long __copy_to_user_inatomic= (void __user *to, if (ret =3D=3D 0) return 0; } @@ -2398,7 +2899,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/asm= /uaccess.h linux-2.6.32.49/ar return __copy_tofrom_user(to, (__force const void __user *)from, n); } =20 -@@ -439,6 +403,92 @@ static inline unsigned long __copy_to_us +@@ -439,6 +403,92 @@ static inline unsigned long __copy_to_user(void __u= ser *to, return __copy_to_user_inatomic(to, from, size); } =20 @@ -2491,10 +2992,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/include/a= sm/uaccess.h linux-2.6.32.49/ar extern unsigned long __clear_user(void __user *addr, unsigned long size= ); =20 static inline unsigned long clear_user(void __user *addr, unsigned long= size) -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/cacheinfo.c linux-2.6.32.= 49/arch/powerpc/kernel/cacheinfo.c ---- linux-2.6.32.49/arch/powerpc/kernel/cacheinfo.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/cacheinfo.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -642,7 +642,7 @@ static struct kobj_attribute *cache_inde +diff --git a/arch/powerpc/kernel/cacheinfo.c b/arch/powerpc/kernel/cache= info.c +index bb37b1d..01fe9ce 100644 +--- a/arch/powerpc/kernel/cacheinfo.c ++++ b/arch/powerpc/kernel/cacheinfo.c +@@ -642,7 +642,7 @@ static struct kobj_attribute *cache_index_opt_attrs[= ] =3D { &cache_assoc_attr, }; =20 @@ -2503,22 +3005,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/ca= cheinfo.c linux-2.6.32.49/arch/ .show =3D cache_index_show, }; =20 -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/dma.c linux-2.6.32.49/arc= h/powerpc/kernel/dma.c ---- linux-2.6.32.49/arch/powerpc/kernel/dma.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/dma.c 2011-11-15 19:59:42.000000= 000 -0500 -@@ -134,7 +134,7 @@ static inline void dma_direct_sync_singl - } - #endif -=20 --struct dma_map_ops dma_direct_ops =3D { -+const struct dma_map_ops dma_direct_ops =3D { - .alloc_coherent =3D dma_direct_alloc_coherent, - .free_coherent =3D dma_direct_free_coherent, - .map_sg =3D dma_direct_map_sg, -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/dma-iommu.c linux-2.6.32.= 49/arch/powerpc/kernel/dma-iommu.c ---- linux-2.6.32.49/arch/powerpc/kernel/dma-iommu.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/dma-iommu.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -70,7 +70,7 @@ static void dma_iommu_unmap_sg(struct de +diff --git a/arch/powerpc/kernel/dma-iommu.c b/arch/powerpc/kernel/dma-i= ommu.c +index 37771a5..648530c 100644 +--- a/arch/powerpc/kernel/dma-iommu.c ++++ b/arch/powerpc/kernel/dma-iommu.c +@@ -70,7 +70,7 @@ static void dma_iommu_unmap_sg(struct device *dev, str= uct scatterlist *sglist, } =20 /* We support DMA to/from any memory page via the iommu */ @@ -2527,9 +3018,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/dma= -iommu.c linux-2.6.32.49/arch/ { struct iommu_table *tbl =3D get_iommu_table_base(dev); =20 -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/dma-swiotlb.c linux-2.6.3= 2.49/arch/powerpc/kernel/dma-swiotlb.c ---- linux-2.6.32.49/arch/powerpc/kernel/dma-swiotlb.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/dma-swiotlb.c 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/powerpc/kernel/dma-swiotlb.c b/arch/powerpc/kernel/dma= -swiotlb.c +index e96cbbd..bdd6d41 100644 +--- a/arch/powerpc/kernel/dma-swiotlb.c ++++ b/arch/powerpc/kernel/dma-swiotlb.c @@ -31,7 +31,7 @@ unsigned int ppc_swiotlb_enable; * map_page, and unmap_page on highmem, use normal dma_ops * for everything else. @@ -2539,9 +3031,23 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/dma= -swiotlb.c linux-2.6.32.49/arc .alloc_coherent =3D dma_direct_alloc_coherent, .free_coherent =3D dma_direct_free_coherent, .map_sg =3D swiotlb_map_sg_attrs, -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/exceptions-64e.S linux-2.= 6.32.49/arch/powerpc/kernel/exceptions-64e.S ---- linux-2.6.32.49/arch/powerpc/kernel/exceptions-64e.S 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/exceptions-64e.S 2011-11-15 19:5= 9:42.000000000 -0500 +diff --git a/arch/powerpc/kernel/dma.c b/arch/powerpc/kernel/dma.c +index 6215062..ebea59c 100644 +--- a/arch/powerpc/kernel/dma.c ++++ b/arch/powerpc/kernel/dma.c +@@ -134,7 +134,7 @@ static inline void dma_direct_sync_single_range(stru= ct device *dev, + } + #endif +=20 +-struct dma_map_ops dma_direct_ops =3D { ++const struct dma_map_ops dma_direct_ops =3D { + .alloc_coherent =3D dma_direct_alloc_coherent, + .free_coherent =3D dma_direct_free_coherent, + .map_sg =3D dma_direct_map_sg, +diff --git a/arch/powerpc/kernel/exceptions-64e.S b/arch/powerpc/kernel/= exceptions-64e.S +index 24dcc0e..a300455 100644 +--- a/arch/powerpc/kernel/exceptions-64e.S ++++ b/arch/powerpc/kernel/exceptions-64e.S @@ -455,6 +455,7 @@ storage_fault_common: std r14,_DAR(r1) std r15,_DSISR(r1) @@ -2560,9 +3066,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/exc= eptions-64e.S linux-2.6.32.49/ addi r3,r1,STACK_FRAME_OVERHEAD ld r4,_DAR(r1) bl .bad_page_fault -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/exceptions-64s.S linux-2.= 6.32.49/arch/powerpc/kernel/exceptions-64s.S ---- linux-2.6.32.49/arch/powerpc/kernel/exceptions-64s.S 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/exceptions-64s.S 2011-11-15 19:5= 9:42.000000000 -0500 +diff --git a/arch/powerpc/kernel/exceptions-64s.S b/arch/powerpc/kernel/= exceptions-64s.S +index 1808876..9fd206a 100644 +--- a/arch/powerpc/kernel/exceptions-64s.S ++++ b/arch/powerpc/kernel/exceptions-64s.S @@ -818,10 +818,10 @@ handle_page_fault: 11: ld r4,_DAR(r1) ld r5,_DSISR(r1) @@ -2575,10 +3082,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/ex= ceptions-64s.S linux-2.6.32.49/ mr r5,r3 addi r3,r1,STACK_FRAME_OVERHEAD lwz r4,_DAR(r1) -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/ibmebus.c linux-2.6.32.49= /arch/powerpc/kernel/ibmebus.c ---- linux-2.6.32.49/arch/powerpc/kernel/ibmebus.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/ibmebus.c 2011-11-15 19:59:42.00= 0000000 -0500 -@@ -127,7 +127,7 @@ static int ibmebus_dma_supported(struct=20 +diff --git a/arch/powerpc/kernel/ibmebus.c b/arch/powerpc/kernel/ibmebus= .c +index a4c8b38..1b09ad9 100644 +--- a/arch/powerpc/kernel/ibmebus.c ++++ b/arch/powerpc/kernel/ibmebus.c +@@ -127,7 +127,7 @@ static int ibmebus_dma_supported(struct device *dev,= u64 mask) return 1; } =20 @@ -2587,10 +3095,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/ib= mebus.c linux-2.6.32.49/arch/po .alloc_coherent =3D ibmebus_alloc_coherent, .free_coherent =3D ibmebus_free_coherent, .map_sg =3D ibmebus_map_sg, -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/kgdb.c linux-2.6.32.49/ar= ch/powerpc/kernel/kgdb.c ---- linux-2.6.32.49/arch/powerpc/kernel/kgdb.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/kgdb.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -126,7 +126,7 @@ static int kgdb_handle_breakpoint(struct +diff --git a/arch/powerpc/kernel/kgdb.c b/arch/powerpc/kernel/kgdb.c +index 641c74b..8339ad7 100644 +--- a/arch/powerpc/kernel/kgdb.c ++++ b/arch/powerpc/kernel/kgdb.c +@@ -126,7 +126,7 @@ static int kgdb_handle_breakpoint(struct pt_regs *re= gs) if (kgdb_handle_exception(0, SIGTRAP, 0, regs) !=3D 0) return 0; =20 @@ -2599,7 +3108,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/kgdb= .c linux-2.6.32.49/arch/power regs->nip +=3D 4; =20 return 1; -@@ -353,7 +353,7 @@ int kgdb_arch_handle_exception(int vecto +@@ -353,7 +353,7 @@ int kgdb_arch_handle_exception(int vector, int signo= , int err_code, /* * Global data */ @@ -2608,41 +3117,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/kg= db.c linux-2.6.32.49/arch/power .gdb_bpt_instr =3D {0x7d, 0x82, 0x10, 0x08}, }; =20 -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/module_32.c linux-2.6.32.= 49/arch/powerpc/kernel/module_32.c ---- linux-2.6.32.49/arch/powerpc/kernel/module_32.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/module_32.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -162,7 +162,7 @@ int module_frob_arch_sections(Elf32_Ehdr - me->arch.core_plt_section =3D i; - } - if (!me->arch.core_plt_section || !me->arch.init_plt_section) { -- printk("Module doesn't contain .plt or .init.plt sections.\n"); -+ printk("Module %s doesn't contain .plt or .init.plt sections.\n", me-= >name); - return -ENOEXEC; - } -=20 -@@ -203,11 +203,16 @@ static uint32_t do_plt_call(void *locati -=20 - DEBUGP("Doing plt for call to 0x%x at 0x%x\n", val, (unsigned int)loca= tion); - /* Init, or core PLT? */ -- if (location >=3D mod->module_core -- && location < mod->module_core + mod->core_size) -+ if ((location >=3D mod->module_core_rx && location < mod->module_core_= rx + mod->core_size_rx) || -+ (location >=3D mod->module_core_rw && location < mod->module_core_= rw + mod->core_size_rw)) - entry =3D (void *)sechdrs[mod->arch.core_plt_section].sh_addr; -- else -+ else if ((location >=3D mod->module_init_rx && location < mod->module_= init_rx + mod->init_size_rx) || -+ (location >=3D mod->module_init_rw && location < mod->module_init_rw= + mod->init_size_rw)) - entry =3D (void *)sechdrs[mod->arch.init_plt_section].sh_addr; -+ else { -+ printk(KERN_ERR "%s: invalid R_PPC_REL24 entry found\n", mod->name); -+ return ~0UL; -+ } -=20 - /* Find this entry, or if that fails, the next avail. entry */ - while (entry->jump[0]) { -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/module.c linux-2.6.32.49/= arch/powerpc/kernel/module.c ---- linux-2.6.32.49/arch/powerpc/kernel/module.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/module.c 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/powerpc/kernel/module.c b/arch/powerpc/kernel/module.c +index 477c663..4f50234 100644 +--- a/arch/powerpc/kernel/module.c ++++ b/arch/powerpc/kernel/module.c @@ -31,11 +31,24 @@ =20 LIST_HEAD(module_bug_list); @@ -2668,7 +3146,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/modu= le.c linux-2.6.32.49/arch/pow return vmalloc_exec(size); } =20 -@@ -45,6 +58,13 @@ void module_free(struct module *mod, voi +@@ -45,6 +58,13 @@ void module_free(struct module *mod, void *module_reg= ion) vfree(module_region); } =20 @@ -2682,9 +3160,43 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/mod= ule.c linux-2.6.32.49/arch/pow static const Elf_Shdr *find_section(const Elf_Ehdr *hdr, const Elf_Shdr *sechdrs, const char *name) -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/pci-common.c linux-2.6.32= .49/arch/powerpc/kernel/pci-common.c ---- linux-2.6.32.49/arch/powerpc/kernel/pci-common.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/pci-common.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/powerpc/kernel/module_32.c b/arch/powerpc/kernel/modul= e_32.c +index f832773..0507238 100644 +--- a/arch/powerpc/kernel/module_32.c ++++ b/arch/powerpc/kernel/module_32.c +@@ -162,7 +162,7 @@ int module_frob_arch_sections(Elf32_Ehdr *hdr, + me->arch.core_plt_section =3D i; + } + if (!me->arch.core_plt_section || !me->arch.init_plt_section) { +- printk("Module doesn't contain .plt or .init.plt sections.\n"); ++ printk("Module %s doesn't contain .plt or .init.plt sections.\n", me-= >name); + return -ENOEXEC; + } +=20 +@@ -203,11 +203,16 @@ static uint32_t do_plt_call(void *location, +=20 + DEBUGP("Doing plt for call to 0x%x at 0x%x\n", val, (unsigned int)loca= tion); + /* Init, or core PLT? */ +- if (location >=3D mod->module_core +- && location < mod->module_core + mod->core_size) ++ if ((location >=3D mod->module_core_rx && location < mod->module_core_= rx + mod->core_size_rx) || ++ (location >=3D mod->module_core_rw && location < mod->module_core_= rw + mod->core_size_rw)) + entry =3D (void *)sechdrs[mod->arch.core_plt_section].sh_addr; +- else ++ else if ((location >=3D mod->module_init_rx && location < mod->module_= init_rx + mod->init_size_rx) || ++ (location >=3D mod->module_init_rw && location < mod->module_init_rw= + mod->init_size_rw)) + entry =3D (void *)sechdrs[mod->arch.init_plt_section].sh_addr; ++ else { ++ printk(KERN_ERR "%s: invalid R_PPC_REL24 entry found\n", mod->name); ++ return ~0UL; ++ } +=20 + /* Find this entry, or if that fails, the next avail. entry */ + while (entry->jump[0]) { +diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-= common.c +index cadbed6..b9bbb00 100644 +--- a/arch/powerpc/kernel/pci-common.c ++++ b/arch/powerpc/kernel/pci-common.c @@ -50,14 +50,14 @@ resource_size_t isa_mem_base; unsigned int ppc_pci_flags =3D 0; =20 @@ -2703,9 +3215,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/pci= -common.c linux-2.6.32.49/arch { return pci_dma_ops; } -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/process.c linux-2.6.32.49= /arch/powerpc/kernel/process.c ---- linux-2.6.32.49/arch/powerpc/kernel/process.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/process.c 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process= .c +index 7b816da..8d5c277 100644 +--- a/arch/powerpc/kernel/process.c ++++ b/arch/powerpc/kernel/process.c @@ -539,8 +539,8 @@ void show_regs(struct pt_regs * regs) * Lookup NIP late so we have the best change of getting the * above info out without failing @@ -2717,7 +3230,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/proc= ess.c linux-2.6.32.49/arch/po #endif show_stack(current, (unsigned long *) regs->gpr[1]); if (!user_mode(regs)) -@@ -1034,10 +1034,10 @@ void show_stack(struct task_struct *tsk, +@@ -1034,10 +1034,10 @@ void show_stack(struct task_struct *tsk, unsigne= d long *stack) newsp =3D stack[0]; ip =3D stack[STACK_FRAME_LR_SAVE]; if (!firstframe || ip !=3D lr) { @@ -2730,7 +3243,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/proc= ess.c linux-2.6.32.49/arch/po (void *)current->ret_stack[curr_frame].ret); curr_frame--; } -@@ -1057,7 +1057,7 @@ void show_stack(struct task_struct *tsk, +@@ -1057,7 +1057,7 @@ void show_stack(struct task_struct *tsk, unsigned = long *stack) struct pt_regs *regs =3D (struct pt_regs *) (sp + STACK_FRAME_OVERHEAD); lr =3D regs->link; @@ -2798,10 +3311,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/pr= ocess.c linux-2.6.32.49/arch/po - - return ret; -} -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/ptrace.c linux-2.6.32.49/= arch/powerpc/kernel/ptrace.c ---- linux-2.6.32.49/arch/powerpc/kernel/ptrace.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/ptrace.c 2011-11-15 19:59:42.000= 000000 -0500 -@@ -86,7 +86,7 @@ static int set_user_trap(struct task_str +diff --git a/arch/powerpc/kernel/ptrace.c b/arch/powerpc/kernel/ptrace.c +index ef14988..856c4bc 100644 +--- a/arch/powerpc/kernel/ptrace.c ++++ b/arch/powerpc/kernel/ptrace.c +@@ -86,7 +86,7 @@ static int set_user_trap(struct task_struct *task, uns= igned long trap) /* * Get contents of register REGNO in task TASK. */ @@ -2810,7 +3324,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/ptra= ce.c linux-2.6.32.49/arch/pow { if (task->thread.regs =3D=3D NULL) return -EIO; -@@ -894,7 +894,7 @@ long arch_ptrace(struct task_struct *chi +@@ -894,7 +894,7 @@ long arch_ptrace(struct task_struct *child, long req= uest, long addr, long data) =20 CHECK_FULL_REGS(child->thread.regs); if (index < PT_FPR0) { @@ -2819,10 +3333,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/pt= race.c linux-2.6.32.49/arch/pow } else { flush_fp_to_thread(child); tmp =3D ((unsigned long *)child->thread.fpr) -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/signal_32.c linux-2.6.32.= 49/arch/powerpc/kernel/signal_32.c ---- linux-2.6.32.49/arch/powerpc/kernel/signal_32.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/signal_32.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -857,7 +857,7 @@ int handle_rt_signal32(unsigned long sig +diff --git a/arch/powerpc/kernel/signal_32.c b/arch/powerpc/kernel/signa= l_32.c +index d670429..2bc59b2 100644 +--- a/arch/powerpc/kernel/signal_32.c ++++ b/arch/powerpc/kernel/signal_32.c +@@ -857,7 +857,7 @@ int handle_rt_signal32(unsigned long sig, struct k_s= igaction *ka, /* Save user registers on the stack */ frame =3D &rt_sf->uc.uc_mcontext; addr =3D frame; @@ -2831,10 +3346,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/si= gnal_32.c linux-2.6.32.49/arch/ if (save_user_regs(regs, frame, 0, 1)) goto badframe; regs->link =3D current->mm->context.vdso_base + vdso32_rt_sigtramp; -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/signal_64.c linux-2.6.32.= 49/arch/powerpc/kernel/signal_64.c ---- linux-2.6.32.49/arch/powerpc/kernel/signal_64.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/signal_64.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -429,7 +429,7 @@ int handle_rt_signal64(int signr, struct +diff --git a/arch/powerpc/kernel/signal_64.c b/arch/powerpc/kernel/signa= l_64.c +index 2fe6fc6..ada0d96 100644 +--- a/arch/powerpc/kernel/signal_64.c ++++ b/arch/powerpc/kernel/signal_64.c +@@ -429,7 +429,7 @@ int handle_rt_signal64(int signr, struct k_sigaction= *ka, siginfo_t *info, current->thread.fpscr.val =3D 0; =20 /* Set up to return from userspace. */ @@ -2843,10 +3359,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/si= gnal_64.c linux-2.6.32.49/arch/ regs->link =3D current->mm->context.vdso_base + vdso64_rt_sigtramp; } else { err |=3D setup_trampoline(__NR_rt_sigreturn, &frame->tramp[0]); -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/sys_ppc32.c linux-2.6.32.= 49/arch/powerpc/kernel/sys_ppc32.c ---- linux-2.6.32.49/arch/powerpc/kernel/sys_ppc32.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/sys_ppc32.c 2011-11-15 19:59:42.= 000000000 -0500 -@@ -563,10 +563,10 @@ asmlinkage long compat_sys_sysctl(struct +diff --git a/arch/powerpc/kernel/sys_ppc32.c b/arch/powerpc/kernel/sys_p= pc32.c +index b97c2d6..dd01a6a 100644 +--- a/arch/powerpc/kernel/sys_ppc32.c ++++ b/arch/powerpc/kernel/sys_ppc32.c +@@ -563,10 +563,10 @@ asmlinkage long compat_sys_sysctl(struct __sysctl_= args32 __user *args) if (oldlenp) { if (!error) { if (get_user(oldlen, oldlenp) || @@ -2859,9 +3376,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/sys= _ppc32.c linux-2.6.32.49/arch/ } return error; } -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/traps.c linux-2.6.32.49/a= rch/powerpc/kernel/traps.c ---- linux-2.6.32.49/arch/powerpc/kernel/traps.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/traps.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c +index 6f0ae1a..e4b6a56 100644 +--- a/arch/powerpc/kernel/traps.c ++++ b/arch/powerpc/kernel/traps.c @@ -99,6 +99,8 @@ static void pmac_backlight_unblank(void) static inline void pmac_backlight_unblank(void) { } #endif @@ -2871,7 +3389,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/trap= s.c linux-2.6.32.49/arch/powe int die(const char *str, struct pt_regs *regs, long err) { static struct { -@@ -168,6 +170,8 @@ int die(const char *str, struct pt_regs=20 +@@ -168,6 +170,8 @@ int die(const char *str, struct pt_regs *regs, long = err) if (panic_on_oops) panic("Fatal exception"); =20 @@ -2880,9 +3398,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/tra= ps.c linux-2.6.32.49/arch/powe oops_exit(); do_exit(err); =20 -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/vdso.c linux-2.6.32.49/ar= ch/powerpc/kernel/vdso.c ---- linux-2.6.32.49/arch/powerpc/kernel/vdso.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/vdso.c 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c +index 137dc22..fe57a79 100644 +--- a/arch/powerpc/kernel/vdso.c ++++ b/arch/powerpc/kernel/vdso.c @@ -36,6 +36,7 @@ #include #include @@ -2891,7 +3410,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/vdso= .c linux-2.6.32.49/arch/power =20 #include "setup.h" =20 -@@ -220,7 +221,7 @@ int arch_setup_additional_pages(struct l +@@ -220,7 +221,7 @@ int arch_setup_additional_pages(struct linux_binprm = *bprm, int uses_interp) vdso_base =3D VDSO32_MBASE; #endif =20 @@ -2900,7 +3419,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/vdso= .c linux-2.6.32.49/arch/power =20 /* vDSO has a problem and was disabled, just don't "enable" it for the * process -@@ -240,7 +241,7 @@ int arch_setup_additional_pages(struct l +@@ -240,7 +241,7 @@ int arch_setup_additional_pages(struct linux_binprm = *bprm, int uses_interp) vdso_base =3D get_unmapped_area(NULL, vdso_base, (vdso_pages << PAGE_SHIFT) + ((VDSO_ALIGNMENT - 1) & PAGE_MASK), @@ -2909,10 +3428,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/vd= so.c linux-2.6.32.49/arch/power if (IS_ERR_VALUE(vdso_base)) { rc =3D vdso_base; goto fail_mmapsem; -diff -urNp linux-2.6.32.49/arch/powerpc/kernel/vio.c linux-2.6.32.49/arc= h/powerpc/kernel/vio.c ---- linux-2.6.32.49/arch/powerpc/kernel/vio.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/powerpc/kernel/vio.c 2011-11-15 19:59:42.000000= 000 -0500 -@@ -601,11 +601,12 @@ static void vio_dma_iommu_unmap_sg(struc +diff --git a/arch/powerpc/kernel/vio.c b/arch/powerpc/kernel/vio.c +index 77f6421..829564a 100644 +--- a/arch/powerpc/kernel/vio.c ++++ b/arch/powerpc/kernel/vio.c +@@ -601,11 +601,12 @@ static void vio_dma_iommu_unmap_sg(struct device *= dev, vio_cmo_dealloc(viodev, alloc_size); } =20 @@ -2926,7 +3446,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/vio.= c linux-2.6.32.49/arch/powerp .map_page =3D vio_dma_iommu_map_page, .unmap_page =3D vio_dma_iommu_unmap_page, =20 -@@ -857,7 +858,6 @@ static void vio_cmo_bus_remove(struct vi +@@ -857,7 +858,6 @@ static void vio_cmo_bus_remove(struct vio_dev *viode= v) =20 static void vio_cmo_set_dma_ops(struct vio_dev *viodev) { @@ -2934,9 +3454,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/kernel/vio= .c linux-2.6.32.49/arch/powerp viodev->dev.archdata.dma_ops =3D &vio_dma_mapping_ops; } =20 -diff -urNp linux-2.6.32.49/arch/powerpc/lib/usercopy_64.c linux-2.6.32.4= 9/arch/powerpc/lib/usercopy_64.c ---- linux-2.6.32.49/arch/powerpc/lib/usercopy_64.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/lib/usercopy_64.c 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/powerpc/lib/usercopy_64.c b/arch/powerpc/lib/usercopy_= 64.c +index 5eea6f3..5d10396 100644 +--- a/arch/powerpc/lib/usercopy_64.c ++++ b/arch/powerpc/lib/usercopy_64.c @@ -9,22 +9,6 @@ #include #include @@ -2960,7 +3481,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/lib/usercop= y_64.c linux-2.6.32.49/arch/p unsigned long copy_in_user(void __user *to, const void __user *from, unsigned long n) { -@@ -35,7 +19,5 @@ unsigned long copy_in_user(void __user * +@@ -35,7 +19,5 @@ unsigned long copy_in_user(void __user *to, const void= __user *from, return n; } =20 @@ -2968,21 +3489,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/lib/userc= opy_64.c linux-2.6.32.49/arch/p -EXPORT_SYMBOL(copy_to_user); EXPORT_SYMBOL(copy_in_user); =20 -diff -urNp linux-2.6.32.49/arch/powerpc/Makefile linux-2.6.32.49/arch/po= werpc/Makefile ---- linux-2.6.32.49/arch/powerpc/Makefile 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/powerpc/Makefile 2011-11-15 19:59:42.000000000 = -0500 -@@ -74,6 +74,8 @@ KBUILD_AFLAGS +=3D -Iarch/$(ARCH) - KBUILD_CFLAGS +=3D -msoft-float -pipe -Iarch/$(ARCH) $(CFLAGS-y) - CPP =3D $(CC) -E $(KBUILD_CFLAGS) -=20 -+cflags-y +=3D -Wno-sign-compare -Wno-extra -+ - CHECKFLAGS +=3D -m$(CONFIG_WORD_SIZE) -D__powerpc__ -D__powerpc$(CONFIG= _WORD_SIZE)__ -=20 - ifeq ($(CONFIG_PPC64),y) -diff -urNp linux-2.6.32.49/arch/powerpc/mm/fault.c linux-2.6.32.49/arch/= powerpc/mm/fault.c ---- linux-2.6.32.49/arch/powerpc/mm/fault.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/powerpc/mm/fault.c 2011-11-18 18:01:52.00000000= 0 -0500 +diff --git a/arch/powerpc/mm/fault.c b/arch/powerpc/mm/fault.c +index e7dae82..877ce0d 100644 +--- a/arch/powerpc/mm/fault.c ++++ b/arch/powerpc/mm/fault.c @@ -30,6 +30,10 @@ #include #include @@ -3002,7 +3512,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/fault.c = linux-2.6.32.49/arch/powerpc/ =20 =20 #ifdef CONFIG_KPROBES -@@ -64,6 +69,33 @@ static inline int notify_page_fault(stru +@@ -64,6 +69,33 @@ static inline int notify_page_fault(struct pt_regs *r= egs) } #endif =20 @@ -3036,7 +3546,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/fault.c = linux-2.6.32.49/arch/powerpc/ /* * Check whether the instruction at regs->nip is a store using * an update addressing form which will update r1. -@@ -134,7 +166,7 @@ int __kprobes do_page_fault(struct pt_re +@@ -134,7 +166,7 @@ int __kprobes do_page_fault(struct pt_regs *regs, un= signed long address, * indicate errors in DSISR but can validly be set in SRR1. */ if (trap =3D=3D 0x400) @@ -3087,10 +3597,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/fault.= c linux-2.6.32.49/arch/powerpc/ _exception(SIGSEGV, regs, code, address); return 0; } -diff -urNp linux-2.6.32.49/arch/powerpc/mm/mem.c linux-2.6.32.49/arch/po= werpc/mm/mem.c ---- linux-2.6.32.49/arch/powerpc/mm/mem.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/powerpc/mm/mem.c 2011-11-15 19:59:42.000000000 = -0500 -@@ -250,7 +250,7 @@ static int __init mark_nonram_nosave(voi +diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c +index 5973631..ad617af 100644 +--- a/arch/powerpc/mm/mem.c ++++ b/arch/powerpc/mm/mem.c +@@ -250,7 +250,7 @@ static int __init mark_nonram_nosave(void) { unsigned long lmb_next_region_start_pfn, lmb_region_max_pfn; @@ -3099,10 +3610,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/mem.c = linux-2.6.32.49/arch/powerpc/mm =20 for (i =3D 0; i < lmb.memory.cnt - 1; i++) { lmb_region_max_pfn =3D -diff -urNp linux-2.6.32.49/arch/powerpc/mm/mmap_64.c linux-2.6.32.49/arc= h/powerpc/mm/mmap_64.c ---- linux-2.6.32.49/arch/powerpc/mm/mmap_64.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/powerpc/mm/mmap_64.c 2011-11-15 19:59:42.000000= 000 -0500 -@@ -99,10 +99,22 @@ void arch_pick_mmap_layout(struct mm_str +diff --git a/arch/powerpc/mm/mmap_64.c b/arch/powerpc/mm/mmap_64.c +index 0d957a4..26d968f 100644 +--- a/arch/powerpc/mm/mmap_64.c ++++ b/arch/powerpc/mm/mmap_64.c +@@ -99,10 +99,22 @@ void arch_pick_mmap_layout(struct mm_struct *mm) */ if (mmap_is_legacy()) { mm->mmap_base =3D TASK_UNMAPPED_BASE; @@ -3125,10 +3637,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/mmap_6= 4.c linux-2.6.32.49/arch/powerp mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-2.6.32.49/arch/powerpc/mm/slice.c linux-2.6.32.49/arch/= powerpc/mm/slice.c ---- linux-2.6.32.49/arch/powerpc/mm/slice.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/powerpc/mm/slice.c 2011-11-15 19:59:42.00000000= 0 -0500 -@@ -98,7 +98,7 @@ static int slice_area_is_free(struct mm_ +diff --git a/arch/powerpc/mm/slice.c b/arch/powerpc/mm/slice.c +index ba51948..23009d9 100644 +--- a/arch/powerpc/mm/slice.c ++++ b/arch/powerpc/mm/slice.c +@@ -98,7 +98,7 @@ static int slice_area_is_free(struct mm_struct *mm, un= signed long addr, if ((mm->task_size - len) < addr) return 0; vma =3D find_vma(mm, addr); @@ -3146,7 +3659,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/slice.c = linux-2.6.32.49/arch/powerpc/ /* * Remember the place where we stopped the search: */ -@@ -313,10 +313,14 @@ static unsigned long slice_find_area_top +@@ -313,10 +313,14 @@ static unsigned long slice_find_area_topdown(struc= t mm_struct *mm, } } =20 @@ -3164,7 +3677,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/slice.c = linux-2.6.32.49/arch/powerpc/ =20 /* Check for hit with different page size */ mask =3D slice_range_to_mask(addr, len); -@@ -336,7 +340,7 @@ static unsigned long slice_find_area_top +@@ -336,7 +340,7 @@ static unsigned long slice_find_area_topdown(struct = mm_struct *mm, * return with success: */ vma =3D find_vma(mm, addr); @@ -3173,7 +3686,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/slice.c = linux-2.6.32.49/arch/powerpc/ /* remember the address as a hint for next time */ if (use_cache) mm->free_area_cache =3D addr; -@@ -348,7 +352,7 @@ static unsigned long slice_find_area_top +@@ -348,7 +352,7 @@ static unsigned long slice_find_area_topdown(struct = mm_struct *mm, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -3182,7 +3695,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/slice.c = linux-2.6.32.49/arch/powerpc/ } =20 /* -@@ -426,6 +430,11 @@ unsigned long slice_get_unmapped_area(un +@@ -426,6 +430,11 @@ unsigned long slice_get_unmapped_area(unsigned long= addr, unsigned long len, if (fixed && addr > (mm->task_size - len)) return -EINVAL; =20 @@ -3194,9 +3707,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/mm/slice.c= linux-2.6.32.49/arch/powerpc/ /* If hint, make sure it matches our alignment restrictions */ if (!fixed && addr) { addr =3D _ALIGN_UP(addr, 1ul << pshift); -diff -urNp linux-2.6.32.49/arch/powerpc/platforms/52xx/lite5200_pm.c lin= ux-2.6.32.49/arch/powerpc/platforms/52xx/lite5200_pm.c ---- linux-2.6.32.49/arch/powerpc/platforms/52xx/lite5200_pm.c 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/platforms/52xx/lite5200_pm.c 2011-11-15= 19:59:42.000000000 -0500 +diff --git a/arch/powerpc/platforms/52xx/lite5200_pm.c b/arch/powerpc/pl= atforms/52xx/lite5200_pm.c +index b5c753d..8f01abe 100644 +--- a/arch/powerpc/platforms/52xx/lite5200_pm.c ++++ b/arch/powerpc/platforms/52xx/lite5200_pm.c @@ -235,7 +235,7 @@ static void lite5200_pm_end(void) lite5200_pm_target_state =3D PM_SUSPEND_ON; } @@ -3206,9 +3720,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/platforms/= 52xx/lite5200_pm.c linux-2.6.3 .valid =3D lite5200_pm_valid, .begin =3D lite5200_pm_begin, .prepare =3D lite5200_pm_prepare, -diff -urNp linux-2.6.32.49/arch/powerpc/platforms/52xx/mpc52xx_pm.c linu= x-2.6.32.49/arch/powerpc/platforms/52xx/mpc52xx_pm.c ---- linux-2.6.32.49/arch/powerpc/platforms/52xx/mpc52xx_pm.c 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/platforms/52xx/mpc52xx_pm.c 2011-11-15 = 19:59:42.000000000 -0500 +diff --git a/arch/powerpc/platforms/52xx/mpc52xx_pm.c b/arch/powerpc/pla= tforms/52xx/mpc52xx_pm.c +index a55b0b6..478c18e 100644 +--- a/arch/powerpc/platforms/52xx/mpc52xx_pm.c ++++ b/arch/powerpc/platforms/52xx/mpc52xx_pm.c @@ -180,7 +180,7 @@ void mpc52xx_pm_finish(void) iounmap(mbar); } @@ -3218,9 +3733,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/platforms/= 52xx/mpc52xx_pm.c linux-2.6.32 .valid =3D mpc52xx_pm_valid, .prepare =3D mpc52xx_pm_prepare, .enter =3D mpc52xx_pm_enter, -diff -urNp linux-2.6.32.49/arch/powerpc/platforms/83xx/suspend.c linux-2= .6.32.49/arch/powerpc/platforms/83xx/suspend.c ---- linux-2.6.32.49/arch/powerpc/platforms/83xx/suspend.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/platforms/83xx/suspend.c 2011-11-15 19:= 59:42.000000000 -0500 +diff --git a/arch/powerpc/platforms/83xx/suspend.c b/arch/powerpc/platfo= rms/83xx/suspend.c +index 08e65fc..643d3ac 100644 +--- a/arch/powerpc/platforms/83xx/suspend.c ++++ b/arch/powerpc/platforms/83xx/suspend.c @@ -273,7 +273,7 @@ static int mpc83xx_is_pci_agent(void) return ret; } @@ -3230,10 +3746,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/platforms= /83xx/suspend.c linux-2.6.32.49 .valid =3D mpc83xx_suspend_valid, .begin =3D mpc83xx_suspend_begin, .enter =3D mpc83xx_suspend_enter, -diff -urNp linux-2.6.32.49/arch/powerpc/platforms/cell/iommu.c linux-2.6= .32.49/arch/powerpc/platforms/cell/iommu.c ---- linux-2.6.32.49/arch/powerpc/platforms/cell/iommu.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/platforms/cell/iommu.c 2011-11-15 19:59= :42.000000000 -0500 -@@ -642,7 +642,7 @@ static int dma_fixed_dma_supported(struc +diff --git a/arch/powerpc/platforms/cell/iommu.c b/arch/powerpc/platform= s/cell/iommu.c +index ca5bfdf..1602e09 100644 +--- a/arch/powerpc/platforms/cell/iommu.c ++++ b/arch/powerpc/platforms/cell/iommu.c +@@ -642,7 +642,7 @@ static int dma_fixed_dma_supported(struct device *de= v, u64 mask) =20 static int dma_set_mask_and_switch(struct device *dev, u64 dma_mask); =20 @@ -3242,10 +3759,11 @@ diff -urNp linux-2.6.32.49/arch/powerpc/platforms= /cell/iommu.c linux-2.6.32.49/a .alloc_coherent =3D dma_fixed_alloc_coherent, .free_coherent =3D dma_fixed_free_coherent, .map_sg =3D dma_fixed_map_sg, -diff -urNp linux-2.6.32.49/arch/powerpc/platforms/ps3/system-bus.c linux= -2.6.32.49/arch/powerpc/platforms/ps3/system-bus.c ---- linux-2.6.32.49/arch/powerpc/platforms/ps3/system-bus.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/platforms/ps3/system-bus.c 2011-11-15 1= 9:59:42.000000000 -0500 -@@ -694,7 +694,7 @@ static int ps3_dma_supported(struct devi +diff --git a/arch/powerpc/platforms/ps3/system-bus.c b/arch/powerpc/plat= forms/ps3/system-bus.c +index e34b305..20e48ec 100644 +--- a/arch/powerpc/platforms/ps3/system-bus.c ++++ b/arch/powerpc/platforms/ps3/system-bus.c +@@ -694,7 +694,7 @@ static int ps3_dma_supported(struct device *_dev, u6= 4 mask) return mask >=3D DMA_BIT_MASK(32); } =20 @@ -3254,7 +3772,7 @@ diff -urNp linux-2.6.32.49/arch/powerpc/platforms/p= s3/system-bus.c linux-2.6.32. .alloc_coherent =3D ps3_alloc_coherent, .free_coherent =3D ps3_free_coherent, .map_sg =3D ps3_sb_map_sg, -@@ -704,7 +704,7 @@ static struct dma_map_ops ps3_sb_dma_ops +@@ -704,7 +704,7 @@ static struct dma_map_ops ps3_sb_dma_ops =3D { .unmap_page =3D ps3_unmap_page, }; =20 @@ -3263,9 +3781,10 @@ diff -urNp linux-2.6.32.49/arch/powerpc/platforms/= ps3/system-bus.c linux-2.6.32. .alloc_coherent =3D ps3_alloc_coherent, .free_coherent =3D ps3_free_coherent, .map_sg =3D ps3_ioc0_map_sg, -diff -urNp linux-2.6.32.49/arch/powerpc/platforms/pseries/Kconfig linux-= 2.6.32.49/arch/powerpc/platforms/pseries/Kconfig ---- linux-2.6.32.49/arch/powerpc/platforms/pseries/Kconfig 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/powerpc/platforms/pseries/Kconfig 2011-11-15 19= :59:42.000000000 -0500 +diff --git a/arch/powerpc/platforms/pseries/Kconfig b/arch/powerpc/platf= orms/pseries/Kconfig +index f0e6f28..60d53ed 100644 +--- a/arch/powerpc/platforms/pseries/Kconfig ++++ b/arch/powerpc/platforms/pseries/Kconfig @@ -2,6 +2,8 @@ config PPC_PSERIES depends on PPC64 && PPC_BOOK3S bool "IBM pSeries & new (POWER5-based) iSeries" @@ -3275,9 +3794,51 @@ diff -urNp linux-2.6.32.49/arch/powerpc/platforms/= pseries/Kconfig linux-2.6.32.4 select PPC_I8259 select PPC_RTAS select RTAS_ERROR_LOGGING -diff -urNp linux-2.6.32.49/arch/s390/include/asm/elf.h linux-2.6.32.49/a= rch/s390/include/asm/elf.h ---- linux-2.6.32.49/arch/s390/include/asm/elf.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/s390/include/asm/elf.h 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig +index 43c0aca..42c045b 100644 +--- a/arch/s390/Kconfig ++++ b/arch/s390/Kconfig +@@ -194,28 +194,26 @@ config AUDIT_ARCH +=20 + config S390_SWITCH_AMODE + bool "Switch kernel/user addressing modes" ++ default y + help + This option allows to switch the addressing modes of kernel and user +- space. The kernel parameter switch_amode=3Don will enable this featu= re, +- default is disabled. Enabling this (via kernel parameter) on machine= s +- earlier than IBM System z9-109 EC/BC will reduce system performance. ++ space. Enabling this on machines earlier than IBM System z9-109 EC/= BC ++ will reduce system performance. +=20 + Note that this option will also be selected by selecting the execute +- protection option below. Enabling the execute protection via the +- noexec kernel parameter will also switch the addressing modes, +- independent of the switch_amode kernel parameter. ++ protection option below. Enabling the execute protection will also ++ switch the addressing modes, independent of this option. +=20 +=20 + config S390_EXEC_PROTECT + bool "Data execute protection" ++ default y + select S390_SWITCH_AMODE + help + This option allows to enable a buffer overflow protection for user + space programs and it also selects the addressing mode option above. +- The kernel parameter noexec=3Don will enable this feature and also +- switch the addressing modes, default is disabled. Enabling this (via +- kernel parameter) on machines earlier than IBM System z9-109 EC/BC +- will reduce system performance. ++ Enabling this on machines earlier than IBM System z9-109 EC/BC will ++ reduce system performance. +=20 + comment "Code generation options" +=20 +diff --git a/arch/s390/include/asm/elf.h b/arch/s390/include/asm/elf.h +index e885442..5e6c303 100644 +--- a/arch/s390/include/asm/elf.h ++++ b/arch/s390/include/asm/elf.h @@ -164,6 +164,13 @@ extern unsigned int vdso_enabled; that it will "exec", and that there is sufficient room for the brk. = */ #define ELF_ET_DYN_BASE (STACK_TOP / 3 * 2) @@ -3292,9 +3853,10 @@ diff -urNp linux-2.6.32.49/arch/s390/include/asm/e= lf.h linux-2.6.32.49/arch/s390 /* This yields a mask that user programs can use to figure out what instruction set this CPU supports. */ =20 -diff -urNp linux-2.6.32.49/arch/s390/include/asm/setup.h linux-2.6.32.49= /arch/s390/include/asm/setup.h ---- linux-2.6.32.49/arch/s390/include/asm/setup.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/s390/include/asm/setup.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/s390/include/asm/setup.h b/arch/s390/include/asm/setup= .h +index e37478e..9ce0e9f 100644 +--- a/arch/s390/include/asm/setup.h ++++ b/arch/s390/include/asm/setup.h @@ -50,13 +50,13 @@ extern unsigned long memory_end; void detect_memory_layout(struct mem_chunk chunk[]); =20 @@ -3311,9 +3873,10 @@ diff -urNp linux-2.6.32.49/arch/s390/include/asm/s= etup.h linux-2.6.32.49/arch/s3 #else #define s390_noexec (0) #endif -diff -urNp linux-2.6.32.49/arch/s390/include/asm/uaccess.h linux-2.6.32.= 49/arch/s390/include/asm/uaccess.h ---- linux-2.6.32.49/arch/s390/include/asm/uaccess.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/s390/include/asm/uaccess.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/s390/include/asm/uaccess.h b/arch/s390/include/asm/uac= cess.h +index 8377e91..e28e6f1 100644 +--- a/arch/s390/include/asm/uaccess.h ++++ b/arch/s390/include/asm/uaccess.h @@ -232,6 +232,10 @@ static inline unsigned long __must_check copy_to_user(void __user *to, const void *from, unsigned long n) { @@ -3325,7 +3888,7 @@ diff -urNp linux-2.6.32.49/arch/s390/include/asm/ua= ccess.h linux-2.6.32.49/arch/ if (access_ok(VERIFY_WRITE, to, n)) n =3D __copy_to_user(to, from, n); return n; -@@ -257,6 +261,9 @@ copy_to_user(void __user *to, const void +@@ -257,6 +261,9 @@ copy_to_user(void __user *to, const void *from, unsi= gned long n) static inline unsigned long __must_check __copy_from_user(void *to, const void __user *from, unsigned long n) { @@ -3346,50 +3909,11 @@ diff -urNp linux-2.6.32.49/arch/s390/include/asm/= uaccess.h linux-2.6.32.49/arch/ if (access_ok(VERIFY_READ, from, n)) n =3D __copy_from_user(to, from, n); else -diff -urNp linux-2.6.32.49/arch/s390/Kconfig linux-2.6.32.49/arch/s390/K= config ---- linux-2.6.32.49/arch/s390/Kconfig 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/arch/s390/Kconfig 2011-11-15 19:59:42.000000000 -050= 0 -@@ -194,28 +194,26 @@ config AUDIT_ARCH -=20 - config S390_SWITCH_AMODE - bool "Switch kernel/user addressing modes" -+ default y - help - This option allows to switch the addressing modes of kernel and user -- space. The kernel parameter switch_amode=3Don will enable this featu= re, -- default is disabled. Enabling this (via kernel parameter) on machine= s -- earlier than IBM System z9-109 EC/BC will reduce system performance. -+ space. Enabling this on machines earlier than IBM System z9-109 EC/= BC -+ will reduce system performance. -=20 - Note that this option will also be selected by selecting the execute -- protection option below. Enabling the execute protection via the -- noexec kernel parameter will also switch the addressing modes, -- independent of the switch_amode kernel parameter. -+ protection option below. Enabling the execute protection will also -+ switch the addressing modes, independent of this option. -=20 -=20 - config S390_EXEC_PROTECT - bool "Data execute protection" -+ default y - select S390_SWITCH_AMODE - help - This option allows to enable a buffer overflow protection for user - space programs and it also selects the addressing mode option above. -- The kernel parameter noexec=3Don will enable this feature and also -- switch the addressing modes, default is disabled. Enabling this (via -- kernel parameter) on machines earlier than IBM System z9-109 EC/BC -- will reduce system performance. -+ Enabling this on machines earlier than IBM System z9-109 EC/BC will -+ reduce system performance. -=20 - comment "Code generation options" -=20 -diff -urNp linux-2.6.32.49/arch/s390/kernel/module.c linux-2.6.32.49/arc= h/s390/kernel/module.c ---- linux-2.6.32.49/arch/s390/kernel/module.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/s390/kernel/module.c 2011-11-15 19:59:42.000000= 000 -0500 -@@ -166,11 +166,11 @@ module_frob_arch_sections(Elf_Ehdr *hdr, +diff --git a/arch/s390/kernel/module.c b/arch/s390/kernel/module.c +index 639380a..72e3c02 100644 +--- a/arch/s390/kernel/module.c ++++ b/arch/s390/kernel/module.c +@@ -166,11 +166,11 @@ module_frob_arch_sections(Elf_Ehdr *hdr, Elf_Shdr = *sechdrs, =20 /* Increase core size by size of got & plt and set start offsets for got and plt. */ @@ -3406,7 +3930,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/module.= c linux-2.6.32.49/arch/s390/k return 0; } =20 -@@ -256,7 +256,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -256,7 +256,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, if (info->got_initialized =3D=3D 0) { Elf_Addr *gotent; =20 @@ -3415,7 +3939,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/module.= c linux-2.6.32.49/arch/s390/k info->got_offset; *gotent =3D val; info->got_initialized =3D 1; -@@ -280,7 +280,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -280,7 +280,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, else if (r_type =3D=3D R_390_GOTENT || r_type =3D=3D R_390_GOTPLTENT) *(unsigned int *) loc =3D @@ -3424,7 +3948,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/module.= c linux-2.6.32.49/arch/s390/k else if (r_type =3D=3D R_390_GOT64 || r_type =3D=3D R_390_GOTPLT64) *(unsigned long *) loc =3D val; -@@ -294,7 +294,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -294,7 +294,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, case R_390_PLTOFF64: /* 16 bit offset from GOT to PLT. */ if (info->plt_initialized =3D=3D 0) { unsigned int *ip; @@ -3433,7 +3957,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/module.= c linux-2.6.32.49/arch/s390/k info->plt_offset; #ifndef CONFIG_64BIT ip[0] =3D 0x0d105810; /* basr 1,0; l 1,6(1); br 1 */ -@@ -319,7 +319,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -319,7 +319,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, val - loc + 0xffffUL < 0x1ffffeUL) || (r_type =3D=3D R_390_PLT32DBL && val - loc + 0xffffffffULL < 0x1fffffffeULL))) @@ -3442,7 +3966,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/module.= c linux-2.6.32.49/arch/s390/k me->arch.plt_offset + info->plt_offset; val +=3D rela->r_addend - loc; -@@ -341,7 +341,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -341,7 +341,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, case R_390_GOTOFF32: /* 32 bit offset to GOT. */ case R_390_GOTOFF64: /* 64 bit offset to GOT. */ val =3D val + rela->r_addend - @@ -3451,7 +3975,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/module.= c linux-2.6.32.49/arch/s390/k if (r_type =3D=3D R_390_GOTOFF16) *(unsigned short *) loc =3D val; else if (r_type =3D=3D R_390_GOTOFF32) -@@ -351,7 +351,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -351,7 +351,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, break; case R_390_GOTPC: /* 32 bit PC relative offset to GOT. */ case R_390_GOTPCDBL: /* 32 bit PC rel. off. to GOT shifted by 1. */ @@ -3460,10 +3984,11 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/modul= e.c linux-2.6.32.49/arch/s390/k rela->r_addend - loc; if (r_type =3D=3D R_390_GOTPC) *(unsigned int *) loc =3D val; -diff -urNp linux-2.6.32.49/arch/s390/kernel/setup.c linux-2.6.32.49/arch= /s390/kernel/setup.c ---- linux-2.6.32.49/arch/s390/kernel/setup.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/s390/kernel/setup.c 2011-11-15 19:59:42.0000000= 00 -0500 -@@ -306,9 +306,6 @@ static int __init early_parse_mem(char * +diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c +index 061479f..dbfb08c 100644 +--- a/arch/s390/kernel/setup.c ++++ b/arch/s390/kernel/setup.c +@@ -306,9 +306,6 @@ static int __init early_parse_mem(char *p) early_param("mem", early_parse_mem); =20 #ifdef CONFIG_S390_SWITCH_AMODE @@ -3473,7 +3998,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/setup.c= linux-2.6.32.49/arch/s390/ke static int set_amode_and_uaccess(unsigned long user_amode, unsigned long user32_amode) { -@@ -334,17 +331,6 @@ static int set_amode_and_uaccess(unsigne +@@ -334,17 +331,6 @@ static int set_amode_and_uaccess(unsigned long user= _amode, return 0; } } @@ -3491,7 +4016,7 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/setup.c= linux-2.6.32.49/arch/s390/ke #else /* CONFIG_S390_SWITCH_AMODE */ static inline int set_amode_and_uaccess(unsigned long user_amode, unsigned long user32_amode) -@@ -353,24 +339,6 @@ static inline int set_amode_and_uaccess( +@@ -353,24 +339,6 @@ static inline int set_amode_and_uaccess(unsigned lo= ng user_amode, } #endif /* CONFIG_S390_SWITCH_AMODE */ =20 @@ -3516,10 +4041,11 @@ diff -urNp linux-2.6.32.49/arch/s390/kernel/setup= .c linux-2.6.32.49/arch/s390/ke static void setup_addressing_mode(void) { if (s390_noexec) { -diff -urNp linux-2.6.32.49/arch/s390/mm/mmap.c linux-2.6.32.49/arch/s390= /mm/mmap.c ---- linux-2.6.32.49/arch/s390/mm/mmap.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/s390/mm/mmap.c 2011-11-15 19:59:42.000000000 -0= 500 -@@ -78,10 +78,22 @@ void arch_pick_mmap_layout(struct mm_str +diff --git a/arch/s390/mm/mmap.c b/arch/s390/mm/mmap.c +index f4558cc..e461f37 100644 +--- a/arch/s390/mm/mmap.c ++++ b/arch/s390/mm/mmap.c +@@ -78,10 +78,22 @@ void arch_pick_mmap_layout(struct mm_struct *mm) */ if (mmap_is_legacy()) { mm->mmap_base =3D TASK_UNMAPPED_BASE; @@ -3542,7 +4068,7 @@ diff -urNp linux-2.6.32.49/arch/s390/mm/mmap.c linu= x-2.6.32.49/arch/s390/mm/mmap mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -@@ -153,10 +165,22 @@ void arch_pick_mmap_layout(struct mm_str +@@ -153,10 +165,22 @@ void arch_pick_mmap_layout(struct mm_struct *mm) */ if (mmap_is_legacy()) { mm->mmap_base =3D TASK_UNMAPPED_BASE; @@ -3565,9 +4091,10 @@ diff -urNp linux-2.6.32.49/arch/s390/mm/mmap.c lin= ux-2.6.32.49/arch/s390/mm/mmap mm->get_unmapped_area =3D s390_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-2.6.32.49/arch/score/include/asm/system.h linux-2.6.32.= 49/arch/score/include/asm/system.h ---- linux-2.6.32.49/arch/score/include/asm/system.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/score/include/asm/system.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/score/include/asm/system.h b/arch/score/include/asm/sy= stem.h +index 589d5c7..669e274 100644 +--- a/arch/score/include/asm/system.h ++++ b/arch/score/include/asm/system.h @@ -17,7 +17,7 @@ do { \ #define finish_arch_switch(prev) do {} while (0) =20 @@ -3577,10 +4104,11 @@ diff -urNp linux-2.6.32.49/arch/score/include/asm= /system.h linux-2.6.32.49/arch/ =20 #define mb() barrier() #define rmb() barrier() -diff -urNp linux-2.6.32.49/arch/score/kernel/process.c linux-2.6.32.49/a= rch/score/kernel/process.c ---- linux-2.6.32.49/arch/score/kernel/process.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/score/kernel/process.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -161,8 +161,3 @@ unsigned long get_wchan(struct task_stru +diff --git a/arch/score/kernel/process.c b/arch/score/kernel/process.c +index 25d0803..d6c8e36 100644 +--- a/arch/score/kernel/process.c ++++ b/arch/score/kernel/process.c +@@ -161,8 +161,3 @@ unsigned long get_wchan(struct task_struct *task) =20 return task_pt_regs(task)->cp0_epc; } @@ -3589,10 +4117,11 @@ diff -urNp linux-2.6.32.49/arch/score/kernel/proc= ess.c linux-2.6.32.49/arch/scor -{ - return sp; -} -diff -urNp linux-2.6.32.49/arch/sh/boards/mach-hp6xx/pm.c linux-2.6.32.4= 9/arch/sh/boards/mach-hp6xx/pm.c ---- linux-2.6.32.49/arch/sh/boards/mach-hp6xx/pm.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/sh/boards/mach-hp6xx/pm.c 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -143,7 +143,7 @@ static int hp6x0_pm_enter(suspend_state_ +diff --git a/arch/sh/boards/mach-hp6xx/pm.c b/arch/sh/boards/mach-hp6xx/= pm.c +index d936c1a..304a252 100644 +--- a/arch/sh/boards/mach-hp6xx/pm.c ++++ b/arch/sh/boards/mach-hp6xx/pm.c +@@ -143,7 +143,7 @@ static int hp6x0_pm_enter(suspend_state_t state) return 0; } =20 @@ -3601,10 +4130,11 @@ diff -urNp linux-2.6.32.49/arch/sh/boards/mach-hp= 6xx/pm.c linux-2.6.32.49/arch/s .enter =3D hp6x0_pm_enter, .valid =3D suspend_valid_only_mem, }; -diff -urNp linux-2.6.32.49/arch/sh/kernel/cpu/sh4/sq.c linux-2.6.32.49/a= rch/sh/kernel/cpu/sh4/sq.c ---- linux-2.6.32.49/arch/sh/kernel/cpu/sh4/sq.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/sh/kernel/cpu/sh4/sq.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -327,7 +327,7 @@ static struct attribute *sq_sysfs_attrs[ +diff --git a/arch/sh/kernel/cpu/sh4/sq.c b/arch/sh/kernel/cpu/sh4/sq.c +index 8a8a993..7b3079b 100644 +--- a/arch/sh/kernel/cpu/sh4/sq.c ++++ b/arch/sh/kernel/cpu/sh4/sq.c +@@ -327,7 +327,7 @@ static struct attribute *sq_sysfs_attrs[] =3D { NULL, }; =20 @@ -3613,10 +4143,11 @@ diff -urNp linux-2.6.32.49/arch/sh/kernel/cpu/sh4= /sq.c linux-2.6.32.49/arch/sh/k .show =3D sq_sysfs_show, .store =3D sq_sysfs_store, }; -diff -urNp linux-2.6.32.49/arch/sh/kernel/cpu/shmobile/pm.c linux-2.6.32= .49/arch/sh/kernel/cpu/shmobile/pm.c ---- linux-2.6.32.49/arch/sh/kernel/cpu/shmobile/pm.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/sh/kernel/cpu/shmobile/pm.c 2011-11-15 19:59:42= .000000000 -0500 -@@ -58,7 +58,7 @@ static int sh_pm_enter(suspend_state_t s +diff --git a/arch/sh/kernel/cpu/shmobile/pm.c b/arch/sh/kernel/cpu/shmob= ile/pm.c +index ee3c2aa..c49cee6 100644 +--- a/arch/sh/kernel/cpu/shmobile/pm.c ++++ b/arch/sh/kernel/cpu/shmobile/pm.c +@@ -58,7 +58,7 @@ static int sh_pm_enter(suspend_state_t state) return 0; } =20 @@ -3625,9 +4156,10 @@ diff -urNp linux-2.6.32.49/arch/sh/kernel/cpu/shmo= bile/pm.c linux-2.6.32.49/arch .enter =3D sh_pm_enter, .valid =3D suspend_valid_only_mem, }; -diff -urNp linux-2.6.32.49/arch/sh/kernel/kgdb.c linux-2.6.32.49/arch/sh= /kernel/kgdb.c ---- linux-2.6.32.49/arch/sh/kernel/kgdb.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/sh/kernel/kgdb.c 2011-11-15 19:59:42.000000000 = -0500 +diff --git a/arch/sh/kernel/kgdb.c b/arch/sh/kernel/kgdb.c +index 3e532d0..9faa306 100644 +--- a/arch/sh/kernel/kgdb.c ++++ b/arch/sh/kernel/kgdb.c @@ -271,7 +271,7 @@ void kgdb_arch_exit(void) { } @@ -3637,10 +4169,11 @@ diff -urNp linux-2.6.32.49/arch/sh/kernel/kgdb.c = linux-2.6.32.49/arch/sh/kernel/ /* Breakpoint instruction: trapa #0x3c */ #ifdef CONFIG_CPU_LITTLE_ENDIAN .gdb_bpt_instr =3D { 0x3c, 0xc3 }, -diff -urNp linux-2.6.32.49/arch/sh/mm/mmap.c linux-2.6.32.49/arch/sh/mm/= mmap.c ---- linux-2.6.32.49/arch/sh/mm/mmap.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/arch/sh/mm/mmap.c 2011-11-15 19:59:42.000000000 -050= 0 -@@ -74,8 +74,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/sh/mm/mmap.c b/arch/sh/mm/mmap.c +index afeb710..d1d1289 100644 +--- a/arch/sh/mm/mmap.c ++++ b/arch/sh/mm/mmap.c +@@ -74,8 +74,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -3659,7 +4192,7 @@ diff -urNp linux-2.6.32.49/arch/sh/mm/mmap.c linux-= 2.6.32.49/arch/sh/mm/mmap.c /* * Remember the place where we stopped the search: */ -@@ -157,8 +156,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -157,8 +156,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -3669,7 +4202,7 @@ diff -urNp linux-2.6.32.49/arch/sh/mm/mmap.c linux-= 2.6.32.49/arch/sh/mm/mmap.c return addr; } =20 -@@ -179,7 +177,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -179,7 +177,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* make sure it can fit in the remaining address space */ if (likely(addr > len)) { vma =3D find_vma(mm, addr-len); @@ -3678,7 +4211,7 @@ diff -urNp linux-2.6.32.49/arch/sh/mm/mmap.c linux-= 2.6.32.49/arch/sh/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -188,18 +186,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -188,18 +186,18 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, if (unlikely(mm->mmap_base < len)) goto bottomup; =20 @@ -3701,7 +4234,7 @@ diff -urNp linux-2.6.32.49/arch/sh/mm/mmap.c linux-= 2.6.32.49/arch/sh/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); } -@@ -209,10 +207,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -209,10 +207,8 @@ arch_get_unmapped_area_topdown(struct file *filp, c= onst unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -3714,9 +4247,23 @@ diff -urNp linux-2.6.32.49/arch/sh/mm/mmap.c linux= -2.6.32.49/arch/sh/mm/mmap.c =20 bottomup: /* -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/atomic_64.h linux-2.6.= 32.49/arch/sparc/include/asm/atomic_64.h ---- linux-2.6.32.49/arch/sparc/include/asm/atomic_64.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/atomic_64.h 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/sparc/Makefile b/arch/sparc/Makefile +index 113225b..7fd04e7 100644 +--- a/arch/sparc/Makefile ++++ b/arch/sparc/Makefile +@@ -75,7 +75,7 @@ drivers-$(CONFIG_OPROFILE) +=3D arch/sparc/oprofile/ + # Export what is needed by arch/sparc/boot/Makefile + export VMLINUX_INIT VMLINUX_MAIN + VMLINUX_INIT :=3D $(head-y) $(init-y) +-VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ ++VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ grsecurity/ + VMLINUX_MAIN +=3D $(patsubst %/, %/lib.a, $(libs-y)) $(libs-y) + VMLINUX_MAIN +=3D $(drivers-y) $(net-y) +=20 +diff --git a/arch/sparc/include/asm/atomic_64.h b/arch/sparc/include/asm= /atomic_64.h +index f5cc06f..f858d47 100644 +--- a/arch/sparc/include/asm/atomic_64.h ++++ b/arch/sparc/include/asm/atomic_64.h @@ -14,18 +14,40 @@ #define ATOMIC64_INIT(i) { (i) } =20 @@ -3758,7 +4305,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/a= tomic_64.h linux-2.6.32.49/ar extern int atomic_sub_ret(int, atomic_t *); extern long atomic64_sub_ret(long, atomic64_t *); =20 -@@ -33,13 +55,29 @@ extern long atomic64_sub_ret(long, atomi +@@ -33,13 +55,29 @@ extern long atomic64_sub_ret(long, atomic64_t *); #define atomic64_dec_return(v) atomic64_sub_ret(1, v) =20 #define atomic_inc_return(v) atomic_add_ret(1, v) @@ -3788,7 +4335,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/a= tomic_64.h linux-2.6.32.49/ar =20 /* * atomic_inc_and_test - increment and test -@@ -50,6 +88,10 @@ extern long atomic64_sub_ret(long, atomi +@@ -50,6 +88,10 @@ extern long atomic64_sub_ret(long, atomic64_t *); * other cases. */ #define atomic_inc_and_test(v) (atomic_inc_return(v) =3D=3D 0) @@ -3799,7 +4346,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/a= tomic_64.h linux-2.6.32.49/ar #define atomic64_inc_and_test(v) (atomic64_inc_return(v) =3D=3D 0) =20 #define atomic_sub_and_test(i, v) (atomic_sub_ret(i, v) =3D=3D 0) -@@ -59,30 +101,65 @@ extern long atomic64_sub_ret(long, atomi +@@ -59,30 +101,65 @@ extern long atomic64_sub_ret(long, atomic64_t *); #define atomic64_dec_and_test(v) (atomic64_sub_ret(1, v) =3D=3D 0) =20 #define atomic_inc(v) atomic_add(1, v) @@ -3869,7 +4416,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/a= tomic_64.h linux-2.6.32.49/ar } =20 #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) -@@ -90,20 +167,35 @@ static inline int atomic_add_unless(atom +@@ -90,20 +167,35 @@ static inline int atomic_add_unless(atomic_t *v, in= t a, int u) #define atomic64_cmpxchg(v, o, n) \ ((__typeof__((v)->counter))cmpxchg(&((v)->counter), (o), (n))) #define atomic64_xchg(v, new) (xchg(&((v)->counter), new)) @@ -3909,9 +4456,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= atomic_64.h linux-2.6.32.49/ar } =20 #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/cache.h linux-2.6.32.4= 9/arch/sparc/include/asm/cache.h ---- linux-2.6.32.49/arch/sparc/include/asm/cache.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/cache.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/sparc/include/asm/cache.h b/arch/sparc/include/asm/cac= he.h +index 41f85ae..fb54d5e 100644 +--- a/arch/sparc/include/asm/cache.h ++++ b/arch/sparc/include/asm/cache.h @@ -8,7 +8,7 @@ #define _SPARC_CACHE_H =20 @@ -3921,10 +4469,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm= /cache.h linux-2.6.32.49/arch/s #define L1_CACHE_ALIGN(x) ((((x)+(L1_CACHE_BYTES-1))&~(L1_CACHE_BYTES-1= ))) =20 #ifdef CONFIG_SPARC32 -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/dma-mapping.h linux-2.= 6.32.49/arch/sparc/include/asm/dma-mapping.h ---- linux-2.6.32.49/arch/sparc/include/asm/dma-mapping.h 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/dma-mapping.h 2011-11-15 19:5= 9:42.000000000 -0500 -@@ -14,10 +14,10 @@ extern int dma_set_mask(struct device *d +diff --git a/arch/sparc/include/asm/dma-mapping.h b/arch/sparc/include/a= sm/dma-mapping.h +index 5a8c308..38def92 100644 +--- a/arch/sparc/include/asm/dma-mapping.h ++++ b/arch/sparc/include/asm/dma-mapping.h +@@ -14,10 +14,10 @@ extern int dma_set_mask(struct device *dev, u64 dma_= mask); #define dma_free_noncoherent(d, s, v, h) dma_free_coherent(d, s, v, h) #define dma_is_consistent(d, h) (1) =20 @@ -3937,7 +4486,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/d= ma-mapping.h linux-2.6.32.49/ { #if defined(CONFIG_SPARC32) && defined(CONFIG_PCI) if (dev->bus =3D=3D &pci_bus_type) -@@ -31,7 +31,7 @@ static inline struct dma_map_ops *get_dm +@@ -31,7 +31,7 @@ static inline struct dma_map_ops *get_dma_ops(struct d= evice *dev) static inline void *dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *dma_handle, gfp_t flag) { @@ -3946,7 +4495,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/d= ma-mapping.h linux-2.6.32.49/ void *cpu_addr; =20 cpu_addr =3D ops->alloc_coherent(dev, size, dma_handle, flag); -@@ -42,7 +42,7 @@ static inline void *dma_alloc_coherent(s +@@ -42,7 +42,7 @@ static inline void *dma_alloc_coherent(struct device *= dev, size_t size, static inline void dma_free_coherent(struct device *dev, size_t size, void *cpu_addr, dma_addr_t dma_handle) { @@ -3955,9 +4504,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= dma-mapping.h linux-2.6.32.49/ =20 debug_dma_free_coherent(dev, size, cpu_addr, dma_handle); ops->free_coherent(dev, size, cpu_addr, dma_handle); -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/elf_32.h linux-2.6.32.= 49/arch/sparc/include/asm/elf_32.h ---- linux-2.6.32.49/arch/sparc/include/asm/elf_32.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/elf_32.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/sparc/include/asm/elf_32.h b/arch/sparc/include/asm/el= f_32.h +index 381a1b5..b97e3ff 100644 +--- a/arch/sparc/include/asm/elf_32.h ++++ b/arch/sparc/include/asm/elf_32.h @@ -116,6 +116,13 @@ typedef struct { =20 #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE) @@ -3972,9 +4522,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= elf_32.h linux-2.6.32.49/arch/ /* This yields a mask that user programs can use to figure out what instruction set this cpu supports. This can NOT be done in userspac= e on Sparc. */ -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/elf_64.h linux-2.6.32.= 49/arch/sparc/include/asm/elf_64.h ---- linux-2.6.32.49/arch/sparc/include/asm/elf_64.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/elf_64.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/sparc/include/asm/elf_64.h b/arch/sparc/include/asm/el= f_64.h +index 9968085..c2106ef 100644 +--- a/arch/sparc/include/asm/elf_64.h ++++ b/arch/sparc/include/asm/elf_64.h @@ -163,6 +163,12 @@ typedef struct { #define ELF_ET_DYN_BASE 0x0000010000000000UL #define COMPAT_ELF_ET_DYN_BASE 0x0000000070000000UL @@ -3988,9 +4539,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= elf_64.h linux-2.6.32.49/arch/ =20 /* This yields a mask that user programs can use to figure out what instruction set this cpu supports. */ -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/pgtable_32.h linux-2.6= .32.49/arch/sparc/include/asm/pgtable_32.h ---- linux-2.6.32.49/arch/sparc/include/asm/pgtable_32.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/pgtable_32.h 2011-11-15 19:59= :42.000000000 -0500 +diff --git a/arch/sparc/include/asm/pgtable_32.h b/arch/sparc/include/as= m/pgtable_32.h +index e0cabe7..efd60f1 100644 +--- a/arch/sparc/include/asm/pgtable_32.h ++++ b/arch/sparc/include/asm/pgtable_32.h @@ -43,6 +43,13 @@ BTFIXUPDEF_SIMM13(user_ptrs_per_pgd) BTFIXUPDEF_INT(page_none) BTFIXUPDEF_INT(page_copy) @@ -4022,9 +4574,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= pgtable_32.h linux-2.6.32.49/a extern unsigned long page_kernel; =20 #ifdef MODULE -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/pgtsrmmu.h linux-2.6.3= 2.49/arch/sparc/include/asm/pgtsrmmu.h ---- linux-2.6.32.49/arch/sparc/include/asm/pgtsrmmu.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/pgtsrmmu.h 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/sparc/include/asm/pgtsrmmu.h b/arch/sparc/include/asm/= pgtsrmmu.h +index 1407c07..7e10231 100644 +--- a/arch/sparc/include/asm/pgtsrmmu.h ++++ b/arch/sparc/include/asm/pgtsrmmu.h @@ -115,6 +115,13 @@ SRMMU_EXEC | SRMMU_REF) #define SRMMU_PAGE_RDONLY __pgprot(SRMMU_VALID | SRMMU_CACHE | \ @@ -4039,10 +4592,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm= /pgtsrmmu.h linux-2.6.32.49/arc #define SRMMU_PAGE_KERNEL __pgprot(SRMMU_VALID | SRMMU_CACHE | SRMMU_P= RIV | \ SRMMU_DIRTY | SRMMU_REF) =20 -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/spinlock_64.h linux-2.= 6.32.49/arch/sparc/include/asm/spinlock_64.h ---- linux-2.6.32.49/arch/sparc/include/asm/spinlock_64.h 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/spinlock_64.h 2011-11-15 19:5= 9:42.000000000 -0500 -@@ -92,14 +92,19 @@ static inline void __raw_spin_lock_flags +diff --git a/arch/sparc/include/asm/spinlock_64.h b/arch/sparc/include/a= sm/spinlock_64.h +index 43e5147..47622a1 100644 +--- a/arch/sparc/include/asm/spinlock_64.h ++++ b/arch/sparc/include/asm/spinlock_64.h +@@ -92,14 +92,19 @@ static inline void __raw_spin_lock_flags(raw_spinloc= k_t *lock, unsigned long fla =20 /* Multi-reader locks, these are much saner than the 32-bit Sparc ones.= .. */ =20 @@ -4064,7 +4618,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/s= pinlock_64.h linux-2.6.32.49/ " cas [%2], %0, %1\n" " cmp %0, %1\n" " bne,pn %%icc, 1b\n" -@@ -112,10 +117,10 @@ static void inline arch_read_lock(raw_rw +@@ -112,10 +117,10 @@ static void inline arch_read_lock(raw_rwlock_t *lo= ck) " .previous" : "=3D&r" (tmp1), "=3D&r" (tmp2) : "r" (lock) @@ -4077,7 +4631,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/s= pinlock_64.h linux-2.6.32.49/ { int tmp1, tmp2; =20 -@@ -123,7 +128,12 @@ static int inline arch_read_trylock(raw_ +@@ -123,7 +128,12 @@ static int inline arch_read_trylock(raw_rwlock_t *l= ock) "1: ldsw [%2], %0\n" " brlz,a,pn %0, 2f\n" " mov 0, %0\n" @@ -4091,7 +4645,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/s= pinlock_64.h linux-2.6.32.49/ " cas [%2], %0, %1\n" " cmp %0, %1\n" " bne,pn %%icc, 1b\n" -@@ -136,13 +146,18 @@ static int inline arch_read_trylock(raw_ +@@ -136,13 +146,18 @@ static int inline arch_read_trylock(raw_rwlock_t *= lock) return tmp1; } =20 @@ -4112,7 +4666,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/s= pinlock_64.h linux-2.6.32.49/ " cas [%2], %0, %1\n" " cmp %0, %1\n" " bne,pn %%xcc, 1b\n" -@@ -152,7 +167,7 @@ static void inline arch_read_unlock(raw_ +@@ -152,7 +167,7 @@ static void inline arch_read_unlock(raw_rwlock_t *lo= ck) : "memory"); } =20 @@ -4121,7 +4675,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/s= pinlock_64.h linux-2.6.32.49/ { unsigned long mask, tmp1, tmp2; =20 -@@ -177,7 +192,7 @@ static void inline arch_write_lock(raw_r +@@ -177,7 +192,7 @@ static void inline arch_write_lock(raw_rwlock_t *loc= k) : "memory"); } =20 @@ -4130,7 +4684,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/s= pinlock_64.h linux-2.6.32.49/ { __asm__ __volatile__( " stw %%g0, [%0]" -@@ -186,7 +201,7 @@ static void inline arch_write_unlock(raw +@@ -186,7 +201,7 @@ static void inline arch_write_unlock(raw_rwlock_t *l= ock) : "memory"); } =20 @@ -4139,9 +4693,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= spinlock_64.h linux-2.6.32.49/ { unsigned long mask, tmp1, tmp2, result; =20 -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/thread_info_32.h linux= -2.6.32.49/arch/sparc/include/asm/thread_info_32.h ---- linux-2.6.32.49/arch/sparc/include/asm/thread_info_32.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/thread_info_32.h 2011-11-15 1= 9:59:42.000000000 -0500 +diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/includ= e/asm/thread_info_32.h +index 844d73a..f787fb9 100644 +--- a/arch/sparc/include/asm/thread_info_32.h ++++ b/arch/sparc/include/asm/thread_info_32.h @@ -50,6 +50,8 @@ struct thread_info { unsigned long w_saved; =20 @@ -4151,9 +4706,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= thread_info_32.h linux-2.6.32. }; =20 /* -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/thread_info_64.h linux= -2.6.32.49/arch/sparc/include/asm/thread_info_64.h ---- linux-2.6.32.49/arch/sparc/include/asm/thread_info_64.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/thread_info_64.h 2011-11-15 1= 9:59:42.000000000 -0500 +diff --git a/arch/sparc/include/asm/thread_info_64.h b/arch/sparc/includ= e/asm/thread_info_64.h +index f78ad9a..9f55fc7 100644 +--- a/arch/sparc/include/asm/thread_info_64.h ++++ b/arch/sparc/include/asm/thread_info_64.h @@ -68,6 +68,8 @@ struct thread_info { struct pt_regs *kern_una_regs; unsigned int kern_una_insn; @@ -4163,10 +4719,29 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm= /thread_info_64.h linux-2.6.32. unsigned long fpregs[0] __attribute__ ((aligned(64))); }; =20 -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/uaccess_32.h linux-2.6= .32.49/arch/sparc/include/asm/uaccess_32.h ---- linux-2.6.32.49/arch/sparc/include/asm/uaccess_32.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/uaccess_32.h 2011-11-15 19:59= :42.000000000 -0500 -@@ -249,27 +249,46 @@ extern unsigned long __copy_user(void __ +diff --git a/arch/sparc/include/asm/uaccess.h b/arch/sparc/include/asm/u= access.h +index e88fbe5..96b0ce5 100644 +--- a/arch/sparc/include/asm/uaccess.h ++++ b/arch/sparc/include/asm/uaccess.h +@@ -1,5 +1,13 @@ + #ifndef ___ASM_SPARC_UACCESS_H + #define ___ASM_SPARC_UACCESS_H ++ ++#ifdef __KERNEL__ ++#ifndef __ASSEMBLY__ ++#include ++extern void check_object_size(const void *ptr, unsigned long n, bool to= ); ++#endif ++#endif ++ + #if defined(__sparc__) && defined(__arch64__) + #include + #else +diff --git a/arch/sparc/include/asm/uaccess_32.h b/arch/sparc/include/as= m/uaccess_32.h +index 8303ac4..07f333d 100644 +--- a/arch/sparc/include/asm/uaccess_32.h ++++ b/arch/sparc/include/asm/uaccess_32.h +@@ -249,27 +249,46 @@ extern unsigned long __copy_user(void __user *to, = const void __user *from, unsig =20 static inline unsigned long copy_to_user(void __user *to, const void *f= rom, unsigned long n) { @@ -4217,9 +4792,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/= uaccess_32.h linux-2.6.32.49/a return __copy_user((__force void __user *) to, from, n); } =20 -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/uaccess_64.h linux-2.6= .32.49/arch/sparc/include/asm/uaccess_64.h ---- linux-2.6.32.49/arch/sparc/include/asm/uaccess_64.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/uaccess_64.h 2011-11-15 19:59= :42.000000000 -0500 +diff --git a/arch/sparc/include/asm/uaccess_64.h b/arch/sparc/include/as= m/uaccess_64.h +index 9ea271e..7b8a271 100644 +--- a/arch/sparc/include/asm/uaccess_64.h ++++ b/arch/sparc/include/asm/uaccess_64.h @@ -9,6 +9,7 @@ #include #include @@ -4228,7 +4804,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/u= access_64.h linux-2.6.32.49/a #include #include #include -@@ -212,8 +213,15 @@ extern unsigned long copy_from_user_fixu +@@ -212,8 +213,15 @@ extern unsigned long copy_from_user_fixup(void *to,= const void __user *from, static inline unsigned long __must_check copy_from_user(void *to, const void __user *from, unsigned long size) { @@ -4245,7 +4821,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm/u= access_64.h linux-2.6.32.49/a if (unlikely(ret)) ret =3D copy_from_user_fixup(to, from, size); return ret; -@@ -228,8 +236,15 @@ extern unsigned long copy_to_user_fixup( +@@ -228,8 +236,15 @@ extern unsigned long copy_to_user_fixup(void __user= *to, const void *from, static inline unsigned long __must_check copy_to_user(void __user *to, const void *from, unsigned long size) { @@ -4262,27 +4838,24 @@ diff -urNp linux-2.6.32.49/arch/sparc/include/asm= /uaccess_64.h linux-2.6.32.49/a if (unlikely(ret)) ret =3D copy_to_user_fixup(to, from, size); return ret; -diff -urNp linux-2.6.32.49/arch/sparc/include/asm/uaccess.h linux-2.6.32= .49/arch/sparc/include/asm/uaccess.h ---- linux-2.6.32.49/arch/sparc/include/asm/uaccess.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/include/asm/uaccess.h 2011-11-15 19:59:42= .000000000 -0500 -@@ -1,5 +1,13 @@ - #ifndef ___ASM_SPARC_UACCESS_H - #define ___ASM_SPARC_UACCESS_H -+ -+#ifdef __KERNEL__ -+#ifndef __ASSEMBLY__ -+#include -+extern void check_object_size(const void *ptr, unsigned long n, bool to= ); -+#endif -+#endif -+ - #if defined(__sparc__) && defined(__arch64__) - #include - #else -diff -urNp linux-2.6.32.49/arch/sparc/kernel/iommu.c linux-2.6.32.49/arc= h/sparc/kernel/iommu.c ---- linux-2.6.32.49/arch/sparc/kernel/iommu.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/iommu.c 2011-11-15 19:59:42.000000= 000 -0500 -@@ -826,7 +826,7 @@ static void dma_4u_sync_sg_for_cpu(struc +diff --git a/arch/sparc/kernel/Makefile b/arch/sparc/kernel/Makefile +index 2782681..77ded84 100644 +--- a/arch/sparc/kernel/Makefile ++++ b/arch/sparc/kernel/Makefile +@@ -3,7 +3,7 @@ + # +=20 + asflags-y :=3D -ansi +-ccflags-y :=3D -Werror ++#ccflags-y :=3D -Werror +=20 + extra-y :=3D head_$(BITS).o + extra-y +=3D init_task.o +diff --git a/arch/sparc/kernel/iommu.c b/arch/sparc/kernel/iommu.c +index 7690cc2..ece64c9 100644 +--- a/arch/sparc/kernel/iommu.c ++++ b/arch/sparc/kernel/iommu.c +@@ -826,7 +826,7 @@ static void dma_4u_sync_sg_for_cpu(struct device *de= v, spin_unlock_irqrestore(&iommu->lock, flags); } =20 @@ -4291,7 +4864,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/iommu.= c linux-2.6.32.49/arch/sparc/ .alloc_coherent =3D dma_4u_alloc_coherent, .free_coherent =3D dma_4u_free_coherent, .map_page =3D dma_4u_map_page, -@@ -837,7 +837,7 @@ static struct dma_map_ops sun4u_dma_ops=20 +@@ -837,7 +837,7 @@ static struct dma_map_ops sun4u_dma_ops =3D { .sync_sg_for_cpu =3D dma_4u_sync_sg_for_cpu, }; =20 @@ -4300,10 +4873,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/iomm= u.c linux-2.6.32.49/arch/sparc/ EXPORT_SYMBOL(dma_ops); =20 extern int pci64_dma_supported(struct pci_dev *pdev, u64 device_mask); -diff -urNp linux-2.6.32.49/arch/sparc/kernel/ioport.c linux-2.6.32.49/ar= ch/sparc/kernel/ioport.c ---- linux-2.6.32.49/arch/sparc/kernel/ioport.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/ioport.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -392,7 +392,7 @@ static void sbus_sync_sg_for_device(stru +diff --git a/arch/sparc/kernel/ioport.c b/arch/sparc/kernel/ioport.c +index 9f61fd8..bd048db 100644 +--- a/arch/sparc/kernel/ioport.c ++++ b/arch/sparc/kernel/ioport.c +@@ -392,7 +392,7 @@ static void sbus_sync_sg_for_device(struct device *d= ev, struct scatterlist *sg, BUG(); } =20 @@ -4321,7 +4895,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/ioport= .c linux-2.6.32.49/arch/sparc EXPORT_SYMBOL(dma_ops); =20 static int __init sparc_register_ioport(void) -@@ -640,7 +640,7 @@ static void pci32_sync_sg_for_device(str +@@ -640,7 +640,7 @@ static void pci32_sync_sg_for_device(struct device *= device, struct scatterlist * } } =20 @@ -4330,9 +4904,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/iopor= t.c linux-2.6.32.49/arch/sparc .alloc_coherent =3D pci32_alloc_coherent, .free_coherent =3D pci32_free_coherent, .map_page =3D pci32_map_page, -diff -urNp linux-2.6.32.49/arch/sparc/kernel/kgdb_32.c linux-2.6.32.49/a= rch/sparc/kernel/kgdb_32.c ---- linux-2.6.32.49/arch/sparc/kernel/kgdb_32.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/kgdb_32.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/sparc/kernel/kgdb_32.c b/arch/sparc/kernel/kgdb_32.c +index 04df4ed..55c4b6e 100644 +--- a/arch/sparc/kernel/kgdb_32.c ++++ b/arch/sparc/kernel/kgdb_32.c @@ -158,7 +158,7 @@ void kgdb_arch_exit(void) { } @@ -4342,9 +4917,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/kgdb_= 32.c linux-2.6.32.49/arch/spar /* Breakpoint instruction: ta 0x7d */ .gdb_bpt_instr =3D { 0x91, 0xd0, 0x20, 0x7d }, }; -diff -urNp linux-2.6.32.49/arch/sparc/kernel/kgdb_64.c linux-2.6.32.49/a= rch/sparc/kernel/kgdb_64.c ---- linux-2.6.32.49/arch/sparc/kernel/kgdb_64.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/kgdb_64.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/sparc/kernel/kgdb_64.c b/arch/sparc/kernel/kgdb_64.c +index f5a0fd4..d886f71 100644 +--- a/arch/sparc/kernel/kgdb_64.c ++++ b/arch/sparc/kernel/kgdb_64.c @@ -180,7 +180,7 @@ void kgdb_arch_exit(void) { } @@ -4354,22 +4930,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/kgdb= _64.c linux-2.6.32.49/arch/spar /* Breakpoint instruction: ta 0x72 */ .gdb_bpt_instr =3D { 0x91, 0xd0, 0x20, 0x72 }, }; -diff -urNp linux-2.6.32.49/arch/sparc/kernel/Makefile linux-2.6.32.49/ar= ch/sparc/kernel/Makefile ---- linux-2.6.32.49/arch/sparc/kernel/Makefile 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/Makefile 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -3,7 +3,7 @@ - # -=20 - asflags-y :=3D -ansi --ccflags-y :=3D -Werror -+#ccflags-y :=3D -Werror -=20 - extra-y :=3D head_$(BITS).o - extra-y +=3D init_task.o -diff -urNp linux-2.6.32.49/arch/sparc/kernel/pci_sun4v.c linux-2.6.32.49= /arch/sparc/kernel/pci_sun4v.c ---- linux-2.6.32.49/arch/sparc/kernel/pci_sun4v.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/pci_sun4v.c 2011-11-15 19:59:42.00= 0000000 -0500 -@@ -525,7 +525,7 @@ static void dma_4v_unmap_sg(struct devic +diff --git a/arch/sparc/kernel/pci_sun4v.c b/arch/sparc/kernel/pci_sun4v= .c +index 23c33ff..d137fbd 100644 +--- a/arch/sparc/kernel/pci_sun4v.c ++++ b/arch/sparc/kernel/pci_sun4v.c +@@ -525,7 +525,7 @@ static void dma_4v_unmap_sg(struct device *dev, stru= ct scatterlist *sglist, spin_unlock_irqrestore(&iommu->lock, flags); } =20 @@ -4378,9 +4943,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/pci_s= un4v.c linux-2.6.32.49/arch/sp .alloc_coherent =3D dma_4v_alloc_coherent, .free_coherent =3D dma_4v_free_coherent, .map_page =3D dma_4v_map_page, -diff -urNp linux-2.6.32.49/arch/sparc/kernel/process_32.c linux-2.6.32.4= 9/arch/sparc/kernel/process_32.c ---- linux-2.6.32.49/arch/sparc/kernel/process_32.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/process_32.c 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/sparc/kernel/process_32.c b/arch/sparc/kernel/process_= 32.c +index c49865b..b41a81b 100644 +--- a/arch/sparc/kernel/process_32.c ++++ b/arch/sparc/kernel/process_32.c @@ -196,7 +196,7 @@ void __show_backtrace(unsigned long fp) rw->ins[4], rw->ins[5], rw->ins[6], @@ -4407,7 +4973,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/proces= s_32.c linux-2.6.32.49/arch/s =20 printk("%%L: %08lx %08lx %08lx %08lx %08lx %08lx %08lx %08lx\n", rw->locals[0], rw->locals[1], rw->locals[2], rw->locals[3], -@@ -305,7 +305,7 @@ void show_stack(struct task_struct *tsk, +@@ -305,7 +305,7 @@ void show_stack(struct task_struct *tsk, unsigned lo= ng *_ksp) rw =3D (struct reg_window32 *) fp; pc =3D rw->ins[7]; printk("[%08lx : ", pc); @@ -4416,10 +4982,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/proc= ess_32.c linux-2.6.32.49/arch/s fp =3D rw->ins[6]; } while (++count < 16); printk("\n"); -diff -urNp linux-2.6.32.49/arch/sparc/kernel/process_64.c linux-2.6.32.4= 9/arch/sparc/kernel/process_64.c ---- linux-2.6.32.49/arch/sparc/kernel/process_64.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/process_64.c 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -180,14 +180,14 @@ static void show_regwindow(struct pt_reg +diff --git a/arch/sparc/kernel/process_64.c b/arch/sparc/kernel/process_= 64.c +index cb70476..3d0c191 100644 +--- a/arch/sparc/kernel/process_64.c ++++ b/arch/sparc/kernel/process_64.c +@@ -180,14 +180,14 @@ static void show_regwindow(struct pt_regs *regs) printk("i4: %016lx i5: %016lx i6: %016lx i7: %016lx\n", rwk->ins[4], rwk->ins[5], rwk->ins[6], rwk->ins[7]); if (regs->tstate & TSTATE_PRIV) @@ -4445,7 +5012,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/proces= s_64.c linux-2.6.32.49/arch/s show_regwindow(regs); } =20 -@@ -284,7 +284,7 @@ void arch_trigger_all_cpu_backtrace(void +@@ -284,7 +284,7 @@ void arch_trigger_all_cpu_backtrace(void) ((tp && tp->task) ? tp->task->pid : -1)); =20 if (gp->tstate & TSTATE_PRIV) { @@ -4454,9 +5021,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/proce= ss_64.c linux-2.6.32.49/arch/s (void *) gp->tpc, (void *) gp->o7, (void *) gp->i7, -diff -urNp linux-2.6.32.49/arch/sparc/kernel/sigutil_64.c linux-2.6.32.4= 9/arch/sparc/kernel/sigutil_64.c ---- linux-2.6.32.49/arch/sparc/kernel/sigutil_64.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/sigutil_64.c 2011-11-29 18:13:57.0= 00000000 -0500 +diff --git a/arch/sparc/kernel/sigutil_64.c b/arch/sparc/kernel/sigutil_= 64.c +index 6edc4e5..06a69b4 100644 +--- a/arch/sparc/kernel/sigutil_64.c ++++ b/arch/sparc/kernel/sigutil_64.c @@ -2,6 +2,7 @@ #include #include @@ -4465,10 +5033,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sigu= til_64.c linux-2.6.32.49/arch/s =20 #include #include -diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sparc_32.c linux-2.6.32= .49/arch/sparc/kernel/sys_sparc_32.c ---- linux-2.6.32.49/arch/sparc/kernel/sys_sparc_32.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/sys_sparc_32.c 2011-11-15 19:59:42= .000000000 -0500 -@@ -57,7 +57,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/sparc/kernel/sys_sparc_32.c b/arch/sparc/kernel/sys_sp= arc_32.c +index 3a82e65..ce0a53a 100644 +--- a/arch/sparc/kernel/sys_sparc_32.c ++++ b/arch/sparc/kernel/sys_sparc_32.c +@@ -57,7 +57,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi if (ARCH_SUN4C && len > 0x20000000) return -ENOMEM; if (!addr) @@ -4477,7 +5046,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_32.c linux-2.6.32.49/arch =20 if (flags & MAP_SHARED) addr =3D COLOUR_ALIGN(addr); -@@ -72,7 +72,7 @@ unsigned long arch_get_unmapped_area(str +@@ -72,7 +72,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi } if (TASK_SIZE - PAGE_SIZE - len < addr) return -ENOMEM; @@ -4486,10 +5055,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_= sparc_32.c linux-2.6.32.49/arch return addr; addr =3D vmm->vm_end; if (flags & MAP_SHARED) -diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sparc_64.c linux-2.6.32= .49/arch/sparc/kernel/sys_sparc_64.c ---- linux-2.6.32.49/arch/sparc/kernel/sys_sparc_64.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/sys_sparc_64.c 2011-11-15 19:59:42= .000000000 -0500 -@@ -125,7 +125,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/sparc/kernel/sys_sparc_64.c b/arch/sparc/kernel/sys_sp= arc_64.c +index cfa0e19..98972ac 100644 +--- a/arch/sparc/kernel/sys_sparc_64.c ++++ b/arch/sparc/kernel/sys_sparc_64.c +@@ -125,7 +125,7 @@ unsigned long arch_get_unmapped_area(struct file *fi= lp, unsigned long addr, unsi /* We do not accept a shared mapping if it would violate * cache aliasing constraints. */ @@ -4498,7 +5068,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch ((addr - (pgoff << PAGE_SHIFT)) & (SHMLBA - 1))) return -EINVAL; return addr; -@@ -140,6 +140,10 @@ unsigned long arch_get_unmapped_area(str +@@ -140,6 +140,10 @@ unsigned long arch_get_unmapped_area(struct file *f= ilp, unsigned long addr, unsi if (filp || (flags & MAP_SHARED)) do_color_align =3D 1; =20 @@ -4509,7 +5079,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch if (addr) { if (do_color_align) addr =3D COLOUR_ALIGN(addr, pgoff); -@@ -147,15 +151,14 @@ unsigned long arch_get_unmapped_area(str +@@ -147,15 +151,14 @@ unsigned long arch_get_unmapped_area(struct file *= filp, unsigned long addr, unsi addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -4546,7 +5116,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch /* * Remember the place where we stopped the search: */ -@@ -216,7 +219,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -216,7 +219,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* We do not accept a shared mapping if it would violate * cache aliasing constraints. */ @@ -4555,7 +5125,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch ((addr - (pgoff << PAGE_SHIFT)) & (SHMLBA - 1))) return -EINVAL; return addr; -@@ -237,8 +240,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -237,8 +240,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -4565,7 +5135,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch return addr; } =20 -@@ -259,7 +261,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -259,7 +261,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* make sure it can fit in the remaining address space */ if (likely(addr > len)) { vma =3D find_vma(mm, addr-len); @@ -4574,7 +5144,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -268,18 +270,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -268,18 +270,18 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, if (unlikely(mm->mmap_base < len)) goto bottomup; =20 @@ -4597,7 +5167,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); } -@@ -289,10 +291,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -289,10 +291,8 @@ arch_get_unmapped_area_topdown(struct file *filp, c= onst unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -4610,7 +5180,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch =20 bottomup: /* -@@ -384,6 +384,12 @@ void arch_pick_mmap_layout(struct mm_str +@@ -384,6 +384,12 @@ void arch_pick_mmap_layout(struct mm_struct *mm) current->signal->rlim[RLIMIT_STACK].rlim_cur =3D=3D RLIM_INFINITY = || sysctl_legacy_va_layout) { mm->mmap_base =3D TASK_UNMAPPED_BASE + random_factor; @@ -4623,7 +5193,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_sp= arc_64.c linux-2.6.32.49/arch mm->get_unmapped_area =3D arch_get_unmapped_area; mm->unmap_area =3D arch_unmap_area; } else { -@@ -398,6 +404,12 @@ void arch_pick_mmap_layout(struct mm_str +@@ -398,6 +404,12 @@ void arch_pick_mmap_layout(struct mm_struct *mm) gap =3D (task_size / 6 * 5); =20 mm->mmap_base =3D PAGE_ALIGN(task_size - gap - random_factor); @@ -4636,10 +5206,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/sys_= sparc_64.c linux-2.6.32.49/arch mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_32.c linux-2.6.32.49/= arch/sparc/kernel/traps_32.c ---- linux-2.6.32.49/arch/sparc/kernel/traps_32.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/traps_32.c 2011-11-15 19:59:42.000= 000000 -0500 -@@ -44,6 +44,8 @@ static void instruction_dump(unsigned lo +diff --git a/arch/sparc/kernel/traps_32.c b/arch/sparc/kernel/traps_32.c +index c0490c7..84959d1 100644 +--- a/arch/sparc/kernel/traps_32.c ++++ b/arch/sparc/kernel/traps_32.c +@@ -44,6 +44,8 @@ static void instruction_dump(unsigned long *pc) #define __SAVE __asm__ __volatile__("save %sp, -0x40, %sp\n\t") #define __RESTORE __asm__ __volatile__("restore %g0, %g0, %g0\n\t") =20 @@ -4648,7 +5219,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 32.c linux-2.6.32.49/arch/spa void die_if_kernel(char *str, struct pt_regs *regs) { static int die_counter; -@@ -76,15 +78,17 @@ void die_if_kernel(char *str, struct pt_ +@@ -76,15 +78,17 @@ void die_if_kernel(char *str, struct pt_regs *regs) count++ < 30 && (((unsigned long) rw) >=3D PAGE_OFFSET) && !(((unsigned long) rw) & 0x7)) { @@ -4668,10 +5239,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/trap= s_32.c linux-2.6.32.49/arch/spa do_exit(SIGSEGV); } =20 -diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_64.c linux-2.6.32.49/= arch/sparc/kernel/traps_64.c ---- linux-2.6.32.49/arch/sparc/kernel/traps_64.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/traps_64.c 2011-11-15 19:59:42.000= 000000 -0500 -@@ -73,7 +73,7 @@ static void dump_tl1_traplog(struct tl1_ +diff --git a/arch/sparc/kernel/traps_64.c b/arch/sparc/kernel/traps_64.c +index 10f7bb9..cdb6793 100644 +--- a/arch/sparc/kernel/traps_64.c ++++ b/arch/sparc/kernel/traps_64.c +@@ -73,7 +73,7 @@ static void dump_tl1_traplog(struct tl1_traplog *p) i + 1, p->trapstack[i].tstate, p->trapstack[i].tpc, p->trapstack[i].tnpc, p->trapstack[i].tt); @@ -4680,7 +5252,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa } } =20 -@@ -93,6 +93,12 @@ void bad_trap(struct pt_regs *regs, long +@@ -93,6 +93,12 @@ void bad_trap(struct pt_regs *regs, long lvl) =20 lvl -=3D 0x100; if (regs->tstate & TSTATE_PRIV) { @@ -4693,7 +5265,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa sprintf(buffer, "Kernel bad sw trap %lx", lvl); die_if_kernel(buffer, regs); } -@@ -111,11 +117,16 @@ void bad_trap(struct pt_regs *regs, long +@@ -111,11 +117,16 @@ void bad_trap(struct pt_regs *regs, long lvl) void bad_trap_tl1(struct pt_regs *regs, long lvl) { char buffer[32]; @@ -4711,7 +5283,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa dump_tl1_traplog((struct tl1_traplog *)(regs + 1)); =20 sprintf (buffer, "Bad trap %lx at tl>0", lvl); -@@ -1139,7 +1150,7 @@ static void cheetah_log_errors(struct pt +@@ -1139,7 +1150,7 @@ static void cheetah_log_errors(struct pt_regs *reg= s, struct cheetah_err_info *in regs->tpc, regs->tnpc, regs->u_regs[UREG_I7], regs->tstate); printk("%s" "ERROR(%d): ", (recoverable ? KERN_WARNING : KERN_CRIT), smp_processor_id()); @@ -4720,7 +5292,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa printk("%s" "ERROR(%d): M_SYND(%lx), E_SYND(%lx)%s%s\n", (recoverable ? KERN_WARNING : KERN_CRIT), smp_processor_id(), (afsr & CHAFSR_M_SYNDROME) >> CHAFSR_M_SYNDROME_SHIFT, -@@ -1746,7 +1757,7 @@ void cheetah_plus_parity_error(int type, +@@ -1746,7 +1757,7 @@ void cheetah_plus_parity_error(int type, struct pt= _regs *regs) smp_processor_id(), (type & 0x1) ? 'I' : 'D', regs->tpc); @@ -4729,7 +5301,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa panic("Irrecoverable Cheetah+ parity error."); } =20 -@@ -1754,7 +1765,7 @@ void cheetah_plus_parity_error(int type, +@@ -1754,7 +1765,7 @@ void cheetah_plus_parity_error(int type, struct pt= _regs *regs) smp_processor_id(), (type & 0x1) ? 'I' : 'D', regs->tpc); @@ -4738,7 +5310,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa } =20 struct sun4v_error_entry { -@@ -1961,9 +1972,9 @@ void sun4v_itlb_error_report(struct pt_r +@@ -1961,9 +1972,9 @@ void sun4v_itlb_error_report(struct pt_regs *regs,= int tl) =20 printk(KERN_EMERG "SUN4V-ITLB: Error at TPC[%lx], tl %d\n", regs->tpc, tl); @@ -4750,7 +5322,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa (void *) regs->u_regs[UREG_I7]); printk(KERN_EMERG "SUN4V-ITLB: vaddr[%lx] ctx[%lx] " "pte[%lx] error[%lx]\n", -@@ -1985,9 +1996,9 @@ void sun4v_dtlb_error_report(struct pt_r +@@ -1985,9 +1996,9 @@ void sun4v_dtlb_error_report(struct pt_regs *regs,= int tl) =20 printk(KERN_EMERG "SUN4V-DTLB: Error at TPC[%lx], tl %d\n", regs->tpc, tl); @@ -4762,7 +5334,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa (void *) regs->u_regs[UREG_I7]); printk(KERN_EMERG "SUN4V-DTLB: vaddr[%lx] ctx[%lx] " "pte[%lx] error[%lx]\n", -@@ -2191,7 +2202,7 @@ void show_stack(struct task_struct *tsk, +@@ -2191,7 +2202,7 @@ void show_stack(struct task_struct *tsk, unsigned = long *_ksp) fp =3D (unsigned long)sf->fp + STACK_BIAS; } =20 @@ -4771,7 +5343,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa } while (++count < 16); } =20 -@@ -2233,6 +2244,8 @@ static inline struct reg_window *kernel_ +@@ -2233,6 +2244,8 @@ static inline struct reg_window *kernel_stack_up(s= truct reg_window *rw) return (struct reg_window *) (fp + STACK_BIAS); } =20 @@ -4780,7 +5352,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa void die_if_kernel(char *str, struct pt_regs *regs) { static int die_counter; -@@ -2260,7 +2273,7 @@ void die_if_kernel(char *str, struct pt_ +@@ -2260,7 +2273,7 @@ void die_if_kernel(char *str, struct pt_regs *regs= ) while (rw && count++ < 30&& is_kernel_stack(current, rw)) { @@ -4789,7 +5361,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps_= 64.c linux-2.6.32.49/arch/spa (void *) rw->ins[7]); =20 rw =3D kernel_stack_up(rw); -@@ -2273,8 +2286,11 @@ void die_if_kernel(char *str, struct pt_ +@@ -2273,8 +2286,11 @@ void die_if_kernel(char *str, struct pt_regs *reg= s) } user_instruction_dump ((unsigned int __user *) regs->tpc); } @@ -4802,9 +5374,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/traps= _64.c linux-2.6.32.49/arch/spa do_exit(SIGSEGV); } EXPORT_SYMBOL(die_if_kernel); -diff -urNp linux-2.6.32.49/arch/sparc/kernel/una_asm_64.S linux-2.6.32.4= 9/arch/sparc/kernel/una_asm_64.S ---- linux-2.6.32.49/arch/sparc/kernel/una_asm_64.S 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/una_asm_64.S 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/sparc/kernel/una_asm_64.S b/arch/sparc/kernel/una_asm_= 64.S +index be183fe..1c8d332 100644 +--- a/arch/sparc/kernel/una_asm_64.S ++++ b/arch/sparc/kernel/una_asm_64.S @@ -127,7 +127,7 @@ do_int_load: wr %o5, 0x0, %asi retl @@ -4814,10 +5387,11 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/una_= asm_64.S linux-2.6.32.49/arch/s =20 .section __ex_table,"a" .word 4b, __retl_efault -diff -urNp linux-2.6.32.49/arch/sparc/kernel/unaligned_64.c linux-2.6.32= .49/arch/sparc/kernel/unaligned_64.c ---- linux-2.6.32.49/arch/sparc/kernel/unaligned_64.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/sparc/kernel/unaligned_64.c 2011-11-15 19:59:42= .000000000 -0500 -@@ -288,7 +288,7 @@ static void log_unaligned(struct pt_regs +diff --git a/arch/sparc/kernel/unaligned_64.c b/arch/sparc/kernel/unalig= ned_64.c +index 3792099..2af17d8 100644 +--- a/arch/sparc/kernel/unaligned_64.c ++++ b/arch/sparc/kernel/unaligned_64.c +@@ -288,7 +288,7 @@ static void log_unaligned(struct pt_regs *regs) if (count < 5) { last_time =3D jiffies; count++; @@ -4826,9 +5400,23 @@ diff -urNp linux-2.6.32.49/arch/sparc/kernel/unali= gned_64.c linux-2.6.32.49/arch regs->tpc, (void *) regs->tpc); } } -diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64.S linux-2.6.32.49/ar= ch/sparc/lib/atomic_64.S ---- linux-2.6.32.49/arch/sparc/lib/atomic_64.S 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/sparc/lib/atomic_64.S 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/sparc/lib/Makefile b/arch/sparc/lib/Makefile +index e75faf0..24f12f9 100644 +--- a/arch/sparc/lib/Makefile ++++ b/arch/sparc/lib/Makefile +@@ -2,7 +2,7 @@ + # +=20 + asflags-y :=3D -ansi -DST_DIV0=3D0x02 +-ccflags-y :=3D -Werror ++#ccflags-y :=3D -Werror +=20 + lib-$(CONFIG_SPARC32) +=3D mul.o rem.o sdiv.o udiv.o umul.o urem.o ashr= di3.o + lib-$(CONFIG_SPARC32) +=3D memcpy.o memset.o +diff --git a/arch/sparc/lib/atomic_64.S b/arch/sparc/lib/atomic_64.S +index 0268210..f0291ca 100644 +--- a/arch/sparc/lib/atomic_64.S ++++ b/arch/sparc/lib/atomic_64.S @@ -18,7 +18,12 @@ atomic_add: /* %o0 =3D increment, %o1 =3D atomic_ptr */ BACKOFF_SETUP(%o2) @@ -4843,7 +5431,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64= .S linux-2.6.32.49/arch/sparc cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, 2f -@@ -28,12 +33,32 @@ atomic_add: /* %o0 =3D increment, %o1 =3D at +@@ -28,12 +33,32 @@ atomic_add: /* %o0 =3D increment, %o1 =3D atomic_ptr= */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_add, .-atomic_add =20 @@ -4877,7 +5465,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64= .S linux-2.6.32.49/arch/sparc cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, 2f -@@ -43,12 +68,32 @@ atomic_sub: /* %o0 =3D decrement, %o1 =3D at +@@ -43,12 +68,32 @@ atomic_sub: /* %o0 =3D decrement, %o1 =3D atomic_ptr= */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_sub, .-atomic_sub =20 @@ -4911,7 +5499,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64= .S linux-2.6.32.49/arch/sparc cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, 2f -@@ -59,12 +104,33 @@ atomic_add_ret: /* %o0 =3D increment, %o1=20 +@@ -59,12 +104,33 @@ atomic_add_ret: /* %o0 =3D increment, %o1 =3D atomi= c_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_add_ret, .-atomic_add_ret =20 @@ -4946,7 +5534,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64= .S linux-2.6.32.49/arch/sparc cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, 2f -@@ -80,7 +146,12 @@ atomic_sub_ret: /* %o0 =3D decrement, %o1=20 +@@ -80,7 +146,12 @@ atomic_sub_ret: /* %o0 =3D decrement, %o1 =3D atomic= _ptr */ atomic64_add: /* %o0 =3D increment, %o1 =3D atomic_ptr */ BACKOFF_SETUP(%o2) 1: ldx [%o1], %g1 @@ -4960,7 +5548,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64= .S linux-2.6.32.49/arch/sparc casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, 2f -@@ -90,12 +161,32 @@ atomic64_add: /* %o0 =3D increment, %o1 =3D=20 +@@ -90,12 +161,32 @@ atomic64_add: /* %o0 =3D increment, %o1 =3D atomic_= ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_add, .-atomic64_add =20 @@ -4994,7 +5582,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64= .S linux-2.6.32.49/arch/sparc casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, 2f -@@ -105,12 +196,32 @@ atomic64_sub: /* %o0 =3D decrement, %o1 =3D=20 +@@ -105,12 +196,32 @@ atomic64_sub: /* %o0 =3D decrement, %o1 =3D atomic= _ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_sub, .-atomic64_sub =20 @@ -5028,7 +5616,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_64= .S linux-2.6.32.49/arch/sparc casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, 2f -@@ -121,12 +232,33 @@ atomic64_add_ret: /* %o0 =3D increment, %o +@@ -121,12 +232,33 @@ atomic64_add_ret: /* %o0 =3D increment, %o1 =3D at= omic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_add_ret, .-atomic64_add_ret =20 @@ -5063,9 +5651,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/atomic_6= 4.S linux-2.6.32.49/arch/sparc casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, 2f -diff -urNp linux-2.6.32.49/arch/sparc/lib/ksyms.c linux-2.6.32.49/arch/s= parc/lib/ksyms.c ---- linux-2.6.32.49/arch/sparc/lib/ksyms.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/sparc/lib/ksyms.c 2011-11-15 19:59:42.000000000= -0500 +diff --git a/arch/sparc/lib/ksyms.c b/arch/sparc/lib/ksyms.c +index 704b126..2e79d76 100644 +--- a/arch/sparc/lib/ksyms.c ++++ b/arch/sparc/lib/ksyms.c @@ -144,12 +144,18 @@ EXPORT_SYMBOL(__downgrade_write); =20 /* Atomic counter implementation. */ @@ -5085,21 +5674,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/ksyms.c= linux-2.6.32.49/arch/sparc/lib EXPORT_SYMBOL(atomic64_sub_ret); =20 /* Atomic bit operations. */ -diff -urNp linux-2.6.32.49/arch/sparc/lib/Makefile linux-2.6.32.49/arch/= sparc/lib/Makefile ---- linux-2.6.32.49/arch/sparc/lib/Makefile 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/sparc/lib/Makefile 2011-11-15 19:59:42.00000000= 0 -0500 -@@ -2,7 +2,7 @@ - # -=20 - asflags-y :=3D -ansi -DST_DIV0=3D0x02 --ccflags-y :=3D -Werror -+#ccflags-y :=3D -Werror -=20 - lib-$(CONFIG_SPARC32) +=3D mul.o rem.o sdiv.o udiv.o umul.o urem.o ashr= di3.o - lib-$(CONFIG_SPARC32) +=3D memcpy.o memset.o -diff -urNp linux-2.6.32.49/arch/sparc/lib/rwsem_64.S linux-2.6.32.49/arc= h/sparc/lib/rwsem_64.S ---- linux-2.6.32.49/arch/sparc/lib/rwsem_64.S 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/sparc/lib/rwsem_64.S 2011-11-15 19:59:42.000000= 000 -0500 +diff --git a/arch/sparc/lib/rwsem_64.S b/arch/sparc/lib/rwsem_64.S +index 91a7d29..ce75c29 100644 +--- a/arch/sparc/lib/rwsem_64.S ++++ b/arch/sparc/lib/rwsem_64.S @@ -11,7 +11,12 @@ .globl __down_read __down_read: @@ -5198,21 +5776,23 @@ diff -urNp linux-2.6.32.49/arch/sparc/lib/rwsem_6= 4.S linux-2.6.32.49/arch/sparc/ cas [%o0], %g3, %g7 cmp %g3, %g7 bne,pn %icc, 1b -diff -urNp linux-2.6.32.49/arch/sparc/Makefile linux-2.6.32.49/arch/spar= c/Makefile ---- linux-2.6.32.49/arch/sparc/Makefile 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/sparc/Makefile 2011-11-15 19:59:42.000000000 -0= 500 -@@ -75,7 +75,7 @@ drivers-$(CONFIG_OPROFILE) +=3D arch/sparc - # Export what is needed by arch/sparc/boot/Makefile - export VMLINUX_INIT VMLINUX_MAIN - VMLINUX_INIT :=3D $(head-y) $(init-y) --VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ -+VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ grsecurity/ - VMLINUX_MAIN +=3D $(patsubst %/, %/lib.a, $(libs-y)) $(libs-y) - VMLINUX_MAIN +=3D $(drivers-y) $(net-y) +diff --git a/arch/sparc/mm/Makefile b/arch/sparc/mm/Makefile +index 79836a7..62f47a2 100644 +--- a/arch/sparc/mm/Makefile ++++ b/arch/sparc/mm/Makefile +@@ -2,7 +2,7 @@ + # +=20 + asflags-y :=3D -ansi +-ccflags-y :=3D -Werror ++#ccflags-y :=3D -Werror =20 -diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_32.c linux-2.6.32.49/arch= /sparc/mm/fault_32.c ---- linux-2.6.32.49/arch/sparc/mm/fault_32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/sparc/mm/fault_32.c 2011-11-18 18:01:52.0000000= 00 -0500 + obj-$(CONFIG_SPARC64) +=3D ultra.o tlb.o tsb.o + obj-y +=3D fault_$(BITS).o +diff --git a/arch/sparc/mm/fault_32.c b/arch/sparc/mm/fault_32.c +index b99f81c..3453e93 100644 +--- a/arch/sparc/mm/fault_32.c ++++ b/arch/sparc/mm/fault_32.c @@ -21,6 +21,9 @@ #include #include @@ -5223,7 +5803,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_32.c= linux-2.6.32.49/arch/sparc/m =20 #include #include -@@ -167,6 +170,267 @@ static unsigned long compute_si_addr(str +@@ -167,6 +170,267 @@ static unsigned long compute_si_addr(struct pt_reg= s *regs, int text_fault) return safe_compute_effective_address(regs, insn); } =20 @@ -5516,9 +6096,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_32.= c linux-2.6.32.49/arch/sparc/m /* Allow reads even for write-only mappings */ if(!(vma->vm_flags & (VM_READ | VM_EXEC))) goto bad_area; -diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_64.c linux-2.6.32.49/arch= /sparc/mm/fault_64.c ---- linux-2.6.32.49/arch/sparc/mm/fault_64.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/sparc/mm/fault_64.c 2011-11-18 18:01:52.0000000= 00 -0500 +diff --git a/arch/sparc/mm/fault_64.c b/arch/sparc/mm/fault_64.c +index 43b0da9..a0b78f9 100644 +--- a/arch/sparc/mm/fault_64.c ++++ b/arch/sparc/mm/fault_64.c @@ -20,6 +20,9 @@ #include #include @@ -5529,7 +6110,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_64.c= linux-2.6.32.49/arch/sparc/m =20 #include #include -@@ -78,7 +81,7 @@ static void bad_kernel_pc(struct pt_regs +@@ -78,7 +81,7 @@ static void bad_kernel_pc(struct pt_regs *regs, unsign= ed long vaddr) printk(KERN_CRIT "OOPS: Bogus kernel PC [%016lx] in fault handler\n", regs->tpc); printk(KERN_CRIT "OOPS: RPC [%016lx]\n", regs->u_regs[15]); @@ -5538,7 +6119,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_64.c= linux-2.6.32.49/arch/sparc/m printk(KERN_CRIT "OOPS: Fault was to vaddr[%lx]\n", vaddr); dump_stack(); unhandled_fault(regs->tpc, current, regs); -@@ -249,6 +252,456 @@ static void noinline bogus_32bit_fault_a +@@ -249,6 +252,456 @@ static void noinline bogus_32bit_fault_address(str= uct pt_regs *regs, show_regs(regs); } =20 @@ -5995,7 +6576,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_64.c= linux-2.6.32.49/arch/sparc/m asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs) { struct mm_struct *mm =3D current->mm; -@@ -315,6 +768,29 @@ asmlinkage void __kprobes do_sparc64_fau +@@ -315,6 +768,29 @@ asmlinkage void __kprobes do_sparc64_fault(struct p= t_regs *regs) if (!vma) goto bad_area; =20 @@ -6025,9 +6606,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/fault_64.= c linux-2.6.32.49/arch/sparc/m /* Pure DTLB misses do not tell us whether the fault causing * load/store/atomic was a write or not, it only says that there * was no match. So in such a case we (carefully) read the -diff -urNp linux-2.6.32.49/arch/sparc/mm/hugetlbpage.c linux-2.6.32.49/a= rch/sparc/mm/hugetlbpage.c ---- linux-2.6.32.49/arch/sparc/mm/hugetlbpage.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/sparc/mm/hugetlbpage.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/sparc/mm/hugetlbpage.c b/arch/sparc/mm/hugetlbpage.c +index f27d103..1b06377 100644 +--- a/arch/sparc/mm/hugetlbpage.c ++++ b/arch/sparc/mm/hugetlbpage.c @@ -69,7 +69,7 @@ full_search: } return -ENOMEM; @@ -6037,7 +6619,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/hugetlbpag= e.c linux-2.6.32.49/arch/spar /* * Remember the place where we stopped the search: */ -@@ -108,7 +108,7 @@ hugetlb_get_unmapped_area_topdown(struct +@@ -108,7 +108,7 @@ hugetlb_get_unmapped_area_topdown(struct file *filp,= const unsigned long addr0, /* make sure it can fit in the remaining address space */ if (likely(addr > len)) { vma =3D find_vma(mm, addr-len); @@ -6046,7 +6628,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/hugetlbpag= e.c linux-2.6.32.49/arch/spar /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -117,16 +117,17 @@ hugetlb_get_unmapped_area_topdown(struct +@@ -117,16 +117,17 @@ hugetlb_get_unmapped_area_topdown(struct file *fil= p, const unsigned long addr0, if (unlikely(mm->mmap_base < len)) goto bottomup; =20 @@ -6066,7 +6648,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/hugetlbpag= e.c linux-2.6.32.49/arch/spar /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); } -@@ -136,8 +137,8 @@ hugetlb_get_unmapped_area_topdown(struct +@@ -136,8 +137,8 @@ hugetlb_get_unmapped_area_topdown(struct file *filp,= const unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -6077,7 +6659,7 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/hugetlbpag= e.c linux-2.6.32.49/arch/spar =20 bottomup: /* -@@ -183,8 +184,7 @@ hugetlb_get_unmapped_area(struct file *f +@@ -183,8 +184,7 @@ hugetlb_get_unmapped_area(struct file *file, unsigne= d long addr, if (addr) { addr =3D ALIGN(addr, HPAGE_SIZE); vma =3D find_vma(mm, addr); @@ -6087,9 +6669,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/hugetlbpa= ge.c linux-2.6.32.49/arch/spar return addr; } if (mm->get_unmapped_area =3D=3D arch_get_unmapped_area) -diff -urNp linux-2.6.32.49/arch/sparc/mm/init_32.c linux-2.6.32.49/arch/= sparc/mm/init_32.c ---- linux-2.6.32.49/arch/sparc/mm/init_32.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/sparc/mm/init_32.c 2011-11-15 19:59:42.00000000= 0 -0500 +diff --git a/arch/sparc/mm/init_32.c b/arch/sparc/mm/init_32.c +index dc7c3b1..34c0070 100644 +--- a/arch/sparc/mm/init_32.c ++++ b/arch/sparc/mm/init_32.c @@ -317,6 +317,9 @@ extern void device_scan(void); pgprot_t PAGE_SHARED __read_mostly; EXPORT_SYMBOL(PAGE_SHARED); @@ -6124,21 +6707,10 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/init_32.= c linux-2.6.32.49/arch/sparc/mm protection_map[12] =3D PAGE_READONLY; protection_map[13] =3D PAGE_READONLY; protection_map[14] =3D PAGE_SHARED; -diff -urNp linux-2.6.32.49/arch/sparc/mm/Makefile linux-2.6.32.49/arch/s= parc/mm/Makefile ---- linux-2.6.32.49/arch/sparc/mm/Makefile 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/sparc/mm/Makefile 2011-11-15 19:59:42.000000000= -0500 -@@ -2,7 +2,7 @@ - # -=20 - asflags-y :=3D -ansi --ccflags-y :=3D -Werror -+#ccflags-y :=3D -Werror -=20 - obj-$(CONFIG_SPARC64) +=3D ultra.o tlb.o tsb.o - obj-y +=3D fault_$(BITS).o -diff -urNp linux-2.6.32.49/arch/sparc/mm/srmmu.c linux-2.6.32.49/arch/sp= arc/mm/srmmu.c ---- linux-2.6.32.49/arch/sparc/mm/srmmu.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/sparc/mm/srmmu.c 2011-11-15 19:59:42.000000000 = -0500 +diff --git a/arch/sparc/mm/srmmu.c b/arch/sparc/mm/srmmu.c +index 509b1ff..bfd7118 100644 +--- a/arch/sparc/mm/srmmu.c ++++ b/arch/sparc/mm/srmmu.c @@ -2200,6 +2200,13 @@ void __init ld_mmu_srmmu(void) PAGE_SHARED =3D pgprot_val(SRMMU_PAGE_SHARED); BTFIXUPSET_INT(page_copy, pgprot_val(SRMMU_PAGE_COPY)); @@ -6153,9 +6725,25 @@ diff -urNp linux-2.6.32.49/arch/sparc/mm/srmmu.c l= inux-2.6.32.49/arch/sparc/mm/s BTFIXUPSET_INT(page_kernel, pgprot_val(SRMMU_PAGE_KERNEL)); page_kernel =3D pgprot_val(SRMMU_PAGE_KERNEL); =20 -diff -urNp linux-2.6.32.49/arch/um/include/asm/kmap_types.h linux-2.6.32= .49/arch/um/include/asm/kmap_types.h ---- linux-2.6.32.49/arch/um/include/asm/kmap_types.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/um/include/asm/kmap_types.h 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/um/Makefile b/arch/um/Makefile +index fc633db..5e1a1c2 100644 +--- a/arch/um/Makefile ++++ b/arch/um/Makefile +@@ -49,6 +49,10 @@ USER_CFLAGS =3D $(patsubst $(KERNEL_DEFINES),,$(patsu= bst -D__KERNEL__,,\ + $(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \ + $(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=3D64 +=20 ++ifdef CONSTIFY_PLUGIN ++USER_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-con= stify ++endif ++ + include $(srctree)/$(ARCH_DIR)/Makefile-$(SUBARCH) +=20 + #This will adjust *FLAGS accordingly to the platform. +diff --git a/arch/um/include/asm/kmap_types.h b/arch/um/include/asm/kmap= _types.h +index 6c03acd..a5e0215 100644 +--- a/arch/um/include/asm/kmap_types.h ++++ b/arch/um/include/asm/kmap_types.h @@ -23,6 +23,7 @@ enum km_type { KM_IRQ1, KM_SOFTIRQ0, @@ -6164,9 +6752,10 @@ diff -urNp linux-2.6.32.49/arch/um/include/asm/kma= p_types.h linux-2.6.32.49/arch KM_TYPE_NR }; =20 -diff -urNp linux-2.6.32.49/arch/um/include/asm/page.h linux-2.6.32.49/ar= ch/um/include/asm/page.h ---- linux-2.6.32.49/arch/um/include/asm/page.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/um/include/asm/page.h 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/um/include/asm/page.h b/arch/um/include/asm/page.h +index 4cc9b6c..02e5029 100644 +--- a/arch/um/include/asm/page.h ++++ b/arch/um/include/asm/page.h @@ -14,6 +14,9 @@ #define PAGE_SIZE (_AC(1, UL) << PAGE_SHIFT) #define PAGE_MASK (~(PAGE_SIZE-1)) @@ -6177,9 +6766,10 @@ diff -urNp linux-2.6.32.49/arch/um/include/asm/pag= e.h linux-2.6.32.49/arch/um/in #ifndef __ASSEMBLY__ =20 struct page; -diff -urNp linux-2.6.32.49/arch/um/kernel/process.c linux-2.6.32.49/arch= /um/kernel/process.c ---- linux-2.6.32.49/arch/um/kernel/process.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/um/kernel/process.c 2011-11-15 19:59:42.0000000= 00 -0500 +diff --git a/arch/um/kernel/process.c b/arch/um/kernel/process.c +index 4a28a15..654dc2a 100644 +--- a/arch/um/kernel/process.c ++++ b/arch/um/kernel/process.c @@ -393,22 +393,6 @@ int singlestepping(void * t) return 2; } @@ -6203,23 +6793,10 @@ diff -urNp linux-2.6.32.49/arch/um/kernel/process= .c linux-2.6.32.49/arch/um/kern unsigned long get_wchan(struct task_struct *p) { unsigned long stack_page, sp, ip; -diff -urNp linux-2.6.32.49/arch/um/Makefile linux-2.6.32.49/arch/um/Make= file ---- linux-2.6.32.49/arch/um/Makefile 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/um/Makefile 2011-11-18 18:01:52.000000000 -0500 -@@ -49,6 +49,10 @@ USER_CFLAGS =3D $(patsubst $(KERNEL_DEFINE - $(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \ - $(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=3D64 -=20 -+ifdef CONSTIFY_PLUGIN -+USER_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-con= stify -+endif -+ - include $(srctree)/$(ARCH_DIR)/Makefile-$(SUBARCH) -=20 - #This will adjust *FLAGS accordingly to the platform. -diff -urNp linux-2.6.32.49/arch/um/sys-i386/shared/sysdep/system.h linux= -2.6.32.49/arch/um/sys-i386/shared/sysdep/system.h ---- linux-2.6.32.49/arch/um/sys-i386/shared/sysdep/system.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/um/sys-i386/shared/sysdep/system.h 2011-11-18 1= 8:01:52.000000000 -0500 +diff --git a/arch/um/sys-i386/shared/sysdep/system.h b/arch/um/sys-i386/= shared/sysdep/system.h +index d1b93c4..ae1b7fd 100644 +--- a/arch/um/sys-i386/shared/sysdep/system.h ++++ b/arch/um/sys-i386/shared/sysdep/system.h @@ -17,7 +17,7 @@ # define AT_VECTOR_SIZE_ARCH 1 #endif @@ -6229,9 +6806,10 @@ diff -urNp linux-2.6.32.49/arch/um/sys-i386/shared= /sysdep/system.h linux-2.6.32. =20 void default_idle(void); =20 -diff -urNp linux-2.6.32.49/arch/um/sys-i386/syscalls.c linux-2.6.32.49/a= rch/um/sys-i386/syscalls.c ---- linux-2.6.32.49/arch/um/sys-i386/syscalls.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/um/sys-i386/syscalls.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/um/sys-i386/syscalls.c b/arch/um/sys-i386/syscalls.c +index 857ca0b..9a2669d 100644 +--- a/arch/um/sys-i386/syscalls.c ++++ b/arch/um/sys-i386/syscalls.c @@ -11,6 +11,21 @@ #include "asm/uaccess.h" #include "asm/unistd.h" @@ -6254,9 +6832,10 @@ diff -urNp linux-2.6.32.49/arch/um/sys-i386/syscal= ls.c linux-2.6.32.49/arch/um/s /* * Perform the select(nd, in, out, ex, tv) and mmap() system * calls. Linux/i386 didn't use to be able to handle more than -diff -urNp linux-2.6.32.49/arch/um/sys-x86_64/shared/sysdep/system.h lin= ux-2.6.32.49/arch/um/sys-x86_64/shared/sysdep/system.h ---- linux-2.6.32.49/arch/um/sys-x86_64/shared/sysdep/system.h 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/um/sys-x86_64/shared/sysdep/system.h 2011-11-18= 18:01:52.000000000 -0500 +diff --git a/arch/um/sys-x86_64/shared/sysdep/system.h b/arch/um/sys-x86= _64/shared/sysdep/system.h +index d1b93c4..ae1b7fd 100644 +--- a/arch/um/sys-x86_64/shared/sysdep/system.h ++++ b/arch/um/sys-x86_64/shared/sysdep/system.h @@ -17,7 +17,7 @@ # define AT_VECTOR_SIZE_ARCH 1 #endif @@ -6266,10 +6845,170 @@ diff -urNp linux-2.6.32.49/arch/um/sys-x86_64/sh= ared/sysdep/system.h linux-2.6.3 =20 void default_idle(void); =20 -diff -urNp linux-2.6.32.49/arch/x86/boot/bitops.h linux-2.6.32.49/arch/x= 86/boot/bitops.h ---- linux-2.6.32.49/arch/x86/boot/bitops.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/boot/bitops.h 2011-11-15 19:59:42.000000000= -0500 -@@ -26,7 +26,7 @@ static inline int variable_test_bit(int=20 +diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig +index 73ae02a..f932de5 100644 +--- a/arch/x86/Kconfig ++++ b/arch/x86/Kconfig +@@ -223,7 +223,7 @@ config X86_TRAMPOLINE +=20 + config X86_32_LAZY_GS + def_bool y +- depends on X86_32 && !CC_STACKPROTECTOR ++ depends on X86_32 && !CC_STACKPROTECTOR && !PAX_MEMORY_UDEREF +=20 + config KTIME_SCALAR + def_bool X86_32 +@@ -1008,7 +1008,7 @@ choice +=20 + config NOHIGHMEM + bool "off" +- depends on !X86_NUMAQ ++ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) + ---help--- + Linux can use up to 64 Gigabytes of physical memory on x86 systems. + However, the address space of 32-bit x86 processors is only 4 +@@ -1045,7 +1045,7 @@ config NOHIGHMEM +=20 + config HIGHMEM4G + bool "4GB" +- depends on !X86_NUMAQ ++ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) + ---help--- + Select this if you have a 32-bit processor and between 1 and 4 + gigabytes of physical RAM. +@@ -1099,7 +1099,7 @@ config PAGE_OFFSET + hex + default 0xB0000000 if VMSPLIT_3G_OPT + default 0x80000000 if VMSPLIT_2G +- default 0x78000000 if VMSPLIT_2G_OPT ++ default 0x70000000 if VMSPLIT_2G_OPT + default 0x40000000 if VMSPLIT_1G + default 0xC0000000 + depends on X86_32 +@@ -1460,6 +1460,7 @@ config SECCOMP +=20 + config CC_STACKPROTECTOR + bool "Enable -fstack-protector buffer overflow detection (EXPERIMENTAL= )" ++ depends on X86_64 || !PAX_MEMORY_UDEREF + ---help--- + This option turns on the -fstack-protector GCC feature. This + feature puts, at the beginning of functions, a canary value on +@@ -1517,6 +1518,7 @@ config KEXEC_JUMP + config PHYSICAL_START + hex "Physical address where the kernel is loaded" if (EMBEDDED || CRAS= H_DUMP) + default "0x1000000" ++ range 0x400000 0x40000000 + ---help--- + This gives the physical address where the kernel is loaded. +=20 +@@ -1581,6 +1583,7 @@ config PHYSICAL_ALIGN + hex + prompt "Alignment value to which kernel should be aligned" if X86_32 + default "0x1000000" ++ range 0x400000 0x1000000 if PAX_KERNEXEC + range 0x2000 0x1000000 + ---help--- + This value puts the alignment restrictions on physical address +@@ -1612,9 +1615,10 @@ config HOTPLUG_CPU + Say N if you want to disable CPU hotplug. +=20 + config COMPAT_VDSO +- def_bool y ++ def_bool n + prompt "Compat VDSO support" + depends on X86_32 || IA32_EMULATION ++ depends on !PAX_NOEXEC && !PAX_MEMORY_UDEREF + ---help--- + Map the 32-bit VDSO to the predictable old-style address too. + ---help--- +diff --git a/arch/x86/Kconfig.cpu b/arch/x86/Kconfig.cpu +index 0e566103..1a6b57e 100644 +--- a/arch/x86/Kconfig.cpu ++++ b/arch/x86/Kconfig.cpu +@@ -340,7 +340,7 @@ config X86_PPRO_FENCE +=20 + config X86_F00F_BUG + def_bool y +- depends on M586MMX || M586TSC || M586 || M486 || M386 ++ depends on (M586MMX || M586TSC || M586 || M486 || M386) && !PAX_KERNEX= EC +=20 + config X86_WP_WORKS_OK + def_bool y +@@ -360,7 +360,7 @@ config X86_POPAD_OK +=20 + config X86_ALIGNMENT_16 + def_bool y +- depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || X86_ELAN || MK6 ||= M586MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 ++ depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || X86_ELAN || MK8 ||= MK7 || MK6 || MCORE2 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 |= | M586MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 +=20 + config X86_INTEL_USERCOPY + def_bool y +@@ -406,7 +406,7 @@ config X86_CMPXCHG64 + # generates cmov. + config X86_CMOV + def_bool y +- depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUM= III || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEFFICEON |= | X86_64 || MATOM) ++ depends on (MK8 || MK7 || MCORE2 || MPSC || MPENTIUM4 || MPENTIUMM || = MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEF= FICEON || X86_64 || MATOM) +=20 + config X86_MINIMUM_CPU_FAMILY + int +diff --git a/arch/x86/Kconfig.debug b/arch/x86/Kconfig.debug +index d105f29..c928727 100644 +--- a/arch/x86/Kconfig.debug ++++ b/arch/x86/Kconfig.debug +@@ -99,7 +99,7 @@ config X86_PTDUMP + config DEBUG_RODATA + bool "Write protect kernel read-only data structures" + default y +- depends on DEBUG_KERNEL ++ depends on DEBUG_KERNEL && BROKEN + ---help--- + Mark the kernel read-only data as write-protected in the pagetables, + in order to catch accidental (and incorrect) writes to such const +diff --git a/arch/x86/Makefile b/arch/x86/Makefile +index d2d24c9..0f21f8d 100644 +--- a/arch/x86/Makefile ++++ b/arch/x86/Makefile +@@ -44,6 +44,7 @@ ifeq ($(CONFIG_X86_32),y) + else + BITS :=3D 64 + UTS_MACHINE :=3D x86_64 ++ biarch :=3D $(call cc-option,-m64) + CHECKFLAGS +=3D -D__x86_64__ -m64 +=20 + KBUILD_AFLAGS +=3D -m64 +@@ -189,3 +190,12 @@ define archhelp + echo ' FDARGS=3D"..." arguments for the booted ker= nel' + echo ' FDINITRD=3Dfile initrd for the booted kernel= ' + endef ++ ++define OLD_LD ++ ++*** ${VERSION}.${PATCHLEVEL} PaX kernels no longer build correctly with= old versions of binutils. ++*** Please upgrade your binutils to 2.18 or newer ++endef ++ ++archprepare: ++ $(if $(LDFLAGS_BUILD_ID),,$(error $(OLD_LD))) +diff --git a/arch/x86/boot/Makefile b/arch/x86/boot/Makefile +index ec749c2..bbb5319 100644 +--- a/arch/x86/boot/Makefile ++++ b/arch/x86/boot/Makefile +@@ -69,6 +69,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os -D_SETUP -D_= _KERNEL__ \ + $(call cc-option, -fno-stack-protector) \ + $(call cc-option, -mpreferred-stack-boundary=3D2) + KBUILD_CFLAGS +=3D $(call cc-option, -m32) ++ifdef CONSTIFY_PLUGIN ++KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify ++endif + KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ + GCOV_PROFILE :=3D n +=20 +diff --git a/arch/x86/boot/bitops.h b/arch/x86/boot/bitops.h +index 878e4b9..20537ab 100644 +--- a/arch/x86/boot/bitops.h ++++ b/arch/x86/boot/bitops.h +@@ -26,7 +26,7 @@ static inline int variable_test_bit(int nr, const void= *addr) u8 v; const u32 *p =3D (const u32 *)addr; =20 @@ -6278,7 +7017,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/bitops.h l= inux-2.6.32.49/arch/x86/boot/ return v; } =20 -@@ -37,7 +37,7 @@ static inline int variable_test_bit(int=20 +@@ -37,7 +37,7 @@ static inline int variable_test_bit(int nr, const void= *addr) =20 static inline void set_bit(int nr, void *addr) { @@ -6287,9 +7026,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/bitops.h = linux-2.6.32.49/arch/x86/boot/ } =20 #endif /* BOOT_BITOPS_H */ -diff -urNp linux-2.6.32.49/arch/x86/boot/boot.h linux-2.6.32.49/arch/x86= /boot/boot.h ---- linux-2.6.32.49/arch/x86/boot/boot.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/arch/x86/boot/boot.h 2011-11-15 19:59:42.000000000 -= 0500 +diff --git a/arch/x86/boot/boot.h b/arch/x86/boot/boot.h +index 98239d2..f40214c 100644 +--- a/arch/x86/boot/boot.h ++++ b/arch/x86/boot/boot.h @@ -82,7 +82,7 @@ static inline void io_delay(void) static inline u16 ds(void) { @@ -6299,7 +7039,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/boot.h lin= ux-2.6.32.49/arch/x86/boot/bo return seg; } =20 -@@ -178,7 +178,7 @@ static inline void wrgs32(u32 v, addr_t=20 +@@ -178,7 +178,7 @@ static inline void wrgs32(u32 v, addr_t addr) static inline int memcmp(const void *s1, const void *s2, size_t len) { u8 diff; @@ -6308,9 +7048,24 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/boot.h li= nux-2.6.32.49/arch/x86/boot/bo : "=3Dqm" (diff), "+D" (s1), "+S" (s2), "+c" (len)); return diff; } -diff -urNp linux-2.6.32.49/arch/x86/boot/compressed/head_32.S linux-2.6.= 32.49/arch/x86/boot/compressed/head_32.S ---- linux-2.6.32.49/arch/x86/boot/compressed/head_32.S 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/boot/compressed/head_32.S 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compresse= d/Makefile +index f8ed065..5bf5ff3 100644 +--- a/arch/x86/boot/compressed/Makefile ++++ b/arch/x86/boot/compressed/Makefile +@@ -13,6 +13,9 @@ cflags-$(CONFIG_X86_64) :=3D -mcmodel=3Dsmall + KBUILD_CFLAGS +=3D $(cflags-y) + KBUILD_CFLAGS +=3D $(call cc-option,-ffreestanding) + KBUILD_CFLAGS +=3D $(call cc-option,-fno-stack-protector) ++ifdef CONSTIFY_PLUGIN ++KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify ++endif +=20 + KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ + GCOV_PROFILE :=3D n +diff --git a/arch/x86/boot/compressed/head_32.S b/arch/x86/boot/compress= ed/head_32.S +index f543b70..b60fba8 100644 +--- a/arch/x86/boot/compressed/head_32.S ++++ b/arch/x86/boot/compressed/head_32.S @@ -76,7 +76,7 @@ ENTRY(startup_32) notl %eax andl %eax, %ebx @@ -6339,9 +7094,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compresse= d/head_32.S linux-2.6.32.49/ar addl %ebx, -__PAGE_OFFSET(%ebx, %ecx) jmp 1b 2: -diff -urNp linux-2.6.32.49/arch/x86/boot/compressed/head_64.S linux-2.6.= 32.49/arch/x86/boot/compressed/head_64.S ---- linux-2.6.32.49/arch/x86/boot/compressed/head_64.S 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/boot/compressed/head_64.S 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/x86/boot/compressed/head_64.S b/arch/x86/boot/compress= ed/head_64.S +index 077e1b6..2c6b13b 100644 +--- a/arch/x86/boot/compressed/head_64.S ++++ b/arch/x86/boot/compressed/head_64.S @@ -91,7 +91,7 @@ ENTRY(startup_32) notl %eax andl %eax, %ebx @@ -6369,22 +7125,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compress= ed/head_64.S linux-2.6.32.49/ar #endif =20 /* Target address to relocate to for decompression */ -diff -urNp linux-2.6.32.49/arch/x86/boot/compressed/Makefile linux-2.6.3= 2.49/arch/x86/boot/compressed/Makefile ---- linux-2.6.32.49/arch/x86/boot/compressed/Makefile 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/boot/compressed/Makefile 2011-11-15 19:59:4= 2.000000000 -0500 -@@ -13,6 +13,9 @@ cflags-$(CONFIG_X86_64) :=3D -mcmodel=3Dsmal - KBUILD_CFLAGS +=3D $(cflags-y) - KBUILD_CFLAGS +=3D $(call cc-option,-ffreestanding) - KBUILD_CFLAGS +=3D $(call cc-option,-fno-stack-protector) -+ifdef CONSTIFY_PLUGIN -+KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify -+endif -=20 - KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ - GCOV_PROFILE :=3D n -diff -urNp linux-2.6.32.49/arch/x86/boot/compressed/misc.c linux-2.6.32.= 49/arch/x86/boot/compressed/misc.c ---- linux-2.6.32.49/arch/x86/boot/compressed/misc.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/boot/compressed/misc.c 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/= misc.c +index 842b2a3..f00178b 100644 +--- a/arch/x86/boot/compressed/misc.c ++++ b/arch/x86/boot/compressed/misc.c @@ -288,7 +288,7 @@ static void parse_elf(void *output) case PT_LOAD: #ifdef CONFIG_RELOCATABLE @@ -6394,7 +7138,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compressed= /misc.c linux-2.6.32.49/arch/ #else dest =3D (void *)(phdr->p_paddr); #endif -@@ -335,7 +335,7 @@ asmlinkage void decompress_kernel(void * +@@ -335,7 +335,7 @@ asmlinkage void decompress_kernel(void *rmode, mempt= r heap, error("Destination address too large"); #endif #ifndef CONFIG_RELOCATABLE @@ -6403,9 +7147,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compresse= d/misc.c linux-2.6.32.49/arch/ error("Wrong destination address"); #endif =20 -diff -urNp linux-2.6.32.49/arch/x86/boot/compressed/mkpiggy.c linux-2.6.= 32.49/arch/x86/boot/compressed/mkpiggy.c ---- linux-2.6.32.49/arch/x86/boot/compressed/mkpiggy.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/boot/compressed/mkpiggy.c 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/x86/boot/compressed/mkpiggy.c b/arch/x86/boot/compress= ed/mkpiggy.c +index bcbd36c..b1754af 100644 +--- a/arch/x86/boot/compressed/mkpiggy.c ++++ b/arch/x86/boot/compressed/mkpiggy.c @@ -74,7 +74,7 @@ int main(int argc, char *argv[]) =20 offs =3D (olen > ilen) ? olen - ilen : 0; @@ -6415,9 +7160,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compresse= d/mkpiggy.c linux-2.6.32.49/ar offs =3D (offs+4095) & ~4095; /* Round to a 4K boundary */ =20 printf(".section \".rodata.compressed\",\"a\",@progbits\n"); -diff -urNp linux-2.6.32.49/arch/x86/boot/compressed/relocs.c linux-2.6.3= 2.49/arch/x86/boot/compressed/relocs.c ---- linux-2.6.32.49/arch/x86/boot/compressed/relocs.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/boot/compressed/relocs.c 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/x86/boot/compressed/relocs.c b/arch/x86/boot/compresse= d/relocs.c +index bbeb0c3..f5167ab 100644 +--- a/arch/x86/boot/compressed/relocs.c ++++ b/arch/x86/boot/compressed/relocs.c @@ -10,8 +10,11 @@ #define USE_BSD #include @@ -6579,7 +7325,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compressed= /relocs.c linux-2.6.32.49/arc struct section *sec =3D &secs[i]; =20 if (sec->shdr.sh_type !=3D SHT_REL) { -@@ -504,6 +548,21 @@ static void walk_relocs(void (*visit)(El +@@ -504,6 +548,21 @@ static void walk_relocs(void (*visit)(Elf32_Rel *re= l, Elf32_Sym *sym)) if (sym->st_shndx =3D=3D SHN_ABS) { continue; } @@ -6601,7 +7347,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compressed= /relocs.c linux-2.6.32.49/arc if (r_type =3D=3D R_386_NONE || r_type =3D=3D R_386_PC32) { /* * NONE can be ignored and and PC relative -@@ -541,7 +600,7 @@ static int cmp_relocs(const void *va, co +@@ -541,7 +600,7 @@ static int cmp_relocs(const void *va, const void *vb= ) =20 static void emit_relocs(int as_text) { @@ -6618,9 +7364,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/compresse= d/relocs.c linux-2.6.32.49/arc read_shdrs(fp); read_strtabs(fp); read_symtabs(fp); -diff -urNp linux-2.6.32.49/arch/x86/boot/cpucheck.c linux-2.6.32.49/arch= /x86/boot/cpucheck.c ---- linux-2.6.32.49/arch/x86/boot/cpucheck.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/boot/cpucheck.c 2011-11-15 19:59:42.0000000= 00 -0500 +diff --git a/arch/x86/boot/cpucheck.c b/arch/x86/boot/cpucheck.c +index 4d3ff03..e4972ff 100644 +--- a/arch/x86/boot/cpucheck.c ++++ b/arch/x86/boot/cpucheck.c @@ -74,7 +74,7 @@ static int has_fpu(void) u16 fcw =3D -1, fsw =3D -1; u32 cr0; @@ -6675,7 +7422,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/cpucheck.c= linux-2.6.32.49/arch/x86/boo : "+a" (eax), "=3Dc" (cpu.flags[6]), "=3Dd" (cpu.flags[1]) -@@ -203,9 +203,9 @@ int check_cpu(int *cpu_level_ptr, int *r +@@ -203,9 +203,9 @@ int check_cpu(int *cpu_level_ptr, int *req_level_ptr= , u32 **err_flags_ptr) u32 ecx =3D MSR_K7_HWCR; u32 eax, edx; =20 @@ -6687,7 +7434,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/cpucheck.c= linux-2.6.32.49/arch/x86/boo =20 get_flags(); /* Make sure it really did something */ err =3D check_flags(); -@@ -218,9 +218,9 @@ int check_cpu(int *cpu_level_ptr, int *r +@@ -218,9 +218,9 @@ int check_cpu(int *cpu_level_ptr, int *req_level_ptr= , u32 **err_flags_ptr) u32 ecx =3D MSR_VIA_FCR; u32 eax, edx; =20 @@ -6699,7 +7446,7 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/cpucheck.c= linux-2.6.32.49/arch/x86/boo =20 set_bit(X86_FEATURE_CX8, cpu.flags); err =3D check_flags(); -@@ -231,12 +231,12 @@ int check_cpu(int *cpu_level_ptr, int *r +@@ -231,12 +231,12 @@ int check_cpu(int *cpu_level_ptr, int *req_level_p= tr, u32 **err_flags_ptr) u32 eax, edx; u32 level =3D 1; =20 @@ -6716,10 +7463,11 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/cpucheck= .c linux-2.6.32.49/arch/x86/boo =20 err =3D check_flags(); } -diff -urNp linux-2.6.32.49/arch/x86/boot/header.S linux-2.6.32.49/arch/x= 86/boot/header.S ---- linux-2.6.32.49/arch/x86/boot/header.S 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/boot/header.S 2011-11-15 19:59:42.000000000= -0500 -@@ -224,7 +224,7 @@ setup_data: .quad 0 # 64-bit physical +diff --git a/arch/x86/boot/header.S b/arch/x86/boot/header.S +index b31cc54..8d69237 100644 +--- a/arch/x86/boot/header.S ++++ b/arch/x86/boot/header.S +@@ -224,7 +224,7 @@ setup_data: .quad 0 # 64-bit physical pointer to # single linked list of # struct setup_data =20 @@ -6728,22 +7476,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/header.S= linux-2.6.32.49/arch/x86/boot/ =20 #define ZO_INIT_SIZE (ZO__end - ZO_startup_32 + ZO_z_extract_offset) #define VO_INIT_SIZE (VO__end - VO__text) -diff -urNp linux-2.6.32.49/arch/x86/boot/Makefile linux-2.6.32.49/arch/x= 86/boot/Makefile ---- linux-2.6.32.49/arch/x86/boot/Makefile 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/boot/Makefile 2011-11-15 19:59:42.000000000= -0500 -@@ -69,6 +69,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os=20 - $(call cc-option, -fno-stack-protector) \ - $(call cc-option, -mpreferred-stack-boundary=3D2) - KBUILD_CFLAGS +=3D $(call cc-option, -m32) -+ifdef CONSTIFY_PLUGIN -+KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify -+endif - KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ - GCOV_PROFILE :=3D n -=20 -diff -urNp linux-2.6.32.49/arch/x86/boot/memory.c linux-2.6.32.49/arch/x= 86/boot/memory.c ---- linux-2.6.32.49/arch/x86/boot/memory.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/boot/memory.c 2011-11-15 19:59:42.000000000= -0500 +diff --git a/arch/x86/boot/memory.c b/arch/x86/boot/memory.c +index cae3feb..ff8ff2a 100644 +--- a/arch/x86/boot/memory.c ++++ b/arch/x86/boot/memory.c @@ -19,7 +19,7 @@ =20 static int detect_memory_e820(void) @@ -6753,9 +7489,22 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/memory.c = linux-2.6.32.49/arch/x86/boot/ struct biosregs ireg, oreg; struct e820entry *desc =3D boot_params.e820_map; static struct e820entry buf; /* static so it is zeroed */ -diff -urNp linux-2.6.32.49/arch/x86/boot/video.c linux-2.6.32.49/arch/x8= 6/boot/video.c ---- linux-2.6.32.49/arch/x86/boot/video.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/boot/video.c 2011-11-15 19:59:42.000000000 = -0500 +diff --git a/arch/x86/boot/video-vesa.c b/arch/x86/boot/video-vesa.c +index 11e8c6e..fdbb1ed 100644 +--- a/arch/x86/boot/video-vesa.c ++++ b/arch/x86/boot/video-vesa.c +@@ -200,6 +200,7 @@ static void vesa_store_pm_info(void) +=20 + boot_params.screen_info.vesapm_seg =3D oreg.es; + boot_params.screen_info.vesapm_off =3D oreg.di; ++ boot_params.screen_info.vesapm_size =3D oreg.cx; + } +=20 + /* +diff --git a/arch/x86/boot/video.c b/arch/x86/boot/video.c +index d42da38..787cdf3 100644 +--- a/arch/x86/boot/video.c ++++ b/arch/x86/boot/video.c @@ -90,7 +90,7 @@ static void store_mode_params(void) static unsigned int get_entry(void) { @@ -6765,20 +7514,10 @@ diff -urNp linux-2.6.32.49/arch/x86/boot/video.c = linux-2.6.32.49/arch/x86/boot/v int key; unsigned int v; =20 -diff -urNp linux-2.6.32.49/arch/x86/boot/video-vesa.c linux-2.6.32.49/ar= ch/x86/boot/video-vesa.c ---- linux-2.6.32.49/arch/x86/boot/video-vesa.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/boot/video-vesa.c 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -200,6 +200,7 @@ static void vesa_store_pm_info(void) -=20 - boot_params.screen_info.vesapm_seg =3D oreg.es; - boot_params.screen_info.vesapm_off =3D oreg.di; -+ boot_params.screen_info.vesapm_size =3D oreg.cx; - } -=20 - /* -diff -urNp linux-2.6.32.49/arch/x86/crypto/aes-x86_64-asm_64.S linux-2.6= .32.49/arch/x86/crypto/aes-x86_64-asm_64.S ---- linux-2.6.32.49/arch/x86/crypto/aes-x86_64-asm_64.S 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/crypto/aes-x86_64-asm_64.S 2011-11-15 19:59= :42.000000000 -0500 +diff --git a/arch/x86/crypto/aes-x86_64-asm_64.S b/arch/x86/crypto/aes-x= 86_64-asm_64.S +index 5b577d5..3c1fed4 100644 +--- a/arch/x86/crypto/aes-x86_64-asm_64.S ++++ b/arch/x86/crypto/aes-x86_64-asm_64.S @@ -8,6 +8,8 @@ * including this sentence is retained in full. */ @@ -6792,14 +7531,158 @@ diff -urNp linux-2.6.32.49/arch/x86/crypto/aes-x= 86_64-asm_64.S linux-2.6.32.49/a je B192; \ leaq 32(r9),r9; =20 -+#define ret pax_force_retaddr; ret ++#define ret pax_force_retaddr 0, 1; ret + #define epilogue(r1,r2,r3,r4,r5,r6,r7,r8,r9) \ movq r1,r2; \ movq r3,r4; \ -diff -urNp linux-2.6.32.49/arch/x86/crypto/salsa20-x86_64-asm_64.S linux= -2.6.32.49/arch/x86/crypto/salsa20-x86_64-asm_64.S ---- linux-2.6.32.49/arch/x86/crypto/salsa20-x86_64-asm_64.S 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/crypto/salsa20-x86_64-asm_64.S 2011-11-15 1= 9:59:42.000000000 -0500 +diff --git a/arch/x86/crypto/aesni-intel_asm.S b/arch/x86/crypto/aesni-i= ntel_asm.S +index eb0566e..e3ebad8 100644 +--- a/arch/x86/crypto/aesni-intel_asm.S ++++ b/arch/x86/crypto/aesni-intel_asm.S +@@ -16,6 +16,7 @@ + */ +=20 + #include ++#include +=20 + .text +=20 +@@ -52,6 +53,7 @@ _key_expansion_256a: + pxor %xmm1, %xmm0 + movaps %xmm0, (%rcx) + add $0x10, %rcx ++ pax_force_retaddr_bts + ret +=20 + _key_expansion_192a: +@@ -75,6 +77,7 @@ _key_expansion_192a: + shufps $0b01001110, %xmm2, %xmm1 + movaps %xmm1, 16(%rcx) + add $0x20, %rcx ++ pax_force_retaddr_bts + ret +=20 + _key_expansion_192b: +@@ -93,6 +96,7 @@ _key_expansion_192b: +=20 + movaps %xmm0, (%rcx) + add $0x10, %rcx ++ pax_force_retaddr_bts + ret +=20 + _key_expansion_256b: +@@ -104,6 +108,7 @@ _key_expansion_256b: + pxor %xmm1, %xmm2 + movaps %xmm2, (%rcx) + add $0x10, %rcx ++ pax_force_retaddr_bts + ret +=20 + /* +@@ -239,7 +244,9 @@ ENTRY(aesni_set_key) + cmp %rcx, %rdi + jb .Ldec_key_loop + xor %rax, %rax ++ pax_force_retaddr 0, 1 + ret ++ENDPROC(aesni_set_key) +=20 + /* + * void aesni_enc(struct crypto_aes_ctx *ctx, u8 *dst, const u8 *src) +@@ -249,7 +256,9 @@ ENTRY(aesni_enc) + movups (INP), STATE # input + call _aesni_enc1 + movups STATE, (OUTP) # output ++ pax_force_retaddr 0, 1 + ret ++ENDPROC(aesni_enc) +=20 + /* + * _aesni_enc1: internal ABI +@@ -319,6 +328,7 @@ _aesni_enc1: + movaps 0x70(TKEYP), KEY + # aesenclast KEY, STATE # last round + .byte 0x66, 0x0f, 0x38, 0xdd, 0xc2 ++ pax_force_retaddr_bts + ret +=20 + /* +@@ -482,6 +492,7 @@ _aesni_enc4: + .byte 0x66, 0x0f, 0x38, 0xdd, 0xea + # aesenclast KEY, STATE4 + .byte 0x66, 0x0f, 0x38, 0xdd, 0xf2 ++ pax_force_retaddr_bts + ret +=20 + /* +@@ -493,7 +504,9 @@ ENTRY(aesni_dec) + movups (INP), STATE # input + call _aesni_dec1 + movups STATE, (OUTP) #output ++ pax_force_retaddr 0, 1 + ret ++ENDPROC(aesni_dec) +=20 + /* + * _aesni_dec1: internal ABI +@@ -563,6 +576,7 @@ _aesni_dec1: + movaps 0x70(TKEYP), KEY + # aesdeclast KEY, STATE # last round + .byte 0x66, 0x0f, 0x38, 0xdf, 0xc2 ++ pax_force_retaddr_bts + ret +=20 + /* +@@ -726,6 +740,7 @@ _aesni_dec4: + .byte 0x66, 0x0f, 0x38, 0xdf, 0xea + # aesdeclast KEY, STATE4 + .byte 0x66, 0x0f, 0x38, 0xdf, 0xf2 ++ pax_force_retaddr_bts + ret +=20 + /* +@@ -769,7 +784,9 @@ ENTRY(aesni_ecb_enc) + cmp $16, LEN + jge .Lecb_enc_loop1 + .Lecb_enc_ret: ++ pax_force_retaddr 0, 1 + ret ++ENDPROC(aesni_ecb_enc) +=20 + /* + * void aesni_ecb_dec(struct crypto_aes_ctx *ctx, const u8 *dst, u8 *sr= c, +@@ -813,7 +830,9 @@ ENTRY(aesni_ecb_dec) + cmp $16, LEN + jge .Lecb_dec_loop1 + .Lecb_dec_ret: ++ pax_force_retaddr 0, 1 + ret ++ENDPROC(aesni_ecb_dec) +=20 + /* + * void aesni_cbc_enc(struct crypto_aes_ctx *ctx, const u8 *dst, u8 *sr= c, +@@ -837,7 +856,9 @@ ENTRY(aesni_cbc_enc) + jge .Lcbc_enc_loop + movups STATE, (IVP) + .Lcbc_enc_ret: ++ pax_force_retaddr 0, 1 + ret ++ENDPROC(aesni_cbc_enc) +=20 + /* + * void aesni_cbc_dec(struct crypto_aes_ctx *ctx, const u8 *dst, u8 *sr= c, +@@ -894,4 +915,6 @@ ENTRY(aesni_cbc_dec) + .Lcbc_dec_ret: + movups IV, (IVP) + .Lcbc_dec_just_ret: ++ pax_force_retaddr 0, 1 + ret ++ENDPROC(aesni_cbc_dec) +diff --git a/arch/x86/crypto/salsa20-x86_64-asm_64.S b/arch/x86/crypto/s= alsa20-x86_64-asm_64.S +index 6214a9b..1f4fc9a 100644 +--- a/arch/x86/crypto/salsa20-x86_64-asm_64.S ++++ b/arch/x86/crypto/salsa20-x86_64-asm_64.S @@ -1,3 +1,5 @@ +#include + @@ -6810,7 +7693,7 @@ diff -urNp linux-2.6.32.49/arch/x86/crypto/salsa20-= x86_64-asm_64.S linux-2.6.32. add %r11,%rsp mov %rdi,%rax mov %rsi,%rdx -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret # bytesatleast65: ._bytesatleast65: @@ -6828,9 +7711,10 @@ diff -urNp linux-2.6.32.49/arch/x86/crypto/salsa20= -x86_64-asm_64.S linux-2.6.32. mov %rsi,%rdx + pax_force_retaddr ret -diff -urNp linux-2.6.32.49/arch/x86/crypto/twofish-x86_64-asm_64.S linux= -2.6.32.49/arch/x86/crypto/twofish-x86_64-asm_64.S ---- linux-2.6.32.49/arch/x86/crypto/twofish-x86_64-asm_64.S 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/crypto/twofish-x86_64-asm_64.S 2011-11-15 1= 9:59:42.000000000 -0500 +diff --git a/arch/x86/crypto/twofish-x86_64-asm_64.S b/arch/x86/crypto/t= wofish-x86_64-asm_64.S +index 35974a5..5662ae2 100644 +--- a/arch/x86/crypto/twofish-x86_64-asm_64.S ++++ b/arch/x86/crypto/twofish-x86_64-asm_64.S @@ -21,6 +21,7 @@ .text =20 @@ -6843,7 +7727,7 @@ diff -urNp linux-2.6.32.49/arch/x86/crypto/twofish-= x86_64-asm_64.S linux-2.6.32. =20 popq R1 movq $1,%rax -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret =20 twofish_dec_blk: @@ -6851,12 +7735,13 @@ diff -urNp linux-2.6.32.49/arch/x86/crypto/twofis= h-x86_64-asm_64.S linux-2.6.32. =20 popq R1 movq $1,%rax -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret -diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32_aout.c linux-2.6.32.49/arc= h/x86/ia32/ia32_aout.c ---- linux-2.6.32.49/arch/x86/ia32/ia32_aout.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/ia32/ia32_aout.c 2011-11-15 19:59:42.000000= 000 -0500 -@@ -169,6 +169,8 @@ static int aout_core_dump(long signr, st +diff --git a/arch/x86/ia32/ia32_aout.c b/arch/x86/ia32/ia32_aout.c +index 14531ab..a89a0c0 100644 +--- a/arch/x86/ia32/ia32_aout.c ++++ b/arch/x86/ia32/ia32_aout.c +@@ -169,6 +169,8 @@ static int aout_core_dump(long signr, struct pt_regs= *regs, struct file *file, unsigned long dump_start, dump_size; struct user32 dump; =20 @@ -6865,7 +7750,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32_aout.= c linux-2.6.32.49/arch/x86/ia fs =3D get_fs(); set_fs(KERNEL_DS); has_dumped =3D 1; -@@ -218,12 +220,6 @@ static int aout_core_dump(long signr, st +@@ -218,12 +220,6 @@ static int aout_core_dump(long signr, struct pt_reg= s *regs, struct file *file, dump_size =3D dump.u_ssize << PAGE_SHIFT; DUMP_WRITE(dump_start, dump_size); } @@ -6878,9 +7763,90 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32_aout= .c linux-2.6.32.49/arch/x86/ia end_coredump: set_fs(fs); return has_dumped; -diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entry.S linux-2.6.32.49/arc= h/x86/ia32/ia32entry.S ---- linux-2.6.32.49/arch/x86/ia32/ia32entry.S 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/ia32/ia32entry.S 2011-11-18 18:01:52.000000= 000 -0500 +diff --git a/arch/x86/ia32/ia32_signal.c b/arch/x86/ia32/ia32_signal.c +index 588a7aa..a3468b0 100644 +--- a/arch/x86/ia32/ia32_signal.c ++++ b/arch/x86/ia32/ia32_signal.c +@@ -167,7 +167,7 @@ asmlinkage long sys32_sigaltstack(const stack_ia32_t= __user *uss_ptr, + } + seg =3D get_fs(); + set_fs(KERNEL_DS); +- ret =3D do_sigaltstack(uss_ptr ? &uss : NULL, &uoss, regs->sp); ++ ret =3D do_sigaltstack(uss_ptr ? (const stack_t __force_user *)&uss : = NULL, (stack_t __force_user *)&uoss, regs->sp); + set_fs(seg); + if (ret >=3D 0 && uoss_ptr) { + if (!access_ok(VERIFY_WRITE, uoss_ptr, sizeof(stack_ia32_t))) +@@ -374,7 +374,7 @@ static int ia32_setup_sigcontext(struct sigcontext_i= a32 __user *sc, + */ + static void __user *get_sigframe(struct k_sigaction *ka, struct pt_regs= *regs, + size_t frame_size, +- void **fpstate) ++ void __user **fpstate) + { + unsigned long sp; +=20 +@@ -395,7 +395,7 @@ static void __user *get_sigframe(struct k_sigaction = *ka, struct pt_regs *regs, +=20 + if (used_math()) { + sp =3D sp - sig_xstate_ia32_size; +- *fpstate =3D (struct _fpstate_ia32 *) sp; ++ *fpstate =3D (struct _fpstate_ia32 __user *) sp; + if (save_i387_xstate_ia32(*fpstate) < 0) + return (void __user *) -1L; + } +@@ -403,7 +403,7 @@ static void __user *get_sigframe(struct k_sigaction = *ka, struct pt_regs *regs, + sp -=3D frame_size; + /* Align the stack pointer according to the i386 ABI, + * i.e. so that on function entry ((sp + 4) & 15) =3D=3D 0. */ +- sp =3D ((sp + 4) & -16ul) - 4; ++ sp =3D ((sp - 12) & -16ul) - 4; + return (void __user *) sp; + } +=20 +@@ -461,7 +461,7 @@ int ia32_setup_frame(int sig, struct k_sigaction *ka= , + * These are actually not used anymore, but left because some + * gdb versions depend on them as a marker. + */ +- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); ++ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); + } put_user_catch(err); +=20 + if (err) +@@ -503,7 +503,7 @@ int ia32_setup_rt_frame(int sig, struct k_sigaction = *ka, siginfo_t *info, + 0xb8, + __NR_ia32_rt_sigreturn, + 0x80cd, +- 0, ++ 0 + }; +=20 + frame =3D get_sigframe(ka, regs, sizeof(*frame), &fpstate); +@@ -533,16 +533,18 @@ int ia32_setup_rt_frame(int sig, struct k_sigactio= n *ka, siginfo_t *info, +=20 + if (ka->sa.sa_flags & SA_RESTORER) + restorer =3D ka->sa.sa_restorer; ++ else if (current->mm->context.vdso) ++ /* Return stub is in 32bit vsyscall page */ ++ restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, rt_sigreturn); + else +- restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, +- rt_sigreturn); ++ restorer =3D &frame->retcode; + put_user_ex(ptr_to_compat(restorer), &frame->pretcode); +=20 + /* + * Not actually used anymore, but left because some gdb + * versions need it. + */ +- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); ++ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); + } put_user_catch(err); +=20 + if (err) +diff --git a/arch/x86/ia32/ia32entry.S b/arch/x86/ia32/ia32entry.S +index 4edd8eb..07ac7fd 100644 +--- a/arch/x86/ia32/ia32entry.S ++++ b/arch/x86/ia32/ia32entry.S @@ -13,7 +13,9 @@ #include =09 #include @@ -6891,11 +7857,12 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entr= y.S linux-2.6.32.49/arch/x86/ia =20 /* Avoid __ASSEMBLER__'ifying just for this. */ #include -@@ -93,6 +95,29 @@ ENTRY(native_irq_enable_sysexit) +@@ -93,6 +95,30 @@ ENTRY(native_irq_enable_sysexit) ENDPROC(native_irq_enable_sysexit) #endif =20 + .macro pax_enter_kernel_user ++ pax_set_fptr_mask +#ifdef CONFIG_PAX_MEMORY_UDEREF + call pax_enter_kernel_user +#endif @@ -6921,48 +7888,87 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entr= y.S linux-2.6.32.49/arch/x86/ia /* * 32bit SYSENTER instruction entry. * -@@ -119,7 +144,7 @@ ENTRY(ia32_sysenter_target) +@@ -119,12 +145,6 @@ ENTRY(ia32_sysenter_target) CFI_REGISTER rsp,rbp SWAPGS_UNSAFE_STACK movq PER_CPU_VAR(kernel_stack), %rsp - addq $(KERNEL_STACK_OFFSET),%rsp -+ pax_enter_kernel_user - /* - * No need to follow this irqs on/off section: the syscall - * disabled irqs, here we enable it straight after entry: -@@ -135,7 +160,8 @@ ENTRY(ia32_sysenter_target) +- /* +- * No need to follow this irqs on/off section: the syscall +- * disabled irqs, here we enable it straight after entry: +- */ +- ENABLE_INTERRUPTS(CLBR_NONE) + movl %ebp,%ebp /* zero extension */ + pushq $__USER32_DS + CFI_ADJUST_CFA_OFFSET 8 +@@ -135,28 +155,41 @@ ENTRY(ia32_sysenter_target) pushfq CFI_ADJUST_CFA_OFFSET 8 /*CFI_REL_OFFSET rflags,0*/ - movl 8*3-THREAD_SIZE+TI_sysenter_return(%rsp), %r10d -+ GET_THREAD_INFO(%r10) -+ movl TI_sysenter_return(%r10), %r10d - CFI_REGISTER rip,r10 +- CFI_REGISTER rip,r10 ++ GET_THREAD_INFO(%r11) ++ movl TI_sysenter_return(%r11), %r11d ++ CFI_REGISTER rip,r11 pushq $__USER32_CS CFI_ADJUST_CFA_OFFSET 8 -@@ -150,6 +176,12 @@ ENTRY(ia32_sysenter_target) + /*CFI_REL_OFFSET cs,0*/ + movl %eax, %eax +- pushq %r10 ++ pushq %r11 + CFI_ADJUST_CFA_OFFSET 8 + CFI_REL_OFFSET rip,0 + pushq %rax + CFI_ADJUST_CFA_OFFSET 8 + cld SAVE_ARGS 0,0,1 ++ pax_enter_kernel_user ++ /* ++ * No need to follow this irqs on/off section: the syscall ++ * disabled irqs, here we enable it straight after entry: ++ */ ++ ENABLE_INTERRUPTS(CLBR_NONE) /* no need to do an access_ok check here because rbp has been 32bit zero extended */=20 + +#ifdef CONFIG_PAX_MEMORY_UDEREF -+ mov $PAX_USER_SHADOW_BASE,%r10 -+ add %r10,%rbp ++ mov $PAX_USER_SHADOW_BASE,%r11 ++ add %r11,%rbp +#endif + 1: movl (%rbp),%ebp .section __ex_table,"a" .quad 1b,ia32_badarg -@@ -172,6 +204,8 @@ sysenter_dispatch: - testl $_TIF_ALLWORK_MASK,TI_flags(%r10) + .previous=09 +- GET_THREAD_INFO(%r10) +- orl $TS_COMPAT,TI_status(%r10) +- testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r10) ++ GET_THREAD_INFO(%r11) ++ orl $TS_COMPAT,TI_status(%r11) ++ testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r11) + CFI_REMEMBER_STATE + jnz sysenter_tracesys + cmpq $(IA32_NR_syscalls-1),%rax +@@ -166,13 +199,15 @@ sysenter_do_call: + sysenter_dispatch: + call *ia32_sys_call_table(,%rax,8) + movq %rax,RAX-ARGOFFSET(%rsp) +- GET_THREAD_INFO(%r10) ++ GET_THREAD_INFO(%r11) + DISABLE_INTERRUPTS(CLBR_NONE) + TRACE_IRQS_OFF +- testl $_TIF_ALLWORK_MASK,TI_flags(%r10) ++ testl $_TIF_ALLWORK_MASK,TI_flags(%r11) jnz sysexit_audit sysexit_from_sys_call: +- andl $~TS_COMPAT,TI_status(%r10) + pax_exit_kernel_user + pax_erase_kstack - andl $~TS_COMPAT,TI_status(%r10) ++ andl $~TS_COMPAT,TI_status(%r11) /* clear IF, that popfq doesn't enable interrupts early */ andl $~0x200,EFLAGS-R11(%rsp)=20 -@@ -200,6 +234,9 @@ sysexit_from_sys_call: + movl RIP-R11(%rsp),%edx /* User %eip */ +@@ -200,6 +235,9 @@ sysexit_from_sys_call: movl %eax,%esi /* 2nd arg: syscall number */ movl $AUDIT_ARCH_I386,%edi /* 1st arg: audit arch */ call audit_syscall_entry @@ -6972,7 +7978,40 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entry= .S linux-2.6.32.49/arch/x86/ia movl RAX-ARGOFFSET(%rsp),%eax /* reload syscall number */ cmpq $(IA32_NR_syscalls-1),%rax ja ia32_badsys -@@ -252,6 +289,9 @@ sysenter_tracesys: +@@ -211,7 +249,7 @@ sysexit_from_sys_call: + .endm +=20 + .macro auditsys_exit exit +- testl $(_TIF_ALLWORK_MASK & ~_TIF_SYSCALL_AUDIT),TI_flags(%r10) ++ testl $(_TIF_ALLWORK_MASK & ~_TIF_SYSCALL_AUDIT),TI_flags(%r11) + jnz ia32_ret_from_sys_call + TRACE_IRQS_ON + sti +@@ -221,12 +259,12 @@ sysexit_from_sys_call: + movzbl %al,%edi /* zero-extend that into %edi */ + inc %edi /* first arg, 0->1(AUDITSC_SUCCESS), 1->2(AUDITSC_FAILURE) */ + call audit_syscall_exit +- GET_THREAD_INFO(%r10) ++ GET_THREAD_INFO(%r11) + movl RAX-ARGOFFSET(%rsp),%eax /* reload syscall return value */ + movl $(_TIF_ALLWORK_MASK & ~_TIF_SYSCALL_AUDIT),%edi + cli + TRACE_IRQS_OFF +- testl %edi,TI_flags(%r10) ++ testl %edi,TI_flags(%r11) + jz \exit + CLEAR_RREGS -ARGOFFSET + jmp int_with_check +@@ -244,7 +282,7 @@ sysexit_audit: +=20 + sysenter_tracesys: + #ifdef CONFIG_AUDITSYSCALL +- testl $(_TIF_WORK_SYSCALL_ENTRY & ~_TIF_SYSCALL_AUDIT),TI_flags(%r10) ++ testl $(_TIF_WORK_SYSCALL_ENTRY & ~_TIF_SYSCALL_AUDIT),TI_flags(%r11) + jz sysenter_auditsys + #endif + SAVE_REST +@@ -252,6 +290,9 @@ sysenter_tracesys: movq $-ENOSYS,RAX(%rsp)/* ptrace can change this for a bad syscall */ movq %rsp,%rdi /* &pt_regs -> arg1 */ call syscall_trace_enter @@ -6982,7 +8021,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entry.= S linux-2.6.32.49/arch/x86/ia LOAD_ARGS32 ARGOFFSET /* reload args from stack in case ptrace change= d it */ RESTORE_REST cmpq $(IA32_NR_syscalls-1),%rax -@@ -283,19 +323,24 @@ ENDPROC(ia32_sysenter_target) +@@ -283,19 +324,20 @@ ENDPROC(ia32_sysenter_target) ENTRY(ia32_cstar_target) CFI_STARTPROC32 simple CFI_SIGNAL_FRAME @@ -6994,44 +8033,69 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entr= y.S linux-2.6.32.49/arch/x86/ia movl %esp,%r8d CFI_REGISTER rsp,r8 movq PER_CPU_VAR(kernel_stack),%rsp -+ -+#ifdef CONFIG_PAX_MEMORY_UDEREF ++ SAVE_ARGS 8*6,1,1 + pax_enter_kernel_user -+#endif -+ /* * No need to follow this irqs on/off section: the syscall * disabled irqs and here we enable it straight after entry: */ ENABLE_INTERRUPTS(CLBR_NONE) - SAVE_ARGS 8,1,1 -+ SAVE_ARGS 8*6,1,1 movl %eax,%eax /* zero extension */ movq %rax,ORIG_RAX-ARGOFFSET(%rsp) movq %rcx,RIP-ARGOFFSET(%rsp) -@@ -311,6 +356,12 @@ ENTRY(ia32_cstar_target) +@@ -311,13 +353,19 @@ ENTRY(ia32_cstar_target) /* no need to do an access_ok check here because r8 has been 32bit zero extended */=20 /* hardware stack frame is complete now */=09 + +#ifdef CONFIG_PAX_MEMORY_UDEREF -+ mov $PAX_USER_SHADOW_BASE,%r10 -+ add %r10,%r8 ++ mov $PAX_USER_SHADOW_BASE,%r11 ++ add %r11,%r8 +#endif + 1: movl (%r8),%r9d .section __ex_table,"a" .quad 1b,ia32_badarg -@@ -333,6 +384,8 @@ cstar_dispatch: - testl $_TIF_ALLWORK_MASK,TI_flags(%r10) + .previous=09 +- GET_THREAD_INFO(%r10) +- orl $TS_COMPAT,TI_status(%r10) +- testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r10) ++ GET_THREAD_INFO(%r11) ++ orl $TS_COMPAT,TI_status(%r11) ++ testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r11) + CFI_REMEMBER_STATE + jnz cstar_tracesys + cmpq $IA32_NR_syscalls-1,%rax +@@ -327,13 +375,15 @@ cstar_do_call: + cstar_dispatch: + call *ia32_sys_call_table(,%rax,8) + movq %rax,RAX-ARGOFFSET(%rsp) +- GET_THREAD_INFO(%r10) ++ GET_THREAD_INFO(%r11) + DISABLE_INTERRUPTS(CLBR_NONE) + TRACE_IRQS_OFF +- testl $_TIF_ALLWORK_MASK,TI_flags(%r10) ++ testl $_TIF_ALLWORK_MASK,TI_flags(%r11) jnz sysretl_audit sysretl_from_sys_call: +- andl $~TS_COMPAT,TI_status(%r10) + pax_exit_kernel_user + pax_erase_kstack - andl $~TS_COMPAT,TI_status(%r10) ++ andl $~TS_COMPAT,TI_status(%r11) RESTORE_ARGS 1,-ARG_SKIP,1,1,1 movl RIP-ARGOFFSET(%rsp),%ecx -@@ -370,6 +423,9 @@ cstar_tracesys: + CFI_REGISTER rip,rcx +@@ -361,7 +411,7 @@ sysretl_audit: +=20 + cstar_tracesys: + #ifdef CONFIG_AUDITSYSCALL +- testl $(_TIF_WORK_SYSCALL_ENTRY & ~_TIF_SYSCALL_AUDIT),TI_flags(%r10) ++ testl $(_TIF_WORK_SYSCALL_ENTRY & ~_TIF_SYSCALL_AUDIT),TI_flags(%r11) + jz cstar_auditsys + #endif + xchgl %r9d,%ebp +@@ -370,6 +420,9 @@ cstar_tracesys: movq $-ENOSYS,RAX(%rsp) /* ptrace can change this for a bad syscall */ movq %rsp,%rdi /* &pt_regs -> arg1 */ call syscall_trace_enter @@ -7041,15 +8105,38 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entr= y.S linux-2.6.32.49/arch/x86/ia LOAD_ARGS32 ARGOFFSET, 1 /* reload args from stack in case ptrace cha= nged it */ RESTORE_REST xchgl %ebp,%r9d -@@ -415,6 +471,7 @@ ENTRY(ia32_syscall) +@@ -415,11 +468,6 @@ ENTRY(ia32_syscall) CFI_REL_OFFSET rip,RIP-RIP PARAVIRT_ADJUST_EXCEPTION_FRAME SWAPGS +- /* +- * No need to follow this irqs on/off section: the syscall +- * disabled irqs and here we enable it straight after entry: +- */ +- ENABLE_INTERRUPTS(CLBR_NONE) + movl %eax,%eax + pushq %rax + CFI_ADJUST_CFA_OFFSET 8 +@@ -427,9 +475,15 @@ ENTRY(ia32_syscall) + /* note the registers are not zero extended to the sf. + this could be a problem. */ + SAVE_ARGS 0,0,1 +- GET_THREAD_INFO(%r10) +- orl $TS_COMPAT,TI_status(%r10) +- testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r10) + pax_enter_kernel_user - /* - * No need to follow this irqs on/off section: the syscall - * disabled irqs and here we enable it straight after entry: -@@ -448,6 +505,9 @@ ia32_tracesys: =20 ++ /* ++ * No need to follow this irqs on/off section: the syscall ++ * disabled irqs and here we enable it straight after entry: ++ */ ++ ENABLE_INTERRUPTS(CLBR_NONE) ++ GET_THREAD_INFO(%r11) ++ orl $TS_COMPAT,TI_status(%r11) ++ testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%r11) + jnz ia32_tracesys + cmpq $(IA32_NR_syscalls-1),%rax + ja ia32_badsys +@@ -448,6 +502,9 @@ ia32_tracesys: movq $-ENOSYS,RAX(%rsp) /* ptrace can change this for a bad syscall */ movq %rsp,%rdi /* &pt_regs -> arg1 */ call syscall_trace_enter @@ -7059,7 +8146,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entry.= S linux-2.6.32.49/arch/x86/ia LOAD_ARGS32 ARGOFFSET /* reload args from stack in case ptrace change= d it */ RESTORE_REST cmpq $(IA32_NR_syscalls-1),%rax -@@ -462,6 +522,7 @@ ia32_badsys: +@@ -462,6 +519,7 @@ ia32_badsys: =20 quiet_ni_syscall: movq $-ENOSYS,%rax @@ -7067,89 +8154,11 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32entr= y.S linux-2.6.32.49/arch/x86/ia ret CFI_ENDPROC =09 -diff -urNp linux-2.6.32.49/arch/x86/ia32/ia32_signal.c linux-2.6.32.49/a= rch/x86/ia32/ia32_signal.c ---- linux-2.6.32.49/arch/x86/ia32/ia32_signal.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/ia32/ia32_signal.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -167,7 +167,7 @@ asmlinkage long sys32_sigaltstack(const=20 - } - seg =3D get_fs(); - set_fs(KERNEL_DS); -- ret =3D do_sigaltstack(uss_ptr ? &uss : NULL, &uoss, regs->sp); -+ ret =3D do_sigaltstack(uss_ptr ? (const stack_t __force_user *)&uss : = NULL, (stack_t __force_user *)&uoss, regs->sp); - set_fs(seg); - if (ret >=3D 0 && uoss_ptr) { - if (!access_ok(VERIFY_WRITE, uoss_ptr, sizeof(stack_ia32_t))) -@@ -374,7 +374,7 @@ static int ia32_setup_sigcontext(struct=20 - */ - static void __user *get_sigframe(struct k_sigaction *ka, struct pt_regs= *regs, - size_t frame_size, -- void **fpstate) -+ void __user **fpstate) - { - unsigned long sp; -=20 -@@ -395,7 +395,7 @@ static void __user *get_sigframe(struct=20 -=20 - if (used_math()) { - sp =3D sp - sig_xstate_ia32_size; -- *fpstate =3D (struct _fpstate_ia32 *) sp; -+ *fpstate =3D (struct _fpstate_ia32 __user *) sp; - if (save_i387_xstate_ia32(*fpstate) < 0) - return (void __user *) -1L; - } -@@ -403,7 +403,7 @@ static void __user *get_sigframe(struct=20 - sp -=3D frame_size; - /* Align the stack pointer according to the i386 ABI, - * i.e. so that on function entry ((sp + 4) & 15) =3D=3D 0. */ -- sp =3D ((sp + 4) & -16ul) - 4; -+ sp =3D ((sp - 12) & -16ul) - 4; - return (void __user *) sp; - } -=20 -@@ -461,7 +461,7 @@ int ia32_setup_frame(int sig, struct k_s - * These are actually not used anymore, but left because some - * gdb versions depend on them as a marker. - */ -- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); -+ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); - } put_user_catch(err); -=20 - if (err) -@@ -503,7 +503,7 @@ int ia32_setup_rt_frame(int sig, struct=20 - 0xb8, - __NR_ia32_rt_sigreturn, - 0x80cd, -- 0, -+ 0 - }; -=20 - frame =3D get_sigframe(ka, regs, sizeof(*frame), &fpstate); -@@ -533,16 +533,18 @@ int ia32_setup_rt_frame(int sig, struct=20 -=20 - if (ka->sa.sa_flags & SA_RESTORER) - restorer =3D ka->sa.sa_restorer; -+ else if (current->mm->context.vdso) -+ /* Return stub is in 32bit vsyscall page */ -+ restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, rt_sigreturn); - else -- restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, -- rt_sigreturn); -+ restorer =3D &frame->retcode; - put_user_ex(ptr_to_compat(restorer), &frame->pretcode); -=20 - /* - * Not actually used anymore, but left because some gdb - * versions need it. - */ -- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); -+ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); - } put_user_catch(err); -=20 - if (err) -diff -urNp linux-2.6.32.49/arch/x86/ia32/sys_ia32.c linux-2.6.32.49/arch= /x86/ia32/sys_ia32.c ---- linux-2.6.32.49/arch/x86/ia32/sys_ia32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/ia32/sys_ia32.c 2011-11-15 19:59:42.0000000= 00 -0500 -@@ -69,8 +69,8 @@ asmlinkage long sys32_ftruncate64(unsign +diff --git a/arch/x86/ia32/sys_ia32.c b/arch/x86/ia32/sys_ia32.c +index 016218c..47ccbdd 100644 +--- a/arch/x86/ia32/sys_ia32.c ++++ b/arch/x86/ia32/sys_ia32.c +@@ -69,8 +69,8 @@ asmlinkage long sys32_ftruncate64(unsigned int fd, uns= igned long offset_low, */ static int cp_stat64(struct stat64 __user *ubuf, struct kstat *stat) { @@ -7160,7 +8169,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/sys_ia32.c= linux-2.6.32.49/arch/x86/ia3 SET_UID(uid, stat->uid); SET_GID(gid, stat->gid); if (!access_ok(VERIFY_WRITE, ubuf, sizeof(struct stat64)) || -@@ -308,8 +308,8 @@ asmlinkage long sys32_rt_sigprocmask(int +@@ -308,8 +308,8 @@ asmlinkage long sys32_rt_sigprocmask(int how, compat= _sigset_t __user *set, } set_fs(KERNEL_DS); ret =3D sys_rt_sigprocmask(how, @@ -7171,7 +8180,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/sys_ia32.c= linux-2.6.32.49/arch/x86/ia3 sigsetsize); set_fs(old_fs); if (ret) -@@ -371,7 +371,7 @@ asmlinkage long sys32_sched_rr_get_inter +@@ -371,7 +371,7 @@ asmlinkage long sys32_sched_rr_get_interval(compat_p= id_t pid, mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -7180,7 +8189,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/sys_ia32.c= linux-2.6.32.49/arch/x86/ia3 set_fs(old_fs); if (put_compat_timespec(&t, interval)) return -EFAULT; -@@ -387,7 +387,7 @@ asmlinkage long sys32_rt_sigpending(comp +@@ -387,7 +387,7 @@ asmlinkage long sys32_rt_sigpending(compat_sigset_t = __user *set, mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -7189,7 +8198,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/sys_ia32.c= linux-2.6.32.49/arch/x86/ia3 set_fs(old_fs); if (!ret) { switch (_NSIG_WORDS) { -@@ -412,7 +412,7 @@ asmlinkage long sys32_rt_sigqueueinfo(in +@@ -412,7 +412,7 @@ asmlinkage long sys32_rt_sigqueueinfo(int pid, int s= ig, if (copy_siginfo_from_user32(&info, uinfo)) return -EFAULT; set_fs(KERNEL_DS); @@ -7198,7 +8207,7 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/sys_ia32.c= linux-2.6.32.49/arch/x86/ia3 set_fs(old_fs); return ret; } -@@ -513,7 +513,7 @@ asmlinkage long sys32_sendfile(int out_f +@@ -513,7 +513,7 @@ asmlinkage long sys32_sendfile(int out_fd, int in_fd= , return -EFAULT; =20 set_fs(KERNEL_DS); @@ -7207,32 +8216,59 @@ diff -urNp linux-2.6.32.49/arch/x86/ia32/sys_ia32= .c linux-2.6.32.49/arch/x86/ia3 count); set_fs(old_fs); =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/alternative-asm.h linux-= 2.6.32.49/arch/x86/include/asm/alternative-asm.h ---- linux-2.6.32.49/arch/x86/include/asm/alternative-asm.h 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/alternative-asm.h 2011-11-15 19= :59:42.000000000 -0500 -@@ -19,4 +19,18 @@ +diff --git a/arch/x86/include/asm/alternative-asm.h b/arch/x86/include/a= sm/alternative-asm.h +index e2077d3..e134a5e 100644 +--- a/arch/x86/include/asm/alternative-asm.h ++++ b/arch/x86/include/asm/alternative-asm.h +@@ -19,4 +19,43 @@ .endm #endif =20 +#ifdef CONFIG_PAX_KERNEXEC_PLUGIN -+ .macro pax_force_retaddr rip=3D0 ++ .macro pax_force_retaddr_bts rip=3D0 ++ btsq $63,\rip(%rsp) ++ .endm ++#ifdef CONFIG_PAX_KERNEXEC_PLUGIN_METHOD_BTS ++ .macro pax_force_retaddr rip=3D0, reload=3D0 + btsq $63,\rip(%rsp) + .endm + .macro pax_force_fptr ptr + btsq $63,\ptr + .endm ++ .macro pax_set_fptr_mask ++ .endm ++#endif ++#ifdef CONFIG_PAX_KERNEXEC_PLUGIN_METHOD_OR ++ .macro pax_force_retaddr rip=3D0, reload=3D0 ++ .if \reload ++ pax_set_fptr_mask ++ .endif ++ orq %r10,\rip(%rsp) ++ .endm ++ .macro pax_force_fptr ptr ++ orq %r10,\ptr ++ .endm ++ .macro pax_set_fptr_mask ++ movabs $0x8000000000000000,%r10 ++ .endm ++#endif +#else -+ .macro pax_force_retaddr rip=3D0 ++ .macro pax_force_retaddr rip=3D0, reload=3D0 + .endm + .macro pax_force_fptr ptr + .endm ++ .macro pax_force_retaddr_bts rip=3D0 ++ .endm ++ .macro pax_set_fptr_mask ++ .endm +#endif + #endif /* __ASSEMBLY__ */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/alternative.h linux-2.6.= 32.49/arch/x86/include/asm/alternative.h ---- linux-2.6.32.49/arch/x86/include/asm/alternative.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/alternative.h 2011-11-15 19:59:= 42.000000000 -0500 -@@ -85,7 +85,7 @@ static inline void alternatives_smp_swit +diff --git a/arch/x86/include/asm/alternative.h b/arch/x86/include/asm/a= lternative.h +index c240efc..fdfadf3 100644 +--- a/arch/x86/include/asm/alternative.h ++++ b/arch/x86/include/asm/alternative.h +@@ -85,7 +85,7 @@ static inline void alternatives_smp_switch(int smp) {} " .byte 662b-661b\n" /* sourcelen */ \ " .byte 664f-663f\n" /* replacementlen */ \ ".previous\n" \ @@ -7241,10 +8277,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/a= lternative.h linux-2.6.32.49/ar "663:\n\t" newinstr "\n664:\n" /* replacement */ \ ".previous" =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/apic.h linux-2.6.32.49/a= rch/x86/include/asm/apic.h ---- linux-2.6.32.49/arch/x86/include/asm/apic.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/apic.h 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -46,7 +46,7 @@ static inline void generic_apic_probe(vo +diff --git a/arch/x86/include/asm/apic.h b/arch/x86/include/asm/apic.h +index 474d80d..1f97d58 100644 +--- a/arch/x86/include/asm/apic.h ++++ b/arch/x86/include/asm/apic.h +@@ -46,7 +46,7 @@ static inline void generic_apic_probe(void) =20 #ifdef CONFIG_X86_LOCAL_APIC =20 @@ -7253,10 +8290,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/a= pic.h linux-2.6.32.49/arch/x86/ extern int local_apic_timer_c2_ok; =20 extern int disable_apic; -diff -urNp linux-2.6.32.49/arch/x86/include/asm/apm.h linux-2.6.32.49/ar= ch/x86/include/asm/apm.h ---- linux-2.6.32.49/arch/x86/include/asm/apm.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/apm.h 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -34,7 +34,7 @@ static inline void apm_bios_call_asm(u32 +diff --git a/arch/x86/include/asm/apm.h b/arch/x86/include/asm/apm.h +index 20370c6..a2eb9b0 100644 +--- a/arch/x86/include/asm/apm.h ++++ b/arch/x86/include/asm/apm.h +@@ -34,7 +34,7 @@ static inline void apm_bios_call_asm(u32 func, u32 ebx= _in, u32 ecx_in, __asm__ __volatile__(APM_DO_ZERO_SEGS "pushl %%edi\n\t" "pushl %%ebp\n\t" @@ -7265,7 +8303,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/apm= .h linux-2.6.32.49/arch/x86/i "setc %%al\n\t" "popl %%ebp\n\t" "popl %%edi\n\t" -@@ -58,7 +58,7 @@ static inline u8 apm_bios_call_simple_as +@@ -58,7 +58,7 @@ static inline u8 apm_bios_call_simple_asm(u32 func, u3= 2 ebx_in, __asm__ __volatile__(APM_DO_ZERO_SEGS "pushl %%edi\n\t" "pushl %%ebp\n\t" @@ -7274,10 +8312,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/a= pm.h linux-2.6.32.49/arch/x86/i "setc %%bl\n\t" "popl %%ebp\n\t" "popl %%edi\n\t" -diff -urNp linux-2.6.32.49/arch/x86/include/asm/atomic_32.h linux-2.6.32= .49/arch/x86/include/asm/atomic_32.h ---- linux-2.6.32.49/arch/x86/include/asm/atomic_32.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/atomic_32.h 2011-11-15 19:59:42= .000000000 -0500 -@@ -25,6 +25,17 @@ static inline int atomic_read(const atom +diff --git a/arch/x86/include/asm/atomic_32.h b/arch/x86/include/asm/ato= mic_32.h +index dc5a667..fbed878 100644 +--- a/arch/x86/include/asm/atomic_32.h ++++ b/arch/x86/include/asm/atomic_32.h +@@ -25,6 +25,17 @@ static inline int atomic_read(const atomic_t *v) } =20 /** @@ -7295,7 +8334,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch * atomic_set - set atomic variable * @v: pointer of type atomic_t * @i: required value -@@ -37,6 +48,18 @@ static inline void atomic_set(atomic_t * +@@ -37,6 +48,18 @@ static inline void atomic_set(atomic_t *v, int i) } =20 /** @@ -7314,7 +8353,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch * atomic_add - add integer to atomic variable * @i: integer value to add * @v: pointer of type atomic_t -@@ -45,7 +68,29 @@ static inline void atomic_set(atomic_t * +@@ -45,7 +68,29 @@ static inline void atomic_set(atomic_t *v, int i) */ static inline void atomic_add(int i, atomic_t *v) { @@ -7345,7 +8384,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter) : "ir" (i)); } -@@ -59,7 +104,29 @@ static inline void atomic_add(int i, ato +@@ -59,7 +104,29 @@ static inline void atomic_add(int i, atomic_t *v) */ static inline void atomic_sub(int i, atomic_t *v) { @@ -7376,7 +8415,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter) : "ir" (i)); } -@@ -77,7 +144,16 @@ static inline int atomic_sub_and_test(in +@@ -77,7 +144,16 @@ static inline int atomic_sub_and_test(int i, atomic_= t *v) { unsigned char c; =20 @@ -7394,7 +8433,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter), "=3Dqm" (c) : "ir" (i) : "memory"); return c; -@@ -91,7 +167,27 @@ static inline int atomic_sub_and_test(in +@@ -91,7 +167,27 @@ static inline int atomic_sub_and_test(int i, atomic_= t *v) */ static inline void atomic_inc(atomic_t *v) { @@ -7423,7 +8462,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter)); } =20 -@@ -103,7 +199,27 @@ static inline void atomic_inc(atomic_t * +@@ -103,7 +199,27 @@ static inline void atomic_inc(atomic_t *v) */ static inline void atomic_dec(atomic_t *v) { @@ -7452,7 +8491,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter)); } =20 -@@ -119,7 +235,16 @@ static inline int atomic_dec_and_test(at +@@ -119,7 +235,16 @@ static inline int atomic_dec_and_test(atomic_t *v) { unsigned char c; =20 @@ -7470,7 +8509,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter), "=3Dqm" (c) : : "memory"); return c !=3D 0; -@@ -137,7 +262,35 @@ static inline int atomic_inc_and_test(at +@@ -137,7 +262,35 @@ static inline int atomic_inc_and_test(atomic_t *v) { unsigned char c; =20 @@ -7507,7 +8546,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter), "=3Dqm" (c) : : "memory"); return c !=3D 0; -@@ -156,7 +309,16 @@ static inline int atomic_add_negative(in +@@ -156,7 +309,16 @@ static inline int atomic_add_negative(int i, atomic= _t *v) { unsigned char c; =20 @@ -7525,7 +8564,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch : "+m" (v->counter), "=3Dqm" (c) : "ir" (i) : "memory"); return c; -@@ -179,6 +341,46 @@ static inline int atomic_add_return(int=20 +@@ -179,6 +341,46 @@ static inline int atomic_add_return(int i, atomic_t= *v) #endif /* Modern 486+ processor */ __i =3D i; @@ -7572,7 +8611,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch asm volatile(LOCK_PREFIX "xaddl %0, %1" : "+r" (i), "+m" (v->counter) : : "memory"); -@@ -211,11 +413,21 @@ static inline int atomic_cmpxchg(atomic_ +@@ -211,11 +413,21 @@ static inline int atomic_cmpxchg(atomic_t *v, int = old, int new) return cmpxchg(&v->counter, old, new); } =20 @@ -7594,7 +8633,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch /** * atomic_add_unless - add unless the number is already a given value * @v: pointer of type atomic_t -@@ -227,22 +439,39 @@ static inline int atomic_xchg(atomic_t * +@@ -227,22 +439,39 @@ static inline int atomic_xchg(atomic_t *v, int new= ) */ static inline int atomic_add_unless(atomic_t *v, int a, int u) { @@ -7657,7 +8696,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch =20 /** * atomic64_xchg - xchg atomic64 variable -@@ -279,6 +517,7 @@ extern u64 atomic64_cmpxchg(atomic64_t * +@@ -279,6 +517,7 @@ extern u64 atomic64_cmpxchg(atomic64_t *ptr, u64 old= _val, u64 new_val); * the old value. */ extern u64 atomic64_xchg(atomic64_t *ptr, u64 new_val); @@ -7665,7 +8704,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch =20 /** * atomic64_set - set atomic64 variable -@@ -290,6 +529,15 @@ extern u64 atomic64_xchg(atomic64_t *ptr +@@ -290,6 +529,15 @@ extern u64 atomic64_xchg(atomic64_t *ptr, u64 new_v= al); extern void atomic64_set(atomic64_t *ptr, u64 new_val); =20 /** @@ -7681,7 +8720,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch * atomic64_read - read atomic64 variable * @ptr: pointer to type atomic64_t * -@@ -317,7 +565,33 @@ static inline u64 atomic64_read(atomic64 +@@ -317,7 +565,33 @@ static inline u64 atomic64_read(atomic64_t *ptr) return res; } =20 @@ -7716,7 +8755,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch =20 /** * atomic64_add_return - add and return -@@ -332,8 +606,11 @@ extern u64 atomic64_add_return(u64 delta +@@ -332,8 +606,11 @@ extern u64 atomic64_add_return(u64 delta, atomic64_= t *ptr); * Other variants with different arithmetic operators: */ extern u64 atomic64_sub_return(u64 delta, atomic64_t *ptr); @@ -7728,7 +8767,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch =20 /** * atomic64_add - add integer to atomic64 variable -@@ -345,6 +622,15 @@ extern u64 atomic64_dec_return(atomic64_ +@@ -345,6 +622,15 @@ extern u64 atomic64_dec_return(atomic64_t *ptr); extern void atomic64_add(u64 delta, atomic64_t *ptr); =20 /** @@ -7744,7 +8783,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch * atomic64_sub - subtract the atomic64 variable * @delta: integer value to subtract * @ptr: pointer to type atomic64_t -@@ -354,6 +640,15 @@ extern void atomic64_add(u64 delta, atom +@@ -354,6 +640,15 @@ extern void atomic64_add(u64 delta, atomic64_t *ptr= ); extern void atomic64_sub(u64 delta, atomic64_t *ptr); =20 /** @@ -7760,7 +8799,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch * atomic64_sub_and_test - subtract value from variable and test result * @delta: integer value to subtract * @ptr: pointer to type atomic64_t -@@ -373,6 +668,14 @@ extern int atomic64_sub_and_test(u64 del +@@ -373,6 +668,14 @@ extern int atomic64_sub_and_test(u64 delta, atomic6= 4_t *ptr); extern void atomic64_inc(atomic64_t *ptr); =20 /** @@ -7775,7 +8814,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_32.h linux-2.6.32.49/arch * atomic64_dec - decrement atomic64 variable * @ptr: pointer to type atomic64_t * -@@ -381,6 +684,14 @@ extern void atomic64_inc(atomic64_t *ptr +@@ -381,6 +684,14 @@ extern void atomic64_inc(atomic64_t *ptr); extern void atomic64_dec(atomic64_t *ptr); =20 /** @@ -7790,10 +8829,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/a= tomic_32.h linux-2.6.32.49/arch * atomic64_dec_and_test - decrement and test * @ptr: pointer to type atomic64_t * -diff -urNp linux-2.6.32.49/arch/x86/include/asm/atomic_64.h linux-2.6.32= .49/arch/x86/include/asm/atomic_64.h ---- linux-2.6.32.49/arch/x86/include/asm/atomic_64.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/atomic_64.h 2011-11-15 19:59:42= .000000000 -0500 -@@ -24,6 +24,17 @@ static inline int atomic_read(const atom +diff --git a/arch/x86/include/asm/atomic_64.h b/arch/x86/include/asm/ato= mic_64.h +index d605dc2..fafd7bd 100644 +--- a/arch/x86/include/asm/atomic_64.h ++++ b/arch/x86/include/asm/atomic_64.h +@@ -24,6 +24,17 @@ static inline int atomic_read(const atomic_t *v) } =20 /** @@ -7811,7 +8851,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch * atomic_set - set atomic variable * @v: pointer of type atomic_t * @i: required value -@@ -36,6 +47,18 @@ static inline void atomic_set(atomic_t * +@@ -36,6 +47,18 @@ static inline void atomic_set(atomic_t *v, int i) } =20 /** @@ -7830,7 +8870,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch * atomic_add - add integer to atomic variable * @i: integer value to add * @v: pointer of type atomic_t -@@ -44,7 +67,29 @@ static inline void atomic_set(atomic_t * +@@ -44,7 +67,29 @@ static inline void atomic_set(atomic_t *v, int i) */ static inline void atomic_add(int i, atomic_t *v) { @@ -7861,7 +8901,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter) : "ir" (i), "m" (v->counter)); } -@@ -58,7 +103,29 @@ static inline void atomic_add(int i, ato +@@ -58,7 +103,29 @@ static inline void atomic_add(int i, atomic_t *v) */ static inline void atomic_sub(int i, atomic_t *v) { @@ -7892,7 +8932,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter) : "ir" (i), "m" (v->counter)); } -@@ -76,7 +143,16 @@ static inline int atomic_sub_and_test(in +@@ -76,7 +143,16 @@ static inline int atomic_sub_and_test(int i, atomic_= t *v) { unsigned char c; =20 @@ -7910,7 +8950,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "ir" (i), "m" (v->counter) : "memory"); return c; -@@ -90,7 +166,28 @@ static inline int atomic_sub_and_test(in +@@ -90,7 +166,28 @@ static inline int atomic_sub_and_test(int i, atomic_= t *v) */ static inline void atomic_inc(atomic_t *v) { @@ -7940,7 +8980,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter) : "m" (v->counter)); } -@@ -103,7 +200,28 @@ static inline void atomic_inc(atomic_t * +@@ -103,7 +200,28 @@ static inline void atomic_inc(atomic_t *v) */ static inline void atomic_dec(atomic_t *v) { @@ -7970,7 +9010,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter) : "m" (v->counter)); } -@@ -120,7 +238,16 @@ static inline int atomic_dec_and_test(at +@@ -120,7 +238,16 @@ static inline int atomic_dec_and_test(atomic_t *v) { unsigned char c; =20 @@ -7988,7 +9028,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "m" (v->counter) : "memory"); return c !=3D 0; -@@ -138,7 +265,35 @@ static inline int atomic_inc_and_test(at +@@ -138,7 +265,35 @@ static inline int atomic_inc_and_test(atomic_t *v) { unsigned char c; =20 @@ -8025,7 +9065,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "m" (v->counter) : "memory"); return c !=3D 0; -@@ -157,7 +312,16 @@ static inline int atomic_add_negative(in +@@ -157,7 +312,16 @@ static inline int atomic_add_negative(int i, atomic= _t *v) { unsigned char c; =20 @@ -8043,7 +9083,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "ir" (i), "m" (v->counter) : "memory"); return c; -@@ -173,7 +337,31 @@ static inline int atomic_add_negative(in +@@ -173,7 +337,31 @@ static inline int atomic_add_negative(int i, atomic= _t *v) static inline int atomic_add_return(int i, atomic_t *v) { int __i =3D i; @@ -8076,7 +9116,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "+r" (i), "+m" (v->counter) : : "memory"); return i + __i; -@@ -185,6 +373,10 @@ static inline int atomic_sub_return(int=20 +@@ -185,6 +373,10 @@ static inline int atomic_sub_return(int i, atomic_t= *v) } =20 #define atomic_inc_return(v) (atomic_add_return(1, v)) @@ -8087,7 +9127,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch #define atomic_dec_return(v) (atomic_sub_return(1, v)) =20 /* The 64-bit atomic type */ -@@ -204,6 +396,18 @@ static inline long atomic64_read(const a +@@ -204,6 +396,18 @@ static inline long atomic64_read(const atomic64_t *= v) } =20 /** @@ -8106,7 +9146,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch * atomic64_set - set atomic64 variable * @v: pointer to type atomic64_t * @i: required value -@@ -216,6 +420,18 @@ static inline void atomic64_set(atomic64 +@@ -216,6 +420,18 @@ static inline void atomic64_set(atomic64_t *v, long= i) } =20 /** @@ -8125,7 +9165,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch * atomic64_add - add integer to atomic64 variable * @i: integer value to add * @v: pointer to type atomic64_t -@@ -224,6 +440,28 @@ static inline void atomic64_set(atomic64 +@@ -224,6 +440,28 @@ static inline void atomic64_set(atomic64_t *v, long= i) */ static inline void atomic64_add(long i, atomic64_t *v) { @@ -8154,7 +9194,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch asm volatile(LOCK_PREFIX "addq %1,%0" : "=3Dm" (v->counter) : "er" (i), "m" (v->counter)); -@@ -238,7 +476,15 @@ static inline void atomic64_add(long i,=20 +@@ -238,7 +476,15 @@ static inline void atomic64_add(long i, atomic64_t = *v) */ static inline void atomic64_sub(long i, atomic64_t *v) { @@ -8171,7 +9211,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter) : "er" (i), "m" (v->counter)); } -@@ -256,7 +502,16 @@ static inline int atomic64_sub_and_test( +@@ -256,7 +502,16 @@ static inline int atomic64_sub_and_test(long i, ato= mic64_t *v) { unsigned char c; =20 @@ -8189,7 +9229,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "er" (i), "m" (v->counter) : "memory"); return c; -@@ -270,6 +525,27 @@ static inline int atomic64_sub_and_test( +@@ -270,6 +525,27 @@ static inline int atomic64_sub_and_test(long i, ato= mic64_t *v) */ static inline void atomic64_inc(atomic64_t *v) { @@ -8217,7 +9257,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch asm volatile(LOCK_PREFIX "incq %0" : "=3Dm" (v->counter) : "m" (v->counter)); -@@ -283,7 +559,28 @@ static inline void atomic64_inc(atomic64 +@@ -283,7 +559,28 @@ static inline void atomic64_inc(atomic64_t *v) */ static inline void atomic64_dec(atomic64_t *v) { @@ -8247,7 +9287,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter) : "m" (v->counter)); } -@@ -300,7 +597,16 @@ static inline int atomic64_dec_and_test( +@@ -300,7 +597,16 @@ static inline int atomic64_dec_and_test(atomic64_t = *v) { unsigned char c; =20 @@ -8265,7 +9305,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "m" (v->counter) : "memory"); return c !=3D 0; -@@ -318,7 +624,16 @@ static inline int atomic64_inc_and_test( +@@ -318,7 +624,16 @@ static inline int atomic64_inc_and_test(atomic64_t = *v) { unsigned char c; =20 @@ -8283,7 +9323,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "m" (v->counter) : "memory"); return c !=3D 0; -@@ -337,7 +652,16 @@ static inline int atomic64_add_negative( +@@ -337,7 +652,16 @@ static inline int atomic64_add_negative(long i, ato= mic64_t *v) { unsigned char c; =20 @@ -8301,7 +9341,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "=3Dm" (v->counter), "=3Dqm" (c) : "er" (i), "m" (v->counter) : "memory"); return c; -@@ -353,7 +677,31 @@ static inline int atomic64_add_negative( +@@ -353,7 +677,31 @@ static inline int atomic64_add_negative(long i, ato= mic64_t *v) static inline long atomic64_add_return(long i, atomic64_t *v) { long __i =3D i; @@ -8334,7 +9374,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch : "+r" (i), "+m" (v->counter) : : "memory"); return i + __i; -@@ -365,6 +713,10 @@ static inline long atomic64_sub_return(l +@@ -365,6 +713,10 @@ static inline long atomic64_sub_return(long i, atom= ic64_t *v) } =20 #define atomic64_inc_return(v) (atomic64_add_return(1, (v))) @@ -8345,7 +9385,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch #define atomic64_dec_return(v) (atomic64_sub_return(1, (v))) =20 static inline long atomic64_cmpxchg(atomic64_t *v, long old, long new) -@@ -372,21 +724,41 @@ static inline long atomic64_cmpxchg(atom +@@ -372,21 +724,41 @@ static inline long atomic64_cmpxchg(atomic64_t *v,= long old, long new) return cmpxchg(&v->counter, old, new); } =20 @@ -8387,7 +9427,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch /** * atomic_add_unless - add unless the number is a given value * @v: pointer of type atomic_t -@@ -398,17 +770,30 @@ static inline long atomic_xchg(atomic_t=20 +@@ -398,17 +770,30 @@ static inline long atomic_xchg(atomic_t *v, int ne= w) */ static inline int atomic_add_unless(atomic_t *v, int a, int u) { @@ -8422,7 +9462,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/ato= mic_64.h linux-2.6.32.49/arch } =20 #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) -@@ -424,17 +809,30 @@ static inline int atomic_add_unless(atom +@@ -424,17 +809,30 @@ static inline int atomic_add_unless(atomic_t *v, i= nt a, int u) */ static inline int atomic64_add_unless(atomic64_t *v, long a, long u) { @@ -8457,9 +9497,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/at= omic_64.h linux-2.6.32.49/arch } =20 /** -diff -urNp linux-2.6.32.49/arch/x86/include/asm/bitops.h linux-2.6.32.49= /arch/x86/include/asm/bitops.h ---- linux-2.6.32.49/arch/x86/include/asm/bitops.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/bitops.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/bitops.h b/arch/x86/include/asm/bitops= .h +index 02b47a6..d5c4b15 100644 +--- a/arch/x86/include/asm/bitops.h ++++ b/arch/x86/include/asm/bitops.h @@ -38,7 +38,7 @@ * a mask operation on a byte. */ @@ -8469,9 +9510,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/bi= tops.h linux-2.6.32.49/arch/x8 #define CONST_MASK(nr) (1 << ((nr) & 7)) =20 /** -diff -urNp linux-2.6.32.49/arch/x86/include/asm/boot.h linux-2.6.32.49/a= rch/x86/include/asm/boot.h ---- linux-2.6.32.49/arch/x86/include/asm/boot.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/boot.h 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/x86/include/asm/boot.h b/arch/x86/include/asm/boot.h +index 7a10659..8bbf355 100644 +--- a/arch/x86/include/asm/boot.h ++++ b/arch/x86/include/asm/boot.h @@ -11,10 +11,15 @@ #include =20 @@ -8489,9 +9531,26 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/bo= ot.h linux-2.6.32.49/arch/x86/ /* Minimum kernel alignment, as a power of two */ #ifdef CONFIG_X86_64 #define MIN_KERNEL_ALIGN_LG2 PMD_SHIFT -diff -urNp linux-2.6.32.49/arch/x86/include/asm/cacheflush.h linux-2.6.3= 2.49/arch/x86/include/asm/cacheflush.h ---- linux-2.6.32.49/arch/x86/include/asm/cacheflush.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/cacheflush.h 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/x86/include/asm/cache.h b/arch/x86/include/asm/cache.h +index 549860d..7d45f68 100644 +--- a/arch/x86/include/asm/cache.h ++++ b/arch/x86/include/asm/cache.h +@@ -5,9 +5,10 @@ +=20 + /* L1 cache line size */ + #define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) +-#define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT) ++#define L1_CACHE_BYTES (_AC(1,UL) << L1_CACHE_SHIFT) +=20 + #define __read_mostly __attribute__((__section__(".data.read_mostly"))) ++#define __read_only __attribute__((__section__(".data.read_only"))) +=20 + #ifdef CONFIG_X86_VSMP + /* vSMP Internode cacheline shift */ +diff --git a/arch/x86/include/asm/cacheflush.h b/arch/x86/include/asm/ca= cheflush.h +index b54f6af..5b376a6 100644 +--- a/arch/x86/include/asm/cacheflush.h ++++ b/arch/x86/include/asm/cacheflush.h @@ -60,7 +60,7 @@ PAGEFLAG(WC, WC) static inline unsigned long get_page_memtype(struct page *pg) { @@ -8501,7 +9560,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/cac= heflush.h linux-2.6.32.49/arc else if (!PageUncached(pg) && PageWC(pg)) return _PAGE_CACHE_WC; else if (PageUncached(pg) && !PageWC(pg)) -@@ -85,7 +85,7 @@ static inline void set_page_memtype(stru +@@ -85,7 +85,7 @@ static inline void set_page_memtype(struct page *pg, u= nsigned long memtype) SetPageWC(pg); break; default: @@ -8510,25 +9569,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/c= acheflush.h linux-2.6.32.49/arc ClearPageUncached(pg); ClearPageWC(pg); break; -diff -urNp linux-2.6.32.49/arch/x86/include/asm/cache.h linux-2.6.32.49/= arch/x86/include/asm/cache.h ---- linux-2.6.32.49/arch/x86/include/asm/cache.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/cache.h 2011-11-15 19:59:42.000= 000000 -0500 -@@ -5,9 +5,10 @@ -=20 - /* L1 cache line size */ - #define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) --#define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT) -+#define L1_CACHE_BYTES (_AC(1,UL) << L1_CACHE_SHIFT) -=20 - #define __read_mostly __attribute__((__section__(".data.read_mostly"))) -+#define __read_only __attribute__((__section__(".data.read_only"))) -=20 - #ifdef CONFIG_X86_VSMP - /* vSMP Internode cacheline shift */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/calling.h linux-2.6.32.4= 9/arch/x86/include/asm/calling.h ---- linux-2.6.32.49/arch/x86/include/asm/calling.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/calling.h 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -52,32 +52,32 @@ For 32-bit we have the following convent +diff --git a/arch/x86/include/asm/calling.h b/arch/x86/include/asm/calli= ng.h +index 0e63c9a..ab8d972 100644 +--- a/arch/x86/include/asm/calling.h ++++ b/arch/x86/include/asm/calling.h +@@ -52,32 +52,32 @@ For 32-bit we have the following conventions - kerne= l is built with * for assembly code: */ =20 @@ -8582,10 +9627,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/c= alling.h linux-2.6.32.49/arch/x =20 #define ARGOFFSET R11 #define SWFRAME ORIG_RAX -diff -urNp linux-2.6.32.49/arch/x86/include/asm/checksum_32.h linux-2.6.= 32.49/arch/x86/include/asm/checksum_32.h ---- linux-2.6.32.49/arch/x86/include/asm/checksum_32.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/checksum_32.h 2011-11-15 19:59:= 42.000000000 -0500 -@@ -31,6 +31,14 @@ asmlinkage __wsum csum_partial_copy_gene +diff --git a/arch/x86/include/asm/checksum_32.h b/arch/x86/include/asm/c= hecksum_32.h +index 46fc474..b02b0f9 100644 +--- a/arch/x86/include/asm/checksum_32.h ++++ b/arch/x86/include/asm/checksum_32.h +@@ -31,6 +31,14 @@ asmlinkage __wsum csum_partial_copy_generic(const voi= d *src, void *dst, int len, __wsum sum, int *src_err_ptr, int *dst_err_ptr); =20 @@ -8600,7 +9646,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/che= cksum_32.h linux-2.6.32.49/ar /* * Note: when you get a NULL pointer exception here this means someone * passed in an incorrect kernel address to one of these functions. -@@ -50,7 +58,7 @@ static inline __wsum csum_partial_copy_f +@@ -50,7 +58,7 @@ static inline __wsum csum_partial_copy_from_user(const= void __user *src, int *err_ptr) { might_sleep(); @@ -8609,7 +9655,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/che= cksum_32.h linux-2.6.32.49/ar len, sum, err_ptr, NULL); } =20 -@@ -178,7 +186,7 @@ static inline __wsum csum_and_copy_to_us +@@ -178,7 +186,7 @@ static inline __wsum csum_and_copy_to_user(const voi= d *src, { might_sleep(); if (access_ok(VERIFY_WRITE, dst, len)) @@ -8618,25 +9664,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/c= hecksum_32.h linux-2.6.32.49/ar len, sum, NULL, err_ptr); =20 if (len) -diff -urNp linux-2.6.32.49/arch/x86/include/asm/desc_defs.h linux-2.6.32= .49/arch/x86/include/asm/desc_defs.h ---- linux-2.6.32.49/arch/x86/include/asm/desc_defs.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/desc_defs.h 2011-11-15 19:59:42= .000000000 -0500 -@@ -31,6 +31,12 @@ struct desc_struct { - unsigned base1: 8, type: 4, s: 1, dpl: 2, p: 1; - unsigned limit: 4, avl: 1, l: 1, d: 1, g: 1, base2: 8; - }; -+ struct { -+ u16 offset_low; -+ u16 seg; -+ unsigned reserved: 8, type: 4, s: 1, dpl: 2, p: 1; -+ unsigned offset_high: 16; -+ } gate; - }; - } __attribute__((packed)); -=20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/desc.h linux-2.6.32.49/a= rch/x86/include/asm/desc.h ---- linux-2.6.32.49/arch/x86/include/asm/desc.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/desc.h 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/x86/include/asm/desc.h b/arch/x86/include/asm/desc.h +index 617bd56..7b047a1 100644 +--- a/arch/x86/include/asm/desc.h ++++ b/arch/x86/include/asm/desc.h @@ -4,6 +4,7 @@ #include #include @@ -8645,7 +9676,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ #include =20 static inline void fill_ldt(struct desc_struct *desc, -@@ -15,6 +16,7 @@ static inline void fill_ldt(struct desc_ +@@ -15,6 +16,7 @@ static inline void fill_ldt(struct desc_struct *desc, desc->base1 =3D (info->base_addr & 0x00ff0000) >> 16; desc->type =3D (info->read_exec_only ^ 1) << 1; desc->type |=3D info->contents << 2; @@ -8653,7 +9684,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ desc->s =3D 1; desc->dpl =3D 0x3; desc->p =3D info->seg_not_present ^ 1; -@@ -31,16 +33,12 @@ static inline void fill_ldt(struct desc_ +@@ -31,16 +33,12 @@ static inline void fill_ldt(struct desc_struct *desc= , } =20 extern struct desc_ptr idt_descr; @@ -8673,7 +9704,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ } =20 #ifdef CONFIG_X86_64 -@@ -65,9 +63,14 @@ static inline void pack_gate(gate_desc * +@@ -65,9 +63,14 @@ static inline void pack_gate(gate_desc *gate, unsigne= d char type, unsigned long base, unsigned dpl, unsigned flags, unsigned short seg) { @@ -8691,7 +9722,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ } =20 #endif -@@ -115,13 +118,17 @@ static inline void paravirt_free_ldt(str +@@ -115,13 +118,17 @@ static inline void paravirt_free_ldt(struct desc_s= truct *ldt, unsigned entries) static inline void native_write_idt_entry(gate_desc *idt, int entry, const gate_desc *gate) { @@ -8709,7 +9740,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ } =20 static inline void native_write_gdt_entry(struct desc_struct *gdt, int = entry, -@@ -139,7 +146,10 @@ static inline void native_write_gdt_entr +@@ -139,7 +146,10 @@ static inline void native_write_gdt_entry(struct de= sc_struct *gdt, int entry, size =3D sizeof(struct desc_struct); break; } @@ -8720,7 +9751,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ } =20 static inline void pack_descriptor(struct desc_struct *desc, unsigned l= ong base, -@@ -211,7 +221,9 @@ static inline void native_set_ldt(const=20 +@@ -211,7 +221,9 @@ static inline void native_set_ldt(const void *addr, = unsigned int entries) =20 static inline void native_load_tr_desc(void) { @@ -8730,7 +9761,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ } =20 static inline void native_load_gdt(const struct desc_ptr *dtr) -@@ -246,8 +258,10 @@ static inline void native_load_tls(struc +@@ -246,8 +258,10 @@ static inline void native_load_tls(struct thread_st= ruct *t, unsigned int cpu) unsigned int i; struct desc_struct *gdt =3D get_cpu_gdt_table(cpu); =20 @@ -8741,7 +9772,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ } =20 #define _LDT_empty(info) \ -@@ -309,7 +323,7 @@ static inline void set_desc_limit(struct +@@ -309,7 +323,7 @@ static inline void set_desc_limit(struct desc_struct= *desc, unsigned long limit) desc->limit =3D (limit >> 16) & 0xf; } =20 @@ -8750,7 +9781,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ unsigned dpl, unsigned ist, unsigned seg) { gate_desc s; -@@ -327,7 +341,7 @@ static inline void _set_gate(int gate, u +@@ -327,7 +341,7 @@ static inline void _set_gate(int gate, unsigned type= , void *addr, * Pentium F0 0F bugfix can have resulted in the mapped * IDT being write-protected. */ @@ -8759,7 +9790,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ { BUG_ON((unsigned)n > 0xFF); _set_gate(n, GATE_INTERRUPT, addr, 0, 0, __KERNEL_CS); -@@ -356,19 +370,19 @@ static inline void alloc_intr_gate(unsig +@@ -356,19 +370,19 @@ static inline void alloc_intr_gate(unsigned int n,= void *addr) /* * This routine sets up an interrupt gate at directory privilege level = 3. */ @@ -8782,7 +9813,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/des= c.h linux-2.6.32.49/arch/x86/ { BUG_ON((unsigned)n > 0xFF); _set_gate(n, GATE_TRAP, addr, 0, 0, __KERNEL_CS); -@@ -377,19 +391,31 @@ static inline void set_trap_gate(unsigne +@@ -377,19 +391,31 @@ static inline void set_trap_gate(unsigned int n, v= oid *addr) static inline void set_task_gate(unsigned int n, unsigned int gdt_entry= ) { BUG_ON((unsigned)n > 0xFF); @@ -8817,9 +9848,27 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/de= sc.h linux-2.6.32.49/arch/x86/ +#endif + #endif /* _ASM_X86_DESC_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/device.h linux-2.6.32.49= /arch/x86/include/asm/device.h ---- linux-2.6.32.49/arch/x86/include/asm/device.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/device.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/desc_defs.h b/arch/x86/include/asm/des= c_defs.h +index 9d66848..6b4a691 100644 +--- a/arch/x86/include/asm/desc_defs.h ++++ b/arch/x86/include/asm/desc_defs.h +@@ -31,6 +31,12 @@ struct desc_struct { + unsigned base1: 8, type: 4, s: 1, dpl: 2, p: 1; + unsigned limit: 4, avl: 1, l: 1, d: 1, g: 1, base2: 8; + }; ++ struct { ++ u16 offset_low; ++ u16 seg; ++ unsigned reserved: 8, type: 4, s: 1, dpl: 2, p: 1; ++ unsigned offset_high: 16; ++ } gate; + }; + } __attribute__((packed)); +=20 +diff --git a/arch/x86/include/asm/device.h b/arch/x86/include/asm/device= .h +index cee34e9..a7c3fa2 100644 +--- a/arch/x86/include/asm/device.h ++++ b/arch/x86/include/asm/device.h @@ -6,7 +6,7 @@ struct dev_archdata { void *acpi_handle; #endif @@ -8829,9 +9878,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/de= vice.h linux-2.6.32.49/arch/x8 #endif #ifdef CONFIG_DMAR void *iommu; /* hook for IOMMU specific extension */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/dma-mapping.h linux-2.6.= 32.49/arch/x86/include/asm/dma-mapping.h ---- linux-2.6.32.49/arch/x86/include/asm/dma-mapping.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/dma-mapping.h 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/x86/include/asm/dma-mapping.h b/arch/x86/include/asm/d= ma-mapping.h +index 6a25d5d..786b202 100644 +--- a/arch/x86/include/asm/dma-mapping.h ++++ b/arch/x86/include/asm/dma-mapping.h @@ -25,9 +25,9 @@ extern int iommu_merge; extern struct device x86_dma_fallback_dev; extern int panic_on_overflow; @@ -8844,7 +9894,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/dma= -mapping.h linux-2.6.32.49/ar { #ifdef CONFIG_X86_32 return dma_ops; -@@ -44,7 +44,7 @@ static inline struct dma_map_ops *get_dm +@@ -44,7 +44,7 @@ static inline struct dma_map_ops *get_dma_ops(struct d= evice *dev) /* Make sure we keep the same behaviour */ static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_= addr) { @@ -8862,7 +9912,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/dma= -mapping.h linux-2.6.32.49/ar void *memory; =20 gfp &=3D ~(__GFP_DMA | __GFP_HIGHMEM | __GFP_DMA32); -@@ -149,7 +149,7 @@ dma_alloc_coherent(struct device *dev, s +@@ -149,7 +149,7 @@ dma_alloc_coherent(struct device *dev, size_t size, = dma_addr_t *dma_handle, static inline void dma_free_coherent(struct device *dev, size_t size, void *vaddr, dma_addr_t bus) { @@ -8871,10 +9921,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/d= ma-mapping.h linux-2.6.32.49/ar =20 WARN_ON(irqs_disabled()); /* for portability */ =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/e820.h linux-2.6.32.49/a= rch/x86/include/asm/e820.h ---- linux-2.6.32.49/arch/x86/include/asm/e820.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/e820.h 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -133,7 +133,7 @@ extern char *default_machine_specific_me +diff --git a/arch/x86/include/asm/e820.h b/arch/x86/include/asm/e820.h +index 40b4e61..40d8133 100644 +--- a/arch/x86/include/asm/e820.h ++++ b/arch/x86/include/asm/e820.h +@@ -133,7 +133,7 @@ extern char *default_machine_specific_memory_setup(v= oid); #define ISA_END_ADDRESS 0x100000 #define is_ISA_range(s, e) ((s) >=3D ISA_START_ADDRESS && (e) < ISA_END= _ADDRESS) =20 @@ -8883,9 +9934,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/e8= 20.h linux-2.6.32.49/arch/x86/ #define BIOS_END 0x00100000 =20 #ifdef __KERNEL__ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/elf.h linux-2.6.32.49/ar= ch/x86/include/asm/elf.h ---- linux-2.6.32.49/arch/x86/include/asm/elf.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/elf.h 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/x86/include/asm/elf.h b/arch/x86/include/asm/elf.h +index 8ac9d9a..0a6c96e 100644 +--- a/arch/x86/include/asm/elf.h ++++ b/arch/x86/include/asm/elf.h @@ -257,7 +257,25 @@ extern int force_personality32; the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ @@ -8932,7 +9984,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/elf= .h linux-2.6.32.49/arch/x86/i =20 #define VDSO_ENTRY \ ((unsigned long)VDSO32_SYMBOL(VDSO_CURRENT_BASE, vsyscall)) -@@ -337,7 +353,4 @@ extern int arch_setup_additional_pages(s +@@ -337,7 +353,4 @@ extern int arch_setup_additional_pages(struct linux_= binprm *bprm, extern int syscall32_setup_pages(struct linux_binprm *, int exstack); #define compat_arch_setup_additional_pages syscall32_setup_pages =20 @@ -8940,9 +9992,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/el= f.h linux-2.6.32.49/arch/x86/i -#define arch_randomize_brk arch_randomize_brk - #endif /* _ASM_X86_ELF_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/emergency-restart.h linu= x-2.6.32.49/arch/x86/include/asm/emergency-restart.h ---- linux-2.6.32.49/arch/x86/include/asm/emergency-restart.h 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/emergency-restart.h 2011-11-15 = 19:59:42.000000000 -0500 +diff --git a/arch/x86/include/asm/emergency-restart.h b/arch/x86/include= /asm/emergency-restart.h +index cc70c1c..d96d011 100644 +--- a/arch/x86/include/asm/emergency-restart.h ++++ b/arch/x86/include/asm/emergency-restart.h @@ -15,6 +15,6 @@ enum reboot_type { =20 extern enum reboot_type reboot_type; @@ -8951,9 +10004,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/e= mergency-restart.h linux-2.6.32 +extern void machine_emergency_restart(void) __noreturn; =20 #endif /* _ASM_X86_EMERGENCY_RESTART_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/futex.h linux-2.6.32.49/= arch/x86/include/asm/futex.h ---- linux-2.6.32.49/arch/x86/include/asm/futex.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/futex.h 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/x86/include/asm/futex.h b/arch/x86/include/asm/futex.h +index 1f11ce4..7caabd1 100644 +--- a/arch/x86/include/asm/futex.h ++++ b/arch/x86/include/asm/futex.h @@ -12,16 +12,18 @@ #include =20 @@ -8987,7 +10041,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/fu= tex.h linux-2.6.32.49/arch/x86 { int op =3D (encoded_op >> 28) & 7; int cmp =3D (encoded_op >> 24) & 15; -@@ -61,10 +63,10 @@ static inline int futex_atomic_op_inuser +@@ -61,10 +63,10 @@ static inline int futex_atomic_op_inuser(int encoded= _op, int __user *uaddr) =20 switch (op) { case FUTEX_OP_SET: @@ -9000,7 +10054,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/fu= tex.h linux-2.6.32.49/arch/x86 uaddr, oparg); break; case FUTEX_OP_OR: -@@ -109,7 +111,7 @@ static inline int futex_atomic_op_inuser +@@ -109,7 +111,7 @@ static inline int futex_atomic_op_inuser(int encoded= _op, int __user *uaddr) return ret; } =20 @@ -9009,7 +10063,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/fu= tex.h linux-2.6.32.49/arch/x86 int newval) { =20 -@@ -119,16 +121,16 @@ static inline int futex_atomic_cmpxchg_i +@@ -119,16 +121,16 @@ static inline int futex_atomic_cmpxchg_inatomic(in= t __user *uaddr, int oldval, return -ENOSYS; #endif =20 @@ -9029,9 +10083,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/f= utex.h linux-2.6.32.49/arch/x86 : "i" (-EFAULT), "r" (newval), "0" (oldval) : "memory" ); -diff -urNp linux-2.6.32.49/arch/x86/include/asm/hw_irq.h linux-2.6.32.49= /arch/x86/include/asm/hw_irq.h ---- linux-2.6.32.49/arch/x86/include/asm/hw_irq.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/hw_irq.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/hw_irq.h b/arch/x86/include/asm/hw_irq= .h +index ba180d9..3bad351 100644 +--- a/arch/x86/include/asm/hw_irq.h ++++ b/arch/x86/include/asm/hw_irq.h @@ -92,8 +92,8 @@ extern void setup_ioapic_dest(void); extern void enable_IO_APIC(void); =20 @@ -9043,10 +10098,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= hw_irq.h linux-2.6.32.49/arch/x8 =20 /* EISA */ extern void eisa_set_level_irq(unsigned int irq); -diff -urNp linux-2.6.32.49/arch/x86/include/asm/i387.h linux-2.6.32.49/a= rch/x86/include/asm/i387.h ---- linux-2.6.32.49/arch/x86/include/asm/i387.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/i387.h 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -60,6 +60,11 @@ static inline int fxrstor_checking(struc +diff --git a/arch/x86/include/asm/i387.h b/arch/x86/include/asm/i387.h +index 0b20bbb..4cb1396 100644 +--- a/arch/x86/include/asm/i387.h ++++ b/arch/x86/include/asm/i387.h +@@ -60,6 +60,11 @@ static inline int fxrstor_checking(struct i387_fxsave= _struct *fx) { int err; =20 @@ -9058,7 +10114,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/i3= 87.h linux-2.6.32.49/arch/x86/ asm volatile("1: rex64/fxrstor (%[fx])\n\t" "2:\n" ".section .fixup,\"ax\"\n" -@@ -105,6 +110,11 @@ static inline int fxsave_user(struct i38 +@@ -105,6 +110,11 @@ static inline int fxsave_user(struct i387_fxsave_st= ruct __user *fx) { int err; =20 @@ -9070,7 +10126,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/i3= 87.h linux-2.6.32.49/arch/x86/ asm volatile("1: rex64/fxsave (%[fx])\n\t" "2:\n" ".section .fixup,\"ax\"\n" -@@ -195,13 +205,8 @@ static inline int fxrstor_checking(struc +@@ -195,13 +205,8 @@ static inline int fxrstor_checking(struct i387_fxsa= ve_struct *fx) } =20 /* We need a safe address that is cheap to find and that is already @@ -9086,7 +10142,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/i3= 87.h linux-2.6.32.49/arch/x86/ =20 /* * These must be called with preempt disabled -@@ -291,7 +296,7 @@ static inline void kernel_fpu_begin(void +@@ -291,7 +296,7 @@ static inline void kernel_fpu_begin(void) struct thread_info *me =3D current_thread_info(); preempt_disable(); if (me->status & TS_USEDFPU) @@ -9095,9 +10151,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/i= 387.h linux-2.6.32.49/arch/x86/ else clts(); } -diff -urNp linux-2.6.32.49/arch/x86/include/asm/io_32.h linux-2.6.32.49/= arch/x86/include/asm/io_32.h ---- linux-2.6.32.49/arch/x86/include/asm/io_32.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/io_32.h 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/x86/include/asm/io_32.h b/arch/x86/include/asm/io_32.h +index a299900..15c5410 100644 +--- a/arch/x86/include/asm/io_32.h ++++ b/arch/x86/include/asm/io_32.h @@ -3,6 +3,7 @@ =20 #include @@ -9124,9 +10181,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/i= o_32.h linux-2.6.32.49/arch/x86 #include =20 #include -diff -urNp linux-2.6.32.49/arch/x86/include/asm/io_64.h linux-2.6.32.49/= arch/x86/include/asm/io_64.h ---- linux-2.6.32.49/arch/x86/include/asm/io_64.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/io_64.h 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/x86/include/asm/io_64.h b/arch/x86/include/asm/io_64.h +index 2440678..c158b88 100644 +--- a/arch/x86/include/asm/io_64.h ++++ b/arch/x86/include/asm/io_64.h @@ -140,6 +140,17 @@ __OUTS(l) =20 #include @@ -9145,9 +10203,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/i= o_64.h linux-2.6.32.49/arch/x86 #include =20 void __memcpy_fromio(void *, unsigned long, unsigned); -diff -urNp linux-2.6.32.49/arch/x86/include/asm/iommu.h linux-2.6.32.49/= arch/x86/include/asm/iommu.h ---- linux-2.6.32.49/arch/x86/include/asm/iommu.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/iommu.h 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/x86/include/asm/iommu.h b/arch/x86/include/asm/iommu.h +index fd6d21b..8b13915 100644 +--- a/arch/x86/include/asm/iommu.h ++++ b/arch/x86/include/asm/iommu.h @@ -3,7 +3,7 @@ =20 extern void pci_iommu_shutdown(void); @@ -9157,10 +10216,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= iommu.h linux-2.6.32.49/arch/x86 extern int force_iommu, no_iommu; extern int iommu_detected; extern int iommu_pass_through; -diff -urNp linux-2.6.32.49/arch/x86/include/asm/irqflags.h linux-2.6.32.= 49/arch/x86/include/asm/irqflags.h ---- linux-2.6.32.49/arch/x86/include/asm/irqflags.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/irqflags.h 2011-11-15 19:59:42.= 000000000 -0500 -@@ -142,6 +142,11 @@ static inline unsigned long __raw_local_ +diff --git a/arch/x86/include/asm/irqflags.h b/arch/x86/include/asm/irqf= lags.h +index 9e2b952..557206e 100644 +--- a/arch/x86/include/asm/irqflags.h ++++ b/arch/x86/include/asm/irqflags.h +@@ -142,6 +142,11 @@ static inline unsigned long __raw_local_irq_save(vo= id) sti; \ sysexit =20 @@ -9172,9 +10232,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/i= rqflags.h linux-2.6.32.49/arch/ #else #define INTERRUPT_RETURN iret #define ENABLE_INTERRUPTS_SYSEXIT sti; sysexit -diff -urNp linux-2.6.32.49/arch/x86/include/asm/kprobes.h linux-2.6.32.4= 9/arch/x86/include/asm/kprobes.h ---- linux-2.6.32.49/arch/x86/include/asm/kprobes.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/kprobes.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/x86/include/asm/kprobes.h b/arch/x86/include/asm/kprob= es.h +index 4fe681d..bb6d40c 100644 +--- a/arch/x86/include/asm/kprobes.h ++++ b/arch/x86/include/asm/kprobes.h @@ -34,13 +34,8 @@ typedef u8 kprobe_opcode_t; #define BREAKPOINT_INSTRUCTION 0xcc #define RELATIVEJUMP_INSTRUCTION 0xe9 @@ -9191,9 +10252,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/k= probes.h linux-2.6.32.49/arch/x =20 #define flush_insn_slot(p) do { } while (0) =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/kvm_host.h linux-2.6.32.= 49/arch/x86/include/asm/kvm_host.h ---- linux-2.6.32.49/arch/x86/include/asm/kvm_host.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/kvm_host.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_= host.h +index 08bc2ff..2e88d1f 100644 +--- a/arch/x86/include/asm/kvm_host.h ++++ b/arch/x86/include/asm/kvm_host.h @@ -534,9 +534,9 @@ struct kvm_x86_ops { bool (*gb_page_enable)(void); =20 @@ -9206,9 +10268,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/k= vm_host.h linux-2.6.32.49/arch/ =20 int kvm_mmu_module_init(void); void kvm_mmu_module_exit(void); -diff -urNp linux-2.6.32.49/arch/x86/include/asm/local.h linux-2.6.32.49/= arch/x86/include/asm/local.h ---- linux-2.6.32.49/arch/x86/include/asm/local.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/local.h 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/x86/include/asm/local.h b/arch/x86/include/asm/local.h +index 47b9b6f..815aaa1 100644 +--- a/arch/x86/include/asm/local.h ++++ b/arch/x86/include/asm/local.h @@ -18,26 +18,58 @@ typedef struct { =20 static inline void local_inc(local_t *l) @@ -9272,7 +10335,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/lo= cal.h linux-2.6.32.49/arch/x86 : "+m" (l->a.counter) : "ir" (i)); } -@@ -55,7 +87,16 @@ static inline int local_sub_and_test(lon +@@ -55,7 +87,16 @@ static inline int local_sub_and_test(long i, local_t = *l) { unsigned char c; =20 @@ -9290,7 +10353,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/lo= cal.h linux-2.6.32.49/arch/x86 : "+m" (l->a.counter), "=3Dqm" (c) : "ir" (i) : "memory"); return c; -@@ -73,7 +114,16 @@ static inline int local_dec_and_test(loc +@@ -73,7 +114,16 @@ static inline int local_dec_and_test(local_t *l) { unsigned char c; =20 @@ -9308,7 +10371,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/lo= cal.h linux-2.6.32.49/arch/x86 : "+m" (l->a.counter), "=3Dqm" (c) : : "memory"); return c !=3D 0; -@@ -91,7 +141,16 @@ static inline int local_inc_and_test(loc +@@ -91,7 +141,16 @@ static inline int local_inc_and_test(local_t *l) { unsigned char c; =20 @@ -9326,7 +10389,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/lo= cal.h linux-2.6.32.49/arch/x86 : "+m" (l->a.counter), "=3Dqm" (c) : : "memory"); return c !=3D 0; -@@ -110,7 +169,16 @@ static inline int local_add_negative(lon +@@ -110,7 +169,16 @@ static inline int local_add_negative(long i, local_= t *l) { unsigned char c; =20 @@ -9344,7 +10407,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/lo= cal.h linux-2.6.32.49/arch/x86 : "+m" (l->a.counter), "=3Dqm" (c) : "ir" (i) : "memory"); return c; -@@ -133,7 +201,15 @@ static inline long local_add_return(long +@@ -133,7 +201,15 @@ static inline long local_add_return(long i, local_t= *l) #endif /* Modern 486+ processor */ __i =3D i; @@ -9361,9 +10424,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/l= ocal.h linux-2.6.32.49/arch/x86 : "+r" (i), "+m" (l->a.counter) : : "memory"); return i + __i; -diff -urNp linux-2.6.32.49/arch/x86/include/asm/microcode.h linux-2.6.32= .49/arch/x86/include/asm/microcode.h ---- linux-2.6.32.49/arch/x86/include/asm/microcode.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/microcode.h 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/include/asm/microcode.h b/arch/x86/include/asm/mic= rocode.h +index ef51b50..514ba37 100644 +--- a/arch/x86/include/asm/microcode.h ++++ b/arch/x86/include/asm/microcode.h @@ -12,13 +12,13 @@ struct device; enum ucode_state { UCODE_ERROR, UCODE_OK, UCODE_NFOUND }; =20 @@ -9404,9 +10468,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/m= icrocode.h linux-2.6.32.49/arch { return NULL; } -diff -urNp linux-2.6.32.49/arch/x86/include/asm/mman.h linux-2.6.32.49/a= rch/x86/include/asm/mman.h ---- linux-2.6.32.49/arch/x86/include/asm/mman.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/mman.h 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/x86/include/asm/mman.h b/arch/x86/include/asm/mman.h +index 593e51d..fa69c9a 100644 +--- a/arch/x86/include/asm/mman.h ++++ b/arch/x86/include/asm/mman.h @@ -5,4 +5,14 @@ =20 #include @@ -9422,10 +10487,41 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= mman.h linux-2.6.32.49/arch/x86/ +#endif + #endif /* _ASM_X86_MMAN_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/mmu_context.h linux-2.6.= 32.49/arch/x86/include/asm/mmu_context.h ---- linux-2.6.32.49/arch/x86/include/asm/mmu_context.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/mmu_context.h 2011-11-15 19:59:= 42.000000000 -0500 -@@ -24,6 +24,18 @@ void destroy_context(struct mm_struct *m +diff --git a/arch/x86/include/asm/mmu.h b/arch/x86/include/asm/mmu.h +index 80a1dee..239c67d 100644 +--- a/arch/x86/include/asm/mmu.h ++++ b/arch/x86/include/asm/mmu.h +@@ -9,10 +9,23 @@ + * we put the segment information here. + */ + typedef struct { +- void *ldt; ++ struct desc_struct *ldt; + int size; + struct mutex lock; +- void *vdso; ++ unsigned long vdso; ++ ++#ifdef CONFIG_X86_32 ++#if defined(CONFIG_PAX_PAGEEXEC) || defined(CONFIG_PAX_SEGMEXEC) ++ unsigned long user_cs_base; ++ unsigned long user_cs_limit; ++ ++#if defined(CONFIG_PAX_PAGEEXEC) && defined(CONFIG_SMP) ++ cpumask_t cpu_user_cs_mask; ++#endif ++ ++#endif ++#endif ++ + } mm_context_t; +=20 + #ifdef CONFIG_SMP +diff --git a/arch/x86/include/asm/mmu_context.h b/arch/x86/include/asm/m= mu_context.h +index 8b5393e..8143173 100644 +--- a/arch/x86/include/asm/mmu_context.h ++++ b/arch/x86/include/asm/mmu_context.h +@@ -24,6 +24,18 @@ void destroy_context(struct mm_struct *mm); =20 static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_str= uct *tsk) { @@ -9444,7 +10540,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/mm= u_context.h linux-2.6.32.49/ar #ifdef CONFIG_SMP if (percpu_read(cpu_tlbstate.state) =3D=3D TLBSTATE_OK) percpu_write(cpu_tlbstate.state, TLBSTATE_LAZY); -@@ -34,16 +46,30 @@ static inline void switch_mm(struct mm_s +@@ -34,16 +46,30 @@ static inline void switch_mm(struct mm_struct *prev,= struct mm_struct *next, struct task_struct *tsk) { unsigned cpu =3D smp_processor_id(); @@ -9475,7 +10571,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/mm= u_context.h linux-2.6.32.49/ar =20 /* stop flush ipis for the previous mm */ cpumask_clear_cpu(cpu, mm_cpumask(prev)); -@@ -53,9 +79,38 @@ static inline void switch_mm(struct mm_s +@@ -53,9 +79,38 @@ static inline void switch_mm(struct mm_struct *prev, = struct mm_struct *next, */ if (unlikely(prev->context.ldt !=3D next->context.ldt)) load_LDT_nolock(&next->context); @@ -9515,7 +10611,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/mm= u_context.h linux-2.6.32.49/ar percpu_write(cpu_tlbstate.state, TLBSTATE_OK); BUG_ON(percpu_read(cpu_tlbstate.active_mm) !=3D next); =20 -@@ -64,11 +119,28 @@ static inline void switch_mm(struct mm_s +@@ -64,11 +119,28 @@ static inline void switch_mm(struct mm_struct *prev= , struct mm_struct *next, * tlb flush IPI delivery. We must reload CR3 * to make sure to use no freed page tables. */ @@ -9545,38 +10641,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= mmu_context.h linux-2.6.32.49/ar } =20 #define activate_mm(prev, next) \ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/mmu.h linux-2.6.32.49/ar= ch/x86/include/asm/mmu.h ---- linux-2.6.32.49/arch/x86/include/asm/mmu.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/mmu.h 2011-11-15 19:59:42.00000= 0000 -0500 -@@ -9,10 +9,23 @@ - * we put the segment information here. - */ - typedef struct { -- void *ldt; -+ struct desc_struct *ldt; - int size; - struct mutex lock; -- void *vdso; -+ unsigned long vdso; -+ -+#ifdef CONFIG_X86_32 -+#if defined(CONFIG_PAX_PAGEEXEC) || defined(CONFIG_PAX_SEGMEXEC) -+ unsigned long user_cs_base; -+ unsigned long user_cs_limit; -+ -+#if defined(CONFIG_PAX_PAGEEXEC) && defined(CONFIG_SMP) -+ cpumask_t cpu_user_cs_mask; -+#endif -+ -+#endif -+#endif -+ - } mm_context_t; -=20 - #ifdef CONFIG_SMP -diff -urNp linux-2.6.32.49/arch/x86/include/asm/module.h linux-2.6.32.49= /arch/x86/include/asm/module.h ---- linux-2.6.32.49/arch/x86/include/asm/module.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/module.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/module.h b/arch/x86/include/asm/module= .h +index 3e2ce58..caaf478 100644 +--- a/arch/x86/include/asm/module.h ++++ b/arch/x86/include/asm/module.h @@ -5,6 +5,7 @@ =20 #ifdef CONFIG_X86_64 @@ -9585,7 +10653,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/mo= dule.h linux-2.6.32.49/arch/x8 #elif defined CONFIG_M386 #define MODULE_PROC_FAMILY "386 " #elif defined CONFIG_M486 -@@ -59,13 +60,24 @@ +@@ -59,13 +60,26 @@ #error unknown processor family #endif =20 @@ -9602,8 +10670,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/m= odule.h linux-2.6.32.49/arch/x8 +#define MODULE_STACKSIZE "" +#endif + -+#ifdef CONFIG_PAX_KERNEXEC -+#define MODULE_PAX_KERNEXEC "KERNEXEC " ++#ifdef CONFIG_PAX_KERNEXEC_PLUGIN_METHOD_BTS ++#define MODULE_PAX_KERNEXEC "KERNEXEC_BTS " ++#elif defined(CONFIG_PAX_KERNEXEC_PLUGIN_METHOD_OR) ++#define MODULE_PAX_KERNEXEC "KERNEXEC_OR " +#else +#define MODULE_PAX_KERNEXEC "" #endif @@ -9617,9 +10687,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/m= odule.h linux-2.6.32.49/arch/x8 +#define MODULE_ARCH_VERMAGIC MODULE_PROC_FAMILY MODULE_STACKSIZE MODULE= _PAX_KERNEXEC MODULE_PAX_UDEREF + #endif /* _ASM_X86_MODULE_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/page_64_types.h linux-2.= 6.32.49/arch/x86/include/asm/page_64_types.h ---- linux-2.6.32.49/arch/x86/include/asm/page_64_types.h 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/page_64_types.h 2011-11-15 19:5= 9:42.000000000 -0500 +diff --git a/arch/x86/include/asm/page_64_types.h b/arch/x86/include/asm= /page_64_types.h +index 7639dbf..e08a58c 100644 +--- a/arch/x86/include/asm/page_64_types.h ++++ b/arch/x86/include/asm/page_64_types.h @@ -56,7 +56,7 @@ void copy_page(void *to, void *from); =20 /* duplicated to the one in bootmem.h */ @@ -9629,10 +10700,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= page_64_types.h linux-2.6.32.49/ =20 extern unsigned long __phys_addr(unsigned long); #define __phys_reloc_hide(x) (x) -diff -urNp linux-2.6.32.49/arch/x86/include/asm/paravirt.h linux-2.6.32.= 49/arch/x86/include/asm/paravirt.h ---- linux-2.6.32.49/arch/x86/include/asm/paravirt.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/paravirt.h 2011-11-15 19:59:42.= 000000000 -0500 -@@ -648,6 +648,18 @@ static inline void set_pgd(pgd_t *pgdp,=20 +diff --git a/arch/x86/include/asm/paravirt.h b/arch/x86/include/asm/para= virt.h +index efb3899..ef30687 100644 +--- a/arch/x86/include/asm/paravirt.h ++++ b/arch/x86/include/asm/paravirt.h +@@ -648,6 +648,18 @@ static inline void set_pgd(pgd_t *pgdp, pgd_t pgd) val); } =20 @@ -9651,7 +10723,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/pa= ravirt.h linux-2.6.32.49/arch/ static inline void pgd_clear(pgd_t *pgdp) { set_pgd(pgdp, __pgd(0)); -@@ -729,6 +741,21 @@ static inline void __set_fixmap(unsigned +@@ -729,6 +741,21 @@ static inline void __set_fixmap(unsigned /* enum fi= xed_addresses */ idx, pv_mmu_ops.set_fixmap(idx, phys, flags); } =20 @@ -9704,9 +10776,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= aravirt.h linux-2.6.32.49/arch/ #endif /* CONFIG_X86_32 */ =20 #endif /* __ASSEMBLY__ */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/paravirt_types.h linux-2= .6.32.49/arch/x86/include/asm/paravirt_types.h ---- linux-2.6.32.49/arch/x86/include/asm/paravirt_types.h 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/paravirt_types.h 2011-11-15 19:= 59:42.000000000 -0500 +diff --git a/arch/x86/include/asm/paravirt_types.h b/arch/x86/include/as= m/paravirt_types.h +index 9357473..aeb2de5 100644 +--- a/arch/x86/include/asm/paravirt_types.h ++++ b/arch/x86/include/asm/paravirt_types.h @@ -78,19 +78,19 @@ struct pv_init_ops { */ unsigned (*patch)(u8 type, u16 clobber, void *insnbuf, @@ -9778,10 +10851,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= paravirt_types.h linux-2.6.32.49 =20 /* This contains all the paravirt structures: we get a convenient * number for each function using the offset which we use to indicate -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pci_x86.h linux-2.6.32.4= 9/arch/x86/include/asm/pci_x86.h ---- linux-2.6.32.49/arch/x86/include/asm/pci_x86.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pci_x86.h 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -89,16 +89,16 @@ extern int (*pcibios_enable_irq)(struct=20 +diff --git a/arch/x86/include/asm/pci_x86.h b/arch/x86/include/asm/pci_x= 86.h +index b399988..3f47c38 100644 +--- a/arch/x86/include/asm/pci_x86.h ++++ b/arch/x86/include/asm/pci_x86.h +@@ -89,16 +89,16 @@ extern int (*pcibios_enable_irq)(struct pci_dev *dev= ); extern void (*pcibios_disable_irq)(struct pci_dev *dev); =20 struct pci_raw_ops { @@ -9803,9 +10877,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= ci_x86.h linux-2.6.32.49/arch/x extern bool port_cf9_safe; =20 /* arch_initcall level */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/percpu.h linux-2.6.32.49= /arch/x86/include/asm/percpu.h ---- linux-2.6.32.49/arch/x86/include/asm/percpu.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/percpu.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/percpu.h b/arch/x86/include/asm/percpu= .h +index b65a36d..50345a4 100644 +--- a/arch/x86/include/asm/percpu.h ++++ b/arch/x86/include/asm/percpu.h @@ -78,6 +78,7 @@ do { \ if (0) { \ T__ tmp__; \ @@ -9814,10 +10889,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= percpu.h linux-2.6.32.49/arch/x8 } \ switch (sizeof(var)) { \ case 1: \ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgalloc.h linux-2.6.32.4= 9/arch/x86/include/asm/pgalloc.h ---- linux-2.6.32.49/arch/x86/include/asm/pgalloc.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgalloc.h 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -63,6 +63,13 @@ static inline void pmd_populate_kernel(s +diff --git a/arch/x86/include/asm/pgalloc.h b/arch/x86/include/asm/pgall= oc.h +index 271de94..ef944d6 100644 +--- a/arch/x86/include/asm/pgalloc.h ++++ b/arch/x86/include/asm/pgalloc.h +@@ -63,6 +63,13 @@ static inline void pmd_populate_kernel(struct mm_stru= ct *mm, pmd_t *pmd, pte_t *pte) { paravirt_alloc_pte(mm, __pa(pte) >> PAGE_SHIFT); @@ -9831,10 +10907,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= pgalloc.h linux-2.6.32.49/arch/x set_pmd(pmd, __pmd(__pa(pte) | _PAGE_TABLE)); } =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable-2level.h linux-2= .6.32.49/arch/x86/include/asm/pgtable-2level.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable-2level.h 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable-2level.h 2011-11-15 19:= 59:42.000000000 -0500 -@@ -18,7 +18,9 @@ static inline void native_set_pte(pte_t=20 +diff --git a/arch/x86/include/asm/pgtable-2level.h b/arch/x86/include/as= m/pgtable-2level.h +index 2334982..70bc412 100644 +--- a/arch/x86/include/asm/pgtable-2level.h ++++ b/arch/x86/include/asm/pgtable-2level.h +@@ -18,7 +18,9 @@ static inline void native_set_pte(pte_t *ptep , pte_t = pte) =20 static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) { @@ -9844,88 +10921,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= pgtable-2level.h linux-2.6.32.49 } =20 static inline void native_set_pte_atomic(pte_t *ptep, pte_t pte) -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable_32.h linux-2.6.3= 2.49/arch/x86/include/asm/pgtable_32.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable_32.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable_32.h 2011-11-15 19:59:4= 2.000000000 -0500 -@@ -26,9 +26,6 @@ - struct mm_struct; - struct vm_area_struct; -=20 --extern pgd_t swapper_pg_dir[1024]; --extern pgd_t trampoline_pg_dir[1024]; -- - static inline void pgtable_cache_init(void) { } - static inline void check_pgt_cache(void) { } - void paging_init(void); -@@ -49,6 +46,12 @@ extern void set_pmd_pfn(unsigned long, u - # include - #endif -=20 -+extern pgd_t swapper_pg_dir[PTRS_PER_PGD]; -+extern pgd_t trampoline_pg_dir[PTRS_PER_PGD]; -+#ifdef CONFIG_X86_PAE -+extern pmd_t swapper_pm_dir[PTRS_PER_PGD][PTRS_PER_PMD]; -+#endif -+ - #if defined(CONFIG_HIGHPTE) - #define __KM_PTE \ - (in_nmi() ? KM_NMI_PTE : \ -@@ -73,7 +76,9 @@ extern void set_pmd_pfn(unsigned long, u - /* Clear a kernel PTE and flush it from the TLB */ - #define kpte_clear_flush(ptep, vaddr) \ - do { \ -+ pax_open_kernel(); \ - pte_clear(&init_mm, (vaddr), (ptep)); \ -+ pax_close_kernel(); \ - __flush_tlb_one((vaddr)); \ - } while (0) -=20 -@@ -85,6 +90,9 @@ do { \ -=20 - #endif /* !__ASSEMBLY__ */ -=20 -+#define HAVE_ARCH_UNMAPPED_AREA -+#define HAVE_ARCH_UNMAPPED_AREA_TOPDOWN -+ - /* - * kern_addr_valid() is (1) for FLATMEM and (0) for - * SPARSEMEM and DISCONTIGMEM -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable_32_types.h linux= -2.6.32.49/arch/x86/include/asm/pgtable_32_types.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable_32_types.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable_32_types.h 2011-11-15 1= 9:59:42.000000000 -0500 -@@ -8,7 +8,7 @@ - */ - #ifdef CONFIG_X86_PAE - # include --# define PMD_SIZE (1UL << PMD_SHIFT) -+# define PMD_SIZE (_AC(1, UL) << PMD_SHIFT) - # define PMD_MASK (~(PMD_SIZE - 1)) - #else - # include -@@ -46,6 +46,19 @@ extern bool __vmalloc_start_set; /* set=20 - # define VMALLOC_END (FIXADDR_START - 2 * PAGE_SIZE) - #endif -=20 -+#ifdef CONFIG_PAX_KERNEXEC -+#ifndef __ASSEMBLY__ -+extern unsigned char MODULES_EXEC_VADDR[]; -+extern unsigned char MODULES_EXEC_END[]; -+#endif -+#include -+#define ktla_ktva(addr) (addr + LOAD_PHYSICAL_ADDR + PAGE_OFFSET) -+#define ktva_ktla(addr) (addr - LOAD_PHYSICAL_ADDR - PAGE_OFFSET) -+#else -+#define ktla_ktva(addr) (addr) -+#define ktva_ktla(addr) (addr) -+#endif -+ - #define MODULES_VADDR VMALLOC_START - #define MODULES_END VMALLOC_END - #define MODULES_LEN (MODULES_VADDR - MODULES_END) -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable-3level.h linux-2= .6.32.49/arch/x86/include/asm/pgtable-3level.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable-3level.h 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable-3level.h 2011-11-15 19:= 59:42.000000000 -0500 -@@ -38,12 +38,16 @@ static inline void native_set_pte_atomic +diff --git a/arch/x86/include/asm/pgtable-3level.h b/arch/x86/include/as= m/pgtable-3level.h +index 33927d2..ccde329 100644 +--- a/arch/x86/include/asm/pgtable-3level.h ++++ b/arch/x86/include/asm/pgtable-3level.h +@@ -38,12 +38,16 @@ static inline void native_set_pte_atomic(pte_t *ptep= , pte_t pte) =20 static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) { @@ -9942,66 +10942,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= pgtable-3level.h linux-2.6.32.49 } =20 /* -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable_64.h linux-2.6.3= 2.49/arch/x86/include/asm/pgtable_64.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable_64.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable_64.h 2011-11-15 19:59:4= 2.000000000 -0500 -@@ -16,10 +16,13 @@ -=20 - extern pud_t level3_kernel_pgt[512]; - extern pud_t level3_ident_pgt[512]; -+extern pud_t level3_vmalloc_pgt[512]; -+extern pud_t level3_vmemmap_pgt[512]; -+extern pud_t level2_vmemmap_pgt[512]; - extern pmd_t level2_kernel_pgt[512]; - extern pmd_t level2_fixmap_pgt[512]; --extern pmd_t level2_ident_pgt[512]; --extern pgd_t init_level4_pgt[]; -+extern pmd_t level2_ident_pgt[512*2]; -+extern pgd_t init_level4_pgt[512]; -=20 - #define swapper_pg_dir init_level4_pgt -=20 -@@ -74,7 +77,9 @@ static inline pte_t native_ptep_get_and_ -=20 - static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) - { -+ pax_open_kernel(); - *pmdp =3D pmd; -+ pax_close_kernel(); - } -=20 - static inline void native_pmd_clear(pmd_t *pmd) -@@ -94,6 +99,13 @@ static inline void native_pud_clear(pud_ -=20 - static inline void native_set_pgd(pgd_t *pgdp, pgd_t pgd) - { -+ pax_open_kernel(); -+ *pgdp =3D pgd; -+ pax_close_kernel(); -+} -+ -+static inline void native_set_pgd_batched(pgd_t *pgdp, pgd_t pgd) -+{ - *pgdp =3D pgd; - } -=20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable_64_types.h linux= -2.6.32.49/arch/x86/include/asm/pgtable_64_types.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable_64_types.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable_64_types.h 2011-11-15 1= 9:59:42.000000000 -0500 -@@ -59,5 +59,10 @@ typedef struct { pteval_t pte; } pte_t; - #define MODULES_VADDR _AC(0xffffffffa0000000, UL) - #define MODULES_END _AC(0xffffffffff000000, UL) - #define MODULES_LEN (MODULES_END - MODULES_VADDR) -+#define MODULES_EXEC_VADDR MODULES_VADDR -+#define MODULES_EXEC_END MODULES_END -+ -+#define ktla_ktva(addr) (addr) -+#define ktva_ktla(addr) (addr) -=20 - #endif /* _ASM_X86_PGTABLE_64_DEFS_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable.h linux-2.6.32.4= 9/arch/x86/include/asm/pgtable.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtab= le.h +index af6fd36..867ff74 100644 +--- a/arch/x86/include/asm/pgtable.h ++++ b/arch/x86/include/asm/pgtable.h @@ -39,6 +39,7 @@ extern struct list_head pgd_list; =20 #ifndef __PAGETABLE_PUD_FOLDED @@ -10062,7 +11006,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= gtable.h linux-2.6.32.49/arch/x static inline int pte_dirty(pte_t pte) { return pte_flags(pte) & _PAGE_DIRTY; -@@ -167,9 +207,29 @@ static inline pte_t pte_wrprotect(pte_t=20 +@@ -167,9 +207,29 @@ static inline pte_t pte_wrprotect(pte_t pte) return pte_clear_flags(pte, _PAGE_RW); } =20 @@ -10093,7 +11037,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= gtable.h linux-2.6.32.49/arch/x } =20 static inline pte_t pte_mkdirty(pte_t pte) -@@ -302,6 +362,15 @@ pte_t *populate_extra_pte(unsigned long=20 +@@ -302,6 +362,15 @@ pte_t *populate_extra_pte(unsigned long vaddr); #endif =20 #ifndef __ASSEMBLY__ @@ -10109,7 +11053,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= gtable.h linux-2.6.32.49/arch/x #include =20 static inline int pte_none(pte_t pte) -@@ -472,7 +541,7 @@ static inline pud_t *pud_offset(pgd_t *p +@@ -472,7 +541,7 @@ static inline pud_t *pud_offset(pgd_t *pgd, unsigned= long address) =20 static inline int pgd_bad(pgd_t pgd) { @@ -10153,7 +11097,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= gtable.h linux-2.6.32.49/arch/x #ifndef __ASSEMBLY__ =20 extern int direct_gbpages; -@@ -611,11 +699,23 @@ static inline void ptep_set_wrprotect(st +@@ -611,11 +699,23 @@ static inline void ptep_set_wrprotect(struct mm_st= ruct *mm, * dst and src can be on the same page, but the range must not overlap, * and must not cross a page boundary. */ @@ -10179,9 +11123,149 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /pgtable.h linux-2.6.32.49/arch/x =20 #include #endif /* __ASSEMBLY__ */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/pgtable_types.h linux-2.= 6.32.49/arch/x86/include/asm/pgtable_types.h ---- linux-2.6.32.49/arch/x86/include/asm/pgtable_types.h 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/pgtable_types.h 2011-11-15 19:5= 9:42.000000000 -0500 +diff --git a/arch/x86/include/asm/pgtable_32.h b/arch/x86/include/asm/pg= table_32.h +index 750f1bf..971e839 100644 +--- a/arch/x86/include/asm/pgtable_32.h ++++ b/arch/x86/include/asm/pgtable_32.h +@@ -26,9 +26,6 @@ + struct mm_struct; + struct vm_area_struct; +=20 +-extern pgd_t swapper_pg_dir[1024]; +-extern pgd_t trampoline_pg_dir[1024]; +- + static inline void pgtable_cache_init(void) { } + static inline void check_pgt_cache(void) { } + void paging_init(void); +@@ -49,6 +46,12 @@ extern void set_pmd_pfn(unsigned long, unsigned long,= pgprot_t); + # include + #endif +=20 ++extern pgd_t swapper_pg_dir[PTRS_PER_PGD]; ++extern pgd_t trampoline_pg_dir[PTRS_PER_PGD]; ++#ifdef CONFIG_X86_PAE ++extern pmd_t swapper_pm_dir[PTRS_PER_PGD][PTRS_PER_PMD]; ++#endif ++ + #if defined(CONFIG_HIGHPTE) + #define __KM_PTE \ + (in_nmi() ? KM_NMI_PTE : \ +@@ -73,7 +76,9 @@ extern void set_pmd_pfn(unsigned long, unsigned long, = pgprot_t); + /* Clear a kernel PTE and flush it from the TLB */ + #define kpte_clear_flush(ptep, vaddr) \ + do { \ ++ pax_open_kernel(); \ + pte_clear(&init_mm, (vaddr), (ptep)); \ ++ pax_close_kernel(); \ + __flush_tlb_one((vaddr)); \ + } while (0) +=20 +@@ -85,6 +90,9 @@ do { \ +=20 + #endif /* !__ASSEMBLY__ */ +=20 ++#define HAVE_ARCH_UNMAPPED_AREA ++#define HAVE_ARCH_UNMAPPED_AREA_TOPDOWN ++ + /* + * kern_addr_valid() is (1) for FLATMEM and (0) for + * SPARSEMEM and DISCONTIGMEM +diff --git a/arch/x86/include/asm/pgtable_32_types.h b/arch/x86/include/= asm/pgtable_32_types.h +index 5e67c15..12d5c47 100644 +--- a/arch/x86/include/asm/pgtable_32_types.h ++++ b/arch/x86/include/asm/pgtable_32_types.h +@@ -8,7 +8,7 @@ + */ + #ifdef CONFIG_X86_PAE + # include +-# define PMD_SIZE (1UL << PMD_SHIFT) ++# define PMD_SIZE (_AC(1, UL) << PMD_SHIFT) + # define PMD_MASK (~(PMD_SIZE - 1)) + #else + # include +@@ -46,6 +46,19 @@ extern bool __vmalloc_start_set; /* set once high_mem= ory is set */ + # define VMALLOC_END (FIXADDR_START - 2 * PAGE_SIZE) + #endif +=20 ++#ifdef CONFIG_PAX_KERNEXEC ++#ifndef __ASSEMBLY__ ++extern unsigned char MODULES_EXEC_VADDR[]; ++extern unsigned char MODULES_EXEC_END[]; ++#endif ++#include ++#define ktla_ktva(addr) (addr + LOAD_PHYSICAL_ADDR + PAGE_OFFSET) ++#define ktva_ktla(addr) (addr - LOAD_PHYSICAL_ADDR - PAGE_OFFSET) ++#else ++#define ktla_ktva(addr) (addr) ++#define ktva_ktla(addr) (addr) ++#endif ++ + #define MODULES_VADDR VMALLOC_START + #define MODULES_END VMALLOC_END + #define MODULES_LEN (MODULES_VADDR - MODULES_END) +diff --git a/arch/x86/include/asm/pgtable_64.h b/arch/x86/include/asm/pg= table_64.h +index c57a301..312bdb4 100644 +--- a/arch/x86/include/asm/pgtable_64.h ++++ b/arch/x86/include/asm/pgtable_64.h +@@ -16,10 +16,13 @@ +=20 + extern pud_t level3_kernel_pgt[512]; + extern pud_t level3_ident_pgt[512]; ++extern pud_t level3_vmalloc_pgt[512]; ++extern pud_t level3_vmemmap_pgt[512]; ++extern pud_t level2_vmemmap_pgt[512]; + extern pmd_t level2_kernel_pgt[512]; + extern pmd_t level2_fixmap_pgt[512]; +-extern pmd_t level2_ident_pgt[512]; +-extern pgd_t init_level4_pgt[]; ++extern pmd_t level2_ident_pgt[512*2]; ++extern pgd_t init_level4_pgt[512]; +=20 + #define swapper_pg_dir init_level4_pgt +=20 +@@ -74,7 +77,9 @@ static inline pte_t native_ptep_get_and_clear(pte_t *x= p) +=20 + static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) + { ++ pax_open_kernel(); + *pmdp =3D pmd; ++ pax_close_kernel(); + } +=20 + static inline void native_pmd_clear(pmd_t *pmd) +@@ -94,6 +99,13 @@ static inline void native_pud_clear(pud_t *pud) +=20 + static inline void native_set_pgd(pgd_t *pgdp, pgd_t pgd) + { ++ pax_open_kernel(); ++ *pgdp =3D pgd; ++ pax_close_kernel(); ++} ++ ++static inline void native_set_pgd_batched(pgd_t *pgdp, pgd_t pgd) ++{ + *pgdp =3D pgd; + } +=20 +diff --git a/arch/x86/include/asm/pgtable_64_types.h b/arch/x86/include/= asm/pgtable_64_types.h +index 766ea16..5b96cb3 100644 +--- a/arch/x86/include/asm/pgtable_64_types.h ++++ b/arch/x86/include/asm/pgtable_64_types.h +@@ -59,5 +59,10 @@ typedef struct { pteval_t pte; } pte_t; + #define MODULES_VADDR _AC(0xffffffffa0000000, UL) + #define MODULES_END _AC(0xffffffffff000000, UL) + #define MODULES_LEN (MODULES_END - MODULES_VADDR) ++#define MODULES_EXEC_VADDR MODULES_VADDR ++#define MODULES_EXEC_END MODULES_END ++ ++#define ktla_ktva(addr) (addr) ++#define ktva_ktla(addr) (addr) +=20 + #endif /* _ASM_X86_PGTABLE_64_DEFS_H */ +diff --git a/arch/x86/include/asm/pgtable_types.h b/arch/x86/include/asm= /pgtable_types.h +index d1f4a76..2f46ba1 100644 +--- a/arch/x86/include/asm/pgtable_types.h ++++ b/arch/x86/include/asm/pgtable_types.h @@ -16,12 +16,11 @@ #define _PAGE_BIT_PSE 7 /* 4 MB (or 2MB) page */ #define _PAGE_BIT_PAT 7 /* on 4KB pages */ @@ -10249,7 +11333,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= gtable_types.h linux-2.6.32.49/ #define PGD_IDENT_ATTR 0x001 /* PRESENT (no other attributes) */ #endif =20 -@@ -202,7 +205,17 @@ static inline pgdval_t pgd_flags(pgd_t p +@@ -202,7 +205,17 @@ static inline pgdval_t pgd_flags(pgd_t pgd) { return native_pgd_val(pgd) & PTE_FLAGS_MASK; } @@ -10267,7 +11351,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= gtable_types.h linux-2.6.32.49/ #if PAGETABLE_LEVELS > 3 typedef struct { pudval_t pud; } pud_t; =20 -@@ -216,8 +229,6 @@ static inline pudval_t native_pud_val(pu +@@ -216,8 +229,6 @@ static inline pudval_t native_pud_val(pud_t pud) return pud.pud; } #else @@ -10276,7 +11360,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= gtable_types.h linux-2.6.32.49/ static inline pudval_t native_pud_val(pud_t pud) { return native_pgd_val(pud.pgd); -@@ -237,8 +248,6 @@ static inline pmdval_t native_pmd_val(pm +@@ -237,8 +248,6 @@ static inline pmdval_t native_pmd_val(pmd_t pmd) return pmd.pmd; } #else @@ -10302,9 +11386,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= pgtable_types.h linux-2.6.32.49/ =20 #define pgprot_writecombine pgprot_writecombine extern pgprot_t pgprot_writecombine(pgprot_t prot); -diff -urNp linux-2.6.32.49/arch/x86/include/asm/processor.h linux-2.6.32= .49/arch/x86/include/asm/processor.h ---- linux-2.6.32.49/arch/x86/include/asm/processor.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/processor.h 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/pro= cessor.h +index fa04dea..5f823fc 100644 +--- a/arch/x86/include/asm/processor.h ++++ b/arch/x86/include/asm/processor.h @@ -272,7 +272,7 @@ struct tss_struct { =20 } ____cacheline_aligned; @@ -10314,7 +11399,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= rocessor.h linux-2.6.32.49/arch =20 /* * Save the original ist values for checking stack pointers during debu= gging -@@ -911,11 +911,18 @@ static inline void spin_lock_prefetch(co +@@ -911,11 +911,18 @@ static inline void spin_lock_prefetch(const void *= x) */ #define TASK_SIZE PAGE_OFFSET #define TASK_SIZE_MAX TASK_SIZE @@ -10335,7 +11420,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= rocessor.h linux-2.6.32.49/arch .vm86_info =3D NULL, \ .sysenter_cs =3D __KERNEL_CS, \ .io_bitmap_ptr =3D NULL, \ -@@ -929,7 +936,7 @@ static inline void spin_lock_prefetch(co +@@ -929,7 +936,7 @@ static inline void spin_lock_prefetch(const void *x) */ #define INIT_TSS { \ .x86_tss =3D { \ @@ -10344,7 +11429,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= rocessor.h linux-2.6.32.49/arch .ss0 =3D __KERNEL_DS, \ .ss1 =3D __KERNEL_CS, \ .io_bitmap_base =3D INVALID_IO_BITMAP_OFFSET, \ -@@ -940,11 +947,7 @@ static inline void spin_lock_prefetch(co +@@ -940,11 +947,7 @@ static inline void spin_lock_prefetch(const void *x= ) extern unsigned long thread_saved_pc(struct task_struct *tsk); =20 #define THREAD_SIZE_LONGS (THREAD_SIZE/sizeof(unsigned long)) @@ -10357,7 +11442,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= rocessor.h linux-2.6.32.49/arch =20 /* * The below -8 is to reserve 8 bytes on top of the ring0 stack. -@@ -959,7 +962,7 @@ extern unsigned long thread_saved_pc(str +@@ -959,7 +962,7 @@ extern unsigned long thread_saved_pc(struct task_str= uct *tsk); #define task_pt_regs(task) = \ ({ = \ struct pt_regs *__regs__; = \ @@ -10366,7 +11451,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= rocessor.h linux-2.6.32.49/arch __regs__ - 1; = \ }) =20 -@@ -969,13 +972,13 @@ extern unsigned long thread_saved_pc(str +@@ -969,13 +972,13 @@ extern unsigned long thread_saved_pc(struct task_s= truct *tsk); /* * User space process size. 47bits minus one guard page. */ @@ -10382,7 +11467,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= rocessor.h linux-2.6.32.49/arch =20 #define TASK_SIZE (test_thread_flag(TIF_IA32) ? \ IA32_PAGE_OFFSET : TASK_SIZE_MAX) -@@ -986,11 +989,11 @@ extern unsigned long thread_saved_pc(str +@@ -986,11 +989,11 @@ extern unsigned long thread_saved_pc(struct task_s= truct *tsk); #define STACK_TOP_MAX TASK_SIZE_MAX =20 #define INIT_THREAD { \ @@ -10396,7 +11481,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/p= rocessor.h linux-2.6.32.49/arch } =20 /* -@@ -1012,6 +1015,10 @@ extern void start_thread(struct pt_regs=20 +@@ -1012,6 +1015,10 @@ extern void start_thread(struct pt_regs *regs, un= signed long new_ip, */ #define TASK_UNMAPPED_BASE (PAGE_ALIGN(TASK_SIZE / 3)) =20 @@ -10407,10 +11492,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /processor.h linux-2.6.32.49/arch #define KSTK_EIP(task) (task_pt_regs(task)->ip) =20 /* Get/set a process' ability to use the timestamp counter instruction = */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/ptrace.h linux-2.6.32.49= /arch/x86/include/asm/ptrace.h ---- linux-2.6.32.49/arch/x86/include/asm/ptrace.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/ptrace.h 2011-11-15 19:59:42.00= 0000000 -0500 -@@ -151,28 +151,29 @@ static inline unsigned long regs_return_ +diff --git a/arch/x86/include/asm/ptrace.h b/arch/x86/include/asm/ptrace= .h +index 0f0d908..f2e3da2 100644 +--- a/arch/x86/include/asm/ptrace.h ++++ b/arch/x86/include/asm/ptrace.h +@@ -151,28 +151,29 @@ static inline unsigned long regs_return_value(stru= ct pt_regs *regs) } =20 /* @@ -10446,9 +11532,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= ptrace.h linux-2.6.32.49/arch/x8 #endif } =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/reboot.h linux-2.6.32.49= /arch/x86/include/asm/reboot.h ---- linux-2.6.32.49/arch/x86/include/asm/reboot.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/reboot.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/reboot.h b/arch/x86/include/asm/reboot= .h +index 562d4fd..6e39df1 100644 +--- a/arch/x86/include/asm/reboot.h ++++ b/arch/x86/include/asm/reboot.h @@ -6,19 +6,19 @@ struct pt_regs; =20 @@ -10475,10 +11562,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /reboot.h linux-2.6.32.49/arch/x8 =20 typedef void (*nmi_shootdown_cb)(int, struct die_args*); void nmi_shootdown_cpus(nmi_shootdown_cb callback); -diff -urNp linux-2.6.32.49/arch/x86/include/asm/rwsem.h linux-2.6.32.49/= arch/x86/include/asm/rwsem.h ---- linux-2.6.32.49/arch/x86/include/asm/rwsem.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/rwsem.h 2011-11-15 19:59:42.000= 000000 -0500 -@@ -118,6 +118,14 @@ static inline void __down_read(struct rw +diff --git a/arch/x86/include/asm/rwsem.h b/arch/x86/include/asm/rwsem.h +index 606ede1..dbfff37 100644 +--- a/arch/x86/include/asm/rwsem.h ++++ b/arch/x86/include/asm/rwsem.h +@@ -118,6 +118,14 @@ static inline void __down_read(struct rw_semaphore = *sem) { asm volatile("# beginning down_read\n\t" LOCK_PREFIX _ASM_INC "(%1)\n\t" @@ -10493,7 +11581,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/r= wsem.h linux-2.6.32.49/arch/x86 /* adds 0x00000001, returns the old value */ " jns 1f\n" " call call_rwsem_down_read_failed\n" -@@ -139,6 +147,14 @@ static inline int __down_read_trylock(st +@@ -139,6 +147,14 @@ static inline int __down_read_trylock(struct rw_sem= aphore *sem) "1:\n\t" " mov %1,%2\n\t" " add %3,%2\n\t" @@ -10508,7 +11596,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/r= wsem.h linux-2.6.32.49/arch/x86 " jle 2f\n\t" LOCK_PREFIX " cmpxchg %2,%0\n\t" " jnz 1b\n\t" -@@ -160,6 +176,14 @@ static inline void __down_write_nested(s +@@ -160,6 +176,14 @@ static inline void __down_write_nested(struct rw_se= maphore *sem, int subclass) tmp =3D RWSEM_ACTIVE_WRITE_BIAS; asm volatile("# beginning down_write\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -10523,7 +11611,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/r= wsem.h linux-2.6.32.49/arch/x86 /* subtract 0x0000ffff, returns the old value */ " test %1,%1\n\t" /* was the count 0 before? */ -@@ -198,6 +222,14 @@ static inline void __up_read(struct rw_s +@@ -198,6 +222,14 @@ static inline void __up_read(struct rw_semaphore *s= em) rwsem_count_t tmp =3D -RWSEM_ACTIVE_READ_BIAS; asm volatile("# beginning __up_read\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -10538,7 +11626,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/r= wsem.h linux-2.6.32.49/arch/x86 /* subtracts 1, returns the old value */ " jns 1f\n\t" " call call_rwsem_wake\n" -@@ -216,6 +248,14 @@ static inline void __up_write(struct rw_ +@@ -216,6 +248,14 @@ static inline void __up_write(struct rw_semaphore *= sem) rwsem_count_t tmp; asm volatile("# beginning __up_write\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -10553,7 +11641,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/r= wsem.h linux-2.6.32.49/arch/x86 /* tries to transition 0xffff0001 -> 0x00000000 */ " jz 1f\n" -@@ -234,6 +274,14 @@ static inline void __downgrade_write(str +@@ -234,6 +274,14 @@ static inline void __downgrade_write(struct rw_sema= phore *sem) { asm volatile("# beginning __downgrade_write\n\t" LOCK_PREFIX _ASM_ADD "%2,(%1)\n\t" @@ -10568,7 +11656,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/r= wsem.h linux-2.6.32.49/arch/x86 /* * transitions 0xZZZZ0001 -> 0xYYYY0001 (i386) * 0xZZZZZZZZ00000001 -> 0xYYYYYYYY00000001 (x86_64) -@@ -253,7 +301,15 @@ static inline void __downgrade_write(str +@@ -253,7 +301,15 @@ static inline void __downgrade_write(struct rw_sema= phore *sem) static inline void rwsem_atomic_add(rwsem_count_t delta, struct rw_semaphore *sem) { @@ -10585,7 +11673,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/r= wsem.h linux-2.6.32.49/arch/x86 : "+m" (sem->count) : "er" (delta)); } -@@ -266,7 +322,15 @@ static inline rwsem_count_t rwsem_atomic +@@ -266,7 +322,15 @@ static inline rwsem_count_t rwsem_atomic_update(rws= em_count_t delta, { rwsem_count_t tmp =3D delta; =20 @@ -10602,9 +11690,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= rwsem.h linux-2.6.32.49/arch/x86 : "+r" (tmp), "+m" (sem->count) : : "memory"); =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/segment.h linux-2.6.32.4= 9/arch/x86/include/asm/segment.h ---- linux-2.6.32.49/arch/x86/include/asm/segment.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/segment.h 2011-11-15 19:59:42.0= 00000000 -0500 +diff --git a/arch/x86/include/asm/segment.h b/arch/x86/include/asm/segme= nt.h +index 14e0ed8..7f7dd5e 100644 +--- a/arch/x86/include/asm/segment.h ++++ b/arch/x86/include/asm/segment.h @@ -62,10 +62,15 @@ * 26 - ESPFIX small SS * 27 - per-cpu [ offset to per-cpu data area ] @@ -10680,9 +11769,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= segment.h linux-2.6.32.49/arch/x #define __KERNEL_DS (GDT_ENTRY_KERNEL_DS * 8) #define __USER_DS (GDT_ENTRY_DEFAULT_USER_DS* 8 + 3) #define __USER_CS (GDT_ENTRY_DEFAULT_USER_CS* 8 + 3) -diff -urNp linux-2.6.32.49/arch/x86/include/asm/smp.h linux-2.6.32.49/ar= ch/x86/include/asm/smp.h ---- linux-2.6.32.49/arch/x86/include/asm/smp.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/smp.h 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/x86/include/asm/smp.h b/arch/x86/include/asm/smp.h +index 4c2f63c..5685db2 100644 +--- a/arch/x86/include/asm/smp.h ++++ b/arch/x86/include/asm/smp.h @@ -24,7 +24,7 @@ extern unsigned int num_processors; DECLARE_PER_CPU(cpumask_var_t, cpu_sibling_map); DECLARE_PER_CPU(cpumask_var_t, cpu_core_map); @@ -10692,7 +11782,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/s= mp.h linux-2.6.32.49/arch/x86/i =20 static inline struct cpumask *cpu_sibling_mask(int cpu) { -@@ -40,10 +40,7 @@ DECLARE_EARLY_PER_CPU(u16, x86_cpu_to_ap +@@ -40,10 +40,7 @@ DECLARE_EARLY_PER_CPU(u16, x86_cpu_to_apicid); DECLARE_EARLY_PER_CPU(u16, x86_bios_cpu_apicid); =20 /* Static state in head.S used to set up a CPU */ @@ -10713,7 +11803,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/s= mp.h linux-2.6.32.49/arch/x86/i =20 /* Globals due to paravirt */ extern void set_cpu_sibling_map(int cpu); -@@ -175,14 +172,8 @@ extern unsigned disabled_cpus __cpuinitd +@@ -175,14 +172,8 @@ extern unsigned disabled_cpus __cpuinitdata; extern int safe_smp_processor_id(void); =20 #elif defined(CONFIG_X86_64_SMP) @@ -10730,10 +11820,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /smp.h linux-2.6.32.49/arch/x86/i #define safe_smp_processor_id() smp_processor_id() =20 #endif -diff -urNp linux-2.6.32.49/arch/x86/include/asm/spinlock.h linux-2.6.32.= 49/arch/x86/include/asm/spinlock.h ---- linux-2.6.32.49/arch/x86/include/asm/spinlock.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/spinlock.h 2011-11-15 19:59:42.= 000000000 -0500 -@@ -249,6 +249,14 @@ static inline int __raw_write_can_lock(r +diff --git a/arch/x86/include/asm/spinlock.h b/arch/x86/include/asm/spin= lock.h +index 4e77853..4359783 100644 +--- a/arch/x86/include/asm/spinlock.h ++++ b/arch/x86/include/asm/spinlock.h +@@ -249,6 +249,14 @@ static inline int __raw_write_can_lock(raw_rwlock_t= *lock) static inline void __raw_read_lock(raw_rwlock_t *rw) { asm volatile(LOCK_PREFIX " subl $1,(%0)\n\t" @@ -10748,7 +11839,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/s= pinlock.h linux-2.6.32.49/arch/ "jns 1f\n" "call __read_lock_failed\n\t" "1:\n" -@@ -258,6 +266,14 @@ static inline void __raw_read_lock(raw_r +@@ -258,6 +266,14 @@ static inline void __raw_read_lock(raw_rwlock_t *rw= ) static inline void __raw_write_lock(raw_rwlock_t *rw) { asm volatile(LOCK_PREFIX " subl %1,(%0)\n\t" @@ -10763,7 +11854,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/s= pinlock.h linux-2.6.32.49/arch/ "jz 1f\n" "call __write_lock_failed\n\t" "1:\n" -@@ -286,12 +302,29 @@ static inline int __raw_write_trylock(ra +@@ -286,12 +302,29 @@ static inline int __raw_write_trylock(raw_rwlock_t= *lock) =20 static inline void __raw_read_unlock(raw_rwlock_t *rw) { @@ -10795,9 +11886,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= spinlock.h linux-2.6.32.49/arch/ : "+m" (rw->lock) : "i" (RW_LOCK_BIAS) : "memory"); } =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/stackprotector.h linux-2= .6.32.49/arch/x86/include/asm/stackprotector.h ---- linux-2.6.32.49/arch/x86/include/asm/stackprotector.h 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/stackprotector.h 2011-11-15 19:= 59:42.000000000 -0500 +diff --git a/arch/x86/include/asm/stackprotector.h b/arch/x86/include/as= m/stackprotector.h +index 1575177..cb23f52 100644 +--- a/arch/x86/include/asm/stackprotector.h ++++ b/arch/x86/include/asm/stackprotector.h @@ -48,7 +48,7 @@ * head_32 for boot CPU and setup_per_cpu_areas() for others. */ @@ -10807,7 +11899,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/s= tackprotector.h linux-2.6.32.49 =20 /* * Initialize the stackprotector canary value. -@@ -113,7 +113,7 @@ static inline void setup_stack_canary_se +@@ -113,7 +113,7 @@ static inline void setup_stack_canary_segment(int cp= u) =20 static inline void load_stack_canary_segment(void) { @@ -10816,9 +11908,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= stackprotector.h linux-2.6.32.49 asm volatile ("mov %0, %%gs" : : "r" (0)); #endif } -diff -urNp linux-2.6.32.49/arch/x86/include/asm/system.h linux-2.6.32.49= /arch/x86/include/asm/system.h ---- linux-2.6.32.49/arch/x86/include/asm/system.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/system.h 2011-11-15 19:59:42.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/system.h b/arch/x86/include/asm/system= .h +index e0fbf29..858ef4a 100644 +--- a/arch/x86/include/asm/system.h ++++ b/arch/x86/include/asm/system.h @@ -132,7 +132,7 @@ do { \ "thread_return:\n\t" \ "movq "__percpu_arg([current_task])",%%rsi\n\t" \ @@ -10837,7 +11930,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/s= ystem.h linux-2.6.32.49/arch/x8 [current_task] "m" (per_cpu_var(current_task)) \ __switch_canary_iparam \ : "memory", "cc" __EXTRA_CLOBBER) -@@ -200,7 +200,7 @@ static inline unsigned long get_limit(un +@@ -200,7 +200,7 @@ static inline unsigned long get_limit(unsigned long = segment) { unsigned long __limit; asm("lsll %1,%0" : "=3Dr" (__limit) : "r" (segment)); @@ -10861,9 +11954,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= system.h linux-2.6.32.49/arch/x8 =20 /* * Force strict CPU ordering. -diff -urNp linux-2.6.32.49/arch/x86/include/asm/thread_info.h linux-2.6.= 32.49/arch/x86/include/asm/thread_info.h ---- linux-2.6.32.49/arch/x86/include/asm/thread_info.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/thread_info.h 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/x86/include/asm/thread_info.h b/arch/x86/include/asm/t= hread_info.h +index 19c3ce4..8962535 100644 +--- a/arch/x86/include/asm/thread_info.h ++++ b/arch/x86/include/asm/thread_info.h @@ -10,6 +10,7 @@ #include #include @@ -10970,7 +12064,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/t= hread_info.h linux-2.6.32.49/ar /* * macros/functions for gaining access to the thread information struct= ure * preempt_count needs to be 1 initially, until the scheduler is functi= onal. -@@ -209,21 +198,8 @@ static inline struct thread_info *curren +@@ -209,21 +198,8 @@ static inline struct thread_info *current_thread_in= fo(void) #ifndef __ASSEMBLY__ DECLARE_PER_CPU(unsigned long, kernel_stack); =20 @@ -11011,10 +12105,242 @@ diff -urNp linux-2.6.32.49/arch/x86/include/as= m/thread_info.h linux-2.6.32.49/ar + #endif #endif /* _ASM_X86_THREAD_INFO_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/uaccess_32.h linux-2.6.3= 2.49/arch/x86/include/asm/uaccess_32.h ---- linux-2.6.32.49/arch/x86/include/asm/uaccess_32.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/uaccess_32.h 2011-11-15 19:59:4= 2.000000000 -0500 -@@ -44,6 +44,11 @@ unsigned long __must_check __copy_from_u +diff --git a/arch/x86/include/asm/uaccess.h b/arch/x86/include/asm/uacce= ss.h +index 61c5874..8a046e9 100644 +--- a/arch/x86/include/asm/uaccess.h ++++ b/arch/x86/include/asm/uaccess.h +@@ -8,12 +8,15 @@ + #include + #include + #include ++#include + #include + #include +=20 + #define VERIFY_READ 0 + #define VERIFY_WRITE 1 +=20 ++extern void check_object_size(const void *ptr, unsigned long n, bool to= ); ++ + /* + * The fs value determines whether argument validity checking should be + * performed or not. If get_fs() =3D=3D USER_DS, checking is performed= , with +@@ -29,7 +32,12 @@ +=20 + #define get_ds() (KERNEL_DS) + #define get_fs() (current_thread_info()->addr_limit) ++#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) ++void __set_fs(mm_segment_t x); ++void set_fs(mm_segment_t x); ++#else + #define set_fs(x) (current_thread_info()->addr_limit =3D (x)) ++#endif +=20 + #define segment_eq(a, b) ((a).seg =3D=3D (b).seg) +=20 +@@ -77,7 +85,33 @@ + * checks that the pointer is in the user space range - after calling + * this function, memory access functions may still return -EFAULT. + */ +-#define access_ok(type, addr, size) (likely(__range_not_ok(addr, size) = =3D=3D 0)) ++#define __access_ok(type, addr, size) (likely(__range_not_ok(addr, size= ) =3D=3D 0)) ++#define access_ok(type, addr, size) \ ++({ \ ++ long __size =3D size; \ ++ unsigned long __addr =3D (unsigned long)addr; \ ++ unsigned long __addr_ao =3D __addr & PAGE_MASK; \ ++ unsigned long __end_ao =3D __addr + __size - 1; \ ++ bool __ret_ao =3D __range_not_ok(__addr, __size) =3D=3D 0; \ ++ if (__ret_ao && unlikely((__end_ao ^ __addr_ao) & PAGE_MASK)) { \ ++ while(__addr_ao <=3D __end_ao) { \ ++ char __c_ao; \ ++ __addr_ao +=3D PAGE_SIZE; \ ++ if (__size > PAGE_SIZE) \ ++ cond_resched(); \ ++ if (__get_user(__c_ao, (char __user *)__addr)) \ ++ break; \ ++ if (type !=3D VERIFY_WRITE) { \ ++ __addr =3D __addr_ao; \ ++ continue; \ ++ } \ ++ if (__put_user(__c_ao, (char __user *)__addr)) \ ++ break; \ ++ __addr =3D __addr_ao; \ ++ } \ ++ } \ ++ __ret_ao; \ ++}) +=20 + /* + * The exception table consists of pairs of addresses: the first is the +@@ -183,12 +217,20 @@ extern int __get_user_bad(void); + asm volatile("call __put_user_" #size : "=3Da" (__ret_pu) \ + : "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx") +=20 +- ++#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define __copyuser_seg "gs;" ++#define __COPYUSER_SET_ES "pushl %%gs; popl %%es\n" ++#define __COPYUSER_RESTORE_ES "pushl %%ss; popl %%es\n" ++#else ++#define __copyuser_seg ++#define __COPYUSER_SET_ES ++#define __COPYUSER_RESTORE_ES ++#endif +=20 + #ifdef CONFIG_X86_32 + #define __put_user_asm_u64(x, addr, err, errret) \ +- asm volatile("1: movl %%eax,0(%2)\n" \ +- "2: movl %%edx,4(%2)\n" \ ++ asm volatile("1: "__copyuser_seg"movl %%eax,0(%2)\n" \ ++ "2: "__copyuser_seg"movl %%edx,4(%2)\n" \ + "3:\n" \ + ".section .fixup,\"ax\"\n" \ + "4: movl %3,%0\n" \ +@@ -200,8 +242,8 @@ extern int __get_user_bad(void); + : "A" (x), "r" (addr), "i" (errret), "0" (err)) +=20 + #define __put_user_asm_ex_u64(x, addr) \ +- asm volatile("1: movl %%eax,0(%1)\n" \ +- "2: movl %%edx,4(%1)\n" \ ++ asm volatile("1: "__copyuser_seg"movl %%eax,0(%1)\n" \ ++ "2: "__copyuser_seg"movl %%edx,4(%1)\n" \ + "3:\n" \ + _ASM_EXTABLE(1b, 2b - 1b) \ + _ASM_EXTABLE(2b, 3b - 2b) \ +@@ -253,7 +295,7 @@ extern void __put_user_8(void); + __typeof__(*(ptr)) __pu_val; \ + __chk_user_ptr(ptr); \ + might_fault(); \ +- __pu_val =3D x; \ ++ __pu_val =3D (x); \ + switch (sizeof(*(ptr))) { \ + case 1: \ + __put_user_x(1, __pu_val, ptr, __ret_pu); \ +@@ -374,7 +416,7 @@ do { \ + } while (0) +=20 + #define __get_user_asm(x, addr, err, itype, rtype, ltype, errret) \ +- asm volatile("1: mov"itype" %2,%"rtype"1\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %2,%"rtype"1\n"\ + "2:\n" \ + ".section .fixup,\"ax\"\n" \ + "3: mov %3,%0\n" \ +@@ -382,7 +424,7 @@ do { \ + " jmp 2b\n" \ + ".previous\n" \ + _ASM_EXTABLE(1b, 3b) \ +- : "=3Dr" (err), ltype(x) \ ++ : "=3Dr" (err), ltype (x) \ + : "m" (__m(addr)), "i" (errret), "0" (err)) +=20 + #define __get_user_size_ex(x, ptr, size) \ +@@ -407,7 +449,7 @@ do { \ + } while (0) +=20 + #define __get_user_asm_ex(x, addr, itype, rtype, ltype) \ +- asm volatile("1: mov"itype" %1,%"rtype"0\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %1,%"rtype"0\n"\ + "2:\n" \ + _ASM_EXTABLE(1b, 2b - 1b) \ + : ltype(x) : "m" (__m(addr))) +@@ -424,13 +466,24 @@ do { \ + int __gu_err; \ + unsigned long __gu_val; \ + __get_user_size(__gu_val, (ptr), (size), __gu_err, -EFAULT); \ +- (x) =3D (__force __typeof__(*(ptr)))__gu_val; \ ++ (x) =3D (__typeof__(*(ptr)))__gu_val; \ + __gu_err; \ + }) +=20 + /* FIXME: this hack is definitely wrong -AK */ + struct __large_struct { unsigned long buf[100]; }; +-#define __m(x) (*(struct __large_struct __user *)(x)) ++#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define ____m(x) \ ++({ \ ++ unsigned long ____x =3D (unsigned long)(x); \ ++ if (____x < PAX_USER_SHADOW_BASE) \ ++ ____x +=3D PAX_USER_SHADOW_BASE; \ ++ (void __user *)____x; \ ++}) ++#else ++#define ____m(x) (x) ++#endif ++#define __m(x) (*(struct __large_struct __user *)____m(x)) +=20 + /* + * Tell gcc we read from memory instead of writing: this is because +@@ -438,7 +491,7 @@ struct __large_struct { unsigned long buf[100]; }; + * aliasing issues. + */ + #define __put_user_asm(x, addr, err, itype, rtype, ltype, errret) \ +- asm volatile("1: mov"itype" %"rtype"1,%2\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"1,%2\n"\ + "2:\n" \ + ".section .fixup,\"ax\"\n" \ + "3: mov %3,%0\n" \ +@@ -446,10 +499,10 @@ struct __large_struct { unsigned long buf[100]; }; + ".previous\n" \ + _ASM_EXTABLE(1b, 3b) \ + : "=3Dr"(err) \ +- : ltype(x), "m" (__m(addr)), "i" (errret), "0" (err)) ++ : ltype (x), "m" (__m(addr)), "i" (errret), "0" (err)) +=20 + #define __put_user_asm_ex(x, addr, itype, rtype, ltype) \ +- asm volatile("1: mov"itype" %"rtype"0,%1\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"0,%1\n"\ + "2:\n" \ + _ASM_EXTABLE(1b, 2b - 1b) \ + : : ltype(x), "m" (__m(addr))) +@@ -488,8 +541,12 @@ struct __large_struct { unsigned long buf[100]; }; + * On error, the variable @x is set to zero. + */ +=20 ++#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define __get_user(x, ptr) get_user((x), (ptr)) ++#else + #define __get_user(x, ptr) \ + __get_user_nocheck((x), (ptr), sizeof(*(ptr))) ++#endif +=20 + /** + * __put_user: - Write a simple value into user space, with less checki= ng. +@@ -511,8 +568,12 @@ struct __large_struct { unsigned long buf[100]; }; + * Returns zero on success, or -EFAULT on error. + */ +=20 ++#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define __put_user(x, ptr) put_user((x), (ptr)) ++#else + #define __put_user(x, ptr) \ + __put_user_nocheck((__typeof__(*(ptr)))(x), (ptr), sizeof(*(ptr))) ++#endif +=20 + #define __get_user_unaligned __get_user + #define __put_user_unaligned __put_user +@@ -530,7 +591,7 @@ struct __large_struct { unsigned long buf[100]; }; + #define get_user_ex(x, ptr) do { \ + unsigned long __gue_val; \ + __get_user_size_ex((__gue_val), (ptr), (sizeof(*(ptr)))); \ +- (x) =3D (__force __typeof__(*(ptr)))__gue_val; \ ++ (x) =3D (__typeof__(*(ptr)))__gue_val; \ + } while (0) +=20 + #ifdef CONFIG_X86_WP_WORKS_OK +@@ -567,6 +628,7 @@ extern struct movsl_mask { +=20 + #define ARCH_HAS_NOCACHE_UACCESS 1 +=20 ++#define ARCH_HAS_SORT_EXTABLE + #ifdef CONFIG_X86_32 + # include "uaccess_32.h" + #else +diff --git a/arch/x86/include/asm/uaccess_32.h b/arch/x86/include/asm/ua= ccess_32.h +index 632fb44..e30e334 100644 +--- a/arch/x86/include/asm/uaccess_32.h ++++ b/arch/x86/include/asm/uaccess_32.h +@@ -44,6 +44,11 @@ unsigned long __must_check __copy_from_user_ll_nocach= e_nozero static __always_inline unsigned long __must_check __copy_to_user_inatomic(void __user *to, const void *from, unsigned lon= g n) { @@ -11026,7 +12352,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_32.h linux-2.6.32.49/arc if (__builtin_constant_p(n)) { unsigned long ret; =20 -@@ -62,6 +67,8 @@ __copy_to_user_inatomic(void __user *to, +@@ -62,6 +67,8 @@ __copy_to_user_inatomic(void __user *to, const void *f= rom, unsigned long n) return ret; } } @@ -11035,7 +12361,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_32.h linux-2.6.32.49/arc return __copy_to_user_ll(to, from, n); } =20 -@@ -83,12 +90,16 @@ static __always_inline unsigned long __m +@@ -83,12 +90,16 @@ static __always_inline unsigned long __must_check __copy_to_user(void __user *to, const void *from, unsigned long n) { might_fault(); @@ -11065,7 +12391,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_32.h linux-2.6.32.49/arc if (__builtin_constant_p(n)) { unsigned long ret; =20 -@@ -153,6 +170,8 @@ __copy_from_user(void *to, const void __ +@@ -153,6 +170,8 @@ __copy_from_user(void *to, const void __user *from, = unsigned long n) return ret; } } @@ -11074,7 +12400,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_32.h linux-2.6.32.49/arc return __copy_from_user_ll(to, from, n); } =20 -@@ -160,6 +179,10 @@ static __always_inline unsigned long __c +@@ -160,6 +179,10 @@ static __always_inline unsigned long __copy_from_us= er_nocache(void *to, const void __user *from, unsigned long n) { might_fault(); @@ -11154,9 +12480,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= uaccess_32.h linux-2.6.32.49/arc long __must_check strncpy_from_user(char *dst, const char __user *src, long count); long __must_check __strncpy_from_user(char *dst, -diff -urNp linux-2.6.32.49/arch/x86/include/asm/uaccess_64.h linux-2.6.3= 2.49/arch/x86/include/asm/uaccess_64.h ---- linux-2.6.32.49/arch/x86/include/asm/uaccess_64.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/uaccess_64.h 2011-11-15 19:59:4= 2.000000000 -0500 +diff --git a/arch/x86/include/asm/uaccess_64.h b/arch/x86/include/asm/ua= ccess_64.h +index db24b21..72a9dfc 100644 +--- a/arch/x86/include/asm/uaccess_64.h ++++ b/arch/x86/include/asm/uaccess_64.h @@ -9,6 +9,9 @@ #include #include @@ -11336,12 +12663,14 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /uaccess_64.h linux-2.6.32.49/arc +#endif + + return copy_user_generic((__force_kernel void *)dst, src, size); -+ } -+} -+ -+static __always_inline __must_check + } + } +=20 + static __always_inline __must_check +-int __copy_in_user(void __user *dst, const void __user *src, unsigned s= ize) +unsigned long copy_to_user(void __user *to, const void *from, unsigned = len) -+{ + { +- int ret =3D 0; + if (access_ok(VERIFY_WRITE, to, len)) + len =3D __copy_to_user(to, from, len); + return len; @@ -11359,15 +12688,13 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /uaccess_64.h linux-2.6.32.49/arc + if (!__builtin_constant_p(len)) + check_object_size(to, len, false); + memset(to, 0, len); - } ++ } + return len; - } -=20 - static __always_inline __must_check --int __copy_in_user(void __user *dst, const void __user *src, unsigned s= ize) ++} ++ ++static __always_inline __must_check +unsigned long __copy_in_user(void __user *dst, const void __user *src, = unsigned size) - { -- int ret =3D 0; ++{ + unsigned ret =3D 0; =20 might_fault(); @@ -11407,7 +12734,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_64.h linux-2.6.32.49/arc ret, "b", "b", "=3Dq", 1); if (likely(!ret)) __put_user_asm(tmp, (u8 __user *)dst, -@@ -134,7 +227,7 @@ int __copy_in_user(void __user *dst, con +@@ -134,7 +227,7 @@ int __copy_in_user(void __user *dst, const void __us= er *src, unsigned size) } case 2: { u16 tmp; @@ -11416,7 +12743,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_64.h linux-2.6.32.49/arc ret, "w", "w", "=3Dr", 2); if (likely(!ret)) __put_user_asm(tmp, (u16 __user *)dst, -@@ -144,7 +237,7 @@ int __copy_in_user(void __user *dst, con +@@ -144,7 +237,7 @@ int __copy_in_user(void __user *dst, const void __us= er *src, unsigned size) =20 case 4: { u32 tmp; @@ -11425,7 +12752,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_64.h linux-2.6.32.49/arc ret, "l", "k", "=3Dr", 4); if (likely(!ret)) __put_user_asm(tmp, (u32 __user *)dst, -@@ -153,7 +246,7 @@ int __copy_in_user(void __user *dst, con +@@ -153,7 +246,7 @@ int __copy_in_user(void __user *dst, const void __us= er *src, unsigned size) } case 8: { u64 tmp; @@ -11434,7 +12761,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_64.h linux-2.6.32.49/arc ret, "q", "", "=3Dr", 8); if (likely(!ret)) __put_user_asm(tmp, (u64 __user *)dst, -@@ -161,8 +254,16 @@ int __copy_in_user(void __user *dst, con +@@ -161,8 +254,16 @@ int __copy_in_user(void __user *dst, const void __u= ser *src, unsigned size) return ret; } default: @@ -11453,7 +12780,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/u= access_64.h linux-2.6.32.49/arc } } =20 -@@ -176,33 +277,75 @@ __must_check long strlen_user(const char +@@ -176,33 +277,75 @@ __must_check long strlen_user(const char __user *s= tr); __must_check unsigned long clear_user(void __user *mem, unsigned long l= en); __must_check unsigned long __clear_user(void __user *mem, unsigned long= len); =20 @@ -11470,12 +12797,12 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /uaccess_64.h linux-2.6.32.49/arc +#ifdef CONFIG_PAX_MEMORY_UDEREF + if (!__access_ok(VERIFY_READ, src, size)) + return size; -+ +=20 +-static __must_check __always_inline int + if ((unsigned long)src < PAX_USER_SHADOW_BASE) + src +=3D PAX_USER_SHADOW_BASE; +#endif -=20 --static __must_check __always_inline int ++ + return copy_user_generic(dst, (__force_kernel const void *)src, size); +} + @@ -11540,239 +12867,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/as= m/uaccess_64.h linux-2.6.32.49/arc +copy_user_handle_tail(char __user *to, char __user *from, unsigned len,= unsigned zerorest); =20 #endif /* _ASM_X86_UACCESS_64_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/uaccess.h linux-2.6.32.4= 9/arch/x86/include/asm/uaccess.h ---- linux-2.6.32.49/arch/x86/include/asm/uaccess.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/uaccess.h 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -8,12 +8,15 @@ - #include - #include - #include -+#include - #include - #include -=20 - #define VERIFY_READ 0 - #define VERIFY_WRITE 1 -=20 -+extern void check_object_size(const void *ptr, unsigned long n, bool to= ); -+ - /* - * The fs value determines whether argument validity checking should be - * performed or not. If get_fs() =3D=3D USER_DS, checking is performed= , with -@@ -29,7 +32,12 @@ -=20 - #define get_ds() (KERNEL_DS) - #define get_fs() (current_thread_info()->addr_limit) -+#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) -+void __set_fs(mm_segment_t x); -+void set_fs(mm_segment_t x); -+#else - #define set_fs(x) (current_thread_info()->addr_limit =3D (x)) -+#endif -=20 - #define segment_eq(a, b) ((a).seg =3D=3D (b).seg) -=20 -@@ -77,7 +85,33 @@ - * checks that the pointer is in the user space range - after calling - * this function, memory access functions may still return -EFAULT. - */ --#define access_ok(type, addr, size) (likely(__range_not_ok(addr, size) = =3D=3D 0)) -+#define __access_ok(type, addr, size) (likely(__range_not_ok(addr, size= ) =3D=3D 0)) -+#define access_ok(type, addr, size) \ -+({ \ -+ long __size =3D size; \ -+ unsigned long __addr =3D (unsigned long)addr; \ -+ unsigned long __addr_ao =3D __addr & PAGE_MASK; \ -+ unsigned long __end_ao =3D __addr + __size - 1; \ -+ bool __ret_ao =3D __range_not_ok(__addr, __size) =3D=3D 0; \ -+ if (__ret_ao && unlikely((__end_ao ^ __addr_ao) & PAGE_MASK)) { \ -+ while(__addr_ao <=3D __end_ao) { \ -+ char __c_ao; \ -+ __addr_ao +=3D PAGE_SIZE; \ -+ if (__size > PAGE_SIZE) \ -+ cond_resched(); \ -+ if (__get_user(__c_ao, (char __user *)__addr)) \ -+ break; \ -+ if (type !=3D VERIFY_WRITE) { \ -+ __addr =3D __addr_ao; \ -+ continue; \ -+ } \ -+ if (__put_user(__c_ao, (char __user *)__addr)) \ -+ break; \ -+ __addr =3D __addr_ao; \ -+ } \ -+ } \ -+ __ret_ao; \ -+}) -=20 - /* - * The exception table consists of pairs of addresses: the first is the -@@ -183,12 +217,20 @@ extern int __get_user_bad(void); - asm volatile("call __put_user_" #size : "=3Da" (__ret_pu) \ - : "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx") -=20 -- -+#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define __copyuser_seg "gs;" -+#define __COPYUSER_SET_ES "pushl %%gs; popl %%es\n" -+#define __COPYUSER_RESTORE_ES "pushl %%ss; popl %%es\n" -+#else -+#define __copyuser_seg -+#define __COPYUSER_SET_ES -+#define __COPYUSER_RESTORE_ES -+#endif -=20 - #ifdef CONFIG_X86_32 - #define __put_user_asm_u64(x, addr, err, errret) \ -- asm volatile("1: movl %%eax,0(%2)\n" \ -- "2: movl %%edx,4(%2)\n" \ -+ asm volatile("1: "__copyuser_seg"movl %%eax,0(%2)\n" \ -+ "2: "__copyuser_seg"movl %%edx,4(%2)\n" \ - "3:\n" \ - ".section .fixup,\"ax\"\n" \ - "4: movl %3,%0\n" \ -@@ -200,8 +242,8 @@ extern int __get_user_bad(void); - : "A" (x), "r" (addr), "i" (errret), "0" (err)) -=20 - #define __put_user_asm_ex_u64(x, addr) \ -- asm volatile("1: movl %%eax,0(%1)\n" \ -- "2: movl %%edx,4(%1)\n" \ -+ asm volatile("1: "__copyuser_seg"movl %%eax,0(%1)\n" \ -+ "2: "__copyuser_seg"movl %%edx,4(%1)\n" \ - "3:\n" \ - _ASM_EXTABLE(1b, 2b - 1b) \ - _ASM_EXTABLE(2b, 3b - 2b) \ -@@ -253,7 +295,7 @@ extern void __put_user_8(void); - __typeof__(*(ptr)) __pu_val; \ - __chk_user_ptr(ptr); \ - might_fault(); \ -- __pu_val =3D x; \ -+ __pu_val =3D (x); \ - switch (sizeof(*(ptr))) { \ - case 1: \ - __put_user_x(1, __pu_val, ptr, __ret_pu); \ -@@ -374,7 +416,7 @@ do { \ - } while (0) -=20 - #define __get_user_asm(x, addr, err, itype, rtype, ltype, errret) \ -- asm volatile("1: mov"itype" %2,%"rtype"1\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %2,%"rtype"1\n"\ - "2:\n" \ - ".section .fixup,\"ax\"\n" \ - "3: mov %3,%0\n" \ -@@ -382,7 +424,7 @@ do { \ - " jmp 2b\n" \ - ".previous\n" \ - _ASM_EXTABLE(1b, 3b) \ -- : "=3Dr" (err), ltype(x) \ -+ : "=3Dr" (err), ltype (x) \ - : "m" (__m(addr)), "i" (errret), "0" (err)) -=20 - #define __get_user_size_ex(x, ptr, size) \ -@@ -407,7 +449,7 @@ do { \ - } while (0) -=20 - #define __get_user_asm_ex(x, addr, itype, rtype, ltype) \ -- asm volatile("1: mov"itype" %1,%"rtype"0\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %1,%"rtype"0\n"\ - "2:\n" \ - _ASM_EXTABLE(1b, 2b - 1b) \ - : ltype(x) : "m" (__m(addr))) -@@ -424,13 +466,24 @@ do { \ - int __gu_err; \ - unsigned long __gu_val; \ - __get_user_size(__gu_val, (ptr), (size), __gu_err, -EFAULT); \ -- (x) =3D (__force __typeof__(*(ptr)))__gu_val; \ -+ (x) =3D (__typeof__(*(ptr)))__gu_val; \ - __gu_err; \ - }) -=20 - /* FIXME: this hack is definitely wrong -AK */ - struct __large_struct { unsigned long buf[100]; }; --#define __m(x) (*(struct __large_struct __user *)(x)) -+#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define ____m(x) \ -+({ \ -+ unsigned long ____x =3D (unsigned long)(x); \ -+ if (____x < PAX_USER_SHADOW_BASE) \ -+ ____x +=3D PAX_USER_SHADOW_BASE; \ -+ (void __user *)____x; \ -+}) -+#else -+#define ____m(x) (x) -+#endif -+#define __m(x) (*(struct __large_struct __user *)____m(x)) -=20 - /* - * Tell gcc we read from memory instead of writing: this is because -@@ -438,7 +491,7 @@ struct __large_struct { unsigned long bu - * aliasing issues. - */ - #define __put_user_asm(x, addr, err, itype, rtype, ltype, errret) \ -- asm volatile("1: mov"itype" %"rtype"1,%2\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"1,%2\n"\ - "2:\n" \ - ".section .fixup,\"ax\"\n" \ - "3: mov %3,%0\n" \ -@@ -446,10 +499,10 @@ struct __large_struct { unsigned long bu - ".previous\n" \ - _ASM_EXTABLE(1b, 3b) \ - : "=3Dr"(err) \ -- : ltype(x), "m" (__m(addr)), "i" (errret), "0" (err)) -+ : ltype (x), "m" (__m(addr)), "i" (errret), "0" (err)) -=20 - #define __put_user_asm_ex(x, addr, itype, rtype, ltype) \ -- asm volatile("1: mov"itype" %"rtype"0,%1\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"0,%1\n"\ - "2:\n" \ - _ASM_EXTABLE(1b, 2b - 1b) \ - : : ltype(x), "m" (__m(addr))) -@@ -488,8 +541,12 @@ struct __large_struct { unsigned long bu - * On error, the variable @x is set to zero. - */ -=20 -+#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define __get_user(x, ptr) get_user((x), (ptr)) -+#else - #define __get_user(x, ptr) \ - __get_user_nocheck((x), (ptr), sizeof(*(ptr))) -+#endif -=20 - /** - * __put_user: - Write a simple value into user space, with less checki= ng. -@@ -511,8 +568,12 @@ struct __large_struct { unsigned long bu - * Returns zero on success, or -EFAULT on error. - */ -=20 -+#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define __put_user(x, ptr) put_user((x), (ptr)) -+#else - #define __put_user(x, ptr) \ - __put_user_nocheck((__typeof__(*(ptr)))(x), (ptr), sizeof(*(ptr))) -+#endif -=20 - #define __get_user_unaligned __get_user - #define __put_user_unaligned __put_user -@@ -530,7 +591,7 @@ struct __large_struct { unsigned long bu - #define get_user_ex(x, ptr) do { \ - unsigned long __gue_val; \ - __get_user_size_ex((__gue_val), (ptr), (sizeof(*(ptr)))); \ -- (x) =3D (__force __typeof__(*(ptr)))__gue_val; \ -+ (x) =3D (__typeof__(*(ptr)))__gue_val; \ - } while (0) -=20 - #ifdef CONFIG_X86_WP_WORKS_OK -@@ -567,6 +628,7 @@ extern struct movsl_mask { -=20 - #define ARCH_HAS_NOCACHE_UACCESS 1 -=20 -+#define ARCH_HAS_SORT_EXTABLE - #ifdef CONFIG_X86_32 - # include "uaccess_32.h" - #else -diff -urNp linux-2.6.32.49/arch/x86/include/asm/vdso.h linux-2.6.32.49/a= rch/x86/include/asm/vdso.h ---- linux-2.6.32.49/arch/x86/include/asm/vdso.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/vdso.h 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/x86/include/asm/vdso.h b/arch/x86/include/asm/vdso.h +index 9064052..786cfbc 100644 +--- a/arch/x86/include/asm/vdso.h ++++ b/arch/x86/include/asm/vdso.h @@ -25,7 +25,7 @@ extern const char VDSO32_PRELINK[]; #define VDSO32_SYMBOL(base, name) \ ({ \ @@ -11782,9 +12880,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= vdso.h linux-2.6.32.49/arch/x86/ }) #endif =20 -diff -urNp linux-2.6.32.49/arch/x86/include/asm/vgtod.h linux-2.6.32.49/= arch/x86/include/asm/vgtod.h ---- linux-2.6.32.49/arch/x86/include/asm/vgtod.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/vgtod.h 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/x86/include/asm/vgtod.h b/arch/x86/include/asm/vgtod.h +index 3d61e20..9507180 100644 +--- a/arch/x86/include/asm/vgtod.h ++++ b/arch/x86/include/asm/vgtod.h @@ -14,6 +14,7 @@ struct vsyscall_gtod_data { int sysctl_enabled; struct timezone sys_tz; @@ -11793,9 +12892,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= vgtod.h linux-2.6.32.49/arch/x86 cycle_t (*vread)(void); cycle_t cycle_last; cycle_t mask; -diff -urNp linux-2.6.32.49/arch/x86/include/asm/vmi.h linux-2.6.32.49/ar= ch/x86/include/asm/vmi.h ---- linux-2.6.32.49/arch/x86/include/asm/vmi.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/vmi.h 2011-11-15 19:59:42.00000= 0000 -0500 +diff --git a/arch/x86/include/asm/vmi.h b/arch/x86/include/asm/vmi.h +index 61e08c0..b0da582 100644 +--- a/arch/x86/include/asm/vmi.h ++++ b/arch/x86/include/asm/vmi.h @@ -191,6 +191,7 @@ struct vrom_header { u8 reserved[96]; /* Reserved for headers */ char vmi_init[8]; /* VMI_Init jump point */ @@ -11804,9 +12904,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= vmi.h linux-2.6.32.49/arch/x86/i } __attribute__((packed)); =20 struct pnp_header { -diff -urNp linux-2.6.32.49/arch/x86/include/asm/vmi_time.h linux-2.6.32.= 49/arch/x86/include/asm/vmi_time.h ---- linux-2.6.32.49/arch/x86/include/asm/vmi_time.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/vmi_time.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/x86/include/asm/vmi_time.h b/arch/x86/include/asm/vmi_= time.h +index c6e0bee..fcb9f74 100644 +--- a/arch/x86/include/asm/vmi_time.h ++++ b/arch/x86/include/asm/vmi_time.h @@ -43,7 +43,7 @@ extern struct vmi_timer_ops { int (*wallclock_updated)(void); void (*set_alarm)(u32 flags, u64 expiry, u64 period); @@ -11816,9 +12917,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= vmi_time.h linux-2.6.32.49/arch/ =20 /* Prototypes */ extern void __init vmi_time_init(void); -diff -urNp linux-2.6.32.49/arch/x86/include/asm/vsyscall.h linux-2.6.32.= 49/arch/x86/include/asm/vsyscall.h ---- linux-2.6.32.49/arch/x86/include/asm/vsyscall.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/vsyscall.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/x86/include/asm/vsyscall.h b/arch/x86/include/asm/vsys= call.h +index d0983d2..1f7c9e9 100644 +--- a/arch/x86/include/asm/vsyscall.h ++++ b/arch/x86/include/asm/vsyscall.h @@ -15,9 +15,10 @@ enum vsyscall_num { =20 #ifdef __KERNEL__ @@ -11849,9 +12951,10 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/= vsyscall.h linux-2.6.32.49/arch/ #endif /* __KERNEL__ */ =20 #endif /* _ASM_X86_VSYSCALL_H */ -diff -urNp linux-2.6.32.49/arch/x86/include/asm/x86_init.h linux-2.6.32.= 49/arch/x86/include/asm/x86_init.h ---- linux-2.6.32.49/arch/x86/include/asm/x86_init.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/x86_init.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/x86/include/asm/x86_init.h b/arch/x86/include/asm/x86_= init.h +index 2c756fd..3377e37 100644 +--- a/arch/x86/include/asm/x86_init.h ++++ b/arch/x86/include/asm/x86_init.h @@ -28,7 +28,7 @@ struct x86_init_mpparse { void (*mpc_oem_bus_info)(struct mpc_bus *m, char *name); void (*find_smp_config)(unsigned int reserve); @@ -11933,10 +13036,11 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm= /x86_init.h linux-2.6.32.49/arch/ =20 extern struct x86_init_ops x86_init; extern struct x86_cpuinit_ops x86_cpuinit; -diff -urNp linux-2.6.32.49/arch/x86/include/asm/xsave.h linux-2.6.32.49/= arch/x86/include/asm/xsave.h ---- linux-2.6.32.49/arch/x86/include/asm/xsave.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/include/asm/xsave.h 2011-11-15 19:59:42.000= 000000 -0500 -@@ -56,6 +56,12 @@ static inline int xrstor_checking(struct +diff --git a/arch/x86/include/asm/xsave.h b/arch/x86/include/asm/xsave.h +index 727acc1..554f3eb 100644 +--- a/arch/x86/include/asm/xsave.h ++++ b/arch/x86/include/asm/xsave.h +@@ -56,6 +56,12 @@ static inline int xrstor_checking(struct xsave_struct= *fx) static inline int xsave_user(struct xsave_struct __user *buf) { int err; @@ -11949,7 +13053,7 @@ diff -urNp linux-2.6.32.49/arch/x86/include/asm/x= save.h linux-2.6.32.49/arch/x86 __asm__ __volatile__("1: .byte " REX_PREFIX "0x0f,0xae,0x27\n" "2:\n" ".section .fixup,\"ax\"\n" -@@ -78,10 +84,15 @@ static inline int xsave_user(struct xsav +@@ -78,10 +84,15 @@ static inline int xsave_user(struct xsave_struct __u= ser *buf) static inline int xrestore_user(struct xsave_struct __user *buf, u64 ma= sk) { int err; @@ -11966,157 +13070,42 @@ diff -urNp linux-2.6.32.49/arch/x86/include/as= m/xsave.h linux-2.6.32.49/arch/x86 __asm__ __volatile__("1: .byte " REX_PREFIX "0x0f,0xae,0x2f\n" "2:\n" ".section .fixup,\"ax\"\n" -diff -urNp linux-2.6.32.49/arch/x86/Kconfig linux-2.6.32.49/arch/x86/Kco= nfig ---- linux-2.6.32.49/arch/x86/Kconfig 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/Kconfig 2011-11-15 19:59:42.000000000 -0500 -@@ -223,7 +223,7 @@ config X86_TRAMPOLINE +diff --git a/arch/x86/kernel/acpi/realmode/Makefile b/arch/x86/kernel/ac= pi/realmode/Makefile +index 6a564ac..9b1340c 100644 +--- a/arch/x86/kernel/acpi/realmode/Makefile ++++ b/arch/x86/kernel/acpi/realmode/Makefile +@@ -41,6 +41,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os -D_SETUP -D_= WAKEUP -D__KERNEL__ \ + $(call cc-option, -fno-stack-protector) \ + $(call cc-option, -mpreferred-stack-boundary=3D2) + KBUILD_CFLAGS +=3D $(call cc-option, -m32) ++ifdef CONSTIFY_PLUGIN ++KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify ++endif + KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ + GCOV_PROFILE :=3D n =20 - config X86_32_LAZY_GS - def_bool y -- depends on X86_32 && !CC_STACKPROTECTOR -+ depends on X86_32 && !CC_STACKPROTECTOR && !PAX_MEMORY_UDEREF +diff --git a/arch/x86/kernel/acpi/realmode/wakeup.S b/arch/x86/kernel/ac= pi/realmode/wakeup.S +index 580b4e2..d4129e4 100644 +--- a/arch/x86/kernel/acpi/realmode/wakeup.S ++++ b/arch/x86/kernel/acpi/realmode/wakeup.S +@@ -91,6 +91,9 @@ _start: + /* Do any other stuff... */ =20 - config KTIME_SCALAR - def_bool X86_32 -@@ -1008,7 +1008,7 @@ choice -=20 - config NOHIGHMEM - bool "off" -- depends on !X86_NUMAQ -+ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) - ---help--- - Linux can use up to 64 Gigabytes of physical memory on x86 systems. - However, the address space of 32-bit x86 processors is only 4 -@@ -1045,7 +1045,7 @@ config NOHIGHMEM -=20 - config HIGHMEM4G - bool "4GB" -- depends on !X86_NUMAQ -+ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) - ---help--- - Select this if you have a 32-bit processor and between 1 and 4 - gigabytes of physical RAM. -@@ -1099,7 +1099,7 @@ config PAGE_OFFSET - hex - default 0xB0000000 if VMSPLIT_3G_OPT - default 0x80000000 if VMSPLIT_2G -- default 0x78000000 if VMSPLIT_2G_OPT -+ default 0x70000000 if VMSPLIT_2G_OPT - default 0x40000000 if VMSPLIT_1G - default 0xC0000000 - depends on X86_32 -@@ -1460,6 +1460,7 @@ config SECCOMP -=20 - config CC_STACKPROTECTOR - bool "Enable -fstack-protector buffer overflow detection (EXPERIMENTAL= )" -+ depends on X86_64 || !PAX_MEMORY_UDEREF - ---help--- - This option turns on the -fstack-protector GCC feature. This - feature puts, at the beginning of functions, a canary value on -@@ -1517,6 +1518,7 @@ config KEXEC_JUMP - config PHYSICAL_START - hex "Physical address where the kernel is loaded" if (EMBEDDED || CRAS= H_DUMP) - default "0x1000000" -+ range 0x400000 0x40000000 - ---help--- - This gives the physical address where the kernel is loaded. -=20 -@@ -1581,6 +1583,7 @@ config PHYSICAL_ALIGN - hex - prompt "Alignment value to which kernel should be aligned" if X86_32 - default "0x1000000" -+ range 0x400000 0x1000000 if PAX_KERNEXEC - range 0x2000 0x1000000 - ---help--- - This value puts the alignment restrictions on physical address -@@ -1612,9 +1615,10 @@ config HOTPLUG_CPU - Say N if you want to disable CPU hotplug. -=20 - config COMPAT_VDSO -- def_bool y -+ def_bool n - prompt "Compat VDSO support" - depends on X86_32 || IA32_EMULATION -+ depends on !PAX_NOEXEC && !PAX_MEMORY_UDEREF - ---help--- - Map the 32-bit VDSO to the predictable old-style address too. - ---help--- -diff -urNp linux-2.6.32.49/arch/x86/Kconfig.cpu linux-2.6.32.49/arch/x86= /Kconfig.cpu ---- linux-2.6.32.49/arch/x86/Kconfig.cpu 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/arch/x86/Kconfig.cpu 2011-11-15 19:59:42.000000000 -= 0500 -@@ -340,7 +340,7 @@ config X86_PPRO_FENCE -=20 - config X86_F00F_BUG - def_bool y -- depends on M586MMX || M586TSC || M586 || M486 || M386 -+ depends on (M586MMX || M586TSC || M586 || M486 || M386) && !PAX_KERNEX= EC -=20 - config X86_WP_WORKS_OK - def_bool y -@@ -360,7 +360,7 @@ config X86_POPAD_OK -=20 - config X86_ALIGNMENT_16 - def_bool y -- depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || X86_ELAN || MK6 ||= M586MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 -+ depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || X86_ELAN || MK8 ||= MK7 || MK6 || MCORE2 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 |= | M586MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 -=20 - config X86_INTEL_USERCOPY - def_bool y -@@ -406,7 +406,7 @@ config X86_CMPXCHG64 - # generates cmov. - config X86_CMOV - def_bool y -- depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUM= III || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEFFICEON |= | X86_64 || MATOM) -+ depends on (MK8 || MK7 || MCORE2 || MPSC || MPENTIUM4 || MPENTIUMM || = MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEF= FICEON || X86_64 || MATOM) -=20 - config X86_MINIMUM_CPU_FAMILY - int -diff -urNp linux-2.6.32.49/arch/x86/Kconfig.debug linux-2.6.32.49/arch/x= 86/Kconfig.debug ---- linux-2.6.32.49/arch/x86/Kconfig.debug 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/Kconfig.debug 2011-11-15 19:59:42.000000000= -0500 -@@ -99,7 +99,7 @@ config X86_PTDUMP - config DEBUG_RODATA - bool "Write protect kernel read-only data structures" - default y -- depends on DEBUG_KERNEL -+ depends on DEBUG_KERNEL && BROKEN - ---help--- - Mark the kernel read-only data as write-protected in the pagetables, - in order to catch accidental (and incorrect) writes to such const -diff -urNp linux-2.6.32.49/arch/x86/kernel/acpi/realmode/Makefile linux-= 2.6.32.49/arch/x86/kernel/acpi/realmode/Makefile ---- linux-2.6.32.49/arch/x86/kernel/acpi/realmode/Makefile 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/acpi/realmode/Makefile 2011-11-15 19= :59:42.000000000 -0500 -@@ -41,6 +41,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os=20 - $(call cc-option, -fno-stack-protector) \ - $(call cc-option, -mpreferred-stack-boundary=3D2) - KBUILD_CFLAGS +=3D $(call cc-option, -m32) -+ifdef CONSTIFY_PLUGIN -+KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify -+endif - KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ - GCOV_PROFILE :=3D n -=20 -diff -urNp linux-2.6.32.49/arch/x86/kernel/acpi/realmode/wakeup.S linux-= 2.6.32.49/arch/x86/kernel/acpi/realmode/wakeup.S ---- linux-2.6.32.49/arch/x86/kernel/acpi/realmode/wakeup.S 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/acpi/realmode/wakeup.S 2011-11-15 19= :59:42.000000000 -0500 -@@ -91,6 +91,9 @@ _start: - /* Do any other stuff... */ -=20 - #ifndef CONFIG_64BIT -+ /* Recheck NX bit overrides (64bit path does this in trampoline) */ -+ call verify_cpu -+ - /* This could also be done in C code... */ - movl pmode_cr3, %eax - movl %eax, %cr3 -@@ -104,7 +107,7 @@ _start: - movl %eax, %ecx - orl %edx, %ecx - jz 1f -- movl $0xc0000080, %ecx -+ mov $MSR_EFER, %ecx - wrmsr - 1: + #ifndef CONFIG_64BIT ++ /* Recheck NX bit overrides (64bit path does this in trampoline) */ ++ call verify_cpu ++ + /* This could also be done in C code... */ + movl pmode_cr3, %eax + movl %eax, %cr3 +@@ -104,7 +107,7 @@ _start: + movl %eax, %ecx + orl %edx, %ecx + jz 1f +- movl $0xc0000080, %ecx ++ mov $MSR_EFER, %ecx + wrmsr + 1: =20 @@ -114,6 +117,7 @@ _start: movl pmode_cr0, %eax @@ -12126,9 +13115,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/acpi/= realmode/wakeup.S linux-2.6.32.4 #else pushw $0 pushw trampoline_segment -diff -urNp linux-2.6.32.49/arch/x86/kernel/acpi/sleep.c linux-2.6.32.49/= arch/x86/kernel/acpi/sleep.c ---- linux-2.6.32.49/arch/x86/kernel/acpi/sleep.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/acpi/sleep.c 2011-11-15 19:59:42.000= 000000 -0500 +diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c +index ca93638..7042f24 100644 +--- a/arch/x86/kernel/acpi/sleep.c ++++ b/arch/x86/kernel/acpi/sleep.c @@ -11,11 +11,12 @@ #include #include @@ -12175,9 +13165,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/acpi/= sleep.c linux-2.6.32.49/arch/x86 } =20 =20 -diff -urNp linux-2.6.32.49/arch/x86/kernel/acpi/wakeup_32.S linux-2.6.32= .49/arch/x86/kernel/acpi/wakeup_32.S ---- linux-2.6.32.49/arch/x86/kernel/acpi/wakeup_32.S 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/acpi/wakeup_32.S 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/kernel/acpi/wakeup_32.S b/arch/x86/kernel/acpi/wak= eup_32.S +index 8ded418..079961e 100644 +--- a/arch/x86/kernel/acpi/wakeup_32.S ++++ b/arch/x86/kernel/acpi/wakeup_32.S @@ -30,13 +30,11 @@ wakeup_pmode_return: # and restore the stack ... but you need gdt for this to work movl saved_context_esp, %esp @@ -12194,10 +13185,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/acpi= /wakeup_32.S linux-2.6.32.49/arch =20 bogus_magic: jmp bogus_magic -diff -urNp linux-2.6.32.49/arch/x86/kernel/alternative.c linux-2.6.32.49= /arch/x86/kernel/alternative.c ---- linux-2.6.32.49/arch/x86/kernel/alternative.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/alternative.c 2011-11-15 19:59:42.00= 0000000 -0500 -@@ -407,7 +407,7 @@ void __init_or_module apply_paravirt(str +diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative= .c +index de7353c..075da5f 100644 +--- a/arch/x86/kernel/alternative.c ++++ b/arch/x86/kernel/alternative.c +@@ -407,7 +407,7 @@ void __init_or_module apply_paravirt(struct paravirt= _patch_site *start, =20 BUG_ON(p->len > MAX_PATCH_LEN); /* prep the buffer with the original instructions */ @@ -12206,7 +13198,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/altern= ative.c linux-2.6.32.49/arch/x8 used =3D pv_init_ops.patch(p->instrtype, p->clobbers, insnbuf, (unsigned long)p->instr, p->len); =20 -@@ -475,7 +475,7 @@ void __init alternative_instructions(voi +@@ -475,7 +475,7 @@ void __init alternative_instructions(void) if (smp_alt_once) free_init_pages("SMP alternatives", (unsigned long)__smp_locks, @@ -12215,7 +13207,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/altern= ative.c linux-2.6.32.49/arch/x8 =20 restart_nmi(); } -@@ -492,13 +492,17 @@ void __init alternative_instructions(voi +@@ -492,13 +492,17 @@ void __init alternative_instructions(void) * instructions. And on the local CPU you need to be protected again NM= I or MCE * handlers seeing an inconsistent instruction while you patch. */ @@ -12235,7 +13227,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/altern= ative.c linux-2.6.32.49/arch/x8 local_irq_restore(flags); /* Could also do a CLFLUSH here to speed up CPU recovery; but that causes hangs on some VIA CPUs. */ -@@ -520,35 +524,21 @@ static void *__init_or_module text_poke_ +@@ -520,35 +524,21 @@ static void *__init_or_module text_poke_early(void= *addr, const void *opcode, */ void *__kprobes text_poke(void *addr, const void *opcode, size_t len) { @@ -12279,10 +13271,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/alte= rnative.c linux-2.6.32.49/arch/x8 + BUG_ON((vaddr)[i] !=3D ((const unsigned char *)opcode)[i]); return addr; } -diff -urNp linux-2.6.32.49/arch/x86/kernel/amd_iommu.c linux-2.6.32.49/a= rch/x86/kernel/amd_iommu.c ---- linux-2.6.32.49/arch/x86/kernel/amd_iommu.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/amd_iommu.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -2076,7 +2076,7 @@ static void prealloc_protection_domains( +diff --git a/arch/x86/kernel/amd_iommu.c b/arch/x86/kernel/amd_iommu.c +index 3a44b75..1601800 100644 +--- a/arch/x86/kernel/amd_iommu.c ++++ b/arch/x86/kernel/amd_iommu.c +@@ -2076,7 +2076,7 @@ static void prealloc_protection_domains(void) } } =20 @@ -12291,9 +13284,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/amd_i= ommu.c linux-2.6.32.49/arch/x86/ .alloc_coherent =3D alloc_coherent, .free_coherent =3D free_coherent, .map_page =3D map_page, -diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/apic.c linux-2.6.32.49/a= rch/x86/kernel/apic/apic.c ---- linux-2.6.32.49/arch/x86/kernel/apic/apic.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/apic/apic.c 2011-11-15 19:59:42.0000= 00000 -0500 +diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c +index 1d2d670..8e3f477 100644 +--- a/arch/x86/kernel/apic/apic.c ++++ b/arch/x86/kernel/apic/apic.c @@ -170,7 +170,7 @@ int first_system_vector =3D 0xfe; /* * Debug level, exported for io_apic.c @@ -12303,7 +13297,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/a= pic.c linux-2.6.32.49/arch/x86/ =20 int pic_mode; =20 -@@ -1794,7 +1794,7 @@ void smp_error_interrupt(struct pt_regs=20 +@@ -1794,7 +1794,7 @@ void smp_error_interrupt(struct pt_regs *regs) apic_write(APIC_ESR, 0); v1 =3D apic_read(APIC_ESR); ack_APIC_irq(); @@ -12312,7 +13306,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/a= pic.c linux-2.6.32.49/arch/x86/ =20 /* * Here is what the APIC error bits mean: -@@ -2184,6 +2184,8 @@ static int __cpuinit apic_cluster_num(vo +@@ -2184,6 +2184,8 @@ static int __cpuinit apic_cluster_num(void) u16 *bios_cpu_apicid; DECLARE_BITMAP(clustermap, NUM_APIC_CLUSTERS); =20 @@ -12321,10 +13315,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apic= /apic.c linux-2.6.32.49/arch/x86/ bios_cpu_apicid =3D early_per_cpu_ptr(x86_bios_cpu_apicid); bitmap_zero(clustermap, NUM_APIC_CLUSTERS); =20 -diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/io_apic.c linux-2.6.32.4= 9/arch/x86/kernel/apic/io_apic.c ---- linux-2.6.32.49/arch/x86/kernel/apic/io_apic.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/apic/io_apic.c 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -716,7 +716,7 @@ struct IO_APIC_route_entry **alloc_ioapi +diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_ap= ic.c +index 8928d97..f799cea 100644 +--- a/arch/x86/kernel/apic/io_apic.c ++++ b/arch/x86/kernel/apic/io_apic.c +@@ -716,7 +716,7 @@ struct IO_APIC_route_entry **alloc_ioapic_entries(vo= id) ioapic_entries =3D kzalloc(sizeof(*ioapic_entries) * nr_ioapics, GFP_ATOMIC); if (!ioapic_entries) @@ -12342,7 +13337,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/i= o_apic.c linux-2.6.32.49/arch/x } =20 /* -@@ -1150,7 +1150,7 @@ int IO_APIC_get_PCI_irq_vector(int bus,=20 +@@ -1150,7 +1150,7 @@ int IO_APIC_get_PCI_irq_vector(int bus, int slot, = int pin, } EXPORT_SYMBOL(IO_APIC_get_PCI_irq_vector); =20 @@ -12360,7 +13355,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/i= o_apic.c linux-2.6.32.49/arch/x { spin_unlock(&vector_lock); } -@@ -2542,7 +2542,7 @@ static void ack_apic_edge(unsigned int i +@@ -2542,7 +2542,7 @@ static void ack_apic_edge(unsigned int irq) ack_APIC_irq(); } =20 @@ -12369,7 +13364,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/i= o_apic.c linux-2.6.32.49/arch/x =20 static void ack_apic_level(unsigned int irq) { -@@ -2626,7 +2626,7 @@ static void ack_apic_level(unsigned int=20 +@@ -2626,7 +2626,7 @@ static void ack_apic_level(unsigned int irq) =20 /* Tail end of version 0x11 I/O APIC bug workaround */ if (!(v & (1 << (i & 0x1f)))) { @@ -12378,9 +13373,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apic/= io_apic.c linux-2.6.32.49/arch/x spin_lock(&ioapic_lock); __mask_and_edge_IO_APIC_irq(cfg); __unmask_and_level_IO_APIC_irq(cfg); -diff -urNp linux-2.6.32.49/arch/x86/kernel/apm_32.c linux-2.6.32.49/arch= /x86/kernel/apm_32.c ---- linux-2.6.32.49/arch/x86/kernel/apm_32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/apm_32.c 2011-11-15 19:59:42.0000000= 00 -0500 +diff --git a/arch/x86/kernel/apm_32.c b/arch/x86/kernel/apm_32.c +index 151ace6..f317474 100644 +--- a/arch/x86/kernel/apm_32.c ++++ b/arch/x86/kernel/apm_32.c @@ -410,7 +410,7 @@ static DEFINE_SPINLOCK(user_list_lock); * This is for buggy BIOS's that refer to (real mode) segment 0x40 * even though they are called in protected mode. @@ -12413,7 +13409,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apm_32= .c linux-2.6.32.49/arch/x86/ker put_cpu(); =20 return call->eax & 0xff; -@@ -664,7 +671,10 @@ static long __apm_bios_call_simple(void=20 +@@ -664,7 +671,10 @@ static long __apm_bios_call_simple(void *_call) BUG_ON(cpu !=3D 0); gdt =3D get_cpu_gdt_table(cpu); save_desc_40 =3D gdt[0x40 / 8]; @@ -12424,7 +13420,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apm_32= .c linux-2.6.32.49/arch/x86/ker =20 apm_irq_save(flags); APM_DO_SAVE_SEGS; -@@ -672,7 +682,11 @@ static long __apm_bios_call_simple(void=20 +@@ -672,7 +682,11 @@ static long __apm_bios_call_simple(void *_call) &call->eax); APM_DO_RESTORE_SEGS; apm_irq_restore(flags); @@ -12461,9 +13457,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/apm_3= 2.c linux-2.6.32.49/arch/x86/ker =20 proc_create("apm", 0, NULL, &apm_file_ops); =20 -diff -urNp linux-2.6.32.49/arch/x86/kernel/asm-offsets_32.c linux-2.6.32= .49/arch/x86/kernel/asm-offsets_32.c ---- linux-2.6.32.49/arch/x86/kernel/asm-offsets_32.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/asm-offsets_32.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/kernel/asm-offsets_32.c b/arch/x86/kernel/asm-offs= ets_32.c +index dfdbf64..9b2b6ce 100644 +--- a/arch/x86/kernel/asm-offsets_32.c ++++ b/arch/x86/kernel/asm-offsets_32.c @@ -51,7 +51,6 @@ void foo(void) OFFSET(CPUINFO_x86_vendor_id, cpuinfo_x86, x86_vendor_id); BLANK(); @@ -12501,9 +13498,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/asm-o= ffsets_32.c linux-2.6.32.49/arch #endif =20 #ifdef CONFIG_XEN -diff -urNp linux-2.6.32.49/arch/x86/kernel/asm-offsets_64.c linux-2.6.32= .49/arch/x86/kernel/asm-offsets_64.c ---- linux-2.6.32.49/arch/x86/kernel/asm-offsets_64.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/asm-offsets_64.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/kernel/asm-offsets_64.c b/arch/x86/kernel/asm-offs= ets_64.c +index 4a6aeed..371de20 100644 +--- a/arch/x86/kernel/asm-offsets_64.c ++++ b/arch/x86/kernel/asm-offsets_64.c @@ -44,6 +44,8 @@ int main(void) ENTRY(addr_limit); ENTRY(preempt_count); @@ -12548,10 +13546,26 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/asm-= offsets_64.c linux-2.6.32.49/arch #ifdef CONFIG_XEN BLANK(); OFFSET(XEN_vcpu_info_mask, vcpu_info, evtchn_upcall_mask); -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/amd.c linux-2.6.32.49/arc= h/x86/kernel/cpu/amd.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/amd.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/amd.c 2011-11-15 19:59:42.000000= 000 -0500 -@@ -602,7 +602,7 @@ static unsigned int __cpuinit amd_size_c +diff --git a/arch/x86/kernel/cpu/Makefile b/arch/x86/kernel/cpu/Makefile +index ff502cc..dc5133e 100644 +--- a/arch/x86/kernel/cpu/Makefile ++++ b/arch/x86/kernel/cpu/Makefile +@@ -7,10 +7,6 @@ ifdef CONFIG_FUNCTION_TRACER + CFLAGS_REMOVE_common.o =3D -pg + endif +=20 +-# Make sure load_percpu_segment has no stackprotector +-nostackp :=3D $(call cc-option, -fno-stack-protector) +-CFLAGS_common.o :=3D $(nostackp) +- + obj-y :=3D intel_cacheinfo.o addon_cpuid_features.o + obj-y +=3D proc.o capflags.o powerflags.o common.o + obj-y +=3D vmware.o hypervisor.o sched.o +diff --git a/arch/x86/kernel/cpu/amd.c b/arch/x86/kernel/cpu/amd.c +index 6e082dc..a0b5f36 100644 +--- a/arch/x86/kernel/cpu/amd.c ++++ b/arch/x86/kernel/cpu/amd.c +@@ -602,7 +602,7 @@ static unsigned int __cpuinit amd_size_cache(struct = cpuinfo_x86 *c, unsigned int size) { /* AMD errata T13 (order #21922) */ @@ -12560,10 +13574,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= amd.c linux-2.6.32.49/arch/x86/ke /* Duron Rev A0 */ if (c->x86_model =3D=3D 3 && c->x86_mask =3D=3D 0) size =3D 64; -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/common.c linux-2.6.32.49/= arch/x86/kernel/cpu/common.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/common.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/common.c 2011-11-15 19:59:42.000= 000000 -0500 -@@ -83,60 +83,6 @@ static const struct cpu_dev __cpuinitcon +diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c +index 4e34d10..a53b130a 100644 +--- a/arch/x86/kernel/cpu/common.c ++++ b/arch/x86/kernel/cpu/common.c +@@ -83,60 +83,6 @@ static const struct cpu_dev __cpuinitconst default_cp= u =3D { =20 static const struct cpu_dev *this_cpu __cpuinitdata =3D &default_cpu; =20 @@ -12633,7 +13648,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/co= mmon.c linux-2.6.32.49/arch/x86 gdt_descr.size =3D GDT_SIZE - 1; load_gdt(&gdt_descr); /* Reload the per-cpu base */ -@@ -798,6 +744,10 @@ static void __cpuinit identify_cpu(struc +@@ -798,6 +744,10 @@ static void __cpuinit identify_cpu(struct cpuinfo_x= 86 *c) /* Filter out anything that depends on CPUID levels we don't have */ filter_cpuid_features(c, true); =20 @@ -12644,7 +13659,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/co= mmon.c linux-2.6.32.49/arch/x86 /* If the model name is still unset, do table lookup. */ if (!c->x86_model_id[0]) { const char *p; -@@ -980,6 +930,9 @@ static __init int setup_disablecpuid(cha +@@ -980,6 +930,9 @@ static __init int setup_disablecpuid(char *arg) } __setup("clearcpuid=3D", setup_disablecpuid); =20 @@ -12654,7 +13669,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/co= mmon.c linux-2.6.32.49/arch/x86 #ifdef CONFIG_X86_64 struct desc_ptr idt_descr =3D { NR_VECTORS * 16 - 1, (unsigned long) id= t_table }; =20 -@@ -995,7 +948,7 @@ DEFINE_PER_CPU(struct task_struct *, cur +@@ -995,7 +948,7 @@ DEFINE_PER_CPU(struct task_struct *, current_task) _= ___cacheline_aligned =3D EXPORT_PER_CPU_SYMBOL(current_task); =20 DEFINE_PER_CPU(unsigned long, kernel_stack) =3D @@ -12663,7 +13678,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/co= mmon.c linux-2.6.32.49/arch/x86 EXPORT_PER_CPU_SYMBOL(kernel_stack); =20 DEFINE_PER_CPU(char *, irq_stack_ptr) =3D -@@ -1060,7 +1013,7 @@ struct pt_regs * __cpuinit idle_regs(str +@@ -1060,7 +1013,7 @@ struct pt_regs * __cpuinit idle_regs(struct pt_reg= s *regs) { memset(regs, 0, sizeof(struct pt_regs)); regs->fs =3D __KERNEL_PERCPU; @@ -12707,10 +13722,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= common.c linux-2.6.32.49/arch/x86 struct thread_struct *thread =3D &curr->thread; =20 if (cpumask_test_and_set_cpu(cpu, cpu_initialized_mask)) { -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/intel.c linux-2.6.32.49/a= rch/x86/kernel/cpu/intel.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/intel.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/intel.c 2011-11-15 19:59:42.0000= 00000 -0500 -@@ -162,7 +162,7 @@ static void __cpuinit trap_init_f00f_bug +diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c +index 6a77cca..4f4fca0 100644 +--- a/arch/x86/kernel/cpu/intel.c ++++ b/arch/x86/kernel/cpu/intel.c +@@ -162,7 +162,7 @@ static void __cpuinit trap_init_f00f_bug(void) * Update the IDT descriptor and reload the IDT so that * it uses the read-only mapped virtual address. */ @@ -12719,10 +13735,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= intel.c linux-2.6.32.49/arch/x86/ load_idt(&idt_descr); } #endif -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/intel_cacheinfo.c linux-2= .6.32.49/arch/x86/kernel/cpu/intel_cacheinfo.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/intel_cacheinfo.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/intel_cacheinfo.c 2011-11-15 19:= 59:42.000000000 -0500 -@@ -921,7 +921,7 @@ static ssize_t store(struct kobject *kob +diff --git a/arch/x86/kernel/cpu/intel_cacheinfo.c b/arch/x86/kernel/cpu= /intel_cacheinfo.c +index 417990f..96dc36b 100644 +--- a/arch/x86/kernel/cpu/intel_cacheinfo.c ++++ b/arch/x86/kernel/cpu/intel_cacheinfo.c +@@ -921,7 +921,7 @@ static ssize_t store(struct kobject *kobj, struct at= tribute *attr, return ret; } =20 @@ -12731,35 +13748,25 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= intel_cacheinfo.c linux-2.6.32.49 .show =3D show, .store =3D store, }; -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/Makefile linux-2.6.32.49/= arch/x86/kernel/cpu/Makefile ---- linux-2.6.32.49/arch/x86/kernel/cpu/Makefile 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/Makefile 2011-11-15 19:59:42.000= 000000 -0500 -@@ -7,10 +7,6 @@ ifdef CONFIG_FUNCTION_TRACER - CFLAGS_REMOVE_common.o =3D -pg - endif -=20 --# Make sure load_percpu_segment has no stackprotector --nostackp :=3D $(call cc-option, -fno-stack-protector) --CFLAGS_common.o :=3D $(nostackp) -- - obj-y :=3D intel_cacheinfo.o addon_cpuid_features.o - obj-y +=3D proc.o capflags.o powerflags.o common.o - obj-y +=3D vmware.o hypervisor.o sched.o -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce_amd.c linux-2.= 6.32.49/arch/x86/kernel/cpu/mcheck/mce_amd.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce_amd.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce_amd.c 2011-11-15 19:5= 9:42.000000000 -0500 -@@ -385,7 +385,7 @@ static ssize_t store(struct kobject *kob - return ret; +diff --git a/arch/x86/kernel/cpu/mcheck/mce-inject.c b/arch/x86/kernel/c= pu/mcheck/mce-inject.c +index 472763d..9831e11 100644 +--- a/arch/x86/kernel/cpu/mcheck/mce-inject.c ++++ b/arch/x86/kernel/cpu/mcheck/mce-inject.c +@@ -211,7 +211,9 @@ static ssize_t mce_write(struct file *filp, const ch= ar __user *ubuf, + static int inject_init(void) + { + printk(KERN_INFO "Machine check injector initialized\n"); +- mce_chrdev_ops.write =3D mce_write; ++ pax_open_kernel(); ++ *(void **)&mce_chrdev_ops.write =3D mce_write; ++ pax_close_kernel(); + register_die_notifier(&mce_raise_nb); + return 0; } -=20 --static struct sysfs_ops threshold_ops =3D { -+static const struct sysfs_ops threshold_ops =3D { - .show =3D show, - .store =3D store, - }; -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce.c linux-2.6.32= .49/arch/x86/kernel/cpu/mcheck/mce.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/kernel/cpu/mcheck/mce.c b/arch/x86/kernel/cpu/mche= ck/mce.c +index 0f16a2b..21740f5 100644 +--- a/arch/x86/kernel/cpu/mcheck/mce.c ++++ b/arch/x86/kernel/cpu/mcheck/mce.c @@ -43,6 +43,7 @@ #include #include @@ -12790,7 +13797,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mc= heck/mce.c linux-2.6.32.49/arch =20 /* Panic in progress. Enable interrupts and wait for final IPI */ static void wait_for_panic(void) -@@ -248,7 +249,7 @@ static void mce_panic(char *msg, struct=20 +@@ -248,7 +249,7 @@ static void mce_panic(char *msg, struct mce *final, = char *exp) /* * Make sure only one CPU runs in machine check panic */ @@ -12799,7 +13806,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mc= heck/mce.c linux-2.6.32.49/arch wait_for_panic(); barrier(); =20 -@@ -256,7 +257,7 @@ static void mce_panic(char *msg, struct=20 +@@ -256,7 +257,7 @@ static void mce_panic(char *msg, struct mce *final, = char *exp) console_verbose(); } else { /* Don't log too much for fake panic */ @@ -12817,7 +13824,26 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/m= check/mce.c linux-2.6.32.49/arch wait_for_panic(); if (!monarch_timeout) goto out; -@@ -1429,14 +1430,14 @@ void __cpuinit mcheck_init(struct cpuinf +@@ -1394,7 +1395,7 @@ static void unexpected_machine_check(struct pt_reg= s *regs, long error_code) + } +=20 + /* Call the installed machine check handler for this CPU setup. */ +-void (*machine_check_vector)(struct pt_regs *, long error_code) =3D ++void (*machine_check_vector)(struct pt_regs *, long error_code) __read_= only =3D + unexpected_machine_check; +=20 + /* +@@ -1416,7 +1417,9 @@ void __cpuinit mcheck_init(struct cpuinfo_x86 *c) + return; + } +=20 ++ pax_open_kernel(); + machine_check_vector =3D do_machine_check; ++ pax_close_kernel(); +=20 + mce_init(); + mce_cpu_features(c); +@@ -1429,14 +1432,14 @@ void __cpuinit mcheck_init(struct cpuinfo_x86 *c= ) */ =20 static DEFINE_SPINLOCK(mce_state_lock); @@ -12834,7 +13860,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mc= heck/mce.c linux-2.6.32.49/arch spin_unlock(&mce_state_lock); =20 return -EBUSY; -@@ -1444,7 +1445,7 @@ static int mce_open(struct inode *inode, +@@ -1444,7 +1447,7 @@ static int mce_open(struct inode *inode, struct fi= le *file) =20 if (file->f_flags & O_EXCL) open_exclu =3D 1; @@ -12843,7 +13869,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mc= heck/mce.c linux-2.6.32.49/arch =20 spin_unlock(&mce_state_lock); =20 -@@ -1455,7 +1456,7 @@ static int mce_release(struct inode *ino +@@ -1455,7 +1458,7 @@ static int mce_release(struct inode *inode, struct= file *file) { spin_lock(&mce_state_lock); =20 @@ -12852,7 +13878,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mc= heck/mce.c linux-2.6.32.49/arch open_exclu =3D 0; =20 spin_unlock(&mce_state_lock); -@@ -2082,7 +2083,7 @@ struct dentry *mce_get_debugfs_dir(void) +@@ -2082,7 +2085,7 @@ struct dentry *mce_get_debugfs_dir(void) static void mce_reset(void) { cpu_missing =3D 0; @@ -12861,24 +13887,52 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= mcheck/mce.c linux-2.6.32.49/arch atomic_set(&mce_executing, 0); atomic_set(&mce_callin, 0); atomic_set(&global_nwo, 0); -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce-inject.c linux= -2.6.32.49/arch/x86/kernel/cpu/mcheck/mce-inject.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce-inject.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mcheck/mce-inject.c 2011-11-15 1= 9:59:42.000000000 -0500 -@@ -211,7 +211,9 @@ static ssize_t mce_write(struct file *fi - static int inject_init(void) +diff --git a/arch/x86/kernel/cpu/mcheck/mce_amd.c b/arch/x86/kernel/cpu/= mcheck/mce_amd.c +index ef3cd31..9d2f6ab 100644 +--- a/arch/x86/kernel/cpu/mcheck/mce_amd.c ++++ b/arch/x86/kernel/cpu/mcheck/mce_amd.c +@@ -385,7 +385,7 @@ static ssize_t store(struct kobject *kobj, struct at= tribute *attr, + return ret; + } +=20 +-static struct sysfs_ops threshold_ops =3D { ++static const struct sysfs_ops threshold_ops =3D { + .show =3D show, + .store =3D store, + }; +diff --git a/arch/x86/kernel/cpu/mcheck/p5.c b/arch/x86/kernel/cpu/mchec= k/p5.c +index 5c0e653..1e82c7c 100644 +--- a/arch/x86/kernel/cpu/mcheck/p5.c ++++ b/arch/x86/kernel/cpu/mcheck/p5.c +@@ -50,7 +50,9 @@ void intel_p5_mcheck_init(struct cpuinfo_x86 *c) + if (!cpu_has(c, X86_FEATURE_MCE)) + return; +=20 ++ pax_open_kernel(); + machine_check_vector =3D pentium_machine_check; ++ pax_close_kernel(); + /* Make sure the vector pointer is visible before we enable MCEs: */ + wmb(); +=20 +diff --git a/arch/x86/kernel/cpu/mcheck/winchip.c b/arch/x86/kernel/cpu/= mcheck/winchip.c +index 54060f5..e6ba93d 100644 +--- a/arch/x86/kernel/cpu/mcheck/winchip.c ++++ b/arch/x86/kernel/cpu/mcheck/winchip.c +@@ -24,7 +24,9 @@ void winchip_mcheck_init(struct cpuinfo_x86 *c) { - printk(KERN_INFO "Machine check injector initialized\n"); -- mce_chrdev_ops.write =3D mce_write; + u32 lo, hi; +=20 + pax_open_kernel(); -+ *(void **)&mce_chrdev_ops.write =3D mce_write; + machine_check_vector =3D winchip_machine_check; + pax_close_kernel(); - register_die_notifier(&mce_raise_nb); - return 0; - } -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/amd.c linux-2.6.32.4= 9/arch/x86/kernel/cpu/mtrr/amd.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/amd.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/amd.c 2011-11-15 19:59:42.0= 00000000 -0500 -@@ -108,7 +108,7 @@ amd_validate_add_page(unsigned long base + /* Make sure the vector pointer is visible before we enable MCEs: */ + wmb(); +=20 +diff --git a/arch/x86/kernel/cpu/mtrr/amd.c b/arch/x86/kernel/cpu/mtrr/a= md.c +index 33af141..92ba9cd 100644 +--- a/arch/x86/kernel/cpu/mtrr/amd.c ++++ b/arch/x86/kernel/cpu/mtrr/amd.c +@@ -108,7 +108,7 @@ amd_validate_add_page(unsigned long base, unsigned l= ong size, unsigned int type) return 0; } =20 @@ -12887,10 +13941,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= mtrr/amd.c linux-2.6.32.49/arch/x .vendor =3D X86_VENDOR_AMD, .set =3D amd_set_mtrr, .get =3D amd_get_mtrr, -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/centaur.c linux-2.6.= 32.49/arch/x86/kernel/cpu/mtrr/centaur.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/centaur.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/centaur.c 2011-11-15 19:59:= 42.000000000 -0500 -@@ -110,7 +110,7 @@ centaur_validate_add_page(unsigned long=20 +diff --git a/arch/x86/kernel/cpu/mtrr/centaur.c b/arch/x86/kernel/cpu/mt= rr/centaur.c +index de89f14..316fe3e 100644 +--- a/arch/x86/kernel/cpu/mtrr/centaur.c ++++ b/arch/x86/kernel/cpu/mtrr/centaur.c +@@ -110,7 +110,7 @@ centaur_validate_add_page(unsigned long base, unsign= ed long size, unsigned int t return 0; } =20 @@ -12899,9 +13954,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/m= trr/centaur.c linux-2.6.32.49/ar .vendor =3D X86_VENDOR_CENTAUR, .set =3D centaur_set_mcr, .get =3D centaur_get_mcr, -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/cyrix.c linux-2.6.32= .49/arch/x86/kernel/cpu/mtrr/cyrix.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/cyrix.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/cyrix.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/kernel/cpu/mtrr/cyrix.c b/arch/x86/kernel/cpu/mtrr= /cyrix.c +index 228d982..68a3343 100644 +--- a/arch/x86/kernel/cpu/mtrr/cyrix.c ++++ b/arch/x86/kernel/cpu/mtrr/cyrix.c @@ -265,7 +265,7 @@ static void cyrix_set_all(void) post_set(); } @@ -12911,9 +13967,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/m= trr/cyrix.c linux-2.6.32.49/arch .vendor =3D X86_VENDOR_CYRIX, .set_all =3D cyrix_set_all, .set =3D cyrix_set_arr, -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/generic.c linux-2.6.= 32.49/arch/x86/kernel/cpu/mtrr/generic.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/generic.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/generic.c 2011-11-15 19:59:= 42.000000000 -0500 +diff --git a/arch/x86/kernel/cpu/mtrr/generic.c b/arch/x86/kernel/cpu/mt= rr/generic.c +index 55da0c5..4d75584 100644 +--- a/arch/x86/kernel/cpu/mtrr/generic.c ++++ b/arch/x86/kernel/cpu/mtrr/generic.c @@ -752,7 +752,7 @@ int positive_have_wrcomb(void) /* * Generic structure... @@ -12923,9 +13980,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/m= trr/generic.c linux-2.6.32.49/ar .use_intel_if =3D 1, .set_all =3D generic_set_all, .get =3D generic_get_mtrr, -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/main.c linux-2.6.32.= 49/arch/x86/kernel/cpu/mtrr/main.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/main.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/main.c 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/x86/kernel/cpu/mtrr/main.c b/arch/x86/kernel/cpu/mtrr/= main.c +index fd60f09..c94ef52 100644 +--- a/arch/x86/kernel/cpu/mtrr/main.c ++++ b/arch/x86/kernel/cpu/mtrr/main.c @@ -60,14 +60,14 @@ static DEFINE_MUTEX(mtrr_mutex); u64 size_or_mask, size_and_mask; static bool mtrr_aps_delayed_init; @@ -12944,9 +14002,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/m= trr/main.c linux-2.6.32.49/arch/ { if (ops->vendor && ops->vendor < X86_VENDOR_NUM) mtrr_ops[ops->vendor] =3D ops; -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/mtrr.h linux-2.6.32.= 49/arch/x86/kernel/cpu/mtrr/mtrr.h ---- linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/mtrr.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/mtrr/mtrr.h 2011-11-15 19:59:42.= 000000000 -0500 +diff --git a/arch/x86/kernel/cpu/mtrr/mtrr.h b/arch/x86/kernel/cpu/mtrr/= mtrr.h +index a501dee..816c719 100644 +--- a/arch/x86/kernel/cpu/mtrr/mtrr.h ++++ b/arch/x86/kernel/cpu/mtrr/mtrr.h @@ -25,14 +25,14 @@ struct mtrr_ops { int (*validate_add_page)(unsigned long base, unsigned long size, unsigned int type); @@ -12964,7 +14023,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/mt= rr/mtrr.h linux-2.6.32.49/arch/ =20 extern int positive_have_wrcomb(void); =20 -@@ -53,10 +53,10 @@ void fill_mtrr_var_range(unsigned int in +@@ -53,10 +53,10 @@ void fill_mtrr_var_range(unsigned int index, u32 base_lo, u32 base_hi, u32 mask_lo, u32 mask_hi); void get_mtrr_state(void); =20 @@ -12977,46 +14036,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= mtrr/mtrr.h linux-2.6.32.49/arch/ =20 #define is_cpu(vnd) (mtrr_if && mtrr_if->vendor =3D=3D X86_VENDOR_##vnd= ) #define use_intel() (mtrr_if && mtrr_if->use_intel_if =3D=3D 1) -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/perfctr-watchdog.c linux-= 2.6.32.49/arch/x86/kernel/cpu/perfctr-watchdog.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/perfctr-watchdog.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/perfctr-watchdog.c 2011-11-15 19= :59:42.000000000 -0500 -@@ -30,11 +30,11 @@ struct nmi_watchdog_ctlblk { -=20 - /* Interface defining a CPU specific perfctr watchdog */ - struct wd_ops { -- int (*reserve)(void); -- void (*unreserve)(void); -- int (*setup)(unsigned nmi_hz); -- void (*rearm)(struct nmi_watchdog_ctlblk *wd, unsigned nmi_hz); -- void (*stop)(void); -+ int (* const reserve)(void); -+ void (* const unreserve)(void); -+ int (* const setup)(unsigned nmi_hz); -+ void (* const rearm)(struct nmi_watchdog_ctlblk *wd, unsigned nmi_hz); -+ void (* const stop)(void); - unsigned perfctr; - unsigned evntsel; - u64 checkbit; -@@ -645,6 +645,7 @@ static const struct wd_ops p4_wd_ops =3D { - #define ARCH_PERFMON_NMI_EVENT_SEL ARCH_PERFMON_UNHALTED_CORE_CYCLES_SE= L - #define ARCH_PERFMON_NMI_EVENT_UMASK ARCH_PERFMON_UNHALTED_CORE_CYCLES_= UMASK -=20 -+/* cannot be const */ - static struct wd_ops intel_arch_wd_ops; -=20 - static int setup_intel_arch_watchdog(unsigned nmi_hz) -@@ -697,6 +698,7 @@ static int setup_intel_arch_watchdog(uns - return 1; - } -=20 -+/* cannot be const */ - static struct wd_ops intel_arch_wd_ops __read_mostly =3D { - .reserve =3D single_msr_reserve, - .unreserve =3D single_msr_unreserve, -diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/perf_event.c linux-2.6.32= .49/arch/x86/kernel/cpu/perf_event.c ---- linux-2.6.32.49/arch/x86/kernel/cpu/perf_event.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/cpu/perf_event.c 2011-11-15 19:59:42= .000000000 -0500 -@@ -723,10 +723,10 @@ x86_perf_event_update(struct perf_event=20 +diff --git a/arch/x86/kernel/cpu/perf_event.c b/arch/x86/kernel/cpu/perf= _event.c +index 0ff02ca..fc49a60 100644 +--- a/arch/x86/kernel/cpu/perf_event.c ++++ b/arch/x86/kernel/cpu/perf_event.c +@@ -723,10 +723,10 @@ x86_perf_event_update(struct perf_event *event, * count to the generic event atomically: */ again: @@ -13038,7 +14062,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/pe= rf_event.c linux-2.6.32.49/arch atomic64_sub(delta, &hwc->period_left); =20 return new_raw_count; -@@ -1353,7 +1353,7 @@ x86_perf_event_set_period(struct perf_ev +@@ -1353,7 +1353,7 @@ x86_perf_event_set_period(struct perf_event *event= , * The hw event starts counting from this event offset, * mark it to be able to extra future deltas: */ @@ -13047,7 +14071,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/pe= rf_event.c linux-2.6.32.49/arch =20 err =3D checking_wrmsrl(hwc->event_base + idx, (u64)(-left) & x86_pmu.event_mask); -@@ -2357,7 +2357,7 @@ perf_callchain_user(struct pt_regs *regs +@@ -2357,7 +2357,7 @@ perf_callchain_user(struct pt_regs *regs, struct p= erf_callchain_entry *entry) break; =20 callchain_store(entry, frame.return_address); @@ -13056,10 +14080,48 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/cpu/= perf_event.c linux-2.6.32.49/arch } } =20 -diff -urNp linux-2.6.32.49/arch/x86/kernel/crash.c linux-2.6.32.49/arch/= x86/kernel/crash.c ---- linux-2.6.32.49/arch/x86/kernel/crash.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/crash.c 2011-11-15 19:59:42.00000000= 0 -0500 -@@ -41,7 +41,7 @@ static void kdump_nmi_callback(int cpu,=20 +diff --git a/arch/x86/kernel/cpu/perfctr-watchdog.c b/arch/x86/kernel/cp= u/perfctr-watchdog.c +index 898df97..9e82503 100644 +--- a/arch/x86/kernel/cpu/perfctr-watchdog.c ++++ b/arch/x86/kernel/cpu/perfctr-watchdog.c +@@ -30,11 +30,11 @@ struct nmi_watchdog_ctlblk { +=20 + /* Interface defining a CPU specific perfctr watchdog */ + struct wd_ops { +- int (*reserve)(void); +- void (*unreserve)(void); +- int (*setup)(unsigned nmi_hz); +- void (*rearm)(struct nmi_watchdog_ctlblk *wd, unsigned nmi_hz); +- void (*stop)(void); ++ int (* const reserve)(void); ++ void (* const unreserve)(void); ++ int (* const setup)(unsigned nmi_hz); ++ void (* const rearm)(struct nmi_watchdog_ctlblk *wd, unsigned nmi_hz); ++ void (* const stop)(void); + unsigned perfctr; + unsigned evntsel; + u64 checkbit; +@@ -645,6 +645,7 @@ static const struct wd_ops p4_wd_ops =3D { + #define ARCH_PERFMON_NMI_EVENT_SEL ARCH_PERFMON_UNHALTED_CORE_CYCLES_SE= L + #define ARCH_PERFMON_NMI_EVENT_UMASK ARCH_PERFMON_UNHALTED_CORE_CYCLES_= UMASK +=20 ++/* cannot be const */ + static struct wd_ops intel_arch_wd_ops; +=20 + static int setup_intel_arch_watchdog(unsigned nmi_hz) +@@ -697,6 +698,7 @@ static int setup_intel_arch_watchdog(unsigned nmi_hz= ) + return 1; + } +=20 ++/* cannot be const */ + static struct wd_ops intel_arch_wd_ops __read_mostly =3D { + .reserve =3D single_msr_reserve, + .unreserve =3D single_msr_unreserve, +diff --git a/arch/x86/kernel/crash.c b/arch/x86/kernel/crash.c +index ff95824..2ffdcb5 100644 +--- a/arch/x86/kernel/crash.c ++++ b/arch/x86/kernel/crash.c +@@ -41,7 +41,7 @@ static void kdump_nmi_callback(int cpu, struct die_arg= s *args) regs =3D args->regs; =20 #ifdef CONFIG_X86_32 @@ -13068,9 +14130,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/crash= .c linux-2.6.32.49/arch/x86/kern crash_fixup_ss_esp(&fixed_regs, regs); regs =3D &fixed_regs; } -diff -urNp linux-2.6.32.49/arch/x86/kernel/doublefault_32.c linux-2.6.32= .49/arch/x86/kernel/doublefault_32.c ---- linux-2.6.32.49/arch/x86/kernel/doublefault_32.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/doublefault_32.c 2011-11-15 19:59:42= .000000000 -0500 +diff --git a/arch/x86/kernel/doublefault_32.c b/arch/x86/kernel/doublefa= ult_32.c +index 37250fe..bf2ec74 100644 +--- a/arch/x86/kernel/doublefault_32.c ++++ b/arch/x86/kernel/doublefault_32.c @@ -11,7 +11,7 @@ =20 #define DOUBLEFAULT_STACKSIZE (1024) @@ -13089,7 +14152,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/double= fault_32.c linux-2.6.32.49/arch =20 printk(KERN_EMERG "PANIC: double fault, gdt at %08lx [%d bytes]\n", gd= t, gdt_desc.size); =20 -@@ -58,10 +58,10 @@ struct tss_struct doublefault_tss __cach +@@ -58,10 +58,10 @@ struct tss_struct doublefault_tss __cacheline_aligne= d =3D { /* 0x2 bit is always set */ .flags =3D X86_EFLAGS_SF | 0x2, .sp =3D STACK_START, @@ -13102,10 +14165,144 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dou= blefault_32.c linux-2.6.32.49/arch .fs =3D __KERNEL_PERCPU, =20 .__cr3 =3D __pa_nodebug(swapper_pg_dir), -diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpstack_32.c linux-2.6.32.4= 9/arch/x86/kernel/dumpstack_32.c ---- linux-2.6.32.49/arch/x86/kernel/dumpstack_32.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/dumpstack_32.c 2011-11-18 18:10:09.0= 00000000 -0500 -@@ -53,16 +53,12 @@ void dump_trace(struct task_struct *task +diff --git a/arch/x86/kernel/dumpstack.c b/arch/x86/kernel/dumpstack.c +index 2d8a371..4fa6ae6 100644 +--- a/arch/x86/kernel/dumpstack.c ++++ b/arch/x86/kernel/dumpstack.c +@@ -2,6 +2,9 @@ + * Copyright (C) 1991, 1992 Linus Torvalds + * Copyright (C) 2000, 2001, 2002 Andi Kleen, SuSE Labs + */ ++#ifdef CONFIG_GRKERNSEC_HIDESYM ++#define __INCLUDED_BY_HIDESYM 1 ++#endif + #include + #include + #include +@@ -28,7 +31,7 @@ static int die_counter; +=20 + void printk_address(unsigned long address, int reliable) + { +- printk(" [<%p>] %s%pS\n", (void *) address, ++ printk(" [<%p>] %s%pA\n", (void *) address, + reliable ? "" : "? ", (void *) address); + } +=20 +@@ -36,9 +39,8 @@ void printk_address(unsigned long address, int reliabl= e) + static void + print_ftrace_graph_addr(unsigned long addr, void *data, + const struct stacktrace_ops *ops, +- struct thread_info *tinfo, int *graph) ++ struct task_struct *task, int *graph) + { +- struct task_struct *task =3D tinfo->task; + unsigned long ret_addr; + int index =3D task->curr_ret_stack; +=20 +@@ -59,7 +61,7 @@ print_ftrace_graph_addr(unsigned long addr, void *data= , + static inline void + print_ftrace_graph_addr(unsigned long addr, void *data, + const struct stacktrace_ops *ops, +- struct thread_info *tinfo, int *graph) ++ struct task_struct *task, int *graph) + { } + #endif +=20 +@@ -70,10 +72,8 @@ print_ftrace_graph_addr(unsigned long addr, void *dat= a, + * severe exception (double fault, nmi, stack fault, debug, mce) hardwa= re stack + */ +=20 +-static inline int valid_stack_ptr(struct thread_info *tinfo, +- void *p, unsigned int size, void *end) ++static inline int valid_stack_ptr(void *t, void *p, unsigned int size, = void *end) + { +- void *t =3D tinfo; + if (end) { + if (p < end && p >=3D (end-THREAD_SIZE)) + return 1; +@@ -84,14 +84,14 @@ static inline int valid_stack_ptr(struct thread_info= *tinfo, + } +=20 + unsigned long +-print_context_stack(struct thread_info *tinfo, ++print_context_stack(struct task_struct *task, void *stack_start, + unsigned long *stack, unsigned long bp, + const struct stacktrace_ops *ops, void *data, + unsigned long *end, int *graph) + { + struct stack_frame *frame =3D (struct stack_frame *)bp; +=20 +- while (valid_stack_ptr(tinfo, stack, sizeof(*stack), end)) { ++ while (valid_stack_ptr(stack_start, stack, sizeof(*stack), end)) { + unsigned long addr; +=20 + addr =3D *stack; +@@ -103,7 +103,7 @@ print_context_stack(struct thread_info *tinfo, + } else { + ops->address(data, addr, 0); + } +- print_ftrace_graph_addr(addr, data, ops, tinfo, graph); ++ print_ftrace_graph_addr(addr, data, ops, task, graph); + } + stack++; + } +@@ -180,7 +180,7 @@ void dump_stack(void) + #endif +=20 + printk("Pid: %d, comm: %.20s %s %s %.*s\n", +- current->pid, current->comm, print_tainted(), ++ task_pid_nr(current), current->comm, print_tainted(), + init_utsname()->release, + (int)strcspn(init_utsname()->version, " "), + init_utsname()->version); +@@ -220,6 +220,8 @@ unsigned __kprobes long oops_begin(void) + return flags; + } +=20 ++extern void gr_handle_kernel_exploit(void); ++ + void __kprobes oops_end(unsigned long flags, struct pt_regs *regs, int = signr) + { + if (regs && kexec_should_crash(current)) +@@ -241,7 +243,10 @@ void __kprobes oops_end(unsigned long flags, struct= pt_regs *regs, int signr) + panic("Fatal exception in interrupt"); + if (panic_on_oops) + panic("Fatal exception"); +- do_exit(signr); ++ ++ gr_handle_kernel_exploit(); ++ ++ do_group_exit(signr); + } +=20 + int __kprobes __die(const char *str, struct pt_regs *regs, long err) +@@ -295,7 +300,7 @@ void die(const char *str, struct pt_regs *regs, long= err) + unsigned long flags =3D oops_begin(); + int sig =3D SIGSEGV; +=20 +- if (!user_mode_vm(regs)) ++ if (!user_mode(regs)) + report_bug(regs->ip, regs); +=20 + if (__die(str, regs, err)) +diff --git a/arch/x86/kernel/dumpstack.h b/arch/x86/kernel/dumpstack.h +index 81086c2..13e8b17 100644 +--- a/arch/x86/kernel/dumpstack.h ++++ b/arch/x86/kernel/dumpstack.h +@@ -15,7 +15,7 @@ + #endif +=20 + extern unsigned long +-print_context_stack(struct thread_info *tinfo, ++print_context_stack(struct task_struct *task, void *stack_start, + unsigned long *stack, unsigned long bp, + const struct stacktrace_ops *ops, void *data, + unsigned long *end, int *graph); +diff --git a/arch/x86/kernel/dumpstack_32.c b/arch/x86/kernel/dumpstack_= 32.c +index f7dd2a7..504f53b 100644 +--- a/arch/x86/kernel/dumpstack_32.c ++++ b/arch/x86/kernel/dumpstack_32.c +@@ -53,16 +53,12 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, #endif =20 for (;;) { @@ -13126,7 +14323,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_32.c linux-2.6.32.49/arch/x if (ops->stack(data, "IRQ") < 0) break; touch_nmi_watchdog(); -@@ -112,11 +108,12 @@ void show_registers(struct pt_regs *regs +@@ -112,11 +108,12 @@ void show_registers(struct pt_regs *regs) * When in-kernel, we also print out the stack and code at the * time of the fault.. */ @@ -13140,7 +14337,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_32.c linux-2.6.32.49/arch/x =20 printk(KERN_EMERG "Stack:\n"); show_stack_log_lvl(NULL, regs, ®s->sp, -@@ -124,10 +121,10 @@ void show_registers(struct pt_regs *regs +@@ -124,10 +121,10 @@ void show_registers(struct pt_regs *regs) =20 printk(KERN_EMERG "Code: "); =20 @@ -13153,7 +14350,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_32.c linux-2.6.32.49/arch/x code_len =3D code_len - code_prologue + 1; } for (i =3D 0; i < code_len; i++, ip++) { -@@ -136,7 +133,7 @@ void show_registers(struct pt_regs *regs +@@ -136,7 +133,7 @@ void show_registers(struct pt_regs *regs) printk(" Bad EIP value."); break; } @@ -13162,7 +14359,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_32.c linux-2.6.32.49/arch/x printk("<%02x> ", c); else printk("%02x ", c); -@@ -145,10 +142,23 @@ void show_registers(struct pt_regs *regs +@@ -145,10 +142,23 @@ void show_registers(struct pt_regs *regs) printk("\n"); } =20 @@ -13186,10 +14383,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dump= stack_32.c linux-2.6.32.49/arch/x if (ip < PAGE_OFFSET) return 0; if (probe_kernel_address((unsigned short *)ip, ud2)) -diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpstack_64.c linux-2.6.32.4= 9/arch/x86/kernel/dumpstack_64.c ---- linux-2.6.32.49/arch/x86/kernel/dumpstack_64.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/dumpstack_64.c 2011-11-18 18:01:52.0= 00000000 -0500 -@@ -116,8 +116,8 @@ void dump_trace(struct task_struct *task +diff --git a/arch/x86/kernel/dumpstack_64.c b/arch/x86/kernel/dumpstack_= 64.c +index a071e6b..36cd585 100644 +--- a/arch/x86/kernel/dumpstack_64.c ++++ b/arch/x86/kernel/dumpstack_64.c +@@ -116,8 +116,8 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, unsigned long *irq_stack_end =3D (unsigned long *)per_cpu(irq_stack_ptr, cpu); unsigned used =3D 0; @@ -13199,7 +14397,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_64.c linux-2.6.32.49/arch/x =20 if (!task) task =3D current; -@@ -146,10 +146,10 @@ void dump_trace(struct task_struct *task +@@ -146,10 +146,10 @@ void dump_trace(struct task_struct *task, struct p= t_regs *regs, * current stack address. If the stacks consist of nested * exceptions */ @@ -13211,7 +14409,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_64.c linux-2.6.32.49/arch/x estack_end =3D in_exception_stack(cpu, (unsigned long)stack, &used, &id); =20 -@@ -157,7 +157,7 @@ void dump_trace(struct task_struct *task +@@ -157,7 +157,7 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, if (ops->stack(data, id) < 0) break; =20 @@ -13220,7 +14418,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_64.c linux-2.6.32.49/arch/x data, estack_end, &graph); ops->stack(data, ""); /* -@@ -176,7 +176,7 @@ void dump_trace(struct task_struct *task +@@ -176,7 +176,7 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, if (stack >=3D irq_stack && stack < irq_stack_end) { if (ops->stack(data, "IRQ") < 0) break; @@ -13229,7 +14427,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpst= ack_64.c linux-2.6.32.49/arch/x ops, data, irq_stack_end, &graph); /* * We link to the next stack (which would be -@@ -195,7 +195,8 @@ void dump_trace(struct task_struct *task +@@ -195,7 +195,8 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, /* * This handles the process stack: */ @@ -13290,140 +14488,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/dum= pstack_64.c linux-2.6.32.49/arch/x +} +EXPORT_SYMBOL(pax_check_alloca); +#endif -diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpstack.c linux-2.6.32.49/a= rch/x86/kernel/dumpstack.c ---- linux-2.6.32.49/arch/x86/kernel/dumpstack.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/dumpstack.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -2,6 +2,9 @@ - * Copyright (C) 1991, 1992 Linus Torvalds - * Copyright (C) 2000, 2001, 2002 Andi Kleen, SuSE Labs - */ -+#ifdef CONFIG_GRKERNSEC_HIDESYM -+#define __INCLUDED_BY_HIDESYM 1 -+#endif - #include - #include - #include -@@ -28,7 +31,7 @@ static int die_counter; -=20 - void printk_address(unsigned long address, int reliable) - { -- printk(" [<%p>] %s%pS\n", (void *) address, -+ printk(" [<%p>] %s%pA\n", (void *) address, - reliable ? "" : "? ", (void *) address); - } -=20 -@@ -36,9 +39,8 @@ void printk_address(unsigned long addres - static void - print_ftrace_graph_addr(unsigned long addr, void *data, - const struct stacktrace_ops *ops, -- struct thread_info *tinfo, int *graph) -+ struct task_struct *task, int *graph) - { -- struct task_struct *task =3D tinfo->task; - unsigned long ret_addr; - int index =3D task->curr_ret_stack; -=20 -@@ -59,7 +61,7 @@ print_ftrace_graph_addr(unsigned long ad - static inline void - print_ftrace_graph_addr(unsigned long addr, void *data, - const struct stacktrace_ops *ops, -- struct thread_info *tinfo, int *graph) -+ struct task_struct *task, int *graph) - { } - #endif -=20 -@@ -70,10 +72,8 @@ print_ftrace_graph_addr(unsigned long ad - * severe exception (double fault, nmi, stack fault, debug, mce) hardwa= re stack - */ -=20 --static inline int valid_stack_ptr(struct thread_info *tinfo, -- void *p, unsigned int size, void *end) -+static inline int valid_stack_ptr(void *t, void *p, unsigned int size, = void *end) - { -- void *t =3D tinfo; - if (end) { - if (p < end && p >=3D (end-THREAD_SIZE)) - return 1; -@@ -84,14 +84,14 @@ static inline int valid_stack_ptr(struct - } -=20 - unsigned long --print_context_stack(struct thread_info *tinfo, -+print_context_stack(struct task_struct *task, void *stack_start, - unsigned long *stack, unsigned long bp, - const struct stacktrace_ops *ops, void *data, - unsigned long *end, int *graph) - { - struct stack_frame *frame =3D (struct stack_frame *)bp; -=20 -- while (valid_stack_ptr(tinfo, stack, sizeof(*stack), end)) { -+ while (valid_stack_ptr(stack_start, stack, sizeof(*stack), end)) { - unsigned long addr; -=20 - addr =3D *stack; -@@ -103,7 +103,7 @@ print_context_stack(struct thread_info * - } else { - ops->address(data, addr, 0); - } -- print_ftrace_graph_addr(addr, data, ops, tinfo, graph); -+ print_ftrace_graph_addr(addr, data, ops, task, graph); - } - stack++; - } -@@ -180,7 +180,7 @@ void dump_stack(void) - #endif -=20 - printk("Pid: %d, comm: %.20s %s %s %.*s\n", -- current->pid, current->comm, print_tainted(), -+ task_pid_nr(current), current->comm, print_tainted(), - init_utsname()->release, - (int)strcspn(init_utsname()->version, " "), - init_utsname()->version); -@@ -220,6 +220,8 @@ unsigned __kprobes long oops_begin(void) - return flags; - } -=20 -+extern void gr_handle_kernel_exploit(void); -+ - void __kprobes oops_end(unsigned long flags, struct pt_regs *regs, int = signr) - { - if (regs && kexec_should_crash(current)) -@@ -241,7 +243,10 @@ void __kprobes oops_end(unsigned long fl - panic("Fatal exception in interrupt"); - if (panic_on_oops) - panic("Fatal exception"); -- do_exit(signr); -+ -+ gr_handle_kernel_exploit(); -+ -+ do_group_exit(signr); - } -=20 - int __kprobes __die(const char *str, struct pt_regs *regs, long err) -@@ -295,7 +300,7 @@ void die(const char *str, struct pt_regs - unsigned long flags =3D oops_begin(); - int sig =3D SIGSEGV; -=20 -- if (!user_mode_vm(regs)) -+ if (!user_mode(regs)) - report_bug(regs->ip, regs); -=20 - if (__die(str, regs, err)) -diff -urNp linux-2.6.32.49/arch/x86/kernel/dumpstack.h linux-2.6.32.49/a= rch/x86/kernel/dumpstack.h ---- linux-2.6.32.49/arch/x86/kernel/dumpstack.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/dumpstack.h 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -15,7 +15,7 @@ - #endif -=20 - extern unsigned long --print_context_stack(struct thread_info *tinfo, -+print_context_stack(struct task_struct *task, void *stack_start, - unsigned long *stack, unsigned long bp, - const struct stacktrace_ops *ops, void *data, - unsigned long *end, int *graph); -diff -urNp linux-2.6.32.49/arch/x86/kernel/e820.c linux-2.6.32.49/arch/x= 86/kernel/e820.c ---- linux-2.6.32.49/arch/x86/kernel/e820.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/kernel/e820.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/kernel/e820.c b/arch/x86/kernel/e820.c +index a89739a..95e0c48 100644 +--- a/arch/x86/kernel/e820.c ++++ b/arch/x86/kernel/e820.c @@ -733,7 +733,7 @@ struct early_res { }; static struct early_res early_res[MAX_EARLY_RES] __initdata =3D { @@ -13433,9 +14501,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/e820.= c linux-2.6.32.49/arch/x86/kerne }; =20 static int __init find_overlapped_early(u64 start, u64 end) -diff -urNp linux-2.6.32.49/arch/x86/kernel/early_printk.c linux-2.6.32.4= 9/arch/x86/kernel/early_printk.c ---- linux-2.6.32.49/arch/x86/kernel/early_printk.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/early_printk.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/arch/x86/kernel/early_printk.c b/arch/x86/kernel/early_prin= tk.c +index b9c830c..1e41a96 100644 +--- a/arch/x86/kernel/early_printk.c ++++ b/arch/x86/kernel/early_printk.c @@ -7,6 +7,7 @@ #include #include @@ -13444,7 +14513,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/early_= printk.c linux-2.6.32.49/arch/x #include #include #include -@@ -170,6 +171,8 @@ asmlinkage void early_printk(const char=20 +@@ -170,6 +171,8 @@ asmlinkage void early_printk(const char *fmt, ...) int n; va_list ap; =20 @@ -13453,9 +14522,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/early= _printk.c linux-2.6.32.49/arch/x va_start(ap, fmt); n =3D vscnprintf(buf, sizeof(buf), fmt, ap); early_console->write(early_console, buf, n); -diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_32.c linux-2.6.32.49/arch= /x86/kernel/efi_32.c ---- linux-2.6.32.49/arch/x86/kernel/efi_32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/efi_32.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/kernel/efi_32.c b/arch/x86/kernel/efi_32.c +index 5cab48e..b025f9b 100644 +--- a/arch/x86/kernel/efi_32.c ++++ b/arch/x86/kernel/efi_32.c @@ -38,70 +38,56 @@ */ =20 @@ -13470,10 +14540,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_= 32.c linux-2.6.32.49/arch/x86/ker - unsigned long temp; struct desc_ptr gdt_descr; =20 -- local_irq_save(efi_rt_eflags); +#ifdef CONFIG_PAX_KERNEXEC + struct desc_struct d; +#endif ++ + local_irq_save(efi_rt_eflags); =20 - /* - * If I don't have PAE, I should just duplicate two entries in page @@ -13481,8 +14552,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_32= .c linux-2.6.32.49/arch/x86/ker - * page directory. - */ - cr4 =3D read_cr4_safe(); -+ local_irq_save(efi_rt_eflags); -=20 +- - if (cr4 & X86_CR4_PAE) { - efi_bak_pg_dir_pointer[0].pgd =3D - swapper_pg_dir[pgd_index(0)].pgd; @@ -13553,9 +14623,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_3= 2.c linux-2.6.32.49/arch/x86/ker =20 /* * After the lock is released, the original page table is restored. -diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_stub_32.S linux-2.6.32.49= /arch/x86/kernel/efi_stub_32.S ---- linux-2.6.32.49/arch/x86/kernel/efi_stub_32.S 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/efi_stub_32.S 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/arch/x86/kernel/efi_stub_32.S b/arch/x86/kernel/efi_stub_32= .S +index fbe66e6..c5c0dd2 100644 +--- a/arch/x86/kernel/efi_stub_32.S ++++ b/arch/x86/kernel/efi_stub_32.S @@ -6,7 +6,9 @@ */ =20 @@ -13664,9 +14735,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_s= tub_32.S linux-2.6.32.49/arch/x8 saved_return_addr: .long 0 efi_rt_function_ptr: -diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_stub_64.S linux-2.6.32.49= /arch/x86/kernel/efi_stub_64.S ---- linux-2.6.32.49/arch/x86/kernel/efi_stub_64.S 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/efi_stub_64.S 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/arch/x86/kernel/efi_stub_64.S b/arch/x86/kernel/efi_stub_64= .S +index 4c07cca..2c8427d 100644 +--- a/arch/x86/kernel/efi_stub_64.S ++++ b/arch/x86/kernel/efi_stub_64.S @@ -7,6 +7,7 @@ */ =20 @@ -13679,7 +14751,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_st= ub_64.S linux-2.6.32.49/arch/x8 call *%rdi addq $32, %rsp RESTORE_XMM -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret ENDPROC(efi_call0) =20 @@ -13687,7 +14759,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_st= ub_64.S linux-2.6.32.49/arch/x8 call *%rdi addq $32, %rsp RESTORE_XMM -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret ENDPROC(efi_call1) =20 @@ -13695,7 +14767,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_st= ub_64.S linux-2.6.32.49/arch/x8 call *%rdi addq $32, %rsp RESTORE_XMM -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret ENDPROC(efi_call2) =20 @@ -13703,7 +14775,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_st= ub_64.S linux-2.6.32.49/arch/x8 call *%rdi addq $32, %rsp RESTORE_XMM -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret ENDPROC(efi_call3) =20 @@ -13711,7 +14783,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_st= ub_64.S linux-2.6.32.49/arch/x8 call *%rdi addq $32, %rsp RESTORE_XMM -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret ENDPROC(efi_call4) =20 @@ -13719,7 +14791,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_st= ub_64.S linux-2.6.32.49/arch/x8 call *%rdi addq $48, %rsp RESTORE_XMM -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret ENDPROC(efi_call5) =20 @@ -13727,12 +14799,13 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/efi_= stub_64.S linux-2.6.32.49/arch/x8 call *%rdi addq $48, %rsp RESTORE_XMM -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret ENDPROC(efi_call6) -diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_32.S linux-2.6.32.49/ar= ch/x86/kernel/entry_32.S ---- linux-2.6.32.49/arch/x86/kernel/entry_32.S 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/entry_32.S 2011-11-18 18:01:52.00000= 0000 -0500 +diff --git a/arch/x86/kernel/entry_32.S b/arch/x86/kernel/entry_32.S +index c097e7d..c689cf4 100644 +--- a/arch/x86/kernel/entry_32.S ++++ b/arch/x86/kernel/entry_32.S @@ -185,13 +185,146 @@ /*CFI_REL_OFFSET gs, PT_GS*/ .endm @@ -14497,9 +15570,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry= _32.S linux-2.6.32.49/arch/x86/k =20 /* * End of kprobes section -diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_64.S linux-2.6.32.49/ar= ch/x86/kernel/entry_64.S ---- linux-2.6.32.49/arch/x86/kernel/entry_64.S 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/entry_64.S 2011-11-18 18:01:52.00000= 0000 -0500 +diff --git a/arch/x86/kernel/entry_64.S b/arch/x86/kernel/entry_64.S +index 34a56a9..a4abbbe 100644 +--- a/arch/x86/kernel/entry_64.S ++++ b/arch/x86/kernel/entry_64.S @@ -53,6 +53,8 @@ #include #include @@ -14573,7 +15647,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k retq #endif =20 -@@ -174,6 +182,269 @@ ENTRY(native_usergs_sysret64) +@@ -174,6 +182,282 @@ ENTRY(native_usergs_sysret64) ENDPROC(native_usergs_sysret64) #endif /* CONFIG_PARAVIRT */ =20 @@ -14592,6 +15666,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k + .endm + + .macro pax_enter_kernel ++ pax_set_fptr_mask +#ifdef CONFIG_PAX_KERNEXEC + call pax_enter_kernel +#endif @@ -14613,14 +15688,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k + + GET_CR0_INTO_RDI + bts $16,%rdi -+ jnc 1f ++ jnc 3f + mov %cs,%edi + cmp $__KERNEL_CS,%edi -+ jz 3f -+ ljmpq __KERNEL_CS,3f -+1: ljmpq __KERNEXEC_KERNEL_CS,2f -+2: SET_RDI_INTO_CR0 -+3: ++ jnz 2f ++1: + +#ifdef CONFIG_PARAVIRT + PV_RESTORE_REGS(CLBR_RDI) @@ -14629,6 +15701,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry= _64.S linux-2.6.32.49/arch/x86/k + popq %rdi + pax_force_retaddr + retq ++ ++2: ljmpq __KERNEL_CS,1f ++3: ljmpq __KERNEXEC_KERNEL_CS,4f ++4: SET_RDI_INTO_CR0 ++ jmp 1b +ENDPROC(pax_enter_kernel) + +ENTRY(pax_exit_kernel) @@ -14640,12 +15717,8 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry= _64.S linux-2.6.32.49/arch/x86/k + + mov %cs,%rdi + cmp $__KERNEXEC_KERNEL_CS,%edi -+ jnz 2f -+ GET_CR0_INTO_RDI -+ btr $16,%rdi -+ ljmpq __KERNEL_CS,1f -+1: SET_RDI_INTO_CR0 -+2: ++ jz 2f ++1: + +#ifdef CONFIG_PARAVIRT + PV_RESTORE_REGS(CLBR_RDI); @@ -14654,10 +15727,24 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k + popq %rdi + pax_force_retaddr + retq ++ ++2: GET_CR0_INTO_RDI ++ btr $16,%rdi ++ ljmpq __KERNEL_CS,3f ++3: SET_RDI_INTO_CR0 ++ jmp 1b ++#ifdef CONFIG_PARAVIRT ++ PV_RESTORE_REGS(CLBR_RDI); ++#endif ++ ++ popq %rdi ++ pax_force_retaddr ++ retq +ENDPROC(pax_exit_kernel) +#endif + + .macro pax_enter_kernel_user ++ pax_set_fptr_mask +#ifdef CONFIG_PAX_MEMORY_UDEREF + call pax_enter_kernel_user +#endif @@ -14790,16 +15877,16 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k + +#ifdef CONFIG_PAX_MEMORY_STACKLEAK +/* -+ * r10: thread_info ++ * r11: thread_info + * rcx, rdx: can be clobbered + */ +ENTRY(pax_erase_kstack) + pushq %rdi + pushq %rax -+ pushq %r10 ++ pushq %r11 + -+ GET_THREAD_INFO(%r10) -+ mov TI_lowest_stack(%r10), %rdi ++ GET_THREAD_INFO(%r11) ++ mov TI_lowest_stack(%r11), %rdi + mov $-0xBEEF, %rax + std + @@ -14829,11 +15916,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k + shr $3, %ecx + rep stosq + -+ mov TI_task_thread_sp0(%r10), %rdi ++ mov TI_task_thread_sp0(%r11), %rdi + sub $256, %rdi -+ mov %rdi, TI_lowest_stack(%r10) ++ mov %rdi, TI_lowest_stack(%r11) + -+ popq %r10 ++ popq %r11 + popq %rax + popq %rdi + pax_force_retaddr @@ -14843,7 +15930,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 .macro TRACE_IRQS_IRETQ offset=3DARGOFFSET #ifdef CONFIG_TRACE_IRQFLAGS -@@ -317,7 +588,7 @@ ENTRY(save_args) +@@ -317,7 +601,7 @@ ENTRY(save_args) leaq -ARGOFFSET+16(%rsp),%rdi /* arg1 for handler */ movq_cfi rbp, 8 /* push %rbp */ leaq 8(%rsp), %rbp /* mov %rsp, %ebp */ @@ -14852,7 +15939,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k je 1f SWAPGS /* -@@ -337,9 +608,10 @@ ENTRY(save_args) +@@ -337,9 +621,10 @@ ENTRY(save_args) * We entered an interrupt context - irqs are off: */ 2: TRACE_IRQS_OFF @@ -14864,7 +15951,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 ENTRY(save_rest) PARTIAL_FRAME 1 REST_SKIP+8 -@@ -352,9 +624,10 @@ ENTRY(save_rest) +@@ -352,9 +637,10 @@ ENTRY(save_rest) movq_cfi r15, R15+16 movq %r11, 8(%rsp) /* return address */ FIXUP_TOP_OF_STACK %r11, 16 @@ -14876,12 +15963,12 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k =20 /* save complete stack frame */ .pushsection .kprobes.text, "ax" -@@ -383,9 +656,10 @@ ENTRY(save_paranoid) +@@ -383,9 +669,10 @@ ENTRY(save_paranoid) js 1f /* negative -> in kernel */ SWAPGS xorl %ebx,%ebx -1: ret -+1: pax_force_retaddr ++1: pax_force_retaddr_bts + ret CFI_ENDPROC -END(save_paranoid) @@ -14889,7 +15976,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .popsection =20 /* -@@ -409,7 +683,7 @@ ENTRY(ret_from_fork) +@@ -409,7 +696,7 @@ ENTRY(ret_from_fork) =20 RESTORE_REST =20 @@ -14898,7 +15985,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k je int_ret_from_sys_call =20 testl $_TIF_IA32, TI_flags(%rcx) # 32-bit compat task needs IRET -@@ -419,7 +693,7 @@ ENTRY(ret_from_fork) +@@ -419,7 +706,7 @@ ENTRY(ret_from_fork) jmp ret_from_sys_call # go to the SYSRET fastpath =20 CFI_ENDPROC @@ -14907,7 +15994,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * System call entry. Upto 6 arguments in registers are supported. -@@ -455,7 +729,7 @@ END(ret_from_fork) +@@ -455,7 +742,7 @@ END(ret_from_fork) ENTRY(system_call) CFI_STARTPROC simple CFI_SIGNAL_FRAME @@ -14916,10 +16003,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k CFI_REGISTER rip,rcx /*CFI_REGISTER rflags,r11*/ SWAPGS_UNSAFE_STACK -@@ -468,12 +742,13 @@ ENTRY(system_call_after_swapgs) +@@ -468,12 +755,13 @@ ENTRY(system_call_after_swapgs) =20 movq %rsp,PER_CPU_VAR(old_rsp) movq PER_CPU_VAR(kernel_stack),%rsp ++ SAVE_ARGS 8*6,1 + pax_enter_kernel_user /* * No need to follow this irqs off/on section - it's straight @@ -14927,11 +16015,19 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k */ ENABLE_INTERRUPTS(CLBR_NONE) - SAVE_ARGS 8,1 -+ SAVE_ARGS 8*6,1 movq %rax,ORIG_RAX-ARGOFFSET(%rsp) movq %rcx,RIP-ARGOFFSET(%rsp) CFI_REL_OFFSET rip,RIP-ARGOFFSET -@@ -502,6 +777,8 @@ sysret_check: +@@ -483,7 +771,7 @@ ENTRY(system_call_after_swapgs) + system_call_fastpath: + cmpq $__NR_syscall_max,%rax + ja badsys +- movq %r10,%rcx ++ movq R10-ARGOFFSET(%rsp),%rcx + call *sys_call_table(,%rax,8) # XXX: rip relative + movq %rax,RAX-ARGOFFSET(%rsp) + /* +@@ -502,6 +790,8 @@ sysret_check: andl %edi,%edx jnz sysret_careful CFI_REMEMBER_STATE @@ -14940,7 +16036,15 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry= _64.S linux-2.6.32.49/arch/x86/k /* * sysretq will re-enable interrupts: */ -@@ -562,6 +839,9 @@ auditsys: +@@ -555,14 +845,18 @@ badsys: + * jump back to the normal fast path. + */ + auditsys: +- movq %r10,%r9 /* 6th arg: 4th syscall arg */ ++ movq R10-ARGOFFSET(%rsp),%r9 /* 6th arg: 4th syscall arg */ + movq %rdx,%r8 /* 5th arg: 3rd syscall arg */ + movq %rsi,%rcx /* 4th arg: 2nd syscall arg */ + movq %rdi,%rdx /* 3rd arg: 1st syscall arg */ movq %rax,%rsi /* 2nd arg: syscall number */ movl $AUDIT_ARCH_X86_64,%edi /* 1st arg: audit arch */ call audit_syscall_entry @@ -14948,9 +16052,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry= _64.S linux-2.6.32.49/arch/x86/k + pax_erase_kstack + LOAD_ARGS 0 /* reload call-clobbered registers */ ++ pax_set_fptr_mask jmp system_call_fastpath =20 -@@ -592,6 +872,9 @@ tracesys: + /* +@@ -592,16 +886,20 @@ tracesys: FIXUP_TOP_OF_STACK %rdi movq %rsp,%rdi call syscall_trace_enter @@ -14960,7 +16066,19 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry= _64.S linux-2.6.32.49/arch/x86/k /* * Reload arg registers from stack in case ptrace changed them. * We don't reload %rax because syscall_trace_enter() returned -@@ -613,7 +896,7 @@ tracesys: + * the value it wants us to use in the table lookup. + */ + LOAD_ARGS ARGOFFSET, 1 ++ pax_set_fptr_mask + RESTORE_REST + cmpq $__NR_syscall_max,%rax + ja int_ret_from_sys_call /* RAX(%rsp) set to -ENOSYS above */ +- movq %r10,%rcx /* fixup for C */ ++ movq R10-ARGOFFSET(%rsp),%rcx /* fixup for C */ + call *sys_call_table(,%rax,8) + movq %rax,RAX-ARGOFFSET(%rsp) + /* Use IRET because user could have changed frame */ +@@ -613,7 +911,7 @@ tracesys: GLOBAL(int_ret_from_sys_call) DISABLE_INTERRUPTS(CLBR_NONE) TRACE_IRQS_OFF @@ -14969,7 +16087,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k je retint_restore_args movl $_TIF_ALLWORK_MASK,%edi /* edi: mask to check */ -@@ -674,7 +957,7 @@ int_restore_rest: +@@ -674,7 +972,7 @@ int_restore_rest: TRACE_IRQS_OFF jmp int_with_check CFI_ENDPROC @@ -14978,7 +16096,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * Certain special system calls that need to save a complete full stack= frame. -@@ -690,7 +973,7 @@ ENTRY(\label) +@@ -690,7 +988,7 @@ ENTRY(\label) call \func jmp ptregscall_common CFI_ENDPROC @@ -14987,7 +16105,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .endm =20 PTREGSCALL stub_clone, sys_clone, %r8 -@@ -708,9 +991,10 @@ ENTRY(ptregscall_common) +@@ -708,9 +1006,10 @@ ENTRY(ptregscall_common) movq_cfi_restore R12+8, r12 movq_cfi_restore RBP+8, rbp movq_cfi_restore RBX+8, rbx @@ -14999,7 +16117,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 ENTRY(stub_execve) CFI_STARTPROC -@@ -726,7 +1010,7 @@ ENTRY(stub_execve) +@@ -726,7 +1025,7 @@ ENTRY(stub_execve) RESTORE_REST jmp int_ret_from_sys_call CFI_ENDPROC @@ -15008,7 +16126,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * sigreturn is special because it needs to restore all registers on re= turn. -@@ -744,7 +1028,7 @@ ENTRY(stub_rt_sigreturn) +@@ -744,7 +1043,7 @@ ENTRY(stub_rt_sigreturn) RESTORE_REST jmp int_ret_from_sys_call CFI_ENDPROC @@ -15017,7 +16135,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * Build the entry stubs and pointer table with some assembler magic. -@@ -780,7 +1064,7 @@ vector=3Dvector+1 +@@ -780,7 +1079,7 @@ vector=3Dvector+1 2: jmp common_interrupt .endr CFI_ENDPROC @@ -15026,7 +16144,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 .previous END(interrupt) -@@ -800,6 +1084,16 @@ END(interrupt) +@@ -800,6 +1099,16 @@ END(interrupt) CFI_ADJUST_CFA_OFFSET 10*8 call save_args PARTIAL_FRAME 0 @@ -15043,7 +16161,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k call \func .endm =20 -@@ -822,7 +1116,7 @@ ret_from_intr: +@@ -822,7 +1131,7 @@ ret_from_intr: CFI_ADJUST_CFA_OFFSET -8 exit_intr: GET_THREAD_INFO(%rcx) @@ -15052,7 +16170,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k je retint_kernel =20 /* Interrupt came from user space */ -@@ -844,12 +1138,16 @@ retint_swapgs: /* return to user-space=20 +@@ -844,12 +1153,16 @@ retint_swapgs: /* return to user-space */ * The iretq could re-enable interrupts: */ DISABLE_INTERRUPTS(CLBR_ANY) @@ -15069,7 +16187,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k /* * The iretq could re-enable interrupts: */ -@@ -940,7 +1238,7 @@ ENTRY(retint_kernel) +@@ -940,7 +1253,7 @@ ENTRY(retint_kernel) #endif =20 CFI_ENDPROC @@ -15078,7 +16196,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * APIC interrupts. -@@ -953,7 +1251,7 @@ ENTRY(\sym) +@@ -953,7 +1266,7 @@ ENTRY(\sym) interrupt \do_sym jmp ret_from_intr CFI_ENDPROC @@ -15087,7 +16205,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .endm =20 #ifdef CONFIG_SMP -@@ -1032,12 +1330,22 @@ ENTRY(\sym) +@@ -1032,12 +1345,22 @@ ENTRY(\sym) CFI_ADJUST_CFA_OFFSET 15*8 call error_entry DEFAULT_FRAME 0 @@ -15111,7 +16229,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .endm =20 .macro paranoidzeroentry sym do_sym -@@ -1049,12 +1357,22 @@ ENTRY(\sym) +@@ -1049,12 +1372,22 @@ ENTRY(\sym) subq $15*8, %rsp call save_paranoid TRACE_IRQS_OFF @@ -15135,7 +16253,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .endm =20 .macro paranoidzeroentry_ist sym do_sym ist -@@ -1066,15 +1384,30 @@ ENTRY(\sym) +@@ -1066,15 +1399,30 @@ ENTRY(\sym) subq $15*8, %rsp call save_paranoid TRACE_IRQS_OFF @@ -15168,7 +16286,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .endm =20 .macro errorentry sym do_sym -@@ -1085,13 +1418,23 @@ ENTRY(\sym) +@@ -1085,13 +1433,23 @@ ENTRY(\sym) CFI_ADJUST_CFA_OFFSET 15*8 call error_entry DEFAULT_FRAME 0 @@ -15193,7 +16311,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .endm =20 /* error code is on the stack already */ -@@ -1104,13 +1447,23 @@ ENTRY(\sym) +@@ -1104,13 +1462,23 @@ ENTRY(\sym) call save_paranoid DEFAULT_FRAME 0 TRACE_IRQS_OFF @@ -15218,7 +16336,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k .endm =20 zeroentry divide_error do_divide_error -@@ -1141,9 +1494,10 @@ gs_change: +@@ -1141,9 +1509,10 @@ gs_change: SWAPGS popf CFI_ADJUST_CFA_OFFSET -8 @@ -15230,7 +16348,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 .section __ex_table,"a" .align 8 -@@ -1195,9 +1549,10 @@ ENTRY(kernel_thread) +@@ -1195,9 +1564,10 @@ ENTRY(kernel_thread) */ RESTORE_ALL UNFAKE_STACK_FRAME @@ -15242,7 +16360,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 ENTRY(child_rip) pushq $0 # fake return address -@@ -1208,13 +1563,14 @@ ENTRY(child_rip) +@@ -1208,13 +1578,14 @@ ENTRY(child_rip) */ movq %rdi, %rax movq %rsi, %rdi @@ -15258,7 +16376,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * execve(). This function needs to use IRET, not SYSRET, to set up all= state properly. -@@ -1243,9 +1599,10 @@ ENTRY(kernel_execve) +@@ -1243,9 +1614,10 @@ ENTRY(kernel_execve) je int_ret_from_sys_call RESTORE_ARGS UNFAKE_STACK_FRAME @@ -15270,7 +16388,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* Call softirq on interrupt stack. Interrupts are off. */ ENTRY(call_softirq) -@@ -1263,9 +1620,10 @@ ENTRY(call_softirq) +@@ -1263,9 +1635,10 @@ ENTRY(call_softirq) CFI_DEF_CFA_REGISTER rsp CFI_ADJUST_CFA_OFFSET -8 decl PER_CPU_VAR(irq_count) @@ -15282,7 +16400,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 #ifdef CONFIG_XEN zeroentry xen_hypervisor_callback xen_do_hypervisor_callback -@@ -1303,7 +1661,7 @@ ENTRY(xen_do_hypervisor_callback) # do +@@ -1303,7 +1676,7 @@ ENTRY(xen_do_hypervisor_callback) # do_hyperviso= r_callback(struct *pt_regs) decl PER_CPU_VAR(irq_count) jmp error_exit CFI_ENDPROC @@ -15291,7 +16409,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * Hypervisor uses this for application faults while it executes. -@@ -1362,7 +1720,7 @@ ENTRY(xen_failsafe_callback) +@@ -1362,7 +1735,7 @@ ENTRY(xen_failsafe_callback) SAVE_ALL jmp error_exit CFI_ENDPROC @@ -15300,7 +16418,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 #endif /* CONFIG_XEN */ =20 -@@ -1405,16 +1763,31 @@ ENTRY(paranoid_exit) +@@ -1405,16 +1778,31 @@ ENTRY(paranoid_exit) TRACE_IRQS_OFF testl %ebx,%ebx /* swapgs needed? */ jnz paranoid_restore @@ -15312,7 +16430,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k + TRACE_IRQS_IRETQ 0 + SWAPGS_UNSAFE_STACK + RESTORE_ALL 8 -+ pax_force_retaddr ++ pax_force_retaddr_bts + jmp irq_return +#endif paranoid_swapgs: @@ -15329,11 +16447,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k + pax_exit_kernel TRACE_IRQS_IRETQ 0 RESTORE_ALL 8 -+ pax_force_retaddr ++ pax_force_retaddr_bts jmp irq_return paranoid_userspace: GET_THREAD_INFO(%rcx) -@@ -1443,7 +1816,7 @@ paranoid_schedule: +@@ -1443,7 +1831,7 @@ paranoid_schedule: TRACE_IRQS_OFF jmp paranoid_userspace CFI_ENDPROC @@ -15342,7 +16460,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 /* * Exception entry point. This expects an error code/orig_rax on the st= ack. -@@ -1470,12 +1843,13 @@ ENTRY(error_entry) +@@ -1470,12 +1858,13 @@ ENTRY(error_entry) movq_cfi r14, R14+8 movq_cfi r15, R15+8 xorl %ebx,%ebx @@ -15353,11 +16471,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k SWAPGS error_sti: TRACE_IRQS_OFF -+ pax_force_retaddr ++ pax_force_retaddr_bts ret CFI_ENDPROC =20 -@@ -1497,7 +1871,7 @@ error_kernelspace: +@@ -1497,7 +1886,7 @@ error_kernelspace: cmpq $gs_change,RIP+8(%rsp) je error_swapgs jmp error_sti @@ -15366,7 +16484,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 =20 /* ebx: no swapgs flag (1: don't need swapgs, 0: need it) */ -@@ -1517,7 +1891,7 @@ ENTRY(error_exit) +@@ -1517,7 +1906,7 @@ ENTRY(error_exit) jnz retint_careful jmp retint_swapgs CFI_ENDPROC @@ -15375,7 +16493,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k =20 =20 /* runs on exception stack */ -@@ -1529,6 +1903,16 @@ ENTRY(nmi) +@@ -1529,6 +1918,16 @@ ENTRY(nmi) CFI_ADJUST_CFA_OFFSET 15*8 call save_paranoid DEFAULT_FRAME 0 @@ -15392,7 +16510,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k /* paranoidentry do_nmi, 0; without TRACE_IRQS_OFF */ movq %rsp,%rdi movq $-1,%rsi -@@ -1539,12 +1923,28 @@ ENTRY(nmi) +@@ -1539,12 +1938,28 @@ ENTRY(nmi) DISABLE_INTERRUPTS(CLBR_NONE) testl %ebx,%ebx /* swapgs needed? */ jnz nmi_restore @@ -15403,7 +16521,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entry_= 64.S linux-2.6.32.49/arch/x86/k + pax_exit_kernel + SWAPGS_UNSAFE_STACK + RESTORE_ALL 8 -+ pax_force_retaddr ++ pax_force_retaddr_bts + jmp irq_return +#endif nmi_swapgs: @@ -15418,11 +16536,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k nmi_restore: + pax_exit_kernel RESTORE_ALL 8 -+ pax_force_retaddr ++ pax_force_retaddr_bts jmp irq_return nmi_userspace: GET_THREAD_INFO(%rcx) -@@ -1573,14 +1973,14 @@ nmi_schedule: +@@ -1573,14 +1988,14 @@ nmi_schedule: jmp paranoid_exit CFI_ENDPROC #endif @@ -15439,10 +16557,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/entr= y_64.S linux-2.6.32.49/arch/x86/k =20 /* * End of kprobes section -diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrace.c linux-2.6.32.49/arch= /x86/kernel/ftrace.c ---- linux-2.6.32.49/arch/x86/kernel/ftrace.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/ftrace.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -103,7 +103,7 @@ static void *mod_code_ip; /* holds the=20 +diff --git a/arch/x86/kernel/ftrace.c b/arch/x86/kernel/ftrace.c +index 9dbb527..7b3615a 100644 +--- a/arch/x86/kernel/ftrace.c ++++ b/arch/x86/kernel/ftrace.c +@@ -103,7 +103,7 @@ static void *mod_code_ip; /* holds the IP to write = to */ static void *mod_code_newcode; /* holds the text to write to the IP */ =20 static unsigned nmi_wait_count; @@ -15451,7 +16570,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrace= .c linux-2.6.32.49/arch/x86/ker =20 int ftrace_arch_read_dyn_info(char *buf, int size) { -@@ -111,7 +111,7 @@ int ftrace_arch_read_dyn_info(char *buf, +@@ -111,7 +111,7 @@ int ftrace_arch_read_dyn_info(char *buf, int size) =20 r =3D snprintf(buf, size, "%u %u", nmi_wait_count, @@ -15472,7 +16591,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrace= .c linux-2.6.32.49/arch/x86/ker } /* Must have previous changes seen before executions */ smp_mb(); -@@ -215,7 +217,7 @@ do_ftrace_mod_code(unsigned long ip, voi +@@ -215,7 +217,7 @@ do_ftrace_mod_code(unsigned long ip, void *new_code) =20 =20 =20 @@ -15481,7 +16600,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrace= .c linux-2.6.32.49/arch/x86/ker =20 static unsigned char *ftrace_nop_replace(void) { -@@ -228,6 +230,8 @@ ftrace_modify_code(unsigned long ip, uns +@@ -228,6 +230,8 @@ ftrace_modify_code(unsigned long ip, unsigned char *= old_code, { unsigned char replaced[MCOUNT_INSN_SIZE]; =20 @@ -15490,7 +16609,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrace= .c linux-2.6.32.49/arch/x86/ker /* * Note: Due to modules and __init, code can * disappear and change, we need to protect against faulting -@@ -284,7 +288,7 @@ int ftrace_update_ftrace_func(ftrace_fun +@@ -284,7 +288,7 @@ int ftrace_update_ftrace_func(ftrace_func_t func) unsigned char old[MCOUNT_INSN_SIZE], *new; int ret; =20 @@ -15499,7 +16618,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrace= .c linux-2.6.32.49/arch/x86/ker new =3D ftrace_call_replace(ip, (unsigned long)func); ret =3D ftrace_modify_code(ip, old, new); =20 -@@ -337,15 +341,15 @@ int __init ftrace_dyn_arch_init(void *da +@@ -337,15 +341,15 @@ int __init ftrace_dyn_arch_init(void *data) switch (faulted) { case 0: pr_info("ftrace: converting mcount calls to 0f 1f 44 00 00\n"); @@ -15518,7 +16637,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrace= .c linux-2.6.32.49/arch/x86/ker break; } =20 -@@ -366,6 +370,8 @@ static int ftrace_mod_jmp(unsigned long=20 +@@ -366,6 +370,8 @@ static int ftrace_mod_jmp(unsigned long ip, { unsigned char code[MCOUNT_INSN_SIZE]; =20 @@ -15527,9 +16646,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ftrac= e.c linux-2.6.32.49/arch/x86/ker if (probe_kernel_read(code, (void *)ip, MCOUNT_INSN_SIZE)) return -EFAULT; =20 -diff -urNp linux-2.6.32.49/arch/x86/kernel/head32.c linux-2.6.32.49/arch= /x86/kernel/head32.c ---- linux-2.6.32.49/arch/x86/kernel/head32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/head32.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/kernel/head32.c b/arch/x86/kernel/head32.c +index 4f8e250..df24706 100644 +--- a/arch/x86/kernel/head32.c ++++ b/arch/x86/kernel/head32.c @@ -16,6 +16,7 @@ #include #include @@ -15547,9 +16667,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head3= 2.c linux-2.6.32.49/arch/x86/ker =20 #ifdef CONFIG_BLK_DEV_INITRD /* Reserve INITRD */ -diff -urNp linux-2.6.32.49/arch/x86/kernel/head_32.S linux-2.6.32.49/arc= h/x86/kernel/head_32.S ---- linux-2.6.32.49/arch/x86/kernel/head_32.S 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/head_32.S 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/arch/x86/kernel/head_32.S b/arch/x86/kernel/head_32.S +index 34c3308..6fc4e76 100644 +--- a/arch/x86/kernel/head_32.S ++++ b/arch/x86/kernel/head_32.S @@ -19,10 +19,17 @@ #include #include @@ -15581,7 +16702,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_3= 2.S linux-2.6.32.49/arch/x86/ke =20 /* Enough space to fit pagetables for the low memory linear map */ MAPPING_BEYOND_END =3D \ -@@ -73,6 +76,12 @@ INIT_MAP_SIZE =3D PAGE_TABLE_SIZE(KERNEL_P +@@ -73,6 +76,12 @@ INIT_MAP_SIZE =3D PAGE_TABLE_SIZE(KERNEL_PAGES) * PAG= E_SIZE_asm RESERVE_BRK(pagetables, INIT_MAP_SIZE) =20 /* @@ -16071,18 +17192,20 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head= _32.S linux-2.6.32.49/arch/x86/ke + /* Be sure this is zeroed to avoid false validations in Xen */ + .fill PAGE_SIZE_asm - GDT_SIZE,1,0 + .endr -diff -urNp linux-2.6.32.49/arch/x86/kernel/head_64.S linux-2.6.32.49/arc= h/x86/kernel/head_64.S ---- linux-2.6.32.49/arch/x86/kernel/head_64.S 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/head_64.S 2011-11-15 19:59:43.000000= 000 -0500 -@@ -19,6 +19,7 @@ +diff --git a/arch/x86/kernel/head_64.S b/arch/x86/kernel/head_64.S +index 780cd92..564ca35 100644 +--- a/arch/x86/kernel/head_64.S ++++ b/arch/x86/kernel/head_64.S +@@ -19,6 +19,8 @@ #include #include #include +#include ++#include =20 #ifdef CONFIG_PARAVIRT #include -@@ -38,6 +39,10 @@ L4_PAGE_OFFSET =3D pgd_index(__PAGE_OFFSET +@@ -38,6 +40,10 @@ L4_PAGE_OFFSET =3D pgd_index(__PAGE_OFFSET) L3_PAGE_OFFSET =3D pud_index(__PAGE_OFFSET) L4_START_KERNEL =3D pgd_index(__START_KERNEL_map) L3_START_KERNEL =3D pud_index(__START_KERNEL_map) @@ -16093,7 +17216,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_6= 4.S linux-2.6.32.49/arch/x86/ke =20 .text __HEAD -@@ -85,35 +90,22 @@ startup_64: +@@ -85,35 +91,22 @@ startup_64: */ addq %rbp, init_level4_pgt + 0(%rip) addq %rbp, init_level4_pgt + (L4_PAGE_OFFSET*8)(%rip) @@ -16108,12 +17231,9 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_= 64.S linux-2.6.32.49/arch/x86/ke =20 - addq %rbp, level3_kernel_pgt + (510*8)(%rip) - addq %rbp, level3_kernel_pgt + (511*8)(%rip) -+ addq %rbp, level3_vmemmap_pgt + (L3_VMEMMAP_START*8)(%rip) -=20 +- - addq %rbp, level2_fixmap_pgt + (506*8)(%rip) -+ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8)(%rip) -+ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8+8)(%rip) -=20 +- - /* Add an Identity mapping if I am above 1G */ - leaq _text(%rip), %rdi - andq $PMD_PAGE_MASK, %rdi @@ -16122,11 +17242,14 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head= _64.S linux-2.6.32.49/arch/x86/ke - shrq $PUD_SHIFT, %rax - andq $(PTRS_PER_PUD - 1), %rax - jz ident_complete -- ++ addq %rbp, level3_vmemmap_pgt + (L3_VMEMMAP_START*8)(%rip) +=20 - leaq (level2_spare_pgt - __START_KERNEL_map + _KERNPG_TABLE)(%rbp), %r= dx - leaq level3_ident_pgt(%rip), %rbx - movq %rdx, 0(%rbx, %rax, 8) -- ++ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8)(%rip) ++ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8+8)(%rip) +=20 - movq %rdi, %rax - shrq $PMD_SHIFT, %rax - andq $(PTRS_PER_PMD - 1), %rax @@ -16139,7 +17262,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_6= 4.S linux-2.6.32.49/arch/x86/ke =20 /* * Fixup the kernel text+data virtual addresses. Note that -@@ -161,8 +153,8 @@ ENTRY(secondary_startup_64) +@@ -161,8 +154,8 @@ ENTRY(secondary_startup_64) * after the boot processor executes this code. */ =20 @@ -16150,7 +17273,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_6= 4.S linux-2.6.32.49/arch/x86/ke movq %rax, %cr4 =20 /* Setup early boot stage 4 level pagetables. */ -@@ -184,9 +176,13 @@ ENTRY(secondary_startup_64) +@@ -184,9 +177,15 @@ ENTRY(secondary_startup_64) movl $MSR_EFER, %ecx rdmsr btsl $_EFER_SCE, %eax /* Enable System Call */ @@ -16159,13 +17282,23 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head= _64.S linux-2.6.32.49/arch/x86/ke jnc 1f btsl $_EFER_NX, %eax + leaq init_level4_pgt(%rip), %rdi ++#ifndef CONFIG_EFI + btsq $_PAGE_BIT_NX, 8*L4_PAGE_OFFSET(%rdi) ++#endif + btsq $_PAGE_BIT_NX, 8*L4_VMALLOC_START(%rdi) + btsq $_PAGE_BIT_NX, 8*L4_VMEMMAP_START(%rdi) 1: wrmsr /* Make changes effective */ =20 /* Setup cr0 */ -@@ -262,16 +258,16 @@ ENTRY(secondary_startup_64) +@@ -249,6 +248,7 @@ ENTRY(secondary_startup_64) + * jump. In addition we need to ensure %cs is set so we make this + * a far return. + */ ++ pax_set_fptr_mask + movq initial_code(%rip),%rax + pushq $0 # fake return address to stop unwinder + pushq $__KERNEL_CS # set correct cs +@@ -262,16 +262,16 @@ ENTRY(secondary_startup_64) .quad x86_64_start_kernel ENTRY(initial_gs) .quad INIT_PER_CPU_VAR(irq_stack_union) @@ -16184,7 +17317,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_6= 4.S linux-2.6.32.49/arch/x86/ke #ifdef CONFIG_EARLY_PRINTK .globl early_idt_handlers early_idt_handlers: -@@ -316,18 +312,23 @@ ENTRY(early_idt_handler) +@@ -316,18 +316,23 @@ ENTRY(early_idt_handler) #endif /* EARLY_PRINTK */ 1: hlt jmp 1b @@ -16209,7 +17342,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_6= 4.S linux-2.6.32.49/arch/x86/ke #define NEXT_PAGE(name) \ .balign PAGE_SIZE; \ ENTRY(name) -@@ -350,13 +351,36 @@ NEXT_PAGE(init_level4_pgt) +@@ -350,13 +355,36 @@ NEXT_PAGE(init_level4_pgt) .quad level3_ident_pgt - __START_KERNEL_map + _KERNPG_TABLE .org init_level4_pgt + L4_PAGE_OFFSET*8, 0 .quad level3_ident_pgt - __START_KERNEL_map + _KERNPG_TABLE @@ -16246,7 +17379,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_6= 4.S linux-2.6.32.49/arch/x86/ke =20 NEXT_PAGE(level3_kernel_pgt) .fill L3_START_KERNEL,8,0 -@@ -364,20 +388,23 @@ NEXT_PAGE(level3_kernel_pgt) +@@ -364,20 +392,23 @@ NEXT_PAGE(level3_kernel_pgt) .quad level2_kernel_pgt - __START_KERNEL_map + _KERNPG_TABLE .quad level2_fixmap_pgt - __START_KERNEL_map + _PAGE_TABLE =20 @@ -16278,7 +17411,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_6= 4.S linux-2.6.32.49/arch/x86/ke =20 NEXT_PAGE(level2_kernel_pgt) /* -@@ -390,33 +417,55 @@ NEXT_PAGE(level2_kernel_pgt) +@@ -390,33 +421,55 @@ NEXT_PAGE(level2_kernel_pgt) * If you want to increase this then increase MODULES_VADDR * too.) */ @@ -16344,9 +17477,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/head_= 64.S linux-2.6.32.49/arch/x86/ke =20 __PAGE_ALIGNED_BSS .align PAGE_SIZE -diff -urNp linux-2.6.32.49/arch/x86/kernel/i386_ksyms_32.c linux-2.6.32.= 49/arch/x86/kernel/i386_ksyms_32.c ---- linux-2.6.32.49/arch/x86/kernel/i386_ksyms_32.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/i386_ksyms_32.c 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/arch/x86/kernel/i386_ksyms_32.c b/arch/x86/kernel/i386_ksym= s_32.c +index 9c3bd4a..e1d9b35 100644 +--- a/arch/x86/kernel/i386_ksyms_32.c ++++ b/arch/x86/kernel/i386_ksyms_32.c @@ -20,8 +20,12 @@ extern void cmpxchg8b_emu(void); EXPORT_SYMBOL(cmpxchg8b_emu); #endif @@ -16368,9 +17502,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/i386_= ksyms_32.c linux-2.6.32.49/arch/ +#ifdef CONFIG_PAX_KERNEXEC +EXPORT_SYMBOL(__LOAD_PHYSICAL_ADDR); +#endif -diff -urNp linux-2.6.32.49/arch/x86/kernel/i8259.c linux-2.6.32.49/arch/= x86/kernel/i8259.c ---- linux-2.6.32.49/arch/x86/kernel/i8259.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/i8259.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/kernel/i8259.c b/arch/x86/kernel/i8259.c +index df89102..a244320 100644 +--- a/arch/x86/kernel/i8259.c ++++ b/arch/x86/kernel/i8259.c @@ -208,7 +208,7 @@ spurious_8259A_irq: "spurious 8259A interrupt: IRQ%d.\n", irq); spurious_irq_mask |=3D irqmask; @@ -16380,10 +17515,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/i825= 9.c linux-2.6.32.49/arch/x86/kern /* * Theoretically we do not have to handle this IRQ, * but in Linux this does not cause problems and is -diff -urNp linux-2.6.32.49/arch/x86/kernel/init_task.c linux-2.6.32.49/a= rch/x86/kernel/init_task.c ---- linux-2.6.32.49/arch/x86/kernel/init_task.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/init_task.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -20,8 +20,7 @@ static struct sighand_struct init_sighan +diff --git a/arch/x86/kernel/init_task.c b/arch/x86/kernel/init_task.c +index 3a54dcb..1c22348 100644 +--- a/arch/x86/kernel/init_task.c ++++ b/arch/x86/kernel/init_task.c +@@ -20,8 +20,7 @@ static struct sighand_struct init_sighand =3D INIT_SIG= HAND(init_sighand); * way process stacks are handled. This is done by having a special * "init_task" linker map entry.. */ @@ -16401,9 +17537,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/init_= task.c linux-2.6.32.49/arch/x86/ - +struct tss_struct init_tss[NR_CPUS] ____cacheline_internodealigned_in_s= mp =3D { [0 ... NR_CPUS-1] =3D INIT_TSS }; +EXPORT_SYMBOL(init_tss); -diff -urNp linux-2.6.32.49/arch/x86/kernel/ioport.c linux-2.6.32.49/arch= /x86/kernel/ioport.c ---- linux-2.6.32.49/arch/x86/kernel/ioport.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/ioport.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/kernel/ioport.c b/arch/x86/kernel/ioport.c +index 99c4d30..74c84e9 100644 +--- a/arch/x86/kernel/ioport.c ++++ b/arch/x86/kernel/ioport.c @@ -6,6 +6,7 @@ #include #include @@ -16412,7 +17549,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ioport= .c linux-2.6.32.49/arch/x86/ker #include #include #include -@@ -41,6 +42,12 @@ asmlinkage long sys_ioperm(unsigned long +@@ -41,6 +42,12 @@ asmlinkage long sys_ioperm(unsigned long from, unsign= ed long num, int turn_on) =20 if ((from + num <=3D from) || (from + num > IO_BITMAP_BITS)) return -EINVAL; @@ -16425,7 +17562,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ioport= .c linux-2.6.32.49/arch/x86/ker if (turn_on && !capable(CAP_SYS_RAWIO)) return -EPERM; =20 -@@ -67,7 +74,7 @@ asmlinkage long sys_ioperm(unsigned long +@@ -67,7 +74,7 @@ asmlinkage long sys_ioperm(unsigned long from, unsigne= d long num, int turn_on) * because the ->io_bitmap_max value must match the bitmap * contents: */ @@ -16434,7 +17571,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ioport= .c linux-2.6.32.49/arch/x86/ker =20 set_bitmap(t->io_bitmap_ptr, from, num, !turn_on); =20 -@@ -111,6 +118,12 @@ static int do_iopl(unsigned int level, s +@@ -111,6 +118,12 @@ static int do_iopl(unsigned int level, struct pt_re= gs *regs) return -EINVAL; /* Trying to gain more privileges? */ if (level > old) { @@ -16447,9 +17584,48 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/iopor= t.c linux-2.6.32.49/arch/x86/ker if (!capable(CAP_SYS_RAWIO)) return -EPERM; } -diff -urNp linux-2.6.32.49/arch/x86/kernel/irq_32.c linux-2.6.32.49/arch= /x86/kernel/irq_32.c ---- linux-2.6.32.49/arch/x86/kernel/irq_32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/irq_32.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c +index 04bbd52..83a07d9 100644 +--- a/arch/x86/kernel/irq.c ++++ b/arch/x86/kernel/irq.c +@@ -15,7 +15,7 @@ + #include + #include +=20 +-atomic_t irq_err_count; ++atomic_unchecked_t irq_err_count; +=20 + /* Function pointer for generic interrupt vector handling */ + void (*generic_interrupt_extension)(void) =3D NULL; +@@ -114,9 +114,9 @@ static int show_other_interrupts(struct seq_file *p,= int prec) + seq_printf(p, "%10u ", per_cpu(mce_poll_count, j)); + seq_printf(p, " Machine check polls\n"); + #endif +- seq_printf(p, "%*s: %10u\n", prec, "ERR", atomic_read(&irq_err_count))= ; ++ seq_printf(p, "%*s: %10u\n", prec, "ERR", atomic_read_unchecked(&irq_e= rr_count)); + #if defined(CONFIG_X86_IO_APIC) +- seq_printf(p, "%*s: %10u\n", prec, "MIS", atomic_read(&irq_mis_count))= ; ++ seq_printf(p, "%*s: %10u\n", prec, "MIS", atomic_read_unchecked(&irq_m= is_count)); + #endif + return 0; + } +@@ -209,10 +209,10 @@ u64 arch_irq_stat_cpu(unsigned int cpu) +=20 + u64 arch_irq_stat(void) + { +- u64 sum =3D atomic_read(&irq_err_count); ++ u64 sum =3D atomic_read_unchecked(&irq_err_count); +=20 + #ifdef CONFIG_X86_IO_APIC +- sum +=3D atomic_read(&irq_mis_count); ++ sum +=3D atomic_read_unchecked(&irq_mis_count); + #endif + return sum; + } +diff --git a/arch/x86/kernel/irq_32.c b/arch/x86/kernel/irq_32.c +index 7d35d0f..03f1d52 100644 +--- a/arch/x86/kernel/irq_32.c ++++ b/arch/x86/kernel/irq_32.c @@ -35,7 +35,7 @@ static int check_stack_overflow(void) __asm__ __volatile__("andl %%esp,%0" : "=3Dr" (sp) : "0" (THREAD_SIZE - 1)); @@ -16459,7 +17635,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/irq_32= .c linux-2.6.32.49/arch/x86/ker } =20 static void print_stack_overflow(void) -@@ -54,9 +54,9 @@ static inline void print_stack_overflow( +@@ -54,9 +54,9 @@ static inline void print_stack_overflow(void) { } * per-CPU IRQ handling contexts (thread information and stack) */ union irq_ctx { @@ -16472,7 +17648,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/irq_32= .c linux-2.6.32.49/arch/x86/ker =20 static DEFINE_PER_CPU(union irq_ctx *, hardirq_ctx); static DEFINE_PER_CPU(union irq_ctx *, softirq_ctx); -@@ -78,10 +78,9 @@ static void call_on_stack(void *func, vo +@@ -78,10 +78,9 @@ static void call_on_stack(void *func, void *stack) static inline int execute_on_irq_stack(int overflow, struct irq_desc *desc, int irq) { @@ -16484,7 +17660,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/irq_32= .c linux-2.6.32.49/arch/x86/ker irqctx =3D __get_cpu_var(hardirq_ctx); =20 /* -@@ -90,21 +89,16 @@ execute_on_irq_stack(int overflow, struc +@@ -90,21 +89,16 @@ execute_on_irq_stack(int overflow, struct irq_desc *= desc, int irq) * handler) we can't do that and just have to keep using the * current stack (which is the irq stack already after all) */ @@ -16512,7 +17688,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/irq_32= .c linux-2.6.32.49/arch/x86/ker =20 if (unlikely(overflow)) call_on_stack(print_stack_overflow, isp); -@@ -116,6 +110,11 @@ execute_on_irq_stack(int overflow, struc +@@ -116,6 +110,11 @@ execute_on_irq_stack(int overflow, struct irq_desc = *desc, int irq) : "0" (irq), "1" (desc), "2" (isp), "D" (desc->handle_irq) : "memory", "cc", "ecx"); @@ -16524,7 +17700,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/irq_32= .c linux-2.6.32.49/arch/x86/ker return 1; } =20 -@@ -124,28 +123,11 @@ execute_on_irq_stack(int overflow, struc +@@ -124,28 +123,11 @@ execute_on_irq_stack(int overflow, struct irq_desc= *desc, int irq) */ void __cpuinit irq_ctx_init(int cpu) { @@ -16590,47 +17766,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/irq_= 32.c linux-2.6.32.49/arch/x86/ker /* * Shouldnt happen, we returned above if in_interrupt(): */ -diff -urNp linux-2.6.32.49/arch/x86/kernel/irq.c linux-2.6.32.49/arch/x8= 6/kernel/irq.c ---- linux-2.6.32.49/arch/x86/kernel/irq.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/kernel/irq.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -15,7 +15,7 @@ - #include - #include -=20 --atomic_t irq_err_count; -+atomic_unchecked_t irq_err_count; -=20 - /* Function pointer for generic interrupt vector handling */ - void (*generic_interrupt_extension)(void) =3D NULL; -@@ -114,9 +114,9 @@ static int show_other_interrupts(struct=20 - seq_printf(p, "%10u ", per_cpu(mce_poll_count, j)); - seq_printf(p, " Machine check polls\n"); - #endif -- seq_printf(p, "%*s: %10u\n", prec, "ERR", atomic_read(&irq_err_count))= ; -+ seq_printf(p, "%*s: %10u\n", prec, "ERR", atomic_read_unchecked(&irq_e= rr_count)); - #if defined(CONFIG_X86_IO_APIC) -- seq_printf(p, "%*s: %10u\n", prec, "MIS", atomic_read(&irq_mis_count))= ; -+ seq_printf(p, "%*s: %10u\n", prec, "MIS", atomic_read_unchecked(&irq_m= is_count)); - #endif - return 0; - } -@@ -209,10 +209,10 @@ u64 arch_irq_stat_cpu(unsigned int cpu) -=20 - u64 arch_irq_stat(void) - { -- u64 sum =3D atomic_read(&irq_err_count); -+ u64 sum =3D atomic_read_unchecked(&irq_err_count); -=20 - #ifdef CONFIG_X86_IO_APIC -- sum +=3D atomic_read(&irq_mis_count); -+ sum +=3D atomic_read_unchecked(&irq_mis_count); - #endif - return sum; - } -diff -urNp linux-2.6.32.49/arch/x86/kernel/kgdb.c linux-2.6.32.49/arch/x= 86/kernel/kgdb.c ---- linux-2.6.32.49/arch/x86/kernel/kgdb.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/kernel/kgdb.c 2011-11-15 19:59:43.000000000= -0500 -@@ -390,13 +390,13 @@ int kgdb_arch_handle_exception(int e_vec +diff --git a/arch/x86/kernel/kgdb.c b/arch/x86/kernel/kgdb.c +index 8d82a77..0baf312 100644 +--- a/arch/x86/kernel/kgdb.c ++++ b/arch/x86/kernel/kgdb.c +@@ -390,13 +390,13 @@ int kgdb_arch_handle_exception(int e_vector, int s= igno, int err_code, =20 /* clear the trace bit */ linux_regs->flags &=3D ~X86_EFLAGS_TF; @@ -16646,7 +17786,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kgdb.c= linux-2.6.32.49/arch/x86/kerne raw_smp_processor_id()); } =20 -@@ -476,7 +476,7 @@ static int __kgdb_notify(struct die_args +@@ -476,7 +476,7 @@ static int __kgdb_notify(struct die_args *args, unsi= gned long cmd) break; =20 case DIE_DEBUG: @@ -16655,7 +17795,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kgdb.c= linux-2.6.32.49/arch/x86/kerne raw_smp_processor_id()) { if (user_mode(regs)) return single_step_cont(regs, args); -@@ -573,7 +573,7 @@ unsigned long kgdb_arch_pc(int exception +@@ -573,7 +573,7 @@ unsigned long kgdb_arch_pc(int exception, struct pt_= regs *regs) return instruction_pointer(regs); } =20 @@ -16664,10 +17804,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kgdb= .c linux-2.6.32.49/arch/x86/kerne /* Breakpoint instruction: */ .gdb_bpt_instr =3D { 0xcc }, .flags =3D KGDB_HW_BREAKPOINT, -diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobes.c linux-2.6.32.49/arc= h/x86/kernel/kprobes.c ---- linux-2.6.32.49/arch/x86/kernel/kprobes.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/kprobes.c 2011-11-18 18:01:52.000000= 000 -0500 -@@ -168,9 +168,13 @@ static void __kprobes set_jmp_op(void *f +diff --git a/arch/x86/kernel/kprobes.c b/arch/x86/kernel/kprobes.c +index 7a67820..8d15b75 100644 +--- a/arch/x86/kernel/kprobes.c ++++ b/arch/x86/kernel/kprobes.c +@@ -168,9 +168,13 @@ static void __kprobes set_jmp_op(void *from, void *= to) char op; s32 raddr; } __attribute__((packed)) * jop; @@ -16682,7 +17823,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke } =20 /* -@@ -195,7 +199,7 @@ static int __kprobes can_boost(kprobe_op +@@ -195,7 +199,7 @@ static int __kprobes can_boost(kprobe_opcode_t *opco= des) kprobe_opcode_t opcode; kprobe_opcode_t *orig_opcodes =3D opcodes; =20 @@ -16691,7 +17832,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke return 0; /* Page fault may occur on this address. */ =20 retry: -@@ -339,7 +343,9 @@ static void __kprobes fix_riprel(struct=20 +@@ -339,7 +343,9 @@ static void __kprobes fix_riprel(struct kprobe *p) disp =3D (u8 *) p->addr + *((s32 *) insn) - (u8 *) p->ainsn.insn; BUG_ON((s64) (s32) disp !=3D disp); /* Sanity check. */ @@ -16701,7 +17842,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke } } #endif -@@ -347,16 +353,18 @@ static void __kprobes fix_riprel(struct=20 +@@ -347,16 +353,18 @@ static void __kprobes fix_riprel(struct kprobe *p) =20 static void __kprobes arch_copy_kprobe(struct kprobe *p) { @@ -16723,7 +17864,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke } =20 int __kprobes arch_prepare_kprobe(struct kprobe *p) -@@ -434,7 +442,7 @@ static void __kprobes prepare_singlestep +@@ -434,7 +442,7 @@ static void __kprobes prepare_singlestep(struct kpro= be *p, struct pt_regs *regs) if (p->opcode =3D=3D BREAKPOINT_INSTRUCTION) regs->ip =3D (unsigned long)p->addr; else @@ -16732,7 +17873,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke } =20 void __kprobes arch_prepare_kretprobe(struct kretprobe_instance *ri, -@@ -455,7 +463,7 @@ static void __kprobes setup_singlestep(s +@@ -455,7 +463,7 @@ static void __kprobes setup_singlestep(struct kprobe= *p, struct pt_regs *regs, if (p->ainsn.boostable =3D=3D 1 && !p->post_handler) { /* Boost up -- we can execute copied instructions directly */ reset_current_kprobe(); @@ -16741,7 +17882,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke preempt_enable_no_resched(); return; } -@@ -525,7 +533,7 @@ static int __kprobes kprobe_handler(stru +@@ -525,7 +533,7 @@ static int __kprobes kprobe_handler(struct pt_regs *= regs) struct kprobe_ctlblk *kcb; =20 addr =3D (kprobe_opcode_t *)(regs->ip - sizeof(kprobe_opcode_t)); @@ -16750,7 +17891,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke /* * The breakpoint instruction was removed right * after we hit it. Another cpu has removed -@@ -637,6 +645,9 @@ static void __used __kprobes kretprobe_t +@@ -637,6 +645,9 @@ static void __used __kprobes kretprobe_trampoline_ho= lder(void) /* Skip orig_ax, ip, cs */ " addq $24, %rsp\n" " popfq\n" @@ -16760,7 +17901,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke #else " pushf\n" /* -@@ -777,7 +788,7 @@ static void __kprobes resume_execution(s +@@ -777,7 +788,7 @@ static void __kprobes resume_execution(struct kprobe= *p, struct pt_regs *regs, struct kprobe_ctlblk *kcb) { unsigned long *tos =3D stack_addr(regs); @@ -16769,7 +17910,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kprobe= s.c linux-2.6.32.49/arch/x86/ke unsigned long orig_ip =3D (unsigned long)p->addr; kprobe_opcode_t *insn =3D p->ainsn.insn; =20 -@@ -960,7 +971,7 @@ int __kprobes kprobe_exceptions_notify(s +@@ -960,7 +971,7 @@ int __kprobes kprobe_exceptions_notify(struct notifi= er_block *self, struct die_args *args =3D data; int ret =3D NOTIFY_DONE; =20 @@ -16778,10 +17919,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kpro= bes.c linux-2.6.32.49/arch/x86/ke return ret; =20 switch (val) { -diff -urNp linux-2.6.32.49/arch/x86/kernel/kvm.c linux-2.6.32.49/arch/x8= 6/kernel/kvm.c ---- linux-2.6.32.49/arch/x86/kernel/kvm.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/kernel/kvm.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -216,6 +216,7 @@ static void __init paravirt_ops_setup(vo +diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c +index 63b0ec8..6d92227 100644 +--- a/arch/x86/kernel/kvm.c ++++ b/arch/x86/kernel/kvm.c +@@ -216,6 +216,7 @@ static void __init paravirt_ops_setup(void) pv_mmu_ops.set_pud =3D kvm_set_pud; #if PAGETABLE_LEVELS =3D=3D 4 pv_mmu_ops.set_pgd =3D kvm_set_pgd; @@ -16789,10 +17931,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/kvm.= c linux-2.6.32.49/arch/x86/kernel #endif #endif pv_mmu_ops.flush_tlb_user =3D kvm_flush_tlb; -diff -urNp linux-2.6.32.49/arch/x86/kernel/ldt.c linux-2.6.32.49/arch/x8= 6/kernel/ldt.c ---- linux-2.6.32.49/arch/x86/kernel/ldt.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/kernel/ldt.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -66,13 +66,13 @@ static int alloc_ldt(mm_context_t *pc, i +diff --git a/arch/x86/kernel/ldt.c b/arch/x86/kernel/ldt.c +index ec6ef60..ab2c824 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) if (reload) { #ifdef CONFIG_SMP preempt_disable(); @@ -16808,7 +17951,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ldt.c = linux-2.6.32.49/arch/x86/kernel #endif } if (oldsize) { -@@ -94,7 +94,7 @@ static inline int copy_ldt(mm_context_t=20 +@@ -94,7 +94,7 @@ static inline int copy_ldt(mm_context_t *new, mm_conte= xt_t *old) return err; =20 for (i =3D 0; i < old->size; i++) @@ -16817,7 +17960,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ldt.c = linux-2.6.32.49/arch/x86/kernel return 0; } =20 -@@ -115,6 +115,24 @@ int init_new_context(struct task_struct=20 +@@ -115,6 +115,24 @@ int init_new_context(struct task_struct *tsk, struc= t mm_struct *mm) retval =3D copy_ldt(&mm->context, &old_mm->context); mutex_unlock(&old_mm->context.lock); } @@ -16842,7 +17985,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ldt.c = linux-2.6.32.49/arch/x86/kernel return retval; } =20 -@@ -229,6 +247,13 @@ static int write_ldt(void __user *ptr, u +@@ -229,6 +247,13 @@ static int write_ldt(void __user *ptr, unsigned lon= g bytecount, int oldmode) } } =20 @@ -16856,9 +17999,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ldt.c= linux-2.6.32.49/arch/x86/kernel fill_ldt(&ldt, &ldt_info); if (oldmode) ldt.avl =3D 0; -diff -urNp linux-2.6.32.49/arch/x86/kernel/machine_kexec_32.c linux-2.6.= 32.49/arch/x86/kernel/machine_kexec_32.c ---- linux-2.6.32.49/arch/x86/kernel/machine_kexec_32.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/machine_kexec_32.c 2011-11-15 19:59:= 43.000000000 -0500 +diff --git a/arch/x86/kernel/machine_kexec_32.c b/arch/x86/kernel/machin= e_kexec_32.c +index c1c429d..f02eaf9 100644 +--- a/arch/x86/kernel/machine_kexec_32.c ++++ b/arch/x86/kernel/machine_kexec_32.c @@ -26,7 +26,7 @@ #include #include @@ -16868,7 +18012,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/machin= e_kexec_32.c linux-2.6.32.49/ar { struct desc_ptr curidt; =20 -@@ -38,7 +38,7 @@ static void set_idt(void *newidt, __u16=20 +@@ -38,7 +38,7 @@ static void set_idt(void *newidt, __u16 limit) } =20 =20 @@ -16886,10 +18030,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/mach= ine_kexec_32.c linux-2.6.32.49/ar =20 relocate_kernel_ptr =3D control_page; page_list[PA_CONTROL_PAGE] =3D __pa(control_page); -diff -urNp linux-2.6.32.49/arch/x86/kernel/microcode_amd.c linux-2.6.32.= 49/arch/x86/kernel/microcode_amd.c ---- linux-2.6.32.49/arch/x86/kernel/microcode_amd.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/microcode_amd.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -364,7 +364,7 @@ static void microcode_fini_cpu_amd(int c +diff --git a/arch/x86/kernel/microcode_amd.c b/arch/x86/kernel/microcode= _amd.c +index 1e47679..e73449d 100644 +--- a/arch/x86/kernel/microcode_amd.c ++++ b/arch/x86/kernel/microcode_amd.c +@@ -364,7 +364,7 @@ static void microcode_fini_cpu_amd(int cpu) uci->mc =3D NULL; } =20 @@ -16898,7 +18043,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/microc= ode_amd.c linux-2.6.32.49/arch/ .request_microcode_user =3D request_microcode_user, .request_microcode_fw =3D request_microcode_fw, .collect_cpu_info =3D collect_cpu_info_amd, -@@ -372,7 +372,7 @@ static struct microcode_ops microcode_am +@@ -372,7 +372,7 @@ static struct microcode_ops microcode_amd_ops =3D { .microcode_fini_cpu =3D microcode_fini_cpu_amd, }; =20 @@ -16907,9 +18052,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/micro= code_amd.c linux-2.6.32.49/arch/ { return µcode_amd_ops; } -diff -urNp linux-2.6.32.49/arch/x86/kernel/microcode_core.c linux-2.6.32= .49/arch/x86/kernel/microcode_core.c ---- linux-2.6.32.49/arch/x86/kernel/microcode_core.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/microcode_core.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/arch/x86/kernel/microcode_core.c b/arch/x86/kernel/microcod= e_core.c +index 378e9a8..b5a6ea9 100644 +--- a/arch/x86/kernel/microcode_core.c ++++ b/arch/x86/kernel/microcode_core.c @@ -90,7 +90,7 @@ MODULE_LICENSE("GPL"); =20 #define MICROCODE_VERSION "2.00" @@ -16919,10 +18065,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/micr= ocode_core.c linux-2.6.32.49/arch =20 /* * Synchronization. -diff -urNp linux-2.6.32.49/arch/x86/kernel/microcode_intel.c linux-2.6.3= 2.49/arch/x86/kernel/microcode_intel.c ---- linux-2.6.32.49/arch/x86/kernel/microcode_intel.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/microcode_intel.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -443,13 +443,13 @@ static enum ucode_state request_microcod +diff --git a/arch/x86/kernel/microcode_intel.c b/arch/x86/kernel/microco= de_intel.c +index 0d334dd..14cedaf 100644 +--- a/arch/x86/kernel/microcode_intel.c ++++ b/arch/x86/kernel/microcode_intel.c +@@ -443,13 +443,13 @@ static enum ucode_state request_microcode_fw(int c= pu, struct device *device) =20 static int get_ucode_user(void *to, const void *from, size_t n) { @@ -16947,7 +18094,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/microc= ode_intel.c linux-2.6.32.49/arc .request_microcode_user =3D request_microcode_user, .request_microcode_fw =3D request_microcode_fw, .collect_cpu_info =3D collect_cpu_info, -@@ -468,7 +468,7 @@ static struct microcode_ops microcode_in +@@ -468,7 +468,7 @@ static struct microcode_ops microcode_intel_ops =3D = { .microcode_fini_cpu =3D microcode_fini_cpu, }; =20 @@ -16956,9 +18103,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/micro= code_intel.c linux-2.6.32.49/arc { return µcode_intel_ops; } -diff -urNp linux-2.6.32.49/arch/x86/kernel/module.c linux-2.6.32.49/arch= /x86/kernel/module.c ---- linux-2.6.32.49/arch/x86/kernel/module.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/module.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/kernel/module.c b/arch/x86/kernel/module.c +index 89f386f..9028f51 100644 +--- a/arch/x86/kernel/module.c ++++ b/arch/x86/kernel/module.c @@ -34,7 +34,7 @@ #define DEBUGP(fmt...) #endif @@ -16989,7 +18137,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/module= .c linux-2.6.32.49/arch/x86/ker } =20 /* Free memory returned from module_alloc */ -@@ -58,6 +68,40 @@ void module_free(struct module *mod, voi +@@ -58,6 +68,40 @@ void module_free(struct module *mod, void *module_reg= ion) vfree(module_region); } =20 @@ -17068,7 +18216,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/module= .c linux-2.6.32.49/arch/x86/ker break; default: printk(KERN_ERR "module %s: Unknown relocation: %u\n", -@@ -153,21 +203,30 @@ int apply_relocate_add(Elf64_Shdr *sechd +@@ -153,21 +203,30 @@ int apply_relocate_add(Elf64_Shdr *sechdrs, case R_X86_64_NONE: break; case R_X86_64_64: @@ -17099,9 +18247,23 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/modul= e.c linux-2.6.32.49/arch/x86/ker #if 0 if ((s64)val !=3D *(s32 *)loc) goto overflow; -diff -urNp linux-2.6.32.49/arch/x86/kernel/paravirt.c linux-2.6.32.49/ar= ch/x86/kernel/paravirt.c ---- linux-2.6.32.49/arch/x86/kernel/paravirt.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/paravirt.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/arch/x86/kernel/paravirt-spinlocks.c b/arch/x86/kernel/para= virt-spinlocks.c +index 3a7c5a4..9191528 100644 +--- a/arch/x86/kernel/paravirt-spinlocks.c ++++ b/arch/x86/kernel/paravirt-spinlocks.c +@@ -13,7 +13,7 @@ default_spin_lock_flags(raw_spinlock_t *lock, unsigned= long flags) + __raw_spin_lock(lock); + } +=20 +-struct pv_lock_ops pv_lock_ops =3D { ++struct pv_lock_ops pv_lock_ops __read_only =3D { + #ifdef CONFIG_SMP + .spin_is_locked =3D __ticket_spin_is_locked, + .spin_is_contended =3D __ticket_spin_is_contended, +diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c +index 1b1739d..dea6077 100644 +--- a/arch/x86/kernel/paravirt.c ++++ b/arch/x86/kernel/paravirt.c @@ -53,6 +53,9 @@ u64 _paravirt_ident_64(u64 x) { return x; @@ -17112,7 +18274,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/paravi= rt.c linux-2.6.32.49/arch/x86/k =20 void __init default_banner(void) { -@@ -122,7 +125,7 @@ unsigned paravirt_patch_jmp(void *insnbu +@@ -122,7 +125,7 @@ unsigned paravirt_patch_jmp(void *insnbuf, const voi= d *target, * corresponding structure. */ static void *get_call_destination(u8 type) { @@ -17121,7 +18283,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/paravi= rt.c linux-2.6.32.49/arch/x86/k .pv_init_ops =3D pv_init_ops, .pv_time_ops =3D pv_time_ops, .pv_cpu_ops =3D pv_cpu_ops, -@@ -133,6 +136,8 @@ static void *get_call_destination(u8 typ +@@ -133,6 +136,8 @@ static void *get_call_destination(u8 type) .pv_lock_ops =3D pv_lock_ops, #endif }; @@ -17130,7 +18292,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/paravi= rt.c linux-2.6.32.49/arch/x86/k return *((void **)&tmpl + type); } =20 -@@ -145,15 +150,19 @@ unsigned paravirt_patch_default(u8 type, +@@ -145,15 +150,19 @@ unsigned paravirt_patch_default(u8 type, u16 clobb= ers, void *insnbuf, if (opfunc =3D=3D NULL) /* If there's no function, patch it with a ud2a (BUG) */ ret =3D paravirt_patch_insns(insnbuf, len, ud2a, ud2a+sizeof(ud2a)); @@ -17153,7 +18315,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/paravi= rt.c linux-2.6.32.49/arch/x86/k =20 else if (type =3D=3D PARAVIRT_PATCH(pv_cpu_ops.iret) || type =3D=3D PARAVIRT_PATCH(pv_cpu_ops.irq_enable_sysexit) || -@@ -178,7 +187,7 @@ unsigned paravirt_patch_insns(void *insn +@@ -178,7 +187,7 @@ unsigned paravirt_patch_insns(void *insnbuf, unsigne= d len, if (insn_len > len || start =3D=3D NULL) insn_len =3D len; else @@ -17249,22 +18411,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/para= virt.c linux-2.6.32.49/arch/x86/k }; =20 EXPORT_SYMBOL_GPL(pv_time_ops); -diff -urNp linux-2.6.32.49/arch/x86/kernel/paravirt-spinlocks.c linux-2.= 6.32.49/arch/x86/kernel/paravirt-spinlocks.c ---- linux-2.6.32.49/arch/x86/kernel/paravirt-spinlocks.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/paravirt-spinlocks.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -13,7 +13,7 @@ default_spin_lock_flags(raw_spinlock_t * - __raw_spin_lock(lock); - } -=20 --struct pv_lock_ops pv_lock_ops =3D { -+struct pv_lock_ops pv_lock_ops __read_only =3D { - #ifdef CONFIG_SMP - .spin_is_locked =3D __ticket_spin_is_locked, - .spin_is_contended =3D __ticket_spin_is_contended, -diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-calgary_64.c linux-2.6.32= .49/arch/x86/kernel/pci-calgary_64.c ---- linux-2.6.32.49/arch/x86/kernel/pci-calgary_64.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/pci-calgary_64.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -477,7 +477,7 @@ static void calgary_free_coherent(struct +diff --git a/arch/x86/kernel/pci-calgary_64.c b/arch/x86/kernel/pci-calg= ary_64.c +index 1a2d4b1..6a0dd55 100644 +--- a/arch/x86/kernel/pci-calgary_64.c ++++ b/arch/x86/kernel/pci-calgary_64.c +@@ -477,7 +477,7 @@ static void calgary_free_coherent(struct device *dev= , size_t size, free_pages((unsigned long)vaddr, get_order(size)); } =20 @@ -17273,9 +18424,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-c= algary_64.c linux-2.6.32.49/arch .alloc_coherent =3D calgary_alloc_coherent, .free_coherent =3D calgary_free_coherent, .map_sg =3D calgary_map_sg, -diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-dma.c linux-2.6.32.49/arc= h/x86/kernel/pci-dma.c ---- linux-2.6.32.49/arch/x86/kernel/pci-dma.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/pci-dma.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c +index 6ac3931..42b4414 100644 +--- a/arch/x86/kernel/pci-dma.c ++++ b/arch/x86/kernel/pci-dma.c @@ -14,7 +14,7 @@ =20 static int forbid_dac __read_mostly; @@ -17294,10 +18446,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-= dma.c linux-2.6.32.49/arch/x86/ke =20 #ifdef CONFIG_PCI if (mask > 0xffffffff && forbid_dac > 0) { -diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-gart_64.c linux-2.6.32.49= /arch/x86/kernel/pci-gart_64.c ---- linux-2.6.32.49/arch/x86/kernel/pci-gart_64.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/pci-gart_64.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -682,7 +682,7 @@ static __init int init_k8_gatt(struct ag +diff --git a/arch/x86/kernel/pci-gart_64.c b/arch/x86/kernel/pci-gart_64= .c +index 1c76691..e3632db 100644 +--- a/arch/x86/kernel/pci-gart_64.c ++++ b/arch/x86/kernel/pci-gart_64.c +@@ -682,7 +682,7 @@ static __init int init_k8_gatt(struct agp_kern_info = *info) return -1; } =20 @@ -17306,10 +18459,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-= gart_64.c linux-2.6.32.49/arch/x8 .map_sg =3D gart_map_sg, .unmap_sg =3D gart_unmap_sg, .map_page =3D gart_map_page, -diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-nommu.c linux-2.6.32.49/a= rch/x86/kernel/pci-nommu.c ---- linux-2.6.32.49/arch/x86/kernel/pci-nommu.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/pci-nommu.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -94,7 +94,7 @@ static void nommu_sync_sg_for_device(str +diff --git a/arch/x86/kernel/pci-nommu.c b/arch/x86/kernel/pci-nommu.c +index a3933d4..c898869 100644 +--- a/arch/x86/kernel/pci-nommu.c ++++ b/arch/x86/kernel/pci-nommu.c +@@ -94,7 +94,7 @@ static void nommu_sync_sg_for_device(struct device *de= v, flush_write_buffers(); } =20 @@ -17318,10 +18472,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-= nommu.c linux-2.6.32.49/arch/x86/ .alloc_coherent =3D dma_generic_alloc_coherent, .free_coherent =3D nommu_free_coherent, .map_sg =3D nommu_map_sg, -diff -urNp linux-2.6.32.49/arch/x86/kernel/pci-swiotlb.c linux-2.6.32.49= /arch/x86/kernel/pci-swiotlb.c ---- linux-2.6.32.49/arch/x86/kernel/pci-swiotlb.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/pci-swiotlb.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -25,7 +25,7 @@ static void *x86_swiotlb_alloc_coherent( +diff --git a/arch/x86/kernel/pci-swiotlb.c b/arch/x86/kernel/pci-swiotlb= .c +index aaa6b78..4de1881 100644 +--- a/arch/x86/kernel/pci-swiotlb.c ++++ b/arch/x86/kernel/pci-swiotlb.c +@@ -25,7 +25,7 @@ static void *x86_swiotlb_alloc_coherent(struct device = *hwdev, size_t size, return swiotlb_alloc_coherent(hwdev, size, dma_handle, flags); } =20 @@ -17330,10 +18485,129 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/pci= -swiotlb.c linux-2.6.32.49/arch/x8 .mapping_error =3D swiotlb_dma_mapping_error, .alloc_coherent =3D x86_swiotlb_alloc_coherent, .free_coherent =3D swiotlb_free_coherent, -diff -urNp linux-2.6.32.49/arch/x86/kernel/process_32.c linux-2.6.32.49/= arch/x86/kernel/process_32.c ---- linux-2.6.32.49/arch/x86/kernel/process_32.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/process_32.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -67,6 +67,7 @@ asmlinkage void ret_from_fork(void) __as +diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c +index fc6c84d..0312ca2 100644 +--- a/arch/x86/kernel/process.c ++++ b/arch/x86/kernel/process.c +@@ -51,16 +51,33 @@ void free_thread_xstate(struct task_struct *tsk) +=20 + void free_thread_info(struct thread_info *ti) + { +- free_thread_xstate(ti->task); + free_pages((unsigned long)ti, get_order(THREAD_SIZE)); + } +=20 ++static struct kmem_cache *task_struct_cachep; ++ + void arch_task_cache_init(void) + { +- task_xstate_cachep =3D +- kmem_cache_create("task_xstate", xstate_size, ++ /* create a slab on which task_structs can be allocated */ ++ task_struct_cachep =3D ++ kmem_cache_create("task_struct", sizeof(struct task_struct), ++ ARCH_MIN_TASKALIGN, SLAB_PANIC | SLAB_NOTRACK, NULL); ++ ++ task_xstate_cachep =3D ++ kmem_cache_create("task_xstate", xstate_size, + __alignof__(union thread_xstate), +- SLAB_PANIC | SLAB_NOTRACK, NULL); ++ SLAB_PANIC | SLAB_NOTRACK | SLAB_USERCOPY, NULL); ++} ++ ++struct task_struct *alloc_task_struct(void) ++{ ++ return kmem_cache_alloc(task_struct_cachep, GFP_KERNEL); ++} ++ ++void free_task_struct(struct task_struct *task) ++{ ++ free_thread_xstate(task); ++ kmem_cache_free(task_struct_cachep, task); + } +=20 + /* +@@ -73,7 +90,7 @@ void exit_thread(void) + unsigned long *bp =3D t->io_bitmap_ptr; +=20 + if (bp) { +- struct tss_struct *tss =3D &per_cpu(init_tss, get_cpu()); ++ struct tss_struct *tss =3D init_tss + get_cpu(); +=20 + t->io_bitmap_ptr =3D NULL; + clear_thread_flag(TIF_IO_BITMAP); +@@ -93,6 +110,9 @@ void flush_thread(void) +=20 + clear_tsk_thread_flag(tsk, TIF_DEBUG); +=20 ++#if defined(CONFIG_X86_32) && !defined(CONFIG_CC_STACKPROTECTOR) && !de= fined(CONFIG_PAX_MEMORY_UDEREF) ++ loadsegment(gs, 0); ++#endif + tsk->thread.debugreg0 =3D 0; + tsk->thread.debugreg1 =3D 0; + tsk->thread.debugreg2 =3D 0; +@@ -307,7 +327,7 @@ void default_idle(void) + EXPORT_SYMBOL(default_idle); + #endif +=20 +-void stop_this_cpu(void *dummy) ++__noreturn void stop_this_cpu(void *dummy) + { + local_irq_disable(); + /* +@@ -568,16 +588,38 @@ static int __init idle_setup(char *str) + } + early_param("idle", idle_setup); +=20 +-unsigned long arch_align_stack(unsigned long sp) ++#ifdef CONFIG_PAX_RANDKSTACK ++void pax_randomize_kstack(struct pt_regs *regs) + { +- if (!(current->personality & ADDR_NO_RANDOMIZE) && randomize_va_space) +- sp -=3D get_random_int() % 8192; +- return sp & ~0xf; +-} ++ struct thread_struct *thread =3D ¤t->thread; ++ unsigned long time; +=20 +-unsigned long arch_randomize_brk(struct mm_struct *mm) +-{ +- unsigned long range_end =3D mm->brk + 0x02000000; +- return randomize_range(mm->brk, range_end, 0) ? : mm->brk; ++ if (!randomize_va_space) ++ return; ++ ++ if (v8086_mode(regs)) ++ return; ++ ++ rdtscl(time); ++ ++ /* P4 seems to return a 0 LSB, ignore it */ ++#ifdef CONFIG_MPENTIUM4 ++ time &=3D 0x3EUL; ++ time <<=3D 2; ++#elif defined(CONFIG_X86_64) ++ time &=3D 0xFUL; ++ time <<=3D 4; ++#else ++ time &=3D 0x1FUL; ++ time <<=3D 3; ++#endif ++ ++ thread->sp0 ^=3D time; ++ load_sp0(init_tss + smp_processor_id(), thread); ++ ++#ifdef CONFIG_X86_64 ++ percpu_write(kernel_stack, thread->sp0); ++#endif + } ++#endif +=20 +diff --git a/arch/x86/kernel/process_32.c b/arch/x86/kernel/process_32.c +index c40c432..6e1df72 100644 +--- a/arch/x86/kernel/process_32.c ++++ b/arch/x86/kernel/process_32.c +@@ -67,6 +67,7 @@ asmlinkage void ret_from_fork(void) __asm__("ret_from_= fork"); unsigned long thread_saved_pc(struct task_struct *tsk) { return ((unsigned long *)tsk->thread.sp)[3]; @@ -17341,7 +18615,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_32.c linux-2.6.32.49/arch/x86 } =20 #ifndef CONFIG_SMP -@@ -129,15 +130,14 @@ void __show_regs(struct pt_regs *regs, i +@@ -129,15 +130,14 @@ void __show_regs(struct pt_regs *regs, int all) unsigned short ss, gs; const char *board; =20 @@ -17359,7 +18633,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_32.c linux-2.6.32.49/arch/x86 =20 printk("\n"); =20 -@@ -210,10 +210,10 @@ int kernel_thread(int (*fn)(void *), voi +@@ -210,10 +210,10 @@ int kernel_thread(int (*fn)(void *), void *arg, un= signed long flags) regs.bx =3D (unsigned long) fn; regs.dx =3D (unsigned long) arg; =20 @@ -17373,7 +18647,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_32.c linux-2.6.32.49/arch/x86 regs.orig_ax =3D -1; regs.ip =3D (unsigned long) kernel_thread_helper; regs.cs =3D __KERNEL_CS | get_kernel_rpl(); -@@ -247,13 +247,14 @@ int copy_thread(unsigned long clone_flag +@@ -247,13 +247,14 @@ int copy_thread(unsigned long clone_flags, unsigne= d long sp, struct task_struct *tsk; int err; =20 @@ -17389,7 +18663,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_32.c linux-2.6.32.49/arch/x86 =20 p->thread.ip =3D (unsigned long) ret_from_fork; =20 -@@ -345,7 +346,7 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -345,7 +346,7 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) struct thread_struct *prev =3D &prev_p->thread, *next =3D &next_p->thread; int cpu =3D smp_processor_id(); @@ -17398,7 +18672,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_32.c linux-2.6.32.49/arch/x86 bool preload_fpu; =20 /* never put a printk in __switch_to... printk() calls wake_up*() indi= rectly */ -@@ -380,6 +381,10 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -380,6 +381,10 @@ __switch_to(struct task_struct *prev_p, struct task= _struct *next_p) */ lazy_save_gs(prev->gs); =20 @@ -17409,7 +18683,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_32.c linux-2.6.32.49/arch/x86 /* * Load the per-thread Thread-Local Storage descriptor. */ -@@ -415,6 +420,9 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -415,6 +420,9 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) */ arch_end_context_switch(next_p); =20 @@ -17419,7 +18693,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_32.c linux-2.6.32.49/arch/x86 if (preload_fpu) __math_state_restore(); =20 -@@ -424,8 +432,6 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -424,8 +432,6 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) if (prev->gs | next->gs) lazy_load_gs(next->gs); =20 @@ -17428,14 +18702,15 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proc= ess_32.c linux-2.6.32.49/arch/x86 return prev_p; } =20 -@@ -495,4 +501,3 @@ unsigned long get_wchan(struct task_stru +@@ -495,4 +501,3 @@ unsigned long get_wchan(struct task_struct *p) } while (count++ < 16); return 0; } - -diff -urNp linux-2.6.32.49/arch/x86/kernel/process_64.c linux-2.6.32.49/= arch/x86/kernel/process_64.c ---- linux-2.6.32.49/arch/x86/kernel/process_64.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/process_64.c 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/arch/x86/kernel/process_64.c b/arch/x86/kernel/process_64.c +index 39493bc..196816d 100644 +--- a/arch/x86/kernel/process_64.c ++++ b/arch/x86/kernel/process_64.c @@ -91,7 +91,7 @@ static void __exit_idle(void) void exit_idle(void) { @@ -17445,7 +18720,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_64.c linux-2.6.32.49/arch/x86 return; __exit_idle(); } -@@ -170,7 +170,7 @@ void __show_regs(struct pt_regs *regs, i +@@ -170,7 +170,7 @@ void __show_regs(struct pt_regs *regs, int all) if (!board) board =3D ""; printk(KERN_INFO "Pid: %d, comm: %.20s %s %s %.*s %s\n", @@ -17454,7 +18729,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_64.c linux-2.6.32.49/arch/x86 init_utsname()->release, (int)strcspn(init_utsname()->version, " "), init_utsname()->version, board); -@@ -280,8 +280,7 @@ int copy_thread(unsigned long clone_flag +@@ -280,8 +280,7 @@ int copy_thread(unsigned long clone_flags, unsigned = long sp, struct pt_regs *childregs; struct task_struct *me =3D current; =20 @@ -17464,7 +18739,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_64.c linux-2.6.32.49/arch/x86 *childregs =3D *regs; =20 childregs->ax =3D 0; -@@ -292,6 +291,7 @@ int copy_thread(unsigned long clone_flag +@@ -292,6 +291,7 @@ int copy_thread(unsigned long clone_flags, unsigned = long sp, p->thread.sp =3D (unsigned long) childregs; p->thread.sp0 =3D (unsigned long) (childregs+1); p->thread.usersp =3D me->thread.usersp; @@ -17472,7 +18747,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_64.c linux-2.6.32.49/arch/x86 =20 set_tsk_thread_flag(p, TIF_FORK); =20 -@@ -379,7 +379,7 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -379,7 +379,7 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) struct thread_struct *prev =3D &prev_p->thread; struct thread_struct *next =3D &next_p->thread; int cpu =3D smp_processor_id(); @@ -17481,7 +18756,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_64.c linux-2.6.32.49/arch/x86 unsigned fsindex, gsindex; bool preload_fpu; =20 -@@ -475,10 +475,9 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -475,10 +475,9 @@ __switch_to(struct task_struct *prev_p, struct task= _struct *next_p) prev->usersp =3D percpu_read(old_rsp); percpu_write(old_rsp, next->usersp); percpu_write(current_task, next_p); @@ -17494,7 +18769,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/proces= s_64.c linux-2.6.32.49/arch/x86 =20 /* * Now maybe reload the debug registers and handle I/O bitmaps -@@ -559,12 +558,11 @@ unsigned long get_wchan(struct task_stru +@@ -559,12 +558,11 @@ unsigned long get_wchan(struct task_struct *p) if (!p || p =3D=3D current || p->state =3D=3D TASK_RUNNING) return 0; stack =3D (unsigned long)task_stack_page(p); @@ -17509,127 +18784,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/pro= cess_64.c linux-2.6.32.49/arch/x86 return 0; ip =3D *(u64 *)(fp+8); if (!in_sched_functions(ip)) -diff -urNp linux-2.6.32.49/arch/x86/kernel/process.c linux-2.6.32.49/arc= h/x86/kernel/process.c ---- linux-2.6.32.49/arch/x86/kernel/process.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/process.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -51,16 +51,33 @@ void free_thread_xstate(struct task_stru -=20 - void free_thread_info(struct thread_info *ti) - { -- free_thread_xstate(ti->task); - free_pages((unsigned long)ti, get_order(THREAD_SIZE)); - } -=20 -+static struct kmem_cache *task_struct_cachep; -+ - void arch_task_cache_init(void) - { -- task_xstate_cachep =3D -- kmem_cache_create("task_xstate", xstate_size, -+ /* create a slab on which task_structs can be allocated */ -+ task_struct_cachep =3D -+ kmem_cache_create("task_struct", sizeof(struct task_struct), -+ ARCH_MIN_TASKALIGN, SLAB_PANIC | SLAB_NOTRACK, NULL); -+ -+ task_xstate_cachep =3D -+ kmem_cache_create("task_xstate", xstate_size, - __alignof__(union thread_xstate), -- SLAB_PANIC | SLAB_NOTRACK, NULL); -+ SLAB_PANIC | SLAB_NOTRACK | SLAB_USERCOPY, NULL); -+} -+ -+struct task_struct *alloc_task_struct(void) -+{ -+ return kmem_cache_alloc(task_struct_cachep, GFP_KERNEL); -+} -+ -+void free_task_struct(struct task_struct *task) -+{ -+ free_thread_xstate(task); -+ kmem_cache_free(task_struct_cachep, task); - } -=20 - /* -@@ -73,7 +90,7 @@ void exit_thread(void) - unsigned long *bp =3D t->io_bitmap_ptr; -=20 - if (bp) { -- struct tss_struct *tss =3D &per_cpu(init_tss, get_cpu()); -+ struct tss_struct *tss =3D init_tss + get_cpu(); -=20 - t->io_bitmap_ptr =3D NULL; - clear_thread_flag(TIF_IO_BITMAP); -@@ -93,6 +110,9 @@ void flush_thread(void) -=20 - clear_tsk_thread_flag(tsk, TIF_DEBUG); -=20 -+#if defined(CONFIG_X86_32) && !defined(CONFIG_CC_STACKPROTECTOR) && !de= fined(CONFIG_PAX_MEMORY_UDEREF) -+ loadsegment(gs, 0); -+#endif - tsk->thread.debugreg0 =3D 0; - tsk->thread.debugreg1 =3D 0; - tsk->thread.debugreg2 =3D 0; -@@ -307,7 +327,7 @@ void default_idle(void) - EXPORT_SYMBOL(default_idle); - #endif -=20 --void stop_this_cpu(void *dummy) -+__noreturn void stop_this_cpu(void *dummy) - { - local_irq_disable(); - /* -@@ -568,16 +588,38 @@ static int __init idle_setup(char *str) - } - early_param("idle", idle_setup); -=20 --unsigned long arch_align_stack(unsigned long sp) -+#ifdef CONFIG_PAX_RANDKSTACK -+void pax_randomize_kstack(struct pt_regs *regs) - { -- if (!(current->personality & ADDR_NO_RANDOMIZE) && randomize_va_space) -- sp -=3D get_random_int() % 8192; -- return sp & ~0xf; --} -+ struct thread_struct *thread =3D ¤t->thread; -+ unsigned long time; -=20 --unsigned long arch_randomize_brk(struct mm_struct *mm) --{ -- unsigned long range_end =3D mm->brk + 0x02000000; -- return randomize_range(mm->brk, range_end, 0) ? : mm->brk; -+ if (!randomize_va_space) -+ return; -+ -+ if (v8086_mode(regs)) -+ return; -+ -+ rdtscl(time); -+ -+ /* P4 seems to return a 0 LSB, ignore it */ -+#ifdef CONFIG_MPENTIUM4 -+ time &=3D 0x3EUL; -+ time <<=3D 2; -+#elif defined(CONFIG_X86_64) -+ time &=3D 0xFUL; -+ time <<=3D 4; -+#else -+ time &=3D 0x1FUL; -+ time <<=3D 3; -+#endif -+ -+ thread->sp0 ^=3D time; -+ load_sp0(init_tss + smp_processor_id(), thread); -+ -+#ifdef CONFIG_X86_64 -+ percpu_write(kernel_stack, thread->sp0); -+#endif - } -+#endif -=20 -diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace.c linux-2.6.32.49/arch= /x86/kernel/ptrace.c ---- linux-2.6.32.49/arch/x86/kernel/ptrace.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/ptrace.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -925,7 +925,7 @@ static const struct user_regset_view use +diff --git a/arch/x86/kernel/ptrace.c b/arch/x86/kernel/ptrace.c +index c06acdd..3f5fff5 100644 +--- a/arch/x86/kernel/ptrace.c ++++ b/arch/x86/kernel/ptrace.c +@@ -925,7 +925,7 @@ static const struct user_regset_view user_x86_32_vie= w; /* Initialized below. */ long arch_ptrace(struct task_struct *child, long request, long addr, lo= ng data) { int ret; @@ -17638,7 +18797,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace= .c linux-2.6.32.49/arch/x86/ker =20 switch (request) { /* read the word at location addr in the USER area. */ -@@ -1012,14 +1012,14 @@ long arch_ptrace(struct task_struct *chi +@@ -1012,14 +1012,14 @@ long arch_ptrace(struct task_struct *child, long= request, long addr, long data) if (addr < 0) return -EIO; ret =3D do_get_thread_area(child, addr, @@ -17655,7 +18814,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace= .c linux-2.6.32.49/arch/x86/ker break; #endif =20 -@@ -1038,12 +1038,12 @@ long arch_ptrace(struct task_struct *chi +@@ -1038,12 +1038,12 @@ long arch_ptrace(struct task_struct *child, long= request, long addr, long data) #ifdef CONFIG_X86_PTRACE_BTS case PTRACE_BTS_CONFIG: ret =3D ptrace_bts_config @@ -17670,7 +18829,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace= .c linux-2.6.32.49/arch/x86/ker break; =20 case PTRACE_BTS_SIZE: -@@ -1052,7 +1052,7 @@ long arch_ptrace(struct task_struct *chi +@@ -1052,7 +1052,7 @@ long arch_ptrace(struct task_struct *child, long r= equest, long addr, long data) =20 case PTRACE_BTS_GET: ret =3D ptrace_bts_read_record @@ -17679,7 +18838,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace= .c linux-2.6.32.49/arch/x86/ker break; =20 case PTRACE_BTS_CLEAR: -@@ -1061,7 +1061,7 @@ long arch_ptrace(struct task_struct *chi +@@ -1061,7 +1061,7 @@ long arch_ptrace(struct task_struct *child, long r= equest, long addr, long data) =20 case PTRACE_BTS_DRAIN: ret =3D ptrace_bts_drain @@ -17688,7 +18847,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace= .c linux-2.6.32.49/arch/x86/ker break; #endif /* CONFIG_X86_PTRACE_BTS */ =20 -@@ -1450,7 +1450,7 @@ void send_sigtrap(struct task_struct *ts +@@ -1450,7 +1450,7 @@ void send_sigtrap(struct task_struct *tsk, struct = pt_regs *regs, info.si_code =3D si_code; =20 /* User-mode ip? */ @@ -17697,7 +18856,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace= .c linux-2.6.32.49/arch/x86/ker =20 /* Send us the fake SIGTRAP */ force_sig_info(SIGTRAP, &info, tsk); -@@ -1469,7 +1469,7 @@ void send_sigtrap(struct task_struct *ts +@@ -1469,7 +1469,7 @@ void send_sigtrap(struct task_struct *tsk, struct = pt_regs *regs, * We must return the syscall number to actually look up in the table. * This can be -1L to skip running any syscall at all. */ @@ -17706,7 +18865,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrace= .c linux-2.6.32.49/arch/x86/ker { long ret =3D 0; =20 -@@ -1514,7 +1514,7 @@ asmregparm long syscall_trace_enter(stru +@@ -1514,7 +1514,7 @@ asmregparm long syscall_trace_enter(struct pt_regs= *regs) return ret ?: regs->orig_ax; } =20 @@ -17715,9 +18874,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/ptrac= e.c linux-2.6.32.49/arch/x86/ker { if (unlikely(current->audit_context)) audit_syscall_exit(AUDITSC_RESULT(regs->ax), regs->ax); -diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot.c linux-2.6.32.49/arch= /x86/kernel/reboot.c ---- linux-2.6.32.49/arch/x86/kernel/reboot.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/reboot.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c +index cf98100..e76e03d 100644 +--- a/arch/x86/kernel/reboot.c ++++ b/arch/x86/kernel/reboot.c @@ -33,7 +33,7 @@ void (*pm_power_off)(void); EXPORT_SYMBOL(pm_power_off); =20 @@ -17745,7 +18905,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot= .c linux-2.6.32.49/arch/x86/ker }; =20 static const struct desc_ptr -@@ -346,7 +346,7 @@ static const unsigned char jump_to_bios=20 +@@ -346,7 +346,7 @@ static const unsigned char jump_to_bios [] =3D * specified by the code and length parameters. * We assume that length will aways be less that 100! */ @@ -17754,7 +18914,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot= .c linux-2.6.32.49/arch/x86/ker { local_irq_disable(); =20 -@@ -366,8 +366,8 @@ void machine_real_restart(const unsigned +@@ -366,8 +366,8 @@ void machine_real_restart(const unsigned char *code,= int length) /* Remap the kernel at virtual address zero, as well as offset zero from the kernel segment. This assumes the kernel segment starts at virtual address PAGE_OFFSET. */ @@ -17765,7 +18925,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot= .c linux-2.6.32.49/arch/x86/ker =20 /* * Use `swapper_pg_dir' as our page directory. -@@ -379,16 +379,15 @@ void machine_real_restart(const unsigned +@@ -379,16 +379,15 @@ void machine_real_restart(const unsigned char *cod= e, int length) boot)". This seems like a fairly standard thing that gets set by REBOOT.COM programs, and the previous reset routine did this too. */ @@ -17785,7 +18945,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot= .c linux-2.6.32.49/arch/x86/ker =20 /* Set up the IDT for real mode. */ load_idt(&real_mode_idt); -@@ -416,6 +415,7 @@ void machine_real_restart(const unsigned +@@ -416,6 +415,7 @@ void machine_real_restart(const unsigned char *code,= int length) __asm__ __volatile__ ("ljmp $0x0008,%0" : : "i" ((void *)(0x1000 - sizeof (real_mode_switch) - 100))); @@ -17793,7 +18953,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot= .c linux-2.6.32.49/arch/x86/ker } #ifdef CONFIG_APM_MODULE EXPORT_SYMBOL(machine_real_restart); -@@ -544,7 +544,7 @@ void __attribute__((weak)) mach_reboot_f +@@ -544,7 +544,7 @@ void __attribute__((weak)) mach_reboot_fixups(void) { } =20 @@ -17818,7 +18978,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot= .c linux-2.6.32.49/arch/x86/ker { printk("machine restart\n"); =20 -@@ -674,7 +674,7 @@ static void native_machine_restart(char=20 +@@ -674,7 +674,7 @@ static void native_machine_restart(char *__unused) __machine_emergency_restart(0); } =20 @@ -17836,7 +18996,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboot= .c linux-2.6.32.49/arch/x86/ker { if (pm_power_off) { if (!reboot_force) -@@ -694,6 +694,7 @@ static void native_machine_power_off(voi +@@ -694,6 +694,7 @@ static void native_machine_power_off(void) } /* a fallback in case there is no PM info available */ tboot_shutdown(TB_SHUTDOWN_HALT); @@ -17844,9 +19004,30 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/reboo= t.c linux-2.6.32.49/arch/x86/ker } =20 struct machine_ops machine_ops =3D { -diff -urNp linux-2.6.32.49/arch/x86/kernel/setup.c linux-2.6.32.49/arch/= x86/kernel/setup.c ---- linux-2.6.32.49/arch/x86/kernel/setup.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/setup.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/kernel/relocate_kernel_64.S b/arch/x86/kernel/relo= cate_kernel_64.S +index 7a6f3b3..976a959 100644 +--- a/arch/x86/kernel/relocate_kernel_64.S ++++ b/arch/x86/kernel/relocate_kernel_64.S +@@ -11,6 +11,7 @@ + #include + #include + #include ++#include +=20 + /* + * Must be relocatable PIC code callable as a C function +@@ -167,6 +168,7 @@ identity_mapped: + xorq %r14, %r14 + xorq %r15, %r15 +=20 ++ pax_force_retaddr 0, 1 + ret +=20 + 1: +diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c +index 5449a26..0b6c759 100644 +--- a/arch/x86/kernel/setup.c ++++ b/arch/x86/kernel/setup.c @@ -783,14 +783,14 @@ void __init setup_arch(char **cmdline_p) =20 if (!boot_params.hdr.root_flags) @@ -17867,9 +19048,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/setup= .c linux-2.6.32.49/arch/x86/kern data_resource.end =3D virt_to_phys(_edata)-1; bss_resource.start =3D virt_to_phys(&__bss_start); bss_resource.end =3D virt_to_phys(&__bss_stop)-1; -diff -urNp linux-2.6.32.49/arch/x86/kernel/setup_percpu.c linux-2.6.32.4= 9/arch/x86/kernel/setup_percpu.c ---- linux-2.6.32.49/arch/x86/kernel/setup_percpu.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/setup_percpu.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/arch/x86/kernel/setup_percpu.c b/arch/x86/kernel/setup_perc= pu.c +index d559af9..524c6ad 100644 +--- a/arch/x86/kernel/setup_percpu.c ++++ b/arch/x86/kernel/setup_percpu.c @@ -25,19 +25,17 @@ # define DBG(x...) #endif @@ -17894,7 +19076,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/setup_= percpu.c linux-2.6.32.49/arch/x [0 ... NR_CPUS-1] =3D BOOT_PERCPU_OFFSET, }; EXPORT_SYMBOL(__per_cpu_offset); -@@ -159,10 +157,10 @@ static inline void setup_percpu_segment( +@@ -159,10 +157,10 @@ static inline void setup_percpu_segment(int cpu) { #ifdef CONFIG_X86_32 struct desc_struct gdt; @@ -17933,10 +19115,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/setu= p_percpu.c linux-2.6.32.49/arch/x /* * Up to this point, the boot CPU has been using .data.init * area. Reload any changed state for the boot CPU. -diff -urNp linux-2.6.32.49/arch/x86/kernel/signal.c linux-2.6.32.49/arch= /x86/kernel/signal.c ---- linux-2.6.32.49/arch/x86/kernel/signal.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/signal.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -197,7 +197,7 @@ static unsigned long align_sigframe(unsi +diff --git a/arch/x86/kernel/signal.c b/arch/x86/kernel/signal.c +index 6a44a76..a9287a1 100644 +--- a/arch/x86/kernel/signal.c ++++ b/arch/x86/kernel/signal.c +@@ -197,7 +197,7 @@ static unsigned long align_sigframe(unsigned long sp= ) * Align the stack pointer according to the i386 ABI, * i.e. so that on function entry ((sp + 4) & 15) =3D=3D 0. */ @@ -17945,7 +19128,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/signal= .c linux-2.6.32.49/arch/x86/ker #else /* !CONFIG_X86_32 */ sp =3D round_down(sp, 16) - 8; #endif -@@ -248,11 +248,11 @@ get_sigframe(struct k_sigaction *ka, str +@@ -248,11 +248,11 @@ get_sigframe(struct k_sigaction *ka, struct pt_reg= s *regs, size_t frame_size, * Return an always-bogus address instead so we will die with SIGSEGV. */ if (onsigstack && !likely(on_sig_stack(sp))) @@ -17959,7 +19142,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/signal= .c linux-2.6.32.49/arch/x86/ker =20 return (void __user *)sp; } -@@ -307,9 +307,9 @@ __setup_frame(int sig, struct k_sigactio +@@ -307,9 +307,9 @@ __setup_frame(int sig, struct k_sigaction *ka, sigse= t_t *set, } =20 if (current->mm->context.vdso) @@ -17971,7 +19154,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/signal= .c linux-2.6.32.49/arch/x86/ker if (ka->sa.sa_flags & SA_RESTORER) restorer =3D ka->sa.sa_restorer; =20 -@@ -323,7 +323,7 @@ __setup_frame(int sig, struct k_sigactio +@@ -323,7 +323,7 @@ __setup_frame(int sig, struct k_sigaction *ka, sigse= t_t *set, * reasons and because gdb uses it as a signature to notice * signal handler stack frames. */ @@ -17980,7 +19163,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/signal= .c linux-2.6.32.49/arch/x86/ker =20 if (err) return -EFAULT; -@@ -377,7 +377,10 @@ static int __setup_rt_frame(int sig, str +@@ -377,7 +377,10 @@ static int __setup_rt_frame(int sig, struct k_sigac= tion *ka, siginfo_t *info, err |=3D __copy_to_user(&frame->uc.uc_sigmask, set, sizeof(*set)); =20 /* Set up to return from userspace. */ @@ -17992,7 +19175,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/signal= .c linux-2.6.32.49/arch/x86/ker if (ka->sa.sa_flags & SA_RESTORER) restorer =3D ka->sa.sa_restorer; put_user_ex(restorer, &frame->pretcode); -@@ -389,7 +392,7 @@ static int __setup_rt_frame(int sig, str +@@ -389,7 +392,7 @@ static int __setup_rt_frame(int sig, struct k_sigact= ion *ka, siginfo_t *info, * reasons and because gdb uses it as a signature to notice * signal handler stack frames. */ @@ -18001,7 +19184,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/signal= .c linux-2.6.32.49/arch/x86/ker } put_user_catch(err); =20 if (err) -@@ -782,6 +785,8 @@ static void do_signal(struct pt_regs *re +@@ -782,6 +785,8 @@ static void do_signal(struct pt_regs *regs) int signr; sigset_t *oldset; =20 @@ -18010,7 +19193,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/signal= .c linux-2.6.32.49/arch/x86/ker /* * We want the common case to go fast, which is why we may in certain * cases get here from kernel mode. Just return without doing anything -@@ -789,7 +794,7 @@ static void do_signal(struct pt_regs *re +@@ -789,7 +794,7 @@ static void do_signal(struct pt_regs *regs) * X86_32: vm86 regs switched out by assembly code before reaching * here, so testing against kernel CS suffices. */ @@ -18019,10 +19202,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sign= al.c linux-2.6.32.49/arch/x86/ker return; =20 if (current_thread_info()->status & TS_RESTORE_SIGMASK) -diff -urNp linux-2.6.32.49/arch/x86/kernel/smpboot.c linux-2.6.32.49/arc= h/x86/kernel/smpboot.c ---- linux-2.6.32.49/arch/x86/kernel/smpboot.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/smpboot.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -94,14 +94,14 @@ static DEFINE_PER_CPU(struct task_struct +diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c +index 7e8e905..64d5c32 100644 +--- a/arch/x86/kernel/smpboot.c ++++ b/arch/x86/kernel/smpboot.c +@@ -94,14 +94,14 @@ static DEFINE_PER_CPU(struct task_struct *, idle_thr= ead_array); */ static DEFINE_MUTEX(x86_cpu_hotplug_driver_mutex); =20 @@ -18041,7 +19225,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/smpboo= t.c linux-2.6.32.49/arch/x86/ke } =20 ssize_t arch_cpu_probe(const char *buf, size_t count) { return -1; } -@@ -625,7 +625,7 @@ wakeup_secondary_cpu_via_init(int phys_a +@@ -625,7 +625,7 @@ wakeup_secondary_cpu_via_init(int phys_apicid, unsig= ned long start_eip) * target processor state. */ startup_ipi_hook(phys_apicid, (unsigned long) start_secondary, @@ -18050,7 +19234,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/smpboo= t.c linux-2.6.32.49/arch/x86/ke =20 /* * Run STARTUP IPI loop. -@@ -743,6 +743,7 @@ static int __cpuinit do_boot_cpu(int api +@@ -743,6 +743,7 @@ static int __cpuinit do_boot_cpu(int apicid, int cpu= ) set_idle_for_cpu(cpu, c_idle.idle); do_rest: per_cpu(current_task, cpu) =3D c_idle.idle; @@ -18078,7 +19262,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/smpboo= t.c linux-2.6.32.49/arch/x86/ke =20 /* start_ip had better be page-aligned! */ start_ip =3D setup_trampoline(); -@@ -891,6 +894,12 @@ int __cpuinit native_cpu_up(unsigned int +@@ -891,6 +894,12 @@ int __cpuinit native_cpu_up(unsigned int cpu) =20 per_cpu(cpu_state, cpu) =3D CPU_UP_PREPARE; =20 @@ -18091,10 +19275,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/smpb= oot.c linux-2.6.32.49/arch/x86/ke err =3D do_boot_cpu(apicid, cpu); =20 if (err) { -diff -urNp linux-2.6.32.49/arch/x86/kernel/step.c linux-2.6.32.49/arch/x= 86/kernel/step.c ---- linux-2.6.32.49/arch/x86/kernel/step.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/kernel/step.c 2011-11-15 19:59:43.000000000= -0500 -@@ -27,10 +27,10 @@ unsigned long convert_ip_to_linear(struc +diff --git a/arch/x86/kernel/step.c b/arch/x86/kernel/step.c +index 3149032..14f1053 100644 +--- a/arch/x86/kernel/step.c ++++ b/arch/x86/kernel/step.c +@@ -27,10 +27,10 @@ unsigned long convert_ip_to_linear(struct task_struc= t *child, struct pt_regs *re struct desc_struct *desc; unsigned long base; =20 @@ -18107,7 +19292,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/step.c= linux-2.6.32.49/arch/x86/kerne addr =3D -1L; /* bogus selector, access would fault */ else { desc =3D child->mm->context.ldt + seg; -@@ -42,7 +42,8 @@ unsigned long convert_ip_to_linear(struc +@@ -42,7 +42,8 @@ unsigned long convert_ip_to_linear(struct task_struct = *child, struct pt_regs *re addr +=3D base; } mutex_unlock(&child->mm->context.lock); @@ -18117,7 +19302,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/step.c= linux-2.6.32.49/arch/x86/kerne =20 return addr; } -@@ -53,6 +54,9 @@ static int is_setting_trap_flag(struct t +@@ -53,6 +54,9 @@ static int is_setting_trap_flag(struct task_struct *ch= ild, struct pt_regs *regs) unsigned char opcode[15]; unsigned long addr =3D convert_ip_to_linear(child, regs); =20 @@ -18127,7 +19312,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/step.c= linux-2.6.32.49/arch/x86/kerne copied =3D access_process_vm(child, addr, opcode, sizeof(opcode), 0); for (i =3D 0; i < copied; i++) { switch (opcode[i]) { -@@ -74,7 +78,7 @@ static int is_setting_trap_flag(struct t +@@ -74,7 +78,7 @@ static int is_setting_trap_flag(struct task_struct *ch= ild, struct pt_regs *regs) =20 #ifdef CONFIG_X86_64 case 0x40 ... 0x4f: @@ -18136,17 +19321,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/step= .c linux-2.6.32.49/arch/x86/kerne /* 32-bit mode: register increment */ return 0; /* 64-bit mode: REX prefix */ -diff -urNp linux-2.6.32.49/arch/x86/kernel/syscall_table_32.S linux-2.6.= 32.49/arch/x86/kernel/syscall_table_32.S ---- linux-2.6.32.49/arch/x86/kernel/syscall_table_32.S 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/syscall_table_32.S 2011-11-15 19:59:= 43.000000000 -0500 -@@ -1,3 +1,4 @@ -+.section .rodata,"a",@progbits - ENTRY(sys_call_table) - .long sys_restart_syscall /* 0 - old "setup()" system call, used for r= estarting */ - .long sys_exit -diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_i386_32.c linux-2.6.32.49= /arch/x86/kernel/sys_i386_32.c ---- linux-2.6.32.49/arch/x86/kernel/sys_i386_32.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/sys_i386_32.c 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/arch/x86/kernel/sys_i386_32.c b/arch/x86/kernel/sys_i386_32= .c +index dee1ff7..a397f7f 100644 +--- a/arch/x86/kernel/sys_i386_32.c ++++ b/arch/x86/kernel/sys_i386_32.c @@ -24,6 +24,21 @@ =20 #include @@ -18382,7 +19560,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_i3= 86_32.c linux-2.6.32.49/arch/x8 =20 struct sel_arg_struct { unsigned long n; -@@ -93,7 +314,7 @@ asmlinkage int sys_ipc(uint call, int fi +@@ -93,7 +314,7 @@ asmlinkage int sys_ipc(uint call, int first, int seco= nd, return sys_semtimedop(first, (struct sembuf __user *)ptr, second, NUL= L); case SEMTIMEDOP: return sys_semtimedop(first, (struct sembuf __user *)ptr, second, @@ -18391,7 +19569,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_i3= 86_32.c linux-2.6.32.49/arch/x8 =20 case SEMGET: return sys_semget(first, second, third); -@@ -140,7 +361,7 @@ asmlinkage int sys_ipc(uint call, int fi +@@ -140,7 +361,7 @@ asmlinkage int sys_ipc(uint call, int first, int sec= ond, ret =3D do_shmat(first, (char __user *) ptr, second, &raddr); if (ret) return ret; @@ -18400,7 +19578,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_i3= 86_32.c linux-2.6.32.49/arch/x8 } case 1: /* iBCS2 emulator entry point */ if (!segment_eq(get_fs(), get_ds())) -@@ -207,17 +428,3 @@ asmlinkage int sys_olduname(struct oldol +@@ -207,17 +428,3 @@ asmlinkage int sys_olduname(struct oldold_utsname _= _user *name) =20 return error; } @@ -18418,9 +19596,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_i= 386_32.c linux-2.6.32.49/arch/x8 - : "0" (__NR_execve), "ri" (filename), "c" (argv), "d" (envp) : "memory= "); - return __res; -} -diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x86_64.c linux-2.6.32.49/= arch/x86/kernel/sys_x86_64.c ---- linux-2.6.32.49/arch/x86/kernel/sys_x86_64.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/sys_x86_64.c 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/arch/x86/kernel/sys_x86_64.c b/arch/x86/kernel/sys_x86_64.c +index 8aa2057..b604bc1 100644 +--- a/arch/x86/kernel/sys_x86_64.c ++++ b/arch/x86/kernel/sys_x86_64.c @@ -32,8 +32,8 @@ out: return error; } @@ -18432,7 +19611,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x8= 6_64.c linux-2.6.32.49/arch/x86 { if (!test_thread_flag(TIF_IA32) && (flags & MAP_32BIT)) { unsigned long new_begin; -@@ -52,7 +52,7 @@ static void find_start_end(unsigned long +@@ -52,7 +52,7 @@ static void find_start_end(unsigned long flags, unsign= ed long *begin, *begin =3D new_begin; } } else { @@ -18441,7 +19620,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x8= 6_64.c linux-2.6.32.49/arch/x86 *end =3D TASK_SIZE; } } -@@ -69,16 +69,19 @@ arch_get_unmapped_area(struct file *filp +@@ -69,16 +69,19 @@ arch_get_unmapped_area(struct file *filp, unsigned l= ong addr, if (flags & MAP_FIXED) return addr; =20 @@ -18473,7 +19652,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x8= 6_64.c linux-2.6.32.49/arch/x86 /* * Remember the place where we stopped the search: */ -@@ -128,7 +131,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -128,7 +131,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, { struct vm_area_struct *vma; struct mm_struct *mm =3D current->mm; @@ -18482,7 +19661,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x8= 6_64.c linux-2.6.32.49/arch/x86 =20 /* requested length too big for entire address space */ if (len > TASK_SIZE) -@@ -141,13 +144,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -141,13 +144,18 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, if (!test_thread_flag(TIF_IA32) && (flags & MAP_32BIT)) goto bottomup; =20 @@ -18505,7 +19684,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x8= 6_64.c linux-2.6.32.49/arch/x86 } =20 /* check if free_area_cache is useful for us */ -@@ -162,7 +170,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -162,7 +170,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* make sure it can fit in the remaining address space */ if (addr > len) { vma =3D find_vma(mm, addr-len); @@ -18514,7 +19693,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x8= 6_64.c linux-2.6.32.49/arch/x86 /* remember the address as a hint for next time */ return mm->free_area_cache =3D addr-len; } -@@ -179,7 +187,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -179,7 +187,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, * return with success: */ vma =3D find_vma(mm, addr); @@ -18523,7 +19702,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x8= 6_64.c linux-2.6.32.49/arch/x86 /* remember the address as a hint for next time */ return mm->free_area_cache =3D addr; =20 -@@ -188,8 +196,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -188,8 +196,8 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -18558,9 +19737,19 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/sys_x= 86_64.c linux-2.6.32.49/arch/x86 mm->cached_hole_size =3D ~0UL; =20 return addr; -diff -urNp linux-2.6.32.49/arch/x86/kernel/tboot.c linux-2.6.32.49/arch/= x86/kernel/tboot.c ---- linux-2.6.32.49/arch/x86/kernel/tboot.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/tboot.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/kernel/syscall_table_32.S b/arch/x86/kernel/syscal= l_table_32.S +index 76d70a4..4c94a44 100644 +--- a/arch/x86/kernel/syscall_table_32.S ++++ b/arch/x86/kernel/syscall_table_32.S +@@ -1,3 +1,4 @@ ++.section .rodata,"a",@progbits + ENTRY(sys_call_table) + .long sys_restart_syscall /* 0 - old "setup()" system call, used for r= estarting */ + .long sys_exit +diff --git a/arch/x86/kernel/tboot.c b/arch/x86/kernel/tboot.c +index 46b8277..3349d55 100644 +--- a/arch/x86/kernel/tboot.c ++++ b/arch/x86/kernel/tboot.c @@ -216,7 +216,7 @@ static int tboot_setup_sleep(void) =20 void tboot_shutdown(u32 shutdown_type) @@ -18579,7 +19768,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/tboot.= c linux-2.6.32.49/arch/x86/kern shutdown(); =20 /* should not reach here */ -@@ -295,7 +295,7 @@ void tboot_sleep(u8 sleep_state, u32 pm1 +@@ -295,7 +295,7 @@ void tboot_sleep(u8 sleep_state, u32 pm1a_control, u= 32 pm1b_control) tboot_shutdown(acpi_shutdown_map[sleep_state]); } =20 @@ -18588,7 +19777,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/tboot.= c linux-2.6.32.49/arch/x86/kern =20 static int tboot_wait_for_aps(int num_aps) { -@@ -319,9 +319,9 @@ static int __cpuinit tboot_cpu_callback( +@@ -319,9 +319,9 @@ static int __cpuinit tboot_cpu_callback(struct notif= ier_block *nfb, { switch (action) { case CPU_DYING: @@ -18609,9 +19798,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/tboot= .c linux-2.6.32.49/arch/x86/kern register_hotcpu_notifier(&tboot_cpu_notifier); return 0; } -diff -urNp linux-2.6.32.49/arch/x86/kernel/time.c linux-2.6.32.49/arch/x= 86/kernel/time.c ---- linux-2.6.32.49/arch/x86/kernel/time.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/kernel/time.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/kernel/time.c b/arch/x86/kernel/time.c +index be25734..87fe232 100644 +--- a/arch/x86/kernel/time.c ++++ b/arch/x86/kernel/time.c @@ -26,17 +26,13 @@ int timer_ack; #endif @@ -18632,7 +19822,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/time.c= linux-2.6.32.49/arch/x86/kerne #else unsigned long *sp =3D (unsigned long *)kernel_stack_pointer(regs); -@@ -45,11 +41,17 @@ unsigned long profile_pc(struct pt_regs=20 +@@ -45,11 +41,17 @@ unsigned long profile_pc(struct pt_regs *regs) * or above a saved flags. Eflags has bits 22-31 zero, * kernel addresses don't. */ @@ -18650,10 +19840,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/time= .c linux-2.6.32.49/arch/x86/kerne } return pc; } -diff -urNp linux-2.6.32.49/arch/x86/kernel/tls.c linux-2.6.32.49/arch/x8= 6/kernel/tls.c ---- linux-2.6.32.49/arch/x86/kernel/tls.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/kernel/tls.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -85,6 +85,11 @@ int do_set_thread_area(struct task_struc +diff --git a/arch/x86/kernel/tls.c b/arch/x86/kernel/tls.c +index 6bb7b85..dd853e1 100644 +--- a/arch/x86/kernel/tls.c ++++ b/arch/x86/kernel/tls.c +@@ -85,6 +85,11 @@ int do_set_thread_area(struct task_struct *p, int idx= , if (idx < GDT_ENTRY_TLS_MIN || idx > GDT_ENTRY_TLS_MAX) return -EINVAL; =20 @@ -18665,9 +19856,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/tls.c= linux-2.6.32.49/arch/x86/kernel set_tls_desc(p, idx, &info, 1); =20 return 0; -diff -urNp linux-2.6.32.49/arch/x86/kernel/trampoline_32.S linux-2.6.32.= 49/arch/x86/kernel/trampoline_32.S ---- linux-2.6.32.49/arch/x86/kernel/trampoline_32.S 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/trampoline_32.S 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/arch/x86/kernel/trampoline_32.S b/arch/x86/kernel/trampolin= e_32.S +index 8508237..229b664 100644 +--- a/arch/x86/kernel/trampoline_32.S ++++ b/arch/x86/kernel/trampoline_32.S @@ -32,6 +32,12 @@ #include #include @@ -18690,9 +19882,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/tramp= oline_32.S linux-2.6.32.49/arch/ =20 # These need to be in the same 64K segment as the above; # hence we don't use the boot_gdt_descr defined in head.S -diff -urNp linux-2.6.32.49/arch/x86/kernel/trampoline_64.S linux-2.6.32.= 49/arch/x86/kernel/trampoline_64.S ---- linux-2.6.32.49/arch/x86/kernel/trampoline_64.S 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/trampoline_64.S 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/arch/x86/kernel/trampoline_64.S b/arch/x86/kernel/trampolin= e_64.S +index 3af2dff..ba8aa49 100644 +--- a/arch/x86/kernel/trampoline_64.S ++++ b/arch/x86/kernel/trampoline_64.S @@ -91,7 +91,7 @@ startup_32: movl $__KERNEL_DS, %eax # Initialize the %ds segment register movl %eax, %ds @@ -18720,9 +19913,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/tramp= oline_64.S linux-2.6.32.49/arch/ .long tgdt - r_base .short 0 .quad 0x00cf9b000000ffff # __KERNEL32_CS -diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.c linux-2.6.32.49/arch/= x86/kernel/traps.c ---- linux-2.6.32.49/arch/x86/kernel/traps.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/traps.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c +index 7e37dce..ec3f8e5 100644 +--- a/arch/x86/kernel/traps.c ++++ b/arch/x86/kernel/traps.c @@ -69,12 +69,6 @@ asmlinkage int system_call(void); =20 /* Do we ignore FPU interrupts ? */ @@ -18736,7 +19930,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern #endif =20 DECLARE_BITMAP(used_vectors, NR_VECTORS); -@@ -112,19 +106,19 @@ static inline void preempt_conditional_c +@@ -112,19 +106,19 @@ static inline void preempt_conditional_cli(struct = pt_regs *regs) static inline void die_if_kernel(const char *str, struct pt_regs *regs, long err) { @@ -18759,7 +19953,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern /* * traps 0, 1, 3, 4, and 5 should be forwarded to vm86. * On nmi (interrupt 2), do_trap should not be called. -@@ -135,7 +129,7 @@ do_trap(int trapnr, int signr, char *str +@@ -135,7 +129,7 @@ do_trap(int trapnr, int signr, char *str, struct pt_= regs *regs, } #endif =20 @@ -18798,7 +19992,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern return; =20 #ifdef CONFIG_X86_32 -@@ -265,14 +271,30 @@ do_general_protection(struct pt_regs *re +@@ -265,14 +271,30 @@ do_general_protection(struct pt_regs *regs, long e= rror_code) conditional_sti(regs); =20 #ifdef CONFIG_X86_32 @@ -18845,7 +20039,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern die("general protection fault", regs, error_code); } =20 -@@ -435,6 +464,17 @@ static notrace __kprobes void default_do +@@ -435,6 +464,17 @@ static notrace __kprobes void default_do_nmi(struct= pt_regs *regs) dotraplinkage notrace __kprobes void do_nmi(struct pt_regs *regs, long error_code) { @@ -18863,7 +20057,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern nmi_enter(); =20 inc_irq_stat(__nmi_count); -@@ -558,7 +598,7 @@ dotraplinkage void __kprobes do_debug(st +@@ -558,7 +598,7 @@ dotraplinkage void __kprobes do_debug(struct pt_regs= *regs, long error_code) } =20 #ifdef CONFIG_X86_32 @@ -18872,7 +20066,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern goto debug_vm86; #endif =20 -@@ -570,7 +610,7 @@ dotraplinkage void __kprobes do_debug(st +@@ -570,7 +610,7 @@ dotraplinkage void __kprobes do_debug(struct pt_regs= *regs, long error_code) * kernel space (but re-enable TF when returning to user mode). */ if (condition & DR_STEP) { @@ -18881,7 +20075,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern goto clear_TF_reenable; } =20 -@@ -757,7 +797,7 @@ do_simd_coprocessor_error(struct pt_regs +@@ -757,7 +797,7 @@ do_simd_coprocessor_error(struct pt_regs *regs, long= error_code) * Handle strange cache flush from user space exception * in all other cases. This is undocumented behaviour. */ @@ -18890,7 +20084,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/traps.= c linux-2.6.32.49/arch/x86/kern handle_vm86_fault((struct kernel_vm86_regs *)regs, error_code); return; } -@@ -798,7 +838,7 @@ asmlinkage void __attribute__((weak)) sm +@@ -798,7 +838,7 @@ asmlinkage void __attribute__((weak)) smp_threshold_= interrupt(void) void __math_state_restore(void) { struct thread_info *thread =3D current_thread_info(); @@ -18909,118 +20103,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/tra= ps.c linux-2.6.32.49/arch/x86/kern =20 if (!tsk_used_math(tsk)) { local_irq_enable(); -diff -urNp linux-2.6.32.49/arch/x86/kernel/verify_cpu_64.S linux-2.6.32.= 49/arch/x86/kernel/verify_cpu_64.S ---- linux-2.6.32.49/arch/x86/kernel/verify_cpu_64.S 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/verify_cpu_64.S 1969-12-31 19:00:00.= 000000000 -0500 -@@ -1,105 +0,0 @@ --/* -- * -- * verify_cpu.S - Code for cpu long mode and SSE verification. This -- * code has been borrowed from boot/setup.S and was introduced by -- * Andi Kleen. -- * -- * Copyright (c) 2007 Andi Kleen (ak@suse.de) -- * Copyright (c) 2007 Eric Biederman (ebiederm@xmission.com) -- * Copyright (c) 2007 Vivek Goyal (vgoyal@in.ibm.com) -- * -- * This source code is licensed under the GNU General Public License, -- * Version 2. See the file COPYING for more details. -- * -- * This is a common code for verification whether CPU supports -- * long mode and SSE or not. It is not called directly instead this -- * file is included at various places and compiled in that context. -- * Following are the current usage. -- * -- * This file is included by both 16bit and 32bit code. -- * -- * arch/x86_64/boot/setup.S : Boot cpu verification (16bit) -- * arch/x86_64/boot/compressed/head.S: Boot cpu verification (32bit) -- * arch/x86_64/kernel/trampoline.S: secondary processor verfication (16= bit) -- * arch/x86_64/kernel/acpi/wakeup.S:Verfication at resume (16bit) -- * -- * verify_cpu, returns the status of cpu check in register %eax. -- * 0: Success 1: Failure -- * -- * The caller needs to check for the error code and take the action -- * appropriately. Either display a message or halt. -- */ -- --#include -- --verify_cpu: -- pushfl # Save caller passed flags -- pushl $0 # Kill any dangerous flags -- popfl -- -- pushfl # standard way to check for cpuid -- popl %eax -- movl %eax,%ebx -- xorl $0x200000,%eax -- pushl %eax -- popfl -- pushfl -- popl %eax -- cmpl %eax,%ebx -- jz verify_cpu_no_longmode # cpu has no cpuid -- -- movl $0x0,%eax # See if cpuid 1 is implemented -- cpuid -- cmpl $0x1,%eax -- jb verify_cpu_no_longmode # no cpuid 1 -- -- xor %di,%di -- cmpl $0x68747541,%ebx # AuthenticAMD -- jnz verify_cpu_noamd -- cmpl $0x69746e65,%edx -- jnz verify_cpu_noamd -- cmpl $0x444d4163,%ecx -- jnz verify_cpu_noamd -- mov $1,%di # cpu is from AMD -- --verify_cpu_noamd: -- movl $0x1,%eax # Does the cpu have what it takes -- cpuid -- andl $REQUIRED_MASK0,%edx -- xorl $REQUIRED_MASK0,%edx -- jnz verify_cpu_no_longmode -- -- movl $0x80000000,%eax # See if extended cpuid is implemented -- cpuid -- cmpl $0x80000001,%eax -- jb verify_cpu_no_longmode # no extended cpuid -- -- movl $0x80000001,%eax # Does the cpu have what it takes -- cpuid -- andl $REQUIRED_MASK1,%edx -- xorl $REQUIRED_MASK1,%edx -- jnz verify_cpu_no_longmode -- --verify_cpu_sse_test: -- movl $1,%eax -- cpuid -- andl $SSE_MASK,%edx -- cmpl $SSE_MASK,%edx -- je verify_cpu_sse_ok -- test %di,%di -- jz verify_cpu_no_longmode # only try to force SSE on AMD -- movl $0xc0010015,%ecx # HWCR -- rdmsr -- btr $15,%eax # enable SSE -- wrmsr -- xor %di,%di # don't loop -- jmp verify_cpu_sse_test # try again -- --verify_cpu_no_longmode: -- popfl # Restore caller passed flags -- movl $1,%eax -- ret --verify_cpu_sse_ok: -- popfl # Restore caller passed flags -- xorl %eax, %eax -- ret -diff -urNp linux-2.6.32.49/arch/x86/kernel/verify_cpu.S linux-2.6.32.49/= arch/x86/kernel/verify_cpu.S ---- linux-2.6.32.49/arch/x86/kernel/verify_cpu.S 1969-12-31 19:00:00.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/verify_cpu.S 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/arch/x86/kernel/verify_cpu.S b/arch/x86/kernel/verify_cpu.S +new file mode 100644 +index 0000000..50c5edd +--- /dev/null ++++ b/arch/x86/kernel/verify_cpu.S @@ -0,0 +1,140 @@ +/* + * @@ -19162,9 +20249,121 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/veri= fy_cpu.S linux-2.6.32.49/arch/x86 + popfl # Restore caller passed flags + xorl %eax, %eax + ret -diff -urNp linux-2.6.32.49/arch/x86/kernel/vm86_32.c linux-2.6.32.49/arc= h/x86/kernel/vm86_32.c ---- linux-2.6.32.49/arch/x86/kernel/vm86_32.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/vm86_32.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/arch/x86/kernel/verify_cpu_64.S b/arch/x86/kernel/verify_cp= u_64.S +deleted file mode 100644 +index 45b6f8a..0000000 +--- a/arch/x86/kernel/verify_cpu_64.S ++++ /dev/null +@@ -1,105 +0,0 @@ +-/* +- * +- * verify_cpu.S - Code for cpu long mode and SSE verification. This +- * code has been borrowed from boot/setup.S and was introduced by +- * Andi Kleen. +- * +- * Copyright (c) 2007 Andi Kleen (ak@suse.de) +- * Copyright (c) 2007 Eric Biederman (ebiederm@xmission.com) +- * Copyright (c) 2007 Vivek Goyal (vgoyal@in.ibm.com) +- * +- * This source code is licensed under the GNU General Public License, +- * Version 2. See the file COPYING for more details. +- * +- * This is a common code for verification whether CPU supports +- * long mode and SSE or not. It is not called directly instead this +- * file is included at various places and compiled in that context. +- * Following are the current usage. +- * +- * This file is included by both 16bit and 32bit code. +- * +- * arch/x86_64/boot/setup.S : Boot cpu verification (16bit) +- * arch/x86_64/boot/compressed/head.S: Boot cpu verification (32bit) +- * arch/x86_64/kernel/trampoline.S: secondary processor verfication (16= bit) +- * arch/x86_64/kernel/acpi/wakeup.S:Verfication at resume (16bit) +- * +- * verify_cpu, returns the status of cpu check in register %eax. +- * 0: Success 1: Failure +- * +- * The caller needs to check for the error code and take the action +- * appropriately. Either display a message or halt. +- */ +- +-#include +- +-verify_cpu: +- pushfl # Save caller passed flags +- pushl $0 # Kill any dangerous flags +- popfl +- +- pushfl # standard way to check for cpuid +- popl %eax +- movl %eax,%ebx +- xorl $0x200000,%eax +- pushl %eax +- popfl +- pushfl +- popl %eax +- cmpl %eax,%ebx +- jz verify_cpu_no_longmode # cpu has no cpuid +- +- movl $0x0,%eax # See if cpuid 1 is implemented +- cpuid +- cmpl $0x1,%eax +- jb verify_cpu_no_longmode # no cpuid 1 +- +- xor %di,%di +- cmpl $0x68747541,%ebx # AuthenticAMD +- jnz verify_cpu_noamd +- cmpl $0x69746e65,%edx +- jnz verify_cpu_noamd +- cmpl $0x444d4163,%ecx +- jnz verify_cpu_noamd +- mov $1,%di # cpu is from AMD +- +-verify_cpu_noamd: +- movl $0x1,%eax # Does the cpu have what it takes +- cpuid +- andl $REQUIRED_MASK0,%edx +- xorl $REQUIRED_MASK0,%edx +- jnz verify_cpu_no_longmode +- +- movl $0x80000000,%eax # See if extended cpuid is implemented +- cpuid +- cmpl $0x80000001,%eax +- jb verify_cpu_no_longmode # no extended cpuid +- +- movl $0x80000001,%eax # Does the cpu have what it takes +- cpuid +- andl $REQUIRED_MASK1,%edx +- xorl $REQUIRED_MASK1,%edx +- jnz verify_cpu_no_longmode +- +-verify_cpu_sse_test: +- movl $1,%eax +- cpuid +- andl $SSE_MASK,%edx +- cmpl $SSE_MASK,%edx +- je verify_cpu_sse_ok +- test %di,%di +- jz verify_cpu_no_longmode # only try to force SSE on AMD +- movl $0xc0010015,%ecx # HWCR +- rdmsr +- btr $15,%eax # enable SSE +- wrmsr +- xor %di,%di # don't loop +- jmp verify_cpu_sse_test # try again +- +-verify_cpu_no_longmode: +- popfl # Restore caller passed flags +- movl $1,%eax +- ret +-verify_cpu_sse_ok: +- popfl # Restore caller passed flags +- xorl %eax, %eax +- ret +diff --git a/arch/x86/kernel/vm86_32.c b/arch/x86/kernel/vm86_32.c +index 9c4e625..c992817 100644 +--- a/arch/x86/kernel/vm86_32.c ++++ b/arch/x86/kernel/vm86_32.c @@ -41,6 +41,7 @@ #include #include @@ -19173,7 +20372,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vm86_3= 2.c linux-2.6.32.49/arch/x86/ke =20 #include #include -@@ -148,7 +149,7 @@ struct pt_regs *save_v86_state(struct ke +@@ -148,7 +149,7 @@ struct pt_regs *save_v86_state(struct kernel_vm86_re= gs *regs) do_exit(SIGSEGV); } =20 @@ -19211,7 +20410,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vm86_3= 2.c linux-2.6.32.49/arch/x86/ke tsk =3D current; switch (regs->bx) { case VM86_REQUEST_IRQ: -@@ -324,7 +340,7 @@ static void do_sys_vm86(struct kernel_vm +@@ -324,7 +340,7 @@ static void do_sys_vm86(struct kernel_vm86_struct *i= nfo, struct task_struct *tsk tsk->thread.saved_fs =3D info->regs32->fs; tsk->thread.saved_gs =3D get_user_gs(info->regs32); =20 @@ -19220,7 +20419,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vm86_3= 2.c linux-2.6.32.49/arch/x86/ke tsk->thread.sp0 =3D (unsigned long) &info->VM86_TSS_ESP0; if (cpu_has_sep) tsk->thread.sysenter_cs =3D 0; -@@ -529,7 +545,7 @@ static void do_int(struct kernel_vm86_re +@@ -529,7 +545,7 @@ static void do_int(struct kernel_vm86_regs *regs, in= t i, goto cannot_handle; if (i =3D=3D 0x21 && is_revectored(AH(regs), &KVM86->int21_revectored)= ) goto cannot_handle; @@ -19229,10 +20428,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vm86= _32.c linux-2.6.32.49/arch/x86/ke if (get_user(segoffs, intr_ptr)) goto cannot_handle; if ((segoffs >> 16) =3D=3D BIOSSEG) -diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32.c linux-2.6.32.49/arch= /x86/kernel/vmi_32.c ---- linux-2.6.32.49/arch/x86/kernel/vmi_32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/vmi_32.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -44,12 +44,17 @@ typedef u32 __attribute__((regparm(1)))=20 +diff --git a/arch/x86/kernel/vmi_32.c b/arch/x86/kernel/vmi_32.c +index d430e4c..831f817 100644 +--- a/arch/x86/kernel/vmi_32.c ++++ b/arch/x86/kernel/vmi_32.c +@@ -44,12 +44,17 @@ typedef u32 __attribute__((regparm(1))) (VROMFUNC)(v= oid); typedef u64 __attribute__((regparm(2))) (VROMLONGFUNC)(int); =20 #define call_vrom_func(rom,func) \ @@ -19241,14 +20441,15 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_= 32.c linux-2.6.32.49/arch/x86/ker =20 #define call_vrom_long_func(rom,func,arg) \ - (((VROMLONGFUNC *)(rom->func)) (arg)) +- +-static struct vrom_header *vmi_rom; +({\ + u64 __reloc =3D ((VROMLONGFUNC *)(ktva_ktla(rom.func))) (arg);\ + struct vmi_relocation_info *const __rel =3D (struct vmi_relocation_inf= o *)&__reloc;\ + __rel->eip =3D (unsigned char *)ktva_ktla((unsigned long)__rel->eip);\ + __reloc;\ +}) -=20 --static struct vrom_header *vmi_rom; ++ +static struct vrom_header vmi_rom __attribute((__section__(".vmi.rom"),= __aligned__(PAGE_SIZE))); static int disable_pge; static int disable_pse; @@ -19275,7 +20476,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32= .c linux-2.6.32.49/arch/x86/ker } =20 static unsigned patch_internal(int call, unsigned len, void *insnbuf, -@@ -102,6 +107,7 @@ static unsigned patch_internal(int call, +@@ -102,6 +107,7 @@ static unsigned patch_internal(int call, unsigned le= n, void *insnbuf, { u64 reloc; struct vmi_relocation_info *const rel =3D (struct vmi_relocation_info = *)&reloc; @@ -19283,7 +20484,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32= .c linux-2.6.32.49/arch/x86/ker reloc =3D call_vrom_long_func(vmi_rom, get_reloc, call); switch(rel->type) { case VMI_RELOCATION_CALL_REL: -@@ -404,13 +410,13 @@ static void vmi_set_pud(pud_t *pudp, pud +@@ -404,13 +410,13 @@ static void vmi_set_pud(pud_t *pudp, pud_t pudval) =20 static void vmi_pte_clear(struct mm_struct *mm, unsigned long addr, pte= _t *ptep) { @@ -19299,7 +20500,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32= .c linux-2.6.32.49/arch/x86/ker vmi_ops.set_pte(pte, (pte_t *)pmd, VMI_PAGE_PD); } #endif -@@ -438,10 +444,10 @@ vmi_startup_ipi_hook(int phys_apicid, un +@@ -438,10 +444,10 @@ vmi_startup_ipi_hook(int phys_apicid, unsigned lon= g start_eip, ap.ss =3D __KERNEL_DS; ap.esp =3D (unsigned long) start_esp; =20 @@ -19332,7 +20533,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32= .c linux-2.6.32.49/arch/x86/ker static inline int __init check_vmi_rom(struct vrom_header *rom) { struct pci_header *pci; -@@ -498,6 +516,10 @@ static inline int __init check_vmi_rom(s +@@ -498,6 +516,10 @@ static inline int __init check_vmi_rom(struct vrom_= header *rom) return 0; if (rom->vrom_signature !=3D VMI_SIGNATURE) return 0; @@ -19343,7 +20544,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32= .c linux-2.6.32.49/arch/x86/ker if (rom->api_version_maj !=3D VMI_API_REV_MAJOR || rom->api_version_min+1 < VMI_API_REV_MINOR+1) { printk(KERN_WARNING "VMI: Found mismatched rom version %d.%d\n", -@@ -562,7 +584,7 @@ static inline int __init probe_vmi_rom(v +@@ -562,7 +584,7 @@ static inline int __init probe_vmi_rom(void) struct vrom_header *romstart; romstart =3D (struct vrom_header *)isa_bus_to_virt(base); if (check_vmi_rom(romstart)) { @@ -19352,7 +20553,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32= .c linux-2.6.32.49/arch/x86/ker return 1; } } -@@ -836,6 +858,11 @@ static inline int __init activate_vmi(vo +@@ -836,6 +858,11 @@ static inline int __init activate_vmi(void) =20 para_fill(pv_irq_ops.safe_halt, Halt); =20 @@ -19364,7 +20565,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_32= .c linux-2.6.32.49/arch/x86/ker /* * Alternative instruction rewriting doesn't happen soon enough * to convert VMI_IRET to a call instead of a jump; so we have -@@ -853,16 +880,16 @@ static inline int __init activate_vmi(vo +@@ -853,16 +880,16 @@ static inline int __init activate_vmi(void) =20 void __init vmi_init(void) { @@ -19394,9 +20595,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmi_3= 2.c linux-2.6.32.49/arch/x86/ker return; =20 local_irq_save(flags); -diff -urNp linux-2.6.32.49/arch/x86/kernel/vmlinux.lds.S linux-2.6.32.49= /arch/x86/kernel/vmlinux.lds.S ---- linux-2.6.32.49/arch/x86/kernel/vmlinux.lds.S 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/vmlinux.lds.S 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/arch/x86/kernel/vmlinux.lds.S b/arch/x86/kernel/vmlinux.lds= .S +index 3c68fe2..12c8280 100644 +--- a/arch/x86/kernel/vmlinux.lds.S ++++ b/arch/x86/kernel/vmlinux.lds.S @@ -26,6 +26,13 @@ #include #include @@ -19411,7 +20613,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmlinu= x.lds.S linux-2.6.32.49/arch/x8 =20 #undef i386 /* in case the preprocessor is a 32bit one */ =20 -@@ -34,40 +41,53 @@ OUTPUT_FORMAT(CONFIG_OUTPUT_FORMAT, CONF +@@ -34,40 +41,53 @@ OUTPUT_FORMAT(CONFIG_OUTPUT_FORMAT, CONFIG_OUTPUT_FO= RMAT, CONFIG_OUTPUT_FORMAT) #ifdef CONFIG_X86_32 OUTPUT_ARCH(i386) ENTRY(phys_startup_32) @@ -19502,11 +20704,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmli= nux.lds.S linux-2.6.32.49/arch/x8 + . =3D ALIGN(HPAGE_SIZE); + MODULES_EXEC_END =3D . - 1; +#endif -+ -+ } :module -+#endif =20 - EXCEPTION_TABLE(16) :text =3D 0x9090 ++ } :module ++#endif ++ + .text.end : AT(ADDR(.text.end) - LOAD_OFFSET) { + /* End of text section */ + _etext =3D . - __KERNEL_TEXT_OFFSET; @@ -19689,10 +20891,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vmli= nux.lds.S linux-2.6.32.49/arch/x8 "kernel image bigger than KERNEL_IMAGE_SIZE"); =20 #ifdef CONFIG_SMP -diff -urNp linux-2.6.32.49/arch/x86/kernel/vsyscall_64.c linux-2.6.32.49= /arch/x86/kernel/vsyscall_64.c ---- linux-2.6.32.49/arch/x86/kernel/vsyscall_64.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/vsyscall_64.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -80,6 +80,7 @@ void update_vsyscall(struct timespec *wa +diff --git a/arch/x86/kernel/vsyscall_64.c b/arch/x86/kernel/vsyscall_64= .c +index 62f39d7..3bc46a1 100644 +--- a/arch/x86/kernel/vsyscall_64.c ++++ b/arch/x86/kernel/vsyscall_64.c +@@ -80,6 +80,7 @@ void update_vsyscall(struct timespec *wall_time, struc= t clocksource *clock, =20 write_seqlock_irqsave(&vsyscall_gtod_data.lock, flags); /* copy vsyscall data */ @@ -19700,7 +20903,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vsysca= ll_64.c linux-2.6.32.49/arch/x8 vsyscall_gtod_data.clock.vread =3D clock->vread; vsyscall_gtod_data.clock.cycle_last =3D clock->cycle_last; vsyscall_gtod_data.clock.mask =3D clock->mask; -@@ -203,7 +204,7 @@ vgetcpu(unsigned *cpu, unsigned *node, s +@@ -203,7 +204,7 @@ vgetcpu(unsigned *cpu, unsigned *node, struct getcpu= _cache *tcache) We do this here because otherwise user space would do it on its own in a likely inferior way (no access to jiffies). If you don't like it pass NULL. */ @@ -19709,9 +20912,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/vsysc= all_64.c linux-2.6.32.49/arch/x8 p =3D tcache->blob[1]; } else if (__vgetcpu_mode =3D=3D VGETCPU_RDTSCP) { /* Load per CPU data from RDTSCP */ -diff -urNp linux-2.6.32.49/arch/x86/kernel/x8664_ksyms_64.c linux-2.6.32= .49/arch/x86/kernel/x8664_ksyms_64.c ---- linux-2.6.32.49/arch/x86/kernel/x8664_ksyms_64.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/x8664_ksyms_64.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/arch/x86/kernel/x8664_ksyms_64.c b/arch/x86/kernel/x8664_ks= yms_64.c +index 3909e3b..5433a97 100644 +--- a/arch/x86/kernel/x8664_ksyms_64.c ++++ b/arch/x86/kernel/x8664_ksyms_64.c @@ -30,8 +30,6 @@ EXPORT_SYMBOL(__put_user_8); =20 EXPORT_SYMBOL(copy_user_generic); @@ -19721,10 +20925,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/x866= 4_ksyms_64.c linux-2.6.32.49/arch EXPORT_SYMBOL(__copy_from_user_inatomic); =20 EXPORT_SYMBOL(copy_page); -diff -urNp linux-2.6.32.49/arch/x86/kernel/xsave.c linux-2.6.32.49/arch/= x86/kernel/xsave.c ---- linux-2.6.32.49/arch/x86/kernel/xsave.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/kernel/xsave.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -54,7 +54,7 @@ int check_for_xstate(struct i387_fxsave_ +diff --git a/arch/x86/kernel/xsave.c b/arch/x86/kernel/xsave.c +index c5ee17e..d63218f 100644 +--- a/arch/x86/kernel/xsave.c ++++ b/arch/x86/kernel/xsave.c +@@ -54,7 +54,7 @@ int check_for_xstate(struct i387_fxsave_struct __user = *buf, fx_sw_user->xstate_size > fx_sw_user->extended_size) return -1; =20 @@ -19742,7 +20947,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/xsave.= c linux-2.6.32.49/arch/x86/kern } =20 /* -@@ -228,7 +228,7 @@ int restore_i387_xstate(void __user *buf +@@ -228,7 +228,7 @@ int restore_i387_xstate(void __user *buf) if (task_thread_info(tsk)->status & TS_XSAVE) err =3D restore_user_xstate(buf); else @@ -19751,9 +20956,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kernel/xsave= .c linux-2.6.32.49/arch/x86/kern buf); if (unlikely(err)) { /* -diff -urNp linux-2.6.32.49/arch/x86/kvm/emulate.c linux-2.6.32.49/arch/x= 86/kvm/emulate.c ---- linux-2.6.32.49/arch/x86/kvm/emulate.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/kvm/emulate.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c +index 1350e43..a94b011 100644 +--- a/arch/x86/kvm/emulate.c ++++ b/arch/x86/kvm/emulate.c @@ -81,8 +81,8 @@ #define Src2CL (1<<29) #define Src2ImmByte (2<<29) @@ -19790,9 +20996,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/emulate.= c linux-2.6.32.49/arch/x86/kvm/e switch ((_dst).bytes) { \ case 1: \ ____emulate_2op(_op,_src,_dst,_eflags,_bx,_by,"b"); \ -diff -urNp linux-2.6.32.49/arch/x86/kvm/lapic.c linux-2.6.32.49/arch/x86= /kvm/lapic.c ---- linux-2.6.32.49/arch/x86/kvm/lapic.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/arch/x86/kvm/lapic.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c +index 8dfeaaa..4daa395 100644 +--- a/arch/x86/kvm/lapic.c ++++ b/arch/x86/kvm/lapic.c @@ -52,7 +52,7 @@ #define APIC_BUS_CYCLE_NS 1 =20 @@ -19802,10 +21009,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/lapic.c= linux-2.6.32.49/arch/x86/kvm/lap =20 #define APIC_LVT_NUM 6 /* 14 is the version for Xeon and Pentium 8.4.8*/ -diff -urNp linux-2.6.32.49/arch/x86/kvm/paging_tmpl.h linux-2.6.32.49/ar= ch/x86/kvm/paging_tmpl.h ---- linux-2.6.32.49/arch/x86/kvm/paging_tmpl.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/kvm/paging_tmpl.h 2011-11-18 18:01:55.00000= 0000 -0500 -@@ -416,6 +416,8 @@ static int FNAME(page_fault)(struct kvm_ +diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h +index 3bc2707..dd157e2 100644 +--- a/arch/x86/kvm/paging_tmpl.h ++++ b/arch/x86/kvm/paging_tmpl.h +@@ -416,6 +416,8 @@ static int FNAME(page_fault)(struct kvm_vcpu *vcpu, = gva_t addr, int level =3D PT_PAGE_TABLE_LEVEL; unsigned long mmu_seq; =20 @@ -19814,7 +21022,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/paging_tm= pl.h linux-2.6.32.49/arch/x86/k pgprintk("%s: addr %lx err %x\n", __func__, addr, error_code); kvm_mmu_audit(vcpu, "pre page fault"); =20 -@@ -461,6 +463,7 @@ static int FNAME(page_fault)(struct kvm_ +@@ -461,6 +463,7 @@ static int FNAME(page_fault)(struct kvm_vcpu *vcpu, = gva_t addr, kvm_mmu_free_some_pages(vcpu); sptep =3D FNAME(fetch)(vcpu, addr, &walker, user_fault, write_fault, level, &write_pt, pfn); @@ -19822,10 +21030,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/paging_= tmpl.h linux-2.6.32.49/arch/x86/k pgprintk("%s: shadow pte %p %llx ptwrite %d\n", __func__, sptep, *sptep, write_pt); =20 -diff -urNp linux-2.6.32.49/arch/x86/kvm/svm.c linux-2.6.32.49/arch/x86/k= vm/svm.c ---- linux-2.6.32.49/arch/x86/kvm/svm.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/x86/kvm/svm.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -2486,7 +2486,11 @@ static void reload_tss(struct kvm_vcpu * +diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c +index 7c6e63e..c5d92c1 100644 +--- a/arch/x86/kvm/svm.c ++++ b/arch/x86/kvm/svm.c +@@ -2486,7 +2486,11 @@ static void reload_tss(struct kvm_vcpu *vcpu) int cpu =3D raw_smp_processor_id(); =20 struct svm_cpu_data *svm_data =3D per_cpu(svm_data, cpu); @@ -19846,9 +21055,10 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/svm.c li= nux-2.6.32.49/arch/x86/kvm/svm.c .cpu_has_kvm_support =3D has_svm, .disabled_by_bios =3D is_disabled, .hardware_setup =3D svm_hardware_setup, -diff -urNp linux-2.6.32.49/arch/x86/kvm/vmx.c linux-2.6.32.49/arch/x86/k= vm/vmx.c ---- linux-2.6.32.49/arch/x86/kvm/vmx.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/x86/kvm/vmx.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c +index e6d925f..e7a4af8 100644 +--- a/arch/x86/kvm/vmx.c ++++ b/arch/x86/kvm/vmx.c @@ -570,7 +570,11 @@ static void reload_tss(void) =20 kvm_get_gdt(&gdt); @@ -19875,7 +21085,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/vmx.c lin= ux-2.6.32.49/arch/x86/kvm/vmx.c =20 if (enable_ept && !cpu_has_vmx_ept_2m_page()) kvm_disable_largepages(); -@@ -2362,7 +2369,7 @@ static int vmx_vcpu_setup(struct vcpu_vm +@@ -2362,7 +2369,7 @@ static int vmx_vcpu_setup(struct vcpu_vmx *vmx) vmcs_writel(HOST_IDTR_BASE, dt.base); /* 22.2.4 */ =20 asm("mov $.Lkvm_vmx_return, %0" : "=3Dr"(kvm_vmx_return)); @@ -19884,7 +21094,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/vmx.c lin= ux-2.6.32.49/arch/x86/kvm/vmx.c vmcs_write32(VM_EXIT_MSR_STORE_COUNT, 0); vmcs_write32(VM_EXIT_MSR_LOAD_COUNT, 0); vmcs_write32(VM_ENTRY_MSR_LOAD_COUNT, 0); -@@ -3718,6 +3725,12 @@ static void vmx_vcpu_run(struct kvm_vcpu +@@ -3718,6 +3725,12 @@ static void vmx_vcpu_run(struct kvm_vcpu *vcpu, s= truct kvm_run *kvm_run) "jmp .Lkvm_vmx_return \n\t" ".Llaunched: " __ex(ASM_VMX_VMRESUME) "\n\t" ".Lkvm_vmx_return: " @@ -19897,7 +21107,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/vmx.c lin= ux-2.6.32.49/arch/x86/kvm/vmx.c /* Save guest registers, load host registers, keep flags */ "xchg %0, (%%"R"sp) \n\t" "mov %%"R"ax, %c[rax](%0) \n\t" -@@ -3764,8 +3777,13 @@ static void vmx_vcpu_run(struct kvm_vcpu +@@ -3764,8 +3777,13 @@ static void vmx_vcpu_run(struct kvm_vcpu *vcpu, s= truct kvm_run *kvm_run) [r15]"i"(offsetof(struct vcpu_vmx, vcpu.arch.regs[VCPU_REGS_R15])), #endif [cr2]"i"(offsetof(struct vcpu_vmx, vcpu.arch.cr2)) @@ -19912,7 +21122,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/vmx.c lin= ux-2.6.32.49/arch/x86/kvm/vmx.c #ifdef CONFIG_X86_64 , "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15" #endif -@@ -3782,7 +3800,16 @@ static void vmx_vcpu_run(struct kvm_vcpu +@@ -3782,7 +3800,16 @@ static void vmx_vcpu_run(struct kvm_vcpu *vcpu, s= truct kvm_run *kvm_run) if (vmx->rmode.irq.pending) fixup_rmode_irq(vmx); =20 @@ -19939,10 +21149,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/vmx.c l= inux-2.6.32.49/arch/x86/kvm/vmx.c .cpu_has_kvm_support =3D cpu_has_kvm_support, .disabled_by_bios =3D vmx_disabled_by_bios, .hardware_setup =3D hardware_setup, -diff -urNp linux-2.6.32.49/arch/x86/kvm/x86.c linux-2.6.32.49/arch/x86/k= vm/x86.c ---- linux-2.6.32.49/arch/x86/kvm/x86.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/x86/kvm/x86.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -82,7 +82,7 @@ static void update_cr8_intercept(struct=20 +diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c +index df1cefb..5e882ad 100644 +--- a/arch/x86/kvm/x86.c ++++ b/arch/x86/kvm/x86.c +@@ -82,7 +82,7 @@ static void update_cr8_intercept(struct kvm_vcpu *vcpu= ); static int kvm_dev_ioctl_get_supported_cpuid(struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 __user *entries); =20 @@ -19951,7 +21162,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/x86.c lin= ux-2.6.32.49/arch/x86/kvm/x86.c EXPORT_SYMBOL_GPL(kvm_x86_ops); =20 int ignore_msrs =3D 0; -@@ -1430,15 +1430,20 @@ static int kvm_vcpu_ioctl_set_cpuid2(str +@@ -1430,15 +1430,20 @@ static int kvm_vcpu_ioctl_set_cpuid2(struct kvm_= vcpu *vcpu, struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 __user *entries) { @@ -19975,7 +21186,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/x86.c lin= ux-2.6.32.49/arch/x86/kvm/x86.c vcpu->arch.cpuid_nent =3D cpuid->nent; kvm_apic_set_version(vcpu); return 0; -@@ -1451,16 +1456,20 @@ static int kvm_vcpu_ioctl_get_cpuid2(str +@@ -1451,16 +1456,20 @@ static int kvm_vcpu_ioctl_get_cpuid2(struct kvm_= vcpu *vcpu, struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 __user *entries) { @@ -19999,7 +21210,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/x86.c lin= ux-2.6.32.49/arch/x86/kvm/x86.c return 0; =20 out: -@@ -1678,7 +1687,7 @@ static int kvm_vcpu_ioctl_set_lapic(stru +@@ -1678,7 +1687,7 @@ static int kvm_vcpu_ioctl_set_lapic(struct kvm_vcp= u *vcpu, static int kvm_vcpu_ioctl_interrupt(struct kvm_vcpu *vcpu, struct kvm_interrupt *irq) { @@ -20008,7 +21219,7 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/x86.c lin= ux-2.6.32.49/arch/x86/kvm/x86.c return -EINVAL; if (irqchip_in_kernel(vcpu->kvm)) return -ENXIO; -@@ -3260,10 +3269,10 @@ static struct notifier_block kvmclock_cp +@@ -3260,10 +3269,10 @@ static struct notifier_block kvmclock_cpufreq_no= tifier_block =3D { .notifier_call =3D kvmclock_cpufreq_notifier }; =20 @@ -20021,10 +21232,11 @@ diff -urNp linux-2.6.32.49/arch/x86/kvm/x86.c l= inux-2.6.32.49/arch/x86/kvm/x86.c =20 if (kvm_x86_ops) { printk(KERN_ERR "kvm: already loaded the other module\n"); -diff -urNp linux-2.6.32.49/arch/x86/lguest/boot.c linux-2.6.32.49/arch/x= 86/lguest/boot.c ---- linux-2.6.32.49/arch/x86/lguest/boot.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/lguest/boot.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1172,9 +1172,10 @@ static __init int early_put_chars(u32 vt +diff --git a/arch/x86/lguest/boot.c b/arch/x86/lguest/boot.c +index 7e59dc1..b88c98f 100644 +--- a/arch/x86/lguest/boot.c ++++ b/arch/x86/lguest/boot.c +@@ -1172,9 +1172,10 @@ static __init int early_put_chars(u32 vtermno, co= nst char *buf, int count) * Rebooting also tells the Host we're finished, but the RESTART flag t= ells the * Launcher to reboot us. */ @@ -20036,10 +21248,11 @@ diff -urNp linux-2.6.32.49/arch/x86/lguest/boot= .c linux-2.6.32.49/arch/x86/lgues } =20 /*G:050 -diff -urNp linux-2.6.32.49/arch/x86/lib/atomic64_32.c linux-2.6.32.49/ar= ch/x86/lib/atomic64_32.c ---- linux-2.6.32.49/arch/x86/lib/atomic64_32.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/atomic64_32.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -25,6 +25,12 @@ u64 atomic64_cmpxchg(atomic64_t *ptr, u6 +diff --git a/arch/x86/lib/atomic64_32.c b/arch/x86/lib/atomic64_32.c +index 824fa0b..c619e96 100644 +--- a/arch/x86/lib/atomic64_32.c ++++ b/arch/x86/lib/atomic64_32.c +@@ -25,6 +25,12 @@ u64 atomic64_cmpxchg(atomic64_t *ptr, u64 old_val, u6= 4 new_val) } EXPORT_SYMBOL(atomic64_cmpxchg); =20 @@ -20052,7 +21265,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/atomic64_= 32.c linux-2.6.32.49/arch/x86/l /** * atomic64_xchg - xchg atomic64 variable * @ptr: pointer to type atomic64_t -@@ -56,6 +62,36 @@ u64 atomic64_xchg(atomic64_t *ptr, u64 n +@@ -56,6 +62,36 @@ u64 atomic64_xchg(atomic64_t *ptr, u64 new_val) EXPORT_SYMBOL(atomic64_xchg); =20 /** @@ -20089,7 +21302,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/atomic64_= 32.c linux-2.6.32.49/arch/x86/l * atomic64_set - set atomic64 variable * @ptr: pointer to type atomic64_t * @new_val: value to assign -@@ -69,7 +105,19 @@ void atomic64_set(atomic64_t *ptr, u64 n +@@ -69,7 +105,19 @@ void atomic64_set(atomic64_t *ptr, u64 new_val) EXPORT_SYMBOL(atomic64_set); =20 /** @@ -20110,7 +21323,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/atomic64_= 32.c linux-2.6.32.49/arch/x86/l * atomic64_add_return - add and return * @delta: integer value to add * @ptr: pointer to type atomic64_t -@@ -99,24 +147,72 @@ noinline u64 atomic64_add_return(u64 del +@@ -99,24 +147,72 @@ noinline u64 atomic64_add_return(u64 delta, atomic6= 4_t *ptr) } EXPORT_SYMBOL(atomic64_add_return); =20 @@ -20183,7 +21396,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/atomic64_= 32.c linux-2.6.32.49/arch/x86/l /** * atomic64_add - add integer to atomic64 variable * @delta: integer value to add -@@ -131,6 +227,19 @@ void atomic64_add(u64 delta, atomic64_t=20 +@@ -131,6 +227,19 @@ void atomic64_add(u64 delta, atomic64_t *ptr) EXPORT_SYMBOL(atomic64_add); =20 /** @@ -20203,7 +21416,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/atomic64_= 32.c linux-2.6.32.49/arch/x86/l * atomic64_sub - subtract the atomic64 variable * @delta: integer value to subtract * @ptr: pointer to type atomic64_t -@@ -144,6 +253,19 @@ void atomic64_sub(u64 delta, atomic64_t=20 +@@ -144,6 +253,19 @@ void atomic64_sub(u64 delta, atomic64_t *ptr) EXPORT_SYMBOL(atomic64_sub); =20 /** @@ -20261,9 +21474,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/atomic64= _32.c linux-2.6.32.49/arch/x86/l * atomic64_dec_and_test - decrement and test * @ptr: pointer to type atomic64_t * -diff -urNp linux-2.6.32.49/arch/x86/lib/checksum_32.S linux-2.6.32.49/ar= ch/x86/lib/checksum_32.S ---- linux-2.6.32.49/arch/x86/lib/checksum_32.S 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/checksum_32.S 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/arch/x86/lib/checksum_32.S b/arch/x86/lib/checksum_32.S +index adbccd0..98f96c8 100644 +--- a/arch/x86/lib/checksum_32.S ++++ b/arch/x86/lib/checksum_32.S @@ -28,7 +28,8 @@ #include #include @@ -20274,7 +21488,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/checksum_= 32.S linux-2.6.32.49/arch/x86/l /* * computes a partial checksum, e.g. for TCP/UDP fragments */ -@@ -304,9 +305,28 @@ unsigned int csum_partial_copy_generic ( +@@ -304,9 +305,28 @@ unsigned int csum_partial_copy_generic (const char = *src, char *dst, =20 #define ARGBASE 16 =09 #define FP 12 @@ -20524,9 +21738,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/checksum= _32.S linux-2.6.32.49/arch/x86/l =09 #undef ROUND #undef ROUND1 =09 -diff -urNp linux-2.6.32.49/arch/x86/lib/clear_page_64.S linux-2.6.32.49/= arch/x86/lib/clear_page_64.S ---- linux-2.6.32.49/arch/x86/lib/clear_page_64.S 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/clear_page_64.S 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/arch/x86/lib/clear_page_64.S b/arch/x86/lib/clear_page_64.S +index ebeafcc..1e3a402 100644 +--- a/arch/x86/lib/clear_page_64.S ++++ b/arch/x86/lib/clear_page_64.S @@ -1,5 +1,6 @@ #include #include @@ -20559,9 +21774,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/clear_pa= ge_64.S linux-2.6.32.49/arch/x86 1: .byte 0xeb /* jmp */ .byte (clear_page_c - clear_page) - (2f - 1b) /* offset */ 2: -diff -urNp linux-2.6.32.49/arch/x86/lib/copy_page_64.S linux-2.6.32.49/a= rch/x86/lib/copy_page_64.S ---- linux-2.6.32.49/arch/x86/lib/copy_page_64.S 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/copy_page_64.S 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/arch/x86/lib/copy_page_64.S b/arch/x86/lib/copy_page_64.S +index 727a5d4..333818a 100644 +--- a/arch/x86/lib/copy_page_64.S ++++ b/arch/x86/lib/copy_page_64.S @@ -2,12 +2,14 @@ =20 #include @@ -20577,6 +21793,42 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/copy_pag= e_64.S linux-2.6.32.49/arch/x86/ ret CFI_ENDPROC ENDPROC(copy_page_c) +@@ -38,7 +40,7 @@ ENTRY(copy_page) + movq 16 (%rsi), %rdx + movq 24 (%rsi), %r8 + movq 32 (%rsi), %r9 +- movq 40 (%rsi), %r10 ++ movq 40 (%rsi), %r13 + movq 48 (%rsi), %r11 + movq 56 (%rsi), %r12 +=20 +@@ -49,7 +51,7 @@ ENTRY(copy_page) + movq %rdx, 16 (%rdi) + movq %r8, 24 (%rdi) + movq %r9, 32 (%rdi) +- movq %r10, 40 (%rdi) ++ movq %r13, 40 (%rdi) + movq %r11, 48 (%rdi) + movq %r12, 56 (%rdi) +=20 +@@ -68,7 +70,7 @@ ENTRY(copy_page) + movq 16 (%rsi), %rdx + movq 24 (%rsi), %r8 + movq 32 (%rsi), %r9 +- movq 40 (%rsi), %r10 ++ movq 40 (%rsi), %r13 + movq 48 (%rsi), %r11 + movq 56 (%rsi), %r12 +=20 +@@ -77,7 +79,7 @@ ENTRY(copy_page) + movq %rdx, 16 (%rdi) + movq %r8, 24 (%rdi) + movq %r9, 32 (%rdi) +- movq %r10, 40 (%rdi) ++ movq %r13, 40 (%rdi) + movq %r11, 48 (%rdi) + movq %r12, 56 (%rdi) +=20 @@ -94,6 +96,7 @@ ENTRY(copy_page) CFI_RESTORE r13 addq $3*8,%rsp @@ -20594,9 +21846,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/copy_pag= e_64.S linux-2.6.32.49/arch/x86/ 1: .byte 0xeb /* jmp */ .byte (copy_page_c - copy_page) - (2f - 1b) /* offset */ 2: -diff -urNp linux-2.6.32.49/arch/x86/lib/copy_user_64.S linux-2.6.32.49/a= rch/x86/lib/copy_user_64.S ---- linux-2.6.32.49/arch/x86/lib/copy_user_64.S 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/copy_user_64.S 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/arch/x86/lib/copy_user_64.S b/arch/x86/lib/copy_user_64.S +index af8debd..40c75f3 100644 +--- a/arch/x86/lib/copy_user_64.S ++++ b/arch/x86/lib/copy_user_64.S @@ -15,13 +15,15 @@ #include #include @@ -20673,6 +21926,30 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/copy_use= r_64.S linux-2.6.32.49/arch/x86/ ret CFI_ENDPROC ENDPROC(bad_from_user) +@@ -142,19 +115,19 @@ ENTRY(copy_user_generic_unrolled) + jz 17f + 1: movq (%rsi),%r8 + 2: movq 1*8(%rsi),%r9 +-3: movq 2*8(%rsi),%r10 ++3: movq 2*8(%rsi),%rax + 4: movq 3*8(%rsi),%r11 + 5: movq %r8,(%rdi) + 6: movq %r9,1*8(%rdi) +-7: movq %r10,2*8(%rdi) ++7: movq %rax,2*8(%rdi) + 8: movq %r11,3*8(%rdi) + 9: movq 4*8(%rsi),%r8 + 10: movq 5*8(%rsi),%r9 +-11: movq 6*8(%rsi),%r10 ++11: movq 6*8(%rsi),%rax + 12: movq 7*8(%rsi),%r11 + 13: movq %r8,4*8(%rdi) + 14: movq %r9,5*8(%rdi) +-15: movq %r10,6*8(%rdi) ++15: movq %rax,6*8(%rdi) + 16: movq %r11,7*8(%rdi) + leaq 64(%rsi),%rsi + leaq 64(%rdi),%rdi @@ -180,6 +153,7 @@ ENTRY(copy_user_generic_unrolled) decl %ecx jnz 21b @@ -20689,9 +21966,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/copy_use= r_64.S linux-2.6.32.49/arch/x86/ ret =20 .section .fixup,"ax" -diff -urNp linux-2.6.32.49/arch/x86/lib/copy_user_nocache_64.S linux-2.6= .32.49/arch/x86/lib/copy_user_nocache_64.S ---- linux-2.6.32.49/arch/x86/lib/copy_user_nocache_64.S 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/copy_user_nocache_64.S 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/arch/x86/lib/copy_user_nocache_64.S b/arch/x86/lib/copy_use= r_nocache_64.S +index cb0c112..e3a6895 100644 +--- a/arch/x86/lib/copy_user_nocache_64.S ++++ b/arch/x86/lib/copy_user_nocache_64.S @@ -8,12 +8,14 @@ =20 #include @@ -20723,6 +22001,30 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/copy_use= r_nocache_64.S linux-2.6.32.49/a cmpl $8,%edx jb 20f /* less then 8 bytes, go to byte copy loop */ ALIGN_DESTINATION +@@ -59,19 +70,19 @@ ENTRY(__copy_user_nocache) + jz 17f + 1: movq (%rsi),%r8 + 2: movq 1*8(%rsi),%r9 +-3: movq 2*8(%rsi),%r10 ++3: movq 2*8(%rsi),%rax + 4: movq 3*8(%rsi),%r11 + 5: movnti %r8,(%rdi) + 6: movnti %r9,1*8(%rdi) +-7: movnti %r10,2*8(%rdi) ++7: movnti %rax,2*8(%rdi) + 8: movnti %r11,3*8(%rdi) + 9: movq 4*8(%rsi),%r8 + 10: movq 5*8(%rsi),%r9 +-11: movq 6*8(%rsi),%r10 ++11: movq 6*8(%rsi),%rax + 12: movq 7*8(%rsi),%r11 + 13: movnti %r8,4*8(%rdi) + 14: movnti %r9,5*8(%rdi) +-15: movnti %r10,6*8(%rdi) ++15: movnti %rax,6*8(%rdi) + 16: movnti %r11,7*8(%rdi) + leaq 64(%rsi),%rsi + leaq 64(%rdi),%rdi @@ -98,6 +109,7 @@ ENTRY(__copy_user_nocache) jnz 21b 23: xorl %eax,%eax @@ -20731,9 +22033,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/copy_use= r_nocache_64.S linux-2.6.32.49/a ret =20 .section .fixup,"ax" -diff -urNp linux-2.6.32.49/arch/x86/lib/csum-copy_64.S linux-2.6.32.49/a= rch/x86/lib/csum-copy_64.S ---- linux-2.6.32.49/arch/x86/lib/csum-copy_64.S 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/csum-copy_64.S 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/arch/x86/lib/csum-copy_64.S b/arch/x86/lib/csum-copy_64.S +index f0dba36..48cb4d6 100644 +--- a/arch/x86/lib/csum-copy_64.S ++++ b/arch/x86/lib/csum-copy_64.S @@ -8,6 +8,7 @@ #include #include @@ -20746,14 +22049,15 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/csum-co= py_64.S linux-2.6.32.49/arch/x86/ CFI_RESTORE rbp addq $7*8,%rsp CFI_ADJUST_CFA_OFFSET -7*8 -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret CFI_RESTORE_STATE =20 -diff -urNp linux-2.6.32.49/arch/x86/lib/csum-wrappers_64.c linux-2.6.32.= 49/arch/x86/lib/csum-wrappers_64.c ---- linux-2.6.32.49/arch/x86/lib/csum-wrappers_64.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/csum-wrappers_64.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -52,7 +52,13 @@ csum_partial_copy_from_user(const void _ +diff --git a/arch/x86/lib/csum-wrappers_64.c b/arch/x86/lib/csum-wrapper= s_64.c +index 459b58a..9570bc7 100644 +--- a/arch/x86/lib/csum-wrappers_64.c ++++ b/arch/x86/lib/csum-wrappers_64.c +@@ -52,7 +52,13 @@ csum_partial_copy_from_user(const void __user *src, v= oid *dst, len -=3D 2; } } @@ -20768,7 +22072,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/csum-wrap= pers_64.c linux-2.6.32.49/arch/ dst, len, isum, errp, NULL); if (unlikely(*errp)) goto out_err; -@@ -105,7 +111,13 @@ csum_partial_copy_to_user(const void *sr +@@ -105,7 +111,13 @@ csum_partial_copy_to_user(const void *src, void __u= ser *dst, } =20 *errp =3D 0; @@ -20783,9 +22087,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/csum-wra= ppers_64.c linux-2.6.32.49/arch/ len, isum, NULL, errp); } EXPORT_SYMBOL(csum_partial_copy_to_user); -diff -urNp linux-2.6.32.49/arch/x86/lib/getuser.S linux-2.6.32.49/arch/x= 86/lib/getuser.S ---- linux-2.6.32.49/arch/x86/lib/getuser.S 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/lib/getuser.S 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/lib/getuser.S b/arch/x86/lib/getuser.S +index 51f1504..ddac4c1 100644 +--- a/arch/x86/lib/getuser.S ++++ b/arch/x86/lib/getuser.S @@ -33,15 +33,38 @@ #include #include @@ -20909,9 +22214,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/getuser.= S linux-2.6.32.49/arch/x86/lib/g ret CFI_ENDPROC END(bad_get_user) -diff -urNp linux-2.6.32.49/arch/x86/lib/iomap_copy_64.S linux-2.6.32.49/= arch/x86/lib/iomap_copy_64.S ---- linux-2.6.32.49/arch/x86/lib/iomap_copy_64.S 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/iomap_copy_64.S 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/arch/x86/lib/iomap_copy_64.S b/arch/x86/lib/iomap_copy_64.S +index 05a95e7..326f2fa 100644 +--- a/arch/x86/lib/iomap_copy_64.S ++++ b/arch/x86/lib/iomap_copy_64.S @@ -17,6 +17,7 @@ =20 #include @@ -20928,9 +22234,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/iomap_co= py_64.S linux-2.6.32.49/arch/x86 ret CFI_ENDPROC ENDPROC(__iowrite32_copy) -diff -urNp linux-2.6.32.49/arch/x86/lib/memcpy_64.S linux-2.6.32.49/arch= /x86/lib/memcpy_64.S ---- linux-2.6.32.49/arch/x86/lib/memcpy_64.S 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/lib/memcpy_64.S 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/lib/memcpy_64.S b/arch/x86/lib/memcpy_64.S +index ad5441e..610e351 100644 +--- a/arch/x86/lib/memcpy_64.S ++++ b/arch/x86/lib/memcpy_64.S @@ -4,6 +4,7 @@ =20 #include @@ -20951,7 +22258,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/memcpy_64= .S linux-2.6.32.49/arch/x86/lib jnz .Lloop_1 =20 .Lend: -+ pax_force_retaddr ++ pax_force_retaddr 0, 1 ret CFI_ENDPROC ENDPROC(memcpy) @@ -20964,9 +22271,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/memcpy_6= 4.S linux-2.6.32.49/arch/x86/lib 1: .byte 0xeb /* jmp */ .byte (memcpy_c - memcpy) - (2f - 1b) /* offset */ 2: -diff -urNp linux-2.6.32.49/arch/x86/lib/memset_64.S linux-2.6.32.49/arch= /x86/lib/memset_64.S ---- linux-2.6.32.49/arch/x86/lib/memset_64.S 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/lib/memset_64.S 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/lib/memset_64.S b/arch/x86/lib/memset_64.S +index 2c59481..7e9ba4e 100644 +--- a/arch/x86/lib/memset_64.S ++++ b/arch/x86/lib/memset_64.S @@ -2,6 +2,7 @@ =20 #include @@ -20983,10 +22291,27 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/memset_= 64.S linux-2.6.32.49/arch/x86/lib ret CFI_ENDPROC ENDPROC(memset_c) -@@ -96,6 +98,7 @@ ENTRY(__memset) +@@ -35,13 +37,13 @@ ENDPROC(memset_c) + ENTRY(memset) + ENTRY(__memset) + CFI_STARTPROC +- movq %rdi,%r10 + movq %rdx,%r11 +=20 + /* expand byte value */ + movzbl %sil,%ecx + movabs $0x0101010101010101,%rax + mul %rcx /* with rax, clobbers rdx */ ++ movq %rdi,%rdx +=20 + /* align dst */ + movl %edi,%r9d +@@ -95,7 +97,8 @@ ENTRY(__memset) + jnz .Lloop_1 =20 .Lende: - movq %r10,%rax +- movq %r10,%rax ++ movq %rdx,%rax + pax_force_retaddr ret =20 @@ -21000,10 +22325,11 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/memset_= 64.S linux-2.6.32.49/arch/x86/lib 1: .byte 0xeb /* jmp */ .byte (memset_c - memset) - (2f - 1b) /* offset */ 2: -diff -urNp linux-2.6.32.49/arch/x86/lib/mmx_32.c linux-2.6.32.49/arch/x8= 6/lib/mmx_32.c ---- linux-2.6.32.49/arch/x86/lib/mmx_32.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/lib/mmx_32.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -29,6 +29,7 @@ void *_mmx_memcpy(void *to, const void * +diff --git a/arch/x86/lib/mmx_32.c b/arch/x86/lib/mmx_32.c +index c9f2d9b..e7fd2c0 100644 +--- a/arch/x86/lib/mmx_32.c ++++ b/arch/x86/lib/mmx_32.c +@@ -29,6 +29,7 @@ void *_mmx_memcpy(void *to, const void *from, size_t l= en) { void *p; int i; @@ -21011,7 +22337,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/mmx_32.c = linux-2.6.32.49/arch/x86/lib/mm =20 if (unlikely(in_interrupt())) return __memcpy(to, from, len); -@@ -39,44 +40,72 @@ void *_mmx_memcpy(void *to, const void * +@@ -39,44 +40,72 @@ void *_mmx_memcpy(void *to, const void *from, size_t= len) kernel_fpu_begin(); =20 __asm__ __volatile__ ( @@ -21118,7 +22444,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/mmx_32.c = linux-2.6.32.49/arch/x86/lib/mm =20 kernel_fpu_begin(); =20 -@@ -166,42 +196,70 @@ static void fast_copy_page(void *to, voi +@@ -166,42 +196,70 @@ static void fast_copy_page(void *to, void *from) * but that is for later. -AV */ __asm__ __volatile__( @@ -21318,9 +22644,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/mmx_32.c= linux-2.6.32.49/arch/x86/lib/mm =20 from +=3D 64; to +=3D 64; -diff -urNp linux-2.6.32.49/arch/x86/lib/msr-reg.S linux-2.6.32.49/arch/x= 86/lib/msr-reg.S ---- linux-2.6.32.49/arch/x86/lib/msr-reg.S 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/lib/msr-reg.S 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/lib/msr-reg.S b/arch/x86/lib/msr-reg.S +index 69fa106..adda88b 100644 +--- a/arch/x86/lib/msr-reg.S ++++ b/arch/x86/lib/msr-reg.S @@ -3,6 +3,7 @@ #include #include @@ -21329,17 +22656,44 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/msr-reg= .S linux-2.6.32.49/arch/x86/lib/m =20 #ifdef CONFIG_X86_64 /* -@@ -37,6 +38,7 @@ ENTRY(native_\op\()_safe_regs) - movl %edi, 28(%r10) +@@ -16,7 +17,7 @@ ENTRY(native_\op\()_safe_regs) + CFI_STARTPROC + pushq_cfi %rbx + pushq_cfi %rbp +- movq %rdi, %r10 /* Save pointer */ ++ movq %rdi, %r9 /* Save pointer */ + xorl %r11d, %r11d /* Return value */ + movl (%rdi), %eax + movl 4(%rdi), %ecx +@@ -27,16 +28,17 @@ ENTRY(native_\op\()_safe_regs) + movl 28(%rdi), %edi + CFI_REMEMBER_STATE + 1: \op +-2: movl %eax, (%r10) ++2: movl %eax, (%r9) + movl %r11d, %eax /* Return value */ +- movl %ecx, 4(%r10) +- movl %edx, 8(%r10) +- movl %ebx, 12(%r10) +- movl %ebp, 20(%r10) +- movl %esi, 24(%r10) +- movl %edi, 28(%r10) ++ movl %ecx, 4(%r9) ++ movl %edx, 8(%r9) ++ movl %ebx, 12(%r9) ++ movl %ebp, 20(%r9) ++ movl %esi, 24(%r9) ++ movl %edi, 28(%r9) popq_cfi %rbp popq_cfi %rbx + pax_force_retaddr ret 3: CFI_RESTORE_STATE -diff -urNp linux-2.6.32.49/arch/x86/lib/putuser.S linux-2.6.32.49/arch/x= 86/lib/putuser.S ---- linux-2.6.32.49/arch/x86/lib/putuser.S 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/lib/putuser.S 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/lib/putuser.S b/arch/x86/lib/putuser.S +index 36b0d15..d381858 100644 +--- a/arch/x86/lib/putuser.S ++++ b/arch/x86/lib/putuser.S @@ -15,7 +15,9 @@ #include #include @@ -21479,9 +22833,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/putuser.= S linux-2.6.32.49/arch/x86/lib/p #endif xor %eax,%eax EXIT -diff -urNp linux-2.6.32.49/arch/x86/lib/rwlock_64.S linux-2.6.32.49/arch= /x86/lib/rwlock_64.S ---- linux-2.6.32.49/arch/x86/lib/rwlock_64.S 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/lib/rwlock_64.S 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/lib/rwlock_64.S b/arch/x86/lib/rwlock_64.S +index 05ea55f..f81311a 100644 +--- a/arch/x86/lib/rwlock_64.S ++++ b/arch/x86/lib/rwlock_64.S @@ -17,6 +17,7 @@ ENTRY(__write_lock_failed) LOCK_PREFIX subl $RW_LOCK_BIAS,(%rdi) @@ -21498,9 +22853,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/rwlock_6= 4.S linux-2.6.32.49/arch/x86/lib ret CFI_ENDPROC END(__read_lock_failed) -diff -urNp linux-2.6.32.49/arch/x86/lib/rwsem_64.S linux-2.6.32.49/arch/= x86/lib/rwsem_64.S ---- linux-2.6.32.49/arch/x86/lib/rwsem_64.S 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/lib/rwsem_64.S 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/lib/rwsem_64.S b/arch/x86/lib/rwsem_64.S +index 15acecf..f768b10 100644 +--- a/arch/x86/lib/rwsem_64.S ++++ b/arch/x86/lib/rwsem_64.S @@ -48,6 +48,7 @@ ENTRY(call_rwsem_down_read_failed) call rwsem_down_read_failed popq %rdx @@ -21534,9 +22890,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/rwsem_64= .S linux-2.6.32.49/arch/x86/lib/ + pax_force_retaddr ret ENDPROC(call_rwsem_downgrade_wake) -diff -urNp linux-2.6.32.49/arch/x86/lib/thunk_64.S linux-2.6.32.49/arch/= x86/lib/thunk_64.S ---- linux-2.6.32.49/arch/x86/lib/thunk_64.S 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/lib/thunk_64.S 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/lib/thunk_64.S b/arch/x86/lib/thunk_64.S +index bf9a7d5..fb06ab5 100644 +--- a/arch/x86/lib/thunk_64.S ++++ b/arch/x86/lib/thunk_64.S @@ -10,7 +10,8 @@ #include #include =09 @@ -21562,9 +22919,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/thunk_64= .S linux-2.6.32.49/arch/x86/lib/ + pax_force_retaddr ret CFI_ENDPROC -diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_32.c linux-2.6.32.49/ar= ch/x86/lib/usercopy_32.c ---- linux-2.6.32.49/arch/x86/lib/usercopy_32.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/usercopy_32.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/arch/x86/lib/usercopy_32.c b/arch/x86/lib/usercopy_32.c +index 1f118d4..ec4a953 100644 +--- a/arch/x86/lib/usercopy_32.c ++++ b/arch/x86/lib/usercopy_32.c @@ -43,7 +43,7 @@ do { \ __asm__ __volatile__( \ " testl %1,%1\n" \ @@ -21587,7 +22945,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l ".section .fixup,\"ax\"\n" \ "3: lea 0(%2,%0,4),%0\n" \ " jmp 2b\n" \ -@@ -200,6 +202,7 @@ long strnlen_user(const char __user *s,=20 +@@ -200,6 +202,7 @@ long strnlen_user(const char __user *s, long n) might_fault(); =20 __asm__ __volatile__( @@ -21595,7 +22953,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l " testl %0, %0\n" " jz 3f\n" " andl %0,%%ecx\n" -@@ -208,6 +211,7 @@ long strnlen_user(const char __user *s,=20 +@@ -208,6 +211,7 @@ long strnlen_user(const char __user *s, long n) " subl %%ecx,%0\n" " addl %0,%%eax\n" "1:\n" @@ -21612,7 +22970,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l { int d0, d1; __asm__ __volatile__( -@@ -239,36 +243,36 @@ __copy_user_intel(void __user *to, const +@@ -239,36 +243,36 @@ __copy_user_intel(void __user *to, const void *fro= m, unsigned long size) " .align 2,0x90\n" "3: movl 0(%4), %%eax\n" "4: movl 4(%4), %%edx\n" @@ -21665,7 +23023,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l " addl $-64, %0\n" " addl $64, %4\n" " addl $64, %3\n" -@@ -278,10 +282,119 @@ __copy_user_intel(void __user *to, const +@@ -278,10 +282,119 @@ __copy_user_intel(void __user *to, const void *fr= om, unsigned long size) " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -21785,7 +23143,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l ".section .fixup,\"ax\"\n" "101: lea 0(%%eax,%0,4),%0\n" " jmp 100b\n" -@@ -339,41 +452,41 @@ __copy_user_zeroing_intel(void *to, cons +@@ -339,41 +452,41 @@ __copy_user_zeroing_intel(void *to, const void __u= ser *from, unsigned long size) int d0, d1; __asm__ __volatile__( " .align 2,0x90\n" @@ -21845,7 +23203,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l " movl %%eax, 56(%3)\n" " movl %%edx, 60(%3)\n" " addl $-64, %0\n" -@@ -385,9 +498,9 @@ __copy_user_zeroing_intel(void *to, cons +@@ -385,9 +498,9 @@ __copy_user_zeroing_intel(void *to, const void __use= r *from, unsigned long size) " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -21857,7 +23215,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l "8:\n" ".section .fixup,\"ax\"\n" "9: lea 0(%%eax,%0,4),%0\n" -@@ -440,41 +553,41 @@ static unsigned long __copy_user_zeroing +@@ -440,41 +553,41 @@ static unsigned long __copy_user_zeroing_intel_noc= ache(void *to, =20 __asm__ __volatile__( " .align 2,0x90\n" @@ -21917,7 +23275,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l " movnti %%eax, 56(%3)\n" " movnti %%edx, 60(%3)\n" " addl $-64, %0\n" -@@ -487,9 +600,9 @@ static unsigned long __copy_user_zeroing +@@ -487,9 +600,9 @@ static unsigned long __copy_user_zeroing_intel_nocac= he(void *to, " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -21929,7 +23287,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l "8:\n" ".section .fixup,\"ax\"\n" "9: lea 0(%%eax,%0,4),%0\n" -@@ -537,41 +650,41 @@ static unsigned long __copy_user_intel_n +@@ -537,41 +650,41 @@ static unsigned long __copy_user_intel_nocache(voi= d *to, =20 __asm__ __volatile__( " .align 2,0x90\n" @@ -21989,7 +23347,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l " movnti %%eax, 56(%3)\n" " movnti %%edx, 60(%3)\n" " addl $-64, %0\n" -@@ -584,9 +697,9 @@ static unsigned long __copy_user_intel_n +@@ -584,9 +697,9 @@ static unsigned long __copy_user_intel_nocache(void = *to, " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -22001,7 +23359,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l "8:\n" ".section .fixup,\"ax\"\n" "9: lea 0(%%eax,%0,4),%0\n" -@@ -629,32 +742,36 @@ static unsigned long __copy_user_intel_n +@@ -629,32 +742,36 @@ static unsigned long __copy_user_intel_nocache(voi= d *to, */ unsigned long __copy_user_zeroing_intel(void *to, const void __user *fr= om, unsigned long size); @@ -22073,7 +23431,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l return n; } EXPORT_SYMBOL(__copy_to_user_ll); -@@ -797,10 +914,9 @@ unsigned long __copy_from_user_ll_nozero +@@ -797,10 +914,9 @@ unsigned long __copy_from_user_ll_nozero(void *to, = const void __user *from, unsigned long n) { if (movsl_is_ok(to, from, n)) @@ -22086,7 +23444,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 32.c linux-2.6.32.49/arch/x86/l return n; } EXPORT_SYMBOL(__copy_from_user_ll_nozero); -@@ -827,59 +943,38 @@ unsigned long __copy_from_user_ll_nocach +@@ -827,59 +943,38 @@ unsigned long __copy_from_user_ll_nocache_nozero(v= oid *to, const void __user *fr if (n > 64 && cpu_has_xmm2) n =3D __copy_user_intel_nocache(to, from, n); else @@ -22170,9 +23528,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy= _32.c linux-2.6.32.49/arch/x86/l -EXPORT_SYMBOL(copy_from_user); +EXPORT_SYMBOL(set_fs); +#endif -diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_64.c linux-2.6.32.49/ar= ch/x86/lib/usercopy_64.c ---- linux-2.6.32.49/arch/x86/lib/usercopy_64.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/lib/usercopy_64.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/arch/x86/lib/usercopy_64.c b/arch/x86/lib/usercopy_64.c +index b7c2849..5ef0f95 100644 +--- a/arch/x86/lib/usercopy_64.c ++++ b/arch/x86/lib/usercopy_64.c @@ -42,6 +42,12 @@ long __strncpy_from_user(char *dst, const char __user *src, long count) { @@ -22186,7 +23545,7 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercopy_= 64.c linux-2.6.32.49/arch/x86/l __do_strncpy_from_user(dst, src, count, res); return res; } -@@ -65,6 +71,12 @@ unsigned long __clear_user(void __user * +@@ -65,6 +71,12 @@ unsigned long __clear_user(void __user *addr, unsigne= d long size) { long __d0; might_fault(); @@ -22231,33 +23590,10 @@ diff -urNp linux-2.6.32.49/arch/x86/lib/usercop= y_64.c linux-2.6.32.49/arch/x86/l { char c; unsigned zero_len; -diff -urNp linux-2.6.32.49/arch/x86/Makefile linux-2.6.32.49/arch/x86/Ma= kefile ---- linux-2.6.32.49/arch/x86/Makefile 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/arch/x86/Makefile 2011-11-15 19:59:43.000000000 -050= 0 -@@ -44,6 +44,7 @@ ifeq ($(CONFIG_X86_32),y) - else - BITS :=3D 64 - UTS_MACHINE :=3D x86_64 -+ biarch :=3D $(call cc-option,-m64) - CHECKFLAGS +=3D -D__x86_64__ -m64 -=20 - KBUILD_AFLAGS +=3D -m64 -@@ -189,3 +190,12 @@ define archhelp - echo ' FDARGS=3D"..." arguments for the booted ker= nel' - echo ' FDINITRD=3Dfile initrd for the booted kernel= ' - endef -+ -+define OLD_LD -+ -+*** ${VERSION}.${PATCHLEVEL} PaX kernels no longer build correctly with= old versions of binutils. -+*** Please upgrade your binutils to 2.18 or newer -+endef -+ -+archprepare: -+ $(if $(LDFLAGS_BUILD_ID),,$(error $(OLD_LD))) -diff -urNp linux-2.6.32.49/arch/x86/mm/extable.c linux-2.6.32.49/arch/x8= 6/mm/extable.c ---- linux-2.6.32.49/arch/x86/mm/extable.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/mm/extable.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/arch/x86/mm/extable.c b/arch/x86/mm/extable.c +index 61b41ca..5fef66a 100644 +--- a/arch/x86/mm/extable.c ++++ b/arch/x86/mm/extable.c @@ -1,14 +1,71 @@ #include #include @@ -22331,9 +23667,10 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/extable.c= linux-2.6.32.49/arch/x86/mm/ext extern u32 pnp_bios_fault_eip, pnp_bios_fault_esp; extern u32 pnp_bios_is_utter_crap; pnp_bios_is_utter_crap =3D 1; -diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c linux-2.6.32.49/arch/x86/= mm/fault.c ---- linux-2.6.32.49/arch/x86/mm/fault.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/x86/mm/fault.c 2011-11-18 18:07:11.000000000 -0= 500 +diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c +index 8ac0d76..3f191dc 100644 +--- a/arch/x86/mm/fault.c ++++ b/arch/x86/mm/fault.c @@ -11,10 +11,19 @@ #include /* __kprobes, ... */ #include /* kmmio_handler, ... */ @@ -22354,7 +23691,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault =20 /* * Page fault error code bits: -@@ -51,7 +60,7 @@ static inline int notify_page_fault(stru +@@ -51,7 +60,7 @@ static inline int notify_page_fault(struct pt_regs *re= gs) int ret =3D 0; =20 /* kprobe_running() needs smp_processor_id() */ @@ -22363,7 +23700,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault preempt_disable(); if (kprobe_running() && kprobe_fault_handler(regs, 14)) ret =3D 1; -@@ -112,7 +121,10 @@ check_prefetch_opcode(struct pt_regs *re +@@ -112,7 +121,10 @@ check_prefetch_opcode(struct pt_regs *regs, unsigne= d char *instr, return !instr_lo || (instr_lo>>1) =3D=3D 1; case 0x00: /* Prefetch instruction is 0x0F0D or 0x0F18 */ @@ -22375,7 +23712,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault return 0; =20 *prefetch =3D (instr_lo =3D=3D 0xF) && -@@ -146,7 +158,10 @@ is_prefetch(struct pt_regs *regs, unsign +@@ -146,7 +158,10 @@ is_prefetch(struct pt_regs *regs, unsigned long err= or_code, unsigned long addr) while (instr < max_instr) { unsigned char opcode; =20 @@ -22387,7 +23724,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault break; =20 instr++; -@@ -172,6 +187,34 @@ force_sig_info_fault(int si_signo, int s +@@ -172,6 +187,34 @@ force_sig_info_fault(int si_signo, int si_code, uns= igned long address, force_sig_info(si_signo, &info, tsk); } =20 @@ -22448,7 +23785,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault break; } spin_unlock_irqrestore(&pgd_lock, flags); -@@ -258,6 +314,11 @@ static noinline int vmalloc_fault(unsign +@@ -258,6 +314,11 @@ static noinline int vmalloc_fault(unsigned long add= ress) * an interrupt in the middle of a task switch.. */ pgd_paddr =3D read_cr3(); @@ -22488,7 +23825,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault if (pgd_none(*pgd)) set_pgd(pgd, *pgd_ref); else -@@ -373,7 +446,14 @@ static noinline int vmalloc_fault(unsign +@@ -373,7 +446,14 @@ static noinline int vmalloc_fault(unsigned long add= ress) * happen within a race in page table update. In the later * case just flush: */ @@ -22503,7 +23840,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault pgd_ref =3D pgd_offset_k(address); if (pgd_none(*pgd_ref)) return -1; -@@ -535,7 +615,7 @@ static int is_errata93(struct pt_regs *r +@@ -535,7 +615,7 @@ static int is_errata93(struct pt_regs *regs, unsigne= d long address) static int is_errata100(struct pt_regs *regs, unsigned long address) { #ifdef CONFIG_X86_64 @@ -22512,7 +23849,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault return 1; #endif return 0; -@@ -562,7 +642,7 @@ static int is_f00f_bug(struct pt_regs *r +@@ -562,7 +642,7 @@ static int is_f00f_bug(struct pt_regs *regs, unsigne= d long address) } =20 static const char nx_warning[] =3D KERN_CRIT @@ -22521,7 +23858,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault =20 static void show_fault_oops(struct pt_regs *regs, unsigned long error_code, -@@ -571,15 +651,26 @@ show_fault_oops(struct pt_regs *regs, un +@@ -571,15 +651,26 @@ show_fault_oops(struct pt_regs *regs, unsigned lon= g error_code, if (!oops_may_print()) return; =20 @@ -22550,7 +23887,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault printk(KERN_ALERT "BUG: unable to handle kernel "); if (address < PAGE_SIZE) printk(KERN_CONT "NULL pointer dereference"); -@@ -705,6 +796,23 @@ __bad_area_nosemaphore(struct pt_regs *r +@@ -705,6 +796,23 @@ __bad_area_nosemaphore(struct pt_regs *regs, unsign= ed long error_code, { struct task_struct *tsk =3D current; =20 @@ -22574,7 +23911,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault /* User mode accesses just cause a SIGSEGV */ if (error_code & PF_USER) { /* -@@ -722,6 +830,21 @@ __bad_area_nosemaphore(struct pt_regs *r +@@ -722,6 +830,21 @@ __bad_area_nosemaphore(struct pt_regs *regs, unsign= ed long error_code, if (is_errata100(regs, address)) return; =20 @@ -22596,7 +23933,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault if (unlikely(show_unhandled_signals)) show_signal_msg(regs, error_code, address, tsk); =20 -@@ -818,7 +941,7 @@ do_sigbus(struct pt_regs *regs, unsigned +@@ -818,7 +941,7 @@ do_sigbus(struct pt_regs *regs, unsigned long error_= code, unsigned long address, if (fault & VM_FAULT_HWPOISON) { printk(KERN_ERR "MCE: Killing %s:%d due to hardware memory corruption fault at %lx\n", @@ -22605,7 +23942,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault code =3D BUS_MCEERR_AR; } #endif -@@ -857,6 +980,99 @@ static int spurious_fault_check(unsigned +@@ -857,6 +980,99 @@ static int spurious_fault_check(unsigned long error= _code, pte_t *pte) return 1; } =20 @@ -22715,7 +24052,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault if (write) { /* write, present and write, not present: */ if (unlikely(!(vma->vm_flags & VM_WRITE))) -@@ -956,17 +1175,31 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -956,17 +1175,31 @@ do_page_fault(struct pt_regs *regs, unsigned long= error_code) { struct vm_area_struct *vma; struct task_struct *tsk; @@ -22751,7 +24088,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault /* * Detect and handle instructions that would cause a page fault for * both a tracked kernel page and a userspace page. -@@ -1026,7 +1259,7 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -1026,7 +1259,7 @@ do_page_fault(struct pt_regs *regs, unsigned long = error_code) * User-mode registers count as a user access even for any * potential system fault or CPU buglet: */ @@ -22760,7 +24097,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault local_irq_enable(); error_code |=3D PF_USER; } else { -@@ -1080,6 +1313,11 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -1080,6 +1313,11 @@ do_page_fault(struct pt_regs *regs, unsigned long= error_code) might_sleep(); } =20 @@ -22772,7 +24109,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c li= nux-2.6.32.49/arch/x86/mm/fault vma =3D find_vma(mm, address); if (unlikely(!vma)) { bad_area(regs, error_code, address); -@@ -1091,18 +1329,24 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -1091,18 +1329,24 @@ do_page_fault(struct pt_regs *regs, unsigned lon= g error_code) bad_area(regs, error_code, address); return; } @@ -22796,13 +24133,13 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c = linux-2.6.32.49/arch/x86/mm/fault + if (unlikely(address + 65536 + 32 * sizeof(unsigned long) < task_pt_re= gs(tsk)->sp)) { + bad_area(regs, error_code, address); + return; -+ } + } + +#ifdef CONFIG_PAX_SEGMEXEC + if (unlikely((mm->pax_flags & MF_PAX_SEGMEXEC) && vma->vm_end - SEGMEX= EC_TASK_SIZE - 1 < address - SEGMEXEC_TASK_SIZE - 1)) { + bad_area(regs, error_code, address); + return; - } ++ } +#endif + if (unlikely(expand_stack(vma, address))) { @@ -23049,10 +24386,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/fault.c = linux-2.6.32.49/arch/x86/mm/fault + + return ret ? -EFAULT : 0; +} -diff -urNp linux-2.6.32.49/arch/x86/mm/gup.c linux-2.6.32.49/arch/x86/mm= /gup.c ---- linux-2.6.32.49/arch/x86/mm/gup.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/arch/x86/mm/gup.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -237,7 +237,7 @@ int __get_user_pages_fast(unsigned long=20 +diff --git a/arch/x86/mm/gup.c b/arch/x86/mm/gup.c +index 71da1bc..7a16bf4 100644 +--- a/arch/x86/mm/gup.c ++++ b/arch/x86/mm/gup.c +@@ -237,7 +237,7 @@ int __get_user_pages_fast(unsigned long start, int n= r_pages, int write, addr =3D start; len =3D (unsigned long) nr_pages << PAGE_SHIFT; end =3D start + len; @@ -23061,10 +24399,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/gup.c li= nux-2.6.32.49/arch/x86/mm/gup.c (void __user *)start, len))) return 0; =20 -diff -urNp linux-2.6.32.49/arch/x86/mm/highmem_32.c linux-2.6.32.49/arch= /x86/mm/highmem_32.c ---- linux-2.6.32.49/arch/x86/mm/highmem_32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/mm/highmem_32.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -43,7 +43,10 @@ void *kmap_atomic_prot(struct page *page +diff --git a/arch/x86/mm/highmem_32.c b/arch/x86/mm/highmem_32.c +index 63a6ba6..79abd7a 100644 +--- a/arch/x86/mm/highmem_32.c ++++ b/arch/x86/mm/highmem_32.c +@@ -43,7 +43,10 @@ void *kmap_atomic_prot(struct page *page, enum km_typ= e type, pgprot_t prot) idx =3D type + KM_TYPE_NR*smp_processor_id(); vaddr =3D __fix_to_virt(FIX_KMAP_BEGIN + idx); BUG_ON(!pte_none(*(kmap_pte-idx))); @@ -23075,10 +24414,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/highmem_= 32.c linux-2.6.32.49/arch/x86/mm/ =20 return (void *)vaddr; } -diff -urNp linux-2.6.32.49/arch/x86/mm/hugetlbpage.c linux-2.6.32.49/arc= h/x86/mm/hugetlbpage.c ---- linux-2.6.32.49/arch/x86/mm/hugetlbpage.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/mm/hugetlbpage.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -267,13 +267,20 @@ static unsigned long hugetlb_get_unmappe +diff --git a/arch/x86/mm/hugetlbpage.c b/arch/x86/mm/hugetlbpage.c +index f46c340..6ff9a26 100644 +--- a/arch/x86/mm/hugetlbpage.c ++++ b/arch/x86/mm/hugetlbpage.c +@@ -267,13 +267,20 @@ static unsigned long hugetlb_get_unmapped_area_bot= tomup(struct file *file, struct hstate *h =3D hstate_file(file); struct mm_struct *mm =3D current->mm; struct vm_area_struct *vma; @@ -23138,7 +24478,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/hugetlbpag= e.c linux-2.6.32.49/arch/x86/mm } =20 static unsigned long hugetlb_get_unmapped_area_topdown(struct file *fil= e, -@@ -309,10 +317,9 @@ static unsigned long hugetlb_get_unmappe +@@ -309,10 +317,9 @@ static unsigned long hugetlb_get_unmapped_area_topd= own(struct file *file, { struct hstate *h =3D hstate_file(file); struct mm_struct *mm =3D current->mm; @@ -23151,7 +24491,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/hugetlbpag= e.c linux-2.6.32.49/arch/x86/mm =20 /* don't allow allocations above current base */ if (mm->free_area_cache > base) -@@ -322,64 +329,63 @@ static unsigned long hugetlb_get_unmappe +@@ -322,64 +329,63 @@ static unsigned long hugetlb_get_unmapped_area_top= down(struct file *file, largest_hole =3D 0; mm->free_area_cache =3D base; } @@ -23254,7 +24594,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/hugetlbpag= e.c linux-2.6.32.49/arch/x86/mm mm->free_area_cache =3D base; mm->cached_hole_size =3D ~0UL; =20 -@@ -400,10 +407,19 @@ hugetlb_get_unmapped_area(struct file *f +@@ -400,10 +407,19 @@ hugetlb_get_unmapped_area(struct file *file, unsig= ned long addr, struct hstate *h =3D hstate_file(file); struct mm_struct *mm =3D current->mm; struct vm_area_struct *vma; @@ -23275,7 +24615,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/hugetlbpag= e.c linux-2.6.32.49/arch/x86/mm return -ENOMEM; =20 if (flags & MAP_FIXED) { -@@ -415,8 +431,7 @@ hugetlb_get_unmapped_area(struct file *f +@@ -415,8 +431,7 @@ hugetlb_get_unmapped_area(struct file *file, unsigne= d long addr, if (addr) { addr =3D ALIGN(addr, huge_page_size(h)); vma =3D find_vma(mm, addr); @@ -23285,9 +24625,151 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/hugetlbp= age.c linux-2.6.32.49/arch/x86/mm return addr; } if (mm->get_unmapped_area =3D=3D arch_get_unmapped_area) -diff -urNp linux-2.6.32.49/arch/x86/mm/init_32.c linux-2.6.32.49/arch/x8= 6/mm/init_32.c ---- linux-2.6.32.49/arch/x86/mm/init_32.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/mm/init_32.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/arch/x86/mm/init.c b/arch/x86/mm/init.c +index 73ffd55..ad78676 100644 +--- a/arch/x86/mm/init.c ++++ b/arch/x86/mm/init.c +@@ -69,11 +69,7 @@ static void __init find_early_table_space(unsigned lo= ng end, int use_pse, + * cause a hotspot and fill up ZONE_DMA. The page tables + * need roughly 0.5KB per GB. + */ +-#ifdef CONFIG_X86_32 +- start =3D 0x7000; +-#else +- start =3D 0x8000; +-#endif ++ start =3D 0x100000; + e820_table_start =3D find_e820_area(start, max_pfn_mapped<> PAGE_SHIFT) =3D=3D pagenr) ++ return 1; ++ /* allow ISA/video mem */ ++ if ((ISA_START_ADDRESS >> PAGE_SHIFT) <=3D pagenr && pagenr < (ISA_END= _ADDRESS >> PAGE_SHIFT)) ++ return 1; ++ /* throw out everything else below 1MB */ ++ if (pagenr <=3D 256) ++ return 0; ++#else + if (pagenr <=3D 256) + return 1; ++#endif ++ + if (iomem_is_exclusive(pagenr << PAGE_SHIFT)) + return 0; + if (!page_is_ram(pagenr)) +@@ -379,6 +392,86 @@ void free_init_pages(char *what, unsigned long begi= n, unsigned long end) +=20 + void free_initmem(void) + { ++ ++#ifdef CONFIG_PAX_KERNEXEC ++#ifdef CONFIG_X86_32 ++ /* PaX: limit KERNEL_CS to actual size */ ++ unsigned long addr, limit; ++ struct desc_struct d; ++ int cpu; ++ ++ limit =3D paravirt_enabled() ? ktva_ktla(0xffffffff) : (unsigned long)= &_etext; ++ limit =3D (limit - 1UL) >> PAGE_SHIFT; ++ ++ memset(__LOAD_PHYSICAL_ADDR + PAGE_OFFSET, POISON_FREE_INITMEM, PAGE_S= IZE); ++ for (cpu =3D 0; cpu < NR_CPUS; cpu++) { ++ pack_descriptor(&d, get_desc_base(&get_cpu_gdt_table(cpu)[GDT_ENTRY_K= ERNEL_CS]), limit, 0x9B, 0xC); ++ write_gdt_entry(get_cpu_gdt_table(cpu), GDT_ENTRY_KERNEL_CS, &d, DESC= TYPE_S); ++ } ++ ++ /* PaX: make KERNEL_CS read-only */ ++ addr =3D PFN_ALIGN(ktla_ktva((unsigned long)&_text)); ++ if (!paravirt_enabled()) ++ set_memory_ro(addr, (PFN_ALIGN(_sdata) - addr) >> PAGE_SHIFT); ++/* ++ for (addr =3D ktla_ktva((unsigned long)&_text); addr < (unsigned long= )&_sdata; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); ++ } ++*/ ++#ifdef CONFIG_X86_PAE ++ set_memory_nx(PFN_ALIGN(__init_begin), (PFN_ALIGN(__init_end) - PFN_AL= IGN(__init_begin)) >> PAGE_SHIFT); ++/* ++ for (addr =3D (unsigned long)&__init_begin; addr < (unsigned long)&__i= nit_end; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask))= ); ++ } ++*/ ++#endif ++ ++#ifdef CONFIG_MODULES ++ set_memory_4k((unsigned long)MODULES_EXEC_VADDR, (MODULES_EXEC_END - M= ODULES_EXEC_VADDR) >> PAGE_SHIFT); ++#endif ++ ++#else ++ pgd_t *pgd; ++ pud_t *pud; ++ pmd_t *pmd; ++ unsigned long addr, end; ++ ++ /* PaX: make kernel code/rodata read-only, rest non-executable */ ++ for (addr =3D __START_KERNEL_map; addr < __START_KERNEL_map + KERNEL_I= MAGE_SIZE; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ if (!pmd_present(*pmd)) ++ continue; ++ if ((unsigned long)_text <=3D addr && addr < (unsigned long)_sdata) ++ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); ++ else ++ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask)= )); ++ } ++ ++ addr =3D (unsigned long)__va(__pa(__START_KERNEL_map)); ++ end =3D addr + KERNEL_IMAGE_SIZE; ++ for (; addr < end; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ if (!pmd_present(*pmd)) ++ continue; ++ if ((unsigned long)__va(__pa(_text)) <=3D addr && addr < (unsigned lo= ng)__va(__pa(_sdata))) ++ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); ++ } ++#endif ++ ++ flush_tlb_all(); ++#endif ++ + free_init_pages("unused kernel memory", + (unsigned long)(&__init_begin), + (unsigned long)(&__init_end)); +diff --git a/arch/x86/mm/init_32.c b/arch/x86/mm/init_32.c +index 30938c1..bda3d5d 100644 +--- a/arch/x86/mm/init_32.c ++++ b/arch/x86/mm/init_32.c @@ -72,36 +72,6 @@ static __init void *alloc_low_page(void) } =20 @@ -23325,7 +24807,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_32.c = linux-2.6.32.49/arch/x86/mm/ini * Create a page table and place a pointer to it in a middle page * directory entry: */ -@@ -121,13 +91,28 @@ static pte_t * __init one_page_table_ini +@@ -121,13 +91,28 @@ static pte_t * __init one_page_table_init(pmd_t *pm= d) page_table =3D (pte_t *)alloc_low_page(); =20 paravirt_alloc_pte(&init_mm, __pa(page_table) >> PAGE_SHIFT); @@ -23354,7 +24836,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_32.c = linux-2.6.32.49/arch/x86/mm/ini pmd_t * __init populate_extra_pmd(unsigned long vaddr) { int pgd_idx =3D pgd_index(vaddr); -@@ -201,6 +186,7 @@ page_table_range_init(unsigned long star +@@ -201,6 +186,7 @@ page_table_range_init(unsigned long start, unsigned = long end, pgd_t *pgd_base) int pgd_idx, pmd_idx; unsigned long vaddr; pgd_t *pgd; @@ -23362,7 +24844,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_32.c = linux-2.6.32.49/arch/x86/mm/ini pmd_t *pmd; pte_t *pte =3D NULL; =20 -@@ -210,8 +196,13 @@ page_table_range_init(unsigned long star +@@ -210,8 +196,13 @@ page_table_range_init(unsigned long start, unsigned= long end, pgd_t *pgd_base) pgd =3D pgd_base + pgd_idx; =20 for ( ; (pgd_idx < PTRS_PER_PGD) && (vaddr !=3D end); pgd++, pgd_idx++= ) { @@ -23378,7 +24860,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_32.c = linux-2.6.32.49/arch/x86/mm/ini for (; (pmd_idx < PTRS_PER_PMD) && (vaddr !=3D end); pmd++, pmd_idx++) { pte =3D page_table_kmap_check(one_page_table_init(pmd), -@@ -223,11 +214,20 @@ page_table_range_init(unsigned long star +@@ -223,11 +214,20 @@ page_table_range_init(unsigned long start, unsigne= d long end, pgd_t *pgd_base) } } =20 @@ -23403,7 +24885,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_32.c = linux-2.6.32.49/arch/x86/mm/ini } =20 /* -@@ -243,9 +243,10 @@ kernel_physical_mapping_init(unsigned lo +@@ -243,9 +243,10 @@ kernel_physical_mapping_init(unsigned long start, int use_pse =3D page_size_mask =3D=3D (1<> PAGE_SHIFT); printk(KERN_INFO "Write protecting the kernel text: %luk\n", size >> 10); -diff -urNp linux-2.6.32.49/arch/x86/mm/init_64.c linux-2.6.32.49/arch/x8= 6/mm/init_64.c ---- linux-2.6.32.49/arch/x86/mm/init_64.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/mm/init_64.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -164,7 +164,9 @@ void set_pte_vaddr_pud(pud_t *pud_page,=20 +diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c +index 7d095ad..25d2549 100644 +--- a/arch/x86/mm/init_64.c ++++ b/arch/x86/mm/init_64.c +@@ -164,7 +164,9 @@ void set_pte_vaddr_pud(pud_t *pud_page, unsigned lon= g vaddr, pte_t new_pte) pmd =3D fill_pmd(pud, vaddr); pte =3D fill_pte(pmd, vaddr); =20 @@ -23604,7 +25087,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_64.c = linux-2.6.32.49/arch/x86/mm/ini =20 /* * It's enough to flush this one mapping. -@@ -223,14 +225,12 @@ static void __init __init_extra_mapping( +@@ -223,14 +225,12 @@ static void __init __init_extra_mapping(unsigned l= ong phys, unsigned long size, pgd =3D pgd_offset_k((unsigned long)__va(phys)); if (pgd_none(*pgd)) { pud =3D (pud_t *) spp_getpage(); @@ -23645,7 +25128,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_64.c = linux-2.6.32.49/arch/x86/mm/ini }; =20 struct vm_area_struct *get_gate_vma(struct task_struct *tsk) -@@ -896,7 +902,7 @@ int in_gate_area_no_task(unsigned long a +@@ -896,7 +902,7 @@ int in_gate_area_no_task(unsigned long addr) =20 const char *arch_vma_name(struct vm_area_struct *vma) { @@ -23654,150 +25137,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/init_64= .c linux-2.6.32.49/arch/x86/mm/ini return "[vdso]"; if (vma =3D=3D &gate_vma) return "[vsyscall]"; -diff -urNp linux-2.6.32.49/arch/x86/mm/init.c linux-2.6.32.49/arch/x86/m= m/init.c ---- linux-2.6.32.49/arch/x86/mm/init.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/x86/mm/init.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -69,11 +69,7 @@ static void __init find_early_table_spac - * cause a hotspot and fill up ZONE_DMA. The page tables - * need roughly 0.5KB per GB. - */ --#ifdef CONFIG_X86_32 -- start =3D 0x7000; --#else -- start =3D 0x8000; --#endif -+ start =3D 0x100000; - e820_table_start =3D find_e820_area(start, max_pfn_mapped<> PAGE_SHIFT) =3D=3D pagenr) -+ return 1; -+ /* allow ISA/video mem */ -+ if ((ISA_START_ADDRESS >> PAGE_SHIFT) <=3D pagenr && pagenr < (ISA_END= _ADDRESS >> PAGE_SHIFT)) -+ return 1; -+ /* throw out everything else below 1MB */ -+ if (pagenr <=3D 256) -+ return 0; -+#else - if (pagenr <=3D 256) - return 1; -+#endif -+ - if (iomem_is_exclusive(pagenr << PAGE_SHIFT)) - return 0; - if (!page_is_ram(pagenr)) -@@ -379,6 +392,86 @@ void free_init_pages(char *what, unsigne -=20 - void free_initmem(void) - { -+ -+#ifdef CONFIG_PAX_KERNEXEC -+#ifdef CONFIG_X86_32 -+ /* PaX: limit KERNEL_CS to actual size */ -+ unsigned long addr, limit; -+ struct desc_struct d; -+ int cpu; -+ -+ limit =3D paravirt_enabled() ? ktva_ktla(0xffffffff) : (unsigned long)= &_etext; -+ limit =3D (limit - 1UL) >> PAGE_SHIFT; -+ -+ memset(__LOAD_PHYSICAL_ADDR + PAGE_OFFSET, POISON_FREE_INITMEM, PAGE_S= IZE); -+ for (cpu =3D 0; cpu < NR_CPUS; cpu++) { -+ pack_descriptor(&d, get_desc_base(&get_cpu_gdt_table(cpu)[GDT_ENTRY_K= ERNEL_CS]), limit, 0x9B, 0xC); -+ write_gdt_entry(get_cpu_gdt_table(cpu), GDT_ENTRY_KERNEL_CS, &d, DESC= TYPE_S); -+ } -+ -+ /* PaX: make KERNEL_CS read-only */ -+ addr =3D PFN_ALIGN(ktla_ktva((unsigned long)&_text)); -+ if (!paravirt_enabled()) -+ set_memory_ro(addr, (PFN_ALIGN(_sdata) - addr) >> PAGE_SHIFT); -+/* -+ for (addr =3D ktla_ktva((unsigned long)&_text); addr < (unsigned long= )&_sdata; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); -+ } -+*/ -+#ifdef CONFIG_X86_PAE -+ set_memory_nx(PFN_ALIGN(__init_begin), (PFN_ALIGN(__init_end) - PFN_AL= IGN(__init_begin)) >> PAGE_SHIFT); -+/* -+ for (addr =3D (unsigned long)&__init_begin; addr < (unsigned long)&__i= nit_end; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask))= ); -+ } -+*/ -+#endif -+ -+#ifdef CONFIG_MODULES -+ set_memory_4k((unsigned long)MODULES_EXEC_VADDR, (MODULES_EXEC_END - M= ODULES_EXEC_VADDR) >> PAGE_SHIFT); -+#endif -+ -+#else -+ pgd_t *pgd; -+ pud_t *pud; -+ pmd_t *pmd; -+ unsigned long addr, end; -+ -+ /* PaX: make kernel code/rodata read-only, rest non-executable */ -+ for (addr =3D __START_KERNEL_map; addr < __START_KERNEL_map + KERNEL_I= MAGE_SIZE; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ if (!pmd_present(*pmd)) -+ continue; -+ if ((unsigned long)_text <=3D addr && addr < (unsigned long)_sdata) -+ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); -+ else -+ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask)= )); -+ } -+ -+ addr =3D (unsigned long)__va(__pa(__START_KERNEL_map)); -+ end =3D addr + KERNEL_IMAGE_SIZE; -+ for (; addr < end; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ if (!pmd_present(*pmd)) -+ continue; -+ if ((unsigned long)__va(__pa(_text)) <=3D addr && addr < (unsigned lo= ng)__va(__pa(_sdata))) -+ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); -+ } -+#endif -+ -+ flush_tlb_all(); -+#endif -+ - free_init_pages("unused kernel memory", - (unsigned long)(&__init_begin), - (unsigned long)(&__init_end)); -diff -urNp linux-2.6.32.49/arch/x86/mm/iomap_32.c linux-2.6.32.49/arch/x= 86/mm/iomap_32.c ---- linux-2.6.32.49/arch/x86/mm/iomap_32.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/mm/iomap_32.c 2011-11-15 19:59:43.000000000= -0500 -@@ -65,7 +65,11 @@ void *kmap_atomic_prot_pfn(unsigned long +diff --git a/arch/x86/mm/iomap_32.c b/arch/x86/mm/iomap_32.c +index 84e236c..69bd3f6 100644 +--- a/arch/x86/mm/iomap_32.c ++++ b/arch/x86/mm/iomap_32.c +@@ -65,7 +65,11 @@ void *kmap_atomic_prot_pfn(unsigned long pfn, enum km= _type type, pgprot_t prot) debug_kmap_atomic(type); idx =3D type + KM_TYPE_NR * smp_processor_id(); vaddr =3D __fix_to_virt(FIX_KMAP_BEGIN + idx); @@ -23809,9 +25153,10 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/iomap_32.= c linux-2.6.32.49/arch/x86/mm/io arch_flush_lazy_mmu_mode(); =20 return (void *)vaddr; -diff -urNp linux-2.6.32.49/arch/x86/mm/ioremap.c linux-2.6.32.49/arch/x8= 6/mm/ioremap.c ---- linux-2.6.32.49/arch/x86/mm/ioremap.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/mm/ioremap.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/arch/x86/mm/ioremap.c b/arch/x86/mm/ioremap.c +index 2feb9bd..3646202 100644 +--- a/arch/x86/mm/ioremap.c ++++ b/arch/x86/mm/ioremap.c @@ -41,8 +41,8 @@ int page_is_ram(unsigned long pagenr) * Second special case: Some BIOSen report the PC BIOS * area (640->1Mb) as ram even though it is not. @@ -23823,7 +25168,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/ioremap.c = linux-2.6.32.49/arch/x86/mm/ior return 0; =20 for (i =3D 0; i < e820.nr_map; i++) { -@@ -137,13 +137,10 @@ static void __iomem *__ioremap_caller(re +@@ -137,13 +137,10 @@ static void __iomem *__ioremap_caller(resource_siz= e_t phys_addr, /* * Don't allow anybody to remap normal RAM that we're using.. */ @@ -23839,7 +25184,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/ioremap.c = linux-2.6.32.49/arch/x86/mm/ior return NULL; WARN_ON_ONCE(is_ram); } -@@ -407,7 +404,7 @@ static int __init early_ioremap_debug_se +@@ -407,7 +404,7 @@ static int __init early_ioremap_debug_setup(char *st= r) early_param("early_ioremap_debug", early_ioremap_debug_setup); =20 static __initdata int after_paging_init; @@ -23858,10 +25203,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/ioremap.= c linux-2.6.32.49/arch/x86/mm/ior =20 /* * The boot-ioremap range spans multiple pmds, for which -diff -urNp linux-2.6.32.49/arch/x86/mm/kmemcheck/kmemcheck.c linux-2.6.3= 2.49/arch/x86/mm/kmemcheck/kmemcheck.c ---- linux-2.6.32.49/arch/x86/mm/kmemcheck/kmemcheck.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/arch/x86/mm/kmemcheck/kmemcheck.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -622,9 +622,9 @@ bool kmemcheck_fault(struct pt_regs *reg +diff --git a/arch/x86/mm/kmemcheck/kmemcheck.c b/arch/x86/mm/kmemcheck/k= memcheck.c +index 8cc1833..1abbc5b 100644 +--- a/arch/x86/mm/kmemcheck/kmemcheck.c ++++ b/arch/x86/mm/kmemcheck/kmemcheck.c +@@ -622,9 +622,9 @@ bool kmemcheck_fault(struct pt_regs *regs, unsigned = long address, * memory (e.g. tracked pages)? For now, we need this to avoid * invoking kmemcheck for PnP BIOS calls. */ @@ -23873,10 +25219,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/kmemchec= k/kmemcheck.c linux-2.6.32.49/arc return false; =20 pte =3D kmemcheck_pte_lookup(address); -diff -urNp linux-2.6.32.49/arch/x86/mm/mmap.c linux-2.6.32.49/arch/x86/m= m/mmap.c ---- linux-2.6.32.49/arch/x86/mm/mmap.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/x86/mm/mmap.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -49,7 +49,7 @@ static unsigned int stack_maxrandom_size +diff --git a/arch/x86/mm/mmap.c b/arch/x86/mm/mmap.c +index c8191de..2975082 100644 +--- a/arch/x86/mm/mmap.c ++++ b/arch/x86/mm/mmap.c +@@ -49,7 +49,7 @@ static unsigned int stack_maxrandom_size(void) * Leave an at least ~128 MB hole with possible stack randomization. */ #define MIN_GAP (128*1024*1024UL + stack_maxrandom_size()) @@ -23931,7 +25278,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/mmap.c lin= ux-2.6.32.49/arch/x86/mm/mmap.c return TASK_UNMAPPED_BASE + mmap_rnd(); } =20 -@@ -125,11 +138,23 @@ static unsigned long mmap_legacy_base(vo +@@ -125,11 +138,23 @@ static unsigned long mmap_legacy_base(void) void arch_pick_mmap_layout(struct mm_struct *mm) { if (mmap_is_legacy()) { @@ -23957,10 +25304,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/mmap.c l= inux-2.6.32.49/arch/x86/mm/mmap.c mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-2.6.32.49/arch/x86/mm/mmio-mod.c linux-2.6.32.49/arch/x= 86/mm/mmio-mod.c ---- linux-2.6.32.49/arch/x86/mm/mmio-mod.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/mm/mmio-mod.c 2011-11-15 19:59:43.000000000= -0500 -@@ -193,7 +193,7 @@ static void pre(struct kmmio_probe *p, s +diff --git a/arch/x86/mm/mmio-mod.c b/arch/x86/mm/mmio-mod.c +index 132772a..b961f11 100644 +--- a/arch/x86/mm/mmio-mod.c ++++ b/arch/x86/mm/mmio-mod.c +@@ -193,7 +193,7 @@ static void pre(struct kmmio_probe *p, struct pt_reg= s *regs, break; default: { @@ -23969,7 +25317,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/mmio-mod.c= linux-2.6.32.49/arch/x86/mm/mm my_trace->opcode =3D MMIO_UNKNOWN_OP; my_trace->width =3D 0; my_trace->value =3D (*ip) << 16 | *(ip + 1) << 8 | -@@ -233,7 +233,7 @@ static void post(struct kmmio_probe *p,=20 +@@ -233,7 +233,7 @@ static void post(struct kmmio_probe *p, unsigned lon= g condition, static void ioremap_trace_core(resource_size_t offset, unsigned long si= ze, void __iomem *addr) { @@ -23978,7 +25326,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/mmio-mod.c= linux-2.6.32.49/arch/x86/mm/mm struct remap_trace *trace =3D kmalloc(sizeof(*trace), GFP_KERNEL); /* These are page-unaligned. */ struct mmiotrace_map map =3D { -@@ -257,7 +257,7 @@ static void ioremap_trace_core(resource_ +@@ -257,7 +257,7 @@ static void ioremap_trace_core(resource_size_t offse= t, unsigned long size, .private =3D trace }, .phys =3D offset, @@ -23987,10 +25335,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/mmio-mod= .c linux-2.6.32.49/arch/x86/mm/mm }; map.map_id =3D trace->id; =20 -diff -urNp linux-2.6.32.49/arch/x86/mm/numa_32.c linux-2.6.32.49/arch/x8= 6/mm/numa_32.c ---- linux-2.6.32.49/arch/x86/mm/numa_32.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/mm/numa_32.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -98,7 +98,6 @@ unsigned long node_memmap_size_bytes(int +diff --git a/arch/x86/mm/numa_32.c b/arch/x86/mm/numa_32.c +index d253006..e56dd6a 100644 +--- a/arch/x86/mm/numa_32.c ++++ b/arch/x86/mm/numa_32.c +@@ -98,7 +98,6 @@ unsigned long node_memmap_size_bytes(int nid, unsigned= long start_pfn, } #endif =20 @@ -23998,10 +25347,24 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/numa_32.= c linux-2.6.32.49/arch/x86/mm/num extern unsigned long highend_pfn, highstart_pfn; =20 #define LARGE_PAGE_BYTES (PTRS_PER_PTE * PAGE_SIZE) -diff -urNp linux-2.6.32.49/arch/x86/mm/pageattr.c linux-2.6.32.49/arch/x= 86/mm/pageattr.c ---- linux-2.6.32.49/arch/x86/mm/pageattr.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/mm/pageattr.c 2011-11-15 19:59:43.000000000= -0500 -@@ -261,16 +261,17 @@ static inline pgprot_t static_protection +diff --git a/arch/x86/mm/pageattr-test.c b/arch/x86/mm/pageattr-test.c +index e1d1069..2251ff3 100644 +--- a/arch/x86/mm/pageattr-test.c ++++ b/arch/x86/mm/pageattr-test.c +@@ -36,7 +36,7 @@ enum { +=20 + static int pte_testbit(pte_t pte) + { +- return pte_flags(pte) & _PAGE_UNUSED1; ++ return pte_flags(pte) & _PAGE_CPA_TEST; + } +=20 + struct split_state { +diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c +index dd38bfb..8c12306 100644 +--- a/arch/x86/mm/pageattr.c ++++ b/arch/x86/mm/pageattr.c +@@ -261,16 +261,17 @@ static inline pgprot_t static_protections(pgprot_t= prot, unsigned long address, * PCI BIOS based config access (CONFIG_PCI_GOBIOS) support. */ if (within(pfn, BIOS_BEGIN >> PAGE_SHIFT, BIOS_END >> PAGE_SHIFT)) @@ -24022,7 +25385,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pageattr.c= linux-2.6.32.49/arch/x86/mm/pa /* * The .rodata section needs to be read-only. Using the pfn * catches all aliases. -@@ -278,6 +279,14 @@ static inline pgprot_t static_protection +@@ -278,6 +279,14 @@ static inline pgprot_t static_protections(pgprot_t = prot, unsigned long address, if (within(pfn, __pa((unsigned long)__start_rodata) >> PAGE_SHIFT, __pa((unsigned long)__end_rodata) >> PAGE_SHIFT)) pgprot_val(forbidden) |=3D _PAGE_RW; @@ -24077,22 +25440,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pageattr= .c linux-2.6.32.49/arch/x86/mm/pa } =20 static int -diff -urNp linux-2.6.32.49/arch/x86/mm/pageattr-test.c linux-2.6.32.49/a= rch/x86/mm/pageattr-test.c ---- linux-2.6.32.49/arch/x86/mm/pageattr-test.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/arch/x86/mm/pageattr-test.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -36,7 +36,7 @@ enum { -=20 - static int pte_testbit(pte_t pte) - { -- return pte_flags(pte) & _PAGE_UNUSED1; -+ return pte_flags(pte) & _PAGE_CPA_TEST; - } -=20 - struct split_state { -diff -urNp linux-2.6.32.49/arch/x86/mm/pat.c linux-2.6.32.49/arch/x86/mm= /pat.c ---- linux-2.6.32.49/arch/x86/mm/pat.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/arch/x86/mm/pat.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -258,7 +258,7 @@ chk_conflict(struct memtype *new, struct +diff --git a/arch/x86/mm/pat.c b/arch/x86/mm/pat.c +index e78cd0e..de0a817 100644 +--- a/arch/x86/mm/pat.c ++++ b/arch/x86/mm/pat.c +@@ -258,7 +258,7 @@ chk_conflict(struct memtype *new, struct memtype *en= try, unsigned long *type) =20 conflict: printk(KERN_INFO "%s:%d conflicting memory types " @@ -24110,7 +25462,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pat.c linu= x-2.6.32.49/arch/x86/mm/pat.c } =20 dprintk("free_memtype request 0x%Lx-0x%Lx\n", start, end); -@@ -689,8 +689,8 @@ static inline int range_is_allowed(unsig +@@ -689,8 +689,8 @@ static inline int range_is_allowed(unsigned long pfn= , unsigned long size) while (cursor < to) { if (!devmem_is_allowed(pfn)) { printk(KERN_INFO @@ -24121,7 +25473,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pat.c linu= x-2.6.32.49/arch/x86/mm/pat.c return 0; } cursor +=3D PAGE_SIZE; -@@ -755,7 +755,7 @@ int kernel_map_sync_memtype(u64 base, un +@@ -755,7 +755,7 @@ int kernel_map_sync_memtype(u64 base, unsigned long = size, unsigned long flags) printk(KERN_INFO "%s:%d ioremap_change_attr failed %s " "for %Lx-%Lx\n", @@ -24130,7 +25482,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pat.c linu= x-2.6.32.49/arch/x86/mm/pat.c cattr_name(flags), base, (unsigned long long)(base + size)); return -EINVAL; -@@ -813,7 +813,7 @@ static int reserve_pfn_range(u64 paddr,=20 +@@ -813,7 +813,7 @@ static int reserve_pfn_range(u64 paddr, unsigned lon= g size, pgprot_t *vma_prot, free_memtype(paddr, paddr + size); printk(KERN_ERR "%s:%d map pfn expected mapping type %s" " for %Lx-%Lx, got %s\n", @@ -24139,10 +25491,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pat.c li= nux-2.6.32.49/arch/x86/mm/pat.c cattr_name(want_flags), (unsigned long long)paddr, (unsigned long long)(paddr + size), -diff -urNp linux-2.6.32.49/arch/x86/mm/pf_in.c linux-2.6.32.49/arch/x86/= mm/pf_in.c ---- linux-2.6.32.49/arch/x86/mm/pf_in.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/x86/mm/pf_in.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -148,7 +148,7 @@ enum reason_type get_ins_type(unsigned l +diff --git a/arch/x86/mm/pf_in.c b/arch/x86/mm/pf_in.c +index df3d5c8..c2223e1 100644 +--- a/arch/x86/mm/pf_in.c ++++ b/arch/x86/mm/pf_in.c +@@ -148,7 +148,7 @@ enum reason_type get_ins_type(unsigned long ins_addr= ) int i; enum reason_type rv =3D OTHERS; =20 @@ -24151,7 +25504,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pf_in.c li= nux-2.6.32.49/arch/x86/mm/pf_in p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); =20 -@@ -168,7 +168,7 @@ static unsigned int get_ins_reg_width(un +@@ -168,7 +168,7 @@ static unsigned int get_ins_reg_width(unsigned long = ins_addr) struct prefix_bits prf; int i; =20 @@ -24160,7 +25513,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pf_in.c li= nux-2.6.32.49/arch/x86/mm/pf_in p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); =20 -@@ -191,7 +191,7 @@ unsigned int get_ins_mem_width(unsigned=20 +@@ -191,7 +191,7 @@ unsigned int get_ins_mem_width(unsigned long ins_add= r) struct prefix_bits prf; int i; =20 @@ -24169,7 +25522,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pf_in.c li= nux-2.6.32.49/arch/x86/mm/pf_in p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); =20 -@@ -417,7 +417,7 @@ unsigned long get_ins_reg_val(unsigned l +@@ -417,7 +417,7 @@ unsigned long get_ins_reg_val(unsigned long ins_addr= , struct pt_regs *regs) int i; unsigned long rv; =20 @@ -24178,7 +25531,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pf_in.c li= nux-2.6.32.49/arch/x86/mm/pf_in p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); for (i =3D 0; i < ARRAY_SIZE(reg_rop); i++) -@@ -472,7 +472,7 @@ unsigned long get_ins_imm_val(unsigned l +@@ -472,7 +472,7 @@ unsigned long get_ins_imm_val(unsigned long ins_addr= ) int i; unsigned long rv; =20 @@ -24187,27 +25540,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pf_in.c = linux-2.6.32.49/arch/x86/mm/pf_in p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); for (i =3D 0; i < ARRAY_SIZE(imm_wop); i++) -diff -urNp linux-2.6.32.49/arch/x86/mm/pgtable_32.c linux-2.6.32.49/arch= /x86/mm/pgtable_32.c ---- linux-2.6.32.49/arch/x86/mm/pgtable_32.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/mm/pgtable_32.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -49,10 +49,13 @@ void set_pte_vaddr(unsigned long vaddr,=20 - return; - } - pte =3D pte_offset_kernel(pmd, vaddr); -+ -+ pax_open_kernel(); - if (pte_val(pteval)) - set_pte_at(&init_mm, vaddr, pte, pteval); - else - pte_clear(&init_mm, vaddr, pte); -+ pax_close_kernel(); -=20 - /* - * It's enough to flush this one mapping. -diff -urNp linux-2.6.32.49/arch/x86/mm/pgtable.c linux-2.6.32.49/arch/x8= 6/mm/pgtable.c ---- linux-2.6.32.49/arch/x86/mm/pgtable.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/mm/pgtable.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -83,9 +83,52 @@ static inline void pgd_list_del(pgd_t *p +diff --git a/arch/x86/mm/pgtable.c b/arch/x86/mm/pgtable.c +index e0e6fad..6b90017 100644 +--- a/arch/x86/mm/pgtable.c ++++ b/arch/x86/mm/pgtable.c +@@ -83,9 +83,52 @@ static inline void pgd_list_del(pgd_t *pgd) list_del(&page->lru); } =20 @@ -24288,7 +25625,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pgtable.c = linux-2.6.32.49/arch/x86/mm/pgt =20 void pud_populate(struct mm_struct *mm, pud_t *pudp, pmd_t *pmd) { -@@ -161,36 +205,38 @@ void pud_populate(struct mm_struct *mm,=20 +@@ -161,36 +205,38 @@ void pud_populate(struct mm_struct *mm, pud_t *pud= p, pmd_t *pmd) */ flush_tlb_mm(mm); } @@ -24338,7 +25675,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pgtable.c = linux-2.6.32.49/arch/x86/mm/pgt return -ENOMEM; } =20 -@@ -203,51 +249,56 @@ static int preallocate_pmds(pmd_t *pmds[ +@@ -203,51 +249,56 @@ static int preallocate_pmds(pmd_t *pmds[]) * preallocate which never got a corresponding vma will need to be * freed manually. */ @@ -24453,9 +25790,28 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/pgtable.c= linux-2.6.32.49/arch/x86/mm/pgt pgd_dtor(pgd); paravirt_pgd_free(mm, pgd); free_page((unsigned long)pgd); -diff -urNp linux-2.6.32.49/arch/x86/mm/setup_nx.c linux-2.6.32.49/arch/x= 86/mm/setup_nx.c ---- linux-2.6.32.49/arch/x86/mm/setup_nx.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/mm/setup_nx.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/mm/pgtable_32.c b/arch/x86/mm/pgtable_32.c +index 46c8834..fcab43d 100644 +--- a/arch/x86/mm/pgtable_32.c ++++ b/arch/x86/mm/pgtable_32.c +@@ -49,10 +49,13 @@ void set_pte_vaddr(unsigned long vaddr, pte_t pteval= ) + return; + } + pte =3D pte_offset_kernel(pmd, vaddr); ++ ++ pax_open_kernel(); + if (pte_val(pteval)) + set_pte_at(&init_mm, vaddr, pte, pteval); + else + pte_clear(&init_mm, vaddr, pte); ++ pax_close_kernel(); +=20 + /* + * It's enough to flush this one mapping. +diff --git a/arch/x86/mm/setup_nx.c b/arch/x86/mm/setup_nx.c +index 513d8ed..978c161 100644 +--- a/arch/x86/mm/setup_nx.c ++++ b/arch/x86/mm/setup_nx.c @@ -4,11 +4,10 @@ =20 #include @@ -24470,7 +25826,7 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/setup_nx.c= linux-2.6.32.49/arch/x86/mm/se /* * noexec =3D on|off * -@@ -22,32 +21,26 @@ static int __init noexec_setup(char *str +@@ -22,32 +21,26 @@ static int __init noexec_setup(char *str) if (!str) return -EINVAL; if (!strncmp(str, "on", 2)) { @@ -24521,9 +25877,10 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/setup_nx.= c linux-2.6.32.49/arch/x86/mm/se __supported_pte_mask &=3D ~_PAGE_NX; } #endif -diff -urNp linux-2.6.32.49/arch/x86/mm/tlb.c linux-2.6.32.49/arch/x86/mm= /tlb.c ---- linux-2.6.32.49/arch/x86/mm/tlb.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/arch/x86/mm/tlb.c 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/arch/x86/mm/tlb.c b/arch/x86/mm/tlb.c +index 36fe08e..b123d3a 100644 +--- a/arch/x86/mm/tlb.c ++++ b/arch/x86/mm/tlb.c @@ -61,7 +61,11 @@ void leave_mm(int cpu) BUG(); cpumask_clear_cpu(cpu, @@ -24536,10 +25893,11 @@ diff -urNp linux-2.6.32.49/arch/x86/mm/tlb.c li= nux-2.6.32.49/arch/x86/mm/tlb.c } EXPORT_SYMBOL_GPL(leave_mm); =20 -diff -urNp linux-2.6.32.49/arch/x86/oprofile/backtrace.c linux-2.6.32.49= /arch/x86/oprofile/backtrace.c ---- linux-2.6.32.49/arch/x86/oprofile/backtrace.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/arch/x86/oprofile/backtrace.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -57,7 +57,7 @@ static struct frame_head *dump_user_back +diff --git a/arch/x86/oprofile/backtrace.c b/arch/x86/oprofile/backtrace= .c +index 044897b..a195924 100644 +--- a/arch/x86/oprofile/backtrace.c ++++ b/arch/x86/oprofile/backtrace.c +@@ -57,7 +57,7 @@ static struct frame_head *dump_user_backtrace(struct f= rame_head *head) struct frame_head bufhead[2]; =20 /* Also check accessibility of one struct frame_head beyond */ @@ -24548,7 +25906,7 @@ diff -urNp linux-2.6.32.49/arch/x86/oprofile/back= trace.c linux-2.6.32.49/arch/x8 return NULL; if (__copy_from_user_inatomic(bufhead, head, sizeof(bufhead))) return NULL; -@@ -77,7 +77,7 @@ x86_backtrace(struct pt_regs * const reg +@@ -77,7 +77,7 @@ x86_backtrace(struct pt_regs * const regs, unsigned in= t depth) { struct frame_head *head =3D (struct frame_head *)frame_pointer(regs); =20 @@ -24557,10 +25915,11 @@ diff -urNp linux-2.6.32.49/arch/x86/oprofile/ba= cktrace.c linux-2.6.32.49/arch/x8 unsigned long stack =3D kernel_stack_pointer(regs); if (depth) dump_trace(NULL, regs, (unsigned long *)stack, 0, -diff -urNp linux-2.6.32.49/arch/x86/oprofile/op_model_p4.c linux-2.6.32.= 49/arch/x86/oprofile/op_model_p4.c ---- linux-2.6.32.49/arch/x86/oprofile/op_model_p4.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/arch/x86/oprofile/op_model_p4.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -50,7 +50,7 @@ static inline void setup_num_counters(vo +diff --git a/arch/x86/oprofile/op_model_p4.c b/arch/x86/oprofile/op_mode= l_p4.c +index e6a160a..36deff6 100644 +--- a/arch/x86/oprofile/op_model_p4.c ++++ b/arch/x86/oprofile/op_model_p4.c +@@ -50,7 +50,7 @@ static inline void setup_num_counters(void) #endif } =20 @@ -24569,9 +25928,10 @@ diff -urNp linux-2.6.32.49/arch/x86/oprofile/op_= model_p4.c linux-2.6.32.49/arch/ { #ifdef CONFIG_SMP return smp_num_siblings =3D=3D 2 ? 2 : 1; -diff -urNp linux-2.6.32.49/arch/x86/pci/common.c linux-2.6.32.49/arch/x8= 6/pci/common.c ---- linux-2.6.32.49/arch/x86/pci/common.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/pci/common.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/arch/x86/pci/common.c b/arch/x86/pci/common.c +index 1331fcf..03901b2 100644 +--- a/arch/x86/pci/common.c ++++ b/arch/x86/pci/common.c @@ -31,8 +31,8 @@ int noioapicreroute =3D 1; int pcibios_last_bus =3D -1; unsigned long pirq_table_addr; @@ -24583,10 +25943,11 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/common.= c linux-2.6.32.49/arch/x86/pci/co =20 int raw_pci_read(unsigned int domain, unsigned int bus, unsigned int de= vfn, int reg, int len, u32 *val) -diff -urNp linux-2.6.32.49/arch/x86/pci/direct.c linux-2.6.32.49/arch/x8= 6/pci/direct.c ---- linux-2.6.32.49/arch/x86/pci/direct.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/pci/direct.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -79,7 +79,7 @@ static int pci_conf1_write(unsigned int=20 +diff --git a/arch/x86/pci/direct.c b/arch/x86/pci/direct.c +index 347d882..4baf6b6 100644 +--- a/arch/x86/pci/direct.c ++++ b/arch/x86/pci/direct.c +@@ -79,7 +79,7 @@ static int pci_conf1_write(unsigned int seg, unsigned = int bus, =20 #undef PCI_CONF1_ADDRESS =20 @@ -24595,7 +25956,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/direct.c = linux-2.6.32.49/arch/x86/pci/di .read =3D pci_conf1_read, .write =3D pci_conf1_write, }; -@@ -173,7 +173,7 @@ static int pci_conf2_write(unsigned int=20 +@@ -173,7 +173,7 @@ static int pci_conf2_write(unsigned int seg, unsigne= d int bus, =20 #undef PCI_CONF2_ADDRESS =20 @@ -24613,10 +25974,11 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/direct.= c linux-2.6.32.49/arch/x86/pci/di { u32 x =3D 0; int year, devfn; -diff -urNp linux-2.6.32.49/arch/x86/pci/mmconfig_32.c linux-2.6.32.49/ar= ch/x86/pci/mmconfig_32.c ---- linux-2.6.32.49/arch/x86/pci/mmconfig_32.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/pci/mmconfig_32.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -125,7 +125,7 @@ static int pci_mmcfg_write(unsigned int=20 +diff --git a/arch/x86/pci/mmconfig_32.c b/arch/x86/pci/mmconfig_32.c +index f10a7e9..0425342 100644 +--- a/arch/x86/pci/mmconfig_32.c ++++ b/arch/x86/pci/mmconfig_32.c +@@ -125,7 +125,7 @@ static int pci_mmcfg_write(unsigned int seg, unsigne= d int bus, return 0; } =20 @@ -24625,10 +25987,11 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/mmconfi= g_32.c linux-2.6.32.49/arch/x86/p .read =3D pci_mmcfg_read, .write =3D pci_mmcfg_write, }; -diff -urNp linux-2.6.32.49/arch/x86/pci/mmconfig_64.c linux-2.6.32.49/ar= ch/x86/pci/mmconfig_64.c ---- linux-2.6.32.49/arch/x86/pci/mmconfig_64.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/arch/x86/pci/mmconfig_64.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -104,7 +104,7 @@ static int pci_mmcfg_write(unsigned int=20 +diff --git a/arch/x86/pci/mmconfig_64.c b/arch/x86/pci/mmconfig_64.c +index 94349f8..41600a7 100644 +--- a/arch/x86/pci/mmconfig_64.c ++++ b/arch/x86/pci/mmconfig_64.c +@@ -104,7 +104,7 @@ static int pci_mmcfg_write(unsigned int seg, unsigne= d int bus, return 0; } =20 @@ -24637,10 +26000,11 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/mmconfi= g_64.c linux-2.6.32.49/arch/x86/p .read =3D pci_mmcfg_read, .write =3D pci_mmcfg_write, }; -diff -urNp linux-2.6.32.49/arch/x86/pci/numaq_32.c linux-2.6.32.49/arch/= x86/pci/numaq_32.c ---- linux-2.6.32.49/arch/x86/pci/numaq_32.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/pci/numaq_32.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -112,7 +112,7 @@ static int pci_conf1_mq_write(unsigned i +diff --git a/arch/x86/pci/numaq_32.c b/arch/x86/pci/numaq_32.c +index 8eb295e..86bd657 100644 +--- a/arch/x86/pci/numaq_32.c ++++ b/arch/x86/pci/numaq_32.c +@@ -112,7 +112,7 @@ static int pci_conf1_mq_write(unsigned int seg, unsi= gned int bus, =20 #undef PCI_CONF1_MQ_ADDRESS =20 @@ -24649,10 +26013,11 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/numaq_3= 2.c linux-2.6.32.49/arch/x86/pci/ .read =3D pci_conf1_mq_read, .write =3D pci_conf1_mq_write }; -diff -urNp linux-2.6.32.49/arch/x86/pci/olpc.c linux-2.6.32.49/arch/x86/= pci/olpc.c ---- linux-2.6.32.49/arch/x86/pci/olpc.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/x86/pci/olpc.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -297,7 +297,7 @@ static int pci_olpc_write(unsigned int s +diff --git a/arch/x86/pci/olpc.c b/arch/x86/pci/olpc.c +index b889d82..5a58a0a 100644 +--- a/arch/x86/pci/olpc.c ++++ b/arch/x86/pci/olpc.c +@@ -297,7 +297,7 @@ static int pci_olpc_write(unsigned int seg, unsigned= int bus, return 0; } =20 @@ -24661,9 +26026,10 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/olpc.c l= inux-2.6.32.49/arch/x86/pci/olpc .read =3D pci_olpc_read, .write =3D pci_olpc_write, }; -diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c linux-2.6.32.49/arch/x8= 6/pci/pcbios.c ---- linux-2.6.32.49/arch/x86/pci/pcbios.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/arch/x86/pci/pcbios.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/arch/x86/pci/pcbios.c b/arch/x86/pci/pcbios.c +index 1c975cc..ffd0536 100644 +--- a/arch/x86/pci/pcbios.c ++++ b/arch/x86/pci/pcbios.c @@ -56,50 +56,93 @@ union bios32 { static struct { unsigned long address; @@ -24799,7 +26165,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc : "memory"); local_irq_restore(flags); =20 -@@ -165,7 +211,10 @@ static int pci_bios_read(unsigned int se +@@ -165,7 +211,10 @@ static int pci_bios_read(unsigned int seg, unsigned= int bus, =20 switch (len) { case 1: @@ -24811,7 +26177,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -174,7 +223,8 @@ static int pci_bios_read(unsigned int se +@@ -174,7 +223,8 @@ static int pci_bios_read(unsigned int seg, unsigned = int bus, : "1" (PCIBIOS_READ_CONFIG_BYTE), "b" (bx), "D" ((long)reg), @@ -24821,7 +26187,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc /* * Zero-extend the result beyond 8 bits, do not trust the * BIOS having done it: -@@ -182,7 +232,10 @@ static int pci_bios_read(unsigned int se +@@ -182,7 +232,10 @@ static int pci_bios_read(unsigned int seg, unsigned= int bus, *value &=3D 0xff; break; case 2: @@ -24833,7 +26199,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -191,7 +244,8 @@ static int pci_bios_read(unsigned int se +@@ -191,7 +244,8 @@ static int pci_bios_read(unsigned int seg, unsigned = int bus, : "1" (PCIBIOS_READ_CONFIG_WORD), "b" (bx), "D" ((long)reg), @@ -24843,7 +26209,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc /* * Zero-extend the result beyond 16 bits, do not trust the * BIOS having done it: -@@ -199,7 +253,10 @@ static int pci_bios_read(unsigned int se +@@ -199,7 +253,10 @@ static int pci_bios_read(unsigned int seg, unsigned= int bus, *value &=3D 0xffff; break; case 4: @@ -24855,7 +26221,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -208,7 +265,8 @@ static int pci_bios_read(unsigned int se +@@ -208,7 +265,8 @@ static int pci_bios_read(unsigned int seg, unsigned = int bus, : "1" (PCIBIOS_READ_CONFIG_DWORD), "b" (bx), "D" ((long)reg), @@ -24865,7 +26231,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc break; } =20 -@@ -231,7 +289,10 @@ static int pci_bios_write(unsigned int s +@@ -231,7 +289,10 @@ static int pci_bios_write(unsigned int seg, unsigne= d int bus, =20 switch (len) { case 1: @@ -24877,7 +26243,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -240,10 +301,14 @@ static int pci_bios_write(unsigned int s +@@ -240,10 +301,14 @@ static int pci_bios_write(unsigned int seg, unsign= ed int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -24894,7 +26260,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -252,10 +317,14 @@ static int pci_bios_write(unsigned int s +@@ -252,10 +317,14 @@ static int pci_bios_write(unsigned int seg, unsign= ed int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -24911,7 +26277,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -264,7 +333,8 @@ static int pci_bios_write(unsigned int s +@@ -264,7 +333,8 @@ static int pci_bios_write(unsigned int seg, unsigned= int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -24921,7 +26287,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc break; } =20 -@@ -278,7 +348,7 @@ static int pci_bios_write(unsigned int s +@@ -278,7 +348,7 @@ static int pci_bios_write(unsigned int seg, unsigned= int bus, * Function table for BIOS32 access */ =20 @@ -24930,7 +26296,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc .read =3D pci_bios_read, .write =3D pci_bios_write }; -@@ -287,7 +357,7 @@ static struct pci_raw_ops pci_bios_acces +@@ -287,7 +357,7 @@ static struct pci_raw_ops pci_bios_access =3D { * Try to find PCI BIOS. */ =20 @@ -24939,7 +26305,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc { union bios32 *check; unsigned char sum; -@@ -368,10 +438,13 @@ struct irq_routing_table * pcibios_get_i +@@ -368,10 +438,13 @@ struct irq_routing_table * pcibios_get_irq_routing= _table(void) =20 DBG("PCI: Fetching IRQ routing table... "); __asm__("push %%es\n\t" @@ -24954,7 +26320,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -382,7 +455,8 @@ struct irq_routing_table * pcibios_get_i +@@ -382,7 +455,8 @@ struct irq_routing_table * pcibios_get_irq_routing_t= able(void) "1" (0), "D" ((long) &opt), "S" (&pci_indirect), @@ -24964,7 +26330,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc : "memory"); DBG("OK ret=3D%d, size=3D%d, map=3D%x\n", ret, opt.size, map); if (ret & 0xff00) -@@ -406,7 +480,10 @@ int pcibios_set_irq_routing(struct pci_d +@@ -406,7 +480,10 @@ int pcibios_set_irq_routing(struct pci_dev *dev, in= t pin, int irq) { int ret; =20 @@ -24976,7 +26342,7 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c = linux-2.6.32.49/arch/x86/pci/pc "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -414,7 +491,8 @@ int pcibios_set_irq_routing(struct pci_d +@@ -414,7 +491,8 @@ int pcibios_set_irq_routing(struct pci_dev *dev, int= pin, int irq) : "0" (PCIBIOS_SET_PCI_HW_INT), "b" ((dev->bus->number << 8) | dev->devfn), "c" ((irq << 8) | (pin + 10)), @@ -24986,9 +26352,10 @@ diff -urNp linux-2.6.32.49/arch/x86/pci/pcbios.c= linux-2.6.32.49/arch/x86/pci/pc return !(ret & 0xff00); } EXPORT_SYMBOL(pcibios_set_irq_routing); -diff -urNp linux-2.6.32.49/arch/x86/power/cpu.c linux-2.6.32.49/arch/x86= /power/cpu.c ---- linux-2.6.32.49/arch/x86/power/cpu.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/arch/x86/power/cpu.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/arch/x86/power/cpu.c b/arch/x86/power/cpu.c +index fa0f651..9d8f3d9 100644 +--- a/arch/x86/power/cpu.c ++++ b/arch/x86/power/cpu.c @@ -129,7 +129,7 @@ static void do_fpu_end(void) static void fix_processor_context(void) { @@ -25008,9 +26375,10 @@ diff -urNp linux-2.6.32.49/arch/x86/power/cpu.c = linux-2.6.32.49/arch/x86/power/c =20 syscall_init(); /* This sets MSR_*STAR and related */ #endif -diff -urNp linux-2.6.32.49/arch/x86/vdso/Makefile linux-2.6.32.49/arch/x= 86/vdso/Makefile ---- linux-2.6.32.49/arch/x86/vdso/Makefile 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/vdso/Makefile 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/vdso/Makefile b/arch/x86/vdso/Makefile +index dd78ef6..f9d928d 100644 +--- a/arch/x86/vdso/Makefile ++++ b/arch/x86/vdso/Makefile @@ -122,7 +122,7 @@ quiet_cmd_vdso =3D VDSO $@ $(VDSO_LDFLAGS) $(VDSO_LDFLAGS_$(filter %.lds,$(^F))) \ -Wl,-T,$(filter %.lds,$^) $(filter %.o,$^) @@ -25020,9 +26388,10 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/Makefil= e linux-2.6.32.49/arch/x86/vdso/ GCOV_PROFILE :=3D n =20 # -diff -urNp linux-2.6.32.49/arch/x86/vdso/vclock_gettime.c linux-2.6.32.4= 9/arch/x86/vdso/vclock_gettime.c ---- linux-2.6.32.49/arch/x86/vdso/vclock_gettime.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/arch/x86/vdso/vclock_gettime.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/arch/x86/vdso/vclock_gettime.c b/arch/x86/vdso/vclock_getti= me.c +index ee55754..0013b2e 100644 +--- a/arch/x86/vdso/vclock_gettime.c ++++ b/arch/x86/vdso/vclock_gettime.c @@ -22,24 +22,48 @@ #include #include @@ -25076,7 +26445,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vclock_g= ettime.c linux-2.6.32.49/arch/x return (v * gtod->clock.mult) >> gtod->clock.shift; } =20 -@@ -113,7 +137,9 @@ notrace static noinline int do_monotonic +@@ -113,7 +137,9 @@ notrace static noinline int do_monotonic_coarse(stru= ct timespec *ts) =20 notrace int __vdso_clock_gettime(clockid_t clock, struct timespec *ts) { @@ -25087,7 +26456,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vclock_g= ettime.c linux-2.6.32.49/arch/x switch (clock) { case CLOCK_REALTIME: if (likely(gtod->clock.vread)) -@@ -133,10 +159,20 @@ notrace int __vdso_clock_gettime(clockid +@@ -133,10 +159,20 @@ notrace int __vdso_clock_gettime(clockid_t clock, = struct timespec *ts) int clock_gettime(clockid_t, struct timespec *) __attribute__((weak, alias("__vdso_clock_gettime"))); =20 @@ -25110,7 +26479,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vclock_g= ettime.c linux-2.6.32.49/arch/x if (likely(tv !=3D NULL)) { BUILD_BUG_ON(offsetof(struct timeval, tv_usec) !=3D offsetof(struct timespec, tv_nsec) || -@@ -151,9 +187,7 @@ notrace int __vdso_gettimeofday(struct t +@@ -151,9 +187,7 @@ notrace int __vdso_gettimeofday(struct timeval *tv, = struct timezone *tz) } return 0; } @@ -25121,9 +26490,24 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vclock_= gettime.c linux-2.6.32.49/arch/x } int gettimeofday(struct timeval *, struct timezone *) __attribute__((weak, alias("__vdso_gettimeofday"))); -diff -urNp linux-2.6.32.49/arch/x86/vdso/vdso32-setup.c linux-2.6.32.49/= arch/x86/vdso/vdso32-setup.c ---- linux-2.6.32.49/arch/x86/vdso/vdso32-setup.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/arch/x86/vdso/vdso32-setup.c 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/arch/x86/vdso/vdso.lds.S b/arch/x86/vdso/vdso.lds.S +index 4e5dd3b..00ba15e 100644 +--- a/arch/x86/vdso/vdso.lds.S ++++ b/arch/x86/vdso/vdso.lds.S +@@ -35,3 +35,9 @@ VDSO64_PRELINK =3D VDSO_PRELINK; + #define VEXTERN(x) VDSO64_ ## x =3D vdso_ ## x; + #include "vextern.h" + #undef VEXTERN ++ ++#define VEXTERN(x) VDSO64_ ## x =3D __vdso_ ## x; ++VEXTERN(fallback_gettimeofday) ++VEXTERN(fallback_time) ++VEXTERN(getcpu) ++#undef VEXTERN +diff --git a/arch/x86/vdso/vdso32-setup.c b/arch/x86/vdso/vdso32-setup.c +index 58bc00f..d53fb48 100644 +--- a/arch/x86/vdso/vdso32-setup.c ++++ b/arch/x86/vdso/vdso32-setup.c @@ -25,6 +25,7 @@ #include #include @@ -25132,7 +26516,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vdso32-s= etup.c linux-2.6.32.49/arch/x86 =20 enum { VDSO_DISABLED =3D 0, -@@ -226,7 +227,7 @@ static inline void map_compat_vdso(int m +@@ -226,7 +227,7 @@ static inline void map_compat_vdso(int map) void enable_sep_cpu(void) { int cpu =3D get_cpu(); @@ -25150,7 +26534,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vdso32-s= etup.c linux-2.6.32.49/arch/x86 /* * Make sure the vDSO gets into every core dump. * Dumping its contents makes post-mortem fully interpretable later -@@ -331,14 +332,14 @@ int arch_setup_additional_pages(struct l +@@ -331,14 +332,14 @@ int arch_setup_additional_pages(struct linux_binpr= m *bprm, int uses_interp) if (compat) addr =3D VDSO_HIGH_BASE; else { @@ -25167,7 +26551,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vdso32-s= etup.c linux-2.6.32.49/arch/x86 =20 if (compat_uses_vma || !compat) { /* -@@ -361,11 +362,11 @@ int arch_setup_additional_pages(struct l +@@ -361,11 +362,11 @@ int arch_setup_additional_pages(struct linux_binpr= m *bprm, int uses_interp) } =20 current_thread_info()->sysenter_return =3D @@ -25197,7 +26581,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vdso32-s= etup.c linux-2.6.32.49/arch/x86 return NULL; } =20 -@@ -423,7 +430,7 @@ struct vm_area_struct *get_gate_vma(stru +@@ -423,7 +430,7 @@ struct vm_area_struct *get_gate_vma(struct task_stru= ct *tsk) struct mm_struct *mm =3D tsk->mm; =20 /* Check to see if this task was created in compat vdso mode */ @@ -25206,22 +26590,10 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vdso32= -setup.c linux-2.6.32.49/arch/x86 return &gate_vma; return NULL; } -diff -urNp linux-2.6.32.49/arch/x86/vdso/vdso.lds.S linux-2.6.32.49/arch= /x86/vdso/vdso.lds.S ---- linux-2.6.32.49/arch/x86/vdso/vdso.lds.S 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/vdso/vdso.lds.S 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -35,3 +35,9 @@ VDSO64_PRELINK =3D VDSO_PRELINK; - #define VEXTERN(x) VDSO64_ ## x =3D vdso_ ## x; - #include "vextern.h" - #undef VEXTERN -+ -+#define VEXTERN(x) VDSO64_ ## x =3D __vdso_ ## x; -+VEXTERN(fallback_gettimeofday) -+VEXTERN(fallback_time) -+VEXTERN(getcpu) -+#undef VEXTERN -diff -urNp linux-2.6.32.49/arch/x86/vdso/vextern.h linux-2.6.32.49/arch/= x86/vdso/vextern.h ---- linux-2.6.32.49/arch/x86/vdso/vextern.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/vdso/vextern.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/vdso/vextern.h b/arch/x86/vdso/vextern.h +index 1683ba2..48d07f3 100644 +--- a/arch/x86/vdso/vextern.h ++++ b/arch/x86/vdso/vextern.h @@ -11,6 +11,5 @@ put into vextern.h and be referenced as a pointer with vdso prefix. The main kernel later fills in the values. */ @@ -25229,9 +26601,10 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vextern= .h linux-2.6.32.49/arch/x86/vdso -VEXTERN(jiffies) VEXTERN(vgetcpu_mode) VEXTERN(vsyscall_gtod_data) -diff -urNp linux-2.6.32.49/arch/x86/vdso/vma.c linux-2.6.32.49/arch/x86/= vdso/vma.c ---- linux-2.6.32.49/arch/x86/vdso/vma.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/arch/x86/vdso/vma.c 2011-11-18 18:01:52.000000000 -0= 500 +diff --git a/arch/x86/vdso/vma.c b/arch/x86/vdso/vma.c +index 21e1aeb..2c0b3c4 100644 +--- a/arch/x86/vdso/vma.c ++++ b/arch/x86/vdso/vma.c @@ -17,8 +17,6 @@ #include "vextern.h" /* Just for VMAGIC. */ #undef VEXTERN @@ -25280,7 +26653,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vma.c li= nux-2.6.32.49/arch/x86/vdso/vma } __initcall(init_vdso_vars); =20 -@@ -102,13 +95,15 @@ static unsigned long vdso_addr(unsigned=20 +@@ -102,13 +95,15 @@ static unsigned long vdso_addr(unsigned long start,= unsigned len) int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_int= erp) { struct mm_struct *mm =3D current->mm; @@ -25300,7 +26673,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vma.c li= nux-2.6.32.49/arch/x86/vdso/vma addr =3D vdso_addr(mm->start_stack, vdso_size); addr =3D get_unmapped_area(NULL, addr, vdso_size, 0, 0); if (IS_ERR_VALUE(addr)) { -@@ -116,7 +111,7 @@ int arch_setup_additional_pages(struct l +@@ -116,7 +111,7 @@ int arch_setup_additional_pages(struct linux_binprm = *bprm, int uses_interp) goto up_fail; } =20 @@ -25309,7 +26682,7 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vma.c li= nux-2.6.32.49/arch/x86/vdso/vma =20 ret =3D install_special_mapping(mm, addr, vdso_size, VM_READ|VM_EXEC| -@@ -124,7 +119,7 @@ int arch_setup_additional_pages(struct l +@@ -124,7 +119,7 @@ int arch_setup_additional_pages(struct linux_binprm = *bprm, int uses_interp) VM_ALWAYSDUMP, vdso_pages); if (ret) { @@ -25329,9 +26702,10 @@ diff -urNp linux-2.6.32.49/arch/x86/vdso/vma.c l= inux-2.6.32.49/arch/x86/vdso/vma - return 0; -} -__setup("vdso=3D", vdso_setup); -diff -urNp linux-2.6.32.49/arch/x86/xen/enlighten.c linux-2.6.32.49/arch= /x86/xen/enlighten.c ---- linux-2.6.32.49/arch/x86/xen/enlighten.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/arch/x86/xen/enlighten.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c +index 0087b00..eecb34f 100644 +--- a/arch/x86/xen/enlighten.c ++++ b/arch/x86/xen/enlighten.c @@ -71,8 +71,6 @@ EXPORT_SYMBOL_GPL(xen_start_info); =20 struct shared_info xen_dummy_shared_info; @@ -25341,7 +26715,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/enlighten= .c linux-2.6.32.49/arch/x86/xen /* * Point at some empty memory to start with. We map the real shared_inf= o * page as soon as fixmap is up and running. -@@ -548,7 +546,7 @@ static void xen_write_idt_entry(gate_des +@@ -548,7 +546,7 @@ static void xen_write_idt_entry(gate_desc *dt, int e= ntrynum, const gate_desc *g) =20 preempt_disable(); =20 @@ -25350,7 +26724,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/enlighten= .c linux-2.6.32.49/arch/x86/xen end =3D start + __get_cpu_var(idt_desc).size + 1; =20 xen_mc_flush(); -@@ -993,7 +991,7 @@ static const struct pv_apic_ops xen_apic +@@ -993,7 +991,7 @@ static const struct pv_apic_ops xen_apic_ops __initd= ata =3D { #endif }; =20 @@ -25380,7 +26754,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/enlighten= .c linux-2.6.32.49/arch/x86/xen { xen_reboot(SHUTDOWN_poweroff); } -@@ -1095,9 +1093,20 @@ asmlinkage void __init xen_start_kernel( +@@ -1095,9 +1093,20 @@ asmlinkage void __init xen_start_kernel(void) */ __userpte_alloc_gfp &=3D ~__GFP_HIGHMEM; =20 @@ -25403,7 +26777,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/enlighten= .c linux-2.6.32.49/arch/x86/xen #endif =20 xen_setup_features(); -@@ -1129,13 +1138,6 @@ asmlinkage void __init xen_start_kernel( +@@ -1129,13 +1138,6 @@ asmlinkage void __init xen_start_kernel(void) =20 machine_ops =3D xen_machine_ops; =20 @@ -25417,10 +26791,11 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/enlight= en.c linux-2.6.32.49/arch/x86/xen xen_smp_init(); =20 pgd =3D (pgd_t *)xen_start_info->pt_base; -diff -urNp linux-2.6.32.49/arch/x86/xen/mmu.c linux-2.6.32.49/arch/x86/x= en/mmu.c ---- linux-2.6.32.49/arch/x86/xen/mmu.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/x86/xen/mmu.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -1719,6 +1719,8 @@ __init pgd_t *xen_setup_kernel_pagetable +diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c +index 3f90a2c..ee0d992 100644 +--- a/arch/x86/xen/mmu.c ++++ b/arch/x86/xen/mmu.c +@@ -1719,6 +1719,8 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pg= d, convert_pfn_mfn(init_level4_pgt); convert_pfn_mfn(level3_ident_pgt); convert_pfn_mfn(level3_kernel_pgt); @@ -25429,7 +26804,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/mmu.c lin= ux-2.6.32.49/arch/x86/xen/mmu.c =20 l3 =3D m2v(pgd[pgd_index(__START_KERNEL_map)].pgd); l2 =3D m2v(l3[pud_index(__START_KERNEL_map)].pud); -@@ -1737,7 +1739,10 @@ __init pgd_t *xen_setup_kernel_pagetable +@@ -1737,7 +1739,10 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *p= gd, set_page_prot(init_level4_pgt, PAGE_KERNEL_RO); set_page_prot(level3_ident_pgt, PAGE_KERNEL_RO); set_page_prot(level3_kernel_pgt, PAGE_KERNEL_RO); @@ -25440,7 +26815,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/mmu.c lin= ux-2.6.32.49/arch/x86/xen/mmu.c set_page_prot(level2_kernel_pgt, PAGE_KERNEL_RO); set_page_prot(level2_fixmap_pgt, PAGE_KERNEL_RO); =20 -@@ -1860,6 +1865,7 @@ static __init void xen_post_allocator_in +@@ -1860,6 +1865,7 @@ static __init void xen_post_allocator_init(void) pv_mmu_ops.set_pud =3D xen_set_pud; #if PAGETABLE_LEVELS =3D=3D 4 pv_mmu_ops.set_pgd =3D xen_set_pgd; @@ -25448,7 +26823,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/mmu.c lin= ux-2.6.32.49/arch/x86/xen/mmu.c #endif =20 /* This will work as long as patching hasn't happened yet -@@ -1946,6 +1952,7 @@ static const struct pv_mmu_ops xen_mmu_o +@@ -1946,6 +1952,7 @@ static const struct pv_mmu_ops xen_mmu_ops __initd= ata =3D { .pud_val =3D PV_CALLEE_SAVE(xen_pud_val), .make_pud =3D PV_CALLEE_SAVE(xen_make_pud), .set_pgd =3D xen_set_pgd_hyper, @@ -25456,10 +26831,11 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/mmu.c l= inux-2.6.32.49/arch/x86/xen/mmu.c =20 .alloc_pud =3D xen_alloc_pmd_init, .release_pud =3D xen_release_pmd_init, -diff -urNp linux-2.6.32.49/arch/x86/xen/smp.c linux-2.6.32.49/arch/x86/x= en/smp.c ---- linux-2.6.32.49/arch/x86/xen/smp.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/arch/x86/xen/smp.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -168,11 +168,6 @@ static void __init xen_smp_prepare_boot_ +diff --git a/arch/x86/xen/smp.c b/arch/x86/xen/smp.c +index a96204a..fca9b8e 100644 +--- a/arch/x86/xen/smp.c ++++ b/arch/x86/xen/smp.c +@@ -168,11 +168,6 @@ static void __init xen_smp_prepare_boot_cpu(void) { BUG_ON(smp_processor_id() !=3D 0); native_smp_prepare_boot_cpu(); @@ -25471,7 +26847,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/smp.c lin= ux-2.6.32.49/arch/x86/xen/smp.c xen_setup_vcpu_info_placement(); } =20 -@@ -241,12 +236,12 @@ cpu_initialize_context(unsigned int cpu, +@@ -241,12 +236,12 @@ cpu_initialize_context(unsigned int cpu, struct ta= sk_struct *idle) gdt =3D get_cpu_gdt_table(cpu); =20 ctxt->flags =3D VGCF_IN_KERNEL; @@ -25487,7 +26863,7 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/smp.c lin= ux-2.6.32.49/arch/x86/xen/smp.c #else ctxt->gs_base_kernel =3D per_cpu_offset(cpu); #endif -@@ -297,13 +292,12 @@ static int __cpuinit xen_cpu_up(unsigned +@@ -297,13 +292,12 @@ static int __cpuinit xen_cpu_up(unsigned int cpu) int rc; =20 per_cpu(current_task, cpu) =3D idle; @@ -25503,9 +26879,10 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/smp.c li= nux-2.6.32.49/arch/x86/xen/smp.c #endif xen_setup_runstate_info(cpu); xen_setup_timer(cpu); -diff -urNp linux-2.6.32.49/arch/x86/xen/xen-asm_32.S linux-2.6.32.49/arc= h/x86/xen/xen-asm_32.S ---- linux-2.6.32.49/arch/x86/xen/xen-asm_32.S 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/arch/x86/xen/xen-asm_32.S 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/arch/x86/xen/xen-asm_32.S b/arch/x86/xen/xen-asm_32.S +index 9a95a9c..4f39e774 100644 +--- a/arch/x86/xen/xen-asm_32.S ++++ b/arch/x86/xen/xen-asm_32.S @@ -83,14 +83,14 @@ ENTRY(xen_iret) ESP_OFFSET=3D4 # bytes pushed onto stack =20 @@ -25527,9 +26904,10 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/xen-asm_= 32.S linux-2.6.32.49/arch/x86/xe #else movl per_cpu__xen_vcpu, %eax #endif -diff -urNp linux-2.6.32.49/arch/x86/xen/xen-head.S linux-2.6.32.49/arch/= x86/xen/xen-head.S ---- linux-2.6.32.49/arch/x86/xen/xen-head.S 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/arch/x86/xen/xen-head.S 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/arch/x86/xen/xen-head.S b/arch/x86/xen/xen-head.S +index 1a5ff24..a187d40 100644 +--- a/arch/x86/xen/xen-head.S ++++ b/arch/x86/xen/xen-head.S @@ -19,6 +19,17 @@ ENTRY(startup_xen) #ifdef CONFIG_X86_32 mov %esi,xen_start_info @@ -25548,9 +26926,10 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/xen-head= .S linux-2.6.32.49/arch/x86/xen/ #else mov %rsi,xen_start_info mov $init_thread_union+THREAD_SIZE,%rsp -diff -urNp linux-2.6.32.49/arch/x86/xen/xen-ops.h linux-2.6.32.49/arch/x= 86/xen/xen-ops.h ---- linux-2.6.32.49/arch/x86/xen/xen-ops.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/arch/x86/xen/xen-ops.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/arch/x86/xen/xen-ops.h b/arch/x86/xen/xen-ops.h +index f9153a3..51eab3d 100644 +--- a/arch/x86/xen/xen-ops.h ++++ b/arch/x86/xen/xen-ops.h @@ -10,8 +10,6 @@ extern const char xen_hypervisor_callback[]; extern const char xen_failsafe_callback[]; @@ -25560,10 +26939,11 @@ diff -urNp linux-2.6.32.49/arch/x86/xen/xen-ops= .h linux-2.6.32.49/arch/x86/xen/x struct trap_info; void xen_copy_trap_info(struct trap_info *traps); =20 -diff -urNp linux-2.6.32.49/block/blk-integrity.c linux-2.6.32.49/block/b= lk-integrity.c ---- linux-2.6.32.49/block/blk-integrity.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/block/blk-integrity.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -278,7 +278,7 @@ static struct attribute *integrity_attrs +diff --git a/block/blk-integrity.c b/block/blk-integrity.c +index 15c6308..96e83c2 100644 +--- a/block/blk-integrity.c ++++ b/block/blk-integrity.c +@@ -278,7 +278,7 @@ static struct attribute *integrity_attrs[] =3D { NULL, }; =20 @@ -25572,10 +26952,11 @@ diff -urNp linux-2.6.32.49/block/blk-integrity.= c linux-2.6.32.49/block/blk-integ .show =3D &integrity_attr_show, .store =3D &integrity_attr_store, }; -diff -urNp linux-2.6.32.49/block/blk-iopoll.c linux-2.6.32.49/block/blk-= iopoll.c ---- linux-2.6.32.49/block/blk-iopoll.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/block/blk-iopoll.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -77,7 +77,7 @@ void blk_iopoll_complete(struct blk_iopo +diff --git a/block/blk-iopoll.c b/block/blk-iopoll.c +index ca56420..f2fc409 100644 +--- a/block/blk-iopoll.c ++++ b/block/blk-iopoll.c +@@ -77,7 +77,7 @@ void blk_iopoll_complete(struct blk_iopoll *iopoll) } EXPORT_SYMBOL(blk_iopoll_complete); =20 @@ -25584,10 +26965,11 @@ diff -urNp linux-2.6.32.49/block/blk-iopoll.c l= inux-2.6.32.49/block/blk-iopoll.c { struct list_head *list =3D &__get_cpu_var(blk_cpu_iopoll); int rearm =3D 0, budget =3D blk_iopoll_budget; -diff -urNp linux-2.6.32.49/block/blk-map.c linux-2.6.32.49/block/blk-map= .c ---- linux-2.6.32.49/block/blk-map.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/block/blk-map.c 2011-11-15 19:59:43.000000000 -0500 -@@ -54,7 +54,7 @@ static int __blk_rq_map_user(struct requ +diff --git a/block/blk-map.c b/block/blk-map.c +index 30a7e51..0aeec6a 100644 +--- a/block/blk-map.c ++++ b/block/blk-map.c +@@ -54,7 +54,7 @@ static int __blk_rq_map_user(struct request_queue *q, = struct request *rq, * direct dma. else, set up kernel bounce buffers */ uaddr =3D (unsigned long) ubuf; @@ -25596,7 +26978,7 @@ diff -urNp linux-2.6.32.49/block/blk-map.c linux-= 2.6.32.49/block/blk-map.c bio =3D bio_map_user(q, NULL, uaddr, len, reading, gfp_mask); else bio =3D bio_copy_user(q, map_data, uaddr, len, reading, gfp_mask); -@@ -201,12 +201,13 @@ int blk_rq_map_user_iov(struct request_q +@@ -201,12 +201,13 @@ int blk_rq_map_user_iov(struct request_queue *q, s= truct request *rq, for (i =3D 0; i < iov_count; i++) { unsigned long uaddr =3D (unsigned long)iov[i].iov_base; =20 @@ -25612,7 +26994,7 @@ diff -urNp linux-2.6.32.49/block/blk-map.c linux-= 2.6.32.49/block/blk-map.c } =20 if (unaligned || (q->dma_pad_mask & len) || map_data) -@@ -299,7 +300,7 @@ int blk_rq_map_kern(struct request_queue +@@ -299,7 +300,7 @@ int blk_rq_map_kern(struct request_queue *q, struct = request *rq, void *kbuf, if (!len || !kbuf) return -EINVAL; =20 @@ -25621,10 +27003,11 @@ diff -urNp linux-2.6.32.49/block/blk-map.c linu= x-2.6.32.49/block/blk-map.c if (do_copy) bio =3D bio_copy_kern(q, kbuf, len, gfp_mask, reading); else -diff -urNp linux-2.6.32.49/block/blk-softirq.c linux-2.6.32.49/block/blk= -softirq.c ---- linux-2.6.32.49/block/blk-softirq.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/block/blk-softirq.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -17,7 +17,7 @@ static DEFINE_PER_CPU(struct list_head,=20 +diff --git a/block/blk-softirq.c b/block/blk-softirq.c +index ee9c216..58d410a 100644 +--- a/block/blk-softirq.c ++++ b/block/blk-softirq.c +@@ -17,7 +17,7 @@ static DEFINE_PER_CPU(struct list_head, blk_cpu_done); * Softirq action handler - move entries to local list and loop over th= em * while passing them to the queue registered handler. */ @@ -25633,10 +27016,11 @@ diff -urNp linux-2.6.32.49/block/blk-softirq.c = linux-2.6.32.49/block/blk-softirq { struct list_head *cpu_list, local_list; =20 -diff -urNp linux-2.6.32.49/block/blk-sysfs.c linux-2.6.32.49/block/blk-s= ysfs.c ---- linux-2.6.32.49/block/blk-sysfs.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/block/blk-sysfs.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -414,7 +414,7 @@ static void blk_release_queue(struct kob +diff --git a/block/blk-sysfs.c b/block/blk-sysfs.c +index bb9c5ea..5330d48 100644 +--- a/block/blk-sysfs.c ++++ b/block/blk-sysfs.c +@@ -414,7 +414,7 @@ static void blk_release_queue(struct kobject *kobj) kmem_cache_free(blk_requestq_cachep, q); } =20 @@ -25645,10 +27029,11 @@ diff -urNp linux-2.6.32.49/block/blk-sysfs.c li= nux-2.6.32.49/block/blk-sysfs.c .show =3D queue_attr_show, .store =3D queue_attr_store, }; -diff -urNp linux-2.6.32.49/block/bsg.c linux-2.6.32.49/block/bsg.c ---- linux-2.6.32.49/block/bsg.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/block/bsg.c 2011-11-15 19:59:43.000000000 -0500 -@@ -175,16 +175,24 @@ static int blk_fill_sgv4_hdr_rq(struct r +diff --git a/block/bsg.c b/block/bsg.c +index 7154a7a..08ac2f0 100644 +--- a/block/bsg.c ++++ b/block/bsg.c +@@ -175,16 +175,24 @@ static int blk_fill_sgv4_hdr_rq(struct request_que= ue *q, struct request *rq, struct sg_io_v4 *hdr, struct bsg_device *bd, fmode_t has_write_perm) { @@ -25675,7 +27060,7 @@ diff -urNp linux-2.6.32.49/block/bsg.c linux-2.6.= 32.49/block/bsg.c if (hdr->subprotocol =3D=3D BSG_SUB_PROTOCOL_SCSI_CMD) { if (blk_verify_command(rq->cmd, has_write_perm)) return -EPERM; -@@ -282,7 +290,7 @@ bsg_map_hdr(struct bsg_device *bd, struc +@@ -282,7 +290,7 @@ bsg_map_hdr(struct bsg_device *bd, struct sg_io_v4 *= hdr, fmode_t has_write_perm, rq->next_rq =3D next_rq; next_rq->cmd_type =3D rq->cmd_type; =20 @@ -25684,7 +27069,7 @@ diff -urNp linux-2.6.32.49/block/bsg.c linux-2.6.= 32.49/block/bsg.c ret =3D blk_rq_map_user(q, next_rq, NULL, dxferp, hdr->din_xfer_len, GFP_KERNEL); if (ret) -@@ -291,10 +299,10 @@ bsg_map_hdr(struct bsg_device *bd, struc +@@ -291,10 +299,10 @@ bsg_map_hdr(struct bsg_device *bd, struct sg_io_v4= *hdr, fmode_t has_write_perm, =20 if (hdr->dout_xfer_len) { dxfer_len =3D hdr->dout_xfer_len; @@ -25697,7 +27082,7 @@ diff -urNp linux-2.6.32.49/block/bsg.c linux-2.6.= 32.49/block/bsg.c } else dxfer_len =3D 0; =20 -@@ -436,7 +444,7 @@ static int blk_complete_sgv4_hdr_rq(stru +@@ -436,7 +444,7 @@ static int blk_complete_sgv4_hdr_rq(struct request *= rq, struct sg_io_v4 *hdr, int len =3D min_t(unsigned int, hdr->max_response_len, rq->sense_len); =20 @@ -25706,10 +27091,11 @@ diff -urNp linux-2.6.32.49/block/bsg.c linux-2.= 6.32.49/block/bsg.c rq->sense, len); if (!ret) hdr->response_len =3D len; -diff -urNp linux-2.6.32.49/block/compat_ioctl.c linux-2.6.32.49/block/co= mpat_ioctl.c ---- linux-2.6.32.49/block/compat_ioctl.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/block/compat_ioctl.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -354,7 +354,7 @@ static int compat_fd_ioctl(struct block_ +diff --git a/block/compat_ioctl.c b/block/compat_ioctl.c +index 9bd086c..ca1fc22 100644 +--- a/block/compat_ioctl.c ++++ b/block/compat_ioctl.c +@@ -354,7 +354,7 @@ static int compat_fd_ioctl(struct block_device *bdev= , fmode_t mode, err |=3D __get_user(f->spec1, &uf->spec1); err |=3D __get_user(f->fmt_gap, &uf->fmt_gap); err |=3D __get_user(name, &uf->name); @@ -25718,10 +27104,11 @@ diff -urNp linux-2.6.32.49/block/compat_ioctl.c= linux-2.6.32.49/block/compat_ioc if (err) { err =3D -EFAULT; goto out; -diff -urNp linux-2.6.32.49/block/elevator.c linux-2.6.32.49/block/elevat= or.c ---- linux-2.6.32.49/block/elevator.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/block/elevator.c 2011-11-15 19:59:43.000000000 -0500 -@@ -889,7 +889,7 @@ elv_attr_store(struct kobject *kobj, str +diff --git a/block/elevator.c b/block/elevator.c +index a847046..75a1746 100644 +--- a/block/elevator.c ++++ b/block/elevator.c +@@ -889,7 +889,7 @@ elv_attr_store(struct kobject *kobj, struct attribut= e *attr, return error; } =20 @@ -25730,9 +27117,10 @@ diff -urNp linux-2.6.32.49/block/elevator.c linu= x-2.6.32.49/block/elevator.c .show =3D elv_attr_show, .store =3D elv_attr_store, }; -diff -urNp linux-2.6.32.49/block/scsi_ioctl.c linux-2.6.32.49/block/scsi= _ioctl.c ---- linux-2.6.32.49/block/scsi_ioctl.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/block/scsi_ioctl.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/block/scsi_ioctl.c b/block/scsi_ioctl.c +index 1d5a780..0e2fb8c 100644 +--- a/block/scsi_ioctl.c ++++ b/block/scsi_ioctl.c @@ -220,8 +220,20 @@ EXPORT_SYMBOL(blk_verify_command); static int blk_fill_sghdr_rq(struct request_queue *q, struct request *r= q, struct sg_io_hdr *hdr, fmode_t mode) @@ -25755,7 +27143,7 @@ diff -urNp linux-2.6.32.49/block/scsi_ioctl.c lin= ux-2.6.32.49/block/scsi_ioctl.c if (blk_verify_command(rq->cmd, mode & FMODE_WRITE)) return -EPERM; =20 -@@ -430,6 +442,8 @@ int sg_scsi_ioctl(struct request_queue * +@@ -430,6 +442,8 @@ int sg_scsi_ioctl(struct request_queue *q, struct ge= ndisk *disk, fmode_t mode, int err; unsigned int in_len, out_len, bytes, opcode, cmdlen; char *buffer =3D NULL, sense[SCSI_SENSE_BUFFERSIZE]; @@ -25764,7 +27152,7 @@ diff -urNp linux-2.6.32.49/block/scsi_ioctl.c lin= ux-2.6.32.49/block/scsi_ioctl.c =20 if (!sic) return -EINVAL; -@@ -463,9 +477,18 @@ int sg_scsi_ioctl(struct request_queue * +@@ -463,9 +477,18 @@ int sg_scsi_ioctl(struct request_queue *q, struct g= endisk *disk, fmode_t mode, */ err =3D -EFAULT; rq->cmd_len =3D cmdlen; @@ -25784,9 +27172,10 @@ diff -urNp linux-2.6.32.49/block/scsi_ioctl.c li= nux-2.6.32.49/block/scsi_ioctl.c if (in_len && copy_from_user(buffer, sic->data + cmdlen, in_len)) goto error; =20 -diff -urNp linux-2.6.32.49/crypto/cryptd.c linux-2.6.32.49/crypto/cryptd= .c ---- linux-2.6.32.49/crypto/cryptd.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/crypto/cryptd.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/crypto/cryptd.c b/crypto/cryptd.c +index 3533582..f143117 100644 +--- a/crypto/cryptd.c ++++ b/crypto/cryptd.c @@ -50,7 +50,7 @@ struct cryptd_blkcipher_ctx { =20 struct cryptd_blkcipher_request_ctx { @@ -25796,10 +27185,11 @@ diff -urNp linux-2.6.32.49/crypto/cryptd.c linu= x-2.6.32.49/crypto/cryptd.c =20 struct cryptd_hash_ctx { struct crypto_shash *child; -diff -urNp linux-2.6.32.49/crypto/gf128mul.c linux-2.6.32.49/crypto/gf12= 8mul.c ---- linux-2.6.32.49/crypto/gf128mul.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/crypto/gf128mul.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -182,7 +182,7 @@ void gf128mul_lle(be128 *r, const be128=20 +diff --git a/crypto/gf128mul.c b/crypto/gf128mul.c +index a90d260..7a9765e 100644 +--- a/crypto/gf128mul.c ++++ b/crypto/gf128mul.c +@@ -182,7 +182,7 @@ void gf128mul_lle(be128 *r, const be128 *b) for (i =3D 0; i < 7; ++i) gf128mul_x_lle(&p[i + 1], &p[i]); =20 @@ -25808,7 +27198,7 @@ diff -urNp linux-2.6.32.49/crypto/gf128mul.c linu= x-2.6.32.49/crypto/gf128mul.c for (i =3D 0;;) { u8 ch =3D ((u8 *)b)[15 - i]; =20 -@@ -220,7 +220,7 @@ void gf128mul_bbe(be128 *r, const be128=20 +@@ -220,7 +220,7 @@ void gf128mul_bbe(be128 *r, const be128 *b) for (i =3D 0; i < 7; ++i) gf128mul_x_bbe(&p[i + 1], &p[i]); =20 @@ -25817,9 +27207,10 @@ diff -urNp linux-2.6.32.49/crypto/gf128mul.c lin= ux-2.6.32.49/crypto/gf128mul.c for (i =3D 0;;) { u8 ch =3D ((u8 *)b)[i]; =20 -diff -urNp linux-2.6.32.49/crypto/serpent.c linux-2.6.32.49/crypto/serpe= nt.c ---- linux-2.6.32.49/crypto/serpent.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/crypto/serpent.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/crypto/serpent.c b/crypto/serpent.c +index b651a55..023297d 100644 +--- a/crypto/serpent.c ++++ b/crypto/serpent.c @@ -21,6 +21,7 @@ #include #include @@ -25828,7 +27219,7 @@ diff -urNp linux-2.6.32.49/crypto/serpent.c linux= -2.6.32.49/crypto/serpent.c =20 /* Key is padded to the maximum of 256 bits before round key generation= . * Any key length <=3D 256 bits (32 bytes) is allowed by the algorithm. -@@ -224,6 +225,8 @@ static int serpent_setkey(struct crypto_ +@@ -224,6 +225,8 @@ static int serpent_setkey(struct crypto_tfm *tfm, co= nst u8 *key, u32 r0,r1,r2,r3,r4; int i; =20 @@ -25837,182 +27228,10 @@ diff -urNp linux-2.6.32.49/crypto/serpent.c li= nux-2.6.32.49/crypto/serpent.c /* Copy key, add padding */ =20 for (i =3D 0; i < keylen; ++i) -diff -urNp linux-2.6.32.49/Documentation/dontdiff linux-2.6.32.49/Docume= ntation/dontdiff ---- linux-2.6.32.49/Documentation/dontdiff 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/Documentation/dontdiff 2011-11-18 18:01:52.000000000= -0500 -@@ -1,13 +1,16 @@ - *.a - *.aux - *.bin -+*.cis - *.cpio - *.csp -+*.dbg - *.dsp - *.dvi - *.elf - *.eps - *.fw -+*.gcno - *.gen.S - *.gif - *.grep -@@ -38,8 +41,10 @@ - *.tab.h - *.tex - *.ver -+*.vim - *.xml - *_MODULES -+*_reg_safe.h - *_vga16.c - *~ - *.9 -@@ -49,11 +54,16 @@ - 53c700_d.h - CVS - ChangeSet -+GPATH -+GRTAGS -+GSYMS -+GTAGS - Image - Kerntypes - Module.markers - Module.symvers - PENDING -+PERF* - SCCS - System.map* - TAGS -@@ -76,7 +86,11 @@ btfixupprep - build - bvmlinux - bzImage* -+capability_names.h -+capflags.c - classlist.h* -+clut_vga16.c -+common-cmds.h - comp*.log - compile.h* - conf -@@ -84,6 +98,8 @@ config - config-* - config_data.h* - config_data.gz* -+config.c -+config.tmp - conmakehash - consolemap_deftbl.c* - cpustr.h -@@ -97,19 +113,22 @@ elfconfig.h* - fixdep - fore200e_mkfirm - fore200e_pca_fw.c* -+gate.lds - gconf - gen-devlist - gen_crc32table - gen_init_cpio - genksyms - *_gray256.c -+hash - ihex2fw - ikconfig.h* - initramfs_data.cpio -+initramfs_data.cpio.bz2 - initramfs_data.cpio.gz - initramfs_list - kallsyms --kconfig -+kern_constants.h - keywords.c - ksym.c* - ksym.h* -@@ -133,7 +152,9 @@ mkboot - mkbugboot - mkcpustr - mkdep -+mkpiggy - mkprep -+mkregtable - mktables - mktree - modpost -@@ -149,6 +170,7 @@ patches* - pca200e.bin - pca200e_ecd.bin2 - piggy.gz -+piggy.S - piggyback - pnmtologo - ppc_defs.h* -@@ -157,12 +179,15 @@ qconf - raid6altivec*.c - raid6int*.c - raid6tables.c -+regdb.c - relocs -+rlim_names.h - series - setup - setup.bin - setup.elf - sImage -+slabinfo - sm_tbl* - split-include - syscalltab.h -@@ -171,6 +196,7 @@ tftpboot.img - timeconst.h - times.h* - trix_boot.h -+user_constants.h - utsrelease.h* - vdso-syms.lds - vdso.lds -@@ -186,14 +212,20 @@ version.h* - vmlinux - vmlinux-* - vmlinux.aout -+vmlinux.bin.all -+vmlinux.bin.bz2 - vmlinux.lds -+vmlinux.relocs -+voffset.h - vsyscall.lds - vsyscall_32.lds - wanxlfw.inc - uImage - unifdef -+utsrelease.h - wakeup.bin - wakeup.elf - wakeup.lds - zImage* - zconf.hash.c -+zoffset.h -diff -urNp linux-2.6.32.49/Documentation/kernel-parameters.txt linux-2.6= .32.49/Documentation/kernel-parameters.txt ---- linux-2.6.32.49/Documentation/kernel-parameters.txt 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/Documentation/kernel-parameters.txt 2011-11-15 19:59= :43.000000000 -0500 -@@ -1837,6 +1837,13 @@ and is between 256 and 4096 characters.=20 - the specified number of seconds. This is to be used if - your oopses keep scrolling off the screen. -=20 -+ pax_nouderef [X86] disables UDEREF. Most likely needed under certain -+ virtualization environments that don't cope well with the -+ expand down segment used by UDEREF on X86-32 or the frequent -+ page table updates on X86-64. -+ -+ pax_softmode=3D 0/1 to disable/enable PaX softmode on boot already. -+ - pcbit=3D [HW,ISDN] -=20 - pcd. [PARIDE] -diff -urNp linux-2.6.32.49/drivers/acpi/acpi_pad.c linux-2.6.32.49/drive= rs/acpi/acpi_pad.c ---- linux-2.6.32.49/drivers/acpi/acpi_pad.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/acpi/acpi_pad.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/acpi/acpi_pad.c b/drivers/acpi/acpi_pad.c +index 0d2cdb8..d8de48d 100644 +--- a/drivers/acpi/acpi_pad.c ++++ b/drivers/acpi/acpi_pad.c @@ -30,7 +30,7 @@ #include #include @@ -26022,9 +27241,10 @@ diff -urNp linux-2.6.32.49/drivers/acpi/acpi_pad= .c linux-2.6.32.49/drivers/acpi/ #define ACPI_PROCESSOR_AGGREGATOR_DEVICE_NAME "Processor Aggregator" #define ACPI_PROCESSOR_AGGREGATOR_NOTIFY 0x80 static DEFINE_MUTEX(isolated_cpus_lock); -diff -urNp linux-2.6.32.49/drivers/acpi/battery.c linux-2.6.32.49/driver= s/acpi/battery.c ---- linux-2.6.32.49/drivers/acpi/battery.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/acpi/battery.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/drivers/acpi/battery.c b/drivers/acpi/battery.c +index 3f4602b..2e41d36 100644 +--- a/drivers/acpi/battery.c ++++ b/drivers/acpi/battery.c @@ -763,7 +763,7 @@ DECLARE_FILE_FUNCTIONS(alarm); } =20 @@ -26034,9 +27254,10 @@ diff -urNp linux-2.6.32.49/drivers/acpi/battery.= c linux-2.6.32.49/drivers/acpi/b mode_t mode; const char *name; } acpi_battery_file[] =3D { -diff -urNp linux-2.6.32.49/drivers/acpi/dock.c linux-2.6.32.49/drivers/a= cpi/dock.c ---- linux-2.6.32.49/drivers/acpi/dock.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/acpi/dock.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/drivers/acpi/dock.c b/drivers/acpi/dock.c +index 7338b6a..82f0257 100644 +--- a/drivers/acpi/dock.c ++++ b/drivers/acpi/dock.c @@ -77,7 +77,7 @@ struct dock_dependent_device { struct list_head list; struct list_head hotplug_list; @@ -26046,7 +27267,7 @@ diff -urNp linux-2.6.32.49/drivers/acpi/dock.c li= nux-2.6.32.49/drivers/acpi/dock void *context; }; =20 -@@ -605,7 +605,7 @@ EXPORT_SYMBOL_GPL(unregister_dock_notifi +@@ -605,7 +605,7 @@ EXPORT_SYMBOL_GPL(unregister_dock_notifier); * the dock driver after _DCK is executed. */ int @@ -26055,10 +27276,11 @@ diff -urNp linux-2.6.32.49/drivers/acpi/dock.c = linux-2.6.32.49/drivers/acpi/dock void *context) { struct dock_dependent_device *dd; -diff -urNp linux-2.6.32.49/drivers/acpi/osl.c linux-2.6.32.49/drivers/ac= pi/osl.c ---- linux-2.6.32.49/drivers/acpi/osl.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/acpi/osl.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -523,6 +523,8 @@ acpi_os_read_memory(acpi_physical_addres +diff --git a/drivers/acpi/osl.c b/drivers/acpi/osl.c +index 7c1c59e..2993595 100644 +--- a/drivers/acpi/osl.c ++++ b/drivers/acpi/osl.c +@@ -523,6 +523,8 @@ acpi_os_read_memory(acpi_physical_address phys_addr,= u32 * value, u32 width) void __iomem *virt_addr; =20 virt_addr =3D ioremap(phys_addr, width); @@ -26067,7 +27289,7 @@ diff -urNp linux-2.6.32.49/drivers/acpi/osl.c lin= ux-2.6.32.49/drivers/acpi/osl.c if (!value) value =3D &dummy; =20 -@@ -551,6 +553,8 @@ acpi_os_write_memory(acpi_physical_addre +@@ -551,6 +553,8 @@ acpi_os_write_memory(acpi_physical_address phys_addr= , u32 value, u32 width) void __iomem *virt_addr; =20 virt_addr =3D ioremap(phys_addr, width); @@ -26076,10 +27298,11 @@ diff -urNp linux-2.6.32.49/drivers/acpi/osl.c l= inux-2.6.32.49/drivers/acpi/osl.c =20 switch (width) { case 8: -diff -urNp linux-2.6.32.49/drivers/acpi/power_meter.c linux-2.6.32.49/dr= ivers/acpi/power_meter.c ---- linux-2.6.32.49/drivers/acpi/power_meter.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/acpi/power_meter.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -315,8 +315,6 @@ static ssize_t set_trip(struct device *d +diff --git a/drivers/acpi/power_meter.c b/drivers/acpi/power_meter.c +index c216062..eec10d2 100644 +--- a/drivers/acpi/power_meter.c ++++ b/drivers/acpi/power_meter.c +@@ -315,8 +315,6 @@ static ssize_t set_trip(struct device *dev, struct d= evice_attribute *devattr, return res; =20 temp /=3D 1000; @@ -26088,10 +27311,11 @@ diff -urNp linux-2.6.32.49/drivers/acpi/power_m= eter.c linux-2.6.32.49/drivers/ac =20 mutex_lock(&resource->lock); resource->trip[attr->index - 7] =3D temp; -diff -urNp linux-2.6.32.49/drivers/acpi/proc.c linux-2.6.32.49/drivers/a= cpi/proc.c ---- linux-2.6.32.49/drivers/acpi/proc.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/acpi/proc.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -391,20 +391,15 @@ acpi_system_write_wakeup_device(struct f +diff --git a/drivers/acpi/proc.c b/drivers/acpi/proc.c +index d0d25e2..961643d 100644 +--- a/drivers/acpi/proc.c ++++ b/drivers/acpi/proc.c +@@ -391,20 +391,15 @@ acpi_system_write_wakeup_device(struct file *file, size_t count, loff_t * ppos) { struct list_head *node, *next; @@ -26117,7 +27341,7 @@ diff -urNp linux-2.6.32.49/drivers/acpi/proc.c li= nux-2.6.32.49/drivers/acpi/proc =20 mutex_lock(&acpi_device_lock); list_for_each_safe(node, next, &acpi_wakeup_device_list) { -@@ -413,7 +408,7 @@ acpi_system_write_wakeup_device(struct f +@@ -413,7 +408,7 @@ acpi_system_write_wakeup_device(struct file *file, if (!dev->wakeup.flags.valid) continue; =20 @@ -26126,10 +27350,11 @@ diff -urNp linux-2.6.32.49/drivers/acpi/proc.c = linux-2.6.32.49/drivers/acpi/proc dev->wakeup.state.enabled =3D dev->wakeup.state.enabled ? 0 : 1; found_dev =3D dev; -diff -urNp linux-2.6.32.49/drivers/acpi/processor_core.c linux-2.6.32.49= /drivers/acpi/processor_core.c ---- linux-2.6.32.49/drivers/acpi/processor_core.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/acpi/processor_core.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -790,7 +790,7 @@ static int __cpuinit acpi_processor_add( +diff --git a/drivers/acpi/processor_core.c b/drivers/acpi/processor_core= .c +index 7102474..de8ad22 100644 +--- a/drivers/acpi/processor_core.c ++++ b/drivers/acpi/processor_core.c +@@ -790,7 +790,7 @@ static int __cpuinit acpi_processor_add(struct acpi_= device *device) return 0; } =20 @@ -26138,9 +27363,10 @@ diff -urNp linux-2.6.32.49/drivers/acpi/processo= r_core.c linux-2.6.32.49/drivers =20 /* * Buggy BIOS check -diff -urNp linux-2.6.32.49/drivers/acpi/sbshc.c linux-2.6.32.49/drivers/= acpi/sbshc.c ---- linux-2.6.32.49/drivers/acpi/sbshc.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/acpi/sbshc.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/drivers/acpi/sbshc.c b/drivers/acpi/sbshc.c +index d933980..5761f13 100644 +--- a/drivers/acpi/sbshc.c ++++ b/drivers/acpi/sbshc.c @@ -17,7 +17,7 @@ =20 #define PREFIX "ACPI: " @@ -26150,10 +27376,11 @@ diff -urNp linux-2.6.32.49/drivers/acpi/sbshc.c= linux-2.6.32.49/drivers/acpi/sbs #define ACPI_SMB_HC_DEVICE_NAME "ACPI SMBus HC" =20 struct acpi_smb_hc { -diff -urNp linux-2.6.32.49/drivers/acpi/sleep.c linux-2.6.32.49/drivers/= acpi/sleep.c ---- linux-2.6.32.49/drivers/acpi/sleep.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/acpi/sleep.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -283,7 +283,7 @@ static int acpi_suspend_state_valid(susp +diff --git a/drivers/acpi/sleep.c b/drivers/acpi/sleep.c +index 0458094..6978e7b 100644 +--- a/drivers/acpi/sleep.c ++++ b/drivers/acpi/sleep.c +@@ -283,7 +283,7 @@ static int acpi_suspend_state_valid(suspend_state_t = pm_state) } } =20 @@ -26162,7 +27389,7 @@ diff -urNp linux-2.6.32.49/drivers/acpi/sleep.c l= inux-2.6.32.49/drivers/acpi/sle .valid =3D acpi_suspend_state_valid, .begin =3D acpi_suspend_begin, .prepare_late =3D acpi_pm_prepare, -@@ -311,7 +311,7 @@ static int acpi_suspend_begin_old(suspen +@@ -311,7 +311,7 @@ static int acpi_suspend_begin_old(suspend_state_t pm= _state) * The following callbacks are used if the pre-ACPI 2.0 suspend orderin= g has * been requested. */ @@ -26180,7 +27407,7 @@ diff -urNp linux-2.6.32.49/drivers/acpi/sleep.c l= inux-2.6.32.49/drivers/acpi/sle .begin =3D acpi_hibernation_begin, .end =3D acpi_pm_end, .pre_snapshot =3D acpi_hibernation_pre_snapshot, -@@ -513,7 +513,7 @@ static int acpi_hibernation_pre_snapshot +@@ -513,7 +513,7 @@ static int acpi_hibernation_pre_snapshot_old(void) * The following callbacks are used if the pre-ACPI 2.0 suspend orderin= g has * been requested. */ @@ -26189,10 +27416,11 @@ diff -urNp linux-2.6.32.49/drivers/acpi/sleep.c= linux-2.6.32.49/drivers/acpi/sle .begin =3D acpi_hibernation_begin_old, .end =3D acpi_pm_end, .pre_snapshot =3D acpi_hibernation_pre_snapshot_old, -diff -urNp linux-2.6.32.49/drivers/acpi/video.c linux-2.6.32.49/drivers/= acpi/video.c ---- linux-2.6.32.49/drivers/acpi/video.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/acpi/video.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -359,7 +359,7 @@ static int acpi_video_set_brightness(str +diff --git a/drivers/acpi/video.c b/drivers/acpi/video.c +index 05dff63..b662ab7 100644 +--- a/drivers/acpi/video.c ++++ b/drivers/acpi/video.c +@@ -359,7 +359,7 @@ static int acpi_video_set_brightness(struct backligh= t_device *bd) vd->brightness->levels[request_level]); } =20 @@ -26201,10 +27429,11 @@ diff -urNp linux-2.6.32.49/drivers/acpi/video.c= linux-2.6.32.49/drivers/acpi/vid .get_brightness =3D acpi_video_get_brightness, .update_status =3D acpi_video_set_brightness, }; -diff -urNp linux-2.6.32.49/drivers/ata/ahci.c linux-2.6.32.49/drivers/at= a/ahci.c ---- linux-2.6.32.49/drivers/ata/ahci.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/ata/ahci.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -387,7 +387,7 @@ static struct scsi_host_template ahci_sh +diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c +index 6787aab..23ffb0e 100644 +--- a/drivers/ata/ahci.c ++++ b/drivers/ata/ahci.c +@@ -387,7 +387,7 @@ static struct scsi_host_template ahci_sht =3D { .sdev_attrs =3D ahci_sdev_attrs, }; =20 @@ -26213,7 +27442,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/ahci.c lin= ux-2.6.32.49/drivers/ata/ahci.c .inherits =3D &sata_pmp_port_ops, =20 .qc_defer =3D sata_pmp_qc_defer_cmd_switch, -@@ -424,17 +424,17 @@ static struct ata_port_operations ahci_o +@@ -424,17 +424,17 @@ static struct ata_port_operations ahci_ops =3D { .port_stop =3D ahci_port_stop, }; =20 @@ -26234,10 +27463,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/ahci.c l= inux-2.6.32.49/drivers/ata/ahci.c .inherits =3D &ahci_ops, .softreset =3D ahci_sb600_softreset, .pmp_softreset =3D ahci_sb600_softreset, -diff -urNp linux-2.6.32.49/drivers/ata/ata_generic.c linux-2.6.32.49/dri= vers/ata/ata_generic.c ---- linux-2.6.32.49/drivers/ata/ata_generic.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/ata_generic.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -104,7 +104,7 @@ static struct scsi_host_template generic +diff --git a/drivers/ata/ata_generic.c b/drivers/ata/ata_generic.c +index 99e7196..4968c77 100644 +--- a/drivers/ata/ata_generic.c ++++ b/drivers/ata/ata_generic.c +@@ -104,7 +104,7 @@ static struct scsi_host_template generic_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26246,10 +27476,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/ata_gene= ric.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D ata_cable_unknown, .set_mode =3D generic_set_mode, -diff -urNp linux-2.6.32.49/drivers/ata/ata_piix.c linux-2.6.32.49/driver= s/ata/ata_piix.c ---- linux-2.6.32.49/drivers/ata/ata_piix.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/ata_piix.c 2011-11-15 19:59:43.000000000= -0500 -@@ -318,7 +318,7 @@ static struct scsi_host_template piix_sh +diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c +index c33591d..000c121 100644 +--- a/drivers/ata/ata_piix.c ++++ b/drivers/ata/ata_piix.c +@@ -318,7 +318,7 @@ static struct scsi_host_template piix_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26258,7 +27489,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/ata_piix.c= linux-2.6.32.49/drivers/ata/at .inherits =3D &ata_bmdma32_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D piix_set_piomode, -@@ -326,22 +326,22 @@ static struct ata_port_operations piix_p +@@ -326,22 +326,22 @@ static struct ata_port_operations piix_pata_ops =3D= { .prereset =3D piix_pata_prereset, }; =20 @@ -26285,10 +27516,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/ata_piix= .c linux-2.6.32.49/drivers/ata/at .inherits =3D &piix_sata_ops, .hardreset =3D sata_std_hardreset, .scr_read =3D piix_sidpr_scr_read, -diff -urNp linux-2.6.32.49/drivers/ata/libata-acpi.c linux-2.6.32.49/dri= vers/ata/libata-acpi.c ---- linux-2.6.32.49/drivers/ata/libata-acpi.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/libata-acpi.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -223,12 +223,12 @@ static void ata_acpi_dev_uevent(acpi_han +diff --git a/drivers/ata/libata-acpi.c b/drivers/ata/libata-acpi.c +index b0882cd..c295d65 100644 +--- a/drivers/ata/libata-acpi.c ++++ b/drivers/ata/libata-acpi.c +@@ -223,12 +223,12 @@ static void ata_acpi_dev_uevent(acpi_handle handle= , u32 event, void *data) ata_acpi_uevent(dev->link->ap, dev, event); } =20 @@ -26303,10 +27535,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-a= cpi.c linux-2.6.32.49/drivers/ata .handler =3D ata_acpi_ap_notify_dock, .uevent =3D ata_acpi_ap_uevent, }; -diff -urNp linux-2.6.32.49/drivers/ata/libata-core.c linux-2.6.32.49/dri= vers/ata/libata-core.c ---- linux-2.6.32.49/drivers/ata/libata-core.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/libata-core.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -4954,7 +4954,7 @@ void ata_qc_free(struct ata_queued_cmd * +diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c +index d4f7f99..94f603e 100644 +--- a/drivers/ata/libata-core.c ++++ b/drivers/ata/libata-core.c +@@ -4954,7 +4954,7 @@ void ata_qc_free(struct ata_queued_cmd *qc) struct ata_port *ap; unsigned int tag; =20 @@ -26315,7 +27548,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-cor= e.c linux-2.6.32.49/drivers/ata ap =3D qc->ap; =20 qc->flags =3D 0; -@@ -4970,7 +4970,7 @@ void __ata_qc_complete(struct ata_queued +@@ -4970,7 +4970,7 @@ void __ata_qc_complete(struct ata_queued_cmd *qc) struct ata_port *ap; struct ata_link *link; =20 @@ -26324,7 +27557,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-cor= e.c linux-2.6.32.49/drivers/ata WARN_ON_ONCE(!(qc->flags & ATA_QCFLAG_ACTIVE)); ap =3D qc->ap; link =3D qc->dev->link; -@@ -5987,7 +5987,7 @@ static void ata_host_stop(struct device=20 +@@ -5987,7 +5987,7 @@ static void ata_host_stop(struct device *gendev, v= oid *res) * LOCKING: * None. */ @@ -26333,7 +27566,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-cor= e.c linux-2.6.32.49/drivers/ata { static DEFINE_SPINLOCK(lock); const struct ata_port_operations *cur; -@@ -5999,6 +5999,7 @@ static void ata_finalize_port_ops(struct +@@ -5999,6 +5999,7 @@ static void ata_finalize_port_ops(struct ata_port_= operations *ops) return; =20 spin_lock(&lock); @@ -26341,7 +27574,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-cor= e.c linux-2.6.32.49/drivers/ata =20 for (cur =3D ops->inherits; cur; cur =3D cur->inherits) { void **inherit =3D (void **)cur; -@@ -6012,8 +6013,9 @@ static void ata_finalize_port_ops(struct +@@ -6012,8 +6013,9 @@ static void ata_finalize_port_ops(struct ata_port_= operations *ops) if (IS_ERR(*pp)) *pp =3D NULL; =20 @@ -26352,7 +27585,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-cor= e.c linux-2.6.32.49/drivers/ata spin_unlock(&lock); } =20 -@@ -6110,7 +6112,7 @@ int ata_host_start(struct ata_host *host +@@ -6110,7 +6112,7 @@ int ata_host_start(struct ata_host *host) */ /* KILLME - the only user left is ipr */ void ata_host_init(struct ata_host *host, struct device *dev, @@ -26361,7 +27594,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-cor= e.c linux-2.6.32.49/drivers/ata { spin_lock_init(&host->lock); host->dev =3D dev; -@@ -6773,7 +6775,7 @@ static void ata_dummy_error_handler(stru +@@ -6773,7 +6775,7 @@ static void ata_dummy_error_handler(struct ata_por= t *ap) /* truly dummy */ } =20 @@ -26370,9 +27603,10 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-co= re.c linux-2.6.32.49/drivers/ata .qc_prep =3D ata_noop_qc_prep, .qc_issue =3D ata_dummy_qc_issue, .error_handler =3D ata_dummy_error_handler, -diff -urNp linux-2.6.32.49/drivers/ata/libata-eh.c linux-2.6.32.49/drive= rs/ata/libata-eh.c ---- linux-2.6.32.49/drivers/ata/libata-eh.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ata/libata-eh.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c +index e5bdb9b..45a8e72 100644 +--- a/drivers/ata/libata-eh.c ++++ b/drivers/ata/libata-eh.c @@ -2423,6 +2423,8 @@ void ata_eh_report(struct ata_port *ap) { struct ata_link *link; @@ -26382,7 +27616,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-eh.= c linux-2.6.32.49/drivers/ata/l ata_for_each_link(link, ap, HOST_FIRST) ata_eh_link_report(link); } -@@ -3594,7 +3596,7 @@ void ata_do_eh(struct ata_port *ap, ata_ +@@ -3594,7 +3596,7 @@ void ata_do_eh(struct ata_port *ap, ata_prereset_f= n_t prereset, */ void ata_std_error_handler(struct ata_port *ap) { @@ -26391,10 +27625,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-e= h.c linux-2.6.32.49/drivers/ata/l ata_reset_fn_t hardreset =3D ops->hardreset; =20 /* ignore built-in hardreset if SCR access is not available */ -diff -urNp linux-2.6.32.49/drivers/ata/libata-pmp.c linux-2.6.32.49/driv= ers/ata/libata-pmp.c ---- linux-2.6.32.49/drivers/ata/libata-pmp.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ata/libata-pmp.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -841,7 +841,7 @@ static int sata_pmp_handle_link_fail(str +diff --git a/drivers/ata/libata-pmp.c b/drivers/ata/libata-pmp.c +index 51f0ffb..19ce3e3 100644 +--- a/drivers/ata/libata-pmp.c ++++ b/drivers/ata/libata-pmp.c +@@ -841,7 +841,7 @@ static int sata_pmp_handle_link_fail(struct ata_link= *link, int *link_tries) */ static int sata_pmp_eh_recover(struct ata_port *ap) { @@ -26403,10 +27638,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/libata-p= mp.c linux-2.6.32.49/drivers/ata/ int pmp_tries, link_tries[SATA_PMP_MAX_PORTS]; struct ata_link *pmp_link =3D &ap->link; struct ata_device *pmp_dev =3D pmp_link->device; -diff -urNp linux-2.6.32.49/drivers/ata/pata_acpi.c linux-2.6.32.49/drive= rs/ata/pata_acpi.c ---- linux-2.6.32.49/drivers/ata/pata_acpi.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_acpi.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -215,7 +215,7 @@ static struct scsi_host_template pacpi_s +diff --git a/drivers/ata/pata_acpi.c b/drivers/ata/pata_acpi.c +index d8f35fe..288180a 100644 +--- a/drivers/ata/pata_acpi.c ++++ b/drivers/ata/pata_acpi.c +@@ -215,7 +215,7 @@ static struct scsi_host_template pacpi_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26415,10 +27651,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_acp= i.c linux-2.6.32.49/drivers/ata/p .inherits =3D &ata_bmdma_port_ops, .qc_issue =3D pacpi_qc_issue, .cable_detect =3D pacpi_cable_detect, -diff -urNp linux-2.6.32.49/drivers/ata/pata_ali.c linux-2.6.32.49/driver= s/ata/pata_ali.c ---- linux-2.6.32.49/drivers/ata/pata_ali.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_ali.c 2011-11-15 19:59:43.000000000= -0500 -@@ -365,7 +365,7 @@ static struct scsi_host_template ali_sht +diff --git a/drivers/ata/pata_ali.c b/drivers/ata/pata_ali.c +index 9434114..1f2f364 100644 +--- a/drivers/ata/pata_ali.c ++++ b/drivers/ata/pata_ali.c +@@ -365,7 +365,7 @@ static struct scsi_host_template ali_sht =3D { * Port operations for PIO only ALi */ =20 @@ -26427,7 +27664,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ali.c= linux-2.6.32.49/drivers/ata/pa .inherits =3D &ata_sff_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D ali_set_piomode, -@@ -382,7 +382,7 @@ static const struct ata_port_operations=20 +@@ -382,7 +382,7 @@ static const struct ata_port_operations ali_dma_base= _ops =3D { * Port operations for DMA capable ALi without cable * detect */ @@ -26436,7 +27673,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ali.c= linux-2.6.32.49/drivers/ata/pa .inherits =3D &ali_dma_base_ops, .cable_detect =3D ata_cable_40wire, .mode_filter =3D ali_20_filter, -@@ -393,7 +393,7 @@ static struct ata_port_operations ali_20 +@@ -393,7 +393,7 @@ static struct ata_port_operations ali_20_port_ops =3D= { /* * Port operations for DMA capable ALi with cable detect */ @@ -26445,7 +27682,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ali.c= linux-2.6.32.49/drivers/ata/pa .inherits =3D &ali_dma_base_ops, .check_atapi_dma =3D ali_check_atapi_dma, .cable_detect =3D ali_c2_cable_detect, -@@ -404,7 +404,7 @@ static struct ata_port_operations ali_c2 +@@ -404,7 +404,7 @@ static struct ata_port_operations ali_c2_port_ops =3D= { /* * Port operations for DMA capable ALi with cable detect */ @@ -26454,7 +27691,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ali.c= linux-2.6.32.49/drivers/ata/pa .inherits =3D &ali_dma_base_ops, .check_atapi_dma =3D ali_check_atapi_dma, .cable_detect =3D ali_c2_cable_detect, -@@ -414,7 +414,7 @@ static struct ata_port_operations ali_c4 +@@ -414,7 +414,7 @@ static struct ata_port_operations ali_c4_port_ops =3D= { /* * Port operations for DMA capable ALi with cable detect and LBA48 */ @@ -26463,10 +27700,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ali= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &ali_dma_base_ops, .check_atapi_dma =3D ali_check_atapi_dma, .dev_config =3D ali_warn_atapi_dma, -diff -urNp linux-2.6.32.49/drivers/ata/pata_amd.c linux-2.6.32.49/driver= s/ata/pata_amd.c ---- linux-2.6.32.49/drivers/ata/pata_amd.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_amd.c 2011-11-15 19:59:43.000000000= -0500 -@@ -397,28 +397,28 @@ static const struct ata_port_operations=20 +diff --git a/drivers/ata/pata_amd.c b/drivers/ata/pata_amd.c +index 567f3f7..c8ee0da 100644 +--- a/drivers/ata/pata_amd.c ++++ b/drivers/ata/pata_amd.c +@@ -397,28 +397,28 @@ static const struct ata_port_operations amd_base_p= ort_ops =3D { .prereset =3D amd_pre_reset, }; =20 @@ -26499,7 +27737,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_amd.c= linux-2.6.32.49/drivers/ata/pa .inherits =3D &amd_base_port_ops, .cable_detect =3D amd_cable_detect, .set_piomode =3D amd133_set_piomode, -@@ -433,13 +433,13 @@ static const struct ata_port_operations=20 +@@ -433,13 +433,13 @@ static const struct ata_port_operations nv_base_po= rt_ops =3D { .host_stop =3D nv_host_stop, }; =20 @@ -26515,10 +27753,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_amd= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &nv_base_port_ops, .set_piomode =3D nv133_set_piomode, .set_dmamode =3D nv133_set_dmamode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_artop.c linux-2.6.32.49/driv= ers/ata/pata_artop.c ---- linux-2.6.32.49/drivers/ata/pata_artop.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_artop.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -311,7 +311,7 @@ static struct scsi_host_template artop_s +diff --git a/drivers/ata/pata_artop.c b/drivers/ata/pata_artop.c +index d332cfd..4b7eaae 100644 +--- a/drivers/ata/pata_artop.c ++++ b/drivers/ata/pata_artop.c +@@ -311,7 +311,7 @@ static struct scsi_host_template artop_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26527,7 +27766,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_artop= .c linux-2.6.32.49/drivers/ata/ .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D artop6210_set_piomode, -@@ -320,7 +320,7 @@ static struct ata_port_operations artop6 +@@ -320,7 +320,7 @@ static struct ata_port_operations artop6210_ops =3D = { .qc_defer =3D artop6210_qc_defer, }; =20 @@ -26536,10 +27775,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_art= op.c linux-2.6.32.49/drivers/ata/ .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D artop6260_cable_detect, .set_piomode =3D artop6260_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_at32.c linux-2.6.32.49/drive= rs/ata/pata_at32.c ---- linux-2.6.32.49/drivers/ata/pata_at32.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_at32.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -172,7 +172,7 @@ static struct scsi_host_template at32_sh +diff --git a/drivers/ata/pata_at32.c b/drivers/ata/pata_at32.c +index 5c129f9..7bb7ccb 100644 +--- a/drivers/ata/pata_at32.c ++++ b/drivers/ata/pata_at32.c +@@ -172,7 +172,7 @@ static struct scsi_host_template at32_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -26548,10 +27788,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_at3= 2.c linux-2.6.32.49/drivers/ata/p .inherits =3D &ata_sff_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D pata_at32_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_at91.c linux-2.6.32.49/drive= rs/ata/pata_at91.c ---- linux-2.6.32.49/drivers/ata/pata_at91.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_at91.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -195,7 +195,7 @@ static struct scsi_host_template pata_at +diff --git a/drivers/ata/pata_at91.c b/drivers/ata/pata_at91.c +index 41c94b1..829006d 100644 +--- a/drivers/ata/pata_at91.c ++++ b/drivers/ata/pata_at91.c +@@ -195,7 +195,7 @@ static struct scsi_host_template pata_at91_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -26560,10 +27801,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_at9= 1.c linux-2.6.32.49/drivers/ata/p .inherits =3D &ata_sff_port_ops, =20 .sff_data_xfer =3D pata_at91_data_xfer_noirq, -diff -urNp linux-2.6.32.49/drivers/ata/pata_atiixp.c linux-2.6.32.49/dri= vers/ata/pata_atiixp.c ---- linux-2.6.32.49/drivers/ata/pata_atiixp.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_atiixp.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -205,7 +205,7 @@ static struct scsi_host_template atiixp_ +diff --git a/drivers/ata/pata_atiixp.c b/drivers/ata/pata_atiixp.c +index ae4454d..d391eb4 100644 +--- a/drivers/ata/pata_atiixp.c ++++ b/drivers/ata/pata_atiixp.c +@@ -205,7 +205,7 @@ static struct scsi_host_template atiixp_sht =3D { .sg_tablesize =3D LIBATA_DUMB_MAX_PRD, }; =20 @@ -26572,10 +27814,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ati= ixp.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, =20 .qc_prep =3D ata_sff_dumb_qc_prep, -diff -urNp linux-2.6.32.49/drivers/ata/pata_atp867x.c linux-2.6.32.49/dr= ivers/ata/pata_atp867x.c ---- linux-2.6.32.49/drivers/ata/pata_atp867x.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_atp867x.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -274,7 +274,7 @@ static struct scsi_host_template atp867x +diff --git a/drivers/ata/pata_atp867x.c b/drivers/ata/pata_atp867x.c +index 6fe7ded..2a425dc 100644 +--- a/drivers/ata/pata_atp867x.c ++++ b/drivers/ata/pata_atp867x.c +@@ -274,7 +274,7 @@ static struct scsi_host_template atp867x_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26584,10 +27827,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_atp= 867x.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D atp867x_cable_detect, .set_piomode =3D atp867x_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_bf54x.c linux-2.6.32.49/driv= ers/ata/pata_bf54x.c ---- linux-2.6.32.49/drivers/ata/pata_bf54x.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_bf54x.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -1464,7 +1464,7 @@ static struct scsi_host_template bfin_sh +diff --git a/drivers/ata/pata_bf54x.c b/drivers/ata/pata_bf54x.c +index c4b47a3..b27a367 100644 +--- a/drivers/ata/pata_bf54x.c ++++ b/drivers/ata/pata_bf54x.c +@@ -1464,7 +1464,7 @@ static struct scsi_host_template bfin_sht =3D { .dma_boundary =3D ATA_DMA_BOUNDARY, }; =20 @@ -26596,10 +27840,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_bf5= 4x.c linux-2.6.32.49/drivers/ata/ .inherits =3D &ata_sff_port_ops, =20 .set_piomode =3D bfin_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_cmd640.c linux-2.6.32.49/dri= vers/ata/pata_cmd640.c ---- linux-2.6.32.49/drivers/ata/pata_cmd640.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_cmd640.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -168,7 +168,7 @@ static struct scsi_host_template cmd640_ +diff --git a/drivers/ata/pata_cmd640.c b/drivers/ata/pata_cmd640.c +index 5acf9fa..84248be 100644 +--- a/drivers/ata/pata_cmd640.c ++++ b/drivers/ata/pata_cmd640.c +@@ -168,7 +168,7 @@ static struct scsi_host_template cmd640_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26608,10 +27853,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_cmd= 640.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, /* In theory xfer_noirq is not needed once we kill the prefetcher */ .sff_data_xfer =3D ata_sff_data_xfer_noirq, -diff -urNp linux-2.6.32.49/drivers/ata/pata_cmd64x.c linux-2.6.32.49/dri= vers/ata/pata_cmd64x.c ---- linux-2.6.32.49/drivers/ata/pata_cmd64x.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_cmd64x.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -271,18 +271,18 @@ static const struct ata_port_operations=20 +diff --git a/drivers/ata/pata_cmd64x.c b/drivers/ata/pata_cmd64x.c +index ccd2694..c869c3d 100644 +--- a/drivers/ata/pata_cmd64x.c ++++ b/drivers/ata/pata_cmd64x.c +@@ -271,18 +271,18 @@ static const struct ata_port_operations cmd64x_bas= e_ops =3D { .set_dmamode =3D cmd64x_set_dmamode, }; =20 @@ -26633,10 +27879,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_cmd= 64x.c linux-2.6.32.49/drivers/ata .inherits =3D &cmd64x_base_ops, .bmdma_stop =3D cmd648_bmdma_stop, .cable_detect =3D cmd648_cable_detect, -diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5520.c linux-2.6.32.49/dri= vers/ata/pata_cs5520.c ---- linux-2.6.32.49/drivers/ata/pata_cs5520.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_cs5520.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -144,7 +144,7 @@ static struct scsi_host_template cs5520_ +diff --git a/drivers/ata/pata_cs5520.c b/drivers/ata/pata_cs5520.c +index 0df83cf..d7595b0 100644 +--- a/drivers/ata/pata_cs5520.c ++++ b/drivers/ata/pata_cs5520.c +@@ -144,7 +144,7 @@ static struct scsi_host_template cs5520_sht =3D { .sg_tablesize =3D LIBATA_DUMB_MAX_PRD, }; =20 @@ -26645,10 +27892,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5= 520.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .qc_prep =3D ata_sff_dumb_qc_prep, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5530.c linux-2.6.32.49/dri= vers/ata/pata_cs5530.c ---- linux-2.6.32.49/drivers/ata/pata_cs5530.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_cs5530.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -164,7 +164,7 @@ static struct scsi_host_template cs5530_ +diff --git a/drivers/ata/pata_cs5530.c b/drivers/ata/pata_cs5530.c +index c974b05..6d26b11 100644 +--- a/drivers/ata/pata_cs5530.c ++++ b/drivers/ata/pata_cs5530.c +@@ -164,7 +164,7 @@ static struct scsi_host_template cs5530_sht =3D { .sg_tablesize =3D LIBATA_DUMB_MAX_PRD, }; =20 @@ -26657,10 +27905,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5= 530.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, =20 .qc_prep =3D ata_sff_dumb_qc_prep, -diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5535.c linux-2.6.32.49/dri= vers/ata/pata_cs5535.c ---- linux-2.6.32.49/drivers/ata/pata_cs5535.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_cs5535.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -160,7 +160,7 @@ static struct scsi_host_template cs5535_ +diff --git a/drivers/ata/pata_cs5535.c b/drivers/ata/pata_cs5535.c +index 403f561..aacd26b 100644 +--- a/drivers/ata/pata_cs5535.c ++++ b/drivers/ata/pata_cs5535.c +@@ -160,7 +160,7 @@ static struct scsi_host_template cs5535_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26669,10 +27918,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5= 535.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D cs5535_cable_detect, .set_piomode =3D cs5535_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5536.c linux-2.6.32.49/dri= vers/ata/pata_cs5536.c ---- linux-2.6.32.49/drivers/ata/pata_cs5536.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_cs5536.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -223,7 +223,7 @@ static struct scsi_host_template cs5536_ +diff --git a/drivers/ata/pata_cs5536.c b/drivers/ata/pata_cs5536.c +index 6da4cb4..de24a25 100644 +--- a/drivers/ata/pata_cs5536.c ++++ b/drivers/ata/pata_cs5536.c +@@ -223,7 +223,7 @@ static struct scsi_host_template cs5536_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26681,10 +27931,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_cs5= 536.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D cs5536_cable_detect, .set_piomode =3D cs5536_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_cypress.c linux-2.6.32.49/dr= ivers/ata/pata_cypress.c ---- linux-2.6.32.49/drivers/ata/pata_cypress.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_cypress.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -113,7 +113,7 @@ static struct scsi_host_template cy82c69 +diff --git a/drivers/ata/pata_cypress.c b/drivers/ata/pata_cypress.c +index 8fb040b..b16a9c9 100644 +--- a/drivers/ata/pata_cypress.c ++++ b/drivers/ata/pata_cypress.c +@@ -113,7 +113,7 @@ static struct scsi_host_template cy82c693_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26693,10 +27944,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_cyp= ress.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D cy82c693_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_efar.c linux-2.6.32.49/drive= rs/ata/pata_efar.c ---- linux-2.6.32.49/drivers/ata/pata_efar.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_efar.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -222,7 +222,7 @@ static struct scsi_host_template efar_sh +diff --git a/drivers/ata/pata_efar.c b/drivers/ata/pata_efar.c +index 2a6412f..555ee11 100644 +--- a/drivers/ata/pata_efar.c ++++ b/drivers/ata/pata_efar.c +@@ -222,7 +222,7 @@ static struct scsi_host_template efar_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26705,10 +27957,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_efa= r.c linux-2.6.32.49/drivers/ata/p .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D efar_cable_detect, .set_piomode =3D efar_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt366.c linux-2.6.32.49/dri= vers/ata/pata_hpt366.c ---- linux-2.6.32.49/drivers/ata/pata_hpt366.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_hpt366.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -282,7 +282,7 @@ static struct scsi_host_template hpt36x_ +diff --git a/drivers/ata/pata_hpt366.c b/drivers/ata/pata_hpt366.c +index b9d8836..0b92030 100644 +--- a/drivers/ata/pata_hpt366.c ++++ b/drivers/ata/pata_hpt366.c +@@ -282,7 +282,7 @@ static struct scsi_host_template hpt36x_sht =3D { * Configuration for HPT366/68 */ =20 @@ -26717,10 +27970,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt= 366.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D hpt36x_cable_detect, .mode_filter =3D hpt366_filter, -diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt37x.c linux-2.6.32.49/dri= vers/ata/pata_hpt37x.c ---- linux-2.6.32.49/drivers/ata/pata_hpt37x.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_hpt37x.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -576,7 +576,7 @@ static struct scsi_host_template hpt37x_ +diff --git a/drivers/ata/pata_hpt37x.c b/drivers/ata/pata_hpt37x.c +index 5af7f19..00c4980 100644 +--- a/drivers/ata/pata_hpt37x.c ++++ b/drivers/ata/pata_hpt37x.c +@@ -576,7 +576,7 @@ static struct scsi_host_template hpt37x_sht =3D { * Configuration for HPT370 */ =20 @@ -26729,7 +27983,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt37= x.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, =20 .bmdma_stop =3D hpt370_bmdma_stop, -@@ -591,7 +591,7 @@ static struct ata_port_operations hpt370 +@@ -591,7 +591,7 @@ static struct ata_port_operations hpt370_port_ops =3D= { * Configuration for HPT370A. Close to 370 but less filters */ =20 @@ -26738,7 +27992,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt37= x.c linux-2.6.32.49/drivers/ata .inherits =3D &hpt370_port_ops, .mode_filter =3D hpt370a_filter, }; -@@ -601,7 +601,7 @@ static struct ata_port_operations hpt370 +@@ -601,7 +601,7 @@ static struct ata_port_operations hpt370a_port_ops =3D= { * and DMA mode setting functionality. */ =20 @@ -26747,7 +28001,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt37= x.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, =20 .bmdma_stop =3D hpt37x_bmdma_stop, -@@ -616,7 +616,7 @@ static struct ata_port_operations hpt372 +@@ -616,7 +616,7 @@ static struct ata_port_operations hpt372_port_ops =3D= { * but we have a different cable detection procedure for function 1. */ =20 @@ -26756,10 +28010,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt= 37x.c linux-2.6.32.49/drivers/ata .inherits =3D &hpt372_port_ops, .prereset =3D hpt374_fn1_pre_reset, }; -diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt3x2n.c linux-2.6.32.49/dr= ivers/ata/pata_hpt3x2n.c ---- linux-2.6.32.49/drivers/ata/pata_hpt3x2n.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_hpt3x2n.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -337,7 +337,7 @@ static struct scsi_host_template hpt3x2n +diff --git a/drivers/ata/pata_hpt3x2n.c b/drivers/ata/pata_hpt3x2n.c +index 100f227..2e39382 100644 +--- a/drivers/ata/pata_hpt3x2n.c ++++ b/drivers/ata/pata_hpt3x2n.c +@@ -337,7 +337,7 @@ static struct scsi_host_template hpt3x2n_sht =3D { * Configuration for HPT3x2n. */ =20 @@ -26768,10 +28023,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt= 3x2n.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, =20 .bmdma_stop =3D hpt3x2n_bmdma_stop, -diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt3x3.c linux-2.6.32.49/dri= vers/ata/pata_hpt3x3.c ---- linux-2.6.32.49/drivers/ata/pata_hpt3x3.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_hpt3x3.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -141,7 +141,7 @@ static struct scsi_host_template hpt3x3_ +diff --git a/drivers/ata/pata_hpt3x3.c b/drivers/ata/pata_hpt3x3.c +index 7e31025..6fca8f4 100644 +--- a/drivers/ata/pata_hpt3x3.c ++++ b/drivers/ata/pata_hpt3x3.c +@@ -141,7 +141,7 @@ static struct scsi_host_template hpt3x3_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26780,10 +28036,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_hpt= 3x3.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D hpt3x3_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_icside.c linux-2.6.32.49/dri= vers/ata/pata_icside.c ---- linux-2.6.32.49/drivers/ata/pata_icside.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_icside.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -319,7 +319,7 @@ static void pata_icside_postreset(struct +diff --git a/drivers/ata/pata_icside.c b/drivers/ata/pata_icside.c +index b663b7f..9a26c2a 100644 +--- a/drivers/ata/pata_icside.c ++++ b/drivers/ata/pata_icside.c +@@ -319,7 +319,7 @@ static void pata_icside_postreset(struct ata_link *l= ink, unsigned int *classes) } } =20 @@ -26792,10 +28049,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ics= ide.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_sff_port_ops, /* no need to build any PRD tables for DMA */ .qc_prep =3D ata_noop_qc_prep, -diff -urNp linux-2.6.32.49/drivers/ata/pata_isapnp.c linux-2.6.32.49/dri= vers/ata/pata_isapnp.c ---- linux-2.6.32.49/drivers/ata/pata_isapnp.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_isapnp.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -23,12 +23,12 @@ static struct scsi_host_template isapnp_ +diff --git a/drivers/ata/pata_isapnp.c b/drivers/ata/pata_isapnp.c +index 4bceb88..457dfb6 100644 +--- a/drivers/ata/pata_isapnp.c ++++ b/drivers/ata/pata_isapnp.c +@@ -23,12 +23,12 @@ static struct scsi_host_template isapnp_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -26810,10 +28068,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_isa= pnp.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_sff_port_ops, .cable_detect =3D ata_cable_40wire, /* No altstatus so we don't want to use the lost interrupt poll */ -diff -urNp linux-2.6.32.49/drivers/ata/pata_it8213.c linux-2.6.32.49/dri= vers/ata/pata_it8213.c ---- linux-2.6.32.49/drivers/ata/pata_it8213.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_it8213.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -234,7 +234,7 @@ static struct scsi_host_template it8213_ +diff --git a/drivers/ata/pata_it8213.c b/drivers/ata/pata_it8213.c +index f156da8..24976e2 100644 +--- a/drivers/ata/pata_it8213.c ++++ b/drivers/ata/pata_it8213.c +@@ -234,7 +234,7 @@ static struct scsi_host_template it8213_sht =3D { }; =20 =20 @@ -26822,10 +28081,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_it8= 213.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D it8213_cable_detect, .set_piomode =3D it8213_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_it821x.c linux-2.6.32.49/dri= vers/ata/pata_it821x.c ---- linux-2.6.32.49/drivers/ata/pata_it821x.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_it821x.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -800,7 +800,7 @@ static struct scsi_host_template it821x_ +diff --git a/drivers/ata/pata_it821x.c b/drivers/ata/pata_it821x.c +index 188bc2f..ca9e785 100644 +--- a/drivers/ata/pata_it821x.c ++++ b/drivers/ata/pata_it821x.c +@@ -800,7 +800,7 @@ static struct scsi_host_template it821x_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26834,7 +28094,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_it821= x.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, =20 .check_atapi_dma=3D it821x_check_atapi_dma, -@@ -814,7 +814,7 @@ static struct ata_port_operations it821x +@@ -814,7 +814,7 @@ static struct ata_port_operations it821x_smart_port_= ops =3D { .port_start =3D it821x_port_start, }; =20 @@ -26843,7 +28103,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_it821= x.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, =20 .check_atapi_dma=3D it821x_check_atapi_dma, -@@ -830,7 +830,7 @@ static struct ata_port_operations it821x +@@ -830,7 +830,7 @@ static struct ata_port_operations it821x_passthru_po= rt_ops =3D { .port_start =3D it821x_port_start, }; =20 @@ -26852,10 +28112,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_it8= 21x.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, =20 .check_atapi_dma=3D it821x_check_atapi_dma, -diff -urNp linux-2.6.32.49/drivers/ata/pata_ixp4xx_cf.c linux-2.6.32.49/= drivers/ata/pata_ixp4xx_cf.c ---- linux-2.6.32.49/drivers/ata/pata_ixp4xx_cf.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_ixp4xx_cf.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -89,7 +89,7 @@ static struct scsi_host_template ixp4xx_ +diff --git a/drivers/ata/pata_ixp4xx_cf.c b/drivers/ata/pata_ixp4xx_cf.c +index ba54b08..4b952b7 100644 +--- a/drivers/ata/pata_ixp4xx_cf.c ++++ b/drivers/ata/pata_ixp4xx_cf.c +@@ -89,7 +89,7 @@ static struct scsi_host_template ixp4xx_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -26864,10 +28125,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ixp= 4xx_cf.c linux-2.6.32.49/drivers/ .inherits =3D &ata_sff_port_ops, .sff_data_xfer =3D ixp4xx_mmio_data_xfer, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pata_jmicron.c linux-2.6.32.49/dr= ivers/ata/pata_jmicron.c ---- linux-2.6.32.49/drivers/ata/pata_jmicron.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_jmicron.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -111,7 +111,7 @@ static struct scsi_host_template jmicron +diff --git a/drivers/ata/pata_jmicron.c b/drivers/ata/pata_jmicron.c +index 3a1474a..434b0ff 100644 +--- a/drivers/ata/pata_jmicron.c ++++ b/drivers/ata/pata_jmicron.c +@@ -111,7 +111,7 @@ static struct scsi_host_template jmicron_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -26876,9 +28138,10 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_jmic= ron.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .prereset =3D jmicron_pre_reset, }; -diff -urNp linux-2.6.32.49/drivers/ata/pata_legacy.c linux-2.6.32.49/dri= vers/ata/pata_legacy.c ---- linux-2.6.32.49/drivers/ata/pata_legacy.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_legacy.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/ata/pata_legacy.c b/drivers/ata/pata_legacy.c +index 6932e56..220e71d 100644 +--- a/drivers/ata/pata_legacy.c ++++ b/drivers/ata/pata_legacy.c @@ -106,7 +106,7 @@ struct legacy_probe { =20 struct legacy_controller { @@ -26888,7 +28151,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata unsigned int pio_mask; unsigned int flags; unsigned int pflags; -@@ -223,12 +223,12 @@ static const struct ata_port_operations=20 +@@ -223,12 +223,12 @@ static const struct ata_port_operations legacy_bas= e_port_ops =3D { * pio_mask as well. */ =20 @@ -26903,7 +28166,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .sff_data_xfer =3D ata_sff_data_xfer_noirq, .set_mode =3D legacy_set_mode, -@@ -324,7 +324,7 @@ static unsigned int pdc_data_xfer_vlb(st +@@ -324,7 +324,7 @@ static unsigned int pdc_data_xfer_vlb(struct ata_dev= ice *dev, return buflen; } =20 @@ -26912,7 +28175,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .set_piomode =3D pdc20230_set_piomode, .sff_data_xfer =3D pdc_data_xfer_vlb, -@@ -357,7 +357,7 @@ static void ht6560a_set_piomode(struct a +@@ -357,7 +357,7 @@ static void ht6560a_set_piomode(struct ata_port *ap,= struct ata_device *adev) ioread8(ap->ioaddr.status_addr); } =20 @@ -26921,7 +28184,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .set_piomode =3D ht6560a_set_piomode, }; -@@ -400,7 +400,7 @@ static void ht6560b_set_piomode(struct a +@@ -400,7 +400,7 @@ static void ht6560b_set_piomode(struct ata_port *ap,= struct ata_device *adev) ioread8(ap->ioaddr.status_addr); } =20 @@ -26930,7 +28193,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .set_piomode =3D ht6560b_set_piomode, }; -@@ -499,7 +499,7 @@ static void opti82c611a_set_piomode(stru +@@ -499,7 +499,7 @@ static void opti82c611a_set_piomode(struct ata_port = *ap, } =20 =20 @@ -26939,7 +28202,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .set_piomode =3D opti82c611a_set_piomode, }; -@@ -609,7 +609,7 @@ static unsigned int opti82c46x_qc_issue( +@@ -609,7 +609,7 @@ static unsigned int opti82c46x_qc_issue(struct ata_q= ueued_cmd *qc) return ata_sff_qc_issue(qc); } =20 @@ -26948,7 +28211,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .set_piomode =3D opti82c46x_set_piomode, .qc_issue =3D opti82c46x_qc_issue, -@@ -771,20 +771,20 @@ static int qdi_port(struct platform_devi +@@ -771,20 +771,20 @@ static int qdi_port(struct platform_device *dev, return 0; } =20 @@ -26972,7 +28235,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .set_piomode =3D qdi6580dp_set_piomode, .sff_data_xfer =3D vlb32_data_xfer, -@@ -855,7 +855,7 @@ static int winbond_port(struct platform_ +@@ -855,7 +855,7 @@ static int winbond_port(struct platform_device *dev, return 0; } =20 @@ -26981,7 +28244,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_legac= y.c linux-2.6.32.49/drivers/ata .inherits =3D &legacy_base_port_ops, .set_piomode =3D winbond_set_piomode, .sff_data_xfer =3D vlb32_data_xfer, -@@ -978,7 +978,7 @@ static __init int legacy_init_one(struct +@@ -978,7 +978,7 @@ static __init int legacy_init_one(struct legacy_prob= e *probe) int pio_modes =3D controller->pio_mask; unsigned long io =3D probe->port; u32 mask =3D (1 << probe->slot); @@ -26990,10 +28253,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_leg= acy.c linux-2.6.32.49/drivers/ata struct legacy_data *ld =3D &legacy_data[probe->slot]; struct ata_host *host =3D NULL; struct ata_port *ap; -diff -urNp linux-2.6.32.49/drivers/ata/pata_marvell.c linux-2.6.32.49/dr= ivers/ata/pata_marvell.c ---- linux-2.6.32.49/drivers/ata/pata_marvell.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_marvell.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -100,7 +100,7 @@ static struct scsi_host_template marvell +diff --git a/drivers/ata/pata_marvell.c b/drivers/ata/pata_marvell.c +index 2096fb7..4d090fc 100644 +--- a/drivers/ata/pata_marvell.c ++++ b/drivers/ata/pata_marvell.c +@@ -100,7 +100,7 @@ static struct scsi_host_template marvell_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27002,10 +28266,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_mar= vell.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D marvell_cable_detect, .prereset =3D marvell_pre_reset, -diff -urNp linux-2.6.32.49/drivers/ata/pata_mpc52xx.c linux-2.6.32.49/dr= ivers/ata/pata_mpc52xx.c ---- linux-2.6.32.49/drivers/ata/pata_mpc52xx.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_mpc52xx.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -609,7 +609,7 @@ static struct scsi_host_template mpc52xx +diff --git a/drivers/ata/pata_mpc52xx.c b/drivers/ata/pata_mpc52xx.c +index 99d41be..7d56aa8 100644 +--- a/drivers/ata/pata_mpc52xx.c ++++ b/drivers/ata/pata_mpc52xx.c +@@ -609,7 +609,7 @@ static struct scsi_host_template mpc52xx_ata_sht =3D= { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27014,10 +28279,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_mpc= 52xx.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .sff_dev_select =3D mpc52xx_ata_dev_select, .set_piomode =3D mpc52xx_ata_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_mpiix.c linux-2.6.32.49/driv= ers/ata/pata_mpiix.c ---- linux-2.6.32.49/drivers/ata/pata_mpiix.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_mpiix.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -140,7 +140,7 @@ static struct scsi_host_template mpiix_s +diff --git a/drivers/ata/pata_mpiix.c b/drivers/ata/pata_mpiix.c +index b21f002..0a27e7f 100644 +--- a/drivers/ata/pata_mpiix.c ++++ b/drivers/ata/pata_mpiix.c +@@ -140,7 +140,7 @@ static struct scsi_host_template mpiix_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27026,10 +28292,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_mpi= ix.c linux-2.6.32.49/drivers/ata/ .inherits =3D &ata_sff_port_ops, .qc_issue =3D mpiix_qc_issue, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pata_netcell.c linux-2.6.32.49/dr= ivers/ata/pata_netcell.c ---- linux-2.6.32.49/drivers/ata/pata_netcell.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_netcell.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -34,7 +34,7 @@ static struct scsi_host_template netcell +diff --git a/drivers/ata/pata_netcell.c b/drivers/ata/pata_netcell.c +index f0d52f7..89c3be3 100644 +--- a/drivers/ata/pata_netcell.c ++++ b/drivers/ata/pata_netcell.c +@@ -34,7 +34,7 @@ static struct scsi_host_template netcell_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27038,10 +28305,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_net= cell.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D ata_cable_80wire, .read_id =3D netcell_read_id, -diff -urNp linux-2.6.32.49/drivers/ata/pata_ninja32.c linux-2.6.32.49/dr= ivers/ata/pata_ninja32.c ---- linux-2.6.32.49/drivers/ata/pata_ninja32.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_ninja32.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -81,7 +81,7 @@ static struct scsi_host_template ninja32 +diff --git a/drivers/ata/pata_ninja32.c b/drivers/ata/pata_ninja32.c +index dd53a66..a3f4317 100644 +--- a/drivers/ata/pata_ninja32.c ++++ b/drivers/ata/pata_ninja32.c +@@ -81,7 +81,7 @@ static struct scsi_host_template ninja32_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27050,10 +28318,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_nin= ja32.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .sff_dev_select =3D ninja32_dev_select, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pata_ns87410.c linux-2.6.32.49/dr= ivers/ata/pata_ns87410.c ---- linux-2.6.32.49/drivers/ata/pata_ns87410.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_ns87410.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -132,7 +132,7 @@ static struct scsi_host_template ns87410 +diff --git a/drivers/ata/pata_ns87410.c b/drivers/ata/pata_ns87410.c +index ca53fac..9aa93ef 100644 +--- a/drivers/ata/pata_ns87410.c ++++ b/drivers/ata/pata_ns87410.c +@@ -132,7 +132,7 @@ static struct scsi_host_template ns87410_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27062,10 +28331,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ns8= 7410.c linux-2.6.32.49/drivers/at .inherits =3D &ata_sff_port_ops, .qc_issue =3D ns87410_qc_issue, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pata_ns87415.c linux-2.6.32.49/dr= ivers/ata/pata_ns87415.c ---- linux-2.6.32.49/drivers/ata/pata_ns87415.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_ns87415.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -299,7 +299,7 @@ static u8 ns87560_bmdma_status(struct at +diff --git a/drivers/ata/pata_ns87415.c b/drivers/ata/pata_ns87415.c +index 773b159..55f454e 100644 +--- a/drivers/ata/pata_ns87415.c ++++ b/drivers/ata/pata_ns87415.c +@@ -299,7 +299,7 @@ static u8 ns87560_bmdma_status(struct ata_port *ap) } #endif /* 87560 SuperIO Support */ =20 @@ -27074,7 +28344,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ns874= 15.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, =20 .check_atapi_dma =3D ns87415_check_atapi_dma, -@@ -313,7 +313,7 @@ static struct ata_port_operations ns8741 +@@ -313,7 +313,7 @@ static struct ata_port_operations ns87415_pata_ops =3D= { }; =20 #if defined(CONFIG_SUPERIO) @@ -27083,10 +28353,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ns8= 7415.c linux-2.6.32.49/drivers/at .inherits =3D &ns87415_pata_ops, .sff_tf_read =3D ns87560_tf_read, .sff_check_status =3D ns87560_check_status, -diff -urNp linux-2.6.32.49/drivers/ata/pata_octeon_cf.c linux-2.6.32.49/= drivers/ata/pata_octeon_cf.c ---- linux-2.6.32.49/drivers/ata/pata_octeon_cf.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_octeon_cf.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -801,6 +801,7 @@ static unsigned int octeon_cf_qc_issue(s +diff --git a/drivers/ata/pata_octeon_cf.c b/drivers/ata/pata_octeon_cf.c +index d6f6956..639295b 100644 +--- a/drivers/ata/pata_octeon_cf.c ++++ b/drivers/ata/pata_octeon_cf.c +@@ -801,6 +801,7 @@ static unsigned int octeon_cf_qc_issue(struct ata_qu= eued_cmd *qc) return 0; } =20 @@ -27094,10 +28365,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_oct= eon_cf.c linux-2.6.32.49/drivers/ static struct ata_port_operations octeon_cf_ops =3D { .inherits =3D &ata_sff_port_ops, .check_atapi_dma =3D octeon_cf_check_atapi_dma, -diff -urNp linux-2.6.32.49/drivers/ata/pata_oldpiix.c linux-2.6.32.49/dr= ivers/ata/pata_oldpiix.c ---- linux-2.6.32.49/drivers/ata/pata_oldpiix.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_oldpiix.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -208,7 +208,7 @@ static struct scsi_host_template oldpiix +diff --git a/drivers/ata/pata_oldpiix.c b/drivers/ata/pata_oldpiix.c +index 84ac503..adee1cd 100644 +--- a/drivers/ata/pata_oldpiix.c ++++ b/drivers/ata/pata_oldpiix.c +@@ -208,7 +208,7 @@ static struct scsi_host_template oldpiix_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27106,10 +28378,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_old= piix.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .qc_issue =3D oldpiix_qc_issue, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pata_opti.c linux-2.6.32.49/drive= rs/ata/pata_opti.c ---- linux-2.6.32.49/drivers/ata/pata_opti.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_opti.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -152,7 +152,7 @@ static struct scsi_host_template opti_sh +diff --git a/drivers/ata/pata_opti.c b/drivers/ata/pata_opti.c +index 99eddda..3a4c0aa 100644 +--- a/drivers/ata/pata_opti.c ++++ b/drivers/ata/pata_opti.c +@@ -152,7 +152,7 @@ static struct scsi_host_template opti_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27118,10 +28391,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_opt= i.c linux-2.6.32.49/drivers/ata/p .inherits =3D &ata_sff_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D opti_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_optidma.c linux-2.6.32.49/dr= ivers/ata/pata_optidma.c ---- linux-2.6.32.49/drivers/ata/pata_optidma.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_optidma.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -337,7 +337,7 @@ static struct scsi_host_template optidma +diff --git a/drivers/ata/pata_optidma.c b/drivers/ata/pata_optidma.c +index 86885a4..8e9968d 100644 +--- a/drivers/ata/pata_optidma.c ++++ b/drivers/ata/pata_optidma.c +@@ -337,7 +337,7 @@ static struct scsi_host_template optidma_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27130,7 +28404,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_optid= ma.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D ata_cable_40wire, .set_piomode =3D optidma_set_pio_mode, -@@ -346,7 +346,7 @@ static struct ata_port_operations optidm +@@ -346,7 +346,7 @@ static struct ata_port_operations optidma_port_ops =3D= { .prereset =3D optidma_pre_reset, }; =20 @@ -27139,10 +28413,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_opt= idma.c linux-2.6.32.49/drivers/at .inherits =3D &optidma_port_ops, .set_piomode =3D optiplus_set_pio_mode, .set_dmamode =3D optiplus_set_dma_mode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_palmld.c linux-2.6.32.49/dri= vers/ata/pata_palmld.c ---- linux-2.6.32.49/drivers/ata/pata_palmld.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_palmld.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -37,7 +37,7 @@ static struct scsi_host_template palmld_ +diff --git a/drivers/ata/pata_palmld.c b/drivers/ata/pata_palmld.c +index 11fb4cc..1a14022 100644 +--- a/drivers/ata/pata_palmld.c ++++ b/drivers/ata/pata_palmld.c +@@ -37,7 +37,7 @@ static struct scsi_host_template palmld_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27151,10 +28426,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_pal= mld.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_sff_port_ops, .sff_data_xfer =3D ata_sff_data_xfer_noirq, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pata_pcmcia.c linux-2.6.32.49/dri= vers/ata/pata_pcmcia.c ---- linux-2.6.32.49/drivers/ata/pata_pcmcia.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_pcmcia.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -162,14 +162,14 @@ static struct scsi_host_template pcmcia_ +diff --git a/drivers/ata/pata_pcmcia.c b/drivers/ata/pata_pcmcia.c +index dc99e26..7f4b1e4 100644 +--- a/drivers/ata/pata_pcmcia.c ++++ b/drivers/ata/pata_pcmcia.c +@@ -162,14 +162,14 @@ static struct scsi_host_template pcmcia_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27171,7 +28447,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_pcmci= a.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_sff_port_ops, .sff_data_xfer =3D ata_data_xfer_8bit, .cable_detect =3D ata_cable_40wire, -@@ -256,7 +256,7 @@ static int pcmcia_init_one(struct pcmcia +@@ -256,7 +256,7 @@ static int pcmcia_init_one(struct pcmcia_device *pde= v) unsigned long io_base, ctl_base; void __iomem *io_addr, *ctl_addr; int n_ports =3D 1; @@ -27180,10 +28456,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_pcm= cia.c linux-2.6.32.49/drivers/ata =20 info =3D kzalloc(sizeof(*info), GFP_KERNEL); if (info =3D=3D NULL) -diff -urNp linux-2.6.32.49/drivers/ata/pata_pdc2027x.c linux-2.6.32.49/d= rivers/ata/pata_pdc2027x.c ---- linux-2.6.32.49/drivers/ata/pata_pdc2027x.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_pdc2027x.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -132,14 +132,14 @@ static struct scsi_host_template pdc2027 +diff --git a/drivers/ata/pata_pdc2027x.c b/drivers/ata/pata_pdc2027x.c +index ca5cad0..3a1f125 100644 +--- a/drivers/ata/pata_pdc2027x.c ++++ b/drivers/ata/pata_pdc2027x.c +@@ -132,14 +132,14 @@ static struct scsi_host_template pdc2027x_sht =3D = { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27200,10 +28477,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_pdc= 2027x.c linux-2.6.32.49/drivers/a .inherits =3D &pdc2027x_pata100_ops, .mode_filter =3D pdc2027x_mode_filter, .set_piomode =3D pdc2027x_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_pdc202xx_old.c linux-2.6.32.= 49/drivers/ata/pata_pdc202xx_old.c ---- linux-2.6.32.49/drivers/ata/pata_pdc202xx_old.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_pdc202xx_old.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -274,7 +274,7 @@ static struct scsi_host_template pdc202x +diff --git a/drivers/ata/pata_pdc202xx_old.c b/drivers/ata/pata_pdc202xx= _old.c +index 2911120..4bf62aa 100644 +--- a/drivers/ata/pata_pdc202xx_old.c ++++ b/drivers/ata/pata_pdc202xx_old.c +@@ -274,7 +274,7 @@ static struct scsi_host_template pdc202xx_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27212,7 +28490,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_pdc20= 2xx_old.c linux-2.6.32.49/drive .inherits =3D &ata_bmdma_port_ops, =20 .cable_detect =3D ata_cable_40wire, -@@ -284,7 +284,7 @@ static struct ata_port_operations pdc202 +@@ -284,7 +284,7 @@ static struct ata_port_operations pdc2024x_port_ops = =3D { .sff_exec_command =3D pdc202xx_exec_command, }; =20 @@ -27221,10 +28499,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_pdc= 202xx_old.c linux-2.6.32.49/drive .inherits =3D &pdc2024x_port_ops, =20 .check_atapi_dma =3D pdc2026x_check_atapi_dma, -diff -urNp linux-2.6.32.49/drivers/ata/pata_platform.c linux-2.6.32.49/d= rivers/ata/pata_platform.c ---- linux-2.6.32.49/drivers/ata/pata_platform.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_platform.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -48,7 +48,7 @@ static struct scsi_host_template pata_pl +diff --git a/drivers/ata/pata_platform.c b/drivers/ata/pata_platform.c +index 3f6ebc6..a18c358 100644 +--- a/drivers/ata/pata_platform.c ++++ b/drivers/ata/pata_platform.c +@@ -48,7 +48,7 @@ static struct scsi_host_template pata_platform_sht =3D= { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27233,10 +28512,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_pla= tform.c linux-2.6.32.49/drivers/a .inherits =3D &ata_sff_port_ops, .sff_data_xfer =3D ata_sff_data_xfer_noirq, .cable_detect =3D ata_cable_unknown, -diff -urNp linux-2.6.32.49/drivers/ata/pata_qdi.c linux-2.6.32.49/driver= s/ata/pata_qdi.c ---- linux-2.6.32.49/drivers/ata/pata_qdi.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_qdi.c 2011-11-15 19:59:43.000000000= -0500 -@@ -157,7 +157,7 @@ static struct scsi_host_template qdi_sht +diff --git a/drivers/ata/pata_qdi.c b/drivers/ata/pata_qdi.c +index 45879dc..165a9f9 100644 +--- a/drivers/ata/pata_qdi.c ++++ b/drivers/ata/pata_qdi.c +@@ -157,7 +157,7 @@ static struct scsi_host_template qdi_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27245,7 +28525,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_qdi.c= linux-2.6.32.49/drivers/ata/pa .inherits =3D &ata_sff_port_ops, .qc_issue =3D qdi_qc_issue, .sff_data_xfer =3D qdi_data_xfer, -@@ -165,7 +165,7 @@ static struct ata_port_operations qdi650 +@@ -165,7 +165,7 @@ static struct ata_port_operations qdi6500_port_ops =3D= { .set_piomode =3D qdi6500_set_piomode, }; =20 @@ -27254,10 +28534,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_qdi= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &qdi6500_port_ops, .set_piomode =3D qdi6580_set_piomode, }; -diff -urNp linux-2.6.32.49/drivers/ata/pata_radisys.c linux-2.6.32.49/dr= ivers/ata/pata_radisys.c ---- linux-2.6.32.49/drivers/ata/pata_radisys.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_radisys.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -187,7 +187,7 @@ static struct scsi_host_template radisys +diff --git a/drivers/ata/pata_radisys.c b/drivers/ata/pata_radisys.c +index 4401b33..716c5cc 100644 +--- a/drivers/ata/pata_radisys.c ++++ b/drivers/ata/pata_radisys.c +@@ -187,7 +187,7 @@ static struct scsi_host_template radisys_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27266,10 +28547,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_rad= isys.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .qc_issue =3D radisys_qc_issue, .cable_detect =3D ata_cable_unknown, -diff -urNp linux-2.6.32.49/drivers/ata/pata_rb532_cf.c linux-2.6.32.49/d= rivers/ata/pata_rb532_cf.c ---- linux-2.6.32.49/drivers/ata/pata_rb532_cf.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_rb532_cf.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -68,7 +68,7 @@ static irqreturn_t rb532_pata_irq_handle +diff --git a/drivers/ata/pata_rb532_cf.c b/drivers/ata/pata_rb532_cf.c +index 45f1e10..fab6bca 100644 +--- a/drivers/ata/pata_rb532_cf.c ++++ b/drivers/ata/pata_rb532_cf.c +@@ -68,7 +68,7 @@ static irqreturn_t rb532_pata_irq_handler(int irq, voi= d *dev_instance) return IRQ_HANDLED; } =20 @@ -27278,10 +28560,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_rb5= 32_cf.c linux-2.6.32.49/drivers/a .inherits =3D &ata_sff_port_ops, .sff_data_xfer =3D ata_sff_data_xfer32, }; -diff -urNp linux-2.6.32.49/drivers/ata/pata_rdc.c linux-2.6.32.49/driver= s/ata/pata_rdc.c ---- linux-2.6.32.49/drivers/ata/pata_rdc.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_rdc.c 2011-11-15 19:59:43.000000000= -0500 -@@ -272,7 +272,7 @@ static void rdc_set_dmamode(struct ata_p +diff --git a/drivers/ata/pata_rdc.c b/drivers/ata/pata_rdc.c +index c843a1e..b5853c3 100644 +--- a/drivers/ata/pata_rdc.c ++++ b/drivers/ata/pata_rdc.c +@@ -272,7 +272,7 @@ static void rdc_set_dmamode(struct ata_port *ap, str= uct ata_device *adev) pci_write_config_byte(dev, 0x48, udma_enable); } =20 @@ -27290,10 +28573,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_rdc= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &ata_bmdma32_port_ops, .cable_detect =3D rdc_pata_cable_detect, .set_piomode =3D rdc_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_rz1000.c linux-2.6.32.49/dri= vers/ata/pata_rz1000.c ---- linux-2.6.32.49/drivers/ata/pata_rz1000.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_rz1000.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -54,7 +54,7 @@ static struct scsi_host_template rz1000_ +diff --git a/drivers/ata/pata_rz1000.c b/drivers/ata/pata_rz1000.c +index a5e4dfe..080c8c9 100644 +--- a/drivers/ata/pata_rz1000.c ++++ b/drivers/ata/pata_rz1000.c +@@ -54,7 +54,7 @@ static struct scsi_host_template rz1000_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27302,10 +28586,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_rz1= 000.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_sff_port_ops, .cable_detect =3D ata_cable_40wire, .set_mode =3D rz1000_set_mode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_sc1200.c linux-2.6.32.49/dri= vers/ata/pata_sc1200.c ---- linux-2.6.32.49/drivers/ata/pata_sc1200.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_sc1200.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -207,7 +207,7 @@ static struct scsi_host_template sc1200_ +diff --git a/drivers/ata/pata_sc1200.c b/drivers/ata/pata_sc1200.c +index 3bbed83..e309daf 100644 +--- a/drivers/ata/pata_sc1200.c ++++ b/drivers/ata/pata_sc1200.c +@@ -207,7 +207,7 @@ static struct scsi_host_template sc1200_sht =3D { .sg_tablesize =3D LIBATA_DUMB_MAX_PRD, }; =20 @@ -27314,10 +28599,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_sc1= 200.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma_port_ops, .qc_prep =3D ata_sff_dumb_qc_prep, .qc_issue =3D sc1200_qc_issue, -diff -urNp linux-2.6.32.49/drivers/ata/pata_scc.c linux-2.6.32.49/driver= s/ata/pata_scc.c ---- linux-2.6.32.49/drivers/ata/pata_scc.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_scc.c 2011-11-15 19:59:43.000000000= -0500 -@@ -965,7 +965,7 @@ static struct scsi_host_template scc_sht +diff --git a/drivers/ata/pata_scc.c b/drivers/ata/pata_scc.c +index 4257d6b..4c1d9d5 100644 +--- a/drivers/ata/pata_scc.c ++++ b/drivers/ata/pata_scc.c +@@ -965,7 +965,7 @@ static struct scsi_host_template scc_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27326,10 +28612,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_scc= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &ata_bmdma_port_ops, =20 .set_piomode =3D scc_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_sch.c linux-2.6.32.49/driver= s/ata/pata_sch.c ---- linux-2.6.32.49/drivers/ata/pata_sch.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_sch.c 2011-11-15 19:59:43.000000000= -0500 -@@ -75,7 +75,7 @@ static struct scsi_host_template sch_sht +diff --git a/drivers/ata/pata_sch.c b/drivers/ata/pata_sch.c +index 99cceb4..e2e0a87 100644 +--- a/drivers/ata/pata_sch.c ++++ b/drivers/ata/pata_sch.c +@@ -75,7 +75,7 @@ static struct scsi_host_template sch_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27338,10 +28625,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_sch= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D ata_cable_unknown, .set_piomode =3D sch_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_serverworks.c linux-2.6.32.4= 9/drivers/ata/pata_serverworks.c ---- linux-2.6.32.49/drivers/ata/pata_serverworks.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_serverworks.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -299,7 +299,7 @@ static struct scsi_host_template serverw +diff --git a/drivers/ata/pata_serverworks.c b/drivers/ata/pata_serverwor= ks.c +index beaed12..39969f1 100644 +--- a/drivers/ata/pata_serverworks.c ++++ b/drivers/ata/pata_serverworks.c +@@ -299,7 +299,7 @@ static struct scsi_host_template serverworks_sht =3D= { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27350,7 +28638,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_serve= rworks.c linux-2.6.32.49/driver .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D serverworks_cable_detect, .mode_filter =3D serverworks_osb4_filter, -@@ -307,7 +307,7 @@ static struct ata_port_operations server +@@ -307,7 +307,7 @@ static struct ata_port_operations serverworks_osb4_p= ort_ops =3D { .set_dmamode =3D serverworks_set_dmamode, }; =20 @@ -27359,10 +28647,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_ser= verworks.c linux-2.6.32.49/driver .inherits =3D &serverworks_osb4_port_ops, .mode_filter =3D serverworks_csb_filter, }; -diff -urNp linux-2.6.32.49/drivers/ata/pata_sil680.c linux-2.6.32.49/dri= vers/ata/pata_sil680.c ---- linux-2.6.32.49/drivers/ata/pata_sil680.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_sil680.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -194,7 +194,7 @@ static struct scsi_host_template sil680_ +diff --git a/drivers/ata/pata_sil680.c b/drivers/ata/pata_sil680.c +index a2ace48..0463b44 100644 +--- a/drivers/ata/pata_sil680.c ++++ b/drivers/ata/pata_sil680.c +@@ -194,7 +194,7 @@ static struct scsi_host_template sil680_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27371,10 +28660,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_sil= 680.c linux-2.6.32.49/drivers/ata .inherits =3D &ata_bmdma32_port_ops, .cable_detect =3D sil680_cable_detect, .set_piomode =3D sil680_set_piomode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_sis.c linux-2.6.32.49/driver= s/ata/pata_sis.c ---- linux-2.6.32.49/drivers/ata/pata_sis.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_sis.c 2011-11-15 19:59:43.000000000= -0500 -@@ -503,47 +503,47 @@ static struct scsi_host_template sis_sht +diff --git a/drivers/ata/pata_sis.c b/drivers/ata/pata_sis.c +index 488e77b..b3724d5 100644 +--- a/drivers/ata/pata_sis.c ++++ b/drivers/ata/pata_sis.c +@@ -503,47 +503,47 @@ static struct scsi_host_template sis_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27429,10 +28719,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_sis= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &sis_base_ops, .set_piomode =3D sis_old_set_piomode, .set_dmamode =3D sis_old_set_dmamode, -diff -urNp linux-2.6.32.49/drivers/ata/pata_sl82c105.c linux-2.6.32.49/d= rivers/ata/pata_sl82c105.c ---- linux-2.6.32.49/drivers/ata/pata_sl82c105.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_sl82c105.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -231,7 +231,7 @@ static struct scsi_host_template sl82c10 +diff --git a/drivers/ata/pata_sl82c105.c b/drivers/ata/pata_sl82c105.c +index 29f733c..43e9ca0 100644 +--- a/drivers/ata/pata_sl82c105.c ++++ b/drivers/ata/pata_sl82c105.c +@@ -231,7 +231,7 @@ static struct scsi_host_template sl82c105_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27441,10 +28732,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_sl8= 2c105.c linux-2.6.32.49/drivers/a .inherits =3D &ata_bmdma_port_ops, .qc_defer =3D sl82c105_qc_defer, .bmdma_start =3D sl82c105_bmdma_start, -diff -urNp linux-2.6.32.49/drivers/ata/pata_triflex.c linux-2.6.32.49/dr= ivers/ata/pata_triflex.c ---- linux-2.6.32.49/drivers/ata/pata_triflex.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_triflex.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -178,7 +178,7 @@ static struct scsi_host_template triflex +diff --git a/drivers/ata/pata_triflex.c b/drivers/ata/pata_triflex.c +index f1f13ff..df39e99 100644 +--- a/drivers/ata/pata_triflex.c ++++ b/drivers/ata/pata_triflex.c +@@ -178,7 +178,7 @@ static struct scsi_host_template triflex_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27453,10 +28745,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_tri= flex.c linux-2.6.32.49/drivers/at .inherits =3D &ata_bmdma_port_ops, .bmdma_start =3D triflex_bmdma_start, .bmdma_stop =3D triflex_bmdma_stop, -diff -urNp linux-2.6.32.49/drivers/ata/pata_via.c linux-2.6.32.49/driver= s/ata/pata_via.c ---- linux-2.6.32.49/drivers/ata/pata_via.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pata_via.c 2011-11-15 19:59:43.000000000= -0500 -@@ -419,7 +419,7 @@ static struct scsi_host_template via_sht +diff --git a/drivers/ata/pata_via.c b/drivers/ata/pata_via.c +index 1d73b8d..98a4b29 100644 +--- a/drivers/ata/pata_via.c ++++ b/drivers/ata/pata_via.c +@@ -419,7 +419,7 @@ static struct scsi_host_template via_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27465,7 +28758,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_via.c= linux-2.6.32.49/drivers/ata/pa .inherits =3D &ata_bmdma_port_ops, .cable_detect =3D via_cable_detect, .set_piomode =3D via_set_piomode, -@@ -429,7 +429,7 @@ static struct ata_port_operations via_po +@@ -429,7 +429,7 @@ static struct ata_port_operations via_port_ops =3D { .port_start =3D via_port_start, }; =20 @@ -27474,10 +28767,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_via= .c linux-2.6.32.49/drivers/ata/pa .inherits =3D &via_port_ops, .sff_data_xfer =3D ata_sff_data_xfer_noirq, }; -diff -urNp linux-2.6.32.49/drivers/ata/pata_winbond.c linux-2.6.32.49/dr= ivers/ata/pata_winbond.c ---- linux-2.6.32.49/drivers/ata/pata_winbond.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/pata_winbond.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -125,7 +125,7 @@ static struct scsi_host_template winbond +diff --git a/drivers/ata/pata_winbond.c b/drivers/ata/pata_winbond.c +index 6d8619b..ad511c4 100644 +--- a/drivers/ata/pata_winbond.c ++++ b/drivers/ata/pata_winbond.c +@@ -125,7 +125,7 @@ static struct scsi_host_template winbond_sht =3D { ATA_PIO_SHT(DRV_NAME), }; =20 @@ -27486,10 +28780,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pata_win= bond.c linux-2.6.32.49/drivers/at .inherits =3D &ata_sff_port_ops, .sff_data_xfer =3D winbond_data_xfer, .cable_detect =3D ata_cable_40wire, -diff -urNp linux-2.6.32.49/drivers/ata/pdc_adma.c linux-2.6.32.49/driver= s/ata/pdc_adma.c ---- linux-2.6.32.49/drivers/ata/pdc_adma.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/pdc_adma.c 2011-11-15 19:59:43.000000000= -0500 -@@ -145,7 +145,7 @@ static struct scsi_host_template adma_at +diff --git a/drivers/ata/pdc_adma.c b/drivers/ata/pdc_adma.c +index 6c65b07..f996ec7 100644 +--- a/drivers/ata/pdc_adma.c ++++ b/drivers/ata/pdc_adma.c +@@ -145,7 +145,7 @@ static struct scsi_host_template adma_ata_sht =3D { .dma_boundary =3D ADMA_DMA_BOUNDARY, }; =20 @@ -27498,10 +28793,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/pdc_adma= .c linux-2.6.32.49/drivers/ata/pd .inherits =3D &ata_sff_port_ops, =20 .lost_interrupt =3D ATA_OP_NULL, -diff -urNp linux-2.6.32.49/drivers/ata/sata_fsl.c linux-2.6.32.49/driver= s/ata/sata_fsl.c ---- linux-2.6.32.49/drivers/ata/sata_fsl.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_fsl.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1258,7 +1258,7 @@ static struct scsi_host_template sata_fs +diff --git a/drivers/ata/sata_fsl.c b/drivers/ata/sata_fsl.c +index 172b57e..c49bc1e 100644 +--- a/drivers/ata/sata_fsl.c ++++ b/drivers/ata/sata_fsl.c +@@ -1258,7 +1258,7 @@ static struct scsi_host_template sata_fsl_sht =3D = { .dma_boundary =3D ATA_DMA_BOUNDARY, }; =20 @@ -27510,10 +28806,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_fsl= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &sata_pmp_port_ops, =20 .qc_defer =3D ata_std_qc_defer, -diff -urNp linux-2.6.32.49/drivers/ata/sata_inic162x.c linux-2.6.32.49/d= rivers/ata/sata_inic162x.c ---- linux-2.6.32.49/drivers/ata/sata_inic162x.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/ata/sata_inic162x.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -721,7 +721,7 @@ static int inic_port_start(struct ata_po +diff --git a/drivers/ata/sata_inic162x.c b/drivers/ata/sata_inic162x.c +index 4406902..60603ef 100644 +--- a/drivers/ata/sata_inic162x.c ++++ b/drivers/ata/sata_inic162x.c +@@ -721,7 +721,7 @@ static int inic_port_start(struct ata_port *ap) return 0; } =20 @@ -27522,10 +28819,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_ini= c162x.c linux-2.6.32.49/drivers/a .inherits =3D &sata_port_ops, =20 .check_atapi_dma =3D inic_check_atapi_dma, -diff -urNp linux-2.6.32.49/drivers/ata/sata_mv.c linux-2.6.32.49/drivers= /ata/sata_mv.c ---- linux-2.6.32.49/drivers/ata/sata_mv.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ata/sata_mv.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -656,7 +656,7 @@ static struct scsi_host_template mv6_sht +diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c +index cf41126..8107be6 100644 +--- a/drivers/ata/sata_mv.c ++++ b/drivers/ata/sata_mv.c +@@ -656,7 +656,7 @@ static struct scsi_host_template mv6_sht =3D { .dma_boundary =3D MV_DMA_BOUNDARY, }; =20 @@ -27534,7 +28832,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_mv.c = linux-2.6.32.49/drivers/ata/sat .inherits =3D &ata_sff_port_ops, =20 .lost_interrupt =3D ATA_OP_NULL, -@@ -678,7 +678,7 @@ static struct ata_port_operations mv5_op +@@ -678,7 +678,7 @@ static struct ata_port_operations mv5_ops =3D { .port_stop =3D mv_port_stop, }; =20 @@ -27543,7 +28841,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_mv.c = linux-2.6.32.49/drivers/ata/sat .inherits =3D &mv5_ops, .dev_config =3D mv6_dev_config, .scr_read =3D mv_scr_read, -@@ -698,7 +698,7 @@ static struct ata_port_operations mv6_op +@@ -698,7 +698,7 @@ static struct ata_port_operations mv6_ops =3D { .bmdma_status =3D mv_bmdma_status, }; =20 @@ -27552,10 +28850,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_mv.= c linux-2.6.32.49/drivers/ata/sat .inherits =3D &mv6_ops, .dev_config =3D ATA_OP_NULL, .qc_prep =3D mv_qc_prep_iie, -diff -urNp linux-2.6.32.49/drivers/ata/sata_nv.c linux-2.6.32.49/drivers= /ata/sata_nv.c ---- linux-2.6.32.49/drivers/ata/sata_nv.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ata/sata_nv.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -464,7 +464,7 @@ static struct scsi_host_template nv_swnc +diff --git a/drivers/ata/sata_nv.c b/drivers/ata/sata_nv.c +index ae2297c..d5c9c33 100644 +--- a/drivers/ata/sata_nv.c ++++ b/drivers/ata/sata_nv.c +@@ -464,7 +464,7 @@ static struct scsi_host_template nv_swncq_sht =3D { * cases. Define nv_hardreset() which only kicks in for post-boot * probing and use it for all variants. */ @@ -27564,7 +28863,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_nv.c = linux-2.6.32.49/drivers/ata/sat .inherits =3D &ata_bmdma_port_ops, .lost_interrupt =3D ATA_OP_NULL, .scr_read =3D nv_scr_read, -@@ -472,20 +472,20 @@ static struct ata_port_operations nv_gen +@@ -472,20 +472,20 @@ static struct ata_port_operations nv_generic_ops =3D= { .hardreset =3D nv_hardreset, }; =20 @@ -27588,7 +28887,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_nv.c = linux-2.6.32.49/drivers/ata/sat .inherits =3D &nv_ck804_ops, =20 .check_atapi_dma =3D nv_adma_check_atapi_dma, -@@ -509,7 +509,7 @@ static struct ata_port_operations nv_adm +@@ -509,7 +509,7 @@ static struct ata_port_operations nv_adma_ops =3D { .host_stop =3D nv_adma_host_stop, }; =20 @@ -27597,10 +28896,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_nv.= c linux-2.6.32.49/drivers/ata/sat .inherits =3D &nv_generic_ops, =20 .qc_defer =3D ata_std_qc_defer, -diff -urNp linux-2.6.32.49/drivers/ata/sata_promise.c linux-2.6.32.49/dr= ivers/ata/sata_promise.c ---- linux-2.6.32.49/drivers/ata/sata_promise.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ata/sata_promise.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -195,7 +195,7 @@ static const struct ata_port_operations=20 +diff --git a/drivers/ata/sata_promise.c b/drivers/ata/sata_promise.c +index 07d8d00..6cc70bb 100644 +--- a/drivers/ata/sata_promise.c ++++ b/drivers/ata/sata_promise.c +@@ -195,7 +195,7 @@ static const struct ata_port_operations pdc_common_o= ps =3D { .error_handler =3D pdc_error_handler, }; =20 @@ -27609,7 +28909,7 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_promi= se.c linux-2.6.32.49/drivers/at .inherits =3D &pdc_common_ops, .cable_detect =3D pdc_sata_cable_detect, .freeze =3D pdc_sata_freeze, -@@ -208,14 +208,14 @@ static struct ata_port_operations pdc_sa +@@ -208,14 +208,14 @@ static struct ata_port_operations pdc_sata_ops =3D= { =20 /* First-generation chips need a more restrictive ->check_atapi_dma op, and ->freeze/thaw that ignore the hotplug controls. */ @@ -27626,10 +28926,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_pro= mise.c linux-2.6.32.49/drivers/at .inherits =3D &pdc_common_ops, .cable_detect =3D pdc_pata_cable_detect, .freeze =3D pdc_freeze, -diff -urNp linux-2.6.32.49/drivers/ata/sata_qstor.c linux-2.6.32.49/driv= ers/ata/sata_qstor.c ---- linux-2.6.32.49/drivers/ata/sata_qstor.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ata/sata_qstor.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -132,7 +132,7 @@ static struct scsi_host_template qs_ata_ +diff --git a/drivers/ata/sata_qstor.c b/drivers/ata/sata_qstor.c +index 326c0cf..36ecebe 100644 +--- a/drivers/ata/sata_qstor.c ++++ b/drivers/ata/sata_qstor.c +@@ -132,7 +132,7 @@ static struct scsi_host_template qs_ata_sht =3D { .dma_boundary =3D QS_DMA_BOUNDARY, }; =20 @@ -27638,22 +28939,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_qst= or.c linux-2.6.32.49/drivers/ata/ .inherits =3D &ata_sff_port_ops, =20 .check_atapi_dma =3D qs_check_atapi_dma, -diff -urNp linux-2.6.32.49/drivers/ata/sata_sil24.c linux-2.6.32.49/driv= ers/ata/sata_sil24.c ---- linux-2.6.32.49/drivers/ata/sata_sil24.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ata/sata_sil24.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -388,7 +388,7 @@ static struct scsi_host_template sil24_s - .dma_boundary =3D ATA_DMA_BOUNDARY, - }; -=20 --static struct ata_port_operations sil24_ops =3D { -+static const struct ata_port_operations sil24_ops =3D { - .inherits =3D &sata_pmp_port_ops, -=20 - .qc_defer =3D sil24_qc_defer, -diff -urNp linux-2.6.32.49/drivers/ata/sata_sil.c linux-2.6.32.49/driver= s/ata/sata_sil.c ---- linux-2.6.32.49/drivers/ata/sata_sil.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_sil.c 2011-11-15 19:59:43.000000000= -0500 -@@ -182,7 +182,7 @@ static struct scsi_host_template sil_sht +diff --git a/drivers/ata/sata_sil.c b/drivers/ata/sata_sil.c +index 3cb69d5..0871d3c 100644 +--- a/drivers/ata/sata_sil.c ++++ b/drivers/ata/sata_sil.c +@@ -182,7 +182,7 @@ static struct scsi_host_template sil_sht =3D { .sg_tablesize =3D ATA_MAX_PRD }; =20 @@ -27662,10 +28952,24 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_sil= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &ata_bmdma32_port_ops, .dev_config =3D sil_dev_config, .set_mode =3D sil_set_mode, -diff -urNp linux-2.6.32.49/drivers/ata/sata_sis.c linux-2.6.32.49/driver= s/ata/sata_sis.c ---- linux-2.6.32.49/drivers/ata/sata_sis.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_sis.c 2011-11-15 19:59:43.000000000= -0500 -@@ -89,7 +89,7 @@ static struct scsi_host_template sis_sht +diff --git a/drivers/ata/sata_sil24.c b/drivers/ata/sata_sil24.c +index e6946fc..eddb794 100644 +--- a/drivers/ata/sata_sil24.c ++++ b/drivers/ata/sata_sil24.c +@@ -388,7 +388,7 @@ static struct scsi_host_template sil24_sht =3D { + .dma_boundary =3D ATA_DMA_BOUNDARY, + }; +=20 +-static struct ata_port_operations sil24_ops =3D { ++static const struct ata_port_operations sil24_ops =3D { + .inherits =3D &sata_pmp_port_ops, +=20 + .qc_defer =3D sil24_qc_defer, +diff --git a/drivers/ata/sata_sis.c b/drivers/ata/sata_sis.c +index f8a91bf..9cb06b6 100644 +--- a/drivers/ata/sata_sis.c ++++ b/drivers/ata/sata_sis.c +@@ -89,7 +89,7 @@ static struct scsi_host_template sis_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27674,10 +28978,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_sis= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &ata_bmdma_port_ops, .scr_read =3D sis_scr_read, .scr_write =3D sis_scr_write, -diff -urNp linux-2.6.32.49/drivers/ata/sata_svw.c linux-2.6.32.49/driver= s/ata/sata_svw.c ---- linux-2.6.32.49/drivers/ata/sata_svw.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_svw.c 2011-11-15 19:59:43.000000000= -0500 -@@ -344,7 +344,7 @@ static struct scsi_host_template k2_sata +diff --git a/drivers/ata/sata_svw.c b/drivers/ata/sata_svw.c +index 7257f2d..d04c6f5 100644 +--- a/drivers/ata/sata_svw.c ++++ b/drivers/ata/sata_svw.c +@@ -344,7 +344,7 @@ static struct scsi_host_template k2_sata_sht =3D { }; =20 =20 @@ -27686,10 +28991,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_svw= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &ata_bmdma_port_ops, .sff_tf_load =3D k2_sata_tf_load, .sff_tf_read =3D k2_sata_tf_read, -diff -urNp linux-2.6.32.49/drivers/ata/sata_sx4.c linux-2.6.32.49/driver= s/ata/sata_sx4.c ---- linux-2.6.32.49/drivers/ata/sata_sx4.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_sx4.c 2011-11-15 19:59:43.000000000= -0500 -@@ -248,7 +248,7 @@ static struct scsi_host_template pdc_sat +diff --git a/drivers/ata/sata_sx4.c b/drivers/ata/sata_sx4.c +index bbcf970..cd0df0d 100644 +--- a/drivers/ata/sata_sx4.c ++++ b/drivers/ata/sata_sx4.c +@@ -248,7 +248,7 @@ static struct scsi_host_template pdc_sata_sht =3D { }; =20 /* TODO: inherit from base port_ops after converting to new EH */ @@ -27698,10 +29004,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_sx4= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &ata_sff_port_ops, =20 .check_atapi_dma =3D pdc_check_atapi_dma, -diff -urNp linux-2.6.32.49/drivers/ata/sata_uli.c linux-2.6.32.49/driver= s/ata/sata_uli.c ---- linux-2.6.32.49/drivers/ata/sata_uli.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_uli.c 2011-11-15 19:59:43.000000000= -0500 -@@ -79,7 +79,7 @@ static struct scsi_host_template uli_sht +diff --git a/drivers/ata/sata_uli.c b/drivers/ata/sata_uli.c +index e5bff47..089d859 100644 +--- a/drivers/ata/sata_uli.c ++++ b/drivers/ata/sata_uli.c +@@ -79,7 +79,7 @@ static struct scsi_host_template uli_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27710,10 +29017,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_uli= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &ata_bmdma_port_ops, .scr_read =3D uli_scr_read, .scr_write =3D uli_scr_write, -diff -urNp linux-2.6.32.49/drivers/ata/sata_via.c linux-2.6.32.49/driver= s/ata/sata_via.c ---- linux-2.6.32.49/drivers/ata/sata_via.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_via.c 2011-11-15 19:59:43.000000000= -0500 -@@ -115,32 +115,32 @@ static struct scsi_host_template svia_sh +diff --git a/drivers/ata/sata_via.c b/drivers/ata/sata_via.c +index f5dcca7..77b94eb 100644 +--- a/drivers/ata/sata_via.c ++++ b/drivers/ata/sata_via.c +@@ -115,32 +115,32 @@ static struct scsi_host_template svia_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -27751,10 +29059,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_via= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &svia_base_ops, .hardreset =3D sata_std_hardreset, .scr_read =3D vt8251_scr_read, -diff -urNp linux-2.6.32.49/drivers/ata/sata_vsc.c linux-2.6.32.49/driver= s/ata/sata_vsc.c ---- linux-2.6.32.49/drivers/ata/sata_vsc.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ata/sata_vsc.c 2011-11-15 19:59:43.000000000= -0500 -@@ -306,7 +306,7 @@ static struct scsi_host_template vsc_sat +diff --git a/drivers/ata/sata_vsc.c b/drivers/ata/sata_vsc.c +index 8b2a278..51e65d3 100644 +--- a/drivers/ata/sata_vsc.c ++++ b/drivers/ata/sata_vsc.c +@@ -306,7 +306,7 @@ static struct scsi_host_template vsc_sata_sht =3D { }; =20 =20 @@ -27763,10 +29072,11 @@ diff -urNp linux-2.6.32.49/drivers/ata/sata_vsc= .c linux-2.6.32.49/drivers/ata/sa .inherits =3D &ata_bmdma_port_ops, /* The IRQ handling is not quite standard SFF behaviour so we cannot use the default lost interrupt handler */ -diff -urNp linux-2.6.32.49/drivers/atm/adummy.c linux-2.6.32.49/drivers/= atm/adummy.c ---- linux-2.6.32.49/drivers/atm/adummy.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/atm/adummy.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -77,7 +77,7 @@ adummy_send(struct atm_vcc *vcc, struct=20 +diff --git a/drivers/atm/adummy.c b/drivers/atm/adummy.c +index 5effec6..7e4019a 100644 +--- a/drivers/atm/adummy.c ++++ b/drivers/atm/adummy.c +@@ -77,7 +77,7 @@ adummy_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -27775,10 +29085,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/adummy.c= linux-2.6.32.49/drivers/atm/adum =20 return 0; } -diff -urNp linux-2.6.32.49/drivers/atm/ambassador.c linux-2.6.32.49/driv= ers/atm/ambassador.c ---- linux-2.6.32.49/drivers/atm/ambassador.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/atm/ambassador.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -453,7 +453,7 @@ static void tx_complete (amb_dev * dev,=20 +diff --git a/drivers/atm/ambassador.c b/drivers/atm/ambassador.c +index 66e1813..26a27c6 100644 +--- a/drivers/atm/ambassador.c ++++ b/drivers/atm/ambassador.c +@@ -453,7 +453,7 @@ static void tx_complete (amb_dev * dev, tx_out * tx)= { PRINTD (DBG_FLOW|DBG_TX, "tx_complete %p %p", dev, tx); =20 // VC layer stats @@ -27787,7 +29098,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/ambassador= .c linux-2.6.32.49/drivers/atm/ =20 // free the descriptor kfree (tx_descr); -@@ -494,7 +494,7 @@ static void rx_complete (amb_dev * dev,=20 +@@ -494,7 +494,7 @@ static void rx_complete (amb_dev * dev, rx_out * rx)= { dump_skb ("<<<", vc, skb); =20 // VC layer stats @@ -27796,7 +29107,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/ambassador= .c linux-2.6.32.49/drivers/atm/ __net_timestamp(skb); // end of our responsability atm_vcc->push (atm_vcc, skb); -@@ -509,7 +509,7 @@ static void rx_complete (amb_dev * dev,=20 +@@ -509,7 +509,7 @@ static void rx_complete (amb_dev * dev, rx_out * rx)= { } else { PRINTK (KERN_INFO, "dropped over-size frame"); // should we count this? @@ -27805,7 +29116,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/ambassador= .c linux-2.6.32.49/drivers/atm/ } =20 } else { -@@ -1341,7 +1341,7 @@ static int amb_send (struct atm_vcc * at +@@ -1341,7 +1341,7 @@ static int amb_send (struct atm_vcc * atm_vcc, str= uct sk_buff * skb) { } =20 if (check_area (skb->data, skb->len)) { @@ -27814,10 +29125,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/ambassad= or.c linux-2.6.32.49/drivers/atm/ return -ENOMEM; // ? } =20 -diff -urNp linux-2.6.32.49/drivers/atm/atmtcp.c linux-2.6.32.49/drivers/= atm/atmtcp.c ---- linux-2.6.32.49/drivers/atm/atmtcp.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/atm/atmtcp.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -206,7 +206,7 @@ static int atmtcp_v_send(struct atm_vcc=20 +diff --git a/drivers/atm/atmtcp.c b/drivers/atm/atmtcp.c +index 02ad83d..6daffeb 100644 +--- a/drivers/atm/atmtcp.c ++++ b/drivers/atm/atmtcp.c +@@ -206,7 +206,7 @@ static int atmtcp_v_send(struct atm_vcc *vcc,struct = sk_buff *skb) if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); if (dev_data) return 0; @@ -27826,7 +29138,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/atmtcp.c l= inux-2.6.32.49/drivers/atm/atmt return -ENOLINK; } size =3D skb->len+sizeof(struct atmtcp_hdr); -@@ -214,7 +214,7 @@ static int atmtcp_v_send(struct atm_vcc=20 +@@ -214,7 +214,7 @@ static int atmtcp_v_send(struct atm_vcc *vcc,struct = sk_buff *skb) if (!new_skb) { if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); @@ -27835,7 +29147,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/atmtcp.c l= inux-2.6.32.49/drivers/atm/atmt return -ENOBUFS; } hdr =3D (void *) skb_put(new_skb,sizeof(struct atmtcp_hdr)); -@@ -225,8 +225,8 @@ static int atmtcp_v_send(struct atm_vcc=20 +@@ -225,8 +225,8 @@ static int atmtcp_v_send(struct atm_vcc *vcc,struct = sk_buff *skb) if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); out_vcc->push(out_vcc,new_skb); @@ -27846,7 +29158,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/atmtcp.c l= inux-2.6.32.49/drivers/atm/atmt return 0; } =20 -@@ -300,7 +300,7 @@ static int atmtcp_c_send(struct atm_vcc=20 +@@ -300,7 +300,7 @@ static int atmtcp_c_send(struct atm_vcc *vcc,struct = sk_buff *skb) out_vcc =3D find_vcc(dev, ntohs(hdr->vpi), ntohs(hdr->vci)); read_unlock(&vcc_sklist_lock); if (!out_vcc) { @@ -27855,7 +29167,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/atmtcp.c l= inux-2.6.32.49/drivers/atm/atmt goto done; } skb_pull(skb,sizeof(struct atmtcp_hdr)); -@@ -312,8 +312,8 @@ static int atmtcp_c_send(struct atm_vcc=20 +@@ -312,8 +312,8 @@ static int atmtcp_c_send(struct atm_vcc *vcc,struct = sk_buff *skb) __net_timestamp(new_skb); skb_copy_from_linear_data(skb, skb_put(new_skb, skb->len), skb->len); out_vcc->push(out_vcc,new_skb); @@ -27866,9 +29178,10 @@ diff -urNp linux-2.6.32.49/drivers/atm/atmtcp.c = linux-2.6.32.49/drivers/atm/atmt done: if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); -diff -urNp linux-2.6.32.49/drivers/atm/eni.c linux-2.6.32.49/drivers/atm= /eni.c ---- linux-2.6.32.49/drivers/atm/eni.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/atm/eni.c 2011-11-18 18:01:52.000000000 -050= 0 +diff --git a/drivers/atm/eni.c b/drivers/atm/eni.c +index 0c30261..3da356e 100644 +--- a/drivers/atm/eni.c ++++ b/drivers/atm/eni.c @@ -525,7 +525,7 @@ static int rx_aal0(struct atm_vcc *vcc) DPRINTK(DEV_LABEL "(itf %d): trashing empty cell\n", vcc->dev->number); @@ -27905,7 +29218,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/eni.c linu= x-2.6.32.49/drivers/atm/eni.c } wake_up(&eni_dev->rx_wait); } -@@ -1227,7 +1227,7 @@ static void dequeue_tx(struct atm_dev *d +@@ -1227,7 +1227,7 @@ static void dequeue_tx(struct atm_dev *dev) PCI_DMA_TODEVICE); if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb_irq(skb); @@ -27923,10 +29236,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/eni.c li= nux-2.6.32.49/drivers/atm/eni.c "MMF", "SMF", "MMF", "03?", /* 0- 3 */ "UTP", "05?", "06?", "07?", /* 4- 7 */ "TAXI","09?", "10?", "11?", /* 8-11 */ -diff -urNp linux-2.6.32.49/drivers/atm/firestream.c linux-2.6.32.49/driv= ers/atm/firestream.c ---- linux-2.6.32.49/drivers/atm/firestream.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/atm/firestream.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -748,7 +748,7 @@ static void process_txdone_queue (struct +diff --git a/drivers/atm/firestream.c b/drivers/atm/firestream.c +index cd5049a..a51209f 100644 +--- a/drivers/atm/firestream.c ++++ b/drivers/atm/firestream.c +@@ -748,7 +748,7 @@ static void process_txdone_queue (struct fs_dev *dev= , struct queue *q) } } =20 @@ -27935,7 +29249,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/firestream= .c linux-2.6.32.49/drivers/atm/ =20 fs_dprintk (FS_DEBUG_TXMEM, "i"); fs_dprintk (FS_DEBUG_ALLOC, "Free t-skb: %p\n", skb); -@@ -815,7 +815,7 @@ static void process_incoming (struct fs_ +@@ -815,7 +815,7 @@ static void process_incoming (struct fs_dev *dev, st= ruct queue *q) #endif skb_put (skb, qe->p1 & 0xffff);=20 ATM_SKB(skb)->vcc =3D atm_vcc; @@ -27944,7 +29258,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/firestream= .c linux-2.6.32.49/drivers/atm/ __net_timestamp(skb); fs_dprintk (FS_DEBUG_ALLOC, "Free rec-skb: %p (pushed)\n", skb); atm_vcc->push (atm_vcc, skb); -@@ -836,12 +836,12 @@ static void process_incoming (struct fs_ +@@ -836,12 +836,12 @@ static void process_incoming (struct fs_dev *dev, = struct queue *q) kfree (pe); } if (atm_vcc) @@ -27959,10 +29273,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/firestre= am.c linux-2.6.32.49/drivers/atm/ break; default: /* Hmm. Haven't written the code to handle the others yet...= -- REW */ printk (KERN_WARNING "Don't know what to do with RX status %x: %s.\n= ",=20 -diff -urNp linux-2.6.32.49/drivers/atm/fore200e.c linux-2.6.32.49/driver= s/atm/fore200e.c ---- linux-2.6.32.49/drivers/atm/fore200e.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/atm/fore200e.c 2011-11-15 19:59:43.000000000= -0500 -@@ -931,9 +931,9 @@ fore200e_tx_irq(struct fore200e* fore200 +diff --git a/drivers/atm/fore200e.c b/drivers/atm/fore200e.c +index f766cc4..a34002e 100644 +--- a/drivers/atm/fore200e.c ++++ b/drivers/atm/fore200e.c +@@ -931,9 +931,9 @@ fore200e_tx_irq(struct fore200e* fore200e) #endif /* check error condition */ if (*entry->status & STATUS_ERROR) @@ -27974,7 +29289,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/fore200e.c= linux-2.6.32.49/drivers/atm/fo } } =20 -@@ -1082,7 +1082,7 @@ fore200e_push_rpd(struct fore200e* fore2 +@@ -1082,7 +1082,7 @@ fore200e_push_rpd(struct fore200e* fore200e, struc= t atm_vcc* vcc, struct rpd* rp if (skb =3D=3D NULL) { DPRINTK(2, "unable to alloc new skb, rx PDU length =3D %d\n", pdu_len)= ; =20 @@ -27983,7 +29298,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/fore200e.c= linux-2.6.32.49/drivers/atm/fo return -ENOMEM; }=20 =20 -@@ -1125,14 +1125,14 @@ fore200e_push_rpd(struct fore200e* fore2 +@@ -1125,14 +1125,14 @@ fore200e_push_rpd(struct fore200e* fore200e, str= uct atm_vcc* vcc, struct rpd* rp =20 dev_kfree_skb_any(skb); =20 @@ -28000,7 +29315,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/fore200e.c= linux-2.6.32.49/drivers/atm/fo =20 ASSERT(atomic_read(&sk_atm(vcc)->sk_wmem_alloc) >=3D 0); =20 -@@ -1210,7 +1210,7 @@ fore200e_rx_irq(struct fore200e* fore200 +@@ -1210,7 +1210,7 @@ fore200e_rx_irq(struct fore200e* fore200e) DPRINTK(2, "damaged PDU on %d.%d.%d\n", fore200e->atm_dev->number, entry->rpd->atm_header.vpi, entry->rpd->atm_header.vci); @@ -28009,7 +29324,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/fore200e.c= linux-2.6.32.49/drivers/atm/fo } } =20 -@@ -1655,7 +1655,7 @@ fore200e_send(struct atm_vcc *vcc, struc +@@ -1655,7 +1655,7 @@ fore200e_send(struct atm_vcc *vcc, struct sk_buff = *skb) goto retry_here; } =20 @@ -28018,10 +29333,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/fore200e= .c linux-2.6.32.49/drivers/atm/fo =20 fore200e->tx_sat++; DPRINTK(2, "tx queue of device %s is saturated, PDU dropped - hear= tbeat is %08x\n", -diff -urNp linux-2.6.32.49/drivers/atm/he.c linux-2.6.32.49/drivers/atm/= he.c ---- linux-2.6.32.49/drivers/atm/he.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/atm/he.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1769,7 +1769,7 @@ he_service_rbrq(struct he_dev *he_dev, i +diff --git a/drivers/atm/he.c b/drivers/atm/he.c +index 7066703..2b130de 100644 +--- a/drivers/atm/he.c ++++ b/drivers/atm/he.c +@@ -1769,7 +1769,7 @@ he_service_rbrq(struct he_dev *he_dev, int group) =20 if (RBRQ_HBUF_ERR(he_dev->rbrq_head)) { hprintk("HBUF_ERR! (cid 0x%x)\n", cid); @@ -28030,7 +29346,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c goto return_host_buffers; } =20 -@@ -1802,7 +1802,7 @@ he_service_rbrq(struct he_dev *he_dev, i +@@ -1802,7 +1802,7 @@ he_service_rbrq(struct he_dev *he_dev, int group) RBRQ_LEN_ERR(he_dev->rbrq_head) ? "LEN_ERR" : "", vcc->vpi, vcc->vci); @@ -28039,7 +29355,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c goto return_host_buffers; } =20 -@@ -1861,7 +1861,7 @@ he_service_rbrq(struct he_dev *he_dev, i +@@ -1861,7 +1861,7 @@ he_service_rbrq(struct he_dev *he_dev, int group) vcc->push(vcc, skb); spin_lock(&he_dev->global_lock); =20 @@ -28048,7 +29364,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c =20 return_host_buffers: ++pdus_assembled; -@@ -2206,7 +2206,7 @@ __enqueue_tpd(struct he_dev *he_dev, str +@@ -2206,7 +2206,7 @@ __enqueue_tpd(struct he_dev *he_dev, struct he_tpd= *tpd, unsigned cid) tpd->vcc->pop(tpd->vcc, tpd->skb); else dev_kfree_skb_any(tpd->skb); @@ -28057,7 +29373,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c } pci_pool_free(he_dev->tpd_pool, tpd, TPD_ADDR(tpd->status)); return; -@@ -2618,7 +2618,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2618,7 +2618,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -28066,7 +29382,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c return -EINVAL; } =20 -@@ -2629,7 +2629,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2629,7 +2629,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -28075,7 +29391,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c return -EINVAL; } #endif -@@ -2641,7 +2641,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2641,7 +2641,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -28084,7 +29400,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c spin_unlock_irqrestore(&he_dev->global_lock, flags); return -ENOMEM; } -@@ -2683,7 +2683,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2683,7 +2683,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -28093,7 +29409,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c linux= -2.6.32.49/drivers/atm/he.c spin_unlock_irqrestore(&he_dev->global_lock, flags); return -ENOMEM; } -@@ -2714,7 +2714,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2714,7 +2714,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) __enqueue_tpd(he_dev, tpd, cid); spin_unlock_irqrestore(&he_dev->global_lock, flags); =20 @@ -28102,10 +29418,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/he.c lin= ux-2.6.32.49/drivers/atm/he.c =20 return 0; } -diff -urNp linux-2.6.32.49/drivers/atm/horizon.c linux-2.6.32.49/drivers= /atm/horizon.c ---- linux-2.6.32.49/drivers/atm/horizon.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/atm/horizon.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1033,7 +1033,7 @@ static void rx_schedule (hrz_dev * dev,=20 +diff --git a/drivers/atm/horizon.c b/drivers/atm/horizon.c +index 4e49021..01b1512 100644 +--- a/drivers/atm/horizon.c ++++ b/drivers/atm/horizon.c +@@ -1033,7 +1033,7 @@ static void rx_schedule (hrz_dev * dev, int irq) { { struct atm_vcc * vcc =3D ATM_SKB(skb)->vcc; // VC layer stats @@ -28114,7 +29431,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/horizon.c = linux-2.6.32.49/drivers/atm/hor __net_timestamp(skb); // end of our responsability vcc->push (vcc, skb); -@@ -1185,7 +1185,7 @@ static void tx_schedule (hrz_dev * const +@@ -1185,7 +1185,7 @@ static void tx_schedule (hrz_dev * const dev, int = irq) { dev->tx_iovec =3D NULL; =09 // VC layer stats @@ -28123,10 +29440,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/horizon.= c linux-2.6.32.49/drivers/atm/hor =09 // free the skb hrz_kfree_skb (skb); -diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c linux-2.6.32.49/driver= s/atm/idt77252.c ---- linux-2.6.32.49/drivers/atm/idt77252.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/atm/idt77252.c 2011-11-15 19:59:43.000000000= -0500 -@@ -810,7 +810,7 @@ drain_scq(struct idt77252_dev *card, str +diff --git a/drivers/atm/idt77252.c b/drivers/atm/idt77252.c +index e33ae00..9deb4ab 100644 +--- a/drivers/atm/idt77252.c ++++ b/drivers/atm/idt77252.c +@@ -810,7 +810,7 @@ drain_scq(struct idt77252_dev *card, struct vc_map *= vc) else dev_kfree_skb(skb); =20 @@ -28135,7 +29453,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id } =20 atomic_dec(&scq->used); -@@ -1073,13 +1073,13 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1073,13 +1073,13 @@ dequeue_rx(struct idt77252_dev *card, struct rsq= _entry *rsqe) if ((sb =3D dev_alloc_skb(64)) =3D=3D NULL) { printk("%s: Can't allocate buffers for aal0.\n", card->name); @@ -28151,7 +29469,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id dev_kfree_skb(sb); break; } -@@ -1096,7 +1096,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1096,7 +1096,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -28160,7 +29478,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id =20 cell +=3D ATM_CELL_PAYLOAD; } -@@ -1133,13 +1133,13 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1133,13 +1133,13 @@ dequeue_rx(struct idt77252_dev *card, struct rsq= _entry *rsqe) "(CDC: %08x)\n", card->name, len, rpp->len, readl(SAR_REG_CDC)); recycle_rx_pool_skb(card, rpp); @@ -28176,7 +29494,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id return; } if (skb_queue_len(&rpp->queue) > 1) { -@@ -1150,7 +1150,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1150,7 +1150,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) RXPRINTK("%s: Can't alloc RX skb.\n", card->name); recycle_rx_pool_skb(card, rpp); @@ -28185,7 +29503,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id return; } if (!atm_charge(vcc, skb->truesize)) { -@@ -1169,7 +1169,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1169,7 +1169,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) __net_timestamp(skb); =20 vcc->push(vcc, skb); @@ -28194,7 +29512,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id =20 return; } -@@ -1191,7 +1191,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1191,7 +1191,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) __net_timestamp(skb); =20 vcc->push(vcc, skb); @@ -28203,7 +29521,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id =20 if (skb->truesize > SAR_FB_SIZE_3) add_rx_skb(card, 3, SAR_FB_SIZE_3, 1); -@@ -1303,14 +1303,14 @@ idt77252_rx_raw(struct idt77252_dev *car +@@ -1303,14 +1303,14 @@ idt77252_rx_raw(struct idt77252_dev *card) if (vcc->qos.aal !=3D ATM_AAL0) { RPRINTK("%s: raw cell for non AAL0 vc %u.%u\n", card->name, vpi, vci); @@ -28220,7 +29538,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id goto drop; } =20 -@@ -1329,7 +1329,7 @@ idt77252_rx_raw(struct idt77252_dev *car +@@ -1329,7 +1329,7 @@ idt77252_rx_raw(struct idt77252_dev *card) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -28229,7 +29547,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id =20 drop: skb_pull(queue, 64); -@@ -1954,13 +1954,13 @@ idt77252_send_skb(struct atm_vcc *vcc, s +@@ -1954,13 +1954,13 @@ idt77252_send_skb(struct atm_vcc *vcc, struct sk= _buff *skb, int oam) =20 if (vc =3D=3D NULL) { printk("%s: NULL connection in send().\n", card->name); @@ -28245,7 +29563,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id dev_kfree_skb(skb); return -EINVAL; } -@@ -1972,14 +1972,14 @@ idt77252_send_skb(struct atm_vcc *vcc, s +@@ -1972,14 +1972,14 @@ idt77252_send_skb(struct atm_vcc *vcc, struct sk= _buff *skb, int oam) break; default: printk("%s: Unsupported AAL: %d\n", card->name, vcc->qos.aal); @@ -28262,7 +29580,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id dev_kfree_skb(skb); return -EINVAL; } -@@ -1987,7 +1987,7 @@ idt77252_send_skb(struct atm_vcc *vcc, s +@@ -1987,7 +1987,7 @@ idt77252_send_skb(struct atm_vcc *vcc, struct sk_b= uff *skb, int oam) =20 err =3D queue_skb(card, vc, skb, oam); if (err) { @@ -28271,7 +29589,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252.c= linux-2.6.32.49/drivers/atm/id dev_kfree_skb(skb); return err; } -@@ -2010,7 +2010,7 @@ idt77252_send_oam(struct atm_vcc *vcc, v +@@ -2010,7 +2010,7 @@ idt77252_send_oam(struct atm_vcc *vcc, void *cell,= int flags) skb =3D dev_alloc_skb(64); if (!skb) { printk("%s: Out of memory in send_oam().\n", card->name); @@ -28280,10 +29598,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/idt77252= .c linux-2.6.32.49/drivers/atm/id return -ENOMEM; } atomic_add(skb->truesize, &sk_atm(vcc)->sk_wmem_alloc); -diff -urNp linux-2.6.32.49/drivers/atm/iphase.c linux-2.6.32.49/drivers/= atm/iphase.c ---- linux-2.6.32.49/drivers/atm/iphase.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/atm/iphase.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -1123,7 +1123,7 @@ static int rx_pkt(struct atm_dev *dev) =20 +diff --git a/drivers/atm/iphase.c b/drivers/atm/iphase.c +index b2c1b37..faa672b 100644 +--- a/drivers/atm/iphase.c ++++ b/drivers/atm/iphase.c +@@ -1123,7 +1123,7 @@ static int rx_pkt(struct atm_dev *dev) status =3D (u_short) (buf_desc_ptr->desc_mode); =20 if (status & (RX_CER | RX_PTE | RX_OFL)) =20 { =20 @@ -28292,7 +29611,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c l= inux-2.6.32.49/drivers/atm/ipha IF_ERR(printk("IA: bad packet, dropping it");) =20 if (status & RX_CER) {=20 IF_ERR(printk(" cause: packet CRC error\n");) -@@ -1146,7 +1146,7 @@ static int rx_pkt(struct atm_dev *dev) =20 +@@ -1146,7 +1146,7 @@ static int rx_pkt(struct atm_dev *dev) len =3D dma_addr - buf_addr; =20 if (len > iadev->rx_buf_sz) { printk("Over %d bytes sdu received, dropped!!!\n", iadev->rx= _buf_sz); @@ -28301,7 +29620,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c l= inux-2.6.32.49/drivers/atm/ipha goto out_free_desc; } =20 -@@ -1296,7 +1296,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1296,7 +1296,7 @@ static void rx_dle_intr(struct atm_dev *dev) ia_vcc =3D INPH_IA_VCC(vcc); if (ia_vcc =3D=3D NULL) { @@ -28310,7 +29629,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c l= inux-2.6.32.49/drivers/atm/ipha dev_kfree_skb_any(skb); atm_return(vcc, atm_guess_pdu2truesize(len)); goto INCR_DLE; -@@ -1308,7 +1308,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1308,7 +1308,7 @@ static void rx_dle_intr(struct atm_dev *dev) if ((length > iadev->rx_buf_sz) || (length >=20 (skb->len - sizeof(struct cpcs_trailer)))= ) { @@ -28319,7 +29638,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c l= inux-2.6.32.49/drivers/atm/ipha IF_ERR(printk("rx_dle_intr: Bad AAL5 trailer %d (skb len = %d)",=20 length, skb= ->len);) dev_kfree_skb_any(skb); -@@ -1324,7 +1324,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1324,7 +1324,7 @@ static void rx_dle_intr(struct atm_dev *dev) =20 IF_RX(printk("rx_dle_intr: skb push");) =20 vcc->push(vcc,skb); =20 @@ -28328,7 +29647,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c l= inux-2.6.32.49/drivers/atm/ipha iadev->rx_pkt_cnt++; } =20 INCR_DLE: -@@ -2806,15 +2806,15 @@ static int ia_ioctl(struct atm_dev *dev, +@@ -2806,15 +2806,15 @@ static int ia_ioctl(struct atm_dev *dev, unsigne= d int cmd, void __user *arg) { struct k_sonet_stats *stats; stats =3D &PRIV(_ia_dev[board])->sonet_stats; @@ -28353,7 +29672,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c l= inux-2.6.32.49/drivers/atm/ipha } ia_cmds.status =3D 0; break; -@@ -2919,7 +2919,7 @@ static int ia_pkt_tx (struct atm_vcc *vc +@@ -2919,7 +2919,7 @@ static int ia_pkt_tx (struct atm_vcc *vcc, struct = sk_buff *skb) { if ((desc =3D=3D 0) || (desc > iadev->num_tx_desc)) =20 { =20 IF_ERR(printk(DEV_LABEL "invalid desc for send: %d\n", desc);)=20 @@ -28362,7 +29681,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c l= inux-2.6.32.49/drivers/atm/ipha if (vcc->pop) =20 vcc->pop(vcc, skb); =20 else =20 -@@ -3024,14 +3024,14 @@ static int ia_pkt_tx (struct atm_vcc *vc +@@ -3024,14 +3024,14 @@ static int ia_pkt_tx (struct atm_vcc *vcc, struc= t sk_buff *skb) { ATM_DESC(skb) =3D vcc->vci; skb_queue_tail(&iadev->tx_dma_q, skb); =20 @@ -28379,10 +29698,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/iphase.c= linux-2.6.32.49/drivers/atm/ipha if (iavcc->vc_desc_cnt > 10) { vcc->tx_quota =3D vcc->tx_quota * 3 / 4; printk("Tx1: vcc->tx_quota =3D %d \n", (u32)vcc->tx_quota = ); -diff -urNp linux-2.6.32.49/drivers/atm/lanai.c linux-2.6.32.49/drivers/a= tm/lanai.c ---- linux-2.6.32.49/drivers/atm/lanai.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/atm/lanai.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1305,7 +1305,7 @@ static void lanai_send_one_aal5(struct l +diff --git a/drivers/atm/lanai.c b/drivers/atm/lanai.c +index cf97c34..8d30655 100644 +--- a/drivers/atm/lanai.c ++++ b/drivers/atm/lanai.c +@@ -1305,7 +1305,7 @@ static void lanai_send_one_aal5(struct lanai_dev *= lanai, vcc_tx_add_aal5_trailer(lvcc, skb->len, 0, 0); lanai_endtx(lanai, lvcc); lanai_free_skb(lvcc->tx.atmvcc, skb); @@ -28391,7 +29711,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/lanai.c li= nux-2.6.32.49/drivers/atm/lanai } =20 /* Try to fill the buffer - don't call unless there is backlog */ -@@ -1428,7 +1428,7 @@ static void vcc_rx_aal5(struct lanai_vcc +@@ -1428,7 +1428,7 @@ static void vcc_rx_aal5(struct lanai_vcc *lvcc, in= t endptr) ATM_SKB(skb)->vcc =3D lvcc->rx.atmvcc; __net_timestamp(skb); lvcc->rx.atmvcc->push(lvcc->rx.atmvcc, skb); @@ -28400,7 +29720,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/lanai.c li= nux-2.6.32.49/drivers/atm/lanai out: lvcc->rx.buf.ptr =3D end; cardvcc_write(lvcc, endptr, vcc_rxreadptr); -@@ -1670,7 +1670,7 @@ static int handle_service(struct lanai_d +@@ -1670,7 +1670,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) DPRINTK("(itf %d) got RX service entry 0x%X for non-AAL5 " "vcc %d\n", lanai->number, (unsigned int) s, vci); lanai->stats.service_rxnotaal5++; @@ -28409,7 +29729,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/lanai.c li= nux-2.6.32.49/drivers/atm/lanai return 0; } if (likely(!(s & (SERVICE_TRASH | SERVICE_STREAM | SERVICE_CRCERR)))) = { -@@ -1682,7 +1682,7 @@ static int handle_service(struct lanai_d +@@ -1682,7 +1682,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) int bytes; read_unlock(&vcc_sklist_lock); DPRINTK("got trashed rx pdu on vci %d\n", vci); @@ -28418,7 +29738,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/lanai.c li= nux-2.6.32.49/drivers/atm/lanai lvcc->stats.x.aal5.service_trash++; bytes =3D (SERVICE_GET_END(s) * 16) - (((unsigned long) lvcc->rx.buf.ptr) - -@@ -1694,7 +1694,7 @@ static int handle_service(struct lanai_d +@@ -1694,7 +1694,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) } if (s & SERVICE_STREAM) { read_unlock(&vcc_sklist_lock); @@ -28427,7 +29747,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/lanai.c li= nux-2.6.32.49/drivers/atm/lanai lvcc->stats.x.aal5.service_stream++; printk(KERN_ERR DEV_LABEL "(itf %d): Got AAL5 stream " "PDU on VCI %d!\n", lanai->number, vci); -@@ -1702,7 +1702,7 @@ static int handle_service(struct lanai_d +@@ -1702,7 +1702,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) return 0; } DPRINTK("got rx crc error on vci %d\n", vci); @@ -28436,10 +29756,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/lanai.c = linux-2.6.32.49/drivers/atm/lanai lvcc->stats.x.aal5.service_rxcrc++; lvcc->rx.buf.ptr =3D &lvcc->rx.buf.start[SERVICE_GET_END(s) * 4]; cardvcc_write(lvcc, SERVICE_GET_END(s), vcc_rxreadptr); -diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c linux-2.6.32.49/drivers= /atm/nicstar.c ---- linux-2.6.32.49/drivers/atm/nicstar.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/atm/nicstar.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1723,7 +1723,7 @@ static int ns_send(struct atm_vcc *vcc,=20 +diff --git a/drivers/atm/nicstar.c b/drivers/atm/nicstar.c +index 3da804b..d3b0eed 100644 +--- a/drivers/atm/nicstar.c ++++ b/drivers/atm/nicstar.c +@@ -1723,7 +1723,7 @@ static int ns_send(struct atm_vcc *vcc, struct sk_= buff *skb) if ((vc =3D (vc_map *) vcc->dev_data) =3D=3D NULL) { printk("nicstar%d: vcc->dev_data =3D=3D NULL on ns_send().\n", ca= rd->index); @@ -28448,7 +29769,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1731,7 +1731,7 @@ static int ns_send(struct atm_vcc *vcc,=20 +@@ -1731,7 +1731,7 @@ static int ns_send(struct atm_vcc *vcc, struct sk_= buff *skb) if (!vc->tx) { printk("nicstar%d: Trying to transmit on a non-tx VC.\n", card->i= ndex); @@ -28457,7 +29778,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1739,7 +1739,7 @@ static int ns_send(struct atm_vcc *vcc,=20 +@@ -1739,7 +1739,7 @@ static int ns_send(struct atm_vcc *vcc, struct sk_= buff *skb) if (vcc->qos.aal !=3D ATM_AAL5 && vcc->qos.aal !=3D ATM_AAL0) { printk("nicstar%d: Only AAL0 and AAL5 are supported.\n", card->in= dex); @@ -28466,7 +29787,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1747,7 +1747,7 @@ static int ns_send(struct atm_vcc *vcc,=20 +@@ -1747,7 +1747,7 @@ static int ns_send(struct atm_vcc *vcc, struct sk_= buff *skb) if (skb_shinfo(skb)->nr_frags !=3D 0) { printk("nicstar%d: No scatter-gather yet.\n", card->index); @@ -28475,7 +29796,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1792,11 +1792,11 @@ static int ns_send(struct atm_vcc *vcc,=20 +@@ -1792,11 +1792,11 @@ static int ns_send(struct atm_vcc *vcc, struct s= k_buff *skb) =20 if (push_scqe(card, vc, scq, &scqe, skb) !=3D 0) { @@ -28489,7 +29810,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic =20 return 0; } -@@ -2111,14 +2111,14 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2111,14 +2111,14 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rs= qe) { printk("nicstar%d: Can't allocate buffers for aal0.\n", card->index); @@ -28506,7 +29827,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic dev_kfree_skb_any(sb); break; } -@@ -2133,7 +2133,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2133,7 +2133,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -28515,7 +29836,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic cell +=3D ATM_CELL_PAYLOAD; } =20 -@@ -2152,7 +2152,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2152,7 +2152,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) if (iovb =3D=3D NULL) { printk("nicstar%d: Out of iovec buffers.\n", card->index); @@ -28524,7 +29845,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic recycle_rx_buf(card, skb); return; } -@@ -2182,7 +2182,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2182,7 +2182,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) else if (NS_SKB(iovb)->iovcnt >=3D NS_MAX_IOVECS) { printk("nicstar%d: received too big AAL5 SDU.\n", card->index); @@ -28533,7 +29854,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic recycle_iovec_rx_bufs(card, (struct iovec *) iovb->data, NS_MAX_I= OVECS); NS_SKB(iovb)->iovcnt =3D 0; iovb->len =3D 0; -@@ -2202,7 +2202,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2202,7 +2202,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) printk("nicstar%d: Expected a small buffer, and this is not on= e.\n", card->index); which_list(card, skb); @@ -28542,7 +29863,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic recycle_rx_buf(card, skb); vc->rx_iov =3D NULL; recycle_iov_buf(card, iovb); -@@ -2216,7 +2216,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2216,7 +2216,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) printk("nicstar%d: Expected a large buffer, and this is not on= e.\n", card->index); which_list(card, skb); @@ -28551,7 +29872,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic recycle_iovec_rx_bufs(card, (struct iovec *) iovb->data, NS_SKB(iovb)->iovcnt); vc->rx_iov =3D NULL; -@@ -2240,7 +2240,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2240,7 +2240,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) printk(" - PDU size mismatch.\n"); else printk(".\n"); @@ -28560,7 +29881,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic recycle_iovec_rx_bufs(card, (struct iovec *) iovb->data, NS_SKB(iovb)->iovcnt); vc->rx_iov =3D NULL; -@@ -2256,7 +2256,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2256,7 +2256,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) if (!atm_charge(vcc, skb->truesize)) { push_rxbufs(card, skb); @@ -28569,7 +29890,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic } else { -@@ -2268,7 +2268,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2268,7 +2268,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) ATM_SKB(skb)->vcc =3D vcc; __net_timestamp(skb); vcc->push(vcc, skb); @@ -28578,7 +29899,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic } } else if (NS_SKB(iovb)->iovcnt =3D=3D 2) /* One small plus one lar= ge buffer */ -@@ -2283,7 +2283,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2283,7 +2283,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) if (!atm_charge(vcc, sb->truesize)) { push_rxbufs(card, sb); @@ -28587,7 +29908,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic } else { -@@ -2295,7 +2295,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2295,7 +2295,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -28596,7 +29917,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic } =20 push_rxbufs(card, skb); -@@ -2306,7 +2306,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2306,7 +2306,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) if (!atm_charge(vcc, skb->truesize)) { push_rxbufs(card, skb); @@ -28605,7 +29926,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic } else { -@@ -2320,7 +2320,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2320,7 +2320,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) ATM_SKB(skb)->vcc =3D vcc; __net_timestamp(skb); vcc->push(vcc, skb); @@ -28614,7 +29935,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic } =20 push_rxbufs(card, sb); -@@ -2342,7 +2342,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2342,7 +2342,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) if (hb =3D=3D NULL) { printk("nicstar%d: Out of huge buffers.\n", card->index)= ; @@ -28623,7 +29944,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic recycle_iovec_rx_bufs(card, (struct iovec *) iovb->data, NS_SKB(iovb)->iovcnt); vc->rx_iov =3D NULL; -@@ -2393,7 +2393,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2393,7 +2393,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) } else dev_kfree_skb_any(hb); @@ -28632,7 +29953,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c = linux-2.6.32.49/drivers/atm/nic } else { -@@ -2427,7 +2427,7 @@ static void dequeue_rx(ns_dev *card, ns_ +@@ -2427,7 +2427,7 @@ static void dequeue_rx(ns_dev *card, ns_rsqe *rsqe= ) #endif /* NS_USE_DESTRUCTORS */ __net_timestamp(hb); vcc->push(vcc, hb); @@ -28641,9 +29962,10 @@ diff -urNp linux-2.6.32.49/drivers/atm/nicstar.c= linux-2.6.32.49/drivers/atm/nic } } =20 -diff -urNp linux-2.6.32.49/drivers/atm/solos-pci.c linux-2.6.32.49/drive= rs/atm/solos-pci.c ---- linux-2.6.32.49/drivers/atm/solos-pci.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/atm/solos-pci.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/atm/solos-pci.c b/drivers/atm/solos-pci.c +index 84c93ff..e6ed269 100644 +--- a/drivers/atm/solos-pci.c ++++ b/drivers/atm/solos-pci.c @@ -708,7 +708,7 @@ void solos_bh(unsigned long card_arg) } atm_charge(vcc, skb->truesize); @@ -28653,7 +29975,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/solos-pci.= c linux-2.6.32.49/drivers/atm/s break; =20 case PKT_STATUS: -@@ -914,6 +914,8 @@ static int print_buffer(struct sk_buff * +@@ -914,6 +914,8 @@ static int print_buffer(struct sk_buff *buf) char msg[500]; char item[10]; =20 @@ -28662,7 +29984,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/solos-pci.= c linux-2.6.32.49/drivers/atm/s len =3D buf->len; for (i =3D 0; i < len; i++){ if(i % 8 =3D=3D 0) -@@ -1023,7 +1025,7 @@ static uint32_t fpga_tx(struct solos_car +@@ -1023,7 +1025,7 @@ static uint32_t fpga_tx(struct solos_card *card) vcc =3D SKB_CB(oldskb)->vcc; =20 if (vcc) { @@ -28671,9 +29993,10 @@ diff -urNp linux-2.6.32.49/drivers/atm/solos-pci= .c linux-2.6.32.49/drivers/atm/s solos_pop(vcc, oldskb); } else dev_kfree_skb_irq(oldskb); -diff -urNp linux-2.6.32.49/drivers/atm/suni.c linux-2.6.32.49/drivers/at= m/suni.c ---- linux-2.6.32.49/drivers/atm/suni.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/atm/suni.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/drivers/atm/suni.c b/drivers/atm/suni.c +index 6dd3f59..ee377f3 100644 +--- a/drivers/atm/suni.c ++++ b/drivers/atm/suni.c @@ -49,8 +49,8 @@ static DEFINE_SPINLOCK(sunis_lock); =20 =20 @@ -28685,10 +30008,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/suni.c l= inux-2.6.32.49/drivers/atm/suni.c =20 =20 static void suni_hz(unsigned long from_timer) -diff -urNp linux-2.6.32.49/drivers/atm/uPD98402.c linux-2.6.32.49/driver= s/atm/uPD98402.c ---- linux-2.6.32.49/drivers/atm/uPD98402.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/atm/uPD98402.c 2011-11-15 19:59:43.000000000= -0500 -@@ -41,7 +41,7 @@ static int fetch_stats(struct atm_dev *d +diff --git a/drivers/atm/uPD98402.c b/drivers/atm/uPD98402.c +index fc8cb07..4a80e53 100644 +--- a/drivers/atm/uPD98402.c ++++ b/drivers/atm/uPD98402.c +@@ -41,7 +41,7 @@ static int fetch_stats(struct atm_dev *dev,struct sone= t_stats __user *arg,int ze struct sonet_stats tmp; int error =3D 0; =20 @@ -28697,7 +30021,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/uPD98402.c= linux-2.6.32.49/drivers/atm/uP sonet_copy_stats(&PRIV(dev)->sonet_stats,&tmp); if (arg) error =3D copy_to_user(arg,&tmp,sizeof(tmp)); if (zero && !error) { -@@ -160,9 +160,9 @@ static int uPD98402_ioctl(struct atm_dev +@@ -160,9 +160,9 @@ static int uPD98402_ioctl(struct atm_dev *dev,unsign= ed int cmd,void __user *arg) =20 =20 #define ADD_LIMITED(s,v) \ @@ -28710,7 +30034,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/uPD98402.c= linux-2.6.32.49/drivers/atm/uP =20 =20 static void stat_event(struct atm_dev *dev) -@@ -193,7 +193,7 @@ static void uPD98402_int(struct atm_dev=20 +@@ -193,7 +193,7 @@ static void uPD98402_int(struct atm_dev *dev) if (reason & uPD98402_INT_PFM) stat_event(dev); if (reason & uPD98402_INT_PCO) { (void) GET(PCOCR); /* clear interrupt cause */ @@ -28719,7 +30043,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/uPD98402.c= linux-2.6.32.49/drivers/atm/uP &PRIV(dev)->sonet_stats.uncorr_hcs); } if ((reason & uPD98402_INT_RFO) &&=20 -@@ -221,9 +221,9 @@ static int uPD98402_start(struct atm_dev +@@ -221,9 +221,9 @@ static int uPD98402_start(struct atm_dev *dev) PUT(~(uPD98402_INT_PFM | uPD98402_INT_ALM | uPD98402_INT_RFO | uPD98402_INT_LOS),PIMR); /* enable them */ (void) fetch_stats(dev,NULL,1); /* clear kernel counters */ @@ -28732,10 +30056,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/uPD98402= .c linux-2.6.32.49/drivers/atm/uP return 0; } =20 -diff -urNp linux-2.6.32.49/drivers/atm/zatm.c linux-2.6.32.49/drivers/at= m/zatm.c ---- linux-2.6.32.49/drivers/atm/zatm.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/atm/zatm.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -458,7 +458,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy +diff --git a/drivers/atm/zatm.c b/drivers/atm/zatm.c +index 2e9635b..32927b4 100644 +--- a/drivers/atm/zatm.c ++++ b/drivers/atm/zatm.c +@@ -458,7 +458,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy[0],dummy[1]= ); } if (!size) { dev_kfree_skb_irq(skb); @@ -28744,7 +30069,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/zatm.c lin= ux-2.6.32.49/drivers/atm/zatm.c continue; } if (!atm_charge(vcc,skb->truesize)) { -@@ -468,7 +468,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy +@@ -468,7 +468,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy[0],dummy[1]= ); skb->len =3D size; ATM_SKB(skb)->vcc =3D vcc; vcc->push(vcc,skb); @@ -28753,7 +30078,7 @@ diff -urNp linux-2.6.32.49/drivers/atm/zatm.c lin= ux-2.6.32.49/drivers/atm/zatm.c } zout(pos & 0xffff,MTA(mbx)); #if 0 /* probably a stupid idea */ -@@ -732,7 +732,7 @@ if (*ZATM_PRV_DSC(skb) !=3D (uPD98401_TXPD +@@ -732,7 +732,7 @@ if (*ZATM_PRV_DSC(skb) !=3D (uPD98401_TXPD_V | uPD98= 401_TXPD_DP | skb_queue_head(&zatm_vcc->backlog,skb); break; } @@ -28762,10 +30087,11 @@ diff -urNp linux-2.6.32.49/drivers/atm/zatm.c l= inux-2.6.32.49/drivers/atm/zatm.c wake_up(&zatm_vcc->tx_wait); } =20 -diff -urNp linux-2.6.32.49/drivers/base/bus.c linux-2.6.32.49/drivers/ba= se/bus.c ---- linux-2.6.32.49/drivers/base/bus.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/base/bus.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -70,7 +70,7 @@ static ssize_t drv_attr_store(struct kob +diff --git a/drivers/base/bus.c b/drivers/base/bus.c +index 63c143e..fece183 100644 +--- a/drivers/base/bus.c ++++ b/drivers/base/bus.c +@@ -70,7 +70,7 @@ static ssize_t drv_attr_store(struct kobject *kobj, st= ruct attribute *attr, return ret; } =20 @@ -28774,7 +30100,7 @@ diff -urNp linux-2.6.32.49/drivers/base/bus.c lin= ux-2.6.32.49/drivers/base/bus.c .show =3D drv_attr_show, .store =3D drv_attr_store, }; -@@ -115,7 +115,7 @@ static ssize_t bus_attr_store(struct kob +@@ -115,7 +115,7 @@ static ssize_t bus_attr_store(struct kobject *kobj, = struct attribute *attr, return ret; } =20 @@ -28783,7 +30109,7 @@ diff -urNp linux-2.6.32.49/drivers/base/bus.c lin= ux-2.6.32.49/drivers/base/bus.c .show =3D bus_attr_show, .store =3D bus_attr_store, }; -@@ -154,7 +154,7 @@ static int bus_uevent_filter(struct kset +@@ -154,7 +154,7 @@ static int bus_uevent_filter(struct kset *kset, stru= ct kobject *kobj) return 0; } =20 @@ -28792,10 +30118,11 @@ diff -urNp linux-2.6.32.49/drivers/base/bus.c l= inux-2.6.32.49/drivers/base/bus.c .filter =3D bus_uevent_filter, }; =20 -diff -urNp linux-2.6.32.49/drivers/base/class.c linux-2.6.32.49/drivers/= base/class.c ---- linux-2.6.32.49/drivers/base/class.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/base/class.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -63,7 +63,7 @@ static void class_release(struct kobject +diff --git a/drivers/base/class.c b/drivers/base/class.c +index 6e2c3b0..cb61871 100644 +--- a/drivers/base/class.c ++++ b/drivers/base/class.c +@@ -63,7 +63,7 @@ static void class_release(struct kobject *kobj) kfree(cp); } =20 @@ -28804,10 +30131,11 @@ diff -urNp linux-2.6.32.49/drivers/base/class.c= linux-2.6.32.49/drivers/base/cla .show =3D class_attr_show, .store =3D class_attr_store, }; -diff -urNp linux-2.6.32.49/drivers/base/core.c linux-2.6.32.49/drivers/b= ase/core.c ---- linux-2.6.32.49/drivers/base/core.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/base/core.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -100,7 +100,7 @@ static ssize_t dev_attr_store(struct kob +diff --git a/drivers/base/core.c b/drivers/base/core.c +index f33d768..a9358d0 100644 +--- a/drivers/base/core.c ++++ b/drivers/base/core.c +@@ -100,7 +100,7 @@ static ssize_t dev_attr_store(struct kobject *kobj, = struct attribute *attr, return ret; } =20 @@ -28816,7 +30144,7 @@ diff -urNp linux-2.6.32.49/drivers/base/core.c li= nux-2.6.32.49/drivers/base/core .show =3D dev_attr_show, .store =3D dev_attr_store, }; -@@ -252,7 +252,7 @@ static int dev_uevent(struct kset *kset, +@@ -252,7 +252,7 @@ static int dev_uevent(struct kset *kset, struct kobj= ect *kobj, return retval; } =20 @@ -28825,10 +30153,11 @@ diff -urNp linux-2.6.32.49/drivers/base/core.c = linux-2.6.32.49/drivers/base/core .filter =3D dev_uevent_filter, .name =3D dev_uevent_name, .uevent =3D dev_uevent, -diff -urNp linux-2.6.32.49/drivers/base/memory.c linux-2.6.32.49/drivers= /base/memory.c ---- linux-2.6.32.49/drivers/base/memory.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/base/memory.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -44,7 +44,7 @@ static int memory_uevent(struct kset *ks +diff --git a/drivers/base/memory.c b/drivers/base/memory.c +index 989429c..2272b00 100644 +--- a/drivers/base/memory.c ++++ b/drivers/base/memory.c +@@ -44,7 +44,7 @@ static int memory_uevent(struct kset *kset, struct kob= ject *obj, struct kobj_uev return retval; } =20 @@ -28837,10 +30166,11 @@ diff -urNp linux-2.6.32.49/drivers/base/memory.= c linux-2.6.32.49/drivers/base/me .name =3D memory_uevent_name, .uevent =3D memory_uevent, }; -diff -urNp linux-2.6.32.49/drivers/base/sys.c linux-2.6.32.49/drivers/ba= se/sys.c ---- linux-2.6.32.49/drivers/base/sys.c 2011-11-26 19:44:53.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/base/sys.c 2011-11-26 19:45:05.000000000 -05= 00 -@@ -54,7 +54,7 @@ sysdev_store(struct kobject *kobj, struc +diff --git a/drivers/base/sys.c b/drivers/base/sys.c +index 3f202f7..61c4a6f 100644 +--- a/drivers/base/sys.c ++++ b/drivers/base/sys.c +@@ -54,7 +54,7 @@ sysdev_store(struct kobject *kobj, struct attribute *a= ttr, return -EIO; } =20 @@ -28849,7 +30179,7 @@ diff -urNp linux-2.6.32.49/drivers/base/sys.c lin= ux-2.6.32.49/drivers/base/sys.c .show =3D sysdev_show, .store =3D sysdev_store, }; -@@ -104,7 +104,7 @@ static ssize_t sysdev_class_store(struct +@@ -104,7 +104,7 @@ static ssize_t sysdev_class_store(struct kobject *ko= bj, struct attribute *attr, return -EIO; } =20 @@ -28858,10 +30188,24 @@ diff -urNp linux-2.6.32.49/drivers/base/sys.c l= inux-2.6.32.49/drivers/base/sys.c .show =3D sysdev_class_show, .store =3D sysdev_class_store, }; -diff -urNp linux-2.6.32.49/drivers/block/cciss.c linux-2.6.32.49/drivers= /block/cciss.c ---- linux-2.6.32.49/drivers/block/cciss.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/block/cciss.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1011,6 +1011,8 @@ static int cciss_ioctl32_passthru(struct +diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c +index eb4fa19..1954777 100644 +--- a/drivers/block/DAC960.c ++++ b/drivers/block/DAC960.c +@@ -1973,6 +1973,8 @@ static bool DAC960_V1_ReadDeviceConfiguration(DAC9= 60_Controller_T + unsigned long flags; + int Channel, TargetID; +=20 ++ pax_track_stack(); ++ + if (!init_dma_loaf(Controller->PCIDevice, &local_dma,=20 + DAC960_V1_MaxChannels*(sizeof(DAC960_V1_DCDB_T) + + sizeof(DAC960_SCSI_Inquiry_T) + +diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c +index ca9c548..ca6899c 100644 +--- a/drivers/block/cciss.c ++++ b/drivers/block/cciss.c +@@ -1011,6 +1011,8 @@ static int cciss_ioctl32_passthru(struct block_dev= ice *bdev, fmode_t mode, int err; u32 cp; =20 @@ -28870,7 +30214,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cciss.c = linux-2.6.32.49/drivers/block/c err =3D 0; err |=3D copy_from_user(&arg64.LUN_info, &arg32->LUN_info, -@@ -2852,7 +2854,7 @@ static unsigned long pollcomplete(int ct +@@ -2852,7 +2854,7 @@ static unsigned long pollcomplete(int ctlr) /* Wait (up to 20 seconds) for a command to complete */ =20 for (i =3D 20 * HZ; i > 0; i--) { @@ -28879,7 +30223,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cciss.c = linux-2.6.32.49/drivers/block/c if (done =3D=3D FIFO_EMPTY) schedule_timeout_uninterruptible(1); else -@@ -2876,7 +2878,7 @@ static int sendcmd_core(ctlr_info_t *h,=20 +@@ -2876,7 +2878,7 @@ static int sendcmd_core(ctlr_info_t *h, CommandLis= t_struct *c) resend_cmd1: =20 /* Disable interrupt on the board. */ @@ -28943,7 +30287,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cciss.c = linux-2.6.32.49/drivers/block/c (h->interrupts_enabled =3D=3D 0))); } =20 -@@ -3892,7 +3894,7 @@ static int __devinit cciss_pci_init(ctlr +@@ -3892,7 +3894,7 @@ static int __devinit cciss_pci_init(ctlr_info_t *c= , struct pci_dev *pdev) */ c->max_commands =3D readl(&(c->cfgtable->CmdsOutMax)); c->product_name =3D products[prod_index].product_name; @@ -28952,7 +30296,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cciss.c = linux-2.6.32.49/drivers/block/c c->nr_cmds =3D c->max_commands - 4; if ((readb(&c->cfgtable->Signature[0]) !=3D 'C') || (readb(&c->cfgtable->Signature[1]) !=3D 'I') || -@@ -4291,7 +4293,7 @@ static int __devinit cciss_init_one(stru +@@ -4291,7 +4293,7 @@ static int __devinit cciss_init_one(struct pci_dev= *pdev, } =20 /* make sure the board interrupts are off */ @@ -28961,7 +30305,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cciss.c = linux-2.6.32.49/drivers/block/c if (request_irq(hba[i]->intr[SIMPLE_MODE_INT], do_cciss_intr, IRQF_DISABLED | IRQF_SHARED, hba[i]->devname, hba[i])) { printk(KERN_ERR "cciss: Unable to get irq %d for %s\n", -@@ -4341,7 +4343,7 @@ static int __devinit cciss_init_one(stru +@@ -4341,7 +4343,7 @@ static int __devinit cciss_init_one(struct pci_dev= *pdev, cciss_scsi_setup(i); =20 /* Turn the interrupts on so we can service requests */ @@ -28970,10 +30314,11 @@ diff -urNp linux-2.6.32.49/drivers/block/cciss.= c linux-2.6.32.49/drivers/block/c =20 /* Get the firmware version */ inq_buff =3D kzalloc(sizeof(InquiryData_struct), GFP_KERNEL); -diff -urNp linux-2.6.32.49/drivers/block/cciss.h linux-2.6.32.49/drivers= /block/cciss.h ---- linux-2.6.32.49/drivers/block/cciss.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/block/cciss.h 2011-11-15 19:59:43.000000000 = -0500 -@@ -90,7 +90,7 @@ struct ctlr_info=20 +diff --git a/drivers/block/cciss.h b/drivers/block/cciss.h +index 04d6bf8..36e712d 100644 +--- a/drivers/block/cciss.h ++++ b/drivers/block/cciss.h +@@ -90,7 +90,7 @@ struct ctlr_info // information about each logical volume drive_info_struct *drv[CISS_MAX_LUN]; =20 @@ -28982,10 +30327,11 @@ diff -urNp linux-2.6.32.49/drivers/block/cciss.= h linux-2.6.32.49/drivers/block/c =20 /* queue and queue Info */=20 struct hlist_head reqQ; -diff -urNp linux-2.6.32.49/drivers/block/cpqarray.c linux-2.6.32.49/driv= ers/block/cpqarray.c ---- linux-2.6.32.49/drivers/block/cpqarray.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/block/cpqarray.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -402,7 +402,7 @@ static int __init cpqarray_register_ctlr +diff --git a/drivers/block/cpqarray.c b/drivers/block/cpqarray.c +index 6422651..bb1bdef 100644 +--- a/drivers/block/cpqarray.c ++++ b/drivers/block/cpqarray.c +@@ -402,7 +402,7 @@ static int __init cpqarray_register_ctlr( int i, str= uct pci_dev *pdev) if (register_blkdev(COMPAQ_SMART2_MAJOR+i, hba[i]->devname)) { goto Enomem4; } @@ -28994,7 +30340,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarray= .c linux-2.6.32.49/drivers/bloc if (request_irq(hba[i]->intr, do_ida_intr, IRQF_DISABLED|IRQF_SHARED, hba[i]->devname, hba[i])) { -@@ -460,7 +460,7 @@ static int __init cpqarray_register_ctlr +@@ -460,7 +460,7 @@ static int __init cpqarray_register_ctlr( int i, str= uct pci_dev *pdev) add_timer(&hba[i]->timer); =20 /* Enable IRQ now that spinlock and rate limit timer are set up */ @@ -29012,7 +30358,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarray= .c linux-2.6.32.49/drivers/bloc break; } } -@@ -793,7 +793,7 @@ static int __init cpqarray_eisa_detect(v +@@ -793,7 +793,7 @@ static int __init cpqarray_eisa_detect(void) hba[ctlr]->intr =3D intr; sprintf(hba[ctlr]->devname, "ida%d", nr_ctlr); hba[ctlr]->product_name =3D products[j].product_name; @@ -29021,7 +30367,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarray= .c linux-2.6.32.49/drivers/bloc hba[ctlr]->ctlr =3D ctlr; hba[ctlr]->board_id =3D board_id; hba[ctlr]->pci_dev =3D NULL; /* not PCI */ -@@ -896,6 +896,8 @@ static void do_ida_request(struct reques +@@ -896,6 +896,8 @@ static void do_ida_request(struct request_queue *q) struct scatterlist tmp_sg[SG_MAX]; int i, dir, seg; =20 @@ -29048,7 +30394,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarray= .c linux-2.6.32.49/drivers/bloc =20 /* Get onto the completion Q */ addQ(&h->cmpQ, c); -@@ -1038,7 +1040,7 @@ static irqreturn_t do_ida_intr(int irq,=20 +@@ -1038,7 +1040,7 @@ static irqreturn_t do_ida_intr(int irq, void *dev_= id) unsigned long flags; __u32 a,a1; =20 @@ -29057,7 +30403,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarray= .c linux-2.6.32.49/drivers/bloc /* Is this interrupt for us? */ if (istat =3D=3D 0) return IRQ_NONE; -@@ -1049,7 +1051,7 @@ static irqreturn_t do_ida_intr(int irq,=20 +@@ -1049,7 +1051,7 @@ static irqreturn_t do_ida_intr(int irq, void *dev_= id) */ spin_lock_irqsave(IDA_LOCK(h->ctlr), flags); if (istat & FIFO_NOT_EMPTY) { @@ -29089,7 +30435,7 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarray= .c linux-2.6.32.49/drivers/bloc complete =3D pollcomplete(ctlr); =09 pci_unmap_single(info_p->pci_dev, (dma_addr_t) c->req.sg[0].addr,=20 -@@ -1534,9 +1536,9 @@ static int revalidate_allvol(ctlr_info_t +@@ -1534,9 +1536,9 @@ static int revalidate_allvol(ctlr_info_t *host) * we check the new geometry. Then turn interrupts back on when * we're done. */ @@ -29110,9 +30456,10 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarra= y.c linux-2.6.32.49/drivers/bloc if (done =3D=3D 0) { udelay(10); /* a short fixed delay */ } else -diff -urNp linux-2.6.32.49/drivers/block/cpqarray.h linux-2.6.32.49/driv= ers/block/cpqarray.h ---- linux-2.6.32.49/drivers/block/cpqarray.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/block/cpqarray.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/drivers/block/cpqarray.h b/drivers/block/cpqarray.h +index be73e9d..7fbf140 100644 +--- a/drivers/block/cpqarray.h ++++ b/drivers/block/cpqarray.h @@ -99,7 +99,7 @@ struct ctlr_info { drv_info_t drv[NWD]; struct proc_dir_entry *proc; @@ -29122,22 +30469,11 @@ diff -urNp linux-2.6.32.49/drivers/block/cpqarr= ay.h linux-2.6.32.49/drivers/bloc =20 cmdlist_t *reqQ; cmdlist_t *cmpQ; -diff -urNp linux-2.6.32.49/drivers/block/DAC960.c linux-2.6.32.49/driver= s/block/DAC960.c ---- linux-2.6.32.49/drivers/block/DAC960.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/block/DAC960.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1973,6 +1973,8 @@ static bool DAC960_V1_ReadDeviceConfigur - unsigned long flags; - int Channel, TargetID; -=20 -+ pax_track_stack(); -+ - if (!init_dma_loaf(Controller->PCIDevice, &local_dma,=20 - DAC960_V1_MaxChannels*(sizeof(DAC960_V1_DCDB_T) + - sizeof(DAC960_SCSI_Inquiry_T) + -diff -urNp linux-2.6.32.49/drivers/block/loop.c linux-2.6.32.49/drivers/= block/loop.c ---- linux-2.6.32.49/drivers/block/loop.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/block/loop.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -282,7 +282,7 @@ static int __do_lo_send_write(struct fil +diff --git a/drivers/block/loop.c b/drivers/block/loop.c +index 8ec2d70..2804b30 100644 +--- a/drivers/block/loop.c ++++ b/drivers/block/loop.c +@@ -282,7 +282,7 @@ static int __do_lo_send_write(struct file *file, mm_segment_t old_fs =3D get_fs(); =20 set_fs(get_ds()); @@ -29146,10 +30482,11 @@ diff -urNp linux-2.6.32.49/drivers/block/loop.c= linux-2.6.32.49/drivers/block/lo set_fs(old_fs); if (likely(bw =3D=3D len)) return 0; -diff -urNp linux-2.6.32.49/drivers/block/nbd.c linux-2.6.32.49/drivers/b= lock/nbd.c ---- linux-2.6.32.49/drivers/block/nbd.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/block/nbd.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -155,6 +155,8 @@ static int sock_xmit(struct nbd_device * +diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c +index 26ada47..083c480 100644 +--- a/drivers/block/nbd.c ++++ b/drivers/block/nbd.c +@@ -155,6 +155,8 @@ static int sock_xmit(struct nbd_device *lo, int send= , void *buf, int size, struct kvec iov; sigset_t blocked, oldset; =20 @@ -29158,7 +30495,7 @@ diff -urNp linux-2.6.32.49/drivers/block/nbd.c li= nux-2.6.32.49/drivers/block/nbd if (unlikely(!sock)) { printk(KERN_ERR "%s: Attempted %s on closed socket in sock_xmit\n", lo->disk->disk_name, (send ? "send" : "recv")); -@@ -569,6 +571,8 @@ static void do_nbd_request(struct reques +@@ -569,6 +571,8 @@ static void do_nbd_request(struct request_queue *q) static int __nbd_ioctl(struct block_device *bdev, struct nbd_device *lo= , unsigned int cmd, unsigned long arg) { @@ -29167,10 +30504,11 @@ diff -urNp linux-2.6.32.49/drivers/block/nbd.c = linux-2.6.32.49/drivers/block/nbd switch (cmd) { case NBD_DISCONNECT: { struct request sreq; -diff -urNp linux-2.6.32.49/drivers/block/pktcdvd.c linux-2.6.32.49/drive= rs/block/pktcdvd.c ---- linux-2.6.32.49/drivers/block/pktcdvd.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/block/pktcdvd.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -284,7 +284,7 @@ static ssize_t kobj_pkt_store(struct kob +diff --git a/drivers/block/pktcdvd.c b/drivers/block/pktcdvd.c +index a5d585d..d087be3 100644 +--- a/drivers/block/pktcdvd.c ++++ b/drivers/block/pktcdvd.c +@@ -284,7 +284,7 @@ static ssize_t kobj_pkt_store(struct kobject *kobj, return len; } =20 @@ -29179,10 +30517,33 @@ diff -urNp linux-2.6.32.49/drivers/block/pktcdv= d.c linux-2.6.32.49/drivers/block .show =3D kobj_pkt_show, .store =3D kobj_pkt_store }; -diff -urNp linux-2.6.32.49/drivers/char/agp/frontend.c linux-2.6.32.49/d= rivers/char/agp/frontend.c ---- linux-2.6.32.49/drivers/char/agp/frontend.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/char/agp/frontend.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -824,7 +824,7 @@ static int agpioc_reserve_wrap(struct ag +diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig +index 6aad99e..89cd142 100644 +--- a/drivers/char/Kconfig ++++ b/drivers/char/Kconfig +@@ -90,7 +90,8 @@ config VT_HW_CONSOLE_BINDING +=20 + config DEVKMEM + bool "/dev/kmem virtual device support" +- default y ++ default n ++ depends on !GRKERNSEC_KMEM + help + Say Y here if you want to support the /dev/kmem device. The + /dev/kmem device is rarely used, but can be used for certain +@@ -1114,6 +1115,7 @@ config DEVPORT + bool + depends on !M68K + depends on ISA || PCI ++ depends on !GRKERNSEC_KMEM + default y +=20 + source "drivers/s390/char/Kconfig" +diff --git a/drivers/char/agp/frontend.c b/drivers/char/agp/frontend.c +index a96f319..a778a5b 100644 +--- a/drivers/char/agp/frontend.c ++++ b/drivers/char/agp/frontend.c +@@ -824,7 +824,7 @@ static int agpioc_reserve_wrap(struct agp_file_priva= te *priv, void __user *arg) if (copy_from_user(&reserve, arg, sizeof(struct agp_region))) return -EFAULT; =20 @@ -29191,9 +30552,10 @@ diff -urNp linux-2.6.32.49/drivers/char/agp/fron= tend.c linux-2.6.32.49/drivers/c return -EFAULT; =20 client =3D agp_find_client_by_pid(reserve.pid); -diff -urNp linux-2.6.32.49/drivers/char/briq_panel.c linux-2.6.32.49/dri= vers/char/briq_panel.c ---- linux-2.6.32.49/drivers/char/briq_panel.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/char/briq_panel.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/char/briq_panel.c b/drivers/char/briq_panel.c +index d8cff90..9628e70 100644 +--- a/drivers/char/briq_panel.c ++++ b/drivers/char/briq_panel.c @@ -10,6 +10,7 @@ #include #include @@ -29210,7 +30572,7 @@ diff -urNp linux-2.6.32.49/drivers/char/briq_pane= l.c linux-2.6.32.49/drivers/cha =20 static void update_vfd(void) { -@@ -142,12 +144,15 @@ static ssize_t briq_panel_write(struct f +@@ -142,12 +144,15 @@ static ssize_t briq_panel_write(struct file *file,= const char __user *buf, size_ if (!vfd_is_open) return -EBUSY; =20 @@ -29227,7 +30589,7 @@ diff -urNp linux-2.6.32.49/drivers/char/briq_pane= l.c linux-2.6.32.49/drivers/cha if (esc) { set_led(c); esc =3D 0; -@@ -177,6 +182,7 @@ static ssize_t briq_panel_write(struct f +@@ -177,6 +182,7 @@ static ssize_t briq_panel_write(struct file *file, c= onst char __user *buf, size_ buf++; } update_vfd(); @@ -29235,10 +30597,11 @@ diff -urNp linux-2.6.32.49/drivers/char/briq_pa= nel.c linux-2.6.32.49/drivers/cha =20 return len; } -diff -urNp linux-2.6.32.49/drivers/char/genrtc.c linux-2.6.32.49/drivers= /char/genrtc.c ---- linux-2.6.32.49/drivers/char/genrtc.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/char/genrtc.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -272,6 +272,7 @@ static int gen_rtc_ioctl(struct inode *i +diff --git a/drivers/char/genrtc.c b/drivers/char/genrtc.c +index 31e7c91..161afc0 100644 +--- a/drivers/char/genrtc.c ++++ b/drivers/char/genrtc.c +@@ -272,6 +272,7 @@ static int gen_rtc_ioctl(struct inode *inode, struct= file *file, switch (cmd) { =20 case RTC_PLL_GET: @@ -29246,10 +30609,11 @@ diff -urNp linux-2.6.32.49/drivers/char/genrtc.= c linux-2.6.32.49/drivers/char/ge if (get_rtc_pll(&pll)) return -EINVAL; else -diff -urNp linux-2.6.32.49/drivers/char/hpet.c linux-2.6.32.49/drivers/c= har/hpet.c ---- linux-2.6.32.49/drivers/char/hpet.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/char/hpet.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -430,7 +430,7 @@ static int hpet_release(struct inode *in +diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c +index 006466d..a2bb21c 100644 +--- a/drivers/char/hpet.c ++++ b/drivers/char/hpet.c +@@ -430,7 +430,7 @@ static int hpet_release(struct inode *inode, struct = file *file) return 0; } =20 @@ -29258,7 +30622,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hpet.c li= nux-2.6.32.49/drivers/char/hpet =20 static int hpet_ioctl(struct inode *inode, struct file *file, unsigned int cmd, -@@ -565,7 +565,7 @@ static inline unsigned long hpet_time_di +@@ -565,7 +565,7 @@ static inline unsigned long hpet_time_div(struct hpe= ts *hpets, } =20 static int @@ -29267,7 +30631,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hpet.c li= nux-2.6.32.49/drivers/char/hpet { struct hpet_timer __iomem *timer; struct hpet __iomem *hpet; -@@ -608,11 +608,11 @@ hpet_ioctl_common(struct hpet_dev *devp, +@@ -608,11 +608,11 @@ hpet_ioctl_common(struct hpet_dev *devp, int cmd, = unsigned long arg, int kernel) { struct hpet_info info; =20 @@ -29281,10 +30645,11 @@ diff -urNp linux-2.6.32.49/drivers/char/hpet.c = linux-2.6.32.49/drivers/char/hpet info.hi_flags =3D readq(&timer->hpet_config) & Tn_PER_INT_CAP_MASK; info.hi_hpet =3D hpetp->hp_which; -diff -urNp linux-2.6.32.49/drivers/char/hvc_beat.c linux-2.6.32.49/drive= rs/char/hvc_beat.c ---- linux-2.6.32.49/drivers/char/hvc_beat.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/char/hvc_beat.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -84,7 +84,7 @@ static int hvc_beat_put_chars(uint32_t v +diff --git a/drivers/char/hvc_beat.c b/drivers/char/hvc_beat.c +index 0afc8b8..6913fc3 100644 +--- a/drivers/char/hvc_beat.c ++++ b/drivers/char/hvc_beat.c +@@ -84,7 +84,7 @@ static int hvc_beat_put_chars(uint32_t vtermno, const = char *buf, int cnt) return cnt; } =20 @@ -29293,10 +30658,11 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_bea= t.c linux-2.6.32.49/drivers/char/ .get_chars =3D hvc_beat_get_chars, .put_chars =3D hvc_beat_put_chars, }; -diff -urNp linux-2.6.32.49/drivers/char/hvc_console.c linux-2.6.32.49/dr= ivers/char/hvc_console.c ---- linux-2.6.32.49/drivers/char/hvc_console.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/char/hvc_console.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -125,7 +125,7 @@ static struct hvc_struct *hvc_get_by_ind +diff --git a/drivers/char/hvc_console.c b/drivers/char/hvc_console.c +index 98097f2..407dddc 100644 +--- a/drivers/char/hvc_console.c ++++ b/drivers/char/hvc_console.c +@@ -125,7 +125,7 @@ static struct hvc_struct *hvc_get_by_index(int index= ) * console interfaces but can still be used as a tty device. This has = to be * static because kmalloc will not work during early console init. */ @@ -29305,7 +30671,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_conso= le.c linux-2.6.32.49/drivers/ch static uint32_t vtermnos[MAX_NR_HVC_CONSOLES] =3D {[0 ... MAX_NR_HVC_CONSOLES - 1] =3D -1}; =20 -@@ -249,7 +249,7 @@ static void destroy_hvc_struct(struct kr +@@ -249,7 +249,7 @@ static void destroy_hvc_struct(struct kref *kref) * vty adapters do NOT get an hvc_instantiate() callback since they * appear after early console init. */ @@ -29314,7 +30680,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_conso= le.c linux-2.6.32.49/drivers/ch { struct hvc_struct *hp; =20 -@@ -758,7 +758,7 @@ static const struct tty_operations hvc_o +@@ -758,7 +758,7 @@ static const struct tty_operations hvc_ops =3D { }; =20 struct hvc_struct __devinit *hvc_alloc(uint32_t vtermno, int data, @@ -29323,9 +30689,10 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_cons= ole.c linux-2.6.32.49/drivers/ch { struct hvc_struct *hp; int i; -diff -urNp linux-2.6.32.49/drivers/char/hvc_console.h linux-2.6.32.49/dr= ivers/char/hvc_console.h ---- linux-2.6.32.49/drivers/char/hvc_console.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/char/hvc_console.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/drivers/char/hvc_console.h b/drivers/char/hvc_console.h +index 10950ca..ed176c3 100644 +--- a/drivers/char/hvc_console.h ++++ b/drivers/char/hvc_console.h @@ -55,7 +55,7 @@ struct hvc_struct { int outbuf_size; int n_outbuf; @@ -29349,9 +30716,10 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_cons= ole.h linux-2.6.32.49/drivers/ch /* remove a vterm from hvc tty operation (module_exit or hotplug remove= ) */ extern int hvc_remove(struct hvc_struct *hp); =20 -diff -urNp linux-2.6.32.49/drivers/char/hvc_iseries.c linux-2.6.32.49/dr= ivers/char/hvc_iseries.c ---- linux-2.6.32.49/drivers/char/hvc_iseries.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/char/hvc_iseries.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/drivers/char/hvc_iseries.c b/drivers/char/hvc_iseries.c +index 936d05b..fd02426 100644 +--- a/drivers/char/hvc_iseries.c ++++ b/drivers/char/hvc_iseries.c @@ -197,7 +197,7 @@ done: return sent; } @@ -29361,10 +30729,11 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_ise= ries.c linux-2.6.32.49/drivers/ch .get_chars =3D get_chars, .put_chars =3D put_chars, .notifier_add =3D notifier_add_irq, -diff -urNp linux-2.6.32.49/drivers/char/hvc_iucv.c linux-2.6.32.49/drive= rs/char/hvc_iucv.c ---- linux-2.6.32.49/drivers/char/hvc_iucv.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/char/hvc_iucv.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -924,7 +924,7 @@ static int hvc_iucv_pm_restore_thaw(stru +diff --git a/drivers/char/hvc_iucv.c b/drivers/char/hvc_iucv.c +index b0e168f..69cda2a 100644 +--- a/drivers/char/hvc_iucv.c ++++ b/drivers/char/hvc_iucv.c +@@ -924,7 +924,7 @@ static int hvc_iucv_pm_restore_thaw(struct device *d= ev) =20 =20 /* HVC operations */ @@ -29373,10 +30742,11 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_iuc= v.c linux-2.6.32.49/drivers/char/ .get_chars =3D hvc_iucv_get_chars, .put_chars =3D hvc_iucv_put_chars, .notifier_add =3D hvc_iucv_notifier_add, -diff -urNp linux-2.6.32.49/drivers/char/hvc_rtas.c linux-2.6.32.49/drive= rs/char/hvc_rtas.c ---- linux-2.6.32.49/drivers/char/hvc_rtas.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/char/hvc_rtas.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -71,7 +71,7 @@ static int hvc_rtas_read_console(uint32_ +diff --git a/drivers/char/hvc_rtas.c b/drivers/char/hvc_rtas.c +index 88590d0..61c4a61 100644 +--- a/drivers/char/hvc_rtas.c ++++ b/drivers/char/hvc_rtas.c +@@ -71,7 +71,7 @@ static int hvc_rtas_read_console(uint32_t vtermno, cha= r *buf, int count) return i; } =20 @@ -29385,9 +30755,49 @@ diff -urNp linux-2.6.32.49/drivers/char/hvc_rtas= .c linux-2.6.32.49/drivers/char/ .get_chars =3D hvc_rtas_read_console, .put_chars =3D hvc_rtas_write_console, }; -diff -urNp linux-2.6.32.49/drivers/char/hvcs.c linux-2.6.32.49/drivers/c= har/hvcs.c ---- linux-2.6.32.49/drivers/char/hvcs.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/char/hvcs.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/drivers/char/hvc_udbg.c b/drivers/char/hvc_udbg.c +index bd63ba8..b0957e6 100644 +--- a/drivers/char/hvc_udbg.c ++++ b/drivers/char/hvc_udbg.c +@@ -58,7 +58,7 @@ static int hvc_udbg_get(uint32_t vtermno, char *buf, i= nt count) + return i; + } +=20 +-static struct hv_ops hvc_udbg_ops =3D { ++static const struct hv_ops hvc_udbg_ops =3D { + .get_chars =3D hvc_udbg_get, + .put_chars =3D hvc_udbg_put, + }; +diff --git a/drivers/char/hvc_vio.c b/drivers/char/hvc_vio.c +index 10be343..27370e9 100644 +--- a/drivers/char/hvc_vio.c ++++ b/drivers/char/hvc_vio.c +@@ -77,7 +77,7 @@ static int filtered_get_chars(uint32_t vtermno, char *= buf, int count) + return got; + } +=20 +-static struct hv_ops hvc_get_put_ops =3D { ++static const struct hv_ops hvc_get_put_ops =3D { + .get_chars =3D filtered_get_chars, + .put_chars =3D hvc_put_chars, + .notifier_add =3D notifier_add_irq, +diff --git a/drivers/char/hvc_xen.c b/drivers/char/hvc_xen.c +index a6ee32b..94f8c26 100644 +--- a/drivers/char/hvc_xen.c ++++ b/drivers/char/hvc_xen.c +@@ -120,7 +120,7 @@ static int read_console(uint32_t vtermno, char *buf,= int len) + return recv; + } +=20 +-static struct hv_ops hvc_ops =3D { ++static const struct hv_ops hvc_ops =3D { + .get_chars =3D read_console, + .put_chars =3D write_console, + .notifier_add =3D notifier_add_irq, +diff --git a/drivers/char/hvcs.c b/drivers/char/hvcs.c +index 266b858..f3ee0bb 100644 +--- a/drivers/char/hvcs.c ++++ b/drivers/char/hvcs.c @@ -82,6 +82,7 @@ #include #include @@ -29405,7 +30815,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs =20 /* * Used to tell the driver kernel_thread what operations need to take -@@ -419,7 +420,7 @@ static ssize_t hvcs_vterm_state_store(st +@@ -419,7 +420,7 @@ static ssize_t hvcs_vterm_state_store(struct device = *dev, struct device_attribut =20 spin_lock_irqsave(&hvcsd->lock, flags); =20 @@ -29414,7 +30824,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs spin_unlock_irqrestore(&hvcsd->lock, flags); printk(KERN_INFO "HVCS: vterm state unchanged. " "The hvcs device node is still in use.\n"); -@@ -1135,7 +1136,7 @@ static int hvcs_open(struct tty_struct * +@@ -1135,7 +1136,7 @@ static int hvcs_open(struct tty_struct *tty, struc= t file *filp) if ((retval =3D hvcs_partner_connect(hvcsd))) goto error_release; =20 @@ -29432,7 +30842,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs hvcsd->todo_mask |=3D HVCS_SCHED_READ; spin_unlock_irqrestore(&hvcsd->lock, flags); =20 -@@ -1213,7 +1214,7 @@ static void hvcs_close(struct tty_struct +@@ -1213,7 +1214,7 @@ static void hvcs_close(struct tty_struct *tty, str= uct file *filp) hvcsd =3D tty->driver_data; =20 spin_lock_irqsave(&hvcsd->lock, flags); @@ -29441,7 +30851,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs =20 vio_disable_interrupts(hvcsd->vdev); =20 -@@ -1239,10 +1240,10 @@ static void hvcs_close(struct tty_struct +@@ -1239,10 +1240,10 @@ static void hvcs_close(struct tty_struct *tty, s= truct file *filp) free_irq(irq, hvcsd); kref_put(&hvcsd->kref, destroy_hvcs_struct); return; @@ -29454,7 +30864,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs } =20 spin_unlock_irqrestore(&hvcsd->lock, flags); -@@ -1258,7 +1259,7 @@ static void hvcs_hangup(struct tty_struc +@@ -1258,7 +1259,7 @@ static void hvcs_hangup(struct tty_struct * tty) =20 spin_lock_irqsave(&hvcsd->lock, flags); /* Preserve this so that we know how many kref refs to put */ @@ -29463,7 +30873,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs =20 /* * Don't kref put inside the spinlock because the destruction -@@ -1273,7 +1274,7 @@ static void hvcs_hangup(struct tty_struc +@@ -1273,7 +1274,7 @@ static void hvcs_hangup(struct tty_struct * tty) hvcsd->tty->driver_data =3D NULL; hvcsd->tty =3D NULL; =20 @@ -29472,7 +30882,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs =20 /* This will drop any buffered data on the floor which is OK in a hang= up * scenario. */ -@@ -1344,7 +1345,7 @@ static int hvcs_write(struct tty_struct=20 +@@ -1344,7 +1345,7 @@ static int hvcs_write(struct tty_struct *tty, * the middle of a write operation? This is a crummy place to do this * but we want to keep it all in the spinlock. */ @@ -29481,7 +30891,7 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c li= nux-2.6.32.49/drivers/char/hvcs spin_unlock_irqrestore(&hvcsd->lock, flags); return -ENODEV; } -@@ -1418,7 +1419,7 @@ static int hvcs_write_room(struct tty_st +@@ -1418,7 +1419,7 @@ static int hvcs_write_room(struct tty_struct *tty) { struct hvcs_struct *hvcsd =3D tty->driver_data; =20 @@ -29490,45 +30900,10 @@ diff -urNp linux-2.6.32.49/drivers/char/hvcs.c = linux-2.6.32.49/drivers/char/hvcs return 0; =20 return HVCS_BUFF_LEN - hvcsd->chars_in_buffer; -diff -urNp linux-2.6.32.49/drivers/char/hvc_udbg.c linux-2.6.32.49/drive= rs/char/hvc_udbg.c ---- linux-2.6.32.49/drivers/char/hvc_udbg.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/char/hvc_udbg.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -58,7 +58,7 @@ static int hvc_udbg_get(uint32_t vtermno - return i; - } -=20 --static struct hv_ops hvc_udbg_ops =3D { -+static const struct hv_ops hvc_udbg_ops =3D { - .get_chars =3D hvc_udbg_get, - .put_chars =3D hvc_udbg_put, - }; -diff -urNp linux-2.6.32.49/drivers/char/hvc_vio.c linux-2.6.32.49/driver= s/char/hvc_vio.c ---- linux-2.6.32.49/drivers/char/hvc_vio.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/char/hvc_vio.c 2011-11-15 19:59:43.000000000= -0500 -@@ -77,7 +77,7 @@ static int filtered_get_chars(uint32_t v - return got; - } -=20 --static struct hv_ops hvc_get_put_ops =3D { -+static const struct hv_ops hvc_get_put_ops =3D { - .get_chars =3D filtered_get_chars, - .put_chars =3D hvc_put_chars, - .notifier_add =3D notifier_add_irq, -diff -urNp linux-2.6.32.49/drivers/char/hvc_xen.c linux-2.6.32.49/driver= s/char/hvc_xen.c ---- linux-2.6.32.49/drivers/char/hvc_xen.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/char/hvc_xen.c 2011-11-15 19:59:43.000000000= -0500 -@@ -120,7 +120,7 @@ static int read_console(uint32_t vtermno - return recv; - } -=20 --static struct hv_ops hvc_ops =3D { -+static const struct hv_ops hvc_ops =3D { - .get_chars =3D read_console, - .put_chars =3D write_console, - .notifier_add =3D notifier_add_irq, -diff -urNp linux-2.6.32.49/drivers/char/ipmi/ipmi_msghandler.c linux-2.6= .32.49/drivers/char/ipmi/ipmi_msghandler.c ---- linux-2.6.32.49/drivers/char/ipmi/ipmi_msghandler.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/char/ipmi/ipmi_msghandler.c 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/drivers/char/ipmi/ipmi_msghandler.c b/drivers/char/ipmi/ipm= i_msghandler.c +index ec5e3f8..02455ba 100644 +--- a/drivers/char/ipmi/ipmi_msghandler.c ++++ b/drivers/char/ipmi/ipmi_msghandler.c @@ -414,7 +414,7 @@ struct ipmi_smi { struct proc_dir_entry *proc_dir; char proc_dir_name[10]; @@ -29550,7 +30925,7 @@ diff -urNp linux-2.6.32.49/drivers/char/ipmi/ipmi= _msghandler.c linux-2.6.32.49/d =20 static int is_lan_addr(struct ipmi_addr *addr) { -@@ -2808,7 +2808,7 @@ int ipmi_register_smi(struct ipmi_smi_ha +@@ -2808,7 +2808,7 @@ int ipmi_register_smi(struct ipmi_smi_handlers *ha= ndlers, INIT_LIST_HEAD(&intf->cmd_rcvrs); init_waitqueue_head(&intf->waitq); for (i =3D 0; i < IPMI_NUM_STATS; i++) @@ -29568,9 +30943,10 @@ diff -urNp linux-2.6.32.49/drivers/char/ipmi/ipm= i_msghandler.c linux-2.6.32.49/d si =3D (struct ipmi_system_interface_addr *) &addr; si->addr_type =3D IPMI_SYSTEM_INTERFACE_ADDR_TYPE; si->channel =3D IPMI_BMC_CHANNEL; -diff -urNp linux-2.6.32.49/drivers/char/ipmi/ipmi_si_intf.c linux-2.6.32= .49/drivers/char/ipmi/ipmi_si_intf.c ---- linux-2.6.32.49/drivers/char/ipmi/ipmi_si_intf.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/char/ipmi/ipmi_si_intf.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_s= i_intf.c +index abae8c9..8021979 100644 +--- a/drivers/char/ipmi/ipmi_si_intf.c ++++ b/drivers/char/ipmi/ipmi_si_intf.c @@ -277,7 +277,7 @@ struct smi_info { unsigned char slave_addr; =20 @@ -29592,7 +30968,7 @@ diff -urNp linux-2.6.32.49/drivers/char/ipmi/ipmi= _si_intf.c linux-2.6.32.49/driv =20 #define SI_MAX_PARMS 4 =20 -@@ -2931,7 +2931,7 @@ static int try_smi_init(struct smi_info=20 +@@ -2931,7 +2931,7 @@ static int try_smi_init(struct smi_info *new_smi) atomic_set(&new_smi->req_events, 0); new_smi->run_to_completion =3D 0; for (i =3D 0; i < SI_NUM_STATS; i++) @@ -29601,10 +30977,11 @@ diff -urNp linux-2.6.32.49/drivers/char/ipmi/ip= mi_si_intf.c linux-2.6.32.49/driv =20 new_smi->interrupt_disabled =3D 0; atomic_set(&new_smi->stop_operation, 0); -diff -urNp linux-2.6.32.49/drivers/char/istallion.c linux-2.6.32.49/driv= ers/char/istallion.c ---- linux-2.6.32.49/drivers/char/istallion.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/char/istallion.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -187,7 +187,6 @@ static struct ktermios stli_deftermios=20 +diff --git a/drivers/char/istallion.c b/drivers/char/istallion.c +index 402838f..55e2200 100644 +--- a/drivers/char/istallion.c ++++ b/drivers/char/istallion.c +@@ -187,7 +187,6 @@ static struct ktermios stli_deftermios =3D { * re-used for each stats call. */ static comstats_t stli_comstats; @@ -29612,7 +30989,7 @@ diff -urNp linux-2.6.32.49/drivers/char/istallion= .c linux-2.6.32.49/drivers/char static struct asystats stli_cdkstats; =20 /**********************************************************************= *******/ -@@ -4058,6 +4057,7 @@ static int stli_getbrdstats(combrd_t __u +@@ -4058,6 +4057,7 @@ static int stli_getbrdstats(combrd_t __user *bp) { struct stlibrd *brdp; unsigned int i; @@ -29620,7 +30997,7 @@ diff -urNp linux-2.6.32.49/drivers/char/istallion= .c linux-2.6.32.49/drivers/char =20 if (copy_from_user(&stli_brdstats, bp, sizeof(combrd_t))) return -EFAULT; -@@ -4269,6 +4269,8 @@ static int stli_getportstruct(struct stl +@@ -4269,6 +4269,8 @@ static int stli_getportstruct(struct stliport __us= er *arg) struct stliport stli_dummyport; struct stliport *portp; =20 @@ -29629,7 +31006,7 @@ diff -urNp linux-2.6.32.49/drivers/char/istallion= .c linux-2.6.32.49/drivers/char if (copy_from_user(&stli_dummyport, arg, sizeof(struct stliport))) return -EFAULT; portp =3D stli_getport(stli_dummyport.brdnr, stli_dummyport.panelnr, -@@ -4291,6 +4293,8 @@ static int stli_getbrdstruct(struct stli +@@ -4291,6 +4293,8 @@ static int stli_getbrdstruct(struct stlibrd __user= *arg) struct stlibrd stli_dummybrd; struct stlibrd *brdp; =20 @@ -29638,31 +31015,11 @@ diff -urNp linux-2.6.32.49/drivers/char/istalli= on.c linux-2.6.32.49/drivers/char if (copy_from_user(&stli_dummybrd, arg, sizeof(struct stlibrd))) return -EFAULT; if (stli_dummybrd.brdnr >=3D STL_MAXBRDS) -diff -urNp linux-2.6.32.49/drivers/char/Kconfig linux-2.6.32.49/drivers/= char/Kconfig ---- linux-2.6.32.49/drivers/char/Kconfig 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/char/Kconfig 2011-11-15 19:59:43.000000000 -= 0500 -@@ -90,7 +90,8 @@ config VT_HW_CONSOLE_BINDING -=20 - config DEVKMEM - bool "/dev/kmem virtual device support" -- default y -+ default n -+ depends on !GRKERNSEC_KMEM - help - Say Y here if you want to support the /dev/kmem device. The - /dev/kmem device is rarely used, but can be used for certain -@@ -1114,6 +1115,7 @@ config DEVPORT - bool - depends on !M68K - depends on ISA || PCI -+ depends on !GRKERNSEC_KMEM - default y -=20 - source "drivers/s390/char/Kconfig" -diff -urNp linux-2.6.32.49/drivers/char/keyboard.c linux-2.6.32.49/drive= rs/char/keyboard.c ---- linux-2.6.32.49/drivers/char/keyboard.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/char/keyboard.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -635,6 +635,16 @@ static void k_spec(struct vc_data *vc, u +diff --git a/drivers/char/keyboard.c b/drivers/char/keyboard.c +index 950837c..e55a288 100644 +--- a/drivers/char/keyboard.c ++++ b/drivers/char/keyboard.c +@@ -635,6 +635,16 @@ static void k_spec(struct vc_data *vc, unsigned cha= r value, char up_flag) kbd->kbdmode =3D=3D VC_MEDIUMRAW) && value !=3D KVAL(K_SAK)) return; /* SAK is allowed even in raw mode */ @@ -29679,7 +31036,7 @@ diff -urNp linux-2.6.32.49/drivers/char/keyboard.= c linux-2.6.32.49/drivers/char/ fn_handler[value](vc); } =20 -@@ -1386,7 +1396,7 @@ static const struct input_device_id kbd_ +@@ -1386,7 +1396,7 @@ static const struct input_device_id kbd_ids[] =3D = { .evbit =3D { BIT_MASK(EV_SND) }, }, =20 @@ -29688,10 +31045,11 @@ diff -urNp linux-2.6.32.49/drivers/char/keyboar= d.c linux-2.6.32.49/drivers/char/ }; =20 MODULE_DEVICE_TABLE(input, kbd_ids); -diff -urNp linux-2.6.32.49/drivers/char/mbcs.c linux-2.6.32.49/drivers/c= har/mbcs.c ---- linux-2.6.32.49/drivers/char/mbcs.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/char/mbcs.c 2011-11-18 18:01:55.000000000 -0= 500 -@@ -799,7 +799,7 @@ static int mbcs_remove(struct cx_dev *de +diff --git a/drivers/char/mbcs.c b/drivers/char/mbcs.c +index 87c67b4..230527a 100644 +--- a/drivers/char/mbcs.c ++++ b/drivers/char/mbcs.c +@@ -799,7 +799,7 @@ static int mbcs_remove(struct cx_dev *dev) return 0; } =20 @@ -29700,9 +31058,10 @@ diff -urNp linux-2.6.32.49/drivers/char/mbcs.c l= inux-2.6.32.49/drivers/char/mbcs { .part_num =3D MBCS_PART_NUM, .mfg_num =3D MBCS_MFG_NUM, -diff -urNp linux-2.6.32.49/drivers/char/mem.c linux-2.6.32.49/drivers/ch= ar/mem.c ---- linux-2.6.32.49/drivers/char/mem.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/char/mem.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/drivers/char/mem.c b/drivers/char/mem.c +index 1270f64..8495f49 100644 +--- a/drivers/char/mem.c ++++ b/drivers/char/mem.c @@ -18,6 +18,7 @@ #include #include @@ -29722,7 +31081,7 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c lin= ux-2.6.32.49/drivers/char/mem.c static inline unsigned long size_inside_page(unsigned long start, unsigned long size) { -@@ -102,9 +107,13 @@ static inline int range_is_allowed(unsig +@@ -102,9 +107,13 @@ static inline int range_is_allowed(unsigned long pf= n, unsigned long size) =20 while (cursor < to) { if (!devmem_is_allowed(pfn)) { @@ -29736,7 +31095,7 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c lin= ux-2.6.32.49/drivers/char/mem.c return 0; } cursor +=3D PAGE_SIZE; -@@ -112,6 +121,11 @@ static inline int range_is_allowed(unsig +@@ -112,6 +121,11 @@ static inline int range_is_allowed(unsigned long pf= n, unsigned long size) } return 1; } @@ -29748,7 +31107,7 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c lin= ux-2.6.32.49/drivers/char/mem.c #else static inline int range_is_allowed(unsigned long pfn, unsigned long siz= e) { -@@ -155,6 +169,8 @@ static ssize_t read_mem(struct file * fi +@@ -155,6 +169,8 @@ static ssize_t read_mem(struct file * file, char __u= ser * buf, #endif =20 while (count > 0) { @@ -29757,7 +31116,7 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c lin= ux-2.6.32.49/drivers/char/mem.c /* * Handle first page in case it's not aligned */ -@@ -177,11 +193,31 @@ static ssize_t read_mem(struct file * fi +@@ -177,11 +193,31 @@ static ssize_t read_mem(struct file * file, char _= _user * buf, if (!ptr) return -EFAULT; =20 @@ -29790,7 +31149,7 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c lin= ux-2.6.32.49/drivers/char/mem.c unxlate_dev_mem_ptr(p, ptr); =20 buf +=3D sz; -@@ -419,9 +455,8 @@ static ssize_t read_kmem(struct file *fi +@@ -419,9 +455,8 @@ static ssize_t read_kmem(struct file *file, char __u= ser *buf, size_t count, loff_t *ppos) { unsigned long p =3D *ppos; @@ -29801,7 +31160,7 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c lin= ux-2.6.32.49/drivers/char/mem.c =20 read =3D 0; if (p < (unsigned long) high_memory) { -@@ -444,6 +479,8 @@ static ssize_t read_kmem(struct file *fi +@@ -444,6 +479,8 @@ static ssize_t read_kmem(struct file *file, char __u= ser *buf, } #endif while (low_count > 0) { @@ -29810,7 +31169,7 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c lin= ux-2.6.32.49/drivers/char/mem.c sz =3D size_inside_page(p, low_count); =20 /* -@@ -453,7 +490,22 @@ static ssize_t read_kmem(struct file *fi +@@ -453,7 +490,22 @@ static ssize_t read_kmem(struct file *file, char __= user *buf, */ kbuf =3D xlate_dev_kmem_ptr((char *)p); =20 @@ -29844,9 +31203,10 @@ diff -urNp linux-2.6.32.49/drivers/char/mem.c li= nux-2.6.32.49/drivers/char/mem.c }; =20 static int memory_open(struct inode *inode, struct file *filp) -diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ipwireless/tty.c linux-2.= 6.32.49/drivers/char/pcmcia/ipwireless/tty.c ---- linux-2.6.32.49/drivers/char/pcmcia/ipwireless/tty.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/char/pcmcia/ipwireless/tty.c 2011-11-15 19:5= 9:43.000000000 -0500 +diff --git a/drivers/char/pcmcia/ipwireless/tty.c b/drivers/char/pcmcia/= ipwireless/tty.c +index 674b3ab..a8d1970 100644 +--- a/drivers/char/pcmcia/ipwireless/tty.c ++++ b/drivers/char/pcmcia/ipwireless/tty.c @@ -29,6 +29,7 @@ #include #include @@ -29864,7 +31224,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ unsigned int control_lines; struct mutex ipw_tty_mutex; int tx_bytes_queued; -@@ -127,10 +128,10 @@ static int ipw_open(struct tty_struct *l +@@ -127,10 +128,10 @@ static int ipw_open(struct tty_struct *linux_tty, = struct file *filp) mutex_unlock(&tty->ipw_tty_mutex); return -ENODEV; } @@ -29877,7 +31237,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ =20 tty->linux_tty =3D linux_tty; linux_tty->driver_data =3D tty; -@@ -146,9 +147,7 @@ static int ipw_open(struct tty_struct *l +@@ -146,9 +147,7 @@ static int ipw_open(struct tty_struct *linux_tty, st= ruct file *filp) =20 static void do_ipw_close(struct ipw_tty *tty) { @@ -29888,7 +31248,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ struct tty_struct *linux_tty =3D tty->linux_tty; =20 if (linux_tty !=3D NULL) { -@@ -169,7 +168,7 @@ static void ipw_hangup(struct tty_struct +@@ -169,7 +168,7 @@ static void ipw_hangup(struct tty_struct *linux_tty) return; =20 mutex_lock(&tty->ipw_tty_mutex); @@ -29897,7 +31257,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ mutex_unlock(&tty->ipw_tty_mutex); return; } -@@ -198,7 +197,7 @@ void ipwireless_tty_received(struct ipw_ +@@ -198,7 +197,7 @@ void ipwireless_tty_received(struct ipw_tty *tty, un= signed char *data, return; } =20 @@ -29906,7 +31266,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ mutex_unlock(&tty->ipw_tty_mutex); return; } -@@ -240,7 +239,7 @@ static int ipw_write(struct tty_struct * +@@ -240,7 +239,7 @@ static int ipw_write(struct tty_struct *linux_tty, return -ENODEV; =20 mutex_lock(&tty->ipw_tty_mutex); @@ -29915,7 +31275,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ mutex_unlock(&tty->ipw_tty_mutex); return -EINVAL; } -@@ -280,7 +279,7 @@ static int ipw_write_room(struct tty_str +@@ -280,7 +279,7 @@ static int ipw_write_room(struct tty_struct *linux_t= ty) if (!tty) return -ENODEV; =20 @@ -29924,7 +31284,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ return -EINVAL; =20 room =3D IPWIRELESS_TX_QUEUE_SIZE - tty->tx_bytes_queued; -@@ -322,7 +321,7 @@ static int ipw_chars_in_buffer(struct tt +@@ -322,7 +321,7 @@ static int ipw_chars_in_buffer(struct tty_struct *li= nux_tty) if (!tty) return 0; =20 @@ -29933,7 +31293,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ return 0; =20 return tty->tx_bytes_queued; -@@ -403,7 +402,7 @@ static int ipw_tiocmget(struct tty_struc +@@ -403,7 +402,7 @@ static int ipw_tiocmget(struct tty_struct *linux_tty= , struct file *file) if (!tty) return -ENODEV; =20 @@ -29942,7 +31302,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ return -EINVAL; =20 return get_control_lines(tty); -@@ -419,7 +418,7 @@ ipw_tiocmset(struct tty_struct *linux_tt +@@ -419,7 +418,7 @@ ipw_tiocmset(struct tty_struct *linux_tty, struct fi= le *file, if (!tty) return -ENODEV; =20 @@ -29951,7 +31311,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ return -EINVAL; =20 return set_control_lines(tty, set, clear); -@@ -433,7 +432,7 @@ static int ipw_ioctl(struct tty_struct * +@@ -433,7 +432,7 @@ static int ipw_ioctl(struct tty_struct *linux_tty, s= truct file *file, if (!tty) return -ENODEV; =20 @@ -29960,7 +31320,7 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/ip= wireless/tty.c linux-2.6.32.49/ return -EINVAL; =20 /* FIXME: Exactly how is the tty object locked here .. */ -@@ -591,7 +590,7 @@ void ipwireless_tty_free(struct ipw_tty=20 +@@ -591,7 +590,7 @@ void ipwireless_tty_free(struct ipw_tty *tty) against a parallel ioctl etc */ mutex_lock(&ttyj->ipw_tty_mutex); } @@ -29969,9 +31329,10 @@ diff -urNp linux-2.6.32.49/drivers/char/pcmcia/i= pwireless/tty.c linux-2.6.32.49/ do_ipw_close(ttyj); ipwireless_disassociate_network_ttys(network, ttyj->channel_idx); -diff -urNp linux-2.6.32.49/drivers/char/pty.c linux-2.6.32.49/drivers/ch= ar/pty.c ---- linux-2.6.32.49/drivers/char/pty.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/char/pty.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/drivers/char/pty.c b/drivers/char/pty.c +index 62f282e..e45c45c 100644 +--- a/drivers/char/pty.c ++++ b/drivers/char/pty.c @@ -736,8 +736,10 @@ static void __init unix98_pty_init(void) register_sysctl_table(pty_root_table); =20 @@ -29984,9 +31345,10 @@ diff -urNp linux-2.6.32.49/drivers/char/pty.c li= nux-2.6.32.49/drivers/char/pty.c =20 cdev_init(&ptmx_cdev, &ptmx_fops); if (cdev_add(&ptmx_cdev, MKDEV(TTYAUX_MAJOR, 2), 1) || -diff -urNp linux-2.6.32.49/drivers/char/random.c linux-2.6.32.49/drivers= /char/random.c ---- linux-2.6.32.49/drivers/char/random.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/char/random.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/char/random.c b/drivers/char/random.c +index 3a19e2d..6ed09d3 100644 +--- a/drivers/char/random.c ++++ b/drivers/char/random.c @@ -254,8 +254,13 @@ /* * Configuration information @@ -30028,10 +31390,11 @@ diff -urNp linux-2.6.32.49/drivers/char/random.= c linux-2.6.32.49/drivers/char/ra static int max_write_thresh =3D INPUT_POOL_WORDS * 32; static char sysctl_bootid[16]; =20 -diff -urNp linux-2.6.32.49/drivers/char/rocket.c linux-2.6.32.49/drivers= /char/rocket.c ---- linux-2.6.32.49/drivers/char/rocket.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/char/rocket.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1266,6 +1266,8 @@ static int get_ports(struct r_port *info +diff --git a/drivers/char/rocket.c b/drivers/char/rocket.c +index 0e29a23..0efc2c2 100644 +--- a/drivers/char/rocket.c ++++ b/drivers/char/rocket.c +@@ -1266,6 +1266,8 @@ static int get_ports(struct r_port *info, struct r= ocket_ports __user *retports) struct rocket_ports tmp; int board; =20 @@ -30040,9 +31403,10 @@ diff -urNp linux-2.6.32.49/drivers/char/rocket.c= linux-2.6.32.49/drivers/char/ro if (!retports) return -EFAULT; memset(&tmp, 0, sizeof (tmp)); -diff -urNp linux-2.6.32.49/drivers/char/sonypi.c linux-2.6.32.49/drivers= /char/sonypi.c ---- linux-2.6.32.49/drivers/char/sonypi.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/char/sonypi.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/char/sonypi.c b/drivers/char/sonypi.c +index 8c262aa..4d3b058 100644 +--- a/drivers/char/sonypi.c ++++ b/drivers/char/sonypi.c @@ -55,6 +55,7 @@ #include #include @@ -30060,7 +31424,7 @@ diff -urNp linux-2.6.32.49/drivers/char/sonypi.c = linux-2.6.32.49/drivers/char/so int model; struct input_dev *input_jog_dev; struct input_dev *input_key_dev; -@@ -895,7 +896,7 @@ static int sonypi_misc_fasync(int fd, st +@@ -895,7 +896,7 @@ static int sonypi_misc_fasync(int fd, struct file *f= ilp, int on) static int sonypi_misc_release(struct inode *inode, struct file *file) { mutex_lock(&sonypi_device.lock); @@ -30069,7 +31433,7 @@ diff -urNp linux-2.6.32.49/drivers/char/sonypi.c = linux-2.6.32.49/drivers/char/so mutex_unlock(&sonypi_device.lock); return 0; } -@@ -905,9 +906,9 @@ static int sonypi_misc_open(struct inode +@@ -905,9 +906,9 @@ static int sonypi_misc_open(struct inode *inode, str= uct file *file) lock_kernel(); mutex_lock(&sonypi_device.lock); /* Flush input queue on first open */ @@ -30081,10 +31445,11 @@ diff -urNp linux-2.6.32.49/drivers/char/sonypi.= c linux-2.6.32.49/drivers/char/so mutex_unlock(&sonypi_device.lock); unlock_kernel(); return 0; -diff -urNp linux-2.6.32.49/drivers/char/stallion.c linux-2.6.32.49/drive= rs/char/stallion.c ---- linux-2.6.32.49/drivers/char/stallion.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/char/stallion.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -2448,6 +2448,8 @@ static int stl_getportstruct(struct stlp +diff --git a/drivers/char/stallion.c b/drivers/char/stallion.c +index db6dcfa..13834cb 100644 +--- a/drivers/char/stallion.c ++++ b/drivers/char/stallion.c +@@ -2448,6 +2448,8 @@ static int stl_getportstruct(struct stlport __user= *arg) struct stlport stl_dummyport; struct stlport *portp; =20 @@ -30093,10 +31458,33 @@ diff -urNp linux-2.6.32.49/drivers/char/stallio= n.c linux-2.6.32.49/drivers/char/ if (copy_from_user(&stl_dummyport, arg, sizeof(struct stlport))) return -EFAULT; portp =3D stl_getport(stl_dummyport.brdnr, stl_dummyport.panelnr, -diff -urNp linux-2.6.32.49/drivers/char/tpm/tpm_bios.c linux-2.6.32.49/d= rivers/char/tpm/tpm_bios.c ---- linux-2.6.32.49/drivers/char/tpm/tpm_bios.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/char/tpm/tpm_bios.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -172,7 +172,7 @@ static void *tpm_bios_measurements_start +diff --git a/drivers/char/tpm/tpm.c b/drivers/char/tpm/tpm.c +index a0789f6..cea3902 100644 +--- a/drivers/char/tpm/tpm.c ++++ b/drivers/char/tpm/tpm.c +@@ -405,7 +405,7 @@ static ssize_t tpm_transmit(struct tpm_chip *chip, c= onst char *buf, + chip->vendor.req_complete_val) + goto out_recv; +=20 +- if ((status =3D=3D chip->vendor.req_canceled)) { ++ if (status =3D=3D chip->vendor.req_canceled) { + dev_err(chip->dev, "Operation Canceled\n"); + rc =3D -ECANCELED; + goto out; +@@ -824,6 +824,8 @@ ssize_t tpm_show_pubek(struct device *dev, struct de= vice_attribute *attr, +=20 + struct tpm_chip *chip =3D dev_get_drvdata(dev); +=20 ++ pax_track_stack(); ++ + tpm_cmd.header.in =3D tpm_readpubek_header; + err =3D transmit_cmd(chip, &tpm_cmd, READ_PUBEK_RESULT_SIZE, + "attempting to read the PUBEK"); +diff --git a/drivers/char/tpm/tpm_bios.c b/drivers/char/tpm/tpm_bios.c +index bf2170f..ce8cab9 100644 +--- a/drivers/char/tpm/tpm_bios.c ++++ b/drivers/char/tpm/tpm_bios.c +@@ -172,7 +172,7 @@ static void *tpm_bios_measurements_start(struct seq_= file *m, loff_t *pos) event =3D addr; =20 if ((event->event_type =3D=3D 0 && event->event_size =3D=3D 0) || @@ -30105,7 +31493,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tpm/tpm_b= ios.c linux-2.6.32.49/drivers/c return NULL; =20 return addr; -@@ -197,7 +197,7 @@ static void *tpm_bios_measurements_next( +@@ -197,7 +197,7 @@ static void *tpm_bios_measurements_next(struct seq_f= ile *m, void *v, return NULL; =20 if ((event->event_type =3D=3D 0 && event->event_size =3D=3D 0) || @@ -30114,7 +31502,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tpm/tpm_b= ios.c linux-2.6.32.49/drivers/c return NULL; =20 (*pos)++; -@@ -290,7 +290,8 @@ static int tpm_binary_bios_measurements_ +@@ -290,7 +290,8 @@ static int tpm_binary_bios_measurements_show(struct = seq_file *m, void *v) int i; =20 for (i =3D 0; i < sizeof(struct tcpa_event) + event->event_size; i++) @@ -30124,7 +31512,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tpm/tpm_b= ios.c linux-2.6.32.49/drivers/c =20 return 0; } -@@ -409,8 +410,13 @@ static int read_log(struct tpm_bios_log=20 +@@ -409,8 +410,13 @@ static int read_log(struct tpm_bios_log *log) log->bios_event_log_end =3D log->bios_event_log + len; =20 virt =3D acpi_os_map_memory(start, len); @@ -30139,30 +31527,10 @@ diff -urNp linux-2.6.32.49/drivers/char/tpm/tpm= _bios.c linux-2.6.32.49/drivers/c =20 acpi_os_unmap_memory(virt, len); return 0; -diff -urNp linux-2.6.32.49/drivers/char/tpm/tpm.c linux-2.6.32.49/driver= s/char/tpm/tpm.c ---- linux-2.6.32.49/drivers/char/tpm/tpm.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/char/tpm/tpm.c 2011-11-15 19:59:43.000000000= -0500 -@@ -405,7 +405,7 @@ static ssize_t tpm_transmit(struct tpm_c - chip->vendor.req_complete_val) - goto out_recv; -=20 -- if ((status =3D=3D chip->vendor.req_canceled)) { -+ if (status =3D=3D chip->vendor.req_canceled) { - dev_err(chip->dev, "Operation Canceled\n"); - rc =3D -ECANCELED; - goto out; -@@ -824,6 +824,8 @@ ssize_t tpm_show_pubek(struct device *de -=20 - struct tpm_chip *chip =3D dev_get_drvdata(dev); -=20 -+ pax_track_stack(); -+ - tpm_cmd.header.in =3D tpm_readpubek_header; - err =3D transmit_cmd(chip, &tpm_cmd, READ_PUBEK_RESULT_SIZE, - "attempting to read the PUBEK"); -diff -urNp linux-2.6.32.49/drivers/char/tty_io.c linux-2.6.32.49/drivers= /char/tty_io.c ---- linux-2.6.32.49/drivers/char/tty_io.c 2011-11-26 19:44:53.000000000 = -0500 -+++ linux-2.6.32.49/drivers/char/tty_io.c 2011-11-26 19:45:05.000000000 = -0500 +diff --git a/drivers/char/tty_io.c b/drivers/char/tty_io.c +index 123cedf..137edef 100644 +--- a/drivers/char/tty_io.c ++++ b/drivers/char/tty_io.c @@ -1774,6 +1774,7 @@ got_driver: =20 if (IS_ERR(tty)) { @@ -30171,7 +31539,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tty_io.c = linux-2.6.32.49/drivers/char/tt return PTR_ERR(tty); } } -@@ -2603,8 +2604,10 @@ long tty_ioctl(struct file *file, unsign +@@ -2603,8 +2604,10 @@ long tty_ioctl(struct file *file, unsigned int cm= d, unsigned long arg) return retval; } =20 @@ -30183,7 +31551,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tty_io.c = linux-2.6.32.49/drivers/char/tt unsigned long arg) { struct inode *inode =3D file->f_dentry->d_inode; -@@ -2628,6 +2631,8 @@ static long tty_compat_ioctl(struct file +@@ -2628,6 +2631,8 @@ static long tty_compat_ioctl(struct file *file, un= signed int cmd, =20 return retval; } @@ -30201,10 +31569,11 @@ diff -urNp linux-2.6.32.49/drivers/char/tty_io.= c linux-2.6.32.49/drivers/char/tt } =20 /* -diff -urNp linux-2.6.32.49/drivers/char/tty_ldisc.c linux-2.6.32.49/driv= ers/char/tty_ldisc.c ---- linux-2.6.32.49/drivers/char/tty_ldisc.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/char/tty_ldisc.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -74,7 +74,7 @@ static void put_ldisc(struct tty_ldisc * +diff --git a/drivers/char/tty_ldisc.c b/drivers/char/tty_ldisc.c +index d814a3d..b55b9c9 100644 +--- a/drivers/char/tty_ldisc.c ++++ b/drivers/char/tty_ldisc.c +@@ -74,7 +74,7 @@ static void put_ldisc(struct tty_ldisc *ld) if (atomic_dec_and_lock(&ld->users, &tty_ldisc_lock)) { struct tty_ldisc_ops *ldo =3D ld->ops; =20 @@ -30213,7 +31582,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tty_ldisc= .c linux-2.6.32.49/drivers/char module_put(ldo->owner); spin_unlock_irqrestore(&tty_ldisc_lock, flags); =20 -@@ -109,7 +109,7 @@ int tty_register_ldisc(int disc, struct=20 +@@ -109,7 +109,7 @@ int tty_register_ldisc(int disc, struct tty_ldisc_op= s *new_ldisc) spin_lock_irqsave(&tty_ldisc_lock, flags); tty_ldiscs[disc] =3D new_ldisc; new_ldisc->num =3D disc; @@ -30231,7 +31600,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tty_ldisc= .c linux-2.6.32.49/drivers/char ret =3D -EBUSY; else tty_ldiscs[disc] =3D NULL; -@@ -158,7 +158,7 @@ static struct tty_ldisc_ops *get_ldops(i +@@ -158,7 +158,7 @@ static struct tty_ldisc_ops *get_ldops(int disc) if (ldops) { ret =3D ERR_PTR(-EAGAIN); if (try_module_get(ldops->owner)) { @@ -30240,7 +31609,7 @@ diff -urNp linux-2.6.32.49/drivers/char/tty_ldisc= .c linux-2.6.32.49/drivers/char ret =3D ldops; } } -@@ -171,7 +171,7 @@ static void put_ldops(struct tty_ldisc_o +@@ -171,7 +171,7 @@ static void put_ldops(struct tty_ldisc_ops *ldops) unsigned long flags; =20 spin_lock_irqsave(&tty_ldisc_lock, flags); @@ -30249,10 +31618,11 @@ diff -urNp linux-2.6.32.49/drivers/char/tty_ldi= sc.c linux-2.6.32.49/drivers/char module_put(ldops->owner); spin_unlock_irqrestore(&tty_ldisc_lock, flags); } -diff -urNp linux-2.6.32.49/drivers/char/virtio_console.c linux-2.6.32.49= /drivers/char/virtio_console.c ---- linux-2.6.32.49/drivers/char/virtio_console.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/char/virtio_console.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -133,7 +133,9 @@ static int get_chars(u32 vtermno, char * +diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console= .c +index a035ae3..c27fe2c 100644 +--- a/drivers/char/virtio_console.c ++++ b/drivers/char/virtio_console.c +@@ -133,7 +133,9 @@ static int get_chars(u32 vtermno, char *buf, int cou= nt) * virtqueue, so we let the drivers do some boutique early-output thing= . */ int __init virtio_cons_early_init(int (*put_chars)(u32, const char *, i= nt)) { @@ -30263,7 +31633,7 @@ diff -urNp linux-2.6.32.49/drivers/char/virtio_co= nsole.c linux-2.6.32.49/drivers return hvc_instantiate(0, 0, &virtio_cons); } =20 -@@ -213,11 +215,13 @@ static int __devinit virtcons_probe(stru +@@ -213,11 +215,13 @@ static int __devinit virtcons_probe(struct virtio_= device *dev) out_vq =3D vqs[1]; =20 /* Start using the new console output. */ @@ -30282,10 +31652,11 @@ diff -urNp linux-2.6.32.49/drivers/char/virtio_= console.c linux-2.6.32.49/drivers =20 /* The first argument of hvc_alloc() is the virtual console number, so * we use zero. The second argument is the parameter for the -diff -urNp linux-2.6.32.49/drivers/char/vt.c linux-2.6.32.49/drivers/cha= r/vt.c ---- linux-2.6.32.49/drivers/char/vt.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/char/vt.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -243,7 +243,7 @@ EXPORT_SYMBOL_GPL(unregister_vt_notifier +diff --git a/drivers/char/vt.c b/drivers/char/vt.c +index 0c80c68..53d59c1 100644 +--- a/drivers/char/vt.c ++++ b/drivers/char/vt.c +@@ -243,7 +243,7 @@ EXPORT_SYMBOL_GPL(unregister_vt_notifier); =20 static void notify_write(struct vc_data *vc, unsigned int unicode) { @@ -30294,10 +31665,11 @@ diff -urNp linux-2.6.32.49/drivers/char/vt.c li= nux-2.6.32.49/drivers/char/vt.c atomic_notifier_call_chain(&vt_notifier_list, VT_WRITE, ¶m); } =20 -diff -urNp linux-2.6.32.49/drivers/char/vt_ioctl.c linux-2.6.32.49/drive= rs/char/vt_ioctl.c ---- linux-2.6.32.49/drivers/char/vt_ioctl.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/char/vt_ioctl.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -210,9 +210,6 @@ do_kdsk_ioctl(int cmd, struct kbentry __ +diff --git a/drivers/char/vt_ioctl.c b/drivers/char/vt_ioctl.c +index 6351a26..999af95 100644 +--- a/drivers/char/vt_ioctl.c ++++ b/drivers/char/vt_ioctl.c +@@ -210,9 +210,6 @@ do_kdsk_ioctl(int cmd, struct kbentry __user *user_k= be, int perm, struct kbd_str if (copy_from_user(&tmp, user_kbe, sizeof(struct kbentry))) return -EFAULT; =20 @@ -30307,7 +31679,7 @@ diff -urNp linux-2.6.32.49/drivers/char/vt_ioctl.= c linux-2.6.32.49/drivers/char/ switch (cmd) { case KDGKBENT: key_map =3D key_maps[s]; -@@ -224,8 +221,12 @@ do_kdsk_ioctl(int cmd, struct kbentry __ +@@ -224,8 +221,12 @@ do_kdsk_ioctl(int cmd, struct kbentry __user *user_= kbe, int perm, struct kbd_str val =3D (i ? K_HOLE : K_NOSUCHMAP); return put_user(val, &user_kbe->kb_value); case KDSKBENT: @@ -30320,7 +31692,7 @@ diff -urNp linux-2.6.32.49/drivers/char/vt_ioctl.= c linux-2.6.32.49/drivers/char/ if (!i && v =3D=3D K_NOSUCHMAP) { /* deallocate map */ key_map =3D key_maps[s]; -@@ -325,9 +326,6 @@ do_kdgkb_ioctl(int cmd, struct kbsentry=20 +@@ -325,9 +326,6 @@ do_kdgkb_ioctl(int cmd, struct kbsentry __user *user= _kdgkb, int perm) int i, j, k; int ret; =20 @@ -30330,7 +31702,7 @@ diff -urNp linux-2.6.32.49/drivers/char/vt_ioctl.= c linux-2.6.32.49/drivers/char/ kbs =3D kmalloc(sizeof(*kbs), GFP_KERNEL); if (!kbs) { ret =3D -ENOMEM; -@@ -361,6 +359,9 @@ do_kdgkb_ioctl(int cmd, struct kbsentry=20 +@@ -361,6 +359,9 @@ do_kdgkb_ioctl(int cmd, struct kbsentry __user *user= _kdgkb, int perm) kfree(kbs); return ((p && *p) ? -EOVERFLOW : 0); case KDSKBSENT: @@ -30340,10 +31712,11 @@ diff -urNp linux-2.6.32.49/drivers/char/vt_ioct= l.c linux-2.6.32.49/drivers/char/ if (!perm) { ret =3D -EPERM; goto reterr; -diff -urNp linux-2.6.32.49/drivers/cpufreq/cpufreq.c linux-2.6.32.49/dri= vers/cpufreq/cpufreq.c ---- linux-2.6.32.49/drivers/cpufreq/cpufreq.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/cpufreq/cpufreq.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -750,7 +750,7 @@ static void cpufreq_sysfs_release(struct +diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c +index c7ae026..1769c1d 100644 +--- a/drivers/cpufreq/cpufreq.c ++++ b/drivers/cpufreq/cpufreq.c +@@ -750,7 +750,7 @@ static void cpufreq_sysfs_release(struct kobject *ko= bj) complete(&policy->kobj_unregister); } =20 @@ -30352,10 +31725,11 @@ diff -urNp linux-2.6.32.49/drivers/cpufreq/cpuf= req.c linux-2.6.32.49/drivers/cpu .show =3D show, .store =3D store, }; -diff -urNp linux-2.6.32.49/drivers/cpuidle/sysfs.c linux-2.6.32.49/drive= rs/cpuidle/sysfs.c ---- linux-2.6.32.49/drivers/cpuidle/sysfs.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/cpuidle/sysfs.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -191,7 +191,7 @@ static ssize_t cpuidle_store(struct kobj +diff --git a/drivers/cpuidle/sysfs.c b/drivers/cpuidle/sysfs.c +index 97b0038..2056670 100644 +--- a/drivers/cpuidle/sysfs.c ++++ b/drivers/cpuidle/sysfs.c +@@ -191,7 +191,7 @@ static ssize_t cpuidle_store(struct kobject * kobj, = struct attribute * attr, return ret; } =20 @@ -30364,7 +31738,7 @@ diff -urNp linux-2.6.32.49/drivers/cpuidle/sysfs.= c linux-2.6.32.49/drivers/cpuid .show =3D cpuidle_show, .store =3D cpuidle_store, }; -@@ -277,7 +277,7 @@ static ssize_t cpuidle_state_show(struct +@@ -277,7 +277,7 @@ static ssize_t cpuidle_state_show(struct kobject * k= obj, return ret; } =20 @@ -30373,7 +31747,7 @@ diff -urNp linux-2.6.32.49/drivers/cpuidle/sysfs.= c linux-2.6.32.49/drivers/cpuid .show =3D cpuidle_state_show, }; =20 -@@ -294,7 +294,7 @@ static struct kobj_type ktype_state_cpui +@@ -294,7 +294,7 @@ static struct kobj_type ktype_state_cpuidle =3D { .release =3D cpuidle_state_sysfs_release, }; =20 @@ -30382,10 +31756,11 @@ diff -urNp linux-2.6.32.49/drivers/cpuidle/sysf= s.c linux-2.6.32.49/drivers/cpuid { kobject_put(&device->kobjs[i]->kobj); wait_for_completion(&device->kobjs[i]->kobj_unregister); -diff -urNp linux-2.6.32.49/drivers/crypto/hifn_795x.c linux-2.6.32.49/dr= ivers/crypto/hifn_795x.c ---- linux-2.6.32.49/drivers/crypto/hifn_795x.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/crypto/hifn_795x.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -1655,6 +1655,8 @@ static int hifn_test(struct hifn_device=20 +diff --git a/drivers/crypto/hifn_795x.c b/drivers/crypto/hifn_795x.c +index 5f753fc..0377ae9 100644 +--- a/drivers/crypto/hifn_795x.c ++++ b/drivers/crypto/hifn_795x.c +@@ -1655,6 +1655,8 @@ static int hifn_test(struct hifn_device *dev, int = encdec, u8 snum) 0xCA, 0x34, 0x2B, 0x2E}; struct scatterlist sg; =20 @@ -30394,10 +31769,11 @@ diff -urNp linux-2.6.32.49/drivers/crypto/hifn_= 795x.c linux-2.6.32.49/drivers/cr memset(src, 0, sizeof(src)); memset(ctx.key, 0, sizeof(ctx.key)); =20 -diff -urNp linux-2.6.32.49/drivers/crypto/padlock-aes.c linux-2.6.32.49/= drivers/crypto/padlock-aes.c ---- linux-2.6.32.49/drivers/crypto/padlock-aes.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/crypto/padlock-aes.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -108,6 +108,8 @@ static int aes_set_key(struct crypto_tfm +diff --git a/drivers/crypto/padlock-aes.c b/drivers/crypto/padlock-aes.c +index 71e6482..de8d96c 100644 +--- a/drivers/crypto/padlock-aes.c ++++ b/drivers/crypto/padlock-aes.c +@@ -108,6 +108,8 @@ static int aes_set_key(struct crypto_tfm *tfm, const= u8 *in_key, struct crypto_aes_ctx gen_aes; int cpu; =20 @@ -30406,10 +31782,11 @@ diff -urNp linux-2.6.32.49/drivers/crypto/padlo= ck-aes.c linux-2.6.32.49/drivers/ if (key_len % 8) { *flags |=3D CRYPTO_TFM_RES_BAD_KEY_LEN; return -EINVAL; -diff -urNp linux-2.6.32.49/drivers/dma/ioat/dma.c linux-2.6.32.49/driver= s/dma/ioat/dma.c ---- linux-2.6.32.49/drivers/dma/ioat/dma.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/dma/ioat/dma.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1146,7 +1146,7 @@ ioat_attr_show(struct kobject *kobj, str +diff --git a/drivers/dma/ioat/dma.c b/drivers/dma/ioat/dma.c +index dcc4ab7..cc834bb 100644 +--- a/drivers/dma/ioat/dma.c ++++ b/drivers/dma/ioat/dma.c +@@ -1146,7 +1146,7 @@ ioat_attr_show(struct kobject *kobj, struct attrib= ute *attr, char *page) return entry->show(&chan->common, page); } =20 @@ -30418,10 +31795,11 @@ diff -urNp linux-2.6.32.49/drivers/dma/ioat/dma= .c linux-2.6.32.49/drivers/dma/io .show =3D ioat_attr_show, }; =20 -diff -urNp linux-2.6.32.49/drivers/dma/ioat/dma.h linux-2.6.32.49/driver= s/dma/ioat/dma.h ---- linux-2.6.32.49/drivers/dma/ioat/dma.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/dma/ioat/dma.h 2011-11-15 19:59:43.000000000= -0500 -@@ -347,7 +347,7 @@ bool ioat_cleanup_preamble(struct ioat_c +diff --git a/drivers/dma/ioat/dma.h b/drivers/dma/ioat/dma.h +index bbc3e78..f2db62c 100644 +--- a/drivers/dma/ioat/dma.h ++++ b/drivers/dma/ioat/dma.h +@@ -347,7 +347,7 @@ bool ioat_cleanup_preamble(struct ioat_chan_common *= chan, unsigned long *phys_complete); void ioat_kobject_add(struct ioatdma_device *device, struct kobj_type *= type); void ioat_kobject_del(struct ioatdma_device *device); @@ -30430,9 +31808,10 @@ diff -urNp linux-2.6.32.49/drivers/dma/ioat/dma.= h linux-2.6.32.49/drivers/dma/io extern struct ioat_sysfs_entry ioat_version_attr; extern struct ioat_sysfs_entry ioat_cap_attr; #endif /* IOATDMA_H */ -diff -urNp linux-2.6.32.49/drivers/dma/ioat/dma_v3.c linux-2.6.32.49/dri= vers/dma/ioat/dma_v3.c ---- linux-2.6.32.49/drivers/dma/ioat/dma_v3.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/dma/ioat/dma_v3.c 2011-11-18 18:01:55.000000= 000 -0500 +diff --git a/drivers/dma/ioat/dma_v3.c b/drivers/dma/ioat/dma_v3.c +index 9908c9e..3ceb0e5 100644 +--- a/drivers/dma/ioat/dma_v3.c ++++ b/drivers/dma/ioat/dma_v3.c @@ -71,10 +71,10 @@ /* provide a lookup table for setting the source address in the base or * extended descriptor of an xor or pq descriptor @@ -30448,10 +31827,11 @@ diff -urNp linux-2.6.32.49/drivers/dma/ioat/dma= _v3.c linux-2.6.32.49/drivers/dma =20 static dma_addr_t xor_get_src(struct ioat_raw_descriptor *descs[2], int= idx) { -diff -urNp linux-2.6.32.49/drivers/edac/amd64_edac.c linux-2.6.32.49/dri= vers/edac/amd64_edac.c ---- linux-2.6.32.49/drivers/edac/amd64_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/amd64_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -3099,7 +3099,7 @@ static void __devexit amd64_remove_one_i +diff --git a/drivers/edac/amd64_edac.c b/drivers/edac/amd64_edac.c +index 85c464a..afd1e73 100644 +--- a/drivers/edac/amd64_edac.c ++++ b/drivers/edac/amd64_edac.c +@@ -3099,7 +3099,7 @@ static void __devexit amd64_remove_one_instance(st= ruct pci_dev *pdev) * PCI core identifies what devices are on a system during boot, and th= en * inquiry this table to see if this driver is for a given device found= . */ @@ -30460,10 +31840,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/amd64_e= dac.c linux-2.6.32.49/drivers/eda { .vendor =3D PCI_VENDOR_ID_AMD, .device =3D PCI_DEVICE_ID_AMD_K8_NB_MEMCTL, -diff -urNp linux-2.6.32.49/drivers/edac/amd76x_edac.c linux-2.6.32.49/dr= ivers/edac/amd76x_edac.c ---- linux-2.6.32.49/drivers/edac/amd76x_edac.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/edac/amd76x_edac.c 2011-11-18 18:01:55.00000= 0000 -0500 -@@ -322,7 +322,7 @@ static void __devexit amd76x_remove_one( +diff --git a/drivers/edac/amd76x_edac.c b/drivers/edac/amd76x_edac.c +index 2b95f1a..4f52793 100644 +--- a/drivers/edac/amd76x_edac.c ++++ b/drivers/edac/amd76x_edac.c +@@ -322,7 +322,7 @@ static void __devexit amd76x_remove_one(struct pci_d= ev *pdev) edac_mc_free(mci); } =20 @@ -30472,10 +31853,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/amd76x_= edac.c linux-2.6.32.49/drivers/ed { PCI_VEND_DEV(AMD, FE_GATE_700C), PCI_ANY_ID, PCI_ANY_ID, 0, 0, AMD762}, -diff -urNp linux-2.6.32.49/drivers/edac/e752x_edac.c linux-2.6.32.49/dri= vers/edac/e752x_edac.c ---- linux-2.6.32.49/drivers/edac/e752x_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/e752x_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -1282,7 +1282,7 @@ static void __devexit e752x_remove_one(s +diff --git a/drivers/edac/e752x_edac.c b/drivers/edac/e752x_edac.c +index d205d49..74c9672 100644 +--- a/drivers/edac/e752x_edac.c ++++ b/drivers/edac/e752x_edac.c +@@ -1282,7 +1282,7 @@ static void __devexit e752x_remove_one(struct pci_= dev *pdev) edac_mc_free(mci); } =20 @@ -30484,10 +31866,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/e752x_e= dac.c linux-2.6.32.49/drivers/eda { PCI_VEND_DEV(INTEL, 7520_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, E7520}, -diff -urNp linux-2.6.32.49/drivers/edac/e7xxx_edac.c linux-2.6.32.49/dri= vers/edac/e7xxx_edac.c ---- linux-2.6.32.49/drivers/edac/e7xxx_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/e7xxx_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -526,7 +526,7 @@ static void __devexit e7xxx_remove_one(s +diff --git a/drivers/edac/e7xxx_edac.c b/drivers/edac/e7xxx_edac.c +index c7d11cc..c59c1ca 100644 +--- a/drivers/edac/e7xxx_edac.c ++++ b/drivers/edac/e7xxx_edac.c +@@ -526,7 +526,7 @@ static void __devexit e7xxx_remove_one(struct pci_de= v *pdev) edac_mc_free(mci); } =20 @@ -30496,10 +31879,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/e7xxx_e= dac.c linux-2.6.32.49/drivers/eda { PCI_VEND_DEV(INTEL, 7205_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, E7205}, -diff -urNp linux-2.6.32.49/drivers/edac/edac_device_sysfs.c linux-2.6.32= .49/drivers/edac/edac_device_sysfs.c ---- linux-2.6.32.49/drivers/edac/edac_device_sysfs.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/edac/edac_device_sysfs.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -137,7 +137,7 @@ static ssize_t edac_dev_ctl_info_store(s +diff --git a/drivers/edac/edac_device_sysfs.c b/drivers/edac/edac_device= _sysfs.c +index 5376457..5fdedbc 100644 +--- a/drivers/edac/edac_device_sysfs.c ++++ b/drivers/edac/edac_device_sysfs.c +@@ -137,7 +137,7 @@ static ssize_t edac_dev_ctl_info_store(struct kobjec= t *kobj, } =20 /* edac_dev file operations for an 'ctl_info' */ @@ -30508,7 +31892,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_devi= ce_sysfs.c linux-2.6.32.49/driv .show =3D edac_dev_ctl_info_show, .store =3D edac_dev_ctl_info_store }; -@@ -373,7 +373,7 @@ static ssize_t edac_dev_instance_store(s +@@ -373,7 +373,7 @@ static ssize_t edac_dev_instance_store(struct kobjec= t *kobj, } =20 /* edac_dev file operations for an 'instance' */ @@ -30517,7 +31901,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_devi= ce_sysfs.c linux-2.6.32.49/driv .show =3D edac_dev_instance_show, .store =3D edac_dev_instance_store }; -@@ -476,7 +476,7 @@ static ssize_t edac_dev_block_store(stru +@@ -476,7 +476,7 @@ static ssize_t edac_dev_block_store(struct kobject *= kobj, } =20 /* edac_dev file operations for a 'block' */ @@ -30526,10 +31910,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_de= vice_sysfs.c linux-2.6.32.49/driv .show =3D edac_dev_block_show, .store =3D edac_dev_block_store }; -diff -urNp linux-2.6.32.49/drivers/edac/edac_mc_sysfs.c linux-2.6.32.49/= drivers/edac/edac_mc_sysfs.c ---- linux-2.6.32.49/drivers/edac/edac_mc_sysfs.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/edac/edac_mc_sysfs.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -245,7 +245,7 @@ static ssize_t csrowdev_store(struct kob +diff --git a/drivers/edac/edac_mc_sysfs.c b/drivers/edac/edac_mc_sysfs.c +index e1d4ce0..88840e9 100644 +--- a/drivers/edac/edac_mc_sysfs.c ++++ b/drivers/edac/edac_mc_sysfs.c +@@ -245,7 +245,7 @@ static ssize_t csrowdev_store(struct kobject *kobj, = struct attribute *attr, return -EIO; } =20 @@ -30538,7 +31923,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_mc_s= ysfs.c linux-2.6.32.49/drivers/ .show =3D csrowdev_show, .store =3D csrowdev_store }; -@@ -575,7 +575,7 @@ static ssize_t mcidev_store(struct kobje +@@ -575,7 +575,7 @@ static ssize_t mcidev_store(struct kobject *kobj, st= ruct attribute *attr, } =20 /* Intermediate show/store table */ @@ -30547,10 +31932,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_mc= _sysfs.c linux-2.6.32.49/drivers/ .show =3D mcidev_show, .store =3D mcidev_store }; -diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_sysfs.c linux-2.6.32.49= /drivers/edac/edac_pci_sysfs.c ---- linux-2.6.32.49/drivers/edac/edac_pci_sysfs.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/edac/edac_pci_sysfs.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -25,8 +25,8 @@ static int edac_pci_log_pe =3D 1; /* log=20 +diff --git a/drivers/edac/edac_pci_sysfs.c b/drivers/edac/edac_pci_sysfs= .c +index 422728c..d8d9c88 100644 +--- a/drivers/edac/edac_pci_sysfs.c ++++ b/drivers/edac/edac_pci_sysfs.c +@@ -25,8 +25,8 @@ static int edac_pci_log_pe =3D 1; /* log PCI parity e= rrors */ static int edac_pci_log_npe =3D 1; /* log PCI non-parity error errors *= / static int edac_pci_poll_msec =3D 1000; /* one second workq period */ =20 @@ -30561,7 +31947,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers =20 static struct kobject *edac_pci_top_main_kobj; static atomic_t edac_pci_sysfs_refcount =3D ATOMIC_INIT(0); -@@ -121,7 +121,7 @@ static ssize_t edac_pci_instance_store(s +@@ -121,7 +121,7 @@ static ssize_t edac_pci_instance_store(struct kobjec= t *kobj, } =20 /* fs_ops table */ @@ -30570,7 +31956,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers .show =3D edac_pci_instance_show, .store =3D edac_pci_instance_store }; -@@ -261,7 +261,7 @@ static ssize_t edac_pci_dev_store(struct +@@ -261,7 +261,7 @@ static ssize_t edac_pci_dev_store(struct kobject *ko= bj, return -EIO; } =20 @@ -30579,7 +31965,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers .show =3D edac_pci_dev_show, .store =3D edac_pci_dev_store }; -@@ -579,7 +579,7 @@ static void edac_pci_dev_parity_test(str +@@ -579,7 +579,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) edac_printk(KERN_CRIT, EDAC_PCI, "Signaled System Error on %s\n", pci_name(dev)); @@ -30588,7 +31974,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers } =20 if (status & (PCI_STATUS_PARITY)) { -@@ -587,7 +587,7 @@ static void edac_pci_dev_parity_test(str +@@ -587,7 +587,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Master Data Parity Error on %s\n", pci_name(dev)); =20 @@ -30597,7 +31983,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers } =20 if (status & (PCI_STATUS_DETECTED_PARITY)) { -@@ -595,7 +595,7 @@ static void edac_pci_dev_parity_test(str +@@ -595,7 +595,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Detected Parity Error on %s\n", pci_name(dev)); =20 @@ -30606,7 +31992,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers } } =20 -@@ -616,7 +616,7 @@ static void edac_pci_dev_parity_test(str +@@ -616,7 +616,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) edac_printk(KERN_CRIT, EDAC_PCI, "Bridge " "Signaled System Error on %s\n", pci_name(dev)); @@ -30615,7 +32001,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers } =20 if (status & (PCI_STATUS_PARITY)) { -@@ -624,7 +624,7 @@ static void edac_pci_dev_parity_test(str +@@ -624,7 +624,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Master Data Parity Error on " "%s\n", pci_name(dev)); =20 @@ -30624,7 +32010,7 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pci_= sysfs.c linux-2.6.32.49/drivers } =20 if (status & (PCI_STATUS_DETECTED_PARITY)) { -@@ -632,7 +632,7 @@ static void edac_pci_dev_parity_test(str +@@ -632,7 +632,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Detected Parity Error on %s\n", pci_name(dev)); =20 @@ -30651,10 +32037,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/edac_pc= i_sysfs.c linux-2.6.32.49/drivers panic("EDAC: PCI Parity Error"); } } -diff -urNp linux-2.6.32.49/drivers/edac/i3000_edac.c linux-2.6.32.49/dri= vers/edac/i3000_edac.c ---- linux-2.6.32.49/drivers/edac/i3000_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/i3000_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -471,7 +471,7 @@ static void __devexit i3000_remove_one(s +diff --git a/drivers/edac/i3000_edac.c b/drivers/edac/i3000_edac.c +index 6c9a0f2..9c1cf7e 100644 +--- a/drivers/edac/i3000_edac.c ++++ b/drivers/edac/i3000_edac.c +@@ -471,7 +471,7 @@ static void __devexit i3000_remove_one(struct pci_de= v *pdev) edac_mc_free(mci); } =20 @@ -30663,10 +32050,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i3000_e= dac.c linux-2.6.32.49/drivers/eda { PCI_VEND_DEV(INTEL, 3000_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I3000}, -diff -urNp linux-2.6.32.49/drivers/edac/i3200_edac.c linux-2.6.32.49/dri= vers/edac/i3200_edac.c ---- linux-2.6.32.49/drivers/edac/i3200_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/i3200_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -444,7 +444,7 @@ static void __devexit i3200_remove_one(s +diff --git a/drivers/edac/i3200_edac.c b/drivers/edac/i3200_edac.c +index fde4db9..fe108f9 100644 +--- a/drivers/edac/i3200_edac.c ++++ b/drivers/edac/i3200_edac.c +@@ -444,7 +444,7 @@ static void __devexit i3200_remove_one(struct pci_de= v *pdev) edac_mc_free(mci); } =20 @@ -30675,10 +32063,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i3200_e= dac.c linux-2.6.32.49/drivers/eda { PCI_VEND_DEV(INTEL, 3200_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I3200}, -diff -urNp linux-2.6.32.49/drivers/edac/i5000_edac.c linux-2.6.32.49/dri= vers/edac/i5000_edac.c ---- linux-2.6.32.49/drivers/edac/i5000_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/i5000_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -1516,7 +1516,7 @@ static void __devexit i5000_remove_one(s +diff --git a/drivers/edac/i5000_edac.c b/drivers/edac/i5000_edac.c +index adc10a2..57d4ccf 100644 +--- a/drivers/edac/i5000_edac.c ++++ b/drivers/edac/i5000_edac.c +@@ -1516,7 +1516,7 @@ static void __devexit i5000_remove_one(struct pci_= dev *pdev) * * The "E500P" device is the first device supported. */ @@ -30687,10 +32076,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i5000_e= dac.c linux-2.6.32.49/drivers/eda {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_I5000_DEV16), .driver_data =3D I5000P}, =20 -diff -urNp linux-2.6.32.49/drivers/edac/i5100_edac.c linux-2.6.32.49/dri= vers/edac/i5100_edac.c ---- linux-2.6.32.49/drivers/edac/i5100_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/i5100_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -944,7 +944,7 @@ static void __devexit i5100_remove_one(s +diff --git a/drivers/edac/i5100_edac.c b/drivers/edac/i5100_edac.c +index 22db05a..b2b5503 100644 +--- a/drivers/edac/i5100_edac.c ++++ b/drivers/edac/i5100_edac.c +@@ -944,7 +944,7 @@ static void __devexit i5100_remove_one(struct pci_de= v *pdev) edac_mc_free(mci); } =20 @@ -30699,10 +32089,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i5100_e= dac.c linux-2.6.32.49/drivers/eda /* Device 16, Function 0, Channel 0 Memory Map, Error Flag/Mask, ... *= / { PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_5100_16) }, { 0, } -diff -urNp linux-2.6.32.49/drivers/edac/i5400_edac.c linux-2.6.32.49/dri= vers/edac/i5400_edac.c ---- linux-2.6.32.49/drivers/edac/i5400_edac.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/edac/i5400_edac.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -1383,7 +1383,7 @@ static void __devexit i5400_remove_one(s +diff --git a/drivers/edac/i5400_edac.c b/drivers/edac/i5400_edac.c +index f99d106..f050710 100644 +--- a/drivers/edac/i5400_edac.c ++++ b/drivers/edac/i5400_edac.c +@@ -1383,7 +1383,7 @@ static void __devexit i5400_remove_one(struct pci_= dev *pdev) * * The "E500P" device is the first device supported. */ @@ -30711,10 +32102,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i5400_e= dac.c linux-2.6.32.49/drivers/eda {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_5400_ERR)}, {0,} /* 0 terminated list. */ }; -diff -urNp linux-2.6.32.49/drivers/edac/i82443bxgx_edac.c linux-2.6.32.4= 9/drivers/edac/i82443bxgx_edac.c ---- linux-2.6.32.49/drivers/edac/i82443bxgx_edac.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/edac/i82443bxgx_edac.c 2011-11-18 18:01:55.0= 00000000 -0500 -@@ -381,7 +381,7 @@ static void __devexit i82443bxgx_edacmc_ +diff --git a/drivers/edac/i82443bxgx_edac.c b/drivers/edac/i82443bxgx_ed= ac.c +index 577760a..9ce16ce 100644 +--- a/drivers/edac/i82443bxgx_edac.c ++++ b/drivers/edac/i82443bxgx_edac.c +@@ -381,7 +381,7 @@ static void __devexit i82443bxgx_edacmc_remove_one(s= truct pci_dev *pdev) =20 EXPORT_SYMBOL_GPL(i82443bxgx_edacmc_remove_one); =20 @@ -30723,10 +32115,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i82443b= xgx_edac.c linux-2.6.32.49/driver {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82443BX_0)}, {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82443BX_2)}, {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82443GX_0)}, -diff -urNp linux-2.6.32.49/drivers/edac/i82860_edac.c linux-2.6.32.49/dr= ivers/edac/i82860_edac.c ---- linux-2.6.32.49/drivers/edac/i82860_edac.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/edac/i82860_edac.c 2011-11-18 18:01:55.00000= 0000 -0500 -@@ -271,7 +271,7 @@ static void __devexit i82860_remove_one( +diff --git a/drivers/edac/i82860_edac.c b/drivers/edac/i82860_edac.c +index c0088ba..64a7b98 100644 +--- a/drivers/edac/i82860_edac.c ++++ b/drivers/edac/i82860_edac.c +@@ -271,7 +271,7 @@ static void __devexit i82860_remove_one(struct pci_d= ev *pdev) edac_mc_free(mci); } =20 @@ -30735,10 +32128,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i82860_= edac.c linux-2.6.32.49/drivers/ed { PCI_VEND_DEV(INTEL, 82860_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82860}, -diff -urNp linux-2.6.32.49/drivers/edac/i82875p_edac.c linux-2.6.32.49/d= rivers/edac/i82875p_edac.c ---- linux-2.6.32.49/drivers/edac/i82875p_edac.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/edac/i82875p_edac.c 2011-11-18 18:01:55.0000= 00000 -0500 -@@ -512,7 +512,7 @@ static void __devexit i82875p_remove_one +diff --git a/drivers/edac/i82875p_edac.c b/drivers/edac/i82875p_edac.c +index b2d83b9..a34357b 100644 +--- a/drivers/edac/i82875p_edac.c ++++ b/drivers/edac/i82875p_edac.c +@@ -512,7 +512,7 @@ static void __devexit i82875p_remove_one(struct pci_= dev *pdev) edac_mc_free(mci); } =20 @@ -30747,10 +32141,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i82875p= _edac.c linux-2.6.32.49/drivers/e { PCI_VEND_DEV(INTEL, 82875_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82875P}, -diff -urNp linux-2.6.32.49/drivers/edac/i82975x_edac.c linux-2.6.32.49/d= rivers/edac/i82975x_edac.c ---- linux-2.6.32.49/drivers/edac/i82975x_edac.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/edac/i82975x_edac.c 2011-11-18 18:01:55.0000= 00000 -0500 -@@ -586,7 +586,7 @@ static void __devexit i82975x_remove_one +diff --git a/drivers/edac/i82975x_edac.c b/drivers/edac/i82975x_edac.c +index 2eed3ea..87bbbd1 100644 +--- a/drivers/edac/i82975x_edac.c ++++ b/drivers/edac/i82975x_edac.c +@@ -586,7 +586,7 @@ static void __devexit i82975x_remove_one(struct pci_= dev *pdev) edac_mc_free(mci); } =20 @@ -30759,10 +32154,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/i82975x= _edac.c linux-2.6.32.49/drivers/e { PCI_VEND_DEV(INTEL, 82975_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82975X -diff -urNp linux-2.6.32.49/drivers/edac/r82600_edac.c linux-2.6.32.49/dr= ivers/edac/r82600_edac.c ---- linux-2.6.32.49/drivers/edac/r82600_edac.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/edac/r82600_edac.c 2011-11-18 18:01:55.00000= 0000 -0500 -@@ -374,7 +374,7 @@ static void __devexit r82600_remove_one( +diff --git a/drivers/edac/r82600_edac.c b/drivers/edac/r82600_edac.c +index 9900675..78ac2b6 100644 +--- a/drivers/edac/r82600_edac.c ++++ b/drivers/edac/r82600_edac.c +@@ -374,7 +374,7 @@ static void __devexit r82600_remove_one(struct pci_d= ev *pdev) edac_mc_free(mci); } =20 @@ -30771,10 +32167,11 @@ diff -urNp linux-2.6.32.49/drivers/edac/r82600_= edac.c linux-2.6.32.49/drivers/ed { PCI_DEVICE(PCI_VENDOR_ID_RADISYS, R82600_BRIDGE_ID) }, -diff -urNp linux-2.6.32.49/drivers/edac/x38_edac.c linux-2.6.32.49/drive= rs/edac/x38_edac.c ---- linux-2.6.32.49/drivers/edac/x38_edac.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/edac/x38_edac.c 2011-11-18 18:01:55.00000000= 0 -0500 -@@ -441,7 +441,7 @@ static void __devexit x38_remove_one(str +diff --git a/drivers/edac/x38_edac.c b/drivers/edac/x38_edac.c +index d4ec605..4cfec4e 100644 +--- a/drivers/edac/x38_edac.c ++++ b/drivers/edac/x38_edac.c +@@ -441,7 +441,7 @@ static void __devexit x38_remove_one(struct pci_dev = *pdev) edac_mc_free(mci); } =20 @@ -30783,9 +32180,10 @@ diff -urNp linux-2.6.32.49/drivers/edac/x38_edac= .c linux-2.6.32.49/drivers/edac/ { PCI_VEND_DEV(INTEL, X38_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, X38}, -diff -urNp linux-2.6.32.49/drivers/firewire/core-card.c linux-2.6.32.49/= drivers/firewire/core-card.c ---- linux-2.6.32.49/drivers/firewire/core-card.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/firewire/core-card.c 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/drivers/firewire/core-card.c b/drivers/firewire/core-card.c +index 3fc2ceb..daf098f 100644 +--- a/drivers/firewire/core-card.c ++++ b/drivers/firewire/core-card.c @@ -558,7 +558,7 @@ void fw_card_release(struct kref *kref) =20 void fw_core_remove_card(struct fw_card *card) @@ -30795,10 +32193,11 @@ diff -urNp linux-2.6.32.49/drivers/firewire/cor= e-card.c linux-2.6.32.49/drivers/ =20 card->driver->update_phy_reg(card, 4, PHY_LINK_ACTIVE | PHY_CONTENDER, 0); -diff -urNp linux-2.6.32.49/drivers/firewire/core-cdev.c linux-2.6.32.49/= drivers/firewire/core-cdev.c ---- linux-2.6.32.49/drivers/firewire/core-cdev.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/firewire/core-cdev.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -1141,8 +1141,7 @@ static int init_iso_resource(struct clie +diff --git a/drivers/firewire/core-cdev.c b/drivers/firewire/core-cdev.c +index 4560d8f..36db24a 100644 +--- a/drivers/firewire/core-cdev.c ++++ b/drivers/firewire/core-cdev.c +@@ -1141,8 +1141,7 @@ static int init_iso_resource(struct client *client= , int ret; =20 if ((request->channels =3D=3D 0 && request->bandwidth =3D=3D 0) || @@ -30808,20 +32207,10 @@ diff -urNp linux-2.6.32.49/drivers/firewire/cor= e-cdev.c linux-2.6.32.49/drivers/ return -EINVAL; =20 r =3D kmalloc(sizeof(*r), GFP_KERNEL); -diff -urNp linux-2.6.32.49/drivers/firewire/core.h linux-2.6.32.49/drive= rs/firewire/core.h ---- linux-2.6.32.49/drivers/firewire/core.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/firewire/core.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -86,6 +86,7 @@ struct fw_card_driver { -=20 - int (*stop_iso)(struct fw_iso_context *ctx); - }; -+typedef struct fw_card_driver __no_const fw_card_driver_no_const; -=20 - void fw_card_initialize(struct fw_card *card, - const struct fw_card_driver *driver, struct device *device); -diff -urNp linux-2.6.32.49/drivers/firewire/core-transaction.c linux-2.6= .32.49/drivers/firewire/core-transaction.c ---- linux-2.6.32.49/drivers/firewire/core-transaction.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/firewire/core-transaction.c 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/drivers/firewire/core-transaction.c b/drivers/firewire/core= -transaction.c +index da628c7..cf54a2c 100644 +--- a/drivers/firewire/core-transaction.c ++++ b/drivers/firewire/core-transaction.c @@ -36,6 +36,7 @@ #include #include @@ -30830,7 +32219,7 @@ diff -urNp linux-2.6.32.49/drivers/firewire/core-= transaction.c linux-2.6.32.49/d =20 #include =20 -@@ -344,6 +345,8 @@ int fw_run_transaction(struct fw_card *c +@@ -344,6 +345,8 @@ int fw_run_transaction(struct fw_card *card, int tco= de, int destination_id, struct transaction_callback_data d; struct fw_transaction t; =20 @@ -30839,9 +32228,22 @@ diff -urNp linux-2.6.32.49/drivers/firewire/core= -transaction.c linux-2.6.32.49/d init_completion(&d.done); d.payload =3D payload; fw_send_request(card, &t, tcode, destination_id, generation, speed, -diff -urNp linux-2.6.32.49/drivers/firmware/dmi_scan.c linux-2.6.32.49/d= rivers/firmware/dmi_scan.c ---- linux-2.6.32.49/drivers/firmware/dmi_scan.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/firmware/dmi_scan.c 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/drivers/firewire/core.h b/drivers/firewire/core.h +index 7ff6e75..a2965d9 100644 +--- a/drivers/firewire/core.h ++++ b/drivers/firewire/core.h +@@ -86,6 +86,7 @@ struct fw_card_driver { +=20 + int (*stop_iso)(struct fw_iso_context *ctx); + }; ++typedef struct fw_card_driver __no_const fw_card_driver_no_const; +=20 + void fw_card_initialize(struct fw_card *card, + const struct fw_card_driver *driver, struct device *device); +diff --git a/drivers/firmware/dmi_scan.c b/drivers/firmware/dmi_scan.c +index 3a2ccb0..82fd7c4 100644 +--- a/drivers/firmware/dmi_scan.c ++++ b/drivers/firmware/dmi_scan.c @@ -391,11 +391,6 @@ void __init dmi_scan_machine(void) } } @@ -30854,7 +32256,7 @@ diff -urNp linux-2.6.32.49/drivers/firmware/dmi_s= can.c linux-2.6.32.49/drivers/f p =3D dmi_ioremap(0xF0000, 0x10000); if (p =3D=3D NULL) goto error; -@@ -667,7 +662,7 @@ int dmi_walk(void (*decode)(const struct +@@ -667,7 +662,7 @@ int dmi_walk(void (*decode)(const struct dmi_header = *, void *), if (buf =3D=3D NULL) return -1; =20 @@ -30863,10 +32265,11 @@ diff -urNp linux-2.6.32.49/drivers/firmware/dmi= _scan.c linux-2.6.32.49/drivers/f =20 iounmap(buf); return 0; -diff -urNp linux-2.6.32.49/drivers/firmware/edd.c linux-2.6.32.49/driver= s/firmware/edd.c ---- linux-2.6.32.49/drivers/firmware/edd.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/firmware/edd.c 2011-11-15 19:59:43.000000000= -0500 -@@ -122,7 +122,7 @@ edd_attr_show(struct kobject * kobj, str +diff --git a/drivers/firmware/edd.c b/drivers/firmware/edd.c +index 9e4f59d..110e24e 100644 +--- a/drivers/firmware/edd.c ++++ b/drivers/firmware/edd.c +@@ -122,7 +122,7 @@ edd_attr_show(struct kobject * kobj, struct attribut= e *attr, char *buf) return ret; } =20 @@ -30875,10 +32278,11 @@ diff -urNp linux-2.6.32.49/drivers/firmware/edd= .c linux-2.6.32.49/drivers/firmwa .show =3D edd_attr_show, }; =20 -diff -urNp linux-2.6.32.49/drivers/firmware/efivars.c linux-2.6.32.49/dr= ivers/firmware/efivars.c ---- linux-2.6.32.49/drivers/firmware/efivars.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/firmware/efivars.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -362,7 +362,7 @@ static ssize_t efivar_attr_store(struct=20 +diff --git a/drivers/firmware/efivars.c b/drivers/firmware/efivars.c +index f4f709d..082f06e 100644 +--- a/drivers/firmware/efivars.c ++++ b/drivers/firmware/efivars.c +@@ -362,7 +362,7 @@ static ssize_t efivar_attr_store(struct kobject *kob= j, struct attribute *attr, return ret; } =20 @@ -30887,10 +32291,11 @@ diff -urNp linux-2.6.32.49/drivers/firmware/efi= vars.c linux-2.6.32.49/drivers/fi .show =3D efivar_attr_show, .store =3D efivar_attr_store, }; -diff -urNp linux-2.6.32.49/drivers/firmware/iscsi_ibft.c linux-2.6.32.49= /drivers/firmware/iscsi_ibft.c ---- linux-2.6.32.49/drivers/firmware/iscsi_ibft.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/firmware/iscsi_ibft.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -525,7 +525,7 @@ static ssize_t ibft_show_attribute(struc +diff --git a/drivers/firmware/iscsi_ibft.c b/drivers/firmware/iscsi_ibft= .c +index 051d1eb..0a5d4e7 100644 +--- a/drivers/firmware/iscsi_ibft.c ++++ b/drivers/firmware/iscsi_ibft.c +@@ -525,7 +525,7 @@ static ssize_t ibft_show_attribute(struct kobject *k= obj, return ret; } =20 @@ -30899,9 +32304,10 @@ diff -urNp linux-2.6.32.49/drivers/firmware/iscs= i_ibft.c linux-2.6.32.49/drivers .show =3D ibft_show_attribute, }; =20 -diff -urNp linux-2.6.32.49/drivers/firmware/memmap.c linux-2.6.32.49/dri= vers/firmware/memmap.c ---- linux-2.6.32.49/drivers/firmware/memmap.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/firmware/memmap.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/firmware/memmap.c b/drivers/firmware/memmap.c +index 56f9234..8c58c7b 100644 +--- a/drivers/firmware/memmap.c ++++ b/drivers/firmware/memmap.c @@ -74,7 +74,7 @@ static struct attribute *def_attrs[] =3D { NULL }; @@ -30911,9 +32317,10 @@ diff -urNp linux-2.6.32.49/drivers/firmware/memm= ap.c linux-2.6.32.49/drivers/fir .show =3D memmap_attr_show, }; =20 -diff -urNp linux-2.6.32.49/drivers/gpio/vr41xx_giu.c linux-2.6.32.49/dri= vers/gpio/vr41xx_giu.c ---- linux-2.6.32.49/drivers/gpio/vr41xx_giu.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/gpio/vr41xx_giu.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/gpio/vr41xx_giu.c b/drivers/gpio/vr41xx_giu.c +index b16c9a8..2af7d3f 100644 +--- a/drivers/gpio/vr41xx_giu.c ++++ b/drivers/gpio/vr41xx_giu.c @@ -204,7 +204,7 @@ static int giu_get_irq(unsigned int irq) printk(KERN_ERR "spurious GIU interrupt: %04x(%04x),%04x(%04x)\n", maskl, pendl, maskh, pendh); @@ -30923,10 +32330,11 @@ diff -urNp linux-2.6.32.49/drivers/gpio/vr41xx_= giu.c linux-2.6.32.49/drivers/gpi =20 return -EINVAL; } -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_crtc.c linux-2.6.32.49/dr= ivers/gpu/drm/drm_crtc.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_crtc.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_crtc.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -1323,7 +1323,7 @@ int drm_mode_getconnector(struct drm_dev +diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c +index bea6efc..3dc0f42 100644 +--- a/drivers/gpu/drm/drm_crtc.c ++++ b/drivers/gpu/drm/drm_crtc.c +@@ -1323,7 +1323,7 @@ int drm_mode_getconnector(struct drm_device *dev, = void *data, */ if ((out_resp->count_modes >=3D mode_count) && mode_count) { copied =3D 0; @@ -30935,7 +32343,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc.c linux-2.6.32.49/drivers/gp list_for_each_entry(mode, &connector->modes, head) { drm_crtc_convert_to_umode(&u_mode, mode); if (copy_to_user(mode_ptr + copied, -@@ -1338,8 +1338,8 @@ int drm_mode_getconnector(struct drm_dev +@@ -1338,8 +1338,8 @@ int drm_mode_getconnector(struct drm_device *dev, = void *data, =20 if ((out_resp->count_props >=3D props_count) && props_count) { copied =3D 0; @@ -30946,7 +32354,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc.c linux-2.6.32.49/drivers/gp for (i =3D 0; i < DRM_CONNECTOR_MAX_PROPERTY; i++) { if (connector->property_ids[i] !=3D 0) { if (put_user(connector->property_ids[i], -@@ -1361,7 +1361,7 @@ int drm_mode_getconnector(struct drm_dev +@@ -1361,7 +1361,7 @@ int drm_mode_getconnector(struct drm_device *dev, = void *data, =20 if ((out_resp->count_encoders >=3D encoders_count) && encoders_count) = { copied =3D 0; @@ -30955,7 +32363,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc.c linux-2.6.32.49/drivers/gp for (i =3D 0; i < DRM_CONNECTOR_MAX_ENCODER; i++) { if (connector->encoder_ids[i] !=3D 0) { if (put_user(connector->encoder_ids[i], -@@ -1513,7 +1513,7 @@ int drm_mode_setcrtc(struct drm_device * +@@ -1513,7 +1513,7 @@ int drm_mode_setcrtc(struct drm_device *dev, void = *data, } =20 for (i =3D 0; i < crtc_req->count_connectors; i++) { @@ -30964,7 +32372,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc.c linux-2.6.32.49/drivers/gp if (get_user(out_id, &set_connectors_ptr[i])) { ret =3D -EFAULT; goto out; -@@ -2118,7 +2118,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2118,7 +2118,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *= dev, out_resp->flags =3D property->flags; =20 if ((out_resp->count_values >=3D value_count) && value_count) { @@ -30973,7 +32381,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc.c linux-2.6.32.49/drivers/gp for (i =3D 0; i < value_count; i++) { if (copy_to_user(values_ptr + i, &property->values[i], sizeof(uint64= _t))) { ret =3D -EFAULT; -@@ -2131,7 +2131,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2131,7 +2131,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *= dev, if (property->flags & DRM_MODE_PROP_ENUM) { if ((out_resp->count_enum_blobs >=3D enum_count) && enum_count) { copied =3D 0; @@ -30982,7 +32390,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc.c linux-2.6.32.49/drivers/gp list_for_each_entry(prop_enum, &property->enum_blob_list, head) { =20 if (copy_to_user(&enum_ptr[copied].value, &prop_enum->value, sizeof= (uint64_t))) { -@@ -2154,7 +2154,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2154,7 +2154,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *= dev, if ((out_resp->count_enum_blobs >=3D blob_count) && blob_count) { copied =3D 0; blob_id_ptr =3D (uint32_t *)(unsigned long)out_resp->enum_blob_ptr; @@ -30991,7 +32399,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc.c linux-2.6.32.49/drivers/gp =20 list_for_each_entry(prop_blob, &property->enum_blob_list, head) { if (put_user(prop_blob->base.id, blob_id_ptr + copied)) { -@@ -2226,7 +2226,7 @@ int drm_mode_getblob_ioctl(struct drm_de +@@ -2226,7 +2226,7 @@ int drm_mode_getblob_ioctl(struct drm_device *dev, blob =3D obj_to_blob(obj); =20 if (out_resp->length =3D=3D blob->length) { @@ -31000,10 +32408,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= crtc.c linux-2.6.32.49/drivers/gp if (copy_to_user(blob_ptr, blob->data, blob->length)){ ret =3D -EFAULT; goto done; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_crtc_helper.c linux-2.6.3= 2.49/drivers/gpu/drm/drm_crtc_helper.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_crtc_helper.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_crtc_helper.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -573,7 +573,7 @@ static bool drm_encoder_crtc_ok(struct d +diff --git a/drivers/gpu/drm/drm_crtc_helper.c b/drivers/gpu/drm/drm_crt= c_helper.c +index 1b8745d..92fdbf6 100644 +--- a/drivers/gpu/drm/drm_crtc_helper.c ++++ b/drivers/gpu/drm/drm_crtc_helper.c +@@ -573,7 +573,7 @@ static bool drm_encoder_crtc_ok(struct drm_encoder *= encoder, struct drm_crtc *tmp; int crtc_mask =3D 1; =20 @@ -31012,7 +32421,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_cr= tc_helper.c linux-2.6.32.49/dri =20 dev =3D crtc->dev; =20 -@@ -642,6 +642,8 @@ bool drm_crtc_helper_set_mode(struct drm +@@ -642,6 +642,8 @@ bool drm_crtc_helper_set_mode(struct drm_crtc *crtc, =20 adjusted_mode =3D drm_mode_duplicate(dev, mode); =20 @@ -31021,10 +32430,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= crtc_helper.c linux-2.6.32.49/dri crtc->enabled =3D drm_helper_crtc_in_use(crtc); =20 if (!crtc->enabled) -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_drv.c linux-2.6.32.49/dri= vers/gpu/drm/drm_drv.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_drv.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_drv.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -417,7 +417,7 @@ int drm_ioctl(struct inode *inode, struc +diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c +index 0e27d98..dec8768 100644 +--- a/drivers/gpu/drm/drm_drv.c ++++ b/drivers/gpu/drm/drm_drv.c +@@ -417,7 +417,7 @@ int drm_ioctl(struct inode *inode, struct file *filp= , char *kdata =3D NULL; =20 atomic_inc(&dev->ioctl_count); @@ -31033,10 +32443,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= drv.c linux-2.6.32.49/drivers/gpu ++file_priv->ioctl_count; =20 DRM_DEBUG("pid=3D%d, cmd=3D0x%02x, nr=3D0x%02x, dev 0x%lx, auth=3D%d\n= ", -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_fops.c linux-2.6.32.49/dr= ivers/gpu/drm/drm_fops.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_fops.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_fops.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -66,7 +66,7 @@ static int drm_setup(struct drm_device * +diff --git a/drivers/gpu/drm/drm_fops.c b/drivers/gpu/drm/drm_fops.c +index ba14553..182d0bb 100644 +--- a/drivers/gpu/drm/drm_fops.c ++++ b/drivers/gpu/drm/drm_fops.c +@@ -66,7 +66,7 @@ static int drm_setup(struct drm_device * dev) } =20 for (i =3D 0; i < ARRAY_SIZE(dev->counts); i++) @@ -31045,7 +32456,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_fo= ps.c linux-2.6.32.49/drivers/gp =20 dev->sigdata.lock =3D NULL; =20 -@@ -130,9 +130,9 @@ int drm_open(struct inode *inode, struct +@@ -130,9 +130,9 @@ int drm_open(struct inode *inode, struct file *filp) =20 retcode =3D drm_open_helper(inode, filp, dev); if (!retcode) { @@ -31057,7 +32468,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_fo= ps.c linux-2.6.32.49/drivers/gp spin_unlock(&dev->count_lock); retcode =3D drm_setup(dev); goto out; -@@ -435,7 +435,7 @@ int drm_release(struct inode *inode, str +@@ -435,7 +435,7 @@ int drm_release(struct inode *inode, struct file *fi= lp) =20 lock_kernel(); =20 @@ -31066,7 +32477,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_fo= ps.c linux-2.6.32.49/drivers/gp =20 if (dev->driver->preclose) dev->driver->preclose(dev, file_priv); -@@ -447,7 +447,7 @@ int drm_release(struct inode *inode, str +@@ -447,7 +447,7 @@ int drm_release(struct inode *inode, struct file *fi= lp) DRM_DEBUG("pid =3D %d, device =3D 0x%lx, open_count =3D %d\n", task_pid_nr(current), (long)old_encode_dev(file_priv->minor->device), @@ -31075,7 +32486,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_fo= ps.c linux-2.6.32.49/drivers/gp =20 /* if the master has gone away we can't do anything with the lock */ if (file_priv->minor->master) -@@ -524,9 +524,9 @@ int drm_release(struct inode *inode, str +@@ -524,9 +524,9 @@ int drm_release(struct inode *inode, struct file *fi= lp) * End inline drm_release */ =20 @@ -31087,9 +32498,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_f= ops.c linux-2.6.32.49/drivers/gp if (atomic_read(&dev->ioctl_count)) { DRM_ERROR("Device busy: %d\n", atomic_read(&dev->ioctl_count)); -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_gem.c linux-2.6.32.49/dri= vers/gpu/drm/drm_gem.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_gem.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_gem.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/gpu/drm/drm_gem.c b/drivers/gpu/drm/drm_gem.c +index 8bf3770..7942280 100644 +--- a/drivers/gpu/drm/drm_gem.c ++++ b/drivers/gpu/drm/drm_gem.c @@ -83,11 +83,11 @@ drm_gem_init(struct drm_device *dev) spin_lock_init(&dev->object_name_lock); idr_init(&dev->object_name_idr); @@ -31105,7 +32517,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_ge= m.c linux-2.6.32.49/drivers/gpu =20 mm =3D kzalloc(sizeof(struct drm_gem_mm), GFP_KERNEL); if (!mm) { -@@ -150,7 +150,7 @@ drm_gem_object_alloc(struct drm_device * +@@ -150,7 +150,7 @@ drm_gem_object_alloc(struct drm_device *dev, size_t = size) goto fput; } atomic_inc(&dev->object_count); @@ -31123,10 +32535,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= gem.c linux-2.6.32.49/drivers/gpu kfree(obj); } EXPORT_SYMBOL(drm_gem_object_free); -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_info.c linux-2.6.32.49/dr= ivers/gpu/drm/drm_info.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_info.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_info.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -75,10 +75,14 @@ int drm_vm_info(struct seq_file *m, void +diff --git a/drivers/gpu/drm/drm_info.c b/drivers/gpu/drm/drm_info.c +index f0f6c6b..34af322 100644 +--- a/drivers/gpu/drm/drm_info.c ++++ b/drivers/gpu/drm/drm_info.c +@@ -75,10 +75,14 @@ int drm_vm_info(struct seq_file *m, void *data) struct drm_local_map *map; struct drm_map_list *r_list; =20 @@ -31145,7 +32558,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_in= fo.c linux-2.6.32.49/drivers/gp const char *type; int i; =20 -@@ -89,7 +93,7 @@ int drm_vm_info(struct seq_file *m, void +@@ -89,7 +93,7 @@ int drm_vm_info(struct seq_file *m, void *data) map =3D r_list->map; if (!map) continue; @@ -31154,7 +32567,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_in= fo.c linux-2.6.32.49/drivers/gp type =3D "??"; else type =3D types[map->type]; -@@ -265,10 +269,10 @@ int drm_gem_object_info(struct seq_file=20 +@@ -265,10 +269,10 @@ int drm_gem_object_info(struct seq_file *m, void* = data) struct drm_device *dev =3D node->minor->dev; =20 seq_printf(m, "%d objects\n", atomic_read(&dev->object_count)); @@ -31168,7 +32581,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_in= fo.c linux-2.6.32.49/drivers/gp seq_printf(m, "%d gtt total\n", dev->gtt_total); return 0; } -@@ -288,7 +292,11 @@ int drm_vma_info(struct seq_file *m, voi +@@ -288,7 +292,11 @@ int drm_vma_info(struct seq_file *m, void *data) mutex_lock(&dev->struct_mutex); seq_printf(m, "vma use count: %d, high_memory =3D %p, 0x%08llx\n", atomic_read(&dev->vma_count), @@ -31180,7 +32593,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_in= fo.c linux-2.6.32.49/drivers/gp =20 list_for_each_entry(pt, &dev->vmalist, head) { vma =3D pt->vma; -@@ -296,14 +304,23 @@ int drm_vma_info(struct seq_file *m, voi +@@ -296,14 +304,23 @@ int drm_vma_info(struct seq_file *m, void *data) continue; seq_printf(m, "\n%5d 0x%08lx-0x%08lx %c%c%c%c%c%c 0x%08lx000", @@ -31205,10 +32618,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= info.c linux-2.6.32.49/drivers/gp =20 #if defined(__i386__) pgprot =3D pgprot_val(vma->vm_page_prot); -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_ioc32.c linux-2.6.32.49/d= rivers/gpu/drm/drm_ioc32.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_ioc32.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_ioc32.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -463,7 +463,7 @@ static int compat_drm_infobufs(struct fi +diff --git a/drivers/gpu/drm/drm_ioc32.c b/drivers/gpu/drm/drm_ioc32.c +index 282d9fd..71e5f11 100644 +--- a/drivers/gpu/drm/drm_ioc32.c ++++ b/drivers/gpu/drm/drm_ioc32.c +@@ -463,7 +463,7 @@ static int compat_drm_infobufs(struct file *file, un= signed int cmd, request =3D compat_alloc_user_space(nbytes); if (!access_ok(VERIFY_WRITE, request, nbytes)) return -EFAULT; @@ -31217,7 +32631,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_io= c32.c linux-2.6.32.49/drivers/g =20 if (__put_user(count, &request->count) || __put_user(list, &request->list)) -@@ -525,7 +525,7 @@ static int compat_drm_mapbufs(struct fil +@@ -525,7 +525,7 @@ static int compat_drm_mapbufs(struct file *file, uns= igned int cmd, request =3D compat_alloc_user_space(nbytes); if (!access_ok(VERIFY_WRITE, request, nbytes)) return -EFAULT; @@ -31226,10 +32640,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= ioc32.c linux-2.6.32.49/drivers/g =20 if (__put_user(count, &request->count) || __put_user(list, &request->list)) -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_ioctl.c linux-2.6.32.49/d= rivers/gpu/drm/drm_ioctl.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_ioctl.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_ioctl.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -283,7 +283,7 @@ int drm_getstats(struct drm_device *dev, +diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c +index 9b9ff46..4ea724c 100644 +--- a/drivers/gpu/drm/drm_ioctl.c ++++ b/drivers/gpu/drm/drm_ioctl.c +@@ -283,7 +283,7 @@ int drm_getstats(struct drm_device *dev, void *data, stats->data[i].value =3D (file_priv->master->lock.hw_lock ? file_priv->master->lock.hw_lo= ck->lock : 0); else @@ -31238,10 +32653,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= ioctl.c linux-2.6.32.49/drivers/g stats->data[i].type =3D dev->types[i]; } =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_lock.c linux-2.6.32.49/dr= ivers/gpu/drm/drm_lock.c ---- linux-2.6.32.49/drivers/gpu/drm/drm_lock.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/drm_lock.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -87,7 +87,7 @@ int drm_lock(struct drm_device *dev, voi +diff --git a/drivers/gpu/drm/drm_lock.c b/drivers/gpu/drm/drm_lock.c +index e2f70a5..c703e86 100644 +--- a/drivers/gpu/drm/drm_lock.c ++++ b/drivers/gpu/drm/drm_lock.c +@@ -87,7 +87,7 @@ int drm_lock(struct drm_device *dev, void *data, struc= t drm_file *file_priv) if (drm_lock_take(&master->lock, lock->context)) { master->lock.file_priv =3D file_priv; master->lock.lock_time =3D jiffies; @@ -31250,7 +32666,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_lo= ck.c linux-2.6.32.49/drivers/gp break; /* Got lock */ } =20 -@@ -165,7 +165,7 @@ int drm_unlock(struct drm_device *dev, v +@@ -165,7 +165,7 @@ int drm_unlock(struct drm_device *dev, void *data, s= truct drm_file *file_priv) return -EINVAL; } =20 @@ -31259,10 +32675,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/drm_= lock.c linux-2.6.32.49/drivers/gp =20 /* kernel_context_switch isn't used by any of the x86 drm * modules but is required by the Sparc driver. -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i810/i810_dma.c linux-2.6.32.= 49/drivers/gpu/drm/i810/i810_dma.c ---- linux-2.6.32.49/drivers/gpu/drm/i810/i810_dma.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i810/i810_dma.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -952,8 +952,8 @@ static int i810_dma_vertex(struct drm_de +diff --git a/drivers/gpu/drm/i810/i810_dma.c b/drivers/gpu/drm/i810/i810= _dma.c +index 7d1d88c..b9131b2 100644 +--- a/drivers/gpu/drm/i810/i810_dma.c ++++ b/drivers/gpu/drm/i810/i810_dma.c +@@ -952,8 +952,8 @@ static int i810_dma_vertex(struct drm_device *dev, v= oid *data, dma->buflist[vertex->idx], vertex->discard, vertex->used); =20 @@ -31273,7 +32690,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i810/i= 810_dma.c linux-2.6.32.49/drive sarea_priv->last_enqueue =3D dev_priv->counter - 1; sarea_priv->last_dispatch =3D (int)hw_status[5]; =20 -@@ -1115,8 +1115,8 @@ static int i810_dma_mc(struct drm_device +@@ -1115,8 +1115,8 @@ static int i810_dma_mc(struct drm_device *dev, voi= d *data, i810_dma_dispatch_mc(dev, dma->buflist[mc->idx], mc->used, mc->last_render); =20 @@ -31284,9 +32701,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i810/= i810_dma.c linux-2.6.32.49/drive sarea_priv->last_enqueue =3D dev_priv->counter - 1; sarea_priv->last_dispatch =3D (int)hw_status[5]; =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i810/i810_drv.h linux-2.6.32.= 49/drivers/gpu/drm/i810/i810_drv.h ---- linux-2.6.32.49/drivers/gpu/drm/i810/i810_drv.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i810/i810_drv.h 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/gpu/drm/i810/i810_drv.h b/drivers/gpu/drm/i810/i810= _drv.h +index 21e2691..7321edd 100644 +--- a/drivers/gpu/drm/i810/i810_drv.h ++++ b/drivers/gpu/drm/i810/i810_drv.h @@ -108,8 +108,8 @@ typedef struct drm_i810_private { int page_flipping; =20 @@ -31298,9 +32716,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i810/= i810_drv.h linux-2.6.32.49/drive =20 int front_offset; } drm_i810_private_t; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830/i830_drv.h linux-2.6.32.= 49/drivers/gpu/drm/i830/i830_drv.h ---- linux-2.6.32.49/drivers/gpu/drm/i830/i830_drv.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i830/i830_drv.h 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/gpu/drm/i830/i830_drv.h b/drivers/gpu/drm/i830/i830= _drv.h +index da82afe..48a45de 100644 +--- a/drivers/gpu/drm/i830/i830_drv.h ++++ b/drivers/gpu/drm/i830/i830_drv.h @@ -115,8 +115,8 @@ typedef struct drm_i830_private { int page_flipping; =20 @@ -31312,10 +32731,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830= /i830_drv.h linux-2.6.32.49/drive =20 int use_mi_batchbuffer_start; =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830/i830_irq.c linux-2.6.32.= 49/drivers/gpu/drm/i830/i830_irq.c ---- linux-2.6.32.49/drivers/gpu/drm/i830/i830_irq.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i830/i830_irq.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -47,7 +47,7 @@ irqreturn_t i830_driver_irq_handler(DRM_ +diff --git a/drivers/gpu/drm/i830/i830_irq.c b/drivers/gpu/drm/i830/i830= _irq.c +index 91ec2bb..6f21fab 100644 +--- a/drivers/gpu/drm/i830/i830_irq.c ++++ b/drivers/gpu/drm/i830/i830_irq.c +@@ -47,7 +47,7 @@ irqreturn_t i830_driver_irq_handler(DRM_IRQ_ARGS) =20 I830_WRITE16(I830REG_INT_IDENTITY_R, temp); =20 @@ -31324,7 +32744,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830/i= 830_irq.c linux-2.6.32.49/drive wake_up_interruptible(&dev_priv->irq_queue); =20 return IRQ_HANDLED; -@@ -60,14 +60,14 @@ static int i830_emit_irq(struct drm_devi +@@ -60,14 +60,14 @@ static int i830_emit_irq(struct drm_device * dev) =20 DRM_DEBUG("%s\n", __func__); =20 @@ -31341,7 +32761,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830/i= 830_irq.c linux-2.6.32.49/drive } =20 static int i830_wait_irq(struct drm_device * dev, int irq_nr) -@@ -79,7 +79,7 @@ static int i830_wait_irq(struct drm_devi +@@ -79,7 +79,7 @@ static int i830_wait_irq(struct drm_device * dev, int = irq_nr) =20 DRM_DEBUG("%s\n", __func__); =20 @@ -31350,7 +32770,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830/i= 830_irq.c linux-2.6.32.49/drive return 0; =20 dev_priv->sarea_priv->perf_boxes |=3D I830_BOX_WAIT; -@@ -88,7 +88,7 @@ static int i830_wait_irq(struct drm_devi +@@ -88,7 +88,7 @@ static int i830_wait_irq(struct drm_device * dev, int = irq_nr) =20 for (;;) { __set_current_state(TASK_INTERRUPTIBLE); @@ -31359,7 +32779,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830/i= 830_irq.c linux-2.6.32.49/drive break; if ((signed)(end - jiffies) <=3D 0) { DRM_ERROR("timeout iir %x imr %x ier %x hwstam %x\n", -@@ -163,8 +163,8 @@ void i830_driver_irq_preinstall(struct d +@@ -163,8 +163,8 @@ void i830_driver_irq_preinstall(struct drm_device * = dev) I830_WRITE16(I830REG_HWSTAM, 0xffff); I830_WRITE16(I830REG_INT_MASK_R, 0x0); I830_WRITE16(I830REG_INT_ENABLE_R, 0x0); @@ -31370,33 +32790,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i830= /i830_irq.c linux-2.6.32.49/drive init_waitqueue_head(&dev_priv->irq_queue); } =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ch7017.c linux-2.6.3= 2.49/drivers/gpu/drm/i915/dvo_ch7017.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ch7017.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ch7017.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -443,7 +443,7 @@ static void ch7017_destroy(struct intel_ - } - } -=20 --struct intel_dvo_dev_ops ch7017_ops =3D { -+const struct intel_dvo_dev_ops ch7017_ops =3D { - .init =3D ch7017_init, - .detect =3D ch7017_detect, - .mode_valid =3D ch7017_mode_valid, -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ch7xxx.c linux-2.6.3= 2.49/drivers/gpu/drm/i915/dvo_ch7xxx.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ch7xxx.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ch7xxx.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -356,7 +356,7 @@ static void ch7xxx_destroy(struct intel_ - } - } -=20 --struct intel_dvo_dev_ops ch7xxx_ops =3D { -+const struct intel_dvo_dev_ops ch7xxx_ops =3D { - .init =3D ch7xxx_init, - .detect =3D ch7xxx_detect, - .mode_valid =3D ch7xxx_mode_valid, -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/dvo.h linux-2.6.32.49/dr= ivers/gpu/drm/i915/dvo.h ---- linux-2.6.32.49/drivers/gpu/drm/i915/dvo.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/dvo.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/drivers/gpu/drm/i915/dvo.h b/drivers/gpu/drm/i915/dvo.h +index 288fc50..c6092055 100644 +--- a/drivers/gpu/drm/i915/dvo.h ++++ b/drivers/gpu/drm/i915/dvo.h @@ -135,23 +135,23 @@ struct intel_dvo_dev_ops { * * \return singly-linked list of modes or NULL if no modes found. @@ -31429,10 +32826,37 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915= /dvo.h linux-2.6.32.49/drivers/gp +extern const struct intel_dvo_dev_ops ch7017_ops; =20 #endif /* _INTEL_DVO_H */ -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ivch.c linux-2.6.32.= 49/drivers/gpu/drm/i915/dvo_ivch.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ivch.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/dvo_ivch.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -430,7 +430,7 @@ static void ivch_destroy(struct intel_dv +diff --git a/drivers/gpu/drm/i915/dvo_ch7017.c b/drivers/gpu/drm/i915/dv= o_ch7017.c +index 621815b..499d82e 100644 +--- a/drivers/gpu/drm/i915/dvo_ch7017.c ++++ b/drivers/gpu/drm/i915/dvo_ch7017.c +@@ -443,7 +443,7 @@ static void ch7017_destroy(struct intel_dvo_device *= dvo) + } + } +=20 +-struct intel_dvo_dev_ops ch7017_ops =3D { ++const struct intel_dvo_dev_ops ch7017_ops =3D { + .init =3D ch7017_init, + .detect =3D ch7017_detect, + .mode_valid =3D ch7017_mode_valid, +diff --git a/drivers/gpu/drm/i915/dvo_ch7xxx.c b/drivers/gpu/drm/i915/dv= o_ch7xxx.c +index a9b8962..ac769ba 100644 +--- a/drivers/gpu/drm/i915/dvo_ch7xxx.c ++++ b/drivers/gpu/drm/i915/dvo_ch7xxx.c +@@ -356,7 +356,7 @@ static void ch7xxx_destroy(struct intel_dvo_device *= dvo) + } + } +=20 +-struct intel_dvo_dev_ops ch7xxx_ops =3D { ++const struct intel_dvo_dev_ops ch7xxx_ops =3D { + .init =3D ch7xxx_init, + .detect =3D ch7xxx_detect, + .mode_valid =3D ch7xxx_mode_valid, +diff --git a/drivers/gpu/drm/i915/dvo_ivch.c b/drivers/gpu/drm/i915/dvo_= ivch.c +index aa176f9..ed2930c 100644 +--- a/drivers/gpu/drm/i915/dvo_ivch.c ++++ b/drivers/gpu/drm/i915/dvo_ivch.c +@@ -430,7 +430,7 @@ static void ivch_destroy(struct intel_dvo_device *dv= o) } } =20 @@ -31441,10 +32865,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915= /dvo_ivch.c linux-2.6.32.49/drive .init =3D ivch_init, .dpms =3D ivch_dpms, .save =3D ivch_save, -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/dvo_sil164.c linux-2.6.3= 2.49/drivers/gpu/drm/i915/dvo_sil164.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/dvo_sil164.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/dvo_sil164.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -290,7 +290,7 @@ static void sil164_destroy(struct intel_ +diff --git a/drivers/gpu/drm/i915/dvo_sil164.c b/drivers/gpu/drm/i915/dv= o_sil164.c +index e1c1f73..7dbebcf 100644 +--- a/drivers/gpu/drm/i915/dvo_sil164.c ++++ b/drivers/gpu/drm/i915/dvo_sil164.c +@@ -290,7 +290,7 @@ static void sil164_destroy(struct intel_dvo_device *= dvo) } } =20 @@ -31453,10 +32878,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915= /dvo_sil164.c linux-2.6.32.49/dri .init =3D sil164_init, .detect =3D sil164_detect, .mode_valid =3D sil164_mode_valid, -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/dvo_tfp410.c linux-2.6.3= 2.49/drivers/gpu/drm/i915/dvo_tfp410.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/dvo_tfp410.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/dvo_tfp410.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -323,7 +323,7 @@ static void tfp410_destroy(struct intel_ +diff --git a/drivers/gpu/drm/i915/dvo_tfp410.c b/drivers/gpu/drm/i915/dv= o_tfp410.c +index 16dce84..7e1b6f8 100644 +--- a/drivers/gpu/drm/i915/dvo_tfp410.c ++++ b/drivers/gpu/drm/i915/dvo_tfp410.c +@@ -323,7 +323,7 @@ static void tfp410_destroy(struct intel_dvo_device *= dvo) } } =20 @@ -31465,10 +32891,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915= /dvo_tfp410.c linux-2.6.32.49/dri .init =3D tfp410_init, .detect =3D tfp410_detect, .mode_valid =3D tfp410_mode_valid, -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i915_debugfs.c linux-2.6= .32.49/drivers/gpu/drm/i915/i915_debugfs.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/i915_debugfs.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/i915_debugfs.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -192,7 +192,7 @@ static int i915_interrupt_info(struct se +diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/= i915_debugfs.c +index 7e859d6..7d1cf2b 100644 +--- a/drivers/gpu/drm/i915/i915_debugfs.c ++++ b/drivers/gpu/drm/i915/i915_debugfs.c +@@ -192,7 +192,7 @@ static int i915_interrupt_info(struct seq_file *m, v= oid *data) I915_READ(GTIMR)); } seq_printf(m, "Interrupts received: %d\n", @@ -31477,9 +32904,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/= i915_debugfs.c linux-2.6.32.49/d if (dev_priv->hw_status_page !=3D NULL) { seq_printf(m, "Current sequence: %d\n", i915_get_gem_seqno(dev)); -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i915_drv.c linux-2.6.32.= 49/drivers/gpu/drm/i915/i915_drv.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/i915_drv.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/i915_drv.c 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915= _drv.c +index 5449239..7e4f68d 100644 +--- a/drivers/gpu/drm/i915/i915_drv.c ++++ b/drivers/gpu/drm/i915/i915_drv.c @@ -285,7 +285,7 @@ i915_pci_resume(struct pci_dev *pdev) return i915_resume(dev); } @@ -31489,9 +32917,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/= i915_drv.c linux-2.6.32.49/drive .fault =3D i915_gem_fault, .open =3D drm_gem_vm_open, .close =3D drm_gem_vm_close, -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i915_drv.h linux-2.6.32.= 49/drivers/gpu/drm/i915/i915_drv.h ---- linux-2.6.32.49/drivers/gpu/drm/i915/i915_drv.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/i915_drv.h 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915= _drv.h +index 97163f7..c24c7c7 100644 +--- a/drivers/gpu/drm/i915/i915_drv.h ++++ b/drivers/gpu/drm/i915/i915_drv.h @@ -168,7 +168,7 @@ struct drm_i915_display_funcs { /* display clock increase/decrease */ /* pll clock increase/decrease */ @@ -31510,10 +32939,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915= /i915_drv.h linux-2.6.32.49/drive /** Protects user_irq_refcount and irq_mask_reg */ spinlock_t user_irq_lock; /** Refcount for i915_user_irq_get() versus i915_user_irq_put(). */ -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i915_gem.c linux-2.6.32.= 49/drivers/gpu/drm/i915/i915_gem.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/i915_gem.c 2011-11-26 19:44:53.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/i915_gem.c 2011-11-26 19:55:10.= 000000000 -0500 -@@ -102,7 +102,7 @@ i915_gem_get_aperture_ioctl(struct drm_d +diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915= _gem.c +index 27a3074..eb3f959 100644 +--- a/drivers/gpu/drm/i915/i915_gem.c ++++ b/drivers/gpu/drm/i915/i915_gem.c +@@ -102,7 +102,7 @@ i915_gem_get_aperture_ioctl(struct drm_device *dev, = void *data, =20 args->aper_size =3D dev->gtt_total; args->aper_available_size =3D (args->aper_size - @@ -31522,7 +32952,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i= 915_gem.c linux-2.6.32.49/drive =20 return 0; } -@@ -2058,7 +2058,7 @@ i915_gem_object_unbind(struct drm_gem_ob +@@ -2058,7 +2058,7 @@ i915_gem_object_unbind(struct drm_gem_object *obj) =20 if (obj_priv->gtt_space) { atomic_dec(&dev->gtt_count); @@ -31531,7 +32961,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i= 915_gem.c linux-2.6.32.49/drive =20 drm_mm_put_block(obj_priv->gtt_space); obj_priv->gtt_space =3D NULL; -@@ -2701,7 +2701,7 @@ i915_gem_object_bind_to_gtt(struct drm_g +@@ -2701,7 +2701,7 @@ i915_gem_object_bind_to_gtt(struct drm_gem_object = *obj, unsigned alignment) goto search_free; } atomic_inc(&dev->gtt_count); @@ -31540,7 +32970,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i= 915_gem.c linux-2.6.32.49/drive =20 /* Assert that the object is not currently in any GPU domain. As it * wasn't in the GTT, there shouldn't be any way it could have been in -@@ -3755,9 +3755,9 @@ i915_gem_execbuffer(struct drm_device *d +@@ -3755,9 +3755,9 @@ i915_gem_execbuffer(struct drm_device *dev, void *= data, "%d/%d gtt bytes\n", atomic_read(&dev->object_count), atomic_read(&dev->pin_count), @@ -31553,7 +32983,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i= 915_gem.c linux-2.6.32.49/drive dev->gtt_total); } goto err; -@@ -3989,7 +3989,7 @@ i915_gem_object_pin(struct drm_gem_objec +@@ -3989,7 +3989,7 @@ i915_gem_object_pin(struct drm_gem_object *obj, ui= nt32_t alignment) */ if (obj_priv->pin_count =3D=3D 1) { atomic_inc(&dev->pin_count); @@ -31562,7 +32992,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i= 915_gem.c linux-2.6.32.49/drive if (!obj_priv->active && (obj->write_domain & I915_GEM_GPU_DOMAINS) =3D=3D 0 && !list_empty(&obj_priv->list)) -@@ -4022,7 +4022,7 @@ i915_gem_object_unpin(struct drm_gem_obj +@@ -4022,7 +4022,7 @@ i915_gem_object_unpin(struct drm_gem_object *obj) list_move_tail(&obj_priv->list, &dev_priv->mm.inactive_list); atomic_dec(&dev->pin_count); @@ -31571,10 +33001,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915= /i915_gem.c linux-2.6.32.49/drive } i915_verify_inactive(dev, __FILE__, __LINE__); } -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i915_irq.c linux-2.6.32.= 49/drivers/gpu/drm/i915/i915_irq.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/i915_irq.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/i915_irq.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -528,7 +528,7 @@ irqreturn_t i915_driver_irq_handler(DRM_ +diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915= _irq.c +index 63f28ad..f5469da 100644 +--- a/drivers/gpu/drm/i915/i915_irq.c ++++ b/drivers/gpu/drm/i915/i915_irq.c +@@ -528,7 +528,7 @@ irqreturn_t i915_driver_irq_handler(DRM_IRQ_ARGS) int irq_received; int ret =3D IRQ_NONE; =20 @@ -31583,7 +33014,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/i= 915_irq.c linux-2.6.32.49/drive =20 if (IS_IGDNG(dev)) return igdng_irq_handler(dev); -@@ -1021,7 +1021,7 @@ void i915_driver_irq_preinstall(struct d +@@ -1021,7 +1021,7 @@ void i915_driver_irq_preinstall(struct drm_device = * dev) { drm_i915_private_t *dev_priv =3D (drm_i915_private_t *) dev->dev_priva= te; =20 @@ -31592,10 +33023,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915= /i915_irq.c linux-2.6.32.49/drive =20 INIT_WORK(&dev_priv->hotplug_work, i915_hotplug_work_func); INIT_WORK(&dev_priv->error_work, i915_error_work_func); -diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/intel_sdvo.c linux-2.6.3= 2.49/drivers/gpu/drm/i915/intel_sdvo.c ---- linux-2.6.32.49/drivers/gpu/drm/i915/intel_sdvo.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/i915/intel_sdvo.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -2795,7 +2795,9 @@ bool intel_sdvo_init(struct drm_device * +diff --git a/drivers/gpu/drm/i915/intel_sdvo.c b/drivers/gpu/drm/i915/in= tel_sdvo.c +index 5d9c6a7..d1b0e29 100644 +--- a/drivers/gpu/drm/i915/intel_sdvo.c ++++ b/drivers/gpu/drm/i915/intel_sdvo.c +@@ -2795,7 +2795,9 @@ bool intel_sdvo_init(struct drm_device *dev, int o= utput_device) sdvo_priv->slave_addr =3D intel_sdvo_get_slave_addr(dev, output_device= ); =20 /* Save the bit-banging i2c functionality for use by the DDC wrapper *= / @@ -31606,9 +33038,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/i915/= intel_sdvo.c linux-2.6.32.49/dri =20 /* Read the regs to test if we can talk to the device */ for (i =3D 0; i < 0x40; i++) { -diff -urNp linux-2.6.32.49/drivers/gpu/drm/mga/mga_drv.h linux-2.6.32.49= /drivers/gpu/drm/mga/mga_drv.h ---- linux-2.6.32.49/drivers/gpu/drm/mga/mga_drv.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/mga/mga_drv.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/drivers/gpu/drm/mga/mga_drv.h b/drivers/gpu/drm/mga/mga_drv= .h +index be6c6b9..8615d9c 100644 +--- a/drivers/gpu/drm/mga/mga_drv.h ++++ b/drivers/gpu/drm/mga/mga_drv.h @@ -120,9 +120,9 @@ typedef struct drm_mga_private { u32 clear_cmd; u32 maccess; @@ -31621,10 +33054,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/mga/= mga_drv.h linux-2.6.32.49/drivers u32 next_fence_to_post; =20 unsigned int fb_cpp; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/mga/mga_irq.c linux-2.6.32.49= /drivers/gpu/drm/mga/mga_irq.c ---- linux-2.6.32.49/drivers/gpu/drm/mga/mga_irq.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/mga/mga_irq.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -44,7 +44,7 @@ u32 mga_get_vblank_counter(struct drm_de +diff --git a/drivers/gpu/drm/mga/mga_irq.c b/drivers/gpu/drm/mga/mga_irq= .c +index daa6041..a28a5da 100644 +--- a/drivers/gpu/drm/mga/mga_irq.c ++++ b/drivers/gpu/drm/mga/mga_irq.c +@@ -44,7 +44,7 @@ u32 mga_get_vblank_counter(struct drm_device *dev, int= crtc) if (crtc !=3D 0) return 0; =20 @@ -31633,7 +33067,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/mga/mg= a_irq.c linux-2.6.32.49/drivers } =20 =20 -@@ -60,7 +60,7 @@ irqreturn_t mga_driver_irq_handler(DRM_I +@@ -60,7 +60,7 @@ irqreturn_t mga_driver_irq_handler(DRM_IRQ_ARGS) /* VBLANK interrupt */ if (status & MGA_VLINEPEN) { MGA_WRITE(MGA_ICLEAR, MGA_VLINEICLR); @@ -31642,7 +33076,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/mga/mg= a_irq.c linux-2.6.32.49/drivers drm_handle_vblank(dev, 0); handled =3D 1; } -@@ -80,7 +80,7 @@ irqreturn_t mga_driver_irq_handler(DRM_I +@@ -80,7 +80,7 @@ irqreturn_t mga_driver_irq_handler(DRM_IRQ_ARGS) MGA_WRITE(MGA_PRIMEND, prim_end); } =20 @@ -31651,7 +33085,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/mga/mg= a_irq.c linux-2.6.32.49/drivers DRM_WAKEUP(&dev_priv->fence_queue); handled =3D 1; } -@@ -131,7 +131,7 @@ int mga_driver_fence_wait(struct drm_dev +@@ -131,7 +131,7 @@ int mga_driver_fence_wait(struct drm_device * dev, u= nsigned int *sequence) * using fences. */ DRM_WAIT_ON(ret, dev_priv->fence_queue, 3 * DRM_HZ, @@ -31660,10 +33094,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/mga/= mga_irq.c linux-2.6.32.49/drivers - *sequence) <=3D (1 << 23))); =20 *sequence =3D cur_fence; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128/r128_cce.c linux-2.6.32.= 49/drivers/gpu/drm/r128/r128_cce.c ---- linux-2.6.32.49/drivers/gpu/drm/r128/r128_cce.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/r128/r128_cce.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -377,7 +377,7 @@ static int r128_do_init_cce(struct drm_d +diff --git a/drivers/gpu/drm/r128/r128_cce.c b/drivers/gpu/drm/r128/r128= _cce.c +index 4c39a40..b22a9ea 100644 +--- a/drivers/gpu/drm/r128/r128_cce.c ++++ b/drivers/gpu/drm/r128/r128_cce.c +@@ -377,7 +377,7 @@ static int r128_do_init_cce(struct drm_device * dev,= drm_r128_init_t * init) =20 /* GH: Simple idle check. */ @@ -31672,9 +33107,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128/= r128_cce.c linux-2.6.32.49/drive =20 /* We don't support anything other than bus-mastering ring mode, * but the ring can be in either AGP or PCI space for the ring -diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128/r128_drv.h linux-2.6.32.= 49/drivers/gpu/drm/r128/r128_drv.h ---- linux-2.6.32.49/drivers/gpu/drm/r128/r128_drv.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/r128/r128_drv.h 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/gpu/drm/r128/r128_drv.h b/drivers/gpu/drm/r128/r128= _drv.h +index 3c60829..4faf484 100644 +--- a/drivers/gpu/drm/r128/r128_drv.h ++++ b/drivers/gpu/drm/r128/r128_drv.h @@ -90,14 +90,14 @@ typedef struct drm_r128_private { int is_pci; unsigned long cce_buffers_offset; @@ -31692,10 +33128,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128= /r128_drv.h linux-2.6.32.49/drive =20 u32 color_fmt; unsigned int front_offset; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128/r128_irq.c linux-2.6.32.= 49/drivers/gpu/drm/r128/r128_irq.c ---- linux-2.6.32.49/drivers/gpu/drm/r128/r128_irq.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/r128/r128_irq.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -42,7 +42,7 @@ u32 r128_get_vblank_counter(struct drm_d +diff --git a/drivers/gpu/drm/r128/r128_irq.c b/drivers/gpu/drm/r128/r128= _irq.c +index 69810fb..97bf17a 100644 +--- a/drivers/gpu/drm/r128/r128_irq.c ++++ b/drivers/gpu/drm/r128/r128_irq.c +@@ -42,7 +42,7 @@ u32 r128_get_vblank_counter(struct drm_device *dev, in= t crtc) if (crtc !=3D 0) return 0; =20 @@ -31704,7 +33141,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128/r= 128_irq.c linux-2.6.32.49/drive } =20 irqreturn_t r128_driver_irq_handler(DRM_IRQ_ARGS) -@@ -56,7 +56,7 @@ irqreturn_t r128_driver_irq_handler(DRM_ +@@ -56,7 +56,7 @@ irqreturn_t r128_driver_irq_handler(DRM_IRQ_ARGS) /* VBLANK interrupt */ if (status & R128_CRTC_VBLANK_INT) { R128_WRITE(R128_GEN_INT_STATUS, R128_CRTC_VBLANK_INT_AK); @@ -31713,10 +33150,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128= /r128_irq.c linux-2.6.32.49/drive drm_handle_vblank(dev, 0); return IRQ_HANDLED; } -diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128/r128_state.c linux-2.6.3= 2.49/drivers/gpu/drm/r128/r128_state.c ---- linux-2.6.32.49/drivers/gpu/drm/r128/r128_state.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/r128/r128_state.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -323,10 +323,10 @@ static void r128_clear_box(drm_r128_priv +diff --git a/drivers/gpu/drm/r128/r128_state.c b/drivers/gpu/drm/r128/r1= 28_state.c +index af2665c..51922d2 100644 +--- a/drivers/gpu/drm/r128/r128_state.c ++++ b/drivers/gpu/drm/r128/r128_state.c +@@ -323,10 +323,10 @@ static void r128_clear_box(drm_r128_private_t * de= v_priv, =20 static void r128_cce_performance_boxes(drm_r128_private_t * dev_priv) { @@ -31729,10 +33167,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/r128= /r128_state.c linux-2.6.32.49/dri } } =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/atom.c linux-2.6.32.49= /drivers/gpu/drm/radeon/atom.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/atom.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/atom.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -1115,6 +1115,8 @@ struct atom_context *atom_parse(struct c +diff --git a/drivers/gpu/drm/radeon/atom.c b/drivers/gpu/drm/radeon/atom= .c +index dd72b91..8644b3c 100644 +--- a/drivers/gpu/drm/radeon/atom.c ++++ b/drivers/gpu/drm/radeon/atom.c +@@ -1115,6 +1115,8 @@ struct atom_context *atom_parse(struct card_info *= card, void *bios) char name[512]; int i; =20 @@ -31741,10 +33180,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/atom.c linux-2.6.32.49/drivers ctx->card =3D card; ctx->bios =3D bios; =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/mkregtable.c linux-2.6= .32.49/drivers/gpu/drm/radeon/mkregtable.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/mkregtable.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/mkregtable.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -637,14 +637,14 @@ static int parser_auth(struct table *t,=20 +diff --git a/drivers/gpu/drm/radeon/mkregtable.c b/drivers/gpu/drm/radeo= n/mkregtable.c +index 0d79577..efaa7a5 100644 +--- a/drivers/gpu/drm/radeon/mkregtable.c ++++ b/drivers/gpu/drm/radeon/mkregtable.c +@@ -637,14 +637,14 @@ static int parser_auth(struct table *t, const char= *filename) regex_t mask_rex; regmatch_t match[4]; char buf[1024]; @@ -31761,10 +33201,33 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/mkregtable.c linux-2.6.32.49/d =20 if (regcomp (&mask_rex, "(0x[0-9a-fA-F]*) *([_a-zA-Z0-9]*)", REG_EXTENDED)) { -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_atombios.c linu= x-2.6.32.49/drivers/gpu/drm/radeon/radeon_atombios.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_atombios.c 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_atombios.c 2011-11-15 = 19:59:43.000000000 -0500 -@@ -275,6 +275,8 @@ bool radeon_get_atom_connector_info_from +diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/ra= deon.h +index 6735213..38c2c67 100644 +--- a/drivers/gpu/drm/radeon/radeon.h ++++ b/drivers/gpu/drm/radeon/radeon.h +@@ -149,7 +149,7 @@ int radeon_pm_init(struct radeon_device *rdev); + */ + struct radeon_fence_driver { + uint32_t scratch_reg; +- atomic_t seq; ++ atomic_unchecked_t seq; + uint32_t last_seq; + unsigned long count_timeout; + wait_queue_head_t queue; +@@ -640,7 +640,7 @@ struct radeon_asic { + uint32_t offset, uint32_t obj_size); + int (*clear_surface_reg)(struct radeon_device *rdev, int reg); + void (*bandwidth_update)(struct radeon_device *rdev); +-}; ++} __no_const; +=20 + /* + * Asic structures +diff --git a/drivers/gpu/drm/radeon/radeon_atombios.c b/drivers/gpu/drm/= radeon/radeon_atombios.c +index 4e928b9..d8b6008 100644 +--- a/drivers/gpu/drm/radeon/radeon_atombios.c ++++ b/drivers/gpu/drm/radeon/radeon_atombios.c +@@ -275,6 +275,8 @@ bool radeon_get_atom_connector_info_from_object_tabl= e(struct drm_device *dev) bool linkb; struct radeon_i2c_bus_rec ddc_bus; =20 @@ -31773,7 +33236,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon= /radeon_atombios.c linux-2.6.32 atom_parse_data_header(ctx, index, &size, &frev, &crev, &data_offset); =20 if (data_offset =3D=3D 0) -@@ -520,13 +522,13 @@ static uint16_t atombios_get_connector_o +@@ -520,13 +522,13 @@ static uint16_t atombios_get_connector_object_id(s= truct drm_device *dev, } } =20 @@ -31789,7 +33252,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon= /radeon_atombios.c linux-2.6.32 =20 bool radeon_get_atom_connector_info_from_supported_devices_table(struct drm_device -@@ -542,7 +544,6 @@ bool radeon_get_atom_connector_info_from +@@ -542,7 +544,6 @@ bool radeon_get_atom_connector_info_from_supported_d= evices_table(struct uint8_t dac; union atom_supported_devices *supported_devices; int i, j; @@ -31797,10 +33260,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/radeon_atombios.c linux-2.6.32 =20 atom_parse_data_header(ctx, index, &size, &frev, &crev, &data_offset); =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_display.c linux= -2.6.32.49/drivers/gpu/drm/radeon/radeon_display.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_display.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_display.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -482,7 +482,7 @@ void radeon_compute_pll(struct radeon_pl +diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/r= adeon/radeon_display.c +index 083a181..ccccae0 100644 +--- a/drivers/gpu/drm/radeon/radeon_display.c ++++ b/drivers/gpu/drm/radeon/radeon_display.c +@@ -482,7 +482,7 @@ void radeon_compute_pll(struct radeon_pll *pll, =20 if (flags & RADEON_PLL_PREFER_CLOSEST_LOWER) { error =3D freq - current_freq; @@ -31809,9 +33273,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeo= n/radeon_display.c linux-2.6.32. } else error =3D abs(current_freq - freq); vco_diff =3D abs(vco - best_vco); -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_drv.h linux-2.6= .32.49/drivers/gpu/drm/radeon/radeon_drv.h ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_drv.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_drv.h 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/drivers/gpu/drm/radeon/radeon_drv.h b/drivers/gpu/drm/radeo= n/radeon_drv.h +index 76e4070..193fa7f 100644 +--- a/drivers/gpu/drm/radeon/radeon_drv.h ++++ b/drivers/gpu/drm/radeon/radeon_drv.h @@ -253,7 +253,7 @@ typedef struct drm_radeon_private { =20 /* SW interrupt */ @@ -31821,10 +33286,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/radeon_drv.h linux-2.6.32.49/d int vblank_crtc; uint32_t irq_enable_reg; uint32_t r500_disp_irq_reg; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_fence.c linux-2= .6.32.49/drivers/gpu/drm/radeon/radeon_fence.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_fence.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_fence.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -47,7 +47,7 @@ int radeon_fence_emit(struct radeon_devi +diff --git a/drivers/gpu/drm/radeon/radeon_fence.c b/drivers/gpu/drm/rad= eon/radeon_fence.c +index 3beb26d..6ce9c4a 100644 +--- a/drivers/gpu/drm/radeon/radeon_fence.c ++++ b/drivers/gpu/drm/radeon/radeon_fence.c +@@ -47,7 +47,7 @@ int radeon_fence_emit(struct radeon_device *rdev, stru= ct radeon_fence *fence) write_unlock_irqrestore(&rdev->fence_drv.lock, irq_flags); return 0; } @@ -31833,7 +33299,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon= /radeon_fence.c linux-2.6.32.49 if (!rdev->cp.ready) { /* FIXME: cp is not running assume everythings is done right * away -@@ -364,7 +364,7 @@ int radeon_fence_driver_init(struct rade +@@ -364,7 +364,7 @@ int radeon_fence_driver_init(struct radeon_device *r= dev) return r; } WREG32(rdev->fence_drv.scratch_reg, 0); @@ -31842,31 +33308,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/radeon_fence.c linux-2.6.32.49 INIT_LIST_HEAD(&rdev->fence_drv.created); INIT_LIST_HEAD(&rdev->fence_drv.emited); INIT_LIST_HEAD(&rdev->fence_drv.signaled); -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon.h linux-2.6.32.= 49/drivers/gpu/drm/radeon/radeon.h ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon.h 2011-11-15 19:59:43.= 000000000 -0500 -@@ -149,7 +149,7 @@ int radeon_pm_init(struct radeon_device=20 - */ - struct radeon_fence_driver { - uint32_t scratch_reg; -- atomic_t seq; -+ atomic_unchecked_t seq; - uint32_t last_seq; - unsigned long count_timeout; - wait_queue_head_t queue; -@@ -640,7 +640,7 @@ struct radeon_asic { - uint32_t offset, uint32_t obj_size); - int (*clear_surface_reg)(struct radeon_device *rdev, int reg); - void (*bandwidth_update)(struct radeon_device *rdev); --}; -+} __no_const; -=20 - /* - * Asic structures -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_ioc32.c linux-2= .6.32.49/drivers/gpu/drm/radeon/radeon_ioc32.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_ioc32.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_ioc32.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -368,7 +368,7 @@ static int compat_radeon_cp_setparam(str +diff --git a/drivers/gpu/drm/radeon/radeon_ioc32.c b/drivers/gpu/drm/rad= eon/radeon_ioc32.c +index a1bf11d..4a123c0 100644 +--- a/drivers/gpu/drm/radeon/radeon_ioc32.c ++++ b/drivers/gpu/drm/radeon/radeon_ioc32.c +@@ -368,7 +368,7 @@ static int compat_radeon_cp_setparam(struct file *fi= le, unsigned int cmd, request =3D compat_alloc_user_space(sizeof(*request)); if (!access_ok(VERIFY_WRITE, request, sizeof(*request)) || __put_user(req32.param, &request->param) @@ -31875,10 +33321,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/radeon_ioc32.c linux-2.6.32.49 &request->value)) return -EFAULT; =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_irq.c linux-2.6= .32.49/drivers/gpu/drm/radeon/radeon_irq.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_irq.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_irq.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -225,8 +225,8 @@ static int radeon_emit_irq(struct drm_de +diff --git a/drivers/gpu/drm/radeon/radeon_irq.c b/drivers/gpu/drm/radeo= n/radeon_irq.c +index b79ecc4..8dab92d 100644 +--- a/drivers/gpu/drm/radeon/radeon_irq.c ++++ b/drivers/gpu/drm/radeon/radeon_irq.c +@@ -225,8 +225,8 @@ static int radeon_emit_irq(struct drm_device * dev) unsigned int ret; RING_LOCALS; =20 @@ -31889,7 +33336,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon= /radeon_irq.c linux-2.6.32.49/d =20 BEGIN_RING(4); OUT_RING_REG(RADEON_LAST_SWI_REG, ret); -@@ -352,7 +352,7 @@ int radeon_driver_irq_postinstall(struct +@@ -352,7 +352,7 @@ int radeon_driver_irq_postinstall(struct drm_device = *dev) drm_radeon_private_t *dev_priv =3D (drm_radeon_private_t *) dev->dev_private; =20 @@ -31898,10 +33345,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/radeon_irq.c linux-2.6.32.49/d DRM_INIT_WAITQUEUE(&dev_priv->swi_queue); =20 dev->max_vblank_count =3D 0x001fffff; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_state.c linux-2= .6.32.49/drivers/gpu/drm/radeon/radeon_state.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_state.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_state.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -3021,7 +3021,7 @@ static int radeon_cp_getparam(struct drm +diff --git a/drivers/gpu/drm/radeon/radeon_state.c b/drivers/gpu/drm/rad= eon/radeon_state.c +index 4747910..48ca4b3 100644 +--- a/drivers/gpu/drm/radeon/radeon_state.c ++++ b/drivers/gpu/drm/radeon/radeon_state.c +@@ -3021,7 +3021,7 @@ static int radeon_cp_getparam(struct drm_device *d= ev, void *data, struct drm_fil { drm_radeon_private_t *dev_priv =3D dev->dev_private; drm_radeon_getparam_t *param =3D data; @@ -31910,10 +33358,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/radeon_state.c linux-2.6.32.49 =20 DRM_DEBUG("pid=3D%d\n", DRM_CURRENTPID); =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_ttm.c linux-2.6= .32.49/drivers/gpu/drm/radeon/radeon_ttm.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_ttm.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/radeon_ttm.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -535,27 +535,10 @@ void radeon_ttm_fini(struct radeon_devic +diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeo= n/radeon_ttm.c +index 1381e06..0e53b17 100644 +--- a/drivers/gpu/drm/radeon/radeon_ttm.c ++++ b/drivers/gpu/drm/radeon/radeon_ttm.c +@@ -535,27 +535,10 @@ void radeon_ttm_fini(struct radeon_device *rdev) DRM_INFO("radeon: ttm finalized\n"); } =20 @@ -31941,7 +33390,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon= /radeon_ttm.c linux-2.6.32.49/d =20 if (unlikely(vma->vm_pgoff < DRM_FILE_PAGE_OFFSET)) { return drm_mmap(filp, vma); -@@ -563,20 +546,9 @@ int radeon_mmap(struct file *filp, struc +@@ -563,20 +546,9 @@ int radeon_mmap(struct file *filp, struct vm_area_s= truct *vma) =20 file_priv =3D (struct drm_file *)filp->private_data; rdev =3D file_priv->minor->dev->dev_private; @@ -31964,10 +33413,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/radeon_ttm.c linux-2.6.32.49/d } =20 =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/radeon/rs690.c linux-2.6.32.4= 9/drivers/gpu/drm/radeon/rs690.c ---- linux-2.6.32.49/drivers/gpu/drm/radeon/rs690.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/radeon/rs690.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -302,9 +302,11 @@ void rs690_crtc_bandwidth_compute(struct +diff --git a/drivers/gpu/drm/radeon/rs690.c b/drivers/gpu/drm/radeon/rs6= 90.c +index b12ff76..0bd0c6e 100644 +--- a/drivers/gpu/drm/radeon/rs690.c ++++ b/drivers/gpu/drm/radeon/rs690.c +@@ -302,9 +302,11 @@ void rs690_crtc_bandwidth_compute(struct radeon_dev= ice *rdev, if (rdev->pm.max_bandwidth.full > rdev->pm.sideport_bandwidth.full && rdev->pm.sideport_bandwidth.full) rdev->pm.max_bandwidth =3D rdev->pm.sideport_bandwidth; @@ -31980,10 +33430,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/rade= on/rs690.c linux-2.6.32.49/driver } else { if (rdev->pm.max_bandwidth.full > rdev->pm.k8_bandwidth.full && rdev->pm.k8_bandwidth.full) -diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_bo.c linux-2.6.32.49/= drivers/gpu/drm/ttm/ttm_bo.c ---- linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_bo.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_bo.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -67,7 +67,7 @@ static struct attribute *ttm_bo_global_a +diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c +index 0ed436e..e6e7ce3 100644 +--- a/drivers/gpu/drm/ttm/ttm_bo.c ++++ b/drivers/gpu/drm/ttm/ttm_bo.c +@@ -67,7 +67,7 @@ static struct attribute *ttm_bo_global_attrs[] =3D { NULL }; =20 @@ -31992,10 +33443,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/= ttm_bo.c linux-2.6.32.49/drivers/ .show =3D &ttm_bo_global_show }; =20 -diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_bo_vm.c linux-2.6.32.= 49/drivers/gpu/drm/ttm/ttm_bo_vm.c ---- linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_bo_vm.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_bo_vm.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -73,7 +73,7 @@ static int ttm_bo_vm_fault(struct vm_are +diff --git a/drivers/gpu/drm/ttm/ttm_bo_vm.c b/drivers/gpu/drm/ttm/ttm_b= o_vm.c +index 1c040d0..f9e4af8 100644 +--- a/drivers/gpu/drm/ttm/ttm_bo_vm.c ++++ b/drivers/gpu/drm/ttm/ttm_bo_vm.c +@@ -73,7 +73,7 @@ static int ttm_bo_vm_fault(struct vm_area_struct *vma,= struct vm_fault *vmf) { struct ttm_buffer_object *bo =3D (struct ttm_buffer_object *) vma->vm_private_data; @@ -32004,7 +33456,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/tt= m_bo_vm.c linux-2.6.32.49/drive unsigned long bus_base; unsigned long bus_offset; unsigned long bus_size; -@@ -88,6 +88,10 @@ static int ttm_bo_vm_fault(struct vm_are +@@ -88,6 +88,10 @@ static int ttm_bo_vm_fault(struct vm_area_struct *vma= , struct vm_fault *vmf) unsigned long address =3D (unsigned long)vmf->virtual_address; int retval =3D VM_FAULT_NOPAGE; =20 @@ -32015,9 +33467,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/t= tm_bo_vm.c linux-2.6.32.49/drive /* * Work around locking order reversal in fault / nopfn * between mmap_sem and bo_reserve: Perform a trylock operation -diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_global.c linux-2.6.32= .49/drivers/gpu/drm/ttm/ttm_global.c ---- linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_global.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_global.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/gpu/drm/ttm/ttm_global.c b/drivers/gpu/drm/ttm/ttm_= global.c +index b170071..28ae90e 100644 +--- a/drivers/gpu/drm/ttm/ttm_global.c ++++ b/drivers/gpu/drm/ttm/ttm_global.c @@ -36,7 +36,7 @@ struct ttm_global_item { struct mutex mutex; @@ -32045,7 +33498,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/tt= m_global.c linux-2.6.32.49/driv } } =20 -@@ -70,7 +70,7 @@ int ttm_global_item_ref(struct ttm_globa +@@ -70,7 +70,7 @@ int ttm_global_item_ref(struct ttm_global_reference *r= ef) void *object; =20 mutex_lock(&item->mutex); @@ -32054,7 +33507,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/tt= m_global.c linux-2.6.32.49/driv item->object =3D kzalloc(ref->size, GFP_KERNEL); if (unlikely(item->object =3D=3D NULL)) { ret =3D -ENOMEM; -@@ -83,7 +83,7 @@ int ttm_global_item_ref(struct ttm_globa +@@ -83,7 +83,7 @@ int ttm_global_item_ref(struct ttm_global_reference *r= ef) goto out_err; =20 } @@ -32063,7 +33516,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/tt= m_global.c linux-2.6.32.49/driv ref->object =3D item->object; object =3D item->object; mutex_unlock(&item->mutex); -@@ -100,9 +100,9 @@ void ttm_global_item_unref(struct ttm_gl +@@ -100,9 +100,9 @@ void ttm_global_item_unref(struct ttm_global_referen= ce *ref) struct ttm_global_item *item =3D &glob[ref->global_type]; =20 mutex_lock(&item->mutex); @@ -32075,10 +33528,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/= ttm_global.c linux-2.6.32.49/driv ref->release(ref); item->object =3D NULL; } -diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_memory.c linux-2.6.32= .49/drivers/gpu/drm/ttm/ttm_memory.c ---- linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_memory.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/ttm/ttm_memory.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -152,7 +152,7 @@ static struct attribute *ttm_mem_zone_at +diff --git a/drivers/gpu/drm/ttm/ttm_memory.c b/drivers/gpu/drm/ttm/ttm_= memory.c +index 072c281..d8ef483 100644 +--- a/drivers/gpu/drm/ttm/ttm_memory.c ++++ b/drivers/gpu/drm/ttm/ttm_memory.c +@@ -152,7 +152,7 @@ static struct attribute *ttm_mem_zone_attrs[] =3D { NULL }; =20 @@ -32087,9 +33541,10 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/ttm/t= tm_memory.c linux-2.6.32.49/driv .show =3D &ttm_mem_zone_show, .store =3D &ttm_mem_zone_store }; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/via_drv.h linux-2.6.32.49= /drivers/gpu/drm/via/via_drv.h ---- linux-2.6.32.49/drivers/gpu/drm/via/via_drv.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/via/via_drv.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/drivers/gpu/drm/via/via_drv.h b/drivers/gpu/drm/via/via_drv= .h +index cafcb84..b8e66cc 100644 +--- a/drivers/gpu/drm/via/via_drv.h ++++ b/drivers/gpu/drm/via/via_drv.h @@ -51,7 +51,7 @@ typedef struct drm_via_ring_buffer { typedef uint32_t maskarray_t[5]; =20 @@ -32108,10 +33563,11 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/= via_drv.h linux-2.6.32.49/drivers drm_via_state_t hc_state; char pci_buf[VIA_PCI_BUF_SIZE]; const uint32_t *fire_offsets[VIA_FIRE_BUF_SIZE]; -diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/via_irq.c linux-2.6.32.49= /drivers/gpu/drm/via/via_irq.c ---- linux-2.6.32.49/drivers/gpu/drm/via/via_irq.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/gpu/drm/via/via_irq.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -102,7 +102,7 @@ u32 via_get_vblank_counter(struct drm_de +diff --git a/drivers/gpu/drm/via/via_irq.c b/drivers/gpu/drm/via/via_irq= .c +index 5935b88..127a8a6 100644 +--- a/drivers/gpu/drm/via/via_irq.c ++++ b/drivers/gpu/drm/via/via_irq.c +@@ -102,7 +102,7 @@ u32 via_get_vblank_counter(struct drm_device *dev, i= nt crtc) if (crtc !=3D 0) return 0; =20 @@ -32120,7 +33576,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/vi= a_irq.c linux-2.6.32.49/drivers } =20 irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) -@@ -117,8 +117,8 @@ irqreturn_t via_driver_irq_handler(DRM_I +@@ -117,8 +117,8 @@ irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) =20 status =3D VIA_READ(VIA_REG_INTERRUPT); if (status & VIA_IRQ_VBLANK_PENDING) { @@ -32131,7 +33587,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/vi= a_irq.c linux-2.6.32.49/drivers do_gettimeofday(&cur_vblank); if (dev_priv->last_vblank_valid) { dev_priv->usec_per_vblank =3D -@@ -128,7 +128,7 @@ irqreturn_t via_driver_irq_handler(DRM_I +@@ -128,7 +128,7 @@ irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) dev_priv->last_vblank =3D cur_vblank; dev_priv->last_vblank_valid =3D 1; } @@ -32140,7 +33596,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/vi= a_irq.c linux-2.6.32.49/drivers DRM_DEBUG("US per vblank is: %u\n", dev_priv->usec_per_vblank); } -@@ -138,7 +138,7 @@ irqreturn_t via_driver_irq_handler(DRM_I +@@ -138,7 +138,7 @@ irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) =20 for (i =3D 0; i < dev_priv->num_irqs; ++i) { if (status & cur_irq->pending_mask) { @@ -32149,7 +33605,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/vi= a_irq.c linux-2.6.32.49/drivers DRM_WAKEUP(&cur_irq->irq_queue); handled =3D 1; if (dev_priv->irq_map[drm_via_irq_dma0_td] =3D=3D i) { -@@ -244,11 +244,11 @@ via_driver_irq_wait(struct drm_device *=20 +@@ -244,11 +244,11 @@ via_driver_irq_wait(struct drm_device * dev, unsig= ned int irq, int force_sequenc DRM_WAIT_ON(ret, cur_irq->irq_queue, 3 * DRM_HZ, ((VIA_READ(masks[irq][2]) & masks[irq][3]) =3D=3D masks[irq][4])); @@ -32163,7 +33619,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/vi= a_irq.c linux-2.6.32.49/drivers *sequence) <=3D (1 << 23))); } *sequence =3D cur_irq_sequence; -@@ -286,7 +286,7 @@ void via_driver_irq_preinstall(struct dr +@@ -286,7 +286,7 @@ void via_driver_irq_preinstall(struct drm_device * d= ev) } =20 for (i =3D 0; i < dev_priv->num_irqs; ++i) { @@ -32172,7 +33628,7 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/vi= a_irq.c linux-2.6.32.49/drivers cur_irq->enable_mask =3D dev_priv->irq_masks[i][0]; cur_irq->pending_mask =3D dev_priv->irq_masks[i][1]; DRM_INIT_WAITQUEUE(&cur_irq->irq_queue); -@@ -368,7 +368,7 @@ int via_wait_irq(struct drm_device *dev, +@@ -368,7 +368,7 @@ int via_wait_irq(struct drm_device *dev, void *data,= struct drm_file *file_priv) switch (irqwait->request.type & ~VIA_IRQ_FLAGS_MASK) { case VIA_IRQ_RELATIVE: irqwait->request.sequence +=3D @@ -32181,10 +33637,42 @@ diff -urNp linux-2.6.32.49/drivers/gpu/drm/via/= via_irq.c linux-2.6.32.49/drivers irqwait->request.type &=3D ~_DRM_VBLANK_RELATIVE; case VIA_IRQ_ABSOLUTE: break; -diff -urNp linux-2.6.32.49/drivers/hid/hid-core.c linux-2.6.32.49/driver= s/hid/hid-core.c ---- linux-2.6.32.49/drivers/hid/hid-core.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/hid/hid-core.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1752,7 +1752,7 @@ static bool hid_ignore(struct hid_device +diff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c +index aa8688d..6a0140c 100644 +--- a/drivers/gpu/vga/vgaarb.c ++++ b/drivers/gpu/vga/vgaarb.c +@@ -894,14 +894,20 @@ static ssize_t vga_arb_write(struct file *file, co= nst char __user * buf, + uc =3D &priv->cards[i]; + } +=20 +- if (!uc) +- return -EINVAL; ++ if (!uc) { ++ ret_val =3D -EINVAL; ++ goto done; ++ } +=20 +- if (io_state & VGA_RSRC_LEGACY_IO && uc->io_cnt =3D=3D 0) +- return -EINVAL; ++ if (io_state & VGA_RSRC_LEGACY_IO && uc->io_cnt =3D=3D 0) { ++ ret_val =3D -EINVAL; ++ goto done; ++ } +=20 +- if (io_state & VGA_RSRC_LEGACY_MEM && uc->mem_cnt =3D=3D 0) +- return -EINVAL; ++ if (io_state & VGA_RSRC_LEGACY_MEM && uc->mem_cnt =3D=3D 0) { ++ ret_val =3D -EINVAL; ++ goto done; ++ } +=20 + vga_put(pdev, io_state); +=20 +diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c +index f3f1415..e561d90 100644 +--- a/drivers/hid/hid-core.c ++++ b/drivers/hid/hid-core.c +@@ -1752,7 +1752,7 @@ static bool hid_ignore(struct hid_device *hdev) =20 int hid_add_device(struct hid_device *hdev) { @@ -32193,7 +33681,7 @@ diff -urNp linux-2.6.32.49/drivers/hid/hid-core.c= linux-2.6.32.49/drivers/hid/hi int ret; =20 if (WARN_ON(hdev->status & HID_STAT_ADDED)) -@@ -1766,7 +1766,7 @@ int hid_add_device(struct hid_device *hd +@@ -1766,7 +1766,7 @@ int hid_add_device(struct hid_device *hdev) /* XXX hack, any other cleaner solution after the driver core * is converted to allow more than 20 bytes as the device name? */ dev_set_name(&hdev->dev, "%04X:%04X:%04X.%04X", hdev->bus, @@ -32202,10 +33690,11 @@ diff -urNp linux-2.6.32.49/drivers/hid/hid-core= .c linux-2.6.32.49/drivers/hid/hi =20 ret =3D device_add(&hdev->dev); if (!ret) -diff -urNp linux-2.6.32.49/drivers/hid/usbhid/hiddev.c linux-2.6.32.49/d= rivers/hid/usbhid/hiddev.c ---- linux-2.6.32.49/drivers/hid/usbhid/hiddev.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/hid/usbhid/hiddev.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -617,7 +617,7 @@ static long hiddev_ioctl(struct file *fi +diff --git a/drivers/hid/usbhid/hiddev.c b/drivers/hid/usbhid/hiddev.c +index 8b6ee24..70f657d 100644 +--- a/drivers/hid/usbhid/hiddev.c ++++ b/drivers/hid/usbhid/hiddev.c +@@ -617,7 +617,7 @@ static long hiddev_ioctl(struct file *file, unsigned= int cmd, unsigned long arg) return put_user(HID_VERSION, (int __user *)arg); =20 case HIDIOCAPPLICATION: @@ -32214,10 +33703,11 @@ diff -urNp linux-2.6.32.49/drivers/hid/usbhid/h= iddev.c linux-2.6.32.49/drivers/h return -EINVAL; =20 for (i =3D 0; i < hid->maxcollection; i++) -diff -urNp linux-2.6.32.49/drivers/hwmon/lis3lv02d.c linux-2.6.32.49/dri= vers/hwmon/lis3lv02d.c ---- linux-2.6.32.49/drivers/hwmon/lis3lv02d.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/hwmon/lis3lv02d.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -146,7 +146,7 @@ static irqreturn_t lis302dl_interrupt(in +diff --git a/drivers/hwmon/lis3lv02d.c b/drivers/hwmon/lis3lv02d.c +index 5d5ed69..f40533e 100644 +--- a/drivers/hwmon/lis3lv02d.c ++++ b/drivers/hwmon/lis3lv02d.c +@@ -146,7 +146,7 @@ static irqreturn_t lis302dl_interrupt(int irq, void = *dummy) * the lid is closed. This leads to interrupts as soon as a little mov= e * is done. */ @@ -32226,7 +33716,7 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/lis3lv02= d.c linux-2.6.32.49/drivers/hwm =20 wake_up_interruptible(&lis3_dev.misc_wait); kill_fasync(&lis3_dev.async_queue, SIGIO, POLL_IN); -@@ -160,7 +160,7 @@ static int lis3lv02d_misc_open(struct in +@@ -160,7 +160,7 @@ static int lis3lv02d_misc_open(struct inode *inode, = struct file *file) if (test_and_set_bit(0, &lis3_dev.misc_opened)) return -EBUSY; /* already open */ =20 @@ -32235,7 +33725,7 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/lis3lv02= d.c linux-2.6.32.49/drivers/hwm =20 /* * The sensor can generate interrupts for free-fall and direction -@@ -206,7 +206,7 @@ static ssize_t lis3lv02d_misc_read(struc +@@ -206,7 +206,7 @@ static ssize_t lis3lv02d_misc_read(struct file *file= , char __user *buf, add_wait_queue(&lis3_dev.misc_wait, &wait); while (true) { set_current_state(TASK_INTERRUPTIBLE); @@ -32253,9 +33743,10 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/lis3lv0= 2d.c linux-2.6.32.49/drivers/hwm return POLLIN | POLLRDNORM; return 0; } -diff -urNp linux-2.6.32.49/drivers/hwmon/lis3lv02d.h linux-2.6.32.49/dri= vers/hwmon/lis3lv02d.h ---- linux-2.6.32.49/drivers/hwmon/lis3lv02d.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/hwmon/lis3lv02d.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/hwmon/lis3lv02d.h b/drivers/hwmon/lis3lv02d.h +index 7cdd76f..fe0efdf 100644 +--- a/drivers/hwmon/lis3lv02d.h ++++ b/drivers/hwmon/lis3lv02d.h @@ -201,7 +201,7 @@ struct lis3lv02d { =20 struct input_polled_dev *idev; /* input device */ @@ -32265,9 +33756,10 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/lis3lv0= 2d.h linux-2.6.32.49/drivers/hwm int xcalib; /* calibrated null value for x */ int ycalib; /* calibrated null value for y */ int zcalib; /* calibrated null value for z */ -diff -urNp linux-2.6.32.49/drivers/hwmon/sht15.c linux-2.6.32.49/drivers= /hwmon/sht15.c ---- linux-2.6.32.49/drivers/hwmon/sht15.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/hwmon/sht15.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/hwmon/sht15.c b/drivers/hwmon/sht15.c +index 2040507..706ec1e 100644 +--- a/drivers/hwmon/sht15.c ++++ b/drivers/hwmon/sht15.c @@ -112,7 +112,7 @@ struct sht15_data { int supply_uV; int supply_uV_valid; @@ -32277,7 +33769,7 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/sht15.c = linux-2.6.32.49/drivers/hwmon/s }; =20 /** -@@ -245,13 +245,13 @@ static inline int sht15_update_single_va +@@ -245,13 +245,13 @@ static inline int sht15_update_single_val(struct s= ht15_data *data, return ret; =20 gpio_direction_input(data->pdata->gpio_data); @@ -32293,7 +33785,7 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/sht15.c = linux-2.6.32.49/drivers/hwmon/s schedule_work(&data->read_work); } ret =3D wait_event_timeout(data->wait_queue, -@@ -398,7 +398,7 @@ static irqreturn_t sht15_interrupt_fired +@@ -398,7 +398,7 @@ static irqreturn_t sht15_interrupt_fired(int irq, vo= id *d) struct sht15_data *data =3D d; /* First disable the interrupt */ disable_irq_nosync(irq); @@ -32302,7 +33794,7 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/sht15.c = linux-2.6.32.49/drivers/hwmon/s /* Then schedule a reading work struct */ if (data->flag !=3D SHT15_READING_NOTHING) schedule_work(&data->read_work); -@@ -449,11 +449,11 @@ static void sht15_bh_read_data(struct wo +@@ -449,11 +449,11 @@ static void sht15_bh_read_data(struct work_struct = *work_s) here as could have gone low in meantime so verify it hasn't! */ @@ -32316,10 +33808,11 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/sht15.= c linux-2.6.32.49/drivers/hwmon/s return; } /* Read the data back from the device */ -diff -urNp linux-2.6.32.49/drivers/hwmon/w83791d.c linux-2.6.32.49/drive= rs/hwmon/w83791d.c ---- linux-2.6.32.49/drivers/hwmon/w83791d.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/hwmon/w83791d.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -330,8 +330,8 @@ static int w83791d_detect(struct i2c_cli +diff --git a/drivers/hwmon/w83791d.c b/drivers/hwmon/w83791d.c +index 97851c5..cb40626 100644 +--- a/drivers/hwmon/w83791d.c ++++ b/drivers/hwmon/w83791d.c +@@ -330,8 +330,8 @@ static int w83791d_detect(struct i2c_client *client,= int kind, struct i2c_board_info *info); static int w83791d_remove(struct i2c_client *client); =20 @@ -32330,9 +33823,10 @@ diff -urNp linux-2.6.32.49/drivers/hwmon/w83791d= .c linux-2.6.32.49/drivers/hwmon static struct w83791d_data *w83791d_update_device(struct device *dev); =20 #ifdef DEBUG -diff -urNp linux-2.6.32.49/drivers/i2c/busses/i2c-amd756-s4882.c linux-2= .6.32.49/drivers/i2c/busses/i2c-amd756-s4882.c ---- linux-2.6.32.49/drivers/i2c/busses/i2c-amd756-s4882.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/i2c/busses/i2c-amd756-s4882.c 2011-11-15 19:= 59:43.000000000 -0500 +diff --git a/drivers/i2c/busses/i2c-amd756-s4882.c b/drivers/i2c/busses/= i2c-amd756-s4882.c +index 378fcb5..5e91fa8 100644 +--- a/drivers/i2c/busses/i2c-amd756-s4882.c ++++ b/drivers/i2c/busses/i2c-amd756-s4882.c @@ -43,7 +43,7 @@ extern struct i2c_adapter amd756_smbus; =20 @@ -32342,9 +33836,10 @@ diff -urNp linux-2.6.32.49/drivers/i2c/busses/i2= c-amd756-s4882.c linux-2.6.32.49 =20 /* Wrapper access functions for multiplexed SMBus */ static DEFINE_MUTEX(amd756_lock); -diff -urNp linux-2.6.32.49/drivers/i2c/busses/i2c-nforce2-s4985.c linux-= 2.6.32.49/drivers/i2c/busses/i2c-nforce2-s4985.c ---- linux-2.6.32.49/drivers/i2c/busses/i2c-nforce2-s4985.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/i2c/busses/i2c-nforce2-s4985.c 2011-11-15 19= :59:43.000000000 -0500 +diff --git a/drivers/i2c/busses/i2c-nforce2-s4985.c b/drivers/i2c/busses= /i2c-nforce2-s4985.c +index 29015eb..af2d8e9 100644 +--- a/drivers/i2c/busses/i2c-nforce2-s4985.c ++++ b/drivers/i2c/busses/i2c-nforce2-s4985.c @@ -41,7 +41,7 @@ extern struct i2c_adapter *nforce2_smbus; =20 @@ -32354,10 +33849,11 @@ diff -urNp linux-2.6.32.49/drivers/i2c/busses/i= 2c-nforce2-s4985.c linux-2.6.32.4 =20 /* Wrapper access functions for multiplexed SMBus */ static DEFINE_MUTEX(nforce2_lock); -diff -urNp linux-2.6.32.49/drivers/ide/aec62xx.c linux-2.6.32.49/drivers= /ide/aec62xx.c ---- linux-2.6.32.49/drivers/ide/aec62xx.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/aec62xx.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -180,7 +180,7 @@ static const struct ide_port_ops atp86x_ +diff --git a/drivers/ide/aec62xx.c b/drivers/ide/aec62xx.c +index 878f8ec..12376fc 100644 +--- a/drivers/ide/aec62xx.c ++++ b/drivers/ide/aec62xx.c +@@ -180,7 +180,7 @@ static const struct ide_port_ops atp86x_port_ops =3D= { .cable_detect =3D atp86x_cable_detect, }; =20 @@ -32366,10 +33862,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/aec62xx.= c linux-2.6.32.49/drivers/ide/aec { /* 0: AEC6210 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_aec62xx, -diff -urNp linux-2.6.32.49/drivers/ide/alim15x3.c linux-2.6.32.49/driver= s/ide/alim15x3.c ---- linux-2.6.32.49/drivers/ide/alim15x3.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ide/alim15x3.c 2011-11-18 18:01:55.000000000= -0500 -@@ -509,7 +509,7 @@ static const struct ide_dma_ops ali_dma_ +diff --git a/drivers/ide/alim15x3.c b/drivers/ide/alim15x3.c +index e59b6de..4b4fc65 100644 +--- a/drivers/ide/alim15x3.c ++++ b/drivers/ide/alim15x3.c +@@ -509,7 +509,7 @@ static const struct ide_dma_ops ali_dma_ops =3D { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -32378,10 +33875,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/alim15x3= .c linux-2.6.32.49/drivers/ide/al .name =3D DRV_NAME, .init_chipset =3D init_chipset_ali15x3, .init_hwif =3D init_hwif_ali15x3, -diff -urNp linux-2.6.32.49/drivers/ide/amd74xx.c linux-2.6.32.49/drivers= /ide/amd74xx.c ---- linux-2.6.32.49/drivers/ide/amd74xx.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/amd74xx.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -221,7 +221,7 @@ static const struct ide_port_ops amd_por +diff --git a/drivers/ide/amd74xx.c b/drivers/ide/amd74xx.c +index 628cd2e..087a414 100644 +--- a/drivers/ide/amd74xx.c ++++ b/drivers/ide/amd74xx.c +@@ -221,7 +221,7 @@ static const struct ide_port_ops amd_port_ops =3D { .udma_mask =3D udma, \ } =20 @@ -32390,10 +33888,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/amd74xx.= c linux-2.6.32.49/drivers/ide/amd /* 0: AMD7401 */ DECLARE_AMD_DEV(0x00, ATA_UDMA2), /* 1: AMD7409 */ DECLARE_AMD_DEV(ATA_SWDMA2, ATA_UDMA4), /* 2: AMD7411/7441 */ DECLARE_AMD_DEV(ATA_SWDMA2, ATA_UDMA5), -diff -urNp linux-2.6.32.49/drivers/ide/atiixp.c linux-2.6.32.49/drivers/= ide/atiixp.c ---- linux-2.6.32.49/drivers/ide/atiixp.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/atiixp.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -137,7 +137,7 @@ static const struct ide_port_ops atiixp_ +diff --git a/drivers/ide/atiixp.c b/drivers/ide/atiixp.c +index 837322b..837fd71 100644 +--- a/drivers/ide/atiixp.c ++++ b/drivers/ide/atiixp.c +@@ -137,7 +137,7 @@ static const struct ide_port_ops atiixp_port_ops =3D= { .cable_detect =3D atiixp_cable_detect, }; =20 @@ -32402,10 +33901,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/atiixp.c= linux-2.6.32.49/drivers/ide/atii { /* 0: IXP200/300/400/700 */ .name =3D DRV_NAME, .enablebits =3D {{0x48,0x01,0x00}, {0x48,0x08,0x00}}, -diff -urNp linux-2.6.32.49/drivers/ide/cmd64x.c linux-2.6.32.49/drivers/= ide/cmd64x.c ---- linux-2.6.32.49/drivers/ide/cmd64x.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/cmd64x.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -372,7 +372,7 @@ static const struct ide_dma_ops cmd646_r +diff --git a/drivers/ide/cmd64x.c b/drivers/ide/cmd64x.c +index ca0c46f..d55318a 100644 +--- a/drivers/ide/cmd64x.c ++++ b/drivers/ide/cmd64x.c +@@ -372,7 +372,7 @@ static const struct ide_dma_ops cmd646_rev1_dma_ops = =3D { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -32414,10 +33914,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/cmd64x.c= linux-2.6.32.49/drivers/ide/cmd6 { /* 0: CMD643 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_cmd64x, -diff -urNp linux-2.6.32.49/drivers/ide/cs5520.c linux-2.6.32.49/drivers/= ide/cs5520.c ---- linux-2.6.32.49/drivers/ide/cs5520.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/cs5520.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -93,7 +93,7 @@ static const struct ide_port_ops cs5520_ +diff --git a/drivers/ide/cs5520.c b/drivers/ide/cs5520.c +index 09f98ed..cebc5bc 100644 +--- a/drivers/ide/cs5520.c ++++ b/drivers/ide/cs5520.c +@@ -93,7 +93,7 @@ static const struct ide_port_ops cs5520_port_ops =3D { .set_dma_mode =3D cs5520_set_dma_mode, }; =20 @@ -32426,10 +33927,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/cs5520.c= linux-2.6.32.49/drivers/ide/cs55 .name =3D DRV_NAME, .enablebits =3D { { 0x60, 0x01, 0x01 }, { 0x60, 0x02, 0x02 } }, .port_ops =3D &cs5520_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/cs5530.c linux-2.6.32.49/drivers/= ide/cs5530.c ---- linux-2.6.32.49/drivers/ide/cs5530.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/cs5530.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -244,7 +244,7 @@ static const struct ide_port_ops cs5530_ +diff --git a/drivers/ide/cs5530.c b/drivers/ide/cs5530.c +index 40bf05e..7d58ca0 100644 +--- a/drivers/ide/cs5530.c ++++ b/drivers/ide/cs5530.c +@@ -244,7 +244,7 @@ static const struct ide_port_ops cs5530_port_ops =3D= { .udma_filter =3D cs5530_udma_filter, }; =20 @@ -32438,10 +33940,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/cs5530.c= linux-2.6.32.49/drivers/ide/cs55 .name =3D DRV_NAME, .init_chipset =3D init_chipset_cs5530, .init_hwif =3D init_hwif_cs5530, -diff -urNp linux-2.6.32.49/drivers/ide/cs5535.c linux-2.6.32.49/drivers/= ide/cs5535.c ---- linux-2.6.32.49/drivers/ide/cs5535.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/cs5535.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -170,7 +170,7 @@ static const struct ide_port_ops cs5535_ +diff --git a/drivers/ide/cs5535.c b/drivers/ide/cs5535.c +index 983d957..53e6172 100644 +--- a/drivers/ide/cs5535.c ++++ b/drivers/ide/cs5535.c +@@ -170,7 +170,7 @@ static const struct ide_port_ops cs5535_port_ops =3D= { .cable_detect =3D cs5535_cable_detect, }; =20 @@ -32450,10 +33953,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/cs5535.c= linux-2.6.32.49/drivers/ide/cs55 .name =3D DRV_NAME, .port_ops =3D &cs5535_port_ops, .host_flags =3D IDE_HFLAG_SINGLE | IDE_HFLAG_POST_SET_MODE, -diff -urNp linux-2.6.32.49/drivers/ide/cy82c693.c linux-2.6.32.49/driver= s/ide/cy82c693.c ---- linux-2.6.32.49/drivers/ide/cy82c693.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ide/cy82c693.c 2011-11-18 18:01:55.000000000= -0500 -@@ -288,7 +288,7 @@ static const struct ide_port_ops cy82c69 +diff --git a/drivers/ide/cy82c693.c b/drivers/ide/cy82c693.c +index 74fc540..8e933d8 100644 +--- a/drivers/ide/cy82c693.c ++++ b/drivers/ide/cy82c693.c +@@ -288,7 +288,7 @@ static const struct ide_port_ops cy82c693_port_ops =3D= { .set_dma_mode =3D cy82c693_set_dma_mode, }; =20 @@ -32462,10 +33966,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/cy82c693= .c linux-2.6.32.49/drivers/ide/cy .name =3D DRV_NAME, .init_iops =3D init_iops_cy82c693, .port_ops =3D &cy82c693_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c linux-2.6.32.49/drivers/= ide/hpt366.c ---- linux-2.6.32.49/drivers/ide/hpt366.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/hpt366.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -507,7 +507,7 @@ static struct hpt_timings hpt37x_timings +diff --git a/drivers/ide/hpt366.c b/drivers/ide/hpt366.c +index 7ce68ef..e78197d 100644 +--- a/drivers/ide/hpt366.c ++++ b/drivers/ide/hpt366.c +@@ -507,7 +507,7 @@ static struct hpt_timings hpt37x_timings =3D { } }; =20 @@ -32474,7 +33979,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT36x", .chip_type =3D HPT36x, .udma_mask =3D HPT366_ALLOW_ATA66_3 ? (HPT366_ALLOW_ATA66_4 ? ATA_UDMA= 4 : ATA_UDMA3) : ATA_UDMA2, -@@ -515,7 +515,7 @@ static const struct hpt_info hpt36x __de +@@ -515,7 +515,7 @@ static const struct hpt_info hpt36x __devinitdata =3D= { .timings =3D &hpt36x_timings }; =20 @@ -32483,7 +33988,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT370", .chip_type =3D HPT370, .udma_mask =3D HPT370_ALLOW_ATA100_5 ? ATA_UDMA5 : ATA_UDMA4, -@@ -523,7 +523,7 @@ static const struct hpt_info hpt370 __de +@@ -523,7 +523,7 @@ static const struct hpt_info hpt370 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32492,7 +33997,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT370A", .chip_type =3D HPT370A, .udma_mask =3D HPT370_ALLOW_ATA100_5 ? ATA_UDMA5 : ATA_UDMA4, -@@ -531,7 +531,7 @@ static const struct hpt_info hpt370a __d +@@ -531,7 +531,7 @@ static const struct hpt_info hpt370a __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32501,7 +34006,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT374", .chip_type =3D HPT374, .udma_mask =3D ATA_UDMA5, -@@ -539,7 +539,7 @@ static const struct hpt_info hpt374 __de +@@ -539,7 +539,7 @@ static const struct hpt_info hpt374 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32510,7 +34015,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT372", .chip_type =3D HPT372, .udma_mask =3D HPT372_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -547,7 +547,7 @@ static const struct hpt_info hpt372 __de +@@ -547,7 +547,7 @@ static const struct hpt_info hpt372 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32519,7 +34024,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT372A", .chip_type =3D HPT372A, .udma_mask =3D HPT372_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -555,7 +555,7 @@ static const struct hpt_info hpt372a __d +@@ -555,7 +555,7 @@ static const struct hpt_info hpt372a __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32528,7 +34033,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT302", .chip_type =3D HPT302, .udma_mask =3D HPT302_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -563,7 +563,7 @@ static const struct hpt_info hpt302 __de +@@ -563,7 +563,7 @@ static const struct hpt_info hpt302 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32537,7 +34042,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT371", .chip_type =3D HPT371, .udma_mask =3D HPT371_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -571,7 +571,7 @@ static const struct hpt_info hpt371 __de +@@ -571,7 +571,7 @@ static const struct hpt_info hpt371 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32546,7 +34051,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT372N", .chip_type =3D HPT372N, .udma_mask =3D HPT372_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -579,7 +579,7 @@ static const struct hpt_info hpt372n __d +@@ -579,7 +579,7 @@ static const struct hpt_info hpt372n __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32555,7 +34060,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT302N", .chip_type =3D HPT302N, .udma_mask =3D HPT302_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -587,7 +587,7 @@ static const struct hpt_info hpt302n __d +@@ -587,7 +587,7 @@ static const struct hpt_info hpt302n __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -32564,7 +34069,7 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c l= inux-2.6.32.49/drivers/ide/hpt3 .chip_name =3D "HPT371N", .chip_type =3D HPT371N, .udma_mask =3D HPT371_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -1422,7 +1422,7 @@ static const struct ide_dma_ops hpt36x_d +@@ -1422,7 +1422,7 @@ static const struct ide_dma_ops hpt36x_dma_ops =3D= { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -32573,10 +34078,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/hpt366.c= linux-2.6.32.49/drivers/ide/hpt3 { /* 0: HPT36x */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_hpt366, -diff -urNp linux-2.6.32.49/drivers/ide/ide-cd.c linux-2.6.32.49/drivers/= ide/ide-cd.c ---- linux-2.6.32.49/drivers/ide/ide-cd.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/ide-cd.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -774,7 +774,7 @@ static void cdrom_do_block_pc(ide_drive_ +diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c +index 2de76cc..74186a1 100644 +--- a/drivers/ide/ide-cd.c ++++ b/drivers/ide/ide-cd.c +@@ -774,7 +774,7 @@ static void cdrom_do_block_pc(ide_drive_t *drive, st= ruct request *rq) alignment =3D queue_dma_alignment(q) | q->dma_pad_mask; if ((unsigned long)buf & alignment || blk_rq_bytes(rq) & q->dma_pad_mask @@ -32585,10 +34091,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/ide-cd.c= linux-2.6.32.49/drivers/ide/ide- drive->dma =3D 0; } } -diff -urNp linux-2.6.32.49/drivers/ide/ide-floppy.c linux-2.6.32.49/driv= ers/ide/ide-floppy.c ---- linux-2.6.32.49/drivers/ide/ide-floppy.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ide/ide-floppy.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -373,6 +373,8 @@ static int ide_floppy_get_capacity(ide_d +diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c +index fefbdfc..62ff465 100644 +--- a/drivers/ide/ide-floppy.c ++++ b/drivers/ide/ide-floppy.c +@@ -373,6 +373,8 @@ static int ide_floppy_get_capacity(ide_drive_t *driv= e) u8 pc_buf[256], header_len, desc_cnt; int i, rc =3D 1, blocks, length; =20 @@ -32597,10 +34104,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/ide-flop= py.c linux-2.6.32.49/drivers/ide/ ide_debug_log(IDE_DBG_FUNC, "enter"); =20 drive->bios_cyl =3D 0; -diff -urNp linux-2.6.32.49/drivers/ide/ide-pci-generic.c linux-2.6.32.49= /drivers/ide/ide-pci-generic.c ---- linux-2.6.32.49/drivers/ide/ide-pci-generic.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/ide/ide-pci-generic.c 2011-11-18 18:01:55.00= 0000000 -0500 -@@ -53,7 +53,7 @@ static const struct ide_port_ops netcell +diff --git a/drivers/ide/ide-pci-generic.c b/drivers/ide/ide-pci-generic= .c +index 39d4e01..11538ce 100644 +--- a/drivers/ide/ide-pci-generic.c ++++ b/drivers/ide/ide-pci-generic.c +@@ -53,7 +53,7 @@ static const struct ide_port_ops netcell_port_ops =3D = { .udma_mask =3D ATA_UDMA6, \ } =20 @@ -32609,10 +34117,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/ide-pci-= generic.c linux-2.6.32.49/drivers /* 0: Unknown */ DECLARE_GENERIC_PCI_DEV(0), =20 -diff -urNp linux-2.6.32.49/drivers/ide/it8172.c linux-2.6.32.49/drivers/= ide/it8172.c ---- linux-2.6.32.49/drivers/ide/it8172.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/it8172.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -115,7 +115,7 @@ static const struct ide_port_ops it8172_ +diff --git a/drivers/ide/it8172.c b/drivers/ide/it8172.c +index 0d266a5..aaca790 100644 +--- a/drivers/ide/it8172.c ++++ b/drivers/ide/it8172.c +@@ -115,7 +115,7 @@ static const struct ide_port_ops it8172_port_ops =3D= { .set_dma_mode =3D it8172_set_dma_mode, }; =20 @@ -32621,10 +34130,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/it8172.c= linux-2.6.32.49/drivers/ide/it81 .name =3D DRV_NAME, .port_ops =3D &it8172_port_ops, .enablebits =3D { {0x41, 0x80, 0x80}, {0x00, 0x00, 0x00} }, -diff -urNp linux-2.6.32.49/drivers/ide/it8213.c linux-2.6.32.49/drivers/= ide/it8213.c ---- linux-2.6.32.49/drivers/ide/it8213.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/it8213.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -156,7 +156,7 @@ static const struct ide_port_ops it8213_ +diff --git a/drivers/ide/it8213.c b/drivers/ide/it8213.c +index 4797616..4be488a 100644 +--- a/drivers/ide/it8213.c ++++ b/drivers/ide/it8213.c +@@ -156,7 +156,7 @@ static const struct ide_port_ops it8213_port_ops =3D= { .cable_detect =3D it8213_cable_detect, }; =20 @@ -32633,10 +34143,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/it8213.c= linux-2.6.32.49/drivers/ide/it82 .name =3D DRV_NAME, .enablebits =3D { {0x41, 0x80, 0x80} }, .port_ops =3D &it8213_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/it821x.c linux-2.6.32.49/drivers/= ide/it821x.c ---- linux-2.6.32.49/drivers/ide/it821x.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/it821x.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -627,7 +627,7 @@ static const struct ide_port_ops it821x_ +diff --git a/drivers/ide/it821x.c b/drivers/ide/it821x.c +index 51aa745..146ee60 100644 +--- a/drivers/ide/it821x.c ++++ b/drivers/ide/it821x.c +@@ -627,7 +627,7 @@ static const struct ide_port_ops it821x_port_ops =3D= { .cable_detect =3D it821x_cable_detect, }; =20 @@ -32645,10 +34156,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/it821x.c= linux-2.6.32.49/drivers/ide/it82 .name =3D DRV_NAME, .init_chipset =3D init_chipset_it821x, .init_hwif =3D init_hwif_it821x, -diff -urNp linux-2.6.32.49/drivers/ide/jmicron.c linux-2.6.32.49/drivers= /ide/jmicron.c ---- linux-2.6.32.49/drivers/ide/jmicron.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/jmicron.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -102,7 +102,7 @@ static const struct ide_port_ops jmicron +diff --git a/drivers/ide/jmicron.c b/drivers/ide/jmicron.c +index bf2be64..9270098 100644 +--- a/drivers/ide/jmicron.c ++++ b/drivers/ide/jmicron.c +@@ -102,7 +102,7 @@ static const struct ide_port_ops jmicron_port_ops =3D= { .cable_detect =3D jmicron_cable_detect, }; =20 @@ -32657,10 +34169,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/jmicron.= c linux-2.6.32.49/drivers/ide/jmi .name =3D DRV_NAME, .enablebits =3D { { 0x40, 0x01, 0x01 }, { 0x40, 0x10, 0x10 } }, .port_ops =3D &jmicron_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/ns87415.c linux-2.6.32.49/drivers= /ide/ns87415.c ---- linux-2.6.32.49/drivers/ide/ns87415.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/ns87415.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -293,7 +293,7 @@ static const struct ide_dma_ops ns87415_ +diff --git a/drivers/ide/ns87415.c b/drivers/ide/ns87415.c +index 95327a2..73f78d8 100644 +--- a/drivers/ide/ns87415.c ++++ b/drivers/ide/ns87415.c +@@ -293,7 +293,7 @@ static const struct ide_dma_ops ns87415_dma_ops =3D = { .dma_sff_read_status =3D superio_dma_sff_read_status, }; =20 @@ -32669,10 +34182,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/ns87415.= c linux-2.6.32.49/drivers/ide/ns8 .name =3D DRV_NAME, .init_hwif =3D init_hwif_ns87415, .tp_ops =3D &ns87415_tp_ops, -diff -urNp linux-2.6.32.49/drivers/ide/opti621.c linux-2.6.32.49/drivers= /ide/opti621.c ---- linux-2.6.32.49/drivers/ide/opti621.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/opti621.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -202,7 +202,7 @@ static const struct ide_port_ops opti621 +diff --git a/drivers/ide/opti621.c b/drivers/ide/opti621.c +index f1d70d6..e1de05b 100644 +--- a/drivers/ide/opti621.c ++++ b/drivers/ide/opti621.c +@@ -202,7 +202,7 @@ static const struct ide_port_ops opti621_port_ops =3D= { .set_pio_mode =3D opti621_set_pio_mode, }; =20 @@ -32681,10 +34195,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/opti621.= c linux-2.6.32.49/drivers/ide/opt .name =3D DRV_NAME, .enablebits =3D { {0x45, 0x80, 0x00}, {0x40, 0x08, 0x00} }, .port_ops =3D &opti621_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/pdc202xx_new.c linux-2.6.32.49/dr= ivers/ide/pdc202xx_new.c ---- linux-2.6.32.49/drivers/ide/pdc202xx_new.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ide/pdc202xx_new.c 2011-11-18 18:01:55.00000= 0000 -0500 -@@ -465,7 +465,7 @@ static const struct ide_port_ops pdcnew_ +diff --git a/drivers/ide/pdc202xx_new.c b/drivers/ide/pdc202xx_new.c +index 65ba823..7311f4d 100644 +--- a/drivers/ide/pdc202xx_new.c ++++ b/drivers/ide/pdc202xx_new.c +@@ -465,7 +465,7 @@ static const struct ide_port_ops pdcnew_port_ops =3D= { .udma_mask =3D udma, \ } =20 @@ -32693,10 +34208,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/pdc202xx= _new.c linux-2.6.32.49/drivers/id /* 0: PDC202{68,70} */ DECLARE_PDCNEW_DEV(ATA_UDMA5), /* 1: PDC202{69,71,75,76,77} */ DECLARE_PDCNEW_DEV(ATA_UDMA6), }; -diff -urNp linux-2.6.32.49/drivers/ide/pdc202xx_old.c linux-2.6.32.49/dr= ivers/ide/pdc202xx_old.c ---- linux-2.6.32.49/drivers/ide/pdc202xx_old.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/ide/pdc202xx_old.c 2011-11-18 18:01:55.00000= 0000 -0500 -@@ -285,7 +285,7 @@ static const struct ide_dma_ops pdc2026x +diff --git a/drivers/ide/pdc202xx_old.c b/drivers/ide/pdc202xx_old.c +index cb812f3..af816ef 100644 +--- a/drivers/ide/pdc202xx_old.c ++++ b/drivers/ide/pdc202xx_old.c +@@ -285,7 +285,7 @@ static const struct ide_dma_ops pdc2026x_dma_ops =3D= { .max_sectors =3D sectors, \ } =20 @@ -32705,10 +34221,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/pdc202xx= _old.c linux-2.6.32.49/drivers/id { /* 0: PDC20246 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_pdc202xx, -diff -urNp linux-2.6.32.49/drivers/ide/piix.c linux-2.6.32.49/drivers/id= e/piix.c ---- linux-2.6.32.49/drivers/ide/piix.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/ide/piix.c 2011-11-18 18:01:55.000000000 -05= 00 -@@ -344,7 +344,7 @@ static const struct ide_port_ops ich_por +diff --git a/drivers/ide/piix.c b/drivers/ide/piix.c +index bf14f39..15c4b98 100644 +--- a/drivers/ide/piix.c ++++ b/drivers/ide/piix.c +@@ -344,7 +344,7 @@ static const struct ide_port_ops ich_port_ops =3D { .udma_mask =3D udma, \ } =20 @@ -32717,10 +34234,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/piix.c l= inux-2.6.32.49/drivers/ide/piix.c /* 0: MPIIX */ { /* * MPIIX actually has only a single IDE channel mapped to -diff -urNp linux-2.6.32.49/drivers/ide/rz1000.c linux-2.6.32.49/drivers/= ide/rz1000.c ---- linux-2.6.32.49/drivers/ide/rz1000.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/rz1000.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -38,7 +38,7 @@ static int __devinit rz1000_disable_read +diff --git a/drivers/ide/rz1000.c b/drivers/ide/rz1000.c +index a6414a8..c04173e 100644 +--- a/drivers/ide/rz1000.c ++++ b/drivers/ide/rz1000.c +@@ -38,7 +38,7 @@ static int __devinit rz1000_disable_readahead(struct p= ci_dev *dev) } } =20 @@ -32729,10 +34247,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/rz1000.c= linux-2.6.32.49/drivers/ide/rz10 .name =3D DRV_NAME, .host_flags =3D IDE_HFLAG_NO_DMA, }; -diff -urNp linux-2.6.32.49/drivers/ide/sc1200.c linux-2.6.32.49/drivers/= ide/sc1200.c ---- linux-2.6.32.49/drivers/ide/sc1200.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/sc1200.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -290,7 +290,7 @@ static const struct ide_dma_ops sc1200_d +diff --git a/drivers/ide/sc1200.c b/drivers/ide/sc1200.c +index d467478..9203942 100644 +--- a/drivers/ide/sc1200.c ++++ b/drivers/ide/sc1200.c +@@ -290,7 +290,7 @@ static const struct ide_dma_ops sc1200_dma_ops =3D { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -32741,10 +34260,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/sc1200.c= linux-2.6.32.49/drivers/ide/sc12 .name =3D DRV_NAME, .port_ops =3D &sc1200_port_ops, .dma_ops =3D &sc1200_dma_ops, -diff -urNp linux-2.6.32.49/drivers/ide/scc_pata.c linux-2.6.32.49/driver= s/ide/scc_pata.c ---- linux-2.6.32.49/drivers/ide/scc_pata.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ide/scc_pata.c 2011-11-18 18:01:55.000000000= -0500 -@@ -811,7 +811,7 @@ static const struct ide_dma_ops scc_dma_ +diff --git a/drivers/ide/scc_pata.c b/drivers/ide/scc_pata.c +index 1104bb3..59c5194 100644 +--- a/drivers/ide/scc_pata.c ++++ b/drivers/ide/scc_pata.c +@@ -811,7 +811,7 @@ static const struct ide_dma_ops scc_dma_ops =3D { .dma_sff_read_status =3D scc_dma_sff_read_status, }; =20 @@ -32753,10 +34273,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/scc_pata= .c linux-2.6.32.49/drivers/ide/sc .name =3D "sccIDE", .init_iops =3D init_iops_scc, .init_dma =3D scc_init_dma, -diff -urNp linux-2.6.32.49/drivers/ide/serverworks.c linux-2.6.32.49/dri= vers/ide/serverworks.c ---- linux-2.6.32.49/drivers/ide/serverworks.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ide/serverworks.c 2011-11-18 18:01:55.000000= 000 -0500 -@@ -353,7 +353,7 @@ static const struct ide_port_ops svwks_p +diff --git a/drivers/ide/serverworks.c b/drivers/ide/serverworks.c +index b6554ef..6cc2cc3 100644 +--- a/drivers/ide/serverworks.c ++++ b/drivers/ide/serverworks.c +@@ -353,7 +353,7 @@ static const struct ide_port_ops svwks_port_ops =3D = { .cable_detect =3D svwks_cable_detect, }; =20 @@ -32765,10 +34286,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/serverwo= rks.c linux-2.6.32.49/drivers/ide { /* 0: OSB4 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_svwks, -diff -urNp linux-2.6.32.49/drivers/ide/setup-pci.c linux-2.6.32.49/drive= rs/ide/setup-pci.c ---- linux-2.6.32.49/drivers/ide/setup-pci.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ide/setup-pci.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -542,6 +542,8 @@ int ide_pci_init_two(struct pci_dev *dev +diff --git a/drivers/ide/setup-pci.c b/drivers/ide/setup-pci.c +index ab3db61..afed580 100644 +--- a/drivers/ide/setup-pci.c ++++ b/drivers/ide/setup-pci.c +@@ -542,6 +542,8 @@ int ide_pci_init_two(struct pci_dev *dev1, struct pc= i_dev *dev2, int ret, i, n_ports =3D dev2 ? 4 : 2; struct ide_hw hw[4], *hws[] =3D { NULL, NULL, NULL, NULL }; =20 @@ -32777,10 +34299,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/setup-pc= i.c linux-2.6.32.49/drivers/ide/s for (i =3D 0; i < n_ports / 2; i++) { ret =3D ide_setup_pci_controller(pdev[i], d, !i); if (ret < 0) -diff -urNp linux-2.6.32.49/drivers/ide/siimage.c linux-2.6.32.49/drivers= /ide/siimage.c ---- linux-2.6.32.49/drivers/ide/siimage.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/siimage.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -719,7 +719,7 @@ static const struct ide_dma_ops sil_dma_ +diff --git a/drivers/ide/siimage.c b/drivers/ide/siimage.c +index d95df52..0b03a39 100644 +--- a/drivers/ide/siimage.c ++++ b/drivers/ide/siimage.c +@@ -719,7 +719,7 @@ static const struct ide_dma_ops sil_dma_ops =3D { .udma_mask =3D ATA_UDMA6, \ } =20 @@ -32789,10 +34312,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/siimage.= c linux-2.6.32.49/drivers/ide/sii /* 0: SiI680 */ DECLARE_SII_DEV(&sil_pata_port_ops), /* 1: SiI3112 */ DECLARE_SII_DEV(&sil_sata_port_ops) }; -diff -urNp linux-2.6.32.49/drivers/ide/sis5513.c linux-2.6.32.49/drivers= /ide/sis5513.c ---- linux-2.6.32.49/drivers/ide/sis5513.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/sis5513.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -561,7 +561,7 @@ static const struct ide_port_ops sis_ata +diff --git a/drivers/ide/sis5513.c b/drivers/ide/sis5513.c +index 3b88eba..ca8699d 100644 +--- a/drivers/ide/sis5513.c ++++ b/drivers/ide/sis5513.c +@@ -561,7 +561,7 @@ static const struct ide_port_ops sis_ata133_port_ops= =3D { .cable_detect =3D sis_cable_detect, }; =20 @@ -32801,10 +34325,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/sis5513.= c linux-2.6.32.49/drivers/ide/sis .name =3D DRV_NAME, .init_chipset =3D init_chipset_sis5513, .enablebits =3D { {0x4a, 0x02, 0x02}, {0x4a, 0x04, 0x04} }, -diff -urNp linux-2.6.32.49/drivers/ide/sl82c105.c linux-2.6.32.49/driver= s/ide/sl82c105.c ---- linux-2.6.32.49/drivers/ide/sl82c105.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ide/sl82c105.c 2011-11-18 18:01:55.000000000= -0500 -@@ -319,7 +319,7 @@ static const struct ide_dma_ops sl82c105 +diff --git a/drivers/ide/sl82c105.c b/drivers/ide/sl82c105.c +index d698da4..fca42a4 100644 +--- a/drivers/ide/sl82c105.c ++++ b/drivers/ide/sl82c105.c +@@ -319,7 +319,7 @@ static const struct ide_dma_ops sl82c105_dma_ops =3D= { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -32813,10 +34338,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/sl82c105= .c linux-2.6.32.49/drivers/ide/sl .name =3D DRV_NAME, .init_chipset =3D init_chipset_sl82c105, .enablebits =3D {{0x40,0x01,0x01}, {0x40,0x10,0x10}}, -diff -urNp linux-2.6.32.49/drivers/ide/slc90e66.c linux-2.6.32.49/driver= s/ide/slc90e66.c ---- linux-2.6.32.49/drivers/ide/slc90e66.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ide/slc90e66.c 2011-11-18 18:01:55.000000000= -0500 -@@ -131,7 +131,7 @@ static const struct ide_port_ops slc90e6 +diff --git a/drivers/ide/slc90e66.c b/drivers/ide/slc90e66.c +index 1ccfb40..83d5779 100644 +--- a/drivers/ide/slc90e66.c ++++ b/drivers/ide/slc90e66.c +@@ -131,7 +131,7 @@ static const struct ide_port_ops slc90e66_port_ops =3D= { .cable_detect =3D slc90e66_cable_detect, }; =20 @@ -32825,10 +34351,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/slc90e66= .c linux-2.6.32.49/drivers/ide/sl .name =3D DRV_NAME, .enablebits =3D { {0x41, 0x80, 0x80}, {0x43, 0x80, 0x80} }, .port_ops =3D &slc90e66_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/tc86c001.c linux-2.6.32.49/driver= s/ide/tc86c001.c ---- linux-2.6.32.49/drivers/ide/tc86c001.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/ide/tc86c001.c 2011-11-18 18:01:55.000000000= -0500 -@@ -190,7 +190,7 @@ static const struct ide_dma_ops tc86c001 +diff --git a/drivers/ide/tc86c001.c b/drivers/ide/tc86c001.c +index 05a93d6..5f9e325 100644 +--- a/drivers/ide/tc86c001.c ++++ b/drivers/ide/tc86c001.c +@@ -190,7 +190,7 @@ static const struct ide_dma_ops tc86c001_dma_ops =3D= { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -32837,10 +34364,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/tc86c001= .c linux-2.6.32.49/drivers/ide/tc .name =3D DRV_NAME, .init_hwif =3D init_hwif_tc86c001, .port_ops =3D &tc86c001_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/triflex.c linux-2.6.32.49/drivers= /ide/triflex.c ---- linux-2.6.32.49/drivers/ide/triflex.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/ide/triflex.c 2011-11-18 18:01:55.000000000 = -0500 -@@ -92,7 +92,7 @@ static const struct ide_port_ops triflex +diff --git a/drivers/ide/triflex.c b/drivers/ide/triflex.c +index 8773c3b..7907d6c 100644 +--- a/drivers/ide/triflex.c ++++ b/drivers/ide/triflex.c +@@ -92,7 +92,7 @@ static const struct ide_port_ops triflex_port_ops =3D = { .set_dma_mode =3D triflex_set_mode, }; =20 @@ -32849,10 +34377,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/triflex.= c linux-2.6.32.49/drivers/ide/tri .name =3D DRV_NAME, .enablebits =3D {{0x80, 0x01, 0x01}, {0x80, 0x02, 0x02}}, .port_ops =3D &triflex_port_ops, -diff -urNp linux-2.6.32.49/drivers/ide/trm290.c linux-2.6.32.49/drivers/= ide/trm290.c ---- linux-2.6.32.49/drivers/ide/trm290.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/ide/trm290.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -324,7 +324,7 @@ static struct ide_dma_ops trm290_dma_ops +diff --git a/drivers/ide/trm290.c b/drivers/ide/trm290.c +index 4b42ca0..e494a98 100644 +--- a/drivers/ide/trm290.c ++++ b/drivers/ide/trm290.c +@@ -324,7 +324,7 @@ static struct ide_dma_ops trm290_dma_ops =3D { .dma_check =3D trm290_dma_check, }; =20 @@ -32861,10 +34390,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/trm290.c= linux-2.6.32.49/drivers/ide/trm2 .name =3D DRV_NAME, .init_hwif =3D init_hwif_trm290, .tp_ops =3D &trm290_tp_ops, -diff -urNp linux-2.6.32.49/drivers/ide/via82cxxx.c linux-2.6.32.49/drive= rs/ide/via82cxxx.c ---- linux-2.6.32.49/drivers/ide/via82cxxx.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ide/via82cxxx.c 2011-11-18 18:01:55.00000000= 0 -0500 -@@ -374,7 +374,7 @@ static const struct ide_port_ops via_por +diff --git a/drivers/ide/via82cxxx.c b/drivers/ide/via82cxxx.c +index 028de26..520d5d5 100644 +--- a/drivers/ide/via82cxxx.c ++++ b/drivers/ide/via82cxxx.c +@@ -374,7 +374,7 @@ static const struct ide_port_ops via_port_ops =3D { .cable_detect =3D via82cxxx_cable_detect, }; =20 @@ -32873,10 +34403,11 @@ diff -urNp linux-2.6.32.49/drivers/ide/via82cxx= x.c linux-2.6.32.49/drivers/ide/v .name =3D DRV_NAME, .init_chipset =3D init_chipset_via82cxxx, .enablebits =3D { { 0x40, 0x02, 0x02 }, { 0x40, 0x01, 0x01 } }, -diff -urNp linux-2.6.32.49/drivers/ieee1394/dv1394.c linux-2.6.32.49/dri= vers/ieee1394/dv1394.c ---- linux-2.6.32.49/drivers/ieee1394/dv1394.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/ieee1394/dv1394.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -739,7 +739,7 @@ static void frame_prepare(struct video_c +diff --git a/drivers/ieee1394/dv1394.c b/drivers/ieee1394/dv1394.c +index 2cd00b5..14de699 100644 +--- a/drivers/ieee1394/dv1394.c ++++ b/drivers/ieee1394/dv1394.c +@@ -739,7 +739,7 @@ static void frame_prepare(struct video_card *video, = unsigned int this_frame) based upon DIF section and sequence */ =20 @@ -32885,10 +34416,11 @@ diff -urNp linux-2.6.32.49/drivers/ieee1394/dv1= 394.c linux-2.6.32.49/drivers/iee frame_put_packet (struct frame *f, struct packet *p) { int section_type =3D p->data[0] >> 5; /* section type is in = bits 5 - 7 */ -diff -urNp linux-2.6.32.49/drivers/ieee1394/hosts.c linux-2.6.32.49/driv= ers/ieee1394/hosts.c ---- linux-2.6.32.49/drivers/ieee1394/hosts.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/ieee1394/hosts.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -78,6 +78,7 @@ static int dummy_isoctl(struct hpsb_iso=20 +diff --git a/drivers/ieee1394/hosts.c b/drivers/ieee1394/hosts.c +index e947d8f..6a966b9 100644 +--- a/drivers/ieee1394/hosts.c ++++ b/drivers/ieee1394/hosts.c +@@ -78,6 +78,7 @@ static int dummy_isoctl(struct hpsb_iso *iso, enum iso= ctl_cmd command, } =20 static struct hpsb_host_driver dummy_driver =3D { @@ -32896,10 +34428,11 @@ diff -urNp linux-2.6.32.49/drivers/ieee1394/hos= ts.c linux-2.6.32.49/drivers/ieee .transmit_packet =3D dummy_transmit_packet, .devctl =3D dummy_devctl, .isoctl =3D dummy_isoctl -diff -urNp linux-2.6.32.49/drivers/ieee1394/init_ohci1394_dma.c linux-2.= 6.32.49/drivers/ieee1394/init_ohci1394_dma.c ---- linux-2.6.32.49/drivers/ieee1394/init_ohci1394_dma.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/ieee1394/init_ohci1394_dma.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -257,7 +257,7 @@ void __init init_ohci1394_dma_on_all_con +diff --git a/drivers/ieee1394/init_ohci1394_dma.c b/drivers/ieee1394/ini= t_ohci1394_dma.c +index ddaab6e..8d37435 100644 +--- a/drivers/ieee1394/init_ohci1394_dma.c ++++ b/drivers/ieee1394/init_ohci1394_dma.c +@@ -257,7 +257,7 @@ void __init init_ohci1394_dma_on_all_controllers(voi= d) for (func =3D 0; func < 8; func++) { u32 class =3D read_pci_config(num,slot,func, PCI_CLASS_REVISION); @@ -32908,10 +34441,11 @@ diff -urNp linux-2.6.32.49/drivers/ieee1394/ini= t_ohci1394_dma.c linux-2.6.32.49/ continue; /* No device at this func */ =20 if (class>>8 !=3D PCI_CLASS_SERIAL_FIREWIRE_OHCI) -diff -urNp linux-2.6.32.49/drivers/ieee1394/ohci1394.c linux-2.6.32.49/d= rivers/ieee1394/ohci1394.c ---- linux-2.6.32.49/drivers/ieee1394/ohci1394.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/ieee1394/ohci1394.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -147,9 +147,9 @@ printk(level "%s: " fmt "\n" , OHCI1394_ +diff --git a/drivers/ieee1394/ohci1394.c b/drivers/ieee1394/ohci1394.c +index 65c1429..5d8c11f 100644 +--- a/drivers/ieee1394/ohci1394.c ++++ b/drivers/ieee1394/ohci1394.c +@@ -147,9 +147,9 @@ printk(level "%s: " fmt "\n" , OHCI1394_DRIVER_NAME = , ## args) printk(level "%s: fw-host%d: " fmt "\n" , OHCI1394_DRIVER_NAME, ohci->h= ost->id , ## args) =20 /* Module Parameters */ @@ -32923,10 +34457,11 @@ diff -urNp linux-2.6.32.49/drivers/ieee1394/ohc= i1394.c linux-2.6.32.49/drivers/i =20 static void dma_trm_tasklet(unsigned long data); static void dma_trm_reset(struct dma_trm_ctx *d); -diff -urNp linux-2.6.32.49/drivers/ieee1394/sbp2.c linux-2.6.32.49/drive= rs/ieee1394/sbp2.c ---- linux-2.6.32.49/drivers/ieee1394/sbp2.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/ieee1394/sbp2.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -2111,7 +2111,7 @@ MODULE_DESCRIPTION("IEEE-1394 SBP-2 prot +diff --git a/drivers/ieee1394/sbp2.c b/drivers/ieee1394/sbp2.c +index f199896..78c9fc8 100644 +--- a/drivers/ieee1394/sbp2.c ++++ b/drivers/ieee1394/sbp2.c +@@ -2111,7 +2111,7 @@ MODULE_DESCRIPTION("IEEE-1394 SBP-2 protocol drive= r"); MODULE_SUPPORTED_DEVICE(SBP2_DEVICE_NAME); MODULE_LICENSE("GPL"); =20 @@ -32935,10 +34470,11 @@ diff -urNp linux-2.6.32.49/drivers/ieee1394/sbp= 2.c linux-2.6.32.49/drivers/ieee1 { int ret; =20 -diff -urNp linux-2.6.32.49/drivers/infiniband/core/cm.c linux-2.6.32.49/= drivers/infiniband/core/cm.c ---- linux-2.6.32.49/drivers/infiniband/core/cm.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/core/cm.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -112,7 +112,7 @@ static char const counter_group_names[CM +diff --git a/drivers/infiniband/core/cm.c b/drivers/infiniband/core/cm.c +index a5dea6b..0cefe8f 100644 +--- a/drivers/infiniband/core/cm.c ++++ b/drivers/infiniband/core/cm.c +@@ -112,7 +112,7 @@ static char const counter_group_names[CM_COUNTER_GRO= UPS] =20 struct cm_counter_group { struct kobject obj; @@ -32947,7 +34483,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ }; =20 struct cm_counter_attribute { -@@ -1386,7 +1386,7 @@ static void cm_dup_req_handler(struct cm +@@ -1386,7 +1386,7 @@ static void cm_dup_req_handler(struct cm_work *wor= k, struct ib_mad_send_buf *msg =3D NULL; int ret; =20 @@ -32956,7 +34492,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_REQ_COUNTER]); =20 /* Quick state check to discard duplicate REQs. */ -@@ -1764,7 +1764,7 @@ static void cm_dup_rep_handler(struct cm +@@ -1764,7 +1764,7 @@ static void cm_dup_rep_handler(struct cm_work *wor= k) if (!cm_id_priv) return; =20 @@ -32965,7 +34501,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_REP_COUNTER]); ret =3D cm_alloc_response_msg(work->port, work->mad_recv_wc, &msg); if (ret) -@@ -1931,7 +1931,7 @@ static int cm_rtu_handler(struct cm_work +@@ -1931,7 +1931,7 @@ static int cm_rtu_handler(struct cm_work *work) if (cm_id_priv->id.state !=3D IB_CM_REP_SENT && cm_id_priv->id.state !=3D IB_CM_MRA_REP_RCVD) { spin_unlock_irq(&cm_id_priv->lock); @@ -32974,7 +34510,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_RTU_COUNTER]); goto out; } -@@ -2110,7 +2110,7 @@ static int cm_dreq_handler(struct cm_wor +@@ -2110,7 +2110,7 @@ static int cm_dreq_handler(struct cm_work *work) cm_id_priv =3D cm_acquire_id(dreq_msg->remote_comm_id, dreq_msg->local_comm_id); if (!cm_id_priv) { @@ -32983,7 +34519,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_DREQ_COUNTER]); cm_issue_drep(work->port, work->mad_recv_wc); return -EINVAL; -@@ -2131,7 +2131,7 @@ static int cm_dreq_handler(struct cm_wor +@@ -2131,7 +2131,7 @@ static int cm_dreq_handler(struct cm_work *work) case IB_CM_MRA_REP_RCVD: break; case IB_CM_TIMEWAIT: @@ -32992,7 +34528,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_DREQ_COUNTER]); if (cm_alloc_response_msg(work->port, work->mad_recv_wc, &msg)) goto unlock; -@@ -2145,7 +2145,7 @@ static int cm_dreq_handler(struct cm_wor +@@ -2145,7 +2145,7 @@ static int cm_dreq_handler(struct cm_work *work) cm_free_msg(msg); goto deref; case IB_CM_DREQ_RCVD: @@ -33001,7 +34537,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_DREQ_COUNTER]); goto unlock; default: -@@ -2501,7 +2501,7 @@ static int cm_mra_handler(struct cm_work +@@ -2501,7 +2501,7 @@ static int cm_mra_handler(struct cm_work *work) ib_modify_mad(cm_id_priv->av.port->mad_agent, cm_id_priv->msg, timeout)) { if (cm_id_priv->id.lap_state =3D=3D IB_CM_MRA_LAP_RCVD) @@ -33010,7 +34546,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter_group[CM_RECV_DUPLICATES]. counter[CM_MRA_COUNTER]); goto out; -@@ -2510,7 +2510,7 @@ static int cm_mra_handler(struct cm_work +@@ -2510,7 +2510,7 @@ static int cm_mra_handler(struct cm_work *work) break; case IB_CM_MRA_REQ_RCVD: case IB_CM_MRA_REP_RCVD: @@ -33019,7 +34555,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_MRA_COUNTER]); /* fall through */ default: -@@ -2672,7 +2672,7 @@ static int cm_lap_handler(struct cm_work +@@ -2672,7 +2672,7 @@ static int cm_lap_handler(struct cm_work *work) case IB_CM_LAP_IDLE: break; case IB_CM_MRA_LAP_SENT: @@ -33028,7 +34564,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_LAP_COUNTER]); if (cm_alloc_response_msg(work->port, work->mad_recv_wc, &msg)) goto unlock; -@@ -2688,7 +2688,7 @@ static int cm_lap_handler(struct cm_work +@@ -2688,7 +2688,7 @@ static int cm_lap_handler(struct cm_work *work) cm_free_msg(msg); goto deref; case IB_CM_LAP_RCVD: @@ -33037,7 +34573,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_LAP_COUNTER]); goto unlock; default: -@@ -2972,7 +2972,7 @@ static int cm_sidr_req_handler(struct cm +@@ -2972,7 +2972,7 @@ static int cm_sidr_req_handler(struct cm_work *wor= k) cur_cm_id_priv =3D cm_insert_remote_sidr(cm_id_priv); if (cur_cm_id_priv) { spin_unlock_irq(&cm.lock); @@ -33046,7 +34582,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[CM_SIDR_REQ_COUNTER]); goto out; /* Duplicate message. */ } -@@ -3184,10 +3184,10 @@ static void cm_send_handler(struct ib_ma +@@ -3184,10 +3184,10 @@ static void cm_send_handler(struct ib_mad_agent = *mad_agent, if (!msg->context[0] && (attr_index !=3D CM_REJ_COUNTER)) msg->retries =3D 1; =20 @@ -33059,7 +34595,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ &port->counter_group[CM_XMIT_RETRIES]. counter[attr_index]); =20 -@@ -3397,7 +3397,7 @@ static void cm_recv_handler(struct ib_ma +@@ -3397,7 +3397,7 @@ static void cm_recv_handler(struct ib_mad_agent *m= ad_agent, } =20 attr_id =3D be16_to_cpu(mad_recv_wc->recv_buf.mad->mad_hdr.attr_id); @@ -33068,7 +34604,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/cm.c linux-2.6.32.49/drivers/ counter[attr_id - CM_ATTR_ID_OFFSET]); =20 work =3D kmalloc(sizeof *work + sizeof(struct ib_sa_path_rec) * paths, -@@ -3595,10 +3595,10 @@ static ssize_t cm_show_counter(struct ko +@@ -3595,10 +3595,10 @@ static ssize_t cm_show_counter(struct kobject *o= bj, struct attribute *attr, cm_attr =3D container_of(attr, struct cm_counter_attribute, attr); =20 return sprintf(buf, "%ld\n", @@ -33081,9 +34617,10 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/co= re/cm.c linux-2.6.32.49/drivers/ .show =3D cm_show_counter }; =20 -diff -urNp linux-2.6.32.49/drivers/infiniband/core/fmr_pool.c linux-2.6.= 32.49/drivers/infiniband/core/fmr_pool.c ---- linux-2.6.32.49/drivers/infiniband/core/fmr_pool.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/core/fmr_pool.c 2011-11-15 19:59:= 43.000000000 -0500 +diff --git a/drivers/infiniband/core/fmr_pool.c b/drivers/infiniband/cor= e/fmr_pool.c +index 4507043..14ad522 100644 +--- a/drivers/infiniband/core/fmr_pool.c ++++ b/drivers/infiniband/core/fmr_pool.c @@ -97,8 +97,8 @@ struct ib_fmr_pool { =20 struct task_struct *thread; @@ -33095,7 +34632,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/fmr_pool.c linux-2.6.32.49/dr =20 wait_queue_head_t force_wait; }; -@@ -179,10 +179,10 @@ static int ib_fmr_cleanup_thread(void *p +@@ -179,10 +179,10 @@ static int ib_fmr_cleanup_thread(void *pool_ptr) struct ib_fmr_pool *pool =3D pool_ptr; =20 do { @@ -33108,7 +34645,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/fmr_pool.c linux-2.6.32.49/dr wake_up_interruptible(&pool->force_wait); =20 if (pool->flush_function) -@@ -190,7 +190,7 @@ static int ib_fmr_cleanup_thread(void *p +@@ -190,7 +190,7 @@ static int ib_fmr_cleanup_thread(void *pool_ptr) } =20 set_current_state(TASK_INTERRUPTIBLE); @@ -33117,7 +34654,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/fmr_pool.c linux-2.6.32.49/dr !kthread_should_stop()) schedule(); __set_current_state(TASK_RUNNING); -@@ -282,8 +282,8 @@ struct ib_fmr_pool *ib_create_fmr_pool(s +@@ -282,8 +282,8 @@ struct ib_fmr_pool *ib_create_fmr_pool(struct ib_pd = *pd, pool->dirty_watermark =3D params->dirty_watermark; pool->dirty_len =3D 0; spin_lock_init(&pool->pool_lock); @@ -33128,7 +34665,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/fmr_pool.c linux-2.6.32.49/dr init_waitqueue_head(&pool->force_wait); =20 pool->thread =3D kthread_run(ib_fmr_cleanup_thread, -@@ -411,11 +411,11 @@ int ib_flush_fmr_pool(struct ib_fmr_pool +@@ -411,11 +411,11 @@ int ib_flush_fmr_pool(struct ib_fmr_pool *pool) } spin_unlock_irq(&pool->pool_lock); =20 @@ -33142,7 +34679,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/fmr_pool.c linux-2.6.32.49/dr return -EINTR; =20 return 0; -@@ -525,7 +525,7 @@ int ib_fmr_pool_unmap(struct ib_pool_fmr +@@ -525,7 +525,7 @@ int ib_fmr_pool_unmap(struct ib_pool_fmr *fmr) } else { list_add_tail(&fmr->list, &pool->dirty_list); if (++pool->dirty_len >=3D pool->dirty_watermark) { @@ -33151,10 +34688,11 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/c= ore/fmr_pool.c linux-2.6.32.49/dr wake_up_process(pool->thread); } } -diff -urNp linux-2.6.32.49/drivers/infiniband/core/sysfs.c linux-2.6.32.= 49/drivers/infiniband/core/sysfs.c ---- linux-2.6.32.49/drivers/infiniband/core/sysfs.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/core/sysfs.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -79,7 +79,7 @@ static ssize_t port_attr_show(struct kob +diff --git a/drivers/infiniband/core/sysfs.c b/drivers/infiniband/core/s= ysfs.c +index 158a214..1558bb7 100644 +--- a/drivers/infiniband/core/sysfs.c ++++ b/drivers/infiniband/core/sysfs.c +@@ -79,7 +79,7 @@ static ssize_t port_attr_show(struct kobject *kobj, return port_attr->show(p, port_attr, buf); } =20 @@ -33163,10 +34701,11 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/c= ore/sysfs.c linux-2.6.32.49/drive .show =3D port_attr_show }; =20 -diff -urNp linux-2.6.32.49/drivers/infiniband/core/uverbs_marshall.c lin= ux-2.6.32.49/drivers/infiniband/core/uverbs_marshall.c ---- linux-2.6.32.49/drivers/infiniband/core/uverbs_marshall.c 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/core/uverbs_marshall.c 2011-11-15= 19:59:43.000000000 -0500 -@@ -40,18 +40,21 @@ void ib_copy_ah_attr_to_user(struct ib_u +diff --git a/drivers/infiniband/core/uverbs_marshall.c b/drivers/infinib= and/core/uverbs_marshall.c +index 5440da0..1194ecb 100644 +--- a/drivers/infiniband/core/uverbs_marshall.c ++++ b/drivers/infiniband/core/uverbs_marshall.c +@@ -40,18 +40,21 @@ void ib_copy_ah_attr_to_user(struct ib_uverbs_ah_att= r *dst, dst->grh.sgid_index =3D src->grh.sgid_index; dst->grh.hop_limit =3D src->grh.hop_limit; dst->grh.traffic_class =3D src->grh.traffic_class; @@ -33188,7 +34727,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/cor= e/uverbs_marshall.c linux-2.6.3 dst->cur_qp_state =3D src->cur_qp_state; dst->path_mtu =3D src->path_mtu; dst->path_mig_state =3D src->path_mig_state; -@@ -83,6 +86,7 @@ void ib_copy_qp_attr_to_user(struct ib_u +@@ -83,6 +86,7 @@ void ib_copy_qp_attr_to_user(struct ib_uverbs_qp_attr = *dst, dst->rnr_retry =3D src->rnr_retry; dst->alt_port_num =3D src->alt_port_num; dst->alt_timeout =3D src->alt_timeout; @@ -33196,10 +34735,11 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/c= ore/uverbs_marshall.c linux-2.6.3 } EXPORT_SYMBOL(ib_copy_qp_attr_to_user); =20 -diff -urNp linux-2.6.32.49/drivers/infiniband/hw/ipath/ipath_fs.c linux-= 2.6.32.49/drivers/infiniband/hw/ipath/ipath_fs.c ---- linux-2.6.32.49/drivers/infiniband/hw/ipath/ipath_fs.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/hw/ipath/ipath_fs.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -110,6 +110,8 @@ static ssize_t atomic_counters_read(stru +diff --git a/drivers/infiniband/hw/ipath/ipath_fs.c b/drivers/infiniband= /hw/ipath/ipath_fs.c +index 100da85..62e6b88 100644 +--- a/drivers/infiniband/hw/ipath/ipath_fs.c ++++ b/drivers/infiniband/hw/ipath/ipath_fs.c +@@ -110,6 +110,8 @@ static ssize_t atomic_counters_read(struct file *fil= e, char __user *buf, struct infinipath_counters counters; struct ipath_devdata *dd; =20 @@ -33208,10 +34748,11 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/h= w/ipath/ipath_fs.c linux-2.6.32.4 dd =3D file->f_path.dentry->d_inode->i_private; dd->ipath_f_read_counters(dd, &counters); =20 -diff -urNp linux-2.6.32.49/drivers/infiniband/hw/nes/nes.c linux-2.6.32.= 49/drivers/infiniband/hw/nes/nes.c ---- linux-2.6.32.49/drivers/infiniband/hw/nes/nes.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/hw/nes/nes.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -102,7 +102,7 @@ MODULE_PARM_DESC(limit_maxrdreqsz, "Limi +diff --git a/drivers/infiniband/hw/nes/nes.c b/drivers/infiniband/hw/nes= /nes.c +index cbde0cf..afaf55c 100644 +--- a/drivers/infiniband/hw/nes/nes.c ++++ b/drivers/infiniband/hw/nes/nes.c +@@ -102,7 +102,7 @@ MODULE_PARM_DESC(limit_maxrdreqsz, "Limit max read r= equest size to 256 Bytes"); LIST_HEAD(nes_adapter_list); static LIST_HEAD(nes_dev_list); =20 @@ -33220,7 +34761,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes.c linux-2.6.32.49/drive =20 static unsigned int ee_flsh_adapter; static unsigned int sysfs_nonidx_addr; -@@ -259,7 +259,7 @@ static void nes_cqp_rem_ref_callback(str +@@ -259,7 +259,7 @@ static void nes_cqp_rem_ref_callback(struct nes_devi= ce *nesdev, struct nes_cqp_r struct nes_adapter *nesadapter =3D nesdev->nesadapter; u32 qp_id; =20 @@ -33229,9 +34770,60 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw= /nes/nes.c linux-2.6.32.49/drive =20 /* Free the control structures */ =20 -diff -urNp linux-2.6.32.49/drivers/infiniband/hw/nes/nes_cm.c linux-2.6.= 32.49/drivers/infiniband/hw/nes/nes_cm.c ---- linux-2.6.32.49/drivers/infiniband/hw/nes/nes_cm.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/hw/nes/nes_cm.c 2011-11-15 19:59:= 43.000000000 -0500 +diff --git a/drivers/infiniband/hw/nes/nes.h b/drivers/infiniband/hw/nes= /nes.h +index bcc6abc..9c76b2f 100644 +--- a/drivers/infiniband/hw/nes/nes.h ++++ b/drivers/infiniband/hw/nes/nes.h +@@ -174,17 +174,17 @@ extern unsigned int nes_debug_level; + extern unsigned int wqm_quanta; + extern struct list_head nes_adapter_list; +=20 +-extern atomic_t cm_connects; +-extern atomic_t cm_accepts; +-extern atomic_t cm_disconnects; +-extern atomic_t cm_closes; +-extern atomic_t cm_connecteds; +-extern atomic_t cm_connect_reqs; +-extern atomic_t cm_rejects; +-extern atomic_t mod_qp_timouts; +-extern atomic_t qps_created; +-extern atomic_t qps_destroyed; +-extern atomic_t sw_qps_destroyed; ++extern atomic_unchecked_t cm_connects; ++extern atomic_unchecked_t cm_accepts; ++extern atomic_unchecked_t cm_disconnects; ++extern atomic_unchecked_t cm_closes; ++extern atomic_unchecked_t cm_connecteds; ++extern atomic_unchecked_t cm_connect_reqs; ++extern atomic_unchecked_t cm_rejects; ++extern atomic_unchecked_t mod_qp_timouts; ++extern atomic_unchecked_t qps_created; ++extern atomic_unchecked_t qps_destroyed; ++extern atomic_unchecked_t sw_qps_destroyed; + extern u32 mh_detected; + extern u32 mh_pauses_sent; + extern u32 cm_packets_sent; +@@ -196,11 +196,11 @@ extern u32 cm_packets_retrans; + extern u32 cm_listens_created; + extern u32 cm_listens_destroyed; + extern u32 cm_backlog_drops; +-extern atomic_t cm_loopbacks; +-extern atomic_t cm_nodes_created; +-extern atomic_t cm_nodes_destroyed; +-extern atomic_t cm_accel_dropped_pkts; +-extern atomic_t cm_resets_recvd; ++extern atomic_unchecked_t cm_loopbacks; ++extern atomic_unchecked_t cm_nodes_created; ++extern atomic_unchecked_t cm_nodes_destroyed; ++extern atomic_unchecked_t cm_accel_dropped_pkts; ++extern atomic_unchecked_t cm_resets_recvd; +=20 + extern u32 int_mod_timer_init; + extern u32 int_mod_cq_depth_256; +diff --git a/drivers/infiniband/hw/nes/nes_cm.c b/drivers/infiniband/hw/= nes/nes_cm.c +index 73473db..5ed06e8 100644 +--- a/drivers/infiniband/hw/nes/nes_cm.c ++++ b/drivers/infiniband/hw/nes/nes_cm.c @@ -69,11 +69,11 @@ u32 cm_packets_received; u32 cm_listens_created; u32 cm_listens_destroyed; @@ -33270,7 +34862,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr =20 =20 /** -@@ -1195,7 +1195,7 @@ static struct nes_cm_node *make_cm_node( +@@ -1195,7 +1195,7 @@ static struct nes_cm_node *make_cm_node(struct nes= _cm_core *cm_core, cm_node->rem_mac); =20 add_hte_node(cm_core, cm_node); @@ -33279,7 +34871,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr =20 return cm_node; } -@@ -1253,7 +1253,7 @@ static int rem_ref_cm_node(struct nes_cm +@@ -1253,7 +1253,7 @@ static int rem_ref_cm_node(struct nes_cm_core *cm_= core, } =20 atomic_dec(&cm_core->node_cnt); @@ -33288,7 +34880,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr nesqp =3D cm_node->nesqp; if (nesqp) { nesqp->cm_node =3D NULL; -@@ -1320,7 +1320,7 @@ static int process_options(struct nes_cm +@@ -1320,7 +1320,7 @@ static int process_options(struct nes_cm_node *cm_= node, u8 *optionsloc, =20 static void drop_packet(struct sk_buff *skb) { @@ -33297,7 +34889,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr dev_kfree_skb_any(skb); } =20 -@@ -1377,7 +1377,7 @@ static void handle_rst_pkt(struct nes_cm +@@ -1377,7 +1377,7 @@ static void handle_rst_pkt(struct nes_cm_node *cm_= node, struct sk_buff *skb, =20 int reset =3D 0; /* whether to send reset in case of err.. */ int passive_state; @@ -33306,7 +34898,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr nes_debug(NES_DBG_CM, "Received Reset, cm_node =3D %p, state =3D %u." " refcnt=3D%d\n", cm_node, cm_node->state, atomic_read(&cm_node->ref_count)); -@@ -2000,7 +2000,7 @@ static struct nes_cm_node *mini_cm_conne +@@ -2000,7 +2000,7 @@ static struct nes_cm_node *mini_cm_connect(struct = nes_cm_core *cm_core, rem_ref_cm_node(cm_node->cm_core, cm_node); return NULL; } @@ -33315,7 +34907,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr loopbackremotenode->loopbackpartner =3D cm_node; loopbackremotenode->tcp_cntxt.rcv_wscale =3D NES_CM_DEFAULT_RCV_WND_SCALE; -@@ -2262,7 +2262,7 @@ static int mini_cm_recv_pkt(struct nes_c +@@ -2262,7 +2262,7 @@ static int mini_cm_recv_pkt(struct nes_cm_core *cm= _core, add_ref_cm_node(cm_node); } else if (cm_node->state =3D=3D NES_CM_STATE_TSA) { rem_ref_cm_node(cm_core, cm_node); @@ -33324,7 +34916,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr dev_kfree_skb_any(skb); break; } -@@ -2568,7 +2568,7 @@ static int nes_cm_disconn_true(struct ne +@@ -2568,7 +2568,7 @@ static int nes_cm_disconn_true(struct nes_qp *nesq= p) =20 if ((cm_id) && (cm_id->event_handler)) { if (issue_disconn) { @@ -33333,7 +34925,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr cm_event.event =3D IW_CM_EVENT_DISCONNECT; cm_event.status =3D disconn_status; cm_event.local_addr =3D cm_id->local_addr; -@@ -2590,7 +2590,7 @@ static int nes_cm_disconn_true(struct ne +@@ -2590,7 +2590,7 @@ static int nes_cm_disconn_true(struct nes_qp *nesq= p) } =20 if (issue_close) { @@ -33342,7 +34934,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr nes_disconnect(nesqp, 1); =20 cm_id->provider_data =3D nesqp; -@@ -2710,7 +2710,7 @@ int nes_accept(struct iw_cm_id *cm_id, s +@@ -2710,7 +2710,7 @@ int nes_accept(struct iw_cm_id *cm_id, struct iw_c= m_conn_param *conn_param) =20 nes_debug(NES_DBG_CM, "QP%u, cm_node=3D%p, jiffies =3D %lu listener =3D= %p\n", nesqp->hwqp.qp_id, cm_node, jiffies, cm_node->listener); @@ -33351,7 +34943,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr =20 nes_debug(NES_DBG_CM, "netdev refcnt =3D %u.\n", atomic_read(&nesvnic->netdev->refcnt)); -@@ -2919,7 +2919,7 @@ int nes_reject(struct iw_cm_id *cm_id, c +@@ -2919,7 +2919,7 @@ int nes_reject(struct iw_cm_id *cm_id, const void = *pdata, u8 pdata_len) =20 struct nes_cm_core *cm_core; =20 @@ -33360,7 +34952,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr cm_node =3D (struct nes_cm_node *) cm_id->provider_data; loopback =3D cm_node->loopbackpartner; cm_core =3D cm_node->cm_core; -@@ -2982,7 +2982,7 @@ int nes_connect(struct iw_cm_id *cm_id,=20 +@@ -2982,7 +2982,7 @@ int nes_connect(struct iw_cm_id *cm_id, struct iw_= cm_conn_param *conn_param) ntohl(cm_id->local_addr.sin_addr.s_addr), ntohs(cm_id->local_addr.sin_port)); =20 @@ -33369,7 +34961,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr nesqp->active_conn =3D 1; =20 /* cache the cm_id in the qp */ -@@ -3195,7 +3195,7 @@ static void cm_event_connected(struct ne +@@ -3195,7 +3195,7 @@ static void cm_event_connected(struct nes_cm_event= *event) if (nesqp->destroyed) { return; } @@ -33378,7 +34970,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr nes_debug(NES_DBG_CM, "QP%u attempting to connect to 0x%08X:0x%04X on= " " local port 0x%04X. jiffies =3D %lu.\n", nesqp->hwqp.qp_id, -@@ -3403,7 +3403,7 @@ static void cm_event_reset(struct nes_cm +@@ -3403,7 +3403,7 @@ static void cm_event_reset(struct nes_cm_event *ev= ent) =20 ret =3D cm_id->event_handler(cm_id, &cm_event); cm_id->add_ref(cm_id); @@ -33387,7 +34979,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr cm_event.event =3D IW_CM_EVENT_CLOSE; cm_event.status =3D IW_CM_EVENT_STATUS_OK; cm_event.provider_data =3D cm_id->provider_data; -@@ -3439,7 +3439,7 @@ static void cm_event_mpa_req(struct nes_ +@@ -3439,7 +3439,7 @@ static void cm_event_mpa_req(struct nes_cm_event *= event) return; cm_id =3D cm_node->cm_id; =20 @@ -33396,7 +34988,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_cm.c linux-2.6.32.49/dr nes_debug(NES_DBG_CM, "cm_node =3D %p - cm_id =3D %p, jiffies =3D %lu\= n", cm_node, cm_id, jiffies); =20 -@@ -3477,7 +3477,7 @@ static void cm_event_mpa_reject(struct n +@@ -3477,7 +3477,7 @@ static void cm_event_mpa_reject(struct nes_cm_even= t *event) return; cm_id =3D cm_node->cm_id; =20 @@ -33405,59 +34997,11 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/h= w/nes/nes_cm.c linux-2.6.32.49/dr nes_debug(NES_DBG_CM, "cm_node =3D %p - cm_id =3D %p, jiffies =3D %lu\= n", cm_node, cm_id, jiffies); =20 -diff -urNp linux-2.6.32.49/drivers/infiniband/hw/nes/nes.h linux-2.6.32.= 49/drivers/infiniband/hw/nes/nes.h ---- linux-2.6.32.49/drivers/infiniband/hw/nes/nes.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/hw/nes/nes.h 2011-11-15 19:59:43.= 000000000 -0500 -@@ -174,17 +174,17 @@ extern unsigned int nes_debug_level; - extern unsigned int wqm_quanta; - extern struct list_head nes_adapter_list; -=20 --extern atomic_t cm_connects; --extern atomic_t cm_accepts; --extern atomic_t cm_disconnects; --extern atomic_t cm_closes; --extern atomic_t cm_connecteds; --extern atomic_t cm_connect_reqs; --extern atomic_t cm_rejects; --extern atomic_t mod_qp_timouts; --extern atomic_t qps_created; --extern atomic_t qps_destroyed; --extern atomic_t sw_qps_destroyed; -+extern atomic_unchecked_t cm_connects; -+extern atomic_unchecked_t cm_accepts; -+extern atomic_unchecked_t cm_disconnects; -+extern atomic_unchecked_t cm_closes; -+extern atomic_unchecked_t cm_connecteds; -+extern atomic_unchecked_t cm_connect_reqs; -+extern atomic_unchecked_t cm_rejects; -+extern atomic_unchecked_t mod_qp_timouts; -+extern atomic_unchecked_t qps_created; -+extern atomic_unchecked_t qps_destroyed; -+extern atomic_unchecked_t sw_qps_destroyed; - extern u32 mh_detected; - extern u32 mh_pauses_sent; - extern u32 cm_packets_sent; -@@ -196,11 +196,11 @@ extern u32 cm_packets_retrans; - extern u32 cm_listens_created; - extern u32 cm_listens_destroyed; - extern u32 cm_backlog_drops; --extern atomic_t cm_loopbacks; --extern atomic_t cm_nodes_created; --extern atomic_t cm_nodes_destroyed; --extern atomic_t cm_accel_dropped_pkts; --extern atomic_t cm_resets_recvd; -+extern atomic_unchecked_t cm_loopbacks; -+extern atomic_unchecked_t cm_nodes_created; -+extern atomic_unchecked_t cm_nodes_destroyed; -+extern atomic_unchecked_t cm_accel_dropped_pkts; -+extern atomic_unchecked_t cm_resets_recvd; -=20 - extern u32 int_mod_timer_init; - extern u32 int_mod_cq_depth_256; -diff -urNp linux-2.6.32.49/drivers/infiniband/hw/nes/nes_nic.c linux-2.6= .32.49/drivers/infiniband/hw/nes/nes_nic.c ---- linux-2.6.32.49/drivers/infiniband/hw/nes/nes_nic.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/hw/nes/nes_nic.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -1210,17 +1210,17 @@ static void nes_netdev_get_ethtool_stats +diff --git a/drivers/infiniband/hw/nes/nes_nic.c b/drivers/infiniband/hw= /nes/nes_nic.c +index e593af3..870694a 100644 +--- a/drivers/infiniband/hw/nes/nes_nic.c ++++ b/drivers/infiniband/hw/nes/nes_nic.c +@@ -1210,17 +1210,17 @@ static void nes_netdev_get_ethtool_stats(struct = net_device *netdev, target_stat_values[++index] =3D mh_detected; target_stat_values[++index] =3D mh_pauses_sent; target_stat_values[++index] =3D nesvnic->endnode_ipv4_tcp_retransmits; @@ -33486,7 +35030,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_nic.c linux-2.6.32.49/d target_stat_values[++index] =3D cm_packets_sent; target_stat_values[++index] =3D cm_packets_bounced; target_stat_values[++index] =3D cm_packets_created; -@@ -1230,11 +1230,11 @@ static void nes_netdev_get_ethtool_stats +@@ -1230,11 +1230,11 @@ static void nes_netdev_get_ethtool_stats(struct = net_device *netdev, target_stat_values[++index] =3D cm_listens_created; target_stat_values[++index] =3D cm_listens_destroyed; target_stat_values[++index] =3D cm_backlog_drops; @@ -33503,9 +35047,10 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw= /nes/nes_nic.c linux-2.6.32.49/d target_stat_values[++index] =3D int_mod_timer_init; target_stat_values[++index] =3D int_mod_cq_depth_1; target_stat_values[++index] =3D int_mod_cq_depth_4; -diff -urNp linux-2.6.32.49/drivers/infiniband/hw/nes/nes_verbs.c linux-2= .6.32.49/drivers/infiniband/hw/nes/nes_verbs.c ---- linux-2.6.32.49/drivers/infiniband/hw/nes/nes_verbs.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/infiniband/hw/nes/nes_verbs.c 2011-11-15 19:= 59:43.000000000 -0500 +diff --git a/drivers/infiniband/hw/nes/nes_verbs.c b/drivers/infiniband/= hw/nes/nes_verbs.c +index a680c42..f914deb 100644 +--- a/drivers/infiniband/hw/nes/nes_verbs.c ++++ b/drivers/infiniband/hw/nes/nes_verbs.c @@ -45,9 +45,9 @@ =20 #include @@ -33519,7 +35064,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_verbs.c linux-2.6.32.49 =20 static void nes_unregister_ofa_device(struct nes_ib_device *nesibdev); =20 -@@ -1240,7 +1240,7 @@ static struct ib_qp *nes_create_qp(struc +@@ -1240,7 +1240,7 @@ static struct ib_qp *nes_create_qp(struct ib_pd *i= bpd, if (init_attr->create_flags) return ERR_PTR(-EINVAL); =20 @@ -33528,7 +35073,7 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw/= nes/nes_verbs.c linux-2.6.32.49 switch (init_attr->qp_type) { case IB_QPT_RC: if (nes_drv_opt & NES_DRV_OPT_NO_INLINE_DATA) { -@@ -1568,7 +1568,7 @@ static int nes_destroy_qp(struct ib_qp * +@@ -1568,7 +1568,7 @@ static int nes_destroy_qp(struct ib_qp *ibqp) struct iw_cm_event cm_event; int ret; =20 @@ -33537,9 +35082,10 @@ diff -urNp linux-2.6.32.49/drivers/infiniband/hw= /nes/nes_verbs.c linux-2.6.32.49 nesqp->destroyed =3D 1; =20 /* Blow away the connection if it exists. */ -diff -urNp linux-2.6.32.49/drivers/input/gameport/gameport.c linux-2.6.3= 2.49/drivers/input/gameport/gameport.c ---- linux-2.6.32.49/drivers/input/gameport/gameport.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/input/gameport/gameport.c 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/drivers/input/gameport/gameport.c b/drivers/input/gameport/= gameport.c +index ac11be0..3883c04 100644 +--- a/drivers/input/gameport/gameport.c ++++ b/drivers/input/gameport/gameport.c @@ -515,13 +515,13 @@ EXPORT_SYMBOL(gameport_set_phys); */ static void gameport_init_port(struct gameport *gameport) @@ -33556,9 +35102,10 @@ diff -urNp linux-2.6.32.49/drivers/input/gamepor= t/gameport.c linux-2.6.32.49/dri gameport->dev.bus =3D &gameport_bus; gameport->dev.release =3D gameport_release_port; if (gameport->parent) -diff -urNp linux-2.6.32.49/drivers/input/input.c linux-2.6.32.49/drivers= /input/input.c ---- linux-2.6.32.49/drivers/input/input.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/input/input.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/input/input.c b/drivers/input/input.c +index c82ae82..8cfb9cb 100644 +--- a/drivers/input/input.c ++++ b/drivers/input/input.c @@ -1558,7 +1558,7 @@ EXPORT_SYMBOL(input_set_capability); */ int input_register_device(struct input_dev *dev) @@ -33568,7 +35115,7 @@ diff -urNp linux-2.6.32.49/drivers/input/input.c = linux-2.6.32.49/drivers/input/i struct input_handler *handler; const char *path; int error; -@@ -1585,7 +1585,7 @@ int input_register_device(struct input_d +@@ -1585,7 +1585,7 @@ int input_register_device(struct input_dev *dev) dev->setkeycode =3D input_default_setkeycode; =20 dev_set_name(&dev->dev, "input%ld", @@ -33577,9 +35124,10 @@ diff -urNp linux-2.6.32.49/drivers/input/input.c= linux-2.6.32.49/drivers/input/i =20 error =3D device_add(&dev->dev); if (error) -diff -urNp linux-2.6.32.49/drivers/input/joystick/sidewinder.c linux-2.6= .32.49/drivers/input/joystick/sidewinder.c ---- linux-2.6.32.49/drivers/input/joystick/sidewinder.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/input/joystick/sidewinder.c 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/drivers/input/joystick/sidewinder.c b/drivers/input/joystic= k/sidewinder.c +index ca13a6b..b032b0c 100644 +--- a/drivers/input/joystick/sidewinder.c ++++ b/drivers/input/joystick/sidewinder.c @@ -30,6 +30,7 @@ #include #include @@ -33597,10 +35145,11 @@ diff -urNp linux-2.6.32.49/drivers/input/joysti= ck/sidewinder.c linux-2.6.32.49/d i =3D sw_read_packet(sw->gameport, buf, sw->length, 0); =20 if (sw->type =3D=3D SW_ID_3DP && sw->length =3D=3D 66 && i !=3D 66) { = /* Broken packet, try to fix */ -diff -urNp linux-2.6.32.49/drivers/input/joystick/xpad.c linux-2.6.32.49= /drivers/input/joystick/xpad.c ---- linux-2.6.32.49/drivers/input/joystick/xpad.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/input/joystick/xpad.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -621,7 +621,7 @@ static void xpad_led_set(struct led_clas +diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad= .c +index 79e3edc..01412b9 100644 +--- a/drivers/input/joystick/xpad.c ++++ b/drivers/input/joystick/xpad.c +@@ -621,7 +621,7 @@ static void xpad_led_set(struct led_classdev *led_cd= ev, =20 static int xpad_led_probe(struct usb_xpad *xpad) { @@ -33609,7 +35158,7 @@ diff -urNp linux-2.6.32.49/drivers/input/joystick= /xpad.c linux-2.6.32.49/drivers long led_no; struct xpad_led *led; struct led_classdev *led_cdev; -@@ -634,7 +634,7 @@ static int xpad_led_probe(struct usb_xpa +@@ -634,7 +634,7 @@ static int xpad_led_probe(struct usb_xpad *xpad) if (!led) return -ENOMEM; =20 @@ -33618,10 +35167,11 @@ diff -urNp linux-2.6.32.49/drivers/input/joysti= ck/xpad.c linux-2.6.32.49/drivers =20 snprintf(led->name, sizeof(led->name), "xpad%ld", led_no); led->xpad =3D xpad; -diff -urNp linux-2.6.32.49/drivers/input/serio/serio.c linux-2.6.32.49/d= rivers/input/serio/serio.c ---- linux-2.6.32.49/drivers/input/serio/serio.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/input/serio/serio.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -527,7 +527,7 @@ static void serio_release_port(struct de +diff --git a/drivers/input/serio/serio.c b/drivers/input/serio/serio.c +index 0236f0d..c7327f1 100644 +--- a/drivers/input/serio/serio.c ++++ b/drivers/input/serio/serio.c +@@ -527,7 +527,7 @@ static void serio_release_port(struct device *dev) */ static void serio_init_port(struct serio *serio) { @@ -33630,7 +35180,7 @@ diff -urNp linux-2.6.32.49/drivers/input/serio/se= rio.c linux-2.6.32.49/drivers/i =20 __module_get(THIS_MODULE); =20 -@@ -536,7 +536,7 @@ static void serio_init_port(struct serio +@@ -536,7 +536,7 @@ static void serio_init_port(struct serio *serio) mutex_init(&serio->drv_mutex); device_initialize(&serio->dev); dev_set_name(&serio->dev, "serio%ld", @@ -33639,10 +35189,11 @@ diff -urNp linux-2.6.32.49/drivers/input/serio/= serio.c linux-2.6.32.49/drivers/i serio->dev.bus =3D &serio_bus; serio->dev.release =3D serio_release_port; if (serio->parent) { -diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/common.c linux-2.6.32.49= /drivers/isdn/gigaset/common.c ---- linux-2.6.32.49/drivers/isdn/gigaset/common.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/gigaset/common.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -712,7 +712,7 @@ struct cardstate *gigaset_initcs(struct=20 +diff --git a/drivers/isdn/gigaset/common.c b/drivers/isdn/gigaset/common= .c +index 33dcd8d..2783d25 100644 +--- a/drivers/isdn/gigaset/common.c ++++ b/drivers/isdn/gigaset/common.c +@@ -712,7 +712,7 @@ struct cardstate *gigaset_initcs(struct gigaset_driv= er *drv, int channels, cs->commands_pending =3D 0; cs->cur_at_seq =3D 0; cs->gotfwver =3D -1; @@ -33651,9 +35202,10 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/= common.c linux-2.6.32.49/drivers cs->dev =3D NULL; cs->tty =3D NULL; cs->tty_dev =3D NULL; -diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/gigaset.h linux-2.6.32.4= 9/drivers/isdn/gigaset/gigaset.h ---- linux-2.6.32.49/drivers/isdn/gigaset/gigaset.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/gigaset/gigaset.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/isdn/gigaset/gigaset.h b/drivers/isdn/gigaset/gigas= et.h +index a2f6125..6a70677 100644 +--- a/drivers/isdn/gigaset/gigaset.h ++++ b/drivers/isdn/gigaset/gigaset.h @@ -34,6 +34,7 @@ #include #include @@ -33671,10 +35223,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset= /gigaset.h linux-2.6.32.49/driver struct tty_struct *tty; struct tasklet_struct if_wake_tasklet; unsigned control_state; -diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/interface.c linux-2.6.32= .49/drivers/isdn/gigaset/interface.c ---- linux-2.6.32.49/drivers/isdn/gigaset/interface.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/gigaset/interface.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -165,9 +165,7 @@ static int if_open(struct tty_struct *tt +diff --git a/drivers/isdn/gigaset/interface.c b/drivers/isdn/gigaset/int= erface.c +index b3065b8..c7e8cc9 100644 +--- a/drivers/isdn/gigaset/interface.c ++++ b/drivers/isdn/gigaset/interface.c +@@ -165,9 +165,7 @@ static int if_open(struct tty_struct *tty, struct fi= le *filp) return -ERESTARTSYS; // FIXME -EINTR? tty->driver_data =3D cs; =20 @@ -33685,7 +35238,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv spin_lock_irqsave(&cs->lock, flags); cs->tty =3D tty; spin_unlock_irqrestore(&cs->lock, flags); -@@ -195,10 +193,10 @@ static void if_close(struct tty_struct * +@@ -195,10 +193,10 @@ static void if_close(struct tty_struct *tty, struc= t file *filp) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -33698,7 +35251,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv spin_lock_irqsave(&cs->lock, flags); cs->tty =3D NULL; spin_unlock_irqrestore(&cs->lock, flags); -@@ -233,7 +231,7 @@ static int if_ioctl(struct tty_struct *t +@@ -233,7 +231,7 @@ static int if_ioctl(struct tty_struct *tty, struct f= ile *file, if (!cs->connected) { gig_dbg(DEBUG_IF, "not connected"); retval =3D -ENODEV; @@ -33707,7 +35260,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv dev_warn(cs->dev, "%s: device not opened\n", __func__); else { retval =3D 0; -@@ -361,7 +359,7 @@ static int if_write(struct tty_struct *t +@@ -361,7 +359,7 @@ static int if_write(struct tty_struct *tty, const un= signed char *buf, int count) if (!cs->connected) { gig_dbg(DEBUG_IF, "not connected"); retval =3D -ENODEV; @@ -33716,7 +35269,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv dev_warn(cs->dev, "%s: device not opened\n", __func__); else if (cs->mstate !=3D MS_LOCKED) { dev_warn(cs->dev, "can't write to unlocked device\n"); -@@ -395,7 +393,7 @@ static int if_write_room(struct tty_stru +@@ -395,7 +393,7 @@ static int if_write_room(struct tty_struct *tty) if (!cs->connected) { gig_dbg(DEBUG_IF, "not connected"); retval =3D -ENODEV; @@ -33725,7 +35278,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv dev_warn(cs->dev, "%s: device not opened\n", __func__); else if (cs->mstate !=3D MS_LOCKED) { dev_warn(cs->dev, "can't write to unlocked device\n"); -@@ -425,7 +423,7 @@ static int if_chars_in_buffer(struct tty +@@ -425,7 +423,7 @@ static int if_chars_in_buffer(struct tty_struct *tty= ) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); @@ -33734,7 +35287,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv dev_warn(cs->dev, "%s: device not opened\n", __func__); else if (cs->mstate !=3D MS_LOCKED) dev_warn(cs->dev, "can't write to unlocked device\n"); -@@ -453,7 +451,7 @@ static void if_throttle(struct tty_struc +@@ -453,7 +451,7 @@ static void if_throttle(struct tty_struct *tty) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -33743,7 +35296,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv dev_warn(cs->dev, "%s: device not opened\n", __func__); else { //FIXME -@@ -478,7 +476,7 @@ static void if_unthrottle(struct tty_str +@@ -478,7 +476,7 @@ static void if_unthrottle(struct tty_struct *tty) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -33752,7 +35305,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset/i= nterface.c linux-2.6.32.49/driv dev_warn(cs->dev, "%s: device not opened\n", __func__); else { //FIXME -@@ -510,7 +508,7 @@ static void if_set_termios(struct tty_st +@@ -510,7 +508,7 @@ static void if_set_termios(struct tty_struct *tty, s= truct ktermios *old) goto out; } =20 @@ -33761,10 +35314,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/gigaset= /interface.c linux-2.6.32.49/driv dev_warn(cs->dev, "%s: device not opened\n", __func__); goto out; } -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/avm/b1.c linux-2.6.32.4= 9/drivers/isdn/hardware/avm/b1.c ---- linux-2.6.32.49/drivers/isdn/hardware/avm/b1.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/avm/b1.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -173,7 +173,7 @@ int b1_load_t4file(avmcard *card, capilo +diff --git a/drivers/isdn/hardware/avm/b1.c b/drivers/isdn/hardware/avm/= b1.c +index a7c0083..62a7cb6 100644 +--- a/drivers/isdn/hardware/avm/b1.c ++++ b/drivers/isdn/hardware/avm/b1.c +@@ -173,7 +173,7 @@ int b1_load_t4file(avmcard *card, capiloaddatapart *= t4file) } if (left) { if (t4file->user) { @@ -33773,7 +35327,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware/= avm/b1.c linux-2.6.32.49/driver return -EFAULT; } else { memcpy(buf, dp, left); -@@ -221,7 +221,7 @@ int b1_load_config(avmcard *card, capilo +@@ -221,7 +221,7 @@ int b1_load_config(avmcard *card, capiloaddatapart *= config) } if (left) { if (config->user) { @@ -33782,10 +35336,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardwar= e/avm/b1.c linux-2.6.32.49/driver return -EFAULT; } else { memcpy(buf, dp, left); -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/capidtmf.c linux-= 2.6.32.49/drivers/isdn/hardware/eicon/capidtmf.c ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/capidtmf.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/capidtmf.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -498,6 +498,7 @@ void capidtmf_recv_block (t_capidtmf_sta +diff --git a/drivers/isdn/hardware/eicon/capidtmf.c b/drivers/isdn/hardw= are/eicon/capidtmf.c +index f130724..c373c68 100644 +--- a/drivers/isdn/hardware/eicon/capidtmf.c ++++ b/drivers/isdn/hardware/eicon/capidtmf.c +@@ -498,6 +498,7 @@ void capidtmf_recv_block (t_capidtmf_state *p_stat= e, byte *buffer, word leng byte goertzel_result_buffer[CAPIDTMF_RECV_TOTAL_FREQUENCY_COUNT]; short windowed_sample_buffer[CAPIDTMF_RECV_WINDOWED_SAMPLES]; =20 @@ -33793,9 +35348,10 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware= /eicon/capidtmf.c linux-2.6.32.4 =20 if (p_state->recv.state & CAPIDTMF_RECV_STATE_DTMF_ACTIVE) { -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/capifunc.c linux-= 2.6.32.49/drivers/isdn/hardware/eicon/capifunc.c ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/capifunc.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/capifunc.c 2011-11-15 19= :59:43.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/capifunc.c b/drivers/isdn/hardw= are/eicon/capifunc.c +index 4d425c6..a9be6c4 100644 +--- a/drivers/isdn/hardware/eicon/capifunc.c ++++ b/drivers/isdn/hardware/eicon/capifunc.c @@ -1055,6 +1055,8 @@ static int divacapi_connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; @@ -33805,10 +35361,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardwar= e/eicon/capifunc.c linux-2.6.32.4 DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/diddfunc.c linux-= 2.6.32.49/drivers/isdn/hardware/eicon/diddfunc.c ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/diddfunc.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/diddfunc.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -54,6 +54,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/diddfunc.c b/drivers/isdn/hardw= are/eicon/diddfunc.c +index 3029234..ef0d9e2 100644 +--- a/drivers/isdn/hardware/eicon/diddfunc.c ++++ b/drivers/isdn/hardware/eicon/diddfunc.c +@@ -54,6 +54,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -33817,10 +35374,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardwar= e/eicon/diddfunc.c linux-2.6.32.4 DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/divasfunc.c linux= -2.6.32.49/drivers/isdn/hardware/eicon/divasfunc.c ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/divasfunc.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/divasfunc.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -161,6 +161,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/divasfunc.c b/drivers/isdn/hard= ware/eicon/divasfunc.c +index d36a4c0..11e7d1a 100644 +--- a/drivers/isdn/hardware/eicon/divasfunc.c ++++ b/drivers/isdn/hardware/eicon/divasfunc.c +@@ -161,6 +161,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -33829,9 +35387,10 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware= /eicon/divasfunc.c linux-2.6.32. DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/divasync.h linux-= 2.6.32.49/drivers/isdn/hardware/eicon/divasync.h ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/divasync.h 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/divasync.h 2011-11-15 19= :59:43.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/divasync.h b/drivers/isdn/hardw= are/eicon/divasync.h +index 85784a7..a19ca98 100644 +--- a/drivers/isdn/hardware/eicon/divasync.h ++++ b/drivers/isdn/hardware/eicon/divasync.h @@ -146,7 +146,7 @@ typedef struct _diva_didd_add_adapter { } diva_didd_add_adapter_t; typedef struct _diva_didd_remove_adapter { @@ -33841,10 +35400,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardwar= e/eicon/divasync.h linux-2.6.32.4 typedef struct _diva_didd_read_adapter_array { void * buffer; dword length; -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/idifunc.c linux-2= .6.32.49/drivers/isdn/hardware/eicon/idifunc.c ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/idifunc.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/idifunc.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -188,6 +188,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/idifunc.c b/drivers/isdn/hardwa= re/eicon/idifunc.c +index db87d51..7d09acf 100644 +--- a/drivers/isdn/hardware/eicon/idifunc.c ++++ b/drivers/isdn/hardware/eicon/idifunc.c +@@ -188,6 +188,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -33853,9 +35413,10 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware= /eicon/idifunc.c linux-2.6.32.49 DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/message.c linux-2= .6.32.49/drivers/isdn/hardware/eicon/message.c ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/message.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/message.c 2011-11-15 19:= 59:43.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/message.c b/drivers/isdn/hardwa= re/eicon/message.c +index ae89fb8..0fab299 100644 +--- a/drivers/isdn/hardware/eicon/message.c ++++ b/drivers/isdn/hardware/eicon/message.c @@ -4889,6 +4889,8 @@ static void sig_ind(PLCI *plci) dword d; word w; @@ -33865,7 +35426,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware/= eicon/message.c linux-2.6.32.49 a =3D plci->adapter; Id =3D ((word)plci->Id<<8)|a->Id; PUT_WORD(&SS_Ind[4],0x0000); -@@ -7484,6 +7486,8 @@ static word add_b1(PLCI *plci, API_PARSE +@@ -7484,6 +7486,8 @@ static word add_b1(PLCI *plci, API_PARSE *bp, word= b_channel_info, word j, n, w; dword d; =20 @@ -33874,7 +35435,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware/= eicon/message.c linux-2.6.32.49 =20 for(i=3D0;i<8;i++) bp_parms[i].length =3D 0; for(i=3D0;i<2;i++) global_config[i].length =3D 0; -@@ -7958,6 +7962,8 @@ static word add_b23(PLCI *plci, API_PARS +@@ -7958,6 +7962,8 @@ static word add_b23(PLCI *plci, API_PARSE *bp) const byte llc3[] =3D {4,3,2,2,6,6,0}; const byte header[] =3D {0,2,3,3,0,0,0}; =20 @@ -33883,7 +35444,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware/= eicon/message.c linux-2.6.32.49 for(i=3D0;i<8;i++) bp_parms[i].length =3D 0; for(i=3D0;i<6;i++) b2_config_parms[i].length =3D 0; for(i=3D0;i<5;i++) b3_config_parms[i].length =3D 0; -@@ -14761,6 +14767,8 @@ static void group_optimization(DIVA_CAPI +@@ -14761,6 +14767,8 @@ static void group_optimization(DIVA_CAPI_ADAPTER= * a, PLCI * plci) word appl_number_group_type[MAX_APPL]; PLCI *auxplci; =20 @@ -33892,10 +35453,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardwar= e/eicon/message.c linux-2.6.32.49 set_group_ind_mask (plci); /* all APPLs within this inc. call are all= owed to dial in */ =20 if(!a->group_optimization_enabled) -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/mntfunc.c linux-2= .6.32.49/drivers/isdn/hardware/eicon/mntfunc.c ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/mntfunc.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/mntfunc.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -79,6 +79,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/mntfunc.c b/drivers/isdn/hardwa= re/eicon/mntfunc.c +index a564b75..f3cf8b5 100644 +--- a/drivers/isdn/hardware/eicon/mntfunc.c ++++ b/drivers/isdn/hardware/eicon/mntfunc.c +@@ -79,6 +79,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -33904,9 +35466,10 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardware= /eicon/mntfunc.c linux-2.6.32.49 DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-2.6.32.49/drivers/isdn/hardware/eicon/xdi_adapter.h lin= ux-2.6.32.49/drivers/isdn/hardware/eicon/xdi_adapter.h ---- linux-2.6.32.49/drivers/isdn/hardware/eicon/xdi_adapter.h 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/hardware/eicon/xdi_adapter.h 2011-11-15= 19:59:43.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/xdi_adapter.h b/drivers/isdn/ha= rdware/eicon/xdi_adapter.h +index a3bd163..8956575 100644 +--- a/drivers/isdn/hardware/eicon/xdi_adapter.h ++++ b/drivers/isdn/hardware/eicon/xdi_adapter.h @@ -44,7 +44,7 @@ typedef struct _xdi_mbox_t { typedef struct _diva_os_idi_adapter_interface { diva_init_card_proc_t cleanup_adapter_proc; @@ -33916,10 +35479,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/hardwar= e/eicon/xdi_adapter.h linux-2.6.3 =20 typedef struct _diva_os_xdi_adapter { struct list_head link; -diff -urNp linux-2.6.32.49/drivers/isdn/i4l/isdn_common.c linux-2.6.32.4= 9/drivers/isdn/i4l/isdn_common.c ---- linux-2.6.32.49/drivers/isdn/i4l/isdn_common.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/isdn/i4l/isdn_common.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -1290,6 +1290,8 @@ isdn_ioctl(struct inode *inode, struct f +diff --git a/drivers/isdn/i4l/isdn_common.c b/drivers/isdn/i4l/isdn_comm= on.c +index adb1e8c..21b590b 100644 +--- a/drivers/isdn/i4l/isdn_common.c ++++ b/drivers/isdn/i4l/isdn_common.c +@@ -1290,6 +1290,8 @@ isdn_ioctl(struct inode *inode, struct file *file,= uint cmd, ulong arg) } iocpar; void __user *argp =3D (void __user *)arg; =20 @@ -33928,10 +35492,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/i4l/isd= n_common.c linux-2.6.32.49/driver #define name iocpar.name #define bname iocpar.bname #define iocts iocpar.iocts -diff -urNp linux-2.6.32.49/drivers/isdn/icn/icn.c linux-2.6.32.49/driver= s/isdn/icn/icn.c ---- linux-2.6.32.49/drivers/isdn/icn/icn.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/isdn/icn/icn.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1044,7 +1044,7 @@ icn_writecmd(const u_char * buf, int len +diff --git a/drivers/isdn/icn/icn.c b/drivers/isdn/icn/icn.c +index bf7997a..cf091db 100644 +--- a/drivers/isdn/icn/icn.c ++++ b/drivers/isdn/icn/icn.c +@@ -1044,7 +1044,7 @@ icn_writecmd(const u_char * buf, int len, int user= , icn_card * card) if (count > len) count =3D len; if (user) { @@ -33940,10 +35505,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/icn/icn= .c linux-2.6.32.49/drivers/isdn/i return -EFAULT; } else memcpy(msg, buf, count); -diff -urNp linux-2.6.32.49/drivers/isdn/mISDN/socket.c linux-2.6.32.49/d= rivers/isdn/mISDN/socket.c ---- linux-2.6.32.49/drivers/isdn/mISDN/socket.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/isdn/mISDN/socket.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -391,6 +391,7 @@ data_sock_ioctl(struct socket *sock, uns +diff --git a/drivers/isdn/mISDN/socket.c b/drivers/isdn/mISDN/socket.c +index feb0fa4..f76f830 100644 +--- a/drivers/isdn/mISDN/socket.c ++++ b/drivers/isdn/mISDN/socket.c +@@ -391,6 +391,7 @@ data_sock_ioctl(struct socket *sock, unsigned int cm= d, unsigned long arg) if (dev) { struct mISDN_devinfo di; =20 @@ -33951,7 +35517,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/mISDN/soc= ket.c linux-2.6.32.49/drivers/i di.id =3D dev->id; di.Dprotocols =3D dev->Dprotocols; di.Bprotocols =3D dev->Bprotocols | get_all_Bprotocols(); -@@ -671,6 +672,7 @@ base_sock_ioctl(struct socket *sock, uns +@@ -671,6 +672,7 @@ base_sock_ioctl(struct socket *sock, unsigned int cm= d, unsigned long arg) if (dev) { struct mISDN_devinfo di; =20 @@ -33959,10 +35525,11 @@ diff -urNp linux-2.6.32.49/drivers/isdn/mISDN/s= ocket.c linux-2.6.32.49/drivers/i di.id =3D dev->id; di.Dprotocols =3D dev->Dprotocols; di.Bprotocols =3D dev->Bprotocols | get_all_Bprotocols(); -diff -urNp linux-2.6.32.49/drivers/isdn/sc/interrupt.c linux-2.6.32.49/d= rivers/isdn/sc/interrupt.c ---- linux-2.6.32.49/drivers/isdn/sc/interrupt.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/isdn/sc/interrupt.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -112,11 +112,19 @@ irqreturn_t interrupt_handler(int dummy, +diff --git a/drivers/isdn/sc/interrupt.c b/drivers/isdn/sc/interrupt.c +index 485be8b..f0225bc 100644 +--- a/drivers/isdn/sc/interrupt.c ++++ b/drivers/isdn/sc/interrupt.c +@@ -112,11 +112,19 @@ irqreturn_t interrupt_handler(int dummy, void *car= d_inst) } else if(callid>=3D0x0000 && callid<=3D0x7FFF) { @@ -33985,7 +35552,7 @@ diff -urNp linux-2.6.32.49/drivers/isdn/sc/interr= upt.c linux-2.6.32.49/drivers/i setup.si1 =3D 7; setup.si2 =3D 0; setup.plan =3D 0; -@@ -176,7 +184,9 @@ irqreturn_t interrupt_handler(int dummy, +@@ -176,7 +184,9 @@ irqreturn_t interrupt_handler(int dummy, void *card_= inst) * Handle a GetMyNumber Rsp */ if (IS_CE_MESSAGE(rcvmsg,Call,0,GetMyNumber)){ @@ -33996,9 +35563,10 @@ diff -urNp linux-2.6.32.49/drivers/isdn/sc/inter= rupt.c linux-2.6.32.49/drivers/i continue; } =09 -diff -urNp linux-2.6.32.49/drivers/lguest/core.c linux-2.6.32.49/drivers= /lguest/core.c ---- linux-2.6.32.49/drivers/lguest/core.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/lguest/core.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/lguest/core.c b/drivers/lguest/core.c +index 8744d24..d1f9a9a 100644 +--- a/drivers/lguest/core.c ++++ b/drivers/lguest/core.c @@ -91,9 +91,17 @@ static __init int map_switcher(void) * it's worked so far. The end address needs +1 because __get_vm_area * allocates an extra guard page, so we need space for that. @@ -34026,9 +35594,10 @@ diff -urNp linux-2.6.32.49/drivers/lguest/core.c= linux-2.6.32.49/drivers/lguest/ end_switcher_text - start_switcher_text); =20 printk(KERN_INFO "lguest: mapped switcher at %p\n", -diff -urNp linux-2.6.32.49/drivers/lguest/x86/core.c linux-2.6.32.49/dri= vers/lguest/x86/core.c ---- linux-2.6.32.49/drivers/lguest/x86/core.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/lguest/x86/core.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/lguest/x86/core.c b/drivers/lguest/x86/core.c +index 6ae3888..8b38145 100644 +--- a/drivers/lguest/x86/core.c ++++ b/drivers/lguest/x86/core.c @@ -59,7 +59,7 @@ static struct { /* Offset from where switcher.S was compiled to where we've copied it *= / static unsigned long switcher_offset(void) @@ -34038,7 +35607,7 @@ diff -urNp linux-2.6.32.49/drivers/lguest/x86/cor= e.c linux-2.6.32.49/drivers/lgu } =20 /* This cpu's struct lguest_pages. */ -@@ -100,7 +100,13 @@ static void copy_in_guest_info(struct lg +@@ -100,7 +100,13 @@ static void copy_in_guest_info(struct lg_cpu *cpu, = struct lguest_pages *pages) * These copies are pretty cheap, so we do them unconditionally: */ /* Save the current Host top-level page directory. */ @@ -34070,9 +35639,10 @@ diff -urNp linux-2.6.32.49/drivers/lguest/x86/co= re.c linux-2.6.32.49/drivers/lgu lguest_entry.segment =3D LGUEST_CS; =20 /* -diff -urNp linux-2.6.32.49/drivers/lguest/x86/switcher_32.S linux-2.6.32= .49/drivers/lguest/x86/switcher_32.S ---- linux-2.6.32.49/drivers/lguest/x86/switcher_32.S 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/lguest/x86/switcher_32.S 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/lguest/x86/switcher_32.S b/drivers/lguest/x86/switc= her_32.S +index 40634b0..4f5855e 100644 +--- a/drivers/lguest/x86/switcher_32.S ++++ b/drivers/lguest/x86/switcher_32.S @@ -87,6 +87,7 @@ #include #include @@ -34131,10 +35701,11 @@ diff -urNp linux-2.6.32.49/drivers/lguest/x86/s= witcher_32.S linux-2.6.32.49/driv =20 // Every interrupt can come to us here // But we must truly tell each apart. -diff -urNp linux-2.6.32.49/drivers/macintosh/macio_asic.c linux-2.6.32.4= 9/drivers/macintosh/macio_asic.c ---- linux-2.6.32.49/drivers/macintosh/macio_asic.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/macintosh/macio_asic.c 2011-11-18 18:01:55.0= 00000000 -0500 -@@ -701,7 +701,7 @@ static void __devexit macio_pci_remove(s +diff --git a/drivers/macintosh/macio_asic.c b/drivers/macintosh/macio_as= ic.c +index 588a5b0..b71db89 100644 +--- a/drivers/macintosh/macio_asic.c ++++ b/drivers/macintosh/macio_asic.c +@@ -701,7 +701,7 @@ static void __devexit macio_pci_remove(struct pci_de= v* pdev) * MacIO is matched against any Apple ID, it's probe() function * will then decide wether it applies or not */ @@ -34143,9 +35714,10 @@ diff -urNp linux-2.6.32.49/drivers/macintosh/mac= io_asic.c linux-2.6.32.49/driver .vendor =3D PCI_VENDOR_ID_APPLE, .device =3D PCI_ANY_ID, .subvendor =3D PCI_ANY_ID, -diff -urNp linux-2.6.32.49/drivers/macintosh/via-pmu-backlight.c linux-2= .6.32.49/drivers/macintosh/via-pmu-backlight.c ---- linux-2.6.32.49/drivers/macintosh/via-pmu-backlight.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/macintosh/via-pmu-backlight.c 2011-11-15 19:= 59:43.000000000 -0500 +diff --git a/drivers/macintosh/via-pmu-backlight.c b/drivers/macintosh/v= ia-pmu-backlight.c +index a348bb0..ecd9b3f 100644 +--- a/drivers/macintosh/via-pmu-backlight.c ++++ b/drivers/macintosh/via-pmu-backlight.c @@ -15,7 +15,7 @@ =20 #define MAX_PMU_LEVEL 0xFF @@ -34155,7 +35727,7 @@ diff -urNp linux-2.6.32.49/drivers/macintosh/via-= pmu-backlight.c linux-2.6.32.49 static DEFINE_SPINLOCK(pmu_backlight_lock); static int sleeping, uses_pmu_bl; static u8 bl_curve[FB_BACKLIGHT_LEVELS]; -@@ -115,7 +115,7 @@ static int pmu_backlight_get_brightness( +@@ -115,7 +115,7 @@ static int pmu_backlight_get_brightness(struct backl= ight_device *bd) return bd->props.brightness; } =20 @@ -34164,10 +35736,11 @@ diff -urNp linux-2.6.32.49/drivers/macintosh/vi= a-pmu-backlight.c linux-2.6.32.49 .get_brightness =3D pmu_backlight_get_brightness, .update_status =3D pmu_backlight_update_status, =20 -diff -urNp linux-2.6.32.49/drivers/macintosh/via-pmu.c linux-2.6.32.49/d= rivers/macintosh/via-pmu.c ---- linux-2.6.32.49/drivers/macintosh/via-pmu.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/macintosh/via-pmu.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -2232,7 +2232,7 @@ static int pmu_sleep_valid(suspend_state +diff --git a/drivers/macintosh/via-pmu.c b/drivers/macintosh/via-pmu.c +index 6f308a4..b5f7ff7 100644 +--- a/drivers/macintosh/via-pmu.c ++++ b/drivers/macintosh/via-pmu.c +@@ -2232,7 +2232,7 @@ static int pmu_sleep_valid(suspend_state_t state) && (pmac_call_feature(PMAC_FTR_SLEEP_STATE, NULL, 0, -1) >=3D 0); } =20 @@ -34176,67 +35749,11 @@ diff -urNp linux-2.6.32.49/drivers/macintosh/vi= a-pmu.c linux-2.6.32.49/drivers/m .enter =3D powerbook_sleep, .valid =3D pmu_sleep_valid, }; -diff -urNp linux-2.6.32.49/drivers/md/dm.c linux-2.6.32.49/drivers/md/dm= .c ---- linux-2.6.32.49/drivers/md/dm.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/md/dm.c 2011-11-15 19:59:43.000000000 -0500 -@@ -165,9 +165,9 @@ struct mapped_device { - /* - * Event handling. - */ -- atomic_t event_nr; -+ atomic_unchecked_t event_nr; - wait_queue_head_t eventq; -- atomic_t uevent_seq; -+ atomic_unchecked_t uevent_seq; - struct list_head uevent_list; - spinlock_t uevent_lock; /* Protect access to uevent_list */ -=20 -@@ -1776,8 +1776,8 @@ static struct mapped_device *alloc_dev(i - rwlock_init(&md->map_lock); - atomic_set(&md->holders, 1); - atomic_set(&md->open_count, 0); -- atomic_set(&md->event_nr, 0); -- atomic_set(&md->uevent_seq, 0); -+ atomic_set_unchecked(&md->event_nr, 0); -+ atomic_set_unchecked(&md->uevent_seq, 0); - INIT_LIST_HEAD(&md->uevent_list); - spin_lock_init(&md->uevent_lock); -=20 -@@ -1927,7 +1927,7 @@ static void event_callback(void *context -=20 - dm_send_uevents(&uevents, &disk_to_dev(md->disk)->kobj); -=20 -- atomic_inc(&md->event_nr); -+ atomic_inc_unchecked(&md->event_nr); - wake_up(&md->eventq); - } -=20 -@@ -2562,18 +2562,18 @@ void dm_kobject_uevent(struct mapped_dev -=20 - uint32_t dm_next_uevent_seq(struct mapped_device *md) - { -- return atomic_add_return(1, &md->uevent_seq); -+ return atomic_add_return_unchecked(1, &md->uevent_seq); - } -=20 - uint32_t dm_get_event_nr(struct mapped_device *md) - { -- return atomic_read(&md->event_nr); -+ return atomic_read_unchecked(&md->event_nr); - } -=20 - int dm_wait_event(struct mapped_device *md, int event_nr) - { - return wait_event_interruptible(md->eventq, -- (event_nr !=3D atomic_read(&md->event_nr))); -+ (event_nr !=3D atomic_read_unchecked(&md->event_nr))); - } -=20 - void dm_uevent_add(struct mapped_device *md, struct list_head *elist) -diff -urNp linux-2.6.32.49/drivers/md/dm-ioctl.c linux-2.6.32.49/drivers= /md/dm-ioctl.c ---- linux-2.6.32.49/drivers/md/dm-ioctl.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/md/dm-ioctl.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1437,7 +1437,7 @@ static int validate_params(uint cmd, str +diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c +index 818b617..4656e38 100644 +--- a/drivers/md/dm-ioctl.c ++++ b/drivers/md/dm-ioctl.c +@@ -1437,7 +1437,7 @@ static int validate_params(uint cmd, struct dm_ioc= tl *param) cmd =3D=3D DM_LIST_VERSIONS_CMD) return 0; =20 @@ -34245,9 +35762,10 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-ioctl.c= linux-2.6.32.49/drivers/md/dm-i if (!*param->name) { DMWARN("name not supplied when creating device"); return -EINVAL; -diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c linux-2.6.32.49/drivers= /md/dm-raid1.c ---- linux-2.6.32.49/drivers/md/dm-raid1.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/md/dm-raid1.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/md/dm-raid1.c b/drivers/md/dm-raid1.c +index 6021d0a..a878643 100644 +--- a/drivers/md/dm-raid1.c ++++ b/drivers/md/dm-raid1.c @@ -41,7 +41,7 @@ enum dm_raid1_error { =20 struct mirror { @@ -34257,7 +35775,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c = linux-2.6.32.49/drivers/md/dm-r unsigned long error_type; struct dm_dev *dev; sector_t offset; -@@ -203,7 +203,7 @@ static void fail_mirror(struct mirror *m +@@ -203,7 +203,7 @@ static void fail_mirror(struct mirror *m, enum dm_ra= id1_error error_type) * simple way to tell if a device has encountered * errors. */ @@ -34266,7 +35784,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c = linux-2.6.32.49/drivers/md/dm-r =20 if (test_and_set_bit(error_type, &m->error_type)) return; -@@ -225,7 +225,7 @@ static void fail_mirror(struct mirror *m +@@ -225,7 +225,7 @@ static void fail_mirror(struct mirror *m, enum dm_ra= id1_error error_type) } =20 for (new =3D ms->mirror; new < ms->mirror + ms->nr_mirrors; new++) @@ -34275,7 +35793,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c = linux-2.6.32.49/drivers/md/dm-r set_default_mirror(new); break; } -@@ -363,7 +363,7 @@ static struct mirror *choose_mirror(stru +@@ -363,7 +363,7 @@ static struct mirror *choose_mirror(struct mirror_se= t *ms, sector_t sector) struct mirror *m =3D get_default_mirror(ms); =20 do { @@ -34293,7 +35811,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c = linux-2.6.32.49/drivers/md/dm-r } =20 static int mirror_available(struct mirror_set *ms, struct bio *bio) -@@ -484,7 +484,7 @@ static void do_reads(struct mirror_set * +@@ -484,7 +484,7 @@ static void do_reads(struct mirror_set *ms, struct b= io_list *reads) */ if (likely(region_in_sync(ms, region, 1))) m =3D choose_mirror(ms, bio->bi_sector); @@ -34302,7 +35820,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c = linux-2.6.32.49/drivers/md/dm-r m =3D NULL; =20 if (likely(m)) -@@ -855,7 +855,7 @@ static int get_mirror(struct mirror_set=20 +@@ -855,7 +855,7 @@ static int get_mirror(struct mirror_set *ms, struct = dm_target *ti, } =20 ms->mirror[mirror].ms =3D ms; @@ -34311,7 +35829,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c = linux-2.6.32.49/drivers/md/dm-r ms->mirror[mirror].error_type =3D 0; ms->mirror[mirror].offset =3D offset; =20 -@@ -1241,7 +1241,7 @@ static void mirror_resume(struct dm_targ +@@ -1241,7 +1241,7 @@ static void mirror_resume(struct dm_target *ti) */ static char device_status_char(struct mirror *m) { @@ -34320,9 +35838,10 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-raid1.c= linux-2.6.32.49/drivers/md/dm-r return 'A'; =20 return (test_bit(DM_RAID1_WRITE_ERROR, &(m->error_type))) ? 'D' : -diff -urNp linux-2.6.32.49/drivers/md/dm-stripe.c linux-2.6.32.49/driver= s/md/dm-stripe.c ---- linux-2.6.32.49/drivers/md/dm-stripe.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/md/dm-stripe.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/drivers/md/dm-stripe.c b/drivers/md/dm-stripe.c +index bd58703..9f26571 100644 +--- a/drivers/md/dm-stripe.c ++++ b/drivers/md/dm-stripe.c @@ -20,7 +20,7 @@ struct stripe { struct dm_dev *dev; sector_t physical_start; @@ -34332,7 +35851,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-stripe.c= linux-2.6.32.49/drivers/md/dm- }; =20 struct stripe_c { -@@ -188,7 +188,7 @@ static int stripe_ctr(struct dm_target * +@@ -188,7 +188,7 @@ static int stripe_ctr(struct dm_target *ti, unsigned= int argc, char **argv) kfree(sc); return r; } @@ -34341,7 +35860,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-stripe.c= linux-2.6.32.49/drivers/md/dm- } =20 ti->private =3D sc; -@@ -257,7 +257,7 @@ static int stripe_status(struct dm_targe +@@ -257,7 +257,7 @@ static int stripe_status(struct dm_target *ti, DMEMIT("%d ", sc->stripes); for (i =3D 0; i < sc->stripes; i++) { DMEMIT("%s ", sc->stripe[i].dev->name); @@ -34350,7 +35869,7 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-stripe.c= linux-2.6.32.49/drivers/md/dm- 'D' : 'A'; } buffer[i] =3D '\0'; -@@ -304,8 +304,8 @@ static int stripe_end_io(struct dm_targe +@@ -304,8 +304,8 @@ static int stripe_end_io(struct dm_target *ti, struc= t bio *bio, */ for (i =3D 0; i < sc->stripes; i++) if (!strcmp(sc->stripe[i].dev->name, major_minor)) { @@ -34361,9 +35880,10 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-stripe.= c linux-2.6.32.49/drivers/md/dm- DM_IO_ERROR_THRESHOLD) queue_work(kstriped, &sc->kstriped_ws); } -diff -urNp linux-2.6.32.49/drivers/md/dm-sysfs.c linux-2.6.32.49/drivers= /md/dm-sysfs.c ---- linux-2.6.32.49/drivers/md/dm-sysfs.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/md/dm-sysfs.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/md/dm-sysfs.c b/drivers/md/dm-sysfs.c +index 4b04590..13a77b2 100644 +--- a/drivers/md/dm-sysfs.c ++++ b/drivers/md/dm-sysfs.c @@ -75,7 +75,7 @@ static struct attribute *dm_attrs[] =3D { NULL, }; @@ -34373,10 +35893,11 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-sysfs.= c linux-2.6.32.49/drivers/md/dm-s .show =3D dm_attr_show, }; =20 -diff -urNp linux-2.6.32.49/drivers/md/dm-table.c linux-2.6.32.49/drivers= /md/dm-table.c ---- linux-2.6.32.49/drivers/md/dm-table.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/md/dm-table.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -376,7 +376,7 @@ static int device_area_is_invalid(struct +diff --git a/drivers/md/dm-table.c b/drivers/md/dm-table.c +index 03345bb..332250d 100644 +--- a/drivers/md/dm-table.c ++++ b/drivers/md/dm-table.c +@@ -376,7 +376,7 @@ static int device_area_is_invalid(struct dm_target *= ti, struct dm_dev *dev, if (!dev_size) return 0; =20 @@ -34385,9 +35906,68 @@ diff -urNp linux-2.6.32.49/drivers/md/dm-table.c= linux-2.6.32.49/drivers/md/dm-t DMWARN("%s: %s too small for target: " "start=3D%llu, len=3D%llu, dev_size=3D%llu", dm_device_name(ti->table->md), bdevname(bdev, b), -diff -urNp linux-2.6.32.49/drivers/md/md.c linux-2.6.32.49/drivers/md/md= .c ---- linux-2.6.32.49/drivers/md/md.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/md/md.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/drivers/md/dm.c b/drivers/md/dm.c +index c988ac2..c418141 100644 +--- a/drivers/md/dm.c ++++ b/drivers/md/dm.c +@@ -165,9 +165,9 @@ struct mapped_device { + /* + * Event handling. + */ +- atomic_t event_nr; ++ atomic_unchecked_t event_nr; + wait_queue_head_t eventq; +- atomic_t uevent_seq; ++ atomic_unchecked_t uevent_seq; + struct list_head uevent_list; + spinlock_t uevent_lock; /* Protect access to uevent_list */ +=20 +@@ -1776,8 +1776,8 @@ static struct mapped_device *alloc_dev(int minor) + rwlock_init(&md->map_lock); + atomic_set(&md->holders, 1); + atomic_set(&md->open_count, 0); +- atomic_set(&md->event_nr, 0); +- atomic_set(&md->uevent_seq, 0); ++ atomic_set_unchecked(&md->event_nr, 0); ++ atomic_set_unchecked(&md->uevent_seq, 0); + INIT_LIST_HEAD(&md->uevent_list); + spin_lock_init(&md->uevent_lock); +=20 +@@ -1927,7 +1927,7 @@ static void event_callback(void *context) +=20 + dm_send_uevents(&uevents, &disk_to_dev(md->disk)->kobj); +=20 +- atomic_inc(&md->event_nr); ++ atomic_inc_unchecked(&md->event_nr); + wake_up(&md->eventq); + } +=20 +@@ -2562,18 +2562,18 @@ void dm_kobject_uevent(struct mapped_device *md,= enum kobject_action action, +=20 + uint32_t dm_next_uevent_seq(struct mapped_device *md) + { +- return atomic_add_return(1, &md->uevent_seq); ++ return atomic_add_return_unchecked(1, &md->uevent_seq); + } +=20 + uint32_t dm_get_event_nr(struct mapped_device *md) + { +- return atomic_read(&md->event_nr); ++ return atomic_read_unchecked(&md->event_nr); + } +=20 + int dm_wait_event(struct mapped_device *md, int event_nr) + { + return wait_event_interruptible(md->eventq, +- (event_nr !=3D atomic_read(&md->event_nr))); ++ (event_nr !=3D atomic_read_unchecked(&md->event_nr))); + } +=20 + void dm_uevent_add(struct mapped_device *md, struct list_head *elist) +diff --git a/drivers/md/md.c b/drivers/md/md.c +index 4ce6e2f..7a9530a 100644 +--- a/drivers/md/md.c ++++ b/drivers/md/md.c @@ -153,10 +153,10 @@ static int start_readonly; * start build, activate spare */ @@ -34410,7 +35990,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c wake_up(&md_event_waiters); } =20 -@@ -1226,7 +1226,7 @@ static int super_1_load(mdk_rdev_t *rdev +@@ -1226,7 +1226,7 @@ static int super_1_load(mdk_rdev_t *rdev, mdk_rdev= _t *refdev, int minor_version) =20 rdev->preferred_minor =3D 0xffff; rdev->data_offset =3D le64_to_cpu(sb->data_offset); @@ -34419,7 +35999,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c =20 rdev->sb_size =3D le32_to_cpu(sb->max_dev) * 2 + 256; bmask =3D queue_logical_block_size(rdev->bdev->bd_disk->queue)-1; -@@ -1400,7 +1400,7 @@ static void super_1_sync(mddev_t *mddev, +@@ -1400,7 +1400,7 @@ static void super_1_sync(mddev_t *mddev, mdk_rdev_= t *rdev) else sb->resync_offset =3D cpu_to_le64(0); =20 @@ -34428,7 +36008,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c =20 sb->raid_disks =3D cpu_to_le32(mddev->raid_disks); sb->size =3D cpu_to_le64(mddev->dev_sectors); -@@ -2222,7 +2222,7 @@ __ATTR(state, S_IRUGO|S_IWUSR, state_sho +@@ -2222,7 +2222,7 @@ __ATTR(state, S_IRUGO|S_IWUSR, state_show, state_s= tore); static ssize_t errors_show(mdk_rdev_t *rdev, char *page) { @@ -34437,7 +36017,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c } =20 static ssize_t -@@ -2231,7 +2231,7 @@ errors_store(mdk_rdev_t *rdev, const cha +@@ -2231,7 +2231,7 @@ errors_store(mdk_rdev_t *rdev, const char *buf, si= ze_t len) char *e; unsigned long n =3D simple_strtoul(buf, &e, 10); if (*buf && (*e =3D=3D 0 || *e =3D=3D '\n')) { @@ -34446,7 +36026,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c return len; } return -EINVAL; -@@ -2525,7 +2525,7 @@ static void rdev_free(struct kobject *ko +@@ -2525,7 +2525,7 @@ static void rdev_free(struct kobject *ko) mdk_rdev_t *rdev =3D container_of(ko, mdk_rdev_t, kobj); kfree(rdev); } @@ -34455,7 +36035,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c .show =3D rdev_attr_show, .store =3D rdev_attr_store, }; -@@ -2574,8 +2574,8 @@ static mdk_rdev_t *md_import_device(dev_ +@@ -2574,8 +2574,8 @@ static mdk_rdev_t *md_import_device(dev_t newdev, = int super_format, int super_mi rdev->data_offset =3D 0; rdev->sb_events =3D 0; atomic_set(&rdev->nr_pending, 0); @@ -34485,7 +36065,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c return err; } =20 -@@ -5962,7 +5963,7 @@ static int md_seq_show(struct seq_file * +@@ -5962,7 +5963,7 @@ static int md_seq_show(struct seq_file *seq, void = *v) =20 spin_unlock(&pers_lock); seq_printf(seq, "\n"); @@ -34494,7 +36074,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c return 0; } if (v =3D=3D (void*)2) { -@@ -6051,7 +6052,7 @@ static int md_seq_show(struct seq_file * +@@ -6051,7 +6052,7 @@ static int md_seq_show(struct seq_file *seq, void = *v) chunk_kb ? "KB" : "B"); if (bitmap->file) { seq_printf(seq, ", file: "); @@ -34503,7 +36083,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c } =20 seq_printf(seq, "\n"); -@@ -6085,7 +6086,7 @@ static int md_seq_open(struct inode *ino +@@ -6085,7 +6086,7 @@ static int md_seq_open(struct inode *inode, struct= file *file) else { struct seq_file *p =3D file->private_data; p->private =3D mi; @@ -34512,7 +36092,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c } return error; } -@@ -6101,7 +6102,7 @@ static unsigned int mdstat_poll(struct f +@@ -6101,7 +6102,7 @@ static unsigned int mdstat_poll(struct file *filp,= poll_table *wait) /* always allow read */ mask =3D POLLIN | POLLRDNORM; =20 @@ -34521,7 +36101,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux-= 2.6.32.49/drivers/md/md.c mask |=3D POLLERR | POLLPRI; return mask; } -@@ -6145,7 +6146,7 @@ static int is_mddev_idle(mddev_t *mddev, +@@ -6145,7 +6146,7 @@ static int is_mddev_idle(mddev_t *mddev, int init) struct gendisk *disk =3D rdev->bdev->bd_contains->bd_disk; curr_events =3D (int)part_stat_read(&disk->part0, sectors[0]) + (int)part_stat_read(&disk->part0, sectors[1]) - @@ -34530,9 +36110,10 @@ diff -urNp linux-2.6.32.49/drivers/md/md.c linux= -2.6.32.49/drivers/md/md.c /* sync IO will cause sync_io to increase before the disk_stats * as sync_io is counted when a request starts, and * disk_stats is counted when it completes. -diff -urNp linux-2.6.32.49/drivers/md/md.h linux-2.6.32.49/drivers/md/md= .h ---- linux-2.6.32.49/drivers/md/md.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/md/md.h 2011-11-15 19:59:43.000000000 -0500 +diff --git a/drivers/md/md.h b/drivers/md/md.h +index 87430fe..0024a4c 100644 +--- a/drivers/md/md.h ++++ b/drivers/md/md.h @@ -94,10 +94,10 @@ struct mdk_rdev_s * only maintained for arrays that * support hot removal @@ -34546,7 +36127,7 @@ diff -urNp linux-2.6.32.49/drivers/md/md.h linux-= 2.6.32.49/drivers/md/md.h * for reporting to userspace and storing * in superblock. */ -@@ -304,7 +304,7 @@ static inline void rdev_dec_pending(mdk_ +@@ -304,7 +304,7 @@ static inline void rdev_dec_pending(mdk_rdev_t *rdev= , mddev_t *mddev) =20 static inline void md_sync_acct(struct block_device *bdev, unsigned lon= g nr_sectors) { @@ -34555,31 +36136,11 @@ diff -urNp linux-2.6.32.49/drivers/md/md.h linu= x-2.6.32.49/drivers/md/md.h } =20 struct mdk_personality -diff -urNp linux-2.6.32.49/drivers/md/raid10.c linux-2.6.32.49/drivers/m= d/raid10.c ---- linux-2.6.32.49/drivers/md/raid10.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/md/raid10.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1255,7 +1255,7 @@ static void end_sync_read(struct bio *bi - if (test_bit(BIO_UPTODATE, &bio->bi_flags)) - set_bit(R10BIO_Uptodate, &r10_bio->state); - else { -- atomic_add(r10_bio->sectors, -+ atomic_add_unchecked(r10_bio->sectors, - &conf->mirrors[d].rdev->corrected_errors); - if (!test_bit(MD_RECOVERY_SYNC, &conf->mddev->recovery)) - md_error(r10_bio->mddev, -@@ -1520,7 +1520,7 @@ static void fix_read_error(conf_t *conf, - test_bit(In_sync, &rdev->flags)) { - atomic_inc(&rdev->nr_pending); - rcu_read_unlock(); -- atomic_add(s, &rdev->corrected_errors); -+ atomic_add_unchecked(s, &rdev->corrected_errors); - if (sync_page_io(rdev->bdev, - r10_bio->devs[sl].addr + - sect + rdev->data_offset, -diff -urNp linux-2.6.32.49/drivers/md/raid1.c linux-2.6.32.49/drivers/md= /raid1.c ---- linux-2.6.32.49/drivers/md/raid1.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/md/raid1.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -1415,7 +1415,7 @@ static void sync_request_write(mddev_t * +diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c +index 968cb14..f0ad2e4 100644 +--- a/drivers/md/raid1.c ++++ b/drivers/md/raid1.c +@@ -1415,7 +1415,7 @@ static void sync_request_write(mddev_t *mddev, r1b= io_t *r1_bio) if (r1_bio->bios[d]->bi_end_io !=3D end_sync_read) continue; rdev =3D conf->mirrors[d].rdev; @@ -34588,7 +36149,7 @@ diff -urNp linux-2.6.32.49/drivers/md/raid1.c lin= ux-2.6.32.49/drivers/md/raid1.c if (sync_page_io(rdev->bdev, sect + rdev->data_offset, s<<9, -@@ -1564,7 +1564,7 @@ static void fix_read_error(conf_t *conf, +@@ -1564,7 +1564,7 @@ static void fix_read_error(conf_t *conf, int read_= disk, /* Well, this device is dead */ md_error(mddev, rdev); else { @@ -34597,10 +36158,33 @@ diff -urNp linux-2.6.32.49/drivers/md/raid1.c l= inux-2.6.32.49/drivers/md/raid1.c printk(KERN_INFO "raid1:%s: read error corrected " "(%d sectors at %llu on %s)\n", -diff -urNp linux-2.6.32.49/drivers/md/raid5.c linux-2.6.32.49/drivers/md= /raid5.c ---- linux-2.6.32.49/drivers/md/raid5.c 2011-11-26 19:44:53.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/md/raid5.c 2011-11-26 19:45:06.000000000 -05= 00 -@@ -482,7 +482,7 @@ static void ops_run_io(struct stripe_hea +diff --git a/drivers/md/raid10.c b/drivers/md/raid10.c +index 1b4e232..cf0f534 100644 +--- a/drivers/md/raid10.c ++++ b/drivers/md/raid10.c +@@ -1255,7 +1255,7 @@ static void end_sync_read(struct bio *bio, int err= or) + if (test_bit(BIO_UPTODATE, &bio->bi_flags)) + set_bit(R10BIO_Uptodate, &r10_bio->state); + else { +- atomic_add(r10_bio->sectors, ++ atomic_add_unchecked(r10_bio->sectors, + &conf->mirrors[d].rdev->corrected_errors); + if (!test_bit(MD_RECOVERY_SYNC, &conf->mddev->recovery)) + md_error(r10_bio->mddev, +@@ -1520,7 +1520,7 @@ static void fix_read_error(conf_t *conf, mddev_t *= mddev, r10bio_t *r10_bio) + test_bit(In_sync, &rdev->flags)) { + atomic_inc(&rdev->nr_pending); + rcu_read_unlock(); +- atomic_add(s, &rdev->corrected_errors); ++ atomic_add_unchecked(s, &rdev->corrected_errors); + if (sync_page_io(rdev->bdev, + r10_bio->devs[sl].addr + + sect + rdev->data_offset, +diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c +index 883215d..675bf47 100644 +--- a/drivers/md/raid5.c ++++ b/drivers/md/raid5.c +@@ -482,7 +482,7 @@ static void ops_run_io(struct stripe_head *sh, struc= t stripe_head_state *s) bi->bi_next =3D NULL; if ((rw & WRITE) && test_bit(R5_ReWrite, &sh->dev[i].flags)) @@ -34609,7 +36193,7 @@ diff -urNp linux-2.6.32.49/drivers/md/raid5.c lin= ux-2.6.32.49/drivers/md/raid5.c &rdev->corrected_errors); generic_make_request(bi); } else { -@@ -1517,15 +1517,15 @@ static void raid5_end_read_request(struc +@@ -1517,15 +1517,15 @@ static void raid5_end_read_request(struct bio * = bi, int error) clear_bit(R5_ReadError, &sh->dev[i].flags); clear_bit(R5_ReWrite, &sh->dev[i].flags); } @@ -34628,7 +36212,7 @@ diff -urNp linux-2.6.32.49/drivers/md/raid5.c lin= ux-2.6.32.49/drivers/md/raid5.c if (conf->mddev->degraded >=3D conf->max_degraded) printk_rl(KERN_WARNING "raid5:%s: read error not correctable " -@@ -1543,7 +1543,7 @@ static void raid5_end_read_request(struc +@@ -1543,7 +1543,7 @@ static void raid5_end_read_request(struct bio * bi= , int error) (unsigned long long)(sh->sector + rdev->data_offset), bdn); @@ -34637,7 +36221,7 @@ diff -urNp linux-2.6.32.49/drivers/md/raid5.c lin= ux-2.6.32.49/drivers/md/raid5.c > conf->max_nr_stripes) printk(KERN_WARNING "raid5:%s: Too many read errors, failing device %s.\n", -@@ -1870,6 +1870,7 @@ static sector_t compute_blocknr(struct s +@@ -1870,6 +1870,7 @@ static sector_t compute_blocknr(struct stripe_head= *sh, int i, int previous) sector_t r_sector; struct stripe_head sh2; =20 @@ -34645,10 +36229,11 @@ diff -urNp linux-2.6.32.49/drivers/md/raid5.c l= inux-2.6.32.49/drivers/md/raid5.c =20 chunk_offset =3D sector_div(new_sector, sectors_per_chunk); stripe =3D new_sector; -diff -urNp linux-2.6.32.49/drivers/media/common/saa7146_hlp.c linux-2.6.= 32.49/drivers/media/common/saa7146_hlp.c ---- linux-2.6.32.49/drivers/media/common/saa7146_hlp.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/common/saa7146_hlp.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -353,6 +353,8 @@ static void calculate_clipping_registers +diff --git a/drivers/media/common/saa7146_hlp.c b/drivers/media/common/s= aa7146_hlp.c +index 05bde9c..2f31d40 100644 +--- a/drivers/media/common/saa7146_hlp.c ++++ b/drivers/media/common/saa7146_hlp.c +@@ -353,6 +353,8 @@ static void calculate_clipping_registers_rect(struct= saa7146_dev *dev, struct sa =20 int x[32], y[32], w[32], h[32]; =20 @@ -34657,10 +36242,11 @@ diff -urNp linux-2.6.32.49/drivers/media/common= /saa7146_hlp.c linux-2.6.32.49/dr /* clear out memory */ memset(&line_list[0], 0x00, sizeof(u32)*32); memset(&pixel_list[0], 0x00, sizeof(u32)*32); -diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb-core/dvb_ca_en50221.c l= inux-2.6.32.49/drivers/media/dvb/dvb-core/dvb_ca_en50221.c ---- linux-2.6.32.49/drivers/media/dvb/dvb-core/dvb_ca_en50221.c 2011-11-= 08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/dvb-core/dvb_ca_en50221.c 2011-11-= 15 19:59:43.000000000 -0500 -@@ -590,6 +590,8 @@ static int dvb_ca_en50221_read_data(stru +diff --git a/drivers/media/dvb/dvb-core/dvb_ca_en50221.c b/drivers/media= /dvb/dvb-core/dvb_ca_en50221.c +index cb22da5..82b686e 100644 +--- a/drivers/media/dvb/dvb-core/dvb_ca_en50221.c ++++ b/drivers/media/dvb/dvb-core/dvb_ca_en50221.c +@@ -590,6 +590,8 @@ static int dvb_ca_en50221_read_data(struct dvb_ca_pr= ivate *ca, int slot, u8 * eb u8 buf[HOST_LINK_BUF_SIZE]; int i; =20 @@ -34669,7 +36255,7 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb-= core/dvb_ca_en50221.c linux-2.6 dprintk("%s\n", __func__); =20 /* check if we have space for a link buf in the rx_buffer */ -@@ -1285,6 +1287,8 @@ static ssize_t dvb_ca_en50221_io_write(s +@@ -1285,6 +1287,8 @@ static ssize_t dvb_ca_en50221_io_write(struct file= *file, unsigned long timeout; int written; =20 @@ -34678,9 +36264,10 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb= -core/dvb_ca_en50221.c linux-2.6 dprintk("%s\n", __func__); =20 /* Incoming packet has a 2 byte header. hdr[0] =3D slot_id, hdr[1] =3D= connection_id */ -diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb-core/dvb_demux.h linux-= 2.6.32.49/drivers/media/dvb/dvb-core/dvb_demux.h ---- linux-2.6.32.49/drivers/media/dvb/dvb-core/dvb_demux.h 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/dvb-core/dvb_demux.h 2011-11-15 19= :59:43.000000000 -0500 +diff --git a/drivers/media/dvb/dvb-core/dvb_demux.h b/drivers/media/dvb/= dvb-core/dvb_demux.h +index 2fe05d0..a3289c4 100644 +--- a/drivers/media/dvb/dvb-core/dvb_demux.h ++++ b/drivers/media/dvb/dvb-core/dvb_demux.h @@ -71,7 +71,7 @@ struct dvb_demux_feed { union { dmx_ts_cb ts; @@ -34690,10 +36277,11 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/dv= b-core/dvb_demux.h linux-2.6.32.4 =20 struct dvb_demux *demux; void *priv; -diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb-core/dvbdev.c linux-2.6= .32.49/drivers/media/dvb/dvb-core/dvbdev.c ---- linux-2.6.32.49/drivers/media/dvb/dvb-core/dvbdev.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/dvb-core/dvbdev.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -191,7 +191,7 @@ int dvb_register_device(struct dvb_adapt +diff --git a/drivers/media/dvb/dvb-core/dvbdev.c b/drivers/media/dvb/dvb= -core/dvbdev.c +index 94159b9..376bd8e 100644 +--- a/drivers/media/dvb/dvb-core/dvbdev.c ++++ b/drivers/media/dvb/dvb-core/dvbdev.c +@@ -191,7 +191,7 @@ int dvb_register_device(struct dvb_adapter *adap, st= ruct dvb_device **pdvbdev, const struct dvb_device *template, void *priv, int type) { struct dvb_device *dvbdev; @@ -34702,10 +36290,11 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/dv= b-core/dvbdev.c linux-2.6.32.49/d struct device *clsdev; int minor; int id; -diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb-usb/cxusb.c linux-2.6.3= 2.49/drivers/media/dvb/dvb-usb/cxusb.c ---- linux-2.6.32.49/drivers/media/dvb/dvb-usb/cxusb.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/dvb-usb/cxusb.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -1040,7 +1040,7 @@ static struct dib0070_config dib7070p_di +diff --git a/drivers/media/dvb/dvb-usb/cxusb.c b/drivers/media/dvb/dvb-u= sb/cxusb.c +index 2a53dd0..db8c07a 100644 +--- a/drivers/media/dvb/dvb-usb/cxusb.c ++++ b/drivers/media/dvb/dvb-usb/cxusb.c +@@ -1040,7 +1040,7 @@ static struct dib0070_config dib7070p_dib0070_conf= ig =3D { struct dib0700_adapter_state { int (*set_param_save) (struct dvb_frontend *, struct dvb_frontend_parameters *); @@ -34714,10 +36303,11 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/dv= b-usb/cxusb.c linux-2.6.32.49/dri =20 static int dib7070_set_param_override(struct dvb_frontend *fe, struct dvb_frontend_parameters *fep) -diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_core.c linu= x-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_core.c ---- linux-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_core.c 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_core.c 2011-11-15 = 19:59:43.000000000 -0500 -@@ -332,6 +332,8 @@ int dib0700_download_firmware(struct usb +diff --git a/drivers/media/dvb/dvb-usb/dib0700_core.c b/drivers/media/dv= b/dvb-usb/dib0700_core.c +index db7f7f7..f55e96f 100644 +--- a/drivers/media/dvb/dvb-usb/dib0700_core.c ++++ b/drivers/media/dvb/dvb-usb/dib0700_core.c +@@ -332,6 +332,8 @@ int dib0700_download_firmware(struct usb_device *ude= v, const struct firmware *fw =20 u8 buf[260]; =20 @@ -34726,10 +36316,11 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/dv= b-usb/dib0700_core.c linux-2.6.32 while ((ret =3D dvb_usb_get_hexline(fw, &hx, &pos)) > 0) { deb_fwdata("writing to address 0x%08x (buffer: 0x%02x %02x)\n",hx.add= r, hx.len, hx.chk); =20 -diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_devices.c l= inux-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_devices.c ---- linux-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_devices.c 2011-11-= 08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/dvb-usb/dib0700_devices.c 2011-11-= 15 19:59:43.000000000 -0500 -@@ -28,7 +28,7 @@ MODULE_PARM_DESC(force_lna_activation, " +diff --git a/drivers/media/dvb/dvb-usb/dib0700_devices.c b/drivers/media= /dvb/dvb-usb/dib0700_devices.c +index 524acf5..5ffc403 100644 +--- a/drivers/media/dvb/dvb-usb/dib0700_devices.c ++++ b/drivers/media/dvb/dvb-usb/dib0700_devices.c +@@ -28,7 +28,7 @@ MODULE_PARM_DESC(force_lna_activation, "force the acti= vation of Low-Noise-Amplif =20 struct dib0700_adapter_state { int (*set_param_save) (struct dvb_frontend *, struct dvb_frontend_para= meters *); @@ -34738,9 +36329,10 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/dvb= -usb/dib0700_devices.c linux-2.6 =20 /* Hauppauge Nova-T 500 (aka Bristol) * has a LNA on GPIO0 which is enabled by setting 1 */ -diff -urNp linux-2.6.32.49/drivers/media/dvb/frontends/dib3000.h linux-2= .6.32.49/drivers/media/dvb/frontends/dib3000.h ---- linux-2.6.32.49/drivers/media/dvb/frontends/dib3000.h 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/frontends/dib3000.h 2011-11-15 19:= 59:43.000000000 -0500 +diff --git a/drivers/media/dvb/frontends/dib3000.h b/drivers/media/dvb/f= rontends/dib3000.h +index ba91735..4261d84 100644 +--- a/drivers/media/dvb/frontends/dib3000.h ++++ b/drivers/media/dvb/frontends/dib3000.h @@ -39,7 +39,7 @@ struct dib_fe_xfer_ops int (*fifo_ctrl)(struct dvb_frontend *fe, int onoff); int (*pid_ctrl)(struct dvb_frontend *fe, int index, int pid, int onoff= ); @@ -34750,10 +36342,11 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/fr= ontends/dib3000.h linux-2.6.32.49 =20 #if defined(CONFIG_DVB_DIB3000MB) || (defined(CONFIG_DVB_DIB3000MB_MODU= LE) && defined(MODULE)) extern struct dvb_frontend* dib3000mb_attach(const struct dib3000_confi= g* config, -diff -urNp linux-2.6.32.49/drivers/media/dvb/frontends/or51211.c linux-2= .6.32.49/drivers/media/dvb/frontends/or51211.c ---- linux-2.6.32.49/drivers/media/dvb/frontends/or51211.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/dvb/frontends/or51211.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -113,6 +113,8 @@ static int or51211_load_firmware (struct +diff --git a/drivers/media/dvb/frontends/or51211.c b/drivers/media/dvb/f= rontends/or51211.c +index c709ce6..b3fe620 100644 +--- a/drivers/media/dvb/frontends/or51211.c ++++ b/drivers/media/dvb/frontends/or51211.c +@@ -113,6 +113,8 @@ static int or51211_load_firmware (struct dvb_fronten= d* fe, u8 tudata[585]; int i; =20 @@ -34762,10 +36355,11 @@ diff -urNp linux-2.6.32.49/drivers/media/dvb/fr= ontends/or51211.c linux-2.6.32.49 dprintk("Firmware is %zd bytes\n",fw->size); =20 /* Get eprom data */ -diff -urNp linux-2.6.32.49/drivers/media/radio/radio-cadet.c linux-2.6.3= 2.49/drivers/media/radio/radio-cadet.c ---- linux-2.6.32.49/drivers/media/radio/radio-cadet.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/radio/radio-cadet.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -347,7 +347,7 @@ static ssize_t cadet_read(struct file *f +diff --git a/drivers/media/radio/radio-cadet.c b/drivers/media/radio/rad= io-cadet.c +index 482d0f3..ee1e202 100644 +--- a/drivers/media/radio/radio-cadet.c ++++ b/drivers/media/radio/radio-cadet.c +@@ -347,7 +347,7 @@ static ssize_t cadet_read(struct file *file, char __= user *data, size_t count, lo while (i < count && dev->rdsin !=3D dev->rdsout) readbuf[i++] =3D dev->rdsbuf[dev->rdsout++]; =20 @@ -34774,10 +36368,11 @@ diff -urNp linux-2.6.32.49/drivers/media/radio/= radio-cadet.c linux-2.6.32.49/dri return -EFAULT; return i; } -diff -urNp linux-2.6.32.49/drivers/media/video/cx18/cx18-driver.c linux-= 2.6.32.49/drivers/media/video/cx18/cx18-driver.c ---- linux-2.6.32.49/drivers/media/video/cx18/cx18-driver.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/cx18/cx18-driver.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -56,7 +56,7 @@ static struct pci_device_id cx18_pci_tbl +diff --git a/drivers/media/video/cx18/cx18-driver.c b/drivers/media/vide= o/cx18/cx18-driver.c +index 6dd51e2..0359b92 100644 +--- a/drivers/media/video/cx18/cx18-driver.c ++++ b/drivers/media/video/cx18/cx18-driver.c +@@ -56,7 +56,7 @@ static struct pci_device_id cx18_pci_tbl[] __devinitda= ta =3D { =20 MODULE_DEVICE_TABLE(pci, cx18_pci_tbl); =20 @@ -34786,7 +36381,7 @@ diff -urNp linux-2.6.32.49/drivers/media/video/cx= 18/cx18-driver.c linux-2.6.32.4 =20 /* Parameter declarations */ static int cardtype[CX18_MAX_CARDS]; -@@ -288,6 +288,8 @@ void cx18_read_eeprom(struct cx18 *cx, s +@@ -288,6 +288,8 @@ void cx18_read_eeprom(struct cx18 *cx, struct tveepr= om *tv) struct i2c_client c; u8 eedata[256]; =20 @@ -34795,7 +36390,7 @@ diff -urNp linux-2.6.32.49/drivers/media/video/cx= 18/cx18-driver.c linux-2.6.32.4 memset(&c, 0, sizeof(c)); strlcpy(c.name, "cx18 tveeprom tmp", sizeof(c.name)); c.adapter =3D &cx->i2c_adap[0]; -@@ -800,7 +802,7 @@ static int __devinit cx18_probe(struct p +@@ -800,7 +802,7 @@ static int __devinit cx18_probe(struct pci_dev *pci_= dev, struct cx18 *cx; =20 /* FIXME - module parameter arrays constrain max instances */ @@ -34804,10 +36399,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= cx18/cx18-driver.c linux-2.6.32.4 if (i >=3D CX18_MAX_CARDS) { printk(KERN_ERR "cx18: cannot manage card %d, driver has a " "limit of 0 - %d\n", i, CX18_MAX_CARDS - 1); -diff -urNp linux-2.6.32.49/drivers/media/video/ivtv/ivtv-driver.c linux-= 2.6.32.49/drivers/media/video/ivtv/ivtv-driver.c ---- linux-2.6.32.49/drivers/media/video/ivtv/ivtv-driver.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/ivtv/ivtv-driver.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -79,7 +79,7 @@ static struct pci_device_id ivtv_pci_tbl +diff --git a/drivers/media/video/ivtv/ivtv-driver.c b/drivers/media/vide= o/ivtv/ivtv-driver.c +index 463ec34..2f4625a 100644 +--- a/drivers/media/video/ivtv/ivtv-driver.c ++++ b/drivers/media/video/ivtv/ivtv-driver.c +@@ -79,7 +79,7 @@ static struct pci_device_id ivtv_pci_tbl[] __devinitda= ta =3D { MODULE_DEVICE_TABLE(pci,ivtv_pci_tbl); =20 /* ivtv instance counter */ @@ -34816,10 +36412,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= ivtv/ivtv-driver.c linux-2.6.32.4 =20 /* Parameter declarations */ static int cardtype[IVTV_MAX_CARDS]; -diff -urNp linux-2.6.32.49/drivers/media/video/omap24xxcam.c linux-2.6.3= 2.49/drivers/media/video/omap24xxcam.c ---- linux-2.6.32.49/drivers/media/video/omap24xxcam.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/omap24xxcam.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -401,7 +401,7 @@ static void omap24xxcam_vbq_complete(str +diff --git a/drivers/media/video/omap24xxcam.c b/drivers/media/video/oma= p24xxcam.c +index 5fc4ac0..652a54a 100644 +--- a/drivers/media/video/omap24xxcam.c ++++ b/drivers/media/video/omap24xxcam.c +@@ -401,7 +401,7 @@ static void omap24xxcam_vbq_complete(struct omap24xx= cam_sgdma *sgdma, spin_unlock_irqrestore(&cam->core_enable_disable_lock, flags); =20 do_gettimeofday(&vb->ts); @@ -34828,9 +36425,10 @@ diff -urNp linux-2.6.32.49/drivers/media/video/o= map24xxcam.c linux-2.6.32.49/dri if (csr & csr_error) { vb->state =3D VIDEOBUF_ERROR; if (!atomic_read(&fh->cam->in_reset)) { -diff -urNp linux-2.6.32.49/drivers/media/video/omap24xxcam.h linux-2.6.3= 2.49/drivers/media/video/omap24xxcam.h ---- linux-2.6.32.49/drivers/media/video/omap24xxcam.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/omap24xxcam.h 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/drivers/media/video/omap24xxcam.h b/drivers/media/video/oma= p24xxcam.h +index 2ce67f5..cf26a5b 100644 +--- a/drivers/media/video/omap24xxcam.h ++++ b/drivers/media/video/omap24xxcam.h @@ -533,7 +533,7 @@ struct omap24xxcam_fh { spinlock_t vbq_lock; /* spinlock for the videobuf queue */ struct videobuf_queue vbq; @@ -34840,10 +36438,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= omap24xxcam.h linux-2.6.32.49/dri /* accessing cam here doesn't need serialisation: it's constant */ struct omap24xxcam_device *cam; }; -diff -urNp linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-eeprom.c = linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-eeprom.c ---- linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-eeprom.c 2011-11= -08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-eeprom.c 2011-11= -15 19:59:43.000000000 -0500 -@@ -119,6 +119,8 @@ int pvr2_eeprom_analyze(struct pvr2_hdw=20 +diff --git a/drivers/media/video/pvrusb2/pvrusb2-eeprom.c b/drivers/medi= a/video/pvrusb2/pvrusb2-eeprom.c +index 299afa4..eb47459 100644 +--- a/drivers/media/video/pvrusb2/pvrusb2-eeprom.c ++++ b/drivers/media/video/pvrusb2/pvrusb2-eeprom.c +@@ -119,6 +119,8 @@ int pvr2_eeprom_analyze(struct pvr2_hdw *hdw) u8 *eeprom; struct tveeprom tvdata; =20 @@ -34852,9 +36451,10 @@ diff -urNp linux-2.6.32.49/drivers/media/video/p= vrusb2/pvrusb2-eeprom.c linux-2. memset(&tvdata,0,sizeof(tvdata)); =20 eeprom =3D pvr2_eeprom_fetch(hdw); -diff -urNp linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-hdw-inter= nal.h linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h ---- linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h 2= 011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h 2= 011-11-15 19:59:43.000000000 -0500 +diff --git a/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h b/driver= s/media/video/pvrusb2/pvrusb2-hdw-internal.h +index 5b152ff..3320638 100644 +--- a/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h ++++ b/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h @@ -195,7 +195,7 @@ struct pvr2_hdw { =20 /* I2C stuff */ @@ -34864,10 +36464,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= pvrusb2/pvrusb2-hdw-internal.h li pvr2_i2c_func i2c_func[PVR2_I2C_FUNC_CNT]; int i2c_cx25840_hack_state; int i2c_linked; -diff -urNp linux-2.6.32.49/drivers/media/video/saa7134/saa6752hs.c linux= -2.6.32.49/drivers/media/video/saa7134/saa6752hs.c ---- linux-2.6.32.49/drivers/media/video/saa7134/saa6752hs.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/saa7134/saa6752hs.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -683,6 +683,8 @@ static int saa6752hs_init(struct v4l2_su +diff --git a/drivers/media/video/saa7134/saa6752hs.c b/drivers/media/vid= eo/saa7134/saa6752hs.c +index 1eabff6..8e2313a 100644 +--- a/drivers/media/video/saa7134/saa6752hs.c ++++ b/drivers/media/video/saa7134/saa6752hs.c +@@ -683,6 +683,8 @@ static int saa6752hs_init(struct v4l2_subdev *sd, u3= 2 leading_null_bytes) unsigned char localPAT[256]; unsigned char localPMT[256]; =20 @@ -34876,10 +36477,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= saa7134/saa6752hs.c linux-2.6.32. /* Set video format - must be done first as it resets other settings *= / set_reg8(client, 0x41, h->video_format); =20 -diff -urNp linux-2.6.32.49/drivers/media/video/saa7164/saa7164-cmd.c lin= ux-2.6.32.49/drivers/media/video/saa7164/saa7164-cmd.c ---- linux-2.6.32.49/drivers/media/video/saa7164/saa7164-cmd.c 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/saa7164/saa7164-cmd.c 2011-11-15= 19:59:43.000000000 -0500 -@@ -87,6 +87,8 @@ int saa7164_irq_dequeue(struct saa7164_d +diff --git a/drivers/media/video/saa7164/saa7164-cmd.c b/drivers/media/v= ideo/saa7164/saa7164-cmd.c +index 9c1d3ac..b1b49e9 100644 +--- a/drivers/media/video/saa7164/saa7164-cmd.c ++++ b/drivers/media/video/saa7164/saa7164-cmd.c +@@ -87,6 +87,8 @@ int saa7164_irq_dequeue(struct saa7164_dev *dev) wait_queue_head_t *q =3D 0; dprintk(DBGLVL_CMD, "%s()\n", __func__); =20 @@ -34888,7 +36490,7 @@ diff -urNp linux-2.6.32.49/drivers/media/video/sa= a7164/saa7164-cmd.c linux-2.6.3 /* While any outstand message on the bus exists... */ do { =20 -@@ -126,6 +128,8 @@ int saa7164_cmd_dequeue(struct saa7164_d +@@ -126,6 +128,8 @@ int saa7164_cmd_dequeue(struct saa7164_dev *dev) u8 tmp[512]; dprintk(DBGLVL_CMD, "%s()\n", __func__); =20 @@ -34897,10 +36499,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= saa7164/saa7164-cmd.c linux-2.6.3 while (loop) { =20 tmComResInfo_t tRsp =3D { 0, 0, 0, 0, 0, 0 }; -diff -urNp linux-2.6.32.49/drivers/media/video/usbvideo/ibmcam.c linux-2= .6.32.49/drivers/media/video/usbvideo/ibmcam.c ---- linux-2.6.32.49/drivers/media/video/usbvideo/ibmcam.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/usbvideo/ibmcam.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -3947,15 +3947,15 @@ static struct usb_device_id id_table[] =3D +diff --git a/drivers/media/video/usbvideo/ibmcam.c b/drivers/media/video= /usbvideo/ibmcam.c +index b085496..cde0270 100644 +--- a/drivers/media/video/usbvideo/ibmcam.c ++++ b/drivers/media/video/usbvideo/ibmcam.c +@@ -3947,15 +3947,15 @@ static struct usb_device_id id_table[] =3D { static int __init ibmcam_init(void) { struct usbvideo_cb cbTbl; @@ -34925,10 +36528,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= usbvideo/ibmcam.c linux-2.6.32.49 return usbvideo_register( &cams, MAX_IBMCAM, -diff -urNp linux-2.6.32.49/drivers/media/video/usbvideo/konicawc.c linux= -2.6.32.49/drivers/media/video/usbvideo/konicawc.c ---- linux-2.6.32.49/drivers/media/video/usbvideo/konicawc.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/usbvideo/konicawc.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -225,7 +225,7 @@ static void konicawc_register_input(stru +diff --git a/drivers/media/video/usbvideo/konicawc.c b/drivers/media/vid= eo/usbvideo/konicawc.c +index 31d57f2..600b735 100644 +--- a/drivers/media/video/usbvideo/konicawc.c ++++ b/drivers/media/video/usbvideo/konicawc.c +@@ -225,7 +225,7 @@ static void konicawc_register_input(struct konicawc = *cam, struct usb_device *dev int error; =20 usb_make_path(dev, cam->input_physname, sizeof(cam->input_physname)); @@ -34964,10 +36568,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= usbvideo/konicawc.c linux-2.6.32. return usbvideo_register( &cams, MAX_CAMERAS, -diff -urNp linux-2.6.32.49/drivers/media/video/usbvideo/quickcam_messeng= er.c linux-2.6.32.49/drivers/media/video/usbvideo/quickcam_messenger.c ---- linux-2.6.32.49/drivers/media/video/usbvideo/quickcam_messenger.c 20= 11-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/usbvideo/quickcam_messenger.c 20= 11-11-15 19:59:43.000000000 -0500 -@@ -89,7 +89,7 @@ static void qcm_register_input(struct qc +diff --git a/drivers/media/video/usbvideo/quickcam_messenger.c b/drivers= /media/video/usbvideo/quickcam_messenger.c +index 803d3e4..c4d1b96 100644 +--- a/drivers/media/video/usbvideo/quickcam_messenger.c ++++ b/drivers/media/video/usbvideo/quickcam_messenger.c +@@ -89,7 +89,7 @@ static void qcm_register_input(struct qcm *cam, struct= usb_device *dev) int error; =20 usb_make_path(dev, cam->input_physname, sizeof(cam->input_physname)); @@ -34976,9 +36581,10 @@ diff -urNp linux-2.6.32.49/drivers/media/video/u= sbvideo/quickcam_messenger.c lin =20 cam->input =3D input_dev =3D input_allocate_device(); if (!input_dev) { -diff -urNp linux-2.6.32.49/drivers/media/video/usbvideo/ultracam.c linux= -2.6.32.49/drivers/media/video/usbvideo/ultracam.c ---- linux-2.6.32.49/drivers/media/video/usbvideo/ultracam.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/usbvideo/ultracam.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/media/video/usbvideo/ultracam.c b/drivers/media/vid= eo/usbvideo/ultracam.c +index fbd1b63..292f9f0 100644 +--- a/drivers/media/video/usbvideo/ultracam.c ++++ b/drivers/media/video/usbvideo/ultracam.c @@ -655,14 +655,14 @@ static int __init ultracam_init(void) { struct usbvideo_cb cbTbl; @@ -35002,9 +36608,10 @@ diff -urNp linux-2.6.32.49/drivers/media/video/u= sbvideo/ultracam.c linux-2.6.32. return usbvideo_register( &cams, MAX_CAMERAS, -diff -urNp linux-2.6.32.49/drivers/media/video/usbvideo/usbvideo.c linux= -2.6.32.49/drivers/media/video/usbvideo/usbvideo.c ---- linux-2.6.32.49/drivers/media/video/usbvideo/usbvideo.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/usbvideo/usbvideo.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/media/video/usbvideo/usbvideo.c b/drivers/media/vid= eo/usbvideo/usbvideo.c +index dea8b32..34f6878 100644 +--- a/drivers/media/video/usbvideo/usbvideo.c ++++ b/drivers/media/video/usbvideo/usbvideo.c @@ -697,15 +697,15 @@ int usbvideo_register( __func__, cams, base_size, num_cams); =20 @@ -35026,9 +36633,10 @@ diff -urNp linux-2.6.32.49/drivers/media/video/u= sbvideo/usbvideo.c linux-2.6.32. =20 cams->num_cameras =3D num_cams; cams->cam =3D (struct uvd *) &cams[1]; -diff -urNp linux-2.6.32.49/drivers/media/video/usbvideo/usbvideo.h linux= -2.6.32.49/drivers/media/video/usbvideo/usbvideo.h ---- linux-2.6.32.49/drivers/media/video/usbvideo/usbvideo.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/usbvideo/usbvideo.h 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/media/video/usbvideo/usbvideo.h b/drivers/media/vid= eo/usbvideo/usbvideo.h +index c66985b..7fa143a 100644 +--- a/drivers/media/video/usbvideo/usbvideo.h ++++ b/drivers/media/video/usbvideo/usbvideo.h @@ -268,7 +268,7 @@ struct usbvideo_cb { int (*startDataPump)(struct uvd *uvd); void (*stopDataPump)(struct uvd *uvd); @@ -35038,10 +36646,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= usbvideo/usbvideo.h linux-2.6.32. =20 struct usbvideo { int num_cameras; /* As allocated */ -diff -urNp linux-2.6.32.49/drivers/media/video/usbvision/usbvision-core.= c linux-2.6.32.49/drivers/media/video/usbvision/usbvision-core.c ---- linux-2.6.32.49/drivers/media/video/usbvision/usbvision-core.c 2011-= 11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/usbvision/usbvision-core.c 2011-= 11-15 19:59:43.000000000 -0500 -@@ -820,6 +820,8 @@ static enum ParseState usbvision_parse_c +diff --git a/drivers/media/video/usbvision/usbvision-core.c b/drivers/me= dia/video/usbvision/usbvision-core.c +index e0f91e4..37554ea 100644 +--- a/drivers/media/video/usbvision/usbvision-core.c ++++ b/drivers/media/video/usbvision/usbvision-core.c +@@ -820,6 +820,8 @@ static enum ParseState usbvision_parse_compress(stru= ct usb_usbvision *usbvision, unsigned char rv, gv, bv; static unsigned char *Y, *U, *V; =20 @@ -35050,10 +36659,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= usbvision/usbvision-core.c linux- frame =3D usbvision->curFrame; imageSize =3D frame->frmwidth * frame->frmheight; if ( (frame->v4l2_format.format =3D=3D V4L2_PIX_FMT_YUV422P) || -diff -urNp linux-2.6.32.49/drivers/media/video/v4l2-device.c linux-2.6.3= 2.49/drivers/media/video/v4l2-device.c ---- linux-2.6.32.49/drivers/media/video/v4l2-device.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/v4l2-device.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -50,9 +50,9 @@ int v4l2_device_register(struct device * +diff --git a/drivers/media/video/v4l2-device.c b/drivers/media/video/v4l= 2-device.c +index 0d06e7c..3d17d24 100644 +--- a/drivers/media/video/v4l2-device.c ++++ b/drivers/media/video/v4l2-device.c +@@ -50,9 +50,9 @@ int v4l2_device_register(struct device *dev, struct v4= l2_device *v4l2_dev) EXPORT_SYMBOL_GPL(v4l2_device_register); =20 int v4l2_device_set_name(struct v4l2_device *v4l2_dev, const char *base= name, @@ -35065,9 +36675,10 @@ diff -urNp linux-2.6.32.49/drivers/media/video/v= 4l2-device.c linux-2.6.32.49/dri int len =3D strlen(basename); =20 if (basename[len - 1] >=3D '0' && basename[len - 1] <=3D '9') -diff -urNp linux-2.6.32.49/drivers/media/video/videobuf-dma-sg.c linux-2= .6.32.49/drivers/media/video/videobuf-dma-sg.c ---- linux-2.6.32.49/drivers/media/video/videobuf-dma-sg.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/media/video/videobuf-dma-sg.c 2011-11-15 19:= 59:43.000000000 -0500 +diff --git a/drivers/media/video/videobuf-dma-sg.c b/drivers/media/video= /videobuf-dma-sg.c +index 032ebae..6a3532c 100644 +--- a/drivers/media/video/videobuf-dma-sg.c ++++ b/drivers/media/video/videobuf-dma-sg.c @@ -693,6 +693,8 @@ void *videobuf_sg_alloc(size_t size) { struct videobuf_queue q; @@ -35077,10 +36688,11 @@ diff -urNp linux-2.6.32.49/drivers/media/video/= videobuf-dma-sg.c linux-2.6.32.49 /* Required to make generic handler to call __videobuf_alloc */ q.int_ops =3D &sg_ops; =20 -diff -urNp linux-2.6.32.49/drivers/message/fusion/mptbase.c linux-2.6.32= .49/drivers/message/fusion/mptbase.c ---- linux-2.6.32.49/drivers/message/fusion/mptbase.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/message/fusion/mptbase.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -6709,8 +6709,14 @@ procmpt_iocinfo_read(char *buf, char **s +diff --git a/drivers/message/fusion/mptbase.c b/drivers/message/fusion/m= ptbase.c +index b6992b7..9fa7547 100644 +--- a/drivers/message/fusion/mptbase.c ++++ b/drivers/message/fusion/mptbase.c +@@ -6709,8 +6709,14 @@ procmpt_iocinfo_read(char *buf, char **start, off= _t offset, int request, int *eo len +=3D sprintf(buf+len, " MaxChainDepth =3D 0x%02x frames\n", ioc->= facts.MaxChainDepth); len +=3D sprintf(buf+len, " MinBlockSize =3D 0x%02x bytes\n", 4*ioc->= facts.BlockSize); =20 @@ -35095,10 +36707,11 @@ diff -urNp linux-2.6.32.49/drivers/message/fusi= on/mptbase.c linux-2.6.32.49/driv /* * Rounding UP to nearest 4-kB boundary here... */ -diff -urNp linux-2.6.32.49/drivers/message/fusion/mptsas.c linux-2.6.32.= 49/drivers/message/fusion/mptsas.c ---- linux-2.6.32.49/drivers/message/fusion/mptsas.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/message/fusion/mptsas.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -436,6 +436,23 @@ mptsas_is_end_device(struct mptsas_devin +diff --git a/drivers/message/fusion/mptsas.c b/drivers/message/fusion/mp= tsas.c +index 83873e3..e360e9a 100644 +--- a/drivers/message/fusion/mptsas.c ++++ b/drivers/message/fusion/mptsas.c +@@ -436,6 +436,23 @@ mptsas_is_end_device(struct mptsas_devinfo * attach= ed) return 0; } =20 @@ -35122,7 +36735,7 @@ diff -urNp linux-2.6.32.49/drivers/message/fusion= /mptsas.c linux-2.6.32.49/drive /* no mutex */ static void mptsas_port_delete(MPT_ADAPTER *ioc, struct mptsas_portinfo_details * p= ort_details) -@@ -474,23 +491,6 @@ mptsas_get_rphy(struct mptsas_phyinfo *p +@@ -474,23 +491,6 @@ mptsas_get_rphy(struct mptsas_phyinfo *phy_info) return NULL; } =20 @@ -35146,9 +36759,10 @@ diff -urNp linux-2.6.32.49/drivers/message/fusio= n/mptsas.c linux-2.6.32.49/drive static inline struct sas_port * mptsas_get_port(struct mptsas_phyinfo *phy_info) { -diff -urNp linux-2.6.32.49/drivers/message/fusion/mptscsih.c linux-2.6.3= 2.49/drivers/message/fusion/mptscsih.c ---- linux-2.6.32.49/drivers/message/fusion/mptscsih.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/message/fusion/mptscsih.c 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/drivers/message/fusion/mptscsih.c b/drivers/message/fusion/= mptscsih.c +index bd096ca..332cf76 100644 +--- a/drivers/message/fusion/mptscsih.c ++++ b/drivers/message/fusion/mptscsih.c @@ -1248,15 +1248,16 @@ mptscsih_info(struct Scsi_Host *SChost) =20 h =3D shost_priv(SChost); @@ -35174,10 +36788,11 @@ diff -urNp linux-2.6.32.49/drivers/message/fusi= on/mptscsih.c linux-2.6.32.49/dri =20 return h->info_kbuf; } -diff -urNp linux-2.6.32.49/drivers/message/i2o/i2o_config.c linux-2.6.32= .49/drivers/message/i2o/i2o_config.c ---- linux-2.6.32.49/drivers/message/i2o/i2o_config.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/message/i2o/i2o_config.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -787,6 +787,8 @@ static int i2o_cfg_passthru(unsigned lon +diff --git a/drivers/message/i2o/i2o_config.c b/drivers/message/i2o/i2o_= config.c +index efba702..59b2c0f 100644 +--- a/drivers/message/i2o/i2o_config.c ++++ b/drivers/message/i2o/i2o_config.c +@@ -787,6 +787,8 @@ static int i2o_cfg_passthru(unsigned long arg) struct i2o_message *msg; unsigned int iop; =20 @@ -35186,9 +36801,10 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/i= 2o_config.c linux-2.6.32.49/driv if (get_user(iop, &cmd->iop) || get_user(user_msg, &cmd->msg)) return -EFAULT; =20 -diff -urNp linux-2.6.32.49/drivers/message/i2o/i2o_proc.c linux-2.6.32.4= 9/drivers/message/i2o/i2o_proc.c ---- linux-2.6.32.49/drivers/message/i2o/i2o_proc.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/message/i2o/i2o_proc.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/message/i2o/i2o_proc.c b/drivers/message/i2o/i2o_pr= oc.c +index 7045c45..c07b170 100644 +--- a/drivers/message/i2o/i2o_proc.c ++++ b/drivers/message/i2o/i2o_proc.c @@ -259,13 +259,6 @@ static char *scsi_devices[] =3D { "Array Controller Device" }; @@ -35203,7 +36819,7 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/i2= o_proc.c linux-2.6.32.49/driver static int i2o_report_query_status(struct seq_file *seq, int block_stat= us, char *group) { -@@ -842,8 +835,7 @@ static int i2o_seq_show_ddm_table(struct +@@ -842,8 +835,7 @@ static int i2o_seq_show_ddm_table(struct seq_file *s= eq, void *v) =20 seq_printf(seq, "%-#7x", ddm_table.i2o_vendor_id); seq_printf(seq, "%-#8x", ddm_table.module_id); @@ -35213,7 +36829,7 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/i2= o_proc.c linux-2.6.32.49/driver seq_printf(seq, "%9d ", ddm_table.data_size); seq_printf(seq, "%8d", ddm_table.code_size); =20 -@@ -944,8 +936,8 @@ static int i2o_seq_show_drivers_stored(s +@@ -944,8 +936,8 @@ static int i2o_seq_show_drivers_stored(struct seq_fi= le *seq, void *v) =20 seq_printf(seq, "%-#7x", dst->i2o_vendor_id); seq_printf(seq, "%-#8x", dst->module_id); @@ -35224,7 +36840,7 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/i2= o_proc.c linux-2.6.32.49/driver seq_printf(seq, "%8d ", dst->module_size); seq_printf(seq, "%8d ", dst->mpb_size); seq_printf(seq, "0x%04x", dst->module_flags); -@@ -1276,14 +1268,10 @@ static int i2o_seq_show_dev_identity(str +@@ -1276,14 +1268,10 @@ static int i2o_seq_show_dev_identity(struct seq_= file *seq, void *v) seq_printf(seq, "Device Class : %s\n", i2o_get_class_name(work16[0]))= ; seq_printf(seq, "Owner TID : %0#5x\n", work16[2]); seq_printf(seq, "Parent TID : %0#5x\n", work16[3]); @@ -35243,7 +36859,7 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/i2= o_proc.c linux-2.6.32.49/driver =20 seq_printf(seq, "Serial number : "); print_serial_number(seq, (u8 *) (work32 + 16), -@@ -1328,10 +1316,8 @@ static int i2o_seq_show_ddm_identity(str +@@ -1328,10 +1316,8 @@ static int i2o_seq_show_ddm_identity(struct seq_f= ile *seq, void *v) } =20 seq_printf(seq, "Registering DDM TID : 0x%03x\n", result.ddm_tid); @@ -35256,7 +36872,7 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/i2= o_proc.c linux-2.6.32.49/driver =20 seq_printf(seq, "Serial number : "); print_serial_number(seq, result.serial_number, sizeof(result) - 36); -@@ -1362,14 +1348,10 @@ static int i2o_seq_show_uinfo(struct seq +@@ -1362,14 +1348,10 @@ static int i2o_seq_show_uinfo(struct seq_file *s= eq, void *v) return 0; } =20 @@ -35275,10 +36891,11 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/= i2o_proc.c linux-2.6.32.49/driver =20 return 0; } -diff -urNp linux-2.6.32.49/drivers/message/i2o/iop.c linux-2.6.32.49/dri= vers/message/i2o/iop.c ---- linux-2.6.32.49/drivers/message/i2o/iop.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/message/i2o/iop.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -110,10 +110,10 @@ u32 i2o_cntxt_list_add(struct i2o_contro +diff --git a/drivers/message/i2o/iop.c b/drivers/message/i2o/iop.c +index 27cf4af..b1205b8 100644 +--- a/drivers/message/i2o/iop.c ++++ b/drivers/message/i2o/iop.c +@@ -110,10 +110,10 @@ u32 i2o_cntxt_list_add(struct i2o_controller * c, = void *ptr) =20 spin_lock_irqsave(&c->context_list_lock, flags); =20 @@ -35292,7 +36909,7 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/io= p.c linux-2.6.32.49/drivers/mes =20 list_add(&entry->list, &c->context_list); =20 -@@ -1076,7 +1076,7 @@ struct i2o_controller *i2o_iop_alloc(voi +@@ -1076,7 +1076,7 @@ struct i2o_controller *i2o_iop_alloc(void) =20 #if BITS_PER_LONG =3D=3D 64 spin_lock_init(&c->context_list_lock); @@ -35301,9 +36918,10 @@ diff -urNp linux-2.6.32.49/drivers/message/i2o/i= op.c linux-2.6.32.49/drivers/mes INIT_LIST_HEAD(&c->context_list); #endif =20 -diff -urNp linux-2.6.32.49/drivers/mfd/ab3100-core.c linux-2.6.32.49/dri= vers/mfd/ab3100-core.c ---- linux-2.6.32.49/drivers/mfd/ab3100-core.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/mfd/ab3100-core.c 2011-11-18 18:01:55.000000= 000 -0500 +diff --git a/drivers/mfd/ab3100-core.c b/drivers/mfd/ab3100-core.c +index 78e3e85..66c9a0d 100644 +--- a/drivers/mfd/ab3100-core.c ++++ b/drivers/mfd/ab3100-core.c @@ -777,7 +777,7 @@ struct ab_family_id { char *name; }; @@ -35313,10 +36931,11 @@ diff -urNp linux-2.6.32.49/drivers/mfd/ab3100-c= ore.c linux-2.6.32.49/drivers/mfd /* AB3100 */ { .id =3D 0xc0, -diff -urNp linux-2.6.32.49/drivers/mfd/wm8350-i2c.c linux-2.6.32.49/driv= ers/mfd/wm8350-i2c.c ---- linux-2.6.32.49/drivers/mfd/wm8350-i2c.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/mfd/wm8350-i2c.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -43,6 +43,8 @@ static int wm8350_i2c_write_device(struc +diff --git a/drivers/mfd/wm8350-i2c.c b/drivers/mfd/wm8350-i2c.c +index 8d8c932..8104515 100644 +--- a/drivers/mfd/wm8350-i2c.c ++++ b/drivers/mfd/wm8350-i2c.c +@@ -43,6 +43,8 @@ static int wm8350_i2c_write_device(struct wm8350 *wm83= 50, char reg, u8 msg[(WM8350_MAX_REGISTER << 1) + 1]; int ret; =20 @@ -35325,9 +36944,10 @@ diff -urNp linux-2.6.32.49/drivers/mfd/wm8350-i2= c.c linux-2.6.32.49/drivers/mfd/ if (bytes > ((WM8350_MAX_REGISTER << 1) + 1)) return -EINVAL; =20 -diff -urNp linux-2.6.32.49/drivers/misc/kgdbts.c linux-2.6.32.49/drivers= /misc/kgdbts.c ---- linux-2.6.32.49/drivers/misc/kgdbts.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/misc/kgdbts.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/misc/kgdbts.c b/drivers/misc/kgdbts.c +index e4ff50b..4cc3f04 100644 +--- a/drivers/misc/kgdbts.c ++++ b/drivers/misc/kgdbts.c @@ -118,7 +118,7 @@ } while (0) #define MAX_CONFIG_LEN 40 @@ -35337,7 +36957,7 @@ diff -urNp linux-2.6.32.49/drivers/misc/kgdbts.c = linux-2.6.32.49/drivers/misc/kg static char get_buf[BUFMAX]; static int get_buf_cnt; static char put_buf[BUFMAX]; -@@ -1102,7 +1102,7 @@ static void kgdbts_post_exp_handler(void +@@ -1102,7 +1102,7 @@ static void kgdbts_post_exp_handler(void) module_put(THIS_MODULE); } =20 @@ -35346,10 +36966,11 @@ diff -urNp linux-2.6.32.49/drivers/misc/kgdbts.= c linux-2.6.32.49/drivers/misc/kg .name =3D "kgdbts", .read_char =3D kgdbts_get_char, .write_char =3D kgdbts_put_char, -diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/gruhandles.c linux-2.6.3= 2.49/drivers/misc/sgi-gru/gruhandles.c ---- linux-2.6.32.49/drivers/misc/sgi-gru/gruhandles.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-gru/gruhandles.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -39,8 +39,8 @@ struct mcs_op_statistic mcs_op_statistic +diff --git a/drivers/misc/sgi-gru/gruhandles.c b/drivers/misc/sgi-gru/gr= uhandles.c +index 37e7cfc..67cfb76 100644 +--- a/drivers/misc/sgi-gru/gruhandles.c ++++ b/drivers/misc/sgi-gru/gruhandles.c +@@ -39,8 +39,8 @@ struct mcs_op_statistic mcs_op_statistics[mcsop_last]; =20 static void update_mcs_stats(enum mcs_op op, unsigned long clks) { @@ -35360,9 +36981,10 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/= gruhandles.c linux-2.6.32.49/dri if (mcs_op_statistics[op].max < clks) mcs_op_statistics[op].max =3D clks; } -diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/gruprocfs.c linux-2.6.32= .49/drivers/misc/sgi-gru/gruprocfs.c ---- linux-2.6.32.49/drivers/misc/sgi-gru/gruprocfs.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-gru/gruprocfs.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/misc/sgi-gru/gruprocfs.c b/drivers/misc/sgi-gru/gru= procfs.c +index 3f2375c..467c6e6 100644 +--- a/drivers/misc/sgi-gru/gruprocfs.c ++++ b/drivers/misc/sgi-gru/gruprocfs.c @@ -32,9 +32,9 @@ =20 #define printstat(s, f) printstat_val(s, &gru_stats.f, #f) @@ -35375,7 +36997,7 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/g= ruprocfs.c linux-2.6.32.49/driv =20 if (val) seq_printf(s, "%16lu %s\n", val, id); -@@ -136,8 +136,8 @@ static int mcs_statistics_show(struct se +@@ -136,8 +136,8 @@ static int mcs_statistics_show(struct seq_file *s, v= oid *p) "cch_interrupt_sync", "cch_deallocate", "tgh_invalidate"}; =20 for (op =3D 0; op < mcsop_last; op++) { @@ -35386,9 +37008,10 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/= gruprocfs.c linux-2.6.32.49/driv max =3D mcs_op_statistics[op].max; seq_printf(s, "%-20s%12ld%12ld%12ld\n", id[op], count, count ? total / count : 0, max); -diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/grutables.h linux-2.6.32= .49/drivers/misc/sgi-gru/grutables.h ---- linux-2.6.32.49/drivers/misc/sgi-gru/grutables.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-gru/grutables.h 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/misc/sgi-gru/grutables.h b/drivers/misc/sgi-gru/gru= tables.h +index 46990bc..4a251b5 100644 +--- a/drivers/misc/sgi-gru/grutables.h ++++ b/drivers/misc/sgi-gru/grutables.h @@ -167,84 +167,84 @@ extern unsigned int gru_max_gids; * GRU statistics. */ @@ -35552,7 +37175,7 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/g= rutables.h linux-2.6.32.49/driv =20 }; =20 -@@ -252,8 +252,8 @@ enum mcs_op {cchop_allocate, cchop_start +@@ -252,8 +252,8 @@ enum mcs_op {cchop_allocate, cchop_start, cchop_inte= rrupt, cchop_interrupt_sync, cchop_deallocate, tghop_invalidate, mcsop_last}; =20 struct mcs_op_statistic { @@ -35563,7 +37186,7 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/g= rutables.h linux-2.6.32.49/driv unsigned long max; }; =20 -@@ -276,7 +276,7 @@ extern struct mcs_op_statistic mcs_op_st +@@ -276,7 +276,7 @@ extern struct mcs_op_statistic mcs_op_statistics[mcs= op_last]; =20 #define STAT(id) do { \ if (gru_options & OPT_STATS) \ @@ -35572,9 +37195,23 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-gru/= grutables.h linux-2.6.32.49/driv } while (0) =20 #ifdef CONFIG_SGI_GRU_DEBUG -diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/xpc.h linux-2.6.32.49/dri= vers/misc/sgi-xp/xpc.h ---- linux-2.6.32.49/drivers/misc/sgi-xp/xpc.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-xp/xpc.h 2011-11-18 18:05:51.000000= 000 -0500 +diff --git a/drivers/misc/sgi-xp/xp.h b/drivers/misc/sgi-xp/xp.h +index 2275126..12a9dbfb 100644 +--- a/drivers/misc/sgi-xp/xp.h ++++ b/drivers/misc/sgi-xp/xp.h +@@ -289,7 +289,7 @@ struct xpc_interface { + xpc_notify_func, void *); + void (*received) (short, int, void *); + enum xp_retval (*partid_to_nasids) (short, void *); +-}; ++} __no_const; +=20 + extern struct xpc_interface xpc_interface; +=20 +diff --git a/drivers/misc/sgi-xp/xpc.h b/drivers/misc/sgi-xp/xpc.h +index b94d5f7..7f494c5 100644 +--- a/drivers/misc/sgi-xp/xpc.h ++++ b/drivers/misc/sgi-xp/xpc.h @@ -835,6 +835,7 @@ struct xpc_arch_operations { void (*received_payload) (struct xpc_channel *, void *); void (*notify_senders_of_disconnect) (struct xpc_channel *); @@ -35583,7 +37220,7 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/xp= c.h linux-2.6.32.49/drivers/mis =20 /* struct xpc_partition act_state values (for XPC HB) */ =20 -@@ -876,7 +877,7 @@ extern struct xpc_registration xpc_regis +@@ -876,7 +877,7 @@ extern struct xpc_registration xpc_registrations[]; /* found in xpc_main.c */ extern struct device *xpc_part; extern struct device *xpc_chan; @@ -35592,10 +37229,11 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/= xpc.h linux-2.6.32.49/drivers/mis extern int xpc_disengage_timelimit; extern int xpc_disengage_timedout; extern int xpc_activate_IRQ_rcvd; -diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/xpc_main.c linux-2.6.32.4= 9/drivers/misc/sgi-xp/xpc_main.c ---- linux-2.6.32.49/drivers/misc/sgi-xp/xpc_main.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-xp/xpc_main.c 2011-11-18 18:05:28.0= 00000000 -0500 -@@ -169,7 +169,7 @@ static struct notifier_block xpc_die_not +diff --git a/drivers/misc/sgi-xp/xpc_main.c b/drivers/misc/sgi-xp/xpc_ma= in.c +index fd3688a..7e211a4 100644 +--- a/drivers/misc/sgi-xp/xpc_main.c ++++ b/drivers/misc/sgi-xp/xpc_main.c +@@ -169,7 +169,7 @@ static struct notifier_block xpc_die_notifier =3D { .notifier_call =3D xpc_system_die, }; =20 @@ -35604,10 +37242,11 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/= xpc_main.c linux-2.6.32.49/driver =20 /* * Timer function to enforce the timelimit on the partition disengage. -diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/xpc_sn2.c linux-2.6.32.49= /drivers/misc/sgi-xp/xpc_sn2.c ---- linux-2.6.32.49/drivers/misc/sgi-xp/xpc_sn2.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-xp/xpc_sn2.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -2350,7 +2350,7 @@ xpc_received_payload_sn2(struct xpc_chan +diff --git a/drivers/misc/sgi-xp/xpc_sn2.c b/drivers/misc/sgi-xp/xpc_sn2= .c +index 8b70e03..700bda6 100644 +--- a/drivers/misc/sgi-xp/xpc_sn2.c ++++ b/drivers/misc/sgi-xp/xpc_sn2.c +@@ -2350,7 +2350,7 @@ xpc_received_payload_sn2(struct xpc_channel *ch, v= oid *payload) xpc_acknowledge_msgs_sn2(ch, get, msg->flags); } =20 @@ -35627,10 +37266,11 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/= xpc_sn2.c linux-2.6.32.49/drivers =20 if (offsetof(struct xpc_msg_sn2, payload) > XPC_MSG_HDR_MAX_SIZE) { dev_err(xpc_part, "header portion of struct xpc_msg_sn2 is " -diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/xpc_uv.c linux-2.6.32.49/= drivers/misc/sgi-xp/xpc_uv.c ---- linux-2.6.32.49/drivers/misc/sgi-xp/xpc_uv.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-xp/xpc_uv.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -1669,7 +1669,7 @@ xpc_received_payload_uv(struct xpc_chann +diff --git a/drivers/misc/sgi-xp/xpc_uv.c b/drivers/misc/sgi-xp/xpc_uv.c +index 8e08d71..7cb8c9b 100644 +--- a/drivers/misc/sgi-xp/xpc_uv.c ++++ b/drivers/misc/sgi-xp/xpc_uv.c +@@ -1669,7 +1669,7 @@ xpc_received_payload_uv(struct xpc_channel *ch, vo= id *payload) XPC_DEACTIVATE_PARTITION(&xpc_partitions[ch->partid], ret); } =20 @@ -35639,7 +37279,7 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/xp= c_uv.c linux-2.6.32.49/drivers/ .setup_partitions =3D xpc_setup_partitions_uv, .teardown_partitions =3D xpc_teardown_partitions_uv, .process_activate_IRQ_rcvd =3D xpc_process_activate_IRQ_rcvd_uv, -@@ -1729,7 +1729,9 @@ static struct xpc_arch_operations xpc_ar +@@ -1729,7 +1729,9 @@ static struct xpc_arch_operations xpc_arch_ops_uv = =3D { int xpc_init_uv(void) { @@ -35650,22 +37290,11 @@ diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/= xpc_uv.c linux-2.6.32.49/drivers/ =20 if (sizeof(struct xpc_notify_mq_msghdr_uv) > XPC_MSG_HDR_MAX_SIZE) { dev_err(xpc_part, "xpc_notify_mq_msghdr_uv is larger than %d\n", -diff -urNp linux-2.6.32.49/drivers/misc/sgi-xp/xp.h linux-2.6.32.49/driv= ers/misc/sgi-xp/xp.h ---- linux-2.6.32.49/drivers/misc/sgi-xp/xp.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/misc/sgi-xp/xp.h 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -289,7 +289,7 @@ struct xpc_interface { - xpc_notify_func, void *); - void (*received) (short, int, void *); - enum xp_retval (*partid_to_nasids) (short, void *); --}; -+} __no_const; -=20 - extern struct xpc_interface xpc_interface; -=20 -diff -urNp linux-2.6.32.49/drivers/mmc/host/sdhci-pci.c linux-2.6.32.49/= drivers/mmc/host/sdhci-pci.c ---- linux-2.6.32.49/drivers/mmc/host/sdhci-pci.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/mmc/host/sdhci-pci.c 2011-11-18 18:01:55.000= 000000 -0500 -@@ -297,7 +297,7 @@ static const struct sdhci_pci_fixes sdhc +diff --git a/drivers/mmc/host/sdhci-pci.c b/drivers/mmc/host/sdhci-pci.c +index 6fd20b42..650efe3 100644 +--- a/drivers/mmc/host/sdhci-pci.c ++++ b/drivers/mmc/host/sdhci-pci.c +@@ -297,7 +297,7 @@ static const struct sdhci_pci_fixes sdhci_via =3D { .probe =3D via_probe, }; =20 @@ -35674,10 +37303,11 @@ diff -urNp linux-2.6.32.49/drivers/mmc/host/sdh= ci-pci.c linux-2.6.32.49/drivers/ { .vendor =3D PCI_VENDOR_ID_RICOH, .device =3D PCI_DEVICE_ID_RICOH_R5C822, -diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_cmdset_0001.c linux-2.6= .32.49/drivers/mtd/chips/cfi_cmdset_0001.c ---- linux-2.6.32.49/drivers/mtd/chips/cfi_cmdset_0001.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/mtd/chips/cfi_cmdset_0001.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -743,6 +743,8 @@ static int chip_ready (struct map_info * +diff --git a/drivers/mtd/chips/cfi_cmdset_0001.c b/drivers/mtd/chips/cfi= _cmdset_0001.c +index e7563a9..5f90ce5 100644 +--- a/drivers/mtd/chips/cfi_cmdset_0001.c ++++ b/drivers/mtd/chips/cfi_cmdset_0001.c +@@ -743,6 +743,8 @@ static int chip_ready (struct map_info *map, struct = flchip *chip, unsigned long struct cfi_pri_intelext *cfip =3D cfi->cmdset_priv; unsigned long timeo =3D jiffies + HZ; =20 @@ -35686,7 +37316,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_= cmdset_0001.c linux-2.6.32.49/d /* Prevent setting state FL_SYNCING for chip in suspended state. */ if (mode =3D=3D FL_SYNCING && chip->oldstate !=3D FL_READY) goto sleep; -@@ -1642,6 +1644,8 @@ static int __xipram do_write_buffer(stru +@@ -1642,6 +1644,8 @@ static int __xipram do_write_buffer(struct map_inf= o *map, struct flchip *chip, unsigned long initial_adr; int initial_len =3D len; =20 @@ -35695,7 +37325,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_= cmdset_0001.c linux-2.6.32.49/d wbufsize =3D cfi_interleave(cfi) << cfi->cfiq->MaxBufWriteSize; adr +=3D chip->start; initial_adr =3D adr; -@@ -1860,6 +1864,8 @@ static int __xipram do_erase_oneblock(st +@@ -1860,6 +1864,8 @@ static int __xipram do_erase_oneblock(struct map_i= nfo *map, struct flchip *chip, int retries =3D 3; int ret; =20 @@ -35704,10 +37334,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cf= i_cmdset_0001.c linux-2.6.32.49/d adr +=3D chip->start; =20 retry: -diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_cmdset_0020.c linux-2.6= .32.49/drivers/mtd/chips/cfi_cmdset_0020.c ---- linux-2.6.32.49/drivers/mtd/chips/cfi_cmdset_0020.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/mtd/chips/cfi_cmdset_0020.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -255,6 +255,8 @@ static inline int do_read_onechip(struct +diff --git a/drivers/mtd/chips/cfi_cmdset_0020.c b/drivers/mtd/chips/cfi= _cmdset_0020.c +index 0667a67..3ab97ed 100644 +--- a/drivers/mtd/chips/cfi_cmdset_0020.c ++++ b/drivers/mtd/chips/cfi_cmdset_0020.c +@@ -255,6 +255,8 @@ static inline int do_read_onechip(struct map_info *m= ap, struct flchip *chip, lof unsigned long cmd_addr; struct cfi_private *cfi =3D map->fldrv_priv; =20 @@ -35716,7 +37347,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_= cmdset_0020.c linux-2.6.32.49/d adr +=3D chip->start; =20 /* Ensure cmd read/writes are aligned. */ -@@ -428,6 +430,8 @@ static inline int do_write_buffer(struct +@@ -428,6 +430,8 @@ static inline int do_write_buffer(struct map_info *m= ap, struct flchip *chip, DECLARE_WAITQUEUE(wait, current); int wbufsize, z; =20 @@ -35725,7 +37356,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_= cmdset_0020.c linux-2.6.32.49/d /* M58LW064A requires bus alignment for buffer wriets -- saw */ if (adr & (map_bankwidth(map)-1)) return -EINVAL; -@@ -742,6 +746,8 @@ static inline int do_erase_oneblock(stru +@@ -742,6 +746,8 @@ static inline int do_erase_oneblock(struct map_info = *map, struct flchip *chip, u DECLARE_WAITQUEUE(wait, current); int ret =3D 0; =20 @@ -35734,7 +37365,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_= cmdset_0020.c linux-2.6.32.49/d adr +=3D chip->start; =20 /* Let's determine this according to the interleave only once */ -@@ -1047,6 +1053,8 @@ static inline int do_lock_oneblock(struc +@@ -1047,6 +1053,8 @@ static inline int do_lock_oneblock(struct map_info= *map, struct flchip *chip, un unsigned long timeo =3D jiffies + HZ; DECLARE_WAITQUEUE(wait, current); =20 @@ -35743,7 +37374,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cfi_= cmdset_0020.c linux-2.6.32.49/d adr +=3D chip->start; =20 /* Let's determine this according to the interleave only once */ -@@ -1196,6 +1204,8 @@ static inline int do_unlock_oneblock(str +@@ -1196,6 +1204,8 @@ static inline int do_unlock_oneblock(struct map_in= fo *map, struct flchip *chip, unsigned long timeo =3D jiffies + HZ; DECLARE_WAITQUEUE(wait, current); =20 @@ -35752,10 +37383,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/chips/cf= i_cmdset_0020.c linux-2.6.32.49/d adr +=3D chip->start; =20 /* Let's determine this according to the interleave only once */ -diff -urNp linux-2.6.32.49/drivers/mtd/devices/doc2000.c linux-2.6.32.49= /drivers/mtd/devices/doc2000.c ---- linux-2.6.32.49/drivers/mtd/devices/doc2000.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/mtd/devices/doc2000.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -776,7 +776,7 @@ static int doc_write(struct mtd_info *mt +diff --git a/drivers/mtd/devices/doc2000.c b/drivers/mtd/devices/doc2000= .c +index 5bf5f46..c5de373 100644 +--- a/drivers/mtd/devices/doc2000.c ++++ b/drivers/mtd/devices/doc2000.c +@@ -776,7 +776,7 @@ static int doc_write(struct mtd_info *mtd, loff_t to= , size_t len, =20 /* The ECC will not be calculated correctly if less than 512 is writt= en */ /* DBB- @@ -35764,10 +37396,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/devices/= doc2000.c linux-2.6.32.49/drivers printk(KERN_WARNING "ECC needs a full sector write (adr: %lx size %lx)\n", (long) to, (long) len); -diff -urNp linux-2.6.32.49/drivers/mtd/devices/doc2001.c linux-2.6.32.49= /drivers/mtd/devices/doc2001.c ---- linux-2.6.32.49/drivers/mtd/devices/doc2001.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/mtd/devices/doc2001.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -393,7 +393,7 @@ static int doc_read (struct mtd_info *mt +diff --git a/drivers/mtd/devices/doc2001.c b/drivers/mtd/devices/doc2001= .c +index 0990f78..bb4e8a4 100644 +--- a/drivers/mtd/devices/doc2001.c ++++ b/drivers/mtd/devices/doc2001.c +@@ -393,7 +393,7 @@ static int doc_read (struct mtd_info *mtd, loff_t fr= om, size_t len, struct Nand *mychip =3D &this->chips[from >> (this->chipshift)]; =20 /* Don't allow read past end of device */ @@ -35776,10 +37409,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/devices/= doc2001.c linux-2.6.32.49/drivers return -EINVAL; =20 /* Don't allow a single read to cross a 512-byte block boundary */ -diff -urNp linux-2.6.32.49/drivers/mtd/ftl.c linux-2.6.32.49/drivers/mtd= /ftl.c ---- linux-2.6.32.49/drivers/mtd/ftl.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/mtd/ftl.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -474,6 +474,8 @@ static int copy_erase_unit(partition_t * +diff --git a/drivers/mtd/ftl.c b/drivers/mtd/ftl.c +index e56d6b4..f07e6cf 100644 +--- a/drivers/mtd/ftl.c ++++ b/drivers/mtd/ftl.c +@@ -474,6 +474,8 @@ static int copy_erase_unit(partition_t *part, uint16= _t srcunit, loff_t offset; uint16_t srcunitswap =3D cpu_to_le16(srcunit); =20 @@ -35788,10 +37422,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/ftl.c li= nux-2.6.32.49/drivers/mtd/ftl.c eun =3D &part->EUNInfo[srcunit]; xfer =3D &part->XferInfo[xferunit]; DEBUG(2, "ftl_cs: copying block 0x%x to 0x%x\n", -diff -urNp linux-2.6.32.49/drivers/mtd/inftlcore.c linux-2.6.32.49/drive= rs/mtd/inftlcore.c ---- linux-2.6.32.49/drivers/mtd/inftlcore.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/mtd/inftlcore.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -260,6 +260,8 @@ static u16 INFTL_foldchain(struct INFTLr +diff --git a/drivers/mtd/inftlcore.c b/drivers/mtd/inftlcore.c +index 8aca552..146446e 100755 +--- a/drivers/mtd/inftlcore.c ++++ b/drivers/mtd/inftlcore.c +@@ -260,6 +260,8 @@ static u16 INFTL_foldchain(struct INFTLrecord *inftl= , unsigned thisVUC, unsigned struct inftl_oob oob; size_t retlen; =20 @@ -35800,10 +37435,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/inftlcor= e.c linux-2.6.32.49/drivers/mtd/i DEBUG(MTD_DEBUG_LEVEL3, "INFTL: INFTL_foldchain(inftl=3D%p,thisVUC=3D%= d," "pending=3D%d)\n", inftl, thisVUC, pendingblock); =20 -diff -urNp linux-2.6.32.49/drivers/mtd/inftlmount.c linux-2.6.32.49/driv= ers/mtd/inftlmount.c ---- linux-2.6.32.49/drivers/mtd/inftlmount.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/mtd/inftlmount.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -54,6 +54,8 @@ static int find_boot_record(struct INFTL +diff --git a/drivers/mtd/inftlmount.c b/drivers/mtd/inftlmount.c +index 32e82ae..ed50953 100644 +--- a/drivers/mtd/inftlmount.c ++++ b/drivers/mtd/inftlmount.c +@@ -54,6 +54,8 @@ static int find_boot_record(struct INFTLrecord *inftl) struct INFTLPartition *ip; size_t retlen; =20 @@ -35812,10 +37448,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/inftlmou= nt.c linux-2.6.32.49/drivers/mtd/ DEBUG(MTD_DEBUG_LEVEL3, "INFTL: find_boot_record(inftl=3D%p)\n", inftl= ); =20 /* -diff -urNp linux-2.6.32.49/drivers/mtd/lpddr/qinfo_probe.c linux-2.6.32.= 49/drivers/mtd/lpddr/qinfo_probe.c ---- linux-2.6.32.49/drivers/mtd/lpddr/qinfo_probe.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/mtd/lpddr/qinfo_probe.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -106,6 +106,8 @@ static int lpddr_pfow_present(struct map +diff --git a/drivers/mtd/lpddr/qinfo_probe.c b/drivers/mtd/lpddr/qinfo_p= robe.c +index 79bf40f..fe5f8fd 100644 +--- a/drivers/mtd/lpddr/qinfo_probe.c ++++ b/drivers/mtd/lpddr/qinfo_probe.c +@@ -106,6 +106,8 @@ static int lpddr_pfow_present(struct map_info *map, = struct lpddr_private *lpddr) { map_word pfow_val[4]; =20 @@ -35824,10 +37461,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/lpddr/qi= nfo_probe.c linux-2.6.32.49/drive /* Check identification string */ pfow_val[0] =3D map_read(map, map->pfow_base + PFOW_QUERY_STRING_P); pfow_val[1] =3D map_read(map, map->pfow_base + PFOW_QUERY_STRING_F); -diff -urNp linux-2.6.32.49/drivers/mtd/mtdchar.c linux-2.6.32.49/drivers= /mtd/mtdchar.c ---- linux-2.6.32.49/drivers/mtd/mtdchar.c 2011-11-26 19:44:53.000000000 = -0500 -+++ linux-2.6.32.49/drivers/mtd/mtdchar.c 2011-11-26 19:45:06.000000000 = -0500 -@@ -461,6 +461,8 @@ static int mtd_ioctl(struct inode *inode +diff --git a/drivers/mtd/mtdchar.c b/drivers/mtd/mtdchar.c +index 726a1b8..f46b460 100644 +--- a/drivers/mtd/mtdchar.c ++++ b/drivers/mtd/mtdchar.c +@@ -461,6 +461,8 @@ static int mtd_ioctl(struct inode *inode, struct fil= e *file, u_long size; struct mtd_info_user info; =20 @@ -35836,10 +37474,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/mtdchar.= c linux-2.6.32.49/drivers/mtd/mtd DEBUG(MTD_DEBUG_LEVEL0, "MTD_ioctl\n"); =20 size =3D (cmd & IOCSIZE_MASK) >> IOCSIZE_SHIFT; -diff -urNp linux-2.6.32.49/drivers/mtd/nftlcore.c linux-2.6.32.49/driver= s/mtd/nftlcore.c ---- linux-2.6.32.49/drivers/mtd/nftlcore.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/mtd/nftlcore.c 2011-11-15 19:59:43.000000000= -0500 -@@ -254,6 +254,8 @@ static u16 NFTL_foldchain (struct NFTLre +diff --git a/drivers/mtd/nftlcore.c b/drivers/mtd/nftlcore.c +index 1002e18..26d82d5 100644 +--- a/drivers/mtd/nftlcore.c ++++ b/drivers/mtd/nftlcore.c +@@ -254,6 +254,8 @@ static u16 NFTL_foldchain (struct NFTLrecord *nftl, = unsigned thisVUC, unsigned p int inplace =3D 1; size_t retlen; =20 @@ -35848,9 +37487,10 @@ diff -urNp linux-2.6.32.49/drivers/mtd/nftlcore.= c linux-2.6.32.49/drivers/mtd/nf memset(BlockMap, 0xff, sizeof(BlockMap)); memset(BlockFreeFound, 0, sizeof(BlockFreeFound)); =20 -diff -urNp linux-2.6.32.49/drivers/mtd/nftlmount.c linux-2.6.32.49/drive= rs/mtd/nftlmount.c ---- linux-2.6.32.49/drivers/mtd/nftlmount.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/mtd/nftlmount.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/mtd/nftlmount.c b/drivers/mtd/nftlmount.c +index 8b22b18..6fada85 100644 +--- a/drivers/mtd/nftlmount.c ++++ b/drivers/mtd/nftlmount.c @@ -23,6 +23,7 @@ #include #include @@ -35859,7 +37499,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/nftlmount.= c linux-2.6.32.49/drivers/mtd/n #include #include #include -@@ -44,6 +45,8 @@ static int find_boot_record(struct NFTLr +@@ -44,6 +45,8 @@ static int find_boot_record(struct NFTLrecord *nftl) struct mtd_info *mtd =3D nftl->mbd.mtd; unsigned int i; =20 @@ -35868,9 +37508,10 @@ diff -urNp linux-2.6.32.49/drivers/mtd/nftlmount= .c linux-2.6.32.49/drivers/mtd/n /* Assume logical EraseSize =3D=3D physical erasesize for start= ing the scan. We'll sort it out later if we find a MediaHeader which says otherwi= se */ /* Actually, we won't. The new DiskOnChip driver has already scanned -diff -urNp linux-2.6.32.49/drivers/mtd/ubi/build.c linux-2.6.32.49/drive= rs/mtd/ubi/build.c ---- linux-2.6.32.49/drivers/mtd/ubi/build.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/mtd/ubi/build.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c +index 14cec04..d775b87 100644 +--- a/drivers/mtd/ubi/build.c ++++ b/drivers/mtd/ubi/build.c @@ -1255,7 +1255,7 @@ module_exit(ubi_exit); static int __init bytes_str_to_int(const char *str) { @@ -35880,7 +37521,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/ubi/build.= c linux-2.6.32.49/drivers/mtd/u =20 result =3D simple_strtoul(str, &endp, 0); if (str =3D=3D endp || result >=3D INT_MAX) { -@@ -1266,11 +1266,11 @@ static int __init bytes_str_to_int(const +@@ -1266,11 +1266,11 @@ static int __init bytes_str_to_int(const char *s= tr) =20 switch (*endp) { case 'G': @@ -35895,7 +37536,7 @@ diff -urNp linux-2.6.32.49/drivers/mtd/ubi/build.= c linux-2.6.32.49/drivers/mtd/u if (endp[1] =3D=3D 'i' && endp[2] =3D=3D 'B') endp +=3D 2; case '\0': -@@ -1281,7 +1281,13 @@ static int __init bytes_str_to_int(const +@@ -1281,7 +1281,13 @@ static int __init bytes_str_to_int(const char *st= r) return -EINVAL; } =20 @@ -35910,10 +37551,11 @@ diff -urNp linux-2.6.32.49/drivers/mtd/ubi/buil= d.c linux-2.6.32.49/drivers/mtd/u } =20 /** -diff -urNp linux-2.6.32.49/drivers/net/atlx/atl2.c linux-2.6.32.49/drive= rs/net/atlx/atl2.c ---- linux-2.6.32.49/drivers/net/atlx/atl2.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/net/atlx/atl2.c 2011-11-18 18:01:55.00000000= 0 -0500 -@@ -2845,7 +2845,7 @@ static void atl2_force_ps(struct atl2_hw +diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c +index ab68886..ca405e8 100644 +--- a/drivers/net/atlx/atl2.c ++++ b/drivers/net/atlx/atl2.c +@@ -2845,7 +2845,7 @@ static void atl2_force_ps(struct atl2_hw *hw) */ =20 #define ATL2_PARAM(X, desc) \ @@ -35922,9 +37564,10 @@ diff -urNp linux-2.6.32.49/drivers/net/atlx/atl2= .c linux-2.6.32.49/drivers/net/a MODULE_PARM(X, "1-" __MODULE_STRING(ATL2_MAX_NIC) "i"); \ MODULE_PARM_DESC(X, desc); #else -diff -urNp linux-2.6.32.49/drivers/net/bnx2.c linux-2.6.32.49/drivers/ne= t/bnx2.c ---- linux-2.6.32.49/drivers/net/bnx2.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/net/bnx2.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c +index 4874b2b..67f8526 100644 +--- a/drivers/net/bnx2.c ++++ b/drivers/net/bnx2.c @@ -5809,6 +5809,8 @@ bnx2_test_nvram(struct bnx2 *bp) int rc =3D 0; u32 magic, csum; @@ -35934,10 +37577,11 @@ diff -urNp linux-2.6.32.49/drivers/net/bnx2.c l= inux-2.6.32.49/drivers/net/bnx2.c if ((rc =3D bnx2_nvram_read(bp, 0, data, 4)) !=3D 0) goto test_nvram_done; =20 -diff -urNp linux-2.6.32.49/drivers/net/cxgb3/l2t.h linux-2.6.32.49/drive= rs/net/cxgb3/l2t.h ---- linux-2.6.32.49/drivers/net/cxgb3/l2t.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/net/cxgb3/l2t.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -86,7 +86,7 @@ typedef void (*arp_failure_handler_func) +diff --git a/drivers/net/cxgb3/l2t.h b/drivers/net/cxgb3/l2t.h +index fd3eb07..8a6978d 100644 +--- a/drivers/net/cxgb3/l2t.h ++++ b/drivers/net/cxgb3/l2t.h +@@ -86,7 +86,7 @@ typedef void (*arp_failure_handler_func)(struct t3cdev= * dev, */ struct l2t_skb_cb { arp_failure_handler_func arp_failure_handler; @@ -35946,10 +37590,11 @@ diff -urNp linux-2.6.32.49/drivers/net/cxgb3/l2= t.h linux-2.6.32.49/drivers/net/c =20 #define L2T_SKB_CB(skb) ((struct l2t_skb_cb *)(skb)->cb) =20 -diff -urNp linux-2.6.32.49/drivers/net/cxgb3/t3_hw.c linux-2.6.32.49/dri= vers/net/cxgb3/t3_hw.c ---- linux-2.6.32.49/drivers/net/cxgb3/t3_hw.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/net/cxgb3/t3_hw.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -699,6 +699,8 @@ static int get_vpd_params(struct adapter +diff --git a/drivers/net/cxgb3/t3_hw.c b/drivers/net/cxgb3/t3_hw.c +index 032cfe0..411af379 100644 +--- a/drivers/net/cxgb3/t3_hw.c ++++ b/drivers/net/cxgb3/t3_hw.c +@@ -699,6 +699,8 @@ static int get_vpd_params(struct adapter *adapter, s= truct vpd_params *p) int i, addr, ret; struct t3_vpd vpd; =20 @@ -35958,10 +37603,11 @@ diff -urNp linux-2.6.32.49/drivers/net/cxgb3/t3= _hw.c linux-2.6.32.49/drivers/net /* * Card information is normally at VPD_BASE but some early cards had * it at 0. -diff -urNp linux-2.6.32.49/drivers/net/e1000e/82571.c linux-2.6.32.49/dr= ivers/net/e1000e/82571.c ---- linux-2.6.32.49/drivers/net/e1000e/82571.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/net/e1000e/82571.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -212,7 +212,7 @@ static s32 e1000_init_mac_params_82571(s +diff --git a/drivers/net/e1000e/82571.c b/drivers/net/e1000e/82571.c +index d1e0563..b9e129c 100644 +--- a/drivers/net/e1000e/82571.c ++++ b/drivers/net/e1000e/82571.c +@@ -212,7 +212,7 @@ static s32 e1000_init_mac_params_82571(struct e1000_= adapter *adapter) { struct e1000_hw *hw =3D &adapter->hw; struct e1000_mac_info *mac =3D &hw->mac; @@ -35970,7 +37616,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/825= 71.c linux-2.6.32.49/drivers/ne u32 swsm =3D 0; u32 swsm2 =3D 0; bool force_clear_smbi =3D false; -@@ -1656,7 +1656,7 @@ static void e1000_clear_hw_cntrs_82571(s +@@ -1656,7 +1656,7 @@ static void e1000_clear_hw_cntrs_82571(struct e100= 0_hw *hw) temp =3D er32(ICRXDMTC); } =20 @@ -35979,7 +37625,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/825= 71.c linux-2.6.32.49/drivers/ne /* .check_mng_mode: mac type dependent */ /* .check_for_link: media type dependent */ .id_led_init =3D e1000e_id_led_init, -@@ -1674,7 +1674,7 @@ static struct e1000_mac_operations e8257 +@@ -1674,7 +1674,7 @@ static struct e1000_mac_operations e82571_mac_ops = =3D { .setup_led =3D e1000e_setup_led_generic, }; =20 @@ -35988,7 +37634,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/825= 71.c linux-2.6.32.49/drivers/ne .acquire_phy =3D e1000_get_hw_semaphore_82571, .check_reset_block =3D e1000e_check_reset_block_generic, .commit_phy =3D NULL, -@@ -1691,7 +1691,7 @@ static struct e1000_phy_operations e82_p +@@ -1691,7 +1691,7 @@ static struct e1000_phy_operations e82_phy_ops_igp= =3D { .cfg_on_link_up =3D NULL, }; =20 @@ -35997,7 +37643,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/825= 71.c linux-2.6.32.49/drivers/ne .acquire_phy =3D e1000_get_hw_semaphore_82571, .check_reset_block =3D e1000e_check_reset_block_generic, .commit_phy =3D e1000e_phy_sw_reset, -@@ -1708,7 +1708,7 @@ static struct e1000_phy_operations e82_p +@@ -1708,7 +1708,7 @@ static struct e1000_phy_operations e82_phy_ops_m88= =3D { .cfg_on_link_up =3D NULL, }; =20 @@ -36006,7 +37652,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/825= 71.c linux-2.6.32.49/drivers/ne .acquire_phy =3D e1000_get_hw_semaphore_82571, .check_reset_block =3D e1000e_check_reset_block_generic, .commit_phy =3D e1000e_phy_sw_reset, -@@ -1725,7 +1725,7 @@ static struct e1000_phy_operations e82_p +@@ -1725,7 +1725,7 @@ static struct e1000_phy_operations e82_phy_ops_bm = =3D { .cfg_on_link_up =3D NULL, }; =20 @@ -36015,9 +37661,10 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/82= 571.c linux-2.6.32.49/drivers/ne .acquire_nvm =3D e1000_acquire_nvm_82571, .read_nvm =3D e1000e_read_nvm_eerd, .release_nvm =3D e1000_release_nvm_82571, -diff -urNp linux-2.6.32.49/drivers/net/e1000e/e1000.h linux-2.6.32.49/dr= ivers/net/e1000e/e1000.h ---- linux-2.6.32.49/drivers/net/e1000e/e1000.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/net/e1000e/e1000.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/drivers/net/e1000e/e1000.h b/drivers/net/e1000e/e1000.h +index 47db9bd..fa58ccd 100644 +--- a/drivers/net/e1000e/e1000.h ++++ b/drivers/net/e1000e/e1000.h @@ -375,9 +375,9 @@ struct e1000_info { u32 pba; u32 max_hw_frame_size; @@ -36031,10 +37678,11 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/e= 1000.h linux-2.6.32.49/drivers/ne }; =20 /* hardware capability, feature, and workaround flags */ -diff -urNp linux-2.6.32.49/drivers/net/e1000e/es2lan.c linux-2.6.32.49/d= rivers/net/e1000e/es2lan.c ---- linux-2.6.32.49/drivers/net/e1000e/es2lan.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/net/e1000e/es2lan.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -207,7 +207,7 @@ static s32 e1000_init_mac_params_80003es +diff --git a/drivers/net/e1000e/es2lan.c b/drivers/net/e1000e/es2lan.c +index ae5d736..e9a93a1 100644 +--- a/drivers/net/e1000e/es2lan.c ++++ b/drivers/net/e1000e/es2lan.c +@@ -207,7 +207,7 @@ static s32 e1000_init_mac_params_80003es2lan(struct = e1000_adapter *adapter) { struct e1000_hw *hw =3D &adapter->hw; struct e1000_mac_info *mac =3D &hw->mac; @@ -36043,7 +37691,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/es2= lan.c linux-2.6.32.49/drivers/n =20 /* Set media type */ switch (adapter->pdev->device) { -@@ -1365,7 +1365,7 @@ static void e1000_clear_hw_cntrs_80003es +@@ -1365,7 +1365,7 @@ static void e1000_clear_hw_cntrs_80003es2lan(struc= t e1000_hw *hw) temp =3D er32(ICRXDMTC); } =20 @@ -36052,7 +37700,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/es2= lan.c linux-2.6.32.49/drivers/n .id_led_init =3D e1000e_id_led_init, .check_mng_mode =3D e1000e_check_mng_mode_generic, /* check_for_link dependent on media type */ -@@ -1383,7 +1383,7 @@ static struct e1000_mac_operations es2_m +@@ -1383,7 +1383,7 @@ static struct e1000_mac_operations es2_mac_ops =3D= { .setup_led =3D e1000e_setup_led_generic, }; =20 @@ -36061,7 +37709,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/es2= lan.c linux-2.6.32.49/drivers/n .acquire_phy =3D e1000_acquire_phy_80003es2lan, .check_reset_block =3D e1000e_check_reset_block_generic, .commit_phy =3D e1000e_phy_sw_reset, -@@ -1400,7 +1400,7 @@ static struct e1000_phy_operations es2_p +@@ -1400,7 +1400,7 @@ static struct e1000_phy_operations es2_phy_ops =3D= { .cfg_on_link_up =3D e1000_cfg_on_link_up_80003es2lan, }; =20 @@ -36070,9 +37718,10 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/es= 2lan.c linux-2.6.32.49/drivers/n .acquire_nvm =3D e1000_acquire_nvm_80003es2lan, .read_nvm =3D e1000e_read_nvm_eerd, .release_nvm =3D e1000_release_nvm_80003es2lan, -diff -urNp linux-2.6.32.49/drivers/net/e1000e/hw.h linux-2.6.32.49/drive= rs/net/e1000e/hw.h ---- linux-2.6.32.49/drivers/net/e1000e/hw.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/net/e1000e/hw.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/net/e1000e/hw.h b/drivers/net/e1000e/hw.h +index 11f3b7c..6381887 100644 +--- a/drivers/net/e1000e/hw.h ++++ b/drivers/net/e1000e/hw.h @@ -753,6 +753,7 @@ struct e1000_mac_operations { s32 (*setup_physical_interface)(struct e1000_hw *); s32 (*setup_led)(struct e1000_hw *); @@ -36119,10 +37768,11 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/h= w.h linux-2.6.32.49/drivers/net/e =20 enum e1000_nvm_type type; enum e1000_nvm_override override; -diff -urNp linux-2.6.32.49/drivers/net/e1000e/ich8lan.c linux-2.6.32.49/= drivers/net/e1000e/ich8lan.c ---- linux-2.6.32.49/drivers/net/e1000e/ich8lan.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/net/e1000e/ich8lan.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -3463,7 +3463,7 @@ static void e1000_clear_hw_cntrs_ich8lan +diff --git a/drivers/net/e1000e/ich8lan.c b/drivers/net/e1000e/ich8lan.c +index de39f9a..e28d3e0 100644 +--- a/drivers/net/e1000e/ich8lan.c ++++ b/drivers/net/e1000e/ich8lan.c +@@ -3463,7 +3463,7 @@ static void e1000_clear_hw_cntrs_ich8lan(struct e1= 000_hw *hw) } } =20 @@ -36131,7 +37781,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/ich= 8lan.c linux-2.6.32.49/drivers/ .id_led_init =3D e1000e_id_led_init, .check_mng_mode =3D e1000_check_mng_mode_ich8lan, .check_for_link =3D e1000_check_for_copper_link_ich8lan, -@@ -3481,7 +3481,7 @@ static struct e1000_mac_operations ich8_ +@@ -3481,7 +3481,7 @@ static struct e1000_mac_operations ich8_mac_ops =3D= { /* id_led_init dependent on mac type */ }; =20 @@ -36140,7 +37790,7 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/ich= 8lan.c linux-2.6.32.49/drivers/ .acquire_phy =3D e1000_acquire_swflag_ich8lan, .check_reset_block =3D e1000_check_reset_block_ich8lan, .commit_phy =3D NULL, -@@ -3497,7 +3497,7 @@ static struct e1000_phy_operations ich8_ +@@ -3497,7 +3497,7 @@ static struct e1000_phy_operations ich8_phy_ops =3D= { .write_phy_reg =3D e1000e_write_phy_reg_igp, }; =20 @@ -36149,9 +37799,10 @@ diff -urNp linux-2.6.32.49/drivers/net/e1000e/ic= h8lan.c linux-2.6.32.49/drivers/ .acquire_nvm =3D e1000_acquire_nvm_ich8lan, .read_nvm =3D e1000_read_nvm_ich8lan, .release_nvm =3D e1000_release_nvm_ich8lan, -diff -urNp linux-2.6.32.49/drivers/net/fealnx.c linux-2.6.32.49/drivers/= net/fealnx.c ---- linux-2.6.32.49/drivers/net/fealnx.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/net/fealnx.c 2011-11-18 18:01:55.000000000 -= 0500 +diff --git a/drivers/net/fealnx.c b/drivers/net/fealnx.c +index 18d5fbb..542d96d 100644 +--- a/drivers/net/fealnx.c ++++ b/drivers/net/fealnx.c @@ -151,7 +151,7 @@ struct chip_info { int flags; }; @@ -36161,10 +37812,11 @@ diff -urNp linux-2.6.32.49/drivers/net/fealnx.c= linux-2.6.32.49/drivers/net/feal { "100/10M Ethernet PCI Adapter", HAS_MII_XCVR }, { "100/10M Ethernet PCI Adapter", HAS_CHIP_XCVR }, { "1000/100/10M Ethernet PCI Adapter", HAS_MII_XCVR }, -diff -urNp linux-2.6.32.49/drivers/net/hamradio/6pack.c linux-2.6.32.49/= drivers/net/hamradio/6pack.c ---- linux-2.6.32.49/drivers/net/hamradio/6pack.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/net/hamradio/6pack.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -461,6 +461,8 @@ static void sixpack_receive_buf(struct t +diff --git a/drivers/net/hamradio/6pack.c b/drivers/net/hamradio/6pack.c +index 0e5b54b..b503f82 100644 +--- a/drivers/net/hamradio/6pack.c ++++ b/drivers/net/hamradio/6pack.c +@@ -461,6 +461,8 @@ static void sixpack_receive_buf(struct tty_struct *t= ty, unsigned char buf[512]; int count1; =20 @@ -36173,10 +37825,11 @@ diff -urNp linux-2.6.32.49/drivers/net/hamradio= /6pack.c linux-2.6.32.49/drivers/ if (!count) return; =20 -diff -urNp linux-2.6.32.49/drivers/net/ibmveth.c linux-2.6.32.49/drivers= /net/ibmveth.c ---- linux-2.6.32.49/drivers/net/ibmveth.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/net/ibmveth.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1577,7 +1577,7 @@ static struct attribute * veth_pool_attr +diff --git a/drivers/net/ibmveth.c b/drivers/net/ibmveth.c +index 5862282..7cce8cb 100644 +--- a/drivers/net/ibmveth.c ++++ b/drivers/net/ibmveth.c +@@ -1577,7 +1577,7 @@ static struct attribute * veth_pool_attrs[] =3D { NULL, }; =20 @@ -36185,10 +37838,11 @@ diff -urNp linux-2.6.32.49/drivers/net/ibmveth.= c linux-2.6.32.49/drivers/net/ibm .show =3D veth_pool_show, .store =3D veth_pool_store, }; -diff -urNp linux-2.6.32.49/drivers/net/igb/e1000_82575.c linux-2.6.32.49= /drivers/net/igb/e1000_82575.c ---- linux-2.6.32.49/drivers/net/igb/e1000_82575.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/net/igb/e1000_82575.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -1411,7 +1411,7 @@ void igb_vmdq_set_replication_pf(struct=20 +diff --git a/drivers/net/igb/e1000_82575.c b/drivers/net/igb/e1000_82575= .c +index d617f2d..57b5309 100644 +--- a/drivers/net/igb/e1000_82575.c ++++ b/drivers/net/igb/e1000_82575.c +@@ -1411,7 +1411,7 @@ void igb_vmdq_set_replication_pf(struct e1000_hw *= hw, bool enable) wr32(E1000_VT_CTL, vt_ctl); } =20 @@ -36197,7 +37851,7 @@ diff -urNp linux-2.6.32.49/drivers/net/igb/e1000_= 82575.c linux-2.6.32.49/drivers .reset_hw =3D igb_reset_hw_82575, .init_hw =3D igb_init_hw_82575, .check_for_link =3D igb_check_for_link_82575, -@@ -1420,13 +1420,13 @@ static struct e1000_mac_operations e1000 +@@ -1420,13 +1420,13 @@ static struct e1000_mac_operations e1000_mac_ops= _82575 =3D { .get_speed_and_duplex =3D igb_get_speed_and_duplex_copper, }; =20 @@ -36213,9 +37867,10 @@ diff -urNp linux-2.6.32.49/drivers/net/igb/e1000= _82575.c linux-2.6.32.49/drivers .acquire =3D igb_acquire_nvm_82575, .read =3D igb_read_nvm_eerd, .release =3D igb_release_nvm_82575, -diff -urNp linux-2.6.32.49/drivers/net/igb/e1000_hw.h linux-2.6.32.49/dr= ivers/net/igb/e1000_hw.h ---- linux-2.6.32.49/drivers/net/igb/e1000_hw.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/net/igb/e1000_hw.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/drivers/net/igb/e1000_hw.h b/drivers/net/igb/e1000_hw.h +index 72081df..d855cf5 100644 +--- a/drivers/net/igb/e1000_hw.h ++++ b/drivers/net/igb/e1000_hw.h @@ -288,6 +288,7 @@ struct e1000_mac_operations { s32 (*read_mac_addr)(struct e1000_hw *); s32 (*get_speed_and_duplex)(struct e1000_hw *, u16 *, u16 *); @@ -36284,9 +37939,10 @@ diff -urNp linux-2.6.32.49/drivers/net/igb/e1000= _hw.h linux-2.6.32.49/drivers/ne struct e1000_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-2.6.32.49/drivers/net/igbvf/vf.h linux-2.6.32.49/driver= s/net/igbvf/vf.h ---- linux-2.6.32.49/drivers/net/igbvf/vf.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/net/igbvf/vf.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/drivers/net/igbvf/vf.h b/drivers/net/igbvf/vf.h +index 1e8ce37..549c453 100644 +--- a/drivers/net/igbvf/vf.h ++++ b/drivers/net/igbvf/vf.h @@ -187,9 +187,10 @@ struct e1000_mac_operations { s32 (*read_mac_addr)(struct e1000_hw *); s32 (*set_vfta)(struct e1000_hw *, u16, bool); @@ -36316,10 +37972,11 @@ diff -urNp linux-2.6.32.49/drivers/net/igbvf/vf= .h linux-2.6.32.49/drivers/net/ig struct e1000_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-2.6.32.49/drivers/net/iseries_veth.c linux-2.6.32.49/dr= ivers/net/iseries_veth.c ---- linux-2.6.32.49/drivers/net/iseries_veth.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/net/iseries_veth.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -384,7 +384,7 @@ static struct attribute *veth_cnx_defaul +diff --git a/drivers/net/iseries_veth.c b/drivers/net/iseries_veth.c +index aa7286b..a61394f 100644 +--- a/drivers/net/iseries_veth.c ++++ b/drivers/net/iseries_veth.c +@@ -384,7 +384,7 @@ static struct attribute *veth_cnx_default_attrs[] =3D= { NULL }; =20 @@ -36328,7 +37985,7 @@ diff -urNp linux-2.6.32.49/drivers/net/iseries_ve= th.c linux-2.6.32.49/drivers/ne .show =3D veth_cnx_attribute_show }; =20 -@@ -441,7 +441,7 @@ static struct attribute *veth_port_defau +@@ -441,7 +441,7 @@ static struct attribute *veth_port_default_attrs[] =3D= { NULL }; =20 @@ -36337,10 +37994,11 @@ diff -urNp linux-2.6.32.49/drivers/net/iseries_= veth.c linux-2.6.32.49/drivers/ne .show =3D veth_port_attribute_show }; =20 -diff -urNp linux-2.6.32.49/drivers/net/ixgb/ixgb_main.c linux-2.6.32.49/= drivers/net/ixgb/ixgb_main.c ---- linux-2.6.32.49/drivers/net/ixgb/ixgb_main.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/net/ixgb/ixgb_main.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -1052,6 +1052,8 @@ ixgb_set_multi(struct net_device *netdev +diff --git a/drivers/net/ixgb/ixgb_main.c b/drivers/net/ixgb/ixgb_main.c +index 8aa44dc..fa1e797 100644 +--- a/drivers/net/ixgb/ixgb_main.c ++++ b/drivers/net/ixgb/ixgb_main.c +@@ -1052,6 +1052,8 @@ ixgb_set_multi(struct net_device *netdev) u32 rctl; int i; =20 @@ -36349,9 +38007,10 @@ diff -urNp linux-2.6.32.49/drivers/net/ixgb/ixgb= _main.c linux-2.6.32.49/drivers/ /* Check for Promiscuous and All Multicast modes */ =20 rctl =3D IXGB_READ_REG(hw, RCTL); -diff -urNp linux-2.6.32.49/drivers/net/ixgb/ixgb_param.c linux-2.6.32.49= /drivers/net/ixgb/ixgb_param.c ---- linux-2.6.32.49/drivers/net/ixgb/ixgb_param.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/net/ixgb/ixgb_param.c 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/drivers/net/ixgb/ixgb_param.c b/drivers/net/ixgb/ixgb_param= .c +index af35e1d..8781785 100644 +--- a/drivers/net/ixgb/ixgb_param.c ++++ b/drivers/net/ixgb/ixgb_param.c @@ -260,6 +260,9 @@ void __devinit ixgb_check_options(struct ixgb_adapter *adapter) { @@ -36362,9 +38021,10 @@ diff -urNp linux-2.6.32.49/drivers/net/ixgb/ixgb= _param.c linux-2.6.32.49/drivers if (bd >=3D IXGB_MAX_NIC) { printk(KERN_NOTICE "Warning: no configuration for board #%i\n", bd); -diff -urNp linux-2.6.32.49/drivers/net/ixgbe/ixgbe_type.h linux-2.6.32.4= 9/drivers/net/ixgbe/ixgbe_type.h ---- linux-2.6.32.49/drivers/net/ixgbe/ixgbe_type.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/net/ixgbe/ixgbe_type.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/net/ixgbe/ixgbe_type.h b/drivers/net/ixgbe/ixgbe_ty= pe.h +index b17aa73..ed74540 100644 +--- a/drivers/net/ixgbe/ixgbe_type.h ++++ b/drivers/net/ixgbe/ixgbe_type.h @@ -2327,6 +2327,7 @@ struct ixgbe_eeprom_operations { s32 (*validate_checksum)(struct ixgbe_hw *, u16 *); s32 (*update_checksum)(struct ixgbe_hw *); @@ -36411,9 +38071,10 @@ diff -urNp linux-2.6.32.49/drivers/net/ixgbe/ixg= be_type.h linux-2.6.32.49/driver struct mdio_if_info mdio; enum ixgbe_phy_type type; u32 id; -diff -urNp linux-2.6.32.49/drivers/net/mlx4/main.c linux-2.6.32.49/drive= rs/net/mlx4/main.c ---- linux-2.6.32.49/drivers/net/mlx4/main.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/net/mlx4/main.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/net/mlx4/main.c b/drivers/net/mlx4/main.c +index 291a505..2543756 100644 +--- a/drivers/net/mlx4/main.c ++++ b/drivers/net/mlx4/main.c @@ -38,6 +38,7 @@ #include #include @@ -36422,7 +38083,7 @@ diff -urNp linux-2.6.32.49/drivers/net/mlx4/main.= c linux-2.6.32.49/drivers/net/m =20 #include #include -@@ -730,6 +731,8 @@ static int mlx4_init_hca(struct mlx4_dev +@@ -730,6 +731,8 @@ static int mlx4_init_hca(struct mlx4_dev *dev) u64 icm_size; int err; =20 @@ -36431,10 +38092,11 @@ diff -urNp linux-2.6.32.49/drivers/net/mlx4/mai= n.c linux-2.6.32.49/drivers/net/m err =3D mlx4_QUERY_FW(dev); if (err) { if (err =3D=3D -EACCES) -diff -urNp linux-2.6.32.49/drivers/net/niu.c linux-2.6.32.49/drivers/net= /niu.c ---- linux-2.6.32.49/drivers/net/niu.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/net/niu.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -9128,6 +9128,8 @@ static void __devinit niu_try_msix(struc +diff --git a/drivers/net/niu.c b/drivers/net/niu.c +index 2dce134..fa5ce75 100644 +--- a/drivers/net/niu.c ++++ b/drivers/net/niu.c +@@ -9128,6 +9128,8 @@ static void __devinit niu_try_msix(struct niu *np,= u8 *ldg_num_map) int i, num_irqs, err; u8 first_ldg; =20 @@ -36443,9 +38105,10 @@ diff -urNp linux-2.6.32.49/drivers/net/niu.c lin= ux-2.6.32.49/drivers/net/niu.c first_ldg =3D (NIU_NUM_LDG / parent->num_ports) * np->port; for (i =3D 0; i < (NIU_NUM_LDG / parent->num_ports); i++) ldg_num_map[i] =3D first_ldg + i; -diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c linux-2.6.32.49/drivers= /net/pcnet32.c ---- linux-2.6.32.49/drivers/net/pcnet32.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/net/pcnet32.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/net/pcnet32.c b/drivers/net/pcnet32.c +index c1b3f09..97cd8c4 100644 +--- a/drivers/net/pcnet32.c ++++ b/drivers/net/pcnet32.c @@ -79,7 +79,7 @@ static int cards_found; /* * VLB I/O addresses @@ -36464,7 +38127,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn spinlock_t lock; /* Guard lock */ unsigned int cur_rx, cur_tx; /* The next free ring entry */ unsigned int rx_ring_size; /* current rx ring size */ -@@ -457,9 +457,9 @@ static void pcnet32_netif_start(struct n +@@ -457,9 +457,9 @@ static void pcnet32_netif_start(struct net_device *d= ev) u16 val; =20 netif_wake_queue(dev); @@ -36476,7 +38139,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn napi_enable(&lp->napi); } =20 -@@ -744,7 +744,7 @@ static u32 pcnet32_get_link(struct net_d +@@ -744,7 +744,7 @@ static u32 pcnet32_get_link(struct net_device *dev) r =3D mii_link_ok(&lp->mii_if); } else if (lp->chip_version >=3D PCNET32_79C970A) { ulong ioaddr =3D dev->base_addr; /* card base I/O address */ @@ -36485,7 +38148,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } else { /* can not detect link on really old chips */ r =3D 1; } -@@ -806,7 +806,7 @@ static int pcnet32_set_ringparam(struct=20 +@@ -806,7 +806,7 @@ static int pcnet32_set_ringparam(struct net_device *= dev, pcnet32_netif_stop(dev); =20 spin_lock_irqsave(&lp->lock, flags); @@ -36494,7 +38157,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 size =3D min(ering->tx_pending, (unsigned int)TX_MAX_RING_SIZE); =20 -@@ -886,7 +886,7 @@ static void pcnet32_ethtool_test(struct=20 +@@ -886,7 +886,7 @@ static void pcnet32_ethtool_test(struct net_device *= dev, static int pcnet32_loopback_test(struct net_device *dev, uint64_t * dat= a1) { struct pcnet32_private *lp =3D netdev_priv(dev); @@ -36503,7 +38166,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn ulong ioaddr =3D dev->base_addr; /* card base I/O address */ struct sk_buff *skb; /* sk buff */ int x, i; /* counters */ -@@ -906,21 +906,21 @@ static int pcnet32_loopback_test(struct=20 +@@ -906,21 +906,21 @@ static int pcnet32_loopback_test(struct net_device= *dev, uint64_t * data1) pcnet32_netif_stop(dev); =20 spin_lock_irqsave(&lp->lock, flags); @@ -36530,7 +38193,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 /* Initialize Transmit buffers. */ size =3D data_len + 15; -@@ -966,10 +966,10 @@ static int pcnet32_loopback_test(struct=20 +@@ -966,10 +966,10 @@ static int pcnet32_loopback_test(struct net_device= *dev, uint64_t * data1) =20 /* set int loopback in CSR15 */ x =3D a->read_csr(ioaddr, CSR15) & 0xfffc; @@ -36543,7 +38206,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 /* Check status of descriptors */ for (x =3D 0; x < numbuffs; x++) { -@@ -990,7 +990,7 @@ static int pcnet32_loopback_test(struct=20 +@@ -990,7 +990,7 @@ static int pcnet32_loopback_test(struct net_device *= dev, uint64_t * data1) } } =20 @@ -36552,7 +38215,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn wmb(); if (netif_msg_hw(lp) && netif_msg_pktdata(lp)) { printk(KERN_DEBUG "%s: RX loopback packets:\n", dev->name); -@@ -1039,7 +1039,7 @@ static int pcnet32_loopback_test(struct=20 +@@ -1039,7 +1039,7 @@ static int pcnet32_loopback_test(struct net_device= *dev, uint64_t * data1) pcnet32_restart(dev, CSR0_NORMAL); } else { pcnet32_purge_rx_ring(dev); @@ -36561,7 +38224,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } spin_unlock_irqrestore(&lp->lock, flags); =20 -@@ -1049,7 +1049,7 @@ static int pcnet32_loopback_test(struct=20 +@@ -1049,7 +1049,7 @@ static int pcnet32_loopback_test(struct net_device= *dev, uint64_t * data1) static void pcnet32_led_blink_callback(struct net_device *dev) { struct pcnet32_private *lp =3D netdev_priv(dev); @@ -36570,7 +38233,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn ulong ioaddr =3D dev->base_addr; unsigned long flags; int i; -@@ -1066,7 +1066,7 @@ static void pcnet32_led_blink_callback(s +@@ -1066,7 +1066,7 @@ static void pcnet32_led_blink_callback(struct net_= device *dev) static int pcnet32_phys_id(struct net_device *dev, u32 data) { struct pcnet32_private *lp =3D netdev_priv(dev); @@ -36579,7 +38242,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn ulong ioaddr =3D dev->base_addr; unsigned long flags; int i, regs[4]; -@@ -1112,7 +1112,7 @@ static int pcnet32_suspend(struct net_de +@@ -1112,7 +1112,7 @@ static int pcnet32_suspend(struct net_device *dev,= unsigned long *flags, { int csr5; struct pcnet32_private *lp =3D netdev_priv(dev); @@ -36588,7 +38251,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn ulong ioaddr =3D dev->base_addr; int ticks; =20 -@@ -1388,8 +1388,8 @@ static int pcnet32_poll(struct napi_stru +@@ -1388,8 +1388,8 @@ static int pcnet32_poll(struct napi_struct *napi, = int budget) spin_lock_irqsave(&lp->lock, flags); if (pcnet32_tx(dev)) { /* reset the chip to clear the error condition, then restart */ @@ -36599,7 +38262,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn pcnet32_restart(dev, CSR0_START); netif_wake_queue(dev); } -@@ -1401,12 +1401,12 @@ static int pcnet32_poll(struct napi_stru +@@ -1401,12 +1401,12 @@ static int pcnet32_poll(struct napi_struct *napi= , int budget) __napi_complete(napi); =20 /* clear interrupt masks */ @@ -36615,7 +38278,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 spin_unlock_irqrestore(&lp->lock, flags); } -@@ -1429,7 +1429,7 @@ static void pcnet32_get_regs(struct net_ +@@ -1429,7 +1429,7 @@ static void pcnet32_get_regs(struct net_device *de= v, struct ethtool_regs *regs, int i, csr0; u16 *buff =3D ptr; struct pcnet32_private *lp =3D netdev_priv(dev); @@ -36624,7 +38287,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn ulong ioaddr =3D dev->base_addr; unsigned long flags; =20 -@@ -1466,9 +1466,9 @@ static void pcnet32_get_regs(struct net_ +@@ -1466,9 +1466,9 @@ static void pcnet32_get_regs(struct net_device *de= v, struct ethtool_regs *regs, for (j =3D 0; j < PCNET32_MAX_PHYS; j++) { if (lp->phymask & (1 << j)) { for (i =3D 0; i < PCNET32_REGS_PER_PHY; i++) { @@ -36636,7 +38299,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } } } -@@ -1858,7 +1858,7 @@ pcnet32_probe1(unsigned long ioaddr, int +@@ -1858,7 +1858,7 @@ pcnet32_probe1(unsigned long ioaddr, int shared, s= truct pci_dev *pdev) ((cards_found >=3D MAX_UNITS) || full_duplex[cards_found])) lp->options |=3D PCNET32_PORT_FD; =20 @@ -36645,7 +38308,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 /* prior to register_netdev, dev->name is not yet correct */ if (pcnet32_alloc_ring(dev, pci_name(lp->pci_dev))) { -@@ -1917,7 +1917,7 @@ pcnet32_probe1(unsigned long ioaddr, int +@@ -1917,7 +1917,7 @@ pcnet32_probe1(unsigned long ioaddr, int shared, s= truct pci_dev *pdev) if (lp->mii) { /* lp->phycount and lp->phymask are set to 0 by memset above */ =20 @@ -36654,7 +38317,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn /* scan for PHYs */ for (i =3D 0; i < PCNET32_MAX_PHYS; i++) { unsigned short id1, id2; -@@ -1938,7 +1938,7 @@ pcnet32_probe1(unsigned long ioaddr, int +@@ -1938,7 +1938,7 @@ pcnet32_probe1(unsigned long ioaddr, int shared, s= truct pci_dev *pdev) "Found PHY %04x:%04x at address %d.\n", id1, id2, i); } @@ -36663,7 +38326,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn if (lp->phycount > 1) { lp->options |=3D PCNET32_PORT_MII; } -@@ -2109,10 +2109,10 @@ static int pcnet32_open(struct net_devic +@@ -2109,10 +2109,10 @@ static int pcnet32_open(struct net_device *dev) } =20 /* Reset the PCNET32 */ @@ -36676,7 +38339,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 if (netif_msg_ifup(lp)) printk(KERN_DEBUG -@@ -2122,14 +2122,14 @@ static int pcnet32_open(struct net_devic +@@ -2122,14 +2122,14 @@ static int pcnet32_open(struct net_device *dev) (u32) (lp->init_dma_addr)); =20 /* set/reset autoselect bit */ @@ -36694,7 +38357,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn if (lp->options & PCNET32_PORT_FD) { val |=3D 1; if (lp->options =3D=3D (PCNET32_PORT_FD | PCNET32_PORT_AUI)) -@@ -2139,14 +2139,14 @@ static int pcnet32_open(struct net_devic +@@ -2139,14 +2139,14 @@ static int pcnet32_open(struct net_device *dev) if (lp->chip_version =3D=3D 0x2627) val |=3D 3; } @@ -36712,7 +38375,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 /* Allied Telesyn AT 2700/2701 FX are 100Mbit only and do not negotiat= e */ if (pdev && pdev->subsystem_vendor =3D=3D PCI_VENDOR_ID_AT && -@@ -2167,24 +2167,24 @@ static int pcnet32_open(struct net_devic +@@ -2167,24 +2167,24 @@ static int pcnet32_open(struct net_device *dev) * duplex, and/or enable auto negotiation, and clear DANAS */ if (lp->mii && !(lp->options & PCNET32_PORT_ASEL)) { @@ -36745,7 +38408,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } } } else { -@@ -2197,10 +2197,10 @@ static int pcnet32_open(struct net_devic +@@ -2197,10 +2197,10 @@ static int pcnet32_open(struct net_device *dev) * There is really no good other way to handle multiple PHYs * other than turning off all automatics */ @@ -36760,7 +38423,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 if (!(lp->options & PCNET32_PORT_ASEL)) { /* setup ecmd */ -@@ -2210,7 +2210,7 @@ static int pcnet32_open(struct net_devic +@@ -2210,7 +2210,7 @@ static int pcnet32_open(struct net_device *dev) ecmd.speed =3D lp-> options & PCNET32_PORT_100 ? SPEED_100 : SPEED_10; @@ -36769,7 +38432,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 if (lp->options & PCNET32_PORT_FD) { ecmd.duplex =3D DUPLEX_FULL; -@@ -2219,7 +2219,7 @@ static int pcnet32_open(struct net_devic +@@ -2219,7 +2219,7 @@ static int pcnet32_open(struct net_device *dev) ecmd.duplex =3D DUPLEX_HALF; bcr9 |=3D ~(1 << 0); } @@ -36778,7 +38441,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } =20 for (i =3D 0; i < PCNET32_MAX_PHYS; i++) { -@@ -2252,9 +2252,9 @@ static int pcnet32_open(struct net_devic +@@ -2252,9 +2252,9 @@ static int pcnet32_open(struct net_device *dev) =20 #ifdef DO_DXSUFLO if (lp->dxsuflo) { /* Disable transmit stop on underflow */ @@ -36790,7 +38453,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } #endif =20 -@@ -2270,11 +2270,11 @@ static int pcnet32_open(struct net_devic +@@ -2270,11 +2270,11 @@ static int pcnet32_open(struct net_device *dev) napi_enable(&lp->napi); =20 /* Re-initialize the PCNET32, and start it when done. */ @@ -36806,7 +38469,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 netif_start_queue(dev); =20 -@@ -2286,20 +2286,20 @@ static int pcnet32_open(struct net_devic +@@ -2286,20 +2286,20 @@ static int pcnet32_open(struct net_device *dev) =20 i =3D 0; while (i++ < 100) @@ -36830,7 +38493,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 spin_unlock_irqrestore(&lp->lock, flags); =20 -@@ -2313,7 +2313,7 @@ static int pcnet32_open(struct net_devic +@@ -2313,7 +2313,7 @@ static int pcnet32_open(struct net_device *dev) * Switch back to 16bit mode to avoid problems with dumb * DOS packet driver after a warm reboot */ @@ -36839,7 +38502,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 err_free_irq: spin_unlock_irqrestore(&lp->lock, flags); -@@ -2420,7 +2420,7 @@ static void pcnet32_restart(struct net_d +@@ -2420,7 +2420,7 @@ static void pcnet32_restart(struct net_device *dev= , unsigned int csr0_bits) =20 /* wait for stop */ for (i =3D 0; i < 100; i++) @@ -36848,7 +38511,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn break; =20 if (i >=3D 100 && netif_msg_drv(lp)) -@@ -2433,13 +2433,13 @@ static void pcnet32_restart(struct net_d +@@ -2433,13 +2433,13 @@ static void pcnet32_restart(struct net_device *d= ev, unsigned int csr0_bits) return; =20 /* ReInit Ring */ @@ -36865,7 +38528,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } =20 static void pcnet32_tx_timeout(struct net_device *dev) -@@ -2452,8 +2452,8 @@ static void pcnet32_tx_timeout(struct ne +@@ -2452,8 +2452,8 @@ static void pcnet32_tx_timeout(struct net_device *= dev) if (pcnet32_debug & NETIF_MSG_DRV) printk(KERN_ERR "%s: transmit timed out, status %4.4x, resetting.\n", @@ -36876,7 +38539,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn dev->stats.tx_errors++; if (netif_msg_tx_err(lp)) { int i; -@@ -2497,7 +2497,7 @@ static netdev_tx_t pcnet32_start_xmit(st +@@ -2497,7 +2497,7 @@ static netdev_tx_t pcnet32_start_xmit(struct sk_bu= ff *skb, if (netif_msg_tx_queued(lp)) { printk(KERN_DEBUG "%s: pcnet32_start_xmit() called, csr0 %4.4x.\n", @@ -36885,7 +38548,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } =20 /* Default status -- will not enable Successful-TxDone -@@ -2528,7 +2528,7 @@ static netdev_tx_t pcnet32_start_xmit(st +@@ -2528,7 +2528,7 @@ static netdev_tx_t pcnet32_start_xmit(struct sk_bu= ff *skb, dev->stats.tx_bytes +=3D skb->len; =20 /* Trigger an immediate send poll. */ @@ -36940,7 +38603,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 spin_unlock(&lp->lock); =20 -@@ -2627,21 +2627,21 @@ static int pcnet32_close(struct net_devi +@@ -2627,21 +2627,21 @@ static int pcnet32_close(struct net_device *dev) =20 spin_lock_irqsave(&lp->lock, flags); =20 @@ -36966,7 +38629,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 spin_unlock_irqrestore(&lp->lock, flags); =20 -@@ -2664,7 +2664,7 @@ static struct net_device_stats *pcnet32_ +@@ -2664,7 +2664,7 @@ static struct net_device_stats *pcnet32_get_stats(= struct net_device *dev) unsigned long flags; =20 spin_lock_irqsave(&lp->lock, flags); @@ -36975,7 +38638,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn spin_unlock_irqrestore(&lp->lock, flags); =20 return &dev->stats; -@@ -2686,10 +2686,10 @@ static void pcnet32_load_multicast(struc +@@ -2686,10 +2686,10 @@ static void pcnet32_load_multicast(struct net_de= vice *dev) if (dev->flags & IFF_ALLMULTI) { ib->filter[0] =3D cpu_to_le32(~0U); ib->filter[1] =3D cpu_to_le32(~0U); @@ -36990,7 +38653,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn return; } /* clear the multicast filter */ -@@ -2710,7 +2710,7 @@ static void pcnet32_load_multicast(struc +@@ -2710,7 +2710,7 @@ static void pcnet32_load_multicast(struct net_devi= ce *dev) mcast_table[crc >> 4] |=3D cpu_to_le16(1 << (crc & 0xf)); } for (i =3D 0; i < 4; i++) @@ -36999,7 +38662,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn le16_to_cpu(mcast_table[i])); return; } -@@ -2726,7 +2726,7 @@ static void pcnet32_set_multicast_list(s +@@ -2726,7 +2726,7 @@ static void pcnet32_set_multicast_list(struct net_= device *dev) =20 spin_lock_irqsave(&lp->lock, flags); suspended =3D pcnet32_suspend(dev, &flags, 0); @@ -37008,7 +38671,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn if (dev->flags & IFF_PROMISC) { /* Log any net taps. */ if (netif_msg_hw(lp)) -@@ -2735,21 +2735,21 @@ static void pcnet32_set_multicast_list(s +@@ -2735,21 +2735,21 @@ static void pcnet32_set_multicast_list(struct ne= t_device *dev) lp->init_block->mode =3D cpu_to_le16(0x8000 | (lp->options & PCNET32_PORT_PORTSEL) << 7); @@ -37035,7 +38698,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn pcnet32_restart(dev, CSR0_NORMAL); netif_wake_queue(dev); } -@@ -2767,8 +2767,8 @@ static int mdio_read(struct net_device * +@@ -2767,8 +2767,8 @@ static int mdio_read(struct net_device *dev, int p= hy_id, int reg_num) if (!lp->mii) return 0; =20 @@ -37046,7 +38709,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn =20 return val_out; } -@@ -2782,8 +2782,8 @@ static void mdio_write(struct net_device +@@ -2782,8 +2782,8 @@ static void mdio_write(struct net_device *dev, int= phy_id, int reg_num, int val) if (!lp->mii) return; =20 @@ -37057,7 +38720,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } =20 static int pcnet32_ioctl(struct net_device *dev, struct ifreq *rq, int = cmd) -@@ -2862,7 +2862,7 @@ static void pcnet32_check_media(struct n +@@ -2862,7 +2862,7 @@ static void pcnet32_check_media(struct net_device = *dev, int verbose) curr_link =3D mii_link_ok(&lp->mii_if); } else { ulong ioaddr =3D dev->base_addr; /* card base I/O address */ @@ -37066,7 +38729,7 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.c = linux-2.6.32.49/drivers/net/pcn } if (!curr_link) { if (prev_link || verbose) { -@@ -2887,13 +2887,13 @@ static void pcnet32_check_media(struct n +@@ -2887,13 +2887,13 @@ static void pcnet32_check_media(struct net_devic= e *dev, int verbose) (ecmd.duplex =3D=3D DUPLEX_FULL) ? "full" : "half"); } @@ -37082,10 +38745,11 @@ diff -urNp linux-2.6.32.49/drivers/net/pcnet32.= c linux-2.6.32.49/drivers/net/pcn } } else { if (netif_msg_link(lp)) -diff -urNp linux-2.6.32.49/drivers/net/sis190.c linux-2.6.32.49/drivers/= net/sis190.c ---- linux-2.6.32.49/drivers/net/sis190.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/net/sis190.c 2011-11-18 18:01:55.000000000 -= 0500 -@@ -1598,7 +1598,7 @@ static int __devinit sis190_get_mac_addr +diff --git a/drivers/net/sis190.c b/drivers/net/sis190.c +index 7cc9898..6eb50d3 100644 +--- a/drivers/net/sis190.c ++++ b/drivers/net/sis190.c +@@ -1598,7 +1598,7 @@ static int __devinit sis190_get_mac_addr_from_eepr= om(struct pci_dev *pdev, static int __devinit sis190_get_mac_addr_from_apc(struct pci_dev *pdev, struct net_device *dev) { @@ -37094,9 +38758,10 @@ diff -urNp linux-2.6.32.49/drivers/net/sis190.c = linux-2.6.32.49/drivers/net/sis1 struct sis190_private *tp =3D netdev_priv(dev); struct pci_dev *isa_bridge; u8 reg, tmp8; -diff -urNp linux-2.6.32.49/drivers/net/sundance.c linux-2.6.32.49/driver= s/net/sundance.c ---- linux-2.6.32.49/drivers/net/sundance.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/net/sundance.c 2011-11-18 18:01:55.000000000= -0500 +diff --git a/drivers/net/sundance.c b/drivers/net/sundance.c +index e13685a..60c948c 100644 +--- a/drivers/net/sundance.c ++++ b/drivers/net/sundance.c @@ -225,7 +225,7 @@ enum { struct pci_id_info { const char *name; @@ -37106,9 +38771,10 @@ diff -urNp linux-2.6.32.49/drivers/net/sundance.= c linux-2.6.32.49/drivers/net/su {"D-Link DFE-550TX FAST Ethernet Adapter"}, {"D-Link DFE-550FX 100Mbps Fiber-optics Adapter"}, {"D-Link DFE-580TX 4 port Server Adapter"}, -diff -urNp linux-2.6.32.49/drivers/net/tg3.h linux-2.6.32.49/drivers/net= /tg3.h ---- linux-2.6.32.49/drivers/net/tg3.h 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/net/tg3.h 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h +index 529f55a..cccaa18 100644 +--- a/drivers/net/tg3.h ++++ b/drivers/net/tg3.h @@ -95,6 +95,7 @@ #define CHIPREV_ID_5750_A0 0x4000 #define CHIPREV_ID_5750_A1 0x4001 @@ -37117,10 +38783,11 @@ diff -urNp linux-2.6.32.49/drivers/net/tg3.h li= nux-2.6.32.49/drivers/net/tg3.h #define CHIPREV_ID_5750_C2 0x4202 #define CHIPREV_ID_5752_A0_HW 0x5000 #define CHIPREV_ID_5752_A0 0x6000 -diff -urNp linux-2.6.32.49/drivers/net/tokenring/abyss.c linux-2.6.32.49= /drivers/net/tokenring/abyss.c ---- linux-2.6.32.49/drivers/net/tokenring/abyss.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/net/tokenring/abyss.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -451,10 +451,12 @@ static struct pci_driver abyss_driver =3D=20 +diff --git a/drivers/net/tokenring/abyss.c b/drivers/net/tokenring/abyss= .c +index b9db1b5..720f9ce 100644 +--- a/drivers/net/tokenring/abyss.c ++++ b/drivers/net/tokenring/abyss.c +@@ -451,10 +451,12 @@ static struct pci_driver abyss_driver =3D { =20 static int __init abyss_init (void) { @@ -37136,10 +38803,11 @@ diff -urNp linux-2.6.32.49/drivers/net/tokenrin= g/abyss.c linux-2.6.32.49/drivers =20 return pci_register_driver(&abyss_driver); } -diff -urNp linux-2.6.32.49/drivers/net/tokenring/madgemc.c linux-2.6.32.= 49/drivers/net/tokenring/madgemc.c ---- linux-2.6.32.49/drivers/net/tokenring/madgemc.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/net/tokenring/madgemc.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -755,9 +755,11 @@ static struct mca_driver madgemc_driver=20 +diff --git a/drivers/net/tokenring/madgemc.c b/drivers/net/tokenring/mad= gemc.c +index 456f8bf..373e56d 100644 +--- a/drivers/net/tokenring/madgemc.c ++++ b/drivers/net/tokenring/madgemc.c +@@ -755,9 +755,11 @@ static struct mca_driver madgemc_driver =3D { =20 static int __init madgemc_init (void) { @@ -37154,9 +38822,10 @@ diff -urNp linux-2.6.32.49/drivers/net/tokenring= /madgemc.c linux-2.6.32.49/drive =20 return mca_register_driver (&madgemc_driver); } -diff -urNp linux-2.6.32.49/drivers/net/tokenring/proteon.c linux-2.6.32.= 49/drivers/net/tokenring/proteon.c ---- linux-2.6.32.49/drivers/net/tokenring/proteon.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/net/tokenring/proteon.c 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/net/tokenring/proteon.c b/drivers/net/tokenring/pro= teon.c +index 16e8783..925bd49 100644 +--- a/drivers/net/tokenring/proteon.c ++++ b/drivers/net/tokenring/proteon.c @@ -353,9 +353,11 @@ static int __init proteon_init(void) struct platform_device *pdev; int i, num =3D 0, err =3D 0; @@ -37172,9 +38841,10 @@ diff -urNp linux-2.6.32.49/drivers/net/tokenring= /proteon.c linux-2.6.32.49/drive =20 err =3D platform_driver_register(&proteon_driver); if (err) -diff -urNp linux-2.6.32.49/drivers/net/tokenring/skisa.c linux-2.6.32.49= /drivers/net/tokenring/skisa.c ---- linux-2.6.32.49/drivers/net/tokenring/skisa.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/net/tokenring/skisa.c 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/drivers/net/tokenring/skisa.c b/drivers/net/tokenring/skisa= .c +index 46db5c5..37c1536 100644 +--- a/drivers/net/tokenring/skisa.c ++++ b/drivers/net/tokenring/skisa.c @@ -363,9 +363,11 @@ static int __init sk_isa_init(void) struct platform_device *pdev; int i, num =3D 0, err =3D 0; @@ -37190,10 +38860,11 @@ diff -urNp linux-2.6.32.49/drivers/net/tokenrin= g/skisa.c linux-2.6.32.49/drivers =20 err =3D platform_driver_register(&sk_isa_driver); if (err) -diff -urNp linux-2.6.32.49/drivers/net/tulip/de2104x.c linux-2.6.32.49/d= rivers/net/tulip/de2104x.c ---- linux-2.6.32.49/drivers/net/tulip/de2104x.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/net/tulip/de2104x.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -1785,6 +1785,8 @@ static void __devinit de21041_get_srom_i +diff --git a/drivers/net/tulip/de2104x.c b/drivers/net/tulip/de2104x.c +index 74e5ba4..5cf6bc9 100644 +--- a/drivers/net/tulip/de2104x.c ++++ b/drivers/net/tulip/de2104x.c +@@ -1785,6 +1785,8 @@ static void __devinit de21041_get_srom_info (struc= t de_private *de) struct de_srom_info_leaf *il; void *bufp; =20 @@ -37202,10 +38873,11 @@ diff -urNp linux-2.6.32.49/drivers/net/tulip/de= 2104x.c linux-2.6.32.49/drivers/n /* download entire eeprom */ for (i =3D 0; i < DE_EEPROM_WORDS; i++) ((__le16 *)ee_data)[i] =3D -diff -urNp linux-2.6.32.49/drivers/net/tulip/de4x5.c linux-2.6.32.49/dri= vers/net/tulip/de4x5.c ---- linux-2.6.32.49/drivers/net/tulip/de4x5.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/net/tulip/de4x5.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -5472,7 +5472,7 @@ de4x5_ioctl(struct net_device *dev, stru +diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c +index a8349b7..90f9dfe 100644 +--- a/drivers/net/tulip/de4x5.c ++++ b/drivers/net/tulip/de4x5.c +@@ -5472,7 +5472,7 @@ de4x5_ioctl(struct net_device *dev, struct ifreq *= rq, int cmd) for (i=3D0; idev_addr[i]; } @@ -37214,7 +38886,7 @@ diff -urNp linux-2.6.32.49/drivers/net/tulip/de4x= 5.c linux-2.6.32.49/drivers/net break; =20 case DE4X5_SET_HWADDR: /* Set the hardware address */ -@@ -5512,7 +5512,7 @@ de4x5_ioctl(struct net_device *dev, stru +@@ -5512,7 +5512,7 @@ de4x5_ioctl(struct net_device *dev, struct ifreq *= rq, int cmd) spin_lock_irqsave(&lp->lock, flags); memcpy(&statbuf, &lp->pktStats, ioc->len); spin_unlock_irqrestore(&lp->lock, flags); @@ -37223,10 +38895,11 @@ diff -urNp linux-2.6.32.49/drivers/net/tulip/de= 4x5.c linux-2.6.32.49/drivers/net return -EFAULT; break; } -diff -urNp linux-2.6.32.49/drivers/net/tulip/eeprom.c linux-2.6.32.49/dr= ivers/net/tulip/eeprom.c ---- linux-2.6.32.49/drivers/net/tulip/eeprom.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/net/tulip/eeprom.c 2011-11-18 18:01:55.00000= 0000 -0500 -@@ -80,7 +80,7 @@ static struct eeprom_fixup eeprom_fixups +diff --git a/drivers/net/tulip/eeprom.c b/drivers/net/tulip/eeprom.c +index 391acd3..56d11cd 100644 +--- a/drivers/net/tulip/eeprom.c ++++ b/drivers/net/tulip/eeprom.c +@@ -80,7 +80,7 @@ static struct eeprom_fixup eeprom_fixups[] __devinitda= ta =3D { {NULL}}; =20 =20 @@ -37235,9 +38908,10 @@ diff -urNp linux-2.6.32.49/drivers/net/tulip/eep= rom.c linux-2.6.32.49/drivers/ne "21140 non-MII", "21140 MII PHY", "21142 Serial PHY", -diff -urNp linux-2.6.32.49/drivers/net/tulip/winbond-840.c linux-2.6.32.= 49/drivers/net/tulip/winbond-840.c ---- linux-2.6.32.49/drivers/net/tulip/winbond-840.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/net/tulip/winbond-840.c 2011-11-18 18:01:55.= 000000000 -0500 +diff --git a/drivers/net/tulip/winbond-840.c b/drivers/net/tulip/winbond= -840.c +index b38d3b7..b1cff23 100644 +--- a/drivers/net/tulip/winbond-840.c ++++ b/drivers/net/tulip/winbond-840.c @@ -235,7 +235,7 @@ struct pci_id_info { int drv_flags; /* Driver use, intended as capability flags. */ }; @@ -37247,9 +38921,10 @@ diff -urNp linux-2.6.32.49/drivers/net/tulip/win= bond-840.c linux-2.6.32.49/drive { /* Sometime a Level-One switch card. */ "Winbond W89c840", CanHaveMII | HasBrokenTx | FDXOnNoMII}, { "Winbond W89c840", CanHaveMII | HasBrokenTx}, -diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c linux-2.6.32.49/drivers= /net/usb/hso.c ---- linux-2.6.32.49/drivers/net/usb/hso.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/net/usb/hso.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c +index f450bc9..2b747c8 100644 +--- a/drivers/net/usb/hso.c ++++ b/drivers/net/usb/hso.c @@ -71,7 +71,7 @@ #include #include @@ -37268,7 +38943,7 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c = linux-2.6.32.49/drivers/net/usb spinlock_t serial_lock; =20 int (*write_data) (struct hso_serial *serial); -@@ -1180,7 +1180,7 @@ static void put_rxbuf_data_and_resubmit_ +@@ -1180,7 +1180,7 @@ static void put_rxbuf_data_and_resubmit_ctrl_urb(s= truct hso_serial *serial) struct urb *urb; =20 urb =3D serial->rx_urb[0]; @@ -37277,7 +38952,7 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c = linux-2.6.32.49/drivers/net/usb count =3D put_rxbuf_data(urb, serial); if (count =3D=3D -1) return; -@@ -1216,7 +1216,7 @@ static void hso_std_serial_read_bulk_cal +@@ -1216,7 +1216,7 @@ static void hso_std_serial_read_bulk_callback(stru= ct urb *urb) DUMP1(urb->transfer_buffer, urb->actual_length); =20 /* Anyone listening? */ @@ -37286,7 +38961,7 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c = linux-2.6.32.49/drivers/net/usb return; =20 if (status =3D=3D 0) { -@@ -1311,8 +1311,7 @@ static int hso_serial_open(struct tty_st +@@ -1311,8 +1311,7 @@ static int hso_serial_open(struct tty_struct *tty,= struct file *filp) spin_unlock_irq(&serial->serial_lock); =20 /* check for port already opened, if not set the termios */ @@ -37296,7 +38971,7 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c = linux-2.6.32.49/drivers/net/usb tty->low_latency =3D 1; serial->rx_state =3D RX_IDLE; /* Force default termio settings */ -@@ -1325,7 +1324,7 @@ static int hso_serial_open(struct tty_st +@@ -1325,7 +1324,7 @@ static int hso_serial_open(struct tty_struct *tty,= struct file *filp) result =3D hso_start_serial_device(serial->parent, GFP_KERNEL); if (result) { hso_stop_serial_device(serial->parent); @@ -37305,7 +38980,7 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c = linux-2.6.32.49/drivers/net/usb kref_put(&serial->parent->ref, hso_serial_ref_free); } } else { -@@ -1362,10 +1361,10 @@ static void hso_serial_close(struct tty_ +@@ -1362,10 +1361,10 @@ static void hso_serial_close(struct tty_struct *= tty, struct file *filp) =20 /* reset the rts and dtr */ /* do the actual close */ @@ -37319,7 +38994,7 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c = linux-2.6.32.49/drivers/net/usb spin_lock_irq(&serial->serial_lock); if (serial->tty =3D=3D tty) { serial->tty->driver_data =3D NULL; -@@ -1447,7 +1446,7 @@ static void hso_serial_set_termios(struc +@@ -1447,7 +1446,7 @@ static void hso_serial_set_termios(struct tty_stru= ct *tty, struct ktermios *old) =20 /* the actual setup */ spin_lock_irqsave(&serial->serial_lock, flags); @@ -37328,7 +39003,7 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c = linux-2.6.32.49/drivers/net/usb _hso_serial_set_termios(tty, old); else tty->termios =3D old; -@@ -3097,7 +3096,7 @@ static int hso_resume(struct usb_interfa +@@ -3097,7 +3096,7 @@ static int hso_resume(struct usb_interface *iface) /* Start all serial ports */ for (i =3D 0; i < HSO_SERIAL_TTY_MINORS; i++) { if (serial_table[i] && (serial_table[i]->interface =3D=3D iface)) { @@ -37337,9 +39012,10 @@ diff -urNp linux-2.6.32.49/drivers/net/usb/hso.c= linux-2.6.32.49/drivers/net/usb result =3D hso_start_serial_device(serial_table[i], GFP_NOIO); hso_kick_transmit(dev2ser(serial_table[i])); -diff -urNp linux-2.6.32.49/drivers/net/vxge/vxge-config.h linux-2.6.32.4= 9/drivers/net/vxge/vxge-config.h ---- linux-2.6.32.49/drivers/net/vxge/vxge-config.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/net/vxge/vxge-config.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/net/vxge/vxge-config.h b/drivers/net/vxge/vxge-conf= ig.h +index 3e94f0c..ffdd926 100644 +--- a/drivers/net/vxge/vxge-config.h ++++ b/drivers/net/vxge/vxge-config.h @@ -474,7 +474,7 @@ struct vxge_hw_uld_cbs { void (*link_down)(struct __vxge_hw_device *devh); void (*crit_err)(struct __vxge_hw_device *devh, @@ -37349,10 +39025,11 @@ diff -urNp linux-2.6.32.49/drivers/net/vxge/vxg= e-config.h linux-2.6.32.49/driver =20 /* * struct __vxge_hw_blockpool_entry - Block private data structure -diff -urNp linux-2.6.32.49/drivers/net/vxge/vxge-main.c linux-2.6.32.49/= drivers/net/vxge/vxge-main.c ---- linux-2.6.32.49/drivers/net/vxge/vxge-main.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/net/vxge/vxge-main.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -93,6 +93,8 @@ static inline void VXGE_COMPLETE_VPATH_T +diff --git a/drivers/net/vxge/vxge-main.c b/drivers/net/vxge/vxge-main.c +index 068d7a9..35293de 100644 +--- a/drivers/net/vxge/vxge-main.c ++++ b/drivers/net/vxge/vxge-main.c +@@ -93,6 +93,8 @@ static inline void VXGE_COMPLETE_VPATH_TX(struct vxge_= fifo *fifo) struct sk_buff *completed[NR_SKB_COMPLETED]; int more; =20 @@ -37361,7 +39038,7 @@ diff -urNp linux-2.6.32.49/drivers/net/vxge/vxge-= main.c linux-2.6.32.49/drivers/ do { more =3D 0; skb_ptr =3D completed; -@@ -1779,6 +1781,8 @@ static enum vxge_hw_status vxge_rth_conf +@@ -1779,6 +1781,8 @@ static enum vxge_hw_status vxge_rth_configure(stru= ct vxgedev *vdev) u8 mtable[256] =3D {0}; /* CPU to vpath mapping */ int index; =20 @@ -37370,9 +39047,10 @@ diff -urNp linux-2.6.32.49/drivers/net/vxge/vxge= -main.c linux-2.6.32.49/drivers/ /* * Filling * - itable with bucket numbers -diff -urNp linux-2.6.32.49/drivers/net/vxge/vxge-traffic.h linux-2.6.32.= 49/drivers/net/vxge/vxge-traffic.h ---- linux-2.6.32.49/drivers/net/vxge/vxge-traffic.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/net/vxge/vxge-traffic.h 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/net/vxge/vxge-traffic.h b/drivers/net/vxge/vxge-tra= ffic.h +index 461742b..81be42e 100644 +--- a/drivers/net/vxge/vxge-traffic.h ++++ b/drivers/net/vxge/vxge-traffic.h @@ -2123,7 +2123,7 @@ struct vxge_hw_mempool_cbs { struct vxge_hw_mempool_dma *dma_object, u32 index, @@ -37382,10 +39060,11 @@ diff -urNp linux-2.6.32.49/drivers/net/vxge/vxg= e-traffic.h linux-2.6.32.49/drive =20 void __vxge_hw_mempool_destroy( -diff -urNp linux-2.6.32.49/drivers/net/wan/cycx_x25.c linux-2.6.32.49/dr= ivers/net/wan/cycx_x25.c ---- linux-2.6.32.49/drivers/net/wan/cycx_x25.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/net/wan/cycx_x25.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -1017,6 +1017,8 @@ static void hex_dump(char *msg, unsigned +diff --git a/drivers/net/wan/cycx_x25.c b/drivers/net/wan/cycx_x25.c +index cd8cb95..4153b79 100644 +--- a/drivers/net/wan/cycx_x25.c ++++ b/drivers/net/wan/cycx_x25.c +@@ -1017,6 +1017,8 @@ static void hex_dump(char *msg, unsigned char *p, = int len) unsigned char hex[1024], * phex =3D hex; =20 @@ -37394,10 +39073,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wan/cycx= _x25.c linux-2.6.32.49/drivers/ne if (len >=3D (sizeof(hex) / 2)) len =3D (sizeof(hex) / 2) - 1; =20 -diff -urNp linux-2.6.32.49/drivers/net/wan/hdlc_x25.c linux-2.6.32.49/dr= ivers/net/wan/hdlc_x25.c ---- linux-2.6.32.49/drivers/net/wan/hdlc_x25.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/net/wan/hdlc_x25.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -136,16 +136,16 @@ static netdev_tx_t x25_xmit(struct sk_bu +diff --git a/drivers/net/wan/hdlc_x25.c b/drivers/net/wan/hdlc_x25.c +index aa9248f..a4e3c3b 100644 +--- a/drivers/net/wan/hdlc_x25.c ++++ b/drivers/net/wan/hdlc_x25.c +@@ -136,16 +136,16 @@ static netdev_tx_t x25_xmit(struct sk_buff *skb, s= truct net_device *dev) =20 static int x25_open(struct net_device *dev) { @@ -37422,10 +39102,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wan/hdlc= _x25.c linux-2.6.32.49/drivers/ne result =3D lapb_register(dev, &cb); if (result !=3D LAPB_OK) return result; -diff -urNp linux-2.6.32.49/drivers/net/wimax/i2400m/usb-fw.c linux-2.6.3= 2.49/drivers/net/wimax/i2400m/usb-fw.c ---- linux-2.6.32.49/drivers/net/wimax/i2400m/usb-fw.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wimax/i2400m/usb-fw.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -263,6 +263,8 @@ ssize_t i2400mu_bus_bm_wait_for_ack(stru +diff --git a/drivers/net/wimax/i2400m/usb-fw.c b/drivers/net/wimax/i2400= m/usb-fw.c +index 5ad287c..783b020 100644 +--- a/drivers/net/wimax/i2400m/usb-fw.c ++++ b/drivers/net/wimax/i2400m/usb-fw.c +@@ -263,6 +263,8 @@ ssize_t i2400mu_bus_bm_wait_for_ack(struct i2400m *i= 2400m, int do_autopm =3D 1; DECLARE_COMPLETION_ONSTACK(notif_completion); =20 @@ -37434,10 +39115,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wimax/i2= 400m/usb-fw.c linux-2.6.32.49/dri d_fnstart(8, dev, "(i2400m %p ack %p size %zu)\n", i2400m, ack, ack_size); BUG_ON(_ack =3D=3D i2400m->bm_ack_buf); -diff -urNp linux-2.6.32.49/drivers/net/wireless/airo.c linux-2.6.32.49/d= rivers/net/wireless/airo.c ---- linux-2.6.32.49/drivers/net/wireless/airo.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/airo.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -3003,6 +3003,8 @@ static void airo_process_scan_results (s +diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c +index 6c26840..62c97c3 100644 +--- a/drivers/net/wireless/airo.c ++++ b/drivers/net/wireless/airo.c +@@ -3003,6 +3003,8 @@ static void airo_process_scan_results (struct airo= _info *ai) { BSSListElement * loop_net; BSSListElement * tmp_net; =20 @@ -37446,7 +39128,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/a= iro.c linux-2.6.32.49/drivers/n /* Blow away current list of scan results */ list_for_each_entry_safe (loop_net, tmp_net, &ai->network_list, list) = { list_move_tail (&loop_net->list, &ai->network_free_list); -@@ -3783,6 +3785,8 @@ static u16 setup_card(struct airo_info * +@@ -3783,6 +3785,8 @@ static u16 setup_card(struct airo_info *ai, u8 *ma= c, int lock) WepKeyRid wkr; int rc; =20 @@ -37455,7 +39137,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/a= iro.c linux-2.6.32.49/drivers/n memset( &mySsid, 0, sizeof( mySsid ) ); kfree (ai->flash); ai->flash =3D NULL; -@@ -4758,6 +4762,8 @@ static int proc_stats_rid_open( struct i +@@ -4758,6 +4762,8 @@ static int proc_stats_rid_open( struct inode *inod= e, __le32 *vals =3D stats.vals; int len; =20 @@ -37464,7 +39146,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/a= iro.c linux-2.6.32.49/drivers/n if ((file->private_data =3D kzalloc(sizeof(struct proc_data ), GFP_KER= NEL)) =3D=3D NULL) return -ENOMEM; data =3D (struct proc_data *)file->private_data; -@@ -5487,6 +5493,8 @@ static int proc_BSSList_open( struct ino +@@ -5487,6 +5493,8 @@ static int proc_BSSList_open( struct inode *inode,= struct file *file ) { /* If doLoseSync is not 1, we won't do a Lose Sync */ int doLoseSync =3D -1; =20 @@ -37473,7 +39155,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/a= iro.c linux-2.6.32.49/drivers/n if ((file->private_data =3D kzalloc(sizeof(struct proc_data ), GFP_KER= NEL)) =3D=3D NULL) return -ENOMEM; data =3D (struct proc_data *)file->private_data; -@@ -7193,6 +7201,8 @@ static int airo_get_aplist(struct net_de +@@ -7193,6 +7201,8 @@ static int airo_get_aplist(struct net_device *dev, int i; int loseSync =3D capable(CAP_NET_ADMIN) ? 1: -1; =20 @@ -37482,7 +39164,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/a= iro.c linux-2.6.32.49/drivers/n qual =3D kmalloc(IW_MAX_AP * sizeof(*qual), GFP_KERNEL); if (!qual) return -ENOMEM; -@@ -7753,6 +7763,8 @@ static void airo_read_wireless_stats(str +@@ -7753,6 +7763,8 @@ static void airo_read_wireless_stats(struct airo_i= nfo *local) CapabilityRid cap_rid; __le32 *vals =3D stats_rid.vals; =20 @@ -37491,10 +39173,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /airo.c linux-2.6.32.49/drivers/n /* Get stats out of the card */ clear_bit(JOB_WSTATS, &local->jobs); if (local->power.event) { -diff -urNp linux-2.6.32.49/drivers/net/wireless/ath/ath5k/debug.c linux-= 2.6.32.49/drivers/net/wireless/ath/ath5k/debug.c ---- linux-2.6.32.49/drivers/net/wireless/ath/ath5k/debug.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/ath/ath5k/debug.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -205,6 +205,8 @@ static ssize_t read_file_beacon(struct f +diff --git a/drivers/net/wireless/ath/ath5k/debug.c b/drivers/net/wirele= ss/ath/ath5k/debug.c +index 747508c..82e965d 100644 +--- a/drivers/net/wireless/ath/ath5k/debug.c ++++ b/drivers/net/wireless/ath/ath5k/debug.c +@@ -205,6 +205,8 @@ static ssize_t read_file_beacon(struct file *file, c= har __user *user_buf, unsigned int v; u64 tsf; =20 @@ -37503,7 +39186,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/a= th/ath5k/debug.c linux-2.6.32.4 v =3D ath5k_hw_reg_read(sc->ah, AR5K_BEACON); len +=3D snprintf(buf+len, sizeof(buf)-len, "%-24s0x%08x\tintval: %d\tTIM: 0x%x\n", -@@ -318,6 +320,8 @@ static ssize_t read_file_debug(struct fi +@@ -318,6 +320,8 @@ static ssize_t read_file_debug(struct file *file, ch= ar __user *user_buf, unsigned int len =3D 0; unsigned int i; =20 @@ -37512,10 +39195,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /ath/ath5k/debug.c linux-2.6.32.4 len +=3D snprintf(buf+len, sizeof(buf)-len, "DEBUG LEVEL: 0x%08x\n\n", sc->debug.level); =20 -diff -urNp linux-2.6.32.49/drivers/net/wireless/ath/ath9k/debug.c linux-= 2.6.32.49/drivers/net/wireless/ath/ath9k/debug.c ---- linux-2.6.32.49/drivers/net/wireless/ath/ath9k/debug.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/ath/ath9k/debug.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -220,6 +220,8 @@ static ssize_t read_file_interrupt(struc +diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wirele= ss/ath/ath9k/debug.c +index 2be4c22..593b1eb 100644 +--- a/drivers/net/wireless/ath/ath9k/debug.c ++++ b/drivers/net/wireless/ath/ath9k/debug.c +@@ -220,6 +220,8 @@ static ssize_t read_file_interrupt(struct file *file= , char __user *user_buf, char buf[512]; unsigned int len =3D 0; =20 @@ -37524,7 +39208,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/a= th/ath9k/debug.c linux-2.6.32.4 len +=3D snprintf(buf + len, sizeof(buf) - len, "%8s: %10u\n", "RX", sc->debug.stats.istats.rxok); len +=3D snprintf(buf + len, sizeof(buf) - len, -@@ -360,6 +362,8 @@ static ssize_t read_file_wiphy(struct fi +@@ -360,6 +362,8 @@ static ssize_t read_file_wiphy(struct file *file, ch= ar __user *user_buf, int i; u8 addr[ETH_ALEN]; =20 @@ -37533,9 +39217,10 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/= ath/ath9k/debug.c linux-2.6.32.4 len +=3D snprintf(buf + len, sizeof(buf) - len, "primary: %s (%s chan=3D%d ht=3D%d)\n", wiphy_name(sc->pri_wiphy->hw->wiphy), -diff -urNp linux-2.6.32.49/drivers/net/wireless/b43/debugfs.c linux-2.6.= 32.49/drivers/net/wireless/b43/debugfs.c ---- linux-2.6.32.49/drivers/net/wireless/b43/debugfs.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/b43/debugfs.c 2011-11-15 19:59:= 43.000000000 -0500 +diff --git a/drivers/net/wireless/b43/debugfs.c b/drivers/net/wireless/b= 43/debugfs.c +index 80b19a4..dab3a45 100644 +--- a/drivers/net/wireless/b43/debugfs.c ++++ b/drivers/net/wireless/b43/debugfs.c @@ -43,7 +43,7 @@ static struct dentry *rootdir; struct b43_debugfs_fops { ssize_t (*read)(struct b43_wldev *dev, char *buf, size_t bufsize); @@ -37545,9 +39230,10 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/= b43/debugfs.c linux-2.6.32.49/dr /* Offset of struct b43_dfs_file in struct b43_dfsentry */ size_t file_struct_offset; }; -diff -urNp linux-2.6.32.49/drivers/net/wireless/b43legacy/debugfs.c linu= x-2.6.32.49/drivers/net/wireless/b43legacy/debugfs.c ---- linux-2.6.32.49/drivers/net/wireless/b43legacy/debugfs.c 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/b43legacy/debugfs.c 2011-11-15 = 19:59:43.000000000 -0500 +diff --git a/drivers/net/wireless/b43legacy/debugfs.c b/drivers/net/wire= less/b43legacy/debugfs.c +index 1f85ac5..c99b4b4 100644 +--- a/drivers/net/wireless/b43legacy/debugfs.c ++++ b/drivers/net/wireless/b43legacy/debugfs.c @@ -44,7 +44,7 @@ static struct dentry *rootdir; struct b43legacy_debugfs_fops { ssize_t (*read)(struct b43legacy_wldev *dev, char *buf, size_t bufsize= ); @@ -37557,10 +39243,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /b43legacy/debugfs.c linux-2.6.32 /* Offset of struct b43legacy_dfs_file in struct b43legacy_dfsentry */ size_t file_struct_offset; /* Take wl->irq_lock before calling read/write? */ -diff -urNp linux-2.6.32.49/drivers/net/wireless/ipw2x00/ipw2100.c linux-= 2.6.32.49/drivers/net/wireless/ipw2x00/ipw2100.c ---- linux-2.6.32.49/drivers/net/wireless/ipw2x00/ipw2100.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/ipw2x00/ipw2100.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -2014,6 +2014,8 @@ static int ipw2100_set_essid(struct ipw2 +diff --git a/drivers/net/wireless/ipw2x00/ipw2100.c b/drivers/net/wirele= ss/ipw2x00/ipw2100.c +index 43102bf..3b569c3 100644 +--- a/drivers/net/wireless/ipw2x00/ipw2100.c ++++ b/drivers/net/wireless/ipw2x00/ipw2100.c +@@ -2014,6 +2014,8 @@ static int ipw2100_set_essid(struct ipw2100_priv *= priv, char *essid, int err; DECLARE_SSID_BUF(ssid); =20 @@ -37569,7 +39256,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/i= pw2x00/ipw2100.c linux-2.6.32.4 IPW_DEBUG_HC("SSID: '%s'\n", print_ssid(ssid, essid, ssid_len)); =20 if (ssid_len) -@@ -5380,6 +5382,8 @@ static int ipw2100_set_key(struct ipw210 +@@ -5380,6 +5382,8 @@ static int ipw2100_set_key(struct ipw2100_priv *pr= iv, struct ipw2100_wep_key *wep_key =3D (void *)cmd.host_command_parameter= s; int err; =20 @@ -37578,10 +39265,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /ipw2x00/ipw2100.c linux-2.6.32.4 IPW_DEBUG_HC("WEP_KEY_INFO: index =3D %d, len =3D %d/%d\n", idx, keylen, len); =20 -diff -urNp linux-2.6.32.49/drivers/net/wireless/ipw2x00/libipw_rx.c linu= x-2.6.32.49/drivers/net/wireless/ipw2x00/libipw_rx.c ---- linux-2.6.32.49/drivers/net/wireless/ipw2x00/libipw_rx.c 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/ipw2x00/libipw_rx.c 2011-11-15 = 19:59:43.000000000 -0500 -@@ -1566,6 +1566,8 @@ static void libipw_process_probe_respons +diff --git a/drivers/net/wireless/ipw2x00/libipw_rx.c b/drivers/net/wire= less/ipw2x00/libipw_rx.c +index 282b1f7..169f0cf 100644 +--- a/drivers/net/wireless/ipw2x00/libipw_rx.c ++++ b/drivers/net/wireless/ipw2x00/libipw_rx.c +@@ -1566,6 +1566,8 @@ static void libipw_process_probe_response(struct l= ibipw_device unsigned long flags; DECLARE_SSID_BUF(ssid); =20 @@ -37590,10 +39278,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /ipw2x00/libipw_rx.c linux-2.6.32 LIBIPW_DEBUG_SCAN("'%s' (%pM" "): %c%c%c%c %c%c%c%c-%c%c%c%c %c%c%c%c\n", print_ssid(ssid, info_element->data, info_element->len), -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-1000.c linux= -2.6.32.49/drivers/net/wireless/iwlwifi/iwl-1000.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-1000.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-1000.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -137,7 +137,7 @@ static struct iwl_lib_ops iwl1000_lib =3D=20 +diff --git a/drivers/net/wireless/iwlwifi/iwl-1000.c b/drivers/net/wirel= ess/iwlwifi/iwl-1000.c +index 950267a..80d5fd2 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-1000.c ++++ b/drivers/net/wireless/iwlwifi/iwl-1000.c +@@ -137,7 +137,7 @@ static struct iwl_lib_ops iwl1000_lib =3D { }, }; =20 @@ -37602,24 +39291,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-1000.c linux-2.6.32. .ucode =3D &iwl5000_ucode, .lib =3D &iwl1000_lib, .hcmd =3D &iwl5000_hcmd, -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl3945-base.c l= inux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl3945-base.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl3945-base.c 2011-11-= 08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl3945-base.c 2011-11-= 15 19:59:43.000000000 -0500 -@@ -3927,7 +3927,9 @@ static int iwl3945_pci_probe(struct pci_ - */ - if (iwl3945_mod_params.disable_hw_scan) { - IWL_DEBUG_INFO(priv, "Disabling hw_scan\n"); -- iwl3945_hw_ops.hw_scan =3D NULL; -+ pax_open_kernel(); -+ *(void **)&iwl3945_hw_ops.hw_scan =3D NULL; -+ pax_close_kernel(); - } -=20 -=20 -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-3945.c linux= -2.6.32.49/drivers/net/wireless/iwlwifi/iwl-3945.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-3945.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-3945.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -2874,7 +2874,7 @@ static struct iwl_hcmd_utils_ops iwl3945 +diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wirel= ess/iwlwifi/iwl-3945.c +index 56bfcc3..b348020 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-3945.c ++++ b/drivers/net/wireless/iwlwifi/iwl-3945.c +@@ -2874,7 +2874,7 @@ static struct iwl_hcmd_utils_ops iwl3945_hcmd_util= s =3D { .build_addsta_hcmd =3D iwl3945_build_addsta_hcmd, }; =20 @@ -37628,10 +39304,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-3945.c linux-2.6.32. .ucode =3D &iwl3945_ucode, .lib =3D &iwl3945_lib, .hcmd =3D &iwl3945_hcmd, -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-4965.c linux= -2.6.32.49/drivers/net/wireless/iwlwifi/iwl-4965.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-4965.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-4965.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -2345,7 +2345,7 @@ static struct iwl_lib_ops iwl4965_lib =3D=20 +diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wirel= ess/iwlwifi/iwl-4965.c +index 585b8d4..e142963 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-4965.c ++++ b/drivers/net/wireless/iwlwifi/iwl-4965.c +@@ -2345,7 +2345,7 @@ static struct iwl_lib_ops iwl4965_lib =3D { }, }; =20 @@ -37640,10 +39317,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-4965.c linux-2.6.32. .ucode =3D &iwl4965_ucode, .lib =3D &iwl4965_lib, .hcmd =3D &iwl4965_hcmd, -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-5000.c linux= -2.6.32.49/drivers/net/wireless/iwlwifi/iwl-5000.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-5000.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-5000.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -1633,14 +1633,14 @@ static struct iwl_lib_ops iwl5150_lib =3D=20 +diff --git a/drivers/net/wireless/iwlwifi/iwl-5000.c b/drivers/net/wirel= ess/iwlwifi/iwl-5000.c +index 1f423f2..e37c192 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-5000.c ++++ b/drivers/net/wireless/iwlwifi/iwl-5000.c +@@ -1633,14 +1633,14 @@ static struct iwl_lib_ops iwl5150_lib =3D { }, }; =20 @@ -37660,10 +39338,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-5000.c linux-2.6.32. .ucode =3D &iwl5000_ucode, .lib =3D &iwl5150_lib, .hcmd =3D &iwl5000_hcmd, -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-6000.c linux= -2.6.32.49/drivers/net/wireless/iwlwifi/iwl-6000.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-6000.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-6000.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -146,7 +146,7 @@ static struct iwl_hcmd_utils_ops iwl6000 +diff --git a/drivers/net/wireless/iwlwifi/iwl-6000.c b/drivers/net/wirel= ess/iwlwifi/iwl-6000.c +index 1473452..f07d5e1 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-6000.c ++++ b/drivers/net/wireless/iwlwifi/iwl-6000.c +@@ -146,7 +146,7 @@ static struct iwl_hcmd_utils_ops iwl6000_hcmd_utils = =3D { .calc_rssi =3D iwl5000_calc_rssi, }; =20 @@ -37672,24 +39351,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-6000.c linux-2.6.32. .ucode =3D &iwl5000_ucode, .lib =3D &iwl6000_lib, .hcmd =3D &iwl5000_hcmd, -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn.c linux-= 2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -2911,7 +2911,9 @@ static int iwl_pci_probe(struct pci_dev=20 - if (iwl_debug_level & IWL_DL_INFO) - dev_printk(KERN_DEBUG, &(pdev->dev), - "Disabling hw_scan\n"); -- iwl_hw_ops.hw_scan =3D NULL; -+ pax_open_kernel(); -+ *(void **)&iwl_hw_ops.hw_scan =3D NULL; -+ pax_close_kernel(); - } -=20 - hw =3D iwl_alloc_all(cfg, &iwl_hw_ops); -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn-rs.c lin= ux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn-rs.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn-rs.c 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-agn-rs.c 2011-11-15= 19:59:43.000000000 -0500 -@@ -857,6 +857,8 @@ static void rs_tx_status(void *priv_r, s +diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wir= eless/iwlwifi/iwl-agn-rs.c +index 1a3dfa2..b3e0a61 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c ++++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +@@ -857,6 +857,8 @@ static void rs_tx_status(void *priv_r, struct ieee80= 211_supported_band *sband, u8 active_index =3D 0; s32 tpt =3D 0; =20 @@ -37698,7 +39364,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/i= wlwifi/iwl-agn-rs.c linux-2.6.3 IWL_DEBUG_RATE_LIMIT(priv, "get frame ack response, update rate scale = window\n"); =20 if (!ieee80211_is_data(hdr->frame_control) || -@@ -2722,6 +2724,8 @@ static void rs_fill_link_cmd(struct iwl_ +@@ -2722,6 +2724,8 @@ static void rs_fill_link_cmd(struct iwl_priv *priv= , u8 valid_tx_ant =3D 0; struct iwl_link_quality_cmd *lq_cmd =3D &lq_sta->lq; =20 @@ -37707,10 +39373,41 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-agn-rs.c linux-2.6.3 /* Override starting rate (index 0) if needed for debug purposes */ rs_dbgfs_set_mcs(lq_sta, &new_rate, index); =20 -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debugfs.c li= nux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debugfs.c ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debugfs.c 2011-11-0= 8 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debugfs.c 2011-11-1= 5 19:59:43.000000000 -0500 -@@ -524,6 +524,8 @@ static ssize_t iwl_dbgfs_status_read(str +diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wirele= ss/iwlwifi/iwl-agn.c +index 0e56d78..6a3c107 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-agn.c ++++ b/drivers/net/wireless/iwlwifi/iwl-agn.c +@@ -2911,7 +2911,9 @@ static int iwl_pci_probe(struct pci_dev *pdev, con= st struct pci_device_id *ent) + if (iwl_debug_level & IWL_DL_INFO) + dev_printk(KERN_DEBUG, &(pdev->dev), + "Disabling hw_scan\n"); +- iwl_hw_ops.hw_scan =3D NULL; ++ pax_open_kernel(); ++ *(void **)&iwl_hw_ops.hw_scan =3D NULL; ++ pax_close_kernel(); + } +=20 + hw =3D iwl_alloc_all(cfg, &iwl_hw_ops); +diff --git a/drivers/net/wireless/iwlwifi/iwl-debug.h b/drivers/net/wire= less/iwlwifi/iwl-debug.h +index cbc6290..eb323d7 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-debug.h ++++ b/drivers/net/wireless/iwlwifi/iwl-debug.h +@@ -118,8 +118,8 @@ void iwl_dbgfs_unregister(struct iwl_priv *priv); + #endif +=20 + #else +-#define IWL_DEBUG(__priv, level, fmt, args...) +-#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) ++#define IWL_DEBUG(__priv, level, fmt, args...) do {} while (0) ++#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) do {} while (0) + static inline void iwl_print_hex_dump(struct iwl_priv *priv, int level, + void *p, u32 len) + {} +diff --git a/drivers/net/wireless/iwlwifi/iwl-debugfs.c b/drivers/net/wi= reless/iwlwifi/iwl-debugfs.c +index a198bcf..8e68233 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-debugfs.c ++++ b/drivers/net/wireless/iwlwifi/iwl-debugfs.c +@@ -524,6 +524,8 @@ static ssize_t iwl_dbgfs_status_read(struct file *fi= le, int pos =3D 0; const size_t bufsz =3D sizeof(buf); =20 @@ -37719,7 +39416,7 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/i= wlwifi/iwl-debugfs.c linux-2.6. pos +=3D scnprintf(buf + pos, bufsz - pos, "STATUS_HCMD_ACTIVE:\t %d\n= ", test_bit(STATUS_HCMD_ACTIVE, &priv->status)); pos +=3D scnprintf(buf + pos, bufsz - pos, "STATUS_HCMD_SYNC_ACTIVE: %= d\n", -@@ -658,6 +660,8 @@ static ssize_t iwl_dbgfs_qos_read(struct +@@ -658,6 +660,8 @@ static ssize_t iwl_dbgfs_qos_read(struct file *file,= char __user *user_buf, const size_t bufsz =3D sizeof(buf); ssize_t ret; =20 @@ -37728,23 +39425,10 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-debugfs.c linux-2.6. for (i =3D 0; i < AC_NUM; i++) { pos +=3D scnprintf(buf + pos, bufsz - pos, "\tcw_min\tcw_max\taifsn\ttxop\n"); -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debug.h linu= x-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debug.h ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debug.h 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-debug.h 2011-11-15 = 19:59:43.000000000 -0500 -@@ -118,8 +118,8 @@ void iwl_dbgfs_unregister(struct iwl_pri - #endif -=20 - #else --#define IWL_DEBUG(__priv, level, fmt, args...) --#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) -+#define IWL_DEBUG(__priv, level, fmt, args...) do {} while (0) -+#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) do {} while (0) - static inline void iwl_print_hex_dump(struct iwl_priv *priv, int level, - void *p, u32 len) - {} -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-dev.h linux-= 2.6.32.49/drivers/net/wireless/iwlwifi/iwl-dev.h ---- linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-dev.h 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwlwifi/iwl-dev.h 2011-11-15 19= :59:43.000000000 -0500 +diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wirele= ss/iwlwifi/iwl-dev.h +index 3539ea4..b174bfa 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-dev.h ++++ b/drivers/net/wireless/iwlwifi/iwl-dev.h @@ -68,7 +68,7 @@ struct iwl_tx_queue; =20 /* shared structures from iwl-5000.c */ @@ -37754,10 +39438,26 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /iwlwifi/iwl-dev.h linux-2.6.32.4 extern struct iwl_ucode_ops iwl5000_ucode; extern struct iwl_lib_ops iwl5000_lib; extern struct iwl_hcmd_ops iwl5000_hcmd; -diff -urNp linux-2.6.32.49/drivers/net/wireless/iwmc3200wifi/debugfs.c l= inux-2.6.32.49/drivers/net/wireless/iwmc3200wifi/debugfs.c ---- linux-2.6.32.49/drivers/net/wireless/iwmc3200wifi/debugfs.c 2011-11-= 08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/iwmc3200wifi/debugfs.c 2011-11-= 15 19:59:43.000000000 -0500 -@@ -299,6 +299,8 @@ static ssize_t iwm_debugfs_fw_err_read(s +diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/w= ireless/iwlwifi/iwl3945-base.c +index 619590d..69235ee 100644 +--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c ++++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c +@@ -3927,7 +3927,9 @@ static int iwl3945_pci_probe(struct pci_dev *pdev,= const struct pci_device_id *e + */ + if (iwl3945_mod_params.disable_hw_scan) { + IWL_DEBUG_INFO(priv, "Disabling hw_scan\n"); +- iwl3945_hw_ops.hw_scan =3D NULL; ++ pax_open_kernel(); ++ *(void **)&iwl3945_hw_ops.hw_scan =3D NULL; ++ pax_close_kernel(); + } +=20 +=20 +diff --git a/drivers/net/wireless/iwmc3200wifi/debugfs.c b/drivers/net/w= ireless/iwmc3200wifi/debugfs.c +index 1465379..fe4d78b 100644 +--- a/drivers/net/wireless/iwmc3200wifi/debugfs.c ++++ b/drivers/net/wireless/iwmc3200wifi/debugfs.c +@@ -299,6 +299,8 @@ static ssize_t iwm_debugfs_fw_err_read(struct file *= filp, int buf_len =3D 512; size_t len =3D 0; =20 @@ -37766,9 +39466,10 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless/= iwmc3200wifi/debugfs.c linux-2.6 if (*ppos !=3D 0) return 0; if (count < sizeof(buf)) -diff -urNp linux-2.6.32.49/drivers/net/wireless/libertas/debugfs.c linux= -2.6.32.49/drivers/net/wireless/libertas/debugfs.c ---- linux-2.6.32.49/drivers/net/wireless/libertas/debugfs.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/libertas/debugfs.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/net/wireless/libertas/debugfs.c b/drivers/net/wirel= ess/libertas/debugfs.c +index 893a55c..7f66a50 100644 +--- a/drivers/net/wireless/libertas/debugfs.c ++++ b/drivers/net/wireless/libertas/debugfs.c @@ -708,7 +708,7 @@ out_unlock: struct lbs_debugfs_files { const char *name; @@ -37778,10 +39479,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /libertas/debugfs.c linux-2.6.32. }; =20 static const struct lbs_debugfs_files debugfs_files[] =3D { -diff -urNp linux-2.6.32.49/drivers/net/wireless/rndis_wlan.c linux-2.6.3= 2.49/drivers/net/wireless/rndis_wlan.c ---- linux-2.6.32.49/drivers/net/wireless/rndis_wlan.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/net/wireless/rndis_wlan.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -1176,7 +1176,7 @@ static int set_rts_threshold(struct usbn +diff --git a/drivers/net/wireless/rndis_wlan.c b/drivers/net/wireless/rn= dis_wlan.c +index 2ecbedb..42704f0 100644 +--- a/drivers/net/wireless/rndis_wlan.c ++++ b/drivers/net/wireless/rndis_wlan.c +@@ -1176,7 +1176,7 @@ static int set_rts_threshold(struct usbnet *usbdev= , u32 rts_threshold) =20 devdbg(usbdev, "set_rts_threshold %i", rts_threshold); =20 @@ -37790,10 +39492,11 @@ diff -urNp linux-2.6.32.49/drivers/net/wireless= /rndis_wlan.c linux-2.6.32.49/dri rts_threshold =3D 2347; =20 tmp =3D cpu_to_le32(rts_threshold); -diff -urNp linux-2.6.32.49/drivers/oprofile/buffer_sync.c linux-2.6.32.4= 9/drivers/oprofile/buffer_sync.c ---- linux-2.6.32.49/drivers/oprofile/buffer_sync.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/oprofile/buffer_sync.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -341,7 +341,7 @@ static void add_data(struct op_entry *en +diff --git a/drivers/oprofile/buffer_sync.c b/drivers/oprofile/buffer_sy= nc.c +index 5c4df24..3b42925 100644 +--- a/drivers/oprofile/buffer_sync.c ++++ b/drivers/oprofile/buffer_sync.c +@@ -341,7 +341,7 @@ static void add_data(struct op_entry *entry, struct = mm_struct *mm) if (cookie =3D=3D NO_COOKIE) offset =3D pc; if (cookie =3D=3D INVALID_COOKIE) { @@ -37802,7 +39505,7 @@ diff -urNp linux-2.6.32.49/drivers/oprofile/buffe= r_sync.c linux-2.6.32.49/driver offset =3D pc; } if (cookie !=3D last_cookie) { -@@ -385,14 +385,14 @@ add_sample(struct mm_struct *mm, struct=20 +@@ -385,14 +385,14 @@ add_sample(struct mm_struct *mm, struct op_sample = *s, int in_kernel) /* add userspace sample */ =20 if (!mm) { @@ -37828,10 +39531,11 @@ diff -urNp linux-2.6.32.49/drivers/oprofile/buf= fer_sync.c linux-2.6.32.49/driver } } release_mm(mm); -diff -urNp linux-2.6.32.49/drivers/oprofile/event_buffer.c linux-2.6.32.= 49/drivers/oprofile/event_buffer.c ---- linux-2.6.32.49/drivers/oprofile/event_buffer.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/oprofile/event_buffer.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -53,7 +53,7 @@ void add_event_entry(unsigned long value +diff --git a/drivers/oprofile/event_buffer.c b/drivers/oprofile/event_bu= ffer.c +index 5df60a6..72f5c1c 100644 +--- a/drivers/oprofile/event_buffer.c ++++ b/drivers/oprofile/event_buffer.c +@@ -53,7 +53,7 @@ void add_event_entry(unsigned long value) } =20 if (buffer_pos =3D=3D buffer_size) { @@ -37840,10 +39544,11 @@ diff -urNp linux-2.6.32.49/drivers/oprofile/eve= nt_buffer.c linux-2.6.32.49/drive return; } =20 -diff -urNp linux-2.6.32.49/drivers/oprofile/oprof.c linux-2.6.32.49/driv= ers/oprofile/oprof.c ---- linux-2.6.32.49/drivers/oprofile/oprof.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/oprofile/oprof.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -110,7 +110,7 @@ static void switch_worker(struct work_st +diff --git a/drivers/oprofile/oprof.c b/drivers/oprofile/oprof.c +index dc8a042..fe5f315 100644 +--- a/drivers/oprofile/oprof.c ++++ b/drivers/oprofile/oprof.c +@@ -110,7 +110,7 @@ static void switch_worker(struct work_struct *work) if (oprofile_ops.switch_events()) return; =20 @@ -37852,21 +39557,10 @@ diff -urNp linux-2.6.32.49/drivers/oprofile/opr= of.c linux-2.6.32.49/drivers/opro start_switch_worker(); } =20 -diff -urNp linux-2.6.32.49/drivers/oprofile/oprofilefs.c linux-2.6.32.49= /drivers/oprofile/oprofilefs.c ---- linux-2.6.32.49/drivers/oprofile/oprofilefs.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/oprofile/oprofilefs.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -187,7 +187,7 @@ static const struct file_operations atom -=20 -=20 - int oprofilefs_create_ro_atomic(struct super_block *sb, struct dentry *= root, -- char const *name, atomic_t *val) -+ char const *name, atomic_unchecked_t *val) - { - struct dentry *d =3D __oprofilefs_create_file(sb, root, name, - &atomic_ro_fops, 0444); -diff -urNp linux-2.6.32.49/drivers/oprofile/oprofile_stats.c linux-2.6.3= 2.49/drivers/oprofile/oprofile_stats.c ---- linux-2.6.32.49/drivers/oprofile/oprofile_stats.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/oprofile/oprofile_stats.c 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/drivers/oprofile/oprofile_stats.c b/drivers/oprofile/oprofi= le_stats.c +index 61689e8..387f7f8 100644 +--- a/drivers/oprofile/oprofile_stats.c ++++ b/drivers/oprofile/oprofile_stats.c @@ -30,11 +30,11 @@ void oprofile_reset_stats(void) cpu_buf->sample_invalid_eip =3D 0; } @@ -37884,9 +39578,10 @@ diff -urNp linux-2.6.32.49/drivers/oprofile/opro= file_stats.c linux-2.6.32.49/dri } =20 =20 -diff -urNp linux-2.6.32.49/drivers/oprofile/oprofile_stats.h linux-2.6.3= 2.49/drivers/oprofile/oprofile_stats.h ---- linux-2.6.32.49/drivers/oprofile/oprofile_stats.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/oprofile/oprofile_stats.h 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/drivers/oprofile/oprofile_stats.h b/drivers/oprofile/oprofi= le_stats.h +index 0b54e46..a37c527 100644 +--- a/drivers/oprofile/oprofile_stats.h ++++ b/drivers/oprofile/oprofile_stats.h @@ -13,11 +13,11 @@ #include =20 @@ -37904,10 +39599,24 @@ diff -urNp linux-2.6.32.49/drivers/oprofile/opr= ofile_stats.h linux-2.6.32.49/dri }; =20 extern struct oprofile_stat_struct oprofile_stats; -diff -urNp linux-2.6.32.49/drivers/parisc/pdc_stable.c linux-2.6.32.49/d= rivers/parisc/pdc_stable.c ---- linux-2.6.32.49/drivers/parisc/pdc_stable.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/parisc/pdc_stable.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -481,7 +481,7 @@ pdcspath_attr_store(struct kobject *kobj +diff --git a/drivers/oprofile/oprofilefs.c b/drivers/oprofile/oprofilefs= .c +index 2766a6d..80c77e2 100644 +--- a/drivers/oprofile/oprofilefs.c ++++ b/drivers/oprofile/oprofilefs.c +@@ -187,7 +187,7 @@ static const struct file_operations atomic_ro_fops =3D= { +=20 +=20 + int oprofilefs_create_ro_atomic(struct super_block *sb, struct dentry *= root, +- char const *name, atomic_t *val) ++ char const *name, atomic_unchecked_t *val) + { + struct dentry *d =3D __oprofilefs_create_file(sb, root, name, + &atomic_ro_fops, 0444); +diff --git a/drivers/parisc/pdc_stable.c b/drivers/parisc/pdc_stable.c +index 13a64bc..ad62835 100644 +--- a/drivers/parisc/pdc_stable.c ++++ b/drivers/parisc/pdc_stable.c +@@ -481,7 +481,7 @@ pdcspath_attr_store(struct kobject *kobj, struct att= ribute *attr, return ret; } =20 @@ -37916,10 +39625,11 @@ diff -urNp linux-2.6.32.49/drivers/parisc/pdc_s= table.c linux-2.6.32.49/drivers/p .show =3D pdcspath_attr_show, .store =3D pdcspath_attr_store, }; -diff -urNp linux-2.6.32.49/drivers/parport/procfs.c linux-2.6.32.49/driv= ers/parport/procfs.c ---- linux-2.6.32.49/drivers/parport/procfs.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/parport/procfs.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -64,7 +64,7 @@ static int do_active_device(ctl_table *t +diff --git a/drivers/parport/procfs.c b/drivers/parport/procfs.c +index 8eefe56..40751a7 100644 +--- a/drivers/parport/procfs.c ++++ b/drivers/parport/procfs.c +@@ -64,7 +64,7 @@ static int do_active_device(ctl_table *table, int writ= e, =20 *ppos +=3D len; =20 @@ -37928,7 +39638,7 @@ diff -urNp linux-2.6.32.49/drivers/parport/procfs= .c linux-2.6.32.49/drivers/parp } =20 #ifdef CONFIG_PARPORT_1284 -@@ -106,7 +106,7 @@ static int do_autoprobe(ctl_table *table +@@ -106,7 +106,7 @@ static int do_autoprobe(ctl_table *table, int write, =20 *ppos +=3D len; =20 @@ -37937,10 +39647,11 @@ diff -urNp linux-2.6.32.49/drivers/parport/proc= fs.c linux-2.6.32.49/drivers/parp } #endif /* IEEE1284.3 support. */ =20 -diff -urNp linux-2.6.32.49/drivers/pci/hotplug/acpiphp_glue.c linux-2.6.= 32.49/drivers/pci/hotplug/acpiphp_glue.c ---- linux-2.6.32.49/drivers/pci/hotplug/acpiphp_glue.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/pci/hotplug/acpiphp_glue.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -111,7 +111,7 @@ static int post_dock_fixups(struct notif +diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/ac= piphp_glue.c +index 73e7d8e..c80f3d2 100644 +--- a/drivers/pci/hotplug/acpiphp_glue.c ++++ b/drivers/pci/hotplug/acpiphp_glue.c +@@ -111,7 +111,7 @@ static int post_dock_fixups(struct notifier_block *n= b, unsigned long val, } =20 =20 @@ -37949,9 +39660,10 @@ diff -urNp linux-2.6.32.49/drivers/pci/hotplug/a= cpiphp_glue.c linux-2.6.32.49/dr .handler =3D handle_hotplug_event_func, }; =20 -diff -urNp linux-2.6.32.49/drivers/pci/hotplug/cpci_hotplug.h linux-2.6.= 32.49/drivers/pci/hotplug/cpci_hotplug.h ---- linux-2.6.32.49/drivers/pci/hotplug/cpci_hotplug.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/pci/hotplug/cpci_hotplug.h 2011-11-15 19:59:= 43.000000000 -0500 +diff --git a/drivers/pci/hotplug/cpci_hotplug.h b/drivers/pci/hotplug/cp= ci_hotplug.h +index 9fff878..ad0ad53 100644 +--- a/drivers/pci/hotplug/cpci_hotplug.h ++++ b/drivers/pci/hotplug/cpci_hotplug.h @@ -59,7 +59,7 @@ struct cpci_hp_controller_ops { int (*hardware_test) (struct slot* slot, u32 value); u8 (*get_power) (struct slot* slot); @@ -37961,10 +39673,11 @@ diff -urNp linux-2.6.32.49/drivers/pci/hotplug/= cpci_hotplug.h linux-2.6.32.49/dr =20 struct cpci_hp_controller { unsigned int irq; -diff -urNp linux-2.6.32.49/drivers/pci/hotplug/cpqphp_nvram.c linux-2.6.= 32.49/drivers/pci/hotplug/cpqphp_nvram.c ---- linux-2.6.32.49/drivers/pci/hotplug/cpqphp_nvram.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/pci/hotplug/cpqphp_nvram.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -428,9 +428,13 @@ static u32 store_HRT (void __iomem *rom_ +diff --git a/drivers/pci/hotplug/cpqphp_nvram.c b/drivers/pci/hotplug/cp= qphp_nvram.c +index 76ba8a1..20ca857 100644 +--- a/drivers/pci/hotplug/cpqphp_nvram.c ++++ b/drivers/pci/hotplug/cpqphp_nvram.c +@@ -428,9 +428,13 @@ static u32 store_HRT (void __iomem *rom_start) =20 void compaq_nvram_init (void __iomem *rom_start) { @@ -37978,10 +39691,11 @@ diff -urNp linux-2.6.32.49/drivers/pci/hotplug/= cpqphp_nvram.c linux-2.6.32.49/dr dbg("int15 entry =3D %p\n", compaq_int15_entry_point); =20 /* initialize our int15 lock */ -diff -urNp linux-2.6.32.49/drivers/pci/hotplug/fakephp.c linux-2.6.32.49= /drivers/pci/hotplug/fakephp.c ---- linux-2.6.32.49/drivers/pci/hotplug/fakephp.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/pci/hotplug/fakephp.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -73,7 +73,7 @@ static void legacy_release(struct kobjec +diff --git a/drivers/pci/hotplug/fakephp.c b/drivers/pci/hotplug/fakephp= .c +index 6151389..0a894ef 100644 +--- a/drivers/pci/hotplug/fakephp.c ++++ b/drivers/pci/hotplug/fakephp.c +@@ -73,7 +73,7 @@ static void legacy_release(struct kobject *kobj) } =20 static struct kobj_type legacy_ktype =3D { @@ -37990,9 +39704,10 @@ diff -urNp linux-2.6.32.49/drivers/pci/hotplug/f= akephp.c linux-2.6.32.49/drivers .store =3D legacy_store, .show =3D legacy_show }, .release =3D &legacy_release, -diff -urNp linux-2.6.32.49/drivers/pci/intel-iommu.c linux-2.6.32.49/dri= vers/pci/intel-iommu.c ---- linux-2.6.32.49/drivers/pci/intel-iommu.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/pci/intel-iommu.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c +index 5b680df..fe05b7e 100644 +--- a/drivers/pci/intel-iommu.c ++++ b/drivers/pci/intel-iommu.c @@ -2643,7 +2643,7 @@ error: return 0; } @@ -38002,7 +39717,7 @@ diff -urNp linux-2.6.32.49/drivers/pci/intel-iomm= u.c linux-2.6.32.49/drivers/pci unsigned long offset, size_t size, enum dma_data_direction dir, struct dma_attrs *attrs) -@@ -2719,7 +2719,7 @@ static void add_unmap(struct dmar_domain +@@ -2719,7 +2719,7 @@ static void add_unmap(struct dmar_domain *dom, str= uct iova *iova) spin_unlock_irqrestore(&async_umap_flush_lock, flags); } =20 @@ -38011,7 +39726,7 @@ diff -urNp linux-2.6.32.49/drivers/pci/intel-iomm= u.c linux-2.6.32.49/drivers/pci size_t size, enum dma_data_direction dir, struct dma_attrs *attrs) { -@@ -2768,7 +2768,7 @@ static void intel_unmap_page(struct devi +@@ -2768,7 +2768,7 @@ static void intel_unmap_page(struct device *dev, d= ma_addr_t dev_addr, } } =20 @@ -38020,7 +39735,7 @@ diff -urNp linux-2.6.32.49/drivers/pci/intel-iomm= u.c linux-2.6.32.49/drivers/pci dma_addr_t *dma_handle, gfp_t flags) { void *vaddr; -@@ -2800,7 +2800,7 @@ static void *intel_alloc_coherent(struct +@@ -2800,7 +2800,7 @@ static void *intel_alloc_coherent(struct device *h= wdev, size_t size, return NULL; } =20 @@ -38029,7 +39744,7 @@ diff -urNp linux-2.6.32.49/drivers/pci/intel-iomm= u.c linux-2.6.32.49/drivers/pci dma_addr_t dma_handle) { int order; -@@ -2812,7 +2812,7 @@ static void intel_free_coherent(struct d +@@ -2812,7 +2812,7 @@ static void intel_free_coherent(struct device *hwd= ev, size_t size, void *vaddr, free_pages((unsigned long)vaddr, order); } =20 @@ -38038,7 +39753,7 @@ diff -urNp linux-2.6.32.49/drivers/pci/intel-iomm= u.c linux-2.6.32.49/drivers/pci int nelems, enum dma_data_direction dir, struct dma_attrs *attrs) { -@@ -2872,7 +2872,7 @@ static int intel_nontranslate_map_sg(str +@@ -2872,7 +2872,7 @@ static int intel_nontranslate_map_sg(struct device= *hddev, return nelems; } =20 @@ -38047,7 +39762,7 @@ diff -urNp linux-2.6.32.49/drivers/pci/intel-iomm= u.c linux-2.6.32.49/drivers/pci enum dma_data_direction dir, struct dma_attrs *attrs) { int i; -@@ -2941,12 +2941,12 @@ static int intel_map_sg(struct device *h +@@ -2941,12 +2941,12 @@ static int intel_map_sg(struct device *hwdev, st= ruct scatterlist *sglist, int ne return nelems; } =20 @@ -38062,9 +39777,10 @@ diff -urNp linux-2.6.32.49/drivers/pci/intel-iom= mu.c linux-2.6.32.49/drivers/pci .alloc_coherent =3D intel_alloc_coherent, .free_coherent =3D intel_free_coherent, .map_sg =3D intel_map_sg, -diff -urNp linux-2.6.32.49/drivers/pci/pcie/aspm.c linux-2.6.32.49/drive= rs/pci/pcie/aspm.c ---- linux-2.6.32.49/drivers/pci/pcie/aspm.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/pci/pcie/aspm.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/pci/pcie/aspm.c b/drivers/pci/pcie/aspm.c +index 5b7056c..607bc94 100644 +--- a/drivers/pci/pcie/aspm.c ++++ b/drivers/pci/pcie/aspm.c @@ -27,9 +27,9 @@ #define MODULE_PARAM_PREFIX "pcie_aspm." =20 @@ -38078,10 +39794,11 @@ diff -urNp linux-2.6.32.49/drivers/pci/pcie/asp= m.c linux-2.6.32.49/drivers/pci/p #define ASPM_STATE_L0S (ASPM_STATE_L0S_UP | ASPM_STATE_L0S_DW) #define ASPM_STATE_ALL (ASPM_STATE_L0S | ASPM_STATE_L1) =20 -diff -urNp linux-2.6.32.49/drivers/pci/probe.c linux-2.6.32.49/drivers/p= ci/probe.c ---- linux-2.6.32.49/drivers/pci/probe.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/pci/probe.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -62,14 +62,14 @@ static ssize_t pci_bus_show_cpuaffinity( +diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c +index 8105e32..ca10419 100644 +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -62,14 +62,14 @@ static ssize_t pci_bus_show_cpuaffinity(struct devic= e *dev, return ret; } =20 @@ -38098,10 +39815,11 @@ diff -urNp linux-2.6.32.49/drivers/pci/probe.c = linux-2.6.32.49/drivers/pci/probe struct device_attribute *attr, char *buf) { -diff -urNp linux-2.6.32.49/drivers/pci/proc.c linux-2.6.32.49/drivers/pc= i/proc.c ---- linux-2.6.32.49/drivers/pci/proc.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/pci/proc.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -480,7 +480,16 @@ static const struct file_operations proc +diff --git a/drivers/pci/proc.c b/drivers/pci/proc.c +index a03ad8c..024b0da 100644 +--- a/drivers/pci/proc.c ++++ b/drivers/pci/proc.c +@@ -480,7 +480,16 @@ static const struct file_operations proc_bus_pci_de= v_operations =3D { static int __init pci_proc_init(void) { struct pci_dev *dev =3D NULL; @@ -38118,10 +39836,11 @@ diff -urNp linux-2.6.32.49/drivers/pci/proc.c l= inux-2.6.32.49/drivers/pci/proc.c proc_create("devices", 0, proc_bus_pci_dir, &proc_bus_pci_dev_operations); proc_initialized =3D 1; -diff -urNp linux-2.6.32.49/drivers/pci/slot.c linux-2.6.32.49/drivers/pc= i/slot.c ---- linux-2.6.32.49/drivers/pci/slot.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/pci/slot.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -29,7 +29,7 @@ static ssize_t pci_slot_attr_store(struc +diff --git a/drivers/pci/slot.c b/drivers/pci/slot.c +index 8c02b6c..5584d8e 100644 +--- a/drivers/pci/slot.c ++++ b/drivers/pci/slot.c +@@ -29,7 +29,7 @@ static ssize_t pci_slot_attr_store(struct kobject *kob= j, return attribute->store ? attribute->store(slot, buf, len) : -EIO; } =20 @@ -38130,10 +39849,11 @@ diff -urNp linux-2.6.32.49/drivers/pci/slot.c l= inux-2.6.32.49/drivers/pci/slot.c .show =3D pci_slot_attr_show, .store =3D pci_slot_attr_store, }; -diff -urNp linux-2.6.32.49/drivers/pcmcia/pcmcia_ioctl.c linux-2.6.32.49= /drivers/pcmcia/pcmcia_ioctl.c ---- linux-2.6.32.49/drivers/pcmcia/pcmcia_ioctl.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/pcmcia/pcmcia_ioctl.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -819,7 +819,7 @@ static int ds_ioctl(struct inode * inode +diff --git a/drivers/pcmcia/pcmcia_ioctl.c b/drivers/pcmcia/pcmcia_ioctl= .c +index 30cf71d2..50938f1 100644 +--- a/drivers/pcmcia/pcmcia_ioctl.c ++++ b/drivers/pcmcia/pcmcia_ioctl.c +@@ -819,7 +819,7 @@ static int ds_ioctl(struct inode * inode, struct fil= e * file, return -EFAULT; } } @@ -38142,10 +39862,11 @@ diff -urNp linux-2.6.32.49/drivers/pcmcia/pcmci= a_ioctl.c linux-2.6.32.49/drivers if (!buf) return -ENOMEM; =20 -diff -urNp linux-2.6.32.49/drivers/platform/x86/acer-wmi.c linux-2.6.32.= 49/drivers/platform/x86/acer-wmi.c ---- linux-2.6.32.49/drivers/platform/x86/acer-wmi.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/acer-wmi.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -918,7 +918,7 @@ static int update_bl_status(struct backl +diff --git a/drivers/platform/x86/acer-wmi.c b/drivers/platform/x86/acer= -wmi.c +index 52183c4..b224c69 100644 +--- a/drivers/platform/x86/acer-wmi.c ++++ b/drivers/platform/x86/acer-wmi.c +@@ -918,7 +918,7 @@ static int update_bl_status(struct backlight_device = *bd) return 0; } =20 @@ -38154,22 +39875,11 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /acer-wmi.c linux-2.6.32.49/drive .get_brightness =3D read_brightness, .update_status =3D update_bl_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/asus_acpi.c linux-2.6.32= .49/drivers/platform/x86/asus_acpi.c ---- linux-2.6.32.49/drivers/platform/x86/asus_acpi.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/asus_acpi.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -1396,7 +1396,7 @@ static int asus_hotk_remove(struct acpi_ - return 0; - } -=20 --static struct backlight_ops asus_backlight_data =3D { -+static const struct backlight_ops asus_backlight_data =3D { - .get_brightness =3D read_brightness, - .update_status =3D set_brightness_status, - }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/asus-laptop.c linux-2.6.= 32.49/drivers/platform/x86/asus-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/asus-laptop.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/asus-laptop.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -250,7 +250,7 @@ static struct backlight_device *asus_bac +diff --git a/drivers/platform/x86/asus-laptop.c b/drivers/platform/x86/a= sus-laptop.c +index 767cb61..a87380b 100644 +--- a/drivers/platform/x86/asus-laptop.c ++++ b/drivers/platform/x86/asus-laptop.c +@@ -250,7 +250,7 @@ static struct backlight_device *asus_backlight_devic= e; */ static int read_brightness(struct backlight_device *bd); static int update_bl_status(struct backlight_device *bd); @@ -38178,10 +39888,24 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /asus-laptop.c linux-2.6.32.49/dr .get_brightness =3D read_brightness, .update_status =3D update_bl_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/compal-laptop.c linux-2.= 6.32.49/drivers/platform/x86/compal-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/compal-laptop.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/compal-laptop.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -163,7 +163,7 @@ static int bl_update_status(struct backl +diff --git a/drivers/platform/x86/asus_acpi.c b/drivers/platform/x86/asu= s_acpi.c +index d66c07a..a4abaac 100644 +--- a/drivers/platform/x86/asus_acpi.c ++++ b/drivers/platform/x86/asus_acpi.c +@@ -1396,7 +1396,7 @@ static int asus_hotk_remove(struct acpi_device *de= vice, int type) + return 0; + } +=20 +-static struct backlight_ops asus_backlight_data =3D { ++static const struct backlight_ops asus_backlight_data =3D { + .get_brightness =3D read_brightness, + .update_status =3D set_brightness_status, + }; +diff --git a/drivers/platform/x86/compal-laptop.c b/drivers/platform/x86= /compal-laptop.c +index 11003bb..550ff1b 100644 +--- a/drivers/platform/x86/compal-laptop.c ++++ b/drivers/platform/x86/compal-laptop.c +@@ -163,7 +163,7 @@ static int bl_update_status(struct backlight_device = *b) return set_lcd_level(b->props.brightness); } =20 @@ -38190,10 +39914,11 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /compal-laptop.c linux-2.6.32.49/ .get_brightness =3D bl_get_brightness, .update_status =3D bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/dell-laptop.c linux-2.6.= 32.49/drivers/platform/x86/dell-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/dell-laptop.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/dell-laptop.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -318,7 +318,7 @@ static int dell_get_intensity(struct bac +diff --git a/drivers/platform/x86/dell-laptop.c b/drivers/platform/x86/d= ell-laptop.c +index 07a74da..9dc99fa 100644 +--- a/drivers/platform/x86/dell-laptop.c ++++ b/drivers/platform/x86/dell-laptop.c +@@ -318,7 +318,7 @@ static int dell_get_intensity(struct backlight_devic= e *bd) return buffer.output[1]; } =20 @@ -38202,10 +39927,11 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /dell-laptop.c linux-2.6.32.49/dr .get_brightness =3D dell_get_intensity, .update_status =3D dell_send_intensity, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/eeepc-laptop.c linux-2.6= .32.49/drivers/platform/x86/eeepc-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/eeepc-laptop.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/eeepc-laptop.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -245,7 +245,7 @@ static struct device *eeepc_hwmon_device +diff --git a/drivers/platform/x86/eeepc-laptop.c b/drivers/platform/x86/= eeepc-laptop.c +index c533b1c..5c81f22 100644 +--- a/drivers/platform/x86/eeepc-laptop.c ++++ b/drivers/platform/x86/eeepc-laptop.c +@@ -245,7 +245,7 @@ static struct device *eeepc_hwmon_device; */ static int read_brightness(struct backlight_device *bd); static int update_bl_status(struct backlight_device *bd); @@ -38214,10 +39940,11 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /eeepc-laptop.c linux-2.6.32.49/d .get_brightness =3D read_brightness, .update_status =3D update_bl_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/fujitsu-laptop.c linux-2= .6.32.49/drivers/platform/x86/fujitsu-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/fujitsu-laptop.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/fujitsu-laptop.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -436,7 +436,7 @@ static int bl_update_status(struct backl +diff --git a/drivers/platform/x86/fujitsu-laptop.c b/drivers/platform/x8= 6/fujitsu-laptop.c +index bcd4ba8..a249b35 100644 +--- a/drivers/platform/x86/fujitsu-laptop.c ++++ b/drivers/platform/x86/fujitsu-laptop.c +@@ -436,7 +436,7 @@ static int bl_update_status(struct backlight_device = *b) return ret; } =20 @@ -38226,10 +39953,11 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /fujitsu-laptop.c linux-2.6.32.49 .get_brightness =3D bl_get_brightness, .update_status =3D bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/msi-laptop.c linux-2.6.3= 2.49/drivers/platform/x86/msi-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/msi-laptop.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/msi-laptop.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -161,7 +161,7 @@ static int bl_update_status(struct backl +diff --git a/drivers/platform/x86/msi-laptop.c b/drivers/platform/x86/ms= i-laptop.c +index 759763d..1093ba2 100644 +--- a/drivers/platform/x86/msi-laptop.c ++++ b/drivers/platform/x86/msi-laptop.c +@@ -161,7 +161,7 @@ static int bl_update_status(struct backlight_device = *b) return set_lcd_level(b->props.brightness); } =20 @@ -38238,10 +39966,11 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /msi-laptop.c linux-2.6.32.49/dri .get_brightness =3D bl_get_brightness, .update_status =3D bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/panasonic-laptop.c linux= -2.6.32.49/drivers/platform/x86/panasonic-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/panasonic-laptop.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/panasonic-laptop.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -352,7 +352,7 @@ static int bl_set_status(struct backligh +diff --git a/drivers/platform/x86/panasonic-laptop.c b/drivers/platform/= x86/panasonic-laptop.c +index fe7cf01..9012d8d 100644 +--- a/drivers/platform/x86/panasonic-laptop.c ++++ b/drivers/platform/x86/panasonic-laptop.c +@@ -352,7 +352,7 @@ static int bl_set_status(struct backlight_device *bd= ) return acpi_pcc_write_sset(pcc, SINF_DC_CUR_BRIGHT, bright); } =20 @@ -38250,10 +39979,11 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86= /panasonic-laptop.c linux-2.6.32. .get_brightness =3D bl_get, .update_status =3D bl_set_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/sony-laptop.c linux-2.6.= 32.49/drivers/platform/x86/sony-laptop.c ---- linux-2.6.32.49/drivers/platform/x86/sony-laptop.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/sony-laptop.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -850,7 +850,7 @@ static int sony_backlight_get_brightness +diff --git a/drivers/platform/x86/sony-laptop.c b/drivers/platform/x86/s= ony-laptop.c +index a2a742c..b37e25e 100644 +--- a/drivers/platform/x86/sony-laptop.c ++++ b/drivers/platform/x86/sony-laptop.c +@@ -850,7 +850,7 @@ static int sony_backlight_get_brightness(struct back= light_device *bd) } =20 static struct backlight_device *sony_backlight_device; @@ -38262,9 +39992,10 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86/= sony-laptop.c linux-2.6.32.49/dr .update_status =3D sony_backlight_update_status, .get_brightness =3D sony_backlight_get_brightness, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/thinkpad_acpi.c linux-2.= 6.32.49/drivers/platform/x86/thinkpad_acpi.c ---- linux-2.6.32.49/drivers/platform/x86/thinkpad_acpi.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/thinkpad_acpi.c 2011-11-15 19:5= 9:43.000000000 -0500 +diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86= /thinkpad_acpi.c +index 68271ae..5e8fb10 100644 +--- a/drivers/platform/x86/thinkpad_acpi.c ++++ b/drivers/platform/x86/thinkpad_acpi.c @@ -2139,7 +2139,7 @@ static int hotkey_mask_get(void) return 0; } @@ -38274,7 +40005,7 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86/t= hinkpad_acpi.c linux-2.6.32.49/ { /* log only what the user can fix... */ const u32 wantedmask =3D hotkey_driver_mask & -@@ -6125,7 +6125,7 @@ static void tpacpi_brightness_notify_cha +@@ -6125,7 +6125,7 @@ static void tpacpi_brightness_notify_change(void) BACKLIGHT_UPDATE_HOTKEY); } =20 @@ -38283,9 +40014,10 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86/= thinkpad_acpi.c linux-2.6.32.49/ .get_brightness =3D brightness_get, .update_status =3D brightness_update_status, }; -diff -urNp linux-2.6.32.49/drivers/platform/x86/toshiba_acpi.c linux-2.6= .32.49/drivers/platform/x86/toshiba_acpi.c ---- linux-2.6.32.49/drivers/platform/x86/toshiba_acpi.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/platform/x86/toshiba_acpi.c 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/drivers/platform/x86/toshiba_acpi.c b/drivers/platform/x86/= toshiba_acpi.c +index 51c0a8b..0786629 100644 +--- a/drivers/platform/x86/toshiba_acpi.c ++++ b/drivers/platform/x86/toshiba_acpi.c @@ -671,7 +671,7 @@ static acpi_status remove_device(void) return AE_OK; } @@ -38295,9 +40027,10 @@ diff -urNp linux-2.6.32.49/drivers/platform/x86/= toshiba_acpi.c linux-2.6.32.49/d .get_brightness =3D get_lcd, .update_status =3D set_lcd_status, }; -diff -urNp linux-2.6.32.49/drivers/pnp/pnpbios/bioscalls.c linux-2.6.32.= 49/drivers/pnp/pnpbios/bioscalls.c ---- linux-2.6.32.49/drivers/pnp/pnpbios/bioscalls.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/pnp/pnpbios/bioscalls.c 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/pnp/pnpbios/bioscalls.c b/drivers/pnp/pnpbios/biosc= alls.c +index fc83783c..cf370d7 100644 +--- a/drivers/pnp/pnpbios/bioscalls.c ++++ b/drivers/pnp/pnpbios/bioscalls.c @@ -60,7 +60,7 @@ do { \ set_desc_limit(&gdt[(selname) >> 3], (size) - 1); \ } while(0) @@ -38307,7 +40040,7 @@ diff -urNp linux-2.6.32.49/drivers/pnp/pnpbios/bi= oscalls.c linux-2.6.32.49/drive (unsigned long)__va(0x400UL), PAGE_SIZE - 0x400 - 1); =20 /* -@@ -97,7 +97,10 @@ static inline u16 call_pnp_bios(u16 func +@@ -97,7 +97,10 @@ static inline u16 call_pnp_bios(u16 func, u16 arg1, u= 16 arg2, u16 arg3, =20 cpu =3D get_cpu(); save_desc_40 =3D get_cpu_gdt_table(cpu)[0x40 / 8]; @@ -38318,7 +40051,7 @@ diff -urNp linux-2.6.32.49/drivers/pnp/pnpbios/bi= oscalls.c linux-2.6.32.49/drive =20 /* On some boxes IRQ's during PnP BIOS calls are deadly. */ spin_lock_irqsave(&pnp_bios_lock, flags); -@@ -135,7 +138,10 @@ static inline u16 call_pnp_bios(u16 func +@@ -135,7 +138,10 @@ static inline u16 call_pnp_bios(u16 func, u16 arg1,= u16 arg2, u16 arg3, :"memory"); spin_unlock_irqrestore(&pnp_bios_lock, flags); =20 @@ -38329,7 +40062,7 @@ diff -urNp linux-2.6.32.49/drivers/pnp/pnpbios/bi= oscalls.c linux-2.6.32.49/drive put_cpu(); =20 /* If we get here and this is set then the PnP BIOS faulted on us. */ -@@ -469,7 +475,7 @@ int pnp_bios_read_escd(char *data, u32 n +@@ -469,7 +475,7 @@ int pnp_bios_read_escd(char *data, u32 nvram_base) return status; } =20 @@ -38338,7 +40071,7 @@ diff -urNp linux-2.6.32.49/drivers/pnp/pnpbios/bi= oscalls.c linux-2.6.32.49/drive { int i; =20 -@@ -477,6 +483,8 @@ void pnpbios_calls_init(union pnp_bios_i +@@ -477,6 +483,8 @@ void pnpbios_calls_init(union pnp_bios_install_struc= t *header) pnp_bios_callpoint.offset =3D header->fields.pm16offset; pnp_bios_callpoint.segment =3D PNP_CS16; =20 @@ -38347,17 +40080,18 @@ diff -urNp linux-2.6.32.49/drivers/pnp/pnpbios/= bioscalls.c linux-2.6.32.49/drive for_each_possible_cpu(i) { struct desc_struct *gdt =3D get_cpu_gdt_table(i); if (!gdt) -@@ -488,4 +496,6 @@ void pnpbios_calls_init(union pnp_bios_i +@@ -488,4 +496,6 @@ void pnpbios_calls_init(union pnp_bios_install_struc= t *header) set_desc_base(&gdt[GDT_ENTRY_PNPBIOS_DS], (unsigned long)__va(header->fields.pm16dseg)); } + + pax_close_kernel(); } -diff -urNp linux-2.6.32.49/drivers/pnp/resource.c linux-2.6.32.49/driver= s/pnp/resource.c ---- linux-2.6.32.49/drivers/pnp/resource.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/pnp/resource.c 2011-11-15 19:59:43.000000000= -0500 -@@ -355,7 +355,7 @@ int pnp_check_irq(struct pnp_dev *dev, s +diff --git a/drivers/pnp/resource.c b/drivers/pnp/resource.c +index ba97654..66b99d4 100644 +--- a/drivers/pnp/resource.c ++++ b/drivers/pnp/resource.c +@@ -355,7 +355,7 @@ int pnp_check_irq(struct pnp_dev *dev, struct resour= ce *res) return 1; =20 /* check if the resource is valid */ @@ -38366,7 +40100,7 @@ diff -urNp linux-2.6.32.49/drivers/pnp/resource.c= linux-2.6.32.49/drivers/pnp/re return 0; =20 /* check if the resource is reserved */ -@@ -419,7 +419,7 @@ int pnp_check_dma(struct pnp_dev *dev, s +@@ -419,7 +419,7 @@ int pnp_check_dma(struct pnp_dev *dev, struct resour= ce *res) return 1; =20 /* check if the resource is valid */ @@ -38375,9 +40109,10 @@ diff -urNp linux-2.6.32.49/drivers/pnp/resource.= c linux-2.6.32.49/drivers/pnp/re return 0; =20 /* check if the resource is reserved */ -diff -urNp linux-2.6.32.49/drivers/power/bq27x00_battery.c linux-2.6.32.= 49/drivers/power/bq27x00_battery.c ---- linux-2.6.32.49/drivers/power/bq27x00_battery.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/power/bq27x00_battery.c 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/drivers/power/bq27x00_battery.c b/drivers/power/bq27x00_bat= tery.c +index 62bb981..24a2dc9 100644 +--- a/drivers/power/bq27x00_battery.c ++++ b/drivers/power/bq27x00_battery.c @@ -44,7 +44,7 @@ struct bq27x00_device_info; struct bq27x00_access_methods { int (*read)(u8 reg, int *rt_value, int b_single, @@ -38387,9 +40122,10 @@ diff -urNp linux-2.6.32.49/drivers/power/bq27x00= _battery.c linux-2.6.32.49/drive =20 struct bq27x00_device_info { struct device *dev; -diff -urNp linux-2.6.32.49/drivers/rtc/rtc-dev.c linux-2.6.32.49/drivers= /rtc/rtc-dev.c ---- linux-2.6.32.49/drivers/rtc/rtc-dev.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/rtc/rtc-dev.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/drivers/rtc/rtc-dev.c b/drivers/rtc/rtc-dev.c +index 62227cd..b5b538b 100644 +--- a/drivers/rtc/rtc-dev.c ++++ b/drivers/rtc/rtc-dev.c @@ -14,6 +14,7 @@ #include #include @@ -38398,7 +40134,7 @@ diff -urNp linux-2.6.32.49/drivers/rtc/rtc-dev.c = linux-2.6.32.49/drivers/rtc/rtc #include "rtc-core.h" =20 static dev_t rtc_devt; -@@ -357,6 +358,8 @@ static long rtc_dev_ioctl(struct file *f +@@ -357,6 +358,8 @@ static long rtc_dev_ioctl(struct file *file, if (copy_from_user(&tm, uarg, sizeof(tm))) return -EFAULT; =20 @@ -38407,10 +40143,11 @@ diff -urNp linux-2.6.32.49/drivers/rtc/rtc-dev.= c linux-2.6.32.49/drivers/rtc/rtc return rtc_set_time(rtc, &tm); =20 case RTC_PIE_ON: -diff -urNp linux-2.6.32.49/drivers/s390/cio/qdio_perf.c linux-2.6.32.49/= drivers/s390/cio/qdio_perf.c ---- linux-2.6.32.49/drivers/s390/cio/qdio_perf.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/s390/cio/qdio_perf.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -31,51 +31,51 @@ static struct proc_dir_entry *qdio_perf_ +diff --git a/drivers/s390/cio/qdio_perf.c b/drivers/s390/cio/qdio_perf.c +index 968e3c7..fbc637a 100644 +--- a/drivers/s390/cio/qdio_perf.c ++++ b/drivers/s390/cio/qdio_perf.c +@@ -31,51 +31,51 @@ static struct proc_dir_entry *qdio_perf_pde; static int qdio_perf_proc_show(struct seq_file *m, void *v) { seq_printf(m, "Number of qdio interrupts\t\t\t: %li\n", @@ -38485,9 +40222,10 @@ diff -urNp linux-2.6.32.49/drivers/s390/cio/qdio= _perf.c linux-2.6.32.49/drivers/ seq_printf(m, "\n"); return 0; } -diff -urNp linux-2.6.32.49/drivers/s390/cio/qdio_perf.h linux-2.6.32.49/= drivers/s390/cio/qdio_perf.h ---- linux-2.6.32.49/drivers/s390/cio/qdio_perf.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/s390/cio/qdio_perf.h 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/drivers/s390/cio/qdio_perf.h b/drivers/s390/cio/qdio_perf.h +index ff4504c..b3604c3 100644 +--- a/drivers/s390/cio/qdio_perf.h ++++ b/drivers/s390/cio/qdio_perf.h @@ -13,46 +13,46 @@ =20 struct qdio_perf_stats { @@ -38560,9 +40298,23 @@ diff -urNp linux-2.6.32.49/drivers/s390/cio/qdio= _perf.h linux-2.6.32.49/drivers/ } =20 int qdio_setup_perf_stats(void); -diff -urNp linux-2.6.32.49/drivers/scsi/aacraid/aacraid.h linux-2.6.32.4= 9/drivers/scsi/aacraid/aacraid.h ---- linux-2.6.32.49/drivers/scsi/aacraid/aacraid.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/aacraid/aacraid.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c +index 1ddcf40..a85f062 100644 +--- a/drivers/scsi/BusLogic.c ++++ b/drivers/scsi/BusLogic.c +@@ -961,6 +961,8 @@ static int __init BusLogic_InitializeFlashPointProbe= Info(struct BusLogic_HostAda + static void __init BusLogic_InitializeProbeInfoList(struct BusLogic_Hos= tAdapter + *PrototypeHostAdapter) + { ++ pax_track_stack(); ++ + /* + If a PCI BIOS is present, interrogate it for MultiMaster and FlashP= oint + Host Adapters; otherwise, default to the standard ISA MultiMaster p= robe. +diff --git a/drivers/scsi/aacraid/aacraid.h b/drivers/scsi/aacraid/aacra= id.h +index cdbdec9..b7d560b 100644 +--- a/drivers/scsi/aacraid/aacraid.h ++++ b/drivers/scsi/aacraid/aacraid.h @@ -471,7 +471,7 @@ struct adapter_ops int (*adapter_scsi)(struct fib * fib, struct scsi_cmnd * cmd); /* Administrative operations */ @@ -38572,10 +40324,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/aacraid= /aacraid.h linux-2.6.32.49/driver =20 /* * Define which interrupt handler needs to be installed -diff -urNp linux-2.6.32.49/drivers/scsi/aacraid/commctrl.c linux-2.6.32.= 49/drivers/scsi/aacraid/commctrl.c ---- linux-2.6.32.49/drivers/scsi/aacraid/commctrl.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/aacraid/commctrl.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -481,6 +481,7 @@ static int aac_send_raw_srb(struct aac_d +diff --git a/drivers/scsi/aacraid/commctrl.c b/drivers/scsi/aacraid/comm= ctrl.c +index a5b8e7b..a6a0e43 100644 +--- a/drivers/scsi/aacraid/commctrl.c ++++ b/drivers/scsi/aacraid/commctrl.c +@@ -481,6 +481,7 @@ static int aac_send_raw_srb(struct aac_dev* dev, voi= d __user * arg) u32 actual_fibsize64, actual_fibsize =3D 0; int i; =20 @@ -38583,10 +40336,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/aacraid= /commctrl.c linux-2.6.32.49/drive =20 if (dev->in_reset) { dprintk((KERN_DEBUG"aacraid: send raw srb -EBUSY\n")); -diff -urNp linux-2.6.32.49/drivers/scsi/aacraid/linit.c linux-2.6.32.49/= drivers/scsi/aacraid/linit.c ---- linux-2.6.32.49/drivers/scsi/aacraid/linit.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/aacraid/linit.c 2011-11-18 18:01:55.000= 000000 -0500 -@@ -91,7 +91,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_ +diff --git a/drivers/scsi/aacraid/linit.c b/drivers/scsi/aacraid/linit.c +index 9b97c3e..f099725 100644 +--- a/drivers/scsi/aacraid/linit.c ++++ b/drivers/scsi/aacraid/linit.c +@@ -91,7 +91,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_tbl) =3D { #elif defined(__devinitconst) static const struct pci_device_id aac_pci_tbl[] __devinitconst =3D { #else @@ -38595,10 +40349,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/aacraid= /linit.c linux-2.6.32.49/drivers/ #endif { 0x1028, 0x0001, 0x1028, 0x0001, 0, 0, 0 }, /* PERC 2/Si (Iguana/PERC= 2Si) */ { 0x1028, 0x0002, 0x1028, 0x0002, 0, 0, 1 }, /* PERC 3/Di (Opal/PERC3D= i) */ -diff -urNp linux-2.6.32.49/drivers/scsi/aic94xx/aic94xx_init.c linux-2.6= .32.49/drivers/scsi/aic94xx/aic94xx_init.c ---- linux-2.6.32.49/drivers/scsi/aic94xx/aic94xx_init.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/aic94xx/aic94xx_init.c 2011-11-18 18:01= :55.000000000 -0500 -@@ -485,7 +485,7 @@ static ssize_t asd_show_update_bios(stru +diff --git a/drivers/scsi/aic94xx/aic94xx_init.c b/drivers/scsi/aic94xx/= aic94xx_init.c +index 996f722..9127845 100644 +--- a/drivers/scsi/aic94xx/aic94xx_init.c ++++ b/drivers/scsi/aic94xx/aic94xx_init.c +@@ -485,7 +485,7 @@ static ssize_t asd_show_update_bios(struct device *d= ev, flash_error_table[i].reason); } =20 @@ -38607,7 +40362,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/aic94xx/a= ic94xx_init.c linux-2.6.32.49/d asd_show_update_bios, asd_store_update_bios); =20 static int asd_create_dev_attrs(struct asd_ha_struct *asd_ha) -@@ -1011,7 +1011,7 @@ static struct sas_domain_function_templa +@@ -1011,7 +1011,7 @@ static struct sas_domain_function_template aic94xx= _transport_functions =3D { .lldd_control_phy =3D asd_control_phy, }; =20 @@ -38616,21 +40371,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/aic94xx= /aic94xx_init.c linux-2.6.32.49/d {PCI_DEVICE(PCI_VENDOR_ID_ADAPTEC2, 0x410),0, 0, 1}, {PCI_DEVICE(PCI_VENDOR_ID_ADAPTEC2, 0x412),0, 0, 1}, {PCI_DEVICE(PCI_VENDOR_ID_ADAPTEC2, 0x416),0, 0, 1}, -diff -urNp linux-2.6.32.49/drivers/scsi/bfa/bfa_iocfc.h linux-2.6.32.49/= drivers/scsi/bfa/bfa_iocfc.h ---- linux-2.6.32.49/drivers/scsi/bfa/bfa_iocfc.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/bfa/bfa_iocfc.h 2011-11-15 19:59:43.000= 000000 -0500 -@@ -61,7 +61,7 @@ struct bfa_hwif_s { - void (*hw_isr_mode_set)(struct bfa_s *bfa, bfa_boolean_t msix); - void (*hw_msix_getvecs)(struct bfa_s *bfa, u32 *vecmap, - u32 *nvecs, u32 *maxvec); --}; -+} __no_const; - typedef void (*bfa_cb_iocfc_t) (void *cbarg, enum bfa_status status); -=20 - struct bfa_iocfc_s { -diff -urNp linux-2.6.32.49/drivers/scsi/bfa/bfa_ioc.h linux-2.6.32.49/dr= ivers/scsi/bfa/bfa_ioc.h ---- linux-2.6.32.49/drivers/scsi/bfa/bfa_ioc.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/scsi/bfa/bfa_ioc.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/drivers/scsi/bfa/bfa_ioc.h b/drivers/scsi/bfa/bfa_ioc.h +index 58efd4b..cb48dc7 100644 +--- a/drivers/scsi/bfa/bfa_ioc.h ++++ b/drivers/scsi/bfa/bfa_ioc.h @@ -127,7 +127,7 @@ struct bfa_ioc_cbfn_s { bfa_ioc_disable_cbfn_t disable_cbfn; bfa_ioc_hbfail_cbfn_t hbfail_cbfn; @@ -38640,22 +40384,24 @@ diff -urNp linux-2.6.32.49/drivers/scsi/bfa/bfa= _ioc.h linux-2.6.32.49/drivers/sc =20 /** * Heartbeat failure notification queue element. -diff -urNp linux-2.6.32.49/drivers/scsi/BusLogic.c linux-2.6.32.49/drive= rs/scsi/BusLogic.c ---- linux-2.6.32.49/drivers/scsi/BusLogic.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/scsi/BusLogic.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -961,6 +961,8 @@ static int __init BusLogic_InitializeFla - static void __init BusLogic_InitializeProbeInfoList(struct BusLogic_Hos= tAdapter - *PrototypeHostAdapter) - { -+ pax_track_stack(); -+ - /* - If a PCI BIOS is present, interrogate it for MultiMaster and FlashP= oint - Host Adapters; otherwise, default to the standard ISA MultiMaster p= robe. -diff -urNp linux-2.6.32.49/drivers/scsi/dpt_i2o.c linux-2.6.32.49/driver= s/scsi/dpt_i2o.c ---- linux-2.6.32.49/drivers/scsi/dpt_i2o.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/scsi/dpt_i2o.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1804,6 +1804,8 @@ static int adpt_i2o_passthru(adpt_hba* p +diff --git a/drivers/scsi/bfa/bfa_iocfc.h b/drivers/scsi/bfa/bfa_iocfc.h +index 7ad177e..5503586 100644 +--- a/drivers/scsi/bfa/bfa_iocfc.h ++++ b/drivers/scsi/bfa/bfa_iocfc.h +@@ -61,7 +61,7 @@ struct bfa_hwif_s { + void (*hw_isr_mode_set)(struct bfa_s *bfa, bfa_boolean_t msix); + void (*hw_msix_getvecs)(struct bfa_s *bfa, u32 *vecmap, + u32 *nvecs, u32 *maxvec); +-}; ++} __no_const; + typedef void (*bfa_cb_iocfc_t) (void *cbarg, enum bfa_status status); +=20 + struct bfa_iocfc_s { +diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c +index 4967643..cbec06b 100644 +--- a/drivers/scsi/dpt_i2o.c ++++ b/drivers/scsi/dpt_i2o.c +@@ -1804,6 +1804,8 @@ static int adpt_i2o_passthru(adpt_hba* pHba, u32 _= _user *arg) dma_addr_t addr; ulong flags =3D 0; =20 @@ -38664,7 +40410,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/dpt_i2o.c= linux-2.6.32.49/drivers/scsi/d memset(&msg, 0, MAX_MESSAGE_SIZE*4); // get user msg size in u32s=20 if(get_user(size, &user_msg[0])){ -@@ -2297,6 +2299,8 @@ static s32 adpt_scsi_to_i2o(adpt_hba* pH +@@ -2297,6 +2299,8 @@ static s32 adpt_scsi_to_i2o(adpt_hba* pHba, struct= scsi_cmnd* cmd, struct adpt_d s32 rcode; dma_addr_t addr; =20 @@ -38673,10 +40419,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/dpt_i2o= .c linux-2.6.32.49/drivers/scsi/d memset(msg, 0 , sizeof(msg)); len =3D scsi_bufflen(cmd); direction =3D 0x00000000;=09 -diff -urNp linux-2.6.32.49/drivers/scsi/eata.c linux-2.6.32.49/drivers/s= csi/eata.c ---- linux-2.6.32.49/drivers/scsi/eata.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/scsi/eata.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1087,6 +1087,8 @@ static int port_detect(unsigned long por +diff --git a/drivers/scsi/eata.c b/drivers/scsi/eata.c +index c7076ce..e20c67c 100644 +--- a/drivers/scsi/eata.c ++++ b/drivers/scsi/eata.c +@@ -1087,6 +1087,8 @@ static int port_detect(unsigned long port_base, un= signed int j, struct hostdata *ha; char name[16]; =20 @@ -38685,10 +40432,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/eata.c = linux-2.6.32.49/drivers/scsi/eata sprintf(name, "%s%d", driver_name, j); =20 if (!request_region(port_base, REGION_SIZE, driver_name)) { -diff -urNp linux-2.6.32.49/drivers/scsi/fcoe/libfcoe.c linux-2.6.32.49/d= rivers/scsi/fcoe/libfcoe.c ---- linux-2.6.32.49/drivers/scsi/fcoe/libfcoe.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/scsi/fcoe/libfcoe.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -809,6 +809,8 @@ static void fcoe_ctlr_recv_els(struct fc +diff --git a/drivers/scsi/fcoe/libfcoe.c b/drivers/scsi/fcoe/libfcoe.c +index 11ae5c9..891daec 100644 +--- a/drivers/scsi/fcoe/libfcoe.c ++++ b/drivers/scsi/fcoe/libfcoe.c +@@ -809,6 +809,8 @@ static void fcoe_ctlr_recv_els(struct fcoe_ctlr *fip= , struct sk_buff *skb) size_t rlen; size_t dlen; =20 @@ -38697,10 +40445,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/fcoe/li= bfcoe.c linux-2.6.32.49/drivers/s fiph =3D (struct fip_header *)skb->data; sub =3D fiph->fip_subcode; if (sub !=3D FIP_SC_REQ && sub !=3D FIP_SC_REP) -diff -urNp linux-2.6.32.49/drivers/scsi/fnic/fnic_main.c linux-2.6.32.49= /drivers/scsi/fnic/fnic_main.c ---- linux-2.6.32.49/drivers/scsi/fnic/fnic_main.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/fnic/fnic_main.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -669,7 +669,7 @@ static int __devinit fnic_probe(struct p +diff --git a/drivers/scsi/fnic/fnic_main.c b/drivers/scsi/fnic/fnic_main= .c +index 71c7bbe..e93088a 100644 +--- a/drivers/scsi/fnic/fnic_main.c ++++ b/drivers/scsi/fnic/fnic_main.c +@@ -669,7 +669,7 @@ static int __devinit fnic_probe(struct pci_dev *pdev= , /* Start local port initiatialization */ =20 lp->link_up =3D 0; @@ -38709,9 +40458,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/fnic/fni= c_main.c linux-2.6.32.49/drivers =20 lp->max_retry_count =3D fnic->config.flogi_retries; lp->max_rport_retry_count =3D fnic->config.plogi_retries; -diff -urNp linux-2.6.32.49/drivers/scsi/gdth.c linux-2.6.32.49/drivers/s= csi/gdth.c ---- linux-2.6.32.49/drivers/scsi/gdth.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/scsi/gdth.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/drivers/scsi/gdth.c b/drivers/scsi/gdth.c +index bb96d74..9ec3ce4 100644 +--- a/drivers/scsi/gdth.c ++++ b/drivers/scsi/gdth.c @@ -4102,6 +4102,8 @@ static int ioc_lockdrv(void __user *arg) ulong flags; gdth_ha_str *ha; @@ -38721,7 +40471,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/gdth.c li= nux-2.6.32.49/drivers/scsi/gdth if (copy_from_user(&ldrv, arg, sizeof(gdth_ioctl_lockdrv))) return -EFAULT; ha =3D gdth_find_ha(ldrv.ionode); -@@ -4134,6 +4136,8 @@ static int ioc_resetdrv(void __user *arg +@@ -4134,6 +4136,8 @@ static int ioc_resetdrv(void __user *arg, char *cm= nd) gdth_ha_str *ha; int rval; =20 @@ -38730,7 +40480,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/gdth.c li= nux-2.6.32.49/drivers/scsi/gdth if (copy_from_user(&res, arg, sizeof(gdth_ioctl_reset)) || res.number >=3D MAX_HDRIVES) return -EFAULT; -@@ -4169,6 +4173,8 @@ static int ioc_general(void __user *arg, +@@ -4169,6 +4173,8 @@ static int ioc_general(void __user *arg, char *cmn= d) gdth_ha_str *ha; int rval; =20 @@ -38749,10 +40499,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/gdth.c = linux-2.6.32.49/drivers/scsi/gdth memset(cmnd, 0xff, MAX_COMMAND_SIZE); =20 TRACE2(("gdth_flush() hanum %d\n", ha->hanum)); -diff -urNp linux-2.6.32.49/drivers/scsi/gdth_proc.c linux-2.6.32.49/driv= ers/scsi/gdth_proc.c ---- linux-2.6.32.49/drivers/scsi/gdth_proc.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/scsi/gdth_proc.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -46,6 +46,9 @@ static int gdth_set_asc_info(struct Scsi +diff --git a/drivers/scsi/gdth_proc.c b/drivers/scsi/gdth_proc.c +index 1258da3..20d8ae6 100644 +--- a/drivers/scsi/gdth_proc.c ++++ b/drivers/scsi/gdth_proc.c +@@ -46,6 +46,9 @@ static int gdth_set_asc_info(struct Scsi_Host *host, c= har *buffer, ulong64 paddr; =20 char cmnd[MAX_COMMAND_SIZE]; @@ -38762,7 +40513,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/gdth_proc= .c linux-2.6.32.49/drivers/scsi memset(cmnd, 0xff, 12); memset(&gdtcmd, 0, sizeof(gdth_cmd_str)); =20 -@@ -174,6 +177,8 @@ static int gdth_get_info(char *buffer,ch +@@ -174,6 +177,8 @@ static int gdth_get_info(char *buffer,char **start,o= ff_t offset,int length, gdth_hget_str *phg; char cmnd[MAX_COMMAND_SIZE]; =20 @@ -38771,9 +40522,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/gdth_pro= c.c linux-2.6.32.49/drivers/scsi gdtcmd =3D kmalloc(sizeof(*gdtcmd), GFP_KERNEL); estr =3D kmalloc(sizeof(*estr), GFP_KERNEL); if (!gdtcmd || !estr) -diff -urNp linux-2.6.32.49/drivers/scsi/hosts.c linux-2.6.32.49/drivers/= scsi/hosts.c ---- linux-2.6.32.49/drivers/scsi/hosts.c 2011-11-26 19:44:53.000000000 -= 0500 -+++ linux-2.6.32.49/drivers/scsi/hosts.c 2011-11-26 19:45:06.000000000 -= 0500 +diff --git a/drivers/scsi/hosts.c b/drivers/scsi/hosts.c +index d03a926..f324286 100644 +--- a/drivers/scsi/hosts.c ++++ b/drivers/scsi/hosts.c @@ -40,7 +40,7 @@ #include "scsi_logging.h" =20 @@ -38783,7 +40535,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/hosts.c l= inux-2.6.32.49/drivers/scsi/hos =20 =20 static void scsi_host_cls_release(struct device *dev) -@@ -347,7 +347,7 @@ struct Scsi_Host *scsi_host_alloc(struct +@@ -347,7 +347,7 @@ struct Scsi_Host *scsi_host_alloc(struct scsi_host_t= emplate *sht, int privsize) * subtract one because we increment first then return, but we need to * know what the next host number was before increment */ @@ -38792,10 +40544,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/hosts.c= linux-2.6.32.49/drivers/scsi/hos shost->dma_channel =3D 0xff; =20 /* These three are default values which can be overridden */ -diff -urNp linux-2.6.32.49/drivers/scsi/ipr.c linux-2.6.32.49/drivers/sc= si/ipr.c ---- linux-2.6.32.49/drivers/scsi/ipr.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/scsi/ipr.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -5286,7 +5286,7 @@ static bool ipr_qc_fill_rtf(struct ata_q +diff --git a/drivers/scsi/ipr.c b/drivers/scsi/ipr.c +index a601159..55e19d2 100644 +--- a/drivers/scsi/ipr.c ++++ b/drivers/scsi/ipr.c +@@ -5286,7 +5286,7 @@ static bool ipr_qc_fill_rtf(struct ata_queued_cmd = *qc) return true; } =20 @@ -38804,9 +40557,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/ipr.c li= nux-2.6.32.49/drivers/scsi/ipr.c .phy_reset =3D ipr_ata_phy_reset, .hardreset =3D ipr_sata_reset, .post_internal_cmd =3D ipr_ata_post_internal, -diff -urNp linux-2.6.32.49/drivers/scsi/ips.h linux-2.6.32.49/drivers/sc= si/ips.h ---- linux-2.6.32.49/drivers/scsi/ips.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/drivers/scsi/ips.h 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/drivers/scsi/ips.h b/drivers/scsi/ips.h +index 4e49fbc..97907ff 100644 +--- a/drivers/scsi/ips.h ++++ b/drivers/scsi/ips.h @@ -1027,7 +1027,7 @@ typedef struct { int (*intr)(struct ips_ha *); void (*enableint)(struct ips_ha *); @@ -38816,9 +40570,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/ips.h li= nux-2.6.32.49/drivers/scsi/ips.h =20 typedef struct ips_ha { uint8_t ha_id[IPS_MAX_CHANNELS+1]; -diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_exch.c linux-2.6.32.49/= drivers/scsi/libfc/fc_exch.c ---- linux-2.6.32.49/drivers/scsi/libfc/fc_exch.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/libfc/fc_exch.c 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/drivers/scsi/libfc/fc_exch.c b/drivers/scsi/libfc/fc_exch.c +index c1c1574..a9c9348 100644 +--- a/drivers/scsi/libfc/fc_exch.c ++++ b/drivers/scsi/libfc/fc_exch.c @@ -86,12 +86,12 @@ struct fc_exch_mgr { * all together if not used XXX */ @@ -38838,7 +40593,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ } stats; }; #define fc_seq_exch(sp) container_of(sp, struct fc_exch, seq) -@@ -510,7 +510,7 @@ static struct fc_exch *fc_exch_em_alloc( +@@ -510,7 +510,7 @@ static struct fc_exch *fc_exch_em_alloc(struct fc_lp= ort *lport, /* allocate memory for exchange */ ep =3D mempool_alloc(mp->ep_pool, GFP_ATOMIC); if (!ep) { @@ -38856,7 +40611,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ mempool_free(ep, mp->ep_pool); return NULL; } -@@ -690,7 +690,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -690,7 +690,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, xid =3D ntohs(fh->fh_ox_id); /* we originated exch */ ep =3D fc_exch_find(mp, xid); if (!ep) { @@ -38865,7 +40620,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ reject =3D FC_RJT_OX_ID; goto out; } -@@ -720,7 +720,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -720,7 +720,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, ep =3D fc_exch_find(mp, xid); if ((f_ctl & FC_FC_FIRST_SEQ) && fc_sof_is_init(fr_sof(fp))) { if (ep) { @@ -38874,7 +40629,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ reject =3D FC_RJT_RX_ID; goto rel; } -@@ -731,7 +731,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -731,7 +731,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, } xid =3D ep->xid; /* get our XID */ } else if (!ep) { @@ -38883,7 +40638,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ reject =3D FC_RJT_RX_ID; /* XID not found */ goto out; } -@@ -752,7 +752,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -752,7 +752,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, } else { sp =3D &ep->seq; if (sp->id !=3D fh->fh_seq_id) { @@ -38892,7 +40647,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ reject =3D FC_RJT_SEQ_ID; /* sequence/exch should exist */ goto rel; } -@@ -1163,22 +1163,22 @@ static void fc_exch_recv_seq_resp(struct +@@ -1163,22 +1163,22 @@ static void fc_exch_recv_seq_resp(struct fc_exch= _mgr *mp, struct fc_frame *fp) =20 ep =3D fc_exch_find(mp, ntohs(fh->fh_ox_id)); if (!ep) { @@ -38919,7 +40674,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ goto rel; } sof =3D fr_sof(fp); -@@ -1189,7 +1189,7 @@ static void fc_exch_recv_seq_resp(struct +@@ -1189,7 +1189,7 @@ static void fc_exch_recv_seq_resp(struct fc_exch_m= gr *mp, struct fc_frame *fp) } else { sp =3D &ep->seq; if (sp->id !=3D fh->fh_seq_id) { @@ -38928,7 +40683,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/fc_= exch.c linux-2.6.32.49/drivers/ goto rel; } } -@@ -1249,9 +1249,9 @@ static void fc_exch_recv_resp(struct fc_ +@@ -1249,9 +1249,9 @@ static void fc_exch_recv_resp(struct fc_exch_mgr *= mp, struct fc_frame *fp) sp =3D fc_seq_lookup_orig(mp, fp); /* doesn't hold sequence */ =20 if (!sp) @@ -38940,10 +40695,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libfc/f= c_exch.c linux-2.6.32.49/drivers/ =20 fc_frame_free(fp); } -diff -urNp linux-2.6.32.49/drivers/scsi/libsas/sas_ata.c linux-2.6.32.49= /drivers/scsi/libsas/sas_ata.c ---- linux-2.6.32.49/drivers/scsi/libsas/sas_ata.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/libsas/sas_ata.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -343,7 +343,7 @@ static int sas_ata_scr_read(struct ata_l +diff --git a/drivers/scsi/libsas/sas_ata.c b/drivers/scsi/libsas/sas_ata= .c +index 0ee989f..a582241 100644 +--- a/drivers/scsi/libsas/sas_ata.c ++++ b/drivers/scsi/libsas/sas_ata.c +@@ -343,7 +343,7 @@ static int sas_ata_scr_read(struct ata_link *link, u= nsigned int sc_reg_in, } } =20 @@ -38952,9 +40708,43 @@ diff -urNp linux-2.6.32.49/drivers/scsi/libsas/s= as_ata.c linux-2.6.32.49/drivers .phy_reset =3D sas_ata_phy_reset, .post_internal_cmd =3D sas_ata_post_internal, .qc_defer =3D ata_std_qc_defer, -diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc_debugfs.c linux-2.6.32= .49/drivers/scsi/lpfc/lpfc_debugfs.c ---- linux-2.6.32.49/drivers/scsi/lpfc/lpfc_debugfs.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/lpfc/lpfc_debugfs.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/scsi/lpfc/lpfc.h b/drivers/scsi/lpfc/lpfc.h +index aa10f79..5cc79e4 100644 +--- a/drivers/scsi/lpfc/lpfc.h ++++ b/drivers/scsi/lpfc/lpfc.h +@@ -400,7 +400,7 @@ struct lpfc_vport { + struct dentry *debug_nodelist; + struct dentry *vport_debugfs_root; + struct lpfc_debugfs_trc *disc_trc; +- atomic_t disc_trc_cnt; ++ atomic_unchecked_t disc_trc_cnt; + #endif + uint8_t stat_data_enabled; + uint8_t stat_data_blocked; +@@ -725,8 +725,8 @@ struct lpfc_hba { + struct timer_list fabric_block_timer; + unsigned long bit_flags; + #define FABRIC_COMANDS_BLOCKED 0 +- atomic_t num_rsrc_err; +- atomic_t num_cmd_success; ++ atomic_unchecked_t num_rsrc_err; ++ atomic_unchecked_t num_cmd_success; + unsigned long last_rsrc_error_time; + unsigned long last_ramp_down_time; + unsigned long last_ramp_up_time; +@@ -740,7 +740,7 @@ struct lpfc_hba { + struct dentry *debug_dumpDif; /* BlockGuard BPL*/ + struct dentry *debug_slow_ring_trc; + struct lpfc_debugfs_trc *slow_ring_trc; +- atomic_t slow_ring_trc_cnt; ++ atomic_unchecked_t slow_ring_trc_cnt; + #endif +=20 + /* Used for deferred freeing of ELS data buffers */ +diff --git a/drivers/scsi/lpfc/lpfc_debugfs.c b/drivers/scsi/lpfc/lpfc_d= ebugfs.c +index 8d0f0de..7c77a62 100644 +--- a/drivers/scsi/lpfc/lpfc_debugfs.c ++++ b/drivers/scsi/lpfc/lpfc_debugfs.c @@ -124,7 +124,7 @@ struct lpfc_debug { int len; }; @@ -38964,7 +40754,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _debugfs.c linux-2.6.32.49/driv static unsigned long lpfc_debugfs_start_time =3D 0L; =20 /** -@@ -158,7 +158,7 @@ lpfc_debugfs_disc_trc_data(struct lpfc_v +@@ -158,7 +158,7 @@ lpfc_debugfs_disc_trc_data(struct lpfc_vport *vport,= char *buf, int size) lpfc_debugfs_enable =3D 0; =20 len =3D 0; @@ -38973,7 +40763,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _debugfs.c linux-2.6.32.49/driv (lpfc_debugfs_max_disc_trc - 1); for (i =3D index; i < lpfc_debugfs_max_disc_trc; i++) { dtp =3D vport->disc_trc + i; -@@ -219,7 +219,7 @@ lpfc_debugfs_slow_ring_trc_data(struct l +@@ -219,7 +219,7 @@ lpfc_debugfs_slow_ring_trc_data(struct lpfc_hba *phb= a, char *buf, int size) lpfc_debugfs_enable =3D 0; =20 len =3D 0; @@ -38982,7 +40772,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _debugfs.c linux-2.6.32.49/driv (lpfc_debugfs_max_slow_ring_trc - 1); for (i =3D index; i < lpfc_debugfs_max_slow_ring_trc; i++) { dtp =3D phba->slow_ring_trc + i; -@@ -397,6 +397,8 @@ lpfc_debugfs_dumpHBASlim_data(struct lpf +@@ -397,6 +397,8 @@ lpfc_debugfs_dumpHBASlim_data(struct lpfc_hba *phba,= char *buf, int size) uint32_t *ptr; char buffer[1024]; =20 @@ -38991,7 +40781,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _debugfs.c linux-2.6.32.49/driv off =3D 0; spin_lock_irq(&phba->hbalock); =20 -@@ -634,14 +636,14 @@ lpfc_debugfs_disc_trc(struct lpfc_vport=20 +@@ -634,14 +636,14 @@ lpfc_debugfs_disc_trc(struct lpfc_vport *vport, in= t mask, char *fmt, !vport || !vport->disc_trc) return; =20 @@ -39008,7 +40798,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _debugfs.c linux-2.6.32.49/driv dtp->jif =3D jiffies; #endif return; -@@ -672,14 +674,14 @@ lpfc_debugfs_slow_ring_trc(struct lpfc_h +@@ -672,14 +674,14 @@ lpfc_debugfs_slow_ring_trc(struct lpfc_hba *phba, = char *fmt, !phba || !phba->slow_ring_trc) return; =20 @@ -39025,7 +40815,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _debugfs.c linux-2.6.32.49/driv dtp->jif =3D jiffies; #endif return; -@@ -1364,7 +1366,7 @@ lpfc_debugfs_initialize(struct lpfc_vpor +@@ -1364,7 +1366,7 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport) "slow_ring buffer\n"); goto debug_failed; } @@ -39034,7 +40824,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _debugfs.c linux-2.6.32.49/driv memset(phba->slow_ring_trc, 0, (sizeof(struct lpfc_debugfs_trc) * lpfc_debugfs_max_slow_ring_trc)); -@@ -1410,7 +1412,7 @@ lpfc_debugfs_initialize(struct lpfc_vpor +@@ -1410,7 +1412,7 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport) "buffer\n"); goto debug_failed; } @@ -39043,41 +40833,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lp= fc_debugfs.c linux-2.6.32.49/driv =20 snprintf(name, sizeof(name), "discovery_trace"); vport->debug_disc_trc =3D -diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc.h linux-2.6.32.49/driv= ers/scsi/lpfc/lpfc.h ---- linux-2.6.32.49/drivers/scsi/lpfc/lpfc.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/scsi/lpfc/lpfc.h 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -400,7 +400,7 @@ struct lpfc_vport { - struct dentry *debug_nodelist; - struct dentry *vport_debugfs_root; - struct lpfc_debugfs_trc *disc_trc; -- atomic_t disc_trc_cnt; -+ atomic_unchecked_t disc_trc_cnt; - #endif - uint8_t stat_data_enabled; - uint8_t stat_data_blocked; -@@ -725,8 +725,8 @@ struct lpfc_hba { - struct timer_list fabric_block_timer; - unsigned long bit_flags; - #define FABRIC_COMANDS_BLOCKED 0 -- atomic_t num_rsrc_err; -- atomic_t num_cmd_success; -+ atomic_unchecked_t num_rsrc_err; -+ atomic_unchecked_t num_cmd_success; - unsigned long last_rsrc_error_time; - unsigned long last_ramp_down_time; - unsigned long last_ramp_up_time; -@@ -740,7 +740,7 @@ struct lpfc_hba { - struct dentry *debug_dumpDif; /* BlockGuard BPL*/ - struct dentry *debug_slow_ring_trc; - struct lpfc_debugfs_trc *slow_ring_trc; -- atomic_t slow_ring_trc_cnt; -+ atomic_unchecked_t slow_ring_trc_cnt; - #endif -=20 - /* Used for deferred freeing of ELS data buffers */ -diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc_init.c linux-2.6.32.49= /drivers/scsi/lpfc/lpfc_init.c ---- linux-2.6.32.49/drivers/scsi/lpfc/lpfc_init.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/lpfc/lpfc_init.c 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init= .c +index 549bc7d..8189dbb 100644 +--- a/drivers/scsi/lpfc/lpfc_init.c ++++ b/drivers/scsi/lpfc/lpfc_init.c @@ -8021,8 +8021,10 @@ lpfc_init(void) printk(LPFC_COPYRIGHT "\n"); =20 @@ -39091,10 +40850,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lp= fc_init.c linux-2.6.32.49/drivers } lpfc_transport_template =3D fc_attach_transport(&lpfc_transport_functions); -diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc_scsi.c linux-2.6.32.49= /drivers/scsi/lpfc/lpfc_scsi.c ---- linux-2.6.32.49/drivers/scsi/lpfc/lpfc_scsi.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/lpfc/lpfc_scsi.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -259,7 +259,7 @@ lpfc_rampdown_queue_depth(struct lpfc_hb +diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi= .c +index c88f59f..ff2a42f 100644 +--- a/drivers/scsi/lpfc/lpfc_scsi.c ++++ b/drivers/scsi/lpfc/lpfc_scsi.c +@@ -259,7 +259,7 @@ lpfc_rampdown_queue_depth(struct lpfc_hba *phba) uint32_t evt_posted; =20 spin_lock_irqsave(&phba->hbalock, flags); @@ -39103,7 +40863,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _scsi.c linux-2.6.32.49/drivers phba->last_rsrc_error_time =3D jiffies; =20 if ((phba->last_ramp_down_time + QUEUE_RAMP_DOWN_INTERVAL) > jiffies) = { -@@ -300,7 +300,7 @@ lpfc_rampup_queue_depth(struct lpfc_vpor +@@ -300,7 +300,7 @@ lpfc_rampup_queue_depth(struct lpfc_vport *vport, unsigned long flags; struct lpfc_hba *phba =3D vport->phba; uint32_t evt_posted; @@ -39112,7 +40872,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _scsi.c linux-2.6.32.49/drivers =20 if (vport->cfg_lun_queue_depth <=3D queue_depth) return; -@@ -343,8 +343,8 @@ lpfc_ramp_down_queue_handler(struct lpfc +@@ -343,8 +343,8 @@ lpfc_ramp_down_queue_handler(struct lpfc_hba *phba) int i; struct lpfc_rport_data *rdata; =20 @@ -39123,7 +40883,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _scsi.c linux-2.6.32.49/drivers =20 vports =3D lpfc_create_vport_work_array(phba); if (vports !=3D NULL) -@@ -378,8 +378,8 @@ lpfc_ramp_down_queue_handler(struct lpfc +@@ -378,8 +378,8 @@ lpfc_ramp_down_queue_handler(struct lpfc_hba *phba) } } lpfc_destroy_vport_work_array(phba, vports); @@ -39134,7 +40894,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lpfc= _scsi.c linux-2.6.32.49/drivers } =20 /** -@@ -427,8 +427,8 @@ lpfc_ramp_up_queue_handler(struct lpfc_h +@@ -427,8 +427,8 @@ lpfc_ramp_up_queue_handler(struct lpfc_hba *phba) } } lpfc_destroy_vport_work_array(phba, vports); @@ -39145,10 +40905,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/lpfc/lp= fc_scsi.c linux-2.6.32.49/drivers } =20 /** -diff -urNp linux-2.6.32.49/drivers/scsi/megaraid/megaraid_mbox.c linux-2= .6.32.49/drivers/scsi/megaraid/megaraid_mbox.c ---- linux-2.6.32.49/drivers/scsi/megaraid/megaraid_mbox.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/megaraid/megaraid_mbox.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -3503,6 +3503,8 @@ megaraid_cmm_register(adapter_t *adapter +diff --git a/drivers/scsi/megaraid/megaraid_mbox.c b/drivers/scsi/megara= id/megaraid_mbox.c +index 234f0b7..3020aea 100644 +--- a/drivers/scsi/megaraid/megaraid_mbox.c ++++ b/drivers/scsi/megaraid/megaraid_mbox.c +@@ -3503,6 +3503,8 @@ megaraid_cmm_register(adapter_t *adapter) int rval; int i; =20 @@ -39157,10 +40918,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/megarai= d/megaraid_mbox.c linux-2.6.32.49 // Allocate memory for the base list of scb for management module. adapter->uscb_list =3D kcalloc(MBOX_MAX_USER_CMDS, sizeof(scb_t), GFP_= KERNEL); =20 -diff -urNp linux-2.6.32.49/drivers/scsi/osd/osd_initiator.c linux-2.6.32= .49/drivers/scsi/osd/osd_initiator.c ---- linux-2.6.32.49/drivers/scsi/osd/osd_initiator.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/osd/osd_initiator.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -94,6 +94,8 @@ static int _osd_print_system_info(struct +diff --git a/drivers/scsi/osd/osd_initiator.c b/drivers/scsi/osd/osd_ini= tiator.c +index 7a117c1..ee01e9e 100644 +--- a/drivers/scsi/osd/osd_initiator.c ++++ b/drivers/scsi/osd/osd_initiator.c +@@ -94,6 +94,8 @@ static int _osd_print_system_info(struct osd_dev *od, = void *caps) int nelem =3D ARRAY_SIZE(get_attrs), a =3D 0; int ret; =20 @@ -39169,10 +40931,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/osd/osd= _initiator.c linux-2.6.32.49/driv or =3D osd_start_request(od, GFP_KERNEL); if (!or) return -ENOMEM; -diff -urNp linux-2.6.32.49/drivers/scsi/pmcraid.c linux-2.6.32.49/driver= s/scsi/pmcraid.c ---- linux-2.6.32.49/drivers/scsi/pmcraid.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/scsi/pmcraid.c 2011-11-15 19:59:43.000000000= -0500 -@@ -189,8 +189,8 @@ static int pmcraid_slave_alloc(struct sc +diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c +index 9ab8c86..9425ad3 100644 +--- a/drivers/scsi/pmcraid.c ++++ b/drivers/scsi/pmcraid.c +@@ -189,8 +189,8 @@ static int pmcraid_slave_alloc(struct scsi_device *s= csi_dev) res->scsi_dev =3D scsi_dev; scsi_dev->hostdata =3D res; res->change_detected =3D 0; @@ -39183,7 +40946,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/pmcraid.c= linux-2.6.32.49/drivers/scsi/p rc =3D 0; } spin_unlock_irqrestore(&pinstance->resource_lock, lock_flags); -@@ -2396,9 +2396,9 @@ static int pmcraid_error_handler(struct=20 +@@ -2396,9 +2396,9 @@ static int pmcraid_error_handler(struct pmcraid_cm= d *cmd) =20 /* If this was a SCSI read/write command keep count of errors */ if (SCSI_CMD_TYPE(scsi_cmd->cmnd[0]) =3D=3D SCSI_READ_CMD) @@ -39195,7 +40958,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/pmcraid.c= linux-2.6.32.49/drivers/scsi/p =20 if (!RES_IS_GSCSI(res->cfg_entry) && masked_ioasc !=3D PMCRAID_IOASC_HW_DEVICE_BUS_STATUS_ERROR) { -@@ -4116,7 +4116,7 @@ static void pmcraid_worker_function(stru +@@ -4116,7 +4116,7 @@ static void pmcraid_worker_function(struct work_st= ruct *workp) =20 pinstance =3D container_of(workp, struct pmcraid_instance, worker_q); /* add resources only after host is added into system */ @@ -39204,7 +40967,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/pmcraid.c= linux-2.6.32.49/drivers/scsi/p return; =20 spin_lock_irqsave(&pinstance->resource_lock, lock_flags); -@@ -4850,7 +4850,7 @@ static int __devinit pmcraid_init_instan +@@ -4850,7 +4850,7 @@ static int __devinit pmcraid_init_instance( init_waitqueue_head(&pinstance->reset_wait_q); =20 atomic_set(&pinstance->outstanding_cmds, 0); @@ -39222,9 +40985,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/pmcraid.= c linux-2.6.32.49/drivers/scsi/p schedule_work(&pinstance->worker_q); return rc; =20 -diff -urNp linux-2.6.32.49/drivers/scsi/pmcraid.h linux-2.6.32.49/driver= s/scsi/pmcraid.h ---- linux-2.6.32.49/drivers/scsi/pmcraid.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/scsi/pmcraid.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/drivers/scsi/pmcraid.h b/drivers/scsi/pmcraid.h +index 3441b3f..6cbe8f7 100644 +--- a/drivers/scsi/pmcraid.h ++++ b/drivers/scsi/pmcraid.h @@ -690,7 +690,7 @@ struct pmcraid_instance { atomic_t outstanding_cmds; =20 @@ -39245,9 +41009,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/pmcraid.= h linux-2.6.32.49/drivers/scsi/p =20 /* To indicate add/delete/modify during CCN */ u8 change_detected; -diff -urNp linux-2.6.32.49/drivers/scsi/qla2xxx/qla_def.h linux-2.6.32.4= 9/drivers/scsi/qla2xxx/qla_def.h ---- linux-2.6.32.49/drivers/scsi/qla2xxx/qla_def.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/qla2xxx/qla_def.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_d= ef.h +index 2150618..7034215 100644 +--- a/drivers/scsi/qla2xxx/qla_def.h ++++ b/drivers/scsi/qla2xxx/qla_def.h @@ -2089,7 +2089,7 @@ struct isp_operations { =20 int (*get_flash_version) (struct scsi_qla_host *, void *); @@ -39257,9 +41022,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/qla2xxx/= qla_def.h linux-2.6.32.49/driver =20 /* MSI-X Support ******************************************************= *******/ =20 -diff -urNp linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_def.h linux-2.6.32.4= 9/drivers/scsi/qla4xxx/ql4_def.h ---- linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_def.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_def.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/scsi/qla4xxx/ql4_def.h b/drivers/scsi/qla4xxx/ql4_d= ef.h +index 81b5f29..2ae1fad 100644 +--- a/drivers/scsi/qla4xxx/ql4_def.h ++++ b/drivers/scsi/qla4xxx/ql4_def.h @@ -240,7 +240,7 @@ struct ddb_entry { atomic_t retry_relogin_timer; /* Min Time between relogins * (4000 only) */ @@ -39269,10 +41035,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/qla4xxx= /ql4_def.h linux-2.6.32.49/driver * retried */ =20 uint16_t port; -diff -urNp linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_init.c linux-2.6.32.= 49/drivers/scsi/qla4xxx/ql4_init.c ---- linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_init.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_init.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -482,7 +482,7 @@ static struct ddb_entry * qla4xxx_alloc_ +diff --git a/drivers/scsi/qla4xxx/ql4_init.c b/drivers/scsi/qla4xxx/ql4_= init.c +index af8c323..515dd51 100644 +--- a/drivers/scsi/qla4xxx/ql4_init.c ++++ b/drivers/scsi/qla4xxx/ql4_init.c +@@ -482,7 +482,7 @@ static struct ddb_entry * qla4xxx_alloc_ddb(struct s= csi_qla_host *ha, atomic_set(&ddb_entry->port_down_timer, ha->port_down_retry_count); atomic_set(&ddb_entry->retry_relogin_timer, INVALID_ENTRY); atomic_set(&ddb_entry->relogin_timer, 0); @@ -39281,7 +41048,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/qla4xxx/q= l4_init.c linux-2.6.32.49/drive atomic_set(&ddb_entry->state, DDB_STATE_ONLINE); list_add_tail(&ddb_entry->list, &ha->ddb_list); ha->fw_ddb_index_map[fw_ddb_index] =3D ddb_entry; -@@ -1308,7 +1308,7 @@ int qla4xxx_process_ddb_changed(struct s +@@ -1308,7 +1308,7 @@ int qla4xxx_process_ddb_changed(struct scsi_qla_ho= st *ha, atomic_set(&ddb_entry->state, DDB_STATE_ONLINE); atomic_set(&ddb_entry->port_down_timer, ha->port_down_retry_count); @@ -39290,10 +41057,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/qla4xxx= /ql4_init.c linux-2.6.32.49/drive atomic_set(&ddb_entry->relogin_timer, 0); clear_bit(DF_RELOGIN, &ddb_entry->flags); clear_bit(DF_NO_RELOGIN, &ddb_entry->flags); -diff -urNp linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_os.c linux-2.6.32.49= /drivers/scsi/qla4xxx/ql4_os.c ---- linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_os.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/qla4xxx/ql4_os.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -641,13 +641,13 @@ static void qla4xxx_timer(struct scsi_ql +diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os= .c +index 83c8b5e..a82b348 100644 +--- a/drivers/scsi/qla4xxx/ql4_os.c ++++ b/drivers/scsi/qla4xxx/ql4_os.c +@@ -641,13 +641,13 @@ static void qla4xxx_timer(struct scsi_qla_host *ha= ) ddb_entry->fw_ddb_device_state =3D=3D DDB_DS_SESSION_FAILED) { /* Reset retry relogin timer */ @@ -39309,10 +41077,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/qla4xxx= /ql4_os.c linux-2.6.32.49/drivers relogin_retry_count)) ); start_dpc++; -diff -urNp linux-2.6.32.49/drivers/scsi/scsi.c linux-2.6.32.49/drivers/s= csi/scsi.c ---- linux-2.6.32.49/drivers/scsi/scsi.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/drivers/scsi/scsi.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -652,7 +652,7 @@ int scsi_dispatch_cmd(struct scsi_cmnd * +diff --git a/drivers/scsi/scsi.c b/drivers/scsi/scsi.c +index dd098ca..686ce01 100644 +--- a/drivers/scsi/scsi.c ++++ b/drivers/scsi/scsi.c +@@ -652,7 +652,7 @@ int scsi_dispatch_cmd(struct scsi_cmnd *cmd) unsigned long timeout; int rtn =3D 0; =20 @@ -39321,10 +41090,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi.c = linux-2.6.32.49/drivers/scsi/scsi =20 /* check if the device is still usable */ if (unlikely(cmd->device->sdev_state =3D=3D SDEV_DEL)) { -diff -urNp linux-2.6.32.49/drivers/scsi/scsi_debug.c linux-2.6.32.49/dri= vers/scsi/scsi_debug.c ---- linux-2.6.32.49/drivers/scsi/scsi_debug.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/scsi/scsi_debug.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -1395,6 +1395,8 @@ static int resp_mode_select(struct scsi_ +diff --git a/drivers/scsi/scsi_debug.c b/drivers/scsi/scsi_debug.c +index bc3e363..e1a8e50 100644 +--- a/drivers/scsi/scsi_debug.c ++++ b/drivers/scsi/scsi_debug.c +@@ -1395,6 +1395,8 @@ static int resp_mode_select(struct scsi_cmnd * scp= , int mselect6, unsigned char arr[SDEBUG_MAX_MSELECT_SZ]; unsigned char *cmd =3D (unsigned char *)scp->cmnd; =20 @@ -39333,7 +41103,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_debu= g.c linux-2.6.32.49/drivers/scs if ((errsts =3D check_readiness(scp, 1, devip))) return errsts; memset(arr, 0, sizeof(arr)); -@@ -1492,6 +1494,8 @@ static int resp_log_sense(struct scsi_cm +@@ -1492,6 +1494,8 @@ static int resp_log_sense(struct scsi_cmnd * scp, unsigned char arr[SDEBUG_MAX_LSENSE_SZ]; unsigned char *cmd =3D (unsigned char *)scp->cmnd; =20 @@ -39342,10 +41112,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_de= bug.c linux-2.6.32.49/drivers/scs if ((errsts =3D check_readiness(scp, 1, devip))) return errsts; memset(arr, 0, sizeof(arr)); -diff -urNp linux-2.6.32.49/drivers/scsi/scsi_lib.c linux-2.6.32.49/drive= rs/scsi/scsi_lib.c ---- linux-2.6.32.49/drivers/scsi/scsi_lib.c 2011-11-26 19:44:53.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/scsi/scsi_lib.c 2011-11-26 19:45:06.00000000= 0 -0500 -@@ -1384,7 +1384,7 @@ static void scsi_kill_request(struct req +diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c +index 1ae7b7c..0a44924 100644 +--- a/drivers/scsi/scsi_lib.c ++++ b/drivers/scsi/scsi_lib.c +@@ -1384,7 +1384,7 @@ static void scsi_kill_request(struct request *req,= struct request_queue *q) =20 scsi_init_cmd_errh(cmd); cmd->result =3D DID_NO_CONNECT << 16; @@ -39354,7 +41125,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_lib.= c linux-2.6.32.49/drivers/scsi/ =20 /* * SCSI request completion path will do scsi_device_unbusy(), -@@ -1415,9 +1415,9 @@ static void scsi_softirq_done(struct req +@@ -1415,9 +1415,9 @@ static void scsi_softirq_done(struct request *rq) */ cmd->serial_number =3D 0; =20 @@ -39366,10 +41137,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_li= b.c linux-2.6.32.49/drivers/scsi/ =20 disposition =3D scsi_decide_disposition(cmd); if (disposition !=3D SUCCESS && -diff -urNp linux-2.6.32.49/drivers/scsi/scsi_sysfs.c linux-2.6.32.49/dri= vers/scsi/scsi_sysfs.c ---- linux-2.6.32.49/drivers/scsi/scsi_sysfs.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/drivers/scsi/scsi_sysfs.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -662,7 +662,7 @@ show_iostat_##field(struct device *dev,=20 +diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c +index 91a93e0..eae0fe3 100644 +--- a/drivers/scsi/scsi_sysfs.c ++++ b/drivers/scsi/scsi_sysfs.c +@@ -662,7 +662,7 @@ show_iostat_##field(struct device *dev, struct devic= e_attribute *attr, \ char *buf) \ { \ struct scsi_device *sdev =3D to_scsi_device(dev); \ @@ -39378,10 +41150,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_sy= sfs.c linux-2.6.32.49/drivers/scs return snprintf(buf, 20, "0x%llx\n", count); \ } \ static DEVICE_ATTR(field, S_IRUGO, show_iostat_##field, NULL) -diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tgt_lib.c linux-2.6.32.49/d= rivers/scsi/scsi_tgt_lib.c ---- linux-2.6.32.49/drivers/scsi/scsi_tgt_lib.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/scsi/scsi_tgt_lib.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -362,7 +362,7 @@ static int scsi_map_user_pages(struct sc +diff --git a/drivers/scsi/scsi_tgt_lib.c b/drivers/scsi/scsi_tgt_lib.c +index 1030327..f91fd30 100644 +--- a/drivers/scsi/scsi_tgt_lib.c ++++ b/drivers/scsi/scsi_tgt_lib.c +@@ -362,7 +362,7 @@ static int scsi_map_user_pages(struct scsi_tgt_cmd *= tcmd, struct scsi_cmnd *cmd, int err; =20 dprintk("%lx %u\n", uaddr, len); @@ -39390,9 +41163,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tgt= _lib.c linux-2.6.32.49/drivers/s if (err) { /* * TODO: need to fixup sg_tablesize, max_segment_size, -diff -urNp linux-2.6.32.49/drivers/scsi/scsi_transport_fc.c linux-2.6.32= .49/drivers/scsi/scsi_transport_fc.c ---- linux-2.6.32.49/drivers/scsi/scsi_transport_fc.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/scsi_transport_fc.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/scsi/scsi_transport_fc.c b/drivers/scsi/scsi_transp= ort_fc.c +index db02e31..1b42ea9 100644 +--- a/drivers/scsi/scsi_transport_fc.c ++++ b/drivers/scsi/scsi_transport_fc.c @@ -480,7 +480,7 @@ MODULE_PARM_DESC(dev_loss_tmo, * Netlink Infrastructure */ @@ -39411,7 +41185,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tran= sport_fc.c linux-2.6.32.49/driv } EXPORT_SYMBOL(fc_get_event_number); =20 -@@ -641,7 +641,7 @@ static __init int fc_transport_init(void +@@ -641,7 +641,7 @@ static __init int fc_transport_init(void) { int error; =20 @@ -39420,9 +41194,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tra= nsport_fc.c linux-2.6.32.49/driv =20 error =3D transport_class_register(&fc_host_class); if (error) -diff -urNp linux-2.6.32.49/drivers/scsi/scsi_transport_iscsi.c linux-2.6= .32.49/drivers/scsi/scsi_transport_iscsi.c ---- linux-2.6.32.49/drivers/scsi/scsi_transport_iscsi.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/scsi_transport_iscsi.c 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_tra= nsport_iscsi.c +index de2f8c4..63c5278 100644 +--- a/drivers/scsi/scsi_transport_iscsi.c ++++ b/drivers/scsi/scsi_transport_iscsi.c @@ -81,7 +81,7 @@ struct iscsi_internal { struct device_attribute *session_attrs[ISCSI_SESSION_ATTRS + 1]; }; @@ -39432,7 +41207,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tran= sport_iscsi.c linux-2.6.32.49/d static struct workqueue_struct *iscsi_eh_timer_workq; =20 /* -@@ -728,7 +728,7 @@ int iscsi_add_session(struct iscsi_cls_s +@@ -728,7 +728,7 @@ int iscsi_add_session(struct iscsi_cls_session *sess= ion, unsigned int target_id) int err; =20 ihost =3D shost->shost_data; @@ -39441,7 +41216,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tran= sport_iscsi.c linux-2.6.32.49/d =20 if (id =3D=3D ISCSI_MAX_TARGET) { for (id =3D 0; id < ISCSI_MAX_TARGET; id++) { -@@ -2060,7 +2060,7 @@ static __init int iscsi_transport_init(v +@@ -2060,7 +2060,7 @@ static __init int iscsi_transport_init(void) printk(KERN_INFO "Loading iSCSI transport class v%s.\n", ISCSI_TRANSPORT_VERSION); =20 @@ -39450,9 +41225,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tra= nsport_iscsi.c linux-2.6.32.49/d =20 err =3D class_register(&iscsi_transport_class); if (err) -diff -urNp linux-2.6.32.49/drivers/scsi/scsi_transport_srp.c linux-2.6.3= 2.49/drivers/scsi/scsi_transport_srp.c ---- linux-2.6.32.49/drivers/scsi/scsi_transport_srp.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/scsi_transport_srp.c 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/drivers/scsi/scsi_transport_srp.c b/drivers/scsi/scsi_trans= port_srp.c +index 21a045e..ec89e03 100644 +--- a/drivers/scsi/scsi_transport_srp.c ++++ b/drivers/scsi/scsi_transport_srp.c @@ -33,7 +33,7 @@ #include "scsi_transport_srp_internal.h" =20 @@ -39462,7 +41238,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tran= sport_srp.c linux-2.6.32.49/dri }; #define to_srp_host_attrs(host) ((struct srp_host_attrs *)(host)->shost= _data) =20 -@@ -62,7 +62,7 @@ static int srp_host_setup(struct transpo +@@ -62,7 +62,7 @@ static int srp_host_setup(struct transport_container *= tc, struct device *dev, struct Scsi_Host *shost =3D dev_to_shost(dev); struct srp_host_attrs *srp_host =3D to_srp_host_attrs(shost); =20 @@ -39471,7 +41247,7 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tran= sport_srp.c linux-2.6.32.49/dri return 0; } =20 -@@ -211,7 +211,7 @@ struct srp_rport *srp_rport_add(struct S +@@ -211,7 +211,7 @@ struct srp_rport *srp_rport_add(struct Scsi_Host *sh= ost, memcpy(rport->port_id, ids->port_id, sizeof(rport->port_id)); rport->roles =3D ids->roles; =20 @@ -39480,10 +41256,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/scsi_tr= ansport_srp.c linux-2.6.32.49/dri dev_set_name(&rport->dev, "port-%d:%d", shost->host_no, id); =20 transport_setup_device(&rport->dev); -diff -urNp linux-2.6.32.49/drivers/scsi/sg.c linux-2.6.32.49/drivers/scs= i/sg.c ---- linux-2.6.32.49/drivers/scsi/sg.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/scsi/sg.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -1064,7 +1064,7 @@ sg_ioctl(struct inode *inode, struct fil +diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c +index 040f751..98a5ed2 100644 +--- a/drivers/scsi/sg.c ++++ b/drivers/scsi/sg.c +@@ -1064,7 +1064,7 @@ sg_ioctl(struct inode *inode, struct file *filp, sdp->disk->disk_name, MKDEV(SCSI_GENERIC_MAJOR, sdp->index), NULL, @@ -39510,10 +41287,11 @@ diff -urNp linux-2.6.32.49/drivers/scsi/sg.c li= nux-2.6.32.49/drivers/scsi/sg.c =20 sg_proc_sgp =3D proc_mkdir(sg_proc_sg_dirname, NULL); if (!sg_proc_sgp) -diff -urNp linux-2.6.32.49/drivers/scsi/sym53c8xx_2/sym_glue.c linux-2.6= .32.49/drivers/scsi/sym53c8xx_2/sym_glue.c ---- linux-2.6.32.49/drivers/scsi/sym53c8xx_2/sym_glue.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/scsi/sym53c8xx_2/sym_glue.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -1754,6 +1754,8 @@ static int __devinit sym2_probe(struct p +diff --git a/drivers/scsi/sym53c8xx_2/sym_glue.c b/drivers/scsi/sym53c8x= x_2/sym_glue.c +index 45374d6..61ee484 100644 +--- a/drivers/scsi/sym53c8xx_2/sym_glue.c ++++ b/drivers/scsi/sym53c8xx_2/sym_glue.c +@@ -1754,6 +1754,8 @@ static int __devinit sym2_probe(struct pci_dev *pd= ev, int do_iounmap =3D 0; int do_disable_device =3D 1; =20 @@ -39522,9 +41300,10 @@ diff -urNp linux-2.6.32.49/drivers/scsi/sym53c8x= x_2/sym_glue.c linux-2.6.32.49/d memset(&sym_dev, 0, sizeof(sym_dev)); memset(&nvram, 0, sizeof(nvram)); sym_dev.pdev =3D pdev; -diff -urNp linux-2.6.32.49/drivers/serial/kgdboc.c linux-2.6.32.49/drive= rs/serial/kgdboc.c ---- linux-2.6.32.49/drivers/serial/kgdboc.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/serial/kgdboc.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/serial/kgdboc.c b/drivers/serial/kgdboc.c +index eadc1ab..2d81457 100644 +--- a/drivers/serial/kgdboc.c ++++ b/drivers/serial/kgdboc.c @@ -18,7 +18,7 @@ =20 #define MAX_CONFIG_LEN 40 @@ -39534,7 +41313,7 @@ diff -urNp linux-2.6.32.49/drivers/serial/kgdboc.= c linux-2.6.32.49/drivers/seria =20 /* -1 =3D init not run yet, 0 =3D unconfigured, 1 =3D configured. */ static int configured =3D -1; -@@ -154,7 +154,7 @@ static void kgdboc_post_exp_handler(void +@@ -154,7 +154,7 @@ static void kgdboc_post_exp_handler(void) module_put(THIS_MODULE); } =20 @@ -39543,10 +41322,11 @@ diff -urNp linux-2.6.32.49/drivers/serial/kgdbo= c.c linux-2.6.32.49/drivers/seria .name =3D "kgdboc", .read_char =3D kgdboc_get_char, .write_char =3D kgdboc_put_char, -diff -urNp linux-2.6.32.49/drivers/spi/spi.c linux-2.6.32.49/drivers/spi= /spi.c ---- linux-2.6.32.49/drivers/spi/spi.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/spi/spi.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -774,7 +774,7 @@ int spi_sync(struct spi_device *spi, str +diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c +index b76f246..7f41af7 100644 +--- a/drivers/spi/spi.c ++++ b/drivers/spi/spi.c +@@ -774,7 +774,7 @@ int spi_sync(struct spi_device *spi, struct spi_mess= age *message) EXPORT_SYMBOL_GPL(spi_sync); =20 /* portable code must never pass more than 32 bytes */ @@ -39555,10 +41335,11 @@ diff -urNp linux-2.6.32.49/drivers/spi/spi.c li= nux-2.6.32.49/drivers/spi/spi.c =20 static u8 *buf; =20 -diff -urNp linux-2.6.32.49/drivers/staging/android/binder.c linux-2.6.32= .49/drivers/staging/android/binder.c ---- linux-2.6.32.49/drivers/staging/android/binder.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/android/binder.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -2756,7 +2756,7 @@ static void binder_vma_close(struct vm_a +diff --git a/drivers/staging/android/binder.c b/drivers/staging/android/= binder.c +index 99010d4..6bad87b 100644 +--- a/drivers/staging/android/binder.c ++++ b/drivers/staging/android/binder.c +@@ -2756,7 +2756,7 @@ static void binder_vma_close(struct vm_area_struct= *vma) binder_defer_work(proc, BINDER_DEFERRED_PUT_FILES); } =20 @@ -39567,10 +41348,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/andr= oid/binder.c linux-2.6.32.49/driv .open =3D binder_vma_open, .close =3D binder_vma_close, }; -diff -urNp linux-2.6.32.49/drivers/staging/b3dfg/b3dfg.c linux-2.6.32.49= /drivers/staging/b3dfg/b3dfg.c ---- linux-2.6.32.49/drivers/staging/b3dfg/b3dfg.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/staging/b3dfg/b3dfg.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -455,7 +455,7 @@ static int b3dfg_vma_fault(struct vm_are +diff --git a/drivers/staging/b3dfg/b3dfg.c b/drivers/staging/b3dfg/b3dfg= .c +index cda26bb..39fed3f 100644 +--- a/drivers/staging/b3dfg/b3dfg.c ++++ b/drivers/staging/b3dfg/b3dfg.c +@@ -455,7 +455,7 @@ static int b3dfg_vma_fault(struct vm_area_struct *vm= a, return VM_FAULT_NOPAGE; } =20 @@ -39579,7 +41361,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/b3dfg/= b3dfg.c linux-2.6.32.49/drivers .fault =3D b3dfg_vma_fault, }; =20 -@@ -848,7 +848,7 @@ static int b3dfg_mmap(struct file *filp, +@@ -848,7 +848,7 @@ static int b3dfg_mmap(struct file *filp, struct vm_a= rea_struct *vma) return r; } =20 @@ -39588,10 +41370,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/b3df= g/b3dfg.c linux-2.6.32.49/drivers .owner =3D THIS_MODULE, .open =3D b3dfg_open, .release =3D b3dfg_release, -diff -urNp linux-2.6.32.49/drivers/staging/comedi/comedi_fops.c linux-2.= 6.32.49/drivers/staging/comedi/comedi_fops.c ---- linux-2.6.32.49/drivers/staging/comedi/comedi_fops.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/comedi/comedi_fops.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -1389,7 +1389,7 @@ void comedi_unmap(struct vm_area_struct=20 +diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/come= di/comedi_fops.c +index 80a1071..8c14e17 100644 +--- a/drivers/staging/comedi/comedi_fops.c ++++ b/drivers/staging/comedi/comedi_fops.c +@@ -1389,7 +1389,7 @@ void comedi_unmap(struct vm_area_struct *area) mutex_unlock(&dev->mutex); } =20 @@ -39600,10 +41383,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/come= di/comedi_fops.c linux-2.6.32.49/ .close =3D comedi_unmap, }; =20 -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/adsp_driver.c lin= ux-2.6.32.49/drivers/staging/dream/qdsp5/adsp_driver.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/adsp_driver.c 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/adsp_driver.c 2011-11-15= 19:59:43.000000000 -0500 -@@ -576,7 +576,7 @@ static struct adsp_device *inode_to_devi +diff --git a/drivers/staging/dream/qdsp5/adsp_driver.c b/drivers/staging= /dream/qdsp5/adsp_driver.c +index e55a0db..577b776 100644 +--- a/drivers/staging/dream/qdsp5/adsp_driver.c ++++ b/drivers/staging/dream/qdsp5/adsp_driver.c +@@ -576,7 +576,7 @@ static struct adsp_device *inode_to_device(struct in= ode *inode) static dev_t adsp_devno; static struct class *adsp_class; =20 @@ -39612,9 +41396,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream= /qdsp5/adsp_driver.c linux-2.6.3 .owner =3D THIS_MODULE, .open =3D adsp_open, .unlocked_ioctl =3D adsp_ioctl, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_aac.c linux= -2.6.32.49/drivers/staging/dream/qdsp5/audio_aac.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_aac.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_aac.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/staging/dream/qdsp5/audio_aac.c b/drivers/staging/d= ream/qdsp5/audio_aac.c +index ad2390f..4116ee8 100644 +--- a/drivers/staging/dream/qdsp5/audio_aac.c ++++ b/drivers/staging/dream/qdsp5/audio_aac.c @@ -1022,7 +1022,7 @@ done: return rc; } @@ -39624,9 +41409,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream= /qdsp5/audio_aac.c linux-2.6.32. .owner =3D THIS_MODULE, .open =3D audio_open, .release =3D audio_release, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_amrnb.c lin= ux-2.6.32.49/drivers/staging/dream/qdsp5/audio_amrnb.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_amrnb.c 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_amrnb.c 2011-11-15= 19:59:43.000000000 -0500 +diff --git a/drivers/staging/dream/qdsp5/audio_amrnb.c b/drivers/staging= /dream/qdsp5/audio_amrnb.c +index cd818a5..870b37b 100644 +--- a/drivers/staging/dream/qdsp5/audio_amrnb.c ++++ b/drivers/staging/dream/qdsp5/audio_amrnb.c @@ -833,7 +833,7 @@ done: return rc; } @@ -39636,9 +41422,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream= /qdsp5/audio_amrnb.c linux-2.6.3 .owner =3D THIS_MODULE, .open =3D audamrnb_open, .release =3D audamrnb_release, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_evrc.c linu= x-2.6.32.49/drivers/staging/dream/qdsp5/audio_evrc.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_evrc.c 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_evrc.c 2011-11-15 = 19:59:43.000000000 -0500 +diff --git a/drivers/staging/dream/qdsp5/audio_evrc.c b/drivers/staging/= dream/qdsp5/audio_evrc.c +index 4b43e18..cedafda 100644 +--- a/drivers/staging/dream/qdsp5/audio_evrc.c ++++ b/drivers/staging/dream/qdsp5/audio_evrc.c @@ -805,7 +805,7 @@ dma_fail: return rc; } @@ -39648,10 +41435,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/drea= m/qdsp5/audio_evrc.c linux-2.6.32 .owner =3D THIS_MODULE, .open =3D audevrc_open, .release =3D audevrc_release, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_in.c linux-= 2.6.32.49/drivers/staging/dream/qdsp5/audio_in.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_in.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_in.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -913,7 +913,7 @@ static int audpre_open(struct inode *ino +diff --git a/drivers/staging/dream/qdsp5/audio_in.c b/drivers/staging/dr= eam/qdsp5/audio_in.c +index 3d950a2..9431118 100644 +--- a/drivers/staging/dream/qdsp5/audio_in.c ++++ b/drivers/staging/dream/qdsp5/audio_in.c +@@ -913,7 +913,7 @@ static int audpre_open(struct inode *inode, struct f= ile *file) return 0; } =20 @@ -39660,7 +41448,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream/= qdsp5/audio_in.c linux-2.6.32.4 .owner =3D THIS_MODULE, .open =3D audio_in_open, .release =3D audio_in_release, -@@ -922,7 +922,7 @@ static struct file_operations audio_fops +@@ -922,7 +922,7 @@ static struct file_operations audio_fops =3D { .unlocked_ioctl =3D audio_in_ioctl, }; =20 @@ -39669,9 +41457,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream= /qdsp5/audio_in.c linux-2.6.32.4 .owner =3D THIS_MODULE, .open =3D audpre_open, .unlocked_ioctl =3D audpre_ioctl, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_mp3.c linux= -2.6.32.49/drivers/staging/dream/qdsp5/audio_mp3.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_mp3.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_mp3.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/staging/dream/qdsp5/audio_mp3.c b/drivers/staging/d= ream/qdsp5/audio_mp3.c +index b95574f..286c2f4 100644 +--- a/drivers/staging/dream/qdsp5/audio_mp3.c ++++ b/drivers/staging/dream/qdsp5/audio_mp3.c @@ -941,7 +941,7 @@ done: return rc; } @@ -39681,10 +41470,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/drea= m/qdsp5/audio_mp3.c linux-2.6.32. .owner =3D THIS_MODULE, .open =3D audio_open, .release =3D audio_release, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_out.c linux= -2.6.32.49/drivers/staging/dream/qdsp5/audio_out.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_out.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_out.c 2011-11-15 1= 9:59:43.000000000 -0500 -@@ -810,7 +810,7 @@ static int audpp_open(struct inode *inod +diff --git a/drivers/staging/dream/qdsp5/audio_out.c b/drivers/staging/d= ream/qdsp5/audio_out.c +index d1adcf6..f8f9833 100644 +--- a/drivers/staging/dream/qdsp5/audio_out.c ++++ b/drivers/staging/dream/qdsp5/audio_out.c +@@ -810,7 +810,7 @@ static int audpp_open(struct inode *inode, struct fi= le *file) return 0; } =20 @@ -39693,7 +41483,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream/= qdsp5/audio_out.c linux-2.6.32. .owner =3D THIS_MODULE, .open =3D audio_open, .release =3D audio_release, -@@ -819,7 +819,7 @@ static struct file_operations audio_fops +@@ -819,7 +819,7 @@ static struct file_operations audio_fops =3D { .unlocked_ioctl =3D audio_ioctl, }; =20 @@ -39702,9 +41492,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream= /qdsp5/audio_out.c linux-2.6.32. .owner =3D THIS_MODULE, .open =3D audpp_open, .unlocked_ioctl =3D audpp_ioctl, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_qcelp.c lin= ux-2.6.32.49/drivers/staging/dream/qdsp5/audio_qcelp.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_qcelp.c 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/audio_qcelp.c 2011-11-15= 19:59:43.000000000 -0500 +diff --git a/drivers/staging/dream/qdsp5/audio_qcelp.c b/drivers/staging= /dream/qdsp5/audio_qcelp.c +index f0f50e3..f6b9dbc 100644 +--- a/drivers/staging/dream/qdsp5/audio_qcelp.c ++++ b/drivers/staging/dream/qdsp5/audio_qcelp.c @@ -816,7 +816,7 @@ err: return rc; } @@ -39714,9 +41505,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream= /qdsp5/audio_qcelp.c linux-2.6.3 .owner =3D THIS_MODULE, .open =3D audqcelp_open, .release =3D audqcelp_release, -diff -urNp linux-2.6.32.49/drivers/staging/dream/qdsp5/snd.c linux-2.6.3= 2.49/drivers/staging/dream/qdsp5/snd.c ---- linux-2.6.32.49/drivers/staging/dream/qdsp5/snd.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/qdsp5/snd.c 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/drivers/staging/dream/qdsp5/snd.c b/drivers/staging/dream/q= dsp5/snd.c +index 037d7ff..5469ec3 100644 +--- a/drivers/staging/dream/qdsp5/snd.c ++++ b/drivers/staging/dream/qdsp5/snd.c @@ -242,7 +242,7 @@ err: return rc; } @@ -39726,10 +41518,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/drea= m/qdsp5/snd.c linux-2.6.32.49/dri .owner =3D THIS_MODULE, .open =3D snd_open, .release =3D snd_release, -diff -urNp linux-2.6.32.49/drivers/staging/dream/smd/smd_qmi.c linux-2.6= .32.49/drivers/staging/dream/smd/smd_qmi.c ---- linux-2.6.32.49/drivers/staging/dream/smd/smd_qmi.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/smd/smd_qmi.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -793,7 +793,7 @@ static int qmi_release(struct inode *ip, +diff --git a/drivers/staging/dream/smd/smd_qmi.c b/drivers/staging/dream= /smd/smd_qmi.c +index d4e7d88..0ea632a 100644 +--- a/drivers/staging/dream/smd/smd_qmi.c ++++ b/drivers/staging/dream/smd/smd_qmi.c +@@ -793,7 +793,7 @@ static int qmi_release(struct inode *ip, struct file= *fp) return 0; } =20 @@ -39738,10 +41531,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/drea= m/smd/smd_qmi.c linux-2.6.32.49/d .owner =3D THIS_MODULE, .read =3D qmi_read, .write =3D qmi_write, -diff -urNp linux-2.6.32.49/drivers/staging/dream/smd/smd_rpcrouter_devic= e.c linux-2.6.32.49/drivers/staging/dream/smd/smd_rpcrouter_device.c ---- linux-2.6.32.49/drivers/staging/dream/smd/smd_rpcrouter_device.c 201= 1-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/dream/smd/smd_rpcrouter_device.c 201= 1-11-15 19:59:43.000000000 -0500 -@@ -214,7 +214,7 @@ static long rpcrouter_ioctl(struct file=20 +diff --git a/drivers/staging/dream/smd/smd_rpcrouter_device.c b/drivers/= staging/dream/smd/smd_rpcrouter_device.c +index cd3910b..ff053d3 100644 +--- a/drivers/staging/dream/smd/smd_rpcrouter_device.c ++++ b/drivers/staging/dream/smd/smd_rpcrouter_device.c +@@ -214,7 +214,7 @@ static long rpcrouter_ioctl(struct file *filp, unsig= ned int cmd, return rc; } =20 @@ -39750,7 +41544,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/dream/= smd/smd_rpcrouter_device.c linu .owner =3D THIS_MODULE, .open =3D rpcrouter_open, .release =3D rpcrouter_release, -@@ -224,7 +224,7 @@ static struct file_operations rpcrouter_ +@@ -224,7 +224,7 @@ static struct file_operations rpcrouter_server_fops = =3D { .unlocked_ioctl =3D rpcrouter_ioctl, }; =20 @@ -39759,10 +41553,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/drea= m/smd/smd_rpcrouter_device.c linu .owner =3D THIS_MODULE, .open =3D rpcrouter_open, .release =3D rpcrouter_release, -diff -urNp linux-2.6.32.49/drivers/staging/dst/dcore.c linux-2.6.32.49/d= rivers/staging/dst/dcore.c ---- linux-2.6.32.49/drivers/staging/dst/dcore.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/staging/dst/dcore.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -149,7 +149,7 @@ static int dst_bdev_release(struct gendi +diff --git a/drivers/staging/dst/dcore.c b/drivers/staging/dst/dcore.c +index c24e4e0..07665be 100644 +--- a/drivers/staging/dst/dcore.c ++++ b/drivers/staging/dst/dcore.c +@@ -149,7 +149,7 @@ static int dst_bdev_release(struct gendisk *disk, fm= ode_t mode) return 0; } =20 @@ -39771,7 +41566,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/dst/dc= ore.c linux-2.6.32.49/drivers/s .open =3D dst_bdev_open, .release =3D dst_bdev_release, .owner =3D THIS_MODULE, -@@ -588,7 +588,7 @@ static struct dst_node *dst_alloc_node(s +@@ -588,7 +588,7 @@ static struct dst_node *dst_alloc_node(struct dst_ct= l *ctl, n->size =3D ctl->size; =20 atomic_set(&n->refcnt, 1); @@ -39780,10 +41575,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/dst/= dcore.c linux-2.6.32.49/drivers/s snprintf(n->name, sizeof(n->name), "%s", ctl->name); =20 err =3D dst_node_sysfs_init(n); -diff -urNp linux-2.6.32.49/drivers/staging/dst/trans.c linux-2.6.32.49/d= rivers/staging/dst/trans.c ---- linux-2.6.32.49/drivers/staging/dst/trans.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/staging/dst/trans.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -169,7 +169,7 @@ int dst_process_bio(struct dst_node *n,=20 +diff --git a/drivers/staging/dst/trans.c b/drivers/staging/dst/trans.c +index 557d372..8d84422 100644 +--- a/drivers/staging/dst/trans.c ++++ b/drivers/staging/dst/trans.c +@@ -169,7 +169,7 @@ int dst_process_bio(struct dst_node *n, struct bio *= bio) t->error =3D 0; t->retries =3D 0; atomic_set(&t->refcnt, 1); @@ -39792,10 +41588,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/dst/= trans.c linux-2.6.32.49/drivers/s =20 t->enc =3D bio_data_dir(bio); dst_bio_to_cmd(bio, &t->cmd, DST_IO, t->gen); -diff -urNp linux-2.6.32.49/drivers/staging/et131x/et1310_tx.c linux-2.6.= 32.49/drivers/staging/et131x/et1310_tx.c ---- linux-2.6.32.49/drivers/staging/et131x/et1310_tx.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/et131x/et1310_tx.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -710,11 +710,11 @@ inline void et131x_free_send_packet(stru +diff --git a/drivers/staging/et131x/et1310_tx.c b/drivers/staging/et131x= /et1310_tx.c +index 94f7752..d051514 100644 +--- a/drivers/staging/et131x/et1310_tx.c ++++ b/drivers/staging/et131x/et1310_tx.c +@@ -710,11 +710,11 @@ inline void et131x_free_send_packet(struct et131x_= adapter *etdev, struct net_device_stats *stats =3D &etdev->net_stats; =20 if (pMpTcb->Flags & fMP_DEST_BROAD) @@ -39810,9 +41607,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/et131= x/et1310_tx.c linux-2.6.32.49/dr =20 if (pMpTcb->Packet) { stats->tx_bytes +=3D pMpTcb->Packet->len; -diff -urNp linux-2.6.32.49/drivers/staging/et131x/et131x_adapter.h linux= -2.6.32.49/drivers/staging/et131x/et131x_adapter.h ---- linux-2.6.32.49/drivers/staging/et131x/et131x_adapter.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/et131x/et131x_adapter.h 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/staging/et131x/et131x_adapter.h b/drivers/staging/e= t131x/et131x_adapter.h +index 1dfe06f..f469b4d 100644 +--- a/drivers/staging/et131x/et131x_adapter.h ++++ b/drivers/staging/et131x/et131x_adapter.h @@ -145,11 +145,11 @@ typedef struct _ce_stats_t { * operations */ @@ -39828,10 +41626,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/et13= 1x/et131x_adapter.h linux-2.6.32. u32 norcvbuf; /* # Rx packets discarded */ u32 noxmtbuf; /* # Tx packets discarded */ =20 -diff -urNp linux-2.6.32.49/drivers/staging/go7007/go7007-v4l2.c linux-2.= 6.32.49/drivers/staging/go7007/go7007-v4l2.c ---- linux-2.6.32.49/drivers/staging/go7007/go7007-v4l2.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/go7007/go7007-v4l2.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -1700,7 +1700,7 @@ static int go7007_vm_fault(struct vm_are +diff --git a/drivers/staging/go7007/go7007-v4l2.c b/drivers/staging/go70= 07/go7007-v4l2.c +index 4bd353a..e28f455 100644 +--- a/drivers/staging/go7007/go7007-v4l2.c ++++ b/drivers/staging/go7007/go7007-v4l2.c +@@ -1700,7 +1700,7 @@ static int go7007_vm_fault(struct vm_area_struct *= vma, struct vm_fault *vmf) return 0; } =20 @@ -39840,22 +41639,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/go70= 07/go7007-v4l2.c linux-2.6.32.49/ .open =3D go7007_vm_open, .close =3D go7007_vm_close, .fault =3D go7007_vm_fault, -diff -urNp linux-2.6.32.49/drivers/staging/hv/blkvsc_drv.c linux-2.6.32.= 49/drivers/staging/hv/blkvsc_drv.c ---- linux-2.6.32.49/drivers/staging/hv/blkvsc_drv.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/hv/blkvsc_drv.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -153,7 +153,7 @@ static int blkvsc_ringbuffer_size =3D BLKV - /* The one and only one */ - static struct blkvsc_driver_context g_blkvsc_drv; -=20 --static struct block_device_operations block_ops =3D { -+static const struct block_device_operations block_ops =3D { - .owner =3D THIS_MODULE, - .open =3D blkvsc_open, - .release =3D blkvsc_release, -diff -urNp linux-2.6.32.49/drivers/staging/hv/Channel.c linux-2.6.32.49/= drivers/staging/hv/Channel.c ---- linux-2.6.32.49/drivers/staging/hv/Channel.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/staging/hv/Channel.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -464,8 +464,8 @@ int VmbusChannelEstablishGpadl(struct vm +diff --git a/drivers/staging/hv/Channel.c b/drivers/staging/hv/Channel.c +index 366dc95..b974d87 100644 +--- a/drivers/staging/hv/Channel.c ++++ b/drivers/staging/hv/Channel.c +@@ -464,8 +464,8 @@ int VmbusChannelEstablishGpadl(struct vmbus_channel = *Channel, void *Kbuffer, =20 DPRINT_ENTER(VMBUS); =20 @@ -39866,10 +41654,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/hv/C= hannel.c linux-2.6.32.49/drivers/ =20 VmbusChannelCreateGpadlHeader(Kbuffer, Size, &msgInfo, &msgCount); ASSERT(msgInfo !=3D NULL); -diff -urNp linux-2.6.32.49/drivers/staging/hv/Hv.c linux-2.6.32.49/drive= rs/staging/hv/Hv.c ---- linux-2.6.32.49/drivers/staging/hv/Hv.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/staging/hv/Hv.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -161,7 +161,7 @@ static u64 HvDoHypercall(u64 Control, vo +diff --git a/drivers/staging/hv/Hv.c b/drivers/staging/hv/Hv.c +index b12237f..01ae28a 100644 +--- a/drivers/staging/hv/Hv.c ++++ b/drivers/staging/hv/Hv.c +@@ -161,7 +161,7 @@ static u64 HvDoHypercall(u64 Control, void *Input, v= oid *Output) u64 outputAddress =3D (Output) ? virt_to_phys(Output) : 0; u32 outputAddressHi =3D outputAddress >> 32; u32 outputAddressLo =3D outputAddress & 0xFFFFFFFF; @@ -39878,9 +41667,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/hv/Hv= .c linux-2.6.32.49/drivers/stagi =20 DPRINT_DBG(VMBUS, "Hypercall ", Control, Input, Output); -diff -urNp linux-2.6.32.49/drivers/staging/hv/VmbusApi.h linux-2.6.32.49= /drivers/staging/hv/VmbusApi.h ---- linux-2.6.32.49/drivers/staging/hv/VmbusApi.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/staging/hv/VmbusApi.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/drivers/staging/hv/VmbusApi.h b/drivers/staging/hv/VmbusApi= .h +index d089bb1..2ebc158 100644 +--- a/drivers/staging/hv/VmbusApi.h ++++ b/drivers/staging/hv/VmbusApi.h @@ -109,7 +109,7 @@ struct vmbus_channel_interface { u32 *GpadlHandle); int (*TeardownGpadl)(struct hv_device *device, u32 GpadlHandle); @@ -39890,10 +41680,37 @@ diff -urNp linux-2.6.32.49/drivers/staging/hv/V= mbusApi.h linux-2.6.32.49/drivers =20 /* Base driver object */ struct hv_driver { -diff -urNp linux-2.6.32.49/drivers/staging/hv/vmbus_drv.c linux-2.6.32.4= 9/drivers/staging/hv/vmbus_drv.c ---- linux-2.6.32.49/drivers/staging/hv/vmbus_drv.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/staging/hv/vmbus_drv.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -532,7 +532,7 @@ static int vmbus_child_device_register(s +diff --git a/drivers/staging/hv/VmbusPrivate.h b/drivers/staging/hv/Vmbu= sPrivate.h +index 5a37cce..6ecc88c 100644 +--- a/drivers/staging/hv/VmbusPrivate.h ++++ b/drivers/staging/hv/VmbusPrivate.h +@@ -59,7 +59,7 @@ enum VMBUS_CONNECT_STATE { + struct VMBUS_CONNECTION { + enum VMBUS_CONNECT_STATE ConnectState; +=20 +- atomic_t NextGpadlHandle; ++ atomic_unchecked_t NextGpadlHandle; +=20 + /* + * Represents channel interrupts. Each bit position represents a +diff --git a/drivers/staging/hv/blkvsc_drv.c b/drivers/staging/hv/blkvsc= _drv.c +index 871a202..ca50ddf 100644 +--- a/drivers/staging/hv/blkvsc_drv.c ++++ b/drivers/staging/hv/blkvsc_drv.c +@@ -153,7 +153,7 @@ static int blkvsc_ringbuffer_size =3D BLKVSC_RING_BU= FFER_SIZE; + /* The one and only one */ + static struct blkvsc_driver_context g_blkvsc_drv; +=20 +-static struct block_device_operations block_ops =3D { ++static const struct block_device_operations block_ops =3D { + .owner =3D THIS_MODULE, + .open =3D blkvsc_open, + .release =3D blkvsc_release, +diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_d= rv.c +index 6acc49a..fbc8d46 100644 +--- a/drivers/staging/hv/vmbus_drv.c ++++ b/drivers/staging/hv/vmbus_drv.c +@@ -532,7 +532,7 @@ static int vmbus_child_device_register(struct hv_dev= ice *root_device_obj, to_device_context(root_device_obj); struct device_context *child_device_ctx =3D to_device_context(child_device_obj); @@ -39902,7 +41719,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/hv/vmb= us_drv.c linux-2.6.32.49/driver =20 DPRINT_ENTER(VMBUS_DRV); =20 -@@ -541,7 +541,7 @@ static int vmbus_child_device_register(s +@@ -541,7 +541,7 @@ static int vmbus_child_device_register(struct hv_dev= ice *root_device_obj, =20 /* Set the device name. Otherwise, device_register() will fail. */ dev_set_name(&child_device_ctx->device, "vmbus_0_%d", @@ -39911,21 +41728,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/hv/v= mbus_drv.c linux-2.6.32.49/driver =20 /* The new device belongs to this bus */ child_device_ctx->device.bus =3D &g_vmbus_drv.bus; /* device->dev.bus;= */ -diff -urNp linux-2.6.32.49/drivers/staging/hv/VmbusPrivate.h linux-2.6.3= 2.49/drivers/staging/hv/VmbusPrivate.h ---- linux-2.6.32.49/drivers/staging/hv/VmbusPrivate.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/hv/VmbusPrivate.h 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -59,7 +59,7 @@ enum VMBUS_CONNECT_STATE { - struct VMBUS_CONNECTION { - enum VMBUS_CONNECT_STATE ConnectState; -=20 -- atomic_t NextGpadlHandle; -+ atomic_unchecked_t NextGpadlHandle; -=20 - /* - * Represents channel interrupts. Each bit position represents a -diff -urNp linux-2.6.32.49/drivers/staging/iio/ring_generic.h linux-2.6.= 32.49/drivers/staging/iio/ring_generic.h ---- linux-2.6.32.49/drivers/staging/iio/ring_generic.h 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/iio/ring_generic.h 2011-11-15 19:59:= 43.000000000 -0500 +diff --git a/drivers/staging/iio/ring_generic.h b/drivers/staging/iio/ri= ng_generic.h +index d926189..17b19fd 100644 +--- a/drivers/staging/iio/ring_generic.h ++++ b/drivers/staging/iio/ring_generic.h @@ -87,7 +87,7 @@ struct iio_ring_access_funcs { =20 int (*is_enabled)(struct iio_ring_buffer *ring); @@ -39935,29 +41741,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/iio/= ring_generic.h linux-2.6.32.49/dr =20 /** * struct iio_ring_buffer - general ring buffer structure -diff -urNp linux-2.6.32.49/drivers/staging/octeon/ethernet.c linux-2.6.3= 2.49/drivers/staging/octeon/ethernet.c ---- linux-2.6.32.49/drivers/staging/octeon/ethernet.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/octeon/ethernet.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -294,11 +294,11 @@ static struct net_device_stats *cvm_oct_ - * since the RX tasklet also increments it. - */ - #ifdef CONFIG_64BIT -- atomic64_add(rx_status.dropped_packets, -- (atomic64_t *)&priv->stats.rx_dropped); -+ atomic64_add_unchecked(rx_status.dropped_packets, -+ (atomic64_unchecked_t *)&priv->stats.rx_dropped); - #else -- atomic_add(rx_status.dropped_packets, -- (atomic_t *)&priv->stats.rx_dropped); -+ atomic_add_unchecked(rx_status.dropped_packets, -+ (atomic_unchecked_t *)&priv->stats.rx_dropped); - #endif - } -=20 -diff -urNp linux-2.6.32.49/drivers/staging/octeon/ethernet-rx.c linux-2.= 6.32.49/drivers/staging/octeon/ethernet-rx.c ---- linux-2.6.32.49/drivers/staging/octeon/ethernet-rx.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/octeon/ethernet-rx.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -406,11 +406,11 @@ void cvm_oct_tasklet_rx(unsigned long un +diff --git a/drivers/staging/octeon/ethernet-rx.c b/drivers/staging/octe= on/ethernet-rx.c +index 1b237b7..88c624e 100644 +--- a/drivers/staging/octeon/ethernet-rx.c ++++ b/drivers/staging/octeon/ethernet-rx.c +@@ -406,11 +406,11 @@ void cvm_oct_tasklet_rx(unsigned long unused) /* Increment RX stats for virtual ports */ if (work->ipprt >=3D CVMX_PIP_NUM_INPUT_PORTS) { #ifdef CONFIG_64BIT @@ -39973,7 +41761,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/octeon= /ethernet-rx.c linux-2.6.32.49/ #endif } netif_receive_skb(skb); -@@ -424,9 +424,9 @@ void cvm_oct_tasklet_rx(unsigned long un +@@ -424,9 +424,9 @@ void cvm_oct_tasklet_rx(unsigned long unused) dev->name); */ #ifdef CONFIG_64BIT @@ -39985,9 +41773,30 @@ diff -urNp linux-2.6.32.49/drivers/staging/octeo= n/ethernet-rx.c linux-2.6.32.49/ #endif dev_kfree_skb_irq(skb); } -diff -urNp linux-2.6.32.49/drivers/staging/otus/80211core/pub_zfi.h linu= x-2.6.32.49/drivers/staging/otus/80211core/pub_zfi.h ---- linux-2.6.32.49/drivers/staging/otus/80211core/pub_zfi.h 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/otus/80211core/pub_zfi.h 2011-11-18 = 18:01:55.000000000 -0500 +diff --git a/drivers/staging/octeon/ethernet.c b/drivers/staging/octeon/= ethernet.c +index 492c502..d9909f1 100644 +--- a/drivers/staging/octeon/ethernet.c ++++ b/drivers/staging/octeon/ethernet.c +@@ -294,11 +294,11 @@ static struct net_device_stats *cvm_oct_common_get= _stats(struct net_device *dev) + * since the RX tasklet also increments it. + */ + #ifdef CONFIG_64BIT +- atomic64_add(rx_status.dropped_packets, +- (atomic64_t *)&priv->stats.rx_dropped); ++ atomic64_add_unchecked(rx_status.dropped_packets, ++ (atomic64_unchecked_t *)&priv->stats.rx_dropped); + #else +- atomic_add(rx_status.dropped_packets, +- (atomic_t *)&priv->stats.rx_dropped); ++ atomic_add_unchecked(rx_status.dropped_packets, ++ (atomic_unchecked_t *)&priv->stats.rx_dropped); + #endif + } +=20 +diff --git a/drivers/staging/otus/80211core/pub_zfi.h b/drivers/staging/= otus/80211core/pub_zfi.h +index a35bd5d..28fff45 100644 +--- a/drivers/staging/otus/80211core/pub_zfi.h ++++ b/drivers/staging/otus/80211core/pub_zfi.h @@ -531,7 +531,7 @@ struct zsCbFuncTbl u8_t (*zfcbClassifyTxPacket)(zdev_t* dev, zbuf_t* buf); =20 @@ -39997,10 +41806,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/otus= /80211core/pub_zfi.h linux-2.6.32 =20 extern void zfZeroMemory(u8_t* va, u16_t length); #define ZM_INIT_CB_FUNC_TABLE(p) zfZeroMemory((u8_t *)p, sizeof(= struct zsCbFuncTbl)); -diff -urNp linux-2.6.32.49/drivers/staging/panel/panel.c linux-2.6.32.49= /drivers/staging/panel/panel.c ---- linux-2.6.32.49/drivers/staging/panel/panel.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/staging/panel/panel.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -1305,7 +1305,7 @@ static int lcd_release(struct inode *ino +diff --git a/drivers/staging/panel/panel.c b/drivers/staging/panel/panel= .c +index c39a25f..696f5aa 100644 +--- a/drivers/staging/panel/panel.c ++++ b/drivers/staging/panel/panel.c +@@ -1305,7 +1305,7 @@ static int lcd_release(struct inode *inode, struct= file *file) return 0; } =20 @@ -40009,7 +41819,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/panel/= panel.c linux-2.6.32.49/drivers .write =3D lcd_write, .open =3D lcd_open, .release =3D lcd_release, -@@ -1565,7 +1565,7 @@ static int keypad_release(struct inode * +@@ -1565,7 +1565,7 @@ static int keypad_release(struct inode *inode, str= uct file *file) return 0; } =20 @@ -40018,10 +41828,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/pane= l/panel.c linux-2.6.32.49/drivers .read =3D keypad_read, /* read */ .open =3D keypad_open, /* open */ .release =3D keypad_release, /* close */ -diff -urNp linux-2.6.32.49/drivers/staging/phison/phison.c linux-2.6.32.= 49/drivers/staging/phison/phison.c ---- linux-2.6.32.49/drivers/staging/phison/phison.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/phison/phison.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -43,7 +43,7 @@ static struct scsi_host_template phison_ +diff --git a/drivers/staging/phison/phison.c b/drivers/staging/phison/ph= ison.c +index 270ebcb..37e46af 100644 +--- a/drivers/staging/phison/phison.c ++++ b/drivers/staging/phison/phison.c +@@ -43,7 +43,7 @@ static struct scsi_host_template phison_sht =3D { ATA_BMDMA_SHT(DRV_NAME), }; =20 @@ -40030,10 +41841,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/phis= on/phison.c linux-2.6.32.49/drive .inherits =3D &ata_bmdma_port_ops, .prereset =3D phison_pre_reset, }; -diff -urNp linux-2.6.32.49/drivers/staging/poch/poch.c linux-2.6.32.49/d= rivers/staging/poch/poch.c ---- linux-2.6.32.49/drivers/staging/poch/poch.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/staging/poch/poch.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -1057,7 +1057,7 @@ static int poch_ioctl(struct inode *inod +diff --git a/drivers/staging/poch/poch.c b/drivers/staging/poch/poch.c +index 2eb8e3d..57616a7 100644 +--- a/drivers/staging/poch/poch.c ++++ b/drivers/staging/poch/poch.c +@@ -1057,7 +1057,7 @@ static int poch_ioctl(struct inode *inode, struct = file *filp, return 0; } =20 @@ -40042,10 +41854,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/poch= /poch.c linux-2.6.32.49/drivers/s .owner =3D THIS_MODULE, .open =3D poch_open, .release =3D poch_release, -diff -urNp linux-2.6.32.49/drivers/staging/pohmelfs/inode.c linux-2.6.32= .49/drivers/staging/pohmelfs/inode.c ---- linux-2.6.32.49/drivers/staging/pohmelfs/inode.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/pohmelfs/inode.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -1850,7 +1850,7 @@ static int pohmelfs_fill_super(struct su +diff --git a/drivers/staging/pohmelfs/inode.c b/drivers/staging/pohmelfs= /inode.c +index c94de31..19402bc 100644 +--- a/drivers/staging/pohmelfs/inode.c ++++ b/drivers/staging/pohmelfs/inode.c +@@ -1850,7 +1850,7 @@ static int pohmelfs_fill_super(struct super_block = *sb, void *data, int silent) mutex_init(&psb->mcache_lock); psb->mcache_root =3D RB_ROOT; psb->mcache_timeout =3D msecs_to_jiffies(5000); @@ -40054,7 +41867,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/pohmel= fs/inode.c linux-2.6.32.49/driv =20 psb->trans_max_pages =3D 100; =20 -@@ -1865,7 +1865,7 @@ static int pohmelfs_fill_super(struct su +@@ -1865,7 +1865,7 @@ static int pohmelfs_fill_super(struct super_block = *sb, void *data, int silent) INIT_LIST_HEAD(&psb->crypto_ready_list); INIT_LIST_HEAD(&psb->crypto_active_list); =20 @@ -40063,10 +41876,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/pohm= elfs/inode.c linux-2.6.32.49/driv atomic_long_set(&psb->total_inodes, 0); =20 mutex_init(&psb->state_lock); -diff -urNp linux-2.6.32.49/drivers/staging/pohmelfs/mcache.c linux-2.6.3= 2.49/drivers/staging/pohmelfs/mcache.c ---- linux-2.6.32.49/drivers/staging/pohmelfs/mcache.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/pohmelfs/mcache.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -121,7 +121,7 @@ struct pohmelfs_mcache *pohmelfs_mcache_ +diff --git a/drivers/staging/pohmelfs/mcache.c b/drivers/staging/pohmelf= s/mcache.c +index e22665c..a2a9390 100644 +--- a/drivers/staging/pohmelfs/mcache.c ++++ b/drivers/staging/pohmelfs/mcache.c +@@ -121,7 +121,7 @@ struct pohmelfs_mcache *pohmelfs_mcache_alloc(struct= pohmelfs_sb *psb, u64 start m->data =3D data; m->start =3D start; m->size =3D size; @@ -40075,9 +41889,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/pohme= lfs/mcache.c linux-2.6.32.49/dri =20 mutex_lock(&psb->mcache_lock); err =3D pohmelfs_mcache_insert(psb, m); -diff -urNp linux-2.6.32.49/drivers/staging/pohmelfs/netfs.h linux-2.6.32= .49/drivers/staging/pohmelfs/netfs.h ---- linux-2.6.32.49/drivers/staging/pohmelfs/netfs.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/pohmelfs/netfs.h 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/staging/pohmelfs/netfs.h b/drivers/staging/pohmelfs= /netfs.h +index 623a07d..4035c19 100644 +--- a/drivers/staging/pohmelfs/netfs.h ++++ b/drivers/staging/pohmelfs/netfs.h @@ -570,14 +570,14 @@ struct pohmelfs_config; struct pohmelfs_sb { struct rb_root mcache_root; @@ -40095,10 +41910,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/pohm= elfs/netfs.h linux-2.6.32.49/driv =20 unsigned int crypto_attached_size; unsigned int crypto_align_size; -diff -urNp linux-2.6.32.49/drivers/staging/pohmelfs/trans.c linux-2.6.32= .49/drivers/staging/pohmelfs/trans.c ---- linux-2.6.32.49/drivers/staging/pohmelfs/trans.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/pohmelfs/trans.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -492,7 +492,7 @@ int netfs_trans_finish(struct netfs_tran +diff --git a/drivers/staging/pohmelfs/trans.c b/drivers/staging/pohmelfs= /trans.c +index 36a2535..0591bf4 100644 +--- a/drivers/staging/pohmelfs/trans.c ++++ b/drivers/staging/pohmelfs/trans.c +@@ -492,7 +492,7 @@ int netfs_trans_finish(struct netfs_trans *t, struct= pohmelfs_sb *psb) int err; struct netfs_cmd *cmd =3D t->iovec.iov_base; =20 @@ -40107,10 +41923,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/pohm= elfs/trans.c linux-2.6.32.49/driv =20 cmd->size =3D t->iovec.iov_len - sizeof(struct netfs_cmd) + t->attached_size + t->attached_pages * sizeof(struct netfs_cmd); -diff -urNp linux-2.6.32.49/drivers/staging/sep/sep_driver.c linux-2.6.32= .49/drivers/staging/sep/sep_driver.c ---- linux-2.6.32.49/drivers/staging/sep/sep_driver.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/sep/sep_driver.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -2603,7 +2603,7 @@ static struct pci_driver sep_pci_driver=20 +diff --git a/drivers/staging/sep/sep_driver.c b/drivers/staging/sep/sep_= driver.c +index f890a16..509ece8 100644 +--- a/drivers/staging/sep/sep_driver.c ++++ b/drivers/staging/sep/sep_driver.c +@@ -2603,7 +2603,7 @@ static struct pci_driver sep_pci_driver =3D { static dev_t sep_devno; =20 /* the files operations structure of the driver */ @@ -40119,9 +41936,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/sep/s= ep_driver.c linux-2.6.32.49/driv .owner =3D THIS_MODULE, .ioctl =3D sep_ioctl, .poll =3D sep_poll, -diff -urNp linux-2.6.32.49/drivers/staging/usbip/usbip_common.h linux-2.= 6.32.49/drivers/staging/usbip/usbip_common.h ---- linux-2.6.32.49/drivers/staging/usbip/usbip_common.h 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/usbip/usbip_common.h 2011-11-15 19:5= 9:43.000000000 -0500 +diff --git a/drivers/staging/usbip/usbip_common.h b/drivers/staging/usbi= p/usbip_common.h +index 5e16bc3..7655b10 100644 +--- a/drivers/staging/usbip/usbip_common.h ++++ b/drivers/staging/usbip/usbip_common.h @@ -374,7 +374,7 @@ struct usbip_device { void (*shutdown)(struct usbip_device *); void (*reset)(struct usbip_device *); @@ -40131,9 +41949,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/usbip= /usbip_common.h linux-2.6.32.49/ }; =20 =20 -diff -urNp linux-2.6.32.49/drivers/staging/usbip/vhci.h linux-2.6.32.49/= drivers/staging/usbip/vhci.h ---- linux-2.6.32.49/drivers/staging/usbip/vhci.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/staging/usbip/vhci.h 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/drivers/staging/usbip/vhci.h b/drivers/staging/usbip/vhci.h +index 57f7946..d9df23d 100644 +--- a/drivers/staging/usbip/vhci.h ++++ b/drivers/staging/usbip/vhci.h @@ -92,7 +92,7 @@ struct vhci_hcd { unsigned resuming:1; unsigned long re_timeout; @@ -40143,9 +41962,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/usbip= /vhci.h linux-2.6.32.49/drivers/ =20 /* * NOTE: -diff -urNp linux-2.6.32.49/drivers/staging/usbip/vhci_hcd.c linux-2.6.32= .49/drivers/staging/usbip/vhci_hcd.c ---- linux-2.6.32.49/drivers/staging/usbip/vhci_hcd.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/usbip/vhci_hcd.c 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/drivers/staging/usbip/vhci_hcd.c b/drivers/staging/usbip/vh= ci_hcd.c +index 20cd7db..c2693ff 100644 +--- a/drivers/staging/usbip/vhci_hcd.c ++++ b/drivers/staging/usbip/vhci_hcd.c @@ -534,7 +534,7 @@ static void vhci_tx_urb(struct urb *urb) return; } @@ -40155,7 +41975,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/usbip/= vhci_hcd.c linux-2.6.32.49/driv if (priv->seqnum =3D=3D 0xffff) usbip_uinfo("seqnum max\n"); =20 -@@ -793,7 +793,7 @@ static int vhci_urb_dequeue(struct usb_h +@@ -793,7 +793,7 @@ static int vhci_urb_dequeue(struct usb_hcd *hcd, str= uct urb *urb, int status) return -ENOMEM; } =20 @@ -40164,7 +41984,7 @@ diff -urNp linux-2.6.32.49/drivers/staging/usbip/= vhci_hcd.c linux-2.6.32.49/driv if (unlink->seqnum =3D=3D 0xffff) usbip_uinfo("seqnum max\n"); =20 -@@ -988,7 +988,7 @@ static int vhci_start(struct usb_hcd *hc +@@ -988,7 +988,7 @@ static int vhci_start(struct usb_hcd *hcd) vdev->rhport =3D rhport; } =20 @@ -40173,10 +41993,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/usbi= p/vhci_hcd.c linux-2.6.32.49/driv spin_lock_init(&vhci->lock); =20 =20 -diff -urNp linux-2.6.32.49/drivers/staging/usbip/vhci_rx.c linux-2.6.32.= 49/drivers/staging/usbip/vhci_rx.c ---- linux-2.6.32.49/drivers/staging/usbip/vhci_rx.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/usbip/vhci_rx.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -78,7 +78,7 @@ static void vhci_recv_ret_submit(struct=20 +diff --git a/drivers/staging/usbip/vhci_rx.c b/drivers/staging/usbip/vhc= i_rx.c +index 8ed5206..92469e3 100644 +--- a/drivers/staging/usbip/vhci_rx.c ++++ b/drivers/staging/usbip/vhci_rx.c +@@ -78,7 +78,7 @@ static void vhci_recv_ret_submit(struct vhci_device *v= dev, usbip_uerr("cannot find a urb of seqnum %u\n", pdu->base.seqnum); usbip_uinfo("max seqnum %d\n", @@ -40185,10 +42006,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/usbi= p/vhci_rx.c linux-2.6.32.49/drive usbip_event_add(ud, VDEV_EVENT_ERROR_TCP); return; } -diff -urNp linux-2.6.32.49/drivers/staging/vme/devices/vme_user.c linux-= 2.6.32.49/drivers/staging/vme/devices/vme_user.c ---- linux-2.6.32.49/drivers/staging/vme/devices/vme_user.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/vme/devices/vme_user.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -136,7 +136,7 @@ static int vme_user_ioctl(struct inode * +diff --git a/drivers/staging/vme/devices/vme_user.c b/drivers/staging/vm= e/devices/vme_user.c +index 7891288..8e31300 100644 +--- a/drivers/staging/vme/devices/vme_user.c ++++ b/drivers/staging/vme/devices/vme_user.c +@@ -136,7 +136,7 @@ static int vme_user_ioctl(struct inode *, struct fil= e *, unsigned int, static int __init vme_user_probe(struct device *, int, int); static int __exit vme_user_remove(struct device *, int, int); =20 @@ -40197,10 +42019,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/vme/= devices/vme_user.c linux-2.6.32.4 .open =3D vme_user_open, .release =3D vme_user_release, .read =3D vme_user_read, -diff -urNp linux-2.6.32.49/drivers/staging/vt6655/hostap.c linux-2.6.32.= 49/drivers/staging/vt6655/hostap.c ---- linux-2.6.32.49/drivers/staging/vt6655/hostap.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/vt6655/hostap.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -84,7 +84,7 @@ static int hostap_enable_hostapd(PSDevic +diff --git a/drivers/staging/vt6655/hostap.c b/drivers/staging/vt6655/ho= stap.c +index 58abf44..00c1fc8 100644 +--- a/drivers/staging/vt6655/hostap.c ++++ b/drivers/staging/vt6655/hostap.c +@@ -84,7 +84,7 @@ static int hostap_enable_hostapd(PSDevice pDevice, int= rtnl_locked) PSDevice apdev_priv; struct net_device *dev =3D pDevice->dev; int ret; @@ -40209,10 +42032,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/vt66= 55/hostap.c linux-2.6.32.49/drive .ndo_start_xmit =3D pDevice->tx_80211, }; =20 -diff -urNp linux-2.6.32.49/drivers/staging/vt6656/hostap.c linux-2.6.32.= 49/drivers/staging/vt6656/hostap.c ---- linux-2.6.32.49/drivers/staging/vt6656/hostap.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/vt6656/hostap.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -86,7 +86,7 @@ static int hostap_enable_hostapd(PSDevic +diff --git a/drivers/staging/vt6656/hostap.c b/drivers/staging/vt6656/ho= stap.c +index 0c8267a..db1f363 100644 +--- a/drivers/staging/vt6656/hostap.c ++++ b/drivers/staging/vt6656/hostap.c +@@ -86,7 +86,7 @@ static int hostap_enable_hostapd(PSDevice pDevice, int= rtnl_locked) PSDevice apdev_priv; struct net_device *dev =3D pDevice->dev; int ret; @@ -40221,10 +42045,11 @@ diff -urNp linux-2.6.32.49/drivers/staging/vt66= 56/hostap.c linux-2.6.32.49/drive .ndo_start_xmit =3D pDevice->tx_80211, }; =20 -diff -urNp linux-2.6.32.49/drivers/staging/wlan-ng/hfa384x_usb.c linux-2= .6.32.49/drivers/staging/wlan-ng/hfa384x_usb.c ---- linux-2.6.32.49/drivers/staging/wlan-ng/hfa384x_usb.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/staging/wlan-ng/hfa384x_usb.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -205,7 +205,7 @@ static void unlocked_usbctlx_complete(hf +diff --git a/drivers/staging/wlan-ng/hfa384x_usb.c b/drivers/staging/wla= n-ng/hfa384x_usb.c +index 925678b..da7f5ed 100644 +--- a/drivers/staging/wlan-ng/hfa384x_usb.c ++++ b/drivers/staging/wlan-ng/hfa384x_usb.c +@@ -205,7 +205,7 @@ static void unlocked_usbctlx_complete(hfa384x_t *hw,= hfa384x_usbctlx_t *ctlx); =20 struct usbctlx_completor { int (*complete) (struct usbctlx_completor *); @@ -40233,9 +42058,10 @@ diff -urNp linux-2.6.32.49/drivers/staging/wlan-= ng/hfa384x_usb.c linux-2.6.32.49 typedef struct usbctlx_completor usbctlx_completor_t; =20 static int -diff -urNp linux-2.6.32.49/drivers/telephony/ixj.c linux-2.6.32.49/drive= rs/telephony/ixj.c ---- linux-2.6.32.49/drivers/telephony/ixj.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/telephony/ixj.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/telephony/ixj.c b/drivers/telephony/ixj.c +index 40de151..924f268 100644 +--- a/drivers/telephony/ixj.c ++++ b/drivers/telephony/ixj.c @@ -4976,6 +4976,8 @@ static int ixj_daa_cid_read(IXJ *j) bool mContinue; char *pIn, *pOut; @@ -40245,9 +42071,10 @@ diff -urNp linux-2.6.32.49/drivers/telephony/ixj= .c linux-2.6.32.49/drivers/telep if (!SCI_Prepare(j)) return 0; =20 -diff -urNp linux-2.6.32.49/drivers/uio/uio.c linux-2.6.32.49/drivers/uio= /uio.c ---- linux-2.6.32.49/drivers/uio/uio.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/drivers/uio/uio.c 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/drivers/uio/uio.c b/drivers/uio/uio.c +index e941367..b631f5a 100644 +--- a/drivers/uio/uio.c ++++ b/drivers/uio/uio.c @@ -23,6 +23,7 @@ #include #include @@ -40269,7 +42096,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c struct uio_info *info; struct kobject *map_dir; struct kobject *portio_dir; -@@ -129,7 +130,7 @@ static ssize_t map_type_show(struct kobj +@@ -129,7 +130,7 @@ static ssize_t map_type_show(struct kobject *kobj, s= truct attribute *attr, return entry->show(mem, buf); } =20 @@ -40278,7 +42105,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c .show =3D map_type_show, }; =20 -@@ -217,7 +218,7 @@ static ssize_t portio_type_show(struct k +@@ -217,7 +218,7 @@ static ssize_t portio_type_show(struct kobject *kobj= , struct attribute *attr, return entry->show(port, buf); } =20 @@ -40287,7 +42114,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c .show =3D portio_type_show, }; =20 -@@ -255,7 +256,7 @@ static ssize_t show_event(struct device=20 +@@ -255,7 +256,7 @@ static ssize_t show_event(struct device *dev, struct uio_device *idev =3D dev_get_drvdata(dev); if (idev) return sprintf(buf, "%u\n", @@ -40296,7 +42123,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c else return -ENODEV; } -@@ -424,7 +425,7 @@ void uio_event_notify(struct uio_info *i +@@ -424,7 +425,7 @@ void uio_event_notify(struct uio_info *info) { struct uio_device *idev =3D info->uio_dev; =20 @@ -40305,7 +42132,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c wake_up_interruptible(&idev->wait); kill_fasync(&idev->async_queue, SIGIO, POLL_IN); } -@@ -477,7 +478,7 @@ static int uio_open(struct inode *inode, +@@ -477,7 +478,7 @@ static int uio_open(struct inode *inode, struct file= *filep) } =20 listener->dev =3D idev; @@ -40314,7 +42141,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c filep->private_data =3D listener; =20 if (idev->info->open) { -@@ -528,7 +529,7 @@ static unsigned int uio_poll(struct file +@@ -528,7 +529,7 @@ static unsigned int uio_poll(struct file *filep, pol= l_table *wait) return -EIO; =20 poll_wait(filep, &idev->wait, wait); @@ -40323,7 +42150,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c return POLLIN | POLLRDNORM; return 0; } -@@ -553,7 +554,7 @@ static ssize_t uio_read(struct file *fil +@@ -553,7 +554,7 @@ static ssize_t uio_read(struct file *filep, char __u= ser *buf, do { set_current_state(TASK_INTERRUPTIBLE); =20 @@ -40332,7 +42159,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c if (event_count !=3D listener->event_count) { if (copy_to_user(buf, &event_count, count)) retval =3D -EFAULT; -@@ -624,13 +625,13 @@ static int uio_find_mem_index(struct vm_ +@@ -624,13 +625,13 @@ static int uio_find_mem_index(struct vm_area_struc= t *vma) static void uio_vma_open(struct vm_area_struct *vma) { struct uio_device *idev =3D vma->vm_private_data; @@ -40348,7 +42175,7 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c linu= x-2.6.32.49/drivers/uio/uio.c } =20 static int uio_vma_fault(struct vm_area_struct *vma, struct vm_fault *v= mf) -@@ -840,7 +841,7 @@ int __uio_register_device(struct module=20 +@@ -840,7 +841,7 @@ int __uio_register_device(struct module *owner, idev->owner =3D owner; idev->info =3D info; init_waitqueue_head(&idev->wait); @@ -40357,10 +42184,11 @@ diff -urNp linux-2.6.32.49/drivers/uio/uio.c li= nux-2.6.32.49/drivers/uio/uio.c =20 ret =3D uio_get_minor(idev); if (ret) -diff -urNp linux-2.6.32.49/drivers/usb/atm/usbatm.c linux-2.6.32.49/driv= ers/usb/atm/usbatm.c ---- linux-2.6.32.49/drivers/usb/atm/usbatm.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/drivers/usb/atm/usbatm.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -333,7 +333,7 @@ static void usbatm_extract_one_cell(stru +diff --git a/drivers/usb/atm/usbatm.c b/drivers/usb/atm/usbatm.c +index fbea856..06efea6 100644 +--- a/drivers/usb/atm/usbatm.c ++++ b/drivers/usb/atm/usbatm.c +@@ -333,7 +333,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char if (printk_ratelimit()) atm_warn(instance, "%s: OAM not supported (vpi %d, vci %d)!\n", __func__, vpi, vci); @@ -40369,7 +42197,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/atm/usbatm= .c linux-2.6.32.49/drivers/usb/ return; } =20 -@@ -361,7 +361,7 @@ static void usbatm_extract_one_cell(stru +@@ -361,7 +361,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char if (length > ATM_MAX_AAL5_PDU) { atm_rldbg(instance, "%s: bogus length %u (vcc: 0x%p)!\n", __func__, length, vcc); @@ -40378,7 +42206,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/atm/usbatm= .c linux-2.6.32.49/drivers/usb/ goto out; } =20 -@@ -370,14 +370,14 @@ static void usbatm_extract_one_cell(stru +@@ -370,14 +370,14 @@ static void usbatm_extract_one_cell(struct usbatm_= data *instance, unsigned char if (sarb->len < pdu_length) { atm_rldbg(instance, "%s: bogus pdu_length %u (sarb->len: %u, vcc: 0x= %p)!\n", __func__, pdu_length, sarb->len, vcc); @@ -40395,7 +42223,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/atm/usbatm= .c linux-2.6.32.49/drivers/usb/ goto out; } =20 -@@ -387,7 +387,7 @@ static void usbatm_extract_one_cell(stru +@@ -387,7 +387,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char if (printk_ratelimit()) atm_err(instance, "%s: no memory for skb (length: %u)!\n", __func__, length); @@ -40404,7 +42232,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/atm/usbatm= .c linux-2.6.32.49/drivers/usb/ goto out; } =20 -@@ -412,7 +412,7 @@ static void usbatm_extract_one_cell(stru +@@ -412,7 +412,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char =20 vcc->push(vcc, skb); =20 @@ -40413,7 +42241,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/atm/usbatm= .c linux-2.6.32.49/drivers/usb/ out: skb_trim(sarb, 0); } -@@ -616,7 +616,7 @@ static void usbatm_tx_process(unsigned l +@@ -616,7 +616,7 @@ static void usbatm_tx_process(unsigned long data) struct atm_vcc *vcc =3D UDSL_SKB(skb)->atm.vcc; =20 usbatm_pop(vcc, skb); @@ -40422,7 +42250,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/atm/usbatm= .c linux-2.6.32.49/drivers/usb/ =20 skb =3D skb_dequeue(&instance->sndqueue); } -@@ -775,11 +775,11 @@ static int usbatm_atm_proc_read(struct a +@@ -775,11 +775,11 @@ static int usbatm_atm_proc_read(struct atm_dev *at= m_dev, loff_t * pos, char *pag if (!left--) return sprintf(page, "AAL5: tx %d ( %d err ), rx %d ( %d err, %d drop )\n", @@ -40439,9 +42267,10 @@ diff -urNp linux-2.6.32.49/drivers/usb/atm/usbat= m.c linux-2.6.32.49/drivers/usb/ =20 if (!left--) { if (instance->disconnected) -diff -urNp linux-2.6.32.49/drivers/usb/class/cdc-wdm.c linux-2.6.32.49/d= rivers/usb/class/cdc-wdm.c ---- linux-2.6.32.49/drivers/usb/class/cdc-wdm.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/usb/class/cdc-wdm.c 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/drivers/usb/class/cdc-wdm.c b/drivers/usb/class/cdc-wdm.c +index 3e564bf..949b448 100644 +--- a/drivers/usb/class/cdc-wdm.c ++++ b/drivers/usb/class/cdc-wdm.c @@ -314,7 +314,7 @@ static ssize_t wdm_write if (r < 0) goto outnp; @@ -40451,10 +42280,11 @@ diff -urNp linux-2.6.32.49/drivers/usb/class/cd= c-wdm.c linux-2.6.32.49/drivers/u r =3D wait_event_interruptible(desc->wait, !test_bit(WDM_IN_USE, &desc->flags)); else -diff -urNp linux-2.6.32.49/drivers/usb/core/hcd.c linux-2.6.32.49/driver= s/usb/core/hcd.c ---- linux-2.6.32.49/drivers/usb/core/hcd.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/usb/core/hcd.c 2011-11-15 19:59:43.000000000= -0500 -@@ -2216,7 +2216,7 @@ EXPORT_SYMBOL_GPL(usb_hcd_platform_shutd +diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c +index 24e6205..fe5a5d4 100644 +--- a/drivers/usb/core/hcd.c ++++ b/drivers/usb/core/hcd.c +@@ -2216,7 +2216,7 @@ EXPORT_SYMBOL_GPL(usb_hcd_platform_shutdown); =20 #if defined(CONFIG_USB_MON) || defined(CONFIG_USB_MON_MODULE) =20 @@ -40472,10 +42302,11 @@ diff -urNp linux-2.6.32.49/drivers/usb/core/hcd= .c linux-2.6.32.49/drivers/usb/co { =20 if (mon_ops) -diff -urNp linux-2.6.32.49/drivers/usb/core/hcd.h linux-2.6.32.49/driver= s/usb/core/hcd.h ---- linux-2.6.32.49/drivers/usb/core/hcd.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/usb/core/hcd.h 2011-11-15 19:59:43.000000000= -0500 -@@ -486,13 +486,13 @@ static inline void usbfs_cleanup(void) { +diff --git a/drivers/usb/core/hcd.h b/drivers/usb/core/hcd.h +index bcbe104..9cfd1c6 100644 +--- a/drivers/usb/core/hcd.h ++++ b/drivers/usb/core/hcd.h +@@ -486,13 +486,13 @@ static inline void usbfs_cleanup(void) { } #if defined(CONFIG_USB_MON) || defined(CONFIG_USB_MON_MODULE) =20 struct usb_mon_operations { @@ -40493,7 +42324,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/core/hcd.h= linux-2.6.32.49/drivers/usb/co =20 static inline void usbmon_urb_submit(struct usb_bus *bus, struct urb *u= rb) { -@@ -514,7 +514,7 @@ static inline void usbmon_urb_complete(s +@@ -514,7 +514,7 @@ static inline void usbmon_urb_complete(struct usb_bu= s *bus, struct urb *urb, (*mon_ops->urb_complete)(bus, urb, status); } =20 @@ -40502,10 +42333,11 @@ diff -urNp linux-2.6.32.49/drivers/usb/core/hcd= .h linux-2.6.32.49/drivers/usb/co void usb_mon_deregister(void); =20 #else -diff -urNp linux-2.6.32.49/drivers/usb/core/message.c linux-2.6.32.49/dr= ivers/usb/core/message.c ---- linux-2.6.32.49/drivers/usb/core/message.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/usb/core/message.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -914,8 +914,8 @@ char *usb_cache_string(struct usb_device +diff --git a/drivers/usb/core/message.c b/drivers/usb/core/message.c +index 409cc94..a673bad 100644 +--- a/drivers/usb/core/message.c ++++ b/drivers/usb/core/message.c +@@ -914,8 +914,8 @@ char *usb_cache_string(struct usb_device *udev, int = index) buf =3D kmalloc(MAX_USB_STRING_SIZE, GFP_NOIO); if (buf) { len =3D usb_string(udev, index, buf, MAX_USB_STRING_SIZE); @@ -40516,10 +42348,11 @@ diff -urNp linux-2.6.32.49/drivers/usb/core/mes= sage.c linux-2.6.32.49/drivers/us if (!smallbuf) return buf; memcpy(smallbuf, buf, len); -diff -urNp linux-2.6.32.49/drivers/usb/misc/appledisplay.c linux-2.6.32.= 49/drivers/usb/misc/appledisplay.c ---- linux-2.6.32.49/drivers/usb/misc/appledisplay.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/usb/misc/appledisplay.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -178,7 +178,7 @@ static int appledisplay_bl_get_brightnes +diff --git a/drivers/usb/misc/appledisplay.c b/drivers/usb/misc/appledis= play.c +index 62ff5e7..530b74e 100644 +--- a/drivers/usb/misc/appledisplay.c ++++ b/drivers/usb/misc/appledisplay.c +@@ -178,7 +178,7 @@ static int appledisplay_bl_get_brightness(struct bac= klight_device *bd) return pdata->msgdata[1]; } =20 @@ -40528,9 +42361,10 @@ diff -urNp linux-2.6.32.49/drivers/usb/misc/appl= edisplay.c linux-2.6.32.49/drive .get_brightness =3D appledisplay_bl_get_brightness, .update_status =3D appledisplay_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/usb/mon/mon_main.c linux-2.6.32.49/dr= ivers/usb/mon/mon_main.c ---- linux-2.6.32.49/drivers/usb/mon/mon_main.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/usb/mon/mon_main.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/drivers/usb/mon/mon_main.c b/drivers/usb/mon/mon_main.c +index e0c2db3..bd8cb66 100644 +--- a/drivers/usb/mon/mon_main.c ++++ b/drivers/usb/mon/mon_main.c @@ -238,7 +238,7 @@ static struct notifier_block mon_nb =3D { /* * Ops @@ -40540,9 +42374,10 @@ diff -urNp linux-2.6.32.49/drivers/usb/mon/mon_m= ain.c linux-2.6.32.49/drivers/us .urb_submit =3D mon_submit, .urb_submit_error =3D mon_submit_error, .urb_complete =3D mon_complete, -diff -urNp linux-2.6.32.49/drivers/usb/wusbcore/wa-hc.h linux-2.6.32.49/= drivers/usb/wusbcore/wa-hc.h ---- linux-2.6.32.49/drivers/usb/wusbcore/wa-hc.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/usb/wusbcore/wa-hc.h 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/drivers/usb/wusbcore/wa-hc.h b/drivers/usb/wusbcore/wa-hc.h +index d6bea3e..60b250e 100644 +--- a/drivers/usb/wusbcore/wa-hc.h ++++ b/drivers/usb/wusbcore/wa-hc.h @@ -192,7 +192,7 @@ struct wahc { struct list_head xfer_delayed_list; spinlock_t xfer_list_lock; @@ -40552,7 +42387,7 @@ diff -urNp linux-2.6.32.49/drivers/usb/wusbcore/w= a-hc.h linux-2.6.32.49/drivers/ }; =20 =20 -@@ -246,7 +246,7 @@ static inline void wa_init(struct wahc * +@@ -246,7 +246,7 @@ static inline void wa_init(struct wahc *wa) INIT_LIST_HEAD(&wa->xfer_delayed_list); spin_lock_init(&wa->xfer_list_lock); INIT_WORK(&wa->xfer_work, wa_urb_enqueue_run); @@ -40561,9 +42396,10 @@ diff -urNp linux-2.6.32.49/drivers/usb/wusbcore/= wa-hc.h linux-2.6.32.49/drivers/ } =20 /** -diff -urNp linux-2.6.32.49/drivers/usb/wusbcore/wa-xfer.c linux-2.6.32.4= 9/drivers/usb/wusbcore/wa-xfer.c ---- linux-2.6.32.49/drivers/usb/wusbcore/wa-xfer.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/usb/wusbcore/wa-xfer.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/drivers/usb/wusbcore/wa-xfer.c b/drivers/usb/wusbcore/wa-xf= er.c +index 613a5fc..3174865 100644 +--- a/drivers/usb/wusbcore/wa-xfer.c ++++ b/drivers/usb/wusbcore/wa-xfer.c @@ -293,7 +293,7 @@ out: */ static void wa_xfer_id_init(struct wa_xfer *xfer) @@ -40573,10 +42409,11 @@ diff -urNp linux-2.6.32.49/drivers/usb/wusbcore= /wa-xfer.c linux-2.6.32.49/driver } =20 /* -diff -urNp linux-2.6.32.49/drivers/uwb/wlp/messages.c linux-2.6.32.49/dr= ivers/uwb/wlp/messages.c ---- linux-2.6.32.49/drivers/uwb/wlp/messages.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/uwb/wlp/messages.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -903,7 +903,7 @@ int wlp_parse_f0(struct wlp *wlp, struct +diff --git a/drivers/uwb/wlp/messages.c b/drivers/uwb/wlp/messages.c +index aa42fce..f8a828c 100644 +--- a/drivers/uwb/wlp/messages.c ++++ b/drivers/uwb/wlp/messages.c +@@ -903,7 +903,7 @@ int wlp_parse_f0(struct wlp *wlp, struct sk_buff *sk= b) size_t len =3D skb->len; size_t used; ssize_t result; @@ -40585,10 +42422,11 @@ diff -urNp linux-2.6.32.49/drivers/uwb/wlp/mess= ages.c linux-2.6.32.49/drivers/uw enum wlp_assc_error assc_err; char enonce_buf[WLP_WSS_NONCE_STRSIZE]; char rnonce_buf[WLP_WSS_NONCE_STRSIZE]; -diff -urNp linux-2.6.32.49/drivers/uwb/wlp/sysfs.c linux-2.6.32.49/drive= rs/uwb/wlp/sysfs.c ---- linux-2.6.32.49/drivers/uwb/wlp/sysfs.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/uwb/wlp/sysfs.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -615,8 +615,7 @@ ssize_t wlp_wss_attr_store(struct kobjec +diff --git a/drivers/uwb/wlp/sysfs.c b/drivers/uwb/wlp/sysfs.c +index 0370399..6627c94 100644 +--- a/drivers/uwb/wlp/sysfs.c ++++ b/drivers/uwb/wlp/sysfs.c +@@ -615,8 +615,7 @@ ssize_t wlp_wss_attr_store(struct kobject *kobj, str= uct attribute *attr, return ret; } =20 @@ -40598,10 +42436,11 @@ diff -urNp linux-2.6.32.49/drivers/uwb/wlp/sysf= s.c linux-2.6.32.49/drivers/uwb/w .show =3D wlp_wss_attr_show, .store =3D wlp_wss_attr_store, }; -diff -urNp linux-2.6.32.49/drivers/video/atmel_lcdfb.c linux-2.6.32.49/d= rivers/video/atmel_lcdfb.c ---- linux-2.6.32.49/drivers/video/atmel_lcdfb.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/drivers/video/atmel_lcdfb.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -110,7 +110,7 @@ static int atmel_bl_get_brightness(struc +diff --git a/drivers/video/atmel_lcdfb.c b/drivers/video/atmel_lcdfb.c +index d5e8010..5687b56 100644 +--- a/drivers/video/atmel_lcdfb.c ++++ b/drivers/video/atmel_lcdfb.c +@@ -110,7 +110,7 @@ static int atmel_bl_get_brightness(struct backlight_= device *bl) return lcdc_readl(sinfo, ATMEL_LCDC_CONTRAST_VAL); } =20 @@ -40610,9 +42449,10 @@ diff -urNp linux-2.6.32.49/drivers/video/atmel_l= cdfb.c linux-2.6.32.49/drivers/v .update_status =3D atmel_bl_update_status, .get_brightness =3D atmel_bl_get_brightness, }; -diff -urNp linux-2.6.32.49/drivers/video/aty/aty128fb.c linux-2.6.32.49/= drivers/video/aty/aty128fb.c ---- linux-2.6.32.49/drivers/video/aty/aty128fb.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/video/aty/aty128fb.c 2011-11-18 18:01:55.000= 000000 -0500 +diff --git a/drivers/video/aty/aty128fb.c b/drivers/video/aty/aty128fb.c +index e4e4d43..66bcbcc 100644 +--- a/drivers/video/aty/aty128fb.c ++++ b/drivers/video/aty/aty128fb.c @@ -149,7 +149,7 @@ enum { }; =20 @@ -40622,7 +42462,7 @@ diff -urNp linux-2.6.32.49/drivers/video/aty/aty1= 28fb.c linux-2.6.32.49/drivers/ "AGP", "PCI", "PRO AGP", -@@ -1787,7 +1787,7 @@ static int aty128_bl_get_brightness(stru +@@ -1787,7 +1787,7 @@ static int aty128_bl_get_brightness(struct backlig= ht_device *bd) return bd->props.brightness; } =20 @@ -40631,10 +42471,11 @@ diff -urNp linux-2.6.32.49/drivers/video/aty/at= y128fb.c linux-2.6.32.49/drivers/ .get_brightness =3D aty128_bl_get_brightness, .update_status =3D aty128_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/aty/atyfb_base.c linux-2.6.32.4= 9/drivers/video/aty/atyfb_base.c ---- linux-2.6.32.49/drivers/video/aty/atyfb_base.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/video/aty/atyfb_base.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -2225,7 +2225,7 @@ static int aty_bl_get_brightness(struct=20 +diff --git a/drivers/video/aty/atyfb_base.c b/drivers/video/aty/atyfb_ba= se.c +index 913b4a4..9295a38 100644 +--- a/drivers/video/aty/atyfb_base.c ++++ b/drivers/video/aty/atyfb_base.c +@@ -2225,7 +2225,7 @@ static int aty_bl_get_brightness(struct backlight_= device *bd) return bd->props.brightness; } =20 @@ -40643,10 +42484,11 @@ diff -urNp linux-2.6.32.49/drivers/video/aty/at= yfb_base.c linux-2.6.32.49/driver .get_brightness =3D aty_bl_get_brightness, .update_status =3D aty_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/aty/radeon_backlight.c linux-2.= 6.32.49/drivers/video/aty/radeon_backlight.c ---- linux-2.6.32.49/drivers/video/aty/radeon_backlight.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/aty/radeon_backlight.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -127,7 +127,7 @@ static int radeon_bl_get_brightness(stru +diff --git a/drivers/video/aty/radeon_backlight.c b/drivers/video/aty/ra= deon_backlight.c +index 1a056ad..221bd6a 100644 +--- a/drivers/video/aty/radeon_backlight.c ++++ b/drivers/video/aty/radeon_backlight.c +@@ -127,7 +127,7 @@ static int radeon_bl_get_brightness(struct backlight= _device *bd) return bd->props.brightness; } =20 @@ -40655,10 +42497,11 @@ diff -urNp linux-2.6.32.49/drivers/video/aty/ra= deon_backlight.c linux-2.6.32.49/ .get_brightness =3D radeon_bl_get_brightness, .update_status =3D radeon_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/adp5520_bl.c linux-2.= 6.32.49/drivers/video/backlight/adp5520_bl.c ---- linux-2.6.32.49/drivers/video/backlight/adp5520_bl.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/adp5520_bl.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -84,7 +84,7 @@ static int adp5520_bl_get_brightness(str +diff --git a/drivers/video/backlight/adp5520_bl.c b/drivers/video/backli= ght/adp5520_bl.c +index ad05da5..3cb2cb9 100644 +--- a/drivers/video/backlight/adp5520_bl.c ++++ b/drivers/video/backlight/adp5520_bl.c +@@ -84,7 +84,7 @@ static int adp5520_bl_get_brightness(struct backlight_= device *bl) return error ? data->current_brightness : reg_val; } =20 @@ -40667,10 +42510,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/adp5520_bl.c linux-2.6.32.49/ .update_status =3D adp5520_bl_update_status, .get_brightness =3D adp5520_bl_get_brightness, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/adx_bl.c linux-2.6.32= .49/drivers/video/backlight/adx_bl.c ---- linux-2.6.32.49/drivers/video/backlight/adx_bl.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/adx_bl.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -61,7 +61,7 @@ static int adx_backlight_check_fb(struct +diff --git a/drivers/video/backlight/adx_bl.c b/drivers/video/backlight/= adx_bl.c +index 2c3bdfc..d769b0b 100644 +--- a/drivers/video/backlight/adx_bl.c ++++ b/drivers/video/backlight/adx_bl.c +@@ -61,7 +61,7 @@ static int adx_backlight_check_fb(struct fb_info *fb) return 1; } =20 @@ -40679,10 +42523,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/adx_bl.c linux-2.6.32.49/driv .options =3D 0, .update_status =3D adx_backlight_update_status, .get_brightness =3D adx_backlight_get_brightness, -diff -urNp linux-2.6.32.49/drivers/video/backlight/atmel-pwm-bl.c linux-= 2.6.32.49/drivers/video/backlight/atmel-pwm-bl.c ---- linux-2.6.32.49/drivers/video/backlight/atmel-pwm-bl.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/atmel-pwm-bl.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -113,7 +113,7 @@ static int atmel_pwm_bl_init_pwm(struct=20 +diff --git a/drivers/video/backlight/atmel-pwm-bl.c b/drivers/video/back= light/atmel-pwm-bl.c +index 505c082..6b6b3cc 100644 +--- a/drivers/video/backlight/atmel-pwm-bl.c ++++ b/drivers/video/backlight/atmel-pwm-bl.c +@@ -113,7 +113,7 @@ static int atmel_pwm_bl_init_pwm(struct atmel_pwm_bl= *pwmbl) return pwm_channel_enable(&pwmbl->pwmc); } =20 @@ -40691,9 +42536,10 @@ diff -urNp linux-2.6.32.49/drivers/video/backlig= ht/atmel-pwm-bl.c linux-2.6.32.4 .get_brightness =3D atmel_pwm_bl_get_intensity, .update_status =3D atmel_pwm_bl_set_intensity, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/backlight.c linux-2.6= .32.49/drivers/video/backlight/backlight.c ---- linux-2.6.32.49/drivers/video/backlight/backlight.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/backlight.c 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/drivers/video/backlight/backlight.c b/drivers/video/backlig= ht/backlight.c +index 5e20e6e..89025e6 100644 +--- a/drivers/video/backlight/backlight.c ++++ b/drivers/video/backlight/backlight.c @@ -269,7 +269,7 @@ EXPORT_SYMBOL(backlight_force_update); * ERR_PTR() or a pointer to the newly allocated device. */ @@ -40703,10 +42549,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/backlight.c linux-2.6.32.49/d { struct backlight_device *new_bd; int rc; -diff -urNp linux-2.6.32.49/drivers/video/backlight/corgi_lcd.c linux-2.6= .32.49/drivers/video/backlight/corgi_lcd.c ---- linux-2.6.32.49/drivers/video/backlight/corgi_lcd.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/corgi_lcd.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -451,7 +451,7 @@ void corgi_lcd_limit_intensity(int limit +diff --git a/drivers/video/backlight/corgi_lcd.c b/drivers/video/backlig= ht/corgi_lcd.c +index 9677494..b4bcf80 100644 +--- a/drivers/video/backlight/corgi_lcd.c ++++ b/drivers/video/backlight/corgi_lcd.c +@@ -451,7 +451,7 @@ void corgi_lcd_limit_intensity(int limit) } EXPORT_SYMBOL(corgi_lcd_limit_intensity); =20 @@ -40715,10 +42562,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/corgi_lcd.c linux-2.6.32.49/d .get_brightness =3D corgi_bl_get_intensity, .update_status =3D corgi_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/cr_bllcd.c linux-2.6.= 32.49/drivers/video/backlight/cr_bllcd.c ---- linux-2.6.32.49/drivers/video/backlight/cr_bllcd.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/cr_bllcd.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -108,7 +108,7 @@ static int cr_backlight_get_intensity(st +diff --git a/drivers/video/backlight/cr_bllcd.c b/drivers/video/backligh= t/cr_bllcd.c +index b9fe62b..2914bf1 100644 +--- a/drivers/video/backlight/cr_bllcd.c ++++ b/drivers/video/backlight/cr_bllcd.c +@@ -108,7 +108,7 @@ static int cr_backlight_get_intensity(struct backlig= ht_device *bd) return intensity; } =20 @@ -40727,10 +42575,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/cr_bllcd.c linux-2.6.32.49/dr .get_brightness =3D cr_backlight_get_intensity, .update_status =3D cr_backlight_set_intensity, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/da903x_bl.c linux-2.6= .32.49/drivers/video/backlight/da903x_bl.c ---- linux-2.6.32.49/drivers/video/backlight/da903x_bl.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/da903x_bl.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -94,7 +94,7 @@ static int da903x_backlight_get_brightne +diff --git a/drivers/video/backlight/da903x_bl.c b/drivers/video/backlig= ht/da903x_bl.c +index 701a108..feacfd5 100644 +--- a/drivers/video/backlight/da903x_bl.c ++++ b/drivers/video/backlight/da903x_bl.c +@@ -94,7 +94,7 @@ static int da903x_backlight_get_brightness(struct back= light_device *bl) return data->current_brightness; } =20 @@ -40739,9 +42588,10 @@ diff -urNp linux-2.6.32.49/drivers/video/backlig= ht/da903x_bl.c linux-2.6.32.49/d .update_status =3D da903x_backlight_update_status, .get_brightness =3D da903x_backlight_get_brightness, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/generic_bl.c linux-2.= 6.32.49/drivers/video/backlight/generic_bl.c ---- linux-2.6.32.49/drivers/video/backlight/generic_bl.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/generic_bl.c 2011-11-15 19:5= 9:43.000000000 -0500 +diff --git a/drivers/video/backlight/generic_bl.c b/drivers/video/backli= ght/generic_bl.c +index 6d27f62..e6d348e 100644 +--- a/drivers/video/backlight/generic_bl.c ++++ b/drivers/video/backlight/generic_bl.c @@ -70,7 +70,7 @@ void corgibl_limit_intensity(int limit) } EXPORT_SYMBOL(corgibl_limit_intensity); @@ -40751,10 +42601,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/generic_bl.c linux-2.6.32.49/ .options =3D BL_CORE_SUSPENDRESUME, .get_brightness =3D genericbl_get_intensity, .update_status =3D genericbl_send_intensity, -diff -urNp linux-2.6.32.49/drivers/video/backlight/hp680_bl.c linux-2.6.= 32.49/drivers/video/backlight/hp680_bl.c ---- linux-2.6.32.49/drivers/video/backlight/hp680_bl.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/hp680_bl.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -98,7 +98,7 @@ static int hp680bl_get_intensity(struct=20 +diff --git a/drivers/video/backlight/hp680_bl.c b/drivers/video/backligh= t/hp680_bl.c +index 7fb4eef..f7cc528 100644 +--- a/drivers/video/backlight/hp680_bl.c ++++ b/drivers/video/backlight/hp680_bl.c +@@ -98,7 +98,7 @@ static int hp680bl_get_intensity(struct backlight_devi= ce *bd) return current_intensity; } =20 @@ -40763,9 +42614,10 @@ diff -urNp linux-2.6.32.49/drivers/video/backlig= ht/hp680_bl.c linux-2.6.32.49/dr .get_brightness =3D hp680bl_get_intensity, .update_status =3D hp680bl_set_intensity, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/jornada720_bl.c linux= -2.6.32.49/drivers/video/backlight/jornada720_bl.c ---- linux-2.6.32.49/drivers/video/backlight/jornada720_bl.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/jornada720_bl.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/video/backlight/jornada720_bl.c b/drivers/video/bac= klight/jornada720_bl.c +index 7aed256..db9071f 100644 +--- a/drivers/video/backlight/jornada720_bl.c ++++ b/drivers/video/backlight/jornada720_bl.c @@ -93,7 +93,7 @@ out: return ret; } @@ -40775,10 +42627,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/jornada720_bl.c linux-2.6.32. .get_brightness =3D jornada_bl_get_brightness, .update_status =3D jornada_bl_update_status, .options =3D BL_CORE_SUSPENDRESUME, -diff -urNp linux-2.6.32.49/drivers/video/backlight/kb3886_bl.c linux-2.6= .32.49/drivers/video/backlight/kb3886_bl.c ---- linux-2.6.32.49/drivers/video/backlight/kb3886_bl.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/kb3886_bl.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -134,7 +134,7 @@ static int kb3886bl_get_intensity(struct +diff --git a/drivers/video/backlight/kb3886_bl.c b/drivers/video/backlig= ht/kb3886_bl.c +index a38fda1..939e7b8 100644 +--- a/drivers/video/backlight/kb3886_bl.c ++++ b/drivers/video/backlight/kb3886_bl.c +@@ -134,7 +134,7 @@ static int kb3886bl_get_intensity(struct backlight_d= evice *bd) return kb3886bl_intensity; } =20 @@ -40787,10 +42640,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/kb3886_bl.c linux-2.6.32.49/d .get_brightness =3D kb3886bl_get_intensity, .update_status =3D kb3886bl_send_intensity, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/locomolcd.c linux-2.6= .32.49/drivers/video/backlight/locomolcd.c ---- linux-2.6.32.49/drivers/video/backlight/locomolcd.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/locomolcd.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -141,7 +141,7 @@ static int locomolcd_get_intensity(struc +diff --git a/drivers/video/backlight/locomolcd.c b/drivers/video/backlig= ht/locomolcd.c +index 6b488b8..00a9591 100644 +--- a/drivers/video/backlight/locomolcd.c ++++ b/drivers/video/backlight/locomolcd.c +@@ -141,7 +141,7 @@ static int locomolcd_get_intensity(struct backlight_= device *bd) return current_intensity; } =20 @@ -40799,9 +42653,10 @@ diff -urNp linux-2.6.32.49/drivers/video/backlig= ht/locomolcd.c linux-2.6.32.49/d .get_brightness =3D locomolcd_get_intensity, .update_status =3D locomolcd_set_intensity, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/mbp_nvidia_bl.c linux= -2.6.32.49/drivers/video/backlight/mbp_nvidia_bl.c ---- linux-2.6.32.49/drivers/video/backlight/mbp_nvidia_bl.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/mbp_nvidia_bl.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/drivers/video/backlight/mbp_nvidia_bl.c b/drivers/video/bac= klight/mbp_nvidia_bl.c +index 99bdfa8..3dac448 100644 +--- a/drivers/video/backlight/mbp_nvidia_bl.c ++++ b/drivers/video/backlight/mbp_nvidia_bl.c @@ -33,7 +33,7 @@ struct dmi_match_data { unsigned long iostart; unsigned long iolen; @@ -40811,10 +42666,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/mbp_nvidia_bl.c linux-2.6.32. }; =20 /* Module parameters. */ -diff -urNp linux-2.6.32.49/drivers/video/backlight/omap1_bl.c linux-2.6.= 32.49/drivers/video/backlight/omap1_bl.c ---- linux-2.6.32.49/drivers/video/backlight/omap1_bl.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/omap1_bl.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -125,7 +125,7 @@ static int omapbl_get_intensity(struct b +diff --git a/drivers/video/backlight/omap1_bl.c b/drivers/video/backligh= t/omap1_bl.c +index cbad67e..3cf900e 100644 +--- a/drivers/video/backlight/omap1_bl.c ++++ b/drivers/video/backlight/omap1_bl.c +@@ -125,7 +125,7 @@ static int omapbl_get_intensity(struct backlight_dev= ice *dev) return bl->current_intensity; } =20 @@ -40823,10 +42679,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/omap1_bl.c linux-2.6.32.49/dr .get_brightness =3D omapbl_get_intensity, .update_status =3D omapbl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/progear_bl.c linux-2.= 6.32.49/drivers/video/backlight/progear_bl.c ---- linux-2.6.32.49/drivers/video/backlight/progear_bl.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/progear_bl.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -54,7 +54,7 @@ static int progearbl_get_intensity(struc +diff --git a/drivers/video/backlight/progear_bl.c b/drivers/video/backli= ght/progear_bl.c +index 9edaf24..075786e 100644 +--- a/drivers/video/backlight/progear_bl.c ++++ b/drivers/video/backlight/progear_bl.c +@@ -54,7 +54,7 @@ static int progearbl_get_intensity(struct backlight_de= vice *bd) return intensity - HW_LEVEL_MIN; } =20 @@ -40835,10 +42692,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/progear_bl.c linux-2.6.32.49/ .get_brightness =3D progearbl_get_intensity, .update_status =3D progearbl_set_intensity, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/pwm_bl.c linux-2.6.32= .49/drivers/video/backlight/pwm_bl.c ---- linux-2.6.32.49/drivers/video/backlight/pwm_bl.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/pwm_bl.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -56,7 +56,7 @@ static int pwm_backlight_get_brightness( +diff --git a/drivers/video/backlight/pwm_bl.c b/drivers/video/backlight/= pwm_bl.c +index 8871662..df9e0b3 100644 +--- a/drivers/video/backlight/pwm_bl.c ++++ b/drivers/video/backlight/pwm_bl.c +@@ -56,7 +56,7 @@ static int pwm_backlight_get_brightness(struct backlig= ht_device *bl) return bl->props.brightness; } =20 @@ -40847,10 +42705,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/pwm_bl.c linux-2.6.32.49/driv .update_status =3D pwm_backlight_update_status, .get_brightness =3D pwm_backlight_get_brightness, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/tosa_bl.c linux-2.6.3= 2.49/drivers/video/backlight/tosa_bl.c ---- linux-2.6.32.49/drivers/video/backlight/tosa_bl.c 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/tosa_bl.c 2011-11-15 19:59:4= 3.000000000 -0500 -@@ -72,7 +72,7 @@ static int tosa_bl_get_brightness(struct +diff --git a/drivers/video/backlight/tosa_bl.c b/drivers/video/backlight= /tosa_bl.c +index 43edbad..e14ce4d 100644 +--- a/drivers/video/backlight/tosa_bl.c ++++ b/drivers/video/backlight/tosa_bl.c +@@ -72,7 +72,7 @@ static int tosa_bl_get_brightness(struct backlight_dev= ice *dev) return props->brightness; } =20 @@ -40859,10 +42718,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/tosa_bl.c linux-2.6.32.49/dri .get_brightness =3D tosa_bl_get_brightness, .update_status =3D tosa_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/backlight/wm831x_bl.c linux-2.6= .32.49/drivers/video/backlight/wm831x_bl.c ---- linux-2.6.32.49/drivers/video/backlight/wm831x_bl.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/backlight/wm831x_bl.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -112,7 +112,7 @@ static int wm831x_backlight_get_brightne +diff --git a/drivers/video/backlight/wm831x_bl.c b/drivers/video/backlig= ht/wm831x_bl.c +index 467bdb7..e32add3 100644 +--- a/drivers/video/backlight/wm831x_bl.c ++++ b/drivers/video/backlight/wm831x_bl.c +@@ -112,7 +112,7 @@ static int wm831x_backlight_get_brightness(struct ba= cklight_device *bl) return data->current_brightness; } =20 @@ -40871,10 +42731,11 @@ diff -urNp linux-2.6.32.49/drivers/video/backli= ght/wm831x_bl.c linux-2.6.32.49/d .options =3D BL_CORE_SUSPENDRESUME, .update_status =3D wm831x_backlight_update_status, .get_brightness =3D wm831x_backlight_get_brightness, -diff -urNp linux-2.6.32.49/drivers/video/bf54x-lq043fb.c linux-2.6.32.49= /drivers/video/bf54x-lq043fb.c ---- linux-2.6.32.49/drivers/video/bf54x-lq043fb.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/drivers/video/bf54x-lq043fb.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -463,7 +463,7 @@ static int bl_get_brightness(struct back +diff --git a/drivers/video/bf54x-lq043fb.c b/drivers/video/bf54x-lq043fb= .c +index e49ae5e..db4e6f7 100644 +--- a/drivers/video/bf54x-lq043fb.c ++++ b/drivers/video/bf54x-lq043fb.c +@@ -463,7 +463,7 @@ static int bl_get_brightness(struct backlight_device= *bd) return 0; } =20 @@ -40883,10 +42744,11 @@ diff -urNp linux-2.6.32.49/drivers/video/bf54x-= lq043fb.c linux-2.6.32.49/drivers .get_brightness =3D bl_get_brightness, }; =20 -diff -urNp linux-2.6.32.49/drivers/video/bfin-t350mcqb-fb.c linux-2.6.32= .49/drivers/video/bfin-t350mcqb-fb.c ---- linux-2.6.32.49/drivers/video/bfin-t350mcqb-fb.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/video/bfin-t350mcqb-fb.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -381,7 +381,7 @@ static int bl_get_brightness(struct back +diff --git a/drivers/video/bfin-t350mcqb-fb.c b/drivers/video/bfin-t350m= cqb-fb.c +index 2c72a7c..d523e52 100644 +--- a/drivers/video/bfin-t350mcqb-fb.c ++++ b/drivers/video/bfin-t350mcqb-fb.c +@@ -381,7 +381,7 @@ static int bl_get_brightness(struct backlight_device= *bd) return 0; } =20 @@ -40895,10 +42757,11 @@ diff -urNp linux-2.6.32.49/drivers/video/bfin-t= 350mcqb-fb.c linux-2.6.32.49/driv .get_brightness =3D bl_get_brightness, }; =20 -diff -urNp linux-2.6.32.49/drivers/video/fbcmap.c linux-2.6.32.49/driver= s/video/fbcmap.c ---- linux-2.6.32.49/drivers/video/fbcmap.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/video/fbcmap.c 2011-11-15 19:59:43.000000000= -0500 -@@ -266,8 +266,7 @@ int fb_set_user_cmap(struct fb_cmap_user +diff --git a/drivers/video/fbcmap.c b/drivers/video/fbcmap.c +index f53b9f1..958bf4e 100644 +--- a/drivers/video/fbcmap.c ++++ b/drivers/video/fbcmap.c +@@ -266,8 +266,7 @@ int fb_set_user_cmap(struct fb_cmap_user *cmap, stru= ct fb_info *info) rc =3D -ENODEV; goto out; } @@ -40908,10 +42771,11 @@ diff -urNp linux-2.6.32.49/drivers/video/fbcmap= .c linux-2.6.32.49/drivers/video/ rc =3D -EINVAL; goto out1; } -diff -urNp linux-2.6.32.49/drivers/video/fbmem.c linux-2.6.32.49/drivers= /video/fbmem.c ---- linux-2.6.32.49/drivers/video/fbmem.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/drivers/video/fbmem.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -403,7 +403,7 @@ static void fb_do_show_logo(struct fb_in +diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c +index 99bbd28..ad3829e 100644 +--- a/drivers/video/fbmem.c ++++ b/drivers/video/fbmem.c +@@ -403,7 +403,7 @@ static void fb_do_show_logo(struct fb_info *info, st= ruct fb_image *image, image->dx +=3D image->width + 8; } } else if (rotate =3D=3D FB_ROTATE_UD) { @@ -40920,7 +42784,7 @@ diff -urNp linux-2.6.32.49/drivers/video/fbmem.c = linux-2.6.32.49/drivers/video/f info->fbops->fb_imageblit(info, image); image->dx -=3D image->width + 8; } -@@ -415,7 +415,7 @@ static void fb_do_show_logo(struct fb_in +@@ -415,7 +415,7 @@ static void fb_do_show_logo(struct fb_info *info, st= ruct fb_image *image, image->dy +=3D image->height + 8; } } else if (rotate =3D=3D FB_ROTATE_CCW) { @@ -40929,7 +42793,7 @@ diff -urNp linux-2.6.32.49/drivers/video/fbmem.c = linux-2.6.32.49/drivers/video/f info->fbops->fb_imageblit(info, image); image->dy -=3D image->height + 8; } -@@ -915,6 +915,8 @@ fb_set_var(struct fb_info *info, struct=20 +@@ -915,6 +915,8 @@ fb_set_var(struct fb_info *info, struct fb_var_scree= ninfo *var) int flags =3D info->flags; int ret =3D 0; =20 @@ -40938,7 +42802,7 @@ diff -urNp linux-2.6.32.49/drivers/video/fbmem.c = linux-2.6.32.49/drivers/video/f if (var->activate & FB_ACTIVATE_INV_MODE) { struct fb_videomode mode1, mode2; =20 -@@ -1040,6 +1042,8 @@ static long do_fb_ioctl(struct fb_info * +@@ -1040,6 +1042,8 @@ static long do_fb_ioctl(struct fb_info *info, unsi= gned int cmd, void __user *argp =3D (void __user *)arg; long ret =3D 0; =20 @@ -40947,7 +42811,7 @@ diff -urNp linux-2.6.32.49/drivers/video/fbmem.c = linux-2.6.32.49/drivers/video/f switch (cmd) { case FBIOGET_VSCREENINFO: if (!lock_fb_info(info)) -@@ -1119,7 +1123,7 @@ static long do_fb_ioctl(struct fb_info * +@@ -1119,7 +1123,7 @@ static long do_fb_ioctl(struct fb_info *info, unsi= gned int cmd, return -EFAULT; if (con2fb.console < 1 || con2fb.console > MAX_NR_CONSOLES) return -EINVAL; @@ -40956,9 +42820,10 @@ diff -urNp linux-2.6.32.49/drivers/video/fbmem.c= linux-2.6.32.49/drivers/video/f return -EINVAL; if (!registered_fb[con2fb.framebuffer]) request_module("fb%d", con2fb.framebuffer); -diff -urNp linux-2.6.32.49/drivers/video/geode/gx1fb_core.c linux-2.6.32= .49/drivers/video/geode/gx1fb_core.c ---- linux-2.6.32.49/drivers/video/geode/gx1fb_core.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/drivers/video/geode/gx1fb_core.c 2011-11-18 18:01:55= .000000000 -0500 +diff --git a/drivers/video/geode/gx1fb_core.c b/drivers/video/geode/gx1f= b_core.c +index f20eff8..3e4f622 100644 +--- a/drivers/video/geode/gx1fb_core.c ++++ b/drivers/video/geode/gx1fb_core.c @@ -30,7 +30,7 @@ static int crt_option =3D 1; static char panel_option[32] =3D ""; =20 @@ -40968,9 +42833,10 @@ diff -urNp linux-2.6.32.49/drivers/video/geode/g= x1fb_core.c linux-2.6.32.49/driv /* 640x480-60 VESA */ { NULL, 60, 640, 480, 39682, 48, 16, 33, 10, 96, 2, 0, FB_VMODE_NONINTERLACED, FB_MODE_IS_VESA }, -diff -urNp linux-2.6.32.49/drivers/video/gxt4500.c linux-2.6.32.49/drive= rs/video/gxt4500.c ---- linux-2.6.32.49/drivers/video/gxt4500.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/video/gxt4500.c 2011-11-18 18:01:55.00000000= 0 -0500 +diff --git a/drivers/video/gxt4500.c b/drivers/video/gxt4500.c +index 896e53d..4d87d0b 100644 +--- a/drivers/video/gxt4500.c ++++ b/drivers/video/gxt4500.c @@ -156,7 +156,7 @@ struct gxt4500_par { static char *mode_option; =20 @@ -40980,7 +42846,7 @@ diff -urNp linux-2.6.32.49/drivers/video/gxt4500.= c linux-2.6.32.49/drivers/video .refresh =3D 60, .xres =3D 1280, .yres =3D 1024, -@@ -581,7 +581,7 @@ static int gxt4500_blank(int blank, stru +@@ -581,7 +581,7 @@ static int gxt4500_blank(int blank, struct fb_info *= info) return 0; } =20 @@ -40989,10 +42855,11 @@ diff -urNp linux-2.6.32.49/drivers/video/gxt450= 0.c linux-2.6.32.49/drivers/video .id =3D "IBM GXT4500P", .type =3D FB_TYPE_PACKED_PIXELS, .visual =3D FB_VISUAL_PSEUDOCOLOR, -diff -urNp linux-2.6.32.49/drivers/video/i810/i810_accel.c linux-2.6.32.= 49/drivers/video/i810/i810_accel.c ---- linux-2.6.32.49/drivers/video/i810/i810_accel.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/drivers/video/i810/i810_accel.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -73,6 +73,7 @@ static inline int wait_for_space(struct=20 +diff --git a/drivers/video/i810/i810_accel.c b/drivers/video/i810/i810_a= ccel.c +index f5bedee..28c6028 100644 +--- a/drivers/video/i810/i810_accel.c ++++ b/drivers/video/i810/i810_accel.c +@@ -73,6 +73,7 @@ static inline int wait_for_space(struct fb_info *info,= u32 space) } } printk("ringbuffer lockup!!!\n"); @@ -41000,10 +42867,11 @@ diff -urNp linux-2.6.32.49/drivers/video/i810/i= 810_accel.c linux-2.6.32.49/drive i810_report_error(mmio);=20 par->dev_flags |=3D LOCKUP; info->pixmap.scan_align =3D 1; -diff -urNp linux-2.6.32.49/drivers/video/i810/i810_main.c linux-2.6.32.4= 9/drivers/video/i810/i810_main.c ---- linux-2.6.32.49/drivers/video/i810/i810_main.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/drivers/video/i810/i810_main.c 2011-11-18 18:01:55.0= 00000000 -0500 -@@ -97,7 +97,7 @@ static int i810fb_blank (int blank_ +diff --git a/drivers/video/i810/i810_main.c b/drivers/video/i810/i810_ma= in.c +index 5743ea2..457f82c 100644 +--- a/drivers/video/i810/i810_main.c ++++ b/drivers/video/i810/i810_main.c +@@ -97,7 +97,7 @@ static int i810fb_blank (int blank_mode, struct f= b_info *info); static void i810fb_release_resource (struct fb_info *info, struct= i810fb_par *par); =20 /* PCI */ @@ -41012,9 +42880,10 @@ diff -urNp linux-2.6.32.49/drivers/video/i810/i8= 10_main.c linux-2.6.32.49/driver "Intel(R) 810 Framebuffer Device" , "Intel(R) 810-DC100 Framebuffer Device" , "Intel(R) 810E Framebuffer Device" , -diff -urNp linux-2.6.32.49/drivers/video/logo/logo_linux_clut224.ppm lin= ux-2.6.32.49/drivers/video/logo/logo_linux_clut224.ppm ---- linux-2.6.32.49/drivers/video/logo/logo_linux_clut224.ppm 2011-11-08= 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/logo/logo_linux_clut224.ppm 2011-11-15= 19:59:43.000000000 -0500 +diff --git a/drivers/video/logo/logo_linux_clut224.ppm b/drivers/video/l= ogo/logo_linux_clut224.ppm +index 3c14e43..eafa544 100644 +--- a/drivers/video/logo/logo_linux_clut224.ppm ++++ b/drivers/video/logo/logo_linux_clut224.ppm @@ -1,1604 +1,1123 @@ P3 -# Standard 224-color Linux logo @@ -43740,10 +45609,11 @@ diff -urNp linux-2.6.32.49/drivers/video/logo/l= ogo_linux_clut224.ppm linux-2.6.3 +4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 +4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 +4 4 4 4 4 4 -diff -urNp linux-2.6.32.49/drivers/video/nvidia/nv_backlight.c linux-2.6= .32.49/drivers/video/nvidia/nv_backlight.c ---- linux-2.6.32.49/drivers/video/nvidia/nv_backlight.c 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/drivers/video/nvidia/nv_backlight.c 2011-11-15 19:59= :43.000000000 -0500 -@@ -87,7 +87,7 @@ static int nvidia_bl_get_brightness(stru +diff --git a/drivers/video/nvidia/nv_backlight.c b/drivers/video/nvidia/= nv_backlight.c +index 443e3c8..c443d6a 100644 +--- a/drivers/video/nvidia/nv_backlight.c ++++ b/drivers/video/nvidia/nv_backlight.c +@@ -87,7 +87,7 @@ static int nvidia_bl_get_brightness(struct backlight_d= evice *bd) return bd->props.brightness; } =20 @@ -43752,10 +45622,11 @@ diff -urNp linux-2.6.32.49/drivers/video/nvidia= /nv_backlight.c linux-2.6.32.49/d .get_brightness =3D nvidia_bl_get_brightness, .update_status =3D nvidia_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/riva/fbdev.c linux-2.6.32.49/dr= ivers/video/riva/fbdev.c ---- linux-2.6.32.49/drivers/video/riva/fbdev.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/drivers/video/riva/fbdev.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -331,7 +331,7 @@ static int riva_bl_get_brightness(struct +diff --git a/drivers/video/riva/fbdev.c b/drivers/video/riva/fbdev.c +index d94c57f..912984c 100644 +--- a/drivers/video/riva/fbdev.c ++++ b/drivers/video/riva/fbdev.c +@@ -331,7 +331,7 @@ static int riva_bl_get_brightness(struct backlight_d= evice *bd) return bd->props.brightness; } =20 @@ -43764,9 +45635,10 @@ diff -urNp linux-2.6.32.49/drivers/video/riva/fb= dev.c linux-2.6.32.49/drivers/vi .get_brightness =3D riva_bl_get_brightness, .update_status =3D riva_bl_update_status, }; -diff -urNp linux-2.6.32.49/drivers/video/uvesafb.c linux-2.6.32.49/drive= rs/video/uvesafb.c ---- linux-2.6.32.49/drivers/video/uvesafb.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/drivers/video/uvesafb.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/drivers/video/uvesafb.c b/drivers/video/uvesafb.c +index 54fbb29..2c108fc 100644 +--- a/drivers/video/uvesafb.c ++++ b/drivers/video/uvesafb.c @@ -18,6 +18,7 @@ #include #include @@ -43784,7 +45656,7 @@ diff -urNp linux-2.6.32.49/drivers/video/uvesafb.= c linux-2.6.32.49/drivers/video } =20 /* -@@ -568,10 +569,32 @@ static int __devinit uvesafb_vbe_getpmi( +@@ -568,10 +569,32 @@ static int __devinit uvesafb_vbe_getpmi(struct uve= safb_ktask *task, if ((task->t.regs.eax & 0xffff) !=3D 0x4f || task->t.regs.es < 0xc000)= { par->pmi_setpal =3D par->ypan =3D 0; } else { @@ -43829,7 +45701,7 @@ diff -urNp linux-2.6.32.49/drivers/video/uvesafb.= c linux-2.6.32.49/drivers/video framebuffer_release(info); return err; } -@@ -1825,6 +1853,12 @@ static int uvesafb_remove(struct platfor +@@ -1825,6 +1853,12 @@ static int uvesafb_remove(struct platform_device = *dev) kfree(par->vbe_state_orig); if (par->vbe_state_saved) kfree(par->vbe_state_saved); @@ -43842,9 +45714,10 @@ diff -urNp linux-2.6.32.49/drivers/video/uvesafb= .c linux-2.6.32.49/drivers/video } =20 framebuffer_release(info); -diff -urNp linux-2.6.32.49/drivers/video/vesafb.c linux-2.6.32.49/driver= s/video/vesafb.c ---- linux-2.6.32.49/drivers/video/vesafb.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/drivers/video/vesafb.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/drivers/video/vesafb.c b/drivers/video/vesafb.c +index bd37ee1..cb827e8 100644 +--- a/drivers/video/vesafb.c ++++ b/drivers/video/vesafb.c @@ -9,6 +9,7 @@ */ =20 @@ -43853,7 +45726,7 @@ diff -urNp linux-2.6.32.49/drivers/video/vesafb.c= linux-2.6.32.49/drivers/video/ #include #include #include -@@ -53,8 +54,8 @@ static int vram_remap __initdata; /*=20 +@@ -53,8 +54,8 @@ static int vram_remap __initdata; /* Set amount of = memory to be used */ static int vram_total __initdata; /* Set total amount of memory */ static int pmi_setpal __read_mostly =3D 1; /* pmi for palette changes= ??? */ static int ypan __read_mostly; /* 0..nothing, 1..ypan, 2..ywra= p */ @@ -43864,7 +45737,7 @@ diff -urNp linux-2.6.32.49/drivers/video/vesafb.c= linux-2.6.32.49/drivers/video/ static int depth __read_mostly; static int vga_compat __read_mostly; /* --------------------------------------------------------------------= - */ -@@ -233,6 +234,7 @@ static int __init vesafb_probe(struct pl +@@ -233,6 +234,7 @@ static int __init vesafb_probe(struct platform_devic= e *dev) unsigned int size_vmode; unsigned int size_remap; unsigned int size_total; @@ -43872,7 +45745,7 @@ diff -urNp linux-2.6.32.49/drivers/video/vesafb.c= linux-2.6.32.49/drivers/video/ =20 if (screen_info.orig_video_isVGA !=3D VIDEO_TYPE_VLFB) return -ENODEV; -@@ -275,10 +277,6 @@ static int __init vesafb_probe(struct pl +@@ -275,10 +277,6 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) size_remap =3D size_total; vesafb_fix.smem_len =3D size_remap; =20 @@ -43883,7 +45756,7 @@ diff -urNp linux-2.6.32.49/drivers/video/vesafb.c= linux-2.6.32.49/drivers/video/ if (!request_mem_region(vesafb_fix.smem_start, size_total, "vesafb")) = { printk(KERN_WARNING "vesafb: cannot reserve video memory at 0x%lx\n", -@@ -315,9 +313,21 @@ static int __init vesafb_probe(struct pl +@@ -315,9 +313,21 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) printk(KERN_INFO "vesafb: mode is %dx%dx%d, linelength=3D%d, pages=3D%= d\n", vesafb_defined.xres, vesafb_defined.yres, vesafb_defined.bits_p= er_pixel, vesafb_fix.line_length, screen_info.pages); =20 @@ -43907,7 +45780,7 @@ diff -urNp linux-2.6.32.49/drivers/video/vesafb.c= linux-2.6.32.49/drivers/video/ } =20 if (screen_info.vesapm_seg < 0xc000) -@@ -325,9 +335,25 @@ static int __init vesafb_probe(struct pl +@@ -325,9 +335,25 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) =20 if (ypan || pmi_setpal) { unsigned short *pmi_base; @@ -43935,7 +45808,7 @@ diff -urNp linux-2.6.32.49/drivers/video/vesafb.c= linux-2.6.32.49/drivers/video/ printk(KERN_INFO "vesafb: pmi: set display start =3D %p, set palette = =3D %p\n",pmi_start,pmi_pal); if (pmi_base[3]) { printk(KERN_INFO "vesafb: pmi: ports =3D "); -@@ -469,6 +495,11 @@ static int __init vesafb_probe(struct pl +@@ -469,6 +495,11 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) info->node, info->fix.id); return 0; err: @@ -43947,10 +45820,11 @@ diff -urNp linux-2.6.32.49/drivers/video/vesafb= .c linux-2.6.32.49/drivers/video/ if (info->screen_base) iounmap(info->screen_base); framebuffer_release(info); -diff -urNp linux-2.6.32.49/drivers/xen/sys-hypervisor.c linux-2.6.32.49/= drivers/xen/sys-hypervisor.c ---- linux-2.6.32.49/drivers/xen/sys-hypervisor.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/drivers/xen/sys-hypervisor.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -425,7 +425,7 @@ static ssize_t hyp_sysfs_store(struct ko +diff --git a/drivers/xen/sys-hypervisor.c b/drivers/xen/sys-hypervisor.c +index 88a60e0..6783cc2 100644 +--- a/drivers/xen/sys-hypervisor.c ++++ b/drivers/xen/sys-hypervisor.c +@@ -425,7 +425,7 @@ static ssize_t hyp_sysfs_store(struct kobject *kobj, return 0; } =20 @@ -43959,10 +45833,11 @@ diff -urNp linux-2.6.32.49/drivers/xen/sys-hype= rvisor.c linux-2.6.32.49/drivers/ .show =3D hyp_sysfs_show, .store =3D hyp_sysfs_store, }; -diff -urNp linux-2.6.32.49/fs/9p/vfs_inode.c linux-2.6.32.49/fs/9p/vfs_i= node.c ---- linux-2.6.32.49/fs/9p/vfs_inode.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/9p/vfs_inode.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -1079,7 +1079,7 @@ static void *v9fs_vfs_follow_link(struct +diff --git a/fs/9p/vfs_inode.c b/fs/9p/vfs_inode.c +index 18f74ec..3227009 100644 +--- a/fs/9p/vfs_inode.c ++++ b/fs/9p/vfs_inode.c +@@ -1079,7 +1079,7 @@ static void *v9fs_vfs_follow_link(struct dentry *d= entry, struct nameidata *nd) static void v9fs_vfs_put_link(struct dentry *dentry, struct nameidata *nd, void *p) { @@ -43971,10 +45846,24 @@ diff -urNp linux-2.6.32.49/fs/9p/vfs_inode.c li= nux-2.6.32.49/fs/9p/vfs_inode.c =20 P9_DPRINTK(P9_DEBUG_VFS, " %s %s\n", dentry->d_name.name, IS_ERR(s) ? "" : s); -diff -urNp linux-2.6.32.49/fs/aio.c linux-2.6.32.49/fs/aio.c ---- linux-2.6.32.49/fs/aio.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/aio.c 2011-11-15 19:59:43.000000000 -0500 -@@ -115,7 +115,7 @@ static int aio_setup_ring(struct kioctx=20 +diff --git a/fs/Kconfig.binfmt b/fs/Kconfig.binfmt +index bb4cc5b..df5eaa0 100644 +--- a/fs/Kconfig.binfmt ++++ b/fs/Kconfig.binfmt +@@ -86,7 +86,7 @@ config HAVE_AOUT +=20 + config BINFMT_AOUT + tristate "Kernel support for a.out and ECOFF binaries" +- depends on HAVE_AOUT ++ depends on HAVE_AOUT && BROKEN + ---help--- + A.out (Assembler.OUTput) is a set of formats for libraries and + executables used in the earliest versions of UNIX. Linux used +diff --git a/fs/aio.c b/fs/aio.c +index 22a19ad..d484e5b 100644 +--- a/fs/aio.c ++++ b/fs/aio.c +@@ -115,7 +115,7 @@ static int aio_setup_ring(struct kioctx *ctx) size +=3D sizeof(struct io_event) * nr_events; nr_pages =3D (size + PAGE_SIZE-1) >> PAGE_SHIFT; =20 @@ -43983,7 +45872,7 @@ diff -urNp linux-2.6.32.49/fs/aio.c linux-2.6.32.= 49/fs/aio.c return -EINVAL; =20 nr_events =3D (PAGE_SIZE * nr_pages - sizeof(struct aio_ring)) / sizeo= f(struct io_event); -@@ -1089,6 +1089,8 @@ static int read_events(struct kioctx *ct +@@ -1089,6 +1089,8 @@ static int read_events(struct kioctx *ctx, struct aio_timeout to; int retry =3D 0; =20 @@ -43992,7 +45881,7 @@ diff -urNp linux-2.6.32.49/fs/aio.c linux-2.6.32.= 49/fs/aio.c /* needed to zero any padding within an entry (there shouldn't be=20 * any, but C is fun! */ -@@ -1382,13 +1384,18 @@ static ssize_t aio_fsync(struct kiocb *i +@@ -1382,13 +1384,18 @@ static ssize_t aio_fsync(struct kiocb *iocb) static ssize_t aio_setup_vectored_rw(int type, struct kiocb *kiocb) { ssize_t ret; @@ -44012,10 +45901,11 @@ diff -urNp linux-2.6.32.49/fs/aio.c linux-2.6.3= 2.49/fs/aio.c kiocb->ki_nr_segs =3D kiocb->ki_nbytes; kiocb->ki_cur_seg =3D 0; /* ki_nbytes/left now reflect bytes instead of segs */ -diff -urNp linux-2.6.32.49/fs/attr.c linux-2.6.32.49/fs/attr.c ---- linux-2.6.32.49/fs/attr.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/attr.c 2011-11-15 19:59:43.000000000 -0500 -@@ -83,6 +83,7 @@ int inode_newsize_ok(const struct inode=20 +diff --git a/fs/attr.c b/fs/attr.c +index 96d394b..33cf5b4 100644 +--- a/fs/attr.c ++++ b/fs/attr.c +@@ -83,6 +83,7 @@ int inode_newsize_ok(const struct inode *inode, loff_t= offset) unsigned long limit; =20 limit =3D current->signal->rlim[RLIMIT_FSIZE].rlim_cur; @@ -44023,10 +45913,11 @@ diff -urNp linux-2.6.32.49/fs/attr.c linux-2.6.= 32.49/fs/attr.c if (limit !=3D RLIM_INFINITY && offset > limit) goto out_sig; if (offset > inode->i_sb->s_maxbytes) -diff -urNp linux-2.6.32.49/fs/autofs/root.c linux-2.6.32.49/fs/autofs/ro= ot.c ---- linux-2.6.32.49/fs/autofs/root.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/autofs/root.c 2011-11-15 19:59:43.000000000 -0500 -@@ -299,7 +299,8 @@ static int autofs_root_symlink(struct in +diff --git a/fs/autofs/root.c b/fs/autofs/root.c +index 4a1401c..05eb5ca 100644 +--- a/fs/autofs/root.c ++++ b/fs/autofs/root.c +@@ -299,7 +299,8 @@ static int autofs_root_symlink(struct inode *dir, st= ruct dentry *dentry, const c set_bit(n,sbi->symlink_bitmap); sl =3D &sbi->symlink[n]; sl->len =3D strlen(symname); @@ -44036,9 +45927,10 @@ diff -urNp linux-2.6.32.49/fs/autofs/root.c linu= x-2.6.32.49/fs/autofs/root.c if (!sl->data) { clear_bit(n,sbi->symlink_bitmap); unlock_kernel(); -diff -urNp linux-2.6.32.49/fs/autofs4/symlink.c linux-2.6.32.49/fs/autof= s4/symlink.c ---- linux-2.6.32.49/fs/autofs4/symlink.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/autofs4/symlink.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/fs/autofs4/symlink.c b/fs/autofs4/symlink.c +index b4ea829..e63ef18 100644 +--- a/fs/autofs4/symlink.c ++++ b/fs/autofs4/symlink.c @@ -15,7 +15,7 @@ static void *autofs4_follow_link(struct dentry *dentry, struct nameidat= a *nd) { @@ -44048,10 +45940,11 @@ diff -urNp linux-2.6.32.49/fs/autofs4/symlink.c= linux-2.6.32.49/fs/autofs4/symli return NULL; } =20 -diff -urNp linux-2.6.32.49/fs/autofs4/waitq.c linux-2.6.32.49/fs/autofs4= /waitq.c ---- linux-2.6.32.49/fs/autofs4/waitq.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/autofs4/waitq.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -60,7 +60,7 @@ static int autofs4_write(struct file *fi +diff --git a/fs/autofs4/waitq.c b/fs/autofs4/waitq.c +index 2341375..df9d1c2 100644 +--- a/fs/autofs4/waitq.c ++++ b/fs/autofs4/waitq.c +@@ -60,7 +60,7 @@ static int autofs4_write(struct file *file, const void= *addr, int bytes) { unsigned long sigpipe, flags; mm_segment_t fs; @@ -44060,10 +45953,11 @@ diff -urNp linux-2.6.32.49/fs/autofs4/waitq.c l= inux-2.6.32.49/fs/autofs4/waitq.c ssize_t wr =3D 0; =20 /** WARNING: this is not safe for writing more than PIPE_BUF bytes! **= / -diff -urNp linux-2.6.32.49/fs/befs/linuxvfs.c linux-2.6.32.49/fs/befs/li= nuxvfs.c ---- linux-2.6.32.49/fs/befs/linuxvfs.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/befs/linuxvfs.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -498,7 +498,7 @@ static void befs_put_link(struct dentry=20 +diff --git a/fs/befs/linuxvfs.c b/fs/befs/linuxvfs.c +index 9158c07..3f06659 100644 +--- a/fs/befs/linuxvfs.c ++++ b/fs/befs/linuxvfs.c +@@ -498,7 +498,7 @@ static void befs_put_link(struct dentry *dentry, str= uct nameidata *nd, void *p) { befs_inode_info *befs_ino =3D BEFS_I(dentry->d_inode); if (befs_ino->i_flags & BEFS_LONG_SYMLINK) { @@ -44072,9 +45966,10 @@ diff -urNp linux-2.6.32.49/fs/befs/linuxvfs.c li= nux-2.6.32.49/fs/befs/linuxvfs.c if (!IS_ERR(link)) kfree(link); } -diff -urNp linux-2.6.32.49/fs/binfmt_aout.c linux-2.6.32.49/fs/binfmt_ao= ut.c ---- linux-2.6.32.49/fs/binfmt_aout.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/binfmt_aout.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/binfmt_aout.c b/fs/binfmt_aout.c +index 0133b5a..b3baa9f 100644 +--- a/fs/binfmt_aout.c ++++ b/fs/binfmt_aout.c @@ -16,6 +16,7 @@ #include #include @@ -44083,7 +45978,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_aout.c linux= -2.6.32.49/fs/binfmt_aout.c #include #include #include -@@ -102,6 +103,8 @@ static int aout_core_dump(long signr, st +@@ -102,6 +103,8 @@ static int aout_core_dump(long signr, struct pt_regs= *regs, struct file *file, u #endif # define START_STACK(u) (u.start_stack) =20 @@ -44092,7 +45987,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_aout.c linux= -2.6.32.49/fs/binfmt_aout.c fs =3D get_fs(); set_fs(KERNEL_DS); has_dumped =3D 1; -@@ -113,10 +116,12 @@ static int aout_core_dump(long signr, st +@@ -113,10 +116,12 @@ static int aout_core_dump(long signr, struct pt_re= gs *regs, struct file *file, u =20 /* If the size of the dump file exceeds the rlimit, then see what would= happen if we wrote the stack, but not the data area. */ @@ -44105,7 +46000,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_aout.c linux= -2.6.32.49/fs/binfmt_aout.c if ((dump.u_ssize + 1) * PAGE_SIZE > limit) dump.u_ssize =3D 0; =20 -@@ -146,9 +151,7 @@ static int aout_core_dump(long signr, st +@@ -146,9 +151,7 @@ static int aout_core_dump(long signr, struct pt_regs= *regs, struct file *file, u dump_size =3D dump.u_ssize << PAGE_SHIFT; DUMP_WRITE(dump_start,dump_size); } @@ -44116,7 +46011,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_aout.c linux= -2.6.32.49/fs/binfmt_aout.c end_coredump: set_fs(fs); return has_dumped; -@@ -249,6 +252,8 @@ static int load_aout_binary(struct linux +@@ -249,6 +252,8 @@ static int load_aout_binary(struct linux_binprm * bp= rm, struct pt_regs * regs) rlim =3D current->signal->rlim[RLIMIT_DATA].rlim_cur; if (rlim >=3D RLIM_INFINITY) rlim =3D ~0; @@ -44125,7 +46020,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_aout.c linux= -2.6.32.49/fs/binfmt_aout.c if (ex.a_data + ex.a_bss > rlim) return -ENOMEM; =20 -@@ -277,6 +282,27 @@ static int load_aout_binary(struct linux +@@ -277,6 +282,27 @@ static int load_aout_binary(struct linux_binprm * b= prm, struct pt_regs * regs) install_exec_creds(bprm); current->flags &=3D ~PF_FORKNOEXEC; =20 @@ -44153,7 +46048,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_aout.c linux= -2.6.32.49/fs/binfmt_aout.c if (N_MAGIC(ex) =3D=3D OMAGIC) { unsigned long text_addr, map_size; loff_t pos; -@@ -349,7 +375,7 @@ static int load_aout_binary(struct linux +@@ -349,7 +375,7 @@ static int load_aout_binary(struct linux_binprm * bp= rm, struct pt_regs * regs) =20 down_write(¤t->mm->mmap_sem); error =3D do_mmap(bprm->file, N_DATADDR(ex), ex.a_data, @@ -44162,10 +46057,11 @@ diff -urNp linux-2.6.32.49/fs/binfmt_aout.c lin= ux-2.6.32.49/fs/binfmt_aout.c MAP_FIXED | MAP_PRIVATE | MAP_DENYWRITE | MAP_EXECUTABLE, fd_offset + ex.a_text); up_write(¤t->mm->mmap_sem); -diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-2.6.32.49/fs/binfmt_elf= .c ---- linux-2.6.32.49/fs/binfmt_elf.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/binfmt_elf.c 2011-11-18 18:51:56.000000000 -0500 -@@ -50,6 +50,10 @@ static int elf_core_dump(long signr, str +diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c +index 1ed37ba..32cc555 100644 +--- a/fs/binfmt_elf.c ++++ b/fs/binfmt_elf.c +@@ -50,6 +50,10 @@ static int elf_core_dump(long signr, struct pt_regs *= regs, struct file *file, un #define elf_core_dump NULL #endif =20 @@ -44176,7 +46072,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c #if ELF_EXEC_PAGESIZE > PAGE_SIZE #define ELF_MIN_ALIGN ELF_EXEC_PAGESIZE #else -@@ -69,6 +73,11 @@ static struct linux_binfmt elf_format =3D=20 +@@ -69,6 +73,11 @@ static struct linux_binfmt elf_format =3D { .load_binary =3D load_elf_binary, .load_shlib =3D load_elf_library, .core_dump =3D elf_core_dump, @@ -44188,7 +46084,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c .min_coredump =3D ELF_EXEC_PAGESIZE, .hasvdso =3D 1 }; -@@ -77,6 +86,8 @@ static struct linux_binfmt elf_format =3D=20 +@@ -77,6 +86,8 @@ static struct linux_binfmt elf_format =3D { =20 static int set_brk(unsigned long start, unsigned long end) { @@ -44197,7 +46093,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c start =3D ELF_PAGEALIGN(start); end =3D ELF_PAGEALIGN(end); if (end > start) { -@@ -87,7 +98,7 @@ static int set_brk(unsigned long start,=20 +@@ -87,7 +98,7 @@ static int set_brk(unsigned long start, unsigned long = end) if (BAD_ADDR(addr)) return addr; } @@ -44206,7 +46102,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c return 0; } =20 -@@ -148,12 +159,15 @@ create_elf_tables(struct linux_binprm *b +@@ -148,12 +159,15 @@ create_elf_tables(struct linux_binprm *bprm, struc= t elfhdr *exec, elf_addr_t __user *u_rand_bytes; const char *k_platform =3D ELF_PLATFORM; const char *k_base_platform =3D ELF_BASE_PLATFORM; @@ -44223,7 +46119,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c =20 /* * In some cases (e.g. Hyper-Threading), we want to avoid L1 -@@ -195,8 +209,12 @@ create_elf_tables(struct linux_binprm *b +@@ -195,8 +209,12 @@ create_elf_tables(struct linux_binprm *bprm, struct= elfhdr *exec, * Generate 16 random bytes for userspace PRNG seeding. */ get_random_bytes(k_rand_bytes, sizeof(k_rand_bytes)); @@ -44238,7 +46134,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c if (__copy_to_user(u_rand_bytes, k_rand_bytes, sizeof(k_rand_bytes))) return -EFAULT; =20 -@@ -308,9 +326,11 @@ create_elf_tables(struct linux_binprm *b +@@ -308,9 +326,11 @@ create_elf_tables(struct linux_binprm *bprm, struct= elfhdr *exec, return -EFAULT; current->mm->env_end =3D p; =20 @@ -44251,7 +46147,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c return -EFAULT; return 0; } -@@ -385,10 +405,10 @@ static unsigned long load_elf_interp(str +@@ -385,10 +405,10 @@ static unsigned long load_elf_interp(struct elfhdr= *interp_elf_ex, { struct elf_phdr *elf_phdata; struct elf_phdr *eppnt; @@ -44264,7 +46160,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c unsigned long total_size; int retval, i, size; =20 -@@ -434,6 +454,11 @@ static unsigned long load_elf_interp(str +@@ -434,6 +454,11 @@ static unsigned long load_elf_interp(struct elfhdr = *interp_elf_ex, goto out_close; } =20 @@ -44276,7 +46172,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c eppnt =3D elf_phdata; for (i =3D 0; i < interp_elf_ex->e_phnum; i++, eppnt++) { if (eppnt->p_type =3D=3D PT_LOAD) { -@@ -477,8 +502,8 @@ static unsigned long load_elf_interp(str +@@ -477,8 +502,8 @@ static unsigned long load_elf_interp(struct elfhdr *= interp_elf_ex, k =3D load_addr + eppnt->p_vaddr; if (BAD_ADDR(k) || eppnt->p_filesz > eppnt->p_memsz || @@ -44482,7 +46378,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c /* * These are the functions used to load ELF style executables and share= d * libraries. There is no binary dependent code anywhere else. -@@ -548,6 +761,11 @@ static unsigned long randomize_stack_top +@@ -548,6 +761,11 @@ static unsigned long randomize_stack_top(unsigned l= ong stack_top) { unsigned int random_variable =3D 0; =20 @@ -44494,7 +46390,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c if ((current->flags & PF_RANDOMIZE) && !(current->personality & ADDR_NO_RANDOMIZE)) { random_variable =3D get_random_int() & STACK_RND_MASK; -@@ -566,7 +784,7 @@ static int load_elf_binary(struct linux_ +@@ -566,7 +784,7 @@ static int load_elf_binary(struct linux_binprm *bprm= , struct pt_regs *regs) unsigned long load_addr =3D 0, load_bias =3D 0; int load_addr_set =3D 0; char * elf_interpreter =3D NULL; @@ -44503,7 +46399,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c struct elf_phdr *elf_ppnt, *elf_phdata; unsigned long elf_bss, elf_brk; int retval, i; -@@ -576,11 +794,11 @@ static int load_elf_binary(struct linux_ +@@ -576,11 +794,11 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) unsigned long start_code, end_code, start_data, end_data; unsigned long reloc_func_desc =3D 0; int executable_stack =3D EXSTACK_DEFAULT; @@ -44516,7 +46412,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c =20 loc =3D kmalloc(sizeof(*loc), GFP_KERNEL); if (!loc) { -@@ -718,11 +936,80 @@ static int load_elf_binary(struct linux_ +@@ -718,11 +936,80 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) =20 /* OK, This is the point of no return */ current->flags &=3D ~PF_FORKNOEXEC; @@ -44598,7 +46494,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c if (elf_read_implies_exec(loc->elf_ex, executable_stack)) current->personality |=3D READ_IMPLIES_EXEC; =20 -@@ -800,10 +1087,27 @@ static int load_elf_binary(struct linux_ +@@ -800,10 +1087,27 @@ static int load_elf_binary(struct linux_binprm *b= prm, struct pt_regs *regs) * might try to exec. This is because the brk will * follow the loader, and is not movable. */ #ifdef CONFIG_X86 @@ -44627,7 +46523,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c } =20 error =3D elf_map(bprm->file, load_bias + vaddr, elf_ppnt, -@@ -836,9 +1140,9 @@ static int load_elf_binary(struct linux_ +@@ -836,9 +1140,9 @@ static int load_elf_binary(struct linux_binprm *bpr= m, struct pt_regs *regs) * allowed task size. Note that p_filesz must always be * <=3D p_memsz so it is only necessary to check p_memsz. */ @@ -44640,7 +46536,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c /* set_brk can never work. Avoid overflows. */ send_sig(SIGKILL, current, 0); retval =3D -EINVAL; -@@ -866,6 +1170,11 @@ static int load_elf_binary(struct linux_ +@@ -866,6 +1170,11 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) start_data +=3D load_bias; end_data +=3D load_bias; =20 @@ -44652,7 +46548,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c /* Calling set_brk effectively mmaps the pages that we need * for the bss and break sections. We must do this before * mapping in the interpreter, to make sure it doesn't wind -@@ -877,9 +1186,11 @@ static int load_elf_binary(struct linux_ +@@ -877,9 +1186,11 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) goto out_free_dentry; } if (likely(elf_bss !=3D elf_brk) && unlikely(padzero(elf_bss))) { @@ -44667,7 +46563,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c } =20 if (elf_interpreter) { -@@ -1112,8 +1423,10 @@ static int dump_seek(struct file *file,=20 +@@ -1112,8 +1423,10 @@ static int dump_seek(struct file *file, loff_t of= f) unsigned long n =3D off; if (n > PAGE_SIZE) n =3D PAGE_SIZE; @@ -44679,7 +46575,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c off -=3D n; } free_page((unsigned long)buf); -@@ -1125,7 +1438,7 @@ static int dump_seek(struct file *file,=20 +@@ -1125,7 +1438,7 @@ static int dump_seek(struct file *file, loff_t off= ) * Decide what to dump of a segment, part, all or none. */ static unsigned long vma_dump_size(struct vm_area_struct *vma, @@ -44688,7 +46584,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c { #define FILTER(type) (mm_flags & (1UL << MMF_DUMP_##type)) =20 -@@ -1159,7 +1472,7 @@ static unsigned long vma_dump_size(struc +@@ -1159,7 +1472,7 @@ static unsigned long vma_dump_size(struct vm_area_= struct *vma, if (vma->vm_file =3D=3D NULL) return 0; =20 @@ -44697,7 +46593,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c goto whole; =20 /* -@@ -1255,8 +1568,11 @@ static int writenote(struct memelfnote * +@@ -1255,8 +1568,11 @@ static int writenote(struct memelfnote *men, stru= ct file *file, #undef DUMP_WRITE =20 #define DUMP_WRITE(addr, nr) \ @@ -44710,7 +46606,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c =20 static void fill_elf_header(struct elfhdr *elf, int segs, u16 machine, u32 flags, u8 osabi) -@@ -1385,9 +1701,9 @@ static void fill_auxv_note(struct memelf +@@ -1385,9 +1701,9 @@ static void fill_auxv_note(struct memelfnote *note= , struct mm_struct *mm) { elf_addr_t *auxv =3D (elf_addr_t *) mm->saved_auxv; int i =3D 0; @@ -44722,7 +46618,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c fill_note(note, "CORE", NT_AUXV, i * sizeof(elf_addr_t), auxv); } =20 -@@ -1973,7 +2289,7 @@ static int elf_core_dump(long signr, str +@@ -1973,7 +2289,7 @@ static int elf_core_dump(long signr, struct pt_reg= s *regs, struct file *file, un phdr.p_offset =3D offset; phdr.p_vaddr =3D vma->vm_start; phdr.p_paddr =3D 0; @@ -44731,7 +46627,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c phdr.p_memsz =3D vma->vm_end - vma->vm_start; offset +=3D phdr.p_filesz; phdr.p_flags =3D vma->vm_flags & VM_READ ? PF_R : 0; -@@ -2006,7 +2322,7 @@ static int elf_core_dump(long signr, str +@@ -2006,7 +2322,7 @@ static int elf_core_dump(long signr, struct pt_reg= s *regs, struct file *file, un unsigned long addr; unsigned long end; =20 @@ -44740,7 +46636,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linux-= 2.6.32.49/fs/binfmt_elf.c =20 for (addr =3D vma->vm_start; addr < end; addr +=3D PAGE_SIZE) { struct page *page; -@@ -2015,6 +2331,7 @@ static int elf_core_dump(long signr, str +@@ -2015,6 +2331,7 @@ static int elf_core_dump(long signr, struct pt_reg= s *regs, struct file *file, un page =3D get_dump_page(addr); if (page) { void *kaddr =3D kmap(page); @@ -44846,10 +46742,11 @@ diff -urNp linux-2.6.32.49/fs/binfmt_elf.c linu= x-2.6.32.49/fs/binfmt_elf.c static int __init init_elf_binfmt(void) { return register_binfmt(&elf_format); -diff -urNp linux-2.6.32.49/fs/binfmt_flat.c linux-2.6.32.49/fs/binfmt_fl= at.c ---- linux-2.6.32.49/fs/binfmt_flat.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/binfmt_flat.c 2011-11-15 19:59:43.000000000 -0500 -@@ -564,7 +564,9 @@ static int load_flat_file(struct linux_b +diff --git a/fs/binfmt_flat.c b/fs/binfmt_flat.c +index ca88c46..f155a60 100644 +--- a/fs/binfmt_flat.c ++++ b/fs/binfmt_flat.c +@@ -564,7 +564,9 @@ static int load_flat_file(struct linux_binprm * bprm= , realdatastart =3D (unsigned long) -ENOMEM; printk("Unable to allocate RAM for process data, errno %d\n", (int)-realdatastart); @@ -44859,7 +46756,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_flat.c linux= -2.6.32.49/fs/binfmt_flat.c ret =3D realdatastart; goto err; } -@@ -588,8 +590,10 @@ static int load_flat_file(struct linux_b +@@ -588,8 +590,10 @@ static int load_flat_file(struct linux_binprm * bpr= m, } if (IS_ERR_VALUE(result)) { printk("Unable to read data+bss, errno %d\n", (int)-result); @@ -44870,7 +46767,7 @@ diff -urNp linux-2.6.32.49/fs/binfmt_flat.c linux= -2.6.32.49/fs/binfmt_flat.c ret =3D result; goto err; } -@@ -658,8 +662,10 @@ static int load_flat_file(struct linux_b +@@ -658,8 +662,10 @@ static int load_flat_file(struct linux_binprm * bpr= m, } if (IS_ERR_VALUE(result)) { printk("Unable to read code+data+bss, errno %d\n",(int)-result); @@ -44881,10 +46778,11 @@ diff -urNp linux-2.6.32.49/fs/binfmt_flat.c lin= ux-2.6.32.49/fs/binfmt_flat.c ret =3D result; goto err; } -diff -urNp linux-2.6.32.49/fs/bio.c linux-2.6.32.49/fs/bio.c ---- linux-2.6.32.49/fs/bio.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/bio.c 2011-11-15 19:59:43.000000000 -0500 -@@ -78,7 +78,7 @@ static struct kmem_cache *bio_find_or_cr +diff --git a/fs/bio.c b/fs/bio.c +index e696713..83de133 100644 +--- a/fs/bio.c ++++ b/fs/bio.c +@@ -78,7 +78,7 @@ static struct kmem_cache *bio_find_or_create_slab(unsi= gned int extra_size) =20 i =3D 0; while (i < bio_slab_nr) { @@ -44893,7 +46791,7 @@ diff -urNp linux-2.6.32.49/fs/bio.c linux-2.6.32.= 49/fs/bio.c =20 if (!bslab->slab && entry =3D=3D -1) entry =3D i; -@@ -1236,7 +1236,7 @@ static void bio_copy_kern_endio(struct b +@@ -1236,7 +1236,7 @@ static void bio_copy_kern_endio(struct bio *bio, i= nt err) const int read =3D bio_data_dir(bio) =3D=3D READ; struct bio_map_data *bmd =3D bio->bi_private; int i; @@ -44902,10 +46800,11 @@ diff -urNp linux-2.6.32.49/fs/bio.c linux-2.6.3= 2.49/fs/bio.c =20 __bio_for_each_segment(bvec, bio, i, 0) { char *addr =3D page_address(bvec->bv_page); -diff -urNp linux-2.6.32.49/fs/block_dev.c linux-2.6.32.49/fs/block_dev.c ---- linux-2.6.32.49/fs/block_dev.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/block_dev.c 2011-11-15 19:59:43.000000000 -0500 -@@ -664,7 +664,7 @@ int bd_claim(struct block_device *bdev,=20 +diff --git a/fs/block_dev.c b/fs/block_dev.c +index e65efa2..04fae57 100644 +--- a/fs/block_dev.c ++++ b/fs/block_dev.c +@@ -664,7 +664,7 @@ int bd_claim(struct block_device *bdev, void *holder= ) else if (bdev->bd_contains =3D=3D bdev) res =3D 0; /* is a whole device which isn't held */ =20 @@ -44914,10 +46813,11 @@ diff -urNp linux-2.6.32.49/fs/block_dev.c linux= -2.6.32.49/fs/block_dev.c res =3D 0; /* is a partition of a device that is being partitioned = */ else if (bdev->bd_contains->bd_holder !=3D NULL) res =3D -EBUSY; /* is a partition of a held device */ -diff -urNp linux-2.6.32.49/fs/btrfs/ctree.c linux-2.6.32.49/fs/btrfs/ctr= ee.c ---- linux-2.6.32.49/fs/btrfs/ctree.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/btrfs/ctree.c 2011-11-15 19:59:43.000000000 -0500 -@@ -461,9 +461,12 @@ static noinline int __btrfs_cow_block(st +diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c +index c4bc570..42acd8d 100644 +--- a/fs/btrfs/ctree.c ++++ b/fs/btrfs/ctree.c +@@ -461,9 +461,12 @@ static noinline int __btrfs_cow_block(struct btrfs_= trans_handle *trans, free_extent_buffer(buf); add_root_to_dirty_list(root); } else { @@ -44933,7 +46833,7 @@ diff -urNp linux-2.6.32.49/fs/btrfs/ctree.c linux= -2.6.32.49/fs/btrfs/ctree.c parent_start =3D 0; =20 WARN_ON(trans->transid !=3D btrfs_header_generation(parent)); -@@ -3645,7 +3648,6 @@ setup_items_for_insert(struct btrfs_tran +@@ -3645,7 +3648,6 @@ setup_items_for_insert(struct btrfs_trans_handle *= trans, =20 ret =3D 0; if (slot =3D=3D 0) { @@ -44941,9 +46841,10 @@ diff -urNp linux-2.6.32.49/fs/btrfs/ctree.c linu= x-2.6.32.49/fs/btrfs/ctree.c btrfs_cpu_key_to_disk(&disk_key, cpu_key); ret =3D fixup_low_keys(trans, root, path, &disk_key, 1); } -diff -urNp linux-2.6.32.49/fs/btrfs/disk-io.c linux-2.6.32.49/fs/btrfs/d= isk-io.c ---- linux-2.6.32.49/fs/btrfs/disk-io.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/btrfs/disk-io.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c +index f447188..59c17c5 100644 +--- a/fs/btrfs/disk-io.c ++++ b/fs/btrfs/disk-io.c @@ -39,7 +39,7 @@ #include "tree-log.h" #include "free-space-cache.h" @@ -44962,10 +46863,26 @@ diff -urNp linux-2.6.32.49/fs/btrfs/disk-io.c l= inux-2.6.32.49/fs/btrfs/disk-io.c .write_cache_pages_lock_hook =3D btree_lock_page_hook, .readpage_end_io_hook =3D btree_readpage_end_io_hook, .submit_bio_hook =3D btree_submit_bio_hook, -diff -urNp linux-2.6.32.49/fs/btrfs/extent_io.h linux-2.6.32.49/fs/btrfs= /extent_io.h ---- linux-2.6.32.49/fs/btrfs/extent_io.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/btrfs/extent_io.h 2011-11-15 19:59:43.000000000 -= 0500 -@@ -49,36 +49,36 @@ typedef int (extent_submit_bio_hook_t)(s +diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c +index 559f724..a026171 100644 +--- a/fs/btrfs/extent-tree.c ++++ b/fs/btrfs/extent-tree.c +@@ -7141,6 +7141,10 @@ static noinline int relocate_one_extent(struct bt= rfs_root *extent_root, + u64 group_start =3D group->key.objectid; + new_extents =3D kmalloc(sizeof(*new_extents), + GFP_NOFS); ++ if (!new_extents) { ++ ret =3D -ENOMEM; ++ goto out; ++ } + nr_extents =3D 1; + ret =3D get_new_locations(reloc_inode, + extent_key, +diff --git a/fs/btrfs/extent_io.h b/fs/btrfs/extent_io.h +index 36de250..7ec75c7 100644 +--- a/fs/btrfs/extent_io.h ++++ b/fs/btrfs/extent_io.h +@@ -49,36 +49,36 @@ typedef int (extent_submit_bio_hook_t)(struct inode = *inode, int rw, struct bio *bio, int mirror_num, unsigned long bio_flags); struct extent_io_ops { @@ -45025,24 +46942,11 @@ diff -urNp linux-2.6.32.49/fs/btrfs/extent_io.h= linux-2.6.32.49/fs/btrfs/extent_ }; =20 struct extent_state { -diff -urNp linux-2.6.32.49/fs/btrfs/extent-tree.c linux-2.6.32.49/fs/btr= fs/extent-tree.c ---- linux-2.6.32.49/fs/btrfs/extent-tree.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/fs/btrfs/extent-tree.c 2011-11-15 19:59:43.000000000= -0500 -@@ -7141,6 +7141,10 @@ static noinline int relocate_one_extent( - u64 group_start =3D group->key.objectid; - new_extents =3D kmalloc(sizeof(*new_extents), - GFP_NOFS); -+ if (!new_extents) { -+ ret =3D -ENOMEM; -+ goto out; -+ } - nr_extents =3D 1; - ret =3D get_new_locations(reloc_inode, - extent_key, -diff -urNp linux-2.6.32.49/fs/btrfs/free-space-cache.c linux-2.6.32.49/f= s/btrfs/free-space-cache.c ---- linux-2.6.32.49/fs/btrfs/free-space-cache.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/fs/btrfs/free-space-cache.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -1074,8 +1074,6 @@ u64 btrfs_alloc_from_cluster(struct btrf +diff --git a/fs/btrfs/free-space-cache.c b/fs/btrfs/free-space-cache.c +index cb2849f..3718fb4 100644 +--- a/fs/btrfs/free-space-cache.c ++++ b/fs/btrfs/free-space-cache.c +@@ -1074,8 +1074,6 @@ u64 btrfs_alloc_from_cluster(struct btrfs_block_gr= oup_cache *block_group, =20 while(1) { if (entry->bytes < bytes || entry->offset < min_start) { @@ -45060,10 +46964,11 @@ diff -urNp linux-2.6.32.49/fs/btrfs/free-space-= cache.c linux-2.6.32.49/fs/btrfs/ =20 if (entry->bitmap && entry->bytes > bytes + empty_size) { ret =3D btrfs_bitmap_cluster(block_group, entry, cluster, -diff -urNp linux-2.6.32.49/fs/btrfs/inode.c linux-2.6.32.49/fs/btrfs/ino= de.c ---- linux-2.6.32.49/fs/btrfs/inode.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/btrfs/inode.c 2011-11-15 19:59:43.000000000 -0500 -@@ -63,7 +63,7 @@ static const struct inode_operations btr +diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c +index e03a836..323837e 100644 +--- a/fs/btrfs/inode.c ++++ b/fs/btrfs/inode.c +@@ -63,7 +63,7 @@ static const struct inode_operations btrfs_file_inode_= operations; static const struct address_space_operations btrfs_aops; static const struct address_space_operations btrfs_symlink_aops; static const struct file_operations btrfs_dir_file_operations; @@ -45072,7 +46977,7 @@ diff -urNp linux-2.6.32.49/fs/btrfs/inode.c linux= -2.6.32.49/fs/btrfs/inode.c =20 static struct kmem_cache *btrfs_inode_cachep; struct kmem_cache *btrfs_trans_handle_cachep; -@@ -925,6 +925,7 @@ static int cow_file_range_async(struct i +@@ -925,6 +925,7 @@ static int cow_file_range_async(struct inode *inode,= struct page *locked_page, 1, 0, NULL, GFP_NOFS); while (start < end) { async_cow =3D kmalloc(sizeof(*async_cow), GFP_NOFS); @@ -45080,7 +46985,7 @@ diff -urNp linux-2.6.32.49/fs/btrfs/inode.c linux= -2.6.32.49/fs/btrfs/inode.c async_cow->inode =3D inode; async_cow->root =3D root; async_cow->locked_page =3D locked_page; -@@ -4591,6 +4592,8 @@ static noinline int uncompress_inline(st +@@ -4591,6 +4592,8 @@ static noinline int uncompress_inline(struct btrfs= _path *path, inline_size =3D btrfs_file_extent_inline_item_len(leaf, btrfs_item_nr(leaf, path->slots[0])); tmp =3D kmalloc(inline_size, GFP_NOFS); @@ -45098,7 +47003,7 @@ diff -urNp linux-2.6.32.49/fs/btrfs/inode.c linux= -2.6.32.49/fs/btrfs/inode.c struct dentry *dentry, struct kstat *stat) { struct inode *inode =3D dentry->d_inode; -@@ -5422,6 +5425,14 @@ static int btrfs_getattr(struct vfsmount +@@ -5422,6 +5425,14 @@ static int btrfs_getattr(struct vfsmount *mnt, return 0; } =20 @@ -45113,7 +47018,7 @@ diff -urNp linux-2.6.32.49/fs/btrfs/inode.c linux= -2.6.32.49/fs/btrfs/inode.c static int btrfs_rename(struct inode *old_dir, struct dentry *old_dentr= y, struct inode *new_dir, struct dentry *new_dentry) { -@@ -5972,7 +5983,7 @@ static const struct file_operations btrf +@@ -5972,7 +5983,7 @@ static const struct file_operations btrfs_dir_file= _operations =3D { .fsync =3D btrfs_sync_file, }; =20 @@ -45122,10 +47027,11 @@ diff -urNp linux-2.6.32.49/fs/btrfs/inode.c lin= ux-2.6.32.49/fs/btrfs/inode.c .fill_delalloc =3D run_delalloc_range, .submit_bio_hook =3D btrfs_submit_bio_hook, .merge_bio_hook =3D btrfs_merge_bio_hook, -diff -urNp linux-2.6.32.49/fs/btrfs/relocation.c linux-2.6.32.49/fs/btrf= s/relocation.c ---- linux-2.6.32.49/fs/btrfs/relocation.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/fs/btrfs/relocation.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -884,7 +884,7 @@ static int __update_reloc_root(struct bt +diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c +index ab7ab53..94e0781 100644 +--- a/fs/btrfs/relocation.c ++++ b/fs/btrfs/relocation.c +@@ -884,7 +884,7 @@ static int __update_reloc_root(struct btrfs_root *ro= ot, int del) } spin_unlock(&rc->reloc_root_tree.lock); =20 @@ -45134,10 +47040,11 @@ diff -urNp linux-2.6.32.49/fs/btrfs/relocation.= c linux-2.6.32.49/fs/btrfs/reloca =20 if (!del) { spin_lock(&rc->reloc_root_tree.lock); -diff -urNp linux-2.6.32.49/fs/btrfs/sysfs.c linux-2.6.32.49/fs/btrfs/sys= fs.c ---- linux-2.6.32.49/fs/btrfs/sysfs.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/btrfs/sysfs.c 2011-11-15 19:59:43.000000000 -0500 -@@ -164,12 +164,12 @@ static void btrfs_root_release(struct ko +diff --git a/fs/btrfs/sysfs.c b/fs/btrfs/sysfs.c +index a240b6f..4ce16ef 100644 +--- a/fs/btrfs/sysfs.c ++++ b/fs/btrfs/sysfs.c +@@ -164,12 +164,12 @@ static void btrfs_root_release(struct kobject *kob= j) complete(&root->kobj_unregister); } =20 @@ -45152,9 +47059,10 @@ diff -urNp linux-2.6.32.49/fs/btrfs/sysfs.c linu= x-2.6.32.49/fs/btrfs/sysfs.c .show =3D btrfs_root_attr_show, .store =3D btrfs_root_attr_store, }; -diff -urNp linux-2.6.32.49/fs/buffer.c linux-2.6.32.49/fs/buffer.c ---- linux-2.6.32.49/fs/buffer.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/buffer.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/buffer.c b/fs/buffer.c +index 6fa5302..395d9f6 100644 +--- a/fs/buffer.c ++++ b/fs/buffer.c @@ -25,6 +25,7 @@ #include #include @@ -45163,10 +47071,11 @@ diff -urNp linux-2.6.32.49/fs/buffer.c linux-2.= 6.32.49/fs/buffer.c #include #include #include -diff -urNp linux-2.6.32.49/fs/cachefiles/bind.c linux-2.6.32.49/fs/cache= files/bind.c ---- linux-2.6.32.49/fs/cachefiles/bind.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/cachefiles/bind.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -39,13 +39,11 @@ int cachefiles_daemon_bind(struct cachef +diff --git a/fs/cachefiles/bind.c b/fs/cachefiles/bind.c +index 3797e00..ce776f6 100644 +--- a/fs/cachefiles/bind.c ++++ b/fs/cachefiles/bind.c +@@ -39,13 +39,11 @@ int cachefiles_daemon_bind(struct cachefiles_cache *= cache, char *args) args); =20 /* start by checking things over */ @@ -45182,10 +47091,11 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/bind.c= linux-2.6.32.49/fs/cachefiles/bi cache->bcull_percent < cache->brun_percent && cache->brun_percent < 100); =20 -diff -urNp linux-2.6.32.49/fs/cachefiles/daemon.c linux-2.6.32.49/fs/cac= hefiles/daemon.c ---- linux-2.6.32.49/fs/cachefiles/daemon.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/fs/cachefiles/daemon.c 2011-11-15 19:59:43.000000000= -0500 -@@ -220,7 +220,7 @@ static ssize_t cachefiles_daemon_write(s +diff --git a/fs/cachefiles/daemon.c b/fs/cachefiles/daemon.c +index 4618516..bb30d01 100644 +--- a/fs/cachefiles/daemon.c ++++ b/fs/cachefiles/daemon.c +@@ -220,7 +220,7 @@ static ssize_t cachefiles_daemon_write(struct file *= file, if (test_bit(CACHEFILES_DEAD, &cache->flags)) return -EIO; =20 @@ -45194,7 +47104,7 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/daemon.c= linux-2.6.32.49/fs/cachefiles/ return -EOPNOTSUPP; =20 /* drag the command string into the kernel so we can parse it */ -@@ -385,7 +385,7 @@ static int cachefiles_daemon_fstop(struc +@@ -385,7 +385,7 @@ static int cachefiles_daemon_fstop(struct cachefiles= _cache *cache, char *args) if (args[0] !=3D '%' || args[1] !=3D '\0') return -EINVAL; =20 @@ -45203,7 +47113,7 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/daemon.c= linux-2.6.32.49/fs/cachefiles/ return cachefiles_daemon_range_error(cache, args); =20 cache->fstop_percent =3D fstop; -@@ -457,7 +457,7 @@ static int cachefiles_daemon_bstop(struc +@@ -457,7 +457,7 @@ static int cachefiles_daemon_bstop(struct cachefiles= _cache *cache, char *args) if (args[0] !=3D '%' || args[1] !=3D '\0') return -EINVAL; =20 @@ -45212,9 +47122,10 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/daemon.= c linux-2.6.32.49/fs/cachefiles/ return cachefiles_daemon_range_error(cache, args); =20 cache->bstop_percent =3D bstop; -diff -urNp linux-2.6.32.49/fs/cachefiles/internal.h linux-2.6.32.49/fs/c= achefiles/internal.h ---- linux-2.6.32.49/fs/cachefiles/internal.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/fs/cachefiles/internal.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/fs/cachefiles/internal.h b/fs/cachefiles/internal.h +index f7c255f..fcd61de 100644 +--- a/fs/cachefiles/internal.h ++++ b/fs/cachefiles/internal.h @@ -56,7 +56,7 @@ struct cachefiles_cache { wait_queue_head_t daemon_pollwq; /* poll waitqueue for daemon */ struct rb_root active_nodes; /* active nodes (can't be culled) */ @@ -45224,7 +47135,7 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/internal= .h linux-2.6.32.49/fs/cachefile unsigned frun_percent; /* when to stop culling (% files) */ unsigned fcull_percent; /* when to start culling (% files) */ unsigned fstop_percent; /* when to stop allocating (% files) */ -@@ -168,19 +168,19 @@ extern int cachefiles_check_in_use(struc +@@ -168,19 +168,19 @@ extern int cachefiles_check_in_use(struct cachefil= es_cache *cache, * proc.c */ #ifdef CONFIG_CACHEFILES_HISTOGRAM @@ -45249,9 +47160,10 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/interna= l.h linux-2.6.32.49/fs/cachefile } =20 #else -diff -urNp linux-2.6.32.49/fs/cachefiles/namei.c linux-2.6.32.49/fs/cach= efiles/namei.c ---- linux-2.6.32.49/fs/cachefiles/namei.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/fs/cachefiles/namei.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/fs/cachefiles/namei.c b/fs/cachefiles/namei.c +index 14ac480..a62766c 100644 +--- a/fs/cachefiles/namei.c ++++ b/fs/cachefiles/namei.c @@ -250,7 +250,7 @@ try_again: /* first step is to make up a grave dentry in the graveyard */ sprintf(nbuffer, "%08x%08x", @@ -45261,9 +47173,10 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/namei.c= linux-2.6.32.49/fs/cachefiles/n =20 /* do the multiway lock magic */ trap =3D lock_rename(cache->graveyard, dir); -diff -urNp linux-2.6.32.49/fs/cachefiles/proc.c linux-2.6.32.49/fs/cache= files/proc.c ---- linux-2.6.32.49/fs/cachefiles/proc.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/cachefiles/proc.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/fs/cachefiles/proc.c b/fs/cachefiles/proc.c +index eccd339..4c1d995 100644 +--- a/fs/cachefiles/proc.c ++++ b/fs/cachefiles/proc.c @@ -14,9 +14,9 @@ #include #include "internal.h" @@ -45277,7 +47190,7 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/proc.c l= inux-2.6.32.49/fs/cachefiles/pr =20 /* * display the latency histogram -@@ -35,9 +35,9 @@ static int cachefiles_histogram_show(str +@@ -35,9 +35,9 @@ static int cachefiles_histogram_show(struct seq_file *= m, void *v) return 0; default: index =3D (unsigned long) v - 3; @@ -45290,10 +47203,11 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/proc.c= linux-2.6.32.49/fs/cachefiles/pr if (x =3D=3D 0 && y =3D=3D 0 && z =3D=3D 0) return 0; =20 -diff -urNp linux-2.6.32.49/fs/cachefiles/rdwr.c linux-2.6.32.49/fs/cache= files/rdwr.c ---- linux-2.6.32.49/fs/cachefiles/rdwr.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/cachefiles/rdwr.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -946,7 +946,7 @@ int cachefiles_write_page(struct fscache +diff --git a/fs/cachefiles/rdwr.c b/fs/cachefiles/rdwr.c +index a6c8c6f..5cf8517 100644 +--- a/fs/cachefiles/rdwr.c ++++ b/fs/cachefiles/rdwr.c +@@ -946,7 +946,7 @@ int cachefiles_write_page(struct fscache_storage *op= , struct page *page) old_fs =3D get_fs(); set_fs(KERNEL_DS); ret =3D file->f_op->write( @@ -45302,10 +47216,11 @@ diff -urNp linux-2.6.32.49/fs/cachefiles/rdwr.c= linux-2.6.32.49/fs/cachefiles/rd set_fs(old_fs); kunmap(page); if (ret !=3D len) -diff -urNp linux-2.6.32.49/fs/cifs/cifs_debug.c linux-2.6.32.49/fs/cifs/= cifs_debug.c ---- linux-2.6.32.49/fs/cifs/cifs_debug.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/cifs/cifs_debug.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -256,25 +256,25 @@ static ssize_t cifs_stats_proc_write(str +diff --git a/fs/cifs/cifs_debug.c b/fs/cifs/cifs_debug.c +index 42cec2a..2aba466 100644 +--- a/fs/cifs/cifs_debug.c ++++ b/fs/cifs/cifs_debug.c +@@ -256,25 +256,25 @@ static ssize_t cifs_stats_proc_write(struct file *= file, tcon =3D list_entry(tmp3, struct cifsTconInfo, tcon_list); @@ -45350,7 +47265,7 @@ diff -urNp linux-2.6.32.49/fs/cifs/cifs_debug.c l= inux-2.6.32.49/fs/cifs/cifs_deb } } } -@@ -334,41 +334,41 @@ static int cifs_stats_proc_show(struct s +@@ -334,41 +334,41 @@ static int cifs_stats_proc_show(struct seq_file *m= , void *v) if (tcon->need_reconnect) seq_puts(m, "\tDISCONNECTED "); seq_printf(m, "\nSMBs: %d Oplock Breaks: %d", @@ -45412,9 +47327,10 @@ diff -urNp linux-2.6.32.49/fs/cifs/cifs_debug.c = linux-2.6.32.49/fs/cifs/cifs_deb } } } -diff -urNp linux-2.6.32.49/fs/cifs/cifsfs.c linux-2.6.32.49/fs/cifs/cifs= fs.c ---- linux-2.6.32.49/fs/cifs/cifsfs.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/cifs/cifsfs.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c +index 1445407..68cb0dc 100644 +--- a/fs/cifs/cifsfs.c ++++ b/fs/cifs/cifsfs.c @@ -869,7 +869,7 @@ cifs_init_request_bufs(void) cifs_req_cachep =3D kmem_cache_create("cifs_request", CIFSMaxBufSize + @@ -45444,9 +47360,10 @@ diff -urNp linux-2.6.32.49/fs/cifs/cifsfs.c linu= x-2.6.32.49/fs/cifs/cifsfs.c #endif /* CONFIG_CIFS_STATS2 */ =20 atomic_set(&midCount, 0); -diff -urNp linux-2.6.32.49/fs/cifs/cifsglob.h linux-2.6.32.49/fs/cifs/ci= fsglob.h ---- linux-2.6.32.49/fs/cifs/cifsglob.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/cifs/cifsglob.h 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h +index e29581e..1c22bab 100644 +--- a/fs/cifs/cifsglob.h ++++ b/fs/cifs/cifsglob.h @@ -252,28 +252,28 @@ struct cifsTconInfo { __u16 Flags; /* optional support bits */ enum statusEnum tidStatus; @@ -45498,7 +47415,7 @@ diff -urNp linux-2.6.32.49/fs/cifs/cifsglob.h lin= ux-2.6.32.49/fs/cifs/cifsglob.h #ifdef CONFIG_CIFS_STATS2 unsigned long long time_writes; unsigned long long time_reads; -@@ -414,7 +414,7 @@ static inline char CIFS_DIR_SEP(const st +@@ -414,7 +414,7 @@ static inline char CIFS_DIR_SEP(const struct cifs_sb= _info *cifs_sb) } =20 #ifdef CONFIG_CIFS_STATS @@ -45507,7 +47424,7 @@ diff -urNp linux-2.6.32.49/fs/cifs/cifsglob.h lin= ux-2.6.32.49/fs/cifs/cifsglob.h =20 static inline void cifs_stats_bytes_written(struct cifsTconInfo *tcon, unsigned int bytes) -@@ -701,8 +701,8 @@ GLOBAL_EXTERN atomic_t tconInfoReconnect +@@ -701,8 +701,8 @@ GLOBAL_EXTERN atomic_t tconInfoReconnectCount; /* Various Debug counters */ GLOBAL_EXTERN atomic_t bufAllocCount; /* current number allocated *= / #ifdef CONFIG_CIFS_STATS2 @@ -45518,10 +47435,11 @@ diff -urNp linux-2.6.32.49/fs/cifs/cifsglob.h l= inux-2.6.32.49/fs/cifs/cifsglob.h #endif GLOBAL_EXTERN atomic_t smBufAllocCount; GLOBAL_EXTERN atomic_t midCount; -diff -urNp linux-2.6.32.49/fs/cifs/link.c linux-2.6.32.49/fs/cifs/link.c ---- linux-2.6.32.49/fs/cifs/link.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/cifs/link.c 2011-11-15 19:59:43.000000000 -0500 -@@ -215,7 +215,7 @@ cifs_symlink(struct inode *inode, struct +diff --git a/fs/cifs/link.c b/fs/cifs/link.c +index fc1e048..28b3441 100644 +--- a/fs/cifs/link.c ++++ b/fs/cifs/link.c +@@ -215,7 +215,7 @@ cifs_symlink(struct inode *inode, struct dentry *dir= entry, const char *symname) =20 void cifs_put_link(struct dentry *direntry, struct nameidata *nd, void = *cookie) { @@ -45530,9 +47448,10 @@ diff -urNp linux-2.6.32.49/fs/cifs/link.c linux-= 2.6.32.49/fs/cifs/link.c if (!IS_ERR(p)) kfree(p); } -diff -urNp linux-2.6.32.49/fs/cifs/misc.c linux-2.6.32.49/fs/cifs/misc.c ---- linux-2.6.32.49/fs/cifs/misc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/cifs/misc.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/cifs/misc.c b/fs/cifs/misc.c +index d27d4ec..8d0a444 100644 +--- a/fs/cifs/misc.c ++++ b/fs/cifs/misc.c @@ -155,7 +155,7 @@ cifs_buf_get(void) memset(ret_buf, 0, sizeof(struct smb_hdr) + 3); atomic_inc(&bufAllocCount); @@ -45551,9 +47470,10 @@ diff -urNp linux-2.6.32.49/fs/cifs/misc.c linux-= 2.6.32.49/fs/cifs/misc.c #endif /* CONFIG_CIFS_STATS2 */ =20 } -diff -urNp linux-2.6.32.49/fs/coda/cache.c linux-2.6.32.49/fs/coda/cache= .c ---- linux-2.6.32.49/fs/coda/cache.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/coda/cache.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/coda/cache.c b/fs/coda/cache.c +index a5bf577..6d19845 100644 +--- a/fs/coda/cache.c ++++ b/fs/coda/cache.c @@ -24,14 +24,14 @@ #include #include @@ -45571,7 +47491,7 @@ diff -urNp linux-2.6.32.49/fs/coda/cache.c linux-= 2.6.32.49/fs/coda/cache.c if (cii->c_uid !=3D current_fsuid()) { cii->c_uid =3D current_fsuid(); cii->c_cached_perm =3D mask; -@@ -43,13 +43,13 @@ void coda_cache_enter(struct inode *inod +@@ -43,13 +43,13 @@ void coda_cache_enter(struct inode *inode, int mask) void coda_cache_clear_inode(struct inode *inode) { struct coda_inode_info *cii =3D ITOC(inode); @@ -45587,7 +47507,7 @@ diff -urNp linux-2.6.32.49/fs/coda/cache.c linux-= 2.6.32.49/fs/coda/cache.c } =20 =20 -@@ -61,7 +61,7 @@ int coda_cache_check(struct inode *inode +@@ -61,7 +61,7 @@ int coda_cache_check(struct inode *inode, int mask) =09 hit =3D (mask & cii->c_cached_perm) =3D=3D mask && cii->c_uid =3D=3D current_fsuid() && @@ -45596,26 +47516,11 @@ diff -urNp linux-2.6.32.49/fs/coda/cache.c linu= x-2.6.32.49/fs/coda/cache.c =20 return hit; } -diff -urNp linux-2.6.32.49/fs/compat_binfmt_elf.c linux-2.6.32.49/fs/com= pat_binfmt_elf.c ---- linux-2.6.32.49/fs/compat_binfmt_elf.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/fs/compat_binfmt_elf.c 2011-11-15 19:59:43.000000000= -0500 -@@ -29,10 +29,12 @@ - #undef elfhdr - #undef elf_phdr - #undef elf_note -+#undef elf_dyn - #undef elf_addr_t - #define elfhdr elf32_hdr - #define elf_phdr elf32_phdr - #define elf_note elf32_note -+#define elf_dyn Elf32_Dyn - #define elf_addr_t Elf32_Addr -=20 - /* -diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.32.49/fs/compat.c ---- linux-2.6.32.49/fs/compat.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/compat.c 2011-11-15 19:59:43.000000000 -0500 -@@ -133,8 +133,8 @@ asmlinkage long compat_sys_utimes(char _ +diff --git a/fs/compat.c b/fs/compat.c +index d1e2411..27064e4 100644 +--- a/fs/compat.c ++++ b/fs/compat.c +@@ -133,8 +133,8 @@ asmlinkage long compat_sys_utimes(char __user *filen= ame, struct compat_timeval _ static int cp_compat_stat(struct kstat *stat, struct compat_stat __user= *ubuf) { compat_ino_t ino =3D stat->ino; @@ -45626,7 +47531,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c int err; =20 SET_UID(uid, stat->uid); -@@ -533,7 +533,7 @@ compat_sys_io_setup(unsigned nr_reqs, u3 +@@ -533,7 +533,7 @@ compat_sys_io_setup(unsigned nr_reqs, u32 __user *ct= x32p) =20 set_fs(KERNEL_DS); /* The __user pointer cast is valid because of the set_fs() */ @@ -45643,7 +47548,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c int result; }; =20 -@@ -847,6 +848,10 @@ static int compat_fillonedir(void *__buf +@@ -847,6 +848,10 @@ static int compat_fillonedir(void *__buf, const cha= r *name, int namlen, buf->result =3D -EOVERFLOW; return -EOVERFLOW; } @@ -45654,7 +47559,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c buf->result++; dirent =3D buf->dirent; if (!access_ok(VERIFY_WRITE, dirent, -@@ -879,6 +884,7 @@ asmlinkage long compat_sys_old_readdir(u +@@ -879,6 +884,7 @@ asmlinkage long compat_sys_old_readdir(unsigned int = fd, =20 buf.result =3D 0; buf.dirent =3D dirent; @@ -45670,7 +47575,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c int count; int error; }; -@@ -919,6 +926,10 @@ static int compat_filldir(void *__buf, c +@@ -919,6 +926,10 @@ static int compat_filldir(void *__buf, const char *= name, int namlen, buf->error =3D -EOVERFLOW; return -EOVERFLOW; } @@ -45681,7 +47586,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c dirent =3D buf->previous; if (dirent) { if (__put_user(offset, &dirent->d_off)) -@@ -966,6 +977,7 @@ asmlinkage long compat_sys_getdents(unsi +@@ -966,6 +977,7 @@ asmlinkage long compat_sys_getdents(unsigned int fd, buf.previous =3D NULL; buf.count =3D count; buf.error =3D 0; @@ -45697,7 +47602,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c int count; int error; }; -@@ -1003,6 +1016,10 @@ static int compat_filldir64(void * __buf +@@ -1003,6 +1016,10 @@ static int compat_filldir64(void * __buf, const c= har * name, int namlen, loff_t buf->error =3D -EINVAL; /* only used if we fail.. */ if (reclen > buf->count) return -EINVAL; @@ -45708,7 +47613,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c dirent =3D buf->previous; =20 if (dirent) { -@@ -1054,13 +1071,14 @@ asmlinkage long compat_sys_getdents64(un +@@ -1054,13 +1071,14 @@ asmlinkage long compat_sys_getdents64(unsigned i= nt fd, buf.previous =3D NULL; buf.count =3D count; buf.error =3D 0; @@ -45724,7 +47629,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c if (__put_user_unaligned(d_off, &lastdirent->d_off)) error =3D -EFAULT; else -@@ -1098,7 +1116,7 @@ static ssize_t compat_do_readv_writev(in +@@ -1098,7 +1116,7 @@ static ssize_t compat_do_readv_writev(int type, st= ruct file *file, * verify all the pointers */ ret =3D -EINVAL; @@ -45842,7 +47747,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c out: if (bprm->mm) { acct_arg_size(bprm, 0); -@@ -1711,6 +1801,8 @@ int compat_core_sys_select(int n, compat +@@ -1711,6 +1801,8 @@ int compat_core_sys_select(int n, compat_ulong_t _= _user *inp, struct fdtable *fdt; long stack_fds[SELECT_STACK_ALLOC/sizeof(long)]; =20 @@ -45851,7 +47756,7 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.6.= 32.49/fs/compat.c if (n < 0) goto out_nofds; =20 -@@ -2151,7 +2243,7 @@ asmlinkage long compat_sys_nfsservctl(in +@@ -2151,7 +2243,7 @@ asmlinkage long compat_sys_nfsservctl(int cmd, oldfs =3D get_fs(); set_fs(KERNEL_DS); /* The __user pointer casts are valid because of the set_fs() */ @@ -45860,10 +47765,28 @@ diff -urNp linux-2.6.32.49/fs/compat.c linux-2.= 6.32.49/fs/compat.c set_fs(oldfs); =20 if (err) -diff -urNp linux-2.6.32.49/fs/compat_ioctl.c linux-2.6.32.49/fs/compat_i= octl.c ---- linux-2.6.32.49/fs/compat_ioctl.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/compat_ioctl.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -234,6 +234,8 @@ static int do_video_set_spu_palette(unsi +diff --git a/fs/compat_binfmt_elf.c b/fs/compat_binfmt_elf.c +index 0adced2..bbb1b0d 100644 +--- a/fs/compat_binfmt_elf.c ++++ b/fs/compat_binfmt_elf.c +@@ -29,10 +29,12 @@ + #undef elfhdr + #undef elf_phdr + #undef elf_note ++#undef elf_dyn + #undef elf_addr_t + #define elfhdr elf32_hdr + #define elf_phdr elf32_phdr + #define elf_note elf32_note ++#define elf_dyn Elf32_Dyn + #define elf_addr_t Elf32_Addr +=20 + /* +diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c +index d84e705..d8c364c 100644 +--- a/fs/compat_ioctl.c ++++ b/fs/compat_ioctl.c +@@ -234,6 +234,8 @@ static int do_video_set_spu_palette(unsigned int fd,= unsigned int cmd, unsigned up =3D (struct compat_video_spu_palette __user *) arg; err =3D get_user(palp, &up->palette); err |=3D get_user(length, &up->length); @@ -45872,7 +47795,7 @@ diff -urNp linux-2.6.32.49/fs/compat_ioctl.c linu= x-2.6.32.49/fs/compat_ioctl.c =20 up_native =3D compat_alloc_user_space(sizeof(struct video_spu_palette)= ); err =3D put_user(compat_ptr(palp), &up_native->palette); -@@ -1513,7 +1515,7 @@ static int serial_struct_ioctl(unsigned=20 +@@ -1513,7 +1515,7 @@ static int serial_struct_ioctl(unsigned fd, unsign= ed cmd, unsigned long arg) return -EFAULT; if (__get_user(udata, &ss32->iomem_base)) return -EFAULT; @@ -45881,7 +47804,7 @@ diff -urNp linux-2.6.32.49/fs/compat_ioctl.c linu= x-2.6.32.49/fs/compat_ioctl.c if (__get_user(ss.iomem_reg_shift, &ss32->iomem_reg_shi= ft) || __get_user(ss.port_high, &ss32->port_high)) return -EFAULT; -@@ -1809,7 +1811,7 @@ static int compat_ioctl_preallocate(stru +@@ -1809,7 +1811,7 @@ static int compat_ioctl_preallocate(struct file *f= ile, unsigned long arg) copy_in_user(&p->l_len, &p32->l_len, sizeof(s64)) || copy_in_user(&p->l_sysid, &p32->l_sysid, sizeof(s32)) || copy_in_user(&p->l_pid, &p32->l_pid, sizeof(u32)) || @@ -45890,10 +47813,11 @@ diff -urNp linux-2.6.32.49/fs/compat_ioctl.c li= nux-2.6.32.49/fs/compat_ioctl.c return -EFAULT; =20 return ioctl_preallocate(file, p); -diff -urNp linux-2.6.32.49/fs/configfs/dir.c linux-2.6.32.49/fs/configfs= /dir.c ---- linux-2.6.32.49/fs/configfs/dir.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/configfs/dir.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -1572,7 +1572,8 @@ static int configfs_readdir(struct file=20 +diff --git a/fs/configfs/dir.c b/fs/configfs/dir.c +index 8e48b52..f01ed91 100644 +--- a/fs/configfs/dir.c ++++ b/fs/configfs/dir.c +@@ -1572,7 +1572,8 @@ static int configfs_readdir(struct file * filp, vo= id * dirent, filldir_t filldir } for (p=3Dq->next; p!=3D &parent_sd->s_children; p=3Dp->next) { struct configfs_dirent *next; @@ -45903,7 +47827,7 @@ diff -urNp linux-2.6.32.49/fs/configfs/dir.c linu= x-2.6.32.49/fs/configfs/dir.c int len; =20 next =3D list_entry(p, struct configfs_dirent, -@@ -1581,7 +1582,12 @@ static int configfs_readdir(struct file=20 +@@ -1581,7 +1582,12 @@ static int configfs_readdir(struct file * filp, v= oid * dirent, filldir_t filldir continue; =20 name =3D configfs_get_name(next); @@ -45917,9 +47841,10 @@ diff -urNp linux-2.6.32.49/fs/configfs/dir.c lin= ux-2.6.32.49/fs/configfs/dir.c if (next->s_dentry) ino =3D next->s_dentry->d_inode->i_ino; else -diff -urNp linux-2.6.32.49/fs/dcache.c linux-2.6.32.49/fs/dcache.c ---- linux-2.6.32.49/fs/dcache.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/dcache.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/dcache.c b/fs/dcache.c +index 44c0aea..2529092 100644 +--- a/fs/dcache.c ++++ b/fs/dcache.c @@ -45,8 +45,6 @@ EXPORT_SYMBOL(dcache_lock); =20 static struct kmem_cache *dentry_cache __read_mostly; @@ -45929,7 +47854,7 @@ diff -urNp linux-2.6.32.49/fs/dcache.c linux-2.6.= 32.49/fs/dcache.c /* * This is the single most critical data structure when it comes * to the dcache: the hashtable for lookups. Somebody should try -@@ -2319,7 +2317,7 @@ void __init vfs_caches_init(unsigned lon +@@ -2319,7 +2317,7 @@ void __init vfs_caches_init(unsigned long mempages= ) mempages -=3D reserve; =20 names_cachep =3D kmem_cache_create("names_cache", PATH_MAX, 0, @@ -45938,10 +47863,11 @@ diff -urNp linux-2.6.32.49/fs/dcache.c linux-2.= 6.32.49/fs/dcache.c =20 dcache_init(); inode_init(); -diff -urNp linux-2.6.32.49/fs/dlm/lockspace.c linux-2.6.32.49/fs/dlm/loc= kspace.c ---- linux-2.6.32.49/fs/dlm/lockspace.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/dlm/lockspace.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -148,7 +148,7 @@ static void lockspace_kobj_release(struc +diff --git a/fs/dlm/lockspace.c b/fs/dlm/lockspace.c +index c010ecf..a8d8c59 100644 +--- a/fs/dlm/lockspace.c ++++ b/fs/dlm/lockspace.c +@@ -148,7 +148,7 @@ static void lockspace_kobj_release(struct kobject *k= ) kfree(ls); } =20 @@ -45950,10 +47876,11 @@ diff -urNp linux-2.6.32.49/fs/dlm/lockspace.c l= inux-2.6.32.49/fs/dlm/lockspace.c .show =3D dlm_attr_show, .store =3D dlm_attr_store, }; -diff -urNp linux-2.6.32.49/fs/ecryptfs/inode.c linux-2.6.32.49/fs/ecrypt= fs/inode.c ---- linux-2.6.32.49/fs/ecryptfs/inode.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/ecryptfs/inode.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -660,7 +660,7 @@ static int ecryptfs_readlink_lower(struc +diff --git a/fs/ecryptfs/inode.c b/fs/ecryptfs/inode.c +index 88ba4d4..073f003 100644 +--- a/fs/ecryptfs/inode.c ++++ b/fs/ecryptfs/inode.c +@@ -660,7 +660,7 @@ static int ecryptfs_readlink_lower(struct dentry *de= ntry, char **buf, old_fs =3D get_fs(); set_fs(get_ds()); rc =3D lower_dentry->d_inode->i_op->readlink(lower_dentry, @@ -45962,7 +47889,7 @@ diff -urNp linux-2.6.32.49/fs/ecryptfs/inode.c li= nux-2.6.32.49/fs/ecryptfs/inode lower_bufsiz); set_fs(old_fs); if (rc < 0) -@@ -706,7 +706,7 @@ static void *ecryptfs_follow_link(struct +@@ -706,7 +706,7 @@ static void *ecryptfs_follow_link(struct dentry *den= try, struct nameidata *nd) } old_fs =3D get_fs(); set_fs(get_ds()); @@ -45971,9 +47898,10 @@ diff -urNp linux-2.6.32.49/fs/ecryptfs/inode.c l= inux-2.6.32.49/fs/ecryptfs/inode set_fs(old_fs); if (rc < 0) goto out_free; -diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32.49/fs/exec.c ---- linux-2.6.32.49/fs/exec.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/exec.c 2011-11-18 19:28:23.000000000 -0500 +diff --git a/fs/exec.c b/fs/exec.c +index 86fafc6..b307bfa 100644 +--- a/fs/exec.c ++++ b/fs/exec.c @@ -56,12 +56,24 @@ #include #include @@ -45999,7 +47927,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c int core_uses_pid; char core_pattern[CORENAME_MAX_SIZE] =3D "core"; unsigned int core_pipe_limit; -@@ -178,18 +190,10 @@ struct page *get_arg_page(struct linux_b +@@ -178,18 +190,10 @@ struct page *get_arg_page(struct linux_binprm *bpr= m, unsigned long pos, int write) { struct page *page; @@ -46021,7 +47949,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c return NULL; =20 if (write) { -@@ -263,6 +267,11 @@ static int __bprm_mm_init(struct linux_b +@@ -263,6 +267,11 @@ static int __bprm_mm_init(struct linux_binprm *bprm= ) vma->vm_end =3D STACK_TOP_MAX; vma->vm_start =3D vma->vm_end - PAGE_SIZE; vma->vm_flags =3D VM_STACK_FLAGS; @@ -46033,7 +47961,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c vma->vm_page_prot =3D vm_get_page_prot(vma->vm_flags); =20 err =3D security_file_mmap(NULL, 0, 0, 0, vma->vm_start, 1); -@@ -276,6 +285,12 @@ static int __bprm_mm_init(struct linux_b +@@ -276,6 +285,12 @@ static int __bprm_mm_init(struct linux_binprm *bprm= ) mm->stack_vm =3D mm->total_vm =3D 1; up_write(&mm->mmap_sem); bprm->p =3D vma->vm_end - sizeof(void *); @@ -46046,7 +47974,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c return 0; err: up_write(&mm->mmap_sem); -@@ -510,7 +525,7 @@ int copy_strings_kernel(int argc,char ** +@@ -510,7 +525,7 @@ int copy_strings_kernel(int argc,char ** argv, struc= t linux_binprm *bprm) int r; mm_segment_t oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -46055,7 +47983,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c set_fs(oldfs); return r; } -@@ -540,7 +555,8 @@ static int shift_arg_pages(struct vm_are +@@ -540,7 +555,8 @@ static int shift_arg_pages(struct vm_area_struct *vm= a, unsigned long shift) unsigned long new_end =3D old_end - shift; struct mmu_gather *tlb; =20 @@ -46065,7 +47993,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c =20 /* * ensure there are no vmas between where we want to go -@@ -549,6 +565,10 @@ static int shift_arg_pages(struct vm_are +@@ -549,6 +565,10 @@ static int shift_arg_pages(struct vm_area_struct *v= ma, unsigned long shift) if (vma !=3D find_vma(mm, new_start)) return -EFAULT; =20 @@ -46076,7 +48004,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c /* * cover the whole range: [new_start, old_end) */ -@@ -630,10 +650,6 @@ int setup_arg_pages(struct linux_binprm=20 +@@ -630,10 +650,6 @@ int setup_arg_pages(struct linux_binprm *bprm, stack_top =3D arch_align_stack(stack_top); stack_top =3D PAGE_ALIGN(stack_top); =20 @@ -46087,7 +48015,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c stack_shift =3D vma->vm_end - stack_top; =20 bprm->p -=3D stack_shift; -@@ -645,6 +661,14 @@ int setup_arg_pages(struct linux_binprm=20 +@@ -645,6 +661,14 @@ int setup_arg_pages(struct linux_binprm *bprm, bprm->exec -=3D stack_shift; =20 down_write(&mm->mmap_sem); @@ -46102,7 +48030,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c vm_flags =3D VM_STACK_FLAGS; =20 /* -@@ -658,19 +682,24 @@ int setup_arg_pages(struct linux_binprm=20 +@@ -658,19 +682,24 @@ int setup_arg_pages(struct linux_binprm *bprm, vm_flags &=3D ~VM_EXEC; vm_flags |=3D mm->def_flags; =20 @@ -46134,7 +48062,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c stack_expand =3D EXTRA_STACK_VM_PAGES * PAGE_SIZE; stack_size =3D vma->vm_end - vma->vm_start; /* -@@ -744,7 +773,7 @@ int kernel_read(struct file *file, loff_ +@@ -744,7 +773,7 @@ int kernel_read(struct file *file, loff_t offset, old_fs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -46143,7 +48071,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c set_fs(old_fs); return result; } -@@ -1152,7 +1181,7 @@ int check_unsafe_exec(struct linux_binpr +@@ -1152,7 +1181,7 @@ int check_unsafe_exec(struct linux_binprm *bprm) } rcu_read_unlock(); =20 @@ -46484,7 +48412,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c static int zap_process(struct task_struct *start) { struct task_struct *t; -@@ -1793,17 +2109,17 @@ static void wait_for_dump_helpers(struct +@@ -1793,17 +2109,17 @@ static void wait_for_dump_helpers(struct file *f= ile) pipe =3D file->f_path.dentry->d_inode->i_pipe; =20 pipe_lock(pipe); @@ -46507,7 +48435,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c pipe_unlock(pipe); =20 } -@@ -1826,10 +2142,13 @@ void do_coredump(long signr, int exit_co +@@ -1826,10 +2142,13 @@ void do_coredump(long signr, int exit_code, stru= ct pt_regs *regs) char **helper_argv =3D NULL; int helper_argc =3D 0; int dump_count =3D 0; @@ -46522,7 +48450,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c binfmt =3D mm->binfmt; if (!binfmt || !binfmt->core_dump) goto fail; -@@ -1874,6 +2193,8 @@ void do_coredump(long signr, int exit_co +@@ -1874,6 +2193,8 @@ void do_coredump(long signr, int exit_code, struct= pt_regs *regs) */ clear_thread_flag(TIF_SIGPENDING); =20 @@ -46531,7 +48459,7 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.32= .49/fs/exec.c /* * lock_kernel() because format_corename() is controlled by sysctl, wh= ich * uses lock_kernel() -@@ -1908,7 +2229,7 @@ void do_coredump(long signr, int exit_co +@@ -1908,7 +2229,7 @@ void do_coredump(long signr, int exit_code, struct= pt_regs *regs) goto fail_unlock; } =20 @@ -46549,10 +48477,11 @@ diff -urNp linux-2.6.32.49/fs/exec.c linux-2.6.= 32.49/fs/exec.c fail_unlock: if (helper_argv) argv_free(helper_argv); -diff -urNp linux-2.6.32.49/fs/ext2/balloc.c linux-2.6.32.49/fs/ext2/ball= oc.c ---- linux-2.6.32.49/fs/ext2/balloc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ext2/balloc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1192,7 +1192,7 @@ static int ext2_has_free_blocks(struct e +diff --git a/fs/ext2/balloc.c b/fs/ext2/balloc.c +index 7f8d2e5..a1abdbb 100644 +--- a/fs/ext2/balloc.c ++++ b/fs/ext2/balloc.c +@@ -1192,7 +1192,7 @@ static int ext2_has_free_blocks(struct ext2_sb_inf= o *sbi) =20 free_blocks =3D percpu_counter_read_positive(&sbi->s_freeblocks_counte= r); root_blocks =3D le32_to_cpu(sbi->s_es->s_r_blocks_count); @@ -46561,10 +48490,11 @@ diff -urNp linux-2.6.32.49/fs/ext2/balloc.c lin= ux-2.6.32.49/fs/ext2/balloc.c sbi->s_resuid !=3D current_fsuid() && (sbi->s_resgid =3D=3D 0 || !in_group_p (sbi->s_resgid))) { return 0; -diff -urNp linux-2.6.32.49/fs/ext3/balloc.c linux-2.6.32.49/fs/ext3/ball= oc.c ---- linux-2.6.32.49/fs/ext3/balloc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ext3/balloc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1421,7 +1421,7 @@ static int ext3_has_free_blocks(struct e +diff --git a/fs/ext3/balloc.c b/fs/ext3/balloc.c +index 27967f9..9f2a5fb 100644 +--- a/fs/ext3/balloc.c ++++ b/fs/ext3/balloc.c +@@ -1421,7 +1421,7 @@ static int ext3_has_free_blocks(struct ext3_sb_inf= o *sbi) =20 free_blocks =3D percpu_counter_read_positive(&sbi->s_freeblocks_counte= r); root_blocks =3D le32_to_cpu(sbi->s_es->s_r_blocks_count); @@ -46573,10 +48503,11 @@ diff -urNp linux-2.6.32.49/fs/ext3/balloc.c lin= ux-2.6.32.49/fs/ext3/balloc.c sbi->s_resuid !=3D current_fsuid() && (sbi->s_resgid =3D=3D 0 || !in_group_p (sbi->s_resgid))) { return 0; -diff -urNp linux-2.6.32.49/fs/ext4/balloc.c linux-2.6.32.49/fs/ext4/ball= oc.c ---- linux-2.6.32.49/fs/ext4/balloc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ext4/balloc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -570,7 +570,7 @@ int ext4_has_free_blocks(struct ext4_sb_ +diff --git a/fs/ext4/balloc.c b/fs/ext4/balloc.c +index e85b63c..80398e6 100644 +--- a/fs/ext4/balloc.c ++++ b/fs/ext4/balloc.c +@@ -570,7 +570,7 @@ int ext4_has_free_blocks(struct ext4_sb_info *sbi, s= 64 nblocks) /* Hm, nope. Are (enough) root reserved blocks available? */ if (sbi->s_resuid =3D=3D current_fsuid() || ((sbi->s_resgid !=3D 0) && in_group_p(sbi->s_resgid)) || @@ -46585,9 +48516,10 @@ diff -urNp linux-2.6.32.49/fs/ext4/balloc.c linu= x-2.6.32.49/fs/ext4/balloc.c if (free_blocks >=3D (nblocks + dirty_blocks)) return 1; } -diff -urNp linux-2.6.32.49/fs/ext4/ext4.h linux-2.6.32.49/fs/ext4/ext4.h ---- linux-2.6.32.49/fs/ext4/ext4.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ext4/ext4.h 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h +index 67c46ed..1f237e5 100644 +--- a/fs/ext4/ext4.h ++++ b/fs/ext4/ext4.h @@ -1077,19 +1077,19 @@ struct ext4_sb_info { =20 /* stats for buddy allocator */ @@ -46618,10 +48550,11 @@ diff -urNp linux-2.6.32.49/fs/ext4/ext4.h linux= -2.6.32.49/fs/ext4/ext4.h atomic_t s_lock_busy; =20 /* locality groups */ -diff -urNp linux-2.6.32.49/fs/ext4/file.c linux-2.6.32.49/fs/ext4/file.c ---- linux-2.6.32.49/fs/ext4/file.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ext4/file.c 2011-11-15 19:59:43.000000000 -0500 -@@ -122,8 +122,8 @@ static int ext4_file_open(struct inode * +diff --git a/fs/ext4/file.c b/fs/ext4/file.c +index 2a60541..7439d61 100644 +--- a/fs/ext4/file.c ++++ b/fs/ext4/file.c +@@ -122,8 +122,8 @@ static int ext4_file_open(struct inode * inode, stru= ct file * filp) cp =3D d_path(&path, buf, sizeof(buf)); path_put(&path); if (!IS_ERR(cp)) { @@ -46632,10 +48565,11 @@ diff -urNp linux-2.6.32.49/fs/ext4/file.c linux= -2.6.32.49/fs/ext4/file.c sb->s_dirt =3D 1; } } -diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linux-2.6.32.49/fs/ext4/mba= lloc.c ---- linux-2.6.32.49/fs/ext4/mballoc.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/ext4/mballoc.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -1755,7 +1755,7 @@ void ext4_mb_simple_scan_group(struct ex +diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c +index 42bac1b..0aab9d8 100644 +--- a/fs/ext4/mballoc.c ++++ b/fs/ext4/mballoc.c +@@ -1755,7 +1755,7 @@ void ext4_mb_simple_scan_group(struct ext4_allocat= ion_context *ac, BUG_ON(ac->ac_b_ex.fe_len !=3D ac->ac_g_ex.fe_len); =20 if (EXT4_SB(sb)->s_mb_stats) @@ -46653,7 +48587,7 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linu= x-2.6.32.49/fs/ext4/mballoc.c goto repeat; } } -@@ -2174,6 +2174,8 @@ static int ext4_mb_seq_groups_show(struc +@@ -2174,6 +2174,8 @@ static int ext4_mb_seq_groups_show(struct seq_file= *seq, void *v) ext4_grpblk_t counters[16]; } sg; =20 @@ -46662,7 +48596,7 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linu= x-2.6.32.49/fs/ext4/mballoc.c group--; if (group =3D=3D 0) seq_printf(seq, "#%-5s: %-5s %-5s %-5s " -@@ -2534,25 +2536,25 @@ int ext4_mb_release(struct super_block * +@@ -2534,25 +2536,25 @@ int ext4_mb_release(struct super_block *sb) if (sbi->s_mb_stats) { printk(KERN_INFO "EXT4-fs: mballoc: %u blocks %u reqs (%u success)\n", @@ -46698,7 +48632,7 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linu= x-2.6.32.49/fs/ext4/mballoc.c } =20 free_percpu(sbi->s_locality_groups); -@@ -3034,16 +3036,16 @@ static void ext4_mb_collect_stats(struct +@@ -3034,16 +3036,16 @@ static void ext4_mb_collect_stats(struct ext4_al= location_context *ac) struct ext4_sb_info *sbi =3D EXT4_SB(ac->ac_sb); =20 if (sbi->s_mb_stats && ac->ac_g_ex.fe_len > 1) { @@ -46721,7 +48655,7 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linu= x-2.6.32.49/fs/ext4/mballoc.c } =20 if (ac->ac_op =3D=3D EXT4_MB_HISTORY_ALLOC) -@@ -3443,7 +3445,7 @@ ext4_mb_new_inode_pa(struct ext4_allocat +@@ -3443,7 +3445,7 @@ ext4_mb_new_inode_pa(struct ext4_allocation_contex= t *ac) trace_ext4_mb_new_inode_pa(ac, pa); =20 ext4_mb_use_inode_pa(ac, pa); @@ -46730,7 +48664,7 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linu= x-2.6.32.49/fs/ext4/mballoc.c =20 ei =3D EXT4_I(ac->ac_inode); grp =3D ext4_get_group_info(sb, ac->ac_b_ex.fe_group); -@@ -3503,7 +3505,7 @@ ext4_mb_new_group_pa(struct ext4_allocat +@@ -3503,7 +3505,7 @@ ext4_mb_new_group_pa(struct ext4_allocation_contex= t *ac) trace_ext4_mb_new_group_pa(ac, pa); =20 ext4_mb_use_group_pa(ac, pa); @@ -46739,7 +48673,7 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linu= x-2.6.32.49/fs/ext4/mballoc.c =20 grp =3D ext4_get_group_info(sb, ac->ac_b_ex.fe_group); lg =3D ac->ac_lg; -@@ -3607,7 +3609,7 @@ ext4_mb_release_inode_pa(struct ext4_bud +@@ -3607,7 +3609,7 @@ ext4_mb_release_inode_pa(struct ext4_buddy *e4b, s= truct buffer_head *bitmap_bh, * from the bitmap and continue. */ } @@ -46748,7 +48682,7 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c linu= x-2.6.32.49/fs/ext4/mballoc.c =20 return err; } -@@ -3626,7 +3628,7 @@ ext4_mb_release_group_pa(struct ext4_bud +@@ -3626,7 +3628,7 @@ ext4_mb_release_group_pa(struct ext4_buddy *e4b, ext4_get_group_no_and_offset(sb, pa->pa_pstart, &group, &bit); BUG_ON(group !=3D e4b->bd_group && pa->pa_len !=3D 0); mb_free_blocks(pa->pa_inode, e4b, bit, pa->pa_len); @@ -46757,10 +48691,11 @@ diff -urNp linux-2.6.32.49/fs/ext4/mballoc.c li= nux-2.6.32.49/fs/ext4/mballoc.c =20 if (ac) { ac->ac_sb =3D sb; -diff -urNp linux-2.6.32.49/fs/ext4/super.c linux-2.6.32.49/fs/ext4/super= .c ---- linux-2.6.32.49/fs/ext4/super.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ext4/super.c 2011-11-15 19:59:43.000000000 -0500 -@@ -2287,7 +2287,7 @@ static void ext4_sb_release(struct kobje +diff --git a/fs/ext4/super.c b/fs/ext4/super.c +index f27e045..be5a1c3 100644 +--- a/fs/ext4/super.c ++++ b/fs/ext4/super.c +@@ -2287,7 +2287,7 @@ static void ext4_sb_release(struct kobject *kobj) } =20 =20 @@ -46769,10 +48704,11 @@ diff -urNp linux-2.6.32.49/fs/ext4/super.c linu= x-2.6.32.49/fs/ext4/super.c .show =3D ext4_attr_show, .store =3D ext4_attr_store, }; -diff -urNp linux-2.6.32.49/fs/fcntl.c linux-2.6.32.49/fs/fcntl.c ---- linux-2.6.32.49/fs/fcntl.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/fcntl.c 2011-11-15 19:59:43.000000000 -0500 -@@ -223,6 +223,11 @@ int __f_setown(struct file *filp, struct +diff --git a/fs/fcntl.c b/fs/fcntl.c +index 97e01dc..e9aab2d 100644 +--- a/fs/fcntl.c ++++ b/fs/fcntl.c +@@ -223,6 +223,11 @@ int __f_setown(struct file *filp, struct pid *pid, = enum pid_type type, if (err) return err; =20 @@ -46793,7 +48729,7 @@ diff -urNp linux-2.6.32.49/fs/fcntl.c linux-2.6.3= 2.49/fs/fcntl.c struct f_owner_ex owner; struct pid *pid; int type; -@@ -305,7 +310,7 @@ static int f_setown_ex(struct file *filp +@@ -305,7 +310,7 @@ static int f_setown_ex(struct file *filp, unsigned l= ong arg) =20 static int f_getown_ex(struct file *filp, unsigned long arg) { @@ -46802,7 +48738,7 @@ diff -urNp linux-2.6.32.49/fs/fcntl.c linux-2.6.3= 2.49/fs/fcntl.c struct f_owner_ex owner; int ret =3D 0; =20 -@@ -344,6 +349,7 @@ static long do_fcntl(int fd, unsigned in +@@ -344,6 +349,7 @@ static long do_fcntl(int fd, unsigned int cmd, unsig= ned long arg, switch (cmd) { case F_DUPFD: case F_DUPFD_CLOEXEC: @@ -46810,10 +48746,11 @@ diff -urNp linux-2.6.32.49/fs/fcntl.c linux-2.6= .32.49/fs/fcntl.c if (arg >=3D current->signal->rlim[RLIMIT_NOFILE].rlim_cur) break; err =3D alloc_fd(arg, cmd =3D=3D F_DUPFD_CLOEXEC ? O_CLOEXEC : 0); -diff -urNp linux-2.6.32.49/fs/fifo.c linux-2.6.32.49/fs/fifo.c ---- linux-2.6.32.49/fs/fifo.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/fifo.c 2011-11-15 19:59:43.000000000 -0500 -@@ -59,10 +59,10 @@ static int fifo_open(struct inode *inode +diff --git a/fs/fifo.c b/fs/fifo.c +index f8f97b8..b1f2259 100644 +--- a/fs/fifo.c ++++ b/fs/fifo.c +@@ -59,10 +59,10 @@ static int fifo_open(struct inode *inode, struct fil= e *filp) */ filp->f_op =3D &read_pipefifo_fops; pipe->r_counter++; @@ -46826,7 +48763,7 @@ diff -urNp linux-2.6.32.49/fs/fifo.c linux-2.6.32= .49/fs/fifo.c if ((filp->f_flags & O_NONBLOCK)) { /* suppress POLLHUP until we have * seen a writer */ -@@ -83,15 +83,15 @@ static int fifo_open(struct inode *inode +@@ -83,15 +83,15 @@ static int fifo_open(struct inode *inode, struct fil= e *filp) * errno=3DENXIO when there is no process reading the FIFO. */ ret =3D -ENXIO; @@ -46845,7 +48782,7 @@ diff -urNp linux-2.6.32.49/fs/fifo.c linux-2.6.32= .49/fs/fifo.c wait_for_partner(inode, &pipe->r_counter); if (signal_pending(current)) goto err_wr; -@@ -107,11 +107,11 @@ static int fifo_open(struct inode *inode +@@ -107,11 +107,11 @@ static int fifo_open(struct inode *inode, struct f= ile *filp) */ filp->f_op =3D &rdwr_pipefifo_fops; =20 @@ -46860,7 +48797,7 @@ diff -urNp linux-2.6.32.49/fs/fifo.c linux-2.6.32= .49/fs/fifo.c wake_up_partner(inode); break; =20 -@@ -125,19 +125,19 @@ static int fifo_open(struct inode *inode +@@ -125,19 +125,19 @@ static int fifo_open(struct inode *inode, struct f= ile *filp) return 0; =20 err_rd: @@ -46883,9 +48820,10 @@ diff -urNp linux-2.6.32.49/fs/fifo.c linux-2.6.3= 2.49/fs/fifo.c free_pipe_info(inode); =20 err_nocleanup: -diff -urNp linux-2.6.32.49/fs/file.c linux-2.6.32.49/fs/file.c ---- linux-2.6.32.49/fs/file.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/file.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/file.c b/fs/file.c +index 87e1290..a930cc4 100644 +--- a/fs/file.c ++++ b/fs/file.c @@ -14,6 +14,7 @@ #include #include @@ -46894,7 +48832,7 @@ diff -urNp linux-2.6.32.49/fs/file.c linux-2.6.32= .49/fs/file.c #include #include #include -@@ -257,6 +258,8 @@ int expand_files(struct files_struct *fi +@@ -257,6 +258,8 @@ int expand_files(struct files_struct *files, int nr) * N.B. For clone tasks sharing a files structure, this test * will limit the total number of files that can be opened. */ @@ -46903,10 +48841,11 @@ diff -urNp linux-2.6.32.49/fs/file.c linux-2.6.= 32.49/fs/file.c if (nr >=3D current->signal->rlim[RLIMIT_NOFILE].rlim_cur) return -EMFILE; =20 -diff -urNp linux-2.6.32.49/fs/filesystems.c linux-2.6.32.49/fs/filesyste= ms.c ---- linux-2.6.32.49/fs/filesystems.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/filesystems.c 2011-11-15 19:59:43.000000000 -0500 -@@ -272,7 +272,12 @@ struct file_system_type *get_fs_type(con +diff --git a/fs/filesystems.c b/fs/filesystems.c +index a24c58e..53f91ee 100644 +--- a/fs/filesystems.c ++++ b/fs/filesystems.c +@@ -272,7 +272,12 @@ struct file_system_type *get_fs_type(const char *na= me) int len =3D dot ? dot - name : strlen(name); =20 fs =3D __get_fs_type(name, len); @@ -46919,10 +48858,94 @@ diff -urNp linux-2.6.32.49/fs/filesystems.c lin= ux-2.6.32.49/fs/filesystems.c fs =3D __get_fs_type(name, len); =20 if (dot && fs && !(fs->fs_flags & FS_HAS_SUBTYPE)) { -diff -urNp linux-2.6.32.49/fs/fscache/cookie.c linux-2.6.32.49/fs/fscach= e/cookie.c ---- linux-2.6.32.49/fs/fscache/cookie.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/fscache/cookie.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -68,11 +68,11 @@ struct fscache_cookie *__fscache_acquire +diff --git a/fs/fs_struct.c b/fs/fs_struct.c +index eee0590..ef5bc0e 100644 +--- a/fs/fs_struct.c ++++ b/fs/fs_struct.c +@@ -4,6 +4,7 @@ + #include + #include + #include ++#include +=20 + /* + * Replace the fs->{rootmnt,root} with {mnt,dentry}. Put the old values= . +@@ -17,6 +18,7 @@ void set_fs_root(struct fs_struct *fs, struct path *pa= th) + old_root =3D fs->root; + fs->root =3D *path; + path_get(path); ++ gr_set_chroot_entries(current, path); + write_unlock(&fs->lock); + if (old_root.dentry) + path_put(&old_root); +@@ -56,6 +58,7 @@ void chroot_fs_refs(struct path *old_root, struct path= *new_root) + && fs->root.mnt =3D=3D old_root->mnt) { + path_get(new_root); + fs->root =3D *new_root; ++ gr_set_chroot_entries(p, new_root); + count++; + } + if (fs->pwd.dentry =3D=3D old_root->dentry +@@ -89,7 +92,8 @@ void exit_fs(struct task_struct *tsk) + task_lock(tsk); + write_lock(&fs->lock); + tsk->fs =3D NULL; +- kill =3D !--fs->users; ++ gr_clear_chroot_entries(tsk); ++ kill =3D !atomic_dec_return(&fs->users); + write_unlock(&fs->lock); + task_unlock(tsk); + if (kill) +@@ -102,7 +106,7 @@ struct fs_struct *copy_fs_struct(struct fs_struct *o= ld) + struct fs_struct *fs =3D kmem_cache_alloc(fs_cachep, GFP_KERNEL); + /* We don't need to lock fs - think why ;-) */ + if (fs) { +- fs->users =3D 1; ++ atomic_set(&fs->users, 1); + fs->in_exec =3D 0; + rwlock_init(&fs->lock); + fs->umask =3D old->umask; +@@ -127,8 +131,9 @@ int unshare_fs_struct(void) +=20 + task_lock(current); + write_lock(&fs->lock); +- kill =3D !--fs->users; ++ kill =3D !atomic_dec_return(&fs->users); + current->fs =3D new_fs; ++ gr_set_chroot_entries(current, &new_fs->root); + write_unlock(&fs->lock); + task_unlock(current); +=20 +@@ -147,7 +152,7 @@ EXPORT_SYMBOL(current_umask); +=20 + /* to be mentioned only in INIT_TASK */ + struct fs_struct init_fs =3D { +- .users =3D 1, ++ .users =3D ATOMIC_INIT(1), + .lock =3D __RW_LOCK_UNLOCKED(init_fs.lock), + .umask =3D 0022, + }; +@@ -162,12 +167,13 @@ void daemonize_fs_struct(void) + task_lock(current); +=20 + write_lock(&init_fs.lock); +- init_fs.users++; ++ atomic_inc(&init_fs.users); + write_unlock(&init_fs.lock); +=20 + write_lock(&fs->lock); + current->fs =3D &init_fs; +- kill =3D !--fs->users; ++ gr_set_chroot_entries(current, ¤t->fs->root); ++ kill =3D !atomic_dec_return(&fs->users); + write_unlock(&fs->lock); +=20 + task_unlock(current); +diff --git a/fs/fscache/cookie.c b/fs/fscache/cookie.c +index 9905350..02eaec4 100644 +--- a/fs/fscache/cookie.c ++++ b/fs/fscache/cookie.c +@@ -68,11 +68,11 @@ struct fscache_cookie *__fscache_acquire_cookie( parent ? (char *) parent->def->name : "", def->name, netfs_data); =20 @@ -46936,7 +48959,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie _leave(" [no parent]"); return NULL; } -@@ -87,7 +87,7 @@ struct fscache_cookie *__fscache_acquire +@@ -87,7 +87,7 @@ struct fscache_cookie *__fscache_acquire_cookie( /* allocate and initialise a cookie */ cookie =3D kmem_cache_alloc(fscache_cookie_jar, GFP_KERNEL); if (!cookie) { @@ -46945,7 +48968,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie _leave(" [ENOMEM]"); return NULL; } -@@ -109,13 +109,13 @@ struct fscache_cookie *__fscache_acquire +@@ -109,13 +109,13 @@ struct fscache_cookie *__fscache_acquire_cookie( =20 switch (cookie->def->type) { case FSCACHE_COOKIE_TYPE_INDEX: @@ -46962,7 +48985,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie break; } =20 -@@ -126,13 +126,13 @@ struct fscache_cookie *__fscache_acquire +@@ -126,13 +126,13 @@ struct fscache_cookie *__fscache_acquire_cookie( if (fscache_acquire_non_index_cookie(cookie) < 0) { atomic_dec(&parent->n_children); __fscache_cookie_put(cookie); @@ -46978,7 +49001,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie _leave(" =3D %p", cookie); return cookie; } -@@ -168,7 +168,7 @@ static int fscache_acquire_non_index_coo +@@ -168,7 +168,7 @@ static int fscache_acquire_non_index_cookie(struct f= scache_cookie *cookie) cache =3D fscache_select_cache_for_object(cookie->parent); if (!cache) { up_read(&fscache_addremove_sem); @@ -46987,7 +49010,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie _leave(" =3D -ENOMEDIUM [no cache]"); return -ENOMEDIUM; } -@@ -256,12 +256,12 @@ static int fscache_alloc_object(struct f +@@ -256,12 +256,12 @@ static int fscache_alloc_object(struct fscache_cac= he *cache, object =3D cache->ops->alloc_object(cache, cookie); fscache_stat_d(&fscache_n_cop_alloc_object); if (IS_ERR(object)) { @@ -47002,7 +49025,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie =20 object->debug_id =3D atomic_inc_return(&fscache_object_debug_id); =20 -@@ -377,10 +377,10 @@ void __fscache_update_cookie(struct fsca +@@ -377,10 +377,10 @@ void __fscache_update_cookie(struct fscache_cookie= *cookie) struct fscache_object *object; struct hlist_node *_p; =20 @@ -47015,7 +49038,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie _leave(" [no cookie]"); return; } -@@ -414,12 +414,12 @@ void __fscache_relinquish_cookie(struct=20 +@@ -414,12 +414,12 @@ void __fscache_relinquish_cookie(struct fscache_co= okie *cookie, int retire) struct fscache_object *object; unsigned long event; =20 @@ -47031,7 +49054,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c li= nux-2.6.32.49/fs/fscache/cookie _leave(" [no cookie]"); return; } -@@ -435,7 +435,7 @@ void __fscache_relinquish_cookie(struct=20 +@@ -435,7 +435,7 @@ void __fscache_relinquish_cookie(struct fscache_cook= ie *cookie, int retire) =20 /* wait for the cookie to finish being instantiated (or to fail) */ if (test_bit(FSCACHE_COOKIE_CREATING, &cookie->flags)) { @@ -47040,9 +49063,10 @@ diff -urNp linux-2.6.32.49/fs/fscache/cookie.c l= inux-2.6.32.49/fs/fscache/cookie wait_on_bit(&cookie->flags, FSCACHE_COOKIE_CREATING, fscache_wait_bit, TASK_UNINTERRUPTIBLE); } -diff -urNp linux-2.6.32.49/fs/fscache/internal.h linux-2.6.32.49/fs/fsca= che/internal.h ---- linux-2.6.32.49/fs/fscache/internal.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/fs/fscache/internal.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/fs/fscache/internal.h b/fs/fscache/internal.h +index edd7434..0725e66 100644 +--- a/fs/fscache/internal.h ++++ b/fs/fscache/internal.h @@ -136,94 +136,94 @@ extern void fscache_proc_cleanup(void); extern atomic_t fscache_n_ops_processed[FSCACHE_MAX_THREADS]; extern atomic_t fscache_n_objs_processed[FSCACHE_MAX_THREADS]; @@ -47226,7 +49250,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/internal.h = linux-2.6.32.49/fs/fscache/inte =20 extern atomic_t fscache_n_cop_alloc_object; extern atomic_t fscache_n_cop_lookup_object; -@@ -247,6 +247,11 @@ static inline void fscache_stat(atomic_t +@@ -247,6 +247,11 @@ static inline void fscache_stat(atomic_t *stat) atomic_inc(stat); } =20 @@ -47238,7 +49262,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/internal.h = linux-2.6.32.49/fs/fscache/inte static inline void fscache_stat_d(atomic_t *stat) { atomic_dec(stat); -@@ -259,6 +264,7 @@ extern const struct file_operations fsca +@@ -259,6 +264,7 @@ extern const struct file_operations fscache_stats_fo= ps; =20 #define __fscache_stat(stat) (NULL) #define fscache_stat(stat) do {} while (0) @@ -47246,10 +49270,11 @@ diff -urNp linux-2.6.32.49/fs/fscache/internal.= h linux-2.6.32.49/fs/fscache/inte #define fscache_stat_d(stat) do {} while (0) #endif =20 -diff -urNp linux-2.6.32.49/fs/fscache/object.c linux-2.6.32.49/fs/fscach= e/object.c ---- linux-2.6.32.49/fs/fscache/object.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/fscache/object.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -144,7 +144,7 @@ static void fscache_object_state_machine +diff --git a/fs/fscache/object.c b/fs/fscache/object.c +index e513ac5..e888d34 100644 +--- a/fs/fscache/object.c ++++ b/fs/fscache/object.c +@@ -144,7 +144,7 @@ static void fscache_object_state_machine(struct fsca= che_object *object) /* update the object metadata on disk */ case FSCACHE_OBJECT_UPDATING: clear_bit(FSCACHE_OBJECT_EV_UPDATE, &object->events); @@ -47258,7 +49283,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object fscache_stat(&fscache_n_cop_update_object); object->cache->ops->update_object(object); fscache_stat_d(&fscache_n_cop_update_object); -@@ -233,7 +233,7 @@ static void fscache_object_state_machine +@@ -233,7 +233,7 @@ static void fscache_object_state_machine(struct fsca= che_object *object) spin_lock(&object->lock); object->state =3D FSCACHE_OBJECT_DEAD; spin_unlock(&object->lock); @@ -47267,7 +49292,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object goto terminal_transit; =20 /* handle the parent cache of this object being withdrawn from -@@ -248,7 +248,7 @@ static void fscache_object_state_machine +@@ -248,7 +248,7 @@ static void fscache_object_state_machine(struct fsca= che_object *object) spin_lock(&object->lock); object->state =3D FSCACHE_OBJECT_DEAD; spin_unlock(&object->lock); @@ -47276,7 +49301,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object goto terminal_transit; =20 /* complain about the object being woken up once it is -@@ -492,7 +492,7 @@ static void fscache_lookup_object(struct +@@ -492,7 +492,7 @@ static void fscache_lookup_object(struct fscache_obj= ect *object) parent->cookie->def->name, cookie->def->name, object->cache->tag->name); =20 @@ -47285,7 +49310,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object fscache_stat(&fscache_n_cop_lookup_object); ret =3D object->cache->ops->lookup_object(object); fscache_stat_d(&fscache_n_cop_lookup_object); -@@ -503,7 +503,7 @@ static void fscache_lookup_object(struct +@@ -503,7 +503,7 @@ static void fscache_lookup_object(struct fscache_obj= ect *object) if (ret =3D=3D -ETIMEDOUT) { /* probably stuck behind another object, so move this one to * the back of the queue */ @@ -47294,7 +49319,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object set_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events); } =20 -@@ -526,7 +526,7 @@ void fscache_object_lookup_negative(stru +@@ -526,7 +526,7 @@ void fscache_object_lookup_negative(struct fscache_o= bject *object) =20 spin_lock(&object->lock); if (object->state =3D=3D FSCACHE_OBJECT_LOOKING_UP) { @@ -47303,7 +49328,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object =20 /* transit here to allow write requests to begin stacking up * and read requests to begin returning ENODATA */ -@@ -572,7 +572,7 @@ void fscache_obtained_object(struct fsca +@@ -572,7 +572,7 @@ void fscache_obtained_object(struct fscache_object *= object) * result, in which case there may be data available */ spin_lock(&object->lock); if (object->state =3D=3D FSCACHE_OBJECT_LOOKING_UP) { @@ -47312,7 +49337,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object =20 clear_bit(FSCACHE_COOKIE_NO_DATA_YET, &cookie->flags); =20 -@@ -586,7 +586,7 @@ void fscache_obtained_object(struct fsca +@@ -586,7 +586,7 @@ void fscache_obtained_object(struct fscache_object *= object) set_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events); } else { ASSERTCMP(object->state, =3D=3D, FSCACHE_OBJECT_CREATING); @@ -47321,7 +49346,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object =20 object->state =3D FSCACHE_OBJECT_AVAILABLE; spin_unlock(&object->lock); -@@ -633,7 +633,7 @@ static void fscache_object_available(str +@@ -633,7 +633,7 @@ static void fscache_object_available(struct fscache_= object *object) fscache_enqueue_dependents(object); =20 fscache_hist(fscache_obj_instantiate_histogram, object->lookup_jif); @@ -47330,7 +49355,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object =20 _leave(""); } -@@ -861,7 +861,7 @@ enum fscache_checkaux fscache_check_aux( +@@ -861,7 +861,7 @@ enum fscache_checkaux fscache_check_aux(struct fscac= he_object *object, enum fscache_checkaux result; =20 if (!object->cookie->def->check_aux) { @@ -47339,7 +49364,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c li= nux-2.6.32.49/fs/fscache/object return FSCACHE_CHECKAUX_OKAY; } =20 -@@ -870,17 +870,17 @@ enum fscache_checkaux fscache_check_aux( +@@ -870,17 +870,17 @@ enum fscache_checkaux fscache_check_aux(struct fsc= ache_object *object, switch (result) { /* entry okay as is */ case FSCACHE_CHECKAUX_OKAY: @@ -47360,9 +49385,10 @@ diff -urNp linux-2.6.32.49/fs/fscache/object.c l= inux-2.6.32.49/fs/fscache/object break; =20 default: -diff -urNp linux-2.6.32.49/fs/fscache/operation.c linux-2.6.32.49/fs/fsc= ache/operation.c ---- linux-2.6.32.49/fs/fscache/operation.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/fs/fscache/operation.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/fs/fscache/operation.c b/fs/fscache/operation.c +index 313e79a..775240f 100644 +--- a/fs/fscache/operation.c ++++ b/fs/fscache/operation.c @@ -16,7 +16,7 @@ #include #include "internal.h" @@ -47372,7 +49398,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope EXPORT_SYMBOL(fscache_op_debug_id); =20 /** -@@ -39,7 +39,7 @@ void fscache_enqueue_operation(struct fs +@@ -39,7 +39,7 @@ void fscache_enqueue_operation(struct fscache_operatio= n *op) ASSERTCMP(op->object->state, >=3D, FSCACHE_OBJECT_AVAILABLE); ASSERTCMP(atomic_read(&op->usage), >, 0); =20 @@ -47381,7 +49407,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope switch (op->flags & FSCACHE_OP_TYPE) { case FSCACHE_OP_FAST: _debug("queue fast"); -@@ -76,7 +76,7 @@ static void fscache_run_op(struct fscach +@@ -76,7 +76,7 @@ static void fscache_run_op(struct fscache_object *obje= ct, wake_up_bit(&op->flags, FSCACHE_OP_WAITING); if (op->processor) fscache_enqueue_operation(op); @@ -47390,7 +49416,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope } =20 /* -@@ -107,11 +107,11 @@ int fscache_submit_exclusive_op(struct f +@@ -107,11 +107,11 @@ int fscache_submit_exclusive_op(struct fscache_obj= ect *object, if (object->n_ops > 0) { atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -47404,7 +49430,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope fscache_start_operations(object); } else { ASSERTCMP(object->n_in_progress, =3D=3D, 0); -@@ -127,7 +127,7 @@ int fscache_submit_exclusive_op(struct f +@@ -127,7 +127,7 @@ int fscache_submit_exclusive_op(struct fscache_objec= t *object, object->n_exclusive++; /* reads and writes must wait */ atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -47413,7 +49439,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope ret =3D 0; } else { /* not allowed to submit ops in any other state */ -@@ -214,11 +214,11 @@ int fscache_submit_op(struct fscache_obj +@@ -214,11 +214,11 @@ int fscache_submit_op(struct fscache_object *objec= t, if (object->n_exclusive > 0) { atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -47427,7 +49453,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope fscache_start_operations(object); } else { ASSERTCMP(object->n_exclusive, =3D=3D, 0); -@@ -230,12 +230,12 @@ int fscache_submit_op(struct fscache_obj +@@ -230,12 +230,12 @@ int fscache_submit_op(struct fscache_object *objec= t, object->n_ops++; atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -47442,7 +49468,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope ret =3D -ENOBUFS; } else if (!test_bit(FSCACHE_IOERROR, &object->cache->flags)) { fscache_report_unexpected_submission(object, op, ostate); -@@ -305,7 +305,7 @@ int fscache_cancel_op(struct fscache_ope +@@ -305,7 +305,7 @@ int fscache_cancel_op(struct fscache_operation *op) =20 ret =3D -EBUSY; if (!list_empty(&op->pend_link)) { @@ -47451,7 +49477,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope list_del_init(&op->pend_link); object->n_ops--; if (test_bit(FSCACHE_OP_EXCLUSIVE, &op->flags)) -@@ -344,7 +344,7 @@ void fscache_put_operation(struct fscach +@@ -344,7 +344,7 @@ void fscache_put_operation(struct fscache_operation = *op) if (test_and_set_bit(FSCACHE_OP_DEAD, &op->flags)) BUG(); =20 @@ -47460,7 +49486,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope =20 if (op->release) { op->release(op); -@@ -361,7 +361,7 @@ void fscache_put_operation(struct fscach +@@ -361,7 +361,7 @@ void fscache_put_operation(struct fscache_operation = *op) * lock, and defer it otherwise */ if (!spin_trylock(&object->lock)) { _debug("defer put"); @@ -47469,7 +49495,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation.c= linux-2.6.32.49/fs/fscache/ope =20 cache =3D object->cache; spin_lock(&cache->op_gc_list_lock); -@@ -423,7 +423,7 @@ void fscache_operation_gc(struct work_st +@@ -423,7 +423,7 @@ void fscache_operation_gc(struct work_struct *work) =20 _debug("GC DEFERRED REL OBJ%x OP%x", object->debug_id, op->debug_id); @@ -47478,10 +49504,11 @@ diff -urNp linux-2.6.32.49/fs/fscache/operation= .c linux-2.6.32.49/fs/fscache/ope =20 ASSERTCMP(atomic_read(&op->usage), =3D=3D, 0); =20 -diff -urNp linux-2.6.32.49/fs/fscache/page.c linux-2.6.32.49/fs/fscache/= page.c ---- linux-2.6.32.49/fs/fscache/page.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/fscache/page.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -59,7 +59,7 @@ bool __fscache_maybe_release_page(struct +diff --git a/fs/fscache/page.c b/fs/fscache/page.c +index c598ea4..6aac13e 100644 +--- a/fs/fscache/page.c ++++ b/fs/fscache/page.c +@@ -59,7 +59,7 @@ bool __fscache_maybe_release_page(struct fscache_cooki= e *cookie, val =3D radix_tree_lookup(&cookie->stores, page->index); if (!val) { rcu_read_unlock(); @@ -47490,7 +49517,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c __fscache_uncache_page(cookie, page); return true; } -@@ -89,11 +89,11 @@ bool __fscache_maybe_release_page(struct +@@ -89,11 +89,11 @@ bool __fscache_maybe_release_page(struct fscache_coo= kie *cookie, spin_unlock(&cookie->stores_lock); =20 if (xpage) { @@ -47514,7 +49541,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c return false; } EXPORT_SYMBOL(__fscache_maybe_release_page); -@@ -130,7 +130,7 @@ static void fscache_end_page_write(struc +@@ -130,7 +130,7 @@ static void fscache_end_page_write(struct fscache_ob= ject *object, FSCACHE_COOKIE_STORING_TAG); if (!radix_tree_tag_get(&cookie->stores, page->index, FSCACHE_COOKIE_PENDING_TAG)) { @@ -47523,7 +49550,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c xpage =3D radix_tree_delete(&cookie->stores, page->index); } spin_unlock(&cookie->stores_lock); -@@ -151,7 +151,7 @@ static void fscache_attr_changed_op(stru +@@ -151,7 +151,7 @@ static void fscache_attr_changed_op(struct fscache_o= peration *op) =20 _enter("{OBJ%x OP%x}", object->debug_id, op->debug_id); =20 @@ -47532,7 +49559,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 if (fscache_object_is_active(object)) { fscache_set_op_state(op, "CallFS"); -@@ -178,11 +178,11 @@ int __fscache_attr_changed(struct fscach +@@ -178,11 +178,11 @@ int __fscache_attr_changed(struct fscache_cookie *= cookie) =20 ASSERTCMP(cookie->def->type, !=3D, FSCACHE_COOKIE_TYPE_INDEX); =20 @@ -47546,7 +49573,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c _leave(" =3D -ENOMEM"); return -ENOMEM; } -@@ -202,7 +202,7 @@ int __fscache_attr_changed(struct fscach +@@ -202,7 +202,7 @@ int __fscache_attr_changed(struct fscache_cookie *co= okie) if (fscache_submit_exclusive_op(object, op) < 0) goto nobufs; spin_unlock(&cookie->lock); @@ -47555,7 +49582,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c fscache_put_operation(op); _leave(" =3D 0"); return 0; -@@ -210,7 +210,7 @@ int __fscache_attr_changed(struct fscach +@@ -210,7 +210,7 @@ int __fscache_attr_changed(struct fscache_cookie *co= okie) nobufs: spin_unlock(&cookie->lock); kfree(op); @@ -47564,7 +49591,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c _leave(" =3D %d", -ENOBUFS); return -ENOBUFS; } -@@ -264,7 +264,7 @@ static struct fscache_retrieval *fscache +@@ -264,7 +264,7 @@ static struct fscache_retrieval *fscache_alloc_retri= eval( /* allocate a retrieval operation and attempt to submit it */ op =3D kzalloc(sizeof(*op), GFP_NOIO); if (!op) { @@ -47573,7 +49600,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c return NULL; } =20 -@@ -294,13 +294,13 @@ static int fscache_wait_for_deferred_loo +@@ -294,13 +294,13 @@ static int fscache_wait_for_deferred_lookup(struct= fscache_cookie *cookie) return 0; } =20 @@ -47589,7 +49616,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c _leave(" =3D -ERESTARTSYS"); return -ERESTARTSYS; } -@@ -318,8 +318,8 @@ static int fscache_wait_for_deferred_loo +@@ -318,8 +318,8 @@ static int fscache_wait_for_deferred_lookup(struct f= scache_cookie *cookie) */ static int fscache_wait_for_retrieval_activation(struct fscache_object = *object, struct fscache_retrieval *op, @@ -47600,7 +49627,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c { int ret; =20 -@@ -327,7 +327,7 @@ static int fscache_wait_for_retrieval_ac +@@ -327,7 +327,7 @@ static int fscache_wait_for_retrieval_activation(str= uct fscache_object *object, goto check_if_dead; =20 _debug(">>> WT"); @@ -47609,7 +49636,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c if (wait_on_bit(&op->op.flags, FSCACHE_OP_WAITING, fscache_wait_bit_interruptible, TASK_INTERRUPTIBLE) < 0) { -@@ -344,7 +344,7 @@ static int fscache_wait_for_retrieval_ac +@@ -344,7 +344,7 @@ static int fscache_wait_for_retrieval_activation(str= uct fscache_object *object, =20 check_if_dead: if (unlikely(fscache_object_is_dead(object))) { @@ -47618,7 +49645,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c return -ENOBUFS; } return 0; -@@ -371,7 +371,7 @@ int __fscache_read_or_alloc_page(struct=20 +@@ -371,7 +371,7 @@ int __fscache_read_or_alloc_page(struct fscache_cook= ie *cookie, =20 _enter("%p,%p,,,", cookie, page); =20 @@ -47627,7 +49654,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 if (hlist_empty(&cookie->backing_objects)) goto nobufs; -@@ -405,7 +405,7 @@ int __fscache_read_or_alloc_page(struct=20 +@@ -405,7 +405,7 @@ int __fscache_read_or_alloc_page(struct fscache_cook= ie *cookie, goto nobufs_unlock; spin_unlock(&cookie->lock); =20 @@ -47636,7 +49663,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 /* pin the netfs read context in case we need to do the actual netfs * read because we've encountered a cache read failure */ -@@ -435,15 +435,15 @@ int __fscache_read_or_alloc_page(struct=20 +@@ -435,15 +435,15 @@ int __fscache_read_or_alloc_page(struct fscache_co= okie *cookie, =20 error: if (ret =3D=3D -ENOMEM) @@ -47666,7 +49693,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c _leave(" =3D -ENOBUFS"); return -ENOBUFS; } -@@ -491,7 +491,7 @@ int __fscache_read_or_alloc_pages(struct +@@ -491,7 +491,7 @@ int __fscache_read_or_alloc_pages(struct fscache_coo= kie *cookie, =20 _enter("%p,,%d,,,", cookie, *nr_pages); =20 @@ -47675,7 +49702,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 if (hlist_empty(&cookie->backing_objects)) goto nobufs; -@@ -522,7 +522,7 @@ int __fscache_read_or_alloc_pages(struct +@@ -522,7 +522,7 @@ int __fscache_read_or_alloc_pages(struct fscache_coo= kie *cookie, goto nobufs_unlock; spin_unlock(&cookie->lock); =20 @@ -47684,7 +49711,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 /* pin the netfs read context in case we need to do the actual netfs * read because we've encountered a cache read failure */ -@@ -552,15 +552,15 @@ int __fscache_read_or_alloc_pages(struct +@@ -552,15 +552,15 @@ int __fscache_read_or_alloc_pages(struct fscache_c= ookie *cookie, =20 error: if (ret =3D=3D -ENOMEM) @@ -47714,7 +49741,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c _leave(" =3D -ENOBUFS"); return -ENOBUFS; } -@@ -594,7 +594,7 @@ int __fscache_alloc_page(struct fscache_ +@@ -594,7 +594,7 @@ int __fscache_alloc_page(struct fscache_cookie *cook= ie, =20 _enter("%p,%p,,,", cookie, page); =20 @@ -47723,7 +49750,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 if (hlist_empty(&cookie->backing_objects)) goto nobufs; -@@ -621,7 +621,7 @@ int __fscache_alloc_page(struct fscache_ +@@ -621,7 +621,7 @@ int __fscache_alloc_page(struct fscache_cookie *cook= ie, goto nobufs_unlock; spin_unlock(&cookie->lock); =20 @@ -47732,7 +49759,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 ret =3D fscache_wait_for_retrieval_activation( object, op, -@@ -637,11 +637,11 @@ int __fscache_alloc_page(struct fscache_ +@@ -637,11 +637,11 @@ int __fscache_alloc_page(struct fscache_cookie *co= okie, =20 error: if (ret =3D=3D -ERESTARTSYS) @@ -47756,7 +49783,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c _leave(" =3D -ENOBUFS"); return -ENOBUFS; } -@@ -694,7 +694,7 @@ static void fscache_write_op(struct fsca +@@ -694,7 +694,7 @@ static void fscache_write_op(struct fscache_operatio= n *_op) =20 spin_lock(&cookie->stores_lock); =20 @@ -47765,7 +49792,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 /* find a page to store */ page =3D NULL; -@@ -705,7 +705,7 @@ static void fscache_write_op(struct fsca +@@ -705,7 +705,7 @@ static void fscache_write_op(struct fscache_operatio= n *_op) page =3D results[0]; _debug("gang %d [%lx]", n, page->index); if (page->index > op->store_limit) { @@ -47774,7 +49801,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c goto superseded; } =20 -@@ -721,7 +721,7 @@ static void fscache_write_op(struct fsca +@@ -721,7 +721,7 @@ static void fscache_write_op(struct fscache_operatio= n *_op) =20 if (page) { fscache_set_op_state(&op->op, "Store"); @@ -47783,7 +49810,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c fscache_stat(&fscache_n_cop_write_page); ret =3D object->cache->ops->write_page(op, page); fscache_stat_d(&fscache_n_cop_write_page); -@@ -792,7 +792,7 @@ int __fscache_write_page(struct fscache_ +@@ -792,7 +792,7 @@ int __fscache_write_page(struct fscache_cookie *cook= ie, ASSERTCMP(cookie->def->type, !=3D, FSCACHE_COOKIE_TYPE_INDEX); ASSERT(PageFsCache(page)); =20 @@ -47792,7 +49819,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 op =3D kzalloc(sizeof(*op), GFP_NOIO); if (!op) -@@ -844,7 +844,7 @@ int __fscache_write_page(struct fscache_ +@@ -844,7 +844,7 @@ int __fscache_write_page(struct fscache_cookie *cook= ie, spin_unlock(&cookie->stores_lock); spin_unlock(&object->lock); =20 @@ -47801,7 +49828,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c op->store_limit =3D object->store_limit; =20 if (fscache_submit_op(object, &op->op) < 0) -@@ -852,8 +852,8 @@ int __fscache_write_page(struct fscache_ +@@ -852,8 +852,8 @@ int __fscache_write_page(struct fscache_cookie *cook= ie, =20 spin_unlock(&cookie->lock); radix_tree_preload_end(); @@ -47812,7 +49839,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 /* the slow work queue now carries its own ref on the object */ fscache_put_operation(&op->op); -@@ -861,14 +861,14 @@ int __fscache_write_page(struct fscache_ +@@ -861,14 +861,14 @@ int __fscache_write_page(struct fscache_cookie *co= okie, return 0; =20 already_queued: @@ -47846,7 +49873,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c _leave(" =3D -ENOMEM"); return -ENOMEM; } -@@ -911,7 +911,7 @@ void __fscache_uncache_page(struct fscac +@@ -911,7 +911,7 @@ void __fscache_uncache_page(struct fscache_cookie *c= ookie, struct page *page) ASSERTCMP(cookie->def->type, !=3D, FSCACHE_COOKIE_TYPE_INDEX); ASSERTCMP(page, !=3D, NULL); =20 @@ -47855,7 +49882,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c linu= x-2.6.32.49/fs/fscache/page.c =20 /* cache withdrawal may beat us to it */ if (!PageFsCache(page)) -@@ -964,7 +964,7 @@ void fscache_mark_pages_cached(struct fs +@@ -964,7 +964,7 @@ void fscache_mark_pages_cached(struct fscache_retrie= val *op, unsigned long loop; =20 #ifdef CONFIG_FSCACHE_STATS @@ -47864,9 +49891,10 @@ diff -urNp linux-2.6.32.49/fs/fscache/page.c lin= ux-2.6.32.49/fs/fscache/page.c #endif =20 for (loop =3D 0; loop < pagevec->nr; loop++) { -diff -urNp linux-2.6.32.49/fs/fscache/stats.c linux-2.6.32.49/fs/fscache= /stats.c ---- linux-2.6.32.49/fs/fscache/stats.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/fscache/stats.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/fs/fscache/stats.c b/fs/fscache/stats.c +index 46435f3..8cddf18 100644 +--- a/fs/fscache/stats.c ++++ b/fs/fscache/stats.c @@ -18,95 +18,95 @@ /* * operation counters @@ -48052,7 +50080,7 @@ diff -urNp linux-2.6.32.49/fs/fscache/stats.c lin= ux-2.6.32.49/fs/fscache/stats.c =20 atomic_t fscache_n_cop_alloc_object; atomic_t fscache_n_cop_lookup_object; -@@ -133,113 +133,113 @@ static int fscache_stats_show(struct seq +@@ -133,113 +133,113 @@ static int fscache_stats_show(struct seq_file *m= , void *v) seq_puts(m, "FS-Cache statistics\n"); =20 seq_printf(m, "Cookies: idx=3D%u dat=3D%u spc=3D%u\n", @@ -48242,91 +50270,10 @@ diff -urNp linux-2.6.32.49/fs/fscache/stats.c l= inux-2.6.32.49/fs/fscache/stats.c =20 seq_printf(m, "CacheOp: alo=3D%d luo=3D%d luc=3D%d gro=3D%d\n", atomic_read(&fscache_n_cop_alloc_object), -diff -urNp linux-2.6.32.49/fs/fs_struct.c linux-2.6.32.49/fs/fs_struct.c ---- linux-2.6.32.49/fs/fs_struct.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/fs_struct.c 2011-11-15 19:59:43.000000000 -0500 -@@ -4,6 +4,7 @@ - #include - #include - #include -+#include -=20 - /* - * Replace the fs->{rootmnt,root} with {mnt,dentry}. Put the old values= . -@@ -17,6 +18,7 @@ void set_fs_root(struct fs_struct *fs, s - old_root =3D fs->root; - fs->root =3D *path; - path_get(path); -+ gr_set_chroot_entries(current, path); - write_unlock(&fs->lock); - if (old_root.dentry) - path_put(&old_root); -@@ -56,6 +58,7 @@ void chroot_fs_refs(struct path *old_roo - && fs->root.mnt =3D=3D old_root->mnt) { - path_get(new_root); - fs->root =3D *new_root; -+ gr_set_chroot_entries(p, new_root); - count++; - } - if (fs->pwd.dentry =3D=3D old_root->dentry -@@ -89,7 +92,8 @@ void exit_fs(struct task_struct *tsk) - task_lock(tsk); - write_lock(&fs->lock); - tsk->fs =3D NULL; -- kill =3D !--fs->users; -+ gr_clear_chroot_entries(tsk); -+ kill =3D !atomic_dec_return(&fs->users); - write_unlock(&fs->lock); - task_unlock(tsk); - if (kill) -@@ -102,7 +106,7 @@ struct fs_struct *copy_fs_struct(struct=20 - struct fs_struct *fs =3D kmem_cache_alloc(fs_cachep, GFP_KERNEL); - /* We don't need to lock fs - think why ;-) */ - if (fs) { -- fs->users =3D 1; -+ atomic_set(&fs->users, 1); - fs->in_exec =3D 0; - rwlock_init(&fs->lock); - fs->umask =3D old->umask; -@@ -127,8 +131,9 @@ int unshare_fs_struct(void) -=20 - task_lock(current); - write_lock(&fs->lock); -- kill =3D !--fs->users; -+ kill =3D !atomic_dec_return(&fs->users); - current->fs =3D new_fs; -+ gr_set_chroot_entries(current, &new_fs->root); - write_unlock(&fs->lock); - task_unlock(current); -=20 -@@ -147,7 +152,7 @@ EXPORT_SYMBOL(current_umask); -=20 - /* to be mentioned only in INIT_TASK */ - struct fs_struct init_fs =3D { -- .users =3D 1, -+ .users =3D ATOMIC_INIT(1), - .lock =3D __RW_LOCK_UNLOCKED(init_fs.lock), - .umask =3D 0022, - }; -@@ -162,12 +167,13 @@ void daemonize_fs_struct(void) - task_lock(current); -=20 - write_lock(&init_fs.lock); -- init_fs.users++; -+ atomic_inc(&init_fs.users); - write_unlock(&init_fs.lock); -=20 - write_lock(&fs->lock); - current->fs =3D &init_fs; -- kill =3D !--fs->users; -+ gr_set_chroot_entries(current, ¤t->fs->root); -+ kill =3D !atomic_dec_return(&fs->users); - write_unlock(&fs->lock); -=20 - task_unlock(current); -diff -urNp linux-2.6.32.49/fs/fuse/cuse.c linux-2.6.32.49/fs/fuse/cuse.c ---- linux-2.6.32.49/fs/fuse/cuse.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/fuse/cuse.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/fuse/cuse.c b/fs/fuse/cuse.c +index de792dc..448b532 100644 +--- a/fs/fuse/cuse.c ++++ b/fs/fuse/cuse.c @@ -576,10 +576,12 @@ static int __init cuse_init(void) INIT_LIST_HEAD(&cuse_conntbl[i]); =20 @@ -48344,10 +50291,11 @@ diff -urNp linux-2.6.32.49/fs/fuse/cuse.c linux= -2.6.32.49/fs/fuse/cuse.c =20 cuse_class =3D class_create(THIS_MODULE, "cuse"); if (IS_ERR(cuse_class)) -diff -urNp linux-2.6.32.49/fs/fuse/dev.c linux-2.6.32.49/fs/fuse/dev.c ---- linux-2.6.32.49/fs/fuse/dev.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/fuse/dev.c 2011-11-15 19:59:43.000000000 -0500 -@@ -885,7 +885,7 @@ static int fuse_notify_inval_entry(struc +diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c +index 1facb39..7f48557 100644 +--- a/fs/fuse/dev.c ++++ b/fs/fuse/dev.c +@@ -885,7 +885,7 @@ static int fuse_notify_inval_entry(struct fuse_conn = *fc, unsigned int size, { struct fuse_notify_inval_entry_out outarg; int err =3D -EINVAL; @@ -48356,7 +50304,7 @@ diff -urNp linux-2.6.32.49/fs/fuse/dev.c linux-2.= 6.32.49/fs/fuse/dev.c struct qstr name; =20 if (size < sizeof(outarg)) -@@ -899,6 +899,11 @@ static int fuse_notify_inval_entry(struc +@@ -899,6 +899,11 @@ static int fuse_notify_inval_entry(struct fuse_conn= *fc, unsigned int size, if (outarg.namelen > FUSE_NAME_MAX) goto err; =20 @@ -48368,7 +50316,7 @@ diff -urNp linux-2.6.32.49/fs/fuse/dev.c linux-2.= 6.32.49/fs/fuse/dev.c err =3D -EINVAL; if (size !=3D sizeof(outarg) + outarg.namelen + 1) goto err; -@@ -914,17 +919,15 @@ static int fuse_notify_inval_entry(struc +@@ -914,17 +919,15 @@ static int fuse_notify_inval_entry(struct fuse_con= n *fc, unsigned int size, =20 down_read(&fc->killsb); err =3D -ENOENT; @@ -48390,10 +50338,11 @@ diff -urNp linux-2.6.32.49/fs/fuse/dev.c linux-= 2.6.32.49/fs/fuse/dev.c return err; } =20 -diff -urNp linux-2.6.32.49/fs/fuse/dir.c linux-2.6.32.49/fs/fuse/dir.c ---- linux-2.6.32.49/fs/fuse/dir.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/fuse/dir.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1127,7 +1127,7 @@ static char *read_link(struct dentry *de +diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c +index 4787ae6..73efff7 100644 +--- a/fs/fuse/dir.c ++++ b/fs/fuse/dir.c +@@ -1127,7 +1127,7 @@ static char *read_link(struct dentry *dentry) return link; } =20 @@ -48402,10 +50351,11 @@ diff -urNp linux-2.6.32.49/fs/fuse/dir.c linux-= 2.6.32.49/fs/fuse/dir.c { if (!IS_ERR(link)) free_page((unsigned long) link); -diff -urNp linux-2.6.32.49/fs/gfs2/ops_inode.c linux-2.6.32.49/fs/gfs2/o= ps_inode.c ---- linux-2.6.32.49/fs/gfs2/ops_inode.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/gfs2/ops_inode.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -752,6 +752,8 @@ static int gfs2_rename(struct inode *odi +diff --git a/fs/gfs2/ops_inode.c b/fs/gfs2/ops_inode.c +index 247436c..e650ccb 100644 +--- a/fs/gfs2/ops_inode.c ++++ b/fs/gfs2/ops_inode.c +@@ -752,6 +752,8 @@ static int gfs2_rename(struct inode *odir, struct de= ntry *odentry, unsigned int x; int error; =20 @@ -48414,10 +50364,11 @@ diff -urNp linux-2.6.32.49/fs/gfs2/ops_inode.c = linux-2.6.32.49/fs/gfs2/ops_inode if (ndentry->d_inode) { nip =3D GFS2_I(ndentry->d_inode); if (ip =3D=3D nip) -diff -urNp linux-2.6.32.49/fs/gfs2/sys.c linux-2.6.32.49/fs/gfs2/sys.c ---- linux-2.6.32.49/fs/gfs2/sys.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/gfs2/sys.c 2011-11-15 19:59:43.000000000 -0500 -@@ -49,7 +49,7 @@ static ssize_t gfs2_attr_store(struct ko +diff --git a/fs/gfs2/sys.c b/fs/gfs2/sys.c +index 4463297..4fed53b 100644 +--- a/fs/gfs2/sys.c ++++ b/fs/gfs2/sys.c +@@ -49,7 +49,7 @@ static ssize_t gfs2_attr_store(struct kobject *kobj, s= truct attribute *attr, return a->store ? a->store(sdp, buf, len) : len; } =20 @@ -48426,7 +50377,7 @@ diff -urNp linux-2.6.32.49/fs/gfs2/sys.c linux-2.= 6.32.49/fs/gfs2/sys.c .show =3D gfs2_attr_show, .store =3D gfs2_attr_store, }; -@@ -584,7 +584,7 @@ static int gfs2_uevent(struct kset *kset +@@ -584,7 +584,7 @@ static int gfs2_uevent(struct kset *kset, struct kob= ject *kobj, return 0; } =20 @@ -48435,10 +50386,11 @@ diff -urNp linux-2.6.32.49/fs/gfs2/sys.c linux-= 2.6.32.49/fs/gfs2/sys.c .uevent =3D gfs2_uevent, }; =20 -diff -urNp linux-2.6.32.49/fs/hfs/btree.c linux-2.6.32.49/fs/hfs/btree.c ---- linux-2.6.32.49/fs/hfs/btree.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/hfs/btree.c 2011-11-18 18:49:57.000000000 -0500 -@@ -45,11 +45,27 @@ struct hfs_btree *hfs_btree_open(struct=20 +diff --git a/fs/hfs/btree.c b/fs/hfs/btree.c +index 052f214..2462c5b 100644 +--- a/fs/hfs/btree.c ++++ b/fs/hfs/btree.c +@@ -45,11 +45,27 @@ struct hfs_btree *hfs_btree_open(struct super_block = *sb, u32 id, btree_keycmp ke case HFS_EXT_CNID: hfs_inode_read_fork(tree->inode, mdb->drXTExtRec, mdb->drXTFlSize, mdb->drXTFlSize, be32_to_cpu(mdb->drXTClpSiz)); @@ -48466,7 +50418,7 @@ diff -urNp linux-2.6.32.49/fs/hfs/btree.c linux-2= .6.32.49/fs/hfs/btree.c tree->inode->i_mapping->a_ops =3D &hfs_btree_aops; break; default: -@@ -58,11 +74,6 @@ struct hfs_btree *hfs_btree_open(struct=20 +@@ -58,11 +74,6 @@ struct hfs_btree *hfs_btree_open(struct super_block *= sb, u32 id, btree_keycmp ke } unlock_new_inode(tree->inode); =20 @@ -48478,10 +50430,11 @@ diff -urNp linux-2.6.32.49/fs/hfs/btree.c linux= -2.6.32.49/fs/hfs/btree.c mapping =3D tree->inode->i_mapping; page =3D read_mapping_page(mapping, 0, NULL); if (IS_ERR(page)) -diff -urNp linux-2.6.32.49/fs/hfsplus/catalog.c linux-2.6.32.49/fs/hfspl= us/catalog.c ---- linux-2.6.32.49/fs/hfsplus/catalog.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/hfsplus/catalog.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -157,6 +157,8 @@ int hfsplus_find_cat(struct super_block=20 +diff --git a/fs/hfsplus/catalog.c b/fs/hfsplus/catalog.c +index f6874ac..7cd98a8 100644 +--- a/fs/hfsplus/catalog.c ++++ b/fs/hfsplus/catalog.c +@@ -157,6 +157,8 @@ int hfsplus_find_cat(struct super_block *sb, u32 cni= d, int err; u16 type; =20 @@ -48490,7 +50443,7 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/catalog.c l= inux-2.6.32.49/fs/hfsplus/catal hfsplus_cat_build_key(sb, fd->search_key, cnid, NULL); err =3D hfs_brec_read(fd, &tmp, sizeof(hfsplus_cat_entry)); if (err) -@@ -186,6 +188,8 @@ int hfsplus_create_cat(u32 cnid, struct=20 +@@ -186,6 +188,8 @@ int hfsplus_create_cat(u32 cnid, struct inode *dir, = struct qstr *str, struct ino int entry_size; int err; =20 @@ -48508,10 +50461,11 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/catalog.c= linux-2.6.32.49/fs/hfsplus/catal dprint(DBG_CAT_MOD, "rename_cat: %u - %lu,%s - %lu,%s\n", cnid, src_di= r->i_ino, src_name->name, dst_dir->i_ino, dst_name->name); sb =3D src_dir->i_sb; -diff -urNp linux-2.6.32.49/fs/hfsplus/dir.c linux-2.6.32.49/fs/hfsplus/d= ir.c ---- linux-2.6.32.49/fs/hfsplus/dir.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/hfsplus/dir.c 2011-11-15 19:59:43.000000000 -0500 -@@ -121,6 +121,8 @@ static int hfsplus_readdir(struct file * +diff --git a/fs/hfsplus/dir.c b/fs/hfsplus/dir.c +index 5f40236..dac3421 100644 +--- a/fs/hfsplus/dir.c ++++ b/fs/hfsplus/dir.c +@@ -121,6 +121,8 @@ static int hfsplus_readdir(struct file *filp, void *= dirent, filldir_t filldir) struct hfsplus_readdir_data *rd; u16 type; =20 @@ -48520,10 +50474,11 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/dir.c lin= ux-2.6.32.49/fs/hfsplus/dir.c if (filp->f_pos >=3D inode->i_size) return 0; =20 -diff -urNp linux-2.6.32.49/fs/hfsplus/inode.c linux-2.6.32.49/fs/hfsplus= /inode.c ---- linux-2.6.32.49/fs/hfsplus/inode.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/hfsplus/inode.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -399,6 +399,8 @@ int hfsplus_cat_read_inode(struct inode=20 +diff --git a/fs/hfsplus/inode.c b/fs/hfsplus/inode.c +index 1bcf597..905a251 100644 +--- a/fs/hfsplus/inode.c ++++ b/fs/hfsplus/inode.c +@@ -399,6 +399,8 @@ int hfsplus_cat_read_inode(struct inode *inode, stru= ct hfs_find_data *fd) int res =3D 0; u16 type; =20 @@ -48532,7 +50487,7 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/inode.c lin= ux-2.6.32.49/fs/hfsplus/inode.c type =3D hfs_bnode_read_u16(fd->bnode, fd->entryoffset); =20 HFSPLUS_I(inode).dev =3D 0; -@@ -461,6 +463,8 @@ int hfsplus_cat_write_inode(struct inode +@@ -461,6 +463,8 @@ int hfsplus_cat_write_inode(struct inode *inode) struct hfs_find_data fd; hfsplus_cat_entry entry; =20 @@ -48541,10 +50496,11 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/inode.c l= inux-2.6.32.49/fs/hfsplus/inode.c if (HFSPLUS_IS_RSRC(inode)) main_inode =3D HFSPLUS_I(inode).rsrc_inode; =20 -diff -urNp linux-2.6.32.49/fs/hfsplus/ioctl.c linux-2.6.32.49/fs/hfsplus= /ioctl.c ---- linux-2.6.32.49/fs/hfsplus/ioctl.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/hfsplus/ioctl.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -101,6 +101,8 @@ int hfsplus_setxattr(struct dentry *dent +diff --git a/fs/hfsplus/ioctl.c b/fs/hfsplus/ioctl.c +index f457d2c..7ef4ad5 100644 +--- a/fs/hfsplus/ioctl.c ++++ b/fs/hfsplus/ioctl.c +@@ -101,6 +101,8 @@ int hfsplus_setxattr(struct dentry *dentry, const ch= ar *name, struct hfsplus_cat_file *file; int res; =20 @@ -48553,7 +50509,7 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/ioctl.c lin= ux-2.6.32.49/fs/hfsplus/ioctl.c if (!S_ISREG(inode->i_mode) || HFSPLUS_IS_RSRC(inode)) return -EOPNOTSUPP; =20 -@@ -143,6 +145,8 @@ ssize_t hfsplus_getxattr(struct dentry * +@@ -143,6 +145,8 @@ ssize_t hfsplus_getxattr(struct dentry *dentry, cons= t char *name, struct hfsplus_cat_file *file; ssize_t res =3D 0; =20 @@ -48562,10 +50518,11 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/ioctl.c l= inux-2.6.32.49/fs/hfsplus/ioctl.c if (!S_ISREG(inode->i_mode) || HFSPLUS_IS_RSRC(inode)) return -EOPNOTSUPP; =20 -diff -urNp linux-2.6.32.49/fs/hfsplus/super.c linux-2.6.32.49/fs/hfsplus= /super.c ---- linux-2.6.32.49/fs/hfsplus/super.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/hfsplus/super.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -312,6 +312,8 @@ static int hfsplus_fill_super(struct sup +diff --git a/fs/hfsplus/super.c b/fs/hfsplus/super.c +index 43022f3..7298079 100644 +--- a/fs/hfsplus/super.c ++++ b/fs/hfsplus/super.c +@@ -312,6 +312,8 @@ static int hfsplus_fill_super(struct super_block *sb= , void *data, int silent) struct nls_table *nls =3D NULL; int err =3D -EINVAL; =20 @@ -48574,10 +50531,11 @@ diff -urNp linux-2.6.32.49/fs/hfsplus/super.c l= inux-2.6.32.49/fs/hfsplus/super.c sbi =3D kzalloc(sizeof(*sbi), GFP_KERNEL); if (!sbi) return -ENOMEM; -diff -urNp linux-2.6.32.49/fs/hugetlbfs/inode.c linux-2.6.32.49/fs/huget= lbfs/inode.c ---- linux-2.6.32.49/fs/hugetlbfs/inode.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/hugetlbfs/inode.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -909,7 +909,7 @@ static struct file_system_type hugetlbfs +diff --git a/fs/hugetlbfs/inode.c b/fs/hugetlbfs/inode.c +index 87a1258..5694d91 100644 +--- a/fs/hugetlbfs/inode.c ++++ b/fs/hugetlbfs/inode.c +@@ -909,7 +909,7 @@ static struct file_system_type hugetlbfs_fs_type =3D= { .kill_sb =3D kill_litter_super, }; =20 @@ -48586,10 +50544,11 @@ diff -urNp linux-2.6.32.49/fs/hugetlbfs/inode.c= linux-2.6.32.49/fs/hugetlbfs/ino =20 static int can_do_hugetlb_shm(void) { -diff -urNp linux-2.6.32.49/fs/ioctl.c linux-2.6.32.49/fs/ioctl.c ---- linux-2.6.32.49/fs/ioctl.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ioctl.c 2011-11-15 19:59:43.000000000 -0500 -@@ -97,7 +97,7 @@ int fiemap_fill_next_extent(struct fiema +diff --git a/fs/ioctl.c b/fs/ioctl.c +index 6c75110..19d2c3c 100644 +--- a/fs/ioctl.c ++++ b/fs/ioctl.c +@@ -97,7 +97,7 @@ int fiemap_fill_next_extent(struct fiemap_extent_info = *fieinfo, u64 logical, u64 phys, u64 len, u32 flags) { struct fiemap_extent extent; @@ -48598,7 +50557,7 @@ diff -urNp linux-2.6.32.49/fs/ioctl.c linux-2.6.3= 2.49/fs/ioctl.c =20 /* only count the extents */ if (fieinfo->fi_extents_max =3D=3D 0) { -@@ -207,7 +207,7 @@ static int ioctl_fiemap(struct file *fil +@@ -207,7 +207,7 @@ static int ioctl_fiemap(struct file *filp, unsigned = long arg) =20 fieinfo.fi_flags =3D fiemap.fm_flags; fieinfo.fi_extents_max =3D fiemap.fm_extent_count; @@ -48607,7 +50566,7 @@ diff -urNp linux-2.6.32.49/fs/ioctl.c linux-2.6.3= 2.49/fs/ioctl.c =20 if (fiemap.fm_extent_count !=3D 0 && !access_ok(VERIFY_WRITE, fieinfo.fi_extents_start, -@@ -220,7 +220,7 @@ static int ioctl_fiemap(struct file *fil +@@ -220,7 +220,7 @@ static int ioctl_fiemap(struct file *filp, unsigned = long arg) error =3D inode->i_op->fiemap(inode, &fieinfo, fiemap.fm_start, len); fiemap.fm_flags =3D fieinfo.fi_flags; fiemap.fm_mapped_extents =3D fieinfo.fi_extents_mapped; @@ -48616,10 +50575,11 @@ diff -urNp linux-2.6.32.49/fs/ioctl.c linux-2.6= .32.49/fs/ioctl.c error =3D -EFAULT; =20 return error; -diff -urNp linux-2.6.32.49/fs/jbd/checkpoint.c linux-2.6.32.49/fs/jbd/ch= eckpoint.c ---- linux-2.6.32.49/fs/jbd/checkpoint.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/jbd/checkpoint.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -348,6 +348,8 @@ int log_do_checkpoint(journal_t *journal +diff --git a/fs/jbd/checkpoint.c b/fs/jbd/checkpoint.c +index b0435dd..81ee0be 100644 +--- a/fs/jbd/checkpoint.c ++++ b/fs/jbd/checkpoint.c +@@ -348,6 +348,8 @@ int log_do_checkpoint(journal_t *journal) tid_t this_tid; int result; =20 @@ -48628,10 +50588,11 @@ diff -urNp linux-2.6.32.49/fs/jbd/checkpoint.c = linux-2.6.32.49/fs/jbd/checkpoint jbd_debug(1, "Start checkpoint\n"); =20 /* -diff -urNp linux-2.6.32.49/fs/jffs2/compr_rtime.c linux-2.6.32.49/fs/jff= s2/compr_rtime.c ---- linux-2.6.32.49/fs/jffs2/compr_rtime.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/fs/jffs2/compr_rtime.c 2011-11-15 19:59:43.000000000= -0500 -@@ -37,6 +37,8 @@ static int jffs2_rtime_compress(unsigned +diff --git a/fs/jffs2/compr_rtime.c b/fs/jffs2/compr_rtime.c +index 546d153..736896c 100644 +--- a/fs/jffs2/compr_rtime.c ++++ b/fs/jffs2/compr_rtime.c +@@ -37,6 +37,8 @@ static int jffs2_rtime_compress(unsigned char *data_in= , int outpos =3D 0; int pos=3D0; =20 @@ -48640,7 +50601,7 @@ diff -urNp linux-2.6.32.49/fs/jffs2/compr_rtime.c= linux-2.6.32.49/fs/jffs2/compr memset(positions,0,sizeof(positions)); =20 while (pos < (*sourcelen) && outpos <=3D (*dstlen)-2) { -@@ -79,6 +81,8 @@ static int jffs2_rtime_decompress(unsign +@@ -79,6 +81,8 @@ static int jffs2_rtime_decompress(unsigned char *data_= in, int outpos =3D 0; int pos=3D0; =20 @@ -48649,10 +50610,11 @@ diff -urNp linux-2.6.32.49/fs/jffs2/compr_rtime= .c linux-2.6.32.49/fs/jffs2/compr memset(positions,0,sizeof(positions)); =20 while (outposflags & JFFS2_SB_FLAG_BUILDING)); =20 @@ -48699,9 +50664,10 @@ diff -urNp linux-2.6.32.49/fs/jffs2/xattr.c linu= x-2.6.32.49/fs/jffs2/xattr.c /* Phase.1 : Merge same xref */ for (i=3D0; i < XREF_TMPHASH_SIZE; i++) xref_tmphash[i] =3D NULL; -diff -urNp linux-2.6.32.49/fs/jfs/super.c linux-2.6.32.49/fs/jfs/super.c ---- linux-2.6.32.49/fs/jfs/super.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/jfs/super.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/jfs/super.c b/fs/jfs/super.c +index 2234c73..f6e6e6b 100644 +--- a/fs/jfs/super.c ++++ b/fs/jfs/super.c @@ -793,7 +793,7 @@ static int __init init_jfs_fs(void) =20 jfs_inode_cachep =3D @@ -48711,22 +50677,11 @@ diff -urNp linux-2.6.32.49/fs/jfs/super.c linux= -2.6.32.49/fs/jfs/super.c init_once); if (jfs_inode_cachep =3D=3D NULL) return -ENOMEM; -diff -urNp linux-2.6.32.49/fs/Kconfig.binfmt linux-2.6.32.49/fs/Kconfig.= binfmt ---- linux-2.6.32.49/fs/Kconfig.binfmt 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/Kconfig.binfmt 2011-11-15 19:59:43.000000000 -050= 0 -@@ -86,7 +86,7 @@ config HAVE_AOUT -=20 - config BINFMT_AOUT - tristate "Kernel support for a.out and ECOFF binaries" -- depends on HAVE_AOUT -+ depends on HAVE_AOUT && BROKEN - ---help--- - A.out (Assembler.OUTput) is a set of formats for libraries and - executables used in the earliest versions of UNIX. Linux used -diff -urNp linux-2.6.32.49/fs/libfs.c linux-2.6.32.49/fs/libfs.c ---- linux-2.6.32.49/fs/libfs.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/libfs.c 2011-11-15 19:59:43.000000000 -0500 -@@ -157,12 +157,20 @@ int dcache_readdir(struct file * filp, v +diff --git a/fs/libfs.c b/fs/libfs.c +index ba36e93..3153fce 100644 +--- a/fs/libfs.c ++++ b/fs/libfs.c +@@ -157,12 +157,20 @@ int dcache_readdir(struct file * filp, void * dire= nt, filldir_t filldir) =20 for (p=3Dq->next; p !=3D &dentry->d_subdirs; p=3Dp->next) { struct dentry *next; @@ -48748,10 +50703,11 @@ diff -urNp linux-2.6.32.49/fs/libfs.c linux-2.6= .32.49/fs/libfs.c next->d_name.len, filp->f_pos,=20 next->d_inode->i_ino,=20 dt_type(next->d_inode)) < 0) -diff -urNp linux-2.6.32.49/fs/lockd/clntproc.c linux-2.6.32.49/fs/lockd/= clntproc.c ---- linux-2.6.32.49/fs/lockd/clntproc.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/lockd/clntproc.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -36,11 +36,11 @@ static const struct rpc_call_ops nlmclnt +diff --git a/fs/lockd/clntproc.c b/fs/lockd/clntproc.c +index c325a83..d15b07b 100644 +--- a/fs/lockd/clntproc.c ++++ b/fs/lockd/clntproc.c +@@ -36,11 +36,11 @@ static const struct rpc_call_ops nlmclnt_cancel_ops; /* * Cookie counter for NLM requests */ @@ -48765,7 +50721,7 @@ diff -urNp linux-2.6.32.49/fs/lockd/clntproc.c li= nux-2.6.32.49/fs/lockd/clntproc =20 memcpy(c->data, &cookie, 4); c->len=3D4; -@@ -621,6 +621,8 @@ nlmclnt_reclaim(struct nlm_host *host, s +@@ -621,6 +621,8 @@ nlmclnt_reclaim(struct nlm_host *host, struct file_l= ock *fl) struct nlm_rqst reqst, *req; int status; =20 @@ -48774,9 +50730,10 @@ diff -urNp linux-2.6.32.49/fs/lockd/clntproc.c l= inux-2.6.32.49/fs/lockd/clntproc req =3D &reqst; memset(req, 0, sizeof(*req)); locks_init_lock(&req->a_args.lock.fl); -diff -urNp linux-2.6.32.49/fs/lockd/svc.c linux-2.6.32.49/fs/lockd/svc.c ---- linux-2.6.32.49/fs/lockd/svc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/lockd/svc.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/lockd/svc.c b/fs/lockd/svc.c +index 1a54ae1..6a16c27 100644 +--- a/fs/lockd/svc.c ++++ b/fs/lockd/svc.c @@ -43,7 +43,7 @@ =20 static struct svc_program nlmsvc_program; @@ -48786,9 +50743,10 @@ diff -urNp linux-2.6.32.49/fs/lockd/svc.c linux-= 2.6.32.49/fs/lockd/svc.c EXPORT_SYMBOL_GPL(nlmsvc_ops); =20 static DEFINE_MUTEX(nlmsvc_mutex); -diff -urNp linux-2.6.32.49/fs/locks.c linux-2.6.32.49/fs/locks.c ---- linux-2.6.32.49/fs/locks.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/locks.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/locks.c b/fs/locks.c +index a8794f2..4041e55 100644 +--- a/fs/locks.c ++++ b/fs/locks.c @@ -145,10 +145,28 @@ static LIST_HEAD(blocked_list); =20 static struct kmem_cache *filelock_cache __read_mostly; @@ -48819,7 +50777,7 @@ diff -urNp linux-2.6.32.49/fs/locks.c linux-2.6.3= 2.49/fs/locks.c } =20 void locks_release_private(struct file_lock *fl) -@@ -183,17 +201,9 @@ void locks_init_lock(struct file_lock *f +@@ -183,17 +201,9 @@ void locks_init_lock(struct file_lock *fl) INIT_LIST_HEAD(&fl->fl_link); INIT_LIST_HEAD(&fl->fl_block); init_waitqueue_head(&fl->fl_wait); @@ -48838,7 +50796,7 @@ diff -urNp linux-2.6.32.49/fs/locks.c linux-2.6.3= 2.49/fs/locks.c } =20 EXPORT_SYMBOL(locks_init_lock); -@@ -2007,16 +2017,16 @@ void locks_remove_flock(struct file *fil +@@ -2007,16 +2017,16 @@ void locks_remove_flock(struct file *filp) return; =20 if (filp->f_op && filp->f_op->flock) { @@ -48859,10 +50817,11 @@ diff -urNp linux-2.6.32.49/fs/locks.c linux-2.6= .32.49/fs/locks.c } =20 lock_kernel(); -diff -urNp linux-2.6.32.49/fs/mbcache.c linux-2.6.32.49/fs/mbcache.c ---- linux-2.6.32.49/fs/mbcache.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/mbcache.c 2011-11-15 19:59:43.000000000 -0500 -@@ -266,9 +266,9 @@ mb_cache_create(const char *name, struct +diff --git a/fs/mbcache.c b/fs/mbcache.c +index ec88ff3..b843a82 100644 +--- a/fs/mbcache.c ++++ b/fs/mbcache.c +@@ -266,9 +266,9 @@ mb_cache_create(const char *name, struct mb_cache_op= *cache_op, if (!cache) goto fail; cache->c_name =3D name; @@ -48874,10 +50833,11 @@ diff -urNp linux-2.6.32.49/fs/mbcache.c linux-2= .6.32.49/fs/mbcache.c atomic_set(&cache->c_entry_count, 0); cache->c_bucket_bits =3D bucket_bits; #ifdef MB_CACHE_INDEXES_COUNT -diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.32.49/fs/namei.c ---- linux-2.6.32.49/fs/namei.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/namei.c 2011-11-18 19:36:31.000000000 -0500 -@@ -224,14 +224,6 @@ int generic_permission(struct inode *ino +diff --git a/fs/namei.c b/fs/namei.c +index b0afbd4..8d065a1 100644 +--- a/fs/namei.c ++++ b/fs/namei.c +@@ -224,14 +224,6 @@ int generic_permission(struct inode *inode, int mas= k, return ret; =20 /* @@ -48892,7 +50852,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c * Searching includes executable on directories, else just read. */ mask &=3D MAY_READ | MAY_WRITE | MAY_EXEC; -@@ -239,6 +231,14 @@ int generic_permission(struct inode *ino +@@ -239,6 +231,14 @@ int generic_permission(struct inode *inode, int mas= k, if (capable(CAP_DAC_READ_SEARCH)) return 0; =20 @@ -48907,7 +50867,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c return -EACCES; } =20 -@@ -458,7 +458,8 @@ static int exec_permission_lite(struct i +@@ -458,7 +458,8 @@ static int exec_permission_lite(struct inode *inode) if (!ret) goto ok; =20 @@ -48917,7 +50877,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c goto ok; =20 return ret; -@@ -638,7 +639,7 @@ static __always_inline int __do_follow_l +@@ -638,7 +639,7 @@ static __always_inline int __do_follow_link(struct p= ath *path, struct nameidata cookie =3D dentry->d_inode->i_op->follow_link(dentry, nd); error =3D PTR_ERR(cookie); if (!IS_ERR(cookie)) { @@ -48926,7 +50886,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D 0; if (s) error =3D __vfs_follow_link(nd, s); -@@ -669,6 +670,13 @@ static inline int do_follow_link(struct=20 +@@ -669,6 +670,13 @@ static inline int do_follow_link(struct path *path,= struct nameidata *nd) err =3D security_inode_follow_link(path->dentry, nd); if (err) goto loop; @@ -48960,7 +50920,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c path_put(&nd->path); return_err: return err; -@@ -1091,13 +1107,20 @@ static int do_path_lookup(int dfd, const +@@ -1091,13 +1107,20 @@ static int do_path_lookup(int dfd, const char *n= ame, int retval =3D path_init(dfd, name, flags, nd); if (!retval) retval =3D path_walk(name, nd); @@ -48984,7 +50944,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c return retval; } =20 -@@ -1576,6 +1599,20 @@ int may_open(struct path *path, int acc_ +@@ -1576,6 +1599,20 @@ int may_open(struct path *path, int acc_mode, int= flag) if (error) goto err_out; =20 @@ -49005,7 +50965,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c if (flag & O_TRUNC) { error =3D get_write_access(inode); if (error) -@@ -1620,6 +1657,17 @@ static int __open_namei_create(struct na +@@ -1620,6 +1657,17 @@ static int __open_namei_create(struct nameidata *= nd, struct path *path, { int error; struct dentry *dir =3D nd->path.dentry; @@ -49023,7 +50983,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c =20 if (!IS_POSIXACL(dir->d_inode)) mode &=3D ~current_umask(); -@@ -1627,6 +1675,8 @@ static int __open_namei_create(struct na +@@ -1627,6 +1675,8 @@ static int __open_namei_create(struct nameidata *n= d, struct path *path, if (error) goto out_unlock; error =3D vfs_create(dir->d_inode, path->dentry, mode, nd); @@ -49032,7 +50992,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c out_unlock: mutex_unlock(&dir->d_inode->i_mutex); dput(nd->path.dentry); -@@ -1709,6 +1759,22 @@ struct file *do_filp_open(int dfd, const +@@ -1709,6 +1759,22 @@ struct file *do_filp_open(int dfd, const char *pa= thname, &nd, flag); if (error) return ERR_PTR(error); @@ -49089,7 +51049,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D __do_follow_link(&path, &nd); if (error) { /* Does someone understand code flow here? Or it is only -@@ -1984,6 +2070,10 @@ struct dentry *lookup_create(struct name +@@ -1984,6 +2070,10 @@ struct dentry *lookup_create(struct nameidata *nd= , int is_dir) } return dentry; eexist: @@ -49100,7 +51060,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c dput(dentry); dentry =3D ERR_PTR(-EEXIST); fail: -@@ -2061,6 +2151,17 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const +@@ -2061,6 +2151,17 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const char __u= ser *, filename, int, mode, error =3D may_mknod(mode); if (error) goto out_dput; @@ -49118,7 +51078,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D mnt_want_write(nd.path.mnt); if (error) goto out_dput; -@@ -2081,6 +2182,9 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const +@@ -2081,6 +2182,9 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const char __us= er *, filename, int, mode, } out_drop_write: mnt_drop_write(nd.path.mnt); @@ -49128,7 +51088,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c out_dput: dput(dentry); out_unlock: -@@ -2134,6 +2238,11 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const +@@ -2134,6 +2238,11 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const char __u= ser *, pathname, int, mode) if (IS_ERR(dentry)) goto out_unlock; =20 @@ -49140,7 +51100,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c if (!IS_POSIXACL(nd.path.dentry->d_inode)) mode &=3D ~current_umask(); error =3D mnt_want_write(nd.path.mnt); -@@ -2145,6 +2254,10 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const +@@ -2145,6 +2254,10 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const char __u= ser *, pathname, int, mode) error =3D vfs_mkdir(nd.path.dentry->d_inode, dentry, mode); out_drop_write: mnt_drop_write(nd.path.mnt); @@ -49151,7 +51111,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c out_dput: dput(dentry); out_unlock: -@@ -2226,6 +2339,8 @@ static long do_rmdir(int dfd, const char +@@ -2226,6 +2339,8 @@ static long do_rmdir(int dfd, const char __user *p= athname) char * name; struct dentry *dentry; struct nameidata nd; @@ -49160,7 +51120,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c =20 error =3D user_path_parent(dfd, pathname, &nd, &name); if (error) -@@ -2250,6 +2365,17 @@ static long do_rmdir(int dfd, const char +@@ -2250,6 +2365,17 @@ static long do_rmdir(int dfd, const char __user *= pathname) error =3D PTR_ERR(dentry); if (IS_ERR(dentry)) goto exit2; @@ -49178,7 +51138,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D mnt_want_write(nd.path.mnt); if (error) goto exit3; -@@ -2257,6 +2383,8 @@ static long do_rmdir(int dfd, const char +@@ -2257,6 +2383,8 @@ static long do_rmdir(int dfd, const char __user *p= athname) if (error) goto exit4; error =3D vfs_rmdir(nd.path.dentry->d_inode, dentry); @@ -49187,7 +51147,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c exit4: mnt_drop_write(nd.path.mnt); exit3: -@@ -2318,6 +2446,8 @@ static long do_unlinkat(int dfd, const c +@@ -2318,6 +2446,8 @@ static long do_unlinkat(int dfd, const char __user= *pathname) struct dentry *dentry; struct nameidata nd; struct inode *inode =3D NULL; @@ -49196,7 +51156,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c =20 error =3D user_path_parent(dfd, pathname, &nd, &name); if (error) -@@ -2337,8 +2467,19 @@ static long do_unlinkat(int dfd, const c +@@ -2337,8 +2467,19 @@ static long do_unlinkat(int dfd, const char __use= r *pathname) if (nd.last.name[nd.last.len]) goto slashes; inode =3D dentry->d_inode; @@ -49217,7 +51177,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D mnt_want_write(nd.path.mnt); if (error) goto exit2; -@@ -2346,6 +2487,8 @@ static long do_unlinkat(int dfd, const c +@@ -2346,6 +2487,8 @@ static long do_unlinkat(int dfd, const char __user= *pathname) if (error) goto exit3; error =3D vfs_unlink(nd.path.dentry->d_inode, dentry); @@ -49226,7 +51186,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c exit3: mnt_drop_write(nd.path.mnt); exit2: -@@ -2424,6 +2567,11 @@ SYSCALL_DEFINE3(symlinkat, const char __ +@@ -2424,6 +2567,11 @@ SYSCALL_DEFINE3(symlinkat, const char __user *, o= ldname, if (IS_ERR(dentry)) goto out_unlock; =20 @@ -49238,7 +51198,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D mnt_want_write(nd.path.mnt); if (error) goto out_dput; -@@ -2431,6 +2579,8 @@ SYSCALL_DEFINE3(symlinkat, const char __ +@@ -2431,6 +2579,8 @@ SYSCALL_DEFINE3(symlinkat, const char __user *, ol= dname, if (error) goto out_drop_write; error =3D vfs_symlink(nd.path.dentry->d_inode, dentry, from); @@ -49247,7 +51207,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c out_drop_write: mnt_drop_write(nd.path.mnt); out_dput: -@@ -2524,6 +2674,20 @@ SYSCALL_DEFINE5(linkat, int, olddfd, con +@@ -2524,6 +2674,20 @@ SYSCALL_DEFINE5(linkat, int, olddfd, const char _= _user *, oldname, error =3D PTR_ERR(new_dentry); if (IS_ERR(new_dentry)) goto out_unlock; @@ -49268,7 +51228,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D mnt_want_write(nd.path.mnt); if (error) goto out_dput; -@@ -2531,6 +2695,8 @@ SYSCALL_DEFINE5(linkat, int, olddfd, con +@@ -2531,6 +2695,8 @@ SYSCALL_DEFINE5(linkat, int, olddfd, const char __= user *, oldname, if (error) goto out_drop_write; error =3D vfs_link(old_path.dentry, nd.path.dentry->d_inode, new_dentr= y); @@ -49277,7 +51237,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c out_drop_write: mnt_drop_write(nd.path.mnt); out_dput: -@@ -2708,6 +2874,8 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -2708,6 +2874,8 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char = __user *, oldname, char *to; int error; =20 @@ -49286,7 +51246,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D user_path_parent(olddfd, oldname, &oldnd, &from); if (error) goto exit; -@@ -2764,6 +2932,12 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -2764,6 +2932,12 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char= __user *, oldname, if (new_dentry =3D=3D trap) goto exit5; =20 @@ -49299,7 +51259,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c error =3D mnt_want_write(oldnd.path.mnt); if (error) goto exit5; -@@ -2773,6 +2947,9 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -2773,6 +2947,9 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char = __user *, oldname, goto exit6; error =3D vfs_rename(old_dir->d_inode, old_dentry, new_dir->d_inode, new_dentry); @@ -49309,7 +51269,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c exit6: mnt_drop_write(oldnd.path.mnt); exit5: -@@ -2798,6 +2975,8 @@ SYSCALL_DEFINE2(rename, const char __use +@@ -2798,6 +2975,8 @@ SYSCALL_DEFINE2(rename, const char __user *, oldna= me, const char __user *, newna =20 int vfs_readlink(struct dentry *dentry, char __user *buffer, int buflen= , const char *link) { @@ -49318,7 +51278,7 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6.3= 2.49/fs/namei.c int len; =20 len =3D PTR_ERR(link); -@@ -2807,7 +2986,14 @@ int vfs_readlink(struct dentry *dentry,=20 +@@ -2807,7 +2986,14 @@ int vfs_readlink(struct dentry *dentry, char __us= er *buffer, int buflen, const c len =3D strlen(link); if (len > (unsigned) buflen) len =3D buflen; @@ -49334,10 +51294,11 @@ diff -urNp linux-2.6.32.49/fs/namei.c linux-2.6= .32.49/fs/namei.c len =3D -EFAULT; out: return len; -diff -urNp linux-2.6.32.49/fs/namespace.c linux-2.6.32.49/fs/namespace.c ---- linux-2.6.32.49/fs/namespace.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/namespace.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1083,6 +1083,9 @@ static int do_umount(struct vfsmount *mn +diff --git a/fs/namespace.c b/fs/namespace.c +index 2beb0fb..11a95a5 100644 +--- a/fs/namespace.c ++++ b/fs/namespace.c +@@ -1083,6 +1083,9 @@ static int do_umount(struct vfsmount *mnt, int fla= gs) if (!(sb->s_flags & MS_RDONLY)) retval =3D do_remount_sb(sb, MS_RDONLY, NULL, 0); up_write(&sb->s_umount); @@ -49347,7 +51308,7 @@ diff -urNp linux-2.6.32.49/fs/namespace.c linux-2= .6.32.49/fs/namespace.c return retval; } =20 -@@ -1104,6 +1107,9 @@ static int do_umount(struct vfsmount *mn +@@ -1104,6 +1107,9 @@ static int do_umount(struct vfsmount *mnt, int fla= gs) security_sb_umount_busy(mnt); up_write(&namespace_sem); release_mounts(&umount_list); @@ -49357,7 +51318,7 @@ diff -urNp linux-2.6.32.49/fs/namespace.c linux-2= .6.32.49/fs/namespace.c return retval; } =20 -@@ -1962,6 +1968,16 @@ long do_mount(char *dev_name, char *dir_ +@@ -1962,6 +1968,16 @@ long do_mount(char *dev_name, char *dir_name, cha= r *type_page, if (retval) goto dput_out; =20 @@ -49374,7 +51335,7 @@ diff -urNp linux-2.6.32.49/fs/namespace.c linux-2= .6.32.49/fs/namespace.c if (flags & MS_REMOUNT) retval =3D do_remount(&path, flags & ~MS_REMOUNT, mnt_flags, data_page); -@@ -1976,6 +1992,9 @@ long do_mount(char *dev_name, char *dir_ +@@ -1976,6 +1992,9 @@ long do_mount(char *dev_name, char *dir_name, char= *type_page, dev_name, data_page); dput_out: path_put(&path); @@ -49384,7 +51345,7 @@ diff -urNp linux-2.6.32.49/fs/namespace.c linux-2= .6.32.49/fs/namespace.c return retval; } =20 -@@ -2182,6 +2201,12 @@ SYSCALL_DEFINE2(pivot_root, const char _ +@@ -2182,6 +2201,12 @@ SYSCALL_DEFINE2(pivot_root, const char __user *, = new_root, goto out1; } =20 @@ -49397,10 +51358,11 @@ diff -urNp linux-2.6.32.49/fs/namespace.c linux= -2.6.32.49/fs/namespace.c read_lock(¤t->fs->lock); root =3D current->fs->root; path_get(¤t->fs->root); -diff -urNp linux-2.6.32.49/fs/ncpfs/dir.c linux-2.6.32.49/fs/ncpfs/dir.c ---- linux-2.6.32.49/fs/ncpfs/dir.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ncpfs/dir.c 2011-11-15 19:59:43.000000000 -0500 -@@ -275,6 +275,8 @@ __ncp_lookup_validate(struct dentry *den +diff --git a/fs/ncpfs/dir.c b/fs/ncpfs/dir.c +index b8b5b30..2bd9ccb 100644 +--- a/fs/ncpfs/dir.c ++++ b/fs/ncpfs/dir.c +@@ -275,6 +275,8 @@ __ncp_lookup_validate(struct dentry *dentry) int res, val =3D 0, len; __u8 __name[NCP_MAXPATHLEN + 1]; =20 @@ -49409,7 +51371,7 @@ diff -urNp linux-2.6.32.49/fs/ncpfs/dir.c linux-2= .6.32.49/fs/ncpfs/dir.c parent =3D dget_parent(dentry); dir =3D parent->d_inode; =20 -@@ -799,6 +801,8 @@ static struct dentry *ncp_lookup(struct=20 +@@ -799,6 +801,8 @@ static struct dentry *ncp_lookup(struct inode *dir, = struct dentry *dentry, struc int error, res, len; __u8 __name[NCP_MAXPATHLEN + 1]; =20 @@ -49418,7 +51380,7 @@ diff -urNp linux-2.6.32.49/fs/ncpfs/dir.c linux-2= .6.32.49/fs/ncpfs/dir.c lock_kernel(); error =3D -EIO; if (!ncp_conn_valid(server)) -@@ -883,10 +887,12 @@ int ncp_create_new(struct inode *dir, st +@@ -883,10 +887,12 @@ int ncp_create_new(struct inode *dir, struct dentr= y *dentry, int mode, int error, result, len; int opmode; __u8 __name[NCP_MAXPATHLEN + 1]; @@ -49432,7 +51394,7 @@ diff -urNp linux-2.6.32.49/fs/ncpfs/dir.c linux-2= .6.32.49/fs/ncpfs/dir.c error =3D -EIO; lock_kernel(); if (!ncp_conn_valid(server)) -@@ -952,6 +958,8 @@ static int ncp_mkdir(struct inode *dir,=20 +@@ -952,6 +958,8 @@ static int ncp_mkdir(struct inode *dir, struct dentr= y *dentry, int mode) int error, len; __u8 __name[NCP_MAXPATHLEN + 1]; =20 @@ -49441,7 +51403,7 @@ diff -urNp linux-2.6.32.49/fs/ncpfs/dir.c linux-2= .6.32.49/fs/ncpfs/dir.c DPRINTK("ncp_mkdir: making %s/%s\n", dentry->d_parent->d_name.name, dentry->d_name.name); =20 -@@ -960,6 +968,8 @@ static int ncp_mkdir(struct inode *dir,=20 +@@ -960,6 +968,8 @@ static int ncp_mkdir(struct inode *dir, struct dentr= y *dentry, int mode) if (!ncp_conn_valid(server)) goto out; =20 @@ -49450,7 +51412,7 @@ diff -urNp linux-2.6.32.49/fs/ncpfs/dir.c linux-2= .6.32.49/fs/ncpfs/dir.c ncp_age_dentry(server, dentry); len =3D sizeof(__name); error =3D ncp_io2vol(server, __name, &len, dentry->d_name.name, -@@ -1114,6 +1124,8 @@ static int ncp_rename(struct inode *old_ +@@ -1114,6 +1124,8 @@ static int ncp_rename(struct inode *old_dir, struc= t dentry *old_dentry, int old_len, new_len; __u8 __old_name[NCP_MAXPATHLEN + 1], __new_name[NCP_MAXPATHLEN + 1]; =20 @@ -49459,10 +51421,11 @@ diff -urNp linux-2.6.32.49/fs/ncpfs/dir.c linux= -2.6.32.49/fs/ncpfs/dir.c DPRINTK("ncp_rename: %s/%s to %s/%s\n", old_dentry->d_parent->d_name.name, old_dentry->d_name.name, new_dentry->d_parent->d_name.name, new_dentry->d_name.name); -diff -urNp linux-2.6.32.49/fs/ncpfs/inode.c linux-2.6.32.49/fs/ncpfs/ino= de.c ---- linux-2.6.32.49/fs/ncpfs/inode.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ncpfs/inode.c 2011-11-15 19:59:43.000000000 -0500 -@@ -445,6 +445,8 @@ static int ncp_fill_super(struct super_b +diff --git a/fs/ncpfs/inode.c b/fs/ncpfs/inode.c +index cf98da1..da890a9 100644 +--- a/fs/ncpfs/inode.c ++++ b/fs/ncpfs/inode.c +@@ -445,6 +445,8 @@ static int ncp_fill_super(struct super_block *sb, vo= id *raw_data, int silent) #endif struct ncp_entry_info finfo; =20 @@ -49471,10 +51434,11 @@ diff -urNp linux-2.6.32.49/fs/ncpfs/inode.c lin= ux-2.6.32.49/fs/ncpfs/inode.c data.wdog_pid =3D NULL; server =3D kzalloc(sizeof(struct ncp_server), GFP_KERNEL); if (!server) -diff -urNp linux-2.6.32.49/fs/nfs/inode.c linux-2.6.32.49/fs/nfs/inode.c ---- linux-2.6.32.49/fs/nfs/inode.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/nfs/inode.c 2011-11-15 19:59:43.000000000 -0500 -@@ -156,7 +156,7 @@ static void nfs_zap_caches_locked(struct +diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c +index bfaef7b..e9d03ca 100644 +--- a/fs/nfs/inode.c ++++ b/fs/nfs/inode.c +@@ -156,7 +156,7 @@ static void nfs_zap_caches_locked(struct inode *inod= e) nfsi->attrtimeo =3D NFS_MINATTRTIMEO(inode); nfsi->attrtimeo_timestamp =3D jiffies; =20 @@ -49483,7 +51447,7 @@ diff -urNp linux-2.6.32.49/fs/nfs/inode.c linux-2= .6.32.49/fs/nfs/inode.c if (S_ISREG(mode) || S_ISDIR(mode) || S_ISLNK(mode)) nfsi->cache_validity |=3D NFS_INO_INVALID_ATTR|NFS_INO_INVALID_DATA|N= FS_INO_INVALID_ACCESS|NFS_INO_INVALID_ACL|NFS_INO_REVAL_PAGECACHE; else -@@ -973,16 +973,16 @@ static int nfs_size_need_update(const st +@@ -973,16 +973,16 @@ static int nfs_size_need_update(const struct inode= *inode, const struct nfs_fatt return nfs_size_to_loff_t(fattr->size) > i_size_read(inode); } =20 @@ -49503,9 +51467,10 @@ diff -urNp linux-2.6.32.49/fs/nfs/inode.c linux-= 2.6.32.49/fs/nfs/inode.c } =20 void nfs_fattr_init(struct nfs_fattr *fattr) -diff -urNp linux-2.6.32.49/fs/nfsd/lockd.c linux-2.6.32.49/fs/nfsd/lockd= .c ---- linux-2.6.32.49/fs/nfsd/lockd.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/nfsd/lockd.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/nfsd/lockd.c b/fs/nfsd/lockd.c +index cc2f505..f6a236f 100644 +--- a/fs/nfsd/lockd.c ++++ b/fs/nfsd/lockd.c @@ -66,7 +66,7 @@ nlm_fclose(struct file *filp) fput(filp); } @@ -49515,10 +51480,11 @@ diff -urNp linux-2.6.32.49/fs/nfsd/lockd.c linu= x-2.6.32.49/fs/nfsd/lockd.c .fopen =3D nlm_fopen, /* open file for locking */ .fclose =3D nlm_fclose, /* close file */ }; -diff -urNp linux-2.6.32.49/fs/nfsd/nfs4state.c linux-2.6.32.49/fs/nfsd/n= fs4state.c ---- linux-2.6.32.49/fs/nfsd/nfs4state.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/nfsd/nfs4state.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -3459,6 +3459,8 @@ nfsd4_lock(struct svc_rqst *rqstp, struc +diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c +index cfc3391..dcc083a 100644 +--- a/fs/nfsd/nfs4state.c ++++ b/fs/nfsd/nfs4state.c +@@ -3459,6 +3459,8 @@ nfsd4_lock(struct svc_rqst *rqstp, struct nfsd4_co= mpound_state *cstate, unsigned int cmd; int err; =20 @@ -49527,10 +51493,11 @@ diff -urNp linux-2.6.32.49/fs/nfsd/nfs4state.c = linux-2.6.32.49/fs/nfsd/nfs4state dprintk("NFSD: nfsd4_lock: start=3D%Ld length=3D%Ld\n", (long long) lock->lk_offset, (long long) lock->lk_length); -diff -urNp linux-2.6.32.49/fs/nfsd/nfs4xdr.c linux-2.6.32.49/fs/nfsd/nfs= 4xdr.c ---- linux-2.6.32.49/fs/nfsd/nfs4xdr.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/nfsd/nfs4xdr.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -1751,6 +1751,8 @@ nfsd4_encode_fattr(struct svc_fh *fhp, s +diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c +index 4a82a96..0d5fb49 100644 +--- a/fs/nfsd/nfs4xdr.c ++++ b/fs/nfsd/nfs4xdr.c +@@ -1751,6 +1751,8 @@ nfsd4_encode_fattr(struct svc_fh *fhp, struct svc_= export *exp, struct nfsd4_compoundres *resp =3D rqstp->rq_resp; u32 minorversion =3D resp->cstate.minorversion; =20 @@ -49539,10 +51506,11 @@ diff -urNp linux-2.6.32.49/fs/nfsd/nfs4xdr.c li= nux-2.6.32.49/fs/nfsd/nfs4xdr.c BUG_ON(bmval1 & NFSD_WRITEONLY_ATTRS_WORD1); BUG_ON(bmval0 & ~nfsd_suppattrs0(minorversion)); BUG_ON(bmval1 & ~nfsd_suppattrs1(minorversion)); -diff -urNp linux-2.6.32.49/fs/nfsd/vfs.c linux-2.6.32.49/fs/nfsd/vfs.c ---- linux-2.6.32.49/fs/nfsd/vfs.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/nfsd/vfs.c 2011-11-15 19:59:43.000000000 -0500 -@@ -937,7 +937,7 @@ nfsd_vfs_read(struct svc_rqst *rqstp, st +diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c +index 2e09588..596421d 100644 +--- a/fs/nfsd/vfs.c ++++ b/fs/nfsd/vfs.c +@@ -937,7 +937,7 @@ nfsd_vfs_read(struct svc_rqst *rqstp, struct svc_fh = *fhp, struct file *file, } else { oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -49551,7 +51519,7 @@ diff -urNp linux-2.6.32.49/fs/nfsd/vfs.c linux-2.= 6.32.49/fs/nfsd/vfs.c set_fs(oldfs); } =20 -@@ -1060,7 +1060,7 @@ nfsd_vfs_write(struct svc_rqst *rqstp, s +@@ -1060,7 +1060,7 @@ nfsd_vfs_write(struct svc_rqst *rqstp, struct svc_= fh *fhp, struct file *file, =20 /* Write the data. */ oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -49560,7 +51528,7 @@ diff -urNp linux-2.6.32.49/fs/nfsd/vfs.c linux-2.= 6.32.49/fs/nfsd/vfs.c set_fs(oldfs); if (host_err < 0) goto out_nfserr; -@@ -1542,7 +1542,7 @@ nfsd_readlink(struct svc_rqst *rqstp, st +@@ -1542,7 +1542,7 @@ nfsd_readlink(struct svc_rqst *rqstp, struct svc_f= h *fhp, char *buf, int *lenp) */ =20 oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -49569,10 +51537,11 @@ diff -urNp linux-2.6.32.49/fs/nfsd/vfs.c linux-= 2.6.32.49/fs/nfsd/vfs.c set_fs(oldfs); =20 if (host_err < 0) -diff -urNp linux-2.6.32.49/fs/nilfs2/ioctl.c linux-2.6.32.49/fs/nilfs2/i= octl.c ---- linux-2.6.32.49/fs/nilfs2/ioctl.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/nilfs2/ioctl.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -480,7 +480,7 @@ static int nilfs_ioctl_clean_segments(st +diff --git a/fs/nilfs2/ioctl.c b/fs/nilfs2/ioctl.c +index f6af760..d6b2b83 100644 +--- a/fs/nilfs2/ioctl.c ++++ b/fs/nilfs2/ioctl.c +@@ -480,7 +480,7 @@ static int nilfs_ioctl_clean_segments(struct inode *= inode, struct file *filp, unsigned int cmd, void __user *argp) { struct nilfs_argv argv[5]; @@ -49581,10 +51550,11 @@ diff -urNp linux-2.6.32.49/fs/nilfs2/ioctl.c li= nux-2.6.32.49/fs/nilfs2/ioctl.c sizeof(struct nilfs_vdesc), sizeof(struct nilfs_period), sizeof(__u64), -diff -urNp linux-2.6.32.49/fs/notify/dnotify/dnotify.c linux-2.6.32.49/f= s/notify/dnotify/dnotify.c ---- linux-2.6.32.49/fs/notify/dnotify/dnotify.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/fs/notify/dnotify/dnotify.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -173,7 +173,7 @@ static void dnotify_free_mark(struct fsn +diff --git a/fs/notify/dnotify/dnotify.c b/fs/notify/dnotify/dnotify.c +index 7e54e52..9337248 100644 +--- a/fs/notify/dnotify/dnotify.c ++++ b/fs/notify/dnotify/dnotify.c +@@ -173,7 +173,7 @@ static void dnotify_free_mark(struct fsnotify_mark_e= ntry *entry) kmem_cache_free(dnotify_mark_entry_cache, dnentry); } =20 @@ -49593,10 +51563,11 @@ diff -urNp linux-2.6.32.49/fs/notify/dnotify/dn= otify.c linux-2.6.32.49/fs/notify .handle_event =3D dnotify_handle_event, .should_send_event =3D dnotify_should_send_event, .free_group_priv =3D NULL, -diff -urNp linux-2.6.32.49/fs/notify/notification.c linux-2.6.32.49/fs/n= otify/notification.c ---- linux-2.6.32.49/fs/notify/notification.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/fs/notify/notification.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -57,7 +57,7 @@ static struct kmem_cache *fsnotify_event +diff --git a/fs/notify/notification.c b/fs/notify/notification.c +index b8bf53b..c518688 100644 +--- a/fs/notify/notification.c ++++ b/fs/notify/notification.c +@@ -57,7 +57,7 @@ static struct kmem_cache *fsnotify_event_holder_cachep= ; * get set to 0 so it will never get 'freed' */ static struct fsnotify_event q_overflow_event; @@ -49605,7 +51576,7 @@ diff -urNp linux-2.6.32.49/fs/notify/notification= .c linux-2.6.32.49/fs/notify/no =20 /** * fsnotify_get_cookie - return a unique cookie for use in synchronizin= g events. -@@ -65,7 +65,7 @@ static atomic_t fsnotify_sync_cookie =3D A +@@ -65,7 +65,7 @@ static atomic_t fsnotify_sync_cookie =3D ATOMIC_INIT(0= ); */ u32 fsnotify_get_cookie(void) { @@ -49614,9 +51585,10 @@ diff -urNp linux-2.6.32.49/fs/notify/notificatio= n.c linux-2.6.32.49/fs/notify/no } EXPORT_SYMBOL_GPL(fsnotify_get_cookie); =20 -diff -urNp linux-2.6.32.49/fs/ntfs/dir.c linux-2.6.32.49/fs/ntfs/dir.c ---- linux-2.6.32.49/fs/ntfs/dir.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ntfs/dir.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/ntfs/dir.c b/fs/ntfs/dir.c +index 5a9e344..0f8cd28 100644 +--- a/fs/ntfs/dir.c ++++ b/fs/ntfs/dir.c @@ -1328,7 +1328,7 @@ find_next_index_buffer: ia =3D (INDEX_ALLOCATION*)(kaddr + (ia_pos & ~PAGE_CACHE_MASK & ~(s64)(ndir->itype.index.block_size - 1))); @@ -49626,10 +51598,11 @@ diff -urNp linux-2.6.32.49/fs/ntfs/dir.c linux-= 2.6.32.49/fs/ntfs/dir.c ntfs_error(sb, "Out of bounds check failed. Corrupt directory " "inode 0x%lx or driver bug.", vdir->i_ino); goto err_out; -diff -urNp linux-2.6.32.49/fs/ntfs/file.c linux-2.6.32.49/fs/ntfs/file.c ---- linux-2.6.32.49/fs/ntfs/file.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ntfs/file.c 2011-11-15 19:59:43.000000000 -0500 -@@ -2243,6 +2243,6 @@ const struct inode_operations ntfs_file_ +diff --git a/fs/ntfs/file.c b/fs/ntfs/file.c +index 663c0e3..b6868e9 100644 +--- a/fs/ntfs/file.c ++++ b/fs/ntfs/file.c +@@ -2243,6 +2243,6 @@ const struct inode_operations ntfs_file_inode_ops = =3D { #endif /* NTFS_RW */ }; =20 @@ -49638,10 +51611,11 @@ diff -urNp linux-2.6.32.49/fs/ntfs/file.c linux= -2.6.32.49/fs/ntfs/file.c =20 -const struct inode_operations ntfs_empty_inode_ops =3D {}; +const struct inode_operations ntfs_empty_inode_ops __read_only; -diff -urNp linux-2.6.32.49/fs/ocfs2/cluster/masklog.c linux-2.6.32.49/fs= /ocfs2/cluster/masklog.c ---- linux-2.6.32.49/fs/ocfs2/cluster/masklog.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/fs/ocfs2/cluster/masklog.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -135,7 +135,7 @@ static ssize_t mlog_store(struct kobject +diff --git a/fs/ocfs2/cluster/masklog.c b/fs/ocfs2/cluster/masklog.c +index 1cd2934..880b5d2 100644 +--- a/fs/ocfs2/cluster/masklog.c ++++ b/fs/ocfs2/cluster/masklog.c +@@ -135,7 +135,7 @@ static ssize_t mlog_store(struct kobject *obj, struc= t attribute *attr, return mlog_mask_store(mlog_attr->mask, buf, count); } =20 @@ -49650,10 +51624,11 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/cluster/mas= klog.c linux-2.6.32.49/fs/ocfs2/c .show =3D mlog_show, .store =3D mlog_store, }; -diff -urNp linux-2.6.32.49/fs/ocfs2/localalloc.c linux-2.6.32.49/fs/ocfs= 2/localalloc.c ---- linux-2.6.32.49/fs/ocfs2/localalloc.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/fs/ocfs2/localalloc.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1188,7 +1188,7 @@ static int ocfs2_local_alloc_slide_windo +diff --git a/fs/ocfs2/localalloc.c b/fs/ocfs2/localalloc.c +index ac10f83..2cd2607 100644 +--- a/fs/ocfs2/localalloc.c ++++ b/fs/ocfs2/localalloc.c +@@ -1188,7 +1188,7 @@ static int ocfs2_local_alloc_slide_window(struct o= cfs2_super *osb, goto bail; } =20 @@ -49662,10 +51637,11 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/localalloc.= c linux-2.6.32.49/fs/ocfs2/locala =20 status =3D 0; bail: -diff -urNp linux-2.6.32.49/fs/ocfs2/namei.c linux-2.6.32.49/fs/ocfs2/nam= ei.c ---- linux-2.6.32.49/fs/ocfs2/namei.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ocfs2/namei.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1043,6 +1043,8 @@ static int ocfs2_rename(struct inode *ol +diff --git a/fs/ocfs2/namei.c b/fs/ocfs2/namei.c +index f010b22..9f9ed34 100644 +--- a/fs/ocfs2/namei.c ++++ b/fs/ocfs2/namei.c +@@ -1043,6 +1043,8 @@ static int ocfs2_rename(struct inode *old_dir, struct ocfs2_dir_lookup_result orphan_insert =3D { NULL, }; struct ocfs2_dir_lookup_result target_insert =3D { NULL, }; =20 @@ -49674,9 +51650,10 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/namei.c linu= x-2.6.32.49/fs/ocfs2/namei.c /* At some point it might be nice to break this function up a * bit. */ =20 -diff -urNp linux-2.6.32.49/fs/ocfs2/ocfs2.h linux-2.6.32.49/fs/ocfs2/ocf= s2.h ---- linux-2.6.32.49/fs/ocfs2/ocfs2.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ocfs2/ocfs2.h 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/ocfs2/ocfs2.h b/fs/ocfs2/ocfs2.h +index d963d86..914cfbd 100644 +--- a/fs/ocfs2/ocfs2.h ++++ b/fs/ocfs2/ocfs2.h @@ -217,11 +217,11 @@ enum ocfs2_vol_state =20 struct ocfs2_alloc_stats @@ -49694,10 +51671,11 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/ocfs2.h lin= ux-2.6.32.49/fs/ocfs2/ocfs2.h }; =20 enum ocfs2_local_alloc_state -diff -urNp linux-2.6.32.49/fs/ocfs2/suballoc.c linux-2.6.32.49/fs/ocfs2/= suballoc.c ---- linux-2.6.32.49/fs/ocfs2/suballoc.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/ocfs2/suballoc.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -623,7 +623,7 @@ static int ocfs2_reserve_suballoc_bits(s +diff --git a/fs/ocfs2/suballoc.c b/fs/ocfs2/suballoc.c +index 79b5dac..d322952 100644 +--- a/fs/ocfs2/suballoc.c ++++ b/fs/ocfs2/suballoc.c +@@ -623,7 +623,7 @@ static int ocfs2_reserve_suballoc_bits(struct ocfs2_= super *osb, mlog_errno(status); goto bail; } @@ -49706,7 +51684,7 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/suballoc.c li= nux-2.6.32.49/fs/ocfs2/suballoc =20 /* You should never ask for this much metadata */ BUG_ON(bits_wanted > -@@ -1654,7 +1654,7 @@ int ocfs2_claim_metadata(struct ocfs2_su +@@ -1654,7 +1654,7 @@ int ocfs2_claim_metadata(struct ocfs2_super *osb, mlog_errno(status); goto bail; } @@ -49715,7 +51693,7 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/suballoc.c li= nux-2.6.32.49/fs/ocfs2/suballoc =20 *blkno_start =3D bg_blkno + (u64) *suballoc_bit_start; ac->ac_bits_given +=3D (*num_bits); -@@ -1728,7 +1728,7 @@ int ocfs2_claim_new_inode(struct ocfs2_s +@@ -1728,7 +1728,7 @@ int ocfs2_claim_new_inode(struct ocfs2_super *osb, mlog_errno(status); goto bail; } @@ -49724,7 +51702,7 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/suballoc.c li= nux-2.6.32.49/fs/ocfs2/suballoc =20 BUG_ON(num_bits !=3D 1); =20 -@@ -1830,7 +1830,7 @@ int __ocfs2_claim_clusters(struct ocfs2_ +@@ -1830,7 +1830,7 @@ int __ocfs2_claim_clusters(struct ocfs2_super *osb= , cluster_start, num_clusters); if (!status) @@ -49733,7 +51711,7 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/suballoc.c li= nux-2.6.32.49/fs/ocfs2/suballoc } else { if (min_clusters > (osb->bitmap_cpg - 1)) { /* The only paths asking for contiguousness -@@ -1858,7 +1858,7 @@ int __ocfs2_claim_clusters(struct ocfs2_ +@@ -1858,7 +1858,7 @@ int __ocfs2_claim_clusters(struct ocfs2_super *osb= , ocfs2_desc_bitmap_to_cluster_off(ac->ac_inode, bg_blkno, bg_bit_off); @@ -49742,10 +51720,11 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/suballoc.c = linux-2.6.32.49/fs/ocfs2/suballoc } } if (status < 0) { -diff -urNp linux-2.6.32.49/fs/ocfs2/super.c linux-2.6.32.49/fs/ocfs2/sup= er.c ---- linux-2.6.32.49/fs/ocfs2/super.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/ocfs2/super.c 2011-11-15 19:59:43.000000000 -0500 -@@ -284,11 +284,11 @@ static int ocfs2_osb_dump(struct ocfs2_s +diff --git a/fs/ocfs2/super.c b/fs/ocfs2/super.c +index 9f55be4..a3f8048 100644 +--- a/fs/ocfs2/super.c ++++ b/fs/ocfs2/super.c +@@ -284,11 +284,11 @@ static int ocfs2_osb_dump(struct ocfs2_super *osb,= char *buf, int len) "%10s =3D> GlobalAllocs: %d LocalAllocs: %d " "SubAllocs: %d LAWinMoves: %d SAExtends: %d\n", "Stats", @@ -49762,7 +51741,7 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/super.c linux= -2.6.32.49/fs/ocfs2/super.c =20 out +=3D snprintf(buf + out, len - out, "%10s =3D> State: %u Descriptor: %llu Size: %u bits " -@@ -2002,11 +2002,11 @@ static int ocfs2_initialize_super(struct +@@ -2002,11 +2002,11 @@ static int ocfs2_initialize_super(struct super_b= lock *sb, spin_lock_init(&osb->osb_xattr_lock); ocfs2_init_inode_steal_slot(osb); =20 @@ -49779,10 +51758,11 @@ diff -urNp linux-2.6.32.49/fs/ocfs2/super.c lin= ux-2.6.32.49/fs/ocfs2/super.c =20 /* Copy the blockcheck stats from the superblock probe */ osb->osb_ecc_stats =3D *stats; -diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32.49/fs/open.c ---- linux-2.6.32.49/fs/open.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/open.c 2011-11-18 19:28:37.000000000 -0500 -@@ -275,6 +275,10 @@ static long do_sys_truncate(const char _ +diff --git a/fs/open.c b/fs/open.c +index 4f01e06..091f6c3 100644 +--- a/fs/open.c ++++ b/fs/open.c +@@ -275,6 +275,10 @@ static long do_sys_truncate(const char __user *path= name, loff_t length) error =3D locks_verify_truncate(inode, NULL, length); if (!error) error =3D security_path_truncate(&path, length, 0); @@ -49793,7 +51773,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c if (!error) { vfs_dq_init(inode); error =3D do_truncate(path.dentry, length, 0, NULL); -@@ -511,6 +515,9 @@ SYSCALL_DEFINE3(faccessat, int, dfd, con +@@ -511,6 +515,9 @@ SYSCALL_DEFINE3(faccessat, int, dfd, const char __us= er *, filename, int, mode) if (__mnt_is_readonly(path.mnt)) res =3D -EROFS; =20 @@ -49803,7 +51783,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c out_path_release: path_put(&path); out: -@@ -537,6 +544,8 @@ SYSCALL_DEFINE1(chdir, const char __user +@@ -537,6 +544,8 @@ SYSCALL_DEFINE1(chdir, const char __user *, filename= ) if (error) goto dput_and_out; =20 @@ -49812,7 +51792,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c set_fs_pwd(current->fs, &path); =20 dput_and_out: -@@ -563,6 +572,13 @@ SYSCALL_DEFINE1(fchdir, unsigned int, fd +@@ -563,6 +572,13 @@ SYSCALL_DEFINE1(fchdir, unsigned int, fd) goto out_putf; =20 error =3D inode_permission(inode, MAY_EXEC | MAY_ACCESS); @@ -49826,7 +51806,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c if (!error) set_fs_pwd(current->fs, &file->f_path); out_putf: -@@ -588,7 +604,13 @@ SYSCALL_DEFINE1(chroot, const char __use +@@ -588,7 +604,13 @@ SYSCALL_DEFINE1(chroot, const char __user *, filena= me) if (!capable(CAP_SYS_CHROOT)) goto dput_and_out; =20 @@ -49840,7 +51820,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c error =3D 0; dput_and_out: path_put(&path); -@@ -616,12 +638,27 @@ SYSCALL_DEFINE2(fchmod, unsigned int, fd +@@ -616,12 +638,27 @@ SYSCALL_DEFINE2(fchmod, unsigned int, fd, mode_t, = mode) err =3D mnt_want_write_file(file); if (err) goto out_putf; @@ -49868,7 +51848,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c mutex_unlock(&inode->i_mutex); mnt_drop_write(file->f_path.mnt); out_putf: -@@ -645,12 +682,27 @@ SYSCALL_DEFINE3(fchmodat, int, dfd, cons +@@ -645,12 +682,27 @@ SYSCALL_DEFINE3(fchmodat, int, dfd, const char __u= ser *, filename, mode_t, mode) error =3D mnt_want_write(path.mnt); if (error) goto dput_and_out; @@ -49896,7 +51876,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c mutex_unlock(&inode->i_mutex); mnt_drop_write(path.mnt); dput_and_out: -@@ -664,12 +716,15 @@ SYSCALL_DEFINE2(chmod, const char __user +@@ -664,12 +716,15 @@ SYSCALL_DEFINE2(chmod, const char __user *, filena= me, mode_t, mode) return sys_fchmodat(AT_FDCWD, filename, mode); } =20 @@ -49913,7 +51893,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c newattrs.ia_valid =3D ATTR_CTIME; if (user !=3D (uid_t) -1) { newattrs.ia_valid |=3D ATTR_UID; -@@ -700,7 +755,7 @@ SYSCALL_DEFINE3(chown, const char __user +@@ -700,7 +755,7 @@ SYSCALL_DEFINE3(chown, const char __user *, filename= , uid_t, user, gid_t, group) error =3D mnt_want_write(path.mnt); if (error) goto out_release; @@ -49922,7 +51902,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c mnt_drop_write(path.mnt); out_release: path_put(&path); -@@ -725,7 +780,7 @@ SYSCALL_DEFINE5(fchownat, int, dfd, cons +@@ -725,7 +780,7 @@ SYSCALL_DEFINE5(fchownat, int, dfd, const char __use= r *, filename, uid_t, user, error =3D mnt_want_write(path.mnt); if (error) goto out_release; @@ -49931,7 +51911,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c mnt_drop_write(path.mnt); out_release: path_put(&path); -@@ -744,7 +799,7 @@ SYSCALL_DEFINE3(lchown, const char __use +@@ -744,7 +799,7 @@ SYSCALL_DEFINE3(lchown, const char __user *, filenam= e, uid_t, user, gid_t, group error =3D mnt_want_write(path.mnt); if (error) goto out_release; @@ -49940,7 +51920,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c mnt_drop_write(path.mnt); out_release: path_put(&path); -@@ -767,7 +822,7 @@ SYSCALL_DEFINE3(fchown, unsigned int, fd +@@ -767,7 +822,7 @@ SYSCALL_DEFINE3(fchown, unsigned int, fd, uid_t, use= r, gid_t, group) goto out_fput; dentry =3D file->f_path.dentry; audit_inode(NULL, dentry); @@ -49949,7 +51929,7 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.32= .49/fs/open.c mnt_drop_write(file->f_path.mnt); out_fput: fput(file); -@@ -1036,7 +1091,7 @@ long do_sys_open(int dfd, const char __u +@@ -1036,7 +1091,7 @@ long do_sys_open(int dfd, const char __user *filen= ame, int flags, int mode) if (!IS_ERR(tmp)) { fd =3D get_unused_fd_flags(flags); if (fd >=3D 0) { @@ -49958,10 +51938,11 @@ diff -urNp linux-2.6.32.49/fs/open.c linux-2.6.= 32.49/fs/open.c if (IS_ERR(f)) { put_unused_fd(fd); fd =3D PTR_ERR(f); -diff -urNp linux-2.6.32.49/fs/partitions/ldm.c linux-2.6.32.49/fs/partit= ions/ldm.c ---- linux-2.6.32.49/fs/partitions/ldm.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/partitions/ldm.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1311,6 +1311,7 @@ static bool ldm_frag_add (const u8 *data +diff --git a/fs/partitions/ldm.c b/fs/partitions/ldm.c +index dd6efdb..3babc6c 100644 +--- a/fs/partitions/ldm.c ++++ b/fs/partitions/ldm.c +@@ -1311,6 +1311,7 @@ static bool ldm_frag_add (const u8 *data, int size= , struct list_head *frags) ldm_error ("A VBLK claims to have %d parts.", num); return false; } @@ -49969,7 +51950,7 @@ diff -urNp linux-2.6.32.49/fs/partitions/ldm.c li= nux-2.6.32.49/fs/partitions/ldm if (rec >=3D num) { ldm_error("REC value (%d) exceeds NUM value (%d)", rec, num); return false; -@@ -1322,7 +1323,7 @@ static bool ldm_frag_add (const u8 *data +@@ -1322,7 +1323,7 @@ static bool ldm_frag_add (const u8 *data, int size= , struct list_head *frags) goto found; } =20 @@ -49978,10 +51959,11 @@ diff -urNp linux-2.6.32.49/fs/partitions/ldm.c = linux-2.6.32.49/fs/partitions/ldm if (!f) { ldm_crit ("Out of memory."); return false; -diff -urNp linux-2.6.32.49/fs/partitions/mac.c linux-2.6.32.49/fs/partit= ions/mac.c ---- linux-2.6.32.49/fs/partitions/mac.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/partitions/mac.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -59,11 +59,11 @@ int mac_partition(struct parsed_partitio +diff --git a/fs/partitions/mac.c b/fs/partitions/mac.c +index 5765198..7f8e9e0 100644 +--- a/fs/partitions/mac.c ++++ b/fs/partitions/mac.c +@@ -59,11 +59,11 @@ int mac_partition(struct parsed_partitions *state, s= truct block_device *bdev) return 0; /* not a MacOS disk */ } blocks_in_map =3D be32_to_cpu(part->map_count); @@ -49994,9 +51976,10 @@ diff -urNp linux-2.6.32.49/fs/partitions/mac.c l= inux-2.6.32.49/fs/partitions/mac for (slot =3D 1; slot <=3D blocks_in_map; ++slot) { int pos =3D slot * secsize; put_dev_sector(sect); -diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32.49/fs/pipe.c ---- linux-2.6.32.49/fs/pipe.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/pipe.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/pipe.c b/fs/pipe.c +index d0cc080..8a6f211 100644 +--- a/fs/pipe.c ++++ b/fs/pipe.c @@ -401,9 +401,9 @@ redo: } if (bufs) /* More to do? */ @@ -50009,7 +51992,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c /* syscall merging: Usually we must not sleep * if O_NONBLOCK is set, or if we got some data. * But if a writer sleeps in kernel space, then -@@ -462,7 +462,7 @@ pipe_write(struct kiocb *iocb, const str +@@ -462,7 +462,7 @@ pipe_write(struct kiocb *iocb, const struct iovec *_= iov, mutex_lock(&inode->i_mutex); pipe =3D inode->i_pipe; =20 @@ -50039,7 +52022,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c } out: mutex_unlock(&inode->i_mutex); -@@ -666,7 +666,7 @@ pipe_poll(struct file *filp, poll_table=20 +@@ -666,7 +666,7 @@ pipe_poll(struct file *filp, poll_table *wait) mask =3D 0; if (filp->f_mode & FMODE_READ) { mask =3D (nrbufs > 0) ? POLLIN | POLLRDNORM : 0; @@ -50048,7 +52031,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c mask |=3D POLLHUP; } =20 -@@ -676,7 +676,7 @@ pipe_poll(struct file *filp, poll_table=20 +@@ -676,7 +676,7 @@ pipe_poll(struct file *filp, poll_table *wait) * Most Unices do not set POLLERR for FIFOs but on Linux they * behave exactly like pipes for poll(). */ @@ -50057,7 +52040,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c mask |=3D POLLERR; } =20 -@@ -690,10 +690,10 @@ pipe_release(struct inode *inode, int de +@@ -690,10 +690,10 @@ pipe_release(struct inode *inode, int decr, int de= cw) =20 mutex_lock(&inode->i_mutex); pipe =3D inode->i_pipe; @@ -50071,7 +52054,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c free_pipe_info(inode); } else { wake_up_interruptible_sync(&pipe->wait); -@@ -783,7 +783,7 @@ pipe_read_open(struct inode *inode, stru +@@ -783,7 +783,7 @@ pipe_read_open(struct inode *inode, struct file *fil= p) =20 if (inode->i_pipe) { ret =3D 0; @@ -50080,7 +52063,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c } =20 mutex_unlock(&inode->i_mutex); -@@ -800,7 +800,7 @@ pipe_write_open(struct inode *inode, str +@@ -800,7 +800,7 @@ pipe_write_open(struct inode *inode, struct file *fi= lp) =20 if (inode->i_pipe) { ret =3D 0; @@ -50089,7 +52072,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c } =20 mutex_unlock(&inode->i_mutex); -@@ -818,9 +818,9 @@ pipe_rdwr_open(struct inode *inode, stru +@@ -818,9 +818,9 @@ pipe_rdwr_open(struct inode *inode, struct file *fil= p) if (inode->i_pipe) { ret =3D 0; if (filp->f_mode & FMODE_READ) @@ -50110,7 +52093,7 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.32= .49/fs/pipe.c static int pipefs_delete_dentry(struct dentry *dentry) { /* -@@ -945,7 +945,8 @@ static struct inode * get_pipe_inode(voi +@@ -945,7 +945,8 @@ static struct inode * get_pipe_inode(void) goto fail_iput; inode->i_pipe =3D pipe; =20 @@ -50120,9 +52103,41 @@ diff -urNp linux-2.6.32.49/fs/pipe.c linux-2.6.3= 2.49/fs/pipe.c inode->i_fop =3D &rdwr_pipefifo_fops; =20 /* -diff -urNp linux-2.6.32.49/fs/proc/array.c linux-2.6.32.49/fs/proc/array= .c ---- linux-2.6.32.49/fs/proc/array.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/proc/array.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/proc/Kconfig b/fs/proc/Kconfig +index 50f8f06..c5755df 100644 +--- a/fs/proc/Kconfig ++++ b/fs/proc/Kconfig +@@ -30,12 +30,12 @@ config PROC_FS +=20 + config PROC_KCORE + bool "/proc/kcore support" if !ARM +- depends on PROC_FS && MMU ++ depends on PROC_FS && MMU && !GRKERNSEC_PROC_ADD +=20 + config PROC_VMCORE + bool "/proc/vmcore support (EXPERIMENTAL)" +- depends on PROC_FS && CRASH_DUMP +- default y ++ depends on PROC_FS && CRASH_DUMP && !GRKERNSEC ++ default n + help + Exports the dump image of crashed kernel in ELF format. +=20 +@@ -59,8 +59,8 @@ config PROC_SYSCTL + limited in memory. +=20 + config PROC_PAGE_MONITOR +- default y +- depends on PROC_FS && MMU ++ default n ++ depends on PROC_FS && MMU && !GRKERNSEC + bool "Enable /proc page monitoring" if EMBEDDED + help + Various /proc files exist to monitor process memory utilization: +diff --git a/fs/proc/array.c b/fs/proc/array.c +index c5ef152..1363194 100644 +--- a/fs/proc/array.c ++++ b/fs/proc/array.c @@ -60,6 +60,7 @@ #include #include @@ -50131,7 +52146,7 @@ diff -urNp linux-2.6.32.49/fs/proc/array.c linux-= 2.6.32.49/fs/proc/array.c #include #include #include -@@ -321,6 +322,21 @@ static inline void task_context_switch_c +@@ -321,6 +322,21 @@ static inline void task_context_switch_counts(struc= t seq_file *m, p->nivcsw); } =20 @@ -50153,7 +52168,7 @@ diff -urNp linux-2.6.32.49/fs/proc/array.c linux-= 2.6.32.49/fs/proc/array.c int proc_pid_status(struct seq_file *m, struct pid_namespace *ns, struct pid *pid, struct task_struct *task) { -@@ -337,9 +353,24 @@ int proc_pid_status(struct seq_file *m,=20 +@@ -337,9 +353,24 @@ int proc_pid_status(struct seq_file *m, struct pid_= namespace *ns, task_cap(m, task); cpuset_task_status_allowed(m, task); task_context_switch_counts(m, task); @@ -50178,7 +52193,7 @@ diff -urNp linux-2.6.32.49/fs/proc/array.c linux-= 2.6.32.49/fs/proc/array.c static int do_task_stat(struct seq_file *m, struct pid_namespace *ns, struct pid *pid, struct task_struct *task, int whole) { -@@ -358,9 +389,11 @@ static int do_task_stat(struct seq_file=20 +@@ -358,9 +389,11 @@ static int do_task_stat(struct seq_file *m, struct = pid_namespace *ns, cputime_t cutime, cstime, utime, stime; cputime_t cgtime, gtime; unsigned long rsslim =3D 0; @@ -50191,7 +52206,7 @@ diff -urNp linux-2.6.32.49/fs/proc/array.c linux-= 2.6.32.49/fs/proc/array.c state =3D *get_task_state(task); vsize =3D eip =3D esp =3D 0; permitted =3D ptrace_may_access(task, PTRACE_MODE_READ); -@@ -433,6 +466,19 @@ static int do_task_stat(struct seq_file=20 +@@ -433,6 +466,19 @@ static int do_task_stat(struct seq_file *m, struct = pid_namespace *ns, gtime =3D task_gtime(task); } =20 @@ -50211,7 +52226,7 @@ diff -urNp linux-2.6.32.49/fs/proc/array.c linux-= 2.6.32.49/fs/proc/array.c /* scale priority and nice values from timeslices to -20..20 */ /* to make it look like a "normal" Unix priority/nice value */ priority =3D task_prio(task); -@@ -473,9 +519,15 @@ static int do_task_stat(struct seq_file=20 +@@ -473,9 +519,15 @@ static int do_task_stat(struct seq_file *m, struct = pid_namespace *ns, vsize, mm ? get_mm_rss(mm) : 0, rsslim, @@ -50227,7 +52242,7 @@ diff -urNp linux-2.6.32.49/fs/proc/array.c linux-= 2.6.32.49/fs/proc/array.c esp, eip, /* The signal information here is obsolete. -@@ -528,3 +580,18 @@ int proc_pid_statm(struct seq_file *m, s +@@ -528,3 +580,18 @@ int proc_pid_statm(struct seq_file *m, struct pid_n= amespace *ns, =20 return 0; } @@ -50246,9 +52261,10 @@ diff -urNp linux-2.6.32.49/fs/proc/array.c linux= -2.6.32.49/fs/proc/array.c + return sprintf(buffer, "%pI4\n", &curr_ip); +} +#endif -diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2.6.32.49/fs/proc/base.c ---- linux-2.6.32.49/fs/proc/base.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/proc/base.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/proc/base.c b/fs/proc/base.c +index 67f7dc0..7171c9a 100644 +--- a/fs/proc/base.c ++++ b/fs/proc/base.c @@ -102,6 +102,22 @@ struct pid_entry { union proc_op op; }; @@ -50272,7 +52288,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c #define NOD(NAME, MODE, IOP, FOP, OP) { \ .name =3D (NAME), \ .len =3D sizeof(NAME) - 1, \ -@@ -213,6 +229,9 @@ static int check_mem_permission(struct t +@@ -213,6 +229,9 @@ static int check_mem_permission(struct task_struct *= task) if (task =3D=3D current) return 0; =20 @@ -50282,7 +52298,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c /* * If current is actively ptrace'ing, and would also be * permitted to freshly attach with ptrace now, permit it. -@@ -260,6 +279,9 @@ static int proc_pid_cmdline(struct task_ +@@ -260,6 +279,9 @@ static int proc_pid_cmdline(struct task_struct *task= , char * buffer) if (!mm->arg_end) goto out_mm; /* Shh! No looking before we're done */ =20 @@ -50321,7 +52337,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c do { nwords +=3D 2; } while (mm->saved_auxv[nwords - 2] !=3D 0); /* AT_NULL */ -@@ -306,7 +344,7 @@ static int proc_pid_auxv(struct task_str +@@ -306,7 +344,7 @@ static int proc_pid_auxv(struct task_struct *task, c= har *buffer) } =20 =20 @@ -50330,7 +52346,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c /* * Provides a wchan file via kallsyms in a proper one-value-per-file fo= rmat. * Returns the resolved symbol. If that fails, simply return the addre= ss. -@@ -345,7 +383,7 @@ static void unlock_trace(struct task_str +@@ -345,7 +383,7 @@ static void unlock_trace(struct task_struct *task) mutex_unlock(&task->cred_guard_mutex); } =20 @@ -50339,7 +52355,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c =20 #define MAX_STACK_TRACE_DEPTH 64 =20 -@@ -545,7 +583,7 @@ static int proc_pid_limits(struct task_s +@@ -545,7 +583,7 @@ static int proc_pid_limits(struct task_struct *task,= char *buffer) return count; } =20 @@ -50348,7 +52364,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c static int proc_pid_syscall(struct task_struct *task, char *buffer) { long nr; -@@ -574,7 +612,7 @@ static int proc_pid_syscall(struct task_ +@@ -574,7 +612,7 @@ static int proc_pid_syscall(struct task_struct *task= , char *buffer) /**********************************************************************= **/ =20 /* permission checks */ @@ -50357,7 +52373,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c { struct task_struct *task; int allowed =3D 0; -@@ -584,7 +622,10 @@ static int proc_fd_access_allowed(struct +@@ -584,7 +622,10 @@ static int proc_fd_access_allowed(struct inode *ino= de) */ task =3D get_proc_task(inode); if (task) { @@ -50369,7 +52385,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c put_task_struct(task); } return allowed; -@@ -963,6 +1004,9 @@ static ssize_t environ_read(struct file=20 +@@ -963,6 +1004,9 @@ static ssize_t environ_read(struct file *file, char= __user *buf, if (!task) goto out_no_task; =20 @@ -50379,7 +52395,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c if (!ptrace_may_access(task, PTRACE_MODE_READ)) goto out; =20 -@@ -1377,7 +1421,7 @@ static void *proc_pid_follow_link(struct +@@ -1377,7 +1421,7 @@ static void *proc_pid_follow_link(struct dentry *d= entry, struct nameidata *nd) path_put(&nd->path); =20 /* Are we allowed to snoop on the tasks file descriptors? */ @@ -50388,7 +52404,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c goto out; =20 error =3D PROC_I(inode)->op.proc_get_link(inode, &nd->path); -@@ -1417,8 +1461,18 @@ static int proc_pid_readlink(struct dent +@@ -1417,8 +1461,18 @@ static int proc_pid_readlink(struct dentry * dent= ry, char __user * buffer, int b struct path path; =20 /* Are we allowed to snoop on the tasks file descriptors? */ @@ -50409,7 +52425,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c =20 error =3D PROC_I(inode)->op.proc_get_link(inode, &path); if (error) -@@ -1483,7 +1537,11 @@ static struct inode *proc_pid_make_inode +@@ -1483,7 +1537,11 @@ static struct inode *proc_pid_make_inode(struct s= uper_block * sb, struct task_st rcu_read_lock(); cred =3D __task_cred(task); inode->i_uid =3D cred->euid; @@ -50421,7 +52437,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c rcu_read_unlock(); } security_task_to_inode(task, inode); -@@ -1501,6 +1559,9 @@ static int pid_getattr(struct vfsmount * +@@ -1501,6 +1559,9 @@ static int pid_getattr(struct vfsmount *mnt, struc= t dentry *dentry, struct kstat struct inode *inode =3D dentry->d_inode; struct task_struct *task; const struct cred *cred; @@ -50431,7 +52447,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c =20 generic_fillattr(inode, stat); =20 -@@ -1508,13 +1569,41 @@ static int pid_getattr(struct vfsmount * +@@ -1508,13 +1569,41 @@ static int pid_getattr(struct vfsmount *mnt, str= uct dentry *dentry, struct kstat stat->uid =3D 0; stat->gid =3D 0; task =3D pid_task(proc_pid(inode), PIDTYPE_PID); @@ -50474,7 +52490,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c } rcu_read_unlock(); return 0; -@@ -1545,11 +1634,20 @@ static int pid_revalidate(struct dentry=20 +@@ -1545,11 +1634,20 @@ static int pid_revalidate(struct dentry *dentry,= struct nameidata *nd) =20 if (task) { if ((inode->i_mode =3D=3D (S_IFDIR|S_IRUGO|S_IXUGO)) || @@ -50495,7 +52511,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c rcu_read_unlock(); } else { inode->i_uid =3D 0; -@@ -1670,7 +1768,8 @@ static int proc_fd_info(struct inode *in +@@ -1670,7 +1768,8 @@ static int proc_fd_info(struct inode *inode, struc= t path *path, char *info) int fd =3D proc_fd(inode); =20 if (task) { @@ -50505,7 +52521,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c put_task_struct(task); } if (files) { -@@ -1922,12 +2021,22 @@ static const struct file_operations proc +@@ -1922,12 +2021,22 @@ static const struct file_operations proc_fd_oper= ations =3D { static int proc_fd_permission(struct inode *inode, int mask) { int rv; @@ -50530,7 +52546,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c return rv; } =20 -@@ -2036,6 +2145,9 @@ static struct dentry *proc_pident_lookup +@@ -2036,6 +2145,9 @@ static struct dentry *proc_pident_lookup(struct in= ode *dir, if (!task) goto out_no_task; =20 @@ -50540,7 +52556,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c /* * Yes, it does not scale. And it should not. Don't add * new entries into /proc// without very good reasons. -@@ -2080,6 +2192,9 @@ static int proc_pident_readdir(struct fi +@@ -2080,6 +2192,9 @@ static int proc_pident_readdir(struct file *filp, if (!task) goto out_no_task; =20 @@ -50550,7 +52566,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c ret =3D 0; i =3D filp->f_pos; switch (i) { -@@ -2347,7 +2462,7 @@ static void *proc_self_follow_link(struc +@@ -2347,7 +2462,7 @@ static void *proc_self_follow_link(struct dentry *= dentry, struct nameidata *nd) static void proc_self_put_link(struct dentry *dentry, struct nameidata = *nd, void *cookie) { @@ -50559,7 +52575,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c if (!IS_ERR(s)) __putname(s); } -@@ -2553,7 +2668,7 @@ static const struct pid_entry tgid_base_ +@@ -2553,7 +2668,7 @@ static const struct pid_entry tgid_base_stuff[] =3D= { #ifdef CONFIG_SCHED_DEBUG REG("sched", S_IRUGO|S_IWUSR, proc_pid_sched_operations), #endif @@ -50568,7 +52584,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c INF("syscall", S_IRUGO, proc_pid_syscall), #endif INF("cmdline", S_IRUGO, proc_pid_cmdline), -@@ -2578,10 +2693,10 @@ static const struct pid_entry tgid_base_ +@@ -2578,10 +2693,10 @@ static const struct pid_entry tgid_base_stuff[] = =3D { #ifdef CONFIG_SECURITY DIR("attr", S_IRUGO|S_IXUGO, proc_attr_dir_inode_operations, pro= c_attr_dir_operations), #endif @@ -50581,7 +52597,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c ONE("stack", S_IRUGO, proc_pid_stack), #endif #ifdef CONFIG_SCHEDSTATS -@@ -2611,6 +2726,9 @@ static const struct pid_entry tgid_base_ +@@ -2611,6 +2726,9 @@ static const struct pid_entry tgid_base_stuff[] =3D= { #ifdef CONFIG_TASK_IO_ACCOUNTING INF("io", S_IRUSR, proc_tgid_io_accounting), #endif @@ -50591,7 +52607,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c }; =20 static int proc_tgid_base_readdir(struct file * filp, -@@ -2735,7 +2853,14 @@ static struct dentry *proc_pid_instantia +@@ -2735,7 +2853,14 @@ static struct dentry *proc_pid_instantiate(struct= inode *dir, if (!inode) goto out; =20 @@ -50606,7 +52622,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c inode->i_op =3D &proc_tgid_base_inode_operations; inode->i_fop =3D &proc_tgid_base_operations; inode->i_flags|=3DS_IMMUTABLE; -@@ -2777,7 +2902,14 @@ struct dentry *proc_pid_lookup(struct in +@@ -2777,7 +2902,14 @@ struct dentry *proc_pid_lookup(struct inode *dir,= struct dentry * dentry, struct if (!task) goto out; =20 @@ -50621,7 +52637,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c put_task_struct(task); out: return result; -@@ -2842,6 +2974,11 @@ int proc_pid_readdir(struct file * filp, +@@ -2842,6 +2974,11 @@ int proc_pid_readdir(struct file * filp, void * d= irent, filldir_t filldir) { unsigned int nr; struct task_struct *reaper; @@ -50633,7 +52649,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c struct tgid_iter iter; struct pid_namespace *ns; =20 -@@ -2865,8 +3002,27 @@ int proc_pid_readdir(struct file * filp, +@@ -2865,8 +3002,27 @@ int proc_pid_readdir(struct file * filp, void * d= irent, filldir_t filldir) for (iter =3D next_tgid(ns, iter); iter.task; iter.tgid +=3D 1, iter =3D next_tgid(ns, iter)) { @@ -50662,7 +52678,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c put_task_struct(iter.task); goto out; } -@@ -2892,7 +3048,7 @@ static const struct pid_entry tid_base_s +@@ -2892,7 +3048,7 @@ static const struct pid_entry tid_base_stuff[] =3D= { #ifdef CONFIG_SCHED_DEBUG REG("sched", S_IRUGO|S_IWUSR, proc_pid_sched_operations), #endif @@ -50671,7 +52687,7 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux-2= .6.32.49/fs/proc/base.c INF("syscall", S_IRUGO, proc_pid_syscall), #endif INF("cmdline", S_IRUGO, proc_pid_cmdline), -@@ -2916,10 +3072,10 @@ static const struct pid_entry tid_base_s +@@ -2916,10 +3072,10 @@ static const struct pid_entry tid_base_stuff[] =3D= { #ifdef CONFIG_SECURITY DIR("attr", S_IRUGO|S_IXUGO, proc_attr_dir_inode_operations, proc= _attr_dir_operations), #endif @@ -50684,10 +52700,11 @@ diff -urNp linux-2.6.32.49/fs/proc/base.c linux= -2.6.32.49/fs/proc/base.c ONE("stack", S_IRUGO, proc_pid_stack), #endif #ifdef CONFIG_SCHEDSTATS -diff -urNp linux-2.6.32.49/fs/proc/cmdline.c linux-2.6.32.49/fs/proc/cmd= line.c ---- linux-2.6.32.49/fs/proc/cmdline.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/proc/cmdline.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -23,7 +23,11 @@ static const struct file_operations cmdl +diff --git a/fs/proc/cmdline.c b/fs/proc/cmdline.c +index 82676e3..5f8518a 100644 +--- a/fs/proc/cmdline.c ++++ b/fs/proc/cmdline.c +@@ -23,7 +23,11 @@ static const struct file_operations cmdline_proc_fops= =3D { =20 static int __init proc_cmdline_init(void) { @@ -50699,10 +52716,11 @@ diff -urNp linux-2.6.32.49/fs/proc/cmdline.c li= nux-2.6.32.49/fs/proc/cmdline.c return 0; } module_init(proc_cmdline_init); -diff -urNp linux-2.6.32.49/fs/proc/devices.c linux-2.6.32.49/fs/proc/dev= ices.c ---- linux-2.6.32.49/fs/proc/devices.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/proc/devices.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -64,7 +64,11 @@ static const struct file_operations proc +diff --git a/fs/proc/devices.c b/fs/proc/devices.c +index 59ee7da..469b4b6 100644 +--- a/fs/proc/devices.c ++++ b/fs/proc/devices.c +@@ -64,7 +64,11 @@ static const struct file_operations proc_devinfo_oper= ations =3D { =20 static int __init proc_devices_init(void) { @@ -50714,9 +52732,10 @@ diff -urNp linux-2.6.32.49/fs/proc/devices.c lin= ux-2.6.32.49/fs/proc/devices.c return 0; } module_init(proc_devices_init); -diff -urNp linux-2.6.32.49/fs/proc/inode.c linux-2.6.32.49/fs/proc/inode= .c ---- linux-2.6.32.49/fs/proc/inode.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/proc/inode.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/proc/inode.c b/fs/proc/inode.c +index d78ade3..81767f9 100644 +--- a/fs/proc/inode.c ++++ b/fs/proc/inode.c @@ -18,12 +18,19 @@ #include #include @@ -50737,7 +52756,7 @@ diff -urNp linux-2.6.32.49/fs/proc/inode.c linux-= 2.6.32.49/fs/proc/inode.c struct proc_dir_entry *de_get(struct proc_dir_entry *de) { atomic_inc(&de->count); -@@ -62,6 +69,13 @@ static void proc_delete_inode(struct ino +@@ -62,6 +69,13 @@ static void proc_delete_inode(struct inode *inode) de_put(de); if (PROC_I(inode)->sysctl) sysctl_head_put(PROC_I(inode)->sysctl); @@ -50751,7 +52770,7 @@ diff -urNp linux-2.6.32.49/fs/proc/inode.c linux-= 2.6.32.49/fs/proc/inode.c clear_inode(inode); } =20 -@@ -457,7 +471,11 @@ struct inode *proc_get_inode(struct supe +@@ -457,7 +471,11 @@ struct inode *proc_get_inode(struct super_block *sb= , unsigned int ino, if (de->mode) { inode->i_mode =3D de->mode; inode->i_uid =3D de->uid; @@ -50763,10 +52782,11 @@ diff -urNp linux-2.6.32.49/fs/proc/inode.c linu= x-2.6.32.49/fs/proc/inode.c } if (de->size) inode->i_size =3D de->size; -diff -urNp linux-2.6.32.49/fs/proc/internal.h linux-2.6.32.49/fs/proc/in= ternal.h ---- linux-2.6.32.49/fs/proc/internal.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/proc/internal.h 2011-11-15 19:59:43.000000000 -05= 00 -@@ -51,6 +51,9 @@ extern int proc_pid_status(struct seq_fi +diff --git a/fs/proc/internal.h b/fs/proc/internal.h +index 753ca37..26bcf3b 100644 +--- a/fs/proc/internal.h ++++ b/fs/proc/internal.h +@@ -51,6 +51,9 @@ extern int proc_pid_status(struct seq_file *m, struct = pid_namespace *ns, struct pid *pid, struct task_struct *task); extern int proc_pid_statm(struct seq_file *m, struct pid_namespace *ns, struct pid *pid, struct task_struct *task); @@ -50776,40 +52796,11 @@ diff -urNp linux-2.6.32.49/fs/proc/internal.h l= inux-2.6.32.49/fs/proc/internal.h extern loff_t mem_lseek(struct file *file, loff_t offset, int orig); =20 extern const struct file_operations proc_maps_operations; -diff -urNp linux-2.6.32.49/fs/proc/Kconfig linux-2.6.32.49/fs/proc/Kconf= ig ---- linux-2.6.32.49/fs/proc/Kconfig 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/proc/Kconfig 2011-11-15 19:59:43.000000000 -0500 -@@ -30,12 +30,12 @@ config PROC_FS -=20 - config PROC_KCORE - bool "/proc/kcore support" if !ARM -- depends on PROC_FS && MMU -+ depends on PROC_FS && MMU && !GRKERNSEC_PROC_ADD -=20 - config PROC_VMCORE - bool "/proc/vmcore support (EXPERIMENTAL)" -- depends on PROC_FS && CRASH_DUMP -- default y -+ depends on PROC_FS && CRASH_DUMP && !GRKERNSEC -+ default n - help - Exports the dump image of crashed kernel in ELF format. -=20 -@@ -59,8 +59,8 @@ config PROC_SYSCTL - limited in memory. -=20 - config PROC_PAGE_MONITOR -- default y -- depends on PROC_FS && MMU -+ default n -+ depends on PROC_FS && MMU && !GRKERNSEC - bool "Enable /proc page monitoring" if EMBEDDED - help - Various /proc files exist to monitor process memory utilization: -diff -urNp linux-2.6.32.49/fs/proc/kcore.c linux-2.6.32.49/fs/proc/kcore= .c ---- linux-2.6.32.49/fs/proc/kcore.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/proc/kcore.c 2011-11-15 19:59:43.000000000 -0500 -@@ -320,6 +320,8 @@ static void elf_kcore_store_hdr(char *bu +diff --git a/fs/proc/kcore.c b/fs/proc/kcore.c +index b442dac..aab29cb 100644 +--- a/fs/proc/kcore.c ++++ b/fs/proc/kcore.c +@@ -320,6 +320,8 @@ static void elf_kcore_store_hdr(char *bufp, int nphd= r, int dataoff) off_t offset =3D 0; struct kcore_list *m; =20 @@ -50818,7 +52809,7 @@ diff -urNp linux-2.6.32.49/fs/proc/kcore.c linux-= 2.6.32.49/fs/proc/kcore.c /* setup ELF header */ elf =3D (struct elfhdr *) bufp; bufp +=3D sizeof(struct elfhdr); -@@ -477,9 +479,10 @@ read_kcore(struct file *file, char __use +@@ -477,9 +479,10 @@ read_kcore(struct file *file, char __user *buffer, = size_t buflen, loff_t *fpos) * the addresses in the elf_phdr on our list. */ start =3D kc_offset_to_vaddr(*fpos - elf_buflen); @@ -50831,14 +52822,12 @@ diff -urNp linux-2.6.32.49/fs/proc/kcore.c linu= x-2.6.32.49/fs/proc/kcore.c while (buflen) { struct kcore_list *m; =20 -@@ -508,20 +511,23 @@ read_kcore(struct file *file, char __use +@@ -508,20 +511,23 @@ read_kcore(struct file *file, char __user *buffer,= size_t buflen, loff_t *fpos) kfree(elf_buf); } else { if (kern_addr_valid(start)) { - unsigned long n; -+ char *elf_buf; -+ mm_segment_t oldfs; -=20 +- - n =3D copy_to_user(buffer, (char *)start, tsz); - /* - * We cannot distingush between fault on source @@ -50849,6 +52838,9 @@ diff -urNp linux-2.6.32.49/fs/proc/kcore.c linux-= 2.6.32.49/fs/proc/kcore.c - if (n) {=20 - if (clear_user(buffer + tsz - n, - n)) ++ char *elf_buf; ++ mm_segment_t oldfs; ++ + elf_buf =3D kmalloc(tsz, GFP_KERNEL); + if (!elf_buf) + return -ENOMEM; @@ -50866,7 +52858,7 @@ diff -urNp linux-2.6.32.49/fs/proc/kcore.c linux-= 2.6.32.49/fs/proc/kcore.c } else { if (clear_user(buffer, tsz)) return -EFAULT; -@@ -541,6 +547,9 @@ read_kcore(struct file *file, char __use +@@ -541,6 +547,9 @@ read_kcore(struct file *file, char __user *buffer, s= ize_t buflen, loff_t *fpos) =20 static int open_kcore(struct inode *inode, struct file *filp) { @@ -50876,10 +52868,11 @@ diff -urNp linux-2.6.32.49/fs/proc/kcore.c linu= x-2.6.32.49/fs/proc/kcore.c if (!capable(CAP_SYS_RAWIO)) return -EPERM; if (kcore_need_update) -diff -urNp linux-2.6.32.49/fs/proc/meminfo.c linux-2.6.32.49/fs/proc/mem= info.c ---- linux-2.6.32.49/fs/proc/meminfo.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/proc/meminfo.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -29,6 +29,8 @@ static int meminfo_proc_show(struct seq_ +diff --git a/fs/proc/meminfo.c b/fs/proc/meminfo.c +index a65239c..ad1182a 100644 +--- a/fs/proc/meminfo.c ++++ b/fs/proc/meminfo.c +@@ -29,6 +29,8 @@ static int meminfo_proc_show(struct seq_file *m, void = *v) unsigned long pages[NR_LRU_LISTS]; int lru; =20 @@ -50888,7 +52881,7 @@ diff -urNp linux-2.6.32.49/fs/proc/meminfo.c linu= x-2.6.32.49/fs/proc/meminfo.c /* * display in kilobytes. */ -@@ -149,7 +151,7 @@ static int meminfo_proc_show(struct seq_ +@@ -149,7 +151,7 @@ static int meminfo_proc_show(struct seq_file *m, voi= d *v) vmi.used >> 10, vmi.largest_chunk >> 10 #ifdef CONFIG_MEMORY_FAILURE @@ -50897,10 +52890,11 @@ diff -urNp linux-2.6.32.49/fs/proc/meminfo.c li= nux-2.6.32.49/fs/proc/meminfo.c #endif ); =20 -diff -urNp linux-2.6.32.49/fs/proc/nommu.c linux-2.6.32.49/fs/proc/nommu= .c ---- linux-2.6.32.49/fs/proc/nommu.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/proc/nommu.c 2011-11-15 19:59:43.000000000 -0500 -@@ -67,7 +67,7 @@ static int nommu_region_show(struct seq_ +diff --git a/fs/proc/nommu.c b/fs/proc/nommu.c +index 9fe7d7e..cdb62c9 100644 +--- a/fs/proc/nommu.c ++++ b/fs/proc/nommu.c +@@ -67,7 +67,7 @@ static int nommu_region_show(struct seq_file *m, struc= t vm_region *region) if (len < 1) len =3D 1; seq_printf(m, "%*c", len, ' '); @@ -50909,10 +52903,11 @@ diff -urNp linux-2.6.32.49/fs/proc/nommu.c linu= x-2.6.32.49/fs/proc/nommu.c } =20 seq_putc(m, '\n'); -diff -urNp linux-2.6.32.49/fs/proc/proc_net.c linux-2.6.32.49/fs/proc/pr= oc_net.c ---- linux-2.6.32.49/fs/proc/proc_net.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/proc/proc_net.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -104,6 +104,17 @@ static struct net *get_proc_task_net(str +diff --git a/fs/proc/proc_net.c b/fs/proc/proc_net.c +index 04d1270..25e1173 100644 +--- a/fs/proc/proc_net.c ++++ b/fs/proc/proc_net.c +@@ -104,6 +104,17 @@ static struct net *get_proc_task_net(struct inode *= dir) struct task_struct *task; struct nsproxy *ns; struct net *net =3D NULL; @@ -50930,9 +52925,10 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_net.c li= nux-2.6.32.49/fs/proc/proc_net.c =20 rcu_read_lock(); task =3D pid_task(proc_pid(dir), PIDTYPE_PID); -diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c linux-2.6.32.49/fs/proc= /proc_sysctl.c ---- linux-2.6.32.49/fs/proc/proc_sysctl.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/fs/proc/proc_sysctl.c 2011-11-18 18:45:06.000000000 = -0500 +diff --git a/fs/proc/proc_sysctl.c b/fs/proc/proc_sysctl.c +index f667e8a..55f4d96 100644 +--- a/fs/proc/proc_sysctl.c ++++ b/fs/proc/proc_sysctl.c @@ -7,11 +7,13 @@ #include #include "internal.h" @@ -50949,7 +52945,7 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c = linux-2.6.32.49/fs/proc/proc_sy =20 static struct inode *proc_sys_make_inode(struct super_block *sb, struct ctl_table_header *head, struct ctl_table *table) -@@ -109,6 +111,9 @@ static struct dentry *proc_sys_lookup(st +@@ -109,6 +111,9 @@ static struct dentry *proc_sys_lookup(struct inode *= dir, struct dentry *dentry, if (!p) goto out; =20 @@ -50959,7 +52955,7 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c = linux-2.6.32.49/fs/proc/proc_sy err =3D ERR_PTR(-ENOMEM); inode =3D proc_sys_make_inode(dir->i_sb, h ? h : head, p); if (h) -@@ -119,6 +124,9 @@ static struct dentry *proc_sys_lookup(st +@@ -119,6 +124,9 @@ static struct dentry *proc_sys_lookup(struct inode *= dir, struct dentry *dentry, =20 err =3D NULL; dentry->d_op =3D &proc_sys_dentry_operations; @@ -50969,7 +52965,7 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c = linux-2.6.32.49/fs/proc/proc_sy d_add(dentry, inode); =20 out: -@@ -200,6 +208,9 @@ static int proc_sys_fill_cache(struct fi +@@ -200,6 +208,9 @@ static int proc_sys_fill_cache(struct file *filp, vo= id *dirent, return -ENOMEM; } else { child->d_op =3D &proc_sys_dentry_operations; @@ -50979,7 +52975,7 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c = linux-2.6.32.49/fs/proc/proc_sy d_add(child, inode); } } else { -@@ -228,6 +239,9 @@ static int scan(struct ctl_table_header=20 +@@ -228,6 +239,9 @@ static int scan(struct ctl_table_header *head, ctl_t= able *table, if (*pos < file->f_pos) continue; =20 @@ -50989,7 +52985,7 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c = linux-2.6.32.49/fs/proc/proc_sy res =3D proc_sys_fill_cache(file, dirent, filldir, head, table); if (res) return res; -@@ -344,6 +358,9 @@ static int proc_sys_getattr(struct vfsmo +@@ -344,6 +358,9 @@ static int proc_sys_getattr(struct vfsmount *mnt, st= ruct dentry *dentry, struct if (IS_ERR(head)) return PTR_ERR(head); =20 @@ -50999,7 +52995,7 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c = linux-2.6.32.49/fs/proc/proc_sy generic_fillattr(inode, stat); if (table) stat->mode =3D (stat->mode & S_IFMT) | table->mode; -@@ -358,17 +375,18 @@ static const struct file_operations proc +@@ -358,17 +375,18 @@ static const struct file_operations proc_sys_file_= operations =3D { }; =20 static const struct file_operations proc_sys_dir_file_operations =3D { @@ -51020,9 +53016,10 @@ diff -urNp linux-2.6.32.49/fs/proc/proc_sysctl.c= linux-2.6.32.49/fs/proc/proc_sy .lookup =3D proc_sys_lookup, .permission =3D proc_sys_permission, .setattr =3D proc_sys_setattr, -diff -urNp linux-2.6.32.49/fs/proc/root.c linux-2.6.32.49/fs/proc/root.c ---- linux-2.6.32.49/fs/proc/root.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/proc/root.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/proc/root.c b/fs/proc/root.c +index b080b79..d957e63 100644 +--- a/fs/proc/root.c ++++ b/fs/proc/root.c @@ -134,7 +134,15 @@ void __init proc_root_init(void) #ifdef CONFIG_PROC_DEVICETREE proc_device_tree_init(); @@ -51039,10 +53036,11 @@ diff -urNp linux-2.6.32.49/fs/proc/root.c linux= -2.6.32.49/fs/proc/root.c proc_sys_init(); } =20 -diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c linux-2.6.32.49/fs/proc/ta= sk_mmu.c ---- linux-2.6.32.49/fs/proc/task_mmu.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/proc/task_mmu.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -46,15 +46,26 @@ void task_mem(struct seq_file *m, struct +diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c +index 3b7b82a..7dbb571 100644 +--- a/fs/proc/task_mmu.c ++++ b/fs/proc/task_mmu.c +@@ -46,15 +46,26 @@ void task_mem(struct seq_file *m, struct mm_struct *= mm) "VmStk:\t%8lu kB\n" "VmExe:\t%8lu kB\n" "VmLib:\t%8lu kB\n" @@ -51072,7 +53070,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c } =20 unsigned long task_vsize(struct mm_struct *mm) -@@ -175,7 +186,8 @@ static void m_stop(struct seq_file *m, v +@@ -175,7 +186,8 @@ static void m_stop(struct seq_file *m, void *v) struct proc_maps_private *priv =3D m->private; struct vm_area_struct *vma =3D v; =20 @@ -51082,7 +53080,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c if (priv->task) put_task_struct(priv->task); } -@@ -199,6 +211,12 @@ static int do_maps_open(struct inode *in +@@ -199,6 +211,12 @@ static int do_maps_open(struct inode *inode, struct= file *file, return ret; } =20 @@ -51095,7 +53093,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c static void show_map_vma(struct seq_file *m, struct vm_area_struct *vma= ) { struct mm_struct *mm =3D vma->vm_mm; -@@ -206,7 +224,6 @@ static void show_map_vma(struct seq_file +@@ -206,7 +224,6 @@ static void show_map_vma(struct seq_file *m, struct = vm_area_struct *vma) int flags =3D vma->vm_flags; unsigned long ino =3D 0; unsigned long long pgoff =3D 0; @@ -51103,7 +53101,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c dev_t dev =3D 0; int len; =20 -@@ -217,20 +234,23 @@ static void show_map_vma(struct seq_file +@@ -217,20 +234,23 @@ static void show_map_vma(struct seq_file *m, struc= t vm_area_struct *vma) pgoff =3D ((loff_t)vma->vm_pgoff) << PAGE_SHIFT; } =20 @@ -51134,7 +53132,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c MAJOR(dev), MINOR(dev), ino, &len); =20 /* -@@ -239,7 +259,7 @@ static void show_map_vma(struct seq_file +@@ -239,7 +259,7 @@ static void show_map_vma(struct seq_file *m, struct = vm_area_struct *vma) */ if (file) { pad_len_spaces(m, len); @@ -51143,7 +53141,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c } else { const char *name =3D arch_vma_name(vma); if (!name) { -@@ -247,8 +267,9 @@ static void show_map_vma(struct seq_file +@@ -247,8 +267,9 @@ static void show_map_vma(struct seq_file *m, struct = vm_area_struct *vma) if (vma->vm_start <=3D mm->brk && vma->vm_end >=3D mm->start_brk) { name =3D "[heap]"; @@ -51155,7 +53153,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c name =3D "[stack]"; } } else { -@@ -391,9 +412,16 @@ static int show_smap(struct seq_file *m, +@@ -391,9 +412,16 @@ static int show_smap(struct seq_file *m, void *v) }; =20 memset(&mss, 0, sizeof mss); @@ -51175,7 +53173,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c lin= ux-2.6.32.49/fs/proc/task_mmu.c =20 show_map_vma(m, vma); =20 -@@ -409,7 +437,11 @@ static int show_smap(struct seq_file *m, +@@ -409,7 +437,11 @@ static int show_smap(struct seq_file *m, void *v) "Swap: %8lu kB\n" "KernelPageSize: %8lu kB\n" "MMUPageSize: %8lu kB\n", @@ -51187,10 +53185,11 @@ diff -urNp linux-2.6.32.49/fs/proc/task_mmu.c l= inux-2.6.32.49/fs/proc/task_mmu.c mss.resident >> 10, (unsigned long)(mss.pss >> (10 + PSS_SHIFT)), mss.shared_clean >> 10, -diff -urNp linux-2.6.32.49/fs/proc/task_nommu.c linux-2.6.32.49/fs/proc/= task_nommu.c ---- linux-2.6.32.49/fs/proc/task_nommu.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/proc/task_nommu.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -50,7 +50,7 @@ void task_mem(struct seq_file *m, struct +diff --git a/fs/proc/task_nommu.c b/fs/proc/task_nommu.c +index 8f5c05d..c99c76d 100644 +--- a/fs/proc/task_nommu.c ++++ b/fs/proc/task_nommu.c +@@ -50,7 +50,7 @@ void task_mem(struct seq_file *m, struct mm_struct *mm= ) else bytes +=3D kobjsize(mm); =09 @@ -51199,7 +53198,7 @@ diff -urNp linux-2.6.32.49/fs/proc/task_nommu.c l= inux-2.6.32.49/fs/proc/task_nom sbytes +=3D kobjsize(current->fs); else bytes +=3D kobjsize(current->fs); -@@ -154,7 +154,7 @@ static int nommu_vma_show(struct seq_fil +@@ -154,7 +154,7 @@ static int nommu_vma_show(struct seq_file *m, struct= vm_area_struct *vma) if (len < 1) len =3D 1; seq_printf(m, "%*c", len, ' '); @@ -51208,9 +53207,10 @@ diff -urNp linux-2.6.32.49/fs/proc/task_nommu.c = linux-2.6.32.49/fs/proc/task_nom } =20 seq_putc(m, '\n'); -diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6.32.49/fs/readdir.c ---- linux-2.6.32.49/fs/readdir.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/readdir.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/readdir.c b/fs/readdir.c +index 7723401..30059a6 100644 +--- a/fs/readdir.c ++++ b/fs/readdir.c @@ -16,6 +16,7 @@ #include #include @@ -51227,7 +53227,7 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6= .32.49/fs/readdir.c int result; }; =20 -@@ -84,6 +86,10 @@ static int fillonedir(void * __buf, cons +@@ -84,6 +86,10 @@ static int fillonedir(void * __buf, const char * name= , int namlen, loff_t offset buf->result =3D -EOVERFLOW; return -EOVERFLOW; } @@ -51238,7 +53238,7 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6= .32.49/fs/readdir.c buf->result++; dirent =3D buf->dirent; if (!access_ok(VERIFY_WRITE, dirent, -@@ -116,6 +122,7 @@ SYSCALL_DEFINE3(old_readdir, unsigned in +@@ -116,6 +122,7 @@ SYSCALL_DEFINE3(old_readdir, unsigned int, fd, =20 buf.result =3D 0; buf.dirent =3D dirent; @@ -51254,7 +53254,7 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6= .32.49/fs/readdir.c int count; int error; }; -@@ -162,6 +170,10 @@ static int filldir(void * __buf, const c +@@ -162,6 +170,10 @@ static int filldir(void * __buf, const char * name,= int namlen, loff_t offset, buf->error =3D -EOVERFLOW; return -EOVERFLOW; } @@ -51265,7 +53265,7 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6= .32.49/fs/readdir.c dirent =3D buf->previous; if (dirent) { if (__put_user(offset, &dirent->d_off)) -@@ -209,6 +221,7 @@ SYSCALL_DEFINE3(getdents, unsigned int,=20 +@@ -209,6 +221,7 @@ SYSCALL_DEFINE3(getdents, unsigned int, fd, buf.previous =3D NULL; buf.count =3D count; buf.error =3D 0; @@ -51281,7 +53281,7 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6= .32.49/fs/readdir.c int count; int error; }; -@@ -242,6 +256,10 @@ static int filldir64(void * __buf, const +@@ -242,6 +256,10 @@ static int filldir64(void * __buf, const char * nam= e, int namlen, loff_t offset, buf->error =3D -EINVAL; /* only used if we fail.. */ if (reclen > buf->count) return -EINVAL; @@ -51292,7 +53292,7 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6= .32.49/fs/readdir.c dirent =3D buf->previous; if (dirent) { if (__put_user(offset, &dirent->d_off)) -@@ -289,6 +307,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int +@@ -289,6 +307,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int, fd, =20 buf.current_dir =3D dirent; buf.previous =3D NULL; @@ -51300,7 +53300,7 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2.6= .32.49/fs/readdir.c buf.count =3D count; buf.error =3D 0; =20 -@@ -297,7 +316,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int +@@ -297,7 +316,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int, fd, error =3D buf.error; lastdirent =3D buf.previous; if (lastdirent) { @@ -51309,10 +53309,11 @@ diff -urNp linux-2.6.32.49/fs/readdir.c linux-2= .6.32.49/fs/readdir.c if (__put_user(d_off, &lastdirent->d_off)) error =3D -EFAULT; else -diff -urNp linux-2.6.32.49/fs/reiserfs/dir.c linux-2.6.32.49/fs/reiserfs= /dir.c ---- linux-2.6.32.49/fs/reiserfs/dir.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/reiserfs/dir.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -66,6 +66,8 @@ int reiserfs_readdir_dentry(struct dentr +diff --git a/fs/reiserfs/dir.c b/fs/reiserfs/dir.c +index d42c30c..4fd8718 100644 +--- a/fs/reiserfs/dir.c ++++ b/fs/reiserfs/dir.c +@@ -66,6 +66,8 @@ int reiserfs_readdir_dentry(struct dentry *dentry, voi= d *dirent, struct reiserfs_dir_entry de; int ret =3D 0; =20 @@ -51321,10 +53322,11 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/dir.c li= nux-2.6.32.49/fs/reiserfs/dir.c reiserfs_write_lock(inode->i_sb); =20 reiserfs_check_lock_depth(inode->i_sb, "readdir"); -diff -urNp linux-2.6.32.49/fs/reiserfs/do_balan.c linux-2.6.32.49/fs/rei= serfs/do_balan.c ---- linux-2.6.32.49/fs/reiserfs/do_balan.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/fs/reiserfs/do_balan.c 2011-11-15 19:59:43.000000000= -0500 -@@ -2058,7 +2058,7 @@ void do_balance(struct tree_balance *tb, +diff --git a/fs/reiserfs/do_balan.c b/fs/reiserfs/do_balan.c +index 128d3f7..8840d44 100644 +--- a/fs/reiserfs/do_balan.c ++++ b/fs/reiserfs/do_balan.c +@@ -2058,7 +2058,7 @@ void do_balance(struct tree_balance *tb, /* tree_b= alance structure */ return; } =20 @@ -51333,10 +53335,11 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/do_balan= .c linux-2.6.32.49/fs/reiserfs/do do_balance_starts(tb); =20 /* balance leaf returns 0 except if combining L R and S into -diff -urNp linux-2.6.32.49/fs/reiserfs/item_ops.c linux-2.6.32.49/fs/rei= serfs/item_ops.c ---- linux-2.6.32.49/fs/reiserfs/item_ops.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/fs/reiserfs/item_ops.c 2011-11-15 19:59:43.000000000= -0500 -@@ -102,7 +102,7 @@ static void sd_print_vi(struct virtual_i +diff --git a/fs/reiserfs/item_ops.c b/fs/reiserfs/item_ops.c +index 72cb1cc..d0e3181 100644 +--- a/fs/reiserfs/item_ops.c ++++ b/fs/reiserfs/item_ops.c +@@ -102,7 +102,7 @@ static void sd_print_vi(struct virtual_item *vi) vi->vi_index, vi->vi_type, vi->vi_ih); } =20 @@ -51345,7 +53348,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/item_ops.c= linux-2.6.32.49/fs/reiserfs/it .bytes_number =3D sd_bytes_number, .decrement_key =3D sd_decrement_key, .is_left_mergeable =3D sd_is_left_mergeable, -@@ -196,7 +196,7 @@ static void direct_print_vi(struct virtu +@@ -196,7 +196,7 @@ static void direct_print_vi(struct virtual_item *vi) vi->vi_index, vi->vi_type, vi->vi_ih); } =20 @@ -51354,7 +53357,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/item_ops.c= linux-2.6.32.49/fs/reiserfs/it .bytes_number =3D direct_bytes_number, .decrement_key =3D direct_decrement_key, .is_left_mergeable =3D direct_is_left_mergeable, -@@ -341,7 +341,7 @@ static void indirect_print_vi(struct vir +@@ -341,7 +341,7 @@ static void indirect_print_vi(struct virtual_item *v= i) vi->vi_index, vi->vi_type, vi->vi_ih); } =20 @@ -51363,7 +53366,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/item_ops.c= linux-2.6.32.49/fs/reiserfs/it .bytes_number =3D indirect_bytes_number, .decrement_key =3D indirect_decrement_key, .is_left_mergeable =3D indirect_is_left_mergeable, -@@ -628,7 +628,7 @@ static void direntry_print_vi(struct vir +@@ -628,7 +628,7 @@ static void direntry_print_vi(struct virtual_item *v= i) printk("\n"); } =20 @@ -51372,7 +53375,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/item_ops.c= linux-2.6.32.49/fs/reiserfs/it .bytes_number =3D direntry_bytes_number, .decrement_key =3D direntry_decrement_key, .is_left_mergeable =3D direntry_is_left_mergeable, -@@ -724,7 +724,7 @@ static void errcatch_print_vi(struct vir +@@ -724,7 +724,7 @@ static void errcatch_print_vi(struct virtual_item *v= i) "Invalid item type observed, run fsck ASAP"); } =20 @@ -51381,7 +53384,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/item_ops.c= linux-2.6.32.49/fs/reiserfs/it errcatch_bytes_number, errcatch_decrement_key, errcatch_is_left_mergeable, -@@ -746,7 +746,7 @@ static struct item_operations errcatch_o +@@ -746,7 +746,7 @@ static struct item_operations errcatch_ops =3D { #error Item types must use disk-format assigned values. #endif =20 @@ -51390,10 +53393,11 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/item_ops= .c linux-2.6.32.49/fs/reiserfs/it &stat_data_ops, &indirect_ops, &direct_ops, -diff -urNp linux-2.6.32.49/fs/reiserfs/journal.c linux-2.6.32.49/fs/reis= erfs/journal.c ---- linux-2.6.32.49/fs/reiserfs/journal.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/fs/reiserfs/journal.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -2329,6 +2329,8 @@ static struct buffer_head *reiserfs_brea +diff --git a/fs/reiserfs/journal.c b/fs/reiserfs/journal.c +index b5fe0aa..e0e25c4 100644 +--- a/fs/reiserfs/journal.c ++++ b/fs/reiserfs/journal.c +@@ -2329,6 +2329,8 @@ static struct buffer_head *reiserfs_breada(struct = block_device *dev, struct buffer_head *bh; int i, j; =20 @@ -51402,10 +53406,11 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/journal.= c linux-2.6.32.49/fs/reiserfs/jou bh =3D __getblk(dev, block, bufsize); if (buffer_uptodate(bh)) return (bh); -diff -urNp linux-2.6.32.49/fs/reiserfs/namei.c linux-2.6.32.49/fs/reiser= fs/namei.c ---- linux-2.6.32.49/fs/reiserfs/namei.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/reiserfs/namei.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1214,6 +1214,8 @@ static int reiserfs_rename(struct inode=20 +diff --git a/fs/reiserfs/namei.c b/fs/reiserfs/namei.c +index 2715791..b8996db 100644 +--- a/fs/reiserfs/namei.c ++++ b/fs/reiserfs/namei.c +@@ -1214,6 +1214,8 @@ static int reiserfs_rename(struct inode *old_dir, = struct dentry *old_dentry, unsigned long savelink =3D 1; struct timespec ctime; =20 @@ -51414,10 +53419,11 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/namei.c = linux-2.6.32.49/fs/reiserfs/namei /* three balancings: (1) old name removal, (2) new name insertion and (3) maybe "save" link insertion stat data updates: (1) old directory, -diff -urNp linux-2.6.32.49/fs/reiserfs/procfs.c linux-2.6.32.49/fs/reise= rfs/procfs.c ---- linux-2.6.32.49/fs/reiserfs/procfs.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/reiserfs/procfs.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -123,7 +123,7 @@ static int show_super(struct seq_file *m +diff --git a/fs/reiserfs/procfs.c b/fs/reiserfs/procfs.c +index 9229e55..3d2e3b7 100644 +--- a/fs/reiserfs/procfs.c ++++ b/fs/reiserfs/procfs.c +@@ -123,7 +123,7 @@ static int show_super(struct seq_file *m, struct sup= er_block *sb) "SMALL_TAILS " : "NO_TAILS ", replay_only(sb) ? "REPLAY_ONLY " : "", convert_reiserfs(sb) ? "CONV " : "", @@ -51426,7 +53432,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/procfs.c l= inux-2.6.32.49/fs/reiserfs/proc SF(s_disk_reads), SF(s_disk_writes), SF(s_fix_nodes), SF(s_do_balance), SF(s_unneeded_left_neighbor), SF(s_good_search_by_key_reada), SF(s_bmaps), -@@ -309,6 +309,8 @@ static int show_journal(struct seq_file=20 +@@ -309,6 +309,8 @@ static int show_journal(struct seq_file *m, struct s= uper_block *sb) struct journal_params *jp =3D &rs->s_v1.s_journal; char b[BDEVNAME_SIZE]; =20 @@ -51435,10 +53441,11 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/procfs.c= linux-2.6.32.49/fs/reiserfs/proc seq_printf(m, /* on-disk fields */ "jp_journal_1st_block: \t%i\n" "jp_journal_dev: \t%s[%x]\n" -diff -urNp linux-2.6.32.49/fs/reiserfs/stree.c linux-2.6.32.49/fs/reiser= fs/stree.c ---- linux-2.6.32.49/fs/reiserfs/stree.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/reiserfs/stree.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1159,6 +1159,8 @@ int reiserfs_delete_item(struct reiserfs +diff --git a/fs/reiserfs/stree.c b/fs/reiserfs/stree.c +index d036ee5..4c7dca1 100644 +--- a/fs/reiserfs/stree.c ++++ b/fs/reiserfs/stree.c +@@ -1159,6 +1159,8 @@ int reiserfs_delete_item(struct reiserfs_transacti= on_handle *th, int iter =3D 0; #endif =20 @@ -51447,7 +53454,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/stree.c li= nux-2.6.32.49/fs/reiserfs/stree BUG_ON(!th->t_trans_id); =20 init_tb_struct(th, &s_del_balance, sb, path, -@@ -1296,6 +1298,8 @@ void reiserfs_delete_solid_item(struct r +@@ -1296,6 +1298,8 @@ void reiserfs_delete_solid_item(struct reiserfs_tr= ansaction_handle *th, int retval; int quota_cut_bytes =3D 0; =20 @@ -51456,7 +53463,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/stree.c li= nux-2.6.32.49/fs/reiserfs/stree BUG_ON(!th->t_trans_id); =20 le_key2cpu_key(&cpu_key, key); -@@ -1525,6 +1529,8 @@ int reiserfs_cut_from_item(struct reiser +@@ -1525,6 +1529,8 @@ int reiserfs_cut_from_item(struct reiserfs_transac= tion_handle *th, int quota_cut_bytes; loff_t tail_pos =3D 0; =20 @@ -51465,7 +53472,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/stree.c li= nux-2.6.32.49/fs/reiserfs/stree BUG_ON(!th->t_trans_id); =20 init_tb_struct(th, &s_cut_balance, inode->i_sb, path, -@@ -1920,6 +1926,8 @@ int reiserfs_paste_into_item(struct reis +@@ -1920,6 +1926,8 @@ int reiserfs_paste_into_item(struct reiserfs_trans= action_handle *th, struct tree int retval; int fs_gen; =20 @@ -51474,7 +53481,7 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/stree.c li= nux-2.6.32.49/fs/reiserfs/stree BUG_ON(!th->t_trans_id); =20 fs_gen =3D get_generation(inode->i_sb); -@@ -2007,6 +2015,8 @@ int reiserfs_insert_item(struct reiserfs +@@ -2007,6 +2015,8 @@ int reiserfs_insert_item(struct reiserfs_transacti= on_handle *th, int fs_gen =3D 0; int quota_bytes =3D 0; =20 @@ -51483,10 +53490,11 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/stree.c = linux-2.6.32.49/fs/reiserfs/stree BUG_ON(!th->t_trans_id); =20 if (inode) { /* Do we count quotas for item? */ -diff -urNp linux-2.6.32.49/fs/reiserfs/super.c linux-2.6.32.49/fs/reiser= fs/super.c ---- linux-2.6.32.49/fs/reiserfs/super.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/fs/reiserfs/super.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -912,6 +912,8 @@ static int reiserfs_parse_options(struct +diff --git a/fs/reiserfs/super.c b/fs/reiserfs/super.c +index f0ad05f..af3306f 100644 +--- a/fs/reiserfs/super.c ++++ b/fs/reiserfs/super.c +@@ -912,6 +912,8 @@ static int reiserfs_parse_options(struct super_block= *s, char *options, /* strin {.option_name =3D NULL} }; =20 @@ -51495,9 +53503,10 @@ diff -urNp linux-2.6.32.49/fs/reiserfs/super.c l= inux-2.6.32.49/fs/reiserfs/super *blocks =3D 0; if (!options || !*options) /* use default configuration: create tails, journaling on, no -diff -urNp linux-2.6.32.49/fs/select.c linux-2.6.32.49/fs/select.c ---- linux-2.6.32.49/fs/select.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/select.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/select.c b/fs/select.c +index fd38ce2..f5381b8 100644 +--- a/fs/select.c ++++ b/fs/select.c @@ -20,6 +20,7 @@ #include #include @@ -51506,7 +53515,7 @@ diff -urNp linux-2.6.32.49/fs/select.c linux-2.6.= 32.49/fs/select.c #include /* for STICKY_TIMEOUTS */ #include #include -@@ -401,6 +402,8 @@ int do_select(int n, fd_set_bits *fds, s +@@ -401,6 +402,8 @@ int do_select(int n, fd_set_bits *fds, struct timesp= ec *end_time) int retval, i, timed_out =3D 0; unsigned long slack =3D 0; =20 @@ -51515,7 +53524,7 @@ diff -urNp linux-2.6.32.49/fs/select.c linux-2.6.= 32.49/fs/select.c rcu_read_lock(); retval =3D max_select_fd(n, fds); rcu_read_unlock(); -@@ -529,6 +532,8 @@ int core_sys_select(int n, fd_set __user +@@ -529,6 +532,8 @@ int core_sys_select(int n, fd_set __user *inp, fd_se= t __user *outp, /* Allocate small arguments on the stack to save memory and be faster = */ long stack_fds[SELECT_STACK_ALLOC/sizeof(long)]; =20 @@ -51524,7 +53533,7 @@ diff -urNp linux-2.6.32.49/fs/select.c linux-2.6.= 32.49/fs/select.c ret =3D -EINVAL; if (n < 0) goto out_nofds; -@@ -821,6 +826,9 @@ int do_sys_poll(struct pollfd __user *uf +@@ -821,6 +826,9 @@ int do_sys_poll(struct pollfd __user *ufds, unsigned= int nfds, struct poll_list *walk =3D head; unsigned long todo =3D nfds; =20 @@ -51534,10 +53543,11 @@ diff -urNp linux-2.6.32.49/fs/select.c linux-2.= 6.32.49/fs/select.c if (nfds > current->signal->rlim[RLIMIT_NOFILE].rlim_cur) return -EINVAL; =20 -diff -urNp linux-2.6.32.49/fs/seq_file.c linux-2.6.32.49/fs/seq_file.c ---- linux-2.6.32.49/fs/seq_file.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/seq_file.c 2011-11-15 19:59:43.000000000 -0500 -@@ -76,7 +76,8 @@ static int traverse(struct seq_file *m,=20 +diff --git a/fs/seq_file.c b/fs/seq_file.c +index eae7d9d..679f099 100644 +--- a/fs/seq_file.c ++++ b/fs/seq_file.c +@@ -76,7 +76,8 @@ static int traverse(struct seq_file *m, loff_t offset) return 0; } if (!m->buf) { @@ -51547,7 +53557,7 @@ diff -urNp linux-2.6.32.49/fs/seq_file.c linux-2.= 6.32.49/fs/seq_file.c if (!m->buf) return -ENOMEM; } -@@ -116,7 +117,8 @@ static int traverse(struct seq_file *m,=20 +@@ -116,7 +117,8 @@ static int traverse(struct seq_file *m, loff_t offse= t) Eoverflow: m->op->stop(m, p); kfree(m->buf); @@ -51557,7 +53567,7 @@ diff -urNp linux-2.6.32.49/fs/seq_file.c linux-2.= 6.32.49/fs/seq_file.c return !m->buf ? -ENOMEM : -EAGAIN; } =20 -@@ -169,7 +171,8 @@ ssize_t seq_read(struct file *file, char +@@ -169,7 +171,8 @@ ssize_t seq_read(struct file *file, char __user *buf= , size_t size, loff_t *ppos) m->version =3D file->f_version; /* grab buffer if we didn't have one */ if (!m->buf) { @@ -51567,7 +53577,7 @@ diff -urNp linux-2.6.32.49/fs/seq_file.c linux-2.= 6.32.49/fs/seq_file.c if (!m->buf) goto Enomem; } -@@ -210,7 +213,8 @@ ssize_t seq_read(struct file *file, char +@@ -210,7 +213,8 @@ ssize_t seq_read(struct file *file, char __user *buf= , size_t size, loff_t *ppos) goto Fill; m->op->stop(m, p); kfree(m->buf); @@ -51577,7 +53587,7 @@ diff -urNp linux-2.6.32.49/fs/seq_file.c linux-2.= 6.32.49/fs/seq_file.c if (!m->buf) goto Enomem; m->count =3D 0; -@@ -551,7 +555,7 @@ static void single_stop(struct seq_file=20 +@@ -551,7 +555,7 @@ static void single_stop(struct seq_file *p, void *v) int single_open(struct file *file, int (*show)(struct seq_file *, void = *), void *data) { @@ -51586,10 +53596,11 @@ diff -urNp linux-2.6.32.49/fs/seq_file.c linux-= 2.6.32.49/fs/seq_file.c int res =3D -ENOMEM; =20 if (op) { -diff -urNp linux-2.6.32.49/fs/smbfs/proc.c linux-2.6.32.49/fs/smbfs/proc= .c ---- linux-2.6.32.49/fs/smbfs/proc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/smbfs/proc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -266,9 +266,9 @@ int smb_setcodepage(struct smb_sb_info * +diff --git a/fs/smbfs/proc.c b/fs/smbfs/proc.c +index 71c29b6..54694dd 100644 +--- a/fs/smbfs/proc.c ++++ b/fs/smbfs/proc.c +@@ -266,9 +266,9 @@ int smb_setcodepage(struct smb_sb_info *server, stru= ct smb_nls_codepage *cp) =20 out: if (server->local_nls !=3D NULL && server->remote_nls !=3D NULL) @@ -51601,7 +53612,7 @@ diff -urNp linux-2.6.32.49/fs/smbfs/proc.c linux-= 2.6.32.49/fs/smbfs/proc.c =20 smb_unlock_server(server); return n; -@@ -933,9 +933,9 @@ smb_newconn(struct smb_sb_info *server,=20 +@@ -933,9 +933,9 @@ smb_newconn(struct smb_sb_info *server, struct smb_c= onn_opt *opt) =20 /* FIXME: the win9x code wants to modify these ... (seek/trunc bug) */ if (server->mnt->flags & SMB_MOUNT_OLDATTR) { @@ -51622,10 +53633,11 @@ diff -urNp linux-2.6.32.49/fs/smbfs/proc.c linu= x-2.6.32.49/fs/smbfs/proc.c } =20 /* < LANMAN2 */ -diff -urNp linux-2.6.32.49/fs/smbfs/symlink.c linux-2.6.32.49/fs/smbfs/s= ymlink.c ---- linux-2.6.32.49/fs/smbfs/symlink.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/smbfs/symlink.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -55,7 +55,7 @@ static void *smb_follow_link(struct dent +diff --git a/fs/smbfs/symlink.c b/fs/smbfs/symlink.c +index 00b2909..2ace383 100644 +--- a/fs/smbfs/symlink.c ++++ b/fs/smbfs/symlink.c +@@ -55,7 +55,7 @@ static void *smb_follow_link(struct dentry *dentry, st= ruct nameidata *nd) =20 static void smb_put_link(struct dentry *dentry, struct nameidata *nd, v= oid *p) { @@ -51634,10 +53646,11 @@ diff -urNp linux-2.6.32.49/fs/smbfs/symlink.c l= inux-2.6.32.49/fs/smbfs/symlink.c if (!IS_ERR(s)) __putname(s); } -diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.32.49/fs/splice.c ---- linux-2.6.32.49/fs/splice.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/splice.c 2011-11-15 19:59:43.000000000 -0500 -@@ -185,7 +185,7 @@ ssize_t splice_to_pipe(struct pipe_inode +diff --git a/fs/splice.c b/fs/splice.c +index bb92b7c..5aa72b0 100644 +--- a/fs/splice.c ++++ b/fs/splice.c +@@ -185,7 +185,7 @@ ssize_t splice_to_pipe(struct pipe_inode_info *pipe, pipe_lock(pipe); =20 for (;;) { @@ -51646,7 +53659,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c send_sig(SIGPIPE, current, 0); if (!ret) ret =3D -EPIPE; -@@ -239,9 +239,9 @@ ssize_t splice_to_pipe(struct pipe_inode +@@ -239,9 +239,9 @@ ssize_t splice_to_pipe(struct pipe_inode_info *pipe, do_wakeup =3D 0; } =20 @@ -51658,7 +53671,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c } =20 pipe_unlock(pipe); -@@ -285,6 +285,8 @@ __generic_file_splice_read(struct file * +@@ -285,6 +285,8 @@ __generic_file_splice_read(struct file *in, loff_t *= ppos, .spd_release =3D spd_release_page, }; =20 @@ -51667,7 +53680,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c index =3D *ppos >> PAGE_CACHE_SHIFT; loff =3D *ppos & ~PAGE_CACHE_MASK; req_pages =3D (len + loff + PAGE_CACHE_SIZE - 1) >> PAGE_CACHE_SHIFT; -@@ -521,7 +523,7 @@ static ssize_t kernel_readv(struct file=20 +@@ -521,7 +523,7 @@ static ssize_t kernel_readv(struct file *file, const= struct iovec *vec, old_fs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -51676,7 +53689,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c set_fs(old_fs); =20 return res; -@@ -536,7 +538,7 @@ static ssize_t kernel_write(struct file=20 +@@ -536,7 +538,7 @@ static ssize_t kernel_write(struct file *file, const= char *buf, size_t count, old_fs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -51685,7 +53698,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c set_fs(old_fs); =20 return res; -@@ -565,6 +567,8 @@ ssize_t default_file_splice_read(struct=20 +@@ -565,6 +567,8 @@ ssize_t default_file_splice_read(struct file *in, lo= ff_t *ppos, .spd_release =3D spd_release_page, }; =20 @@ -51694,7 +53707,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c index =3D *ppos >> PAGE_CACHE_SHIFT; offset =3D *ppos & ~PAGE_CACHE_MASK; nr_pages =3D (len + offset + PAGE_CACHE_SIZE - 1) >> PAGE_CACHE_SHIFT; -@@ -578,7 +582,7 @@ ssize_t default_file_splice_read(struct=20 +@@ -578,7 +582,7 @@ ssize_t default_file_splice_read(struct file *in, lo= ff_t *ppos, goto err; =20 this_len =3D min_t(size_t, len, PAGE_CACHE_SIZE - offset); @@ -51716,7 +53729,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c return 0; =20 if (sd->flags & SPLICE_F_NONBLOCK) -@@ -1140,7 +1144,7 @@ ssize_t splice_direct_to_actor(struct fi +@@ -1140,7 +1144,7 @@ ssize_t splice_direct_to_actor(struct file *in, st= ruct splice_desc *sd, * out of the pipe right after the splice_to_pipe(). So set * PIPE_READERS appropriately. */ @@ -51725,7 +53738,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c =20 current->splice_pipe =3D pipe; } -@@ -1593,6 +1597,8 @@ static long vmsplice_to_pipe(struct file +@@ -1593,6 +1597,8 @@ static long vmsplice_to_pipe(struct file *file, co= nst struct iovec __user *iov, .spd_release =3D spd_release_page, }; =20 @@ -51734,7 +53747,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c pipe =3D pipe_info(file->f_path.dentry->d_inode); if (!pipe) return -EBADF; -@@ -1701,9 +1707,9 @@ static int ipipe_prep(struct pipe_inode_ +@@ -1701,9 +1707,9 @@ static int ipipe_prep(struct pipe_inode_info *pipe= , unsigned int flags) ret =3D -ERESTARTSYS; break; } @@ -51746,7 +53759,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c if (flags & SPLICE_F_NONBLOCK) { ret =3D -EAGAIN; break; -@@ -1735,7 +1741,7 @@ static int opipe_prep(struct pipe_inode_ +@@ -1735,7 +1741,7 @@ static int opipe_prep(struct pipe_inode_info *pipe= , unsigned int flags) pipe_lock(pipe); =20 while (pipe->nrbufs >=3D PIPE_BUFFERS) { @@ -51755,7 +53768,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c send_sig(SIGPIPE, current, 0); ret =3D -EPIPE; break; -@@ -1748,9 +1754,9 @@ static int opipe_prep(struct pipe_inode_ +@@ -1748,9 +1754,9 @@ static int opipe_prep(struct pipe_inode_info *pipe= , unsigned int flags) ret =3D -ERESTARTSYS; break; } @@ -51784,7 +53797,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c break; =20 /* -@@ -1893,7 +1899,7 @@ static int link_pipe(struct pipe_inode_i +@@ -1893,7 +1899,7 @@ static int link_pipe(struct pipe_inode_info *ipipe= , pipe_double_lock(ipipe, opipe); =20 do { @@ -51793,7 +53806,7 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.6.= 32.49/fs/splice.c send_sig(SIGPIPE, current, 0); if (!ret) ret =3D -EPIPE; -@@ -1938,7 +1944,7 @@ static int link_pipe(struct pipe_inode_i +@@ -1938,7 +1944,7 @@ static int link_pipe(struct pipe_inode_info *ipipe= , * return EAGAIN if we have the potential of some data in the * future, otherwise just return 0 */ @@ -51802,10 +53815,11 @@ diff -urNp linux-2.6.32.49/fs/splice.c linux-2.= 6.32.49/fs/splice.c ret =3D -EAGAIN; =20 pipe_unlock(ipipe); -diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-2.6.32.49/fs/sysfs/file= .c ---- linux-2.6.32.49/fs/sysfs/file.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/sysfs/file.c 2011-11-15 19:59:43.000000000 -0500 -@@ -44,7 +44,7 @@ static DEFINE_SPINLOCK(sysfs_open_dirent +diff --git a/fs/sysfs/file.c b/fs/sysfs/file.c +index 7118a38..70af853 100644 +--- a/fs/sysfs/file.c ++++ b/fs/sysfs/file.c +@@ -44,7 +44,7 @@ static DEFINE_SPINLOCK(sysfs_open_dirent_lock); =20 struct sysfs_open_dirent { atomic_t refcnt; @@ -51823,7 +53837,7 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-= 2.6.32.49/fs/sysfs/file.c struct mutex mutex; int needs_read_fill; int event; -@@ -75,7 +75,7 @@ static int fill_read_buffer(struct dentr +@@ -75,7 +75,7 @@ static int fill_read_buffer(struct dentry * dentry, st= ruct sysfs_buffer * buffer { struct sysfs_dirent *attr_sd =3D dentry->d_fsdata; struct kobject *kobj =3D attr_sd->s_parent->s_dir.kobj; @@ -51832,7 +53846,7 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-= 2.6.32.49/fs/sysfs/file.c int ret =3D 0; ssize_t count; =20 -@@ -88,7 +88,7 @@ static int fill_read_buffer(struct dentr +@@ -88,7 +88,7 @@ static int fill_read_buffer(struct dentry * dentry, st= ruct sysfs_buffer * buffer if (!sysfs_get_active_two(attr_sd)) return -ENODEV; =20 @@ -51841,7 +53855,7 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-= 2.6.32.49/fs/sysfs/file.c count =3D ops->show(kobj, attr_sd->s_attr.attr, buffer->page); =20 sysfs_put_active_two(attr_sd); -@@ -199,7 +199,7 @@ flush_write_buffer(struct dentry * dentr +@@ -199,7 +199,7 @@ flush_write_buffer(struct dentry * dentry, struct sy= sfs_buffer * buffer, size_t { struct sysfs_dirent *attr_sd =3D dentry->d_fsdata; struct kobject *kobj =3D attr_sd->s_parent->s_dir.kobj; @@ -51850,7 +53864,7 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-= 2.6.32.49/fs/sysfs/file.c int rc; =20 /* need attr_sd for attr and ops, its parent for kobj */ -@@ -294,7 +294,7 @@ static int sysfs_get_open_dirent(struct=20 +@@ -294,7 +294,7 @@ static int sysfs_get_open_dirent(struct sysfs_dirent= *sd, return -ENOMEM; =20 atomic_set(&new_od->refcnt, 0); @@ -51859,7 +53873,7 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-= 2.6.32.49/fs/sysfs/file.c init_waitqueue_head(&new_od->poll); INIT_LIST_HEAD(&new_od->buffers); goto retry; -@@ -335,7 +335,7 @@ static int sysfs_open_file(struct inode=20 +@@ -335,7 +335,7 @@ static int sysfs_open_file(struct inode *inode, stru= ct file *file) struct sysfs_dirent *attr_sd =3D file->f_path.dentry->d_fsdata; struct kobject *kobj =3D attr_sd->s_parent->s_dir.kobj; struct sysfs_buffer *buffer; @@ -51868,7 +53882,7 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-= 2.6.32.49/fs/sysfs/file.c int error =3D -EACCES; char *p; =20 -@@ -444,7 +444,7 @@ static unsigned int sysfs_poll(struct fi +@@ -444,7 +444,7 @@ static unsigned int sysfs_poll(struct file *filp, po= ll_table *wait) =20 sysfs_put_active_two(attr_sd); =20 @@ -51877,7 +53891,7 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux-= 2.6.32.49/fs/sysfs/file.c goto trigger; =20 return DEFAULT_POLLMASK; -@@ -463,7 +463,7 @@ void sysfs_notify_dirent(struct sysfs_di +@@ -463,7 +463,7 @@ void sysfs_notify_dirent(struct sysfs_dirent *sd) =20 od =3D sd->s_attr.open; if (od) { @@ -51886,9 +53900,10 @@ diff -urNp linux-2.6.32.49/fs/sysfs/file.c linux= -2.6.32.49/fs/sysfs/file.c wake_up_interruptible(&od->poll); } =20 -diff -urNp linux-2.6.32.49/fs/sysfs/mount.c linux-2.6.32.49/fs/sysfs/mou= nt.c ---- linux-2.6.32.49/fs/sysfs/mount.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/sysfs/mount.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/sysfs/mount.c b/fs/sysfs/mount.c +index 4974995..c26609c 100644 +--- a/fs/sysfs/mount.c ++++ b/fs/sysfs/mount.c @@ -36,7 +36,11 @@ struct sysfs_dirent sysfs_root =3D { .s_name =3D "", .s_count =3D ATOMIC_INIT(1), @@ -51901,10 +53916,11 @@ diff -urNp linux-2.6.32.49/fs/sysfs/mount.c lin= ux-2.6.32.49/fs/sysfs/mount.c .s_ino =3D 1, }; =20 -diff -urNp linux-2.6.32.49/fs/sysfs/symlink.c linux-2.6.32.49/fs/sysfs/s= ymlink.c ---- linux-2.6.32.49/fs/sysfs/symlink.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/fs/sysfs/symlink.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -204,7 +204,7 @@ static void *sysfs_follow_link(struct de +diff --git a/fs/sysfs/symlink.c b/fs/sysfs/symlink.c +index c5081ad..342ea86 100644 +--- a/fs/sysfs/symlink.c ++++ b/fs/sysfs/symlink.c +@@ -204,7 +204,7 @@ static void *sysfs_follow_link(struct dentry *dentry= , struct nameidata *nd) =20 static void sysfs_put_link(struct dentry *dentry, struct nameidata *nd,= void *cookie) { @@ -51913,10 +53929,11 @@ diff -urNp linux-2.6.32.49/fs/sysfs/symlink.c l= inux-2.6.32.49/fs/sysfs/symlink.c if (!IS_ERR(page)) free_page((unsigned long)page); } -diff -urNp linux-2.6.32.49/fs/udf/balloc.c linux-2.6.32.49/fs/udf/balloc= .c ---- linux-2.6.32.49/fs/udf/balloc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/udf/balloc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -172,9 +172,7 @@ static void udf_bitmap_free_blocks(struc +diff --git a/fs/udf/balloc.c b/fs/udf/balloc.c +index 1e06853..b06d325 100644 +--- a/fs/udf/balloc.c ++++ b/fs/udf/balloc.c +@@ -172,9 +172,7 @@ static void udf_bitmap_free_blocks(struct super_bloc= k *sb, =20 mutex_lock(&sbi->s_alloc_mutex); partmap =3D &sbi->s_partmaps[bloc->partitionReferenceNum]; @@ -51927,7 +53944,7 @@ diff -urNp linux-2.6.32.49/fs/udf/balloc.c linux-= 2.6.32.49/fs/udf/balloc.c udf_debug("%d < %d || %d + %d > %d\n", bloc->logicalBlockNum, 0, bloc->logicalBlockNum, count, partmap->s_partition_len); -@@ -436,9 +434,7 @@ static void udf_table_free_blocks(struct +@@ -436,9 +434,7 @@ static void udf_table_free_blocks(struct super_block= *sb, =20 mutex_lock(&sbi->s_alloc_mutex); partmap =3D &sbi->s_partmaps[bloc->partitionReferenceNum]; @@ -51938,10 +53955,11 @@ diff -urNp linux-2.6.32.49/fs/udf/balloc.c linu= x-2.6.32.49/fs/udf/balloc.c udf_debug("%d < %d || %d + %d > %d\n", bloc.logicalBlockNum, 0, bloc.logicalBlockNum, count, partmap->s_partition_len); -diff -urNp linux-2.6.32.49/fs/udf/inode.c linux-2.6.32.49/fs/udf/inode.c ---- linux-2.6.32.49/fs/udf/inode.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/udf/inode.c 2011-11-15 19:59:43.000000000 -0500 -@@ -484,6 +484,8 @@ static struct buffer_head *inode_getblk( +diff --git a/fs/udf/inode.c b/fs/udf/inode.c +index 6d24c2c..fff470f 100644 +--- a/fs/udf/inode.c ++++ b/fs/udf/inode.c +@@ -484,6 +484,8 @@ static struct buffer_head *inode_getblk(struct inode= *inode, sector_t block, int goal =3D 0, pgoal =3D iinfo->i_location.logicalBlockNum; int lastblock =3D 0; =20 @@ -51950,10 +53968,11 @@ diff -urNp linux-2.6.32.49/fs/udf/inode.c linux= -2.6.32.49/fs/udf/inode.c prev_epos.offset =3D udf_file_entry_alloc_offset(inode); prev_epos.block =3D iinfo->i_location; prev_epos.bh =3D NULL; -diff -urNp linux-2.6.32.49/fs/udf/misc.c linux-2.6.32.49/fs/udf/misc.c ---- linux-2.6.32.49/fs/udf/misc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/udf/misc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -286,7 +286,7 @@ void udf_new_tag(char *data, uint16_t id +diff --git a/fs/udf/misc.c b/fs/udf/misc.c +index 9215700..bf1f68e 100644 +--- a/fs/udf/misc.c ++++ b/fs/udf/misc.c +@@ -286,7 +286,7 @@ void udf_new_tag(char *data, uint16_t ident, uint16_= t version, uint16_t snum, =20 u8 udf_tag_checksum(const struct tag *t) { @@ -51962,9 +53981,10 @@ diff -urNp linux-2.6.32.49/fs/udf/misc.c linux-2= .6.32.49/fs/udf/misc.c u8 checksum =3D 0; int i; for (i =3D 0; i < sizeof(struct tag); ++i) -diff -urNp linux-2.6.32.49/fs/utimes.c linux-2.6.32.49/fs/utimes.c ---- linux-2.6.32.49/fs/utimes.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/utimes.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/utimes.c b/fs/utimes.c +index e4c75db..b4df0e0 100644 +--- a/fs/utimes.c ++++ b/fs/utimes.c @@ -1,6 +1,7 @@ #include #include @@ -51973,7 +53993,7 @@ diff -urNp linux-2.6.32.49/fs/utimes.c linux-2.6.= 32.49/fs/utimes.c #include #include #include -@@ -101,6 +102,12 @@ static int utimes_common(struct path *pa +@@ -101,6 +102,12 @@ static int utimes_common(struct path *path, struct = timespec *times) goto mnt_drop_write_and_out; } } @@ -51986,23 +54006,10 @@ diff -urNp linux-2.6.32.49/fs/utimes.c linux-2.= 6.32.49/fs/utimes.c mutex_lock(&inode->i_mutex); error =3D notify_change(path->dentry, &newattrs); mutex_unlock(&inode->i_mutex); -diff -urNp linux-2.6.32.49/fs/xattr_acl.c linux-2.6.32.49/fs/xattr_acl.c ---- linux-2.6.32.49/fs/xattr_acl.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/xattr_acl.c 2011-11-15 19:59:43.000000000 -0500 -@@ -17,8 +17,8 @@ - struct posix_acl * - posix_acl_from_xattr(const void *value, size_t size) - { -- posix_acl_xattr_header *header =3D (posix_acl_xattr_header *)value; -- posix_acl_xattr_entry *entry =3D (posix_acl_xattr_entry *)(header+1), = *end; -+ const posix_acl_xattr_header *header =3D (const posix_acl_xattr_header= *)value; -+ const posix_acl_xattr_entry *entry =3D (const posix_acl_xattr_entry *)= (header+1), *end; - int count; - struct posix_acl *acl; - struct posix_acl_entry *acl_e; -diff -urNp linux-2.6.32.49/fs/xattr.c linux-2.6.32.49/fs/xattr.c ---- linux-2.6.32.49/fs/xattr.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/fs/xattr.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/fs/xattr.c b/fs/xattr.c +index 6d4f6d3..cda3958 100644 +--- a/fs/xattr.c ++++ b/fs/xattr.c @@ -247,7 +247,7 @@ EXPORT_SYMBOL_GPL(vfs_removexattr); * Extended attribute SET operations */ @@ -52012,7 +54019,7 @@ diff -urNp linux-2.6.32.49/fs/xattr.c linux-2.6.3= 2.49/fs/xattr.c size_t size, int flags) { int error; -@@ -271,7 +271,13 @@ setxattr(struct dentry *d, const char __ +@@ -271,7 +271,13 @@ setxattr(struct dentry *d, const char __user *name,= const void __user *value, return PTR_ERR(kvalue); } =20 @@ -52027,7 +54034,7 @@ diff -urNp linux-2.6.32.49/fs/xattr.c linux-2.6.3= 2.49/fs/xattr.c kfree(kvalue); return error; } -@@ -288,7 +294,7 @@ SYSCALL_DEFINE5(setxattr, const char __u +@@ -288,7 +294,7 @@ SYSCALL_DEFINE5(setxattr, const char __user *, pathn= ame, return error; error =3D mnt_want_write(path.mnt); if (!error) { @@ -52036,7 +54043,7 @@ diff -urNp linux-2.6.32.49/fs/xattr.c linux-2.6.3= 2.49/fs/xattr.c mnt_drop_write(path.mnt); } path_put(&path); -@@ -307,7 +313,7 @@ SYSCALL_DEFINE5(lsetxattr, const char __ +@@ -307,7 +313,7 @@ SYSCALL_DEFINE5(lsetxattr, const char __user *, path= name, return error; error =3D mnt_want_write(path.mnt); if (!error) { @@ -52045,7 +54052,7 @@ diff -urNp linux-2.6.32.49/fs/xattr.c linux-2.6.3= 2.49/fs/xattr.c mnt_drop_write(path.mnt); } path_put(&path); -@@ -318,17 +324,15 @@ SYSCALL_DEFINE5(fsetxattr, int, fd, cons +@@ -318,17 +324,15 @@ SYSCALL_DEFINE5(fsetxattr, int, fd, const char __u= ser *, name, const void __user *,value, size_t, size, int, flags) { struct file *f; @@ -52065,20 +54072,25 @@ diff -urNp linux-2.6.32.49/fs/xattr.c linux-2.6= .32.49/fs/xattr.c mnt_drop_write(f->f_path.mnt); } fput(f); -diff -urNp linux-2.6.32.49/fs/xfs/linux-2.6/xfs_ioctl32.c linux-2.6.32.4= 9/fs/xfs/linux-2.6/xfs_ioctl32.c ---- linux-2.6.32.49/fs/xfs/linux-2.6/xfs_ioctl32.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/fs/xfs/linux-2.6/xfs_ioctl32.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -75,6 +75,7 @@ xfs_compat_ioc_fsgeometry_v1( - xfs_fsop_geom_t fsgeo; - int error; -=20 -+ memset(&fsgeo, 0, sizeof(fsgeo)); - error =3D xfs_fs_geometry(mp, &fsgeo, 3); - if (error) - return -error; -diff -urNp linux-2.6.32.49/fs/xfs/linux-2.6/xfs_ioctl.c linux-2.6.32.49/= fs/xfs/linux-2.6/xfs_ioctl.c ---- linux-2.6.32.49/fs/xfs/linux-2.6/xfs_ioctl.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/fs/xfs/linux-2.6/xfs_ioctl.c 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/fs/xattr_acl.c b/fs/xattr_acl.c +index c6ad7c7..f2847a7 100644 +--- a/fs/xattr_acl.c ++++ b/fs/xattr_acl.c +@@ -17,8 +17,8 @@ + struct posix_acl * + posix_acl_from_xattr(const void *value, size_t size) + { +- posix_acl_xattr_header *header =3D (posix_acl_xattr_header *)value; +- posix_acl_xattr_entry *entry =3D (posix_acl_xattr_entry *)(header+1), = *end; ++ const posix_acl_xattr_header *header =3D (const posix_acl_xattr_header= *)value; ++ const posix_acl_xattr_entry *entry =3D (const posix_acl_xattr_entry *)= (header+1), *end; + int count; + struct posix_acl *acl; + struct posix_acl_entry *acl_e; +diff --git a/fs/xfs/linux-2.6/xfs_ioctl.c b/fs/xfs/linux-2.6/xfs_ioctl.c +index 942362f..88f96f5 100644 +--- a/fs/xfs/linux-2.6/xfs_ioctl.c ++++ b/fs/xfs/linux-2.6/xfs_ioctl.c @@ -134,7 +134,7 @@ xfs_find_handle( } =20 @@ -52106,9 +54118,22 @@ diff -urNp linux-2.6.32.49/fs/xfs/linux-2.6/xfs_= ioctl.c linux-2.6.32.49/fs/xfs/l int error; =20 error =3D xfs_fs_geometry(mp, &fsgeo, 3); -diff -urNp linux-2.6.32.49/fs/xfs/linux-2.6/xfs_iops.c linux-2.6.32.49/f= s/xfs/linux-2.6/xfs_iops.c ---- linux-2.6.32.49/fs/xfs/linux-2.6/xfs_iops.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/fs/xfs/linux-2.6/xfs_iops.c 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/fs/xfs/linux-2.6/xfs_ioctl32.c b/fs/xfs/linux-2.6/xfs_ioctl= 32.c +index bad485a..479bd32 100644 +--- a/fs/xfs/linux-2.6/xfs_ioctl32.c ++++ b/fs/xfs/linux-2.6/xfs_ioctl32.c +@@ -75,6 +75,7 @@ xfs_compat_ioc_fsgeometry_v1( + xfs_fsop_geom_t fsgeo; + int error; +=20 ++ memset(&fsgeo, 0, sizeof(fsgeo)); + error =3D xfs_fs_geometry(mp, &fsgeo, 3); + if (error) + return -error; +diff --git a/fs/xfs/linux-2.6/xfs_iops.c b/fs/xfs/linux-2.6/xfs_iops.c +index 1f3b4b8..6102f6d 100644 +--- a/fs/xfs/linux-2.6/xfs_iops.c ++++ b/fs/xfs/linux-2.6/xfs_iops.c @@ -468,7 +468,7 @@ xfs_vn_put_link( struct nameidata *nd, void *p) @@ -52118,9 +54143,10 @@ diff -urNp linux-2.6.32.49/fs/xfs/linux-2.6/xfs_= iops.c linux-2.6.32.49/fs/xfs/li =20 if (!IS_ERR(s)) kfree(s); -diff -urNp linux-2.6.32.49/fs/xfs/xfs_bmap.c linux-2.6.32.49/fs/xfs/xfs_= bmap.c ---- linux-2.6.32.49/fs/xfs/xfs_bmap.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/fs/xfs/xfs_bmap.c 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/fs/xfs/xfs_bmap.c b/fs/xfs/xfs_bmap.c +index 8971fb0..5fc1eb2 100644 +--- a/fs/xfs/xfs_bmap.c ++++ b/fs/xfs/xfs_bmap.c @@ -360,7 +360,7 @@ xfs_bmap_validate_ret( int nmap, int ret_nmap); @@ -52130,9 +54156,10 @@ diff -urNp linux-2.6.32.49/fs/xfs/xfs_bmap.c lin= ux-2.6.32.49/fs/xfs/xfs_bmap.c #endif /* DEBUG */ =20 #if defined(XFS_RW_TRACE) -diff -urNp linux-2.6.32.49/fs/xfs/xfs_dir2_sf.c linux-2.6.32.49/fs/xfs/x= fs_dir2_sf.c ---- linux-2.6.32.49/fs/xfs/xfs_dir2_sf.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/fs/xfs/xfs_dir2_sf.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/fs/xfs/xfs_dir2_sf.c b/fs/xfs/xfs_dir2_sf.c +index e89734e..5e84d8d 100644 +--- a/fs/xfs/xfs_dir2_sf.c ++++ b/fs/xfs/xfs_dir2_sf.c @@ -779,7 +779,15 @@ xfs_dir2_sf_getdents( } =20 @@ -52150,9 +54177,10 @@ diff -urNp linux-2.6.32.49/fs/xfs/xfs_dir2_sf.c = linux-2.6.32.49/fs/xfs/xfs_dir2_ off & 0x7fffffff, ino, DT_UNKNOWN)) { *offset =3D off & 0x7fffffff; return 0; -diff -urNp linux-2.6.32.49/fs/xfs/xfs_vnodeops.c linux-2.6.32.49/fs/xfs/= xfs_vnodeops.c ---- linux-2.6.32.49/fs/xfs/xfs_vnodeops.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/fs/xfs/xfs_vnodeops.c 2011-11-18 18:59:38.000000000 = -0500 +diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c +index 8f32f50..859e8a3 100644 +--- a/fs/xfs/xfs_vnodeops.c ++++ b/fs/xfs/xfs_vnodeops.c @@ -564,13 +564,17 @@ xfs_readlink( =20 xfs_ilock(ip, XFS_ILOCK_SHARED); @@ -52174,1860 +54202,2837 @@ diff -urNp linux-2.6.32.49/fs/xfs/xfs_vnode= ops.c linux-2.6.32.49/fs/xfs/xfs_vnod if (ip->i_df.if_flags & XFS_IFINLINE) { memcpy(link, ip->i_df.if_u1.if_data, pathlen); link[pathlen] =3D '\0'; -diff -urNp linux-2.6.32.49/grsecurity/gracl_alloc.c linux-2.6.32.49/grse= curity/gracl_alloc.c ---- linux-2.6.32.49/grsecurity/gracl_alloc.c 1969-12-31 19:00:00.0000000= 00 -0500 -+++ linux-2.6.32.49/grsecurity/gracl_alloc.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -0,0 +1,105 @@ -+#include -+#include -+#include -+#include -+#include -+#include -+ -+static unsigned long alloc_stack_next =3D 1; -+static unsigned long alloc_stack_size =3D 1; -+static void **alloc_stack; +diff --git a/grsecurity/Kconfig b/grsecurity/Kconfig +new file mode 100644 +index 0000000..f27a8e8 +--- /dev/null ++++ b/grsecurity/Kconfig +@@ -0,0 +1,1036 @@ ++# ++# grecurity configuration ++# + -+static __inline__ int -+alloc_pop(void) -+{ -+ if (alloc_stack_next =3D=3D 1) -+ return 0; ++menu "Grsecurity" + -+ kfree(alloc_stack[alloc_stack_next - 2]); ++config GRKERNSEC ++ bool "Grsecurity" ++ select CRYPTO ++ select CRYPTO_SHA256 ++ help ++ If you say Y here, you will be able to configure many features ++ that will enhance the security of your system. It is highly ++ recommended that you say Y here and read through the help ++ for each option so that you fully understand the features and ++ can evaluate their usefulness for your machine. + -+ alloc_stack_next--; ++choice ++ prompt "Security Level" ++ depends on GRKERNSEC ++ default GRKERNSEC_CUSTOM + -+ return 1; -+} ++config GRKERNSEC_LOW ++ bool "Low" ++ select GRKERNSEC_LINK ++ select GRKERNSEC_FIFO ++ select GRKERNSEC_RANDNET ++ select GRKERNSEC_DMESG ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_CHDIR + -+static __inline__ int -+alloc_push(void *buf) -+{ -+ if (alloc_stack_next >=3D alloc_stack_size) -+ return 1; ++ help ++ If you choose this option, several of the grsecurity options will ++ be enabled that will give you greater protection against a number ++ of attacks, while assuring that none of your software will have any ++ conflicts with the additional security measures. If you run a lot ++ of unusual software, or you are having problems with the higher ++ security levels, you should say Y here. With this option, the ++ following features are enabled: + -+ alloc_stack[alloc_stack_next - 1] =3D buf; ++ - Linking restrictions ++ - FIFO restrictions ++ - Restricted dmesg ++ - Enforced chdir("/") on chroot ++ - Runtime module disabling + -+ alloc_stack_next++; ++config GRKERNSEC_MEDIUM ++ bool "Medium" ++ select PAX ++ select PAX_EI_PAX ++ select PAX_PT_PAX_FLAGS ++ select PAX_HAVE_ACL_FLAGS ++ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_SYSCTL ++ select GRKERNSEC_LINK ++ select GRKERNSEC_FIFO ++ select GRKERNSEC_DMESG ++ select GRKERNSEC_RANDNET ++ select GRKERNSEC_FORKFAIL ++ select GRKERNSEC_TIME ++ select GRKERNSEC_SIGNAL ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_UNIX ++ select GRKERNSEC_CHROOT_MOUNT ++ select GRKERNSEC_CHROOT_PIVOT ++ select GRKERNSEC_CHROOT_DOUBLE ++ select GRKERNSEC_CHROOT_CHDIR ++ select GRKERNSEC_CHROOT_MKNOD ++ select GRKERNSEC_PROC ++ select GRKERNSEC_PROC_USERGROUP ++ select PAX_RANDUSTACK ++ select PAX_ASLR ++ select PAX_RANDMMAP ++ select PAX_REFCOUNT if (X86 || SPARC64) ++ select PAX_USERCOPY if ((X86 || SPARC || PPC || ARM) && (SLAB || SLUB = || SLOB)) + -+ return 0; -+} ++ help ++ If you say Y here, several features in addition to those included ++ in the low additional security level will be enabled. These ++ features provide even more security to your system, though in rare ++ cases they may be incompatible with very old or poorly written ++ software. If you enable this option, make sure that your auth ++ service (identd) is running as gid 1001. With this option,=20 ++ the following features (in addition to those provided in the=20 ++ low additional security level) will be enabled: + -+void * -+acl_alloc(unsigned long len) -+{ -+ void *ret =3D NULL; ++ - Failed fork logging ++ - Time change logging ++ - Signal logging ++ - Deny mounts in chroot ++ - Deny double chrooting ++ - Deny sysctl writes in chroot ++ - Deny mknod in chroot ++ - Deny access to abstract AF_UNIX sockets out of chroot ++ - Deny pivot_root in chroot ++ - Denied reads/writes of /dev/kmem, /dev/mem, and /dev/port ++ - /proc restrictions with special GID set to 10 (usually wheel) ++ - Address Space Layout Randomization (ASLR) ++ - Prevent exploitation of most refcount overflows ++ - Bounds checking of copying between the kernel and userland + -+ if (!len || len > PAGE_SIZE) -+ goto out; ++config GRKERNSEC_HIGH ++ bool "High" ++ select GRKERNSEC_LINK ++ select GRKERNSEC_FIFO ++ select GRKERNSEC_DMESG ++ select GRKERNSEC_FORKFAIL ++ select GRKERNSEC_TIME ++ select GRKERNSEC_SIGNAL ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_SHMAT ++ select GRKERNSEC_CHROOT_UNIX ++ select GRKERNSEC_CHROOT_MOUNT ++ select GRKERNSEC_CHROOT_FCHDIR ++ select GRKERNSEC_CHROOT_PIVOT ++ select GRKERNSEC_CHROOT_DOUBLE ++ select GRKERNSEC_CHROOT_CHDIR ++ select GRKERNSEC_CHROOT_MKNOD ++ select GRKERNSEC_CHROOT_CAPS ++ select GRKERNSEC_CHROOT_SYSCTL ++ select GRKERNSEC_CHROOT_FINDTASK ++ select GRKERNSEC_SYSFS_RESTRICT ++ select GRKERNSEC_PROC ++ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) ++ select GRKERNSEC_HIDESYM ++ select GRKERNSEC_BRUTE ++ select GRKERNSEC_PROC_USERGROUP ++ select GRKERNSEC_KMEM ++ select GRKERNSEC_RESLOG ++ select GRKERNSEC_RANDNET ++ select GRKERNSEC_PROC_ADD ++ select GRKERNSEC_CHROOT_CHMOD ++ select GRKERNSEC_CHROOT_NICE ++ select GRKERNSEC_AUDIT_MOUNT ++ select GRKERNSEC_MODHARDEN if (MODULES) ++ select GRKERNSEC_HARDEN_PTRACE ++ select GRKERNSEC_VM86 if (X86_32) ++ select GRKERNSEC_KERN_LOCKOUT if (X86 || ARM || PPC || SPARC) ++ select PAX ++ select PAX_RANDUSTACK ++ select PAX_ASLR ++ select PAX_RANDMMAP ++ select PAX_NOEXEC ++ select PAX_MPROTECT ++ select PAX_EI_PAX ++ select PAX_PT_PAX_FLAGS ++ select PAX_HAVE_ACL_FLAGS ++ select PAX_KERNEXEC if ((PPC || X86) && (!X86_32 || X86_WP_WORKS_OK) &= & !XEN) ++ select PAX_MEMORY_UDEREF if (X86 && !XEN) ++ select PAX_RANDKSTACK if (X86_TSC && X86) ++ select PAX_SEGMEXEC if (X86_32) ++ select PAX_PAGEEXEC ++ select PAX_EMUPLT if (ALPHA || PARISC || SPARC) ++ select PAX_EMUTRAMP if (PARISC) ++ select PAX_EMUSIGRT if (PARISC) ++ select PAX_ETEXECRELOCS if (ALPHA || IA64 || PARISC) ++ select PAX_ELFRELOCS if (PAX_ETEXECRELOCS || (IA64 || PPC || X86)) ++ select PAX_REFCOUNT if (X86 || SPARC64) ++ select PAX_USERCOPY if ((X86 || SPARC || PPC || ARM) && (SLAB || SLUB = || SLOB)) ++ help ++ If you say Y here, many of the features of grsecurity will be ++ enabled, which will protect you against many kinds of attacks ++ against your system. The heightened security comes at a cost ++ of an increased chance of incompatibilities with rare software ++ on your machine. Since this security level enables PaX, you should ++ view and read about the PaX ++ project. While you are there, download chpax and run it on ++ binaries that cause problems with PaX. Also remember that ++ since the /proc restrictions are enabled, you must run your ++ identd as gid 1001. This security level enables the following=20 ++ features in addition to those listed in the low and medium=20 ++ security levels: + -+ ret =3D kmalloc(len, GFP_KERNEL); ++ - Additional /proc restrictions ++ - Chmod restrictions in chroot ++ - No signals, ptrace, or viewing of processes outside of chroot ++ - Capability restrictions in chroot ++ - Deny fchdir out of chroot ++ - Priority restrictions in chroot ++ - Segmentation-based implementation of PaX ++ - Mprotect restrictions ++ - Removal of addresses from /proc//[smaps|maps|stat] ++ - Kernel stack randomization ++ - Mount/unmount/remount logging ++ - Kernel symbol hiding ++ - Hardening of module auto-loading ++ - Ptrace restrictions ++ - Restricted vm86 mode ++ - Restricted sysfs/debugfs ++ - Active kernel exploit response + -+ if (ret) { -+ if (alloc_push(ret)) { -+ kfree(ret); -+ ret =3D NULL; -+ } -+ } ++config GRKERNSEC_CUSTOM ++ bool "Custom" ++ help ++ If you say Y here, you will be able to configure every grsecurity ++ option, which allows you to enable many more features that aren't ++ covered in the basic security levels. These additional features ++ include TPE, socket restrictions, and the sysctl system for ++ grsecurity. It is advised that you read through the help for ++ each option to determine its usefulness in your situation. + -+out: -+ return ret; -+} ++endchoice + -+void * -+acl_alloc_num(unsigned long num, unsigned long len) -+{ -+ if (!len || (num > (PAGE_SIZE / len))) -+ return NULL; ++menu "Address Space Protection" ++depends on GRKERNSEC + -+ return acl_alloc(num * len); -+} ++config GRKERNSEC_KMEM ++ bool "Deny reading/writing to /dev/kmem, /dev/mem, and /dev/port" ++ select STRICT_DEVMEM if (X86 || ARM || TILE || S390) ++ help ++ If you say Y here, /dev/kmem and /dev/mem won't be allowed to ++ be written to or read from to modify or leak the contents of the run= ning ++ kernel. /dev/port will also not be allowed to be opened. If you hav= e module ++ support disabled, enabling this will close up four ways that are ++ currently used to insert malicious code into the running kernel. ++ Even with all these features enabled, we still highly recommend that ++ you use the RBAC system, as it is still possible for an attacker to ++ modify the running kernel through privileged I/O granted by ioperm/i= opl. ++ If you are not using XFree86, you may be able to stop this additiona= l ++ case by enabling the 'Disable privileged I/O' option. Though nothing ++ legitimately writes to /dev/kmem, XFree86 does need to write to /dev= /mem, ++ but only to video memory, which is the only writing we allow in this ++ case. If /dev/kmem or /dev/mem are mmaped without PROT_WRITE, they = will ++ not be allowed to mprotect it with PROT_WRITE later. ++ It is highly recommended that you say Y here if you meet all the ++ conditions above. + -+void -+acl_free_all(void) -+{ -+ if (gr_acl_is_enabled() || !alloc_stack) -+ return; ++config GRKERNSEC_VM86 ++ bool "Restrict VM86 mode" ++ depends on X86_32 + -+ while (alloc_pop()) ; ++ help ++ If you say Y here, only processes with CAP_SYS_RAWIO will be able to ++ make use of a special execution mode on 32bit x86 processors called ++ Virtual 8086 (VM86) mode. XFree86 may need vm86 mode for certain ++ video cards and will still work with this option enabled. The purpo= se ++ of the option is to prevent exploitation of emulation errors in ++ virtualization of vm86 mode like the one discovered in VMWare in 200= 9. ++ Nearly all users should be able to enable this option. + -+ if (alloc_stack) { -+ if ((alloc_stack_size * sizeof (void *)) <=3D PAGE_SIZE) -+ kfree(alloc_stack); -+ else -+ vfree(alloc_stack); -+ } ++config GRKERNSEC_IO ++ bool "Disable privileged I/O" ++ depends on X86 ++ select RTC_CLASS ++ select RTC_INTF_DEV ++ select RTC_DRV_CMOS + -+ alloc_stack =3D NULL; -+ alloc_stack_size =3D 1; -+ alloc_stack_next =3D 1; ++ help ++ If you say Y here, all ioperm and iopl calls will return an error. ++ Ioperm and iopl can be used to modify the running kernel. ++ Unfortunately, some programs need this access to operate properly, ++ the most notable of which are XFree86 and hwclock. hwclock can be ++ remedied by having RTC support in the kernel, so real-time=20 ++ clock support is enabled if this option is enabled, to ensure=20 ++ that hwclock operates correctly. XFree86 still will not=20 ++ operate correctly with this option enabled, so DO NOT CHOOSE Y=20 ++ IF YOU USE XFree86. If you use XFree86 and you still want to=20 ++ protect your kernel against modification, use the RBAC system. + -+ return; -+} ++config GRKERNSEC_PROC_MEMMAP ++ bool "Remove addresses from /proc//[smaps|maps|stat]" ++ default y if (PAX_NOEXEC || PAX_ASLR) ++ depends on PAX_NOEXEC || PAX_ASLR ++ help ++ If you say Y here, the /proc//maps and /proc//stat files w= ill ++ give no information about the addresses of its mappings if ++ PaX features that rely on random addresses are enabled on the task. ++ If you use PaX it is greatly recommended that you say Y here as it ++ closes up a hole that makes the full ASLR useless for suid ++ binaries. + -+int -+acl_alloc_stack_init(unsigned long size) -+{ -+ if ((size * sizeof (void *)) <=3D PAGE_SIZE) -+ alloc_stack =3D -+ (void **) kmalloc(size * sizeof (void *), GFP_KERNEL); -+ else -+ alloc_stack =3D (void **) vmalloc(size * sizeof (void *)); ++config GRKERNSEC_BRUTE ++ bool "Deter exploit bruteforcing" ++ help ++ If you say Y here, attempts to bruteforce exploits against forking ++ daemons such as apache or sshd, as well as against suid/sgid binarie= s ++ will be deterred. When a child of a forking daemon is killed by PaX ++ or crashes due to an illegal instruction or other suspicious signal, ++ the parent process will be delayed 30 seconds upon every subsequent ++ fork until the administrator is able to assess the situation and ++ restart the daemon. ++ In the suid/sgid case, the attempt is logged, the user has all their ++ processes terminated, and they are prevented from executing any furt= her ++ processes for 15 minutes. ++ It is recommended that you also enable signal logging in the auditin= g ++ section so that logs are generated when a process triggers a suspici= ous ++ signal. ++ If the sysctl option is enabled, a sysctl option with name ++ "deter_bruteforce" is created. + -+ alloc_stack_size =3D size; ++config GRKERNSEC_MODHARDEN ++ bool "Harden module auto-loading" ++ depends on MODULES ++ help ++ If you say Y here, module auto-loading in response to use of some ++ feature implemented by an unloaded module will be restricted to ++ root users. Enabling this option helps defend against attacks=20 ++ by unprivileged users who abuse the auto-loading behavior to=20 ++ cause a vulnerable module to load that is then exploited. + -+ if (!alloc_stack) -+ return 0; -+ else -+ return 1; -+} -diff -urNp linux-2.6.32.49/grsecurity/gracl.c linux-2.6.32.49/grsecurity= /gracl.c ---- linux-2.6.32.49/grsecurity/gracl.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-2.6.32.49/grsecurity/gracl.c 2011-11-16 17:55:28.000000000 -05= 00 -@@ -0,0 +1,4141 @@ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include ++ If this option prevents a legitimate use of auto-loading for a=20 ++ non-root user, the administrator can execute modprobe manually=20 ++ with the exact name of the module mentioned in the alert log. ++ Alternatively, the administrator can add the module to the list ++ of modules loaded at boot by modifying init scripts. + -+#include -+#include -+#include ++ Modification of init scripts will most likely be needed on=20 ++ Ubuntu servers with encrypted home directory support enabled, ++ as the first non-root user logging in will cause the ecb(aes), ++ ecb(aes)-all, cbc(aes), and cbc(aes)-all modules to be loaded. + -+static struct acl_role_db acl_role_set; -+static struct name_db name_set; -+static struct inodev_db inodev_set; ++config GRKERNSEC_HIDESYM ++ bool "Hide kernel symbols" ++ help ++ If you say Y here, getting information on loaded modules, and ++ displaying all kernel symbols through a syscall will be restricted ++ to users with CAP_SYS_MODULE. For software compatibility reasons, ++ /proc/kallsyms will be restricted to the root user. The RBAC ++ system can hide that entry even from root. + -+/* for keeping track of userspace pointers used for subjects, so we -+ can share references in the kernel as well -+*/ ++ This option also prevents leaking of kernel addresses through ++ several /proc entries. + -+static struct dentry *real_root; -+static struct vfsmount *real_root_mnt; ++ Note that this option is only effective provided the following ++ conditions are met: ++ 1) The kernel using grsecurity is not precompiled by some distributi= on ++ 2) You have also enabled GRKERNSEC_DMESG ++ 3) You are using the RBAC system and hiding other files such as your ++ kernel image and System.map. Alternatively, enabling this option ++ causes the permissions on /boot, /lib/modules, and the kernel ++ source directory to change at compile time to prevent=20 ++ reading by non-root users. ++ If the above conditions are met, this option will aid in providing a ++ useful protection against local kernel exploitation of overflows ++ and arbitrary read/write vulnerabilities. + -+static struct acl_subj_map_db subj_map_set; ++config GRKERNSEC_KERN_LOCKOUT ++ bool "Active kernel exploit response" ++ depends on X86 || ARM || PPC || SPARC ++ help ++ If you say Y here, when a PaX alert is triggered due to suspicious ++ activity in the kernel (from KERNEXEC/UDEREF/USERCOPY) ++ or an OOPs occurs due to bad memory accesses, instead of just ++ terminating the offending process (and potentially allowing ++ a subsequent exploit from the same user), we will take one of two ++ actions: ++ If the user was root, we will panic the system ++ If the user was non-root, we will log the attempt, terminate ++ all processes owned by the user, then prevent them from creating ++ any new processes until the system is restarted ++ This deters repeated kernel exploitation/bruteforcing attempts ++ and is useful for later forensics. + -+static struct acl_role_label *default_role; ++endmenu ++menu "Role Based Access Control Options" ++depends on GRKERNSEC + -+static struct acl_role_label *role_list; ++config GRKERNSEC_RBAC_DEBUG ++ bool + -+static u16 acl_sp_role_value; ++config GRKERNSEC_NO_RBAC ++ bool "Disable RBAC system" ++ help ++ If you say Y here, the /dev/grsec device will be removed from the ke= rnel, ++ preventing the RBAC system from being enabled. You should only say = Y ++ here if you have no intention of using the RBAC system, so as to pre= vent ++ an attacker with root access from misusing the RBAC system to hide f= iles ++ and processes when loadable module support and /dev/[k]mem have been ++ locked down. + -+extern char *gr_shared_page[4]; -+static DEFINE_MUTEX(gr_dev_mutex); -+DEFINE_RWLOCK(gr_inode_lock); ++config GRKERNSEC_ACL_HIDEKERN ++ bool "Hide kernel processes" ++ help ++ If you say Y here, all kernel threads will be hidden to all ++ processes but those whose subject has the "view hidden processes" ++ flag. + -+struct gr_arg *gr_usermode; ++config GRKERNSEC_ACL_MAXTRIES ++ int "Maximum tries before password lockout" ++ default 3 ++ help ++ This option enforces the maximum number of times a user can attempt ++ to authorize themselves with the grsecurity RBAC system before being ++ denied the ability to attempt authorization again for a specified ti= me. ++ The lower the number, the harder it will be to brute-force a passwor= d. + -+static unsigned int gr_status __read_only =3D GR_STATUS_INIT; ++config GRKERNSEC_ACL_TIMEOUT ++ int "Time to wait after max password tries, in seconds" ++ default 30 ++ help ++ This option specifies the time the user must wait after attempting t= o ++ authorize to the RBAC system with the maximum number of invalid ++ passwords. The higher the number, the harder it will be to brute-fo= rce ++ a password. + -+extern int chkpw(struct gr_arg *entry, unsigned char *salt, unsigned ch= ar *sum); -+extern void gr_clear_learn_entries(void); ++endmenu ++menu "Filesystem Protections" ++depends on GRKERNSEC + -+#ifdef CONFIG_GRKERNSEC_RESLOG -+extern void gr_log_resource(const struct task_struct *task, -+ const int res, const unsigned long wanted, const int gt); -+#endif ++config GRKERNSEC_PROC ++ bool "Proc restrictions" ++ help ++ If you say Y here, the permissions of the /proc filesystem ++ will be altered to enhance system security and privacy. You MUST ++ choose either a user only restriction or a user and group restrict= ion. ++ Depending upon the option you choose, you can either restrict users = to ++ see only the processes they themselves run, or choose a group that c= an ++ view all processes and files normally restricted to root if you choo= se ++ the "restrict to user only" option. NOTE: If you're running identd = as ++ a non-root user, you will have to run it as the group you specify he= re. + -+unsigned char *gr_system_salt; -+unsigned char *gr_system_sum; ++config GRKERNSEC_PROC_USER ++ bool "Restrict /proc to user only" ++ depends on GRKERNSEC_PROC ++ help ++ If you say Y here, non-root users will only be able to view their ow= n ++ processes, and restricts them from viewing network-related informati= on, ++ and viewing kernel symbol and module information. + -+static struct sprole_pw **acl_special_roles =3D NULL; -+static __u16 num_sprole_pws =3D 0; ++config GRKERNSEC_PROC_USERGROUP ++ bool "Allow special group" ++ depends on GRKERNSEC_PROC && !GRKERNSEC_PROC_USER ++ help ++ If you say Y here, you will be able to select a group that will be ++ able to view all processes and network-related information. If you'= ve ++ enabled GRKERNSEC_HIDESYM, kernel and symbol information may still ++ remain hidden. This option is useful if you want to run identd as ++ a non-root user. + -+static struct acl_role_label *kernel_role =3D NULL; ++config GRKERNSEC_PROC_GID ++ int "GID for special group" ++ depends on GRKERNSEC_PROC_USERGROUP ++ default 1001 + -+static unsigned int gr_auth_attempts =3D 0; -+static unsigned long gr_auth_expires =3D 0UL; ++config GRKERNSEC_PROC_ADD ++ bool "Additional restrictions" ++ depends on GRKERNSEC_PROC_USER || GRKERNSEC_PROC_USERGROUP ++ help ++ If you say Y here, additional restrictions will be placed on ++ /proc that keep normal users from viewing device information and=20 ++ slabinfo information that could be useful for exploits. + -+#ifdef CONFIG_NET -+extern struct vfsmount *sock_mnt; -+#endif -+extern struct vfsmount *pipe_mnt; -+extern struct vfsmount *shm_mnt; -+#ifdef CONFIG_HUGETLBFS -+extern struct vfsmount *hugetlbfs_vfsmount; -+#endif ++config GRKERNSEC_LINK ++ bool "Linking restrictions" ++ help ++ If you say Y here, /tmp race exploits will be prevented, since users ++ will no longer be able to follow symlinks owned by other users in ++ world-writable +t directories (e.g. /tmp), unless the owner of the ++ symlink is the owner of the directory. users will also not be ++ able to hardlink to files they do not own. If the sysctl option is ++ enabled, a sysctl option with name "linking_restrictions" is created= . + -+static struct acl_object_label *fakefs_obj_rw; -+static struct acl_object_label *fakefs_obj_rwx; ++config GRKERNSEC_FIFO ++ bool "FIFO restrictions" ++ help ++ If you say Y here, users will not be able to write to FIFOs they don= 't ++ own in world-writable +t directories (e.g. /tmp), unless the owner o= f ++ the FIFO is the same owner of the directory it's held in. If the sy= sctl ++ option is enabled, a sysctl option with name "fifo_restrictions" is ++ created. + -+extern int gr_init_uidset(void); -+extern void gr_free_uidset(void); -+extern void gr_remove_uid(uid_t uid); -+extern int gr_find_uid(uid_t uid); ++config GRKERNSEC_SYSFS_RESTRICT ++ bool "Sysfs/debugfs restriction" ++ depends on SYSFS ++ help ++ If you say Y here, sysfs (the pseudo-filesystem mounted at /sys) and ++ any filesystem normally mounted under it (e.g. debugfs) will only ++ be accessible by root. These filesystems generally provide access ++ to hardware and debug information that isn't appropriate for unprivi= leged ++ users of the system. Sysfs and debugfs have also become a large sou= rce ++ of new vulnerabilities, ranging from infoleaks to local compromise. ++ There has been very little oversight with an eye toward security inv= olved ++ in adding new exporters of information to these filesystems, so thei= r ++ use is discouraged. ++ This option is equivalent to a chmod 0700 of the mount paths. + -+__inline__ int -+gr_acl_is_enabled(void) -+{ -+ return (gr_status & GR_READY); -+} ++config GRKERNSEC_ROFS ++ bool "Runtime read-only mount protection" ++ help ++ If you say Y here, a sysctl option with name "romount_protect" will ++ be created. By setting this option to 1 at runtime, filesystems ++ will be protected in the following ways: ++ * No new writable mounts will be allowed ++ * Existing read-only mounts won't be able to be remounted read/write ++ * Write operations will be denied on all block devices ++ This option acts independently of grsec_lock: once it is set to 1, ++ it cannot be turned off. Therefore, please be mindful of the result= ing ++ behavior if this option is enabled in an init script on a read-only ++ filesystem. This feature is mainly intended for secure embedded sys= tems. + -+#ifdef CONFIG_BTRFS_FS -+extern dev_t get_btrfs_dev_from_inode(struct inode *inode); -+extern int btrfs_getattr(struct vfsmount *mnt, struct dentry *dentry, s= truct kstat *stat); -+#endif ++config GRKERNSEC_CHROOT ++ bool "Chroot jail restrictions" ++ help ++ If you say Y here, you will be able to choose several options that w= ill ++ make breaking out of a chrooted jail much more difficult. If you ++ encounter no software incompatibilities with the following options, = it ++ is recommended that you enable each one. + -+static inline dev_t __get_dev(const struct dentry *dentry) -+{ -+#ifdef CONFIG_BTRFS_FS -+ if (dentry->d_inode->i_op && dentry->d_inode->i_op->getattr =3D=3D &bt= rfs_getattr) -+ return get_btrfs_dev_from_inode(dentry->d_inode); -+ else -+#endif -+ return dentry->d_inode->i_sb->s_dev; -+} ++config GRKERNSEC_CHROOT_MOUNT ++ bool "Deny mounts" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to ++ mount or remount filesystems. If the sysctl option is enabled, a ++ sysctl option with name "chroot_deny_mount" is created. + -+dev_t gr_get_dev_from_dentry(struct dentry *dentry) -+{ -+ return __get_dev(dentry); -+} ++config GRKERNSEC_CHROOT_DOUBLE ++ bool "Deny double-chroots" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to chr= oot ++ again outside the chroot. This is a widely used method of breaking ++ out of a chroot jail and should not be allowed. If the sysctl=20 ++ option is enabled, a sysctl option with name=20 ++ "chroot_deny_chroot" is created. + -+static char gr_task_roletype_to_char(struct task_struct *task) -+{ -+ switch (task->role->roletype & -+ (GR_ROLE_DEFAULT | GR_ROLE_USER | GR_ROLE_GROUP | -+ GR_ROLE_SPECIAL)) { -+ case GR_ROLE_DEFAULT: -+ return 'D'; -+ case GR_ROLE_USER: -+ return 'U'; -+ case GR_ROLE_GROUP: -+ return 'G'; -+ case GR_ROLE_SPECIAL: -+ return 'S'; -+ } ++config GRKERNSEC_CHROOT_PIVOT ++ bool "Deny pivot_root in chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to use ++ a function called pivot_root() that was introduced in Linux 2.3.41. = It ++ works similar to chroot in that it changes the root filesystem. Thi= s ++ function could be misused in a chrooted process to attempt to break = out ++ of the chroot, and therefore should not be allowed. If the sysctl ++ option is enabled, a sysctl option with name "chroot_deny_pivot" is ++ created. + -+ return 'X'; -+} ++config GRKERNSEC_CHROOT_CHDIR ++ bool "Enforce chdir(\"/\") on all chroots" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, the current working directory of all newly-chroot= ed ++ applications will be set to the the root directory of the chroot. ++ The man page on chroot(2) states: ++ Note that this call does not change the current working ++ directory, so that `.' can be outside the tree rooted at ++ `/'. In particular, the super-user can escape from a ++ `chroot jail' by doing `mkdir foo; chroot foo; cd ..'. + -+char gr_roletype_to_char(void) -+{ -+ return gr_task_roletype_to_char(current); -+} ++ It is recommended that you say Y here, since it's not known to break ++ any software. If the sysctl option is enabled, a sysctl option with ++ name "chroot_enforce_chdir" is created. + -+__inline__ int -+gr_acl_tpe_check(void) -+{ -+ if (unlikely(!(gr_status & GR_READY))) -+ return 0; -+ if (current->role->roletype & GR_ROLE_TPE) -+ return 1; -+ else -+ return 0; -+} ++config GRKERNSEC_CHROOT_CHMOD ++ bool "Deny (f)chmod +s" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to chm= od ++ or fchmod files to make them have suid or sgid bits. This protects ++ against another published method of breaking a chroot. If the sysct= l ++ option is enabled, a sysctl option with name "chroot_deny_chmod" is ++ created. + -+int -+gr_handle_rawio(const struct inode *inode) -+{ -+#ifdef CONFIG_GRKERNSEC_CHROOT_CAPS -+ if (inode && S_ISBLK(inode->i_mode) && -+ grsec_enable_chroot_caps && proc_is_chrooted(current) && -+ !capable(CAP_SYS_RAWIO)) -+ return 1; -+#endif -+ return 0; -+} ++config GRKERNSEC_CHROOT_FCHDIR ++ bool "Deny fchdir out of chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, a well-known method of breaking chroots by fchdir= 'ing ++ to a file descriptor of the chrooting process that points to a direc= tory ++ outside the filesystem will be stopped. If the sysctl option ++ is enabled, a sysctl option with name "chroot_deny_fchdir" is create= d. + -+static int -+gr_streq(const char *a, const char *b, const unsigned int lena, const u= nsigned int lenb) -+{ -+ if (likely(lena !=3D lenb)) -+ return 0; ++config GRKERNSEC_CHROOT_MKNOD ++ bool "Deny mknod" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be allowed to ++ mknod. The problem with using mknod inside a chroot is that it ++ would allow an attacker to create a device entry that is the same ++ as one on the physical root of your system, which could range from ++ anything from the console device to a device for your harddrive (whi= ch ++ they could then use to wipe the drive or steal data). It is recomme= nded ++ that you say Y here, unless you run into software incompatibilities. ++ If the sysctl option is enabled, a sysctl option with name ++ "chroot_deny_mknod" is created. + -+ return !memcmp(a, b, lena); -+} ++config GRKERNSEC_CHROOT_SHMAT ++ bool "Deny shmat() out of chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to att= ach ++ to shared memory segments that were created outside of the chroot ja= il. ++ It is recommended that you say Y here. If the sysctl option is enab= led, ++ a sysctl option with name "chroot_deny_shmat" is created. + -+static int prepend(char **buffer, int *buflen, const char *str, int nam= elen) -+{ -+ *buflen -=3D namelen; -+ if (*buflen < 0) -+ return -ENAMETOOLONG; -+ *buffer -=3D namelen; -+ memcpy(*buffer, str, namelen); -+ return 0; -+} ++config GRKERNSEC_CHROOT_UNIX ++ bool "Deny access to abstract AF_UNIX sockets out of chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to ++ connect to abstract (meaning not belonging to a filesystem) Unix ++ domain sockets that were bound outside of a chroot. It is recommend= ed ++ that you say Y here. If the sysctl option is enabled, a sysctl opti= on ++ with name "chroot_deny_unix" is created. + -+/* this must be called with vfsmount_lock and dcache_lock held */ ++config GRKERNSEC_CHROOT_FINDTASK ++ bool "Protect outside processes" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to ++ kill, send signals with fcntl, ptrace, capget, getpgid, setpgid,=20 ++ getsid, or view any process outside of the chroot. If the sysctl ++ option is enabled, a sysctl option with name "chroot_findtask" is ++ created. + -+static char * __our_d_path(struct dentry *dentry, struct vfsmount *vfsm= nt, -+ struct dentry *root, struct vfsmount *rootmnt, -+ char *buffer, int buflen) -+{ -+ char * end =3D buffer+buflen; -+ char * retval; -+ int namelen; ++config GRKERNSEC_CHROOT_NICE ++ bool "Restrict priority changes" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to rai= se ++ the priority of processes in the chroot, or alter the priority of ++ processes outside the chroot. This provides more security than simp= ly ++ removing CAP_SYS_NICE from the process' capability set. If the ++ sysctl option is enabled, a sysctl option with name "chroot_restrict= _nice" ++ is created. + -+ *--end =3D '\0'; -+ buflen--; ++config GRKERNSEC_CHROOT_SYSCTL ++ bool "Deny sysctl writes" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, an attacker in a chroot will not be able to ++ write to sysctl entries, either by sysctl(2) or through a /proc ++ interface. It is strongly recommended that you say Y here. If the ++ sysctl option is enabled, a sysctl option with name ++ "chroot_deny_sysctl" is created. + -+ if (buflen < 1) -+ goto Elong; -+ /* Get '/' right */ -+ retval =3D end-1; -+ *retval =3D '/'; ++config GRKERNSEC_CHROOT_CAPS ++ bool "Capability restrictions" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, the capabilities on all processes within a ++ chroot jail will be lowered to stop module insertion, raw i/o, ++ system and net admin tasks, rebooting the system, modifying immutabl= e ++ files, modifying IPC owned by another, and changing the system time. ++ This is left an option because it can break some apps. Disable this ++ if your chrooted apps are having problems performing those kinds of ++ tasks. If the sysctl option is enabled, a sysctl option with ++ name "chroot_caps" is created. + -+ for (;;) { -+ struct dentry * parent; ++endmenu ++menu "Kernel Auditing" ++depends on GRKERNSEC + -+ if (dentry =3D=3D root && vfsmnt =3D=3D rootmnt) -+ break; -+ if (dentry =3D=3D vfsmnt->mnt_root || IS_ROOT(dentry)) { -+ /* Global root? */ -+ if (vfsmnt->mnt_parent =3D=3D vfsmnt) -+ goto global_root; -+ dentry =3D vfsmnt->mnt_mountpoint; -+ vfsmnt =3D vfsmnt->mnt_parent; -+ continue; -+ } -+ parent =3D dentry->d_parent; -+ prefetch(parent); -+ namelen =3D dentry->d_name.len; -+ buflen -=3D namelen + 1; -+ if (buflen < 0) -+ goto Elong; -+ end -=3D namelen; -+ memcpy(end, dentry->d_name.name, namelen); -+ *--end =3D '/'; -+ retval =3D end; -+ dentry =3D parent; -+ } -+ -+out: -+ return retval; -+ -+global_root: -+ namelen =3D dentry->d_name.len; -+ buflen -=3D namelen; -+ if (buflen < 0) -+ goto Elong; -+ retval -=3D namelen-1; /* hit the slash */ -+ memcpy(retval, dentry->d_name.name, namelen); -+ goto out; -+Elong: -+ retval =3D ERR_PTR(-ENAMETOOLONG); -+ goto out; -+} ++config GRKERNSEC_AUDIT_GROUP ++ bool "Single group for auditing" ++ help ++ If you say Y here, the exec, chdir, and (un)mount logging features ++ will only operate on a group you specify. This option is recommende= d ++ if you only want to watch certain users instead of having a large ++ amount of logs from the entire system. If the sysctl option is enab= led, ++ a sysctl option with name "audit_group" is created. + -+static char * -+gen_full_path(struct dentry *dentry, struct vfsmount *vfsmnt, -+ struct dentry *root, struct vfsmount *rootmnt, char *buf,= int buflen) -+{ -+ char *retval; ++config GRKERNSEC_AUDIT_GID ++ int "GID for auditing" ++ depends on GRKERNSEC_AUDIT_GROUP ++ default 1007 + -+ retval =3D __our_d_path(dentry, vfsmnt, root, rootmnt, buf, buflen); -+ if (unlikely(IS_ERR(retval))) -+ retval =3D strcpy(buf, ""); -+ else if (unlikely(retval[1] =3D=3D '/' && retval[2] =3D=3D '\0')) -+ retval[1] =3D '\0'; ++config GRKERNSEC_EXECLOG ++ bool "Exec logging" ++ help ++ If you say Y here, all execve() calls will be logged (since the ++ other exec*() calls are frontends to execve(), all execution ++ will be logged). Useful for shell-servers that like to keep track ++ of their users. If the sysctl option is enabled, a sysctl option wi= th ++ name "exec_logging" is created. ++ WARNING: This option when enabled will produce a LOT of logs, especi= ally ++ on an active system. + -+ return retval; -+} ++config GRKERNSEC_RESLOG ++ bool "Resource logging" ++ help ++ If you say Y here, all attempts to overstep resource limits will ++ be logged with the resource name, the requested size, and the curren= t ++ limit. It is highly recommended that you say Y here. If the sysctl ++ option is enabled, a sysctl option with name "resource_logging" is ++ created. If the RBAC system is enabled, the sysctl value is ignored= . + -+static char * -+__d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmn= t, -+ char *buf, int buflen) -+{ -+ char *res; ++config GRKERNSEC_CHROOT_EXECLOG ++ bool "Log execs within chroot" ++ help ++ If you say Y here, all executions inside a chroot jail will be logge= d ++ to syslog. This can cause a large amount of logs if certain ++ applications (eg. djb's daemontools) are installed on the system, an= d ++ is therefore left as an option. If the sysctl option is enabled, a ++ sysctl option with name "chroot_execlog" is created. + -+ /* we can use real_root, real_root_mnt, because this is only called -+ by the RBAC system */ -+ res =3D gen_full_path((struct dentry *)dentry, (struct vfsmount *)vfsm= nt, real_root, real_root_mnt, buf, buflen); ++config GRKERNSEC_AUDIT_PTRACE ++ bool "Ptrace logging" ++ help ++ If you say Y here, all attempts to attach to a process via ptrace ++ will be logged. If the sysctl option is enabled, a sysctl option ++ with name "audit_ptrace" is created. + -+ return res; -+} ++config GRKERNSEC_AUDIT_CHDIR ++ bool "Chdir logging" ++ help ++ If you say Y here, all chdir() calls will be logged. If the sysctl ++ option is enabled, a sysctl option with name "audit_chdir" is creat= ed. + -+static char * -+d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmnt, -+ char *buf, int buflen) -+{ -+ char *res; -+ struct dentry *root; -+ struct vfsmount *rootmnt; -+ struct task_struct *reaper =3D &init_task; ++config GRKERNSEC_AUDIT_MOUNT ++ bool "(Un)Mount logging" ++ help ++ If you say Y here, all mounts and unmounts will be logged. If the ++ sysctl option is enabled, a sysctl option with name "audit_mount" is ++ created. + -+ /* we can't use real_root, real_root_mnt, because they belong only to = the RBAC system */ -+ read_lock(&reaper->fs->lock); -+ root =3D dget(reaper->fs->root.dentry); -+ rootmnt =3D mntget(reaper->fs->root.mnt); -+ read_unlock(&reaper->fs->lock); ++config GRKERNSEC_SIGNAL ++ bool "Signal logging" ++ help ++ If you say Y here, certain important signals will be logged, such as ++ SIGSEGV, which will as a result inform you of when a error in a prog= ram ++ occurred, which in some cases could mean a possible exploit attempt. ++ If the sysctl option is enabled, a sysctl option with name ++ "signal_logging" is created. + -+ spin_lock(&dcache_lock); -+ spin_lock(&vfsmount_lock); -+ res =3D gen_full_path((struct dentry *)dentry, (struct vfsmount *)vfsm= nt, root, rootmnt, buf, buflen); -+ spin_unlock(&vfsmount_lock); -+ spin_unlock(&dcache_lock); ++config GRKERNSEC_FORKFAIL ++ bool "Fork failure logging" ++ help ++ If you say Y here, all failed fork() attempts will be logged. ++ This could suggest a fork bomb, or someone attempting to overstep ++ their process limit. If the sysctl option is enabled, a sysctl opti= on ++ with name "forkfail_logging" is created. + -+ dput(root); -+ mntput(rootmnt); -+ return res; -+} ++config GRKERNSEC_TIME ++ bool "Time change logging" ++ help ++ If you say Y here, any changes of the system clock will be logged. ++ If the sysctl option is enabled, a sysctl option with name ++ "timechange_logging" is created. + -+static char * -+gr_to_filename_rbac(const struct dentry *dentry, const struct vfsmount = *mnt) -+{ -+ char *ret; -+ spin_lock(&dcache_lock); -+ spin_lock(&vfsmount_lock); -+ ret =3D __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_p= rocessor_id()), -+ PAGE_SIZE); -+ spin_unlock(&vfsmount_lock); -+ spin_unlock(&dcache_lock); -+ return ret; -+} ++config GRKERNSEC_PROC_IPADDR ++ bool "/proc//ipaddr support" ++ help ++ If you say Y here, a new entry will be added to each /proc/ ++ directory that contains the IP address of the person using the task. ++ The IP is carried across local TCP and AF_UNIX stream sockets. ++ This information can be useful for IDS/IPSes to perform remote respo= nse ++ to a local attack. The entry is readable by only the owner of the ++ process (and root if he has CAP_DAC_OVERRIDE, which can be removed v= ia ++ the RBAC system), and thus does not create privacy concerns. + -+static char * -+gr_to_proc_filename_rbac(const struct dentry *dentry, const struct vfsm= ount *mnt) -+{ -+ char *ret; -+ char *buf; -+ int buflen; ++config GRKERNSEC_RWXMAP_LOG ++ bool 'Denied RWX mmap/mprotect logging' ++ depends on PAX_MPROTECT && !PAX_EMUPLT && !PAX_EMUSIGRT ++ help ++ If you say Y here, calls to mmap() and mprotect() with explicit ++ usage of PROT_WRITE and PROT_EXEC together will be logged when ++ denied by the PAX_MPROTECT feature. If the sysctl option is ++ enabled, a sysctl option with name "rwxmap_logging" is created. + -+ spin_lock(&dcache_lock); -+ spin_lock(&vfsmount_lock); -+ buf =3D per_cpu_ptr(gr_shared_page[0], smp_processor_id()); -+ ret =3D __d_real_path(dentry, mnt, buf, PAGE_SIZE - 6); -+ buflen =3D (int)(ret - buf); -+ if (buflen >=3D 5) -+ prepend(&ret, &buflen, "/proc", 5); -+ else -+ ret =3D strcpy(buf, ""); -+ spin_unlock(&vfsmount_lock); -+ spin_unlock(&dcache_lock); -+ return ret; -+} ++config GRKERNSEC_AUDIT_TEXTREL ++ bool 'ELF text relocations logging (READ HELP)' ++ depends on PAX_MPROTECT ++ help ++ If you say Y here, text relocations will be logged with the filename ++ of the offending library or binary. The purpose of the feature is ++ to help Linux distribution developers get rid of libraries and ++ binaries that need text relocations which hinder the future progress ++ of PaX. Only Linux distribution developers should say Y here, and ++ never on a production machine, as this option creates an information ++ leak that could aid an attacker in defeating the randomization of ++ a single memory region. If the sysctl option is enabled, a sysctl ++ option with name "audit_textrel" is created. + -+char * -+gr_to_filename_nolock(const struct dentry *dentry, const struct vfsmoun= t *mnt) -+{ -+ return __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_pr= ocessor_id()), -+ PAGE_SIZE); -+} ++endmenu + -+char * -+gr_to_filename(const struct dentry *dentry, const struct vfsmount *mnt) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++menu "Executable Protections" ++depends on GRKERNSEC + -+char * -+gr_to_filename1(const struct dentry *dentry, const struct vfsmount *mnt= ) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[1], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++config GRKERNSEC_DMESG ++ bool "Dmesg(8) restriction" ++ help ++ If you say Y here, non-root users will not be able to use dmesg(8) ++ to view up to the last 4kb of messages in the kernel's log buffer. ++ The kernel's log buffer often contains kernel addresses and other ++ identifying information useful to an attacker in fingerprinting a ++ system for a targeted exploit. ++ If the sysctl option is enabled, a sysctl option with name "dmesg" i= s ++ created. + -+char * -+gr_to_filename2(const struct dentry *dentry, const struct vfsmount *mnt= ) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[2], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++config GRKERNSEC_HARDEN_PTRACE ++ bool "Deter ptrace-based process snooping" ++ help ++ If you say Y here, TTY sniffers and other malicious monitoring ++ programs implemented through ptrace will be defeated. If you ++ have been using the RBAC system, this option has already been ++ enabled for several years for all users, with the ability to make ++ fine-grained exceptions. + -+char * -+gr_to_filename3(const struct dentry *dentry, const struct vfsmount *mnt= ) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[3], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++ This option only affects the ability of non-root users to ptrace ++ processes that are not a descendent of the ptracing process. ++ This means that strace ./binary and gdb ./binary will still work, ++ but attaching to arbitrary processes will not. If the sysctl ++ option is enabled, a sysctl option with name "harden_ptrace" is ++ created. + -+__inline__ __u32 -+to_gr_audit(const __u32 reqmode) -+{ -+ /* masks off auditable permission flags, then shifts them to create -+ auditing flags, and adds the special case of append auditing if -+ we're requesting write */ -+ return (((reqmode & ~GR_AUDITS) << 10) | ((reqmode & GR_WRITE) ? GR_AU= DIT_APPEND : 0)); -+} ++config GRKERNSEC_TPE ++ bool "Trusted Path Execution (TPE)" ++ help ++ If you say Y here, you will be able to choose a gid to add to the ++ supplementary groups of users you want to mark as "untrusted." ++ These users will not be able to execute any files that are not in ++ root-owned directories writable only by root. If the sysctl option ++ is enabled, a sysctl option with name "tpe" is created. + -+struct acl_subject_label * -+lookup_subject_map(const struct acl_subject_label *userp) -+{ -+ unsigned int index =3D shash(userp, subj_map_set.s_size); -+ struct subject_map *match; ++config GRKERNSEC_TPE_ALL ++ bool "Partially restrict all non-root users" ++ depends on GRKERNSEC_TPE ++ help ++ If you say Y here, all non-root users will be covered under ++ a weaker TPE restriction. This is separate from, and in addition to= , ++ the main TPE options that you have selected elsewhere. Thus, if a ++ "trusted" GID is chosen, this restriction applies to even that GID. ++ Under this restriction, all non-root users will only be allowed to ++ execute files in directories they own that are not group or ++ world-writable, or in directories owned by root and writable only by ++ root. If the sysctl option is enabled, a sysctl option with name ++ "tpe_restrict_all" is created. + -+ match =3D subj_map_set.s_hash[index]; ++config GRKERNSEC_TPE_INVERT ++ bool "Invert GID option" ++ depends on GRKERNSEC_TPE ++ help ++ If you say Y here, the group you specify in the TPE configuration wi= ll ++ decide what group TPE restrictions will be *disabled* for. This ++ option is useful if you want TPE restrictions to be applied to most ++ users on the system. If the sysctl option is enabled, a sysctl opti= on ++ with name "tpe_invert" is created. Unlike other sysctl options, thi= s ++ entry will default to on for backward-compatibility. + -+ while (match && match->user !=3D userp) -+ match =3D match->next; ++config GRKERNSEC_TPE_GID ++ int "GID for untrusted users" ++ depends on GRKERNSEC_TPE && !GRKERNSEC_TPE_INVERT ++ default 1005 ++ help ++ Setting this GID determines what group TPE restrictions will be ++ *enabled* for. If the sysctl option is enabled, a sysctl option ++ with name "tpe_gid" is created. + -+ if (match !=3D NULL) -+ return match->kernel; -+ else -+ return NULL; -+} ++config GRKERNSEC_TPE_GID ++ int "GID for trusted users" ++ depends on GRKERNSEC_TPE && GRKERNSEC_TPE_INVERT ++ default 1005 ++ help ++ Setting this GID determines what group TPE restrictions will be ++ *disabled* for. If the sysctl option is enabled, a sysctl option ++ with name "tpe_gid" is created. + -+static void -+insert_subj_map_entry(struct subject_map *subjmap) -+{ -+ unsigned int index =3D shash(subjmap->user, subj_map_set.s_size); -+ struct subject_map **curr; ++endmenu ++menu "Network Protections" ++depends on GRKERNSEC + -+ subjmap->prev =3D NULL; ++config GRKERNSEC_RANDNET ++ bool "Larger entropy pools" ++ help ++ If you say Y here, the entropy pools used for many features of Linux ++ and grsecurity will be doubled in size. Since several grsecurity ++ features use additional randomness, it is recommended that you say Y ++ here. Saying Y here has a similar effect as modifying ++ /proc/sys/kernel/random/poolsize. + -+ curr =3D &subj_map_set.s_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D subjmap; ++config GRKERNSEC_BLACKHOLE ++ bool "TCP/UDP blackhole and LAST_ACK DoS prevention" ++ depends on NET ++ help ++ If you say Y here, neither TCP resets nor ICMP ++ destination-unreachable packets will be sent in response to packets ++ sent to ports for which no associated listening process exists. ++ This feature supports both IPV4 and IPV6 and exempts the=20 ++ loopback interface from blackholing. Enabling this feature=20 ++ makes a host more resilient to DoS attacks and reduces network ++ visibility against scanners. + -+ subjmap->next =3D *curr; -+ *curr =3D subjmap; ++ The blackhole feature as-implemented is equivalent to the FreeBSD ++ blackhole feature, as it prevents RST responses to all packets, not ++ just SYNs. Under most application behavior this causes no ++ problems, but applications (like haproxy) may not close certain ++ connections in a way that cleanly terminates them on the remote ++ end, leaving the remote host in LAST_ACK state. Because of this ++ side-effect and to prevent intentional LAST_ACK DoSes, this ++ feature also adds automatic mitigation against such attacks. ++ The mitigation drastically reduces the amount of time a socket ++ can spend in LAST_ACK state. If you're using haproxy and not ++ all servers it connects to have this option enabled, consider ++ disabling this feature on the haproxy host. + -+ return; -+} ++ If the sysctl option is enabled, two sysctl options with names ++ "ip_blackhole" and "lastack_retries" will be created. ++ While "ip_blackhole" takes the standard zero/non-zero on/off ++ toggle, "lastack_retries" uses the same kinds of values as ++ "tcp_retries1" and "tcp_retries2". The default value of 4 ++ prevents a socket from lasting more than 45 seconds in LAST_ACK ++ state. + -+static struct acl_role_label * -+lookup_acl_role_label(const struct task_struct *task, const uid_t uid, -+ const gid_t gid) -+{ -+ unsigned int index =3D rhash(uid, GR_ROLE_USER, acl_role_set.r_size); -+ struct acl_role_label *match; -+ struct role_allowed_ip *ipp; -+ unsigned int x; -+ u32 curr_ip =3D task->signal->curr_ip; ++config GRKERNSEC_SOCKET ++ bool "Socket restrictions" ++ depends on NET ++ help ++ If you say Y here, you will be able to choose from several options. ++ If you assign a GID on your system and add it to the supplementary ++ groups of users you want to restrict socket access to, this patch ++ will perform up to three things, based on the option(s) you choose. + -+ task->signal->saved_ip =3D curr_ip; ++config GRKERNSEC_SOCKET_ALL ++ bool "Deny any sockets to group" ++ depends on GRKERNSEC_SOCKET ++ help ++ If you say Y here, you will be able to choose a GID of whose users w= ill ++ be unable to connect to other hosts from your machine or run server ++ applications from your machine. If the sysctl option is enabled, a ++ sysctl option with name "socket_all" is created. + -+ match =3D acl_role_set.r_hash[index]; ++config GRKERNSEC_SOCKET_ALL_GID ++ int "GID to deny all sockets for" ++ depends on GRKERNSEC_SOCKET_ALL ++ default 1004 ++ help ++ Here you can choose the GID to disable socket access for. Remember t= o ++ add the users you want socket access disabled for to the GID ++ specified here. If the sysctl option is enabled, a sysctl option ++ with name "socket_all_gid" is created. + -+ while (match) { -+ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_USER)) =3D=3D (GR_RO= LE_DOMAIN | GR_ROLE_USER)) { -+ for (x =3D 0; x < match->domain_child_num; x++) { -+ if (match->domain_children[x] =3D=3D uid) -+ goto found; -+ } -+ } else if (match->uidgid =3D=3D uid && match->roletype & GR_ROLE_USER= ) -+ break; -+ match =3D match->next; -+ } -+found: -+ if (match =3D=3D NULL) { -+ try_group: -+ index =3D rhash(gid, GR_ROLE_GROUP, acl_role_set.r_size); -+ match =3D acl_role_set.r_hash[index]; ++config GRKERNSEC_SOCKET_CLIENT ++ bool "Deny client sockets to group" ++ depends on GRKERNSEC_SOCKET ++ help ++ If you say Y here, you will be able to choose a GID of whose users w= ill ++ be unable to connect to other hosts from your machine, but will be ++ able to run servers. If this option is enabled, all users in the gr= oup ++ you specify will have to use passive mode when initiating ftp transf= ers ++ from the shell on your machine. If the sysctl option is enabled, a ++ sysctl option with name "socket_client" is created. + -+ while (match) { -+ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_GROUP)) =3D=3D (GR_= ROLE_DOMAIN | GR_ROLE_GROUP)) { -+ for (x =3D 0; x < match->domain_child_num; x++) { -+ if (match->domain_children[x] =3D=3D gid) -+ goto found2; -+ } -+ } else if (match->uidgid =3D=3D gid && match->roletype & GR_ROLE_GRO= UP) -+ break; -+ match =3D match->next; -+ } -+found2: -+ if (match =3D=3D NULL) -+ match =3D default_role; -+ if (match->allowed_ips =3D=3D NULL) -+ return match; -+ else { -+ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { -+ if (likely -+ ((ntohl(curr_ip) & ipp->netmask) =3D=3D -+ (ntohl(ipp->addr) & ipp->netmask))) -+ return match; -+ } -+ match =3D default_role; -+ } -+ } else if (match->allowed_ips =3D=3D NULL) { -+ return match; -+ } else { -+ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { -+ if (likely -+ ((ntohl(curr_ip) & ipp->netmask) =3D=3D -+ (ntohl(ipp->addr) & ipp->netmask))) -+ return match; -+ } -+ goto try_group; -+ } ++config GRKERNSEC_SOCKET_CLIENT_GID ++ int "GID to deny client sockets for" ++ depends on GRKERNSEC_SOCKET_CLIENT ++ default 1003 ++ help ++ Here you can choose the GID to disable client socket access for. ++ Remember to add the users you want client socket access disabled for= to ++ the GID specified here. If the sysctl option is enabled, a sysctl ++ option with name "socket_client_gid" is created. + -+ return match; -+} ++config GRKERNSEC_SOCKET_SERVER ++ bool "Deny server sockets to group" ++ depends on GRKERNSEC_SOCKET ++ help ++ If you say Y here, you will be able to choose a GID of whose users w= ill ++ be unable to run server applications from your machine. If the sysc= tl ++ option is enabled, a sysctl option with name "socket_server" is crea= ted. + -+struct acl_subject_label * -+lookup_acl_subj_label(const ino_t ino, const dev_t dev, -+ const struct acl_role_label *role) -+{ -+ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); -+ struct acl_subject_label *match; -+ -+ match =3D role->subj_hash[index]; -+ -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ (match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++config GRKERNSEC_SOCKET_SERVER_GID ++ int "GID to deny server sockets for" ++ depends on GRKERNSEC_SOCKET_SERVER ++ default 1002 ++ help ++ Here you can choose the GID to disable server socket access for. ++ Remember to add the users you want server socket access disabled for= to ++ the GID specified here. If the sysctl option is enabled, a sysctl ++ option with name "socket_server_gid" is created. + -+ if (match && !(match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++endmenu ++menu "Sysctl support" ++depends on GRKERNSEC && SYSCTL + -+struct acl_subject_label * -+lookup_acl_subj_label_deleted(const ino_t ino, const dev_t dev, -+ const struct acl_role_label *role) -+{ -+ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); -+ struct acl_subject_label *match; ++config GRKERNSEC_SYSCTL ++ bool "Sysctl support" ++ help ++ If you say Y here, you will be able to change the options that ++ grsecurity runs with at bootup, without having to recompile your ++ kernel. You can echo values to files in /proc/sys/kernel/grsecurity ++ to enable (1) or disable (0) various features. All the sysctl entri= es ++ are mutable until the "grsec_lock" entry is set to a non-zero value. ++ All features enabled in the kernel configuration are disabled at boo= t ++ if you do not say Y to the "Turn on features by default" option. ++ All options should be set at startup, and the grsec_lock entry shoul= d ++ be set to a non-zero value after all the options are set. ++ *THIS IS EXTREMELY IMPORTANT* + -+ match =3D role->subj_hash[index]; ++config GRKERNSEC_SYSCTL_DISTRO ++ bool "Extra sysctl support for distro makers (READ HELP)" ++ depends on GRKERNSEC_SYSCTL && GRKERNSEC_IO ++ help ++ If you say Y here, additional sysctl options will be created ++ for features that affect processes running as root. Therefore, ++ it is critical when using this option that the grsec_lock entry be ++ enabled after boot. Only distros with prebuilt kernel packages ++ with this option enabled that can ensure grsec_lock is enabled ++ after boot should use this option. ++ *Failure to set grsec_lock after boot makes all grsec features ++ this option covers useless* + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ !(match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++ Currently this option creates the following sysctl entries: ++ "Disable Privileged I/O": "disable_priv_io"=09 + -+ if (match && (match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++config GRKERNSEC_SYSCTL_ON ++ bool "Turn on features by default" ++ depends on GRKERNSEC_SYSCTL ++ help ++ If you say Y here, instead of having all features enabled in the ++ kernel configuration disabled at boot time, the features will be ++ enabled at boot time. It is recommended you say Y here unless ++ there is some reason you would want all sysctl-tunable features to ++ be disabled by default. As mentioned elsewhere, it is important ++ to enable the grsec_lock entry once you have finished modifying ++ the sysctl entries. + -+static struct acl_object_label * -+lookup_acl_obj_label(const ino_t ino, const dev_t dev, -+ const struct acl_subject_label *subj) -+{ -+ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); -+ struct acl_object_label *match; ++endmenu ++menu "Logging Options" ++depends on GRKERNSEC + -+ match =3D subj->obj_hash[index]; ++config GRKERNSEC_FLOODTIME ++ int "Seconds in between log messages (minimum)" ++ default 10 ++ help ++ This option allows you to enforce the number of seconds between ++ grsecurity log messages. The default should be suitable for most ++ people, however, if you choose to change it, choose a value small en= ough ++ to allow informative logs to be produced, but large enough to ++ prevent flooding. + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ (match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++config GRKERNSEC_FLOODBURST ++ int "Number of messages in a burst (maximum)" ++ default 6 ++ help ++ This option allows you to choose the maximum number of messages allo= wed ++ within the flood time interval you chose in a separate option. The ++ default should be suitable for most people, however if you find that ++ many of your logs are being interpreted as flooding, you may want to ++ raise this value. + -+ if (match && !(match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++endmenu + -+static struct acl_object_label * -+lookup_acl_obj_label_create(const ino_t ino, const dev_t dev, -+ const struct acl_subject_label *subj) -+{ -+ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); -+ struct acl_object_label *match; ++endmenu +diff --git a/grsecurity/Makefile b/grsecurity/Makefile +new file mode 100644 +index 0000000..be9ae3a +--- /dev/null ++++ b/grsecurity/Makefile +@@ -0,0 +1,36 @@ ++# grsecurity's ACL system was originally written in 2001 by Michael Dal= ton ++# during 2001-2009 it has been completely redesigned by Brad Spengler ++# into an RBAC system ++# ++# All code in this directory and various hooks inserted throughout the = kernel ++# are copyright Brad Spengler - Open Source Security, Inc., and release= d=20 ++# under the GPL v2 or higher + -+ match =3D subj->obj_hash[index]; ++obj-y =3D grsec_chdir.o grsec_chroot.o grsec_exec.o grsec_fifo.o grsec_= fork.o \ ++ grsec_mount.o grsec_sig.o grsec_sysctl.o \ ++ grsec_time.o grsec_tpe.o grsec_link.o grsec_pax.o grsec_ptrace.o + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ !(match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++obj-$(CONFIG_GRKERNSEC) +=3D grsec_init.o grsum.o gracl.o gracl_segv.o = \ ++ gracl_cap.o gracl_alloc.o gracl_shm.o grsec_mem.o gracl_fs.o \ ++ gracl_learn.o grsec_log.o ++obj-$(CONFIG_GRKERNSEC_RESLOG) +=3D gracl_res.o + -+ if (match && (match->mode & GR_DELETED)) -+ return match; ++ifdef CONFIG_NET ++obj-y +=3D grsec_sock.o ++obj-$(CONFIG_GRKERNSEC) +=3D gracl_ip.o ++endif + -+ match =3D subj->obj_hash[index]; ++ifndef CONFIG_GRKERNSEC ++obj-y +=3D grsec_disabled.o ++endif + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ (match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++ifdef CONFIG_GRKERNSEC_HIDESYM ++extra-y :=3D grsec_hidesym.o ++$(obj)/grsec_hidesym.o: ++ @-chmod -f 500 /boot ++ @-chmod -f 500 /lib/modules ++ @-chmod -f 500 /lib64/modules ++ @-chmod -f 500 /lib32/modules ++ @-chmod -f 700 . ++ @echo ' grsec: protected kernel image paths' ++endif +diff --git a/grsecurity/gracl.c b/grsecurity/gracl.c +new file mode 100644 +index 0000000..6bd68d6 +--- /dev/null ++++ b/grsecurity/gracl.c +@@ -0,0 +1,4141 @@ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include + -+ if (match && !(match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++#include ++#include ++#include + -+static struct name_entry * -+lookup_name_entry(const char *name) -+{ -+ unsigned int len =3D strlen(name); -+ unsigned int key =3D full_name_hash(name, len); -+ unsigned int index =3D key % name_set.n_size; -+ struct name_entry *match; ++static struct acl_role_db acl_role_set; ++static struct name_db name_set; ++static struct inodev_db inodev_set; + -+ match =3D name_set.n_hash[index]; ++/* for keeping track of userspace pointers used for subjects, so we ++ can share references in the kernel as well ++*/ + -+ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len))) -+ match =3D match->next; ++static struct dentry *real_root; ++static struct vfsmount *real_root_mnt; + -+ return match; -+} ++static struct acl_subj_map_db subj_map_set; + -+static struct name_entry * -+lookup_name_entry_create(const char *name) -+{ -+ unsigned int len =3D strlen(name); -+ unsigned int key =3D full_name_hash(name, len); -+ unsigned int index =3D key % name_set.n_size; -+ struct name_entry *match; ++static struct acl_role_label *default_role; + -+ match =3D name_set.n_hash[index]; ++static struct acl_role_label *role_list; + -+ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || -+ !match->deleted)) -+ match =3D match->next; ++static u16 acl_sp_role_value; + -+ if (match && match->deleted) -+ return match; ++extern char *gr_shared_page[4]; ++static DEFINE_MUTEX(gr_dev_mutex); ++DEFINE_RWLOCK(gr_inode_lock); + -+ match =3D name_set.n_hash[index]; ++struct gr_arg *gr_usermode; + -+ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || -+ match->deleted)) -+ match =3D match->next; ++static unsigned int gr_status __read_only =3D GR_STATUS_INIT; + -+ if (match && !match->deleted) -+ return match; -+ else -+ return NULL; -+} ++extern int chkpw(struct gr_arg *entry, unsigned char *salt, unsigned ch= ar *sum); ++extern void gr_clear_learn_entries(void); + -+static struct inodev_entry * -+lookup_inodev_entry(const ino_t ino, const dev_t dev) -+{ -+ unsigned int index =3D fhash(ino, dev, inodev_set.i_size); -+ struct inodev_entry *match; ++#ifdef CONFIG_GRKERNSEC_RESLOG ++extern void gr_log_resource(const struct task_struct *task, ++ const int res, const unsigned long wanted, const int gt); ++#endif + -+ match =3D inodev_set.i_hash[index]; ++unsigned char *gr_system_salt; ++unsigned char *gr_system_sum; + -+ while (match && (match->nentry->inode !=3D ino || match->nentry->devic= e !=3D dev)) -+ match =3D match->next; ++static struct sprole_pw **acl_special_roles =3D NULL; ++static __u16 num_sprole_pws =3D 0; + -+ return match; -+} ++static struct acl_role_label *kernel_role =3D NULL; + -+static void -+insert_inodev_entry(struct inodev_entry *entry) -+{ -+ unsigned int index =3D fhash(entry->nentry->inode, entry->nentry->devi= ce, -+ inodev_set.i_size); -+ struct inodev_entry **curr; ++static unsigned int gr_auth_attempts =3D 0; ++static unsigned long gr_auth_expires =3D 0UL; + -+ entry->prev =3D NULL; ++#ifdef CONFIG_NET ++extern struct vfsmount *sock_mnt; ++#endif ++extern struct vfsmount *pipe_mnt; ++extern struct vfsmount *shm_mnt; ++#ifdef CONFIG_HUGETLBFS ++extern struct vfsmount *hugetlbfs_vfsmount; ++#endif + -+ curr =3D &inodev_set.i_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D entry; -+=09 -+ entry->next =3D *curr; -+ *curr =3D entry; ++static struct acl_object_label *fakefs_obj_rw; ++static struct acl_object_label *fakefs_obj_rwx; + -+ return; -+} ++extern int gr_init_uidset(void); ++extern void gr_free_uidset(void); ++extern void gr_remove_uid(uid_t uid); ++extern int gr_find_uid(uid_t uid); + -+static void -+__insert_acl_role_label(struct acl_role_label *role, uid_t uidgid) ++__inline__ int ++gr_acl_is_enabled(void) +{ -+ unsigned int index =3D -+ rhash(uidgid, role->roletype & (GR_ROLE_USER | GR_ROLE_GROUP), acl= _role_set.r_size); -+ struct acl_role_label **curr; -+ struct acl_role_label *tmp; -+ -+ curr =3D &acl_role_set.r_hash[index]; ++ return (gr_status & GR_READY); ++} + -+ /* if role was already inserted due to domains and already has -+ a role in the same bucket as it attached, then we need to -+ combine these two buckets -+ */ -+ if (role->next) { -+ tmp =3D role->next; -+ while (tmp->next) -+ tmp =3D tmp->next; -+ tmp->next =3D *curr; -+ } else -+ role->next =3D *curr; -+ *curr =3D role; ++#ifdef CONFIG_BTRFS_FS ++extern dev_t get_btrfs_dev_from_inode(struct inode *inode); ++extern int btrfs_getattr(struct vfsmount *mnt, struct dentry *dentry, s= truct kstat *stat); ++#endif + -+ return; ++static inline dev_t __get_dev(const struct dentry *dentry) ++{ ++#ifdef CONFIG_BTRFS_FS ++ if (dentry->d_inode->i_op && dentry->d_inode->i_op->getattr =3D=3D &bt= rfs_getattr) ++ return get_btrfs_dev_from_inode(dentry->d_inode); ++ else ++#endif ++ return dentry->d_inode->i_sb->s_dev; +} + -+static void -+insert_acl_role_label(struct acl_role_label *role) ++dev_t gr_get_dev_from_dentry(struct dentry *dentry) +{ -+ int i; ++ return __get_dev(dentry); ++} + -+ if (role_list =3D=3D NULL) { -+ role_list =3D role; -+ role->prev =3D NULL; -+ } else { -+ role->prev =3D role_list; -+ role_list =3D role; ++static char gr_task_roletype_to_char(struct task_struct *task) ++{ ++ switch (task->role->roletype & ++ (GR_ROLE_DEFAULT | GR_ROLE_USER | GR_ROLE_GROUP | ++ GR_ROLE_SPECIAL)) { ++ case GR_ROLE_DEFAULT: ++ return 'D'; ++ case GR_ROLE_USER: ++ return 'U'; ++ case GR_ROLE_GROUP: ++ return 'G'; ++ case GR_ROLE_SPECIAL: ++ return 'S'; + } -+=09 -+ /* used for hash chains */ -+ role->next =3D NULL; + -+ if (role->roletype & GR_ROLE_DOMAIN) { -+ for (i =3D 0; i < role->domain_child_num; i++) -+ __insert_acl_role_label(role, role->domain_children[i]); -+ } else -+ __insert_acl_role_label(role, role->uidgid); ++ return 'X'; +} -+ =09 -+static int -+insert_name_entry(char *name, const ino_t inode, const dev_t device, __= u8 deleted) -+{ -+ struct name_entry **curr, *nentry; -+ struct inodev_entry *ientry; -+ unsigned int len =3D strlen(name); -+ unsigned int key =3D full_name_hash(name, len); -+ unsigned int index =3D key % name_set.n_size; -+ -+ curr =3D &name_set.n_hash[index]; + -+ while (*curr && ((*curr)->key !=3D key || !gr_streq((*curr)->name, nam= e, (*curr)->len, len))) -+ curr =3D &((*curr)->next); -+ -+ if (*curr !=3D NULL) -+ return 1; ++char gr_roletype_to_char(void) ++{ ++ return gr_task_roletype_to_char(current); ++} + -+ nentry =3D acl_alloc(sizeof (struct name_entry)); -+ if (nentry =3D=3D NULL) ++__inline__ int ++gr_acl_tpe_check(void) ++{ ++ if (unlikely(!(gr_status & GR_READY))) + return 0; -+ ientry =3D acl_alloc(sizeof (struct inodev_entry)); -+ if (ientry =3D=3D NULL) ++ if (current->role->roletype & GR_ROLE_TPE) ++ return 1; ++ else + return 0; -+ ientry->nentry =3D nentry; -+ -+ nentry->key =3D key; -+ nentry->name =3D name; -+ nentry->inode =3D inode; -+ nentry->device =3D device; -+ nentry->len =3D len; -+ nentry->deleted =3D deleted; -+ -+ nentry->prev =3D NULL; -+ curr =3D &name_set.n_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D nentry; -+ nentry->next =3D *curr; -+ *curr =3D nentry; -+ -+ /* insert us into the table searchable by inode/dev */ -+ insert_inodev_entry(ientry); -+ -+ return 1; +} + -+static void -+insert_acl_obj_label(struct acl_object_label *obj, -+ struct acl_subject_label *subj) ++int ++gr_handle_rawio(const struct inode *inode) +{ -+ unsigned int index =3D -+ fhash(obj->inode, obj->device, subj->obj_hash_size); -+ struct acl_object_label **curr; -+ -+=09 -+ obj->prev =3D NULL; -+ -+ curr =3D &subj->obj_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D obj; -+ -+ obj->next =3D *curr; -+ *curr =3D obj; -+ -+ return; ++#ifdef CONFIG_GRKERNSEC_CHROOT_CAPS ++ if (inode && S_ISBLK(inode->i_mode) && ++ grsec_enable_chroot_caps && proc_is_chrooted(current) && ++ !capable(CAP_SYS_RAWIO)) ++ return 1; ++#endif ++ return 0; +} + -+static void -+insert_acl_subj_label(struct acl_subject_label *obj, -+ struct acl_role_label *role) ++static int ++gr_streq(const char *a, const char *b, const unsigned int lena, const u= nsigned int lenb) +{ -+ unsigned int index =3D fhash(obj->inode, obj->device, role->subj_hash_= size); -+ struct acl_subject_label **curr; -+ -+ obj->prev =3D NULL; -+ -+ curr =3D &role->subj_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D obj; ++ if (likely(lena !=3D lenb)) ++ return 0; + -+ obj->next =3D *curr; -+ *curr =3D obj; ++ return !memcmp(a, b, lena); ++} + -+ return; ++static int prepend(char **buffer, int *buflen, const char *str, int nam= elen) ++{ ++ *buflen -=3D namelen; ++ if (*buflen < 0) ++ return -ENAMETOOLONG; ++ *buffer -=3D namelen; ++ memcpy(*buffer, str, namelen); ++ return 0; +} + -+/* allocating chained hash tables, so optimal size is where lambda ~ 1 = */ ++/* this must be called with vfsmount_lock and dcache_lock held */ + -+static void * -+create_table(__u32 * len, int elementsize) ++static char * __our_d_path(struct dentry *dentry, struct vfsmount *vfsm= nt, ++ struct dentry *root, struct vfsmount *rootmnt, ++ char *buffer, int buflen) +{ -+ unsigned int table_sizes[] =3D { -+ 7, 13, 31, 61, 127, 251, 509, 1021, 2039, 4093, 8191, 16381, -+ 32749, 65521, 131071, 262139, 524287, 1048573, 2097143, -+ 4194301, 8388593, 16777213, 33554393, 67108859 -+ }; -+ void *newtable =3D NULL; -+ unsigned int pwr =3D 0; ++ char * end =3D buffer+buflen; ++ char * retval; ++ int namelen; + -+ while ((pwr < ((sizeof (table_sizes) / sizeof (table_sizes[0])) - 1)) = && -+ table_sizes[pwr] <=3D *len) -+ pwr++; ++ *--end =3D '\0'; ++ buflen--; + -+ if (table_sizes[pwr] <=3D *len || (table_sizes[pwr] > ULONG_MAX / elem= entsize)) -+ return newtable; ++ if (buflen < 1) ++ goto Elong; ++ /* Get '/' right */ ++ retval =3D end-1; ++ *retval =3D '/'; + -+ if ((table_sizes[pwr] * elementsize) <=3D PAGE_SIZE) -+ newtable =3D -+ kmalloc(table_sizes[pwr] * elementsize, GFP_KERNEL); -+ else -+ newtable =3D vmalloc(table_sizes[pwr] * elementsize); ++ for (;;) { ++ struct dentry * parent; + -+ *len =3D table_sizes[pwr]; ++ if (dentry =3D=3D root && vfsmnt =3D=3D rootmnt) ++ break; ++ if (dentry =3D=3D vfsmnt->mnt_root || IS_ROOT(dentry)) { ++ /* Global root? */ ++ if (vfsmnt->mnt_parent =3D=3D vfsmnt) ++ goto global_root; ++ dentry =3D vfsmnt->mnt_mountpoint; ++ vfsmnt =3D vfsmnt->mnt_parent; ++ continue; ++ } ++ parent =3D dentry->d_parent; ++ prefetch(parent); ++ namelen =3D dentry->d_name.len; ++ buflen -=3D namelen + 1; ++ if (buflen < 0) ++ goto Elong; ++ end -=3D namelen; ++ memcpy(end, dentry->d_name.name, namelen); ++ *--end =3D '/'; ++ retval =3D end; ++ dentry =3D parent; ++ } + -+ return newtable; ++out: ++ return retval; ++ ++global_root: ++ namelen =3D dentry->d_name.len; ++ buflen -=3D namelen; ++ if (buflen < 0) ++ goto Elong; ++ retval -=3D namelen-1; /* hit the slash */ ++ memcpy(retval, dentry->d_name.name, namelen); ++ goto out; ++Elong: ++ retval =3D ERR_PTR(-ENAMETOOLONG); ++ goto out; +} + -+static int -+init_variables(const struct gr_arg *arg) ++static char * ++gen_full_path(struct dentry *dentry, struct vfsmount *vfsmnt, ++ struct dentry *root, struct vfsmount *rootmnt, char *buf,= int buflen) +{ -+ struct task_struct *reaper =3D &init_task; -+ unsigned int stacksize; ++ char *retval; + -+ subj_map_set.s_size =3D arg->role_db.num_subjects; -+ acl_role_set.r_size =3D arg->role_db.num_roles + arg->role_db.num_doma= in_children; -+ name_set.n_size =3D arg->role_db.num_objects; -+ inodev_set.i_size =3D arg->role_db.num_objects; ++ retval =3D __our_d_path(dentry, vfsmnt, root, rootmnt, buf, buflen); ++ if (unlikely(IS_ERR(retval))) ++ retval =3D strcpy(buf, ""); ++ else if (unlikely(retval[1] =3D=3D '/' && retval[2] =3D=3D '\0')) ++ retval[1] =3D '\0'; + -+ if (!subj_map_set.s_size || !acl_role_set.r_size || -+ !name_set.n_size || !inodev_set.i_size) -+ return 1; ++ return retval; ++} + -+ if (!gr_init_uidset()) -+ return 1; ++static char * ++__d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmn= t, ++ char *buf, int buflen) ++{ ++ char *res; + -+ /* set up the stack that holds allocation info */ ++ /* we can use real_root, real_root_mnt, because this is only called ++ by the RBAC system */ ++ res =3D gen_full_path((struct dentry *)dentry, (struct vfsmount *)vfsm= nt, real_root, real_root_mnt, buf, buflen); + -+ stacksize =3D arg->role_db.num_pointers + 5; ++ return res; ++} + -+ if (!acl_alloc_stack_init(stacksize)) -+ return 1; ++static char * ++d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmnt, ++ char *buf, int buflen) ++{ ++ char *res; ++ struct dentry *root; ++ struct vfsmount *rootmnt; ++ struct task_struct *reaper =3D &init_task; + -+ /* grab reference for the real root dentry and vfsmount */ ++ /* we can't use real_root, real_root_mnt, because they belong only to = the RBAC system */ + read_lock(&reaper->fs->lock); -+ real_root =3D dget(reaper->fs->root.dentry); -+ real_root_mnt =3D mntget(reaper->fs->root.mnt); ++ root =3D dget(reaper->fs->root.dentry); ++ rootmnt =3D mntget(reaper->fs->root.mnt); + read_unlock(&reaper->fs->lock); -+=09 -+#ifdef CONFIG_GRKERNSEC_RBAC_DEBUG -+ printk(KERN_ALERT "Obtained real root device=3D%d, inode=3D%lu\n", __g= et_dev(real_root), real_root->d_inode->i_ino); -+#endif -+ -+ fakefs_obj_rw =3D acl_alloc(sizeof(struct acl_object_label)); -+ if (fakefs_obj_rw =3D=3D NULL) -+ return 1; -+ fakefs_obj_rw->mode =3D GR_FIND | GR_READ | GR_WRITE; -+ -+ fakefs_obj_rwx =3D acl_alloc(sizeof(struct acl_object_label)); -+ if (fakefs_obj_rwx =3D=3D NULL) -+ return 1; -+ fakefs_obj_rwx->mode =3D GR_FIND | GR_READ | GR_WRITE | GR_EXEC; -+ -+ subj_map_set.s_hash =3D -+ (struct subject_map **) create_table(&subj_map_set.s_size, sizeof(= void *)); -+ acl_role_set.r_hash =3D -+ (struct acl_role_label **) create_table(&acl_role_set.r_size, size= of(void *)); -+ name_set.n_hash =3D (struct name_entry **) create_table(&name_set.n_si= ze, sizeof(void *)); -+ inodev_set.i_hash =3D -+ (struct inodev_entry **) create_table(&inodev_set.i_size, sizeof(v= oid *)); -+ -+ if (!subj_map_set.s_hash || !acl_role_set.r_hash || -+ !name_set.n_hash || !inodev_set.i_hash) -+ return 1; + -+ memset(subj_map_set.s_hash, 0, -+ sizeof(struct subject_map *) * subj_map_set.s_size); -+ memset(acl_role_set.r_hash, 0, -+ sizeof (struct acl_role_label *) * acl_role_set.r_size); -+ memset(name_set.n_hash, 0, -+ sizeof (struct name_entry *) * name_set.n_size); -+ memset(inodev_set.i_hash, 0, -+ sizeof (struct inodev_entry *) * inodev_set.i_size); ++ spin_lock(&dcache_lock); ++ spin_lock(&vfsmount_lock); ++ res =3D gen_full_path((struct dentry *)dentry, (struct vfsmount *)vfsm= nt, root, rootmnt, buf, buflen); ++ spin_unlock(&vfsmount_lock); ++ spin_unlock(&dcache_lock); + -+ return 0; ++ dput(root); ++ mntput(rootmnt); ++ return res; +} + -+/* free information not needed after startup -+ currently contains user->kernel pointer mappings for subjects -+*/ ++static char * ++gr_to_filename_rbac(const struct dentry *dentry, const struct vfsmount = *mnt) ++{ ++ char *ret; ++ spin_lock(&dcache_lock); ++ spin_lock(&vfsmount_lock); ++ ret =3D __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_p= rocessor_id()), ++ PAGE_SIZE); ++ spin_unlock(&vfsmount_lock); ++ spin_unlock(&dcache_lock); ++ return ret; ++} + -+static void -+free_init_variables(void) ++static char * ++gr_to_proc_filename_rbac(const struct dentry *dentry, const struct vfsm= ount *mnt) +{ -+ __u32 i; ++ char *ret; ++ char *buf; ++ int buflen; + -+ if (subj_map_set.s_hash) { -+ for (i =3D 0; i < subj_map_set.s_size; i++) { -+ if (subj_map_set.s_hash[i]) { -+ kfree(subj_map_set.s_hash[i]); -+ subj_map_set.s_hash[i] =3D NULL; -+ } -+ } ++ spin_lock(&dcache_lock); ++ spin_lock(&vfsmount_lock); ++ buf =3D per_cpu_ptr(gr_shared_page[0], smp_processor_id()); ++ ret =3D __d_real_path(dentry, mnt, buf, PAGE_SIZE - 6); ++ buflen =3D (int)(ret - buf); ++ if (buflen >=3D 5) ++ prepend(&ret, &buflen, "/proc", 5); ++ else ++ ret =3D strcpy(buf, ""); ++ spin_unlock(&vfsmount_lock); ++ spin_unlock(&dcache_lock); ++ return ret; ++} + -+ if ((subj_map_set.s_size * sizeof (struct subject_map *)) <=3D -+ PAGE_SIZE) -+ kfree(subj_map_set.s_hash); -+ else -+ vfree(subj_map_set.s_hash); -+ } ++char * ++gr_to_filename_nolock(const struct dentry *dentry, const struct vfsmoun= t *mnt) ++{ ++ return __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_pr= ocessor_id()), ++ PAGE_SIZE); ++} + -+ return; ++char * ++gr_to_filename(const struct dentry *dentry, const struct vfsmount *mnt) ++{ ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0], smp_pro= cessor_id()), ++ PAGE_SIZE); +} + -+static void -+free_variables(void) ++char * ++gr_to_filename1(const struct dentry *dentry, const struct vfsmount *mnt= ) +{ -+ struct acl_subject_label *s; -+ struct acl_role_label *r; -+ struct task_struct *task, *task2; -+ unsigned int x; ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[1], smp_pro= cessor_id()), ++ PAGE_SIZE); ++} + -+ gr_clear_learn_entries(); ++char * ++gr_to_filename2(const struct dentry *dentry, const struct vfsmount *mnt= ) ++{ ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[2], smp_pro= cessor_id()), ++ PAGE_SIZE); ++} + -+ read_lock(&tasklist_lock); -+ do_each_thread(task2, task) { -+ task->acl_sp_role =3D 0; -+ task->acl_role_id =3D 0; -+ task->acl =3D NULL; -+ task->role =3D NULL; -+ } while_each_thread(task2, task); -+ read_unlock(&tasklist_lock); ++char * ++gr_to_filename3(const struct dentry *dentry, const struct vfsmount *mnt= ) ++{ ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[3], smp_pro= cessor_id()), ++ PAGE_SIZE); ++} + -+ /* release the reference to the real root dentry and vfsmount */ -+ if (real_root) -+ dput(real_root); -+ real_root =3D NULL; -+ if (real_root_mnt) -+ mntput(real_root_mnt); -+ real_root_mnt =3D NULL; ++__inline__ __u32 ++to_gr_audit(const __u32 reqmode) ++{ ++ /* masks off auditable permission flags, then shifts them to create ++ auditing flags, and adds the special case of append auditing if ++ we're requesting write */ ++ return (((reqmode & ~GR_AUDITS) << 10) | ((reqmode & GR_WRITE) ? GR_AU= DIT_APPEND : 0)); ++} + -+ /* free all object hash tables */ ++struct acl_subject_label * ++lookup_subject_map(const struct acl_subject_label *userp) ++{ ++ unsigned int index =3D shash(userp, subj_map_set.s_size); ++ struct subject_map *match; + -+ FOR_EACH_ROLE_START(r) -+ if (r->subj_hash =3D=3D NULL) -+ goto next_role; -+ FOR_EACH_SUBJECT_START(r, s, x) -+ if (s->obj_hash =3D=3D NULL) -+ break; -+ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) -+ kfree(s->obj_hash); -+ else -+ vfree(s->obj_hash); -+ FOR_EACH_SUBJECT_END(s, x) -+ FOR_EACH_NESTED_SUBJECT_START(r, s) -+ if (s->obj_hash =3D=3D NULL) -+ break; -+ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) -+ kfree(s->obj_hash); -+ else -+ vfree(s->obj_hash); -+ FOR_EACH_NESTED_SUBJECT_END(s) -+ if ((r->subj_hash_size * sizeof (struct acl_subject_label *)) <=3D PA= GE_SIZE) -+ kfree(r->subj_hash); -+ else -+ vfree(r->subj_hash); -+ r->subj_hash =3D NULL; -+next_role: -+ FOR_EACH_ROLE_END(r) ++ match =3D subj_map_set.s_hash[index]; + -+ acl_free_all(); ++ while (match && match->user !=3D userp) ++ match =3D match->next; + -+ if (acl_role_set.r_hash) { -+ if ((acl_role_set.r_size * sizeof (struct acl_role_label *)) <=3D -+ PAGE_SIZE) -+ kfree(acl_role_set.r_hash); -+ else -+ vfree(acl_role_set.r_hash); -+ } -+ if (name_set.n_hash) { -+ if ((name_set.n_size * sizeof (struct name_entry *)) <=3D -+ PAGE_SIZE) -+ kfree(name_set.n_hash); -+ else -+ vfree(name_set.n_hash); -+ } ++ if (match !=3D NULL) ++ return match->kernel; ++ else ++ return NULL; ++} + -+ if (inodev_set.i_hash) { -+ if ((inodev_set.i_size * sizeof (struct inodev_entry *)) <=3D -+ PAGE_SIZE) -+ kfree(inodev_set.i_hash); -+ else -+ vfree(inodev_set.i_hash); -+ } ++static void ++insert_subj_map_entry(struct subject_map *subjmap) ++{ ++ unsigned int index =3D shash(subjmap->user, subj_map_set.s_size); ++ struct subject_map **curr; + -+ gr_free_uidset(); ++ subjmap->prev =3D NULL; + -+ memset(&name_set, 0, sizeof (struct name_db)); -+ memset(&inodev_set, 0, sizeof (struct inodev_db)); -+ memset(&acl_role_set, 0, sizeof (struct acl_role_db)); -+ memset(&subj_map_set, 0, sizeof (struct acl_subj_map_db)); ++ curr =3D &subj_map_set.s_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D subjmap; + -+ default_role =3D NULL; -+ role_list =3D NULL; ++ subjmap->next =3D *curr; ++ *curr =3D subjmap; + + return; +} + -+static __u32 -+count_user_objs(struct acl_object_label *userp) ++static struct acl_role_label * ++lookup_acl_role_label(const struct task_struct *task, const uid_t uid, ++ const gid_t gid) +{ -+ struct acl_object_label o_tmp; -+ __u32 num =3D 0; ++ unsigned int index =3D rhash(uid, GR_ROLE_USER, acl_role_set.r_size); ++ struct acl_role_label *match; ++ struct role_allowed_ip *ipp; ++ unsigned int x; ++ u32 curr_ip =3D task->signal->curr_ip; + -+ while (userp) { -+ if (copy_from_user(&o_tmp, userp, -+ sizeof (struct acl_object_label))) ++ task->signal->saved_ip =3D curr_ip; ++ ++ match =3D acl_role_set.r_hash[index]; ++ ++ while (match) { ++ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_USER)) =3D=3D (GR_RO= LE_DOMAIN | GR_ROLE_USER)) { ++ for (x =3D 0; x < match->domain_child_num; x++) { ++ if (match->domain_children[x] =3D=3D uid) ++ goto found; ++ } ++ } else if (match->uidgid =3D=3D uid && match->roletype & GR_ROLE_USER= ) + break; ++ match =3D match->next; ++ } ++found: ++ if (match =3D=3D NULL) { ++ try_group: ++ index =3D rhash(gid, GR_ROLE_GROUP, acl_role_set.r_size); ++ match =3D acl_role_set.r_hash[index]; + -+ userp =3D o_tmp.prev; -+ num++; ++ while (match) { ++ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_GROUP)) =3D=3D (GR_= ROLE_DOMAIN | GR_ROLE_GROUP)) { ++ for (x =3D 0; x < match->domain_child_num; x++) { ++ if (match->domain_children[x] =3D=3D gid) ++ goto found2; ++ } ++ } else if (match->uidgid =3D=3D gid && match->roletype & GR_ROLE_GRO= UP) ++ break; ++ match =3D match->next; ++ } ++found2: ++ if (match =3D=3D NULL) ++ match =3D default_role; ++ if (match->allowed_ips =3D=3D NULL) ++ return match; ++ else { ++ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { ++ if (likely ++ ((ntohl(curr_ip) & ipp->netmask) =3D=3D ++ (ntohl(ipp->addr) & ipp->netmask))) ++ return match; ++ } ++ match =3D default_role; ++ } ++ } else if (match->allowed_ips =3D=3D NULL) { ++ return match; ++ } else { ++ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { ++ if (likely ++ ((ntohl(curr_ip) & ipp->netmask) =3D=3D ++ (ntohl(ipp->addr) & ipp->netmask))) ++ return match; ++ } ++ goto try_group; + } + -+ return num; ++ return match; +} + -+static struct acl_subject_label * -+do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role); -+ -+static int -+copy_user_glob(struct acl_object_label *obj) ++struct acl_subject_label * ++lookup_acl_subj_label(const ino_t ino, const dev_t dev, ++ const struct acl_role_label *role) +{ -+ struct acl_object_label *g_tmp, **guser; -+ unsigned int len; -+ char *tmp; ++ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); ++ struct acl_subject_label *match; + -+ if (obj->globbed =3D=3D NULL) -+ return 0; ++ match =3D role->subj_hash[index]; + -+ guser =3D &obj->globbed; -+ while (*guser) { -+ g_tmp =3D (struct acl_object_label *) -+ acl_alloc(sizeof (struct acl_object_label)); -+ if (g_tmp =3D=3D NULL) -+ return -ENOMEM; ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ (match->mode & GR_DELETED))) { ++ match =3D match->next; ++ } + -+ if (copy_from_user(g_tmp, *guser, -+ sizeof (struct acl_object_label))) -+ return -EFAULT; ++ if (match && !(match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; ++} + -+ len =3D strnlen_user(g_tmp->filename, PATH_MAX); ++struct acl_subject_label * ++lookup_acl_subj_label_deleted(const ino_t ino, const dev_t dev, ++ const struct acl_role_label *role) ++{ ++ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); ++ struct acl_subject_label *match; + -+ if (!len || len >=3D PATH_MAX) -+ return -EINVAL; ++ match =3D role->subj_hash[index]; + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return -ENOMEM; ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ !(match->mode & GR_DELETED))) { ++ match =3D match->next; ++ } + -+ if (copy_from_user(tmp, g_tmp->filename, len)) -+ return -EFAULT; -+ tmp[len-1] =3D '\0'; -+ g_tmp->filename =3D tmp; ++ if (match && (match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; ++} + -+ *guser =3D g_tmp; -+ guser =3D &(g_tmp->next); ++static struct acl_object_label * ++lookup_acl_obj_label(const ino_t ino, const dev_t dev, ++ const struct acl_subject_label *subj) ++{ ++ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); ++ struct acl_object_label *match; ++ ++ match =3D subj->obj_hash[index]; ++ ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ (match->mode & GR_DELETED))) { ++ match =3D match->next; + } + -+ return 0; ++ if (match && !(match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; +} + -+static int -+copy_user_objs(struct acl_object_label *userp, struct acl_subject_label= *subj, -+ struct acl_role_label *role) ++static struct acl_object_label * ++lookup_acl_obj_label_create(const ino_t ino, const dev_t dev, ++ const struct acl_subject_label *subj) +{ -+ struct acl_object_label *o_tmp; -+ unsigned int len; -+ int ret; -+ char *tmp; ++ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); ++ struct acl_object_label *match; + -+ while (userp) { -+ if ((o_tmp =3D (struct acl_object_label *) -+ acl_alloc(sizeof (struct acl_object_label))) =3D=3D NULL) -+ return -ENOMEM; ++ match =3D subj->obj_hash[index]; + -+ if (copy_from_user(o_tmp, userp, -+ sizeof (struct acl_object_label))) -+ return -EFAULT; ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ !(match->mode & GR_DELETED))) { ++ match =3D match->next; ++ } + -+ userp =3D o_tmp->prev; ++ if (match && (match->mode & GR_DELETED)) ++ return match; + -+ len =3D strnlen_user(o_tmp->filename, PATH_MAX); ++ match =3D subj->obj_hash[index]; + -+ if (!len || len >=3D PATH_MAX) -+ return -EINVAL; ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ (match->mode & GR_DELETED))) { ++ match =3D match->next; ++ } + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return -ENOMEM; -+ -+ if (copy_from_user(tmp, o_tmp->filename, len)) -+ return -EFAULT; -+ tmp[len-1] =3D '\0'; -+ o_tmp->filename =3D tmp; -+ -+ insert_acl_obj_label(o_tmp, subj); -+ if (!insert_name_entry(o_tmp->filename, o_tmp->inode, -+ o_tmp->device, (o_tmp->mode & GR_DELETED) ? 1 : 0)) -+ return -ENOMEM; -+ -+ ret =3D copy_user_glob(o_tmp); -+ if (ret) -+ return ret; -+ -+ if (o_tmp->nested) { -+ o_tmp->nested =3D do_copy_user_subj(o_tmp->nested, role); -+ if (IS_ERR(o_tmp->nested)) -+ return PTR_ERR(o_tmp->nested); -+ -+ /* insert into nested subject list */ -+ o_tmp->nested->next =3D role->hash->first; -+ role->hash->first =3D o_tmp->nested; -+ } -+ } -+ -+ return 0; ++ if (match && !(match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; +} + -+static __u32 -+count_user_subjs(struct acl_subject_label *userp) ++static struct name_entry * ++lookup_name_entry(const char *name) +{ -+ struct acl_subject_label s_tmp; -+ __u32 num =3D 0; ++ unsigned int len =3D strlen(name); ++ unsigned int key =3D full_name_hash(name, len); ++ unsigned int index =3D key % name_set.n_size; ++ struct name_entry *match; + -+ while (userp) { -+ if (copy_from_user(&s_tmp, userp, -+ sizeof (struct acl_subject_label))) -+ break; ++ match =3D name_set.n_hash[index]; + -+ userp =3D s_tmp.prev; -+ /* do not count nested subjects against this count, since -+ they are not included in the hash table, but are -+ attached to objects. We have already counted -+ the subjects in userspace for the allocation=20 -+ stack -+ */ -+ if (!(s_tmp.mode & GR_NESTED)) -+ num++; -+ } ++ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len))) ++ match =3D match->next; + -+ return num; ++ return match; +} + -+static int -+copy_user_allowedips(struct acl_role_label *rolep) ++static struct name_entry * ++lookup_name_entry_create(const char *name) +{ -+ struct role_allowed_ip *ruserip, *rtmp =3D NULL, *rlast; -+ -+ ruserip =3D rolep->allowed_ips; -+ -+ while (ruserip) { -+ rlast =3D rtmp; ++ unsigned int len =3D strlen(name); ++ unsigned int key =3D full_name_hash(name, len); ++ unsigned int index =3D key % name_set.n_size; ++ struct name_entry *match; + -+ if ((rtmp =3D (struct role_allowed_ip *) -+ acl_alloc(sizeof (struct role_allowed_ip))) =3D=3D NULL) -+ return -ENOMEM; ++ match =3D name_set.n_hash[index]; + -+ if (copy_from_user(rtmp, ruserip, -+ sizeof (struct role_allowed_ip))) -+ return -EFAULT; ++ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || ++ !match->deleted)) ++ match =3D match->next; + -+ ruserip =3D rtmp->prev; ++ if (match && match->deleted) ++ return match; + -+ if (!rlast) { -+ rtmp->prev =3D NULL; -+ rolep->allowed_ips =3D rtmp; -+ } else { -+ rlast->next =3D rtmp; -+ rtmp->prev =3D rlast; -+ } ++ match =3D name_set.n_hash[index]; + -+ if (!ruserip) -+ rtmp->next =3D NULL; -+ } ++ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || ++ match->deleted)) ++ match =3D match->next; + -+ return 0; ++ if (match && !match->deleted) ++ return match; ++ else ++ return NULL; +} + -+static int -+copy_user_transitions(struct acl_role_label *rolep) ++static struct inodev_entry * ++lookup_inodev_entry(const ino_t ino, const dev_t dev) +{ -+ struct role_transition *rusertp, *rtmp =3D NULL, *rlast; -+=09 -+ unsigned int len; -+ char *tmp; ++ unsigned int index =3D fhash(ino, dev, inodev_set.i_size); ++ struct inodev_entry *match; + -+ rusertp =3D rolep->transitions; ++ match =3D inodev_set.i_hash[index]; + -+ while (rusertp) { -+ rlast =3D rtmp; ++ while (match && (match->nentry->inode !=3D ino || match->nentry->devic= e !=3D dev)) ++ match =3D match->next; + -+ if ((rtmp =3D (struct role_transition *) -+ acl_alloc(sizeof (struct role_transition))) =3D=3D NULL) -+ return -ENOMEM; ++ return match; ++} + -+ if (copy_from_user(rtmp, rusertp, -+ sizeof (struct role_transition))) -+ return -EFAULT; ++static void ++insert_inodev_entry(struct inodev_entry *entry) ++{ ++ unsigned int index =3D fhash(entry->nentry->inode, entry->nentry->devi= ce, ++ inodev_set.i_size); ++ struct inodev_entry **curr; + -+ rusertp =3D rtmp->prev; ++ entry->prev =3D NULL; + -+ len =3D strnlen_user(rtmp->rolename, GR_SPROLE_LEN); ++ curr =3D &inodev_set.i_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D entry; ++=09 ++ entry->next =3D *curr; ++ *curr =3D entry; + -+ if (!len || len >=3D GR_SPROLE_LEN) -+ return -EINVAL; ++ return; ++} + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return -ENOMEM; ++static void ++__insert_acl_role_label(struct acl_role_label *role, uid_t uidgid) ++{ ++ unsigned int index =3D ++ rhash(uidgid, role->roletype & (GR_ROLE_USER | GR_ROLE_GROUP), acl= _role_set.r_size); ++ struct acl_role_label **curr; ++ struct acl_role_label *tmp; + -+ if (copy_from_user(tmp, rtmp->rolename, len)) -+ return -EFAULT; -+ tmp[len-1] =3D '\0'; -+ rtmp->rolename =3D tmp; ++ curr =3D &acl_role_set.r_hash[index]; + -+ if (!rlast) { -+ rtmp->prev =3D NULL; -+ rolep->transitions =3D rtmp; -+ } else { -+ rlast->next =3D rtmp; -+ rtmp->prev =3D rlast; -+ } ++ /* if role was already inserted due to domains and already has ++ a role in the same bucket as it attached, then we need to ++ combine these two buckets ++ */ ++ if (role->next) { ++ tmp =3D role->next; ++ while (tmp->next) ++ tmp =3D tmp->next; ++ tmp->next =3D *curr; ++ } else ++ role->next =3D *curr; ++ *curr =3D role; + -+ if (!rusertp) -+ rtmp->next =3D NULL; ++ return; ++} ++ ++static void ++insert_acl_role_label(struct acl_role_label *role) ++{ ++ int i; ++ ++ if (role_list =3D=3D NULL) { ++ role_list =3D role; ++ role->prev =3D NULL; ++ } else { ++ role->prev =3D role_list; ++ role_list =3D role; + } ++=09 ++ /* used for hash chains */ ++ role->next =3D NULL; + -+ return 0; ++ if (role->roletype & GR_ROLE_DOMAIN) { ++ for (i =3D 0; i < role->domain_child_num; i++) ++ __insert_acl_role_label(role, role->domain_children[i]); ++ } else ++ __insert_acl_role_label(role, role->uidgid); +} -+ -+static struct acl_subject_label * -+do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role) ++ =09 ++static int ++insert_name_entry(char *name, const ino_t inode, const dev_t device, __= u8 deleted) +{ -+ struct acl_subject_label *s_tmp =3D NULL, *s_tmp2; -+ unsigned int len; -+ char *tmp; -+ __u32 num_objs; -+ struct acl_ip_label **i_tmp, *i_utmp2; -+ struct gr_hash_struct ghash; -+ struct subject_map *subjmap; -+ unsigned int i_num; -+ int err; ++ struct name_entry **curr, *nentry; ++ struct inodev_entry *ientry; ++ unsigned int len =3D strlen(name); ++ unsigned int key =3D full_name_hash(name, len); ++ unsigned int index =3D key % name_set.n_size; + -+ s_tmp =3D lookup_subject_map(userp); ++ curr =3D &name_set.n_hash[index]; + -+ /* we've already copied this subject into the kernel, just return -+ the reference to it, and don't copy it over again -+ */ -+ if (s_tmp) -+ return(s_tmp); ++ while (*curr && ((*curr)->key !=3D key || !gr_streq((*curr)->name, nam= e, (*curr)->len, len))) ++ curr =3D &((*curr)->next); + -+ if ((s_tmp =3D (struct acl_subject_label *) -+ acl_alloc(sizeof (struct acl_subject_label))) =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); ++ if (*curr !=3D NULL) ++ return 1; + -+ subjmap =3D (struct subject_map *)kmalloc(sizeof (struct subject_map),= GFP_KERNEL); -+ if (subjmap =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); ++ nentry =3D acl_alloc(sizeof (struct name_entry)); ++ if (nentry =3D=3D NULL) ++ return 0; ++ ientry =3D acl_alloc(sizeof (struct inodev_entry)); ++ if (ientry =3D=3D NULL) ++ return 0; ++ ientry->nentry =3D nentry; + -+ subjmap->user =3D userp; -+ subjmap->kernel =3D s_tmp; -+ insert_subj_map_entry(subjmap); ++ nentry->key =3D key; ++ nentry->name =3D name; ++ nentry->inode =3D inode; ++ nentry->device =3D device; ++ nentry->len =3D len; ++ nentry->deleted =3D deleted; + -+ if (copy_from_user(s_tmp, userp, -+ sizeof (struct acl_subject_label))) -+ return ERR_PTR(-EFAULT); ++ nentry->prev =3D NULL; ++ curr =3D &name_set.n_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D nentry; ++ nentry->next =3D *curr; ++ *curr =3D nentry; + -+ len =3D strnlen_user(s_tmp->filename, PATH_MAX); ++ /* insert us into the table searchable by inode/dev */ ++ insert_inodev_entry(ientry); + -+ if (!len || len >=3D PATH_MAX) -+ return ERR_PTR(-EINVAL); ++ return 1; ++} + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); ++static void ++insert_acl_obj_label(struct acl_object_label *obj, ++ struct acl_subject_label *subj) ++{ ++ unsigned int index =3D ++ fhash(obj->inode, obj->device, subj->obj_hash_size); ++ struct acl_object_label **curr; + -+ if (copy_from_user(tmp, s_tmp->filename, len)) -+ return ERR_PTR(-EFAULT); -+ tmp[len-1] =3D '\0'; -+ s_tmp->filename =3D tmp; ++=09 ++ obj->prev =3D NULL; + -+ if (!strcmp(s_tmp->filename, "/")) -+ role->root_label =3D s_tmp; ++ curr =3D &subj->obj_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D obj; + -+ if (copy_from_user(&ghash, s_tmp->hash, sizeof(struct gr_hash_struct))= ) -+ return ERR_PTR(-EFAULT); ++ obj->next =3D *curr; ++ *curr =3D obj; + -+ /* copy user and group transition tables */ ++ return; ++} + -+ if (s_tmp->user_trans_num) { -+ uid_t *uidlist; ++static void ++insert_acl_subj_label(struct acl_subject_label *obj, ++ struct acl_role_label *role) ++{ ++ unsigned int index =3D fhash(obj->inode, obj->device, role->subj_hash_= size); ++ struct acl_subject_label **curr; + -+ uidlist =3D (uid_t *)acl_alloc_num(s_tmp->user_trans_num, sizeof(uid_= t)); -+ if (uidlist =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); -+ if (copy_from_user(uidlist, s_tmp->user_transitions, s_tmp->user_tran= s_num * sizeof(uid_t))) -+ return ERR_PTR(-EFAULT); ++ obj->prev =3D NULL; + -+ s_tmp->user_transitions =3D uidlist; -+ } ++ curr =3D &role->subj_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D obj; + -+ if (s_tmp->group_trans_num) { -+ gid_t *gidlist; ++ obj->next =3D *curr; ++ *curr =3D obj; + -+ gidlist =3D (gid_t *)acl_alloc_num(s_tmp->group_trans_num, sizeof(gid= _t)); -+ if (gidlist =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); -+ if (copy_from_user(gidlist, s_tmp->group_transitions, s_tmp->group_tr= ans_num * sizeof(gid_t))) -+ return ERR_PTR(-EFAULT); ++ return; ++} + -+ s_tmp->group_transitions =3D gidlist; -+ } ++/* allocating chained hash tables, so optimal size is where lambda ~ 1 = */ + -+ /* set up object hash table */ -+ num_objs =3D count_user_objs(ghash.first); ++static void * ++create_table(__u32 * len, int elementsize) ++{ ++ unsigned int table_sizes[] =3D { ++ 7, 13, 31, 61, 127, 251, 509, 1021, 2039, 4093, 8191, 16381, ++ 32749, 65521, 131071, 262139, 524287, 1048573, 2097143, ++ 4194301, 8388593, 16777213, 33554393, 67108859 ++ }; ++ void *newtable =3D NULL; ++ unsigned int pwr =3D 0; + -+ s_tmp->obj_hash_size =3D num_objs; -+ s_tmp->obj_hash =3D -+ (struct acl_object_label **) -+ create_table(&(s_tmp->obj_hash_size), sizeof(void *)); ++ while ((pwr < ((sizeof (table_sizes) / sizeof (table_sizes[0])) - 1)) = && ++ table_sizes[pwr] <=3D *len) ++ pwr++; + -+ if (!s_tmp->obj_hash) -+ return ERR_PTR(-ENOMEM); ++ if (table_sizes[pwr] <=3D *len || (table_sizes[pwr] > ULONG_MAX / elem= entsize)) ++ return newtable; + -+ memset(s_tmp->obj_hash, 0, -+ s_tmp->obj_hash_size * -+ sizeof (struct acl_object_label *)); ++ if ((table_sizes[pwr] * elementsize) <=3D PAGE_SIZE) ++ newtable =3D ++ kmalloc(table_sizes[pwr] * elementsize, GFP_KERNEL); ++ else ++ newtable =3D vmalloc(table_sizes[pwr] * elementsize); + -+ /* add in objects */ -+ err =3D copy_user_objs(ghash.first, s_tmp, role); ++ *len =3D table_sizes[pwr]; + -+ if (err) -+ return ERR_PTR(err); ++ return newtable; ++} + -+ /* set pointer for parent subject */ -+ if (s_tmp->parent_subject) { -+ s_tmp2 =3D do_copy_user_subj(s_tmp->parent_subject, role); ++static int ++init_variables(const struct gr_arg *arg) ++{ ++ struct task_struct *reaper =3D &init_task; ++ unsigned int stacksize; + -+ if (IS_ERR(s_tmp2)) -+ return s_tmp2; ++ subj_map_set.s_size =3D arg->role_db.num_subjects; ++ acl_role_set.r_size =3D arg->role_db.num_roles + arg->role_db.num_doma= in_children; ++ name_set.n_size =3D arg->role_db.num_objects; ++ inodev_set.i_size =3D arg->role_db.num_objects; + -+ s_tmp->parent_subject =3D s_tmp2; -+ } ++ if (!subj_map_set.s_size || !acl_role_set.r_size || ++ !name_set.n_size || !inodev_set.i_size) ++ return 1; + -+ /* add in ip acls */ ++ if (!gr_init_uidset()) ++ return 1; + -+ if (!s_tmp->ip_num) { -+ s_tmp->ips =3D NULL; -+ goto insert; -+ } ++ /* set up the stack that holds allocation info */ + -+ i_tmp =3D -+ (struct acl_ip_label **) acl_alloc_num(s_tmp->ip_num, -+ sizeof (struct acl_ip_label *)); ++ stacksize =3D arg->role_db.num_pointers + 5; + -+ if (!i_tmp) -+ return ERR_PTR(-ENOMEM); ++ if (!acl_alloc_stack_init(stacksize)) ++ return 1; + -+ for (i_num =3D 0; i_num < s_tmp->ip_num; i_num++) { -+ *(i_tmp + i_num) =3D -+ (struct acl_ip_label *) -+ acl_alloc(sizeof (struct acl_ip_label)); -+ if (!*(i_tmp + i_num)) -+ return ERR_PTR(-ENOMEM); ++ /* grab reference for the real root dentry and vfsmount */ ++ read_lock(&reaper->fs->lock); ++ real_root =3D dget(reaper->fs->root.dentry); ++ real_root_mnt =3D mntget(reaper->fs->root.mnt); ++ read_unlock(&reaper->fs->lock); ++=09 ++#ifdef CONFIG_GRKERNSEC_RBAC_DEBUG ++ printk(KERN_ALERT "Obtained real root device=3D%d, inode=3D%lu\n", __g= et_dev(real_root), real_root->d_inode->i_ino); ++#endif + -+ if (copy_from_user -+ (&i_utmp2, s_tmp->ips + i_num, -+ sizeof (struct acl_ip_label *))) -+ return ERR_PTR(-EFAULT); ++ fakefs_obj_rw =3D acl_alloc(sizeof(struct acl_object_label)); ++ if (fakefs_obj_rw =3D=3D NULL) ++ return 1; ++ fakefs_obj_rw->mode =3D GR_FIND | GR_READ | GR_WRITE; + -+ if (copy_from_user -+ (*(i_tmp + i_num), i_utmp2, -+ sizeof (struct acl_ip_label))) -+ return ERR_PTR(-EFAULT); -+ =09 -+ if ((*(i_tmp + i_num))->iface =3D=3D NULL) -+ continue; ++ fakefs_obj_rwx =3D acl_alloc(sizeof(struct acl_object_label)); ++ if (fakefs_obj_rwx =3D=3D NULL) ++ return 1; ++ fakefs_obj_rwx->mode =3D GR_FIND | GR_READ | GR_WRITE | GR_EXEC; + -+ len =3D strnlen_user((*(i_tmp + i_num))->iface, IFNAMSIZ); -+ if (!len || len >=3D IFNAMSIZ) -+ return ERR_PTR(-EINVAL); -+ tmp =3D acl_alloc(len); -+ if (tmp =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); -+ if (copy_from_user(tmp, (*(i_tmp + i_num))->iface, len)) -+ return ERR_PTR(-EFAULT); -+ (*(i_tmp + i_num))->iface =3D tmp; -+ } ++ subj_map_set.s_hash =3D ++ (struct subject_map **) create_table(&subj_map_set.s_size, sizeof(= void *)); ++ acl_role_set.r_hash =3D ++ (struct acl_role_label **) create_table(&acl_role_set.r_size, size= of(void *)); ++ name_set.n_hash =3D (struct name_entry **) create_table(&name_set.n_si= ze, sizeof(void *)); ++ inodev_set.i_hash =3D ++ (struct inodev_entry **) create_table(&inodev_set.i_size, sizeof(v= oid *)); + -+ s_tmp->ips =3D i_tmp; ++ if (!subj_map_set.s_hash || !acl_role_set.r_hash || ++ !name_set.n_hash || !inodev_set.i_hash) ++ return 1; + -+insert: -+ if (!insert_name_entry(s_tmp->filename, s_tmp->inode, -+ s_tmp->device, (s_tmp->mode & GR_DELETED) ? 1 : 0)) -+ return ERR_PTR(-ENOMEM); ++ memset(subj_map_set.s_hash, 0, ++ sizeof(struct subject_map *) * subj_map_set.s_size); ++ memset(acl_role_set.r_hash, 0, ++ sizeof (struct acl_role_label *) * acl_role_set.r_size); ++ memset(name_set.n_hash, 0, ++ sizeof (struct name_entry *) * name_set.n_size); ++ memset(inodev_set.i_hash, 0, ++ sizeof (struct inodev_entry *) * inodev_set.i_size); + -+ return s_tmp; ++ return 0; +} + -+static int -+copy_user_subjs(struct acl_subject_label *userp, struct acl_role_label = *role) -+{ -+ struct acl_subject_label s_pre; -+ struct acl_subject_label * ret; -+ int err; ++/* free information not needed after startup ++ currently contains user->kernel pointer mappings for subjects ++*/ + -+ while (userp) { -+ if (copy_from_user(&s_pre, userp, -+ sizeof (struct acl_subject_label))) -+ return -EFAULT; -+ =09 -+ /* do not add nested subjects here, add -+ while parsing objects -+ */ ++static void ++free_init_variables(void) ++{ ++ __u32 i; + -+ if (s_pre.mode & GR_NESTED) { -+ userp =3D s_pre.prev; -+ continue; ++ if (subj_map_set.s_hash) { ++ for (i =3D 0; i < subj_map_set.s_size; i++) { ++ if (subj_map_set.s_hash[i]) { ++ kfree(subj_map_set.s_hash[i]); ++ subj_map_set.s_hash[i] =3D NULL; ++ } + } + -+ ret =3D do_copy_user_subj(userp, role); -+ -+ err =3D PTR_ERR(ret); -+ if (IS_ERR(ret)) -+ return err; -+ -+ insert_acl_subj_label(ret, role); -+ -+ userp =3D s_pre.prev; ++ if ((subj_map_set.s_size * sizeof (struct subject_map *)) <=3D ++ PAGE_SIZE) ++ kfree(subj_map_set.s_hash); ++ else ++ vfree(subj_map_set.s_hash); + } + -+ return 0; ++ return; +} + -+static int -+copy_user_acl(struct gr_arg *arg) ++static void ++free_variables(void) +{ -+ struct acl_role_label *r_tmp =3D NULL, **r_utmp, *r_utmp2; -+ struct sprole_pw *sptmp; -+ struct gr_hash_struct *ghash; -+ uid_t *domainlist; -+ unsigned int r_num; -+ unsigned int len; -+ char *tmp; -+ int err =3D 0; -+ __u16 i; -+ __u32 num_subjs; ++ struct acl_subject_label *s; ++ struct acl_role_label *r; ++ struct task_struct *task, *task2; ++ unsigned int x; + -+ /* we need a default and kernel role */ -+ if (arg->role_db.num_roles < 2) -+ return -EINVAL; ++ gr_clear_learn_entries(); + -+ /* copy special role authentication info from userspace */ ++ read_lock(&tasklist_lock); ++ do_each_thread(task2, task) { ++ task->acl_sp_role =3D 0; ++ task->acl_role_id =3D 0; ++ task->acl =3D NULL; ++ task->role =3D NULL; ++ } while_each_thread(task2, task); ++ read_unlock(&tasklist_lock); + -+ num_sprole_pws =3D arg->num_sprole_pws; -+ acl_special_roles =3D (struct sprole_pw **) acl_alloc_num(num_sprole_p= ws, sizeof(struct sprole_pw *)); ++ /* release the reference to the real root dentry and vfsmount */ ++ if (real_root) ++ dput(real_root); ++ real_root =3D NULL; ++ if (real_root_mnt) ++ mntput(real_root_mnt); ++ real_root_mnt =3D NULL; + -+ if (!acl_special_roles) { -+ err =3D -ENOMEM; -+ goto cleanup; ++ /* free all object hash tables */ ++ ++ FOR_EACH_ROLE_START(r) ++ if (r->subj_hash =3D=3D NULL) ++ goto next_role; ++ FOR_EACH_SUBJECT_START(r, s, x) ++ if (s->obj_hash =3D=3D NULL) ++ break; ++ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) ++ kfree(s->obj_hash); ++ else ++ vfree(s->obj_hash); ++ FOR_EACH_SUBJECT_END(s, x) ++ FOR_EACH_NESTED_SUBJECT_START(r, s) ++ if (s->obj_hash =3D=3D NULL) ++ break; ++ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) ++ kfree(s->obj_hash); ++ else ++ vfree(s->obj_hash); ++ FOR_EACH_NESTED_SUBJECT_END(s) ++ if ((r->subj_hash_size * sizeof (struct acl_subject_label *)) <=3D PA= GE_SIZE) ++ kfree(r->subj_hash); ++ else ++ vfree(r->subj_hash); ++ r->subj_hash =3D NULL; ++next_role: ++ FOR_EACH_ROLE_END(r) ++ ++ acl_free_all(); ++ ++ if (acl_role_set.r_hash) { ++ if ((acl_role_set.r_size * sizeof (struct acl_role_label *)) <=3D ++ PAGE_SIZE) ++ kfree(acl_role_set.r_hash); ++ else ++ vfree(acl_role_set.r_hash); ++ } ++ if (name_set.n_hash) { ++ if ((name_set.n_size * sizeof (struct name_entry *)) <=3D ++ PAGE_SIZE) ++ kfree(name_set.n_hash); ++ else ++ vfree(name_set.n_hash); + } + -+ for (i =3D 0; i < num_sprole_pws; i++) { -+ sptmp =3D (struct sprole_pw *) acl_alloc(sizeof(struct sprole_pw)); -+ if (!sptmp) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } -+ if (copy_from_user(sptmp, arg->sprole_pws + i, -+ sizeof (struct sprole_pw))) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } ++ if (inodev_set.i_hash) { ++ if ((inodev_set.i_size * sizeof (struct inodev_entry *)) <=3D ++ PAGE_SIZE) ++ kfree(inodev_set.i_hash); ++ else ++ vfree(inodev_set.i_hash); ++ } + -+ len =3D -+ strnlen_user(sptmp->rolename, GR_SPROLE_LEN); ++ gr_free_uidset(); + -+ if (!len || len >=3D GR_SPROLE_LEN) { -+ err =3D -EINVAL; -+ goto cleanup; -+ } ++ memset(&name_set, 0, sizeof (struct name_db)); ++ memset(&inodev_set, 0, sizeof (struct inodev_db)); ++ memset(&acl_role_set, 0, sizeof (struct acl_role_db)); ++ memset(&subj_map_set, 0, sizeof (struct acl_subj_map_db)); + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } ++ default_role =3D NULL; ++ role_list =3D NULL; + -+ if (copy_from_user(tmp, sptmp->rolename, len)) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } -+ tmp[len-1] =3D '\0'; -+#ifdef CONFIG_GRKERNSEC_RBAC_DEBUG -+ printk(KERN_ALERT "Copying special role %s\n", tmp); -+#endif -+ sptmp->rolename =3D tmp; -+ acl_special_roles[i] =3D sptmp; ++ return; ++} ++ ++static __u32 ++count_user_objs(struct acl_object_label *userp) ++{ ++ struct acl_object_label o_tmp; ++ __u32 num =3D 0; ++ ++ while (userp) { ++ if (copy_from_user(&o_tmp, userp, ++ sizeof (struct acl_object_label))) ++ break; ++ ++ userp =3D o_tmp.prev; ++ num++; + } + -+ r_utmp =3D (struct acl_role_label **) arg->role_db.r_table; ++ return num; ++} + -+ for (r_num =3D 0; r_num < arg->role_db.num_roles; r_num++) { -+ r_tmp =3D acl_alloc(sizeof (struct acl_role_label)); ++static struct acl_subject_label * ++do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role); + -+ if (!r_tmp) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } ++static int ++copy_user_glob(struct acl_object_label *obj) ++{ ++ struct acl_object_label *g_tmp, **guser; ++ unsigned int len; ++ char *tmp; + -+ if (copy_from_user(&r_utmp2, r_utmp + r_num, -+ sizeof (struct acl_role_label *))) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } ++ if (obj->globbed =3D=3D NULL) ++ return 0; + -+ if (copy_from_user(r_tmp, r_utmp2, -+ sizeof (struct acl_role_label))) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } ++ guser =3D &obj->globbed; ++ while (*guser) { ++ g_tmp =3D (struct acl_object_label *) ++ acl_alloc(sizeof (struct acl_object_label)); ++ if (g_tmp =3D=3D NULL) ++ return -ENOMEM; + -+ len =3D strnlen_user(r_tmp->rolename, GR_SPROLE_LEN); ++ if (copy_from_user(g_tmp, *guser, ++ sizeof (struct acl_object_label))) ++ return -EFAULT; + -+ if (!len || len >=3D PATH_MAX) { -+ err =3D -EINVAL; -+ goto cleanup; -+ } ++ len =3D strnlen_user(g_tmp->filename, PATH_MAX); + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } -+ if (copy_from_user(tmp, r_tmp->rolename, len)) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } ++ if (!len || len >=3D PATH_MAX) ++ return -EINVAL; ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(tmp, g_tmp->filename, len)) ++ return -EFAULT; + tmp[len-1] =3D '\0'; -+ r_tmp->rolename =3D tmp; ++ g_tmp->filename =3D tmp; + -+ if (!strcmp(r_tmp->rolename, "default") -+ && (r_tmp->roletype & GR_ROLE_DEFAULT)) { -+ default_role =3D r_tmp; -+ } else if (!strcmp(r_tmp->rolename, ":::kernel:::")) { -+ kernel_role =3D r_tmp; -+ } ++ *guser =3D g_tmp; ++ guser =3D &(g_tmp->next); ++ } + -+ if ((ghash =3D (struct gr_hash_struct *) acl_alloc(sizeof(struct gr_h= ash_struct))) =3D=3D NULL) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } -+ if (copy_from_user(ghash, r_tmp->hash, sizeof(struct gr_hash_struct))= ) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } ++ return 0; ++} + -+ r_tmp->hash =3D ghash; ++static int ++copy_user_objs(struct acl_object_label *userp, struct acl_subject_label= *subj, ++ struct acl_role_label *role) ++{ ++ struct acl_object_label *o_tmp; ++ unsigned int len; ++ int ret; ++ char *tmp; + -+ num_subjs =3D count_user_subjs(r_tmp->hash->first); ++ while (userp) { ++ if ((o_tmp =3D (struct acl_object_label *) ++ acl_alloc(sizeof (struct acl_object_label))) =3D=3D NULL) ++ return -ENOMEM; + -+ r_tmp->subj_hash_size =3D num_subjs; -+ r_tmp->subj_hash =3D -+ (struct acl_subject_label **) -+ create_table(&(r_tmp->subj_hash_size), sizeof(void *)); ++ if (copy_from_user(o_tmp, userp, ++ sizeof (struct acl_object_label))) ++ return -EFAULT; + -+ if (!r_tmp->subj_hash) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } ++ userp =3D o_tmp->prev; + -+ err =3D copy_user_allowedips(r_tmp); -+ if (err) -+ goto cleanup; ++ len =3D strnlen_user(o_tmp->filename, PATH_MAX); + -+ /* copy domain info */ -+ if (r_tmp->domain_children !=3D NULL) { -+ domainlist =3D acl_alloc_num(r_tmp->domain_child_num, sizeof(uid_t))= ; -+ if (domainlist =3D=3D NULL) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } -+ if (copy_from_user(domainlist, r_tmp->domain_children, r_tmp->domain= _child_num * sizeof(uid_t))) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } -+ r_tmp->domain_children =3D domainlist; -+ } ++ if (!len || len >=3D PATH_MAX) ++ return -EINVAL; + -+ err =3D copy_user_transitions(r_tmp); -+ if (err) -+ goto cleanup; ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return -ENOMEM; + -+ memset(r_tmp->subj_hash, 0, -+ r_tmp->subj_hash_size * -+ sizeof (struct acl_subject_label *)); ++ if (copy_from_user(tmp, o_tmp->filename, len)) ++ return -EFAULT; ++ tmp[len-1] =3D '\0'; ++ o_tmp->filename =3D tmp; + -+ err =3D copy_user_subjs(r_tmp->hash->first, r_tmp); ++ insert_acl_obj_label(o_tmp, subj); ++ if (!insert_name_entry(o_tmp->filename, o_tmp->inode, ++ o_tmp->device, (o_tmp->mode & GR_DELETED) ? 1 : 0)) ++ return -ENOMEM; + -+ if (err) -+ goto cleanup; ++ ret =3D copy_user_glob(o_tmp); ++ if (ret) ++ return ret; + -+ /* set nested subject list to null */ -+ r_tmp->hash->first =3D NULL; ++ if (o_tmp->nested) { ++ o_tmp->nested =3D do_copy_user_subj(o_tmp->nested, role); ++ if (IS_ERR(o_tmp->nested)) ++ return PTR_ERR(o_tmp->nested); + -+ insert_acl_role_label(r_tmp); ++ /* insert into nested subject list */ ++ o_tmp->nested->next =3D role->hash->first; ++ role->hash->first =3D o_tmp->nested; ++ } + } + -+ goto return_err; -+ cleanup: -+ free_variables(); -+ return_err: -+ return err; ++ return 0; ++} ++ ++static __u32 ++count_user_subjs(struct acl_subject_label *userp) ++{ ++ struct acl_subject_label s_tmp; ++ __u32 num =3D 0; ++ ++ while (userp) { ++ if (copy_from_user(&s_tmp, userp, ++ sizeof (struct acl_subject_label))) ++ break; ++ ++ userp =3D s_tmp.prev; ++ /* do not count nested subjects against this count, since ++ they are not included in the hash table, but are ++ attached to objects. We have already counted ++ the subjects in userspace for the allocation=20 ++ stack ++ */ ++ if (!(s_tmp.mode & GR_NESTED)) ++ num++; ++ } + ++ return num; +} + +static int -+gracl_init(struct gr_arg *args) ++copy_user_allowedips(struct acl_role_label *rolep) +{ -+ int error =3D 0; ++ struct role_allowed_ip *ruserip, *rtmp =3D NULL, *rlast; + -+ memcpy(gr_system_salt, args->salt, GR_SALT_LEN); -+ memcpy(gr_system_sum, args->sum, GR_SHA_LEN); ++ ruserip =3D rolep->allowed_ips; + -+ if (init_variables(args)) { -+ gr_log_str(GR_DONT_AUDIT_GOOD, GR_INITF_ACL_MSG, GR_VERSION); -+ error =3D -ENOMEM; -+ free_variables(); -+ goto out; -+ } ++ while (ruserip) { ++ rlast =3D rtmp; + -+ error =3D copy_user_acl(args); -+ free_init_variables(); -+ if (error) { -+ free_variables(); -+ goto out; -+ } ++ if ((rtmp =3D (struct role_allowed_ip *) ++ acl_alloc(sizeof (struct role_allowed_ip))) =3D=3D NULL) ++ return -ENOMEM; + -+ if ((error =3D gr_set_acls(0))) { -+ free_variables(); -+ goto out; -+ } ++ if (copy_from_user(rtmp, ruserip, ++ sizeof (struct role_allowed_ip))) ++ return -EFAULT; + -+ pax_open_kernel(); -+ gr_status |=3D GR_READY; -+ pax_close_kernel(); ++ ruserip =3D rtmp->prev; + -+ out: -+ return error; -+} ++ if (!rlast) { ++ rtmp->prev =3D NULL; ++ rolep->allowed_ips =3D rtmp; ++ } else { ++ rlast->next =3D rtmp; ++ rtmp->prev =3D rlast; ++ } + -+/* derived from glibc fnmatch() 0: match, 1: no match*/ ++ if (!ruserip) ++ rtmp->next =3D NULL; ++ } ++ ++ return 0; ++} + +static int -+glob_match(const char *p, const char *n) ++copy_user_transitions(struct acl_role_label *rolep) +{ -+ char c; ++ struct role_transition *rusertp, *rtmp =3D NULL, *rlast; ++=09 ++ unsigned int len; ++ char *tmp; + -+ while ((c =3D *p++) !=3D '\0') { -+ switch (c) { -+ case '?': -+ if (*n =3D=3D '\0') -+ return 1; -+ else if (*n =3D=3D '/') -+ return 1; -+ break; -+ case '\\': -+ if (*n !=3D c) -+ return 1; -+ break; -+ case '*': -+ for (c =3D *p++; c =3D=3D '?' || c =3D=3D '*'; c =3D *p++) { -+ if (*n =3D=3D '/') -+ return 1; -+ else if (c =3D=3D '?') { -+ if (*n =3D=3D '\0') -+ return 1; -+ else -+ ++n; -+ } -+ } -+ if (c =3D=3D '\0') { -+ return 0; -+ } else { -+ const char *endp; ++ rusertp =3D rolep->transitions; + -+ if ((endp =3D strchr(n, '/')) =3D=3D NULL) -+ endp =3D n + strlen(n); ++ while (rusertp) { ++ rlast =3D rtmp; + -+ if (c =3D=3D '[') { -+ for (--p; n < endp; ++n) -+ if (!glob_match(p, n)) -+ return 0; -+ } else if (c =3D=3D '/') { -+ while (*n !=3D '\0' && *n !=3D '/') -+ ++n; -+ if (*n =3D=3D '/' && !glob_match(p, n + 1)) -+ return 0; -+ } else { -+ for (--p; n < endp; ++n) -+ if (*n =3D=3D c && !glob_match(p, n)) -+ return 0; -+ } ++ if ((rtmp =3D (struct role_transition *) ++ acl_alloc(sizeof (struct role_transition))) =3D=3D NULL) ++ return -ENOMEM; + -+ return 1; -+ } -+ case '[': -+ { -+ int not; -+ char cold; ++ if (copy_from_user(rtmp, rusertp, ++ sizeof (struct role_transition))) ++ return -EFAULT; + -+ if (*n =3D=3D '\0' || *n =3D=3D '/') -+ return 1; ++ rusertp =3D rtmp->prev; + -+ not =3D (*p =3D=3D '!' || *p =3D=3D '^'); -+ if (not) -+ ++p; ++ len =3D strnlen_user(rtmp->rolename, GR_SPROLE_LEN); + -+ c =3D *p++; -+ for (;;) { -+ unsigned char fn =3D (unsigned char)*n; ++ if (!len || len >=3D GR_SPROLE_LEN) ++ return -EINVAL; + -+ if (c =3D=3D '\0') -+ return 1; -+ else { -+ if (c =3D=3D fn) -+ goto matched; -+ cold =3D c; -+ c =3D *p++; ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return -ENOMEM; + -+ if (c =3D=3D '-' && *p !=3D ']') { -+ unsigned char cend =3D *p++; ++ if (copy_from_user(tmp, rtmp->rolename, len)) ++ return -EFAULT; ++ tmp[len-1] =3D '\0'; ++ rtmp->rolename =3D tmp; + -+ if (cend =3D=3D '\0') -+ return 1; ++ if (!rlast) { ++ rtmp->prev =3D NULL; ++ rolep->transitions =3D rtmp; ++ } else { ++ rlast->next =3D rtmp; ++ rtmp->prev =3D rlast; ++ } + -+ if (cold <=3D fn && fn <=3D cend) -+ goto matched; ++ if (!rusertp) ++ rtmp->next =3D NULL; ++ } + -+ c =3D *p++; -+ } -+ } ++ return 0; ++} ++ ++static struct acl_subject_label * ++do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role) ++{ ++ struct acl_subject_label *s_tmp =3D NULL, *s_tmp2; ++ unsigned int len; ++ char *tmp; ++ __u32 num_objs; ++ struct acl_ip_label **i_tmp, *i_utmp2; ++ struct gr_hash_struct ghash; ++ struct subject_map *subjmap; ++ unsigned int i_num; ++ int err; ++ ++ s_tmp =3D lookup_subject_map(userp); ++ ++ /* we've already copied this subject into the kernel, just return ++ the reference to it, and don't copy it over again ++ */ ++ if (s_tmp) ++ return(s_tmp); ++ ++ if ((s_tmp =3D (struct acl_subject_label *) ++ acl_alloc(sizeof (struct acl_subject_label))) =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ ++ subjmap =3D (struct subject_map *)kmalloc(sizeof (struct subject_map),= GFP_KERNEL); ++ if (subjmap =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ ++ subjmap->user =3D userp; ++ subjmap->kernel =3D s_tmp; ++ insert_subj_map_entry(subjmap); ++ ++ if (copy_from_user(s_tmp, userp, ++ sizeof (struct acl_subject_label))) ++ return ERR_PTR(-EFAULT); ++ ++ len =3D strnlen_user(s_tmp->filename, PATH_MAX); ++ ++ if (!len || len >=3D PATH_MAX) ++ return ERR_PTR(-EINVAL); ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ ++ if (copy_from_user(tmp, s_tmp->filename, len)) ++ return ERR_PTR(-EFAULT); ++ tmp[len-1] =3D '\0'; ++ s_tmp->filename =3D tmp; ++ ++ if (!strcmp(s_tmp->filename, "/")) ++ role->root_label =3D s_tmp; ++ ++ if (copy_from_user(&ghash, s_tmp->hash, sizeof(struct gr_hash_struct))= ) ++ return ERR_PTR(-EFAULT); ++ ++ /* copy user and group transition tables */ ++ ++ if (s_tmp->user_trans_num) { ++ uid_t *uidlist; ++ ++ uidlist =3D (uid_t *)acl_alloc_num(s_tmp->user_trans_num, sizeof(uid_= t)); ++ if (uidlist =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ if (copy_from_user(uidlist, s_tmp->user_transitions, s_tmp->user_tran= s_num * sizeof(uid_t))) ++ return ERR_PTR(-EFAULT); ++ ++ s_tmp->user_transitions =3D uidlist; ++ } ++ ++ if (s_tmp->group_trans_num) { ++ gid_t *gidlist; ++ ++ gidlist =3D (gid_t *)acl_alloc_num(s_tmp->group_trans_num, sizeof(gid= _t)); ++ if (gidlist =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ if (copy_from_user(gidlist, s_tmp->group_transitions, s_tmp->group_tr= ans_num * sizeof(gid_t))) ++ return ERR_PTR(-EFAULT); ++ ++ s_tmp->group_transitions =3D gidlist; ++ } ++ ++ /* set up object hash table */ ++ num_objs =3D count_user_objs(ghash.first); ++ ++ s_tmp->obj_hash_size =3D num_objs; ++ s_tmp->obj_hash =3D ++ (struct acl_object_label **) ++ create_table(&(s_tmp->obj_hash_size), sizeof(void *)); ++ ++ if (!s_tmp->obj_hash) ++ return ERR_PTR(-ENOMEM); ++ ++ memset(s_tmp->obj_hash, 0, ++ s_tmp->obj_hash_size * ++ sizeof (struct acl_object_label *)); ++ ++ /* add in objects */ ++ err =3D copy_user_objs(ghash.first, s_tmp, role); ++ ++ if (err) ++ return ERR_PTR(err); ++ ++ /* set pointer for parent subject */ ++ if (s_tmp->parent_subject) { ++ s_tmp2 =3D do_copy_user_subj(s_tmp->parent_subject, role); ++ ++ if (IS_ERR(s_tmp2)) ++ return s_tmp2; ++ ++ s_tmp->parent_subject =3D s_tmp2; ++ } ++ ++ /* add in ip acls */ ++ ++ if (!s_tmp->ip_num) { ++ s_tmp->ips =3D NULL; ++ goto insert; ++ } ++ ++ i_tmp =3D ++ (struct acl_ip_label **) acl_alloc_num(s_tmp->ip_num, ++ sizeof (struct acl_ip_label *)); ++ ++ if (!i_tmp) ++ return ERR_PTR(-ENOMEM); ++ ++ for (i_num =3D 0; i_num < s_tmp->ip_num; i_num++) { ++ *(i_tmp + i_num) =3D ++ (struct acl_ip_label *) ++ acl_alloc(sizeof (struct acl_ip_label)); ++ if (!*(i_tmp + i_num)) ++ return ERR_PTR(-ENOMEM); ++ ++ if (copy_from_user ++ (&i_utmp2, s_tmp->ips + i_num, ++ sizeof (struct acl_ip_label *))) ++ return ERR_PTR(-EFAULT); ++ ++ if (copy_from_user ++ (*(i_tmp + i_num), i_utmp2, ++ sizeof (struct acl_ip_label))) ++ return ERR_PTR(-EFAULT); ++ =09 ++ if ((*(i_tmp + i_num))->iface =3D=3D NULL) ++ continue; ++ ++ len =3D strnlen_user((*(i_tmp + i_num))->iface, IFNAMSIZ); ++ if (!len || len >=3D IFNAMSIZ) ++ return ERR_PTR(-EINVAL); ++ tmp =3D acl_alloc(len); ++ if (tmp =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ if (copy_from_user(tmp, (*(i_tmp + i_num))->iface, len)) ++ return ERR_PTR(-EFAULT); ++ (*(i_tmp + i_num))->iface =3D tmp; ++ } ++ ++ s_tmp->ips =3D i_tmp; ++ ++insert: ++ if (!insert_name_entry(s_tmp->filename, s_tmp->inode, ++ s_tmp->device, (s_tmp->mode & GR_DELETED) ? 1 : 0)) ++ return ERR_PTR(-ENOMEM); ++ ++ return s_tmp; ++} ++ ++static int ++copy_user_subjs(struct acl_subject_label *userp, struct acl_role_label = *role) ++{ ++ struct acl_subject_label s_pre; ++ struct acl_subject_label * ret; ++ int err; ++ ++ while (userp) { ++ if (copy_from_user(&s_pre, userp, ++ sizeof (struct acl_subject_label))) ++ return -EFAULT; ++ =09 ++ /* do not add nested subjects here, add ++ while parsing objects ++ */ ++ ++ if (s_pre.mode & GR_NESTED) { ++ userp =3D s_pre.prev; ++ continue; ++ } ++ ++ ret =3D do_copy_user_subj(userp, role); ++ ++ err =3D PTR_ERR(ret); ++ if (IS_ERR(ret)) ++ return err; ++ ++ insert_acl_subj_label(ret, role); ++ ++ userp =3D s_pre.prev; ++ } ++ ++ return 0; ++} ++ ++static int ++copy_user_acl(struct gr_arg *arg) ++{ ++ struct acl_role_label *r_tmp =3D NULL, **r_utmp, *r_utmp2; ++ struct sprole_pw *sptmp; ++ struct gr_hash_struct *ghash; ++ uid_t *domainlist; ++ unsigned int r_num; ++ unsigned int len; ++ char *tmp; ++ int err =3D 0; ++ __u16 i; ++ __u32 num_subjs; ++ ++ /* we need a default and kernel role */ ++ if (arg->role_db.num_roles < 2) ++ return -EINVAL; ++ ++ /* copy special role authentication info from userspace */ ++ ++ num_sprole_pws =3D arg->num_sprole_pws; ++ acl_special_roles =3D (struct sprole_pw **) acl_alloc_num(num_sprole_p= ws, sizeof(struct sprole_pw *)); ++ ++ if (!acl_special_roles) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ ++ for (i =3D 0; i < num_sprole_pws; i++) { ++ sptmp =3D (struct sprole_pw *) acl_alloc(sizeof(struct sprole_pw)); ++ if (!sptmp) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ if (copy_from_user(sptmp, arg->sprole_pws + i, ++ sizeof (struct sprole_pw))) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ ++ len =3D ++ strnlen_user(sptmp->rolename, GR_SPROLE_LEN); ++ ++ if (!len || len >=3D GR_SPROLE_LEN) { ++ err =3D -EINVAL; ++ goto cleanup; ++ } ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ ++ if (copy_from_user(tmp, sptmp->rolename, len)) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ tmp[len-1] =3D '\0'; ++#ifdef CONFIG_GRKERNSEC_RBAC_DEBUG ++ printk(KERN_ALERT "Copying special role %s\n", tmp); ++#endif ++ sptmp->rolename =3D tmp; ++ acl_special_roles[i] =3D sptmp; ++ } ++ ++ r_utmp =3D (struct acl_role_label **) arg->role_db.r_table; ++ ++ for (r_num =3D 0; r_num < arg->role_db.num_roles; r_num++) { ++ r_tmp =3D acl_alloc(sizeof (struct acl_role_label)); ++ ++ if (!r_tmp) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ ++ if (copy_from_user(&r_utmp2, r_utmp + r_num, ++ sizeof (struct acl_role_label *))) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ ++ if (copy_from_user(r_tmp, r_utmp2, ++ sizeof (struct acl_role_label))) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ ++ len =3D strnlen_user(r_tmp->rolename, GR_SPROLE_LEN); ++ ++ if (!len || len >=3D PATH_MAX) { ++ err =3D -EINVAL; ++ goto cleanup; ++ } ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ if (copy_from_user(tmp, r_tmp->rolename, len)) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ tmp[len-1] =3D '\0'; ++ r_tmp->rolename =3D tmp; ++ ++ if (!strcmp(r_tmp->rolename, "default") ++ && (r_tmp->roletype & GR_ROLE_DEFAULT)) { ++ default_role =3D r_tmp; ++ } else if (!strcmp(r_tmp->rolename, ":::kernel:::")) { ++ kernel_role =3D r_tmp; ++ } ++ ++ if ((ghash =3D (struct gr_hash_struct *) acl_alloc(sizeof(struct gr_h= ash_struct))) =3D=3D NULL) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ if (copy_from_user(ghash, r_tmp->hash, sizeof(struct gr_hash_struct))= ) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ ++ r_tmp->hash =3D ghash; ++ ++ num_subjs =3D count_user_subjs(r_tmp->hash->first); ++ ++ r_tmp->subj_hash_size =3D num_subjs; ++ r_tmp->subj_hash =3D ++ (struct acl_subject_label **) ++ create_table(&(r_tmp->subj_hash_size), sizeof(void *)); ++ ++ if (!r_tmp->subj_hash) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ ++ err =3D copy_user_allowedips(r_tmp); ++ if (err) ++ goto cleanup; ++ ++ /* copy domain info */ ++ if (r_tmp->domain_children !=3D NULL) { ++ domainlist =3D acl_alloc_num(r_tmp->domain_child_num, sizeof(uid_t))= ; ++ if (domainlist =3D=3D NULL) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ if (copy_from_user(domainlist, r_tmp->domain_children, r_tmp->domain= _child_num * sizeof(uid_t))) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ r_tmp->domain_children =3D domainlist; ++ } ++ ++ err =3D copy_user_transitions(r_tmp); ++ if (err) ++ goto cleanup; ++ ++ memset(r_tmp->subj_hash, 0, ++ r_tmp->subj_hash_size * ++ sizeof (struct acl_subject_label *)); ++ ++ err =3D copy_user_subjs(r_tmp->hash->first, r_tmp); ++ ++ if (err) ++ goto cleanup; ++ ++ /* set nested subject list to null */ ++ r_tmp->hash->first =3D NULL; ++ ++ insert_acl_role_label(r_tmp); ++ } ++ ++ goto return_err; ++ cleanup: ++ free_variables(); ++ return_err: ++ return err; ++ ++} ++ ++static int ++gracl_init(struct gr_arg *args) ++{ ++ int error =3D 0; ++ ++ memcpy(gr_system_salt, args->salt, GR_SALT_LEN); ++ memcpy(gr_system_sum, args->sum, GR_SHA_LEN); ++ ++ if (init_variables(args)) { ++ gr_log_str(GR_DONT_AUDIT_GOOD, GR_INITF_ACL_MSG, GR_VERSION); ++ error =3D -ENOMEM; ++ free_variables(); ++ goto out; ++ } ++ ++ error =3D copy_user_acl(args); ++ free_init_variables(); ++ if (error) { ++ free_variables(); ++ goto out; ++ } ++ ++ if ((error =3D gr_set_acls(0))) { ++ free_variables(); ++ goto out; ++ } ++ ++ pax_open_kernel(); ++ gr_status |=3D GR_READY; ++ pax_close_kernel(); ++ ++ out: ++ return error; ++} ++ ++/* derived from glibc fnmatch() 0: match, 1: no match*/ ++ ++static int ++glob_match(const char *p, const char *n) ++{ ++ char c; ++ ++ while ((c =3D *p++) !=3D '\0') { ++ switch (c) { ++ case '?': ++ if (*n =3D=3D '\0') ++ return 1; ++ else if (*n =3D=3D '/') ++ return 1; ++ break; ++ case '\\': ++ if (*n !=3D c) ++ return 1; ++ break; ++ case '*': ++ for (c =3D *p++; c =3D=3D '?' || c =3D=3D '*'; c =3D *p++) { ++ if (*n =3D=3D '/') ++ return 1; ++ else if (c =3D=3D '?') { ++ if (*n =3D=3D '\0') ++ return 1; ++ else ++ ++n; ++ } ++ } ++ if (c =3D=3D '\0') { ++ return 0; ++ } else { ++ const char *endp; ++ ++ if ((endp =3D strchr(n, '/')) =3D=3D NULL) ++ endp =3D n + strlen(n); ++ ++ if (c =3D=3D '[') { ++ for (--p; n < endp; ++n) ++ if (!glob_match(p, n)) ++ return 0; ++ } else if (c =3D=3D '/') { ++ while (*n !=3D '\0' && *n !=3D '/') ++ ++n; ++ if (*n =3D=3D '/' && !glob_match(p, n + 1)) ++ return 0; ++ } else { ++ for (--p; n < endp; ++n) ++ if (*n =3D=3D c && !glob_match(p, n)) ++ return 0; ++ } ++ ++ return 1; ++ } ++ case '[': ++ { ++ int not; ++ char cold; ++ ++ if (*n =3D=3D '\0' || *n =3D=3D '/') ++ return 1; ++ ++ not =3D (*p =3D=3D '!' || *p =3D=3D '^'); ++ if (not) ++ ++p; ++ ++ c =3D *p++; ++ for (;;) { ++ unsigned char fn =3D (unsigned char)*n; ++ ++ if (c =3D=3D '\0') ++ return 1; ++ else { ++ if (c =3D=3D fn) ++ goto matched; ++ cold =3D c; ++ c =3D *p++; ++ ++ if (c =3D=3D '-' && *p !=3D ']') { ++ unsigned char cend =3D *p++; ++ ++ if (cend =3D=3D '\0') ++ return 1; ++ ++ if (cold <=3D fn && fn <=3D cend) ++ goto matched; ++ ++ c =3D *p++; ++ } ++ } + + if (c =3D=3D ']') + break; @@ -56428,9 +59433,122 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl.c l= inux-2.6.32.49/grsecurity/gracl.c +EXPORT_SYMBOL(gr_check_group_change); +#endif + -diff -urNp linux-2.6.32.49/grsecurity/gracl_cap.c linux-2.6.32.49/grsecu= rity/gracl_cap.c ---- linux-2.6.32.49/grsecurity/gracl_cap.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/gracl_cap.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/grsecurity/gracl_alloc.c b/grsecurity/gracl_alloc.c +new file mode 100644 +index 0000000..34fefda +--- /dev/null ++++ b/grsecurity/gracl_alloc.c +@@ -0,0 +1,105 @@ ++#include ++#include ++#include ++#include ++#include ++#include ++ ++static unsigned long alloc_stack_next =3D 1; ++static unsigned long alloc_stack_size =3D 1; ++static void **alloc_stack; ++ ++static __inline__ int ++alloc_pop(void) ++{ ++ if (alloc_stack_next =3D=3D 1) ++ return 0; ++ ++ kfree(alloc_stack[alloc_stack_next - 2]); ++ ++ alloc_stack_next--; ++ ++ return 1; ++} ++ ++static __inline__ int ++alloc_push(void *buf) ++{ ++ if (alloc_stack_next >=3D alloc_stack_size) ++ return 1; ++ ++ alloc_stack[alloc_stack_next - 1] =3D buf; ++ ++ alloc_stack_next++; ++ ++ return 0; ++} ++ ++void * ++acl_alloc(unsigned long len) ++{ ++ void *ret =3D NULL; ++ ++ if (!len || len > PAGE_SIZE) ++ goto out; ++ ++ ret =3D kmalloc(len, GFP_KERNEL); ++ ++ if (ret) { ++ if (alloc_push(ret)) { ++ kfree(ret); ++ ret =3D NULL; ++ } ++ } ++ ++out: ++ return ret; ++} ++ ++void * ++acl_alloc_num(unsigned long num, unsigned long len) ++{ ++ if (!len || (num > (PAGE_SIZE / len))) ++ return NULL; ++ ++ return acl_alloc(num * len); ++} ++ ++void ++acl_free_all(void) ++{ ++ if (gr_acl_is_enabled() || !alloc_stack) ++ return; ++ ++ while (alloc_pop()) ; ++ ++ if (alloc_stack) { ++ if ((alloc_stack_size * sizeof (void *)) <=3D PAGE_SIZE) ++ kfree(alloc_stack); ++ else ++ vfree(alloc_stack); ++ } ++ ++ alloc_stack =3D NULL; ++ alloc_stack_size =3D 1; ++ alloc_stack_next =3D 1; ++ ++ return; ++} ++ ++int ++acl_alloc_stack_init(unsigned long size) ++{ ++ if ((size * sizeof (void *)) <=3D PAGE_SIZE) ++ alloc_stack =3D ++ (void **) kmalloc(size * sizeof (void *), GFP_KERNEL); ++ else ++ alloc_stack =3D (void **) vmalloc(size * sizeof (void *)); ++ ++ alloc_stack_size =3D size; ++ ++ if (!alloc_stack) ++ return 0; ++ else ++ return 1; ++} +diff --git a/grsecurity/gracl_cap.c b/grsecurity/gracl_cap.c +new file mode 100644 +index 0000000..955ddfb +--- /dev/null ++++ b/grsecurity/gracl_cap.c @@ -0,0 +1,101 @@ +#include +#include @@ -56533,9 +59651,11 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl_cap.= c linux-2.6.32.49/grsecurity/gra + return 0; +} + -diff -urNp linux-2.6.32.49/grsecurity/gracl_fs.c linux-2.6.32.49/grsecur= ity/gracl_fs.c ---- linux-2.6.32.49/grsecurity/gracl_fs.c 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-2.6.32.49/grsecurity/gracl_fs.c 2011-11-18 19:29:57.000000000 = -0500 +diff --git a/grsecurity/gracl_fs.c b/grsecurity/gracl_fs.c +new file mode 100644 +index 0000000..d5f210c +--- /dev/null ++++ b/grsecurity/gracl_fs.c @@ -0,0 +1,433 @@ +#include +#include @@ -56970,9 +60090,11 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl_fs.c= linux-2.6.32.49/grsecurity/grac + + return 0; +} -diff -urNp linux-2.6.32.49/grsecurity/gracl_ip.c linux-2.6.32.49/grsecur= ity/gracl_ip.c ---- linux-2.6.32.49/grsecurity/gracl_ip.c 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-2.6.32.49/grsecurity/gracl_ip.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/grsecurity/gracl_ip.c b/grsecurity/gracl_ip.c +new file mode 100644 +index 0000000..cd07b96 +--- /dev/null ++++ b/grsecurity/gracl_ip.c @@ -0,0 +1,382 @@ +#include +#include @@ -57356,9 +60478,11 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl_ip.c= linux-2.6.32.49/grsecurity/grac + + return gr_search_connectbind(GR_CONNECT | GR_CONNECTOVERRIDE, sk, &sin= , SOCK_DGRAM); +} -diff -urNp linux-2.6.32.49/grsecurity/gracl_learn.c linux-2.6.32.49/grse= curity/gracl_learn.c ---- linux-2.6.32.49/grsecurity/gracl_learn.c 1969-12-31 19:00:00.0000000= 00 -0500 -+++ linux-2.6.32.49/grsecurity/gracl_learn.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/grsecurity/gracl_learn.c b/grsecurity/gracl_learn.c +new file mode 100644 +index 0000000..34bdd46 +--- /dev/null ++++ b/grsecurity/gracl_learn.c @@ -0,0 +1,208 @@ +#include +#include @@ -57568,9 +60692,11 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl_lear= n.c linux-2.6.32.49/grsecurity/g + .release =3D close_learn, + .poll =3D poll_learn, +}; -diff -urNp linux-2.6.32.49/grsecurity/gracl_res.c linux-2.6.32.49/grsecu= rity/gracl_res.c ---- linux-2.6.32.49/grsecurity/gracl_res.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/gracl_res.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/grsecurity/gracl_res.c b/grsecurity/gracl_res.c +new file mode 100644 +index 0000000..70b2179 +--- /dev/null ++++ b/grsecurity/gracl_res.c @@ -0,0 +1,67 @@ +#include +#include @@ -57639,9 +60765,11 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl_res.= c linux-2.6.32.49/grsecurity/gra + rcu_read_unlock(); + return; +} -diff -urNp linux-2.6.32.49/grsecurity/gracl_segv.c linux-2.6.32.49/grsec= urity/gracl_segv.c ---- linux-2.6.32.49/grsecurity/gracl_segv.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/gracl_segv.c 2011-11-17 20:48:17.00000000= 0 -0500 +diff --git a/grsecurity/gracl_segv.c b/grsecurity/gracl_segv.c +new file mode 100644 +index 0000000..1d1b734 +--- /dev/null ++++ b/grsecurity/gracl_segv.c @@ -0,0 +1,284 @@ +#include +#include @@ -57927,9 +61055,11 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl_segv= .c linux-2.6.32.49/grsecurity/gr + + return; +} -diff -urNp linux-2.6.32.49/grsecurity/gracl_shm.c linux-2.6.32.49/grsecu= rity/gracl_shm.c ---- linux-2.6.32.49/grsecurity/gracl_shm.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/gracl_shm.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/grsecurity/gracl_shm.c b/grsecurity/gracl_shm.c +new file mode 100644 +index 0000000..9d83a69 +--- /dev/null ++++ b/grsecurity/gracl_shm.c @@ -0,0 +1,40 @@ +#include +#include @@ -57971,9 +61101,11 @@ diff -urNp linux-2.6.32.49/grsecurity/gracl_shm.= c linux-2.6.32.49/grsecurity/gra + + return 1; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_chdir.c linux-2.6.32.49/grse= curity/grsec_chdir.c ---- linux-2.6.32.49/grsecurity/grsec_chdir.c 1969-12-31 19:00:00.0000000= 00 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_chdir.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/grsecurity/grsec_chdir.c b/grsecurity/grsec_chdir.c +new file mode 100644 +index 0000000..bc0be01 +--- /dev/null ++++ b/grsecurity/grsec_chdir.c @@ -0,0 +1,19 @@ +#include +#include @@ -57994,9 +61126,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_chdi= r.c linux-2.6.32.49/grsecurity/g +#endif + return; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_chroot.c linux-2.6.32.49/grs= ecurity/grsec_chroot.c ---- linux-2.6.32.49/grsecurity/grsec_chroot.c 1969-12-31 19:00:00.000000= 000 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_chroot.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/grsecurity/grsec_chroot.c b/grsecurity/grsec_chroot.c +new file mode 100644 +index 0000000..197bdd5 +--- /dev/null ++++ b/grsecurity/grsec_chroot.c @@ -0,0 +1,386 @@ +#include +#include @@ -58384,9 +61518,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_chro= ot.c linux-2.6.32.49/grsecurity/ +#endif + return 0; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_disabled.c linux-2.6.32.49/g= rsecurity/grsec_disabled.c ---- linux-2.6.32.49/grsecurity/grsec_disabled.c 1969-12-31 19:00:00.0000= 00000 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_disabled.c 2011-11-18 19:30:15.0000= 00000 -0500 +diff --git a/grsecurity/grsec_disabled.c b/grsecurity/grsec_disabled.c +new file mode 100644 +index 0000000..b81db5b +--- /dev/null ++++ b/grsecurity/grsec_disabled.c @@ -0,0 +1,439 @@ +#include +#include @@ -58827,9 +61963,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_disa= bled.c linux-2.6.32.49/grsecurit +EXPORT_SYMBOL(gr_check_user_change); +EXPORT_SYMBOL(gr_check_group_change); +#endif -diff -urNp linux-2.6.32.49/grsecurity/grsec_exec.c linux-2.6.32.49/grsec= urity/grsec_exec.c ---- linux-2.6.32.49/grsecurity/grsec_exec.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_exec.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/grsecurity/grsec_exec.c b/grsecurity/grsec_exec.c +new file mode 100644 +index 0000000..a96e155 +--- /dev/null ++++ b/grsecurity/grsec_exec.c @@ -0,0 +1,204 @@ +#include +#include @@ -59035,9 +62173,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_exec= .c linux-2.6.32.49/grsecurity/gr + +EXPORT_SYMBOL(gr_is_capable); +EXPORT_SYMBOL(gr_is_capable_nolog); -diff -urNp linux-2.6.32.49/grsecurity/grsec_fifo.c linux-2.6.32.49/grsec= urity/grsec_fifo.c ---- linux-2.6.32.49/grsecurity/grsec_fifo.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_fifo.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/grsecurity/grsec_fifo.c b/grsecurity/grsec_fifo.c +new file mode 100644 +index 0000000..d3ee748 +--- /dev/null ++++ b/grsecurity/grsec_fifo.c @@ -0,0 +1,24 @@ +#include +#include @@ -59063,9 +62203,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_fifo= .c linux-2.6.32.49/grsecurity/gr +#endif + return 0; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_fork.c linux-2.6.32.49/grsec= urity/grsec_fork.c ---- linux-2.6.32.49/grsecurity/grsec_fork.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_fork.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/grsecurity/grsec_fork.c b/grsecurity/grsec_fork.c +new file mode 100644 +index 0000000..8ca18bf +--- /dev/null ++++ b/grsecurity/grsec_fork.c @@ -0,0 +1,23 @@ +#include +#include @@ -59090,9 +62232,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_fork= .c linux-2.6.32.49/grsecurity/gr +#endif + return; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_init.c linux-2.6.32.49/grsec= urity/grsec_init.c ---- linux-2.6.32.49/grsecurity/grsec_init.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_init.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/grsecurity/grsec_init.c b/grsecurity/grsec_init.c +new file mode 100644 +index 0000000..f813c26 +--- /dev/null ++++ b/grsecurity/grsec_init.c @@ -0,0 +1,270 @@ +#include +#include @@ -59364,9 +62508,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_init= .c linux-2.6.32.49/grsecurity/gr + + return; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_link.c linux-2.6.32.49/grsec= urity/grsec_link.c ---- linux-2.6.32.49/grsecurity/grsec_link.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_link.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/grsecurity/grsec_link.c b/grsecurity/grsec_link.c +new file mode 100644 +index 0000000..3efe141 +--- /dev/null ++++ b/grsecurity/grsec_link.c @@ -0,0 +1,43 @@ +#include +#include @@ -59411,9 +62557,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_link= .c linux-2.6.32.49/grsecurity/gr +#endif + return 0; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_log.c linux-2.6.32.49/grsecu= rity/grsec_log.c ---- linux-2.6.32.49/grsecurity/grsec_log.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/grsec_log.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/grsecurity/grsec_log.c b/grsecurity/grsec_log.c +new file mode 100644 +index 0000000..a45d2e9 +--- /dev/null ++++ b/grsecurity/grsec_log.c @@ -0,0 +1,322 @@ +#include +#include @@ -59737,9 +62885,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_log.= c linux-2.6.32.49/grsecurity/grs + gr_log_end(audit, 1); + END_LOCKS(audit); +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_mem.c linux-2.6.32.49/grsecu= rity/grsec_mem.c ---- linux-2.6.32.49/grsecurity/grsec_mem.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/grsec_mem.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/grsecurity/grsec_mem.c b/grsecurity/grsec_mem.c +new file mode 100644 +index 0000000..6c0416b +--- /dev/null ++++ b/grsecurity/grsec_mem.c @@ -0,0 +1,33 @@ +#include +#include @@ -59774,9 +62924,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_mem.= c linux-2.6.32.49/grsecurity/grs + gr_log_noargs(GR_DONT_AUDIT, GR_VM86_MSG); + return; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_mount.c linux-2.6.32.49/grse= curity/grsec_mount.c ---- linux-2.6.32.49/grsecurity/grsec_mount.c 1969-12-31 19:00:00.0000000= 00 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_mount.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/grsecurity/grsec_mount.c b/grsecurity/grsec_mount.c +new file mode 100644 +index 0000000..2131422 +--- /dev/null ++++ b/grsecurity/grsec_mount.c @@ -0,0 +1,62 @@ +#include +#include @@ -59840,9 +62992,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_moun= t.c linux-2.6.32.49/grsecurity/g +#endif + return 0; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_pax.c linux-2.6.32.49/grsecu= rity/grsec_pax.c ---- linux-2.6.32.49/grsecurity/grsec_pax.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/grsec_pax.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/grsecurity/grsec_pax.c b/grsecurity/grsec_pax.c +new file mode 100644 +index 0000000..a3b12a0 +--- /dev/null ++++ b/grsecurity/grsec_pax.c @@ -0,0 +1,36 @@ +#include +#include @@ -59880,9 +63034,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_pax.= c linux-2.6.32.49/grsecurity/grs +#endif + return; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_ptrace.c linux-2.6.32.49/grs= ecurity/grsec_ptrace.c ---- linux-2.6.32.49/grsecurity/grsec_ptrace.c 1969-12-31 19:00:00.000000= 000 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_ptrace.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/grsecurity/grsec_ptrace.c b/grsecurity/grsec_ptrace.c +new file mode 100644 +index 0000000..472c1d6 +--- /dev/null ++++ b/grsecurity/grsec_ptrace.c @@ -0,0 +1,14 @@ +#include +#include @@ -59898,9 +63054,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_ptra= ce.c linux-2.6.32.49/grsecurity/ +#endif + return; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_sig.c linux-2.6.32.49/grsecu= rity/grsec_sig.c ---- linux-2.6.32.49/grsecurity/grsec_sig.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/grsec_sig.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/grsecurity/grsec_sig.c b/grsecurity/grsec_sig.c +new file mode 100644 +index 0000000..dc73fe9 +--- /dev/null ++++ b/grsecurity/grsec_sig.c @@ -0,0 +1,205 @@ +#include +#include @@ -60107,9 +63265,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_sig.= c linux-2.6.32.49/grsecurity/grs +#endif + return 0; +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_sock.c linux-2.6.32.49/grsec= urity/grsec_sock.c ---- linux-2.6.32.49/grsecurity/grsec_sock.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_sock.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/grsecurity/grsec_sock.c b/grsecurity/grsec_sock.c +new file mode 100644 +index 0000000..7512ea9 +--- /dev/null ++++ b/grsecurity/grsec_sock.c @@ -0,0 +1,275 @@ +#include +#include @@ -60386,9 +63546,11 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_sock= .c linux-2.6.32.49/grsecurity/gr + return current_cap(); +#endif +} -diff -urNp linux-2.6.32.49/grsecurity/grsec_sysctl.c linux-2.6.32.49/grs= ecurity/grsec_sysctl.c ---- linux-2.6.32.49/grsecurity/grsec_sysctl.c 1969-12-31 19:00:00.000000= 000 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_sysctl.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/grsecurity/grsec_sysctl.c b/grsecurity/grsec_sysctl.c +new file mode 100644 +index 0000000..2753505 +--- /dev/null ++++ b/grsecurity/grsec_sysctl.c @@ -0,0 +1,479 @@ +#include +#include @@ -60669,1417 +63831,344 @@ diff -urNp linux-2.6.32.49/grsecurity/grsec_= sysctl.c linux-2.6.32.49/grsecurity/ + .procname =3D "tpe_gid", + .data =3D &grsec_tpe_gid, + .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_TPE_INVERT -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "tpe_invert", -+ .data =3D &grsec_enable_tpe_invert, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_TPE_ALL -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "tpe_restrict_all", -+ .data =3D &grsec_enable_tpe_all, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_SOCKET_ALL -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "socket_all", -+ .data =3D &grsec_enable_socket_all, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "socket_all_gid", -+ .data =3D &grsec_socket_all_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_SOCKET_CLIENT -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "socket_client", -+ .data =3D &grsec_enable_socket_client, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "socket_client_gid", -+ .data =3D &grsec_socket_client_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_SOCKET_SERVER -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "socket_server", -+ .data =3D &grsec_enable_socket_server, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "socket_server_gid", -+ .data =3D &grsec_socket_server_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_GROUP -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "audit_group", -+ .data =3D &grsec_enable_group, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "audit_gid", -+ .data =3D &grsec_audit_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_CHDIR -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "audit_chdir", -+ .data =3D &grsec_enable_chdir, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_MOUNT -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "audit_mount", -+ .data =3D &grsec_enable_mount, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_TEXTREL -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "audit_textrel", -+ .data =3D &grsec_enable_audit_textrel, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_DMESG -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "dmesg", -+ .data =3D &grsec_enable_dmesg, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_FINDTASK -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "chroot_findtask", -+ .data =3D &grsec_enable_chroot_findtask, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_RESLOG -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "resource_logging", -+ .data =3D &grsec_resource_logging, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_PTRACE -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "audit_ptrace", -+ .data =3D &grsec_enable_audit_ptrace, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_HARDEN_PTRACE -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "harden_ptrace", -+ .data =3D &grsec_enable_harden_ptrace, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "grsec_lock", -+ .data =3D &grsec_lock, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_ROFS -+ { -+ .ctl_name =3D CTL_UNNUMBERED, -+ .procname =3D "romount_protect", -+ .data =3D &grsec_enable_rofs, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec_minmax, -+ .extra1 =3D &one, -+ .extra2 =3D &one, -+ }, -+#endif -+ { .ctl_name =3D 0 } -+}; -+#endif -diff -urNp linux-2.6.32.49/grsecurity/grsec_time.c linux-2.6.32.49/grsec= urity/grsec_time.c ---- linux-2.6.32.49/grsecurity/grsec_time.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/grsecurity/grsec_time.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -0,0 +1,16 @@ -+#include -+#include -+#include -+#include -+ -+void -+gr_log_timechange(void) -+{ -+#ifdef CONFIG_GRKERNSEC_TIME -+ if (grsec_enable_time) -+ gr_log_noargs(GR_DONT_AUDIT_GOOD, GR_TIME_MSG); -+#endif -+ return; -+} -+ -+EXPORT_SYMBOL(gr_log_timechange); -diff -urNp linux-2.6.32.49/grsecurity/grsec_tpe.c linux-2.6.32.49/grsecu= rity/grsec_tpe.c ---- linux-2.6.32.49/grsecurity/grsec_tpe.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/grsecurity/grsec_tpe.c 2011-11-15 19:59:43.000000000= -0500 -@@ -0,0 +1,39 @@ -+#include -+#include -+#include -+#include -+#include -+ -+extern int gr_acl_tpe_check(void); -+ -+int -+gr_tpe_allow(const struct file *file) -+{ -+#ifdef CONFIG_GRKERNSEC -+ struct inode *inode =3D file->f_path.dentry->d_parent->d_inode; -+ const struct cred *cred =3D current_cred(); -+ -+ if (cred->uid && ((grsec_enable_tpe && -+#ifdef CONFIG_GRKERNSEC_TPE_INVERT -+ ((grsec_enable_tpe_invert && !in_group_p(grsec_tpe_gid)) || -+ (!grsec_enable_tpe_invert && in_group_p(grsec_tpe_gid))) -+#else -+ in_group_p(grsec_tpe_gid) -+#endif -+ ) || gr_acl_tpe_check()) && -+ (inode->i_uid || (!inode->i_uid && ((inode->i_mode & S_IWGRP) || -+ (inode->i_mode & S_IWOTH))))) { -+ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); -+ return 0; -+ } -+#ifdef CONFIG_GRKERNSEC_TPE_ALL -+ if (cred->uid && grsec_enable_tpe && grsec_enable_tpe_all && -+ ((inode->i_uid && (inode->i_uid !=3D cred->uid)) || -+ (inode->i_mode & S_IWGRP) || (inode->i_mode & S_IWOTH))) { -+ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); -+ return 0; -+ } -+#endif -+#endif -+ return 1; -+} -diff -urNp linux-2.6.32.49/grsecurity/grsum.c linux-2.6.32.49/grsecurity= /grsum.c ---- linux-2.6.32.49/grsecurity/grsum.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-2.6.32.49/grsecurity/grsum.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -0,0 +1,61 @@ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+ -+#if !defined(CONFIG_CRYPTO) || defined(CONFIG_CRYPTO_MODULE) || !define= d(CONFIG_CRYPTO_SHA256) || defined(CONFIG_CRYPTO_SHA256_MODULE) -+#error "crypto and sha256 must be built into the kernel" -+#endif -+ -+int -+chkpw(struct gr_arg *entry, unsigned char *salt, unsigned char *sum) -+{ -+ char *p; -+ struct crypto_hash *tfm; -+ struct hash_desc desc; -+ struct scatterlist sg; -+ unsigned char temp_sum[GR_SHA_LEN]; -+ volatile int retval =3D 0; -+ volatile int dummy =3D 0; -+ unsigned int i; -+ -+ sg_init_table(&sg, 1); -+ -+ tfm =3D crypto_alloc_hash("sha256", 0, CRYPTO_ALG_ASYNC); -+ if (IS_ERR(tfm)) { -+ /* should never happen, since sha256 should be built in */ -+ return 1; -+ } -+ -+ desc.tfm =3D tfm; -+ desc.flags =3D 0; -+ -+ crypto_hash_init(&desc); -+ -+ p =3D salt; -+ sg_set_buf(&sg, p, GR_SALT_LEN); -+ crypto_hash_update(&desc, &sg, sg.length); -+ -+ p =3D entry->pw; -+ sg_set_buf(&sg, p, strlen(p)); -+=09 -+ crypto_hash_update(&desc, &sg, sg.length); -+ -+ crypto_hash_final(&desc, temp_sum); -+ -+ memset(entry->pw, 0, GR_PW_LEN); -+ -+ for (i =3D 0; i < GR_SHA_LEN; i++) -+ if (sum[i] !=3D temp_sum[i]) -+ retval =3D 1; -+ else -+ dummy =3D 1; // waste a cycle -+ -+ crypto_free_hash(tfm); -+ -+ return retval; -+} -diff -urNp linux-2.6.32.49/grsecurity/Kconfig linux-2.6.32.49/grsecurity= /Kconfig ---- linux-2.6.32.49/grsecurity/Kconfig 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-2.6.32.49/grsecurity/Kconfig 2011-11-15 19:59:43.000000000 -05= 00 -@@ -0,0 +1,1036 @@ -+# -+# grecurity configuration -+# -+ -+menu "Grsecurity" -+ -+config GRKERNSEC -+ bool "Grsecurity" -+ select CRYPTO -+ select CRYPTO_SHA256 -+ help -+ If you say Y here, you will be able to configure many features -+ that will enhance the security of your system. It is highly -+ recommended that you say Y here and read through the help -+ for each option so that you fully understand the features and -+ can evaluate their usefulness for your machine. -+ -+choice -+ prompt "Security Level" -+ depends on GRKERNSEC -+ default GRKERNSEC_CUSTOM -+ -+config GRKERNSEC_LOW -+ bool "Low" -+ select GRKERNSEC_LINK -+ select GRKERNSEC_FIFO -+ select GRKERNSEC_RANDNET -+ select GRKERNSEC_DMESG -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_CHDIR -+ -+ help -+ If you choose this option, several of the grsecurity options will -+ be enabled that will give you greater protection against a number -+ of attacks, while assuring that none of your software will have any -+ conflicts with the additional security measures. If you run a lot -+ of unusual software, or you are having problems with the higher -+ security levels, you should say Y here. With this option, the -+ following features are enabled: -+ -+ - Linking restrictions -+ - FIFO restrictions -+ - Restricted dmesg -+ - Enforced chdir("/") on chroot -+ - Runtime module disabling -+ -+config GRKERNSEC_MEDIUM -+ bool "Medium" -+ select PAX -+ select PAX_EI_PAX -+ select PAX_PT_PAX_FLAGS -+ select PAX_HAVE_ACL_FLAGS -+ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_SYSCTL -+ select GRKERNSEC_LINK -+ select GRKERNSEC_FIFO -+ select GRKERNSEC_DMESG -+ select GRKERNSEC_RANDNET -+ select GRKERNSEC_FORKFAIL -+ select GRKERNSEC_TIME -+ select GRKERNSEC_SIGNAL -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_UNIX -+ select GRKERNSEC_CHROOT_MOUNT -+ select GRKERNSEC_CHROOT_PIVOT -+ select GRKERNSEC_CHROOT_DOUBLE -+ select GRKERNSEC_CHROOT_CHDIR -+ select GRKERNSEC_CHROOT_MKNOD -+ select GRKERNSEC_PROC -+ select GRKERNSEC_PROC_USERGROUP -+ select PAX_RANDUSTACK -+ select PAX_ASLR -+ select PAX_RANDMMAP -+ select PAX_REFCOUNT if (X86 || SPARC64) -+ select PAX_USERCOPY if ((X86 || SPARC || PPC || ARM) && (SLAB || SLUB = || SLOB)) -+ -+ help -+ If you say Y here, several features in addition to those included -+ in the low additional security level will be enabled. These -+ features provide even more security to your system, though in rare -+ cases they may be incompatible with very old or poorly written -+ software. If you enable this option, make sure that your auth -+ service (identd) is running as gid 1001. With this option,=20 -+ the following features (in addition to those provided in the=20 -+ low additional security level) will be enabled: -+ -+ - Failed fork logging -+ - Time change logging -+ - Signal logging -+ - Deny mounts in chroot -+ - Deny double chrooting -+ - Deny sysctl writes in chroot -+ - Deny mknod in chroot -+ - Deny access to abstract AF_UNIX sockets out of chroot -+ - Deny pivot_root in chroot -+ - Denied reads/writes of /dev/kmem, /dev/mem, and /dev/port -+ - /proc restrictions with special GID set to 10 (usually wheel) -+ - Address Space Layout Randomization (ASLR) -+ - Prevent exploitation of most refcount overflows -+ - Bounds checking of copying between the kernel and userland -+ -+config GRKERNSEC_HIGH -+ bool "High" -+ select GRKERNSEC_LINK -+ select GRKERNSEC_FIFO -+ select GRKERNSEC_DMESG -+ select GRKERNSEC_FORKFAIL -+ select GRKERNSEC_TIME -+ select GRKERNSEC_SIGNAL -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_SHMAT -+ select GRKERNSEC_CHROOT_UNIX -+ select GRKERNSEC_CHROOT_MOUNT -+ select GRKERNSEC_CHROOT_FCHDIR -+ select GRKERNSEC_CHROOT_PIVOT -+ select GRKERNSEC_CHROOT_DOUBLE -+ select GRKERNSEC_CHROOT_CHDIR -+ select GRKERNSEC_CHROOT_MKNOD -+ select GRKERNSEC_CHROOT_CAPS -+ select GRKERNSEC_CHROOT_SYSCTL -+ select GRKERNSEC_CHROOT_FINDTASK -+ select GRKERNSEC_SYSFS_RESTRICT -+ select GRKERNSEC_PROC -+ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) -+ select GRKERNSEC_HIDESYM -+ select GRKERNSEC_BRUTE -+ select GRKERNSEC_PROC_USERGROUP -+ select GRKERNSEC_KMEM -+ select GRKERNSEC_RESLOG -+ select GRKERNSEC_RANDNET -+ select GRKERNSEC_PROC_ADD -+ select GRKERNSEC_CHROOT_CHMOD -+ select GRKERNSEC_CHROOT_NICE -+ select GRKERNSEC_AUDIT_MOUNT -+ select GRKERNSEC_MODHARDEN if (MODULES) -+ select GRKERNSEC_HARDEN_PTRACE -+ select GRKERNSEC_VM86 if (X86_32) -+ select GRKERNSEC_KERN_LOCKOUT if (X86 || ARM || PPC || SPARC) -+ select PAX -+ select PAX_RANDUSTACK -+ select PAX_ASLR -+ select PAX_RANDMMAP -+ select PAX_NOEXEC -+ select PAX_MPROTECT -+ select PAX_EI_PAX -+ select PAX_PT_PAX_FLAGS -+ select PAX_HAVE_ACL_FLAGS -+ select PAX_KERNEXEC if ((PPC || X86) && (!X86_32 || X86_WP_WORKS_OK) &= & !XEN) -+ select PAX_MEMORY_UDEREF if (X86 && !XEN) -+ select PAX_RANDKSTACK if (X86_TSC && X86) -+ select PAX_SEGMEXEC if (X86_32) -+ select PAX_PAGEEXEC -+ select PAX_EMUPLT if (ALPHA || PARISC || SPARC) -+ select PAX_EMUTRAMP if (PARISC) -+ select PAX_EMUSIGRT if (PARISC) -+ select PAX_ETEXECRELOCS if (ALPHA || IA64 || PARISC) -+ select PAX_ELFRELOCS if (PAX_ETEXECRELOCS || (IA64 || PPC || X86)) -+ select PAX_REFCOUNT if (X86 || SPARC64) -+ select PAX_USERCOPY if ((X86 || SPARC || PPC || ARM) && (SLAB || SLUB = || SLOB)) -+ help -+ If you say Y here, many of the features of grsecurity will be -+ enabled, which will protect you against many kinds of attacks -+ against your system. The heightened security comes at a cost -+ of an increased chance of incompatibilities with rare software -+ on your machine. Since this security level enables PaX, you should -+ view and read about the PaX -+ project. While you are there, download chpax and run it on -+ binaries that cause problems with PaX. Also remember that -+ since the /proc restrictions are enabled, you must run your -+ identd as gid 1001. This security level enables the following=20 -+ features in addition to those listed in the low and medium=20 -+ security levels: -+ -+ - Additional /proc restrictions -+ - Chmod restrictions in chroot -+ - No signals, ptrace, or viewing of processes outside of chroot -+ - Capability restrictions in chroot -+ - Deny fchdir out of chroot -+ - Priority restrictions in chroot -+ - Segmentation-based implementation of PaX -+ - Mprotect restrictions -+ - Removal of addresses from /proc//[smaps|maps|stat] -+ - Kernel stack randomization -+ - Mount/unmount/remount logging -+ - Kernel symbol hiding -+ - Hardening of module auto-loading -+ - Ptrace restrictions -+ - Restricted vm86 mode -+ - Restricted sysfs/debugfs -+ - Active kernel exploit response -+ -+config GRKERNSEC_CUSTOM -+ bool "Custom" -+ help -+ If you say Y here, you will be able to configure every grsecurity -+ option, which allows you to enable many more features that aren't -+ covered in the basic security levels. These additional features -+ include TPE, socket restrictions, and the sysctl system for -+ grsecurity. It is advised that you read through the help for -+ each option to determine its usefulness in your situation. -+ -+endchoice -+ -+menu "Address Space Protection" -+depends on GRKERNSEC -+ -+config GRKERNSEC_KMEM -+ bool "Deny reading/writing to /dev/kmem, /dev/mem, and /dev/port" -+ select STRICT_DEVMEM if (X86 || ARM || TILE || S390) -+ help -+ If you say Y here, /dev/kmem and /dev/mem won't be allowed to -+ be written to or read from to modify or leak the contents of the run= ning -+ kernel. /dev/port will also not be allowed to be opened. If you hav= e module -+ support disabled, enabling this will close up four ways that are -+ currently used to insert malicious code into the running kernel. -+ Even with all these features enabled, we still highly recommend that -+ you use the RBAC system, as it is still possible for an attacker to -+ modify the running kernel through privileged I/O granted by ioperm/i= opl. -+ If you are not using XFree86, you may be able to stop this additiona= l -+ case by enabling the 'Disable privileged I/O' option. Though nothing -+ legitimately writes to /dev/kmem, XFree86 does need to write to /dev= /mem, -+ but only to video memory, which is the only writing we allow in this -+ case. If /dev/kmem or /dev/mem are mmaped without PROT_WRITE, they = will -+ not be allowed to mprotect it with PROT_WRITE later. -+ It is highly recommended that you say Y here if you meet all the -+ conditions above. -+ -+config GRKERNSEC_VM86 -+ bool "Restrict VM86 mode" -+ depends on X86_32 -+ -+ help -+ If you say Y here, only processes with CAP_SYS_RAWIO will be able to -+ make use of a special execution mode on 32bit x86 processors called -+ Virtual 8086 (VM86) mode. XFree86 may need vm86 mode for certain -+ video cards and will still work with this option enabled. The purpo= se -+ of the option is to prevent exploitation of emulation errors in -+ virtualization of vm86 mode like the one discovered in VMWare in 200= 9. -+ Nearly all users should be able to enable this option. -+ -+config GRKERNSEC_IO -+ bool "Disable privileged I/O" -+ depends on X86 -+ select RTC_CLASS -+ select RTC_INTF_DEV -+ select RTC_DRV_CMOS -+ -+ help -+ If you say Y here, all ioperm and iopl calls will return an error. -+ Ioperm and iopl can be used to modify the running kernel. -+ Unfortunately, some programs need this access to operate properly, -+ the most notable of which are XFree86 and hwclock. hwclock can be -+ remedied by having RTC support in the kernel, so real-time=20 -+ clock support is enabled if this option is enabled, to ensure=20 -+ that hwclock operates correctly. XFree86 still will not=20 -+ operate correctly with this option enabled, so DO NOT CHOOSE Y=20 -+ IF YOU USE XFree86. If you use XFree86 and you still want to=20 -+ protect your kernel against modification, use the RBAC system. -+ -+config GRKERNSEC_PROC_MEMMAP -+ bool "Remove addresses from /proc//[smaps|maps|stat]" -+ default y if (PAX_NOEXEC || PAX_ASLR) -+ depends on PAX_NOEXEC || PAX_ASLR -+ help -+ If you say Y here, the /proc//maps and /proc//stat files w= ill -+ give no information about the addresses of its mappings if -+ PaX features that rely on random addresses are enabled on the task. -+ If you use PaX it is greatly recommended that you say Y here as it -+ closes up a hole that makes the full ASLR useless for suid -+ binaries. -+ -+config GRKERNSEC_BRUTE -+ bool "Deter exploit bruteforcing" -+ help -+ If you say Y here, attempts to bruteforce exploits against forking -+ daemons such as apache or sshd, as well as against suid/sgid binarie= s -+ will be deterred. When a child of a forking daemon is killed by PaX -+ or crashes due to an illegal instruction or other suspicious signal, -+ the parent process will be delayed 30 seconds upon every subsequent -+ fork until the administrator is able to assess the situation and -+ restart the daemon. -+ In the suid/sgid case, the attempt is logged, the user has all their -+ processes terminated, and they are prevented from executing any furt= her -+ processes for 15 minutes. -+ It is recommended that you also enable signal logging in the auditin= g -+ section so that logs are generated when a process triggers a suspici= ous -+ signal. -+ If the sysctl option is enabled, a sysctl option with name -+ "deter_bruteforce" is created. -+ -+config GRKERNSEC_MODHARDEN -+ bool "Harden module auto-loading" -+ depends on MODULES -+ help -+ If you say Y here, module auto-loading in response to use of some -+ feature implemented by an unloaded module will be restricted to -+ root users. Enabling this option helps defend against attacks=20 -+ by unprivileged users who abuse the auto-loading behavior to=20 -+ cause a vulnerable module to load that is then exploited. -+ -+ If this option prevents a legitimate use of auto-loading for a=20 -+ non-root user, the administrator can execute modprobe manually=20 -+ with the exact name of the module mentioned in the alert log. -+ Alternatively, the administrator can add the module to the list -+ of modules loaded at boot by modifying init scripts. -+ -+ Modification of init scripts will most likely be needed on=20 -+ Ubuntu servers with encrypted home directory support enabled, -+ as the first non-root user logging in will cause the ecb(aes), -+ ecb(aes)-all, cbc(aes), and cbc(aes)-all modules to be loaded. -+ -+config GRKERNSEC_HIDESYM -+ bool "Hide kernel symbols" -+ help -+ If you say Y here, getting information on loaded modules, and -+ displaying all kernel symbols through a syscall will be restricted -+ to users with CAP_SYS_MODULE. For software compatibility reasons, -+ /proc/kallsyms will be restricted to the root user. The RBAC -+ system can hide that entry even from root. -+ -+ This option also prevents leaking of kernel addresses through -+ several /proc entries. -+ -+ Note that this option is only effective provided the following -+ conditions are met: -+ 1) The kernel using grsecurity is not precompiled by some distributi= on -+ 2) You have also enabled GRKERNSEC_DMESG -+ 3) You are using the RBAC system and hiding other files such as your -+ kernel image and System.map. Alternatively, enabling this option -+ causes the permissions on /boot, /lib/modules, and the kernel -+ source directory to change at compile time to prevent=20 -+ reading by non-root users. -+ If the above conditions are met, this option will aid in providing a -+ useful protection against local kernel exploitation of overflows -+ and arbitrary read/write vulnerabilities. -+ -+config GRKERNSEC_KERN_LOCKOUT -+ bool "Active kernel exploit response" -+ depends on X86 || ARM || PPC || SPARC -+ help -+ If you say Y here, when a PaX alert is triggered due to suspicious -+ activity in the kernel (from KERNEXEC/UDEREF/USERCOPY) -+ or an OOPs occurs due to bad memory accesses, instead of just -+ terminating the offending process (and potentially allowing -+ a subsequent exploit from the same user), we will take one of two -+ actions: -+ If the user was root, we will panic the system -+ If the user was non-root, we will log the attempt, terminate -+ all processes owned by the user, then prevent them from creating -+ any new processes until the system is restarted -+ This deters repeated kernel exploitation/bruteforcing attempts -+ and is useful for later forensics. -+ -+endmenu -+menu "Role Based Access Control Options" -+depends on GRKERNSEC -+ -+config GRKERNSEC_RBAC_DEBUG -+ bool -+ -+config GRKERNSEC_NO_RBAC -+ bool "Disable RBAC system" -+ help -+ If you say Y here, the /dev/grsec device will be removed from the ke= rnel, -+ preventing the RBAC system from being enabled. You should only say = Y -+ here if you have no intention of using the RBAC system, so as to pre= vent -+ an attacker with root access from misusing the RBAC system to hide f= iles -+ and processes when loadable module support and /dev/[k]mem have been -+ locked down. -+ -+config GRKERNSEC_ACL_HIDEKERN -+ bool "Hide kernel processes" -+ help -+ If you say Y here, all kernel threads will be hidden to all -+ processes but those whose subject has the "view hidden processes" -+ flag. -+ -+config GRKERNSEC_ACL_MAXTRIES -+ int "Maximum tries before password lockout" -+ default 3 -+ help -+ This option enforces the maximum number of times a user can attempt -+ to authorize themselves with the grsecurity RBAC system before being -+ denied the ability to attempt authorization again for a specified ti= me. -+ The lower the number, the harder it will be to brute-force a passwor= d. -+ -+config GRKERNSEC_ACL_TIMEOUT -+ int "Time to wait after max password tries, in seconds" -+ default 30 -+ help -+ This option specifies the time the user must wait after attempting t= o -+ authorize to the RBAC system with the maximum number of invalid -+ passwords. The higher the number, the harder it will be to brute-fo= rce -+ a password. -+ -+endmenu -+menu "Filesystem Protections" -+depends on GRKERNSEC -+ -+config GRKERNSEC_PROC -+ bool "Proc restrictions" -+ help -+ If you say Y here, the permissions of the /proc filesystem -+ will be altered to enhance system security and privacy. You MUST -+ choose either a user only restriction or a user and group restrict= ion. -+ Depending upon the option you choose, you can either restrict users = to -+ see only the processes they themselves run, or choose a group that c= an -+ view all processes and files normally restricted to root if you choo= se -+ the "restrict to user only" option. NOTE: If you're running identd = as -+ a non-root user, you will have to run it as the group you specify he= re. -+ -+config GRKERNSEC_PROC_USER -+ bool "Restrict /proc to user only" -+ depends on GRKERNSEC_PROC -+ help -+ If you say Y here, non-root users will only be able to view their ow= n -+ processes, and restricts them from viewing network-related informati= on, -+ and viewing kernel symbol and module information. -+ -+config GRKERNSEC_PROC_USERGROUP -+ bool "Allow special group" -+ depends on GRKERNSEC_PROC && !GRKERNSEC_PROC_USER -+ help -+ If you say Y here, you will be able to select a group that will be -+ able to view all processes and network-related information. If you'= ve -+ enabled GRKERNSEC_HIDESYM, kernel and symbol information may still -+ remain hidden. This option is useful if you want to run identd as -+ a non-root user. -+ -+config GRKERNSEC_PROC_GID -+ int "GID for special group" -+ depends on GRKERNSEC_PROC_USERGROUP -+ default 1001 -+ -+config GRKERNSEC_PROC_ADD -+ bool "Additional restrictions" -+ depends on GRKERNSEC_PROC_USER || GRKERNSEC_PROC_USERGROUP -+ help -+ If you say Y here, additional restrictions will be placed on -+ /proc that keep normal users from viewing device information and=20 -+ slabinfo information that could be useful for exploits. -+ -+config GRKERNSEC_LINK -+ bool "Linking restrictions" -+ help -+ If you say Y here, /tmp race exploits will be prevented, since users -+ will no longer be able to follow symlinks owned by other users in -+ world-writable +t directories (e.g. /tmp), unless the owner of the -+ symlink is the owner of the directory. users will also not be -+ able to hardlink to files they do not own. If the sysctl option is -+ enabled, a sysctl option with name "linking_restrictions" is created= . -+ -+config GRKERNSEC_FIFO -+ bool "FIFO restrictions" -+ help -+ If you say Y here, users will not be able to write to FIFOs they don= 't -+ own in world-writable +t directories (e.g. /tmp), unless the owner o= f -+ the FIFO is the same owner of the directory it's held in. If the sy= sctl -+ option is enabled, a sysctl option with name "fifo_restrictions" is -+ created. -+ -+config GRKERNSEC_SYSFS_RESTRICT -+ bool "Sysfs/debugfs restriction" -+ depends on SYSFS -+ help -+ If you say Y here, sysfs (the pseudo-filesystem mounted at /sys) and -+ any filesystem normally mounted under it (e.g. debugfs) will only -+ be accessible by root. These filesystems generally provide access -+ to hardware and debug information that isn't appropriate for unprivi= leged -+ users of the system. Sysfs and debugfs have also become a large sou= rce -+ of new vulnerabilities, ranging from infoleaks to local compromise. -+ There has been very little oversight with an eye toward security inv= olved -+ in adding new exporters of information to these filesystems, so thei= r -+ use is discouraged. -+ This option is equivalent to a chmod 0700 of the mount paths. -+ -+config GRKERNSEC_ROFS -+ bool "Runtime read-only mount protection" -+ help -+ If you say Y here, a sysctl option with name "romount_protect" will -+ be created. By setting this option to 1 at runtime, filesystems -+ will be protected in the following ways: -+ * No new writable mounts will be allowed -+ * Existing read-only mounts won't be able to be remounted read/write -+ * Write operations will be denied on all block devices -+ This option acts independently of grsec_lock: once it is set to 1, -+ it cannot be turned off. Therefore, please be mindful of the result= ing -+ behavior if this option is enabled in an init script on a read-only -+ filesystem. This feature is mainly intended for secure embedded sys= tems. -+ -+config GRKERNSEC_CHROOT -+ bool "Chroot jail restrictions" -+ help -+ If you say Y here, you will be able to choose several options that w= ill -+ make breaking out of a chrooted jail much more difficult. If you -+ encounter no software incompatibilities with the following options, = it -+ is recommended that you enable each one. -+ -+config GRKERNSEC_CHROOT_MOUNT -+ bool "Deny mounts" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to -+ mount or remount filesystems. If the sysctl option is enabled, a -+ sysctl option with name "chroot_deny_mount" is created. -+ -+config GRKERNSEC_CHROOT_DOUBLE -+ bool "Deny double-chroots" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to chr= oot -+ again outside the chroot. This is a widely used method of breaking -+ out of a chroot jail and should not be allowed. If the sysctl=20 -+ option is enabled, a sysctl option with name=20 -+ "chroot_deny_chroot" is created. -+ -+config GRKERNSEC_CHROOT_PIVOT -+ bool "Deny pivot_root in chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to use -+ a function called pivot_root() that was introduced in Linux 2.3.41. = It -+ works similar to chroot in that it changes the root filesystem. Thi= s -+ function could be misused in a chrooted process to attempt to break = out -+ of the chroot, and therefore should not be allowed. If the sysctl -+ option is enabled, a sysctl option with name "chroot_deny_pivot" is -+ created. -+ -+config GRKERNSEC_CHROOT_CHDIR -+ bool "Enforce chdir(\"/\") on all chroots" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, the current working directory of all newly-chroot= ed -+ applications will be set to the the root directory of the chroot. -+ The man page on chroot(2) states: -+ Note that this call does not change the current working -+ directory, so that `.' can be outside the tree rooted at -+ `/'. In particular, the super-user can escape from a -+ `chroot jail' by doing `mkdir foo; chroot foo; cd ..'. -+ -+ It is recommended that you say Y here, since it's not known to break -+ any software. If the sysctl option is enabled, a sysctl option with -+ name "chroot_enforce_chdir" is created. -+ -+config GRKERNSEC_CHROOT_CHMOD -+ bool "Deny (f)chmod +s" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to chm= od -+ or fchmod files to make them have suid or sgid bits. This protects -+ against another published method of breaking a chroot. If the sysct= l -+ option is enabled, a sysctl option with name "chroot_deny_chmod" is -+ created. -+ -+config GRKERNSEC_CHROOT_FCHDIR -+ bool "Deny fchdir out of chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, a well-known method of breaking chroots by fchdir= 'ing -+ to a file descriptor of the chrooting process that points to a direc= tory -+ outside the filesystem will be stopped. If the sysctl option -+ is enabled, a sysctl option with name "chroot_deny_fchdir" is create= d. -+ -+config GRKERNSEC_CHROOT_MKNOD -+ bool "Deny mknod" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be allowed to -+ mknod. The problem with using mknod inside a chroot is that it -+ would allow an attacker to create a device entry that is the same -+ as one on the physical root of your system, which could range from -+ anything from the console device to a device for your harddrive (whi= ch -+ they could then use to wipe the drive or steal data). It is recomme= nded -+ that you say Y here, unless you run into software incompatibilities. -+ If the sysctl option is enabled, a sysctl option with name -+ "chroot_deny_mknod" is created. -+ -+config GRKERNSEC_CHROOT_SHMAT -+ bool "Deny shmat() out of chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to att= ach -+ to shared memory segments that were created outside of the chroot ja= il. -+ It is recommended that you say Y here. If the sysctl option is enab= led, -+ a sysctl option with name "chroot_deny_shmat" is created. -+ -+config GRKERNSEC_CHROOT_UNIX -+ bool "Deny access to abstract AF_UNIX sockets out of chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to -+ connect to abstract (meaning not belonging to a filesystem) Unix -+ domain sockets that were bound outside of a chroot. It is recommend= ed -+ that you say Y here. If the sysctl option is enabled, a sysctl opti= on -+ with name "chroot_deny_unix" is created. -+ -+config GRKERNSEC_CHROOT_FINDTASK -+ bool "Protect outside processes" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to -+ kill, send signals with fcntl, ptrace, capget, getpgid, setpgid,=20 -+ getsid, or view any process outside of the chroot. If the sysctl -+ option is enabled, a sysctl option with name "chroot_findtask" is -+ created. -+ -+config GRKERNSEC_CHROOT_NICE -+ bool "Restrict priority changes" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to rai= se -+ the priority of processes in the chroot, or alter the priority of -+ processes outside the chroot. This provides more security than simp= ly -+ removing CAP_SYS_NICE from the process' capability set. If the -+ sysctl option is enabled, a sysctl option with name "chroot_restrict= _nice" -+ is created. -+ -+config GRKERNSEC_CHROOT_SYSCTL -+ bool "Deny sysctl writes" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, an attacker in a chroot will not be able to -+ write to sysctl entries, either by sysctl(2) or through a /proc -+ interface. It is strongly recommended that you say Y here. If the -+ sysctl option is enabled, a sysctl option with name -+ "chroot_deny_sysctl" is created. -+ -+config GRKERNSEC_CHROOT_CAPS -+ bool "Capability restrictions" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, the capabilities on all processes within a -+ chroot jail will be lowered to stop module insertion, raw i/o, -+ system and net admin tasks, rebooting the system, modifying immutabl= e -+ files, modifying IPC owned by another, and changing the system time. -+ This is left an option because it can break some apps. Disable this -+ if your chrooted apps are having problems performing those kinds of -+ tasks. If the sysctl option is enabled, a sysctl option with -+ name "chroot_caps" is created. -+ -+endmenu -+menu "Kernel Auditing" -+depends on GRKERNSEC -+ -+config GRKERNSEC_AUDIT_GROUP -+ bool "Single group for auditing" -+ help -+ If you say Y here, the exec, chdir, and (un)mount logging features -+ will only operate on a group you specify. This option is recommende= d -+ if you only want to watch certain users instead of having a large -+ amount of logs from the entire system. If the sysctl option is enab= led, -+ a sysctl option with name "audit_group" is created. -+ -+config GRKERNSEC_AUDIT_GID -+ int "GID for auditing" -+ depends on GRKERNSEC_AUDIT_GROUP -+ default 1007 -+ -+config GRKERNSEC_EXECLOG -+ bool "Exec logging" -+ help -+ If you say Y here, all execve() calls will be logged (since the -+ other exec*() calls are frontends to execve(), all execution -+ will be logged). Useful for shell-servers that like to keep track -+ of their users. If the sysctl option is enabled, a sysctl option wi= th -+ name "exec_logging" is created. -+ WARNING: This option when enabled will produce a LOT of logs, especi= ally -+ on an active system. -+ -+config GRKERNSEC_RESLOG -+ bool "Resource logging" -+ help -+ If you say Y here, all attempts to overstep resource limits will -+ be logged with the resource name, the requested size, and the curren= t -+ limit. It is highly recommended that you say Y here. If the sysctl -+ option is enabled, a sysctl option with name "resource_logging" is -+ created. If the RBAC system is enabled, the sysctl value is ignored= . -+ -+config GRKERNSEC_CHROOT_EXECLOG -+ bool "Log execs within chroot" -+ help -+ If you say Y here, all executions inside a chroot jail will be logge= d -+ to syslog. This can cause a large amount of logs if certain -+ applications (eg. djb's daemontools) are installed on the system, an= d -+ is therefore left as an option. If the sysctl option is enabled, a -+ sysctl option with name "chroot_execlog" is created. -+ -+config GRKERNSEC_AUDIT_PTRACE -+ bool "Ptrace logging" -+ help -+ If you say Y here, all attempts to attach to a process via ptrace -+ will be logged. If the sysctl option is enabled, a sysctl option -+ with name "audit_ptrace" is created. -+ -+config GRKERNSEC_AUDIT_CHDIR -+ bool "Chdir logging" -+ help -+ If you say Y here, all chdir() calls will be logged. If the sysctl -+ option is enabled, a sysctl option with name "audit_chdir" is creat= ed. -+ -+config GRKERNSEC_AUDIT_MOUNT -+ bool "(Un)Mount logging" -+ help -+ If you say Y here, all mounts and unmounts will be logged. If the -+ sysctl option is enabled, a sysctl option with name "audit_mount" is -+ created. -+ -+config GRKERNSEC_SIGNAL -+ bool "Signal logging" -+ help -+ If you say Y here, certain important signals will be logged, such as -+ SIGSEGV, which will as a result inform you of when a error in a prog= ram -+ occurred, which in some cases could mean a possible exploit attempt. -+ If the sysctl option is enabled, a sysctl option with name -+ "signal_logging" is created. -+ -+config GRKERNSEC_FORKFAIL -+ bool "Fork failure logging" -+ help -+ If you say Y here, all failed fork() attempts will be logged. -+ This could suggest a fork bomb, or someone attempting to overstep -+ their process limit. If the sysctl option is enabled, a sysctl opti= on -+ with name "forkfail_logging" is created. -+ -+config GRKERNSEC_TIME -+ bool "Time change logging" -+ help -+ If you say Y here, any changes of the system clock will be logged. -+ If the sysctl option is enabled, a sysctl option with name -+ "timechange_logging" is created. -+ -+config GRKERNSEC_PROC_IPADDR -+ bool "/proc//ipaddr support" -+ help -+ If you say Y here, a new entry will be added to each /proc/ -+ directory that contains the IP address of the person using the task. -+ The IP is carried across local TCP and AF_UNIX stream sockets. -+ This information can be useful for IDS/IPSes to perform remote respo= nse -+ to a local attack. The entry is readable by only the owner of the -+ process (and root if he has CAP_DAC_OVERRIDE, which can be removed v= ia -+ the RBAC system), and thus does not create privacy concerns. -+ -+config GRKERNSEC_RWXMAP_LOG -+ bool 'Denied RWX mmap/mprotect logging' -+ depends on PAX_MPROTECT && !PAX_EMUPLT && !PAX_EMUSIGRT -+ help -+ If you say Y here, calls to mmap() and mprotect() with explicit -+ usage of PROT_WRITE and PROT_EXEC together will be logged when -+ denied by the PAX_MPROTECT feature. If the sysctl option is -+ enabled, a sysctl option with name "rwxmap_logging" is created. -+ -+config GRKERNSEC_AUDIT_TEXTREL -+ bool 'ELF text relocations logging (READ HELP)' -+ depends on PAX_MPROTECT -+ help -+ If you say Y here, text relocations will be logged with the filename -+ of the offending library or binary. The purpose of the feature is -+ to help Linux distribution developers get rid of libraries and -+ binaries that need text relocations which hinder the future progress -+ of PaX. Only Linux distribution developers should say Y here, and -+ never on a production machine, as this option creates an information -+ leak that could aid an attacker in defeating the randomization of -+ a single memory region. If the sysctl option is enabled, a sysctl -+ option with name "audit_textrel" is created. -+ -+endmenu -+ -+menu "Executable Protections" -+depends on GRKERNSEC -+ -+config GRKERNSEC_DMESG -+ bool "Dmesg(8) restriction" -+ help -+ If you say Y here, non-root users will not be able to use dmesg(8) -+ to view up to the last 4kb of messages in the kernel's log buffer. -+ The kernel's log buffer often contains kernel addresses and other -+ identifying information useful to an attacker in fingerprinting a -+ system for a targeted exploit. -+ If the sysctl option is enabled, a sysctl option with name "dmesg" i= s -+ created. -+ -+config GRKERNSEC_HARDEN_PTRACE -+ bool "Deter ptrace-based process snooping" -+ help -+ If you say Y here, TTY sniffers and other malicious monitoring -+ programs implemented through ptrace will be defeated. If you -+ have been using the RBAC system, this option has already been -+ enabled for several years for all users, with the ability to make -+ fine-grained exceptions. -+ -+ This option only affects the ability of non-root users to ptrace -+ processes that are not a descendent of the ptracing process. -+ This means that strace ./binary and gdb ./binary will still work, -+ but attaching to arbitrary processes will not. If the sysctl -+ option is enabled, a sysctl option with name "harden_ptrace" is -+ created. -+ -+config GRKERNSEC_TPE -+ bool "Trusted Path Execution (TPE)" -+ help -+ If you say Y here, you will be able to choose a gid to add to the -+ supplementary groups of users you want to mark as "untrusted." -+ These users will not be able to execute any files that are not in -+ root-owned directories writable only by root. If the sysctl option -+ is enabled, a sysctl option with name "tpe" is created. -+ -+config GRKERNSEC_TPE_ALL -+ bool "Partially restrict all non-root users" -+ depends on GRKERNSEC_TPE -+ help -+ If you say Y here, all non-root users will be covered under -+ a weaker TPE restriction. This is separate from, and in addition to= , -+ the main TPE options that you have selected elsewhere. Thus, if a -+ "trusted" GID is chosen, this restriction applies to even that GID. -+ Under this restriction, all non-root users will only be allowed to -+ execute files in directories they own that are not group or -+ world-writable, or in directories owned by root and writable only by -+ root. If the sysctl option is enabled, a sysctl option with name -+ "tpe_restrict_all" is created. -+ -+config GRKERNSEC_TPE_INVERT -+ bool "Invert GID option" -+ depends on GRKERNSEC_TPE -+ help -+ If you say Y here, the group you specify in the TPE configuration wi= ll -+ decide what group TPE restrictions will be *disabled* for. This -+ option is useful if you want TPE restrictions to be applied to most -+ users on the system. If the sysctl option is enabled, a sysctl opti= on -+ with name "tpe_invert" is created. Unlike other sysctl options, thi= s -+ entry will default to on for backward-compatibility. -+ -+config GRKERNSEC_TPE_GID -+ int "GID for untrusted users" -+ depends on GRKERNSEC_TPE && !GRKERNSEC_TPE_INVERT -+ default 1005 -+ help -+ Setting this GID determines what group TPE restrictions will be -+ *enabled* for. If the sysctl option is enabled, a sysctl option -+ with name "tpe_gid" is created. -+ -+config GRKERNSEC_TPE_GID -+ int "GID for trusted users" -+ depends on GRKERNSEC_TPE && GRKERNSEC_TPE_INVERT -+ default 1005 -+ help -+ Setting this GID determines what group TPE restrictions will be -+ *disabled* for. If the sysctl option is enabled, a sysctl option -+ with name "tpe_gid" is created. -+ -+endmenu -+menu "Network Protections" -+depends on GRKERNSEC -+ -+config GRKERNSEC_RANDNET -+ bool "Larger entropy pools" -+ help -+ If you say Y here, the entropy pools used for many features of Linux -+ and grsecurity will be doubled in size. Since several grsecurity -+ features use additional randomness, it is recommended that you say Y -+ here. Saying Y here has a similar effect as modifying -+ /proc/sys/kernel/random/poolsize. -+ -+config GRKERNSEC_BLACKHOLE -+ bool "TCP/UDP blackhole and LAST_ACK DoS prevention" -+ depends on NET -+ help -+ If you say Y here, neither TCP resets nor ICMP -+ destination-unreachable packets will be sent in response to packets -+ sent to ports for which no associated listening process exists. -+ This feature supports both IPV4 and IPV6 and exempts the=20 -+ loopback interface from blackholing. Enabling this feature=20 -+ makes a host more resilient to DoS attacks and reduces network -+ visibility against scanners. -+ -+ The blackhole feature as-implemented is equivalent to the FreeBSD -+ blackhole feature, as it prevents RST responses to all packets, not -+ just SYNs. Under most application behavior this causes no -+ problems, but applications (like haproxy) may not close certain -+ connections in a way that cleanly terminates them on the remote -+ end, leaving the remote host in LAST_ACK state. Because of this -+ side-effect and to prevent intentional LAST_ACK DoSes, this -+ feature also adds automatic mitigation against such attacks. -+ The mitigation drastically reduces the amount of time a socket -+ can spend in LAST_ACK state. If you're using haproxy and not -+ all servers it connects to have this option enabled, consider -+ disabling this feature on the haproxy host. -+ -+ If the sysctl option is enabled, two sysctl options with names -+ "ip_blackhole" and "lastack_retries" will be created. -+ While "ip_blackhole" takes the standard zero/non-zero on/off -+ toggle, "lastack_retries" uses the same kinds of values as -+ "tcp_retries1" and "tcp_retries2". The default value of 4 -+ prevents a socket from lasting more than 45 seconds in LAST_ACK -+ state. -+ -+config GRKERNSEC_SOCKET -+ bool "Socket restrictions" -+ depends on NET -+ help -+ If you say Y here, you will be able to choose from several options. -+ If you assign a GID on your system and add it to the supplementary -+ groups of users you want to restrict socket access to, this patch -+ will perform up to three things, based on the option(s) you choose. -+ -+config GRKERNSEC_SOCKET_ALL -+ bool "Deny any sockets to group" -+ depends on GRKERNSEC_SOCKET -+ help -+ If you say Y here, you will be able to choose a GID of whose users w= ill -+ be unable to connect to other hosts from your machine or run server -+ applications from your machine. If the sysctl option is enabled, a -+ sysctl option with name "socket_all" is created. -+ -+config GRKERNSEC_SOCKET_ALL_GID -+ int "GID to deny all sockets for" -+ depends on GRKERNSEC_SOCKET_ALL -+ default 1004 -+ help -+ Here you can choose the GID to disable socket access for. Remember t= o -+ add the users you want socket access disabled for to the GID -+ specified here. If the sysctl option is enabled, a sysctl option -+ with name "socket_all_gid" is created. ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_TPE_INVERT ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "tpe_invert", ++ .data =3D &grsec_enable_tpe_invert, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_TPE_ALL ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "tpe_restrict_all", ++ .data =3D &grsec_enable_tpe_all, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_SOCKET_ALL ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "socket_all", ++ .data =3D &grsec_enable_socket_all, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "socket_all_gid", ++ .data =3D &grsec_socket_all_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_SOCKET_CLIENT ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "socket_client", ++ .data =3D &grsec_enable_socket_client, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "socket_client_gid", ++ .data =3D &grsec_socket_client_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_SOCKET_SERVER ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "socket_server", ++ .data =3D &grsec_enable_socket_server, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "socket_server_gid", ++ .data =3D &grsec_socket_server_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_GROUP ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "audit_group", ++ .data =3D &grsec_enable_group, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "audit_gid", ++ .data =3D &grsec_audit_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_CHDIR ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "audit_chdir", ++ .data =3D &grsec_enable_chdir, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_MOUNT ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "audit_mount", ++ .data =3D &grsec_enable_mount, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_TEXTREL ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "audit_textrel", ++ .data =3D &grsec_enable_audit_textrel, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_DMESG ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "dmesg", ++ .data =3D &grsec_enable_dmesg, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_FINDTASK ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "chroot_findtask", ++ .data =3D &grsec_enable_chroot_findtask, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_RESLOG ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "resource_logging", ++ .data =3D &grsec_resource_logging, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_PTRACE ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "audit_ptrace", ++ .data =3D &grsec_enable_audit_ptrace, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_HARDEN_PTRACE ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "harden_ptrace", ++ .data =3D &grsec_enable_harden_ptrace, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "grsec_lock", ++ .data =3D &grsec_lock, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_ROFS ++ { ++ .ctl_name =3D CTL_UNNUMBERED, ++ .procname =3D "romount_protect", ++ .data =3D &grsec_enable_rofs, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec_minmax, ++ .extra1 =3D &one, ++ .extra2 =3D &one, ++ }, ++#endif ++ { .ctl_name =3D 0 } ++}; ++#endif +diff --git a/grsecurity/grsec_time.c b/grsecurity/grsec_time.c +new file mode 100644 +index 0000000..0dc13c3 +--- /dev/null ++++ b/grsecurity/grsec_time.c +@@ -0,0 +1,16 @@ ++#include ++#include ++#include ++#include + -+config GRKERNSEC_SOCKET_CLIENT -+ bool "Deny client sockets to group" -+ depends on GRKERNSEC_SOCKET -+ help -+ If you say Y here, you will be able to choose a GID of whose users w= ill -+ be unable to connect to other hosts from your machine, but will be -+ able to run servers. If this option is enabled, all users in the gr= oup -+ you specify will have to use passive mode when initiating ftp transf= ers -+ from the shell on your machine. If the sysctl option is enabled, a -+ sysctl option with name "socket_client" is created. ++void ++gr_log_timechange(void) ++{ ++#ifdef CONFIG_GRKERNSEC_TIME ++ if (grsec_enable_time) ++ gr_log_noargs(GR_DONT_AUDIT_GOOD, GR_TIME_MSG); ++#endif ++ return; ++} + -+config GRKERNSEC_SOCKET_CLIENT_GID -+ int "GID to deny client sockets for" -+ depends on GRKERNSEC_SOCKET_CLIENT -+ default 1003 -+ help -+ Here you can choose the GID to disable client socket access for. -+ Remember to add the users you want client socket access disabled for= to -+ the GID specified here. If the sysctl option is enabled, a sysctl -+ option with name "socket_client_gid" is created. ++EXPORT_SYMBOL(gr_log_timechange); +diff --git a/grsecurity/grsec_tpe.c b/grsecurity/grsec_tpe.c +new file mode 100644 +index 0000000..4a78774 +--- /dev/null ++++ b/grsecurity/grsec_tpe.c +@@ -0,0 +1,39 @@ ++#include ++#include ++#include ++#include ++#include + -+config GRKERNSEC_SOCKET_SERVER -+ bool "Deny server sockets to group" -+ depends on GRKERNSEC_SOCKET -+ help -+ If you say Y here, you will be able to choose a GID of whose users w= ill -+ be unable to run server applications from your machine. If the sysc= tl -+ option is enabled, a sysctl option with name "socket_server" is crea= ted. ++extern int gr_acl_tpe_check(void); + -+config GRKERNSEC_SOCKET_SERVER_GID -+ int "GID to deny server sockets for" -+ depends on GRKERNSEC_SOCKET_SERVER -+ default 1002 -+ help -+ Here you can choose the GID to disable server socket access for. -+ Remember to add the users you want server socket access disabled for= to -+ the GID specified here. If the sysctl option is enabled, a sysctl -+ option with name "socket_server_gid" is created. ++int ++gr_tpe_allow(const struct file *file) ++{ ++#ifdef CONFIG_GRKERNSEC ++ struct inode *inode =3D file->f_path.dentry->d_parent->d_inode; ++ const struct cred *cred =3D current_cred(); + -+endmenu -+menu "Sysctl support" -+depends on GRKERNSEC && SYSCTL ++ if (cred->uid && ((grsec_enable_tpe && ++#ifdef CONFIG_GRKERNSEC_TPE_INVERT ++ ((grsec_enable_tpe_invert && !in_group_p(grsec_tpe_gid)) || ++ (!grsec_enable_tpe_invert && in_group_p(grsec_tpe_gid))) ++#else ++ in_group_p(grsec_tpe_gid) ++#endif ++ ) || gr_acl_tpe_check()) && ++ (inode->i_uid || (!inode->i_uid && ((inode->i_mode & S_IWGRP) || ++ (inode->i_mode & S_IWOTH))))) { ++ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); ++ return 0; ++ } ++#ifdef CONFIG_GRKERNSEC_TPE_ALL ++ if (cred->uid && grsec_enable_tpe && grsec_enable_tpe_all && ++ ((inode->i_uid && (inode->i_uid !=3D cred->uid)) || ++ (inode->i_mode & S_IWGRP) || (inode->i_mode & S_IWOTH))) { ++ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); ++ return 0; ++ } ++#endif ++#endif ++ return 1; ++} +diff --git a/grsecurity/grsum.c b/grsecurity/grsum.c +new file mode 100644 +index 0000000..9f7b1ac +--- /dev/null ++++ b/grsecurity/grsum.c +@@ -0,0 +1,61 @@ ++#include ++#include ++#include ++#include ++#include ++#include ++#include + -+config GRKERNSEC_SYSCTL -+ bool "Sysctl support" -+ help -+ If you say Y here, you will be able to change the options that -+ grsecurity runs with at bootup, without having to recompile your -+ kernel. You can echo values to files in /proc/sys/kernel/grsecurity -+ to enable (1) or disable (0) various features. All the sysctl entri= es -+ are mutable until the "grsec_lock" entry is set to a non-zero value. -+ All features enabled in the kernel configuration are disabled at boo= t -+ if you do not say Y to the "Turn on features by default" option. -+ All options should be set at startup, and the grsec_lock entry shoul= d -+ be set to a non-zero value after all the options are set. -+ *THIS IS EXTREMELY IMPORTANT* + -+config GRKERNSEC_SYSCTL_DISTRO -+ bool "Extra sysctl support for distro makers (READ HELP)" -+ depends on GRKERNSEC_SYSCTL && GRKERNSEC_IO -+ help -+ If you say Y here, additional sysctl options will be created -+ for features that affect processes running as root. Therefore, -+ it is critical when using this option that the grsec_lock entry be -+ enabled after boot. Only distros with prebuilt kernel packages -+ with this option enabled that can ensure grsec_lock is enabled -+ after boot should use this option. -+ *Failure to set grsec_lock after boot makes all grsec features -+ this option covers useless* ++#if !defined(CONFIG_CRYPTO) || defined(CONFIG_CRYPTO_MODULE) || !define= d(CONFIG_CRYPTO_SHA256) || defined(CONFIG_CRYPTO_SHA256_MODULE) ++#error "crypto and sha256 must be built into the kernel" ++#endif + -+ Currently this option creates the following sysctl entries: -+ "Disable Privileged I/O": "disable_priv_io"=09 ++int ++chkpw(struct gr_arg *entry, unsigned char *salt, unsigned char *sum) ++{ ++ char *p; ++ struct crypto_hash *tfm; ++ struct hash_desc desc; ++ struct scatterlist sg; ++ unsigned char temp_sum[GR_SHA_LEN]; ++ volatile int retval =3D 0; ++ volatile int dummy =3D 0; ++ unsigned int i; + -+config GRKERNSEC_SYSCTL_ON -+ bool "Turn on features by default" -+ depends on GRKERNSEC_SYSCTL -+ help -+ If you say Y here, instead of having all features enabled in the -+ kernel configuration disabled at boot time, the features will be -+ enabled at boot time. It is recommended you say Y here unless -+ there is some reason you would want all sysctl-tunable features to -+ be disabled by default. As mentioned elsewhere, it is important -+ to enable the grsec_lock entry once you have finished modifying -+ the sysctl entries. ++ sg_init_table(&sg, 1); + -+endmenu -+menu "Logging Options" -+depends on GRKERNSEC ++ tfm =3D crypto_alloc_hash("sha256", 0, CRYPTO_ALG_ASYNC); ++ if (IS_ERR(tfm)) { ++ /* should never happen, since sha256 should be built in */ ++ return 1; ++ } + -+config GRKERNSEC_FLOODTIME -+ int "Seconds in between log messages (minimum)" -+ default 10 -+ help -+ This option allows you to enforce the number of seconds between -+ grsecurity log messages. The default should be suitable for most -+ people, however, if you choose to change it, choose a value small en= ough -+ to allow informative logs to be produced, but large enough to -+ prevent flooding. ++ desc.tfm =3D tfm; ++ desc.flags =3D 0; + -+config GRKERNSEC_FLOODBURST -+ int "Number of messages in a burst (maximum)" -+ default 6 -+ help -+ This option allows you to choose the maximum number of messages allo= wed -+ within the flood time interval you chose in a separate option. The -+ default should be suitable for most people, however if you find that -+ many of your logs are being interpreted as flooding, you may want to -+ raise this value. ++ crypto_hash_init(&desc); + -+endmenu ++ p =3D salt; ++ sg_set_buf(&sg, p, GR_SALT_LEN); ++ crypto_hash_update(&desc, &sg, sg.length); + -+endmenu -diff -urNp linux-2.6.32.49/grsecurity/Makefile linux-2.6.32.49/grsecurit= y/Makefile ---- linux-2.6.32.49/grsecurity/Makefile 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-2.6.32.49/grsecurity/Makefile 2011-11-15 19:59:43.000000000 -0= 500 -@@ -0,0 +1,36 @@ -+# grsecurity's ACL system was originally written in 2001 by Michael Dal= ton -+# during 2001-2009 it has been completely redesigned by Brad Spengler -+# into an RBAC system -+# -+# All code in this directory and various hooks inserted throughout the = kernel -+# are copyright Brad Spengler - Open Source Security, Inc., and release= d=20 -+# under the GPL v2 or higher ++ p =3D entry->pw; ++ sg_set_buf(&sg, p, strlen(p)); ++=09 ++ crypto_hash_update(&desc, &sg, sg.length); + -+obj-y =3D grsec_chdir.o grsec_chroot.o grsec_exec.o grsec_fifo.o grsec_= fork.o \ -+ grsec_mount.o grsec_sig.o grsec_sysctl.o \ -+ grsec_time.o grsec_tpe.o grsec_link.o grsec_pax.o grsec_ptrace.o ++ crypto_hash_final(&desc, temp_sum); + -+obj-$(CONFIG_GRKERNSEC) +=3D grsec_init.o grsum.o gracl.o gracl_segv.o = \ -+ gracl_cap.o gracl_alloc.o gracl_shm.o grsec_mem.o gracl_fs.o \ -+ gracl_learn.o grsec_log.o -+obj-$(CONFIG_GRKERNSEC_RESLOG) +=3D gracl_res.o ++ memset(entry->pw, 0, GR_PW_LEN); + -+ifdef CONFIG_NET -+obj-y +=3D grsec_sock.o -+obj-$(CONFIG_GRKERNSEC) +=3D gracl_ip.o -+endif ++ for (i =3D 0; i < GR_SHA_LEN; i++) ++ if (sum[i] !=3D temp_sum[i]) ++ retval =3D 1; ++ else ++ dummy =3D 1; // waste a cycle + -+ifndef CONFIG_GRKERNSEC -+obj-y +=3D grsec_disabled.o -+endif ++ crypto_free_hash(tfm); + -+ifdef CONFIG_GRKERNSEC_HIDESYM -+extra-y :=3D grsec_hidesym.o -+$(obj)/grsec_hidesym.o: -+ @-chmod -f 500 /boot -+ @-chmod -f 500 /lib/modules -+ @-chmod -f 500 /lib64/modules -+ @-chmod -f 500 /lib32/modules -+ @-chmod -f 700 . -+ @echo ' grsec: protected kernel image paths' -+endif -diff -urNp linux-2.6.32.49/include/acpi/acpi_bus.h linux-2.6.32.49/inclu= de/acpi/acpi_bus.h ---- linux-2.6.32.49/include/acpi/acpi_bus.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/acpi/acpi_bus.h 2011-11-15 19:59:43.00000000= 0 -0500 ++ return retval; ++} +diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h +index 3cd9ccd..fe16d47 100644 +--- a/include/acpi/acpi_bus.h ++++ b/include/acpi/acpi_bus.h @@ -107,7 +107,7 @@ struct acpi_device_ops { acpi_op_bind bind; acpi_op_unbind unbind; @@ -62089,10 +64178,11 @@ diff -urNp linux-2.6.32.49/include/acpi/acpi_bu= s.h linux-2.6.32.49/include/acpi/ =20 #define ACPI_DRIVER_ALL_NOTIFY_EVENTS 0x1 /* system AND device events *= / =20 -diff -urNp linux-2.6.32.49/include/acpi/acpi_drivers.h linux-2.6.32.49/i= nclude/acpi/acpi_drivers.h ---- linux-2.6.32.49/include/acpi/acpi_drivers.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/acpi/acpi_drivers.h 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -119,8 +119,8 @@ int acpi_processor_set_thermal_limit(acp +diff --git a/include/acpi/acpi_drivers.h b/include/acpi/acpi_drivers.h +index f4906f6..71feb73 100644 +--- a/include/acpi/acpi_drivers.h ++++ b/include/acpi/acpi_drivers.h +@@ -119,8 +119,8 @@ int acpi_processor_set_thermal_limit(acpi_handle han= dle, int type); Dock Station ---------------------------------------------------------------------= ----- */ struct acpi_dock_ops { @@ -62103,7 +64193,7 @@ diff -urNp linux-2.6.32.49/include/acpi/acpi_driv= ers.h linux-2.6.32.49/include/a }; =20 #if defined(CONFIG_ACPI_DOCK) || defined(CONFIG_ACPI_DOCK_MODULE) -@@ -128,7 +128,7 @@ extern int is_dock_device(acpi_handle ha +@@ -128,7 +128,7 @@ extern int is_dock_device(acpi_handle handle); extern int register_dock_notifier(struct notifier_block *nb); extern void unregister_dock_notifier(struct notifier_block *nb); extern int register_hotplug_dock_device(acpi_handle handle, @@ -62112,7 +64202,7 @@ diff -urNp linux-2.6.32.49/include/acpi/acpi_driv= ers.h linux-2.6.32.49/include/a void *context); extern void unregister_hotplug_dock_device(acpi_handle handle); #else -@@ -144,7 +144,7 @@ static inline void unregister_dock_notif +@@ -144,7 +144,7 @@ static inline void unregister_dock_notifier(struct n= otifier_block *nb) { } static inline int register_hotplug_dock_device(acpi_handle handle, @@ -62121,9 +64211,10 @@ diff -urNp linux-2.6.32.49/include/acpi/acpi_dri= vers.h linux-2.6.32.49/include/a void *context) { return -ENODEV; -diff -urNp linux-2.6.32.49/include/asm-generic/atomic-long.h linux-2.6.3= 2.49/include/asm-generic/atomic-long.h ---- linux-2.6.32.49/include/asm-generic/atomic-long.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/atomic-long.h 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/include/asm-generic/atomic-long.h b/include/asm-generic/ato= mic-long.h +index b7babf0..a9ac9fc 100644 +--- a/include/asm-generic/atomic-long.h ++++ b/include/asm-generic/atomic-long.h @@ -22,6 +22,12 @@ =20 typedef atomic64_t atomic_long_t; @@ -62137,7 +64228,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc #define ATOMIC_LONG_INIT(i) ATOMIC64_INIT(i) =20 static inline long atomic_long_read(atomic_long_t *l) -@@ -31,6 +37,15 @@ static inline long atomic_long_read(atom +@@ -31,6 +37,15 @@ static inline long atomic_long_read(atomic_long_t *l) return (long)atomic64_read(v); } =20 @@ -62153,7 +64244,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_set(atomic_long_t *l, long i) { atomic64_t *v =3D (atomic64_t *)l; -@@ -38,6 +53,15 @@ static inline void atomic_long_set(atomi +@@ -38,6 +53,15 @@ static inline void atomic_long_set(atomic_long_t *l, = long i) atomic64_set(v, i); } =20 @@ -62169,7 +64260,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_inc(atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -45,6 +69,15 @@ static inline void atomic_long_inc(atomi +@@ -45,6 +69,15 @@ static inline void atomic_long_inc(atomic_long_t *l) atomic64_inc(v); } =20 @@ -62185,7 +64276,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_dec(atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -52,6 +85,15 @@ static inline void atomic_long_dec(atomi +@@ -52,6 +85,15 @@ static inline void atomic_long_dec(atomic_long_t *l) atomic64_dec(v); } =20 @@ -62201,7 +64292,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_add(long i, atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -59,6 +101,15 @@ static inline void atomic_long_add(long=20 +@@ -59,6 +101,15 @@ static inline void atomic_long_add(long i, atomic_lo= ng_t *l) atomic64_add(i, v); } =20 @@ -62217,7 +64308,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_sub(long i, atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -115,6 +166,15 @@ static inline long atomic_long_inc_retur +@@ -115,6 +166,15 @@ static inline long atomic_long_inc_return(atomic_lo= ng_t *l) return (long)atomic64_inc_return(v); } =20 @@ -62233,7 +64324,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline long atomic_long_dec_return(atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -140,6 +200,12 @@ static inline long atomic_long_add_unles +@@ -140,6 +200,12 @@ static inline long atomic_long_add_unless(atomic_lo= ng_t *l, long a, long u) =20 typedef atomic_t atomic_long_t; =20 @@ -62246,7 +64337,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc #define ATOMIC_LONG_INIT(i) ATOMIC_INIT(i) static inline long atomic_long_read(atomic_long_t *l) { -@@ -148,6 +214,15 @@ static inline long atomic_long_read(atom +@@ -148,6 +214,15 @@ static inline long atomic_long_read(atomic_long_t *= l) return (long)atomic_read(v); } =20 @@ -62262,7 +64353,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_set(atomic_long_t *l, long i) { atomic_t *v =3D (atomic_t *)l; -@@ -155,6 +230,15 @@ static inline void atomic_long_set(atomi +@@ -155,6 +230,15 @@ static inline void atomic_long_set(atomic_long_t *l= , long i) atomic_set(v, i); } =20 @@ -62278,7 +64369,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_inc(atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -162,6 +246,15 @@ static inline void atomic_long_inc(atomi +@@ -162,6 +246,15 @@ static inline void atomic_long_inc(atomic_long_t *l= ) atomic_inc(v); } =20 @@ -62294,7 +64385,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_dec(atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -169,6 +262,15 @@ static inline void atomic_long_dec(atomi +@@ -169,6 +262,15 @@ static inline void atomic_long_dec(atomic_long_t *l= ) atomic_dec(v); } =20 @@ -62310,7 +64401,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_add(long i, atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -176,6 +278,15 @@ static inline void atomic_long_add(long=20 +@@ -176,6 +278,15 @@ static inline void atomic_long_add(long i, atomic_l= ong_t *l) atomic_add(i, v); } =20 @@ -62326,7 +64417,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline void atomic_long_sub(long i, atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -232,6 +343,15 @@ static inline long atomic_long_inc_retur +@@ -232,6 +343,15 @@ static inline long atomic_long_inc_return(atomic_lo= ng_t *l) return (long)atomic_inc_return(v); } =20 @@ -62342,7 +64433,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/at= omic-long.h linux-2.6.32.49/inc static inline long atomic_long_dec_return(atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -255,4 +375,47 @@ static inline long atomic_long_add_unles +@@ -255,4 +375,47 @@ static inline long atomic_long_add_unless(atomic_lo= ng_t *l, long a, long u) =20 #endif /* BITS_PER_LONG =3D=3D 64 */ =20 @@ -62390,10 +64481,11 @@ diff -urNp linux-2.6.32.49/include/asm-generic/= atomic-long.h linux-2.6.32.49/inc +#endif + #endif /* _ASM_GENERIC_ATOMIC_LONG_H */ -diff -urNp linux-2.6.32.49/include/asm-generic/bug.h linux-2.6.32.49/inc= lude/asm-generic/bug.h ---- linux-2.6.32.49/include/asm-generic/bug.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/include/asm-generic/bug.h 2011-11-15 19:59:43.000000= 000 -0500 -@@ -105,11 +105,11 @@ extern void warn_slowpath_null(const cha +diff --git a/include/asm-generic/bug.h b/include/asm-generic/bug.h +index d48ddf0..656a0ac 100644 +--- a/include/asm-generic/bug.h ++++ b/include/asm-generic/bug.h +@@ -105,11 +105,11 @@ extern void warn_slowpath_null(const char *file, c= onst int line); =20 #else /* !CONFIG_BUG */ #ifndef HAVE_ARCH_BUG @@ -62407,9 +64499,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/b= ug.h linux-2.6.32.49/include/asm #endif =20 #ifndef HAVE_ARCH_WARN_ON -diff -urNp linux-2.6.32.49/include/asm-generic/cache.h linux-2.6.32.49/i= nclude/asm-generic/cache.h ---- linux-2.6.32.49/include/asm-generic/cache.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/asm-generic/cache.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/asm-generic/cache.h b/include/asm-generic/cache.h +index 1bfcfe5..e04c5c9 100644 +--- a/include/asm-generic/cache.h ++++ b/include/asm-generic/cache.h @@ -6,7 +6,7 @@ * cache lines need to provide their own cache.h. */ @@ -62420,10 +64513,11 @@ diff -urNp linux-2.6.32.49/include/asm-generic/= cache.h linux-2.6.32.49/include/a +#define L1_CACHE_BYTES (1UL << L1_CACHE_SHIFT) =20 #endif /* __ASM_GENERIC_CACHE_H */ -diff -urNp linux-2.6.32.49/include/asm-generic/dma-mapping-common.h linu= x-2.6.32.49/include/asm-generic/dma-mapping-common.h ---- linux-2.6.32.49/include/asm-generic/dma-mapping-common.h 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/dma-mapping-common.h 2011-11-15 = 19:59:43.000000000 -0500 -@@ -11,7 +11,7 @@ static inline dma_addr_t dma_map_single_ +diff --git a/include/asm-generic/dma-mapping-common.h b/include/asm-gene= ric/dma-mapping-common.h +index 6920695..41038bc 100644 +--- a/include/asm-generic/dma-mapping-common.h ++++ b/include/asm-generic/dma-mapping-common.h +@@ -11,7 +11,7 @@ static inline dma_addr_t dma_map_single_attrs(struct d= evice *dev, void *ptr, enum dma_data_direction dir, struct dma_attrs *attrs) { @@ -62432,7 +64526,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 dma_addr_t addr; =20 kmemcheck_mark_initialized(ptr, size); -@@ -30,7 +30,7 @@ static inline void dma_unmap_single_attr +@@ -30,7 +30,7 @@ static inline void dma_unmap_single_attrs(struct devic= e *dev, dma_addr_t addr, enum dma_data_direction dir, struct dma_attrs *attrs) { @@ -62441,7 +64535,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 =20 BUG_ON(!valid_dma_direction(dir)); if (ops->unmap_page) -@@ -42,7 +42,7 @@ static inline int dma_map_sg_attrs(struc +@@ -42,7 +42,7 @@ static inline int dma_map_sg_attrs(struct device *dev,= struct scatterlist *sg, int nents, enum dma_data_direction dir, struct dma_attrs *attrs) { @@ -62450,7 +64544,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 int i, ents; struct scatterlist *s; =20 -@@ -59,7 +59,7 @@ static inline void dma_unmap_sg_attrs(st +@@ -59,7 +59,7 @@ static inline void dma_unmap_sg_attrs(struct device *d= ev, struct scatterlist *sg int nents, enum dma_data_direction dir, struct dma_attrs *attrs) { @@ -62459,7 +64553,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 =20 BUG_ON(!valid_dma_direction(dir)); debug_dma_unmap_sg(dev, sg, nents, dir); -@@ -71,7 +71,7 @@ static inline dma_addr_t dma_map_page(st +@@ -71,7 +71,7 @@ static inline dma_addr_t dma_map_page(struct device *d= ev, struct page *page, size_t offset, size_t size, enum dma_data_direction dir) { @@ -62468,7 +64562,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 dma_addr_t addr; =20 kmemcheck_mark_initialized(page_address(page) + offset, size); -@@ -85,7 +85,7 @@ static inline dma_addr_t dma_map_page(st +@@ -85,7 +85,7 @@ static inline dma_addr_t dma_map_page(struct device *d= ev, struct page *page, static inline void dma_unmap_page(struct device *dev, dma_addr_t addr, size_t size, enum dma_data_direction dir) { @@ -62477,7 +64571,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 =20 BUG_ON(!valid_dma_direction(dir)); if (ops->unmap_page) -@@ -97,7 +97,7 @@ static inline void dma_sync_single_for_c +@@ -97,7 +97,7 @@ static inline void dma_sync_single_for_cpu(struct devi= ce *dev, dma_addr_t addr, size_t size, enum dma_data_direction dir) { @@ -62486,7 +64580,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 =20 BUG_ON(!valid_dma_direction(dir)); if (ops->sync_single_for_cpu) -@@ -109,7 +109,7 @@ static inline void dma_sync_single_for_d +@@ -109,7 +109,7 @@ static inline void dma_sync_single_for_device(struct= device *dev, dma_addr_t addr, size_t size, enum dma_data_direction dir) { @@ -62495,7 +64589,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 =20 BUG_ON(!valid_dma_direction(dir)); if (ops->sync_single_for_device) -@@ -123,7 +123,7 @@ static inline void dma_sync_single_range +@@ -123,7 +123,7 @@ static inline void dma_sync_single_range_for_cpu(str= uct device *dev, size_t size, enum dma_data_direction dir) { @@ -62504,7 +64598,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/dm= a-mapping-common.h linux-2.6.32 =20 BUG_ON(!valid_dma_direction(dir)); if (ops->sync_single_range_for_cpu) { -@@ -140,7 +140,7 @@ static inline void dma_sync_single_range +@@ -140,7 +140,7 @@ static inline void dma_sync_single_range_for_device(= struct device *dev, size_t size, enum dma_data_direction dir) { @@ -62531,9 +64625,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/d= ma-mapping-common.h linux-2.6.32 =20 BUG_ON(!valid_dma_direction(dir)); if (ops->sync_sg_for_device) -diff -urNp linux-2.6.32.49/include/asm-generic/emergency-restart.h linux= -2.6.32.49/include/asm-generic/emergency-restart.h ---- linux-2.6.32.49/include/asm-generic/emergency-restart.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/emergency-restart.h 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/include/asm-generic/emergency-restart.h b/include/asm-gener= ic/emergency-restart.h +index 0d68a1e..b74a761 100644 +--- a/include/asm-generic/emergency-restart.h ++++ b/include/asm-generic/emergency-restart.h @@ -1,7 +1,7 @@ #ifndef _ASM_GENERIC_EMERGENCY_RESTART_H #define _ASM_GENERIC_EMERGENCY_RESTART_H @@ -62543,9 +64638,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/e= mergency-restart.h linux-2.6.32. { machine_restart(NULL); } -diff -urNp linux-2.6.32.49/include/asm-generic/futex.h linux-2.6.32.49/i= nclude/asm-generic/futex.h ---- linux-2.6.32.49/include/asm-generic/futex.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/asm-generic/futex.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/asm-generic/futex.h b/include/asm-generic/futex.h +index 3c2344f..4590a7d 100644 +--- a/include/asm-generic/futex.h ++++ b/include/asm-generic/futex.h @@ -6,7 +6,7 @@ #include =20 @@ -62555,7 +64651,7 @@ diff -urNp linux-2.6.32.49/include/asm-generic/fu= tex.h linux-2.6.32.49/include/a { int op =3D (encoded_op >> 28) & 7; int cmp =3D (encoded_op >> 24) & 15; -@@ -48,7 +48,7 @@ futex_atomic_op_inuser (int encoded_op,=20 +@@ -48,7 +48,7 @@ futex_atomic_op_inuser (int encoded_op, int __user *ua= ddr) } =20 static inline int @@ -62564,9 +64660,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/f= utex.h linux-2.6.32.49/include/a { return -ENOSYS; } -diff -urNp linux-2.6.32.49/include/asm-generic/int-l64.h linux-2.6.32.49= /include/asm-generic/int-l64.h ---- linux-2.6.32.49/include/asm-generic/int-l64.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/int-l64.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/include/asm-generic/int-l64.h b/include/asm-generic/int-l64= .h +index 1ca3efc..e3dc852 100644 +--- a/include/asm-generic/int-l64.h ++++ b/include/asm-generic/int-l64.h @@ -46,6 +46,8 @@ typedef unsigned int u32; typedef signed long s64; typedef unsigned long u64; @@ -62576,9 +64673,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/i= nt-l64.h linux-2.6.32.49/include #define S8_C(x) x #define U8_C(x) x ## U #define S16_C(x) x -diff -urNp linux-2.6.32.49/include/asm-generic/int-ll64.h linux-2.6.32.4= 9/include/asm-generic/int-ll64.h ---- linux-2.6.32.49/include/asm-generic/int-ll64.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/int-ll64.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/include/asm-generic/int-ll64.h b/include/asm-generic/int-ll= 64.h +index f394147..b6152b9 100644 +--- a/include/asm-generic/int-ll64.h ++++ b/include/asm-generic/int-ll64.h @@ -51,6 +51,8 @@ typedef unsigned int u32; typedef signed long long s64; typedef unsigned long long u64; @@ -62588,9 +64686,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/i= nt-ll64.h linux-2.6.32.49/includ #define S8_C(x) x #define U8_C(x) x ## U #define S16_C(x) x -diff -urNp linux-2.6.32.49/include/asm-generic/kmap_types.h linux-2.6.32= .49/include/asm-generic/kmap_types.h ---- linux-2.6.32.49/include/asm-generic/kmap_types.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/kmap_types.h 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/include/asm-generic/kmap_types.h b/include/asm-generic/kmap= _types.h +index e5f234a..cdb16b3 100644 +--- a/include/asm-generic/kmap_types.h ++++ b/include/asm-generic/kmap_types.h @@ -28,7 +28,8 @@ KMAP_D(15) KM_UML_USERCOPY, KMAP_D(16) KM_IRQ_PTE, KMAP_D(17) KM_NMI, @@ -62601,27 +64700,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/= kmap_types.h linux-2.6.32.49/incl }; =20 #undef KMAP_D -diff -urNp linux-2.6.32.49/include/asm-generic/pgtable.h linux-2.6.32.49= /include/asm-generic/pgtable.h ---- linux-2.6.32.49/include/asm-generic/pgtable.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/pgtable.h 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -344,6 +344,14 @@ extern void untrack_pfn_vma(struct vm_ar - unsigned long size); - #endif -=20 -+#ifndef __HAVE_ARCH_PAX_OPEN_KERNEL -+static inline unsigned long pax_open_kernel(void) { return 0; } -+#endif -+ -+#ifndef __HAVE_ARCH_PAX_CLOSE_KERNEL -+static inline unsigned long pax_close_kernel(void) { return 0; } -+#endif -+ - #endif /* !__ASSEMBLY__ */ -=20 - #endif /* _ASM_GENERIC_PGTABLE_H */ -diff -urNp linux-2.6.32.49/include/asm-generic/pgtable-nopmd.h linux-2.6= .32.49/include/asm-generic/pgtable-nopmd.h ---- linux-2.6.32.49/include/asm-generic/pgtable-nopmd.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/pgtable-nopmd.h 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/include/asm-generic/pgtable-nopmd.h b/include/asm-generic/p= gtable-nopmd.h +index 725612b..9cc513a 100644 +--- a/include/asm-generic/pgtable-nopmd.h ++++ b/include/asm-generic/pgtable-nopmd.h @@ -1,14 +1,19 @@ #ifndef _PGTABLE_NOPMD_H #define _PGTABLE_NOPMD_H @@ -62658,9 +64740,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/p= gtable-nopmd.h linux-2.6.32.49/i /* * The "pud_xxx()" functions here are trivial for a folded two-level * setup: the pmd is never bad, and a pmd always exists (as it's folded -diff -urNp linux-2.6.32.49/include/asm-generic/pgtable-nopud.h linux-2.6= .32.49/include/asm-generic/pgtable-nopud.h ---- linux-2.6.32.49/include/asm-generic/pgtable-nopud.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/pgtable-nopud.h 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/include/asm-generic/pgtable-nopud.h b/include/asm-generic/p= gtable-nopud.h +index 810431d..ccc3638 100644 +--- a/include/asm-generic/pgtable-nopud.h ++++ b/include/asm-generic/pgtable-nopud.h @@ -1,10 +1,15 @@ #ifndef _PGTABLE_NOPUD_H #define _PGTABLE_NOPUD_H @@ -62691,9 +64774,29 @@ diff -urNp linux-2.6.32.49/include/asm-generic/p= gtable-nopud.h linux-2.6.32.49/i /* * The "pgd_xxx()" functions here are trivial for a folded two-level * setup: the pud is never bad, and a pud always exists (as it's folded -diff -urNp linux-2.6.32.49/include/asm-generic/vmlinux.lds.h linux-2.6.3= 2.49/include/asm-generic/vmlinux.lds.h ---- linux-2.6.32.49/include/asm-generic/vmlinux.lds.h 2011-11-08 19:02:4= 3.000000000 -0500 -+++ linux-2.6.32.49/include/asm-generic/vmlinux.lds.h 2011-11-15 19:59:4= 3.000000000 -0500 +diff --git a/include/asm-generic/pgtable.h b/include/asm-generic/pgtable= .h +index e2bd73e..fea8ed3 100644 +--- a/include/asm-generic/pgtable.h ++++ b/include/asm-generic/pgtable.h +@@ -344,6 +344,14 @@ extern void untrack_pfn_vma(struct vm_area_struct *= vma, unsigned long pfn, + unsigned long size); + #endif +=20 ++#ifndef __HAVE_ARCH_PAX_OPEN_KERNEL ++static inline unsigned long pax_open_kernel(void) { return 0; } ++#endif ++ ++#ifndef __HAVE_ARCH_PAX_CLOSE_KERNEL ++static inline unsigned long pax_close_kernel(void) { return 0; } ++#endif ++ + #endif /* !__ASSEMBLY__ */ +=20 + #endif /* _ASM_GENERIC_PGTABLE_H */ +diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vml= inux.lds.h +index b6e818f..21aa58a 100644 +--- a/include/asm-generic/vmlinux.lds.h ++++ b/include/asm-generic/vmlinux.lds.h @@ -199,6 +199,7 @@ .rodata : AT(ADDR(.rodata) - LOAD_OFFSET) { \ VMLINUX_SYMBOL(__start_rodata) =3D .; \ @@ -62732,30 +64835,10 @@ diff -urNp linux-2.6.32.49/include/asm-generic/= vmlinux.lds.h linux-2.6.32.49/inc =20 /** * PERCPU - define output section for percpu area, simple version -diff -urNp linux-2.6.32.49/include/drm/drm_crtc_helper.h linux-2.6.32.49= /include/drm/drm_crtc_helper.h ---- linux-2.6.32.49/include/drm/drm_crtc_helper.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/drm/drm_crtc_helper.h 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -64,7 +64,7 @@ struct drm_crtc_helper_funcs { -=20 - /* reload the current crtc LUT */ - void (*load_lut)(struct drm_crtc *crtc); --}; -+} __no_const; -=20 - struct drm_encoder_helper_funcs { - void (*dpms)(struct drm_encoder *encoder, int mode); -@@ -85,7 +85,7 @@ struct drm_encoder_helper_funcs { - struct drm_connector *connector); - /* disable encoder when not in use - more explicit than dpms off */ - void (*disable)(struct drm_encoder *encoder); --}; -+} __no_const; -=20 - struct drm_connector_helper_funcs { - int (*get_modes)(struct drm_connector *connector); -diff -urNp linux-2.6.32.49/include/drm/drmP.h linux-2.6.32.49/include/dr= m/drmP.h ---- linux-2.6.32.49/include/drm/drmP.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/include/drm/drmP.h 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/include/drm/drmP.h b/include/drm/drmP.h +index 66713c6..98c0460 100644 +--- a/include/drm/drmP.h ++++ b/include/drm/drmP.h @@ -71,6 +71,7 @@ #include #include @@ -62815,9 +64898,32 @@ diff -urNp linux-2.6.32.49/include/drm/drmP.h li= nux-2.6.32.49/include/drm/drmP.h uint32_t gtt_total; uint32_t invalidate_domains; /* domains pending invalidation */ uint32_t flush_domains; /* domains pending flush */ -diff -urNp linux-2.6.32.49/include/drm/ttm/ttm_memory.h linux-2.6.32.49/= include/drm/ttm/ttm_memory.h ---- linux-2.6.32.49/include/drm/ttm/ttm_memory.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/include/drm/ttm/ttm_memory.h 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/include/drm/drm_crtc_helper.h b/include/drm/drm_crtc_helper= .h +index b29e201..3413cc9 100644 +--- a/include/drm/drm_crtc_helper.h ++++ b/include/drm/drm_crtc_helper.h +@@ -64,7 +64,7 @@ struct drm_crtc_helper_funcs { +=20 + /* reload the current crtc LUT */ + void (*load_lut)(struct drm_crtc *crtc); +-}; ++} __no_const; +=20 + struct drm_encoder_helper_funcs { + void (*dpms)(struct drm_encoder *encoder, int mode); +@@ -85,7 +85,7 @@ struct drm_encoder_helper_funcs { + struct drm_connector *connector); + /* disable encoder when not in use - more explicit than dpms off */ + void (*disable)(struct drm_encoder *encoder); +-}; ++} __no_const; +=20 + struct drm_connector_helper_funcs { + int (*get_modes)(struct drm_connector *connector); +diff --git a/include/drm/ttm/ttm_memory.h b/include/drm/ttm/ttm_memory.h +index b199170..6f9e64c 100644 +--- a/include/drm/ttm/ttm_memory.h ++++ b/include/drm/ttm/ttm_memory.h @@ -47,7 +47,7 @@ =20 struct ttm_mem_shrink { @@ -62827,9 +64933,10 @@ diff -urNp linux-2.6.32.49/include/drm/ttm/ttm_m= emory.h linux-2.6.32.49/include/ =20 /** * struct ttm_mem_global - Global memory accounting structure. -diff -urNp linux-2.6.32.49/include/linux/a.out.h linux-2.6.32.49/include= /linux/a.out.h ---- linux-2.6.32.49/include/linux/a.out.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/a.out.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/a.out.h b/include/linux/a.out.h +index e86dfca..40cc55f 100644 +--- a/include/linux/a.out.h ++++ b/include/linux/a.out.h @@ -39,6 +39,14 @@ enum machine_type { M_MIPS2 =3D 152 /* MIPS R6000/R4000 binary */ }; @@ -62845,9 +64952,10 @@ diff -urNp linux-2.6.32.49/include/linux/a.out.h= linux-2.6.32.49/include/linux/a #if !defined (N_MAGIC) #define N_MAGIC(exec) ((exec).a_info & 0xffff) #endif -diff -urNp linux-2.6.32.49/include/linux/atmdev.h linux-2.6.32.49/includ= e/linux/atmdev.h ---- linux-2.6.32.49/include/linux/atmdev.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/atmdev.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/atmdev.h b/include/linux/atmdev.h +index 817b237..62c10bc 100644 +--- a/include/linux/atmdev.h ++++ b/include/linux/atmdev.h @@ -237,7 +237,7 @@ struct compat_atm_iobuf { #endif =20 @@ -62857,9 +64965,10 @@ diff -urNp linux-2.6.32.49/include/linux/atmdev.= h linux-2.6.32.49/include/linux/ __AAL_STAT_ITEMS #undef __HANDLE_ITEM }; -diff -urNp linux-2.6.32.49/include/linux/backlight.h linux-2.6.32.49/inc= lude/linux/backlight.h ---- linux-2.6.32.49/include/linux/backlight.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/include/linux/backlight.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/include/linux/backlight.h b/include/linux/backlight.h +index 0f5f578..8c4f884 100644 +--- a/include/linux/backlight.h ++++ b/include/linux/backlight.h @@ -36,18 +36,18 @@ struct backlight_device; struct fb_info; =20 @@ -62892,7 +65001,7 @@ diff -urNp linux-2.6.32.49/include/linux/backligh= t.h linux-2.6.32.49/include/lin =20 /* The framebuffer notifier block */ struct notifier_block fb_notif; -@@ -103,7 +103,7 @@ static inline void backlight_update_stat +@@ -103,7 +103,7 @@ static inline void backlight_update_status(struct ba= cklight_device *bd) } =20 extern struct backlight_device *backlight_device_register(const char *n= ame, @@ -62901,9 +65010,10 @@ diff -urNp linux-2.6.32.49/include/linux/backlig= ht.h linux-2.6.32.49/include/lin extern void backlight_device_unregister(struct backlight_device *bd); extern void backlight_force_update(struct backlight_device *bd, enum backlight_update_reason reason); -diff -urNp linux-2.6.32.49/include/linux/binfmts.h linux-2.6.32.49/inclu= de/linux/binfmts.h ---- linux-2.6.32.49/include/linux/binfmts.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/binfmts.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/include/linux/binfmts.h b/include/linux/binfmts.h +index a3d802e..482f69c 100644 +--- a/include/linux/binfmts.h ++++ b/include/linux/binfmts.h @@ -83,6 +83,7 @@ struct linux_binfmt { int (*load_binary)(struct linux_binprm *, struct pt_regs * regs); int (*load_shlib)(struct file *); @@ -62912,9 +65022,10 @@ diff -urNp linux-2.6.32.49/include/linux/binfmts= .h linux-2.6.32.49/include/linux unsigned long min_coredump; /* minimal dump size */ int hasvdso; }; -diff -urNp linux-2.6.32.49/include/linux/blkdev.h linux-2.6.32.49/includ= e/linux/blkdev.h ---- linux-2.6.32.49/include/linux/blkdev.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/blkdev.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h +index a06bfab..4fa38bb 100644 +--- a/include/linux/blkdev.h ++++ b/include/linux/blkdev.h @@ -1278,7 +1278,7 @@ struct block_device_operations { int (*revalidate_disk) (struct gendisk *); int (*getgeo)(struct block_device *, struct hd_geometry *); @@ -62924,9 +65035,10 @@ diff -urNp linux-2.6.32.49/include/linux/blkdev.= h linux-2.6.32.49/include/linux/ =20 extern int __blkdev_driver_ioctl(struct block_device *, fmode_t, unsign= ed int, unsigned long); -diff -urNp linux-2.6.32.49/include/linux/blktrace_api.h linux-2.6.32.49/= include/linux/blktrace_api.h ---- linux-2.6.32.49/include/linux/blktrace_api.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/include/linux/blktrace_api.h 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/include/linux/blktrace_api.h b/include/linux/blktrace_api.h +index 3b73b99..629d21b 100644 +--- a/include/linux/blktrace_api.h ++++ b/include/linux/blktrace_api.h @@ -160,7 +160,7 @@ struct blk_trace { struct dentry *dir; struct dentry *dropped_file; @@ -62936,9 +65048,10 @@ diff -urNp linux-2.6.32.49/include/linux/blktrac= e_api.h linux-2.6.32.49/include/ }; =20 extern int blk_trace_ioctl(struct block_device *, unsigned, char __user= *); -diff -urNp linux-2.6.32.49/include/linux/byteorder/little_endian.h linux= -2.6.32.49/include/linux/byteorder/little_endian.h ---- linux-2.6.32.49/include/linux/byteorder/little_endian.h 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/include/linux/byteorder/little_endian.h 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/include/linux/byteorder/little_endian.h b/include/linux/byt= eorder/little_endian.h +index 83195fb..0b0f77d 100644 +--- a/include/linux/byteorder/little_endian.h ++++ b/include/linux/byteorder/little_endian.h @@ -42,51 +42,51 @@ =20 static inline __le64 __cpu_to_le64p(const __u64 *p) @@ -63003,9 +65116,10 @@ diff -urNp linux-2.6.32.49/include/linux/byteord= er/little_endian.h linux-2.6.32. } #define __cpu_to_le64s(x) do { (void)(x); } while (0) #define __le64_to_cpus(x) do { (void)(x); } while (0) -diff -urNp linux-2.6.32.49/include/linux/cache.h linux-2.6.32.49/include= /linux/cache.h ---- linux-2.6.32.49/include/linux/cache.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/cache.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/cache.h b/include/linux/cache.h +index 97e2488..e7576b9 100644 +--- a/include/linux/cache.h ++++ b/include/linux/cache.h @@ -16,6 +16,10 @@ #define __read_mostly #endif @@ -63017,10 +65131,11 @@ diff -urNp linux-2.6.32.49/include/linux/cache.= h linux-2.6.32.49/include/linux/c #ifndef ____cacheline_aligned #define ____cacheline_aligned __attribute__((__aligned__(SMP_CACHE_BYTE= S))) #endif -diff -urNp linux-2.6.32.49/include/linux/capability.h linux-2.6.32.49/in= clude/linux/capability.h ---- linux-2.6.32.49/include/linux/capability.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/linux/capability.h 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -563,6 +563,7 @@ extern const kernel_cap_t __cap_init_eff +diff --git a/include/linux/capability.h b/include/linux/capability.h +index c8f2a5f7..1618a5c 100644 +--- a/include/linux/capability.h ++++ b/include/linux/capability.h +@@ -563,6 +563,7 @@ extern const kernel_cap_t __cap_init_eff_set; (security_real_capable_noaudit((t), (cap)) =3D=3D 0) =20 extern int capable(int cap); @@ -63028,9 +65143,10 @@ diff -urNp linux-2.6.32.49/include/linux/capabil= ity.h linux-2.6.32.49/include/li =20 /* audit system wants to get cap info from files as well */ struct dentry; -diff -urNp linux-2.6.32.49/include/linux/compiler-gcc4.h linux-2.6.32.49= /include/linux/compiler-gcc4.h ---- linux-2.6.32.49/include/linux/compiler-gcc4.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/linux/compiler-gcc4.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/include/linux/compiler-gcc4.h b/include/linux/compiler-gcc4= .h +index 450fa59..86019fb 100644 +--- a/include/linux/compiler-gcc4.h ++++ b/include/linux/compiler-gcc4.h @@ -36,4 +36,16 @@ the kernel context */ #define __cold __attribute__((__cold__)) @@ -63048,9 +65164,10 @@ diff -urNp linux-2.6.32.49/include/linux/compile= r-gcc4.h linux-2.6.32.49/include +#endif + #endif -diff -urNp linux-2.6.32.49/include/linux/compiler.h linux-2.6.32.49/incl= ude/linux/compiler.h ---- linux-2.6.32.49/include/linux/compiler.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/compiler.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/linux/compiler.h b/include/linux/compiler.h +index 04fb513..fd6477b 100644 +--- a/include/linux/compiler.h ++++ b/include/linux/compiler.h @@ -5,11 +5,14 @@ =20 #ifdef __CHECKER__ @@ -63101,7 +65218,7 @@ diff -urNp linux-2.6.32.49/include/linux/compiler= .h linux-2.6.32.49/include/linu # define __chk_user_ptr(x) (void)0 # define __chk_io_ptr(x) (void)0 # define __builtin_warning(x, y...) (1) -@@ -247,6 +271,14 @@ void ftrace_likely_update(struct ftrace_ +@@ -247,6 +271,14 @@ void ftrace_likely_update(struct ftrace_branch_data= *f, int val, int expect); # define __attribute_const__ /* unimplemented */ #endif =20 @@ -63116,7 +65233,7 @@ diff -urNp linux-2.6.32.49/include/linux/compiler= .h linux-2.6.32.49/include/linu /* * Tell gcc if a function is cold. The compiler will assume any path * directly leading to the call is unlikely. -@@ -256,6 +288,22 @@ void ftrace_likely_update(struct ftrace_ +@@ -256,6 +288,22 @@ void ftrace_likely_update(struct ftrace_branch_data= *f, int val, int expect); #define __cold #endif =20 @@ -63139,7 +65256,7 @@ diff -urNp linux-2.6.32.49/include/linux/compiler= .h linux-2.6.32.49/include/linu /* Simple shorthand for a section definition */ #ifndef __section # define __section(S) __attribute__ ((__section__(#S))) -@@ -278,6 +326,7 @@ void ftrace_likely_update(struct ftrace_ +@@ -278,6 +326,7 @@ void ftrace_likely_update(struct ftrace_branch_data = *f, int val, int expect); * use is to mediate communication between process-level code and irq/N= MI * handlers, all running on the same CPU. */ @@ -63148,9 +65265,10 @@ diff -urNp linux-2.6.32.49/include/linux/compile= r.h linux-2.6.32.49/include/linu +#define ACCESS_ONCE_RW(x) (*(volatile typeof(x) *)&(x)) =20 #endif /* __LINUX_COMPILER_H */ -diff -urNp linux-2.6.32.49/include/linux/crypto.h linux-2.6.32.49/includ= e/linux/crypto.h ---- linux-2.6.32.49/include/linux/crypto.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/crypto.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/crypto.h b/include/linux/crypto.h +index fd92988..a3164bd 100644 +--- a/include/linux/crypto.h ++++ b/include/linux/crypto.h @@ -394,7 +394,7 @@ struct cipher_tfm { const u8 *key, unsigned int keylen); void (*cit_encrypt_one)(struct crypto_tfm *tfm, u8 *dst, const u8 *src= ); @@ -63176,9 +65294,10 @@ diff -urNp linux-2.6.32.49/include/linux/crypto.= h linux-2.6.32.49/include/linux/ =20 #define crt_ablkcipher crt_u.ablkcipher #define crt_aead crt_u.aead -diff -urNp linux-2.6.32.49/include/linux/dcache.h linux-2.6.32.49/includ= e/linux/dcache.h ---- linux-2.6.32.49/include/linux/dcache.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/dcache.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/dcache.h b/include/linux/dcache.h +index 30b93b2..cd7a8db 100644 +--- a/include/linux/dcache.h ++++ b/include/linux/dcache.h @@ -119,6 +119,8 @@ struct dentry { unsigned char d_iname[DNAME_INLINE_LEN_MIN]; /* small names */ }; @@ -63188,9 +65307,10 @@ diff -urNp linux-2.6.32.49/include/linux/dcache.= h linux-2.6.32.49/include/linux/ /* * dentry->d_lock spinlock nesting subclasses: * -diff -urNp linux-2.6.32.49/include/linux/decompress/mm.h linux-2.6.32.49= /include/linux/decompress/mm.h ---- linux-2.6.32.49/include/linux/decompress/mm.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/linux/decompress/mm.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/include/linux/decompress/mm.h b/include/linux/decompress/mm= .h +index 3e9bd6a..f4e1aa0 100644 +--- a/include/linux/decompress/mm.h ++++ b/include/linux/decompress/mm.h @@ -78,7 +78,7 @@ static void free(void *where) * warnings when not needed (indeed large_malloc / large_free are not * needed by inflate */ @@ -63200,9 +65320,10 @@ diff -urNp linux-2.6.32.49/include/linux/decompr= ess/mm.h linux-2.6.32.49/include #define free(a) kfree(a) =20 #define large_malloc(a) vmalloc(a) -diff -urNp linux-2.6.32.49/include/linux/dma-mapping.h linux-2.6.32.49/i= nclude/linux/dma-mapping.h ---- linux-2.6.32.49/include/linux/dma-mapping.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/linux/dma-mapping.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h +index 91b7618..92a93d32 100644 +--- a/include/linux/dma-mapping.h ++++ b/include/linux/dma-mapping.h @@ -16,51 +16,51 @@ enum dma_data_direction { }; =20 @@ -63270,9 +65391,10 @@ diff -urNp linux-2.6.32.49/include/linux/dma-map= ping.h linux-2.6.32.49/include/l =20 #define DMA_BIT_MASK(n) (((n) =3D=3D 64) ? ~0ULL : ((1ULL<<(n))-1)) =20 -diff -urNp linux-2.6.32.49/include/linux/dst.h linux-2.6.32.49/include/l= inux/dst.h ---- linux-2.6.32.49/include/linux/dst.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/dst.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/linux/dst.h b/include/linux/dst.h +index e26fed8..b976d9f 100644 +--- a/include/linux/dst.h ++++ b/include/linux/dst.h @@ -380,7 +380,7 @@ struct dst_node struct thread_pool *pool; =20 @@ -63282,9 +65404,10 @@ diff -urNp linux-2.6.32.49/include/linux/dst.h l= inux-2.6.32.49/include/linux/dst =20 /* * How frequently and how many times transaction -diff -urNp linux-2.6.32.49/include/linux/elf.h linux-2.6.32.49/include/l= inux/elf.h ---- linux-2.6.32.49/include/linux/elf.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/elf.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/linux/elf.h b/include/linux/elf.h +index 90a4ed0..d652617 100644 +--- a/include/linux/elf.h ++++ b/include/linux/elf.h @@ -49,6 +49,17 @@ typedef __s64 Elf64_Sxword; #define PT_GNU_EH_FRAME 0x6474e550 =20 @@ -63357,31 +65480,11 @@ diff -urNp linux-2.6.32.49/include/linux/elf.h = linux-2.6.32.49/include/linux/elf =20 #endif =20 -diff -urNp linux-2.6.32.49/include/linux/fscache-cache.h linux-2.6.32.49= /include/linux/fscache-cache.h ---- linux-2.6.32.49/include/linux/fscache-cache.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/linux/fscache-cache.h 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -116,7 +116,7 @@ struct fscache_operation { - #endif - }; -=20 --extern atomic_t fscache_op_debug_id; -+extern atomic_unchecked_t fscache_op_debug_id; - extern const struct slow_work_ops fscache_op_slow_work_ops; -=20 - extern void fscache_enqueue_operation(struct fscache_operation *); -@@ -134,7 +134,7 @@ static inline void fscache_operation_ini - fscache_operation_release_t release) - { - atomic_set(&op->usage, 1); -- op->debug_id =3D atomic_inc_return(&fscache_op_debug_id); -+ op->debug_id =3D atomic_inc_return_unchecked(&fscache_op_debug_id); - op->release =3D release; - INIT_LIST_HEAD(&op->pend_link); - fscache_set_op_state(op, "Init"); -diff -urNp linux-2.6.32.49/include/linux/fs.h linux-2.6.32.49/include/li= nux/fs.h ---- linux-2.6.32.49/include/linux/fs.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/include/linux/fs.h 2011-11-18 19:28:58.000000000 -05= 00 -@@ -568,41 +568,41 @@ typedef int (*read_actor_t)(read_descrip +diff --git a/include/linux/fs.h b/include/linux/fs.h +index 1b9a47a..6fe2934 100644 +--- a/include/linux/fs.h ++++ b/include/linux/fs.h +@@ -568,41 +568,41 @@ typedef int (*read_actor_t)(read_descriptor_t *, s= truct page *, unsigned long, unsigned long); =20 struct address_space_operations { @@ -63440,7 +65543,7 @@ diff -urNp linux-2.6.32.49/include/linux/fs.h lin= ux-2.6.32.49/include/linux/fs.h }; =20 /* -@@ -1031,19 +1031,19 @@ static inline int file_check_writeable(s +@@ -1031,19 +1031,19 @@ static inline int file_check_writeable(struct fi= le *filp) typedef struct files_struct *fl_owner_t; =20 struct file_lock_operations { @@ -63489,15 +65592,13 @@ diff -urNp linux-2.6.32.49/include/linux/fs.h l= inux-2.6.32.49/include/linux/fs.h =20 struct inode_operations { int (*create) (struct inode *,struct dentry *,int, struct nameidata *)= ; -@@ -1559,30 +1560,30 @@ extern ssize_t vfs_writev(struct file *, +@@ -1559,30 +1560,30 @@ extern ssize_t vfs_writev(struct file *, const s= truct iovec __user *, unsigned long, loff_t *); =20 struct super_operations { - struct inode *(*alloc_inode)(struct super_block *sb); - void (*destroy_inode)(struct inode *); -+ struct inode *(* const alloc_inode)(struct super_block *sb); -+ void (* const destroy_inode)(struct inode *); -=20 +- - void (*dirty_inode) (struct inode *); - int (*write_inode) (struct inode *, int); - void (*drop_inode) (struct inode *); @@ -63511,6 +65612,12 @@ diff -urNp linux-2.6.32.49/include/linux/fs.h li= nux-2.6.32.49/include/linux/fs.h - int (*remount_fs) (struct super_block *, int *, char *); - void (*clear_inode) (struct inode *); - void (*umount_begin) (struct super_block *); +- +- int (*show_options)(struct seq_file *, struct vfsmount *); +- int (*show_stats)(struct seq_file *, struct vfsmount *); ++ struct inode *(* const alloc_inode)(struct super_block *sb); ++ void (* const destroy_inode)(struct inode *); ++ + void (* const dirty_inode) (struct inode *); + int (* const write_inode) (struct inode *, int); + void (* const drop_inode) (struct inode *); @@ -63524,9 +65631,7 @@ diff -urNp linux-2.6.32.49/include/linux/fs.h lin= ux-2.6.32.49/include/linux/fs.h + int (* const remount_fs) (struct super_block *, int *, char *); + void (* const clear_inode) (struct inode *); + void (* const umount_begin) (struct super_block *); -=20 -- int (*show_options)(struct seq_file *, struct vfsmount *); -- int (*show_stats)(struct seq_file *, struct vfsmount *); ++ + int (* const show_options)(struct seq_file *, struct vfsmount *); + int (* const show_stats)(struct seq_file *, struct vfsmount *); #ifdef CONFIG_QUOTA @@ -63540,9 +65645,10 @@ diff -urNp linux-2.6.32.49/include/linux/fs.h li= nux-2.6.32.49/include/linux/fs.h }; =20 /* -diff -urNp linux-2.6.32.49/include/linux/fs_struct.h linux-2.6.32.49/inc= lude/linux/fs_struct.h ---- linux-2.6.32.49/include/linux/fs_struct.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/include/linux/fs_struct.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/include/linux/fs_struct.h b/include/linux/fs_struct.h +index 78a05bf..2a7d3e1 100644 +--- a/include/linux/fs_struct.h ++++ b/include/linux/fs_struct.h @@ -4,7 +4,7 @@ #include =20 @@ -63552,10 +65658,33 @@ diff -urNp linux-2.6.32.49/include/linux/fs_str= uct.h linux-2.6.32.49/include/lin rwlock_t lock; int umask; int in_exec; -diff -urNp linux-2.6.32.49/include/linux/ftrace_event.h linux-2.6.32.49/= include/linux/ftrace_event.h ---- linux-2.6.32.49/include/linux/ftrace_event.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/include/linux/ftrace_event.h 2011-11-15 19:59:43.000= 000000 -0500 -@@ -163,7 +163,7 @@ extern int trace_define_field(struct ftr +diff --git a/include/linux/fscache-cache.h b/include/linux/fscache-cache= .h +index 7be0c6f..2f63a2b 100644 +--- a/include/linux/fscache-cache.h ++++ b/include/linux/fscache-cache.h +@@ -116,7 +116,7 @@ struct fscache_operation { + #endif + }; +=20 +-extern atomic_t fscache_op_debug_id; ++extern atomic_unchecked_t fscache_op_debug_id; + extern const struct slow_work_ops fscache_op_slow_work_ops; +=20 + extern void fscache_enqueue_operation(struct fscache_operation *); +@@ -134,7 +134,7 @@ static inline void fscache_operation_init(struct fsc= ache_operation *op, + fscache_operation_release_t release) + { + atomic_set(&op->usage, 1); +- op->debug_id =3D atomic_inc_return(&fscache_op_debug_id); ++ op->debug_id =3D atomic_inc_return_unchecked(&fscache_op_debug_id); + op->release =3D release; + INIT_LIST_HEAD(&op->pend_link); + fscache_set_op_state(op, "Init"); +diff --git a/include/linux/ftrace_event.h b/include/linux/ftrace_event.h +index 4ec5e67..42f1eb9 100644 +--- a/include/linux/ftrace_event.h ++++ b/include/linux/ftrace_event.h +@@ -163,7 +163,7 @@ extern int trace_define_field(struct ftrace_event_ca= ll *call, int filter_type); extern int trace_define_common_fields(struct ftrace_event_call *call); =20 @@ -63564,9 +65693,10 @@ diff -urNp linux-2.6.32.49/include/linux/ftrace_= event.h linux-2.6.32.49/include/ =20 int trace_set_clr_event(const char *system, const char *event, int set)= ; =20 -diff -urNp linux-2.6.32.49/include/linux/genhd.h linux-2.6.32.49/include= /linux/genhd.h ---- linux-2.6.32.49/include/linux/genhd.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/genhd.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/genhd.h b/include/linux/genhd.h +index 297df45..b6a74ff 100644 +--- a/include/linux/genhd.h ++++ b/include/linux/genhd.h @@ -161,7 +161,7 @@ struct gendisk { =20 struct timer_rand_state *random; @@ -63576,9 +65706,11 @@ diff -urNp linux-2.6.32.49/include/linux/genhd.h= linux-2.6.32.49/include/linux/g struct work_struct async_notify; #ifdef CONFIG_BLK_DEV_INTEGRITY struct blk_integrity *integrity; -diff -urNp linux-2.6.32.49/include/linux/gracl.h linux-2.6.32.49/include= /linux/gracl.h ---- linux-2.6.32.49/include/linux/gracl.h 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/gracl.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/gracl.h b/include/linux/gracl.h +new file mode 100644 +index 0000000..0dc3943 +--- /dev/null ++++ b/include/linux/gracl.h @@ -0,0 +1,317 @@ +#ifndef GR_ACL_H +#define GR_ACL_H @@ -63897,9 +66029,11 @@ diff -urNp linux-2.6.32.49/include/linux/gracl.h= linux-2.6.32.49/include/linux/g + +#endif + -diff -urNp linux-2.6.32.49/include/linux/gralloc.h linux-2.6.32.49/inclu= de/linux/gralloc.h ---- linux-2.6.32.49/include/linux/gralloc.h 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/gralloc.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/include/linux/gralloc.h b/include/linux/gralloc.h +new file mode 100644 +index 0000000..323ecf2 +--- /dev/null ++++ b/include/linux/gralloc.h @@ -0,0 +1,9 @@ +#ifndef __GRALLOC_H +#define __GRALLOC_H @@ -63910,9 +66044,11 @@ diff -urNp linux-2.6.32.49/include/linux/gralloc= .h linux-2.6.32.49/include/linux +void *acl_alloc_num(unsigned long num, unsigned long len); + +#endif -diff -urNp linux-2.6.32.49/include/linux/grdefs.h linux-2.6.32.49/includ= e/linux/grdefs.h ---- linux-2.6.32.49/include/linux/grdefs.h 1969-12-31 19:00:00.000000000= -0500 -+++ linux-2.6.32.49/include/linux/grdefs.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/grdefs.h b/include/linux/grdefs.h +new file mode 100644 +index 0000000..70d6cd5 +--- /dev/null ++++ b/include/linux/grdefs.h @@ -0,0 +1,140 @@ +#ifndef GRDEFS_H +#define GRDEFS_H @@ -64054,9 +66190,11 @@ diff -urNp linux-2.6.32.49/include/linux/grdefs.= h linux-2.6.32.49/include/linux/ +}; + +#endif -diff -urNp linux-2.6.32.49/include/linux/grinternal.h linux-2.6.32.49/in= clude/linux/grinternal.h ---- linux-2.6.32.49/include/linux/grinternal.h 1969-12-31 19:00:00.00000= 0000 -0500 -+++ linux-2.6.32.49/include/linux/grinternal.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/linux/grinternal.h b/include/linux/grinternal.h +new file mode 100644 +index 0000000..e5817d7 +--- /dev/null ++++ b/include/linux/grinternal.h @@ -0,0 +1,218 @@ +#ifndef __GRINTERNAL_H +#define __GRINTERNAL_H @@ -64276,9 +66414,11 @@ diff -urNp linux-2.6.32.49/include/linux/grinter= nal.h linux-2.6.32.49/include/li +#endif + +#endif -diff -urNp linux-2.6.32.49/include/linux/grmsg.h linux-2.6.32.49/include= /linux/grmsg.h ---- linux-2.6.32.49/include/linux/grmsg.h 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/grmsg.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/grmsg.h b/include/linux/grmsg.h +new file mode 100644 +index 0000000..9d5fd4a +--- /dev/null ++++ b/include/linux/grmsg.h @@ -0,0 +1,108 @@ +#define DEFAULTSECMSG "%.256s[%.16s:%d] uid/euid:%u/%u gid/egid:%u/%u, = parent %.256s[%.16s:%d] uid/euid:%u/%u gid/egid:%u/%u" +#define GR_ACL_PROCACCT_MSG "%.256s[%.16s:%d] IP:%pI4 TTY:%.64s uid/eui= d:%u/%u gid/egid:%u/%u run time:[%ud %uh %um %us] cpu time:[%ud %uh %um %= us] %s with exit code %ld, parent %.256s[%.16s:%d] IP:%pI4 TTY:%.64s uid/= euid:%u/%u gid/egid:%u/%u" @@ -64388,9 +66528,11 @@ diff -urNp linux-2.6.32.49/include/linux/grmsg.h= linux-2.6.32.49/include/linux/g +#define GR_VM86_MSG "denied use of vm86 by " +#define GR_PTRACE_AUDIT_MSG "process %.950s(%.16s:%d) attached to via p= trace by " +#define GR_INIT_TRANSFER_MSG "persistent special role transferred privi= lege to init by " -diff -urNp linux-2.6.32.49/include/linux/grsecurity.h linux-2.6.32.49/in= clude/linux/grsecurity.h ---- linux-2.6.32.49/include/linux/grsecurity.h 1969-12-31 19:00:00.00000= 0000 -0500 -+++ linux-2.6.32.49/include/linux/grsecurity.h 2011-11-18 19:31:08.00000= 0000 -0500 +diff --git a/include/linux/grsecurity.h b/include/linux/grsecurity.h +new file mode 100644 +index 0000000..24676f4 +--- /dev/null ++++ b/include/linux/grsecurity.h @@ -0,0 +1,218 @@ +#ifndef GR_SECURITY_H +#define GR_SECURITY_H @@ -64610,9 +66752,10 @@ diff -urNp linux-2.6.32.49/include/linux/grsecur= ity.h linux-2.6.32.49/include/li +#endif + +#endif -diff -urNp linux-2.6.32.49/include/linux/hdpu_features.h linux-2.6.32.49= /include/linux/hdpu_features.h ---- linux-2.6.32.49/include/linux/hdpu_features.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/linux/hdpu_features.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/include/linux/hdpu_features.h b/include/linux/hdpu_features= .h +index 6a87154..a3ce57b 100644 +--- a/include/linux/hdpu_features.h ++++ b/include/linux/hdpu_features.h @@ -3,7 +3,7 @@ struct cpustate_t { spinlock_t lock; @@ -64622,10 +66765,11 @@ diff -urNp linux-2.6.32.49/include/linux/hdpu_f= eatures.h linux-2.6.32.49/include unsigned char cached_val; int inited; unsigned long *set_addr; -diff -urNp linux-2.6.32.49/include/linux/highmem.h linux-2.6.32.49/inclu= de/linux/highmem.h ---- linux-2.6.32.49/include/linux/highmem.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/highmem.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -137,6 +137,18 @@ static inline void clear_highpage(struct +diff --git a/include/linux/highmem.h b/include/linux/highmem.h +index 211ff44..00ab6d7 100644 +--- a/include/linux/highmem.h ++++ b/include/linux/highmem.h +@@ -137,6 +137,18 @@ static inline void clear_highpage(struct page *page= ) kunmap_atomic(kaddr, KM_USER0); } =20 @@ -64644,9 +66788,10 @@ diff -urNp linux-2.6.32.49/include/linux/highmem= .h linux-2.6.32.49/include/linux static inline void zero_user_segments(struct page *page, unsigned start1, unsigned end1, unsigned start2, unsigned end2) -diff -urNp linux-2.6.32.49/include/linux/i2c.h linux-2.6.32.49/include/l= inux/i2c.h ---- linux-2.6.32.49/include/linux/i2c.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/i2c.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/linux/i2c.h b/include/linux/i2c.h +index 7b40cda..24eb44e 100644 +--- a/include/linux/i2c.h ++++ b/include/linux/i2c.h @@ -325,6 +325,7 @@ struct i2c_algorithm { /* To determine what the adapter supports */ u32 (*functionality) (struct i2c_adapter *); @@ -64655,9 +66800,10 @@ diff -urNp linux-2.6.32.49/include/linux/i2c.h l= inux-2.6.32.49/include/linux/i2c =20 /* * i2c_adapter is the structure used to identify a physical i2c bus alo= ng -diff -urNp linux-2.6.32.49/include/linux/i2o.h linux-2.6.32.49/include/l= inux/i2o.h ---- linux-2.6.32.49/include/linux/i2o.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/i2o.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/linux/i2o.h b/include/linux/i2o.h +index 4c4e57d..f3c5303 100644 +--- a/include/linux/i2o.h ++++ b/include/linux/i2o.h @@ -564,7 +564,7 @@ struct i2o_controller { struct i2o_device *exec; /* Executive */ #if BITS_PER_LONG =3D=3D 64 @@ -64667,9 +66813,10 @@ diff -urNp linux-2.6.32.49/include/linux/i2o.h l= inux-2.6.32.49/include/linux/i2o struct list_head context_list; /* list of context id's and pointers */ #endif -diff -urNp linux-2.6.32.49/include/linux/init_task.h linux-2.6.32.49/inc= lude/linux/init_task.h ---- linux-2.6.32.49/include/linux/init_task.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/include/linux/init_task.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/include/linux/init_task.h b/include/linux/init_task.h +index 21a6f5d..dc42eab 100644 +--- a/include/linux/init_task.h ++++ b/include/linux/init_task.h @@ -83,6 +83,12 @@ extern struct group_info init_groups; #define INIT_IDS #endif @@ -64691,9 +66838,10 @@ diff -urNp linux-2.6.32.49/include/linux/init_ta= sk.h linux-2.6.32.49/include/lin .fs =3D &init_fs, \ .files =3D &init_files, \ .signal =3D &init_signals, \ -diff -urNp linux-2.6.32.49/include/linux/intel-iommu.h linux-2.6.32.49/i= nclude/linux/intel-iommu.h ---- linux-2.6.32.49/include/linux/intel-iommu.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/linux/intel-iommu.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/linux/intel-iommu.h b/include/linux/intel-iommu.h +index 4f0a72a..a849599 100644 +--- a/include/linux/intel-iommu.h ++++ b/include/linux/intel-iommu.h @@ -296,7 +296,7 @@ struct iommu_flush { u8 fm, u64 type); void (*flush_iotlb)(struct intel_iommu *iommu, u16 did, u64 addr, @@ -64703,9 +66851,10 @@ diff -urNp linux-2.6.32.49/include/linux/intel-i= ommu.h linux-2.6.32.49/include/l =20 enum { SR_DMAR_FECTL_REG, -diff -urNp linux-2.6.32.49/include/linux/interrupt.h linux-2.6.32.49/inc= lude/linux/interrupt.h ---- linux-2.6.32.49/include/linux/interrupt.h 2011-11-26 19:44:53.000000= 000 -0500 -+++ linux-2.6.32.49/include/linux/interrupt.h 2011-11-26 19:45:13.000000= 000 -0500 +diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h +index c739150..be577b5 100644 +--- a/include/linux/interrupt.h ++++ b/include/linux/interrupt.h @@ -369,7 +369,7 @@ enum /* map softirq index to softirq name. update 'softirq_to_name' in * kernel/softirq.c when adding a new softirq. @@ -64715,7 +66864,7 @@ diff -urNp linux-2.6.32.49/include/linux/interrup= t.h linux-2.6.32.49/include/lin =20 /* softirq mask and active fields moved to irq_cpustat_t in * asm/hardirq.h to get better cache usage. KAO -@@ -377,12 +377,12 @@ extern char *softirq_to_name[NR_SOFTIRQS +@@ -377,12 +377,12 @@ extern char *softirq_to_name[NR_SOFTIRQS]; =20 struct softirq_action { @@ -64730,10 +66879,11 @@ diff -urNp linux-2.6.32.49/include/linux/interr= upt.h linux-2.6.32.49/include/lin extern void softirq_init(void); #define __raise_softirq_irqoff(nr) do { or_softirq_pending(1UL << (nr))= ; } while (0) extern void raise_softirq_irqoff(unsigned int nr); -diff -urNp linux-2.6.32.49/include/linux/irq.h linux-2.6.32.49/include/l= inux/irq.h ---- linux-2.6.32.49/include/linux/irq.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/irq.h 2011-11-15 19:59:43.000000000 -0= 500 -@@ -438,12 +438,12 @@ extern int set_irq_msi(unsigned int irq, +diff --git a/include/linux/irq.h b/include/linux/irq.h +index 9e5f45a..025865b 100644 +--- a/include/linux/irq.h ++++ b/include/linux/irq.h +@@ -438,12 +438,12 @@ extern int set_irq_msi(unsigned int irq, struct ms= i_desc *entry); static inline bool alloc_desc_masks(struct irq_desc *desc, int node, bool boot) { @@ -64747,9 +66897,10 @@ diff -urNp linux-2.6.32.49/include/linux/irq.h l= inux-2.6.32.49/include/linux/irq if (!alloc_cpumask_var_node(&desc->affinity, gfp, node)) return false; =20 -diff -urNp linux-2.6.32.49/include/linux/kallsyms.h linux-2.6.32.49/incl= ude/linux/kallsyms.h ---- linux-2.6.32.49/include/linux/kallsyms.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/kallsyms.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h +index 7922742..27306a2 100644 +--- a/include/linux/kallsyms.h ++++ b/include/linux/kallsyms.h @@ -15,7 +15,8 @@ =20 struct module; @@ -64760,7 +66911,7 @@ diff -urNp linux-2.6.32.49/include/linux/kallsyms= .h linux-2.6.32.49/include/linu /* Lookup the address for a symbol. Returns 0 if not found. */ unsigned long kallsyms_lookup_name(const char *name); =20 -@@ -92,6 +93,15 @@ static inline int lookup_symbol_attrs(un +@@ -92,6 +93,15 @@ static inline int lookup_symbol_attrs(unsigned long a= ddr, unsigned long *size, u /* Stupid that this does nothing, but I didn't create this mess. */ #define __print_symbol(fmt, addr) #endif /*CONFIG_KALLSYMS*/ @@ -64776,9 +66927,10 @@ diff -urNp linux-2.6.32.49/include/linux/kallsym= s.h linux-2.6.32.49/include/linu =20 /* This macro allows us to keep printk typechecking */ static void __check_printsym_format(const char *fmt, ...) -diff -urNp linux-2.6.32.49/include/linux/kgdb.h linux-2.6.32.49/include/= linux/kgdb.h ---- linux-2.6.32.49/include/linux/kgdb.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/include/linux/kgdb.h 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/include/linux/kgdb.h b/include/linux/kgdb.h +index 6adcc29..13369e8 100644 +--- a/include/linux/kgdb.h ++++ b/include/linux/kgdb.h @@ -74,8 +74,8 @@ void kgdb_breakpoint(void); =20 extern int kgdb_connected; @@ -64818,9 +66970,10 @@ diff -urNp linux-2.6.32.49/include/linux/kgdb.h = linux-2.6.32.49/include/linux/kg =20 extern int kgdb_hex2long(char **ptr, unsigned long *long_val); extern int kgdb_mem2hex(char *mem, char *buf, int count); -diff -urNp linux-2.6.32.49/include/linux/kmod.h linux-2.6.32.49/include/= linux/kmod.h ---- linux-2.6.32.49/include/linux/kmod.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/include/linux/kmod.h 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/include/linux/kmod.h b/include/linux/kmod.h +index 384ca8b..83dd97d 100644 +--- a/include/linux/kmod.h ++++ b/include/linux/kmod.h @@ -31,6 +31,8 @@ * usually useless though. */ extern int __request_module(bool wait, const char *name, ...) \ @@ -64830,10 +66983,11 @@ diff -urNp linux-2.6.32.49/include/linux/kmod.h= linux-2.6.32.49/include/linux/km #define request_module(mod...) __request_module(true, mod) #define request_module_nowait(mod...) __request_module(false, mod) #define try_then_request_module(x, mod...) \ -diff -urNp linux-2.6.32.49/include/linux/kobject.h linux-2.6.32.49/inclu= de/linux/kobject.h ---- linux-2.6.32.49/include/linux/kobject.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/kobject.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -106,7 +106,7 @@ extern char *kobject_get_path(struct kob +diff --git a/include/linux/kobject.h b/include/linux/kobject.h +index 58ae8e0..3950d3c 100644 +--- a/include/linux/kobject.h ++++ b/include/linux/kobject.h +@@ -106,7 +106,7 @@ extern char *kobject_get_path(struct kobject *kobj, = gfp_t flag); =20 struct kobj_type { void (*release)(struct kobject *kobj); @@ -64881,10 +67035,11 @@ diff -urNp linux-2.6.32.49/include/linux/kobjec= t.h linux-2.6.32.49/include/linux struct kobject *parent_kobj); =20 static inline struct kset *to_kset(struct kobject *kobj) -diff -urNp linux-2.6.32.49/include/linux/kvm_host.h linux-2.6.32.49/incl= ude/linux/kvm_host.h ---- linux-2.6.32.49/include/linux/kvm_host.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/kvm_host.h 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -210,7 +210,7 @@ void kvm_vcpu_uninit(struct kvm_vcpu *vc +diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h +index c728a50..752d821 100644 +--- a/include/linux/kvm_host.h ++++ b/include/linux/kvm_host.h +@@ -210,7 +210,7 @@ void kvm_vcpu_uninit(struct kvm_vcpu *vcpu); void vcpu_load(struct kvm_vcpu *vcpu); void vcpu_put(struct kvm_vcpu *vcpu); =20 @@ -64893,7 +67048,7 @@ diff -urNp linux-2.6.32.49/include/linux/kvm_host= .h linux-2.6.32.49/include/linu struct module *module); void kvm_exit(void); =20 -@@ -316,7 +316,7 @@ int kvm_arch_vcpu_ioctl_set_guest_debug( +@@ -316,7 +316,7 @@ int kvm_arch_vcpu_ioctl_set_guest_debug(struct kvm_v= cpu *vcpu, struct kvm_guest_debug *dbg); int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu, struct kvm_run *kvm_= run); =20 @@ -64902,9 +67057,10 @@ diff -urNp linux-2.6.32.49/include/linux/kvm_hos= t.h linux-2.6.32.49/include/linu void kvm_arch_exit(void); =20 int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu); -diff -urNp linux-2.6.32.49/include/linux/libata.h linux-2.6.32.49/includ= e/linux/libata.h ---- linux-2.6.32.49/include/linux/libata.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/libata.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/libata.h b/include/linux/libata.h +index a069916..223edde 100644 +--- a/include/linux/libata.h ++++ b/include/linux/libata.h @@ -525,11 +525,11 @@ struct ata_ioports { =20 struct ata_host { @@ -64946,7 +67102,7 @@ diff -urNp linux-2.6.32.49/include/linux/libata.h= linux-2.6.32.49/include/linux/ void *private_data; }; =20 -@@ -916,7 +916,7 @@ extern const unsigned long sata_deb_timi +@@ -916,7 +916,7 @@ extern const unsigned long sata_deb_timing_normal[]; extern const unsigned long sata_deb_timing_hotplug[]; extern const unsigned long sata_deb_timing_long[]; =20 @@ -64955,7 +67111,7 @@ diff -urNp linux-2.6.32.49/include/linux/libata.h= linux-2.6.32.49/include/linux/ extern const struct ata_port_info ata_dummy_port_info; =20 static inline const unsigned long * -@@ -962,7 +962,7 @@ extern int ata_host_activate(struct ata_ +@@ -962,7 +962,7 @@ extern int ata_host_activate(struct ata_host *host, = int irq, struct scsi_host_template *sht); extern void ata_host_detach(struct ata_host *host); extern void ata_host_init(struct ata_host *, struct device *, @@ -64964,9 +67120,10 @@ diff -urNp linux-2.6.32.49/include/linux/libata.= h linux-2.6.32.49/include/linux/ extern int ata_scsi_detect(struct scsi_host_template *sht); extern int ata_scsi_ioctl(struct scsi_device *dev, int cmd, void __user= *arg); extern int ata_scsi_queuecmd(struct scsi_cmnd *cmd, void (*done)(struct= scsi_cmnd *)); -diff -urNp linux-2.6.32.49/include/linux/lockd/bind.h linux-2.6.32.49/in= clude/linux/lockd/bind.h ---- linux-2.6.32.49/include/linux/lockd/bind.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/linux/lockd/bind.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/linux/lockd/bind.h b/include/linux/lockd/bind.h +index fbc48f8..0886e57 100644 +--- a/include/linux/lockd/bind.h ++++ b/include/linux/lockd/bind.h @@ -23,13 +23,13 @@ struct svc_rqst; * This is the set of functions for lockd->nfsd communication */ @@ -64984,9 +67141,10 @@ diff -urNp linux-2.6.32.49/include/linux/lockd/b= ind.h linux-2.6.32.49/include/li =20 /* * Similar to nfs_client_initdata, but without the NFS-specific -diff -urNp linux-2.6.32.49/include/linux/mca.h linux-2.6.32.49/include/l= inux/mca.h ---- linux-2.6.32.49/include/linux/mca.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/mca.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/linux/mca.h b/include/linux/mca.h +index 3797270..7765ede 100644 +--- a/include/linux/mca.h ++++ b/include/linux/mca.h @@ -80,7 +80,7 @@ struct mca_bus_accessor_functions { int region); void * (*mca_transform_memory)(struct mca_device *, @@ -64996,9 +67154,10 @@ diff -urNp linux-2.6.32.49/include/linux/mca.h l= inux-2.6.32.49/include/linux/mca =20 struct mca_bus { u64 default_dma_mask; -diff -urNp linux-2.6.32.49/include/linux/memory.h linux-2.6.32.49/includ= e/linux/memory.h ---- linux-2.6.32.49/include/linux/memory.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/memory.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/memory.h b/include/linux/memory.h +index 37fa19b..b597c85 100644 +--- a/include/linux/memory.h ++++ b/include/linux/memory.h @@ -108,7 +108,7 @@ struct memory_accessor { size_t count); ssize_t (*write)(struct memory_accessor *, const char *buf, @@ -65008,10 +67167,11 @@ diff -urNp linux-2.6.32.49/include/linux/memory= .h linux-2.6.32.49/include/linux/ =20 /* * Kernel text modification mutex, used for code patching. Users of thi= s lock -diff -urNp linux-2.6.32.49/include/linux/mm.h linux-2.6.32.49/include/li= nux/mm.h ---- linux-2.6.32.49/include/linux/mm.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/include/linux/mm.h 2011-11-15 19:59:43.000000000 -05= 00 -@@ -106,7 +106,14 @@ extern unsigned int kobjsize(const void=20 +diff --git a/include/linux/mm.h b/include/linux/mm.h +index 11e5be6..1ff2423 100644 +--- a/include/linux/mm.h ++++ b/include/linux/mm.h +@@ -106,7 +106,14 @@ extern unsigned int kobjsize(const void *objp); =20 #define VM_CAN_NONLINEAR 0x08000000 /* Has ->fault & does nonlinear pag= es */ #define VM_MIXEDMAP 0x10000000 /* Can contain "struct page" and pure PF= N pages */ @@ -65056,7 +67216,7 @@ diff -urNp linux-2.6.32.49/include/linux/mm.h lin= ux-2.6.32.49/include/linux/mm.h =20 extern unsigned long do_brk(unsigned long, unsigned long); =20 -@@ -1218,6 +1222,10 @@ extern struct vm_area_struct * find_vma( +@@ -1218,6 +1222,10 @@ extern struct vm_area_struct * find_vma(struct mm= _struct * mm, unsigned long add extern struct vm_area_struct * find_vma_prev(struct mm_struct * mm, uns= igned long addr, struct vm_area_struct **pprev); =20 @@ -65067,7 +67227,7 @@ diff -urNp linux-2.6.32.49/include/linux/mm.h lin= ux-2.6.32.49/include/linux/mm.h /* Look up the first VMA which intersects the interval start_addr..end_= addr-1, NULL if none. Assume start_addr < end_addr. */ static inline struct vm_area_struct * find_vma_intersection(struct mm_s= truct * mm, unsigned long start_addr, unsigned long end_addr) -@@ -1234,7 +1242,6 @@ static inline unsigned long vma_pages(st +@@ -1234,7 +1242,6 @@ static inline unsigned long vma_pages(struct vm_ar= ea_struct *vma) return (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; } =20 @@ -65075,7 +67235,7 @@ diff -urNp linux-2.6.32.49/include/linux/mm.h lin= ux-2.6.32.49/include/linux/mm.h struct vm_area_struct *find_extend_vma(struct mm_struct *, unsigned lon= g addr); int remap_pfn_range(struct vm_area_struct *, unsigned long addr, unsigned long pfn, unsigned long size, pgprot_t); -@@ -1332,7 +1339,13 @@ extern void memory_failure(unsigned long +@@ -1332,7 +1339,13 @@ extern void memory_failure(unsigned long pfn, int= trapno); extern int __memory_failure(unsigned long pfn, int trapno, int ref); extern int sysctl_memory_failure_early_kill; extern int sysctl_memory_failure_recovery; @@ -65090,9 +67250,10 @@ diff -urNp linux-2.6.32.49/include/linux/mm.h li= nux-2.6.32.49/include/linux/mm.h =20 #endif /* __KERNEL__ */ #endif /* _LINUX_MM_H */ -diff -urNp linux-2.6.32.49/include/linux/mm_types.h linux-2.6.32.49/incl= ude/linux/mm_types.h ---- linux-2.6.32.49/include/linux/mm_types.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/mm_types.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h +index 9d12ed5..8023125 100644 +--- a/include/linux/mm_types.h ++++ b/include/linux/mm_types.h @@ -186,6 +186,8 @@ struct vm_area_struct { #ifdef CONFIG_NUMA struct mempolicy *vm_policy; /* NUMA policy for the VMA */ @@ -65127,10 +67288,11 @@ diff -urNp linux-2.6.32.49/include/linux/mm_typ= es.h linux-2.6.32.49/include/linu }; =20 /* Future-safe accessor for struct mm_struct's cpu_vm_mask. */ -diff -urNp linux-2.6.32.49/include/linux/mmu_notifier.h linux-2.6.32.49/= include/linux/mmu_notifier.h ---- linux-2.6.32.49/include/linux/mmu_notifier.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/include/linux/mmu_notifier.h 2011-11-15 19:59:43.000= 000000 -0500 -@@ -235,12 +235,12 @@ static inline void mmu_notifier_mm_destr +diff --git a/include/linux/mmu_notifier.h b/include/linux/mmu_notifier.h +index 4e02ee2..afb159e 100644 +--- a/include/linux/mmu_notifier.h ++++ b/include/linux/mmu_notifier.h +@@ -235,12 +235,12 @@ static inline void mmu_notifier_mm_destroy(struct = mm_struct *mm) */ #define ptep_clear_flush_notify(__vma, __address, __ptep) \ ({ \ @@ -65146,9 +67308,10 @@ diff -urNp linux-2.6.32.49/include/linux/mmu_not= ifier.h linux-2.6.32.49/include/ }) =20 #define ptep_clear_flush_young_notify(__vma, __address, __ptep) \ -diff -urNp linux-2.6.32.49/include/linux/mmzone.h linux-2.6.32.49/includ= e/linux/mmzone.h ---- linux-2.6.32.49/include/linux/mmzone.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/mmzone.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h +index 6c31a2a..4b0e930 100644 +--- a/include/linux/mmzone.h ++++ b/include/linux/mmzone.h @@ -350,7 +350,7 @@ struct zone { unsigned long flags; /* zone flags, see below */ =20 @@ -65158,9 +67321,10 @@ diff -urNp linux-2.6.32.49/include/linux/mmzone.= h linux-2.6.32.49/include/linux/ =20 /* * prev_priority holds the scanning priority for this zone. It is -diff -urNp linux-2.6.32.49/include/linux/mod_devicetable.h linux-2.6.32.= 49/include/linux/mod_devicetable.h ---- linux-2.6.32.49/include/linux/mod_devicetable.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/include/linux/mod_devicetable.h 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicet= able.h +index f58e9d8..3503935 100644 +--- a/include/linux/mod_devicetable.h ++++ b/include/linux/mod_devicetable.h @@ -12,7 +12,7 @@ typedef unsigned long kernel_ulong_t; #endif @@ -65179,9 +67343,10 @@ diff -urNp linux-2.6.32.49/include/linux/mod_dev= icetable.h linux-2.6.32.49/inclu =20 struct hid_device_id { __u16 bus; -diff -urNp linux-2.6.32.49/include/linux/module.h linux-2.6.32.49/includ= e/linux/module.h ---- linux-2.6.32.49/include/linux/module.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/module.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/module.h b/include/linux/module.h +index 482efc8..642032b 100644 +--- a/include/linux/module.h ++++ b/include/linux/module.h @@ -16,6 +16,7 @@ #include #include @@ -65222,7 +67387,7 @@ diff -urNp linux-2.6.32.49/include/linux/module.h= linux-2.6.32.49/include/linux/ #endif #ifdef CONFIG_FTRACE_MCOUNT_RECORD unsigned long *ftrace_callsites; -@@ -393,16 +398,46 @@ struct module *__module_address(unsigned +@@ -393,16 +398,46 @@ struct module *__module_address(unsigned long addr= ); bool is_module_address(unsigned long addr); bool is_module_text_address(unsigned long addr); =20 @@ -65273,10 +67438,11 @@ diff -urNp linux-2.6.32.49/include/linux/module= .h linux-2.6.32.49/include/linux/ } =20 /* Search for module by name: must hold module_mutex. */ -diff -urNp linux-2.6.32.49/include/linux/moduleloader.h linux-2.6.32.49/= include/linux/moduleloader.h ---- linux-2.6.32.49/include/linux/moduleloader.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/include/linux/moduleloader.h 2011-11-15 19:59:43.000= 000000 -0500 -@@ -20,9 +20,21 @@ unsigned int arch_mod_section_prepend(st +diff --git a/include/linux/moduleloader.h b/include/linux/moduleloader.h +index c1f40c2..682ca53 100644 +--- a/include/linux/moduleloader.h ++++ b/include/linux/moduleloader.h +@@ -20,9 +20,21 @@ unsigned int arch_mod_section_prepend(struct module *= mod, unsigned int section); sections. Returns NULL on failure. */ void *module_alloc(unsigned long size); =20 @@ -65298,9 +67464,10 @@ diff -urNp linux-2.6.32.49/include/linux/modulel= oader.h linux-2.6.32.49/include/ /* Apply the given relocation to the (simplified) ELF. Return -error or 0. */ int apply_relocate(Elf_Shdr *sechdrs, -diff -urNp linux-2.6.32.49/include/linux/moduleparam.h linux-2.6.32.49/i= nclude/linux/moduleparam.h ---- linux-2.6.32.49/include/linux/moduleparam.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/linux/moduleparam.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/linux/moduleparam.h b/include/linux/moduleparam.h +index 82a9124..8a5f622 100644 +--- a/include/linux/moduleparam.h ++++ b/include/linux/moduleparam.h @@ -132,7 +132,7 @@ struct kparam_array =20 /* Actually copy string: maxlen param is usually sizeof(string). */ @@ -65310,7 +67477,7 @@ diff -urNp linux-2.6.32.49/include/linux/modulepa= ram.h linux-2.6.32.49/include/l =3D { len, string }; \ __module_param_call(MODULE_PARAM_PREFIX, name, \ param_set_copystring, param_get_string, \ -@@ -211,7 +211,7 @@ extern int param_get_invbool(char *buffe +@@ -211,7 +211,7 @@ extern int param_get_invbool(char *buffer, struct ke= rnel_param *kp); =20 /* Comma-separated array: *nump is set to number they actually specifie= d. */ #define module_param_array_named(name, array, type, nump, perm) \ @@ -65319,9 +67486,10 @@ diff -urNp linux-2.6.32.49/include/linux/modulep= aram.h linux-2.6.32.49/include/l =3D { ARRAY_SIZE(array), nump, param_set_##type, param_get_##type,\ sizeof(array[0]), array }; \ __module_param_call(MODULE_PARAM_PREFIX, name, \ -diff -urNp linux-2.6.32.49/include/linux/mutex.h linux-2.6.32.49/include= /linux/mutex.h ---- linux-2.6.32.49/include/linux/mutex.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/mutex.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/mutex.h b/include/linux/mutex.h +index 878cab4..c92cb3e 100644 +--- a/include/linux/mutex.h ++++ b/include/linux/mutex.h @@ -51,7 +51,7 @@ struct mutex { spinlock_t wait_lock; struct list_head wait_list; @@ -65331,9 +67499,10 @@ diff -urNp linux-2.6.32.49/include/linux/mutex.h= linux-2.6.32.49/include/linux/m #endif #ifdef CONFIG_DEBUG_MUTEXES const char *name; -diff -urNp linux-2.6.32.49/include/linux/namei.h linux-2.6.32.49/include= /linux/namei.h ---- linux-2.6.32.49/include/linux/namei.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/namei.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/namei.h b/include/linux/namei.h +index ec0f607..d19e675 100644 +--- a/include/linux/namei.h ++++ b/include/linux/namei.h @@ -22,7 +22,7 @@ struct nameidata { unsigned int flags; int last_type; @@ -65358,9 +67527,10 @@ diff -urNp linux-2.6.32.49/include/linux/namei.h= linux-2.6.32.49/include/linux/n { return nd->saved_names[nd->depth]; } -diff -urNp linux-2.6.32.49/include/linux/netdevice.h linux-2.6.32.49/inc= lude/linux/netdevice.h ---- linux-2.6.32.49/include/linux/netdevice.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/include/linux/netdevice.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h +index 9d7e8f7..04428c5 100644 +--- a/include/linux/netdevice.h ++++ b/include/linux/netdevice.h @@ -637,6 +637,7 @@ struct net_device_ops { u16 xid); #endif @@ -65369,9 +67539,11 @@ diff -urNp linux-2.6.32.49/include/linux/netdevi= ce.h linux-2.6.32.49/include/lin =20 /* * The DEVICE structure. -diff -urNp linux-2.6.32.49/include/linux/netfilter/xt_gradm.h linux-2.6.= 32.49/include/linux/netfilter/xt_gradm.h ---- linux-2.6.32.49/include/linux/netfilter/xt_gradm.h 1969-12-31 19:00:= 00.000000000 -0500 -+++ linux-2.6.32.49/include/linux/netfilter/xt_gradm.h 2011-11-15 19:59:= 43.000000000 -0500 +diff --git a/include/linux/netfilter/xt_gradm.h b/include/linux/netfilte= r/xt_gradm.h +new file mode 100644 +index 0000000..33f4af8 +--- /dev/null ++++ b/include/linux/netfilter/xt_gradm.h @@ -0,0 +1,9 @@ +#ifndef _LINUX_NETFILTER_XT_GRADM_H +#define _LINUX_NETFILTER_XT_GRADM_H 1 @@ -65382,10 +67554,11 @@ diff -urNp linux-2.6.32.49/include/linux/netfil= ter/xt_gradm.h linux-2.6.32.49/in +}; + +#endif -diff -urNp linux-2.6.32.49/include/linux/nodemask.h linux-2.6.32.49/incl= ude/linux/nodemask.h ---- linux-2.6.32.49/include/linux/nodemask.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/nodemask.h 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -464,11 +464,11 @@ static inline int num_node_state(enum no +diff --git a/include/linux/nodemask.h b/include/linux/nodemask.h +index b359c4a..c08b334 100644 +--- a/include/linux/nodemask.h ++++ b/include/linux/nodemask.h +@@ -464,11 +464,11 @@ static inline int num_node_state(enum node_states = state) =20 #define any_online_node(mask) \ ({ \ @@ -65401,10 +67574,11 @@ diff -urNp linux-2.6.32.49/include/linux/nodema= sk.h linux-2.6.32.49/include/linu }) =20 #define num_online_nodes() num_node_state(N_ONLINE) -diff -urNp linux-2.6.32.49/include/linux/oprofile.h linux-2.6.32.49/incl= ude/linux/oprofile.h ---- linux-2.6.32.49/include/linux/oprofile.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/oprofile.h 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -129,9 +129,9 @@ int oprofilefs_create_ulong(struct super +diff --git a/include/linux/oprofile.h b/include/linux/oprofile.h +index 5171639..7cf4235 100644 +--- a/include/linux/oprofile.h ++++ b/include/linux/oprofile.h +@@ -129,9 +129,9 @@ int oprofilefs_create_ulong(struct super_block * sb,= struct dentry * root, int oprofilefs_create_ro_ulong(struct super_block * sb, struct dentry *= root, char const * name, ulong * val); =20 @@ -65416,10 +67590,11 @@ diff -urNp linux-2.6.32.49/include/linux/oprofi= le.h linux-2.6.32.49/include/linu =20 /** create a directory */ struct dentry * oprofilefs_mkdir(struct super_block * sb, struct dentry= * root, -diff -urNp linux-2.6.32.49/include/linux/pagemap.h linux-2.6.32.49/inclu= de/linux/pagemap.h ---- linux-2.6.32.49/include/linux/pagemap.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/pagemap.h 2011-11-18 18:01:55.00000000= 0 -0500 -@@ -425,7 +425,9 @@ static inline int fault_in_pages_readabl +diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h +index 3c62ed4..8924c7c 100644 +--- a/include/linux/pagemap.h ++++ b/include/linux/pagemap.h +@@ -425,7 +425,9 @@ static inline int fault_in_pages_readable(const char= __user *uaddr, int size) if (((unsigned long)uaddr & PAGE_MASK) !=3D ((unsigned long)end & PAGE_MASK)) ret =3D __get_user(c, end); @@ -65429,9 +67604,10 @@ diff -urNp linux-2.6.32.49/include/linux/pagemap= .h linux-2.6.32.49/include/linux return ret; } =20 -diff -urNp linux-2.6.32.49/include/linux/perf_event.h linux-2.6.32.49/in= clude/linux/perf_event.h ---- linux-2.6.32.49/include/linux/perf_event.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/linux/perf_event.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h +index 81c9689..a567a55 100644 +--- a/include/linux/perf_event.h ++++ b/include/linux/perf_event.h @@ -476,7 +476,7 @@ struct hw_perf_event { struct hrtimer hrtimer; }; @@ -65461,9 +67637,10 @@ diff -urNp linux-2.6.32.49/include/linux/perf_ev= ent.h linux-2.6.32.49/include/li =20 /* * Protect attach/detach and child_list: -diff -urNp linux-2.6.32.49/include/linux/pipe_fs_i.h linux-2.6.32.49/inc= lude/linux/pipe_fs_i.h ---- linux-2.6.32.49/include/linux/pipe_fs_i.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/include/linux/pipe_fs_i.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/include/linux/pipe_fs_i.h b/include/linux/pipe_fs_i.h +index b43a9e0..b77d869 100644 +--- a/include/linux/pipe_fs_i.h ++++ b/include/linux/pipe_fs_i.h @@ -46,9 +46,9 @@ struct pipe_inode_info { wait_queue_head_t wait; unsigned int nrbufs, curbuf; @@ -65477,9 +67654,10 @@ diff -urNp linux-2.6.32.49/include/linux/pipe_fs= _i.h linux-2.6.32.49/include/lin unsigned int r_counter; unsigned int w_counter; struct fasync_struct *fasync_readers; -diff -urNp linux-2.6.32.49/include/linux/poison.h linux-2.6.32.49/includ= e/linux/poison.h ---- linux-2.6.32.49/include/linux/poison.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/poison.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/poison.h b/include/linux/poison.h +index 34066ff..e95d744 100644 +--- a/include/linux/poison.h ++++ b/include/linux/poison.h @@ -19,8 +19,8 @@ * under normal circumstances, used to verify that nobody uses * non-initialized list entries. @@ -65491,9 +67669,10 @@ diff -urNp linux-2.6.32.49/include/linux/poison.= h linux-2.6.32.49/include/linux/ =20 /********** include/linux/timer.h **********/ /* -diff -urNp linux-2.6.32.49/include/linux/posix-timers.h linux-2.6.32.49/= include/linux/posix-timers.h ---- linux-2.6.32.49/include/linux/posix-timers.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/include/linux/posix-timers.h 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/include/linux/posix-timers.h b/include/linux/posix-timers.h +index 4f71bf4..77ffa64 100644 +--- a/include/linux/posix-timers.h ++++ b/include/linux/posix-timers.h @@ -67,7 +67,7 @@ struct k_itimer { }; =20 @@ -65503,9 +67682,10 @@ diff -urNp linux-2.6.32.49/include/linux/posix-t= imers.h linux-2.6.32.49/include/ int (*clock_getres) (const clockid_t which_clock, struct timespec *tp)= ; int (*clock_set) (const clockid_t which_clock, struct timespec * tp); int (*clock_get) (const clockid_t which_clock, struct timespec * tp); -diff -urNp linux-2.6.32.49/include/linux/preempt.h linux-2.6.32.49/inclu= de/linux/preempt.h ---- linux-2.6.32.49/include/linux/preempt.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/preempt.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/include/linux/preempt.h b/include/linux/preempt.h +index 72b1a10..13303a9 100644 +--- a/include/linux/preempt.h ++++ b/include/linux/preempt.h @@ -110,7 +110,7 @@ struct preempt_ops { void (*sched_in)(struct preempt_notifier *notifier, int cpu); void (*sched_out)(struct preempt_notifier *notifier, @@ -65515,10 +67695,11 @@ diff -urNp linux-2.6.32.49/include/linux/preemp= t.h linux-2.6.32.49/include/linux =20 /** * preempt_notifier - key for installing preemption notifiers -diff -urNp linux-2.6.32.49/include/linux/proc_fs.h linux-2.6.32.49/inclu= de/linux/proc_fs.h ---- linux-2.6.32.49/include/linux/proc_fs.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/proc_fs.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -155,6 +155,19 @@ static inline struct proc_dir_entry *pro +diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h +index 379eaed..1bf73e3 100644 +--- a/include/linux/proc_fs.h ++++ b/include/linux/proc_fs.h +@@ -155,6 +155,19 @@ static inline struct proc_dir_entry *proc_create(co= nst char *name, mode_t mode, return proc_create_data(name, mode, parent, proc_fops, NULL); } =20 @@ -65547,10 +67728,11 @@ diff -urNp linux-2.6.32.49/include/linux/proc_f= s.h linux-2.6.32.49/include/linux =20 struct ctl_table_header; struct ctl_table; -diff -urNp linux-2.6.32.49/include/linux/ptrace.h linux-2.6.32.49/includ= e/linux/ptrace.h ---- linux-2.6.32.49/include/linux/ptrace.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/ptrace.h 2011-11-15 19:59:43.000000000= -0500 -@@ -96,10 +96,10 @@ extern void __ptrace_unlink(struct task_ +diff --git a/include/linux/ptrace.h b/include/linux/ptrace.h +index 7456d7d..6c1cfc9 100644 +--- a/include/linux/ptrace.h ++++ b/include/linux/ptrace.h +@@ -96,10 +96,10 @@ extern void __ptrace_unlink(struct task_struct *chil= d); extern void exit_ptrace(struct task_struct *tracer); #define PTRACE_MODE_READ 1 #define PTRACE_MODE_ATTACH 2 @@ -65563,10 +67745,11 @@ diff -urNp linux-2.6.32.49/include/linux/ptrace= .h linux-2.6.32.49/include/linux/ =20 static inline int ptrace_reparented(struct task_struct *child) { -diff -urNp linux-2.6.32.49/include/linux/random.h linux-2.6.32.49/includ= e/linux/random.h ---- linux-2.6.32.49/include/linux/random.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/random.h 2011-11-15 19:59:43.000000000= -0500 -@@ -63,6 +63,11 @@ unsigned long randomize_range(unsigned l +diff --git a/include/linux/random.h b/include/linux/random.h +index 2948046..3262567 100644 +--- a/include/linux/random.h ++++ b/include/linux/random.h +@@ -63,6 +63,11 @@ unsigned long randomize_range(unsigned long start, un= signed long end, unsigned l u32 random32(void); void srandom32(u32 seed); =20 @@ -65578,10 +67761,11 @@ diff -urNp linux-2.6.32.49/include/linux/random= .h linux-2.6.32.49/include/linux/ #endif /* __KERNEL___ */ =20 #endif /* _LINUX_RANDOM_H */ -diff -urNp linux-2.6.32.49/include/linux/reboot.h linux-2.6.32.49/includ= e/linux/reboot.h ---- linux-2.6.32.49/include/linux/reboot.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/reboot.h 2011-11-15 19:59:43.000000000= -0500 -@@ -47,9 +47,9 @@ extern int unregister_reboot_notifier(st +diff --git a/include/linux/reboot.h b/include/linux/reboot.h +index 988e55f..17cb4ef 100644 +--- a/include/linux/reboot.h ++++ b/include/linux/reboot.h +@@ -47,9 +47,9 @@ extern int unregister_reboot_notifier(struct notifier_= block *); * Architecture-specific implementations of sys_reboot commands. */ =20 @@ -65594,7 +67778,7 @@ diff -urNp linux-2.6.32.49/include/linux/reboot.h= linux-2.6.32.49/include/linux/ =20 extern void machine_shutdown(void); struct pt_regs; -@@ -60,9 +60,9 @@ extern void machine_crash_shutdown(struc +@@ -60,9 +60,9 @@ extern void machine_crash_shutdown(struct pt_regs *); */ =20 extern void kernel_restart_prepare(char *cmd); @@ -65616,10 +67800,11 @@ diff -urNp linux-2.6.32.49/include/linux/reboot= .h linux-2.6.32.49/include/linux/ #include =20 #endif -diff -urNp linux-2.6.32.49/include/linux/reiserfs_fs.h linux-2.6.32.49/i= nclude/linux/reiserfs_fs.h ---- linux-2.6.32.49/include/linux/reiserfs_fs.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/linux/reiserfs_fs.h 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -1326,7 +1326,7 @@ static inline loff_t max_reiserfs_offset +diff --git a/include/linux/reiserfs_fs.h b/include/linux/reiserfs_fs.h +index dd31e7b..5b03c5c 100644 +--- a/include/linux/reiserfs_fs.h ++++ b/include/linux/reiserfs_fs.h +@@ -1326,7 +1326,7 @@ static inline loff_t max_reiserfs_offset(struct in= ode *inode) #define REISERFS_USER_MEM 1 /* reiserfs user memory mode */ =20 #define fs_generation(s) (REISERFS_SB(s)->s_generation_counter) @@ -65628,7 +67813,7 @@ diff -urNp linux-2.6.32.49/include/linux/reiserfs= _fs.h linux-2.6.32.49/include/l #define FILESYSTEM_CHANGED_TB(tb) (get_generation((tb)->tb_sb) !=3D (t= b)->fs_gen) #define __fs_changed(gen,s) (gen !=3D get_generation (s)) #define fs_changed(gen,s) ({cond_resched(); __fs_changed(gen, s);}) -@@ -1534,24 +1534,24 @@ static inline struct super_block *sb_fro +@@ -1534,24 +1534,24 @@ static inline struct super_block *sb_from_bi(str= uct buffer_info *bi) */ =20 struct item_operations { @@ -65665,9 +67850,10 @@ diff -urNp linux-2.6.32.49/include/linux/reiserf= s_fs.h linux-2.6.32.49/include/l =20 #define op_bytes_number(ih,bsize) item_ops[le_ih_k_t= ype (ih)]->bytes_number (ih, bsize) #define op_is_left_mergeable(key,bsize) item_ops[le_key_k_= type (le_key_version (key), key)]->is_left_mergeable (key, bsize) -diff -urNp linux-2.6.32.49/include/linux/reiserfs_fs_sb.h linux-2.6.32.4= 9/include/linux/reiserfs_fs_sb.h ---- linux-2.6.32.49/include/linux/reiserfs_fs_sb.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/include/linux/reiserfs_fs_sb.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/include/linux/reiserfs_fs_sb.h b/include/linux/reiserfs_fs_= sb.h +index dab68bb..0688727 100644 +--- a/include/linux/reiserfs_fs_sb.h ++++ b/include/linux/reiserfs_fs_sb.h @@ -377,7 +377,7 @@ struct reiserfs_sb_info { /* Comment? -Hans */ wait_queue_head_t s_wait; @@ -65677,9 +67863,10 @@ diff -urNp linux-2.6.32.49/include/linux/reiserf= s_fs_sb.h linux-2.6.32.49/includ // tree gets re-balanced unsigned long s_properties; /* File system properties. Currently holds on-disk FS format */ -diff -urNp linux-2.6.32.49/include/linux/relay.h linux-2.6.32.49/include= /linux/relay.h ---- linux-2.6.32.49/include/linux/relay.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/relay.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/relay.h b/include/linux/relay.h +index 14a86bc..17d0700 100644 +--- a/include/linux/relay.h ++++ b/include/linux/relay.h @@ -159,7 +159,7 @@ struct rchan_callbacks * The callback should return 0 if successful, negative if not. */ @@ -65689,9 +67876,10 @@ diff -urNp linux-2.6.32.49/include/linux/relay.h= linux-2.6.32.49/include/linux/r =20 /* * CONFIG_RELAY kernel API, kernel/relay.c -diff -urNp linux-2.6.32.49/include/linux/rfkill.h linux-2.6.32.49/includ= e/linux/rfkill.h ---- linux-2.6.32.49/include/linux/rfkill.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/rfkill.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/rfkill.h b/include/linux/rfkill.h +index 3392c59..a746428 100644 +--- a/include/linux/rfkill.h ++++ b/include/linux/rfkill.h @@ -144,6 +144,7 @@ struct rfkill_ops { void (*query)(struct rfkill *rfkill, void *data); int (*set_block)(void *data, bool blocked); @@ -65700,9 +67888,10 @@ diff -urNp linux-2.6.32.49/include/linux/rfkill.= h linux-2.6.32.49/include/linux/ =20 #if defined(CONFIG_RFKILL) || defined(CONFIG_RFKILL_MODULE) /** -diff -urNp linux-2.6.32.49/include/linux/sched.h linux-2.6.32.49/include= /linux/sched.h ---- linux-2.6.32.49/include/linux/sched.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/sched.h 2011-11-18 18:01:52.000000000 = -0500 +diff --git a/include/linux/sched.h b/include/linux/sched.h +index 71849bf..40217dc 100644 +--- a/include/linux/sched.h ++++ b/include/linux/sched.h @@ -101,6 +101,7 @@ struct bio; struct fs_struct; struct bts_context; @@ -65711,7 +67900,7 @@ diff -urNp linux-2.6.32.49/include/linux/sched.h = linux-2.6.32.49/include/linux/s =20 /* * List of flags we want to share for kernel threads, -@@ -350,7 +351,7 @@ extern signed long schedule_timeout_kill +@@ -350,7 +351,7 @@ extern signed long schedule_timeout_killable(signed = long timeout); extern signed long schedule_timeout_uninterruptible(signed long timeout= ); asmlinkage void __schedule(void); asmlinkage void schedule(void); @@ -65907,7 +68096,7 @@ diff -urNp linux-2.6.32.49/include/linux/sched.h = linux-2.6.32.49/include/linux/s /* Future-safe accessor for struct task_struct's cpus_allowed. */ #define tsk_cpumask(tsk) (&(tsk)->cpus_allowed) =20 -@@ -1740,7 +1831,7 @@ extern void thread_group_times(struct ta +@@ -1740,7 +1831,7 @@ extern void thread_group_times(struct task_struct = *p, cputime_t *ut, cputime_t * #define PF_DUMPCORE 0x00000200 /* dumped core */ #define PF_SIGNALED 0x00000400 /* killed by a signal */ #define PF_MEMALLOC 0x00000800 /* Allocating memory */ @@ -65934,7 +68123,7 @@ diff -urNp linux-2.6.32.49/include/linux/sched.h = linux-2.6.32.49/include/linux/s extern struct task_struct *find_task_by_pid_ns(pid_t nr, struct pid_namespace *ns); =20 -@@ -2155,7 +2249,7 @@ extern void __cleanup_sighand(struct sig +@@ -2155,7 +2249,7 @@ extern void __cleanup_sighand(struct sighand_struc= t *); extern void exit_itimers(struct signal_struct *); extern void flush_itimer_signals(void); =20 @@ -65943,7 +68132,7 @@ diff -urNp linux-2.6.32.49/include/linux/sched.h = linux-2.6.32.49/include/linux/s =20 extern void daemonize(const char *, ...); extern int allow_signal(int); -@@ -2284,13 +2378,17 @@ static inline unsigned long *end_of_stac +@@ -2284,13 +2378,17 @@ static inline unsigned long *end_of_stack(struct= task_struct *p) =20 #endif =20 @@ -65963,9 +68152,10 @@ diff -urNp linux-2.6.32.49/include/linux/sched.h= linux-2.6.32.49/include/linux/s extern void thread_info_cache_init(void); =20 #ifdef CONFIG_DEBUG_STACK_USAGE -diff -urNp linux-2.6.32.49/include/linux/screen_info.h linux-2.6.32.49/i= nclude/linux/screen_info.h ---- linux-2.6.32.49/include/linux/screen_info.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/linux/screen_info.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/linux/screen_info.h b/include/linux/screen_info.h +index 1ee2c05..81b7ec4 100644 +--- a/include/linux/screen_info.h ++++ b/include/linux/screen_info.h @@ -42,7 +42,8 @@ struct screen_info { __u16 pages; /* 0x32 */ __u16 vesa_attributes; /* 0x34 */ @@ -65976,9 +68166,10 @@ diff -urNp linux-2.6.32.49/include/linux/screen_= info.h linux-2.6.32.49/include/l } __attribute__((packed)); =20 #define VIDEO_TYPE_MDA 0x10 /* Monochrome Text Display */ -diff -urNp linux-2.6.32.49/include/linux/security.h linux-2.6.32.49/incl= ude/linux/security.h ---- linux-2.6.32.49/include/linux/security.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/security.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/linux/security.h b/include/linux/security.h +index d40d23f..253bd14 100644 +--- a/include/linux/security.h ++++ b/include/linux/security.h @@ -34,6 +34,7 @@ #include #include @@ -65987,9 +68178,10 @@ diff -urNp linux-2.6.32.49/include/linux/securit= y.h linux-2.6.32.49/include/linu #include =20 /* Maximum number of letters for an LSM name string */ -diff -urNp linux-2.6.32.49/include/linux/seq_file.h linux-2.6.32.49/incl= ude/linux/seq_file.h ---- linux-2.6.32.49/include/linux/seq_file.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/seq_file.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/linux/seq_file.h b/include/linux/seq_file.h +index 8366d8f..2307490 100644 +--- a/include/linux/seq_file.h ++++ b/include/linux/seq_file.h @@ -32,6 +32,7 @@ struct seq_operations { void * (*next) (struct seq_file *m, void *v, loff_t *pos); int (*show) (struct seq_file *m, void *v); @@ -65998,10 +68190,11 @@ diff -urNp linux-2.6.32.49/include/linux/seq_fi= le.h linux-2.6.32.49/include/linu =20 #define SEQ_SKIP 1 =20 -diff -urNp linux-2.6.32.49/include/linux/shm.h linux-2.6.32.49/include/l= inux/shm.h ---- linux-2.6.32.49/include/linux/shm.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/shm.h 2011-11-15 19:59:43.000000000 -0= 500 -@@ -95,6 +95,10 @@ struct shmid_kernel /* private to the ke +diff --git a/include/linux/shm.h b/include/linux/shm.h +index eca6235..c7417ed 100644 +--- a/include/linux/shm.h ++++ b/include/linux/shm.h +@@ -95,6 +95,10 @@ struct shmid_kernel /* private to the kernel */ pid_t shm_cprid; pid_t shm_lprid; struct user_struct *mlock_user; @@ -66012,9 +68205,10 @@ diff -urNp linux-2.6.32.49/include/linux/shm.h l= inux-2.6.32.49/include/linux/shm }; =20 /* shm_mode upper byte flags */ -diff -urNp linux-2.6.32.49/include/linux/skbuff.h linux-2.6.32.49/includ= e/linux/skbuff.h ---- linux-2.6.32.49/include/linux/skbuff.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/skbuff.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h +index bcdd660..6e12e11 100644 +--- a/include/linux/skbuff.h ++++ b/include/linux/skbuff.h @@ -14,6 +14,7 @@ #ifndef _LINUX_SKBUFF_H #define _LINUX_SKBUFF_H @@ -66023,7 +68217,7 @@ diff -urNp linux-2.6.32.49/include/linux/skbuff.h= linux-2.6.32.49/include/linux/ #include #include #include -@@ -544,7 +545,7 @@ static inline union skb_shared_tx *skb_t +@@ -544,7 +545,7 @@ static inline union skb_shared_tx *skb_tx(struct sk_= buff *skb) */ static inline int skb_queue_empty(const struct sk_buff_head *list) { @@ -66032,7 +68226,7 @@ diff -urNp linux-2.6.32.49/include/linux/skbuff.h= linux-2.6.32.49/include/linux/ } =20 /** -@@ -557,7 +558,7 @@ static inline int skb_queue_empty(const=20 +@@ -557,7 +558,7 @@ static inline int skb_queue_empty(const struct sk_bu= ff_head *list) static inline bool skb_queue_is_last(const struct sk_buff_head *list, const struct sk_buff *skb) { @@ -66041,7 +68235,7 @@ diff -urNp linux-2.6.32.49/include/linux/skbuff.h= linux-2.6.32.49/include/linux/ } =20 /** -@@ -570,7 +571,7 @@ static inline bool skb_queue_is_last(con +@@ -570,7 +571,7 @@ static inline bool skb_queue_is_last(const struct sk= _buff_head *list, static inline bool skb_queue_is_first(const struct sk_buff_head *list, const struct sk_buff *skb) { @@ -66050,7 +68244,7 @@ diff -urNp linux-2.6.32.49/include/linux/skbuff.h= linux-2.6.32.49/include/linux/ } =20 /** -@@ -1367,7 +1368,7 @@ static inline int skb_network_offset(con +@@ -1367,7 +1368,7 @@ static inline int skb_network_offset(const struct = sk_buff *skb) * headroom, you should not reduce this. */ #ifndef NET_SKB_PAD @@ -66059,27 +68253,10 @@ diff -urNp linux-2.6.32.49/include/linux/skbuff= .h linux-2.6.32.49/include/linux/ #endif =20 extern int ___pskb_trim(struct sk_buff *skb, unsigned int len); -diff -urNp linux-2.6.32.49/include/linux/slab_def.h linux-2.6.32.49/incl= ude/linux/slab_def.h ---- linux-2.6.32.49/include/linux/slab_def.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/slab_def.h 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -69,10 +69,10 @@ struct kmem_cache { - unsigned long node_allocs; - unsigned long node_frees; - unsigned long node_overflow; -- atomic_t allochit; -- atomic_t allocmiss; -- atomic_t freehit; -- atomic_t freemiss; -+ atomic_unchecked_t allochit; -+ atomic_unchecked_t allocmiss; -+ atomic_unchecked_t freehit; -+ atomic_unchecked_t freemiss; -=20 - /* - * If debugging is enabled, then the allocator can add additional -diff -urNp linux-2.6.32.49/include/linux/slab.h linux-2.6.32.49/include/= linux/slab.h ---- linux-2.6.32.49/include/linux/slab.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/include/linux/slab.h 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/include/linux/slab.h b/include/linux/slab.h +index 2da8372..a3be824 100644 +--- a/include/linux/slab.h ++++ b/include/linux/slab.h @@ -11,12 +11,20 @@ =20 #include @@ -66118,7 +68295,7 @@ diff -urNp linux-2.6.32.49/include/linux/slab.h l= inux-2.6.32.49/include/linux/sl =20 /* * struct kmem_cache related prototypes -@@ -138,6 +149,7 @@ void * __must_check krealloc(const void=20 +@@ -138,6 +149,7 @@ void * __must_check krealloc(const void *, size_t, g= fp_t); void kfree(const void *); void kzfree(const void *); size_t ksize(const void *); @@ -66126,7 +68303,7 @@ diff -urNp linux-2.6.32.49/include/linux/slab.h l= inux-2.6.32.49/include/linux/sl =20 /* * Allocator specific definitions. These are mainly used to establish o= ptimized -@@ -328,4 +340,37 @@ static inline void *kzalloc_node(size_t=20 +@@ -328,4 +340,37 @@ static inline void *kzalloc_node(size_t size, gfp_t= flags, int node) =20 void __init kmem_cache_init_late(void); =20 @@ -66164,9 +68341,29 @@ diff -urNp linux-2.6.32.49/include/linux/slab.h = linux-2.6.32.49/include/linux/sl +}) + #endif /* _LINUX_SLAB_H */ -diff -urNp linux-2.6.32.49/include/linux/slub_def.h linux-2.6.32.49/incl= ude/linux/slub_def.h ---- linux-2.6.32.49/include/linux/slub_def.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/slub_def.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/linux/slab_def.h b/include/linux/slab_def.h +index 850d057..d9dfe3c 100644 +--- a/include/linux/slab_def.h ++++ b/include/linux/slab_def.h +@@ -69,10 +69,10 @@ struct kmem_cache { + unsigned long node_allocs; + unsigned long node_frees; + unsigned long node_overflow; +- atomic_t allochit; +- atomic_t allocmiss; +- atomic_t freehit; +- atomic_t freemiss; ++ atomic_unchecked_t allochit; ++ atomic_unchecked_t allocmiss; ++ atomic_unchecked_t freehit; ++ atomic_unchecked_t freemiss; +=20 + /* + * If debugging is enabled, then the allocator can add additional +diff --git a/include/linux/slub_def.h b/include/linux/slub_def.h +index 5ad70a6..57f9f65 100644 +--- a/include/linux/slub_def.h ++++ b/include/linux/slub_def.h @@ -86,7 +86,7 @@ struct kmem_cache { struct kmem_cache_order_objects max; struct kmem_cache_order_objects min; @@ -66176,7 +68373,7 @@ diff -urNp linux-2.6.32.49/include/linux/slub_def= .h linux-2.6.32.49/include/linu void (*ctor)(void *); int inuse; /* Offset to metadata */ int align; /* Alignment */ -@@ -215,7 +215,7 @@ static __always_inline struct kmem_cache +@@ -215,7 +215,7 @@ static __always_inline struct kmem_cache *kmalloc_sl= ab(size_t size) #endif =20 void *kmem_cache_alloc(struct kmem_cache *, gfp_t); @@ -66185,9 +68382,10 @@ diff -urNp linux-2.6.32.49/include/linux/slub_de= f.h linux-2.6.32.49/include/linu =20 #ifdef CONFIG_KMEMTRACE extern void *kmem_cache_alloc_notrace(struct kmem_cache *s, gfp_t gfpfl= ags); -diff -urNp linux-2.6.32.49/include/linux/sonet.h linux-2.6.32.49/include= /linux/sonet.h ---- linux-2.6.32.49/include/linux/sonet.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/sonet.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/sonet.h b/include/linux/sonet.h +index 67ad11f..0bbd8af 100644 +--- a/include/linux/sonet.h ++++ b/include/linux/sonet.h @@ -61,7 +61,7 @@ struct sonet_stats { #include =20 @@ -66197,9 +68395,10 @@ diff -urNp linux-2.6.32.49/include/linux/sonet.h= linux-2.6.32.49/include/linux/s __SONET_ITEMS #undef __HANDLE_ITEM }; -diff -urNp linux-2.6.32.49/include/linux/sunrpc/cache.h linux-2.6.32.49/= include/linux/sunrpc/cache.h ---- linux-2.6.32.49/include/linux/sunrpc/cache.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/include/linux/sunrpc/cache.h 2011-11-15 19:59:43.000= 000000 -0500 +diff --git a/include/linux/sunrpc/cache.h b/include/linux/sunrpc/cache.h +index 6f52b4d..5500323 100644 +--- a/include/linux/sunrpc/cache.h ++++ b/include/linux/sunrpc/cache.h @@ -125,7 +125,7 @@ struct cache_detail { */ struct cache_req { @@ -66209,10 +68408,11 @@ diff -urNp linux-2.6.32.49/include/linux/sunrpc= /cache.h linux-2.6.32.49/include/ /* this must be embedded in a deferred_request that is being * delayed awaiting cache-fill */ -diff -urNp linux-2.6.32.49/include/linux/sunrpc/clnt.h linux-2.6.32.49/i= nclude/linux/sunrpc/clnt.h ---- linux-2.6.32.49/include/linux/sunrpc/clnt.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/linux/sunrpc/clnt.h 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -167,9 +167,9 @@ static inline unsigned short rpc_get_por +diff --git a/include/linux/sunrpc/clnt.h b/include/linux/sunrpc/clnt.h +index 8ed9642..101ceab 100644 +--- a/include/linux/sunrpc/clnt.h ++++ b/include/linux/sunrpc/clnt.h +@@ -167,9 +167,9 @@ static inline unsigned short rpc_get_port(const stru= ct sockaddr *sap) { switch (sap->sa_family) { case AF_INET: @@ -66224,7 +68424,7 @@ diff -urNp linux-2.6.32.49/include/linux/sunrpc/c= lnt.h linux-2.6.32.49/include/l } return 0; } -@@ -202,7 +202,7 @@ static inline bool __rpc_cmp_addr4(const +@@ -202,7 +202,7 @@ static inline bool __rpc_cmp_addr4(const struct sock= addr *sap1, static inline bool __rpc_copy_addr4(struct sockaddr *dst, const struct sockaddr *src) { @@ -66233,7 +68433,7 @@ diff -urNp linux-2.6.32.49/include/linux/sunrpc/c= lnt.h linux-2.6.32.49/include/l struct sockaddr_in *dsin =3D (struct sockaddr_in *) dst; =20 dsin->sin_family =3D ssin->sin_family; -@@ -299,7 +299,7 @@ static inline u32 rpc_get_scope_id(const +@@ -299,7 +299,7 @@ static inline u32 rpc_get_scope_id(const struct sock= addr *sa) if (sa->sa_family !=3D AF_INET6) return 0; =20 @@ -66242,9 +68442,10 @@ diff -urNp linux-2.6.32.49/include/linux/sunrpc/= clnt.h linux-2.6.32.49/include/l } =20 #endif /* __KERNEL__ */ -diff -urNp linux-2.6.32.49/include/linux/sunrpc/svc_rdma.h linux-2.6.32.= 49/include/linux/sunrpc/svc_rdma.h ---- linux-2.6.32.49/include/linux/sunrpc/svc_rdma.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/include/linux/sunrpc/svc_rdma.h 2011-11-15 19:59:43.= 000000000 -0500 +diff --git a/include/linux/sunrpc/svc_rdma.h b/include/linux/sunrpc/svc_= rdma.h +index c14fe86..393245e 100644 +--- a/include/linux/sunrpc/svc_rdma.h ++++ b/include/linux/sunrpc/svc_rdma.h @@ -53,15 +53,15 @@ extern unsigned int svcrdma_ord; extern unsigned int svcrdma_max_requests; extern unsigned int svcrdma_max_req_size; @@ -66270,9 +68471,10 @@ diff -urNp linux-2.6.32.49/include/linux/sunrpc/= svc_rdma.h linux-2.6.32.49/inclu =20 #define RPCRDMA_VERSION 1 =20 -diff -urNp linux-2.6.32.49/include/linux/suspend.h linux-2.6.32.49/inclu= de/linux/suspend.h ---- linux-2.6.32.49/include/linux/suspend.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/suspend.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/include/linux/suspend.h b/include/linux/suspend.h +index 5e781d8..1e62818 100644 +--- a/include/linux/suspend.h ++++ b/include/linux/suspend.h @@ -104,15 +104,15 @@ typedef int __bitwise suspend_state_t; * which require special recovery actions in that situation. */ @@ -66307,7 +68509,7 @@ diff -urNp linux-2.6.32.49/include/linux/suspend.= h linux-2.6.32.49/include/linux extern int suspend_valid_only_mem(suspend_state_t state); =20 /** -@@ -145,7 +145,7 @@ extern int pm_suspend(suspend_state_t st +@@ -145,7 +145,7 @@ extern int pm_suspend(suspend_state_t state); #else /* !CONFIG_SUSPEND */ #define suspend_valid_only_mem NULL =20 @@ -66316,7 +68518,7 @@ diff -urNp linux-2.6.32.49/include/linux/suspend.= h linux-2.6.32.49/include/linux static inline int pm_suspend(suspend_state_t state) { return -ENOSYS; } #endif /* !CONFIG_SUSPEND */ =20 -@@ -215,16 +215,16 @@ extern void mark_free_pages(struct zone=20 +@@ -215,16 +215,16 @@ extern void mark_free_pages(struct zone *zone); * platforms which require special recovery actions in that situation. */ struct platform_hibernation_ops { @@ -66343,7 +68545,7 @@ diff -urNp linux-2.6.32.49/include/linux/suspend.= h linux-2.6.32.49/include/linux }; =20 #ifdef CONFIG_HIBERNATION -@@ -243,7 +243,7 @@ extern void swsusp_set_page_free(struct=20 +@@ -243,7 +243,7 @@ extern void swsusp_set_page_free(struct page *); extern void swsusp_unset_page_free(struct page *); extern unsigned long get_safe_page(gfp_t gfp_mask); =20 @@ -66352,7 +68554,7 @@ diff -urNp linux-2.6.32.49/include/linux/suspend.= h linux-2.6.32.49/include/linux extern int hibernate(void); extern bool system_entering_hibernation(void); #else /* CONFIG_HIBERNATION */ -@@ -251,7 +251,7 @@ static inline int swsusp_page_is_forbidd +@@ -251,7 +251,7 @@ static inline int swsusp_page_is_forbidden(struct pa= ge *p) { return 0; } static inline void swsusp_set_page_free(struct page *p) {} static inline void swsusp_unset_page_free(struct page *p) {} =20 @@ -66361,9 +68563,10 @@ diff -urNp linux-2.6.32.49/include/linux/suspend= .h linux-2.6.32.49/include/linux static inline int hibernate(void) { return -ENOSYS; } static inline bool system_entering_hibernation(void) { return false; } #endif /* CONFIG_HIBERNATION */ -diff -urNp linux-2.6.32.49/include/linux/sysctl.h linux-2.6.32.49/includ= e/linux/sysctl.h ---- linux-2.6.32.49/include/linux/sysctl.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/sysctl.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h +index 0eb6942..a805cb6 100644 +--- a/include/linux/sysctl.h ++++ b/include/linux/sysctl.h @@ -164,7 +164,11 @@ enum KERN_PANIC_ON_NMI=3D76, /* int: whether we will panic on an unrecovere= d */ }; @@ -66377,7 +68580,7 @@ diff -urNp linux-2.6.32.49/include/linux/sysctl.h= linux-2.6.32.49/include/linux/ =20 /* CTL_VM names: */ enum -@@ -982,6 +986,8 @@ typedef int proc_handler (struct ctl_tab +@@ -982,6 +986,8 @@ typedef int proc_handler (struct ctl_table *ctl, int= write, =20 extern int proc_dostring(struct ctl_table *, int, void __user *, size_t *, loff_t *); @@ -66386,7 +68589,7 @@ diff -urNp linux-2.6.32.49/include/linux/sysctl.h= linux-2.6.32.49/include/linux/ extern int proc_dointvec(struct ctl_table *, int, void __user *, size_t *, loff_t *); extern int proc_dointvec_minmax(struct ctl_table *, int, -@@ -1003,6 +1009,7 @@ extern int do_sysctl (int __user *name,=20 +@@ -1003,6 +1009,7 @@ extern int do_sysctl (int __user *name, int nlen, =20 extern ctl_handler sysctl_data; extern ctl_handler sysctl_string; @@ -66394,9 +68597,10 @@ diff -urNp linux-2.6.32.49/include/linux/sysctl.= h linux-2.6.32.49/include/linux/ extern ctl_handler sysctl_intvec; extern ctl_handler sysctl_jiffies; extern ctl_handler sysctl_ms_jiffies; -diff -urNp linux-2.6.32.49/include/linux/sysfs.h linux-2.6.32.49/include= /linux/sysfs.h ---- linux-2.6.32.49/include/linux/sysfs.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/sysfs.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h +index 9d68fed..71f02cc 100644 +--- a/include/linux/sysfs.h ++++ b/include/linux/sysfs.h @@ -75,8 +75,8 @@ struct bin_attribute { }; =20 @@ -66408,9 +68612,10 @@ diff -urNp linux-2.6.32.49/include/linux/sysfs.h= linux-2.6.32.49/include/linux/s }; =20 struct sysfs_dirent; -diff -urNp linux-2.6.32.49/include/linux/thread_info.h linux-2.6.32.49/i= nclude/linux/thread_info.h ---- linux-2.6.32.49/include/linux/thread_info.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/linux/thread_info.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/linux/thread_info.h b/include/linux/thread_info.h +index a8cc4e1..98d3b85 100644 +--- a/include/linux/thread_info.h ++++ b/include/linux/thread_info.h @@ -23,7 +23,7 @@ struct restart_block { }; /* For futex_wait and futex_wait_requeue_pi */ @@ -66420,9 +68625,10 @@ diff -urNp linux-2.6.32.49/include/linux/thread_= info.h linux-2.6.32.49/include/l u32 val; u32 flags; u32 bitset; -diff -urNp linux-2.6.32.49/include/linux/tty.h linux-2.6.32.49/include/l= inux/tty.h ---- linux-2.6.32.49/include/linux/tty.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/linux/tty.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/linux/tty.h b/include/linux/tty.h +index e9c57e9..ee6d489 100644 +--- a/include/linux/tty.h ++++ b/include/linux/tty.h @@ -493,7 +493,6 @@ extern void tty_ldisc_begin(void); /* This last one is just for the tty layer internals and shouldn't be u= sed elsewhere */ extern void tty_ldisc_enable(struct tty_struct *tty); @@ -66431,9 +68637,10 @@ diff -urNp linux-2.6.32.49/include/linux/tty.h l= inux-2.6.32.49/include/linux/tty /* n_tty.c */ extern struct tty_ldisc_ops tty_ldisc_N_TTY; =20 -diff -urNp linux-2.6.32.49/include/linux/tty_ldisc.h linux-2.6.32.49/inc= lude/linux/tty_ldisc.h ---- linux-2.6.32.49/include/linux/tty_ldisc.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/include/linux/tty_ldisc.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/include/linux/tty_ldisc.h b/include/linux/tty_ldisc.h +index 0c4ee9b..9f7c426 100644 +--- a/include/linux/tty_ldisc.h ++++ b/include/linux/tty_ldisc.h @@ -139,7 +139,7 @@ struct tty_ldisc_ops { =20 struct module *owner; @@ -66443,9 +68650,10 @@ diff -urNp linux-2.6.32.49/include/linux/tty_ldi= sc.h linux-2.6.32.49/include/lin }; =20 struct tty_ldisc { -diff -urNp linux-2.6.32.49/include/linux/types.h linux-2.6.32.49/include= /linux/types.h ---- linux-2.6.32.49/include/linux/types.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/linux/types.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/linux/types.h b/include/linux/types.h +index c42724f..d190eee 100644 +--- a/include/linux/types.h ++++ b/include/linux/types.h @@ -191,10 +191,26 @@ typedef struct { volatile int counter; } atomic_t; @@ -66473,10 +68681,11 @@ diff -urNp linux-2.6.32.49/include/linux/types.= h linux-2.6.32.49/include/linux/t #endif =20 struct ustat { -diff -urNp linux-2.6.32.49/include/linux/uaccess.h linux-2.6.32.49/inclu= de/linux/uaccess.h ---- linux-2.6.32.49/include/linux/uaccess.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/uaccess.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -76,11 +76,11 @@ static inline unsigned long __copy_from_ +diff --git a/include/linux/uaccess.h b/include/linux/uaccess.h +index 6b58367..53a3e8e 100644 +--- a/include/linux/uaccess.h ++++ b/include/linux/uaccess.h +@@ -76,11 +76,11 @@ static inline unsigned long __copy_from_user_nocache= (void *to, long ret; \ mm_segment_t old_fs =3D get_fs(); \ \ @@ -66491,7 +68700,7 @@ diff -urNp linux-2.6.32.49/include/linux/uaccess.= h linux-2.6.32.49/include/linux ret; \ }) =20 -@@ -93,7 +93,7 @@ static inline unsigned long __copy_from_ +@@ -93,7 +93,7 @@ static inline unsigned long __copy_from_user_nocache(v= oid *to, * Safely read from address @src to the buffer at @dst. If a kernel fa= ult * happens, handle that and return -EFAULT. */ @@ -66500,7 +68709,7 @@ diff -urNp linux-2.6.32.49/include/linux/uaccess.= h linux-2.6.32.49/include/linux =20 /* * probe_kernel_write(): safely attempt to write to a location -@@ -104,6 +104,6 @@ extern long probe_kernel_read(void *dst, +@@ -104,6 +104,6 @@ extern long probe_kernel_read(void *dst, void *src, = size_t size); * Safely write to address @dst from the buffer at @src. If a kernel f= ault * happens, handle that and return -EFAULT. */ @@ -66508,9 +68717,10 @@ diff -urNp linux-2.6.32.49/include/linux/uaccess= .h linux-2.6.32.49/include/linux +extern long probe_kernel_write(void *dst, const void *src, size_t size)= ; =20 #endif /* __LINUX_UACCESS_H__ */ -diff -urNp linux-2.6.32.49/include/linux/unaligned/access_ok.h linux-2.6= .32.49/include/linux/unaligned/access_ok.h ---- linux-2.6.32.49/include/linux/unaligned/access_ok.h 2011-11-08 19:02= :43.000000000 -0500 -+++ linux-2.6.32.49/include/linux/unaligned/access_ok.h 2011-11-15 19:59= :43.000000000 -0500 +diff --git a/include/linux/unaligned/access_ok.h b/include/linux/unalign= ed/access_ok.h +index 99c1b4d..bb94261 100644 +--- a/include/linux/unaligned/access_ok.h ++++ b/include/linux/unaligned/access_ok.h @@ -6,32 +6,32 @@ =20 static inline u16 get_unaligned_le16(const void *p) @@ -66550,9 +68760,10 @@ diff -urNp linux-2.6.32.49/include/linux/unalign= ed/access_ok.h linux-2.6.32.49/i } =20 static inline void put_unaligned_le16(u16 val, void *p) -diff -urNp linux-2.6.32.49/include/linux/vermagic.h linux-2.6.32.49/incl= ude/linux/vermagic.h ---- linux-2.6.32.49/include/linux/vermagic.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/linux/vermagic.h 2011-11-18 18:09:44.0000000= 00 -0500 +diff --git a/include/linux/vermagic.h b/include/linux/vermagic.h +index 79b9837..b5a56f9 100644 +--- a/include/linux/vermagic.h ++++ b/include/linux/vermagic.h @@ -26,9 +26,35 @@ #define MODULE_ARCH_VERMAGIC "" #endif @@ -66590,10 +68801,11 @@ diff -urNp linux-2.6.32.49/include/linux/vermag= ic.h linux-2.6.32.49/include/linu + MODULE_PAX_REFCOUNT MODULE_CONSTIFY_PLUGIN MODULE_STACKLEAK_PLUGIN \ + MODULE_GRSEC =20 -diff -urNp linux-2.6.32.49/include/linux/vmalloc.h linux-2.6.32.49/inclu= de/linux/vmalloc.h ---- linux-2.6.32.49/include/linux/vmalloc.h 2011-11-26 19:44:53.00000000= 0 -0500 -+++ linux-2.6.32.49/include/linux/vmalloc.h 2011-11-26 19:46:42.00000000= 0 -0500 -@@ -14,6 +14,11 @@ struct vm_area_struct; /* vma defining=20 +diff --git a/include/linux/vmalloc.h b/include/linux/vmalloc.h +index 819a634..462ac12 100644 +--- a/include/linux/vmalloc.h ++++ b/include/linux/vmalloc.h +@@ -14,6 +14,11 @@ struct vm_area_struct; /* vma defining user mapping = in mm_types.h */ #define VM_USERMAP 0x00000008 /* suitable for remap_vmalloc_range */ #define VM_VPAGES 0x00000010 /* buffer for pages was vmalloc'ed */ #define VM_UNLIST 0x00000020 /* vm_struct is not listed in vmlist */ @@ -66605,7 +68817,7 @@ diff -urNp linux-2.6.32.49/include/linux/vmalloc.= h linux-2.6.32.49/include/linux /* bits [20..32] reserved for arch specific ioremap internals */ =20 /* -@@ -124,4 +129,81 @@ struct vm_struct **pcpu_get_vm_areas(con +@@ -124,4 +129,81 @@ struct vm_struct **pcpu_get_vm_areas(const unsigned= long *offsets, =20 void pcpu_free_vm_areas(struct vm_struct **vms, int nr_vms); =20 @@ -66687,10 +68899,11 @@ diff -urNp linux-2.6.32.49/include/linux/vmallo= c.h linux-2.6.32.49/include/linux +}) + #endif /* _LINUX_VMALLOC_H */ -diff -urNp linux-2.6.32.49/include/linux/vmstat.h linux-2.6.32.49/includ= e/linux/vmstat.h ---- linux-2.6.32.49/include/linux/vmstat.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/linux/vmstat.h 2011-11-15 19:59:43.000000000= -0500 -@@ -136,18 +136,18 @@ static inline void vm_events_fold_cpu(in +diff --git a/include/linux/vmstat.h b/include/linux/vmstat.h +index 13070d6..aa4159a 100644 +--- a/include/linux/vmstat.h ++++ b/include/linux/vmstat.h +@@ -136,18 +136,18 @@ static inline void vm_events_fold_cpu(int cpu) /* * Zone based page accounting with per cpu differentials. */ @@ -66713,7 +68926,7 @@ diff -urNp linux-2.6.32.49/include/linux/vmstat.h= linux-2.6.32.49/include/linux/ #ifdef CONFIG_SMP if (x < 0) x =3D 0; -@@ -158,7 +158,7 @@ static inline unsigned long global_page_ +@@ -158,7 +158,7 @@ static inline unsigned long global_page_state(enum z= one_stat_item item) static inline unsigned long zone_page_state(struct zone *zone, enum zone_stat_item item) { @@ -66722,7 +68935,7 @@ diff -urNp linux-2.6.32.49/include/linux/vmstat.h= linux-2.6.32.49/include/linux/ #ifdef CONFIG_SMP if (x < 0) x =3D 0; -@@ -175,7 +175,7 @@ static inline unsigned long zone_page_st +@@ -175,7 +175,7 @@ static inline unsigned long zone_page_state(struct z= one *zone, static inline unsigned long zone_page_state_snapshot(struct zone *zone, enum zone_stat_item item) { @@ -66731,7 +68944,7 @@ diff -urNp linux-2.6.32.49/include/linux/vmstat.h= linux-2.6.32.49/include/linux/ =20 #ifdef CONFIG_SMP int cpu; -@@ -264,8 +264,8 @@ static inline void __mod_zone_page_state +@@ -264,8 +264,8 @@ static inline void __mod_zone_page_state(struct zone= *zone, =20 static inline void __inc_zone_state(struct zone *zone, enum zone_stat_i= tem item) { @@ -66742,7 +68955,7 @@ diff -urNp linux-2.6.32.49/include/linux/vmstat.h= linux-2.6.32.49/include/linux/ } =20 static inline void __inc_zone_page_state(struct page *page, -@@ -276,8 +276,8 @@ static inline void __inc_zone_page_state +@@ -276,8 +276,8 @@ static inline void __inc_zone_page_state(struct page= *page, =20 static inline void __dec_zone_state(struct zone *zone, enum zone_stat_i= tem item) { @@ -66753,9 +68966,10 @@ diff -urNp linux-2.6.32.49/include/linux/vmstat.= h linux-2.6.32.49/include/linux/ } =20 static inline void __dec_zone_page_state(struct page *page, -diff -urNp linux-2.6.32.49/include/media/saa7146_vv.h linux-2.6.32.49/in= clude/media/saa7146_vv.h ---- linux-2.6.32.49/include/media/saa7146_vv.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/media/saa7146_vv.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/media/saa7146_vv.h b/include/media/saa7146_vv.h +index eed5fcc..5080d24 100644 +--- a/include/media/saa7146_vv.h ++++ b/include/media/saa7146_vv.h @@ -167,7 +167,7 @@ struct saa7146_ext_vv int (*std_callback)(struct saa7146_dev*, struct saa7146_standard *); =20 @@ -66765,9 +68979,10 @@ diff -urNp linux-2.6.32.49/include/media/saa7146= _vv.h linux-2.6.32.49/include/me /* pointer to the saa7146 core ops */ const struct v4l2_ioctl_ops *core_ops; =20 -diff -urNp linux-2.6.32.49/include/media/v4l2-dev.h linux-2.6.32.49/incl= ude/media/v4l2-dev.h ---- linux-2.6.32.49/include/media/v4l2-dev.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/media/v4l2-dev.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/media/v4l2-dev.h b/include/media/v4l2-dev.h +index 73c9867..2da8837 100644 +--- a/include/media/v4l2-dev.h ++++ b/include/media/v4l2-dev.h @@ -34,7 +34,7 @@ struct v4l2_device; #define V4L2_FL_UNREGISTERED (0) =20 @@ -66785,10 +69000,11 @@ diff -urNp linux-2.6.32.49/include/media/v4l2-d= ev.h linux-2.6.32.49/include/medi =20 /* * Newer version of video_device, handled by videodev2.c -diff -urNp linux-2.6.32.49/include/media/v4l2-device.h linux-2.6.32.49/i= nclude/media/v4l2-device.h ---- linux-2.6.32.49/include/media/v4l2-device.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/media/v4l2-device.h 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -71,7 +71,7 @@ int __must_check v4l2_device_register(st +diff --git a/include/media/v4l2-device.h b/include/media/v4l2-device.h +index 5d5d550..f559ef1 100644 +--- a/include/media/v4l2-device.h ++++ b/include/media/v4l2-device.h +@@ -71,7 +71,7 @@ int __must_check v4l2_device_register(struct device *d= ev, struct v4l2_device *v4 this function returns 0. If the name ends with a digit (e.g. cx18), then the name will be set to cx18-0 since cx180 looks really odd. */ int v4l2_device_set_name(struct v4l2_device *v4l2_dev, const char *base= name, @@ -66797,9 +69013,10 @@ diff -urNp linux-2.6.32.49/include/media/v4l2-de= vice.h linux-2.6.32.49/include/m =20 /* Set v4l2_dev->dev to NULL. Call when the USB parent disconnects. Since the parent disappears this ensures that v4l2_dev doesn't have = an -diff -urNp linux-2.6.32.49/include/media/v4l2-ioctl.h linux-2.6.32.49/in= clude/media/v4l2-ioctl.h ---- linux-2.6.32.49/include/media/v4l2-ioctl.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/media/v4l2-ioctl.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/media/v4l2-ioctl.h b/include/media/v4l2-ioctl.h +index 7a4529d..7244290 100644 +--- a/include/media/v4l2-ioctl.h ++++ b/include/media/v4l2-ioctl.h @@ -243,6 +243,7 @@ struct v4l2_ioctl_ops { long (*vidioc_default) (struct file *file, void *fh, int cmd, void *arg); @@ -66808,10 +69025,11 @@ diff -urNp linux-2.6.32.49/include/media/v4l2-i= octl.h linux-2.6.32.49/include/me =20 =20 /* v4l debugging and diagnostics */ -diff -urNp linux-2.6.32.49/include/net/flow.h linux-2.6.32.49/include/ne= t/flow.h ---- linux-2.6.32.49/include/net/flow.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/include/net/flow.h 2011-11-15 19:59:43.000000000 -05= 00 -@@ -92,7 +92,7 @@ typedef int (*flow_resolve_t)(struct net +diff --git a/include/net/flow.h b/include/net/flow.h +index 809970b..c3df4f3 100644 +--- a/include/net/flow.h ++++ b/include/net/flow.h +@@ -92,7 +92,7 @@ typedef int (*flow_resolve_t)(struct net *net, struct = flowi *key, u16 family, extern void *flow_cache_lookup(struct net *net, struct flowi *key, u16 = family, u8 dir, flow_resolve_t resolver); extern void flow_cache_flush(void); @@ -66820,9 +69038,10 @@ diff -urNp linux-2.6.32.49/include/net/flow.h li= nux-2.6.32.49/include/net/flow.h =20 static inline int flow_cache_uli_match(struct flowi *fl1, struct flowi = *fl2) { -diff -urNp linux-2.6.32.49/include/net/inetpeer.h linux-2.6.32.49/includ= e/net/inetpeer.h ---- linux-2.6.32.49/include/net/inetpeer.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/net/inetpeer.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/net/inetpeer.h b/include/net/inetpeer.h +index 15e1f8fe..668837c 100644 +--- a/include/net/inetpeer.h ++++ b/include/net/inetpeer.h @@ -24,7 +24,7 @@ struct inet_peer __u32 dtime; /* the time of last use of not * referenced entries */ @@ -66832,9 +69051,10 @@ diff -urNp linux-2.6.32.49/include/net/inetpeer.= h linux-2.6.32.49/include/net/in __u32 tcp_ts; unsigned long tcp_ts_stamp; }; -diff -urNp linux-2.6.32.49/include/net/ip_vs.h linux-2.6.32.49/include/n= et/ip_vs.h ---- linux-2.6.32.49/include/net/ip_vs.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/net/ip_vs.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h +index 98978e7..2243a3d 100644 +--- a/include/net/ip_vs.h ++++ b/include/net/ip_vs.h @@ -365,7 +365,7 @@ struct ip_vs_conn { struct ip_vs_conn *control; /* Master control connection *= / atomic_t n_control; /* Number of controlled ones *= / @@ -66853,9 +69073,10 @@ diff -urNp linux-2.6.32.49/include/net/ip_vs.h l= inux-2.6.32.49/include/net/ip_vs atomic_t weight; /* server weight */ =20 atomic_t refcnt; /* reference counter */ -diff -urNp linux-2.6.32.49/include/net/irda/ircomm_core.h linux-2.6.32.4= 9/include/net/irda/ircomm_core.h ---- linux-2.6.32.49/include/net/irda/ircomm_core.h 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/include/net/irda/ircomm_core.h 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/include/net/irda/ircomm_core.h b/include/net/irda/ircomm_co= re.h +index 69b610a..fe3962c 100644 +--- a/include/net/irda/ircomm_core.h ++++ b/include/net/irda/ircomm_core.h @@ -51,7 +51,7 @@ typedef struct { int (*connect_response)(struct ircomm_cb *, struct sk_buff *); int (*disconnect_request)(struct ircomm_cb *, struct sk_buff *,=20 @@ -66865,9 +69086,10 @@ diff -urNp linux-2.6.32.49/include/net/irda/irco= mm_core.h linux-2.6.32.49/includ =20 struct ircomm_cb { irda_queue_t queue; -diff -urNp linux-2.6.32.49/include/net/irda/ircomm_tty.h linux-2.6.32.49= /include/net/irda/ircomm_tty.h ---- linux-2.6.32.49/include/net/irda/ircomm_tty.h 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/include/net/irda/ircomm_tty.h 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/include/net/irda/ircomm_tty.h b/include/net/irda/ircomm_tty= .h +index eea2e61..08c692d 100644 +--- a/include/net/irda/ircomm_tty.h ++++ b/include/net/irda/ircomm_tty.h @@ -35,6 +35,7 @@ #include #include @@ -66887,9 +69109,10 @@ diff -urNp linux-2.6.32.49/include/net/irda/irco= mm_tty.h linux-2.6.32.49/include =20 /* Protect concurent access to : * o self->open_count -diff -urNp linux-2.6.32.49/include/net/iucv/af_iucv.h linux-2.6.32.49/in= clude/net/iucv/af_iucv.h ---- linux-2.6.32.49/include/net/iucv/af_iucv.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/net/iucv/af_iucv.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/net/iucv/af_iucv.h b/include/net/iucv/af_iucv.h +index f82a1e8..82d81e8 100644 +--- a/include/net/iucv/af_iucv.h ++++ b/include/net/iucv/af_iucv.h @@ -87,7 +87,7 @@ struct iucv_sock { struct iucv_sock_list { struct hlist_head head; @@ -66899,9 +69122,10 @@ diff -urNp linux-2.6.32.49/include/net/iucv/af_i= ucv.h linux-2.6.32.49/include/ne }; =20 unsigned int iucv_sock_poll(struct file *file, struct socket *sock, -diff -urNp linux-2.6.32.49/include/net/lapb.h linux-2.6.32.49/include/ne= t/lapb.h ---- linux-2.6.32.49/include/net/lapb.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/include/net/lapb.h 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/include/net/lapb.h b/include/net/lapb.h +index 96cb5dd..25e8d4f 100644 +--- a/include/net/lapb.h ++++ b/include/net/lapb.h @@ -95,7 +95,7 @@ struct lapb_cb { struct sk_buff_head write_queue; struct sk_buff_head ack_queue; @@ -66911,9 +69135,10 @@ diff -urNp linux-2.6.32.49/include/net/lapb.h li= nux-2.6.32.49/include/net/lapb.h =20 /* FRMR control information */ struct lapb_frame frmr_data; -diff -urNp linux-2.6.32.49/include/net/neighbour.h linux-2.6.32.49/inclu= de/net/neighbour.h ---- linux-2.6.32.49/include/net/neighbour.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/net/neighbour.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/include/net/neighbour.h b/include/net/neighbour.h +index 3817fda..cdb2343 100644 +--- a/include/net/neighbour.h ++++ b/include/net/neighbour.h @@ -131,7 +131,7 @@ struct neigh_ops int (*connected_output)(struct sk_buff*); int (*hh_output)(struct sk_buff*); @@ -66923,10 +69148,11 @@ diff -urNp linux-2.6.32.49/include/net/neighbou= r.h linux-2.6.32.49/include/net/n =20 struct pneigh_entry { -diff -urNp linux-2.6.32.49/include/net/netlink.h linux-2.6.32.49/include= /net/netlink.h ---- linux-2.6.32.49/include/net/netlink.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/net/netlink.h 2011-11-15 19:59:43.000000000 = -0500 -@@ -335,7 +335,7 @@ static inline int nlmsg_ok(const struct=20 +diff --git a/include/net/netlink.h b/include/net/netlink.h +index c344646..4778c71 100644 +--- a/include/net/netlink.h ++++ b/include/net/netlink.h +@@ -335,7 +335,7 @@ static inline int nlmsg_ok(const struct nlmsghdr *nl= h, int remaining) { return (remaining >=3D (int) sizeof(struct nlmsghdr) && nlh->nlmsg_len >=3D sizeof(struct nlmsghdr) && @@ -66935,7 +69161,7 @@ diff -urNp linux-2.6.32.49/include/net/netlink.h = linux-2.6.32.49/include/net/net } =20 /** -@@ -558,7 +558,7 @@ static inline void *nlmsg_get_pos(struct +@@ -558,7 +558,7 @@ static inline void *nlmsg_get_pos(struct sk_buff *sk= b) static inline void nlmsg_trim(struct sk_buff *skb, const void *mark) { if (mark) @@ -66944,9 +69170,10 @@ diff -urNp linux-2.6.32.49/include/net/netlink.h= linux-2.6.32.49/include/net/net } =20 /** -diff -urNp linux-2.6.32.49/include/net/netns/ipv4.h linux-2.6.32.49/incl= ude/net/netns/ipv4.h ---- linux-2.6.32.49/include/net/netns/ipv4.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/net/netns/ipv4.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/net/netns/ipv4.h b/include/net/netns/ipv4.h +index 9a4b8b7..e49e077 100644 +--- a/include/net/netns/ipv4.h ++++ b/include/net/netns/ipv4.h @@ -54,7 +54,7 @@ struct netns_ipv4 { int current_rt_cache_rebuild_count; =20 @@ -66956,9 +69183,10 @@ diff -urNp linux-2.6.32.49/include/net/netns/ipv= 4.h linux-2.6.32.49/include/net/ =20 #ifdef CONFIG_IP_MROUTE struct sock *mroute_sk; -diff -urNp linux-2.6.32.49/include/net/sctp/sctp.h linux-2.6.32.49/inclu= de/net/sctp/sctp.h ---- linux-2.6.32.49/include/net/sctp/sctp.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/net/sctp/sctp.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h +index 8a6d529..171f401 100644 +--- a/include/net/sctp/sctp.h ++++ b/include/net/sctp/sctp.h @@ -305,8 +305,8 @@ extern int sctp_debug_flag; =20 #else /* SCTP_DEBUG */ @@ -66970,9 +69198,10 @@ diff -urNp linux-2.6.32.49/include/net/sctp/sctp= .h linux-2.6.32.49/include/net/s #define SCTP_ENABLE_DEBUG #define SCTP_DISABLE_DEBUG #define SCTP_ASSERT(expr, str, func) -diff -urNp linux-2.6.32.49/include/net/secure_seq.h linux-2.6.32.49/incl= ude/net/secure_seq.h ---- linux-2.6.32.49/include/net/secure_seq.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/net/secure_seq.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/net/secure_seq.h b/include/net/secure_seq.h +index d97f689..f3b90ab 100644 +--- a/include/net/secure_seq.h ++++ b/include/net/secure_seq.h @@ -7,14 +7,14 @@ extern __u32 secure_ip_id(__be32 daddr); extern __u32 secure_ipv6_id(const __be32 daddr[4]); extern u32 secure_ipv4_port_ephemeral(__be32 saddr, __be32 daddr, __be1= 6 dport); @@ -66992,9 +69221,10 @@ diff -urNp linux-2.6.32.49/include/net/secure_se= q.h linux-2.6.32.49/include/net/ + __be16 sport, __be16 dport); =20 #endif /* _NET_SECURE_SEQ */ -diff -urNp linux-2.6.32.49/include/net/sock.h linux-2.6.32.49/include/ne= t/sock.h ---- linux-2.6.32.49/include/net/sock.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/include/net/sock.h 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/include/net/sock.h b/include/net/sock.h +index 9f96394..76fc9c7 100644 +--- a/include/net/sock.h ++++ b/include/net/sock.h @@ -272,7 +272,7 @@ struct sock { rwlock_t sk_callback_lock; int sk_err, @@ -67004,7 +69234,7 @@ diff -urNp linux-2.6.32.49/include/net/sock.h lin= ux-2.6.32.49/include/net/sock.h unsigned short sk_ack_backlog; unsigned short sk_max_ack_backlog; __u32 sk_priority; -@@ -737,7 +737,7 @@ static inline void sk_refcnt_debug_relea +@@ -737,7 +737,7 @@ static inline void sk_refcnt_debug_release(const str= uct sock *sk) extern void sock_prot_inuse_add(struct net *net, struct proto *prot, in= t inc); extern int sock_prot_inuse_get(struct net *net, struct proto *proto); #else @@ -67013,9 +69243,10 @@ diff -urNp linux-2.6.32.49/include/net/sock.h li= nux-2.6.32.49/include/net/sock.h int inc) { } -diff -urNp linux-2.6.32.49/include/net/tcp.h linux-2.6.32.49/include/net= /tcp.h ---- linux-2.6.32.49/include/net/tcp.h 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/include/net/tcp.h 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/include/net/tcp.h b/include/net/tcp.h +index 6cfe18b..dd21acb 100644 +--- a/include/net/tcp.h ++++ b/include/net/tcp.h @@ -1444,8 +1444,8 @@ enum tcp_seq_states { struct tcp_seq_afinfo { char *name; @@ -67027,9 +69258,10 @@ diff -urNp linux-2.6.32.49/include/net/tcp.h lin= ux-2.6.32.49/include/net/tcp.h }; =20 struct tcp_iter_state { -diff -urNp linux-2.6.32.49/include/net/udp.h linux-2.6.32.49/include/net= /udp.h ---- linux-2.6.32.49/include/net/udp.h 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/include/net/udp.h 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/include/net/udp.h b/include/net/udp.h +index f98abd2..b4b042f 100644 +--- a/include/net/udp.h ++++ b/include/net/udp.h @@ -187,8 +187,8 @@ struct udp_seq_afinfo { char *name; sa_family_t family; @@ -67041,9 +69273,10 @@ diff -urNp linux-2.6.32.49/include/net/udp.h lin= ux-2.6.32.49/include/net/udp.h }; =20 struct udp_iter_state { -diff -urNp linux-2.6.32.49/include/rdma/iw_cm.h linux-2.6.32.49/include/= rdma/iw_cm.h ---- linux-2.6.32.49/include/rdma/iw_cm.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/include/rdma/iw_cm.h 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/include/rdma/iw_cm.h b/include/rdma/iw_cm.h +index cbb822e..e9c1cbe 100644 +--- a/include/rdma/iw_cm.h ++++ b/include/rdma/iw_cm.h @@ -129,7 +129,7 @@ struct iw_cm_verbs { int backlog); =20 @@ -67053,9 +69286,10 @@ diff -urNp linux-2.6.32.49/include/rdma/iw_cm.h = linux-2.6.32.49/include/rdma/iw_ =20 /** * iw_create_cm_id - Create an IW CM identifier. -diff -urNp linux-2.6.32.49/include/scsi/libfc.h linux-2.6.32.49/include/= scsi/libfc.h ---- linux-2.6.32.49/include/scsi/libfc.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/include/scsi/libfc.h 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/include/scsi/libfc.h b/include/scsi/libfc.h +index 09a124b..caa8ca8 100644 +--- a/include/scsi/libfc.h ++++ b/include/scsi/libfc.h @@ -675,6 +675,7 @@ struct libfc_function_template { */ void (*disc_stop_final) (struct fc_lport *); @@ -67073,9 +69307,10 @@ diff -urNp linux-2.6.32.49/include/scsi/libfc.h = linux-2.6.32.49/include/scsi/lib u8 link_up; u8 qfull; enum fc_lport_state state; -diff -urNp linux-2.6.32.49/include/scsi/scsi_device.h linux-2.6.32.49/in= clude/scsi/scsi_device.h ---- linux-2.6.32.49/include/scsi/scsi_device.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/scsi/scsi_device.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h +index de8e180..f15e0d7 100644 +--- a/include/scsi/scsi_device.h ++++ b/include/scsi/scsi_device.h @@ -156,9 +156,9 @@ struct scsi_device { unsigned int max_device_blocked; /* what device_blocked counts down fr= om */ #define SCSI_DEFAULT_DEVICE_BLOCKED 3 @@ -67089,9 +69324,10 @@ diff -urNp linux-2.6.32.49/include/scsi/scsi_dev= ice.h linux-2.6.32.49/include/sc =20 struct device sdev_gendev, sdev_dev; -diff -urNp linux-2.6.32.49/include/scsi/scsi_transport_fc.h linux-2.6.32= .49/include/scsi/scsi_transport_fc.h ---- linux-2.6.32.49/include/scsi/scsi_transport_fc.h 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/include/scsi/scsi_transport_fc.h 2011-11-15 19:59:43= .000000000 -0500 +diff --git a/include/scsi/scsi_transport_fc.h b/include/scsi/scsi_transp= ort_fc.h +index fc50bd6..81ba9cb 100644 +--- a/include/scsi/scsi_transport_fc.h ++++ b/include/scsi/scsi_transport_fc.h @@ -708,7 +708,7 @@ struct fc_function_template { unsigned long show_host_system_hostname:1; =20 @@ -67101,9 +69337,10 @@ diff -urNp linux-2.6.32.49/include/scsi/scsi_tra= nsport_fc.h linux-2.6.32.49/incl =20 =20 /** -diff -urNp linux-2.6.32.49/include/sound/ac97_codec.h linux-2.6.32.49/in= clude/sound/ac97_codec.h ---- linux-2.6.32.49/include/sound/ac97_codec.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/sound/ac97_codec.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/sound/ac97_codec.h b/include/sound/ac97_codec.h +index 3dae3f7..8440d6f 100644 +--- a/include/sound/ac97_codec.h ++++ b/include/sound/ac97_codec.h @@ -419,15 +419,15 @@ struct snd_ac97; =20 @@ -67136,9 +69373,10 @@ diff -urNp linux-2.6.32.49/include/sound/ac97_co= dec.h linux-2.6.32.49/include/so void *private_data; void (*private_free) (struct snd_ac97 *ac97); /* --- */ -diff -urNp linux-2.6.32.49/include/sound/ak4xxx-adda.h linux-2.6.32.49/i= nclude/sound/ak4xxx-adda.h ---- linux-2.6.32.49/include/sound/ak4xxx-adda.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/include/sound/ak4xxx-adda.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/include/sound/ak4xxx-adda.h b/include/sound/ak4xxx-adda.h +index 891cf1a..a94ba2b 100644 +--- a/include/sound/ak4xxx-adda.h ++++ b/include/sound/ak4xxx-adda.h @@ -35,7 +35,7 @@ struct snd_ak4xxx_ops { void (*write)(struct snd_akm4xxx *ak, int chip, unsigned char reg, unsigned char val); @@ -67148,9 +69386,10 @@ diff -urNp linux-2.6.32.49/include/sound/ak4xxx-= adda.h linux-2.6.32.49/include/s =20 #define AK4XXX_IMAGE_SIZE (AK4XXX_MAX_CHIPS * 16) /* 64 bytes */ =20 -diff -urNp linux-2.6.32.49/include/sound/hwdep.h linux-2.6.32.49/include= /sound/hwdep.h ---- linux-2.6.32.49/include/sound/hwdep.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/include/sound/hwdep.h 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/include/sound/hwdep.h b/include/sound/hwdep.h +index 8c05e47..2b5df97 100644 +--- a/include/sound/hwdep.h ++++ b/include/sound/hwdep.h @@ -49,7 +49,7 @@ struct snd_hwdep_ops { struct snd_hwdep_dsp_status *status); int (*dsp_load)(struct snd_hwdep *hw, @@ -67160,9 +69399,10 @@ diff -urNp linux-2.6.32.49/include/sound/hwdep.h= linux-2.6.32.49/include/sound/h =20 struct snd_hwdep { struct snd_card *card; -diff -urNp linux-2.6.32.49/include/sound/info.h linux-2.6.32.49/include/= sound/info.h ---- linux-2.6.32.49/include/sound/info.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/include/sound/info.h 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/include/sound/info.h b/include/sound/info.h +index 112e894..6fda5b5 100644 +--- a/include/sound/info.h ++++ b/include/sound/info.h @@ -44,7 +44,7 @@ struct snd_info_entry_text { struct snd_info_buffer *buffer); void (*write)(struct snd_info_entry *entry, @@ -67172,9 +69412,10 @@ diff -urNp linux-2.6.32.49/include/sound/info.h = linux-2.6.32.49/include/sound/in =20 struct snd_info_entry_ops { int (*open)(struct snd_info_entry *entry, -diff -urNp linux-2.6.32.49/include/sound/pcm.h linux-2.6.32.49/include/s= ound/pcm.h ---- linux-2.6.32.49/include/sound/pcm.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/include/sound/pcm.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/include/sound/pcm.h b/include/sound/pcm.h +index de6d981..590a550 100644 +--- a/include/sound/pcm.h ++++ b/include/sound/pcm.h @@ -80,6 +80,7 @@ struct snd_pcm_ops { int (*mmap)(struct snd_pcm_substream *substream, struct vm_area_struct= *vma); int (*ack)(struct snd_pcm_substream *substream); @@ -67183,9 +69424,10 @@ diff -urNp linux-2.6.32.49/include/sound/pcm.h l= inux-2.6.32.49/include/sound/pcm =20 /* * -diff -urNp linux-2.6.32.49/include/sound/sb16_csp.h linux-2.6.32.49/incl= ude/sound/sb16_csp.h ---- linux-2.6.32.49/include/sound/sb16_csp.h 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/include/sound/sb16_csp.h 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/include/sound/sb16_csp.h b/include/sound/sb16_csp.h +index 736eac7..fe8a80f 100644 +--- a/include/sound/sb16_csp.h ++++ b/include/sound/sb16_csp.h @@ -139,7 +139,7 @@ struct snd_sb_csp_ops { int (*csp_start) (struct snd_sb_csp * p, int sample_width, int channel= s); int (*csp_stop) (struct snd_sb_csp * p); @@ -67195,9 +69437,10 @@ diff -urNp linux-2.6.32.49/include/sound/sb16_cs= p.h linux-2.6.32.49/include/soun =20 /* * CSP private data -diff -urNp linux-2.6.32.49/include/sound/ymfpci.h linux-2.6.32.49/includ= e/sound/ymfpci.h ---- linux-2.6.32.49/include/sound/ymfpci.h 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/include/sound/ymfpci.h 2011-11-15 19:59:43.000000000= -0500 +diff --git a/include/sound/ymfpci.h b/include/sound/ymfpci.h +index 444cd6b..3327cc5 100644 +--- a/include/sound/ymfpci.h ++++ b/include/sound/ymfpci.h @@ -358,7 +358,7 @@ struct snd_ymfpci { spinlock_t reg_lock; spinlock_t voice_lock; @@ -67207,9 +69450,10 @@ diff -urNp linux-2.6.32.49/include/sound/ymfpci.= h linux-2.6.32.49/include/sound/ struct snd_info_entry *proc_entry; const struct firmware *dsp_microcode; const struct firmware *controller_microcode; -diff -urNp linux-2.6.32.49/include/trace/events/irq.h linux-2.6.32.49/in= clude/trace/events/irq.h ---- linux-2.6.32.49/include/trace/events/irq.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/include/trace/events/irq.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/include/trace/events/irq.h b/include/trace/events/irq.h +index b89f9db..f097b38 100644 +--- a/include/trace/events/irq.h ++++ b/include/trace/events/irq.h @@ -34,7 +34,7 @@ */ TRACE_EVENT(irq_handler_entry, @@ -67246,9 +69490,10 @@ diff -urNp linux-2.6.32.49/include/trace/events/= irq.h linux-2.6.32.49/include/tr =20 TP_ARGS(h, vec), =20 -diff -urNp linux-2.6.32.49/include/video/uvesafb.h linux-2.6.32.49/inclu= de/video/uvesafb.h ---- linux-2.6.32.49/include/video/uvesafb.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/include/video/uvesafb.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/include/video/uvesafb.h b/include/video/uvesafb.h +index 0993a22..32ba2fe 100644 +--- a/include/video/uvesafb.h ++++ b/include/video/uvesafb.h @@ -177,6 +177,7 @@ struct uvesafb_par { u8 ypan; /* 0 - nothing, 1 - ypan, 2 - ywrap */ u8 pmi_setpal; /* PMI for palette changes */ @@ -67257,10 +69502,24 @@ diff -urNp linux-2.6.32.49/include/video/uvesaf= b.h linux-2.6.32.49/include/video void *pmi_start; void *pmi_pal; u8 *vbe_state_orig; /* -diff -urNp linux-2.6.32.49/init/do_mounts.c linux-2.6.32.49/init/do_moun= ts.c ---- linux-2.6.32.49/init/do_mounts.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/init/do_mounts.c 2011-11-15 19:59:43.000000000 -0500 -@@ -216,11 +216,11 @@ static void __init get_fs_names(char *pa +diff --git a/init/Kconfig b/init/Kconfig +index d72691b..3996e54 100644 +--- a/init/Kconfig ++++ b/init/Kconfig +@@ -1004,7 +1004,7 @@ config SLUB_DEBUG +=20 + config COMPAT_BRK + bool "Disable heap randomization" +- default y ++ default n + help + Randomizing heap placement makes heap exploits harder, but it + also breaks ancient binaries (including anything libc5 based). +diff --git a/init/do_mounts.c b/init/do_mounts.c +index bb008d0..4fa3933 100644 +--- a/init/do_mounts.c ++++ b/init/do_mounts.c +@@ -216,11 +216,11 @@ static void __init get_fs_names(char *page) =20 static int __init do_mount_root(char *name, char *fs, int flags, void *= data) { @@ -67274,7 +69533,7 @@ diff -urNp linux-2.6.32.49/init/do_mounts.c linux= -2.6.32.49/init/do_mounts.c ROOT_DEV =3D current->fs->pwd.mnt->mnt_sb->s_dev; printk("VFS: Mounted root (%s filesystem)%s on device %u:%u.\n", current->fs->pwd.mnt->mnt_sb->s_type->name, -@@ -311,18 +311,18 @@ void __init change_floppy(char *fmt, ... +@@ -311,18 +311,18 @@ void __init change_floppy(char *fmt, ...) va_start(args, fmt); vsprintf(buf, fmt, args); va_end(args); @@ -67305,9 +69564,10 @@ diff -urNp linux-2.6.32.49/init/do_mounts.c linu= x-2.6.32.49/init/do_mounts.c + sys_mount((__force char __user *)".", (__force char __user *)"/", NULL= , MS_MOVE, NULL); + sys_chroot((__force char __user *)"."); } -diff -urNp linux-2.6.32.49/init/do_mounts.h linux-2.6.32.49/init/do_moun= ts.h ---- linux-2.6.32.49/init/do_mounts.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/init/do_mounts.h 2011-11-15 19:59:43.000000000 -0500 +diff --git a/init/do_mounts.h b/init/do_mounts.h +index f5b978a..69dbfe8 100644 +--- a/init/do_mounts.h ++++ b/init/do_mounts.h @@ -15,15 +15,15 @@ extern int root_mountflags; =20 static inline int create_dev(char *name, dev_t dev) @@ -67336,10 +69596,11 @@ diff -urNp linux-2.6.32.49/init/do_mounts.h lin= ux-2.6.32.49/init/do_mounts.h return 0; if (!S_ISBLK(stat.st_mode)) return 0; -diff -urNp linux-2.6.32.49/init/do_mounts_initrd.c linux-2.6.32.49/init/= do_mounts_initrd.c ---- linux-2.6.32.49/init/do_mounts_initrd.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/init/do_mounts_initrd.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -32,7 +32,7 @@ static int __init do_linuxrc(void * shel +diff --git a/init/do_mounts_initrd.c b/init/do_mounts_initrd.c +index 614241b..4da046b 100644 +--- a/init/do_mounts_initrd.c ++++ b/init/do_mounts_initrd.c +@@ -32,7 +32,7 @@ static int __init do_linuxrc(void * shell) sys_close(old_fd);sys_close(root_fd); sys_close(0);sys_close(1);sys_close(2); sys_setsid(); @@ -67422,9 +69683,10 @@ diff -urNp linux-2.6.32.49/init/do_mounts_initrd= .c linux-2.6.32.49/init/do_mount + sys_unlink((const char __force_user *)"/initrd.image"); return 0; } -diff -urNp linux-2.6.32.49/init/do_mounts_md.c linux-2.6.32.49/init/do_m= ounts_md.c ---- linux-2.6.32.49/init/do_mounts_md.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/init/do_mounts_md.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/init/do_mounts_md.c b/init/do_mounts_md.c +index 69aebbf..c0bf6a7 100644 +--- a/init/do_mounts_md.c ++++ b/init/do_mounts_md.c @@ -170,7 +170,7 @@ static void __init md_setup_drive(void) partitioned ? "_d" : "", minor, md_setup_args[ent].device_names); @@ -67452,9 +69714,10 @@ diff -urNp linux-2.6.32.49/init/do_mounts_md.c l= inux-2.6.32.49/init/do_mounts_md if (fd >=3D 0) { sys_ioctl(fd, RAID_AUTORUN, raid_autopart); sys_close(fd); -diff -urNp linux-2.6.32.49/init/initramfs.c linux-2.6.32.49/init/initram= fs.c ---- linux-2.6.32.49/init/initramfs.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/init/initramfs.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/init/initramfs.c b/init/initramfs.c +index 1fd59b8..a01b079 100644 +--- a/init/initramfs.c ++++ b/init/initramfs.c @@ -74,7 +74,7 @@ static void __init free_hash(void) } } @@ -67482,7 +69745,7 @@ diff -urNp linux-2.6.32.49/init/initramfs.c linux= -2.6.32.49/init/initramfs.c } return 0; } -@@ -280,11 +280,11 @@ static void __init clean_path(char *path +@@ -280,11 +280,11 @@ static void __init clean_path(char *path, mode_t m= ode) { struct stat st; =20 @@ -67563,22 +69826,11 @@ diff -urNp linux-2.6.32.49/init/initramfs.c lin= ux-2.6.32.49/init/initramfs.c state =3D SkipIt; next_state =3D Reset; return 0; -diff -urNp linux-2.6.32.49/init/Kconfig linux-2.6.32.49/init/Kconfig ---- linux-2.6.32.49/init/Kconfig 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/init/Kconfig 2011-11-15 19:59:43.000000000 -0500 -@@ -1004,7 +1004,7 @@ config SLUB_DEBUG -=20 - config COMPAT_BRK - bool "Disable heap randomization" -- default y -+ default n - help - Randomizing heap placement makes heap exploits harder, but it - also breaks ancient binaries (including anything libc5 based). -diff -urNp linux-2.6.32.49/init/main.c linux-2.6.32.49/init/main.c ---- linux-2.6.32.49/init/main.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/init/main.c 2011-11-15 19:59:43.000000000 -0500 -@@ -97,6 +97,7 @@ static inline void mark_rodata_ro(void)=20 +diff --git a/init/main.c b/init/main.c +index 1eb4bd5..da8c6f5 100644 +--- a/init/main.c ++++ b/init/main.c +@@ -97,6 +97,7 @@ static inline void mark_rodata_ro(void) { } #ifdef CONFIG_TC extern void tc_init(void); #endif @@ -67586,7 +69838,7 @@ diff -urNp linux-2.6.32.49/init/main.c linux-2.6.= 32.49/init/main.c =20 enum system_states system_state __read_mostly; EXPORT_SYMBOL(system_state); -@@ -183,6 +184,49 @@ static int __init set_reset_devices(char +@@ -183,6 +184,49 @@ static int __init set_reset_devices(char *str) =20 __setup("reset_devices", set_reset_devices); =20 @@ -67706,7 +69958,7 @@ diff -urNp linux-2.6.32.49/init/main.c linux-2.6.= 32.49/init/main.c } =20 =20 -@@ -893,11 +938,13 @@ static int __init kernel_init(void * unu +@@ -893,11 +938,13 @@ static int __init kernel_init(void * unused) if (!ramdisk_execute_command) ramdisk_execute_command =3D "/init"; =20 @@ -67721,9 +69973,10 @@ diff -urNp linux-2.6.32.49/init/main.c linux-2.6= .32.49/init/main.c /* * Ok, we have completed the initial bootup, and * we're essentially up and running. Get rid of the -diff -urNp linux-2.6.32.49/init/noinitramfs.c linux-2.6.32.49/init/noini= tramfs.c ---- linux-2.6.32.49/init/noinitramfs.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/init/noinitramfs.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/init/noinitramfs.c b/init/noinitramfs.c +index f4c1a3a..96c19bd 100644 +--- a/init/noinitramfs.c ++++ b/init/noinitramfs.c @@ -29,7 +29,7 @@ static int __init default_rootfs(void) { int err; @@ -67742,10 +69995,11 @@ diff -urNp linux-2.6.32.49/init/noinitramfs.c l= inux-2.6.32.49/init/noinitramfs.c if (err < 0) goto out; =20 -diff -urNp linux-2.6.32.49/ipc/mqueue.c linux-2.6.32.49/ipc/mqueue.c ---- linux-2.6.32.49/ipc/mqueue.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/ipc/mqueue.c 2011-11-15 19:59:43.000000000 -0500 -@@ -150,6 +150,7 @@ static struct inode *mqueue_get_inode(st +diff --git a/ipc/mqueue.c b/ipc/mqueue.c +index d01bc14..8df81db 100644 +--- a/ipc/mqueue.c ++++ b/ipc/mqueue.c +@@ -150,6 +150,7 @@ static struct inode *mqueue_get_inode(struct super_b= lock *sb, mq_bytes =3D (mq_msg_tblsz + (info->attr.mq_maxmsg * info->attr.mq_msgsize)); =20 @@ -67753,10 +70007,11 @@ diff -urNp linux-2.6.32.49/ipc/mqueue.c linux-2= .6.32.49/ipc/mqueue.c spin_lock(&mq_lock); if (u->mq_bytes + mq_bytes < u->mq_bytes || u->mq_bytes + mq_bytes > -diff -urNp linux-2.6.32.49/ipc/msg.c linux-2.6.32.49/ipc/msg.c ---- linux-2.6.32.49/ipc/msg.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/ipc/msg.c 2011-11-15 19:59:43.000000000 -0500 -@@ -310,18 +310,19 @@ static inline int msg_security(struct ke +diff --git a/ipc/msg.c b/ipc/msg.c +index 779f762..4af9e36 100644 +--- a/ipc/msg.c ++++ b/ipc/msg.c +@@ -310,18 +310,19 @@ static inline int msg_security(struct kern_ipc_per= m *ipcp, int msgflg) return security_msg_queue_associate(msq, msgflg); } =20 @@ -67781,10 +70036,11 @@ diff -urNp linux-2.6.32.49/ipc/msg.c linux-2.6.= 32.49/ipc/msg.c msg_params.key =3D key; msg_params.flg =3D msgflg; =20 -diff -urNp linux-2.6.32.49/ipc/sem.c linux-2.6.32.49/ipc/sem.c ---- linux-2.6.32.49/ipc/sem.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/ipc/sem.c 2011-11-15 19:59:43.000000000 -0500 -@@ -309,10 +309,15 @@ static inline int sem_more_checks(struct +diff --git a/ipc/sem.c b/ipc/sem.c +index b781007..f738b04 100644 +--- a/ipc/sem.c ++++ b/ipc/sem.c +@@ -309,10 +309,15 @@ static inline int sem_more_checks(struct kern_ipc_= perm *ipcp, return 0; } =20 @@ -67801,7 +70057,7 @@ diff -urNp linux-2.6.32.49/ipc/sem.c linux-2.6.32= .49/ipc/sem.c struct ipc_params sem_params; =20 ns =3D current->nsproxy->ipc_ns; -@@ -320,10 +325,6 @@ SYSCALL_DEFINE3(semget, key_t, key, int, +@@ -320,10 +325,6 @@ SYSCALL_DEFINE3(semget, key_t, key, int, nsems, int= , semflg) if (nsems < 0 || nsems > ns->sc_semmsl) return -EINVAL; =20 @@ -67812,7 +70068,7 @@ diff -urNp linux-2.6.32.49/ipc/sem.c linux-2.6.32= .49/ipc/sem.c sem_params.key =3D key; sem_params.flg =3D semflg; sem_params.u.nsems =3D nsems; -@@ -671,6 +672,8 @@ static int semctl_main(struct ipc_namesp +@@ -671,6 +672,8 @@ static int semctl_main(struct ipc_namespace *ns, int= semid, int semnum, ushort* sem_io =3D fast_sem_io; int nsems; =20 @@ -67821,7 +70077,7 @@ diff -urNp linux-2.6.32.49/ipc/sem.c linux-2.6.32= .49/ipc/sem.c sma =3D sem_lock_check(ns, semid); if (IS_ERR(sma)) return PTR_ERR(sma); -@@ -1071,6 +1074,8 @@ SYSCALL_DEFINE4(semtimedop, int, semid,=20 +@@ -1071,6 +1074,8 @@ SYSCALL_DEFINE4(semtimedop, int, semid, struct sem= buf __user *, tsops, unsigned long jiffies_left =3D 0; struct ipc_namespace *ns; =20 @@ -67830,10 +70086,11 @@ diff -urNp linux-2.6.32.49/ipc/sem.c linux-2.6.= 32.49/ipc/sem.c ns =3D current->nsproxy->ipc_ns; =20 if (nsops < 1 || semid < 0) -diff -urNp linux-2.6.32.49/ipc/shm.c linux-2.6.32.49/ipc/shm.c ---- linux-2.6.32.49/ipc/shm.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/ipc/shm.c 2011-11-15 19:59:43.000000000 -0500 -@@ -70,6 +70,14 @@ static void shm_destroy (struct ipc_name +diff --git a/ipc/shm.c b/ipc/shm.c +index d30732c..7379456 100644 +--- a/ipc/shm.c ++++ b/ipc/shm.c +@@ -70,6 +70,14 @@ static void shm_destroy (struct ipc_namespace *ns, st= ruct shmid_kernel *shp); static int sysvipc_shm_proc_show(struct seq_file *s, void *it); #endif =20 @@ -67848,7 +70105,7 @@ diff -urNp linux-2.6.32.49/ipc/shm.c linux-2.6.32= .49/ipc/shm.c void shm_init_ns(struct ipc_namespace *ns) { ns->shm_ctlmax =3D SHMMAX; -@@ -396,6 +404,14 @@ static int newseg(struct ipc_namespace * +@@ -396,6 +404,14 @@ static int newseg(struct ipc_namespace *ns, struct = ipc_params *params) shp->shm_lprid =3D 0; shp->shm_atim =3D shp->shm_dtim =3D 0; shp->shm_ctim =3D get_seconds(); @@ -67863,7 +70120,7 @@ diff -urNp linux-2.6.32.49/ipc/shm.c linux-2.6.32= .49/ipc/shm.c shp->shm_segsz =3D size; shp->shm_nattch =3D 0; shp->shm_file =3D file; -@@ -446,18 +462,19 @@ static inline int shm_more_checks(struct +@@ -446,18 +462,19 @@ static inline int shm_more_checks(struct kern_ipc_= perm *ipcp, return 0; } =20 @@ -67888,7 +70145,7 @@ diff -urNp linux-2.6.32.49/ipc/shm.c linux-2.6.32= .49/ipc/shm.c shm_params.key =3D key; shm_params.flg =3D shmflg; shm_params.u.size =3D size; -@@ -880,9 +897,21 @@ long do_shmat(int shmid, char __user *sh +@@ -880,9 +897,21 @@ long do_shmat(int shmid, char __user *shmaddr, int = shmflg, ulong *raddr) if (err) goto out_unlock; =20 @@ -67910,10 +70167,11 @@ diff -urNp linux-2.6.32.49/ipc/shm.c linux-2.6.= 32.49/ipc/shm.c size =3D i_size_read(path.dentry->d_inode); shm_unlock(shp); =20 -diff -urNp linux-2.6.32.49/kernel/acct.c linux-2.6.32.49/kernel/acct.c ---- linux-2.6.32.49/kernel/acct.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/acct.c 2011-11-15 19:59:43.000000000 -0500 -@@ -579,7 +579,7 @@ static void do_acct_process(struct bsd_a +diff --git a/kernel/acct.c b/kernel/acct.c +index a6605ca..ca91111 100644 +--- a/kernel/acct.c ++++ b/kernel/acct.c +@@ -579,7 +579,7 @@ static void do_acct_process(struct bsd_acct_struct *= acct, */ flim =3D current->signal->rlim[RLIMIT_FSIZE].rlim_cur; current->signal->rlim[RLIMIT_FSIZE].rlim_cur =3D RLIM_INFINITY; @@ -67922,9 +70180,10 @@ diff -urNp linux-2.6.32.49/kernel/acct.c linux-2= .6.32.49/kernel/acct.c sizeof(acct_t), &file->f_pos); current->signal->rlim[RLIMIT_FSIZE].rlim_cur =3D flim; set_fs(fs); -diff -urNp linux-2.6.32.49/kernel/audit.c linux-2.6.32.49/kernel/audit.c ---- linux-2.6.32.49/kernel/audit.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/audit.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/audit.c b/kernel/audit.c +index 5feed23..513b02c 100644 +--- a/kernel/audit.c ++++ b/kernel/audit.c @@ -110,7 +110,7 @@ u32 audit_sig_sid =3D 0; 3) suppressed due to audit_rate_limit 4) suppressed due to audit_backlog_limit @@ -67952,7 +70211,7 @@ diff -urNp linux-2.6.32.49/kernel/audit.c linux-2= .6.32.49/kernel/audit.c audit_rate_limit, audit_backlog_limit); audit_panic(message); -@@ -691,7 +691,7 @@ static int audit_receive_msg(struct sk_b +@@ -691,7 +691,7 @@ static int audit_receive_msg(struct sk_buff *skb, st= ruct nlmsghdr *nlh) status_set.pid =3D audit_pid; status_set.rate_limit =3D audit_rate_limit; status_set.backlog_limit =3D audit_backlog_limit; @@ -67961,7 +70220,7 @@ diff -urNp linux-2.6.32.49/kernel/audit.c linux-2= .6.32.49/kernel/audit.c status_set.backlog =3D skb_queue_len(&audit_skb_queue); audit_send_reply(NETLINK_CB(skb).pid, seq, AUDIT_GET, 0, 0, &status_set, sizeof(status_set)); -@@ -891,8 +891,10 @@ static int audit_receive_msg(struct sk_b +@@ -891,8 +891,10 @@ static int audit_receive_msg(struct sk_buff *skb, s= truct nlmsghdr *nlh) spin_unlock_irq(&tsk->sighand->siglock); } read_unlock(&tasklist_lock); @@ -67974,10 +70233,11 @@ diff -urNp linux-2.6.32.49/kernel/audit.c linux= -2.6.32.49/kernel/audit.c break; } case AUDIT_TTY_SET: { -diff -urNp linux-2.6.32.49/kernel/auditsc.c linux-2.6.32.49/kernel/audit= sc.c ---- linux-2.6.32.49/kernel/auditsc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/auditsc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -2113,7 +2113,7 @@ int auditsc_get_stamp(struct audit_conte +diff --git a/kernel/auditsc.c b/kernel/auditsc.c +index 267e484..f8e295a 100644 +--- a/kernel/auditsc.c ++++ b/kernel/auditsc.c +@@ -2113,7 +2113,7 @@ int auditsc_get_stamp(struct audit_context *ctx, } =20 /* global counter which is incremented every time something logs in */ @@ -67986,7 +70246,7 @@ diff -urNp linux-2.6.32.49/kernel/auditsc.c linux= -2.6.32.49/kernel/auditsc.c =20 /** * audit_set_loginuid - set a task's audit_context loginuid -@@ -2126,7 +2126,7 @@ static atomic_t session_id =3D ATOMIC_INIT +@@ -2126,7 +2126,7 @@ static atomic_t session_id =3D ATOMIC_INIT(0); */ int audit_set_loginuid(struct task_struct *task, uid_t loginuid) { @@ -67995,9 +70255,10 @@ diff -urNp linux-2.6.32.49/kernel/auditsc.c linu= x-2.6.32.49/kernel/auditsc.c struct audit_context *context =3D task->audit_context; =20 if (context && context->in_syscall) { -diff -urNp linux-2.6.32.49/kernel/capability.c linux-2.6.32.49/kernel/ca= pability.c ---- linux-2.6.32.49/kernel/capability.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/kernel/capability.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/kernel/capability.c b/kernel/capability.c +index 8a944f5..db5001e 100644 +--- a/kernel/capability.c ++++ b/kernel/capability.c @@ -305,10 +305,26 @@ int capable(int cap) BUG(); } @@ -68026,9 +70287,10 @@ diff -urNp linux-2.6.32.49/kernel/capability.c l= inux-2.6.32.49/kernel/capability + EXPORT_SYMBOL(capable); +EXPORT_SYMBOL(capable_nolog); -diff -urNp linux-2.6.32.49/kernel/cgroup.c linux-2.6.32.49/kernel/cgroup= .c ---- linux-2.6.32.49/kernel/cgroup.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/cgroup.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/cgroup.c b/kernel/cgroup.c +index 1fbcc74..7000012 100644 +--- a/kernel/cgroup.c ++++ b/kernel/cgroup.c @@ -536,6 +536,8 @@ static struct css_set *find_css_set( struct hlist_head *hhead; struct cg_cgroup_link *link; @@ -68038,10 +70300,11 @@ diff -urNp linux-2.6.32.49/kernel/cgroup.c linu= x-2.6.32.49/kernel/cgroup.c /* First see if we already have a cgroup group that matches * the desired set */ read_lock(&css_set_lock); -diff -urNp linux-2.6.32.49/kernel/compat.c linux-2.6.32.49/kernel/compat= .c ---- linux-2.6.32.49/kernel/compat.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/compat.c 2011-11-15 19:59:43.000000000 -0500 -@@ -108,7 +108,7 @@ static long compat_nanosleep_restart(str +diff --git a/kernel/compat.c b/kernel/compat.c +index 8bc5578..186e44a 100644 +--- a/kernel/compat.c ++++ b/kernel/compat.c +@@ -108,7 +108,7 @@ static long compat_nanosleep_restart(struct restart_= block *restart) mm_segment_t oldfs; long ret; =20 @@ -68050,7 +70313,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c oldfs =3D get_fs(); set_fs(KERNEL_DS); ret =3D hrtimer_nanosleep_restart(restart); -@@ -140,7 +140,7 @@ asmlinkage long compat_sys_nanosleep(str +@@ -140,7 +140,7 @@ asmlinkage long compat_sys_nanosleep(struct compat_t= imespec __user *rqtp, oldfs =3D get_fs(); set_fs(KERNEL_DS); ret =3D hrtimer_nanosleep(&tu, @@ -68059,7 +70322,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c HRTIMER_MODE_REL, CLOCK_MONOTONIC); set_fs(oldfs); =20 -@@ -247,7 +247,7 @@ asmlinkage long compat_sys_sigpending(co +@@ -247,7 +247,7 @@ asmlinkage long compat_sys_sigpending(compat_old_sig= set_t __user *set) mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -68068,7 +70331,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(old_fs); if (ret =3D=3D 0) ret =3D put_user(s, set); -@@ -266,8 +266,8 @@ asmlinkage long compat_sys_sigprocmask(i +@@ -266,8 +266,8 @@ asmlinkage long compat_sys_sigprocmask(int how, comp= at_old_sigset_t __user *set, old_fs =3D get_fs(); set_fs(KERNEL_DS); ret =3D sys_sigprocmask(how, @@ -68079,7 +70342,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(old_fs); if (ret =3D=3D 0) if (oset) -@@ -310,7 +310,7 @@ asmlinkage long compat_sys_old_getrlimit +@@ -310,7 +310,7 @@ asmlinkage long compat_sys_old_getrlimit(unsigned in= t resource, mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -68088,7 +70351,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(old_fs); =20 if (!ret) { -@@ -385,7 +385,7 @@ asmlinkage long compat_sys_getrusage(int +@@ -385,7 +385,7 @@ asmlinkage long compat_sys_getrusage(int who, struct= compat_rusage __user *ru) mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -68097,7 +70360,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(old_fs); =20 if (ret) -@@ -412,8 +412,8 @@ compat_sys_wait4(compat_pid_t pid, compa +@@ -412,8 +412,8 @@ compat_sys_wait4(compat_pid_t pid, compat_uint_t __u= ser *stat_addr, int options, set_fs (KERNEL_DS); ret =3D sys_wait4(pid, (stat_addr ? @@ -68108,7 +70371,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs (old_fs); =20 if (ret > 0) { -@@ -438,8 +438,8 @@ asmlinkage long compat_sys_waitid(int wh +@@ -438,8 +438,8 @@ asmlinkage long compat_sys_waitid(int which, compat_= pid_t pid, memset(&info, 0, sizeof(info)); =20 set_fs(KERNEL_DS); @@ -68119,7 +70382,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(old_fs); =20 if ((ret < 0) || (info.si_signo =3D=3D 0)) -@@ -569,8 +569,8 @@ long compat_sys_timer_settime(timer_t ti +@@ -569,8 +569,8 @@ long compat_sys_timer_settime(timer_t timer_id, int = flags, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_timer_settime(timer_id, flags, @@ -68130,7 +70393,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(oldfs); if (!err && old && put_compat_itimerspec(old, &oldts)) return -EFAULT; -@@ -587,7 +587,7 @@ long compat_sys_timer_gettime(timer_t ti +@@ -587,7 +587,7 @@ long compat_sys_timer_gettime(timer_t timer_id, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_timer_gettime(timer_id, @@ -68139,7 +70402,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(oldfs); if (!err && put_compat_itimerspec(setting, &ts)) return -EFAULT; -@@ -606,7 +606,7 @@ long compat_sys_clock_settime(clockid_t=20 +@@ -606,7 +606,7 @@ long compat_sys_clock_settime(clockid_t which_clock, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_settime(which_clock, @@ -68148,7 +70411,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(oldfs); return err; } -@@ -621,7 +621,7 @@ long compat_sys_clock_gettime(clockid_t=20 +@@ -621,7 +621,7 @@ long compat_sys_clock_gettime(clockid_t which_clock, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_gettime(which_clock, @@ -68157,7 +70420,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(oldfs); if (!err && put_compat_timespec(&ts, tp)) return -EFAULT; -@@ -638,7 +638,7 @@ long compat_sys_clock_getres(clockid_t w +@@ -638,7 +638,7 @@ long compat_sys_clock_getres(clockid_t which_clock, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_getres(which_clock, @@ -68166,7 +70429,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c set_fs(oldfs); if (!err && tp && put_compat_timespec(&ts, tp)) return -EFAULT; -@@ -650,9 +650,9 @@ static long compat_clock_nanosleep_resta +@@ -650,9 +650,9 @@ static long compat_clock_nanosleep_restart(struct re= start_block *restart) long err; mm_segment_t oldfs; struct timespec tu; @@ -68178,7 +70441,7 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux-= 2.6.32.49/kernel/compat.c oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D clock_nanosleep_restart(restart); -@@ -684,8 +684,8 @@ long compat_sys_clock_nanosleep(clockid_ +@@ -684,8 +684,8 @@ long compat_sys_clock_nanosleep(clockid_t which_cloc= k, int flags, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_nanosleep(which_clock, flags, @@ -68189,9 +70452,10 @@ diff -urNp linux-2.6.32.49/kernel/compat.c linux= -2.6.32.49/kernel/compat.c set_fs(oldfs); =20 if ((err =3D=3D -ERESTART_RESTARTBLOCK) && rmtp && -diff -urNp linux-2.6.32.49/kernel/configs.c linux-2.6.32.49/kernel/confi= gs.c ---- linux-2.6.32.49/kernel/configs.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/configs.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/configs.c b/kernel/configs.c +index abaee68..047facd 100644 +--- a/kernel/configs.c ++++ b/kernel/configs.c @@ -73,8 +73,19 @@ static int __init ikconfig_init(void) struct proc_dir_entry *entry; =20 @@ -68212,9 +70476,10 @@ diff -urNp linux-2.6.32.49/kernel/configs.c linu= x-2.6.32.49/kernel/configs.c if (!entry) return -ENOMEM; =20 -diff -urNp linux-2.6.32.49/kernel/cpu.c linux-2.6.32.49/kernel/cpu.c ---- linux-2.6.32.49/kernel/cpu.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/cpu.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/cpu.c b/kernel/cpu.c +index 7e8b6ac..8921388 100644 +--- a/kernel/cpu.c ++++ b/kernel/cpu.c @@ -19,7 +19,7 @@ /* Serializes the updates to cpu_online_mask, cpu_present_mask */ static DEFINE_MUTEX(cpu_add_remove_lock); @@ -68224,10 +70489,11 @@ diff -urNp linux-2.6.32.49/kernel/cpu.c linux-2= .6.32.49/kernel/cpu.c =20 /* If set, cpu_up and cpu_down will return -EBUSY and do nothing. * Should always be manipulated under cpu_add_remove_lock -diff -urNp linux-2.6.32.49/kernel/cred.c linux-2.6.32.49/kernel/cred.c ---- linux-2.6.32.49/kernel/cred.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/cred.c 2011-11-15 19:59:43.000000000 -0500 -@@ -160,6 +160,8 @@ static void put_cred_rcu(struct rcu_head +diff --git a/kernel/cred.c b/kernel/cred.c +index 0b5b5fc..419b86a 100644 +--- a/kernel/cred.c ++++ b/kernel/cred.c +@@ -160,6 +160,8 @@ static void put_cred_rcu(struct rcu_head *rcu) */ void __put_cred(struct cred *cred) { @@ -68245,7 +70511,7 @@ diff -urNp linux-2.6.32.49/kernel/cred.c linux-2.= 6.32.49/kernel/cred.c kdebug("exit_creds(%u,%p,%p,{%d,%d})", tsk->pid, tsk->real_cred, tsk->= cred, atomic_read(&tsk->cred->usage), read_cred_subscribers(tsk->cred)); -@@ -222,6 +226,8 @@ const struct cred *get_task_cred(struct=20 +@@ -222,6 +226,8 @@ const struct cred *get_task_cred(struct task_struct = *task) { const struct cred *cred; =20 @@ -68281,7 +70547,7 @@ diff -urNp linux-2.6.32.49/kernel/cred.c linux-2.= 6.32.49/kernel/cred.c #ifdef CONFIG_KEYS tgcred =3D kmalloc(sizeof(*tgcred), GFP_KERNEL); if (!tgcred) -@@ -441,6 +453,8 @@ int copy_creds(struct task_struct *p, un +@@ -441,6 +453,8 @@ int copy_creds(struct task_struct *p, unsigned long = clone_flags) struct cred *new; int ret; =20 @@ -68330,7 +70596,7 @@ diff -urNp linux-2.6.32.49/kernel/cred.c linux-2.= 6.32.49/kernel/cred.c kdebug("abort_creds(%p{%d,%d})", new, atomic_read(&new->usage), read_cred_subscribers(new)); -@@ -629,6 +647,8 @@ const struct cred *override_creds(const=20 +@@ -629,6 +647,8 @@ const struct cred *override_creds(const struct cred = *new) { const struct cred *old =3D current->cred; =20 @@ -68339,7 +70605,7 @@ diff -urNp linux-2.6.32.49/kernel/cred.c linux-2.= 6.32.49/kernel/cred.c kdebug("override_creds(%p{%d,%d})", new, atomic_read(&new->usage), read_cred_subscribers(new)); -@@ -658,6 +678,8 @@ void revert_creds(const struct cred *old +@@ -658,6 +678,8 @@ void revert_creds(const struct cred *old) { const struct cred *override =3D current->cred; =20 @@ -68348,7 +70614,7 @@ diff -urNp linux-2.6.32.49/kernel/cred.c linux-2.= 6.32.49/kernel/cred.c kdebug("revert_creds(%p{%d,%d})", old, atomic_read(&old->usage), read_cred_subscribers(old)); -@@ -704,6 +726,8 @@ struct cred *prepare_kernel_cred(struct=20 +@@ -704,6 +726,8 @@ struct cred *prepare_kernel_cred(struct task_struct = *daemon) const struct cred *old; struct cred *new; =20 @@ -68366,7 +70632,7 @@ diff -urNp linux-2.6.32.49/kernel/cred.c linux-2.= 6.32.49/kernel/cred.c return security_kernel_act_as(new, secid); } EXPORT_SYMBOL(set_security_override); -@@ -777,6 +803,8 @@ int set_security_override_from_ctx(struc +@@ -777,6 +803,8 @@ int set_security_override_from_ctx(struct cred *new,= const char *secctx) u32 secid; int ret; =20 @@ -68375,9 +70641,10 @@ diff -urNp linux-2.6.32.49/kernel/cred.c linux-2= .6.32.49/kernel/cred.c ret =3D security_secctx_to_secid(secctx, strlen(secctx), &secid); if (ret < 0) return ret; -diff -urNp linux-2.6.32.49/kernel/exit.c linux-2.6.32.49/kernel/exit.c ---- linux-2.6.32.49/kernel/exit.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/exit.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/exit.c b/kernel/exit.c +index 0f8fae3..11757f1 100644 +--- a/kernel/exit.c ++++ b/kernel/exit.c @@ -55,6 +55,10 @@ #include #include @@ -68389,7 +70656,7 @@ diff -urNp linux-2.6.32.49/kernel/exit.c linux-2.= 6.32.49/kernel/exit.c static void exit_mm(struct task_struct * tsk); =20 static void __unhash_process(struct task_struct *p) -@@ -174,6 +178,10 @@ void release_task(struct task_struct * p +@@ -174,6 +178,10 @@ void release_task(struct task_struct * p) struct task_struct *leader; int zap_leader; repeat: @@ -68499,7 +70766,7 @@ diff -urNp linux-2.6.32.49/kernel/exit.c linux-2.= 6.32.49/kernel/exit.c exit_mm(tsk); =20 if (group_dead) -@@ -1188,7 +1228,7 @@ static int wait_task_zombie(struct wait_ +@@ -1188,7 +1228,7 @@ static int wait_task_zombie(struct wait_opts *wo, = struct task_struct *p) =20 if (unlikely(wo->wo_flags & WNOWAIT)) { int exit_code =3D p->exit_code; @@ -68508,10 +70775,11 @@ diff -urNp linux-2.6.32.49/kernel/exit.c linux-= 2.6.32.49/kernel/exit.c =20 get_task_struct(p); read_unlock(&tasklist_lock); -diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.6.32.49/kernel/fork.c ---- linux-2.6.32.49/kernel/fork.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/fork.c 2011-11-15 19:59:43.000000000 -0500 -@@ -253,7 +253,7 @@ static struct task_struct *dup_task_stru +diff --git a/kernel/fork.c b/kernel/fork.c +index 4bde56f..29a9bab 100644 +--- a/kernel/fork.c ++++ b/kernel/fork.c +@@ -253,7 +253,7 @@ static struct task_struct *dup_task_struct(struct ta= sk_struct *orig) *stackend =3D STACK_END_MAGIC; /* for overflow detection */ =20 #ifdef CONFIG_CC_STACKPROTECTOR @@ -68520,7 +70788,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c #endif =20 /* One for us, one for whoever does the "release_task()" (usually pare= nt) */ -@@ -293,8 +293,8 @@ static int dup_mmap(struct mm_struct *mm +@@ -293,8 +293,8 @@ static int dup_mmap(struct mm_struct *mm, struct mm_= struct *oldmm) mm->locked_vm =3D 0; mm->mmap =3D NULL; mm->mmap_cache =3D NULL; @@ -68531,7 +70799,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c mm->map_count =3D 0; cpumask_clear(mm_cpumask(mm)); mm->mm_rb =3D RB_ROOT; -@@ -335,6 +335,7 @@ static int dup_mmap(struct mm_struct *mm +@@ -335,6 +335,7 @@ static int dup_mmap(struct mm_struct *mm, struct mm_= struct *oldmm) tmp->vm_flags &=3D ~VM_LOCKED; tmp->vm_mm =3D mm; tmp->vm_next =3D tmp->vm_prev =3D NULL; @@ -68539,7 +70807,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c anon_vma_link(tmp); file =3D tmp->vm_file; if (file) { -@@ -384,6 +385,31 @@ static int dup_mmap(struct mm_struct *mm +@@ -384,6 +385,31 @@ static int dup_mmap(struct mm_struct *mm, struct mm= _struct *oldmm) if (retval) goto out; } @@ -68571,7 +70839,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c /* a new mm has just been created */ arch_dup_mmap(oldmm, mm); retval =3D 0; -@@ -734,13 +760,14 @@ static int copy_fs(unsigned long clone_f +@@ -734,13 +760,14 @@ static int copy_fs(unsigned long clone_flags, stru= ct task_struct *tsk) write_unlock(&fs->lock); return -EAGAIN; } @@ -68587,7 +70855,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c return 0; } =20 -@@ -1033,12 +1060,16 @@ static struct task_struct *copy_process( +@@ -1033,12 +1060,16 @@ static struct task_struct *copy_process(unsigned= long clone_flags, DEBUG_LOCKS_WARN_ON(!p->softirqs_enabled); #endif retval =3D -EAGAIN; @@ -68606,7 +70874,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c =20 retval =3D copy_creds(p, clone_flags); if (retval < 0) -@@ -1183,6 +1214,8 @@ static struct task_struct *copy_process( +@@ -1183,6 +1214,8 @@ static struct task_struct *copy_process(unsigned l= ong clone_flags, goto bad_fork_free_pid; } =20 @@ -68633,7 +70901,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c if (clone_flags & CLONE_VFORK) { p->vfork_done =3D &vfork; init_completion(&vfork); -@@ -1558,7 +1595,7 @@ static int unshare_fs(unsigned long unsh +@@ -1558,7 +1595,7 @@ static int unshare_fs(unsigned long unshare_flags,= struct fs_struct **new_fsp) return 0; =20 /* don't need lock here; in the worst case we'll do useless copy */ @@ -68642,7 +70910,7 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2.= 6.32.49/kernel/fork.c return 0; =20 *new_fsp =3D copy_fs_struct(fs); -@@ -1681,7 +1718,8 @@ SYSCALL_DEFINE1(unshare, unsigned long,=20 +@@ -1681,7 +1718,8 @@ SYSCALL_DEFINE1(unshare, unsigned long, unshare_fl= ags) fs =3D current->fs; write_lock(&fs->lock); current->fs =3D new_fs; @@ -68652,9 +70920,10 @@ diff -urNp linux-2.6.32.49/kernel/fork.c linux-2= .6.32.49/kernel/fork.c new_fs =3D NULL; else new_fs =3D fs; -diff -urNp linux-2.6.32.49/kernel/futex.c linux-2.6.32.49/kernel/futex.c ---- linux-2.6.32.49/kernel/futex.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/futex.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/futex.c b/kernel/futex.c +index fb98c9f..f158c0c 100644 +--- a/kernel/futex.c ++++ b/kernel/futex.c @@ -54,6 +54,7 @@ #include #include @@ -68663,7 +70932,7 @@ diff -urNp linux-2.6.32.49/kernel/futex.c linux-2= .6.32.49/kernel/futex.c #include #include #include -@@ -223,6 +224,11 @@ get_futex_key(u32 __user *uaddr, int fsh +@@ -223,6 +224,11 @@ get_futex_key(u32 __user *uaddr, int fshared, union= futex_key *key, int rw) struct page *page; int err, ro =3D 0; =20 @@ -68675,7 +70944,7 @@ diff -urNp linux-2.6.32.49/kernel/futex.c linux-2= .6.32.49/kernel/futex.c /* * The futex address must be "naturally" aligned. */ -@@ -1819,6 +1825,8 @@ static int futex_wait(u32 __user *uaddr, +@@ -1819,6 +1825,8 @@ static int futex_wait(u32 __user *uaddr, int fshar= ed, struct futex_q q; int ret; =20 @@ -68693,7 +70962,7 @@ diff -urNp linux-2.6.32.49/kernel/futex.c linux-2= .6.32.49/kernel/futex.c restart->futex.val =3D val; restart->futex.time =3D abs_time->tv64; restart->futex.bitset =3D bitset; -@@ -2233,6 +2241,8 @@ static int futex_wait_requeue_pi(u32 __u +@@ -2233,6 +2241,8 @@ static int futex_wait_requeue_pi(u32 __user *uaddr= , int fshared, struct futex_q q; int res, ret; =20 @@ -68702,7 +70971,7 @@ diff -urNp linux-2.6.32.49/kernel/futex.c linux-2= .6.32.49/kernel/futex.c if (!bitset) return -EINVAL; =20 -@@ -2407,7 +2417,9 @@ SYSCALL_DEFINE3(get_robust_list, int, pi +@@ -2407,7 +2417,9 @@ SYSCALL_DEFINE3(get_robust_list, int, pid, { struct robust_list_head __user *head; unsigned long ret; @@ -68712,7 +70981,7 @@ diff -urNp linux-2.6.32.49/kernel/futex.c linux-2= .6.32.49/kernel/futex.c =20 if (!futex_cmpxchg_enabled) return -ENOSYS; -@@ -2423,11 +2435,16 @@ SYSCALL_DEFINE3(get_robust_list, int, pi +@@ -2423,11 +2435,16 @@ SYSCALL_DEFINE3(get_robust_list, int, pid, if (!p) goto err_unlock; ret =3D -EPERM; @@ -68757,9 +71026,10 @@ diff -urNp linux-2.6.32.49/kernel/futex.c linux-= 2.6.32.49/kernel/futex.c if (curval =3D=3D -EFAULT) futex_cmpxchg_enabled =3D 1; =20 -diff -urNp linux-2.6.32.49/kernel/futex_compat.c linux-2.6.32.49/kernel/= futex_compat.c ---- linux-2.6.32.49/kernel/futex_compat.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/kernel/futex_compat.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/kernel/futex_compat.c b/kernel/futex_compat.c +index 2357165..8d70cee 100644 +--- a/kernel/futex_compat.c ++++ b/kernel/futex_compat.c @@ -10,6 +10,7 @@ #include #include @@ -68768,7 +71038,7 @@ diff -urNp linux-2.6.32.49/kernel/futex_compat.c = linux-2.6.32.49/kernel/futex_co =20 #include =20 -@@ -135,7 +136,10 @@ compat_sys_get_robust_list(int pid, comp +@@ -135,7 +136,10 @@ compat_sys_get_robust_list(int pid, compat_uptr_t _= _user *head_ptr, { struct compat_robust_list_head __user *head; unsigned long ret; @@ -68780,7 +71050,7 @@ diff -urNp linux-2.6.32.49/kernel/futex_compat.c = linux-2.6.32.49/kernel/futex_co =20 if (!futex_cmpxchg_enabled) return -ENOSYS; -@@ -151,11 +155,16 @@ compat_sys_get_robust_list(int pid, comp +@@ -151,11 +155,16 @@ compat_sys_get_robust_list(int pid, compat_uptr_t = __user *head_ptr, if (!p) goto err_unlock; ret =3D -EPERM; @@ -68797,9 +71067,10 @@ diff -urNp linux-2.6.32.49/kernel/futex_compat.c= linux-2.6.32.49/kernel/futex_co head =3D p->compat_robust_list; read_unlock(&tasklist_lock); } -diff -urNp linux-2.6.32.49/kernel/gcov/base.c linux-2.6.32.49/kernel/gco= v/base.c ---- linux-2.6.32.49/kernel/gcov/base.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/kernel/gcov/base.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/kernel/gcov/base.c b/kernel/gcov/base.c +index 9b22d03..6295b62 100644 +--- a/kernel/gcov/base.c ++++ b/kernel/gcov/base.c @@ -102,11 +102,6 @@ void gcov_enable_events(void) } =20 @@ -68812,7 +71083,7 @@ diff -urNp linux-2.6.32.49/kernel/gcov/base.c lin= ux-2.6.32.49/kernel/gcov/base.c /* Update list and generate events when modules are unloaded. */ static int gcov_module_notifier(struct notifier_block *nb, unsigned lon= g event, void *data) -@@ -121,7 +116,7 @@ static int gcov_module_notifier(struct n +@@ -121,7 +116,7 @@ static int gcov_module_notifier(struct notifier_bloc= k *nb, unsigned long event, prev =3D NULL; /* Remove entries located in module from linked list. */ for (info =3D gcov_info_head; info; info =3D info->next) { @@ -68821,9 +71092,10 @@ diff -urNp linux-2.6.32.49/kernel/gcov/base.c li= nux-2.6.32.49/kernel/gcov/base.c if (prev) prev->next =3D info->next; else -diff -urNp linux-2.6.32.49/kernel/hrtimer.c linux-2.6.32.49/kernel/hrtim= er.c ---- linux-2.6.32.49/kernel/hrtimer.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/hrtimer.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c +index a6e9d00..a0da4f9 100644 +--- a/kernel/hrtimer.c ++++ b/kernel/hrtimer.c @@ -1391,7 +1391,7 @@ void hrtimer_peek_ahead_timers(void) local_irq_restore(flags); } @@ -68833,9 +71105,10 @@ diff -urNp linux-2.6.32.49/kernel/hrtimer.c linu= x-2.6.32.49/kernel/hrtimer.c { hrtimer_peek_ahead_timers(); } -diff -urNp linux-2.6.32.49/kernel/kallsyms.c linux-2.6.32.49/kernel/kall= syms.c ---- linux-2.6.32.49/kernel/kallsyms.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/kernel/kallsyms.c 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c +index 8b6b8b6..6bc87df 100644 +--- a/kernel/kallsyms.c ++++ b/kernel/kallsyms.c @@ -11,6 +11,9 @@ * Changed the compression method from stem compression to "table = lookup" * compression (see scripts/kallsyms.c for a more complete descrip= tion) @@ -68846,7 +71119,7 @@ diff -urNp linux-2.6.32.49/kernel/kallsyms.c linu= x-2.6.32.49/kernel/kallsyms.c #include #include #include -@@ -51,12 +54,33 @@ extern const unsigned long kallsyms_mark +@@ -51,12 +54,33 @@ extern const unsigned long kallsyms_markers[] __attr= ibute__((weak)); =20 static inline int is_kernel_inittext(unsigned long addr) { @@ -68880,7 +71153,7 @@ diff -urNp linux-2.6.32.49/kernel/kallsyms.c linu= x-2.6.32.49/kernel/kallsyms.c static inline int is_kernel_text(unsigned long addr) { if ((addr >=3D (unsigned long)_stext && addr <=3D (unsigned long)_etex= t) || -@@ -67,13 +91,28 @@ static inline int is_kernel_text(unsigne +@@ -67,13 +91,28 @@ static inline int is_kernel_text(unsigned long addr) =20 static inline int is_kernel(unsigned long addr) { @@ -68909,7 +71182,7 @@ diff -urNp linux-2.6.32.49/kernel/kallsyms.c linu= x-2.6.32.49/kernel/kallsyms.c if (all_var) return is_kernel(addr); =20 -@@ -413,7 +452,6 @@ static unsigned long get_ksymbol_core(st +@@ -413,7 +452,6 @@ static unsigned long get_ksymbol_core(struct kallsym= _iter *iter) =20 static void reset_iter(struct kallsym_iter *iter, loff_t new_pos) { @@ -68917,7 +71190,7 @@ diff -urNp linux-2.6.32.49/kernel/kallsyms.c linu= x-2.6.32.49/kernel/kallsyms.c iter->nameoff =3D get_symbol_offset(new_pos); iter->pos =3D new_pos; } -@@ -461,6 +499,11 @@ static int s_show(struct seq_file *m, vo +@@ -461,6 +499,11 @@ static int s_show(struct seq_file *m, void *p) { struct kallsym_iter *iter =3D m->private; =20 @@ -68929,7 +71202,7 @@ diff -urNp linux-2.6.32.49/kernel/kallsyms.c linu= x-2.6.32.49/kernel/kallsyms.c /* Some debugging symbols have no name. Ignore them. */ if (!iter->name[0]) return 0; -@@ -501,7 +544,7 @@ static int kallsyms_open(struct inode *i +@@ -501,7 +544,7 @@ static int kallsyms_open(struct inode *inode, struct= file *file) struct kallsym_iter *iter; int ret; =20 @@ -68938,10 +71211,11 @@ diff -urNp linux-2.6.32.49/kernel/kallsyms.c li= nux-2.6.32.49/kernel/kallsyms.c if (!iter) return -ENOMEM; reset_iter(iter, 0); -diff -urNp linux-2.6.32.49/kernel/kexec.c linux-2.6.32.49/kernel/kexec.c ---- linux-2.6.32.49/kernel/kexec.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/kexec.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1028,7 +1028,8 @@ asmlinkage long compat_sys_kexec_load(un +diff --git a/kernel/kexec.c b/kernel/kexec.c +index f336e21..9c1c20b 100644 +--- a/kernel/kexec.c ++++ b/kernel/kexec.c +@@ -1028,7 +1028,8 @@ asmlinkage long compat_sys_kexec_load(unsigned lon= g entry, unsigned long flags) { struct compat_kexec_segment in; @@ -68951,9 +71225,10 @@ diff -urNp linux-2.6.32.49/kernel/kexec.c linux-= 2.6.32.49/kernel/kexec.c unsigned long i, result; =20 /* Don't allow clients that don't understand the native -diff -urNp linux-2.6.32.49/kernel/kgdb.c linux-2.6.32.49/kernel/kgdb.c ---- linux-2.6.32.49/kernel/kgdb.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/kgdb.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/kgdb.c b/kernel/kgdb.c +index 53dae4b..9ba3743 100644 +--- a/kernel/kgdb.c ++++ b/kernel/kgdb.c @@ -86,7 +86,7 @@ static int kgdb_io_module_registered; /* Guard for recursive entry */ static int exception_level; @@ -68963,7 +71238,7 @@ diff -urNp linux-2.6.32.49/kernel/kgdb.c linux-2.= 6.32.49/kernel/kgdb.c static DEFINE_SPINLOCK(kgdb_registration_lock); =20 /* kgdb console driver is loaded */ -@@ -123,7 +123,7 @@ atomic_t kgdb_active =3D ATOMIC_INIT(-1) +@@ -123,7 +123,7 @@ atomic_t kgdb_active =3D ATOMIC_INIT(-1); */ static atomic_t passive_cpu_wait[NR_CPUS]; static atomic_t cpu_in_kgdb[NR_CPUS]; @@ -68972,7 +71247,7 @@ diff -urNp linux-2.6.32.49/kernel/kgdb.c linux-2.= 6.32.49/kernel/kgdb.c =20 struct task_struct *kgdb_usethread; struct task_struct *kgdb_contthread; -@@ -140,7 +140,7 @@ static unsigned long gdb_regs[(NUMREGBY +@@ -140,7 +140,7 @@ static unsigned long gdb_regs[(NUMREGBYTES + sizeof(unsigned long)]; =20 /* to keep track of the CPU which is doing the single stepping*/ @@ -69001,7 +71276,7 @@ diff -urNp linux-2.6.32.49/kernel/kgdb.c linux-2.= 6.32.49/kernel/kgdb.c =20 atomic_set(&kgdb_active, -1); touch_softlockup_watchdog(); -@@ -1634,7 +1634,7 @@ static void kgdb_initial_breakpoint(void +@@ -1634,7 +1634,7 @@ static void kgdb_initial_breakpoint(void) * * Register it with the KGDB core. */ @@ -69010,7 +71285,7 @@ diff -urNp linux-2.6.32.49/kernel/kgdb.c linux-2.= 6.32.49/kernel/kgdb.c { int err; =20 -@@ -1679,7 +1679,7 @@ EXPORT_SYMBOL_GPL(kgdb_register_io_modul +@@ -1679,7 +1679,7 @@ EXPORT_SYMBOL_GPL(kgdb_register_io_module); * * Unregister it with the KGDB core. */ @@ -69019,7 +71294,7 @@ diff -urNp linux-2.6.32.49/kernel/kgdb.c linux-2.= 6.32.49/kernel/kgdb.c { BUG_ON(kgdb_connected); =20 -@@ -1712,11 +1712,11 @@ EXPORT_SYMBOL_GPL(kgdb_unregister_io_mod +@@ -1712,11 +1712,11 @@ EXPORT_SYMBOL_GPL(kgdb_unregister_io_module); */ void kgdb_breakpoint(void) { @@ -69033,10 +71308,11 @@ diff -urNp linux-2.6.32.49/kernel/kgdb.c linux-= 2.6.32.49/kernel/kgdb.c } EXPORT_SYMBOL_GPL(kgdb_breakpoint); =20 -diff -urNp linux-2.6.32.49/kernel/kmod.c linux-2.6.32.49/kernel/kmod.c ---- linux-2.6.32.49/kernel/kmod.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/kmod.c 2011-11-15 19:59:43.000000000 -0500 -@@ -65,13 +65,12 @@ char modprobe_path[KMOD_PATH_LEN] =3D "/sb +diff --git a/kernel/kmod.c b/kernel/kmod.c +index d206078..e27ba6a 100644 +--- a/kernel/kmod.c ++++ b/kernel/kmod.c +@@ -65,13 +65,12 @@ char modprobe_path[KMOD_PATH_LEN] =3D "/sbin/modprob= e"; * If module auto-loading support is disabled then this function * becomes a no-operation. */ @@ -69052,7 +71328,7 @@ diff -urNp linux-2.6.32.49/kernel/kmod.c linux-2.= 6.32.49/kernel/kmod.c static char *envp[] =3D { "HOME=3D/", "TERM=3Dlinux", "PATH=3D/sbin:/usr/sbin:/bin:/usr/bin", -@@ -84,12 +83,24 @@ int __request_module(bool wait, const ch +@@ -84,12 +83,24 @@ int __request_module(bool wait, const char *fmt, ...= ) if (ret) return ret; =20 @@ -69080,7 +71356,7 @@ diff -urNp linux-2.6.32.49/kernel/kmod.c linux-2.= 6.32.49/kernel/kmod.c /* If modprobe needs a service that is in a module, we get a recursive * loop. Limit the number of running kmod threads to max_threads/2 or * MAX_KMOD_CONCURRENT, whichever is the smaller. A cleaner method -@@ -123,6 +134,48 @@ int __request_module(bool wait, const ch +@@ -123,6 +134,48 @@ int __request_module(bool wait, const char *fmt, ..= .) atomic_dec(&kmod_concurrent); return ret; } @@ -69138,10 +71414,11 @@ diff -urNp linux-2.6.32.49/kernel/kmod.c linux-= 2.6.32.49/kernel/kmod.c =20 /* * If ret is 0, either ____call_usermodehelper failed and the -diff -urNp linux-2.6.32.49/kernel/kprobes.c linux-2.6.32.49/kernel/kprob= es.c ---- linux-2.6.32.49/kernel/kprobes.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/kprobes.c 2011-11-15 19:59:43.000000000 -0500 -@@ -183,7 +183,7 @@ static kprobe_opcode_t __kprobes *__get_ +diff --git a/kernel/kprobes.c b/kernel/kprobes.c +index 5240d75..5a6fb33 100644 +--- a/kernel/kprobes.c ++++ b/kernel/kprobes.c +@@ -183,7 +183,7 @@ static kprobe_opcode_t __kprobes *__get_insn_slot(vo= id) * kernel image and loaded module images reside. This is required * so x86_64 can correctly handle the %rip-relative fixups. */ @@ -69150,7 +71427,7 @@ diff -urNp linux-2.6.32.49/kernel/kprobes.c linux= -2.6.32.49/kernel/kprobes.c if (!kip->insns) { kfree(kip); return NULL; -@@ -220,7 +220,7 @@ static int __kprobes collect_one_slot(st +@@ -220,7 +220,7 @@ static int __kprobes collect_one_slot(struct kprobe_= insn_page *kip, int idx) */ if (!list_is_singular(&kprobe_insn_pages)) { list_del(&kip->list); @@ -69168,7 +71445,7 @@ diff -urNp linux-2.6.32.49/kernel/kprobes.c linux= -2.6.32.49/kernel/kprobes.c const char *symbol_name; void *addr; struct kprobe_blackpoint *kb; -@@ -1304,7 +1304,7 @@ static int __kprobes show_kprobe_addr(st +@@ -1304,7 +1304,7 @@ static int __kprobes show_kprobe_addr(struct seq_f= ile *pi, void *v) const char *sym =3D NULL; unsigned int i =3D *(loff_t *) v; unsigned long offset =3D 0; @@ -69177,10 +71454,11 @@ diff -urNp linux-2.6.32.49/kernel/kprobes.c lin= ux-2.6.32.49/kernel/kprobes.c =20 head =3D &kprobe_table[i]; preempt_disable(); -diff -urNp linux-2.6.32.49/kernel/lockdep.c linux-2.6.32.49/kernel/lockd= ep.c ---- linux-2.6.32.49/kernel/lockdep.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/lockdep.c 2011-11-15 19:59:43.000000000 -0500 -@@ -421,20 +421,20 @@ static struct stack_trace lockdep_init_t +diff --git a/kernel/lockdep.c b/kernel/lockdep.c +index d86fe89..d12fc66 100644 +--- a/kernel/lockdep.c ++++ b/kernel/lockdep.c +@@ -421,20 +421,20 @@ static struct stack_trace lockdep_init_trace =3D { /* * Various lockdep statistics: */ @@ -69236,7 +71514,7 @@ diff -urNp linux-2.6.32.49/kernel/lockdep.c linux= -2.6.32.49/kernel/lockdep.c =20 if ((addr >=3D start) && (addr < end)) return 1; -@@ -710,6 +713,7 @@ register_lock_class(struct lockdep_map * +@@ -710,6 +713,7 @@ register_lock_class(struct lockdep_map *lock, unsign= ed int subclass, int force) if (!static_obj(lock->key)) { debug_locks_off(); printk("INFO: trying to register non-static key.\n"); @@ -69244,7 +71522,7 @@ diff -urNp linux-2.6.32.49/kernel/lockdep.c linux= -2.6.32.49/kernel/lockdep.c printk("the code is fine but needs lockdep annotation.\n"); printk("turning off the locking correctness validator.\n"); dump_stack(); -@@ -2751,7 +2755,7 @@ static int __lock_acquire(struct lockdep +@@ -2751,7 +2755,7 @@ static int __lock_acquire(struct lockdep_map *lock= , unsigned int subclass, if (!class) return 0; } @@ -69253,10 +71531,11 @@ diff -urNp linux-2.6.32.49/kernel/lockdep.c lin= ux-2.6.32.49/kernel/lockdep.c if (very_verbose(class)) { printk("\nacquire class [%p] %s", class->key, class->name); if (class->name_version > 1) -diff -urNp linux-2.6.32.49/kernel/lockdep_internals.h linux-2.6.32.49/ke= rnel/lockdep_internals.h ---- linux-2.6.32.49/kernel/lockdep_internals.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/kernel/lockdep_internals.h 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -113,26 +113,26 @@ lockdep_count_backward_deps(struct lock_ +diff --git a/kernel/lockdep_internals.h b/kernel/lockdep_internals.h +index a2ee95a..092f0f2 100644 +--- a/kernel/lockdep_internals.h ++++ b/kernel/lockdep_internals.h +@@ -113,26 +113,26 @@ lockdep_count_backward_deps(struct lock_class *cla= ss) /* * Various lockdep statistics: */ @@ -69303,10 +71582,11 @@ diff -urNp linux-2.6.32.49/kernel/lockdep_inter= nals.h linux-2.6.32.49/kernel/loc #else # define debug_atomic_inc(ptr) do { } while (0) # define debug_atomic_dec(ptr) do { } while (0) -diff -urNp linux-2.6.32.49/kernel/lockdep_proc.c linux-2.6.32.49/kernel/= lockdep_proc.c ---- linux-2.6.32.49/kernel/lockdep_proc.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/kernel/lockdep_proc.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -39,7 +39,7 @@ static void l_stop(struct seq_file *m, v +diff --git a/kernel/lockdep_proc.c b/kernel/lockdep_proc.c +index d4aba4f..02a353f 100644 +--- a/kernel/lockdep_proc.c ++++ b/kernel/lockdep_proc.c +@@ -39,7 +39,7 @@ static void l_stop(struct seq_file *m, void *v) =20 static void print_name(struct seq_file *m, struct lock_class *class) { @@ -69315,9 +71595,10 @@ diff -urNp linux-2.6.32.49/kernel/lockdep_proc.c= linux-2.6.32.49/kernel/lockdep_ const char *name =3D class->name; =20 if (!name) { -diff -urNp linux-2.6.32.49/kernel/module.c linux-2.6.32.49/kernel/module= .c ---- linux-2.6.32.49/kernel/module.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/module.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/module.c b/kernel/module.c +index 4b270e6..2226274 100644 +--- a/kernel/module.c ++++ b/kernel/module.c @@ -55,6 +55,7 @@ #include #include @@ -69326,7 +71607,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 #define CREATE_TRACE_POINTS #include -@@ -89,7 +90,8 @@ static DECLARE_WAIT_QUEUE_HEAD(module_wq +@@ -89,7 +90,8 @@ static DECLARE_WAIT_QUEUE_HEAD(module_wq); static BLOCKING_NOTIFIER_HEAD(module_notify_list); =20 /* Bounds of module allocation, for speeding __module_address */ @@ -69336,7 +71617,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 int register_module_notifier(struct notifier_block * nb) { -@@ -245,7 +247,7 @@ bool each_symbol(bool (*fn)(const struct +@@ -245,7 +247,7 @@ bool each_symbol(bool (*fn)(const struct symsearch *= arr, struct module *owner, return true; =20 list_for_each_entry_rcu(mod, &modules, list) { @@ -69345,7 +71626,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c { mod->syms, mod->syms + mod->num_syms, mod->crcs, NOT_GPL_ONLY, false }, { mod->gpl_syms, mod->gpl_syms + mod->num_gpl_syms, -@@ -267,7 +269,7 @@ bool each_symbol(bool (*fn)(const struct +@@ -267,7 +269,7 @@ bool each_symbol(bool (*fn)(const struct symsearch *= arr, struct module *owner, #endif }; =20 @@ -69354,7 +71635,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c return true; } return false; -@@ -442,7 +444,7 @@ static void *percpu_modalloc(unsigned lo +@@ -442,7 +444,7 @@ static void *percpu_modalloc(unsigned long size, uns= igned long align, void *ptr; int cpu; =20 @@ -69363,7 +71644,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c printk(KERN_WARNING "%s: per-cpu alignment %li > %li\n", name, align, PAGE_SIZE); align =3D PAGE_SIZE; -@@ -1158,7 +1160,7 @@ static const struct kernel_symbol *resol +@@ -1158,7 +1160,7 @@ static const struct kernel_symbol *resolve_symbol(= Elf_Shdr *sechdrs, * /sys/module/foo/sections stuff * J. Corbet */ @@ -69372,7 +71653,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 static inline bool sect_empty(const Elf_Shdr *sect) { -@@ -1545,7 +1547,8 @@ static void free_module(struct module *m +@@ -1545,7 +1547,8 @@ static void free_module(struct module *mod) destroy_params(mod->kp, mod->num_kp); =20 /* This may be NULL, but that's OK */ @@ -69382,7 +71663,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c kfree(mod->args); if (mod->percpu) percpu_modfree(mod->percpu); -@@ -1554,10 +1557,12 @@ static void free_module(struct module *m +@@ -1554,10 +1557,12 @@ static void free_module(struct module *mod) percpu_modfree(mod->refptr); #endif /* Free lock-classes: */ @@ -69397,7 +71678,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 #ifdef CONFIG_MPU update_protections(current->mm); -@@ -1628,8 +1633,32 @@ static int simplify_symbols(Elf_Shdr *se +@@ -1628,8 +1633,32 @@ static int simplify_symbols(Elf_Shdr *sechdrs, unsigned int i, n =3D sechdrs[symindex].sh_size / sizeof(Elf_Sym); int ret =3D 0; const struct kernel_symbol *ksym; @@ -69430,7 +71711,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c switch (sym[i].st_shndx) { case SHN_COMMON: /* We compiled with -fno-common. These are not -@@ -1651,7 +1680,9 @@ static int simplify_symbols(Elf_Shdr *se +@@ -1651,7 +1680,9 @@ static int simplify_symbols(Elf_Shdr *sechdrs, strtab + sym[i].st_name, mod); /* Ok if resolved. */ if (ksym) { @@ -69440,7 +71721,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c break; } =20 -@@ -1670,11 +1701,20 @@ static int simplify_symbols(Elf_Shdr *se +@@ -1670,11 +1701,20 @@ static int simplify_symbols(Elf_Shdr *sechdrs, secbase =3D (unsigned long)mod->percpu; else secbase =3D sechdrs[sym[i].st_shndx].sh_addr; @@ -69461,7 +71742,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c return ret; } =20 -@@ -1731,11 +1771,12 @@ static void layout_sections(struct modul +@@ -1731,11 +1771,12 @@ static void layout_sections(struct module *mod, || s->sh_entsize !=3D ~0UL || strstarts(secstrings + s->sh_name, ".init")) continue; @@ -69477,7 +71758,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c } =20 DEBUGP("Init section allocation order:\n"); -@@ -1748,12 +1789,13 @@ static void layout_sections(struct modul +@@ -1748,12 +1789,13 @@ static void layout_sections(struct module *mod, || s->sh_entsize !=3D ~0UL || !strstarts(secstrings + s->sh_name, ".init")) continue; @@ -69495,7 +71776,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c } } =20 -@@ -1857,9 +1899,8 @@ static int is_exported(const char *name, +@@ -1857,9 +1899,8 @@ static int is_exported(const char *name, unsigned = long value, =20 /* As per nm */ static char elf_type(const Elf_Sym *sym, @@ -69507,7 +71788,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c { if (ELF_ST_BIND(sym->st_info) =3D=3D STB_WEAK) { if (ELF_ST_TYPE(sym->st_info) =3D=3D STT_OBJECT) -@@ -1934,7 +1975,7 @@ static unsigned long layout_symtab(struc +@@ -1934,7 +1975,7 @@ static unsigned long layout_symtab(struct module *= mod, =20 /* Put symbol section at end of init part of module. */ symsect->sh_flags |=3D SHF_ALLOC; @@ -69516,7 +71797,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c symindex) | INIT_OFFSET_MASK; DEBUGP("\t%s\n", secstrings + symsect->sh_name); =20 -@@ -1951,19 +1992,19 @@ static unsigned long layout_symtab(struc +@@ -1951,19 +1992,19 @@ static unsigned long layout_symtab(struct module= *mod, } =20 /* Append room for core symbols at end of core part. */ @@ -69541,7 +71822,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 return symoffs; } -@@ -1987,12 +2028,14 @@ static void add_kallsyms(struct module * +@@ -1987,12 +2028,14 @@ static void add_kallsyms(struct module *mod, mod->num_symtab =3D sechdrs[symindex].sh_size / sizeof(Elf_Sym); mod->strtab =3D (void *)sechdrs[strindex].sh_addr; =20 @@ -69558,7 +71839,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c src =3D mod->symtab; *dst =3D *src; for (ndst =3D i =3D 1; i < mod->num_symtab; ++i, ++src) { -@@ -2004,10 +2047,12 @@ static void add_kallsyms(struct module * +@@ -2004,10 +2047,12 @@ static void add_kallsyms(struct module *mod, } mod->core_num_syms =3D ndst; =20 @@ -69572,7 +71853,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c } #else static inline unsigned long layout_symtab(struct module *mod, -@@ -2044,16 +2089,30 @@ static void dynamic_debug_setup(struct _ +@@ -2044,16 +2089,30 @@ static void dynamic_debug_setup(struct _ddebug *= debug, unsigned int num) #endif } =20 @@ -69608,7 +71889,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c } return ret; } -@@ -2065,8 +2124,8 @@ static void kmemleak_load_module(struct=20 +@@ -2065,8 +2124,8 @@ static void kmemleak_load_module(struct module *mo= d, Elf_Ehdr *hdr, unsigned int i; =20 /* only scan the sections containing data */ @@ -69619,7 +71900,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c sizeof(struct module), GFP_KERNEL); =20 for (i =3D 1; i < hdr->e_shnum; i++) { -@@ -2076,8 +2135,8 @@ static void kmemleak_load_module(struct=20 +@@ -2076,8 +2135,8 @@ static void kmemleak_load_module(struct module *mo= d, Elf_Ehdr *hdr, && strncmp(secstrings + sechdrs[i].sh_name, ".bss", 4) !=3D 0) continue; =20 @@ -69630,7 +71911,31 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux= -2.6.32.49/kernel/module.c sechdrs[i].sh_size, GFP_KERNEL); } } -@@ -2263,7 +2322,7 @@ static noinline struct module *load_modu +@@ -2097,7 +2156,7 @@ static noinline struct module *load_module(void __= user *umod, + Elf_Ehdr *hdr; + Elf_Shdr *sechdrs; + char *secstrings, *args, *modmagic, *strtab =3D NULL; +- char *staging; ++ char *staging, *license; + unsigned int i; + unsigned int symindex =3D 0; + unsigned int strindex =3D 0; +@@ -2195,6 +2254,14 @@ static noinline struct module *load_module(void _= _user *umod, + goto free_hdr; + } +=20 ++ license =3D get_modinfo(sechdrs, infoindex, "license"); ++#ifdef CONFIG_PAX_KERNEXEC_PLUGIN_METHOD_OR ++ if (!license || !license_is_gpl_compatible(license)) { ++ err -ENOEXEC; ++ goto free_hdr; ++ } ++#endif ++ + modmagic =3D get_modinfo(sechdrs, infoindex, "vermagic"); + /* This is allowed: modprobe --force will invalidate it. */ + if (!modmagic) { +@@ -2263,7 +2330,7 @@ static noinline struct module *load_module(void __= user *umod, secstrings, &stroffs, strmap); =20 /* Do the allocs. */ @@ -69639,7 +71944,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c /* * The pointer to this block is stored in the module structure * which is inside the block. Just mark it as not being a -@@ -2274,23 +2333,47 @@ static noinline struct module *load_modu +@@ -2274,23 +2341,47 @@ static noinline struct module *load_module(void = __user *umod, err =3D -ENOMEM; goto free_percpu; } @@ -69669,12 +71974,9 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux= -2.6.32.49/kernel/module.c + ptr =3D module_alloc_update_bounds_rx(mod->core_size_rx); + kmemleak_not_leak(ptr); + if (!ptr) { - err =3D -ENOMEM; -- goto free_core; ++ err =3D -ENOMEM; + goto free_init_rw; - } -- memset(ptr, 0, mod->init_size); -- mod->module_init =3D ptr; ++ } + + pax_open_kernel(); + memset(ptr, 0, mod->core_size_rx); @@ -69684,9 +71986,12 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux= -2.6.32.49/kernel/module.c + ptr =3D module_alloc_update_bounds_rx(mod->init_size_rx); + kmemleak_not_leak(ptr); + if (!ptr && mod->init_size_rx) { -+ err =3D -ENOMEM; + err =3D -ENOMEM; +- goto free_core; + goto free_core_rx; -+ } + } +- memset(ptr, 0, mod->init_size); +- mod->module_init =3D ptr; + + pax_open_kernel(); + memset(ptr, 0, mod->init_size_rx); @@ -69695,7 +72000,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 /* Transfer each section which specifies SHF_ALLOC */ DEBUGP("final section addresses:\n"); -@@ -2300,17 +2383,45 @@ static noinline struct module *load_modu +@@ -2300,17 +2391,45 @@ static noinline struct module *load_module(void = __user *umod, if (!(sechdrs[i].sh_flags & SHF_ALLOC)) continue; =20 @@ -69717,12 +72022,12 @@ diff -urNp linux-2.6.32.49/kernel/module.c linu= x-2.6.32.49/kernel/module.c + else + dest =3D mod->module_core_rx + sechdrs[i].sh_entsize; + } -+ -+ if (sechdrs[i].sh_type !=3D SHT_NOBITS) { =20 - if (sechdrs[i].sh_type !=3D SHT_NOBITS) - memcpy(dest, (void *)sechdrs[i].sh_addr, - sechdrs[i].sh_size); ++ if (sechdrs[i].sh_type !=3D SHT_NOBITS) { ++ +#ifdef CONFIG_PAX_KERNEXEC +#ifdef CONFIG_X86_64 + if ((sechdrs[i].sh_flags & SHF_WRITE) && (sechdrs[i].sh_flags & SHF_= EXECINSTR)) @@ -69750,7 +72055,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c DEBUGP("\t0x%lx %s\n", sechdrs[i].sh_addr, secstrings + sechdrs[i].sh= _name); } /* Module has been moved. */ -@@ -2322,7 +2433,7 @@ static noinline struct module *load_modu +@@ -2322,7 +2441,7 @@ static noinline struct module *load_module(void __= user *umod, mod->name); if (!mod->refptr) { err =3D -ENOMEM; @@ -69759,7 +72064,16 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux= -2.6.32.49/kernel/module.c } #endif /* Now we've moved module, initialize linked lists, etc. */ -@@ -2351,6 +2462,31 @@ static noinline struct module *load_modu +@@ -2334,7 +2453,7 @@ static noinline struct module *load_module(void __= user *umod, + goto free_unload; +=20 + /* Set up license info based on the info section */ +- set_license(mod, get_modinfo(sechdrs, infoindex, "license")); ++ set_license(mod, license); +=20 + /* + * ndiswrapper is under GPL by itself, but loads proprietary modules. +@@ -2351,6 +2470,31 @@ static noinline struct module *load_module(void _= _user *umod, /* Set up MODINFO_ATTR fields */ setup_modinfo(mod, sechdrs, infoindex); =20 @@ -69791,7 +72105,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c /* Fix up syms, so that st_value is a pointer to location. */ err =3D simplify_symbols(sechdrs, symindex, strtab, versindex, pcpuind= ex, mod); -@@ -2431,8 +2567,8 @@ static noinline struct module *load_modu +@@ -2431,8 +2575,8 @@ static noinline struct module *load_module(void __= user *umod, =20 /* Now do relocations. */ for (i =3D 1; i < hdr->e_shnum; i++) { @@ -69801,7 +72115,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 /* Not a valid relocation section? */ if (info >=3D hdr->e_shnum) -@@ -2493,16 +2629,15 @@ static noinline struct module *load_modu +@@ -2493,16 +2637,15 @@ static noinline struct module *load_module(void = __user *umod, * Do it before processing of module parameters, so the module * can provide parameter accessor functions of its own. */ @@ -69824,7 +72138,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c if (section_addr(hdr, sechdrs, secstrings, "__obsparm")) printk(KERN_WARNING "%s: Ignoring obsolete parameters\n", mod->name); -@@ -2546,12 +2681,16 @@ static noinline struct module *load_modu +@@ -2546,12 +2689,16 @@ static noinline struct module *load_module(void = __user *umod, free_unload: module_unload_free(mod); #if defined(CONFIG_MODULE_UNLOAD) && defined(CONFIG_SMP) @@ -69845,7 +72159,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c /* mod will be freed with core. Don't access it beyond this line! */ free_percpu: if (percpu) -@@ -2653,10 +2792,12 @@ SYSCALL_DEFINE3(init_module, void __user +@@ -2653,10 +2800,12 @@ SYSCALL_DEFINE3(init_module, void __user *, umod= , mod->symtab =3D mod->core_symtab; mod->strtab =3D mod->core_strtab; #endif @@ -69862,7 +72176,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c mutex_unlock(&module_mutex); =20 return 0; -@@ -2687,10 +2828,16 @@ static const char *get_ksymbol(struct mo +@@ -2687,10 +2836,16 @@ static const char *get_ksymbol(struct module *mo= d, unsigned long nextval; =20 /* At worse, next value is at end of module */ @@ -69882,7 +72196,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 /* Scan for closest preceeding symbol, and next symbol. (ELF starts real symbols at 1). */ -@@ -2936,7 +3083,7 @@ static int m_show(struct seq_file *m, vo +@@ -2936,7 +3091,7 @@ static int m_show(struct seq_file *m, void *p) char buf[8]; =20 seq_printf(m, "%s %u", @@ -69891,7 +72205,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c print_unload_info(m, mod); =20 /* Informative for users. */ -@@ -2945,7 +3092,7 @@ static int m_show(struct seq_file *m, vo +@@ -2945,7 +3100,7 @@ static int m_show(struct seq_file *m, void *p) mod->state =3D=3D MODULE_STATE_COMING ? "Loading": "Live"); /* Used by oprofile and other similar tools. */ @@ -69900,7 +72214,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c =20 /* Taints info */ if (mod->taints) -@@ -2981,7 +3128,17 @@ static const struct file_operations proc +@@ -2981,7 +3136,17 @@ static const struct file_operations proc_modules_= operations =3D { =20 static int __init proc_modules_init(void) { @@ -69918,7 +72232,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c return 0; } module_init(proc_modules_init); -@@ -3040,12 +3197,12 @@ struct module *__module_address(unsigned +@@ -3040,12 +3205,12 @@ struct module *__module_address(unsigned long ad= dr) { struct module *mod; =20 @@ -69934,7 +72248,7 @@ diff -urNp linux-2.6.32.49/kernel/module.c linux-= 2.6.32.49/kernel/module.c return mod; return NULL; } -@@ -3079,11 +3236,20 @@ bool is_module_text_address(unsigned lon +@@ -3079,11 +3244,20 @@ bool is_module_text_address(unsigned long addr) */ struct module *__module_text_address(unsigned long addr) { @@ -69958,50 +72272,11 @@ diff -urNp linux-2.6.32.49/kernel/module.c linu= x-2.6.32.49/kernel/module.c mod =3D NULL; } return mod; -diff -urNp linux-2.6.32.49/kernel/mutex.c linux-2.6.32.49/kernel/mutex.c ---- linux-2.6.32.49/kernel/mutex.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/mutex.c 2011-11-15 19:59:43.000000000 -0500 -@@ -169,7 +169,7 @@ __mutex_lock_common(struct mutex *lock,=20 - */ -=20 - for (;;) { -- struct thread_info *owner; -+ struct task_struct *owner; -=20 - /* - * If we own the BKL, then don't spin. The owner of -@@ -214,7 +214,7 @@ __mutex_lock_common(struct mutex *lock,=20 - spin_lock_mutex(&lock->wait_lock, flags); -=20 - debug_mutex_lock_common(lock, &waiter); -- debug_mutex_add_waiter(lock, &waiter, task_thread_info(task)); -+ debug_mutex_add_waiter(lock, &waiter, task); -=20 - /* add waiting tasks to the end of the waitqueue (FIFO): */ - list_add_tail(&waiter.list, &lock->wait_list); -@@ -243,8 +243,7 @@ __mutex_lock_common(struct mutex *lock,=20 - * TASK_UNINTERRUPTIBLE case.) - */ - if (unlikely(signal_pending_state(state, task))) { -- mutex_remove_waiter(lock, &waiter, -- task_thread_info(task)); -+ mutex_remove_waiter(lock, &waiter, task); - mutex_release(&lock->dep_map, 1, ip); - spin_unlock_mutex(&lock->wait_lock, flags); -=20 -@@ -265,7 +264,7 @@ __mutex_lock_common(struct mutex *lock,=20 - done: - lock_acquired(&lock->dep_map, ip); - /* got the lock - rejoice! */ -- mutex_remove_waiter(lock, &waiter, current_thread_info()); -+ mutex_remove_waiter(lock, &waiter, task); - mutex_set_owner(lock); -=20 - /* set it to 0 if there are no waiters left: */ -diff -urNp linux-2.6.32.49/kernel/mutex-debug.c linux-2.6.32.49/kernel/m= utex-debug.c ---- linux-2.6.32.49/kernel/mutex-debug.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/kernel/mutex-debug.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -49,21 +49,21 @@ void debug_mutex_free_waiter(struct mute +diff --git a/kernel/mutex-debug.c b/kernel/mutex-debug.c +index ec815a9..fe46e99 100644 +--- a/kernel/mutex-debug.c ++++ b/kernel/mutex-debug.c +@@ -49,21 +49,21 @@ void debug_mutex_free_waiter(struct mutex_waiter *wa= iter) } =20 void debug_mutex_add_waiter(struct mutex *lock, struct mutex_waiter *wa= iter, @@ -70029,7 +72304,7 @@ diff -urNp linux-2.6.32.49/kernel/mutex-debug.c l= inux-2.6.32.49/kernel/mutex-deb =20 list_del_init(&waiter->list); waiter->task =3D NULL; -@@ -75,7 +75,7 @@ void debug_mutex_unlock(struct mutex *lo +@@ -75,7 +75,7 @@ void debug_mutex_unlock(struct mutex *lock) return; =20 DEBUG_LOCKS_WARN_ON(lock->magic !=3D lock); @@ -70038,10 +72313,11 @@ diff -urNp linux-2.6.32.49/kernel/mutex-debug.c= linux-2.6.32.49/kernel/mutex-deb DEBUG_LOCKS_WARN_ON(!lock->wait_list.prev && !lock->wait_list.next); mutex_clear_owner(lock); } -diff -urNp linux-2.6.32.49/kernel/mutex-debug.h linux-2.6.32.49/kernel/m= utex-debug.h ---- linux-2.6.32.49/kernel/mutex-debug.h 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/kernel/mutex-debug.h 2011-11-15 19:59:43.000000000 -= 0500 -@@ -20,16 +20,16 @@ extern void debug_mutex_wake_waiter(stru +diff --git a/kernel/mutex-debug.h b/kernel/mutex-debug.h +index 6b2d735..372d3c4 100644 +--- a/kernel/mutex-debug.h ++++ b/kernel/mutex-debug.h +@@ -20,16 +20,16 @@ extern void debug_mutex_wake_waiter(struct mutex *lo= ck, extern void debug_mutex_free_waiter(struct mutex_waiter *waiter); extern void debug_mutex_add_waiter(struct mutex *lock, struct mutex_waiter *waiter, @@ -70061,9 +72337,51 @@ diff -urNp linux-2.6.32.49/kernel/mutex-debug.h = linux-2.6.32.49/kernel/mutex-deb } =20 static inline void mutex_clear_owner(struct mutex *lock) -diff -urNp linux-2.6.32.49/kernel/mutex.h linux-2.6.32.49/kernel/mutex.h ---- linux-2.6.32.49/kernel/mutex.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/mutex.h 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/mutex.c b/kernel/mutex.c +index f85644c..5ee9f77 100644 +--- a/kernel/mutex.c ++++ b/kernel/mutex.c +@@ -169,7 +169,7 @@ __mutex_lock_common(struct mutex *lock, long state, = unsigned int subclass, + */ +=20 + for (;;) { +- struct thread_info *owner; ++ struct task_struct *owner; +=20 + /* + * If we own the BKL, then don't spin. The owner of +@@ -214,7 +214,7 @@ __mutex_lock_common(struct mutex *lock, long state, = unsigned int subclass, + spin_lock_mutex(&lock->wait_lock, flags); +=20 + debug_mutex_lock_common(lock, &waiter); +- debug_mutex_add_waiter(lock, &waiter, task_thread_info(task)); ++ debug_mutex_add_waiter(lock, &waiter, task); +=20 + /* add waiting tasks to the end of the waitqueue (FIFO): */ + list_add_tail(&waiter.list, &lock->wait_list); +@@ -243,8 +243,7 @@ __mutex_lock_common(struct mutex *lock, long state, = unsigned int subclass, + * TASK_UNINTERRUPTIBLE case.) + */ + if (unlikely(signal_pending_state(state, task))) { +- mutex_remove_waiter(lock, &waiter, +- task_thread_info(task)); ++ mutex_remove_waiter(lock, &waiter, task); + mutex_release(&lock->dep_map, 1, ip); + spin_unlock_mutex(&lock->wait_lock, flags); +=20 +@@ -265,7 +264,7 @@ __mutex_lock_common(struct mutex *lock, long state, = unsigned int subclass, + done: + lock_acquired(&lock->dep_map, ip); + /* got the lock - rejoice! */ +- mutex_remove_waiter(lock, &waiter, current_thread_info()); ++ mutex_remove_waiter(lock, &waiter, task); + mutex_set_owner(lock); +=20 + /* set it to 0 if there are no waiters left: */ +diff --git a/kernel/mutex.h b/kernel/mutex.h +index 67578ca..4115fbf 100644 +--- a/kernel/mutex.h ++++ b/kernel/mutex.h @@ -19,7 +19,7 @@ #ifdef CONFIG_SMP static inline void mutex_set_owner(struct mutex *lock) @@ -70073,10 +72391,11 @@ diff -urNp linux-2.6.32.49/kernel/mutex.h linux= -2.6.32.49/kernel/mutex.h } =20 static inline void mutex_clear_owner(struct mutex *lock) -diff -urNp linux-2.6.32.49/kernel/panic.c linux-2.6.32.49/kernel/panic.c ---- linux-2.6.32.49/kernel/panic.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/panic.c 2011-11-15 19:59:43.000000000 -0500 -@@ -352,7 +352,7 @@ static void warn_slowpath_common(const c +diff --git a/kernel/panic.c b/kernel/panic.c +index 96b45d0..45c447a 100644 +--- a/kernel/panic.c ++++ b/kernel/panic.c +@@ -352,7 +352,7 @@ static void warn_slowpath_common(const char *file, i= nt line, void *caller, struc const char *board; =20 printk(KERN_WARNING "------------[ cut here ]------------\n"); @@ -70095,10 +72414,11 @@ diff -urNp linux-2.6.32.49/kernel/panic.c linux= -2.6.32.49/kernel/panic.c __builtin_return_address(0)); } EXPORT_SYMBOL(__stack_chk_fail); -diff -urNp linux-2.6.32.49/kernel/params.c linux-2.6.32.49/kernel/params= .c ---- linux-2.6.32.49/kernel/params.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/params.c 2011-11-15 19:59:43.000000000 -0500 -@@ -725,7 +725,7 @@ static ssize_t module_attr_store(struct=20 +diff --git a/kernel/params.c b/kernel/params.c +index d656c27..21e452c 100644 +--- a/kernel/params.c ++++ b/kernel/params.c +@@ -725,7 +725,7 @@ static ssize_t module_attr_store(struct kobject *kob= j, return ret; } =20 @@ -70107,7 +72427,7 @@ diff -urNp linux-2.6.32.49/kernel/params.c linux-= 2.6.32.49/kernel/params.c .show =3D module_attr_show, .store =3D module_attr_store, }; -@@ -739,7 +739,7 @@ static int uevent_filter(struct kset *ks +@@ -739,7 +739,7 @@ static int uevent_filter(struct kset *kset, struct k= object *kobj) return 0; } =20 @@ -70116,10 +72436,11 @@ diff -urNp linux-2.6.32.49/kernel/params.c linu= x-2.6.32.49/kernel/params.c .filter =3D uevent_filter, }; =20 -diff -urNp linux-2.6.32.49/kernel/perf_event.c linux-2.6.32.49/kernel/pe= rf_event.c ---- linux-2.6.32.49/kernel/perf_event.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/kernel/perf_event.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -77,7 +77,7 @@ int sysctl_perf_event_mlock __read_mostl +diff --git a/kernel/perf_event.c b/kernel/perf_event.c +index 37ebc14..9c121d9 100644 +--- a/kernel/perf_event.c ++++ b/kernel/perf_event.c +@@ -77,7 +77,7 @@ int sysctl_perf_event_mlock __read_mostly =3D 516; /* = 'free' kb per user */ */ int sysctl_perf_event_sample_rate __read_mostly =3D 100000; =20 @@ -70128,7 +72449,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event =20 /* * Lock for (sysadmin-configurable) event reservations: -@@ -1094,9 +1094,9 @@ static void __perf_event_sync_stat(struc +@@ -1094,9 +1094,9 @@ static void __perf_event_sync_stat(struct perf_eve= nt *event, * In order to keep per-task stats reliable we need to flip the event * values when we flip the contexts. */ @@ -70141,7 +72462,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event =20 swap(event->total_time_enabled, next_event->total_time_enabled); swap(event->total_time_running, next_event->total_time_running); -@@ -1552,7 +1552,7 @@ static u64 perf_event_read(struct perf_e +@@ -1552,7 +1552,7 @@ static u64 perf_event_read(struct perf_event *even= t) update_event_times(event); } =20 @@ -70150,7 +72471,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event } =20 /* -@@ -1790,11 +1790,11 @@ static int perf_event_read_group(struct=20 +@@ -1790,11 +1790,11 @@ static int perf_event_read_group(struct perf_eve= nt *event, values[n++] =3D 1 + leader->nr_siblings; if (read_format & PERF_FORMAT_TOTAL_TIME_ENABLED) { values[n++] =3D leader->total_time_enabled + @@ -70164,7 +72485,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event } =20 size =3D n * sizeof(u64); -@@ -1829,11 +1829,11 @@ static int perf_event_read_one(struct pe +@@ -1829,11 +1829,11 @@ static int perf_event_read_one(struct perf_event= *event, values[n++] =3D perf_event_read_value(event); if (read_format & PERF_FORMAT_TOTAL_TIME_ENABLED) { values[n++] =3D event->total_time_enabled + @@ -70178,7 +72499,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event } if (read_format & PERF_FORMAT_ID) values[n++] =3D primary_event_id(event); -@@ -1903,7 +1903,7 @@ static unsigned int perf_poll(struct fil +@@ -1903,7 +1903,7 @@ static unsigned int perf_poll(struct file *file, p= oll_table *wait) static void perf_event_reset(struct perf_event *event) { (void)perf_event_read(event); @@ -70187,7 +72508,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event perf_event_update_userpage(event); } =20 -@@ -2079,15 +2079,15 @@ void perf_event_update_userpage(struct p +@@ -2079,15 +2079,15 @@ void perf_event_update_userpage(struct perf_even= t *event) ++userpg->lock; barrier(); userpg->index =3D perf_event_index(event); @@ -70207,7 +72528,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event =20 barrier(); ++userpg->lock; -@@ -2903,14 +2903,14 @@ static void perf_output_read_one(struct=20 +@@ -2903,14 +2903,14 @@ static void perf_output_read_one(struct perf_out= put_handle *handle, u64 values[4]; int n =3D 0; =20 @@ -70225,7 +72546,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event } if (read_format & PERF_FORMAT_ID) values[n++] =3D primary_event_id(event); -@@ -2940,7 +2940,7 @@ static void perf_output_read_group(struc +@@ -2940,7 +2940,7 @@ static void perf_output_read_group(struct perf_out= put_handle *handle, if (leader !=3D event) leader->pmu->read(leader); =20 @@ -70234,7 +72555,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event if (read_format & PERF_FORMAT_ID) values[n++] =3D primary_event_id(leader); =20 -@@ -2952,7 +2952,7 @@ static void perf_output_read_group(struc +@@ -2952,7 +2952,7 @@ static void perf_output_read_group(struct perf_out= put_handle *handle, if (sub !=3D event) sub->pmu->read(sub); =20 @@ -70243,7 +72564,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event if (read_format & PERF_FORMAT_ID) values[n++] =3D primary_event_id(sub); =20 -@@ -3525,12 +3525,12 @@ static void perf_event_mmap_event(struct +@@ -3525,12 +3525,12 @@ static void perf_event_mmap_event(struct perf_mm= ap_event *mmap_event) * need to add enough zero bytes after the string to handle * the 64bit alignment we do later. */ @@ -70258,7 +72579,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event if (IS_ERR(name)) { name =3D strncpy(tmp, "//toolong", sizeof(tmp)); goto got_name; -@@ -3783,7 +3783,7 @@ static void perf_swevent_add(struct perf +@@ -3783,7 +3783,7 @@ static void perf_swevent_add(struct perf_event *ev= ent, u64 nr, { struct hw_perf_event *hwc =3D &event->hw; =20 @@ -70267,7 +72588,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event =20 if (!hwc->sample_period) return; -@@ -4040,9 +4040,9 @@ static void cpu_clock_perf_event_update( +@@ -4040,9 +4040,9 @@ static void cpu_clock_perf_event_update(struct per= f_event *event) u64 now; =20 now =3D cpu_clock(cpu); @@ -70280,7 +72601,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event } =20 static int cpu_clock_perf_event_enable(struct perf_event *event) -@@ -4050,7 +4050,7 @@ static int cpu_clock_perf_event_enable(s +@@ -4050,7 +4050,7 @@ static int cpu_clock_perf_event_enable(struct perf= _event *event) struct hw_perf_event *hwc =3D &event->hw; int cpu =3D raw_smp_processor_id(); =20 @@ -70289,7 +72610,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event perf_swevent_start_hrtimer(event); =20 return 0; -@@ -4082,9 +4082,9 @@ static void task_clock_perf_event_update +@@ -4082,9 +4082,9 @@ static void task_clock_perf_event_update(struct pe= rf_event *event, u64 now) u64 prev; s64 delta; =20 @@ -70301,7 +72622,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event } =20 static int task_clock_perf_event_enable(struct perf_event *event) -@@ -4094,7 +4094,7 @@ static int task_clock_perf_event_enable( +@@ -4094,7 +4094,7 @@ static int task_clock_perf_event_enable(struct per= f_event *event) =20 now =3D event->ctx->time; =20 @@ -70310,7 +72631,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event =20 perf_swevent_start_hrtimer(event); =20 -@@ -4289,7 +4289,7 @@ perf_event_alloc(struct perf_event_attr=20 +@@ -4289,7 +4289,7 @@ perf_event_alloc(struct perf_event_attr *attr, event->parent =3D parent_event; =20 event->ns =3D get_pid_ns(current->nsproxy->pid_ns); @@ -70319,7 +72640,7 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c li= nux-2.6.32.49/kernel/perf_event =20 event->state =3D PERF_EVENT_STATE_INACTIVE; =20 -@@ -4720,15 +4720,15 @@ static void sync_child_event(struct perf +@@ -4720,15 +4720,15 @@ static void sync_child_event(struct perf_event *= child_event, if (child_event->attr.inherit_stat) perf_event_read_event(child_event, child); =20 @@ -70339,9 +72660,10 @@ diff -urNp linux-2.6.32.49/kernel/perf_event.c l= inux-2.6.32.49/kernel/perf_event &parent_event->child_total_time_running); =20 /* -diff -urNp linux-2.6.32.49/kernel/pid.c linux-2.6.32.49/kernel/pid.c ---- linux-2.6.32.49/kernel/pid.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/pid.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/pid.c b/kernel/pid.c +index fce7198..4f23a7e 100644 +--- a/kernel/pid.c ++++ b/kernel/pid.c @@ -33,6 +33,7 @@ #include #include @@ -70350,7 +72672,7 @@ diff -urNp linux-2.6.32.49/kernel/pid.c linux-2.6= .32.49/kernel/pid.c #include #include #include -@@ -45,7 +46,7 @@ struct pid init_struct_pid =3D INIT_STRUCT +@@ -45,7 +46,7 @@ struct pid init_struct_pid =3D INIT_STRUCT_PID; =20 int pid_max =3D PID_MAX_DEFAULT; =20 @@ -70375,7 +72697,7 @@ diff -urNp linux-2.6.32.49/kernel/pid.c linux-2.6= .32.49/kernel/pid.c } =20 struct task_struct *find_task_by_vpid(pid_t vnr) -@@ -391,6 +399,11 @@ struct task_struct *find_task_by_vpid(pi +@@ -391,6 +399,11 @@ struct task_struct *find_task_by_vpid(pid_t vnr) return find_task_by_pid_ns(vnr, current->nsproxy->pid_ns); } =20 @@ -70387,9 +72709,10 @@ diff -urNp linux-2.6.32.49/kernel/pid.c linux-2.= 6.32.49/kernel/pid.c struct pid *get_task_pid(struct task_struct *task, enum pid_type type) { struct pid *pid; -diff -urNp linux-2.6.32.49/kernel/posix-cpu-timers.c linux-2.6.32.49/ker= nel/posix-cpu-timers.c ---- linux-2.6.32.49/kernel/posix-cpu-timers.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/kernel/posix-cpu-timers.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/kernel/posix-cpu-timers.c b/kernel/posix-cpu-timers.c +index 5c9dc22..d271117 100644 +--- a/kernel/posix-cpu-timers.c ++++ b/kernel/posix-cpu-timers.c @@ -6,6 +6,7 @@ #include #include @@ -70398,7 +72721,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-cpu-timer= s.c linux-2.6.32.49/kernel/posi #include #include #include -@@ -1697,7 +1698,7 @@ static long thread_cpu_nsleep_restart(st +@@ -1697,7 +1698,7 @@ static long thread_cpu_nsleep_restart(struct resta= rt_block *restart_block) =20 static __init int init_posix_cpu_timers(void) { @@ -70407,7 +72730,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-cpu-timer= s.c linux-2.6.32.49/kernel/posi .clock_getres =3D process_cpu_clock_getres, .clock_get =3D process_cpu_clock_get, .clock_set =3D do_posix_clock_nosettime, -@@ -1705,7 +1706,7 @@ static __init int init_posix_cpu_timers( +@@ -1705,7 +1706,7 @@ static __init int init_posix_cpu_timers(void) .nsleep =3D process_cpu_nsleep, .nsleep_restart =3D process_cpu_nsleep_restart, }; @@ -70416,9 +72739,10 @@ diff -urNp linux-2.6.32.49/kernel/posix-cpu-time= rs.c linux-2.6.32.49/kernel/posi .clock_getres =3D thread_cpu_clock_getres, .clock_get =3D thread_cpu_clock_get, .clock_set =3D do_posix_clock_nosettime, -diff -urNp linux-2.6.32.49/kernel/posix-timers.c linux-2.6.32.49/kernel/= posix-timers.c ---- linux-2.6.32.49/kernel/posix-timers.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/kernel/posix-timers.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/kernel/posix-timers.c b/kernel/posix-timers.c +index 5e76d22..cf1baeb 100644 +--- a/kernel/posix-timers.c ++++ b/kernel/posix-timers.c @@ -42,6 +42,7 @@ #include #include @@ -70436,7 +72760,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c = linux-2.6.32.49/kernel/posix-ti =20 /* * These ones are defined below. -@@ -157,8 +158,8 @@ static inline void unlock_timer(struct k +@@ -157,8 +158,8 @@ static inline void unlock_timer(struct k_itimer *tim= r, unsigned long flags) */ #define CLOCK_DISPATCH(clock, call, arglist) \ ((clock) < 0 ? posix_cpu_##call arglist : \ @@ -70447,7 +72771,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c = linux-2.6.32.49/kernel/posix-ti =20 /* * Default clock hook functions when the struct k_clock passed -@@ -172,7 +173,7 @@ static inline int common_clock_getres(co +@@ -172,7 +173,7 @@ static inline int common_clock_getres(const clockid_= t which_clock, struct timespec *tp) { tp->tv_sec =3D 0; @@ -70456,7 +72780,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c = linux-2.6.32.49/kernel/posix-ti return 0; } =20 -@@ -217,9 +218,11 @@ static inline int invalid_clockid(const=20 +@@ -217,9 +218,11 @@ static inline int invalid_clockid(const clockid_t w= hich_clock) return 0; if ((unsigned) which_clock >=3D MAX_CLOCKS) return 1; @@ -70470,7 +72794,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c = linux-2.6.32.49/kernel/posix-ti return 0; return 1; } -@@ -266,29 +269,29 @@ int posix_get_coarse_res(const clockid_t +@@ -266,29 +269,29 @@ int posix_get_coarse_res(const clockid_t which_clo= ck, struct timespec *tp) */ static __init int init_posix_timers(void) { @@ -70505,7 +72829,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c = linux-2.6.32.49/kernel/posix-ti .clock_getres =3D posix_get_coarse_res, .clock_get =3D posix_get_monotonic_coarse, .clock_set =3D do_posix_clock_nosettime, -@@ -296,6 +299,8 @@ static __init int init_posix_timers(void +@@ -296,6 +299,8 @@ static __init int init_posix_timers(void) .nsleep =3D no_nsleep, }; =20 @@ -70514,7 +72838,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c = linux-2.6.32.49/kernel/posix-ti register_posix_clock(CLOCK_REALTIME, &clock_realtime); register_posix_clock(CLOCK_MONOTONIC, &clock_monotonic); register_posix_clock(CLOCK_MONOTONIC_RAW, &clock_monotonic_raw); -@@ -484,7 +489,7 @@ void register_posix_clock(const clockid_ +@@ -484,7 +489,7 @@ void register_posix_clock(const clockid_t clock_id, = struct k_clock *new_clock) return; } =20 @@ -70523,7 +72847,7 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c = linux-2.6.32.49/kernel/posix-ti } EXPORT_SYMBOL_GPL(register_posix_clock); =20 -@@ -948,6 +953,13 @@ SYSCALL_DEFINE2(clock_settime, const clo +@@ -948,6 +953,13 @@ SYSCALL_DEFINE2(clock_settime, const clockid_t, whi= ch_clock, if (copy_from_user(&new_tp, tp, sizeof (*tp))) return -EFAULT; =20 @@ -70537,9 +72861,10 @@ diff -urNp linux-2.6.32.49/kernel/posix-timers.c= linux-2.6.32.49/kernel/posix-ti return CLOCK_DISPATCH(which_clock, clock_set, (which_clock, &new_tp)); } =20 -diff -urNp linux-2.6.32.49/kernel/power/hibernate.c linux-2.6.32.49/kern= el/power/hibernate.c ---- linux-2.6.32.49/kernel/power/hibernate.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/kernel/power/hibernate.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/kernel/power/hibernate.c b/kernel/power/hibernate.c +index 04a9e90..bc355aa 100644 +--- a/kernel/power/hibernate.c ++++ b/kernel/power/hibernate.c @@ -48,14 +48,14 @@ enum { =20 static int hibernation_mode =3D HIBERNATION_SHUTDOWN; @@ -70557,10 +72882,11 @@ diff -urNp linux-2.6.32.49/kernel/power/hiberna= te.c linux-2.6.32.49/kernel/power { if (ops && !(ops->begin && ops->end && ops->pre_snapshot && ops->prepare && ops->finish && ops->enter && ops->pre_restore -diff -urNp linux-2.6.32.49/kernel/power/poweroff.c linux-2.6.32.49/kerne= l/power/poweroff.c ---- linux-2.6.32.49/kernel/power/poweroff.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/kernel/power/poweroff.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -37,7 +37,7 @@ static struct sysrq_key_op sysrq_powerof +diff --git a/kernel/power/poweroff.c b/kernel/power/poweroff.c +index e8b3370..484c2e4 100644 +--- a/kernel/power/poweroff.c ++++ b/kernel/power/poweroff.c +@@ -37,7 +37,7 @@ static struct sysrq_key_op sysrq_poweroff_op =3D { .enable_mask =3D SYSRQ_ENABLE_BOOT, }; =20 @@ -70569,10 +72895,11 @@ diff -urNp linux-2.6.32.49/kernel/power/powerof= f.c linux-2.6.32.49/kernel/power/ { register_sysrq_key('o', &sysrq_poweroff_op); return 0; -diff -urNp linux-2.6.32.49/kernel/power/process.c linux-2.6.32.49/kernel= /power/process.c ---- linux-2.6.32.49/kernel/power/process.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/kernel/power/process.c 2011-11-15 19:59:43.000000000= -0500 -@@ -37,12 +37,15 @@ static int try_to_freeze_tasks(bool sig_ +diff --git a/kernel/power/process.c b/kernel/power/process.c +index e7cd671..56d5f459 100644 +--- a/kernel/power/process.c ++++ b/kernel/power/process.c +@@ -37,12 +37,15 @@ static int try_to_freeze_tasks(bool sig_only) struct timeval start, end; u64 elapsed_csecs64; unsigned int elapsed_csecs; @@ -70588,7 +72915,7 @@ diff -urNp linux-2.6.32.49/kernel/power/process.c= linux-2.6.32.49/kernel/power/p read_lock(&tasklist_lock); do_each_thread(g, p) { if (frozen(p) || !freezeable(p)) -@@ -57,15 +60,17 @@ static int try_to_freeze_tasks(bool sig_ +@@ -57,15 +60,17 @@ static int try_to_freeze_tasks(bool sig_only) * It is "frozen enough". If the task does wake * up, it will immediately call try_to_freeze. */ @@ -70611,10 +72938,11 @@ diff -urNp linux-2.6.32.49/kernel/power/process= .c linux-2.6.32.49/kernel/power/p =20 do_gettimeofday(&end); elapsed_csecs64 =3D timeval_to_ns(&end) - timeval_to_ns(&start); -diff -urNp linux-2.6.32.49/kernel/power/suspend.c linux-2.6.32.49/kernel= /power/suspend.c ---- linux-2.6.32.49/kernel/power/suspend.c 2011-11-26 19:44:53.000000000= -0500 -+++ linux-2.6.32.49/kernel/power/suspend.c 2011-11-26 19:45:13.000000000= -0500 -@@ -23,13 +23,13 @@ const char *const pm_states[PM_SUSPEND_M +diff --git a/kernel/power/suspend.c b/kernel/power/suspend.c +index 40dd021..fb30ceb 100644 +--- a/kernel/power/suspend.c ++++ b/kernel/power/suspend.c +@@ -23,13 +23,13 @@ const char *const pm_states[PM_SUSPEND_MAX] =3D { [PM_SUSPEND_MEM] =3D "mem", }; =20 @@ -70630,10 +72958,11 @@ diff -urNp linux-2.6.32.49/kernel/power/suspend= .c linux-2.6.32.49/kernel/power/s { mutex_lock(&pm_mutex); suspend_ops =3D ops; -diff -urNp linux-2.6.32.49/kernel/printk.c linux-2.6.32.49/kernel/printk= .c ---- linux-2.6.32.49/kernel/printk.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/printk.c 2011-11-15 19:59:43.000000000 -0500 -@@ -278,6 +278,11 @@ int do_syslog(int type, char __user *buf +diff --git a/kernel/printk.c b/kernel/printk.c +index 4cade47..637e78a 100644 +--- a/kernel/printk.c ++++ b/kernel/printk.c +@@ -278,6 +278,11 @@ int do_syslog(int type, char __user *buf, int len) char c; int error =3D 0; =20 @@ -70645,9 +72974,10 @@ diff -urNp linux-2.6.32.49/kernel/printk.c linux= -2.6.32.49/kernel/printk.c error =3D security_syslog(type); if (error) return error; -diff -urNp linux-2.6.32.49/kernel/profile.c linux-2.6.32.49/kernel/profi= le.c ---- linux-2.6.32.49/kernel/profile.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/profile.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/profile.c b/kernel/profile.c +index dfadc5b..7f59404 100644 +--- a/kernel/profile.c ++++ b/kernel/profile.c @@ -39,7 +39,7 @@ struct profile_hit { /* Oprofile timer tick hook */ static int (*timer_hook)(struct pt_regs *) __read_mostly; @@ -70666,7 +72996,7 @@ diff -urNp linux-2.6.32.49/kernel/profile.c linux= -2.6.32.49/kernel/profile.c hits[i].hits =3D hits[i].pc =3D 0; } } -@@ -346,9 +346,9 @@ void profile_hits(int type, void *__pc,=20 +@@ -346,9 +346,9 @@ void profile_hits(int type, void *__pc, unsigned int= nr_hits) * Add the current hit(s) and flush the write-queue out * to the global buffer: */ @@ -70678,7 +73008,7 @@ diff -urNp linux-2.6.32.49/kernel/profile.c linux= -2.6.32.49/kernel/profile.c hits[i].pc =3D hits[i].hits =3D 0; } out: -@@ -426,7 +426,7 @@ void profile_hits(int type, void *__pc,=20 +@@ -426,7 +426,7 @@ void profile_hits(int type, void *__pc, unsigned int= nr_hits) if (prof_on !=3D type || !prof_buffer) return; pc =3D ((unsigned long)__pc - (unsigned long)_stext) >> prof_shift; @@ -70687,7 +73017,7 @@ diff -urNp linux-2.6.32.49/kernel/profile.c linux= -2.6.32.49/kernel/profile.c } #endif /* !CONFIG_SMP */ EXPORT_SYMBOL_GPL(profile_hits); -@@ -517,7 +517,7 @@ read_profile(struct file *file, char __u +@@ -517,7 +517,7 @@ read_profile(struct file *file, char __user *buf, si= ze_t count, loff_t *ppos) return -EFAULT; buf++; p++; count--; read++; } @@ -70696,7 +73026,7 @@ diff -urNp linux-2.6.32.49/kernel/profile.c linux= -2.6.32.49/kernel/profile.c if (copy_to_user(buf, (void *)pnt, count)) return -EFAULT; read +=3D count; -@@ -548,7 +548,7 @@ static ssize_t write_profile(struct file +@@ -548,7 +548,7 @@ static ssize_t write_profile(struct file *file, cons= t char __user *buf, } #endif profile_discard_flip_buffers(); @@ -70705,10 +73035,11 @@ diff -urNp linux-2.6.32.49/kernel/profile.c lin= ux-2.6.32.49/kernel/profile.c return count; } =20 -diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-2.6.32.49/kernel/ptrace= .c ---- linux-2.6.32.49/kernel/ptrace.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/ptrace.c 2011-11-15 19:59:43.000000000 -0500 -@@ -117,7 +117,8 @@ int ptrace_check_attach(struct task_stru +diff --git a/kernel/ptrace.c b/kernel/ptrace.c +index 05625f6..733bf70 100644 +--- a/kernel/ptrace.c ++++ b/kernel/ptrace.c +@@ -117,7 +117,8 @@ int ptrace_check_attach(struct task_struct *child, i= nt kill) return ret; } =20 @@ -70718,7 +73049,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c { const struct cred *cred =3D current_cred(), *tcred; =20 -@@ -141,7 +142,9 @@ int __ptrace_may_access(struct task_stru +@@ -141,7 +142,9 @@ int __ptrace_may_access(struct task_struct *task, un= signed int mode) cred->gid !=3D tcred->egid || cred->gid !=3D tcred->sgid || cred->gid !=3D tcred->gid) && @@ -70729,7 +73060,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c rcu_read_unlock(); return -EPERM; } -@@ -149,7 +152,9 @@ int __ptrace_may_access(struct task_stru +@@ -149,7 +152,9 @@ int __ptrace_may_access(struct task_struct *task, un= signed int mode) smp_rmb(); if (task->mm) dumpable =3D get_dumpable(task->mm); @@ -70740,7 +73071,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c return -EPERM; =20 return security_ptrace_access_check(task, mode); -@@ -159,7 +164,16 @@ bool ptrace_may_access(struct task_struc +@@ -159,7 +164,16 @@ bool ptrace_may_access(struct task_struct *task, un= signed int mode) { int err; task_lock(task); @@ -70758,7 +73089,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c task_unlock(task); return !err; } -@@ -186,7 +200,7 @@ int ptrace_attach(struct task_struct *ta +@@ -186,7 +200,7 @@ int ptrace_attach(struct task_struct *task) goto out; =20 task_lock(task); @@ -70767,7 +73098,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c task_unlock(task); if (retval) goto unlock_creds; -@@ -199,7 +213,7 @@ int ptrace_attach(struct task_struct *ta +@@ -199,7 +213,7 @@ int ptrace_attach(struct task_struct *task) goto unlock_tasklist; =20 task->ptrace =3D PT_PTRACED; @@ -70776,7 +73107,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c task->ptrace |=3D PT_PTRACE_CAP; =20 __ptrace_link(task, current); -@@ -351,6 +365,8 @@ int ptrace_readdata(struct task_struct * +@@ -351,6 +365,8 @@ int ptrace_readdata(struct task_struct *tsk, unsigne= d long src, char __user *dst { int copied =3D 0; =20 @@ -70785,7 +73116,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c while (len > 0) { char buf[128]; int this_len, retval; -@@ -376,6 +392,8 @@ int ptrace_writedata(struct task_struct=20 +@@ -376,6 +392,8 @@ int ptrace_writedata(struct task_struct *tsk, char _= _user *src, unsigned long ds { int copied =3D 0; =20 @@ -70794,7 +73125,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c while (len > 0) { char buf[128]; int this_len, retval; -@@ -517,6 +535,8 @@ int ptrace_request(struct task_struct *c +@@ -517,6 +535,8 @@ int ptrace_request(struct task_struct *child, long r= equest, int ret =3D -EIO; siginfo_t siginfo; =20 @@ -70803,7 +73134,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c switch (request) { case PTRACE_PEEKTEXT: case PTRACE_PEEKDATA: -@@ -532,18 +552,18 @@ int ptrace_request(struct task_struct *c +@@ -532,18 +552,18 @@ int ptrace_request(struct task_struct *child, long= request, ret =3D ptrace_setoptions(child, data); break; case PTRACE_GETEVENTMSG: @@ -70825,7 +73156,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c sizeof siginfo)) ret =3D -EFAULT; else -@@ -621,14 +641,21 @@ SYSCALL_DEFINE4(ptrace, long, request, l +@@ -621,14 +641,21 @@ SYSCALL_DEFINE4(ptrace, long, request, long, pid, = long, addr, long, data) goto out; } =20 @@ -70848,7 +73179,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c goto out_put_task_struct; } =20 -@@ -653,7 +680,7 @@ int generic_ptrace_peekdata(struct task_ +@@ -653,7 +680,7 @@ int generic_ptrace_peekdata(struct task_struct *tsk,= long addr, long data) copied =3D access_process_vm(tsk, addr, &tmp, sizeof(tmp), 0); if (copied !=3D sizeof(tmp)) return -EIO; @@ -70857,7 +73188,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c } =20 int generic_ptrace_pokedata(struct task_struct *tsk, long addr, long da= ta) -@@ -675,6 +702,8 @@ int compat_ptrace_request(struct task_st +@@ -675,6 +702,8 @@ int compat_ptrace_request(struct task_struct *child,= compat_long_t request, siginfo_t siginfo; int ret; =20 @@ -70866,7 +73197,7 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linux-= 2.6.32.49/kernel/ptrace.c switch (request) { case PTRACE_PEEKTEXT: case PTRACE_PEEKDATA: -@@ -740,14 +769,21 @@ asmlinkage long compat_sys_ptrace(compat +@@ -740,14 +769,21 @@ asmlinkage long compat_sys_ptrace(compat_long_t re= quest, compat_long_t pid, goto out; } =20 @@ -70889,10 +73220,11 @@ diff -urNp linux-2.6.32.49/kernel/ptrace.c linu= x-2.6.32.49/kernel/ptrace.c goto out_put_task_struct; } =20 -diff -urNp linux-2.6.32.49/kernel/rcutorture.c linux-2.6.32.49/kernel/rc= utorture.c ---- linux-2.6.32.49/kernel/rcutorture.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/kernel/rcutorture.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -118,12 +118,12 @@ static DEFINE_PER_CPU(long [RCU_TORTURE_ +diff --git a/kernel/rcutorture.c b/kernel/rcutorture.c +index 697c0a0..2402696 100644 +--- a/kernel/rcutorture.c ++++ b/kernel/rcutorture.c +@@ -118,12 +118,12 @@ static DEFINE_PER_CPU(long [RCU_TORTURE_PIPE_LEN += 1], rcu_torture_count) =3D { 0 }; static DEFINE_PER_CPU(long [RCU_TORTURE_PIPE_LEN + 1], rcu_torture_batc= h) =3D { 0 }; @@ -70943,7 +73275,7 @@ diff -urNp linux-2.6.32.49/kernel/rcutorture.c li= nux-2.6.32.49/kernel/rcutorture if (++rp->rtort_pipe_count >=3D RCU_TORTURE_PIPE_LEN) { rp->rtort_mbtest =3D 0; rcu_torture_free(rp); -@@ -359,7 +359,7 @@ static void rcu_sync_torture_deferred_fr +@@ -359,7 +359,7 @@ static void rcu_sync_torture_deferred_free(struct rc= u_torture *p) i =3D rp->rtort_pipe_count; if (i > RCU_TORTURE_PIPE_LEN) i =3D RCU_TORTURE_PIPE_LEN; @@ -70961,7 +73293,7 @@ diff -urNp linux-2.6.32.49/kernel/rcutorture.c li= nux-2.6.32.49/kernel/rcutorture old_rp->rtort_pipe_count++; cur_ops->deferred_free(old_rp); } -@@ -718,7 +718,7 @@ static void rcu_torture_timer(unsigned l +@@ -718,7 +718,7 @@ static void rcu_torture_timer(unsigned long unused) return; } if (p->rtort_mbtest =3D=3D 0) @@ -71041,10 +73373,11 @@ diff -urNp linux-2.6.32.49/kernel/rcutorture.c = linux-2.6.32.49/kernel/rcutorture for_each_possible_cpu(cpu) { for (i =3D 0; i < RCU_TORTURE_PIPE_LEN + 1; i++) { per_cpu(rcu_torture_count, cpu)[i] =3D 0; -diff -urNp linux-2.6.32.49/kernel/rcutree.c linux-2.6.32.49/kernel/rcutr= ee.c ---- linux-2.6.32.49/kernel/rcutree.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/rcutree.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1303,7 +1303,7 @@ __rcu_process_callbacks(struct rcu_state +diff --git a/kernel/rcutree.c b/kernel/rcutree.c +index 683c4f3..97f54c6 100644 +--- a/kernel/rcutree.c ++++ b/kernel/rcutree.c +@@ -1303,7 +1303,7 @@ __rcu_process_callbacks(struct rcu_state *rsp, str= uct rcu_data *rdp) /* * Do softirq processing for the current CPU. */ @@ -71053,10 +73386,11 @@ diff -urNp linux-2.6.32.49/kernel/rcutree.c lin= ux-2.6.32.49/kernel/rcutree.c { /* * Memory references from any prior RCU read-side critical sections -diff -urNp linux-2.6.32.49/kernel/rcutree_plugin.h linux-2.6.32.49/kerne= l/rcutree_plugin.h ---- linux-2.6.32.49/kernel/rcutree_plugin.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/kernel/rcutree_plugin.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -145,7 +145,7 @@ static void rcu_preempt_note_context_swi +diff --git a/kernel/rcutree_plugin.h b/kernel/rcutree_plugin.h +index c03edf7..ac1b341 100644 +--- a/kernel/rcutree_plugin.h ++++ b/kernel/rcutree_plugin.h +@@ -145,7 +145,7 @@ static void rcu_preempt_note_context_switch(int cpu) */ void __rcu_read_lock(void) { @@ -71074,10 +73408,11 @@ diff -urNp linux-2.6.32.49/kernel/rcutree_plugi= n.h linux-2.6.32.49/kernel/rcutre unlikely(ACCESS_ONCE(t->rcu_read_unlock_special))) rcu_read_unlock_special(t); } -diff -urNp linux-2.6.32.49/kernel/relay.c linux-2.6.32.49/kernel/relay.c ---- linux-2.6.32.49/kernel/relay.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/relay.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1222,7 +1222,7 @@ static int subbuf_splice_actor(struct fi +diff --git a/kernel/relay.c b/kernel/relay.c +index 760c262..a9fd241 100644 +--- a/kernel/relay.c ++++ b/kernel/relay.c +@@ -1222,7 +1222,7 @@ static int subbuf_splice_actor(struct file *in, unsigned int flags, int *nonpad_ret) { @@ -71086,7 +73421,7 @@ diff -urNp linux-2.6.32.49/kernel/relay.c linux-2= .6.32.49/kernel/relay.c struct rchan_buf *rbuf =3D in->private_data; unsigned int subbuf_size =3D rbuf->chan->subbuf_size; uint64_t pos =3D (uint64_t) *ppos; -@@ -1241,6 +1241,9 @@ static int subbuf_splice_actor(struct fi +@@ -1241,6 +1241,9 @@ static int subbuf_splice_actor(struct file *in, .ops =3D &relay_pipe_buf_ops, .spd_release =3D relay_page_release, }; @@ -71096,10 +73431,11 @@ diff -urNp linux-2.6.32.49/kernel/relay.c linux= -2.6.32.49/kernel/relay.c =20 if (rbuf->subbufs_produced =3D=3D rbuf->subbufs_consumed) return 0; -diff -urNp linux-2.6.32.49/kernel/resource.c linux-2.6.32.49/kernel/reso= urce.c ---- linux-2.6.32.49/kernel/resource.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/kernel/resource.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -132,8 +132,18 @@ static const struct file_operations proc +diff --git a/kernel/resource.c b/kernel/resource.c +index fb11a58..4e61ae1 100644 +--- a/kernel/resource.c ++++ b/kernel/resource.c +@@ -132,8 +132,18 @@ static const struct file_operations proc_iomem_oper= ations =3D { =20 static int __init ioresources_init(void) { @@ -71118,21 +73454,10 @@ diff -urNp linux-2.6.32.49/kernel/resource.c li= nux-2.6.32.49/kernel/resource.c return 0; } __initcall(ioresources_init); -diff -urNp linux-2.6.32.49/kernel/rtmutex.c linux-2.6.32.49/kernel/rtmut= ex.c ---- linux-2.6.32.49/kernel/rtmutex.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/rtmutex.c 2011-11-15 19:59:43.000000000 -0500 -@@ -511,7 +511,7 @@ static void wakeup_next_waiter(struct rt - */ - spin_lock_irqsave(&pendowner->pi_lock, flags); -=20 -- WARN_ON(!pendowner->pi_blocked_on); -+ BUG_ON(!pendowner->pi_blocked_on); - WARN_ON(pendowner->pi_blocked_on !=3D waiter); - WARN_ON(pendowner->pi_blocked_on->lock !=3D lock); -=20 -diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.c linux-2.6.32.49/kerne= l/rtmutex-tester.c ---- linux-2.6.32.49/kernel/rtmutex-tester.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/kernel/rtmutex-tester.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/kernel/rtmutex-tester.c b/kernel/rtmutex-tester.c +index a56f629..1fc4989 100644 +--- a/kernel/rtmutex-tester.c ++++ b/kernel/rtmutex-tester.c @@ -21,7 +21,7 @@ #define MAX_RT_TEST_MUTEXES 8 =20 @@ -71142,7 +73467,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute =20 struct test_thread_data { int opcode; -@@ -64,7 +64,7 @@ static int handle_op(struct test_thread_ +@@ -64,7 +64,7 @@ static int handle_op(struct test_thread_data *td, int = lockwakeup) =20 case RTTEST_LOCKCONT: td->mutexes[td->opdata] =3D 1; @@ -71151,7 +73476,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute return 0; =20 case RTTEST_RESET: -@@ -82,7 +82,7 @@ static int handle_op(struct test_thread_ +@@ -82,7 +82,7 @@ static int handle_op(struct test_thread_data *td, int = lockwakeup) return 0; =20 case RTTEST_RESETEVENT: @@ -71160,7 +73485,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute return 0; =20 default: -@@ -99,9 +99,9 @@ static int handle_op(struct test_thread_ +@@ -99,9 +99,9 @@ static int handle_op(struct test_thread_data *td, int = lockwakeup) return ret; =20 td->mutexes[id] =3D 1; @@ -71172,7 +73497,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute td->mutexes[id] =3D 4; return 0; =20 -@@ -112,9 +112,9 @@ static int handle_op(struct test_thread_ +@@ -112,9 +112,9 @@ static int handle_op(struct test_thread_data *td, in= t lockwakeup) return ret; =20 td->mutexes[id] =3D 1; @@ -71184,7 +73509,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute td->mutexes[id] =3D ret ? 0 : 4; return ret ? -EINTR : 0; =20 -@@ -123,9 +123,9 @@ static int handle_op(struct test_thread_ +@@ -123,9 +123,9 @@ static int handle_op(struct test_thread_data *td, in= t lockwakeup) if (id < 0 || id >=3D MAX_RT_TEST_MUTEXES || td->mutexes[id] !=3D 4) return ret; =20 @@ -71196,7 +73521,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute td->mutexes[id] =3D 0; return 0; =20 -@@ -187,7 +187,7 @@ void schedule_rt_mutex_test(struct rt_mu +@@ -187,7 +187,7 @@ void schedule_rt_mutex_test(struct rt_mutex *mutex) break; =20 td->mutexes[dat] =3D 2; @@ -71205,7 +73530,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute break; =20 case RTTEST_LOCKBKL: -@@ -208,7 +208,7 @@ void schedule_rt_mutex_test(struct rt_mu +@@ -208,7 +208,7 @@ void schedule_rt_mutex_test(struct rt_mutex *mutex) return; =20 td->mutexes[dat] =3D 3; @@ -71214,7 +73539,7 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-tester.= c linux-2.6.32.49/kernel/rtmute break; =20 case RTTEST_LOCKNOWAIT: -@@ -220,7 +220,7 @@ void schedule_rt_mutex_test(struct rt_mu +@@ -220,7 +220,7 @@ void schedule_rt_mutex_test(struct rt_mutex *mutex) return; =20 td->mutexes[dat] =3D 1; @@ -71223,10 +73548,24 @@ diff -urNp linux-2.6.32.49/kernel/rtmutex-teste= r.c linux-2.6.32.49/kernel/rtmute return; =20 case RTTEST_LOCKBKL: -diff -urNp linux-2.6.32.49/kernel/sched.c linux-2.6.32.49/kernel/sched.c ---- linux-2.6.32.49/kernel/sched.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/sched.c 2011-11-15 19:59:43.000000000 -0500 -@@ -2764,9 +2764,10 @@ void wake_up_new_task(struct task_struct +diff --git a/kernel/rtmutex.c b/kernel/rtmutex.c +index 29bd4ba..8c5de90 100644 +--- a/kernel/rtmutex.c ++++ b/kernel/rtmutex.c +@@ -511,7 +511,7 @@ static void wakeup_next_waiter(struct rt_mutex *lock= ) + */ + spin_lock_irqsave(&pendowner->pi_lock, flags); +=20 +- WARN_ON(!pendowner->pi_blocked_on); ++ BUG_ON(!pendowner->pi_blocked_on); + WARN_ON(pendowner->pi_blocked_on !=3D waiter); + WARN_ON(pendowner->pi_blocked_on->lock !=3D lock); +=20 +diff --git a/kernel/sched.c b/kernel/sched.c +index 0591df8..6e343c3 100644 +--- a/kernel/sched.c ++++ b/kernel/sched.c +@@ -2764,9 +2764,10 @@ void wake_up_new_task(struct task_struct *p, unsi= gned long clone_flags) { unsigned long flags; struct rq *rq; @@ -71265,7 +73604,7 @@ diff -urNp linux-2.6.32.49/kernel/sched.c linux-2= .6.32.49/kernel/sched.c { unsigned int cpu; struct rq *rq; -@@ -5784,10 +5787,10 @@ int mutex_spin_on_owner(struct mutex *lo +@@ -5784,10 +5787,10 @@ int mutex_spin_on_owner(struct mutex *lock, stru= ct thread_info *owner) * DEBUG_PAGEALLOC could have unmapped it if * the mutex owner just released it and exited. */ @@ -71278,7 +73617,7 @@ diff -urNp linux-2.6.32.49/kernel/sched.c linux-2= .6.32.49/kernel/sched.c #endif =20 /* -@@ -5816,7 +5819,7 @@ int mutex_spin_on_owner(struct mutex *lo +@@ -5816,7 +5819,7 @@ int mutex_spin_on_owner(struct mutex *lock, struct= thread_info *owner) /* * Is that owner really running on that cpu? */ @@ -71287,7 +73626,7 @@ diff -urNp linux-2.6.32.49/kernel/sched.c linux-2= .6.32.49/kernel/sched.c return 0; =20 cpu_relax(); -@@ -6359,6 +6362,8 @@ int can_nice(const struct task_struct *p +@@ -6359,6 +6362,8 @@ int can_nice(const struct task_struct *p, const in= t nice) /* convert nice value [19,-20] to rlimit style value [1,40] */ int nice_rlim =3D 20 - nice; =20 @@ -71306,7 +73645,7 @@ diff -urNp linux-2.6.32.49/kernel/sched.c linux-2= .6.32.49/kernel/sched.c return -EPERM; =20 retval =3D security_task_setnice(current, nice); -@@ -8774,7 +8780,7 @@ static void init_sched_groups_power(int=20 +@@ -8774,7 +8780,7 @@ static void init_sched_groups_power(int cpu, struc= t sched_domain *sd) long power; int weight; =20 @@ -71315,9 +73654,10 @@ diff -urNp linux-2.6.32.49/kernel/sched.c linux-= 2.6.32.49/kernel/sched.c =20 if (cpu !=3D group_first_cpu(sd->groups)) return; -diff -urNp linux-2.6.32.49/kernel/signal.c linux-2.6.32.49/kernel/signal= .c ---- linux-2.6.32.49/kernel/signal.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/signal.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/signal.c b/kernel/signal.c +index 2494827..cda80a0 100644 +--- a/kernel/signal.c ++++ b/kernel/signal.c @@ -41,12 +41,12 @@ =20 static struct kmem_cache *sigqueue_cachep; @@ -71333,7 +73673,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c { /* Is it explicitly or implicitly ignored? */ return handler =3D=3D SIG_IGN || -@@ -56,7 +56,7 @@ static int sig_handler_ignored(void __us +@@ -56,7 +56,7 @@ static int sig_handler_ignored(void __user *handler, i= nt sig) static int sig_task_ignored(struct task_struct *t, int sig, int from_ancestor_ns) { @@ -71342,7 +73682,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c =20 handler =3D sig_handler(t, sig); =20 -@@ -207,6 +207,9 @@ static struct sigqueue *__sigqueue_alloc +@@ -207,6 +207,9 @@ static struct sigqueue *__sigqueue_alloc(struct task= _struct *t, gfp_t flags, */ user =3D get_uid(__task_cred(t)->user); atomic_inc(&user->sigpending); @@ -71352,7 +73692,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c if (override_rlimit || atomic_read(&user->sigpending) <=3D t->signal->rlim[RLIMIT_SIGPENDING].rlim_cur) -@@ -327,7 +330,7 @@ flush_signal_handlers(struct task_struct +@@ -327,7 +330,7 @@ flush_signal_handlers(struct task_struct *t, int for= ce_default) =20 int unhandled_signal(struct task_struct *tsk, int sig) { @@ -71361,7 +73701,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c if (is_global_init(tsk)) return 1; if (handler !=3D SIG_IGN && handler !=3D SIG_DFL) -@@ -627,6 +630,13 @@ static int check_kill_permission(int sig +@@ -627,6 +630,13 @@ static int check_kill_permission(int sig, struct si= ginfo *info, } } =20 @@ -71375,7 +73715,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c return security_task_kill(t, info, sig, 0); } =20 -@@ -968,7 +978,7 @@ __group_send_sig_info(int sig, struct si +@@ -968,7 +978,7 @@ __group_send_sig_info(int sig, struct siginfo *info,= struct task_struct *p) return send_signal(sig, info, p, 1); } =20 @@ -71384,7 +73724,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c specific_send_sig_info(int sig, struct siginfo *info, struct task_struc= t *t) { return send_signal(sig, info, t, 0); -@@ -1005,6 +1015,7 @@ force_sig_info(int sig, struct siginfo * +@@ -1005,6 +1015,7 @@ force_sig_info(int sig, struct siginfo *info, stru= ct task_struct *t) unsigned long int flags; int ret, blocked, ignored; struct k_sigaction *action; @@ -71392,7 +73732,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c =20 spin_lock_irqsave(&t->sighand->siglock, flags); action =3D &t->sighand->action[sig-1]; -@@ -1019,9 +1030,18 @@ force_sig_info(int sig, struct siginfo * +@@ -1019,9 +1030,18 @@ force_sig_info(int sig, struct siginfo *info, str= uct task_struct *t) } if (action->sa.sa_handler =3D=3D SIG_DFL) t->signal->flags &=3D ~SIGNAL_UNKILLABLE; @@ -71411,7 +73751,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c return ret; } =20 -@@ -1081,8 +1101,11 @@ int group_send_sig_info(int sig, struct=20 +@@ -1081,8 +1101,11 @@ int group_send_sig_info(int sig, struct siginfo *= info, struct task_struct *p) { int ret =3D check_kill_permission(sig, info, p); =20 @@ -71433,7 +73773,7 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linux-= 2.6.32.49/kernel/signal.c BUG_ON((exit_code & (0x7f | ~0xffff)) !=3D SIGTRAP); =20 memset(&info, 0, sizeof info); -@@ -2275,7 +2300,15 @@ do_send_specific(pid_t tgid, pid_t pid,=20 +@@ -2275,7 +2300,15 @@ do_send_specific(pid_t tgid, pid_t pid, int sig, = struct siginfo *info) int error =3D -ESRCH; =20 rcu_read_lock(); @@ -71450,10 +73790,11 @@ diff -urNp linux-2.6.32.49/kernel/signal.c linu= x-2.6.32.49/kernel/signal.c if (p && (tgid <=3D 0 || task_tgid_vnr(p) =3D=3D tgid)) { error =3D check_kill_permission(sig, info, p); /* -diff -urNp linux-2.6.32.49/kernel/smp.c linux-2.6.32.49/kernel/smp.c ---- linux-2.6.32.49/kernel/smp.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/smp.c 2011-11-15 19:59:43.000000000 -0500 -@@ -522,22 +522,22 @@ int smp_call_function(void (*func)(void=20 +diff --git a/kernel/smp.c b/kernel/smp.c +index aa9cff3..631a0de 100644 +--- a/kernel/smp.c ++++ b/kernel/smp.c +@@ -522,22 +522,22 @@ int smp_call_function(void (*func)(void *), void *= info, int wait) } EXPORT_SYMBOL(smp_call_function); =20 @@ -71480,10 +73821,11 @@ diff -urNp linux-2.6.32.49/kernel/smp.c linux-2= .6.32.49/kernel/smp.c { spin_unlock_irq(&call_function.lock); } -diff -urNp linux-2.6.32.49/kernel/softirq.c linux-2.6.32.49/kernel/softi= rq.c ---- linux-2.6.32.49/kernel/softirq.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/softirq.c 2011-11-15 19:59:43.000000000 -0500 -@@ -56,7 +56,7 @@ static struct softirq_action softirq_vec +diff --git a/kernel/softirq.c b/kernel/softirq.c +index 04a0252..580c512 100644 +--- a/kernel/softirq.c ++++ b/kernel/softirq.c +@@ -56,7 +56,7 @@ static struct softirq_action softirq_vec[NR_SOFTIRQS] = __cacheline_aligned_in_smp =20 static DEFINE_PER_CPU(struct task_struct *, ksoftirqd); =20 @@ -71524,7 +73866,7 @@ diff -urNp linux-2.6.32.49/kernel/softirq.c linux= -2.6.32.49/kernel/softirq.c } =20 /* -@@ -419,7 +421,7 @@ void __tasklet_hi_schedule_first(struct=20 +@@ -419,7 +421,7 @@ void __tasklet_hi_schedule_first(struct tasklet_stru= ct *t) =20 EXPORT_SYMBOL(__tasklet_hi_schedule_first); =20 @@ -71533,7 +73875,7 @@ diff -urNp linux-2.6.32.49/kernel/softirq.c linux= -2.6.32.49/kernel/softirq.c { struct tasklet_struct *list; =20 -@@ -454,7 +456,7 @@ static void tasklet_action(struct softir +@@ -454,7 +456,7 @@ static void tasklet_action(struct softirq_action *a) } } =20 @@ -71542,10 +73884,11 @@ diff -urNp linux-2.6.32.49/kernel/softirq.c lin= ux-2.6.32.49/kernel/softirq.c { struct tasklet_struct *list; =20 -diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6.32.49/kernel/sys.c ---- linux-2.6.32.49/kernel/sys.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/sys.c 2011-11-15 19:59:43.000000000 -0500 -@@ -133,6 +133,12 @@ static int set_one_prio(struct task_stru +diff --git a/kernel/sys.c b/kernel/sys.c +index e9512b1..3c265de 100644 +--- a/kernel/sys.c ++++ b/kernel/sys.c +@@ -133,6 +133,12 @@ static int set_one_prio(struct task_struct *p, int = niceval, int error) error =3D -EACCES; goto out; } @@ -71558,7 +73901,7 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6= .32.49/kernel/sys.c no_nice =3D security_task_setnice(p, niceval); if (no_nice) { error =3D no_nice; -@@ -190,10 +196,10 @@ SYSCALL_DEFINE3(setpriority, int, which, +@@ -190,10 +196,10 @@ SYSCALL_DEFINE3(setpriority, int, which, int, who,= int, niceval) !(user =3D find_user(who))) goto out_unlock; /* No processes for this user */ =20 @@ -71571,7 +73914,7 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6= .32.49/kernel/sys.c if (who !=3D cred->uid) free_uid(user); /* For find_user() */ break; -@@ -253,13 +259,13 @@ SYSCALL_DEFINE2(getpriority, int, which, +@@ -253,13 +259,13 @@ SYSCALL_DEFINE2(getpriority, int, which, int, who) !(user =3D find_user(who))) goto out_unlock; /* No processes for this user */ =20 @@ -71587,7 +73930,7 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6= .32.49/kernel/sys.c if (who !=3D cred->uid) free_uid(user); /* for find_user() */ break; -@@ -509,6 +515,9 @@ SYSCALL_DEFINE2(setregid, gid_t, rgid, g +@@ -509,6 +515,9 @@ SYSCALL_DEFINE2(setregid, gid_t, rgid, gid_t, egid) goto error; } =20 @@ -71632,7 +73975,7 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6= .32.49/kernel/sys.c =20 free_uid(new->user); new->user =3D new_user; -@@ -627,6 +647,9 @@ SYSCALL_DEFINE2(setreuid, uid_t, ruid, u +@@ -627,6 +647,9 @@ SYSCALL_DEFINE2(setreuid, uid_t, ruid, uid_t, euid) goto error; } =20 @@ -71655,7 +73998,7 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6= .32.49/kernel/sys.c if (capable(CAP_SETUID)) { new->suid =3D new->uid =3D uid; if (uid !=3D old->uid) { -@@ -732,6 +761,9 @@ SYSCALL_DEFINE3(setresuid, uid_t, ruid,=20 +@@ -732,6 +761,9 @@ SYSCALL_DEFINE3(setresuid, uid_t, ruid, uid_t, euid,= uid_t, suid) goto error; } =20 @@ -71665,7 +74008,7 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6= .32.49/kernel/sys.c if (ruid !=3D (uid_t) -1) { new->uid =3D ruid; if (ruid !=3D old->uid) { -@@ -800,6 +832,9 @@ SYSCALL_DEFINE3(setresgid, gid_t, rgid,=20 +@@ -800,6 +832,9 @@ SYSCALL_DEFINE3(setresgid, gid_t, rgid, gid_t, egid,= gid_t, sgid) goto error; } =20 @@ -71695,7 +74038,7 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.6= .32.49/kernel/sys.c if (gid !=3D old_fsgid) { new->fsgid =3D gid; goto change_okay; -@@ -1454,7 +1495,7 @@ SYSCALL_DEFINE5(prctl, int, option, unsi +@@ -1454,7 +1495,7 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long,= arg2, unsigned long, arg3, error =3D get_dumpable(me->mm); break; case PR_SET_DUMPABLE: @@ -71704,9 +74047,10 @@ diff -urNp linux-2.6.32.49/kernel/sys.c linux-2.= 6.32.49/kernel/sys.c error =3D -EINVAL; break; } -diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-2.6.32.49/kernel/sysctl= .c ---- linux-2.6.32.49/kernel/sysctl.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/sysctl.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/sysctl.c b/kernel/sysctl.c +index b8bd058..ab6a76be 100644 +--- a/kernel/sysctl.c ++++ b/kernel/sysctl.c @@ -63,6 +63,13 @@ static int deprecated_sysctl_warning(struct __sysctl_args *args); =20 @@ -71721,7 +74065,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c =20 /* External variables not in a header file. */ extern int C_A_D; -@@ -168,6 +175,7 @@ static int proc_do_cad_pid(struct ctl_ta +@@ -168,6 +175,7 @@ static int proc_do_cad_pid(struct ctl_table *table, = int write, static int proc_taint(struct ctl_table *table, int write, void __user *buffer, size_t *lenp, loff_t *ppos); #endif @@ -71751,7 +74095,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c extern int prove_locking; extern int lock_stat; =20 -@@ -251,6 +274,24 @@ static int max_wakeup_granularity_ns =3D N +@@ -251,6 +274,24 @@ static int max_wakeup_granularity_ns =3D NSEC_PER_S= EC; /* 1 second */ #endif =20 static struct ctl_table kern_table[] =3D { @@ -71801,7 +74145,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c #else { .ctl_name =3D CTL_UNNUMBERED, -@@ -1803,6 +1851,8 @@ static int do_sysctl_strategy(struct ctl +@@ -1803,6 +1851,8 @@ static int do_sysctl_strategy(struct ctl_table_roo= t *root, return 0; } =20 @@ -71819,7 +74163,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c return -EPERM; name++; nlen--; -@@ -1906,6 +1956,33 @@ int sysctl_perm(struct ctl_table_root *r +@@ -1906,6 +1956,33 @@ int sysctl_perm(struct ctl_table_root *root, stru= ct ctl_table *table, int op) int error; int mode; =20 @@ -71853,7 +74197,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c error =3D security_sysctl(table, op & (MAY_READ | MAY_WRITE | MAY_EXEC= )); if (error) return error; -@@ -2335,6 +2412,16 @@ int proc_dostring(struct ctl_table *tabl +@@ -2335,6 +2412,16 @@ int proc_dostring(struct ctl_table *table, int wr= ite, buffer, lenp, ppos); } =20 @@ -71870,7 +74214,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c =20 static int do_proc_dointvec_conv(int *negp, unsigned long *lvalp, int *valp, -@@ -2609,7 +2696,7 @@ static int __do_proc_doulongvec_minmax(v +@@ -2609,7 +2696,7 @@ static int __do_proc_doulongvec_minmax(void *data,= struct ctl_table *table, int vleft =3D table->maxlen / sizeof(unsigned long); left =3D *lenp; =09 @@ -71879,7 +74223,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c if (write) { while (left) { char c; -@@ -2910,6 +2997,12 @@ int proc_dostring(struct ctl_table *tabl +@@ -2910,6 +2997,12 @@ int proc_dostring(struct ctl_table *table, int wr= ite, return -ENOSYS; } =20 @@ -71892,7 +74236,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c int proc_dointvec(struct ctl_table *table, int write, void __user *buffer, size_t *lenp, loff_t *ppos) { -@@ -3038,6 +3131,16 @@ int sysctl_string(struct ctl_table *tabl +@@ -3038,6 +3131,16 @@ int sysctl_string(struct ctl_table *table, return 1; } =20 @@ -71909,7 +74253,7 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linux-= 2.6.32.49/kernel/sysctl.c /* * This function makes sure that all of the integers in the vector * are between the minimum and maximum values given in the arrays -@@ -3182,6 +3285,13 @@ int sysctl_string(struct ctl_table *tabl +@@ -3182,6 +3285,13 @@ int sysctl_string(struct ctl_table *table, return -ENOSYS; } =20 @@ -71938,10 +74282,11 @@ diff -urNp linux-2.6.32.49/kernel/sysctl.c linu= x-2.6.32.49/kernel/sysctl.c +EXPORT_SYMBOL(sysctl_string_modpriv); EXPORT_SYMBOL(sysctl_data); EXPORT_SYMBOL(unregister_sysctl_table); -diff -urNp linux-2.6.32.49/kernel/sysctl_check.c linux-2.6.32.49/kernel/= sysctl_check.c ---- linux-2.6.32.49/kernel/sysctl_check.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/kernel/sysctl_check.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1489,10 +1489,12 @@ int sysctl_check_table(struct nsproxy *n +diff --git a/kernel/sysctl_check.c b/kernel/sysctl_check.c +index 469193c..ea3ecb2 100644 +--- a/kernel/sysctl_check.c ++++ b/kernel/sysctl_check.c +@@ -1489,10 +1489,12 @@ int sysctl_check_table(struct nsproxy *namespace= s, struct ctl_table *table) } else { if ((table->strategy =3D=3D sysctl_data) || (table->strategy =3D=3D sysctl_string) || @@ -71954,9 +74299,10 @@ diff -urNp linux-2.6.32.49/kernel/sysctl_check.c= linux-2.6.32.49/kernel/sysctl_c (table->proc_handler =3D=3D proc_dointvec) || (table->proc_handler =3D=3D proc_dointvec_minmax) || (table->proc_handler =3D=3D proc_dointvec_jiffies) || -diff -urNp linux-2.6.32.49/kernel/taskstats.c linux-2.6.32.49/kernel/tas= kstats.c ---- linux-2.6.32.49/kernel/taskstats.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/kernel/taskstats.c 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/kernel/taskstats.c b/kernel/taskstats.c +index b080920..d344f89 100644 +--- a/kernel/taskstats.c ++++ b/kernel/taskstats.c @@ -26,9 +26,12 @@ #include #include @@ -71970,7 +74316,7 @@ diff -urNp linux-2.6.32.49/kernel/taskstats.c lin= ux-2.6.32.49/kernel/taskstats.c /* * Maximum length of a cpumask that can be specified in * the TASKSTATS_CMD_ATTR_REGISTER/DEREGISTER_CPUMASK attribute -@@ -442,6 +445,9 @@ static int taskstats_user_cmd(struct sk_ +@@ -442,6 +445,9 @@ static int taskstats_user_cmd(struct sk_buff *skb, s= truct genl_info *info) size_t size; cpumask_var_t mask; =20 @@ -71980,10 +74326,45 @@ diff -urNp linux-2.6.32.49/kernel/taskstats.c l= inux-2.6.32.49/kernel/taskstats.c if (!alloc_cpumask_var(&mask, GFP_KERNEL)) return -ENOMEM; =20 -diff -urNp linux-2.6.32.49/kernel/time/tick-broadcast.c linux-2.6.32.49/= kernel/time/tick-broadcast.c ---- linux-2.6.32.49/kernel/time/tick-broadcast.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/kernel/time/tick-broadcast.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -116,7 +116,7 @@ int tick_device_uses_broadcast(struct cl +diff --git a/kernel/time.c b/kernel/time.c +index 33df60e..ca768bd 100644 +--- a/kernel/time.c ++++ b/kernel/time.c +@@ -165,6 +165,11 @@ int do_sys_settimeofday(struct timespec *tv, struct= timezone *tz) + return error; +=20 + if (tz) { ++ /* we log in do_settimeofday called below, so don't log twice ++ */ ++ if (!tv) ++ gr_log_timechange(); ++ + /* SMP safe, global irq locking makes it work. */ + sys_tz =3D *tz; + update_vsyscall_tz(); +@@ -240,7 +245,7 @@ EXPORT_SYMBOL(current_fs_time); + * Avoid unnecessary multiplications/divisions in the + * two most common HZ cases: + */ +-unsigned int inline jiffies_to_msecs(const unsigned long j) ++inline unsigned int jiffies_to_msecs(const unsigned long j) + { + #if HZ <=3D MSEC_PER_SEC && !(MSEC_PER_SEC % HZ) + return (MSEC_PER_SEC / HZ) * j; +@@ -256,7 +261,7 @@ unsigned int inline jiffies_to_msecs(const unsigned = long j) + } + EXPORT_SYMBOL(jiffies_to_msecs); +=20 +-unsigned int inline jiffies_to_usecs(const unsigned long j) ++inline unsigned int jiffies_to_usecs(const unsigned long j) + { + #if HZ <=3D USEC_PER_SEC && !(USEC_PER_SEC % HZ) + return (USEC_PER_SEC / HZ) * j; +diff --git a/kernel/time/tick-broadcast.c b/kernel/time/tick-broadcast.c +index 8917fd3..5f0ead6 100644 +--- a/kernel/time/tick-broadcast.c ++++ b/kernel/time/tick-broadcast.c +@@ -116,7 +116,7 @@ int tick_device_uses_broadcast(struct clock_event_de= vice *dev, int cpu) * then clear the broadcast bit. */ if (!(dev->features & CLOCK_EVT_FEAT_C3STOP)) { @@ -71992,9 +74373,10 @@ diff -urNp linux-2.6.32.49/kernel/time/tick-broa= dcast.c linux-2.6.32.49/kernel/t =20 cpumask_clear_cpu(cpu, tick_get_broadcast_mask()); tick_broadcast_clear_oneshot(cpu); -diff -urNp linux-2.6.32.49/kernel/time/timekeeping.c linux-2.6.32.49/ker= nel/time/timekeeping.c ---- linux-2.6.32.49/kernel/time/timekeeping.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/kernel/time/timekeeping.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c +index 1d1206a..08a7c2f 100644 +--- a/kernel/time/timekeeping.c ++++ b/kernel/time/timekeeping.c @@ -14,6 +14,7 @@ #include #include @@ -72021,10 +74403,11 @@ diff -urNp linux-2.6.32.49/kernel/time/timekeep= ing.c linux-2.6.32.49/kernel/time write_seqlock_irqsave(&xtime_lock, flags); =20 timekeeping_forward_now(); -diff -urNp linux-2.6.32.49/kernel/time/timer_list.c linux-2.6.32.49/kern= el/time/timer_list.c ---- linux-2.6.32.49/kernel/time/timer_list.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/kernel/time/timer_list.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -38,12 +38,16 @@ DECLARE_PER_CPU(struct hrtimer_cpu_base, +diff --git a/kernel/time/timer_list.c b/kernel/time/timer_list.c +index 54c0dda..e9095d9 100644 +--- a/kernel/time/timer_list.c ++++ b/kernel/time/timer_list.c +@@ -38,12 +38,16 @@ DECLARE_PER_CPU(struct hrtimer_cpu_base, hrtimer_bas= es); =20 static void print_name_offset(struct seq_file *m, void *sym) { @@ -72053,7 +74436,7 @@ diff -urNp linux-2.6.32.49/kernel/time/timer_list= .c linux-2.6.32.49/kernel/time/ SEQ_printf(m, " .index: %d\n", base->index); SEQ_printf(m, " .resolution: %Lu nsecs\n", -@@ -289,7 +297,11 @@ static int __init init_timer_list_procfs +@@ -289,7 +297,11 @@ static int __init init_timer_list_procfs(void) { struct proc_dir_entry *pe; =20 @@ -72065,9 +74448,10 @@ diff -urNp linux-2.6.32.49/kernel/time/timer_lis= t.c linux-2.6.32.49/kernel/time/ if (!pe) return -ENOMEM; return 0; -diff -urNp linux-2.6.32.49/kernel/time/timer_stats.c linux-2.6.32.49/ker= nel/time/timer_stats.c ---- linux-2.6.32.49/kernel/time/timer_stats.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/kernel/time/timer_stats.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/kernel/time/timer_stats.c b/kernel/time/timer_stats.c +index ee5681f..634089b 100644 +--- a/kernel/time/timer_stats.c ++++ b/kernel/time/timer_stats.c @@ -116,7 +116,7 @@ static ktime_t time_start, time_stop; static unsigned long nr_entries; static struct entry entries[MAX_ENTRIES]; @@ -72086,7 +74470,7 @@ diff -urNp linux-2.6.32.49/kernel/time/timer_stat= s.c linux-2.6.32.49/kernel/time } =20 static struct entry *alloc_entry(void) -@@ -261,7 +261,7 @@ void timer_stats_update_stats(void *time +@@ -261,7 +261,7 @@ void timer_stats_update_stats(void *timer, pid_t pid= , void *startf, if (likely(entry)) entry->count++; else @@ -72095,7 +74479,7 @@ diff -urNp linux-2.6.32.49/kernel/time/timer_stat= s.c linux-2.6.32.49/kernel/time =20 out_unlock: spin_unlock_irqrestore(lock, flags); -@@ -269,12 +269,16 @@ void timer_stats_update_stats(void *time +@@ -269,12 +269,16 @@ void timer_stats_update_stats(void *timer, pid_t p= id, void *startf, =20 static void print_name_offset(struct seq_file *m, unsigned long addr) { @@ -72112,7 +74496,7 @@ diff -urNp linux-2.6.32.49/kernel/time/timer_stat= s.c linux-2.6.32.49/kernel/time } =20 static int tstats_show(struct seq_file *m, void *v) -@@ -300,9 +304,9 @@ static int tstats_show(struct seq_file * +@@ -300,9 +304,9 @@ static int tstats_show(struct seq_file *m, void *v) =20 seq_puts(m, "Timer Stats Version: v0.2\n"); seq_printf(m, "Sample period: %ld.%03ld s\n", period.tv_sec, ms); @@ -72124,7 +74508,7 @@ diff -urNp linux-2.6.32.49/kernel/time/timer_stat= s.c linux-2.6.32.49/kernel/time =20 for (i =3D 0; i < nr_entries; i++) { entry =3D entries + i; -@@ -415,7 +419,11 @@ static int __init init_tstats_procfs(voi +@@ -415,7 +419,11 @@ static int __init init_tstats_procfs(void) { struct proc_dir_entry *pe; =20 @@ -72136,42 +74520,10 @@ diff -urNp linux-2.6.32.49/kernel/time/timer_st= ats.c linux-2.6.32.49/kernel/time if (!pe) return -ENOMEM; return 0; -diff -urNp linux-2.6.32.49/kernel/time.c linux-2.6.32.49/kernel/time.c ---- linux-2.6.32.49/kernel/time.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/time.c 2011-11-15 19:59:43.000000000 -0500 -@@ -165,6 +165,11 @@ int do_sys_settimeofday(struct timespec=20 - return error; -=20 - if (tz) { -+ /* we log in do_settimeofday called below, so don't log twice -+ */ -+ if (!tv) -+ gr_log_timechange(); -+ - /* SMP safe, global irq locking makes it work. */ - sys_tz =3D *tz; - update_vsyscall_tz(); -@@ -240,7 +245,7 @@ EXPORT_SYMBOL(current_fs_time); - * Avoid unnecessary multiplications/divisions in the - * two most common HZ cases: - */ --unsigned int inline jiffies_to_msecs(const unsigned long j) -+inline unsigned int jiffies_to_msecs(const unsigned long j) - { - #if HZ <=3D MSEC_PER_SEC && !(MSEC_PER_SEC % HZ) - return (MSEC_PER_SEC / HZ) * j; -@@ -256,7 +261,7 @@ unsigned int inline jiffies_to_msecs(con - } - EXPORT_SYMBOL(jiffies_to_msecs); -=20 --unsigned int inline jiffies_to_usecs(const unsigned long j) -+inline unsigned int jiffies_to_usecs(const unsigned long j) - { - #if HZ <=3D USEC_PER_SEC && !(USEC_PER_SEC % HZ) - return (USEC_PER_SEC / HZ) * j; -diff -urNp linux-2.6.32.49/kernel/timer.c linux-2.6.32.49/kernel/timer.c ---- linux-2.6.32.49/kernel/timer.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/timer.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/kernel/timer.c b/kernel/timer.c +index cb3c1f1..8bf5526 100644 +--- a/kernel/timer.c ++++ b/kernel/timer.c @@ -1213,7 +1213,7 @@ void update_process_times(int user_tick) /* * This function runs timers and the timer-tq in bottom half context. @@ -72181,10 +74533,11 @@ diff -urNp linux-2.6.32.49/kernel/timer.c linux= -2.6.32.49/kernel/timer.c { struct tvec_base *base =3D __get_cpu_var(tvec_bases); =20 -diff -urNp linux-2.6.32.49/kernel/trace/blktrace.c linux-2.6.32.49/kerne= l/trace/blktrace.c ---- linux-2.6.32.49/kernel/trace/blktrace.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/kernel/trace/blktrace.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -313,7 +313,7 @@ static ssize_t blk_dropped_read(struct f +diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c +index d9d6206..f19467e 100644 +--- a/kernel/trace/blktrace.c ++++ b/kernel/trace/blktrace.c +@@ -313,7 +313,7 @@ static ssize_t blk_dropped_read(struct file *filp, c= har __user *buffer, struct blk_trace *bt =3D filp->private_data; char buf[16]; =20 @@ -72193,7 +74546,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/blktrace.= c linux-2.6.32.49/kernel/trace/ =20 return simple_read_from_buffer(buffer, count, ppos, buf, strlen(buf)); } -@@ -376,7 +376,7 @@ static int blk_subbuf_start_callback(str +@@ -376,7 +376,7 @@ static int blk_subbuf_start_callback(struct rchan_bu= f *buf, void *subbuf, return 1; =20 bt =3D buf->chan->private_data; @@ -72202,7 +74555,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/blktrace.= c linux-2.6.32.49/kernel/trace/ return 0; } =20 -@@ -477,7 +477,7 @@ int do_blk_trace_setup(struct request_qu +@@ -477,7 +477,7 @@ int do_blk_trace_setup(struct request_queue *q, char= *name, dev_t dev, =20 bt->dir =3D dir; bt->dev =3D dev; @@ -72211,10 +74564,11 @@ diff -urNp linux-2.6.32.49/kernel/trace/blktrac= e.c linux-2.6.32.49/kernel/trace/ =20 ret =3D -EIO; bt->dropped_file =3D debugfs_create_file("dropped", 0444, dir, bt, -diff -urNp linux-2.6.32.49/kernel/trace/ftrace.c linux-2.6.32.49/kernel/= trace/ftrace.c ---- linux-2.6.32.49/kernel/trace/ftrace.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/kernel/trace/ftrace.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -1100,13 +1100,18 @@ ftrace_code_disable(struct module *mod,=20 +diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c +index 4872937..c794d40 100644 +--- a/kernel/trace/ftrace.c ++++ b/kernel/trace/ftrace.c +@@ -1100,13 +1100,18 @@ ftrace_code_disable(struct module *mod, struct d= yn_ftrace *rec) =20 ip =3D rec->ip; =20 @@ -72235,10 +74589,11 @@ diff -urNp linux-2.6.32.49/kernel/trace/ftrace.= c linux-2.6.32.49/kernel/trace/ft } =20 /* -diff -urNp linux-2.6.32.49/kernel/trace/ring_buffer.c linux-2.6.32.49/ke= rnel/trace/ring_buffer.c ---- linux-2.6.32.49/kernel/trace/ring_buffer.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/kernel/trace/ring_buffer.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -606,7 +606,7 @@ static struct list_head *rb_list_head(st +diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c +index e749a05..19c6e94 100644 +--- a/kernel/trace/ring_buffer.c ++++ b/kernel/trace/ring_buffer.c +@@ -606,7 +606,7 @@ static struct list_head *rb_list_head(struct list_he= ad *list) * the reader page). But if the next page is a header page, * its flags will be non zero. */ @@ -72247,10 +74602,11 @@ diff -urNp linux-2.6.32.49/kernel/trace/ring_bu= ffer.c linux-2.6.32.49/kernel/tra rb_is_head_page(struct ring_buffer_per_cpu *cpu_buffer, struct buffer_page *page, struct list_head *list) { -diff -urNp linux-2.6.32.49/kernel/trace/trace.c linux-2.6.32.49/kernel/t= race/trace.c ---- linux-2.6.32.49/kernel/trace/trace.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/kernel/trace/trace.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -3193,6 +3193,8 @@ static ssize_t tracing_splice_read_pipe( +diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c +index a2a2d1f..7f32b09 100644 +--- a/kernel/trace/trace.c ++++ b/kernel/trace/trace.c +@@ -3193,6 +3193,8 @@ static ssize_t tracing_splice_read_pipe(struct fil= e *filp, size_t rem; unsigned int i; =20 @@ -72259,7 +74615,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace.c l= inux-2.6.32.49/kernel/trace/tra /* copy the tracer to avoid using a global lock all around */ mutex_lock(&trace_types_lock); if (unlikely(old_tracer !=3D current_trace && current_trace)) { -@@ -3659,6 +3661,8 @@ tracing_buffers_splice_read(struct file=20 +@@ -3659,6 +3661,8 @@ tracing_buffers_splice_read(struct file *file, lof= f_t *ppos, int entries, size, i; size_t ret; =20 @@ -72268,7 +74624,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace.c l= inux-2.6.32.49/kernel/trace/tra if (*ppos & (PAGE_SIZE - 1)) { WARN_ONCE(1, "Ftrace: previous read must page-align\n"); return -EINVAL; -@@ -3816,10 +3820,9 @@ static const struct file_operations trac +@@ -3816,10 +3820,9 @@ static const struct file_operations tracing_dyn_i= nfo_fops =3D { }; #endif =20 @@ -72292,10 +74648,11 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace.c= linux-2.6.32.49/kernel/trace/tra static int once; struct dentry *d_tracer; =20 -diff -urNp linux-2.6.32.49/kernel/trace/trace_events.c linux-2.6.32.49/k= ernel/trace/trace_events.c ---- linux-2.6.32.49/kernel/trace/trace_events.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/kernel/trace/trace_events.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -951,13 +951,10 @@ static LIST_HEAD(ftrace_module_file_list +diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c +index d128f65..f37b4af 100644 +--- a/kernel/trace/trace_events.c ++++ b/kernel/trace/trace_events.c +@@ -951,13 +951,10 @@ static LIST_HEAD(ftrace_module_file_list); * Modules must own their file_operations to keep up with * reference counting. */ @@ -72310,7 +74667,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_eve= nts.c linux-2.6.32.49/kernel/tr }; =20 static void remove_subsystem_dir(const char *name) -@@ -1004,17 +1001,12 @@ trace_create_file_ops(struct module *mod +@@ -1004,17 +1001,12 @@ trace_create_file_ops(struct module *mod) =20 file_ops->mod =3D mod; =20 @@ -72334,7 +74691,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_eve= nts.c linux-2.6.32.49/kernel/tr =20 list_add(&file_ops->list, &ftrace_module_file_list); =20 -@@ -1063,8 +1055,8 @@ static void trace_module_add_events(stru +@@ -1063,8 +1055,8 @@ static void trace_module_add_events(struct module = *mod) call->mod =3D mod; list_add(&call->list, &ftrace_events); event_create_dir(call, d_events, @@ -72345,9 +74702,10 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_ev= ents.c linux-2.6.32.49/kernel/tr } } =20 -diff -urNp linux-2.6.32.49/kernel/trace/trace_mmiotrace.c linux-2.6.32.4= 9/kernel/trace/trace_mmiotrace.c ---- linux-2.6.32.49/kernel/trace/trace_mmiotrace.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/kernel/trace/trace_mmiotrace.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/kernel/trace/trace_mmiotrace.c b/kernel/trace/trace_mmiotra= ce.c +index 0acd834..b800b56 100644 +--- a/kernel/trace/trace_mmiotrace.c ++++ b/kernel/trace/trace_mmiotrace.c @@ -23,7 +23,7 @@ struct header_iter { static struct trace_array *mmio_trace_array; static bool overrun_detected; @@ -72357,7 +74715,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_mmi= otrace.c linux-2.6.32.49/kernel =20 static void mmio_reset_data(struct trace_array *tr) { -@@ -126,7 +126,7 @@ static void mmio_close(struct trace_iter +@@ -126,7 +126,7 @@ static void mmio_close(struct trace_iterator *iter) =20 static unsigned long count_overruns(struct trace_iterator *iter) { @@ -72366,7 +74724,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_mmi= otrace.c linux-2.6.32.49/kernel unsigned long over =3D ring_buffer_overruns(iter->tr->buffer); =20 if (over > prev_overruns) -@@ -316,7 +316,7 @@ static void __trace_mmiotrace_rw(struct=20 +@@ -316,7 +316,7 @@ static void __trace_mmiotrace_rw(struct trace_array = *tr, event =3D trace_buffer_lock_reserve(buffer, TRACE_MMIO_RW, sizeof(*entry), 0, pc); if (!event) { @@ -72375,7 +74733,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_mmi= otrace.c linux-2.6.32.49/kernel return; } entry =3D ring_buffer_event_data(event); -@@ -346,7 +346,7 @@ static void __trace_mmiotrace_map(struct +@@ -346,7 +346,7 @@ static void __trace_mmiotrace_map(struct trace_array= *tr, event =3D trace_buffer_lock_reserve(buffer, TRACE_MMIO_MAP, sizeof(*entry), 0, pc); if (!event) { @@ -72384,10 +74742,11 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_m= miotrace.c linux-2.6.32.49/kernel return; } entry =3D ring_buffer_event_data(event); -diff -urNp linux-2.6.32.49/kernel/trace/trace_output.c linux-2.6.32.49/k= ernel/trace/trace_output.c ---- linux-2.6.32.49/kernel/trace/trace_output.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/kernel/trace/trace_output.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -237,7 +237,7 @@ int trace_seq_path(struct trace_seq *s,=20 +diff --git a/kernel/trace/trace_output.c b/kernel/trace/trace_output.c +index b6c12c6..41fdc53 100644 +--- a/kernel/trace/trace_output.c ++++ b/kernel/trace/trace_output.c +@@ -237,7 +237,7 @@ int trace_seq_path(struct trace_seq *s, struct path = *path) return 0; p =3D d_path(path, s->buffer + s->len, PAGE_SIZE - s->len); if (!IS_ERR(p)) { @@ -72396,9 +74755,10 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_ou= tput.c linux-2.6.32.49/kernel/tr if (p) { s->len =3D p - s->buffer; return 1; -diff -urNp linux-2.6.32.49/kernel/trace/trace_stack.c linux-2.6.32.49/ke= rnel/trace/trace_stack.c ---- linux-2.6.32.49/kernel/trace/trace_stack.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/kernel/trace/trace_stack.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/kernel/trace/trace_stack.c b/kernel/trace/trace_stack.c +index 8504ac7..ecf0adb 100644 +--- a/kernel/trace/trace_stack.c ++++ b/kernel/trace/trace_stack.c @@ -50,7 +50,7 @@ static inline void check_stack(void) return; =20 @@ -72408,9 +74768,10 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_st= ack.c linux-2.6.32.49/kernel/tra return; =20 local_irq_save(flags); -diff -urNp linux-2.6.32.49/kernel/trace/trace_workqueue.c linux-2.6.32.4= 9/kernel/trace/trace_workqueue.c ---- linux-2.6.32.49/kernel/trace/trace_workqueue.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/kernel/trace/trace_workqueue.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/kernel/trace/trace_workqueue.c b/kernel/trace/trace_workque= ue.c +index 40cafb0..d5ead43 100644 +--- a/kernel/trace/trace_workqueue.c ++++ b/kernel/trace/trace_workqueue.c @@ -21,7 +21,7 @@ struct cpu_workqueue_stats { int cpu; pid_t pid; @@ -72420,7 +74781,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_wor= kqueue.c linux-2.6.32.49/kernel /* * Don't need to be atomic, works are serialized in a single workqueue= thread * on a single CPU. -@@ -58,7 +58,7 @@ probe_workqueue_insertion(struct task_st +@@ -58,7 +58,7 @@ probe_workqueue_insertion(struct task_struct *wq_threa= d, spin_lock_irqsave(&workqueue_cpu_stat(cpu)->lock, flags); list_for_each_entry(node, &workqueue_cpu_stat(cpu)->list, list) { if (node->pid =3D=3D wq_thread->pid) { @@ -72429,7 +74790,7 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_wor= kqueue.c linux-2.6.32.49/kernel goto found; } } -@@ -205,7 +205,7 @@ static int workqueue_stat_show(struct se +@@ -205,7 +205,7 @@ static int workqueue_stat_show(struct seq_file *s, v= oid *p) tsk =3D get_pid_task(pid, PIDTYPE_PID); if (tsk) { seq_printf(s, "%3d %6d %6u %s\n", cws->cpu, @@ -72438,10 +74799,11 @@ diff -urNp linux-2.6.32.49/kernel/trace/trace_w= orkqueue.c linux-2.6.32.49/kernel tsk->comm); put_task_struct(tsk); } -diff -urNp linux-2.6.32.49/kernel/user.c linux-2.6.32.49/kernel/user.c ---- linux-2.6.32.49/kernel/user.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/kernel/user.c 2011-11-15 19:59:43.000000000 -0500 -@@ -159,6 +159,7 @@ struct user_struct *alloc_uid(struct use +diff --git a/kernel/user.c b/kernel/user.c +index 1b91701..8795237 100644 +--- a/kernel/user.c ++++ b/kernel/user.c +@@ -159,6 +159,7 @@ struct user_struct *alloc_uid(struct user_namespace = *ns, uid_t uid) spin_lock_irq(&uidhash_lock); up =3D uid_hash_find(uid, hashent); if (up) { @@ -72449,10 +74811,24 @@ diff -urNp linux-2.6.32.49/kernel/user.c linux-= 2.6.32.49/kernel/user.c key_put(new->uid_keyring); key_put(new->session_keyring); kmem_cache_free(uid_cachep, new); -diff -urNp linux-2.6.32.49/lib/bitmap.c linux-2.6.32.49/lib/bitmap.c ---- linux-2.6.32.49/lib/bitmap.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/bitmap.c 2011-11-15 19:59:43.000000000 -0500 -@@ -341,7 +341,7 @@ int __bitmap_parse(const char *buf, unsi +diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug +index 234ceb1..ad74049 100644 +--- a/lib/Kconfig.debug ++++ b/lib/Kconfig.debug +@@ -905,7 +905,7 @@ config LATENCYTOP + select STACKTRACE + select SCHEDSTATS + select SCHED_DEBUG +- depends on HAVE_LATENCYTOP_SUPPORT ++ depends on HAVE_LATENCYTOP_SUPPORT && !GRKERNSEC_HIDESYM + help + Enable this option if you want to use the LatencyTOP tool + to find out which userspace is blocking on what kernel operations. +diff --git a/lib/bitmap.c b/lib/bitmap.c +index 7025658..8d14cab 100644 +--- a/lib/bitmap.c ++++ b/lib/bitmap.c +@@ -341,7 +341,7 @@ int __bitmap_parse(const char *buf, unsigned int buf= len, { int c, old_c, totaldigits, ndigits, nchunks, nbits; u32 chunk; @@ -72461,7 +74837,7 @@ diff -urNp linux-2.6.32.49/lib/bitmap.c linux-2.6= .32.49/lib/bitmap.c =20 bitmap_zero(maskp, nmaskbits); =20 -@@ -426,7 +426,7 @@ int bitmap_parse_user(const char __user=20 +@@ -426,7 +426,7 @@ int bitmap_parse_user(const char __user *ubuf, { if (!access_ok(VERIFY_READ, ubuf, ulen)) return -EFAULT; @@ -72470,10 +74846,11 @@ diff -urNp linux-2.6.32.49/lib/bitmap.c linux-2= .6.32.49/lib/bitmap.c } EXPORT_SYMBOL(bitmap_parse_user); =20 -diff -urNp linux-2.6.32.49/lib/bug.c linux-2.6.32.49/lib/bug.c ---- linux-2.6.32.49/lib/bug.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/bug.c 2011-11-15 19:59:43.000000000 -0500 -@@ -135,6 +135,8 @@ enum bug_trap_type report_bug(unsigned l +diff --git a/lib/bug.c b/lib/bug.c +index 300e41a..2779eb0 100644 +--- a/lib/bug.c ++++ b/lib/bug.c +@@ -135,6 +135,8 @@ enum bug_trap_type report_bug(unsigned long bugaddr,= struct pt_regs *regs) return BUG_TRAP_TYPE_NONE; =20 bug =3D find_bug(bugaddr); @@ -72482,10 +74859,11 @@ diff -urNp linux-2.6.32.49/lib/bug.c linux-2.6.= 32.49/lib/bug.c =20 printk(KERN_EMERG "------------[ cut here ]------------\n"); =20 -diff -urNp linux-2.6.32.49/lib/debugobjects.c linux-2.6.32.49/lib/debugo= bjects.c ---- linux-2.6.32.49/lib/debugobjects.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/lib/debugobjects.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -277,7 +277,7 @@ static void debug_object_is_on_stack(voi +diff --git a/lib/debugobjects.c b/lib/debugobjects.c +index 2b413db..e21d207 100644 +--- a/lib/debugobjects.c ++++ b/lib/debugobjects.c +@@ -277,7 +277,7 @@ static void debug_object_is_on_stack(void *addr, int= onstack) if (limit > 4) return; =20 @@ -72494,10 +74872,11 @@ diff -urNp linux-2.6.32.49/lib/debugobjects.c l= inux-2.6.32.49/lib/debugobjects.c if (is_on_stack =3D=3D onstack) return; =20 -diff -urNp linux-2.6.32.49/lib/devres.c linux-2.6.32.49/lib/devres.c ---- linux-2.6.32.49/lib/devres.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/devres.c 2011-11-15 19:59:43.000000000 -0500 -@@ -80,7 +80,7 @@ void devm_iounmap(struct device *dev, vo +diff --git a/lib/devres.c b/lib/devres.c +index 72c8909..7543868 100644 +--- a/lib/devres.c ++++ b/lib/devres.c +@@ -80,7 +80,7 @@ void devm_iounmap(struct device *dev, void __iomem *ad= dr) { iounmap(addr); WARN_ON(devres_destroy(dev, devm_ioremap_release, devm_ioremap_match, @@ -72506,7 +74885,7 @@ diff -urNp linux-2.6.32.49/lib/devres.c linux-2.6= .32.49/lib/devres.c } EXPORT_SYMBOL(devm_iounmap); =20 -@@ -140,7 +140,7 @@ void devm_ioport_unmap(struct device *de +@@ -140,7 +140,7 @@ void devm_ioport_unmap(struct device *dev, void __io= mem *addr) { ioport_unmap(addr); WARN_ON(devres_destroy(dev, devm_ioport_map_release, @@ -72515,9 +74894,10 @@ diff -urNp linux-2.6.32.49/lib/devres.c linux-2.= 6.32.49/lib/devres.c } EXPORT_SYMBOL(devm_ioport_unmap); =20 -diff -urNp linux-2.6.32.49/lib/dma-debug.c linux-2.6.32.49/lib/dma-debug= .c ---- linux-2.6.32.49/lib/dma-debug.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/dma-debug.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/lib/dma-debug.c b/lib/dma-debug.c +index 084e879..0674448 100644 +--- a/lib/dma-debug.c ++++ b/lib/dma-debug.c @@ -861,7 +861,7 @@ out: =20 static void check_for_stack(struct device *dev, void *addr) @@ -72527,10 +74907,11 @@ diff -urNp linux-2.6.32.49/lib/dma-debug.c linu= x-2.6.32.49/lib/dma-debug.c err_printk(dev, NULL, "DMA-API: device driver maps memory from" "stack [addr=3D%p]\n", addr); } -diff -urNp linux-2.6.32.49/lib/idr.c linux-2.6.32.49/lib/idr.c ---- linux-2.6.32.49/lib/idr.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/idr.c 2011-11-15 19:59:43.000000000 -0500 -@@ -156,7 +156,7 @@ static int sub_alloc(struct idr *idp, in +diff --git a/lib/idr.c b/lib/idr.c +index eda7ba3..915dfae 100644 +--- a/lib/idr.c ++++ b/lib/idr.c +@@ -156,7 +156,7 @@ static int sub_alloc(struct idr *idp, int *starting_= id, struct idr_layer **pa) id =3D (id | ((1 << (IDR_BITS * l)) - 1)) + 1; =20 /* if already at the top layer, we need to grow */ @@ -72539,9 +74920,10 @@ diff -urNp linux-2.6.32.49/lib/idr.c linux-2.6.3= 2.49/lib/idr.c *starting_id =3D id; return IDR_NEED_TO_GROW; } -diff -urNp linux-2.6.32.49/lib/inflate.c linux-2.6.32.49/lib/inflate.c ---- linux-2.6.32.49/lib/inflate.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/inflate.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/lib/inflate.c b/lib/inflate.c +index d102559..4215f31 100644 +--- a/lib/inflate.c ++++ b/lib/inflate.c @@ -266,7 +266,7 @@ static void free(void *where) malloc_ptr =3D free_mem_ptr; } @@ -72551,22 +74933,11 @@ diff -urNp linux-2.6.32.49/lib/inflate.c linux-= 2.6.32.49/lib/inflate.c #define free(a) kfree(a) #endif =20 -diff -urNp linux-2.6.32.49/lib/Kconfig.debug linux-2.6.32.49/lib/Kconfig= .debug ---- linux-2.6.32.49/lib/Kconfig.debug 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/lib/Kconfig.debug 2011-11-15 19:59:43.000000000 -050= 0 -@@ -905,7 +905,7 @@ config LATENCYTOP - select STACKTRACE - select SCHEDSTATS - select SCHED_DEBUG -- depends on HAVE_LATENCYTOP_SUPPORT -+ depends on HAVE_LATENCYTOP_SUPPORT && !GRKERNSEC_HIDESYM - help - Enable this option if you want to use the LatencyTOP tool - to find out which userspace is blocking on what kernel operations. -diff -urNp linux-2.6.32.49/lib/kobject.c linux-2.6.32.49/lib/kobject.c ---- linux-2.6.32.49/lib/kobject.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/kobject.c 2011-11-15 19:59:43.000000000 -0500 -@@ -700,7 +700,7 @@ static ssize_t kobj_attr_store(struct ko +diff --git a/lib/kobject.c b/lib/kobject.c +index b512b74..8115eb1 100644 +--- a/lib/kobject.c ++++ b/lib/kobject.c +@@ -700,7 +700,7 @@ static ssize_t kobj_attr_store(struct kobject *kobj,= struct attribute *attr, return ret; } =20 @@ -72584,7 +74955,7 @@ diff -urNp linux-2.6.32.49/lib/kobject.c linux-2.= 6.32.49/lib/kobject.c struct kobject *parent_kobj) { struct kset *kset; -@@ -832,7 +832,7 @@ static struct kset *kset_create(const ch +@@ -832,7 +832,7 @@ static struct kset *kset_create(const char *name, * If the kset was not able to be created, NULL will be returned. */ struct kset *kset_create_and_add(const char *name, @@ -72593,10 +74964,11 @@ diff -urNp linux-2.6.32.49/lib/kobject.c linux-= 2.6.32.49/lib/kobject.c struct kobject *parent_kobj) { struct kset *kset; -diff -urNp linux-2.6.32.49/lib/kobject_uevent.c linux-2.6.32.49/lib/kobj= ect_uevent.c ---- linux-2.6.32.49/lib/kobject_uevent.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/lib/kobject_uevent.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -95,7 +95,7 @@ int kobject_uevent_env(struct kobject *k +diff --git a/lib/kobject_uevent.c b/lib/kobject_uevent.c +index 507b821..0bf8ed0 100644 +--- a/lib/kobject_uevent.c ++++ b/lib/kobject_uevent.c +@@ -95,7 +95,7 @@ int kobject_uevent_env(struct kobject *kobj, enum kobj= ect_action action, const char *subsystem; struct kobject *top_kobj; struct kset *kset; @@ -72605,9 +74977,10 @@ diff -urNp linux-2.6.32.49/lib/kobject_uevent.c = linux-2.6.32.49/lib/kobject_ueve u64 seq; int i =3D 0; int retval =3D 0; -diff -urNp linux-2.6.32.49/lib/kref.c linux-2.6.32.49/lib/kref.c ---- linux-2.6.32.49/lib/kref.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/kref.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/lib/kref.c b/lib/kref.c +index 9ecd6e8..12c94c1 100644 +--- a/lib/kref.c ++++ b/lib/kref.c @@ -61,7 +61,7 @@ void kref_get(struct kref *kref) */ int kref_put(struct kref *kref, void (*release)(struct kref *kref)) @@ -72617,10 +74990,11 @@ diff -urNp linux-2.6.32.49/lib/kref.c linux-2.6= .32.49/lib/kref.c WARN_ON(release =3D=3D (void (*)(struct kref *))kfree); =20 if (atomic_dec_and_test(&kref->refcount)) { -diff -urNp linux-2.6.32.49/lib/parser.c linux-2.6.32.49/lib/parser.c ---- linux-2.6.32.49/lib/parser.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/parser.c 2011-11-15 19:59:43.000000000 -0500 -@@ -126,7 +126,7 @@ static int match_number(substring_t *s,=20 +diff --git a/lib/parser.c b/lib/parser.c +index b00d020..1b34325 100644 +--- a/lib/parser.c ++++ b/lib/parser.c +@@ -126,7 +126,7 @@ static int match_number(substring_t *s, int *result,= int base) char *buf; int ret; =20 @@ -72629,9 +75003,10 @@ diff -urNp linux-2.6.32.49/lib/parser.c linux-2.= 6.32.49/lib/parser.c if (!buf) return -ENOMEM; memcpy(buf, s->from, s->to - s->from); -diff -urNp linux-2.6.32.49/lib/radix-tree.c linux-2.6.32.49/lib/radix-tr= ee.c ---- linux-2.6.32.49/lib/radix-tree.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/radix-tree.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/lib/radix-tree.c b/lib/radix-tree.c +index 92cdd99..a8149d7 100644 +--- a/lib/radix-tree.c ++++ b/lib/radix-tree.c @@ -81,7 +81,7 @@ struct radix_tree_preload { int nr; struct radix_tree_node *nodes[RADIX_TREE_MAX_PATH]; @@ -72641,10 +75016,11 @@ diff -urNp linux-2.6.32.49/lib/radix-tree.c lin= ux-2.6.32.49/lib/radix-tree.c =20 static inline gfp_t root_gfp_mask(struct radix_tree_root *root) { -diff -urNp linux-2.6.32.49/lib/random32.c linux-2.6.32.49/lib/random32.c ---- linux-2.6.32.49/lib/random32.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/random32.c 2011-11-15 19:59:43.000000000 -0500 -@@ -61,7 +61,7 @@ static u32 __random32(struct rnd_state * +diff --git a/lib/random32.c b/lib/random32.c +index 217d5c4..45aba8a 100644 +--- a/lib/random32.c ++++ b/lib/random32.c +@@ -61,7 +61,7 @@ static u32 __random32(struct rnd_state *state) */ static inline u32 __seed(u32 x, u32 m) { @@ -72653,9 +75029,10 @@ diff -urNp linux-2.6.32.49/lib/random32.c linux-= 2.6.32.49/lib/random32.c } =20 /** -diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2.6.32.49/lib/vsprintf.c ---- linux-2.6.32.49/lib/vsprintf.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/lib/vsprintf.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/lib/vsprintf.c b/lib/vsprintf.c +index 33bed5e..1477e46 100644 +--- a/lib/vsprintf.c ++++ b/lib/vsprintf.c @@ -16,6 +16,9 @@ * - scnprintf and vscnprintf */ @@ -72666,7 +75043,7 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2= .6.32.49/lib/vsprintf.c #include #include #include -@@ -546,12 +549,12 @@ static char *number(char *buf, char *end +@@ -546,12 +549,12 @@ static char *number(char *buf, char *end, unsigned= long long num, return buf; } =20 @@ -72681,7 +75058,7 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2= .6.32.49/lib/vsprintf.c =20 len =3D strnlen(s, spec.precision); =20 -@@ -581,7 +584,7 @@ static char *symbol_string(char *buf, ch +@@ -581,7 +584,7 @@ static char *symbol_string(char *buf, char *end, voi= d *ptr, unsigned long value =3D (unsigned long) ptr; #ifdef CONFIG_KALLSYMS char sym[KSYM_SYMBOL_LEN]; @@ -72690,7 +75067,7 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2= .6.32.49/lib/vsprintf.c sprint_symbol(sym, value); else kallsyms_lookup(value, NULL, NULL, NULL, sym); -@@ -801,6 +804,8 @@ static char *ip4_addr_string(char *buf,=20 +@@ -801,6 +804,8 @@ static char *ip4_addr_string(char *buf, char *end, c= onst u8 *addr, * - 'f' For simple symbolic function names without offset * - 'S' For symbolic direct pointers with offset * - 's' For symbolic direct pointers without offset @@ -72699,7 +75076,7 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2= .6.32.49/lib/vsprintf.c * - 'R' For a struct resource pointer, it prints the range of * addresses (not the name nor the flags) * - 'M' For a 6-byte MAC address, it prints the address in the -@@ -822,7 +827,7 @@ static char *pointer(const char *fmt, ch +@@ -822,7 +827,7 @@ static char *pointer(const char *fmt, char *buf, cha= r *end, void *ptr, struct printf_spec spec) { if (!ptr) @@ -72708,7 +75085,7 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2= .6.32.49/lib/vsprintf.c =20 switch (*fmt) { case 'F': -@@ -831,6 +836,14 @@ static char *pointer(const char *fmt, ch +@@ -831,6 +836,14 @@ static char *pointer(const char *fmt, char *buf, ch= ar *end, void *ptr, case 's': /* Fallthrough */ case 'S': @@ -72732,7 +75109,7 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2= .6.32.49/lib/vsprintf.c len =3D strlen(save_str); if (str + len + 1 < end) memcpy(str, save_str, len + 1); -@@ -1555,11 +1568,11 @@ int bstr_printf(char *buf, size_t size,=20 +@@ -1555,11 +1568,11 @@ int bstr_printf(char *buf, size_t size, const ch= ar *fmt, const u32 *bin_buf) typeof(type) value; \ if (sizeof(type) =3D=3D 8) { \ args =3D PTR_ALIGN(args, sizeof(u32)); \ @@ -72747,7 +75124,7 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linux-2= .6.32.49/lib/vsprintf.c } \ args +=3D sizeof(type); \ value; \ -@@ -1622,7 +1635,7 @@ int bstr_printf(char *buf, size_t size,=20 +@@ -1622,7 +1635,7 @@ int bstr_printf(char *buf, size_t size, const char= *fmt, const u32 *bin_buf) const char *str_arg =3D args; size_t len =3D strlen(str_arg); args +=3D len + 1; @@ -72756,226 +75133,31 @@ diff -urNp linux-2.6.32.49/lib/vsprintf.c linu= x-2.6.32.49/lib/vsprintf.c break; } =20 -diff -urNp linux-2.6.32.49/localversion-grsec linux-2.6.32.49/localversi= on-grsec ---- linux-2.6.32.49/localversion-grsec 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-2.6.32.49/localversion-grsec 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/localversion-grsec b/localversion-grsec +new file mode 100644 +index 0000000..7cd6065 +--- /dev/null ++++ b/localversion-grsec @@ -0,0 +1 @@ +-grsec -diff -urNp linux-2.6.32.49/Makefile linux-2.6.32.49/Makefile ---- linux-2.6.32.49/Makefile 2011-11-26 19:44:53.000000000 -0500 -+++ linux-2.6.32.49/Makefile 2011-11-26 19:45:05.000000000 -0500 -@@ -221,8 +221,9 @@ CONFIG_SHELL :=3D $(shell if [ -x "$$BASH" -=20 - HOSTCC =3D gcc - HOSTCXX =3D g++ --HOSTCFLAGS =3D -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fo= mit-frame-pointer --HOSTCXXFLAGS =3D -O2 -+HOSTCFLAGS =3D -Wall -W -Wmissing-prototypes -Wstrict-prototypes -Wno= -unused-parameter -Wno-missing-field-initializers -O2 -fomit-frame-pointe= r -fno-delete-null-pointer-checks -+HOSTCFLAGS +=3D $(call cc-option, -Wno-empty-body) -+HOSTCXXFLAGS =3D -O2 -Wall -W -fno-delete-null-pointer-checks -=20 - # Decide whether to build built-in, modular, or both. - # Normally, just do built-in. -@@ -376,8 +377,8 @@ export RCS_TAR_IGNORE :=3D --exclude SCCS=20 - # Rules shared between *config targets and build targets -=20 - # Basic helpers built in scripts/ --PHONY +=3D scripts_basic --scripts_basic: -+PHONY +=3D scripts_basic gcc-plugins -+scripts_basic: gcc-plugins - $(Q)$(MAKE) $(build)=3Dscripts/basic -=20 - # To avoid any implicit rule to kick in, define an empty command. -@@ -403,7 +404,7 @@ endif - # of make so .config is not included in this case either (for *config). -=20 - no-dot-config-targets :=3D clean mrproper distclean \ -- cscope TAGS tags help %docs check% \ -+ cscope gtags TAGS tags help %docs check% \ - include/linux/version.h headers_% \ - kernelrelease kernelversion -=20 -@@ -526,6 +527,41 @@ else - KBUILD_CFLAGS +=3D -O2 - endif -=20 -+ifndef DISABLE_PAX_PLUGINS -+ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-plugin.sh "$(HOSTC= C)" "$(CC)"), y) -+ifndef DISABLE_PAX_CONSTIFY_PLUGIN -+CONSTIFY_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/constify_plugin.so= -DCONSTIFY_PLUGIN -+endif -+ifdef CONFIG_PAX_MEMORY_STACKLEAK -+STACKLEAK_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/stackleak_plugin.= so -DSTACKLEAK_PLUGIN -+STACKLEAK_PLUGIN +=3D -fplugin-arg-stackleak_plugin-track-lowest-sp=3D1= 00 -+endif -+ifdef CONFIG_KALLOCSTAT_PLUGIN -+KALLOCSTAT_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kallocstat_plugi= n.so -+endif -+ifdef CONFIG_PAX_KERNEXEC_PLUGIN -+KERNEXEC_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kernexec_plugin.so -+endif -+ifdef CONFIG_CHECKER_PLUGIN -+ifeq ($(call cc-ifversion, -ge, 0406, y), y) -+CHECKER_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/checker_plugin.so -= DCHECKER_PLUGIN -+endif -+endif -+GCC_PLUGINS :=3D $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN) $(KALLOCSTAT_PL= UGIN) $(KERNEXEC_PLUGIN) $(CHECKER_PLUGIN) -+export CONSTIFY_PLUGIN STACKLEAK_PLUGIN KERNEXEC_PLUGIN CHECKER_PLUGIN -+gcc-plugins: -+ $(Q)$(MAKE) $(build)=3Dtools/gcc -+else -+gcc-plugins: -+ifeq ($(call cc-ifversion, -ge, 0405, y), y) -+ $(error Your gcc installation does not support plugins. If the necess= ary headers for plugin support are missing, they should be installed. On= Debian, apt-get install gcc--plugin-dev. If you choose to ignore t= his error and lessen the improvements provided by this patch, re-run make= with the DISABLE_PAX_PLUGINS=3Dy argument.)) -+else -+ $(Q)echo "warning, your gcc version does not support plugins, you shou= ld upgrade it to gcc 4.5 at least" -+endif -+ $(Q)echo "PAX_MEMORY_STACKLEAK and constification will be less secure" -+endif -+endif -+ - include $(srctree)/arch/$(SRCARCH)/Makefile -=20 - ifneq ($(CONFIG_FRAME_WARN),0) -@@ -647,7 +683,7 @@ export mod_strip_cmd -=20 -=20 - ifeq ($(KBUILD_EXTMOD),) --core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ -+core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ -=20 - vmlinux-dirs :=3D $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ - $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ -@@ -868,6 +904,7 @@ vmlinux.o: $(modpost-init) $(vmlinux-mai -=20 - # The actual objects are generated when descending,=20 - # make sure no implicit rule kicks in -+$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): KBUILD_CFLAGS += =3D $(GCC_PLUGINS) - $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): $(vmlinux-dirs)= ; -=20 - # Handle descending into subdirectories listed in $(vmlinux-dirs) -@@ -877,7 +914,7 @@ $(sort $(vmlinux-init) $(vmlinux-main))=20 - # Error messages still appears in the original language -=20 - PHONY +=3D $(vmlinux-dirs) --$(vmlinux-dirs): prepare scripts -+$(vmlinux-dirs): gcc-plugins prepare scripts - $(Q)$(MAKE) $(build)=3D$@ -=20 - # Build the kernel release string -@@ -986,6 +1023,7 @@ prepare0: archprepare FORCE - $(Q)$(MAKE) $(build)=3D. missing-syscalls -=20 - # All the preparing.. -+prepare: KBUILD_CFLAGS :=3D $(filter-out $(GCC_PLUGINS),$(KBUILD_CFLAGS= )) - prepare: prepare0 -=20 - # The asm symlink changes when $(ARCH) changes. -@@ -1127,6 +1165,7 @@ all: modules - # using awk while concatenating to the final file. -=20 - PHONY +=3D modules -+modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) - modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) - $(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=3D$(objtree)/%/modules.order) = > $(objtree)/modules.order - @$(kecho) ' Building modules, stage 2.'; -@@ -1136,7 +1175,7 @@ modules: $(vmlinux-dirs) $(if $(KBUILD_B -=20 - # Target to prepare building external modules - PHONY +=3D modules_prepare --modules_prepare: prepare scripts -+modules_prepare: gcc-plugins prepare scripts -=20 - # Target to install modules - PHONY +=3D modules_install -@@ -1201,7 +1240,7 @@ MRPROPER_FILES +=3D .config .config.old in - include/linux/autoconf.h include/linux/version.h = \ - include/linux/utsrelease.h = \ - include/linux/bounds.h include/asm*/asm-offsets.h = \ -- Module.symvers Module.markers tags TAGS cscope* -+ Module.symvers Module.markers tags TAGS cscope* GPATH GTAGS GRTAGS = GSYMS -=20 - # clean - Delete most, but leave enough to build external modules - # -@@ -1245,7 +1284,7 @@ distclean: mrproper - @find $(srctree) $(RCS_FIND_IGNORE) \ - \( -name '*.orig' -o -name '*.rej' -o -name '*~' \ - -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \ -- -o -name '.*.rej' -o -size 0 \ -+ -o -name '.*.rej' -o -name '*.so' -o -size 0 \ - -o -name '*%' -o -name '.*.cmd' -o -name 'core' \) \ - -type f -print | xargs rm -f -=20 -@@ -1292,6 +1331,7 @@ help: - @echo ' modules_prepare - Set up for building external modules' - @echo ' tags/TAGS - Generate tags file for editors' - @echo ' cscope - Generate cscope index' -+ @echo ' gtags - Generate GNU GLOBAL index' - @echo ' kernelrelease - Output the release version string' - @echo ' kernelversion - Output the version stored in Makefile' - @echo ' headers_install - Install sanitised kernel headers to INSTAL= L_HDR_PATH'; \ -@@ -1393,6 +1433,7 @@ PHONY +=3D $(module-dirs) modules - $(module-dirs): crmodverdir $(objtree)/Module.symvers - $(Q)$(MAKE) $(build)=3D$(patsubst _module_%,%,$@) -=20 -+modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) - modules: $(module-dirs) - @$(kecho) ' Building modules, stage 2.'; - $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost -@@ -1448,7 +1489,7 @@ endif # KBUILD_EXTMOD - quiet_cmd_tags =3D GEN $@ - cmd_tags =3D $(CONFIG_SHELL) $(srctree)/scripts/tags.sh $@ -=20 --tags TAGS cscope: FORCE -+tags TAGS cscope gtags: FORCE - $(call cmd,tags) -=20 - # Scripts to check various things for consistency -@@ -1513,17 +1554,19 @@ else - target-dir =3D $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@)) - endif -=20 --%.s: %.c prepare scripts FORCE -+%.s: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%.s: %.c gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) - %.i: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) --%.o: %.c prepare scripts FORCE -+%.o: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%.o: %.c gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) - %.lst: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) --%.s: %.S prepare scripts FORCE -+%.s: %.S gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) --%.o: %.S prepare scripts FORCE -+%.o: %.S gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) - %.symtypes: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) -@@ -1533,11 +1576,13 @@ endif - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ - $(build)=3D$(build-dir) --%/: prepare scripts FORCE -+%/: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%/: gcc-plugins prepare scripts FORCE - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ - $(build)=3D$(build-dir) --%.ko: prepare scripts FORCE -+%.ko: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%.ko: gcc-plugins prepare scripts FORCE - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ - $(build)=3D$(build-dir) $(@:.ko=3D.o) -diff -urNp linux-2.6.32.49/mm/backing-dev.c linux-2.6.32.49/mm/backing-d= ev.c ---- linux-2.6.32.49/mm/backing-dev.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/backing-dev.c 2011-11-15 19:59:43.000000000 -0500 -@@ -272,7 +272,7 @@ static void bdi_task_init(struct backing +diff --git a/mm/Kconfig b/mm/Kconfig +index 2c19c0b..f3c3f83 100644 +--- a/mm/Kconfig ++++ b/mm/Kconfig +@@ -228,7 +228,7 @@ config KSM + config DEFAULT_MMAP_MIN_ADDR + int "Low address space to protect from user allocation" + depends on MMU +- default 4096 ++ default 65536 + help + This is the portion of low virtual memory which should be protected + from userspace allocation. Keeping a user from writing to low pages +diff --git a/mm/backing-dev.c b/mm/backing-dev.c +index 67a33a5..094dcf1 100644 +--- a/mm/backing-dev.c ++++ b/mm/backing-dev.c +@@ -272,7 +272,7 @@ static void bdi_task_init(struct backing_dev_info *b= di, list_add_tail_rcu(&wb->list, &bdi->wb_list); spin_unlock(&bdi->wb_lock); =20 @@ -72984,7 +75166,7 @@ diff -urNp linux-2.6.32.49/mm/backing-dev.c linux= -2.6.32.49/mm/backing-dev.c set_freezable(); =20 /* -@@ -484,7 +484,7 @@ static void bdi_add_to_pending(struct rc +@@ -484,7 +484,7 @@ static void bdi_add_to_pending(struct rcu_head *head= ) * Add the default flusher task that gets created for any bdi * that has dirty data pending writeout */ @@ -72993,10 +75175,11 @@ diff -urNp linux-2.6.32.49/mm/backing-dev.c lin= ux-2.6.32.49/mm/backing-dev.c { if (!bdi_cap_writeback_dirty(bdi)) return; -diff -urNp linux-2.6.32.49/mm/filemap.c linux-2.6.32.49/mm/filemap.c ---- linux-2.6.32.49/mm/filemap.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/filemap.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1631,7 +1631,7 @@ int generic_file_mmap(struct file * file +diff --git a/mm/filemap.c b/mm/filemap.c +index 9e0826e..4ee8f13 100644 +--- a/mm/filemap.c ++++ b/mm/filemap.c +@@ -1631,7 +1631,7 @@ int generic_file_mmap(struct file * file, struct v= m_area_struct * vma) struct address_space *mapping =3D file->f_mapping; =20 if (!mapping->a_ops->readpage) @@ -73005,7 +75188,7 @@ diff -urNp linux-2.6.32.49/mm/filemap.c linux-2.6= .32.49/mm/filemap.c file_accessed(file); vma->vm_ops =3D &generic_file_vm_ops; vma->vm_flags |=3D VM_CAN_NONLINEAR; -@@ -2027,6 +2027,7 @@ inline int generic_write_checks(struct f +@@ -2027,6 +2027,7 @@ inline int generic_write_checks(struct file *file,= loff_t *pos, size_t *count, i *pos =3D i_size_read(inode); =20 if (limit !=3D RLIM_INFINITY) { @@ -73013,10 +75196,11 @@ diff -urNp linux-2.6.32.49/mm/filemap.c linux-2= .6.32.49/mm/filemap.c if (*pos >=3D limit) { send_sig(SIGXFSZ, current, 0); return -EFBIG; -diff -urNp linux-2.6.32.49/mm/fremap.c linux-2.6.32.49/mm/fremap.c ---- linux-2.6.32.49/mm/fremap.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/fremap.c 2011-11-15 19:59:43.000000000 -0500 -@@ -153,6 +153,11 @@ SYSCALL_DEFINE5(remap_file_pages, unsign +diff --git a/mm/fremap.c b/mm/fremap.c +index b6ec85a..a24ac22 100644 +--- a/mm/fremap.c ++++ b/mm/fremap.c +@@ -153,6 +153,11 @@ SYSCALL_DEFINE5(remap_file_pages, unsigned long, st= art, unsigned long, size, retry: vma =3D find_vma(mm, start); =20 @@ -73028,7 +75212,7 @@ diff -urNp linux-2.6.32.49/mm/fremap.c linux-2.6.= 32.49/mm/fremap.c /* * Make sure the vma is shared, that it supports prefaulting, * and that the remapped range is valid and fully within -@@ -221,7 +226,7 @@ SYSCALL_DEFINE5(remap_file_pages, unsign +@@ -221,7 +226,7 @@ SYSCALL_DEFINE5(remap_file_pages, unsigned long, sta= rt, unsigned long, size, /* * drop PG_Mlocked flag for over-mapped range */ @@ -73037,9 +75221,10 @@ diff -urNp linux-2.6.32.49/mm/fremap.c linux-2.6= .32.49/mm/fremap.c munlock_vma_pages_range(vma, start, start + size); vma->vm_flags =3D saved_flags; } -diff -urNp linux-2.6.32.49/mm/highmem.c linux-2.6.32.49/mm/highmem.c ---- linux-2.6.32.49/mm/highmem.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/highmem.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/highmem.c b/mm/highmem.c +index 9c1e627..5ca9447 100644 +--- a/mm/highmem.c ++++ b/mm/highmem.c @@ -116,9 +116,10 @@ static void flush_all_zero_pkmaps(void) * So no dangers, even with speculative execution. */ @@ -73065,10 +75250,11 @@ diff -urNp linux-2.6.32.49/mm/highmem.c linux-2= .6.32.49/mm/highmem.c pkmap_count[last_pkmap_nr] =3D 1; set_page_address(page, (void *)vaddr); =20 -diff -urNp linux-2.6.32.49/mm/hugetlb.c linux-2.6.32.49/mm/hugetlb.c ---- linux-2.6.32.49/mm/hugetlb.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/hugetlb.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1933,6 +1933,26 @@ static int unmap_ref_private(struct mm_s +diff --git a/mm/hugetlb.c b/mm/hugetlb.c +index 5e1e508..9f0ebad 100644 +--- a/mm/hugetlb.c ++++ b/mm/hugetlb.c +@@ -1933,6 +1933,26 @@ static int unmap_ref_private(struct mm_struct *mm= , struct vm_area_struct *vma, return 1; } =20 @@ -73118,7 +75304,7 @@ diff -urNp linux-2.6.32.49/mm/hugetlb.c linux-2.6= .32.49/mm/hugetlb.c if ((flags & FAULT_FLAG_WRITE) && !(vma->vm_flags & VM_SHARED)) { /* Optimization, do the COW without a second fault */ ret =3D hugetlb_cow(mm, vma, address, ptep, new_pte, page); -@@ -2163,6 +2192,28 @@ int hugetlb_fault(struct mm_struct *mm,=20 +@@ -2163,6 +2192,28 @@ int hugetlb_fault(struct mm_struct *mm, struct vm= _area_struct *vma, static DEFINE_MUTEX(hugetlb_instantiation_mutex); struct hstate *h =3D hstate_vma(vma); =20 @@ -73147,10 +75333,11 @@ diff -urNp linux-2.6.32.49/mm/hugetlb.c linux-2= .6.32.49/mm/hugetlb.c ptep =3D huge_pte_alloc(mm, address, huge_page_size(h)); if (!ptep) return VM_FAULT_OOM; -diff -urNp linux-2.6.32.49/mm/internal.h linux-2.6.32.49/mm/internal.h ---- linux-2.6.32.49/mm/internal.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/internal.h 2011-11-15 19:59:43.000000000 -0500 -@@ -49,6 +49,7 @@ extern void putback_lru_page(struct page +diff --git a/mm/internal.h b/mm/internal.h +index f03e8e2..7354343 100644 +--- a/mm/internal.h ++++ b/mm/internal.h +@@ -49,6 +49,7 @@ extern void putback_lru_page(struct page *page); * in mm/page_alloc.c */ extern void __free_pages_bootmem(struct page *page, unsigned int order)= ; @@ -73158,22 +75345,11 @@ diff -urNp linux-2.6.32.49/mm/internal.h linux-= 2.6.32.49/mm/internal.h extern void prep_compound_page(struct page *page, unsigned long order); =20 =20 -diff -urNp linux-2.6.32.49/mm/Kconfig linux-2.6.32.49/mm/Kconfig ---- linux-2.6.32.49/mm/Kconfig 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/Kconfig 2011-11-15 19:59:43.000000000 -0500 -@@ -228,7 +228,7 @@ config KSM - config DEFAULT_MMAP_MIN_ADDR - int "Low address space to protect from user allocation" - depends on MMU -- default 4096 -+ default 65536 - help - This is the portion of low virtual memory which should be protected - from userspace allocation. Keeping a user from writing to low pages -diff -urNp linux-2.6.32.49/mm/kmemleak.c linux-2.6.32.49/mm/kmemleak.c ---- linux-2.6.32.49/mm/kmemleak.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/kmemleak.c 2011-11-15 19:59:43.000000000 -0500 -@@ -358,7 +358,7 @@ static void print_unreferenced(struct se +diff --git a/mm/kmemleak.c b/mm/kmemleak.c +index c346660..b47382f 100644 +--- a/mm/kmemleak.c ++++ b/mm/kmemleak.c +@@ -358,7 +358,7 @@ static void print_unreferenced(struct seq_file *seq, =20 for (i =3D 0; i < object->trace_len; i++) { void *ptr =3D (void *)object->trace[i]; @@ -73182,9 +75358,10 @@ diff -urNp linux-2.6.32.49/mm/kmemleak.c linux-2= .6.32.49/mm/kmemleak.c } } =20 -diff -urNp linux-2.6.32.49/mm/maccess.c linux-2.6.32.49/mm/maccess.c ---- linux-2.6.32.49/mm/maccess.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/maccess.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/maccess.c b/mm/maccess.c +index 9073695..1127f348 100644 +--- a/mm/maccess.c ++++ b/mm/maccess.c @@ -14,7 +14,7 @@ * Safely read from address @src to the buffer at @dst. If a kernel fa= ult * happens, handle that and return -EFAULT. @@ -73194,7 +75371,7 @@ diff -urNp linux-2.6.32.49/mm/maccess.c linux-2.6= .32.49/mm/maccess.c { long ret; mm_segment_t old_fs =3D get_fs(); -@@ -22,7 +22,7 @@ long probe_kernel_read(void *dst, void * +@@ -22,7 +22,7 @@ long probe_kernel_read(void *dst, void *src, size_t si= ze) set_fs(KERNEL_DS); pagefault_disable(); ret =3D __copy_from_user_inatomic(dst, @@ -73220,10 +75397,11 @@ diff -urNp linux-2.6.32.49/mm/maccess.c linux-2= .6.32.49/mm/maccess.c pagefault_enable(); set_fs(old_fs); =20 -diff -urNp linux-2.6.32.49/mm/madvise.c linux-2.6.32.49/mm/madvise.c ---- linux-2.6.32.49/mm/madvise.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/madvise.c 2011-11-15 19:59:43.000000000 -0500 -@@ -44,6 +44,10 @@ static long madvise_behavior(struct vm_a +diff --git a/mm/madvise.c b/mm/madvise.c +index 35b1479..499f7d4 100644 +--- a/mm/madvise.c ++++ b/mm/madvise.c +@@ -44,6 +44,10 @@ static long madvise_behavior(struct vm_area_struct * = vma, pgoff_t pgoff; unsigned long new_flags =3D vma->vm_flags; =20 @@ -73248,7 +75426,7 @@ diff -urNp linux-2.6.32.49/mm/madvise.c linux-2.6= .32.49/mm/madvise.c vma->vm_flags =3D new_flags; =20 out: -@@ -161,6 +172,11 @@ static long madvise_dontneed(struct vm_a +@@ -161,6 +172,11 @@ static long madvise_dontneed(struct vm_area_struct = * vma, struct vm_area_struct ** prev, unsigned long start, unsigned long end) { @@ -73260,7 +75438,7 @@ diff -urNp linux-2.6.32.49/mm/madvise.c linux-2.6= .32.49/mm/madvise.c *prev =3D vma; if (vma->vm_flags & (VM_LOCKED|VM_HUGETLB|VM_PFNMAP)) return -EINVAL; -@@ -173,6 +189,21 @@ static long madvise_dontneed(struct vm_a +@@ -173,6 +189,21 @@ static long madvise_dontneed(struct vm_area_struct = * vma, zap_page_range(vma, start, end - start, &details); } else zap_page_range(vma, start, end - start, NULL); @@ -73282,7 +75460,7 @@ diff -urNp linux-2.6.32.49/mm/madvise.c linux-2.6= .32.49/mm/madvise.c return 0; } =20 -@@ -359,6 +390,16 @@ SYSCALL_DEFINE3(madvise, unsigned long,=20 +@@ -359,6 +390,16 @@ SYSCALL_DEFINE3(madvise, unsigned long, start, size= _t, len_in, int, behavior) if (end < start) goto out; =20 @@ -73299,10 +75477,42 @@ diff -urNp linux-2.6.32.49/mm/madvise.c linux-2= .6.32.49/mm/madvise.c error =3D 0; if (end =3D=3D start) goto out; -diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.32.49/mm/memory.c ---- linux-2.6.32.49/mm/memory.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/memory.c 2011-11-15 19:59:43.000000000 -0500 -@@ -187,8 +187,12 @@ static inline void free_pmd_range(struct +diff --git a/mm/memory-failure.c b/mm/memory-failure.c +index 8aeba53..b4a4198 100644 +--- a/mm/memory-failure.c ++++ b/mm/memory-failure.c +@@ -46,7 +46,7 @@ int sysctl_memory_failure_early_kill __read_mostly =3D= 0; +=20 + int sysctl_memory_failure_recovery __read_mostly =3D 1; +=20 +-atomic_long_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INIT(0); ++atomic_long_unchecked_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INI= T(0); +=20 + /* + * Send all the processes who have the page mapped an ``action optional= '' +@@ -64,7 +64,7 @@ static int kill_proc_ao(struct task_struct *t, unsigne= d long addr, int trapno, + si.si_signo =3D SIGBUS; + si.si_errno =3D 0; + si.si_code =3D BUS_MCEERR_AO; +- si.si_addr =3D (void *)addr; ++ si.si_addr =3D (void __user *)addr; + #ifdef __ARCH_SI_TRAPNO + si.si_trapno =3D trapno; + #endif +@@ -745,7 +745,7 @@ int __memory_failure(unsigned long pfn, int trapno, = int ref) + return 0; + } +=20 +- atomic_long_add(1, &mce_bad_pages); ++ atomic_long_add_unchecked(1, &mce_bad_pages); +=20 + /* + * We need/can do nothing about count=3D0 pages. +diff --git a/mm/memory.c b/mm/memory.c +index 6c836d3..48f3264 100644 +--- a/mm/memory.c ++++ b/mm/memory.c +@@ -187,8 +187,12 @@ static inline void free_pmd_range(struct mmu_gather= *tlb, pud_t *pud, return; =20 pmd =3D pmd_offset(pud, start); @@ -73315,7 +75525,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c } =20 static inline void free_pud_range(struct mmu_gather *tlb, pgd_t *pgd, -@@ -219,9 +223,12 @@ static inline void free_pud_range(struct +@@ -219,9 +223,12 @@ static inline void free_pud_range(struct mmu_gather= *tlb, pgd_t *pgd, if (end - 1 > ceiling - 1) return; =20 @@ -73328,7 +75538,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c } =20 /* -@@ -1251,10 +1258,10 @@ int __get_user_pages(struct task_struct=20 +@@ -1251,10 +1258,10 @@ int __get_user_pages(struct task_struct *tsk, st= ruct mm_struct *mm, (VM_MAYREAD | VM_MAYWRITE) : (VM_READ | VM_WRITE); i =3D 0; =20 @@ -73341,7 +75551,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c if (!vma && in_gate_area(tsk, start)) { unsigned long pg =3D start & PAGE_MASK; struct vm_area_struct *gate_vma =3D get_gate_vma(tsk); -@@ -1306,7 +1313,7 @@ int __get_user_pages(struct task_struct=20 +@@ -1306,7 +1313,7 @@ int __get_user_pages(struct task_struct *tsk, stru= ct mm_struct *mm, continue; } =20 @@ -73350,7 +75560,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c (vma->vm_flags & (VM_IO | VM_PFNMAP)) || !(vm_flags & vma->vm_flags)) return i ? : -EFAULT; -@@ -1381,7 +1388,7 @@ int __get_user_pages(struct task_struct=20 +@@ -1381,7 +1388,7 @@ int __get_user_pages(struct task_struct *tsk, stru= ct mm_struct *mm, start +=3D PAGE_SIZE; nr_pages--; } while (nr_pages && start < vma->vm_end); @@ -73359,7 +75569,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c return i; } =20 -@@ -1526,6 +1533,10 @@ static int insert_page(struct vm_area_st +@@ -1526,6 +1533,10 @@ static int insert_page(struct vm_area_struct *vma= , unsigned long addr, page_add_file_rmap(page); set_pte_at(mm, addr, pte, mk_pte(page, prot)); =20 @@ -73393,7 +75603,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c vma->vm_flags |=3D VM_INSERTPAGE; return insert_page(vma, addr, page, vma->vm_page_prot); } -@@ -1649,6 +1672,7 @@ int vm_insert_mixed(struct vm_area_struc +@@ -1649,6 +1672,7 @@ int vm_insert_mixed(struct vm_area_struct *vma, un= signed long addr, unsigned long pfn) { BUG_ON(!(vma->vm_flags & VM_MIXEDMAP)); @@ -73401,7 +75611,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c =20 if (addr < vma->vm_start || addr >=3D vma->vm_end) return -EFAULT; -@@ -1977,6 +2001,186 @@ static inline void cow_user_page(struct=20 +@@ -1977,6 +2001,186 @@ static inline void cow_user_page(struct page *ds= t, struct page *src, unsigned lo copy_user_highpage(dst, src, va, vma); } =20 @@ -73612,7 +75822,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c /* Free the old page.. */ new_page =3D old_page; ret |=3D VM_FAULT_WRITE; -@@ -2606,6 +2820,11 @@ static int do_swap_page(struct mm_struct +@@ -2606,6 +2820,11 @@ static int do_swap_page(struct mm_struct *mm, str= uct vm_area_struct *vma, swap_free(entry); if (vm_swap_full() || (vma->vm_flags & VM_LOCKED) || PageMlocked(page)= ) try_to_free_swap(page); @@ -73624,7 +75834,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c unlock_page(page); =20 if (flags & FAULT_FLAG_WRITE) { -@@ -2617,6 +2836,11 @@ static int do_swap_page(struct mm_struct +@@ -2617,6 +2836,11 @@ static int do_swap_page(struct mm_struct *mm, str= uct vm_area_struct *vma, =20 /* No need to invalidate - it was non-present before */ update_mmu_cache(vma, address, pte); @@ -73677,7 +75887,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c * We enter with non-exclusive mmap_sem (to exclude vma changes, * but allow concurrent faults), and pte mapped but not yet locked. * We return with mmap_sem still held, but pte unmapped and unlocked. -@@ -2674,27 +2864,23 @@ static int do_anonymous_page(struct mm_s +@@ -2674,27 +2864,23 @@ static int do_anonymous_page(struct mm_struct *m= m, struct vm_area_struct *vma, unsigned long address, pte_t *page_table, pmd_t *pmd, unsigned int flags) { @@ -73710,7 +75920,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c if (unlikely(anon_vma_prepare(vma))) goto oom; page =3D alloc_zeroed_user_highpage_movable(vma, address); -@@ -2713,6 +2899,11 @@ static int do_anonymous_page(struct mm_s +@@ -2713,6 +2899,11 @@ static int do_anonymous_page(struct mm_struct *mm= , struct vm_area_struct *vma, if (!pte_none(*page_table)) goto release; =20 @@ -73735,7 +75945,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c unlock: pte_unmap_unlock(page_table, ptl); return 0; -@@ -2862,6 +3059,12 @@ static int __do_fault(struct mm_struct * +@@ -2862,6 +3059,12 @@ static int __do_fault(struct mm_struct *mm, struc= t vm_area_struct *vma, */ /* Only go through if we didn't race with anybody else... */ if (likely(pte_same(*page_table, orig_pte))) { @@ -73748,7 +75958,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c flush_icache_page(vma, page); entry =3D mk_pte(page, vma->vm_page_prot); if (flags & FAULT_FLAG_WRITE) -@@ -2881,6 +3084,14 @@ static int __do_fault(struct mm_struct * +@@ -2881,6 +3084,14 @@ static int __do_fault(struct mm_struct *mm, struc= t vm_area_struct *vma, =20 /* no need to invalidate: a not-present page won't be cached */ update_mmu_cache(vma, address, entry); @@ -73763,7 +75973,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c } else { if (charged) mem_cgroup_uncharge_page(page); -@@ -3028,6 +3239,12 @@ static inline int handle_pte_fault(struc +@@ -3028,6 +3239,12 @@ static inline int handle_pte_fault(struct mm_stru= ct *mm, if (flags & FAULT_FLAG_WRITE) flush_tlb_page(vma, address); } @@ -73776,7 +75986,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c unlock: pte_unmap_unlock(pte, ptl); return 0; -@@ -3044,6 +3261,10 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3044,6 +3261,10 @@ int handle_mm_fault(struct mm_struct *mm, struct = vm_area_struct *vma, pmd_t *pmd; pte_t *pte; =20 @@ -73787,7 +75997,7 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.6.= 32.49/mm/memory.c __set_current_state(TASK_RUNNING); =20 count_vm_event(PGFAULT); -@@ -3051,6 +3272,34 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3051,6 +3272,34 @@ int handle_mm_fault(struct mm_struct *mm, struct = vm_area_struct *vma, if (unlikely(is_vm_hugetlb_page(vma))) return hugetlb_fault(mm, vma, address, flags); =20 @@ -73831,40 +76041,11 @@ diff -urNp linux-2.6.32.49/mm/memory.c linux-2.= 6.32.49/mm/memory.c /* * Make sure the vDSO gets into every core dump. * Dumping its contents makes post-mortem fully interpretable later -diff -urNp linux-2.6.32.49/mm/memory-failure.c linux-2.6.32.49/mm/memory= -failure.c ---- linux-2.6.32.49/mm/memory-failure.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/mm/memory-failure.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -46,7 +46,7 @@ int sysctl_memory_failure_early_kill __r -=20 - int sysctl_memory_failure_recovery __read_mostly =3D 1; -=20 --atomic_long_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INIT(0); -+atomic_long_unchecked_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INI= T(0); -=20 - /* - * Send all the processes who have the page mapped an ``action optional= '' -@@ -64,7 +64,7 @@ static int kill_proc_ao(struct task_stru - si.si_signo =3D SIGBUS; - si.si_errno =3D 0; - si.si_code =3D BUS_MCEERR_AO; -- si.si_addr =3D (void *)addr; -+ si.si_addr =3D (void __user *)addr; - #ifdef __ARCH_SI_TRAPNO - si.si_trapno =3D trapno; - #endif -@@ -745,7 +745,7 @@ int __memory_failure(unsigned long pfn,=20 - return 0; - } -=20 -- atomic_long_add(1, &mce_bad_pages); -+ atomic_long_add_unchecked(1, &mce_bad_pages); -=20 - /* - * We need/can do nothing about count=3D0 pages. -diff -urNp linux-2.6.32.49/mm/mempolicy.c linux-2.6.32.49/mm/mempolicy.c ---- linux-2.6.32.49/mm/mempolicy.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/mempolicy.c 2011-11-15 19:59:43.000000000 -0500 -@@ -573,6 +573,10 @@ static int mbind_range(struct vm_area_st +diff --git a/mm/mempolicy.c b/mm/mempolicy.c +index 3c6e3e2..ad9871c 100644 +--- a/mm/mempolicy.c ++++ b/mm/mempolicy.c +@@ -573,6 +573,10 @@ static int mbind_range(struct vm_area_struct *vma, = unsigned long start, struct vm_area_struct *next; int err; =20 @@ -73875,7 +76056,7 @@ diff -urNp linux-2.6.32.49/mm/mempolicy.c linux-2= .6.32.49/mm/mempolicy.c err =3D 0; for (; vma && vma->vm_start < end; vma =3D next) { next =3D vma->vm_next; -@@ -584,6 +588,16 @@ static int mbind_range(struct vm_area_st +@@ -584,6 +588,16 @@ static int mbind_range(struct vm_area_struct *vma, = unsigned long start, err =3D policy_vma(vma, new); if (err) break; @@ -73892,7 +76073,7 @@ diff -urNp linux-2.6.32.49/mm/mempolicy.c linux-2= .6.32.49/mm/mempolicy.c } return err; } -@@ -1002,6 +1016,17 @@ static long do_mbind(unsigned long start +@@ -1002,6 +1016,17 @@ static long do_mbind(unsigned long start, unsigne= d long len, =20 if (end < start) return -EINVAL; @@ -73910,7 +76091,7 @@ diff -urNp linux-2.6.32.49/mm/mempolicy.c linux-2= .6.32.49/mm/mempolicy.c if (end =3D=3D start) return 0; =20 -@@ -1207,6 +1232,14 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pi +@@ -1207,6 +1232,14 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pid, unsign= ed long, maxnode, if (!mm) return -EINVAL; =20 @@ -73925,7 +76106,7 @@ diff -urNp linux-2.6.32.49/mm/mempolicy.c linux-2= .6.32.49/mm/mempolicy.c /* * Check if this process has the right to modify the specified * process. The right exists if the process has administrative -@@ -1216,8 +1249,7 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pi +@@ -1216,8 +1249,7 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pid, unsigne= d long, maxnode, rcu_read_lock(); tcred =3D __task_cred(task); if (cred->euid !=3D tcred->suid && cred->euid !=3D tcred->uid && @@ -73935,7 +76116,7 @@ diff -urNp linux-2.6.32.49/mm/mempolicy.c linux-2= .6.32.49/mm/mempolicy.c rcu_read_unlock(); err =3D -EPERM; goto out; -@@ -2396,7 +2428,7 @@ int show_numa_map(struct seq_file *m, vo +@@ -2396,7 +2428,7 @@ int show_numa_map(struct seq_file *m, void *v) =20 if (file) { seq_printf(m, " file=3D"); @@ -73944,10 +76125,11 @@ diff -urNp linux-2.6.32.49/mm/mempolicy.c linux= -2.6.32.49/mm/mempolicy.c } else if (vma->vm_start <=3D mm->brk && vma->vm_end >=3D mm->start_br= k) { seq_printf(m, " heap"); } else if (vma->vm_start <=3D mm->start_stack && -diff -urNp linux-2.6.32.49/mm/migrate.c linux-2.6.32.49/mm/migrate.c ---- linux-2.6.32.49/mm/migrate.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/migrate.c 2011-11-15 19:59:43.000000000 -0500 -@@ -916,6 +916,8 @@ static int do_pages_move(struct mm_struc +diff --git a/mm/migrate.c b/mm/migrate.c +index aaca868..2ebecdc 100644 +--- a/mm/migrate.c ++++ b/mm/migrate.c +@@ -916,6 +916,8 @@ static int do_pages_move(struct mm_struct *mm, struc= t task_struct *task, unsigned long chunk_start; int err; =20 @@ -73956,7 +76138,7 @@ diff -urNp linux-2.6.32.49/mm/migrate.c linux-2.6= .32.49/mm/migrate.c task_nodes =3D cpuset_mems_allowed(task); =20 err =3D -ENOMEM; -@@ -1106,6 +1108,14 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid,=20 +@@ -1106,6 +1108,14 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, unsigned = long, nr_pages, if (!mm) return -EINVAL; =20 @@ -73971,7 +76153,7 @@ diff -urNp linux-2.6.32.49/mm/migrate.c linux-2.6= .32.49/mm/migrate.c /* * Check if this process has the right to modify the specified * process. The right exists if the process has administrative -@@ -1115,8 +1125,7 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid,=20 +@@ -1115,8 +1125,7 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, unsigned l= ong, nr_pages, rcu_read_lock(); tcred =3D __task_cred(task); if (cred->euid !=3D tcred->suid && cred->euid !=3D tcred->uid && @@ -73981,9 +76163,10 @@ diff -urNp linux-2.6.32.49/mm/migrate.c linux-2.= 6.32.49/mm/migrate.c rcu_read_unlock(); err =3D -EPERM; goto out; -diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.32.49/mm/mlock.c ---- linux-2.6.32.49/mm/mlock.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/mlock.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/mlock.c b/mm/mlock.c +index 2d846cf..98134d2 100644 +--- a/mm/mlock.c ++++ b/mm/mlock.c @@ -13,6 +13,7 @@ #include #include @@ -74006,7 +76189,7 @@ diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.3= 2.49/mm/mlock.c /** * __mlock_vma_pages_range() - mlock a range of pages in the vma. * @vma: target vma -@@ -177,12 +171,6 @@ static long __mlock_vma_pages_range(stru +@@ -177,12 +171,6 @@ static long __mlock_vma_pages_range(struct vm_area_= struct *vma, if (vma->vm_flags & VM_WRITE) gup_flags |=3D FOLL_WRITE; =20 @@ -74019,7 +76202,7 @@ diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.3= 2.49/mm/mlock.c while (nr_pages > 0) { int i; =20 -@@ -440,7 +428,7 @@ static int do_mlock(unsigned long start, +@@ -440,7 +428,7 @@ static int do_mlock(unsigned long start, size_t len,= int on) { unsigned long nstart, end, tmp; struct vm_area_struct * vma, * prev; @@ -74028,7 +76211,7 @@ diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.3= 2.49/mm/mlock.c =20 len =3D PAGE_ALIGN(len); end =3D start + len; -@@ -448,6 +436,9 @@ static int do_mlock(unsigned long start, +@@ -448,6 +436,9 @@ static int do_mlock(unsigned long start, size_t len,= int on) return -EINVAL; if (end =3D=3D start) return 0; @@ -74038,7 +76221,7 @@ diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.3= 2.49/mm/mlock.c vma =3D find_vma_prev(current->mm, start, &prev); if (!vma || vma->vm_start > start) return -ENOMEM; -@@ -458,6 +449,11 @@ static int do_mlock(unsigned long start, +@@ -458,6 +449,11 @@ static int do_mlock(unsigned long start, size_t len= , int on) for (nstart =3D start ; ; ) { unsigned int newflags; =20 @@ -74050,7 +76233,7 @@ diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.3= 2.49/mm/mlock.c /* Here we know that vma->vm_start <=3D nstart < vma->vm_end. */ =20 newflags =3D vma->vm_flags | VM_LOCKED; -@@ -507,6 +503,7 @@ SYSCALL_DEFINE2(mlock, unsigned long, st +@@ -507,6 +503,7 @@ SYSCALL_DEFINE2(mlock, unsigned long, start, size_t,= len) lock_limit >>=3D PAGE_SHIFT; =20 /* check against resource limits */ @@ -74058,7 +76241,7 @@ diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.3= 2.49/mm/mlock.c if ((locked <=3D lock_limit) || capable(CAP_IPC_LOCK)) error =3D do_mlock(start, len, 1); up_write(¤t->mm->mmap_sem); -@@ -528,17 +525,23 @@ SYSCALL_DEFINE2(munlock, unsigned long,=20 +@@ -528,17 +525,23 @@ SYSCALL_DEFINE2(munlock, unsigned long, start, siz= e_t, len) static int do_mlockall(int flags) { struct vm_area_struct * vma, * prev =3D NULL; @@ -74094,9 +76277,10 @@ diff -urNp linux-2.6.32.49/mm/mlock.c linux-2.6.= 32.49/mm/mlock.c if (!(flags & MCL_CURRENT) || (current->mm->total_vm <=3D lock_limit) = || capable(CAP_IPC_LOCK)) ret =3D do_mlockall(flags); -diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32.49/mm/mmap.c ---- linux-2.6.32.49/mm/mmap.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/mmap.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/mmap.c b/mm/mmap.c +index 4b80cbf..c5ce1df 100644 +--- a/mm/mmap.c ++++ b/mm/mmap.c @@ -45,6 +45,16 @@ #define arch_rebalance_pgtables(addr, len) (addr) #endif @@ -74114,7 +76298,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c static void unmap_region(struct mm_struct *mm, struct vm_area_struct *vma, struct vm_area_struct *prev, unsigned long start, unsigned long end); -@@ -70,22 +80,32 @@ static void unmap_region(struct mm_struc +@@ -70,22 +80,32 @@ static void unmap_region(struct mm_struct *mm, * x: (no) no x: (no) yes x: (no) yes x: (yes) yes * */ @@ -74149,7 +76333,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c struct percpu_counter vm_committed_as; =20 /* -@@ -231,6 +251,7 @@ static struct vm_area_struct *remove_vma +@@ -231,6 +251,7 @@ static struct vm_area_struct *remove_vma(struct vm_a= rea_struct *vma) struct vm_area_struct *next =3D vma->vm_next; =20 might_sleep(); @@ -74191,7 +76375,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (is_mergeable_vma(vma, file, vm_flags) && is_mergeable_anon_vma(anon_vma, vma->anon_vma)) { pgoff_t vm_pglen; -@@ -765,12 +799,19 @@ can_vma_merge_after(struct vm_area_struc +@@ -765,12 +799,19 @@ can_vma_merge_after(struct vm_area_struct *vma, un= signed long vm_flags, struct vm_area_struct *vma_merge(struct mm_struct *mm, struct vm_area_struct *prev, unsigned long addr, unsigned long end, unsigned long vm_flags, @@ -74212,7 +76396,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * We later require that vma->vm_flags =3D=3D vm_flags, * so this tests vma->vm_flags & VM_SPECIAL, too. -@@ -786,6 +827,15 @@ struct vm_area_struct *vma_merge(struct=20 +@@ -786,6 +827,15 @@ struct vm_area_struct *vma_merge(struct mm_struct *= mm, if (next && next->vm_end =3D=3D end) /* cases 6, 7, 8 */ next =3D next->vm_next; =20 @@ -74228,7 +76412,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * Can it merge with the predecessor? */ -@@ -805,9 +855,24 @@ struct vm_area_struct *vma_merge(struct=20 +@@ -805,9 +855,24 @@ struct vm_area_struct *vma_merge(struct mm_struct *= mm, /* cases 1, 6 */ vma_adjust(prev, prev->vm_start, next->vm_end, prev->vm_pgoff, NULL); @@ -74254,7 +76438,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return prev; } =20 -@@ -818,12 +883,27 @@ struct vm_area_struct *vma_merge(struct=20 +@@ -818,12 +883,27 @@ struct vm_area_struct *vma_merge(struct mm_struct = *mm, mpol_equal(policy, vma_policy(next)) && can_vma_merge_before(next, vm_flags, anon_vma, file, pgoff+pglen)) { @@ -74300,7 +76484,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c mm->stack_vm +=3D pages; if (flags & (VM_RESERVED|VM_IO)) mm->reserved_vm +=3D pages; -@@ -932,7 +1009,7 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -932,7 +1009,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsi= gned long addr, * (the exception is when the underlying filesystem is noexec * mounted, in which case we dont add PROT_EXEC.) */ @@ -74309,7 +76493,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (!(file && (file->f_path.mnt->mnt_flags & MNT_NOEXEC))) prot |=3D PROT_EXEC; =20 -@@ -958,7 +1035,7 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -958,7 +1035,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsi= gned long addr, /* Obtain the address to map to. we verify (or select) it and ensure * that it represents a valid section of the address space. */ @@ -74318,7 +76502,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (addr & ~PAGE_MASK) return addr; =20 -@@ -969,6 +1046,36 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -969,6 +1046,36 @@ unsigned long do_mmap_pgoff(struct file *file, uns= igned long addr, vm_flags =3D calc_vm_prot_bits(prot) | calc_vm_flag_bits(flags) | mm->def_flags | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC; =20 @@ -74355,7 +76539,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (flags & MAP_LOCKED) if (!can_do_mlock()) return -EPERM; -@@ -980,6 +1087,7 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -980,6 +1087,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsi= gned long addr, locked +=3D mm->locked_vm; lock_limit =3D current->signal->rlim[RLIMIT_MEMLOCK].rlim_cur; lock_limit >>=3D PAGE_SHIFT; @@ -74363,7 +76547,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (locked > lock_limit && !capable(CAP_IPC_LOCK)) return -EAGAIN; } -@@ -1053,6 +1161,9 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -1053,6 +1161,9 @@ unsigned long do_mmap_pgoff(struct file *file, uns= igned long addr, if (error) return error; =20 @@ -74386,7 +76570,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return 0; =20 /* The backer wishes to know when pages are first written to? */ -@@ -1117,14 +1228,24 @@ unsigned long mmap_region(struct file *f +@@ -1117,14 +1228,24 @@ unsigned long mmap_region(struct file *file, uns= igned long addr, unsigned long charged =3D 0; struct inode *inode =3D file ? file->f_path.dentry->d_inode : NULL; =20 @@ -74528,7 +76712,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* Get an address range which is currently unmapped. * For shmat() with addr=3D0. * -@@ -1281,18 +1475,23 @@ arch_get_unmapped_area(struct file *filp +@@ -1281,18 +1475,23 @@ arch_get_unmapped_area(struct file *filp, unsign= ed long addr, if (flags & MAP_FIXED) return addr; =20 @@ -74611,7 +76795,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c mm->free_area_cache =3D addr; mm->cached_hole_size =3D ~0UL; } -@@ -1348,7 +1553,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1348,7 +1553,7 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, { struct vm_area_struct *vma; struct mm_struct *mm =3D current->mm; @@ -74620,7 +76804,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c =20 /* requested length too big for entire address space */ if (len > TASK_SIZE) -@@ -1357,13 +1562,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1357,13 +1562,18 @@ arch_get_unmapped_area_topdown(struct file *filp= , const unsigned long addr0, if (flags & MAP_FIXED) return addr; =20 @@ -74643,7 +76827,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c } =20 /* check if free_area_cache is useful for us */ -@@ -1378,7 +1588,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1378,7 +1588,7 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, /* make sure it can fit in the remaining address space */ if (addr > len) { vma =3D find_vma(mm, addr-len); @@ -74652,7 +76836,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -1395,7 +1605,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1395,7 +1605,7 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, * return with success: */ vma =3D find_vma(mm, addr); @@ -74661,7 +76845,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); =20 -@@ -1404,8 +1614,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1404,8 +1614,8 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -74709,7 +76893,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * Is this a new hole at the highest possible address? */ -@@ -1436,8 +1660,10 @@ void arch_unmap_area_topdown(struct mm_s +@@ -1436,8 +1660,10 @@ void arch_unmap_area_topdown(struct mm_struct *mm= , unsigned long addr) mm->free_area_cache =3D addr; =20 /* dont allow allocations above current base */ @@ -74749,7 +76933,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * Verify that the stack growth is acceptable and * update accounting. This is shared with both the -@@ -1561,6 +1808,7 @@ static int acct_stack_growth(struct vm_a +@@ -1561,6 +1808,7 @@ static int acct_stack_growth(struct vm_area_struct= *vma, unsigned long size, uns return -ENOMEM; =20 /* Stack limit test */ @@ -74757,7 +76941,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (size > rlim[RLIMIT_STACK].rlim_cur) return -ENOMEM; =20 -@@ -1570,6 +1818,7 @@ static int acct_stack_growth(struct vm_a +@@ -1570,6 +1818,7 @@ static int acct_stack_growth(struct vm_area_struct= *vma, unsigned long size, uns unsigned long limit; locked =3D mm->locked_vm + grow; limit =3D rlim[RLIMIT_MEMLOCK].rlim_cur >> PAGE_SHIFT; @@ -74765,7 +76949,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (locked > limit && !capable(CAP_IPC_LOCK)) return -ENOMEM; } -@@ -1600,37 +1849,48 @@ static int acct_stack_growth(struct vm_a +@@ -1600,37 +1849,48 @@ static int acct_stack_growth(struct vm_area_stru= ct *vma, unsigned long size, uns * PA-RISC uses this for its stack; IA64 for its Register Backing Store= . * vma is the last one with address > vma->vm_end. Have to extend vma. */ @@ -74823,7 +77007,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c unsigned long size, grow; =20 size =3D address - vma->vm_start; -@@ -1643,6 +1903,8 @@ int expand_upwards(struct vm_area_struct +@@ -1643,6 +1903,8 @@ int expand_upwards(struct vm_area_struct *vma, uns= igned long address) vma->vm_end =3D address; } } @@ -74832,7 +77016,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c anon_vma_unlock(vma); return error; } -@@ -1655,6 +1917,8 @@ static int expand_downwards(struct vm_ar +@@ -1655,6 +1917,8 @@ static int expand_downwards(struct vm_area_struct = *vma, unsigned long address) { int error; @@ -74841,7 +77025,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c =20 /* * We must make sure the anon_vma is allocated -@@ -1668,6 +1932,15 @@ static int expand_downwards(struct vm_ar +@@ -1668,6 +1932,15 @@ static int expand_downwards(struct vm_area_struct= *vma, if (error) return error; =20 @@ -74857,7 +77041,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c anon_vma_lock(vma); =20 /* -@@ -1677,9 +1950,17 @@ static int expand_downwards(struct vm_ar +@@ -1677,9 +1950,17 @@ static int expand_downwards(struct vm_area_struct= *vma, */ =20 /* Somebody else might have raced and expanded it already */ @@ -74876,7 +77060,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c size =3D vma->vm_end - address; grow =3D (vma->vm_start - address) >> PAGE_SHIFT; =20 -@@ -1689,10 +1970,22 @@ static int expand_downwards(struct vm_ar +@@ -1689,10 +1970,22 @@ static int expand_downwards(struct vm_area_struc= t *vma, if (!error) { vma->vm_start =3D address; vma->vm_pgoff -=3D grow; @@ -74899,7 +77083,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return error; } =20 -@@ -1768,6 +2061,13 @@ static void remove_vma_list(struct mm_st +@@ -1768,6 +2061,13 @@ static void remove_vma_list(struct mm_struct *mm,= struct vm_area_struct *vma) do { long nrpages =3D vma_pages(vma); =20 @@ -74913,7 +77097,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c mm->total_vm -=3D nrpages; vm_stat_account(mm, vma->vm_flags, vma->vm_file, -nrpages); vma =3D remove_vma(vma); -@@ -1813,6 +2113,16 @@ detach_vmas_to_be_unmapped(struct mm_str +@@ -1813,6 +2113,16 @@ detach_vmas_to_be_unmapped(struct mm_struct *mm, = struct vm_area_struct *vma, insertion_point =3D (prev ? &prev->vm_next : &mm->mmap); vma->vm_prev =3D NULL; do { @@ -74930,7 +77114,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c rb_erase(&vma->vm_rb, &mm->mm_rb); mm->map_count--; tail_vma =3D vma; -@@ -1840,10 +2150,25 @@ int split_vma(struct mm_struct * mm, str +@@ -1840,10 +2150,25 @@ int split_vma(struct mm_struct * mm, struct vm_a= rea_struct * vma, struct mempolicy *pol; struct vm_area_struct *new; =20 @@ -74956,7 +77140,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (mm->map_count >=3D sysctl_max_map_count) return -ENOMEM; =20 -@@ -1851,6 +2176,16 @@ int split_vma(struct mm_struct * mm, str +@@ -1851,6 +2176,16 @@ int split_vma(struct mm_struct * mm, struct vm_ar= ea_struct * vma, if (!new) return -ENOMEM; =20 @@ -74973,7 +77157,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* most fields are the same, copy all, and then fixup */ *new =3D *vma; =20 -@@ -1861,8 +2196,29 @@ int split_vma(struct mm_struct * mm, str +@@ -1861,8 +2196,29 @@ int split_vma(struct mm_struct * mm, struct vm_ar= ea_struct * vma, new->vm_pgoff +=3D ((addr - vma->vm_start) >> PAGE_SHIFT); } =20 @@ -75003,7 +77187,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c kmem_cache_free(vm_area_cachep, new); return PTR_ERR(pol); } -@@ -1883,6 +2239,28 @@ int split_vma(struct mm_struct * mm, str +@@ -1883,6 +2239,28 @@ int split_vma(struct mm_struct * mm, struct vm_ar= ea_struct * vma, else vma_adjust(vma, vma->vm_start, addr, vma->vm_pgoff, new); =20 @@ -75032,7 +77216,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return 0; } =20 -@@ -1891,11 +2269,30 @@ int split_vma(struct mm_struct * mm, str +@@ -1891,11 +2269,30 @@ int split_vma(struct mm_struct * mm, struct vm_a= rea_struct * vma, * work. This now handles partial unmappings. * Jeremy Fitzhardinge */ @@ -75063,7 +77247,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if ((start & ~PAGE_MASK) || start > TASK_SIZE || len > TASK_SIZE-start= ) return -EINVAL; =20 -@@ -1959,6 +2356,8 @@ int do_munmap(struct mm_struct *mm, unsi +@@ -1959,6 +2356,8 @@ int do_munmap(struct mm_struct *mm, unsigned long = start, size_t len) /* Fix up all other VM information */ remove_vma_list(mm, vma); =20 @@ -75072,7 +77256,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return 0; } =20 -@@ -1971,22 +2370,18 @@ SYSCALL_DEFINE2(munmap, unsigned long, a +@@ -1971,22 +2370,18 @@ SYSCALL_DEFINE2(munmap, unsigned long, addr, siz= e_t, len) =20 profile_munmap(addr); =20 @@ -75101,7 +77285,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * this is really a simplified "do_mmap". it only handles * anonymous maps. eventually we may be able to do some -@@ -2000,6 +2395,7 @@ unsigned long do_brk(unsigned long addr, +@@ -2000,6 +2395,7 @@ unsigned long do_brk(unsigned long addr, unsigned = long len) struct rb_node ** rb_link, * rb_parent; pgoff_t pgoff =3D addr >> PAGE_SHIFT; int error; @@ -75109,7 +77293,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c =20 len =3D PAGE_ALIGN(len); if (!len) -@@ -2011,16 +2407,30 @@ unsigned long do_brk(unsigned long addr, +@@ -2011,16 +2407,30 @@ unsigned long do_brk(unsigned long addr, unsigne= d long len) =20 flags =3D VM_DATA_DEFAULT_FLAGS | VM_ACCOUNT | mm->def_flags; =20 @@ -75141,7 +77325,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c locked +=3D mm->locked_vm; lock_limit =3D current->signal->rlim[RLIMIT_MEMLOCK].rlim_cur; lock_limit >>=3D PAGE_SHIFT; -@@ -2037,22 +2447,22 @@ unsigned long do_brk(unsigned long addr, +@@ -2037,22 +2447,22 @@ unsigned long do_brk(unsigned long addr, unsigne= d long len) /* * Clear old maps. this also does some error checking for us */ @@ -75168,7 +77352,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return -ENOMEM; =20 /* Can we just expand an old private anonymous mapping? */ -@@ -2066,7 +2476,7 @@ unsigned long do_brk(unsigned long addr, +@@ -2066,7 +2476,7 @@ unsigned long do_brk(unsigned long addr, unsigned = long len) */ vma =3D kmem_cache_zalloc(vm_area_cachep, GFP_KERNEL); if (!vma) { @@ -75177,7 +77361,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return -ENOMEM; } =20 -@@ -2078,11 +2488,12 @@ unsigned long do_brk(unsigned long addr, +@@ -2078,11 +2488,12 @@ unsigned long do_brk(unsigned long addr, unsigne= d long len) vma->vm_page_prot =3D vm_get_page_prot(flags); vma_link(mm, vma, prev, rb_link, rb_parent); out: @@ -75204,7 +77388,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c =20 BUG_ON(mm->nr_ptes > (FIRST_USER_ADDRESS+PMD_SIZE-1)>>PMD_SHIFT); } -@@ -2144,6 +2557,10 @@ int insert_vm_struct(struct mm_struct *=20 +@@ -2144,6 +2557,10 @@ int insert_vm_struct(struct mm_struct * mm, struc= t vm_area_struct * vma) struct vm_area_struct * __vma, * prev; struct rb_node ** rb_link, * rb_parent; =20 @@ -75215,7 +77399,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * The vm_pgoff of a purely anonymous vma should be irrelevant * until its first write fault, when page's anon_vma and index -@@ -2166,7 +2583,22 @@ int insert_vm_struct(struct mm_struct *=20 +@@ -2166,7 +2583,22 @@ int insert_vm_struct(struct mm_struct * mm, struc= t vm_area_struct * vma) if ((vma->vm_flags & VM_ACCOUNT) && security_vm_enough_memory_mm(mm, vma_pages(vma))) return -ENOMEM; @@ -75238,7 +77422,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c return 0; } =20 -@@ -2184,6 +2616,8 @@ struct vm_area_struct *copy_vma(struct v +@@ -2184,6 +2616,8 @@ struct vm_area_struct *copy_vma(struct vm_area_str= uct **vmap, struct rb_node **rb_link, *rb_parent; struct mempolicy *pol; =20 @@ -75247,7 +77431,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * If anonymous vma has not yet been faulted, update new pgoff * to match new location, to increase its chance of merging. -@@ -2227,6 +2661,35 @@ struct vm_area_struct *copy_vma(struct v +@@ -2227,6 +2661,35 @@ struct vm_area_struct *copy_vma(struct vm_area_st= ruct **vmap, return new_vma; } =20 @@ -75283,7 +77467,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c /* * Return true if the calling process may expand its vm space by the pa= ssed * number of pages -@@ -2237,7 +2700,7 @@ int may_expand_vm(struct mm_struct *mm,=20 +@@ -2237,7 +2700,7 @@ int may_expand_vm(struct mm_struct *mm, unsigned l= ong npages) unsigned long lim; =20 lim =3D current->signal->rlim[RLIMIT_AS].rlim_cur >> PAGE_SHIFT; @@ -75292,7 +77476,7 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.32= .49/mm/mmap.c if (cur + npages > lim) return 0; return 1; -@@ -2307,6 +2770,22 @@ int install_special_mapping(struct mm_st +@@ -2307,6 +2770,22 @@ int install_special_mapping(struct mm_struct *mm, vma->vm_start =3D addr; vma->vm_end =3D addr + len; =20 @@ -75315,9 +77499,10 @@ diff -urNp linux-2.6.32.49/mm/mmap.c linux-2.6.3= 2.49/mm/mmap.c vma->vm_flags =3D vm_flags | mm->def_flags | VM_DONTEXPAND; vma->vm_page_prot =3D vm_get_page_prot(vma->vm_flags); =20 -diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.6.32.49/mm/mprotect.c ---- linux-2.6.32.49/mm/mprotect.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/mprotect.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/mprotect.c b/mm/mprotect.c +index 1737c7e..c7faeb4 100644 +--- a/mm/mprotect.c ++++ b/mm/mprotect.c @@ -24,10 +24,16 @@ #include #include @@ -75335,7 +77520,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c =20 #ifndef pgprot_modify static inline pgprot_t pgprot_modify(pgprot_t oldprot, pgprot_t newprot= ) -@@ -132,6 +138,48 @@ static void change_protection(struct vm_ +@@ -132,6 +138,48 @@ static void change_protection(struct vm_area_struct= *vma, flush_tlb_range(vma, start, end); } =20 @@ -75384,7 +77569,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c int mprotect_fixup(struct vm_area_struct *vma, struct vm_area_struct **ppre= v, unsigned long start, unsigned long end, unsigned long newflags) -@@ -144,11 +192,29 @@ mprotect_fixup(struct vm_area_struct *vm +@@ -144,11 +192,29 @@ mprotect_fixup(struct vm_area_struct *vma, struct = vm_area_struct **pprev, int error; int dirty_accountable =3D 0; =20 @@ -75414,7 +77599,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c /* * If we make a private mapping writable we increase our commit; * but (without finer accounting) cannot reduce our commit if we -@@ -165,6 +231,38 @@ mprotect_fixup(struct vm_area_struct *vm +@@ -165,6 +231,38 @@ mprotect_fixup(struct vm_area_struct *vma, struct v= m_area_struct **pprev, } } =20 @@ -75476,7 +77661,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c =20 if (vma_wants_writenotify(vma)) { vma->vm_page_prot =3D vm_get_page_prot(newflags & ~VM_SHARED); -@@ -239,6 +349,17 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -239,6 +349,17 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, siz= e_t, len, end =3D start + len; if (end <=3D start) return -ENOMEM; @@ -75494,7 +77679,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c if (!arch_validate_prot(prot)) return -EINVAL; =20 -@@ -246,7 +367,7 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -246,7 +367,7 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, size= _t, len, /* * Does the application expect PROT_READ to imply PROT_EXEC: */ @@ -75503,7 +77688,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c prot |=3D PROT_EXEC; =20 vm_flags =3D calc_vm_prot_bits(prot); -@@ -278,6 +399,11 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -278,6 +399,11 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, siz= e_t, len, if (start > vma->vm_start) prev =3D vma; =20 @@ -75515,7 +77700,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c for (nstart =3D start ; ; ) { unsigned long newflags; =20 -@@ -287,6 +413,14 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -287,6 +413,14 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, siz= e_t, len, =20 /* newflags >> 4 shift VM_MAY% in place of VM_% */ if ((newflags & ~(newflags >> 4)) & (VM_READ | VM_WRITE | VM_EXEC)) { @@ -75530,7 +77715,7 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-2.= 6.32.49/mm/mprotect.c error =3D -EACCES; goto out; } -@@ -301,6 +435,9 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -301,6 +435,9 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, size= _t, len, error =3D mprotect_fixup(vma, &prev, nstart, tmp, newflags); if (error) goto out; @@ -75540,10 +77725,11 @@ diff -urNp linux-2.6.32.49/mm/mprotect.c linux-= 2.6.32.49/mm/mprotect.c nstart =3D tmp; =20 if (nstart < prev->vm_end) -diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.6.32.49/mm/mremap.c ---- linux-2.6.32.49/mm/mremap.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/mremap.c 2011-11-15 19:59:43.000000000 -0500 -@@ -112,6 +112,12 @@ static void move_ptes(struct vm_area_str +diff --git a/mm/mremap.c b/mm/mremap.c +index 3e98d79..1706cec 100644 +--- a/mm/mremap.c ++++ b/mm/mremap.c +@@ -112,6 +112,12 @@ static void move_ptes(struct vm_area_struct *vma, p= md_t *old_pmd, continue; pte =3D ptep_clear_flush(vma, old_addr, old_pte); pte =3D move_pte(pte, new_vma->vm_page_prot, old_addr, new_addr); @@ -75556,7 +77742,7 @@ diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.6.= 32.49/mm/mremap.c set_pte_at(mm, new_addr, new_pte, pte); } =20 -@@ -271,6 +277,11 @@ static struct vm_area_struct *vma_to_res +@@ -271,6 +277,11 @@ static struct vm_area_struct *vma_to_resize(unsigne= d long addr, if (is_vm_hugetlb_page(vma)) goto Einval; =20 @@ -75568,7 +77754,7 @@ diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.6.= 32.49/mm/mremap.c /* We can't remap across vm area boundaries */ if (old_len > vma->vm_end - addr) goto Efault; -@@ -327,20 +338,25 @@ static unsigned long mremap_to(unsigned=20 +@@ -327,20 +338,25 @@ static unsigned long mremap_to(unsigned long addr, unsigned long ret =3D -EINVAL; unsigned long charged =3D 0; unsigned long map_flags; @@ -75599,7 +77785,7 @@ diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.6.= 32.49/mm/mremap.c goto out; =20 ret =3D security_file_mmap(NULL, 0, 0, 0, new_addr, 1); -@@ -412,6 +428,7 @@ unsigned long do_mremap(unsigned long ad +@@ -412,6 +428,7 @@ unsigned long do_mremap(unsigned long addr, struct vm_area_struct *vma; unsigned long ret =3D -EINVAL; unsigned long charged =3D 0; @@ -75607,7 +77793,7 @@ diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.6.= 32.49/mm/mremap.c =20 if (flags & ~(MREMAP_FIXED | MREMAP_MAYMOVE)) goto out; -@@ -430,6 +447,17 @@ unsigned long do_mremap(unsigned long ad +@@ -430,6 +447,17 @@ unsigned long do_mremap(unsigned long addr, if (!new_len) goto out; =20 @@ -75625,7 +77811,7 @@ diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.6.= 32.49/mm/mremap.c if (flags & MREMAP_FIXED) { if (flags & MREMAP_MAYMOVE) ret =3D mremap_to(addr, old_len, new_addr, new_len); -@@ -476,6 +504,7 @@ unsigned long do_mremap(unsigned long ad +@@ -476,6 +504,7 @@ unsigned long do_mremap(unsigned long addr, addr + new_len); } ret =3D addr; @@ -75633,7 +77819,7 @@ diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.6.= 32.49/mm/mremap.c goto out; } } -@@ -502,7 +531,13 @@ unsigned long do_mremap(unsigned long ad +@@ -502,7 +531,13 @@ unsigned long do_mremap(unsigned long addr, ret =3D security_file_mmap(NULL, 0, 0, 0, new_addr, 1); if (ret) goto out; @@ -75647,10 +77833,11 @@ diff -urNp linux-2.6.32.49/mm/mremap.c linux-2.= 6.32.49/mm/mremap.c } out: if (ret & ~PAGE_MASK) -diff -urNp linux-2.6.32.49/mm/nommu.c linux-2.6.32.49/mm/nommu.c ---- linux-2.6.32.49/mm/nommu.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/nommu.c 2011-11-15 19:59:43.000000000 -0500 -@@ -67,7 +67,6 @@ int sysctl_overcommit_memory =3D OVERCOMMI +diff --git a/mm/nommu.c b/mm/nommu.c +index 406e8d4..53970d3 100644 +--- a/mm/nommu.c ++++ b/mm/nommu.c +@@ -67,7 +67,6 @@ int sysctl_overcommit_memory =3D OVERCOMMIT_GUESS; /* = heuristic overcommit */ int sysctl_overcommit_ratio =3D 50; /* default is 50% */ int sysctl_max_map_count =3D DEFAULT_MAX_MAP_COUNT; int sysctl_nr_trim_pages =3D CONFIG_NOMMU_INITIAL_TRIM_EXCESS; @@ -75658,7 +77845,7 @@ diff -urNp linux-2.6.32.49/mm/nommu.c linux-2.6.3= 2.49/mm/nommu.c =20 atomic_long_t mmap_pages_allocated; =20 -@@ -761,15 +760,6 @@ struct vm_area_struct *find_vma(struct m +@@ -761,15 +760,6 @@ struct vm_area_struct *find_vma(struct mm_struct *m= m, unsigned long addr) EXPORT_SYMBOL(find_vma); =20 /* @@ -75674,9 +77861,10 @@ diff -urNp linux-2.6.32.49/mm/nommu.c linux-2.6.= 32.49/mm/nommu.c * expand a stack to a given address * - not supported under NOMMU conditions */ -diff -urNp linux-2.6.32.49/mm/page_alloc.c linux-2.6.32.49/mm/page_alloc= .c ---- linux-2.6.32.49/mm/page_alloc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/page_alloc.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/page_alloc.c b/mm/page_alloc.c +index 3ecab7e..594a471 100644 +--- a/mm/page_alloc.c ++++ b/mm/page_alloc.c @@ -289,7 +289,7 @@ out: * This usage means that zero-order pages may not be compound. */ @@ -75686,7 +77874,7 @@ diff -urNp linux-2.6.32.49/mm/page_alloc.c linux-= 2.6.32.49/mm/page_alloc.c { __free_pages_ok(page, compound_order(page)); } -@@ -587,6 +587,10 @@ static void __free_pages_ok(struct page=20 +@@ -587,6 +587,10 @@ static void __free_pages_ok(struct page *page, unsi= gned int order) int bad =3D 0; int wasMlocked =3D __TestClearPageMlocked(page); =20 @@ -75697,7 +77885,7 @@ diff -urNp linux-2.6.32.49/mm/page_alloc.c linux-= 2.6.32.49/mm/page_alloc.c kmemcheck_free_shadow(page, order); =20 for (i =3D 0 ; i < (1 << order) ; ++i) -@@ -599,6 +603,12 @@ static void __free_pages_ok(struct page=20 +@@ -599,6 +603,12 @@ static void __free_pages_ok(struct page *page, unsi= gned int order) debug_check_no_obj_freed(page_address(page), PAGE_SIZE << order); } @@ -75710,7 +77898,7 @@ diff -urNp linux-2.6.32.49/mm/page_alloc.c linux-= 2.6.32.49/mm/page_alloc.c arch_free_page(page, order); kernel_map_pages(page, 1 << order, 0); =20 -@@ -702,8 +712,10 @@ static int prep_new_page(struct page *pa +@@ -702,8 +712,10 @@ static int prep_new_page(struct page *page, int ord= er, gfp_t gfp_flags) arch_alloc_page(page, order); kernel_map_pages(page, 1 << order, 1); =20 @@ -75721,7 +77909,7 @@ diff -urNp linux-2.6.32.49/mm/page_alloc.c linux-= 2.6.32.49/mm/page_alloc.c =20 if (order && (gfp_flags & __GFP_COMP)) prep_compound_page(page, order); -@@ -1097,6 +1109,11 @@ static void free_hot_cold_page(struct pa +@@ -1097,6 +1109,11 @@ static void free_hot_cold_page(struct page *page,= int cold) debug_check_no_locks_freed(page_address(page), PAGE_SIZE); debug_check_no_obj_freed(page_address(page), PAGE_SIZE); } @@ -75742,7 +77930,7 @@ diff -urNp linux-2.6.32.49/mm/page_alloc.c linux-= 2.6.32.49/mm/page_alloc.c for_each_populated_zone(zone) { show_node(zone); printk("%s per-cpu:\n", zone->name); -@@ -3736,7 +3755,7 @@ static void __init setup_usemap(struct p +@@ -3736,7 +3755,7 @@ static void __init setup_usemap(struct pglist_data= *pgdat, zone->pageblock_flags =3D alloc_bootmem_node(pgdat, usemapsize); } #else @@ -75751,10 +77939,11 @@ diff -urNp linux-2.6.32.49/mm/page_alloc.c linu= x-2.6.32.49/mm/page_alloc.c struct zone *zone, unsigned long zonesize) {} #endif /* CONFIG_SPARSEMEM */ =20 -diff -urNp linux-2.6.32.49/mm/percpu.c linux-2.6.32.49/mm/percpu.c ---- linux-2.6.32.49/mm/percpu.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/percpu.c 2011-11-15 19:59:43.000000000 -0500 -@@ -115,7 +115,7 @@ static unsigned int pcpu_first_unit_cpu=20 +diff --git a/mm/percpu.c b/mm/percpu.c +index 3bfd6e2..60404b9 100644 +--- a/mm/percpu.c ++++ b/mm/percpu.c +@@ -115,7 +115,7 @@ static unsigned int pcpu_first_unit_cpu __read_mostl= y; static unsigned int pcpu_last_unit_cpu __read_mostly; =20 /* the address of the first chunk which starts with the kernel static a= rea */ @@ -75763,10 +77952,11 @@ diff -urNp linux-2.6.32.49/mm/percpu.c linux-2.= 6.32.49/mm/percpu.c EXPORT_SYMBOL_GPL(pcpu_base_addr); =20 static const int *pcpu_unit_map __read_mostly; /* cpu -> unit */ -diff -urNp linux-2.6.32.49/mm/rmap.c linux-2.6.32.49/mm/rmap.c ---- linux-2.6.32.49/mm/rmap.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/rmap.c 2011-11-15 19:59:43.000000000 -0500 -@@ -121,6 +121,17 @@ int anon_vma_prepare(struct vm_area_stru +diff --git a/mm/rmap.c b/mm/rmap.c +index dd43373..d848cd7 100644 +--- a/mm/rmap.c ++++ b/mm/rmap.c +@@ -121,6 +121,17 @@ int anon_vma_prepare(struct vm_area_struct *vma) /* page_table_lock to protect against threads */ spin_lock(&mm->page_table_lock); if (likely(!vma->anon_vma)) { @@ -75784,9 +77974,10 @@ diff -urNp linux-2.6.32.49/mm/rmap.c linux-2.6.3= 2.49/mm/rmap.c vma->anon_vma =3D anon_vma; list_add_tail(&vma->anon_vma_node, &anon_vma->head); allocated =3D NULL; -diff -urNp linux-2.6.32.49/mm/shmem.c linux-2.6.32.49/mm/shmem.c ---- linux-2.6.32.49/mm/shmem.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/shmem.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/shmem.c b/mm/shmem.c +index 3e0005b..1d659a8 100644 +--- a/mm/shmem.c ++++ b/mm/shmem.c @@ -31,7 +31,7 @@ #include #include @@ -75796,7 +77987,7 @@ diff -urNp linux-2.6.32.49/mm/shmem.c linux-2.6.3= 2.49/mm/shmem.c =20 #ifdef CONFIG_SHMEM /* -@@ -1061,6 +1061,8 @@ static int shmem_writepage(struct page * +@@ -1061,6 +1061,8 @@ static int shmem_writepage(struct page *page, stru= ct writeback_control *wbc) goto unlock; } entry =3D shmem_swp_entry(info, index, NULL); @@ -75805,7 +77996,7 @@ diff -urNp linux-2.6.32.49/mm/shmem.c linux-2.6.3= 2.49/mm/shmem.c if (entry->val) { /* * The more uptodate page coming down from a stacked -@@ -1144,6 +1146,8 @@ static struct page *shmem_swapin(swp_ent +@@ -1144,6 +1146,8 @@ static struct page *shmem_swapin(swp_entry_t entry= , gfp_t gfp, struct vm_area_struct pvma; struct page *page; =20 @@ -75814,7 +78005,7 @@ diff -urNp linux-2.6.32.49/mm/shmem.c linux-2.6.3= 2.49/mm/shmem.c spol =3D mpol_cond_copy(&mpol, mpol_shared_policy_lookup(&info->policy, idx)); =20 -@@ -1962,7 +1966,7 @@ static int shmem_symlink(struct inode *d +@@ -1962,7 +1966,7 @@ static int shmem_symlink(struct inode *dir, struct= dentry *dentry, const char *s =20 info =3D SHMEM_I(inode); inode->i_size =3D len-1; @@ -75823,7 +78014,7 @@ diff -urNp linux-2.6.32.49/mm/shmem.c linux-2.6.3= 2.49/mm/shmem.c /* do it inline */ memcpy(info, symname, len); inode->i_op =3D &shmem_symlink_inline_operations; -@@ -2310,8 +2314,7 @@ int shmem_fill_super(struct super_block=20 +@@ -2310,8 +2314,7 @@ int shmem_fill_super(struct super_block *sb, void = *data, int silent) int err =3D -ENOMEM; =20 /* Round up to L1_CACHE_BYTES to resist false sharing */ @@ -75833,9 +78024,10 @@ diff -urNp linux-2.6.32.49/mm/shmem.c linux-2.6.= 32.49/mm/shmem.c if (!sbinfo) return -ENOMEM; =20 -diff -urNp linux-2.6.32.49/mm/slab.c linux-2.6.32.49/mm/slab.c ---- linux-2.6.32.49/mm/slab.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/slab.c 2011-11-18 18:01:52.000000000 -0500 +diff --git a/mm/slab.c b/mm/slab.c +index c8d466a..909e01e 100644 +--- a/mm/slab.c ++++ b/mm/slab.c @@ -174,7 +174,7 @@ =20 /* Legal flag mask for kmem_cache_create(). */ @@ -75863,7 +78055,7 @@ diff -urNp linux-2.6.32.49/mm/slab.c linux-2.6.32= .49/mm/slab.c #define CACHE_CACHE 0 #define SIZE_AC MAX_NUMNODES #define SIZE_L3 (2 * MAX_NUMNODES) -@@ -409,10 +409,10 @@ static void kmem_list3_init(struct kmem_ +@@ -409,10 +409,10 @@ static void kmem_list3_init(struct kmem_list3 *par= ent) if ((x)->max_freeable < i) \ (x)->max_freeable =3D i; \ } while (0) @@ -75878,7 +78070,7 @@ diff -urNp linux-2.6.32.49/mm/slab.c linux-2.6.32= .49/mm/slab.c #else #define STATS_INC_ACTIVE(x) do { } while (0) #define STATS_DEC_ACTIVE(x) do { } while (0) -@@ -558,7 +558,7 @@ static inline void *index_to_obj(struct=20 +@@ -558,7 +558,7 @@ static inline void *index_to_obj(struct kmem_cache *= cache, struct slab *slab, * reciprocal_divide(offset, cache->reciprocal_buffer_size) */ static inline unsigned int obj_to_index(const struct kmem_cache *cache, @@ -75914,7 +78106,7 @@ diff -urNp linux-2.6.32.49/mm/slab.c linux-2.6.32= .49/mm/slab.c NULL); } #ifdef CONFIG_ZONE_DMA -@@ -4211,10 +4211,10 @@ static int s_show(struct seq_file *m, vo +@@ -4211,10 +4211,10 @@ static int s_show(struct seq_file *m, void *p) } /* cpu stats */ { @@ -75929,7 +78121,7 @@ diff -urNp linux-2.6.32.49/mm/slab.c linux-2.6.32= .49/mm/slab.c =20 seq_printf(m, " : cpustat %6lu %6lu %6lu %6lu", allochit, allocmiss, freehit, freemiss); -@@ -4471,15 +4471,70 @@ static const struct file_operations proc +@@ -4471,15 +4471,70 @@ static const struct file_operations proc_slabsta= ts_operations =3D { =20 static int __init slab_proc_init(void) { @@ -76002,9 +78194,10 @@ diff -urNp linux-2.6.32.49/mm/slab.c linux-2.6.3= 2.49/mm/slab.c /** * ksize - get the actual amount of memory allocated for a given object * @objp: Pointer to the object -diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32.49/mm/slob.c ---- linux-2.6.32.49/mm/slob.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/slob.c 2011-11-18 18:01:52.000000000 -0500 +diff --git a/mm/slob.c b/mm/slob.c +index 837ebd6..4712174 100644 +--- a/mm/slob.c ++++ b/mm/slob.c @@ -29,7 +29,7 @@ * If kmalloc is asked for objects of PAGE_SIZE or larger, it calls * alloc_pages() directly, allocating compound pages so the page order @@ -76041,7 +78234,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c } =20 static inline void set_slob_page(struct slob_page *sp) -@@ -148,7 +150,7 @@ static inline void clear_slob_page(struc +@@ -148,7 +150,7 @@ static inline void clear_slob_page(struct slob_page = *sp) =20 static inline struct slob_page *slob_page(const void *addr) { @@ -76050,7 +78243,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c } =20 /* -@@ -208,7 +210,7 @@ static void set_slob(slob_t *s, slobidx_ +@@ -208,7 +210,7 @@ static void set_slob(slob_t *s, slobidx_t size, slob= _t *next) /* * Return the size of a slob block. */ @@ -76077,7 +78270,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c { return !((unsigned long)slob_next(s) & ~PAGE_MASK); } -@@ -252,6 +254,7 @@ static void *slob_new_pages(gfp_t gfp, i +@@ -252,6 +254,7 @@ static void *slob_new_pages(gfp_t gfp, int order, in= t node) if (!page) return NULL; =20 @@ -76085,7 +78278,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c return page_address(page); } =20 -@@ -368,11 +371,11 @@ static void *slob_alloc(size_t size, gfp +@@ -368,11 +371,11 @@ static void *slob_alloc(size_t size, gfp_t gfp, in= t align, int node) if (!b) return NULL; sp =3D slob_page(b); @@ -76111,7 +78304,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c void *ret; =20 lockdep_trace_alloc(gfp); -@@ -491,7 +493,10 @@ void *__kmalloc_node(size_t size, gfp_t=20 +@@ -491,7 +493,10 @@ void *__kmalloc_node(size_t size, gfp_t gfp, int no= de) =20 if (!m) return NULL; @@ -76123,7 +78316,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c ret =3D (void *)m + align; =20 trace_kmalloc_node(_RET_IP_, ret, -@@ -501,16 +506,25 @@ void *__kmalloc_node(size_t size, gfp_t=20 +@@ -501,16 +506,25 @@ void *__kmalloc_node(size_t size, gfp_t gfp, int n= ode) =20 ret =3D slob_new_pages(gfp | __GFP_COMP, get_order(size), node); if (ret) { @@ -76263,7 +78456,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c } EXPORT_SYMBOL(ksize); =20 -@@ -566,8 +659,13 @@ struct kmem_cache *kmem_cache_create(con +@@ -566,8 +659,13 @@ struct kmem_cache *kmem_cache_create(const char *na= me, size_t size, { struct kmem_cache *c; =20 @@ -76277,7 +78470,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c =20 if (c) { c->name =3D name; -@@ -605,17 +703,25 @@ void *kmem_cache_alloc_node(struct kmem_ +@@ -605,17 +703,25 @@ void *kmem_cache_alloc_node(struct kmem_cache *c, = gfp_t flags, int node) { void *b; =20 @@ -76322,7 +78515,7 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.32= .49/mm/slob.c } =20 static void kmem_rcu_free(struct rcu_head *head) -@@ -643,18 +755,32 @@ static void kmem_rcu_free(struct rcu_hea +@@ -643,18 +755,32 @@ static void kmem_rcu_free(struct rcu_head *head) =20 void kmem_cache_free(struct kmem_cache *c, void *b) { @@ -76358,9 +78551,10 @@ diff -urNp linux-2.6.32.49/mm/slob.c linux-2.6.3= 2.49/mm/slob.c } EXPORT_SYMBOL(kmem_cache_free); =20 -diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32.49/mm/slub.c ---- linux-2.6.32.49/mm/slub.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/slub.c 2011-11-18 18:01:52.000000000 -0500 +diff --git a/mm/slub.c b/mm/slub.c +index 4996fc7..87e01d0 100644 +--- a/mm/slub.c ++++ b/mm/slub.c @@ -201,7 +201,7 @@ struct track { =20 enum track_item { TRACK_ALLOC, TRACK_FREE }; @@ -76370,7 +78564,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c static int sysfs_slab_add(struct kmem_cache *); static int sysfs_slab_alias(struct kmem_cache *, const char *); static void sysfs_slab_remove(struct kmem_cache *); -@@ -410,7 +410,7 @@ static void print_track(const char *s, s +@@ -410,7 +410,7 @@ static void print_track(const char *s, struct track = *t) if (!t->addr) return; =20 @@ -76379,7 +78573,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c s, (void *)t->addr, jiffies - t->when, t->cpu, t->pid); } =20 -@@ -1893,6 +1893,8 @@ void kmem_cache_free(struct kmem_cache * +@@ -1893,6 +1893,8 @@ void kmem_cache_free(struct kmem_cache *s, void *x= ) =20 page =3D virt_to_head_page(x); =20 @@ -76397,7 +78591,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c =20 /* * Calculate the order of allocation given an slab object size. -@@ -2493,7 +2495,7 @@ static int kmem_cache_open(struct kmem_c +@@ -2493,7 +2495,7 @@ static int kmem_cache_open(struct kmem_cache *s, g= fp_t gfpflags, * list to avoid pounding the page allocator excessively. */ set_min_partial(s, ilog2(s->size)); @@ -76406,7 +78600,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c #ifdef CONFIG_NUMA s->remote_node_defrag_ratio =3D 1000; #endif -@@ -2630,8 +2632,7 @@ static inline int kmem_cache_close(struc +@@ -2630,8 +2632,7 @@ static inline int kmem_cache_close(struct kmem_cac= he *s) void kmem_cache_destroy(struct kmem_cache *s) { down_write(&slub_lock); @@ -76416,7 +78610,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c list_del(&s->list); up_write(&slub_lock); if (kmem_cache_close(s)) { -@@ -2691,12 +2692,10 @@ static int __init setup_slub_nomerge(cha +@@ -2691,12 +2692,10 @@ static int __init setup_slub_nomerge(char *str) __setup("slub_nomerge", setup_slub_nomerge); =20 static struct kmem_cache *create_kmalloc_cache(struct kmem_cache *s, @@ -76431,7 +78625,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c =20 /* * This function is called with IRQs disabled during early-boot on -@@ -2915,6 +2914,50 @@ void *__kmalloc_node(size_t size, gfp_t=20 +@@ -2915,6 +2914,50 @@ void *__kmalloc_node(size_t size, gfp_t flags, in= t node) EXPORT_SYMBOL(__kmalloc_node); #endif =20 @@ -76515,7 +78709,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c caches++; } =20 -@@ -3293,7 +3336,7 @@ static int slab_unmergeable(struct kmem_ +@@ -3293,7 +3336,7 @@ static int slab_unmergeable(struct kmem_cache *s) /* * We may have set a slab to be unmergeable during bootstrap. */ @@ -76524,7 +78718,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c return 1; =20 return 0; -@@ -3353,7 +3396,7 @@ struct kmem_cache *kmem_cache_create(con +@@ -3353,7 +3396,7 @@ struct kmem_cache *kmem_cache_create(const char *n= ame, size_t size, if (s) { int cpu; =20 @@ -76533,7 +78727,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c /* * Adjust the object sizes so that we clear * the complete object on kzalloc. -@@ -3372,7 +3415,7 @@ struct kmem_cache *kmem_cache_create(con +@@ -3372,7 +3415,7 @@ struct kmem_cache *kmem_cache_create(const char *n= ame, size_t size, =20 if (sysfs_slab_alias(s, name)) { down_write(&slub_lock); @@ -76551,7 +78745,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c } SLAB_ATTR_RO(aliases); =20 -@@ -4503,7 +4546,7 @@ static void kmem_cache_release(struct ko +@@ -4503,7 +4546,7 @@ static void kmem_cache_release(struct kobject *kob= j) kfree(s); } =20 @@ -76560,7 +78754,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c .show =3D slab_attr_show, .store =3D slab_attr_store, }; -@@ -4522,7 +4565,7 @@ static int uevent_filter(struct kset *ks +@@ -4522,7 +4565,7 @@ static int uevent_filter(struct kset *kset, struct= kobject *kobj) return 0; } =20 @@ -76569,7 +78763,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c .filter =3D uevent_filter, }; =20 -@@ -4564,6 +4607,7 @@ static char *create_unique_id(struct kme +@@ -4564,6 +4607,7 @@ static char *create_unique_id(struct kmem_cache *s= ) return name; } =20 @@ -76577,7 +78771,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c static int sysfs_slab_add(struct kmem_cache *s) { int err; -@@ -4619,6 +4663,7 @@ static void sysfs_slab_remove(struct kme +@@ -4619,6 +4663,7 @@ static void sysfs_slab_remove(struct kmem_cache *s= ) kobject_del(&s->kobj); kobject_put(&s->kobj); } @@ -76593,7 +78787,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c static int sysfs_slab_alias(struct kmem_cache *s, const char *name) { struct saved_alias *al; -@@ -4654,6 +4700,7 @@ static int sysfs_slab_alias(struct kmem_ +@@ -4654,6 +4700,7 @@ static int sysfs_slab_alias(struct kmem_cache *s, = const char *name) alias_list =3D al; return 0; } @@ -76601,7 +78795,7 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.32= .49/mm/slub.c =20 static int __init slab_sysfs_init(void) { -@@ -4785,7 +4832,13 @@ static const struct file_operations proc +@@ -4785,7 +4832,13 @@ static const struct file_operations proc_slabinfo= _operations =3D { =20 static int __init slab_proc_init(void) { @@ -76616,9 +78810,10 @@ diff -urNp linux-2.6.32.49/mm/slub.c linux-2.6.3= 2.49/mm/slub.c return 0; } module_init(slab_proc_init); -diff -urNp linux-2.6.32.49/mm/swap.c linux-2.6.32.49/mm/swap.c ---- linux-2.6.32.49/mm/swap.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/swap.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/swap.c b/mm/swap.c +index 308e57d..5de19c0 100644 +--- a/mm/swap.c ++++ b/mm/swap.c @@ -30,6 +30,7 @@ #include #include @@ -76627,7 +78822,7 @@ diff -urNp linux-2.6.32.49/mm/swap.c linux-2.6.32= .49/mm/swap.c =20 #include "internal.h" =20 -@@ -65,6 +66,8 @@ static void put_compound_page(struct pag +@@ -65,6 +66,8 @@ static void put_compound_page(struct page *page) compound_page_dtor *dtor; =20 dtor =3D get_compound_page_dtor(page); @@ -76636,9 +78831,10 @@ diff -urNp linux-2.6.32.49/mm/swap.c linux-2.6.3= 2.49/mm/swap.c (*dtor)(page); } } -diff -urNp linux-2.6.32.49/mm/util.c linux-2.6.32.49/mm/util.c ---- linux-2.6.32.49/mm/util.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/util.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/util.c b/mm/util.c +index b377ce4..3a891af 100644 +--- a/mm/util.c ++++ b/mm/util.c @@ -228,6 +228,12 @@ EXPORT_SYMBOL(strndup_user); void arch_pick_mmap_layout(struct mm_struct *mm) { @@ -76652,10 +78848,11 @@ diff -urNp linux-2.6.32.49/mm/util.c linux-2.6.= 32.49/mm/util.c mm->get_unmapped_area =3D arch_get_unmapped_area; mm->unmap_area =3D arch_unmap_area; } -diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6.32.49/mm/vmalloc.c ---- linux-2.6.32.49/mm/vmalloc.c 2011-11-26 19:44:53.000000000 -0500 -+++ linux-2.6.32.49/mm/vmalloc.c 2011-11-26 19:49:57.000000000 -0500 -@@ -40,8 +40,19 @@ static void vunmap_pte_range(pmd_t *pmd, +diff --git a/mm/vmalloc.c b/mm/vmalloc.c +index f34ffd0..28e94b7 100644 +--- a/mm/vmalloc.c ++++ b/mm/vmalloc.c +@@ -40,8 +40,19 @@ static void vunmap_pte_range(pmd_t *pmd, unsigned lon= g addr, unsigned long end) =20 pte =3D pte_offset_kernel(pmd, addr); do { @@ -76677,7 +78874,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c } while (pte++, addr +=3D PAGE_SIZE, addr !=3D end); } =20 -@@ -92,6 +103,7 @@ static int vmap_pte_range(pmd_t *pmd, un +@@ -92,6 +103,7 @@ static int vmap_pte_range(pmd_t *pmd, unsigned long a= ddr, unsigned long end, pgprot_t prot, struct page **pages, int *nr) { pte_t *pte; @@ -76685,7 +78882,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c =20 /* * nr is a running index into the array which helps higher level -@@ -101,17 +113,32 @@ static int vmap_pte_range(pmd_t *pmd, un +@@ -101,17 +113,32 @@ static int vmap_pte_range(pmd_t *pmd, unsigned lon= g addr, pte =3D pte_alloc_kernel(pmd, addr); if (!pte) return -ENOMEM; @@ -76723,7 +78920,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c } =20 static int vmap_pmd_range(pud_t *pud, unsigned long addr, -@@ -192,11 +219,20 @@ int is_vmalloc_or_module_addr(const void +@@ -192,11 +219,20 @@ int is_vmalloc_or_module_addr(const void *x) * and fall back on vmalloc() if that fails. Others * just put it in the vmalloc space. */ @@ -76745,7 +78942,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c return is_vmalloc_addr(x); } =20 -@@ -217,8 +253,14 @@ struct page *vmalloc_to_page(const void=20 +@@ -217,8 +253,14 @@ struct page *vmalloc_to_page(const void *vmalloc_ad= dr) =20 if (!pgd_none(*pgd)) { pud_t *pud =3D pud_offset(pgd, addr); @@ -76760,7 +78957,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c if (!pmd_none(*pmd)) { pte_t *ptep, pte; =20 -@@ -292,13 +334,13 @@ static void __insert_vmap_area(struct vm +@@ -292,13 +334,13 @@ static void __insert_vmap_area(struct vmap_area *v= a) struct rb_node *tmp; =20 while (*p) { @@ -76778,7 +78975,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c p =3D &(*p)->rb_right; else BUG(); -@@ -1245,6 +1287,16 @@ static struct vm_struct *__get_vm_area_n +@@ -1245,6 +1287,16 @@ static struct vm_struct *__get_vm_area_node(unsig= ned long size, struct vm_struct *area; =20 BUG_ON(in_interrupt()); @@ -76795,7 +78992,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c if (flags & VM_IOREMAP) { int bit =3D fls(size); =20 -@@ -1484,6 +1536,11 @@ void *vmap(struct page **pages, unsigned +@@ -1484,6 +1536,11 @@ void *vmap(struct page **pages, unsigned int coun= t, if (count > totalram_pages) return NULL; =20 @@ -76807,7 +79004,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c area =3D get_vm_area_caller((count << PAGE_SHIFT), flags, __builtin_return_address(0)); if (!area) -@@ -1594,6 +1651,13 @@ static void *__vmalloc_node(unsigned lon +@@ -1594,6 +1651,13 @@ static void *__vmalloc_node(unsigned long size, u= nsigned long align, if (!size || (size >> PAGE_SHIFT) > totalram_pages) return NULL; =20 @@ -76821,7 +79018,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c area =3D __get_vm_area_node(size, align, VM_ALLOC | VM_UNLIST, VMALLOC_START, VMALLOC_END, node, gfp_mask, caller); -@@ -1619,6 +1683,7 @@ static void *__vmalloc_node(unsigned lon +@@ -1619,6 +1683,7 @@ static void *__vmalloc_node(unsigned long size, un= signed long align, return addr; } =20 @@ -76882,7 +79079,7 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.6= .32.49/mm/vmalloc.c void *vmalloc_32_user(unsigned long size) { struct vm_struct *area; -@@ -1998,6 +2068,8 @@ int remap_vmalloc_range(struct vm_area_s +@@ -1998,6 +2068,8 @@ int remap_vmalloc_range(struct vm_area_struct *vma= , void *addr, unsigned long uaddr =3D vma->vm_start; unsigned long usize =3D vma->vm_end - vma->vm_start; =20 @@ -76891,9 +79088,10 @@ diff -urNp linux-2.6.32.49/mm/vmalloc.c linux-2.= 6.32.49/mm/vmalloc.c if ((PAGE_SIZE-1) & (unsigned long)addr) return -EINVAL; =20 -diff -urNp linux-2.6.32.49/mm/vmstat.c linux-2.6.32.49/mm/vmstat.c ---- linux-2.6.32.49/mm/vmstat.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/mm/vmstat.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/mm/vmstat.c b/mm/vmstat.c +index 42d76c6..5643dc4 100644 +--- a/mm/vmstat.c ++++ b/mm/vmstat.c @@ -74,7 +74,7 @@ void vm_events_fold_cpu(int cpu) * * vm_stat contains the global counters @@ -76946,10 +79144,11 @@ diff -urNp linux-2.6.32.49/mm/vmstat.c linux-2.= 6.32.49/mm/vmstat.c #endif return 0; } -diff -urNp linux-2.6.32.49/net/8021q/vlan.c linux-2.6.32.49/net/8021q/vl= an.c ---- linux-2.6.32.49/net/8021q/vlan.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/8021q/vlan.c 2011-11-15 19:59:43.000000000 -0500 -@@ -622,8 +622,7 @@ static int vlan_ioctl_handler(struct net +diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c +index a29c5ab..6143f20 100644 +--- a/net/8021q/vlan.c ++++ b/net/8021q/vlan.c +@@ -622,8 +622,7 @@ static int vlan_ioctl_handler(struct net *net, void = __user *arg) err =3D -EPERM; if (!capable(CAP_NET_ADMIN)) break; @@ -76959,10 +79158,11 @@ diff -urNp linux-2.6.32.49/net/8021q/vlan.c lin= ux-2.6.32.49/net/8021q/vlan.c struct vlan_net *vn; =20 vn =3D net_generic(net, vlan_net_id); -diff -urNp linux-2.6.32.49/net/9p/trans_fd.c linux-2.6.32.49/net/9p/tran= s_fd.c ---- linux-2.6.32.49/net/9p/trans_fd.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/9p/trans_fd.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -419,7 +419,7 @@ static int p9_fd_write(struct p9_client=20 +diff --git a/net/9p/trans_fd.c b/net/9p/trans_fd.c +index a2d2984..f9eb711 100644 +--- a/net/9p/trans_fd.c ++++ b/net/9p/trans_fd.c +@@ -419,7 +419,7 @@ static int p9_fd_write(struct p9_client *client, voi= d *v, int len) oldfs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -76971,10 +79171,11 @@ diff -urNp linux-2.6.32.49/net/9p/trans_fd.c li= nux-2.6.32.49/net/9p/trans_fd.c set_fs(oldfs); =20 if (ret <=3D 0 && ret !=3D -ERESTARTSYS && ret !=3D -EAGAIN) -diff -urNp linux-2.6.32.49/net/atm/atm_misc.c linux-2.6.32.49/net/atm/at= m_misc.c ---- linux-2.6.32.49/net/atm/atm_misc.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/atm/atm_misc.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -19,7 +19,7 @@ int atm_charge(struct atm_vcc *vcc,int t +diff --git a/net/atm/atm_misc.c b/net/atm/atm_misc.c +index 02cc7e7..4514f1b 100644 +--- a/net/atm/atm_misc.c ++++ b/net/atm/atm_misc.c +@@ -19,7 +19,7 @@ int atm_charge(struct atm_vcc *vcc,int truesize) if (atomic_read(&sk_atm(vcc)->sk_rmem_alloc) <=3D sk_atm(vcc)->sk_rcvb= uf) return 1; atm_return(vcc,truesize); @@ -76983,7 +79184,7 @@ diff -urNp linux-2.6.32.49/net/atm/atm_misc.c lin= ux-2.6.32.49/net/atm/atm_misc.c return 0; } =20 -@@ -41,7 +41,7 @@ struct sk_buff *atm_alloc_charge(struct=20 +@@ -41,7 +41,7 @@ struct sk_buff *atm_alloc_charge(struct atm_vcc *vcc,i= nt pdu_size, } } atm_return(vcc,guess); @@ -76992,7 +79193,7 @@ diff -urNp linux-2.6.32.49/net/atm/atm_misc.c lin= ux-2.6.32.49/net/atm/atm_misc.c return NULL; } =20 -@@ -88,7 +88,7 @@ int atm_pcr_goal(const struct atm_trafpr +@@ -88,7 +88,7 @@ int atm_pcr_goal(const struct atm_trafprm *tp) =20 void sonet_copy_stats(struct k_sonet_stats *from,struct sonet_stats *to= ) { @@ -77001,7 +79202,7 @@ diff -urNp linux-2.6.32.49/net/atm/atm_misc.c lin= ux-2.6.32.49/net/atm/atm_misc.c __SONET_ITEMS #undef __HANDLE_ITEM } -@@ -96,7 +96,7 @@ void sonet_copy_stats(struct k_sonet_sta +@@ -96,7 +96,7 @@ void sonet_copy_stats(struct k_sonet_stats *from,struc= t sonet_stats *to) =20 void sonet_subtract_stats(struct k_sonet_stats *from,struct sonet_stats= *to) { @@ -77010,9 +79211,10 @@ diff -urNp linux-2.6.32.49/net/atm/atm_misc.c li= nux-2.6.32.49/net/atm/atm_misc.c __SONET_ITEMS #undef __HANDLE_ITEM } -diff -urNp linux-2.6.32.49/net/atm/lec.h linux-2.6.32.49/net/atm/lec.h ---- linux-2.6.32.49/net/atm/lec.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/atm/lec.h 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/atm/lec.h b/net/atm/lec.h +index 9d14d19..5c145f3 100644 +--- a/net/atm/lec.h ++++ b/net/atm/lec.h @@ -48,7 +48,7 @@ struct lane2_ops { const u8 *tlvs, u32 sizeoftlvs); void (*associate_indicator) (struct net_device *dev, const u8 *mac_add= r, @@ -77022,9 +79224,10 @@ diff -urNp linux-2.6.32.49/net/atm/lec.h linux-2= .6.32.49/net/atm/lec.h =20 /* * ATM LAN Emulation supports both LLC & Dix Ethernet EtherType -diff -urNp linux-2.6.32.49/net/atm/mpc.h linux-2.6.32.49/net/atm/mpc.h ---- linux-2.6.32.49/net/atm/mpc.h 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/atm/mpc.h 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/atm/mpc.h b/net/atm/mpc.h +index 0919a88..a23d54e 100644 +--- a/net/atm/mpc.h ++++ b/net/atm/mpc.h @@ -33,7 +33,7 @@ struct mpoa_client { struct mpc_parameters parameters; /* parameters for this client */ =20 @@ -77034,10 +79237,11 @@ diff -urNp linux-2.6.32.49/net/atm/mpc.h linux-= 2.6.32.49/net/atm/mpc.h }; =20 =20 -diff -urNp linux-2.6.32.49/net/atm/mpoa_caches.c linux-2.6.32.49/net/atm= /mpoa_caches.c ---- linux-2.6.32.49/net/atm/mpoa_caches.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/net/atm/mpoa_caches.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -498,6 +498,8 @@ static void clear_expired(struct mpoa_cl +diff --git a/net/atm/mpoa_caches.c b/net/atm/mpoa_caches.c +index 4504a4b..1733f1e 100644 +--- a/net/atm/mpoa_caches.c ++++ b/net/atm/mpoa_caches.c +@@ -498,6 +498,8 @@ static void clear_expired(struct mpoa_client *client= ) struct timeval now; struct k_message msg; =20 @@ -77046,10 +79250,11 @@ diff -urNp linux-2.6.32.49/net/atm/mpoa_caches.= c linux-2.6.32.49/net/atm/mpoa_ca do_gettimeofday(&now); =20 write_lock_irq(&client->egress_lock); -diff -urNp linux-2.6.32.49/net/atm/proc.c linux-2.6.32.49/net/atm/proc.c ---- linux-2.6.32.49/net/atm/proc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/atm/proc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -43,9 +43,9 @@ static void add_stats(struct seq_file *s +diff --git a/net/atm/proc.c b/net/atm/proc.c +index ab8419a..aa91497 100644 +--- a/net/atm/proc.c ++++ b/net/atm/proc.c +@@ -43,9 +43,9 @@ static void add_stats(struct seq_file *seq, const char= *aal, const struct k_atm_aal_stats *stats) { seq_printf(seq, "%s ( %d %d %d %d %d )", aal, @@ -77062,7 +79267,7 @@ diff -urNp linux-2.6.32.49/net/atm/proc.c linux-2= .6.32.49/net/atm/proc.c } =20 static void atm_dev_info(struct seq_file *seq, const struct atm_dev *de= v) -@@ -188,7 +188,12 @@ static void vcc_info(struct seq_file *se +@@ -188,7 +188,12 @@ static void vcc_info(struct seq_file *seq, struct a= tm_vcc *vcc) { struct sock *sk =3D sk_atm(vcc); =20 @@ -77075,7 +79280,7 @@ diff -urNp linux-2.6.32.49/net/atm/proc.c linux-2= .6.32.49/net/atm/proc.c if (!vcc->dev) seq_printf(seq, "Unassigned "); else -@@ -214,7 +219,11 @@ static void svc_info(struct seq_file *se +@@ -214,7 +219,11 @@ static void svc_info(struct seq_file *seq, struct a= tm_vcc *vcc) { if (!vcc->dev) seq_printf(seq, sizeof(void *) =3D=3D 4 ? @@ -77087,10 +79292,11 @@ diff -urNp linux-2.6.32.49/net/atm/proc.c linux= -2.6.32.49/net/atm/proc.c else seq_printf(seq, "%3d %3d %5d ", vcc->dev->number, vcc->vpi, vcc->vci); -diff -urNp linux-2.6.32.49/net/atm/resources.c linux-2.6.32.49/net/atm/r= esources.c ---- linux-2.6.32.49/net/atm/resources.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/atm/resources.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -161,7 +161,7 @@ void atm_dev_deregister(struct atm_dev * +diff --git a/net/atm/resources.c b/net/atm/resources.c +index 56b7322..c48b84e 100644 +--- a/net/atm/resources.c ++++ b/net/atm/resources.c +@@ -161,7 +161,7 @@ void atm_dev_deregister(struct atm_dev *dev) static void copy_aal_stats(struct k_atm_aal_stats *from, struct atm_aal_stats *to) { @@ -77099,7 +79305,7 @@ diff -urNp linux-2.6.32.49/net/atm/resources.c li= nux-2.6.32.49/net/atm/resources __AAL_STAT_ITEMS #undef __HANDLE_ITEM } -@@ -170,7 +170,7 @@ static void copy_aal_stats(struct k_atm_ +@@ -170,7 +170,7 @@ static void copy_aal_stats(struct k_atm_aal_stats *f= rom, static void subtract_aal_stats(struct k_atm_aal_stats *from, struct atm_aal_stats *to) { @@ -77108,10 +79314,11 @@ diff -urNp linux-2.6.32.49/net/atm/resources.c = linux-2.6.32.49/net/atm/resources __AAL_STAT_ITEMS #undef __HANDLE_ITEM } -diff -urNp linux-2.6.32.49/net/bridge/br_private.h linux-2.6.32.49/net/b= ridge/br_private.h ---- linux-2.6.32.49/net/bridge/br_private.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/net/bridge/br_private.h 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -255,7 +255,7 @@ extern void br_ifinfo_notify(int event,=20 +diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h +index 8567d47..bba2292 100644 +--- a/net/bridge/br_private.h ++++ b/net/bridge/br_private.h +@@ -255,7 +255,7 @@ extern void br_ifinfo_notify(int event, struct net_b= ridge_port *port); =20 #ifdef CONFIG_SYSFS /* br_sysfs_if.c */ @@ -77120,10 +79327,11 @@ diff -urNp linux-2.6.32.49/net/bridge/br_privat= e.h linux-2.6.32.49/net/bridge/br extern int br_sysfs_addif(struct net_bridge_port *p); =20 /* br_sysfs_br.c */ -diff -urNp linux-2.6.32.49/net/bridge/br_stp_if.c linux-2.6.32.49/net/br= idge/br_stp_if.c ---- linux-2.6.32.49/net/bridge/br_stp_if.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/bridge/br_stp_if.c 2011-11-15 19:59:43.000000000= -0500 -@@ -146,7 +146,7 @@ static void br_stp_stop(struct net_bridg +diff --git a/net/bridge/br_stp_if.c b/net/bridge/br_stp_if.c +index 9a52ac5..c97538e 100644 +--- a/net/bridge/br_stp_if.c ++++ b/net/bridge/br_stp_if.c +@@ -146,7 +146,7 @@ static void br_stp_stop(struct net_bridge *br) char *envp[] =3D { NULL }; =20 if (br->stp_enabled =3D=3D BR_USER_STP) { @@ -77132,10 +79340,11 @@ diff -urNp linux-2.6.32.49/net/bridge/br_stp_if= .c linux-2.6.32.49/net/bridge/br_ printk(KERN_INFO "%s: userspace STP stopped, return code %d\n", br->dev->name, r); =20 -diff -urNp linux-2.6.32.49/net/bridge/br_sysfs_if.c linux-2.6.32.49/net/= bridge/br_sysfs_if.c ---- linux-2.6.32.49/net/bridge/br_sysfs_if.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/net/bridge/br_sysfs_if.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -220,7 +220,7 @@ static ssize_t brport_store(struct kobje +diff --git a/net/bridge/br_sysfs_if.c b/net/bridge/br_sysfs_if.c +index 820643a..ce77fb3 100644 +--- a/net/bridge/br_sysfs_if.c ++++ b/net/bridge/br_sysfs_if.c +@@ -220,7 +220,7 @@ static ssize_t brport_store(struct kobject * kobj, return ret; } =20 @@ -77144,10 +79353,11 @@ diff -urNp linux-2.6.32.49/net/bridge/br_sysfs_= if.c linux-2.6.32.49/net/bridge/b .show =3D brport_show, .store =3D brport_store, }; -diff -urNp linux-2.6.32.49/net/bridge/netfilter/ebtables.c linux-2.6.32.= 49/net/bridge/netfilter/ebtables.c ---- linux-2.6.32.49/net/bridge/netfilter/ebtables.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/net/bridge/netfilter/ebtables.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -1337,6 +1337,8 @@ static int copy_everything_to_user(struc +diff --git a/net/bridge/netfilter/ebtables.c b/net/bridge/netfilter/ebta= bles.c +index d73d47f..72df42a 100644 +--- a/net/bridge/netfilter/ebtables.c ++++ b/net/bridge/netfilter/ebtables.c +@@ -1337,6 +1337,8 @@ static int copy_everything_to_user(struct ebt_tabl= e *t, void __user *user, unsigned int entries_size, nentries; char *entries; =20 @@ -77156,10 +79366,11 @@ diff -urNp linux-2.6.32.49/net/bridge/netfilter= /ebtables.c linux-2.6.32.49/net/b if (cmd =3D=3D EBT_SO_GET_ENTRIES) { entries_size =3D t->private->entries_size; nentries =3D t->private->nentries; -diff -urNp linux-2.6.32.49/net/can/bcm.c linux-2.6.32.49/net/can/bcm.c ---- linux-2.6.32.49/net/can/bcm.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/can/bcm.c 2011-11-15 19:59:43.000000000 -0500 -@@ -164,9 +164,15 @@ static int bcm_proc_show(struct seq_file +diff --git a/net/can/bcm.c b/net/can/bcm.c +index 2ffd2e0..72a7486 100644 +--- a/net/can/bcm.c ++++ b/net/can/bcm.c +@@ -164,9 +164,15 @@ static int bcm_proc_show(struct seq_file *m, void *= v) struct bcm_sock *bo =3D bcm_sk(sk); struct bcm_op *op; =20 @@ -77175,10 +79386,11 @@ diff -urNp linux-2.6.32.49/net/can/bcm.c linux-= 2.6.32.49/net/can/bcm.c seq_printf(m, " / dropped %lu", bo->dropped_usr_msgs); seq_printf(m, " / bound %s", bcm_proc_getifname(ifname, bo->ifindex)); seq_printf(m, " <<<\n"); -diff -urNp linux-2.6.32.49/net/compat.c linux-2.6.32.49/net/compat.c ---- linux-2.6.32.49/net/compat.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/compat.c 2011-11-15 19:59:43.000000000 -0500 -@@ -69,9 +69,9 @@ int get_compat_msghdr(struct msghdr *kms +diff --git a/net/compat.c b/net/compat.c +index 9559afc..ccd74e1 100644 +--- a/net/compat.c ++++ b/net/compat.c +@@ -69,9 +69,9 @@ int get_compat_msghdr(struct msghdr *kmsg, struct comp= at_msghdr __user *umsg) __get_user(kmsg->msg_controllen, &umsg->msg_controllen) || __get_user(kmsg->msg_flags, &umsg->msg_flags)) return -EFAULT; @@ -77191,7 +79403,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c return 0; } =20 -@@ -94,7 +94,7 @@ int verify_compat_iovec(struct msghdr *k +@@ -94,7 +94,7 @@ int verify_compat_iovec(struct msghdr *kern_msg, struc= t iovec *kern_iov, kern_msg->msg_name =3D NULL; =20 tot_len =3D iov_from_user_compat_to_kern(kern_iov, @@ -77200,7 +79412,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c kern_msg->msg_iovlen); if (tot_len >=3D 0) kern_msg->msg_iov =3D kern_iov; -@@ -114,20 +114,20 @@ int verify_compat_iovec(struct msghdr *k +@@ -114,20 +114,20 @@ int verify_compat_iovec(struct msghdr *kern_msg, s= truct iovec *kern_iov, =20 #define CMSG_COMPAT_FIRSTHDR(msg) \ (((msg)->msg_controllen) >=3D sizeof(struct compat_cmsghdr) ? \ @@ -77224,7 +79436,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c msg->msg_controllen) return NULL; return (struct compat_cmsghdr __user *)ptr; -@@ -219,7 +219,7 @@ int put_cmsg_compat(struct msghdr *kmsg, +@@ -219,7 +219,7 @@ int put_cmsg_compat(struct msghdr *kmsg, int level, = int type, int len, void *dat { struct compat_timeval ctv; struct compat_timespec cts[3]; @@ -77233,7 +79445,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c struct compat_cmsghdr cmhdr; int cmlen; =20 -@@ -271,7 +271,7 @@ int put_cmsg_compat(struct msghdr *kmsg, +@@ -271,7 +271,7 @@ int put_cmsg_compat(struct msghdr *kmsg, int level, = int type, int len, void *dat =20 void scm_detach_fds_compat(struct msghdr *kmsg, struct scm_cookie *scm) { @@ -77242,7 +79454,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c int fdmax =3D (kmsg->msg_controllen - sizeof(struct compat_cmsghdr)) /= sizeof(int); int fdnum =3D scm->fp->count; struct file **fp =3D scm->fp->fp; -@@ -433,7 +433,7 @@ static int do_get_sock_timeout(struct so +@@ -433,7 +433,7 @@ static int do_get_sock_timeout(struct socket *sock, = int level, int optname, len =3D sizeof(ktime); old_fs =3D get_fs(); set_fs(KERNEL_DS); @@ -77251,7 +79463,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c set_fs(old_fs); =20 if (!err) { -@@ -570,7 +570,7 @@ int compat_mc_setsockopt(struct sock *so +@@ -570,7 +570,7 @@ int compat_mc_setsockopt(struct sock *sock, int leve= l, int optname, case MCAST_JOIN_GROUP: case MCAST_LEAVE_GROUP: { @@ -77260,7 +79472,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c struct group_req __user *kgr =3D compat_alloc_user_space(sizeof(struct group_req)); u32 interface; -@@ -591,7 +591,7 @@ int compat_mc_setsockopt(struct sock *so +@@ -591,7 +591,7 @@ int compat_mc_setsockopt(struct sock *sock, int leve= l, int optname, case MCAST_BLOCK_SOURCE: case MCAST_UNBLOCK_SOURCE: { @@ -77269,7 +79481,7 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2.6= .32.49/net/compat.c struct group_source_req __user *kgsr =3D compat_alloc_user_space( sizeof(struct group_source_req)); u32 interface; -@@ -612,7 +612,7 @@ int compat_mc_setsockopt(struct sock *so +@@ -612,7 +612,7 @@ int compat_mc_setsockopt(struct sock *sock, int leve= l, int optname, } case MCAST_MSFILTER: { @@ -77278,10 +79490,11 @@ diff -urNp linux-2.6.32.49/net/compat.c linux-2= .6.32.49/net/compat.c struct group_filter __user *kgf; u32 interface, fmode, numsrc; =20 -diff -urNp linux-2.6.32.49/net/core/dev.c linux-2.6.32.49/net/core/dev.c ---- linux-2.6.32.49/net/core/dev.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/core/dev.c 2011-11-15 19:59:43.000000000 -0500 -@@ -1047,10 +1047,14 @@ void dev_load(struct net *net, const cha +diff --git a/net/core/dev.c b/net/core/dev.c +index 64eb849..7b5948b 100644 +--- a/net/core/dev.c ++++ b/net/core/dev.c +@@ -1047,10 +1047,14 @@ void dev_load(struct net *net, const char *name) if (no_module && capable(CAP_NET_ADMIN)) no_module =3D request_module("netdev-%s", name); if (no_module && capable(CAP_SYS_MODULE)) { @@ -77296,7 +79509,7 @@ diff -urNp linux-2.6.32.49/net/core/dev.c linux-2= .6.32.49/net/core/dev.c } } EXPORT_SYMBOL(dev_load); -@@ -1654,7 +1658,7 @@ static inline int illegal_highdma(struct +@@ -1654,7 +1658,7 @@ static inline int illegal_highdma(struct net_devic= e *dev, struct sk_buff *skb) =20 struct dev_gso_cb { void (*destructor)(struct sk_buff *skb); @@ -77314,7 +79527,7 @@ diff -urNp linux-2.6.32.49/net/core/dev.c linux-2= .6.32.49/net/core/dev.c { struct softnet_data *sd =3D &__get_cpu_var(softnet_data); =20 -@@ -2826,7 +2830,7 @@ void netif_napi_del(struct napi_struct * +@@ -2826,7 +2830,7 @@ void netif_napi_del(struct napi_struct *napi) EXPORT_SYMBOL(netif_napi_del); =20 =20 @@ -77323,9 +79536,10 @@ diff -urNp linux-2.6.32.49/net/core/dev.c linux-= 2.6.32.49/net/core/dev.c { struct list_head *list =3D &__get_cpu_var(softnet_data).poll_list; unsigned long time_limit =3D jiffies + 2; -diff -urNp linux-2.6.32.49/net/core/flow.c linux-2.6.32.49/net/core/flow= .c ---- linux-2.6.32.49/net/core/flow.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/core/flow.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/core/flow.c b/net/core/flow.c +index 9601587..8c4824e 100644 +--- a/net/core/flow.c ++++ b/net/core/flow.c @@ -35,11 +35,11 @@ struct flow_cache_entry { atomic_t *object_ref; }; @@ -77358,7 +79572,7 @@ diff -urNp linux-2.6.32.49/net/core/flow.c linux-= 2.6.32.49/net/core/flow.c =20 #define flow_flush_tasklet(cpu) (&per_cpu(flow_flush_tasklets, cpu)) =20 -@@ -190,7 +190,7 @@ void *flow_cache_lookup(struct net *net, +@@ -190,7 +190,7 @@ void *flow_cache_lookup(struct net *net, struct flow= i *key, u16 family, u8 dir, if (fle->family =3D=3D family && fle->dir =3D=3D dir && flow_key_compare(key, &fle->key) =3D=3D 0) { @@ -77376,7 +79590,7 @@ diff -urNp linux-2.6.32.49/net/core/flow.c linux-= 2.6.32.49/net/core/flow.c =20 if (fle->object) atomic_dec(fle->object_ref); -@@ -258,7 +258,7 @@ static void flow_cache_flush_tasklet(uns +@@ -258,7 +258,7 @@ static void flow_cache_flush_tasklet(unsigned long d= ata) =20 fle =3D flow_table(cpu)[i]; for (; fle; fle =3D fle->next) { @@ -77385,9 +79599,10 @@ diff -urNp linux-2.6.32.49/net/core/flow.c linux= -2.6.32.49/net/core/flow.c =20 if (!fle->object || fle->genid =3D=3D genid) continue; -diff -urNp linux-2.6.32.49/net/core/rtnetlink.c linux-2.6.32.49/net/core= /rtnetlink.c ---- linux-2.6.32.49/net/core/rtnetlink.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/core/rtnetlink.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c +index d4fd895..ac9b1e6 100644 +--- a/net/core/rtnetlink.c ++++ b/net/core/rtnetlink.c @@ -57,7 +57,7 @@ struct rtnl_link { rtnl_doit_func doit; @@ -77397,9 +79612,10 @@ diff -urNp linux-2.6.32.49/net/core/rtnetlink.c = linux-2.6.32.49/net/core/rtnetli =20 static DEFINE_MUTEX(rtnl_mutex); =20 -diff -urNp linux-2.6.32.49/net/core/scm.c linux-2.6.32.49/net/core/scm.c ---- linux-2.6.32.49/net/core/scm.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/core/scm.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/core/scm.c b/net/core/scm.c +index d98eafc..1a190a9 100644 +--- a/net/core/scm.c ++++ b/net/core/scm.c @@ -191,7 +191,7 @@ error: int put_cmsg(struct msghdr * msg, int level, int type, int len, void *d= ata) { @@ -77409,7 +79625,7 @@ diff -urNp linux-2.6.32.49/net/core/scm.c linux-2= .6.32.49/net/core/scm.c struct cmsghdr cmhdr; int cmlen =3D CMSG_LEN(len); int err; -@@ -214,7 +214,7 @@ int put_cmsg(struct msghdr * msg, int le +@@ -214,7 +214,7 @@ int put_cmsg(struct msghdr * msg, int level, int typ= e, int len, void *data) err =3D -EFAULT; if (copy_to_user(cm, &cmhdr, sizeof cmhdr)) goto out; @@ -77427,7 +79643,7 @@ diff -urNp linux-2.6.32.49/net/core/scm.c linux-2= .6.32.49/net/core/scm.c =20 int fdmax =3D 0; int fdnum =3D scm->fp->count; -@@ -249,7 +249,7 @@ void scm_detach_fds(struct msghdr *msg,=20 +@@ -249,7 +249,7 @@ void scm_detach_fds(struct msghdr *msg, struct scm_c= ookie *scm) if (fdnum < fdmax) fdmax =3D fdnum; =20 @@ -77436,10 +79652,11 @@ diff -urNp linux-2.6.32.49/net/core/scm.c linux= -2.6.32.49/net/core/scm.c i++, cmfptr++) { int new_fd; -diff -urNp linux-2.6.32.49/net/core/secure_seq.c linux-2.6.32.49/net/cor= e/secure_seq.c ---- linux-2.6.32.49/net/core/secure_seq.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/net/core/secure_seq.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -57,7 +57,7 @@ __u32 secure_tcpv6_sequence_number(__be3 +diff --git a/net/core/secure_seq.c b/net/core/secure_seq.c +index 45329d7..626aaa6 100644 +--- a/net/core/secure_seq.c ++++ b/net/core/secure_seq.c +@@ -57,7 +57,7 @@ __u32 secure_tcpv6_sequence_number(__be32 *saddr, __be= 32 *daddr, EXPORT_SYMBOL(secure_tcpv6_sequence_number); =20 u32 secure_ipv6_port_ephemeral(const __be32 *saddr, const __be32 *daddr= , @@ -77448,7 +79665,7 @@ diff -urNp linux-2.6.32.49/net/core/secure_seq.c = linux-2.6.32.49/net/core/secure { u32 secret[MD5_MESSAGE_BYTES / 4]; u32 hash[MD5_DIGEST_WORDS]; -@@ -71,7 +71,6 @@ u32 secure_ipv6_port_ephemeral(const __b +@@ -71,7 +71,6 @@ u32 secure_ipv6_port_ephemeral(const __be32 *saddr, co= nst __be32 *daddr, secret[i] =3D net_secret[i]; =20 md5_transform(hash, secret); @@ -77456,10 +79673,11 @@ diff -urNp linux-2.6.32.49/net/core/secure_seq.= c linux-2.6.32.49/net/core/secure return hash[0]; } #endif -diff -urNp linux-2.6.32.49/net/core/skbuff.c linux-2.6.32.49/net/core/sk= buff.c ---- linux-2.6.32.49/net/core/skbuff.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/core/skbuff.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -1544,6 +1544,8 @@ int skb_splice_bits(struct sk_buff *skb, +diff --git a/net/core/skbuff.c b/net/core/skbuff.c +index a807f8c..65f906f 100644 +--- a/net/core/skbuff.c ++++ b/net/core/skbuff.c +@@ -1544,6 +1544,8 @@ int skb_splice_bits(struct sk_buff *skb, unsigned = int offset, struct sk_buff *frag_iter; struct sock *sk =3D skb->sk; =20 @@ -77468,10 +79686,11 @@ diff -urNp linux-2.6.32.49/net/core/skbuff.c li= nux-2.6.32.49/net/core/skbuff.c /* * __skb_splice_bits() only fails if the output has no room left, * so no point in going over the frag_list for the error case. -diff -urNp linux-2.6.32.49/net/core/sock.c linux-2.6.32.49/net/core/sock= .c ---- linux-2.6.32.49/net/core/sock.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/core/sock.c 2011-11-15 19:59:43.000000000 -0500 -@@ -864,11 +864,15 @@ int sock_getsockopt(struct socket *sock, +diff --git a/net/core/sock.c b/net/core/sock.c +index 6605e75..3acebda 100644 +--- a/net/core/sock.c ++++ b/net/core/sock.c +@@ -864,11 +864,15 @@ int sock_getsockopt(struct socket *sock, int level= , int optname, break; =20 case SO_PEERCRED: @@ -77488,7 +79707,7 @@ diff -urNp linux-2.6.32.49/net/core/sock.c linux-= 2.6.32.49/net/core/sock.c =20 case SO_PEERNAME: { -@@ -1892,7 +1896,7 @@ void sock_init_data(struct socket *sock, +@@ -1892,7 +1896,7 @@ void sock_init_data(struct socket *sock, struct so= ck *sk) */ smp_wmb(); atomic_set(&sk->sk_refcnt, 1); @@ -77497,10 +79716,11 @@ diff -urNp linux-2.6.32.49/net/core/sock.c linu= x-2.6.32.49/net/core/sock.c } EXPORT_SYMBOL(sock_init_data); =20 -diff -urNp linux-2.6.32.49/net/decnet/sysctl_net_decnet.c linux-2.6.32.4= 9/net/decnet/sysctl_net_decnet.c ---- linux-2.6.32.49/net/decnet/sysctl_net_decnet.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/net/decnet/sysctl_net_decnet.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -206,7 +206,7 @@ static int dn_node_address_handler(ctl_t +diff --git a/net/decnet/sysctl_net_decnet.c b/net/decnet/sysctl_net_decn= et.c +index 2036568..c55883d 100644 +--- a/net/decnet/sysctl_net_decnet.c ++++ b/net/decnet/sysctl_net_decnet.c +@@ -206,7 +206,7 @@ static int dn_node_address_handler(ctl_table *table,= int write, =20 if (len > *lenp) len =3D *lenp; =20 @@ -77509,7 +79729,7 @@ diff -urNp linux-2.6.32.49/net/decnet/sysctl_net_= decnet.c linux-2.6.32.49/net/de return -EFAULT; =20 *lenp =3D len; -@@ -327,7 +327,7 @@ static int dn_def_dev_handler(ctl_table=20 +@@ -327,7 +327,7 @@ static int dn_def_dev_handler(ctl_table *table, int = write, =20 if (len > *lenp) len =3D *lenp; =20 @@ -77518,9 +79738,10 @@ diff -urNp linux-2.6.32.49/net/decnet/sysctl_net= _decnet.c linux-2.6.32.49/net/de return -EFAULT; =20 *lenp =3D len; -diff -urNp linux-2.6.32.49/net/econet/Kconfig linux-2.6.32.49/net/econet= /Kconfig ---- linux-2.6.32.49/net/econet/Kconfig 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/econet/Kconfig 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/net/econet/Kconfig b/net/econet/Kconfig +index 39a2d29..f39c0fe 100644 +--- a/net/econet/Kconfig ++++ b/net/econet/Kconfig @@ -4,7 +4,7 @@ =20 config ECONET @@ -77530,9 +79751,10 @@ diff -urNp linux-2.6.32.49/net/econet/Kconfig li= nux-2.6.32.49/net/econet/Kconfig ---help--- Econet is a fairly old and slow networking protocol mainly used by Acorn computers to access file and print servers. It uses native -diff -urNp linux-2.6.32.49/net/ieee802154/dgram.c linux-2.6.32.49/net/ie= ee802154/dgram.c ---- linux-2.6.32.49/net/ieee802154/dgram.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/ieee802154/dgram.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/net/ieee802154/dgram.c b/net/ieee802154/dgram.c +index a413b1b..380849c 100644 +--- a/net/ieee802154/dgram.c ++++ b/net/ieee802154/dgram.c @@ -318,7 +318,7 @@ out: static int dgram_rcv_skb(struct sock *sk, struct sk_buff *skb) { @@ -77542,9 +79764,10 @@ diff -urNp linux-2.6.32.49/net/ieee802154/dgram.= c linux-2.6.32.49/net/ieee802154 kfree_skb(skb); return NET_RX_DROP; } -diff -urNp linux-2.6.32.49/net/ieee802154/raw.c linux-2.6.32.49/net/ieee= 802154/raw.c ---- linux-2.6.32.49/net/ieee802154/raw.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/ieee802154/raw.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/net/ieee802154/raw.c b/net/ieee802154/raw.c +index 30e74ee..bfc6ee0 100644 +--- a/net/ieee802154/raw.c ++++ b/net/ieee802154/raw.c @@ -206,7 +206,7 @@ out: static int raw_rcv_skb(struct sock *sk, struct sk_buff *skb) { @@ -77554,10 +79777,11 @@ diff -urNp linux-2.6.32.49/net/ieee802154/raw.c= linux-2.6.32.49/net/ieee802154/r kfree_skb(skb); return NET_RX_DROP; } -diff -urNp linux-2.6.32.49/net/ipv4/inet_diag.c linux-2.6.32.49/net/ipv4= /inet_diag.c ---- linux-2.6.32.49/net/ipv4/inet_diag.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/ipv4/inet_diag.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -113,8 +113,13 @@ static int inet_csk_diag_fill(struct soc +diff --git a/net/ipv4/inet_diag.c b/net/ipv4/inet_diag.c +index dba56d2..acee5d6 100644 +--- a/net/ipv4/inet_diag.c ++++ b/net/ipv4/inet_diag.c +@@ -113,8 +113,13 @@ static int inet_csk_diag_fill(struct sock *sk, r->idiag_retrans =3D 0; =20 r->id.idiag_if =3D sk->sk_bound_dev_if; @@ -77571,7 +79795,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/inet_diag.c l= inux-2.6.32.49/net/ipv4/inet_di =20 r->id.idiag_sport =3D inet->sport; r->id.idiag_dport =3D inet->dport; -@@ -200,8 +205,15 @@ static int inet_twsk_diag_fill(struct in +@@ -200,8 +205,15 @@ static int inet_twsk_diag_fill(struct inet_timewait= _sock *tw, r->idiag_family =3D tw->tw_family; r->idiag_retrans =3D 0; r->id.idiag_if =3D tw->tw_bound_dev_if; @@ -77587,7 +79811,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/inet_diag.c l= inux-2.6.32.49/net/ipv4/inet_di r->id.idiag_sport =3D tw->tw_sport; r->id.idiag_dport =3D tw->tw_dport; r->id.idiag_src[0] =3D tw->tw_rcv_saddr; -@@ -284,12 +296,14 @@ static int inet_diag_get_exact(struct sk +@@ -284,12 +296,14 @@ static int inet_diag_get_exact(struct sk_buff *in_= skb, if (sk =3D=3D NULL) goto unlock; =20 @@ -77602,7 +79826,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/inet_diag.c l= inux-2.6.32.49/net/ipv4/inet_di =20 err =3D -ENOMEM; rep =3D alloc_skb(NLMSG_SPACE((sizeof(struct inet_diag_msg) + -@@ -579,8 +593,14 @@ static int inet_diag_fill_req(struct sk_ +@@ -579,8 +593,14 @@ static int inet_diag_fill_req(struct sk_buff *skb, = struct sock *sk, r->idiag_retrans =3D req->retrans; =20 r->id.idiag_if =3D sk->sk_bound_dev_if; @@ -77617,9 +79841,10 @@ diff -urNp linux-2.6.32.49/net/ipv4/inet_diag.c = linux-2.6.32.49/net/ipv4/inet_di =20 tmo =3D req->expires - jiffies; if (tmo < 0) -diff -urNp linux-2.6.32.49/net/ipv4/inet_hashtables.c linux-2.6.32.49/ne= t/ipv4/inet_hashtables.c ---- linux-2.6.32.49/net/ipv4/inet_hashtables.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/net/ipv4/inet_hashtables.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/net/ipv4/inet_hashtables.c b/net/ipv4/inet_hashtables.c +index d717267..56de7e7 100644 +--- a/net/ipv4/inet_hashtables.c ++++ b/net/ipv4/inet_hashtables.c @@ -18,12 +18,15 @@ #include #include @@ -77645,10 +79870,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/inet_hashta= bles.c linux-2.6.32.49/net/ipv4/i if (tw) { inet_twsk_deschedule(tw, death_row); inet_twsk_put(tw); -diff -urNp linux-2.6.32.49/net/ipv4/inetpeer.c linux-2.6.32.49/net/ipv4/= inetpeer.c ---- linux-2.6.32.49/net/ipv4/inetpeer.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/ipv4/inetpeer.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -367,6 +367,8 @@ struct inet_peer *inet_getpeer(__be32 da +diff --git a/net/ipv4/inetpeer.c b/net/ipv4/inetpeer.c +index 13b229f..6956484 100644 +--- a/net/ipv4/inetpeer.c ++++ b/net/ipv4/inetpeer.c +@@ -367,6 +367,8 @@ struct inet_peer *inet_getpeer(__be32 daddr, int cre= ate) struct inet_peer *p, *n; struct inet_peer **stack[PEER_MAXDEPTH], ***stackptr; =20 @@ -77657,7 +79883,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/inetpeer.c li= nux-2.6.32.49/net/ipv4/inetpeer /* Look up for the address quickly. */ read_lock_bh(&peer_pool_lock); p =3D lookup(daddr, NULL); -@@ -390,7 +392,7 @@ struct inet_peer *inet_getpeer(__be32 da +@@ -390,7 +392,7 @@ struct inet_peer *inet_getpeer(__be32 daddr, int cre= ate) return NULL; n->v4daddr =3D daddr; atomic_set(&n->refcnt, 1); @@ -77666,40 +79892,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/inetpeer.c = linux-2.6.32.49/net/ipv4/inetpeer n->ip_id_count =3D secure_ip_id(daddr); n->tcp_ts_stamp =3D 0; =20 -diff -urNp linux-2.6.32.49/net/ipv4/ipconfig.c linux-2.6.32.49/net/ipv4/= ipconfig.c ---- linux-2.6.32.49/net/ipv4/ipconfig.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/ipv4/ipconfig.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -295,7 +295,7 @@ static int __init ic_devinet_ioctl(unsig -=20 - mm_segment_t oldfs =3D get_fs(); - set_fs(get_ds()); -- res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __user *) arg); -+ res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __force_user *) ar= g); - set_fs(oldfs); - return res; - } -@@ -306,7 +306,7 @@ static int __init ic_dev_ioctl(unsigned=20 -=20 - mm_segment_t oldfs =3D get_fs(); - set_fs(get_ds()); -- res =3D dev_ioctl(&init_net, cmd, (struct ifreq __user *) arg); -+ res =3D dev_ioctl(&init_net, cmd, (struct ifreq __force_user *) arg); - set_fs(oldfs); - return res; - } -@@ -317,7 +317,7 @@ static int __init ic_route_ioctl(unsigne -=20 - mm_segment_t oldfs =3D get_fs(); - set_fs(get_ds()); -- res =3D ip_rt_ioctl(&init_net, cmd, (void __user *) arg); -+ res =3D ip_rt_ioctl(&init_net, cmd, (void __force_user *) arg); - set_fs(oldfs); - return res; - } -diff -urNp linux-2.6.32.49/net/ipv4/ip_fragment.c linux-2.6.32.49/net/ip= v4/ip_fragment.c ---- linux-2.6.32.49/net/ipv4/ip_fragment.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/ipv4/ip_fragment.c 2011-11-15 19:59:43.000000000= -0500 -@@ -255,7 +255,7 @@ static inline int ip_frag_too_far(struct +diff --git a/net/ipv4/ip_fragment.c b/net/ipv4/ip_fragment.c +index d3fe10b..feeafc9 100644 +--- a/net/ipv4/ip_fragment.c ++++ b/net/ipv4/ip_fragment.c +@@ -255,7 +255,7 @@ static inline int ip_frag_too_far(struct ipq *qp) return 0; =20 start =3D qp->rid; @@ -77708,10 +79905,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/ip_fragment= .c linux-2.6.32.49/net/ipv4/ip_fr qp->rid =3D end; =20 rc =3D qp->q.fragments && (end - start) > max; -diff -urNp linux-2.6.32.49/net/ipv4/ip_sockglue.c linux-2.6.32.49/net/ip= v4/ip_sockglue.c ---- linux-2.6.32.49/net/ipv4/ip_sockglue.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/ipv4/ip_sockglue.c 2011-11-15 19:59:43.000000000= -0500 -@@ -1015,6 +1015,8 @@ static int do_ip_getsockopt(struct sock=20 +diff --git a/net/ipv4/ip_sockglue.c b/net/ipv4/ip_sockglue.c +index e982b5c..f079d75 100644 +--- a/net/ipv4/ip_sockglue.c ++++ b/net/ipv4/ip_sockglue.c +@@ -1015,6 +1015,8 @@ static int do_ip_getsockopt(struct sock *sk, int l= evel, int optname, int val; int len; =20 @@ -77720,7 +79918,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/ip_sockglue.c= linux-2.6.32.49/net/ipv4/ip_so if (level !=3D SOL_IP) return -EOPNOTSUPP; =20 -@@ -1173,7 +1175,7 @@ static int do_ip_getsockopt(struct sock=20 +@@ -1173,7 +1175,7 @@ static int do_ip_getsockopt(struct sock *sk, int l= evel, int optname, if (sk->sk_type !=3D SOCK_STREAM) return -ENOPROTOOPT; =20 @@ -77729,10 +79927,42 @@ diff -urNp linux-2.6.32.49/net/ipv4/ip_sockglue= .c linux-2.6.32.49/net/ipv4/ip_so msg.msg_controllen =3D len; msg.msg_flags =3D 0; =20 -diff -urNp linux-2.6.32.49/net/ipv4/netfilter/arp_tables.c linux-2.6.32.= 49/net/ipv4/netfilter/arp_tables.c ---- linux-2.6.32.49/net/ipv4/netfilter/arp_tables.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/net/ipv4/netfilter/arp_tables.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -934,6 +934,7 @@ static int get_info(struct net *net, voi +diff --git a/net/ipv4/ipconfig.c b/net/ipv4/ipconfig.c +index f8d04c2..c1188f2 100644 +--- a/net/ipv4/ipconfig.c ++++ b/net/ipv4/ipconfig.c +@@ -295,7 +295,7 @@ static int __init ic_devinet_ioctl(unsigned int cmd,= struct ifreq *arg) +=20 + mm_segment_t oldfs =3D get_fs(); + set_fs(get_ds()); +- res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __user *) arg); ++ res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __force_user *) ar= g); + set_fs(oldfs); + return res; + } +@@ -306,7 +306,7 @@ static int __init ic_dev_ioctl(unsigned int cmd, str= uct ifreq *arg) +=20 + mm_segment_t oldfs =3D get_fs(); + set_fs(get_ds()); +- res =3D dev_ioctl(&init_net, cmd, (struct ifreq __user *) arg); ++ res =3D dev_ioctl(&init_net, cmd, (struct ifreq __force_user *) arg); + set_fs(oldfs); + return res; + } +@@ -317,7 +317,7 @@ static int __init ic_route_ioctl(unsigned int cmd, s= truct rtentry *arg) +=20 + mm_segment_t oldfs =3D get_fs(); + set_fs(get_ds()); +- res =3D ip_rt_ioctl(&init_net, cmd, (void __user *) arg); ++ res =3D ip_rt_ioctl(&init_net, cmd, (void __force_user *) arg); + set_fs(oldfs); + return res; + } +diff --git a/net/ipv4/netfilter/arp_tables.c b/net/ipv4/netfilter/arp_ta= bles.c +index c8b0cc3..4da5ae2 100644 +--- a/net/ipv4/netfilter/arp_tables.c ++++ b/net/ipv4/netfilter/arp_tables.c +@@ -934,6 +934,7 @@ static int get_info(struct net *net, void __user *us= er, int *len, int compat) private =3D &tmp; } #endif @@ -77740,10 +79970,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/netfilter/a= rp_tables.c linux-2.6.32.49/net/i info.valid_hooks =3D t->valid_hooks; memcpy(info.hook_entry, private->hook_entry, sizeof(info.hook_entry)); -diff -urNp linux-2.6.32.49/net/ipv4/netfilter/ip_queue.c linux-2.6.32.49= /net/ipv4/netfilter/ip_queue.c ---- linux-2.6.32.49/net/ipv4/netfilter/ip_queue.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/net/ipv4/netfilter/ip_queue.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -286,6 +286,9 @@ ipq_mangle_ipv4(ipq_verdict_msg_t *v, st +diff --git a/net/ipv4/netfilter/ip_queue.c b/net/ipv4/netfilter/ip_queue= .c +index c156db2..e772975 100644 +--- a/net/ipv4/netfilter/ip_queue.c ++++ b/net/ipv4/netfilter/ip_queue.c +@@ -286,6 +286,9 @@ ipq_mangle_ipv4(ipq_verdict_msg_t *v, struct nf_queu= e_entry *e) =20 if (v->data_len < sizeof(*user_iph)) return 0; @@ -77763,10 +79994,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/netfilter/i= p_queue.c linux-2.6.32.49/net/ipv struct nlmsghdr *nlh; =20 skblen =3D skb->len; -diff -urNp linux-2.6.32.49/net/ipv4/netfilter/ip_tables.c linux-2.6.32.4= 9/net/ipv4/netfilter/ip_tables.c ---- linux-2.6.32.49/net/ipv4/netfilter/ip_tables.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/net/ipv4/netfilter/ip_tables.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -1141,6 +1141,7 @@ static int get_info(struct net *net, voi +diff --git a/net/ipv4/netfilter/ip_tables.c b/net/ipv4/netfilter/ip_tabl= es.c +index 0606db1..02e7e4c 100644 +--- a/net/ipv4/netfilter/ip_tables.c ++++ b/net/ipv4/netfilter/ip_tables.c +@@ -1141,6 +1141,7 @@ static int get_info(struct net *net, void __user *= user, int *len, int compat) private =3D &tmp; } #endif @@ -77774,10 +80006,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/netfilter/i= p_tables.c linux-2.6.32.49/net/ip info.valid_hooks =3D t->valid_hooks; memcpy(info.hook_entry, private->hook_entry, sizeof(info.hook_entry)); -diff -urNp linux-2.6.32.49/net/ipv4/netfilter/nf_nat_snmp_basic.c linux-= 2.6.32.49/net/ipv4/netfilter/nf_nat_snmp_basic.c ---- linux-2.6.32.49/net/ipv4/netfilter/nf_nat_snmp_basic.c 2011-11-08 19= :02:43.000000000 -0500 -+++ linux-2.6.32.49/net/ipv4/netfilter/nf_nat_snmp_basic.c 2011-11-15 19= :59:43.000000000 -0500 -@@ -397,7 +397,7 @@ static unsigned char asn1_octets_decode( +diff --git a/net/ipv4/netfilter/nf_nat_snmp_basic.c b/net/ipv4/netfilter= /nf_nat_snmp_basic.c +index d9521f6..3c3eb25 100644 +--- a/net/ipv4/netfilter/nf_nat_snmp_basic.c ++++ b/net/ipv4/netfilter/nf_nat_snmp_basic.c +@@ -397,7 +397,7 @@ static unsigned char asn1_octets_decode(struct asn1_= ctx *ctx, =20 *len =3D 0; =20 @@ -77786,10 +80019,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/netfilter/n= f_nat_snmp_basic.c linux-2.6.32.4 if (*octets =3D=3D NULL) { if (net_ratelimit()) printk("OOM in bsalg (%d)\n", __LINE__); -diff -urNp linux-2.6.32.49/net/ipv4/raw.c linux-2.6.32.49/net/ipv4/raw.c ---- linux-2.6.32.49/net/ipv4/raw.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/ipv4/raw.c 2011-11-15 19:59:43.000000000 -0500 -@@ -292,7 +292,7 @@ static int raw_rcv_skb(struct sock * sk, +diff --git a/net/ipv4/raw.c b/net/ipv4/raw.c +index ab996f9..3da5f96 100644 +--- a/net/ipv4/raw.c ++++ b/net/ipv4/raw.c +@@ -292,7 +292,7 @@ static int raw_rcv_skb(struct sock * sk, struct sk_b= uff * skb) /* Charge it to the socket. */ =20 if (sock_queue_rcv_skb(sk, skb) < 0) { @@ -77798,7 +80032,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/raw.c linux-2= .6.32.49/net/ipv4/raw.c kfree_skb(skb); return NET_RX_DROP; } -@@ -303,7 +303,7 @@ static int raw_rcv_skb(struct sock * sk, +@@ -303,7 +303,7 @@ static int raw_rcv_skb(struct sock * sk, struct sk_b= uff * skb) int raw_rcv(struct sock *sk, struct sk_buff *skb) { if (!xfrm4_policy_check(sk, XFRM_POLICY_IN, skb)) { @@ -77832,7 +80066,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/raw.c linux-2= .6.32.49/net/ipv4/raw.c =20 if (get_user(len, optlen)) goto out; -@@ -743,8 +750,9 @@ static int raw_geticmpfilter(struct sock +@@ -743,8 +750,9 @@ static int raw_geticmpfilter(struct sock *sk, char _= _user *optval, int __user *o if (len > sizeof(struct icmp_filter)) len =3D sizeof(struct icmp_filter); ret =3D -EFAULT; @@ -77844,7 +80078,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/raw.c linux-2= .6.32.49/net/ipv4/raw.c goto out; ret =3D 0; out: return ret; -@@ -954,7 +962,13 @@ static void raw_sock_seq_show(struct seq +@@ -954,7 +962,13 @@ static void raw_sock_seq_show(struct seq_file *seq,= struct sock *sp, int i) sk_wmem_alloc_get(sp), sk_rmem_alloc_get(sp), 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -77859,10 +80093,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/raw.c linux= -2.6.32.49/net/ipv4/raw.c } =20 static int raw_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-2.6.32.49/net/ipv4/route.c linux-2.6.32.49/net/ipv4/rou= te.c ---- linux-2.6.32.49/net/ipv4/route.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/ipv4/route.c 2011-11-15 19:59:43.000000000 -0500 -@@ -269,7 +269,7 @@ static inline unsigned int rt_hash(__be3 +diff --git a/net/ipv4/route.c b/net/ipv4/route.c +index 58f141b..b759702 100644 +--- a/net/ipv4/route.c ++++ b/net/ipv4/route.c +@@ -269,7 +269,7 @@ static inline unsigned int rt_hash(__be32 daddr, __b= e32 saddr, int idx, =20 static inline int rt_genid(struct net *net) { @@ -77871,7 +80106,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/route.c linux= -2.6.32.49/net/ipv4/route.c } =20 #ifdef CONFIG_PROC_FS -@@ -889,7 +889,7 @@ static void rt_cache_invalidate(struct n +@@ -889,7 +889,7 @@ static void rt_cache_invalidate(struct net *net) unsigned char shuffle; =20 get_random_bytes(&shuffle, sizeof(shuffle)); @@ -77880,7 +80115,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/route.c linux= -2.6.32.49/net/ipv4/route.c } =20 /* -@@ -3357,7 +3357,7 @@ static __net_initdata struct pernet_oper +@@ -3357,7 +3357,7 @@ static __net_initdata struct pernet_operations sys= ctl_route_ops =3D { =20 static __net_init int rt_secret_timer_init(struct net *net) { @@ -77889,10 +80124,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/route.c lin= ux-2.6.32.49/net/ipv4/route.c (int) ((num_physpages ^ (num_physpages>>8)) ^ (jiffies ^ (jiffies >> 7)))); =20 -diff -urNp linux-2.6.32.49/net/ipv4/tcp.c linux-2.6.32.49/net/ipv4/tcp.c ---- linux-2.6.32.49/net/ipv4/tcp.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/ipv4/tcp.c 2011-11-15 19:59:43.000000000 -0500 -@@ -2085,6 +2085,8 @@ static int do_tcp_setsockopt(struct sock +diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c +index f095659..adc892a 100644 +--- a/net/ipv4/tcp.c ++++ b/net/ipv4/tcp.c +@@ -2085,6 +2085,8 @@ static int do_tcp_setsockopt(struct sock *sk, int = level, int val; int err =3D 0; =20 @@ -77901,7 +80137,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp.c linux-2= .6.32.49/net/ipv4/tcp.c /* This is a string value all the others are int's */ if (optname =3D=3D TCP_CONGESTION) { char name[TCP_CA_NAME_MAX]; -@@ -2355,6 +2357,8 @@ static int do_tcp_getsockopt(struct sock +@@ -2355,6 +2357,8 @@ static int do_tcp_getsockopt(struct sock *sk, int = level, struct tcp_sock *tp =3D tcp_sk(sk); int val, len; =20 @@ -77910,9 +80146,10 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp.c linux-= 2.6.32.49/net/ipv4/tcp.c if (get_user(len, optlen)) return -EFAULT; =20 -diff -urNp linux-2.6.32.49/net/ipv4/tcp_ipv4.c linux-2.6.32.49/net/ipv4/= tcp_ipv4.c ---- linux-2.6.32.49/net/ipv4/tcp_ipv4.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/ipv4/tcp_ipv4.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c +index 6fc7961..33bad4a 100644 +--- a/net/ipv4/tcp_ipv4.c ++++ b/net/ipv4/tcp_ipv4.c @@ -85,6 +85,9 @@ int sysctl_tcp_tw_reuse __read_mostly; int sysctl_tcp_low_latency __read_mostly; @@ -77923,7 +80160,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_ipv4.c li= nux-2.6.32.49/net/ipv4/tcp_ipv4 =20 #ifdef CONFIG_TCP_MD5SIG static struct tcp_md5sig_key *tcp_v4_md5_do_lookup(struct sock *sk, -@@ -1543,6 +1546,9 @@ int tcp_v4_do_rcv(struct sock *sk, struc +@@ -1543,6 +1546,9 @@ int tcp_v4_do_rcv(struct sock *sk, struct sk_buff = *skb) return 0; =20 reset: @@ -77967,7 +80204,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_ipv4.c li= nux-2.6.32.49/net/ipv4/tcp_ipv4 tcp_v4_send_reset(NULL, skb); } =20 -@@ -2238,7 +2256,11 @@ static void get_openreq4(struct sock *sk +@@ -2238,7 +2256,11 @@ static void get_openreq4(struct sock *sk, struct = request_sock *req, 0, /* non standard timer */ 0, /* open_requests have no inode */ atomic_read(&sk->sk_refcnt), @@ -77979,7 +80216,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_ipv4.c li= nux-2.6.32.49/net/ipv4/tcp_ipv4 len); } =20 -@@ -2280,7 +2302,12 @@ static void get_tcp4_sock(struct sock *s +@@ -2280,7 +2302,12 @@ static void get_tcp4_sock(struct sock *sk, struct= seq_file *f, int i, int *len) sock_i_uid(sk), icsk->icsk_probes_out, sock_i_ino(sk), @@ -77993,7 +80230,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_ipv4.c li= nux-2.6.32.49/net/ipv4/tcp_ipv4 jiffies_to_clock_t(icsk->icsk_rto), jiffies_to_clock_t(icsk->icsk_ack.ato), (icsk->icsk_ack.quick << 1) | icsk->icsk_ack.pingpong, -@@ -2308,7 +2335,13 @@ static void get_timewait4_sock(struct in +@@ -2308,7 +2335,13 @@ static void get_timewait4_sock(struct inet_timewa= it_sock *tw, " %02X %08X:%08X %02X:%08lX %08X %5d %8d %d %d %p%n", i, src, srcp, dest, destp, tw->tw_substate, 0, 0, 3, jiffies_to_clock_t(ttd), 0, 0, 0, 0, @@ -78008,9 +80245,10 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_ipv4.c l= inux-2.6.32.49/net/ipv4/tcp_ipv4 } =20 #define TMPSZ 150 -diff -urNp linux-2.6.32.49/net/ipv4/tcp_minisocks.c linux-2.6.32.49/net/= ipv4/tcp_minisocks.c ---- linux-2.6.32.49/net/ipv4/tcp_minisocks.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/net/ipv4/tcp_minisocks.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/net/ipv4/tcp_minisocks.c b/net/ipv4/tcp_minisocks.c +index 4c03598..e09a8e8 100644 +--- a/net/ipv4/tcp_minisocks.c ++++ b/net/ipv4/tcp_minisocks.c @@ -26,6 +26,10 @@ #include #include @@ -78033,10 +80271,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_minisoc= ks.c linux-2.6.32.49/net/ipv4/tcp if (!(flg & TCP_FLAG_RST)) req->rsk_ops->send_reset(sk, skb); =20 -diff -urNp linux-2.6.32.49/net/ipv4/tcp_output.c linux-2.6.32.49/net/ipv= 4/tcp_output.c ---- linux-2.6.32.49/net/ipv4/tcp_output.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/net/ipv4/tcp_output.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -2234,6 +2234,8 @@ struct sk_buff *tcp_make_synack(struct s +diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c +index af83bdf..ec91cb2 100644 +--- a/net/ipv4/tcp_output.c ++++ b/net/ipv4/tcp_output.c +@@ -2234,6 +2234,8 @@ struct sk_buff *tcp_make_synack(struct sock *sk, s= truct dst_entry *dst, __u8 *md5_hash_location; int mss; =20 @@ -78045,10 +80284,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_output.= c linux-2.6.32.49/net/ipv4/tcp_ou skb =3D sock_wmalloc(sk, MAX_TCP_HEADER + 15, 1, GFP_ATOMIC); if (skb =3D=3D NULL) return NULL; -diff -urNp linux-2.6.32.49/net/ipv4/tcp_probe.c linux-2.6.32.49/net/ipv4= /tcp_probe.c ---- linux-2.6.32.49/net/ipv4/tcp_probe.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/ipv4/tcp_probe.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -200,7 +200,7 @@ static ssize_t tcpprobe_read(struct file +diff --git a/net/ipv4/tcp_probe.c b/net/ipv4/tcp_probe.c +index 59f5b5e..193860f 100644 +--- a/net/ipv4/tcp_probe.c ++++ b/net/ipv4/tcp_probe.c +@@ -200,7 +200,7 @@ static ssize_t tcpprobe_read(struct file *file, char= __user *buf, if (cnt + width >=3D len) break; =20 @@ -78057,9 +80297,10 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_probe.c = linux-2.6.32.49/net/ipv4/tcp_pro return -EFAULT; cnt +=3D width; } -diff -urNp linux-2.6.32.49/net/ipv4/tcp_timer.c linux-2.6.32.49/net/ipv4= /tcp_timer.c ---- linux-2.6.32.49/net/ipv4/tcp_timer.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/ipv4/tcp_timer.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/net/ipv4/tcp_timer.c b/net/ipv4/tcp_timer.c +index 57d5501..a9ed13a 100644 +--- a/net/ipv4/tcp_timer.c ++++ b/net/ipv4/tcp_timer.c @@ -21,6 +21,10 @@ #include #include @@ -78071,7 +80312,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_timer.c l= inux-2.6.32.49/net/ipv4/tcp_tim int sysctl_tcp_syn_retries __read_mostly =3D TCP_SYN_RETRIES; int sysctl_tcp_synack_retries __read_mostly =3D TCP_SYNACK_RETRIES; int sysctl_tcp_keepalive_time __read_mostly =3D TCP_KEEPALIVE_TIME; -@@ -164,6 +168,13 @@ static int tcp_write_timeout(struct sock +@@ -164,6 +168,13 @@ static int tcp_write_timeout(struct sock *sk) } } =20 @@ -78085,9 +80326,10 @@ diff -urNp linux-2.6.32.49/net/ipv4/tcp_timer.c = linux-2.6.32.49/net/ipv4/tcp_tim if (retransmits_timed_out(sk, retry_until)) { /* Has it gone just too far? */ tcp_write_err(sk); -diff -urNp linux-2.6.32.49/net/ipv4/udp.c linux-2.6.32.49/net/ipv4/udp.c ---- linux-2.6.32.49/net/ipv4/udp.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/ipv4/udp.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c +index 0ac8833..58d8c43 100644 +--- a/net/ipv4/udp.c ++++ b/net/ipv4/udp.c @@ -86,6 +86,7 @@ #include #include @@ -78117,7 +80359,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/udp.c linux-2= .6.32.49/net/ipv4/udp.c /* * This routine is called by the ICMP module when it gets some * sort of error condition. If err < 0 then the socket should -@@ -639,9 +647,18 @@ int udp_sendmsg(struct kiocb *iocb, stru +@@ -639,9 +647,18 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk= , struct msghdr *msg, dport =3D usin->sin_port; if (dport =3D=3D 0) return -EINVAL; @@ -78147,7 +80389,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/udp.c linux-2= .6.32.49/net/ipv4/udp.c ulen =3D skb->len - sizeof(struct udphdr); copied =3D len; if (copied > ulen) -@@ -1068,7 +1089,7 @@ static int __udp_queue_rcv_skb(struct so +@@ -1068,7 +1089,7 @@ static int __udp_queue_rcv_skb(struct sock *sk, st= ruct sk_buff *skb) if (rc =3D=3D -ENOMEM) { UDP_INC_STATS_BH(sock_net(sk), UDP_MIB_RCVBUFERRORS, is_udplite); @@ -78156,7 +80398,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/udp.c linux-2= .6.32.49/net/ipv4/udp.c } goto drop; } -@@ -1338,6 +1359,9 @@ int __udp4_lib_rcv(struct sk_buff *skb,=20 +@@ -1338,6 +1359,9 @@ int __udp4_lib_rcv(struct sk_buff *skb, struct udp= _table *udptable, goto csum_error; =20 UDP_INC_STATS_BH(net, UDP_MIB_NOPORTS, proto =3D=3D IPPROTO_UDPLITE); @@ -78166,7 +80408,7 @@ diff -urNp linux-2.6.32.49/net/ipv4/udp.c linux-2= .6.32.49/net/ipv4/udp.c icmp_send(skb, ICMP_DEST_UNREACH, ICMP_PORT_UNREACH, 0); =20 /* -@@ -1758,8 +1782,13 @@ static void udp4_format_sock(struct sock +@@ -1758,8 +1782,13 @@ static void udp4_format_sock(struct sock *sp, str= uct seq_file *f, sk_wmem_alloc_get(sp), sk_rmem_alloc_get(sp), 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -78182,10 +80424,11 @@ diff -urNp linux-2.6.32.49/net/ipv4/udp.c linux= -2.6.32.49/net/ipv4/udp.c } =20 int udp4_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-2.6.32.49/net/ipv6/addrconf.c linux-2.6.32.49/net/ipv6/= addrconf.c ---- linux-2.6.32.49/net/ipv6/addrconf.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/ipv6/addrconf.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -2053,7 +2053,7 @@ int addrconf_set_dstaddr(struct net *net +diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c +index 8ac3d09..fc58c5f 100644 +--- a/net/ipv6/addrconf.c ++++ b/net/ipv6/addrconf.c +@@ -2053,7 +2053,7 @@ int addrconf_set_dstaddr(struct net *net, void __u= ser *arg) p.iph.ihl =3D 5; p.iph.protocol =3D IPPROTO_IPV6; p.iph.ttl =3D 64; @@ -78194,10 +80437,11 @@ diff -urNp linux-2.6.32.49/net/ipv6/addrconf.c = linux-2.6.32.49/net/ipv6/addrconf =20 if (ops->ndo_do_ioctl) { mm_segment_t oldfs =3D get_fs(); -diff -urNp linux-2.6.32.49/net/ipv6/inet6_connection_sock.c linux-2.6.32= .49/net/ipv6/inet6_connection_sock.c ---- linux-2.6.32.49/net/ipv6/inet6_connection_sock.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/net/ipv6/inet6_connection_sock.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -152,7 +152,7 @@ void __inet6_csk_dst_store(struct sock * +diff --git a/net/ipv6/inet6_connection_sock.c b/net/ipv6/inet6_connectio= n_sock.c +index cc4797d..7cfdfcc 100644 +--- a/net/ipv6/inet6_connection_sock.c ++++ b/net/ipv6/inet6_connection_sock.c +@@ -152,7 +152,7 @@ void __inet6_csk_dst_store(struct sock *sk, struct d= st_entry *dst, #ifdef CONFIG_XFRM { struct rt6_info *rt =3D (struct rt6_info *)dst; @@ -78206,7 +80450,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/inet6_connect= ion_sock.c linux-2.6.32.49/net/ } #endif } -@@ -167,7 +167,7 @@ struct dst_entry *__inet6_csk_dst_check( +@@ -167,7 +167,7 @@ struct dst_entry *__inet6_csk_dst_check(struct sock = *sk, u32 cookie) #ifdef CONFIG_XFRM if (dst) { struct rt6_info *rt =3D (struct rt6_info *)dst; @@ -78215,9 +80459,10 @@ diff -urNp linux-2.6.32.49/net/ipv6/inet6_connec= tion_sock.c linux-2.6.32.49/net/ sk->sk_dst_cache =3D NULL; dst_release(dst); dst =3D NULL; -diff -urNp linux-2.6.32.49/net/ipv6/inet6_hashtables.c linux-2.6.32.49/n= et/ipv6/inet6_hashtables.c ---- linux-2.6.32.49/net/ipv6/inet6_hashtables.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/net/ipv6/inet6_hashtables.c 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/net/ipv6/inet6_hashtables.c b/net/ipv6/inet6_hashtables.c +index 093e9b2..f72cddb 100644 +--- a/net/ipv6/inet6_hashtables.c ++++ b/net/ipv6/inet6_hashtables.c @@ -119,7 +119,7 @@ out: } EXPORT_SYMBOL(__inet6_lookup_established); @@ -78227,10 +80472,11 @@ diff -urNp linux-2.6.32.49/net/ipv6/inet6_hasht= ables.c linux-2.6.32.49/net/ipv6/ const unsigned short hnum, const struct in6_addr *daddr, const int dif) -diff -urNp linux-2.6.32.49/net/ipv6/ipv6_sockglue.c linux-2.6.32.49/net/= ipv6/ipv6_sockglue.c ---- linux-2.6.32.49/net/ipv6/ipv6_sockglue.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/net/ipv6/ipv6_sockglue.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -130,6 +130,8 @@ static int do_ipv6_setsockopt(struct soc +diff --git a/net/ipv6/ipv6_sockglue.c b/net/ipv6/ipv6_sockglue.c +index 4f7aaf6..f7acf45 100644 +--- a/net/ipv6/ipv6_sockglue.c ++++ b/net/ipv6/ipv6_sockglue.c +@@ -130,6 +130,8 @@ static int do_ipv6_setsockopt(struct sock *sk, int l= evel, int optname, int val, valbool; int retv =3D -ENOPROTOOPT; =20 @@ -78239,7 +80485,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/ipv6_sockglue= .c linux-2.6.32.49/net/ipv6/ipv if (optval =3D=3D NULL) val=3D0; else { -@@ -881,6 +883,8 @@ static int do_ipv6_getsockopt(struct soc +@@ -881,6 +883,8 @@ static int do_ipv6_getsockopt(struct sock *sk, int l= evel, int optname, int len; int val; =20 @@ -78248,7 +80494,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/ipv6_sockglue= .c linux-2.6.32.49/net/ipv6/ipv if (ip6_mroute_opt(optname)) return ip6_mroute_getsockopt(sk, optname, optval, optlen); =20 -@@ -922,7 +926,7 @@ static int do_ipv6_getsockopt(struct soc +@@ -922,7 +926,7 @@ static int do_ipv6_getsockopt(struct sock *sk, int l= evel, int optname, if (sk->sk_type !=3D SOCK_STREAM) return -ENOPROTOOPT; =20 @@ -78257,10 +80503,11 @@ diff -urNp linux-2.6.32.49/net/ipv6/ipv6_sockgl= ue.c linux-2.6.32.49/net/ipv6/ipv msg.msg_controllen =3D len; msg.msg_flags =3D 0; =20 -diff -urNp linux-2.6.32.49/net/ipv6/netfilter/ip6_queue.c linux-2.6.32.4= 9/net/ipv6/netfilter/ip6_queue.c ---- linux-2.6.32.49/net/ipv6/netfilter/ip6_queue.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/net/ipv6/netfilter/ip6_queue.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -287,6 +287,9 @@ ipq_mangle_ipv6(ipq_verdict_msg_t *v, st +diff --git a/net/ipv6/netfilter/ip6_queue.c b/net/ipv6/netfilter/ip6_que= ue.c +index 1cf3f0c..1d4376f 100644 +--- a/net/ipv6/netfilter/ip6_queue.c ++++ b/net/ipv6/netfilter/ip6_queue.c +@@ -287,6 +287,9 @@ ipq_mangle_ipv6(ipq_verdict_msg_t *v, struct nf_queu= e_entry *e) =20 if (v->data_len < sizeof(*user_iph)) return 0; @@ -78280,10 +80527,11 @@ diff -urNp linux-2.6.32.49/net/ipv6/netfilter/i= p6_queue.c linux-2.6.32.49/net/ip struct nlmsghdr *nlh; =20 skblen =3D skb->len; -diff -urNp linux-2.6.32.49/net/ipv6/netfilter/ip6_tables.c linux-2.6.32.= 49/net/ipv6/netfilter/ip6_tables.c ---- linux-2.6.32.49/net/ipv6/netfilter/ip6_tables.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/net/ipv6/netfilter/ip6_tables.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -1173,6 +1173,7 @@ static int get_info(struct net *net, voi +diff --git a/net/ipv6/netfilter/ip6_tables.c b/net/ipv6/netfilter/ip6_ta= bles.c +index 78b5a36..7f37433 100644 +--- a/net/ipv6/netfilter/ip6_tables.c ++++ b/net/ipv6/netfilter/ip6_tables.c +@@ -1173,6 +1173,7 @@ static int get_info(struct net *net, void __user *= user, int *len, int compat) private =3D &tmp; } #endif @@ -78291,10 +80539,11 @@ diff -urNp linux-2.6.32.49/net/ipv6/netfilter/i= p6_tables.c linux-2.6.32.49/net/i info.valid_hooks =3D t->valid_hooks; memcpy(info.hook_entry, private->hook_entry, sizeof(info.hook_entry)); -diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux-2.6.32.49/net/ipv6/raw.c ---- linux-2.6.32.49/net/ipv6/raw.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/ipv6/raw.c 2011-11-15 19:59:43.000000000 -0500 -@@ -375,14 +375,14 @@ static inline int rawv6_rcv_skb(struct s +diff --git a/net/ipv6/raw.c b/net/ipv6/raw.c +index 4f24570..b813b34 100644 +--- a/net/ipv6/raw.c ++++ b/net/ipv6/raw.c +@@ -375,14 +375,14 @@ static inline int rawv6_rcv_skb(struct sock * sk, = struct sk_buff * skb) { if ((raw6_sk(sk)->checksum || sk->sk_filter) && skb_checksum_complete(skb)) { @@ -78311,7 +80560,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux-2= .6.32.49/net/ipv6/raw.c kfree_skb(skb); return NET_RX_DROP; } -@@ -403,7 +403,7 @@ int rawv6_rcv(struct sock *sk, struct sk +@@ -403,7 +403,7 @@ int rawv6_rcv(struct sock *sk, struct sk_buff *skb) struct raw6_sock *rp =3D raw6_sk(sk); =20 if (!xfrm6_policy_check(sk, XFRM_POLICY_IN, skb)) { @@ -78320,7 +80569,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux-2= .6.32.49/net/ipv6/raw.c kfree_skb(skb); return NET_RX_DROP; } -@@ -427,7 +427,7 @@ int rawv6_rcv(struct sock *sk, struct sk +@@ -427,7 +427,7 @@ int rawv6_rcv(struct sock *sk, struct sk_buff *skb) =20 if (inet->hdrincl) { if (skb_checksum_complete(skb)) { @@ -78347,7 +80596,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux-2= .6.32.49/net/ipv6/raw.c struct flowi *fl, struct rt6_info *rt, unsigned int flags) { -@@ -738,6 +738,8 @@ static int rawv6_sendmsg(struct kiocb *i +@@ -738,6 +738,8 @@ static int rawv6_sendmsg(struct kiocb *iocb, struct = sock *sk, u16 proto; int err; =20 @@ -78375,7 +80624,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux-2= .6.32.49/net/ipv6/raw.c return 0; default: return -ENOPROTOOPT; -@@ -934,6 +941,7 @@ static int rawv6_geticmpfilter(struct so +@@ -934,6 +941,7 @@ static int rawv6_geticmpfilter(struct sock *sk, int = level, int optname, char __user *optval, int __user *optlen) { int len; @@ -78383,7 +80632,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux-2= .6.32.49/net/ipv6/raw.c =20 switch (optname) { case ICMPV6_FILTER: -@@ -945,7 +953,8 @@ static int rawv6_geticmpfilter(struct so +@@ -945,7 +953,8 @@ static int rawv6_geticmpfilter(struct sock *sk, int = level, int optname, len =3D sizeof(struct icmp6_filter); if (put_user(len, optlen)) return -EFAULT; @@ -78393,7 +80642,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux-2= .6.32.49/net/ipv6/raw.c return -EFAULT; return 0; default: -@@ -1241,7 +1250,13 @@ static void raw6_sock_seq_show(struct se +@@ -1241,7 +1250,13 @@ static void raw6_sock_seq_show(struct seq_file *s= eq, struct sock *sp, int i) 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -78408,10 +80657,11 @@ diff -urNp linux-2.6.32.49/net/ipv6/raw.c linux= -2.6.32.49/net/ipv6/raw.c } =20 static int raw6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-2.6.32.49/net/ipv6/tcp_ipv6.c linux-2.6.32.49/net/ipv6/= tcp_ipv6.c ---- linux-2.6.32.49/net/ipv6/tcp_ipv6.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/ipv6/tcp_ipv6.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -89,6 +89,10 @@ static struct tcp_md5sig_key *tcp_v6_md5 +diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c +index faae6df..d4430c1 100644 +--- a/net/ipv6/tcp_ipv6.c ++++ b/net/ipv6/tcp_ipv6.c +@@ -89,6 +89,10 @@ static struct tcp_md5sig_key *tcp_v6_md5_do_lookup(st= ruct sock *sk, } #endif =20 @@ -78422,7 +80672,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/tcp_ipv6.c li= nux-2.6.32.49/net/ipv6/tcp_ipv6 static void tcp_v6_hash(struct sock *sk) { if (sk->sk_state !=3D TCP_CLOSE) { -@@ -1579,6 +1583,9 @@ static int tcp_v6_do_rcv(struct sock *sk +@@ -1579,6 +1583,9 @@ static int tcp_v6_do_rcv(struct sock *sk, struct s= k_buff *skb) return 0; =20 reset: @@ -78432,7 +80682,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/tcp_ipv6.c li= nux-2.6.32.49/net/ipv6/tcp_ipv6 tcp_v6_send_reset(sk, skb); discard: if (opt_skb) -@@ -1656,12 +1663,20 @@ static int tcp_v6_rcv(struct sk_buff *sk +@@ -1656,12 +1663,20 @@ static int tcp_v6_rcv(struct sk_buff *skb) TCP_SKB_CB(skb)->sacked =3D 0; =20 sk =3D __inet6_lookup_skb(&tcp_hashinfo, skb, th->source, th->dest); @@ -78466,7 +80716,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/tcp_ipv6.c li= nux-2.6.32.49/net/ipv6/tcp_ipv6 tcp_v6_send_reset(NULL, skb); } =20 -@@ -1916,7 +1935,13 @@ static void get_openreq6(struct seq_file +@@ -1916,7 +1935,13 @@ static void get_openreq6(struct seq_file *seq, uid, 0, /* non standard timer */ 0, /* open_requests have no inode */ @@ -78481,7 +80731,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/tcp_ipv6.c li= nux-2.6.32.49/net/ipv6/tcp_ipv6 } =20 static void get_tcp6_sock(struct seq_file *seq, struct sock *sp, int i) -@@ -1966,7 +1991,12 @@ static void get_tcp6_sock(struct seq_fil +@@ -1966,7 +1991,12 @@ static void get_tcp6_sock(struct seq_file *seq, s= truct sock *sp, int i) sock_i_uid(sp), icsk->icsk_probes_out, sock_i_ino(sp), @@ -78495,7 +80745,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/tcp_ipv6.c li= nux-2.6.32.49/net/ipv6/tcp_ipv6 jiffies_to_clock_t(icsk->icsk_rto), jiffies_to_clock_t(icsk->icsk_ack.ato), (icsk->icsk_ack.quick << 1 ) | icsk->icsk_ack.pingpong, -@@ -2001,7 +2031,13 @@ static void get_timewait6_sock(struct se +@@ -2001,7 +2031,13 @@ static void get_timewait6_sock(struct seq_file *s= eq, dest->s6_addr32[2], dest->s6_addr32[3], destp, tw->tw_substate, 0, 0, 3, jiffies_to_clock_t(ttd), 0, 0, 0, 0, @@ -78510,9 +80760,10 @@ diff -urNp linux-2.6.32.49/net/ipv6/tcp_ipv6.c l= inux-2.6.32.49/net/ipv6/tcp_ipv6 } =20 static int tcp6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-2.6.32.49/net/ipv6/udp.c linux-2.6.32.49/net/ipv6/udp.c ---- linux-2.6.32.49/net/ipv6/udp.c 2011-11-26 19:44:53.000000000 -0500 -+++ linux-2.6.32.49/net/ipv6/udp.c 2011-11-26 19:45:13.000000000 -0500 +diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c +index 9cc6289..052c521 100644 +--- a/net/ipv6/udp.c ++++ b/net/ipv6/udp.c @@ -49,6 +49,10 @@ #include #include "udp_impl.h" @@ -78524,7 +80775,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/udp.c linux-2= .6.32.49/net/ipv6/udp.c int ipv6_rcv_saddr_equal(const struct sock *sk, const struct sock *sk2) { const struct in6_addr *sk_rcv_saddr6 =3D &inet6_sk(sk)->rcv_saddr; -@@ -391,7 +395,7 @@ int udpv6_queue_rcv_skb(struct sock * sk +@@ -391,7 +395,7 @@ int udpv6_queue_rcv_skb(struct sock * sk, struct sk_= buff *skb) if (rc =3D=3D -ENOMEM) { UDP6_INC_STATS_BH(sock_net(sk), UDP_MIB_RCVBUFERRORS, is_udplite); @@ -78533,7 +80784,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/udp.c linux-2= .6.32.49/net/ipv6/udp.c } goto drop; } -@@ -590,6 +594,9 @@ int __udp6_lib_rcv(struct sk_buff *skb,=20 +@@ -590,6 +594,9 @@ int __udp6_lib_rcv(struct sk_buff *skb, struct udp_t= able *udptable, UDP6_INC_STATS_BH(net, UDP_MIB_NOPORTS, proto =3D=3D IPPROTO_UDPLITE); =20 @@ -78543,7 +80794,7 @@ diff -urNp linux-2.6.32.49/net/ipv6/udp.c linux-2= .6.32.49/net/ipv6/udp.c icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_PORT_UNREACH, 0, dev); =20 kfree_skb(skb); -@@ -1209,8 +1216,13 @@ static void udp6_sock_seq_show(struct se +@@ -1209,8 +1216,13 @@ static void udp6_sock_seq_show(struct seq_file *s= eq, struct sock *sp, int bucket 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -78559,10 +80810,11 @@ diff -urNp linux-2.6.32.49/net/ipv6/udp.c linux= -2.6.32.49/net/ipv6/udp.c } =20 int udp6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm_tty.c linux-2.6.32.49/= net/irda/ircomm/ircomm_tty.c ---- linux-2.6.32.49/net/irda/ircomm/ircomm_tty.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/net/irda/ircomm/ircomm_tty.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -280,16 +280,16 @@ static int ircomm_tty_block_til_ready(st +diff --git a/net/irda/ircomm/ircomm_tty.c b/net/irda/ircomm/ircomm_tty.c +index 811984d..11f59b7 100644 +--- a/net/irda/ircomm/ircomm_tty.c ++++ b/net/irda/ircomm/ircomm_tty.c +@@ -280,16 +280,16 @@ static int ircomm_tty_block_til_ready(struct ircom= m_tty_cb *self, add_wait_queue(&self->open_wait, &wait); =20 IRDA_DEBUG(2, "%s(%d):block_til_ready before block on %s open_count=3D= %d\n", @@ -78582,7 +80834,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda =20 while (1) { if (tty->termios->c_cflag & CBAUD) { -@@ -329,7 +329,7 @@ static int ircomm_tty_block_til_ready(st +@@ -329,7 +329,7 @@ static int ircomm_tty_block_til_ready(struct ircomm_= tty_cb *self, } =20 IRDA_DEBUG(1, "%s(%d):block_til_ready blocking on %s open_count=3D%d\= n", @@ -78591,7 +80843,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda =20 schedule(); } -@@ -340,13 +340,13 @@ static int ircomm_tty_block_til_ready(st +@@ -340,13 +340,13 @@ static int ircomm_tty_block_til_ready(struct ircom= m_tty_cb *self, if (extra_count) { /* ++ is not atomic, so this should be protected - Jean II */ spin_lock_irqsave(&self->spinlock, flags); @@ -78608,7 +80860,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda =20 if (!retval) self->flags |=3D ASYNC_NORMAL_ACTIVE; -@@ -415,14 +415,14 @@ static int ircomm_tty_open(struct tty_st +@@ -415,14 +415,14 @@ static int ircomm_tty_open(struct tty_struct *tty,= struct file *filp) } /* ++ is not atomic, so this should be protected - Jean II */ spin_lock_irqsave(&self->spinlock, flags); @@ -78625,7 +80877,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda =20 /* Not really used by us, but lets do it anyway */ self->tty->low_latency =3D (self->flags & ASYNC_LOW_LATENCY) ? 1 : 0; -@@ -511,7 +511,7 @@ static void ircomm_tty_close(struct tty_ +@@ -511,7 +511,7 @@ static void ircomm_tty_close(struct tty_struct *tty,= struct file *filp) return; } =20 @@ -78634,7 +80886,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda /* * Uh, oh. tty->count is 1, which means that the tty * structure will be freed. state->count should always -@@ -521,16 +521,16 @@ static void ircomm_tty_close(struct tty_ +@@ -521,16 +521,16 @@ static void ircomm_tty_close(struct tty_struct *tt= y, struct file *filp) */ IRDA_DEBUG(0, "%s(), bad serial port count; " "tty->count is 1, state->count is %d\n", __func__ , @@ -78657,7 +80909,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda spin_unlock_irqrestore(&self->spinlock, flags); =20 IRDA_DEBUG(0, "%s(), open count > 0\n", __func__ ); -@@ -562,7 +562,7 @@ static void ircomm_tty_close(struct tty_ +@@ -562,7 +562,7 @@ static void ircomm_tty_close(struct tty_struct *tty,= struct file *filp) tty->closing =3D 0; self->tty =3D NULL; =20 @@ -78666,7 +80918,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda if (self->close_delay) schedule_timeout_interruptible(self->close_delay); wake_up_interruptible(&self->open_wait); -@@ -1017,7 +1017,7 @@ static void ircomm_tty_hangup(struct tty +@@ -1017,7 +1017,7 @@ static void ircomm_tty_hangup(struct tty_struct *t= ty) spin_lock_irqsave(&self->spinlock, flags); self->flags &=3D ~ASYNC_NORMAL_ACTIVE; self->tty =3D NULL; @@ -78675,7 +80927,7 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/ircomm= _tty.c linux-2.6.32.49/net/irda spin_unlock_irqrestore(&self->spinlock, flags); =20 wake_up_interruptible(&self->open_wait); -@@ -1369,7 +1369,7 @@ static void ircomm_tty_line_info(struct=20 +@@ -1369,7 +1369,7 @@ static void ircomm_tty_line_info(struct ircomm_tty= _cb *self, struct seq_file *m) seq_putc(m, '\n'); =20 seq_printf(m, "Role: %s\n", self->client ? "client" : "server"); @@ -78684,10 +80936,11 @@ diff -urNp linux-2.6.32.49/net/irda/ircomm/irco= mm_tty.c linux-2.6.32.49/net/irda seq_printf(m, "Max data size: %d\n", self->max_data_size); seq_printf(m, "Max header size: %d\n", self->max_header_size); =20 -diff -urNp linux-2.6.32.49/net/iucv/af_iucv.c linux-2.6.32.49/net/iucv/a= f_iucv.c ---- linux-2.6.32.49/net/iucv/af_iucv.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/iucv/af_iucv.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -651,10 +651,10 @@ static int iucv_sock_autobind(struct soc +diff --git a/net/iucv/af_iucv.c b/net/iucv/af_iucv.c +index bada1b9..f325943 100644 +--- a/net/iucv/af_iucv.c ++++ b/net/iucv/af_iucv.c +@@ -651,10 +651,10 @@ static int iucv_sock_autobind(struct sock *sk) =20 write_lock_bh(&iucv_sk_list.lock); =20 @@ -78700,10 +80953,11 @@ diff -urNp linux-2.6.32.49/net/iucv/af_iucv.c l= inux-2.6.32.49/net/iucv/af_iucv.c } =20 write_unlock_bh(&iucv_sk_list.lock); -diff -urNp linux-2.6.32.49/net/key/af_key.c linux-2.6.32.49/net/key/af_k= ey.c ---- linux-2.6.32.49/net/key/af_key.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/key/af_key.c 2011-11-15 19:59:43.000000000 -0500 -@@ -2489,6 +2489,8 @@ static int pfkey_migrate(struct sock *sk +diff --git a/net/key/af_key.c b/net/key/af_key.c +index 4e98193..439b449 100644 +--- a/net/key/af_key.c ++++ b/net/key/af_key.c +@@ -2489,6 +2489,8 @@ static int pfkey_migrate(struct sock *sk, struct s= k_buff *skb, struct xfrm_migrate m[XFRM_MAX_DEPTH]; struct xfrm_kmaddress k; =20 @@ -78712,7 +80966,7 @@ diff -urNp linux-2.6.32.49/net/key/af_key.c linux= -2.6.32.49/net/key/af_key.c if (!present_and_same_family(ext_hdrs[SADB_EXT_ADDRESS_SRC - 1], ext_hdrs[SADB_EXT_ADDRESS_DST - 1]) || !ext_hdrs[SADB_X_EXT_POLICY - 1]) { -@@ -3660,7 +3662,11 @@ static int pfkey_seq_show(struct seq_fil +@@ -3660,7 +3662,11 @@ static int pfkey_seq_show(struct seq_file *f, voi= d *v) seq_printf(f ,"sk RefCnt Rmem Wmem User Inode\n"); else seq_printf(f ,"%p %-6d %-6u %-6u %-6u %-6lu\n", @@ -78724,10 +80978,11 @@ diff -urNp linux-2.6.32.49/net/key/af_key.c lin= ux-2.6.32.49/net/key/af_key.c atomic_read(&s->sk_refcnt), sk_rmem_alloc_get(s), sk_wmem_alloc_get(s), -diff -urNp linux-2.6.32.49/net/lapb/lapb_iface.c linux-2.6.32.49/net/lap= b/lapb_iface.c ---- linux-2.6.32.49/net/lapb/lapb_iface.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/net/lapb/lapb_iface.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -157,7 +157,7 @@ int lapb_register(struct net_device *dev +diff --git a/net/lapb/lapb_iface.c b/net/lapb/lapb_iface.c +index bda96d1..c038b72 100644 +--- a/net/lapb/lapb_iface.c ++++ b/net/lapb/lapb_iface.c +@@ -157,7 +157,7 @@ int lapb_register(struct net_device *dev, struct lap= b_register_struct *callbacks goto out; =20 lapb->dev =3D dev; @@ -78736,7 +80991,7 @@ diff -urNp linux-2.6.32.49/net/lapb/lapb_iface.c = linux-2.6.32.49/net/lapb/lapb_i =20 __lapb_insert_cb(lapb); =20 -@@ -379,32 +379,32 @@ int lapb_data_received(struct net_device +@@ -379,32 +379,32 @@ int lapb_data_received(struct net_device *dev, str= uct sk_buff *skb) =20 void lapb_connect_confirmation(struct lapb_cb *lapb, int reason) { @@ -78779,7 +81034,7 @@ diff -urNp linux-2.6.32.49/net/lapb/lapb_iface.c = linux-2.6.32.49/net/lapb/lapb_i =20 kfree_skb(skb); return NET_RX_SUCCESS; /* For now; must be !=3D NET_RX_DROP */ -@@ -414,8 +414,8 @@ int lapb_data_transmit(struct lapb_cb *l +@@ -414,8 +414,8 @@ int lapb_data_transmit(struct lapb_cb *lapb, struct = sk_buff *skb) { int used =3D 0; =20 @@ -78790,10 +81045,11 @@ diff -urNp linux-2.6.32.49/net/lapb/lapb_iface.= c linux-2.6.32.49/net/lapb/lapb_i used =3D 1; } =20 -diff -urNp linux-2.6.32.49/net/mac80211/cfg.c linux-2.6.32.49/net/mac802= 11/cfg.c ---- linux-2.6.32.49/net/mac80211/cfg.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/mac80211/cfg.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -1369,7 +1369,7 @@ static int ieee80211_set_bitrate_mask(st +diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c +index fe2d3f8..e57f683 100644 +--- a/net/mac80211/cfg.c ++++ b/net/mac80211/cfg.c +@@ -1369,7 +1369,7 @@ static int ieee80211_set_bitrate_mask(struct wiphy= *wiphy, return err; } =20 @@ -78802,9 +81058,10 @@ diff -urNp linux-2.6.32.49/net/mac80211/cfg.c li= nux-2.6.32.49/net/mac80211/cfg.c .add_virtual_intf =3D ieee80211_add_iface, .del_virtual_intf =3D ieee80211_del_iface, .change_virtual_intf =3D ieee80211_change_iface, -diff -urNp linux-2.6.32.49/net/mac80211/cfg.h linux-2.6.32.49/net/mac802= 11/cfg.h ---- linux-2.6.32.49/net/mac80211/cfg.h 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/mac80211/cfg.h 2011-11-15 19:59:43.000000000 -05= 00 +diff --git a/net/mac80211/cfg.h b/net/mac80211/cfg.h +index 7d7879f..2d51f62 100644 +--- a/net/mac80211/cfg.h ++++ b/net/mac80211/cfg.h @@ -4,6 +4,6 @@ #ifndef __CFG_H #define __CFG_H @@ -78813,10 +81070,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/cfg.h l= inux-2.6.32.49/net/mac80211/cfg.h +extern const struct cfg80211_ops mac80211_config_ops; =20 #endif /* __CFG_H */ -diff -urNp linux-2.6.32.49/net/mac80211/debugfs_key.c linux-2.6.32.49/ne= t/mac80211/debugfs_key.c ---- linux-2.6.32.49/net/mac80211/debugfs_key.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/net/mac80211/debugfs_key.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -211,9 +211,13 @@ static ssize_t key_key_read(struct file=20 +diff --git a/net/mac80211/debugfs_key.c b/net/mac80211/debugfs_key.c +index 99c7525..9cb4937 100644 +--- a/net/mac80211/debugfs_key.c ++++ b/net/mac80211/debugfs_key.c +@@ -211,9 +211,13 @@ static ssize_t key_key_read(struct file *file, char= __user *userbuf, size_t count, loff_t *ppos) { struct ieee80211_key *key =3D file->private_data; @@ -78831,10 +81089,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/debugfs= _key.c linux-2.6.32.49/net/mac802 =20 for (i =3D 0; i < key->conf.keylen; i++) p +=3D scnprintf(p, bufsize + buf - p, "%02x", key->conf.key[i]); -diff -urNp linux-2.6.32.49/net/mac80211/debugfs_sta.c linux-2.6.32.49/ne= t/mac80211/debugfs_sta.c ---- linux-2.6.32.49/net/mac80211/debugfs_sta.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/net/mac80211/debugfs_sta.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -124,6 +124,8 @@ static ssize_t sta_agg_status_read(struc +diff --git a/net/mac80211/debugfs_sta.c b/net/mac80211/debugfs_sta.c +index 33a2e89..08650c8 100644 +--- a/net/mac80211/debugfs_sta.c ++++ b/net/mac80211/debugfs_sta.c +@@ -124,6 +124,8 @@ static ssize_t sta_agg_status_read(struct file *file= , char __user *userbuf, int i; struct sta_info *sta =3D file->private_data; =20 @@ -78843,9 +81102,10 @@ diff -urNp linux-2.6.32.49/net/mac80211/debugfs_= sta.c linux-2.6.32.49/net/mac802 spin_lock_bh(&sta->lock); p +=3D scnprintf(p, sizeof(buf)+buf-p, "next dialog_token is %#02x\n", sta->ampdu_mlme.dialog_token_allocator + 1); -diff -urNp linux-2.6.32.49/net/mac80211/ieee80211_i.h linux-2.6.32.49/ne= t/mac80211/ieee80211_i.h ---- linux-2.6.32.49/net/mac80211/ieee80211_i.h 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/net/mac80211/ieee80211_i.h 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h +index ca62bfe..6657a03 100644 +--- a/net/mac80211/ieee80211_i.h ++++ b/net/mac80211/ieee80211_i.h @@ -25,6 +25,7 @@ #include #include @@ -78863,10 +81123,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/ieee802= 11_i.h linux-2.6.32.49/net/mac802 int monitors, cooked_mntrs; /* number of interfaces with corresponding FIF_ flags */ int fif_fcsfail, fif_plcpfail, fif_control, fif_other_bss, fif_pspoll; -diff -urNp linux-2.6.32.49/net/mac80211/iface.c linux-2.6.32.49/net/mac8= 0211/iface.c ---- linux-2.6.32.49/net/mac80211/iface.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/mac80211/iface.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -166,7 +166,7 @@ static int ieee80211_open(struct net_dev +diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c +index 079c500..eb3c6d4 100644 +--- a/net/mac80211/iface.c ++++ b/net/mac80211/iface.c +@@ -166,7 +166,7 @@ static int ieee80211_open(struct net_device *dev) break; } =20 @@ -78875,7 +81136,7 @@ diff -urNp linux-2.6.32.49/net/mac80211/iface.c l= inux-2.6.32.49/net/mac80211/ifa res =3D drv_start(local); if (res) goto err_del_bss; -@@ -196,7 +196,7 @@ static int ieee80211_open(struct net_dev +@@ -196,7 +196,7 @@ static int ieee80211_open(struct net_device *dev) * Validate the MAC address for this device. */ if (!is_valid_ether_addr(dev->dev_addr)) { @@ -78884,7 +81145,7 @@ diff -urNp linux-2.6.32.49/net/mac80211/iface.c l= inux-2.6.32.49/net/mac80211/ifa drv_stop(local); return -EADDRNOTAVAIL; } -@@ -292,7 +292,7 @@ static int ieee80211_open(struct net_dev +@@ -292,7 +292,7 @@ static int ieee80211_open(struct net_device *dev) =20 hw_reconf_flags |=3D __ieee80211_recalc_idle(local); =20 @@ -78893,7 +81154,7 @@ diff -urNp linux-2.6.32.49/net/mac80211/iface.c l= inux-2.6.32.49/net/mac80211/ifa if (hw_reconf_flags) { ieee80211_hw_config(local, hw_reconf_flags); /* -@@ -320,7 +320,7 @@ static int ieee80211_open(struct net_dev +@@ -320,7 +320,7 @@ static int ieee80211_open(struct net_device *dev) err_del_interface: drv_remove_interface(local, &conf); err_stop: @@ -78902,7 +81163,7 @@ diff -urNp linux-2.6.32.49/net/mac80211/iface.c l= inux-2.6.32.49/net/mac80211/ifa drv_stop(local); err_del_bss: sdata->bss =3D NULL; -@@ -420,7 +420,7 @@ static int ieee80211_stop(struct net_dev +@@ -420,7 +420,7 @@ static int ieee80211_stop(struct net_device *dev) WARN_ON(!list_empty(&sdata->u.ap.vlans)); } =20 @@ -78911,7 +81172,7 @@ diff -urNp linux-2.6.32.49/net/mac80211/iface.c l= inux-2.6.32.49/net/mac80211/ifa =20 switch (sdata->vif.type) { case NL80211_IFTYPE_AP_VLAN: -@@ -526,7 +526,7 @@ static int ieee80211_stop(struct net_dev +@@ -526,7 +526,7 @@ static int ieee80211_stop(struct net_device *dev) =20 ieee80211_recalc_ps(local, -1); =20 @@ -78920,10 +81181,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/iface.c= linux-2.6.32.49/net/mac80211/ifa ieee80211_clear_tx_pending(local); ieee80211_stop_device(local); =20 -diff -urNp linux-2.6.32.49/net/mac80211/main.c linux-2.6.32.49/net/mac80= 211/main.c ---- linux-2.6.32.49/net/mac80211/main.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/mac80211/main.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -145,7 +145,7 @@ int ieee80211_hw_config(struct ieee80211 +diff --git a/net/mac80211/main.c b/net/mac80211/main.c +index 2dfe176..74e4388 100644 +--- a/net/mac80211/main.c ++++ b/net/mac80211/main.c +@@ -145,7 +145,7 @@ int ieee80211_hw_config(struct ieee80211_local *loca= l, u32 changed) local->hw.conf.power_level =3D power; } =20 @@ -78932,10 +81194,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/main.c = linux-2.6.32.49/net/mac80211/main ret =3D drv_config(local, changed); /* * Goal: -diff -urNp linux-2.6.32.49/net/mac80211/mlme.c linux-2.6.32.49/net/mac80= 211/mlme.c ---- linux-2.6.32.49/net/mac80211/mlme.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/mac80211/mlme.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1438,6 +1438,8 @@ ieee80211_rx_mgmt_assoc_resp(struct ieee +diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c +index e67eea7..fcc227e 100644 +--- a/net/mac80211/mlme.c ++++ b/net/mac80211/mlme.c +@@ -1438,6 +1438,8 @@ ieee80211_rx_mgmt_assoc_resp(struct ieee80211_sub_= if_data *sdata, bool have_higher_than_11mbit =3D false, newsta =3D false; u16 ap_ht_cap_flags; =20 @@ -78944,10 +81207,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/mlme.c = linux-2.6.32.49/net/mac80211/mlme /* * AssocResp and ReassocResp have identical structure, so process both * of them in this function. -diff -urNp linux-2.6.32.49/net/mac80211/pm.c linux-2.6.32.49/net/mac8021= 1/pm.c ---- linux-2.6.32.49/net/mac80211/pm.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/mac80211/pm.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -107,7 +107,7 @@ int __ieee80211_suspend(struct ieee80211 +diff --git a/net/mac80211/pm.c b/net/mac80211/pm.c +index e535f1c..4d733d1 100644 +--- a/net/mac80211/pm.c ++++ b/net/mac80211/pm.c +@@ -107,7 +107,7 @@ int __ieee80211_suspend(struct ieee80211_hw *hw) } =20 /* stop hardware - this must stop RX */ @@ -78956,10 +81220,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/pm.c li= nux-2.6.32.49/net/mac80211/pm.c ieee80211_stop_device(local); =20 local->suspended =3D true; -diff -urNp linux-2.6.32.49/net/mac80211/rate.c linux-2.6.32.49/net/mac80= 211/rate.c ---- linux-2.6.32.49/net/mac80211/rate.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/mac80211/rate.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -287,7 +287,7 @@ int ieee80211_init_rate_ctrl_alg(struct=20 +diff --git a/net/mac80211/rate.c b/net/mac80211/rate.c +index b33efc4..0a2efb6 100644 +--- a/net/mac80211/rate.c ++++ b/net/mac80211/rate.c +@@ -287,7 +287,7 @@ int ieee80211_init_rate_ctrl_alg(struct ieee80211_lo= cal *local, struct rate_control_ref *ref, *old; =20 ASSERT_RTNL(); @@ -78968,10 +81233,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/rate.c = linux-2.6.32.49/net/mac80211/rate return -EBUSY; =20 ref =3D rate_control_alloc(name, local); -diff -urNp linux-2.6.32.49/net/mac80211/tx.c linux-2.6.32.49/net/mac8021= 1/tx.c ---- linux-2.6.32.49/net/mac80211/tx.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/mac80211/tx.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -173,7 +173,7 @@ static __le16 ieee80211_duration(struct=20 +diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c +index b1d7904..57e4da7 100644 +--- a/net/mac80211/tx.c ++++ b/net/mac80211/tx.c +@@ -173,7 +173,7 @@ static __le16 ieee80211_duration(struct ieee80211_tx= _data *tx, int group_addr, return cpu_to_le16(dur); } =20 @@ -78980,10 +81246,11 @@ diff -urNp linux-2.6.32.49/net/mac80211/tx.c li= nux-2.6.32.49/net/mac80211/tx.c struct net_device *dev) { return local =3D=3D wdev_priv(dev->ieee80211_ptr); -diff -urNp linux-2.6.32.49/net/mac80211/util.c linux-2.6.32.49/net/mac80= 211/util.c ---- linux-2.6.32.49/net/mac80211/util.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/mac80211/util.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -1042,7 +1042,7 @@ int ieee80211_reconfig(struct ieee80211_ +diff --git a/net/mac80211/util.c b/net/mac80211/util.c +index 31b1085..48fb26d 100644 +--- a/net/mac80211/util.c ++++ b/net/mac80211/util.c +@@ -1042,7 +1042,7 @@ int ieee80211_reconfig(struct ieee80211_local *loc= al) local->resuming =3D true; =20 /* restart hardware */ @@ -78992,10 +81259,44 @@ diff -urNp linux-2.6.32.49/net/mac80211/util.c = linux-2.6.32.49/net/mac80211/util /* * Upon resume hardware can sometimes be goofy due to * various platform / driver / bus issues, so restarting -diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_vs_app.c linux-2.6.32.4= 9/net/netfilter/ipvs/ip_vs_app.c ---- linux-2.6.32.49/net/netfilter/ipvs/ip_vs_app.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/net/netfilter/ipvs/ip_vs_app.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -564,7 +564,7 @@ static const struct file_operations ip_v +diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig +index 634d14a..b35a608 100644 +--- a/net/netfilter/Kconfig ++++ b/net/netfilter/Kconfig +@@ -635,6 +635,16 @@ config NETFILTER_XT_MATCH_ESP +=20 + To compile it as a module, choose M here. If unsure, say N. +=20 ++config NETFILTER_XT_MATCH_GRADM ++ tristate '"gradm" match support' ++ depends on NETFILTER_XTABLES && NETFILTER_ADVANCED ++ depends on GRKERNSEC && !GRKERNSEC_NO_RBAC ++ ---help--- ++ The gradm match allows to match on grsecurity RBAC being enabled. ++ It is useful when iptables rules are applied early on bootup to ++ prevent connections to the machine (except from a trusted host) ++ while the RBAC system is disabled. =20 ++ + config NETFILTER_XT_MATCH_HASHLIMIT + tristate '"hashlimit" match support' + depends on (IP6_NF_IPTABLES || IP6_NF_IPTABLES=3Dn) +diff --git a/net/netfilter/Makefile b/net/netfilter/Makefile +index 49f62ee..a17b2c6 100644 +--- a/net/netfilter/Makefile ++++ b/net/netfilter/Makefile +@@ -68,6 +68,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_CONNTRACK) +=3D xt_con= ntrack.o + obj-$(CONFIG_NETFILTER_XT_MATCH_DCCP) +=3D xt_dccp.o + obj-$(CONFIG_NETFILTER_XT_MATCH_DSCP) +=3D xt_dscp.o + obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) +=3D xt_esp.o ++obj-$(CONFIG_NETFILTER_XT_MATCH_GRADM) +=3D xt_gradm.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HASHLIMIT) +=3D xt_hashlimit.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HELPER) +=3D xt_helper.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HL) +=3D xt_hl.o +diff --git a/net/netfilter/ipvs/ip_vs_app.c b/net/netfilter/ipvs/ip_vs_a= pp.c +index 3c7e427..724043c 100644 +--- a/net/netfilter/ipvs/ip_vs_app.c ++++ b/net/netfilter/ipvs/ip_vs_app.c +@@ -564,7 +564,7 @@ static const struct file_operations ip_vs_app_fops =3D= { .open =3D ip_vs_app_open, .read =3D seq_read, .llseek =3D seq_lseek, @@ -79004,10 +81305,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/i= p_vs_app.c linux-2.6.32.49/net/ne }; #endif =20 -diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_vs_conn.c linux-2.6.32.= 49/net/netfilter/ipvs/ip_vs_conn.c ---- linux-2.6.32.49/net/netfilter/ipvs/ip_vs_conn.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/net/netfilter/ipvs/ip_vs_conn.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -453,10 +453,10 @@ ip_vs_bind_dest(struct ip_vs_conn *cp, s +diff --git a/net/netfilter/ipvs/ip_vs_conn.c b/net/netfilter/ipvs/ip_vs_= conn.c +index 95682e5..457dbac 100644 +--- a/net/netfilter/ipvs/ip_vs_conn.c ++++ b/net/netfilter/ipvs/ip_vs_conn.c +@@ -453,10 +453,10 @@ ip_vs_bind_dest(struct ip_vs_conn *cp, struct ip_v= s_dest *dest) /* if the connection is not template and is created * by sync, preserve the activity flag. */ @@ -79020,7 +81322,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_conn.c linux-2.6.32.49/net/n cp->dest =3D dest; =20 IP_VS_DBG_BUF(7, "Bind-dest %s c:%s:%d v:%s:%d " -@@ -723,7 +723,7 @@ ip_vs_conn_new(int af, int proto, const=20 +@@ -723,7 +723,7 @@ ip_vs_conn_new(int af, int proto, const union nf_ine= t_addr *caddr, __be16 cport, atomic_set(&cp->refcnt, 1); =20 atomic_set(&cp->n_control, 0); @@ -79029,7 +81331,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_conn.c linux-2.6.32.49/net/n =20 atomic_inc(&ip_vs_conn_count); if (flags & IP_VS_CONN_F_NO_CPORT) -@@ -871,7 +871,7 @@ static const struct file_operations ip_v +@@ -871,7 +871,7 @@ static const struct file_operations ip_vs_conn_fops = =3D { .open =3D ip_vs_conn_open, .read =3D seq_read, .llseek =3D seq_lseek, @@ -79038,7 +81340,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_conn.c linux-2.6.32.49/net/n }; =20 static const char *ip_vs_origin_name(unsigned flags) -@@ -934,7 +934,7 @@ static const struct file_operations ip_v +@@ -934,7 +934,7 @@ static const struct file_operations ip_vs_conn_sync_= fops =3D { .open =3D ip_vs_conn_sync_open, .read =3D seq_read, .llseek =3D seq_lseek, @@ -79047,7 +81349,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_conn.c linux-2.6.32.49/net/n }; =20 #endif -@@ -961,7 +961,7 @@ static inline int todrop_entry(struct ip +@@ -961,7 +961,7 @@ static inline int todrop_entry(struct ip_vs_conn *cp= ) =20 /* Don't drop the entry if its number of incoming packets is not located in [0, 8] */ @@ -79056,10 +81358,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/i= p_vs_conn.c linux-2.6.32.49/net/n if (i > 8 || i < 0) return 0; =20 if (!todrop_rate[i]) return 0; -diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_vs_core.c linux-2.6.32.= 49/net/netfilter/ipvs/ip_vs_core.c ---- linux-2.6.32.49/net/netfilter/ipvs/ip_vs_core.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/net/netfilter/ipvs/ip_vs_core.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -485,7 +485,7 @@ int ip_vs_leave(struct ip_vs_service *sv +diff --git a/net/netfilter/ipvs/ip_vs_core.c b/net/netfilter/ipvs/ip_vs_= core.c +index b95699f..5fee919 100644 +--- a/net/netfilter/ipvs/ip_vs_core.c ++++ b/net/netfilter/ipvs/ip_vs_core.c +@@ -485,7 +485,7 @@ int ip_vs_leave(struct ip_vs_service *svc, struct sk= _buff *skb, ret =3D cp->packet_xmit(skb, cp, pp); /* do not touch skb anymore */ =20 @@ -79068,7 +81371,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_core.c linux-2.6.32.49/net/n ip_vs_conn_put(cp); return ret; } -@@ -1357,7 +1357,7 @@ ip_vs_in(unsigned int hooknum, struct sk +@@ -1357,7 +1357,7 @@ ip_vs_in(unsigned int hooknum, struct sk_buff *skb= , * Sync connection if it is about to close to * encorage the standby servers to update the connections timeout */ @@ -79077,10 +81380,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/i= p_vs_core.c linux-2.6.32.49/net/n if (af =3D=3D AF_INET && (ip_vs_sync_state & IP_VS_STATE_MASTER) && (((cp->protocol !=3D IPPROTO_TCP || -diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_vs_ctl.c linux-2.6.32.4= 9/net/netfilter/ipvs/ip_vs_ctl.c ---- linux-2.6.32.49/net/netfilter/ipvs/ip_vs_ctl.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/net/netfilter/ipvs/ip_vs_ctl.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -792,7 +792,7 @@ __ip_vs_update_dest(struct ip_vs_service +diff --git a/net/netfilter/ipvs/ip_vs_ctl.c b/net/netfilter/ipvs/ip_vs_c= tl.c +index 02b2610..2d89424 100644 +--- a/net/netfilter/ipvs/ip_vs_ctl.c ++++ b/net/netfilter/ipvs/ip_vs_ctl.c +@@ -792,7 +792,7 @@ __ip_vs_update_dest(struct ip_vs_service *svc, ip_vs_rs_hash(dest); write_unlock_bh(&__ip_vs_rs_lock); } @@ -79089,7 +81393,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_ctl.c linux-2.6.32.49/net/ne =20 /* bind the service */ if (!dest->svc) { -@@ -1888,7 +1888,7 @@ static int ip_vs_info_seq_show(struct se +@@ -1888,7 +1888,7 @@ static int ip_vs_info_seq_show(struct seq_file *se= q, void *v) " %-7s %-6d %-10d %-10d\n", &dest->addr.in6, ntohs(dest->port), @@ -79098,7 +81402,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_ctl.c linux-2.6.32.49/net/ne atomic_read(&dest->weight), atomic_read(&dest->activeconns), atomic_read(&dest->inactconns)); -@@ -1899,7 +1899,7 @@ static int ip_vs_info_seq_show(struct se +@@ -1899,7 +1899,7 @@ static int ip_vs_info_seq_show(struct seq_file *se= q, void *v) "%-7s %-6d %-10d %-10d\n", ntohl(dest->addr.ip), ntohs(dest->port), @@ -79107,7 +81411,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_ctl.c linux-2.6.32.49/net/ne atomic_read(&dest->weight), atomic_read(&dest->activeconns), atomic_read(&dest->inactconns)); -@@ -1927,7 +1927,7 @@ static const struct file_operations ip_v +@@ -1927,7 +1927,7 @@ static const struct file_operations ip_vs_info_fop= s =3D { .open =3D ip_vs_info_open, .read =3D seq_read, .llseek =3D seq_lseek, @@ -79116,7 +81420,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_ctl.c linux-2.6.32.49/net/ne }; =20 #endif -@@ -1976,7 +1976,7 @@ static const struct file_operations ip_v +@@ -1976,7 +1976,7 @@ static const struct file_operations ip_vs_stats_fo= ps =3D { .open =3D ip_vs_stats_seq_open, .read =3D seq_read, .llseek =3D seq_lseek, @@ -79125,7 +81429,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_ctl.c linux-2.6.32.49/net/ne }; =20 #endif -@@ -2292,7 +2292,7 @@ __ip_vs_get_dest_entries(const struct ip +@@ -2292,7 +2292,7 @@ __ip_vs_get_dest_entries(const struct ip_vs_get_de= sts *get, =20 entry.addr =3D dest->addr.ip; entry.port =3D dest->port; @@ -79134,7 +81438,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_ctl.c linux-2.6.32.49/net/ne entry.weight =3D atomic_read(&dest->weight); entry.u_threshold =3D dest->u_threshold; entry.l_threshold =3D dest->l_threshold; -@@ -2353,6 +2353,8 @@ do_ip_vs_get_ctl(struct sock *sk, int cm +@@ -2353,6 +2353,8 @@ do_ip_vs_get_ctl(struct sock *sk, int cmd, void __= user *user, int *len) unsigned char arg[128]; int ret =3D 0; =20 @@ -79143,7 +81447,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_ctl.c linux-2.6.32.49/net/ne if (!capable(CAP_NET_ADMIN)) return -EPERM; =20 -@@ -2802,7 +2804,7 @@ static int ip_vs_genl_fill_dest(struct s +@@ -2802,7 +2804,7 @@ static int ip_vs_genl_fill_dest(struct sk_buff *sk= b, struct ip_vs_dest *dest) NLA_PUT_U16(skb, IPVS_DEST_ATTR_PORT, dest->port); =20 NLA_PUT_U32(skb, IPVS_DEST_ATTR_FWD_METHOD, @@ -79152,10 +81456,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/i= p_vs_ctl.c linux-2.6.32.49/net/ne NLA_PUT_U32(skb, IPVS_DEST_ATTR_WEIGHT, atomic_read(&dest->weight)); NLA_PUT_U32(skb, IPVS_DEST_ATTR_U_THRESH, dest->u_threshold); NLA_PUT_U32(skb, IPVS_DEST_ATTR_L_THRESH, dest->l_threshold); -diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_vs_sync.c linux-2.6.32.= 49/net/netfilter/ipvs/ip_vs_sync.c ---- linux-2.6.32.49/net/netfilter/ipvs/ip_vs_sync.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/net/netfilter/ipvs/ip_vs_sync.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -438,7 +438,7 @@ static void ip_vs_process_message(const=20 +diff --git a/net/netfilter/ipvs/ip_vs_sync.c b/net/netfilter/ipvs/ip_vs_= sync.c +index e177f0d..55e8581 100644 +--- a/net/netfilter/ipvs/ip_vs_sync.c ++++ b/net/netfilter/ipvs/ip_vs_sync.c +@@ -438,7 +438,7 @@ static void ip_vs_process_message(const char *buffer= , const size_t buflen) =20 if (opt) memcpy(&cp->in_seq, opt, sizeof(*opt)); @@ -79164,10 +81469,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/i= p_vs_sync.c linux-2.6.32.49/net/n cp->state =3D state; cp->old_state =3D cp->state; /* -diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_vs_xmit.c linux-2.6.32.= 49/net/netfilter/ipvs/ip_vs_xmit.c ---- linux-2.6.32.49/net/netfilter/ipvs/ip_vs_xmit.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/net/netfilter/ipvs/ip_vs_xmit.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -875,7 +875,7 @@ ip_vs_icmp_xmit(struct sk_buff *skb, str +diff --git a/net/netfilter/ipvs/ip_vs_xmit.c b/net/netfilter/ipvs/ip_vs_= xmit.c +index 30b3189..e2e4b55 100644 +--- a/net/netfilter/ipvs/ip_vs_xmit.c ++++ b/net/netfilter/ipvs/ip_vs_xmit.c +@@ -875,7 +875,7 @@ ip_vs_icmp_xmit(struct sk_buff *skb, struct ip_vs_co= nn *cp, else rc =3D NF_ACCEPT; /* do not touch skb anymore */ @@ -79176,7 +81482,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/ip_= vs_xmit.c linux-2.6.32.49/net/n goto out; } =20 -@@ -949,7 +949,7 @@ ip_vs_icmp_xmit_v6(struct sk_buff *skb,=20 +@@ -949,7 +949,7 @@ ip_vs_icmp_xmit_v6(struct sk_buff *skb, struct ip_vs= _conn *cp, else rc =3D NF_ACCEPT; /* do not touch skb anymore */ @@ -79185,41 +81491,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/ipvs/i= p_vs_xmit.c linux-2.6.32.49/net/n goto out; } =20 -diff -urNp linux-2.6.32.49/net/netfilter/Kconfig linux-2.6.32.49/net/net= filter/Kconfig ---- linux-2.6.32.49/net/netfilter/Kconfig 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/net/netfilter/Kconfig 2011-11-15 19:59:43.000000000 = -0500 -@@ -635,6 +635,16 @@ config NETFILTER_XT_MATCH_ESP -=20 - To compile it as a module, choose M here. If unsure, say N. -=20 -+config NETFILTER_XT_MATCH_GRADM -+ tristate '"gradm" match support' -+ depends on NETFILTER_XTABLES && NETFILTER_ADVANCED -+ depends on GRKERNSEC && !GRKERNSEC_NO_RBAC -+ ---help--- -+ The gradm match allows to match on grsecurity RBAC being enabled. -+ It is useful when iptables rules are applied early on bootup to -+ prevent connections to the machine (except from a trusted host) -+ while the RBAC system is disabled. =20 -+ - config NETFILTER_XT_MATCH_HASHLIMIT - tristate '"hashlimit" match support' - depends on (IP6_NF_IPTABLES || IP6_NF_IPTABLES=3Dn) -diff -urNp linux-2.6.32.49/net/netfilter/Makefile linux-2.6.32.49/net/ne= tfilter/Makefile ---- linux-2.6.32.49/net/netfilter/Makefile 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/netfilter/Makefile 2011-11-15 19:59:43.000000000= -0500 -@@ -68,6 +68,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_CONNTRAC - obj-$(CONFIG_NETFILTER_XT_MATCH_DCCP) +=3D xt_dccp.o - obj-$(CONFIG_NETFILTER_XT_MATCH_DSCP) +=3D xt_dscp.o - obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) +=3D xt_esp.o -+obj-$(CONFIG_NETFILTER_XT_MATCH_GRADM) +=3D xt_gradm.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HASHLIMIT) +=3D xt_hashlimit.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HELPER) +=3D xt_helper.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HL) +=3D xt_hl.o -diff -urNp linux-2.6.32.49/net/netfilter/nf_conntrack_netlink.c linux-2.= 6.32.49/net/netfilter/nf_conntrack_netlink.c ---- linux-2.6.32.49/net/netfilter/nf_conntrack_netlink.c 2011-11-08 19:0= 2:43.000000000 -0500 -+++ linux-2.6.32.49/net/netfilter/nf_conntrack_netlink.c 2011-11-15 19:5= 9:43.000000000 -0500 -@@ -706,7 +706,7 @@ ctnetlink_parse_tuple_proto(struct nlatt +diff --git a/net/netfilter/nf_conntrack_netlink.c b/net/netfilter/nf_con= ntrack_netlink.c +index d521718..d0fd7a1 100644 +--- a/net/netfilter/nf_conntrack_netlink.c ++++ b/net/netfilter/nf_conntrack_netlink.c +@@ -706,7 +706,7 @@ ctnetlink_parse_tuple_proto(struct nlattr *attr, static int ctnetlink_parse_tuple(const struct nlattr * const cda[], struct nf_conntrack_tuple *tuple, @@ -79228,9 +81504,10 @@ diff -urNp linux-2.6.32.49/net/netfilter/nf_conn= track_netlink.c linux-2.6.32.49/ { struct nlattr *tb[CTA_TUPLE_MAX+1]; int err; -diff -urNp linux-2.6.32.49/net/netfilter/nfnetlink_log.c linux-2.6.32.49= /net/netfilter/nfnetlink_log.c ---- linux-2.6.32.49/net/netfilter/nfnetlink_log.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/net/netfilter/nfnetlink_log.c 2011-11-15 19:59:43.00= 0000000 -0500 +diff --git a/net/netfilter/nfnetlink_log.c b/net/netfilter/nfnetlink_log= .c +index f900dc3..5e45346 100644 +--- a/net/netfilter/nfnetlink_log.c ++++ b/net/netfilter/nfnetlink_log.c @@ -68,7 +68,7 @@ struct nfulnl_instance { }; =20 @@ -79240,7 +81517,7 @@ diff -urNp linux-2.6.32.49/net/netfilter/nfnetlin= k_log.c linux-2.6.32.49/net/net =20 #define INSTANCE_BUCKETS 16 static struct hlist_head instance_table[INSTANCE_BUCKETS]; -@@ -493,7 +493,7 @@ __build_packet_message(struct nfulnl_ins +@@ -493,7 +493,7 @@ __build_packet_message(struct nfulnl_instance *inst, /* global sequence number */ if (inst->flags & NFULNL_CFG_F_SEQ_GLOBAL) NLA_PUT_BE32(inst->skb, NFULA_SEQ_GLOBAL, @@ -79249,9 +81526,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/nfnetli= nk_log.c linux-2.6.32.49/net/net =20 if (data_len) { struct nlattr *nla; -diff -urNp linux-2.6.32.49/net/netfilter/xt_gradm.c linux-2.6.32.49/net/= netfilter/xt_gradm.c ---- linux-2.6.32.49/net/netfilter/xt_gradm.c 1969-12-31 19:00:00.0000000= 00 -0500 -+++ linux-2.6.32.49/net/netfilter/xt_gradm.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/net/netfilter/xt_gradm.c b/net/netfilter/xt_gradm.c +new file mode 100644 +index 0000000..b1bac76 +--- /dev/null ++++ b/net/netfilter/xt_gradm.c @@ -0,0 +1,51 @@ +/* + * gradm match for netfilter @@ -79304,10 +81583,11 @@ diff -urNp linux-2.6.32.49/net/netfilter/xt_gra= dm.c linux-2.6.32.49/net/netfilte +MODULE_LICENSE("GPL"); +MODULE_ALIAS("ipt_gradm"); +MODULE_ALIAS("ip6t_gradm"); -diff -urNp linux-2.6.32.49/net/netlink/af_netlink.c linux-2.6.32.49/net/= netlink/af_netlink.c ---- linux-2.6.32.49/net/netlink/af_netlink.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/net/netlink/af_netlink.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -733,7 +733,7 @@ static void netlink_overrun(struct sock=20 +diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c +index 5a7dcdf..24a3578 100644 +--- a/net/netlink/af_netlink.c ++++ b/net/netlink/af_netlink.c +@@ -733,7 +733,7 @@ static void netlink_overrun(struct sock *sk) sk->sk_error_report(sk); } } @@ -79316,7 +81596,7 @@ diff -urNp linux-2.6.32.49/net/netlink/af_netlink= .c linux-2.6.32.49/net/netlink/ } =20 static struct sock *netlink_getsockbypid(struct sock *ssk, u32 pid) -@@ -1964,15 +1964,23 @@ static int netlink_seq_show(struct seq_f +@@ -1964,15 +1964,23 @@ static int netlink_seq_show(struct seq_file *seq= , void *v) struct netlink_sock *nlk =3D nlk_sk(s); =20 seq_printf(seq, "%p %-3d %-6d %08x %-8d %-8d %p %-8d %-8d\n", @@ -79341,10 +81621,11 @@ diff -urNp linux-2.6.32.49/net/netlink/af_netli= nk.c linux-2.6.32.49/net/netlink/ ); =20 } -diff -urNp linux-2.6.32.49/net/netrom/af_netrom.c linux-2.6.32.49/net/ne= trom/af_netrom.c ---- linux-2.6.32.49/net/netrom/af_netrom.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/netrom/af_netrom.c 2011-11-15 19:59:43.000000000= -0500 -@@ -838,6 +838,7 @@ static int nr_getname(struct socket *soc +diff --git a/net/netrom/af_netrom.c b/net/netrom/af_netrom.c +index 7a83495..ab0062f 100644 +--- a/net/netrom/af_netrom.c ++++ b/net/netrom/af_netrom.c +@@ -838,6 +838,7 @@ static int nr_getname(struct socket *sock, struct so= ckaddr *uaddr, struct sock *sk =3D sock->sk; struct nr_sock *nr =3D nr_sk(sk); =20 @@ -79352,7 +81633,7 @@ diff -urNp linux-2.6.32.49/net/netrom/af_netrom.c= linux-2.6.32.49/net/netrom/af_ lock_sock(sk); if (peer !=3D 0) { if (sk->sk_state !=3D TCP_ESTABLISHED) { -@@ -852,7 +853,6 @@ static int nr_getname(struct socket *soc +@@ -852,7 +853,6 @@ static int nr_getname(struct socket *sock, struct so= ckaddr *uaddr, *uaddr_len =3D sizeof(struct full_sockaddr_ax25); } else { sax->fsa_ax25.sax25_family =3D AF_NETROM; @@ -79360,10 +81641,11 @@ diff -urNp linux-2.6.32.49/net/netrom/af_netrom= .c linux-2.6.32.49/net/netrom/af_ sax->fsa_ax25.sax25_call =3D nr->source_addr; *uaddr_len =3D sizeof(struct sockaddr_ax25); } -diff -urNp linux-2.6.32.49/net/packet/af_packet.c linux-2.6.32.49/net/pa= cket/af_packet.c ---- linux-2.6.32.49/net/packet/af_packet.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/packet/af_packet.c 2011-11-15 19:59:43.000000000= -0500 -@@ -2429,7 +2429,11 @@ static int packet_seq_show(struct seq_fi +diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c +index 35cfa79..4e78ff7 100644 +--- a/net/packet/af_packet.c ++++ b/net/packet/af_packet.c +@@ -2429,7 +2429,11 @@ static int packet_seq_show(struct seq_file *seq, = void *v) =20 seq_printf(seq, "%p %-6d %-4d %04x %-5d %1d %-6u %-6u %-6lu\n", @@ -79375,10 +81657,11 @@ diff -urNp linux-2.6.32.49/net/packet/af_packet= .c linux-2.6.32.49/net/packet/af_ atomic_read(&s->sk_refcnt), s->sk_type, ntohs(po->num), -diff -urNp linux-2.6.32.49/net/phonet/af_phonet.c linux-2.6.32.49/net/ph= onet/af_phonet.c ---- linux-2.6.32.49/net/phonet/af_phonet.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/phonet/af_phonet.c 2011-11-15 19:59:43.000000000= -0500 -@@ -41,7 +41,7 @@ static struct phonet_protocol *phonet_pr +diff --git a/net/phonet/af_phonet.c b/net/phonet/af_phonet.c +index 519ff9d..a422a90 100644 +--- a/net/phonet/af_phonet.c ++++ b/net/phonet/af_phonet.c +@@ -41,7 +41,7 @@ static struct phonet_protocol *phonet_proto_get(int pr= otocol) { struct phonet_protocol *pp; =20 @@ -79387,7 +81670,7 @@ diff -urNp linux-2.6.32.49/net/phonet/af_phonet.c= linux-2.6.32.49/net/phonet/af_ return NULL; =20 spin_lock(&proto_tab_lock); -@@ -402,7 +402,7 @@ int __init_or_module phonet_proto_regist +@@ -402,7 +402,7 @@ int __init_or_module phonet_proto_register(int proto= col, { int err =3D 0; =20 @@ -79396,10 +81679,11 @@ diff -urNp linux-2.6.32.49/net/phonet/af_phonet= .c linux-2.6.32.49/net/phonet/af_ return -EINVAL; =20 err =3D proto_register(pp->prot, 1); -diff -urNp linux-2.6.32.49/net/phonet/datagram.c linux-2.6.32.49/net/pho= net/datagram.c ---- linux-2.6.32.49/net/phonet/datagram.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/net/phonet/datagram.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -162,7 +162,7 @@ static int pn_backlog_rcv(struct sock *s +diff --git a/net/phonet/datagram.c b/net/phonet/datagram.c +index ef5c75c..2b6c2fa 100644 +--- a/net/phonet/datagram.c ++++ b/net/phonet/datagram.c +@@ -162,7 +162,7 @@ static int pn_backlog_rcv(struct sock *sk, struct sk= _buff *skb) if (err < 0) { kfree_skb(skb); if (err =3D=3D -ENOMEM) @@ -79408,10 +81692,11 @@ diff -urNp linux-2.6.32.49/net/phonet/datagram.= c linux-2.6.32.49/net/phonet/data } return err ? NET_RX_DROP : NET_RX_SUCCESS; } -diff -urNp linux-2.6.32.49/net/phonet/pep.c linux-2.6.32.49/net/phonet/p= ep.c ---- linux-2.6.32.49/net/phonet/pep.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/phonet/pep.c 2011-11-15 19:59:43.000000000 -0500 -@@ -348,7 +348,7 @@ static int pipe_do_rcv(struct sock *sk,=20 +diff --git a/net/phonet/pep.c b/net/phonet/pep.c +index 9cdd35e..16cd850 100644 +--- a/net/phonet/pep.c ++++ b/net/phonet/pep.c +@@ -348,7 +348,7 @@ static int pipe_do_rcv(struct sock *sk, struct sk_bu= ff *skb) =20 case PNS_PEP_CTRL_REQ: if (skb_queue_len(&pn->ctrlreq_queue) >=3D PNPIPE_CTRLREQ_MAX) { @@ -79420,7 +81705,7 @@ diff -urNp linux-2.6.32.49/net/phonet/pep.c linux= -2.6.32.49/net/phonet/pep.c break; } __skb_pull(skb, 4); -@@ -362,12 +362,12 @@ static int pipe_do_rcv(struct sock *sk,=20 +@@ -362,12 +362,12 @@ static int pipe_do_rcv(struct sock *sk, struct sk_= buff *skb) if (!err) return 0; if (err =3D=3D -ENOMEM) @@ -79435,10 +81720,11 @@ diff -urNp linux-2.6.32.49/net/phonet/pep.c lin= ux-2.6.32.49/net/phonet/pep.c err =3D -ENOBUFS; break; } -diff -urNp linux-2.6.32.49/net/phonet/socket.c linux-2.6.32.49/net/phone= t/socket.c ---- linux-2.6.32.49/net/phonet/socket.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/phonet/socket.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -482,8 +482,13 @@ static int pn_sock_seq_show(struct seq_f +diff --git a/net/phonet/socket.c b/net/phonet/socket.c +index aa5b5a9..c09b4f8 100644 +--- a/net/phonet/socket.c ++++ b/net/phonet/socket.c +@@ -482,8 +482,13 @@ static int pn_sock_seq_show(struct seq_file *seq, v= oid *v) sk->sk_state, sk_wmem_alloc_get(sk), sk_rmem_alloc_get(sk), sock_i_uid(sk), sock_i_ino(sk), @@ -79454,9 +81740,23 @@ diff -urNp linux-2.6.32.49/net/phonet/socket.c l= inux-2.6.32.49/net/phonet/socket } seq_printf(seq, "%*s\n", 127 - len, ""); return 0; -diff -urNp linux-2.6.32.49/net/rds/cong.c linux-2.6.32.49/net/rds/cong.c ---- linux-2.6.32.49/net/rds/cong.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/rds/cong.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/rds/Kconfig b/net/rds/Kconfig +index ec753b3..821187c 100644 +--- a/net/rds/Kconfig ++++ b/net/rds/Kconfig +@@ -1,7 +1,7 @@ +=20 + config RDS + tristate "The RDS Protocol (EXPERIMENTAL)" +- depends on INET && EXPERIMENTAL ++ depends on INET && EXPERIMENTAL && BROKEN + ---help--- + The RDS (Reliable Datagram Sockets) protocol provides reliable, + sequenced delivery of datagrams over Infiniband, iWARP, +diff --git a/net/rds/cong.c b/net/rds/cong.c +index dd2711d..1c7ed12 100644 +--- a/net/rds/cong.c ++++ b/net/rds/cong.c @@ -77,7 +77,7 @@ * finds that the saved generation number is smaller than the global ge= neration * number, it wakes up the process. @@ -79466,7 +81766,7 @@ diff -urNp linux-2.6.32.49/net/rds/cong.c linux-2= .6.32.49/net/rds/cong.c =20 /* * Congestion monitoring -@@ -232,7 +232,7 @@ void rds_cong_map_updated(struct rds_con +@@ -232,7 +232,7 @@ void rds_cong_map_updated(struct rds_cong_map *map, = uint64_t portmask) rdsdebug("waking map %p for %pI4\n", map, &map->m_addr); rds_stats_inc(s_cong_update_received); @@ -79484,10 +81784,11 @@ diff -urNp linux-2.6.32.49/net/rds/cong.c linux= -2.6.32.49/net/rds/cong.c =20 if (likely(*recent =3D=3D gen)) return 0; -diff -urNp linux-2.6.32.49/net/rds/iw_rdma.c linux-2.6.32.49/net/rds/iw_= rdma.c ---- linux-2.6.32.49/net/rds/iw_rdma.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/rds/iw_rdma.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -181,6 +181,8 @@ int rds_iw_update_cm_id(struct rds_iw_de +diff --git a/net/rds/iw_rdma.c b/net/rds/iw_rdma.c +index de4a1b1..94ec861 100644 +--- a/net/rds/iw_rdma.c ++++ b/net/rds/iw_rdma.c +@@ -181,6 +181,8 @@ int rds_iw_update_cm_id(struct rds_iw_device *rds_iw= dev, struct rdma_cm_id *cm_i struct rdma_cm_id *pcm_id; int rc; =20 @@ -79496,22 +81797,11 @@ diff -urNp linux-2.6.32.49/net/rds/iw_rdma.c li= nux-2.6.32.49/net/rds/iw_rdma.c src_addr =3D (struct sockaddr_in *)&cm_id->route.addr.src_addr; dst_addr =3D (struct sockaddr_in *)&cm_id->route.addr.dst_addr; =20 -diff -urNp linux-2.6.32.49/net/rds/Kconfig linux-2.6.32.49/net/rds/Kconf= ig ---- linux-2.6.32.49/net/rds/Kconfig 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/rds/Kconfig 2011-11-15 19:59:43.000000000 -0500 -@@ -1,7 +1,7 @@ -=20 - config RDS - tristate "The RDS Protocol (EXPERIMENTAL)" -- depends on INET && EXPERIMENTAL -+ depends on INET && EXPERIMENTAL && BROKEN - ---help--- - The RDS (Reliable Datagram Sockets) protocol provides reliable, - sequenced delivery of datagrams over Infiniband, iWARP, -diff -urNp linux-2.6.32.49/net/rds/tcp.c linux-2.6.32.49/net/rds/tcp.c ---- linux-2.6.32.49/net/rds/tcp.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/rds/tcp.c 2011-11-15 19:59:43.000000000 -0500 -@@ -57,7 +57,7 @@ void rds_tcp_nonagle(struct socket *sock +diff --git a/net/rds/tcp.c b/net/rds/tcp.c +index b5198ae..8b9fb90 100644 +--- a/net/rds/tcp.c ++++ b/net/rds/tcp.c +@@ -57,7 +57,7 @@ void rds_tcp_nonagle(struct socket *sock) int val =3D 1; =20 set_fs(KERNEL_DS); @@ -79520,10 +81810,11 @@ diff -urNp linux-2.6.32.49/net/rds/tcp.c linux-= 2.6.32.49/net/rds/tcp.c sizeof(val)); set_fs(oldfs); } -diff -urNp linux-2.6.32.49/net/rds/tcp_send.c linux-2.6.32.49/net/rds/tc= p_send.c ---- linux-2.6.32.49/net/rds/tcp_send.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/rds/tcp_send.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -43,7 +43,7 @@ static void rds_tcp_cork(struct socket * +diff --git a/net/rds/tcp_send.c b/net/rds/tcp_send.c +index ab545e0..4079b3b 100644 +--- a/net/rds/tcp_send.c ++++ b/net/rds/tcp_send.c +@@ -43,7 +43,7 @@ static void rds_tcp_cork(struct socket *sock, int val) =20 oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -79532,10 +81823,11 @@ diff -urNp linux-2.6.32.49/net/rds/tcp_send.c l= inux-2.6.32.49/net/rds/tcp_send.c sizeof(val)); set_fs(oldfs); } -diff -urNp linux-2.6.32.49/net/rxrpc/af_rxrpc.c linux-2.6.32.49/net/rxrp= c/af_rxrpc.c ---- linux-2.6.32.49/net/rxrpc/af_rxrpc.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/rxrpc/af_rxrpc.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -38,7 +38,7 @@ static const struct proto_ops rxrpc_rpc_ +diff --git a/net/rxrpc/af_rxrpc.c b/net/rxrpc/af_rxrpc.c +index a86afce..8657bce 100644 +--- a/net/rxrpc/af_rxrpc.c ++++ b/net/rxrpc/af_rxrpc.c +@@ -38,7 +38,7 @@ static const struct proto_ops rxrpc_rpc_ops; __be32 rxrpc_epoch; =20 /* current debugging ID */ @@ -79544,10 +81836,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/af_rxrpc.c= linux-2.6.32.49/net/rxrpc/af_rxr =20 /* count of skbs currently in use */ atomic_t rxrpc_n_skbs; -diff -urNp linux-2.6.32.49/net/rxrpc/ar-ack.c linux-2.6.32.49/net/rxrpc/= ar-ack.c ---- linux-2.6.32.49/net/rxrpc/ar-ack.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/rxrpc/ar-ack.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -174,7 +174,7 @@ static void rxrpc_resend(struct rxrpc_ca +diff --git a/net/rxrpc/ar-ack.c b/net/rxrpc/ar-ack.c +index b4a2209..539106c 100644 +--- a/net/rxrpc/ar-ack.c ++++ b/net/rxrpc/ar-ack.c +@@ -174,7 +174,7 @@ static void rxrpc_resend(struct rxrpc_call *call) =20 _enter("{%d,%d,%d,%d},", call->acks_hard, call->acks_unacked, @@ -79556,7 +81849,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-ack.c lin= ux-2.6.32.49/net/rxrpc/ar-ack.c CIRC_CNT(call->acks_head, call->acks_tail, call->acks_winsz)); =20 stop =3D 0; -@@ -198,7 +198,7 @@ static void rxrpc_resend(struct rxrpc_ca +@@ -198,7 +198,7 @@ static void rxrpc_resend(struct rxrpc_call *call) =20 /* each Tx packet has a new serial number */ sp->hdr.serial =3D @@ -79565,7 +81858,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-ack.c lin= ux-2.6.32.49/net/rxrpc/ar-ack.c =20 hdr =3D (struct rxrpc_header *) txb->head; hdr->serial =3D sp->hdr.serial; -@@ -401,7 +401,7 @@ static void rxrpc_rotate_tx_window(struc +@@ -401,7 +401,7 @@ static void rxrpc_rotate_tx_window(struct rxrpc_call= *call, u32 hard) */ static void rxrpc_clear_tx_window(struct rxrpc_call *call) { @@ -79583,7 +81876,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-ack.c lin= ux-2.6.32.49/net/rxrpc/ar-ack.c =20 _proto("Rx ACK %%%u { m=3D%hu f=3D#%u p=3D#%u s=3D%%%u r=3D%s n=3D%u = }", latest, -@@ -840,6 +840,8 @@ void rxrpc_process_call(struct work_stru +@@ -840,6 +840,8 @@ void rxrpc_process_call(struct work_struct *work) u32 abort_code =3D RX_PROTOCOL_ERROR; u8 *acks =3D NULL; =20 @@ -79592,7 +81885,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-ack.c lin= ux-2.6.32.49/net/rxrpc/ar-ack.c //printk("\n--------------------\n"); _enter("{%d,%s,%lx} [%lu]", call->debug_id, rxrpc_call_states[call->state], call->events, -@@ -1159,7 +1161,7 @@ void rxrpc_process_call(struct work_stru +@@ -1159,7 +1161,7 @@ void rxrpc_process_call(struct work_struct *work) goto maybe_reschedule; =20 send_ACK_with_skew: @@ -79619,10 +81912,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-ack.c l= inux-2.6.32.49/net/rxrpc/ar-ack.c _proto("Tx %s %%%u", rxrpc_pkts[hdr.type], ntohl(hdr.serial)); send_message_2: =20 -diff -urNp linux-2.6.32.49/net/rxrpc/ar-call.c linux-2.6.32.49/net/rxrpc= /ar-call.c ---- linux-2.6.32.49/net/rxrpc/ar-call.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/rxrpc/ar-call.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -82,7 +82,7 @@ static struct rxrpc_call *rxrpc_alloc_ca +diff --git a/net/rxrpc/ar-call.c b/net/rxrpc/ar-call.c +index bc0019f..e1b4b24 100644 +--- a/net/rxrpc/ar-call.c ++++ b/net/rxrpc/ar-call.c +@@ -82,7 +82,7 @@ static struct rxrpc_call *rxrpc_alloc_call(gfp_t gfp) spin_lock_init(&call->lock); rwlock_init(&call->state_lock); atomic_set(&call->usage, 1); @@ -79631,10 +81925,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-call.c = linux-2.6.32.49/net/rxrpc/ar-call call->state =3D RXRPC_CALL_CLIENT_SEND_REQUEST; =20 memset(&call->sock_node, 0xed, sizeof(call->sock_node)); -diff -urNp linux-2.6.32.49/net/rxrpc/ar-connection.c linux-2.6.32.49/net= /rxrpc/ar-connection.c ---- linux-2.6.32.49/net/rxrpc/ar-connection.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/net/rxrpc/ar-connection.c 2011-11-15 19:59:43.000000= 000 -0500 -@@ -205,7 +205,7 @@ static struct rxrpc_connection *rxrpc_al +diff --git a/net/rxrpc/ar-connection.c b/net/rxrpc/ar-connection.c +index 9f1ce84..ff8d061 100644 +--- a/net/rxrpc/ar-connection.c ++++ b/net/rxrpc/ar-connection.c +@@ -205,7 +205,7 @@ static struct rxrpc_connection *rxrpc_alloc_connecti= on(gfp_t gfp) rwlock_init(&conn->lock); spin_lock_init(&conn->state_lock); atomic_set(&conn->usage, 1); @@ -79643,10 +81938,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-connect= ion.c linux-2.6.32.49/net/rxrpc/a conn->avail_calls =3D RXRPC_MAXCALLS; conn->size_align =3D 4; conn->header_size =3D sizeof(struct rxrpc_header); -diff -urNp linux-2.6.32.49/net/rxrpc/ar-connevent.c linux-2.6.32.49/net/= rxrpc/ar-connevent.c ---- linux-2.6.32.49/net/rxrpc/ar-connevent.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/net/rxrpc/ar-connevent.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -109,7 +109,7 @@ static int rxrpc_abort_connection(struct +diff --git a/net/rxrpc/ar-connevent.c b/net/rxrpc/ar-connevent.c +index 0505cdc..f0748ce 100644 +--- a/net/rxrpc/ar-connevent.c ++++ b/net/rxrpc/ar-connevent.c +@@ -109,7 +109,7 @@ static int rxrpc_abort_connection(struct rxrpc_conne= ction *conn, =20 len =3D iov[0].iov_len + iov[1].iov_len; =20 @@ -79655,10 +81951,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-conneve= nt.c linux-2.6.32.49/net/rxrpc/ar _proto("Tx CONN ABORT %%%u { %d }", ntohl(hdr.serial), abort_code); =20 ret =3D kernel_sendmsg(conn->trans->local->socket, &msg, iov, 2, len); -diff -urNp linux-2.6.32.49/net/rxrpc/ar-input.c linux-2.6.32.49/net/rxrp= c/ar-input.c ---- linux-2.6.32.49/net/rxrpc/ar-input.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/rxrpc/ar-input.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -339,9 +339,9 @@ void rxrpc_fast_process_packet(struct rx +diff --git a/net/rxrpc/ar-input.c b/net/rxrpc/ar-input.c +index f98c802..9e8488e 100644 +--- a/net/rxrpc/ar-input.c ++++ b/net/rxrpc/ar-input.c +@@ -339,9 +339,9 @@ void rxrpc_fast_process_packet(struct rxrpc_call *ca= ll, struct sk_buff *skb) /* track the latest serial number on this connection for ACK packet * information */ serial =3D ntohl(sp->hdr.serial); @@ -79670,9 +81967,10 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-input.c = linux-2.6.32.49/net/rxrpc/ar-inp serial); =20 /* request ACK generation for any ACK or DATA packet that requests -diff -urNp linux-2.6.32.49/net/rxrpc/ar-internal.h linux-2.6.32.49/net/r= xrpc/ar-internal.h ---- linux-2.6.32.49/net/rxrpc/ar-internal.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/net/rxrpc/ar-internal.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/net/rxrpc/ar-internal.h b/net/rxrpc/ar-internal.h +index 7043b29..06edcdf 100644 +--- a/net/rxrpc/ar-internal.h ++++ b/net/rxrpc/ar-internal.h @@ -272,8 +272,8 @@ struct rxrpc_connection { int error; /* error code for local abort */ int debug_id; /* debug ID for printks */ @@ -79693,7 +81991,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-internal.= h linux-2.6.32.49/net/rxrpc/ar- u32 abort_code; /* local/remote abort code */ enum { /* current state of call */ RXRPC_CALL_CLIENT_SEND_REQUEST, /* - client sending request phase */ -@@ -420,7 +420,7 @@ static inline void rxrpc_abort_call(stru +@@ -420,7 +420,7 @@ static inline void rxrpc_abort_call(struct rxrpc_cal= l *call, u32 abort_code) */ extern atomic_t rxrpc_n_skbs; extern __be32 rxrpc_epoch; @@ -79702,10 +82000,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-interna= l.h linux-2.6.32.49/net/rxrpc/ar- extern struct workqueue_struct *rxrpc_workqueue; =20 /* -diff -urNp linux-2.6.32.49/net/rxrpc/ar-key.c linux-2.6.32.49/net/rxrpc/= ar-key.c ---- linux-2.6.32.49/net/rxrpc/ar-key.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/rxrpc/ar-key.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -88,11 +88,11 @@ static int rxrpc_instantiate_xdr_rxkad(s +diff --git a/net/rxrpc/ar-key.c b/net/rxrpc/ar-key.c +index 74697b2..10f9b77 100644 +--- a/net/rxrpc/ar-key.c ++++ b/net/rxrpc/ar-key.c +@@ -88,11 +88,11 @@ static int rxrpc_instantiate_xdr_rxkad(struct key *k= ey, const __be32 *xdr, return ret; =20 plen -=3D sizeof(*token); @@ -79719,7 +82018,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-key.c lin= ux-2.6.32.49/net/rxrpc/ar-key.c if (!token->kad) { kfree(token); return -ENOMEM; -@@ -730,10 +730,10 @@ static int rxrpc_instantiate(struct key=20 +@@ -730,10 +730,10 @@ static int rxrpc_instantiate(struct key *key, cons= t void *data, size_t datalen) goto error; =20 ret =3D -ENOMEM; @@ -79732,10 +82031,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-key.c l= inux-2.6.32.49/net/rxrpc/ar-key.c if (!token->kad) goto error_free; =20 -diff -urNp linux-2.6.32.49/net/rxrpc/ar-local.c linux-2.6.32.49/net/rxrp= c/ar-local.c ---- linux-2.6.32.49/net/rxrpc/ar-local.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/rxrpc/ar-local.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -44,7 +44,7 @@ struct rxrpc_local *rxrpc_alloc_local(st +diff --git a/net/rxrpc/ar-local.c b/net/rxrpc/ar-local.c +index 807535f..5b7f19e 100644 +--- a/net/rxrpc/ar-local.c ++++ b/net/rxrpc/ar-local.c +@@ -44,7 +44,7 @@ struct rxrpc_local *rxrpc_alloc_local(struct sockaddr_= rxrpc *srx) spin_lock_init(&local->lock); rwlock_init(&local->services_lock); atomic_set(&local->usage, 1); @@ -79744,10 +82044,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-local.c= linux-2.6.32.49/net/rxrpc/ar-loc memcpy(&local->srx, srx, sizeof(*srx)); } =20 -diff -urNp linux-2.6.32.49/net/rxrpc/ar-output.c linux-2.6.32.49/net/rxr= pc/ar-output.c ---- linux-2.6.32.49/net/rxrpc/ar-output.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/net/rxrpc/ar-output.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -680,9 +680,9 @@ static int rxrpc_send_data(struct kiocb=20 +diff --git a/net/rxrpc/ar-output.c b/net/rxrpc/ar-output.c +index cc9102c..7d3888e 100644 +--- a/net/rxrpc/ar-output.c ++++ b/net/rxrpc/ar-output.c +@@ -680,9 +680,9 @@ static int rxrpc_send_data(struct kiocb *iocb, sp->hdr.cid =3D call->cid; sp->hdr.callNumber =3D call->call_id; sp->hdr.seq =3D @@ -79759,10 +82060,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-output.= c linux-2.6.32.49/net/rxrpc/ar-ou sp->hdr.type =3D RXRPC_PACKET_TYPE_DATA; sp->hdr.userStatus =3D 0; sp->hdr.securityIndex =3D conn->security_ix; -diff -urNp linux-2.6.32.49/net/rxrpc/ar-peer.c linux-2.6.32.49/net/rxrpc= /ar-peer.c ---- linux-2.6.32.49/net/rxrpc/ar-peer.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/rxrpc/ar-peer.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -86,7 +86,7 @@ static struct rxrpc_peer *rxrpc_alloc_pe +diff --git a/net/rxrpc/ar-peer.c b/net/rxrpc/ar-peer.c +index edc026c..4bd4e2d 100644 +--- a/net/rxrpc/ar-peer.c ++++ b/net/rxrpc/ar-peer.c +@@ -86,7 +86,7 @@ static struct rxrpc_peer *rxrpc_alloc_peer(struct sock= addr_rxrpc *srx, INIT_LIST_HEAD(&peer->error_targets); spin_lock_init(&peer->lock); atomic_set(&peer->usage, 1); @@ -79771,10 +82073,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-peer.c = linux-2.6.32.49/net/rxrpc/ar-peer memcpy(&peer->srx, srx, sizeof(*srx)); =20 rxrpc_assess_MTU_size(peer); -diff -urNp linux-2.6.32.49/net/rxrpc/ar-proc.c linux-2.6.32.49/net/rxrpc= /ar-proc.c ---- linux-2.6.32.49/net/rxrpc/ar-proc.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/rxrpc/ar-proc.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -164,8 +164,8 @@ static int rxrpc_connection_seq_show(str +diff --git a/net/rxrpc/ar-proc.c b/net/rxrpc/ar-proc.c +index 38047f7..9f48511 100644 +--- a/net/rxrpc/ar-proc.c ++++ b/net/rxrpc/ar-proc.c +@@ -164,8 +164,8 @@ static int rxrpc_connection_seq_show(struct seq_file= *seq, void *v) atomic_read(&conn->usage), rxrpc_conn_states[conn->state], key_serial(conn->key), @@ -79785,10 +82088,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-proc.c = linux-2.6.32.49/net/rxrpc/ar-proc =20 return 0; } -diff -urNp linux-2.6.32.49/net/rxrpc/ar-transport.c linux-2.6.32.49/net/= rxrpc/ar-transport.c ---- linux-2.6.32.49/net/rxrpc/ar-transport.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/net/rxrpc/ar-transport.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -46,7 +46,7 @@ static struct rxrpc_transport *rxrpc_all +diff --git a/net/rxrpc/ar-transport.c b/net/rxrpc/ar-transport.c +index 0936e1a..437c640 100644 +--- a/net/rxrpc/ar-transport.c ++++ b/net/rxrpc/ar-transport.c +@@ -46,7 +46,7 @@ static struct rxrpc_transport *rxrpc_alloc_transport(s= truct rxrpc_local *local, spin_lock_init(&trans->client_lock); rwlock_init(&trans->conn_lock); atomic_set(&trans->usage, 1); @@ -79797,10 +82101,11 @@ diff -urNp linux-2.6.32.49/net/rxrpc/ar-transpo= rt.c linux-2.6.32.49/net/rxrpc/ar =20 if (peer->srx.transport.family =3D=3D AF_INET) { switch (peer->srx.transport_type) { -diff -urNp linux-2.6.32.49/net/rxrpc/rxkad.c linux-2.6.32.49/net/rxrpc/r= xkad.c ---- linux-2.6.32.49/net/rxrpc/rxkad.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/rxrpc/rxkad.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -210,6 +210,8 @@ static int rxkad_secure_packet_encrypt(c +diff --git a/net/rxrpc/rxkad.c b/net/rxrpc/rxkad.c +index 713ac59..306f6ae 100644 +--- a/net/rxrpc/rxkad.c ++++ b/net/rxrpc/rxkad.c +@@ -210,6 +210,8 @@ static int rxkad_secure_packet_encrypt(const struct = rxrpc_call *call, u16 check; int nsg; =20 @@ -79809,7 +82114,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/rxkad.c linu= x-2.6.32.49/net/rxrpc/rxkad.c sp =3D rxrpc_skb(skb); =20 _enter(""); -@@ -337,6 +339,8 @@ static int rxkad_verify_packet_auth(cons +@@ -337,6 +339,8 @@ static int rxkad_verify_packet_auth(const struct rxr= pc_call *call, u16 check; int nsg; =20 @@ -79818,7 +82123,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/rxkad.c linu= x-2.6.32.49/net/rxrpc/rxkad.c _enter(""); =20 sp =3D rxrpc_skb(skb); -@@ -609,7 +613,7 @@ static int rxkad_issue_challenge(struct=20 +@@ -609,7 +613,7 @@ static int rxkad_issue_challenge(struct rxrpc_connec= tion *conn) =20 len =3D iov[0].iov_len + iov[1].iov_len; =20 @@ -79827,7 +82132,7 @@ diff -urNp linux-2.6.32.49/net/rxrpc/rxkad.c linu= x-2.6.32.49/net/rxrpc/rxkad.c _proto("Tx CHALLENGE %%%u", ntohl(hdr.serial)); =20 ret =3D kernel_sendmsg(conn->trans->local->socket, &msg, iov, 2, len); -@@ -659,7 +663,7 @@ static int rxkad_send_response(struct rx +@@ -659,7 +663,7 @@ static int rxkad_send_response(struct rxrpc_connecti= on *conn, =20 len =3D iov[0].iov_len + iov[1].iov_len + iov[2].iov_len; =20 @@ -79836,10 +82141,24 @@ diff -urNp linux-2.6.32.49/net/rxrpc/rxkad.c li= nux-2.6.32.49/net/rxrpc/rxkad.c _proto("Tx RESPONSE %%%u", ntohl(hdr->serial)); =20 ret =3D kernel_sendmsg(conn->trans->local->socket, &msg, iov, 3, len); -diff -urNp linux-2.6.32.49/net/sctp/proc.c linux-2.6.32.49/net/sctp/proc= .c ---- linux-2.6.32.49/net/sctp/proc.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/sctp/proc.c 2011-11-15 19:59:43.000000000 -0500 -@@ -213,7 +213,12 @@ static int sctp_eps_seq_show(struct seq_ +diff --git a/net/sctp/auth.c b/net/sctp/auth.c +index 914c419..7a16d2c 100644 +--- a/net/sctp/auth.c ++++ b/net/sctp/auth.c +@@ -81,7 +81,7 @@ static struct sctp_auth_bytes *sctp_auth_create_key(__= u32 key_len, gfp_t gfp) + struct sctp_auth_bytes *key; +=20 + /* Verify that we are not going to overflow INT_MAX */ +- if ((INT_MAX - key_len) < sizeof(struct sctp_auth_bytes)) ++ if (key_len > (INT_MAX - sizeof(struct sctp_auth_bytes))) + return NULL; +=20 + /* Allocate the shared key */ +diff --git a/net/sctp/proc.c b/net/sctp/proc.c +index d093cbf..9fc36fc 100644 +--- a/net/sctp/proc.c ++++ b/net/sctp/proc.c +@@ -213,7 +213,12 @@ static int sctp_eps_seq_show(struct seq_file *seq, = void *v) sctp_for_each_hentry(epb, node, &head->chain) { ep =3D sctp_ep(epb); sk =3D epb->sk; @@ -79853,7 +82172,7 @@ diff -urNp linux-2.6.32.49/net/sctp/proc.c linux-= 2.6.32.49/net/sctp/proc.c sctp_sk(sk)->type, sk->sk_state, hash, epb->bind_addr.port, sock_i_uid(sk), sock_i_ino(sk)); -@@ -320,7 +325,12 @@ static int sctp_assocs_seq_show(struct s +@@ -320,7 +325,12 @@ static int sctp_assocs_seq_show(struct seq_file *se= q, void *v) seq_printf(seq, "%8p %8p %-3d %-3d %-2d %-4d " "%4d %8d %8d %7d %5lu %-5d %5d ", @@ -79867,9 +82186,10 @@ diff -urNp linux-2.6.32.49/net/sctp/proc.c linux= -2.6.32.49/net/sctp/proc.c assoc->state, hash, assoc->assoc_id, assoc->sndbuf_used, -diff -urNp linux-2.6.32.49/net/sctp/socket.c linux-2.6.32.49/net/sctp/so= cket.c ---- linux-2.6.32.49/net/sctp/socket.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/sctp/socket.c 2011-11-15 19:59:43.000000000 -050= 0 +diff --git a/net/sctp/socket.c b/net/sctp/socket.c +index 3a95fcb..c40fc1d 100644 +--- a/net/sctp/socket.c ++++ b/net/sctp/socket.c @@ -5802,7 +5802,6 @@ pp_found: */ int reuse =3D sk->sk_reuse; @@ -79878,9 +82198,10 @@ diff -urNp linux-2.6.32.49/net/sctp/socket.c lin= ux-2.6.32.49/net/sctp/socket.c =20 SCTP_DEBUG_PRINTK("sctp_get_port() found a possible match\n"); if (pp->fastreuse && sk->sk_reuse && -diff -urNp linux-2.6.32.49/net/socket.c linux-2.6.32.49/net/socket.c ---- linux-2.6.32.49/net/socket.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/socket.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/socket.c b/net/socket.c +index d449812..4ac08d3c 100644 +--- a/net/socket.c ++++ b/net/socket.c @@ -87,6 +87,7 @@ #include #include @@ -79911,7 +82232,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c static int sock_no_open(struct inode *irrelevant, struct file *dontcare= ); static ssize_t sock_aio_read(struct kiocb *iocb, const struct iovec *io= v, unsigned long nr_segs, loff_t pos); -@@ -298,7 +314,7 @@ static int sockfs_get_sb(struct file_sys +@@ -298,7 +314,7 @@ static int sockfs_get_sb(struct file_system_type *fs= _type, mnt); } =20 @@ -79920,7 +82241,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c =20 static struct file_system_type sock_fs_type =3D { .name =3D "sockfs", -@@ -1154,6 +1170,8 @@ static int __sock_create(struct net *net +@@ -1154,6 +1170,8 @@ static int __sock_create(struct net *net, int fami= ly, int type, int protocol, return -EAFNOSUPPORT; if (type < 0 || type >=3D SOCK_MAX) return -EINVAL; @@ -79929,7 +82250,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c =20 /* Compatibility. =20 -@@ -1283,6 +1301,16 @@ SYSCALL_DEFINE3(socket, int, family, int +@@ -1283,6 +1301,16 @@ SYSCALL_DEFINE3(socket, int, family, int, type, i= nt, protocol) if (SOCK_NONBLOCK !=3D O_NONBLOCK && (flags & SOCK_NONBLOCK)) flags =3D (flags & ~SOCK_NONBLOCK) | O_NONBLOCK; =20 @@ -79946,7 +82267,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c retval =3D sock_create(family, type, protocol, &sock); if (retval < 0) goto out; -@@ -1415,6 +1443,14 @@ SYSCALL_DEFINE3(bind, int, fd, struct so +@@ -1415,6 +1443,14 @@ SYSCALL_DEFINE3(bind, int, fd, struct sockaddr __= user *, umyaddr, int, addrlen) if (sock) { err =3D move_addr_to_kernel(umyaddr, addrlen, (struct sockaddr *)&add= ress); if (err >=3D 0) { @@ -79961,7 +82282,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c err =3D security_socket_bind(sock, (struct sockaddr *)&address, addrlen); -@@ -1423,6 +1459,7 @@ SYSCALL_DEFINE3(bind, int, fd, struct so +@@ -1423,6 +1459,7 @@ SYSCALL_DEFINE3(bind, int, fd, struct sockaddr __u= ser *, umyaddr, int, addrlen) (struct sockaddr *) &address, addrlen); } @@ -79969,7 +82290,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c fput_light(sock->file, fput_needed); } return err; -@@ -1446,10 +1483,20 @@ SYSCALL_DEFINE2(listen, int, fd, int, ba +@@ -1446,10 +1483,20 @@ SYSCALL_DEFINE2(listen, int, fd, int, backlog) if ((unsigned)backlog > somaxconn) backlog =3D somaxconn; =20 @@ -79990,7 +82311,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c fput_light(sock->file, fput_needed); } return err; -@@ -1492,6 +1539,18 @@ SYSCALL_DEFINE4(accept4, int, fd, struct +@@ -1492,6 +1539,18 @@ SYSCALL_DEFINE4(accept4, int, fd, struct sockaddr= __user *, upeer_sockaddr, newsock->type =3D sock->type; newsock->ops =3D sock->ops; =20 @@ -80009,7 +82330,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c /* * We don't need try_module_get here, as the listening socket (sock) * has the protocol module (sock->ops->owner) held. -@@ -1534,6 +1593,8 @@ SYSCALL_DEFINE4(accept4, int, fd, struct +@@ -1534,6 +1593,8 @@ SYSCALL_DEFINE4(accept4, int, fd, struct sockaddr = __user *, upeer_sockaddr, fd_install(newfd, newfile); err =3D newfd; =20 @@ -80018,7 +82339,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c out_put: fput_light(sock->file, fput_needed); out: -@@ -1571,6 +1632,7 @@ SYSCALL_DEFINE3(connect, int, fd, struct +@@ -1571,6 +1632,7 @@ SYSCALL_DEFINE3(connect, int, fd, struct sockaddr = __user *, uservaddr, int, addrlen) { struct socket *sock; @@ -80026,7 +82347,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c struct sockaddr_storage address; int err, fput_needed; =20 -@@ -1581,6 +1643,17 @@ SYSCALL_DEFINE3(connect, int, fd, struct +@@ -1581,6 +1643,17 @@ SYSCALL_DEFINE3(connect, int, fd, struct sockaddr= __user *, uservaddr, if (err < 0) goto out_put; =20 @@ -80044,7 +82365,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c err =3D security_socket_connect(sock, (struct sockaddr *)&address, addrlen= ); if (err) -@@ -1882,6 +1955,8 @@ SYSCALL_DEFINE3(sendmsg, int, fd, struct +@@ -1882,6 +1955,8 @@ SYSCALL_DEFINE3(sendmsg, int, fd, struct msghdr __= user *, msg, unsigned, flags) int err, ctl_len, iov_size, total_len; int fput_needed; =20 @@ -80053,7 +82374,7 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2.6= .32.49/net/socket.c err =3D -EFAULT; if (MSG_CMSG_COMPAT & flags) { if (get_compat_msghdr(&msg_sys, msg_compat)) -@@ -2022,7 +2097,7 @@ SYSCALL_DEFINE3(recvmsg, int, fd, struct +@@ -2022,7 +2097,7 @@ SYSCALL_DEFINE3(recvmsg, int, fd, struct msghdr __= user *, msg, * kernel msghdr to use the kernel address space) */ =20 @@ -80062,10 +82383,11 @@ diff -urNp linux-2.6.32.49/net/socket.c linux-2= .6.32.49/net/socket.c uaddr_len =3D COMPAT_NAMELEN(msg); if (MSG_CMSG_COMPAT & flags) { err =3D verify_compat_iovec(&msg_sys, iov, -diff -urNp linux-2.6.32.49/net/sunrpc/sched.c linux-2.6.32.49/net/sunrpc= /sched.c ---- linux-2.6.32.49/net/sunrpc/sched.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/sunrpc/sched.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -234,10 +234,10 @@ static int rpc_wait_bit_killable(void *w +diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c +index ac94477..8afe5c3 100644 +--- a/net/sunrpc/sched.c ++++ b/net/sunrpc/sched.c +@@ -234,10 +234,10 @@ static int rpc_wait_bit_killable(void *word) #ifdef RPC_DEBUG static void rpc_task_set_debuginfo(struct rpc_task *task) { @@ -80078,10 +82400,11 @@ diff -urNp linux-2.6.32.49/net/sunrpc/sched.c l= inux-2.6.32.49/net/sunrpc/sched.c } #else static inline void rpc_task_set_debuginfo(struct rpc_task *task) -diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma.c linux-2.6.32.4= 9/net/sunrpc/xprtrdma/svc_rdma.c ---- linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -59,15 +59,15 @@ unsigned int svcrdma_max_req_size =3D RPCR +diff --git a/net/sunrpc/xprtrdma/svc_rdma.c b/net/sunrpc/xprtrdma/svc_rd= ma.c +index 35fb68b..236a8bf 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma.c ++++ b/net/sunrpc/xprtrdma/svc_rdma.c +@@ -59,15 +59,15 @@ unsigned int svcrdma_max_req_size =3D RPCRDMA_MAX_RE= Q_SIZE; static unsigned int min_max_inline =3D 4096; static unsigned int max_max_inline =3D 65536; =20 @@ -80106,7 +82429,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma.c linux-2.6.32.49/net/su =20 /* Temporary NFS request map and context caches */ struct kmem_cache *svc_rdma_map_cachep; -@@ -105,7 +105,7 @@ static int read_reset_stat(ctl_table *ta +@@ -105,7 +105,7 @@ static int read_reset_stat(ctl_table *table, int wri= te, len -=3D *ppos; if (len > *lenp) len =3D *lenp; @@ -80115,7 +82438,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma.c linux-2.6.32.49/net/su return -EFAULT; *lenp =3D len; *ppos +=3D len; -@@ -149,63 +149,63 @@ static ctl_table svcrdma_parm_table[] =3D=20 +@@ -149,63 +149,63 @@ static ctl_table svcrdma_parm_table[] =3D { { .procname =3D "rdma_stat_read", .data =3D &rdma_stat_read, @@ -80188,9 +82511,10 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/s= vc_rdma.c linux-2.6.32.49/net/su .mode =3D 0644, .proc_handler =3D &read_reset_stat, }, -diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c linux= -2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c ---- linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c 2011-11-08 1= 9:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c 2011-11-15 1= 9:59:43.000000000 -0500 +diff --git a/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c b/net/sunrpc/xprtrd= ma/svc_rdma_recvfrom.c +index 9e88438..8ed5cf0 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c ++++ b/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c @@ -495,7 +495,7 @@ next_sge: svc_rdma_put_context(ctxt, 0); goto out; @@ -80200,7 +82524,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma_recvfrom.c linux-2.6.32. =20 if (read_wr.num_sge < chl_map->ch[ch_no].count) { chl_map->ch[ch_no].count -=3D read_wr.num_sge; -@@ -606,7 +606,7 @@ int svc_rdma_recvfrom(struct svc_rqst *r +@@ -606,7 +606,7 @@ int svc_rdma_recvfrom(struct svc_rqst *rqstp) dto_q); list_del_init(&ctxt->dto_q); } else { @@ -80209,7 +82533,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma_recvfrom.c linux-2.6.32. clear_bit(XPT_DATA, &xprt->xpt_flags); ctxt =3D NULL; } -@@ -626,7 +626,7 @@ int svc_rdma_recvfrom(struct svc_rqst *r +@@ -626,7 +626,7 @@ int svc_rdma_recvfrom(struct svc_rqst *rqstp) dprintk("svcrdma: processing ctxt=3D%p on xprt=3D%p, rqstp=3D%p, statu= s=3D%d\n", ctxt, rdma_xprt, rqstp, ctxt->wc_status); BUG_ON(ctxt->wc_status !=3D IB_WC_SUCCESS); @@ -80218,10 +82542,11 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/= svc_rdma_recvfrom.c linux-2.6.32. =20 /* Build up the XDR from the receive buffers. */ rdma_build_arg_xdr(rqstp, ctxt, ctxt->byte_len); -diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_sendto.c linux-2= .6.32.49/net/sunrpc/xprtrdma/svc_rdma_sendto.c ---- linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_sendto.c 2011-11-08 19:= 02:43.000000000 -0500 -+++ linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_sendto.c 2011-11-15 19:= 59:43.000000000 -0500 -@@ -328,7 +328,7 @@ static int send_write(struct svcxprt_rdm +diff --git a/net/sunrpc/xprtrdma/svc_rdma_sendto.c b/net/sunrpc/xprtrdma= /svc_rdma_sendto.c +index f11be72..7aad4e8 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma_sendto.c ++++ b/net/sunrpc/xprtrdma/svc_rdma_sendto.c +@@ -328,7 +328,7 @@ static int send_write(struct svcxprt_rdma *xprt, str= uct svc_rqst *rqstp, write_wr.wr.rdma.remote_addr =3D to; =20 /* Post It */ @@ -80230,10 +82555,11 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/= svc_rdma_sendto.c linux-2.6.32.49 if (svc_rdma_send(xprt, &write_wr)) goto err; return 0; -diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_transport.c linu= x-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_transport.c ---- linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_transport.c 2011-11-08 = 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/sunrpc/xprtrdma/svc_rdma_transport.c 2011-11-15 = 19:59:43.000000000 -0500 -@@ -292,7 +292,7 @@ static void rq_cq_reap(struct svcxprt_rd +diff --git a/net/sunrpc/xprtrdma/svc_rdma_transport.c b/net/sunrpc/xprtr= dma/svc_rdma_transport.c +index 3fa5751..030ba89 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma_transport.c ++++ b/net/sunrpc/xprtrdma/svc_rdma_transport.c +@@ -292,7 +292,7 @@ static void rq_cq_reap(struct svcxprt_rdma *xprt) return; =20 ib_req_notify_cq(xprt->sc_rq_cq, IB_CQ_NEXT_COMP); @@ -80242,7 +82568,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma_transport.c linux-2.6.32 =20 while ((ret =3D ib_poll_cq(xprt->sc_rq_cq, 1, &wc)) > 0) { ctxt =3D (struct svc_rdma_op_ctxt *)(unsigned long)wc.wr_id; -@@ -314,7 +314,7 @@ static void rq_cq_reap(struct svcxprt_rd +@@ -314,7 +314,7 @@ static void rq_cq_reap(struct svcxprt_rdma *xprt) } =20 if (ctxt) @@ -80251,7 +82577,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma_transport.c linux-2.6.32 =20 set_bit(XPT_DATA, &xprt->sc_xprt.xpt_flags); /* -@@ -386,7 +386,7 @@ static void sq_cq_reap(struct svcxprt_rd +@@ -386,7 +386,7 @@ static void sq_cq_reap(struct svcxprt_rdma *xprt) return; =20 ib_req_notify_cq(xprt->sc_sq_cq, IB_CQ_NEXT_COMP); @@ -80260,7 +82586,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma_transport.c linux-2.6.32 while ((ret =3D ib_poll_cq(cq, 1, &wc)) > 0) { if (wc.status !=3D IB_WC_SUCCESS) /* Close the transport */ -@@ -404,7 +404,7 @@ static void sq_cq_reap(struct svcxprt_rd +@@ -404,7 +404,7 @@ static void sq_cq_reap(struct svcxprt_rdma *xprt) } =20 if (ctxt) @@ -80269,7 +82595,7 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/sv= c_rdma_transport.c linux-2.6.32 } =20 static void sq_comp_handler(struct ib_cq *cq, void *cq_context) -@@ -1260,7 +1260,7 @@ int svc_rdma_send(struct svcxprt_rdma *x +@@ -1260,7 +1260,7 @@ int svc_rdma_send(struct svcxprt_rdma *xprt, struc= t ib_send_wr *wr) spin_lock_bh(&xprt->sc_lock); if (xprt->sc_sq_depth < atomic_read(&xprt->sc_sq_count) + wr_count) { spin_unlock_bh(&xprt->sc_lock); @@ -80278,10 +82604,11 @@ diff -urNp linux-2.6.32.49/net/sunrpc/xprtrdma/= svc_rdma_transport.c linux-2.6.32 =20 /* See if we can opportunistically reap SQ WR to make room */ sq_cq_reap(xprt); -diff -urNp linux-2.6.32.49/net/sysctl_net.c linux-2.6.32.49/net/sysctl_n= et.c ---- linux-2.6.32.49/net/sysctl_net.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/sysctl_net.c 2011-11-15 19:59:43.000000000 -0500 -@@ -46,7 +46,7 @@ static int net_ctl_permissions(struct ct +diff --git a/net/sysctl_net.c b/net/sysctl_net.c +index 0b15d72..7934fbb 100644 +--- a/net/sysctl_net.c ++++ b/net/sysctl_net.c +@@ -46,7 +46,7 @@ static int net_ctl_permissions(struct ctl_table_root *= root, struct ctl_table *table) { /* Allow network administrator to have same access as root. */ @@ -80290,9 +82617,10 @@ diff -urNp linux-2.6.32.49/net/sysctl_net.c linu= x-2.6.32.49/net/sysctl_net.c int mode =3D (table->mode >> 6) & 7; return (mode << 6) | (mode << 3) | mode; } -diff -urNp linux-2.6.32.49/net/tipc/link.c linux-2.6.32.49/net/tipc/link= .c ---- linux-2.6.32.49/net/tipc/link.c 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/net/tipc/link.c 2011-11-15 19:59:43.000000000 -0500 +diff --git a/net/tipc/link.c b/net/tipc/link.c +index dd4c18b..f40d38d 100644 +--- a/net/tipc/link.c ++++ b/net/tipc/link.c @@ -1418,7 +1418,7 @@ again: =20 if (!sect_rest) { @@ -80311,10 +82639,11 @@ diff -urNp linux-2.6.32.49/net/tipc/link.c linu= x-2.6.32.49/net/tipc/link.c sect_crs +=3D sz; sect_rest -=3D sz; fragm_crs +=3D sz; -diff -urNp linux-2.6.32.49/net/tipc/subscr.c linux-2.6.32.49/net/tipc/su= bscr.c ---- linux-2.6.32.49/net/tipc/subscr.c 2011-11-08 19:02:43.000000000 -050= 0 -+++ linux-2.6.32.49/net/tipc/subscr.c 2011-11-15 19:59:43.000000000 -050= 0 -@@ -104,7 +104,7 @@ static void subscr_send_event(struct sub +diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c +index 0747d8a..e8bf3f3 100644 +--- a/net/tipc/subscr.c ++++ b/net/tipc/subscr.c +@@ -104,7 +104,7 @@ static void subscr_send_event(struct subscription *s= ub, { struct iovec msg_sect; =20 @@ -80323,10 +82652,11 @@ diff -urNp linux-2.6.32.49/net/tipc/subscr.c li= nux-2.6.32.49/net/tipc/subscr.c msg_sect.iov_len =3D sizeof(struct tipc_event); =20 sub->evt.event =3D htohl(event, sub->swap); -diff -urNp linux-2.6.32.49/net/unix/af_unix.c linux-2.6.32.49/net/unix/a= f_unix.c ---- linux-2.6.32.49/net/unix/af_unix.c 2011-11-08 19:02:43.000000000 -05= 00 -+++ linux-2.6.32.49/net/unix/af_unix.c 2011-11-15 19:59:43.000000000 -05= 00 -@@ -745,6 +745,12 @@ static struct sock *unix_find_other(stru +diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c +index db8d51a..608692d 100644 +--- a/net/unix/af_unix.c ++++ b/net/unix/af_unix.c +@@ -745,6 +745,12 @@ static struct sock *unix_find_other(struct net *net= , err =3D -ECONNREFUSED; if (!S_ISSOCK(inode->i_mode)) goto put_fail; @@ -80339,7 +82669,7 @@ diff -urNp linux-2.6.32.49/net/unix/af_unix.c lin= ux-2.6.32.49/net/unix/af_unix.c u =3D unix_find_socket_byinode(net, inode); if (!u) goto put_fail; -@@ -765,6 +771,13 @@ static struct sock *unix_find_other(stru +@@ -765,6 +771,13 @@ static struct sock *unix_find_other(struct net *net= , if (u) { struct dentry *dentry; dentry =3D unix_sk(u)->dentry; @@ -80353,7 +82683,7 @@ diff -urNp linux-2.6.32.49/net/unix/af_unix.c lin= ux-2.6.32.49/net/unix/af_unix.c if (dentry) touch_atime(unix_sk(u)->mnt, dentry); } else -@@ -850,11 +863,18 @@ static int unix_bind(struct socket *sock +@@ -850,11 +863,18 @@ static int unix_bind(struct socket *sock, struct s= ockaddr *uaddr, int addr_len) err =3D security_path_mknod(&nd.path, dentry, mode, 0); if (err) goto out_mknod_drop_write; @@ -80372,7 +82702,7 @@ diff -urNp linux-2.6.32.49/net/unix/af_unix.c lin= ux-2.6.32.49/net/unix/af_unix.c mutex_unlock(&nd.path.dentry->d_inode->i_mutex); dput(nd.path.dentry); nd.path.dentry =3D dentry; -@@ -2211,7 +2231,11 @@ static int unix_seq_show(struct seq_file +@@ -2211,7 +2231,11 @@ static int unix_seq_show(struct seq_file *seq, vo= id *v) unix_state_lock(s); =20 seq_printf(seq, "%p: %08X %08X %08X %04X %02X %5lu", @@ -80384,9 +82714,10 @@ diff -urNp linux-2.6.32.49/net/unix/af_unix.c li= nux-2.6.32.49/net/unix/af_unix.c atomic_read(&s->sk_refcnt), 0, s->sk_state =3D=3D TCP_LISTEN ? __SO_ACCEPTCON : 0, -diff -urNp linux-2.6.32.49/net/wireless/core.h linux-2.6.32.49/net/wirel= ess/core.h ---- linux-2.6.32.49/net/wireless/core.h 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/wireless/core.h 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/net/wireless/core.h b/net/wireless/core.h +index 376798f..109a61f 100644 +--- a/net/wireless/core.h ++++ b/net/wireless/core.h @@ -27,7 +27,7 @@ struct cfg80211_registered_device { struct mutex mtx; =20 @@ -80396,10 +82727,11 @@ diff -urNp linux-2.6.32.49/net/wireless/core.h = linux-2.6.32.49/net/wireless/core struct rfkill *rfkill; struct work_struct rfkill_sync; =20 -diff -urNp linux-2.6.32.49/net/wireless/wext.c linux-2.6.32.49/net/wirel= ess/wext.c ---- linux-2.6.32.49/net/wireless/wext.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/net/wireless/wext.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -816,8 +816,7 @@ static int ioctl_standard_iw_point(struc +diff --git a/net/wireless/wext.c b/net/wireless/wext.c +index a2e4c60..0979cbe 100644 +--- a/net/wireless/wext.c ++++ b/net/wireless/wext.c +@@ -816,8 +816,7 @@ static int ioctl_standard_iw_point(struct iw_point *= iwp, unsigned int cmd, */ =20 /* Support for very large requests */ @@ -80409,7 +82741,7 @@ diff -urNp linux-2.6.32.49/net/wireless/wext.c li= nux-2.6.32.49/net/wireless/wext /* Allow userspace to GET more than max so * we can support any size GET requests. * There is still a limit : -ENOMEM. -@@ -854,22 +853,6 @@ static int ioctl_standard_iw_point(struc +@@ -854,22 +853,6 @@ static int ioctl_standard_iw_point(struct iw_point = *iwp, unsigned int cmd, } } =20 @@ -80432,10 +82764,11 @@ diff -urNp linux-2.6.32.49/net/wireless/wext.c = linux-2.6.32.49/net/wireless/wext err =3D handler(dev, info, (union iwreq_data *) iwp, extra); =20 iwp->length +=3D essid_compat; -diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c linux-2.6.32.49/net/xf= rm/xfrm_policy.c ---- linux-2.6.32.49/net/xfrm/xfrm_policy.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/net/xfrm/xfrm_policy.c 2011-11-15 19:59:43.000000000= -0500 -@@ -586,7 +586,7 @@ int xfrm_policy_insert(int dir, struct x +diff --git a/net/xfrm/xfrm_policy.c b/net/xfrm/xfrm_policy.c +index cb81ca3..e15d49a 100644 +--- a/net/xfrm/xfrm_policy.c ++++ b/net/xfrm/xfrm_policy.c +@@ -586,7 +586,7 @@ int xfrm_policy_insert(int dir, struct xfrm_policy *= policy, int excl) hlist_add_head(&policy->bydst, chain); xfrm_pol_hold(policy); net->xfrm.policy_count[dir]++; @@ -80444,7 +82777,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c= linux-2.6.32.49/net/xfrm/xfrm_ if (delpol) __xfrm_policy_unlink(delpol, dir); policy->index =3D delpol ? delpol->index : xfrm_gen_index(net, dir); -@@ -669,7 +669,7 @@ struct xfrm_policy *xfrm_policy_bysel_ct +@@ -669,7 +669,7 @@ struct xfrm_policy *xfrm_policy_bysel_ctx(struct net= *net, u8 type, int dir, write_unlock_bh(&xfrm_policy_lock); =20 if (ret && delete) { @@ -80453,7 +82786,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c= linux-2.6.32.49/net/xfrm/xfrm_ xfrm_policy_kill(ret); } return ret; -@@ -710,7 +710,7 @@ struct xfrm_policy *xfrm_policy_byid(str +@@ -710,7 +710,7 @@ struct xfrm_policy *xfrm_policy_byid(struct net *net= , u8 type, int dir, u32 id, write_unlock_bh(&xfrm_policy_lock); =20 if (ret && delete) { @@ -80462,7 +82795,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c= linux-2.6.32.49/net/xfrm/xfrm_ xfrm_policy_kill(ret); } return ret; -@@ -824,7 +824,7 @@ int xfrm_policy_flush(struct net *net, u +@@ -824,7 +824,7 @@ int xfrm_policy_flush(struct net *net, u8 type, stru= ct xfrm_audit *audit_info) } =20 } @@ -80471,7 +82804,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c= linux-2.6.32.49/net/xfrm/xfrm_ out: write_unlock_bh(&xfrm_policy_lock); return err; -@@ -1088,7 +1088,7 @@ int xfrm_policy_delete(struct xfrm_polic +@@ -1088,7 +1088,7 @@ int xfrm_policy_delete(struct xfrm_policy *pol, in= t dir) write_unlock_bh(&xfrm_policy_lock); if (pol) { if (dir < XFRM_POLICY_MAX) @@ -80489,7 +82822,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c= linux-2.6.32.49/net/xfrm/xfrm_ xfrm_dst_alloc_copy(void **target, void *src, int size) { if (!*target) { -@@ -1489,7 +1489,7 @@ xfrm_dst_alloc_copy(void **target, void=20 +@@ -1489,7 +1489,7 @@ xfrm_dst_alloc_copy(void **target, void *src, int = size) return 0; } =20 @@ -80498,7 +82831,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c= linux-2.6.32.49/net/xfrm/xfrm_ xfrm_dst_update_parent(struct dst_entry *dst, struct xfrm_selector *sel= ) { #ifdef CONFIG_XFRM_SUB_POLICY -@@ -1501,7 +1501,7 @@ xfrm_dst_update_parent(struct dst_entry=20 +@@ -1501,7 +1501,7 @@ xfrm_dst_update_parent(struct dst_entry *dst, stru= ct xfrm_selector *sel) #endif } =20 @@ -80507,7 +82840,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy.c= linux-2.6.32.49/net/xfrm/xfrm_ xfrm_dst_update_origin(struct dst_entry *dst, struct flowi *fl) { #ifdef CONFIG_XFRM_SUB_POLICY -@@ -1537,7 +1537,7 @@ int __xfrm_lookup(struct net *net, struc +@@ -1537,7 +1537,7 @@ int __xfrm_lookup(struct net *net, struct dst_entr= y **dst_p, struct flowi *fl, u8 dir =3D policy_to_flow_dir(XFRM_POLICY_OUT); =20 restart: @@ -80525,10 +82858,11 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_policy= .c linux-2.6.32.49/net/xfrm/xfrm_ xfrm_pols_put(pols, npols); goto restart; } -diff -urNp linux-2.6.32.49/net/xfrm/xfrm_user.c linux-2.6.32.49/net/xfrm= /xfrm_user.c ---- linux-2.6.32.49/net/xfrm/xfrm_user.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/net/xfrm/xfrm_user.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -1169,6 +1169,8 @@ static int copy_to_user_tmpl(struct xfrm +diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c +index b95a2d6..85c4d78 100644 +--- a/net/xfrm/xfrm_user.c ++++ b/net/xfrm/xfrm_user.c +@@ -1169,6 +1169,8 @@ static int copy_to_user_tmpl(struct xfrm_policy *x= p, struct sk_buff *skb) struct xfrm_user_tmpl vec[XFRM_MAX_DEPTH]; int i; =20 @@ -80537,7 +82871,7 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_user.c l= inux-2.6.32.49/net/xfrm/xfrm_us if (xp->xfrm_nr =3D=3D 0) return 0; =20 -@@ -1784,6 +1786,8 @@ static int xfrm_do_migrate(struct sk_buf +@@ -1784,6 +1786,8 @@ static int xfrm_do_migrate(struct sk_buff *skb, st= ruct nlmsghdr *nlh, int err; int n =3D 0; =20 @@ -80546,10 +82880,11 @@ diff -urNp linux-2.6.32.49/net/xfrm/xfrm_user.c= linux-2.6.32.49/net/xfrm/xfrm_us if (attrs[XFRMA_MIGRATE] =3D=3D NULL) return -EINVAL; =20 -diff -urNp linux-2.6.32.49/samples/kobject/kset-example.c linux-2.6.32.4= 9/samples/kobject/kset-example.c ---- linux-2.6.32.49/samples/kobject/kset-example.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/samples/kobject/kset-example.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -87,7 +87,7 @@ static ssize_t foo_attr_store(struct kob +diff --git a/samples/kobject/kset-example.c b/samples/kobject/kset-examp= le.c +index 45b7d56..19e828c 100644 +--- a/samples/kobject/kset-example.c ++++ b/samples/kobject/kset-example.c +@@ -87,7 +87,7 @@ static ssize_t foo_attr_store(struct kobject *kobj, } =20 /* Our custom sysfs_ops that we will associate with our ktype later on = */ @@ -80558,9 +82893,57 @@ diff -urNp linux-2.6.32.49/samples/kobject/kset-= example.c linux-2.6.32.49/sample .show =3D foo_attr_show, .store =3D foo_attr_store, }; -diff -urNp linux-2.6.32.49/scripts/basic/fixdep.c linux-2.6.32.49/script= s/basic/fixdep.c ---- linux-2.6.32.49/scripts/basic/fixdep.c 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/scripts/basic/fixdep.c 2011-11-15 19:59:43.000000000= -0500 +diff --git a/scripts/Makefile.build b/scripts/Makefile.build +index 341b589..405aed3 100644 +--- a/scripts/Makefile.build ++++ b/scripts/Makefile.build +@@ -59,7 +59,7 @@ endif + endif +=20 + # Do not include host rules unless needed +-ifneq ($(hostprogs-y)$(hostprogs-m),) ++ifneq ($(hostprogs-y)$(hostprogs-m)$(hostlibs-y)$(hostlibs-m),) + include scripts/Makefile.host + endif +=20 +diff --git a/scripts/Makefile.clean b/scripts/Makefile.clean +index 6f89fbb..53adc9c 100644 +--- a/scripts/Makefile.clean ++++ b/scripts/Makefile.clean +@@ -43,7 +43,8 @@ subdir-ymn :=3D $(addprefix $(obj)/,$(subdir-ymn)) + __clean-files :=3D $(extra-y) $(always) \ + $(targets) $(clean-files) \ + $(host-progs) \ +- $(hostprogs-y) $(hostprogs-m) $(hostprogs-) ++ $(hostprogs-y) $(hostprogs-m) $(hostprogs-) \ ++ $(hostlibs-y) $(hostlibs-m) $(hostlibs-) +=20 + # as clean-files is given relative to the current directory, this adds + # a $(obj) prefix, except for absolute paths +diff --git a/scripts/Makefile.host b/scripts/Makefile.host +index 1ac414f..a1c1451 100644 +--- a/scripts/Makefile.host ++++ b/scripts/Makefile.host +@@ -31,6 +31,7 @@ + # Note: Shared libraries consisting of C++ files are not supported +=20 + __hostprogs :=3D $(sort $(hostprogs-y) $(hostprogs-m)) ++__hostlibs :=3D $(sort $(hostlibs-y) $(hostlibs-m)) +=20 + # C code + # Executables compiled from a single .c file +@@ -54,6 +55,7 @@ host-cxxobjs :=3D $(sort $(foreach m,$(host-cxxmulti),= $($(m)-cxxobjs))) + # Shared libaries (only .c supported) + # Shared libraries (.so) - all .so files referenced in "xxx-objs" + host-cshlib :=3D $(sort $(filter %.so, $(host-cobjs))) ++host-cshlib +=3D $(sort $(filter %.so, $(__hostlibs))) + # Remove .so files from "xxx-objs" + host-cobjs :=3D $(filter-out %.so,$(host-cobjs)) +=20 +diff --git a/scripts/basic/fixdep.c b/scripts/basic/fixdep.c +index 6bf21f8..c0546b3 100644 +--- a/scripts/basic/fixdep.c ++++ b/scripts/basic/fixdep.c @@ -162,7 +162,7 @@ static void grow_config(int len) /* * Lookup a value in the configuration string. @@ -80579,7 +82962,7 @@ diff -urNp linux-2.6.32.49/scripts/basic/fixdep.c= linux-2.6.32.49/scripts/basic/ { char s[PATH_MAX]; char *p; -@@ -222,9 +222,9 @@ static void use_config(char *m, int slen +@@ -222,9 +222,9 @@ static void use_config(char *m, int slen) =20 static void parse_config_file(char *map, size_t len) { @@ -80600,60 +82983,19 @@ diff -urNp linux-2.6.32.49/scripts/basic/fixdep= .c linux-2.6.32.49/scripts/basic/ =20 if (*p !=3D INT_CONF) { fprintf(stderr, "fixdep: sizeof(int) !=3D 4 or wrong endianess? %#x\n= ", -diff -urNp linux-2.6.32.49/scripts/gcc-plugin.sh linux-2.6.32.49/scripts= /gcc-plugin.sh ---- linux-2.6.32.49/scripts/gcc-plugin.sh 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-2.6.32.49/scripts/gcc-plugin.sh 2011-11-20 19:22:02.000000000 = -0500 +diff --git a/scripts/gcc-plugin.sh b/scripts/gcc-plugin.sh +new file mode 100644 +index 0000000..8729101 +--- /dev/null ++++ b/scripts/gcc-plugin.sh @@ -0,0 +1,2 @@ +#!/bin/sh +echo -e "#include \"gcc-plugin.h\"\n#include \"tree.h\"\n#include \"tm.= h\"\n#include \"rtl.h\"" | $1 -x c -shared - -o /dev/null -I`$2 -print-fi= le-name=3Dplugin`/include >/dev/null 2>&1 && echo "y" -diff -urNp linux-2.6.32.49/scripts/Makefile.build linux-2.6.32.49/script= s/Makefile.build ---- linux-2.6.32.49/scripts/Makefile.build 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/scripts/Makefile.build 2011-11-15 19:59:43.000000000= -0500 -@@ -59,7 +59,7 @@ endif - endif -=20 - # Do not include host rules unless needed --ifneq ($(hostprogs-y)$(hostprogs-m),) -+ifneq ($(hostprogs-y)$(hostprogs-m)$(hostlibs-y)$(hostlibs-m),) - include scripts/Makefile.host - endif -=20 -diff -urNp linux-2.6.32.49/scripts/Makefile.clean linux-2.6.32.49/script= s/Makefile.clean ---- linux-2.6.32.49/scripts/Makefile.clean 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/scripts/Makefile.clean 2011-11-15 19:59:43.000000000= -0500 -@@ -43,7 +43,8 @@ subdir-ymn :=3D $(addprefix $(obj)/,$(subd - __clean-files :=3D $(extra-y) $(always) \ - $(targets) $(clean-files) \ - $(host-progs) \ -- $(hostprogs-y) $(hostprogs-m) $(hostprogs-) -+ $(hostprogs-y) $(hostprogs-m) $(hostprogs-) \ -+ $(hostlibs-y) $(hostlibs-m) $(hostlibs-) -=20 - # as clean-files is given relative to the current directory, this adds - # a $(obj) prefix, except for absolute paths -diff -urNp linux-2.6.32.49/scripts/Makefile.host linux-2.6.32.49/scripts= /Makefile.host ---- linux-2.6.32.49/scripts/Makefile.host 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/scripts/Makefile.host 2011-11-15 19:59:43.000000000 = -0500 -@@ -31,6 +31,7 @@ - # Note: Shared libraries consisting of C++ files are not supported -=20 - __hostprogs :=3D $(sort $(hostprogs-y) $(hostprogs-m)) -+__hostlibs :=3D $(sort $(hostlibs-y) $(hostlibs-m)) -=20 - # C code - # Executables compiled from a single .c file -@@ -54,6 +55,7 @@ host-cxxobjs :=3D $(sort $(foreach m,$(hos - # Shared libaries (only .c supported) - # Shared libraries (.so) - all .so files referenced in "xxx-objs" - host-cshlib :=3D $(sort $(filter %.so, $(host-cobjs))) -+host-cshlib +=3D $(sort $(filter %.so, $(__hostlibs))) - # Remove .so files from "xxx-objs" - host-cobjs :=3D $(filter-out %.so,$(host-cobjs)) -=20 -diff -urNp linux-2.6.32.49/scripts/mod/file2alias.c linux-2.6.32.49/scri= pts/mod/file2alias.c ---- linux-2.6.32.49/scripts/mod/file2alias.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/scripts/mod/file2alias.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -72,7 +72,7 @@ static void device_id_check(const char * +diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c +index 62a9025..65b82ad 100644 +--- a/scripts/mod/file2alias.c ++++ b/scripts/mod/file2alias.c +@@ -72,7 +72,7 @@ static void device_id_check(const char *modname, const= char *device_id, unsigned long size, unsigned long id_size, void *symval) { @@ -80662,7 +83004,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/file2alias= .c linux-2.6.32.49/scripts/mod/ =20 if (size % id_size || size < id_size) { if (cross_build !=3D 0) -@@ -102,7 +102,7 @@ static void device_id_check(const char * +@@ -102,7 +102,7 @@ static void device_id_check(const char *modname, con= st char *device_id, /* USB is special because the bcdDevice can be matched against a numeri= c range */ /* Looks like "usb:vNpNdNdcNdscNdpNicNiscNipN" */ static void do_usb_entry(struct usb_device_id *id, @@ -80671,7 +83013,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/file2alias= .c linux-2.6.32.49/scripts/mod/ unsigned char range_lo, unsigned char range_hi, struct module *mod) { -@@ -151,7 +151,7 @@ static void do_usb_entry_multi(struct us +@@ -151,7 +151,7 @@ static void do_usb_entry_multi(struct usb_device_id = *id, struct module *mod) { unsigned int devlo, devhi; unsigned char chi, clo; @@ -80680,7 +83022,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/file2alias= .c linux-2.6.32.49/scripts/mod/ =20 id->match_flags =3D TO_NATIVE(id->match_flags); id->idVendor =3D TO_NATIVE(id->idVendor); -@@ -368,7 +368,7 @@ static void do_pnp_device_entry(void *sy +@@ -368,7 +368,7 @@ static void do_pnp_device_entry(void *symval, unsign= ed long size, for (i =3D 0; i < count; i++) { const char *id =3D (char *)devs[i].id; char acpi_id[sizeof(devs[0].id)]; @@ -80689,7 +83031,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/file2alias= .c linux-2.6.32.49/scripts/mod/ =20 buf_printf(&mod->dev_table_buf, "MODULE_ALIAS(\"pnp:d%s*\");\n", id); -@@ -398,7 +398,7 @@ static void do_pnp_card_entries(void *sy +@@ -398,7 +398,7 @@ static void do_pnp_card_entries(void *symval, unsign= ed long size, =20 for (j =3D 0; j < PNP_MAX_DEVICES; j++) { const char *id =3D (char *)card->devs[j].id; @@ -80698,7 +83040,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/file2alias= .c linux-2.6.32.49/scripts/mod/ int dup =3D 0; =20 if (!id[0]) -@@ -424,7 +424,7 @@ static void do_pnp_card_entries(void *sy +@@ -424,7 +424,7 @@ static void do_pnp_card_entries(void *symval, unsign= ed long size, /* add an individual alias for every device entry */ if (!dup) { char acpi_id[sizeof(card->devs[0].id)]; @@ -80707,7 +83049,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/file2alias= .c linux-2.6.32.49/scripts/mod/ =20 buf_printf(&mod->dev_table_buf, "MODULE_ALIAS(\"pnp:d%s*\");\n", id); -@@ -699,7 +699,7 @@ static void dmi_ascii_filter(char *d, co +@@ -699,7 +699,7 @@ static void dmi_ascii_filter(char *d, const char *s) static int do_dmi_entry(const char *filename, struct dmi_system_id *id, char *alias) { @@ -80716,9 +83058,10 @@ diff -urNp linux-2.6.32.49/scripts/mod/file2alia= s.c linux-2.6.32.49/scripts/mod/ =20 sprintf(alias, "dmi*"); =20 -diff -urNp linux-2.6.32.49/scripts/mod/modpost.c linux-2.6.32.49/scripts= /mod/modpost.c ---- linux-2.6.32.49/scripts/mod/modpost.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/scripts/mod/modpost.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c +index 03efeab..0888989 100644 +--- a/scripts/mod/modpost.c ++++ b/scripts/mod/modpost.c @@ -835,6 +835,7 @@ enum mismatch { INIT_TO_EXIT, EXIT_TO_INIT, @@ -80727,7 +83070,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.c = linux-2.6.32.49/scripts/mod/mod }; =20 struct sectioncheck { -@@ -920,6 +921,12 @@ const struct sectioncheck sectioncheck[] +@@ -920,6 +921,12 @@ const struct sectioncheck sectioncheck[] =3D { .fromsec =3D { "__ksymtab*", NULL }, .tosec =3D { INIT_SECTIONS, EXIT_SECTIONS, NULL }, .mismatch =3D EXPORT_TO_INIT_EXIT @@ -80740,7 +83083,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.c = linux-2.6.32.49/scripts/mod/mod } }; =20 -@@ -1024,10 +1031,10 @@ static Elf_Sym *find_elf_symbol(struct e +@@ -1024,10 +1031,10 @@ static Elf_Sym *find_elf_symbol(struct elf_info = *elf, Elf64_Sword addr, continue; if (ELF_ST_TYPE(sym->st_info) =3D=3D STT_SECTION) continue; @@ -80753,7 +83096,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.c = linux-2.6.32.49/scripts/mod/mod if (d < 0) d =3D addr - sym->st_value; if (d < distance) { -@@ -1268,6 +1275,14 @@ static void report_sec_mismatch(const ch +@@ -1268,6 +1275,14 @@ static void report_sec_mismatch(const char *modna= me, enum mismatch mismatch, "Fix this by removing the %sannotation of %s " "or drop the export.\n", tosym, sec2annotation(tosec), sec2annotation(tosec), tosym); @@ -80768,7 +83111,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.c = linux-2.6.32.49/scripts/mod/mod case NO_MISMATCH: /* To get warnings on missing members */ break; -@@ -1495,7 +1510,7 @@ static void section_rel(const char *modn +@@ -1495,7 +1510,7 @@ static void section_rel(const char *modname, struc= t elf_info *elf, static void check_sec_ref(struct module *mod, const char *modname, struct elf_info *elf) { @@ -80777,7 +83120,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.c = linux-2.6.32.49/scripts/mod/mod Elf_Shdr *sechdrs =3D elf->sechdrs; =20 /* Walk through all sections */ -@@ -1651,7 +1666,7 @@ void __attribute__((format(printf, 2, 3) +@@ -1651,7 +1666,7 @@ void __attribute__((format(printf, 2, 3))) buf_pri= ntf(struct buffer *buf, va_end(ap); } =20 @@ -80786,7 +83129,7 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.c = linux-2.6.32.49/scripts/mod/mod { if (buf->size - buf->pos < len) { buf->size +=3D len + SZ; -@@ -1863,7 +1878,7 @@ static void write_if_changed(struct buff +@@ -1863,7 +1878,7 @@ static void write_if_changed(struct buffer *b, con= st char *fname) if (fstat(fileno(file), &st) < 0) goto close_write; =20 @@ -80795,10 +83138,11 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.= c linux-2.6.32.49/scripts/mod/mod goto close_write; =20 tmp =3D NOFAIL(malloc(b->pos)); -diff -urNp linux-2.6.32.49/scripts/mod/modpost.h linux-2.6.32.49/scripts= /mod/modpost.h ---- linux-2.6.32.49/scripts/mod/modpost.h 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/scripts/mod/modpost.h 2011-11-15 19:59:43.000000000 = -0500 -@@ -92,15 +92,15 @@ void *do_nofail(void *ptr, const char *e +diff --git a/scripts/mod/modpost.h b/scripts/mod/modpost.h +index 09f58e3..4b66092 100644 +--- a/scripts/mod/modpost.h ++++ b/scripts/mod/modpost.h +@@ -92,15 +92,15 @@ void *do_nofail(void *ptr, const char *expr); =20 struct buffer { char *p; @@ -80817,10 +83161,11 @@ diff -urNp linux-2.6.32.49/scripts/mod/modpost.= h linux-2.6.32.49/scripts/mod/mod =20 struct module { struct module *next; -diff -urNp linux-2.6.32.49/scripts/mod/sumversion.c linux-2.6.32.49/scri= pts/mod/sumversion.c ---- linux-2.6.32.49/scripts/mod/sumversion.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/scripts/mod/sumversion.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -455,7 +455,7 @@ static void write_version(const char *fi +diff --git a/scripts/mod/sumversion.c b/scripts/mod/sumversion.c +index ecf9c7d..d52b38e 100644 +--- a/scripts/mod/sumversion.c ++++ b/scripts/mod/sumversion.c +@@ -455,7 +455,7 @@ static void write_version(const char *filename, cons= t char *sum, goto out; } =20 @@ -80829,10 +83174,11 @@ diff -urNp linux-2.6.32.49/scripts/mod/sumversi= on.c linux-2.6.32.49/scripts/mod/ warn("writing sum in %s failed: %s\n", filename, strerror(errno)); goto out; -diff -urNp linux-2.6.32.49/scripts/package/mkspec linux-2.6.32.49/script= s/package/mkspec ---- linux-2.6.32.49/scripts/package/mkspec 2011-11-08 19:02:43.000000000= -0500 -+++ linux-2.6.32.49/scripts/package/mkspec 2011-11-15 19:59:43.000000000= -0500 -@@ -70,7 +70,7 @@ echo 'mkdir -p $RPM_BUILD_ROOT/boot $RPM +diff --git a/scripts/package/mkspec b/scripts/package/mkspec +index 47bdd2f..d4d4e93 100755 +--- a/scripts/package/mkspec ++++ b/scripts/package/mkspec +@@ -70,7 +70,7 @@ echo 'mkdir -p $RPM_BUILD_ROOT/boot $RPM_BUILD_ROOT/li= b/modules' echo 'mkdir -p $RPM_BUILD_ROOT/lib/firmware' echo "%endif" =20 @@ -80841,9 +83187,10 @@ diff -urNp linux-2.6.32.49/scripts/package/mkspe= c linux-2.6.32.49/scripts/packag echo "%ifarch ia64" echo 'cp $KBUILD_IMAGE $RPM_BUILD_ROOT'"/boot/efi/vmlinuz-$KERNELRELEAS= E" echo 'ln -s '"efi/vmlinuz-$KERNELRELEASE" '$RPM_BUILD_ROOT'"/boot/" -diff -urNp linux-2.6.32.49/scripts/pnmtologo.c linux-2.6.32.49/scripts/p= nmtologo.c ---- linux-2.6.32.49/scripts/pnmtologo.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/scripts/pnmtologo.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/scripts/pnmtologo.c b/scripts/pnmtologo.c +index 5c11312..72742b5 100644 +--- a/scripts/pnmtologo.c ++++ b/scripts/pnmtologo.c @@ -237,14 +237,14 @@ static void write_header(void) fprintf(out, " * Linux logo %s\n", logoname); fputs(" */\n\n", out); @@ -80870,9 +83217,10 @@ diff -urNp linux-2.6.32.49/scripts/pnmtologo.c l= inux-2.6.32.49/scripts/pnmtologo logoname); write_hex_cnt =3D 0; for (i =3D 0; i < logo_clutsize; i++) { -diff -urNp linux-2.6.32.49/scripts/tags.sh linux-2.6.32.49/scripts/tags.= sh ---- linux-2.6.32.49/scripts/tags.sh 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/scripts/tags.sh 2011-11-15 19:59:43.000000000 -0500 +diff --git a/scripts/tags.sh b/scripts/tags.sh +index d52f7a0..269eb1b 100755 +--- a/scripts/tags.sh ++++ b/scripts/tags.sh @@ -93,6 +93,11 @@ docscope() cscope -b -f cscope.out } @@ -80896,119 +83244,11 @@ diff -urNp linux-2.6.32.49/scripts/tags.sh lin= ux-2.6.32.49/scripts/tags.sh "tags") rm -f tags xtags ctags -diff -urNp linux-2.6.32.49/security/capability.c linux-2.6.32.49/securit= y/capability.c ---- linux-2.6.32.49/security/capability.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/security/capability.c 2011-11-15 19:59:43.000000000 = -0500 -@@ -890,7 +890,7 @@ static void cap_audit_rule_free(void *ls - } - #endif /* CONFIG_AUDIT */ -=20 --struct security_operations default_security_ops =3D { -+struct security_operations default_security_ops __read_only =3D { - .name =3D "default", - }; -=20 -diff -urNp linux-2.6.32.49/security/commoncap.c linux-2.6.32.49/security= /commoncap.c ---- linux-2.6.32.49/security/commoncap.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/security/commoncap.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -27,7 +27,7 @@ - #include - #include - #include -- -+#include - /* - * If a non-root user executes a setuid-root binary in - * !secure(SECURE_NOROOT) mode, then we raise capabilities. -@@ -50,9 +50,18 @@ static void warn_setuid_and_fcaps_mixed( - } - } -=20 -+#ifdef CONFIG_NET -+extern kernel_cap_t gr_cap_rtnetlink(struct sock *sk); -+#endif -+ - int cap_netlink_send(struct sock *sk, struct sk_buff *skb) - { -+#ifdef CONFIG_NET -+ NETLINK_CB(skb).eff_cap =3D gr_cap_rtnetlink(sk); -+#else - NETLINK_CB(skb).eff_cap =3D current_cap(); -+#endif -+=09 - return 0; - } -=20 -@@ -582,6 +591,9 @@ int cap_bprm_secureexec(struct linux_bin - { - const struct cred *cred =3D current_cred(); -=20 -+ if (gr_acl_enable_at_secure()) -+ return 1; -+ - if (cred->uid !=3D 0) { - if (bprm->cap_effective) - return 1; -diff -urNp linux-2.6.32.49/security/integrity/ima/ima_api.c linux-2.6.32= .49/security/integrity/ima/ima_api.c ---- linux-2.6.32.49/security/integrity/ima/ima_api.c 2011-11-08 19:02:43= .000000000 -0500 -+++ linux-2.6.32.49/security/integrity/ima/ima_api.c 2011-11-15 19:59:43= .000000000 -0500 -@@ -74,7 +74,7 @@ void ima_add_violation(struct inode *ino - int result; -=20 - /* can overflow, only indicator */ -- atomic_long_inc(&ima_htable.violations); -+ atomic_long_inc_unchecked(&ima_htable.violations); -=20 - entry =3D kmalloc(sizeof(*entry), GFP_KERNEL); - if (!entry) { -diff -urNp linux-2.6.32.49/security/integrity/ima/ima_fs.c linux-2.6.32.= 49/security/integrity/ima/ima_fs.c ---- linux-2.6.32.49/security/integrity/ima/ima_fs.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/security/integrity/ima/ima_fs.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -27,12 +27,12 @@ - static int valid_policy =3D 1; - #define TMPBUFLEN 12 - static ssize_t ima_show_htable_value(char __user *buf, size_t count, -- loff_t *ppos, atomic_long_t *val) -+ loff_t *ppos, atomic_long_unchecked_t *val) - { - char tmpbuf[TMPBUFLEN]; - ssize_t len; -=20 -- len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read(val)); -+ len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read_uncheck= ed(val)); - return simple_read_from_buffer(buf, count, ppos, tmpbuf, len); - } -=20 -diff -urNp linux-2.6.32.49/security/integrity/ima/ima.h linux-2.6.32.49/= security/integrity/ima/ima.h ---- linux-2.6.32.49/security/integrity/ima/ima.h 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/security/integrity/ima/ima.h 2011-11-15 19:59:43.000= 000000 -0500 -@@ -84,8 +84,8 @@ void ima_add_violation(struct inode *ino - extern spinlock_t ima_queue_lock; -=20 - struct ima_h_table { -- atomic_long_t len; /* number of stored measurements in the list */ -- atomic_long_t violations; -+ atomic_long_unchecked_t len; /* number of stored measurements in the l= ist */ -+ atomic_long_unchecked_t violations; - struct hlist_head queue[IMA_MEASURE_HTABLE_SIZE]; - }; - extern struct ima_h_table ima_htable; -diff -urNp linux-2.6.32.49/security/integrity/ima/ima_queue.c linux-2.6.= 32.49/security/integrity/ima/ima_queue.c ---- linux-2.6.32.49/security/integrity/ima/ima_queue.c 2011-11-08 19:02:= 43.000000000 -0500 -+++ linux-2.6.32.49/security/integrity/ima/ima_queue.c 2011-11-15 19:59:= 43.000000000 -0500 -@@ -78,7 +78,7 @@ static int ima_add_digest_entry(struct i - INIT_LIST_HEAD(&qe->later); - list_add_tail_rcu(&qe->later, &ima_measurements); -=20 -- atomic_long_inc(&ima_htable.len); -+ atomic_long_inc_unchecked(&ima_htable.len); - key =3D ima_hash_key(entry->digest); - hlist_add_head_rcu(&qe->hnext, &ima_htable.queue[key]); - return 0; -diff -urNp linux-2.6.32.49/security/Kconfig linux-2.6.32.49/security/Kco= nfig ---- linux-2.6.32.49/security/Kconfig 2011-11-08 19:02:43.000000000 -0500 -+++ linux-2.6.32.49/security/Kconfig 2011-11-15 19:59:43.000000000 -0500 -@@ -4,6 +4,559 @@ +diff --git a/security/Kconfig b/security/Kconfig +index fb363cd..14c747b 100644 +--- a/security/Kconfig ++++ b/security/Kconfig +@@ -4,6 +4,587 @@ =20 menu "Security options" =20 @@ -81341,6 +83581,34 @@ diff -urNp linux-2.6.32.49/security/Kconfig linu= x-2.6.32.49/security/Kconfig + Note that on x86_64 kernels there is a known regression when + this feature and KVM/VMX are both enabled in the host kernel. + ++choice ++ prompt "Return Address Instrumentation Method" ++ default PAX_KERNEXEC_PLUGIN_METHOD_BTS ++ depends on PAX_KERNEXEC_PLUGIN ++ help ++ Select the method used to instrument function pointer dereferences. ++ Note that binary modules cannot be instrumented by this approach. ++ ++ config PAX_KERNEXEC_PLUGIN_METHOD_BTS ++ bool "bts" ++ help ++ This method is compatible with binary only modules but has ++ a higher runtime overhead. ++ ++ config PAX_KERNEXEC_PLUGIN_METHOD_OR ++ bool "or" ++ depends on !PARAVIRT ++ help ++ This method is incompatible with binary only modules but has ++ a lower runtime overhead. ++endchoice ++ ++config PAX_KERNEXEC_PLUGIN_METHOD ++ string ++ default "bts" if PAX_KERNEXEC_PLUGIN_METHOD_BTS ++ default "or" if PAX_KERNEXEC_PLUGIN_METHOD_OR ++ default "" ++ +config PAX_KERNEXEC_MODULE_TEXT + int "Minimum amount of memory reserved for module code" + default "4" @@ -81568,7 +83836,7 @@ diff -urNp linux-2.6.32.49/security/Kconfig linux= -2.6.32.49/security/Kconfig config KEYS bool "Enable access key retention support" help -@@ -146,7 +699,7 @@ config INTEL_TXT +@@ -146,7 +727,7 @@ config INTEL_TXT config LSM_MMAP_MIN_ADDR int "Low address space for LSM to protect from user allocation" depends on SECURITY && SECURITY_SELINUX @@ -81577,10 +83845,126 @@ diff -urNp linux-2.6.32.49/security/Kconfig li= nux-2.6.32.49/security/Kconfig help This is the portion of low virtual memory which should be protected from userspace allocation. Keeping a user from writing to low pages -diff -urNp linux-2.6.32.49/security/keys/keyring.c linux-2.6.32.49/secur= ity/keys/keyring.c ---- linux-2.6.32.49/security/keys/keyring.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/security/keys/keyring.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -214,15 +214,15 @@ static long keyring_read(const struct ke +diff --git a/security/capability.c b/security/capability.c +index fce07a7..5f12858 100644 +--- a/security/capability.c ++++ b/security/capability.c +@@ -890,7 +890,7 @@ static void cap_audit_rule_free(void *lsmrule) + } + #endif /* CONFIG_AUDIT */ +=20 +-struct security_operations default_security_ops =3D { ++struct security_operations default_security_ops __read_only =3D { + .name =3D "default", + }; +=20 +diff --git a/security/commoncap.c b/security/commoncap.c +index fe30751..cdc60e1 100644 +--- a/security/commoncap.c ++++ b/security/commoncap.c +@@ -27,7 +27,7 @@ + #include + #include + #include +- ++#include + /* + * If a non-root user executes a setuid-root binary in + * !secure(SECURE_NOROOT) mode, then we raise capabilities. +@@ -50,9 +50,18 @@ static void warn_setuid_and_fcaps_mixed(char *fname) + } + } +=20 ++#ifdef CONFIG_NET ++extern kernel_cap_t gr_cap_rtnetlink(struct sock *sk); ++#endif ++ + int cap_netlink_send(struct sock *sk, struct sk_buff *skb) + { ++#ifdef CONFIG_NET ++ NETLINK_CB(skb).eff_cap =3D gr_cap_rtnetlink(sk); ++#else + NETLINK_CB(skb).eff_cap =3D current_cap(); ++#endif ++=09 + return 0; + } +=20 +@@ -582,6 +591,9 @@ int cap_bprm_secureexec(struct linux_binprm *bprm) + { + const struct cred *cred =3D current_cred(); +=20 ++ if (gr_acl_enable_at_secure()) ++ return 1; ++ + if (cred->uid !=3D 0) { + if (bprm->cap_effective) + return 1; +diff --git a/security/integrity/ima/ima.h b/security/integrity/ima/ima.h +index 165eb53..b1db4eb 100644 +--- a/security/integrity/ima/ima.h ++++ b/security/integrity/ima/ima.h +@@ -84,8 +84,8 @@ void ima_add_violation(struct inode *inode, const unsi= gned char *filename, + extern spinlock_t ima_queue_lock; +=20 + struct ima_h_table { +- atomic_long_t len; /* number of stored measurements in the list */ +- atomic_long_t violations; ++ atomic_long_unchecked_t len; /* number of stored measurements in the l= ist */ ++ atomic_long_unchecked_t violations; + struct hlist_head queue[IMA_MEASURE_HTABLE_SIZE]; + }; + extern struct ima_h_table ima_htable; +diff --git a/security/integrity/ima/ima_api.c b/security/integrity/ima/i= ma_api.c +index 3cd58b6..b4c284f 100644 +--- a/security/integrity/ima/ima_api.c ++++ b/security/integrity/ima/ima_api.c +@@ -74,7 +74,7 @@ void ima_add_violation(struct inode *inode, const unsi= gned char *filename, + int result; +=20 + /* can overflow, only indicator */ +- atomic_long_inc(&ima_htable.violations); ++ atomic_long_inc_unchecked(&ima_htable.violations); +=20 + entry =3D kmalloc(sizeof(*entry), GFP_KERNEL); + if (!entry) { +diff --git a/security/integrity/ima/ima_fs.c b/security/integrity/ima/im= a_fs.c +index 0c72c9c..433e29b 100644 +--- a/security/integrity/ima/ima_fs.c ++++ b/security/integrity/ima/ima_fs.c +@@ -27,12 +27,12 @@ + static int valid_policy =3D 1; + #define TMPBUFLEN 12 + static ssize_t ima_show_htable_value(char __user *buf, size_t count, +- loff_t *ppos, atomic_long_t *val) ++ loff_t *ppos, atomic_long_unchecked_t *val) + { + char tmpbuf[TMPBUFLEN]; + ssize_t len; +=20 +- len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read(val)); ++ len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read_uncheck= ed(val)); + return simple_read_from_buffer(buf, count, ppos, tmpbuf, len); + } +=20 +diff --git a/security/integrity/ima/ima_queue.c b/security/integrity/ima= /ima_queue.c +index a0880e9..93e4ebb 100644 +--- a/security/integrity/ima/ima_queue.c ++++ b/security/integrity/ima/ima_queue.c +@@ -78,7 +78,7 @@ static int ima_add_digest_entry(struct ima_template_en= try *entry) + INIT_LIST_HEAD(&qe->later); + list_add_tail_rcu(&qe->later, &ima_measurements); +=20 +- atomic_long_inc(&ima_htable.len); ++ atomic_long_inc_unchecked(&ima_htable.len); + key =3D ima_hash_key(entry->digest); + hlist_add_head_rcu(&qe->hnext, &ima_htable.queue[key]); + return 0; +diff --git a/security/keys/keyring.c b/security/keys/keyring.c +index e031952..c9a535d 100644 +--- a/security/keys/keyring.c ++++ b/security/keys/keyring.c +@@ -214,15 +214,15 @@ static long keyring_read(const struct key *keyring= , ret =3D -EFAULT; =20 for (loop =3D 0; loop < klist->nkeys; loop++) { @@ -81599,10 +83983,11 @@ diff -urNp linux-2.6.32.49/security/keys/keyrin= g.c linux-2.6.32.49/security/keys goto error; =20 buflen -=3D tmp; -diff -urNp linux-2.6.32.49/security/min_addr.c linux-2.6.32.49/security/= min_addr.c ---- linux-2.6.32.49/security/min_addr.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/security/min_addr.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -14,6 +14,7 @@ unsigned long dac_mmap_min_addr =3D CONFIG +diff --git a/security/min_addr.c b/security/min_addr.c +index d9f9425..c28cef4 100644 +--- a/security/min_addr.c ++++ b/security/min_addr.c +@@ -14,6 +14,7 @@ unsigned long dac_mmap_min_addr =3D CONFIG_DEFAULT_MMA= P_MIN_ADDR; */ static void update_mmap_min_addr(void) { @@ -81618,10 +84003,11 @@ diff -urNp linux-2.6.32.49/security/min_addr.c = linux-2.6.32.49/security/min_addr } =20 /* -diff -urNp linux-2.6.32.49/security/root_plug.c linux-2.6.32.49/security= /root_plug.c ---- linux-2.6.32.49/security/root_plug.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/security/root_plug.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -70,7 +70,7 @@ static int rootplug_bprm_check_security=20 +diff --git a/security/root_plug.c b/security/root_plug.c +index 2f7ffa6..0455400 100644 +--- a/security/root_plug.c ++++ b/security/root_plug.c +@@ -70,7 +70,7 @@ static int rootplug_bprm_check_security (struct linux_= binprm *bprm) return 0; } =20 @@ -81630,10 +84016,11 @@ diff -urNp linux-2.6.32.49/security/root_plug.c= linux-2.6.32.49/security/root_pl .bprm_check_security =3D rootplug_bprm_check_security, }; =20 -diff -urNp linux-2.6.32.49/security/security.c linux-2.6.32.49/security/= security.c ---- linux-2.6.32.49/security/security.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/security/security.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -24,7 +24,7 @@ static __initdata char chosen_lsm[SECURI +diff --git a/security/security.c b/security/security.c +index c4c6732..3a3d821 100644 +--- a/security/security.c ++++ b/security/security.c +@@ -24,7 +24,7 @@ static __initdata char chosen_lsm[SECURITY_NAME_MAX + = 1]; extern struct security_operations default_security_ops; extern void security_fixup_ops(struct security_operations *ops); =20 @@ -81642,7 +84029,7 @@ diff -urNp linux-2.6.32.49/security/security.c li= nux-2.6.32.49/security/security =20 static inline int verify(struct security_operations *ops) { -@@ -106,7 +106,7 @@ int __init security_module_enable(struct +@@ -106,7 +106,7 @@ int __init security_module_enable(struct security_op= erations *ops) * If there is already a security module registered with the kernel, * an error will be returned. Otherwise %0 is returned on success. */ @@ -81651,9 +84038,10 @@ diff -urNp linux-2.6.32.49/security/security.c l= inux-2.6.32.49/security/security { if (verify(ops)) { printk(KERN_DEBUG "%s could not verify " -diff -urNp linux-2.6.32.49/security/selinux/hooks.c linux-2.6.32.49/secu= rity/selinux/hooks.c ---- linux-2.6.32.49/security/selinux/hooks.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/security/selinux/hooks.c 2011-11-15 19:59:43.0000000= 00 -0500 +diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c +index a106754..2805823 100644 +--- a/security/selinux/hooks.c ++++ b/security/selinux/hooks.c @@ -131,7 +131,7 @@ int selinux_enabled =3D 1; * Minimal support for a secondary security module, * just to allow the use of the capability module. @@ -81663,7 +84051,7 @@ diff -urNp linux-2.6.32.49/security/selinux/hooks= .c linux-2.6.32.49/security/sel =20 /* Lists of inode and superblock security structures initialized before the policy was loaded. */ -@@ -5457,7 +5457,7 @@ static int selinux_key_getsecurity(struc +@@ -5457,7 +5457,7 @@ static int selinux_key_getsecurity(struct key *key= , char **_buffer) =20 #endif =20 @@ -81682,10 +84070,11 @@ diff -urNp linux-2.6.32.49/security/selinux/hoo= ks.c linux-2.6.32.49/security/sel =20 /* Unregister netfilter hooks. */ selinux_nf_ip_exit(); -diff -urNp linux-2.6.32.49/security/selinux/include/xfrm.h linux-2.6.32.= 49/security/selinux/include/xfrm.h ---- linux-2.6.32.49/security/selinux/include/xfrm.h 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/security/selinux/include/xfrm.h 2011-11-15 19:59:43.= 000000000 -0500 -@@ -48,7 +48,7 @@ int selinux_xfrm_decode_session(struct s +diff --git a/security/selinux/include/xfrm.h b/security/selinux/include/= xfrm.h +index 13128f9..c23c736 100644 +--- a/security/selinux/include/xfrm.h ++++ b/security/selinux/include/xfrm.h +@@ -48,7 +48,7 @@ int selinux_xfrm_decode_session(struct sk_buff *skb, u= 32 *sid, int ckall); =20 static inline void selinux_xfrm_notify_policyload(void) { @@ -81694,10 +84083,11 @@ diff -urNp linux-2.6.32.49/security/selinux/inc= lude/xfrm.h linux-2.6.32.49/secur } #else static inline int selinux_xfrm_enabled(void) -diff -urNp linux-2.6.32.49/security/selinux/ss/services.c linux-2.6.32.4= 9/security/selinux/ss/services.c ---- linux-2.6.32.49/security/selinux/ss/services.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/security/selinux/ss/services.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -1715,6 +1715,8 @@ int security_load_policy(void *data, siz +diff --git a/security/selinux/ss/services.c b/security/selinux/ss/servic= es.c +index ff17820..d68084c 100644 +--- a/security/selinux/ss/services.c ++++ b/security/selinux/ss/services.c +@@ -1715,6 +1715,8 @@ int security_load_policy(void *data, size_t len) int rc =3D 0; struct policy_file file =3D { data, len }, *fp =3D &file; =20 @@ -81706,10 +84096,11 @@ diff -urNp linux-2.6.32.49/security/selinux/ss/= services.c linux-2.6.32.49/securi if (!ss_initialized) { avtab_cache_init(); if (policydb_read(&policydb, fp)) { -diff -urNp linux-2.6.32.49/security/smack/smack_lsm.c linux-2.6.32.49/se= curity/smack/smack_lsm.c ---- linux-2.6.32.49/security/smack/smack_lsm.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/security/smack/smack_lsm.c 2011-11-15 19:59:43.00000= 0000 -0500 -@@ -3073,7 +3073,7 @@ static int smack_inode_getsecctx(struct=20 +diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c +index c33b6bb..9651403 100644 +--- a/security/smack/smack_lsm.c ++++ b/security/smack/smack_lsm.c +@@ -3073,7 +3073,7 @@ static int smack_inode_getsecctx(struct inode *ino= de, void **ctx, u32 *ctxlen) return 0; } =20 @@ -81718,10 +84109,11 @@ diff -urNp linux-2.6.32.49/security/smack/smack= _lsm.c linux-2.6.32.49/security/s .name =3D "smack", =20 .ptrace_access_check =3D smack_ptrace_access_check, -diff -urNp linux-2.6.32.49/security/tomoyo/tomoyo.c linux-2.6.32.49/secu= rity/tomoyo/tomoyo.c ---- linux-2.6.32.49/security/tomoyo/tomoyo.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/security/tomoyo/tomoyo.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -275,7 +275,7 @@ static int tomoyo_dentry_open(struct fil +diff --git a/security/tomoyo/tomoyo.c b/security/tomoyo/tomoyo.c +index 9548a09..9a5f384 100644 +--- a/security/tomoyo/tomoyo.c ++++ b/security/tomoyo/tomoyo.c +@@ -275,7 +275,7 @@ static int tomoyo_dentry_open(struct file *f, const = struct cred *cred) * tomoyo_security_ops is a "struct security_operations" which is used = for * registering TOMOYO. */ @@ -81730,9 +84122,10 @@ diff -urNp linux-2.6.32.49/security/tomoyo/tomoy= o.c linux-2.6.32.49/security/tom .name =3D "tomoyo", .cred_alloc_blank =3D tomoyo_cred_alloc_blank, .cred_prepare =3D tomoyo_cred_prepare, -diff -urNp linux-2.6.32.49/sound/aoa/codecs/onyx.c linux-2.6.32.49/sound= /aoa/codecs/onyx.c ---- linux-2.6.32.49/sound/aoa/codecs/onyx.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/sound/aoa/codecs/onyx.c 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/sound/aoa/codecs/onyx.c b/sound/aoa/codecs/onyx.c +index 84bb07d..c2ab6b6 100644 +--- a/sound/aoa/codecs/onyx.c ++++ b/sound/aoa/codecs/onyx.c @@ -53,7 +53,7 @@ struct onyx { spdif_locked:1, analog_locked:1, @@ -81742,7 +84135,7 @@ diff -urNp linux-2.6.32.49/sound/aoa/codecs/onyx.= c linux-2.6.32.49/sound/aoa/cod struct codec_info *codec_info; =20 /* mutex serializes concurrent access to the device -@@ -752,7 +752,7 @@ static int onyx_open(struct codec_info_i +@@ -752,7 +752,7 @@ static int onyx_open(struct codec_info_item *cii, struct onyx *onyx =3D cii->codec_data; =20 mutex_lock(&onyx->mutex); @@ -81751,7 +84144,7 @@ diff -urNp linux-2.6.32.49/sound/aoa/codecs/onyx.= c linux-2.6.32.49/sound/aoa/cod mutex_unlock(&onyx->mutex); =20 return 0; -@@ -764,8 +764,7 @@ static int onyx_close(struct codec_info_ +@@ -764,8 +764,7 @@ static int onyx_close(struct codec_info_item *cii, struct onyx *onyx =3D cii->codec_data; =20 mutex_lock(&onyx->mutex); @@ -81761,9 +84154,10 @@ diff -urNp linux-2.6.32.49/sound/aoa/codecs/onyx= .c linux-2.6.32.49/sound/aoa/cod onyx->spdif_locked =3D onyx->analog_locked =3D 0; mutex_unlock(&onyx->mutex); =20 -diff -urNp linux-2.6.32.49/sound/aoa/codecs/onyx.h linux-2.6.32.49/sound= /aoa/codecs/onyx.h ---- linux-2.6.32.49/sound/aoa/codecs/onyx.h 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/sound/aoa/codecs/onyx.h 2011-11-15 19:59:43.00000000= 0 -0500 +diff --git a/sound/aoa/codecs/onyx.h b/sound/aoa/codecs/onyx.h +index ffd2025..df062c9 100644 +--- a/sound/aoa/codecs/onyx.h ++++ b/sound/aoa/codecs/onyx.h @@ -11,6 +11,7 @@ #include #include @@ -81772,10 +84166,11 @@ diff -urNp linux-2.6.32.49/sound/aoa/codecs/ony= x.h linux-2.6.32.49/sound/aoa/cod =20 /* PCM3052 register definitions */ =20 -diff -urNp linux-2.6.32.49/sound/core/oss/pcm_oss.c linux-2.6.32.49/soun= d/core/oss/pcm_oss.c ---- linux-2.6.32.49/sound/core/oss/pcm_oss.c 2011-11-08 19:02:43.0000000= 00 -0500 -+++ linux-2.6.32.49/sound/core/oss/pcm_oss.c 2011-11-15 19:59:43.0000000= 00 -0500 -@@ -1395,7 +1395,7 @@ static ssize_t snd_pcm_oss_write1(struct +diff --git a/sound/core/oss/pcm_oss.c b/sound/core/oss/pcm_oss.c +index d9c9635..bc0a5a2 100644 +--- a/sound/core/oss/pcm_oss.c ++++ b/sound/core/oss/pcm_oss.c +@@ -1395,7 +1395,7 @@ static ssize_t snd_pcm_oss_write1(struct snd_pcm_s= ubstream *substream, const cha } } else { tmp =3D snd_pcm_oss_write2(substream, @@ -81784,7 +84179,7 @@ diff -urNp linux-2.6.32.49/sound/core/oss/pcm_oss= .c linux-2.6.32.49/sound/core/o runtime->oss.period_bytes, 0); if (tmp <=3D 0) goto err; -@@ -1483,7 +1483,7 @@ static ssize_t snd_pcm_oss_read1(struct=20 +@@ -1483,7 +1483,7 @@ static ssize_t snd_pcm_oss_read1(struct snd_pcm_su= bstream *substream, char __use xfer +=3D tmp; runtime->oss.buffer_used -=3D tmp; } else { @@ -81793,10 +84188,11 @@ diff -urNp linux-2.6.32.49/sound/core/oss/pcm_o= ss.c linux-2.6.32.49/sound/core/o runtime->oss.period_bytes, 0); if (tmp <=3D 0) goto err; -diff -urNp linux-2.6.32.49/sound/core/pcm_compat.c linux-2.6.32.49/sound= /core/pcm_compat.c ---- linux-2.6.32.49/sound/core/pcm_compat.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/sound/core/pcm_compat.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -30,7 +30,7 @@ static int snd_pcm_ioctl_delay_compat(st +diff --git a/sound/core/pcm_compat.c b/sound/core/pcm_compat.c +index 038232d..7dd9e5c 100644 +--- a/sound/core/pcm_compat.c ++++ b/sound/core/pcm_compat.c +@@ -30,7 +30,7 @@ static int snd_pcm_ioctl_delay_compat(struct snd_pcm_s= ubstream *substream, int err; =20 fs =3D snd_enter_user(); @@ -81805,10 +84201,11 @@ diff -urNp linux-2.6.32.49/sound/core/pcm_compa= t.c linux-2.6.32.49/sound/core/pc snd_leave_user(fs); if (err < 0) return err; -diff -urNp linux-2.6.32.49/sound/core/pcm_native.c linux-2.6.32.49/sound= /core/pcm_native.c ---- linux-2.6.32.49/sound/core/pcm_native.c 2011-11-08 19:02:43.00000000= 0 -0500 -+++ linux-2.6.32.49/sound/core/pcm_native.c 2011-11-15 19:59:43.00000000= 0 -0500 -@@ -2747,11 +2747,11 @@ int snd_pcm_kernel_ioctl(struct snd_pcm_ +diff --git a/sound/core/pcm_native.c b/sound/core/pcm_native.c +index e6d2d97..4843949 100644 +--- a/sound/core/pcm_native.c ++++ b/sound/core/pcm_native.c +@@ -2747,11 +2747,11 @@ int snd_pcm_kernel_ioctl(struct snd_pcm_substrea= m *substream, switch (substream->stream) { case SNDRV_PCM_STREAM_PLAYBACK: result =3D snd_pcm_playback_ioctl1(NULL, substream, cmd, @@ -81822,9 +84219,10 @@ diff -urNp linux-2.6.32.49/sound/core/pcm_native= .c linux-2.6.32.49/sound/core/pc break; default: result =3D -EINVAL; -diff -urNp linux-2.6.32.49/sound/core/seq/seq_device.c linux-2.6.32.49/s= ound/core/seq/seq_device.c ---- linux-2.6.32.49/sound/core/seq/seq_device.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/sound/core/seq/seq_device.c 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/sound/core/seq/seq_device.c b/sound/core/seq/seq_device.c +index 1f99767..14636533 100644 +--- a/sound/core/seq/seq_device.c ++++ b/sound/core/seq/seq_device.c @@ -63,7 +63,7 @@ struct ops_list { int argsize; /* argument size */ =20 @@ -81834,7 +84232,7 @@ diff -urNp linux-2.6.32.49/sound/core/seq/seq_dev= ice.c linux-2.6.32.49/sound/cor =20 /* registred devices */ struct list_head dev_list; /* list of devices */ -@@ -332,7 +332,7 @@ int snd_seq_device_register_driver(char=20 +@@ -332,7 +332,7 @@ int snd_seq_device_register_driver(char *id, struct = snd_seq_dev_ops *entry, =20 mutex_lock(&ops->reg_mutex); /* copy driver operators */ @@ -81843,7 +84241,7 @@ diff -urNp linux-2.6.32.49/sound/core/seq/seq_dev= ice.c linux-2.6.32.49/sound/cor ops->driver |=3D DRIVER_LOADED; ops->argsize =3D argsize; =20 -@@ -462,7 +462,7 @@ static int init_device(struct snd_seq_de +@@ -462,7 +462,7 @@ static int init_device(struct snd_seq_device *dev, s= truct ops_list *ops) dev->name, ops->id, ops->argsize, dev->argsize); return -EINVAL; } @@ -81852,7 +84250,7 @@ diff -urNp linux-2.6.32.49/sound/core/seq/seq_dev= ice.c linux-2.6.32.49/sound/cor dev->status =3D SNDRV_SEQ_DEVICE_REGISTERED; ops->num_init_devices++; } else { -@@ -489,7 +489,7 @@ static int free_device(struct snd_seq_de +@@ -489,7 +489,7 @@ static int free_device(struct snd_seq_device *dev, s= truct ops_list *ops) dev->name, ops->id, ops->argsize, dev->argsize); return -EINVAL; } @@ -81861,9 +84259,10 @@ diff -urNp linux-2.6.32.49/sound/core/seq/seq_de= vice.c linux-2.6.32.49/sound/cor dev->status =3D SNDRV_SEQ_DEVICE_FREE; dev->driver_data =3D NULL; ops->num_init_devices--; -diff -urNp linux-2.6.32.49/sound/drivers/mts64.c linux-2.6.32.49/sound/d= rivers/mts64.c ---- linux-2.6.32.49/sound/drivers/mts64.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/sound/drivers/mts64.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/sound/drivers/mts64.c b/sound/drivers/mts64.c +index 9284829..ac8e8b2 100644 +--- a/sound/drivers/mts64.c ++++ b/sound/drivers/mts64.c @@ -27,6 +27,7 @@ #include #include @@ -81881,7 +84280,7 @@ diff -urNp linux-2.6.32.49/sound/drivers/mts64.c = linux-2.6.32.49/sound/drivers/m int current_midi_output_port; int current_midi_input_port; u8 mode[MTS64_NUM_INPUT_PORTS]; -@@ -695,7 +696,7 @@ static int snd_mts64_rawmidi_open(struct +@@ -695,7 +696,7 @@ static int snd_mts64_rawmidi_open(struct snd_rawmidi= _substream *substream) { struct mts64 *mts =3D substream->rmidi->private_data; =20 @@ -81890,7 +84289,7 @@ diff -urNp linux-2.6.32.49/sound/drivers/mts64.c = linux-2.6.32.49/sound/drivers/m /* We don't need a spinlock here, because this is just called=20 if the device has not been opened before.=20 So there aren't any IRQs from the device */ -@@ -703,7 +704,7 @@ static int snd_mts64_rawmidi_open(struct +@@ -703,7 +704,7 @@ static int snd_mts64_rawmidi_open(struct snd_rawmidi= _substream *substream) =20 msleep(50); } @@ -81899,7 +84298,7 @@ diff -urNp linux-2.6.32.49/sound/drivers/mts64.c = linux-2.6.32.49/sound/drivers/m =20 return 0; } -@@ -713,8 +714,7 @@ static int snd_mts64_rawmidi_close(struc +@@ -713,8 +714,7 @@ static int snd_mts64_rawmidi_close(struct snd_rawmid= i_substream *substream) struct mts64 *mts =3D substream->rmidi->private_data; unsigned long flags; =20 @@ -81909,7 +84308,7 @@ diff -urNp linux-2.6.32.49/sound/drivers/mts64.c = linux-2.6.32.49/sound/drivers/m /* We need the spinlock_irqsave here because we can still have IRQs at this point */ spin_lock_irqsave(&mts->lock, flags); -@@ -723,8 +723,8 @@ static int snd_mts64_rawmidi_close(struc +@@ -723,8 +723,8 @@ static int snd_mts64_rawmidi_close(struct snd_rawmid= i_substream *substream) =20 msleep(500); =20 @@ -81920,10 +84319,11 @@ diff -urNp linux-2.6.32.49/sound/drivers/mts64.= c linux-2.6.32.49/sound/drivers/m =20 return 0; } -diff -urNp linux-2.6.32.49/sound/drivers/opl4/opl4_lib.c linux-2.6.32.49= /sound/drivers/opl4/opl4_lib.c ---- linux-2.6.32.49/sound/drivers/opl4/opl4_lib.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/sound/drivers/opl4/opl4_lib.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -27,7 +27,7 @@ MODULE_AUTHOR("Clemens Ladisch "); MODULE_DESCRIPTION("OPL4 driver"); MODULE_LICENSE("GPL"); =20 @@ -81932,9 +84332,10 @@ diff -urNp linux-2.6.32.49/sound/drivers/opl4/op= l4_lib.c linux-2.6.32.49/sound/d { int timeout =3D 10; while ((inb(opl4->fm_port) & OPL4_STATUS_BUSY) && --timeout > 0) -diff -urNp linux-2.6.32.49/sound/drivers/portman2x4.c linux-2.6.32.49/so= und/drivers/portman2x4.c ---- linux-2.6.32.49/sound/drivers/portman2x4.c 2011-11-08 19:02:43.00000= 0000 -0500 -+++ linux-2.6.32.49/sound/drivers/portman2x4.c 2011-11-15 19:59:43.00000= 0000 -0500 +diff --git a/sound/drivers/portman2x4.c b/sound/drivers/portman2x4.c +index 60158e2..0a0cc1a 100644 +--- a/sound/drivers/portman2x4.c ++++ b/sound/drivers/portman2x4.c @@ -46,6 +46,7 @@ #include #include @@ -81952,9 +84353,10 @@ diff -urNp linux-2.6.32.49/sound/drivers/portman= 2x4.c linux-2.6.32.49/sound/driv int mode[PORTMAN_NUM_INPUT_PORTS]; struct snd_rawmidi_substream *midi_input[PORTMAN_NUM_INPUT_PORTS]; }; -diff -urNp linux-2.6.32.49/sound/isa/cmi8330.c linux-2.6.32.49/sound/isa= /cmi8330.c ---- linux-2.6.32.49/sound/isa/cmi8330.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/sound/isa/cmi8330.c 2011-11-15 19:59:43.000000000 -0= 500 +diff --git a/sound/isa/cmi8330.c b/sound/isa/cmi8330.c +index 02f79d2..8691d43 100644 +--- a/sound/isa/cmi8330.c ++++ b/sound/isa/cmi8330.c @@ -173,7 +173,7 @@ struct snd_cmi8330 { =20 struct snd_pcm *pcm; @@ -81964,9 +84366,10 @@ diff -urNp linux-2.6.32.49/sound/isa/cmi8330.c l= inux-2.6.32.49/sound/isa/cmi8330 snd_pcm_open_callback_t open; void *private_data; /* sb or wss */ } streams[2]; -diff -urNp linux-2.6.32.49/sound/oss/sb_audio.c linux-2.6.32.49/sound/os= s/sb_audio.c ---- linux-2.6.32.49/sound/oss/sb_audio.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/sound/oss/sb_audio.c 2011-11-15 19:59:43.000000000 -= 0500 +diff --git a/sound/oss/sb_audio.c b/sound/oss/sb_audio.c +index 733b014..56ce96f 100644 +--- a/sound/oss/sb_audio.c ++++ b/sound/oss/sb_audio.c @@ -901,7 +901,7 @@ sb16_copy_from_user(int dev, buf16 =3D (signed short *)(localbuf + localoffs); while (c) @@ -81976,9 +84379,10 @@ diff -urNp linux-2.6.32.49/sound/oss/sb_audio.c = linux-2.6.32.49/sound/oss/sb_aud if (copy_from_user(lbuf8, userbuf+useroffs + p, locallen)) -diff -urNp linux-2.6.32.49/sound/oss/swarm_cs4297a.c linux-2.6.32.49/sou= nd/oss/swarm_cs4297a.c ---- linux-2.6.32.49/sound/oss/swarm_cs4297a.c 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/sound/oss/swarm_cs4297a.c 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/sound/oss/swarm_cs4297a.c b/sound/oss/swarm_cs4297a.c +index 3136c88..28ad950 100644 +--- a/sound/oss/swarm_cs4297a.c ++++ b/sound/oss/swarm_cs4297a.c @@ -2577,7 +2577,6 @@ static int __init cs4297a_init(void) { struct cs4297a_state *s; @@ -82013,10 +84417,11 @@ diff -urNp linux-2.6.32.49/sound/oss/swarm_cs42= 97a.c linux-2.6.32.49/sound/oss/s =20 list_add(&s->list, &cs4297a_devs); =20 -diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_codec.c linux-2.6.32.49/s= ound/pci/ac97/ac97_codec.c ---- linux-2.6.32.49/sound/pci/ac97/ac97_codec.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/sound/pci/ac97/ac97_codec.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -1952,7 +1952,7 @@ static int snd_ac97_dev_disconnect(struc +diff --git a/sound/pci/ac97/ac97_codec.c b/sound/pci/ac97/ac97_codec.c +index 78288db..0406809 100644 +--- a/sound/pci/ac97/ac97_codec.c ++++ b/sound/pci/ac97/ac97_codec.c +@@ -1952,7 +1952,7 @@ static int snd_ac97_dev_disconnect(struct snd_devi= ce *device) } =20 /* build_ops to do nothing */ @@ -82025,10 +84430,11 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_= codec.c linux-2.6.32.49/sound/pci =20 #ifdef CONFIG_SND_AC97_POWER_SAVE static void do_update_power(struct work_struct *work) -diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_patch.c linux-2.6.32.49/s= ound/pci/ac97/ac97_patch.c ---- linux-2.6.32.49/sound/pci/ac97/ac97_patch.c 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/sound/pci/ac97/ac97_patch.c 2011-11-15 19:59:43.0000= 00000 -0500 -@@ -371,7 +371,7 @@ static int patch_yamaha_ymf743_build_spd +diff --git a/sound/pci/ac97/ac97_patch.c b/sound/pci/ac97/ac97_patch.c +index eeb2e23..82bf625 100644 +--- a/sound/pci/ac97/ac97_patch.c ++++ b/sound/pci/ac97/ac97_patch.c +@@ -371,7 +371,7 @@ static int patch_yamaha_ymf743_build_spdif(struct sn= d_ac97 *ac97) return 0; } =20 @@ -82037,7 +84443,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_spdif =3D patch_yamaha_ymf743_build_spdif, .build_3d =3D patch_yamaha_ymf7x3_3d, }; -@@ -455,7 +455,7 @@ static int patch_yamaha_ymf753_post_spdi +@@ -455,7 +455,7 @@ static int patch_yamaha_ymf753_post_spdif(struct snd= _ac97 * ac97) return 0; } =20 @@ -82046,7 +84452,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_3d =3D patch_yamaha_ymf7x3_3d, .build_post_spdif =3D patch_yamaha_ymf753_post_spdif }; -@@ -502,7 +502,7 @@ static int patch_wolfson_wm9703_specific +@@ -502,7 +502,7 @@ static int patch_wolfson_wm9703_specific(struct snd_= ac97 * ac97) return 0; } =20 @@ -82055,7 +84461,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_wolfson_wm9703_specific, }; =20 -@@ -533,7 +533,7 @@ static int patch_wolfson_wm9704_specific +@@ -533,7 +533,7 @@ static int patch_wolfson_wm9704_specific(struct snd_= ac97 * ac97) return 0; } =20 @@ -82064,7 +84470,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_wolfson_wm9704_specific, }; =20 -@@ -555,7 +555,7 @@ static int patch_wolfson_wm9705_specific +@@ -555,7 +555,7 @@ static int patch_wolfson_wm9705_specific(struct snd_= ac97 * ac97) return 0; } =20 @@ -82073,7 +84479,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_wolfson_wm9705_specific, }; =20 -@@ -692,7 +692,7 @@ static int patch_wolfson_wm9711_specific +@@ -692,7 +692,7 @@ static int patch_wolfson_wm9711_specific(struct snd_= ac97 * ac97) return 0; } =20 @@ -82082,7 +84488,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_wolfson_wm9711_specific, }; =20 -@@ -886,7 +886,7 @@ static void patch_wolfson_wm9713_resume=20 +@@ -886,7 +886,7 @@ static void patch_wolfson_wm9713_resume (struct snd_= ac97 * ac97) } #endif =20 @@ -82091,7 +84497,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_wolfson_wm9713_specific, .build_3d =3D patch_wolfson_wm9713_3d, #ifdef CONFIG_PM=09 -@@ -991,7 +991,7 @@ static int patch_sigmatel_stac97xx_speci +@@ -991,7 +991,7 @@ static int patch_sigmatel_stac97xx_specific(struct s= nd_ac97 * ac97) return 0; } =20 @@ -82100,7 +84506,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_3d =3D patch_sigmatel_stac9700_3d, .build_specific =3D patch_sigmatel_stac97xx_specific }; -@@ -1038,7 +1038,7 @@ static int patch_sigmatel_stac9708_speci +@@ -1038,7 +1038,7 @@ static int patch_sigmatel_stac9708_specific(struct= snd_ac97 *ac97) return patch_sigmatel_stac97xx_specific(ac97); } =20 @@ -82109,7 +84515,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_3d =3D patch_sigmatel_stac9708_3d, .build_specific =3D patch_sigmatel_stac9708_specific }; -@@ -1267,7 +1267,7 @@ static int patch_sigmatel_stac9758_speci +@@ -1267,7 +1267,7 @@ static int patch_sigmatel_stac9758_specific(struct= snd_ac97 *ac97) return 0; } =20 @@ -82118,7 +84524,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_3d =3D patch_sigmatel_stac9700_3d, .build_specific =3D patch_sigmatel_stac9758_specific }; -@@ -1342,7 +1342,7 @@ static int patch_cirrus_build_spdif(stru +@@ -1342,7 +1342,7 @@ static int patch_cirrus_build_spdif(struct snd_ac9= 7 * ac97) return 0; } =20 @@ -82127,7 +84533,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_spdif =3D patch_cirrus_build_spdif }; =20 -@@ -1399,7 +1399,7 @@ static int patch_conexant_build_spdif(st +@@ -1399,7 +1399,7 @@ static int patch_conexant_build_spdif(struct snd_a= c97 * ac97) return 0; } =20 @@ -82136,7 +84542,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_spdif =3D patch_conexant_build_spdif }; =20 -@@ -1575,7 +1575,7 @@ static void patch_ad1881_chained(struct=20 +@@ -1575,7 +1575,7 @@ static void patch_ad1881_chained(struct snd_ac97 *= ac97, int unchained_idx, int } } =20 @@ -82145,7 +84551,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci #ifdef CONFIG_PM .resume =3D ad18xx_resume #endif -@@ -1662,7 +1662,7 @@ static int patch_ad1885_specific(struct=20 +@@ -1662,7 +1662,7 @@ static int patch_ad1885_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82154,7 +84560,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D &patch_ad1885_specific, #ifdef CONFIG_PM .resume =3D ad18xx_resume -@@ -1689,7 +1689,7 @@ static int patch_ad1886_specific(struct=20 +@@ -1689,7 +1689,7 @@ static int patch_ad1886_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82163,7 +84569,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D &patch_ad1886_specific, #ifdef CONFIG_PM .resume =3D ad18xx_resume -@@ -1896,7 +1896,7 @@ static int patch_ad1981a_specific(struct +@@ -1896,7 +1896,7 @@ static int patch_ad1981a_specific(struct snd_ac97 = * ac97) ARRAY_SIZE(snd_ac97_ad1981x_jack_sense)); } =20 @@ -82172,7 +84578,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_post_spdif =3D patch_ad198x_post_spdif, .build_specific =3D patch_ad1981a_specific, #ifdef CONFIG_PM -@@ -1952,7 +1952,7 @@ static int patch_ad1981b_specific(struct +@@ -1952,7 +1952,7 @@ static int patch_ad1981b_specific(struct snd_ac97 = *ac97) ARRAY_SIZE(snd_ac97_ad1981x_jack_sense)); } =20 @@ -82181,7 +84587,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_post_spdif =3D patch_ad198x_post_spdif, .build_specific =3D patch_ad1981b_specific, #ifdef CONFIG_PM -@@ -2091,7 +2091,7 @@ static int patch_ad1888_specific(struct=20 +@@ -2091,7 +2091,7 @@ static int patch_ad1888_specific(struct snd_ac97 *= ac97) return patch_build_controls(ac97, snd_ac97_ad1888_controls, ARRAY_SIZE= (snd_ac97_ad1888_controls)); } =20 @@ -82190,7 +84596,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_post_spdif =3D patch_ad198x_post_spdif, .build_specific =3D patch_ad1888_specific, #ifdef CONFIG_PM -@@ -2140,7 +2140,7 @@ static int patch_ad1980_specific(struct=20 +@@ -2140,7 +2140,7 @@ static int patch_ad1980_specific(struct snd_ac97 *= ac97) return patch_build_controls(ac97, &snd_ac97_ad198x_2cmic, 1); } =20 @@ -82199,7 +84605,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_post_spdif =3D patch_ad198x_post_spdif, .build_specific =3D patch_ad1980_specific, #ifdef CONFIG_PM -@@ -2255,7 +2255,7 @@ static int patch_ad1985_specific(struct=20 +@@ -2255,7 +2255,7 @@ static int patch_ad1985_specific(struct snd_ac97 *= ac97) ARRAY_SIZE(snd_ac97_ad1985_controls)); } =20 @@ -82208,7 +84614,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_post_spdif =3D patch_ad198x_post_spdif, .build_specific =3D patch_ad1985_specific, #ifdef CONFIG_PM -@@ -2547,7 +2547,7 @@ static int patch_ad1986_specific(struct=20 +@@ -2547,7 +2547,7 @@ static int patch_ad1986_specific(struct snd_ac97 *= ac97) ARRAY_SIZE(snd_ac97_ad1985_controls)); } =20 @@ -82217,7 +84623,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_post_spdif =3D patch_ad198x_post_spdif, .build_specific =3D patch_ad1986_specific, #ifdef CONFIG_PM -@@ -2652,7 +2652,7 @@ static int patch_alc650_specific(struct=20 +@@ -2652,7 +2652,7 @@ static int patch_alc650_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82226,7 +84632,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_alc650_specific, .update_jacks =3D alc650_update_jacks }; -@@ -2804,7 +2804,7 @@ static int patch_alc655_specific(struct=20 +@@ -2804,7 +2804,7 @@ static int patch_alc655_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82235,7 +84641,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_alc655_specific, .update_jacks =3D alc655_update_jacks }; -@@ -2916,7 +2916,7 @@ static int patch_alc850_specific(struct=20 +@@ -2916,7 +2916,7 @@ static int patch_alc850_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82244,7 +84650,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_alc850_specific, .update_jacks =3D alc850_update_jacks }; -@@ -2978,7 +2978,7 @@ static int patch_cm9738_specific(struct=20 +@@ -2978,7 +2978,7 @@ static int patch_cm9738_specific(struct snd_ac97 *= ac97) return patch_build_controls(ac97, snd_ac97_cm9738_controls, ARRAY_SIZE= (snd_ac97_cm9738_controls)); } =20 @@ -82253,7 +84659,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_cm9738_specific, .update_jacks =3D cm9738_update_jacks }; -@@ -3069,7 +3069,7 @@ static int patch_cm9739_post_spdif(struc +@@ -3069,7 +3069,7 @@ static int patch_cm9739_post_spdif(struct snd_ac97= * ac97) return patch_build_controls(ac97, snd_ac97_cm9739_controls_spdif, ARRA= Y_SIZE(snd_ac97_cm9739_controls_spdif)); } =20 @@ -82262,7 +84668,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_cm9739_specific, .build_post_spdif =3D patch_cm9739_post_spdif, .update_jacks =3D cm9739_update_jacks -@@ -3243,7 +3243,7 @@ static int patch_cm9761_specific(struct=20 +@@ -3243,7 +3243,7 @@ static int patch_cm9761_specific(struct snd_ac97 *= ac97) return patch_build_controls(ac97, snd_ac97_cm9761_controls, ARRAY_SIZE= (snd_ac97_cm9761_controls)); } =20 @@ -82271,7 +84677,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_cm9761_specific, .build_post_spdif =3D patch_cm9761_post_spdif, .update_jacks =3D cm9761_update_jacks -@@ -3339,7 +3339,7 @@ static int patch_cm9780_specific(struct=20 +@@ -3339,7 +3339,7 @@ static int patch_cm9780_specific(struct snd_ac97 *= ac97) return patch_build_controls(ac97, cm9780_controls, ARRAY_SIZE(cm9780_c= ontrols)); } =20 @@ -82280,7 +84686,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_cm9780_specific, .build_post_spdif =3D patch_cm9761_post_spdif /* identical with CM9761= */ }; -@@ -3459,7 +3459,7 @@ static int patch_vt1616_specific(struct=20 +@@ -3459,7 +3459,7 @@ static int patch_vt1616_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82289,7 +84695,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_vt1616_specific }; =20 -@@ -3813,7 +3813,7 @@ static int patch_it2646_specific(struct=20 +@@ -3813,7 +3813,7 @@ static int patch_it2646_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82298,7 +84704,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_it2646_specific, .update_jacks =3D it2646_update_jacks }; -@@ -3847,7 +3847,7 @@ static int patch_si3036_specific(struct=20 +@@ -3847,7 +3847,7 @@ static int patch_si3036_specific(struct snd_ac97 *= ac97) return 0; } =20 @@ -82307,7 +84713,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_pa= tch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_si3036_specific, }; =20 -@@ -3914,7 +3914,7 @@ static int patch_ucb1400_specific(struct +@@ -3914,7 +3914,7 @@ static int patch_ucb1400_specific(struct snd_ac97 = * ac97) return 0; } =20 @@ -82316,9 +84722,10 @@ diff -urNp linux-2.6.32.49/sound/pci/ac97/ac97_p= atch.c linux-2.6.32.49/sound/pci .build_specific =3D patch_ucb1400_specific, }; =20 -diff -urNp linux-2.6.32.49/sound/pci/hda/hda_codec.h linux-2.6.32.49/sou= nd/pci/hda/hda_codec.h ---- linux-2.6.32.49/sound/pci/hda/hda_codec.h 2011-11-08 19:02:43.000000= 000 -0500 -+++ linux-2.6.32.49/sound/pci/hda/hda_codec.h 2011-11-15 19:59:43.000000= 000 -0500 +diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h +index 99552fb..4dcc2c5 100644 +--- a/sound/pci/hda/hda_codec.h ++++ b/sound/pci/hda/hda_codec.h @@ -580,7 +580,7 @@ struct hda_bus_ops { /* notify power-up/down from codec to controller */ void (*pm_notify)(struct hda_bus *bus); @@ -82354,10 +84761,11 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/hda_co= dec.h linux-2.6.32.49/sound/pci/h =20 /* PCM to create, set by patch_ops.build_pcms callback */ unsigned int num_pcms; -diff -urNp linux-2.6.32.49/sound/pci/hda/patch_atihdmi.c linux-2.6.32.49= /sound/pci/hda/patch_atihdmi.c ---- linux-2.6.32.49/sound/pci/hda/patch_atihdmi.c 2011-11-08 19:02:43.00= 0000000 -0500 -+++ linux-2.6.32.49/sound/pci/hda/patch_atihdmi.c 2011-11-15 19:59:43.00= 0000000 -0500 -@@ -177,7 +177,7 @@ static int patch_atihdmi(struct hda_code +diff --git a/sound/pci/hda/patch_atihdmi.c b/sound/pci/hda/patch_atihdmi= .c +index fb684f0..2b11cea 100644 +--- a/sound/pci/hda/patch_atihdmi.c ++++ b/sound/pci/hda/patch_atihdmi.c +@@ -177,7 +177,7 @@ static int patch_atihdmi(struct hda_codec *codec) */ spec->multiout.dig_out_nid =3D CVT_NID; =20 @@ -82366,10 +84774,11 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/patch_= atihdmi.c linux-2.6.32.49/sound/p =20 return 0; } -diff -urNp linux-2.6.32.49/sound/pci/hda/patch_intelhdmi.c linux-2.6.32.= 49/sound/pci/hda/patch_intelhdmi.c ---- linux-2.6.32.49/sound/pci/hda/patch_intelhdmi.c 2011-11-08 19:02:43.= 000000000 -0500 -+++ linux-2.6.32.49/sound/pci/hda/patch_intelhdmi.c 2011-11-15 19:59:43.= 000000000 -0500 -@@ -511,10 +511,10 @@ static void hdmi_non_intrinsic_event(str +diff --git a/sound/pci/hda/patch_intelhdmi.c b/sound/pci/hda/patch_intel= hdmi.c +index 7c23016..c5bfdd7 100644 +--- a/sound/pci/hda/patch_intelhdmi.c ++++ b/sound/pci/hda/patch_intelhdmi.c +@@ -511,10 +511,10 @@ static void hdmi_non_intrinsic_event(struct hda_co= dec *codec, unsigned int res) cp_ready); =20 /* TODO */ @@ -82384,7 +84793,7 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/patch_in= telhdmi.c linux-2.6.32.49/sound } =20 =20 -@@ -656,7 +656,7 @@ static int do_patch_intel_hdmi(struct hd +@@ -656,7 +656,7 @@ static int do_patch_intel_hdmi(struct hda_codec *cod= ec) spec->multiout.dig_out_nid =3D cvt_nid; =20 codec->spec =3D spec; @@ -82393,10 +84802,11 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/patch_= intelhdmi.c linux-2.6.32.49/sound =20 snd_hda_eld_proc_new(codec, &spec->sink_eld); =20 -diff -urNp linux-2.6.32.49/sound/pci/hda/patch_nvhdmi.c linux-2.6.32.49/= sound/pci/hda/patch_nvhdmi.c ---- linux-2.6.32.49/sound/pci/hda/patch_nvhdmi.c 2011-11-08 19:02:43.000= 000000 -0500 -+++ linux-2.6.32.49/sound/pci/hda/patch_nvhdmi.c 2011-11-15 19:59:43.000= 000000 -0500 -@@ -367,7 +367,7 @@ static int patch_nvhdmi_8ch(struct hda_c +diff --git a/sound/pci/hda/patch_nvhdmi.c b/sound/pci/hda/patch_nvhdmi.c +index 6afdab0..68ed352 100644 +--- a/sound/pci/hda/patch_nvhdmi.c ++++ b/sound/pci/hda/patch_nvhdmi.c +@@ -367,7 +367,7 @@ static int patch_nvhdmi_8ch(struct hda_codec *codec) spec->multiout.max_channels =3D 8; spec->multiout.dig_out_nid =3D Nv_Master_Convert_nid; =20 @@ -82405,7 +84815,7 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/patch_nv= hdmi.c linux-2.6.32.49/sound/pc =20 return 0; } -@@ -386,7 +386,7 @@ static int patch_nvhdmi_2ch(struct hda_c +@@ -386,7 +386,7 @@ static int patch_nvhdmi_2ch(struct hda_codec *codec) spec->multiout.max_channels =3D 2; spec->multiout.dig_out_nid =3D Nv_Master_Convert_nid; =20 @@ -82414,9 +84824,10 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/patch_n= vhdmi.c linux-2.6.32.49/sound/pc =20 return 0; } -diff -urNp linux-2.6.32.49/sound/pci/hda/patch_sigmatel.c linux-2.6.32.4= 9/sound/pci/hda/patch_sigmatel.c ---- linux-2.6.32.49/sound/pci/hda/patch_sigmatel.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/sound/pci/hda/patch_sigmatel.c 2011-11-15 19:59:43.0= 00000000 -0500 +diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmat= el.c +index 01da10b..01bd71f 100644 +--- a/sound/pci/hda/patch_sigmatel.c ++++ b/sound/pci/hda/patch_sigmatel.c @@ -5220,7 +5220,7 @@ again: snd_hda_codec_write_cache(codec, nid, 0, AC_VERB_SET_CONNECT_SEL, num_dacs); @@ -82426,7 +84837,7 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/patch_si= gmatel.c linux-2.6.32.49/sound/ =20 codec->proc_widget_hook =3D stac92hd_proc_hook; =20 -@@ -5294,7 +5294,7 @@ static int patch_stac92hd71bxx(struct hd +@@ -5294,7 +5294,7 @@ static int patch_stac92hd71bxx(struct hda_codec *c= odec) return -ENOMEM; =20 codec->spec =3D spec; @@ -82435,9 +84846,10 @@ diff -urNp linux-2.6.32.49/sound/pci/hda/patch_s= igmatel.c linux-2.6.32.49/sound/ spec->num_pins =3D STAC92HD71BXX_NUM_PINS; switch (codec->vendor_id) { case 0x111d76b6: -diff -urNp linux-2.6.32.49/sound/pci/ice1712/ice1712.h linux-2.6.32.49/s= ound/pci/ice1712/ice1712.h ---- linux-2.6.32.49/sound/pci/ice1712/ice1712.h 2011-11-08 19:02:43.0000= 00000 -0500 -+++ linux-2.6.32.49/sound/pci/ice1712/ice1712.h 2011-11-15 19:59:43.0000= 00000 -0500 +diff --git a/sound/pci/ice1712/ice1712.h b/sound/pci/ice1712/ice1712.h +index d063149..01599a4 100644 +--- a/sound/pci/ice1712/ice1712.h ++++ b/sound/pci/ice1712/ice1712.h @@ -269,7 +269,7 @@ struct snd_ak4xxx_private { unsigned int mask_flags; /* total mask bits */ struct snd_akm4xxx_ops { @@ -82456,9 +84868,10 @@ diff -urNp linux-2.6.32.49/sound/pci/ice1712/ice= 1712.h linux-2.6.32.49/sound/pci }; =20 =20 -diff -urNp linux-2.6.32.49/sound/pci/intel8x0m.c linux-2.6.32.49/sound/p= ci/intel8x0m.c ---- linux-2.6.32.49/sound/pci/intel8x0m.c 2011-11-08 19:02:43.000000000 = -0500 -+++ linux-2.6.32.49/sound/pci/intel8x0m.c 2011-11-15 19:59:43.000000000 = -0500 +diff --git a/sound/pci/intel8x0m.c b/sound/pci/intel8x0m.c +index 9e7d12e..3e3bc64 100644 +--- a/sound/pci/intel8x0m.c ++++ b/sound/pci/intel8x0m.c @@ -1264,7 +1264,7 @@ static struct shortname_table { { 0x5455, "ALi M5455" }, { 0x746d, "AMD AMD8111" }, @@ -82468,10 +84881,11 @@ diff -urNp linux-2.6.32.49/sound/pci/intel8x0m.= c linux-2.6.32.49/sound/pci/intel }; =20 static int __devinit snd_intel8x0m_probe(struct pci_dev *pci, -diff -urNp linux-2.6.32.49/sound/pci/ymfpci/ymfpci_main.c linux-2.6.32.4= 9/sound/pci/ymfpci/ymfpci_main.c ---- linux-2.6.32.49/sound/pci/ymfpci/ymfpci_main.c 2011-11-08 19:02:43.0= 00000000 -0500 -+++ linux-2.6.32.49/sound/pci/ymfpci/ymfpci_main.c 2011-11-15 19:59:43.0= 00000000 -0500 -@@ -202,8 +202,8 @@ static void snd_ymfpci_hw_stop(struct sn +diff --git a/sound/pci/ymfpci/ymfpci_main.c b/sound/pci/ymfpci/ymfpci_ma= in.c +index 5518371..45cf7ac 100644 +--- a/sound/pci/ymfpci/ymfpci_main.c ++++ b/sound/pci/ymfpci/ymfpci_main.c +@@ -202,8 +202,8 @@ static void snd_ymfpci_hw_stop(struct snd_ymfpci *ch= ip) if ((snd_ymfpci_readl(chip, YDSXGR_STATUS) & 2) =3D=3D 0) break; } @@ -82482,7 +84896,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ymfpci/ymfpc= i_main.c linux-2.6.32.49/sound/ wake_up(&chip->interrupt_sleep); } __end: -@@ -787,7 +787,7 @@ static void snd_ymfpci_irq_wait(struct s +@@ -787,7 +787,7 @@ static void snd_ymfpci_irq_wait(struct snd_ymfpci *c= hip) continue; init_waitqueue_entry(&wait, current); add_wait_queue(&chip->interrupt_sleep, &wait); @@ -82491,7 +84905,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ymfpci/ymfpc= i_main.c linux-2.6.32.49/sound/ schedule_timeout_uninterruptible(msecs_to_jiffies(50)); remove_wait_queue(&chip->interrupt_sleep, &wait); } -@@ -825,8 +825,8 @@ static irqreturn_t snd_ymfpci_interrupt( +@@ -825,8 +825,8 @@ static irqreturn_t snd_ymfpci_interrupt(int irq, voi= d *dev_id) snd_ymfpci_writel(chip, YDSXGR_MODE, mode); spin_unlock(&chip->reg_lock); =20 @@ -82502,7 +84916,7 @@ diff -urNp linux-2.6.32.49/sound/pci/ymfpci/ymfpc= i_main.c linux-2.6.32.49/sound/ wake_up(&chip->interrupt_sleep); } } -@@ -2369,7 +2369,7 @@ int __devinit snd_ymfpci_create(struct s +@@ -2369,7 +2369,7 @@ int __devinit snd_ymfpci_create(struct snd_card *c= ard, spin_lock_init(&chip->reg_lock); spin_lock_init(&chip->voice_lock); init_waitqueue_head(&chip->interrupt_sleep); @@ -82511,10 +84925,11 @@ diff -urNp linux-2.6.32.49/sound/pci/ymfpci/ymf= pci_main.c linux-2.6.32.49/sound/ chip->card =3D card; chip->pci =3D pci; chip->irq =3D -1; -diff -urNp linux-2.6.32.49/sound/soc/soc-core.c linux-2.6.32.49/sound/so= c/soc-core.c ---- linux-2.6.32.49/sound/soc/soc-core.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/sound/soc/soc-core.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -609,7 +609,7 @@ static int soc_pcm_trigger(struct snd_pc +diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c +index 0a1b2f6..776bb19 100644 +--- a/sound/soc/soc-core.c ++++ b/sound/soc/soc-core.c +@@ -609,7 +609,7 @@ static int soc_pcm_trigger(struct snd_pcm_substream = *substream, int cmd) } =20 /* ASoC PCM operations */ @@ -82523,10 +84938,11 @@ diff -urNp linux-2.6.32.49/sound/soc/soc-core.c= linux-2.6.32.49/sound/soc/soc-co .open =3D soc_pcm_open, .close =3D soc_codec_close, .hw_params =3D soc_pcm_hw_params, -diff -urNp linux-2.6.32.49/sound/usb/usbaudio.c linux-2.6.32.49/sound/us= b/usbaudio.c ---- linux-2.6.32.49/sound/usb/usbaudio.c 2011-11-08 19:02:43.000000000 -= 0500 -+++ linux-2.6.32.49/sound/usb/usbaudio.c 2011-11-15 19:59:43.000000000 -= 0500 -@@ -963,12 +963,12 @@ static int snd_usb_pcm_playback_trigger( +diff --git a/sound/usb/usbaudio.c b/sound/usb/usbaudio.c +index 79633ea..9732e90 100644 +--- a/sound/usb/usbaudio.c ++++ b/sound/usb/usbaudio.c +@@ -963,12 +963,12 @@ static int snd_usb_pcm_playback_trigger(struct snd= _pcm_substream *substream, switch (cmd) { case SNDRV_PCM_TRIGGER_START: case SNDRV_PCM_TRIGGER_PAUSE_RELEASE: @@ -82541,7 +84957,7 @@ diff -urNp linux-2.6.32.49/sound/usb/usbaudio.c l= inux-2.6.32.49/sound/usb/usbaud return 0; default: return -EINVAL; -@@ -985,15 +985,15 @@ static int snd_usb_pcm_capture_trigger(s +@@ -985,15 +985,15 @@ static int snd_usb_pcm_capture_trigger(struct snd_= pcm_substream *substream, =20 switch (cmd) { case SNDRV_PCM_TRIGGER_START: @@ -82560,7 +84976,7 @@ diff -urNp linux-2.6.32.49/sound/usb/usbaudio.c l= inux-2.6.32.49/sound/usb/usbaud return 0; default: return -EINVAL; -@@ -1542,7 +1542,7 @@ static int snd_usb_pcm_prepare(struct sn +@@ -1542,7 +1542,7 @@ static int snd_usb_pcm_prepare(struct snd_pcm_subs= tream *substream) /* for playback, submit the URBs now; otherwise, the first hwptr_done * updates for all URBs would happen at the same time when starting */ if (subs->direction =3D=3D SNDRV_PCM_STREAM_PLAYBACK) { @@ -82569,7 +84985,7 @@ diff -urNp linux-2.6.32.49/sound/usb/usbaudio.c l= inux-2.6.32.49/sound/usb/usbaud return start_urbs(subs, runtime); } else return 0; -@@ -2228,14 +2228,14 @@ static void init_substream(struct snd_us +@@ -2228,14 +2228,14 @@ static void init_substream(struct snd_usb_stream= *as, int stream, struct audiofo subs->direction =3D stream; subs->dev =3D as->chip->dev; if (snd_usb_get_speed(subs->dev) =3D=3D USB_SPEED_FULL) { @@ -82587,9 +85003,38 @@ diff -urNp linux-2.6.32.49/sound/usb/usbaudio.c = linux-2.6.32.49/sound/usb/usbaud break; } } -diff -urNp linux-2.6.32.49/tools/gcc/checker_plugin.c linux-2.6.32.49/to= ols/gcc/checker_plugin.c ---- linux-2.6.32.49/tools/gcc/checker_plugin.c 1969-12-31 19:00:00.00000= 0000 -0500 -+++ linux-2.6.32.49/tools/gcc/checker_plugin.c 2011-11-18 18:01:52.00000= 0000 -0500 +diff --git a/tools/gcc/Makefile b/tools/gcc/Makefile +new file mode 100644 +index 0000000..b044b80 +--- /dev/null ++++ b/tools/gcc/Makefile +@@ -0,0 +1,21 @@ ++#CC :=3D gcc ++#PLUGIN_SOURCE_FILES :=3D pax_plugin.c ++#PLUGIN_OBJECT_FILES :=3D $(patsubst %.c,%.o,$(PLUGIN_SOURCE_FILES)) ++GCCPLUGINS_DIR :=3D $(shell $(CC) -print-file-name=3Dplugin) ++#CFLAGS +=3D -I$(GCCPLUGINS_DIR)/include -fPIC -O2 -Wall -W ++ ++HOST_EXTRACFLAGS +=3D -I$(GCCPLUGINS_DIR)/include ++ ++hostlibs-y :=3D constify_plugin.so ++hostlibs-$(CONFIG_PAX_MEMORY_STACKLEAK) +=3D stackleak_plugin.so ++hostlibs-$(CONFIG_KALLOCSTAT_PLUGIN) +=3D kallocstat_plugin.so ++hostlibs-$(CONFIG_PAX_KERNEXEC_PLUGIN) +=3D kernexec_plugin.so ++hostlibs-$(CONFIG_CHECKER_PLUGIN) +=3D checker_plugin.so ++ ++always :=3D $(hostlibs-y) ++ ++constify_plugin-objs :=3D constify_plugin.o ++stackleak_plugin-objs :=3D stackleak_plugin.o ++kallocstat_plugin-objs :=3D kallocstat_plugin.o ++kernexec_plugin-objs :=3D kernexec_plugin.o ++checker_plugin-objs :=3D checker_plugin.o +diff --git a/tools/gcc/checker_plugin.c b/tools/gcc/checker_plugin.c +new file mode 100644 +index 0000000..d41b5af +--- /dev/null ++++ b/tools/gcc/checker_plugin.c @@ -0,0 +1,171 @@ +/* + * Copyright 2011 by the PaX Team @@ -82758,13 +85203,15 @@ diff -urNp linux-2.6.32.49/tools/gcc/checker_pl= ugin.c linux-2.6.32.49/tools/gcc/ + if (TARGET_64BIT =3D=3D 0) + return 0; + -+ register_callback (plugin_name, PLUGIN_PRAGMAS, register_checker_addre= ss_spaces, NULL); ++ register_callback(plugin_name, PLUGIN_PRAGMAS, register_checker_addres= s_spaces, NULL); + + return 0; +} -diff -urNp linux-2.6.32.49/tools/gcc/constify_plugin.c linux-2.6.32.49/t= ools/gcc/constify_plugin.c ---- linux-2.6.32.49/tools/gcc/constify_plugin.c 1969-12-31 19:00:00.0000= 00000 -0500 -+++ linux-2.6.32.49/tools/gcc/constify_plugin.c 2011-11-18 18:01:52.0000= 00000 -0500 +diff --git a/tools/gcc/constify_plugin.c b/tools/gcc/constify_plugin.c +new file mode 100644 +index 0000000..5b07edd +--- /dev/null ++++ b/tools/gcc/constify_plugin.c @@ -0,0 +1,303 @@ +/* + * Copyright 2011 by Emese Revfy @@ -83069,9 +85516,11 @@ diff -urNp linux-2.6.32.49/tools/gcc/constify_pl= ugin.c linux-2.6.32.49/tools/gcc + + return 0; +} -diff -urNp linux-2.6.32.49/tools/gcc/kallocstat_plugin.c linux-2.6.32.49= /tools/gcc/kallocstat_plugin.c ---- linux-2.6.32.49/tools/gcc/kallocstat_plugin.c 1969-12-31 19:00:00.00= 0000000 -0500 -+++ linux-2.6.32.49/tools/gcc/kallocstat_plugin.c 2011-11-18 18:01:52.00= 0000000 -0500 +diff --git a/tools/gcc/kallocstat_plugin.c b/tools/gcc/kallocstat_plugin= .c +new file mode 100644 +index 0000000..a5eabce +--- /dev/null ++++ b/tools/gcc/kallocstat_plugin.c @@ -0,0 +1,167 @@ +/* + * Copyright 2011 by the PaX Team @@ -83240,10 +85689,12 @@ diff -urNp linux-2.6.32.49/tools/gcc/kallocstat= _plugin.c linux-2.6.32.49/tools/g + + return 0; +} -diff -urNp linux-2.6.32.49/tools/gcc/kernexec_plugin.c linux-2.6.32.49/t= ools/gcc/kernexec_plugin.c ---- linux-2.6.32.49/tools/gcc/kernexec_plugin.c 1969-12-31 19:00:00.0000= 00000 -0500 -+++ linux-2.6.32.49/tools/gcc/kernexec_plugin.c 2011-11-18 18:01:52.0000= 00000 -0500 -@@ -0,0 +1,275 @@ +diff --git a/tools/gcc/kernexec_plugin.c b/tools/gcc/kernexec_plugin.c +new file mode 100644 +index 0000000..51f747e +--- /dev/null ++++ b/tools/gcc/kernexec_plugin.c +@@ -0,0 +1,348 @@ +/* + * Copyright 2011 by the PaX Team + * Licensed under the GPL v2 @@ -83287,13 +85738,17 @@ diff -urNp linux-2.6.32.49/tools/gcc/kernexec_p= lugin.c linux-2.6.32.49/tools/gcc +int plugin_is_GPL_compatible; + +static struct plugin_info kernexec_plugin_info =3D { -+ .version =3D "201111150100", ++ .version =3D "201111291120", ++ .help =3D "method=3D[bts|or]\tinstrumentation method\n" +}; + +static unsigned int execute_kernexec_fptr(void); +static unsigned int execute_kernexec_retaddr(void); +static bool kernexec_cmodel_check(void); + ++static void (*kernexec_instrument_fptr)(gimple_stmt_iterator); ++static void (*kernexec_instrument_retaddr)(rtx); ++ +static struct gimple_opt_pass kernexec_fptr_pass =3D { + .pass =3D { + .type =3D GIMPLE_PASS, @@ -83352,7 +85807,7 @@ diff -urNp linux-2.6.32.49/tools/gcc/kernexec_plu= gin.c linux-2.6.32.49/tools/gcc + * add special KERNEXEC instrumentation: force MSB of fptr to 1, which = will produce + * a non-canonical address from a userland ptr and will just trigger a = GPF on dereference + */ -+static void kernexec_instrument_fptr(gimple_stmt_iterator gsi) ++static void kernexec_instrument_fptr_bts(gimple_stmt_iterator gsi) +{ + gimple assign_intptr, assign_new_fptr, call_stmt; + tree intptr, old_fptr, new_fptr, kernexec_mask; @@ -83361,27 +85816,59 @@ diff -urNp linux-2.6.32.49/tools/gcc/kernexec_p= lugin.c linux-2.6.32.49/tools/gcc + old_fptr =3D gimple_call_fn(call_stmt); + + // create temporary unsigned long variable used for bitops and cast fp= tr to it -+ intptr =3D create_tmp_var(long_unsigned_type_node, NULL); ++ intptr =3D create_tmp_var(long_unsigned_type_node, "kernexec_bts"); + add_referenced_var(intptr); + mark_sym_for_renaming(intptr); + assign_intptr =3D gimple_build_assign(intptr, fold_convert(long_unsign= ed_type_node, old_fptr)); -+ update_stmt(assign_intptr); + gsi_insert_before(&gsi, assign_intptr, GSI_SAME_STMT); ++ update_stmt(assign_intptr); + + // apply logical or to temporary unsigned long and bitmask + kernexec_mask =3D build_int_cstu(long_long_unsigned_type_node, 0x80000= 00000000000LL); +// kernexec_mask =3D build_int_cstu(long_long_unsigned_type_node, 0xfff= fffff80000000LL); + assign_intptr =3D gimple_build_assign(intptr, fold_build2(BIT_IOR_EXPR= , long_long_unsigned_type_node, intptr, kernexec_mask)); -+ update_stmt(assign_intptr); + gsi_insert_before(&gsi, assign_intptr, GSI_SAME_STMT); ++ update_stmt(assign_intptr); + + // cast temporary unsigned long back to a temporary fptr variable -+ new_fptr =3D create_tmp_var(TREE_TYPE(old_fptr), NULL); ++ new_fptr =3D create_tmp_var(TREE_TYPE(old_fptr), "kernexec"); + add_referenced_var(new_fptr); + mark_sym_for_renaming(new_fptr); + assign_new_fptr =3D gimple_build_assign(new_fptr, fold_convert(TREE_TY= PE(old_fptr), intptr)); -+ update_stmt(assign_new_fptr); + gsi_insert_before(&gsi, assign_new_fptr, GSI_SAME_STMT); ++ update_stmt(assign_new_fptr); ++ ++ // replace call stmt fn with the new fptr ++ gimple_call_set_fn(call_stmt, new_fptr); ++ update_stmt(call_stmt); ++} ++ ++static void kernexec_instrument_fptr_or(gimple_stmt_iterator gsi) ++{ ++ gimple asm_or_stmt, call_stmt; ++ tree old_fptr, new_fptr, input, output; ++ VEC(tree, gc) *inputs =3D NULL; ++ VEC(tree, gc) *outputs =3D NULL; ++ ++ call_stmt =3D gsi_stmt(gsi); ++ old_fptr =3D gimple_call_fn(call_stmt); ++ ++ // create temporary fptr variable ++ new_fptr =3D create_tmp_var(TREE_TYPE(old_fptr), "kernexec_or"); ++ add_referenced_var(new_fptr); ++ mark_sym_for_renaming(new_fptr); ++ ++ // build asm volatile("orq %%r10, %0\n\t" : "=3Dr"(new_fptr) : "0"(old= _fptr)); ++ input =3D build_tree_list(NULL_TREE, build_string(2, "0")); ++ input =3D chainon(NULL_TREE, build_tree_list(input, old_fptr)); ++ output =3D build_tree_list(NULL_TREE, build_string(3, "=3Dr")); ++ output =3D chainon(NULL_TREE, build_tree_list(output, new_fptr)); ++ VEC_safe_push(tree, gc, inputs, input); ++ VEC_safe_push(tree, gc, outputs, output); ++ asm_or_stmt =3D gimple_build_asm_vec("orq %%r10, %0\n\t", inputs, outp= uts, NULL, NULL); ++ gimple_asm_set_volatile(asm_or_stmt, true); ++ gsi_insert_before(&gsi, asm_or_stmt, GSI_SAME_STMT); ++ update_stmt(asm_or_stmt); + + // replace call stmt fn with the new fptr + gimple_call_set_fn(call_stmt, new_fptr); @@ -83435,7 +85922,7 @@ diff -urNp linux-2.6.32.49/tools/gcc/kernexec_plu= gin.c linux-2.6.32.49/tools/gcc +} + +// add special KERNEXEC instrumentation: btsq $63,(%rsp) just before re= tn -+static void kernexec_instrument_retaddr(rtx insn) ++static void kernexec_instrument_retaddr_bts(rtx insn) +{ + rtx btsq; + rtvec argvec, constraintvec, labelvec; @@ -83452,6 +85939,24 @@ diff -urNp linux-2.6.32.49/tools/gcc/kernexec_pl= ugin.c linux-2.6.32.49/tools/gcc + emit_insn_before(btsq, insn); +} + ++// add special KERNEXEC instrumentation: orq %r10,(%rsp) just before re= tn ++static void kernexec_instrument_retaddr_or(rtx insn) ++{ ++ rtx orq; ++ rtvec argvec, constraintvec, labelvec; ++ int line; ++ ++ // create asm volatile("orq %%r10,(%%rsp)":::) ++ argvec =3D rtvec_alloc(0); ++ constraintvec =3D rtvec_alloc(0); ++ labelvec =3D rtvec_alloc(0); ++ line =3D expand_location(RTL_LOCATION(insn)).line; ++ orq =3D gen_rtx_ASM_OPERANDS(VOIDmode, "orq %%r10,(%%rsp)", empty_stri= ng, 0, argvec, constraintvec, labelvec, line); ++ MEM_VOLATILE_P(orq) =3D 1; ++// RTX_FRAME_RELATED_P(orq) =3D 1; // not for ASM_OPERANDS ++ emit_insn_before(orq, insn); ++} ++ +/* + * find all asm level function returns and forcibly set the highest bit= of the return address + */ @@ -83508,45 +86013,41 @@ diff -urNp linux-2.6.32.49/tools/gcc/kernexec_p= lugin.c linux-2.6.32.49/tools/gcc + + register_callback(plugin_name, PLUGIN_INFO, NULL, &kernexec_plugin_inf= o); + -+ for (i =3D 0; i < argc; ++i) -+ error(G_("unkown option '-fplugin-arg-%s-%s'"), plugin_name, argv[i].= key); -+ + if (TARGET_64BIT =3D=3D 0) + return 0; + ++ for (i =3D 0; i < argc; ++i) { ++ if (!strcmp(argv[i].key, "method")) { ++ if (!argv[i].value) { ++ error(G_("no value supplied for option '-fplugin-arg-%s-%s'"), plug= in_name, argv[i].key); ++ continue; ++ } ++ if (!strcmp(argv[i].value, "bts")) { ++ kernexec_instrument_fptr =3D kernexec_instrument_fptr_bts; ++ kernexec_instrument_retaddr =3D kernexec_instrument_retaddr_bts; ++ } else if (!strcmp(argv[i].value, "or")) { ++ kernexec_instrument_fptr =3D kernexec_instrument_fptr_or; ++ kernexec_instrument_retaddr =3D kernexec_instrument_retaddr_or; ++ fix_register("r10", 1, 1); ++ } else ++ error(G_("invalid option argument '-fplugin-arg-%s-%s=3D%s'"), plug= in_name, argv[i].key, argv[i].value); ++ continue; ++ } ++ error(G_("unkown option '-fplugin-arg-%s-%s'"), plugin_name, argv[i].= key); ++ } ++ if (!kernexec_instrument_fptr || !kernexec_instrument_retaddr) ++ error(G_("no instrumentation method was selected via '-fplugin-arg-%s= -method'"), plugin_name); ++ + register_callback(plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &kerne= xec_fptr_pass_info); + register_callback(plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &kerne= xec_retaddr_pass_info); + + return 0; +} -diff -urNp linux-2.6.32.49/tools/gcc/Makefile linux-2.6.32.49/tools/gcc/= Makefile ---- linux-2.6.32.49/tools/gcc/Makefile 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-2.6.32.49/tools/gcc/Makefile 2011-11-18 18:08:04.000000000 -05= 00 -@@ -0,0 +1,21 @@ -+#CC :=3D gcc -+#PLUGIN_SOURCE_FILES :=3D pax_plugin.c -+#PLUGIN_OBJECT_FILES :=3D $(patsubst %.c,%.o,$(PLUGIN_SOURCE_FILES)) -+GCCPLUGINS_DIR :=3D $(shell $(CC) -print-file-name=3Dplugin) -+#CFLAGS +=3D -I$(GCCPLUGINS_DIR)/include -fPIC -O2 -Wall -W -+ -+HOST_EXTRACFLAGS +=3D -I$(GCCPLUGINS_DIR)/include -+ -+hostlibs-y :=3D constify_plugin.so -+hostlibs-$(CONFIG_PAX_MEMORY_STACKLEAK) +=3D stackleak_plugin.so -+hostlibs-$(CONFIG_KALLOCSTAT_PLUGIN) +=3D kallocstat_plugin.so -+hostlibs-$(CONFIG_PAX_KERNEXEC_PLUGIN) +=3D kernexec_plugin.so -+hostlibs-$(CONFIG_CHECKER_PLUGIN) +=3D checker_plugin.so -+ -+always :=3D $(hostlibs-y) -+ -+constify_plugin-objs :=3D constify_plugin.o -+stackleak_plugin-objs :=3D stackleak_plugin.o -+kallocstat_plugin-objs :=3D kallocstat_plugin.o -+kernexec_plugin-objs :=3D kernexec_plugin.o -+checker_plugin-objs :=3D checker_plugin.o -diff -urNp linux-2.6.32.49/tools/gcc/stackleak_plugin.c linux-2.6.32.49/= tools/gcc/stackleak_plugin.c ---- linux-2.6.32.49/tools/gcc/stackleak_plugin.c 1969-12-31 19:00:00.000= 000000 -0500 -+++ linux-2.6.32.49/tools/gcc/stackleak_plugin.c 2011-11-18 18:01:52.000= 000000 -0500 +diff --git a/tools/gcc/stackleak_plugin.c b/tools/gcc/stackleak_plugin.c +new file mode 100644 +index 0000000..41dd4b1 +--- /dev/null ++++ b/tools/gcc/stackleak_plugin.c @@ -0,0 +1,291 @@ +/* + * Copyright 2011 by the PaX Team @@ -83839,10 +86340,11 @@ diff -urNp linux-2.6.32.49/tools/gcc/stackleak_= plugin.c linux-2.6.32.49/tools/gc + + return 0; +} -diff -urNp linux-2.6.32.49/usr/gen_init_cpio.c linux-2.6.32.49/usr/gen_i= nit_cpio.c ---- linux-2.6.32.49/usr/gen_init_cpio.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/usr/gen_init_cpio.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -299,7 +299,7 @@ static int cpio_mkfile(const char *name, +diff --git a/usr/gen_init_cpio.c b/usr/gen_init_cpio.c +index 83b3dde..835bee7 100644 +--- a/usr/gen_init_cpio.c ++++ b/usr/gen_init_cpio.c +@@ -299,7 +299,7 @@ static int cpio_mkfile(const char *name, const char = *location, int retval; int rc =3D -1; int namesize; @@ -83851,7 +86353,7 @@ diff -urNp linux-2.6.32.49/usr/gen_init_cpio.c li= nux-2.6.32.49/usr/gen_init_cpio =20 mode |=3D S_IFREG; =20 -@@ -383,9 +383,10 @@ static char *cpio_replace_env(char *new_ +@@ -383,9 +383,10 @@ static char *cpio_replace_env(char *new_location) *env_var =3D *expanded =3D '\0'; strncat(env_var, start + 2, end - start - 2); strncat(expanded, new_location, start - new_loca= tion); @@ -83864,10 +86366,11 @@ diff -urNp linux-2.6.32.49/usr/gen_init_cpio.c = linux-2.6.32.49/usr/gen_init_cpio } else break; } -diff -urNp linux-2.6.32.49/virt/kvm/kvm_main.c linux-2.6.32.49/virt/kvm/= kvm_main.c ---- linux-2.6.32.49/virt/kvm/kvm_main.c 2011-11-08 19:02:43.000000000 -0= 500 -+++ linux-2.6.32.49/virt/kvm/kvm_main.c 2011-11-15 19:59:43.000000000 -0= 500 -@@ -2494,7 +2494,7 @@ asmlinkage void kvm_handle_fault_on_rebo +diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c +index 4f3434f..159bc3e 100644 +--- a/virt/kvm/kvm_main.c ++++ b/virt/kvm/kvm_main.c +@@ -2494,7 +2494,7 @@ asmlinkage void kvm_handle_fault_on_reboot(void) if (kvm_rebooting) /* spin while reset goes on */ while (true) @@ -83876,7 +86379,7 @@ diff -urNp linux-2.6.32.49/virt/kvm/kvm_main.c li= nux-2.6.32.49/virt/kvm/kvm_main /* Fault while not rebooting. We want the trace. */ BUG(); } -@@ -2714,7 +2714,7 @@ static void kvm_sched_out(struct preempt +@@ -2714,7 +2714,7 @@ static void kvm_sched_out(struct preempt_notifier = *pn, kvm_arch_vcpu_put(vcpu); } =20 @@ -83885,7 +86388,7 @@ diff -urNp linux-2.6.32.49/virt/kvm/kvm_main.c li= nux-2.6.32.49/virt/kvm/kvm_main struct module *module) { int r; -@@ -2767,15 +2767,17 @@ int kvm_init(void *opaque, unsigned int=20 +@@ -2767,15 +2767,17 @@ int kvm_init(void *opaque, unsigned int vcpu_siz= e, /* A kmem cache lets us meet the alignment requirements of fx_save. */ kvm_vcpu_cache =3D kmem_cache_create("kvm_vcpu", vcpu_size, __alignof__(struct kvm_vcpu), diff --git a/3.1.4/0000_README b/3.1.4/0000_README index 8bab127..933d2ae 100644 --- a/3.1.4/0000_README +++ b/3.1.4/0000_README @@ -7,7 +7,7 @@ Patch: 1003_linux-3.1.4.patch From: http://www.kernel.org Desc: Linux 3.1.4 =20 -Patch: 4420_grsecurity-2.2.2-3.1.4-201112021740.patch +Patch: 4420_grsecurity-2.2.2-3.1.4-201112041811.patch From: http://www.grsecurity.net Desc: hardened-sources base patch from upstream grsecurity =20 diff --git a/3.1.4/4420_grsecurity-2.2.2-3.1.4-201112021740.patch b/3.1.4= /4420_grsecurity-2.2.2-3.1.4-201112041811.patch similarity index 81% rename from 3.1.4/4420_grsecurity-2.2.2-3.1.4-201112021740.patch rename to 3.1.4/4420_grsecurity-2.2.2-3.1.4-201112041811.patch index 511b7bc..5d26ec9 100644 --- a/3.1.4/4420_grsecurity-2.2.2-3.1.4-201112021740.patch +++ b/3.1.4/4420_grsecurity-2.2.2-3.1.4-201112041811.patch @@ -1,7 +1,373 @@ -diff -urNp linux-3.1.4/arch/alpha/include/asm/elf.h linux-3.1.4/arch/alp= ha/include/asm/elf.h ---- linux-3.1.4/arch/alpha/include/asm/elf.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/alpha/include/asm/elf.h 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -90,6 +90,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_N +diff --git a/Documentation/dontdiff b/Documentation/dontdiff +index dfa6fc6..0095943 100644 +--- a/Documentation/dontdiff ++++ b/Documentation/dontdiff +@@ -5,6 +5,7 @@ + *.cis + *.cpio + *.csp ++*.dbg + *.dsp + *.dvi + *.elf +@@ -14,6 +15,7 @@ + *.gcov + *.gen.S + *.gif ++*.gmo + *.grep + *.grp + *.gz +@@ -48,9 +50,11 @@ + *.tab.h + *.tex + *.ver ++*.vim + *.xml + *.xz + *_MODULES ++*_reg_safe.h + *_vga16.c + *~ + \#*# +@@ -70,6 +74,7 @@ Kerntypes + Module.markers + Module.symvers + PENDING ++PERF* + SCCS + System.map* + TAGS +@@ -93,19 +98,24 @@ bounds.h + bsetup + btfixupprep + build ++builtin-policy.h + bvmlinux + bzImage* + capability_names.h + capflags.c + classlist.h* ++clut_vga16.c ++common-cmds.h + comp*.log + compile.h* + conf + config + config-* + config_data.h* ++config.c + config.mak + config.mak.autogen ++config.tmp + conmakehash + consolemap_deftbl.c* + cpustr.h +@@ -119,6 +129,7 @@ dslm + elf2ecoff + elfconfig.h* + evergreen_reg_safe.h ++exception_policy.conf + fixdep + flask.h + fore200e_mkfirm +@@ -126,12 +137,15 @@ fore200e_pca_fw.c* + gconf + gconf.glade.h + gen-devlist ++gen-kdb_cmds.c + gen_crc32table + gen_init_cpio + generated + genheaders + genksyms + *_gray256.c ++hash ++hid-example + hpet_example + hugepage-mmap + hugepage-shm +@@ -146,7 +160,7 @@ int32.c + int4.c + int8.c + kallsyms +-kconfig ++kern_constants.h + keywords.c + ksym.c* + ksym.h* +@@ -154,7 +168,6 @@ kxgettext + lkc_defs.h + lex.c + lex.*.c +-linux + logo_*.c + logo_*_clut224.c + logo_*_mono.c +@@ -166,14 +179,15 @@ machtypes.h + map + map_hugetlb + maui_boot.h +-media + mconf ++mdp + miboot* + mk_elfconfig + mkboot + mkbugboot + mkcpustr + mkdep ++mkpiggy + mkprep + mkregtable + mktables +@@ -209,6 +223,7 @@ r300_reg_safe.h + r420_reg_safe.h + r600_reg_safe.h + recordmcount ++regdb.c + relocs + rlim_names.h + rn50_reg_safe.h +@@ -219,6 +234,7 @@ setup + setup.bin + setup.elf + sImage ++slabinfo + sm_tbl* + split-include + syscalltab.h +@@ -229,6 +245,7 @@ tftpboot.img + timeconst.h + times.h* + trix_boot.h ++user_constants.h + utsrelease.h* + vdso-syms.lds + vdso.lds +@@ -246,7 +263,9 @@ vmlinux + vmlinux-* + vmlinux.aout + vmlinux.bin.all ++vmlinux.bin.bz2 + vmlinux.lds ++vmlinux.relocs + vmlinuz + voffset.h + vsyscall.lds +@@ -254,9 +273,11 @@ vsyscall_32.lds + wanxlfw.inc + uImage + unifdef ++utsrelease.h + wakeup.bin + wakeup.elf + wakeup.lds + zImage* + zconf.hash.c ++zconf.lex.c + zoffset.h +diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-= parameters.txt +index d6e6724..a024ce8 100644 +--- a/Documentation/kernel-parameters.txt ++++ b/Documentation/kernel-parameters.txt +@@ -1898,6 +1898,13 @@ bytes respectively. Such letter suffixes can also= be entirely omitted. + the specified number of seconds. This is to be used if + your oopses keep scrolling off the screen. +=20 ++ pax_nouderef [X86] disables UDEREF. Most likely needed under certain ++ virtualization environments that don't cope well with the ++ expand down segment used by UDEREF on X86-32 or the frequent ++ page table updates on X86-64. ++ ++ pax_softmode=3D 0/1 to disable/enable PaX softmode on boot already. ++ + pcbit=3D [HW,ISDN] +=20 + pcd. [PARIDE] +diff --git a/Makefile b/Makefile +index 7f8a93b..4435dc9 100644 +--- a/Makefile ++++ b/Makefile +@@ -245,8 +245,9 @@ CONFIG_SHELL :=3D $(shell if [ -x "$$BASH" ]; then e= cho $$BASH; \ +=20 + HOSTCC =3D gcc + HOSTCXX =3D g++ +-HOSTCFLAGS =3D -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fo= mit-frame-pointer +-HOSTCXXFLAGS =3D -O2 ++HOSTCFLAGS =3D -Wall -W -Wmissing-prototypes -Wstrict-prototypes -Wno= -unused-parameter -Wno-missing-field-initializers -O2 -fomit-frame-pointe= r -fno-delete-null-pointer-checks ++HOSTCLFAGS +=3D $(call cc-option, -Wno-empty-body) ++HOSTCXXFLAGS =3D -O2 -Wall -W -fno-delete-null-pointer-checks +=20 + # Decide whether to build built-in, modular, or both. + # Normally, just do built-in. +@@ -407,8 +408,8 @@ export RCS_TAR_IGNORE :=3D --exclude SCCS --exclude = BitKeeper --exclude .svn --exc + # Rules shared between *config targets and build targets +=20 + # Basic helpers built in scripts/ +-PHONY +=3D scripts_basic +-scripts_basic: ++PHONY +=3D scripts_basic gcc-plugins ++scripts_basic: gcc-plugins + $(Q)$(MAKE) $(build)=3Dscripts/basic + $(Q)rm -f .tmp_quiet_recordmcount +=20 +@@ -564,6 +565,42 @@ else + KBUILD_CFLAGS +=3D -O2 + endif +=20 ++ifndef DISABLE_PAX_PLUGINS ++ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-plugin.sh "$(HOSTC= C)" "$(CC)"), y) ++ifndef DISABLE_PAX_CONSTIFY_PLUGIN ++CONSTIFY_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/constify_plugin.so= -DCONSTIFY_PLUGIN ++endif ++ifdef CONFIG_PAX_MEMORY_STACKLEAK ++STACKLEAK_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/stackleak_plugin.= so -DSTACKLEAK_PLUGIN ++STACKLEAK_PLUGIN +=3D -fplugin-arg-stackleak_plugin-track-lowest-sp=3D1= 00 ++endif ++ifdef CONFIG_KALLOCSTAT_PLUGIN ++KALLOCSTAT_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kallocstat_plugi= n.so ++endif ++ifdef CONFIG_PAX_KERNEXEC_PLUGIN ++KERNEXEC_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kernexec_plugin.so ++KERNEXEC_PLUGIN +=3D -fplugin-arg-kernexec_plugin-method=3D$(CONFIG_PAX= _KERNEXEC_PLUGIN_METHOD) ++endif ++ifdef CONFIG_CHECKER_PLUGIN ++ifeq ($(call cc-ifversion, -ge, 0406, y), y) ++CHECKER_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/checker_plugin.so -= DCHECKER_PLUGIN ++endif ++endif ++GCC_PLUGINS :=3D $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN) $(KALLOCSTAT_PL= UGIN) $(KERNEXEC_PLUGIN) $(CHECKER_PLUGIN) ++export CONSTIFY_PLUGIN STACKLEAK_PLUGIN KERNEXEC_PLUGIN CHECKER_PLUGIN ++gcc-plugins: ++ $(Q)$(MAKE) $(build)=3Dtools/gcc ++else ++gcc-plugins: ++ifeq ($(call cc-ifversion, -ge, 0405, y), y) ++ $(error Your gcc installation does not support plugins. If the necess= ary headers for plugin support are missing, they should be installed. On= Debian, apt-get install gcc--plugin-dev. If you choose to ignore t= his error and lessen the improvements provided by this patch, re-run make= with the DISABLE_PAX_PLUGINS=3Dy argument.)) ++else ++ $(Q)echo "warning, your gcc version does not support plugins, you shou= ld upgrade it to gcc 4.5 at least" ++endif ++ $(Q)echo "PAX_MEMORY_STACKLEAK and other features will be less secure" ++endif ++endif ++ + include $(srctree)/arch/$(SRCARCH)/Makefile +=20 + ifneq ($(CONFIG_FRAME_WARN),0) +@@ -708,7 +745,7 @@ export mod_strip_cmd +=20 +=20 + ifeq ($(KBUILD_EXTMOD),) +-core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ ++core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ +=20 + vmlinux-dirs :=3D $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ + $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ +@@ -932,6 +969,7 @@ vmlinux.o: $(modpost-init) $(vmlinux-main) FORCE +=20 + # The actual objects are generated when descending,=20 + # make sure no implicit rule kicks in ++$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): KBUILD_CFLAGS += =3D $(GCC_PLUGINS) + $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): $(vmlinux-dirs)= ; +=20 + # Handle descending into subdirectories listed in $(vmlinux-dirs) +@@ -941,7 +979,7 @@ $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-ld= s): $(vmlinux-dirs) ; + # Error messages still appears in the original language +=20 + PHONY +=3D $(vmlinux-dirs) +-$(vmlinux-dirs): prepare scripts ++$(vmlinux-dirs): gcc-plugins prepare scripts + $(Q)$(MAKE) $(build)=3D$@ +=20 + # Store (new) KERNELRELASE string in include/config/kernel.release +@@ -986,6 +1024,7 @@ prepare0: archprepare FORCE + $(Q)$(MAKE) $(build)=3D. missing-syscalls +=20 + # All the preparing.. ++prepare: KBUILD_CFLAGS :=3D $(filter-out $(GCC_PLUGINS),$(KBUILD_CFLAGS= )) + prepare: prepare0 +=20 + # Generate some files +@@ -1087,6 +1126,7 @@ all: modules + # using awk while concatenating to the final file. +=20 + PHONY +=3D modules ++modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) + modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builti= n + $(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=3D$(objtree)/%/modules.order) = > $(objtree)/modules.order + @$(kecho) ' Building modules, stage 2.'; +@@ -1102,7 +1142,7 @@ modules.builtin: $(vmlinux-dirs:%=3D%/modules.buil= tin) +=20 + # Target to prepare building external modules + PHONY +=3D modules_prepare +-modules_prepare: prepare scripts ++modules_prepare: gcc-plugins prepare scripts +=20 + # Target to install modules + PHONY +=3D modules_install +@@ -1198,7 +1238,7 @@ distclean: mrproper + @find $(srctree) $(RCS_FIND_IGNORE) \ + \( -name '*.orig' -o -name '*.rej' -o -name '*~' \ + -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \ +- -o -name '.*.rej' -o -size 0 \ ++ -o -name '.*.rej' -o -name '*.so' -o -size 0 \ + -o -name '*%' -o -name '.*.cmd' -o -name 'core' \) \ + -type f -print | xargs rm -f +=20 +@@ -1360,6 +1400,7 @@ PHONY +=3D $(module-dirs) modules + $(module-dirs): crmodverdir $(objtree)/Module.symvers + $(Q)$(MAKE) $(build)=3D$(patsubst _module_%,%,$@) +=20 ++modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) + modules: $(module-dirs) + @$(kecho) ' Building modules, stage 2.'; + $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost +@@ -1486,17 +1527,19 @@ else + target-dir =3D $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@)) + endif +=20 +-%.s: %.c prepare scripts FORCE ++%.s: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%.s: %.c gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) + %.i: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +-%.o: %.c prepare scripts FORCE ++%.o: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%.o: %.c gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) + %.lst: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +-%.s: %.S prepare scripts FORCE ++%.s: %.S gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +-%.o: %.S prepare scripts FORCE ++%.o: %.S gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) + %.symtypes: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) +@@ -1506,11 +1549,13 @@ endif + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ + $(build)=3D$(build-dir) +-%/: prepare scripts FORCE ++%/: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%/: gcc-plugins prepare scripts FORCE + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ + $(build)=3D$(build-dir) +-%.ko: prepare scripts FORCE ++%.ko: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) ++%.ko: gcc-plugins prepare scripts FORCE + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ + $(build)=3D$(build-dir) $(@:.ko=3D.o) +diff --git a/arch/alpha/include/asm/elf.h b/arch/alpha/include/asm/elf.h +index da5449e..7418343 100644 +--- a/arch/alpha/include/asm/elf.h ++++ b/arch/alpha/include/asm/elf.h +@@ -90,6 +90,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; =20 #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x1000000) =20 @@ -15,9 +381,10 @@ diff -urNp linux-3.1.4/arch/alpha/include/asm/elf.h l= inux-3.1.4/arch/alpha/inclu /* $0 is set by ld.so to a pointer to a function which might be=20 registered using atexit. This provides a mean for the dynamic linker to call DT_FINI functions for shared libraries that have -diff -urNp linux-3.1.4/arch/alpha/include/asm/pgtable.h linux-3.1.4/arch= /alpha/include/asm/pgtable.h ---- linux-3.1.4/arch/alpha/include/asm/pgtable.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/alpha/include/asm/pgtable.h 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/arch/alpha/include/asm/pgtable.h b/arch/alpha/include/asm/p= gtable.h +index de98a73..bd4f1f8 100644 +--- a/arch/alpha/include/asm/pgtable.h ++++ b/arch/alpha/include/asm/pgtable.h @@ -101,6 +101,17 @@ struct vm_area_struct; #define PAGE_SHARED __pgprot(_PAGE_VALID | __ACCESS_BITS) #define PAGE_COPY __pgprot(_PAGE_VALID | __ACCESS_BITS | _PAGE_FOW) @@ -36,10 +403,11 @@ diff -urNp linux-3.1.4/arch/alpha/include/asm/pgtabl= e.h linux-3.1.4/arch/alpha/i #define PAGE_KERNEL __pgprot(_PAGE_VALID | _PAGE_ASM | _PAGE_KRE | _PAG= E_KWE) =20 #define _PAGE_NORMAL(x) __pgprot(_PAGE_VALID | __ACCESS_BITS | (x)) -diff -urNp linux-3.1.4/arch/alpha/kernel/module.c linux-3.1.4/arch/alpha= /kernel/module.c ---- linux-3.1.4/arch/alpha/kernel/module.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/alpha/kernel/module.c 2011-11-16 18:39:07.000000000= -0500 -@@ -160,7 +160,7 @@ apply_relocate_add(Elf64_Shdr *sechdrs,=20 +diff --git a/arch/alpha/kernel/module.c b/arch/alpha/kernel/module.c +index 2fd00b7..cfd5069 100644 +--- a/arch/alpha/kernel/module.c ++++ b/arch/alpha/kernel/module.c +@@ -160,7 +160,7 @@ apply_relocate_add(Elf64_Shdr *sechdrs, const char *= strtab, =20 /* The small sections were sorted to the end of the segment. The following should definitely cover them. */ @@ -48,10 +416,11 @@ diff -urNp linux-3.1.4/arch/alpha/kernel/module.c li= nux-3.1.4/arch/alpha/kernel/ got =3D sechdrs[me->arch.gotsecindex].sh_addr; =20 for (i =3D 0; i < n; i++) { -diff -urNp linux-3.1.4/arch/alpha/kernel/osf_sys.c linux-3.1.4/arch/alph= a/kernel/osf_sys.c ---- linux-3.1.4/arch/alpha/kernel/osf_sys.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/alpha/kernel/osf_sys.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -1147,7 +1147,7 @@ arch_get_unmapped_area_1(unsigned long a +diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c +index 01e8715..be0e80f 100644 +--- a/arch/alpha/kernel/osf_sys.c ++++ b/arch/alpha/kernel/osf_sys.c +@@ -1147,7 +1147,7 @@ arch_get_unmapped_area_1(unsigned long addr, unsig= ned long len, /* At this point: (!vma || addr < vma->vm_end). */ if (limit - len < addr) return -ENOMEM; @@ -60,7 +429,7 @@ diff -urNp linux-3.1.4/arch/alpha/kernel/osf_sys.c lin= ux-3.1.4/arch/alpha/kernel return addr; addr =3D vma->vm_end; vma =3D vma->vm_next; -@@ -1183,6 +1183,10 @@ arch_get_unmapped_area(struct file *filp +@@ -1183,6 +1183,10 @@ arch_get_unmapped_area(struct file *filp, unsigne= d long addr, merely specific addresses, but regions of memory -- perhaps this feature should be incorporated into all ports? */ =20 @@ -71,7 +440,7 @@ diff -urNp linux-3.1.4/arch/alpha/kernel/osf_sys.c lin= ux-3.1.4/arch/alpha/kernel if (addr) { addr =3D arch_get_unmapped_area_1 (PAGE_ALIGN(addr), len, limit); if (addr !=3D (unsigned long) -ENOMEM) -@@ -1190,8 +1194,8 @@ arch_get_unmapped_area(struct file *filp +@@ -1190,8 +1194,8 @@ arch_get_unmapped_area(struct file *filp, unsigned= long addr, } =20 /* Next, try allocating at TASK_UNMAPPED_BASE. */ @@ -82,10 +451,11 @@ diff -urNp linux-3.1.4/arch/alpha/kernel/osf_sys.c l= inux-3.1.4/arch/alpha/kernel if (addr !=3D (unsigned long) -ENOMEM) return addr; =20 -diff -urNp linux-3.1.4/arch/alpha/mm/fault.c linux-3.1.4/arch/alpha/mm/f= ault.c ---- linux-3.1.4/arch/alpha/mm/fault.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/alpha/mm/fault.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -54,6 +54,124 @@ __load_new_mm_context(struct mm_struct * +diff --git a/arch/alpha/mm/fault.c b/arch/alpha/mm/fault.c +index fadd5f8..904e73a 100644 +--- a/arch/alpha/mm/fault.c ++++ b/arch/alpha/mm/fault.c +@@ -54,6 +54,124 @@ __load_new_mm_context(struct mm_struct *next_mm) __reload_thread(pcb); } =20 @@ -210,7 +580,7 @@ diff -urNp linux-3.1.4/arch/alpha/mm/fault.c linux-3.= 1.4/arch/alpha/mm/fault.c =20 /* * This routine handles page faults. It determines the address, -@@ -131,8 +249,29 @@ do_page_fault(unsigned long address, uns +@@ -131,8 +249,29 @@ do_page_fault(unsigned long address, unsigned long = mmcsr, good_area: si_code =3D SEGV_ACCERR; if (cause < 0) { @@ -241,10 +611,11 @@ diff -urNp linux-3.1.4/arch/alpha/mm/fault.c linux-= 3.1.4/arch/alpha/mm/fault.c } else if (!cause) { /* Allow reads even for write-only mappings */ if (!(vma->vm_flags & (VM_READ | VM_WRITE))) -diff -urNp linux-3.1.4/arch/arm/include/asm/elf.h linux-3.1.4/arch/arm/i= nclude/asm/elf.h ---- linux-3.1.4/arch/arm/include/asm/elf.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/arm/include/asm/elf.h 2011-11-16 18:39:07.000000000= -0500 -@@ -116,7 +116,14 @@ int dump_task_regs(struct task_struct *t +diff --git a/arch/arm/include/asm/elf.h b/arch/arm/include/asm/elf.h +index 0e9ce8d..6ef1e03 100644 +--- a/arch/arm/include/asm/elf.h ++++ b/arch/arm/include/asm/elf.h +@@ -116,7 +116,14 @@ int dump_task_regs(struct task_struct *t, elf_gregs= et_t *elfregs); the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ =20 @@ -260,7 +631,7 @@ diff -urNp linux-3.1.4/arch/arm/include/asm/elf.h lin= ux-3.1.4/arch/arm/include/a =20 /* When the program starts, a1 contains a pointer to a function to be=20 registered with atexit, as per the SVR4 ABI. A value of 0 means we=20 -@@ -126,10 +133,6 @@ int dump_task_regs(struct task_struct *t +@@ -126,10 +133,6 @@ int dump_task_regs(struct task_struct *t, elf_gregs= et_t *elfregs); extern void elf_set_personality(const struct elf32_hdr *); #define SET_PERSONALITY(ex) elf_set_personality(&(ex)) =20 @@ -271,9 +642,10 @@ diff -urNp linux-3.1.4/arch/arm/include/asm/elf.h li= nux-3.1.4/arch/arm/include/a extern int vectors_user_mapping(void); #define arch_setup_additional_pages(bprm, uses_interp) vectors_user_map= ping() #define ARCH_HAS_SETUP_ADDITIONAL_PAGES -diff -urNp linux-3.1.4/arch/arm/include/asm/kmap_types.h linux-3.1.4/arc= h/arm/include/asm/kmap_types.h ---- linux-3.1.4/arch/arm/include/asm/kmap_types.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/arm/include/asm/kmap_types.h 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/arch/arm/include/asm/kmap_types.h b/arch/arm/include/asm/km= ap_types.h +index e51b1e8..32a3113 100644 +--- a/arch/arm/include/asm/kmap_types.h ++++ b/arch/arm/include/asm/kmap_types.h @@ -21,6 +21,7 @@ enum km_type { KM_L1_CACHE, KM_L2_CACHE, @@ -282,9 +654,10 @@ diff -urNp linux-3.1.4/arch/arm/include/asm/kmap_typ= es.h linux-3.1.4/arch/arm/in KM_TYPE_NR }; =20 -diff -urNp linux-3.1.4/arch/arm/include/asm/uaccess.h linux-3.1.4/arch/a= rm/include/asm/uaccess.h ---- linux-3.1.4/arch/arm/include/asm/uaccess.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/arm/include/asm/uaccess.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/arm/include/asm/uaccess.h b/arch/arm/include/asm/uacce= ss.h +index b293616..96310e5 100644 +--- a/arch/arm/include/asm/uaccess.h ++++ b/arch/arm/include/asm/uaccess.h @@ -22,6 +22,8 @@ #define VERIFY_READ 0 #define VERIFY_WRITE 1 @@ -320,7 +693,7 @@ diff -urNp linux-3.1.4/arch/arm/include/asm/uaccess.h= linux-3.1.4/arch/arm/inclu extern unsigned long __must_check __copy_to_user_std(void __user *to, c= onst void *from, unsigned long n); extern unsigned long __must_check __clear_user(void __user *addr, unsig= ned long n); extern unsigned long __must_check __clear_user_std(void __user *addr, u= nsigned long n); -@@ -403,6 +420,9 @@ extern unsigned long __must_check __strn +@@ -403,6 +420,9 @@ extern unsigned long __must_check __strnlen_user(con= st char __user *s, long n); =20 static inline unsigned long __must_check copy_from_user(void *to, const= void __user *from, unsigned long n) { @@ -330,7 +703,7 @@ diff -urNp linux-3.1.4/arch/arm/include/asm/uaccess.h= linux-3.1.4/arch/arm/inclu if (access_ok(VERIFY_READ, from, n)) n =3D __copy_from_user(to, from, n); else /* security hole - plug it */ -@@ -412,6 +432,9 @@ static inline unsigned long __must_check +@@ -412,6 +432,9 @@ static inline unsigned long __must_check copy_from_u= ser(void *to, const void __u =20 static inline unsigned long __must_check copy_to_user(void __user *to, = const void *from, unsigned long n) { @@ -340,9 +713,10 @@ diff -urNp linux-3.1.4/arch/arm/include/asm/uaccess.= h linux-3.1.4/arch/arm/inclu if (access_ok(VERIFY_WRITE, to, n)) n =3D __copy_to_user(to, from, n); return n; -diff -urNp linux-3.1.4/arch/arm/kernel/armksyms.c linux-3.1.4/arch/arm/k= ernel/armksyms.c ---- linux-3.1.4/arch/arm/kernel/armksyms.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/arm/kernel/armksyms.c 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/arm/kernel/armksyms.c b/arch/arm/kernel/armksyms.c +index aeef960..2966009 100644 +--- a/arch/arm/kernel/armksyms.c ++++ b/arch/arm/kernel/armksyms.c @@ -98,8 +98,8 @@ EXPORT_SYMBOL(__strncpy_from_user); #ifdef CONFIG_MMU EXPORT_SYMBOL(copy_page); @@ -354,9 +728,10 @@ diff -urNp linux-3.1.4/arch/arm/kernel/armksyms.c li= nux-3.1.4/arch/arm/kernel/ar EXPORT_SYMBOL(__clear_user); =20 EXPORT_SYMBOL(__get_user_1); -diff -urNp linux-3.1.4/arch/arm/kernel/process.c linux-3.1.4/arch/arm/ke= rnel/process.c ---- linux-3.1.4/arch/arm/kernel/process.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/arm/kernel/process.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c +index 1a347f4..8b4c8a1 100644 +--- a/arch/arm/kernel/process.c ++++ b/arch/arm/kernel/process.c @@ -28,7 +28,6 @@ #include #include @@ -365,7 +740,7 @@ diff -urNp linux-3.1.4/arch/arm/kernel/process.c linu= x-3.1.4/arch/arm/kernel/pro #include #include =20 -@@ -481,12 +480,6 @@ unsigned long get_wchan(struct task_stru +@@ -481,12 +480,6 @@ unsigned long get_wchan(struct task_struct *p) return 0; } =20 @@ -378,10 +753,11 @@ diff -urNp linux-3.1.4/arch/arm/kernel/process.c li= nux-3.1.4/arch/arm/kernel/pro #ifdef CONFIG_MMU /* * The vectors page is always readable from user space for the -diff -urNp linux-3.1.4/arch/arm/kernel/traps.c linux-3.1.4/arch/arm/kern= el/traps.c ---- linux-3.1.4/arch/arm/kernel/traps.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/arm/kernel/traps.c 2011-11-16 18:40:08.000000000 -0= 500 -@@ -257,6 +257,8 @@ static int __die(const char *str, int er +diff --git a/arch/arm/kernel/traps.c b/arch/arm/kernel/traps.c +index bc9f9da..c75d826 100644 +--- a/arch/arm/kernel/traps.c ++++ b/arch/arm/kernel/traps.c +@@ -257,6 +257,8 @@ static int __die(const char *str, int err, struct th= read_info *thread, struct pt =20 static DEFINE_SPINLOCK(die_lock); =20 @@ -390,7 +766,7 @@ diff -urNp linux-3.1.4/arch/arm/kernel/traps.c linux-= 3.1.4/arch/arm/kernel/traps /* * This function is protected against re-entrancy. */ -@@ -284,6 +286,9 @@ void die(const char *str, struct pt_regs +@@ -284,6 +286,9 @@ void die(const char *str, struct pt_regs *regs, int = err) panic("Fatal exception in interrupt"); if (panic_on_oops) panic("Fatal exception"); @@ -400,9 +776,10 @@ diff -urNp linux-3.1.4/arch/arm/kernel/traps.c linux= -3.1.4/arch/arm/kernel/traps if (ret !=3D NOTIFY_STOP) do_exit(SIGSEGV); } -diff -urNp linux-3.1.4/arch/arm/lib/copy_from_user.S linux-3.1.4/arch/ar= m/lib/copy_from_user.S ---- linux-3.1.4/arch/arm/lib/copy_from_user.S 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/arm/lib/copy_from_user.S 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/arm/lib/copy_from_user.S b/arch/arm/lib/copy_from_user= .S +index 66a477a..bee61d3 100644 +--- a/arch/arm/lib/copy_from_user.S ++++ b/arch/arm/lib/copy_from_user.S @@ -16,7 +16,7 @@ /* * Prototype: @@ -426,9 +803,10 @@ diff -urNp linux-3.1.4/arch/arm/lib/copy_from_user.S= linux-3.1.4/arch/arm/lib/co =20 .pushsection .fixup,"ax" .align 0 -diff -urNp linux-3.1.4/arch/arm/lib/copy_to_user.S linux-3.1.4/arch/arm/= lib/copy_to_user.S ---- linux-3.1.4/arch/arm/lib/copy_to_user.S 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/arm/lib/copy_to_user.S 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/arm/lib/copy_to_user.S b/arch/arm/lib/copy_to_user.S +index d066df6..df28194 100644 +--- a/arch/arm/lib/copy_to_user.S ++++ b/arch/arm/lib/copy_to_user.S @@ -16,7 +16,7 @@ /* * Prototype: @@ -452,9 +830,10 @@ diff -urNp linux-3.1.4/arch/arm/lib/copy_to_user.S l= inux-3.1.4/arch/arm/lib/copy ENDPROC(__copy_to_user_std) =20 .pushsection .fixup,"ax" -diff -urNp linux-3.1.4/arch/arm/lib/uaccess.S linux-3.1.4/arch/arm/lib/u= access.S ---- linux-3.1.4/arch/arm/lib/uaccess.S 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/arm/lib/uaccess.S 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/arm/lib/uaccess.S b/arch/arm/lib/uaccess.S +index d0ece2a..5ae2f39 100644 +--- a/arch/arm/lib/uaccess.S ++++ b/arch/arm/lib/uaccess.S @@ -20,7 +20,7 @@ =20 #define PAGE_SHIFT 12 @@ -464,7 +843,7 @@ diff -urNp linux-3.1.4/arch/arm/lib/uaccess.S linux-3= .1.4/arch/arm/lib/uaccess.S * Purpose : copy a block to user memory from kernel memory * Params : to - user memory * : from - kernel memory -@@ -40,7 +40,7 @@ USER( T(strgtb) r3, [r0], #1) @ May f +@@ -40,7 +40,7 @@ USER( T(strgtb) r3, [r0], #1) @ May fault sub r2, r2, ip b .Lc2u_dest_aligned =20 @@ -473,7 +852,7 @@ diff -urNp linux-3.1.4/arch/arm/lib/uaccess.S linux-3= .1.4/arch/arm/lib/uaccess.S stmfd sp!, {r2, r4 - r7, lr} cmp r2, #4 blt .Lc2u_not_enough -@@ -278,14 +278,14 @@ USER( T(strgeb) r3, [r0], #1) @ May f +@@ -278,14 +278,14 @@ USER( T(strgeb) r3, [r0], #1) @ May fault ldrgtb r3, [r1], #0 USER( T(strgtb) r3, [r0], #1) @ May fault b .Lc2u_finished @@ -490,7 +869,7 @@ diff -urNp linux-3.1.4/arch/arm/lib/uaccess.S linux-3= .1.4/arch/arm/lib/uaccess.S * Purpose : copy a block from user memory to kernel memory * Params : to - kernel memory * : from - user memory -@@ -304,7 +304,7 @@ USER( T(ldrgtb) r3, [r1], #1) @ May f +@@ -304,7 +304,7 @@ USER( T(ldrgtb) r3, [r1], #1) @ May fault sub r2, r2, ip b .Lcfu_dest_aligned =20 @@ -499,7 +878,7 @@ diff -urNp linux-3.1.4/arch/arm/lib/uaccess.S linux-3= .1.4/arch/arm/lib/uaccess.S stmfd sp!, {r0, r2, r4 - r7, lr} cmp r2, #4 blt .Lcfu_not_enough -@@ -544,7 +544,7 @@ USER( T(ldrgeb) r3, [r1], #1) @ May f +@@ -544,7 +544,7 @@ USER( T(ldrgeb) r3, [r1], #1) @ May fault USER( T(ldrgtb) r3, [r1], #1) @ May fault strgtb r3, [r0], #1 b .Lcfu_finished @@ -508,9 +887,10 @@ diff -urNp linux-3.1.4/arch/arm/lib/uaccess.S linux-= 3.1.4/arch/arm/lib/uaccess.S =20 .pushsection .fixup,"ax" .align 0 -diff -urNp linux-3.1.4/arch/arm/lib/uaccess_with_memcpy.c linux-3.1.4/ar= ch/arm/lib/uaccess_with_memcpy.c ---- linux-3.1.4/arch/arm/lib/uaccess_with_memcpy.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/arm/lib/uaccess_with_memcpy.c 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/arm/lib/uaccess_with_memcpy.c b/arch/arm/lib/uaccess_w= ith_memcpy.c +index 8b9b136..70d5100 100644 +--- a/arch/arm/lib/uaccess_with_memcpy.c ++++ b/arch/arm/lib/uaccess_with_memcpy.c @@ -103,7 +103,7 @@ out: } =20 @@ -520,10 +900,11 @@ diff -urNp linux-3.1.4/arch/arm/lib/uaccess_with_me= mcpy.c linux-3.1.4/arch/arm/l { /* * This test is stubbed out of the main function above to keep -diff -urNp linux-3.1.4/arch/arm/mach-ux500/mbox-db5500.c linux-3.1.4/arc= h/arm/mach-ux500/mbox-db5500.c ---- linux-3.1.4/arch/arm/mach-ux500/mbox-db5500.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/arm/mach-ux500/mbox-db5500.c 2011-11-16 18:40:08.00= 0000000 -0500 -@@ -168,7 +168,7 @@ static ssize_t mbox_read_fifo(struct dev +diff --git a/arch/arm/mach-ux500/mbox-db5500.c b/arch/arm/mach-ux500/mbo= x-db5500.c +index 2b2d51c..0127490 100644 +--- a/arch/arm/mach-ux500/mbox-db5500.c ++++ b/arch/arm/mach-ux500/mbox-db5500.c +@@ -168,7 +168,7 @@ static ssize_t mbox_read_fifo(struct device *dev, return sprintf(buf, "0x%X\n", mbox_value); } =20 @@ -532,10 +913,11 @@ diff -urNp linux-3.1.4/arch/arm/mach-ux500/mbox-db5= 500.c linux-3.1.4/arch/arm/ma =20 static int mbox_show(struct seq_file *s, void *data) { -diff -urNp linux-3.1.4/arch/arm/mm/fault.c linux-3.1.4/arch/arm/mm/fault= .c ---- linux-3.1.4/arch/arm/mm/fault.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/arm/mm/fault.c 2011-11-16 18:39:07.000000000 -0500 -@@ -182,6 +182,13 @@ __do_user_fault(struct task_struct *tsk, +diff --git a/arch/arm/mm/fault.c b/arch/arm/mm/fault.c +index 3b5ea68..42fc9af 100644 +--- a/arch/arm/mm/fault.c ++++ b/arch/arm/mm/fault.c +@@ -182,6 +182,13 @@ __do_user_fault(struct task_struct *tsk, unsigned l= ong addr, } #endif =20 @@ -549,7 +931,7 @@ diff -urNp linux-3.1.4/arch/arm/mm/fault.c linux-3.1.= 4/arch/arm/mm/fault.c tsk->thread.address =3D addr; tsk->thread.error_code =3D fsr; tsk->thread.trap_no =3D 14; -@@ -383,6 +390,33 @@ do_page_fault(unsigned long addr, unsign +@@ -383,6 +390,33 @@ do_page_fault(unsigned long addr, unsigned int fsr,= struct pt_regs *regs) } #endif /* CONFIG_MMU */ =20 @@ -583,10 +965,11 @@ diff -urNp linux-3.1.4/arch/arm/mm/fault.c linux-3.= 1.4/arch/arm/mm/fault.c /* * First Level Translation Fault Handler * -diff -urNp linux-3.1.4/arch/arm/mm/mmap.c linux-3.1.4/arch/arm/mm/mmap.c ---- linux-3.1.4/arch/arm/mm/mmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/arm/mm/mmap.c 2011-11-16 18:39:07.000000000 -0500 -@@ -65,6 +65,10 @@ arch_get_unmapped_area(struct file *filp +diff --git a/arch/arm/mm/mmap.c b/arch/arm/mm/mmap.c +index 74be05f..f605b8c 100644 +--- a/arch/arm/mm/mmap.c ++++ b/arch/arm/mm/mmap.c +@@ -65,6 +65,10 @@ arch_get_unmapped_area(struct file *filp, unsigned lo= ng addr, if (len > TASK_SIZE) return -ENOMEM; =20 @@ -597,7 +980,7 @@ diff -urNp linux-3.1.4/arch/arm/mm/mmap.c linux-3.1.4= /arch/arm/mm/mmap.c if (addr) { if (do_align) addr =3D COLOUR_ALIGN(addr, pgoff); -@@ -72,15 +76,14 @@ arch_get_unmapped_area(struct file *filp +@@ -72,15 +76,14 @@ arch_get_unmapped_area(struct file *filp, unsigned l= ong addr, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -635,10 +1018,11 @@ diff -urNp linux-3.1.4/arch/arm/mm/mmap.c linux-3.= 1.4/arch/arm/mm/mmap.c /* * Remember the place where we stopped the search: */ -diff -urNp linux-3.1.4/arch/avr32/include/asm/elf.h linux-3.1.4/arch/avr= 32/include/asm/elf.h ---- linux-3.1.4/arch/avr32/include/asm/elf.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/avr32/include/asm/elf.h 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -84,8 +84,14 @@ typedef struct user_fpu_struct elf_fpreg +diff --git a/arch/avr32/include/asm/elf.h b/arch/avr32/include/asm/elf.h +index 3b3159b..425ea94 100644 +--- a/arch/avr32/include/asm/elf.h ++++ b/arch/avr32/include/asm/elf.h +@@ -84,8 +84,14 @@ typedef struct user_fpu_struct elf_fpregset_t; the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ =20 @@ -654,9 +1038,10 @@ diff -urNp linux-3.1.4/arch/avr32/include/asm/elf.h= linux-3.1.4/arch/avr32/inclu =20 /* This yields a mask that user programs can use to figure out what instruction set this CPU supports. This could be done in user space= , -diff -urNp linux-3.1.4/arch/avr32/include/asm/kmap_types.h linux-3.1.4/a= rch/avr32/include/asm/kmap_types.h ---- linux-3.1.4/arch/avr32/include/asm/kmap_types.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/avr32/include/asm/kmap_types.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/arch/avr32/include/asm/kmap_types.h b/arch/avr32/include/as= m/kmap_types.h +index b7f5c68..556135c 100644 +--- a/arch/avr32/include/asm/kmap_types.h ++++ b/arch/avr32/include/asm/kmap_types.h @@ -22,7 +22,8 @@ D(10) KM_IRQ0, D(11) KM_IRQ1, D(12) KM_SOFTIRQ0, @@ -667,10 +1052,11 @@ diff -urNp linux-3.1.4/arch/avr32/include/asm/kmap= _types.h linux-3.1.4/arch/avr3 }; =20 #undef D -diff -urNp linux-3.1.4/arch/avr32/mm/fault.c linux-3.1.4/arch/avr32/mm/f= ault.c ---- linux-3.1.4/arch/avr32/mm/fault.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/avr32/mm/fault.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -41,6 +41,23 @@ static inline int notify_page_fault(stru +diff --git a/arch/avr32/mm/fault.c b/arch/avr32/mm/fault.c +index f7040a1..db9f300 100644 +--- a/arch/avr32/mm/fault.c ++++ b/arch/avr32/mm/fault.c +@@ -41,6 +41,23 @@ static inline int notify_page_fault(struct pt_regs *r= egs, int trap) =20 int exception_trace =3D 1; =20 @@ -711,9 +1097,10 @@ diff -urNp linux-3.1.4/arch/avr32/mm/fault.c linux-= 3.1.4/arch/avr32/mm/fault.c if (exception_trace && printk_ratelimit()) printk("%s%s[%d]: segfault at %08lx pc %08lx " "sp %08lx ecr %lu\n", -diff -urNp linux-3.1.4/arch/frv/include/asm/kmap_types.h linux-3.1.4/arc= h/frv/include/asm/kmap_types.h ---- linux-3.1.4/arch/frv/include/asm/kmap_types.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/frv/include/asm/kmap_types.h 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/arch/frv/include/asm/kmap_types.h b/arch/frv/include/asm/km= ap_types.h +index f8e16b2..c73ff79 100644 +--- a/arch/frv/include/asm/kmap_types.h ++++ b/arch/frv/include/asm/kmap_types.h @@ -23,6 +23,7 @@ enum km_type { KM_IRQ1, KM_SOFTIRQ0, @@ -722,10 +1109,11 @@ diff -urNp linux-3.1.4/arch/frv/include/asm/kmap_t= ypes.h linux-3.1.4/arch/frv/in KM_TYPE_NR }; =20 -diff -urNp linux-3.1.4/arch/frv/mm/elf-fdpic.c linux-3.1.4/arch/frv/mm/e= lf-fdpic.c ---- linux-3.1.4/arch/frv/mm/elf-fdpic.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/frv/mm/elf-fdpic.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -73,8 +73,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/frv/mm/elf-fdpic.c b/arch/frv/mm/elf-fdpic.c +index 385fd30..6c3d97e 100644 +--- a/arch/frv/mm/elf-fdpic.c ++++ b/arch/frv/mm/elf-fdpic.c +@@ -73,8 +73,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi if (addr) { addr =3D PAGE_ALIGN(addr); vma =3D find_vma(current->mm, addr); @@ -735,7 +1123,7 @@ diff -urNp linux-3.1.4/arch/frv/mm/elf-fdpic.c linux= -3.1.4/arch/frv/mm/elf-fdpic goto success; } =20 -@@ -89,7 +88,7 @@ unsigned long arch_get_unmapped_area(str +@@ -89,7 +88,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi for (; vma; vma =3D vma->vm_next) { if (addr > limit) break; @@ -744,7 +1132,7 @@ diff -urNp linux-3.1.4/arch/frv/mm/elf-fdpic.c linux= -3.1.4/arch/frv/mm/elf-fdpic goto success; addr =3D vma->vm_end; } -@@ -104,7 +103,7 @@ unsigned long arch_get_unmapped_area(str +@@ -104,7 +103,7 @@ unsigned long arch_get_unmapped_area(struct file *fi= lp, unsigned long addr, unsi for (; vma; vma =3D vma->vm_next) { if (addr > limit) break; @@ -753,9 +1141,10 @@ diff -urNp linux-3.1.4/arch/frv/mm/elf-fdpic.c linu= x-3.1.4/arch/frv/mm/elf-fdpic goto success; addr =3D vma->vm_end; } -diff -urNp linux-3.1.4/arch/ia64/include/asm/elf.h linux-3.1.4/arch/ia64= /include/asm/elf.h ---- linux-3.1.4/arch/ia64/include/asm/elf.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/ia64/include/asm/elf.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/ia64/include/asm/elf.h b/arch/ia64/include/asm/elf.h +index b5298eb..67c6e62 100644 +--- a/arch/ia64/include/asm/elf.h ++++ b/arch/ia64/include/asm/elf.h @@ -42,6 +42,13 @@ */ #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x800000000UL) @@ -770,9 +1159,10 @@ diff -urNp linux-3.1.4/arch/ia64/include/asm/elf.h = linux-3.1.4/arch/ia64/include #define PT_IA_64_UNWIND 0x70000001 =20 /* IA-64 relocations: */ -diff -urNp linux-3.1.4/arch/ia64/include/asm/pgtable.h linux-3.1.4/arch/= ia64/include/asm/pgtable.h ---- linux-3.1.4/arch/ia64/include/asm/pgtable.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/ia64/include/asm/pgtable.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/ia64/include/asm/pgtable.h b/arch/ia64/include/asm/pgt= able.h +index 1a97af3..7529d31 100644 +--- a/arch/ia64/include/asm/pgtable.h ++++ b/arch/ia64/include/asm/pgtable.h @@ -12,7 +12,7 @@ * David Mosberger-Tang */ @@ -800,10 +1190,11 @@ diff -urNp linux-3.1.4/arch/ia64/include/asm/pgtab= le.h linux-3.1.4/arch/ia64/inc #define PAGE_GATE __pgprot(__ACCESS_BITS | _PAGE_PL_0 | _PAGE_AR_X_RX) #define PAGE_KERNEL __pgprot(__DIRTY_BITS | _PAGE_PL_0 | _PAGE_AR_RWX) #define PAGE_KERNELRX __pgprot(__ACCESS_BITS | _PAGE_PL_0 | _PAGE_AR_RX= ) -diff -urNp linux-3.1.4/arch/ia64/include/asm/spinlock.h linux-3.1.4/arch= /ia64/include/asm/spinlock.h ---- linux-3.1.4/arch/ia64/include/asm/spinlock.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/ia64/include/asm/spinlock.h 2011-11-16 18:39:07.000= 000000 -0500 -@@ -72,7 +72,7 @@ static __always_inline void __ticket_spi +diff --git a/arch/ia64/include/asm/spinlock.h b/arch/ia64/include/asm/sp= inlock.h +index b77768d..e0795eb 100644 +--- a/arch/ia64/include/asm/spinlock.h ++++ b/arch/ia64/include/asm/spinlock.h +@@ -72,7 +72,7 @@ static __always_inline void __ticket_spin_unlock(arch_= spinlock_t *lock) unsigned short *p =3D (unsigned short *)&lock->lock + 1, tmp; =20 asm volatile ("ld2.bias %0=3D[%1]" : "=3Dr"(tmp) : "r"(p)); @@ -812,10 +1203,11 @@ diff -urNp linux-3.1.4/arch/ia64/include/asm/spinl= ock.h linux-3.1.4/arch/ia64/in } =20 static __always_inline void __ticket_spin_unlock_wait(arch_spinlock_t *= lock) -diff -urNp linux-3.1.4/arch/ia64/include/asm/uaccess.h linux-3.1.4/arch/= ia64/include/asm/uaccess.h ---- linux-3.1.4/arch/ia64/include/asm/uaccess.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/ia64/include/asm/uaccess.h 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -257,7 +257,7 @@ __copy_from_user (void *to, const void _ +diff --git a/arch/ia64/include/asm/uaccess.h b/arch/ia64/include/asm/uac= cess.h +index 449c8c0..432a3d2 100644 +--- a/arch/ia64/include/asm/uaccess.h ++++ b/arch/ia64/include/asm/uaccess.h +@@ -257,7 +257,7 @@ __copy_from_user (void *to, const void __user *from,= unsigned long count) const void *__cu_from =3D (from); \ long __cu_len =3D (n); \ \ @@ -824,7 +1216,7 @@ diff -urNp linux-3.1.4/arch/ia64/include/asm/uaccess= .h linux-3.1.4/arch/ia64/inc __cu_len =3D __copy_user(__cu_to, (__force void __user *) __cu_from, = __cu_len); \ __cu_len; \ }) -@@ -269,7 +269,7 @@ __copy_from_user (void *to, const void _ +@@ -269,7 +269,7 @@ __copy_from_user (void *to, const void __user *from,= unsigned long count) long __cu_len =3D (n); \ \ __chk_user_ptr(__cu_from); \ @@ -833,9 +1225,10 @@ diff -urNp linux-3.1.4/arch/ia64/include/asm/uacces= s.h linux-3.1.4/arch/ia64/inc __cu_len =3D __copy_user((__force void __user *) __cu_to, __cu_from, = __cu_len); \ __cu_len; \ }) -diff -urNp linux-3.1.4/arch/ia64/kernel/module.c linux-3.1.4/arch/ia64/k= ernel/module.c ---- linux-3.1.4/arch/ia64/kernel/module.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/ia64/kernel/module.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/arch/ia64/kernel/module.c b/arch/ia64/kernel/module.c +index 24603be..948052d 100644 +--- a/arch/ia64/kernel/module.c ++++ b/arch/ia64/kernel/module.c @@ -307,8 +307,7 @@ plt_target (struct plt_entry *plt) void module_free (struct module *mod, void *module_region) @@ -846,7 +1239,7 @@ diff -urNp linux-3.1.4/arch/ia64/kernel/module.c lin= ux-3.1.4/arch/ia64/kernel/mo unw_remove_unwind_table(mod->arch.init_unw_table); mod->arch.init_unw_table =3D NULL; } -@@ -494,15 +493,39 @@ module_frob_arch_sections (Elf_Ehdr *ehd +@@ -494,15 +493,39 @@ module_frob_arch_sections (Elf_Ehdr *ehdr, Elf_Shd= r *sechdrs, char *secstrings, } =20 static inline int @@ -888,7 +1281,7 @@ diff -urNp linux-3.1.4/arch/ia64/kernel/module.c lin= ux-3.1.4/arch/ia64/kernel/mo } =20 static inline int -@@ -685,7 +708,14 @@ do_reloc (struct module *mod, uint8_t r_ +@@ -685,7 +708,14 @@ do_reloc (struct module *mod, uint8_t r_type, Elf64= _Sym *sym, uint64_t addend, break; =20 case RV_BDREL: @@ -904,7 +1297,7 @@ diff -urNp linux-3.1.4/arch/ia64/kernel/module.c lin= ux-3.1.4/arch/ia64/kernel/mo break; =20 case RV_LTV: -@@ -820,15 +850,15 @@ apply_relocate_add (Elf64_Shdr *sechdrs, +@@ -820,15 +850,15 @@ apply_relocate_add (Elf64_Shdr *sechdrs, const cha= r *strtab, unsigned int symind * addresses have been selected... */ uint64_t gp; @@ -924,10 +1317,11 @@ diff -urNp linux-3.1.4/arch/ia64/kernel/module.c l= inux-3.1.4/arch/ia64/kernel/mo mod->arch.gp =3D gp; DEBUGP("%s: placing gp at 0x%lx\n", __func__, gp); } -diff -urNp linux-3.1.4/arch/ia64/kernel/sys_ia64.c linux-3.1.4/arch/ia64= /kernel/sys_ia64.c ---- linux-3.1.4/arch/ia64/kernel/sys_ia64.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/ia64/kernel/sys_ia64.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -43,6 +43,13 @@ arch_get_unmapped_area (struct file *fil +diff --git a/arch/ia64/kernel/sys_ia64.c b/arch/ia64/kernel/sys_ia64.c +index 609d500..7dde2a8 100644 +--- a/arch/ia64/kernel/sys_ia64.c ++++ b/arch/ia64/kernel/sys_ia64.c +@@ -43,6 +43,13 @@ arch_get_unmapped_area (struct file *filp, unsigned l= ong addr, unsigned long len if (REGION_NUMBER(addr) =3D=3D RGN_HPAGE) addr =3D 0; #endif @@ -941,7 +1335,7 @@ diff -urNp linux-3.1.4/arch/ia64/kernel/sys_ia64.c l= inux-3.1.4/arch/ia64/kernel/ if (!addr) addr =3D mm->free_area_cache; =20 -@@ -61,14 +68,14 @@ arch_get_unmapped_area (struct file *fil +@@ -61,14 +68,14 @@ arch_get_unmapped_area (struct file *filp, unsigned = long addr, unsigned long len for (vma =3D find_vma(mm, addr); ; vma =3D vma->vm_next) { /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr || RGN_MAP_LIMIT - len < REGION_OFFSET(add= r)) { @@ -959,9 +1353,10 @@ diff -urNp linux-3.1.4/arch/ia64/kernel/sys_ia64.c = linux-3.1.4/arch/ia64/kernel/ /* Remember the address where we stopped this search: */ mm->free_area_cache =3D addr + len; return addr; -diff -urNp linux-3.1.4/arch/ia64/kernel/vmlinux.lds.S linux-3.1.4/arch/i= a64/kernel/vmlinux.lds.S ---- linux-3.1.4/arch/ia64/kernel/vmlinux.lds.S 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/ia64/kernel/vmlinux.lds.S 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/ia64/kernel/vmlinux.lds.S b/arch/ia64/kernel/vmlinux.l= ds.S +index 53c0ba0..2accdde 100644 +--- a/arch/ia64/kernel/vmlinux.lds.S ++++ b/arch/ia64/kernel/vmlinux.lds.S @@ -199,7 +199,7 @@ SECTIONS { /* Per-cpu data: */ . =3D ALIGN(PERCPU_PAGE_SIZE); @@ -971,10 +1366,11 @@ diff -urNp linux-3.1.4/arch/ia64/kernel/vmlinux.ld= s.S linux-3.1.4/arch/ia64/kern /* * ensure percpu data fits * into percpu page size -diff -urNp linux-3.1.4/arch/ia64/mm/fault.c linux-3.1.4/arch/ia64/mm/fau= lt.c ---- linux-3.1.4/arch/ia64/mm/fault.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/ia64/mm/fault.c 2011-11-16 18:39:07.000000000 -0500 -@@ -73,6 +73,23 @@ mapped_kernel_page_is_present (unsigned=20 +diff --git a/arch/ia64/mm/fault.c b/arch/ia64/mm/fault.c +index 20b3593..1ce77f0 100644 +--- a/arch/ia64/mm/fault.c ++++ b/arch/ia64/mm/fault.c +@@ -73,6 +73,23 @@ mapped_kernel_page_is_present (unsigned long address) return pte_present(pte); } =20 @@ -998,7 +1394,7 @@ diff -urNp linux-3.1.4/arch/ia64/mm/fault.c linux-3.= 1.4/arch/ia64/mm/fault.c void __kprobes ia64_do_page_fault (unsigned long address, unsigned long isr, struct pt= _regs *regs) { -@@ -146,9 +163,23 @@ ia64_do_page_fault (unsigned long addres +@@ -146,9 +163,23 @@ ia64_do_page_fault (unsigned long address, unsigned= long isr, struct pt_regs *re mask =3D ( (((isr >> IA64_ISR_X_BIT) & 1UL) << VM_EXEC_BIT) | (((isr >> IA64_ISR_W_BIT) & 1UL) << VM_WRITE_BIT)); =20 @@ -1023,10 +1419,11 @@ diff -urNp linux-3.1.4/arch/ia64/mm/fault.c linux= -3.1.4/arch/ia64/mm/fault.c /* * If for any reason at all we couldn't handle the fault, make * sure we exit gracefully rather than endlessly redo the -diff -urNp linux-3.1.4/arch/ia64/mm/hugetlbpage.c linux-3.1.4/arch/ia64/= mm/hugetlbpage.c ---- linux-3.1.4/arch/ia64/mm/hugetlbpage.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/ia64/mm/hugetlbpage.c 2011-11-16 18:39:07.000000000= -0500 -@@ -171,7 +171,7 @@ unsigned long hugetlb_get_unmapped_area( +diff --git a/arch/ia64/mm/hugetlbpage.c b/arch/ia64/mm/hugetlbpage.c +index 5ca674b..e0e1b70 100644 +--- a/arch/ia64/mm/hugetlbpage.c ++++ b/arch/ia64/mm/hugetlbpage.c +@@ -171,7 +171,7 @@ unsigned long hugetlb_get_unmapped_area(struct file = *file, unsigned long addr, u /* At this point: (!vmm || addr < vmm->vm_end). */ if (REGION_OFFSET(addr) + len > RGN_MAP_LIMIT) return -ENOMEM; @@ -1035,9 +1432,10 @@ diff -urNp linux-3.1.4/arch/ia64/mm/hugetlbpage.c = linux-3.1.4/arch/ia64/mm/huget return addr; addr =3D ALIGN(vmm->vm_end, HPAGE_SIZE); } -diff -urNp linux-3.1.4/arch/ia64/mm/init.c linux-3.1.4/arch/ia64/mm/init= .c ---- linux-3.1.4/arch/ia64/mm/init.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/ia64/mm/init.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c +index 00cb0e2..2ad8024 100644 +--- a/arch/ia64/mm/init.c ++++ b/arch/ia64/mm/init.c @@ -120,6 +120,19 @@ ia64_init_addr_space (void) vma->vm_start =3D current->thread.rbs_bot & PAGE_MASK; vma->vm_end =3D vma->vm_start + PAGE_SIZE; @@ -1058,9 +1456,10 @@ diff -urNp linux-3.1.4/arch/ia64/mm/init.c linux-3= .1.4/arch/ia64/mm/init.c vma->vm_page_prot =3D vm_get_page_prot(vma->vm_flags); down_write(¤t->mm->mmap_sem); if (insert_vm_struct(current->mm, vma)) { -diff -urNp linux-3.1.4/arch/m32r/lib/usercopy.c linux-3.1.4/arch/m32r/li= b/usercopy.c ---- linux-3.1.4/arch/m32r/lib/usercopy.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/m32r/lib/usercopy.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/arch/m32r/lib/usercopy.c b/arch/m32r/lib/usercopy.c +index 82abd15..d95ae5d 100644 +--- a/arch/m32r/lib/usercopy.c ++++ b/arch/m32r/lib/usercopy.c @@ -14,6 +14,9 @@ unsigned long __generic_copy_to_user(void __user *to, const void *from, unsigned long= n) @@ -1071,7 +1470,7 @@ diff -urNp linux-3.1.4/arch/m32r/lib/usercopy.c lin= ux-3.1.4/arch/m32r/lib/userco prefetch(from); if (access_ok(VERIFY_WRITE, to, n)) __copy_user(to,from,n); -@@ -23,6 +26,9 @@ __generic_copy_to_user(void __user *to,=20 +@@ -23,6 +26,9 @@ __generic_copy_to_user(void __user *to, const void *fr= om, unsigned long n) unsigned long __generic_copy_from_user(void *to, const void __user *from, unsigned lo= ng n) { @@ -1081,9 +1480,10 @@ diff -urNp linux-3.1.4/arch/m32r/lib/usercopy.c li= nux-3.1.4/arch/m32r/lib/userco prefetchw(to); if (access_ok(VERIFY_READ, from, n)) __copy_user_zeroing(to,from,n); -diff -urNp linux-3.1.4/arch/mips/include/asm/elf.h linux-3.1.4/arch/mips= /include/asm/elf.h ---- linux-3.1.4/arch/mips/include/asm/elf.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/mips/include/asm/elf.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/mips/include/asm/elf.h b/arch/mips/include/asm/elf.h +index 455c0ac..ad65fbe 100644 +--- a/arch/mips/include/asm/elf.h ++++ b/arch/mips/include/asm/elf.h @@ -372,13 +372,16 @@ extern const char *__elf_platform; #define ELF_ET_DYN_BASE (TASK_SIZE / 3 * 2) #endif @@ -1105,10 +1505,11 @@ diff -urNp linux-3.1.4/arch/mips/include/asm/elf.= h linux-3.1.4/arch/mips/include -#define arch_randomize_brk arch_randomize_brk - #endif /* _ASM_ELF_H */ -diff -urNp linux-3.1.4/arch/mips/include/asm/page.h linux-3.1.4/arch/mip= s/include/asm/page.h ---- linux-3.1.4/arch/mips/include/asm/page.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/mips/include/asm/page.h 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -93,7 +93,7 @@ extern void copy_user_highpage(struct pa +diff --git a/arch/mips/include/asm/page.h b/arch/mips/include/asm/page.h +index e59cd1a..8e329d6 100644 +--- a/arch/mips/include/asm/page.h ++++ b/arch/mips/include/asm/page.h +@@ -93,7 +93,7 @@ extern void copy_user_highpage(struct page *to, struct= page *from, #ifdef CONFIG_CPU_MIPS32 typedef struct { unsigned long pte_low, pte_high; } pte_t; #define pte_val(x) ((x).pte_low | ((unsigned long long)(x).pte_h= igh << 32)) @@ -1117,9 +1518,10 @@ diff -urNp linux-3.1.4/arch/mips/include/asm/page.= h linux-3.1.4/arch/mips/includ #else typedef struct { unsigned long long pte; } pte_t; #define pte_val(x) ((x).pte) -diff -urNp linux-3.1.4/arch/mips/include/asm/system.h linux-3.1.4/arch/m= ips/include/asm/system.h ---- linux-3.1.4/arch/mips/include/asm/system.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/mips/include/asm/system.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/mips/include/asm/system.h b/arch/mips/include/asm/syst= em.h +index 6018c80..7c37203 100644 +--- a/arch/mips/include/asm/system.h ++++ b/arch/mips/include/asm/system.h @@ -230,6 +230,6 @@ extern void per_cpu_trap_init(void); */ #define __ARCH_WANT_UNLOCKED_CTXSW @@ -1128,10 +1530,11 @@ diff -urNp linux-3.1.4/arch/mips/include/asm/syst= em.h linux-3.1.4/arch/mips/incl +#define arch_align_stack(x) ((x) & ~0xfUL) =20 #endif /* _ASM_SYSTEM_H */ -diff -urNp linux-3.1.4/arch/mips/kernel/binfmt_elfn32.c linux-3.1.4/arch= /mips/kernel/binfmt_elfn32.c ---- linux-3.1.4/arch/mips/kernel/binfmt_elfn32.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/mips/kernel/binfmt_elfn32.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -50,6 +50,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_N +diff --git a/arch/mips/kernel/binfmt_elfn32.c b/arch/mips/kernel/binfmt_= elfn32.c +index 9fdd8bc..4bd7f1a 100644 +--- a/arch/mips/kernel/binfmt_elfn32.c ++++ b/arch/mips/kernel/binfmt_elfn32.c +@@ -50,6 +50,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; #undef ELF_ET_DYN_BASE #define ELF_ET_DYN_BASE (TASK32_SIZE / 3 * 2) =20 @@ -1145,10 +1548,11 @@ diff -urNp linux-3.1.4/arch/mips/kernel/binfmt_el= fn32.c linux-3.1.4/arch/mips/ke #include #include #include -diff -urNp linux-3.1.4/arch/mips/kernel/binfmt_elfo32.c linux-3.1.4/arch= /mips/kernel/binfmt_elfo32.c ---- linux-3.1.4/arch/mips/kernel/binfmt_elfo32.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/mips/kernel/binfmt_elfo32.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -52,6 +52,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_N +diff --git a/arch/mips/kernel/binfmt_elfo32.c b/arch/mips/kernel/binfmt_= elfo32.c +index ff44823..97f8906 100644 +--- a/arch/mips/kernel/binfmt_elfo32.c ++++ b/arch/mips/kernel/binfmt_elfo32.c +@@ -52,6 +52,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; #undef ELF_ET_DYN_BASE #define ELF_ET_DYN_BASE (TASK32_SIZE / 3 * 2) =20 @@ -1162,10 +1566,11 @@ diff -urNp linux-3.1.4/arch/mips/kernel/binfmt_el= fo32.c linux-3.1.4/arch/mips/ke #include =20 /* -diff -urNp linux-3.1.4/arch/mips/kernel/process.c linux-3.1.4/arch/mips/= kernel/process.c ---- linux-3.1.4/arch/mips/kernel/process.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/mips/kernel/process.c 2011-11-16 18:39:07.000000000= -0500 -@@ -481,15 +481,3 @@ unsigned long get_wchan(struct task_stru +diff --git a/arch/mips/kernel/process.c b/arch/mips/kernel/process.c +index b30cb25..454c0a9 100644 +--- a/arch/mips/kernel/process.c ++++ b/arch/mips/kernel/process.c +@@ -481,15 +481,3 @@ unsigned long get_wchan(struct task_struct *task) out: return pc; } @@ -1181,9 +1586,10 @@ diff -urNp linux-3.1.4/arch/mips/kernel/process.c = linux-3.1.4/arch/mips/kernel/p - - return sp & ALMASK; -} -diff -urNp linux-3.1.4/arch/mips/mm/fault.c linux-3.1.4/arch/mips/mm/fau= lt.c ---- linux-3.1.4/arch/mips/mm/fault.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/mips/mm/fault.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/mips/mm/fault.c b/arch/mips/mm/fault.c +index 937cf33..adb39bb 100644 +--- a/arch/mips/mm/fault.c ++++ b/arch/mips/mm/fault.c @@ -28,6 +28,23 @@ #include /* For VMALLOC_END */ #include @@ -1208,10 +1614,11 @@ diff -urNp linux-3.1.4/arch/mips/mm/fault.c linux= -3.1.4/arch/mips/mm/fault.c /* * This routine handles page faults. It determines the address, * and the problem, and then passes it off to one of the appropriate -diff -urNp linux-3.1.4/arch/mips/mm/mmap.c linux-3.1.4/arch/mips/mm/mmap= .c ---- linux-3.1.4/arch/mips/mm/mmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/mips/mm/mmap.c 2011-11-16 18:39:07.000000000 -0500 -@@ -95,6 +95,11 @@ static unsigned long arch_get_unmapped_a +diff --git a/arch/mips/mm/mmap.c b/arch/mips/mm/mmap.c +index 302d779..7d35bf8 100644 +--- a/arch/mips/mm/mmap.c ++++ b/arch/mips/mm/mmap.c +@@ -95,6 +95,11 @@ static unsigned long arch_get_unmapped_area_common(st= ruct file *filp, do_color_align =3D 1; =20 /* requesting a specific address */ @@ -1223,7 +1630,7 @@ diff -urNp linux-3.1.4/arch/mips/mm/mmap.c linux-3.= 1.4/arch/mips/mm/mmap.c if (addr) { if (do_color_align) addr =3D COLOUR_ALIGN(addr, pgoff); -@@ -102,8 +107,7 @@ static unsigned long arch_get_unmapped_a +@@ -102,8 +107,7 @@ static unsigned long arch_get_unmapped_area_common(s= truct file *filp, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -1233,7 +1640,7 @@ diff -urNp linux-3.1.4/arch/mips/mm/mmap.c linux-3.= 1.4/arch/mips/mm/mmap.c return addr; } =20 -@@ -118,7 +122,7 @@ static unsigned long arch_get_unmapped_a +@@ -118,7 +122,7 @@ static unsigned long arch_get_unmapped_area_common(s= truct file *filp, /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1242,7 +1649,7 @@ diff -urNp linux-3.1.4/arch/mips/mm/mmap.c linux-3.= 1.4/arch/mips/mm/mmap.c return addr; addr =3D vma->vm_end; if (do_color_align) -@@ -145,7 +149,7 @@ static unsigned long arch_get_unmapped_a +@@ -145,7 +149,7 @@ static unsigned long arch_get_unmapped_area_common(s= truct file *filp, /* make sure it can fit in the remaining address space */ if (likely(addr > len)) { vma =3D find_vma(mm, addr - len); @@ -1251,7 +1658,7 @@ diff -urNp linux-3.1.4/arch/mips/mm/mmap.c linux-3.= 1.4/arch/mips/mm/mmap.c /* cache the address as a hint for next time */ return mm->free_area_cache =3D addr - len; } -@@ -165,7 +169,7 @@ static unsigned long arch_get_unmapped_a +@@ -165,7 +169,7 @@ static unsigned long arch_get_unmapped_area_common(s= truct file *filp, * return with success: */ vma =3D find_vma(mm, addr); @@ -1260,7 +1667,7 @@ diff -urNp linux-3.1.4/arch/mips/mm/mmap.c linux-3.= 1.4/arch/mips/mm/mmap.c /* cache the address as a hint for next time */ return mm->free_area_cache =3D addr; } -@@ -242,30 +246,3 @@ void arch_pick_mmap_layout(struct mm_str +@@ -242,30 +246,3 @@ void arch_pick_mmap_layout(struct mm_struct *mm) mm->unmap_area =3D arch_unmap_area_topdown; } } @@ -1291,10 +1698,11 @@ diff -urNp linux-3.1.4/arch/mips/mm/mmap.c linux-= 3.1.4/arch/mips/mm/mmap.c - - return ret; -} -diff -urNp linux-3.1.4/arch/parisc/include/asm/elf.h linux-3.1.4/arch/pa= risc/include/asm/elf.h ---- linux-3.1.4/arch/parisc/include/asm/elf.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/parisc/include/asm/elf.h 2011-11-16 18:39:07.000000= 000 -0500 -@@ -342,6 +342,13 @@ struct pt_regs; /* forward declaration.. +diff --git a/arch/parisc/include/asm/elf.h b/arch/parisc/include/asm/elf= .h +index 19f6cb1..6c78cf2 100644 +--- a/arch/parisc/include/asm/elf.h ++++ b/arch/parisc/include/asm/elf.h +@@ -342,6 +342,13 @@ struct pt_regs; /* forward declaration... */ =20 #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x01000000) =20 @@ -1308,9 +1716,10 @@ diff -urNp linux-3.1.4/arch/parisc/include/asm/elf= .h linux-3.1.4/arch/parisc/inc /* This yields a mask that user programs can use to figure out what instruction set this CPU supports. This could be done in user space= , but it's not easy, and we've already done it here. */ -diff -urNp linux-3.1.4/arch/parisc/include/asm/pgtable.h linux-3.1.4/arc= h/parisc/include/asm/pgtable.h ---- linux-3.1.4/arch/parisc/include/asm/pgtable.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/parisc/include/asm/pgtable.h 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/arch/parisc/include/asm/pgtable.h b/arch/parisc/include/asm= /pgtable.h +index 22dadeb..f6c2be4 100644 +--- a/arch/parisc/include/asm/pgtable.h ++++ b/arch/parisc/include/asm/pgtable.h @@ -210,6 +210,17 @@ struct vm_area_struct; #define PAGE_EXECREAD __pgprot(_PAGE_PRESENT | _PAGE_USER | _PAGE_REA= D | _PAGE_EXEC |_PAGE_ACCESSED) #define PAGE_COPY PAGE_EXECREAD @@ -1329,9 +1738,10 @@ diff -urNp linux-3.1.4/arch/parisc/include/asm/pgt= able.h linux-3.1.4/arch/parisc #define PAGE_KERNEL __pgprot(_PAGE_KERNEL) #define PAGE_KERNEL_EXEC __pgprot(_PAGE_KERNEL_EXEC) #define PAGE_KERNEL_RWX __pgprot(_PAGE_KERNEL_RWX) -diff -urNp linux-3.1.4/arch/parisc/kernel/module.c linux-3.1.4/arch/pari= sc/kernel/module.c ---- linux-3.1.4/arch/parisc/kernel/module.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/parisc/kernel/module.c 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/parisc/kernel/module.c b/arch/parisc/kernel/module.c +index 5e34ccf..672bc9c 100644 +--- a/arch/parisc/kernel/module.c ++++ b/arch/parisc/kernel/module.c @@ -98,16 +98,38 @@ =20 /* three functions to determine where in the module core @@ -1375,28 +1785,27 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/module.= c linux-3.1.4/arch/parisc/kerne } =20 static inline int in_local(struct module *me, void *loc) -@@ -373,13 +395,13 @@ int module_frob_arch_sections(CONST Elf_ +@@ -373,13 +395,13 @@ int module_frob_arch_sections(CONST Elf_Ehdr *hdr, } =20 /* align things a bit */ - me->core_size =3D ALIGN(me->core_size, 16); - me->arch.got_offset =3D me->core_size; - me->core_size +=3D gots * sizeof(struct got_entry); -- -- me->core_size =3D ALIGN(me->core_size, 16); -- me->arch.fdesc_offset =3D me->core_size; -- me->core_size +=3D fdescs * sizeof(Elf_Fdesc); + me->core_size_rw =3D ALIGN(me->core_size_rw, 16); + me->arch.got_offset =3D me->core_size_rw; + me->core_size_rw +=3D gots * sizeof(struct got_entry); -+ +=20 +- me->core_size =3D ALIGN(me->core_size, 16); +- me->arch.fdesc_offset =3D me->core_size; +- me->core_size +=3D fdescs * sizeof(Elf_Fdesc); + me->core_size_rw =3D ALIGN(me->core_size_rw, 16); + me->arch.fdesc_offset =3D me->core_size_rw; + me->core_size_rw +=3D fdescs * sizeof(Elf_Fdesc); =20 me->arch.got_max =3D gots; me->arch.fdesc_max =3D fdescs; -@@ -397,7 +419,7 @@ static Elf64_Word get_got(struct module=20 +@@ -397,7 +419,7 @@ static Elf64_Word get_got(struct module *me, unsigne= d long value, long addend) =20 BUG_ON(value =3D=3D 0); =20 @@ -1405,7 +1814,7 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/module.c = linux-3.1.4/arch/parisc/kerne for (i =3D 0; got[i].addr; i++) if (got[i].addr =3D=3D value) goto out; -@@ -415,7 +437,7 @@ static Elf64_Word get_got(struct module=20 +@@ -415,7 +437,7 @@ static Elf64_Word get_got(struct module *me, unsigne= d long value, long addend) #ifdef CONFIG_64BIT static Elf_Addr get_fdesc(struct module *me, unsigned long value) { @@ -1414,7 +1823,7 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/module.c = linux-3.1.4/arch/parisc/kerne =20 if (!value) { printk(KERN_ERR "%s: zero OPD requested!\n", me->name); -@@ -433,7 +455,7 @@ static Elf_Addr get_fdesc(struct module=20 +@@ -433,7 +455,7 @@ static Elf_Addr get_fdesc(struct module *me, unsigne= d long value) =20 /* Create new one */ fdesc->addr =3D value; @@ -1432,10 +1841,11 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/module.= c linux-3.1.4/arch/parisc/kerne =20 DEBUGP("register_unwind_table(), sect =3D %d at 0x%p - 0x%p (gp=3D0x%l= x)\n", me->arch.unwind_section, table, end, gp); -diff -urNp linux-3.1.4/arch/parisc/kernel/sys_parisc.c linux-3.1.4/arch/= parisc/kernel/sys_parisc.c ---- linux-3.1.4/arch/parisc/kernel/sys_parisc.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/parisc/kernel/sys_parisc.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -43,7 +43,7 @@ static unsigned long get_unshared_area(u +diff --git a/arch/parisc/kernel/sys_parisc.c b/arch/parisc/kernel/sys_pa= risc.c +index c9b9322..02d8940 100644 +--- a/arch/parisc/kernel/sys_parisc.c ++++ b/arch/parisc/kernel/sys_parisc.c +@@ -43,7 +43,7 @@ static unsigned long get_unshared_area(unsigned long a= ddr, unsigned long len) /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1444,7 +1854,7 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/sys_paris= c.c linux-3.1.4/arch/parisc/k return addr; addr =3D vma->vm_end; } -@@ -79,7 +79,7 @@ static unsigned long get_shared_area(str +@@ -79,7 +79,7 @@ static unsigned long get_shared_area(struct address_sp= ace *mapping, /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1453,7 +1863,7 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/sys_paris= c.c linux-3.1.4/arch/parisc/k return addr; addr =3D DCACHE_ALIGN(vma->vm_end - offset) + offset; if (addr < vma->vm_end) /* handle wraparound */ -@@ -98,7 +98,7 @@ unsigned long arch_get_unmapped_area(str +@@ -98,7 +98,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, if (flags & MAP_FIXED) return addr; if (!addr) @@ -1462,10 +1872,11 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/sys_par= isc.c linux-3.1.4/arch/parisc/k =20 if (filp) { addr =3D get_shared_area(filp->f_mapping, addr, len, pgoff); -diff -urNp linux-3.1.4/arch/parisc/kernel/traps.c linux-3.1.4/arch/paris= c/kernel/traps.c ---- linux-3.1.4/arch/parisc/kernel/traps.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/parisc/kernel/traps.c 2011-11-16 18:39:07.000000000= -0500 -@@ -733,9 +733,7 @@ void notrace handle_interruption(int cod +diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c +index f19e660..414fe24 100644 +--- a/arch/parisc/kernel/traps.c ++++ b/arch/parisc/kernel/traps.c +@@ -733,9 +733,7 @@ void notrace handle_interruption(int code, struct pt= _regs *regs) =20 down_read(¤t->mm->mmap_sem); vma =3D find_vma(current->mm,regs->iaoq[0]); @@ -1476,9 +1887,10 @@ diff -urNp linux-3.1.4/arch/parisc/kernel/traps.c = linux-3.1.4/arch/parisc/kernel fault_address =3D regs->iaoq[0]; fault_space =3D regs->iasq[0]; =20 -diff -urNp linux-3.1.4/arch/parisc/mm/fault.c linux-3.1.4/arch/parisc/mm= /fault.c ---- linux-3.1.4/arch/parisc/mm/fault.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/parisc/mm/fault.c 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/parisc/mm/fault.c b/arch/parisc/mm/fault.c +index 18162ce..94de376 100644 +--- a/arch/parisc/mm/fault.c ++++ b/arch/parisc/mm/fault.c @@ -15,6 +15,7 @@ #include #include @@ -1487,7 +1899,7 @@ diff -urNp linux-3.1.4/arch/parisc/mm/fault.c linux= -3.1.4/arch/parisc/mm/fault.c =20 #include #include -@@ -52,7 +53,7 @@ DEFINE_PER_CPU(struct exception_data, ex +@@ -52,7 +53,7 @@ DEFINE_PER_CPU(struct exception_data, exception_data); static unsigned long parisc_acctyp(unsigned long code, unsigned int inst) { @@ -1496,7 +1908,7 @@ diff -urNp linux-3.1.4/arch/parisc/mm/fault.c linux= -3.1.4/arch/parisc/mm/fault.c return VM_EXEC; =20 switch (inst & 0xf0000000) { -@@ -138,6 +139,116 @@ parisc_acctyp(unsigned long code, unsign +@@ -138,6 +139,116 @@ parisc_acctyp(unsigned long code, unsigned int ins= t) } #endif =20 @@ -1648,10 +2060,11 @@ diff -urNp linux-3.1.4/arch/parisc/mm/fault.c lin= ux-3.1.4/arch/parisc/mm/fault.c =20 /* * If for any reason at all we couldn't handle the fault, make -diff -urNp linux-3.1.4/arch/powerpc/include/asm/elf.h linux-3.1.4/arch/p= owerpc/include/asm/elf.h ---- linux-3.1.4/arch/powerpc/include/asm/elf.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/elf.h 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -178,8 +178,19 @@ typedef elf_fpreg_t elf_vsrreghalf_t32[E +diff --git a/arch/powerpc/include/asm/elf.h b/arch/powerpc/include/asm/e= lf.h +index 3bf9cca..e7457d0 100644 +--- a/arch/powerpc/include/asm/elf.h ++++ b/arch/powerpc/include/asm/elf.h +@@ -178,8 +178,19 @@ typedef elf_fpreg_t elf_vsrreghalf_t32[ELF_NVSRHALF= REG]; the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ =20 @@ -1673,7 +2086,7 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/elf= .h linux-3.1.4/arch/powerpc/i =20 /* * Our registers are always unsigned longs, whether we're a 32 bit -@@ -274,9 +285,6 @@ extern int arch_setup_additional_pages(s +@@ -274,9 +285,6 @@ extern int arch_setup_additional_pages(struct linux_= binprm *bprm, (0x7ff >> (PAGE_SHIFT - 12)) : \ (0x3ffff >> (PAGE_SHIFT - 12))) =20 @@ -1683,9 +2096,10 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/el= f.h linux-3.1.4/arch/powerpc/i #endif /* __KERNEL__ */ =20 /* -diff -urNp linux-3.1.4/arch/powerpc/include/asm/kmap_types.h linux-3.1.4= /arch/powerpc/include/asm/kmap_types.h ---- linux-3.1.4/arch/powerpc/include/asm/kmap_types.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/kmap_types.h 2011-11-16 18:39:0= 7.000000000 -0500 +diff --git a/arch/powerpc/include/asm/kmap_types.h b/arch/powerpc/includ= e/asm/kmap_types.h +index bca8fdc..61e9580 100644 +--- a/arch/powerpc/include/asm/kmap_types.h ++++ b/arch/powerpc/include/asm/kmap_types.h @@ -27,6 +27,7 @@ enum km_type { KM_PPC_SYNC_PAGE, KM_PPC_SYNC_ICACHE, @@ -1694,10 +2108,11 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/k= map_types.h linux-3.1.4/arch/po KM_TYPE_NR }; =20 -diff -urNp linux-3.1.4/arch/powerpc/include/asm/mman.h linux-3.1.4/arch/= powerpc/include/asm/mman.h ---- linux-3.1.4/arch/powerpc/include/asm/mman.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/mman.h 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -44,7 +44,7 @@ static inline unsigned long arch_calc_vm +diff --git a/arch/powerpc/include/asm/mman.h b/arch/powerpc/include/asm/= mman.h +index d4a7f64..451de1c 100644 +--- a/arch/powerpc/include/asm/mman.h ++++ b/arch/powerpc/include/asm/mman.h +@@ -44,7 +44,7 @@ static inline unsigned long arch_calc_vm_prot_bits(uns= igned long prot) } #define arch_calc_vm_prot_bits(prot) arch_calc_vm_prot_bits(prot) =20 @@ -1706,33 +2121,10 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/m= man.h linux-3.1.4/arch/powerpc/ { return (vm_flags & VM_SAO) ? __pgprot(_PAGE_SAO) : __pgprot(0); } -diff -urNp linux-3.1.4/arch/powerpc/include/asm/page_64.h linux-3.1.4/ar= ch/powerpc/include/asm/page_64.h ---- linux-3.1.4/arch/powerpc/include/asm/page_64.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/page_64.h 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -155,15 +155,18 @@ do { \ - * stack by default, so in the absence of a PT_GNU_STACK program header - * we turn execute permission off. - */ --#define VM_STACK_DEFAULT_FLAGS32 (VM_READ | VM_WRITE | VM_EXEC | \ -- VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) -+#define VM_STACK_DEFAULT_FLAGS32 \ -+ (((current->personality & READ_IMPLIES_EXEC) ? VM_EXEC : 0) | \ -+ VM_READ | VM_WRITE | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) -=20 - #define VM_STACK_DEFAULT_FLAGS64 (VM_READ | VM_WRITE | \ - VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) -=20 -+#ifndef CONFIG_PAX_PAGEEXEC - #define VM_STACK_DEFAULT_FLAGS \ - (is_32bit_task() ? \ - VM_STACK_DEFAULT_FLAGS32 : VM_STACK_DEFAULT_FLAGS64) -+#endif -=20 - #include -=20 -diff -urNp linux-3.1.4/arch/powerpc/include/asm/page.h linux-3.1.4/arch/= powerpc/include/asm/page.h ---- linux-3.1.4/arch/powerpc/include/asm/page.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/page.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/powerpc/include/asm/page.h b/arch/powerpc/include/asm/= page.h +index 2cd664e..1d2e8a7 100644 +--- a/arch/powerpc/include/asm/page.h ++++ b/arch/powerpc/include/asm/page.h @@ -129,8 +129,9 @@ extern phys_addr_t kernstart_addr; * and needs to be executable. This means the whole heap ends * up being executable. @@ -1755,9 +2147,35 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/pa= ge.h linux-3.1.4/arch/powerpc/ #ifndef __ASSEMBLY__ =20 #undef STRICT_MM_TYPECHECKS -diff -urNp linux-3.1.4/arch/powerpc/include/asm/pgtable.h linux-3.1.4/ar= ch/powerpc/include/asm/pgtable.h ---- linux-3.1.4/arch/powerpc/include/asm/pgtable.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/pgtable.h 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/powerpc/include/asm/page_64.h b/arch/powerpc/include/a= sm/page_64.h +index 9356262..ea96148 100644 +--- a/arch/powerpc/include/asm/page_64.h ++++ b/arch/powerpc/include/asm/page_64.h +@@ -155,15 +155,18 @@ do { \ + * stack by default, so in the absence of a PT_GNU_STACK program header + * we turn execute permission off. + */ +-#define VM_STACK_DEFAULT_FLAGS32 (VM_READ | VM_WRITE | VM_EXEC | \ +- VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) ++#define VM_STACK_DEFAULT_FLAGS32 \ ++ (((current->personality & READ_IMPLIES_EXEC) ? VM_EXEC : 0) | \ ++ VM_READ | VM_WRITE | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) +=20 + #define VM_STACK_DEFAULT_FLAGS64 (VM_READ | VM_WRITE | \ + VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) +=20 ++#ifndef CONFIG_PAX_PAGEEXEC + #define VM_STACK_DEFAULT_FLAGS \ + (is_32bit_task() ? \ + VM_STACK_DEFAULT_FLAGS32 : VM_STACK_DEFAULT_FLAGS64) ++#endif +=20 + #include +=20 +diff --git a/arch/powerpc/include/asm/pgtable.h b/arch/powerpc/include/a= sm/pgtable.h +index 88b0bd9..e32bc67 100644 +--- a/arch/powerpc/include/asm/pgtable.h ++++ b/arch/powerpc/include/asm/pgtable.h @@ -2,6 +2,7 @@ #define _ASM_POWERPC_PGTABLE_H #ifdef __KERNEL__ @@ -1766,9 +2184,10 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/pg= table.h linux-3.1.4/arch/power #ifndef __ASSEMBLY__ #include /* For TASK_SIZE */ #include -diff -urNp linux-3.1.4/arch/powerpc/include/asm/pte-hash32.h linux-3.1.4= /arch/powerpc/include/asm/pte-hash32.h ---- linux-3.1.4/arch/powerpc/include/asm/pte-hash32.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/pte-hash32.h 2011-11-16 18:39:0= 7.000000000 -0500 +diff --git a/arch/powerpc/include/asm/pte-hash32.h b/arch/powerpc/includ= e/asm/pte-hash32.h +index 4aad413..85d86bf 100644 +--- a/arch/powerpc/include/asm/pte-hash32.h ++++ b/arch/powerpc/include/asm/pte-hash32.h @@ -21,6 +21,7 @@ #define _PAGE_FILE 0x004 /* when !present: nonlinear file mapping */ #define _PAGE_USER 0x004 /* usermode access allowed */ @@ -1777,9 +2196,10 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/pt= e-hash32.h linux-3.1.4/arch/po #define _PAGE_COHERENT 0x010 /* M: enforce memory coherence (SMP system= s) */ #define _PAGE_NO_CACHE 0x020 /* I: cache inhibit */ #define _PAGE_WRITETHRU 0x040 /* W: cache write-through */ -diff -urNp linux-3.1.4/arch/powerpc/include/asm/reg.h linux-3.1.4/arch/p= owerpc/include/asm/reg.h ---- linux-3.1.4/arch/powerpc/include/asm/reg.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/reg.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/r= eg.h +index 559da19..7e5835c 100644 +--- a/arch/powerpc/include/asm/reg.h ++++ b/arch/powerpc/include/asm/reg.h @@ -212,6 +212,7 @@ #define SPRN_DBCR 0x136 /* e300 Data Breakpoint Control Reg */ #define SPRN_DSISR 0x012 /* Data Storage Interrupt Status Register */ @@ -1788,10 +2208,11 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/r= eg.h linux-3.1.4/arch/powerpc/i #define DSISR_PROTFAULT 0x08000000 /* protection fault */ #define DSISR_ISSTORE 0x02000000 /* access was a store */ #define DSISR_DABRMATCH 0x00400000 /* hit data breakpoint */ -diff -urNp linux-3.1.4/arch/powerpc/include/asm/system.h linux-3.1.4/arc= h/powerpc/include/asm/system.h ---- linux-3.1.4/arch/powerpc/include/asm/system.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/system.h 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -530,7 +530,7 @@ __cmpxchg_local(volatile void *ptr, unsi +diff --git a/arch/powerpc/include/asm/system.h b/arch/powerpc/include/as= m/system.h +index e30a13d..2b7d994 100644 +--- a/arch/powerpc/include/asm/system.h ++++ b/arch/powerpc/include/asm/system.h +@@ -530,7 +530,7 @@ __cmpxchg_local(volatile void *ptr, unsigned long ol= d, unsigned long new, #define cmpxchg64_local(ptr, o, n) __cmpxchg64_local_generic((ptr), (o)= , (n)) #endif =20 @@ -1800,9 +2221,10 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/sy= stem.h linux-3.1.4/arch/powerp =20 /* Used in very early kernel initialization. */ extern unsigned long reloc_offset(void); -diff -urNp linux-3.1.4/arch/powerpc/include/asm/uaccess.h linux-3.1.4/ar= ch/powerpc/include/asm/uaccess.h ---- linux-3.1.4/arch/powerpc/include/asm/uaccess.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/powerpc/include/asm/uaccess.h 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/powerpc/include/asm/uaccess.h b/arch/powerpc/include/a= sm/uaccess.h +index bd0fb84..a42a14b 100644 +--- a/arch/powerpc/include/asm/uaccess.h ++++ b/arch/powerpc/include/asm/uaccess.h @@ -13,6 +13,8 @@ #define VERIFY_READ 0 #define VERIFY_WRITE 1 @@ -1865,7 +2287,7 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/uac= cess.h linux-3.1.4/arch/power static inline unsigned long __copy_from_user_inatomic(void *to, const void __user *from, unsigned long n) { -@@ -396,6 +352,10 @@ static inline unsigned long __copy_from_ +@@ -396,6 +352,10 @@ static inline unsigned long __copy_from_user_inatom= ic(void *to, if (ret =3D=3D 0) return 0; } @@ -1876,7 +2298,7 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/uac= cess.h linux-3.1.4/arch/power return __copy_tofrom_user((__force void __user *)to, from, n); } =20 -@@ -422,6 +382,10 @@ static inline unsigned long __copy_to_us +@@ -422,6 +382,10 @@ static inline unsigned long __copy_to_user_inatomic= (void __user *to, if (ret =3D=3D 0) return 0; } @@ -1887,7 +2309,7 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/uac= cess.h linux-3.1.4/arch/power return __copy_tofrom_user(to, (__force const void __user *)from, n); } =20 -@@ -439,6 +403,92 @@ static inline unsigned long __copy_to_us +@@ -439,6 +403,92 @@ static inline unsigned long __copy_to_user(void __u= ser *to, return __copy_to_user_inatomic(to, from, size); } =20 @@ -1980,9 +2402,10 @@ diff -urNp linux-3.1.4/arch/powerpc/include/asm/ua= ccess.h linux-3.1.4/arch/power extern unsigned long __clear_user(void __user *addr, unsigned long size= ); =20 static inline unsigned long clear_user(void __user *addr, unsigned long= size) -diff -urNp linux-3.1.4/arch/powerpc/kernel/exceptions-64e.S linux-3.1.4/= arch/powerpc/kernel/exceptions-64e.S ---- linux-3.1.4/arch/powerpc/kernel/exceptions-64e.S 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/powerpc/kernel/exceptions-64e.S 2011-11-16 18:39:07= .000000000 -0500 +diff --git a/arch/powerpc/kernel/exceptions-64e.S b/arch/powerpc/kernel/= exceptions-64e.S +index 429983c..7af363b 100644 +--- a/arch/powerpc/kernel/exceptions-64e.S ++++ b/arch/powerpc/kernel/exceptions-64e.S @@ -587,6 +587,7 @@ storage_fault_common: std r14,_DAR(r1) std r15,_DSISR(r1) @@ -2001,9 +2424,10 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/excepti= ons-64e.S linux-3.1.4/arch/pow addi r3,r1,STACK_FRAME_OVERHEAD ld r4,_DAR(r1) bl .bad_page_fault -diff -urNp linux-3.1.4/arch/powerpc/kernel/exceptions-64s.S linux-3.1.4/= arch/powerpc/kernel/exceptions-64s.S ---- linux-3.1.4/arch/powerpc/kernel/exceptions-64s.S 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/powerpc/kernel/exceptions-64s.S 2011-11-16 18:39:07= .000000000 -0500 +diff --git a/arch/powerpc/kernel/exceptions-64s.S b/arch/powerpc/kernel/= exceptions-64s.S +index 41b02c7..05e76fb 100644 +--- a/arch/powerpc/kernel/exceptions-64s.S ++++ b/arch/powerpc/kernel/exceptions-64s.S @@ -1014,10 +1014,10 @@ handle_page_fault: 11: ld r4,_DAR(r1) ld r5,_DSISR(r1) @@ -2016,10 +2440,11 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/except= ions-64s.S linux-3.1.4/arch/pow mr r5,r3 addi r3,r1,STACK_FRAME_OVERHEAD lwz r4,_DAR(r1) -diff -urNp linux-3.1.4/arch/powerpc/kernel/module_32.c linux-3.1.4/arch/= powerpc/kernel/module_32.c ---- linux-3.1.4/arch/powerpc/kernel/module_32.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/powerpc/kernel/module_32.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -162,7 +162,7 @@ int module_frob_arch_sections(Elf32_Ehdr +diff --git a/arch/powerpc/kernel/module_32.c b/arch/powerpc/kernel/modul= e_32.c +index 0b6d796..d760ddb 100644 +--- a/arch/powerpc/kernel/module_32.c ++++ b/arch/powerpc/kernel/module_32.c +@@ -162,7 +162,7 @@ int module_frob_arch_sections(Elf32_Ehdr *hdr, me->arch.core_plt_section =3D i; } if (!me->arch.core_plt_section || !me->arch.init_plt_section) { @@ -2028,7 +2453,7 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/module_3= 2.c linux-3.1.4/arch/powerpc/ return -ENOEXEC; } =20 -@@ -192,11 +192,16 @@ static uint32_t do_plt_call(void *locati +@@ -192,11 +192,16 @@ static uint32_t do_plt_call(void *location, =20 DEBUGP("Doing plt for call to 0x%x at 0x%x\n", val, (unsigned int)loca= tion); /* Init, or core PLT? */ @@ -2048,9 +2473,10 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/module_= 32.c linux-3.1.4/arch/powerpc/ =20 /* Find this entry, or if that fails, the next avail. entry */ while (entry->jump[0]) { -diff -urNp linux-3.1.4/arch/powerpc/kernel/process.c linux-3.1.4/arch/po= werpc/kernel/process.c ---- linux-3.1.4/arch/powerpc/kernel/process.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/powerpc/kernel/process.c 2011-11-16 18:40:08.000000= 000 -0500 +diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process= .c +index 8f53954..a704ad6 100644 +--- a/arch/powerpc/kernel/process.c ++++ b/arch/powerpc/kernel/process.c @@ -682,8 +682,8 @@ void show_regs(struct pt_regs * regs) * Lookup NIP late so we have the best change of getting the * above info out without failing @@ -2062,7 +2488,7 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/process.= c linux-3.1.4/arch/powerpc/ke #endif show_stack(current, (unsigned long *) regs->gpr[1]); if (!user_mode(regs)) -@@ -1187,10 +1187,10 @@ void show_stack(struct task_struct *tsk, +@@ -1187,10 +1187,10 @@ void show_stack(struct task_struct *tsk, unsigne= d long *stack) newsp =3D stack[0]; ip =3D stack[STACK_FRAME_LR_SAVE]; if (!firstframe || ip !=3D lr) { @@ -2075,7 +2501,7 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/process.= c linux-3.1.4/arch/powerpc/ke (void *)current->ret_stack[curr_frame].ret); curr_frame--; } -@@ -1210,7 +1210,7 @@ void show_stack(struct task_struct *tsk, +@@ -1210,7 +1210,7 @@ void show_stack(struct task_struct *tsk, unsigned = long *stack) struct pt_regs *regs =3D (struct pt_regs *) (sp + STACK_FRAME_OVERHEAD); lr =3D regs->link; @@ -2143,10 +2569,11 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/proces= s.c linux-3.1.4/arch/powerpc/ke - - return ret; -} -diff -urNp linux-3.1.4/arch/powerpc/kernel/signal_32.c linux-3.1.4/arch/= powerpc/kernel/signal_32.c ---- linux-3.1.4/arch/powerpc/kernel/signal_32.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/powerpc/kernel/signal_32.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -859,7 +859,7 @@ int handle_rt_signal32(unsigned long sig +diff --git a/arch/powerpc/kernel/signal_32.c b/arch/powerpc/kernel/signa= l_32.c +index 78b76dc..7f232ef 100644 +--- a/arch/powerpc/kernel/signal_32.c ++++ b/arch/powerpc/kernel/signal_32.c +@@ -859,7 +859,7 @@ int handle_rt_signal32(unsigned long sig, struct k_s= igaction *ka, /* Save user registers on the stack */ frame =3D &rt_sf->uc.uc_mcontext; addr =3D frame; @@ -2155,10 +2582,11 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/signal= _32.c linux-3.1.4/arch/powerpc/ if (save_user_regs(regs, frame, 0, 1)) goto badframe; regs->link =3D current->mm->context.vdso_base + vdso32_rt_sigtramp; -diff -urNp linux-3.1.4/arch/powerpc/kernel/signal_64.c linux-3.1.4/arch/= powerpc/kernel/signal_64.c ---- linux-3.1.4/arch/powerpc/kernel/signal_64.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/powerpc/kernel/signal_64.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -430,7 +430,7 @@ int handle_rt_signal64(int signr, struct +diff --git a/arch/powerpc/kernel/signal_64.c b/arch/powerpc/kernel/signa= l_64.c +index e91c736..742ec06 100644 +--- a/arch/powerpc/kernel/signal_64.c ++++ b/arch/powerpc/kernel/signal_64.c +@@ -430,7 +430,7 @@ int handle_rt_signal64(int signr, struct k_sigaction= *ka, siginfo_t *info, current->thread.fpscr.val =3D 0; =20 /* Set up to return from userspace. */ @@ -2167,9 +2595,10 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/signal_= 64.c linux-3.1.4/arch/powerpc/ regs->link =3D current->mm->context.vdso_base + vdso64_rt_sigtramp; } else { err |=3D setup_trampoline(__NR_rt_sigreturn, &frame->tramp[0]); -diff -urNp linux-3.1.4/arch/powerpc/kernel/traps.c linux-3.1.4/arch/powe= rpc/kernel/traps.c ---- linux-3.1.4/arch/powerpc/kernel/traps.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/powerpc/kernel/traps.c 2011-11-16 18:40:08.00000000= 0 -0500 +diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c +index f19d977..8ac286e 100644 +--- a/arch/powerpc/kernel/traps.c ++++ b/arch/powerpc/kernel/traps.c @@ -98,6 +98,8 @@ static void pmac_backlight_unblank(void) static inline void pmac_backlight_unblank(void) { } #endif @@ -2179,7 +2608,7 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/traps.c = linux-3.1.4/arch/powerpc/kern int die(const char *str, struct pt_regs *regs, long err) { static struct { -@@ -171,6 +173,8 @@ int die(const char *str, struct pt_regs=20 +@@ -171,6 +173,8 @@ int die(const char *str, struct pt_regs *regs, long = err) if (panic_on_oops) panic("Fatal exception"); =20 @@ -2188,9 +2617,10 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/traps.c= linux-3.1.4/arch/powerpc/kern oops_exit(); do_exit(err); =20 -diff -urNp linux-3.1.4/arch/powerpc/kernel/vdso.c linux-3.1.4/arch/power= pc/kernel/vdso.c ---- linux-3.1.4/arch/powerpc/kernel/vdso.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/powerpc/kernel/vdso.c 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c +index 142ab10..236e61a 100644 +--- a/arch/powerpc/kernel/vdso.c ++++ b/arch/powerpc/kernel/vdso.c @@ -36,6 +36,7 @@ #include #include @@ -2199,7 +2629,7 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/vdso.c l= inux-3.1.4/arch/powerpc/kerne =20 #include "setup.h" =20 -@@ -220,7 +221,7 @@ int arch_setup_additional_pages(struct l +@@ -220,7 +221,7 @@ int arch_setup_additional_pages(struct linux_binprm = *bprm, int uses_interp) vdso_base =3D VDSO32_MBASE; #endif =20 @@ -2208,7 +2638,7 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/vdso.c l= inux-3.1.4/arch/powerpc/kerne =20 /* vDSO has a problem and was disabled, just don't "enable" it for the * process -@@ -240,7 +241,7 @@ int arch_setup_additional_pages(struct l +@@ -240,7 +241,7 @@ int arch_setup_additional_pages(struct linux_binprm = *bprm, int uses_interp) vdso_base =3D get_unmapped_area(NULL, vdso_base, (vdso_pages << PAGE_SHIFT) + ((VDSO_ALIGNMENT - 1) & PAGE_MASK), @@ -2217,9 +2647,10 @@ diff -urNp linux-3.1.4/arch/powerpc/kernel/vdso.c = linux-3.1.4/arch/powerpc/kerne if (IS_ERR_VALUE(vdso_base)) { rc =3D vdso_base; goto fail_mmapsem; -diff -urNp linux-3.1.4/arch/powerpc/lib/usercopy_64.c linux-3.1.4/arch/p= owerpc/lib/usercopy_64.c ---- linux-3.1.4/arch/powerpc/lib/usercopy_64.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/powerpc/lib/usercopy_64.c 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/powerpc/lib/usercopy_64.c b/arch/powerpc/lib/usercopy_= 64.c +index 5eea6f3..5d10396 100644 +--- a/arch/powerpc/lib/usercopy_64.c ++++ b/arch/powerpc/lib/usercopy_64.c @@ -9,22 +9,6 @@ #include #include @@ -2243,7 +2674,7 @@ diff -urNp linux-3.1.4/arch/powerpc/lib/usercopy_64= .c linux-3.1.4/arch/powerpc/l unsigned long copy_in_user(void __user *to, const void __user *from, unsigned long n) { -@@ -35,7 +19,5 @@ unsigned long copy_in_user(void __user * +@@ -35,7 +19,5 @@ unsigned long copy_in_user(void __user *to, const void= __user *from, return n; } =20 @@ -2251,9 +2682,10 @@ diff -urNp linux-3.1.4/arch/powerpc/lib/usercopy_6= 4.c linux-3.1.4/arch/powerpc/l -EXPORT_SYMBOL(copy_to_user); EXPORT_SYMBOL(copy_in_user); =20 -diff -urNp linux-3.1.4/arch/powerpc/mm/fault.c linux-3.1.4/arch/powerpc/= mm/fault.c ---- linux-3.1.4/arch/powerpc/mm/fault.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/powerpc/mm/fault.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/powerpc/mm/fault.c b/arch/powerpc/mm/fault.c +index 5efe8c9..db9ceef 100644 +--- a/arch/powerpc/mm/fault.c ++++ b/arch/powerpc/mm/fault.c @@ -32,6 +32,10 @@ #include #include @@ -2273,7 +2705,7 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/fault.c linu= x-3.1.4/arch/powerpc/mm/fault =20 #ifdef CONFIG_KPROBES static inline int notify_page_fault(struct pt_regs *regs) -@@ -66,6 +71,33 @@ static inline int notify_page_fault(stru +@@ -66,6 +71,33 @@ static inline int notify_page_fault(struct pt_regs *r= egs) } #endif =20 @@ -2307,7 +2739,7 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/fault.c linu= x-3.1.4/arch/powerpc/mm/fault /* * Check whether the instruction at regs->nip is a store using * an update addressing form which will update r1. -@@ -136,7 +168,7 @@ int __kprobes do_page_fault(struct pt_re +@@ -136,7 +168,7 @@ int __kprobes do_page_fault(struct pt_regs *regs, un= signed long address, * indicate errors in DSISR but can validly be set in SRR1. */ if (trap =3D=3D 0x400) @@ -2358,10 +2790,11 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/fault.c li= nux-3.1.4/arch/powerpc/mm/fault _exception(SIGSEGV, regs, code, address); return 0; } -diff -urNp linux-3.1.4/arch/powerpc/mm/mmap_64.c linux-3.1.4/arch/powerp= c/mm/mmap_64.c ---- linux-3.1.4/arch/powerpc/mm/mmap_64.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/powerpc/mm/mmap_64.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -99,10 +99,22 @@ void arch_pick_mmap_layout(struct mm_str +diff --git a/arch/powerpc/mm/mmap_64.c b/arch/powerpc/mm/mmap_64.c +index 5a783d8..c23e14b 100644 +--- a/arch/powerpc/mm/mmap_64.c ++++ b/arch/powerpc/mm/mmap_64.c +@@ -99,10 +99,22 @@ void arch_pick_mmap_layout(struct mm_struct *mm) */ if (mmap_is_legacy()) { mm->mmap_base =3D TASK_UNMAPPED_BASE; @@ -2384,10 +2817,11 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/mmap_64.c = linux-3.1.4/arch/powerpc/mm/mma mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-3.1.4/arch/powerpc/mm/slice.c linux-3.1.4/arch/powerpc/= mm/slice.c ---- linux-3.1.4/arch/powerpc/mm/slice.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/powerpc/mm/slice.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -98,7 +98,7 @@ static int slice_area_is_free(struct mm_ +diff --git a/arch/powerpc/mm/slice.c b/arch/powerpc/mm/slice.c +index ba51948..23009d9 100644 +--- a/arch/powerpc/mm/slice.c ++++ b/arch/powerpc/mm/slice.c +@@ -98,7 +98,7 @@ static int slice_area_is_free(struct mm_struct *mm, un= signed long addr, if ((mm->task_size - len) < addr) return 0; vma =3D find_vma(mm, addr); @@ -2405,7 +2839,7 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/slice.c linu= x-3.1.4/arch/powerpc/mm/slice /* * Remember the place where we stopped the search: */ -@@ -313,10 +313,14 @@ static unsigned long slice_find_area_top +@@ -313,10 +313,14 @@ static unsigned long slice_find_area_topdown(struc= t mm_struct *mm, } } =20 @@ -2423,7 +2857,7 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/slice.c linu= x-3.1.4/arch/powerpc/mm/slice =20 /* Check for hit with different page size */ mask =3D slice_range_to_mask(addr, len); -@@ -336,7 +340,7 @@ static unsigned long slice_find_area_top +@@ -336,7 +340,7 @@ static unsigned long slice_find_area_topdown(struct = mm_struct *mm, * return with success: */ vma =3D find_vma(mm, addr); @@ -2432,7 +2866,7 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/slice.c linu= x-3.1.4/arch/powerpc/mm/slice /* remember the address as a hint for next time */ if (use_cache) mm->free_area_cache =3D addr; -@@ -348,7 +352,7 @@ static unsigned long slice_find_area_top +@@ -348,7 +352,7 @@ static unsigned long slice_find_area_topdown(struct = mm_struct *mm, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -2441,7 +2875,7 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/slice.c linu= x-3.1.4/arch/powerpc/mm/slice } =20 /* -@@ -426,6 +430,11 @@ unsigned long slice_get_unmapped_area(un +@@ -426,6 +430,11 @@ unsigned long slice_get_unmapped_area(unsigned long= addr, unsigned long len, if (fixed && addr > (mm->task_size - len)) return -EINVAL; =20 @@ -2453,9 +2887,10 @@ diff -urNp linux-3.1.4/arch/powerpc/mm/slice.c lin= ux-3.1.4/arch/powerpc/mm/slice /* If hint, make sure it matches our alignment restrictions */ if (!fixed && addr) { addr =3D _ALIGN_UP(addr, 1ul << pshift); -diff -urNp linux-3.1.4/arch/s390/include/asm/elf.h linux-3.1.4/arch/s390= /include/asm/elf.h ---- linux-3.1.4/arch/s390/include/asm/elf.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/s390/include/asm/elf.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/s390/include/asm/elf.h b/arch/s390/include/asm/elf.h +index 547f1a6..3fff354 100644 +--- a/arch/s390/include/asm/elf.h ++++ b/arch/s390/include/asm/elf.h @@ -162,8 +162,14 @@ extern unsigned int vdso_enabled; the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ @@ -2481,10 +2916,11 @@ diff -urNp linux-3.1.4/arch/s390/include/asm/elf.= h linux-3.1.4/arch/s390/include -#define arch_randomize_brk arch_randomize_brk - #endif -diff -urNp linux-3.1.4/arch/s390/include/asm/system.h linux-3.1.4/arch/s= 390/include/asm/system.h ---- linux-3.1.4/arch/s390/include/asm/system.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/s390/include/asm/system.h 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -256,7 +256,7 @@ extern void (*_machine_restart)(char *co +diff --git a/arch/s390/include/asm/system.h b/arch/s390/include/asm/syst= em.h +index 6582f69..b69906f 100644 +--- a/arch/s390/include/asm/system.h ++++ b/arch/s390/include/asm/system.h +@@ -256,7 +256,7 @@ extern void (*_machine_restart)(char *command); extern void (*_machine_halt)(void); extern void (*_machine_power_off)(void); =20 @@ -2493,9 +2929,10 @@ diff -urNp linux-3.1.4/arch/s390/include/asm/syste= m.h linux-3.1.4/arch/s390/incl =20 static inline int tprot(unsigned long addr) { -diff -urNp linux-3.1.4/arch/s390/include/asm/uaccess.h linux-3.1.4/arch/= s390/include/asm/uaccess.h ---- linux-3.1.4/arch/s390/include/asm/uaccess.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/s390/include/asm/uaccess.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/s390/include/asm/uaccess.h b/arch/s390/include/asm/uac= cess.h +index 2b23885..e136e31 100644 +--- a/arch/s390/include/asm/uaccess.h ++++ b/arch/s390/include/asm/uaccess.h @@ -235,6 +235,10 @@ static inline unsigned long __must_check copy_to_user(void __user *to, const void *from, unsigned long n) { @@ -2507,7 +2944,7 @@ diff -urNp linux-3.1.4/arch/s390/include/asm/uacces= s.h linux-3.1.4/arch/s390/inc if (access_ok(VERIFY_WRITE, to, n)) n =3D __copy_to_user(to, from, n); return n; -@@ -260,6 +264,9 @@ copy_to_user(void __user *to, const void +@@ -260,6 +264,9 @@ copy_to_user(void __user *to, const void *from, unsi= gned long n) static inline unsigned long __must_check __copy_from_user(void *to, const void __user *from, unsigned long n) { @@ -2517,7 +2954,7 @@ diff -urNp linux-3.1.4/arch/s390/include/asm/uacces= s.h linux-3.1.4/arch/s390/inc if (__builtin_constant_p(n) && (n <=3D 256)) return uaccess.copy_from_user_small(n, from, to); else -@@ -294,6 +301,10 @@ copy_from_user(void *to, const void __us +@@ -294,6 +301,10 @@ copy_from_user(void *to, const void __user *from, u= nsigned long n) unsigned int sz =3D __compiletime_object_size(to); =20 might_fault(); @@ -2528,10 +2965,11 @@ diff -urNp linux-3.1.4/arch/s390/include/asm/uacc= ess.h linux-3.1.4/arch/s390/inc if (unlikely(sz !=3D -1 && sz < n)) { copy_from_user_overflow(); return n; -diff -urNp linux-3.1.4/arch/s390/kernel/module.c linux-3.1.4/arch/s390/k= ernel/module.c ---- linux-3.1.4/arch/s390/kernel/module.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/s390/kernel/module.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -161,11 +161,11 @@ module_frob_arch_sections(Elf_Ehdr *hdr, +diff --git a/arch/s390/kernel/module.c b/arch/s390/kernel/module.c +index dfcb343..eda788a 100644 +--- a/arch/s390/kernel/module.c ++++ b/arch/s390/kernel/module.c +@@ -161,11 +161,11 @@ module_frob_arch_sections(Elf_Ehdr *hdr, Elf_Shdr = *sechdrs, =20 /* Increase core size by size of got & plt and set start offsets for got and plt. */ @@ -2548,7 +2986,7 @@ diff -urNp linux-3.1.4/arch/s390/kernel/module.c li= nux-3.1.4/arch/s390/kernel/mo return 0; } =20 -@@ -242,7 +242,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -242,7 +242,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, if (info->got_initialized =3D=3D 0) { Elf_Addr *gotent; =20 @@ -2557,7 +2995,7 @@ diff -urNp linux-3.1.4/arch/s390/kernel/module.c li= nux-3.1.4/arch/s390/kernel/mo info->got_offset; *gotent =3D val; info->got_initialized =3D 1; -@@ -266,7 +266,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -266,7 +266,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, else if (r_type =3D=3D R_390_GOTENT || r_type =3D=3D R_390_GOTPLTENT) *(unsigned int *) loc =3D @@ -2566,7 +3004,7 @@ diff -urNp linux-3.1.4/arch/s390/kernel/module.c li= nux-3.1.4/arch/s390/kernel/mo else if (r_type =3D=3D R_390_GOT64 || r_type =3D=3D R_390_GOTPLT64) *(unsigned long *) loc =3D val; -@@ -280,7 +280,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -280,7 +280,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, case R_390_PLTOFF64: /* 16 bit offset from GOT to PLT. */ if (info->plt_initialized =3D=3D 0) { unsigned int *ip; @@ -2575,7 +3013,7 @@ diff -urNp linux-3.1.4/arch/s390/kernel/module.c li= nux-3.1.4/arch/s390/kernel/mo info->plt_offset; #ifndef CONFIG_64BIT ip[0] =3D 0x0d105810; /* basr 1,0; l 1,6(1); br 1 */ -@@ -305,7 +305,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -305,7 +305,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, val - loc + 0xffffUL < 0x1ffffeUL) || (r_type =3D=3D R_390_PLT32DBL && val - loc + 0xffffffffULL < 0x1fffffffeULL))) @@ -2584,7 +3022,7 @@ diff -urNp linux-3.1.4/arch/s390/kernel/module.c li= nux-3.1.4/arch/s390/kernel/mo me->arch.plt_offset + info->plt_offset; val +=3D rela->r_addend - loc; -@@ -327,7 +327,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -327,7 +327,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, case R_390_GOTOFF32: /* 32 bit offset to GOT. */ case R_390_GOTOFF64: /* 64 bit offset to GOT. */ val =3D val + rela->r_addend - @@ -2593,7 +3031,7 @@ diff -urNp linux-3.1.4/arch/s390/kernel/module.c li= nux-3.1.4/arch/s390/kernel/mo if (r_type =3D=3D R_390_GOTOFF16) *(unsigned short *) loc =3D val; else if (r_type =3D=3D R_390_GOTOFF32) -@@ -337,7 +337,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -337,7 +337,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *s= ymtab, break; case R_390_GOTPC: /* 32 bit PC relative offset to GOT. */ case R_390_GOTPCDBL: /* 32 bit PC rel. off. to GOT shifted by 1. */ @@ -2602,10 +3040,11 @@ diff -urNp linux-3.1.4/arch/s390/kernel/module.c = linux-3.1.4/arch/s390/kernel/mo rela->r_addend - loc; if (r_type =3D=3D R_390_GOTPC) *(unsigned int *) loc =3D val; -diff -urNp linux-3.1.4/arch/s390/kernel/process.c linux-3.1.4/arch/s390/= kernel/process.c ---- linux-3.1.4/arch/s390/kernel/process.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/s390/kernel/process.c 2011-11-16 18:39:07.000000000= -0500 -@@ -319,39 +319,3 @@ unsigned long get_wchan(struct task_stru +diff --git a/arch/s390/kernel/process.c b/arch/s390/kernel/process.c +index 541a750..8739853 100644 +--- a/arch/s390/kernel/process.c ++++ b/arch/s390/kernel/process.c +@@ -319,39 +319,3 @@ unsigned long get_wchan(struct task_struct *p) } return 0; } @@ -2645,10 +3084,11 @@ diff -urNp linux-3.1.4/arch/s390/kernel/process.c= linux-3.1.4/arch/s390/kernel/p - return base; - return ret; -} -diff -urNp linux-3.1.4/arch/s390/kernel/setup.c linux-3.1.4/arch/s390/ke= rnel/setup.c ---- linux-3.1.4/arch/s390/kernel/setup.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/s390/kernel/setup.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -271,7 +271,7 @@ static int __init early_parse_mem(char * +diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c +index 7b371c3..ad06cf1 100644 +--- a/arch/s390/kernel/setup.c ++++ b/arch/s390/kernel/setup.c +@@ -271,7 +271,7 @@ static int __init early_parse_mem(char *p) } early_param("mem", early_parse_mem); =20 @@ -2657,10 +3097,11 @@ diff -urNp linux-3.1.4/arch/s390/kernel/setup.c l= inux-3.1.4/arch/s390/kernel/set EXPORT_SYMBOL_GPL(user_mode); =20 static int set_amode_and_uaccess(unsigned long user_amode, -diff -urNp linux-3.1.4/arch/s390/mm/mmap.c linux-3.1.4/arch/s390/mm/mmap= .c ---- linux-3.1.4/arch/s390/mm/mmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/s390/mm/mmap.c 2011-11-16 18:39:07.000000000 -0500 -@@ -91,10 +91,22 @@ void arch_pick_mmap_layout(struct mm_str +diff --git a/arch/s390/mm/mmap.c b/arch/s390/mm/mmap.c +index c9a9f7f..60d0315 100644 +--- a/arch/s390/mm/mmap.c ++++ b/arch/s390/mm/mmap.c +@@ -91,10 +91,22 @@ void arch_pick_mmap_layout(struct mm_struct *mm) */ if (mmap_is_legacy()) { mm->mmap_base =3D TASK_UNMAPPED_BASE; @@ -2683,7 +3124,7 @@ diff -urNp linux-3.1.4/arch/s390/mm/mmap.c linux-3.= 1.4/arch/s390/mm/mmap.c mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -@@ -166,10 +178,22 @@ void arch_pick_mmap_layout(struct mm_str +@@ -166,10 +178,22 @@ void arch_pick_mmap_layout(struct mm_struct *mm) */ if (mmap_is_legacy()) { mm->mmap_base =3D TASK_UNMAPPED_BASE; @@ -2706,9 +3147,10 @@ diff -urNp linux-3.1.4/arch/s390/mm/mmap.c linux-3= .1.4/arch/s390/mm/mmap.c mm->get_unmapped_area =3D s390_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-3.1.4/arch/score/include/asm/system.h linux-3.1.4/arch/= score/include/asm/system.h ---- linux-3.1.4/arch/score/include/asm/system.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/score/include/asm/system.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/score/include/asm/system.h b/arch/score/include/asm/sy= stem.h +index 589d5c7..669e274 100644 +--- a/arch/score/include/asm/system.h ++++ b/arch/score/include/asm/system.h @@ -17,7 +17,7 @@ do { \ #define finish_arch_switch(prev) do {} while (0) =20 @@ -2718,10 +3160,11 @@ diff -urNp linux-3.1.4/arch/score/include/asm/sys= tem.h linux-3.1.4/arch/score/in =20 #define mb() barrier() #define rmb() barrier() -diff -urNp linux-3.1.4/arch/score/kernel/process.c linux-3.1.4/arch/scor= e/kernel/process.c ---- linux-3.1.4/arch/score/kernel/process.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/score/kernel/process.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -161,8 +161,3 @@ unsigned long get_wchan(struct task_stru +diff --git a/arch/score/kernel/process.c b/arch/score/kernel/process.c +index 25d0803..d6c8e36 100644 +--- a/arch/score/kernel/process.c ++++ b/arch/score/kernel/process.c +@@ -161,8 +161,3 @@ unsigned long get_wchan(struct task_struct *task) =20 return task_pt_regs(task)->cp0_epc; } @@ -2730,10 +3173,11 @@ diff -urNp linux-3.1.4/arch/score/kernel/process.= c linux-3.1.4/arch/score/kernel -{ - return sp; -} -diff -urNp linux-3.1.4/arch/sh/mm/mmap.c linux-3.1.4/arch/sh/mm/mmap.c ---- linux-3.1.4/arch/sh/mm/mmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/sh/mm/mmap.c 2011-11-16 18:39:07.000000000 -0500 -@@ -74,8 +74,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/sh/mm/mmap.c b/arch/sh/mm/mmap.c +index afeb710..d1d1289 100644 +--- a/arch/sh/mm/mmap.c ++++ b/arch/sh/mm/mmap.c +@@ -74,8 +74,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -2752,7 +3196,7 @@ diff -urNp linux-3.1.4/arch/sh/mm/mmap.c linux-3.1.= 4/arch/sh/mm/mmap.c /* * Remember the place where we stopped the search: */ -@@ -157,8 +156,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -157,8 +156,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -2762,7 +3206,7 @@ diff -urNp linux-3.1.4/arch/sh/mm/mmap.c linux-3.1.= 4/arch/sh/mm/mmap.c return addr; } =20 -@@ -179,7 +177,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -179,7 +177,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* make sure it can fit in the remaining address space */ if (likely(addr > len)) { vma =3D find_vma(mm, addr-len); @@ -2771,7 +3215,7 @@ diff -urNp linux-3.1.4/arch/sh/mm/mmap.c linux-3.1.= 4/arch/sh/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -188,18 +186,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -188,18 +186,18 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, if (unlikely(mm->mmap_base < len)) goto bottomup; =20 @@ -2794,7 +3238,7 @@ diff -urNp linux-3.1.4/arch/sh/mm/mmap.c linux-3.1.= 4/arch/sh/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); } -@@ -209,10 +207,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -209,10 +207,8 @@ arch_get_unmapped_area_topdown(struct file *filp, c= onst unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -2807,9 +3251,23 @@ diff -urNp linux-3.1.4/arch/sh/mm/mmap.c linux-3.1= .4/arch/sh/mm/mmap.c =20 bottomup: /* -diff -urNp linux-3.1.4/arch/sparc/include/asm/atomic_64.h linux-3.1.4/ar= ch/sparc/include/asm/atomic_64.h ---- linux-3.1.4/arch/sparc/include/asm/atomic_64.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/atomic_64.h 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/sparc/Makefile b/arch/sparc/Makefile +index ad1fb5d..fc5315b 100644 +--- a/arch/sparc/Makefile ++++ b/arch/sparc/Makefile +@@ -75,7 +75,7 @@ drivers-$(CONFIG_OPROFILE) +=3D arch/sparc/oprofile/ + # Export what is needed by arch/sparc/boot/Makefile + export VMLINUX_INIT VMLINUX_MAIN + VMLINUX_INIT :=3D $(head-y) $(init-y) +-VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ ++VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ grsecurity/ + VMLINUX_MAIN +=3D $(patsubst %/, %/lib.a, $(libs-y)) $(libs-y) + VMLINUX_MAIN +=3D $(drivers-y) $(net-y) +=20 +diff --git a/arch/sparc/include/asm/atomic_64.h b/arch/sparc/include/asm= /atomic_64.h +index 9f421df..b81fc12 100644 +--- a/arch/sparc/include/asm/atomic_64.h ++++ b/arch/sparc/include/asm/atomic_64.h @@ -14,18 +14,40 @@ #define ATOMIC64_INIT(i) { (i) } =20 @@ -2851,7 +3309,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/atomi= c_64.h linux-3.1.4/arch/sparc extern int atomic_sub_ret(int, atomic_t *); extern long atomic64_sub_ret(long, atomic64_t *); =20 -@@ -33,13 +55,29 @@ extern long atomic64_sub_ret(long, atomi +@@ -33,13 +55,29 @@ extern long atomic64_sub_ret(long, atomic64_t *); #define atomic64_dec_return(v) atomic64_sub_ret(1, v) =20 #define atomic_inc_return(v) atomic_add_ret(1, v) @@ -2881,7 +3339,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/atomi= c_64.h linux-3.1.4/arch/sparc =20 /* * atomic_inc_and_test - increment and test -@@ -50,6 +88,10 @@ extern long atomic64_sub_ret(long, atomi +@@ -50,6 +88,10 @@ extern long atomic64_sub_ret(long, atomic64_t *); * other cases. */ #define atomic_inc_and_test(v) (atomic_inc_return(v) =3D=3D 0) @@ -2892,7 +3350,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/atomi= c_64.h linux-3.1.4/arch/sparc #define atomic64_inc_and_test(v) (atomic64_inc_return(v) =3D=3D 0) =20 #define atomic_sub_and_test(i, v) (atomic_sub_ret(i, v) =3D=3D 0) -@@ -59,25 +101,60 @@ extern long atomic64_sub_ret(long, atomi +@@ -59,25 +101,60 @@ extern long atomic64_sub_ret(long, atomic64_t *); #define atomic64_dec_and_test(v) (atomic64_sub_ret(1, v) =3D=3D 0) =20 #define atomic_inc(v) atomic_add(1, v) @@ -2956,7 +3414,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/atomi= c_64.h linux-3.1.4/arch/sparc if (likely(old =3D=3D c)) break; c =3D old; -@@ -89,20 +166,35 @@ static inline int __atomic_add_unless(at +@@ -89,20 +166,35 @@ static inline int __atomic_add_unless(atomic_t *v, = int a, int u) #define atomic64_cmpxchg(v, o, n) \ ((__typeof__((v)->counter))cmpxchg(&((v)->counter), (o), (n))) #define atomic64_xchg(v, new) (xchg(&((v)->counter), new)) @@ -2996,9 +3454,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/atom= ic_64.h linux-3.1.4/arch/sparc } =20 #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) -diff -urNp linux-3.1.4/arch/sparc/include/asm/cache.h linux-3.1.4/arch/s= parc/include/asm/cache.h ---- linux-3.1.4/arch/sparc/include/asm/cache.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/cache.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/sparc/include/asm/cache.h b/arch/sparc/include/asm/cac= he.h +index 69358b5..17b4745 100644 +--- a/arch/sparc/include/asm/cache.h ++++ b/arch/sparc/include/asm/cache.h @@ -10,7 +10,7 @@ #define ARCH_SLAB_MINALIGN __alignof__(unsigned long long) =20 @@ -3008,9 +3467,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/cach= e.h linux-3.1.4/arch/sparc/inc =20 #ifdef CONFIG_SPARC32 #define SMP_CACHE_BYTES_SHIFT 5 -diff -urNp linux-3.1.4/arch/sparc/include/asm/elf_32.h linux-3.1.4/arch/= sparc/include/asm/elf_32.h ---- linux-3.1.4/arch/sparc/include/asm/elf_32.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/elf_32.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/sparc/include/asm/elf_32.h b/arch/sparc/include/asm/el= f_32.h +index 4269ca6..e3da77f 100644 +--- a/arch/sparc/include/asm/elf_32.h ++++ b/arch/sparc/include/asm/elf_32.h @@ -114,6 +114,13 @@ typedef struct { =20 #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE) @@ -3025,9 +3485,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/elf_= 32.h linux-3.1.4/arch/sparc/in /* This yields a mask that user programs can use to figure out what instruction set this cpu supports. This can NOT be done in userspac= e on Sparc. */ -diff -urNp linux-3.1.4/arch/sparc/include/asm/elf_64.h linux-3.1.4/arch/= sparc/include/asm/elf_64.h ---- linux-3.1.4/arch/sparc/include/asm/elf_64.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/elf_64.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/sparc/include/asm/elf_64.h b/arch/sparc/include/asm/el= f_64.h +index 7df8b7f..4946269 100644 +--- a/arch/sparc/include/asm/elf_64.h ++++ b/arch/sparc/include/asm/elf_64.h @@ -180,6 +180,13 @@ typedef struct { #define ELF_ET_DYN_BASE 0x0000010000000000UL #define COMPAT_ELF_ET_DYN_BASE 0x0000000070000000UL @@ -3042,9 +3503,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/elf_= 64.h linux-3.1.4/arch/sparc/in extern unsigned long sparc64_elf_hwcap; #define ELF_HWCAP sparc64_elf_hwcap =20 -diff -urNp linux-3.1.4/arch/sparc/include/asm/pgtable_32.h linux-3.1.4/a= rch/sparc/include/asm/pgtable_32.h ---- linux-3.1.4/arch/sparc/include/asm/pgtable_32.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/pgtable_32.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/arch/sparc/include/asm/pgtable_32.h b/arch/sparc/include/as= m/pgtable_32.h +index 5b31a8e..1d92567 100644 +--- a/arch/sparc/include/asm/pgtable_32.h ++++ b/arch/sparc/include/asm/pgtable_32.h @@ -45,6 +45,13 @@ BTFIXUPDEF_SIMM13(user_ptrs_per_pgd) BTFIXUPDEF_INT(page_none) BTFIXUPDEF_INT(page_copy) @@ -3076,9 +3538,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/pgta= ble_32.h linux-3.1.4/arch/spar extern unsigned long page_kernel; =20 #ifdef MODULE -diff -urNp linux-3.1.4/arch/sparc/include/asm/pgtsrmmu.h linux-3.1.4/arc= h/sparc/include/asm/pgtsrmmu.h ---- linux-3.1.4/arch/sparc/include/asm/pgtsrmmu.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/pgtsrmmu.h 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/arch/sparc/include/asm/pgtsrmmu.h b/arch/sparc/include/asm/= pgtsrmmu.h +index f6ae2b2..b03ffc7 100644 +--- a/arch/sparc/include/asm/pgtsrmmu.h ++++ b/arch/sparc/include/asm/pgtsrmmu.h @@ -115,6 +115,13 @@ SRMMU_EXEC | SRMMU_REF) #define SRMMU_PAGE_RDONLY __pgprot(SRMMU_VALID | SRMMU_CACHE | \ @@ -3093,10 +3556,11 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/pgt= srmmu.h linux-3.1.4/arch/sparc/ #define SRMMU_PAGE_KERNEL __pgprot(SRMMU_VALID | SRMMU_CACHE | SRMMU_P= RIV | \ SRMMU_DIRTY | SRMMU_REF) =20 -diff -urNp linux-3.1.4/arch/sparc/include/asm/spinlock_64.h linux-3.1.4/= arch/sparc/include/asm/spinlock_64.h ---- linux-3.1.4/arch/sparc/include/asm/spinlock_64.h 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/spinlock_64.h 2011-11-16 18:39:07= .000000000 -0500 -@@ -92,14 +92,19 @@ static inline void arch_spin_lock_flags( +diff --git a/arch/sparc/include/asm/spinlock_64.h b/arch/sparc/include/a= sm/spinlock_64.h +index 9689176..63c18ea 100644 +--- a/arch/sparc/include/asm/spinlock_64.h ++++ b/arch/sparc/include/asm/spinlock_64.h +@@ -92,14 +92,19 @@ static inline void arch_spin_lock_flags(arch_spinloc= k_t *lock, unsigned long fla =20 /* Multi-reader locks, these are much saner than the 32-bit Sparc ones.= .. */ =20 @@ -3118,7 +3582,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/spinl= ock_64.h linux-3.1.4/arch/spa " cas [%2], %0, %1\n" " cmp %0, %1\n" " bne,pn %%icc, 1b\n" -@@ -112,10 +117,10 @@ static void inline arch_read_lock(arch_r +@@ -112,10 +117,10 @@ static void inline arch_read_lock(arch_rwlock_t *l= ock) " .previous" : "=3D&r" (tmp1), "=3D&r" (tmp2) : "r" (lock) @@ -3131,7 +3595,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/spinl= ock_64.h linux-3.1.4/arch/spa { int tmp1, tmp2; =20 -@@ -123,7 +128,12 @@ static int inline arch_read_trylock(arch +@@ -123,7 +128,12 @@ static int inline arch_read_trylock(arch_rwlock_t *= lock) "1: ldsw [%2], %0\n" " brlz,a,pn %0, 2f\n" " mov 0, %0\n" @@ -3145,7 +3609,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/spinl= ock_64.h linux-3.1.4/arch/spa " cas [%2], %0, %1\n" " cmp %0, %1\n" " bne,pn %%icc, 1b\n" -@@ -136,13 +146,18 @@ static int inline arch_read_trylock(arch +@@ -136,13 +146,18 @@ static int inline arch_read_trylock(arch_rwlock_t = *lock) return tmp1; } =20 @@ -3166,7 +3630,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/spinl= ock_64.h linux-3.1.4/arch/spa " cas [%2], %0, %1\n" " cmp %0, %1\n" " bne,pn %%xcc, 1b\n" -@@ -152,7 +167,7 @@ static void inline arch_read_unlock(arch +@@ -152,7 +167,7 @@ static void inline arch_read_unlock(arch_rwlock_t *l= ock) : "memory"); } =20 @@ -3175,7 +3639,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/spinl= ock_64.h linux-3.1.4/arch/spa { unsigned long mask, tmp1, tmp2; =20 -@@ -177,7 +192,7 @@ static void inline arch_write_lock(arch_ +@@ -177,7 +192,7 @@ static void inline arch_write_lock(arch_rwlock_t *lo= ck) : "memory"); } =20 @@ -3184,7 +3648,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/spinl= ock_64.h linux-3.1.4/arch/spa { __asm__ __volatile__( " stw %%g0, [%0]" -@@ -186,7 +201,7 @@ static void inline arch_write_unlock(arc +@@ -186,7 +201,7 @@ static void inline arch_write_unlock(arch_rwlock_t *= lock) : "memory"); } =20 @@ -3193,9 +3657,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/spin= lock_64.h linux-3.1.4/arch/spa { unsigned long mask, tmp1, tmp2, result; =20 -diff -urNp linux-3.1.4/arch/sparc/include/asm/thread_info_32.h linux-3.1= .4/arch/sparc/include/asm/thread_info_32.h ---- linux-3.1.4/arch/sparc/include/asm/thread_info_32.h 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/thread_info_32.h 2011-11-16 18:39= :07.000000000 -0500 +diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/includ= e/asm/thread_info_32.h +index fa57532..e1a4c53 100644 +--- a/arch/sparc/include/asm/thread_info_32.h ++++ b/arch/sparc/include/asm/thread_info_32.h @@ -50,6 +50,8 @@ struct thread_info { unsigned long w_saved; =20 @@ -3205,9 +3670,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/thre= ad_info_32.h linux-3.1.4/arch/ }; =20 /* -diff -urNp linux-3.1.4/arch/sparc/include/asm/thread_info_64.h linux-3.1= .4/arch/sparc/include/asm/thread_info_64.h ---- linux-3.1.4/arch/sparc/include/asm/thread_info_64.h 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/thread_info_64.h 2011-11-16 18:39= :07.000000000 -0500 +diff --git a/arch/sparc/include/asm/thread_info_64.h b/arch/sparc/includ= e/asm/thread_info_64.h +index 60d86be..952dea1 100644 +--- a/arch/sparc/include/asm/thread_info_64.h ++++ b/arch/sparc/include/asm/thread_info_64.h @@ -63,6 +63,8 @@ struct thread_info { struct pt_regs *kern_una_regs; unsigned int kern_una_insn; @@ -3217,10 +3683,29 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/thr= ead_info_64.h linux-3.1.4/arch/ unsigned long fpregs[0] __attribute__ ((aligned(64))); }; =20 -diff -urNp linux-3.1.4/arch/sparc/include/asm/uaccess_32.h linux-3.1.4/a= rch/sparc/include/asm/uaccess_32.h ---- linux-3.1.4/arch/sparc/include/asm/uaccess_32.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/uaccess_32.h 2011-11-16 18:39:07.= 000000000 -0500 -@@ -249,27 +249,46 @@ extern unsigned long __copy_user(void __ +diff --git a/arch/sparc/include/asm/uaccess.h b/arch/sparc/include/asm/u= access.h +index e88fbe5..96b0ce5 100644 +--- a/arch/sparc/include/asm/uaccess.h ++++ b/arch/sparc/include/asm/uaccess.h +@@ -1,5 +1,13 @@ + #ifndef ___ASM_SPARC_UACCESS_H + #define ___ASM_SPARC_UACCESS_H ++ ++#ifdef __KERNEL__ ++#ifndef __ASSEMBLY__ ++#include ++extern void check_object_size(const void *ptr, unsigned long n, bool to= ); ++#endif ++#endif ++ + #if defined(__sparc__) && defined(__arch64__) + #include + #else +diff --git a/arch/sparc/include/asm/uaccess_32.h b/arch/sparc/include/as= m/uaccess_32.h +index 8303ac4..07f333d 100644 +--- a/arch/sparc/include/asm/uaccess_32.h ++++ b/arch/sparc/include/asm/uaccess_32.h +@@ -249,27 +249,46 @@ extern unsigned long __copy_user(void __user *to, = const void __user *from, unsig =20 static inline unsigned long copy_to_user(void __user *to, const void *f= rom, unsigned long n) { @@ -3271,9 +3756,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/uacc= ess_32.h linux-3.1.4/arch/spar return __copy_user((__force void __user *) to, from, n); } =20 -diff -urNp linux-3.1.4/arch/sparc/include/asm/uaccess_64.h linux-3.1.4/a= rch/sparc/include/asm/uaccess_64.h ---- linux-3.1.4/arch/sparc/include/asm/uaccess_64.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/uaccess_64.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/arch/sparc/include/asm/uaccess_64.h b/arch/sparc/include/as= m/uaccess_64.h +index 3e1449f..5293a0e 100644 +--- a/arch/sparc/include/asm/uaccess_64.h ++++ b/arch/sparc/include/asm/uaccess_64.h @@ -10,6 +10,7 @@ #include #include @@ -3282,7 +3768,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/uacce= ss_64.h linux-3.1.4/arch/spar #include #include #include -@@ -213,8 +214,15 @@ extern unsigned long copy_from_user_fixu +@@ -213,8 +214,15 @@ extern unsigned long copy_from_user_fixup(void *to,= const void __user *from, static inline unsigned long __must_check copy_from_user(void *to, const void __user *from, unsigned long size) { @@ -3299,7 +3785,7 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/uacce= ss_64.h linux-3.1.4/arch/spar if (unlikely(ret)) ret =3D copy_from_user_fixup(to, from, size); =20 -@@ -230,8 +238,15 @@ extern unsigned long copy_to_user_fixup( +@@ -230,8 +238,15 @@ extern unsigned long copy_to_user_fixup(void __user= *to, const void *from, static inline unsigned long __must_check copy_to_user(void __user *to, const void *from, unsigned long size) { @@ -3316,26 +3802,10 @@ diff -urNp linux-3.1.4/arch/sparc/include/asm/uac= cess_64.h linux-3.1.4/arch/spar if (unlikely(ret)) ret =3D copy_to_user_fixup(to, from, size); return ret; -diff -urNp linux-3.1.4/arch/sparc/include/asm/uaccess.h linux-3.1.4/arch= /sparc/include/asm/uaccess.h ---- linux-3.1.4/arch/sparc/include/asm/uaccess.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/sparc/include/asm/uaccess.h 2011-11-16 18:39:07.000= 000000 -0500 -@@ -1,5 +1,13 @@ - #ifndef ___ASM_SPARC_UACCESS_H - #define ___ASM_SPARC_UACCESS_H -+ -+#ifdef __KERNEL__ -+#ifndef __ASSEMBLY__ -+#include -+extern void check_object_size(const void *ptr, unsigned long n, bool to= ); -+#endif -+#endif -+ - #if defined(__sparc__) && defined(__arch64__) - #include - #else -diff -urNp linux-3.1.4/arch/sparc/kernel/Makefile linux-3.1.4/arch/sparc= /kernel/Makefile ---- linux-3.1.4/arch/sparc/kernel/Makefile 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/sparc/kernel/Makefile 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/sparc/kernel/Makefile b/arch/sparc/kernel/Makefile +index cb85458..e063f17 100644 +--- a/arch/sparc/kernel/Makefile ++++ b/arch/sparc/kernel/Makefile @@ -3,7 +3,7 @@ # =20 @@ -3345,9 +3815,10 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/Makefile = linux-3.1.4/arch/sparc/kernel/ =20 extra-y :=3D head_$(BITS).o extra-y +=3D init_task.o -diff -urNp linux-3.1.4/arch/sparc/kernel/process_32.c linux-3.1.4/arch/s= parc/kernel/process_32.c ---- linux-3.1.4/arch/sparc/kernel/process_32.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/sparc/kernel/process_32.c 2011-11-16 18:40:08.00000= 0000 -0500 +diff --git a/arch/sparc/kernel/process_32.c b/arch/sparc/kernel/process_= 32.c +index f793742..4d880af 100644 +--- a/arch/sparc/kernel/process_32.c ++++ b/arch/sparc/kernel/process_32.c @@ -204,7 +204,7 @@ void __show_backtrace(unsigned long fp) rw->ins[4], rw->ins[5], rw->ins[6], @@ -3374,7 +3845,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/process_32= .c linux-3.1.4/arch/sparc/ker =20 printk("%%L: %08lx %08lx %08lx %08lx %08lx %08lx %08lx %08lx\n", rw->locals[0], rw->locals[1], rw->locals[2], rw->locals[3], -@@ -313,7 +313,7 @@ void show_stack(struct task_struct *tsk, +@@ -313,7 +313,7 @@ void show_stack(struct task_struct *tsk, unsigned lo= ng *_ksp) rw =3D (struct reg_window32 *) fp; pc =3D rw->ins[7]; printk("[%08lx : ", pc); @@ -3383,10 +3854,11 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/process_= 32.c linux-3.1.4/arch/sparc/ker fp =3D rw->ins[6]; } while (++count < 16); printk("\n"); -diff -urNp linux-3.1.4/arch/sparc/kernel/process_64.c linux-3.1.4/arch/s= parc/kernel/process_64.c ---- linux-3.1.4/arch/sparc/kernel/process_64.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/sparc/kernel/process_64.c 2011-11-16 18:40:08.00000= 0000 -0500 -@@ -180,14 +180,14 @@ static void show_regwindow(struct pt_reg +diff --git a/arch/sparc/kernel/process_64.c b/arch/sparc/kernel/process_= 64.c +index d959cd0..7b42812 100644 +--- a/arch/sparc/kernel/process_64.c ++++ b/arch/sparc/kernel/process_64.c +@@ -180,14 +180,14 @@ static void show_regwindow(struct pt_regs *regs) printk("i4: %016lx i5: %016lx i6: %016lx i7: %016lx\n", rwk->ins[4], rwk->ins[5], rwk->ins[6], rwk->ins[7]); if (regs->tstate & TSTATE_PRIV) @@ -3412,7 +3884,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/process_64= .c linux-3.1.4/arch/sparc/ker show_regwindow(regs); show_stack(current, (unsigned long *) regs->u_regs[UREG_FP]); } -@@ -285,7 +285,7 @@ void arch_trigger_all_cpu_backtrace(void +@@ -285,7 +285,7 @@ void arch_trigger_all_cpu_backtrace(void) ((tp && tp->task) ? tp->task->pid : -1)); =20 if (gp->tstate & TSTATE_PRIV) { @@ -3421,10 +3893,11 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/process_= 64.c linux-3.1.4/arch/sparc/ker (void *) gp->tpc, (void *) gp->o7, (void *) gp->i7, -diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_32.c linux-3.1.4/arch= /sparc/kernel/sys_sparc_32.c ---- linux-3.1.4/arch/sparc/kernel/sys_sparc_32.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/sparc/kernel/sys_sparc_32.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -56,7 +56,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/sparc/kernel/sys_sparc_32.c b/arch/sparc/kernel/sys_sp= arc_32.c +index 42b282f..28ce9f2 100644 +--- a/arch/sparc/kernel/sys_sparc_32.c ++++ b/arch/sparc/kernel/sys_sparc_32.c +@@ -56,7 +56,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi if (ARCH_SUN4C && len > 0x20000000) return -ENOMEM; if (!addr) @@ -3433,7 +3906,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 32.c linux-3.1.4/arch/sparc/k =20 if (flags & MAP_SHARED) addr =3D COLOUR_ALIGN(addr); -@@ -71,7 +71,7 @@ unsigned long arch_get_unmapped_area(str +@@ -71,7 +71,7 @@ unsigned long arch_get_unmapped_area(struct file *filp= , unsigned long addr, unsi } if (TASK_SIZE - PAGE_SIZE - len < addr) return -ENOMEM; @@ -3442,10 +3915,11 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_spar= c_32.c linux-3.1.4/arch/sparc/k return addr; addr =3D vmm->vm_end; if (flags & MAP_SHARED) -diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_64.c linux-3.1.4/arch= /sparc/kernel/sys_sparc_64.c ---- linux-3.1.4/arch/sparc/kernel/sys_sparc_64.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/sparc/kernel/sys_sparc_64.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -124,7 +124,7 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/sparc/kernel/sys_sparc_64.c b/arch/sparc/kernel/sys_sp= arc_64.c +index 908b47a..aa9e584 100644 +--- a/arch/sparc/kernel/sys_sparc_64.c ++++ b/arch/sparc/kernel/sys_sparc_64.c +@@ -124,7 +124,7 @@ unsigned long arch_get_unmapped_area(struct file *fi= lp, unsigned long addr, unsi /* We do not accept a shared mapping if it would violate * cache aliasing constraints. */ @@ -3454,7 +3928,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k ((addr - (pgoff << PAGE_SHIFT)) & (SHMLBA - 1))) return -EINVAL; return addr; -@@ -139,6 +139,10 @@ unsigned long arch_get_unmapped_area(str +@@ -139,6 +139,10 @@ unsigned long arch_get_unmapped_area(struct file *f= ilp, unsigned long addr, unsi if (filp || (flags & MAP_SHARED)) do_color_align =3D 1; =20 @@ -3465,7 +3939,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k if (addr) { if (do_color_align) addr =3D COLOUR_ALIGN(addr, pgoff); -@@ -146,15 +150,14 @@ unsigned long arch_get_unmapped_area(str +@@ -146,15 +150,14 @@ unsigned long arch_get_unmapped_area(struct file *= filp, unsigned long addr, unsi addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -3502,7 +3976,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k /* * Remember the place where we stopped the search: */ -@@ -215,7 +218,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -215,7 +218,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* We do not accept a shared mapping if it would violate * cache aliasing constraints. */ @@ -3511,7 +3985,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k ((addr - (pgoff << PAGE_SHIFT)) & (SHMLBA - 1))) return -EINVAL; return addr; -@@ -236,8 +239,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -236,8 +239,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, addr =3D PAGE_ALIGN(addr); =20 vma =3D find_vma(mm, addr); @@ -3521,7 +3995,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k return addr; } =20 -@@ -258,7 +260,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -258,7 +260,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* make sure it can fit in the remaining address space */ if (likely(addr > len)) { vma =3D find_vma(mm, addr-len); @@ -3530,7 +4004,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -267,18 +269,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -267,18 +269,18 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, if (unlikely(mm->mmap_base < len)) goto bottomup; =20 @@ -3553,7 +4027,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); } -@@ -288,10 +290,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -288,10 +290,8 @@ arch_get_unmapped_area_topdown(struct file *filp, c= onst unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -3566,7 +4040,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k =20 bottomup: /* -@@ -390,6 +390,12 @@ void arch_pick_mmap_layout(struct mm_str +@@ -390,6 +390,12 @@ void arch_pick_mmap_layout(struct mm_struct *mm) gap =3D=3D RLIM_INFINITY || sysctl_legacy_va_layout) { mm->mmap_base =3D TASK_UNMAPPED_BASE + random_factor; @@ -3579,7 +4053,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_sparc_= 64.c linux-3.1.4/arch/sparc/k mm->get_unmapped_area =3D arch_get_unmapped_area; mm->unmap_area =3D arch_unmap_area; } else { -@@ -402,6 +408,12 @@ void arch_pick_mmap_layout(struct mm_str +@@ -402,6 +408,12 @@ void arch_pick_mmap_layout(struct mm_struct *mm) gap =3D (task_size / 6 * 5); =20 mm->mmap_base =3D PAGE_ALIGN(task_size - gap - random_factor); @@ -3592,10 +4066,11 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/sys_spar= c_64.c linux-3.1.4/arch/sparc/k mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-3.1.4/arch/sparc/kernel/traps_32.c linux-3.1.4/arch/spa= rc/kernel/traps_32.c ---- linux-3.1.4/arch/sparc/kernel/traps_32.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/sparc/kernel/traps_32.c 2011-11-16 18:40:08.0000000= 00 -0500 -@@ -44,6 +44,8 @@ static void instruction_dump(unsigned lo +diff --git a/arch/sparc/kernel/traps_32.c b/arch/sparc/kernel/traps_32.c +index c0490c7..84959d1 100644 +--- a/arch/sparc/kernel/traps_32.c ++++ b/arch/sparc/kernel/traps_32.c +@@ -44,6 +44,8 @@ static void instruction_dump(unsigned long *pc) #define __SAVE __asm__ __volatile__("save %sp, -0x40, %sp\n\t") #define __RESTORE __asm__ __volatile__("restore %g0, %g0, %g0\n\t") =20 @@ -3604,7 +4079,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_32.c= linux-3.1.4/arch/sparc/kerne void die_if_kernel(char *str, struct pt_regs *regs) { static int die_counter; -@@ -76,15 +78,17 @@ void die_if_kernel(char *str, struct pt_ +@@ -76,15 +78,17 @@ void die_if_kernel(char *str, struct pt_regs *regs) count++ < 30 && (((unsigned long) rw) >=3D PAGE_OFFSET) && !(((unsigned long) rw) & 0x7)) { @@ -3624,10 +4099,11 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_32= .c linux-3.1.4/arch/sparc/kerne do_exit(SIGSEGV); } =20 -diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c linux-3.1.4/arch/spa= rc/kernel/traps_64.c ---- linux-3.1.4/arch/sparc/kernel/traps_64.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/sparc/kernel/traps_64.c 2011-11-16 18:40:08.0000000= 00 -0500 -@@ -75,7 +75,7 @@ static void dump_tl1_traplog(struct tl1_ +diff --git a/arch/sparc/kernel/traps_64.c b/arch/sparc/kernel/traps_64.c +index 0cbdaa4..438e4c9 100644 +--- a/arch/sparc/kernel/traps_64.c ++++ b/arch/sparc/kernel/traps_64.c +@@ -75,7 +75,7 @@ static void dump_tl1_traplog(struct tl1_traplog *p) i + 1, p->trapstack[i].tstate, p->trapstack[i].tpc, p->trapstack[i].tnpc, p->trapstack[i].tt); @@ -3636,7 +4112,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne } } =20 -@@ -95,6 +95,12 @@ void bad_trap(struct pt_regs *regs, long +@@ -95,6 +95,12 @@ void bad_trap(struct pt_regs *regs, long lvl) =20 lvl -=3D 0x100; if (regs->tstate & TSTATE_PRIV) { @@ -3649,7 +4125,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne sprintf(buffer, "Kernel bad sw trap %lx", lvl); die_if_kernel(buffer, regs); } -@@ -113,11 +119,16 @@ void bad_trap(struct pt_regs *regs, long +@@ -113,11 +119,16 @@ void bad_trap(struct pt_regs *regs, long lvl) void bad_trap_tl1(struct pt_regs *regs, long lvl) { char buffer[32]; @@ -3667,7 +4143,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne dump_tl1_traplog((struct tl1_traplog *)(regs + 1)); =20 sprintf (buffer, "Bad trap %lx at tl>0", lvl); -@@ -1141,7 +1152,7 @@ static void cheetah_log_errors(struct pt +@@ -1141,7 +1152,7 @@ static void cheetah_log_errors(struct pt_regs *reg= s, struct cheetah_err_info *in regs->tpc, regs->tnpc, regs->u_regs[UREG_I7], regs->tstate); printk("%s" "ERROR(%d): ", (recoverable ? KERN_WARNING : KERN_CRIT), smp_processor_id()); @@ -3676,7 +4152,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne printk("%s" "ERROR(%d): M_SYND(%lx), E_SYND(%lx)%s%s\n", (recoverable ? KERN_WARNING : KERN_CRIT), smp_processor_id(), (afsr & CHAFSR_M_SYNDROME) >> CHAFSR_M_SYNDROME_SHIFT, -@@ -1748,7 +1759,7 @@ void cheetah_plus_parity_error(int type, +@@ -1748,7 +1759,7 @@ void cheetah_plus_parity_error(int type, struct pt= _regs *regs) smp_processor_id(), (type & 0x1) ? 'I' : 'D', regs->tpc); @@ -3685,7 +4161,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne panic("Irrecoverable Cheetah+ parity error."); } =20 -@@ -1756,7 +1767,7 @@ void cheetah_plus_parity_error(int type, +@@ -1756,7 +1767,7 @@ void cheetah_plus_parity_error(int type, struct pt= _regs *regs) smp_processor_id(), (type & 0x1) ? 'I' : 'D', regs->tpc); @@ -3694,7 +4170,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne } =20 struct sun4v_error_entry { -@@ -1963,9 +1974,9 @@ void sun4v_itlb_error_report(struct pt_r +@@ -1963,9 +1974,9 @@ void sun4v_itlb_error_report(struct pt_regs *regs,= int tl) =20 printk(KERN_EMERG "SUN4V-ITLB: Error at TPC[%lx], tl %d\n", regs->tpc, tl); @@ -3706,7 +4182,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne (void *) regs->u_regs[UREG_I7]); printk(KERN_EMERG "SUN4V-ITLB: vaddr[%lx] ctx[%lx] " "pte[%lx] error[%lx]\n", -@@ -1987,9 +1998,9 @@ void sun4v_dtlb_error_report(struct pt_r +@@ -1987,9 +1998,9 @@ void sun4v_dtlb_error_report(struct pt_regs *regs,= int tl) =20 printk(KERN_EMERG "SUN4V-DTLB: Error at TPC[%lx], tl %d\n", regs->tpc, tl); @@ -3718,7 +4194,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne (void *) regs->u_regs[UREG_I7]); printk(KERN_EMERG "SUN4V-DTLB: vaddr[%lx] ctx[%lx] " "pte[%lx] error[%lx]\n", -@@ -2195,13 +2206,13 @@ void show_stack(struct task_struct *tsk, +@@ -2195,13 +2206,13 @@ void show_stack(struct task_struct *tsk, unsigne= d long *_ksp) fp =3D (unsigned long)sf->fp + STACK_BIAS; } =20 @@ -3734,7 +4210,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne graph++; } } -@@ -2226,6 +2237,8 @@ static inline struct reg_window *kernel_ +@@ -2226,6 +2237,8 @@ static inline struct reg_window *kernel_stack_up(s= truct reg_window *rw) return (struct reg_window *) (fp + STACK_BIAS); } =20 @@ -3743,7 +4219,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne void die_if_kernel(char *str, struct pt_regs *regs) { static int die_counter; -@@ -2254,7 +2267,7 @@ void die_if_kernel(char *str, struct pt_ +@@ -2254,7 +2267,7 @@ void die_if_kernel(char *str, struct pt_regs *regs= ) while (rw && count++ < 30 && kstack_valid(tp, (unsigned long) rw)) { @@ -3752,7 +4228,7 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64.c= linux-3.1.4/arch/sparc/kerne (void *) rw->ins[7]); =20 rw =3D kernel_stack_up(rw); -@@ -2267,8 +2280,10 @@ void die_if_kernel(char *str, struct pt_ +@@ -2267,8 +2280,10 @@ void die_if_kernel(char *str, struct pt_regs *reg= s) } user_instruction_dump ((unsigned int __user *) regs->tpc); } @@ -3764,10 +4240,11 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/traps_64= .c linux-3.1.4/arch/sparc/kerne do_exit(SIGSEGV); } EXPORT_SYMBOL(die_if_kernel); -diff -urNp linux-3.1.4/arch/sparc/kernel/unaligned_64.c linux-3.1.4/arch= /sparc/kernel/unaligned_64.c ---- linux-3.1.4/arch/sparc/kernel/unaligned_64.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/sparc/kernel/unaligned_64.c 2011-11-16 18:40:08.000= 000000 -0500 -@@ -279,7 +279,7 @@ static void log_unaligned(struct pt_regs +diff --git a/arch/sparc/kernel/unaligned_64.c b/arch/sparc/kernel/unalig= ned_64.c +index 76e4ac1..78f8bb1 100644 +--- a/arch/sparc/kernel/unaligned_64.c ++++ b/arch/sparc/kernel/unaligned_64.c +@@ -279,7 +279,7 @@ static void log_unaligned(struct pt_regs *regs) static DEFINE_RATELIMIT_STATE(ratelimit, 5 * HZ, 5); =20 if (__ratelimit(&ratelimit)) { @@ -3776,9 +4253,23 @@ diff -urNp linux-3.1.4/arch/sparc/kernel/unaligned= _64.c linux-3.1.4/arch/sparc/k regs->tpc, (void *) regs->tpc); } } -diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S linux-3.1.4/arch/sparc= /lib/atomic_64.S ---- linux-3.1.4/arch/sparc/lib/atomic_64.S 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/sparc/lib/atomic_64.S 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/sparc/lib/Makefile b/arch/sparc/lib/Makefile +index a3fc437..fea9957 100644 +--- a/arch/sparc/lib/Makefile ++++ b/arch/sparc/lib/Makefile +@@ -2,7 +2,7 @@ + # +=20 + asflags-y :=3D -ansi -DST_DIV0=3D0x02 +-ccflags-y :=3D -Werror ++#ccflags-y :=3D -Werror +=20 + lib-$(CONFIG_SPARC32) +=3D mul.o rem.o sdiv.o udiv.o umul.o urem.o ashr= di3.o + lib-$(CONFIG_SPARC32) +=3D memcpy.o memset.o +diff --git a/arch/sparc/lib/atomic_64.S b/arch/sparc/lib/atomic_64.S +index 59186e0..f747d7a 100644 +--- a/arch/sparc/lib/atomic_64.S ++++ b/arch/sparc/lib/atomic_64.S @@ -18,7 +18,12 @@ atomic_add: /* %o0 =3D increment, %o1 =3D atomic_ptr */ BACKOFF_SETUP(%o2) @@ -3793,7 +4284,7 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S l= inux-3.1.4/arch/sparc/lib/ato cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, BACKOFF_LABEL(2f, 1b) -@@ -28,12 +33,32 @@ atomic_add: /* %o0 =3D increment, %o1 =3D at +@@ -28,12 +33,32 @@ atomic_add: /* %o0 =3D increment, %o1 =3D atomic_ptr= */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_add, .-atomic_add =20 @@ -3827,7 +4318,7 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S l= inux-3.1.4/arch/sparc/lib/ato cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, BACKOFF_LABEL(2f, 1b) -@@ -43,12 +68,32 @@ atomic_sub: /* %o0 =3D decrement, %o1 =3D at +@@ -43,12 +68,32 @@ atomic_sub: /* %o0 =3D decrement, %o1 =3D atomic_ptr= */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_sub, .-atomic_sub =20 @@ -3861,7 +4352,7 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S l= inux-3.1.4/arch/sparc/lib/ato cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, BACKOFF_LABEL(2f, 1b) -@@ -58,12 +103,33 @@ atomic_add_ret: /* %o0 =3D increment, %o1=20 +@@ -58,12 +103,33 @@ atomic_add_ret: /* %o0 =3D increment, %o1 =3D atomi= c_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_add_ret, .-atomic_add_ret =20 @@ -3896,7 +4387,7 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S l= inux-3.1.4/arch/sparc/lib/ato cas [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %icc, BACKOFF_LABEL(2f, 1b) -@@ -78,7 +144,12 @@ atomic_sub_ret: /* %o0 =3D decrement, %o1=20 +@@ -78,7 +144,12 @@ atomic_sub_ret: /* %o0 =3D decrement, %o1 =3D atomic= _ptr */ atomic64_add: /* %o0 =3D increment, %o1 =3D atomic_ptr */ BACKOFF_SETUP(%o2) 1: ldx [%o1], %g1 @@ -3910,7 +4401,7 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S l= inux-3.1.4/arch/sparc/lib/ato casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, BACKOFF_LABEL(2f, 1b) -@@ -88,12 +159,32 @@ atomic64_add: /* %o0 =3D increment, %o1 =3D=20 +@@ -88,12 +159,32 @@ atomic64_add: /* %o0 =3D increment, %o1 =3D atomic_= ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_add, .-atomic64_add =20 @@ -3944,7 +4435,7 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S l= inux-3.1.4/arch/sparc/lib/ato casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, BACKOFF_LABEL(2f, 1b) -@@ -103,12 +194,32 @@ atomic64_sub: /* %o0 =3D decrement, %o1 =3D=20 +@@ -103,12 +194,32 @@ atomic64_sub: /* %o0 =3D decrement, %o1 =3D atomic= _ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_sub, .-atomic64_sub =20 @@ -3978,7 +4469,7 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S l= inux-3.1.4/arch/sparc/lib/ato casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, BACKOFF_LABEL(2f, 1b) -@@ -118,12 +229,33 @@ atomic64_add_ret: /* %o0 =3D increment, %o +@@ -118,12 +229,33 @@ atomic64_add_ret: /* %o0 =3D increment, %o1 =3D at= omic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_add_ret, .-atomic64_add_ret =20 @@ -4013,9 +4504,10 @@ diff -urNp linux-3.1.4/arch/sparc/lib/atomic_64.S = linux-3.1.4/arch/sparc/lib/ato casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, BACKOFF_LABEL(2f, 1b) -diff -urNp linux-3.1.4/arch/sparc/lib/ksyms.c linux-3.1.4/arch/sparc/lib= /ksyms.c ---- linux-3.1.4/arch/sparc/lib/ksyms.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/sparc/lib/ksyms.c 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/sparc/lib/ksyms.c b/arch/sparc/lib/ksyms.c +index 1b30bb3..b4a16c7 100644 +--- a/arch/sparc/lib/ksyms.c ++++ b/arch/sparc/lib/ksyms.c @@ -142,12 +142,18 @@ EXPORT_SYMBOL(__downgrade_write); =20 /* Atomic counter implementation. */ @@ -4035,33 +4527,23 @@ diff -urNp linux-3.1.4/arch/sparc/lib/ksyms.c lin= ux-3.1.4/arch/sparc/lib/ksyms.c EXPORT_SYMBOL(atomic64_sub_ret); =20 /* Atomic bit operations. */ -diff -urNp linux-3.1.4/arch/sparc/lib/Makefile linux-3.1.4/arch/sparc/li= b/Makefile ---- linux-3.1.4/arch/sparc/lib/Makefile 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/sparc/lib/Makefile 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/sparc/mm/Makefile b/arch/sparc/mm/Makefile +index e3cda21..a68e4cb 100644 +--- a/arch/sparc/mm/Makefile ++++ b/arch/sparc/mm/Makefile @@ -2,7 +2,7 @@ # =20 - asflags-y :=3D -ansi -DST_DIV0=3D0x02 + asflags-y :=3D -ansi -ccflags-y :=3D -Werror +#ccflags-y :=3D -Werror =20 - lib-$(CONFIG_SPARC32) +=3D mul.o rem.o sdiv.o udiv.o umul.o urem.o ashr= di3.o - lib-$(CONFIG_SPARC32) +=3D memcpy.o memset.o -diff -urNp linux-3.1.4/arch/sparc/Makefile linux-3.1.4/arch/sparc/Makefi= le ---- linux-3.1.4/arch/sparc/Makefile 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/sparc/Makefile 2011-11-16 18:40:08.000000000 -0500 -@@ -75,7 +75,7 @@ drivers-$(CONFIG_OPROFILE) +=3D arch/sparc - # Export what is needed by arch/sparc/boot/Makefile - export VMLINUX_INIT VMLINUX_MAIN - VMLINUX_INIT :=3D $(head-y) $(init-y) --VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ -+VMLINUX_MAIN :=3D $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ bloc= k/ grsecurity/ - VMLINUX_MAIN +=3D $(patsubst %/, %/lib.a, $(libs-y)) $(libs-y) - VMLINUX_MAIN +=3D $(drivers-y) $(net-y) -=20 -diff -urNp linux-3.1.4/arch/sparc/mm/fault_32.c linux-3.1.4/arch/sparc/m= m/fault_32.c ---- linux-3.1.4/arch/sparc/mm/fault_32.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/sparc/mm/fault_32.c 2011-11-16 18:39:07.000000000 -= 0500 + obj-$(CONFIG_SPARC64) +=3D ultra.o tlb.o tsb.o gup.o + obj-y +=3D fault_$(BITS).o +diff --git a/arch/sparc/mm/fault_32.c b/arch/sparc/mm/fault_32.c +index aa1c1b1..f93e28f 100644 +--- a/arch/sparc/mm/fault_32.c ++++ b/arch/sparc/mm/fault_32.c @@ -22,6 +22,9 @@ #include #include @@ -4072,7 +4554,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/fault_32.c lin= ux-3.1.4/arch/sparc/mm/fault_ =20 #include #include -@@ -209,6 +212,268 @@ static unsigned long compute_si_addr(str +@@ -209,6 +212,268 @@ static unsigned long compute_si_addr(struct pt_reg= s *regs, int text_fault) return safe_compute_effective_address(regs, insn); } =20 @@ -4366,9 +4848,10 @@ diff -urNp linux-3.1.4/arch/sparc/mm/fault_32.c li= nux-3.1.4/arch/sparc/mm/fault_ /* Allow reads even for write-only mappings */ if(!(vma->vm_flags & (VM_READ | VM_EXEC))) goto bad_area; -diff -urNp linux-3.1.4/arch/sparc/mm/fault_64.c linux-3.1.4/arch/sparc/m= m/fault_64.c ---- linux-3.1.4/arch/sparc/mm/fault_64.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/sparc/mm/fault_64.c 2011-11-16 18:40:08.000000000 -= 0500 +diff --git a/arch/sparc/mm/fault_64.c b/arch/sparc/mm/fault_64.c +index 504c062..6fcb9c6 100644 +--- a/arch/sparc/mm/fault_64.c ++++ b/arch/sparc/mm/fault_64.c @@ -21,6 +21,9 @@ #include #include @@ -4379,7 +4862,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/fault_64.c lin= ux-3.1.4/arch/sparc/mm/fault_ =20 #include #include -@@ -74,7 +77,7 @@ static void __kprobes bad_kernel_pc(stru +@@ -74,7 +77,7 @@ static void __kprobes bad_kernel_pc(struct pt_regs *re= gs, unsigned long vaddr) printk(KERN_CRIT "OOPS: Bogus kernel PC [%016lx] in fault handler\n", regs->tpc); printk(KERN_CRIT "OOPS: RPC [%016lx]\n", regs->u_regs[15]); @@ -4388,7 +4871,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/fault_64.c lin= ux-3.1.4/arch/sparc/mm/fault_ printk(KERN_CRIT "OOPS: Fault was to vaddr[%lx]\n", vaddr); dump_stack(); unhandled_fault(regs->tpc, current, regs); -@@ -272,6 +275,457 @@ static void noinline __kprobes bogus_32b +@@ -272,6 +275,457 @@ static void noinline __kprobes bogus_32bit_fault_a= ddress(struct pt_regs *regs, show_regs(regs); } =20 @@ -4846,7 +5329,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/fault_64.c lin= ux-3.1.4/arch/sparc/mm/fault_ asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs) { struct mm_struct *mm =3D current->mm; -@@ -340,6 +794,29 @@ asmlinkage void __kprobes do_sparc64_fau +@@ -340,6 +794,29 @@ asmlinkage void __kprobes do_sparc64_fault(struct p= t_regs *regs) if (!vma) goto bad_area; =20 @@ -4876,9 +5359,10 @@ diff -urNp linux-3.1.4/arch/sparc/mm/fault_64.c li= nux-3.1.4/arch/sparc/mm/fault_ /* Pure DTLB misses do not tell us whether the fault causing * load/store/atomic was a write or not, it only says that there * was no match. So in such a case we (carefully) read the -diff -urNp linux-3.1.4/arch/sparc/mm/hugetlbpage.c linux-3.1.4/arch/spar= c/mm/hugetlbpage.c ---- linux-3.1.4/arch/sparc/mm/hugetlbpage.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/sparc/mm/hugetlbpage.c 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/sparc/mm/hugetlbpage.c b/arch/sparc/mm/hugetlbpage.c +index f4e9764..5682724 100644 +--- a/arch/sparc/mm/hugetlbpage.c ++++ b/arch/sparc/mm/hugetlbpage.c @@ -68,7 +68,7 @@ full_search: } return -ENOMEM; @@ -4888,7 +5372,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/hugetlbpage.c = linux-3.1.4/arch/sparc/mm/hug /* * Remember the place where we stopped the search: */ -@@ -107,7 +107,7 @@ hugetlb_get_unmapped_area_topdown(struct +@@ -107,7 +107,7 @@ hugetlb_get_unmapped_area_topdown(struct file *filp,= const unsigned long addr0, /* make sure it can fit in the remaining address space */ if (likely(addr > len)) { vma =3D find_vma(mm, addr-len); @@ -4897,7 +5381,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/hugetlbpage.c = linux-3.1.4/arch/sparc/mm/hug /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -116,16 +116,17 @@ hugetlb_get_unmapped_area_topdown(struct +@@ -116,16 +116,17 @@ hugetlb_get_unmapped_area_topdown(struct file *fil= p, const unsigned long addr0, if (unlikely(mm->mmap_base < len)) goto bottomup; =20 @@ -4917,7 +5401,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/hugetlbpage.c = linux-3.1.4/arch/sparc/mm/hug /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); } -@@ -135,8 +136,8 @@ hugetlb_get_unmapped_area_topdown(struct +@@ -135,8 +136,8 @@ hugetlb_get_unmapped_area_topdown(struct file *filp,= const unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -4928,7 +5412,7 @@ diff -urNp linux-3.1.4/arch/sparc/mm/hugetlbpage.c = linux-3.1.4/arch/sparc/mm/hug =20 bottomup: /* -@@ -182,8 +183,7 @@ hugetlb_get_unmapped_area(struct file *f +@@ -182,8 +183,7 @@ hugetlb_get_unmapped_area(struct file *file, unsigne= d long addr, if (addr) { addr =3D ALIGN(addr, HPAGE_SIZE); vma =3D find_vma(mm, addr); @@ -4938,9 +5422,10 @@ diff -urNp linux-3.1.4/arch/sparc/mm/hugetlbpage.c= linux-3.1.4/arch/sparc/mm/hug return addr; } if (mm->get_unmapped_area =3D=3D arch_get_unmapped_area) -diff -urNp linux-3.1.4/arch/sparc/mm/init_32.c linux-3.1.4/arch/sparc/mm= /init_32.c ---- linux-3.1.4/arch/sparc/mm/init_32.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/sparc/mm/init_32.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/sparc/mm/init_32.c b/arch/sparc/mm/init_32.c +index 7b00de6..78239f4 100644 +--- a/arch/sparc/mm/init_32.c ++++ b/arch/sparc/mm/init_32.c @@ -316,6 +316,9 @@ extern void device_scan(void); pgprot_t PAGE_SHARED __read_mostly; EXPORT_SYMBOL(PAGE_SHARED); @@ -4975,21 +5460,10 @@ diff -urNp linux-3.1.4/arch/sparc/mm/init_32.c li= nux-3.1.4/arch/sparc/mm/init_32 protection_map[12] =3D PAGE_READONLY; protection_map[13] =3D PAGE_READONLY; protection_map[14] =3D PAGE_SHARED; -diff -urNp linux-3.1.4/arch/sparc/mm/Makefile linux-3.1.4/arch/sparc/mm/= Makefile ---- linux-3.1.4/arch/sparc/mm/Makefile 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/sparc/mm/Makefile 2011-11-16 18:39:07.000000000 -05= 00 -@@ -2,7 +2,7 @@ - # -=20 - asflags-y :=3D -ansi --ccflags-y :=3D -Werror -+#ccflags-y :=3D -Werror -=20 - obj-$(CONFIG_SPARC64) +=3D ultra.o tlb.o tsb.o gup.o - obj-y +=3D fault_$(BITS).o -diff -urNp linux-3.1.4/arch/sparc/mm/srmmu.c linux-3.1.4/arch/sparc/mm/s= rmmu.c ---- linux-3.1.4/arch/sparc/mm/srmmu.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/sparc/mm/srmmu.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/arch/sparc/mm/srmmu.c b/arch/sparc/mm/srmmu.c +index cbef74e..c38fead 100644 +--- a/arch/sparc/mm/srmmu.c ++++ b/arch/sparc/mm/srmmu.c @@ -2200,6 +2200,13 @@ void __init ld_mmu_srmmu(void) PAGE_SHARED =3D pgprot_val(SRMMU_PAGE_SHARED); BTFIXUPSET_INT(page_copy, pgprot_val(SRMMU_PAGE_COPY)); @@ -5004,9 +5478,25 @@ diff -urNp linux-3.1.4/arch/sparc/mm/srmmu.c linux= -3.1.4/arch/sparc/mm/srmmu.c BTFIXUPSET_INT(page_kernel, pgprot_val(SRMMU_PAGE_KERNEL)); page_kernel =3D pgprot_val(SRMMU_PAGE_KERNEL); =20 -diff -urNp linux-3.1.4/arch/um/include/asm/kmap_types.h linux-3.1.4/arch= /um/include/asm/kmap_types.h ---- linux-3.1.4/arch/um/include/asm/kmap_types.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/um/include/asm/kmap_types.h 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/arch/um/Makefile b/arch/um/Makefile +index c0f712c..3a5c4c9 100644 +--- a/arch/um/Makefile ++++ b/arch/um/Makefile +@@ -49,6 +49,10 @@ USER_CFLAGS =3D $(patsubst $(KERNEL_DEFINES),,$(patsu= bst -D__KERNEL__,,\ + $(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \ + $(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=3D64 +=20 ++ifdef CONSTIFY_PLUGIN ++USER_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-con= stify ++endif ++ + include $(srctree)/$(ARCH_DIR)/Makefile-$(SUBARCH) +=20 + #This will adjust *FLAGS accordingly to the platform. +diff --git a/arch/um/include/asm/kmap_types.h b/arch/um/include/asm/kmap= _types.h +index 6c03acd..a5e0215 100644 +--- a/arch/um/include/asm/kmap_types.h ++++ b/arch/um/include/asm/kmap_types.h @@ -23,6 +23,7 @@ enum km_type { KM_IRQ1, KM_SOFTIRQ0, @@ -5015,9 +5505,10 @@ diff -urNp linux-3.1.4/arch/um/include/asm/kmap_ty= pes.h linux-3.1.4/arch/um/incl KM_TYPE_NR }; =20 -diff -urNp linux-3.1.4/arch/um/include/asm/page.h linux-3.1.4/arch/um/in= clude/asm/page.h ---- linux-3.1.4/arch/um/include/asm/page.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/um/include/asm/page.h 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/um/include/asm/page.h b/arch/um/include/asm/page.h +index 4cc9b6c..02e5029 100644 +--- a/arch/um/include/asm/page.h ++++ b/arch/um/include/asm/page.h @@ -14,6 +14,9 @@ #define PAGE_SIZE (_AC(1, UL) << PAGE_SHIFT) #define PAGE_MASK (~(PAGE_SIZE-1)) @@ -5028,9 +5519,10 @@ diff -urNp linux-3.1.4/arch/um/include/asm/page.h = linux-3.1.4/arch/um/include/as #ifndef __ASSEMBLY__ =20 struct page; -diff -urNp linux-3.1.4/arch/um/kernel/process.c linux-3.1.4/arch/um/kern= el/process.c ---- linux-3.1.4/arch/um/kernel/process.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/um/kernel/process.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/arch/um/kernel/process.c b/arch/um/kernel/process.c +index 21c1ae7..4640aaa 100644 +--- a/arch/um/kernel/process.c ++++ b/arch/um/kernel/process.c @@ -404,22 +404,6 @@ int singlestepping(void * t) return 2; } @@ -5054,23 +5546,10 @@ diff -urNp linux-3.1.4/arch/um/kernel/process.c l= inux-3.1.4/arch/um/kernel/proce unsigned long get_wchan(struct task_struct *p) { unsigned long stack_page, sp, ip; -diff -urNp linux-3.1.4/arch/um/Makefile linux-3.1.4/arch/um/Makefile ---- linux-3.1.4/arch/um/Makefile 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/um/Makefile 2011-11-16 18:39:07.000000000 -0500 -@@ -49,6 +49,10 @@ USER_CFLAGS =3D $(patsubst $(KERNEL_DEFINE - $(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \ - $(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=3D64 -=20 -+ifdef CONSTIFY_PLUGIN -+USER_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-con= stify -+endif -+ - include $(srctree)/$(ARCH_DIR)/Makefile-$(SUBARCH) -=20 - #This will adjust *FLAGS accordingly to the platform. -diff -urNp linux-3.1.4/arch/um/sys-i386/shared/sysdep/system.h linux-3.1= .4/arch/um/sys-i386/shared/sysdep/system.h ---- linux-3.1.4/arch/um/sys-i386/shared/sysdep/system.h 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/um/sys-i386/shared/sysdep/system.h 2011-11-16 18:39= :07.000000000 -0500 +diff --git a/arch/um/sys-i386/shared/sysdep/system.h b/arch/um/sys-i386/= shared/sysdep/system.h +index d1b93c4..ae1b7fd 100644 +--- a/arch/um/sys-i386/shared/sysdep/system.h ++++ b/arch/um/sys-i386/shared/sysdep/system.h @@ -17,7 +17,7 @@ # define AT_VECTOR_SIZE_ARCH 1 #endif @@ -5080,9 +5559,10 @@ diff -urNp linux-3.1.4/arch/um/sys-i386/shared/sys= dep/system.h linux-3.1.4/arch/ =20 void default_idle(void); =20 -diff -urNp linux-3.1.4/arch/um/sys-i386/syscalls.c linux-3.1.4/arch/um/s= ys-i386/syscalls.c ---- linux-3.1.4/arch/um/sys-i386/syscalls.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/um/sys-i386/syscalls.c 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/um/sys-i386/syscalls.c b/arch/um/sys-i386/syscalls.c +index 70ca357..728d1cc 100644 +--- a/arch/um/sys-i386/syscalls.c ++++ b/arch/um/sys-i386/syscalls.c @@ -11,6 +11,21 @@ #include "asm/uaccess.h" #include "asm/unistd.h" @@ -5105,9 +5585,10 @@ diff -urNp linux-3.1.4/arch/um/sys-i386/syscalls.c= linux-3.1.4/arch/um/sys-i386/ /* * The prototype on i386 is: * -diff -urNp linux-3.1.4/arch/um/sys-x86_64/shared/sysdep/system.h linux-3= .1.4/arch/um/sys-x86_64/shared/sysdep/system.h ---- linux-3.1.4/arch/um/sys-x86_64/shared/sysdep/system.h 2011-11-11 15:= 19:27.000000000 -0500 -+++ linux-3.1.4/arch/um/sys-x86_64/shared/sysdep/system.h 2011-11-16 18:= 39:07.000000000 -0500 +diff --git a/arch/um/sys-x86_64/shared/sysdep/system.h b/arch/um/sys-x86= _64/shared/sysdep/system.h +index d1b93c4..ae1b7fd 100644 +--- a/arch/um/sys-x86_64/shared/sysdep/system.h ++++ b/arch/um/sys-x86_64/shared/sysdep/system.h @@ -17,7 +17,7 @@ # define AT_VECTOR_SIZE_ARCH 1 #endif @@ -5117,10 +5598,179 @@ diff -urNp linux-3.1.4/arch/um/sys-x86_64/shared= /sysdep/system.h linux-3.1.4/arc =20 void default_idle(void); =20 -diff -urNp linux-3.1.4/arch/x86/boot/bitops.h linux-3.1.4/arch/x86/boot/= bitops.h ---- linux-3.1.4/arch/x86/boot/bitops.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/boot/bitops.h 2011-11-16 18:39:07.000000000 -05= 00 -@@ -26,7 +26,7 @@ static inline int variable_test_bit(int=20 +diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig +index 6a47bb2..dc9a868 100644 +--- a/arch/x86/Kconfig ++++ b/arch/x86/Kconfig +@@ -236,7 +236,7 @@ config X86_HT +=20 + config X86_32_LAZY_GS + def_bool y +- depends on X86_32 && !CC_STACKPROTECTOR ++ depends on X86_32 && !CC_STACKPROTECTOR && !PAX_MEMORY_UDEREF +=20 + config ARCH_HWEIGHT_CFLAGS + string +@@ -1019,7 +1019,7 @@ choice +=20 + config NOHIGHMEM + bool "off" +- depends on !X86_NUMAQ ++ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) + ---help--- + Linux can use up to 64 Gigabytes of physical memory on x86 systems. + However, the address space of 32-bit x86 processors is only 4 +@@ -1056,7 +1056,7 @@ config NOHIGHMEM +=20 + config HIGHMEM4G + bool "4GB" +- depends on !X86_NUMAQ ++ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) + ---help--- + Select this if you have a 32-bit processor and between 1 and 4 + gigabytes of physical RAM. +@@ -1110,7 +1110,7 @@ config PAGE_OFFSET + hex + default 0xB0000000 if VMSPLIT_3G_OPT + default 0x80000000 if VMSPLIT_2G +- default 0x78000000 if VMSPLIT_2G_OPT ++ default 0x70000000 if VMSPLIT_2G_OPT + default 0x40000000 if VMSPLIT_1G + default 0xC0000000 + depends on X86_32 +@@ -1484,6 +1484,7 @@ config SECCOMP +=20 + config CC_STACKPROTECTOR + bool "Enable -fstack-protector buffer overflow detection (EXPERIMENTAL= )" ++ depends on X86_64 || !PAX_MEMORY_UDEREF + ---help--- + This option turns on the -fstack-protector GCC feature. This + feature puts, at the beginning of functions, a canary value on +@@ -1541,6 +1542,7 @@ config KEXEC_JUMP + config PHYSICAL_START + hex "Physical address where the kernel is loaded" if (EXPERT || CRASH_= DUMP) + default "0x1000000" ++ range 0x400000 0x40000000 + ---help--- + This gives the physical address where the kernel is loaded. +=20 +@@ -1604,6 +1606,7 @@ config X86_NEED_RELOCS + config PHYSICAL_ALIGN + hex "Alignment value to which kernel should be aligned" if X86_32 + default "0x1000000" ++ range 0x400000 0x1000000 if PAX_KERNEXEC + range 0x2000 0x1000000 + ---help--- + This value puts the alignment restrictions on physical address +@@ -1635,9 +1638,10 @@ config HOTPLUG_CPU + Say N if you want to disable CPU hotplug. +=20 + config COMPAT_VDSO +- def_bool y ++ def_bool n + prompt "Compat VDSO support" + depends on X86_32 || IA32_EMULATION ++ depends on !PAX_NOEXEC && !PAX_MEMORY_UDEREF + ---help--- + Map the 32-bit VDSO to the predictable old-style address too. +=20 +diff --git a/arch/x86/Kconfig.cpu b/arch/x86/Kconfig.cpu +index e3ca7e0..b30b28a 100644 +--- a/arch/x86/Kconfig.cpu ++++ b/arch/x86/Kconfig.cpu +@@ -341,7 +341,7 @@ config X86_PPRO_FENCE +=20 + config X86_F00F_BUG + def_bool y +- depends on M586MMX || M586TSC || M586 || M486 || M386 ++ depends on (M586MMX || M586TSC || M586 || M486 || M386) && !PAX_KERNEX= EC +=20 + config X86_INVD_BUG + def_bool y +@@ -365,7 +365,7 @@ config X86_POPAD_OK +=20 + config X86_ALIGNMENT_16 + def_bool y +- depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MELAN || MK6 || M5= 86MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 ++ depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || X86_ELAN || MK8 ||= MK7 || MK6 || MCORE2 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 |= | M586MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 +=20 + config X86_INTEL_USERCOPY + def_bool y +@@ -411,7 +411,7 @@ config X86_CMPXCHG64 + # generates cmov. + config X86_CMOV + def_bool y +- depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUM= III || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEFFICEON |= | X86_64 || MATOM || MGEODE_LX) ++ depends on (MK8 || MK7 || MCORE2 || MPSC || MPENTIUM4 || MPENTIUMM || = MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEF= FICEON || X86_64 || MATOM || MGEODE_LX) +=20 + config X86_MINIMUM_CPU_FAMILY + int +diff --git a/arch/x86/Kconfig.debug b/arch/x86/Kconfig.debug +index c0f8a5c..6404f61 100644 +--- a/arch/x86/Kconfig.debug ++++ b/arch/x86/Kconfig.debug +@@ -81,7 +81,7 @@ config X86_PTDUMP + config DEBUG_RODATA + bool "Write protect kernel read-only data structures" + default y +- depends on DEBUG_KERNEL ++ depends on DEBUG_KERNEL && BROKEN + ---help--- + Mark the kernel read-only data as write-protected in the pagetables, + in order to catch accidental (and incorrect) writes to such const +@@ -99,7 +99,7 @@ config DEBUG_RODATA_TEST +=20 + config DEBUG_SET_MODULE_RONX + bool "Set loadable kernel module data as NX and text as RO" +- depends on MODULES ++ depends on MODULES && BROKEN + ---help--- + 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 b02e509..2631e48 100644 +--- a/arch/x86/Makefile ++++ b/arch/x86/Makefile +@@ -46,6 +46,7 @@ else + UTS_MACHINE :=3D x86_64 + CHECKFLAGS +=3D -D__x86_64__ -m64 +=20 ++ biarch :=3D $(call cc-option,-m64) + KBUILD_AFLAGS +=3D -m64 + KBUILD_CFLAGS +=3D -m64 +=20 +@@ -195,3 +196,12 @@ define archhelp + echo ' FDARGS=3D"..." arguments for the booted ker= nel' + echo ' FDINITRD=3Dfile initrd for the booted kernel= ' + endef ++ ++define OLD_LD ++ ++*** ${VERSION}.${PATCHLEVEL} PaX kernels no longer build correctly with= old versions of binutils. ++*** Please upgrade your binutils to 2.18 or newer ++endef ++ ++archprepare: ++ $(if $(LDFLAGS_BUILD_ID),,$(error $(OLD_LD))) +diff --git a/arch/x86/boot/Makefile b/arch/x86/boot/Makefile +index 95365a8..52f857b 100644 +--- a/arch/x86/boot/Makefile ++++ b/arch/x86/boot/Makefile +@@ -63,6 +63,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os -D_SETUP -D_= _KERNEL__ \ + $(call cc-option, -fno-stack-protector) \ + $(call cc-option, -mpreferred-stack-boundary=3D2) + KBUILD_CFLAGS +=3D $(call cc-option, -m32) ++ifdef CONSTIFY_PLUGIN ++KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify ++endif + KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ + GCOV_PROFILE :=3D n +=20 +diff --git a/arch/x86/boot/bitops.h b/arch/x86/boot/bitops.h +index 878e4b9..20537ab 100644 +--- a/arch/x86/boot/bitops.h ++++ b/arch/x86/boot/bitops.h +@@ -26,7 +26,7 @@ static inline int variable_test_bit(int nr, const void= *addr) u8 v; const u32 *p =3D (const u32 *)addr; =20 @@ -5129,7 +5779,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/bitops.h linux= -3.1.4/arch/x86/boot/bitops.h return v; } =20 -@@ -37,7 +37,7 @@ static inline int variable_test_bit(int=20 +@@ -37,7 +37,7 @@ static inline int variable_test_bit(int nr, const void= *addr) =20 static inline void set_bit(int nr, void *addr) { @@ -5138,9 +5788,10 @@ diff -urNp linux-3.1.4/arch/x86/boot/bitops.h linu= x-3.1.4/arch/x86/boot/bitops.h } =20 #endif /* BOOT_BITOPS_H */ -diff -urNp linux-3.1.4/arch/x86/boot/boot.h linux-3.1.4/arch/x86/boot/bo= ot.h ---- linux-3.1.4/arch/x86/boot/boot.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/boot/boot.h 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/boot/boot.h b/arch/x86/boot/boot.h +index c7093bd..d4247ffe0 100644 +--- a/arch/x86/boot/boot.h ++++ b/arch/x86/boot/boot.h @@ -85,7 +85,7 @@ static inline void io_delay(void) static inline u16 ds(void) { @@ -5150,7 +5801,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/boot.h linux-3= .1.4/arch/x86/boot/boot.h return seg; } =20 -@@ -181,7 +181,7 @@ static inline void wrgs32(u32 v, addr_t=20 +@@ -181,7 +181,7 @@ static inline void wrgs32(u32 v, addr_t addr) static inline int memcmp(const void *s1, const void *s2, size_t len) { u8 diff; @@ -5159,9 +5810,24 @@ diff -urNp linux-3.1.4/arch/x86/boot/boot.h linux-= 3.1.4/arch/x86/boot/boot.h : "=3Dqm" (diff), "+D" (s1), "+S" (s2), "+c" (len)); return diff; } -diff -urNp linux-3.1.4/arch/x86/boot/compressed/head_32.S linux-3.1.4/ar= ch/x86/boot/compressed/head_32.S ---- linux-3.1.4/arch/x86/boot/compressed/head_32.S 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/boot/compressed/head_32.S 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compresse= d/Makefile +index 09664ef..edc5d03 100644 +--- a/arch/x86/boot/compressed/Makefile ++++ b/arch/x86/boot/compressed/Makefile +@@ -14,6 +14,9 @@ cflags-$(CONFIG_X86_64) :=3D -mcmodel=3Dsmall + KBUILD_CFLAGS +=3D $(cflags-y) + KBUILD_CFLAGS +=3D $(call cc-option,-ffreestanding) + KBUILD_CFLAGS +=3D $(call cc-option,-fno-stack-protector) ++ifdef CONSTIFY_PLUGIN ++KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify ++endif +=20 + KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ + GCOV_PROFILE :=3D n +diff --git a/arch/x86/boot/compressed/head_32.S b/arch/x86/boot/compress= ed/head_32.S +index 67a655a..b924059 100644 +--- a/arch/x86/boot/compressed/head_32.S ++++ b/arch/x86/boot/compressed/head_32.S @@ -76,7 +76,7 @@ ENTRY(startup_32) notl %eax andl %eax, %ebx @@ -5190,9 +5856,10 @@ diff -urNp linux-3.1.4/arch/x86/boot/compressed/he= ad_32.S linux-3.1.4/arch/x86/b addl %ebx, -__PAGE_OFFSET(%ebx, %ecx) jmp 1b 2: -diff -urNp linux-3.1.4/arch/x86/boot/compressed/head_64.S linux-3.1.4/ar= ch/x86/boot/compressed/head_64.S ---- linux-3.1.4/arch/x86/boot/compressed/head_64.S 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/boot/compressed/head_64.S 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/x86/boot/compressed/head_64.S b/arch/x86/boot/compress= ed/head_64.S +index 35af09d..99c9676 100644 +--- a/arch/x86/boot/compressed/head_64.S ++++ b/arch/x86/boot/compressed/head_64.S @@ -91,7 +91,7 @@ ENTRY(startup_32) notl %eax andl %eax, %ebx @@ -5211,22 +5878,10 @@ diff -urNp linux-3.1.4/arch/x86/boot/compressed/h= ead_64.S linux-3.1.4/arch/x86/b #endif =20 /* Target address to relocate to for decompression */ -diff -urNp linux-3.1.4/arch/x86/boot/compressed/Makefile linux-3.1.4/arc= h/x86/boot/compressed/Makefile ---- linux-3.1.4/arch/x86/boot/compressed/Makefile 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/boot/compressed/Makefile 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -14,6 +14,9 @@ cflags-$(CONFIG_X86_64) :=3D -mcmodel=3Dsmal - KBUILD_CFLAGS +=3D $(cflags-y) - KBUILD_CFLAGS +=3D $(call cc-option,-ffreestanding) - KBUILD_CFLAGS +=3D $(call cc-option,-fno-stack-protector) -+ifdef CONSTIFY_PLUGIN -+KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify -+endif -=20 - KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ - GCOV_PROFILE :=3D n -diff -urNp linux-3.1.4/arch/x86/boot/compressed/misc.c linux-3.1.4/arch/= x86/boot/compressed/misc.c ---- linux-3.1.4/arch/x86/boot/compressed/misc.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/boot/compressed/misc.c 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/= misc.c +index 3a19d04..7c1d55a 100644 +--- a/arch/x86/boot/compressed/misc.c ++++ b/arch/x86/boot/compressed/misc.c @@ -310,7 +310,7 @@ static void parse_elf(void *output) case PT_LOAD: #ifdef CONFIG_RELOCATABLE @@ -5236,7 +5891,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/compressed/mis= c.c linux-3.1.4/arch/x86/boot #else dest =3D (void *)(phdr->p_paddr); #endif -@@ -363,7 +363,7 @@ asmlinkage void decompress_kernel(void * +@@ -363,7 +363,7 @@ asmlinkage void decompress_kernel(void *rmode, mempt= r heap, error("Destination address too large"); #endif #ifndef CONFIG_RELOCATABLE @@ -5245,9 +5900,10 @@ diff -urNp linux-3.1.4/arch/x86/boot/compressed/mi= sc.c linux-3.1.4/arch/x86/boot error("Wrong destination address"); #endif =20 -diff -urNp linux-3.1.4/arch/x86/boot/compressed/relocs.c linux-3.1.4/arc= h/x86/boot/compressed/relocs.c ---- linux-3.1.4/arch/x86/boot/compressed/relocs.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/boot/compressed/relocs.c 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/arch/x86/boot/compressed/relocs.c b/arch/x86/boot/compresse= d/relocs.c +index 89bbf4e..869908e 100644 +--- a/arch/x86/boot/compressed/relocs.c ++++ b/arch/x86/boot/compressed/relocs.c @@ -13,8 +13,11 @@ =20 static void die(char *fmt, ...); @@ -5400,7 +6056,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/compressed/rel= ocs.c linux-3.1.4/arch/x86/bo struct section *sec =3D &secs[i]; =20 if (sec->shdr.sh_type !=3D SHT_REL) { -@@ -530,6 +574,22 @@ static void walk_relocs(void (*visit)(El +@@ -530,6 +574,22 @@ static void walk_relocs(void (*visit)(Elf32_Rel *re= l, Elf32_Sym *sym)) !is_rel_reloc(sym_name(sym_strtab, sym))) { continue; } @@ -5423,7 +6079,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/compressed/rel= ocs.c linux-3.1.4/arch/x86/bo switch (r_type) { case R_386_NONE: case R_386_PC32: -@@ -571,7 +631,7 @@ static int cmp_relocs(const void *va, co +@@ -571,7 +631,7 @@ static int cmp_relocs(const void *va, const void *vb= ) =20 static void emit_relocs(int as_text) { @@ -5440,9 +6096,10 @@ diff -urNp linux-3.1.4/arch/x86/boot/compressed/re= locs.c linux-3.1.4/arch/x86/bo read_shdrs(fp); read_strtabs(fp); read_symtabs(fp); -diff -urNp linux-3.1.4/arch/x86/boot/cpucheck.c linux-3.1.4/arch/x86/boo= t/cpucheck.c ---- linux-3.1.4/arch/x86/boot/cpucheck.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/boot/cpucheck.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/arch/x86/boot/cpucheck.c b/arch/x86/boot/cpucheck.c +index 4d3ff03..e4972ff 100644 +--- a/arch/x86/boot/cpucheck.c ++++ b/arch/x86/boot/cpucheck.c @@ -74,7 +74,7 @@ static int has_fpu(void) u16 fcw =3D -1, fsw =3D -1; u32 cr0; @@ -5497,7 +6154,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/cpucheck.c lin= ux-3.1.4/arch/x86/boot/cpuche : "+a" (eax), "=3Dc" (cpu.flags[6]), "=3Dd" (cpu.flags[1]) -@@ -203,9 +203,9 @@ int check_cpu(int *cpu_level_ptr, int *r +@@ -203,9 +203,9 @@ int check_cpu(int *cpu_level_ptr, int *req_level_ptr= , u32 **err_flags_ptr) u32 ecx =3D MSR_K7_HWCR; u32 eax, edx; =20 @@ -5509,7 +6166,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/cpucheck.c lin= ux-3.1.4/arch/x86/boot/cpuche =20 get_flags(); /* Make sure it really did something */ err =3D check_flags(); -@@ -218,9 +218,9 @@ int check_cpu(int *cpu_level_ptr, int *r +@@ -218,9 +218,9 @@ int check_cpu(int *cpu_level_ptr, int *req_level_ptr= , u32 **err_flags_ptr) u32 ecx =3D MSR_VIA_FCR; u32 eax, edx; =20 @@ -5521,7 +6178,7 @@ diff -urNp linux-3.1.4/arch/x86/boot/cpucheck.c lin= ux-3.1.4/arch/x86/boot/cpuche =20 set_bit(X86_FEATURE_CX8, cpu.flags); err =3D check_flags(); -@@ -231,12 +231,12 @@ int check_cpu(int *cpu_level_ptr, int *r +@@ -231,12 +231,12 @@ int check_cpu(int *cpu_level_ptr, int *req_level_p= tr, u32 **err_flags_ptr) u32 eax, edx; u32 level =3D 1; =20 @@ -5538,10 +6195,11 @@ diff -urNp linux-3.1.4/arch/x86/boot/cpucheck.c l= inux-3.1.4/arch/x86/boot/cpuche =20 err =3D check_flags(); } -diff -urNp linux-3.1.4/arch/x86/boot/header.S linux-3.1.4/arch/x86/boot/= header.S ---- linux-3.1.4/arch/x86/boot/header.S 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/boot/header.S 2011-11-16 18:39:07.000000000 -05= 00 -@@ -224,7 +224,7 @@ setup_data: .quad 0 # 64-bit physical +diff --git a/arch/x86/boot/header.S b/arch/x86/boot/header.S +index 93e689f..504ba09 100644 +--- a/arch/x86/boot/header.S ++++ b/arch/x86/boot/header.S +@@ -224,7 +224,7 @@ setup_data: .quad 0 # 64-bit physical pointer to # single linked list of # struct setup_data =20 @@ -5550,22 +6208,10 @@ diff -urNp linux-3.1.4/arch/x86/boot/header.S lin= ux-3.1.4/arch/x86/boot/header.S =20 #define ZO_INIT_SIZE (ZO__end - ZO_startup_32 + ZO_z_extract_offset) #define VO_INIT_SIZE (VO__end - VO__text) -diff -urNp linux-3.1.4/arch/x86/boot/Makefile linux-3.1.4/arch/x86/boot/= Makefile ---- linux-3.1.4/arch/x86/boot/Makefile 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/boot/Makefile 2011-11-16 18:39:07.000000000 -05= 00 -@@ -63,6 +63,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os=20 - $(call cc-option, -fno-stack-protector) \ - $(call cc-option, -mpreferred-stack-boundary=3D2) - KBUILD_CFLAGS +=3D $(call cc-option, -m32) -+ifdef CONSTIFY_PLUGIN -+KBUILD_CFLAGS +=3D $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-c= onstify -+endif - KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ - GCOV_PROFILE :=3D n -=20 -diff -urNp linux-3.1.4/arch/x86/boot/memory.c linux-3.1.4/arch/x86/boot/= memory.c ---- linux-3.1.4/arch/x86/boot/memory.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/boot/memory.c 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/boot/memory.c b/arch/x86/boot/memory.c +index db75d07..8e6d0af 100644 +--- a/arch/x86/boot/memory.c ++++ b/arch/x86/boot/memory.c @@ -19,7 +19,7 @@ =20 static int detect_memory_e820(void) @@ -5575,9 +6221,22 @@ diff -urNp linux-3.1.4/arch/x86/boot/memory.c linu= x-3.1.4/arch/x86/boot/memory.c struct biosregs ireg, oreg; struct e820entry *desc =3D boot_params.e820_map; static struct e820entry buf; /* static so it is zeroed */ -diff -urNp linux-3.1.4/arch/x86/boot/video.c linux-3.1.4/arch/x86/boot/v= ideo.c ---- linux-3.1.4/arch/x86/boot/video.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/boot/video.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/arch/x86/boot/video-vesa.c b/arch/x86/boot/video-vesa.c +index 11e8c6e..fdbb1ed 100644 +--- a/arch/x86/boot/video-vesa.c ++++ b/arch/x86/boot/video-vesa.c +@@ -200,6 +200,7 @@ static void vesa_store_pm_info(void) +=20 + boot_params.screen_info.vesapm_seg =3D oreg.es; + boot_params.screen_info.vesapm_off =3D oreg.di; ++ boot_params.screen_info.vesapm_size =3D oreg.cx; + } +=20 + /* +diff --git a/arch/x86/boot/video.c b/arch/x86/boot/video.c +index 43eda28..5ab5fdb 100644 +--- a/arch/x86/boot/video.c ++++ b/arch/x86/boot/video.c @@ -96,7 +96,7 @@ static void store_mode_params(void) static unsigned int get_entry(void) { @@ -5587,20 +6246,32 @@ diff -urNp linux-3.1.4/arch/x86/boot/video.c linu= x-3.1.4/arch/x86/boot/video.c int key; unsigned int v; =20 -diff -urNp linux-3.1.4/arch/x86/boot/video-vesa.c linux-3.1.4/arch/x86/b= oot/video-vesa.c ---- linux-3.1.4/arch/x86/boot/video-vesa.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/boot/video-vesa.c 2011-11-16 18:39:07.000000000= -0500 -@@ -200,6 +200,7 @@ static void vesa_store_pm_info(void) +diff --git a/arch/x86/crypto/aes-x86_64-asm_64.S b/arch/x86/crypto/aes-x= 86_64-asm_64.S +index 5b577d5..3c1fed4 100644 +--- a/arch/x86/crypto/aes-x86_64-asm_64.S ++++ b/arch/x86/crypto/aes-x86_64-asm_64.S +@@ -8,6 +8,8 @@ + * including this sentence is retained in full. + */ =20 - boot_params.screen_info.vesapm_seg =3D oreg.es; - boot_params.screen_info.vesapm_off =3D oreg.di; -+ boot_params.screen_info.vesapm_size =3D oreg.cx; - } ++#include ++ + .extern crypto_ft_tab + .extern crypto_it_tab + .extern crypto_fl_tab +@@ -71,6 +73,8 @@ FUNC: movq r1,r2; \ + je B192; \ + leaq 32(r9),r9; =20 - /* -diff -urNp linux-3.1.4/arch/x86/crypto/aesni-intel_asm.S linux-3.1.4/arc= h/x86/crypto/aesni-intel_asm.S ---- linux-3.1.4/arch/x86/crypto/aesni-intel_asm.S 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/crypto/aesni-intel_asm.S 2011-12-02 17:38:47.00= 0000000 -0500 ++#define ret pax_force_retaddr 0, 1; ret ++ + #define epilogue(r1,r2,r3,r4,r5,r6,r7,r8,r9) \ + movq r1,r2; \ + movq r3,r4; \ +diff --git a/arch/x86/crypto/aesni-intel_asm.S b/arch/x86/crypto/aesni-i= ntel_asm.S +index be6d9e3..21fbbca 100644 +--- a/arch/x86/crypto/aesni-intel_asm.S ++++ b/arch/x86/crypto/aesni-intel_asm.S @@ -31,6 +31,7 @@ =20 #include @@ -5787,30 +6458,10 @@ diff -urNp linux-3.1.4/arch/x86/crypto/aesni-inte= l_asm.S linux-3.1.4/arch/x86/cr ret +ENDPROC(aesni_ctr_enc) #endif -diff -urNp linux-3.1.4/arch/x86/crypto/aes-x86_64-asm_64.S linux-3.1.4/a= rch/x86/crypto/aes-x86_64-asm_64.S ---- linux-3.1.4/arch/x86/crypto/aes-x86_64-asm_64.S 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/x86/crypto/aes-x86_64-asm_64.S 2011-12-02 17:38:47.= 000000000 -0500 -@@ -8,6 +8,8 @@ - * including this sentence is retained in full. - */ -=20 -+#include -+ - .extern crypto_ft_tab - .extern crypto_it_tab - .extern crypto_fl_tab -@@ -71,6 +73,8 @@ FUNC: movq r1,r2; \ - je B192; \ - leaq 32(r9),r9; -=20 -+#define ret pax_force_retaddr 0, 1; ret -+ - #define epilogue(r1,r2,r3,r4,r5,r6,r7,r8,r9) \ - movq r1,r2; \ - movq r3,r4; \ -diff -urNp linux-3.1.4/arch/x86/crypto/salsa20-x86_64-asm_64.S linux-3.1= .4/arch/x86/crypto/salsa20-x86_64-asm_64.S ---- linux-3.1.4/arch/x86/crypto/salsa20-x86_64-asm_64.S 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/x86/crypto/salsa20-x86_64-asm_64.S 2011-12-02 17:38= :47.000000000 -0500 +diff --git a/arch/x86/crypto/salsa20-x86_64-asm_64.S b/arch/x86/crypto/s= alsa20-x86_64-asm_64.S +index 6214a9b..1f4fc9a 100644 +--- a/arch/x86/crypto/salsa20-x86_64-asm_64.S ++++ b/arch/x86/crypto/salsa20-x86_64-asm_64.S @@ -1,3 +1,5 @@ +#include + @@ -5839,9 +6490,10 @@ diff -urNp linux-3.1.4/arch/x86/crypto/salsa20-x86= _64-asm_64.S linux-3.1.4/arch/ mov %rsi,%rdx + pax_force_retaddr ret -diff -urNp linux-3.1.4/arch/x86/crypto/twofish-x86_64-asm_64.S linux-3.1= .4/arch/x86/crypto/twofish-x86_64-asm_64.S ---- linux-3.1.4/arch/x86/crypto/twofish-x86_64-asm_64.S 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/x86/crypto/twofish-x86_64-asm_64.S 2011-12-02 17:38= :47.000000000 -0500 +diff --git a/arch/x86/crypto/twofish-x86_64-asm_64.S b/arch/x86/crypto/t= wofish-x86_64-asm_64.S +index 573aa10..b73ad89 100644 +--- a/arch/x86/crypto/twofish-x86_64-asm_64.S ++++ b/arch/x86/crypto/twofish-x86_64-asm_64.S @@ -21,6 +21,7 @@ .text =20 @@ -5864,10 +6516,11 @@ diff -urNp linux-3.1.4/arch/x86/crypto/twofish-x8= 6_64-asm_64.S linux-3.1.4/arch/ movq $1,%rax + pax_force_retaddr 0, 1 ret -diff -urNp linux-3.1.4/arch/x86/ia32/ia32_aout.c linux-3.1.4/arch/x86/ia= 32/ia32_aout.c ---- linux-3.1.4/arch/x86/ia32/ia32_aout.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/ia32/ia32_aout.c 2011-11-16 18:40:08.000000000 = -0500 -@@ -162,6 +162,8 @@ static int aout_core_dump(long signr, st +diff --git a/arch/x86/ia32/ia32_aout.c b/arch/x86/ia32/ia32_aout.c +index fd84387..0b4af7d 100644 +--- a/arch/x86/ia32/ia32_aout.c ++++ b/arch/x86/ia32/ia32_aout.c +@@ -162,6 +162,8 @@ static int aout_core_dump(long signr, struct pt_regs= *regs, struct file *file, unsigned long dump_start, dump_size; struct user32 dump; =20 @@ -5876,9 +6529,90 @@ diff -urNp linux-3.1.4/arch/x86/ia32/ia32_aout.c l= inux-3.1.4/arch/x86/ia32/ia32_ fs =3D get_fs(); set_fs(KERNEL_DS); has_dumped =3D 1; -diff -urNp linux-3.1.4/arch/x86/ia32/ia32entry.S linux-3.1.4/arch/x86/ia= 32/ia32entry.S ---- linux-3.1.4/arch/x86/ia32/ia32entry.S 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/ia32/ia32entry.S 2011-12-02 17:38:47.000000000 = -0500 +diff --git a/arch/x86/ia32/ia32_signal.c b/arch/x86/ia32/ia32_signal.c +index 6557769..ef6ae89 100644 +--- a/arch/x86/ia32/ia32_signal.c ++++ b/arch/x86/ia32/ia32_signal.c +@@ -169,7 +169,7 @@ asmlinkage long sys32_sigaltstack(const stack_ia32_t= __user *uss_ptr, + } + seg =3D get_fs(); + set_fs(KERNEL_DS); +- ret =3D do_sigaltstack(uss_ptr ? &uss : NULL, &uoss, regs->sp); ++ ret =3D do_sigaltstack(uss_ptr ? (const stack_t __force_user *)&uss : = NULL, (stack_t __force_user *)&uoss, regs->sp); + set_fs(seg); + if (ret >=3D 0 && uoss_ptr) { + if (!access_ok(VERIFY_WRITE, uoss_ptr, sizeof(stack_ia32_t))) +@@ -370,7 +370,7 @@ static int ia32_setup_sigcontext(struct sigcontext_i= a32 __user *sc, + */ + static void __user *get_sigframe(struct k_sigaction *ka, struct pt_regs= *regs, + size_t frame_size, +- void **fpstate) ++ void __user **fpstate) + { + unsigned long sp; +=20 +@@ -391,7 +391,7 @@ static void __user *get_sigframe(struct k_sigaction = *ka, struct pt_regs *regs, +=20 + if (used_math()) { + sp =3D sp - sig_xstate_ia32_size; +- *fpstate =3D (struct _fpstate_ia32 *) sp; ++ *fpstate =3D (struct _fpstate_ia32 __user *) sp; + if (save_i387_xstate_ia32(*fpstate) < 0) + return (void __user *) -1L; + } +@@ -399,7 +399,7 @@ static void __user *get_sigframe(struct k_sigaction = *ka, struct pt_regs *regs, + sp -=3D frame_size; + /* Align the stack pointer according to the i386 ABI, + * i.e. so that on function entry ((sp + 4) & 15) =3D=3D 0. */ +- sp =3D ((sp + 4) & -16ul) - 4; ++ sp =3D ((sp - 12) & -16ul) - 4; + return (void __user *) sp; + } +=20 +@@ -457,7 +457,7 @@ int ia32_setup_frame(int sig, struct k_sigaction *ka= , + * These are actually not used anymore, but left because some + * gdb versions depend on them as a marker. + */ +- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); ++ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); + } put_user_catch(err); +=20 + if (err) +@@ -499,7 +499,7 @@ int ia32_setup_rt_frame(int sig, struct k_sigaction = *ka, siginfo_t *info, + 0xb8, + __NR_ia32_rt_sigreturn, + 0x80cd, +- 0, ++ 0 + }; +=20 + frame =3D get_sigframe(ka, regs, sizeof(*frame), &fpstate); +@@ -529,16 +529,18 @@ int ia32_setup_rt_frame(int sig, struct k_sigactio= n *ka, siginfo_t *info, +=20 + if (ka->sa.sa_flags & SA_RESTORER) + restorer =3D ka->sa.sa_restorer; ++ else if (current->mm->context.vdso) ++ /* Return stub is in 32bit vsyscall page */ ++ restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, rt_sigreturn); + else +- restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, +- rt_sigreturn); ++ restorer =3D &frame->retcode; + put_user_ex(ptr_to_compat(restorer), &frame->pretcode); +=20 + /* + * Not actually used anymore, but left because some gdb + * versions need it. + */ +- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); ++ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); + } put_user_catch(err); +=20 + if (err) +diff --git a/arch/x86/ia32/ia32entry.S b/arch/x86/ia32/ia32entry.S +index 54edb207..9335b5f 100644 +--- a/arch/x86/ia32/ia32entry.S ++++ b/arch/x86/ia32/ia32entry.S @@ -13,7 +13,9 @@ #include =09 #include @@ -6164,7 +6898,7 @@ diff -urNp linux-3.1.4/arch/x86/ia32/ia32entry.S li= nux-3.1.4/arch/x86/ia32/ia32e jnz ia32_tracesys cmpq $(IA32_NR_syscalls-1),%rax ja ia32_badsys -@@ -441,6 +495,9 @@ ia32_tracesys: =20 +@@ -441,6 +495,9 @@ ia32_tracesys: movq $-ENOSYS,RAX(%rsp) /* ptrace can change this for a bad syscall */ movq %rsp,%rdi /* &pt_regs -> arg1 */ call syscall_trace_enter @@ -6182,89 +6916,11 @@ diff -urNp linux-3.1.4/arch/x86/ia32/ia32entry.S = linux-3.1.4/arch/x86/ia32/ia32e ret CFI_ENDPROC =09 -diff -urNp linux-3.1.4/arch/x86/ia32/ia32_signal.c linux-3.1.4/arch/x86/= ia32/ia32_signal.c ---- linux-3.1.4/arch/x86/ia32/ia32_signal.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/ia32/ia32_signal.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -169,7 +169,7 @@ asmlinkage long sys32_sigaltstack(const=20 - } - seg =3D get_fs(); - set_fs(KERNEL_DS); -- ret =3D do_sigaltstack(uss_ptr ? &uss : NULL, &uoss, regs->sp); -+ ret =3D do_sigaltstack(uss_ptr ? (const stack_t __force_user *)&uss : = NULL, (stack_t __force_user *)&uoss, regs->sp); - set_fs(seg); - if (ret >=3D 0 && uoss_ptr) { - if (!access_ok(VERIFY_WRITE, uoss_ptr, sizeof(stack_ia32_t))) -@@ -370,7 +370,7 @@ static int ia32_setup_sigcontext(struct=20 - */ - static void __user *get_sigframe(struct k_sigaction *ka, struct pt_regs= *regs, - size_t frame_size, -- void **fpstate) -+ void __user **fpstate) - { - unsigned long sp; -=20 -@@ -391,7 +391,7 @@ static void __user *get_sigframe(struct=20 -=20 - if (used_math()) { - sp =3D sp - sig_xstate_ia32_size; -- *fpstate =3D (struct _fpstate_ia32 *) sp; -+ *fpstate =3D (struct _fpstate_ia32 __user *) sp; - if (save_i387_xstate_ia32(*fpstate) < 0) - return (void __user *) -1L; - } -@@ -399,7 +399,7 @@ static void __user *get_sigframe(struct=20 - sp -=3D frame_size; - /* Align the stack pointer according to the i386 ABI, - * i.e. so that on function entry ((sp + 4) & 15) =3D=3D 0. */ -- sp =3D ((sp + 4) & -16ul) - 4; -+ sp =3D ((sp - 12) & -16ul) - 4; - return (void __user *) sp; - } -=20 -@@ -457,7 +457,7 @@ int ia32_setup_frame(int sig, struct k_s - * These are actually not used anymore, but left because some - * gdb versions depend on them as a marker. - */ -- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); -+ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); - } put_user_catch(err); -=20 - if (err) -@@ -499,7 +499,7 @@ int ia32_setup_rt_frame(int sig, struct=20 - 0xb8, - __NR_ia32_rt_sigreturn, - 0x80cd, -- 0, -+ 0 - }; -=20 - frame =3D get_sigframe(ka, regs, sizeof(*frame), &fpstate); -@@ -529,16 +529,18 @@ int ia32_setup_rt_frame(int sig, struct=20 -=20 - if (ka->sa.sa_flags & SA_RESTORER) - restorer =3D ka->sa.sa_restorer; -+ else if (current->mm->context.vdso) -+ /* Return stub is in 32bit vsyscall page */ -+ restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, rt_sigreturn); - else -- restorer =3D VDSO32_SYMBOL(current->mm->context.vdso, -- rt_sigreturn); -+ restorer =3D &frame->retcode; - put_user_ex(ptr_to_compat(restorer), &frame->pretcode); -=20 - /* - * Not actually used anymore, but left because some gdb - * versions need it. - */ -- put_user_ex(*((u64 *)&code), (u64 *)frame->retcode); -+ put_user_ex(*((const u64 *)&code), (u64 __user *)frame->retcode); - } put_user_catch(err); -=20 - if (err) -diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c linux-3.1.4/arch/x86/ia3= 2/sys_ia32.c ---- linux-3.1.4/arch/x86/ia32/sys_ia32.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/ia32/sys_ia32.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -69,8 +69,8 @@ asmlinkage long sys32_ftruncate64(unsign +diff --git a/arch/x86/ia32/sys_ia32.c b/arch/x86/ia32/sys_ia32.c +index f6f5c53..b358b28 100644 +--- a/arch/x86/ia32/sys_ia32.c ++++ b/arch/x86/ia32/sys_ia32.c +@@ -69,8 +69,8 @@ asmlinkage long sys32_ftruncate64(unsigned int fd, uns= igned long offset_low, */ static int cp_stat64(struct stat64 __user *ubuf, struct kstat *stat) { @@ -6275,7 +6931,7 @@ diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c lin= ux-3.1.4/arch/x86/ia32/sys_ia SET_UID(uid, stat->uid); SET_GID(gid, stat->gid); if (!access_ok(VERIFY_WRITE, ubuf, sizeof(struct stat64)) || -@@ -308,8 +308,8 @@ asmlinkage long sys32_rt_sigprocmask(int +@@ -308,8 +308,8 @@ asmlinkage long sys32_rt_sigprocmask(int how, compat= _sigset_t __user *set, } set_fs(KERNEL_DS); ret =3D sys_rt_sigprocmask(how, @@ -6286,7 +6942,7 @@ diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c lin= ux-3.1.4/arch/x86/ia32/sys_ia sigsetsize); set_fs(old_fs); if (ret) -@@ -332,7 +332,7 @@ asmlinkage long sys32_alarm(unsigned int +@@ -332,7 +332,7 @@ asmlinkage long sys32_alarm(unsigned int seconds) return alarm_setitimer(seconds); } =20 @@ -6295,7 +6951,7 @@ diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c lin= ux-3.1.4/arch/x86/ia32/sys_ia int options) { return compat_sys_wait4(pid, stat_addr, options, NULL); -@@ -353,7 +353,7 @@ asmlinkage long sys32_sched_rr_get_inter +@@ -353,7 +353,7 @@ asmlinkage long sys32_sched_rr_get_interval(compat_p= id_t pid, mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -6304,7 +6960,7 @@ diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c lin= ux-3.1.4/arch/x86/ia32/sys_ia set_fs(old_fs); if (put_compat_timespec(&t, interval)) return -EFAULT; -@@ -369,7 +369,7 @@ asmlinkage long sys32_rt_sigpending(comp +@@ -369,7 +369,7 @@ asmlinkage long sys32_rt_sigpending(compat_sigset_t = __user *set, mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -6313,7 +6969,7 @@ diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c lin= ux-3.1.4/arch/x86/ia32/sys_ia set_fs(old_fs); if (!ret) { switch (_NSIG_WORDS) { -@@ -394,7 +394,7 @@ asmlinkage long sys32_rt_sigqueueinfo(in +@@ -394,7 +394,7 @@ asmlinkage long sys32_rt_sigqueueinfo(int pid, int s= ig, if (copy_siginfo_from_user32(&info, uinfo)) return -EFAULT; set_fs(KERNEL_DS); @@ -6322,7 +6978,7 @@ diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c lin= ux-3.1.4/arch/x86/ia32/sys_ia set_fs(old_fs); return ret; } -@@ -439,7 +439,7 @@ asmlinkage long sys32_sendfile(int out_f +@@ -439,7 +439,7 @@ asmlinkage long sys32_sendfile(int out_fd, int in_fd= , return -EFAULT; =20 set_fs(KERNEL_DS); @@ -6331,9 +6987,10 @@ diff -urNp linux-3.1.4/arch/x86/ia32/sys_ia32.c li= nux-3.1.4/arch/x86/ia32/sys_ia count); set_fs(old_fs); =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/alternative-asm.h linux-3.1.= 4/arch/x86/include/asm/alternative-asm.h ---- linux-3.1.4/arch/x86/include/asm/alternative-asm.h 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/alternative-asm.h 2011-12-02 17:40:= 13.000000000 -0500 +diff --git a/arch/x86/include/asm/alternative-asm.h b/arch/x86/include/a= sm/alternative-asm.h +index 091508b..0ee32ec 100644 +--- a/arch/x86/include/asm/alternative-asm.h ++++ b/arch/x86/include/asm/alternative-asm.h @@ -15,6 +15,45 @@ .endm #endif @@ -6380,10 +7037,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/alter= native-asm.h linux-3.1.4/arch/x .macro altinstruction_entry orig alt feature orig_len alt_len .long \orig - . .long \alt - . -diff -urNp linux-3.1.4/arch/x86/include/asm/alternative.h linux-3.1.4/ar= ch/x86/include/asm/alternative.h ---- linux-3.1.4/arch/x86/include/asm/alternative.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/alternative.h 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -89,7 +89,7 @@ static inline int alternatives_text_rese +diff --git a/arch/x86/include/asm/alternative.h b/arch/x86/include/asm/a= lternative.h +index 37ad100..7d47faa 100644 +--- a/arch/x86/include/asm/alternative.h ++++ b/arch/x86/include/asm/alternative.h +@@ -89,7 +89,7 @@ static inline int alternatives_text_reserved(void *sta= rt, void *end) ".section .discard,\"aw\",@progbits\n" \ " .byte 0xff + (664f-663f) - (662b-661b)\n" /* rlen <=3D slen */= \ ".previous\n" \ @@ -6392,10 +7050,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/alter= native.h linux-3.1.4/arch/x86/i "663:\n\t" newinstr "\n664:\n" /* replacement */ \ ".previous" =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/apic.h linux-3.1.4/arch/x86/= include/asm/apic.h ---- linux-3.1.4/arch/x86/include/asm/apic.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/include/asm/apic.h 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -45,7 +45,7 @@ static inline void generic_apic_probe(vo +diff --git a/arch/x86/include/asm/apic.h b/arch/x86/include/asm/apic.h +index 9b7273c..e9fcc24 100644 +--- a/arch/x86/include/asm/apic.h ++++ b/arch/x86/include/asm/apic.h +@@ -45,7 +45,7 @@ static inline void generic_apic_probe(void) =20 #ifdef CONFIG_X86_LOCAL_APIC =20 @@ -6404,10 +7063,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/apic.= h linux-3.1.4/arch/x86/include/ extern int local_apic_timer_c2_ok; =20 extern int disable_apic; -diff -urNp linux-3.1.4/arch/x86/include/asm/apm.h linux-3.1.4/arch/x86/i= nclude/asm/apm.h ---- linux-3.1.4/arch/x86/include/asm/apm.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/include/asm/apm.h 2011-11-16 18:39:07.000000000= -0500 -@@ -34,7 +34,7 @@ static inline void apm_bios_call_asm(u32 +diff --git a/arch/x86/include/asm/apm.h b/arch/x86/include/asm/apm.h +index 20370c6..a2eb9b0 100644 +--- a/arch/x86/include/asm/apm.h ++++ b/arch/x86/include/asm/apm.h +@@ -34,7 +34,7 @@ static inline void apm_bios_call_asm(u32 func, u32 ebx= _in, u32 ecx_in, __asm__ __volatile__(APM_DO_ZERO_SEGS "pushl %%edi\n\t" "pushl %%ebp\n\t" @@ -6416,7 +7076,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/apm.h l= inux-3.1.4/arch/x86/include/a "setc %%al\n\t" "popl %%ebp\n\t" "popl %%edi\n\t" -@@ -58,7 +58,7 @@ static inline u8 apm_bios_call_simple_as +@@ -58,7 +58,7 @@ static inline u8 apm_bios_call_simple_asm(u32 func, u3= 2 ebx_in, __asm__ __volatile__(APM_DO_ZERO_SEGS "pushl %%edi\n\t" "pushl %%ebp\n\t" @@ -6425,401 +7085,269 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/apm= .h linux-3.1.4/arch/x86/include/a "setc %%bl\n\t" "popl %%ebp\n\t" "popl %%edi\n\t" -diff -urNp linux-3.1.4/arch/x86/include/asm/atomic64_32.h linux-3.1.4/ar= ch/x86/include/asm/atomic64_32.h ---- linux-3.1.4/arch/x86/include/asm/atomic64_32.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/atomic64_32.h 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -12,6 +12,14 @@ typedef struct { - u64 __aligned(8) counter; - } atomic64_t; -=20 -+#ifdef CONFIG_PAX_REFCOUNT -+typedef struct { -+ u64 __aligned(8) counter; -+} atomic64_unchecked_t; -+#else -+typedef atomic64_t atomic64_unchecked_t; -+#endif -+ - #define ATOMIC64_INIT(val) { (val) } -=20 - #ifdef CONFIG_X86_CMPXCHG64 -@@ -38,6 +46,21 @@ static inline long long atomic64_cmpxchg - } -=20 - /** -+ * atomic64_cmpxchg_unchecked - cmpxchg atomic64 variable -+ * @p: pointer to type atomic64_unchecked_t -+ * @o: expected value -+ * @n: new value -+ * -+ * Atomically sets @v to @n if it was equal to @o and returns -+ * the old value. -+ */ -+ -+static inline long long atomic64_cmpxchg_unchecked(atomic64_unchecked_t= *v, long long o, long long n) -+{ -+ return cmpxchg64(&v->counter, o, n); -+} -+ -+/** - * atomic64_xchg - xchg atomic64 variable - * @v: pointer to type atomic64_t - * @n: value to assign -@@ -77,6 +100,24 @@ static inline void atomic64_set(atomic64 - } -=20 - /** -+ * atomic64_set_unchecked - set atomic64 variable -+ * @v: pointer to type atomic64_unchecked_t -+ * @n: value to assign -+ * -+ * Atomically sets the value of @v to @n. -+ */ -+static inline void atomic64_set_unchecked(atomic64_unchecked_t *v, long= long i) -+{ -+ unsigned high =3D (unsigned)(i >> 32); -+ unsigned low =3D (unsigned)i; -+ asm volatile(ATOMIC64_ALTERNATIVE(set) -+ : "+b" (low), "+c" (high) -+ : "S" (v) -+ : "eax", "edx", "memory" -+ ); -+} -+ -+/** - * atomic64_read - read atomic64 variable - * @v: pointer to type atomic64_t - * -@@ -93,6 +134,22 @@ static inline long long atomic64_read(at - } -=20 - /** -+ * atomic64_read_unchecked - read atomic64 variable -+ * @v: pointer to type atomic64_unchecked_t -+ * -+ * Atomically reads the value of @v and returns it. -+ */ -+static inline long long atomic64_read_unchecked(atomic64_unchecked_t *v= ) -+{ -+ long long r; -+ asm volatile(ATOMIC64_ALTERNATIVE(read_unchecked) -+ : "=3DA" (r), "+c" (v) -+ : : "memory" -+ ); -+ return r; -+ } -+ -+/** - * atomic64_add_return - add and return - * @i: integer value to add - * @v: pointer to type atomic64_t -@@ -108,6 +165,22 @@ static inline long long atomic64_add_ret - return i; - } -=20 -+/** -+ * atomic64_add_return_unchecked - add and return -+ * @i: integer value to add -+ * @v: pointer to type atomic64_unchecked_t -+ * -+ * Atomically adds @i to @v and returns @i + *@v -+ */ -+static inline long long atomic64_add_return_unchecked(long long i, atom= ic64_unchecked_t *v) -+{ -+ asm volatile(ATOMIC64_ALTERNATIVE(add_return_unchecked) -+ : "+A" (i), "+c" (v) -+ : : "memory" -+ ); -+ return i; -+} -+ - /* - * Other variants with different arithmetic operators: - */ -@@ -131,6 +204,17 @@ static inline long long atomic64_inc_ret - return a; - } -=20 -+static inline long long atomic64_inc_return_unchecked(atomic64_unchecke= d_t *v) -+{ -+ long long a; -+ asm volatile(ATOMIC64_ALTERNATIVE(inc_return_unchecked) -+ : "=3DA" (a) -+ : "S" (v) -+ : "memory", "ecx" -+ ); -+ return a; -+} -+ - static inline long long atomic64_dec_return(atomic64_t *v) - { - long long a; -@@ -159,6 +243,22 @@ static inline long long atomic64_add(lon - } -=20 - /** -+ * atomic64_add_unchecked - add integer to atomic64 variable -+ * @i: integer value to add -+ * @v: pointer to type atomic64_unchecked_t -+ * -+ * Atomically adds @i to @v. -+ */ -+static inline long long atomic64_add_unchecked(long long i, atomic64_un= checked_t *v) -+{ -+ asm volatile(ATOMIC64_ALTERNATIVE_(add_unchecked, add_return_unchecked= ) -+ : "+A" (i), "+c" (v) -+ : : "memory" -+ ); -+ return i; -+} -+ -+/** - * atomic64_sub - subtract the atomic64 variable - * @i: integer value to subtract - * @v: pointer to type atomic64_t -diff -urNp linux-3.1.4/arch/x86/include/asm/atomic64_64.h linux-3.1.4/ar= ch/x86/include/asm/atomic64_64.h ---- linux-3.1.4/arch/x86/include/asm/atomic64_64.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/atomic64_64.h 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -18,7 +18,19 @@ +diff --git a/arch/x86/include/asm/atomic.h b/arch/x86/include/asm/atomic= .h +index 10572e3..2618d91 100644 +--- a/arch/x86/include/asm/atomic.h ++++ b/arch/x86/include/asm/atomic.h +@@ -22,7 +22,18 @@ */ - static inline long atomic64_read(const atomic64_t *v) + static inline int atomic_read(const atomic_t *v) { -- return (*(volatile long *)&(v)->counter); -+ return (*(volatile const long *)&(v)->counter); +- return (*(volatile int *)&(v)->counter); ++ return (*(volatile const int *)&(v)->counter); +} + +/** -+ * atomic64_read_unchecked - read atomic64 variable -+ * @v: pointer of type atomic64_unchecked_t ++ * atomic_read_unchecked - read atomic variable ++ * @v: pointer of type atomic_unchecked_t + * + * Atomically reads the value of @v. -+ * Doesn't imply a read memory barrier. + */ -+static inline long atomic64_read_unchecked(const atomic64_unchecked_t *= v) ++static inline int atomic_read_unchecked(const atomic_unchecked_t *v) +{ -+ return (*(volatile const long *)&(v)->counter); ++ return (*(volatile const int *)&(v)->counter); } =20 /** -@@ -34,6 +46,18 @@ static inline void atomic64_set(atomic64 +@@ -38,6 +49,18 @@ static inline void atomic_set(atomic_t *v, int i) } =20 /** -+ * atomic64_set_unchecked - set atomic64 variable -+ * @v: pointer to type atomic64_unchecked_t ++ * atomic_set_unchecked - set atomic variable ++ * @v: pointer of type atomic_unchecked_t + * @i: required value + * + * Atomically sets the value of @v to @i. + */ -+static inline void atomic64_set_unchecked(atomic64_unchecked_t *v, long= i) ++static inline void atomic_set_unchecked(atomic_unchecked_t *v, int i) +{ + v->counter =3D i; +} + +/** - * atomic64_add - add integer to atomic64 variable + * atomic_add - add integer to atomic variable * @i: integer value to add - * @v: pointer to type atomic64_t -@@ -42,6 +66,28 @@ static inline void atomic64_set(atomic64 + * @v: pointer of type atomic_t +@@ -46,7 +69,29 @@ static inline void atomic_set(atomic_t *v, int i) */ - static inline void atomic64_add(long i, atomic64_t *v) + static inline void atomic_add(int i, atomic_t *v) { -+ asm volatile(LOCK_PREFIX "addq %1,%0\n" +- asm volatile(LOCK_PREFIX "addl %1,%0" ++ asm volatile(LOCK_PREFIX "addl %1,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "subq %1,%0\n" ++ LOCK_PREFIX "subl %1,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "=3Dm" (v->counter) -+ : "er" (i), "m" (v->counter)); ++ : "+m" (v->counter) ++ : "ir" (i)); +} + +/** -+ * atomic64_add_unchecked - add integer to atomic64 variable ++ * atomic_add_unchecked - add integer to atomic variable + * @i: integer value to add -+ * @v: pointer to type atomic64_unchecked_t ++ * @v: pointer of type atomic_unchecked_t + * + * Atomically adds @i to @v. + */ -+static inline void atomic64_add_unchecked(long i, atomic64_unchecked_t = *v) ++static inline void atomic_add_unchecked(int i, atomic_unchecked_t *v) +{ - asm volatile(LOCK_PREFIX "addq %1,%0" - : "=3Dm" (v->counter) - : "er" (i), "m" (v->counter)); -@@ -56,7 +102,29 @@ static inline void atomic64_add(long i,=20 ++ asm volatile(LOCK_PREFIX "addl %1,%0\n" + : "+m" (v->counter) + : "ir" (i)); + } +@@ -60,7 +105,29 @@ static inline void atomic_add(int i, atomic_t *v) */ - static inline void atomic64_sub(long i, atomic64_t *v) + static inline void atomic_sub(int i, atomic_t *v) { -- asm volatile(LOCK_PREFIX "subq %1,%0" -+ asm volatile(LOCK_PREFIX "subq %1,%0\n" +- asm volatile(LOCK_PREFIX "subl %1,%0" ++ asm volatile(LOCK_PREFIX "subl %1,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "addq %1,%0\n" ++ LOCK_PREFIX "addl %1,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "=3Dm" (v->counter) -+ : "er" (i), "m" (v->counter)); ++ : "+m" (v->counter) ++ : "ir" (i)); +} + +/** -+ * atomic64_sub_unchecked - subtract the atomic64 variable ++ * atomic_sub_unchecked - subtract integer from atomic variable + * @i: integer value to subtract -+ * @v: pointer to type atomic64_unchecked_t ++ * @v: pointer of type atomic_unchecked_t + * + * Atomically subtracts @i from @v. + */ -+static inline void atomic64_sub_unchecked(long i, atomic64_unchecked_t = *v) ++static inline void atomic_sub_unchecked(int i, atomic_unchecked_t *v) +{ -+ asm volatile(LOCK_PREFIX "subq %1,%0\n" - : "=3Dm" (v->counter) - : "er" (i), "m" (v->counter)); ++ asm volatile(LOCK_PREFIX "subl %1,%0\n" + : "+m" (v->counter) + : "ir" (i)); } -@@ -74,7 +142,16 @@ static inline int atomic64_sub_and_test( +@@ -78,7 +145,16 @@ static inline int atomic_sub_and_test(int i, atomic_= t *v) { unsigned char c; =20 -- asm volatile(LOCK_PREFIX "subq %2,%0; sete %1" -+ asm volatile(LOCK_PREFIX "subq %2,%0\n" +- asm volatile(LOCK_PREFIX "subl %2,%0; sete %1" ++ asm volatile(LOCK_PREFIX "subl %2,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "addq %2,%0\n" ++ LOCK_PREFIX "addl %2,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sete %1\n" - : "=3Dm" (v->counter), "=3Dqm" (c) - : "er" (i), "m" (v->counter) : "memory"); + : "+m" (v->counter), "=3Dqm" (c) + : "ir" (i) : "memory"); return c; -@@ -88,6 +165,27 @@ static inline int atomic64_sub_and_test( +@@ -92,7 +168,27 @@ static inline int atomic_sub_and_test(int i, atomic_= t *v) */ - static inline void atomic64_inc(atomic64_t *v) + static inline void atomic_inc(atomic_t *v) { -+ asm volatile(LOCK_PREFIX "incq %0\n" +- asm volatile(LOCK_PREFIX "incl %0" ++ asm volatile(LOCK_PREFIX "incl %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "decq %0\n" ++ LOCK_PREFIX "decl %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "=3Dm" (v->counter) -+ : "m" (v->counter)); ++ : "+m" (v->counter)); +} + +/** -+ * atomic64_inc_unchecked - increment atomic64 variable -+ * @v: pointer to type atomic64_unchecked_t ++ * atomic_inc_unchecked - increment atomic variable ++ * @v: pointer of type atomic_unchecked_t + * + * Atomically increments @v by 1. + */ -+static inline void atomic64_inc_unchecked(atomic64_unchecked_t *v) ++static inline void atomic_inc_unchecked(atomic_unchecked_t *v) +{ - asm volatile(LOCK_PREFIX "incq %0" - : "=3Dm" (v->counter) - : "m" (v->counter)); -@@ -101,7 +199,28 @@ static inline void atomic64_inc(atomic64 ++ asm volatile(LOCK_PREFIX "incl %0\n" + : "+m" (v->counter)); + } +=20 +@@ -104,7 +200,27 @@ static inline void atomic_inc(atomic_t *v) */ - static inline void atomic64_dec(atomic64_t *v) + static inline void atomic_dec(atomic_t *v) { -- asm volatile(LOCK_PREFIX "decq %0" -+ asm volatile(LOCK_PREFIX "decq %0\n" +- asm volatile(LOCK_PREFIX "decl %0" ++ asm volatile(LOCK_PREFIX "decl %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "incq %0\n" ++ LOCK_PREFIX "incl %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "=3Dm" (v->counter) -+ : "m" (v->counter)); ++ : "+m" (v->counter)); +} + +/** -+ * atomic64_dec_unchecked - decrement atomic64 variable -+ * @v: pointer to type atomic64_t ++ * atomic_dec_unchecked - decrement atomic variable ++ * @v: pointer of type atomic_unchecked_t + * + * Atomically decrements @v by 1. + */ -+static inline void atomic64_dec_unchecked(atomic64_unchecked_t *v) ++static inline void atomic_dec_unchecked(atomic_unchecked_t *v) +{ -+ asm volatile(LOCK_PREFIX "decq %0\n" - : "=3Dm" (v->counter) - : "m" (v->counter)); ++ asm volatile(LOCK_PREFIX "decl %0\n" + : "+m" (v->counter)); } -@@ -118,7 +237,16 @@ static inline int atomic64_dec_and_test( +=20 +@@ -120,7 +236,16 @@ static inline int atomic_dec_and_test(atomic_t *v) { unsigned char c; =20 -- asm volatile(LOCK_PREFIX "decq %0; sete %1" -+ asm volatile(LOCK_PREFIX "decq %0\n" +- asm volatile(LOCK_PREFIX "decl %0; sete %1" ++ asm volatile(LOCK_PREFIX "decl %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "incq %0\n" ++ LOCK_PREFIX "incl %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sete %1\n" - : "=3Dm" (v->counter), "=3Dqm" (c) - : "m" (v->counter) : "memory"); + : "+m" (v->counter), "=3Dqm" (c) + : : "memory"); return c !=3D 0; -@@ -136,7 +264,16 @@ static inline int atomic64_inc_and_test( +@@ -138,7 +263,35 @@ static inline int atomic_inc_and_test(atomic_t *v) { unsigned char c; =20 -- asm volatile(LOCK_PREFIX "incq %0; sete %1" -+ asm volatile(LOCK_PREFIX "incq %0\n" +- asm volatile(LOCK_PREFIX "incl %0; sete %1" ++ asm volatile(LOCK_PREFIX "incl %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "decq %0\n" ++ LOCK_PREFIX "decl %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sete %1\n" - : "=3Dm" (v->counter), "=3Dqm" (c) - : "m" (v->counter) : "memory"); - return c !=3D 0; -@@ -155,7 +292,16 @@ static inline int atomic64_add_negative( - { - unsigned char c; -=20 -- asm volatile(LOCK_PREFIX "addq %2,%0; sets %1" -+ asm volatile(LOCK_PREFIX "addq %2,%0\n" -+ ++ : "+m" (v->counter), "=3Dqm" (c) ++ : : "memory"); ++ return c !=3D 0; ++} ++ ++/** ++ * atomic_inc_and_test_unchecked - increment and test ++ * @v: pointer of type atomic_unchecked_t ++ * ++ * Atomically increments @v by 1 ++ * and returns true if the result is zero, or false for all ++ * other cases. ++ */ ++static inline int atomic_inc_and_test_unchecked(atomic_unchecked_t *v) ++{ ++ unsigned char c; ++ ++ asm volatile(LOCK_PREFIX "incl %0\n" ++ "sete %1\n" + : "+m" (v->counter), "=3Dqm" (c) + : : "memory"); + return c !=3D 0; +@@ -157,7 +310,16 @@ static inline int atomic_add_negative(int i, atomic= _t *v) + { + unsigned char c; +=20 +- asm volatile(LOCK_PREFIX "addl %2,%0; sets %1" ++ asm volatile(LOCK_PREFIX "addl %2,%0\n" ++ +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "subq %2,%0\n" ++ LOCK_PREFIX "subl %2,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sets %1\n" - : "=3Dm" (v->counter), "=3Dqm" (c) - : "er" (i), "m" (v->counter) : "memory"); + : "+m" (v->counter), "=3Dqm" (c) + : "ir" (i) : "memory"); return c; -@@ -171,7 +317,31 @@ static inline int atomic64_add_negative( - static inline long atomic64_add_return(long i, atomic64_t *v) - { - long __i =3D i; -- asm volatile(LOCK_PREFIX "xaddq %0, %1;" -+ asm volatile(LOCK_PREFIX "xaddq %0, %1\n" +@@ -180,6 +342,46 @@ static inline int atomic_add_return(int i, atomic_t= *v) + #endif + /* Modern 486+ processor */ + __i =3D i; ++ asm volatile(LOCK_PREFIX "xaddl %0, %1\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ "movq %0, %1\n" ++ "movl %0, %1\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif @@ -6827,63 +7355,88 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/atomi= c64_64.h linux-3.1.4/arch/x86/i + : "+r" (i), "+m" (v->counter) + : : "memory"); + return i + __i; ++ ++#ifdef CONFIG_M386 ++no_xadd: /* Legacy 386 processor */ ++ local_irq_save(flags); ++ __i =3D atomic_read(v); ++ atomic_set(v, i + __i); ++ local_irq_restore(flags); ++ return i + __i; ++#endif +} + +/** -+ * atomic64_add_return_unchecked - add and return ++ * atomic_add_return_unchecked - add integer and return ++ * @v: pointer of type atomic_unchecked_t + * @i: integer value to add -+ * @v: pointer to type atomic64_unchecked_t + * + * Atomically adds @i to @v and returns @i + @v + */ -+static inline long atomic64_add_return_unchecked(long i, atomic64_unche= cked_t *v) ++static inline int atomic_add_return_unchecked(int i, atomic_unchecked_t= *v) +{ -+ long __i =3D i; -+ asm volatile(LOCK_PREFIX "xaddq %0, %1" ++ int __i; ++#ifdef CONFIG_M386 ++ unsigned long flags; ++ if (unlikely(boot_cpu_data.x86 <=3D 3)) ++ goto no_xadd; ++#endif ++ /* Modern 486+ processor */ ++ __i =3D i; + asm volatile(LOCK_PREFIX "xaddl %0, %1" : "+r" (i), "+m" (v->counter) : : "memory"); - return i + __i; -@@ -183,6 +353,10 @@ static inline long atomic64_sub_return(l +@@ -208,6 +410,10 @@ static inline int atomic_sub_return(int i, atomic_t= *v) } =20 - #define atomic64_inc_return(v) (atomic64_add_return(1, (v))) -+static inline long atomic64_inc_return_unchecked(atomic64_unchecked_t *= v) + #define atomic_inc_return(v) (atomic_add_return(1, v)) ++static inline int atomic_inc_return_unchecked(atomic_unchecked_t *v) +{ -+ return atomic64_add_return_unchecked(1, v); ++ return atomic_add_return_unchecked(1, v); +} - #define atomic64_dec_return(v) (atomic64_sub_return(1, (v))) + #define atomic_dec_return(v) (atomic_sub_return(1, v)) =20 - static inline long atomic64_cmpxchg(atomic64_t *v, long old, long new) -@@ -190,6 +364,11 @@ static inline long atomic64_cmpxchg(atom + static inline int atomic_cmpxchg(atomic_t *v, int old, int new) +@@ -215,11 +421,21 @@ static inline int atomic_cmpxchg(atomic_t *v, int = old, int new) return cmpxchg(&v->counter, old, new); } =20 -+static inline long atomic64_cmpxchg_unchecked(atomic64_unchecked_t *v, = long old, long new) ++static inline int atomic_cmpxchg_unchecked(atomic_unchecked_t *v, int o= ld, int new) +{ + return cmpxchg(&v->counter, old, new); +} + - static inline long atomic64_xchg(atomic64_t *v, long new) + static inline int atomic_xchg(atomic_t *v, int new) { return xchg(&v->counter, new); -@@ -206,17 +385,30 @@ static inline long atomic64_xchg(atomic6 + } +=20 ++static inline int atomic_xchg_unchecked(atomic_unchecked_t *v, int new) ++{ ++ return xchg(&v->counter, new); ++} ++ + /** + * __atomic_add_unless - add unless the number is already a given value + * @v: pointer of type atomic_t +@@ -231,12 +447,25 @@ static inline int atomic_xchg(atomic_t *v, int new= ) */ - static inline int atomic64_add_unless(atomic64_t *v, long a, long u) + static inline int __atomic_add_unless(atomic_t *v, int a, int u) { -- long c, old; -+ long c, old, new; - c =3D atomic64_read(v); +- int c, old; ++ int c, old, new; + c =3D atomic_read(v); for (;;) { - if (unlikely(c =3D=3D (u))) + if (unlikely(c =3D=3D u)) break; -- old =3D atomic64_cmpxchg((v), c, c + (a)); +- old =3D atomic_cmpxchg((v), c, c + (a)); + -+ asm volatile("add %2,%0\n" ++ asm volatile("addl %2,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ "sub %2,%0\n" ++ "subl %2,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif @@ -6891,278 +7444,456 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/ato= mic64_64.h linux-3.1.4/arch/x86/i + : "=3Dr" (new) + : "0" (c), "ir" (a)); + -+ old =3D atomic64_cmpxchg(v, c, new); ++ old =3D atomic_cmpxchg(v, c, new); if (likely(old =3D=3D c)) break; c =3D old; - } -- return c !=3D (u); -+ return c !=3D u; +@@ -244,6 +473,48 @@ static inline int __atomic_add_unless(atomic_t *v, = int a, int u) + return c; } =20 - #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) -diff -urNp linux-3.1.4/arch/x86/include/asm/atomic.h linux-3.1.4/arch/x8= 6/include/asm/atomic.h ---- linux-3.1.4/arch/x86/include/asm/atomic.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/atomic.h 2011-11-16 18:39:07.000000= 000 -0500 -@@ -22,7 +22,18 @@ ++/** ++ * atomic_inc_not_zero_hint - increment if not null ++ * @v: pointer of type atomic_t ++ * @hint: probable value of the atomic before the increment ++ * ++ * This version of atomic_inc_not_zero() gives a hint of probable ++ * value of the atomic. This helps processor to not read the memory ++ * before doing the atomic read/modify/write cycle, lowering ++ * number of bus transactions on some arches. ++ * ++ * Returns: 0 if increment was not done, 1 otherwise. ++ */ ++#define atomic_inc_not_zero_hint atomic_inc_not_zero_hint ++static inline int atomic_inc_not_zero_hint(atomic_t *v, int hint) ++{ ++ int val, c =3D hint, new; ++ ++ /* sanity test, should be removed by compiler if hint is a constant */ ++ if (!hint) ++ return __atomic_add_unless(v, 1, 0); ++ ++ do { ++ asm volatile("incl %0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ "decl %0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ : "=3Dr" (new) ++ : "0" (c)); ++ ++ val =3D atomic_cmpxchg(v, c, new); ++ if (val =3D=3D c) ++ return 1; ++ c =3D val; ++ } while (c); ++ ++ return 0; ++} +=20 + /* + * atomic_dec_if_positive - decrement by 1 if old value positive +diff --git a/arch/x86/include/asm/atomic64_32.h b/arch/x86/include/asm/a= tomic64_32.h +index 24098aa..1e37723 100644 +--- a/arch/x86/include/asm/atomic64_32.h ++++ b/arch/x86/include/asm/atomic64_32.h +@@ -12,6 +12,14 @@ typedef struct { + u64 __aligned(8) counter; + } atomic64_t; +=20 ++#ifdef CONFIG_PAX_REFCOUNT ++typedef struct { ++ u64 __aligned(8) counter; ++} atomic64_unchecked_t; ++#else ++typedef atomic64_t atomic64_unchecked_t; ++#endif ++ + #define ATOMIC64_INIT(val) { (val) } +=20 + #ifdef CONFIG_X86_CMPXCHG64 +@@ -38,6 +46,21 @@ static inline long long atomic64_cmpxchg(atomic64_t *= v, long long o, long long n + } +=20 + /** ++ * atomic64_cmpxchg_unchecked - cmpxchg atomic64 variable ++ * @p: pointer to type atomic64_unchecked_t ++ * @o: expected value ++ * @n: new value ++ * ++ * Atomically sets @v to @n if it was equal to @o and returns ++ * the old value. ++ */ ++ ++static inline long long atomic64_cmpxchg_unchecked(atomic64_unchecked_t= *v, long long o, long long n) ++{ ++ return cmpxchg64(&v->counter, o, n); ++} ++ ++/** + * atomic64_xchg - xchg atomic64 variable + * @v: pointer to type atomic64_t + * @n: value to assign +@@ -77,6 +100,24 @@ static inline void atomic64_set(atomic64_t *v, long = long i) + } +=20 + /** ++ * atomic64_set_unchecked - set atomic64 variable ++ * @v: pointer to type atomic64_unchecked_t ++ * @n: value to assign ++ * ++ * Atomically sets the value of @v to @n. ++ */ ++static inline void atomic64_set_unchecked(atomic64_unchecked_t *v, long= long i) ++{ ++ unsigned high =3D (unsigned)(i >> 32); ++ unsigned low =3D (unsigned)i; ++ asm volatile(ATOMIC64_ALTERNATIVE(set) ++ : "+b" (low), "+c" (high) ++ : "S" (v) ++ : "eax", "edx", "memory" ++ ); ++} ++ ++/** + * atomic64_read - read atomic64 variable + * @v: pointer to type atomic64_t + * +@@ -93,6 +134,22 @@ static inline long long atomic64_read(atomic64_t *v) + } +=20 + /** ++ * atomic64_read_unchecked - read atomic64 variable ++ * @v: pointer to type atomic64_unchecked_t ++ * ++ * Atomically reads the value of @v and returns it. ++ */ ++static inline long long atomic64_read_unchecked(atomic64_unchecked_t *v= ) ++{ ++ long long r; ++ asm volatile(ATOMIC64_ALTERNATIVE(read_unchecked) ++ : "=3DA" (r), "+c" (v) ++ : : "memory" ++ ); ++ return r; ++ } ++ ++/** + * atomic64_add_return - add and return + * @i: integer value to add + * @v: pointer to type atomic64_t +@@ -108,6 +165,22 @@ static inline long long atomic64_add_return(long lo= ng i, atomic64_t *v) + return i; + } +=20 ++/** ++ * atomic64_add_return_unchecked - add and return ++ * @i: integer value to add ++ * @v: pointer to type atomic64_unchecked_t ++ * ++ * Atomically adds @i to @v and returns @i + *@v ++ */ ++static inline long long atomic64_add_return_unchecked(long long i, atom= ic64_unchecked_t *v) ++{ ++ asm volatile(ATOMIC64_ALTERNATIVE(add_return_unchecked) ++ : "+A" (i), "+c" (v) ++ : : "memory" ++ ); ++ return i; ++} ++ + /* + * Other variants with different arithmetic operators: */ - static inline int atomic_read(const atomic_t *v) +@@ -131,6 +204,17 @@ static inline long long atomic64_inc_return(atomic6= 4_t *v) + return a; + } +=20 ++static inline long long atomic64_inc_return_unchecked(atomic64_unchecke= d_t *v) ++{ ++ long long a; ++ asm volatile(ATOMIC64_ALTERNATIVE(inc_return_unchecked) ++ : "=3DA" (a) ++ : "S" (v) ++ : "memory", "ecx" ++ ); ++ return a; ++} ++ + static inline long long atomic64_dec_return(atomic64_t *v) { -- return (*(volatile int *)&(v)->counter); -+ return (*(volatile const int *)&(v)->counter); + long long a; +@@ -159,6 +243,22 @@ static inline long long atomic64_add(long long i, a= tomic64_t *v) + } +=20 + /** ++ * atomic64_add_unchecked - add integer to atomic64 variable ++ * @i: integer value to add ++ * @v: pointer to type atomic64_unchecked_t ++ * ++ * Atomically adds @i to @v. ++ */ ++static inline long long atomic64_add_unchecked(long long i, atomic64_un= checked_t *v) ++{ ++ asm volatile(ATOMIC64_ALTERNATIVE_(add_unchecked, add_return_unchecked= ) ++ : "+A" (i), "+c" (v) ++ : : "memory" ++ ); ++ return i; +} + +/** -+ * atomic_read_unchecked - read atomic variable -+ * @v: pointer of type atomic_unchecked_t + * atomic64_sub - subtract the atomic64 variable + * @i: integer value to subtract + * @v: pointer to type atomic64_t +diff --git a/arch/x86/include/asm/atomic64_64.h b/arch/x86/include/asm/a= tomic64_64.h +index 017594d..d3fcf72 100644 +--- a/arch/x86/include/asm/atomic64_64.h ++++ b/arch/x86/include/asm/atomic64_64.h +@@ -18,7 +18,19 @@ + */ + static inline long atomic64_read(const atomic64_t *v) + { +- return (*(volatile long *)&(v)->counter); ++ return (*(volatile const long *)&(v)->counter); ++} ++ ++/** ++ * atomic64_read_unchecked - read atomic64 variable ++ * @v: pointer of type atomic64_unchecked_t + * + * Atomically reads the value of @v. ++ * Doesn't imply a read memory barrier. + */ -+static inline int atomic_read_unchecked(const atomic_unchecked_t *v) ++static inline long atomic64_read_unchecked(const atomic64_unchecked_t *= v) +{ -+ return (*(volatile const int *)&(v)->counter); ++ return (*(volatile const long *)&(v)->counter); } =20 /** -@@ -38,6 +49,18 @@ static inline void atomic_set(atomic_t * +@@ -34,6 +46,18 @@ static inline void atomic64_set(atomic64_t *v, long i= ) } =20 /** -+ * atomic_set_unchecked - set atomic variable -+ * @v: pointer of type atomic_unchecked_t ++ * atomic64_set_unchecked - set atomic64 variable ++ * @v: pointer to type atomic64_unchecked_t + * @i: required value + * + * Atomically sets the value of @v to @i. + */ -+static inline void atomic_set_unchecked(atomic_unchecked_t *v, int i) ++static inline void atomic64_set_unchecked(atomic64_unchecked_t *v, long= i) +{ + v->counter =3D i; +} + +/** - * atomic_add - add integer to atomic variable + * atomic64_add - add integer to atomic64 variable * @i: integer value to add - * @v: pointer of type atomic_t -@@ -46,7 +69,29 @@ static inline void atomic_set(atomic_t * + * @v: pointer to type atomic64_t +@@ -42,6 +66,28 @@ static inline void atomic64_set(atomic64_t *v, long i= ) */ - static inline void atomic_add(int i, atomic_t *v) + static inline void atomic64_add(long i, atomic64_t *v) { -- asm volatile(LOCK_PREFIX "addl %1,%0" -+ asm volatile(LOCK_PREFIX "addl %1,%0\n" ++ asm volatile(LOCK_PREFIX "addq %1,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "subl %1,%0\n" ++ LOCK_PREFIX "subq %1,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "+m" (v->counter) -+ : "ir" (i)); ++ : "=3Dm" (v->counter) ++ : "er" (i), "m" (v->counter)); +} + +/** -+ * atomic_add_unchecked - add integer to atomic variable ++ * atomic64_add_unchecked - add integer to atomic64 variable + * @i: integer value to add -+ * @v: pointer of type atomic_unchecked_t ++ * @v: pointer to type atomic64_unchecked_t + * + * Atomically adds @i to @v. + */ -+static inline void atomic_add_unchecked(int i, atomic_unchecked_t *v) ++static inline void atomic64_add_unchecked(long i, atomic64_unchecked_t = *v) +{ -+ asm volatile(LOCK_PREFIX "addl %1,%0\n" - : "+m" (v->counter) - : "ir" (i)); - } -@@ -60,7 +105,29 @@ static inline void atomic_add(int i, ato + asm volatile(LOCK_PREFIX "addq %1,%0" + : "=3Dm" (v->counter) + : "er" (i), "m" (v->counter)); +@@ -56,7 +102,29 @@ static inline void atomic64_add(long i, atomic64_t *= v) */ - static inline void atomic_sub(int i, atomic_t *v) + static inline void atomic64_sub(long i, atomic64_t *v) { -- asm volatile(LOCK_PREFIX "subl %1,%0" -+ asm volatile(LOCK_PREFIX "subl %1,%0\n" +- asm volatile(LOCK_PREFIX "subq %1,%0" ++ asm volatile(LOCK_PREFIX "subq %1,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "addl %1,%0\n" ++ LOCK_PREFIX "addq %1,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "+m" (v->counter) -+ : "ir" (i)); ++ : "=3Dm" (v->counter) ++ : "er" (i), "m" (v->counter)); +} + +/** -+ * atomic_sub_unchecked - subtract integer from atomic variable ++ * atomic64_sub_unchecked - subtract the atomic64 variable + * @i: integer value to subtract -+ * @v: pointer of type atomic_unchecked_t ++ * @v: pointer to type atomic64_unchecked_t + * + * Atomically subtracts @i from @v. + */ -+static inline void atomic_sub_unchecked(int i, atomic_unchecked_t *v) ++static inline void atomic64_sub_unchecked(long i, atomic64_unchecked_t = *v) +{ -+ asm volatile(LOCK_PREFIX "subl %1,%0\n" - : "+m" (v->counter) - : "ir" (i)); ++ asm volatile(LOCK_PREFIX "subq %1,%0\n" + : "=3Dm" (v->counter) + : "er" (i), "m" (v->counter)); } -@@ -78,7 +145,16 @@ static inline int atomic_sub_and_test(in +@@ -74,7 +142,16 @@ static inline int atomic64_sub_and_test(long i, atom= ic64_t *v) { unsigned char c; =20 -- asm volatile(LOCK_PREFIX "subl %2,%0; sete %1" -+ asm volatile(LOCK_PREFIX "subl %2,%0\n" +- asm volatile(LOCK_PREFIX "subq %2,%0; sete %1" ++ asm volatile(LOCK_PREFIX "subq %2,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "addl %2,%0\n" ++ LOCK_PREFIX "addq %2,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sete %1\n" - : "+m" (v->counter), "=3Dqm" (c) - : "ir" (i) : "memory"); + : "=3Dm" (v->counter), "=3Dqm" (c) + : "er" (i), "m" (v->counter) : "memory"); return c; -@@ -92,7 +168,27 @@ static inline int atomic_sub_and_test(in +@@ -88,6 +165,27 @@ static inline int atomic64_sub_and_test(long i, atom= ic64_t *v) */ - static inline void atomic_inc(atomic_t *v) + static inline void atomic64_inc(atomic64_t *v) { -- asm volatile(LOCK_PREFIX "incl %0" -+ asm volatile(LOCK_PREFIX "incl %0\n" ++ asm volatile(LOCK_PREFIX "incq %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "decl %0\n" ++ LOCK_PREFIX "decq %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "+m" (v->counter)); ++ : "=3Dm" (v->counter) ++ : "m" (v->counter)); +} + +/** -+ * atomic_inc_unchecked - increment atomic variable -+ * @v: pointer of type atomic_unchecked_t ++ * atomic64_inc_unchecked - increment atomic64 variable ++ * @v: pointer to type atomic64_unchecked_t + * + * Atomically increments @v by 1. + */ -+static inline void atomic_inc_unchecked(atomic_unchecked_t *v) ++static inline void atomic64_inc_unchecked(atomic64_unchecked_t *v) +{ -+ asm volatile(LOCK_PREFIX "incl %0\n" - : "+m" (v->counter)); - } -=20 -@@ -104,7 +200,27 @@ static inline void atomic_inc(atomic_t * + asm volatile(LOCK_PREFIX "incq %0" + : "=3Dm" (v->counter) + : "m" (v->counter)); +@@ -101,7 +199,28 @@ static inline void atomic64_inc(atomic64_t *v) */ - static inline void atomic_dec(atomic_t *v) + static inline void atomic64_dec(atomic64_t *v) { -- asm volatile(LOCK_PREFIX "decl %0" -+ asm volatile(LOCK_PREFIX "decl %0\n" +- asm volatile(LOCK_PREFIX "decq %0" ++ asm volatile(LOCK_PREFIX "decq %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "incl %0\n" ++ LOCK_PREFIX "incq %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + -+ : "+m" (v->counter)); ++ : "=3Dm" (v->counter) ++ : "m" (v->counter)); +} + +/** -+ * atomic_dec_unchecked - decrement atomic variable -+ * @v: pointer of type atomic_unchecked_t ++ * atomic64_dec_unchecked - decrement atomic64 variable ++ * @v: pointer to type atomic64_t + * + * Atomically decrements @v by 1. + */ -+static inline void atomic_dec_unchecked(atomic_unchecked_t *v) ++static inline void atomic64_dec_unchecked(atomic64_unchecked_t *v) +{ -+ asm volatile(LOCK_PREFIX "decl %0\n" - : "+m" (v->counter)); ++ asm volatile(LOCK_PREFIX "decq %0\n" + : "=3Dm" (v->counter) + : "m" (v->counter)); } -=20 -@@ -120,7 +236,16 @@ static inline int atomic_dec_and_test(at +@@ -118,7 +237,16 @@ static inline int atomic64_dec_and_test(atomic64_t = *v) { unsigned char c; =20 -- asm volatile(LOCK_PREFIX "decl %0; sete %1" -+ asm volatile(LOCK_PREFIX "decl %0\n" +- asm volatile(LOCK_PREFIX "decq %0; sete %1" ++ asm volatile(LOCK_PREFIX "decq %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "incl %0\n" ++ LOCK_PREFIX "incq %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sete %1\n" - : "+m" (v->counter), "=3Dqm" (c) - : : "memory"); + : "=3Dm" (v->counter), "=3Dqm" (c) + : "m" (v->counter) : "memory"); return c !=3D 0; -@@ -138,7 +263,35 @@ static inline int atomic_inc_and_test(at +@@ -136,7 +264,16 @@ static inline int atomic64_inc_and_test(atomic64_t = *v) { unsigned char c; =20 -- asm volatile(LOCK_PREFIX "incl %0; sete %1" -+ asm volatile(LOCK_PREFIX "incl %0\n" +- asm volatile(LOCK_PREFIX "incq %0; sete %1" ++ asm volatile(LOCK_PREFIX "incq %0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "decl %0\n" ++ LOCK_PREFIX "decq %0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sete %1\n" -+ : "+m" (v->counter), "=3Dqm" (c) -+ : : "memory"); -+ return c !=3D 0; -+} -+ -+/** -+ * atomic_inc_and_test_unchecked - increment and test -+ * @v: pointer of type atomic_unchecked_t -+ * -+ * Atomically increments @v by 1 -+ * and returns true if the result is zero, or false for all -+ * other cases. -+ */ -+static inline int atomic_inc_and_test_unchecked(atomic_unchecked_t *v) -+{ -+ unsigned char c; -+ -+ asm volatile(LOCK_PREFIX "incl %0\n" -+ "sete %1\n" - : "+m" (v->counter), "=3Dqm" (c) - : : "memory"); + : "=3Dm" (v->counter), "=3Dqm" (c) + : "m" (v->counter) : "memory"); return c !=3D 0; -@@ -157,7 +310,16 @@ static inline int atomic_add_negative(in +@@ -155,7 +292,16 @@ static inline int atomic64_add_negative(long i, ato= mic64_t *v) { unsigned char c; =20 -- asm volatile(LOCK_PREFIX "addl %2,%0; sets %1" -+ asm volatile(LOCK_PREFIX "addl %2,%0\n" +- asm volatile(LOCK_PREFIX "addq %2,%0; sets %1" ++ asm volatile(LOCK_PREFIX "addq %2,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ LOCK_PREFIX "subl %2,%0\n" ++ LOCK_PREFIX "subq %2,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif + + "sets %1\n" - : "+m" (v->counter), "=3Dqm" (c) - : "ir" (i) : "memory"); + : "=3Dm" (v->counter), "=3Dqm" (c) + : "er" (i), "m" (v->counter) : "memory"); return c; -@@ -180,6 +342,46 @@ static inline int atomic_add_return(int=20 - #endif - /* Modern 486+ processor */ - __i =3D i; -+ asm volatile(LOCK_PREFIX "xaddl %0, %1\n" +@@ -171,7 +317,31 @@ static inline int atomic64_add_negative(long i, ato= mic64_t *v) + static inline long atomic64_add_return(long i, atomic64_t *v) + { + long __i =3D i; +- asm volatile(LOCK_PREFIX "xaddq %0, %1;" ++ asm volatile(LOCK_PREFIX "xaddq %0, %1\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ "movl %0, %1\n" ++ "movq %0, %1\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif @@ -7170,88 +7901,63 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/atomi= c.h linux-3.1.4/arch/x86/includ + : "+r" (i), "+m" (v->counter) + : : "memory"); + return i + __i; -+ -+#ifdef CONFIG_M386 -+no_xadd: /* Legacy 386 processor */ -+ local_irq_save(flags); -+ __i =3D atomic_read(v); -+ atomic_set(v, i + __i); -+ local_irq_restore(flags); -+ return i + __i; -+#endif +} + +/** -+ * atomic_add_return_unchecked - add integer and return -+ * @v: pointer of type atomic_unchecked_t ++ * atomic64_add_return_unchecked - add and return + * @i: integer value to add ++ * @v: pointer to type atomic64_unchecked_t + * + * Atomically adds @i to @v and returns @i + @v + */ -+static inline int atomic_add_return_unchecked(int i, atomic_unchecked_t= *v) ++static inline long atomic64_add_return_unchecked(long i, atomic64_unche= cked_t *v) +{ -+ int __i; -+#ifdef CONFIG_M386 -+ unsigned long flags; -+ if (unlikely(boot_cpu_data.x86 <=3D 3)) -+ goto no_xadd; -+#endif -+ /* Modern 486+ processor */ -+ __i =3D i; - asm volatile(LOCK_PREFIX "xaddl %0, %1" ++ long __i =3D i; ++ asm volatile(LOCK_PREFIX "xaddq %0, %1" : "+r" (i), "+m" (v->counter) : : "memory"); -@@ -208,6 +410,10 @@ static inline int atomic_sub_return(int=20 + return i + __i; +@@ -183,6 +353,10 @@ static inline long atomic64_sub_return(long i, atom= ic64_t *v) } =20 - #define atomic_inc_return(v) (atomic_add_return(1, v)) -+static inline int atomic_inc_return_unchecked(atomic_unchecked_t *v) + #define atomic64_inc_return(v) (atomic64_add_return(1, (v))) ++static inline long atomic64_inc_return_unchecked(atomic64_unchecked_t *= v) +{ -+ return atomic_add_return_unchecked(1, v); ++ return atomic64_add_return_unchecked(1, v); +} - #define atomic_dec_return(v) (atomic_sub_return(1, v)) + #define atomic64_dec_return(v) (atomic64_sub_return(1, (v))) =20 - static inline int atomic_cmpxchg(atomic_t *v, int old, int new) -@@ -215,11 +421,21 @@ static inline int atomic_cmpxchg(atomic_ + static inline long atomic64_cmpxchg(atomic64_t *v, long old, long new) +@@ -190,6 +364,11 @@ static inline long atomic64_cmpxchg(atomic64_t *v, = long old, long new) return cmpxchg(&v->counter, old, new); } =20 -+static inline int atomic_cmpxchg_unchecked(atomic_unchecked_t *v, int o= ld, int new) ++static inline long atomic64_cmpxchg_unchecked(atomic64_unchecked_t *v, = long old, long new) +{ + return cmpxchg(&v->counter, old, new); +} + - static inline int atomic_xchg(atomic_t *v, int new) + static inline long atomic64_xchg(atomic64_t *v, long new) { return xchg(&v->counter, new); - } -=20 -+static inline int atomic_xchg_unchecked(atomic_unchecked_t *v, int new) -+{ -+ return xchg(&v->counter, new); -+} -+ - /** - * __atomic_add_unless - add unless the number is already a given value - * @v: pointer of type atomic_t -@@ -231,12 +447,25 @@ static inline int atomic_xchg(atomic_t * +@@ -206,17 +385,30 @@ static inline long atomic64_xchg(atomic64_t *v, lo= ng new) */ - static inline int __atomic_add_unless(atomic_t *v, int a, int u) + static inline int atomic64_add_unless(atomic64_t *v, long a, long u) { -- int c, old; -+ int c, old, new; - c =3D atomic_read(v); +- long c, old; ++ long c, old, new; + c =3D atomic64_read(v); for (;;) { - if (unlikely(c =3D=3D (u))) + if (unlikely(c =3D=3D u)) break; -- old =3D atomic_cmpxchg((v), c, c + (a)); +- old =3D atomic64_cmpxchg((v), c, c + (a)); + -+ asm volatile("addl %2,%0\n" ++ asm volatile("add %2,%0\n" + +#ifdef CONFIG_PAX_REFCOUNT + "jno 0f\n" -+ "subl %2,%0\n" ++ "sub %2,%0\n" + "int $4\n0:\n" + _ASM_EXTABLE(0b, 0b) +#endif @@ -7259,62 +7965,20 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/atomi= c.h linux-3.1.4/arch/x86/includ + : "=3Dr" (new) + : "0" (c), "ir" (a)); + -+ old =3D atomic_cmpxchg(v, c, new); ++ old =3D atomic64_cmpxchg(v, c, new); if (likely(old =3D=3D c)) break; c =3D old; -@@ -244,6 +473,48 @@ static inline int __atomic_add_unless(at - return c; + } +- return c !=3D (u); ++ return c !=3D u; } =20 -+/** -+ * atomic_inc_not_zero_hint - increment if not null -+ * @v: pointer of type atomic_t -+ * @hint: probable value of the atomic before the increment -+ * -+ * This version of atomic_inc_not_zero() gives a hint of probable -+ * value of the atomic. This helps processor to not read the memory -+ * before doing the atomic read/modify/write cycle, lowering -+ * number of bus transactions on some arches. -+ * -+ * Returns: 0 if increment was not done, 1 otherwise. -+ */ -+#define atomic_inc_not_zero_hint atomic_inc_not_zero_hint -+static inline int atomic_inc_not_zero_hint(atomic_t *v, int hint) -+{ -+ int val, c =3D hint, new; -+ -+ /* sanity test, should be removed by compiler if hint is a constant */ -+ if (!hint) -+ return __atomic_add_unless(v, 1, 0); -+ -+ do { -+ asm volatile("incl %0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ "decl %0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ : "=3Dr" (new) -+ : "0" (c)); -+ -+ val =3D atomic_cmpxchg(v, c, new); -+ if (val =3D=3D c) -+ return 1; -+ c =3D val; -+ } while (c); -+ -+ return 0; -+} -=20 - /* - * atomic_dec_if_positive - decrement by 1 if old value positive -diff -urNp linux-3.1.4/arch/x86/include/asm/bitops.h linux-3.1.4/arch/x8= 6/include/asm/bitops.h ---- linux-3.1.4/arch/x86/include/asm/bitops.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/bitops.h 2011-11-16 18:39:07.000000= 000 -0500 + #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) +diff --git a/arch/x86/include/asm/bitops.h b/arch/x86/include/asm/bitops= .h +index 1775d6e..b65017f 100644 +--- a/arch/x86/include/asm/bitops.h ++++ b/arch/x86/include/asm/bitops.h @@ -38,7 +38,7 @@ * a mask operation on a byte. */ @@ -7324,9 +7988,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/bitops= .h linux-3.1.4/arch/x86/includ #define CONST_MASK(nr) (1 << ((nr) & 7)) =20 /** -diff -urNp linux-3.1.4/arch/x86/include/asm/boot.h linux-3.1.4/arch/x86/= include/asm/boot.h ---- linux-3.1.4/arch/x86/include/asm/boot.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/include/asm/boot.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/x86/include/asm/boot.h b/arch/x86/include/asm/boot.h +index 5e1a2ee..c9f9533 100644 +--- a/arch/x86/include/asm/boot.h ++++ b/arch/x86/include/asm/boot.h @@ -11,10 +11,15 @@ #include =20 @@ -7344,21 +8009,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/boot.= h linux-3.1.4/arch/x86/include/ /* Minimum kernel alignment, as a power of two */ #ifdef CONFIG_X86_64 #define MIN_KERNEL_ALIGN_LG2 PMD_SHIFT -diff -urNp linux-3.1.4/arch/x86/include/asm/cacheflush.h linux-3.1.4/arc= h/x86/include/asm/cacheflush.h ---- linux-3.1.4/arch/x86/include/asm/cacheflush.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/cacheflush.h 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -26,7 +26,7 @@ static inline unsigned long get_page_mem - unsigned long pg_flags =3D pg->flags & _PGMT_MASK; -=20 - if (pg_flags =3D=3D _PGMT_DEFAULT) -- return -1; -+ return ~0UL; - else if (pg_flags =3D=3D _PGMT_WC) - return _PAGE_CACHE_WC; - else if (pg_flags =3D=3D _PGMT_UC_MINUS) -diff -urNp linux-3.1.4/arch/x86/include/asm/cache.h linux-3.1.4/arch/x86= /include/asm/cache.h ---- linux-3.1.4/arch/x86/include/asm/cache.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/include/asm/cache.h 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/include/asm/cache.h b/arch/x86/include/asm/cache.h +index 48f99f1..d78ebf9 100644 +--- a/arch/x86/include/asm/cache.h ++++ b/arch/x86/include/asm/cache.h @@ -5,12 +5,13 @@ =20 /* L1 cache line size */ @@ -7375,10 +8029,24 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/cache= .h linux-3.1.4/arch/x86/include =20 #ifdef CONFIG_X86_VSMP #ifdef CONFIG_SMP -diff -urNp linux-3.1.4/arch/x86/include/asm/checksum_32.h linux-3.1.4/ar= ch/x86/include/asm/checksum_32.h ---- linux-3.1.4/arch/x86/include/asm/checksum_32.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/checksum_32.h 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -31,6 +31,14 @@ asmlinkage __wsum csum_partial_copy_gene +diff --git a/arch/x86/include/asm/cacheflush.h b/arch/x86/include/asm/ca= cheflush.h +index 4e12668..501d239 100644 +--- a/arch/x86/include/asm/cacheflush.h ++++ b/arch/x86/include/asm/cacheflush.h +@@ -26,7 +26,7 @@ static inline unsigned long get_page_memtype(struct pa= ge *pg) + unsigned long pg_flags =3D pg->flags & _PGMT_MASK; +=20 + if (pg_flags =3D=3D _PGMT_DEFAULT) +- return -1; ++ return ~0UL; + else if (pg_flags =3D=3D _PGMT_WC) + return _PAGE_CACHE_WC; + else if (pg_flags =3D=3D _PGMT_UC_MINUS) +diff --git a/arch/x86/include/asm/checksum_32.h b/arch/x86/include/asm/c= hecksum_32.h +index 46fc474..b02b0f9 100644 +--- a/arch/x86/include/asm/checksum_32.h ++++ b/arch/x86/include/asm/checksum_32.h +@@ -31,6 +31,14 @@ asmlinkage __wsum csum_partial_copy_generic(const voi= d *src, void *dst, int len, __wsum sum, int *src_err_ptr, int *dst_err_ptr); =20 @@ -7393,7 +8061,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/checksu= m_32.h linux-3.1.4/arch/x86/i /* * Note: when you get a NULL pointer exception here this means someone * passed in an incorrect kernel address to one of these functions. -@@ -50,7 +58,7 @@ static inline __wsum csum_partial_copy_f +@@ -50,7 +58,7 @@ static inline __wsum csum_partial_copy_from_user(const= void __user *src, int *err_ptr) { might_sleep(); @@ -7402,7 +8070,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/checksu= m_32.h linux-3.1.4/arch/x86/i len, sum, err_ptr, NULL); } =20 -@@ -178,7 +186,7 @@ static inline __wsum csum_and_copy_to_us +@@ -178,7 +186,7 @@ static inline __wsum csum_and_copy_to_user(const voi= d *src, { might_sleep(); if (access_ok(VERIFY_WRITE, dst, len)) @@ -7411,10 +8079,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/check= sum_32.h linux-3.1.4/arch/x86/i len, sum, NULL, err_ptr); =20 if (len) -diff -urNp linux-3.1.4/arch/x86/include/asm/cpufeature.h linux-3.1.4/arc= h/x86/include/asm/cpufeature.h ---- linux-3.1.4/arch/x86/include/asm/cpufeature.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/cpufeature.h 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -358,7 +358,7 @@ static __always_inline __pure bool __sta +diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cp= ufeature.h +index 88b23a4..d2e5f9f 100644 +--- a/arch/x86/include/asm/cpufeature.h ++++ b/arch/x86/include/asm/cpufeature.h +@@ -358,7 +358,7 @@ static __always_inline __pure bool __static_cpu_has(= u16 bit) ".section .discard,\"aw\",@progbits\n" " .byte 0xff + (4f-3f) - (2b-1b)\n" /* size check */ ".previous\n" @@ -7423,25 +8092,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/cpufe= ature.h linux-3.1.4/arch/x86/in "3: movb $1,%0\n" "4:\n" ".previous\n" -diff -urNp linux-3.1.4/arch/x86/include/asm/desc_defs.h linux-3.1.4/arch= /x86/include/asm/desc_defs.h ---- linux-3.1.4/arch/x86/include/asm/desc_defs.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/desc_defs.h 2011-11-16 18:39:07.000= 000000 -0500 -@@ -31,6 +31,12 @@ struct desc_struct { - unsigned base1: 8, type: 4, s: 1, dpl: 2, p: 1; - unsigned limit: 4, avl: 1, l: 1, d: 1, g: 1, base2: 8; - }; -+ struct { -+ u16 offset_low; -+ u16 seg; -+ unsigned reserved: 8, type: 4, s: 1, dpl: 2, p: 1; -+ unsigned offset_high: 16; -+ } gate; - }; - } __attribute__((packed)); -=20 -diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h linux-3.1.4/arch/x86/= include/asm/desc.h ---- linux-3.1.4/arch/x86/include/asm/desc.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/include/asm/desc.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/x86/include/asm/desc.h b/arch/x86/include/asm/desc.h +index 41935fa..3b40db8 100644 +--- a/arch/x86/include/asm/desc.h ++++ b/arch/x86/include/asm/desc.h @@ -4,6 +4,7 @@ #include #include @@ -7450,7 +8104,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ =20 #include =20 -@@ -16,6 +17,7 @@ static inline void fill_ldt(struct desc_ +@@ -16,6 +17,7 @@ static inline void fill_ldt(struct desc_struct *desc, = const struct user_desc *in =20 desc->type =3D (info->read_exec_only ^ 1) << 1; desc->type |=3D info->contents << 2; @@ -7458,7 +8112,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ =20 desc->s =3D 1; desc->dpl =3D 0x3; -@@ -34,17 +36,12 @@ static inline void fill_ldt(struct desc_ +@@ -34,17 +36,12 @@ static inline void fill_ldt(struct desc_struct *desc= , const struct user_desc *in } =20 extern struct desc_ptr idt_descr; @@ -7479,7 +8133,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ } =20 #ifdef CONFIG_X86_64 -@@ -69,8 +66,14 @@ static inline void pack_gate(gate_desc * +@@ -69,8 +66,14 @@ static inline void pack_gate(gate_desc *gate, unsigne= d char type, unsigned long base, unsigned dpl, unsigned flags, unsigned short seg) { @@ -7496,7 +8150,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ } =20 #endif -@@ -115,12 +118,16 @@ static inline void paravirt_free_ldt(str +@@ -115,12 +118,16 @@ static inline void paravirt_free_ldt(struct desc_s= truct *ldt, unsigned entries) =20 static inline void native_write_idt_entry(gate_desc *idt, int entry, co= nst gate_desc *gate) { @@ -7513,7 +8167,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ } =20 static inline void -@@ -134,7 +141,9 @@ native_write_gdt_entry(struct desc_struc +@@ -134,7 +141,9 @@ native_write_gdt_entry(struct desc_struct *gdt, int = entry, const void *desc, int default: size =3D sizeof(*gdt); break; } =20 @@ -7523,7 +8177,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ } =20 static inline void pack_descriptor(struct desc_struct *desc, unsigned l= ong base, -@@ -207,7 +216,9 @@ static inline void native_set_ldt(const=20 +@@ -207,7 +216,9 @@ static inline void native_set_ldt(const void *addr, = unsigned int entries) =20 static inline void native_load_tr_desc(void) { @@ -7533,7 +8187,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ } =20 static inline void native_load_gdt(const struct desc_ptr *dtr) -@@ -244,8 +255,10 @@ static inline void native_load_tls(struc +@@ -244,8 +255,10 @@ static inline void native_load_tls(struct thread_st= ruct *t, unsigned int cpu) struct desc_struct *gdt =3D get_cpu_gdt_table(cpu); unsigned int i; =20 @@ -7544,7 +8198,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ } =20 #define _LDT_empty(info) \ -@@ -307,7 +320,7 @@ static inline void set_desc_limit(struct +@@ -307,7 +320,7 @@ static inline void set_desc_limit(struct desc_struct= *desc, unsigned long limit) desc->limit =3D (limit >> 16) & 0xf; } =20 @@ -7553,7 +8207,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ unsigned dpl, unsigned ist, unsigned seg) { gate_desc s; -@@ -326,7 +339,7 @@ static inline void _set_gate(int gate, u +@@ -326,7 +339,7 @@ static inline void _set_gate(int gate, unsigned type= , void *addr, * Pentium F0 0F bugfix can have resulted in the mapped * IDT being write-protected. */ @@ -7562,7 +8216,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ { BUG_ON((unsigned)n > 0xFF); _set_gate(n, GATE_INTERRUPT, addr, 0, 0, __KERNEL_CS); -@@ -356,19 +369,19 @@ static inline void alloc_intr_gate(unsig +@@ -356,19 +369,19 @@ static inline void alloc_intr_gate(unsigned int n,= void *addr) /* * This routine sets up an interrupt gate at directory privilege level = 3. */ @@ -7585,7 +8239,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h = linux-3.1.4/arch/x86/include/ { BUG_ON((unsigned)n > 0xFF); _set_gate(n, GATE_TRAP, addr, 0, 0, __KERNEL_CS); -@@ -377,19 +390,31 @@ static inline void set_trap_gate(unsigne +@@ -377,19 +390,31 @@ static inline void set_trap_gate(unsigned int n, v= oid *addr) static inline void set_task_gate(unsigned int n, unsigned int gdt_entry= ) { BUG_ON((unsigned)n > 0xFF); @@ -7620,9 +8274,27 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/desc.h= linux-3.1.4/arch/x86/include/ +#endif + #endif /* _ASM_X86_DESC_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/e820.h linux-3.1.4/arch/x86/= include/asm/e820.h ---- linux-3.1.4/arch/x86/include/asm/e820.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/include/asm/e820.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/x86/include/asm/desc_defs.h b/arch/x86/include/asm/des= c_defs.h +index 278441f..b95a174 100644 +--- a/arch/x86/include/asm/desc_defs.h ++++ b/arch/x86/include/asm/desc_defs.h +@@ -31,6 +31,12 @@ struct desc_struct { + unsigned base1: 8, type: 4, s: 1, dpl: 2, p: 1; + unsigned limit: 4, avl: 1, l: 1, d: 1, g: 1, base2: 8; + }; ++ struct { ++ u16 offset_low; ++ u16 seg; ++ unsigned reserved: 8, type: 4, s: 1, dpl: 2, p: 1; ++ unsigned offset_high: 16; ++ } gate; + }; + } __attribute__((packed)); +=20 +diff --git a/arch/x86/include/asm/e820.h b/arch/x86/include/asm/e820.h +index 908b969..a1f4eb4 100644 +--- a/arch/x86/include/asm/e820.h ++++ b/arch/x86/include/asm/e820.h @@ -69,7 +69,7 @@ struct e820map { #define ISA_START_ADDRESS 0xa0000 #define ISA_END_ADDRESS 0x100000 @@ -7632,9 +8304,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/e820.h= linux-3.1.4/arch/x86/include/ #define BIOS_END 0x00100000 =20 #define BIOS_ROM_BASE 0xffe00000 -diff -urNp linux-3.1.4/arch/x86/include/asm/elf.h linux-3.1.4/arch/x86/i= nclude/asm/elf.h ---- linux-3.1.4/arch/x86/include/asm/elf.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/include/asm/elf.h 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/x86/include/asm/elf.h b/arch/x86/include/asm/elf.h +index f2ad216..eb24c96 100644 +--- a/arch/x86/include/asm/elf.h ++++ b/arch/x86/include/asm/elf.h @@ -237,7 +237,25 @@ extern int force_personality32; the loader. We need to make sure that it is out of the way of the p= rogram that it will "exec", and that there is sufficient room for the brk. = */ @@ -7681,7 +8354,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/elf.h l= inux-3.1.4/arch/x86/include/a =20 #define VDSO_ENTRY \ ((unsigned long)VDSO32_SYMBOL(VDSO_CURRENT_BASE, vsyscall)) -@@ -317,7 +333,4 @@ extern int arch_setup_additional_pages(s +@@ -317,7 +333,4 @@ extern int arch_setup_additional_pages(struct linux_= binprm *bprm, extern int syscall32_setup_pages(struct linux_binprm *, int exstack); #define compat_arch_setup_additional_pages syscall32_setup_pages =20 @@ -7689,9 +8362,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/elf.h = linux-3.1.4/arch/x86/include/a -#define arch_randomize_brk arch_randomize_brk - #endif /* _ASM_X86_ELF_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/emergency-restart.h linux-3.= 1.4/arch/x86/include/asm/emergency-restart.h ---- linux-3.1.4/arch/x86/include/asm/emergency-restart.h 2011-11-11 15:1= 9:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/emergency-restart.h 2011-11-16 18:3= 9:07.000000000 -0500 +diff --git a/arch/x86/include/asm/emergency-restart.h b/arch/x86/include= /asm/emergency-restart.h +index cc70c1c..d96d011 100644 +--- a/arch/x86/include/asm/emergency-restart.h ++++ b/arch/x86/include/asm/emergency-restart.h @@ -15,6 +15,6 @@ enum reboot_type { =20 extern enum reboot_type reboot_type; @@ -7700,9 +8374,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/emerge= ncy-restart.h linux-3.1.4/arch +extern void machine_emergency_restart(void) __noreturn; =20 #endif /* _ASM_X86_EMERGENCY_RESTART_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/futex.h linux-3.1.4/arch/x86= /include/asm/futex.h ---- linux-3.1.4/arch/x86/include/asm/futex.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/include/asm/futex.h 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/include/asm/futex.h b/arch/x86/include/asm/futex.h +index d09bb03..4ea4194 100644 +--- a/arch/x86/include/asm/futex.h ++++ b/arch/x86/include/asm/futex.h @@ -12,16 +12,18 @@ #include =20 @@ -7732,7 +8407,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/futex.h= linux-3.1.4/arch/x86/include : "r" (oparg), "i" (-EFAULT), "1" (0)) =20 static inline int futex_atomic_op_inuser(int encoded_op, u32 __user *ua= ddr) -@@ -61,10 +63,10 @@ static inline int futex_atomic_op_inuser +@@ -61,10 +63,10 @@ static inline int futex_atomic_op_inuser(int encoded= _op, u32 __user *uaddr) =20 switch (op) { case FUTEX_OP_SET: @@ -7745,7 +8420,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/futex.h= linux-3.1.4/arch/x86/include uaddr, oparg); break; case FUTEX_OP_OR: -@@ -123,13 +125,13 @@ static inline int futex_atomic_cmpxchg_i +@@ -123,13 +125,13 @@ static inline int futex_atomic_cmpxchg_inatomic(u3= 2 *uval, u32 __user *uaddr, if (!access_ok(VERIFY_WRITE, uaddr, sizeof(u32))) return -EFAULT; =20 @@ -7761,9 +8436,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/futex.= h linux-3.1.4/arch/x86/include : "i" (-EFAULT), "r" (newval), "1" (oldval) : "memory" ); -diff -urNp linux-3.1.4/arch/x86/include/asm/hw_irq.h linux-3.1.4/arch/x8= 6/include/asm/hw_irq.h ---- linux-3.1.4/arch/x86/include/asm/hw_irq.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/hw_irq.h 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/include/asm/hw_irq.h b/arch/x86/include/asm/hw_irq= .h +index 0919905..2cf38d6 100644 +--- a/arch/x86/include/asm/hw_irq.h ++++ b/arch/x86/include/asm/hw_irq.h @@ -136,8 +136,8 @@ extern void setup_ioapic_dest(void); extern void enable_IO_APIC(void); =20 @@ -7775,10 +8451,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/hw_ir= q.h linux-3.1.4/arch/x86/includ =20 /* EISA */ extern void eisa_set_level_irq(unsigned int irq); -diff -urNp linux-3.1.4/arch/x86/include/asm/i387.h linux-3.1.4/arch/x86/= include/asm/i387.h ---- linux-3.1.4/arch/x86/include/asm/i387.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/include/asm/i387.h 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -92,6 +92,11 @@ static inline int fxrstor_checking(struc +diff --git a/arch/x86/include/asm/i387.h b/arch/x86/include/asm/i387.h +index c9e09ea..73888df 100644 +--- a/arch/x86/include/asm/i387.h ++++ b/arch/x86/include/asm/i387.h +@@ -92,6 +92,11 @@ static inline int fxrstor_checking(struct i387_fxsave= _struct *fx) { int err; =20 @@ -7790,7 +8467,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/i387.h = linux-3.1.4/arch/x86/include/ /* See comment in fxsave() below. */ #ifdef CONFIG_AS_FXSAVEQ asm volatile("1: fxrstorq %[fx]\n\t" -@@ -121,6 +126,11 @@ static inline int fxsave_user(struct i38 +@@ -121,6 +126,11 @@ static inline int fxsave_user(struct i387_fxsave_st= ruct __user *fx) { int err; =20 @@ -7802,7 +8479,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/i387.h = linux-3.1.4/arch/x86/include/ /* * Clear the bytes not touched by the fxsave and reserved * for the SW usage. -@@ -213,13 +223,8 @@ static inline void fpu_fxsave(struct fpu +@@ -213,13 +223,8 @@ static inline void fpu_fxsave(struct fpu *fpu) #endif /* CONFIG_X86_64 */ =20 /* We need a safe address that is cheap to find and that is already @@ -7818,7 +8495,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/i387.h = linux-3.1.4/arch/x86/include/ =20 /* * These must be called with preempt disabled -@@ -312,7 +317,7 @@ static inline void kernel_fpu_begin(void +@@ -312,7 +317,7 @@ static inline void kernel_fpu_begin(void) struct thread_info *me =3D current_thread_info(); preempt_disable(); if (me->status & TS_USEDFPU) @@ -7827,9 +8504,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/i387.h= linux-3.1.4/arch/x86/include/ else clts(); } -diff -urNp linux-3.1.4/arch/x86/include/asm/io.h linux-3.1.4/arch/x86/in= clude/asm/io.h ---- linux-3.1.4/arch/x86/include/asm/io.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/include/asm/io.h 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/arch/x86/include/asm/io.h b/arch/x86/include/asm/io.h +index d8e8eef..99f81ae 100644 +--- a/arch/x86/include/asm/io.h ++++ b/arch/x86/include/asm/io.h @@ -194,6 +194,17 @@ extern void set_iounmap_nonlazy(void); =20 #include @@ -7848,10 +8526,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/io.h = linux-3.1.4/arch/x86/include/as /* * Convert a virtual cached pointer to an uncached pointer */ -diff -urNp linux-3.1.4/arch/x86/include/asm/irqflags.h linux-3.1.4/arch/= x86/include/asm/irqflags.h ---- linux-3.1.4/arch/x86/include/asm/irqflags.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/irqflags.h 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -141,6 +141,11 @@ static inline notrace unsigned long arch +diff --git a/arch/x86/include/asm/irqflags.h b/arch/x86/include/asm/irqf= lags.h +index bba3cf8..06bc8da 100644 +--- a/arch/x86/include/asm/irqflags.h ++++ b/arch/x86/include/asm/irqflags.h +@@ -141,6 +141,11 @@ static inline notrace unsigned long arch_local_irq_= save(void) sti; \ sysexit =20 @@ -7863,9 +8542,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/irqfla= gs.h linux-3.1.4/arch/x86/incl #else #define INTERRUPT_RETURN iret #define ENABLE_INTERRUPTS_SYSEXIT sti; sysexit -diff -urNp linux-3.1.4/arch/x86/include/asm/kprobes.h linux-3.1.4/arch/x= 86/include/asm/kprobes.h ---- linux-3.1.4/arch/x86/include/asm/kprobes.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/kprobes.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/x86/include/asm/kprobes.h b/arch/x86/include/asm/kprob= es.h +index 5478825..839e88c 100644 +--- a/arch/x86/include/asm/kprobes.h ++++ b/arch/x86/include/asm/kprobes.h @@ -37,13 +37,8 @@ typedef u8 kprobe_opcode_t; #define RELATIVEJUMP_SIZE 5 #define RELATIVECALL_OPCODE 0xe8 @@ -7882,9 +8562,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/kprobe= s.h linux-3.1.4/arch/x86/inclu =20 #define flush_insn_slot(p) do { } while (0) =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/kvm_host.h linux-3.1.4/arch/= x86/include/asm/kvm_host.h ---- linux-3.1.4/arch/x86/include/asm/kvm_host.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/kvm_host.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_= host.h +index dd51c83..66cbfac 100644 +--- a/arch/x86/include/asm/kvm_host.h ++++ b/arch/x86/include/asm/kvm_host.h @@ -456,7 +456,7 @@ struct kvm_arch { unsigned int n_requested_mmu_pages; unsigned int n_max_mmu_pages; @@ -7903,9 +8584,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/kvm_ho= st.h linux-3.1.4/arch/x86/incl =20 struct kvm_arch_async_pf { u32 token; -diff -urNp linux-3.1.4/arch/x86/include/asm/local.h linux-3.1.4/arch/x86= /include/asm/local.h ---- linux-3.1.4/arch/x86/include/asm/local.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/include/asm/local.h 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/include/asm/local.h b/arch/x86/include/asm/local.h +index 9cdae5d..300d20f 100644 +--- a/arch/x86/include/asm/local.h ++++ b/arch/x86/include/asm/local.h @@ -18,26 +18,58 @@ typedef struct { =20 static inline void local_inc(local_t *l) @@ -7969,7 +8651,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/local.h= linux-3.1.4/arch/x86/include : "+m" (l->a.counter) : "ir" (i)); } -@@ -55,7 +87,16 @@ static inline int local_sub_and_test(lon +@@ -55,7 +87,16 @@ static inline int local_sub_and_test(long i, local_t = *l) { unsigned char c; =20 @@ -7987,7 +8669,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/local.h= linux-3.1.4/arch/x86/include : "+m" (l->a.counter), "=3Dqm" (c) : "ir" (i) : "memory"); return c; -@@ -73,7 +114,16 @@ static inline int local_dec_and_test(loc +@@ -73,7 +114,16 @@ static inline int local_dec_and_test(local_t *l) { unsigned char c; =20 @@ -8005,7 +8687,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/local.h= linux-3.1.4/arch/x86/include : "+m" (l->a.counter), "=3Dqm" (c) : : "memory"); return c !=3D 0; -@@ -91,7 +141,16 @@ static inline int local_inc_and_test(loc +@@ -91,7 +141,16 @@ static inline int local_inc_and_test(local_t *l) { unsigned char c; =20 @@ -8023,7 +8705,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/local.h= linux-3.1.4/arch/x86/include : "+m" (l->a.counter), "=3Dqm" (c) : : "memory"); return c !=3D 0; -@@ -110,7 +169,16 @@ static inline int local_add_negative(lon +@@ -110,7 +169,16 @@ static inline int local_add_negative(long i, local_= t *l) { unsigned char c; =20 @@ -8041,7 +8723,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/local.h= linux-3.1.4/arch/x86/include : "+m" (l->a.counter), "=3Dqm" (c) : "ir" (i) : "memory"); return c; -@@ -133,7 +201,15 @@ static inline long local_add_return(long +@@ -133,7 +201,15 @@ static inline long local_add_return(long i, local_t= *l) #endif /* Modern 486+ processor */ __i =3D i; @@ -8058,9 +8740,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/local.= h linux-3.1.4/arch/x86/include : "+r" (i), "+m" (l->a.counter) : : "memory"); return i + __i; -diff -urNp linux-3.1.4/arch/x86/include/asm/mman.h linux-3.1.4/arch/x86/= include/asm/mman.h ---- linux-3.1.4/arch/x86/include/asm/mman.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/include/asm/mman.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/x86/include/asm/mman.h b/arch/x86/include/asm/mman.h +index 593e51d..fa69c9a 100644 +--- a/arch/x86/include/asm/mman.h ++++ b/arch/x86/include/asm/mman.h @@ -5,4 +5,14 @@ =20 #include @@ -8076,132 +8759,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/mman= .h linux-3.1.4/arch/x86/include/ +#endif + #endif /* _ASM_X86_MMAN_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/mmu_context.h linux-3.1.4/ar= ch/x86/include/asm/mmu_context.h ---- linux-3.1.4/arch/x86/include/asm/mmu_context.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/mmu_context.h 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -24,6 +24,18 @@ void destroy_context(struct mm_struct *m -=20 - static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_str= uct *tsk) - { -+ -+#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) -+ unsigned int i; -+ pgd_t *pgd; -+ -+ pax_open_kernel(); -+ pgd =3D get_cpu_pgd(smp_processor_id()); -+ for (i =3D USER_PGD_PTRS; i < 2 * USER_PGD_PTRS; ++i) -+ set_pgd_batched(pgd+i, native_make_pgd(0)); -+ pax_close_kernel(); -+#endif -+ - #ifdef CONFIG_SMP - if (percpu_read(cpu_tlbstate.state) =3D=3D TLBSTATE_OK) - percpu_write(cpu_tlbstate.state, TLBSTATE_LAZY); -@@ -34,16 +46,30 @@ static inline void switch_mm(struct mm_s - struct task_struct *tsk) - { - unsigned cpu =3D smp_processor_id(); -+#if defined(CONFIG_X86_32) && defined(CONFIG_SMP) && (defined(CONFIG_PA= X_PAGEEXEC) || defined(CONFIG_PAX_SEGMEXEC)) -+ int tlbstate =3D TLBSTATE_OK; -+#endif -=20 - if (likely(prev !=3D next)) { - #ifdef CONFIG_SMP -+#if defined(CONFIG_X86_32) && (defined(CONFIG_PAX_PAGEEXEC) || defined(= CONFIG_PAX_SEGMEXEC)) -+ tlbstate =3D percpu_read(cpu_tlbstate.state); -+#endif - percpu_write(cpu_tlbstate.state, TLBSTATE_OK); - percpu_write(cpu_tlbstate.active_mm, next); - #endif - cpumask_set_cpu(cpu, mm_cpumask(next)); -=20 - /* Re-load page tables */ -+#ifdef CONFIG_PAX_PER_CPU_PGD -+ pax_open_kernel(); -+ __clone_user_pgds(get_cpu_pgd(cpu), next->pgd, USER_PGD_PTRS); -+ __shadow_user_pgds(get_cpu_pgd(cpu) + USER_PGD_PTRS, next->pgd, USER_= PGD_PTRS); -+ pax_close_kernel(); -+ load_cr3(get_cpu_pgd(cpu)); -+#else - load_cr3(next->pgd); -+#endif -=20 - /* stop flush ipis for the previous mm */ - cpumask_clear_cpu(cpu, mm_cpumask(prev)); -@@ -53,9 +79,38 @@ static inline void switch_mm(struct mm_s - */ - if (unlikely(prev->context.ldt !=3D next->context.ldt)) - load_LDT_nolock(&next->context); -- } -+ -+#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_PAGEEXEC) && defined(C= ONFIG_SMP) -+ if (!(__supported_pte_mask & _PAGE_NX)) { -+ smp_mb__before_clear_bit(); -+ cpu_clear(cpu, prev->context.cpu_user_cs_mask); -+ smp_mb__after_clear_bit(); -+ cpu_set(cpu, next->context.cpu_user_cs_mask); -+ } -+#endif -+ -+#if defined(CONFIG_X86_32) && (defined(CONFIG_PAX_PAGEEXEC) || defined(= CONFIG_PAX_SEGMEXEC)) -+ if (unlikely(prev->context.user_cs_base !=3D next->context.user_cs_ba= se || -+ prev->context.user_cs_limit !=3D next->context.user_cs_limit)) -+ set_user_cs(next->context.user_cs_base, next->context.user_cs_limit,= cpu); - #ifdef CONFIG_SMP -+ else if (unlikely(tlbstate !=3D TLBSTATE_OK)) -+ set_user_cs(next->context.user_cs_base, next->context.user_cs_limit,= cpu); -+#endif -+#endif -+ -+ } - else { -+ -+#ifdef CONFIG_PAX_PER_CPU_PGD -+ pax_open_kernel(); -+ __clone_user_pgds(get_cpu_pgd(cpu), next->pgd, USER_PGD_PTRS); -+ __shadow_user_pgds(get_cpu_pgd(cpu) + USER_PGD_PTRS, next->pgd, USER_= PGD_PTRS); -+ pax_close_kernel(); -+ load_cr3(get_cpu_pgd(cpu)); -+#endif -+ -+#ifdef CONFIG_SMP - percpu_write(cpu_tlbstate.state, TLBSTATE_OK); - BUG_ON(percpu_read(cpu_tlbstate.active_mm) !=3D next); -=20 -@@ -64,11 +119,28 @@ static inline void switch_mm(struct mm_s - * tlb flush IPI delivery. We must reload CR3 - * to make sure to use no freed page tables. - */ -+ -+#ifndef CONFIG_PAX_PER_CPU_PGD - load_cr3(next->pgd); -+#endif -+ - load_LDT_nolock(&next->context); -+ -+#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_PAGEEXEC) -+ if (!(__supported_pte_mask & _PAGE_NX)) -+ cpu_set(cpu, next->context.cpu_user_cs_mask); -+#endif -+ -+#if defined(CONFIG_X86_32) && (defined(CONFIG_PAX_PAGEEXEC) || defined(= CONFIG_PAX_SEGMEXEC)) -+#ifdef CONFIG_PAX_PAGEEXEC -+ if (!((next->pax_flags & MF_PAX_PAGEEXEC) && (__supported_pte_mask &= _PAGE_NX))) -+#endif -+ set_user_cs(next->context.user_cs_base, next->context.user_cs_limit= , cpu); -+#endif -+ - } -- } - #endif -+ } - } -=20 - #define activate_mm(prev, next) \ -diff -urNp linux-3.1.4/arch/x86/include/asm/mmu.h linux-3.1.4/arch/x86/i= nclude/asm/mmu.h ---- linux-3.1.4/arch/x86/include/asm/mmu.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/include/asm/mmu.h 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/x86/include/asm/mmu.h b/arch/x86/include/asm/mmu.h +index 5f55e69..e20bfb1 100644 +--- a/arch/x86/include/asm/mmu.h ++++ b/arch/x86/include/asm/mmu.h @@ -9,7 +9,7 @@ * we put the segment information here. */ @@ -8232,9 +8793,134 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/mmu.h= linux-3.1.4/arch/x86/include/a } mm_context_t; =20 #ifdef CONFIG_SMP -diff -urNp linux-3.1.4/arch/x86/include/asm/module.h linux-3.1.4/arch/x8= 6/include/asm/module.h ---- linux-3.1.4/arch/x86/include/asm/module.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/module.h 2011-12-02 17:38:47.000000= 000 -0500 +diff --git a/arch/x86/include/asm/mmu_context.h b/arch/x86/include/asm/m= mu_context.h +index 6902152..399f3a2 100644 +--- a/arch/x86/include/asm/mmu_context.h ++++ b/arch/x86/include/asm/mmu_context.h +@@ -24,6 +24,18 @@ void destroy_context(struct mm_struct *mm); +=20 + static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_str= uct *tsk) + { ++ ++#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) ++ unsigned int i; ++ pgd_t *pgd; ++ ++ pax_open_kernel(); ++ pgd =3D get_cpu_pgd(smp_processor_id()); ++ for (i =3D USER_PGD_PTRS; i < 2 * USER_PGD_PTRS; ++i) ++ set_pgd_batched(pgd+i, native_make_pgd(0)); ++ pax_close_kernel(); ++#endif ++ + #ifdef CONFIG_SMP + if (percpu_read(cpu_tlbstate.state) =3D=3D TLBSTATE_OK) + percpu_write(cpu_tlbstate.state, TLBSTATE_LAZY); +@@ -34,16 +46,30 @@ static inline void switch_mm(struct mm_struct *prev,= struct mm_struct *next, + struct task_struct *tsk) + { + unsigned cpu =3D smp_processor_id(); ++#if defined(CONFIG_X86_32) && defined(CONFIG_SMP) && (defined(CONFIG_PA= X_PAGEEXEC) || defined(CONFIG_PAX_SEGMEXEC)) ++ int tlbstate =3D TLBSTATE_OK; ++#endif +=20 + if (likely(prev !=3D next)) { + #ifdef CONFIG_SMP ++#if defined(CONFIG_X86_32) && (defined(CONFIG_PAX_PAGEEXEC) || defined(= CONFIG_PAX_SEGMEXEC)) ++ tlbstate =3D percpu_read(cpu_tlbstate.state); ++#endif + percpu_write(cpu_tlbstate.state, TLBSTATE_OK); + percpu_write(cpu_tlbstate.active_mm, next); + #endif + cpumask_set_cpu(cpu, mm_cpumask(next)); +=20 + /* Re-load page tables */ ++#ifdef CONFIG_PAX_PER_CPU_PGD ++ pax_open_kernel(); ++ __clone_user_pgds(get_cpu_pgd(cpu), next->pgd, USER_PGD_PTRS); ++ __shadow_user_pgds(get_cpu_pgd(cpu) + USER_PGD_PTRS, next->pgd, USER_= PGD_PTRS); ++ pax_close_kernel(); ++ load_cr3(get_cpu_pgd(cpu)); ++#else + load_cr3(next->pgd); ++#endif +=20 + /* stop flush ipis for the previous mm */ + cpumask_clear_cpu(cpu, mm_cpumask(prev)); +@@ -53,9 +79,38 @@ static inline void switch_mm(struct mm_struct *prev, = struct mm_struct *next, + */ + if (unlikely(prev->context.ldt !=3D next->context.ldt)) + load_LDT_nolock(&next->context); +- } ++ ++#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_PAGEEXEC) && defined(C= ONFIG_SMP) ++ if (!(__supported_pte_mask & _PAGE_NX)) { ++ smp_mb__before_clear_bit(); ++ cpu_clear(cpu, prev->context.cpu_user_cs_mask); ++ smp_mb__after_clear_bit(); ++ cpu_set(cpu, next->context.cpu_user_cs_mask); ++ } ++#endif ++ ++#if defined(CONFIG_X86_32) && (defined(CONFIG_PAX_PAGEEXEC) || defined(= CONFIG_PAX_SEGMEXEC)) ++ if (unlikely(prev->context.user_cs_base !=3D next->context.user_cs_ba= se || ++ prev->context.user_cs_limit !=3D next->context.user_cs_limit)) ++ set_user_cs(next->context.user_cs_base, next->context.user_cs_limit,= cpu); + #ifdef CONFIG_SMP ++ else if (unlikely(tlbstate !=3D TLBSTATE_OK)) ++ set_user_cs(next->context.user_cs_base, next->context.user_cs_limit,= cpu); ++#endif ++#endif ++ ++ } + else { ++ ++#ifdef CONFIG_PAX_PER_CPU_PGD ++ pax_open_kernel(); ++ __clone_user_pgds(get_cpu_pgd(cpu), next->pgd, USER_PGD_PTRS); ++ __shadow_user_pgds(get_cpu_pgd(cpu) + USER_PGD_PTRS, next->pgd, USER_= PGD_PTRS); ++ pax_close_kernel(); ++ load_cr3(get_cpu_pgd(cpu)); ++#endif ++ ++#ifdef CONFIG_SMP + percpu_write(cpu_tlbstate.state, TLBSTATE_OK); + BUG_ON(percpu_read(cpu_tlbstate.active_mm) !=3D next); +=20 +@@ -64,11 +119,28 @@ static inline void switch_mm(struct mm_struct *prev= , struct mm_struct *next, + * tlb flush IPI delivery. We must reload CR3 + * to make sure to use no freed page tables. + */ ++ ++#ifndef CONFIG_PAX_PER_CPU_PGD + load_cr3(next->pgd); ++#endif ++ + load_LDT_nolock(&next->context); ++ ++#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_PAGEEXEC) ++ if (!(__supported_pte_mask & _PAGE_NX)) ++ cpu_set(cpu, next->context.cpu_user_cs_mask); ++#endif ++ ++#if defined(CONFIG_X86_32) && (defined(CONFIG_PAX_PAGEEXEC) || defined(= CONFIG_PAX_SEGMEXEC)) ++#ifdef CONFIG_PAX_PAGEEXEC ++ if (!((next->pax_flags & MF_PAX_PAGEEXEC) && (__supported_pte_mask &= _PAGE_NX))) ++#endif ++ set_user_cs(next->context.user_cs_base, next->context.user_cs_limit= , cpu); ++#endif ++ + } +- } + #endif ++ } + } +=20 + #define activate_mm(prev, next) \ +diff --git a/arch/x86/include/asm/module.h b/arch/x86/include/asm/module= .h +index 9eae775..c914fea 100644 +--- a/arch/x86/include/asm/module.h ++++ b/arch/x86/include/asm/module.h @@ -5,6 +5,7 @@ =20 #ifdef CONFIG_X86_64 @@ -8266,9 +8952,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/module= .h linux-3.1.4/arch/x86/includ +#define MODULE_ARCH_VERMAGIC MODULE_PROC_FAMILY MODULE_PAX_KERNEXEC MOD= ULE_PAX_UDEREF + #endif /* _ASM_X86_MODULE_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/page_64_types.h linux-3.1.4/= arch/x86/include/asm/page_64_types.h ---- linux-3.1.4/arch/x86/include/asm/page_64_types.h 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/page_64_types.h 2011-11-16 18:39:07= .000000000 -0500 +diff --git a/arch/x86/include/asm/page_64_types.h b/arch/x86/include/asm= /page_64_types.h +index 7639dbf..e08a58c 100644 +--- a/arch/x86/include/asm/page_64_types.h ++++ b/arch/x86/include/asm/page_64_types.h @@ -56,7 +56,7 @@ void copy_page(void *to, void *from); =20 /* duplicated to the one in bootmem.h */ @@ -8278,10 +8965,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/page_= 64_types.h linux-3.1.4/arch/x86 =20 extern unsigned long __phys_addr(unsigned long); #define __phys_reloc_hide(x) (x) -diff -urNp linux-3.1.4/arch/x86/include/asm/paravirt.h linux-3.1.4/arch/= x86/include/asm/paravirt.h ---- linux-3.1.4/arch/x86/include/asm/paravirt.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/paravirt.h 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -667,6 +667,18 @@ static inline void set_pgd(pgd_t *pgdp,=20 +diff --git a/arch/x86/include/asm/paravirt.h b/arch/x86/include/asm/para= virt.h +index a7d2db9..edb023e 100644 +--- a/arch/x86/include/asm/paravirt.h ++++ b/arch/x86/include/asm/paravirt.h +@@ -667,6 +667,18 @@ static inline void set_pgd(pgd_t *pgdp, pgd_t pgd) val); } =20 @@ -8300,7 +8988,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/paravir= t.h linux-3.1.4/arch/x86/incl static inline void pgd_clear(pgd_t *pgdp) { set_pgd(pgdp, __pgd(0)); -@@ -748,6 +760,21 @@ static inline void __set_fixmap(unsigned +@@ -748,6 +760,21 @@ static inline void __set_fixmap(unsigned /* enum fi= xed_addresses */ idx, pv_mmu_ops.set_fixmap(idx, phys, flags); } =20 @@ -8353,9 +9041,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/paravi= rt.h linux-3.1.4/arch/x86/incl #endif /* CONFIG_X86_32 */ =20 #endif /* __ASSEMBLY__ */ -diff -urNp linux-3.1.4/arch/x86/include/asm/paravirt_types.h linux-3.1.4= /arch/x86/include/asm/paravirt_types.h ---- linux-3.1.4/arch/x86/include/asm/paravirt_types.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/paravirt_types.h 2011-11-16 18:39:0= 7.000000000 -0500 +diff --git a/arch/x86/include/asm/paravirt_types.h b/arch/x86/include/as= m/paravirt_types.h +index 8e8b9a4..f07d725 100644 +--- a/arch/x86/include/asm/paravirt_types.h ++++ b/arch/x86/include/asm/paravirt_types.h @@ -84,20 +84,20 @@ struct pv_init_ops { */ unsigned (*patch)(u8 type, u16 clobber, void *insnbuf, @@ -8428,10 +9117,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/parav= irt_types.h linux-3.1.4/arch/x8 =20 /* This contains all the paravirt structures: we get a convenient * number for each function using the offset which we use to indicate -diff -urNp linux-3.1.4/arch/x86/include/asm/pgalloc.h linux-3.1.4/arch/x= 86/include/asm/pgalloc.h ---- linux-3.1.4/arch/x86/include/asm/pgalloc.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgalloc.h 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -63,6 +63,13 @@ static inline void pmd_populate_kernel(s +diff --git a/arch/x86/include/asm/pgalloc.h b/arch/x86/include/asm/pgall= oc.h +index b4389a4..b7ff22c 100644 +--- a/arch/x86/include/asm/pgalloc.h ++++ b/arch/x86/include/asm/pgalloc.h +@@ -63,6 +63,13 @@ static inline void pmd_populate_kernel(struct mm_stru= ct *mm, pmd_t *pmd, pte_t *pte) { paravirt_alloc_pte(mm, __pa(pte) >> PAGE_SHIFT); @@ -8445,10 +9135,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgall= oc.h linux-3.1.4/arch/x86/inclu set_pmd(pmd, __pmd(__pa(pte) | _PAGE_TABLE)); } =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable-2level.h linux-3.1.4= /arch/x86/include/asm/pgtable-2level.h ---- linux-3.1.4/arch/x86/include/asm/pgtable-2level.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable-2level.h 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -18,7 +18,9 @@ static inline void native_set_pte(pte_t=20 +diff --git a/arch/x86/include/asm/pgtable-2level.h b/arch/x86/include/as= m/pgtable-2level.h +index 98391db..8f6984e 100644 +--- a/arch/x86/include/asm/pgtable-2level.h ++++ b/arch/x86/include/asm/pgtable-2level.h +@@ -18,7 +18,9 @@ static inline void native_set_pte(pte_t *ptep , pte_t = pte) =20 static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) { @@ -8458,88 +9149,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtab= le-2level.h linux-3.1.4/arch/x8 } =20 static inline void native_set_pte_atomic(pte_t *ptep, pte_t pte) -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable_32.h linux-3.1.4/arc= h/x86/include/asm/pgtable_32.h ---- linux-3.1.4/arch/x86/include/asm/pgtable_32.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable_32.h 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -25,9 +25,6 @@ - struct mm_struct; - struct vm_area_struct; -=20 --extern pgd_t swapper_pg_dir[1024]; --extern pgd_t initial_page_table[1024]; -- - static inline void pgtable_cache_init(void) { } - static inline void check_pgt_cache(void) { } - void paging_init(void); -@@ -48,6 +45,12 @@ extern void set_pmd_pfn(unsigned long, u - # include - #endif -=20 -+extern pgd_t swapper_pg_dir[PTRS_PER_PGD]; -+extern pgd_t initial_page_table[PTRS_PER_PGD]; -+#ifdef CONFIG_X86_PAE -+extern pmd_t swapper_pm_dir[PTRS_PER_PGD][PTRS_PER_PMD]; -+#endif -+ - #if defined(CONFIG_HIGHPTE) - #define pte_offset_map(dir, address) \ - ((pte_t *)kmap_atomic(pmd_page(*(dir))) + \ -@@ -62,7 +65,9 @@ extern void set_pmd_pfn(unsigned long, u - /* Clear a kernel PTE and flush it from the TLB */ - #define kpte_clear_flush(ptep, vaddr) \ - do { \ -+ pax_open_kernel(); \ - pte_clear(&init_mm, (vaddr), (ptep)); \ -+ pax_close_kernel(); \ - __flush_tlb_one((vaddr)); \ - } while (0) -=20 -@@ -74,6 +79,9 @@ do { \ -=20 - #endif /* !__ASSEMBLY__ */ -=20 -+#define HAVE_ARCH_UNMAPPED_AREA -+#define HAVE_ARCH_UNMAPPED_AREA_TOPDOWN -+ - /* - * kern_addr_valid() is (1) for FLATMEM and (0) for - * SPARSEMEM and DISCONTIGMEM -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable_32_types.h linux-3.1= .4/arch/x86/include/asm/pgtable_32_types.h ---- linux-3.1.4/arch/x86/include/asm/pgtable_32_types.h 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable_32_types.h 2011-11-16 18:39= :07.000000000 -0500 -@@ -8,7 +8,7 @@ - */ - #ifdef CONFIG_X86_PAE - # include --# define PMD_SIZE (1UL << PMD_SHIFT) -+# define PMD_SIZE (_AC(1, UL) << PMD_SHIFT) - # define PMD_MASK (~(PMD_SIZE - 1)) - #else - # include -@@ -46,6 +46,19 @@ extern bool __vmalloc_start_set; /* set=20 - # define VMALLOC_END (FIXADDR_START - 2 * PAGE_SIZE) - #endif -=20 -+#ifdef CONFIG_PAX_KERNEXEC -+#ifndef __ASSEMBLY__ -+extern unsigned char MODULES_EXEC_VADDR[]; -+extern unsigned char MODULES_EXEC_END[]; -+#endif -+#include -+#define ktla_ktva(addr) (addr + LOAD_PHYSICAL_ADDR + PAGE_OFFSET) -+#define ktva_ktla(addr) (addr - LOAD_PHYSICAL_ADDR - PAGE_OFFSET) -+#else -+#define ktla_ktva(addr) (addr) -+#define ktva_ktla(addr) (addr) -+#endif -+ - #define MODULES_VADDR VMALLOC_START - #define MODULES_END VMALLOC_END - #define MODULES_LEN (MODULES_VADDR - MODULES_END) -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable-3level.h linux-3.1.4= /arch/x86/include/asm/pgtable-3level.h ---- linux-3.1.4/arch/x86/include/asm/pgtable-3level.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable-3level.h 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -38,12 +38,16 @@ static inline void native_set_pte_atomic +diff --git a/arch/x86/include/asm/pgtable-3level.h b/arch/x86/include/as= m/pgtable-3level.h +index effff47..f9e4035 100644 +--- a/arch/x86/include/asm/pgtable-3level.h ++++ b/arch/x86/include/asm/pgtable-3level.h +@@ -38,12 +38,16 @@ static inline void native_set_pte_atomic(pte_t *ptep= , pte_t pte) =20 static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) { @@ -8556,67 +9170,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtab= le-3level.h linux-3.1.4/arch/x8 } =20 /* -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable_64.h linux-3.1.4/arc= h/x86/include/asm/pgtable_64.h ---- linux-3.1.4/arch/x86/include/asm/pgtable_64.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable_64.h 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -16,10 +16,13 @@ -=20 - extern pud_t level3_kernel_pgt[512]; - extern pud_t level3_ident_pgt[512]; -+extern pud_t level3_vmalloc_pgt[512]; -+extern pud_t level3_vmemmap_pgt[512]; -+extern pud_t level2_vmemmap_pgt[512]; - extern pmd_t level2_kernel_pgt[512]; - extern pmd_t level2_fixmap_pgt[512]; --extern pmd_t level2_ident_pgt[512]; --extern pgd_t init_level4_pgt[]; -+extern pmd_t level2_ident_pgt[512*2]; -+extern pgd_t init_level4_pgt[512]; -=20 - #define swapper_pg_dir init_level4_pgt -=20 -@@ -61,7 +64,9 @@ static inline void native_set_pte_atomic -=20 - static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) - { -+ pax_open_kernel(); - *pmdp =3D pmd; -+ pax_close_kernel(); - } -=20 - static inline void native_pmd_clear(pmd_t *pmd) -@@ -107,6 +112,13 @@ static inline void native_pud_clear(pud_ -=20 - static inline void native_set_pgd(pgd_t *pgdp, pgd_t pgd) - { -+ pax_open_kernel(); -+ *pgdp =3D pgd; -+ pax_close_kernel(); -+} -+ -+static inline void native_set_pgd_batched(pgd_t *pgdp, pgd_t pgd) -+{ - *pgdp =3D pgd; - } -=20 -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable_64_types.h linux-3.1= .4/arch/x86/include/asm/pgtable_64_types.h ---- linux-3.1.4/arch/x86/include/asm/pgtable_64_types.h 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable_64_types.h 2011-11-16 18:39= :07.000000000 -0500 -@@ -59,5 +59,10 @@ typedef struct { pteval_t pte; } pte_t; - #define MODULES_VADDR _AC(0xffffffffa0000000, UL) - #define MODULES_END _AC(0xffffffffff000000, UL) - #define MODULES_LEN (MODULES_END - MODULES_VADDR) -+#define MODULES_EXEC_VADDR MODULES_VADDR -+#define MODULES_EXEC_END MODULES_END -+ -+#define ktla_ktva(addr) (addr) -+#define ktva_ktla(addr) (addr) -=20 - #endif /* _ASM_X86_PGTABLE_64_DEFS_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable.h linux-3.1.4/arch/x= 86/include/asm/pgtable.h ---- linux-3.1.4/arch/x86/include/asm/pgtable.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable.h 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -44,6 +44,7 @@ extern struct mm_struct *pgd_page_get_mm +diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtab= le.h +index 18601c8..3d716d1 100644 +--- a/arch/x86/include/asm/pgtable.h ++++ b/arch/x86/include/asm/pgtable.h +@@ -44,6 +44,7 @@ extern struct mm_struct *pgd_page_get_mm(struct page *= page); =20 #ifndef __PAGETABLE_PUD_FOLDED #define set_pgd(pgdp, pgd) native_set_pgd(pgdp, pgd) @@ -8624,7 +9182,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= .h linux-3.1.4/arch/x86/inclu #define pgd_clear(pgd) native_pgd_clear(pgd) #endif =20 -@@ -81,12 +82,51 @@ extern struct mm_struct *pgd_page_get_mm +@@ -81,12 +82,51 @@ extern struct mm_struct *pgd_page_get_mm(struct page= *page); =20 #define arch_end_context_switch(prev) do {} while(0) =20 @@ -8676,7 +9234,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= .h linux-3.1.4/arch/x86/inclu static inline int pte_dirty(pte_t pte) { return pte_flags(pte) & _PAGE_DIRTY; -@@ -196,9 +236,29 @@ static inline pte_t pte_wrprotect(pte_t=20 +@@ -196,9 +236,29 @@ static inline pte_t pte_wrprotect(pte_t pte) return pte_clear_flags(pte, _PAGE_RW); } =20 @@ -8707,7 +9265,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= .h linux-3.1.4/arch/x86/inclu } =20 static inline pte_t pte_mkdirty(pte_t pte) -@@ -390,6 +450,15 @@ pte_t *populate_extra_pte(unsigned long=20 +@@ -390,6 +450,15 @@ pte_t *populate_extra_pte(unsigned long vaddr); #endif =20 #ifndef __ASSEMBLY__ @@ -8723,7 +9281,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= .h linux-3.1.4/arch/x86/inclu #include =20 static inline int pte_none(pte_t pte) -@@ -560,7 +629,7 @@ static inline pud_t *pud_offset(pgd_t *p +@@ -560,7 +629,7 @@ static inline pud_t *pud_offset(pgd_t *pgd, unsigned= long address) =20 static inline int pgd_bad(pgd_t pgd) { @@ -8767,7 +9325,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= .h linux-3.1.4/arch/x86/inclu #ifndef __ASSEMBLY__ =20 extern int direct_gbpages; -@@ -758,11 +846,23 @@ static inline void pmdp_set_wrprotect(st +@@ -758,11 +846,23 @@ static inline void pmdp_set_wrprotect(struct mm_st= ruct *mm, * dst and src can be on the same page, but the range must not overlap, * and must not cross a page boundary. */ @@ -8793,9 +9351,149 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtab= le.h linux-3.1.4/arch/x86/inclu =20 #include #endif /* __ASSEMBLY__ */ -diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable_types.h linux-3.1.4/= arch/x86/include/asm/pgtable_types.h ---- linux-3.1.4/arch/x86/include/asm/pgtable_types.h 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/pgtable_types.h 2011-11-16 18:39:07= .000000000 -0500 +diff --git a/arch/x86/include/asm/pgtable_32.h b/arch/x86/include/asm/pg= table_32.h +index 0c92113..34a77c6 100644 +--- a/arch/x86/include/asm/pgtable_32.h ++++ b/arch/x86/include/asm/pgtable_32.h +@@ -25,9 +25,6 @@ + struct mm_struct; + struct vm_area_struct; +=20 +-extern pgd_t swapper_pg_dir[1024]; +-extern pgd_t initial_page_table[1024]; +- + static inline void pgtable_cache_init(void) { } + static inline void check_pgt_cache(void) { } + void paging_init(void); +@@ -48,6 +45,12 @@ extern void set_pmd_pfn(unsigned long, unsigned long,= pgprot_t); + # include + #endif +=20 ++extern pgd_t swapper_pg_dir[PTRS_PER_PGD]; ++extern pgd_t initial_page_table[PTRS_PER_PGD]; ++#ifdef CONFIG_X86_PAE ++extern pmd_t swapper_pm_dir[PTRS_PER_PGD][PTRS_PER_PMD]; ++#endif ++ + #if defined(CONFIG_HIGHPTE) + #define pte_offset_map(dir, address) \ + ((pte_t *)kmap_atomic(pmd_page(*(dir))) + \ +@@ -62,7 +65,9 @@ extern void set_pmd_pfn(unsigned long, unsigned long, = pgprot_t); + /* Clear a kernel PTE and flush it from the TLB */ + #define kpte_clear_flush(ptep, vaddr) \ + do { \ ++ pax_open_kernel(); \ + pte_clear(&init_mm, (vaddr), (ptep)); \ ++ pax_close_kernel(); \ + __flush_tlb_one((vaddr)); \ + } while (0) +=20 +@@ -74,6 +79,9 @@ do { \ +=20 + #endif /* !__ASSEMBLY__ */ +=20 ++#define HAVE_ARCH_UNMAPPED_AREA ++#define HAVE_ARCH_UNMAPPED_AREA_TOPDOWN ++ + /* + * kern_addr_valid() is (1) for FLATMEM and (0) for + * SPARSEMEM and DISCONTIGMEM +diff --git a/arch/x86/include/asm/pgtable_32_types.h b/arch/x86/include/= asm/pgtable_32_types.h +index ed5903b..c7fe163 100644 +--- a/arch/x86/include/asm/pgtable_32_types.h ++++ b/arch/x86/include/asm/pgtable_32_types.h +@@ -8,7 +8,7 @@ + */ + #ifdef CONFIG_X86_PAE + # include +-# define PMD_SIZE (1UL << PMD_SHIFT) ++# define PMD_SIZE (_AC(1, UL) << PMD_SHIFT) + # define PMD_MASK (~(PMD_SIZE - 1)) + #else + # include +@@ -46,6 +46,19 @@ extern bool __vmalloc_start_set; /* set once high_mem= ory is set */ + # define VMALLOC_END (FIXADDR_START - 2 * PAGE_SIZE) + #endif +=20 ++#ifdef CONFIG_PAX_KERNEXEC ++#ifndef __ASSEMBLY__ ++extern unsigned char MODULES_EXEC_VADDR[]; ++extern unsigned char MODULES_EXEC_END[]; ++#endif ++#include ++#define ktla_ktva(addr) (addr + LOAD_PHYSICAL_ADDR + PAGE_OFFSET) ++#define ktva_ktla(addr) (addr - LOAD_PHYSICAL_ADDR - PAGE_OFFSET) ++#else ++#define ktla_ktva(addr) (addr) ++#define ktva_ktla(addr) (addr) ++#endif ++ + #define MODULES_VADDR VMALLOC_START + #define MODULES_END VMALLOC_END + #define MODULES_LEN (MODULES_VADDR - MODULES_END) +diff --git a/arch/x86/include/asm/pgtable_64.h b/arch/x86/include/asm/pg= table_64.h +index 975f709..3a89693 100644 +--- a/arch/x86/include/asm/pgtable_64.h ++++ b/arch/x86/include/asm/pgtable_64.h +@@ -16,10 +16,13 @@ +=20 + extern pud_t level3_kernel_pgt[512]; + extern pud_t level3_ident_pgt[512]; ++extern pud_t level3_vmalloc_pgt[512]; ++extern pud_t level3_vmemmap_pgt[512]; ++extern pud_t level2_vmemmap_pgt[512]; + extern pmd_t level2_kernel_pgt[512]; + extern pmd_t level2_fixmap_pgt[512]; +-extern pmd_t level2_ident_pgt[512]; +-extern pgd_t init_level4_pgt[]; ++extern pmd_t level2_ident_pgt[512*2]; ++extern pgd_t init_level4_pgt[512]; +=20 + #define swapper_pg_dir init_level4_pgt +=20 +@@ -61,7 +64,9 @@ static inline void native_set_pte_atomic(pte_t *ptep, = pte_t pte) +=20 + static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) + { ++ pax_open_kernel(); + *pmdp =3D pmd; ++ pax_close_kernel(); + } +=20 + static inline void native_pmd_clear(pmd_t *pmd) +@@ -107,6 +112,13 @@ static inline void native_pud_clear(pud_t *pud) +=20 + static inline void native_set_pgd(pgd_t *pgdp, pgd_t pgd) + { ++ pax_open_kernel(); ++ *pgdp =3D pgd; ++ pax_close_kernel(); ++} ++ ++static inline void native_set_pgd_batched(pgd_t *pgdp, pgd_t pgd) ++{ + *pgdp =3D pgd; + } +=20 +diff --git a/arch/x86/include/asm/pgtable_64_types.h b/arch/x86/include/= asm/pgtable_64_types.h +index 766ea16..5b96cb3 100644 +--- a/arch/x86/include/asm/pgtable_64_types.h ++++ b/arch/x86/include/asm/pgtable_64_types.h +@@ -59,5 +59,10 @@ typedef struct { pteval_t pte; } pte_t; + #define MODULES_VADDR _AC(0xffffffffa0000000, UL) + #define MODULES_END _AC(0xffffffffff000000, UL) + #define MODULES_LEN (MODULES_END - MODULES_VADDR) ++#define MODULES_EXEC_VADDR MODULES_VADDR ++#define MODULES_EXEC_END MODULES_END ++ ++#define ktla_ktva(addr) (addr) ++#define ktva_ktla(addr) (addr) +=20 + #endif /* _ASM_X86_PGTABLE_64_DEFS_H */ +diff --git a/arch/x86/include/asm/pgtable_types.h b/arch/x86/include/asm= /pgtable_types.h +index 013286a..8b42f4f 100644 +--- a/arch/x86/include/asm/pgtable_types.h ++++ b/arch/x86/include/asm/pgtable_types.h @@ -16,13 +16,12 @@ #define _PAGE_BIT_PSE 7 /* 4 MB (or 2MB) page */ #define _PAGE_BIT_PAT 7 /* on 4KB pages */ @@ -8863,7 +9561,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= _types.h linux-3.1.4/arch/x86 #define PGD_IDENT_ATTR 0x001 /* PRESENT (no other attributes) */ #endif =20 -@@ -207,7 +210,17 @@ static inline pgdval_t pgd_flags(pgd_t p +@@ -207,7 +210,17 @@ static inline pgdval_t pgd_flags(pgd_t pgd) { return native_pgd_val(pgd) & PTE_FLAGS_MASK; } @@ -8881,7 +9579,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= _types.h linux-3.1.4/arch/x86 #if PAGETABLE_LEVELS > 3 typedef struct { pudval_t pud; } pud_t; =20 -@@ -221,8 +234,6 @@ static inline pudval_t native_pud_val(pu +@@ -221,8 +234,6 @@ static inline pudval_t native_pud_val(pud_t pud) return pud.pud; } #else @@ -8890,7 +9588,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtable= _types.h linux-3.1.4/arch/x86 static inline pudval_t native_pud_val(pud_t pud) { return native_pgd_val(pud.pgd); -@@ -242,8 +253,6 @@ static inline pmdval_t native_pmd_val(pm +@@ -242,8 +253,6 @@ static inline pmdval_t native_pmd_val(pmd_t pmd) return pmd.pmd; } #else @@ -8907,9 +9605,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/pgtabl= e_types.h linux-3.1.4/arch/x86 =20 #define pgprot_writecombine pgprot_writecombine extern pgprot_t pgprot_writecombine(pgprot_t prot); -diff -urNp linux-3.1.4/arch/x86/include/asm/processor.h linux-3.1.4/arch= /x86/include/asm/processor.h ---- linux-3.1.4/arch/x86/include/asm/processor.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/processor.h 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/pro= cessor.h +index 0d1171c..36571a9 100644 +--- a/arch/x86/include/asm/processor.h ++++ b/arch/x86/include/asm/processor.h @@ -266,7 +266,7 @@ struct tss_struct { =20 } ____cacheline_aligned; @@ -8919,7 +9618,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/process= or.h linux-3.1.4/arch/x86/inc =20 /* * Save the original ist values for checking stack pointers during debu= gging -@@ -858,11 +858,18 @@ static inline void spin_lock_prefetch(co +@@ -858,11 +858,18 @@ static inline void spin_lock_prefetch(const void *= x) */ #define TASK_SIZE PAGE_OFFSET #define TASK_SIZE_MAX TASK_SIZE @@ -8940,7 +9639,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/process= or.h linux-3.1.4/arch/x86/inc .vm86_info =3D NULL, \ .sysenter_cs =3D __KERNEL_CS, \ .io_bitmap_ptr =3D NULL, \ -@@ -876,7 +883,7 @@ static inline void spin_lock_prefetch(co +@@ -876,7 +883,7 @@ static inline void spin_lock_prefetch(const void *x) */ #define INIT_TSS { \ .x86_tss =3D { \ @@ -8949,7 +9648,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/process= or.h linux-3.1.4/arch/x86/inc .ss0 =3D __KERNEL_DS, \ .ss1 =3D __KERNEL_CS, \ .io_bitmap_base =3D INVALID_IO_BITMAP_OFFSET, \ -@@ -887,11 +894,7 @@ static inline void spin_lock_prefetch(co +@@ -887,11 +894,7 @@ static inline void spin_lock_prefetch(const void *x= ) extern unsigned long thread_saved_pc(struct task_struct *tsk); =20 #define THREAD_SIZE_LONGS (THREAD_SIZE/sizeof(unsigned long)) @@ -8962,7 +9661,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/process= or.h linux-3.1.4/arch/x86/inc =20 /* * The below -8 is to reserve 8 bytes on top of the ring0 stack. -@@ -906,7 +909,7 @@ extern unsigned long thread_saved_pc(str +@@ -906,7 +909,7 @@ extern unsigned long thread_saved_pc(struct task_str= uct *tsk); #define task_pt_regs(task) = \ ({ = \ struct pt_regs *__regs__; = \ @@ -8971,7 +9670,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/process= or.h linux-3.1.4/arch/x86/inc __regs__ - 1; = \ }) =20 -@@ -916,13 +919,13 @@ extern unsigned long thread_saved_pc(str +@@ -916,13 +919,13 @@ extern unsigned long thread_saved_pc(struct task_s= truct *tsk); /* * User space process size. 47bits minus one guard page. */ @@ -8987,7 +9686,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/process= or.h linux-3.1.4/arch/x86/inc =20 #define TASK_SIZE (test_thread_flag(TIF_IA32) ? \ IA32_PAGE_OFFSET : TASK_SIZE_MAX) -@@ -933,11 +936,11 @@ extern unsigned long thread_saved_pc(str +@@ -933,11 +936,11 @@ extern unsigned long thread_saved_pc(struct task_s= truct *tsk); #define STACK_TOP_MAX TASK_SIZE_MAX =20 #define INIT_THREAD { \ @@ -9001,7 +9700,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/process= or.h linux-3.1.4/arch/x86/inc } =20 /* -@@ -959,6 +962,10 @@ extern void start_thread(struct pt_regs=20 +@@ -959,6 +962,10 @@ extern void start_thread(struct pt_regs *regs, unsi= gned long new_ip, */ #define TASK_UNMAPPED_BASE (PAGE_ALIGN(TASK_SIZE / 3)) =20 @@ -9012,10 +9711,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/proce= ssor.h linux-3.1.4/arch/x86/inc #define KSTK_EIP(task) (task_pt_regs(task)->ip) =20 /* Get/set a process' ability to use the timestamp counter instruction = */ -diff -urNp linux-3.1.4/arch/x86/include/asm/ptrace.h linux-3.1.4/arch/x8= 6/include/asm/ptrace.h ---- linux-3.1.4/arch/x86/include/asm/ptrace.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/ptrace.h 2011-11-16 18:39:07.000000= 000 -0500 -@@ -156,28 +156,29 @@ static inline unsigned long regs_return_ +diff --git a/arch/x86/include/asm/ptrace.h b/arch/x86/include/asm/ptrace= .h +index 3566454..4bdfb8c 100644 +--- a/arch/x86/include/asm/ptrace.h ++++ b/arch/x86/include/asm/ptrace.h +@@ -156,28 +156,29 @@ static inline unsigned long regs_return_value(stru= ct pt_regs *regs) } =20 /* @@ -9051,7 +9751,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/ptrace.= h linux-3.1.4/arch/x86/includ #endif } =20 -@@ -193,15 +194,16 @@ static inline int v8086_mode(struct pt_r +@@ -193,15 +194,16 @@ static inline int v8086_mode(struct pt_regs *regs) #ifdef CONFIG_X86_64 static inline bool user_64bit_mode(struct pt_regs *regs) { @@ -9070,9 +9770,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/ptrace= .h linux-3.1.4/arch/x86/includ #endif } #endif -diff -urNp linux-3.1.4/arch/x86/include/asm/reboot.h linux-3.1.4/arch/x8= 6/include/asm/reboot.h ---- linux-3.1.4/arch/x86/include/asm/reboot.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/reboot.h 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/include/asm/reboot.h b/arch/x86/include/asm/reboot= .h +index 3250e3d..20db631 100644 +--- a/arch/x86/include/asm/reboot.h ++++ b/arch/x86/include/asm/reboot.h @@ -6,19 +6,19 @@ struct pt_regs; =20 @@ -9099,10 +9800,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/reboo= t.h linux-3.1.4/arch/x86/includ /* These must match dispatch_table in reboot_32.S */ #define MRR_BIOS 0 #define MRR_APM 1 -diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h linux-3.1.4/arch/x86= /include/asm/rwsem.h ---- linux-3.1.4/arch/x86/include/asm/rwsem.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/include/asm/rwsem.h 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -64,6 +64,14 @@ static inline void __down_read(struct rw +diff --git a/arch/x86/include/asm/rwsem.h b/arch/x86/include/asm/rwsem.h +index df4cd32..27ae072 100644 +--- a/arch/x86/include/asm/rwsem.h ++++ b/arch/x86/include/asm/rwsem.h +@@ -64,6 +64,14 @@ static inline void __down_read(struct rw_semaphore *s= em) { asm volatile("# beginning down_read\n\t" LOCK_PREFIX _ASM_INC "(%1)\n\t" @@ -9117,7 +9819,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h= linux-3.1.4/arch/x86/include /* adds 0x00000001 */ " jns 1f\n" " call call_rwsem_down_read_failed\n" -@@ -85,6 +93,14 @@ static inline int __down_read_trylock(st +@@ -85,6 +93,14 @@ static inline int __down_read_trylock(struct rw_semap= hore *sem) "1:\n\t" " mov %1,%2\n\t" " add %3,%2\n\t" @@ -9132,7 +9834,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h= linux-3.1.4/arch/x86/include " jle 2f\n\t" LOCK_PREFIX " cmpxchg %2,%0\n\t" " jnz 1b\n\t" -@@ -104,6 +120,14 @@ static inline void __down_write_nested(s +@@ -104,6 +120,14 @@ static inline void __down_write_nested(struct rw_se= maphore *sem, int subclass) long tmp; asm volatile("# beginning down_write\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -9147,7 +9849,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h= linux-3.1.4/arch/x86/include /* adds 0xffff0001, returns the old value */ " test %1,%1\n\t" /* was the count 0 before? */ -@@ -141,6 +165,14 @@ static inline void __up_read(struct rw_s +@@ -141,6 +165,14 @@ static inline void __up_read(struct rw_semaphore *s= em) long tmp; asm volatile("# beginning __up_read\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -9162,7 +9864,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h= linux-3.1.4/arch/x86/include /* subtracts 1, returns the old value */ " jns 1f\n\t" " call call_rwsem_wake\n" /* expects old value in %edx */ -@@ -159,6 +191,14 @@ static inline void __up_write(struct rw_ +@@ -159,6 +191,14 @@ static inline void __up_write(struct rw_semaphore *= sem) long tmp; asm volatile("# beginning __up_write\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -9177,7 +9879,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h= linux-3.1.4/arch/x86/include /* subtracts 0xffff0001, returns the old value */ " jns 1f\n\t" " call call_rwsem_wake\n" /* expects old value in %edx */ -@@ -176,6 +216,14 @@ static inline void __downgrade_write(str +@@ -176,6 +216,14 @@ static inline void __downgrade_write(struct rw_sema= phore *sem) { asm volatile("# beginning __downgrade_write\n\t" LOCK_PREFIX _ASM_ADD "%2,(%1)\n\t" @@ -9192,7 +9894,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h= linux-3.1.4/arch/x86/include /* * transitions 0xZZZZ0001 -> 0xYYYY0001 (i386) * 0xZZZZZZZZ00000001 -> 0xYYYYYYYY00000001 (x86_64) -@@ -194,7 +242,15 @@ static inline void __downgrade_write(str +@@ -194,7 +242,15 @@ static inline void __downgrade_write(struct rw_sema= phore *sem) */ static inline void rwsem_atomic_add(long delta, struct rw_semaphore *se= m) { @@ -9209,7 +9911,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.h= linux-3.1.4/arch/x86/include : "+m" (sem->count) : "er" (delta)); } -@@ -206,7 +262,15 @@ static inline long rwsem_atomic_update(l +@@ -206,7 +262,15 @@ static inline long rwsem_atomic_update(long delta, = struct rw_semaphore *sem) { long tmp =3D delta; =20 @@ -9226,9 +9928,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/rwsem.= h linux-3.1.4/arch/x86/include : "+r" (tmp), "+m" (sem->count) : : "memory"); =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/segment.h linux-3.1.4/arch/x= 86/include/asm/segment.h ---- linux-3.1.4/arch/x86/include/asm/segment.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/segment.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/x86/include/asm/segment.h b/arch/x86/include/asm/segme= nt.h +index 5e64171..f58957e 100644 +--- a/arch/x86/include/asm/segment.h ++++ b/arch/x86/include/asm/segment.h @@ -64,10 +64,15 @@ * 26 - ESPFIX small SS * 27 - per-cpu [ offset to per-cpu data area ] @@ -9295,10 +9998,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/segme= nt.h linux-3.1.4/arch/x86/inclu #define __KERNEL_DS (GDT_ENTRY_KERNEL_DS*8) #define __USER_DS (GDT_ENTRY_DEFAULT_USER_DS*8+3) #define __USER_CS (GDT_ENTRY_DEFAULT_USER_CS*8+3) -diff -urNp linux-3.1.4/arch/x86/include/asm/smp.h linux-3.1.4/arch/x86/i= nclude/asm/smp.h ---- linux-3.1.4/arch/x86/include/asm/smp.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/include/asm/smp.h 2011-11-16 18:39:07.000000000= -0500 -@@ -36,7 +36,7 @@ DECLARE_PER_CPU(cpumask_var_t, cpu_core_ +diff --git a/arch/x86/include/asm/smp.h b/arch/x86/include/asm/smp.h +index 73b11bc..d4a3b63 100644 +--- a/arch/x86/include/asm/smp.h ++++ b/arch/x86/include/asm/smp.h +@@ -36,7 +36,7 @@ DECLARE_PER_CPU(cpumask_var_t, cpu_core_map); /* cpus sharing the last level cache: */ DECLARE_PER_CPU(cpumask_var_t, cpu_llc_shared_map); DECLARE_PER_CPU(u16, cpu_llc_id); @@ -9316,7 +10020,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/smp.h = linux-3.1.4/arch/x86/include/a =20 /* Globals due to paravirt */ extern void set_cpu_sibling_map(int cpu); -@@ -192,14 +192,8 @@ extern unsigned disabled_cpus __cpuinitd +@@ -192,14 +192,8 @@ extern unsigned disabled_cpus __cpuinitdata; extern int safe_smp_processor_id(void); =20 #elif defined(CONFIG_X86_64_SMP) @@ -9333,10 +10037,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/smp.= h linux-3.1.4/arch/x86/include/a #define safe_smp_processor_id() smp_processor_id() =20 #endif -diff -urNp linux-3.1.4/arch/x86/include/asm/spinlock.h linux-3.1.4/arch/= x86/include/asm/spinlock.h ---- linux-3.1.4/arch/x86/include/asm/spinlock.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/spinlock.h 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -248,6 +248,14 @@ static inline int arch_write_can_lock(ar +diff --git a/arch/x86/include/asm/spinlock.h b/arch/x86/include/asm/spin= lock.h +index ee67edf..49c796b 100644 +--- a/arch/x86/include/asm/spinlock.h ++++ b/arch/x86/include/asm/spinlock.h +@@ -248,6 +248,14 @@ static inline int arch_write_can_lock(arch_rwlock_t= *lock) static inline void arch_read_lock(arch_rwlock_t *rw) { asm volatile(LOCK_PREFIX READ_LOCK_SIZE(dec) " (%0)\n\t" @@ -9351,7 +10056,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/spinlo= ck.h linux-3.1.4/arch/x86/incl "jns 1f\n" "call __read_lock_failed\n\t" "1:\n" -@@ -257,6 +265,14 @@ static inline void arch_read_lock(arch_r +@@ -257,6 +265,14 @@ static inline void arch_read_lock(arch_rwlock_t *rw= ) static inline void arch_write_lock(arch_rwlock_t *rw) { asm volatile(LOCK_PREFIX WRITE_LOCK_SUB(%1) "(%0)\n\t" @@ -9366,7 +10071,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/spinlo= ck.h linux-3.1.4/arch/x86/incl "jz 1f\n" "call __write_lock_failed\n\t" "1:\n" -@@ -286,13 +302,29 @@ static inline int arch_write_trylock(arc +@@ -286,13 +302,29 @@ static inline int arch_write_trylock(arch_rwlock_t= *lock) =20 static inline void arch_read_unlock(arch_rwlock_t *rw) { @@ -9398,9 +10103,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/spinl= ock.h linux-3.1.4/arch/x86/incl : "+m" (rw->write) : "i" (RW_LOCK_BIAS) : "memory"); } =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/stackprotector.h linux-3.1.4= /arch/x86/include/asm/stackprotector.h ---- linux-3.1.4/arch/x86/include/asm/stackprotector.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/stackprotector.h 2011-11-16 18:39:0= 7.000000000 -0500 +diff --git a/arch/x86/include/asm/stackprotector.h b/arch/x86/include/as= m/stackprotector.h +index 1575177..cb23f52 100644 +--- a/arch/x86/include/asm/stackprotector.h ++++ b/arch/x86/include/asm/stackprotector.h @@ -48,7 +48,7 @@ * head_32 for boot CPU and setup_per_cpu_areas() for others. */ @@ -9410,7 +10116,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/stackp= rotector.h linux-3.1.4/arch/x8 =20 /* * Initialize the stackprotector canary value. -@@ -113,7 +113,7 @@ static inline void setup_stack_canary_se +@@ -113,7 +113,7 @@ static inline void setup_stack_canary_segment(int cp= u) =20 static inline void load_stack_canary_segment(void) { @@ -9419,9 +10125,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/stack= protector.h linux-3.1.4/arch/x8 asm volatile ("mov %0, %%gs" : : "r" (0)); #endif } -diff -urNp linux-3.1.4/arch/x86/include/asm/stacktrace.h linux-3.1.4/arc= h/x86/include/asm/stacktrace.h ---- linux-3.1.4/arch/x86/include/asm/stacktrace.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/stacktrace.h 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/stacktrace.h b/arch/x86/include/asm/st= acktrace.h +index 70bbe39..4ae2bd4 100644 +--- a/arch/x86/include/asm/stacktrace.h ++++ b/arch/x86/include/asm/stacktrace.h @@ -11,28 +11,20 @@ =20 extern int kstack_depth_to_print; @@ -9472,10 +10179,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/stac= ktrace.h linux-3.1.4/arch/x86/in }; =20 void dump_trace(struct task_struct *tsk, struct pt_regs *regs, -diff -urNp linux-3.1.4/arch/x86/include/asm/sys_ia32.h linux-3.1.4/arch/= x86/include/asm/sys_ia32.h ---- linux-3.1.4/arch/x86/include/asm/sys_ia32.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/sys_ia32.h 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -40,7 +40,7 @@ asmlinkage long sys32_rt_sigprocmask(int +diff --git a/arch/x86/include/asm/sys_ia32.h b/arch/x86/include/asm/sys_= ia32.h +index cb23852..2dde194 100644 +--- a/arch/x86/include/asm/sys_ia32.h ++++ b/arch/x86/include/asm/sys_ia32.h +@@ -40,7 +40,7 @@ asmlinkage long sys32_rt_sigprocmask(int, compat_sigse= t_t __user *, compat_sigset_t __user *, unsigned int); asmlinkage long sys32_alarm(unsigned int); =20 @@ -9484,9 +10192,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/sys_i= a32.h linux-3.1.4/arch/x86/incl asmlinkage long sys32_sysfs(int, u32, u32); =20 asmlinkage long sys32_sched_rr_get_interval(compat_pid_t, -diff -urNp linux-3.1.4/arch/x86/include/asm/system.h linux-3.1.4/arch/x8= 6/include/asm/system.h ---- linux-3.1.4/arch/x86/include/asm/system.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/system.h 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/include/asm/system.h b/arch/x86/include/asm/system= .h +index c2ff2a1..4349184 100644 +--- a/arch/x86/include/asm/system.h ++++ b/arch/x86/include/asm/system.h @@ -129,7 +129,7 @@ do { \ "call __switch_to\n\t" \ "movq "__percpu_arg([current_task])",%%rsi\n\t" \ @@ -9505,7 +10214,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/system= .h linux-3.1.4/arch/x86/includ [current_task] "m" (current_task) \ __switch_canary_iparam \ : "memory", "cc" __EXTRA_CLOBBER) -@@ -200,7 +200,7 @@ static inline unsigned long get_limit(un +@@ -200,7 +200,7 @@ static inline unsigned long get_limit(unsigned long = segment) { unsigned long __limit; asm("lsll %1,%0" : "=3Dr" (__limit) : "r" (segment)); @@ -9529,9 +10238,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/syste= m.h linux-3.1.4/arch/x86/includ =20 /* * Force strict CPU ordering. -diff -urNp linux-3.1.4/arch/x86/include/asm/thread_info.h linux-3.1.4/ar= ch/x86/include/asm/thread_info.h ---- linux-3.1.4/arch/x86/include/asm/thread_info.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/thread_info.h 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/x86/include/asm/thread_info.h b/arch/x86/include/asm/t= hread_info.h +index a1fe5c1..ee326d8 100644 +--- a/arch/x86/include/asm/thread_info.h ++++ b/arch/x86/include/asm/thread_info.h @@ -10,6 +10,7 @@ #include #include @@ -9638,7 +10348,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/thread= _info.h linux-3.1.4/arch/x86/i /* * macros/functions for gaining access to the thread information struct= ure * preempt_count needs to be 1 initially, until the scheduler is functi= onal. -@@ -216,21 +205,8 @@ static inline struct thread_info *curren +@@ -216,21 +205,8 @@ static inline struct thread_info *current_thread_in= fo(void) #ifndef __ASSEMBLY__ DECLARE_PER_CPU(unsigned long, kernel_stack); =20 @@ -9679,10 +10389,234 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/thr= ead_info.h linux-3.1.4/arch/x86/i + #endif #endif /* _ASM_X86_THREAD_INFO_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/uaccess_32.h linux-3.1.4/arc= h/x86/include/asm/uaccess_32.h ---- linux-3.1.4/arch/x86/include/asm/uaccess_32.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/uaccess_32.h 2011-11-16 18:40:08.00= 0000000 -0500 -@@ -43,6 +43,11 @@ unsigned long __must_check __copy_from_u +diff --git a/arch/x86/include/asm/uaccess.h b/arch/x86/include/asm/uacce= ss.h +index 36361bf..324f262 100644 +--- a/arch/x86/include/asm/uaccess.h ++++ b/arch/x86/include/asm/uaccess.h +@@ -7,12 +7,15 @@ + #include + #include + #include ++#include + #include + #include +=20 + #define VERIFY_READ 0 + #define VERIFY_WRITE 1 +=20 ++extern void check_object_size(const void *ptr, unsigned long n, bool to= ); ++ + /* + * The fs value determines whether argument validity checking should be + * performed or not. If get_fs() =3D=3D USER_DS, checking is performed= , with +@@ -28,7 +31,12 @@ +=20 + #define get_ds() (KERNEL_DS) + #define get_fs() (current_thread_info()->addr_limit) ++#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) ++void __set_fs(mm_segment_t x); ++void set_fs(mm_segment_t x); ++#else + #define set_fs(x) (current_thread_info()->addr_limit =3D (x)) ++#endif +=20 + #define segment_eq(a, b) ((a).seg =3D=3D (b).seg) +=20 +@@ -76,7 +84,33 @@ + * checks that the pointer is in the user space range - after calling + * this function, memory access functions may still return -EFAULT. + */ +-#define access_ok(type, addr, size) (likely(__range_not_ok(addr, size) = =3D=3D 0)) ++#define __access_ok(type, addr, size) (likely(__range_not_ok(addr, size= ) =3D=3D 0)) ++#define access_ok(type, addr, size) \ ++({ \ ++ long __size =3D size; \ ++ unsigned long __addr =3D (unsigned long)addr; \ ++ unsigned long __addr_ao =3D __addr & PAGE_MASK; \ ++ unsigned long __end_ao =3D __addr + __size - 1; \ ++ bool __ret_ao =3D __range_not_ok(__addr, __size) =3D=3D 0; \ ++ if (__ret_ao && unlikely((__end_ao ^ __addr_ao) & PAGE_MASK)) { \ ++ while(__addr_ao <=3D __end_ao) { \ ++ char __c_ao; \ ++ __addr_ao +=3D PAGE_SIZE; \ ++ if (__size > PAGE_SIZE) \ ++ cond_resched(); \ ++ if (__get_user(__c_ao, (char __user *)__addr)) \ ++ break; \ ++ if (type !=3D VERIFY_WRITE) { \ ++ __addr =3D __addr_ao; \ ++ continue; \ ++ } \ ++ if (__put_user(__c_ao, (char __user *)__addr)) \ ++ break; \ ++ __addr =3D __addr_ao; \ ++ } \ ++ } \ ++ __ret_ao; \ ++}) +=20 + /* + * The exception table consists of pairs of addresses: the first is the +@@ -182,12 +216,20 @@ extern int __get_user_bad(void); + asm volatile("call __put_user_" #size : "=3Da" (__ret_pu) \ + : "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx") +=20 +- ++#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define __copyuser_seg "gs;" ++#define __COPYUSER_SET_ES "pushl %%gs; popl %%es\n" ++#define __COPYUSER_RESTORE_ES "pushl %%ss; popl %%es\n" ++#else ++#define __copyuser_seg ++#define __COPYUSER_SET_ES ++#define __COPYUSER_RESTORE_ES ++#endif +=20 + #ifdef CONFIG_X86_32 + #define __put_user_asm_u64(x, addr, err, errret) \ +- asm volatile("1: movl %%eax,0(%2)\n" \ +- "2: movl %%edx,4(%2)\n" \ ++ asm volatile("1: "__copyuser_seg"movl %%eax,0(%2)\n" \ ++ "2: "__copyuser_seg"movl %%edx,4(%2)\n" \ + "3:\n" \ + ".section .fixup,\"ax\"\n" \ + "4: movl %3,%0\n" \ +@@ -199,8 +241,8 @@ extern int __get_user_bad(void); + : "A" (x), "r" (addr), "i" (errret), "0" (err)) +=20 + #define __put_user_asm_ex_u64(x, addr) \ +- asm volatile("1: movl %%eax,0(%1)\n" \ +- "2: movl %%edx,4(%1)\n" \ ++ asm volatile("1: "__copyuser_seg"movl %%eax,0(%1)\n" \ ++ "2: "__copyuser_seg"movl %%edx,4(%1)\n" \ + "3:\n" \ + _ASM_EXTABLE(1b, 2b - 1b) \ + _ASM_EXTABLE(2b, 3b - 2b) \ +@@ -252,7 +294,7 @@ extern void __put_user_8(void); + __typeof__(*(ptr)) __pu_val; \ + __chk_user_ptr(ptr); \ + might_fault(); \ +- __pu_val =3D x; \ ++ __pu_val =3D (x); \ + switch (sizeof(*(ptr))) { \ + case 1: \ + __put_user_x(1, __pu_val, ptr, __ret_pu); \ +@@ -373,7 +415,7 @@ do { \ + } while (0) +=20 + #define __get_user_asm(x, addr, err, itype, rtype, ltype, errret) \ +- asm volatile("1: mov"itype" %2,%"rtype"1\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %2,%"rtype"1\n"\ + "2:\n" \ + ".section .fixup,\"ax\"\n" \ + "3: mov %3,%0\n" \ +@@ -381,7 +423,7 @@ do { \ + " jmp 2b\n" \ + ".previous\n" \ + _ASM_EXTABLE(1b, 3b) \ +- : "=3Dr" (err), ltype(x) \ ++ : "=3Dr" (err), ltype (x) \ + : "m" (__m(addr)), "i" (errret), "0" (err)) +=20 + #define __get_user_size_ex(x, ptr, size) \ +@@ -406,7 +448,7 @@ do { \ + } while (0) +=20 + #define __get_user_asm_ex(x, addr, itype, rtype, ltype) \ +- asm volatile("1: mov"itype" %1,%"rtype"0\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %1,%"rtype"0\n"\ + "2:\n" \ + _ASM_EXTABLE(1b, 2b - 1b) \ + : ltype(x) : "m" (__m(addr))) +@@ -423,13 +465,24 @@ do { \ + int __gu_err; \ + unsigned long __gu_val; \ + __get_user_size(__gu_val, (ptr), (size), __gu_err, -EFAULT); \ +- (x) =3D (__force __typeof__(*(ptr)))__gu_val; \ ++ (x) =3D (__typeof__(*(ptr)))__gu_val; \ + __gu_err; \ + }) +=20 + /* FIXME: this hack is definitely wrong -AK */ + struct __large_struct { unsigned long buf[100]; }; +-#define __m(x) (*(struct __large_struct __user *)(x)) ++#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define ____m(x) \ ++({ \ ++ unsigned long ____x =3D (unsigned long)(x); \ ++ if (____x < PAX_USER_SHADOW_BASE) \ ++ ____x +=3D PAX_USER_SHADOW_BASE; \ ++ (void __user *)____x; \ ++}) ++#else ++#define ____m(x) (x) ++#endif ++#define __m(x) (*(struct __large_struct __user *)____m(x)) +=20 + /* + * Tell gcc we read from memory instead of writing: this is because +@@ -437,7 +490,7 @@ struct __large_struct { unsigned long buf[100]; }; + * aliasing issues. + */ + #define __put_user_asm(x, addr, err, itype, rtype, ltype, errret) \ +- asm volatile("1: mov"itype" %"rtype"1,%2\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"1,%2\n"\ + "2:\n" \ + ".section .fixup,\"ax\"\n" \ + "3: mov %3,%0\n" \ +@@ -445,10 +498,10 @@ struct __large_struct { unsigned long buf[100]; }; + ".previous\n" \ + _ASM_EXTABLE(1b, 3b) \ + : "=3Dr"(err) \ +- : ltype(x), "m" (__m(addr)), "i" (errret), "0" (err)) ++ : ltype (x), "m" (__m(addr)), "i" (errret), "0" (err)) +=20 + #define __put_user_asm_ex(x, addr, itype, rtype, ltype) \ +- asm volatile("1: mov"itype" %"rtype"0,%1\n" \ ++ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"0,%1\n"\ + "2:\n" \ + _ASM_EXTABLE(1b, 2b - 1b) \ + : : ltype(x), "m" (__m(addr))) +@@ -487,8 +540,12 @@ struct __large_struct { unsigned long buf[100]; }; + * On error, the variable @x is set to zero. + */ +=20 ++#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define __get_user(x, ptr) get_user((x), (ptr)) ++#else + #define __get_user(x, ptr) \ + __get_user_nocheck((x), (ptr), sizeof(*(ptr))) ++#endif +=20 + /** + * __put_user: - Write a simple value into user space, with less checki= ng. +@@ -510,8 +567,12 @@ struct __large_struct { unsigned long buf[100]; }; + * Returns zero on success, or -EFAULT on error. + */ +=20 ++#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) ++#define __put_user(x, ptr) put_user((x), (ptr)) ++#else + #define __put_user(x, ptr) \ + __put_user_nocheck((__typeof__(*(ptr)))(x), (ptr), sizeof(*(ptr))) ++#endif +=20 + #define __get_user_unaligned __get_user + #define __put_user_unaligned __put_user +@@ -529,7 +590,7 @@ struct __large_struct { unsigned long buf[100]; }; + #define get_user_ex(x, ptr) do { \ + unsigned long __gue_val; \ + __get_user_size_ex((__gue_val), (ptr), (sizeof(*(ptr)))); \ +- (x) =3D (__force __typeof__(*(ptr)))__gue_val; \ ++ (x) =3D (__typeof__(*(ptr)))__gue_val; \ + } while (0) +=20 + #ifdef CONFIG_X86_WP_WORKS_OK +diff --git a/arch/x86/include/asm/uaccess_32.h b/arch/x86/include/asm/ua= ccess_32.h +index 566e803..89f1e60 100644 +--- a/arch/x86/include/asm/uaccess_32.h ++++ b/arch/x86/include/asm/uaccess_32.h +@@ -43,6 +43,11 @@ unsigned long __must_check __copy_from_user_ll_nocach= e_nozero static __always_inline unsigned long __must_check __copy_to_user_inatomic(void __user *to, const void *from, unsigned lon= g n) { @@ -9694,7 +10628,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacces= s_32.h linux-3.1.4/arch/x86/in if (__builtin_constant_p(n)) { unsigned long ret; =20 -@@ -61,6 +66,8 @@ __copy_to_user_inatomic(void __user *to, +@@ -61,6 +66,8 @@ __copy_to_user_inatomic(void __user *to, const void *f= rom, unsigned long n) return ret; } } @@ -9703,7 +10637,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacces= s_32.h linux-3.1.4/arch/x86/in return __copy_to_user_ll(to, from, n); } =20 -@@ -82,12 +89,16 @@ static __always_inline unsigned long __m +@@ -82,12 +89,16 @@ static __always_inline unsigned long __must_check __copy_to_user(void __user *to, const void *from, unsigned long n) { might_fault(); @@ -9733,7 +10667,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacces= s_32.h linux-3.1.4/arch/x86/in if (__builtin_constant_p(n)) { unsigned long ret; =20 -@@ -152,6 +169,8 @@ __copy_from_user(void *to, const void __ +@@ -152,6 +169,8 @@ __copy_from_user(void *to, const void __user *from, = unsigned long n) return ret; } } @@ -9742,7 +10676,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacces= s_32.h linux-3.1.4/arch/x86/in return __copy_from_user_ll(to, from, n); } =20 -@@ -159,6 +178,10 @@ static __always_inline unsigned long __c +@@ -159,6 +178,10 @@ static __always_inline unsigned long __copy_from_us= er_nocache(void *to, const void __user *from, unsigned long n) { might_fault(); @@ -9780,7 +10714,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacces= s_32.h linux-3.1.4/arch/x86/in =20 extern void copy_from_user_overflow(void) #ifdef CONFIG_DEBUG_STRICT_USER_COPY_CHECKS -@@ -199,17 +226,61 @@ extern void copy_from_user_overflow(void +@@ -199,17 +226,61 @@ extern void copy_from_user_overflow(void) #endif ; =20 @@ -9849,9 +10783,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacce= ss_32.h linux-3.1.4/arch/x86/in return n; } =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/uaccess_64.h linux-3.1.4/arc= h/x86/include/asm/uaccess_64.h ---- linux-3.1.4/arch/x86/include/asm/uaccess_64.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/uaccess_64.h 2011-11-16 18:40:08.00= 0000000 -0500 +diff --git a/arch/x86/include/asm/uaccess_64.h b/arch/x86/include/asm/ua= ccess_64.h +index 1c66d30..c299480 100644 +--- a/arch/x86/include/asm/uaccess_64.h ++++ b/arch/x86/include/asm/uaccess_64.h @@ -10,6 +10,9 @@ #include #include @@ -9862,7 +10797,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacces= s_64.h linux-3.1.4/arch/x86/in =20 /* * Copy To/From Userspace -@@ -36,26 +39,26 @@ copy_user_generic(void *to, const void * +@@ -36,26 +39,26 @@ copy_user_generic(void *to, const void *from, unsign= ed len) return ret; } =20 @@ -9902,7 +10837,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacces= s_64.h linux-3.1.4/arch/x86/in return n; } =20 -@@ -64,110 +67,198 @@ int copy_to_user(void __user *dst, const +@@ -64,110 +67,198 @@ int copy_to_user(void __user *dst, const void *src= , unsigned size) { might_fault(); =20 @@ -10134,7 +11069,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacce= ss_64.h linux-3.1.4/arch/x86/in ret, "b", "b", "=3Dq", 1); if (likely(!ret)) __put_user_asm(tmp, (u8 __user *)dst, -@@ -176,7 +267,7 @@ int __copy_in_user(void __user *dst, con +@@ -176,7 +267,7 @@ int __copy_in_user(void __user *dst, const void __us= er *src, unsigned size) } case 2: { u16 tmp; @@ -10143,7 +11078,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacce= ss_64.h linux-3.1.4/arch/x86/in ret, "w", "w", "=3Dr", 2); if (likely(!ret)) __put_user_asm(tmp, (u16 __user *)dst, -@@ -186,7 +277,7 @@ int __copy_in_user(void __user *dst, con +@@ -186,7 +277,7 @@ int __copy_in_user(void __user *dst, const void __us= er *src, unsigned size) =20 case 4: { u32 tmp; @@ -10152,7 +11087,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacce= ss_64.h linux-3.1.4/arch/x86/in ret, "l", "k", "=3Dr", 4); if (likely(!ret)) __put_user_asm(tmp, (u32 __user *)dst, -@@ -195,7 +286,7 @@ int __copy_in_user(void __user *dst, con +@@ -195,7 +286,7 @@ int __copy_in_user(void __user *dst, const void __us= er *src, unsigned size) } case 8: { u64 tmp; @@ -10161,7 +11096,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacce= ss_64.h linux-3.1.4/arch/x86/in ret, "q", "", "=3Dr", 8); if (likely(!ret)) __put_user_asm(tmp, (u64 __user *)dst, -@@ -203,8 +294,16 @@ int __copy_in_user(void __user *dst, con +@@ -203,8 +294,16 @@ int __copy_in_user(void __user *dst, const void __u= ser *src, unsigned size) return ret; } default: @@ -10180,7 +11115,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/uacce= ss_64.h linux-3.1.4/arch/x86/in } } =20 -@@ -221,33 +320,72 @@ __must_check unsigned long __clear_user( +@@ -221,33 +320,72 @@ __must_check unsigned long __clear_user(void __use= r *mem, unsigned long len); static __must_check __always_inline int __copy_from_user_inatomic(void *dst, const void __user *src, unsigned s= ize) { @@ -10263,231 +11198,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/ua= ccess_64.h linux-3.1.4/arch/x86/in +copy_user_handle_tail(char __user *to, char __user *from, unsigned len,= unsigned zerorest); =20 #endif /* _ASM_X86_UACCESS_64_H */ -diff -urNp linux-3.1.4/arch/x86/include/asm/uaccess.h linux-3.1.4/arch/x= 86/include/asm/uaccess.h ---- linux-3.1.4/arch/x86/include/asm/uaccess.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/uaccess.h 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -7,12 +7,15 @@ - #include - #include - #include -+#include - #include - #include -=20 - #define VERIFY_READ 0 - #define VERIFY_WRITE 1 -=20 -+extern void check_object_size(const void *ptr, unsigned long n, bool to= ); -+ - /* - * The fs value determines whether argument validity checking should be - * performed or not. If get_fs() =3D=3D USER_DS, checking is performed= , with -@@ -28,7 +31,12 @@ -=20 - #define get_ds() (KERNEL_DS) - #define get_fs() (current_thread_info()->addr_limit) -+#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) -+void __set_fs(mm_segment_t x); -+void set_fs(mm_segment_t x); -+#else - #define set_fs(x) (current_thread_info()->addr_limit =3D (x)) -+#endif -=20 - #define segment_eq(a, b) ((a).seg =3D=3D (b).seg) -=20 -@@ -76,7 +84,33 @@ - * checks that the pointer is in the user space range - after calling - * this function, memory access functions may still return -EFAULT. - */ --#define access_ok(type, addr, size) (likely(__range_not_ok(addr, size) = =3D=3D 0)) -+#define __access_ok(type, addr, size) (likely(__range_not_ok(addr, size= ) =3D=3D 0)) -+#define access_ok(type, addr, size) \ -+({ \ -+ long __size =3D size; \ -+ unsigned long __addr =3D (unsigned long)addr; \ -+ unsigned long __addr_ao =3D __addr & PAGE_MASK; \ -+ unsigned long __end_ao =3D __addr + __size - 1; \ -+ bool __ret_ao =3D __range_not_ok(__addr, __size) =3D=3D 0; \ -+ if (__ret_ao && unlikely((__end_ao ^ __addr_ao) & PAGE_MASK)) { \ -+ while(__addr_ao <=3D __end_ao) { \ -+ char __c_ao; \ -+ __addr_ao +=3D PAGE_SIZE; \ -+ if (__size > PAGE_SIZE) \ -+ cond_resched(); \ -+ if (__get_user(__c_ao, (char __user *)__addr)) \ -+ break; \ -+ if (type !=3D VERIFY_WRITE) { \ -+ __addr =3D __addr_ao; \ -+ continue; \ -+ } \ -+ if (__put_user(__c_ao, (char __user *)__addr)) \ -+ break; \ -+ __addr =3D __addr_ao; \ -+ } \ -+ } \ -+ __ret_ao; \ -+}) -=20 - /* - * The exception table consists of pairs of addresses: the first is the -@@ -182,12 +216,20 @@ extern int __get_user_bad(void); - asm volatile("call __put_user_" #size : "=3Da" (__ret_pu) \ - : "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx") -=20 -- -+#if defined(CONFIG_X86_32) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define __copyuser_seg "gs;" -+#define __COPYUSER_SET_ES "pushl %%gs; popl %%es\n" -+#define __COPYUSER_RESTORE_ES "pushl %%ss; popl %%es\n" -+#else -+#define __copyuser_seg -+#define __COPYUSER_SET_ES -+#define __COPYUSER_RESTORE_ES -+#endif -=20 - #ifdef CONFIG_X86_32 - #define __put_user_asm_u64(x, addr, err, errret) \ -- asm volatile("1: movl %%eax,0(%2)\n" \ -- "2: movl %%edx,4(%2)\n" \ -+ asm volatile("1: "__copyuser_seg"movl %%eax,0(%2)\n" \ -+ "2: "__copyuser_seg"movl %%edx,4(%2)\n" \ - "3:\n" \ - ".section .fixup,\"ax\"\n" \ - "4: movl %3,%0\n" \ -@@ -199,8 +241,8 @@ extern int __get_user_bad(void); - : "A" (x), "r" (addr), "i" (errret), "0" (err)) -=20 - #define __put_user_asm_ex_u64(x, addr) \ -- asm volatile("1: movl %%eax,0(%1)\n" \ -- "2: movl %%edx,4(%1)\n" \ -+ asm volatile("1: "__copyuser_seg"movl %%eax,0(%1)\n" \ -+ "2: "__copyuser_seg"movl %%edx,4(%1)\n" \ - "3:\n" \ - _ASM_EXTABLE(1b, 2b - 1b) \ - _ASM_EXTABLE(2b, 3b - 2b) \ -@@ -252,7 +294,7 @@ extern void __put_user_8(void); - __typeof__(*(ptr)) __pu_val; \ - __chk_user_ptr(ptr); \ - might_fault(); \ -- __pu_val =3D x; \ -+ __pu_val =3D (x); \ - switch (sizeof(*(ptr))) { \ - case 1: \ - __put_user_x(1, __pu_val, ptr, __ret_pu); \ -@@ -373,7 +415,7 @@ do { \ - } while (0) -=20 - #define __get_user_asm(x, addr, err, itype, rtype, ltype, errret) \ -- asm volatile("1: mov"itype" %2,%"rtype"1\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %2,%"rtype"1\n"\ - "2:\n" \ - ".section .fixup,\"ax\"\n" \ - "3: mov %3,%0\n" \ -@@ -381,7 +423,7 @@ do { \ - " jmp 2b\n" \ - ".previous\n" \ - _ASM_EXTABLE(1b, 3b) \ -- : "=3Dr" (err), ltype(x) \ -+ : "=3Dr" (err), ltype (x) \ - : "m" (__m(addr)), "i" (errret), "0" (err)) -=20 - #define __get_user_size_ex(x, ptr, size) \ -@@ -406,7 +448,7 @@ do { \ - } while (0) -=20 - #define __get_user_asm_ex(x, addr, itype, rtype, ltype) \ -- asm volatile("1: mov"itype" %1,%"rtype"0\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %1,%"rtype"0\n"\ - "2:\n" \ - _ASM_EXTABLE(1b, 2b - 1b) \ - : ltype(x) : "m" (__m(addr))) -@@ -423,13 +465,24 @@ do { \ - int __gu_err; \ - unsigned long __gu_val; \ - __get_user_size(__gu_val, (ptr), (size), __gu_err, -EFAULT); \ -- (x) =3D (__force __typeof__(*(ptr)))__gu_val; \ -+ (x) =3D (__typeof__(*(ptr)))__gu_val; \ - __gu_err; \ - }) -=20 - /* FIXME: this hack is definitely wrong -AK */ - struct __large_struct { unsigned long buf[100]; }; --#define __m(x) (*(struct __large_struct __user *)(x)) -+#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define ____m(x) \ -+({ \ -+ unsigned long ____x =3D (unsigned long)(x); \ -+ if (____x < PAX_USER_SHADOW_BASE) \ -+ ____x +=3D PAX_USER_SHADOW_BASE; \ -+ (void __user *)____x; \ -+}) -+#else -+#define ____m(x) (x) -+#endif -+#define __m(x) (*(struct __large_struct __user *)____m(x)) -=20 - /* - * Tell gcc we read from memory instead of writing: this is because -@@ -437,7 +490,7 @@ struct __large_struct { unsigned long bu - * aliasing issues. - */ - #define __put_user_asm(x, addr, err, itype, rtype, ltype, errret) \ -- asm volatile("1: mov"itype" %"rtype"1,%2\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"1,%2\n"\ - "2:\n" \ - ".section .fixup,\"ax\"\n" \ - "3: mov %3,%0\n" \ -@@ -445,10 +498,10 @@ struct __large_struct { unsigned long bu - ".previous\n" \ - _ASM_EXTABLE(1b, 3b) \ - : "=3Dr"(err) \ -- : ltype(x), "m" (__m(addr)), "i" (errret), "0" (err)) -+ : ltype (x), "m" (__m(addr)), "i" (errret), "0" (err)) -=20 - #define __put_user_asm_ex(x, addr, itype, rtype, ltype) \ -- asm volatile("1: mov"itype" %"rtype"0,%1\n" \ -+ asm volatile("1: "__copyuser_seg"mov"itype" %"rtype"0,%1\n"\ - "2:\n" \ - _ASM_EXTABLE(1b, 2b - 1b) \ - : : ltype(x), "m" (__m(addr))) -@@ -487,8 +540,12 @@ struct __large_struct { unsigned long bu - * On error, the variable @x is set to zero. - */ -=20 -+#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define __get_user(x, ptr) get_user((x), (ptr)) -+#else - #define __get_user(x, ptr) \ - __get_user_nocheck((x), (ptr), sizeof(*(ptr))) -+#endif -=20 - /** - * __put_user: - Write a simple value into user space, with less checki= ng. -@@ -510,8 +567,12 @@ struct __large_struct { unsigned long bu - * Returns zero on success, or -EFAULT on error. - */ -=20 -+#if defined(CONFIG_X86_64) && defined(CONFIG_PAX_MEMORY_UDEREF) -+#define __put_user(x, ptr) put_user((x), (ptr)) -+#else - #define __put_user(x, ptr) \ - __put_user_nocheck((__typeof__(*(ptr)))(x), (ptr), sizeof(*(ptr))) -+#endif -=20 - #define __get_user_unaligned __get_user - #define __put_user_unaligned __put_user -@@ -529,7 +590,7 @@ struct __large_struct { unsigned long bu - #define get_user_ex(x, ptr) do { \ - unsigned long __gue_val; \ - __get_user_size_ex((__gue_val), (ptr), (sizeof(*(ptr)))); \ -- (x) =3D (__force __typeof__(*(ptr)))__gue_val; \ -+ (x) =3D (__typeof__(*(ptr)))__gue_val; \ - } while (0) -=20 - #ifdef CONFIG_X86_WP_WORKS_OK -diff -urNp linux-3.1.4/arch/x86/include/asm/vdso.h linux-3.1.4/arch/x86/= include/asm/vdso.h ---- linux-3.1.4/arch/x86/include/asm/vdso.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/include/asm/vdso.h 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/arch/x86/include/asm/vdso.h b/arch/x86/include/asm/vdso.h +index bb05228..d763d5b 100644 +--- a/arch/x86/include/asm/vdso.h ++++ b/arch/x86/include/asm/vdso.h @@ -11,7 +11,7 @@ extern const char VDSO32_PRELINK[]; #define VDSO32_SYMBOL(base, name) \ ({ \ @@ -10497,9 +11211,10 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/vdso= .h linux-3.1.4/arch/x86/include/ }) #endif =20 -diff -urNp linux-3.1.4/arch/x86/include/asm/x86_init.h linux-3.1.4/arch/= x86/include/asm/x86_init.h ---- linux-3.1.4/arch/x86/include/asm/x86_init.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/include/asm/x86_init.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/include/asm/x86_init.h b/arch/x86/include/asm/x86_= init.h +index d3d8590..d296b5f 100644 +--- a/arch/x86/include/asm/x86_init.h ++++ b/arch/x86/include/asm/x86_init.h @@ -28,7 +28,7 @@ struct x86_init_mpparse { void (*mpc_oem_bus_info)(struct mpc_bus *m, char *name); void (*find_smp_config)(void); @@ -10617,10 +11332,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/x86= _init.h linux-3.1.4/arch/x86/incl =20 extern struct x86_init_ops x86_init; extern struct x86_cpuinit_ops x86_cpuinit; -diff -urNp linux-3.1.4/arch/x86/include/asm/xsave.h linux-3.1.4/arch/x86= /include/asm/xsave.h ---- linux-3.1.4/arch/x86/include/asm/xsave.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/include/asm/xsave.h 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -65,6 +65,11 @@ static inline int xsave_user(struct xsav +diff --git a/arch/x86/include/asm/xsave.h b/arch/x86/include/asm/xsave.h +index c6ce245..ffbdab7 100644 +--- a/arch/x86/include/asm/xsave.h ++++ b/arch/x86/include/asm/xsave.h +@@ -65,6 +65,11 @@ static inline int xsave_user(struct xsave_struct __us= er *buf) { int err; =20 @@ -10632,7 +11348,7 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/xsave= .h linux-3.1.4/arch/x86/include /* * Clear the xsave header first, so that reserved fields are * initialized to zero. -@@ -96,10 +101,15 @@ static inline int xsave_user(struct xsav +@@ -96,10 +101,15 @@ static inline int xsave_user(struct xsave_struct __= user *buf) static inline int xrestore_user(struct xsave_struct __user *buf, u64 ma= sk) { int err; @@ -10649,136 +11365,11 @@ diff -urNp linux-3.1.4/arch/x86/include/asm/xs= ave.h linux-3.1.4/arch/x86/include __asm__ __volatile__("1: .byte " REX_PREFIX "0x0f,0xae,0x2f\n" "2:\n" ".section .fixup,\"ax\"\n" -diff -urNp linux-3.1.4/arch/x86/Kconfig linux-3.1.4/arch/x86/Kconfig ---- linux-3.1.4/arch/x86/Kconfig 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/Kconfig 2011-11-16 18:40:08.000000000 -0500 -@@ -236,7 +236,7 @@ config X86_HT -=20 - config X86_32_LAZY_GS - def_bool y -- depends on X86_32 && !CC_STACKPROTECTOR -+ depends on X86_32 && !CC_STACKPROTECTOR && !PAX_MEMORY_UDEREF -=20 - config ARCH_HWEIGHT_CFLAGS - string -@@ -1019,7 +1019,7 @@ choice -=20 - config NOHIGHMEM - bool "off" -- depends on !X86_NUMAQ -+ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) - ---help--- - Linux can use up to 64 Gigabytes of physical memory on x86 systems. - However, the address space of 32-bit x86 processors is only 4 -@@ -1056,7 +1056,7 @@ config NOHIGHMEM -=20 - config HIGHMEM4G - bool "4GB" -- depends on !X86_NUMAQ -+ depends on !X86_NUMAQ && !(PAX_PAGEEXEC && PAX_ENABLE_PAE) - ---help--- - Select this if you have a 32-bit processor and between 1 and 4 - gigabytes of physical RAM. -@@ -1110,7 +1110,7 @@ config PAGE_OFFSET - hex - default 0xB0000000 if VMSPLIT_3G_OPT - default 0x80000000 if VMSPLIT_2G -- default 0x78000000 if VMSPLIT_2G_OPT -+ default 0x70000000 if VMSPLIT_2G_OPT - default 0x40000000 if VMSPLIT_1G - default 0xC0000000 - depends on X86_32 -@@ -1484,6 +1484,7 @@ config SECCOMP -=20 - config CC_STACKPROTECTOR - bool "Enable -fstack-protector buffer overflow detection (EXPERIMENTAL= )" -+ depends on X86_64 || !PAX_MEMORY_UDEREF - ---help--- - This option turns on the -fstack-protector GCC feature. This - feature puts, at the beginning of functions, a canary value on -@@ -1541,6 +1542,7 @@ config KEXEC_JUMP - config PHYSICAL_START - hex "Physical address where the kernel is loaded" if (EXPERT || CRASH_= DUMP) - default "0x1000000" -+ range 0x400000 0x40000000 - ---help--- - This gives the physical address where the kernel is loaded. -=20 -@@ -1604,6 +1606,7 @@ config X86_NEED_RELOCS - config PHYSICAL_ALIGN - hex "Alignment value to which kernel should be aligned" if X86_32 - default "0x1000000" -+ range 0x400000 0x1000000 if PAX_KERNEXEC - range 0x2000 0x1000000 - ---help--- - This value puts the alignment restrictions on physical address -@@ -1635,9 +1638,10 @@ config HOTPLUG_CPU - Say N if you want to disable CPU hotplug. -=20 - config COMPAT_VDSO -- def_bool y -+ def_bool n - prompt "Compat VDSO support" - depends on X86_32 || IA32_EMULATION -+ depends on !PAX_NOEXEC && !PAX_MEMORY_UDEREF - ---help--- - Map the 32-bit VDSO to the predictable old-style address too. -=20 -diff -urNp linux-3.1.4/arch/x86/Kconfig.cpu linux-3.1.4/arch/x86/Kconfig= .cpu ---- linux-3.1.4/arch/x86/Kconfig.cpu 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/Kconfig.cpu 2011-11-16 18:39:07.000000000 -0500 -@@ -341,7 +341,7 @@ config X86_PPRO_FENCE -=20 - config X86_F00F_BUG - def_bool y -- depends on M586MMX || M586TSC || M586 || M486 || M386 -+ depends on (M586MMX || M586TSC || M586 || M486 || M386) && !PAX_KERNEX= EC -=20 - config X86_INVD_BUG - def_bool y -@@ -365,7 +365,7 @@ config X86_POPAD_OK -=20 - config X86_ALIGNMENT_16 - def_bool y -- depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MELAN || MK6 || M5= 86MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 -+ depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || X86_ELAN || MK8 ||= MK7 || MK6 || MCORE2 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 |= | M586MMX || M586TSC || M586 || M486 || MVIAC3_2 || MGEODEGX1 -=20 - config X86_INTEL_USERCOPY - def_bool y -@@ -411,7 +411,7 @@ config X86_CMPXCHG64 - # generates cmov. - config X86_CMOV - def_bool y -- depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUM= III || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEFFICEON |= | X86_64 || MATOM || MGEODE_LX) -+ depends on (MK8 || MK7 || MCORE2 || MPSC || MPENTIUM4 || MPENTIUMM || = MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEF= FICEON || X86_64 || MATOM || MGEODE_LX) -=20 - config X86_MINIMUM_CPU_FAMILY - int -diff -urNp linux-3.1.4/arch/x86/Kconfig.debug linux-3.1.4/arch/x86/Kconf= ig.debug ---- linux-3.1.4/arch/x86/Kconfig.debug 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/Kconfig.debug 2011-11-16 18:39:07.000000000 -05= 00 -@@ -81,7 +81,7 @@ config X86_PTDUMP - config DEBUG_RODATA - bool "Write protect kernel read-only data structures" - default y -- depends on DEBUG_KERNEL -+ depends on DEBUG_KERNEL && BROKEN - ---help--- - Mark the kernel read-only data as write-protected in the pagetables, - in order to catch accidental (and incorrect) writes to such const -@@ -99,7 +99,7 @@ config DEBUG_RODATA_TEST -=20 - config DEBUG_SET_MODULE_RONX - bool "Set loadable kernel module data as NX and text as RO" -- depends on MODULES -+ depends on MODULES && BROKEN - ---help--- - This option helps catch unintended modifications to loadable - kernel module's text and read-only data. It also prevents execution -diff -urNp linux-3.1.4/arch/x86/kernel/acpi/realmode/Makefile linux-3.1.= 4/arch/x86/kernel/acpi/realmode/Makefile ---- linux-3.1.4/arch/x86/kernel/acpi/realmode/Makefile 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/acpi/realmode/Makefile 2011-11-16 18:39:= 07.000000000 -0500 -@@ -41,6 +41,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os=20 +diff --git a/arch/x86/kernel/acpi/realmode/Makefile b/arch/x86/kernel/ac= pi/realmode/Makefile +index 6a564ac..9b1340c 100644 +--- a/arch/x86/kernel/acpi/realmode/Makefile ++++ b/arch/x86/kernel/acpi/realmode/Makefile +@@ -41,6 +41,9 @@ KBUILD_CFLAGS :=3D $(LINUXINCLUDE) -g -Os -D_SETUP -D_= WAKEUP -D__KERNEL__ \ $(call cc-option, -fno-stack-protector) \ $(call cc-option, -mpreferred-stack-boundary=3D2) KBUILD_CFLAGS +=3D $(call cc-option, -m32) @@ -10788,9 +11379,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/acpi/real= mode/Makefile linux-3.1.4/arch/x KBUILD_AFLAGS :=3D $(KBUILD_CFLAGS) -D__ASSEMBLY__ GCOV_PROFILE :=3D n =20 -diff -urNp linux-3.1.4/arch/x86/kernel/acpi/realmode/wakeup.S linux-3.1.= 4/arch/x86/kernel/acpi/realmode/wakeup.S ---- linux-3.1.4/arch/x86/kernel/acpi/realmode/wakeup.S 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/acpi/realmode/wakeup.S 2011-11-16 18:40:= 08.000000000 -0500 +diff --git a/arch/x86/kernel/acpi/realmode/wakeup.S b/arch/x86/kernel/ac= pi/realmode/wakeup.S +index b4fd836..4358fe3 100644 +--- a/arch/x86/kernel/acpi/realmode/wakeup.S ++++ b/arch/x86/kernel/acpi/realmode/wakeup.S @@ -108,6 +108,9 @@ wakeup_code: /* Do any other stuff... */ =20 @@ -10809,9 +11401,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/acpi/real= mode/wakeup.S linux-3.1.4/arch/x #else pushw $0 pushw trampoline_segment -diff -urNp linux-3.1.4/arch/x86/kernel/acpi/sleep.c linux-3.1.4/arch/x86= /kernel/acpi/sleep.c ---- linux-3.1.4/arch/x86/kernel/acpi/sleep.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/kernel/acpi/sleep.c 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c +index 103b6ab..2004d0a 100644 +--- a/arch/x86/kernel/acpi/sleep.c ++++ b/arch/x86/kernel/acpi/sleep.c @@ -94,8 +94,12 @@ int acpi_suspend_lowlevel(void) header->trampoline_segment =3D trampoline_address() >> 4; #ifdef CONFIG_SMP @@ -10825,9 +11418,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/acpi/slee= p.c linux-3.1.4/arch/x86/kernel/ initial_gs =3D per_cpu_offset(smp_processor_id()); #endif initial_code =3D (unsigned long)wakeup_long64; -diff -urNp linux-3.1.4/arch/x86/kernel/acpi/wakeup_32.S linux-3.1.4/arch= /x86/kernel/acpi/wakeup_32.S ---- linux-3.1.4/arch/x86/kernel/acpi/wakeup_32.S 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/acpi/wakeup_32.S 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/arch/x86/kernel/acpi/wakeup_32.S b/arch/x86/kernel/acpi/wak= eup_32.S +index 13ab720..95d5442 100644 +--- a/arch/x86/kernel/acpi/wakeup_32.S ++++ b/arch/x86/kernel/acpi/wakeup_32.S @@ -30,13 +30,11 @@ wakeup_pmode_return: # and restore the stack ... but you need gdt for this to work movl saved_context_esp, %esp @@ -10844,10 +11438,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/acpi/wak= eup_32.S linux-3.1.4/arch/x86/ker =20 bogus_magic: jmp bogus_magic -diff -urNp linux-3.1.4/arch/x86/kernel/alternative.c linux-3.1.4/arch/x8= 6/kernel/alternative.c ---- linux-3.1.4/arch/x86/kernel/alternative.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/kernel/alternative.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -276,6 +276,13 @@ void __init_or_module apply_alternatives +diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative= .c +index c638228..16dfa8d 100644 +--- a/arch/x86/kernel/alternative.c ++++ b/arch/x86/kernel/alternative.c +@@ -276,6 +276,13 @@ void __init_or_module apply_alternatives(struct alt= _instr *start, */ for (a =3D start; a < end; a++) { instr =3D (u8 *)&a->instr_offset + a->instr_offset; @@ -10861,7 +11456,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/alternativ= e.c linux-3.1.4/arch/x86/kernel replacement =3D (u8 *)&a->repl_offset + a->repl_offset; BUG_ON(a->replacementlen > a->instrlen); BUG_ON(a->instrlen > sizeof(insnbuf)); -@@ -307,10 +314,16 @@ static void alternatives_smp_lock(const=20 +@@ -307,10 +314,16 @@ static void alternatives_smp_lock(const s32 *start= , const s32 *end, for (poff =3D start; poff < end; poff++) { u8 *ptr =3D (u8 *)poff + *poff; =20 @@ -10879,7 +11474,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/alternativ= e.c linux-3.1.4/arch/x86/kernel text_poke(ptr, ((unsigned char []){0xf0}), 1); }; mutex_unlock(&text_mutex); -@@ -328,10 +341,16 @@ static void alternatives_smp_unlock(cons +@@ -328,10 +341,16 @@ static void alternatives_smp_unlock(const s32 *sta= rt, const s32 *end, for (poff =3D start; poff < end; poff++) { u8 *ptr =3D (u8 *)poff + *poff; =20 @@ -10897,7 +11492,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/alternativ= e.c linux-3.1.4/arch/x86/kernel text_poke(ptr, ((unsigned char []){0x3E}), 1); }; mutex_unlock(&text_mutex); -@@ -500,7 +519,7 @@ void __init_or_module apply_paravirt(str +@@ -500,7 +519,7 @@ void __init_or_module apply_paravirt(struct paravirt= _patch_site *start, =20 BUG_ON(p->len > MAX_PATCH_LEN); /* prep the buffer with the original instructions */ @@ -10906,7 +11501,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/alternativ= e.c linux-3.1.4/arch/x86/kernel used =3D pv_init_ops.patch(p->instrtype, p->clobbers, insnbuf, (unsigned long)p->instr, p->len); =20 -@@ -568,7 +587,7 @@ void __init alternative_instructions(voi +@@ -568,7 +587,7 @@ void __init alternative_instructions(void) if (smp_alt_once) free_init_pages("SMP alternatives", (unsigned long)__smp_locks, @@ -10915,7 +11510,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/alternativ= e.c linux-3.1.4/arch/x86/kernel =20 restart_nmi(); } -@@ -585,13 +604,17 @@ void __init alternative_instructions(voi +@@ -585,13 +604,17 @@ void __init alternative_instructions(void) * instructions. And on the local CPU you need to be protected again NM= I or MCE * handlers seeing an inconsistent instruction while you patch. */ @@ -10935,7 +11530,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/alternativ= e.c linux-3.1.4/arch/x86/kernel local_irq_restore(flags); /* Could also do a CLFLUSH here to speed up CPU recovery; but that causes hangs on some VIA CPUs. */ -@@ -613,36 +636,22 @@ void *__init_or_module text_poke_early(v +@@ -613,36 +636,22 @@ void *__init_or_module text_poke_early(void *addr,= const void *opcode, */ void *__kprobes text_poke(void *addr, const void *opcode, size_t len) { @@ -10980,9 +11575,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/alternati= ve.c linux-3.1.4/arch/x86/kernel return addr; } =20 -diff -urNp linux-3.1.4/arch/x86/kernel/apic/apic.c linux-3.1.4/arch/x86/= kernel/apic/apic.c ---- linux-3.1.4/arch/x86/kernel/apic/apic.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/kernel/apic/apic.c 2011-11-16 18:40:08.00000000= 0 -0500 +diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c +index 52fa563..5de9d9c 100644 +--- a/arch/x86/kernel/apic/apic.c ++++ b/arch/x86/kernel/apic/apic.c @@ -174,7 +174,7 @@ int first_system_vector =3D 0xfe; /* * Debug level, exported for io_apic.c @@ -10992,7 +11588,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apic/apic.= c linux-3.1.4/arch/x86/kernel/a =20 int pic_mode; =20 -@@ -1835,7 +1835,7 @@ void smp_error_interrupt(struct pt_regs=20 +@@ -1835,7 +1835,7 @@ void smp_error_interrupt(struct pt_regs *regs) apic_write(APIC_ESR, 0); v1 =3D apic_read(APIC_ESR); ack_APIC_irq(); @@ -11001,7 +11597,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apic/apic.= c linux-3.1.4/arch/x86/kernel/a =20 apic_printk(APIC_DEBUG, KERN_DEBUG "APIC error on CPU%d: %02x(%02x)", smp_processor_id(), v0 , v1); -@@ -2209,6 +2209,8 @@ static int __cpuinit apic_cluster_num(vo +@@ -2209,6 +2209,8 @@ static int __cpuinit apic_cluster_num(void) u16 *bios_cpu_apicid; DECLARE_BITMAP(clustermap, NUM_APIC_CLUSTERS); =20 @@ -11010,10 +11606,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apic/api= c.c linux-3.1.4/arch/x86/kernel/a bios_cpu_apicid =3D early_per_cpu_ptr(x86_bios_cpu_apicid); bitmap_zero(clustermap, NUM_APIC_CLUSTERS); =20 -diff -urNp linux-3.1.4/arch/x86/kernel/apic/io_apic.c linux-3.1.4/arch/x= 86/kernel/apic/io_apic.c ---- linux-3.1.4/arch/x86/kernel/apic/io_apic.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/kernel/apic/io_apic.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -1028,7 +1028,7 @@ int IO_APIC_get_PCI_irq_vector(int bus,=20 +diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_ap= ic.c +index 8eb863e..32e6934 100644 +--- a/arch/x86/kernel/apic/io_apic.c ++++ b/arch/x86/kernel/apic/io_apic.c +@@ -1028,7 +1028,7 @@ int IO_APIC_get_PCI_irq_vector(int bus, int slot, = int pin, } EXPORT_SYMBOL(IO_APIC_get_PCI_irq_vector); =20 @@ -11031,7 +11628,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apic/io_ap= ic.c linux-3.1.4/arch/x86/kerne { raw_spin_unlock(&vector_lock); } -@@ -2405,7 +2405,7 @@ static void ack_apic_edge(struct irq_dat +@@ -2405,7 +2405,7 @@ static void ack_apic_edge(struct irq_data *data) ack_APIC_irq(); } =20 @@ -11040,7 +11637,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apic/io_ap= ic.c linux-3.1.4/arch/x86/kerne =20 /* * IO-APIC versions below 0x20 don't support EOI register. -@@ -2513,7 +2513,7 @@ static void ack_apic_level(struct irq_da +@@ -2513,7 +2513,7 @@ static void ack_apic_level(struct irq_data *data) * at the cpu. */ if (!(v & (1 << (i & 0x1f)))) { @@ -11049,9 +11646,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apic/io_a= pic.c linux-3.1.4/arch/x86/kerne =20 eoi_ioapic_irq(irq, cfg); } -diff -urNp linux-3.1.4/arch/x86/kernel/apm_32.c linux-3.1.4/arch/x86/ker= nel/apm_32.c ---- linux-3.1.4/arch/x86/kernel/apm_32.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/apm_32.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/arch/x86/kernel/apm_32.c b/arch/x86/kernel/apm_32.c +index 0371c48..54cdf63 100644 +--- a/arch/x86/kernel/apm_32.c ++++ b/arch/x86/kernel/apm_32.c @@ -413,7 +413,7 @@ static DEFINE_MUTEX(apm_mutex); * This is for buggy BIOS's that refer to (real mode) segment 0x40 * even though they are called in protected mode. @@ -11084,7 +11682,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apm_32.c l= inux-3.1.4/arch/x86/kernel/apm_ put_cpu(); =20 return call->eax & 0xff; -@@ -667,7 +674,10 @@ static long __apm_bios_call_simple(void=20 +@@ -667,7 +674,10 @@ static long __apm_bios_call_simple(void *_call) BUG_ON(cpu !=3D 0); gdt =3D get_cpu_gdt_table(cpu); save_desc_40 =3D gdt[0x40 / 8]; @@ -11095,7 +11693,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apm_32.c l= inux-3.1.4/arch/x86/kernel/apm_ =20 apm_irq_save(flags); APM_DO_SAVE_SEGS; -@@ -675,7 +685,11 @@ static long __apm_bios_call_simple(void=20 +@@ -675,7 +685,11 @@ static long __apm_bios_call_simple(void *_call) &call->eax); APM_DO_RESTORE_SEGS; apm_irq_restore(flags); @@ -11123,20 +11721,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/apm_32.c= linux-3.1.4/arch/x86/kernel/apm_ =20 proc_create("apm", 0, NULL, &apm_file_ops); =20 -diff -urNp linux-3.1.4/arch/x86/kernel/asm-offsets_64.c linux-3.1.4/arch= /x86/kernel/asm-offsets_64.c ---- linux-3.1.4/arch/x86/kernel/asm-offsets_64.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/asm-offsets_64.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -69,6 +69,7 @@ int main(void) - BLANK(); - #undef ENTRY -=20 -+ DEFINE(TSS_size, sizeof(struct tss_struct)); - OFFSET(TSS_ist, tss_struct, x86_tss.ist); - BLANK(); -=20 -diff -urNp linux-3.1.4/arch/x86/kernel/asm-offsets.c linux-3.1.4/arch/x8= 6/kernel/asm-offsets.c ---- linux-3.1.4/arch/x86/kernel/asm-offsets.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/kernel/asm-offsets.c 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/kernel/asm-offsets.c b/arch/x86/kernel/asm-offsets= .c +index 4f13faf..87db5d2 100644 +--- a/arch/x86/kernel/asm-offsets.c ++++ b/arch/x86/kernel/asm-offsets.c @@ -33,6 +33,8 @@ void common(void) { OFFSET(TI_status, thread_info, status); OFFSET(TI_addr_limit, thread_info, addr_limit); @@ -11173,10 +11761,38 @@ diff -urNp linux-3.1.4/arch/x86/kernel/asm-offs= ets.c linux-3.1.4/arch/x86/kernel #ifdef CONFIG_XEN BLANK(); OFFSET(XEN_vcpu_info_mask, vcpu_info, evtchn_upcall_mask); -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/amd.c linux-3.1.4/arch/x86/ke= rnel/cpu/amd.c ---- linux-3.1.4/arch/x86/kernel/cpu/amd.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/amd.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -647,7 +647,7 @@ static unsigned int __cpuinit amd_size_c +diff --git a/arch/x86/kernel/asm-offsets_64.c b/arch/x86/kernel/asm-offs= ets_64.c +index e72a119..6e2955d 100644 +--- a/arch/x86/kernel/asm-offsets_64.c ++++ b/arch/x86/kernel/asm-offsets_64.c +@@ -69,6 +69,7 @@ int main(void) + BLANK(); + #undef ENTRY +=20 ++ DEFINE(TSS_size, sizeof(struct tss_struct)); + OFFSET(TSS_ist, tss_struct, x86_tss.ist); + BLANK(); +=20 +diff --git a/arch/x86/kernel/cpu/Makefile b/arch/x86/kernel/cpu/Makefile +index 6042981..e638266 100644 +--- a/arch/x86/kernel/cpu/Makefile ++++ b/arch/x86/kernel/cpu/Makefile +@@ -8,10 +8,6 @@ CFLAGS_REMOVE_common.o =3D -pg + CFLAGS_REMOVE_perf_event.o =3D -pg + endif +=20 +-# Make sure load_percpu_segment has no stackprotector +-nostackp :=3D $(call cc-option, -fno-stack-protector) +-CFLAGS_common.o :=3D $(nostackp) +- + obj-y :=3D intel_cacheinfo.o scattered.o topology.o + obj-y +=3D proc.o capflags.o powerflags.o common.o + obj-y +=3D vmware.o hypervisor.o sched.o mshyperv.o +diff --git a/arch/x86/kernel/cpu/amd.c b/arch/x86/kernel/cpu/amd.c +index b13ed39..603286c 100644 +--- a/arch/x86/kernel/cpu/amd.c ++++ b/arch/x86/kernel/cpu/amd.c +@@ -647,7 +647,7 @@ static unsigned int __cpuinit amd_size_cache(struct = cpuinfo_x86 *c, unsigned int size) { /* AMD errata T13 (order #21922) */ @@ -11185,10 +11801,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/amd.= c linux-3.1.4/arch/x86/kernel/cpu /* Duron Rev A0 */ if (c->x86_model =3D=3D 3 && c->x86_mask =3D=3D 0) size =3D 64; -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/common.c linux-3.1.4/arch/x86= /kernel/cpu/common.c ---- linux-3.1.4/arch/x86/kernel/cpu/common.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/common.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -83,60 +83,6 @@ static const struct cpu_dev __cpuinitcon +diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c +index 6218439..0f1addc 100644 +--- a/arch/x86/kernel/cpu/common.c ++++ b/arch/x86/kernel/cpu/common.c +@@ -83,60 +83,6 @@ static const struct cpu_dev __cpuinitconst default_cp= u =3D { =20 static const struct cpu_dev *this_cpu __cpuinitdata =3D &default_cpu; =20 @@ -11258,7 +11875,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/common= .c linux-3.1.4/arch/x86/kernel/ gdt_descr.size =3D GDT_SIZE - 1; load_gdt(&gdt_descr); /* Reload the per-cpu base */ -@@ -840,6 +786,10 @@ static void __cpuinit identify_cpu(struc +@@ -840,6 +786,10 @@ static void __cpuinit identify_cpu(struct cpuinfo_x= 86 *c) /* Filter out anything that depends on CPUID levels we don't have */ filter_cpuid_features(c, true); =20 @@ -11269,7 +11886,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/common= .c linux-3.1.4/arch/x86/kernel/ /* If the model name is still unset, do table lookup. */ if (!c->x86_model_id[0]) { const char *p; -@@ -1019,6 +969,9 @@ static __init int setup_disablecpuid(cha +@@ -1019,6 +969,9 @@ static __init int setup_disablecpuid(char *arg) } __setup("clearcpuid=3D", setup_disablecpuid); =20 @@ -11279,7 +11896,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/common= .c linux-3.1.4/arch/x86/kernel/ #ifdef CONFIG_X86_64 struct desc_ptr idt_descr =3D { NR_VECTORS * 16 - 1, (unsigned long) id= t_table }; =20 -@@ -1034,7 +987,7 @@ DEFINE_PER_CPU(struct task_struct *, cur +@@ -1034,7 +987,7 @@ DEFINE_PER_CPU(struct task_struct *, current_task) = ____cacheline_aligned =3D EXPORT_PER_CPU_SYMBOL(current_task); =20 DEFINE_PER_CPU(unsigned long, kernel_stack) =3D @@ -11288,7 +11905,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/common= .c linux-3.1.4/arch/x86/kernel/ EXPORT_PER_CPU_SYMBOL(kernel_stack); =20 DEFINE_PER_CPU(char *, irq_stack_ptr) =3D -@@ -1099,7 +1052,7 @@ struct pt_regs * __cpuinit idle_regs(str +@@ -1099,7 +1052,7 @@ struct pt_regs * __cpuinit idle_regs(struct pt_reg= s *regs) { memset(regs, 0, sizeof(struct pt_regs)); regs->fs =3D __KERNEL_PERCPU; @@ -11332,10 +11949,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/comm= on.c linux-3.1.4/arch/x86/kernel/ struct thread_struct *thread =3D &curr->thread; =20 if (cpumask_test_and_set_cpu(cpu, cpu_initialized_mask)) { -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/intel.c linux-3.1.4/arch/x86/= kernel/cpu/intel.c ---- linux-3.1.4/arch/x86/kernel/cpu/intel.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/intel.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -172,7 +172,7 @@ static void __cpuinit trap_init_f00f_bug +diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c +index ed6086e..a1dcf29 100644 +--- a/arch/x86/kernel/cpu/intel.c ++++ b/arch/x86/kernel/cpu/intel.c +@@ -172,7 +172,7 @@ static void __cpuinit trap_init_f00f_bug(void) * Update the IDT descriptor and reload the IDT so that * it uses the read-only mapped virtual address. */ @@ -11344,23 +11962,25 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/inte= l.c linux-3.1.4/arch/x86/kernel/c load_idt(&idt_descr); } #endif -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/Makefile linux-3.1.4/arch/x86= /kernel/cpu/Makefile ---- linux-3.1.4/arch/x86/kernel/cpu/Makefile 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/Makefile 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -8,10 +8,6 @@ CFLAGS_REMOVE_common.o =3D -pg - CFLAGS_REMOVE_perf_event.o =3D -pg - endif -=20 --# Make sure load_percpu_segment has no stackprotector --nostackp :=3D $(call cc-option, -fno-stack-protector) --CFLAGS_common.o :=3D $(nostackp) -- - obj-y :=3D intel_cacheinfo.o scattered.o topology.o - obj-y +=3D proc.o capflags.o powerflags.o common.o - obj-y +=3D vmware.o hypervisor.o sched.o mshyperv.o -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck/mce.c linux-3.1.4/arch= /x86/kernel/cpu/mcheck/mce.c ---- linux-3.1.4/arch/x86/kernel/cpu/mcheck/mce.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/mcheck/mce.c 2011-12-02 17:38:47.000= 000000 -0500 +diff --git a/arch/x86/kernel/cpu/mcheck/mce-inject.c b/arch/x86/kernel/c= pu/mcheck/mce-inject.c +index 0ed633c..82cef2a 100644 +--- a/arch/x86/kernel/cpu/mcheck/mce-inject.c ++++ b/arch/x86/kernel/cpu/mcheck/mce-inject.c +@@ -215,7 +215,9 @@ static int inject_init(void) + if (!alloc_cpumask_var(&mce_inject_cpumask, GFP_KERNEL)) + return -ENOMEM; + printk(KERN_INFO "Machine check injector initialized\n"); +- mce_chrdev_ops.write =3D mce_write; ++ pax_open_kernel(); ++ *(void **)&mce_chrdev_ops.write =3D mce_write; ++ pax_close_kernel(); + register_die_notifier(&mce_raise_nb); + return 0; + } +diff --git a/arch/x86/kernel/cpu/mcheck/mce.c b/arch/x86/kernel/cpu/mche= ck/mce.c +index 08363b0..ee26113 100644 +--- a/arch/x86/kernel/cpu/mcheck/mce.c ++++ b/arch/x86/kernel/cpu/mcheck/mce.c @@ -42,6 +42,7 @@ #include #include @@ -11391,7 +12011,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker =20 /* Panic in progress. Enable interrupts and wait for final IPI */ static void wait_for_panic(void) -@@ -260,7 +261,7 @@ static void mce_panic(char *msg, struct=20 +@@ -260,7 +261,7 @@ static void mce_panic(char *msg, struct mce *final, = char *exp) /* * Make sure only one CPU runs in machine check panic */ @@ -11400,7 +12020,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker wait_for_panic(); barrier(); =20 -@@ -268,7 +269,7 @@ static void mce_panic(char *msg, struct=20 +@@ -268,7 +269,7 @@ static void mce_panic(char *msg, struct mce *final, = char *exp) console_verbose(); } else { /* Don't log too much for fake panic */ @@ -11418,7 +12038,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker wait_for_panic(); if (!monarch_timeout) goto out; -@@ -1392,7 +1393,7 @@ static void unexpected_machine_check(str +@@ -1392,7 +1393,7 @@ static void unexpected_machine_check(struct pt_reg= s *regs, long error_code) } =20 /* Call the installed machine check handler for this CPU setup. */ @@ -11427,7 +12047,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker unexpected_machine_check; =20 /* -@@ -1415,7 +1416,9 @@ void __cpuinit mcheck_cpu_init(struct cp +@@ -1415,7 +1416,9 @@ void __cpuinit mcheck_cpu_init(struct cpuinfo_x86 = *c) return; } =20 @@ -11437,7 +12057,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker =20 __mcheck_cpu_init_generic(); __mcheck_cpu_init_vendor(c); -@@ -1429,7 +1432,7 @@ void __cpuinit mcheck_cpu_init(struct cp +@@ -1429,7 +1432,7 @@ void __cpuinit mcheck_cpu_init(struct cpuinfo_x86 = *c) */ =20 static DEFINE_SPINLOCK(mce_chrdev_state_lock); @@ -11446,7 +12066,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker static int mce_chrdev_open_exclu; /* already open exclusive? */ =20 static int mce_chrdev_open(struct inode *inode, struct file *file) -@@ -1437,7 +1440,7 @@ static int mce_chrdev_open(struct inode=20 +@@ -1437,7 +1440,7 @@ static int mce_chrdev_open(struct inode *inode, st= ruct file *file) spin_lock(&mce_chrdev_state_lock); =20 if (mce_chrdev_open_exclu || @@ -11455,7 +12075,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker spin_unlock(&mce_chrdev_state_lock); =20 return -EBUSY; -@@ -1445,7 +1448,7 @@ static int mce_chrdev_open(struct inode=20 +@@ -1445,7 +1448,7 @@ static int mce_chrdev_open(struct inode *inode, st= ruct file *file) =20 if (file->f_flags & O_EXCL) mce_chrdev_open_exclu =3D 1; @@ -11464,7 +12084,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck= /mce.c linux-3.1.4/arch/x86/ker =20 spin_unlock(&mce_chrdev_state_lock); =20 -@@ -1456,7 +1459,7 @@ static int mce_chrdev_release(struct ino +@@ -1456,7 +1459,7 @@ static int mce_chrdev_release(struct inode *inode,= struct file *file) { spin_lock(&mce_chrdev_state_lock); =20 @@ -11482,24 +12102,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mche= ck/mce.c linux-3.1.4/arch/x86/ker atomic_set(&mce_executing, 0); atomic_set(&mce_callin, 0); atomic_set(&global_nwo, 0); -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck/mce-inject.c linux-3.1= .4/arch/x86/kernel/cpu/mcheck/mce-inject.c ---- linux-3.1.4/arch/x86/kernel/cpu/mcheck/mce-inject.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/mcheck/mce-inject.c 2011-11-16 18:39= :07.000000000 -0500 -@@ -215,7 +215,9 @@ static int inject_init(void) - if (!alloc_cpumask_var(&mce_inject_cpumask, GFP_KERNEL)) - return -ENOMEM; - printk(KERN_INFO "Machine check injector initialized\n"); -- mce_chrdev_ops.write =3D mce_write; -+ pax_open_kernel(); -+ *(void **)&mce_chrdev_ops.write =3D mce_write; -+ pax_close_kernel(); - register_die_notifier(&mce_raise_nb); - return 0; - } -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck/p5.c linux-3.1.4/arch/= x86/kernel/cpu/mcheck/p5.c ---- linux-3.1.4/arch/x86/kernel/cpu/mcheck/p5.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/mcheck/p5.c 2011-12-02 17:38:47.0000= 00000 -0500 -@@ -50,7 +50,9 @@ void intel_p5_mcheck_init(struct cpuinfo +diff --git a/arch/x86/kernel/cpu/mcheck/p5.c b/arch/x86/kernel/cpu/mchec= k/p5.c +index 5c0e653..1e82c7c 100644 +--- a/arch/x86/kernel/cpu/mcheck/p5.c ++++ b/arch/x86/kernel/cpu/mcheck/p5.c +@@ -50,7 +50,9 @@ void intel_p5_mcheck_init(struct cpuinfo_x86 *c) if (!cpu_has(c, X86_FEATURE_MCE)) return; =20 @@ -11509,10 +12116,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mche= ck/p5.c linux-3.1.4/arch/x86/kern /* Make sure the vector pointer is visible before we enable MCEs: */ wmb(); =20 -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mcheck/winchip.c linux-3.1.4/= arch/x86/kernel/cpu/mcheck/winchip.c ---- linux-3.1.4/arch/x86/kernel/cpu/mcheck/winchip.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/mcheck/winchip.c 2011-12-02 17:38:47= .000000000 -0500 -@@ -24,7 +24,9 @@ void winchip_mcheck_init(struct cpuinfo_ +diff --git a/arch/x86/kernel/cpu/mcheck/winchip.c b/arch/x86/kernel/cpu/= mcheck/winchip.c +index 54060f5..e6ba93d 100644 +--- a/arch/x86/kernel/cpu/mcheck/winchip.c ++++ b/arch/x86/kernel/cpu/mcheck/winchip.c +@@ -24,7 +24,9 @@ void winchip_mcheck_init(struct cpuinfo_x86 *c) { u32 lo, hi; =20 @@ -11522,9 +12130,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mchec= k/winchip.c linux-3.1.4/arch/x86 /* Make sure the vector pointer is visible before we enable MCEs: */ wmb(); =20 -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mtrr/main.c linux-3.1.4/arch/= x86/kernel/cpu/mtrr/main.c ---- linux-3.1.4/arch/x86/kernel/cpu/mtrr/main.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/mtrr/main.c 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/kernel/cpu/mtrr/main.c b/arch/x86/kernel/cpu/mtrr/= main.c +index 6b96110..0da73eb 100644 +--- a/arch/x86/kernel/cpu/mtrr/main.c ++++ b/arch/x86/kernel/cpu/mtrr/main.c @@ -62,7 +62,7 @@ static DEFINE_MUTEX(mtrr_mutex); u64 size_or_mask, size_and_mask; static bool mtrr_aps_delayed_init; @@ -11534,9 +12143,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mtrr/= main.c linux-3.1.4/arch/x86/kern =20 const struct mtrr_ops *mtrr_if; =20 -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mtrr/mtrr.h linux-3.1.4/arch/= x86/kernel/cpu/mtrr/mtrr.h ---- linux-3.1.4/arch/x86/kernel/cpu/mtrr/mtrr.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/mtrr/mtrr.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/kernel/cpu/mtrr/mtrr.h b/arch/x86/kernel/cpu/mtrr/= mtrr.h +index df5e41f..816c719 100644 +--- a/arch/x86/kernel/cpu/mtrr/mtrr.h ++++ b/arch/x86/kernel/cpu/mtrr/mtrr.h @@ -25,7 +25,7 @@ struct mtrr_ops { int (*validate_add_page)(unsigned long base, unsigned long size, unsigned int type); @@ -11546,10 +12156,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/mtrr= /mtrr.h linux-3.1.4/arch/x86/kern =20 extern int generic_get_free_region(unsigned long base, unsigned long si= ze, int replace_reg); -diff -urNp linux-3.1.4/arch/x86/kernel/cpu/perf_event.c linux-3.1.4/arch= /x86/kernel/cpu/perf_event.c ---- linux-3.1.4/arch/x86/kernel/cpu/perf_event.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/cpu/perf_event.c 2011-11-16 18:40:08.000= 000000 -0500 -@@ -795,6 +795,8 @@ static int x86_schedule_events(struct cp +diff --git a/arch/x86/kernel/cpu/perf_event.c b/arch/x86/kernel/cpu/perf= _event.c +index cfa62ec..9250dd7 100644 +--- a/arch/x86/kernel/cpu/perf_event.c ++++ b/arch/x86/kernel/cpu/perf_event.c +@@ -795,6 +795,8 @@ static int x86_schedule_events(struct cpu_hw_events = *cpuc, int n, int *assign) int i, j, w, wmax, num =3D 0; struct hw_perf_event *hwc; =20 @@ -11558,7 +12169,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/perf_e= vent.c linux-3.1.4/arch/x86/ker bitmap_zero(used_mask, X86_PMC_IDX_MAX); =20 for (i =3D 0; i < n; i++) { -@@ -1919,7 +1921,7 @@ perf_callchain_user(struct perf_callchai +@@ -1919,7 +1921,7 @@ perf_callchain_user(struct perf_callchain_entry *e= ntry, struct pt_regs *regs) break; =20 perf_callchain_store(entry, frame.return_address); @@ -11567,10 +12178,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/cpu/perf= _event.c linux-3.1.4/arch/x86/ker } } =20 -diff -urNp linux-3.1.4/arch/x86/kernel/crash.c linux-3.1.4/arch/x86/kern= el/crash.c ---- linux-3.1.4/arch/x86/kernel/crash.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/kernel/crash.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -42,7 +42,7 @@ static void kdump_nmi_callback(int cpu,=20 +diff --git a/arch/x86/kernel/crash.c b/arch/x86/kernel/crash.c +index 764c7c2..c5d9c7b 100644 +--- a/arch/x86/kernel/crash.c ++++ b/arch/x86/kernel/crash.c +@@ -42,7 +42,7 @@ static void kdump_nmi_callback(int cpu, struct die_arg= s *args) regs =3D args->regs; =20 #ifdef CONFIG_X86_32 @@ -11579,9 +12191,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/crash.c l= inux-3.1.4/arch/x86/kernel/crash crash_fixup_ss_esp(&fixed_regs, regs); regs =3D &fixed_regs; } -diff -urNp linux-3.1.4/arch/x86/kernel/doublefault_32.c linux-3.1.4/arch= /x86/kernel/doublefault_32.c ---- linux-3.1.4/arch/x86/kernel/doublefault_32.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/doublefault_32.c 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/arch/x86/kernel/doublefault_32.c b/arch/x86/kernel/doublefa= ult_32.c +index 37250fe..bf2ec74 100644 +--- a/arch/x86/kernel/doublefault_32.c ++++ b/arch/x86/kernel/doublefault_32.c @@ -11,7 +11,7 @@ =20 #define DOUBLEFAULT_STACKSIZE (1024) @@ -11600,7 +12213,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/doublefaul= t_32.c linux-3.1.4/arch/x86/ker =20 printk(KERN_EMERG "PANIC: double fault, gdt at %08lx [%d bytes]\n", gd= t, gdt_desc.size); =20 -@@ -58,10 +58,10 @@ struct tss_struct doublefault_tss __cach +@@ -58,10 +58,10 @@ struct tss_struct doublefault_tss __cacheline_aligne= d =3D { /* 0x2 bit is always set */ .flags =3D X86_EFLAGS_SF | 0x2, .sp =3D STACK_START, @@ -11613,10 +12226,158 @@ diff -urNp linux-3.1.4/arch/x86/kernel/doublef= ault_32.c linux-3.1.4/arch/x86/ker .fs =3D __KERNEL_PERCPU, =20 .__cr3 =3D __pa_nodebug(swapper_pg_dir), -diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_32.c linux-3.1.4/arch/x= 86/kernel/dumpstack_32.c ---- linux-3.1.4/arch/x86/kernel/dumpstack_32.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/kernel/dumpstack_32.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -38,15 +38,13 @@ void dump_trace(struct task_struct *task +diff --git a/arch/x86/kernel/dumpstack.c b/arch/x86/kernel/dumpstack.c +index 1aae78f..aab3a3d 100644 +--- a/arch/x86/kernel/dumpstack.c ++++ b/arch/x86/kernel/dumpstack.c +@@ -2,6 +2,9 @@ + * Copyright (C) 1991, 1992 Linus Torvalds + * Copyright (C) 2000, 2001, 2002 Andi Kleen, SuSE Labs + */ ++#ifdef CONFIG_GRKERNSEC_HIDESYM ++#define __INCLUDED_BY_HIDESYM 1 ++#endif + #include + #include + #include +@@ -35,9 +38,8 @@ void printk_address(unsigned long address, int reliabl= e) + static void + print_ftrace_graph_addr(unsigned long addr, void *data, + const struct stacktrace_ops *ops, +- struct thread_info *tinfo, int *graph) ++ struct task_struct *task, int *graph) + { +- struct task_struct *task =3D tinfo->task; + unsigned long ret_addr; + int index =3D task->curr_ret_stack; +=20 +@@ -58,7 +60,7 @@ print_ftrace_graph_addr(unsigned long addr, void *data= , + static inline void + print_ftrace_graph_addr(unsigned long addr, void *data, + const struct stacktrace_ops *ops, +- struct thread_info *tinfo, int *graph) ++ struct task_struct *task, int *graph) + { } + #endif +=20 +@@ -69,10 +71,8 @@ print_ftrace_graph_addr(unsigned long addr, void *dat= a, + * severe exception (double fault, nmi, stack fault, debug, mce) hardwa= re stack + */ +=20 +-static inline int valid_stack_ptr(struct thread_info *tinfo, +- void *p, unsigned int size, void *end) ++static inline int valid_stack_ptr(void *t, void *p, unsigned int size, = void *end) + { +- void *t =3D tinfo; + if (end) { + if (p < end && p >=3D (end-THREAD_SIZE)) + return 1; +@@ -83,14 +83,14 @@ static inline int valid_stack_ptr(struct thread_info= *tinfo, + } +=20 + unsigned long +-print_context_stack(struct thread_info *tinfo, ++print_context_stack(struct task_struct *task, void *stack_start, + unsigned long *stack, unsigned long bp, + const struct stacktrace_ops *ops, void *data, + unsigned long *end, int *graph) + { + struct stack_frame *frame =3D (struct stack_frame *)bp; +=20 +- while (valid_stack_ptr(tinfo, stack, sizeof(*stack), end)) { ++ while (valid_stack_ptr(stack_start, stack, sizeof(*stack), end)) { + unsigned long addr; +=20 + addr =3D *stack; +@@ -102,7 +102,7 @@ print_context_stack(struct thread_info *tinfo, + } else { + ops->address(data, addr, 0); + } +- print_ftrace_graph_addr(addr, data, ops, tinfo, graph); ++ print_ftrace_graph_addr(addr, data, ops, task, graph); + } + stack++; + } +@@ -111,7 +111,7 @@ print_context_stack(struct thread_info *tinfo, + EXPORT_SYMBOL_GPL(print_context_stack); +=20 + unsigned long +-print_context_stack_bp(struct thread_info *tinfo, ++print_context_stack_bp(struct task_struct *task, void *stack_start, + unsigned long *stack, unsigned long bp, + const struct stacktrace_ops *ops, void *data, + unsigned long *end, int *graph) +@@ -119,7 +119,7 @@ print_context_stack_bp(struct thread_info *tinfo, + struct stack_frame *frame =3D (struct stack_frame *)bp; + unsigned long *ret_addr =3D &frame->return_address; +=20 +- while (valid_stack_ptr(tinfo, ret_addr, sizeof(*ret_addr), end)) { ++ while (valid_stack_ptr(stack_start, ret_addr, sizeof(*ret_addr), end))= { + unsigned long addr =3D *ret_addr; +=20 + if (!__kernel_text_address(addr)) +@@ -128,7 +128,7 @@ print_context_stack_bp(struct thread_info *tinfo, + ops->address(data, addr, 1); + frame =3D frame->next_frame; + ret_addr =3D &frame->return_address; +- print_ftrace_graph_addr(addr, data, ops, tinfo, graph); ++ print_ftrace_graph_addr(addr, data, ops, task, graph); + } +=20 + return (unsigned long)frame; +@@ -186,7 +186,7 @@ void dump_stack(void) +=20 + bp =3D stack_frame(current, NULL); + printk("Pid: %d, comm: %.20s %s %s %.*s\n", +- current->pid, current->comm, print_tainted(), ++ task_pid_nr(current), current->comm, print_tainted(), + init_utsname()->release, + (int)strcspn(init_utsname()->version, " "), + init_utsname()->version); +@@ -222,6 +222,8 @@ unsigned __kprobes long oops_begin(void) + } + EXPORT_SYMBOL_GPL(oops_begin); +=20 ++extern void gr_handle_kernel_exploit(void); ++ + void __kprobes oops_end(unsigned long flags, struct pt_regs *regs, int = signr) + { + if (regs && kexec_should_crash(current)) +@@ -243,7 +245,10 @@ void __kprobes oops_end(unsigned long flags, struct= pt_regs *regs, int signr) + panic("Fatal exception in interrupt"); + if (panic_on_oops) + panic("Fatal exception"); +- do_exit(signr); ++ ++ gr_handle_kernel_exploit(); ++ ++ do_group_exit(signr); + } +=20 + int __kprobes __die(const char *str, struct pt_regs *regs, long err) +@@ -269,7 +274,7 @@ int __kprobes __die(const char *str, struct pt_regs = *regs, long err) +=20 + show_registers(regs); + #ifdef CONFIG_X86_32 +- if (user_mode_vm(regs)) { ++ if (user_mode(regs)) { + sp =3D regs->sp; + ss =3D regs->ss & 0xffff; + } else { +@@ -297,7 +302,7 @@ void die(const char *str, struct pt_regs *regs, long= err) + unsigned long flags =3D oops_begin(); + int sig =3D SIGSEGV; +=20 +- if (!user_mode_vm(regs)) ++ if (!user_mode(regs)) + report_bug(regs->ip, regs); +=20 + if (__die(str, regs, err)) +diff --git a/arch/x86/kernel/dumpstack_32.c b/arch/x86/kernel/dumpstack_= 32.c +index 3b97a80..667ce7a 100644 +--- a/arch/x86/kernel/dumpstack_32.c ++++ b/arch/x86/kernel/dumpstack_32.c +@@ -38,15 +38,13 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, bp =3D stack_frame(task, regs); =20 for (;;) { @@ -11636,7 +12397,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_= 32.c linux-3.1.4/arch/x86/kerne if (ops->stack(data, "IRQ") < 0) break; touch_nmi_watchdog(); -@@ -96,21 +94,22 @@ void show_registers(struct pt_regs *regs +@@ -96,21 +94,22 @@ void show_registers(struct pt_regs *regs) * When in-kernel, we also print out the stack and code at the * time of the fault.. */ @@ -11662,7 +12423,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_= 32.c linux-3.1.4/arch/x86/kerne code_len =3D code_len - code_prologue + 1; } for (i =3D 0; i < code_len; i++, ip++) { -@@ -119,7 +118,7 @@ void show_registers(struct pt_regs *regs +@@ -119,7 +118,7 @@ void show_registers(struct pt_regs *regs) printk(" Bad EIP value."); break; } @@ -11695,10 +12456,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpstac= k_32.c linux-3.1.4/arch/x86/kerne +} +EXPORT_SYMBOL(pax_check_alloca); +#endif -diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_64.c linux-3.1.4/arch/x= 86/kernel/dumpstack_64.c ---- linux-3.1.4/arch/x86/kernel/dumpstack_64.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/kernel/dumpstack_64.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -119,9 +119,9 @@ void dump_trace(struct task_struct *task +diff --git a/arch/x86/kernel/dumpstack_64.c b/arch/x86/kernel/dumpstack_= 64.c +index 19853ad..508ca79 100644 +--- a/arch/x86/kernel/dumpstack_64.c ++++ b/arch/x86/kernel/dumpstack_64.c +@@ -119,9 +119,9 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, unsigned long *irq_stack_end =3D (unsigned long *)per_cpu(irq_stack_ptr, cpu); unsigned used =3D 0; @@ -11709,7 +12471,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_= 64.c linux-3.1.4/arch/x86/kerne =20 if (!task) task =3D current; -@@ -142,10 +142,10 @@ void dump_trace(struct task_struct *task +@@ -142,10 +142,10 @@ void dump_trace(struct task_struct *task, struct p= t_regs *regs, * current stack address. If the stacks consist of nested * exceptions */ @@ -11721,7 +12483,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_= 64.c linux-3.1.4/arch/x86/kerne estack_end =3D in_exception_stack(cpu, (unsigned long)stack, &used, &id); =20 -@@ -153,7 +153,7 @@ void dump_trace(struct task_struct *task +@@ -153,7 +153,7 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, if (ops->stack(data, id) < 0) break; =20 @@ -11730,7 +12492,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_= 64.c linux-3.1.4/arch/x86/kerne data, estack_end, &graph); ops->stack(data, ""); /* -@@ -172,7 +172,7 @@ void dump_trace(struct task_struct *task +@@ -172,7 +172,7 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, if (in_irq_stack(stack, irq_stack, irq_stack_end)) { if (ops->stack(data, "IRQ") < 0) break; @@ -11739,7 +12501,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack_= 64.c linux-3.1.4/arch/x86/kerne ops, data, irq_stack_end, &graph); /* * We link to the next stack (which would be -@@ -191,7 +191,8 @@ void dump_trace(struct task_struct *task +@@ -191,7 +191,8 @@ void dump_trace(struct task_struct *task, struct pt_= regs *regs, /* * This handles the process stack: */ @@ -11800,155 +12562,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/dumpsta= ck_64.c linux-3.1.4/arch/x86/kerne +} +EXPORT_SYMBOL(pax_check_alloca); +#endif -diff -urNp linux-3.1.4/arch/x86/kernel/dumpstack.c linux-3.1.4/arch/x86/= kernel/dumpstack.c ---- linux-3.1.4/arch/x86/kernel/dumpstack.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/kernel/dumpstack.c 2011-11-16 18:40:08.00000000= 0 -0500 -@@ -2,6 +2,9 @@ - * Copyright (C) 1991, 1992 Linus Torvalds - * Copyright (C) 2000, 2001, 2002 Andi Kleen, SuSE Labs - */ -+#ifdef CONFIG_GRKERNSEC_HIDESYM -+#define __INCLUDED_BY_HIDESYM 1 -+#endif - #include - #include - #include -@@ -35,9 +38,8 @@ void printk_address(unsigned long addres - static void - print_ftrace_graph_addr(unsigned long addr, void *data, - const struct stacktrace_ops *ops, -- struct thread_info *tinfo, int *graph) -+ struct task_struct *task, int *graph) - { -- struct task_struct *task =3D tinfo->task; - unsigned long ret_addr; - int index =3D task->curr_ret_stack; -=20 -@@ -58,7 +60,7 @@ print_ftrace_graph_addr(unsigned long ad - static inline void - print_ftrace_graph_addr(unsigned long addr, void *data, - const struct stacktrace_ops *ops, -- struct thread_info *tinfo, int *graph) -+ struct task_struct *task, int *graph) - { } - #endif -=20 -@@ -69,10 +71,8 @@ print_ftrace_graph_addr(unsigned long ad - * severe exception (double fault, nmi, stack fault, debug, mce) hardwa= re stack - */ -=20 --static inline int valid_stack_ptr(struct thread_info *tinfo, -- void *p, unsigned int size, void *end) -+static inline int valid_stack_ptr(void *t, void *p, unsigned int size, = void *end) - { -- void *t =3D tinfo; - if (end) { - if (p < end && p >=3D (end-THREAD_SIZE)) - return 1; -@@ -83,14 +83,14 @@ static inline int valid_stack_ptr(struct - } -=20 - unsigned long --print_context_stack(struct thread_info *tinfo, -+print_context_stack(struct task_struct *task, void *stack_start, - unsigned long *stack, unsigned long bp, - const struct stacktrace_ops *ops, void *data, - unsigned long *end, int *graph) - { - struct stack_frame *frame =3D (struct stack_frame *)bp; -=20 -- while (valid_stack_ptr(tinfo, stack, sizeof(*stack), end)) { -+ while (valid_stack_ptr(stack_start, stack, sizeof(*stack), end)) { - unsigned long addr; -=20 - addr =3D *stack; -@@ -102,7 +102,7 @@ print_context_stack(struct thread_info * - } else { - ops->address(data, addr, 0); - } -- print_ftrace_graph_addr(addr, data, ops, tinfo, graph); -+ print_ftrace_graph_addr(addr, data, ops, task, graph); - } - stack++; - } -@@ -111,7 +111,7 @@ print_context_stack(struct thread_info * - EXPORT_SYMBOL_GPL(print_context_stack); -=20 - unsigned long --print_context_stack_bp(struct thread_info *tinfo, -+print_context_stack_bp(struct task_struct *task, void *stack_start, - unsigned long *stack, unsigned long bp, - const struct stacktrace_ops *ops, void *data, - unsigned long *end, int *graph) -@@ -119,7 +119,7 @@ print_context_stack_bp(struct thread_inf - struct stack_frame *frame =3D (struct stack_frame *)bp; - unsigned long *ret_addr =3D &frame->return_address; -=20 -- while (valid_stack_ptr(tinfo, ret_addr, sizeof(*ret_addr), end)) { -+ while (valid_stack_ptr(stack_start, ret_addr, sizeof(*ret_addr), end))= { - unsigned long addr =3D *ret_addr; -=20 - if (!__kernel_text_address(addr)) -@@ -128,7 +128,7 @@ print_context_stack_bp(struct thread_inf - ops->address(data, addr, 1); - frame =3D frame->next_frame; - ret_addr =3D &frame->return_address; -- print_ftrace_graph_addr(addr, data, ops, tinfo, graph); -+ print_ftrace_graph_addr(addr, data, ops, task, graph); - } -=20 - return (unsigned long)frame; -@@ -186,7 +186,7 @@ void dump_stack(void) -=20 - bp =3D stack_frame(current, NULL); - printk("Pid: %d, comm: %.20s %s %s %.*s\n", -- current->pid, current->comm, print_tainted(), -+ task_pid_nr(current), current->comm, print_tainted(), - init_utsname()->release, - (int)strcspn(init_utsname()->version, " "), - init_utsname()->version); -@@ -222,6 +222,8 @@ unsigned __kprobes long oops_begin(void) - } - EXPORT_SYMBOL_GPL(oops_begin); -=20 -+extern void gr_handle_kernel_exploit(void); -+ - void __kprobes oops_end(unsigned long flags, struct pt_regs *regs, int = signr) - { - if (regs && kexec_should_crash(current)) -@@ -243,7 +245,10 @@ void __kprobes oops_end(unsigned long fl - panic("Fatal exception in interrupt"); - if (panic_on_oops) - panic("Fatal exception"); -- do_exit(signr); -+ -+ gr_handle_kernel_exploit(); -+ -+ do_group_exit(signr); - } -=20 - int __kprobes __die(const char *str, struct pt_regs *regs, long err) -@@ -269,7 +274,7 @@ int __kprobes __die(const char *str, str -=20 - show_registers(regs); - #ifdef CONFIG_X86_32 -- if (user_mode_vm(regs)) { -+ if (user_mode(regs)) { - sp =3D regs->sp; - ss =3D regs->ss & 0xffff; - } else { -@@ -297,7 +302,7 @@ void die(const char *str, struct pt_regs - unsigned long flags =3D oops_begin(); - int sig =3D SIGSEGV; -=20 -- if (!user_mode_vm(regs)) -+ if (!user_mode(regs)) - report_bug(regs->ip, regs); -=20 - if (__die(str, regs, err)) -diff -urNp linux-3.1.4/arch/x86/kernel/early_printk.c linux-3.1.4/arch/x= 86/kernel/early_printk.c ---- linux-3.1.4/arch/x86/kernel/early_printk.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/kernel/early_printk.c 2011-11-16 18:40:08.00000= 0000 -0500 +diff --git a/arch/x86/kernel/early_printk.c b/arch/x86/kernel/early_prin= tk.c +index cd28a35..2601699 100644 +--- a/arch/x86/kernel/early_printk.c ++++ b/arch/x86/kernel/early_printk.c @@ -7,6 +7,7 @@ #include #include @@ -11957,7 +12574,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/early_prin= tk.c linux-3.1.4/arch/x86/kerne #include #include #include -@@ -179,6 +180,8 @@ asmlinkage void early_printk(const char=20 +@@ -179,6 +180,8 @@ asmlinkage void early_printk(const char *fmt, ...) int n; va_list ap; =20 @@ -11966,9 +12583,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/early_pri= ntk.c linux-3.1.4/arch/x86/kerne va_start(ap, fmt); n =3D vscnprintf(buf, sizeof(buf), fmt, ap); early_console->write(early_console, buf, n); -diff -urNp linux-3.1.4/arch/x86/kernel/entry_32.S linux-3.1.4/arch/x86/k= ernel/entry_32.S ---- linux-3.1.4/arch/x86/kernel/entry_32.S 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/kernel/entry_32.S 2011-11-16 18:40:08.000000000= -0500 +diff --git a/arch/x86/kernel/entry_32.S b/arch/x86/kernel/entry_32.S +index f3f6f53..0841b66 100644 +--- a/arch/x86/kernel/entry_32.S ++++ b/arch/x86/kernel/entry_32.S @@ -186,13 +186,146 @@ /*CFI_REL_OFFSET gs, PT_GS*/ .endm @@ -12619,7 +13237,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/entry_32.S= linux-3.1.4/arch/x86/kernel/en /* * End of kprobes section */ -@@ -1109,7 +1358,7 @@ BUILD_INTERRUPT3(xen_hvm_callback_vector +@@ -1109,7 +1358,7 @@ BUILD_INTERRUPT3(xen_hvm_callback_vector, XEN_HVM_= EVTCHN_CALLBACK, =20 ENTRY(mcount) ret @@ -12746,9 +13364,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/entry_32.= S linux-3.1.4/arch/x86/kernel/en #endif =20 /* -diff -urNp linux-3.1.4/arch/x86/kernel/entry_64.S linux-3.1.4/arch/x86/k= ernel/entry_64.S ---- linux-3.1.4/arch/x86/kernel/entry_64.S 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/kernel/entry_64.S 2011-12-02 17:40:13.000000000= -0500 +diff --git a/arch/x86/kernel/entry_64.S b/arch/x86/kernel/entry_64.S +index 6419bb0..4f4cf2b 100644 +--- a/arch/x86/kernel/entry_64.S ++++ b/arch/x86/kernel/entry_64.S @@ -55,6 +55,8 @@ #include #include @@ -13333,7 +13952,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/entry_64.S= linux-3.1.4/arch/x86/kernel/en je retint_kernel =20 /* Interrupt came from user space */ -@@ -842,12 +1150,16 @@ retint_swapgs: /* return to user-space=20 +@@ -842,12 +1150,16 @@ retint_swapgs: /* return to user-space */ * The iretq could re-enable interrupts: */ DISABLE_INTERRUPTS(CLBR_ANY) @@ -13554,7 +14173,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/entry_64.S= linux-3.1.4/arch/x86/kernel/en =20 #ifdef CONFIG_XEN zeroentry xen_hypervisor_callback xen_do_hypervisor_callback -@@ -1244,7 +1616,7 @@ ENTRY(xen_do_hypervisor_callback) # do +@@ -1244,7 +1616,7 @@ ENTRY(xen_do_hypervisor_callback) # do_hyperviso= r_callback(struct *pt_regs) decl PER_CPU_VAR(irq_count) jmp error_exit CFI_ENDPROC @@ -13711,10 +14330,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/entry_64= .S linux-3.1.4/arch/x86/kernel/en =20 /* * End of kprobes section -diff -urNp linux-3.1.4/arch/x86/kernel/ftrace.c linux-3.1.4/arch/x86/ker= nel/ftrace.c ---- linux-3.1.4/arch/x86/kernel/ftrace.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/ftrace.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -126,7 +126,7 @@ static void *mod_code_ip; /* holds the=20 +diff --git a/arch/x86/kernel/ftrace.c b/arch/x86/kernel/ftrace.c +index c9a281f..ce2f317 100644 +--- a/arch/x86/kernel/ftrace.c ++++ b/arch/x86/kernel/ftrace.c +@@ -126,7 +126,7 @@ static void *mod_code_ip; /* holds the IP to write = to */ static const void *mod_code_newcode; /* holds the text to write to the = IP */ =20 static unsigned nmi_wait_count; @@ -13723,7 +14343,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ftrace.c l= inux-3.1.4/arch/x86/kernel/ftra =20 int ftrace_arch_read_dyn_info(char *buf, int size) { -@@ -134,7 +134,7 @@ int ftrace_arch_read_dyn_info(char *buf, +@@ -134,7 +134,7 @@ int ftrace_arch_read_dyn_info(char *buf, int size) =20 r =3D snprintf(buf, size, "%u %u", nmi_wait_count, @@ -13744,7 +14364,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ftrace.c l= inux-3.1.4/arch/x86/kernel/ftra } /* Must have previous changes seen before executions */ smp_mb(); -@@ -271,6 +273,8 @@ ftrace_modify_code(unsigned long ip, uns +@@ -271,6 +273,8 @@ ftrace_modify_code(unsigned long ip, unsigned const = char *old_code, { unsigned char replaced[MCOUNT_INSN_SIZE]; =20 @@ -13753,7 +14373,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ftrace.c l= inux-3.1.4/arch/x86/kernel/ftra /* * Note: Due to modules and __init, code can * disappear and change, we need to protect against faulting -@@ -327,7 +331,7 @@ int ftrace_update_ftrace_func(ftrace_fun +@@ -327,7 +331,7 @@ int ftrace_update_ftrace_func(ftrace_func_t func) unsigned char old[MCOUNT_INSN_SIZE], *new; int ret; =20 @@ -13762,7 +14382,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ftrace.c l= inux-3.1.4/arch/x86/kernel/ftra new =3D ftrace_call_replace(ip, (unsigned long)func); ret =3D ftrace_modify_code(ip, old, new); =20 -@@ -353,6 +357,8 @@ static int ftrace_mod_jmp(unsigned long=20 +@@ -353,6 +357,8 @@ static int ftrace_mod_jmp(unsigned long ip, { unsigned char code[MCOUNT_INSN_SIZE]; =20 @@ -13771,9 +14391,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ftrace.c = linux-3.1.4/arch/x86/kernel/ftra if (probe_kernel_read(code, (void *)ip, MCOUNT_INSN_SIZE)) return -EFAULT; =20 -diff -urNp linux-3.1.4/arch/x86/kernel/head32.c linux-3.1.4/arch/x86/ker= nel/head32.c ---- linux-3.1.4/arch/x86/kernel/head32.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/head32.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/arch/x86/kernel/head32.c b/arch/x86/kernel/head32.c +index 3bb0850..55a56f4 100644 +--- a/arch/x86/kernel/head32.c ++++ b/arch/x86/kernel/head32.c @@ -19,6 +19,7 @@ #include #include @@ -13791,9 +14412,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head32.c = linux-3.1.4/arch/x86/kernel/head =20 #ifdef CONFIG_BLK_DEV_INITRD /* Reserve INITRD */ -diff -urNp linux-3.1.4/arch/x86/kernel/head_32.S linux-3.1.4/arch/x86/ke= rnel/head_32.S ---- linux-3.1.4/arch/x86/kernel/head_32.S 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/head_32.S 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/arch/x86/kernel/head_32.S b/arch/x86/kernel/head_32.S +index ce0be7c..c41476e 100644 +--- a/arch/x86/kernel/head_32.S ++++ b/arch/x86/kernel/head_32.S @@ -25,6 +25,12 @@ /* Physical address */ #define pa(X) ((X) - __PAGE_OFFSET) @@ -13820,7 +14442,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head_32.S = linux-3.1.4/arch/x86/kernel/hea =20 /* Number of possible pages in the lowmem region */ LOWMEM_PAGES =3D (((1<<32) - __PAGE_OFFSET) >> PAGE_SHIFT) -@@ -77,6 +79,12 @@ INIT_MAP_SIZE =3D PAGE_TABLE_SIZE(KERNEL_P +@@ -77,6 +79,12 @@ INIT_MAP_SIZE =3D PAGE_TABLE_SIZE(KERNEL_PAGES) * PAG= E_SIZE RESERVE_BRK(pagetables, INIT_MAP_SIZE) =20 /* @@ -14130,9 +14752,9 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head_32.S = linux-3.1.4/arch/x86/kernel/hea ENTRY(stack_start) - .long init_thread_union+THREAD_SIZE + .long init_thread_union+THREAD_SIZE-8 -+ -+ready: .byte 0 =20 ++ready: .byte 0 ++ +.section .rodata,"a",@progbits early_recursion_flag: .long 0 @@ -14228,9 +14850,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head_32.S= linux-3.1.4/arch/x86/kernel/hea + /* Be sure this is zeroed to avoid false validations in Xen */ + .fill PAGE_SIZE_asm - GDT_SIZE,1,0 + .endr -diff -urNp linux-3.1.4/arch/x86/kernel/head_64.S linux-3.1.4/arch/x86/ke= rnel/head_64.S ---- linux-3.1.4/arch/x86/kernel/head_64.S 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/head_64.S 2011-12-02 17:38:47.000000000 = -0500 +diff --git a/arch/x86/kernel/head_64.S b/arch/x86/kernel/head_64.S +index e11e394..3d66dfe 100644 +--- a/arch/x86/kernel/head_64.S ++++ b/arch/x86/kernel/head_64.S @@ -19,6 +19,8 @@ #include #include @@ -14240,7 +14863,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head_64.S = linux-3.1.4/arch/x86/kernel/hea =20 #ifdef CONFIG_PARAVIRT #include -@@ -38,6 +40,10 @@ L4_PAGE_OFFSET =3D pgd_index(__PAGE_OFFSET +@@ -38,6 +40,10 @@ L4_PAGE_OFFSET =3D pgd_index(__PAGE_OFFSET) L3_PAGE_OFFSET =3D pud_index(__PAGE_OFFSET) L4_START_KERNEL =3D pgd_index(__START_KERNEL_map) L3_START_KERNEL =3D pud_index(__START_KERNEL_map) @@ -14266,12 +14889,9 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head_64.S= linux-3.1.4/arch/x86/kernel/hea =20 - addq %rbp, level3_kernel_pgt + (510*8)(%rip) - addq %rbp, level3_kernel_pgt + (511*8)(%rip) -+ addq %rbp, level3_vmemmap_pgt + (L3_VMEMMAP_START*8)(%rip) -=20 +- - addq %rbp, level2_fixmap_pgt + (506*8)(%rip) -+ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8)(%rip) -+ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8+8)(%rip) -=20 +- - /* Add an Identity mapping if I am above 1G */ - leaq _text(%rip), %rdi - andq $PMD_PAGE_MASK, %rdi @@ -14280,11 +14900,14 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head_64.= S linux-3.1.4/arch/x86/kernel/hea - shrq $PUD_SHIFT, %rax - andq $(PTRS_PER_PUD - 1), %rax - jz ident_complete -- ++ addq %rbp, level3_vmemmap_pgt + (L3_VMEMMAP_START*8)(%rip) +=20 - leaq (level2_spare_pgt - __START_KERNEL_map + _KERNPG_TABLE)(%rbp), %r= dx - leaq level3_ident_pgt(%rip), %rbx - movq %rdx, 0(%rbx, %rax, 8) -- ++ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8)(%rip) ++ addq %rbp, level3_kernel_pgt + (L3_START_KERNEL*8+8)(%rip) +=20 - movq %rdi, %rax - shrq $PMD_SHIFT, %rax - andq $(PTRS_PER_PMD - 1), %rax @@ -14511,9 +15134,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/head_64.S= linux-3.1.4/arch/x86/kernel/hea =20 __PAGE_ALIGNED_BSS .align PAGE_SIZE -diff -urNp linux-3.1.4/arch/x86/kernel/i386_ksyms_32.c linux-3.1.4/arch/= x86/kernel/i386_ksyms_32.c ---- linux-3.1.4/arch/x86/kernel/i386_ksyms_32.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/kernel/i386_ksyms_32.c 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/kernel/i386_ksyms_32.c b/arch/x86/kernel/i386_ksym= s_32.c +index 9c3bd4a..e1d9b35 100644 +--- a/arch/x86/kernel/i386_ksyms_32.c ++++ b/arch/x86/kernel/i386_ksyms_32.c @@ -20,8 +20,12 @@ extern void cmpxchg8b_emu(void); EXPORT_SYMBOL(cmpxchg8b_emu); #endif @@ -14535,9 +15159,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/i386_ksym= s_32.c linux-3.1.4/arch/x86/kern +#ifdef CONFIG_PAX_KERNEXEC +EXPORT_SYMBOL(__LOAD_PHYSICAL_ADDR); +#endif -diff -urNp linux-3.1.4/arch/x86/kernel/i8259.c linux-3.1.4/arch/x86/kern= el/i8259.c ---- linux-3.1.4/arch/x86/kernel/i8259.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/kernel/i8259.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/x86/kernel/i8259.c b/arch/x86/kernel/i8259.c +index 6104852..6114160 100644 +--- a/arch/x86/kernel/i8259.c ++++ b/arch/x86/kernel/i8259.c @@ -210,7 +210,7 @@ spurious_8259A_irq: "spurious 8259A interrupt: IRQ%d.\n", irq); spurious_irq_mask |=3D irqmask; @@ -14547,10 +15172,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/i8259.c = linux-3.1.4/arch/x86/kernel/i8259 /* * Theoretically we do not have to handle this IRQ, * but in Linux this does not cause problems and is -diff -urNp linux-3.1.4/arch/x86/kernel/init_task.c linux-3.1.4/arch/x86/= kernel/init_task.c ---- linux-3.1.4/arch/x86/kernel/init_task.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/kernel/init_task.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -20,8 +20,7 @@ static struct sighand_struct init_sighan +diff --git a/arch/x86/kernel/init_task.c b/arch/x86/kernel/init_task.c +index 43e9ccf..44ccf6f 100644 +--- a/arch/x86/kernel/init_task.c ++++ b/arch/x86/kernel/init_task.c +@@ -20,8 +20,7 @@ static struct sighand_struct init_sighand =3D INIT_SIG= HAND(init_sighand); * way process stacks are handled. This is done by having a special * "init_task" linker map entry.. */ @@ -14568,9 +15194,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/init_task= .c linux-3.1.4/arch/x86/kernel/i - +struct tss_struct init_tss[NR_CPUS] ____cacheline_internodealigned_in_s= mp =3D { [0 ... NR_CPUS-1] =3D INIT_TSS }; +EXPORT_SYMBOL(init_tss); -diff -urNp linux-3.1.4/arch/x86/kernel/ioport.c linux-3.1.4/arch/x86/ker= nel/ioport.c ---- linux-3.1.4/arch/x86/kernel/ioport.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/ioport.c 2011-11-16 18:40:08.000000000 -= 0500 +diff --git a/arch/x86/kernel/ioport.c b/arch/x86/kernel/ioport.c +index 8c96897..be66bfa 100644 +--- a/arch/x86/kernel/ioport.c ++++ b/arch/x86/kernel/ioport.c @@ -6,6 +6,7 @@ #include #include @@ -14579,7 +15206,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ioport.c l= inux-3.1.4/arch/x86/kernel/iopo #include #include #include -@@ -28,6 +29,12 @@ asmlinkage long sys_ioperm(unsigned long +@@ -28,6 +29,12 @@ asmlinkage long sys_ioperm(unsigned long from, unsign= ed long num, int turn_on) =20 if ((from + num <=3D from) || (from + num > IO_BITMAP_BITS)) return -EINVAL; @@ -14592,7 +15219,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ioport.c l= inux-3.1.4/arch/x86/kernel/iopo if (turn_on && !capable(CAP_SYS_RAWIO)) return -EPERM; =20 -@@ -54,7 +61,7 @@ asmlinkage long sys_ioperm(unsigned long +@@ -54,7 +61,7 @@ asmlinkage long sys_ioperm(unsigned long from, unsigne= d long num, int turn_on) * because the ->io_bitmap_max value must match the bitmap * contents: */ @@ -14601,7 +15228,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ioport.c l= inux-3.1.4/arch/x86/kernel/iopo =20 if (turn_on) bitmap_clear(t->io_bitmap_ptr, from, num); -@@ -102,6 +109,12 @@ long sys_iopl(unsigned int level, struct +@@ -102,6 +109,12 @@ long sys_iopl(unsigned int level, struct pt_regs *r= egs) return -EINVAL; /* Trying to gain more privileges? */ if (level > old) { @@ -14614,151 +15241,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ioport.= c linux-3.1.4/arch/x86/kernel/iopo if (!capable(CAP_SYS_RAWIO)) return -EPERM; } -diff -urNp linux-3.1.4/arch/x86/kernel/irq_32.c linux-3.1.4/arch/x86/ker= nel/irq_32.c ---- linux-3.1.4/arch/x86/kernel/irq_32.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/irq_32.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -36,7 +36,7 @@ static int check_stack_overflow(void) - __asm__ __volatile__("andl %%esp,%0" : - "=3Dr" (sp) : "0" (THREAD_SIZE - 1)); -=20 -- return sp < (sizeof(struct thread_info) + STACK_WARN); -+ return sp < STACK_WARN; - } -=20 - static void print_stack_overflow(void) -@@ -54,8 +54,8 @@ static inline void print_stack_overflow( - * per-CPU IRQ handling contexts (thread information and stack) - */ - union irq_ctx { -- struct thread_info tinfo; -- u32 stack[THREAD_SIZE/sizeof(u32)]; -+ unsigned long previous_esp; -+ u32 stack[THREAD_SIZE/sizeof(u32)]; - } __attribute__((aligned(THREAD_SIZE))); -=20 - static DEFINE_PER_CPU(union irq_ctx *, hardirq_ctx); -@@ -75,10 +75,9 @@ static void call_on_stack(void *func, vo - static inline int - execute_on_irq_stack(int overflow, struct irq_desc *desc, int irq) - { -- union irq_ctx *curctx, *irqctx; -+ union irq_ctx *irqctx; - u32 *isp, arg1, arg2; -=20 -- curctx =3D (union irq_ctx *) current_thread_info(); - irqctx =3D __this_cpu_read(hardirq_ctx); -=20 - /* -@@ -87,21 +86,16 @@ execute_on_irq_stack(int overflow, struc - * handler) we can't do that and just have to keep using the - * current stack (which is the irq stack already after all) - */ -- if (unlikely(curctx =3D=3D irqctx)) -+ if (unlikely((void *)current_stack_pointer - (void *)irqctx < THREAD_S= IZE)) - return 0; -=20 - /* build the stack frame on the IRQ stack */ -- isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx)); -- irqctx->tinfo.task =3D curctx->tinfo.task; -- irqctx->tinfo.previous_esp =3D current_stack_pointer; -+ isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx) - 8); -+ irqctx->previous_esp =3D current_stack_pointer; -=20 -- /* -- * Copy the softirq bits in preempt_count so that the -- * softirq checks work in the hardirq context. -- */ -- irqctx->tinfo.preempt_count =3D -- (irqctx->tinfo.preempt_count & ~SOFTIRQ_MASK) | -- (curctx->tinfo.preempt_count & SOFTIRQ_MASK); -+#ifdef CONFIG_PAX_MEMORY_UDEREF -+ __set_fs(MAKE_MM_SEG(0)); -+#endif -=20 - if (unlikely(overflow)) - call_on_stack(print_stack_overflow, isp); -@@ -113,6 +107,11 @@ execute_on_irq_stack(int overflow, struc - : "0" (irq), "1" (desc), "2" (isp), - "D" (desc->handle_irq) - : "memory", "cc", "ecx"); -+ -+#ifdef CONFIG_PAX_MEMORY_UDEREF -+ __set_fs(current_thread_info()->addr_limit); -+#endif -+ - return 1; - } -=20 -@@ -121,29 +120,11 @@ execute_on_irq_stack(int overflow, struc - */ - void __cpuinit irq_ctx_init(int cpu) - { -- union irq_ctx *irqctx; -- - if (per_cpu(hardirq_ctx, cpu)) - return; -=20 -- irqctx =3D page_address(alloc_pages_node(cpu_to_node(cpu), -- THREAD_FLAGS, -- THREAD_ORDER)); -- memset(&irqctx->tinfo, 0, sizeof(struct thread_info)); -- irqctx->tinfo.cpu =3D cpu; -- irqctx->tinfo.preempt_count =3D HARDIRQ_OFFSET; -- irqctx->tinfo.addr_limit =3D MAKE_MM_SEG(0); -- -- per_cpu(hardirq_ctx, cpu) =3D irqctx; -- -- irqctx =3D page_address(alloc_pages_node(cpu_to_node(cpu), -- THREAD_FLAGS, -- THREAD_ORDER)); -- memset(&irqctx->tinfo, 0, sizeof(struct thread_info)); -- irqctx->tinfo.cpu =3D cpu; -- irqctx->tinfo.addr_limit =3D MAKE_MM_SEG(0); -- -- per_cpu(softirq_ctx, cpu) =3D irqctx; -+ per_cpu(hardirq_ctx, cpu) =3D page_address(alloc_pages_node(cpu_to_nod= e(cpu), THREAD_FLAGS, THREAD_ORDER)); -+ per_cpu(softirq_ctx, cpu) =3D page_address(alloc_pages_node(cpu_to_nod= e(cpu), THREAD_FLAGS, THREAD_ORDER)); -=20 - printk(KERN_DEBUG "CPU %u irqstacks, hard=3D%p soft=3D%p\n", - cpu, per_cpu(hardirq_ctx, cpu), per_cpu(softirq_ctx, cpu)); -@@ -152,7 +133,6 @@ void __cpuinit irq_ctx_init(int cpu) - asmlinkage void do_softirq(void) - { - unsigned long flags; -- struct thread_info *curctx; - union irq_ctx *irqctx; - u32 *isp; -=20 -@@ -162,15 +142,22 @@ asmlinkage void do_softirq(void) - local_irq_save(flags); -=20 - if (local_softirq_pending()) { -- curctx =3D current_thread_info(); - irqctx =3D __this_cpu_read(softirq_ctx); -- irqctx->tinfo.task =3D curctx->task; -- irqctx->tinfo.previous_esp =3D current_stack_pointer; -+ irqctx->previous_esp =3D current_stack_pointer; -=20 - /* build the stack frame on the softirq stack */ -- isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx)); -+ isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx) - 8); -+ -+#ifdef CONFIG_PAX_MEMORY_UDEREF -+ __set_fs(MAKE_MM_SEG(0)); -+#endif -=20 - call_on_stack(__do_softirq, isp); -+ -+#ifdef CONFIG_PAX_MEMORY_UDEREF -+ __set_fs(current_thread_info()->addr_limit); -+#endif -+ - /* - * Shouldn't happen, we returned above if in_interrupt(): - */ -diff -urNp linux-3.1.4/arch/x86/kernel/irq.c linux-3.1.4/arch/x86/kernel= /irq.c ---- linux-3.1.4/arch/x86/kernel/irq.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/kernel/irq.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c +index 6c0802e..bea25ae 100644 +--- a/arch/x86/kernel/irq.c ++++ b/arch/x86/kernel/irq.c @@ -17,7 +17,7 @@ #include #include @@ -14768,7 +15254,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/irq.c linu= x-3.1.4/arch/x86/kernel/irq.c =20 /* Function pointer for generic interrupt vector handling */ void (*x86_platform_ipi_callback)(void) =3D NULL; -@@ -116,9 +116,9 @@ int arch_show_interrupts(struct seq_file +@@ -116,9 +116,9 @@ int arch_show_interrupts(struct seq_file *p, int pre= c) seq_printf(p, "%10u ", per_cpu(mce_poll_count, j)); seq_printf(p, " Machine check polls\n"); #endif @@ -14793,10 +15279,154 @@ diff -urNp linux-3.1.4/arch/x86/kernel/irq.c l= inux-3.1.4/arch/x86/kernel/irq.c #endif return sum; } -diff -urNp linux-3.1.4/arch/x86/kernel/kgdb.c linux-3.1.4/arch/x86/kerne= l/kgdb.c ---- linux-3.1.4/arch/x86/kernel/kgdb.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/kernel/kgdb.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -124,11 +124,11 @@ char *dbg_get_reg(int regno, void *mem,=20 +diff --git a/arch/x86/kernel/irq_32.c b/arch/x86/kernel/irq_32.c +index 7209070..cbcd71a 100644 +--- a/arch/x86/kernel/irq_32.c ++++ b/arch/x86/kernel/irq_32.c +@@ -36,7 +36,7 @@ static int check_stack_overflow(void) + __asm__ __volatile__("andl %%esp,%0" : + "=3Dr" (sp) : "0" (THREAD_SIZE - 1)); +=20 +- return sp < (sizeof(struct thread_info) + STACK_WARN); ++ return sp < STACK_WARN; + } +=20 + static void print_stack_overflow(void) +@@ -54,8 +54,8 @@ static inline void print_stack_overflow(void) { } + * per-CPU IRQ handling contexts (thread information and stack) + */ + union irq_ctx { +- struct thread_info tinfo; +- u32 stack[THREAD_SIZE/sizeof(u32)]; ++ unsigned long previous_esp; ++ u32 stack[THREAD_SIZE/sizeof(u32)]; + } __attribute__((aligned(THREAD_SIZE))); +=20 + static DEFINE_PER_CPU(union irq_ctx *, hardirq_ctx); +@@ -75,10 +75,9 @@ static void call_on_stack(void *func, void *stack) + static inline int + execute_on_irq_stack(int overflow, struct irq_desc *desc, int irq) + { +- union irq_ctx *curctx, *irqctx; ++ union irq_ctx *irqctx; + u32 *isp, arg1, arg2; +=20 +- curctx =3D (union irq_ctx *) current_thread_info(); + irqctx =3D __this_cpu_read(hardirq_ctx); +=20 + /* +@@ -87,21 +86,16 @@ execute_on_irq_stack(int overflow, struct irq_desc *= desc, int irq) + * handler) we can't do that and just have to keep using the + * current stack (which is the irq stack already after all) + */ +- if (unlikely(curctx =3D=3D irqctx)) ++ if (unlikely((void *)current_stack_pointer - (void *)irqctx < THREAD_S= IZE)) + return 0; +=20 + /* build the stack frame on the IRQ stack */ +- isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx)); +- irqctx->tinfo.task =3D curctx->tinfo.task; +- irqctx->tinfo.previous_esp =3D current_stack_pointer; ++ isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx) - 8); ++ irqctx->previous_esp =3D current_stack_pointer; +=20 +- /* +- * Copy the softirq bits in preempt_count so that the +- * softirq checks work in the hardirq context. +- */ +- irqctx->tinfo.preempt_count =3D +- (irqctx->tinfo.preempt_count & ~SOFTIRQ_MASK) | +- (curctx->tinfo.preempt_count & SOFTIRQ_MASK); ++#ifdef CONFIG_PAX_MEMORY_UDEREF ++ __set_fs(MAKE_MM_SEG(0)); ++#endif +=20 + if (unlikely(overflow)) + call_on_stack(print_stack_overflow, isp); +@@ -113,6 +107,11 @@ execute_on_irq_stack(int overflow, struct irq_desc = *desc, int irq) + : "0" (irq), "1" (desc), "2" (isp), + "D" (desc->handle_irq) + : "memory", "cc", "ecx"); ++ ++#ifdef CONFIG_PAX_MEMORY_UDEREF ++ __set_fs(current_thread_info()->addr_limit); ++#endif ++ + return 1; + } +=20 +@@ -121,29 +120,11 @@ execute_on_irq_stack(int overflow, struct irq_desc= *desc, int irq) + */ + void __cpuinit irq_ctx_init(int cpu) + { +- union irq_ctx *irqctx; +- + if (per_cpu(hardirq_ctx, cpu)) + return; +=20 +- irqctx =3D page_address(alloc_pages_node(cpu_to_node(cpu), +- THREAD_FLAGS, +- THREAD_ORDER)); +- memset(&irqctx->tinfo, 0, sizeof(struct thread_info)); +- irqctx->tinfo.cpu =3D cpu; +- irqctx->tinfo.preempt_count =3D HARDIRQ_OFFSET; +- irqctx->tinfo.addr_limit =3D MAKE_MM_SEG(0); +- +- per_cpu(hardirq_ctx, cpu) =3D irqctx; +- +- irqctx =3D page_address(alloc_pages_node(cpu_to_node(cpu), +- THREAD_FLAGS, +- THREAD_ORDER)); +- memset(&irqctx->tinfo, 0, sizeof(struct thread_info)); +- irqctx->tinfo.cpu =3D cpu; +- irqctx->tinfo.addr_limit =3D MAKE_MM_SEG(0); +- +- per_cpu(softirq_ctx, cpu) =3D irqctx; ++ per_cpu(hardirq_ctx, cpu) =3D page_address(alloc_pages_node(cpu_to_nod= e(cpu), THREAD_FLAGS, THREAD_ORDER)); ++ per_cpu(softirq_ctx, cpu) =3D page_address(alloc_pages_node(cpu_to_nod= e(cpu), THREAD_FLAGS, THREAD_ORDER)); +=20 + printk(KERN_DEBUG "CPU %u irqstacks, hard=3D%p soft=3D%p\n", + cpu, per_cpu(hardirq_ctx, cpu), per_cpu(softirq_ctx, cpu)); +@@ -152,7 +133,6 @@ void __cpuinit irq_ctx_init(int cpu) + asmlinkage void do_softirq(void) + { + unsigned long flags; +- struct thread_info *curctx; + union irq_ctx *irqctx; + u32 *isp; +=20 +@@ -162,15 +142,22 @@ asmlinkage void do_softirq(void) + local_irq_save(flags); +=20 + if (local_softirq_pending()) { +- curctx =3D current_thread_info(); + irqctx =3D __this_cpu_read(softirq_ctx); +- irqctx->tinfo.task =3D curctx->task; +- irqctx->tinfo.previous_esp =3D current_stack_pointer; ++ irqctx->previous_esp =3D current_stack_pointer; +=20 + /* build the stack frame on the softirq stack */ +- isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx)); ++ isp =3D (u32 *) ((char *)irqctx + sizeof(*irqctx) - 8); ++ ++#ifdef CONFIG_PAX_MEMORY_UDEREF ++ __set_fs(MAKE_MM_SEG(0)); ++#endif +=20 + call_on_stack(__do_softirq, isp); ++ ++#ifdef CONFIG_PAX_MEMORY_UDEREF ++ __set_fs(current_thread_info()->addr_limit); ++#endif ++ + /* + * Shouldn't happen, we returned above if in_interrupt(): + */ +diff --git a/arch/x86/kernel/kgdb.c b/arch/x86/kernel/kgdb.c +index 00354d4..187ae44 100644 +--- a/arch/x86/kernel/kgdb.c ++++ b/arch/x86/kernel/kgdb.c +@@ -124,11 +124,11 @@ char *dbg_get_reg(int regno, void *mem, struct pt_= regs *regs) #ifdef CONFIG_X86_32 switch (regno) { case GDB_SS: @@ -14810,7 +15440,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kgdb.c lin= ux-3.1.4/arch/x86/kernel/kgdb.c *(unsigned long *)mem =3D kernel_stack_pointer(regs); break; case GDB_GS: -@@ -473,12 +473,12 @@ int kgdb_arch_handle_exception(int e_vec +@@ -473,12 +473,12 @@ int kgdb_arch_handle_exception(int e_vector, int s= igno, int err_code, case 'k': /* clear the trace bit */ linux_regs->flags &=3D ~X86_EFLAGS_TF; @@ -14825,7 +15455,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kgdb.c lin= ux-3.1.4/arch/x86/kernel/kgdb.c raw_smp_processor_id()); } =20 -@@ -534,7 +534,7 @@ static int __kgdb_notify(struct die_args +@@ -534,7 +534,7 @@ static int __kgdb_notify(struct die_args *args, unsi= gned long cmd) return NOTIFY_DONE; =20 case DIE_DEBUG: @@ -14834,10 +15464,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kgdb.c l= inux-3.1.4/arch/x86/kernel/kgdb.c if (user_mode(regs)) return single_step_cont(regs, args); break; -diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c linux-3.1.4/arch/x86/ke= rnel/kprobes.c ---- linux-3.1.4/arch/x86/kernel/kprobes.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/kprobes.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -117,8 +117,11 @@ static void __kprobes __synthesize_relat +diff --git a/arch/x86/kernel/kprobes.c b/arch/x86/kernel/kprobes.c +index 794bc95..c6e29e9 100644 +--- a/arch/x86/kernel/kprobes.c ++++ b/arch/x86/kernel/kprobes.c +@@ -117,8 +117,11 @@ static void __kprobes __synthesize_relative_insn(vo= id *from, void *to, u8 op) } __attribute__((packed)) *insn; =20 insn =3D (struct __arch_relative_insn *)from; @@ -14849,7 +15480,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr } =20 /* Insert a jump instruction at address 'from', which jumps to address = 'to'.*/ -@@ -155,7 +158,7 @@ static int __kprobes can_boost(kprobe_op +@@ -155,7 +158,7 @@ static int __kprobes can_boost(kprobe_opcode_t *opco= des) kprobe_opcode_t opcode; kprobe_opcode_t *orig_opcodes =3D opcodes; =20 @@ -14858,7 +15489,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr return 0; /* Page fault may occur on this address. */ =20 retry: -@@ -316,7 +319,9 @@ static int __kprobes __copy_instruction( +@@ -316,7 +319,9 @@ static int __kprobes __copy_instruction(u8 *dest, u8= *src, int recover) } } insn_get_length(&insn); @@ -14868,7 +15499,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr =20 #ifdef CONFIG_X86_64 if (insn_rip_relative(&insn)) { -@@ -340,7 +345,9 @@ static int __kprobes __copy_instruction( +@@ -340,7 +345,9 @@ static int __kprobes __copy_instruction(u8 *dest, u8= *src, int recover) (u8 *) dest; BUG_ON((s64) (s32) newdisp !=3D newdisp); /* Sanity check. */ disp =3D (u8 *) dest + insn_offset_displacement(&insn); @@ -14878,7 +15509,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr } #endif return insn.length; -@@ -354,12 +361,12 @@ static void __kprobes arch_copy_kprobe(s +@@ -354,12 +361,12 @@ static void __kprobes arch_copy_kprobe(struct kpro= be *p) */ __copy_instruction(p->ainsn.insn, p->addr, 0); =20 @@ -14893,7 +15524,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr } =20 int __kprobes arch_prepare_kprobe(struct kprobe *p) -@@ -476,7 +483,7 @@ static void __kprobes setup_singlestep(s +@@ -476,7 +483,7 @@ static void __kprobes setup_singlestep(struct kprobe= *p, struct pt_regs *regs, * nor set current_kprobe, because it doesn't use single * stepping. */ @@ -14902,7 +15533,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr preempt_enable_no_resched(); return; } -@@ -495,7 +502,7 @@ static void __kprobes setup_singlestep(s +@@ -495,7 +502,7 @@ static void __kprobes setup_singlestep(struct kprobe= *p, struct pt_regs *regs, if (p->opcode =3D=3D BREAKPOINT_INSTRUCTION) regs->ip =3D (unsigned long)p->addr; else @@ -14911,7 +15542,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr } =20 /* -@@ -574,7 +581,7 @@ static int __kprobes kprobe_handler(stru +@@ -574,7 +581,7 @@ static int __kprobes kprobe_handler(struct pt_regs *= regs) setup_singlestep(p, regs, kcb, 0); return 1; } @@ -14920,7 +15551,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr /* * The breakpoint instruction was removed right * after we hit it. Another cpu has removed -@@ -682,6 +689,9 @@ static void __used __kprobes kretprobe_t +@@ -682,6 +689,9 @@ static void __used __kprobes kretprobe_trampoline_ho= lder(void) " movq %rax, 152(%rsp)\n" RESTORE_REGS_STRING " popfq\n" @@ -14930,7 +15561,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr #else " pushf\n" SAVE_REGS_STRING -@@ -819,7 +829,7 @@ static void __kprobes resume_execution(s +@@ -819,7 +829,7 @@ static void __kprobes resume_execution(struct kprobe= *p, struct pt_regs *regs, struct kprobe_ctlblk *kcb) { unsigned long *tos =3D stack_addr(regs); @@ -14939,7 +15570,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr unsigned long orig_ip =3D (unsigned long)p->addr; kprobe_opcode_t *insn =3D p->ainsn.insn; =20 -@@ -1001,7 +1011,7 @@ int __kprobes kprobe_exceptions_notify(s +@@ -1001,7 +1011,7 @@ int __kprobes kprobe_exceptions_notify(struct noti= fier_block *self, struct die_args *args =3D data; int ret =3D NOTIFY_DONE; =20 @@ -14948,7 +15579,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr return ret; =20 switch (val) { -@@ -1383,7 +1393,7 @@ int __kprobes arch_prepare_optimized_kpr +@@ -1383,7 +1393,7 @@ int __kprobes arch_prepare_optimized_kprobe(struct= optimized_kprobe *op) * Verify if the address gap is in 2GB range, because this uses * a relative jump. */ @@ -14957,7 +15588,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr if (abs(rel) > 0x7fffffff) return -ERANGE; =20 -@@ -1404,11 +1414,11 @@ int __kprobes arch_prepare_optimized_kpr +@@ -1404,11 +1414,11 @@ int __kprobes arch_prepare_optimized_kprobe(stru= ct optimized_kprobe *op) synthesize_set_arg1(buf + TMPL_MOVE_IDX, (unsigned long)op); =20 /* Set probe function call */ @@ -14971,7 +15602,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.c = linux-3.1.4/arch/x86/kernel/kpr =20 flush_icache_range((unsigned long) buf, (unsigned long) buf + TMPL_END_IDX + -@@ -1430,7 +1440,7 @@ static void __kprobes setup_optimize_kpr +@@ -1430,7 +1440,7 @@ static void __kprobes setup_optimize_kprobe(struct= text_poke_param *tprm, ((long)op->kp.addr + RELATIVEJUMP_SIZE)); =20 /* Backup instructions which will be replaced by jump address */ @@ -14980,10 +15611,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kprobes.= c linux-3.1.4/arch/x86/kernel/kpr RELATIVE_ADDR_SIZE); =20 insn_buf[0] =3D RELATIVEJUMP_OPCODE; -diff -urNp linux-3.1.4/arch/x86/kernel/kvm.c linux-3.1.4/arch/x86/kernel= /kvm.c ---- linux-3.1.4/arch/x86/kernel/kvm.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/kernel/kvm.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -437,6 +437,7 @@ static void __init paravirt_ops_setup(vo +diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c +index a9c2116..a52d4fc 100644 +--- a/arch/x86/kernel/kvm.c ++++ b/arch/x86/kernel/kvm.c +@@ -437,6 +437,7 @@ static void __init paravirt_ops_setup(void) pv_mmu_ops.set_pud =3D kvm_set_pud; #if PAGETABLE_LEVELS =3D=3D 4 pv_mmu_ops.set_pgd =3D kvm_set_pgd; @@ -14991,10 +15623,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/kvm.c li= nux-3.1.4/arch/x86/kernel/kvm.c #endif #endif pv_mmu_ops.flush_tlb_user =3D kvm_flush_tlb; -diff -urNp linux-3.1.4/arch/x86/kernel/ldt.c linux-3.1.4/arch/x86/kernel= /ldt.c ---- linux-3.1.4/arch/x86/kernel/ldt.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/kernel/ldt.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -67,13 +67,13 @@ static int alloc_ldt(mm_context_t *pc, i +diff --git a/arch/x86/kernel/ldt.c b/arch/x86/kernel/ldt.c +index ea69726..604d066 100644 +--- a/arch/x86/kernel/ldt.c ++++ b/arch/x86/kernel/ldt.c +@@ -67,13 +67,13 @@ static int alloc_ldt(mm_context_t *pc, int mincount,= int reload) if (reload) { #ifdef CONFIG_SMP preempt_disable(); @@ -15010,7 +15643,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ldt.c linu= x-3.1.4/arch/x86/kernel/ldt.c #endif } if (oldsize) { -@@ -95,7 +95,7 @@ static inline int copy_ldt(mm_context_t=20 +@@ -95,7 +95,7 @@ static inline int copy_ldt(mm_context_t *new, mm_conte= xt_t *old) return err; =20 for (i =3D 0; i < old->size; i++) @@ -15019,7 +15652,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ldt.c linu= x-3.1.4/arch/x86/kernel/ldt.c return 0; } =20 -@@ -116,6 +116,24 @@ int init_new_context(struct task_struct=20 +@@ -116,6 +116,24 @@ int init_new_context(struct task_struct *tsk, struc= t mm_struct *mm) retval =3D copy_ldt(&mm->context, &old_mm->context); mutex_unlock(&old_mm->context.lock); } @@ -15044,7 +15677,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ldt.c linu= x-3.1.4/arch/x86/kernel/ldt.c return retval; } =20 -@@ -230,6 +248,13 @@ static int write_ldt(void __user *ptr, u +@@ -230,6 +248,13 @@ static int write_ldt(void __user *ptr, unsigned lon= g bytecount, int oldmode) } } =20 @@ -15058,9 +15691,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ldt.c lin= ux-3.1.4/arch/x86/kernel/ldt.c fill_ldt(&ldt, &ldt_info); if (oldmode) ldt.avl =3D 0; -diff -urNp linux-3.1.4/arch/x86/kernel/machine_kexec_32.c linux-3.1.4/ar= ch/x86/kernel/machine_kexec_32.c ---- linux-3.1.4/arch/x86/kernel/machine_kexec_32.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/machine_kexec_32.c 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/arch/x86/kernel/machine_kexec_32.c b/arch/x86/kernel/machin= e_kexec_32.c +index a3fa43b..8966f4c 100644 +--- a/arch/x86/kernel/machine_kexec_32.c ++++ b/arch/x86/kernel/machine_kexec_32.c @@ -27,7 +27,7 @@ #include #include @@ -15070,7 +15704,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/machine_ke= xec_32.c linux-3.1.4/arch/x86/k { struct desc_ptr curidt; =20 -@@ -39,7 +39,7 @@ static void set_idt(void *newidt, __u16=20 +@@ -39,7 +39,7 @@ static void set_idt(void *newidt, __u16 limit) } =20 =20 @@ -15088,10 +15722,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/machine_= kexec_32.c linux-3.1.4/arch/x86/k =20 relocate_kernel_ptr =3D control_page; page_list[PA_CONTROL_PAGE] =3D __pa(control_page); -diff -urNp linux-3.1.4/arch/x86/kernel/microcode_intel.c linux-3.1.4/arc= h/x86/kernel/microcode_intel.c ---- linux-3.1.4/arch/x86/kernel/microcode_intel.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/microcode_intel.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -440,13 +440,13 @@ static enum ucode_state request_microcod +diff --git a/arch/x86/kernel/microcode_intel.c b/arch/x86/kernel/microco= de_intel.c +index 1a1b606..5c89b55 100644 +--- a/arch/x86/kernel/microcode_intel.c ++++ b/arch/x86/kernel/microcode_intel.c +@@ -440,13 +440,13 @@ static enum ucode_state request_microcode_fw(int c= pu, struct device *device) =20 static int get_ucode_user(void *to, const void *from, size_t n) { @@ -15107,9 +15742,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/microcode= _intel.c linux-3.1.4/arch/x86/ke } =20 static void microcode_fini_cpu(int cpu) -diff -urNp linux-3.1.4/arch/x86/kernel/module.c linux-3.1.4/arch/x86/ker= nel/module.c ---- linux-3.1.4/arch/x86/kernel/module.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/module.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/arch/x86/kernel/module.c b/arch/x86/kernel/module.c +index 925179f..85bec6c 100644 +--- a/arch/x86/kernel/module.c ++++ b/arch/x86/kernel/module.c @@ -36,15 +36,60 @@ #define DEBUGP(fmt...) #endif @@ -15211,7 +15847,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/module.c l= inux-3.1.4/arch/x86/kernel/modu break; default: printk(KERN_ERR "module %s: Unknown relocation: %u\n", -@@ -120,21 +171,30 @@ int apply_relocate_add(Elf64_Shdr *sechd +@@ -120,21 +171,30 @@ int apply_relocate_add(Elf64_Shdr *sechdrs, case R_X86_64_NONE: break; case R_X86_64_64: @@ -15242,9 +15878,23 @@ diff -urNp linux-3.1.4/arch/x86/kernel/module.c = linux-3.1.4/arch/x86/kernel/modu #if 0 if ((s64)val !=3D *(s32 *)loc) goto overflow; -diff -urNp linux-3.1.4/arch/x86/kernel/paravirt.c linux-3.1.4/arch/x86/k= ernel/paravirt.c ---- linux-3.1.4/arch/x86/kernel/paravirt.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/kernel/paravirt.c 2011-11-17 18:29:42.000000000= -0500 +diff --git a/arch/x86/kernel/paravirt-spinlocks.c b/arch/x86/kernel/para= virt-spinlocks.c +index 676b8c7..870ba04 100644 +--- a/arch/x86/kernel/paravirt-spinlocks.c ++++ b/arch/x86/kernel/paravirt-spinlocks.c +@@ -13,7 +13,7 @@ default_spin_lock_flags(arch_spinlock_t *lock, unsigne= d long flags) + arch_spin_lock(lock); + } +=20 +-struct pv_lock_ops pv_lock_ops =3D { ++struct pv_lock_ops pv_lock_ops __read_only =3D { + #ifdef CONFIG_SMP + .spin_is_locked =3D __ticket_spin_is_locked, + .spin_is_contended =3D __ticket_spin_is_contended, +diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c +index d90272e..2d54e8e 100644 +--- a/arch/x86/kernel/paravirt.c ++++ b/arch/x86/kernel/paravirt.c @@ -53,6 +53,9 @@ u64 _paravirt_ident_64(u64 x) { return x; @@ -15255,7 +15905,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/paravirt.c= linux-3.1.4/arch/x86/kernel/pa =20 void __init default_banner(void) { -@@ -133,6 +136,9 @@ static void *get_call_destination(u8 typ +@@ -133,6 +136,9 @@ static void *get_call_destination(u8 type) .pv_lock_ops =3D pv_lock_ops, #endif }; @@ -15265,7 +15915,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/paravirt.c= linux-3.1.4/arch/x86/kernel/pa return *((void **)&tmpl + type); } =20 -@@ -145,15 +151,19 @@ unsigned paravirt_patch_default(u8 type, +@@ -145,15 +151,19 @@ unsigned paravirt_patch_default(u8 type, u16 clobb= ers, void *insnbuf, if (opfunc =3D=3D NULL) /* If there's no function, patch it with a ud2a (BUG) */ ret =3D paravirt_patch_insns(insnbuf, len, ud2a, ud2a+sizeof(ud2a)); @@ -15288,7 +15938,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/paravirt.c= linux-3.1.4/arch/x86/kernel/pa =20 else if (type =3D=3D PARAVIRT_PATCH(pv_cpu_ops.iret) || type =3D=3D PARAVIRT_PATCH(pv_cpu_ops.irq_enable_sysexit) || -@@ -178,7 +188,7 @@ unsigned paravirt_patch_insns(void *insn +@@ -178,7 +188,7 @@ unsigned paravirt_patch_insns(void *insnbuf, unsigne= d len, if (insn_len > len || start =3D=3D NULL) insn_len =3D len; else @@ -15386,21 +16036,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/paravirt= .c linux-3.1.4/arch/x86/kernel/pa }; =20 EXPORT_SYMBOL_GPL(pv_time_ops); -diff -urNp linux-3.1.4/arch/x86/kernel/paravirt-spinlocks.c linux-3.1.4/= arch/x86/kernel/paravirt-spinlocks.c ---- linux-3.1.4/arch/x86/kernel/paravirt-spinlocks.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/paravirt-spinlocks.c 2011-11-16 18:39:07= .000000000 -0500 -@@ -13,7 +13,7 @@ default_spin_lock_flags(arch_spinlock_t=20 - arch_spin_lock(lock); - } -=20 --struct pv_lock_ops pv_lock_ops =3D { -+struct pv_lock_ops pv_lock_ops __read_only =3D { - #ifdef CONFIG_SMP - .spin_is_locked =3D __ticket_spin_is_locked, - .spin_is_contended =3D __ticket_spin_is_contended, -diff -urNp linux-3.1.4/arch/x86/kernel/pci-iommu_table.c linux-3.1.4/arc= h/x86/kernel/pci-iommu_table.c ---- linux-3.1.4/arch/x86/kernel/pci-iommu_table.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/pci-iommu_table.c 2011-11-16 18:40:08.00= 0000000 -0500 +diff --git a/arch/x86/kernel/pci-iommu_table.c b/arch/x86/kernel/pci-iom= mu_table.c +index 35ccf75..67e7d4d 100644 +--- a/arch/x86/kernel/pci-iommu_table.c ++++ b/arch/x86/kernel/pci-iommu_table.c @@ -2,7 +2,7 @@ #include #include @@ -15410,7 +16049,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/pci-iommu_= table.c linux-3.1.4/arch/x86/ke =20 #define DEBUG 1 =20 -@@ -51,6 +51,8 @@ void __init check_iommu_entries(struct i +@@ -51,6 +51,8 @@ void __init check_iommu_entries(struct iommu_table_ent= ry *start, { struct iommu_table_entry *p, *q, *x; =20 @@ -15419,10 +16058,152 @@ diff -urNp linux-3.1.4/arch/x86/kernel/pci-iom= mu_table.c linux-3.1.4/arch/x86/ke /* Simple cyclic dependency checker. */ for (p =3D start; p < finish; p++) { q =3D find_dependents_of(start, finish, p); -diff -urNp linux-3.1.4/arch/x86/kernel/process_32.c linux-3.1.4/arch/x86= /kernel/process_32.c ---- linux-3.1.4/arch/x86/kernel/process_32.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/kernel/process_32.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -66,6 +66,7 @@ asmlinkage void ret_from_fork(void) __as +diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c +index e7e3b01..43c5af3 100644 +--- a/arch/x86/kernel/process.c ++++ b/arch/x86/kernel/process.c +@@ -48,16 +48,33 @@ void free_thread_xstate(struct task_struct *tsk) +=20 + void free_thread_info(struct thread_info *ti) + { +- free_thread_xstate(ti->task); + free_pages((unsigned long)ti, get_order(THREAD_SIZE)); + } +=20 ++static struct kmem_cache *task_struct_cachep; ++ + void arch_task_cache_init(void) + { +- task_xstate_cachep =3D +- kmem_cache_create("task_xstate", xstate_size, ++ /* create a slab on which task_structs can be allocated */ ++ task_struct_cachep =3D ++ kmem_cache_create("task_struct", sizeof(struct task_struct), ++ ARCH_MIN_TASKALIGN, SLAB_PANIC | SLAB_NOTRACK, NULL); ++ ++ task_xstate_cachep =3D ++ kmem_cache_create("task_xstate", xstate_size, + __alignof__(union thread_xstate), +- SLAB_PANIC | SLAB_NOTRACK, NULL); ++ SLAB_PANIC | SLAB_NOTRACK | SLAB_USERCOPY, NULL); ++} ++ ++struct task_struct *alloc_task_struct_node(int node) ++{ ++ return kmem_cache_alloc_node(task_struct_cachep, GFP_KERNEL, node); ++} ++ ++void free_task_struct(struct task_struct *task) ++{ ++ free_thread_xstate(task); ++ kmem_cache_free(task_struct_cachep, task); + } +=20 + /* +@@ -70,7 +87,7 @@ void exit_thread(void) + unsigned long *bp =3D t->io_bitmap_ptr; +=20 + if (bp) { +- struct tss_struct *tss =3D &per_cpu(init_tss, get_cpu()); ++ struct tss_struct *tss =3D init_tss + get_cpu(); +=20 + t->io_bitmap_ptr =3D NULL; + clear_thread_flag(TIF_IO_BITMAP); +@@ -106,7 +123,7 @@ void show_regs_common(void) +=20 + printk(KERN_CONT "\n"); + printk(KERN_DEFAULT "Pid: %d, comm: %.20s %s %s %.*s", +- current->pid, current->comm, print_tainted(), ++ task_pid_nr(current), current->comm, print_tainted(), + init_utsname()->release, + (int)strcspn(init_utsname()->version, " "), + init_utsname()->version); +@@ -120,6 +137,9 @@ void flush_thread(void) + { + struct task_struct *tsk =3D current; +=20 ++#if defined(CONFIG_X86_32) && !defined(CONFIG_CC_STACKPROTECTOR) && !de= fined(CONFIG_PAX_MEMORY_UDEREF) ++ loadsegment(gs, 0); ++#endif + flush_ptrace_hw_breakpoint(tsk); + memset(tsk->thread.tls_array, 0, sizeof(tsk->thread.tls_array)); + /* +@@ -282,10 +302,10 @@ int kernel_thread(int (*fn)(void *), void *arg, un= signed long flags) + regs.di =3D (unsigned long) arg; +=20 + #ifdef CONFIG_X86_32 +- regs.ds =3D __USER_DS; +- regs.es =3D __USER_DS; ++ regs.ds =3D __KERNEL_DS; ++ regs.es =3D __KERNEL_DS; + regs.fs =3D __KERNEL_PERCPU; +- regs.gs =3D __KERNEL_STACK_CANARY; ++ savesegment(gs, regs.gs); + #else + regs.ss =3D __KERNEL_DS; + #endif +@@ -403,7 +423,7 @@ void default_idle(void) + EXPORT_SYMBOL(default_idle); + #endif +=20 +-void stop_this_cpu(void *dummy) ++__noreturn void stop_this_cpu(void *dummy) + { + local_irq_disable(); + /* +@@ -645,16 +665,37 @@ static int __init idle_setup(char *str) + } + early_param("idle", idle_setup); +=20 +-unsigned long arch_align_stack(unsigned long sp) ++#ifdef CONFIG_PAX_RANDKSTACK ++void pax_randomize_kstack(struct pt_regs *regs) + { +- if (!(current->personality & ADDR_NO_RANDOMIZE) && randomize_va_space) +- sp -=3D get_random_int() % 8192; +- return sp & ~0xf; +-} ++ struct thread_struct *thread =3D ¤t->thread; ++ unsigned long time; +=20 +-unsigned long arch_randomize_brk(struct mm_struct *mm) +-{ +- unsigned long range_end =3D mm->brk + 0x02000000; +- return randomize_range(mm->brk, range_end, 0) ? : mm->brk; +-} ++ if (!randomize_va_space) ++ return; ++ ++ if (v8086_mode(regs)) ++ return; +=20 ++ rdtscl(time); ++ ++ /* P4 seems to return a 0 LSB, ignore it */ ++#ifdef CONFIG_MPENTIUM4 ++ time &=3D 0x3EUL; ++ time <<=3D 2; ++#elif defined(CONFIG_X86_64) ++ time &=3D 0xFUL; ++ time <<=3D 4; ++#else ++ time &=3D 0x1FUL; ++ time <<=3D 3; ++#endif ++ ++ thread->sp0 ^=3D time; ++ load_sp0(init_tss + smp_processor_id(), thread); ++ ++#ifdef CONFIG_X86_64 ++ percpu_write(kernel_stack, thread->sp0); ++#endif ++} ++#endif +diff --git a/arch/x86/kernel/process_32.c b/arch/x86/kernel/process_32.c +index 7a3b651..5a946f6 100644 +--- a/arch/x86/kernel/process_32.c ++++ b/arch/x86/kernel/process_32.c +@@ -66,6 +66,7 @@ asmlinkage void ret_from_fork(void) __asm__("ret_from_= fork"); unsigned long thread_saved_pc(struct task_struct *tsk) { return ((unsigned long *)tsk->thread.sp)[3]; @@ -15430,7 +16211,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_32= .c linux-3.1.4/arch/x86/kernel/ } =20 #ifndef CONFIG_SMP -@@ -128,15 +129,14 @@ void __show_regs(struct pt_regs *regs, i +@@ -128,15 +129,14 @@ void __show_regs(struct pt_regs *regs, int all) unsigned long sp; unsigned short ss, gs; =20 @@ -15448,7 +16229,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_32= .c linux-3.1.4/arch/x86/kernel/ =20 show_regs_common(); =20 -@@ -198,13 +198,14 @@ int copy_thread(unsigned long clone_flag +@@ -198,13 +198,14 @@ int copy_thread(unsigned long clone_flags, unsigne= d long sp, struct task_struct *tsk; int err; =20 @@ -15464,7 +16245,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_32= .c linux-3.1.4/arch/x86/kernel/ =20 p->thread.ip =3D (unsigned long) ret_from_fork; =20 -@@ -294,7 +295,7 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -294,7 +295,7 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) struct thread_struct *prev =3D &prev_p->thread, *next =3D &next_p->thread; int cpu =3D smp_processor_id(); @@ -15473,7 +16254,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_32= .c linux-3.1.4/arch/x86/kernel/ bool preload_fpu; =20 /* never put a printk in __switch_to... printk() calls wake_up*() indi= rectly */ -@@ -329,6 +330,10 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -329,6 +330,10 @@ __switch_to(struct task_struct *prev_p, struct task= _struct *next_p) */ lazy_save_gs(prev->gs); =20 @@ -15484,7 +16265,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_32= .c linux-3.1.4/arch/x86/kernel/ /* * Load the per-thread Thread-Local Storage descriptor. */ -@@ -364,6 +369,9 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -364,6 +369,9 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) */ arch_end_context_switch(next_p); =20 @@ -15494,7 +16275,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_32= .c linux-3.1.4/arch/x86/kernel/ if (preload_fpu) __math_state_restore(); =20 -@@ -373,8 +381,6 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -373,8 +381,6 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) if (prev->gs | next->gs) lazy_load_gs(next->gs); =20 @@ -15503,14 +16284,15 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_= 32.c linux-3.1.4/arch/x86/kernel/ return prev_p; } =20 -@@ -404,4 +410,3 @@ unsigned long get_wchan(struct task_stru +@@ -404,4 +410,3 @@ unsigned long get_wchan(struct task_struct *p) } while (count++ < 16); return 0; } - -diff -urNp linux-3.1.4/arch/x86/kernel/process_64.c linux-3.1.4/arch/x86= /kernel/process_64.c ---- linux-3.1.4/arch/x86/kernel/process_64.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/kernel/process_64.c 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/kernel/process_64.c b/arch/x86/kernel/process_64.c +index f693e44..3c979b2 100644 +--- a/arch/x86/kernel/process_64.c ++++ b/arch/x86/kernel/process_64.c @@ -88,7 +88,7 @@ static void __exit_idle(void) void exit_idle(void) { @@ -15520,7 +16302,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_64= .c linux-3.1.4/arch/x86/kernel/ return; __exit_idle(); } -@@ -262,8 +262,7 @@ int copy_thread(unsigned long clone_flag +@@ -262,8 +262,7 @@ int copy_thread(unsigned long clone_flags, unsigned = long sp, struct pt_regs *childregs; struct task_struct *me =3D current; =20 @@ -15530,7 +16312,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_64= .c linux-3.1.4/arch/x86/kernel/ *childregs =3D *regs; =20 childregs->ax =3D 0; -@@ -275,6 +274,7 @@ int copy_thread(unsigned long clone_flag +@@ -275,6 +274,7 @@ int copy_thread(unsigned long clone_flags, unsigned = long sp, p->thread.sp =3D (unsigned long) childregs; p->thread.sp0 =3D (unsigned long) (childregs+1); p->thread.usersp =3D me->thread.usersp; @@ -15538,7 +16320,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_64= .c linux-3.1.4/arch/x86/kernel/ =20 set_tsk_thread_flag(p, TIF_FORK); =20 -@@ -377,7 +377,7 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -377,7 +377,7 @@ __switch_to(struct task_struct *prev_p, struct task_= struct *next_p) struct thread_struct *prev =3D &prev_p->thread; struct thread_struct *next =3D &next_p->thread; int cpu =3D smp_processor_id(); @@ -15547,7 +16329,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_64= .c linux-3.1.4/arch/x86/kernel/ unsigned fsindex, gsindex; bool preload_fpu; =20 -@@ -473,10 +473,9 @@ __switch_to(struct task_struct *prev_p,=20 +@@ -473,10 +473,9 @@ __switch_to(struct task_struct *prev_p, struct task= _struct *next_p) prev->usersp =3D percpu_read(old_rsp); percpu_write(old_rsp, next->usersp); percpu_write(current_task, next_p); @@ -15560,7 +16342,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process_64= .c linux-3.1.4/arch/x86/kernel/ =20 /* * Now maybe reload the debug registers and handle I/O bitmaps -@@ -538,12 +537,11 @@ unsigned long get_wchan(struct task_stru +@@ -538,12 +537,11 @@ unsigned long get_wchan(struct task_struct *p) if (!p || p =3D=3D current || p->state =3D=3D TASK_RUNNING) return 0; stack =3D (unsigned long)task_stack_page(p); @@ -15575,150 +16357,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/process= _64.c linux-3.1.4/arch/x86/kernel/ return 0; ip =3D *(u64 *)(fp+8); if (!in_sched_functions(ip)) -diff -urNp linux-3.1.4/arch/x86/kernel/process.c linux-3.1.4/arch/x86/ke= rnel/process.c ---- linux-3.1.4/arch/x86/kernel/process.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/process.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -48,16 +48,33 @@ void free_thread_xstate(struct task_stru -=20 - void free_thread_info(struct thread_info *ti) - { -- free_thread_xstate(ti->task); - free_pages((unsigned long)ti, get_order(THREAD_SIZE)); - } -=20 -+static struct kmem_cache *task_struct_cachep; -+ - void arch_task_cache_init(void) - { -- task_xstate_cachep =3D -- kmem_cache_create("task_xstate", xstate_size, -+ /* create a slab on which task_structs can be allocated */ -+ task_struct_cachep =3D -+ kmem_cache_create("task_struct", sizeof(struct task_struct), -+ ARCH_MIN_TASKALIGN, SLAB_PANIC | SLAB_NOTRACK, NULL); -+ -+ task_xstate_cachep =3D -+ kmem_cache_create("task_xstate", xstate_size, - __alignof__(union thread_xstate), -- SLAB_PANIC | SLAB_NOTRACK, NULL); -+ SLAB_PANIC | SLAB_NOTRACK | SLAB_USERCOPY, NULL); -+} -+ -+struct task_struct *alloc_task_struct_node(int node) -+{ -+ return kmem_cache_alloc_node(task_struct_cachep, GFP_KERNEL, node); -+} -+ -+void free_task_struct(struct task_struct *task) -+{ -+ free_thread_xstate(task); -+ kmem_cache_free(task_struct_cachep, task); - } -=20 - /* -@@ -70,7 +87,7 @@ void exit_thread(void) - unsigned long *bp =3D t->io_bitmap_ptr; -=20 - if (bp) { -- struct tss_struct *tss =3D &per_cpu(init_tss, get_cpu()); -+ struct tss_struct *tss =3D init_tss + get_cpu(); -=20 - t->io_bitmap_ptr =3D NULL; - clear_thread_flag(TIF_IO_BITMAP); -@@ -106,7 +123,7 @@ void show_regs_common(void) -=20 - printk(KERN_CONT "\n"); - printk(KERN_DEFAULT "Pid: %d, comm: %.20s %s %s %.*s", -- current->pid, current->comm, print_tainted(), -+ task_pid_nr(current), current->comm, print_tainted(), - init_utsname()->release, - (int)strcspn(init_utsname()->version, " "), - init_utsname()->version); -@@ -120,6 +137,9 @@ void flush_thread(void) - { - struct task_struct *tsk =3D current; -=20 -+#if defined(CONFIG_X86_32) && !defined(CONFIG_CC_STACKPROTECTOR) && !de= fined(CONFIG_PAX_MEMORY_UDEREF) -+ loadsegment(gs, 0); -+#endif - flush_ptrace_hw_breakpoint(tsk); - memset(tsk->thread.tls_array, 0, sizeof(tsk->thread.tls_array)); - /* -@@ -282,10 +302,10 @@ int kernel_thread(int (*fn)(void *), voi - regs.di =3D (unsigned long) arg; -=20 - #ifdef CONFIG_X86_32 -- regs.ds =3D __USER_DS; -- regs.es =3D __USER_DS; -+ regs.ds =3D __KERNEL_DS; -+ regs.es =3D __KERNEL_DS; - regs.fs =3D __KERNEL_PERCPU; -- regs.gs =3D __KERNEL_STACK_CANARY; -+ savesegment(gs, regs.gs); - #else - regs.ss =3D __KERNEL_DS; - #endif -@@ -403,7 +423,7 @@ void default_idle(void) - EXPORT_SYMBOL(default_idle); - #endif -=20 --void stop_this_cpu(void *dummy) -+__noreturn void stop_this_cpu(void *dummy) - { - local_irq_disable(); - /* -@@ -645,16 +665,37 @@ static int __init idle_setup(char *str) - } - early_param("idle", idle_setup); -=20 --unsigned long arch_align_stack(unsigned long sp) -+#ifdef CONFIG_PAX_RANDKSTACK -+void pax_randomize_kstack(struct pt_regs *regs) - { -- if (!(current->personality & ADDR_NO_RANDOMIZE) && randomize_va_space) -- sp -=3D get_random_int() % 8192; -- return sp & ~0xf; --} -+ struct thread_struct *thread =3D ¤t->thread; -+ unsigned long time; -=20 --unsigned long arch_randomize_brk(struct mm_struct *mm) --{ -- unsigned long range_end =3D mm->brk + 0x02000000; -- return randomize_range(mm->brk, range_end, 0) ? : mm->brk; --} -+ if (!randomize_va_space) -+ return; -+ -+ if (v8086_mode(regs)) -+ return; -=20 -+ rdtscl(time); -+ -+ /* P4 seems to return a 0 LSB, ignore it */ -+#ifdef CONFIG_MPENTIUM4 -+ time &=3D 0x3EUL; -+ time <<=3D 2; -+#elif defined(CONFIG_X86_64) -+ time &=3D 0xFUL; -+ time <<=3D 4; -+#else -+ time &=3D 0x1FUL; -+ time <<=3D 3; -+#endif -+ -+ thread->sp0 ^=3D time; -+ load_sp0(init_tss + smp_processor_id(), thread); -+ -+#ifdef CONFIG_X86_64 -+ percpu_write(kernel_stack, thread->sp0); -+#endif -+} -+#endif -diff -urNp linux-3.1.4/arch/x86/kernel/ptrace.c linux-3.1.4/arch/x86/ker= nel/ptrace.c ---- linux-3.1.4/arch/x86/kernel/ptrace.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/ptrace.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -822,7 +822,7 @@ long arch_ptrace(struct task_struct *chi +diff --git a/arch/x86/kernel/ptrace.c b/arch/x86/kernel/ptrace.c +index 8252879..d3219e0 100644 +--- a/arch/x86/kernel/ptrace.c ++++ b/arch/x86/kernel/ptrace.c +@@ -822,7 +822,7 @@ long arch_ptrace(struct task_struct *child, long req= uest, unsigned long addr, unsigned long data) { int ret; @@ -15727,7 +16370,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ptrace.c l= inux-3.1.4/arch/x86/kernel/ptra =20 switch (request) { /* read the word at location addr in the USER area. */ -@@ -907,14 +907,14 @@ long arch_ptrace(struct task_struct *chi +@@ -907,14 +907,14 @@ long arch_ptrace(struct task_struct *child, long r= equest, if ((int) addr < 0) return -EIO; ret =3D do_get_thread_area(child, addr, @@ -15744,7 +16387,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ptrace.c l= inux-3.1.4/arch/x86/kernel/ptra break; #endif =20 -@@ -1331,7 +1331,7 @@ static void fill_sigtrap_info(struct tas +@@ -1331,7 +1331,7 @@ static void fill_sigtrap_info(struct task_struct *= tsk, memset(info, 0, sizeof(*info)); info->si_signo =3D SIGTRAP; info->si_code =3D si_code; @@ -15753,10 +16396,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/ptrace.c= linux-3.1.4/arch/x86/kernel/ptra } =20 void user_single_step_siginfo(struct task_struct *tsk, -diff -urNp linux-3.1.4/arch/x86/kernel/pvclock.c linux-3.1.4/arch/x86/ke= rnel/pvclock.c ---- linux-3.1.4/arch/x86/kernel/pvclock.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/pvclock.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -81,11 +81,11 @@ unsigned long pvclock_tsc_khz(struct pvc +diff --git a/arch/x86/kernel/pvclock.c b/arch/x86/kernel/pvclock.c +index 42eb330..139955c 100644 +--- a/arch/x86/kernel/pvclock.c ++++ b/arch/x86/kernel/pvclock.c +@@ -81,11 +81,11 @@ unsigned long pvclock_tsc_khz(struct pvclock_vcpu_ti= me_info *src) return pv_tsc_khz; } =20 @@ -15770,7 +16414,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/pvclock.c = linux-3.1.4/arch/x86/kernel/pvc } =20 cycle_t pvclock_clocksource_read(struct pvclock_vcpu_time_info *src) -@@ -121,11 +121,11 @@ cycle_t pvclock_clocksource_read(struct=20 +@@ -121,11 +121,11 @@ cycle_t pvclock_clocksource_read(struct pvclock_vc= pu_time_info *src) * updating at the same time, and one of them could be slightly behind= , * making the assumption that last_value always go forward fail to hol= d. */ @@ -15784,9 +16428,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/pvclock.c= linux-3.1.4/arch/x86/kernel/pvc } while (unlikely(last !=3D ret)); =20 return ret; -diff -urNp linux-3.1.4/arch/x86/kernel/reboot.c linux-3.1.4/arch/x86/ker= nel/reboot.c ---- linux-3.1.4/arch/x86/kernel/reboot.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/reboot.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c +index 9242436..753954d 100644 +--- a/arch/x86/kernel/reboot.c ++++ b/arch/x86/kernel/reboot.c @@ -35,7 +35,7 @@ void (*pm_power_off)(void); EXPORT_SYMBOL(pm_power_off); =20 @@ -15816,7 +16461,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/reboot.c l= inux-3.1.4/arch/x86/kernel/rebo local_irq_disable(); =20 /* Write zero to CMOS register number 0x0f, which the BIOS POST -@@ -347,14 +351,14 @@ void machine_real_restart(unsigned int t +@@ -347,14 +351,14 @@ void machine_real_restart(unsigned int type) boot)". This seems like a fairly standard thing that gets set by REBOOT.COM programs, and the previous reset routine did this too. */ @@ -15833,7 +16478,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/reboot.c l= inux-3.1.4/arch/x86/kernel/rebo =20 /* GDT[0]: GDT self-pointer */ lowmem_gdt[0] =3D -@@ -365,7 +369,33 @@ void machine_real_restart(unsigned int t +@@ -365,7 +369,33 @@ void machine_real_restart(unsigned int type) GDT_ENTRY(0x009b, restart_pa, 0xffff); =20 /* Jump to the identity-mapped low memory code */ @@ -15867,7 +16512,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/reboot.c l= inux-3.1.4/arch/x86/kernel/rebo } #ifdef CONFIG_APM_MODULE EXPORT_SYMBOL(machine_real_restart); -@@ -523,7 +553,7 @@ void __attribute__((weak)) mach_reboot_f +@@ -523,7 +553,7 @@ void __attribute__((weak)) mach_reboot_fixups(void) * try to force a triple fault and then cycle between hitting the keybo= ard * controller and doing that */ @@ -15892,7 +16537,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/reboot.c l= inux-3.1.4/arch/x86/kernel/rebo { printk("machine restart\n"); =20 -@@ -662,7 +692,7 @@ static void native_machine_restart(char=20 +@@ -662,7 +692,7 @@ static void native_machine_restart(char *__unused) __machine_emergency_restart(0); } =20 @@ -15910,7 +16555,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/reboot.c l= inux-3.1.4/arch/x86/kernel/rebo { if (pm_power_off) { if (!reboot_force) -@@ -682,6 +712,7 @@ static void native_machine_power_off(voi +@@ -682,6 +712,7 @@ static void native_machine_power_off(void) } /* a fallback in case there is no PM info available */ tboot_shutdown(TB_SHUTDOWN_HALT); @@ -15918,9 +16563,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/reboot.c = linux-3.1.4/arch/x86/kernel/rebo } =20 struct machine_ops machine_ops =3D { -diff -urNp linux-3.1.4/arch/x86/kernel/relocate_kernel_64.S linux-3.1.4/= arch/x86/kernel/relocate_kernel_64.S ---- linux-3.1.4/arch/x86/kernel/relocate_kernel_64.S 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/relocate_kernel_64.S 2011-12-02 17:38:47= .000000000 -0500 +diff --git a/arch/x86/kernel/relocate_kernel_64.S b/arch/x86/kernel/relo= cate_kernel_64.S +index 7a6f3b3..bed145d7 100644 +--- a/arch/x86/kernel/relocate_kernel_64.S ++++ b/arch/x86/kernel/relocate_kernel_64.S @@ -11,6 +11,7 @@ #include #include @@ -15945,10 +16591,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/relocate= _kernel_64.S linux-3.1.4/arch/x86 ret =20 1: -diff -urNp linux-3.1.4/arch/x86/kernel/setup.c linux-3.1.4/arch/x86/kern= el/setup.c ---- linux-3.1.4/arch/x86/kernel/setup.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/kernel/setup.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -447,7 +447,7 @@ static void __init parse_setup_data(void +diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c +index afaf384..1a101fe 100644 +--- a/arch/x86/kernel/setup.c ++++ b/arch/x86/kernel/setup.c +@@ -447,7 +447,7 @@ static void __init parse_setup_data(void) =20 switch (data->type) { case SETUP_E820_EXT: @@ -15986,9 +16633,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/setup.c l= inux-3.1.4/arch/x86/kernel/setup data_resource.end =3D virt_to_phys(_edata)-1; bss_resource.start =3D virt_to_phys(&__bss_start); bss_resource.end =3D virt_to_phys(&__bss_stop)-1; -diff -urNp linux-3.1.4/arch/x86/kernel/setup_percpu.c linux-3.1.4/arch/x= 86/kernel/setup_percpu.c ---- linux-3.1.4/arch/x86/kernel/setup_percpu.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/kernel/setup_percpu.c 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/x86/kernel/setup_percpu.c b/arch/x86/kernel/setup_perc= pu.c +index 71f4727..16dc9f7 100644 +--- a/arch/x86/kernel/setup_percpu.c ++++ b/arch/x86/kernel/setup_percpu.c @@ -21,19 +21,17 @@ #include #include @@ -16013,7 +16661,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/setup_perc= pu.c linux-3.1.4/arch/x86/kerne [0 ... NR_CPUS-1] =3D BOOT_PERCPU_OFFSET, }; EXPORT_SYMBOL(__per_cpu_offset); -@@ -155,10 +153,10 @@ static inline void setup_percpu_segment( +@@ -155,10 +153,10 @@ static inline void setup_percpu_segment(int cpu) { #ifdef CONFIG_X86_32 struct desc_struct gdt; @@ -16052,10 +16700,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/setup_pe= rcpu.c linux-3.1.4/arch/x86/kerne /* * Up to this point, the boot CPU has been using .init.data * area. Reload any changed state for the boot CPU. -diff -urNp linux-3.1.4/arch/x86/kernel/signal.c linux-3.1.4/arch/x86/ker= nel/signal.c ---- linux-3.1.4/arch/x86/kernel/signal.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/kernel/signal.c 2011-11-16 19:39:49.000000000 -= 0500 -@@ -198,7 +198,7 @@ static unsigned long align_sigframe(unsi +diff --git a/arch/x86/kernel/signal.c b/arch/x86/kernel/signal.c +index 54ddaeb2..a6aa4d2 100644 +--- a/arch/x86/kernel/signal.c ++++ b/arch/x86/kernel/signal.c +@@ -198,7 +198,7 @@ static unsigned long align_sigframe(unsigned long sp= ) * Align the stack pointer according to the i386 ABI, * i.e. so that on function entry ((sp + 4) & 15) =3D=3D 0. */ @@ -16064,7 +16713,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c l= inux-3.1.4/arch/x86/kernel/sign #else /* !CONFIG_X86_32 */ sp =3D round_down(sp, 16) - 8; #endif -@@ -249,11 +249,11 @@ get_sigframe(struct k_sigaction *ka, str +@@ -249,11 +249,11 @@ get_sigframe(struct k_sigaction *ka, struct pt_reg= s *regs, size_t frame_size, * Return an always-bogus address instead so we will die with SIGSEGV. */ if (onsigstack && !likely(on_sig_stack(sp))) @@ -16078,7 +16727,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c l= inux-3.1.4/arch/x86/kernel/sign =20 return (void __user *)sp; } -@@ -308,9 +308,9 @@ __setup_frame(int sig, struct k_sigactio +@@ -308,9 +308,9 @@ __setup_frame(int sig, struct k_sigaction *ka, sigse= t_t *set, } =20 if (current->mm->context.vdso) @@ -16090,7 +16739,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c l= inux-3.1.4/arch/x86/kernel/sign if (ka->sa.sa_flags & SA_RESTORER) restorer =3D ka->sa.sa_restorer; =20 -@@ -324,7 +324,7 @@ __setup_frame(int sig, struct k_sigactio +@@ -324,7 +324,7 @@ __setup_frame(int sig, struct k_sigaction *ka, sigse= t_t *set, * reasons and because gdb uses it as a signature to notice * signal handler stack frames. */ @@ -16099,7 +16748,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c l= inux-3.1.4/arch/x86/kernel/sign =20 if (err) return -EFAULT; -@@ -378,7 +378,10 @@ static int __setup_rt_frame(int sig, str +@@ -378,7 +378,10 @@ static int __setup_rt_frame(int sig, struct k_sigac= tion *ka, siginfo_t *info, err |=3D __copy_to_user(&frame->uc.uc_sigmask, set, sizeof(*set)); =20 /* Set up to return from userspace. */ @@ -16111,7 +16760,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c l= inux-3.1.4/arch/x86/kernel/sign if (ka->sa.sa_flags & SA_RESTORER) restorer =3D ka->sa.sa_restorer; put_user_ex(restorer, &frame->pretcode); -@@ -390,7 +393,7 @@ static int __setup_rt_frame(int sig, str +@@ -390,7 +393,7 @@ static int __setup_rt_frame(int sig, struct k_sigact= ion *ka, siginfo_t *info, * reasons and because gdb uses it as a signature to notice * signal handler stack frames. */ @@ -16120,7 +16769,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c l= inux-3.1.4/arch/x86/kernel/sign } put_user_catch(err); =20 if (err) -@@ -762,6 +765,8 @@ static void do_signal(struct pt_regs *re +@@ -762,6 +765,8 @@ static void do_signal(struct pt_regs *regs) siginfo_t info; int signr; =20 @@ -16129,7 +16778,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c l= inux-3.1.4/arch/x86/kernel/sign /* * We want the common case to go fast, which is why we may in certain * cases get here from kernel mode. Just return without doing anything -@@ -769,7 +774,7 @@ static void do_signal(struct pt_regs *re +@@ -769,7 +774,7 @@ static void do_signal(struct pt_regs *regs) * X86_32: vm86 regs switched out by assembly code before reaching * here, so testing against kernel CS suffices. */ @@ -16138,10 +16787,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/signal.c= linux-3.1.4/arch/x86/kernel/sign return; =20 signr =3D get_signal_to_deliver(&info, &ka, regs, NULL); -diff -urNp linux-3.1.4/arch/x86/kernel/smpboot.c linux-3.1.4/arch/x86/ke= rnel/smpboot.c ---- linux-3.1.4/arch/x86/kernel/smpboot.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/smpboot.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -709,17 +709,20 @@ static int __cpuinit do_boot_cpu(int api +diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c +index 9f548cb..caf76f7 100644 +--- a/arch/x86/kernel/smpboot.c ++++ b/arch/x86/kernel/smpboot.c +@@ -709,17 +709,20 @@ static int __cpuinit do_boot_cpu(int apicid, int c= pu) set_idle_for_cpu(cpu, c_idle.idle); do_rest: per_cpu(current_task, cpu) =3D c_idle.idle; @@ -16165,7 +16815,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/smpboot.c = linux-3.1.4/arch/x86/kernel/smp initial_code =3D (unsigned long)start_secondary; stack_start =3D c_idle.idle->thread.sp; =20 -@@ -861,6 +864,12 @@ int __cpuinit native_cpu_up(unsigned int +@@ -861,6 +864,12 @@ int __cpuinit native_cpu_up(unsigned int cpu) =20 per_cpu(cpu_state, cpu) =3D CPU_UP_PREPARE; =20 @@ -16178,10 +16828,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/smpboot.= c linux-3.1.4/arch/x86/kernel/smp err =3D do_boot_cpu(apicid, cpu); if (err) { pr_debug("do_boot_cpu failed %d\n", err); -diff -urNp linux-3.1.4/arch/x86/kernel/step.c linux-3.1.4/arch/x86/kerne= l/step.c ---- linux-3.1.4/arch/x86/kernel/step.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/kernel/step.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -27,10 +27,10 @@ unsigned long convert_ip_to_linear(struc +diff --git a/arch/x86/kernel/step.c b/arch/x86/kernel/step.c +index c346d11..d43b163 100644 +--- a/arch/x86/kernel/step.c ++++ b/arch/x86/kernel/step.c +@@ -27,10 +27,10 @@ unsigned long convert_ip_to_linear(struct task_struc= t *child, struct pt_regs *re struct desc_struct *desc; unsigned long base; =20 @@ -16194,7 +16845,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/step.c lin= ux-3.1.4/arch/x86/kernel/step.c addr =3D -1L; /* bogus selector, access would fault */ else { desc =3D child->mm->context.ldt + seg; -@@ -42,7 +42,8 @@ unsigned long convert_ip_to_linear(struc +@@ -42,7 +42,8 @@ unsigned long convert_ip_to_linear(struct task_struct = *child, struct pt_regs *re addr +=3D base; } mutex_unlock(&child->mm->context.lock); @@ -16204,7 +16855,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/step.c lin= ux-3.1.4/arch/x86/kernel/step.c =20 return addr; } -@@ -53,6 +54,9 @@ static int is_setting_trap_flag(struct t +@@ -53,6 +54,9 @@ static int is_setting_trap_flag(struct task_struct *ch= ild, struct pt_regs *regs) unsigned char opcode[15]; unsigned long addr =3D convert_ip_to_linear(child, regs); =20 @@ -16214,17 +16865,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/step.c l= inux-3.1.4/arch/x86/kernel/step.c copied =3D access_process_vm(child, addr, opcode, sizeof(opcode), 0); for (i =3D 0; i < copied; i++) { switch (opcode[i]) { -diff -urNp linux-3.1.4/arch/x86/kernel/syscall_table_32.S linux-3.1.4/ar= ch/x86/kernel/syscall_table_32.S ---- linux-3.1.4/arch/x86/kernel/syscall_table_32.S 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/syscall_table_32.S 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -1,3 +1,4 @@ -+.section .rodata,"a",@progbits - ENTRY(sys_call_table) - .long sys_restart_syscall /* 0 - old "setup()" system call, used for r= estarting */ - .long sys_exit -diff -urNp linux-3.1.4/arch/x86/kernel/sys_i386_32.c linux-3.1.4/arch/x8= 6/kernel/sys_i386_32.c ---- linux-3.1.4/arch/x86/kernel/sys_i386_32.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/kernel/sys_i386_32.c 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/kernel/sys_i386_32.c b/arch/x86/kernel/sys_i386_32= .c +index 0b0cb5f..db6b9ed 100644 +--- a/arch/x86/kernel/sys_i386_32.c ++++ b/arch/x86/kernel/sys_i386_32.c @@ -24,17 +24,224 @@ =20 #include @@ -16237,12 +16881,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_i386_= 32.c linux-3.1.4/arch/x86/kernel - const char *const argv[], - const char *const envp[]) +int i386_mmap_check(unsigned long addr, unsigned long len, unsigned lon= g flags) - { -- long __res; -- asm volatile ("int $0x80" -- : "=3Da" (__res) -- : "0" (__NR_execve), "b" (filename), "c" (argv), "d" (envp) : "memory"= ); -- return __res; ++{ + unsigned long pax_task_size =3D TASK_SIZE; + +#ifdef CONFIG_PAX_SEGMEXEC @@ -16350,7 +16989,12 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_i386_= 32.c linux-3.1.4/arch/x86/kernel +arch_get_unmapped_area_topdown(struct file *filp, const unsigned long a= ddr0, + const unsigned long len, const unsigned long pgoff, + const unsigned long flags) -+{ + { +- long __res; +- asm volatile ("int $0x80" +- : "=3Da" (__res) +- : "0" (__NR_execve), "b" (filename), "c" (argv), "d" (envp) : "memory"= ); +- return __res; + struct vm_area_struct *vma; + struct mm_struct *mm =3D current->mm; + unsigned long base =3D mm->mmap_base, addr =3D addr0, pax_task_size =3D= TASK_SIZE; @@ -16462,9 +17106,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_i386_= 32.c linux-3.1.4/arch/x86/kernel + + return addr; } -diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64.c linux-3.1.4/arch/x86= /kernel/sys_x86_64.c ---- linux-3.1.4/arch/x86/kernel/sys_x86_64.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/kernel/sys_x86_64.c 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/kernel/sys_x86_64.c b/arch/x86/kernel/sys_x86_64.c +index ff14a50..35626c3 100644 +--- a/arch/x86/kernel/sys_x86_64.c ++++ b/arch/x86/kernel/sys_x86_64.c @@ -32,8 +32,8 @@ out: return error; } @@ -16476,7 +17121,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64= .c linux-3.1.4/arch/x86/kernel/ { if (!test_thread_flag(TIF_IA32) && (flags & MAP_32BIT)) { unsigned long new_begin; -@@ -52,7 +52,7 @@ static void find_start_end(unsigned long +@@ -52,7 +52,7 @@ static void find_start_end(unsigned long flags, unsign= ed long *begin, *begin =3D new_begin; } } else { @@ -16485,7 +17130,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64= .c linux-3.1.4/arch/x86/kernel/ *end =3D TASK_SIZE; } } -@@ -69,16 +69,19 @@ arch_get_unmapped_area(struct file *filp +@@ -69,16 +69,19 @@ arch_get_unmapped_area(struct file *filp, unsigned l= ong addr, if (flags & MAP_FIXED) return addr; =20 @@ -16517,7 +17162,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64= .c linux-3.1.4/arch/x86/kernel/ /* * Remember the place where we stopped the search: */ -@@ -128,7 +131,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -128,7 +131,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, { struct vm_area_struct *vma; struct mm_struct *mm =3D current->mm; @@ -16526,7 +17171,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64= .c linux-3.1.4/arch/x86/kernel/ =20 /* requested length too big for entire address space */ if (len > TASK_SIZE) -@@ -141,13 +144,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -141,13 +144,18 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, if (!test_thread_flag(TIF_IA32) && (flags & MAP_32BIT)) goto bottomup; =20 @@ -16549,7 +17194,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64= .c linux-3.1.4/arch/x86/kernel/ } =20 /* check if free_area_cache is useful for us */ -@@ -162,7 +170,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -162,7 +170,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, /* make sure it can fit in the remaining address space */ if (addr > len) { vma =3D find_vma(mm, addr-len); @@ -16558,7 +17203,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64= .c linux-3.1.4/arch/x86/kernel/ /* remember the address as a hint for next time */ return mm->free_area_cache =3D addr-len; } -@@ -179,7 +187,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -179,7 +187,7 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, * return with success: */ vma =3D find_vma(mm, addr); @@ -16567,7 +17212,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_64= .c linux-3.1.4/arch/x86/kernel/ /* remember the address as a hint for next time */ return mm->free_area_cache =3D addr; =20 -@@ -188,8 +196,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -188,8 +196,8 @@ arch_get_unmapped_area_topdown(struct file *filp, co= nst unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -16602,9 +17247,19 @@ diff -urNp linux-3.1.4/arch/x86/kernel/sys_x86_6= 4.c linux-3.1.4/arch/x86/kernel/ mm->cached_hole_size =3D ~0UL; =20 return addr; -diff -urNp linux-3.1.4/arch/x86/kernel/tboot.c linux-3.1.4/arch/x86/kern= el/tboot.c ---- linux-3.1.4/arch/x86/kernel/tboot.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/kernel/tboot.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/x86/kernel/syscall_table_32.S b/arch/x86/kernel/syscal= l_table_32.S +index bc19be3..0f5fbf7 100644 +--- a/arch/x86/kernel/syscall_table_32.S ++++ b/arch/x86/kernel/syscall_table_32.S +@@ -1,3 +1,4 @@ ++.section .rodata,"a",@progbits + ENTRY(sys_call_table) + .long sys_restart_syscall /* 0 - old "setup()" system call, used for r= estarting */ + .long sys_exit +diff --git a/arch/x86/kernel/tboot.c b/arch/x86/kernel/tboot.c +index e07a2fc..db0369d 100644 +--- a/arch/x86/kernel/tboot.c ++++ b/arch/x86/kernel/tboot.c @@ -218,7 +218,7 @@ static int tboot_setup_sleep(void) =20 void tboot_shutdown(u32 shutdown_type) @@ -16623,7 +17278,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/tboot.c li= nux-3.1.4/arch/x86/kernel/tboot shutdown(); =20 /* should not reach here */ -@@ -297,7 +297,7 @@ void tboot_sleep(u8 sleep_state, u32 pm1 +@@ -297,7 +297,7 @@ void tboot_sleep(u8 sleep_state, u32 pm1a_control, u= 32 pm1b_control) tboot_shutdown(acpi_shutdown_map[sleep_state]); } =20 @@ -16632,7 +17287,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/tboot.c li= nux-3.1.4/arch/x86/kernel/tboot =20 static int tboot_wait_for_aps(int num_aps) { -@@ -321,9 +321,9 @@ static int __cpuinit tboot_cpu_callback( +@@ -321,9 +321,9 @@ static int __cpuinit tboot_cpu_callback(struct notif= ier_block *nfb, { switch (action) { case CPU_DYING: @@ -16653,10 +17308,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/tboot.c = linux-3.1.4/arch/x86/kernel/tboot register_hotcpu_notifier(&tboot_cpu_notifier); return 0; } -diff -urNp linux-3.1.4/arch/x86/kernel/time.c linux-3.1.4/arch/x86/kerne= l/time.c ---- linux-3.1.4/arch/x86/kernel/time.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/kernel/time.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -30,9 +30,9 @@ unsigned long profile_pc(struct pt_regs=20 +diff --git a/arch/x86/kernel/time.c b/arch/x86/kernel/time.c +index 5a64d05..804587b 100644 +--- a/arch/x86/kernel/time.c ++++ b/arch/x86/kernel/time.c +@@ -30,9 +30,9 @@ unsigned long profile_pc(struct pt_regs *regs) { unsigned long pc =3D instruction_pointer(regs); =20 @@ -16668,7 +17324,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/time.c lin= ux-3.1.4/arch/x86/kernel/time.c #else unsigned long *sp =3D (unsigned long *)kernel_stack_pointer(regs); -@@ -41,11 +41,17 @@ unsigned long profile_pc(struct pt_regs=20 +@@ -41,11 +41,17 @@ unsigned long profile_pc(struct pt_regs *regs) * or above a saved flags. Eflags has bits 22-31 zero, * kernel addresses don't. */ @@ -16686,10 +17342,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/time.c l= inux-3.1.4/arch/x86/kernel/time.c } return pc; } -diff -urNp linux-3.1.4/arch/x86/kernel/tls.c linux-3.1.4/arch/x86/kernel= /tls.c ---- linux-3.1.4/arch/x86/kernel/tls.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/kernel/tls.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -85,6 +85,11 @@ int do_set_thread_area(struct task_struc +diff --git a/arch/x86/kernel/tls.c b/arch/x86/kernel/tls.c +index 6bb7b85..dd853e1 100644 +--- a/arch/x86/kernel/tls.c ++++ b/arch/x86/kernel/tls.c +@@ -85,6 +85,11 @@ int do_set_thread_area(struct task_struct *p, int idx= , if (idx < GDT_ENTRY_TLS_MIN || idx > GDT_ENTRY_TLS_MAX) return -EINVAL; =20 @@ -16701,9 +17358,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/tls.c lin= ux-3.1.4/arch/x86/kernel/tls.c set_tls_desc(p, idx, &info, 1); =20 return 0; -diff -urNp linux-3.1.4/arch/x86/kernel/trampoline_32.S linux-3.1.4/arch/= x86/kernel/trampoline_32.S ---- linux-3.1.4/arch/x86/kernel/trampoline_32.S 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/kernel/trampoline_32.S 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/kernel/trampoline_32.S b/arch/x86/kernel/trampolin= e_32.S +index 451c0a7..e57f551 100644 +--- a/arch/x86/kernel/trampoline_32.S ++++ b/arch/x86/kernel/trampoline_32.S @@ -32,6 +32,12 @@ #include #include @@ -16726,9 +17384,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/trampolin= e_32.S linux-3.1.4/arch/x86/kern =20 # These need to be in the same 64K segment as the above; # hence we don't use the boot_gdt_descr defined in head.S -diff -urNp linux-3.1.4/arch/x86/kernel/trampoline_64.S linux-3.1.4/arch/= x86/kernel/trampoline_64.S ---- linux-3.1.4/arch/x86/kernel/trampoline_64.S 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/kernel/trampoline_64.S 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/arch/x86/kernel/trampoline_64.S b/arch/x86/kernel/trampolin= e_64.S +index 09ff517..df19fbff 100644 +--- a/arch/x86/kernel/trampoline_64.S ++++ b/arch/x86/kernel/trampoline_64.S @@ -90,7 +90,7 @@ startup_32: movl $__KERNEL_DS, %eax # Initialize the %ds segment register movl %eax, %ds @@ -16747,9 +17406,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/trampolin= e_64.S linux-3.1.4/arch/x86/kern .long tgdt - r_base .short 0 .quad 0x00cf9b000000ffff # __KERNEL32_CS -diff -urNp linux-3.1.4/arch/x86/kernel/traps.c linux-3.1.4/arch/x86/kern= el/traps.c ---- linux-3.1.4/arch/x86/kernel/traps.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/kernel/traps.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c +index 6913369..7e7dff6 100644 +--- a/arch/x86/kernel/traps.c ++++ b/arch/x86/kernel/traps.c @@ -70,12 +70,6 @@ asmlinkage int system_call(void); =20 /* Do we ignore FPU interrupts ? */ @@ -16763,7 +17423,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps #endif =20 DECLARE_BITMAP(used_vectors, NR_VECTORS); -@@ -117,13 +111,13 @@ static inline void preempt_conditional_c +@@ -117,13 +111,13 @@ static inline void preempt_conditional_cli(struct = pt_regs *regs) } =20 static void __kprobes @@ -16779,7 +17439,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps /* * traps 0, 1, 3, 4, and 5 should be forwarded to vm86. * On nmi (interrupt 2), do_trap should not be called. -@@ -134,7 +128,7 @@ do_trap(int trapnr, int signr, char *str +@@ -134,7 +128,7 @@ do_trap(int trapnr, int signr, char *str, struct pt_= regs *regs, } #endif =20 @@ -16818,7 +17478,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps return; =20 #ifdef CONFIG_X86_32 -@@ -264,14 +270,30 @@ do_general_protection(struct pt_regs *re +@@ -264,14 +270,30 @@ do_general_protection(struct pt_regs *regs, long e= rror_code) conditional_sti(regs); =20 #ifdef CONFIG_X86_32 @@ -16865,7 +17525,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps die("general protection fault", regs, error_code); } =20 -@@ -433,6 +462,17 @@ static notrace __kprobes void default_do +@@ -433,6 +462,17 @@ static notrace __kprobes void default_do_nmi(struct= pt_regs *regs) dotraplinkage notrace __kprobes void do_nmi(struct pt_regs *regs, long error_code) { @@ -16883,7 +17543,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps nmi_enter(); =20 inc_irq_stat(__nmi_count); -@@ -569,7 +609,7 @@ dotraplinkage void __kprobes do_debug(st +@@ -569,7 +609,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); =20 @@ -16892,7 +17552,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps handle_vm86_trap((struct kernel_vm86_regs *) regs, error_code, 1); preempt_conditional_cli(regs); -@@ -583,7 +623,7 @@ dotraplinkage void __kprobes do_debug(st +@@ -583,7 +623,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. */ @@ -16901,7 +17561,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps tsk->thread.debugreg6 &=3D ~DR_STEP; set_tsk_thread_flag(tsk, TIF_SINGLESTEP); regs->flags &=3D ~X86_EFLAGS_TF; -@@ -612,7 +652,7 @@ void math_error(struct pt_regs *regs, in +@@ -612,7 +652,7 @@ void math_error(struct pt_regs *regs, int error_code= , int trapnr) return; conditional_sti(regs); =20 @@ -16910,7 +17570,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c li= nux-3.1.4/arch/x86/kernel/traps { if (!fixup_exception(regs)) { task->thread.error_code =3D error_code; -@@ -723,7 +763,7 @@ asmlinkage void __attribute__((weak)) sm +@@ -723,7 +763,7 @@ asmlinkage void __attribute__((weak)) smp_threshold_= interrupt(void) void __math_state_restore(void) { struct thread_info *thread =3D current_thread_info(); @@ -16929,9 +17589,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/traps.c l= inux-3.1.4/arch/x86/kernel/traps =20 if (!tsk_used_math(tsk)) { local_irq_enable(); -diff -urNp linux-3.1.4/arch/x86/kernel/verify_cpu.S linux-3.1.4/arch/x86= /kernel/verify_cpu.S ---- linux-3.1.4/arch/x86/kernel/verify_cpu.S 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/kernel/verify_cpu.S 2011-11-16 18:40:08.0000000= 00 -0500 +diff --git a/arch/x86/kernel/verify_cpu.S b/arch/x86/kernel/verify_cpu.S +index b9242ba..50c5edd 100644 +--- a/arch/x86/kernel/verify_cpu.S ++++ b/arch/x86/kernel/verify_cpu.S @@ -20,6 +20,7 @@ * arch/x86/boot/compressed/head_64.S: Boot cpu verification * arch/x86/kernel/trampoline_64.S: secondary processor verification @@ -16940,9 +17601,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/verify_cp= u.S linux-3.1.4/arch/x86/kernel/ * * verify_cpu, returns the status of longmode and SSE in register %eax. * 0: Success 1: Failure -diff -urNp linux-3.1.4/arch/x86/kernel/vm86_32.c linux-3.1.4/arch/x86/ke= rnel/vm86_32.c ---- linux-3.1.4/arch/x86/kernel/vm86_32.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/kernel/vm86_32.c 2011-11-16 18:40:08.000000000 = -0500 +diff --git a/arch/x86/kernel/vm86_32.c b/arch/x86/kernel/vm86_32.c +index 863f875..4307295 100644 +--- a/arch/x86/kernel/vm86_32.c ++++ b/arch/x86/kernel/vm86_32.c @@ -41,6 +41,7 @@ #include #include @@ -16951,7 +17613,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vm86_32.c = linux-3.1.4/arch/x86/kernel/vm8 =20 #include #include -@@ -148,7 +149,7 @@ struct pt_regs *save_v86_state(struct ke +@@ -148,7 +149,7 @@ struct pt_regs *save_v86_state(struct kernel_vm86_re= gs *regs) do_exit(SIGSEGV); } =20 @@ -16960,7 +17622,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vm86_32.c = linux-3.1.4/arch/x86/kernel/vm8 current->thread.sp0 =3D current->thread.saved_sp0; current->thread.sysenter_cs =3D __KERNEL_CS; load_sp0(tss, ¤t->thread); -@@ -208,6 +209,13 @@ int sys_vm86old(struct vm86_struct __use +@@ -208,6 +209,13 @@ int sys_vm86old(struct vm86_struct __user *v86, str= uct pt_regs *regs) struct task_struct *tsk; int tmp, ret =3D -EPERM; =20 @@ -16974,7 +17636,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vm86_32.c = linux-3.1.4/arch/x86/kernel/vm8 tsk =3D current; if (tsk->thread.saved_sp0) goto out; -@@ -238,6 +246,14 @@ int sys_vm86(unsigned long cmd, unsigned +@@ -238,6 +246,14 @@ int sys_vm86(unsigned long cmd, unsigned long arg, = struct pt_regs *regs) int tmp, ret; struct vm86plus_struct __user *v86; =20 @@ -16989,7 +17651,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vm86_32.c = linux-3.1.4/arch/x86/kernel/vm8 tsk =3D current; switch (cmd) { case VM86_REQUEST_IRQ: -@@ -324,7 +340,7 @@ static void do_sys_vm86(struct kernel_vm +@@ -324,7 +340,7 @@ static void do_sys_vm86(struct kernel_vm86_struct *i= nfo, struct task_struct *tsk tsk->thread.saved_fs =3D info->regs32->fs; tsk->thread.saved_gs =3D get_user_gs(info->regs32); =20 @@ -16998,7 +17660,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vm86_32.c = linux-3.1.4/arch/x86/kernel/vm8 tsk->thread.sp0 =3D (unsigned long) &info->VM86_TSS_ESP0; if (cpu_has_sep) tsk->thread.sysenter_cs =3D 0; -@@ -529,7 +545,7 @@ static void do_int(struct kernel_vm86_re +@@ -529,7 +545,7 @@ static void do_int(struct kernel_vm86_regs *regs, in= t i, goto cannot_handle; if (i =3D=3D 0x21 && is_revectored(AH(regs), &KVM86->int21_revectored)= ) goto cannot_handle; @@ -17007,9 +17669,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vm86_32.c= linux-3.1.4/arch/x86/kernel/vm8 if (get_user(segoffs, intr_ptr)) goto cannot_handle; if ((segoffs >> 16) =3D=3D BIOSSEG) -diff -urNp linux-3.1.4/arch/x86/kernel/vmlinux.lds.S linux-3.1.4/arch/x8= 6/kernel/vmlinux.lds.S ---- linux-3.1.4/arch/x86/kernel/vmlinux.lds.S 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/kernel/vmlinux.lds.S 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/kernel/vmlinux.lds.S b/arch/x86/kernel/vmlinux.lds= .S +index 0f703f1..9e15f64 100644 +--- a/arch/x86/kernel/vmlinux.lds.S ++++ b/arch/x86/kernel/vmlinux.lds.S @@ -26,6 +26,13 @@ #include #include @@ -17086,7 +17749,8 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vmlinux.ld= s.S linux-3.1.4/arch/x86/kernel =20 - NOTES :text :note + . +=3D __KERNEL_TEXT_OFFSET; -+ +=20 +- EXCEPTION_TABLE(16) :text =3D 0x9090 +#ifdef CONFIG_X86_32 + . =3D ALIGN(PAGE_SIZE); + .module.text : AT(ADDR(.module.text) - LOAD_OFFSET) { @@ -17122,8 +17786,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vmlinux.ld= s.S linux-3.1.4/arch/x86/kernel + + . =3D ALIGN(PAGE_SIZE); + NOTES :rodata :note -=20 -- EXCEPTION_TABLE(16) :text =3D 0x9090 ++ + EXCEPTION_TABLE(16) :rodata =20 #if defined(CONFIG_DEBUG_RODATA) @@ -17270,10 +17933,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vmlinux.= lds.S linux-3.1.4/arch/x86/kernel "kernel image bigger than KERNEL_IMAGE_SIZE"); =20 #ifdef CONFIG_SMP -diff -urNp linux-3.1.4/arch/x86/kernel/vsyscall_64.c linux-3.1.4/arch/x8= 6/kernel/vsyscall_64.c ---- linux-3.1.4/arch/x86/kernel/vsyscall_64.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/kernel/vsyscall_64.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -56,15 +56,13 @@ DEFINE_VVAR(struct vsyscall_gtod_data, v +diff --git a/arch/x86/kernel/vsyscall_64.c b/arch/x86/kernel/vsyscall_64= .c +index b56c65de..561a55b 100644 +--- a/arch/x86/kernel/vsyscall_64.c ++++ b/arch/x86/kernel/vsyscall_64.c +@@ -56,15 +56,13 @@ DEFINE_VVAR(struct vsyscall_gtod_data, vsyscall_gtod= _data) =3D .lock =3D __SEQLOCK_UNLOCKED(__vsyscall_gtod_data.lock), }; =20 @@ -17290,7 +17954,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vsyscall_6= 4.c linux-3.1.4/arch/x86/kernel else if (!strcmp("none", str)) vsyscall_mode =3D NONE; else -@@ -177,7 +175,7 @@ bool emulate_vsyscall(struct pt_regs *re +@@ -177,7 +175,7 @@ bool emulate_vsyscall(struct pt_regs *regs, unsigned= long address) =20 tsk =3D current; if (seccomp_mode(&tsk->seccomp)) @@ -17299,7 +17963,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vsyscall_6= 4.c linux-3.1.4/arch/x86/kernel =20 switch (vsyscall_nr) { case 0: -@@ -219,8 +217,7 @@ bool emulate_vsyscall(struct pt_regs *re +@@ -219,8 +217,7 @@ bool emulate_vsyscall(struct pt_regs *regs, unsigned= long address) return true; =20 sigsegv: @@ -17321,9 +17985,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/vsyscall_= 64.c linux-3.1.4/arch/x86/kernel BUILD_BUG_ON((unsigned long)__fix_to_virt(VSYSCALL_FIRST_PAGE) !=3D (unsigned long)VSYSCALL_START); =20 -diff -urNp linux-3.1.4/arch/x86/kernel/x8664_ksyms_64.c linux-3.1.4/arch= /x86/kernel/x8664_ksyms_64.c ---- linux-3.1.4/arch/x86/kernel/x8664_ksyms_64.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/arch/x86/kernel/x8664_ksyms_64.c 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/arch/x86/kernel/x8664_ksyms_64.c b/arch/x86/kernel/x8664_ks= yms_64.c +index 9796c2f..f686fbf 100644 +--- a/arch/x86/kernel/x8664_ksyms_64.c ++++ b/arch/x86/kernel/x8664_ksyms_64.c @@ -29,8 +29,6 @@ EXPORT_SYMBOL(__put_user_8); EXPORT_SYMBOL(copy_user_generic_string); EXPORT_SYMBOL(copy_user_generic_unrolled); @@ -17333,10 +17998,11 @@ diff -urNp linux-3.1.4/arch/x86/kernel/x8664_ks= yms_64.c linux-3.1.4/arch/x86/ker =20 EXPORT_SYMBOL(copy_page); EXPORT_SYMBOL(clear_page); -diff -urNp linux-3.1.4/arch/x86/kernel/xsave.c linux-3.1.4/arch/x86/kern= el/xsave.c ---- linux-3.1.4/arch/x86/kernel/xsave.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/kernel/xsave.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -130,7 +130,7 @@ int check_for_xstate(struct i387_fxsave_ +diff --git a/arch/x86/kernel/xsave.c b/arch/x86/kernel/xsave.c +index a391134..d0b63b6e 100644 +--- a/arch/x86/kernel/xsave.c ++++ b/arch/x86/kernel/xsave.c +@@ -130,7 +130,7 @@ int check_for_xstate(struct i387_fxsave_struct __use= r *buf, fx_sw_user->xstate_size > fx_sw_user->extended_size) return -EINVAL; =20 @@ -17354,7 +18020,7 @@ diff -urNp linux-3.1.4/arch/x86/kernel/xsave.c li= nux-3.1.4/arch/x86/kernel/xsave } =20 /* -@@ -299,7 +299,7 @@ int restore_i387_xstate(void __user *buf +@@ -299,7 +299,7 @@ int restore_i387_xstate(void __user *buf) if (use_xsave()) err =3D restore_user_xstate(buf); else @@ -17363,9 +18029,10 @@ diff -urNp linux-3.1.4/arch/x86/kernel/xsave.c l= inux-3.1.4/arch/x86/kernel/xsave buf); if (unlikely(err)) { /* -diff -urNp linux-3.1.4/arch/x86/kvm/emulate.c linux-3.1.4/arch/x86/kvm/e= mulate.c ---- linux-3.1.4/arch/x86/kvm/emulate.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/kvm/emulate.c 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c +index 8b4cc5f..f086b5b 100644 +--- a/arch/x86/kvm/emulate.c ++++ b/arch/x86/kvm/emulate.c @@ -96,7 +96,7 @@ #define Src2ImmByte (2<<29) #define Src2One (3<<29) @@ -17400,9 +18067,10 @@ diff -urNp linux-3.1.4/arch/x86/kvm/emulate.c li= nux-3.1.4/arch/x86/kvm/emulate.c switch ((_dst).bytes) { \ case 1: \ ____emulate_2op(_op,_src,_dst,_eflags,_bx,_by,"b",u8); \ -diff -urNp linux-3.1.4/arch/x86/kvm/lapic.c linux-3.1.4/arch/x86/kvm/lap= ic.c ---- linux-3.1.4/arch/x86/kvm/lapic.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kvm/lapic.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c +index 57dcbd4..79aba9b 100644 +--- a/arch/x86/kvm/lapic.c ++++ b/arch/x86/kvm/lapic.c @@ -53,7 +53,7 @@ #define APIC_BUS_CYCLE_NS 1 =20 @@ -17412,10 +18080,11 @@ diff -urNp linux-3.1.4/arch/x86/kvm/lapic.c lin= ux-3.1.4/arch/x86/kvm/lapic.c =20 #define APIC_LVT_NUM 6 /* 14 is the version for Xeon and Pentium 8.4.8*/ -diff -urNp linux-3.1.4/arch/x86/kvm/mmu.c linux-3.1.4/arch/x86/kvm/mmu.c ---- linux-3.1.4/arch/x86/kvm/mmu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kvm/mmu.c 2011-11-16 18:39:07.000000000 -0500 -@@ -3552,7 +3552,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu * +diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c +index 8e8da79..13bc641 100644 +--- a/arch/x86/kvm/mmu.c ++++ b/arch/x86/kvm/mmu.c +@@ -3552,7 +3552,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu *vcpu, gpa_= t gpa, =20 pgprintk("%s: gpa %llx bytes %d\n", __func__, gpa, bytes); =20 @@ -17424,7 +18093,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/mmu.c linux-3= .1.4/arch/x86/kvm/mmu.c =20 /* * Assume that the pte write on a page table of the same type -@@ -3584,7 +3584,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu * +@@ -3584,7 +3584,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu *vcpu, gpa_= t gpa, } =20 spin_lock(&vcpu->kvm->mmu_lock); @@ -17433,9 +18102,10 @@ diff -urNp linux-3.1.4/arch/x86/kvm/mmu.c linux-= 3.1.4/arch/x86/kvm/mmu.c gentry =3D 0; kvm_mmu_free_some_pages(vcpu); ++vcpu->kvm->stat.mmu_pte_write; -diff -urNp linux-3.1.4/arch/x86/kvm/paging_tmpl.h linux-3.1.4/arch/x86/k= vm/paging_tmpl.h ---- linux-3.1.4/arch/x86/kvm/paging_tmpl.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/kvm/paging_tmpl.h 2011-11-16 19:40:44.000000000= -0500 +diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h +index 507e2b8..fc55f89 100644 +--- a/arch/x86/kvm/paging_tmpl.h ++++ b/arch/x86/kvm/paging_tmpl.h @@ -197,7 +197,7 @@ retry_walk: if (unlikely(kvm_is_error_hva(host_addr))) goto error; @@ -17445,7 +18115,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/paging_tmpl.h= linux-3.1.4/arch/x86/kvm/pagin if (unlikely(__copy_from_user(&pte, ptep_user, sizeof(pte)))) goto error; =20 -@@ -575,6 +575,8 @@ static int FNAME(page_fault)(struct kvm_ +@@ -575,6 +575,8 @@ static int FNAME(page_fault)(struct kvm_vcpu *vcpu, = gva_t addr, u32 error_code, unsigned long mmu_seq; bool map_writable; =20 @@ -17454,7 +18124,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/paging_tmpl.h= linux-3.1.4/arch/x86/kvm/pagin pgprintk("%s: addr %lx err %x\n", __func__, addr, error_code); =20 if (unlikely(error_code & PFERR_RSVD_MASK)) -@@ -701,7 +703,7 @@ static void FNAME(invlpg)(struct kvm_vcp +@@ -701,7 +703,7 @@ static void FNAME(invlpg)(struct kvm_vcpu *vcpu, gva= _t gva) if (need_flush) kvm_flush_remote_tlbs(vcpu->kvm); =20 @@ -17463,10 +18133,11 @@ diff -urNp linux-3.1.4/arch/x86/kvm/paging_tmpl= .h linux-3.1.4/arch/x86/kvm/pagin =20 spin_unlock(&vcpu->kvm->mmu_lock); =20 -diff -urNp linux-3.1.4/arch/x86/kvm/svm.c linux-3.1.4/arch/x86/kvm/svm.c ---- linux-3.1.4/arch/x86/kvm/svm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kvm/svm.c 2011-11-16 18:39:07.000000000 -0500 -@@ -3381,7 +3381,11 @@ static void reload_tss(struct kvm_vcpu * +diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c +index 475d1c9..33658ff 100644 +--- a/arch/x86/kvm/svm.c ++++ b/arch/x86/kvm/svm.c +@@ -3381,7 +3381,11 @@ static void reload_tss(struct kvm_vcpu *vcpu) int cpu =3D raw_smp_processor_id(); =20 struct svm_cpu_data *sd =3D per_cpu(svm_data, cpu); @@ -17478,7 +18149,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/svm.c linux-3= .1.4/arch/x86/kvm/svm.c load_TR_desc(); } =20 -@@ -3759,6 +3763,10 @@ static void svm_vcpu_run(struct kvm_vcpu +@@ -3759,6 +3763,10 @@ static void svm_vcpu_run(struct kvm_vcpu *vcpu) #endif #endif =20 @@ -17489,9 +18160,10 @@ diff -urNp linux-3.1.4/arch/x86/kvm/svm.c linux-= 3.1.4/arch/x86/kvm/svm.c reload_tss(vcpu); =20 local_irq_disable(); -diff -urNp linux-3.1.4/arch/x86/kvm/vmx.c linux-3.1.4/arch/x86/kvm/vmx.c ---- linux-3.1.4/arch/x86/kvm/vmx.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kvm/vmx.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c +index e65a158..656dc24 100644 +--- a/arch/x86/kvm/vmx.c ++++ b/arch/x86/kvm/vmx.c @@ -1251,7 +1251,11 @@ static void reload_tss(void) struct desc_struct *descs; =20 @@ -17518,7 +18190,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/vmx.c linux-3= .1.4/arch/x86/kvm/vmx.c =20 if (enable_ept && !cpu_has_vmx_ept_2m_page()) kvm_disable_largepages(); -@@ -3535,7 +3542,7 @@ static void vmx_set_constant_host_state( +@@ -3535,7 +3542,7 @@ static void vmx_set_constant_host_state(void) vmcs_writel(HOST_IDTR_BASE, dt.address); /* 22.2.4 */ =20 asm("mov $.Lkvm_vmx_return, %0" : "=3Dr"(tmpl)); @@ -17527,7 +18199,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/vmx.c linux-3= .1.4/arch/x86/kvm/vmx.c =20 rdmsr(MSR_IA32_SYSENTER_CS, low32, high32); vmcs_write32(HOST_IA32_SYSENTER_CS, low32); -@@ -6021,6 +6028,12 @@ static void __noclone vmx_vcpu_run(struc +@@ -6021,6 +6028,12 @@ static void __noclone vmx_vcpu_run(struct kvm_vcp= u *vcpu) "jmp .Lkvm_vmx_return \n\t" ".Llaunched: " __ex(ASM_VMX_VMRESUME) "\n\t" ".Lkvm_vmx_return: " @@ -17540,7 +18212,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/vmx.c linux-3= .1.4/arch/x86/kvm/vmx.c /* Save guest registers, load host registers, keep flags */ "mov %0, %c[wordsize](%%"R"sp) \n\t" "pop %0 \n\t" -@@ -6069,6 +6082,11 @@ static void __noclone vmx_vcpu_run(struc +@@ -6069,6 +6082,11 @@ static void __noclone vmx_vcpu_run(struct kvm_vcp= u *vcpu) #endif [cr2]"i"(offsetof(struct vcpu_vmx, vcpu.arch.cr2)), [wordsize]"i"(sizeof(ulong)) @@ -17552,7 +18224,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/vmx.c linux-3= .1.4/arch/x86/kvm/vmx.c : "cc", "memory" , R"ax", R"bx", R"di", R"si" #ifdef CONFIG_X86_64 -@@ -6097,7 +6115,16 @@ static void __noclone vmx_vcpu_run(struc +@@ -6097,7 +6115,16 @@ static void __noclone vmx_vcpu_run(struct kvm_vcp= u *vcpu) } } =20 @@ -17570,10 +18242,11 @@ diff -urNp linux-3.1.4/arch/x86/kvm/vmx.c linux= -3.1.4/arch/x86/kvm/vmx.c vmx->loaded_vmcs->launched =3D 1; =20 vmx->exit_reason =3D vmcs_read32(VM_EXIT_REASON); -diff -urNp linux-3.1.4/arch/x86/kvm/x86.c linux-3.1.4/arch/x86/kvm/x86.c ---- linux-3.1.4/arch/x86/kvm/x86.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/kvm/x86.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1334,8 +1334,8 @@ static int xen_hvm_config(struct kvm_vcp +diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c +index 84a28ea..9326501 100644 +--- a/arch/x86/kvm/x86.c ++++ b/arch/x86/kvm/x86.c +@@ -1334,8 +1334,8 @@ static int xen_hvm_config(struct kvm_vcpu *vcpu, u= 64 data) { struct kvm *kvm =3D vcpu->kvm; int lm =3D is_long_mode(vcpu); @@ -17584,7 +18257,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/x86.c linux-3= .1.4/arch/x86/kvm/x86.c u8 blob_size =3D lm ? kvm->arch.xen_hvm_config.blob_size_64 : kvm->arch.xen_hvm_config.blob_size_32; u32 page_num =3D data & ~PAGE_MASK; -@@ -2137,6 +2137,8 @@ long kvm_arch_dev_ioctl(struct file *fil +@@ -2137,6 +2137,8 @@ long kvm_arch_dev_ioctl(struct file *filp, if (n < msr_list.nmsrs) goto out; r =3D -EFAULT; @@ -17593,7 +18266,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/x86.c linux-3= .1.4/arch/x86/kvm/x86.c if (copy_to_user(user_msr_list->indices, &msrs_to_save, num_msrs_to_save * sizeof(u32))) goto out; -@@ -2312,15 +2314,20 @@ static int kvm_vcpu_ioctl_set_cpuid2(str +@@ -2312,15 +2314,20 @@ static int kvm_vcpu_ioctl_set_cpuid2(struct kvm_= vcpu *vcpu, struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 __user *entries) { @@ -17617,7 +18290,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/x86.c linux-3= .1.4/arch/x86/kvm/x86.c vcpu->arch.cpuid_nent =3D cpuid->nent; kvm_apic_set_version(vcpu); kvm_x86_ops->cpuid_update(vcpu); -@@ -2335,15 +2342,19 @@ static int kvm_vcpu_ioctl_get_cpuid2(str +@@ -2335,15 +2342,19 @@ static int kvm_vcpu_ioctl_get_cpuid2(struct kvm_= vcpu *vcpu, struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 __user *entries) { @@ -17640,7 +18313,7 @@ diff -urNp linux-3.1.4/arch/x86/kvm/x86.c linux-3= .1.4/arch/x86/kvm/x86.c return 0; =20 out: -@@ -2718,7 +2729,7 @@ static int kvm_vcpu_ioctl_set_lapic(stru +@@ -2718,7 +2729,7 @@ static int kvm_vcpu_ioctl_set_lapic(struct kvm_vcp= u *vcpu, static int kvm_vcpu_ioctl_interrupt(struct kvm_vcpu *vcpu, struct kvm_interrupt *irq) { @@ -17658,10 +18331,11 @@ diff -urNp linux-3.1.4/arch/x86/kvm/x86.c linux= -3.1.4/arch/x86/kvm/x86.c { int r; struct kvm_x86_ops *ops =3D (struct kvm_x86_ops *)opaque; -diff -urNp linux-3.1.4/arch/x86/lguest/boot.c linux-3.1.4/arch/x86/lgues= t/boot.c ---- linux-3.1.4/arch/x86/lguest/boot.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/lguest/boot.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -1184,9 +1184,10 @@ static __init int early_put_chars(u32 vt +diff --git a/arch/x86/lguest/boot.c b/arch/x86/lguest/boot.c +index 13ee258..b9632f6 100644 +--- a/arch/x86/lguest/boot.c ++++ b/arch/x86/lguest/boot.c +@@ -1184,9 +1184,10 @@ static __init int early_put_chars(u32 vtermno, co= nst char *buf, int count) * Rebooting also tells the Host we're finished, but the RESTART flag t= ells the * Launcher to reboot us. */ @@ -17673,9 +18347,10 @@ diff -urNp linux-3.1.4/arch/x86/lguest/boot.c li= nux-3.1.4/arch/x86/lguest/boot.c } =20 /*G:050 -diff -urNp linux-3.1.4/arch/x86/lib/atomic64_32.c linux-3.1.4/arch/x86/l= ib/atomic64_32.c ---- linux-3.1.4/arch/x86/lib/atomic64_32.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/lib/atomic64_32.c 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/x86/lib/atomic64_32.c b/arch/x86/lib/atomic64_32.c +index 042f682..c92afb6 100644 +--- a/arch/x86/lib/atomic64_32.c ++++ b/arch/x86/lib/atomic64_32.c @@ -8,18 +8,30 @@ =20 long long atomic64_read_cx8(long long, const atomic64_t *v); @@ -17754,9 +18429,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/atomic64_32.= c linux-3.1.4/arch/x86/lib/atomi long long atomic64_dec_if_positive_386(atomic64_t *v); EXPORT_SYMBOL(atomic64_dec_if_positive_386); int atomic64_inc_not_zero_386(atomic64_t *v); -diff -urNp linux-3.1.4/arch/x86/lib/atomic64_386_32.S linux-3.1.4/arch/x= 86/lib/atomic64_386_32.S ---- linux-3.1.4/arch/x86/lib/atomic64_386_32.S 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/lib/atomic64_386_32.S 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/x86/lib/atomic64_386_32.S b/arch/x86/lib/atomic64_386_= 32.S +index e8e7e0d..56fd1b0 100644 +--- a/arch/x86/lib/atomic64_386_32.S ++++ b/arch/x86/lib/atomic64_386_32.S @@ -48,6 +48,10 @@ BEGIN(read) movl (v), %eax movl 4(v), %edx @@ -18012,9 +18688,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/atomic64_386= _32.S linux-3.1.4/arch/x86/lib/a js 1f movl %eax, (v) movl %edx, 4(v) -diff -urNp linux-3.1.4/arch/x86/lib/atomic64_cx8_32.S linux-3.1.4/arch/x= 86/lib/atomic64_cx8_32.S ---- linux-3.1.4/arch/x86/lib/atomic64_cx8_32.S 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/lib/atomic64_cx8_32.S 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/x86/lib/atomic64_cx8_32.S b/arch/x86/lib/atomic64_cx8_= 32.S +index 391a083..d658e9f 100644 +--- a/arch/x86/lib/atomic64_cx8_32.S ++++ b/arch/x86/lib/atomic64_cx8_32.S @@ -35,10 +35,20 @@ ENTRY(atomic64_read_cx8) CFI_STARTPROC =20 @@ -18236,9 +18913,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/atomic64_cx8= _32.S linux-3.1.4/arch/x86/lib/a ret 4: testl %edx, %edx -diff -urNp linux-3.1.4/arch/x86/lib/checksum_32.S linux-3.1.4/arch/x86/l= ib/checksum_32.S ---- linux-3.1.4/arch/x86/lib/checksum_32.S 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/lib/checksum_32.S 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/x86/lib/checksum_32.S b/arch/x86/lib/checksum_32.S +index 78d16a5..fbcf666 100644 +--- a/arch/x86/lib/checksum_32.S ++++ b/arch/x86/lib/checksum_32.S @@ -28,7 +28,8 @@ #include #include @@ -18249,7 +18927,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/checksum_32.S= linux-3.1.4/arch/x86/lib/check /* * computes a partial checksum, e.g. for TCP/UDP fragments */ -@@ -296,9 +297,24 @@ unsigned int csum_partial_copy_generic ( +@@ -296,9 +297,24 @@ unsigned int csum_partial_copy_generic (const char = *src, char *dst, =20 #define ARGBASE 16 =09 #define FP 12 @@ -18483,9 +19161,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/checksum_32.= S linux-3.1.4/arch/x86/lib/check =09 #undef ROUND #undef ROUND1 =09 -diff -urNp linux-3.1.4/arch/x86/lib/clear_page_64.S linux-3.1.4/arch/x86= /lib/clear_page_64.S ---- linux-3.1.4/arch/x86/lib/clear_page_64.S 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/lib/clear_page_64.S 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/lib/clear_page_64.S b/arch/x86/lib/clear_page_64.S +index f2145cf..cea889d 100644 +--- a/arch/x86/lib/clear_page_64.S ++++ b/arch/x86/lib/clear_page_64.S @@ -11,6 +11,7 @@ ENTRY(clear_page_c) movl $4096/8,%ecx xorl %eax,%eax @@ -18519,9 +19198,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/clear_page_6= 4.S linux-3.1.4/arch/x86/lib/cle 1: .byte 0xeb /* jmp */ .byte (clear_page_c - clear_page) - (2f - 1b) /* offset */ 2: .byte 0xeb /* jmp */ -diff -urNp linux-3.1.4/arch/x86/lib/cmpxchg16b_emu.S linux-3.1.4/arch/x8= 6/lib/cmpxchg16b_emu.S ---- linux-3.1.4/arch/x86/lib/cmpxchg16b_emu.S 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/lib/cmpxchg16b_emu.S 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/lib/cmpxchg16b_emu.S b/arch/x86/lib/cmpxchg16b_emu= .S +index 1e572c5..2a162cd 100644 +--- a/arch/x86/lib/cmpxchg16b_emu.S ++++ b/arch/x86/lib/cmpxchg16b_emu.S @@ -53,11 +53,13 @@ this_cpu_cmpxchg16b_emu: =20 popf @@ -18536,9 +19216,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/cmpxchg16b_e= mu.S linux-3.1.4/arch/x86/lib/cm ret =20 CFI_ENDPROC -diff -urNp linux-3.1.4/arch/x86/lib/copy_page_64.S linux-3.1.4/arch/x86/= lib/copy_page_64.S ---- linux-3.1.4/arch/x86/lib/copy_page_64.S 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/lib/copy_page_64.S 2011-12-02 17:38:47.00000000= 0 -0500 +diff --git a/arch/x86/lib/copy_page_64.S b/arch/x86/lib/copy_page_64.S +index 01c805b..dccb07f 100644 +--- a/arch/x86/lib/copy_page_64.S ++++ b/arch/x86/lib/copy_page_64.S @@ -9,6 +9,7 @@ copy_page_c: CFI_STARTPROC movl $4096/8,%ecx @@ -18600,9 +19281,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/copy_page_64= .S linux-3.1.4/arch/x86/lib/copy 1: .byte 0xeb /* jmp */ .byte (copy_page_c - copy_page) - (2f - 1b) /* offset */ 2: -diff -urNp linux-3.1.4/arch/x86/lib/copy_user_64.S linux-3.1.4/arch/x86/= lib/copy_user_64.S ---- linux-3.1.4/arch/x86/lib/copy_user_64.S 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/lib/copy_user_64.S 2011-12-02 17:38:47.00000000= 0 -0500 +diff --git a/arch/x86/lib/copy_user_64.S b/arch/x86/lib/copy_user_64.S +index 0248402..821c786 100644 +--- a/arch/x86/lib/copy_user_64.S ++++ b/arch/x86/lib/copy_user_64.S @@ -16,6 +16,7 @@ #include #include @@ -18719,9 +19401,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/copy_user_64= .S linux-3.1.4/arch/x86/lib/copy ret =20 .section .fixup,"ax" -diff -urNp linux-3.1.4/arch/x86/lib/copy_user_nocache_64.S linux-3.1.4/a= rch/x86/lib/copy_user_nocache_64.S ---- linux-3.1.4/arch/x86/lib/copy_user_nocache_64.S 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/x86/lib/copy_user_nocache_64.S 2011-12-02 17:38:47.= 000000000 -0500 +diff --git a/arch/x86/lib/copy_user_nocache_64.S b/arch/x86/lib/copy_use= r_nocache_64.S +index cb0c112..e3a6895 100644 +--- a/arch/x86/lib/copy_user_nocache_64.S ++++ b/arch/x86/lib/copy_user_nocache_64.S @@ -8,12 +8,14 @@ =20 #include @@ -18785,9 +19468,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/copy_user_no= cache_64.S linux-3.1.4/arch/x86/ ret =20 .section .fixup,"ax" -diff -urNp linux-3.1.4/arch/x86/lib/csum-copy_64.S linux-3.1.4/arch/x86/= lib/csum-copy_64.S ---- linux-3.1.4/arch/x86/lib/csum-copy_64.S 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/lib/csum-copy_64.S 2011-12-02 17:38:47.00000000= 0 -0500 +diff --git a/arch/x86/lib/csum-copy_64.S b/arch/x86/lib/csum-copy_64.S +index fb903b7..c92b7f7 100644 +--- a/arch/x86/lib/csum-copy_64.S ++++ b/arch/x86/lib/csum-copy_64.S @@ -8,6 +8,7 @@ #include #include @@ -18804,10 +19488,11 @@ diff -urNp linux-3.1.4/arch/x86/lib/csum-copy_6= 4.S linux-3.1.4/arch/x86/lib/csum ret CFI_RESTORE_STATE =20 -diff -urNp linux-3.1.4/arch/x86/lib/csum-wrappers_64.c linux-3.1.4/arch/= x86/lib/csum-wrappers_64.c ---- linux-3.1.4/arch/x86/lib/csum-wrappers_64.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/arch/x86/lib/csum-wrappers_64.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -52,7 +52,13 @@ csum_partial_copy_from_user(const void _ +diff --git a/arch/x86/lib/csum-wrappers_64.c b/arch/x86/lib/csum-wrapper= s_64.c +index 459b58a..9570bc7 100644 +--- a/arch/x86/lib/csum-wrappers_64.c ++++ b/arch/x86/lib/csum-wrappers_64.c +@@ -52,7 +52,13 @@ csum_partial_copy_from_user(const void __user *src, v= oid *dst, len -=3D 2; } } @@ -18822,7 +19507,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/csum-wrappers= _64.c linux-3.1.4/arch/x86/lib/ dst, len, isum, errp, NULL); if (unlikely(*errp)) goto out_err; -@@ -105,7 +111,13 @@ csum_partial_copy_to_user(const void *sr +@@ -105,7 +111,13 @@ csum_partial_copy_to_user(const void *src, void __u= ser *dst, } =20 *errp =3D 0; @@ -18837,9 +19522,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/csum-wrapper= s_64.c linux-3.1.4/arch/x86/lib/ len, isum, NULL, errp); } EXPORT_SYMBOL(csum_partial_copy_to_user); -diff -urNp linux-3.1.4/arch/x86/lib/getuser.S linux-3.1.4/arch/x86/lib/g= etuser.S ---- linux-3.1.4/arch/x86/lib/getuser.S 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/lib/getuser.S 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/lib/getuser.S b/arch/x86/lib/getuser.S +index 51f1504..ddac4c1 100644 +--- a/arch/x86/lib/getuser.S ++++ b/arch/x86/lib/getuser.S @@ -33,15 +33,38 @@ #include #include @@ -18963,9 +19649,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/getuser.S li= nux-3.1.4/arch/x86/lib/getuser.S ret CFI_ENDPROC END(bad_get_user) -diff -urNp linux-3.1.4/arch/x86/lib/insn.c linux-3.1.4/arch/x86/lib/insn= .c ---- linux-3.1.4/arch/x86/lib/insn.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/lib/insn.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/lib/insn.c b/arch/x86/lib/insn.c +index 9f33b98..dfc7678 100644 +--- a/arch/x86/lib/insn.c ++++ b/arch/x86/lib/insn.c @@ -21,6 +21,11 @@ #include #include @@ -18989,9 +19676,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/insn.c linux= -3.1.4/arch/x86/lib/insn.c insn->x86_64 =3D x86_64 ? 1 : 0; insn->opnd_bytes =3D 4; if (x86_64) -diff -urNp linux-3.1.4/arch/x86/lib/iomap_copy_64.S linux-3.1.4/arch/x86= /lib/iomap_copy_64.S ---- linux-3.1.4/arch/x86/lib/iomap_copy_64.S 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/lib/iomap_copy_64.S 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/lib/iomap_copy_64.S b/arch/x86/lib/iomap_copy_64.S +index 05a95e7..326f2fa 100644 +--- a/arch/x86/lib/iomap_copy_64.S ++++ b/arch/x86/lib/iomap_copy_64.S @@ -17,6 +17,7 @@ =20 #include @@ -19008,9 +19696,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/iomap_copy_6= 4.S linux-3.1.4/arch/x86/lib/iom ret CFI_ENDPROC ENDPROC(__iowrite32_copy) -diff -urNp linux-3.1.4/arch/x86/lib/memcpy_64.S linux-3.1.4/arch/x86/lib= /memcpy_64.S ---- linux-3.1.4/arch/x86/lib/memcpy_64.S 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/lib/memcpy_64.S 2011-12-02 17:38:47.000000000 -= 0500 +diff --git a/arch/x86/lib/memcpy_64.S b/arch/x86/lib/memcpy_64.S +index efbf2a0..8893637 100644 +--- a/arch/x86/lib/memcpy_64.S ++++ b/arch/x86/lib/memcpy_64.S @@ -34,6 +34,7 @@ rep movsq movl %edx, %ecx @@ -19098,9 +19787,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/memcpy_64.S = linux-3.1.4/arch/x86/lib/memcpy_ retq CFI_ENDPROC ENDPROC(memcpy) -diff -urNp linux-3.1.4/arch/x86/lib/memmove_64.S linux-3.1.4/arch/x86/li= b/memmove_64.S ---- linux-3.1.4/arch/x86/lib/memmove_64.S 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/lib/memmove_64.S 2011-12-02 17:38:47.000000000 = -0500 +diff --git a/arch/x86/lib/memmove_64.S b/arch/x86/lib/memmove_64.S +index ee16461..c39c199 100644 +--- a/arch/x86/lib/memmove_64.S ++++ b/arch/x86/lib/memmove_64.S @@ -61,13 +61,13 @@ ENTRY(memmove) 5: sub $0x20, %rdx @@ -19229,9 +19919,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/memmove_64.S= linux-3.1.4/arch/x86/lib/memmov retq .Lmemmove_end_forward_efs: .previous -diff -urNp linux-3.1.4/arch/x86/lib/memset_64.S linux-3.1.4/arch/x86/lib= /memset_64.S ---- linux-3.1.4/arch/x86/lib/memset_64.S 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/lib/memset_64.S 2011-12-02 17:38:47.000000000 -= 0500 +diff --git a/arch/x86/lib/memset_64.S b/arch/x86/lib/memset_64.S +index 79bd454..dff325a 100644 +--- a/arch/x86/lib/memset_64.S ++++ b/arch/x86/lib/memset_64.S @@ -31,6 +31,7 @@ movl %r8d,%ecx rep stosb @@ -19273,10 +19964,11 @@ diff -urNp linux-3.1.4/arch/x86/lib/memset_64.S= linux-3.1.4/arch/x86/lib/memset_ ret =20 CFI_RESTORE_STATE -diff -urNp linux-3.1.4/arch/x86/lib/mmx_32.c linux-3.1.4/arch/x86/lib/mm= x_32.c ---- linux-3.1.4/arch/x86/lib/mmx_32.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/lib/mmx_32.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -29,6 +29,7 @@ void *_mmx_memcpy(void *to, const void * +diff --git a/arch/x86/lib/mmx_32.c b/arch/x86/lib/mmx_32.c +index c9f2d9b..e7fd2c0 100644 +--- a/arch/x86/lib/mmx_32.c ++++ b/arch/x86/lib/mmx_32.c +@@ -29,6 +29,7 @@ void *_mmx_memcpy(void *to, const void *from, size_t l= en) { void *p; int i; @@ -19284,7 +19976,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/mmx_32.c linu= x-3.1.4/arch/x86/lib/mmx_32.c =20 if (unlikely(in_interrupt())) return __memcpy(to, from, len); -@@ -39,44 +40,72 @@ void *_mmx_memcpy(void *to, const void * +@@ -39,44 +40,72 @@ void *_mmx_memcpy(void *to, const void *from, size_t= len) kernel_fpu_begin(); =20 __asm__ __volatile__ ( @@ -19391,7 +20083,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/mmx_32.c linu= x-3.1.4/arch/x86/lib/mmx_32.c =20 kernel_fpu_begin(); =20 -@@ -166,42 +196,70 @@ static void fast_copy_page(void *to, voi +@@ -166,42 +196,70 @@ static void fast_copy_page(void *to, void *from) * but that is for later. -AV */ __asm__ __volatile__( @@ -19591,9 +20283,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/mmx_32.c lin= ux-3.1.4/arch/x86/lib/mmx_32.c =20 from +=3D 64; to +=3D 64; -diff -urNp linux-3.1.4/arch/x86/lib/msr-reg.S linux-3.1.4/arch/x86/lib/m= sr-reg.S ---- linux-3.1.4/arch/x86/lib/msr-reg.S 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/lib/msr-reg.S 2011-12-02 17:38:47.000000000 -05= 00 +diff --git a/arch/x86/lib/msr-reg.S b/arch/x86/lib/msr-reg.S +index 69fa106..adda88b 100644 +--- a/arch/x86/lib/msr-reg.S ++++ b/arch/x86/lib/msr-reg.S @@ -3,6 +3,7 @@ #include #include @@ -19636,9 +20329,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/msr-reg.S li= nux-3.1.4/arch/x86/lib/msr-reg.S ret 3: CFI_RESTORE_STATE -diff -urNp linux-3.1.4/arch/x86/lib/putuser.S linux-3.1.4/arch/x86/lib/p= utuser.S ---- linux-3.1.4/arch/x86/lib/putuser.S 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/lib/putuser.S 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/lib/putuser.S b/arch/x86/lib/putuser.S +index 36b0d15..d381858 100644 +--- a/arch/x86/lib/putuser.S ++++ b/arch/x86/lib/putuser.S @@ -15,7 +15,9 @@ #include #include @@ -19778,9 +20472,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/putuser.S li= nux-3.1.4/arch/x86/lib/putuser.S #endif xor %eax,%eax EXIT -diff -urNp linux-3.1.4/arch/x86/lib/rwlock.S linux-3.1.4/arch/x86/lib/rw= lock.S ---- linux-3.1.4/arch/x86/lib/rwlock.S 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/lib/rwlock.S 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/arch/x86/lib/rwlock.S b/arch/x86/lib/rwlock.S +index 1cad221..6cc4b8d 100644 +--- a/arch/x86/lib/rwlock.S ++++ b/arch/x86/lib/rwlock.S @@ -23,6 +23,7 @@ ENTRY(__write_lock_failed) WRITE_LOCK_SUB($RW_LOCK_BIAS) (%__lock_ptr) jnz 0b @@ -19797,9 +20492,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/rwlock.S lin= ux-3.1.4/arch/x86/lib/rwlock.S ret CFI_ENDPROC END(__read_lock_failed) -diff -urNp linux-3.1.4/arch/x86/lib/rwsem.S linux-3.1.4/arch/x86/lib/rws= em.S ---- linux-3.1.4/arch/x86/lib/rwsem.S 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/lib/rwsem.S 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/lib/rwsem.S b/arch/x86/lib/rwsem.S +index 5dff5f0..cadebf4 100644 +--- a/arch/x86/lib/rwsem.S ++++ b/arch/x86/lib/rwsem.S @@ -94,6 +94,7 @@ ENTRY(call_rwsem_down_read_failed) __ASM_SIZE(pop,_cfi) %__ASM_REG(dx) CFI_RESTORE __ASM_REG(dx) @@ -19834,9 +20530,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/rwsem.S linu= x-3.1.4/arch/x86/lib/rwsem.S ret CFI_ENDPROC ENDPROC(call_rwsem_downgrade_wake) -diff -urNp linux-3.1.4/arch/x86/lib/thunk_64.S linux-3.1.4/arch/x86/lib/= thunk_64.S ---- linux-3.1.4/arch/x86/lib/thunk_64.S 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/lib/thunk_64.S 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/x86/lib/thunk_64.S b/arch/x86/lib/thunk_64.S +index a63efd6..ccecad8 100644 +--- a/arch/x86/lib/thunk_64.S ++++ b/arch/x86/lib/thunk_64.S @@ -8,6 +8,7 @@ #include #include @@ -19852,9 +20549,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/thunk_64.S l= inux-3.1.4/arch/x86/lib/thunk_64 + pax_force_retaddr ret CFI_ENDPROC -diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c linux-3.1.4/arch/x86/l= ib/usercopy_32.c ---- linux-3.1.4/arch/x86/lib/usercopy_32.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/lib/usercopy_32.c 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/x86/lib/usercopy_32.c b/arch/x86/lib/usercopy_32.c +index e218d5d..35679b4 100644 +--- a/arch/x86/lib/usercopy_32.c ++++ b/arch/x86/lib/usercopy_32.c @@ -43,7 +43,7 @@ do { \ __asm__ __volatile__( \ " testl %1,%1\n" \ @@ -19877,7 +20575,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc ".section .fixup,\"ax\"\n" \ "3: lea 0(%2,%0,4),%0\n" \ " jmp 2b\n" \ -@@ -200,6 +202,7 @@ long strnlen_user(const char __user *s,=20 +@@ -200,6 +202,7 @@ long strnlen_user(const char __user *s, long n) might_fault(); =20 __asm__ __volatile__( @@ -19885,7 +20583,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc " testl %0, %0\n" " jz 3f\n" " andl %0,%%ecx\n" -@@ -208,6 +211,7 @@ long strnlen_user(const char __user *s,=20 +@@ -208,6 +211,7 @@ long strnlen_user(const char __user *s, long n) " subl %%ecx,%0\n" " addl %0,%%eax\n" "1:\n" @@ -19902,7 +20600,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc { int d0, d1; __asm__ __volatile__( -@@ -239,36 +243,36 @@ __copy_user_intel(void __user *to, const +@@ -239,36 +243,36 @@ __copy_user_intel(void __user *to, const void *fro= m, unsigned long size) " .align 2,0x90\n" "3: movl 0(%4), %%eax\n" "4: movl 4(%4), %%edx\n" @@ -19955,7 +20653,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc " addl $-64, %0\n" " addl $64, %4\n" " addl $64, %3\n" -@@ -278,10 +282,119 @@ __copy_user_intel(void __user *to, const +@@ -278,10 +282,119 @@ __copy_user_intel(void __user *to, const void *fr= om, unsigned long size) " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -20075,7 +20773,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc ".section .fixup,\"ax\"\n" "101: lea 0(%%eax,%0,4),%0\n" " jmp 100b\n" -@@ -339,41 +452,41 @@ __copy_user_zeroing_intel(void *to, cons +@@ -339,41 +452,41 @@ __copy_user_zeroing_intel(void *to, const void __u= ser *from, unsigned long size) int d0, d1; __asm__ __volatile__( " .align 2,0x90\n" @@ -20135,7 +20833,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc " movl %%eax, 56(%3)\n" " movl %%edx, 60(%3)\n" " addl $-64, %0\n" -@@ -385,9 +498,9 @@ __copy_user_zeroing_intel(void *to, cons +@@ -385,9 +498,9 @@ __copy_user_zeroing_intel(void *to, const void __use= r *from, unsigned long size) " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -20147,7 +20845,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc "8:\n" ".section .fixup,\"ax\"\n" "9: lea 0(%%eax,%0,4),%0\n" -@@ -440,41 +553,41 @@ static unsigned long __copy_user_zeroing +@@ -440,41 +553,41 @@ static unsigned long __copy_user_zeroing_intel_noc= ache(void *to, =20 __asm__ __volatile__( " .align 2,0x90\n" @@ -20207,7 +20905,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc " movnti %%eax, 56(%3)\n" " movnti %%edx, 60(%3)\n" " addl $-64, %0\n" -@@ -487,9 +600,9 @@ static unsigned long __copy_user_zeroing +@@ -487,9 +600,9 @@ static unsigned long __copy_user_zeroing_intel_nocac= he(void *to, " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -20219,7 +20917,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc "8:\n" ".section .fixup,\"ax\"\n" "9: lea 0(%%eax,%0,4),%0\n" -@@ -537,41 +650,41 @@ static unsigned long __copy_user_intel_n +@@ -537,41 +650,41 @@ static unsigned long __copy_user_intel_nocache(voi= d *to, =20 __asm__ __volatile__( " .align 2,0x90\n" @@ -20279,7 +20977,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc " movnti %%eax, 56(%3)\n" " movnti %%edx, 60(%3)\n" " addl $-64, %0\n" -@@ -584,9 +697,9 @@ static unsigned long __copy_user_intel_n +@@ -584,9 +697,9 @@ static unsigned long __copy_user_intel_nocache(void = *to, " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -20291,7 +20989,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc "8:\n" ".section .fixup,\"ax\"\n" "9: lea 0(%%eax,%0,4),%0\n" -@@ -629,32 +742,36 @@ static unsigned long __copy_user_intel_n +@@ -629,32 +742,36 @@ static unsigned long __copy_user_intel_nocache(voi= d *to, */ unsigned long __copy_user_zeroing_intel(void *to, const void __user *fr= om, unsigned long size); @@ -20363,7 +21061,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc return n; } EXPORT_SYMBOL(__copy_to_user_ll); -@@ -797,10 +914,9 @@ unsigned long __copy_from_user_ll_nozero +@@ -797,10 +914,9 @@ unsigned long __copy_from_user_ll_nozero(void *to, = const void __user *from, unsigned long n) { if (movsl_is_ok(to, from, n)) @@ -20376,7 +21074,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.c= linux-3.1.4/arch/x86/lib/userc return n; } EXPORT_SYMBOL(__copy_from_user_ll_nozero); -@@ -827,65 +943,50 @@ unsigned long __copy_from_user_ll_nocach +@@ -827,65 +943,50 @@ unsigned long __copy_from_user_ll_nocache_nozero(v= oid *to, const void __user *fr if (n > 64 && cpu_has_xmm2) n =3D __copy_user_intel_nocache(to, from, n); else @@ -20475,9 +21173,10 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_32.= c linux-3.1.4/arch/x86/lib/userc +} +EXPORT_SYMBOL(set_fs); +#endif -diff -urNp linux-3.1.4/arch/x86/lib/usercopy_64.c linux-3.1.4/arch/x86/l= ib/usercopy_64.c ---- linux-3.1.4/arch/x86/lib/usercopy_64.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/arch/x86/lib/usercopy_64.c 2011-11-16 18:39:07.000000000= -0500 +diff --git a/arch/x86/lib/usercopy_64.c b/arch/x86/lib/usercopy_64.c +index b7c2849..5ef0f95 100644 +--- a/arch/x86/lib/usercopy_64.c ++++ b/arch/x86/lib/usercopy_64.c @@ -42,6 +42,12 @@ long __strncpy_from_user(char *dst, const char __user *src, long count) { @@ -20491,7 +21190,7 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_64.c= linux-3.1.4/arch/x86/lib/userc __do_strncpy_from_user(dst, src, count, res); return res; } -@@ -65,6 +71,12 @@ unsigned long __clear_user(void __user * +@@ -65,6 +71,12 @@ unsigned long __clear_user(void __user *addr, unsigne= d long size) { long __d0; might_fault(); @@ -20536,34 +21235,11 @@ diff -urNp linux-3.1.4/arch/x86/lib/usercopy_64= .c linux-3.1.4/arch/x86/lib/userc { char c; unsigned zero_len; -diff -urNp linux-3.1.4/arch/x86/Makefile linux-3.1.4/arch/x86/Makefile ---- linux-3.1.4/arch/x86/Makefile 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/Makefile 2011-11-17 18:30:30.000000000 -0500 -@@ -46,6 +46,7 @@ else - UTS_MACHINE :=3D x86_64 - CHECKFLAGS +=3D -D__x86_64__ -m64 -=20 -+ biarch :=3D $(call cc-option,-m64) - KBUILD_AFLAGS +=3D -m64 - KBUILD_CFLAGS +=3D -m64 -=20 -@@ -195,3 +196,12 @@ define archhelp - echo ' FDARGS=3D"..." arguments for the booted ker= nel' - echo ' FDINITRD=3Dfile initrd for the booted kernel= ' - endef -+ -+define OLD_LD -+ -+*** ${VERSION}.${PATCHLEVEL} PaX kernels no longer build correctly with= old versions of binutils. -+*** Please upgrade your binutils to 2.18 or newer -+endef -+ -+archprepare: -+ $(if $(LDFLAGS_BUILD_ID),,$(error $(OLD_LD))) -diff -urNp linux-3.1.4/arch/x86/mm/extable.c linux-3.1.4/arch/x86/mm/ext= able.c ---- linux-3.1.4/arch/x86/mm/extable.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/mm/extable.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -8,7 +8,7 @@ int fixup_exception(struct pt_regs *regs +diff --git a/arch/x86/mm/extable.c b/arch/x86/mm/extable.c +index d0474ad..36e9257 100644 +--- a/arch/x86/mm/extable.c ++++ b/arch/x86/mm/extable.c +@@ -8,7 +8,7 @@ int fixup_exception(struct pt_regs *regs) const struct exception_table_entry *fixup; =20 #ifdef CONFIG_PNPBIOS @@ -20572,9 +21248,10 @@ diff -urNp linux-3.1.4/arch/x86/mm/extable.c lin= ux-3.1.4/arch/x86/mm/extable.c extern u32 pnp_bios_fault_eip, pnp_bios_fault_esp; extern u32 pnp_bios_is_utter_crap; pnp_bios_is_utter_crap =3D 1; -diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-3.1.4/arch/x86/mm/fault= .c ---- linux-3.1.4/arch/x86/mm/fault.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/mm/fault.c 2011-11-16 20:43:50.000000000 -0500 +diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c +index 0d17c8c..4f4764f 100644 +--- a/arch/x86/mm/fault.c ++++ b/arch/x86/mm/fault.c @@ -13,11 +13,18 @@ #include /* perf_sw_event */ #include /* hstate_index_to_shift */ @@ -20594,7 +21271,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c =20 /* * Page fault error code bits: -@@ -55,7 +62,7 @@ static inline int __kprobes notify_page_ +@@ -55,7 +62,7 @@ static inline int __kprobes notify_page_fault(struct p= t_regs *regs) int ret =3D 0; =20 /* kprobe_running() needs smp_processor_id() */ @@ -20603,7 +21280,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c preempt_disable(); if (kprobe_running() && kprobe_fault_handler(regs, 14)) ret =3D 1; -@@ -116,7 +123,10 @@ check_prefetch_opcode(struct pt_regs *re +@@ -116,7 +123,10 @@ check_prefetch_opcode(struct pt_regs *regs, unsigne= d char *instr, return !instr_lo || (instr_lo>>1) =3D=3D 1; case 0x00: /* Prefetch instruction is 0x0F0D or 0x0F18 */ @@ -20615,7 +21292,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c return 0; =20 *prefetch =3D (instr_lo =3D=3D 0xF) && -@@ -150,7 +160,10 @@ is_prefetch(struct pt_regs *regs, unsign +@@ -150,7 +160,10 @@ is_prefetch(struct pt_regs *regs, unsigned long err= or_code, unsigned long addr) while (instr < max_instr) { unsigned char opcode; =20 @@ -20627,7 +21304,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c break; =20 instr++; -@@ -181,6 +194,34 @@ force_sig_info_fault(int si_signo, int s +@@ -181,6 +194,34 @@ force_sig_info_fault(int si_signo, int si_code, uns= igned long address, force_sig_info(si_signo, &info, tsk); } =20 @@ -20700,7 +21377,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c =20 if (!ret) break; -@@ -277,6 +335,11 @@ static noinline __kprobes int vmalloc_fa +@@ -277,6 +335,11 @@ static noinline __kprobes int vmalloc_fault(unsigne= d long address) * an interrupt in the middle of a task switch.. */ pgd_paddr =3D read_cr3(); @@ -20712,7 +21389,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c pmd_k =3D vmalloc_sync_one(__va(pgd_paddr), address); if (!pmd_k) return -1; -@@ -372,7 +435,14 @@ static noinline __kprobes int vmalloc_fa +@@ -372,7 +435,14 @@ static noinline __kprobes int vmalloc_fault(unsigne= d long address) * happen within a race in page table update. In the later * case just flush: */ @@ -20727,7 +21404,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c pgd_ref =3D pgd_offset_k(address); if (pgd_none(*pgd_ref)) return -1; -@@ -534,7 +604,7 @@ static int is_errata93(struct pt_regs *r +@@ -534,7 +604,7 @@ static int is_errata93(struct pt_regs *regs, unsigne= d long address) static int is_errata100(struct pt_regs *regs, unsigned long address) { #ifdef CONFIG_X86_64 @@ -20736,7 +21413,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c return 1; #endif return 0; -@@ -561,7 +631,7 @@ static int is_f00f_bug(struct pt_regs *r +@@ -561,7 +631,7 @@ static int is_f00f_bug(struct pt_regs *regs, unsigne= d long address) } =20 static const char nx_warning[] =3D KERN_CRIT @@ -20745,7 +21422,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c =20 static void show_fault_oops(struct pt_regs *regs, unsigned long error_code, -@@ -570,14 +640,25 @@ show_fault_oops(struct pt_regs *regs, un +@@ -570,15 +640,26 @@ show_fault_oops(struct pt_regs *regs, unsigned lon= g error_code, if (!oops_may_print()) return; =20 @@ -20758,8 +21435,8 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c if (pte && pte_present(*pte) && !pte_exec(*pte)) - printk(nx_warning, current_uid()); + printk(nx_warning, current_uid(), current->comm, task_pid_nr(current= )); -+ } -+ + } +=20 +#ifdef CONFIG_PAX_KERNEXEC + if (init_mm.start_code <=3D address && address < init_mm.end_code) { + if (current->signal->curr_ip) @@ -20768,12 +21445,13 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linu= x-3.1.4/arch/x86/mm/fault.c + else + printk(KERN_ERR "PAX: %s:%d, uid/euid: %u/%u, attempted to modify ke= rnel code\n", + current->comm, task_pid_nr(current), current_uid(), current_euid(= )); - } ++ } +#endif -=20 ++ printk(KERN_ALERT "BUG: unable to handle kernel "); if (address < PAGE_SIZE) -@@ -733,6 +814,21 @@ __bad_area_nosemaphore(struct pt_regs *r + printk(KERN_CONT "NULL pointer dereference"); +@@ -733,6 +814,21 @@ __bad_area_nosemaphore(struct pt_regs *regs, unsign= ed long error_code, } #endif =20 @@ -20795,7 +21473,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c if (unlikely(show_unhandled_signals)) show_signal_msg(regs, error_code, address, tsk); =20 -@@ -829,7 +925,7 @@ do_sigbus(struct pt_regs *regs, unsigned +@@ -829,7 +925,7 @@ do_sigbus(struct pt_regs *regs, unsigned long error_= code, unsigned long address, if (fault & (VM_FAULT_HWPOISON|VM_FAULT_HWPOISON_LARGE)) { printk(KERN_ERR "MCE: Killing %s:%d due to hardware memory corruption fault at %lx\n", @@ -20804,7 +21482,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c code =3D BUS_MCEERR_AR; } #endif -@@ -884,6 +980,99 @@ static int spurious_fault_check(unsigned +@@ -884,6 +980,99 @@ static int spurious_fault_check(unsigned long error= _code, pte_t *pte) return 1; } =20 @@ -20914,7 +21592,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c if (error_code & PF_WRITE) { /* write, present and write, not present: */ if (unlikely(!(vma->vm_flags & VM_WRITE))) -@@ -989,19 +1181,33 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -989,19 +1181,33 @@ do_page_fault(struct pt_regs *regs, unsigned long= error_code) { struct vm_area_struct *vma; struct task_struct *tsk; @@ -20952,7 +21630,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linux-= 3.1.4/arch/x86/mm/fault.c /* * Detect and handle instructions that would cause a page fault for * both a tracked kernel page and a userspace page. -@@ -1061,7 +1267,7 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -1061,7 +1267,7 @@ do_page_fault(struct pt_regs *regs, unsigned long = error_code) * User-mode registers count as a user access even for any * potential system fault or CPU buglet: */ @@ -20997,13 +21675,13 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linu= x-3.1.4/arch/x86/mm/fault.c + if (unlikely(address + 65536 + 32 * sizeof(unsigned long) < task_pt_re= gs(tsk)->sp)) { + bad_area(regs, error_code, address); + return; - } ++ } + +#ifdef CONFIG_PAX_SEGMEXEC + if (unlikely((mm->pax_flags & MF_PAX_SEGMEXEC) && vma->vm_end - SEGMEX= EC_TASK_SIZE - 1 < address - SEGMEXEC_TASK_SIZE - 1)) { + bad_area(regs, error_code, address); + return; -+ } + } +#endif + if (unlikely(expand_stack(vma, address))) { @@ -21250,10 +21928,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/fault.c linu= x-3.1.4/arch/x86/mm/fault.c + + return ret ? -EFAULT : 0; +} -diff -urNp linux-3.1.4/arch/x86/mm/gup.c linux-3.1.4/arch/x86/mm/gup.c ---- linux-3.1.4/arch/x86/mm/gup.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/mm/gup.c 2011-11-16 18:39:07.000000000 -0500 -@@ -253,7 +253,7 @@ int __get_user_pages_fast(unsigned long=20 +diff --git a/arch/x86/mm/gup.c b/arch/x86/mm/gup.c +index ea30585..b5e1508 100644 +--- a/arch/x86/mm/gup.c ++++ b/arch/x86/mm/gup.c +@@ -253,7 +253,7 @@ int __get_user_pages_fast(unsigned long start, int n= r_pages, int write, addr =3D start; len =3D (unsigned long) nr_pages << PAGE_SHIFT; end =3D start + len; @@ -21262,10 +21941,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/gup.c linux-= 3.1.4/arch/x86/mm/gup.c (void __user *)start, len))) return 0; =20 -diff -urNp linux-3.1.4/arch/x86/mm/highmem_32.c linux-3.1.4/arch/x86/mm/= highmem_32.c ---- linux-3.1.4/arch/x86/mm/highmem_32.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/mm/highmem_32.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -44,7 +44,10 @@ void *kmap_atomic_prot(struct page *page +diff --git a/arch/x86/mm/highmem_32.c b/arch/x86/mm/highmem_32.c +index b499626..6fd1882 100644 +--- a/arch/x86/mm/highmem_32.c ++++ b/arch/x86/mm/highmem_32.c +@@ -44,7 +44,10 @@ void *kmap_atomic_prot(struct page *page, pgprot_t pr= ot) idx =3D type + KM_TYPE_NR*smp_processor_id(); vaddr =3D __fix_to_virt(FIX_KMAP_BEGIN + idx); BUG_ON(!pte_none(*(kmap_pte-idx))); @@ -21276,10 +21956,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/highmem_32.c= linux-3.1.4/arch/x86/mm/highmem_ =20 return (void *)vaddr; } -diff -urNp linux-3.1.4/arch/x86/mm/hugetlbpage.c linux-3.1.4/arch/x86/mm= /hugetlbpage.c ---- linux-3.1.4/arch/x86/mm/hugetlbpage.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/mm/hugetlbpage.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -266,13 +266,20 @@ static unsigned long hugetlb_get_unmappe +diff --git a/arch/x86/mm/hugetlbpage.c b/arch/x86/mm/hugetlbpage.c +index f581a18..29efd37 100644 +--- a/arch/x86/mm/hugetlbpage.c ++++ b/arch/x86/mm/hugetlbpage.c +@@ -266,13 +266,20 @@ static unsigned long hugetlb_get_unmapped_area_bot= tomup(struct file *file, struct hstate *h =3D hstate_file(file); struct mm_struct *mm =3D current->mm; struct vm_area_struct *vma; @@ -21339,7 +22020,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/hugetlbpage.c = linux-3.1.4/arch/x86/mm/hugetlb } =20 static unsigned long hugetlb_get_unmapped_area_topdown(struct file *fil= e, -@@ -308,10 +316,9 @@ static unsigned long hugetlb_get_unmappe +@@ -308,10 +316,9 @@ static unsigned long hugetlb_get_unmapped_area_topd= own(struct file *file, { struct hstate *h =3D hstate_file(file); struct mm_struct *mm =3D current->mm; @@ -21352,7 +22033,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/hugetlbpage.c = linux-3.1.4/arch/x86/mm/hugetlb =20 /* don't allow allocations above current base */ if (mm->free_area_cache > base) -@@ -321,64 +328,63 @@ static unsigned long hugetlb_get_unmappe +@@ -321,64 +328,63 @@ static unsigned long hugetlb_get_unmapped_area_top= down(struct file *file, largest_hole =3D 0; mm->free_area_cache =3D base; } @@ -21455,7 +22136,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/hugetlbpage.c = linux-3.1.4/arch/x86/mm/hugetlb mm->free_area_cache =3D base; mm->cached_hole_size =3D ~0UL; =20 -@@ -399,10 +406,19 @@ hugetlb_get_unmapped_area(struct file *f +@@ -399,10 +406,19 @@ hugetlb_get_unmapped_area(struct file *file, unsig= ned long addr, struct hstate *h =3D hstate_file(file); struct mm_struct *mm =3D current->mm; struct vm_area_struct *vma; @@ -21476,7 +22157,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/hugetlbpage.c = linux-3.1.4/arch/x86/mm/hugetlb return -ENOMEM; =20 if (flags & MAP_FIXED) { -@@ -414,8 +430,7 @@ hugetlb_get_unmapped_area(struct file *f +@@ -414,8 +430,7 @@ hugetlb_get_unmapped_area(struct file *file, unsigne= d long addr, if (addr) { addr =3D ALIGN(addr, huge_page_size(h)); vma =3D find_vma(mm, addr); @@ -21486,9 +22167,141 @@ diff -urNp linux-3.1.4/arch/x86/mm/hugetlbpage.= c linux-3.1.4/arch/x86/mm/hugetlb return addr; } if (mm->get_unmapped_area =3D=3D arch_get_unmapped_area) -diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linux-3.1.4/arch/x86/mm/ini= t_32.c ---- linux-3.1.4/arch/x86/mm/init_32.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/mm/init_32.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/arch/x86/mm/init.c b/arch/x86/mm/init.c +index 87488b9..7129f32 100644 +--- a/arch/x86/mm/init.c ++++ b/arch/x86/mm/init.c +@@ -31,7 +31,7 @@ int direct_gbpages + static void __init find_early_table_space(unsigned long end, int use_ps= e, + int use_gbpages) + { +- unsigned long puds, pmds, ptes, tables, start =3D 0, good_end =3D end; ++ unsigned long puds, pmds, ptes, tables, start =3D 0x100000, good_end =3D= end; + phys_addr_t base; +=20 + puds =3D (end + PUD_SIZE - 1) >> PUD_SHIFT; +@@ -312,8 +312,29 @@ unsigned long __init_refok init_memory_mapping(unsi= gned long start, + */ + int devmem_is_allowed(unsigned long pagenr) + { +- if (pagenr <=3D 256) ++#ifdef CONFIG_GRKERNSEC_KMEM ++ /* allow BDA */ ++ if (!pagenr) ++ return 1; ++ /* allow EBDA */ ++ if ((0x9f000 >> PAGE_SHIFT) =3D=3D pagenr) ++ return 1; ++#else ++ if (!pagenr) ++ return 1; ++#ifdef CONFIG_VM86 ++ if (pagenr < (ISA_START_ADDRESS >> PAGE_SHIFT)) ++ return 1; ++#endif ++#endif ++ ++ if ((ISA_START_ADDRESS >> PAGE_SHIFT) <=3D pagenr && pagenr < (ISA_END= _ADDRESS >> PAGE_SHIFT)) + return 1; ++#ifdef CONFIG_GRKERNSEC_KMEM ++ /* throw out everything else below 1MB */ ++ if (pagenr <=3D 256) ++ return 0; ++#endif + if (iomem_is_exclusive(pagenr << PAGE_SHIFT)) + return 0; + if (!page_is_ram(pagenr)) +@@ -372,6 +393,86 @@ void free_init_pages(char *what, unsigned long begi= n, unsigned long end) +=20 + void free_initmem(void) + { ++ ++#ifdef CONFIG_PAX_KERNEXEC ++#ifdef CONFIG_X86_32 ++ /* PaX: limit KERNEL_CS to actual size */ ++ unsigned long addr, limit; ++ struct desc_struct d; ++ int cpu; ++ ++ limit =3D paravirt_enabled() ? ktva_ktla(0xffffffff) : (unsigned long)= &_etext; ++ limit =3D (limit - 1UL) >> PAGE_SHIFT; ++ ++ memset(__LOAD_PHYSICAL_ADDR + PAGE_OFFSET, POISON_FREE_INITMEM, PAGE_S= IZE); ++ for (cpu =3D 0; cpu < NR_CPUS; cpu++) { ++ pack_descriptor(&d, get_desc_base(&get_cpu_gdt_table(cpu)[GDT_ENTRY_K= ERNEL_CS]), limit, 0x9B, 0xC); ++ write_gdt_entry(get_cpu_gdt_table(cpu), GDT_ENTRY_KERNEL_CS, &d, DESC= TYPE_S); ++ } ++ ++ /* PaX: make KERNEL_CS read-only */ ++ addr =3D PFN_ALIGN(ktla_ktva((unsigned long)&_text)); ++ if (!paravirt_enabled()) ++ set_memory_ro(addr, (PFN_ALIGN(_sdata) - addr) >> PAGE_SHIFT); ++/* ++ for (addr =3D ktla_ktva((unsigned long)&_text); addr < (unsigned long= )&_sdata; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); ++ } ++*/ ++#ifdef CONFIG_X86_PAE ++ set_memory_nx(PFN_ALIGN(__init_begin), (PFN_ALIGN(__init_end) - PFN_AL= IGN(__init_begin)) >> PAGE_SHIFT); ++/* ++ for (addr =3D (unsigned long)&__init_begin; addr < (unsigned long)&__i= nit_end; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask))= ); ++ } ++*/ ++#endif ++ ++#ifdef CONFIG_MODULES ++ set_memory_4k((unsigned long)MODULES_EXEC_VADDR, (MODULES_EXEC_END - M= ODULES_EXEC_VADDR) >> PAGE_SHIFT); ++#endif ++ ++#else ++ pgd_t *pgd; ++ pud_t *pud; ++ pmd_t *pmd; ++ unsigned long addr, end; ++ ++ /* PaX: make kernel code/rodata read-only, rest non-executable */ ++ for (addr =3D __START_KERNEL_map; addr < __START_KERNEL_map + KERNEL_I= MAGE_SIZE; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ if (!pmd_present(*pmd)) ++ continue; ++ if ((unsigned long)_text <=3D addr && addr < (unsigned long)_sdata) ++ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); ++ else ++ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask)= )); ++ } ++ ++ addr =3D (unsigned long)__va(__pa(__START_KERNEL_map)); ++ end =3D addr + KERNEL_IMAGE_SIZE; ++ for (; addr < end; addr +=3D PMD_SIZE) { ++ pgd =3D pgd_offset_k(addr); ++ pud =3D pud_offset(pgd, addr); ++ pmd =3D pmd_offset(pud, addr); ++ if (!pmd_present(*pmd)) ++ continue; ++ if ((unsigned long)__va(__pa(_text)) <=3D addr && addr < (unsigned lo= ng)__va(__pa(_sdata))) ++ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); ++ } ++#endif ++ ++ flush_tlb_all(); ++#endif ++ + free_init_pages("unused kernel memory", + (unsigned long)(&__init_begin), + (unsigned long)(&__init_end)); +diff --git a/arch/x86/mm/init_32.c b/arch/x86/mm/init_32.c +index 29f7c6d..b46b35b 100644 +--- a/arch/x86/mm/init_32.c ++++ b/arch/x86/mm/init_32.c @@ -74,36 +74,6 @@ static __init void *alloc_low_page(void) } =20 @@ -21526,7 +22339,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linu= x-3.1.4/arch/x86/mm/init_32.c * Create a page table and place a pointer to it in a middle page * directory entry: */ -@@ -123,13 +93,28 @@ static pte_t * __init one_page_table_ini +@@ -123,13 +93,28 @@ static pte_t * __init one_page_table_init(pmd_t *pm= d) page_table =3D (pte_t *)alloc_low_page(); =20 paravirt_alloc_pte(&init_mm, __pa(page_table) >> PAGE_SHIFT); @@ -21555,7 +22368,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linu= x-3.1.4/arch/x86/mm/init_32.c pmd_t * __init populate_extra_pmd(unsigned long vaddr) { int pgd_idx =3D pgd_index(vaddr); -@@ -203,6 +188,7 @@ page_table_range_init(unsigned long star +@@ -203,6 +188,7 @@ page_table_range_init(unsigned long start, unsigned = long end, pgd_t *pgd_base) int pgd_idx, pmd_idx; unsigned long vaddr; pgd_t *pgd; @@ -21563,7 +22376,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linu= x-3.1.4/arch/x86/mm/init_32.c pmd_t *pmd; pte_t *pte =3D NULL; =20 -@@ -212,8 +198,13 @@ page_table_range_init(unsigned long star +@@ -212,8 +198,13 @@ page_table_range_init(unsigned long start, unsigned= long end, pgd_t *pgd_base) pgd =3D pgd_base + pgd_idx; =20 for ( ; (pgd_idx < PTRS_PER_PGD) && (vaddr !=3D end); pgd++, pgd_idx++= ) { @@ -21579,7 +22392,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linu= x-3.1.4/arch/x86/mm/init_32.c for (; (pmd_idx < PTRS_PER_PMD) && (vaddr !=3D end); pmd++, pmd_idx++) { pte =3D page_table_kmap_check(one_page_table_init(pmd), -@@ -225,11 +216,20 @@ page_table_range_init(unsigned long star +@@ -225,11 +216,20 @@ page_table_range_init(unsigned long start, unsigne= d long end, pgd_t *pgd_base) } } =20 @@ -21604,7 +22417,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linu= x-3.1.4/arch/x86/mm/init_32.c } =20 /* -@@ -246,9 +246,10 @@ kernel_physical_mapping_init(unsigned lo +@@ -246,9 +246,10 @@ kernel_physical_mapping_init(unsigned long start, unsigned long last_map_addr =3D end; unsigned long start_pfn, end_pfn; pgd_t *pgd_base =3D swapper_pg_dir; @@ -21679,7 +22492,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linu= x-3.1.4/arch/x86/mm/init_32.c prot =3D PAGE_KERNEL_EXEC; =20 pages_4k++; -@@ -472,7 +473,7 @@ void __init native_pagetable_setup_start +@@ -472,7 +473,7 @@ void __init native_pagetable_setup_start(pgd_t *base= ) =20 pud =3D pud_offset(pgd, va); pmd =3D pmd_offset(pud, va); @@ -21688,7 +22501,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c linu= x-3.1.4/arch/x86/mm/init_32.c break; =20 pte =3D pte_offset_kernel(pmd, va); -@@ -524,12 +525,10 @@ void __init early_ioremap_page_table_ran +@@ -524,12 +525,10 @@ void __init early_ioremap_page_table_range_init(vo= id) =20 static void __init pagetable_init(void) { @@ -21763,10 +22576,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_32.c li= nux-3.1.4/arch/x86/mm/init_32.c set_pages_ro(virt_to_page(start), size >> PAGE_SHIFT); printk(KERN_INFO "Write protecting the kernel text: %luk\n", size >> 10); -diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linux-3.1.4/arch/x86/mm/ini= t_64.c ---- linux-3.1.4/arch/x86/mm/init_64.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/mm/init_64.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -75,7 +75,7 @@ early_param("gbpages", parse_direct_gbpa +diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c +index bbaaa00..16dffad 100644 +--- a/arch/x86/mm/init_64.c ++++ b/arch/x86/mm/init_64.c +@@ -75,7 +75,7 @@ early_param("gbpages", parse_direct_gbpages_on); * around without checking the pgd every time. */ =20 @@ -21775,7 +22589,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c EXPORT_SYMBOL_GPL(__supported_pte_mask); =20 int force_personality32; -@@ -108,12 +108,22 @@ void sync_global_pgds(unsigned long star +@@ -108,12 +108,22 @@ void sync_global_pgds(unsigned long start, unsigne= d long end) =20 for (address =3D start; address <=3D end; address +=3D PGDIR_SIZE) { const pgd_t *pgd_ref =3D pgd_offset_k(address); @@ -21798,7 +22612,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c list_for_each_entry(page, &pgd_list, lru) { pgd_t *pgd; spinlock_t *pgt_lock; -@@ -122,6 +132,7 @@ void sync_global_pgds(unsigned long star +@@ -122,6 +132,7 @@ void sync_global_pgds(unsigned long start, unsigned = long end) /* the pgt_lock only for Xen */ pgt_lock =3D &pgd_page_get_mm(page)->page_table_lock; spin_lock(pgt_lock); @@ -21806,7 +22620,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c =20 if (pgd_none(*pgd)) set_pgd(pgd, *pgd_ref); -@@ -129,7 +140,10 @@ void sync_global_pgds(unsigned long star +@@ -129,7 +140,10 @@ void sync_global_pgds(unsigned long start, unsigned= long end) BUG_ON(pgd_page_vaddr(*pgd) !=3D pgd_page_vaddr(*pgd_ref)); =20 @@ -21817,7 +22631,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c } spin_unlock(&pgd_lock); } -@@ -203,7 +217,9 @@ void set_pte_vaddr_pud(pud_t *pud_page,=20 +@@ -203,7 +217,9 @@ void set_pte_vaddr_pud(pud_t *pud_page, unsigned lon= g vaddr, pte_t new_pte) pmd =3D fill_pmd(pud, vaddr); pte =3D fill_pte(pmd, vaddr); =20 @@ -21827,7 +22641,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c =20 /* * It's enough to flush this one mapping. -@@ -262,14 +278,12 @@ static void __init __init_extra_mapping( +@@ -262,14 +278,12 @@ static void __init __init_extra_mapping(unsigned l= ong phys, unsigned long size, pgd =3D pgd_offset_k((unsigned long)__va(phys)); if (pgd_none(*pgd)) { pud =3D (pud_t *) spp_getpage(); @@ -21844,7 +22658,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c } pmd =3D pmd_offset(pud, phys); BUG_ON(!pmd_none(*pmd)); -@@ -330,7 +344,7 @@ static __ref void *alloc_low_page(unsign +@@ -330,7 +344,7 @@ static __ref void *alloc_low_page(unsigned long *phy= s) if (pfn >=3D pgt_buf_top) panic("alloc_low_page: ran out of memory"); =20 @@ -21853,7 +22667,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c clear_page(adr); *phys =3D pfn * PAGE_SIZE; return adr; -@@ -346,7 +360,7 @@ static __ref void *map_low_page(void *vi +@@ -346,7 +360,7 @@ static __ref void *map_low_page(void *virt) =20 phys =3D __pa(virt); left =3D phys & (PAGE_SIZE - 1); @@ -21886,7 +22700,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c linu= x-3.1.4/arch/x86/mm/init_64.c }; =20 struct vm_area_struct *get_gate_vma(struct mm_struct *mm) -@@ -888,7 +908,7 @@ int in_gate_area_no_mm(unsigned long add +@@ -888,7 +908,7 @@ int in_gate_area_no_mm(unsigned long addr) =20 const char *arch_vma_name(struct vm_area_struct *vma) { @@ -21895,140 +22709,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/init_64.c l= inux-3.1.4/arch/x86/mm/init_64.c return "[vdso]"; if (vma =3D=3D &gate_vma) return "[vsyscall]"; -diff -urNp linux-3.1.4/arch/x86/mm/init.c linux-3.1.4/arch/x86/mm/init.c ---- linux-3.1.4/arch/x86/mm/init.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/mm/init.c 2011-11-17 18:31:28.000000000 -0500 -@@ -31,7 +31,7 @@ int direct_gbpages - static void __init find_early_table_space(unsigned long end, int use_ps= e, - int use_gbpages) - { -- unsigned long puds, pmds, ptes, tables, start =3D 0, good_end =3D end; -+ unsigned long puds, pmds, ptes, tables, start =3D 0x100000, good_end =3D= end; - phys_addr_t base; -=20 - puds =3D (end + PUD_SIZE - 1) >> PUD_SHIFT; -@@ -312,8 +312,29 @@ unsigned long __init_refok init_memory_m - */ - int devmem_is_allowed(unsigned long pagenr) - { -- if (pagenr <=3D 256) -+#ifdef CONFIG_GRKERNSEC_KMEM -+ /* allow BDA */ -+ if (!pagenr) -+ return 1; -+ /* allow EBDA */ -+ if ((0x9f000 >> PAGE_SHIFT) =3D=3D pagenr) -+ return 1; -+#else -+ if (!pagenr) -+ return 1; -+#ifdef CONFIG_VM86 -+ if (pagenr < (ISA_START_ADDRESS >> PAGE_SHIFT)) -+ return 1; -+#endif -+#endif -+ -+ if ((ISA_START_ADDRESS >> PAGE_SHIFT) <=3D pagenr && pagenr < (ISA_END= _ADDRESS >> PAGE_SHIFT)) - return 1; -+#ifdef CONFIG_GRKERNSEC_KMEM -+ /* throw out everything else below 1MB */ -+ if (pagenr <=3D 256) -+ return 0; -+#endif - if (iomem_is_exclusive(pagenr << PAGE_SHIFT)) - return 0; - if (!page_is_ram(pagenr)) -@@ -372,6 +393,86 @@ void free_init_pages(char *what, unsigne -=20 - void free_initmem(void) - { -+ -+#ifdef CONFIG_PAX_KERNEXEC -+#ifdef CONFIG_X86_32 -+ /* PaX: limit KERNEL_CS to actual size */ -+ unsigned long addr, limit; -+ struct desc_struct d; -+ int cpu; -+ -+ limit =3D paravirt_enabled() ? ktva_ktla(0xffffffff) : (unsigned long)= &_etext; -+ limit =3D (limit - 1UL) >> PAGE_SHIFT; -+ -+ memset(__LOAD_PHYSICAL_ADDR + PAGE_OFFSET, POISON_FREE_INITMEM, PAGE_S= IZE); -+ for (cpu =3D 0; cpu < NR_CPUS; cpu++) { -+ pack_descriptor(&d, get_desc_base(&get_cpu_gdt_table(cpu)[GDT_ENTRY_K= ERNEL_CS]), limit, 0x9B, 0xC); -+ write_gdt_entry(get_cpu_gdt_table(cpu), GDT_ENTRY_KERNEL_CS, &d, DESC= TYPE_S); -+ } -+ -+ /* PaX: make KERNEL_CS read-only */ -+ addr =3D PFN_ALIGN(ktla_ktva((unsigned long)&_text)); -+ if (!paravirt_enabled()) -+ set_memory_ro(addr, (PFN_ALIGN(_sdata) - addr) >> PAGE_SHIFT); -+/* -+ for (addr =3D ktla_ktva((unsigned long)&_text); addr < (unsigned long= )&_sdata; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); -+ } -+*/ -+#ifdef CONFIG_X86_PAE -+ set_memory_nx(PFN_ALIGN(__init_begin), (PFN_ALIGN(__init_end) - PFN_AL= IGN(__init_begin)) >> PAGE_SHIFT); -+/* -+ for (addr =3D (unsigned long)&__init_begin; addr < (unsigned long)&__i= nit_end; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask))= ); -+ } -+*/ -+#endif -+ -+#ifdef CONFIG_MODULES -+ set_memory_4k((unsigned long)MODULES_EXEC_VADDR, (MODULES_EXEC_END - M= ODULES_EXEC_VADDR) >> PAGE_SHIFT); -+#endif -+ -+#else -+ pgd_t *pgd; -+ pud_t *pud; -+ pmd_t *pmd; -+ unsigned long addr, end; -+ -+ /* PaX: make kernel code/rodata read-only, rest non-executable */ -+ for (addr =3D __START_KERNEL_map; addr < __START_KERNEL_map + KERNEL_I= MAGE_SIZE; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ if (!pmd_present(*pmd)) -+ continue; -+ if ((unsigned long)_text <=3D addr && addr < (unsigned long)_sdata) -+ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); -+ else -+ set_pmd(pmd, __pmd(pmd_val(*pmd) | (_PAGE_NX & __supported_pte_mask)= )); -+ } -+ -+ addr =3D (unsigned long)__va(__pa(__START_KERNEL_map)); -+ end =3D addr + KERNEL_IMAGE_SIZE; -+ for (; addr < end; addr +=3D PMD_SIZE) { -+ pgd =3D pgd_offset_k(addr); -+ pud =3D pud_offset(pgd, addr); -+ pmd =3D pmd_offset(pud, addr); -+ if (!pmd_present(*pmd)) -+ continue; -+ if ((unsigned long)__va(__pa(_text)) <=3D addr && addr < (unsigned lo= ng)__va(__pa(_sdata))) -+ set_pmd(pmd, __pmd(pmd_val(*pmd) & ~_PAGE_RW)); -+ } -+#endif -+ -+ flush_tlb_all(); -+#endif -+ - free_init_pages("unused kernel memory", - (unsigned long)(&__init_begin), - (unsigned long)(&__init_end)); -diff -urNp linux-3.1.4/arch/x86/mm/iomap_32.c linux-3.1.4/arch/x86/mm/io= map_32.c ---- linux-3.1.4/arch/x86/mm/iomap_32.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/mm/iomap_32.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -64,7 +64,11 @@ void *kmap_atomic_prot_pfn(unsigned long +diff --git a/arch/x86/mm/iomap_32.c b/arch/x86/mm/iomap_32.c +index 7b179b4..6bd1777 100644 +--- a/arch/x86/mm/iomap_32.c ++++ b/arch/x86/mm/iomap_32.c +@@ -64,7 +64,11 @@ void *kmap_atomic_prot_pfn(unsigned long pfn, pgprot_= t prot) type =3D kmap_atomic_idx_push(); idx =3D type + KM_TYPE_NR * smp_processor_id(); vaddr =3D __fix_to_virt(FIX_KMAP_BEGIN + idx); @@ -22040,10 +22725,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/iomap_32.c l= inux-3.1.4/arch/x86/mm/iomap_32.c arch_flush_lazy_mmu_mode(); =20 return (void *)vaddr; -diff -urNp linux-3.1.4/arch/x86/mm/ioremap.c linux-3.1.4/arch/x86/mm/ior= emap.c ---- linux-3.1.4/arch/x86/mm/ioremap.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/mm/ioremap.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -97,7 +97,7 @@ static void __iomem *__ioremap_caller(re +diff --git a/arch/x86/mm/ioremap.c b/arch/x86/mm/ioremap.c +index be1ef57..9680edc 100644 +--- a/arch/x86/mm/ioremap.c ++++ b/arch/x86/mm/ioremap.c +@@ -97,7 +97,7 @@ static void __iomem *__ioremap_caller(resource_size_t = phys_addr, for (pfn =3D phys_addr >> PAGE_SHIFT; pfn <=3D last_pfn; pfn++) { int is_ram =3D page_is_ram(pfn); =20 @@ -22052,7 +22738,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/ioremap.c linu= x-3.1.4/arch/x86/mm/ioremap.c return NULL; WARN_ON_ONCE(is_ram); } -@@ -344,7 +344,7 @@ static int __init early_ioremap_debug_se +@@ -344,7 +344,7 @@ static int __init early_ioremap_debug_setup(char *st= r) early_param("early_ioremap_debug", early_ioremap_debug_setup); =20 static __initdata int after_paging_init; @@ -22071,10 +22757,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/ioremap.c li= nux-3.1.4/arch/x86/mm/ioremap.c =20 /* * The boot-ioremap range spans multiple pmds, for which -diff -urNp linux-3.1.4/arch/x86/mm/kmemcheck/kmemcheck.c linux-3.1.4/arc= h/x86/mm/kmemcheck/kmemcheck.c ---- linux-3.1.4/arch/x86/mm/kmemcheck/kmemcheck.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/arch/x86/mm/kmemcheck/kmemcheck.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -622,9 +622,9 @@ bool kmemcheck_fault(struct pt_regs *reg +diff --git a/arch/x86/mm/kmemcheck/kmemcheck.c b/arch/x86/mm/kmemcheck/k= memcheck.c +index d87dd6d..bf3fa66 100644 +--- a/arch/x86/mm/kmemcheck/kmemcheck.c ++++ b/arch/x86/mm/kmemcheck/kmemcheck.c +@@ -622,9 +622,9 @@ bool kmemcheck_fault(struct pt_regs *regs, unsigned = long address, * memory (e.g. tracked pages)? For now, we need this to avoid * invoking kmemcheck for PnP BIOS calls. */ @@ -22086,10 +22773,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/kmemcheck/km= emcheck.c linux-3.1.4/arch/x86/mm return false; =20 pte =3D kmemcheck_pte_lookup(address); -diff -urNp linux-3.1.4/arch/x86/mm/mmap.c linux-3.1.4/arch/x86/mm/mmap.c ---- linux-3.1.4/arch/x86/mm/mmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/mm/mmap.c 2011-11-16 18:39:07.000000000 -0500 -@@ -49,7 +49,7 @@ static unsigned int stack_maxrandom_size +diff --git a/arch/x86/mm/mmap.c b/arch/x86/mm/mmap.c +index 1dab519..60a7e5f 100644 +--- a/arch/x86/mm/mmap.c ++++ b/arch/x86/mm/mmap.c +@@ -49,7 +49,7 @@ static unsigned int stack_maxrandom_size(void) * Leave an at least ~128 MB hole with possible stack randomization. */ #define MIN_GAP (128*1024*1024UL + stack_maxrandom_size()) @@ -22144,7 +22832,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/mmap.c linux-3= .1.4/arch/x86/mm/mmap.c return TASK_UNMAPPED_BASE + mmap_rnd(); } =20 -@@ -125,11 +138,23 @@ static unsigned long mmap_legacy_base(vo +@@ -125,11 +138,23 @@ static unsigned long mmap_legacy_base(void) void arch_pick_mmap_layout(struct mm_struct *mm) { if (mmap_is_legacy()) { @@ -22170,10 +22858,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/mmap.c linux= -3.1.4/arch/x86/mm/mmap.c mm->get_unmapped_area =3D arch_get_unmapped_area_topdown; mm->unmap_area =3D arch_unmap_area_topdown; } -diff -urNp linux-3.1.4/arch/x86/mm/mmio-mod.c linux-3.1.4/arch/x86/mm/mm= io-mod.c ---- linux-3.1.4/arch/x86/mm/mmio-mod.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/mm/mmio-mod.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -195,7 +195,7 @@ static void pre(struct kmmio_probe *p, s +diff --git a/arch/x86/mm/mmio-mod.c b/arch/x86/mm/mmio-mod.c +index 67421f3..8d6b107 100644 +--- a/arch/x86/mm/mmio-mod.c ++++ b/arch/x86/mm/mmio-mod.c +@@ -195,7 +195,7 @@ static void pre(struct kmmio_probe *p, struct pt_reg= s *regs, break; default: { @@ -22182,7 +22871,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/mmio-mod.c lin= ux-3.1.4/arch/x86/mm/mmio-mod.c my_trace->opcode =3D MMIO_UNKNOWN_OP; my_trace->width =3D 0; my_trace->value =3D (*ip) << 16 | *(ip + 1) << 8 | -@@ -235,7 +235,7 @@ static void post(struct kmmio_probe *p,=20 +@@ -235,7 +235,7 @@ static void post(struct kmmio_probe *p, unsigned lon= g condition, static void ioremap_trace_core(resource_size_t offset, unsigned long si= ze, void __iomem *addr) { @@ -22191,7 +22880,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/mmio-mod.c lin= ux-3.1.4/arch/x86/mm/mmio-mod.c struct remap_trace *trace =3D kmalloc(sizeof(*trace), GFP_KERNEL); /* These are page-unaligned. */ struct mmiotrace_map map =3D { -@@ -259,7 +259,7 @@ static void ioremap_trace_core(resource_ +@@ -259,7 +259,7 @@ static void ioremap_trace_core(resource_size_t offse= t, unsigned long size, .private =3D trace }, .phys =3D offset, @@ -22200,10 +22889,24 @@ diff -urNp linux-3.1.4/arch/x86/mm/mmio-mod.c l= inux-3.1.4/arch/x86/mm/mmio-mod.c }; map.map_id =3D trace->id; =20 -diff -urNp linux-3.1.4/arch/x86/mm/pageattr.c linux-3.1.4/arch/x86/mm/pa= geattr.c ---- linux-3.1.4/arch/x86/mm/pageattr.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/mm/pageattr.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -261,7 +261,7 @@ static inline pgprot_t static_protection +diff --git a/arch/x86/mm/pageattr-test.c b/arch/x86/mm/pageattr-test.c +index b008656..773eac2 100644 +--- a/arch/x86/mm/pageattr-test.c ++++ b/arch/x86/mm/pageattr-test.c +@@ -36,7 +36,7 @@ enum { +=20 + static int pte_testbit(pte_t pte) + { +- return pte_flags(pte) & _PAGE_UNUSED1; ++ return pte_flags(pte) & _PAGE_CPA_TEST; + } +=20 + struct split_state { +diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c +index f9e5267..6f6e27f 100644 +--- a/arch/x86/mm/pageattr.c ++++ b/arch/x86/mm/pageattr.c +@@ -261,7 +261,7 @@ static inline pgprot_t static_protections(pgprot_t p= rot, unsigned long address, */ #ifdef CONFIG_PCI_BIOS if (pcibios_enabled && within(pfn, BIOS_BEGIN >> PAGE_SHIFT, BIOS_END = >> PAGE_SHIFT)) @@ -22212,7 +22915,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pageattr.c lin= ux-3.1.4/arch/x86/mm/pageattr.c #endif =20 /* -@@ -269,9 +269,10 @@ static inline pgprot_t static_protection +@@ -269,9 +269,10 @@ static inline pgprot_t static_protections(pgprot_t = prot, unsigned long address, * Does not cover __inittext since that is gone later on. On * 64bit we do not enforce !NX on the low mapping */ @@ -22225,7 +22928,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pageattr.c lin= ux-3.1.4/arch/x86/mm/pageattr.c /* * The .rodata section needs to be read-only. Using the pfn * catches all aliases. -@@ -279,6 +280,7 @@ static inline pgprot_t static_protection +@@ -279,6 +280,7 @@ static inline pgprot_t static_protections(pgprot_t p= rot, unsigned long address, if (within(pfn, __pa((unsigned long)__start_rodata) >> PAGE_SHIFT, __pa((unsigned long)__end_rodata) >> PAGE_SHIFT)) pgprot_val(forbidden) |=3D _PAGE_RW; @@ -22233,7 +22936,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pageattr.c lin= ux-3.1.4/arch/x86/mm/pageattr.c =20 #if defined(CONFIG_X86_64) && defined(CONFIG_DEBUG_RODATA) /* -@@ -317,6 +319,13 @@ static inline pgprot_t static_protection +@@ -317,6 +319,13 @@ static inline pgprot_t static_protections(pgprot_t = prot, unsigned long address, } #endif =20 @@ -22287,21 +22990,10 @@ diff -urNp linux-3.1.4/arch/x86/mm/pageattr.c l= inux-3.1.4/arch/x86/mm/pageattr.c } =20 static int -diff -urNp linux-3.1.4/arch/x86/mm/pageattr-test.c linux-3.1.4/arch/x86/= mm/pageattr-test.c ---- linux-3.1.4/arch/x86/mm/pageattr-test.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/mm/pageattr-test.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -36,7 +36,7 @@ enum { -=20 - static int pte_testbit(pte_t pte) - { -- return pte_flags(pte) & _PAGE_UNUSED1; -+ return pte_flags(pte) & _PAGE_CPA_TEST; - } -=20 - struct split_state { -diff -urNp linux-3.1.4/arch/x86/mm/pat.c linux-3.1.4/arch/x86/mm/pat.c ---- linux-3.1.4/arch/x86/mm/pat.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/mm/pat.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/mm/pat.c b/arch/x86/mm/pat.c +index f6ff57b..481690f 100644 +--- a/arch/x86/mm/pat.c ++++ b/arch/x86/mm/pat.c @@ -361,7 +361,7 @@ int free_memtype(u64 start, u64 end) =20 if (!entry) { @@ -22311,7 +23003,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pat.c linux-3.= 1.4/arch/x86/mm/pat.c return -EINVAL; } =20 -@@ -492,8 +492,8 @@ static inline int range_is_allowed(unsig +@@ -492,8 +492,8 @@ static inline int range_is_allowed(unsigned long pfn= , unsigned long size) while (cursor < to) { if (!devmem_is_allowed(pfn)) { printk(KERN_INFO @@ -22322,7 +23014,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pat.c linux-3.= 1.4/arch/x86/mm/pat.c return 0; } cursor +=3D PAGE_SIZE; -@@ -557,7 +557,7 @@ int kernel_map_sync_memtype(u64 base, un +@@ -557,7 +557,7 @@ int kernel_map_sync_memtype(u64 base, unsigned long = size, unsigned long flags) printk(KERN_INFO "%s:%d ioremap_change_attr failed %s " "for %Lx-%Lx\n", @@ -22331,7 +23023,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pat.c linux-3.= 1.4/arch/x86/mm/pat.c cattr_name(flags), base, (unsigned long long)(base + size)); return -EINVAL; -@@ -593,7 +593,7 @@ static int reserve_pfn_range(u64 paddr,=20 +@@ -593,7 +593,7 @@ static int reserve_pfn_range(u64 paddr, unsigned lon= g size, pgprot_t *vma_prot, if (want_flags !=3D flags) { printk(KERN_WARNING "%s:%d map pfn RAM range req %s for %Lx-%Lx, got %s\n", @@ -22340,7 +23032,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pat.c linux-3.= 1.4/arch/x86/mm/pat.c cattr_name(want_flags), (unsigned long long)paddr, (unsigned long long)(paddr + size), -@@ -615,7 +615,7 @@ static int reserve_pfn_range(u64 paddr,=20 +@@ -615,7 +615,7 @@ static int reserve_pfn_range(u64 paddr, unsigned lon= g size, pgprot_t *vma_prot, free_memtype(paddr, paddr + size); printk(KERN_ERR "%s:%d map pfn expected mapping type %s" " for %Lx-%Lx, got %s\n", @@ -22349,10 +23041,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/pat.c linux-= 3.1.4/arch/x86/mm/pat.c cattr_name(want_flags), (unsigned long long)paddr, (unsigned long long)(paddr + size), -diff -urNp linux-3.1.4/arch/x86/mm/pf_in.c linux-3.1.4/arch/x86/mm/pf_in= .c ---- linux-3.1.4/arch/x86/mm/pf_in.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/mm/pf_in.c 2011-11-16 18:39:07.000000000 -0500 -@@ -148,7 +148,7 @@ enum reason_type get_ins_type(unsigned l +diff --git a/arch/x86/mm/pf_in.c b/arch/x86/mm/pf_in.c +index 9f0614d..92ae64a 100644 +--- a/arch/x86/mm/pf_in.c ++++ b/arch/x86/mm/pf_in.c +@@ -148,7 +148,7 @@ enum reason_type get_ins_type(unsigned long ins_addr= ) int i; enum reason_type rv =3D OTHERS; =20 @@ -22361,7 +23054,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pf_in.c linux-= 3.1.4/arch/x86/mm/pf_in.c p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); =20 -@@ -168,7 +168,7 @@ static unsigned int get_ins_reg_width(un +@@ -168,7 +168,7 @@ static unsigned int get_ins_reg_width(unsigned long = ins_addr) struct prefix_bits prf; int i; =20 @@ -22370,7 +23063,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pf_in.c linux-= 3.1.4/arch/x86/mm/pf_in.c p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); =20 -@@ -191,7 +191,7 @@ unsigned int get_ins_mem_width(unsigned=20 +@@ -191,7 +191,7 @@ unsigned int get_ins_mem_width(unsigned long ins_add= r) struct prefix_bits prf; int i; =20 @@ -22379,7 +23072,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pf_in.c linux-= 3.1.4/arch/x86/mm/pf_in.c p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); =20 -@@ -415,7 +415,7 @@ unsigned long get_ins_reg_val(unsigned l +@@ -415,7 +415,7 @@ unsigned long get_ins_reg_val(unsigned long ins_addr= , struct pt_regs *regs) struct prefix_bits prf; int i; =20 @@ -22388,7 +23081,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pf_in.c linux-= 3.1.4/arch/x86/mm/pf_in.c p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); for (i =3D 0; i < ARRAY_SIZE(reg_rop); i++) -@@ -470,7 +470,7 @@ unsigned long get_ins_imm_val(unsigned l +@@ -470,7 +470,7 @@ unsigned long get_ins_imm_val(unsigned long ins_addr= ) struct prefix_bits prf; int i; =20 @@ -22397,27 +23090,11 @@ diff -urNp linux-3.1.4/arch/x86/mm/pf_in.c linu= x-3.1.4/arch/x86/mm/pf_in.c p +=3D skip_prefix(p, &prf); p +=3D get_opcode(p, &opcode); for (i =3D 0; i < ARRAY_SIZE(imm_wop); i++) -diff -urNp linux-3.1.4/arch/x86/mm/pgtable_32.c linux-3.1.4/arch/x86/mm/= pgtable_32.c ---- linux-3.1.4/arch/x86/mm/pgtable_32.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/mm/pgtable_32.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -48,10 +48,13 @@ void set_pte_vaddr(unsigned long vaddr,=20 - return; - } - pte =3D pte_offset_kernel(pmd, vaddr); -+ -+ pax_open_kernel(); - if (pte_val(pteval)) - set_pte_at(&init_mm, vaddr, pte, pteval); - else - pte_clear(&init_mm, vaddr, pte); -+ pax_close_kernel(); -=20 - /* - * It's enough to flush this one mapping. -diff -urNp linux-3.1.4/arch/x86/mm/pgtable.c linux-3.1.4/arch/x86/mm/pgt= able.c ---- linux-3.1.4/arch/x86/mm/pgtable.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/mm/pgtable.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -84,10 +84,52 @@ static inline void pgd_list_del(pgd_t *p +diff --git a/arch/x86/mm/pgtable.c b/arch/x86/mm/pgtable.c +index 8573b83..6372501 100644 +--- a/arch/x86/mm/pgtable.c ++++ b/arch/x86/mm/pgtable.c +@@ -84,10 +84,52 @@ static inline void pgd_list_del(pgd_t *pgd) list_del(&page->lru); } =20 @@ -22443,7 +23120,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pgtable.c linu= x-3.1.4/arch/x86/mm/pgtable.c +#else + *dst++ =3D *src++; +#endif -=20 ++ +} +#endif + @@ -22464,7 +23141,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pgtable.c linu= x-3.1.4/arch/x86/mm/pgtable.c +#define pyd_offset(mm ,address) pud_offset((mm), (address)) +#define PYD_SIZE PUD_SIZE +#endif -+ +=20 +#ifdef CONFIG_PAX_PER_CPU_PGD +static inline void pgd_ctor(struct mm_struct *mm, pgd_t *pgd) {} +static inline void pgd_dtor(pgd_t *pgd) {} @@ -22498,7 +23175,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pgtable.c linu= x-3.1.4/arch/x86/mm/pgtable.c =20 void pud_populate(struct mm_struct *mm, pud_t *pudp, pmd_t *pmd) { -@@ -170,36 +213,38 @@ void pud_populate(struct mm_struct *mm,=20 +@@ -170,36 +213,38 @@ void pud_populate(struct mm_struct *mm, pud_t *pud= p, pmd_t *pmd) */ flush_tlb_mm(mm); } @@ -22548,7 +23225,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/pgtable.c linu= x-3.1.4/arch/x86/mm/pgtable.c return -ENOMEM; } =20 -@@ -212,51 +257,55 @@ static int preallocate_pmds(pmd_t *pmds[ +@@ -212,51 +257,55 @@ static int preallocate_pmds(pmd_t *pmds[]) * preallocate which never got a corresponding vma will need to be * freed manually. */ @@ -22662,9 +23339,28 @@ diff -urNp linux-3.1.4/arch/x86/mm/pgtable.c lin= ux-3.1.4/arch/x86/mm/pgtable.c pgd_dtor(pgd); paravirt_pgd_free(mm, pgd); free_page((unsigned long)pgd); -diff -urNp linux-3.1.4/arch/x86/mm/setup_nx.c linux-3.1.4/arch/x86/mm/se= tup_nx.c ---- linux-3.1.4/arch/x86/mm/setup_nx.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/mm/setup_nx.c 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/mm/pgtable_32.c b/arch/x86/mm/pgtable_32.c +index cac7184..09a39fa 100644 +--- a/arch/x86/mm/pgtable_32.c ++++ b/arch/x86/mm/pgtable_32.c +@@ -48,10 +48,13 @@ void set_pte_vaddr(unsigned long vaddr, pte_t pteval= ) + return; + } + pte =3D pte_offset_kernel(pmd, vaddr); ++ ++ pax_open_kernel(); + if (pte_val(pteval)) + set_pte_at(&init_mm, vaddr, pte, pteval); + else + pte_clear(&init_mm, vaddr, pte); ++ pax_close_kernel(); +=20 + /* + * It's enough to flush this one mapping. +diff --git a/arch/x86/mm/setup_nx.c b/arch/x86/mm/setup_nx.c +index 410531d..0f16030 100644 +--- a/arch/x86/mm/setup_nx.c ++++ b/arch/x86/mm/setup_nx.c @@ -5,8 +5,10 @@ #include #include @@ -22676,7 +23372,7 @@ diff -urNp linux-3.1.4/arch/x86/mm/setup_nx.c lin= ux-3.1.4/arch/x86/mm/setup_nx.c /* * noexec =3D on|off * -@@ -28,12 +30,17 @@ static int __init noexec_setup(char *str +@@ -28,12 +30,17 @@ static int __init noexec_setup(char *str) return 0; } early_param("noexec", noexec_setup); @@ -22694,9 +23390,10 @@ diff -urNp linux-3.1.4/arch/x86/mm/setup_nx.c li= nux-3.1.4/arch/x86/mm/setup_nx.c __supported_pte_mask &=3D ~_PAGE_NX; } =20 -diff -urNp linux-3.1.4/arch/x86/mm/tlb.c linux-3.1.4/arch/x86/mm/tlb.c ---- linux-3.1.4/arch/x86/mm/tlb.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/mm/tlb.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/mm/tlb.c b/arch/x86/mm/tlb.c +index d6c0418..06a0ad5 100644 +--- a/arch/x86/mm/tlb.c ++++ b/arch/x86/mm/tlb.c @@ -65,7 +65,11 @@ void leave_mm(int cpu) BUG(); cpumask_clear_cpu(cpu, @@ -22709,90 +23406,10 @@ diff -urNp linux-3.1.4/arch/x86/mm/tlb.c linux-= 3.1.4/arch/x86/mm/tlb.c } EXPORT_SYMBOL_GPL(leave_mm); =20 -diff -urNp linux-3.1.4/arch/x86/net/bpf_jit_comp.c linux-3.1.4/arch/x86/= net/bpf_jit_comp.c ---- linux-3.1.4/arch/x86/net/bpf_jit_comp.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/arch/x86/net/bpf_jit_comp.c 2011-11-20 19:21:53.00000000= 0 -0500 -@@ -117,6 +117,10 @@ static inline void bpf_flush_icache(void - set_fs(old_fs); - } -=20 -+struct bpf_jit_work { -+ struct work_struct work; -+ void *image; -+}; -=20 - void bpf_jit_compile(struct sk_filter *fp) - { -@@ -141,6 +145,10 @@ void bpf_jit_compile(struct sk_filter *f - if (addrs =3D=3D NULL) - return; -=20 -+ fp->work =3D kmalloc(sizeof(*fp->work), GFP_KERNEL); -+ if (!fp->work) -+ goto out; -+ - /* Before first pass, make a rough estimation of addrs[] - * each bpf instruction is translated to less than 64 bytes - */ -@@ -585,11 +593,12 @@ cond_branch: f_offset =3D addrs[i + filt - if (image) { - if (unlikely(proglen + ilen > oldproglen)) { - pr_err("bpb_jit_compile fatal error\n"); -- kfree(addrs); -- module_free(NULL, image); -- return; -+ module_free_exec(NULL, image); -+ goto out; - } -+ pax_open_kernel(); - memcpy(image + proglen, temp, ilen); -+ pax_close_kernel(); - } - proglen +=3D ilen; - addrs[i] =3D proglen; -@@ -609,7 +618,7 @@ cond_branch: f_offset =3D addrs[i + filt - break; - } - if (proglen =3D=3D oldproglen) { -- image =3D module_alloc(max_t(unsigned int, -+ image =3D module_alloc_exec(max_t(unsigned int, - proglen, - sizeof(struct work_struct))); - if (!image) -@@ -631,24 +640,27 @@ cond_branch: f_offset =3D addrs[i + filt - fp->bpf_func =3D (void *)image; - } - out: -+ kfree(fp->work); - kfree(addrs); - return; - } -=20 - static void jit_free_defer(struct work_struct *arg) - { -- module_free(NULL, arg); -+ module_free_exec(NULL, ((struct bpf_jit_work*)arg)->image); -+ kfree(arg); - } -=20 - /* run from softirq, we must use a work_struct to call -- * module_free() from process context -+ * module_free_exec() from process context - */ - void bpf_jit_free(struct sk_filter *fp) - { - if (fp->bpf_func !=3D sk_run_filter) { -- struct work_struct *work =3D (struct work_struct *)fp->bpf_func; -+ struct work_struct *work =3D &fp->work->work; -=20 - INIT_WORK(work, jit_free_defer); -+ fp->work->image =3D fp->bpf_func; - schedule_work(work); - } - } -diff -urNp linux-3.1.4/arch/x86/net/bpf_jit.S linux-3.1.4/arch/x86/net/b= pf_jit.S ---- linux-3.1.4/arch/x86/net/bpf_jit.S 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/net/bpf_jit.S 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/net/bpf_jit.S b/arch/x86/net/bpf_jit.S +index 6687022..ceabcfa 100644 +--- a/arch/x86/net/bpf_jit.S ++++ b/arch/x86/net/bpf_jit.S @@ -9,6 +9,7 @@ */ #include @@ -22870,10 +23487,93 @@ diff -urNp linux-3.1.4/arch/x86/net/bpf_jit.S l= inux-3.1.4/arch/x86/net/bpf_jit.S xchg %eax,%ebx + pax_force_retaddr ret -diff -urNp linux-3.1.4/arch/x86/oprofile/backtrace.c linux-3.1.4/arch/x8= 6/oprofile/backtrace.c ---- linux-3.1.4/arch/x86/oprofile/backtrace.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/oprofile/backtrace.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -46,11 +46,11 @@ dump_user_backtrace_32(struct stack_fram +diff --git a/arch/x86/net/bpf_jit_comp.c b/arch/x86/net/bpf_jit_comp.c +index bfab3fa..05aac3a 100644 +--- a/arch/x86/net/bpf_jit_comp.c ++++ b/arch/x86/net/bpf_jit_comp.c +@@ -117,6 +117,10 @@ static inline void bpf_flush_icache(void *start, vo= id *end) + set_fs(old_fs); + } +=20 ++struct bpf_jit_work { ++ struct work_struct work; ++ void *image; ++}; +=20 + void bpf_jit_compile(struct sk_filter *fp) + { +@@ -141,6 +145,10 @@ void bpf_jit_compile(struct sk_filter *fp) + if (addrs =3D=3D NULL) + return; +=20 ++ fp->work =3D kmalloc(sizeof(*fp->work), GFP_KERNEL); ++ if (!fp->work) ++ goto out; ++ + /* Before first pass, make a rough estimation of addrs[] + * each bpf instruction is translated to less than 64 bytes + */ +@@ -585,11 +593,12 @@ cond_branch: f_offset =3D addrs[i + filter[i].jf= ] - addrs[i]; + if (image) { + if (unlikely(proglen + ilen > oldproglen)) { + pr_err("bpb_jit_compile fatal error\n"); +- kfree(addrs); +- module_free(NULL, image); +- return; ++ module_free_exec(NULL, image); ++ goto out; + } ++ pax_open_kernel(); + memcpy(image + proglen, temp, ilen); ++ pax_close_kernel(); + } + proglen +=3D ilen; + addrs[i] =3D proglen; +@@ -609,7 +618,7 @@ cond_branch: f_offset =3D addrs[i + filter[i].jf] = - addrs[i]; + break; + } + if (proglen =3D=3D oldproglen) { +- image =3D module_alloc(max_t(unsigned int, ++ image =3D module_alloc_exec(max_t(unsigned int, + proglen, + sizeof(struct work_struct))); + if (!image) +@@ -631,24 +640,27 @@ cond_branch: f_offset =3D addrs[i + filter[i].jf= ] - addrs[i]; + fp->bpf_func =3D (void *)image; + } + out: ++ kfree(fp->work); + kfree(addrs); + return; + } +=20 + static void jit_free_defer(struct work_struct *arg) + { +- module_free(NULL, arg); ++ module_free_exec(NULL, ((struct bpf_jit_work*)arg)->image); ++ kfree(arg); + } +=20 + /* run from softirq, we must use a work_struct to call +- * module_free() from process context ++ * module_free_exec() from process context + */ + void bpf_jit_free(struct sk_filter *fp) + { + if (fp->bpf_func !=3D sk_run_filter) { +- struct work_struct *work =3D (struct work_struct *)fp->bpf_func; ++ struct work_struct *work =3D &fp->work->work; +=20 + INIT_WORK(work, jit_free_defer); ++ fp->work->image =3D fp->bpf_func; + schedule_work(work); + } + } +diff --git a/arch/x86/oprofile/backtrace.c b/arch/x86/oprofile/backtrace= .c +index bff89df..377758a 100644 +--- a/arch/x86/oprofile/backtrace.c ++++ b/arch/x86/oprofile/backtrace.c +@@ -46,11 +46,11 @@ dump_user_backtrace_32(struct stack_frame_ia32 *head= ) struct stack_frame_ia32 *fp; unsigned long bytes; =20 @@ -22887,7 +23587,7 @@ diff -urNp linux-3.1.4/arch/x86/oprofile/backtrac= e.c linux-3.1.4/arch/x86/oprofi =20 oprofile_add_trace(bufhead[0].return_address); =20 -@@ -92,7 +92,7 @@ static struct stack_frame *dump_user_bac +@@ -92,7 +92,7 @@ static struct stack_frame *dump_user_backtrace(struct = stack_frame *head) struct stack_frame bufhead[2]; unsigned long bytes; =20 @@ -22896,7 +23596,7 @@ diff -urNp linux-3.1.4/arch/x86/oprofile/backtrac= e.c linux-3.1.4/arch/x86/oprofi if (bytes !=3D sizeof(bufhead)) return NULL; =20 -@@ -111,7 +111,7 @@ x86_backtrace(struct pt_regs * const reg +@@ -111,7 +111,7 @@ x86_backtrace(struct pt_regs * const regs, unsigned = int depth) { struct stack_frame *head =3D (struct stack_frame *)frame_pointer(regs)= ; =20 @@ -22905,9 +23605,10 @@ diff -urNp linux-3.1.4/arch/x86/oprofile/backtra= ce.c linux-3.1.4/arch/x86/oprofi unsigned long stack =3D kernel_stack_pointer(regs); if (depth) dump_trace(NULL, regs, (unsigned long *)stack, 0, -diff -urNp linux-3.1.4/arch/x86/pci/mrst.c linux-3.1.4/arch/x86/pci/mrst= .c ---- linux-3.1.4/arch/x86/pci/mrst.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/pci/mrst.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/pci/mrst.c b/arch/x86/pci/mrst.c +index cb29191..036766d 100644 +--- a/arch/x86/pci/mrst.c ++++ b/arch/x86/pci/mrst.c @@ -234,7 +234,9 @@ int __init pci_mrst_init(void) printk(KERN_INFO "Moorestown platform detected, using MRST PCI ops\n")= ; pci_mmcfg_late_init(); @@ -22919,9 +23620,10 @@ diff -urNp linux-3.1.4/arch/x86/pci/mrst.c linux= -3.1.4/arch/x86/pci/mrst.c /* Continue with standard init */ return 1; } -diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linux-3.1.4/arch/x86/pci/pc= bios.c ---- linux-3.1.4/arch/x86/pci/pcbios.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/arch/x86/pci/pcbios.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/arch/x86/pci/pcbios.c b/arch/x86/pci/pcbios.c +index f685535..2b76a81 100644 +--- a/arch/x86/pci/pcbios.c ++++ b/arch/x86/pci/pcbios.c @@ -79,50 +79,93 @@ union bios32 { static struct { unsigned long address; @@ -23057,7 +23759,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c : "memory"); local_irq_restore(flags); =20 -@@ -189,7 +235,10 @@ static int pci_bios_read(unsigned int se +@@ -189,7 +235,10 @@ static int pci_bios_read(unsigned int seg, unsigned= int bus, =20 switch (len) { case 1: @@ -23069,7 +23771,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -198,7 +247,8 @@ static int pci_bios_read(unsigned int se +@@ -198,7 +247,8 @@ static int pci_bios_read(unsigned int seg, unsigned = int bus, : "1" (PCIBIOS_READ_CONFIG_BYTE), "b" (bx), "D" ((long)reg), @@ -23079,7 +23781,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c /* * Zero-extend the result beyond 8 bits, do not trust the * BIOS having done it: -@@ -206,7 +256,10 @@ static int pci_bios_read(unsigned int se +@@ -206,7 +256,10 @@ static int pci_bios_read(unsigned int seg, unsigned= int bus, *value &=3D 0xff; break; case 2: @@ -23091,7 +23793,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -215,7 +268,8 @@ static int pci_bios_read(unsigned int se +@@ -215,7 +268,8 @@ static int pci_bios_read(unsigned int seg, unsigned = int bus, : "1" (PCIBIOS_READ_CONFIG_WORD), "b" (bx), "D" ((long)reg), @@ -23101,7 +23803,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c /* * Zero-extend the result beyond 16 bits, do not trust the * BIOS having done it: -@@ -223,7 +277,10 @@ static int pci_bios_read(unsigned int se +@@ -223,7 +277,10 @@ static int pci_bios_read(unsigned int seg, unsigned= int bus, *value &=3D 0xffff; break; case 4: @@ -23113,7 +23815,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -232,7 +289,8 @@ static int pci_bios_read(unsigned int se +@@ -232,7 +289,8 @@ static int pci_bios_read(unsigned int seg, unsigned = int bus, : "1" (PCIBIOS_READ_CONFIG_DWORD), "b" (bx), "D" ((long)reg), @@ -23123,7 +23825,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c break; } =20 -@@ -256,7 +314,10 @@ static int pci_bios_write(unsigned int s +@@ -256,7 +314,10 @@ static int pci_bios_write(unsigned int seg, unsigne= d int bus, =20 switch (len) { case 1: @@ -23135,7 +23837,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -265,10 +326,14 @@ static int pci_bios_write(unsigned int s +@@ -265,10 +326,14 @@ static int pci_bios_write(unsigned int seg, unsign= ed int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -23152,7 +23854,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -277,10 +342,14 @@ static int pci_bios_write(unsigned int s +@@ -277,10 +342,14 @@ static int pci_bios_write(unsigned int seg, unsign= ed int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -23169,7 +23871,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -289,7 +358,8 @@ static int pci_bios_write(unsigned int s +@@ -289,7 +358,8 @@ static int pci_bios_write(unsigned int seg, unsigned= int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -23179,7 +23881,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c break; } =20 -@@ -394,10 +464,13 @@ struct irq_routing_table * pcibios_get_i +@@ -394,10 +464,13 @@ struct irq_routing_table * pcibios_get_irq_routing= _table(void) =20 DBG("PCI: Fetching IRQ routing table... "); __asm__("push %%es\n\t" @@ -23194,7 +23896,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -408,7 +481,8 @@ struct irq_routing_table * pcibios_get_i +@@ -408,7 +481,8 @@ struct irq_routing_table * pcibios_get_irq_routing_t= able(void) "1" (0), "D" ((long) &opt), "S" (&pci_indirect), @@ -23204,7 +23906,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c : "memory"); DBG("OK ret=3D%d, size=3D%d, map=3D%x\n", ret, opt.size, map); if (ret & 0xff00) -@@ -432,7 +506,10 @@ int pcibios_set_irq_routing(struct pci_d +@@ -432,7 +506,10 @@ int pcibios_set_irq_routing(struct pci_dev *dev, in= t pin, int irq) { int ret; =20 @@ -23216,7 +23918,7 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c linu= x-3.1.4/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -440,7 +517,8 @@ int pcibios_set_irq_routing(struct pci_d +@@ -440,7 +517,8 @@ int pcibios_set_irq_routing(struct pci_dev *dev, int= pin, int irq) : "0" (PCIBIOS_SET_PCI_HW_INT), "b" ((dev->bus->number << 8) | dev->devfn), "c" ((irq << 8) | (pin + 10)), @@ -23226,9 +23928,10 @@ diff -urNp linux-3.1.4/arch/x86/pci/pcbios.c lin= ux-3.1.4/arch/x86/pci/pcbios.c return !(ret & 0xff00); } EXPORT_SYMBOL(pcibios_set_irq_routing); -diff -urNp linux-3.1.4/arch/x86/platform/efi/efi_32.c linux-3.1.4/arch/x= 86/platform/efi/efi_32.c ---- linux-3.1.4/arch/x86/platform/efi/efi_32.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/arch/x86/platform/efi/efi_32.c 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/arch/x86/platform/efi/efi_32.c b/arch/x86/platform/efi/efi_= 32.c +index 5cab48e..b025f9b 100644 +--- a/arch/x86/platform/efi/efi_32.c ++++ b/arch/x86/platform/efi/efi_32.c @@ -38,70 +38,56 @@ */ =20 @@ -23243,10 +23946,11 @@ diff -urNp linux-3.1.4/arch/x86/platform/efi/ef= i_32.c linux-3.1.4/arch/x86/platf - unsigned long temp; struct desc_ptr gdt_descr; =20 -- local_irq_save(efi_rt_eflags); +#ifdef CONFIG_PAX_KERNEXEC + struct desc_struct d; +#endif ++ + local_irq_save(efi_rt_eflags); =20 - /* - * If I don't have PAE, I should just duplicate two entries in page @@ -23254,8 +23958,7 @@ diff -urNp linux-3.1.4/arch/x86/platform/efi/efi_= 32.c linux-3.1.4/arch/x86/platf - * page directory. - */ - cr4 =3D read_cr4_safe(); -+ local_irq_save(efi_rt_eflags); -=20 +- - if (cr4 & X86_CR4_PAE) { - efi_bak_pg_dir_pointer[0].pgd =3D - swapper_pg_dir[pgd_index(0)].pgd; @@ -23326,9 +24029,10 @@ diff -urNp linux-3.1.4/arch/x86/platform/efi/efi= _32.c linux-3.1.4/arch/x86/platf =20 /* * After the lock is released, the original page table is restored. -diff -urNp linux-3.1.4/arch/x86/platform/efi/efi_stub_32.S linux-3.1.4/a= rch/x86/platform/efi/efi_stub_32.S ---- linux-3.1.4/arch/x86/platform/efi/efi_stub_32.S 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/x86/platform/efi/efi_stub_32.S 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/arch/x86/platform/efi/efi_stub_32.S b/arch/x86/platform/efi= /efi_stub_32.S +index fbe66e6..c5c0dd2 100644 +--- a/arch/x86/platform/efi/efi_stub_32.S ++++ b/arch/x86/platform/efi/efi_stub_32.S @@ -6,7 +6,9 @@ */ =20 @@ -23437,9 +24141,10 @@ diff -urNp linux-3.1.4/arch/x86/platform/efi/efi= _stub_32.S linux-3.1.4/arch/x86/ saved_return_addr: .long 0 efi_rt_function_ptr: -diff -urNp linux-3.1.4/arch/x86/platform/efi/efi_stub_64.S linux-3.1.4/a= rch/x86/platform/efi/efi_stub_64.S ---- linux-3.1.4/arch/x86/platform/efi/efi_stub_64.S 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/arch/x86/platform/efi/efi_stub_64.S 2011-12-02 17:38:47.= 000000000 -0500 +diff --git a/arch/x86/platform/efi/efi_stub_64.S b/arch/x86/platform/efi= /efi_stub_64.S +index 4c07cca..2c8427d 100644 +--- a/arch/x86/platform/efi/efi_stub_64.S ++++ b/arch/x86/platform/efi/efi_stub_64.S @@ -7,6 +7,7 @@ */ =20 @@ -23503,9 +24208,10 @@ diff -urNp linux-3.1.4/arch/x86/platform/efi/efi= _stub_64.S linux-3.1.4/arch/x86/ + pax_force_retaddr 0, 1 ret ENDPROC(efi_call6) -diff -urNp linux-3.1.4/arch/x86/platform/mrst/mrst.c linux-3.1.4/arch/x8= 6/platform/mrst/mrst.c ---- linux-3.1.4/arch/x86/platform/mrst/mrst.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/platform/mrst/mrst.c 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/arch/x86/platform/mrst/mrst.c b/arch/x86/platform/mrst/mrst= .c +index fe73276..70fe25a 100644 +--- a/arch/x86/platform/mrst/mrst.c ++++ b/arch/x86/platform/mrst/mrst.c @@ -239,14 +239,16 @@ static int mrst_i8042_detect(void) } =20 @@ -23525,10 +24231,11 @@ diff -urNp linux-3.1.4/arch/x86/platform/mrst/m= rst.c linux-3.1.4/arch/x86/platfo } =20 /* -diff -urNp linux-3.1.4/arch/x86/platform/uv/tlb_uv.c linux-3.1.4/arch/x8= 6/platform/uv/tlb_uv.c ---- linux-3.1.4/arch/x86/platform/uv/tlb_uv.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/arch/x86/platform/uv/tlb_uv.c 2011-11-16 19:39:11.000000= 000 -0500 -@@ -377,6 +377,8 @@ static void reset_with_ipi(struct pnmask +diff --git a/arch/x86/platform/uv/tlb_uv.c b/arch/x86/platform/uv/tlb_uv= .c +index 5b55219..b326540 100644 +--- a/arch/x86/platform/uv/tlb_uv.c ++++ b/arch/x86/platform/uv/tlb_uv.c +@@ -377,6 +377,8 @@ static void reset_with_ipi(struct pnmask *distributi= on, struct bau_control *bcp) struct bau_control *smaster =3D bcp->socket_master; struct reset_args reset_args; =20 @@ -23537,9 +24244,10 @@ diff -urNp linux-3.1.4/arch/x86/platform/uv/tlb_= uv.c linux-3.1.4/arch/x86/platfo reset_args.sender =3D sender; cpus_clear(*mask); /* find a single cpu for each uvhub in this distribution mask */ -diff -urNp linux-3.1.4/arch/x86/power/cpu.c linux-3.1.4/arch/x86/power/c= pu.c ---- linux-3.1.4/arch/x86/power/cpu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/power/cpu.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/power/cpu.c b/arch/x86/power/cpu.c +index 87bb35e..eff2da8 100644 +--- a/arch/x86/power/cpu.c ++++ b/arch/x86/power/cpu.c @@ -130,7 +130,7 @@ static void do_fpu_end(void) static void fix_processor_context(void) { @@ -23559,9 +24267,10 @@ diff -urNp linux-3.1.4/arch/x86/power/cpu.c linu= x-3.1.4/arch/x86/power/cpu.c =20 syscall_init(); /* This sets MSR_*STAR and related */ #endif -diff -urNp linux-3.1.4/arch/x86/vdso/Makefile linux-3.1.4/arch/x86/vdso/= Makefile ---- linux-3.1.4/arch/x86/vdso/Makefile 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/vdso/Makefile 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/vdso/Makefile b/arch/x86/vdso/Makefile +index 5d17950..2253fc9 100644 +--- a/arch/x86/vdso/Makefile ++++ b/arch/x86/vdso/Makefile @@ -137,7 +137,7 @@ quiet_cmd_vdso =3D VDSO $@ -Wl,-T,$(filter %.lds,$^) $(filter %.o,$^) && \ sh $(srctree)/$(src)/checkundef.sh '$(NM)' '$@' @@ -23571,9 +24280,10 @@ diff -urNp linux-3.1.4/arch/x86/vdso/Makefile li= nux-3.1.4/arch/x86/vdso/Makefile GCOV_PROFILE :=3D n =20 # -diff -urNp linux-3.1.4/arch/x86/vdso/vdso32-setup.c linux-3.1.4/arch/x86= /vdso/vdso32-setup.c ---- linux-3.1.4/arch/x86/vdso/vdso32-setup.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/arch/x86/vdso/vdso32-setup.c 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/arch/x86/vdso/vdso32-setup.c b/arch/x86/vdso/vdso32-setup.c +index 468d591..8e80a0a 100644 +--- a/arch/x86/vdso/vdso32-setup.c ++++ b/arch/x86/vdso/vdso32-setup.c @@ -25,6 +25,7 @@ #include #include @@ -23582,7 +24292,7 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vdso32-setup= .c linux-3.1.4/arch/x86/vdso/vd =20 enum { VDSO_DISABLED =3D 0, -@@ -226,7 +227,7 @@ static inline void map_compat_vdso(int m +@@ -226,7 +227,7 @@ static inline void map_compat_vdso(int map) void enable_sep_cpu(void) { int cpu =3D get_cpu(); @@ -23600,7 +24310,7 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vdso32-setup= .c linux-3.1.4/arch/x86/vdso/vd /* * Make sure the vDSO gets into every core dump. * Dumping its contents makes post-mortem fully interpretable later -@@ -331,14 +332,14 @@ int arch_setup_additional_pages(struct l +@@ -331,14 +332,14 @@ int arch_setup_additional_pages(struct linux_binpr= m *bprm, int uses_interp) if (compat) addr =3D VDSO_HIGH_BASE; else { @@ -23617,7 +24327,7 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vdso32-setup= .c linux-3.1.4/arch/x86/vdso/vd =20 if (compat_uses_vma || !compat) { /* -@@ -361,11 +362,11 @@ int arch_setup_additional_pages(struct l +@@ -361,11 +362,11 @@ int arch_setup_additional_pages(struct linux_binpr= m *bprm, int uses_interp) } =20 current_thread_info()->sysenter_return =3D @@ -23647,7 +24357,7 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vdso32-setup= .c linux-3.1.4/arch/x86/vdso/vd return NULL; } =20 -@@ -423,7 +430,7 @@ struct vm_area_struct *get_gate_vma(stru +@@ -423,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. */ @@ -23656,9 +24366,10 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vdso32-setu= p.c linux-3.1.4/arch/x86/vdso/vd return &gate_vma; return NULL; } -diff -urNp linux-3.1.4/arch/x86/vdso/vma.c linux-3.1.4/arch/x86/vdso/vma= .c ---- linux-3.1.4/arch/x86/vdso/vma.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/vdso/vma.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/arch/x86/vdso/vma.c b/arch/x86/vdso/vma.c +index 316fbca..4638633 100644 +--- a/arch/x86/vdso/vma.c ++++ b/arch/x86/vdso/vma.c @@ -16,8 +16,6 @@ #include #include @@ -23668,7 +24379,7 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vma.c linux-= 3.1.4/arch/x86/vdso/vma.c extern char vdso_start[], vdso_end[]; extern unsigned short vdso_sync_cpuid; =20 -@@ -97,13 +95,15 @@ static unsigned long vdso_addr(unsigned=20 +@@ -97,13 +95,15 @@ static unsigned long vdso_addr(unsigned long start, = unsigned len) int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_int= erp) { struct mm_struct *mm =3D current->mm; @@ -23688,7 +24399,7 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vma.c linux-= 3.1.4/arch/x86/vdso/vma.c addr =3D vdso_addr(mm->start_stack, vdso_size); addr =3D get_unmapped_area(NULL, addr, vdso_size, 0, 0); if (IS_ERR_VALUE(addr)) { -@@ -111,26 +111,18 @@ int arch_setup_additional_pages(struct l +@@ -111,26 +111,18 @@ int arch_setup_additional_pages(struct linux_binpr= m *bprm, int uses_interp) goto up_fail; } =20 @@ -23719,9 +24430,10 @@ diff -urNp linux-3.1.4/arch/x86/vdso/vma.c linux= -3.1.4/arch/x86/vdso/vma.c - return 0; -} -__setup("vdso=3D", vdso_setup); -diff -urNp linux-3.1.4/arch/x86/xen/enlighten.c linux-3.1.4/arch/x86/xen= /enlighten.c ---- linux-3.1.4/arch/x86/xen/enlighten.c 2011-11-26 19:57:27.000000000 -= 0500 -+++ linux-3.1.4/arch/x86/xen/enlighten.c 2011-11-26 19:58:40.000000000 -= 0500 +diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c +index 46c8069..6330d3c 100644 +--- a/arch/x86/xen/enlighten.c ++++ b/arch/x86/xen/enlighten.c @@ -85,8 +85,6 @@ EXPORT_SYMBOL_GPL(xen_start_info); =20 struct shared_info xen_dummy_shared_info; @@ -23731,7 +24443,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/enlighten.c l= inux-3.1.4/arch/x86/xen/enlight RESERVE_BRK(shared_info_page_brk, PAGE_SIZE); __read_mostly int xen_have_vector_callback; EXPORT_SYMBOL_GPL(xen_have_vector_callback); -@@ -1028,7 +1026,7 @@ static const struct pv_apic_ops xen_apic +@@ -1028,7 +1026,7 @@ static const struct pv_apic_ops xen_apic_ops __ini= tconst =3D { #endif }; =20 @@ -23761,7 +24473,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/enlighten.c l= inux-3.1.4/arch/x86/xen/enlight { xen_reboot(SHUTDOWN_poweroff); } -@@ -1152,7 +1150,17 @@ asmlinkage void __init xen_start_kernel( +@@ -1152,7 +1150,17 @@ asmlinkage void __init xen_start_kernel(void) __userpte_alloc_gfp &=3D ~__GFP_HIGHMEM; =20 /* Work out if we support NX */ @@ -23780,7 +24492,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/enlighten.c l= inux-3.1.4/arch/x86/xen/enlight =20 xen_setup_features(); =20 -@@ -1183,13 +1191,6 @@ asmlinkage void __init xen_start_kernel( +@@ -1183,13 +1191,6 @@ asmlinkage void __init xen_start_kernel(void) =20 machine_ops =3D xen_machine_ops; =20 @@ -23794,10 +24506,11 @@ diff -urNp linux-3.1.4/arch/x86/xen/enlighten.c= linux-3.1.4/arch/x86/xen/enlight xen_smp_init(); =20 #ifdef CONFIG_ACPI_NUMA -diff -urNp linux-3.1.4/arch/x86/xen/mmu.c linux-3.1.4/arch/x86/xen/mmu.c ---- linux-3.1.4/arch/x86/xen/mmu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/xen/mmu.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1768,6 +1768,8 @@ pgd_t * __init xen_setup_kernel_pagetabl +diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c +index 3dd53f9..9e8ba48 100644 +--- a/arch/x86/xen/mmu.c ++++ b/arch/x86/xen/mmu.c +@@ -1768,6 +1768,8 @@ pgd_t * __init xen_setup_kernel_pagetable(pgd_t *p= gd, convert_pfn_mfn(init_level4_pgt); convert_pfn_mfn(level3_ident_pgt); convert_pfn_mfn(level3_kernel_pgt); @@ -23806,7 +24519,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/mmu.c linux-3= .1.4/arch/x86/xen/mmu.c =20 l3 =3D m2v(pgd[pgd_index(__START_KERNEL_map)].pgd); l2 =3D m2v(l3[pud_index(__START_KERNEL_map)].pud); -@@ -1786,7 +1788,10 @@ pgd_t * __init xen_setup_kernel_pagetabl +@@ -1786,7 +1788,10 @@ pgd_t * __init xen_setup_kernel_pagetable(pgd_t *= pgd, set_page_prot(init_level4_pgt, PAGE_KERNEL_RO); set_page_prot(level3_ident_pgt, PAGE_KERNEL_RO); set_page_prot(level3_kernel_pgt, PAGE_KERNEL_RO); @@ -23817,7 +24530,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/mmu.c linux-3= .1.4/arch/x86/xen/mmu.c set_page_prot(level2_kernel_pgt, PAGE_KERNEL_RO); set_page_prot(level2_fixmap_pgt, PAGE_KERNEL_RO); =20 -@@ -2000,6 +2005,7 @@ static void __init xen_post_allocator_in +@@ -2000,6 +2005,7 @@ static void __init xen_post_allocator_init(void) pv_mmu_ops.set_pud =3D xen_set_pud; #if PAGETABLE_LEVELS =3D=3D 4 pv_mmu_ops.set_pgd =3D xen_set_pgd; @@ -23825,7 +24538,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/mmu.c linux-3= .1.4/arch/x86/xen/mmu.c #endif =20 /* This will work as long as patching hasn't happened yet -@@ -2081,6 +2087,7 @@ static const struct pv_mmu_ops xen_mmu_o +@@ -2081,6 +2087,7 @@ static const struct pv_mmu_ops xen_mmu_ops __initc= onst =3D { .pud_val =3D PV_CALLEE_SAVE(xen_pud_val), .make_pud =3D PV_CALLEE_SAVE(xen_make_pud), .set_pgd =3D xen_set_pgd_hyper, @@ -23833,10 +24546,11 @@ diff -urNp linux-3.1.4/arch/x86/xen/mmu.c linux= -3.1.4/arch/x86/xen/mmu.c =20 .alloc_pud =3D xen_alloc_pmd_init, .release_pud =3D xen_release_pmd_init, -diff -urNp linux-3.1.4/arch/x86/xen/smp.c linux-3.1.4/arch/x86/xen/smp.c ---- linux-3.1.4/arch/x86/xen/smp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/arch/x86/xen/smp.c 2011-11-16 18:39:07.000000000 -0500 -@@ -194,11 +194,6 @@ static void __init xen_smp_prepare_boot_ +diff --git a/arch/x86/xen/smp.c b/arch/x86/xen/smp.c +index 041d4fe..7666b7e 100644 +--- a/arch/x86/xen/smp.c ++++ b/arch/x86/xen/smp.c +@@ -194,11 +194,6 @@ static void __init xen_smp_prepare_boot_cpu(void) { BUG_ON(smp_processor_id() !=3D 0); native_smp_prepare_boot_cpu(); @@ -23848,7 +24562,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/smp.c linux-3= .1.4/arch/x86/xen/smp.c xen_filter_cpu_maps(); xen_setup_vcpu_info_placement(); } -@@ -275,12 +270,12 @@ cpu_initialize_context(unsigned int cpu, +@@ -275,12 +270,12 @@ cpu_initialize_context(unsigned int cpu, struct ta= sk_struct *idle) gdt =3D get_cpu_gdt_table(cpu); =20 ctxt->flags =3D VGCF_IN_KERNEL; @@ -23864,7 +24578,7 @@ diff -urNp linux-3.1.4/arch/x86/xen/smp.c linux-3= .1.4/arch/x86/xen/smp.c #else ctxt->gs_base_kernel =3D per_cpu_offset(cpu); #endif -@@ -331,13 +326,12 @@ static int __cpuinit xen_cpu_up(unsigned +@@ -331,13 +326,12 @@ static int __cpuinit xen_cpu_up(unsigned int cpu) int rc; =20 per_cpu(current_task, cpu) =3D idle; @@ -23880,9 +24594,10 @@ diff -urNp linux-3.1.4/arch/x86/xen/smp.c linux-= 3.1.4/arch/x86/xen/smp.c #endif xen_setup_runstate_info(cpu); xen_setup_timer(cpu); -diff -urNp linux-3.1.4/arch/x86/xen/xen-asm_32.S linux-3.1.4/arch/x86/xe= n/xen-asm_32.S ---- linux-3.1.4/arch/x86/xen/xen-asm_32.S 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/arch/x86/xen/xen-asm_32.S 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/arch/x86/xen/xen-asm_32.S b/arch/x86/xen/xen-asm_32.S +index b040b0e..8cc4fe0 100644 +--- a/arch/x86/xen/xen-asm_32.S ++++ b/arch/x86/xen/xen-asm_32.S @@ -83,14 +83,14 @@ ENTRY(xen_iret) ESP_OFFSET=3D4 # bytes pushed onto stack =20 @@ -23904,9 +24619,10 @@ diff -urNp linux-3.1.4/arch/x86/xen/xen-asm_32.S= linux-3.1.4/arch/x86/xen/xen-as #else movl xen_vcpu, %eax #endif -diff -urNp linux-3.1.4/arch/x86/xen/xen-head.S linux-3.1.4/arch/x86/xen/= xen-head.S ---- linux-3.1.4/arch/x86/xen/xen-head.S 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/arch/x86/xen/xen-head.S 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/arch/x86/xen/xen-head.S b/arch/x86/xen/xen-head.S +index aaa7291..3f77960 100644 +--- a/arch/x86/xen/xen-head.S ++++ b/arch/x86/xen/xen-head.S @@ -19,6 +19,17 @@ ENTRY(startup_xen) #ifdef CONFIG_X86_32 mov %esi,xen_start_info @@ -23925,9 +24641,10 @@ diff -urNp linux-3.1.4/arch/x86/xen/xen-head.S l= inux-3.1.4/arch/x86/xen/xen-head #else mov %rsi,xen_start_info mov $init_thread_union+THREAD_SIZE,%rsp -diff -urNp linux-3.1.4/arch/x86/xen/xen-ops.h linux-3.1.4/arch/x86/xen/x= en-ops.h ---- linux-3.1.4/arch/x86/xen/xen-ops.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/arch/x86/xen/xen-ops.h 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/arch/x86/xen/xen-ops.h b/arch/x86/xen/xen-ops.h +index b095739..8c17bcd 100644 +--- a/arch/x86/xen/xen-ops.h ++++ b/arch/x86/xen/xen-ops.h @@ -10,8 +10,6 @@ extern const char xen_hypervisor_callback[]; extern const char xen_failsafe_callback[]; @@ -23937,10 +24654,11 @@ diff -urNp linux-3.1.4/arch/x86/xen/xen-ops.h l= inux-3.1.4/arch/x86/xen/xen-ops.h struct trap_info; void xen_copy_trap_info(struct trap_info *traps); =20 -diff -urNp linux-3.1.4/block/blk-iopoll.c linux-3.1.4/block/blk-iopoll.c ---- linux-3.1.4/block/blk-iopoll.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/block/blk-iopoll.c 2011-11-16 18:39:07.000000000 -0500 -@@ -77,7 +77,7 @@ void blk_iopoll_complete(struct blk_iopo +diff --git a/block/blk-iopoll.c b/block/blk-iopoll.c +index 58916af..9cb880b 100644 +--- a/block/blk-iopoll.c ++++ b/block/blk-iopoll.c +@@ -77,7 +77,7 @@ void blk_iopoll_complete(struct blk_iopoll *iopoll) } EXPORT_SYMBOL(blk_iopoll_complete); =20 @@ -23949,10 +24667,11 @@ diff -urNp linux-3.1.4/block/blk-iopoll.c linux= -3.1.4/block/blk-iopoll.c { struct list_head *list =3D &__get_cpu_var(blk_cpu_iopoll); int rearm =3D 0, budget =3D blk_iopoll_budget; -diff -urNp linux-3.1.4/block/blk-map.c linux-3.1.4/block/blk-map.c ---- linux-3.1.4/block/blk-map.c 2011-11-26 19:57:27.000000000 -0500 -+++ linux-3.1.4/block/blk-map.c 2011-11-26 19:58:40.000000000 -0500 -@@ -302,7 +302,7 @@ int blk_rq_map_kern(struct request_queue +diff --git a/block/blk-map.c b/block/blk-map.c +index 164cd00..6d96fc1 100644 +--- a/block/blk-map.c ++++ b/block/blk-map.c +@@ -302,7 +302,7 @@ int blk_rq_map_kern(struct request_queue *q, struct = request *rq, void *kbuf, if (!len || !kbuf) return -EINVAL; =20 @@ -23961,10 +24680,11 @@ diff -urNp linux-3.1.4/block/blk-map.c linux-3.= 1.4/block/blk-map.c if (do_copy) bio =3D bio_copy_kern(q, kbuf, len, gfp_mask, reading); else -diff -urNp linux-3.1.4/block/blk-softirq.c linux-3.1.4/block/blk-softirq= .c ---- linux-3.1.4/block/blk-softirq.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/block/blk-softirq.c 2011-11-16 18:39:07.000000000 -0500 -@@ -17,7 +17,7 @@ static DEFINE_PER_CPU(struct list_head,=20 +diff --git a/block/blk-softirq.c b/block/blk-softirq.c +index 1366a89..e17f54b 100644 +--- a/block/blk-softirq.c ++++ b/block/blk-softirq.c +@@ -17,7 +17,7 @@ static DEFINE_PER_CPU(struct list_head, blk_cpu_done); * Softirq action handler - move entries to local list and loop over th= em * while passing them to the queue registered handler. */ @@ -23973,10 +24693,11 @@ diff -urNp linux-3.1.4/block/blk-softirq.c linu= x-3.1.4/block/blk-softirq.c { struct list_head *cpu_list, local_list; =20 -diff -urNp linux-3.1.4/block/bsg.c linux-3.1.4/block/bsg.c ---- linux-3.1.4/block/bsg.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/block/bsg.c 2011-11-16 18:39:07.000000000 -0500 -@@ -176,16 +176,24 @@ static int blk_fill_sgv4_hdr_rq(struct r +diff --git a/block/bsg.c b/block/bsg.c +index 702f131..37808bf 100644 +--- a/block/bsg.c ++++ b/block/bsg.c +@@ -176,16 +176,24 @@ static int blk_fill_sgv4_hdr_rq(struct request_que= ue *q, struct request *rq, struct sg_io_v4 *hdr, struct bsg_device *bd, fmode_t has_write_perm) { @@ -24003,10 +24724,11 @@ diff -urNp linux-3.1.4/block/bsg.c linux-3.1.4/= block/bsg.c if (hdr->subprotocol =3D=3D BSG_SUB_PROTOCOL_SCSI_CMD) { if (blk_verify_command(rq->cmd, has_write_perm)) return -EPERM; -diff -urNp linux-3.1.4/block/compat_ioctl.c linux-3.1.4/block/compat_ioc= tl.c ---- linux-3.1.4/block/compat_ioctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/block/compat_ioctl.c 2011-11-16 18:39:07.000000000 -0500 -@@ -340,7 +340,7 @@ static int compat_fd_ioctl(struct block_ +diff --git a/block/compat_ioctl.c b/block/compat_ioctl.c +index 7b72502..646105c 100644 +--- a/block/compat_ioctl.c ++++ b/block/compat_ioctl.c +@@ -340,7 +340,7 @@ static int compat_fd_ioctl(struct block_device *bdev= , fmode_t mode, err |=3D __get_user(f->spec1, &uf->spec1); err |=3D __get_user(f->fmt_gap, &uf->fmt_gap); err |=3D __get_user(name, &uf->name); @@ -24015,9 +24737,10 @@ diff -urNp linux-3.1.4/block/compat_ioctl.c linu= x-3.1.4/block/compat_ioctl.c if (err) { err =3D -EFAULT; goto out; -diff -urNp linux-3.1.4/block/scsi_ioctl.c linux-3.1.4/block/scsi_ioctl.c ---- linux-3.1.4/block/scsi_ioctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/block/scsi_ioctl.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/block/scsi_ioctl.c b/block/scsi_ioctl.c +index 4f4230b..0feae9a 100644 +--- a/block/scsi_ioctl.c ++++ b/block/scsi_ioctl.c @@ -222,8 +222,20 @@ EXPORT_SYMBOL(blk_verify_command); static int blk_fill_sghdr_rq(struct request_queue *q, struct request *r= q, struct sg_io_hdr *hdr, fmode_t mode) @@ -24040,7 +24763,7 @@ diff -urNp linux-3.1.4/block/scsi_ioctl.c linux-3= .1.4/block/scsi_ioctl.c if (blk_verify_command(rq->cmd, mode & FMODE_WRITE)) return -EPERM; =20 -@@ -432,6 +444,8 @@ int sg_scsi_ioctl(struct request_queue * +@@ -432,6 +444,8 @@ int sg_scsi_ioctl(struct request_queue *q, struct ge= ndisk *disk, fmode_t mode, int err; unsigned int in_len, out_len, bytes, opcode, cmdlen; char *buffer =3D NULL, sense[SCSI_SENSE_BUFFERSIZE]; @@ -24049,7 +24772,7 @@ diff -urNp linux-3.1.4/block/scsi_ioctl.c linux-3= .1.4/block/scsi_ioctl.c =20 if (!sic) return -EINVAL; -@@ -465,9 +479,18 @@ int sg_scsi_ioctl(struct request_queue * +@@ -465,9 +479,18 @@ int sg_scsi_ioctl(struct request_queue *q, struct g= endisk *disk, fmode_t mode, */ err =3D -EFAULT; rq->cmd_len =3D cmdlen; @@ -24069,9 +24792,10 @@ diff -urNp linux-3.1.4/block/scsi_ioctl.c linux-= 3.1.4/block/scsi_ioctl.c if (in_len && copy_from_user(buffer, sic->data + cmdlen, in_len)) goto error; =20 -diff -urNp linux-3.1.4/crypto/cryptd.c linux-3.1.4/crypto/cryptd.c ---- linux-3.1.4/crypto/cryptd.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/crypto/cryptd.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/crypto/cryptd.c b/crypto/cryptd.c +index 671d4d6..5f24030 100644 +--- a/crypto/cryptd.c ++++ b/crypto/cryptd.c @@ -63,7 +63,7 @@ struct cryptd_blkcipher_ctx { =20 struct cryptd_blkcipher_request_ctx { @@ -24090,10 +24814,11 @@ diff -urNp linux-3.1.4/crypto/cryptd.c linux-3.= 1.4/crypto/cryptd.c =20 static void cryptd_queue_worker(struct work_struct *work); =20 -diff -urNp linux-3.1.4/crypto/serpent.c linux-3.1.4/crypto/serpent.c ---- linux-3.1.4/crypto/serpent.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/crypto/serpent.c 2011-11-16 18:40:10.000000000 -0500 -@@ -224,6 +224,8 @@ static int serpent_setkey(struct crypto_ +diff --git a/crypto/serpent.c b/crypto/serpent.c +index b651a55..a9ddd79b 100644 +--- a/crypto/serpent.c ++++ b/crypto/serpent.c +@@ -224,6 +224,8 @@ static int serpent_setkey(struct crypto_tfm *tfm, co= nst u8 *key, u32 r0,r1,r2,r3,r4; int i; =20 @@ -24102,194 +24827,10 @@ diff -urNp linux-3.1.4/crypto/serpent.c linux-= 3.1.4/crypto/serpent.c /* Copy key, add padding */ =20 for (i =3D 0; i < keylen; ++i) -diff -urNp linux-3.1.4/Documentation/dontdiff linux-3.1.4/Documentation/= dontdiff ---- linux-3.1.4/Documentation/dontdiff 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/Documentation/dontdiff 2011-12-02 17:38:47.000000000 -05= 00 -@@ -5,6 +5,7 @@ - *.cis - *.cpio - *.csp -+*.dbg - *.dsp - *.dvi - *.elf -@@ -14,6 +15,7 @@ - *.gcov - *.gen.S - *.gif -+*.gmo - *.grep - *.grp - *.gz -@@ -48,9 +50,11 @@ - *.tab.h - *.tex - *.ver -+*.vim - *.xml - *.xz - *_MODULES -+*_reg_safe.h - *_vga16.c - *~ - \#*# -@@ -70,6 +74,7 @@ Kerntypes - Module.markers - Module.symvers - PENDING -+PERF* - SCCS - System.map* - TAGS -@@ -93,19 +98,24 @@ bounds.h - bsetup - btfixupprep - build -+builtin-policy.h - bvmlinux - bzImage* - capability_names.h - capflags.c - classlist.h* -+clut_vga16.c -+common-cmds.h - comp*.log - compile.h* - conf - config - config-* - config_data.h* -+config.c - config.mak - config.mak.autogen -+config.tmp - conmakehash - consolemap_deftbl.c* - cpustr.h -@@ -119,6 +129,7 @@ dslm - elf2ecoff - elfconfig.h* - evergreen_reg_safe.h -+exception_policy.conf - fixdep - flask.h - fore200e_mkfirm -@@ -126,12 +137,15 @@ fore200e_pca_fw.c* - gconf - gconf.glade.h - gen-devlist -+gen-kdb_cmds.c - gen_crc32table - gen_init_cpio - generated - genheaders - genksyms - *_gray256.c -+hash -+hid-example - hpet_example - hugepage-mmap - hugepage-shm -@@ -146,7 +160,7 @@ int32.c - int4.c - int8.c - kallsyms --kconfig -+kern_constants.h - keywords.c - ksym.c* - ksym.h* -@@ -154,7 +168,6 @@ kxgettext - lkc_defs.h - lex.c - lex.*.c --linux - logo_*.c - logo_*_clut224.c - logo_*_mono.c -@@ -166,14 +179,15 @@ machtypes.h - map - map_hugetlb - maui_boot.h --media - mconf -+mdp - miboot* - mk_elfconfig - mkboot - mkbugboot - mkcpustr - mkdep -+mkpiggy - mkprep - mkregtable - mktables -@@ -209,6 +223,7 @@ r300_reg_safe.h - r420_reg_safe.h - r600_reg_safe.h - recordmcount -+regdb.c - relocs - rlim_names.h - rn50_reg_safe.h -@@ -219,6 +234,7 @@ setup - setup.bin - setup.elf - sImage -+slabinfo - sm_tbl* - split-include - syscalltab.h -@@ -229,6 +245,7 @@ tftpboot.img - timeconst.h - times.h* - trix_boot.h -+user_constants.h - utsrelease.h* - vdso-syms.lds - vdso.lds -@@ -246,7 +263,9 @@ vmlinux - vmlinux-* - vmlinux.aout - vmlinux.bin.all -+vmlinux.bin.bz2 - vmlinux.lds -+vmlinux.relocs - vmlinuz - voffset.h - vsyscall.lds -@@ -254,9 +273,11 @@ vsyscall_32.lds - wanxlfw.inc - uImage - unifdef -+utsrelease.h - wakeup.bin - wakeup.elf - wakeup.lds - zImage* - zconf.hash.c -+zconf.lex.c - zoffset.h -diff -urNp linux-3.1.4/Documentation/kernel-parameters.txt linux-3.1.4/D= ocumentation/kernel-parameters.txt ---- linux-3.1.4/Documentation/kernel-parameters.txt 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/Documentation/kernel-parameters.txt 2011-11-16 18:39:07.= 000000000 -0500 -@@ -1898,6 +1898,13 @@ bytes respectively. Such letter suffixes - the specified number of seconds. This is to be used if - your oopses keep scrolling off the screen. -=20 -+ pax_nouderef [X86] disables UDEREF. Most likely needed under certain -+ virtualization environments that don't cope well with the -+ expand down segment used by UDEREF on X86-32 or the frequent -+ page table updates on X86-64. -+ -+ pax_softmode=3D 0/1 to disable/enable PaX softmode on boot already. -+ - pcbit=3D [HW,ISDN] -=20 - pcd. [PARIDE] -diff -urNp linux-3.1.4/drivers/acpi/apei/cper.c linux-3.1.4/drivers/acpi= /apei/cper.c ---- linux-3.1.4/drivers/acpi/apei/cper.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/acpi/apei/cper.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/drivers/acpi/apei/cper.c b/drivers/acpi/apei/cper.c +index 5d41894..22021e4 100644 +--- a/drivers/acpi/apei/cper.c ++++ b/drivers/acpi/apei/cper.c @@ -38,12 +38,12 @@ */ u64 cper_next_record_id(void) @@ -24307,9 +24848,10 @@ diff -urNp linux-3.1.4/drivers/acpi/apei/cper.c = linux-3.1.4/drivers/acpi/apei/cp } EXPORT_SYMBOL_GPL(cper_next_record_id); =20 -diff -urNp linux-3.1.4/drivers/acpi/ec_sys.c linux-3.1.4/drivers/acpi/ec= _sys.c ---- linux-3.1.4/drivers/acpi/ec_sys.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/acpi/ec_sys.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/acpi/ec_sys.c b/drivers/acpi/ec_sys.c +index 22f918b..9fafb84 100644 +--- a/drivers/acpi/ec_sys.c ++++ b/drivers/acpi/ec_sys.c @@ -11,6 +11,7 @@ #include #include @@ -24318,7 +24860,7 @@ diff -urNp linux-3.1.4/drivers/acpi/ec_sys.c linu= x-3.1.4/drivers/acpi/ec_sys.c #include "internal.h" =20 MODULE_AUTHOR("Thomas Renninger "); -@@ -39,7 +40,7 @@ static ssize_t acpi_ec_read_io(struct fi +@@ -39,7 +40,7 @@ static ssize_t acpi_ec_read_io(struct file *f, char __= user *buf, * struct acpi_ec *ec =3D ((struct seq_file *)f->private_data)->privat= e; */ unsigned int size =3D EC_SPACE_SIZE; @@ -24327,7 +24869,7 @@ diff -urNp linux-3.1.4/drivers/acpi/ec_sys.c linu= x-3.1.4/drivers/acpi/ec_sys.c loff_t init_off =3D *off; int err =3D 0; =20 -@@ -52,9 +53,11 @@ static ssize_t acpi_ec_read_io(struct fi +@@ -52,9 +53,11 @@ static ssize_t acpi_ec_read_io(struct file *f, char _= _user *buf, size =3D count; =20 while (size) { @@ -24340,7 +24882,7 @@ diff -urNp linux-3.1.4/drivers/acpi/ec_sys.c linu= x-3.1.4/drivers/acpi/ec_sys.c *off +=3D 1; size--; } -@@ -70,7 +73,6 @@ static ssize_t acpi_ec_write_io(struct f +@@ -70,7 +73,6 @@ static ssize_t acpi_ec_write_io(struct file *f, const = char __user *buf, =20 unsigned int size =3D count; loff_t init_off =3D *off; @@ -24348,7 +24890,7 @@ diff -urNp linux-3.1.4/drivers/acpi/ec_sys.c linu= x-3.1.4/drivers/acpi/ec_sys.c int err =3D 0; =20 if (*off >=3D EC_SPACE_SIZE) -@@ -81,7 +83,9 @@ static ssize_t acpi_ec_write_io(struct f +@@ -81,7 +83,9 @@ static ssize_t acpi_ec_write_io(struct file *f, const = char __user *buf, } =20 while (size) { @@ -24359,35 +24901,36 @@ diff -urNp linux-3.1.4/drivers/acpi/ec_sys.c li= nux-3.1.4/drivers/acpi/ec_sys.c err =3D ec_write(*off, byte_write); if (err) return err; -diff -urNp linux-3.1.4/drivers/acpi/proc.c linux-3.1.4/drivers/acpi/proc= .c ---- linux-3.1.4/drivers/acpi/proc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/acpi/proc.c 2011-11-16 18:39:07.000000000 -0500 -@@ -342,19 +342,13 @@ acpi_system_write_wakeup_device(struct f +diff --git a/drivers/acpi/proc.c b/drivers/acpi/proc.c +index f5f9869..da87aeb 100644 +--- a/drivers/acpi/proc.c ++++ b/drivers/acpi/proc.c +@@ -342,19 +342,13 @@ acpi_system_write_wakeup_device(struct file *file, size_t count, loff_t * ppos) { struct list_head *node, *next; - char strbuf[5]; - char str[5] =3D ""; - unsigned int len =3D count; -- ++ char strbuf[5] =3D {0}; +=20 - if (len > 4) - len =3D 4; - if (len < 0) -- return -EFAULT; -+ char strbuf[5] =3D {0}; -=20 -- if (copy_from_user(strbuf, buffer, len)) + if (count > 4) + count =3D 4; + if (copy_from_user(strbuf, buffer, count)) return -EFAULT; +- +- if (copy_from_user(strbuf, buffer, len)) +- return -EFAULT; - strbuf[len] =3D '\0'; - sscanf(strbuf, "%s", str); + strbuf[count] =3D '\0'; =20 mutex_lock(&acpi_device_lock); list_for_each_safe(node, next, &acpi_wakeup_device_list) { -@@ -363,7 +357,7 @@ acpi_system_write_wakeup_device(struct f +@@ -363,7 +357,7 @@ acpi_system_write_wakeup_device(struct file *file, if (!dev->wakeup.flags.valid) continue; =20 @@ -24396,10 +24939,11 @@ diff -urNp linux-3.1.4/drivers/acpi/proc.c linu= x-3.1.4/drivers/acpi/proc.c if (device_can_wakeup(&dev->dev)) { bool enable =3D !device_may_wakeup(&dev->dev); device_set_wakeup_enable(&dev->dev, enable); -diff -urNp linux-3.1.4/drivers/acpi/processor_driver.c linux-3.1.4/drive= rs/acpi/processor_driver.c ---- linux-3.1.4/drivers/acpi/processor_driver.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/acpi/processor_driver.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -473,7 +473,7 @@ static int __cpuinit acpi_processor_add( +diff --git a/drivers/acpi/processor_driver.c b/drivers/acpi/processor_dr= iver.c +index a4e0f1b..9793b28 100644 +--- a/drivers/acpi/processor_driver.c ++++ b/drivers/acpi/processor_driver.c +@@ -473,7 +473,7 @@ static int __cpuinit acpi_processor_add(struct acpi_= device *device) return 0; #endif =20 @@ -24408,10 +24952,11 @@ diff -urNp linux-3.1.4/drivers/acpi/processor_d= river.c linux-3.1.4/drivers/acpi/ =20 /* * Buggy BIOS check -diff -urNp linux-3.1.4/drivers/ata/libata-core.c linux-3.1.4/drivers/ata= /libata-core.c ---- linux-3.1.4/drivers/ata/libata-core.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/ata/libata-core.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -4733,7 +4733,7 @@ void ata_qc_free(struct ata_queued_cmd * +diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c +index 4a3a5ae..cbee192 100644 +--- a/drivers/ata/libata-core.c ++++ b/drivers/ata/libata-core.c +@@ -4733,7 +4733,7 @@ void ata_qc_free(struct ata_queued_cmd *qc) struct ata_port *ap; unsigned int tag; =20 @@ -24420,7 +24965,7 @@ diff -urNp linux-3.1.4/drivers/ata/libata-core.c = linux-3.1.4/drivers/ata/libata- ap =3D qc->ap; =20 qc->flags =3D 0; -@@ -4749,7 +4749,7 @@ void __ata_qc_complete(struct ata_queued +@@ -4749,7 +4749,7 @@ void __ata_qc_complete(struct ata_queued_cmd *qc) struct ata_port *ap; struct ata_link *link; =20 @@ -24429,7 +24974,7 @@ diff -urNp linux-3.1.4/drivers/ata/libata-core.c = linux-3.1.4/drivers/ata/libata- WARN_ON_ONCE(!(qc->flags & ATA_QCFLAG_ACTIVE)); ap =3D qc->ap; link =3D qc->dev->link; -@@ -5754,6 +5754,7 @@ static void ata_finalize_port_ops(struct +@@ -5754,6 +5754,7 @@ static void ata_finalize_port_ops(struct ata_port_= operations *ops) return; =20 spin_lock(&lock); @@ -24437,7 +24982,7 @@ diff -urNp linux-3.1.4/drivers/ata/libata-core.c = linux-3.1.4/drivers/ata/libata- =20 for (cur =3D ops->inherits; cur; cur =3D cur->inherits) { void **inherit =3D (void **)cur; -@@ -5767,8 +5768,9 @@ static void ata_finalize_port_ops(struct +@@ -5767,8 +5768,9 @@ static void ata_finalize_port_ops(struct ata_port_= operations *ops) if (IS_ERR(*pp)) *pp =3D NULL; =20 @@ -24448,9 +24993,10 @@ diff -urNp linux-3.1.4/drivers/ata/libata-core.c= linux-3.1.4/drivers/ata/libata- spin_unlock(&lock); } =20 -diff -urNp linux-3.1.4/drivers/ata/libata-eh.c linux-3.1.4/drivers/ata/l= ibata-eh.c ---- linux-3.1.4/drivers/ata/libata-eh.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/ata/libata-eh.c 2011-11-16 18:40:10.000000000 -0= 500 +diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c +index ed16fbe..fc92cb8 100644 +--- a/drivers/ata/libata-eh.c ++++ b/drivers/ata/libata-eh.c @@ -2515,6 +2515,8 @@ void ata_eh_report(struct ata_port *ap) { struct ata_link *link; @@ -24460,10 +25006,11 @@ diff -urNp linux-3.1.4/drivers/ata/libata-eh.c = linux-3.1.4/drivers/ata/libata-eh ata_for_each_link(link, ap, HOST_FIRST) ata_eh_link_report(link); } -diff -urNp linux-3.1.4/drivers/ata/pata_arasan_cf.c linux-3.1.4/drivers/= ata/pata_arasan_cf.c ---- linux-3.1.4/drivers/ata/pata_arasan_cf.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/ata/pata_arasan_cf.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -862,7 +862,9 @@ static int __devinit arasan_cf_probe(str +diff --git a/drivers/ata/pata_arasan_cf.c b/drivers/ata/pata_arasan_cf.c +index 719bb73..79ce858 100644 +--- a/drivers/ata/pata_arasan_cf.c ++++ b/drivers/ata/pata_arasan_cf.c +@@ -862,7 +862,9 @@ static int __devinit arasan_cf_probe(struct platform= _device *pdev) /* Handle platform specific quirks */ if (pdata->quirk) { if (pdata->quirk & CF_BROKEN_PIO) { @@ -24474,10 +25021,11 @@ diff -urNp linux-3.1.4/drivers/ata/pata_arasan_= cf.c linux-3.1.4/drivers/ata/pata ap->pio_mask =3D 0; } if (pdata->quirk & CF_BROKEN_MWDMA) -diff -urNp linux-3.1.4/drivers/atm/adummy.c linux-3.1.4/drivers/atm/adum= my.c ---- linux-3.1.4/drivers/atm/adummy.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/adummy.c 2011-11-16 18:39:07.000000000 -0500 -@@ -114,7 +114,7 @@ adummy_send(struct atm_vcc *vcc, struct=20 +diff --git a/drivers/atm/adummy.c b/drivers/atm/adummy.c +index f9b983a..887b9d8 100644 +--- a/drivers/atm/adummy.c ++++ b/drivers/atm/adummy.c +@@ -114,7 +114,7 @@ adummy_send(struct atm_vcc *vcc, struct sk_buff *skb= ) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -24486,10 +25034,11 @@ diff -urNp linux-3.1.4/drivers/atm/adummy.c lin= ux-3.1.4/drivers/atm/adummy.c =20 return 0; } -diff -urNp linux-3.1.4/drivers/atm/ambassador.c linux-3.1.4/drivers/atm/= ambassador.c ---- linux-3.1.4/drivers/atm/ambassador.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/atm/ambassador.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -454,7 +454,7 @@ static void tx_complete (amb_dev * dev,=20 +diff --git a/drivers/atm/ambassador.c b/drivers/atm/ambassador.c +index f8f41e0..1f987dd 100644 +--- a/drivers/atm/ambassador.c ++++ b/drivers/atm/ambassador.c +@@ -454,7 +454,7 @@ static void tx_complete (amb_dev * dev, tx_out * tx)= { PRINTD (DBG_FLOW|DBG_TX, "tx_complete %p %p", dev, tx); =20 // VC layer stats @@ -24498,7 +25047,7 @@ diff -urNp linux-3.1.4/drivers/atm/ambassador.c l= inux-3.1.4/drivers/atm/ambassad =20 // free the descriptor kfree (tx_descr); -@@ -495,7 +495,7 @@ static void rx_complete (amb_dev * dev,=20 +@@ -495,7 +495,7 @@ static void rx_complete (amb_dev * dev, rx_out * rx)= { dump_skb ("<<<", vc, skb); =20 // VC layer stats @@ -24507,7 +25056,7 @@ diff -urNp linux-3.1.4/drivers/atm/ambassador.c l= inux-3.1.4/drivers/atm/ambassad __net_timestamp(skb); // end of our responsibility atm_vcc->push (atm_vcc, skb); -@@ -510,7 +510,7 @@ static void rx_complete (amb_dev * dev,=20 +@@ -510,7 +510,7 @@ static void rx_complete (amb_dev * dev, rx_out * rx)= { } else { PRINTK (KERN_INFO, "dropped over-size frame"); // should we count this? @@ -24516,7 +25065,7 @@ diff -urNp linux-3.1.4/drivers/atm/ambassador.c l= inux-3.1.4/drivers/atm/ambassad } =20 } else { -@@ -1338,7 +1338,7 @@ static int amb_send (struct atm_vcc * at +@@ -1338,7 +1338,7 @@ static int amb_send (struct atm_vcc * atm_vcc, str= uct sk_buff * skb) { } =20 if (check_area (skb->data, skb->len)) { @@ -24525,10 +25074,11 @@ diff -urNp linux-3.1.4/drivers/atm/ambassador.c= linux-3.1.4/drivers/atm/ambassad return -ENOMEM; // ? } =20 -diff -urNp linux-3.1.4/drivers/atm/atmtcp.c linux-3.1.4/drivers/atm/atmt= cp.c ---- linux-3.1.4/drivers/atm/atmtcp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/atmtcp.c 2011-11-16 18:39:07.000000000 -0500 -@@ -207,7 +207,7 @@ static int atmtcp_v_send(struct atm_vcc=20 +diff --git a/drivers/atm/atmtcp.c b/drivers/atm/atmtcp.c +index b22d71c..d6e1049 100644 +--- a/drivers/atm/atmtcp.c ++++ b/drivers/atm/atmtcp.c +@@ -207,7 +207,7 @@ static int atmtcp_v_send(struct atm_vcc *vcc,struct = sk_buff *skb) if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); if (dev_data) return 0; @@ -24537,7 +25087,7 @@ diff -urNp linux-3.1.4/drivers/atm/atmtcp.c linux= -3.1.4/drivers/atm/atmtcp.c return -ENOLINK; } size =3D skb->len+sizeof(struct atmtcp_hdr); -@@ -215,7 +215,7 @@ static int atmtcp_v_send(struct atm_vcc=20 +@@ -215,7 +215,7 @@ static int atmtcp_v_send(struct atm_vcc *vcc,struct = sk_buff *skb) if (!new_skb) { if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); @@ -24546,7 +25096,7 @@ diff -urNp linux-3.1.4/drivers/atm/atmtcp.c linux= -3.1.4/drivers/atm/atmtcp.c return -ENOBUFS; } hdr =3D (void *) skb_put(new_skb,sizeof(struct atmtcp_hdr)); -@@ -226,8 +226,8 @@ static int atmtcp_v_send(struct atm_vcc=20 +@@ -226,8 +226,8 @@ static int atmtcp_v_send(struct atm_vcc *vcc,struct = sk_buff *skb) if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); out_vcc->push(out_vcc,new_skb); @@ -24557,7 +25107,7 @@ diff -urNp linux-3.1.4/drivers/atm/atmtcp.c linux= -3.1.4/drivers/atm/atmtcp.c return 0; } =20 -@@ -301,7 +301,7 @@ static int atmtcp_c_send(struct atm_vcc=20 +@@ -301,7 +301,7 @@ static int atmtcp_c_send(struct atm_vcc *vcc,struct = sk_buff *skb) out_vcc =3D find_vcc(dev, ntohs(hdr->vpi), ntohs(hdr->vci)); read_unlock(&vcc_sklist_lock); if (!out_vcc) { @@ -24566,7 +25116,7 @@ diff -urNp linux-3.1.4/drivers/atm/atmtcp.c linux= -3.1.4/drivers/atm/atmtcp.c goto done; } skb_pull(skb,sizeof(struct atmtcp_hdr)); -@@ -313,8 +313,8 @@ static int atmtcp_c_send(struct atm_vcc=20 +@@ -313,8 +313,8 @@ static int atmtcp_c_send(struct atm_vcc *vcc,struct = sk_buff *skb) __net_timestamp(new_skb); skb_copy_from_linear_data(skb, skb_put(new_skb, skb->len), skb->len); out_vcc->push(out_vcc,new_skb); @@ -24577,9 +25127,10 @@ diff -urNp linux-3.1.4/drivers/atm/atmtcp.c linu= x-3.1.4/drivers/atm/atmtcp.c done: if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); -diff -urNp linux-3.1.4/drivers/atm/eni.c linux-3.1.4/drivers/atm/eni.c ---- linux-3.1.4/drivers/atm/eni.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/eni.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/atm/eni.c b/drivers/atm/eni.c +index 9307141..d8521bf 100644 +--- a/drivers/atm/eni.c ++++ b/drivers/atm/eni.c @@ -526,7 +526,7 @@ static int rx_aal0(struct atm_vcc *vcc) DPRINTK(DEV_LABEL "(itf %d): trashing empty cell\n", vcc->dev->number); @@ -24616,7 +25167,7 @@ diff -urNp linux-3.1.4/drivers/atm/eni.c linux-3.= 1.4/drivers/atm/eni.c } wake_up(&eni_dev->rx_wait); } -@@ -1228,7 +1228,7 @@ static void dequeue_tx(struct atm_dev *d +@@ -1228,7 +1228,7 @@ static void dequeue_tx(struct atm_dev *dev) PCI_DMA_TODEVICE); if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb_irq(skb); @@ -24634,10 +25185,11 @@ diff -urNp linux-3.1.4/drivers/atm/eni.c linux-= 3.1.4/drivers/atm/eni.c "MMF", "SMF", "MMF", "03?", /* 0- 3 */ "UTP", "05?", "06?", "07?", /* 4- 7 */ "TAXI","09?", "10?", "11?", /* 8-11 */ -diff -urNp linux-3.1.4/drivers/atm/firestream.c linux-3.1.4/drivers/atm/= firestream.c ---- linux-3.1.4/drivers/atm/firestream.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/atm/firestream.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -750,7 +750,7 @@ static void process_txdone_queue (struct +diff --git a/drivers/atm/firestream.c b/drivers/atm/firestream.c +index 5072f8a..fa52520 100644 +--- a/drivers/atm/firestream.c ++++ b/drivers/atm/firestream.c +@@ -750,7 +750,7 @@ static void process_txdone_queue (struct fs_dev *dev= , struct queue *q) } } =20 @@ -24646,7 +25198,7 @@ diff -urNp linux-3.1.4/drivers/atm/firestream.c l= inux-3.1.4/drivers/atm/firestre =20 fs_dprintk (FS_DEBUG_TXMEM, "i"); fs_dprintk (FS_DEBUG_ALLOC, "Free t-skb: %p\n", skb); -@@ -817,7 +817,7 @@ static void process_incoming (struct fs_ +@@ -817,7 +817,7 @@ static void process_incoming (struct fs_dev *dev, st= ruct queue *q) #endif skb_put (skb, qe->p1 & 0xffff);=20 ATM_SKB(skb)->vcc =3D atm_vcc; @@ -24655,7 +25207,7 @@ diff -urNp linux-3.1.4/drivers/atm/firestream.c l= inux-3.1.4/drivers/atm/firestre __net_timestamp(skb); fs_dprintk (FS_DEBUG_ALLOC, "Free rec-skb: %p (pushed)\n", skb); atm_vcc->push (atm_vcc, skb); -@@ -838,12 +838,12 @@ static void process_incoming (struct fs_ +@@ -838,12 +838,12 @@ static void process_incoming (struct fs_dev *dev, = struct queue *q) kfree (pe); } if (atm_vcc) @@ -24670,10 +25222,11 @@ diff -urNp linux-3.1.4/drivers/atm/firestream.c= linux-3.1.4/drivers/atm/firestre break; default: /* Hmm. Haven't written the code to handle the others yet...= -- REW */ printk (KERN_WARNING "Don't know what to do with RX status %x: %s.\n= ",=20 -diff -urNp linux-3.1.4/drivers/atm/fore200e.c linux-3.1.4/drivers/atm/fo= re200e.c ---- linux-3.1.4/drivers/atm/fore200e.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/atm/fore200e.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -933,9 +933,9 @@ fore200e_tx_irq(struct fore200e* fore200 +diff --git a/drivers/atm/fore200e.c b/drivers/atm/fore200e.c +index 361f5ae..7fc552d 100644 +--- a/drivers/atm/fore200e.c ++++ b/drivers/atm/fore200e.c +@@ -933,9 +933,9 @@ fore200e_tx_irq(struct fore200e* fore200e) #endif /* check error condition */ if (*entry->status & STATUS_ERROR) @@ -24685,7 +25238,7 @@ diff -urNp linux-3.1.4/drivers/atm/fore200e.c lin= ux-3.1.4/drivers/atm/fore200e.c } } =20 -@@ -1084,7 +1084,7 @@ fore200e_push_rpd(struct fore200e* fore2 +@@ -1084,7 +1084,7 @@ fore200e_push_rpd(struct fore200e* fore200e, struc= t atm_vcc* vcc, struct rpd* rp if (skb =3D=3D NULL) { DPRINTK(2, "unable to alloc new skb, rx PDU length =3D %d\n", pdu_len)= ; =20 @@ -24694,7 +25247,7 @@ diff -urNp linux-3.1.4/drivers/atm/fore200e.c lin= ux-3.1.4/drivers/atm/fore200e.c return -ENOMEM; }=20 =20 -@@ -1127,14 +1127,14 @@ fore200e_push_rpd(struct fore200e* fore2 +@@ -1127,14 +1127,14 @@ fore200e_push_rpd(struct fore200e* fore200e, str= uct atm_vcc* vcc, struct rpd* rp =20 dev_kfree_skb_any(skb); =20 @@ -24711,7 +25264,7 @@ diff -urNp linux-3.1.4/drivers/atm/fore200e.c lin= ux-3.1.4/drivers/atm/fore200e.c =20 ASSERT(atomic_read(&sk_atm(vcc)->sk_wmem_alloc) >=3D 0); =20 -@@ -1212,7 +1212,7 @@ fore200e_rx_irq(struct fore200e* fore200 +@@ -1212,7 +1212,7 @@ fore200e_rx_irq(struct fore200e* fore200e) DPRINTK(2, "damaged PDU on %d.%d.%d\n", fore200e->atm_dev->number, entry->rpd->atm_header.vpi, entry->rpd->atm_header.vci); @@ -24720,7 +25273,7 @@ diff -urNp linux-3.1.4/drivers/atm/fore200e.c lin= ux-3.1.4/drivers/atm/fore200e.c } } =20 -@@ -1657,7 +1657,7 @@ fore200e_send(struct atm_vcc *vcc, struc +@@ -1657,7 +1657,7 @@ fore200e_send(struct atm_vcc *vcc, struct sk_buff = *skb) goto retry_here; } =20 @@ -24729,10 +25282,11 @@ diff -urNp linux-3.1.4/drivers/atm/fore200e.c l= inux-3.1.4/drivers/atm/fore200e.c =20 fore200e->tx_sat++; DPRINTK(2, "tx queue of device %s is saturated, PDU dropped - hear= tbeat is %08x\n", -diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1.4/drivers/atm/he.c ---- linux-3.1.4/drivers/atm/he.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/he.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1709,7 +1709,7 @@ he_service_rbrq(struct he_dev *he_dev, i +diff --git a/drivers/atm/he.c b/drivers/atm/he.c +index 9a51df4..f3bb5f8 100644 +--- a/drivers/atm/he.c ++++ b/drivers/atm/he.c +@@ -1709,7 +1709,7 @@ he_service_rbrq(struct he_dev *he_dev, int group) =20 if (RBRQ_HBUF_ERR(he_dev->rbrq_head)) { hprintk("HBUF_ERR! (cid 0x%x)\n", cid); @@ -24741,7 +25295,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c goto return_host_buffers; } =20 -@@ -1736,7 +1736,7 @@ he_service_rbrq(struct he_dev *he_dev, i +@@ -1736,7 +1736,7 @@ he_service_rbrq(struct he_dev *he_dev, int group) RBRQ_LEN_ERR(he_dev->rbrq_head) ? "LEN_ERR" : "", vcc->vpi, vcc->vci); @@ -24750,7 +25304,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c goto return_host_buffers; } =20 -@@ -1788,7 +1788,7 @@ he_service_rbrq(struct he_dev *he_dev, i +@@ -1788,7 +1788,7 @@ he_service_rbrq(struct he_dev *he_dev, int group) vcc->push(vcc, skb); spin_lock(&he_dev->global_lock); =20 @@ -24759,7 +25313,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c =20 return_host_buffers: ++pdus_assembled; -@@ -2114,7 +2114,7 @@ __enqueue_tpd(struct he_dev *he_dev, str +@@ -2114,7 +2114,7 @@ __enqueue_tpd(struct he_dev *he_dev, struct he_tpd= *tpd, unsigned cid) tpd->vcc->pop(tpd->vcc, tpd->skb); else dev_kfree_skb_any(tpd->skb); @@ -24768,7 +25322,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c } pci_pool_free(he_dev->tpd_pool, tpd, TPD_ADDR(tpd->status)); return; -@@ -2526,7 +2526,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2526,7 +2526,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -24777,7 +25331,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c return -EINVAL; } =20 -@@ -2537,7 +2537,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2537,7 +2537,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -24786,7 +25340,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c return -EINVAL; } #endif -@@ -2549,7 +2549,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2549,7 +2549,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -24795,7 +25349,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c spin_unlock_irqrestore(&he_dev->global_lock, flags); return -ENOMEM; } -@@ -2591,7 +2591,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2591,7 +2591,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) vcc->pop(vcc, skb); else dev_kfree_skb_any(skb); @@ -24804,7 +25358,7 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3.1= .4/drivers/atm/he.c spin_unlock_irqrestore(&he_dev->global_lock, flags); return -ENOMEM; } -@@ -2622,7 +2622,7 @@ he_send(struct atm_vcc *vcc, struct sk_b +@@ -2622,7 +2622,7 @@ he_send(struct atm_vcc *vcc, struct sk_buff *skb) __enqueue_tpd(he_dev, tpd, cid); spin_unlock_irqrestore(&he_dev->global_lock, flags); =20 @@ -24813,10 +25367,11 @@ diff -urNp linux-3.1.4/drivers/atm/he.c linux-3= .1.4/drivers/atm/he.c =20 return 0; } -diff -urNp linux-3.1.4/drivers/atm/horizon.c linux-3.1.4/drivers/atm/hor= izon.c ---- linux-3.1.4/drivers/atm/horizon.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/atm/horizon.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -1035,7 +1035,7 @@ static void rx_schedule (hrz_dev * dev,=20 +diff --git a/drivers/atm/horizon.c b/drivers/atm/horizon.c +index b812103..e391a49 100644 +--- a/drivers/atm/horizon.c ++++ b/drivers/atm/horizon.c +@@ -1035,7 +1035,7 @@ static void rx_schedule (hrz_dev * dev, int irq) { { struct atm_vcc * vcc =3D ATM_SKB(skb)->vcc; // VC layer stats @@ -24825,7 +25380,7 @@ diff -urNp linux-3.1.4/drivers/atm/horizon.c linu= x-3.1.4/drivers/atm/horizon.c __net_timestamp(skb); // end of our responsibility vcc->push (vcc, skb); -@@ -1187,7 +1187,7 @@ static void tx_schedule (hrz_dev * const +@@ -1187,7 +1187,7 @@ static void tx_schedule (hrz_dev * const dev, int = irq) { dev->tx_iovec =3D NULL; =09 // VC layer stats @@ -24834,10 +25389,11 @@ diff -urNp linux-3.1.4/drivers/atm/horizon.c li= nux-3.1.4/drivers/atm/horizon.c =09 // free the skb hrz_kfree_skb (skb); -diff -urNp linux-3.1.4/drivers/atm/idt77252.c linux-3.1.4/drivers/atm/id= t77252.c ---- linux-3.1.4/drivers/atm/idt77252.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/atm/idt77252.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -812,7 +812,7 @@ drain_scq(struct idt77252_dev *card, str +diff --git a/drivers/atm/idt77252.c b/drivers/atm/idt77252.c +index db06f34..dcebb61 100644 +--- a/drivers/atm/idt77252.c ++++ b/drivers/atm/idt77252.c +@@ -812,7 +812,7 @@ drain_scq(struct idt77252_dev *card, struct vc_map *= vc) else dev_kfree_skb(skb); =20 @@ -24846,7 +25402,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c } =20 atomic_dec(&scq->used); -@@ -1075,13 +1075,13 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1075,13 +1075,13 @@ dequeue_rx(struct idt77252_dev *card, struct rsq= _entry *rsqe) if ((sb =3D dev_alloc_skb(64)) =3D=3D NULL) { printk("%s: Can't allocate buffers for aal0.\n", card->name); @@ -24862,7 +25418,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c dev_kfree_skb(sb); break; } -@@ -1098,7 +1098,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1098,7 +1098,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -24871,7 +25427,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c =20 cell +=3D ATM_CELL_PAYLOAD; } -@@ -1135,13 +1135,13 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1135,13 +1135,13 @@ dequeue_rx(struct idt77252_dev *card, struct rsq= _entry *rsqe) "(CDC: %08x)\n", card->name, len, rpp->len, readl(SAR_REG_CDC)); recycle_rx_pool_skb(card, rpp); @@ -24887,7 +25443,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c return; } if (skb_queue_len(&rpp->queue) > 1) { -@@ -1152,7 +1152,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1152,7 +1152,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) RXPRINTK("%s: Can't alloc RX skb.\n", card->name); recycle_rx_pool_skb(card, rpp); @@ -24896,7 +25452,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c return; } if (!atm_charge(vcc, skb->truesize)) { -@@ -1171,7 +1171,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1171,7 +1171,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) __net_timestamp(skb); =20 vcc->push(vcc, skb); @@ -24905,7 +25461,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c =20 return; } -@@ -1193,7 +1193,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1193,7 +1193,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_e= ntry *rsqe) __net_timestamp(skb); =20 vcc->push(vcc, skb); @@ -24914,7 +25470,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c =20 if (skb->truesize > SAR_FB_SIZE_3) add_rx_skb(card, 3, SAR_FB_SIZE_3, 1); -@@ -1304,14 +1304,14 @@ idt77252_rx_raw(struct idt77252_dev *car +@@ -1304,14 +1304,14 @@ idt77252_rx_raw(struct idt77252_dev *card) if (vcc->qos.aal !=3D ATM_AAL0) { RPRINTK("%s: raw cell for non AAL0 vc %u.%u\n", card->name, vpi, vci); @@ -24931,7 +25487,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c goto drop; } =20 -@@ -1330,7 +1330,7 @@ idt77252_rx_raw(struct idt77252_dev *car +@@ -1330,7 +1330,7 @@ idt77252_rx_raw(struct idt77252_dev *card) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -24940,7 +25496,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c =20 drop: skb_pull(queue, 64); -@@ -1955,13 +1955,13 @@ idt77252_send_skb(struct atm_vcc *vcc, s +@@ -1955,13 +1955,13 @@ idt77252_send_skb(struct atm_vcc *vcc, struct sk= _buff *skb, int oam) =20 if (vc =3D=3D NULL) { printk("%s: NULL connection in send().\n", card->name); @@ -24956,7 +25512,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c dev_kfree_skb(skb); return -EINVAL; } -@@ -1973,14 +1973,14 @@ idt77252_send_skb(struct atm_vcc *vcc, s +@@ -1973,14 +1973,14 @@ idt77252_send_skb(struct atm_vcc *vcc, struct sk= _buff *skb, int oam) break; default: printk("%s: Unsupported AAL: %d\n", card->name, vcc->qos.aal); @@ -24973,7 +25529,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c dev_kfree_skb(skb); return -EINVAL; } -@@ -1988,7 +1988,7 @@ idt77252_send_skb(struct atm_vcc *vcc, s +@@ -1988,7 +1988,7 @@ idt77252_send_skb(struct atm_vcc *vcc, struct sk_b= uff *skb, int oam) =20 err =3D queue_skb(card, vc, skb, oam); if (err) { @@ -24982,7 +25538,7 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c lin= ux-3.1.4/drivers/atm/idt77252.c dev_kfree_skb(skb); return err; } -@@ -2011,7 +2011,7 @@ idt77252_send_oam(struct atm_vcc *vcc, v +@@ -2011,7 +2011,7 @@ idt77252_send_oam(struct atm_vcc *vcc, void *cell,= int flags) skb =3D dev_alloc_skb(64); if (!skb) { printk("%s: Out of memory in send_oam().\n", card->name); @@ -24991,10 +25547,11 @@ diff -urNp linux-3.1.4/drivers/atm/idt77252.c l= inux-3.1.4/drivers/atm/idt77252.c return -ENOMEM; } atomic_add(skb->truesize, &sk_atm(vcc)->sk_wmem_alloc); -diff -urNp linux-3.1.4/drivers/atm/iphase.c linux-3.1.4/drivers/atm/ipha= se.c ---- linux-3.1.4/drivers/atm/iphase.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/iphase.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1121,7 +1121,7 @@ static int rx_pkt(struct atm_dev *dev) =20 +diff --git a/drivers/atm/iphase.c b/drivers/atm/iphase.c +index cb90f7a..bd33566 100644 +--- a/drivers/atm/iphase.c ++++ b/drivers/atm/iphase.c +@@ -1121,7 +1121,7 @@ static int rx_pkt(struct atm_dev *dev) status =3D (u_short) (buf_desc_ptr->desc_mode); =20 if (status & (RX_CER | RX_PTE | RX_OFL)) =20 { =20 @@ -25003,7 +25560,7 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c linux= -3.1.4/drivers/atm/iphase.c IF_ERR(printk("IA: bad packet, dropping it");) =20 if (status & RX_CER) {=20 IF_ERR(printk(" cause: packet CRC error\n");) -@@ -1144,7 +1144,7 @@ static int rx_pkt(struct atm_dev *dev) =20 +@@ -1144,7 +1144,7 @@ static int rx_pkt(struct atm_dev *dev) len =3D dma_addr - buf_addr; =20 if (len > iadev->rx_buf_sz) { printk("Over %d bytes sdu received, dropped!!!\n", iadev->rx= _buf_sz); @@ -25012,7 +25569,7 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c linux= -3.1.4/drivers/atm/iphase.c goto out_free_desc; } =20 -@@ -1294,7 +1294,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1294,7 +1294,7 @@ static void rx_dle_intr(struct atm_dev *dev) ia_vcc =3D INPH_IA_VCC(vcc); if (ia_vcc =3D=3D NULL) { @@ -25021,7 +25578,7 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c linux= -3.1.4/drivers/atm/iphase.c dev_kfree_skb_any(skb); atm_return(vcc, atm_guess_pdu2truesize(len)); goto INCR_DLE; -@@ -1306,7 +1306,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1306,7 +1306,7 @@ static void rx_dle_intr(struct atm_dev *dev) if ((length > iadev->rx_buf_sz) || (length >=20 (skb->len - sizeof(struct cpcs_trailer)))= ) { @@ -25030,7 +25587,7 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c linux= -3.1.4/drivers/atm/iphase.c IF_ERR(printk("rx_dle_intr: Bad AAL5 trailer %d (skb len = %d)",=20 length, skb= ->len);) dev_kfree_skb_any(skb); -@@ -1322,7 +1322,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1322,7 +1322,7 @@ static void rx_dle_intr(struct atm_dev *dev) =20 IF_RX(printk("rx_dle_intr: skb push");) =20 vcc->push(vcc,skb); =20 @@ -25039,7 +25596,7 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c linux= -3.1.4/drivers/atm/iphase.c iadev->rx_pkt_cnt++; } =20 INCR_DLE: -@@ -2802,15 +2802,15 @@ static int ia_ioctl(struct atm_dev *dev, +@@ -2802,15 +2802,15 @@ static int ia_ioctl(struct atm_dev *dev, unsigne= d int cmd, void __user *arg) { struct k_sonet_stats *stats; stats =3D &PRIV(_ia_dev[board])->sonet_stats; @@ -25064,7 +25621,7 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c linux= -3.1.4/drivers/atm/iphase.c } ia_cmds.status =3D 0; break; -@@ -2915,7 +2915,7 @@ static int ia_pkt_tx (struct atm_vcc *vc +@@ -2915,7 +2915,7 @@ static int ia_pkt_tx (struct atm_vcc *vcc, struct = sk_buff *skb) { if ((desc =3D=3D 0) || (desc > iadev->num_tx_desc)) =20 { =20 IF_ERR(printk(DEV_LABEL "invalid desc for send: %d\n", desc);)=20 @@ -25073,7 +25630,7 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c linux= -3.1.4/drivers/atm/iphase.c if (vcc->pop) =20 vcc->pop(vcc, skb); =20 else =20 -@@ -3020,14 +3020,14 @@ static int ia_pkt_tx (struct atm_vcc *vc +@@ -3020,14 +3020,14 @@ static int ia_pkt_tx (struct atm_vcc *vcc, struc= t sk_buff *skb) { ATM_DESC(skb) =3D vcc->vci; skb_queue_tail(&iadev->tx_dma_q, skb); =20 @@ -25090,10 +25647,11 @@ diff -urNp linux-3.1.4/drivers/atm/iphase.c lin= ux-3.1.4/drivers/atm/iphase.c if (iavcc->vc_desc_cnt > 10) { vcc->tx_quota =3D vcc->tx_quota * 3 / 4; printk("Tx1: vcc->tx_quota =3D %d \n", (u32)vcc->tx_quota = ); -diff -urNp linux-3.1.4/drivers/atm/lanai.c linux-3.1.4/drivers/atm/lanai= .c ---- linux-3.1.4/drivers/atm/lanai.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/lanai.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1303,7 +1303,7 @@ static void lanai_send_one_aal5(struct l +diff --git a/drivers/atm/lanai.c b/drivers/atm/lanai.c +index e828c54..ae83976 100644 +--- a/drivers/atm/lanai.c ++++ b/drivers/atm/lanai.c +@@ -1303,7 +1303,7 @@ static void lanai_send_one_aal5(struct lanai_dev *= lanai, vcc_tx_add_aal5_trailer(lvcc, skb->len, 0, 0); lanai_endtx(lanai, lvcc); lanai_free_skb(lvcc->tx.atmvcc, skb); @@ -25102,7 +25660,7 @@ diff -urNp linux-3.1.4/drivers/atm/lanai.c linux-= 3.1.4/drivers/atm/lanai.c } =20 /* Try to fill the buffer - don't call unless there is backlog */ -@@ -1426,7 +1426,7 @@ static void vcc_rx_aal5(struct lanai_vcc +@@ -1426,7 +1426,7 @@ static void vcc_rx_aal5(struct lanai_vcc *lvcc, in= t endptr) ATM_SKB(skb)->vcc =3D lvcc->rx.atmvcc; __net_timestamp(skb); lvcc->rx.atmvcc->push(lvcc->rx.atmvcc, skb); @@ -25111,7 +25669,7 @@ diff -urNp linux-3.1.4/drivers/atm/lanai.c linux-= 3.1.4/drivers/atm/lanai.c out: lvcc->rx.buf.ptr =3D end; cardvcc_write(lvcc, endptr, vcc_rxreadptr); -@@ -1668,7 +1668,7 @@ static int handle_service(struct lanai_d +@@ -1668,7 +1668,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) DPRINTK("(itf %d) got RX service entry 0x%X for non-AAL5 " "vcc %d\n", lanai->number, (unsigned int) s, vci); lanai->stats.service_rxnotaal5++; @@ -25120,7 +25678,7 @@ diff -urNp linux-3.1.4/drivers/atm/lanai.c linux-= 3.1.4/drivers/atm/lanai.c return 0; } if (likely(!(s & (SERVICE_TRASH | SERVICE_STREAM | SERVICE_CRCERR)))) = { -@@ -1680,7 +1680,7 @@ static int handle_service(struct lanai_d +@@ -1680,7 +1680,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) int bytes; read_unlock(&vcc_sklist_lock); DPRINTK("got trashed rx pdu on vci %d\n", vci); @@ -25129,7 +25687,7 @@ diff -urNp linux-3.1.4/drivers/atm/lanai.c linux-= 3.1.4/drivers/atm/lanai.c lvcc->stats.x.aal5.service_trash++; bytes =3D (SERVICE_GET_END(s) * 16) - (((unsigned long) lvcc->rx.buf.ptr) - -@@ -1692,7 +1692,7 @@ static int handle_service(struct lanai_d +@@ -1692,7 +1692,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) } if (s & SERVICE_STREAM) { read_unlock(&vcc_sklist_lock); @@ -25138,7 +25696,7 @@ diff -urNp linux-3.1.4/drivers/atm/lanai.c linux-= 3.1.4/drivers/atm/lanai.c lvcc->stats.x.aal5.service_stream++; printk(KERN_ERR DEV_LABEL "(itf %d): Got AAL5 stream " "PDU on VCI %d!\n", lanai->number, vci); -@@ -1700,7 +1700,7 @@ static int handle_service(struct lanai_d +@@ -1700,7 +1700,7 @@ static int handle_service(struct lanai_dev *lanai,= u32 s) return 0; } DPRINTK("got rx crc error on vci %d\n", vci); @@ -25147,10 +25705,11 @@ diff -urNp linux-3.1.4/drivers/atm/lanai.c linu= x-3.1.4/drivers/atm/lanai.c lvcc->stats.x.aal5.service_rxcrc++; lvcc->rx.buf.ptr =3D &lvcc->rx.buf.start[SERVICE_GET_END(s) * 4]; cardvcc_write(lvcc, SERVICE_GET_END(s), vcc_rxreadptr); -diff -urNp linux-3.1.4/drivers/atm/nicstar.c linux-3.1.4/drivers/atm/nic= star.c ---- linux-3.1.4/drivers/atm/nicstar.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/atm/nicstar.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -1654,7 +1654,7 @@ static int ns_send(struct atm_vcc *vcc,=20 +diff --git a/drivers/atm/nicstar.c b/drivers/atm/nicstar.c +index 1c70c45..300718d 100644 +--- a/drivers/atm/nicstar.c ++++ b/drivers/atm/nicstar.c +@@ -1654,7 +1654,7 @@ static int ns_send(struct atm_vcc *vcc, struct sk_= buff *skb) if ((vc =3D (vc_map *) vcc->dev_data) =3D=3D NULL) { printk("nicstar%d: vcc->dev_data =3D=3D NULL on ns_send().\n", card->index); @@ -25159,7 +25718,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1662,7 +1662,7 @@ static int ns_send(struct atm_vcc *vcc,=20 +@@ -1662,7 +1662,7 @@ static int ns_send(struct atm_vcc *vcc, struct sk_= buff *skb) if (!vc->tx) { printk("nicstar%d: Trying to transmit on a non-tx VC.\n", card->index); @@ -25168,7 +25727,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1670,14 +1670,14 @@ static int ns_send(struct atm_vcc *vcc,=20 +@@ -1670,14 +1670,14 @@ static int ns_send(struct atm_vcc *vcc, struct s= k_buff *skb) if (vcc->qos.aal !=3D ATM_AAL5 && vcc->qos.aal !=3D ATM_AAL0) { printk("nicstar%d: Only AAL0 and AAL5 are supported.\n", card->index); @@ -25185,7 +25744,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1725,11 +1725,11 @@ static int ns_send(struct atm_vcc *vcc,=20 +@@ -1725,11 +1725,11 @@ static int ns_send(struct atm_vcc *vcc, struct s= k_buff *skb) } =20 if (push_scqe(card, vc, scq, &scqe, skb) !=3D 0) { @@ -25199,7 +25758,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c =20 return 0; } -@@ -2046,14 +2046,14 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2046,14 +2046,14 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * = rsqe) printk ("nicstar%d: Can't allocate buffers for aal0.\n", card->index); @@ -25216,7 +25775,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c dev_kfree_skb_any(sb); break; } -@@ -2068,7 +2068,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2068,7 +2068,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -25225,7 +25784,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c cell +=3D ATM_CELL_PAYLOAD; } =20 -@@ -2085,7 +2085,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2085,7 +2085,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) if (iovb =3D=3D NULL) { printk("nicstar%d: Out of iovec buffers.\n", card->index); @@ -25234,7 +25793,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c recycle_rx_buf(card, skb); return; } -@@ -2109,7 +2109,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2109,7 +2109,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) small or large buffer itself. */ } else if (NS_PRV_IOVCNT(iovb) >=3D NS_MAX_IOVECS) { printk("nicstar%d: received too big AAL5 SDU.\n", card->index); @@ -25243,7 +25802,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c recycle_iovec_rx_bufs(card, (struct iovec *)iovb->data, NS_MAX_IOVECS); NS_PRV_IOVCNT(iovb) =3D 0; -@@ -2129,7 +2129,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2129,7 +2129,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) ("nicstar%d: Expected a small buffer, and this is not one.\n", card->index); which_list(card, skb); @@ -25252,7 +25811,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c recycle_rx_buf(card, skb); vc->rx_iov =3D NULL; recycle_iov_buf(card, iovb); -@@ -2142,7 +2142,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2142,7 +2142,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) ("nicstar%d: Expected a large buffer, and this is not one.\n", card->index); which_list(card, skb); @@ -25261,7 +25820,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c recycle_iovec_rx_bufs(card, (struct iovec *)iovb->data, NS_PRV_IOVCNT(iovb)); vc->rx_iov =3D NULL; -@@ -2165,7 +2165,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2165,7 +2165,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) printk(" - PDU size mismatch.\n"); else printk(".\n"); @@ -25270,7 +25829,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c recycle_iovec_rx_bufs(card, (struct iovec *)iovb->data, NS_PRV_IOVCNT(iovb)); vc->rx_iov =3D NULL; -@@ -2179,7 +2179,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2179,7 +2179,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) /* skb points to a small buffer */ if (!atm_charge(vcc, skb->truesize)) { push_rxbufs(card, skb); @@ -25279,7 +25838,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c } else { skb_put(skb, len); dequeue_sm_buf(card, skb); -@@ -2189,7 +2189,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2189,7 +2189,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) ATM_SKB(skb)->vcc =3D vcc; __net_timestamp(skb); vcc->push(vcc, skb); @@ -25288,7 +25847,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c } } else if (NS_PRV_IOVCNT(iovb) =3D=3D 2) { /* One small plus one larg= e buffer */ struct sk_buff *sb; -@@ -2200,7 +2200,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2200,7 +2200,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) if (len <=3D NS_SMBUFSIZE) { if (!atm_charge(vcc, sb->truesize)) { push_rxbufs(card, sb); @@ -25297,7 +25856,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c } else { skb_put(sb, len); dequeue_sm_buf(card, sb); -@@ -2210,7 +2210,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2210,7 +2210,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) ATM_SKB(sb)->vcc =3D vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -25306,7 +25865,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c } =20 push_rxbufs(card, skb); -@@ -2219,7 +2219,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2219,7 +2219,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) =20 if (!atm_charge(vcc, skb->truesize)) { push_rxbufs(card, skb); @@ -25315,7 +25874,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c } else { dequeue_lg_buf(card, skb); #ifdef NS_USE_DESTRUCTORS -@@ -2232,7 +2232,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2232,7 +2232,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) ATM_SKB(skb)->vcc =3D vcc; __net_timestamp(skb); vcc->push(vcc, skb); @@ -25324,7 +25883,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c } =20 push_rxbufs(card, sb); -@@ -2253,7 +2253,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2253,7 +2253,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) printk ("nicstar%d: Out of huge buffers.\n", card->index); @@ -25333,7 +25892,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c recycle_iovec_rx_bufs(card, (struct iovec *) iovb->data, -@@ -2304,7 +2304,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2304,7 +2304,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) card->hbpool.count++; } else dev_kfree_skb_any(hb); @@ -25342,7 +25901,7 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c linu= x-3.1.4/drivers/atm/nicstar.c } else { /* Copy the small buffer to the huge buffer */ sb =3D (struct sk_buff *)iov->iov_base; -@@ -2341,7 +2341,7 @@ static void dequeue_rx(ns_dev * card, ns +@@ -2341,7 +2341,7 @@ static void dequeue_rx(ns_dev * card, ns_rsqe * rs= qe) #endif /* NS_USE_DESTRUCTORS */ __net_timestamp(hb); vcc->push(vcc, hb); @@ -25351,9 +25910,10 @@ diff -urNp linux-3.1.4/drivers/atm/nicstar.c lin= ux-3.1.4/drivers/atm/nicstar.c } } =20 -diff -urNp linux-3.1.4/drivers/atm/solos-pci.c linux-3.1.4/drivers/atm/s= olos-pci.c ---- linux-3.1.4/drivers/atm/solos-pci.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/atm/solos-pci.c 2011-11-16 18:40:10.000000000 -0= 500 +diff --git a/drivers/atm/solos-pci.c b/drivers/atm/solos-pci.c +index 5d1d076..4f31f42 100644 +--- a/drivers/atm/solos-pci.c ++++ b/drivers/atm/solos-pci.c @@ -714,7 +714,7 @@ void solos_bh(unsigned long card_arg) } atm_charge(vcc, skb->truesize); @@ -25363,7 +25923,7 @@ diff -urNp linux-3.1.4/drivers/atm/solos-pci.c li= nux-3.1.4/drivers/atm/solos-pci break; =20 case PKT_STATUS: -@@ -899,6 +899,8 @@ static int print_buffer(struct sk_buff * +@@ -899,6 +899,8 @@ static int print_buffer(struct sk_buff *buf) char msg[500]; char item[10]; =20 @@ -25372,7 +25932,7 @@ diff -urNp linux-3.1.4/drivers/atm/solos-pci.c li= nux-3.1.4/drivers/atm/solos-pci len =3D buf->len; for (i =3D 0; i < len; i++){ if(i % 8 =3D=3D 0) -@@ -1008,7 +1010,7 @@ static uint32_t fpga_tx(struct solos_car +@@ -1008,7 +1010,7 @@ static uint32_t fpga_tx(struct solos_card *card) vcc =3D SKB_CB(oldskb)->vcc; =20 if (vcc) { @@ -25381,9 +25941,10 @@ diff -urNp linux-3.1.4/drivers/atm/solos-pci.c l= inux-3.1.4/drivers/atm/solos-pci solos_pop(vcc, oldskb); } else dev_kfree_skb_irq(oldskb); -diff -urNp linux-3.1.4/drivers/atm/suni.c linux-3.1.4/drivers/atm/suni.c ---- linux-3.1.4/drivers/atm/suni.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/suni.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/atm/suni.c b/drivers/atm/suni.c +index 90f1ccc..04c4a1e 100644 +--- a/drivers/atm/suni.c ++++ b/drivers/atm/suni.c @@ -50,8 +50,8 @@ static DEFINE_SPINLOCK(sunis_lock); =20 =20 @@ -25395,10 +25956,11 @@ diff -urNp linux-3.1.4/drivers/atm/suni.c linux= -3.1.4/drivers/atm/suni.c =20 =20 static void suni_hz(unsigned long from_timer) -diff -urNp linux-3.1.4/drivers/atm/uPD98402.c linux-3.1.4/drivers/atm/uP= D98402.c ---- linux-3.1.4/drivers/atm/uPD98402.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/atm/uPD98402.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -42,7 +42,7 @@ static int fetch_stats(struct atm_dev *d +diff --git a/drivers/atm/uPD98402.c b/drivers/atm/uPD98402.c +index 5120a96..e2572bd 100644 +--- a/drivers/atm/uPD98402.c ++++ b/drivers/atm/uPD98402.c +@@ -42,7 +42,7 @@ static int fetch_stats(struct atm_dev *dev,struct sone= t_stats __user *arg,int ze struct sonet_stats tmp; int error =3D 0; =20 @@ -25407,7 +25969,7 @@ diff -urNp linux-3.1.4/drivers/atm/uPD98402.c lin= ux-3.1.4/drivers/atm/uPD98402.c sonet_copy_stats(&PRIV(dev)->sonet_stats,&tmp); if (arg) error =3D copy_to_user(arg,&tmp,sizeof(tmp)); if (zero && !error) { -@@ -161,9 +161,9 @@ static int uPD98402_ioctl(struct atm_dev +@@ -161,9 +161,9 @@ static int uPD98402_ioctl(struct atm_dev *dev,unsign= ed int cmd,void __user *arg) =20 =20 #define ADD_LIMITED(s,v) \ @@ -25420,7 +25982,7 @@ diff -urNp linux-3.1.4/drivers/atm/uPD98402.c lin= ux-3.1.4/drivers/atm/uPD98402.c =20 =20 static void stat_event(struct atm_dev *dev) -@@ -194,7 +194,7 @@ static void uPD98402_int(struct atm_dev=20 +@@ -194,7 +194,7 @@ static void uPD98402_int(struct atm_dev *dev) if (reason & uPD98402_INT_PFM) stat_event(dev); if (reason & uPD98402_INT_PCO) { (void) GET(PCOCR); /* clear interrupt cause */ @@ -25429,7 +25991,7 @@ diff -urNp linux-3.1.4/drivers/atm/uPD98402.c lin= ux-3.1.4/drivers/atm/uPD98402.c &PRIV(dev)->sonet_stats.uncorr_hcs); } if ((reason & uPD98402_INT_RFO) &&=20 -@@ -222,9 +222,9 @@ static int uPD98402_start(struct atm_dev +@@ -222,9 +222,9 @@ static int uPD98402_start(struct atm_dev *dev) PUT(~(uPD98402_INT_PFM | uPD98402_INT_ALM | uPD98402_INT_RFO | uPD98402_INT_LOS),PIMR); /* enable them */ (void) fetch_stats(dev,NULL,1); /* clear kernel counters */ @@ -25442,10 +26004,11 @@ diff -urNp linux-3.1.4/drivers/atm/uPD98402.c l= inux-3.1.4/drivers/atm/uPD98402.c return 0; } =20 -diff -urNp linux-3.1.4/drivers/atm/zatm.c linux-3.1.4/drivers/atm/zatm.c ---- linux-3.1.4/drivers/atm/zatm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/atm/zatm.c 2011-11-16 18:39:07.000000000 -0500 -@@ -460,7 +460,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy +diff --git a/drivers/atm/zatm.c b/drivers/atm/zatm.c +index d889f56..17eb71e 100644 +--- a/drivers/atm/zatm.c ++++ b/drivers/atm/zatm.c +@@ -460,7 +460,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy[0],dummy[1]= ); } if (!size) { dev_kfree_skb_irq(skb); @@ -25454,7 +26017,7 @@ diff -urNp linux-3.1.4/drivers/atm/zatm.c linux-3= .1.4/drivers/atm/zatm.c continue; } if (!atm_charge(vcc,skb->truesize)) { -@@ -470,7 +470,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy +@@ -470,7 +470,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy[0],dummy[1]= ); skb->len =3D size; ATM_SKB(skb)->vcc =3D vcc; vcc->push(vcc,skb); @@ -25463,7 +26026,7 @@ diff -urNp linux-3.1.4/drivers/atm/zatm.c linux-3= .1.4/drivers/atm/zatm.c } zout(pos & 0xffff,MTA(mbx)); #if 0 /* probably a stupid idea */ -@@ -734,7 +734,7 @@ if (*ZATM_PRV_DSC(skb) !=3D (uPD98401_TXPD +@@ -734,7 +734,7 @@ if (*ZATM_PRV_DSC(skb) !=3D (uPD98401_TXPD_V | uPD98= 401_TXPD_DP | skb_queue_head(&zatm_vcc->backlog,skb); break; } @@ -25472,9 +26035,10 @@ diff -urNp linux-3.1.4/drivers/atm/zatm.c linux-= 3.1.4/drivers/atm/zatm.c wake_up(&zatm_vcc->tx_wait); } =20 -diff -urNp linux-3.1.4/drivers/base/devtmpfs.c linux-3.1.4/drivers/base/= devtmpfs.c ---- linux-3.1.4/drivers/base/devtmpfs.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/base/devtmpfs.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/drivers/base/devtmpfs.c b/drivers/base/devtmpfs.c +index a4760e0..51283cf 100644 +--- a/drivers/base/devtmpfs.c ++++ b/drivers/base/devtmpfs.c @@ -368,7 +368,7 @@ int devtmpfs_mount(const char *mntdir) if (!thread) return 0; @@ -25484,9 +26048,10 @@ diff -urNp linux-3.1.4/drivers/base/devtmpfs.c l= inux-3.1.4/drivers/base/devtmpfs if (err) printk(KERN_INFO "devtmpfs: error mounting %i\n", err); else -diff -urNp linux-3.1.4/drivers/base/power/wakeup.c linux-3.1.4/drivers/b= ase/power/wakeup.c ---- linux-3.1.4/drivers/base/power/wakeup.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/base/power/wakeup.c 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/drivers/base/power/wakeup.c b/drivers/base/power/wakeup.c +index 84f7c7d..37cfd87 100644 +--- a/drivers/base/power/wakeup.c ++++ b/drivers/base/power/wakeup.c @@ -29,14 +29,14 @@ bool events_check_enabled; * They need to be modified together atomically, so it's better to use = one * atomic variable to hold them both. @@ -25504,7 +26069,7 @@ diff -urNp linux-3.1.4/drivers/base/power/wakeup.= c linux-3.1.4/drivers/base/powe =20 *cnt =3D (comb >> IN_PROGRESS_BITS); *inpr =3D comb & MAX_IN_PROGRESS; -@@ -350,7 +350,7 @@ static void wakeup_source_activate(struc +@@ -350,7 +350,7 @@ static void wakeup_source_activate(struct wakeup_sou= rce *ws) ws->last_time =3D ktime_get(); =20 /* Increment the counter of events in progress. */ @@ -25513,7 +26078,7 @@ diff -urNp linux-3.1.4/drivers/base/power/wakeup.= c linux-3.1.4/drivers/base/powe } =20 /** -@@ -440,7 +440,7 @@ static void wakeup_source_deactivate(str +@@ -440,7 +440,7 @@ static void wakeup_source_deactivate(struct wakeup_s= ource *ws) * Increment the counter of registered wakeup events and decrement the * couter of wakeup events in progress simultaneously. */ @@ -25522,10 +26087,24 @@ diff -urNp linux-3.1.4/drivers/base/power/wakeu= p.c linux-3.1.4/drivers/base/powe } =20 /** -diff -urNp linux-3.1.4/drivers/block/cciss.c linux-3.1.4/drivers/block/c= ciss.c ---- linux-3.1.4/drivers/block/cciss.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/block/cciss.c 2011-11-16 18:40:10.000000000 -050= 0 -@@ -1179,6 +1179,8 @@ static int cciss_ioctl32_passthru(struct +diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c +index e086fbb..398e1fe 100644 +--- a/drivers/block/DAC960.c ++++ b/drivers/block/DAC960.c +@@ -1980,6 +1980,8 @@ static bool DAC960_V1_ReadDeviceConfiguration(DAC9= 60_Controller_T + unsigned long flags; + int Channel, TargetID; +=20 ++ pax_track_stack(); ++ + if (!init_dma_loaf(Controller->PCIDevice, &local_dma,=20 + DAC960_V1_MaxChannels*(sizeof(DAC960_V1_DCDB_T) + + sizeof(DAC960_SCSI_Inquiry_T) + +diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c +index c2f9b3e..5911988 100644 +--- a/drivers/block/cciss.c ++++ b/drivers/block/cciss.c +@@ -1179,6 +1179,8 @@ static int cciss_ioctl32_passthru(struct block_dev= ice *bdev, fmode_t mode, int err; u32 cp; =20 @@ -25573,7 +26152,7 @@ diff -urNp linux-3.1.4/drivers/block/cciss.c linu= x-3.1.4/drivers/block/cciss.c (h->interrupts_enabled =3D=3D 0)); } =20 -@@ -3465,7 +3467,7 @@ static inline u32 next_command(ctlr_info +@@ -3465,7 +3467,7 @@ static inline u32 next_command(ctlr_info_t *h) u32 a; =20 if (unlikely(!(h->transMethod & CFGTBL_Trans_Performant))) @@ -25582,7 +26161,7 @@ diff -urNp linux-3.1.4/drivers/block/cciss.c linu= x-3.1.4/drivers/block/cciss.c =20 if ((*(h->reply_pool_head) & 1) =3D=3D (h->reply_pool_wraparound)) { a =3D *(h->reply_pool_head); /* Next cmd in ring buffer */ -@@ -4020,7 +4022,7 @@ static void __devinit cciss_put_controll +@@ -4020,7 +4022,7 @@ static void __devinit cciss_put_controller_into_pe= rformant_mode(ctlr_info_t *h) trans_support & CFGTBL_Trans_use_short_tags); =20 /* Change the access methods to the performant access methods */ @@ -25591,7 +26170,7 @@ diff -urNp linux-3.1.4/drivers/block/cciss.c linu= x-3.1.4/drivers/block/cciss.c h->transMethod =3D CFGTBL_Trans_Performant; =20 return; -@@ -4292,7 +4294,7 @@ static int __devinit cciss_pci_init(ctlr +@@ -4292,7 +4294,7 @@ static int __devinit cciss_pci_init(ctlr_info_t *h= ) if (prod_index < 0) return -ENODEV; h->product_name =3D products[prod_index].product_name; @@ -25639,7 +26218,7 @@ diff -urNp linux-3.1.4/drivers/block/cciss.c linu= x-3.1.4/drivers/block/cciss.c =20 /* Get the firmware version */ inq_buff =3D kzalloc(sizeof(InquiryData_struct), GFP_KERNEL); -@@ -5178,7 +5180,7 @@ static void cciss_shutdown(struct pci_de +@@ -5178,7 +5180,7 @@ static void cciss_shutdown(struct pci_dev *pdev) kfree(flush_buf); if (return_code !=3D IO_OK) dev_warn(&h->pdev->dev, "Error flushing cache\n"); @@ -25648,9 +26227,10 @@ diff -urNp linux-3.1.4/drivers/block/cciss.c lin= ux-3.1.4/drivers/block/cciss.c free_irq(h->intr[PERF_MODE_INT], h); } =20 -diff -urNp linux-3.1.4/drivers/block/cciss.h linux-3.1.4/drivers/block/c= ciss.h ---- linux-3.1.4/drivers/block/cciss.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/block/cciss.h 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/block/cciss.h b/drivers/block/cciss.h +index c049548..a09cb6e 100644 +--- a/drivers/block/cciss.h ++++ b/drivers/block/cciss.h @@ -100,7 +100,7 @@ struct ctlr_info /* information about each logical volume */ drive_info_struct *drv[CISS_MAX_LUN]; @@ -25660,10 +26240,11 @@ diff -urNp linux-3.1.4/drivers/block/cciss.h li= nux-3.1.4/drivers/block/cciss.h =20 /* queue and queue Info */=20 struct list_head reqQ; -diff -urNp linux-3.1.4/drivers/block/cpqarray.c linux-3.1.4/drivers/bloc= k/cpqarray.c ---- linux-3.1.4/drivers/block/cpqarray.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/block/cpqarray.c 2011-11-16 18:40:10.000000000 -= 0500 -@@ -404,7 +404,7 @@ static int __devinit cpqarray_register_c +diff --git a/drivers/block/cpqarray.c b/drivers/block/cpqarray.c +index b2fceb5..87fec83 100644 +--- a/drivers/block/cpqarray.c ++++ b/drivers/block/cpqarray.c +@@ -404,7 +404,7 @@ static int __devinit cpqarray_register_ctlr( int i, = struct pci_dev *pdev) if (register_blkdev(COMPAQ_SMART2_MAJOR+i, hba[i]->devname)) { goto Enomem4; } @@ -25672,7 +26253,7 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.c l= inux-3.1.4/drivers/block/cpqarr if (request_irq(hba[i]->intr, do_ida_intr, IRQF_DISABLED|IRQF_SHARED, hba[i]->devname, hba[i])) { -@@ -459,7 +459,7 @@ static int __devinit cpqarray_register_c +@@ -459,7 +459,7 @@ static int __devinit cpqarray_register_ctlr( int i, = struct pci_dev *pdev) add_timer(&hba[i]->timer); =20 /* Enable IRQ now that spinlock and rate limit timer are set up */ @@ -25690,7 +26271,7 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.c l= inux-3.1.4/drivers/block/cpqarr break; } } -@@ -792,7 +792,7 @@ static int __devinit cpqarray_eisa_detec +@@ -792,7 +792,7 @@ static int __devinit cpqarray_eisa_detect(void) hba[ctlr]->intr =3D intr; sprintf(hba[ctlr]->devname, "ida%d", nr_ctlr); hba[ctlr]->product_name =3D products[j].product_name; @@ -25699,7 +26280,7 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.c l= inux-3.1.4/drivers/block/cpqarr hba[ctlr]->ctlr =3D ctlr; hba[ctlr]->board_id =3D board_id; hba[ctlr]->pci_dev =3D NULL; /* not PCI */ -@@ -911,6 +911,8 @@ static void do_ida_request(struct reques +@@ -911,6 +911,8 @@ static void do_ida_request(struct request_queue *q) struct scatterlist tmp_sg[SG_MAX]; int i, dir, seg; =20 @@ -25726,7 +26307,7 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.c l= inux-3.1.4/drivers/block/cpqarr =20 /* Get onto the completion Q */ addQ(&h->cmpQ, c); -@@ -1050,7 +1052,7 @@ static irqreturn_t do_ida_intr(int irq,=20 +@@ -1050,7 +1052,7 @@ static irqreturn_t do_ida_intr(int irq, void *dev_= id) unsigned long flags; __u32 a,a1; =20 @@ -25735,7 +26316,7 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.c l= inux-3.1.4/drivers/block/cpqarr /* Is this interrupt for us? */ if (istat =3D=3D 0) return IRQ_NONE; -@@ -1061,7 +1063,7 @@ static irqreturn_t do_ida_intr(int irq,=20 +@@ -1061,7 +1063,7 @@ static irqreturn_t do_ida_intr(int irq, void *dev_= id) */ spin_lock_irqsave(IDA_LOCK(h->ctlr), flags); if (istat & FIFO_NOT_EMPTY) { @@ -25767,7 +26348,7 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.c l= inux-3.1.4/drivers/block/cpqarr complete =3D pollcomplete(ctlr); =09 pci_unmap_single(info_p->pci_dev, (dma_addr_t) c->req.sg[0].addr,=20 -@@ -1549,9 +1551,9 @@ static int revalidate_allvol(ctlr_info_t +@@ -1549,9 +1551,9 @@ static int revalidate_allvol(ctlr_info_t *host) * we check the new geometry. Then turn interrupts back on when * we're done. */ @@ -25788,9 +26369,10 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.c = linux-3.1.4/drivers/block/cpqarr if (done =3D=3D 0) { udelay(10); /* a short fixed delay */ } else -diff -urNp linux-3.1.4/drivers/block/cpqarray.h linux-3.1.4/drivers/bloc= k/cpqarray.h ---- linux-3.1.4/drivers/block/cpqarray.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/block/cpqarray.h 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/drivers/block/cpqarray.h b/drivers/block/cpqarray.h +index be73e9d..7fbf140 100644 +--- a/drivers/block/cpqarray.h ++++ b/drivers/block/cpqarray.h @@ -99,7 +99,7 @@ struct ctlr_info { drv_info_t drv[NWD]; struct proc_dir_entry *proc; @@ -25800,21 +26382,10 @@ diff -urNp linux-3.1.4/drivers/block/cpqarray.h= linux-3.1.4/drivers/block/cpqarr =20 cmdlist_t *reqQ; cmdlist_t *cmpQ; -diff -urNp linux-3.1.4/drivers/block/DAC960.c linux-3.1.4/drivers/block/= DAC960.c ---- linux-3.1.4/drivers/block/DAC960.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/block/DAC960.c 2011-11-16 18:40:10.000000000 -05= 00 -@@ -1980,6 +1980,8 @@ static bool DAC960_V1_ReadDeviceConfigur - unsigned long flags; - int Channel, TargetID; -=20 -+ pax_track_stack(); -+ - if (!init_dma_loaf(Controller->PCIDevice, &local_dma,=20 - DAC960_V1_MaxChannels*(sizeof(DAC960_V1_DCDB_T) + - sizeof(DAC960_SCSI_Inquiry_T) + -diff -urNp linux-3.1.4/drivers/block/drbd/drbd_int.h linux-3.1.4/drivers= /block/drbd/drbd_int.h ---- linux-3.1.4/drivers/block/drbd/drbd_int.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/block/drbd/drbd_int.h 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/drivers/block/drbd/drbd_int.h b/drivers/block/drbd/drbd_int= .h +index ef2ceed..c9cb18e 100644 +--- a/drivers/block/drbd/drbd_int.h ++++ b/drivers/block/drbd/drbd_int.h @@ -737,7 +737,7 @@ struct drbd_request; struct drbd_epoch { struct list_head list; @@ -25833,7 +26404,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_in= t.h linux-3.1.4/drivers/block/d unsigned int peer_seq; spinlock_t peer_seq_lock; unsigned int minor; -@@ -1618,30 +1618,30 @@ static inline int drbd_setsockopt(struct +@@ -1618,30 +1618,30 @@ static inline int drbd_setsockopt(struct socket = *sock, int level, int optname, =20 static inline void drbd_tcp_cork(struct socket *sock) { @@ -25872,10 +26443,11 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_= int.h linux-3.1.4/drivers/block/d } =20 void drbd_bump_write_ordering(struct drbd_conf *mdev, enum write_orderi= ng_e wo); -diff -urNp linux-3.1.4/drivers/block/drbd/drbd_main.c linux-3.1.4/driver= s/block/drbd/drbd_main.c ---- linux-3.1.4/drivers/block/drbd/drbd_main.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/block/drbd/drbd_main.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -2397,7 +2397,7 @@ static int _drbd_send_ack(struct drbd_co +diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_ma= in.c +index 0358e55..bc33689 100644 +--- a/drivers/block/drbd/drbd_main.c ++++ b/drivers/block/drbd/drbd_main.c +@@ -2397,7 +2397,7 @@ static int _drbd_send_ack(struct drbd_conf *mdev, = enum drbd_packets cmd, p.sector =3D sector; p.block_id =3D block_id; p.blksize =3D blksize; @@ -25884,7 +26456,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_ma= in.c linux-3.1.4/drivers/block/ =20 if (!mdev->meta.socket || mdev->state.conn < C_CONNECTED) return false; -@@ -2696,7 +2696,7 @@ int drbd_send_dblock(struct drbd_conf *m +@@ -2696,7 +2696,7 @@ int drbd_send_dblock(struct drbd_conf *mdev, struc= t drbd_request *req) p.sector =3D cpu_to_be64(req->sector); p.block_id =3D (unsigned long)req; p.seq_num =3D cpu_to_be32(req->seq_num =3D @@ -25893,7 +26465,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_ma= in.c linux-3.1.4/drivers/block/ =20 dp_flags =3D bio_flags_to_wire(mdev, req->master_bio->bi_rw); =20 -@@ -2981,7 +2981,7 @@ void drbd_init_set_defaults(struct drbd_ +@@ -2981,7 +2981,7 @@ void drbd_init_set_defaults(struct drbd_conf *mdev= ) atomic_set(&mdev->unacked_cnt, 0); atomic_set(&mdev->local_cnt, 0); atomic_set(&mdev->net_cnt, 0); @@ -25902,7 +26474,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_ma= in.c linux-3.1.4/drivers/block/ atomic_set(&mdev->pp_in_use, 0); atomic_set(&mdev->pp_in_use_by_net, 0); atomic_set(&mdev->rs_sect_in, 0); -@@ -3063,8 +3063,8 @@ void drbd_mdev_cleanup(struct drbd_conf=20 +@@ -3063,8 +3063,8 @@ void drbd_mdev_cleanup(struct drbd_conf *mdev) mdev->receiver.t_state); =20 /* no need to lock it, I'm the only thread alive */ @@ -25913,10 +26485,11 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_= main.c linux-3.1.4/drivers/block/ mdev->al_writ_cnt =3D mdev->bm_writ_cnt =3D mdev->read_cnt =3D -diff -urNp linux-3.1.4/drivers/block/drbd/drbd_nl.c linux-3.1.4/drivers/= block/drbd/drbd_nl.c ---- linux-3.1.4/drivers/block/drbd/drbd_nl.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/block/drbd/drbd_nl.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -2359,7 +2359,7 @@ static void drbd_connector_callback(stru +diff --git a/drivers/block/drbd/drbd_nl.c b/drivers/block/drbd/drbd_nl.c +index 0feab26..5d9b3dd 100644 +--- a/drivers/block/drbd/drbd_nl.c ++++ b/drivers/block/drbd/drbd_nl.c +@@ -2359,7 +2359,7 @@ static void drbd_connector_callback(struct cn_msg = *req, struct netlink_skb_parms module_put(THIS_MODULE); } =20 @@ -25925,7 +26498,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_nl= .c linux-3.1.4/drivers/block/dr =20 static unsigned short * __tl_add_blob(unsigned short *tl, enum drbd_tags tag, const void *data, -@@ -2430,7 +2430,7 @@ void drbd_bcast_state(struct drbd_conf * +@@ -2430,7 +2430,7 @@ void drbd_bcast_state(struct drbd_conf *mdev, unio= n drbd_state state) cn_reply->id.idx =3D CN_IDX_DRBD; cn_reply->id.val =3D CN_VAL_DRBD; =20 @@ -25934,7 +26507,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_nl= .c linux-3.1.4/drivers/block/dr cn_reply->ack =3D 0; /* not used here. */ cn_reply->len =3D sizeof(struct drbd_nl_cfg_reply) + (int)((char *)tl - (char *)reply->tag_list); -@@ -2462,7 +2462,7 @@ void drbd_bcast_ev_helper(struct drbd_co +@@ -2462,7 +2462,7 @@ void drbd_bcast_ev_helper(struct drbd_conf *mdev, = char *helper_name) cn_reply->id.idx =3D CN_IDX_DRBD; cn_reply->id.val =3D CN_VAL_DRBD; =20 @@ -25943,7 +26516,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_nl= .c linux-3.1.4/drivers/block/dr cn_reply->ack =3D 0; /* not used here. */ cn_reply->len =3D sizeof(struct drbd_nl_cfg_reply) + (int)((char *)tl - (char *)reply->tag_list); -@@ -2540,7 +2540,7 @@ void drbd_bcast_ee(struct drbd_conf *mde +@@ -2540,7 +2540,7 @@ void drbd_bcast_ee(struct drbd_conf *mdev, cn_reply->id.idx =3D CN_IDX_DRBD; cn_reply->id.val =3D CN_VAL_DRBD; =20 @@ -25952,7 +26525,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_nl= .c linux-3.1.4/drivers/block/dr cn_reply->ack =3D 0; // not used here. cn_reply->len =3D sizeof(struct drbd_nl_cfg_reply) + (int)((char*)tl - (char*)reply->tag_list); -@@ -2579,7 +2579,7 @@ void drbd_bcast_sync_progress(struct drb +@@ -2579,7 +2579,7 @@ void drbd_bcast_sync_progress(struct drbd_conf *md= ev) cn_reply->id.idx =3D CN_IDX_DRBD; cn_reply->id.val =3D CN_VAL_DRBD; =20 @@ -25961,9 +26534,10 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_n= l.c linux-3.1.4/drivers/block/dr cn_reply->ack =3D 0; /* not used here. */ cn_reply->len =3D sizeof(struct drbd_nl_cfg_reply) + (int)((char *)tl - (char *)reply->tag_list); -diff -urNp linux-3.1.4/drivers/block/drbd/drbd_receiver.c linux-3.1.4/dr= ivers/block/drbd/drbd_receiver.c ---- linux-3.1.4/drivers/block/drbd/drbd_receiver.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/block/drbd/drbd_receiver.c 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/drivers/block/drbd/drbd_receiver.c b/drivers/block/drbd/drb= d_receiver.c +index 43beaca..4a5b1dd 100644 +--- a/drivers/block/drbd/drbd_receiver.c ++++ b/drivers/block/drbd/drbd_receiver.c @@ -894,7 +894,7 @@ retry: sock->sk->sk_sndtimeo =3D mdev->net_conf->timeout*HZ/10; sock->sk->sk_rcvtimeo =3D MAX_SCHEDULE_TIMEOUT; @@ -25973,7 +26547,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_re= ceiver.c linux-3.1.4/drivers/bl mdev->peer_seq =3D 0; =20 drbd_thread_start(&mdev->asender); -@@ -985,7 +985,7 @@ static enum finish_epoch drbd_may_finish +@@ -985,7 +985,7 @@ static enum finish_epoch drbd_may_finish_epoch(struc= t drbd_conf *mdev, do { next_epoch =3D NULL; =20 @@ -25982,7 +26556,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_re= ceiver.c linux-3.1.4/drivers/bl =20 switch (ev & ~EV_CLEANUP) { case EV_PUT: -@@ -1020,7 +1020,7 @@ static enum finish_epoch drbd_may_finish +@@ -1020,7 +1020,7 @@ static enum finish_epoch drbd_may_finish_epoch(str= uct drbd_conf *mdev, rv =3D FE_DESTROYED; } else { epoch->flags =3D 0; @@ -25991,7 +26565,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_re= ceiver.c linux-3.1.4/drivers/bl /* atomic_set(&epoch->active, 0); is already zero */ if (rv =3D=3D FE_STILL_LIVE) rv =3D FE_RECYCLED; -@@ -1191,14 +1191,14 @@ static int receive_Barrier(struct drbd_c +@@ -1191,14 +1191,14 @@ static int receive_Barrier(struct drbd_conf *mde= v, enum drbd_packets cmd, unsign drbd_wait_ee_list_empty(mdev, &mdev->active_ee); drbd_flush(mdev); =20 @@ -26008,7 +26582,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_re= ceiver.c linux-3.1.4/drivers/bl =20 D_ASSERT(atomic_read(&epoch->active) =3D=3D 0); D_ASSERT(epoch->flags =3D=3D 0); -@@ -1210,11 +1210,11 @@ static int receive_Barrier(struct drbd_c +@@ -1210,11 +1210,11 @@ static int receive_Barrier(struct drbd_conf *mde= v, enum drbd_packets cmd, unsign } =20 epoch->flags =3D 0; @@ -26022,7 +26596,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_re= ceiver.c linux-3.1.4/drivers/bl list_add(&epoch->list, &mdev->current_epoch->list); mdev->current_epoch =3D epoch; mdev->epochs++; -@@ -1663,7 +1663,7 @@ static int receive_Data(struct drbd_conf +@@ -1663,7 +1663,7 @@ static int receive_Data(struct drbd_conf *mdev, en= um drbd_packets cmd, unsigned spin_unlock(&mdev->peer_seq_lock); =20 drbd_send_ack_dp(mdev, P_NEG_ACK, p, data_size); @@ -26031,7 +26605,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_re= ceiver.c linux-3.1.4/drivers/bl return drbd_drain_block(mdev, data_size); } =20 -@@ -1689,7 +1689,7 @@ static int receive_Data(struct drbd_conf +@@ -1689,7 +1689,7 @@ static int receive_Data(struct drbd_conf *mdev, en= um drbd_packets cmd, unsigned =20 spin_lock(&mdev->epoch_lock); e->epoch =3D mdev->current_epoch; @@ -26040,7 +26614,7 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_re= ceiver.c linux-3.1.4/drivers/bl atomic_inc(&e->epoch->active); spin_unlock(&mdev->epoch_lock); =20 -@@ -3885,7 +3885,7 @@ static void drbd_disconnect(struct drbd_ +@@ -3885,7 +3885,7 @@ static void drbd_disconnect(struct drbd_conf *mdev= ) D_ASSERT(list_empty(&mdev->done_ee)); =20 /* ok, no more ee's on the fly, it is safe to reset the epoch_size */ @@ -26049,10 +26623,11 @@ diff -urNp linux-3.1.4/drivers/block/drbd/drbd_= receiver.c linux-3.1.4/drivers/bl D_ASSERT(list_empty(&mdev->current_epoch->list)); } =20 -diff -urNp linux-3.1.4/drivers/block/loop.c linux-3.1.4/drivers/block/lo= op.c ---- linux-3.1.4/drivers/block/loop.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/block/loop.c 2011-11-16 18:39:07.000000000 -0500 -@@ -283,7 +283,7 @@ static int __do_lo_send_write(struct fil +diff --git a/drivers/block/loop.c b/drivers/block/loop.c +index 4720c7a..2c49af1 100644 +--- a/drivers/block/loop.c ++++ b/drivers/block/loop.c +@@ -283,7 +283,7 @@ static int __do_lo_send_write(struct file *file, mm_segment_t old_fs =3D get_fs(); =20 set_fs(get_ds()); @@ -26061,10 +26636,11 @@ diff -urNp linux-3.1.4/drivers/block/loop.c lin= ux-3.1.4/drivers/block/loop.c set_fs(old_fs); if (likely(bw =3D=3D len)) return 0; -diff -urNp linux-3.1.4/drivers/block/nbd.c linux-3.1.4/drivers/block/nbd= .c ---- linux-3.1.4/drivers/block/nbd.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/block/nbd.c 2011-11-16 18:40:10.000000000 -0500 -@@ -157,6 +157,8 @@ static int sock_xmit(struct nbd_device * +diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c +index f533f33..6177bcb 100644 +--- a/drivers/block/nbd.c ++++ b/drivers/block/nbd.c +@@ -157,6 +157,8 @@ static int sock_xmit(struct nbd_device *lo, int send= , void *buf, int size, struct kvec iov; sigset_t blocked, oldset; =20 @@ -26073,7 +26649,7 @@ diff -urNp linux-3.1.4/drivers/block/nbd.c linux-= 3.1.4/drivers/block/nbd.c if (unlikely(!sock)) { printk(KERN_ERR "%s: Attempted %s on closed socket in sock_xmit\n", lo->disk->disk_name, (send ? "send" : "recv")); -@@ -572,6 +574,8 @@ static void do_nbd_request(struct reques +@@ -572,6 +574,8 @@ static void do_nbd_request(struct request_queue *q) static int __nbd_ioctl(struct block_device *bdev, struct nbd_device *lo= , unsigned int cmd, unsigned long arg) { @@ -26082,10 +26658,33 @@ diff -urNp linux-3.1.4/drivers/block/nbd.c linu= x-3.1.4/drivers/block/nbd.c switch (cmd) { case NBD_DISCONNECT: { struct request sreq; -diff -urNp linux-3.1.4/drivers/char/agp/frontend.c linux-3.1.4/drivers/c= har/agp/frontend.c ---- linux-3.1.4/drivers/char/agp/frontend.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/char/agp/frontend.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -817,7 +817,7 @@ static int agpioc_reserve_wrap(struct ag +diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig +index 423fd56..06d3be0 100644 +--- a/drivers/char/Kconfig ++++ b/drivers/char/Kconfig +@@ -8,7 +8,8 @@ source "drivers/tty/Kconfig" +=20 + config DEVKMEM + bool "/dev/kmem virtual device support" +- default y ++ default n ++ depends on !GRKERNSEC_KMEM + help + Say Y here if you want to support the /dev/kmem device. The + /dev/kmem device is rarely used, but can be used for certain +@@ -596,6 +597,7 @@ config DEVPORT + bool + depends on !M68K + depends on ISA || PCI ++ depends on !GRKERNSEC_KMEM + default y +=20 + source "drivers/s390/char/Kconfig" +diff --git a/drivers/char/agp/frontend.c b/drivers/char/agp/frontend.c +index 2e04433..22afc64 100644 +--- a/drivers/char/agp/frontend.c ++++ b/drivers/char/agp/frontend.c +@@ -817,7 +817,7 @@ static int agpioc_reserve_wrap(struct agp_file_priva= te *priv, void __user *arg) if (copy_from_user(&reserve, arg, sizeof(struct agp_region))) return -EFAULT; =20 @@ -26094,9 +26693,10 @@ diff -urNp linux-3.1.4/drivers/char/agp/frontend= .c linux-3.1.4/drivers/char/agp/ return -EFAULT; =20 client =3D agp_find_client_by_pid(reserve.pid); -diff -urNp linux-3.1.4/drivers/char/briq_panel.c linux-3.1.4/drivers/cha= r/briq_panel.c ---- linux-3.1.4/drivers/char/briq_panel.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/char/briq_panel.c 2011-11-16 18:40:10.000000000 = -0500 +diff --git a/drivers/char/briq_panel.c b/drivers/char/briq_panel.c +index 095ab90..afad0a4 100644 +--- a/drivers/char/briq_panel.c ++++ b/drivers/char/briq_panel.c @@ -9,6 +9,7 @@ #include #include @@ -26113,7 +26713,7 @@ diff -urNp linux-3.1.4/drivers/char/briq_panel.c = linux-3.1.4/drivers/char/briq_p =20 static void update_vfd(void) { -@@ -140,12 +142,15 @@ static ssize_t briq_panel_write(struct f +@@ -140,12 +142,15 @@ static ssize_t briq_panel_write(struct file *file,= const char __user *buf, size_ if (!vfd_is_open) return -EBUSY; =20 @@ -26130,7 +26730,7 @@ diff -urNp linux-3.1.4/drivers/char/briq_panel.c = linux-3.1.4/drivers/char/briq_p if (esc) { set_led(c); esc =3D 0; -@@ -175,6 +180,7 @@ static ssize_t briq_panel_write(struct f +@@ -175,6 +180,7 @@ static ssize_t briq_panel_write(struct file *file, c= onst char __user *buf, size_ buf++; } update_vfd(); @@ -26138,10 +26738,11 @@ diff -urNp linux-3.1.4/drivers/char/briq_panel.= c linux-3.1.4/drivers/char/briq_p =20 return len; } -diff -urNp linux-3.1.4/drivers/char/genrtc.c linux-3.1.4/drivers/char/ge= nrtc.c ---- linux-3.1.4/drivers/char/genrtc.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/char/genrtc.c 2011-11-16 18:40:10.000000000 -050= 0 -@@ -273,6 +273,7 @@ static int gen_rtc_ioctl(struct file *fi +diff --git a/drivers/char/genrtc.c b/drivers/char/genrtc.c +index f773a9d..65cd683 100644 +--- a/drivers/char/genrtc.c ++++ b/drivers/char/genrtc.c +@@ -273,6 +273,7 @@ static int gen_rtc_ioctl(struct file *file, switch (cmd) { =20 case RTC_PLL_GET: @@ -26149,10 +26750,11 @@ diff -urNp linux-3.1.4/drivers/char/genrtc.c li= nux-3.1.4/drivers/char/genrtc.c if (get_rtc_pll(&pll)) return -EINVAL; else -diff -urNp linux-3.1.4/drivers/char/hpet.c linux-3.1.4/drivers/char/hpet= .c ---- linux-3.1.4/drivers/char/hpet.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/char/hpet.c 2011-11-16 18:39:07.000000000 -0500 -@@ -572,7 +572,7 @@ static inline unsigned long hpet_time_di +diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c +index 0833896..cccce52 100644 +--- a/drivers/char/hpet.c ++++ b/drivers/char/hpet.c +@@ -572,7 +572,7 @@ static inline unsigned long hpet_time_div(struct hpe= ts *hpets, } =20 static int @@ -26161,9 +26763,10 @@ diff -urNp linux-3.1.4/drivers/char/hpet.c linux= -3.1.4/drivers/char/hpet.c struct hpet_info *info) { struct hpet_timer __iomem *timer; -diff -urNp linux-3.1.4/drivers/char/ipmi/ipmi_msghandler.c linux-3.1.4/d= rivers/char/ipmi/ipmi_msghandler.c ---- linux-3.1.4/drivers/char/ipmi/ipmi_msghandler.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/char/ipmi/ipmi_msghandler.c 2011-11-16 18:40:10.= 000000000 -0500 +diff --git a/drivers/char/ipmi/ipmi_msghandler.c b/drivers/char/ipmi/ipm= i_msghandler.c +index 58c0e63..25aed94 100644 +--- a/drivers/char/ipmi/ipmi_msghandler.c ++++ b/drivers/char/ipmi/ipmi_msghandler.c @@ -415,7 +415,7 @@ struct ipmi_smi { struct proc_dir_entry *proc_dir; char proc_dir_name[10]; @@ -26185,7 +26788,7 @@ diff -urNp linux-3.1.4/drivers/char/ipmi/ipmi_msg= handler.c linux-3.1.4/drivers/c =20 static int is_lan_addr(struct ipmi_addr *addr) { -@@ -2868,7 +2868,7 @@ int ipmi_register_smi(struct ipmi_smi_ha +@@ -2868,7 +2868,7 @@ int ipmi_register_smi(struct ipmi_smi_handlers *ha= ndlers, INIT_LIST_HEAD(&intf->cmd_rcvrs); init_waitqueue_head(&intf->waitq); for (i =3D 0; i < IPMI_NUM_STATS; i++) @@ -26203,9 +26806,10 @@ diff -urNp linux-3.1.4/drivers/char/ipmi/ipmi_ms= ghandler.c linux-3.1.4/drivers/c si =3D (struct ipmi_system_interface_addr *) &addr; si->addr_type =3D IPMI_SYSTEM_INTERFACE_ADDR_TYPE; si->channel =3D IPMI_BMC_CHANNEL; -diff -urNp linux-3.1.4/drivers/char/ipmi/ipmi_si_intf.c linux-3.1.4/driv= ers/char/ipmi/ipmi_si_intf.c ---- linux-3.1.4/drivers/char/ipmi/ipmi_si_intf.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/char/ipmi/ipmi_si_intf.c 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_s= i_intf.c +index 9397ab4..d01bee1 100644 +--- a/drivers/char/ipmi/ipmi_si_intf.c ++++ b/drivers/char/ipmi/ipmi_si_intf.c @@ -277,7 +277,7 @@ struct smi_info { unsigned char slave_addr; =20 @@ -26227,7 +26831,7 @@ diff -urNp linux-3.1.4/drivers/char/ipmi/ipmi_si_= intf.c linux-3.1.4/drivers/char =20 #define SI_MAX_PARMS 4 =20 -@@ -3230,7 +3230,7 @@ static int try_smi_init(struct smi_info=20 +@@ -3230,7 +3230,7 @@ static int try_smi_init(struct smi_info *new_smi) atomic_set(&new_smi->req_events, 0); new_smi->run_to_completion =3D 0; for (i =3D 0; i < SI_NUM_STATS; i++) @@ -26236,31 +26840,11 @@ diff -urNp linux-3.1.4/drivers/char/ipmi/ipmi_s= i_intf.c linux-3.1.4/drivers/char =20 new_smi->interrupt_disabled =3D 1; atomic_set(&new_smi->stop_operation, 0); -diff -urNp linux-3.1.4/drivers/char/Kconfig linux-3.1.4/drivers/char/Kco= nfig ---- linux-3.1.4/drivers/char/Kconfig 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/char/Kconfig 2011-11-16 18:40:10.000000000 -0500 -@@ -8,7 +8,8 @@ source "drivers/tty/Kconfig" -=20 - config DEVKMEM - bool "/dev/kmem virtual device support" -- default y -+ default n -+ depends on !GRKERNSEC_KMEM - help - Say Y here if you want to support the /dev/kmem device. The - /dev/kmem device is rarely used, but can be used for certain -@@ -596,6 +597,7 @@ config DEVPORT - bool - depends on !M68K - depends on ISA || PCI -+ depends on !GRKERNSEC_KMEM - default y -=20 - source "drivers/s390/char/Kconfig" -diff -urNp linux-3.1.4/drivers/char/mbcs.c linux-3.1.4/drivers/char/mbcs= .c ---- linux-3.1.4/drivers/char/mbcs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/char/mbcs.c 2011-11-16 18:39:07.000000000 -0500 -@@ -800,7 +800,7 @@ static int mbcs_remove(struct cx_dev *de +diff --git a/drivers/char/mbcs.c b/drivers/char/mbcs.c +index 1aeaaba..e018570 100644 +--- a/drivers/char/mbcs.c ++++ b/drivers/char/mbcs.c +@@ -800,7 +800,7 @@ static int mbcs_remove(struct cx_dev *dev) return 0; } =20 @@ -26269,9 +26853,10 @@ diff -urNp linux-3.1.4/drivers/char/mbcs.c linux= -3.1.4/drivers/char/mbcs.c { .part_num =3D MBCS_PART_NUM, .mfg_num =3D MBCS_MFG_NUM, -diff -urNp linux-3.1.4/drivers/char/mem.c linux-3.1.4/drivers/char/mem.c ---- linux-3.1.4/drivers/char/mem.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/char/mem.c 2011-11-17 18:31:56.000000000 -0500 +diff --git a/drivers/char/mem.c b/drivers/char/mem.c +index 8fc04b4..cebdeec 100644 +--- a/drivers/char/mem.c ++++ b/drivers/char/mem.c @@ -18,6 +18,7 @@ #include #include @@ -26291,7 +26876,7 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux-3= .1.4/drivers/char/mem.c static inline unsigned long size_inside_page(unsigned long start, unsigned long size) { -@@ -65,9 +70,13 @@ static inline int range_is_allowed(unsig +@@ -65,9 +70,13 @@ static inline int range_is_allowed(unsigned long pfn,= unsigned long size) =20 while (cursor < to) { if (!devmem_is_allowed(pfn)) { @@ -26305,7 +26890,7 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux-3= .1.4/drivers/char/mem.c return 0; } cursor +=3D PAGE_SIZE; -@@ -75,6 +84,11 @@ static inline int range_is_allowed(unsig +@@ -75,6 +84,11 @@ static inline int range_is_allowed(unsigned long pfn,= unsigned long size) } return 1; } @@ -26317,7 +26902,7 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux-3= .1.4/drivers/char/mem.c #else static inline int range_is_allowed(unsigned long pfn, unsigned long siz= e) { -@@ -117,6 +131,7 @@ static ssize_t read_mem(struct file *fil +@@ -117,6 +131,7 @@ static ssize_t read_mem(struct file *file, char __us= er *buf, =20 while (count > 0) { unsigned long remaining; @@ -26325,7 +26910,7 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux-3= .1.4/drivers/char/mem.c =20 sz =3D size_inside_page(p, count); =20 -@@ -132,7 +147,23 @@ static ssize_t read_mem(struct file *fil +@@ -132,7 +147,23 @@ static ssize_t read_mem(struct file *file, char __u= ser *buf, if (!ptr) return -EFAULT; =20 @@ -26350,7 +26935,7 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux-3= .1.4/drivers/char/mem.c unxlate_dev_mem_ptr(p, ptr); if (remaining) return -EFAULT; -@@ -395,9 +426,8 @@ static ssize_t read_kmem(struct file *fi +@@ -395,9 +426,8 @@ static ssize_t read_kmem(struct file *file, char __u= ser *buf, size_t count, loff_t *ppos) { unsigned long p =3D *ppos; @@ -26361,7 +26946,7 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux-3= .1.4/drivers/char/mem.c =20 read =3D 0; if (p < (unsigned long) high_memory) { -@@ -419,6 +449,8 @@ static ssize_t read_kmem(struct file *fi +@@ -419,6 +449,8 @@ static ssize_t read_kmem(struct file *file, char __u= ser *buf, } #endif while (low_count > 0) { @@ -26370,7 +26955,7 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux-3= .1.4/drivers/char/mem.c sz =3D size_inside_page(p, low_count); =20 /* -@@ -428,7 +460,22 @@ static ssize_t read_kmem(struct file *fi +@@ -428,7 +460,22 @@ static ssize_t read_kmem(struct file *file, char __= user *buf, */ kbuf =3D xlate_dev_kmem_ptr((char *)p); =20 @@ -26404,10 +26989,11 @@ diff -urNp linux-3.1.4/drivers/char/mem.c linux= -3.1.4/drivers/char/mem.c }; =20 static int memory_open(struct inode *inode, struct file *filp) -diff -urNp linux-3.1.4/drivers/char/nvram.c linux-3.1.4/drivers/char/nvr= am.c ---- linux-3.1.4/drivers/char/nvram.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/char/nvram.c 2011-11-16 18:39:07.000000000 -0500 -@@ -248,7 +248,7 @@ static ssize_t nvram_read(struct file *f +diff --git a/drivers/char/nvram.c b/drivers/char/nvram.c +index da3cfee..a5a6606 100644 +--- a/drivers/char/nvram.c ++++ b/drivers/char/nvram.c +@@ -248,7 +248,7 @@ static ssize_t nvram_read(struct file *file, char __= user *buf, =20 spin_unlock_irq(&rtc_lock); =20 @@ -26416,9 +27002,10 @@ diff -urNp linux-3.1.4/drivers/char/nvram.c linu= x-3.1.4/drivers/char/nvram.c return -EFAULT; =20 *ppos =3D i; -diff -urNp linux-3.1.4/drivers/char/random.c linux-3.1.4/drivers/char/ra= ndom.c ---- linux-3.1.4/drivers/char/random.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/char/random.c 2011-11-16 18:40:10.000000000 -050= 0 +diff --git a/drivers/char/random.c b/drivers/char/random.c +index c35a785..6d82202 100644 +--- a/drivers/char/random.c ++++ b/drivers/char/random.c @@ -261,8 +261,13 @@ /* * Configuration information @@ -26451,7 +27038,7 @@ diff -urNp linux-3.1.4/drivers/char/random.c linu= x-3.1.4/drivers/char/random.c #if 0 /* x^2048 + x^1638 + x^1231 + x^819 + x^411 + x + 1 -- 115 */ { 2048, 1638, 1231, 819, 411, 1 }, -@@ -909,7 +921,7 @@ static ssize_t extract_entropy_user(stru +@@ -909,7 +921,7 @@ static ssize_t extract_entropy_user(struct entropy_s= tore *r, void __user *buf, =20 extract_buf(r, tmp); i =3D min_t(int, nbytes, EXTRACT_SIZE); @@ -26469,9 +27056,10 @@ diff -urNp linux-3.1.4/drivers/char/random.c lin= ux-3.1.4/drivers/char/random.c static int max_write_thresh =3D INPUT_POOL_WORDS * 32; static char sysctl_bootid[16]; =20 -diff -urNp linux-3.1.4/drivers/char/sonypi.c linux-3.1.4/drivers/char/so= nypi.c ---- linux-3.1.4/drivers/char/sonypi.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/char/sonypi.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/char/sonypi.c b/drivers/char/sonypi.c +index 1ee8ce7..b778bef 100644 +--- a/drivers/char/sonypi.c ++++ b/drivers/char/sonypi.c @@ -55,6 +55,7 @@ #include #include @@ -26489,7 +27077,7 @@ diff -urNp linux-3.1.4/drivers/char/sonypi.c linu= x-3.1.4/drivers/char/sonypi.c int model; struct input_dev *input_jog_dev; struct input_dev *input_key_dev; -@@ -898,7 +899,7 @@ static int sonypi_misc_fasync(int fd, st +@@ -898,7 +899,7 @@ static int sonypi_misc_fasync(int fd, struct file *f= ilp, int on) static int sonypi_misc_release(struct inode *inode, struct file *file) { mutex_lock(&sonypi_device.lock); @@ -26498,7 +27086,7 @@ diff -urNp linux-3.1.4/drivers/char/sonypi.c linu= x-3.1.4/drivers/char/sonypi.c mutex_unlock(&sonypi_device.lock); return 0; } -@@ -907,9 +908,9 @@ static int sonypi_misc_open(struct inode +@@ -907,9 +908,9 @@ static int sonypi_misc_open(struct inode *inode, str= uct file *file) { mutex_lock(&sonypi_device.lock); /* Flush input queue on first open */ @@ -26510,10 +27098,33 @@ diff -urNp linux-3.1.4/drivers/char/sonypi.c li= nux-3.1.4/drivers/char/sonypi.c mutex_unlock(&sonypi_device.lock); =20 return 0; -diff -urNp linux-3.1.4/drivers/char/tpm/tpm_bios.c linux-3.1.4/drivers/c= har/tpm/tpm_bios.c ---- linux-3.1.4/drivers/char/tpm/tpm_bios.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/char/tpm/tpm_bios.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -173,7 +173,7 @@ static void *tpm_bios_measurements_start +diff --git a/drivers/char/tpm/tpm.c b/drivers/char/tpm/tpm.c +index 9ca5c02..7ce352c 100644 +--- a/drivers/char/tpm/tpm.c ++++ b/drivers/char/tpm/tpm.c +@@ -414,7 +414,7 @@ static ssize_t tpm_transmit(struct tpm_chip *chip, c= onst char *buf, + chip->vendor.req_complete_val) + goto out_recv; +=20 +- if ((status =3D=3D chip->vendor.req_canceled)) { ++ if (status =3D=3D chip->vendor.req_canceled) { + dev_err(chip->dev, "Operation Canceled\n"); + rc =3D -ECANCELED; + goto out; +@@ -862,6 +862,8 @@ ssize_t tpm_show_pubek(struct device *dev, struct de= vice_attribute *attr, +=20 + struct tpm_chip *chip =3D dev_get_drvdata(dev); +=20 ++ pax_track_stack(); ++ + tpm_cmd.header.in =3D tpm_readpubek_header; + err =3D transmit_cmd(chip, &tpm_cmd, READ_PUBEK_RESULT_SIZE, + "attempting to read the PUBEK"); +diff --git a/drivers/char/tpm/tpm_bios.c b/drivers/char/tpm/tpm_bios.c +index 0636520..169c1d0 100644 +--- a/drivers/char/tpm/tpm_bios.c ++++ b/drivers/char/tpm/tpm_bios.c +@@ -173,7 +173,7 @@ static void *tpm_bios_measurements_start(struct seq_= file *m, loff_t *pos) event =3D addr; =20 if ((event->event_type =3D=3D 0 && event->event_size =3D=3D 0) || @@ -26522,7 +27133,7 @@ diff -urNp linux-3.1.4/drivers/char/tpm/tpm_bios.= c linux-3.1.4/drivers/char/tpm/ return NULL; =20 return addr; -@@ -198,7 +198,7 @@ static void *tpm_bios_measurements_next( +@@ -198,7 +198,7 @@ static void *tpm_bios_measurements_next(struct seq_f= ile *m, void *v, return NULL; =20 if ((event->event_type =3D=3D 0 && event->event_size =3D=3D 0) || @@ -26531,7 +27142,7 @@ diff -urNp linux-3.1.4/drivers/char/tpm/tpm_bios.= c linux-3.1.4/drivers/char/tpm/ return NULL; =20 (*pos)++; -@@ -291,7 +291,8 @@ static int tpm_binary_bios_measurements_ +@@ -291,7 +291,8 @@ static int tpm_binary_bios_measurements_show(struct = seq_file *m, void *v) int i; =20 for (i =3D 0; i < sizeof(struct tcpa_event) + event->event_size; i++) @@ -26541,7 +27152,7 @@ diff -urNp linux-3.1.4/drivers/char/tpm/tpm_bios.= c linux-3.1.4/drivers/char/tpm/ =20 return 0; } -@@ -410,8 +411,13 @@ static int read_log(struct tpm_bios_log=20 +@@ -410,8 +411,13 @@ static int read_log(struct tpm_bios_log *log) log->bios_event_log_end =3D log->bios_event_log + len; =20 virt =3D acpi_os_map_memory(start, len); @@ -26556,31 +27167,11 @@ diff -urNp linux-3.1.4/drivers/char/tpm/tpm_bio= s.c linux-3.1.4/drivers/char/tpm/ =20 acpi_os_unmap_memory(virt, len); return 0; -diff -urNp linux-3.1.4/drivers/char/tpm/tpm.c linux-3.1.4/drivers/char/t= pm/tpm.c ---- linux-3.1.4/drivers/char/tpm/tpm.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/char/tpm/tpm.c 2011-11-16 18:40:10.000000000 -05= 00 -@@ -414,7 +414,7 @@ static ssize_t tpm_transmit(struct tpm_c - chip->vendor.req_complete_val) - goto out_recv; -=20 -- if ((status =3D=3D chip->vendor.req_canceled)) { -+ if (status =3D=3D chip->vendor.req_canceled) { - dev_err(chip->dev, "Operation Canceled\n"); - rc =3D -ECANCELED; - goto out; -@@ -862,6 +862,8 @@ ssize_t tpm_show_pubek(struct device *de -=20 - struct tpm_chip *chip =3D dev_get_drvdata(dev); -=20 -+ pax_track_stack(); -+ - tpm_cmd.header.in =3D tpm_readpubek_header; - err =3D transmit_cmd(chip, &tpm_cmd, READ_PUBEK_RESULT_SIZE, - "attempting to read the PUBEK"); -diff -urNp linux-3.1.4/drivers/char/virtio_console.c linux-3.1.4/drivers= /char/virtio_console.c ---- linux-3.1.4/drivers/char/virtio_console.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/char/virtio_console.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -555,7 +555,7 @@ static ssize_t fill_readbuf(struct port=20 +diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console= .c +index fb68b12..0f6c6ca 100644 +--- a/drivers/char/virtio_console.c ++++ b/drivers/char/virtio_console.c +@@ -555,7 +555,7 @@ static ssize_t fill_readbuf(struct port *port, char = *out_buf, size_t out_count, if (to_user) { ssize_t ret; =20 @@ -26589,7 +27180,7 @@ diff -urNp linux-3.1.4/drivers/char/virtio_consol= e.c linux-3.1.4/drivers/char/vi if (ret) return -EFAULT; } else { -@@ -654,7 +654,7 @@ static ssize_t port_fops_read(struct fil +@@ -654,7 +654,7 @@ static ssize_t port_fops_read(struct file *filp, cha= r __user *ubuf, if (!port_has_data(port) && !port->host_connected) return 0; =20 @@ -26598,10 +27189,11 @@ diff -urNp linux-3.1.4/drivers/char/virtio_cons= ole.c linux-3.1.4/drivers/char/vi } =20 static ssize_t port_fops_write(struct file *filp, const char __user *ub= uf, -diff -urNp linux-3.1.4/drivers/crypto/hifn_795x.c linux-3.1.4/drivers/cr= ypto/hifn_795x.c ---- linux-3.1.4/drivers/crypto/hifn_795x.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/crypto/hifn_795x.c 2011-11-16 18:40:10.000000000= -0500 -@@ -1655,6 +1655,8 @@ static int hifn_test(struct hifn_device=20 +diff --git a/drivers/crypto/hifn_795x.c b/drivers/crypto/hifn_795x.c +index a84250a..68c725e 100644 +--- a/drivers/crypto/hifn_795x.c ++++ b/drivers/crypto/hifn_795x.c +@@ -1655,6 +1655,8 @@ static int hifn_test(struct hifn_device *dev, int = encdec, u8 snum) 0xCA, 0x34, 0x2B, 0x2E}; struct scatterlist sg; =20 @@ -26610,10 +27202,11 @@ diff -urNp linux-3.1.4/drivers/crypto/hifn_795x= .c linux-3.1.4/drivers/crypto/hif memset(src, 0, sizeof(src)); memset(ctx.key, 0, sizeof(ctx.key)); =20 -diff -urNp linux-3.1.4/drivers/crypto/padlock-aes.c linux-3.1.4/drivers/= crypto/padlock-aes.c ---- linux-3.1.4/drivers/crypto/padlock-aes.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/crypto/padlock-aes.c 2011-11-16 18:40:10.0000000= 00 -0500 -@@ -109,6 +109,8 @@ static int aes_set_key(struct crypto_tfm +diff --git a/drivers/crypto/padlock-aes.c b/drivers/crypto/padlock-aes.c +index db33d30..7823369 100644 +--- a/drivers/crypto/padlock-aes.c ++++ b/drivers/crypto/padlock-aes.c +@@ -109,6 +109,8 @@ static int aes_set_key(struct crypto_tfm *tfm, const= u8 *in_key, struct crypto_aes_ctx gen_aes; int cpu; =20 @@ -26622,10 +27215,11 @@ diff -urNp linux-3.1.4/drivers/crypto/padlock-a= es.c linux-3.1.4/drivers/crypto/p if (key_len % 8) { *flags |=3D CRYPTO_TFM_RES_BAD_KEY_LEN; return -EINVAL; -diff -urNp linux-3.1.4/drivers/edac/amd64_edac.c linux-3.1.4/drivers/eda= c/amd64_edac.c ---- linux-3.1.4/drivers/edac/amd64_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/amd64_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -2670,7 +2670,7 @@ static void __devexit amd64_remove_one_i +diff --git a/drivers/edac/amd64_edac.c b/drivers/edac/amd64_edac.c +index 9a8bebc..b1e4989 100644 +--- a/drivers/edac/amd64_edac.c ++++ b/drivers/edac/amd64_edac.c +@@ -2670,7 +2670,7 @@ static void __devexit amd64_remove_one_instance(st= ruct pci_dev *pdev) * PCI core identifies what devices are on a system during boot, and th= en * inquiry this table to see if this driver is for a given device found= . */ @@ -26634,10 +27228,11 @@ diff -urNp linux-3.1.4/drivers/edac/amd64_edac.= c linux-3.1.4/drivers/edac/amd64_ { .vendor =3D PCI_VENDOR_ID_AMD, .device =3D PCI_DEVICE_ID_AMD_K8_NB_MEMCTL, -diff -urNp linux-3.1.4/drivers/edac/amd76x_edac.c linux-3.1.4/drivers/ed= ac/amd76x_edac.c ---- linux-3.1.4/drivers/edac/amd76x_edac.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/edac/amd76x_edac.c 2011-11-16 18:39:07.000000000= -0500 -@@ -321,7 +321,7 @@ static void __devexit amd76x_remove_one( +diff --git a/drivers/edac/amd76x_edac.c b/drivers/edac/amd76x_edac.c +index e47e73b..348e0bd 100644 +--- a/drivers/edac/amd76x_edac.c ++++ b/drivers/edac/amd76x_edac.c +@@ -321,7 +321,7 @@ static void __devexit amd76x_remove_one(struct pci_d= ev *pdev) edac_mc_free(mci); } =20 @@ -26646,10 +27241,11 @@ diff -urNp linux-3.1.4/drivers/edac/amd76x_edac= .c linux-3.1.4/drivers/edac/amd76 { PCI_VEND_DEV(AMD, FE_GATE_700C), PCI_ANY_ID, PCI_ANY_ID, 0, 0, AMD762}, -diff -urNp linux-3.1.4/drivers/edac/e752x_edac.c linux-3.1.4/drivers/eda= c/e752x_edac.c ---- linux-3.1.4/drivers/edac/e752x_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/e752x_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -1380,7 +1380,7 @@ static void __devexit e752x_remove_one(s +diff --git a/drivers/edac/e752x_edac.c b/drivers/edac/e752x_edac.c +index 1af531a..3a8ff27 100644 +--- a/drivers/edac/e752x_edac.c ++++ b/drivers/edac/e752x_edac.c +@@ -1380,7 +1380,7 @@ static void __devexit e752x_remove_one(struct pci_= dev *pdev) edac_mc_free(mci); } =20 @@ -26658,10 +27254,11 @@ diff -urNp linux-3.1.4/drivers/edac/e752x_edac.= c linux-3.1.4/drivers/edac/e752x_ { PCI_VEND_DEV(INTEL, 7520_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, E7520}, -diff -urNp linux-3.1.4/drivers/edac/e7xxx_edac.c linux-3.1.4/drivers/eda= c/e7xxx_edac.c ---- linux-3.1.4/drivers/edac/e7xxx_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/e7xxx_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -525,7 +525,7 @@ static void __devexit e7xxx_remove_one(s +diff --git a/drivers/edac/e7xxx_edac.c b/drivers/edac/e7xxx_edac.c +index 6ffb6d2..383d8d7 100644 +--- a/drivers/edac/e7xxx_edac.c ++++ b/drivers/edac/e7xxx_edac.c +@@ -525,7 +525,7 @@ static void __devexit e7xxx_remove_one(struct pci_de= v *pdev) edac_mc_free(mci); } =20 @@ -26670,10 +27267,11 @@ diff -urNp linux-3.1.4/drivers/edac/e7xxx_edac.= c linux-3.1.4/drivers/edac/e7xxx_ { PCI_VEND_DEV(INTEL, 7205_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, E7205}, -diff -urNp linux-3.1.4/drivers/edac/edac_pci_sysfs.c linux-3.1.4/drivers= /edac/edac_pci_sysfs.c ---- linux-3.1.4/drivers/edac/edac_pci_sysfs.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/edac/edac_pci_sysfs.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -26,8 +26,8 @@ static int edac_pci_log_pe =3D 1; /* log=20 +diff --git a/drivers/edac/edac_pci_sysfs.c b/drivers/edac/edac_pci_sysfs= .c +index 495198a..ac08c85 100644 +--- a/drivers/edac/edac_pci_sysfs.c ++++ b/drivers/edac/edac_pci_sysfs.c +@@ -26,8 +26,8 @@ static int edac_pci_log_pe =3D 1; /* log PCI parity e= rrors */ static int edac_pci_log_npe =3D 1; /* log PCI non-parity error errors *= / static int edac_pci_poll_msec =3D 1000; /* one second workq period */ =20 @@ -26684,7 +27282,7 @@ diff -urNp linux-3.1.4/drivers/edac/edac_pci_sysf= s.c linux-3.1.4/drivers/edac/ed =20 static struct kobject *edac_pci_top_main_kobj; static atomic_t edac_pci_sysfs_refcount =3D ATOMIC_INIT(0); -@@ -582,7 +582,7 @@ static void edac_pci_dev_parity_test(str +@@ -582,7 +582,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) edac_printk(KERN_CRIT, EDAC_PCI, "Signaled System Error on %s\n", pci_name(dev)); @@ -26693,7 +27291,7 @@ diff -urNp linux-3.1.4/drivers/edac/edac_pci_sysf= s.c linux-3.1.4/drivers/edac/ed } =20 if (status & (PCI_STATUS_PARITY)) { -@@ -590,7 +590,7 @@ static void edac_pci_dev_parity_test(str +@@ -590,7 +590,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Master Data Parity Error on %s\n", pci_name(dev)); =20 @@ -26702,7 +27300,7 @@ diff -urNp linux-3.1.4/drivers/edac/edac_pci_sysf= s.c linux-3.1.4/drivers/edac/ed } =20 if (status & (PCI_STATUS_DETECTED_PARITY)) { -@@ -598,7 +598,7 @@ static void edac_pci_dev_parity_test(str +@@ -598,7 +598,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Detected Parity Error on %s\n", pci_name(dev)); =20 @@ -26711,7 +27309,7 @@ diff -urNp linux-3.1.4/drivers/edac/edac_pci_sysf= s.c linux-3.1.4/drivers/edac/ed } } =20 -@@ -619,7 +619,7 @@ static void edac_pci_dev_parity_test(str +@@ -619,7 +619,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) edac_printk(KERN_CRIT, EDAC_PCI, "Bridge " "Signaled System Error on %s\n", pci_name(dev)); @@ -26720,7 +27318,7 @@ diff -urNp linux-3.1.4/drivers/edac/edac_pci_sysf= s.c linux-3.1.4/drivers/edac/ed } =20 if (status & (PCI_STATUS_PARITY)) { -@@ -627,7 +627,7 @@ static void edac_pci_dev_parity_test(str +@@ -627,7 +627,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Master Data Parity Error on " "%s\n", pci_name(dev)); =20 @@ -26729,7 +27327,7 @@ diff -urNp linux-3.1.4/drivers/edac/edac_pci_sysf= s.c linux-3.1.4/drivers/edac/ed } =20 if (status & (PCI_STATUS_DETECTED_PARITY)) { -@@ -635,7 +635,7 @@ static void edac_pci_dev_parity_test(str +@@ -635,7 +635,7 @@ static void edac_pci_dev_parity_test(struct pci_dev = *dev) "Detected Parity Error on %s\n", pci_name(dev)); =20 @@ -26756,10 +27354,11 @@ diff -urNp linux-3.1.4/drivers/edac/edac_pci_sy= sfs.c linux-3.1.4/drivers/edac/ed panic("EDAC: PCI Parity Error"); } } -diff -urNp linux-3.1.4/drivers/edac/i3000_edac.c linux-3.1.4/drivers/eda= c/i3000_edac.c ---- linux-3.1.4/drivers/edac/i3000_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/i3000_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -470,7 +470,7 @@ static void __devexit i3000_remove_one(s +diff --git a/drivers/edac/i3000_edac.c b/drivers/edac/i3000_edac.c +index c0510b3..6e2a954 100644 +--- a/drivers/edac/i3000_edac.c ++++ b/drivers/edac/i3000_edac.c +@@ -470,7 +470,7 @@ static void __devexit i3000_remove_one(struct pci_de= v *pdev) edac_mc_free(mci); } =20 @@ -26768,10 +27367,11 @@ diff -urNp linux-3.1.4/drivers/edac/i3000_edac.= c linux-3.1.4/drivers/edac/i3000_ { PCI_VEND_DEV(INTEL, 3000_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I3000}, -diff -urNp linux-3.1.4/drivers/edac/i3200_edac.c linux-3.1.4/drivers/eda= c/i3200_edac.c ---- linux-3.1.4/drivers/edac/i3200_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/i3200_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -456,7 +456,7 @@ static void __devexit i3200_remove_one(s +diff --git a/drivers/edac/i3200_edac.c b/drivers/edac/i3200_edac.c +index aa08497..7e6822a 100644 +--- a/drivers/edac/i3200_edac.c ++++ b/drivers/edac/i3200_edac.c +@@ -456,7 +456,7 @@ static void __devexit i3200_remove_one(struct pci_de= v *pdev) edac_mc_free(mci); } =20 @@ -26780,10 +27380,11 @@ diff -urNp linux-3.1.4/drivers/edac/i3200_edac.= c linux-3.1.4/drivers/edac/i3200_ { PCI_VEND_DEV(INTEL, 3200_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I3200}, -diff -urNp linux-3.1.4/drivers/edac/i5000_edac.c linux-3.1.4/drivers/eda= c/i5000_edac.c ---- linux-3.1.4/drivers/edac/i5000_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/i5000_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -1516,7 +1516,7 @@ static void __devexit i5000_remove_one(s +diff --git a/drivers/edac/i5000_edac.c b/drivers/edac/i5000_edac.c +index 4dc3ac2..67d05a6 100644 +--- a/drivers/edac/i5000_edac.c ++++ b/drivers/edac/i5000_edac.c +@@ -1516,7 +1516,7 @@ static void __devexit i5000_remove_one(struct pci_= dev *pdev) * * The "E500P" device is the first device supported. */ @@ -26792,10 +27393,11 @@ diff -urNp linux-3.1.4/drivers/edac/i5000_edac.= c linux-3.1.4/drivers/edac/i5000_ {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_I5000_DEV16), .driver_data =3D I5000P}, =20 -diff -urNp linux-3.1.4/drivers/edac/i5100_edac.c linux-3.1.4/drivers/eda= c/i5100_edac.c ---- linux-3.1.4/drivers/edac/i5100_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/i5100_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -1051,7 +1051,7 @@ static void __devexit i5100_remove_one(s +diff --git a/drivers/edac/i5100_edac.c b/drivers/edac/i5100_edac.c +index bcbdeec..9886d16 100644 +--- a/drivers/edac/i5100_edac.c ++++ b/drivers/edac/i5100_edac.c +@@ -1051,7 +1051,7 @@ static void __devexit i5100_remove_one(struct pci_= dev *pdev) edac_mc_free(mci); } =20 @@ -26804,10 +27406,11 @@ diff -urNp linux-3.1.4/drivers/edac/i5100_edac.= c linux-3.1.4/drivers/edac/i5100_ /* Device 16, Function 0, Channel 0 Memory Map, Error Flag/Mask, ... *= / { PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_5100_16) }, { 0, } -diff -urNp linux-3.1.4/drivers/edac/i5400_edac.c linux-3.1.4/drivers/eda= c/i5400_edac.c ---- linux-3.1.4/drivers/edac/i5400_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/i5400_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -1383,7 +1383,7 @@ static void __devexit i5400_remove_one(s +diff --git a/drivers/edac/i5400_edac.c b/drivers/edac/i5400_edac.c +index 74d6ec34..baff517 100644 +--- a/drivers/edac/i5400_edac.c ++++ b/drivers/edac/i5400_edac.c +@@ -1383,7 +1383,7 @@ static void __devexit i5400_remove_one(struct pci_= dev *pdev) * * The "E500P" device is the first device supported. */ @@ -26816,10 +27419,11 @@ diff -urNp linux-3.1.4/drivers/edac/i5400_edac.= c linux-3.1.4/drivers/edac/i5400_ {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_5400_ERR)}, {0,} /* 0 terminated list. */ }; -diff -urNp linux-3.1.4/drivers/edac/i7300_edac.c linux-3.1.4/drivers/eda= c/i7300_edac.c ---- linux-3.1.4/drivers/edac/i7300_edac.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/edac/i7300_edac.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -1191,7 +1191,7 @@ static void __devexit i7300_remove_one(s +diff --git a/drivers/edac/i7300_edac.c b/drivers/edac/i7300_edac.c +index a76fe83..15479e6 100644 +--- a/drivers/edac/i7300_edac.c ++++ b/drivers/edac/i7300_edac.c +@@ -1191,7 +1191,7 @@ static void __devexit i7300_remove_one(struct pci_= dev *pdev) * * Has only 8086:360c PCI ID */ @@ -26828,10 +27432,11 @@ diff -urNp linux-3.1.4/drivers/edac/i7300_edac.= c linux-3.1.4/drivers/edac/i7300_ {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_I7300_MCH_ERR)}, {0,} /* 0 terminated list. */ }; -diff -urNp linux-3.1.4/drivers/edac/i7core_edac.c linux-3.1.4/drivers/ed= ac/i7core_edac.c ---- linux-3.1.4/drivers/edac/i7core_edac.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/edac/i7core_edac.c 2011-11-16 18:39:07.000000000= -0500 -@@ -359,7 +359,7 @@ static const struct pci_id_table pci_dev +diff --git a/drivers/edac/i7core_edac.c b/drivers/edac/i7core_edac.c +index f6cf448..3f612e9 100644 +--- a/drivers/edac/i7core_edac.c ++++ b/drivers/edac/i7core_edac.c +@@ -359,7 +359,7 @@ static const struct pci_id_table pci_dev_table[] =3D= { /* * pci_device_id table for which devices we are looking for */ @@ -26840,10 +27445,11 @@ diff -urNp linux-3.1.4/drivers/edac/i7core_edac= .c linux-3.1.4/drivers/edac/i7cor {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_X58_HUB_MGMT)}, {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_LYNNFIELD_QPI_LIN= K0)}, {0,} /* 0 terminated list. */ -diff -urNp linux-3.1.4/drivers/edac/i82443bxgx_edac.c linux-3.1.4/driver= s/edac/i82443bxgx_edac.c ---- linux-3.1.4/drivers/edac/i82443bxgx_edac.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/edac/i82443bxgx_edac.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -380,7 +380,7 @@ static void __devexit i82443bxgx_edacmc_ +diff --git a/drivers/edac/i82443bxgx_edac.c b/drivers/edac/i82443bxgx_ed= ac.c +index 4329d39..f3022ef 100644 +--- a/drivers/edac/i82443bxgx_edac.c ++++ b/drivers/edac/i82443bxgx_edac.c +@@ -380,7 +380,7 @@ static void __devexit i82443bxgx_edacmc_remove_one(s= truct pci_dev *pdev) =20 EXPORT_SYMBOL_GPL(i82443bxgx_edacmc_remove_one); =20 @@ -26852,10 +27458,11 @@ diff -urNp linux-3.1.4/drivers/edac/i82443bxgx_= edac.c linux-3.1.4/drivers/edac/i {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82443BX_0)}, {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82443BX_2)}, {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82443GX_0)}, -diff -urNp linux-3.1.4/drivers/edac/i82860_edac.c linux-3.1.4/drivers/ed= ac/i82860_edac.c ---- linux-3.1.4/drivers/edac/i82860_edac.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/edac/i82860_edac.c 2011-11-16 18:39:07.000000000= -0500 -@@ -270,7 +270,7 @@ static void __devexit i82860_remove_one( +diff --git a/drivers/edac/i82860_edac.c b/drivers/edac/i82860_edac.c +index 931a057..fd28340 100644 +--- a/drivers/edac/i82860_edac.c ++++ b/drivers/edac/i82860_edac.c +@@ -270,7 +270,7 @@ static void __devexit i82860_remove_one(struct pci_d= ev *pdev) edac_mc_free(mci); } =20 @@ -26864,10 +27471,11 @@ diff -urNp linux-3.1.4/drivers/edac/i82860_edac= .c linux-3.1.4/drivers/edac/i8286 { PCI_VEND_DEV(INTEL, 82860_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82860}, -diff -urNp linux-3.1.4/drivers/edac/i82875p_edac.c linux-3.1.4/drivers/e= dac/i82875p_edac.c ---- linux-3.1.4/drivers/edac/i82875p_edac.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/edac/i82875p_edac.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -511,7 +511,7 @@ static void __devexit i82875p_remove_one +diff --git a/drivers/edac/i82875p_edac.c b/drivers/edac/i82875p_edac.c +index 33864c6..01edc61 100644 +--- a/drivers/edac/i82875p_edac.c ++++ b/drivers/edac/i82875p_edac.c +@@ -511,7 +511,7 @@ static void __devexit i82875p_remove_one(struct pci_= dev *pdev) edac_mc_free(mci); } =20 @@ -26876,10 +27484,11 @@ diff -urNp linux-3.1.4/drivers/edac/i82875p_eda= c.c linux-3.1.4/drivers/edac/i828 { PCI_VEND_DEV(INTEL, 82875_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82875P}, -diff -urNp linux-3.1.4/drivers/edac/i82975x_edac.c linux-3.1.4/drivers/e= dac/i82975x_edac.c ---- linux-3.1.4/drivers/edac/i82975x_edac.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/edac/i82975x_edac.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -604,7 +604,7 @@ static void __devexit i82975x_remove_one +diff --git a/drivers/edac/i82975x_edac.c b/drivers/edac/i82975x_edac.c +index a5da732..983363b 100644 +--- a/drivers/edac/i82975x_edac.c ++++ b/drivers/edac/i82975x_edac.c +@@ -604,7 +604,7 @@ static void __devexit i82975x_remove_one(struct pci_= dev *pdev) edac_mc_free(mci); } =20 @@ -26888,9 +27497,10 @@ diff -urNp linux-3.1.4/drivers/edac/i82975x_edac= .c linux-3.1.4/drivers/edac/i829 { PCI_VEND_DEV(INTEL, 82975_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82975X -diff -urNp linux-3.1.4/drivers/edac/mce_amd.h linux-3.1.4/drivers/edac/m= ce_amd.h ---- linux-3.1.4/drivers/edac/mce_amd.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/edac/mce_amd.h 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/drivers/edac/mce_amd.h b/drivers/edac/mce_amd.h +index 795a320..3bbc3d3 100644 +--- a/drivers/edac/mce_amd.h ++++ b/drivers/edac/mce_amd.h @@ -83,7 +83,7 @@ struct amd_decoder_ops { bool (*dc_mce)(u16, u8); bool (*ic_mce)(u16, u8); @@ -26900,10 +27510,11 @@ diff -urNp linux-3.1.4/drivers/edac/mce_amd.h l= inux-3.1.4/drivers/edac/mce_amd.h =20 void amd_report_gart_errors(bool); void amd_register_ecc_decoder(void (*f)(int, struct mce *, u32)); -diff -urNp linux-3.1.4/drivers/edac/r82600_edac.c linux-3.1.4/drivers/ed= ac/r82600_edac.c ---- linux-3.1.4/drivers/edac/r82600_edac.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/edac/r82600_edac.c 2011-11-16 18:39:07.000000000= -0500 -@@ -373,7 +373,7 @@ static void __devexit r82600_remove_one( +diff --git a/drivers/edac/r82600_edac.c b/drivers/edac/r82600_edac.c +index b153674..ad2ba9b 100644 +--- a/drivers/edac/r82600_edac.c ++++ b/drivers/edac/r82600_edac.c +@@ -373,7 +373,7 @@ static void __devexit r82600_remove_one(struct pci_d= ev *pdev) edac_mc_free(mci); } =20 @@ -26912,10 +27523,11 @@ diff -urNp linux-3.1.4/drivers/edac/r82600_edac= .c linux-3.1.4/drivers/edac/r8260 { PCI_DEVICE(PCI_VENDOR_ID_RADISYS, R82600_BRIDGE_ID) }, -diff -urNp linux-3.1.4/drivers/edac/x38_edac.c linux-3.1.4/drivers/edac/= x38_edac.c ---- linux-3.1.4/drivers/edac/x38_edac.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/edac/x38_edac.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -440,7 +440,7 @@ static void __devexit x38_remove_one(str +diff --git a/drivers/edac/x38_edac.c b/drivers/edac/x38_edac.c +index b6f47de..c5acf3a 100644 +--- a/drivers/edac/x38_edac.c ++++ b/drivers/edac/x38_edac.c +@@ -440,7 +440,7 @@ static void __devexit x38_remove_one(struct pci_dev = *pdev) edac_mc_free(mci); } =20 @@ -26924,9 +27536,10 @@ diff -urNp linux-3.1.4/drivers/edac/x38_edac.c l= inux-3.1.4/drivers/edac/x38_edac { PCI_VEND_DEV(INTEL, X38_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, X38}, -diff -urNp linux-3.1.4/drivers/firewire/core-card.c linux-3.1.4/drivers/= firewire/core-card.c ---- linux-3.1.4/drivers/firewire/core-card.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/firewire/core-card.c 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/drivers/firewire/core-card.c b/drivers/firewire/core-card.c +index 85661b0..c784559a 100644 +--- a/drivers/firewire/core-card.c ++++ b/drivers/firewire/core-card.c @@ -657,7 +657,7 @@ void fw_card_release(struct kref *kref) =20 void fw_core_remove_card(struct fw_card *card) @@ -26936,10 +27549,11 @@ diff -urNp linux-3.1.4/drivers/firewire/core-ca= rd.c linux-3.1.4/drivers/firewire =20 card->driver->update_phy_reg(card, 4, PHY_LINK_ACTIVE | PHY_CONTENDER, 0); -diff -urNp linux-3.1.4/drivers/firewire/core-cdev.c linux-3.1.4/drivers/= firewire/core-cdev.c ---- linux-3.1.4/drivers/firewire/core-cdev.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/firewire/core-cdev.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -1331,8 +1331,7 @@ static int init_iso_resource(struct clie +diff --git a/drivers/firewire/core-cdev.c b/drivers/firewire/core-cdev.c +index 4799393..37bd3ab 100644 +--- a/drivers/firewire/core-cdev.c ++++ b/drivers/firewire/core-cdev.c +@@ -1331,8 +1331,7 @@ static int init_iso_resource(struct client *client= , int ret; =20 if ((request->channels =3D=3D 0 && request->bandwidth =3D=3D 0) || @@ -26949,20 +27563,10 @@ diff -urNp linux-3.1.4/drivers/firewire/core-cd= ev.c linux-3.1.4/drivers/firewire return -EINVAL; =20 r =3D kmalloc(sizeof(*r), GFP_KERNEL); -diff -urNp linux-3.1.4/drivers/firewire/core.h linux-3.1.4/drivers/firew= ire/core.h ---- linux-3.1.4/drivers/firewire/core.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/firewire/core.h 2011-11-16 18:39:07.000000000 -0= 500 -@@ -101,6 +101,7 @@ struct fw_card_driver { -=20 - int (*stop_iso)(struct fw_iso_context *ctx); - }; -+typedef struct fw_card_driver __no_const fw_card_driver_no_const; -=20 - void fw_card_initialize(struct fw_card *card, - const struct fw_card_driver *driver, struct device *device); -diff -urNp linux-3.1.4/drivers/firewire/core-transaction.c linux-3.1.4/d= rivers/firewire/core-transaction.c ---- linux-3.1.4/drivers/firewire/core-transaction.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/firewire/core-transaction.c 2011-11-16 18:40:10.= 000000000 -0500 +diff --git a/drivers/firewire/core-transaction.c b/drivers/firewire/core= -transaction.c +index 334b82a..ea5261d 100644 +--- a/drivers/firewire/core-transaction.c ++++ b/drivers/firewire/core-transaction.c @@ -37,6 +37,7 @@ #include #include @@ -26971,7 +27575,7 @@ diff -urNp linux-3.1.4/drivers/firewire/core-tran= saction.c linux-3.1.4/drivers/f =20 #include =20 -@@ -422,6 +423,8 @@ int fw_run_transaction(struct fw_card *c +@@ -422,6 +423,8 @@ int fw_run_transaction(struct fw_card *card, int tco= de, int destination_id, struct transaction_callback_data d; struct fw_transaction t; =20 @@ -26980,9 +27584,22 @@ diff -urNp linux-3.1.4/drivers/firewire/core-tra= nsaction.c linux-3.1.4/drivers/f init_timer_on_stack(&t.split_timeout_timer); init_completion(&d.done); d.payload =3D payload; -diff -urNp linux-3.1.4/drivers/firmware/dmi_scan.c linux-3.1.4/drivers/f= irmware/dmi_scan.c ---- linux-3.1.4/drivers/firmware/dmi_scan.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/firmware/dmi_scan.c 2011-11-16 18:39:07.00000000= 0 -0500 +diff --git a/drivers/firewire/core.h b/drivers/firewire/core.h +index b45be57..5fad18b 100644 +--- a/drivers/firewire/core.h ++++ b/drivers/firewire/core.h +@@ -101,6 +101,7 @@ struct fw_card_driver { +=20 + int (*stop_iso)(struct fw_iso_context *ctx); + }; ++typedef struct fw_card_driver __no_const fw_card_driver_no_const; +=20 + void fw_card_initialize(struct fw_card *card, + const struct fw_card_driver *driver, struct device *device); +diff --git a/drivers/firmware/dmi_scan.c b/drivers/firmware/dmi_scan.c +index bcb1126..2cc2121 100644 +--- a/drivers/firmware/dmi_scan.c ++++ b/drivers/firmware/dmi_scan.c @@ -449,11 +449,6 @@ void __init dmi_scan_machine(void) } } @@ -26995,7 +27612,7 @@ diff -urNp linux-3.1.4/drivers/firmware/dmi_scan.= c linux-3.1.4/drivers/firmware/ p =3D dmi_ioremap(0xF0000, 0x10000); if (p =3D=3D NULL) goto error; -@@ -725,7 +720,7 @@ int dmi_walk(void (*decode)(const struct +@@ -725,7 +720,7 @@ int dmi_walk(void (*decode)(const struct dmi_header = *, void *), if (buf =3D=3D NULL) return -1; =20 @@ -27004,9 +27621,10 @@ diff -urNp linux-3.1.4/drivers/firmware/dmi_scan= .c linux-3.1.4/drivers/firmware/ =20 iounmap(buf); return 0; -diff -urNp linux-3.1.4/drivers/gpio/gpio-vr41xx.c linux-3.1.4/drivers/gp= io/gpio-vr41xx.c ---- linux-3.1.4/drivers/gpio/gpio-vr41xx.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/gpio/gpio-vr41xx.c 2011-11-16 18:39:07.000000000= -0500 +diff --git a/drivers/gpio/gpio-vr41xx.c b/drivers/gpio/gpio-vr41xx.c +index 98723cb..10ca85b 100644 +--- a/drivers/gpio/gpio-vr41xx.c ++++ b/drivers/gpio/gpio-vr41xx.c @@ -204,7 +204,7 @@ static int giu_get_irq(unsigned int irq) printk(KERN_ERR "spurious GIU interrupt: %04x(%04x),%04x(%04x)\n", maskl, pendl, maskh, pendh); @@ -27016,10 +27634,11 @@ diff -urNp linux-3.1.4/drivers/gpio/gpio-vr41xx= .c linux-3.1.4/drivers/gpio/gpio- =20 return -EINVAL; } -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c linux-3.1.4/drivers/gp= u/drm/drm_crtc.c ---- linux-3.1.4/drivers/gpu/drm/drm_crtc.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_crtc.c 2011-11-16 18:39:07.000000000= -0500 -@@ -1374,7 +1374,7 @@ int drm_mode_getconnector(struct drm_dev +diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c +index fe738f0..2d03563 100644 +--- a/drivers/gpu/drm/drm_crtc.c ++++ b/drivers/gpu/drm/drm_crtc.c +@@ -1374,7 +1374,7 @@ int drm_mode_getconnector(struct drm_device *dev, = void *data, */ if ((out_resp->count_modes >=3D mode_count) && mode_count) { copied =3D 0; @@ -27028,7 +27647,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr list_for_each_entry(mode, &connector->modes, head) { drm_crtc_convert_to_umode(&u_mode, mode); if (copy_to_user(mode_ptr + copied, -@@ -1389,8 +1389,8 @@ int drm_mode_getconnector(struct drm_dev +@@ -1389,8 +1389,8 @@ int drm_mode_getconnector(struct drm_device *dev, = void *data, =20 if ((out_resp->count_props >=3D props_count) && props_count) { copied =3D 0; @@ -27039,7 +27658,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr for (i =3D 0; i < DRM_CONNECTOR_MAX_PROPERTY; i++) { if (connector->property_ids[i] !=3D 0) { if (put_user(connector->property_ids[i], -@@ -1412,7 +1412,7 @@ int drm_mode_getconnector(struct drm_dev +@@ -1412,7 +1412,7 @@ int drm_mode_getconnector(struct drm_device *dev, = void *data, =20 if ((out_resp->count_encoders >=3D encoders_count) && encoders_count) = { copied =3D 0; @@ -27048,7 +27667,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr for (i =3D 0; i < DRM_CONNECTOR_MAX_ENCODER; i++) { if (connector->encoder_ids[i] !=3D 0) { if (put_user(connector->encoder_ids[i], -@@ -1571,7 +1571,7 @@ int drm_mode_setcrtc(struct drm_device * +@@ -1571,7 +1571,7 @@ int drm_mode_setcrtc(struct drm_device *dev, void = *data, } =20 for (i =3D 0; i < crtc_req->count_connectors; i++) { @@ -27057,7 +27676,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr if (get_user(out_id, &set_connectors_ptr[i])) { ret =3D -EFAULT; goto out; -@@ -1852,7 +1852,7 @@ int drm_mode_dirtyfb_ioctl(struct drm_de +@@ -1852,7 +1852,7 @@ int drm_mode_dirtyfb_ioctl(struct drm_device *dev, fb =3D obj_to_fb(obj); =20 num_clips =3D r->num_clips; @@ -27066,7 +27685,18 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.= c linux-3.1.4/drivers/gpu/drm/dr =20 if (!num_clips !=3D !clips_ptr) { ret =3D -EINVAL; -@@ -2272,7 +2272,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -1868,6 +1868,10 @@ int drm_mode_dirtyfb_ioctl(struct drm_device *dev= , + } +=20 + if (num_clips && clips_ptr) { ++ if (num_clips < 0 || num_clips > DRM_MODE_FB_DIRTY_MAX_CLIPS) { ++ ret =3D -EINVAL; ++ goto out_err1; ++ } + clips =3D kzalloc(num_clips * sizeof(*clips), GFP_KERNEL); + if (!clips) { + ret =3D -ENOMEM; +@@ -2272,7 +2276,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *= dev, out_resp->flags =3D property->flags; =20 if ((out_resp->count_values >=3D value_count) && value_count) { @@ -27075,7 +27705,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr for (i =3D 0; i < value_count; i++) { if (copy_to_user(values_ptr + i, &property->values[i], sizeof(uint64= _t))) { ret =3D -EFAULT; -@@ -2285,7 +2285,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2285,7 +2289,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *= dev, if (property->flags & DRM_MODE_PROP_ENUM) { if ((out_resp->count_enum_blobs >=3D enum_count) && enum_count) { copied =3D 0; @@ -27084,7 +27714,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr list_for_each_entry(prop_enum, &property->enum_blob_list, head) { =20 if (copy_to_user(&enum_ptr[copied].value, &prop_enum->value, sizeof= (uint64_t))) { -@@ -2308,7 +2308,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2308,7 +2312,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *= dev, if ((out_resp->count_enum_blobs >=3D blob_count) && blob_count) { copied =3D 0; blob_id_ptr =3D (uint32_t *)(unsigned long)out_resp->enum_blob_ptr; @@ -27093,7 +27723,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr =20 list_for_each_entry(prop_blob, &property->enum_blob_list, head) { if (put_user(prop_blob->base.id, blob_id_ptr + copied)) { -@@ -2369,7 +2369,7 @@ int drm_mode_getblob_ioctl(struct drm_de +@@ -2369,7 +2373,7 @@ int drm_mode_getblob_ioctl(struct drm_device *dev, struct drm_mode_get_blob *out_resp =3D data; struct drm_property_blob *blob; int ret =3D 0; @@ -27102,7 +27732,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc.c= linux-3.1.4/drivers/gpu/drm/dr =20 if (!drm_core_check_feature(dev, DRIVER_MODESET)) return -EINVAL; -@@ -2383,7 +2383,7 @@ int drm_mode_getblob_ioctl(struct drm_de +@@ -2383,7 +2387,7 @@ int drm_mode_getblob_ioctl(struct drm_device *dev, blob =3D obj_to_blob(obj); =20 if (out_resp->length =3D=3D blob->length) { @@ -27111,10 +27741,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc= .c linux-3.1.4/drivers/gpu/drm/dr if (copy_to_user(blob_ptr, blob->data, blob->length)){ ret =3D -EFAULT; goto done; -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc_helper.c linux-3.1.4/dri= vers/gpu/drm/drm_crtc_helper.c ---- linux-3.1.4/drivers/gpu/drm/drm_crtc_helper.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_crtc_helper.c 2011-11-16 18:40:10.00= 0000000 -0500 -@@ -276,7 +276,7 @@ static bool drm_encoder_crtc_ok(struct d +diff --git a/drivers/gpu/drm/drm_crtc_helper.c b/drivers/gpu/drm/drm_crt= c_helper.c +index f88a9b2..8f4078f 100644 +--- a/drivers/gpu/drm/drm_crtc_helper.c ++++ b/drivers/gpu/drm/drm_crtc_helper.c +@@ -276,7 +276,7 @@ static bool drm_encoder_crtc_ok(struct drm_encoder *= encoder, struct drm_crtc *tmp; int crtc_mask =3D 1; =20 @@ -27123,7 +27754,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc_h= elper.c linux-3.1.4/drivers/gpu =20 dev =3D crtc->dev; =20 -@@ -343,6 +343,8 @@ bool drm_crtc_helper_set_mode(struct drm +@@ -343,6 +343,8 @@ bool drm_crtc_helper_set_mode(struct drm_crtc *crtc, struct drm_encoder *encoder; bool ret =3D true; =20 @@ -27132,9 +27763,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_crtc_= helper.c linux-3.1.4/drivers/gpu crtc->enabled =3D drm_helper_crtc_in_use(crtc); if (!crtc->enabled) return true; -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_drv.c linux-3.1.4/drivers/gpu= /drm/drm_drv.c ---- linux-3.1.4/drivers/gpu/drm/drm_drv.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_drv.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c +index 93a112d..c8b065d 100644 +--- a/drivers/gpu/drm/drm_drv.c ++++ b/drivers/gpu/drm/drm_drv.c @@ -307,7 +307,7 @@ module_exit(drm_core_exit); /** * Copy and IOCTL return string to user space @@ -27153,10 +27785,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_drv.= c linux-3.1.4/drivers/gpu/drm/drm ++file_priv->ioctl_count; =20 DRM_DEBUG("pid=3D%d, cmd=3D0x%02x, nr=3D0x%02x, dev 0x%lx, auth=3D%d\n= ", -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_fops.c linux-3.1.4/drivers/gp= u/drm/drm_fops.c ---- linux-3.1.4/drivers/gpu/drm/drm_fops.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_fops.c 2011-11-16 18:39:07.000000000= -0500 -@@ -70,7 +70,7 @@ static int drm_setup(struct drm_device * +diff --git a/drivers/gpu/drm/drm_fops.c b/drivers/gpu/drm/drm_fops.c +index 2ec7d48..be14bb1 100644 +--- a/drivers/gpu/drm/drm_fops.c ++++ b/drivers/gpu/drm/drm_fops.c +@@ -70,7 +70,7 @@ static int drm_setup(struct drm_device * dev) } =20 for (i =3D 0; i < ARRAY_SIZE(dev->counts); i++) @@ -27165,7 +27798,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_fops.c= linux-3.1.4/drivers/gpu/drm/dr =20 dev->sigdata.lock =3D NULL; =20 -@@ -134,8 +134,8 @@ int drm_open(struct inode *inode, struct +@@ -134,8 +134,8 @@ int drm_open(struct inode *inode, struct file *filp) =20 retcode =3D drm_open_helper(inode, filp, dev); if (!retcode) { @@ -27176,7 +27809,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_fops.c= linux-3.1.4/drivers/gpu/drm/dr retcode =3D drm_setup(dev); } if (!retcode) { -@@ -472,7 +472,7 @@ int drm_release(struct inode *inode, str +@@ -472,7 +472,7 @@ int drm_release(struct inode *inode, struct file *fi= lp) =20 mutex_lock(&drm_global_mutex); =20 @@ -27185,7 +27818,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_fops.c= linux-3.1.4/drivers/gpu/drm/dr =20 if (dev->driver->preclose) dev->driver->preclose(dev, file_priv); -@@ -484,7 +484,7 @@ int drm_release(struct inode *inode, str +@@ -484,7 +484,7 @@ int drm_release(struct inode *inode, struct file *fi= lp) DRM_DEBUG("pid =3D %d, device =3D 0x%lx, open_count =3D %d\n", task_pid_nr(current), (long)old_encode_dev(file_priv->minor->device), @@ -27194,7 +27827,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_fops.c= linux-3.1.4/drivers/gpu/drm/dr =20 /* if the master has gone away we can't do anything with the lock */ if (file_priv->minor->master) -@@ -565,8 +565,8 @@ int drm_release(struct inode *inode, str +@@ -565,8 +565,8 @@ int drm_release(struct inode *inode, struct file *fi= lp) * End inline drm_release */ =20 @@ -27205,9 +27838,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_fops.= c linux-3.1.4/drivers/gpu/drm/dr if (atomic_read(&dev->ioctl_count)) { DRM_ERROR("Device busy: %d\n", atomic_read(&dev->ioctl_count)); -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_global.c linux-3.1.4/drivers/= gpu/drm/drm_global.c ---- linux-3.1.4/drivers/gpu/drm/drm_global.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_global.c 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/drivers/gpu/drm/drm_global.c b/drivers/gpu/drm/drm_global.c +index c87dc96..326055d 100644 +--- a/drivers/gpu/drm/drm_global.c ++++ b/drivers/gpu/drm/drm_global.c @@ -36,7 +36,7 @@ struct drm_global_item { struct mutex mutex; @@ -27235,7 +27869,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_global= .c linux-3.1.4/drivers/gpu/drm/ } } =20 -@@ -70,7 +70,7 @@ int drm_global_item_ref(struct drm_globa +@@ -70,7 +70,7 @@ int drm_global_item_ref(struct drm_global_reference *r= ef) void *object; =20 mutex_lock(&item->mutex); @@ -27244,7 +27878,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_global= .c linux-3.1.4/drivers/gpu/drm/ item->object =3D kzalloc(ref->size, GFP_KERNEL); if (unlikely(item->object =3D=3D NULL)) { ret =3D -ENOMEM; -@@ -83,7 +83,7 @@ int drm_global_item_ref(struct drm_globa +@@ -83,7 +83,7 @@ int drm_global_item_ref(struct drm_global_reference *r= ef) goto out_err; =20 } @@ -27253,7 +27887,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_global= .c linux-3.1.4/drivers/gpu/drm/ ref->object =3D item->object; object =3D item->object; mutex_unlock(&item->mutex); -@@ -100,9 +100,9 @@ void drm_global_item_unref(struct drm_gl +@@ -100,9 +100,9 @@ void drm_global_item_unref(struct drm_global_referen= ce *ref) struct drm_global_item *item =3D &glob[ref->global_type]; =20 mutex_lock(&item->mutex); @@ -27265,10 +27899,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_glob= al.c linux-3.1.4/drivers/gpu/drm/ ref->release(ref); item->object =3D NULL; } -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_info.c linux-3.1.4/drivers/gp= u/drm/drm_info.c ---- linux-3.1.4/drivers/gpu/drm/drm_info.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_info.c 2011-11-16 18:40:10.000000000= -0500 -@@ -75,10 +75,14 @@ int drm_vm_info(struct seq_file *m, void +diff --git a/drivers/gpu/drm/drm_info.c b/drivers/gpu/drm/drm_info.c +index ab1162d..42587b2 100644 +--- a/drivers/gpu/drm/drm_info.c ++++ b/drivers/gpu/drm/drm_info.c +@@ -75,10 +75,14 @@ int drm_vm_info(struct seq_file *m, void *data) struct drm_local_map *map; struct drm_map_list *r_list; =20 @@ -27287,7 +27922,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_info.c= linux-3.1.4/drivers/gpu/drm/dr const char *type; int i; =20 -@@ -89,7 +93,7 @@ int drm_vm_info(struct seq_file *m, void +@@ -89,7 +93,7 @@ int drm_vm_info(struct seq_file *m, void *data) map =3D r_list->map; if (!map) continue; @@ -27296,7 +27931,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_info.c= linux-3.1.4/drivers/gpu/drm/dr type =3D "??"; else type =3D types[map->type]; -@@ -290,7 +294,11 @@ int drm_vma_info(struct seq_file *m, voi +@@ -290,7 +294,11 @@ int drm_vma_info(struct seq_file *m, void *data) vma->vm_flags & VM_MAYSHARE ? 's' : 'p', vma->vm_flags & VM_LOCKED ? 'l' : '-', vma->vm_flags & VM_IO ? 'i' : '-', @@ -27308,10 +27943,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_info= .c linux-3.1.4/drivers/gpu/drm/dr =20 #if defined(__i386__) pgprot =3D pgprot_val(vma->vm_page_prot); -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_ioc32.c linux-3.1.4/drivers/g= pu/drm/drm_ioc32.c ---- linux-3.1.4/drivers/gpu/drm/drm_ioc32.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_ioc32.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -455,7 +455,7 @@ static int compat_drm_infobufs(struct fi +diff --git a/drivers/gpu/drm/drm_ioc32.c b/drivers/gpu/drm/drm_ioc32.c +index 4a058c7..b42cd92 100644 +--- a/drivers/gpu/drm/drm_ioc32.c ++++ b/drivers/gpu/drm/drm_ioc32.c +@@ -455,7 +455,7 @@ static int compat_drm_infobufs(struct file *file, un= signed int cmd, request =3D compat_alloc_user_space(nbytes); if (!access_ok(VERIFY_WRITE, request, nbytes)) return -EFAULT; @@ -27320,7 +27956,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_ioc32.= c linux-3.1.4/drivers/gpu/drm/d =20 if (__put_user(count, &request->count) || __put_user(list, &request->list)) -@@ -516,7 +516,7 @@ static int compat_drm_mapbufs(struct fil +@@ -516,7 +516,7 @@ static int compat_drm_mapbufs(struct file *file, uns= igned int cmd, request =3D compat_alloc_user_space(nbytes); if (!access_ok(VERIFY_WRITE, request, nbytes)) return -EFAULT; @@ -27329,10 +27965,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_ioc3= 2.c linux-3.1.4/drivers/gpu/drm/d =20 if (__put_user(count, &request->count) || __put_user(list, &request->list)) -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_ioctl.c linux-3.1.4/drivers/g= pu/drm/drm_ioctl.c ---- linux-3.1.4/drivers/gpu/drm/drm_ioctl.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_ioctl.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -256,7 +256,7 @@ int drm_getstats(struct drm_device *dev, +diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c +index 904d7e9..ab88581 100644 +--- a/drivers/gpu/drm/drm_ioctl.c ++++ b/drivers/gpu/drm/drm_ioctl.c +@@ -256,7 +256,7 @@ int drm_getstats(struct drm_device *dev, void *data, stats->data[i].value =3D (file_priv->master->lock.hw_lock ? file_priv->master->lock.hw_lo= ck->lock : 0); else @@ -27341,10 +27978,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_ioct= l.c linux-3.1.4/drivers/gpu/drm/d stats->data[i].type =3D dev->types[i]; } =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/drm_lock.c linux-3.1.4/drivers/gp= u/drm/drm_lock.c ---- linux-3.1.4/drivers/gpu/drm/drm_lock.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/gpu/drm/drm_lock.c 2011-11-16 18:39:07.000000000= -0500 -@@ -89,7 +89,7 @@ int drm_lock(struct drm_device *dev, voi +diff --git a/drivers/gpu/drm/drm_lock.c b/drivers/gpu/drm/drm_lock.c +index 632ae24..244cf4a 100644 +--- a/drivers/gpu/drm/drm_lock.c ++++ b/drivers/gpu/drm/drm_lock.c +@@ -89,7 +89,7 @@ int drm_lock(struct drm_device *dev, void *data, struc= t drm_file *file_priv) if (drm_lock_take(&master->lock, lock->context)) { master->lock.file_priv =3D file_priv; master->lock.lock_time =3D jiffies; @@ -27353,7 +27991,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_lock.c= linux-3.1.4/drivers/gpu/drm/dr break; /* Got lock */ } =20 -@@ -160,7 +160,7 @@ int drm_unlock(struct drm_device *dev, v +@@ -160,7 +160,7 @@ int drm_unlock(struct drm_device *dev, void *data, s= truct drm_file *file_priv) return -EINVAL; } =20 @@ -27362,10 +28000,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/drm_lock= .c linux-3.1.4/drivers/gpu/drm/dr =20 if (drm_lock_free(&master->lock, lock->context)) { /* FIXME: Should really bail out here. */ -diff -urNp linux-3.1.4/drivers/gpu/drm/i810/i810_dma.c linux-3.1.4/drive= rs/gpu/drm/i810/i810_dma.c ---- linux-3.1.4/drivers/gpu/drm/i810/i810_dma.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i810/i810_dma.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -950,8 +950,8 @@ static int i810_dma_vertex(struct drm_de +diff --git a/drivers/gpu/drm/i810/i810_dma.c b/drivers/gpu/drm/i810/i810= _dma.c +index 8f371e8..9f85d52 100644 +--- a/drivers/gpu/drm/i810/i810_dma.c ++++ b/drivers/gpu/drm/i810/i810_dma.c +@@ -950,8 +950,8 @@ static int i810_dma_vertex(struct drm_device *dev, v= oid *data, dma->buflist[vertex->idx], vertex->discard, vertex->used); =20 @@ -27376,7 +28015,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i810/i810_= dma.c linux-3.1.4/drivers/gpu/d sarea_priv->last_enqueue =3D dev_priv->counter - 1; sarea_priv->last_dispatch =3D (int)hw_status[5]; =20 -@@ -1111,8 +1111,8 @@ static int i810_dma_mc(struct drm_device +@@ -1111,8 +1111,8 @@ static int i810_dma_mc(struct drm_device *dev, voi= d *data, i810_dma_dispatch_mc(dev, dma->buflist[mc->idx], mc->used, mc->last_render); =20 @@ -27387,9 +28026,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i810/i810= _dma.c linux-3.1.4/drivers/gpu/d sarea_priv->last_enqueue =3D dev_priv->counter - 1; sarea_priv->last_dispatch =3D (int)hw_status[5]; =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/i810/i810_drv.h linux-3.1.4/drive= rs/gpu/drm/i810/i810_drv.h ---- linux-3.1.4/drivers/gpu/drm/i810/i810_drv.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i810/i810_drv.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/gpu/drm/i810/i810_drv.h b/drivers/gpu/drm/i810/i810= _drv.h +index c9339f4..f5e1b9d 100644 +--- a/drivers/gpu/drm/i810/i810_drv.h ++++ b/drivers/gpu/drm/i810/i810_drv.h @@ -108,8 +108,8 @@ typedef struct drm_i810_private { int page_flipping; =20 @@ -27401,10 +28041,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i810/i81= 0_drv.h linux-3.1.4/drivers/gpu/d =20 int front_offset; } drm_i810_private_t; -diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_debugfs.c linux-3.1.4/d= rivers/gpu/drm/i915/i915_debugfs.c ---- linux-3.1.4/drivers/gpu/drm/i915/i915_debugfs.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i915/i915_debugfs.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -497,7 +497,7 @@ static int i915_interrupt_info(struct se +diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/= i915_debugfs.c +index 3c395a5..02889c2 100644 +--- a/drivers/gpu/drm/i915/i915_debugfs.c ++++ b/drivers/gpu/drm/i915/i915_debugfs.c +@@ -497,7 +497,7 @@ static int i915_interrupt_info(struct seq_file *m, v= oid *data) I915_READ(GTIMR)); } seq_printf(m, "Interrupts received: %d\n", @@ -27413,7 +28054,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_= debugfs.c linux-3.1.4/drivers/g for (i =3D 0; i < I915_NUM_RINGS; i++) { if (IS_GEN6(dev) || IS_GEN7(dev)) { seq_printf(m, "Graphics Interrupt mask (%s): %08x\n", -@@ -1185,7 +1185,7 @@ static int i915_opregion(struct seq_file +@@ -1185,7 +1185,7 @@ static int i915_opregion(struct seq_file *m, void = *unused) return ret; =20 if (opregion->header) @@ -27422,10 +28063,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i91= 5_debugfs.c linux-3.1.4/drivers/g =20 mutex_unlock(&dev->struct_mutex); =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_dma.c linux-3.1.4/drive= rs/gpu/drm/i915/i915_dma.c ---- linux-3.1.4/drivers/gpu/drm/i915/i915_dma.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i915/i915_dma.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -1171,7 +1171,7 @@ static bool i915_switcheroo_can_switch(s +diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915= _dma.c +index 8a3942c..1b73bf1 100644 +--- a/drivers/gpu/drm/i915/i915_dma.c ++++ b/drivers/gpu/drm/i915/i915_dma.c +@@ -1171,7 +1171,7 @@ static bool i915_switcheroo_can_switch(struct pci_= dev *pdev) bool can_switch; =20 spin_lock(&dev->count_lock); @@ -27434,9 +28076,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915= _dma.c linux-3.1.4/drivers/gpu/d spin_unlock(&dev->count_lock); return can_switch; } -diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_drv.h linux-3.1.4/drive= rs/gpu/drm/i915/i915_drv.h ---- linux-3.1.4/drivers/gpu/drm/i915/i915_drv.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i915/i915_drv.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915= _drv.h +index 7916bd9..7c17a0f 100644 +--- a/drivers/gpu/drm/i915/i915_drv.h ++++ b/drivers/gpu/drm/i915/i915_drv.h @@ -222,7 +222,7 @@ struct drm_i915_display_funcs { /* render clock increase/decrease */ /* display clock increase/decrease */ @@ -27464,7 +28107,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_= drv.h linux-3.1.4/drivers/gpu/d }; =20 #define to_intel_bo(x) container_of(x, struct drm_i915_gem_object, base= ) -@@ -1262,7 +1262,7 @@ extern int intel_setup_gmbus(struct drm_ +@@ -1262,7 +1262,7 @@ extern int intel_setup_gmbus(struct drm_device *de= v); extern void intel_teardown_gmbus(struct drm_device *dev); extern void intel_gmbus_set_speed(struct i2c_adapter *adapter, int spee= d); extern void intel_gmbus_force_bit(struct i2c_adapter *adapter, bool for= ce_bit); @@ -27473,10 +28116,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i91= 5_drv.h linux-3.1.4/drivers/gpu/d { return container_of(adapter, struct intel_gmbus, adapter)->force_bit; } -diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_gem_execbuffer.c linux-= 3.1.4/drivers/gpu/drm/i915/i915_gem_execbuffer.c ---- linux-3.1.4/drivers/gpu/drm/i915/i915_gem_execbuffer.c 2011-11-11 15= :19:27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i915/i915_gem_execbuffer.c 2011-11-16 18= :39:07.000000000 -0500 -@@ -188,7 +188,7 @@ i915_gem_object_set_to_gpu_domain(struct +diff --git a/drivers/gpu/drm/i915/i915_gem_execbuffer.c b/drivers/gpu/dr= m/i915/i915_gem_execbuffer.c +index 4934cf8..52e8e83 100644 +--- a/drivers/gpu/drm/i915/i915_gem_execbuffer.c ++++ b/drivers/gpu/drm/i915/i915_gem_execbuffer.c +@@ -188,7 +188,7 @@ i915_gem_object_set_to_gpu_domain(struct drm_i915_ge= m_object *obj, i915_gem_clflush_object(obj); =20 if (obj->base.pending_write_domain) @@ -27485,10 +28129,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i91= 5_gem_execbuffer.c linux-3.1.4/dr =20 /* The actual obj->write_domain will be updated with * pending_write_domain after we emit the accumulated flush for all -diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_irq.c linux-3.1.4/drive= rs/gpu/drm/i915/i915_irq.c ---- linux-3.1.4/drivers/gpu/drm/i915/i915_irq.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i915/i915_irq.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -475,7 +475,7 @@ static irqreturn_t ivybridge_irq_handler +diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915= _irq.c +index 9cbb0cd..958a31f 100644 +--- a/drivers/gpu/drm/i915/i915_irq.c ++++ b/drivers/gpu/drm/i915/i915_irq.c +@@ -475,7 +475,7 @@ static irqreturn_t ivybridge_irq_handler(DRM_IRQ_ARG= S) u32 de_iir, gt_iir, de_ier, pch_iir, pm_iir; struct drm_i915_master_private *master_priv; =20 @@ -27497,7 +28142,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_= irq.c linux-3.1.4/drivers/gpu/d =20 /* disable master interrupt before clearing iir */ de_ier =3D I915_READ(DEIER); -@@ -565,7 +565,7 @@ static irqreturn_t ironlake_irq_handler( +@@ -565,7 +565,7 @@ static irqreturn_t ironlake_irq_handler(DRM_IRQ_ARGS= ) struct drm_i915_master_private *master_priv; u32 bsd_usr_interrupt =3D GT_BSD_USER_INTERRUPT; =20 @@ -27506,7 +28151,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_= irq.c linux-3.1.4/drivers/gpu/d =20 if (IS_GEN6(dev)) bsd_usr_interrupt =3D GT_GEN6_BSD_USER_INTERRUPT; -@@ -1228,7 +1228,7 @@ static irqreturn_t i915_driver_irq_handl +@@ -1228,7 +1228,7 @@ static irqreturn_t i915_driver_irq_handler(DRM_IRQ= _ARGS) int ret =3D IRQ_NONE, pipe; bool blc_event =3D false; =20 @@ -27515,7 +28160,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_= irq.c linux-3.1.4/drivers/gpu/d =20 iir =3D I915_READ(IIR); =20 -@@ -1740,7 +1740,7 @@ static void ironlake_irq_preinstall(stru +@@ -1740,7 +1740,7 @@ static void ironlake_irq_preinstall(struct drm_dev= ice *dev) { drm_i915_private_t *dev_priv =3D (drm_i915_private_t *) dev->dev_priva= te; =20 @@ -27524,7 +28169,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i915_= irq.c linux-3.1.4/drivers/gpu/d =20 INIT_WORK(&dev_priv->hotplug_work, i915_hotplug_work_func); INIT_WORK(&dev_priv->error_work, i915_error_work_func); -@@ -1904,7 +1904,7 @@ static void i915_driver_irq_preinstall(s +@@ -1904,7 +1904,7 @@ static void i915_driver_irq_preinstall(struct drm_= device * dev) drm_i915_private_t *dev_priv =3D (drm_i915_private_t *) dev->dev_priva= te; int pipe; =20 @@ -27533,10 +28178,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/i91= 5_irq.c linux-3.1.4/drivers/gpu/d =20 INIT_WORK(&dev_priv->hotplug_work, i915_hotplug_work_func); INIT_WORK(&dev_priv->error_work, i915_error_work_func); -diff -urNp linux-3.1.4/drivers/gpu/drm/i915/intel_display.c linux-3.1.4/= drivers/gpu/drm/i915/intel_display.c ---- linux-3.1.4/drivers/gpu/drm/i915/intel_display.c 2011-11-26 19:57:29= .000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/i915/intel_display.c 2011-11-26 20:00:43= .000000000 -0500 -@@ -2205,7 +2205,7 @@ intel_pipe_set_base(struct drm_crtc *crt +diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915= /intel_display.c +index e1340a2..24f40c3 100644 +--- a/drivers/gpu/drm/i915/intel_display.c ++++ b/drivers/gpu/drm/i915/intel_display.c +@@ -2205,7 +2205,7 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, = int y, =20 wait_event(dev_priv->pending_flip_queue, atomic_read(&dev_priv->mm.wedged) || @@ -27545,7 +28191,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/intel= _display.c linux-3.1.4/drivers/ =20 /* Big Hammer, we also need to ensure that any pending * MI_WAIT_FOR_EVENT inside a user batch buffer on the -@@ -2826,7 +2826,7 @@ static void intel_crtc_wait_for_pending_ +@@ -2826,7 +2826,7 @@ static void intel_crtc_wait_for_pending_flips(stru= ct drm_crtc *crtc) obj =3D to_intel_framebuffer(crtc->fb)->obj; dev_priv =3D crtc->dev->dev_private; wait_event(dev_priv->pending_flip_queue, @@ -27554,7 +28200,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/intel= _display.c linux-3.1.4/drivers/ } =20 static bool intel_crtc_driving_pch(struct drm_crtc *crtc) -@@ -6676,7 +6676,7 @@ static void do_intel_finish_page_flip(st +@@ -6676,7 +6676,7 @@ static void do_intel_finish_page_flip(struct drm_d= evice *dev, =20 atomic_clear_mask(1 << intel_crtc->plane, &obj->pending_flip.counter); @@ -27563,7 +28209,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/intel= _display.c linux-3.1.4/drivers/ wake_up(&dev_priv->pending_flip_queue); =20 schedule_work(&work->work); -@@ -6965,7 +6965,7 @@ static int intel_crtc_page_flip(struct d +@@ -6965,7 +6965,7 @@ static int intel_crtc_page_flip(struct drm_crtc *c= rtc, /* Block clients from rendering to the new back buffer until * the flip occurs and the object is no longer visible. */ @@ -27572,7 +28218,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/intel= _display.c linux-3.1.4/drivers/ =20 ret =3D dev_priv->display.queue_flip(dev, crtc, fb, obj); if (ret) -@@ -6979,7 +6979,7 @@ static int intel_crtc_page_flip(struct d +@@ -6979,7 +6979,7 @@ static int intel_crtc_page_flip(struct drm_crtc *c= rtc, return 0; =20 cleanup_pending: @@ -27581,9 +28227,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/i915/inte= l_display.c linux-3.1.4/drivers/ cleanup_objs: drm_gem_object_unreference(&work->old_fb_obj->base); drm_gem_object_unreference(&obj->base); -diff -urNp linux-3.1.4/drivers/gpu/drm/mga/mga_drv.h linux-3.1.4/drivers= /gpu/drm/mga/mga_drv.h ---- linux-3.1.4/drivers/gpu/drm/mga/mga_drv.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/mga/mga_drv.h 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/drivers/gpu/drm/mga/mga_drv.h b/drivers/gpu/drm/mga/mga_drv= .h +index 54558a0..2d97005 100644 +--- a/drivers/gpu/drm/mga/mga_drv.h ++++ b/drivers/gpu/drm/mga/mga_drv.h @@ -120,9 +120,9 @@ typedef struct drm_mga_private { u32 clear_cmd; u32 maccess; @@ -27596,10 +28243,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/mga/mga_= drv.h linux-3.1.4/drivers/gpu/drm u32 next_fence_to_post; =20 unsigned int fb_cpp; -diff -urNp linux-3.1.4/drivers/gpu/drm/mga/mga_irq.c linux-3.1.4/drivers= /gpu/drm/mga/mga_irq.c ---- linux-3.1.4/drivers/gpu/drm/mga/mga_irq.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/mga/mga_irq.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -44,7 +44,7 @@ u32 mga_get_vblank_counter(struct drm_de +diff --git a/drivers/gpu/drm/mga/mga_irq.c b/drivers/gpu/drm/mga/mga_irq= .c +index 2581202..f230a8d9 100644 +--- a/drivers/gpu/drm/mga/mga_irq.c ++++ b/drivers/gpu/drm/mga/mga_irq.c +@@ -44,7 +44,7 @@ u32 mga_get_vblank_counter(struct drm_device *dev, int= crtc) if (crtc !=3D 0) return 0; =20 @@ -27608,7 +28256,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/mga/mga_ir= q.c linux-3.1.4/drivers/gpu/drm } =20 =20 -@@ -60,7 +60,7 @@ irqreturn_t mga_driver_irq_handler(DRM_I +@@ -60,7 +60,7 @@ irqreturn_t mga_driver_irq_handler(DRM_IRQ_ARGS) /* VBLANK interrupt */ if (status & MGA_VLINEPEN) { MGA_WRITE(MGA_ICLEAR, MGA_VLINEICLR); @@ -27617,7 +28265,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/mga/mga_ir= q.c linux-3.1.4/drivers/gpu/drm drm_handle_vblank(dev, 0); handled =3D 1; } -@@ -79,7 +79,7 @@ irqreturn_t mga_driver_irq_handler(DRM_I +@@ -79,7 +79,7 @@ irqreturn_t mga_driver_irq_handler(DRM_IRQ_ARGS) if ((prim_start & ~0x03) !=3D (prim_end & ~0x03)) MGA_WRITE(MGA_PRIMEND, prim_end); =20 @@ -27626,7 +28274,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/mga/mga_ir= q.c linux-3.1.4/drivers/gpu/drm DRM_WAKEUP(&dev_priv->fence_queue); handled =3D 1; } -@@ -130,7 +130,7 @@ int mga_driver_fence_wait(struct drm_dev +@@ -130,7 +130,7 @@ int mga_driver_fence_wait(struct drm_device *dev, un= signed int *sequence) * using fences. */ DRM_WAIT_ON(ret, dev_priv->fence_queue, 3 * DRM_HZ, @@ -27635,9 +28283,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/mga/mga_i= rq.c linux-3.1.4/drivers/gpu/drm - *sequence) <=3D (1 << 23))); =20 *sequence =3D cur_fence; -diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_bios.c linux-3.1.= 4/drivers/gpu/drm/nouveau/nouveau_bios.c ---- linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_bios.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_bios.c 2011-11-16 18:39:= 07.000000000 -0500 +diff --git a/drivers/gpu/drm/nouveau/nouveau_bios.c b/drivers/gpu/drm/no= uveau/nouveau_bios.c +index b311fab..dc11d6a 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_bios.c ++++ b/drivers/gpu/drm/nouveau/nouveau_bios.c @@ -201,7 +201,7 @@ struct methods { const char desc[8]; void (*loadbios)(struct drm_device *, uint8_t *); @@ -27647,7 +28296,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/no= uveau_bios.c linux-3.1.4/driver =20 static struct methods shadow_methods[] =3D { { "PRAMIN", load_vbios_pramin, true }, -@@ -5489,7 +5489,7 @@ parse_bit_displayport_tbl_entry(struct d +@@ -5489,7 +5489,7 @@ parse_bit_displayport_tbl_entry(struct drm_device = *dev, struct nvbios *bios, struct bit_table { const char id; int (* const parse_fn)(struct drm_device *, struct nvbios *, struct bi= t_entry *); @@ -27656,9 +28305,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/n= ouveau_bios.c linux-3.1.4/driver =20 #define BIT_TABLE(id, funcid) ((struct bit_table){ id, parse_bit_##func= id##_tbl_entry }) =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_drv.h linux-3.1.4= /drivers/gpu/drm/nouveau/nouveau_drv.h ---- linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_drv.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_drv.h 2011-11-16 18:39:0= 7.000000000 -0500 +diff --git a/drivers/gpu/drm/nouveau/nouveau_drv.h b/drivers/gpu/drm/nou= veau/nouveau_drv.h +index d7d51de..7c6a7f1 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_drv.h ++++ b/drivers/gpu/drm/nouveau/nouveau_drv.h @@ -238,7 +238,7 @@ struct nouveau_channel { struct list_head pending; uint32_t sequence; @@ -27711,10 +28361,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/= nouveau_drv.h linux-3.1.4/drivers } ttm; =20 struct { -diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_fence.c linux-3.1= .4/drivers/gpu/drm/nouveau/nouveau_fence.c ---- linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_fence.c 2011-11-26 19:57= :27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_fence.c 2011-11-26 20:00= :06.000000000 -0500 -@@ -85,7 +85,7 @@ nouveau_fence_update(struct nouveau_chan +diff --git a/drivers/gpu/drm/nouveau/nouveau_fence.c b/drivers/gpu/drm/n= ouveau/nouveau_fence.c +index ae22dfa..4f09960 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_fence.c ++++ b/drivers/gpu/drm/nouveau/nouveau_fence.c +@@ -85,7 +85,7 @@ nouveau_fence_update(struct nouveau_channel *chan) if (USE_REFCNT(dev)) sequence =3D nvchan_rd32(chan, 0x48); else @@ -27723,7 +28374,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/no= uveau_fence.c linux-3.1.4/drive =20 if (chan->fence.sequence_ack =3D=3D sequence) goto out; -@@ -539,7 +539,7 @@ nouveau_fence_channel_init(struct nouvea +@@ -539,7 +539,7 @@ nouveau_fence_channel_init(struct nouveau_channel *c= han) return ret; } =20 @@ -27732,10 +28383,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/= nouveau_fence.c linux-3.1.4/drive return 0; } =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_gem.c linux-3.1.4= /drivers/gpu/drm/nouveau/nouveau_gem.c ---- linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_gem.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_gem.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -314,7 +314,7 @@ validate_init(struct nouveau_channel *ch +diff --git a/drivers/gpu/drm/nouveau/nouveau_gem.c b/drivers/gpu/drm/nou= veau/nouveau_gem.c +index 5f0bc57..eb9fac8 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_gem.c ++++ b/drivers/gpu/drm/nouveau/nouveau_gem.c +@@ -314,7 +314,7 @@ validate_init(struct nouveau_channel *chan, struct d= rm_file *file_priv, int trycnt =3D 0; int ret, i; =20 @@ -27744,10 +28396,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/= nouveau_gem.c linux-3.1.4/drivers retry: if (++trycnt > 100000) { NV_ERROR(dev, "%s failed and gave up.\n", __func__); -diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_state.c linux-3.1= .4/drivers/gpu/drm/nouveau/nouveau_state.c ---- linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_state.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/nouveau/nouveau_state.c 2011-11-16 18:39= :07.000000000 -0500 -@@ -496,7 +496,7 @@ static bool nouveau_switcheroo_can_switc +diff --git a/drivers/gpu/drm/nouveau/nouveau_state.c b/drivers/gpu/drm/n= ouveau/nouveau_state.c +index 10656e4..59bf2a4 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_state.c ++++ b/drivers/gpu/drm/nouveau/nouveau_state.c +@@ -496,7 +496,7 @@ static bool nouveau_switcheroo_can_switch(struct pci= _dev *pdev) bool can_switch; =20 spin_lock(&dev->count_lock); @@ -27756,9 +28409,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/n= ouveau_state.c linux-3.1.4/drive spin_unlock(&dev->count_lock); return can_switch; } -diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/nv04_graph.c linux-3.1.4/= drivers/gpu/drm/nouveau/nv04_graph.c ---- linux-3.1.4/drivers/gpu/drm/nouveau/nv04_graph.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/nouveau/nv04_graph.c 2011-11-16 18:39:07= .000000000 -0500 +diff --git a/drivers/gpu/drm/nouveau/nv04_graph.c b/drivers/gpu/drm/nouv= eau/nv04_graph.c +index dbdea8e..cd6eeeb 100644 +--- a/drivers/gpu/drm/nouveau/nv04_graph.c ++++ b/drivers/gpu/drm/nouveau/nv04_graph.c @@ -554,7 +554,7 @@ static int nv04_graph_mthd_set_ref(struct nouveau_channel *chan, u32 class, u32 mthd, u32 data) @@ -27768,10 +28422,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/nouveau/= nv04_graph.c linux-3.1.4/drivers/ return 0; } =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r128_cce.c linux-3.1.4/drive= rs/gpu/drm/r128/r128_cce.c ---- linux-3.1.4/drivers/gpu/drm/r128/r128_cce.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/r128/r128_cce.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -377,7 +377,7 @@ static int r128_do_init_cce(struct drm_d +diff --git a/drivers/gpu/drm/r128/r128_cce.c b/drivers/gpu/drm/r128/r128= _cce.c +index 570e190..084a31a 100644 +--- a/drivers/gpu/drm/r128/r128_cce.c ++++ b/drivers/gpu/drm/r128/r128_cce.c +@@ -377,7 +377,7 @@ static int r128_do_init_cce(struct drm_device *dev, = drm_r128_init_t *init) =20 /* GH: Simple idle check. */ @@ -27780,9 +28435,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r128= _cce.c linux-3.1.4/drivers/gpu/d =20 /* We don't support anything other than bus-mastering ring mode, * but the ring can be in either AGP or PCI space for the ring -diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r128_drv.h linux-3.1.4/drive= rs/gpu/drm/r128/r128_drv.h ---- linux-3.1.4/drivers/gpu/drm/r128/r128_drv.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/r128/r128_drv.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/gpu/drm/r128/r128_drv.h b/drivers/gpu/drm/r128/r128= _drv.h +index 930c71b..499aded 100644 +--- a/drivers/gpu/drm/r128/r128_drv.h ++++ b/drivers/gpu/drm/r128/r128_drv.h @@ -90,14 +90,14 @@ typedef struct drm_r128_private { int is_pci; unsigned long cce_buffers_offset; @@ -27800,10 +28456,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r12= 8_drv.h linux-3.1.4/drivers/gpu/d =20 u32 color_fmt; unsigned int front_offset; -diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r128_irq.c linux-3.1.4/drive= rs/gpu/drm/r128/r128_irq.c ---- linux-3.1.4/drivers/gpu/drm/r128/r128_irq.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/r128/r128_irq.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -42,7 +42,7 @@ u32 r128_get_vblank_counter(struct drm_d +diff --git a/drivers/gpu/drm/r128/r128_irq.c b/drivers/gpu/drm/r128/r128= _irq.c +index 429d5a0..7e899ed 100644 +--- a/drivers/gpu/drm/r128/r128_irq.c ++++ b/drivers/gpu/drm/r128/r128_irq.c +@@ -42,7 +42,7 @@ u32 r128_get_vblank_counter(struct drm_device *dev, in= t crtc) if (crtc !=3D 0) return 0; =20 @@ -27812,7 +28469,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r128_= irq.c linux-3.1.4/drivers/gpu/d } =20 irqreturn_t r128_driver_irq_handler(DRM_IRQ_ARGS) -@@ -56,7 +56,7 @@ irqreturn_t r128_driver_irq_handler(DRM_ +@@ -56,7 +56,7 @@ irqreturn_t r128_driver_irq_handler(DRM_IRQ_ARGS) /* VBLANK interrupt */ if (status & R128_CRTC_VBLANK_INT) { R128_WRITE(R128_GEN_INT_STATUS, R128_CRTC_VBLANK_INT_AK); @@ -27821,10 +28478,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r12= 8_irq.c linux-3.1.4/drivers/gpu/d drm_handle_vblank(dev, 0); return IRQ_HANDLED; } -diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r128_state.c linux-3.1.4/dri= vers/gpu/drm/r128/r128_state.c ---- linux-3.1.4/drivers/gpu/drm/r128/r128_state.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/r128/r128_state.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -321,10 +321,10 @@ static void r128_clear_box(drm_r128_priv +diff --git a/drivers/gpu/drm/r128/r128_state.c b/drivers/gpu/drm/r128/r1= 28_state.c +index a9e33ce..09edd4b 100644 +--- a/drivers/gpu/drm/r128/r128_state.c ++++ b/drivers/gpu/drm/r128/r128_state.c +@@ -321,10 +321,10 @@ static void r128_clear_box(drm_r128_private_t *dev= _priv, =20 static void r128_cce_performance_boxes(drm_r128_private_t *dev_priv) { @@ -27837,10 +28495,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/r128/r12= 8_state.c linux-3.1.4/drivers/gpu } =20 #endif -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/atom.c linux-3.1.4/drivers= /gpu/drm/radeon/atom.c ---- linux-3.1.4/drivers/gpu/drm/radeon/atom.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/atom.c 2011-11-16 19:09:42.000000= 000 -0500 -@@ -1254,6 +1254,8 @@ struct atom_context *atom_parse(struct c +diff --git a/drivers/gpu/drm/radeon/atom.c b/drivers/gpu/drm/radeon/atom= .c +index 14cc88a..cc7b3a5 100644 +--- a/drivers/gpu/drm/radeon/atom.c ++++ b/drivers/gpu/drm/radeon/atom.c +@@ -1254,6 +1254,8 @@ struct atom_context *atom_parse(struct card_info *= card, void *bios) char name[512]; int i; =20 @@ -27849,10 +28508,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/a= tom.c linux-3.1.4/drivers/gpu/drm if (!ctx) return NULL; =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/mkregtable.c linux-3.1.4/d= rivers/gpu/drm/radeon/mkregtable.c ---- linux-3.1.4/drivers/gpu/drm/radeon/mkregtable.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/mkregtable.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -637,14 +637,14 @@ static int parser_auth(struct table *t,=20 +diff --git a/drivers/gpu/drm/radeon/mkregtable.c b/drivers/gpu/drm/radeo= n/mkregtable.c +index 5a82b6b..9e69c73 100644 +--- a/drivers/gpu/drm/radeon/mkregtable.c ++++ b/drivers/gpu/drm/radeon/mkregtable.c +@@ -637,14 +637,14 @@ static int parser_auth(struct table *t, const char= *filename) regex_t mask_rex; regmatch_t match[4]; char buf[1024]; @@ -27869,10 +28529,33 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/m= kregtable.c linux-3.1.4/drivers/g =20 if (regcomp (&mask_rex, "(0x[0-9a-fA-F]*) *([_a-zA-Z0-9]*)", REG_EXTENDED)) { -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_atombios.c linux-3.= 1.4/drivers/gpu/drm/radeon/radeon_atombios.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_atombios.c 2011-11-11 15:1= 9:27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_atombios.c 2011-11-16 18:4= 0:10.000000000 -0500 -@@ -545,6 +545,8 @@ bool radeon_get_atom_connector_info_from +diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/ra= deon.h +index 184628c..30e1725 100644 +--- a/drivers/gpu/drm/radeon/radeon.h ++++ b/drivers/gpu/drm/radeon/radeon.h +@@ -192,7 +192,7 @@ extern int sumo_get_temp(struct radeon_device *rdev)= ; + */ + struct radeon_fence_driver { + uint32_t scratch_reg; +- atomic_t seq; ++ atomic_unchecked_t seq; + uint32_t last_seq; + unsigned long last_jiffies; + unsigned long last_timeout; +@@ -962,7 +962,7 @@ struct radeon_asic { + void (*pre_page_flip)(struct radeon_device *rdev, int crtc); + u32 (*page_flip)(struct radeon_device *rdev, int crtc, u64 crtc_base); + void (*post_page_flip)(struct radeon_device *rdev, int crtc); +-}; ++} __no_const; +=20 + /* + * Asic structures +diff --git a/drivers/gpu/drm/radeon/radeon_atombios.c b/drivers/gpu/drm/= radeon/radeon_atombios.c +index bf2b615..c821ec8 100644 +--- a/drivers/gpu/drm/radeon/radeon_atombios.c ++++ b/drivers/gpu/drm/radeon/radeon_atombios.c +@@ -545,6 +545,8 @@ bool radeon_get_atom_connector_info_from_object_tabl= e(struct drm_device *dev) struct radeon_gpio_rec gpio; struct radeon_hpd hpd; =20 @@ -27881,10 +28564,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_atombios.c linux-3.1.4/driv if (!atom_parse_data_header(ctx, index, &size, &frev, &crev, &data_off= set)) return false; =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_device.c linux-3.1.= 4/drivers/gpu/drm/radeon/radeon_device.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_device.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_device.c 2011-11-16 18:39:= 07.000000000 -0500 -@@ -684,7 +684,7 @@ static bool radeon_switcheroo_can_switch +diff --git a/drivers/gpu/drm/radeon/radeon_device.c b/drivers/gpu/drm/ra= deon/radeon_device.c +index b51e157..8f14fb9 100644 +--- a/drivers/gpu/drm/radeon/radeon_device.c ++++ b/drivers/gpu/drm/radeon/radeon_device.c +@@ -684,7 +684,7 @@ static bool radeon_switcheroo_can_switch(struct pci_= dev *pdev) bool can_switch; =20 spin_lock(&dev->count_lock); @@ -27893,10 +28577,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_device.c linux-3.1.4/driver spin_unlock(&dev->count_lock); return can_switch; } -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_display.c linux-3.1= .4/drivers/gpu/drm/radeon/radeon_display.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_display.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_display.c 2011-11-16 18:40= :10.000000000 -0500 -@@ -925,6 +925,8 @@ void radeon_compute_pll_legacy(struct ra +diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/r= adeon/radeon_display.c +index 6adb3e5..b91553e2 100644 +--- a/drivers/gpu/drm/radeon/radeon_display.c ++++ b/drivers/gpu/drm/radeon/radeon_display.c +@@ -925,6 +925,8 @@ void radeon_compute_pll_legacy(struct radeon_pll *pl= l, uint32_t post_div; u32 pll_out_min, pll_out_max; =20 @@ -27905,9 +28590,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/ra= deon_display.c linux-3.1.4/drive DRM_DEBUG_KMS("PLL freq %llu %u %u\n", freq, pll->min_ref_div, pll->ma= x_ref_div); freq =3D freq * 1000; =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_drv.h linux-3.1.4/d= rivers/gpu/drm/radeon/radeon_drv.h ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_drv.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_drv.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/drivers/gpu/drm/radeon/radeon_drv.h b/drivers/gpu/drm/radeo= n/radeon_drv.h +index a1b59ca..86f2d44 100644 +--- a/drivers/gpu/drm/radeon/radeon_drv.h ++++ b/drivers/gpu/drm/radeon/radeon_drv.h @@ -255,7 +255,7 @@ typedef struct drm_radeon_private { =20 /* SW interrupt */ @@ -27917,10 +28603,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_drv.h linux-3.1.4/drivers/g int vblank_crtc; uint32_t irq_enable_reg; uint32_t r500_disp_irq_reg; -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_fence.c linux-3.1.4= /drivers/gpu/drm/radeon/radeon_fence.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_fence.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_fence.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -78,7 +78,7 @@ int radeon_fence_emit(struct radeon_devi +diff --git a/drivers/gpu/drm/radeon/radeon_fence.c b/drivers/gpu/drm/rad= eon/radeon_fence.c +index 7fd4e3e..9748ab5 100644 +--- a/drivers/gpu/drm/radeon/radeon_fence.c ++++ b/drivers/gpu/drm/radeon/radeon_fence.c +@@ -78,7 +78,7 @@ int radeon_fence_emit(struct radeon_device *rdev, stru= ct radeon_fence *fence) write_unlock_irqrestore(&rdev->fence_drv.lock, irq_flags); return 0; } @@ -27929,7 +28616,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/rad= eon_fence.c linux-3.1.4/drivers if (!rdev->cp.ready) /* FIXME: cp is not running assume everythings is done right * away -@@ -373,7 +373,7 @@ int radeon_fence_driver_init(struct rade +@@ -373,7 +373,7 @@ int radeon_fence_driver_init(struct radeon_device *r= dev) return r; } radeon_fence_write(rdev, 0); @@ -27938,31 +28625,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_fence.c linux-3.1.4/drivers INIT_LIST_HEAD(&rdev->fence_drv.created); INIT_LIST_HEAD(&rdev->fence_drv.emited); INIT_LIST_HEAD(&rdev->fence_drv.signaled); -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon.h linux-3.1.4/drive= rs/gpu/drm/radeon/radeon.h ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon.h 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -192,7 +192,7 @@ extern int sumo_get_temp(struct radeon_d - */ - struct radeon_fence_driver { - uint32_t scratch_reg; -- atomic_t seq; -+ atomic_unchecked_t seq; - uint32_t last_seq; - unsigned long last_jiffies; - unsigned long last_timeout; -@@ -962,7 +962,7 @@ struct radeon_asic { - void (*pre_page_flip)(struct radeon_device *rdev, int crtc); - u32 (*page_flip)(struct radeon_device *rdev, int crtc, u64 crtc_base); - void (*post_page_flip)(struct radeon_device *rdev, int crtc); --}; -+} __no_const; -=20 - /* - * Asic structures -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_ioc32.c linux-3.1.4= /drivers/gpu/drm/radeon/radeon_ioc32.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_ioc32.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_ioc32.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -359,7 +359,7 @@ static int compat_radeon_cp_setparam(str +diff --git a/drivers/gpu/drm/radeon/radeon_ioc32.c b/drivers/gpu/drm/rad= eon/radeon_ioc32.c +index 48b7cea..342236f 100644 +--- a/drivers/gpu/drm/radeon/radeon_ioc32.c ++++ b/drivers/gpu/drm/radeon/radeon_ioc32.c +@@ -359,7 +359,7 @@ static int compat_radeon_cp_setparam(struct file *fi= le, unsigned int cmd, request =3D compat_alloc_user_space(sizeof(*request)); if (!access_ok(VERIFY_WRITE, request, sizeof(*request)) || __put_user(req32.param, &request->param) @@ -27971,10 +28638,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_ioc32.c linux-3.1.4/drivers &request->value)) return -EFAULT; =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_irq.c linux-3.1.4/d= rivers/gpu/drm/radeon/radeon_irq.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_irq.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_irq.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -225,8 +225,8 @@ static int radeon_emit_irq(struct drm_de +diff --git a/drivers/gpu/drm/radeon/radeon_irq.c b/drivers/gpu/drm/radeo= n/radeon_irq.c +index 465746b..cb2b055 100644 +--- a/drivers/gpu/drm/radeon/radeon_irq.c ++++ b/drivers/gpu/drm/radeon/radeon_irq.c +@@ -225,8 +225,8 @@ static int radeon_emit_irq(struct drm_device * dev) unsigned int ret; RING_LOCALS; =20 @@ -27985,7 +28653,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/rad= eon_irq.c linux-3.1.4/drivers/g =20 BEGIN_RING(4); OUT_RING_REG(RADEON_LAST_SWI_REG, ret); -@@ -352,7 +352,7 @@ int radeon_driver_irq_postinstall(struct +@@ -352,7 +352,7 @@ int radeon_driver_irq_postinstall(struct drm_device = *dev) drm_radeon_private_t *dev_priv =3D (drm_radeon_private_t *) dev->dev_private; =20 @@ -27994,10 +28662,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_irq.c linux-3.1.4/drivers/g DRM_INIT_WAITQUEUE(&dev_priv->swi_queue); =20 dev->max_vblank_count =3D 0x001fffff; -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_state.c linux-3.1.4= /drivers/gpu/drm/radeon/radeon_state.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_state.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_state.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -2168,7 +2168,7 @@ static int radeon_cp_clear(struct drm_de +diff --git a/drivers/gpu/drm/radeon/radeon_state.c b/drivers/gpu/drm/rad= eon/radeon_state.c +index 92e7ea7..147ffad 100644 +--- a/drivers/gpu/drm/radeon/radeon_state.c ++++ b/drivers/gpu/drm/radeon/radeon_state.c +@@ -2168,7 +2168,7 @@ static int radeon_cp_clear(struct drm_device *dev,= void *data, struct drm_file * if (sarea_priv->nbox > RADEON_NR_SAREA_CLIPRECTS) sarea_priv->nbox =3D RADEON_NR_SAREA_CLIPRECTS; =20 @@ -28006,7 +28675,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/rad= eon_state.c linux-3.1.4/drivers sarea_priv->nbox * sizeof(depth_boxes[0]))) return -EFAULT; =20 -@@ -3031,7 +3031,7 @@ static int radeon_cp_getparam(struct drm +@@ -3031,7 +3031,7 @@ static int radeon_cp_getparam(struct drm_device *d= ev, void *data, struct drm_fil { drm_radeon_private_t *dev_priv =3D dev->dev_private; drm_radeon_getparam_t *param =3D data; @@ -28015,10 +28684,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_state.c linux-3.1.4/drivers =20 DRM_DEBUG("pid=3D%d\n", DRM_CURRENTPID); =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/radeon_ttm.c linux-3.1.4/d= rivers/gpu/drm/radeon/radeon_ttm.c ---- linux-3.1.4/drivers/gpu/drm/radeon/radeon_ttm.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/radeon_ttm.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -672,8 +672,10 @@ int radeon_mmap(struct file *filp, struc +diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeo= n/radeon_ttm.c +index 0b5468b..9c4b308 100644 +--- a/drivers/gpu/drm/radeon/radeon_ttm.c ++++ b/drivers/gpu/drm/radeon/radeon_ttm.c +@@ -672,8 +672,10 @@ int radeon_mmap(struct file *filp, struct vm_area_s= truct *vma) } if (unlikely(ttm_vm_ops =3D=3D NULL)) { ttm_vm_ops =3D vma->vm_ops; @@ -28031,10 +28701,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= adeon_ttm.c linux-3.1.4/drivers/g } vma->vm_ops =3D &radeon_ttm_vm_ops; return 0; -diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/rs690.c linux-3.1.4/driver= s/gpu/drm/radeon/rs690.c ---- linux-3.1.4/drivers/gpu/drm/radeon/rs690.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/radeon/rs690.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -304,9 +304,11 @@ void rs690_crtc_bandwidth_compute(struct +diff --git a/drivers/gpu/drm/radeon/rs690.c b/drivers/gpu/drm/radeon/rs6= 90.c +index a9049ed..501f284 100644 +--- a/drivers/gpu/drm/radeon/rs690.c ++++ b/drivers/gpu/drm/radeon/rs690.c +@@ -304,9 +304,11 @@ void rs690_crtc_bandwidth_compute(struct radeon_dev= ice *rdev, if (rdev->pm.max_bandwidth.full > rdev->pm.sideport_bandwidth.full && rdev->pm.sideport_bandwidth.full) rdev->pm.max_bandwidth =3D rdev->pm.sideport_bandwidth; @@ -28047,10 +28718,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/radeon/r= s690.c linux-3.1.4/drivers/gpu/dr } else { if (rdev->pm.max_bandwidth.full > rdev->pm.k8_bandwidth.full && rdev->pm.k8_bandwidth.full) -diff -urNp linux-3.1.4/drivers/gpu/drm/ttm/ttm_page_alloc.c linux-3.1.4/= drivers/gpu/drm/ttm/ttm_page_alloc.c ---- linux-3.1.4/drivers/gpu/drm/ttm/ttm_page_alloc.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/ttm/ttm_page_alloc.c 2011-11-16 18:39:07= .000000000 -0500 -@@ -398,9 +398,9 @@ static int ttm_pool_get_num_unused_pages +diff --git a/drivers/gpu/drm/ttm/ttm_page_alloc.c b/drivers/gpu/drm/ttm/= ttm_page_alloc.c +index 727e93d..1565650 100644 +--- a/drivers/gpu/drm/ttm/ttm_page_alloc.c ++++ b/drivers/gpu/drm/ttm/ttm_page_alloc.c +@@ -398,9 +398,9 @@ static int ttm_pool_get_num_unused_pages(void) static int ttm_pool_mm_shrink(struct shrinker *shrink, struct shrink_control *sc) { @@ -28062,9 +28734,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/ttm/ttm_p= age_alloc.c linux-3.1.4/drivers/ struct ttm_page_pool *pool; int shrink_pages =3D sc->nr_to_scan; =20 -diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_drv.h linux-3.1.4/drivers= /gpu/drm/via/via_drv.h ---- linux-3.1.4/drivers/gpu/drm/via/via_drv.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/via/via_drv.h 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/drivers/gpu/drm/via/via_drv.h b/drivers/gpu/drm/via/via_drv= .h +index 9cf87d9..2000b7d 100644 +--- a/drivers/gpu/drm/via/via_drv.h ++++ b/drivers/gpu/drm/via/via_drv.h @@ -51,7 +51,7 @@ typedef struct drm_via_ring_buffer { typedef uint32_t maskarray_t[5]; =20 @@ -28083,10 +28756,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_= drv.h linux-3.1.4/drivers/gpu/drm drm_via_state_t hc_state; char pci_buf[VIA_PCI_BUF_SIZE]; const uint32_t *fire_offsets[VIA_FIRE_BUF_SIZE]; -diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_irq.c linux-3.1.4/drivers= /gpu/drm/via/via_irq.c ---- linux-3.1.4/drivers/gpu/drm/via/via_irq.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/via/via_irq.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -102,7 +102,7 @@ u32 via_get_vblank_counter(struct drm_de +diff --git a/drivers/gpu/drm/via/via_irq.c b/drivers/gpu/drm/via/via_irq= .c +index d391f48..10c8ca3 100644 +--- a/drivers/gpu/drm/via/via_irq.c ++++ b/drivers/gpu/drm/via/via_irq.c +@@ -102,7 +102,7 @@ u32 via_get_vblank_counter(struct drm_device *dev, i= nt crtc) if (crtc !=3D 0) return 0; =20 @@ -28095,7 +28769,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_ir= q.c linux-3.1.4/drivers/gpu/drm } =20 irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) -@@ -117,8 +117,8 @@ irqreturn_t via_driver_irq_handler(DRM_I +@@ -117,8 +117,8 @@ irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) =20 status =3D VIA_READ(VIA_REG_INTERRUPT); if (status & VIA_IRQ_VBLANK_PENDING) { @@ -28106,7 +28780,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_ir= q.c linux-3.1.4/drivers/gpu/drm do_gettimeofday(&cur_vblank); if (dev_priv->last_vblank_valid) { dev_priv->usec_per_vblank =3D -@@ -128,7 +128,7 @@ irqreturn_t via_driver_irq_handler(DRM_I +@@ -128,7 +128,7 @@ irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) dev_priv->last_vblank =3D cur_vblank; dev_priv->last_vblank_valid =3D 1; } @@ -28115,7 +28789,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_ir= q.c linux-3.1.4/drivers/gpu/drm DRM_DEBUG("US per vblank is: %u\n", dev_priv->usec_per_vblank); } -@@ -138,7 +138,7 @@ irqreturn_t via_driver_irq_handler(DRM_I +@@ -138,7 +138,7 @@ irqreturn_t via_driver_irq_handler(DRM_IRQ_ARGS) =20 for (i =3D 0; i < dev_priv->num_irqs; ++i) { if (status & cur_irq->pending_mask) { @@ -28124,7 +28798,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_ir= q.c linux-3.1.4/drivers/gpu/drm DRM_WAKEUP(&cur_irq->irq_queue); handled =3D 1; if (dev_priv->irq_map[drm_via_irq_dma0_td] =3D=3D i) -@@ -243,11 +243,11 @@ via_driver_irq_wait(struct drm_device *d +@@ -243,11 +243,11 @@ via_driver_irq_wait(struct drm_device *dev, unsign= ed int irq, int force_sequence DRM_WAIT_ON(ret, cur_irq->irq_queue, 3 * DRM_HZ, ((VIA_READ(masks[irq][2]) & masks[irq][3]) =3D=3D masks[irq][4])); @@ -28138,7 +28812,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_ir= q.c linux-3.1.4/drivers/gpu/drm *sequence) <=3D (1 << 23))); } *sequence =3D cur_irq_sequence; -@@ -285,7 +285,7 @@ void via_driver_irq_preinstall(struct dr +@@ -285,7 +285,7 @@ void via_driver_irq_preinstall(struct drm_device *de= v) } =20 for (i =3D 0; i < dev_priv->num_irqs; ++i) { @@ -28147,7 +28821,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_ir= q.c linux-3.1.4/drivers/gpu/drm cur_irq->enable_mask =3D dev_priv->irq_masks[i][0]; cur_irq->pending_mask =3D dev_priv->irq_masks[i][1]; DRM_INIT_WAITQUEUE(&cur_irq->irq_queue); -@@ -367,7 +367,7 @@ int via_wait_irq(struct drm_device *dev, +@@ -367,7 +367,7 @@ int via_wait_irq(struct drm_device *dev, void *data,= struct drm_file *file_priv) switch (irqwait->request.type & ~VIA_IRQ_FLAGS_MASK) { case VIA_IRQ_RELATIVE: irqwait->request.sequence +=3D @@ -28156,9 +28830,10 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/via/via_i= rq.c linux-3.1.4/drivers/gpu/drm irqwait->request.type &=3D ~_DRM_VBLANK_RELATIVE; case VIA_IRQ_ABSOLUTE: break; -diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h linux-3.1.4/d= rivers/gpu/drm/vmwgfx/vmwgfx_drv.h ---- linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h b/drivers/gpu/drm/vmwgf= x/vmwgfx_drv.h +index 10fc01f..b4e9822 100644 +--- a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h ++++ b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h @@ -240,7 +240,7 @@ struct vmw_private { * Fencing and IRQs. */ @@ -28168,10 +28843,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/v= mwgfx_drv.h linux-3.1.4/drivers/g wait_queue_head_t fence_queue; wait_queue_head_t fifo_queue; atomic_t fence_queue_waiters; -diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c linux-3.1= .4/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c ---- linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c 2011-11-16 18:39= :07.000000000 -0500 -@@ -610,7 +610,7 @@ int vmw_execbuf_ioctl(struct drm_device=20 +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c b/drivers/gpu/drm/v= mwgfx/vmwgfx_execbuf.c +index 41b95ed..69ea504 100644 +--- a/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c ++++ b/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c +@@ -610,7 +610,7 @@ int vmw_execbuf_ioctl(struct drm_device *dev, void *= data, struct drm_vmw_fence_rep fence_rep; struct drm_vmw_fence_rep __user *user_fence_rep; int ret; @@ -28180,10 +28856,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/v= mwgfx_execbuf.c linux-3.1.4/drive void *cmd; uint32_t sequence; struct vmw_sw_context *sw_context =3D &dev_priv->ctx; -diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c linux-3.1.4= /drivers/gpu/drm/vmwgfx/vmwgfx_fence.c ---- linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -151,7 +151,7 @@ int vmw_wait_lag(struct vmw_private *dev +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c b/drivers/gpu/drm/vmw= gfx/vmwgfx_fence.c +index 61eacc1..ee38ce8 100644 +--- a/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c ++++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c +@@ -151,7 +151,7 @@ int vmw_wait_lag(struct vmw_private *dev_priv, while (!vmw_lag_lt(queue, us)) { spin_lock(&queue->lock); if (list_empty(&queue->head)) @@ -28192,10 +28869,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/v= mwgfx_fence.c linux-3.1.4/drivers else { fence =3D list_first_entry(&queue->head, struct vmw_fence, head); -diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c linux-3.1.4/= drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c ---- linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c 2011-11-16 18:39:07= .000000000 -0500 -@@ -137,7 +137,7 @@ int vmw_fifo_init(struct vmw_private *de +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c b/drivers/gpu/drm/vmwg= fx/vmwgfx_fifo.c +index 635c0ff..2641bbb 100644 +--- a/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c ++++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c +@@ -137,7 +137,7 @@ int vmw_fifo_init(struct vmw_private *dev_priv, stru= ct vmw_fifo_state *fifo) (unsigned int) min, (unsigned int) fifo->capabilities); =20 @@ -28204,7 +28882,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmw= gfx_fifo.c linux-3.1.4/drivers/ iowrite32(dev_priv->last_read_sequence, fifo_mem + SVGA_FIFO_FENCE); vmw_fence_queue_init(&fifo->fence_queue); return vmw_fifo_send_fence(dev_priv, &dummy); -@@ -356,7 +356,7 @@ void *vmw_fifo_reserve(struct vmw_privat +@@ -356,7 +356,7 @@ void *vmw_fifo_reserve(struct vmw_private *dev_priv,= uint32_t bytes) if (reserveable) iowrite32(bytes, fifo_mem + SVGA_FIFO_RESERVED); @@ -28213,7 +28891,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmw= gfx_fifo.c linux-3.1.4/drivers/ } else { need_bounce =3D true; } -@@ -476,7 +476,7 @@ int vmw_fifo_send_fence(struct vmw_priva +@@ -476,7 +476,7 @@ int vmw_fifo_send_fence(struct vmw_private *dev_priv= , uint32_t *sequence) =20 fm =3D vmw_fifo_reserve(dev_priv, bytes); if (unlikely(fm =3D=3D NULL)) { @@ -28222,7 +28900,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmw= gfx_fifo.c linux-3.1.4/drivers/ ret =3D -ENOMEM; (void)vmw_fallback_wait(dev_priv, false, true, *sequence, false, 3*HZ); -@@ -484,7 +484,7 @@ int vmw_fifo_send_fence(struct vmw_priva +@@ -484,7 +484,7 @@ int vmw_fifo_send_fence(struct vmw_private *dev_priv= , uint32_t *sequence) } =20 do { @@ -28231,10 +28909,11 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/v= mwgfx_fifo.c linux-3.1.4/drivers/ } while (*sequence =3D=3D 0); =20 if (!(fifo_state->capabilities & SVGA_FIFO_CAP_FENCE)) { -diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c linux-3.1.4/d= rivers/gpu/drm/vmwgfx/vmwgfx_irq.c ---- linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -100,7 +100,7 @@ bool vmw_fence_signaled(struct vmw_priva +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c b/drivers/gpu/drm/vmwgf= x/vmwgfx_irq.c +index e92298a..f68f2d6 100644 +--- a/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c ++++ b/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c +@@ -100,7 +100,7 @@ bool vmw_fence_signaled(struct vmw_private *dev_priv= , * emitted. Then the fence is stale and signaled. */ =20 @@ -28243,7 +28922,7 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/vmw= gfx_irq.c linux-3.1.4/drivers/g > VMW_FENCE_WRAP); =20 return ret; -@@ -131,7 +131,7 @@ int vmw_fallback_wait(struct vmw_private +@@ -131,7 +131,7 @@ int vmw_fallback_wait(struct vmw_private *dev_priv, =20 if (fifo_idle) down_read(&fifo_state->rwsem); @@ -28252,10 +28931,42 @@ diff -urNp linux-3.1.4/drivers/gpu/drm/vmwgfx/v= mwgfx_irq.c linux-3.1.4/drivers/g ret =3D 0; =20 for (;;) { -diff -urNp linux-3.1.4/drivers/hid/hid-core.c linux-3.1.4/drivers/hid/hi= d-core.c ---- linux-3.1.4/drivers/hid/hid-core.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/hid/hid-core.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -1951,7 +1951,7 @@ static bool hid_ignore(struct hid_device +diff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c +index c72f1c0..18376f1 100644 +--- a/drivers/gpu/vga/vgaarb.c ++++ b/drivers/gpu/vga/vgaarb.c +@@ -993,14 +993,20 @@ static ssize_t vga_arb_write(struct file *file, co= nst char __user * buf, + uc =3D &priv->cards[i]; + } +=20 +- if (!uc) +- return -EINVAL; ++ if (!uc) { ++ ret_val =3D -EINVAL; ++ goto done; ++ } +=20 +- if (io_state & VGA_RSRC_LEGACY_IO && uc->io_cnt =3D=3D 0) +- return -EINVAL; ++ if (io_state & VGA_RSRC_LEGACY_IO && uc->io_cnt =3D=3D 0) { ++ ret_val =3D -EINVAL; ++ goto done; ++ } +=20 +- if (io_state & VGA_RSRC_LEGACY_MEM && uc->mem_cnt =3D=3D 0) +- return -EINVAL; ++ if (io_state & VGA_RSRC_LEGACY_MEM && uc->mem_cnt =3D=3D 0) { ++ ret_val =3D -EINVAL; ++ goto done; ++ } +=20 + vga_put(pdev, io_state); +=20 +diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c +index 5be9f47..aa81d42 100644 +--- a/drivers/hid/hid-core.c ++++ b/drivers/hid/hid-core.c +@@ -1951,7 +1951,7 @@ static bool hid_ignore(struct hid_device *hdev) =20 int hid_add_device(struct hid_device *hdev) { @@ -28264,7 +28975,7 @@ diff -urNp linux-3.1.4/drivers/hid/hid-core.c lin= ux-3.1.4/drivers/hid/hid-core.c int ret; =20 if (WARN_ON(hdev->status & HID_STAT_ADDED)) -@@ -1966,7 +1966,7 @@ int hid_add_device(struct hid_device *hd +@@ -1966,7 +1966,7 @@ int hid_add_device(struct hid_device *hdev) /* XXX hack, any other cleaner solution after the driver core * is converted to allow more than 20 bytes as the device name? */ dev_set_name(&hdev->dev, "%04X:%04X:%04X.%04X", hdev->bus, @@ -28273,10 +28984,11 @@ diff -urNp linux-3.1.4/drivers/hid/hid-core.c l= inux-3.1.4/drivers/hid/hid-core.c =20 hid_debug_register(hdev, dev_name(&hdev->dev)); ret =3D device_add(&hdev->dev); -diff -urNp linux-3.1.4/drivers/hid/usbhid/hiddev.c linux-3.1.4/drivers/h= id/usbhid/hiddev.c ---- linux-3.1.4/drivers/hid/usbhid/hiddev.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/hid/usbhid/hiddev.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -624,7 +624,7 @@ static long hiddev_ioctl(struct file *fi +diff --git a/drivers/hid/usbhid/hiddev.c b/drivers/hid/usbhid/hiddev.c +index 7c1188b..5a64357 100644 +--- a/drivers/hid/usbhid/hiddev.c ++++ b/drivers/hid/usbhid/hiddev.c +@@ -624,7 +624,7 @@ static long hiddev_ioctl(struct file *file, unsigned= int cmd, unsigned long arg) break; =20 case HIDIOCAPPLICATION: @@ -28285,10 +28997,11 @@ diff -urNp linux-3.1.4/drivers/hid/usbhid/hidde= v.c linux-3.1.4/drivers/hid/usbhi break; =20 for (i =3D 0; i < hid->maxcollection; i++) -diff -urNp linux-3.1.4/drivers/hwmon/acpi_power_meter.c linux-3.1.4/driv= ers/hwmon/acpi_power_meter.c ---- linux-3.1.4/drivers/hwmon/acpi_power_meter.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/hwmon/acpi_power_meter.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -316,8 +316,6 @@ static ssize_t set_trip(struct device *d +diff --git a/drivers/hwmon/acpi_power_meter.c b/drivers/hwmon/acpi_power= _meter.c +index 66f6729..2d6de0a 100644 +--- a/drivers/hwmon/acpi_power_meter.c ++++ b/drivers/hwmon/acpi_power_meter.c +@@ -316,8 +316,6 @@ static ssize_t set_trip(struct device *dev, struct d= evice_attribute *devattr, return res; =20 temp /=3D 1000; @@ -28297,9 +29010,10 @@ diff -urNp linux-3.1.4/drivers/hwmon/acpi_power_= meter.c linux-3.1.4/drivers/hwmo =20 mutex_lock(&resource->lock); resource->trip[attr->index - 7] =3D temp; -diff -urNp linux-3.1.4/drivers/hwmon/sht15.c linux-3.1.4/drivers/hwmon/s= ht15.c ---- linux-3.1.4/drivers/hwmon/sht15.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/hwmon/sht15.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/hwmon/sht15.c b/drivers/hwmon/sht15.c +index fe4104c..346febb 100644 +--- a/drivers/hwmon/sht15.c ++++ b/drivers/hwmon/sht15.c @@ -166,7 +166,7 @@ struct sht15_data { int supply_uV; bool supply_uV_valid; @@ -28309,7 +29023,7 @@ diff -urNp linux-3.1.4/drivers/hwmon/sht15.c linu= x-3.1.4/drivers/hwmon/sht15.c }; =20 /** -@@ -509,13 +509,13 @@ static int sht15_measurement(struct sht1 +@@ -509,13 +509,13 @@ static int sht15_measurement(struct sht15_data *da= ta, return ret; =20 gpio_direction_input(data->pdata->gpio_data); @@ -28325,7 +29039,7 @@ diff -urNp linux-3.1.4/drivers/hwmon/sht15.c linu= x-3.1.4/drivers/hwmon/sht15.c schedule_work(&data->read_work); } ret =3D wait_event_timeout(data->wait_queue, -@@ -782,7 +782,7 @@ static irqreturn_t sht15_interrupt_fired +@@ -782,7 +782,7 @@ static irqreturn_t sht15_interrupt_fired(int irq, vo= id *d) =20 /* First disable the interrupt */ disable_irq_nosync(irq); @@ -28334,7 +29048,7 @@ diff -urNp linux-3.1.4/drivers/hwmon/sht15.c linu= x-3.1.4/drivers/hwmon/sht15.c /* Then schedule a reading work struct */ if (data->state !=3D SHT15_READING_NOTHING) schedule_work(&data->read_work); -@@ -804,11 +804,11 @@ static void sht15_bh_read_data(struct wo +@@ -804,11 +804,11 @@ static void sht15_bh_read_data(struct work_struct = *work_s) * If not, then start the interrupt again - care here as could * have gone low in meantime so verify it hasn't! */ @@ -28348,9 +29062,10 @@ diff -urNp linux-3.1.4/drivers/hwmon/sht15.c lin= ux-3.1.4/drivers/hwmon/sht15.c return; } =20 -diff -urNp linux-3.1.4/drivers/i2c/busses/i2c-amd756-s4882.c linux-3.1.4= /drivers/i2c/busses/i2c-amd756-s4882.c ---- linux-3.1.4/drivers/i2c/busses/i2c-amd756-s4882.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/i2c/busses/i2c-amd756-s4882.c 2011-11-16 18:39:0= 7.000000000 -0500 +diff --git a/drivers/i2c/busses/i2c-amd756-s4882.c b/drivers/i2c/busses/= i2c-amd756-s4882.c +index 378fcb5..5e91fa8 100644 +--- a/drivers/i2c/busses/i2c-amd756-s4882.c ++++ b/drivers/i2c/busses/i2c-amd756-s4882.c @@ -43,7 +43,7 @@ extern struct i2c_adapter amd756_smbus; =20 @@ -28360,9 +29075,10 @@ diff -urNp linux-3.1.4/drivers/i2c/busses/i2c-am= d756-s4882.c linux-3.1.4/drivers =20 /* Wrapper access functions for multiplexed SMBus */ static DEFINE_MUTEX(amd756_lock); -diff -urNp linux-3.1.4/drivers/i2c/busses/i2c-nforce2-s4985.c linux-3.1.= 4/drivers/i2c/busses/i2c-nforce2-s4985.c ---- linux-3.1.4/drivers/i2c/busses/i2c-nforce2-s4985.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/i2c/busses/i2c-nforce2-s4985.c 2011-11-16 18:39:= 07.000000000 -0500 +diff --git a/drivers/i2c/busses/i2c-nforce2-s4985.c b/drivers/i2c/busses= /i2c-nforce2-s4985.c +index 29015eb..af2d8e9 100644 +--- a/drivers/i2c/busses/i2c-nforce2-s4985.c ++++ b/drivers/i2c/busses/i2c-nforce2-s4985.c @@ -41,7 +41,7 @@ extern struct i2c_adapter *nforce2_smbus; =20 @@ -28372,9 +29088,10 @@ diff -urNp linux-3.1.4/drivers/i2c/busses/i2c-nf= orce2-s4985.c linux-3.1.4/driver =20 /* Wrapper access functions for multiplexed SMBus */ static DEFINE_MUTEX(nforce2_lock); -diff -urNp linux-3.1.4/drivers/i2c/i2c-mux.c linux-3.1.4/drivers/i2c/i2c= -mux.c ---- linux-3.1.4/drivers/i2c/i2c-mux.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/i2c/i2c-mux.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/i2c/i2c-mux.c b/drivers/i2c/i2c-mux.c +index d7a4833..7fae376 100644 +--- a/drivers/i2c/i2c-mux.c ++++ b/drivers/i2c/i2c-mux.c @@ -28,7 +28,7 @@ /* multiplexer per channel data */ struct i2c_mux_priv { @@ -28384,10 +29101,11 @@ diff -urNp linux-3.1.4/drivers/i2c/i2c-mux.c li= nux-3.1.4/drivers/i2c/i2c-mux.c =20 struct i2c_adapter *parent; void *mux_dev; /* the mux chip/device */ -diff -urNp linux-3.1.4/drivers/ide/aec62xx.c linux-3.1.4/drivers/ide/aec= 62xx.c ---- linux-3.1.4/drivers/ide/aec62xx.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/aec62xx.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -181,7 +181,7 @@ static const struct ide_port_ops atp86x_ +diff --git a/drivers/ide/aec62xx.c b/drivers/ide/aec62xx.c +index 57d00ca..0145194 100644 +--- a/drivers/ide/aec62xx.c ++++ b/drivers/ide/aec62xx.c +@@ -181,7 +181,7 @@ static const struct ide_port_ops atp86x_port_ops =3D= { .cable_detect =3D atp86x_cable_detect, }; =20 @@ -28396,10 +29114,11 @@ diff -urNp linux-3.1.4/drivers/ide/aec62xx.c li= nux-3.1.4/drivers/ide/aec62xx.c { /* 0: AEC6210 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_aec62xx, -diff -urNp linux-3.1.4/drivers/ide/alim15x3.c linux-3.1.4/drivers/ide/al= im15x3.c ---- linux-3.1.4/drivers/ide/alim15x3.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/ide/alim15x3.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -512,7 +512,7 @@ static const struct ide_dma_ops ali_dma_ +diff --git a/drivers/ide/alim15x3.c b/drivers/ide/alim15x3.c +index 2c8016a..911a27c 100644 +--- a/drivers/ide/alim15x3.c ++++ b/drivers/ide/alim15x3.c +@@ -512,7 +512,7 @@ static const struct ide_dma_ops ali_dma_ops =3D { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -28408,10 +29127,11 @@ diff -urNp linux-3.1.4/drivers/ide/alim15x3.c l= inux-3.1.4/drivers/ide/alim15x3.c .name =3D DRV_NAME, .init_chipset =3D init_chipset_ali15x3, .init_hwif =3D init_hwif_ali15x3, -diff -urNp linux-3.1.4/drivers/ide/amd74xx.c linux-3.1.4/drivers/ide/amd= 74xx.c ---- linux-3.1.4/drivers/ide/amd74xx.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/amd74xx.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -223,7 +223,7 @@ static const struct ide_port_ops amd_por +diff --git a/drivers/ide/amd74xx.c b/drivers/ide/amd74xx.c +index 3747b25..56fc995 100644 +--- a/drivers/ide/amd74xx.c ++++ b/drivers/ide/amd74xx.c +@@ -223,7 +223,7 @@ static const struct ide_port_ops amd_port_ops =3D { .udma_mask =3D udma, \ } =20 @@ -28420,10 +29140,11 @@ diff -urNp linux-3.1.4/drivers/ide/amd74xx.c li= nux-3.1.4/drivers/ide/amd74xx.c /* 0: AMD7401 */ DECLARE_AMD_DEV(0x00, ATA_UDMA2), /* 1: AMD7409 */ DECLARE_AMD_DEV(ATA_SWDMA2, ATA_UDMA4), /* 2: AMD7411/7441 */ DECLARE_AMD_DEV(ATA_SWDMA2, ATA_UDMA5), -diff -urNp linux-3.1.4/drivers/ide/atiixp.c linux-3.1.4/drivers/ide/atii= xp.c ---- linux-3.1.4/drivers/ide/atiixp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/atiixp.c 2011-11-16 18:39:07.000000000 -0500 -@@ -139,7 +139,7 @@ static const struct ide_port_ops atiixp_ +diff --git a/drivers/ide/atiixp.c b/drivers/ide/atiixp.c +index 15f0ead..cb43480 100644 +--- a/drivers/ide/atiixp.c ++++ b/drivers/ide/atiixp.c +@@ -139,7 +139,7 @@ static const struct ide_port_ops atiixp_port_ops =3D= { .cable_detect =3D atiixp_cable_detect, }; =20 @@ -28432,10 +29153,11 @@ diff -urNp linux-3.1.4/drivers/ide/atiixp.c lin= ux-3.1.4/drivers/ide/atiixp.c { /* 0: IXP200/300/400/700 */ .name =3D DRV_NAME, .enablebits =3D {{0x48,0x01,0x00}, {0x48,0x08,0x00}}, -diff -urNp linux-3.1.4/drivers/ide/cmd64x.c linux-3.1.4/drivers/ide/cmd6= 4x.c ---- linux-3.1.4/drivers/ide/cmd64x.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/cmd64x.c 2011-11-16 18:39:07.000000000 -0500 -@@ -327,7 +327,7 @@ static const struct ide_dma_ops cmd646_r +diff --git a/drivers/ide/cmd64x.c b/drivers/ide/cmd64x.c +index 5f80312..d1fc438 100644 +--- a/drivers/ide/cmd64x.c ++++ b/drivers/ide/cmd64x.c +@@ -327,7 +327,7 @@ static const struct ide_dma_ops cmd646_rev1_dma_ops = =3D { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -28444,10 +29166,11 @@ diff -urNp linux-3.1.4/drivers/ide/cmd64x.c lin= ux-3.1.4/drivers/ide/cmd64x.c { /* 0: CMD643 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_cmd64x, -diff -urNp linux-3.1.4/drivers/ide/cs5520.c linux-3.1.4/drivers/ide/cs55= 20.c ---- linux-3.1.4/drivers/ide/cs5520.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/cs5520.c 2011-11-16 18:39:07.000000000 -0500 -@@ -94,7 +94,7 @@ static const struct ide_port_ops cs5520_ +diff --git a/drivers/ide/cs5520.c b/drivers/ide/cs5520.c +index 2c1e5f7..1444762 100644 +--- a/drivers/ide/cs5520.c ++++ b/drivers/ide/cs5520.c +@@ -94,7 +94,7 @@ static const struct ide_port_ops cs5520_port_ops =3D { .set_dma_mode =3D cs5520_set_dma_mode, }; =20 @@ -28456,10 +29179,11 @@ diff -urNp linux-3.1.4/drivers/ide/cs5520.c lin= ux-3.1.4/drivers/ide/cs5520.c .name =3D DRV_NAME, .enablebits =3D { { 0x60, 0x01, 0x01 }, { 0x60, 0x02, 0x02 } }, .port_ops =3D &cs5520_port_ops, -diff -urNp linux-3.1.4/drivers/ide/cs5530.c linux-3.1.4/drivers/ide/cs55= 30.c ---- linux-3.1.4/drivers/ide/cs5530.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/cs5530.c 2011-11-16 18:39:07.000000000 -0500 -@@ -245,7 +245,7 @@ static const struct ide_port_ops cs5530_ +diff --git a/drivers/ide/cs5530.c b/drivers/ide/cs5530.c +index 4dc4eb9..49b40ad 100644 +--- a/drivers/ide/cs5530.c ++++ b/drivers/ide/cs5530.c +@@ -245,7 +245,7 @@ static const struct ide_port_ops cs5530_port_ops =3D= { .udma_filter =3D cs5530_udma_filter, }; =20 @@ -28468,10 +29192,11 @@ diff -urNp linux-3.1.4/drivers/ide/cs5530.c lin= ux-3.1.4/drivers/ide/cs5530.c .name =3D DRV_NAME, .init_chipset =3D init_chipset_cs5530, .init_hwif =3D init_hwif_cs5530, -diff -urNp linux-3.1.4/drivers/ide/cs5535.c linux-3.1.4/drivers/ide/cs55= 35.c ---- linux-3.1.4/drivers/ide/cs5535.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/cs5535.c 2011-11-16 18:39:07.000000000 -0500 -@@ -170,7 +170,7 @@ static const struct ide_port_ops cs5535_ +diff --git a/drivers/ide/cs5535.c b/drivers/ide/cs5535.c +index 5059faf..18d4c85 100644 +--- a/drivers/ide/cs5535.c ++++ b/drivers/ide/cs5535.c +@@ -170,7 +170,7 @@ static const struct ide_port_ops cs5535_port_ops =3D= { .cable_detect =3D cs5535_cable_detect, }; =20 @@ -28480,10 +29205,11 @@ diff -urNp linux-3.1.4/drivers/ide/cs5535.c lin= ux-3.1.4/drivers/ide/cs5535.c .name =3D DRV_NAME, .port_ops =3D &cs5535_port_ops, .host_flags =3D IDE_HFLAG_SINGLE | IDE_HFLAG_POST_SET_MODE, -diff -urNp linux-3.1.4/drivers/ide/cy82c693.c linux-3.1.4/drivers/ide/cy= 82c693.c ---- linux-3.1.4/drivers/ide/cy82c693.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/ide/cy82c693.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -163,7 +163,7 @@ static const struct ide_port_ops cy82c69 +diff --git a/drivers/ide/cy82c693.c b/drivers/ide/cy82c693.c +index 67cbcfa..37ea151 100644 +--- a/drivers/ide/cy82c693.c ++++ b/drivers/ide/cy82c693.c +@@ -163,7 +163,7 @@ static const struct ide_port_ops cy82c693_port_ops =3D= { .set_dma_mode =3D cy82c693_set_dma_mode, }; =20 @@ -28492,10 +29218,11 @@ diff -urNp linux-3.1.4/drivers/ide/cy82c693.c l= inux-3.1.4/drivers/ide/cy82c693.c .name =3D DRV_NAME, .init_iops =3D init_iops_cy82c693, .port_ops =3D &cy82c693_port_ops, -diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux-3.1.4/drivers/ide/hpt3= 66.c ---- linux-3.1.4/drivers/ide/hpt366.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/hpt366.c 2011-11-16 18:39:07.000000000 -0500 -@@ -443,7 +443,7 @@ static struct hpt_timings hpt37x_timings +diff --git a/drivers/ide/hpt366.c b/drivers/ide/hpt366.c +index 58c51cd..4aec3b8 100644 +--- a/drivers/ide/hpt366.c ++++ b/drivers/ide/hpt366.c +@@ -443,7 +443,7 @@ static struct hpt_timings hpt37x_timings =3D { } }; =20 @@ -28504,7 +29231,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT36x", .chip_type =3D HPT36x, .udma_mask =3D HPT366_ALLOW_ATA66_3 ? (HPT366_ALLOW_ATA66_4 ? ATA_UDMA= 4 : ATA_UDMA3) : ATA_UDMA2, -@@ -451,7 +451,7 @@ static const struct hpt_info hpt36x __de +@@ -451,7 +451,7 @@ static const struct hpt_info hpt36x __devinitdata =3D= { .timings =3D &hpt36x_timings }; =20 @@ -28513,7 +29240,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT370", .chip_type =3D HPT370, .udma_mask =3D HPT370_ALLOW_ATA100_5 ? ATA_UDMA5 : ATA_UDMA4, -@@ -459,7 +459,7 @@ static const struct hpt_info hpt370 __de +@@ -459,7 +459,7 @@ static const struct hpt_info hpt370 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28522,7 +29249,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT370A", .chip_type =3D HPT370A, .udma_mask =3D HPT370_ALLOW_ATA100_5 ? ATA_UDMA5 : ATA_UDMA4, -@@ -467,7 +467,7 @@ static const struct hpt_info hpt370a __d +@@ -467,7 +467,7 @@ static const struct hpt_info hpt370a __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28531,7 +29258,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT374", .chip_type =3D HPT374, .udma_mask =3D ATA_UDMA5, -@@ -475,7 +475,7 @@ static const struct hpt_info hpt374 __de +@@ -475,7 +475,7 @@ static const struct hpt_info hpt374 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28540,7 +29267,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT372", .chip_type =3D HPT372, .udma_mask =3D HPT372_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -483,7 +483,7 @@ static const struct hpt_info hpt372 __de +@@ -483,7 +483,7 @@ static const struct hpt_info hpt372 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28549,7 +29276,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT372A", .chip_type =3D HPT372A, .udma_mask =3D HPT372_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -491,7 +491,7 @@ static const struct hpt_info hpt372a __d +@@ -491,7 +491,7 @@ static const struct hpt_info hpt372a __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28558,7 +29285,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT302", .chip_type =3D HPT302, .udma_mask =3D HPT302_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -499,7 +499,7 @@ static const struct hpt_info hpt302 __de +@@ -499,7 +499,7 @@ static const struct hpt_info hpt302 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28567,7 +29294,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT371", .chip_type =3D HPT371, .udma_mask =3D HPT371_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -507,7 +507,7 @@ static const struct hpt_info hpt371 __de +@@ -507,7 +507,7 @@ static const struct hpt_info hpt371 __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28576,7 +29303,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT372N", .chip_type =3D HPT372N, .udma_mask =3D HPT372_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -515,7 +515,7 @@ static const struct hpt_info hpt372n __d +@@ -515,7 +515,7 @@ static const struct hpt_info hpt372n __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28585,7 +29312,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT302N", .chip_type =3D HPT302N, .udma_mask =3D HPT302_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -523,7 +523,7 @@ static const struct hpt_info hpt302n __d +@@ -523,7 +523,7 @@ static const struct hpt_info hpt302n __devinitdata =3D= { .timings =3D &hpt37x_timings }; =20 @@ -28594,7 +29321,7 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c linux= -3.1.4/drivers/ide/hpt366.c .chip_name =3D "HPT371N", .chip_type =3D HPT371N, .udma_mask =3D HPT371_ALLOW_ATA133_6 ? ATA_UDMA6 : ATA_UDMA5, -@@ -1361,7 +1361,7 @@ static const struct ide_dma_ops hpt36x_d +@@ -1361,7 +1361,7 @@ static const struct ide_dma_ops hpt36x_dma_ops =3D= { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -28603,10 +29330,11 @@ diff -urNp linux-3.1.4/drivers/ide/hpt366.c lin= ux-3.1.4/drivers/ide/hpt366.c { /* 0: HPT36x */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_hpt366, -diff -urNp linux-3.1.4/drivers/ide/ide-cd.c linux-3.1.4/drivers/ide/ide-= cd.c ---- linux-3.1.4/drivers/ide/ide-cd.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/ide-cd.c 2011-11-16 18:39:07.000000000 -0500 -@@ -769,7 +769,7 @@ static void cdrom_do_block_pc(ide_drive_ +diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c +index 04b0956..f5b47dc 100644 +--- a/drivers/ide/ide-cd.c ++++ b/drivers/ide/ide-cd.c +@@ -769,7 +769,7 @@ static void cdrom_do_block_pc(ide_drive_t *drive, st= ruct request *rq) alignment =3D queue_dma_alignment(q) | q->dma_pad_mask; if ((unsigned long)buf & alignment || blk_rq_bytes(rq) & q->dma_pad_mask @@ -28615,10 +29343,11 @@ diff -urNp linux-3.1.4/drivers/ide/ide-cd.c lin= ux-3.1.4/drivers/ide/ide-cd.c drive->dma =3D 0; } } -diff -urNp linux-3.1.4/drivers/ide/ide-floppy.c linux-3.1.4/drivers/ide/= ide-floppy.c ---- linux-3.1.4/drivers/ide/ide-floppy.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/ide/ide-floppy.c 2011-11-16 18:40:10.000000000 -= 0500 -@@ -379,6 +379,8 @@ static int ide_floppy_get_capacity(ide_d +diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c +index 61fdf54..2834ea6 100644 +--- a/drivers/ide/ide-floppy.c ++++ b/drivers/ide/ide-floppy.c +@@ -379,6 +379,8 @@ static int ide_floppy_get_capacity(ide_drive_t *driv= e) u8 pc_buf[256], header_len, desc_cnt; int i, rc =3D 1, blocks, length; =20 @@ -28627,10 +29356,11 @@ diff -urNp linux-3.1.4/drivers/ide/ide-floppy.c= linux-3.1.4/drivers/ide/ide-flop ide_debug_log(IDE_DBG_FUNC, "enter"); =20 drive->bios_cyl =3D 0; -diff -urNp linux-3.1.4/drivers/ide/ide-pci-generic.c linux-3.1.4/drivers= /ide/ide-pci-generic.c ---- linux-3.1.4/drivers/ide/ide-pci-generic.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/ide/ide-pci-generic.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -53,7 +53,7 @@ static const struct ide_port_ops netcell +diff --git a/drivers/ide/ide-pci-generic.c b/drivers/ide/ide-pci-generic= .c +index a743e68..1cfd674 100644 +--- a/drivers/ide/ide-pci-generic.c ++++ b/drivers/ide/ide-pci-generic.c +@@ -53,7 +53,7 @@ static const struct ide_port_ops netcell_port_ops =3D = { .udma_mask =3D ATA_UDMA6, \ } =20 @@ -28639,10 +29369,11 @@ diff -urNp linux-3.1.4/drivers/ide/ide-pci-gene= ric.c linux-3.1.4/drivers/ide/ide /* 0: Unknown */ DECLARE_GENERIC_PCI_DEV(0), =20 -diff -urNp linux-3.1.4/drivers/ide/it8172.c linux-3.1.4/drivers/ide/it81= 72.c ---- linux-3.1.4/drivers/ide/it8172.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/it8172.c 2011-11-16 18:39:07.000000000 -0500 -@@ -115,7 +115,7 @@ static const struct ide_port_ops it8172_ +diff --git a/drivers/ide/it8172.c b/drivers/ide/it8172.c +index 560e66d..d5dd180 100644 +--- a/drivers/ide/it8172.c ++++ b/drivers/ide/it8172.c +@@ -115,7 +115,7 @@ static const struct ide_port_ops it8172_port_ops =3D= { .set_dma_mode =3D it8172_set_dma_mode, }; =20 @@ -28651,10 +29382,11 @@ diff -urNp linux-3.1.4/drivers/ide/it8172.c lin= ux-3.1.4/drivers/ide/it8172.c .name =3D DRV_NAME, .port_ops =3D &it8172_port_ops, .enablebits =3D { {0x41, 0x80, 0x80}, {0x00, 0x00, 0x00} }, -diff -urNp linux-3.1.4/drivers/ide/it8213.c linux-3.1.4/drivers/ide/it82= 13.c ---- linux-3.1.4/drivers/ide/it8213.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/it8213.c 2011-11-16 18:39:07.000000000 -0500 -@@ -156,7 +156,7 @@ static const struct ide_port_ops it8213_ +diff --git a/drivers/ide/it8213.c b/drivers/ide/it8213.c +index 46816ba..1847aeb 100644 +--- a/drivers/ide/it8213.c ++++ b/drivers/ide/it8213.c +@@ -156,7 +156,7 @@ static const struct ide_port_ops it8213_port_ops =3D= { .cable_detect =3D it8213_cable_detect, }; =20 @@ -28663,10 +29395,11 @@ diff -urNp linux-3.1.4/drivers/ide/it8213.c lin= ux-3.1.4/drivers/ide/it8213.c .name =3D DRV_NAME, .enablebits =3D { {0x41, 0x80, 0x80} }, .port_ops =3D &it8213_port_ops, -diff -urNp linux-3.1.4/drivers/ide/it821x.c linux-3.1.4/drivers/ide/it82= 1x.c ---- linux-3.1.4/drivers/ide/it821x.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/it821x.c 2011-11-16 18:39:07.000000000 -0500 -@@ -630,7 +630,7 @@ static const struct ide_port_ops it821x_ +diff --git a/drivers/ide/it821x.c b/drivers/ide/it821x.c +index 2e3169f..c5611db 100644 +--- a/drivers/ide/it821x.c ++++ b/drivers/ide/it821x.c +@@ -630,7 +630,7 @@ static const struct ide_port_ops it821x_port_ops =3D= { .cable_detect =3D it821x_cable_detect, }; =20 @@ -28675,10 +29408,11 @@ diff -urNp linux-3.1.4/drivers/ide/it821x.c lin= ux-3.1.4/drivers/ide/it821x.c .name =3D DRV_NAME, .init_chipset =3D init_chipset_it821x, .init_hwif =3D init_hwif_it821x, -diff -urNp linux-3.1.4/drivers/ide/jmicron.c linux-3.1.4/drivers/ide/jmi= cron.c ---- linux-3.1.4/drivers/ide/jmicron.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/jmicron.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -102,7 +102,7 @@ static const struct ide_port_ops jmicron +diff --git a/drivers/ide/jmicron.c b/drivers/ide/jmicron.c +index 74c2c4a..efddd7d 100644 +--- a/drivers/ide/jmicron.c ++++ b/drivers/ide/jmicron.c +@@ -102,7 +102,7 @@ static const struct ide_port_ops jmicron_port_ops =3D= { .cable_detect =3D jmicron_cable_detect, }; =20 @@ -28687,10 +29421,11 @@ diff -urNp linux-3.1.4/drivers/ide/jmicron.c li= nux-3.1.4/drivers/ide/jmicron.c .name =3D DRV_NAME, .enablebits =3D { { 0x40, 0x01, 0x01 }, { 0x40, 0x10, 0x10 } }, .port_ops =3D &jmicron_port_ops, -diff -urNp linux-3.1.4/drivers/ide/ns87415.c linux-3.1.4/drivers/ide/ns8= 7415.c ---- linux-3.1.4/drivers/ide/ns87415.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/ns87415.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -293,7 +293,7 @@ static const struct ide_dma_ops ns87415_ +diff --git a/drivers/ide/ns87415.c b/drivers/ide/ns87415.c +index 95327a2..73f78d8 100644 +--- a/drivers/ide/ns87415.c ++++ b/drivers/ide/ns87415.c +@@ -293,7 +293,7 @@ static const struct ide_dma_ops ns87415_dma_ops =3D = { .dma_sff_read_status =3D superio_dma_sff_read_status, }; =20 @@ -28699,10 +29434,11 @@ diff -urNp linux-3.1.4/drivers/ide/ns87415.c li= nux-3.1.4/drivers/ide/ns87415.c .name =3D DRV_NAME, .init_hwif =3D init_hwif_ns87415, .tp_ops =3D &ns87415_tp_ops, -diff -urNp linux-3.1.4/drivers/ide/opti621.c linux-3.1.4/drivers/ide/opt= i621.c ---- linux-3.1.4/drivers/ide/opti621.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/opti621.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -131,7 +131,7 @@ static const struct ide_port_ops opti621 +diff --git a/drivers/ide/opti621.c b/drivers/ide/opti621.c +index 1a53a4c..39edc66 100644 +--- a/drivers/ide/opti621.c ++++ b/drivers/ide/opti621.c +@@ -131,7 +131,7 @@ static const struct ide_port_ops opti621_port_ops =3D= { .set_pio_mode =3D opti621_set_pio_mode, }; =20 @@ -28711,10 +29447,11 @@ diff -urNp linux-3.1.4/drivers/ide/opti621.c li= nux-3.1.4/drivers/ide/opti621.c .name =3D DRV_NAME, .enablebits =3D { {0x45, 0x80, 0x00}, {0x40, 0x08, 0x00} }, .port_ops =3D &opti621_port_ops, -diff -urNp linux-3.1.4/drivers/ide/pdc202xx_new.c linux-3.1.4/drivers/id= e/pdc202xx_new.c ---- linux-3.1.4/drivers/ide/pdc202xx_new.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/ide/pdc202xx_new.c 2011-11-16 18:39:07.000000000= -0500 -@@ -465,7 +465,7 @@ static const struct ide_port_ops pdcnew_ +diff --git a/drivers/ide/pdc202xx_new.c b/drivers/ide/pdc202xx_new.c +index 9546fe2..2e5ceb6 100644 +--- a/drivers/ide/pdc202xx_new.c ++++ b/drivers/ide/pdc202xx_new.c +@@ -465,7 +465,7 @@ static const struct ide_port_ops pdcnew_port_ops =3D= { .udma_mask =3D udma, \ } =20 @@ -28723,10 +29460,11 @@ diff -urNp linux-3.1.4/drivers/ide/pdc202xx_new= .c linux-3.1.4/drivers/ide/pdc202 /* 0: PDC202{68,70} */ DECLARE_PDCNEW_DEV(ATA_UDMA5), /* 1: PDC202{69,71,75,76,77} */ DECLARE_PDCNEW_DEV(ATA_UDMA6), }; -diff -urNp linux-3.1.4/drivers/ide/pdc202xx_old.c linux-3.1.4/drivers/id= e/pdc202xx_old.c ---- linux-3.1.4/drivers/ide/pdc202xx_old.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/ide/pdc202xx_old.c 2011-11-16 18:39:07.000000000= -0500 -@@ -270,7 +270,7 @@ static const struct ide_dma_ops pdc2026x +diff --git a/drivers/ide/pdc202xx_old.c b/drivers/ide/pdc202xx_old.c +index 3a35ec6..5634510 100644 +--- a/drivers/ide/pdc202xx_old.c ++++ b/drivers/ide/pdc202xx_old.c +@@ -270,7 +270,7 @@ static const struct ide_dma_ops pdc2026x_dma_ops =3D= { .max_sectors =3D sectors, \ } =20 @@ -28735,10 +29473,11 @@ diff -urNp linux-3.1.4/drivers/ide/pdc202xx_old= .c linux-3.1.4/drivers/ide/pdc202 { /* 0: PDC20246 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_pdc202xx, -diff -urNp linux-3.1.4/drivers/ide/piix.c linux-3.1.4/drivers/ide/piix.c ---- linux-3.1.4/drivers/ide/piix.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/piix.c 2011-11-16 18:39:07.000000000 -0500 -@@ -344,7 +344,7 @@ static const struct ide_port_ops ich_por +diff --git a/drivers/ide/piix.c b/drivers/ide/piix.c +index b59d04c..368c2a7 100644 +--- a/drivers/ide/piix.c ++++ b/drivers/ide/piix.c +@@ -344,7 +344,7 @@ static const struct ide_port_ops ich_port_ops =3D { .udma_mask =3D udma, \ } =20 @@ -28747,10 +29486,11 @@ diff -urNp linux-3.1.4/drivers/ide/piix.c linux= -3.1.4/drivers/ide/piix.c /* 0: MPIIX */ { /* * MPIIX actually has only a single IDE channel mapped to -diff -urNp linux-3.1.4/drivers/ide/rz1000.c linux-3.1.4/drivers/ide/rz10= 00.c ---- linux-3.1.4/drivers/ide/rz1000.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/rz1000.c 2011-11-16 18:39:07.000000000 -0500 -@@ -38,7 +38,7 @@ static int __devinit rz1000_disable_read +diff --git a/drivers/ide/rz1000.c b/drivers/ide/rz1000.c +index a6414a8..c04173e 100644 +--- a/drivers/ide/rz1000.c ++++ b/drivers/ide/rz1000.c +@@ -38,7 +38,7 @@ static int __devinit rz1000_disable_readahead(struct p= ci_dev *dev) } } =20 @@ -28759,10 +29499,11 @@ diff -urNp linux-3.1.4/drivers/ide/rz1000.c lin= ux-3.1.4/drivers/ide/rz1000.c .name =3D DRV_NAME, .host_flags =3D IDE_HFLAG_NO_DMA, }; -diff -urNp linux-3.1.4/drivers/ide/sc1200.c linux-3.1.4/drivers/ide/sc12= 00.c ---- linux-3.1.4/drivers/ide/sc1200.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/sc1200.c 2011-11-16 18:39:07.000000000 -0500 -@@ -291,7 +291,7 @@ static const struct ide_dma_ops sc1200_d +diff --git a/drivers/ide/sc1200.c b/drivers/ide/sc1200.c +index 356b9b5..d4758eb 100644 +--- a/drivers/ide/sc1200.c ++++ b/drivers/ide/sc1200.c +@@ -291,7 +291,7 @@ static const struct ide_dma_ops sc1200_dma_ops =3D { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -28771,10 +29512,11 @@ diff -urNp linux-3.1.4/drivers/ide/sc1200.c lin= ux-3.1.4/drivers/ide/sc1200.c .name =3D DRV_NAME, .port_ops =3D &sc1200_port_ops, .dma_ops =3D &sc1200_dma_ops, -diff -urNp linux-3.1.4/drivers/ide/scc_pata.c linux-3.1.4/drivers/ide/sc= c_pata.c ---- linux-3.1.4/drivers/ide/scc_pata.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/ide/scc_pata.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -811,7 +811,7 @@ static const struct ide_dma_ops scc_dma_ +diff --git a/drivers/ide/scc_pata.c b/drivers/ide/scc_pata.c +index b7f5b0c..9701038 100644 +--- a/drivers/ide/scc_pata.c ++++ b/drivers/ide/scc_pata.c +@@ -811,7 +811,7 @@ static const struct ide_dma_ops scc_dma_ops =3D { .dma_sff_read_status =3D scc_dma_sff_read_status, }; =20 @@ -28783,10 +29525,11 @@ diff -urNp linux-3.1.4/drivers/ide/scc_pata.c l= inux-3.1.4/drivers/ide/scc_pata.c .name =3D "sccIDE", .init_iops =3D init_iops_scc, .init_dma =3D scc_init_dma, -diff -urNp linux-3.1.4/drivers/ide/serverworks.c linux-3.1.4/drivers/ide= /serverworks.c ---- linux-3.1.4/drivers/ide/serverworks.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/ide/serverworks.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -337,7 +337,7 @@ static const struct ide_port_ops svwks_p +diff --git a/drivers/ide/serverworks.c b/drivers/ide/serverworks.c +index 35fb8da..24d72ef 100644 +--- a/drivers/ide/serverworks.c ++++ b/drivers/ide/serverworks.c +@@ -337,7 +337,7 @@ static const struct ide_port_ops svwks_port_ops =3D = { .cable_detect =3D svwks_cable_detect, }; =20 @@ -28795,10 +29538,11 @@ diff -urNp linux-3.1.4/drivers/ide/serverworks.= c linux-3.1.4/drivers/ide/serverw { /* 0: OSB4 */ .name =3D DRV_NAME, .init_chipset =3D init_chipset_svwks, -diff -urNp linux-3.1.4/drivers/ide/setup-pci.c linux-3.1.4/drivers/ide/s= etup-pci.c ---- linux-3.1.4/drivers/ide/setup-pci.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/ide/setup-pci.c 2011-11-16 18:40:10.000000000 -0= 500 -@@ -542,6 +542,8 @@ int ide_pci_init_two(struct pci_dev *dev +diff --git a/drivers/ide/setup-pci.c b/drivers/ide/setup-pci.c +index ab3db61..afed580 100644 +--- a/drivers/ide/setup-pci.c ++++ b/drivers/ide/setup-pci.c +@@ -542,6 +542,8 @@ int ide_pci_init_two(struct pci_dev *dev1, struct pc= i_dev *dev2, int ret, i, n_ports =3D dev2 ? 4 : 2; struct ide_hw hw[4], *hws[] =3D { NULL, NULL, NULL, NULL }; =20 @@ -28807,10 +29551,11 @@ diff -urNp linux-3.1.4/drivers/ide/setup-pci.c = linux-3.1.4/drivers/ide/setup-pci for (i =3D 0; i < n_ports / 2; i++) { ret =3D ide_setup_pci_controller(pdev[i], d, !i); if (ret < 0) -diff -urNp linux-3.1.4/drivers/ide/siimage.c linux-3.1.4/drivers/ide/sii= mage.c ---- linux-3.1.4/drivers/ide/siimage.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/siimage.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -719,7 +719,7 @@ static const struct ide_dma_ops sil_dma_ +diff --git a/drivers/ide/siimage.c b/drivers/ide/siimage.c +index ddeda44..46f7e30 100644 +--- a/drivers/ide/siimage.c ++++ b/drivers/ide/siimage.c +@@ -719,7 +719,7 @@ static const struct ide_dma_ops sil_dma_ops =3D { .udma_mask =3D ATA_UDMA6, \ } =20 @@ -28819,10 +29564,11 @@ diff -urNp linux-3.1.4/drivers/ide/siimage.c li= nux-3.1.4/drivers/ide/siimage.c /* 0: SiI680 */ DECLARE_SII_DEV(&sil_pata_port_ops), /* 1: SiI3112 */ DECLARE_SII_DEV(&sil_sata_port_ops) }; -diff -urNp linux-3.1.4/drivers/ide/sis5513.c linux-3.1.4/drivers/ide/sis= 5513.c ---- linux-3.1.4/drivers/ide/sis5513.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/sis5513.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -563,7 +563,7 @@ static const struct ide_port_ops sis_ata +diff --git a/drivers/ide/sis5513.c b/drivers/ide/sis5513.c +index 4a00225..09e61b4 100644 +--- a/drivers/ide/sis5513.c ++++ b/drivers/ide/sis5513.c +@@ -563,7 +563,7 @@ static const struct ide_port_ops sis_ata133_port_ops= =3D { .cable_detect =3D sis_cable_detect, }; =20 @@ -28831,10 +29577,11 @@ diff -urNp linux-3.1.4/drivers/ide/sis5513.c li= nux-3.1.4/drivers/ide/sis5513.c .name =3D DRV_NAME, .init_chipset =3D init_chipset_sis5513, .enablebits =3D { {0x4a, 0x02, 0x02}, {0x4a, 0x04, 0x04} }, -diff -urNp linux-3.1.4/drivers/ide/sl82c105.c linux-3.1.4/drivers/ide/sl= 82c105.c ---- linux-3.1.4/drivers/ide/sl82c105.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/ide/sl82c105.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -299,7 +299,7 @@ static const struct ide_dma_ops sl82c105 +diff --git a/drivers/ide/sl82c105.c b/drivers/ide/sl82c105.c +index f21dc2a..d051cd2 100644 +--- a/drivers/ide/sl82c105.c ++++ b/drivers/ide/sl82c105.c +@@ -299,7 +299,7 @@ static const struct ide_dma_ops sl82c105_dma_ops =3D= { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -28843,10 +29590,11 @@ diff -urNp linux-3.1.4/drivers/ide/sl82c105.c l= inux-3.1.4/drivers/ide/sl82c105.c .name =3D DRV_NAME, .init_chipset =3D init_chipset_sl82c105, .enablebits =3D {{0x40,0x01,0x01}, {0x40,0x10,0x10}}, -diff -urNp linux-3.1.4/drivers/ide/slc90e66.c linux-3.1.4/drivers/ide/sl= c90e66.c ---- linux-3.1.4/drivers/ide/slc90e66.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/ide/slc90e66.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -132,7 +132,7 @@ static const struct ide_port_ops slc90e6 +diff --git a/drivers/ide/slc90e66.c b/drivers/ide/slc90e66.c +index 864ffe0..863a5e9 100644 +--- a/drivers/ide/slc90e66.c ++++ b/drivers/ide/slc90e66.c +@@ -132,7 +132,7 @@ static const struct ide_port_ops slc90e66_port_ops =3D= { .cable_detect =3D slc90e66_cable_detect, }; =20 @@ -28855,10 +29603,11 @@ diff -urNp linux-3.1.4/drivers/ide/slc90e66.c l= inux-3.1.4/drivers/ide/slc90e66.c .name =3D DRV_NAME, .enablebits =3D { {0x41, 0x80, 0x80}, {0x43, 0x80, 0x80} }, .port_ops =3D &slc90e66_port_ops, -diff -urNp linux-3.1.4/drivers/ide/tc86c001.c linux-3.1.4/drivers/ide/tc= 86c001.c ---- linux-3.1.4/drivers/ide/tc86c001.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/ide/tc86c001.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -191,7 +191,7 @@ static const struct ide_dma_ops tc86c001 +diff --git a/drivers/ide/tc86c001.c b/drivers/ide/tc86c001.c +index e444d24..ba577de 100644 +--- a/drivers/ide/tc86c001.c ++++ b/drivers/ide/tc86c001.c +@@ -191,7 +191,7 @@ static const struct ide_dma_ops tc86c001_dma_ops =3D= { .dma_sff_read_status =3D ide_dma_sff_read_status, }; =20 @@ -28867,10 +29616,11 @@ diff -urNp linux-3.1.4/drivers/ide/tc86c001.c l= inux-3.1.4/drivers/ide/tc86c001.c .name =3D DRV_NAME, .init_hwif =3D init_hwif_tc86c001, .port_ops =3D &tc86c001_port_ops, -diff -urNp linux-3.1.4/drivers/ide/triflex.c linux-3.1.4/drivers/ide/tri= flex.c ---- linux-3.1.4/drivers/ide/triflex.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/ide/triflex.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -92,7 +92,7 @@ static const struct ide_port_ops triflex +diff --git a/drivers/ide/triflex.c b/drivers/ide/triflex.c +index e53a1b7..d11aff7 100644 +--- a/drivers/ide/triflex.c ++++ b/drivers/ide/triflex.c +@@ -92,7 +92,7 @@ static const struct ide_port_ops triflex_port_ops =3D = { .set_dma_mode =3D triflex_set_mode, }; =20 @@ -28879,10 +29629,11 @@ diff -urNp linux-3.1.4/drivers/ide/triflex.c li= nux-3.1.4/drivers/ide/triflex.c .name =3D DRV_NAME, .enablebits =3D {{0x80, 0x01, 0x01}, {0x80, 0x02, 0x02}}, .port_ops =3D &triflex_port_ops, -diff -urNp linux-3.1.4/drivers/ide/trm290.c linux-3.1.4/drivers/ide/trm2= 90.c ---- linux-3.1.4/drivers/ide/trm290.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/ide/trm290.c 2011-11-16 18:39:07.000000000 -0500 -@@ -324,7 +324,7 @@ static struct ide_dma_ops trm290_dma_ops +diff --git a/drivers/ide/trm290.c b/drivers/ide/trm290.c +index 4b42ca0..e494a98 100644 +--- a/drivers/ide/trm290.c ++++ b/drivers/ide/trm290.c +@@ -324,7 +324,7 @@ static struct ide_dma_ops trm290_dma_ops =3D { .dma_check =3D trm290_dma_check, }; =20 @@ -28891,10 +29642,11 @@ diff -urNp linux-3.1.4/drivers/ide/trm290.c lin= ux-3.1.4/drivers/ide/trm290.c .name =3D DRV_NAME, .init_hwif =3D init_hwif_trm290, .tp_ops =3D &trm290_tp_ops, -diff -urNp linux-3.1.4/drivers/ide/via82cxxx.c linux-3.1.4/drivers/ide/v= ia82cxxx.c ---- linux-3.1.4/drivers/ide/via82cxxx.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/ide/via82cxxx.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -403,7 +403,7 @@ static const struct ide_port_ops via_por +diff --git a/drivers/ide/via82cxxx.c b/drivers/ide/via82cxxx.c +index f46f49c..eb77678 100644 +--- a/drivers/ide/via82cxxx.c ++++ b/drivers/ide/via82cxxx.c +@@ -403,7 +403,7 @@ static const struct ide_port_ops via_port_ops =3D { .cable_detect =3D via82cxxx_cable_detect, }; =20 @@ -28903,10 +29655,11 @@ diff -urNp linux-3.1.4/drivers/ide/via82cxxx.c = linux-3.1.4/drivers/ide/via82cxxx .name =3D DRV_NAME, .init_chipset =3D init_chipset_via82cxxx, .enablebits =3D { { 0x40, 0x02, 0x02 }, { 0x40, 0x01, 0x01 } }, -diff -urNp linux-3.1.4/drivers/infiniband/core/cm.c linux-3.1.4/drivers/= infiniband/core/cm.c ---- linux-3.1.4/drivers/infiniband/core/cm.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/infiniband/core/cm.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -113,7 +113,7 @@ static char const counter_group_names[CM +diff --git a/drivers/infiniband/core/cm.c b/drivers/infiniband/core/cm.c +index fc0f2bd..ac2f8a5 100644 +--- a/drivers/infiniband/core/cm.c ++++ b/drivers/infiniband/core/cm.c +@@ -113,7 +113,7 @@ static char const counter_group_names[CM_COUNTER_GRO= UPS] =20 struct cm_counter_group { struct kobject obj; @@ -28915,7 +29668,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba }; =20 struct cm_counter_attribute { -@@ -1387,7 +1387,7 @@ static void cm_dup_req_handler(struct cm +@@ -1387,7 +1387,7 @@ static void cm_dup_req_handler(struct cm_work *wor= k, struct ib_mad_send_buf *msg =3D NULL; int ret; =20 @@ -28924,7 +29677,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_REQ_COUNTER]); =20 /* Quick state check to discard duplicate REQs. */ -@@ -1765,7 +1765,7 @@ static void cm_dup_rep_handler(struct cm +@@ -1765,7 +1765,7 @@ static void cm_dup_rep_handler(struct cm_work *wor= k) if (!cm_id_priv) return; =20 @@ -28933,7 +29686,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_REP_COUNTER]); ret =3D cm_alloc_response_msg(work->port, work->mad_recv_wc, &msg); if (ret) -@@ -1932,7 +1932,7 @@ static int cm_rtu_handler(struct cm_work +@@ -1932,7 +1932,7 @@ static int cm_rtu_handler(struct cm_work *work) if (cm_id_priv->id.state !=3D IB_CM_REP_SENT && cm_id_priv->id.state !=3D IB_CM_MRA_REP_RCVD) { spin_unlock_irq(&cm_id_priv->lock); @@ -28942,7 +29695,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_RTU_COUNTER]); goto out; } -@@ -2115,7 +2115,7 @@ static int cm_dreq_handler(struct cm_wor +@@ -2115,7 +2115,7 @@ static int cm_dreq_handler(struct cm_work *work) cm_id_priv =3D cm_acquire_id(dreq_msg->remote_comm_id, dreq_msg->local_comm_id); if (!cm_id_priv) { @@ -28951,7 +29704,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_DREQ_COUNTER]); cm_issue_drep(work->port, work->mad_recv_wc); return -EINVAL; -@@ -2140,7 +2140,7 @@ static int cm_dreq_handler(struct cm_wor +@@ -2140,7 +2140,7 @@ static int cm_dreq_handler(struct cm_work *work) case IB_CM_MRA_REP_RCVD: break; case IB_CM_TIMEWAIT: @@ -28960,7 +29713,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_DREQ_COUNTER]); if (cm_alloc_response_msg(work->port, work->mad_recv_wc, &msg)) goto unlock; -@@ -2154,7 +2154,7 @@ static int cm_dreq_handler(struct cm_wor +@@ -2154,7 +2154,7 @@ static int cm_dreq_handler(struct cm_work *work) cm_free_msg(msg); goto deref; case IB_CM_DREQ_RCVD: @@ -28969,7 +29722,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_DREQ_COUNTER]); goto unlock; default: -@@ -2521,7 +2521,7 @@ static int cm_mra_handler(struct cm_work +@@ -2521,7 +2521,7 @@ static int cm_mra_handler(struct cm_work *work) ib_modify_mad(cm_id_priv->av.port->mad_agent, cm_id_priv->msg, timeout)) { if (cm_id_priv->id.lap_state =3D=3D IB_CM_MRA_LAP_RCVD) @@ -28978,7 +29731,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter_group[CM_RECV_DUPLICATES]. counter[CM_MRA_COUNTER]); goto out; -@@ -2530,7 +2530,7 @@ static int cm_mra_handler(struct cm_work +@@ -2530,7 +2530,7 @@ static int cm_mra_handler(struct cm_work *work) break; case IB_CM_MRA_REQ_RCVD: case IB_CM_MRA_REP_RCVD: @@ -28987,7 +29740,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_MRA_COUNTER]); /* fall through */ default: -@@ -2692,7 +2692,7 @@ static int cm_lap_handler(struct cm_work +@@ -2692,7 +2692,7 @@ static int cm_lap_handler(struct cm_work *work) case IB_CM_LAP_IDLE: break; case IB_CM_MRA_LAP_SENT: @@ -28996,7 +29749,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_LAP_COUNTER]); if (cm_alloc_response_msg(work->port, work->mad_recv_wc, &msg)) goto unlock; -@@ -2708,7 +2708,7 @@ static int cm_lap_handler(struct cm_work +@@ -2708,7 +2708,7 @@ static int cm_lap_handler(struct cm_work *work) cm_free_msg(msg); goto deref; case IB_CM_LAP_RCVD: @@ -29005,7 +29758,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_LAP_COUNTER]); goto unlock; default: -@@ -2992,7 +2992,7 @@ static int cm_sidr_req_handler(struct cm +@@ -2992,7 +2992,7 @@ static int cm_sidr_req_handler(struct cm_work *wor= k) cur_cm_id_priv =3D cm_insert_remote_sidr(cm_id_priv); if (cur_cm_id_priv) { spin_unlock_irq(&cm.lock); @@ -29014,7 +29767,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[CM_SIDR_REQ_COUNTER]); goto out; /* Duplicate message. */ } -@@ -3204,10 +3204,10 @@ static void cm_send_handler(struct ib_ma +@@ -3204,10 +3204,10 @@ static void cm_send_handler(struct ib_mad_agent = *mad_agent, if (!msg->context[0] && (attr_index !=3D CM_REJ_COUNTER)) msg->retries =3D 1; =20 @@ -29027,7 +29780,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba &port->counter_group[CM_XMIT_RETRIES]. counter[attr_index]); =20 -@@ -3417,7 +3417,7 @@ static void cm_recv_handler(struct ib_ma +@@ -3417,7 +3417,7 @@ static void cm_recv_handler(struct ib_mad_agent *m= ad_agent, } =20 attr_id =3D be16_to_cpu(mad_recv_wc->recv_buf.mad->mad_hdr.attr_id); @@ -29036,7 +29789,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/cm= .c linux-3.1.4/drivers/infiniba counter[attr_id - CM_ATTR_ID_OFFSET]); =20 work =3D kmalloc(sizeof *work + sizeof(struct ib_sa_path_rec) * paths, -@@ -3615,7 +3615,7 @@ static ssize_t cm_show_counter(struct ko +@@ -3615,7 +3615,7 @@ static ssize_t cm_show_counter(struct kobject *obj= , struct attribute *attr, cm_attr =3D container_of(attr, struct cm_counter_attribute, attr); =20 return sprintf(buf, "%ld\n", @@ -29045,9 +29798,10 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/c= m.c linux-3.1.4/drivers/infiniba } =20 static const struct sysfs_ops cm_counter_ops =3D { -diff -urNp linux-3.1.4/drivers/infiniband/core/fmr_pool.c linux-3.1.4/dr= ivers/infiniband/core/fmr_pool.c ---- linux-3.1.4/drivers/infiniband/core/fmr_pool.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/infiniband/core/fmr_pool.c 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/drivers/infiniband/core/fmr_pool.c b/drivers/infiniband/cor= e/fmr_pool.c +index 4507043..14ad522 100644 +--- a/drivers/infiniband/core/fmr_pool.c ++++ b/drivers/infiniband/core/fmr_pool.c @@ -97,8 +97,8 @@ struct ib_fmr_pool { =20 struct task_struct *thread; @@ -29059,7 +29813,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/fm= r_pool.c linux-3.1.4/drivers/in =20 wait_queue_head_t force_wait; }; -@@ -179,10 +179,10 @@ static int ib_fmr_cleanup_thread(void *p +@@ -179,10 +179,10 @@ static int ib_fmr_cleanup_thread(void *pool_ptr) struct ib_fmr_pool *pool =3D pool_ptr; =20 do { @@ -29072,7 +29826,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/fm= r_pool.c linux-3.1.4/drivers/in wake_up_interruptible(&pool->force_wait); =20 if (pool->flush_function) -@@ -190,7 +190,7 @@ static int ib_fmr_cleanup_thread(void *p +@@ -190,7 +190,7 @@ static int ib_fmr_cleanup_thread(void *pool_ptr) } =20 set_current_state(TASK_INTERRUPTIBLE); @@ -29081,7 +29835,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/fm= r_pool.c linux-3.1.4/drivers/in !kthread_should_stop()) schedule(); __set_current_state(TASK_RUNNING); -@@ -282,8 +282,8 @@ struct ib_fmr_pool *ib_create_fmr_pool(s +@@ -282,8 +282,8 @@ struct ib_fmr_pool *ib_create_fmr_pool(struct ib_pd = *pd, pool->dirty_watermark =3D params->dirty_watermark; pool->dirty_len =3D 0; spin_lock_init(&pool->pool_lock); @@ -29092,7 +29846,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/fm= r_pool.c linux-3.1.4/drivers/in init_waitqueue_head(&pool->force_wait); =20 pool->thread =3D kthread_run(ib_fmr_cleanup_thread, -@@ -411,11 +411,11 @@ int ib_flush_fmr_pool(struct ib_fmr_pool +@@ -411,11 +411,11 @@ int ib_flush_fmr_pool(struct ib_fmr_pool *pool) } spin_unlock_irq(&pool->pool_lock); =20 @@ -29106,7 +29860,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/fm= r_pool.c linux-3.1.4/drivers/in return -EINTR; =20 return 0; -@@ -525,7 +525,7 @@ int ib_fmr_pool_unmap(struct ib_pool_fmr +@@ -525,7 +525,7 @@ int ib_fmr_pool_unmap(struct ib_pool_fmr *fmr) } else { list_add_tail(&fmr->list, &pool->dirty_list); if (++pool->dirty_len >=3D pool->dirty_watermark) { @@ -29115,10 +29869,11 @@ diff -urNp linux-3.1.4/drivers/infiniband/core/= fmr_pool.c linux-3.1.4/drivers/in wake_up_process(pool->thread); } } -diff -urNp linux-3.1.4/drivers/infiniband/hw/cxgb4/mem.c linux-3.1.4/dri= vers/infiniband/hw/cxgb4/mem.c ---- linux-3.1.4/drivers/infiniband/hw/cxgb4/mem.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/cxgb4/mem.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -122,7 +122,7 @@ static int write_tpt_entry(struct c4iw_r +diff --git a/drivers/infiniband/hw/cxgb4/mem.c b/drivers/infiniband/hw/c= xgb4/mem.c +index 40c8353..946b0e4 100644 +--- a/drivers/infiniband/hw/cxgb4/mem.c ++++ b/drivers/infiniband/hw/cxgb4/mem.c +@@ -122,7 +122,7 @@ static int write_tpt_entry(struct c4iw_rdev *rdev, u= 32 reset_tpt_entry, int err; struct fw_ri_tpte tpt; u32 stag_idx; @@ -29127,7 +29882,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/cxgb= 4/mem.c linux-3.1.4/drivers/inf =20 if (c4iw_fatal_error(rdev)) return -EIO; -@@ -135,7 +135,7 @@ static int write_tpt_entry(struct c4iw_r +@@ -135,7 +135,7 @@ static int write_tpt_entry(struct c4iw_rdev *rdev, u= 32 reset_tpt_entry, &rdev->resource.tpt_fifo_lock); if (!stag_idx) return -ENOMEM; @@ -29136,10 +29891,11 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/cx= gb4/mem.c linux-3.1.4/drivers/inf } PDBG("%s stag_state 0x%0x type 0x%0x pdid 0x%0x, stag_idx 0x%x\n", __func__, stag_state, type, pdid, stag_idx); -diff -urNp linux-3.1.4/drivers/infiniband/hw/ipath/ipath_fs.c linux-3.1.= 4/drivers/infiniband/hw/ipath/ipath_fs.c ---- linux-3.1.4/drivers/infiniband/hw/ipath/ipath_fs.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/ipath/ipath_fs.c 2011-11-16 18:40:= 10.000000000 -0500 -@@ -113,6 +113,8 @@ static ssize_t atomic_counters_read(stru +diff --git a/drivers/infiniband/hw/ipath/ipath_fs.c b/drivers/infiniband= /hw/ipath/ipath_fs.c +index 31ae1b1..2f5b038 100644 +--- a/drivers/infiniband/hw/ipath/ipath_fs.c ++++ b/drivers/infiniband/hw/ipath/ipath_fs.c +@@ -113,6 +113,8 @@ static ssize_t atomic_counters_read(struct file *fil= e, char __user *buf, struct infinipath_counters counters; struct ipath_devdata *dd; =20 @@ -29148,10 +29904,11 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/ip= ath/ipath_fs.c linux-3.1.4/driver dd =3D file->f_path.dentry->d_inode->i_private; dd->ipath_f_read_counters(dd, &counters); =20 -diff -urNp linux-3.1.4/drivers/infiniband/hw/ipath/ipath_rc.c linux-3.1.= 4/drivers/infiniband/hw/ipath/ipath_rc.c ---- linux-3.1.4/drivers/infiniband/hw/ipath/ipath_rc.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/ipath/ipath_rc.c 2011-11-16 18:39:= 07.000000000 -0500 -@@ -1868,7 +1868,7 @@ void ipath_rc_rcv(struct ipath_ibdev *de +diff --git a/drivers/infiniband/hw/ipath/ipath_rc.c b/drivers/infiniband= /hw/ipath/ipath_rc.c +index 79b3dbc..96e5fcc 100644 +--- a/drivers/infiniband/hw/ipath/ipath_rc.c ++++ b/drivers/infiniband/hw/ipath/ipath_rc.c +@@ -1868,7 +1868,7 @@ void ipath_rc_rcv(struct ipath_ibdev *dev, struct = ipath_ib_header *hdr, struct ib_atomic_eth *ateth; struct ipath_ack_entry *e; u64 vaddr; @@ -29160,7 +29917,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/ipat= h/ipath_rc.c linux-3.1.4/driver u64 sdata; u32 rkey; u8 next; -@@ -1903,11 +1903,11 @@ void ipath_rc_rcv(struct ipath_ibdev *de +@@ -1903,11 +1903,11 @@ void ipath_rc_rcv(struct ipath_ibdev *dev, struc= t ipath_ib_header *hdr, IB_ACCESS_REMOTE_ATOMIC))) goto nack_acc_unlck; /* Perform atomic OP and save result. */ @@ -29174,10 +29931,11 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/ip= ath/ipath_rc.c linux-3.1.4/driver (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, be64_to_cpu(ateth->compare_data), sdata); -diff -urNp linux-3.1.4/drivers/infiniband/hw/ipath/ipath_ruc.c linux-3.1= .4/drivers/infiniband/hw/ipath/ipath_ruc.c ---- linux-3.1.4/drivers/infiniband/hw/ipath/ipath_ruc.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/ipath/ipath_ruc.c 2011-11-16 18:39= :07.000000000 -0500 -@@ -266,7 +266,7 @@ static void ipath_ruc_loopback(struct ip +diff --git a/drivers/infiniband/hw/ipath/ipath_ruc.c b/drivers/infiniban= d/hw/ipath/ipath_ruc.c +index 1f95bba..9530f87 100644 +--- a/drivers/infiniband/hw/ipath/ipath_ruc.c ++++ b/drivers/infiniband/hw/ipath/ipath_ruc.c +@@ -266,7 +266,7 @@ static void ipath_ruc_loopback(struct ipath_qp *sqp) unsigned long flags; struct ib_wc wc; u64 sdata; @@ -29200,10 +29958,11 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/ip= ath/ipath_ruc.c linux-3.1.4/drive (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, sdata, wqe->wr.wr.atomic.swap); goto send_comp; -diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/nes.c linux-3.1.4/drive= rs/infiniband/hw/nes/nes.c ---- linux-3.1.4/drivers/infiniband/hw/nes/nes.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/nes/nes.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -103,7 +103,7 @@ MODULE_PARM_DESC(limit_maxrdreqsz, "Limi +diff --git a/drivers/infiniband/hw/nes/nes.c b/drivers/infiniband/hw/nes= /nes.c +index 2d668c6..3312bb7 100644 +--- a/drivers/infiniband/hw/nes/nes.c ++++ b/drivers/infiniband/hw/nes/nes.c +@@ -103,7 +103,7 @@ MODULE_PARM_DESC(limit_maxrdreqsz, "Limit max read r= equest size to 256 Bytes"); LIST_HEAD(nes_adapter_list); static LIST_HEAD(nes_dev_list); =20 @@ -29212,7 +29971,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/= nes.c linux-3.1.4/drivers/infin =20 static unsigned int ee_flsh_adapter; static unsigned int sysfs_nonidx_addr; -@@ -275,7 +275,7 @@ static void nes_cqp_rem_ref_callback(str +@@ -275,7 +275,7 @@ static void nes_cqp_rem_ref_callback(struct nes_devi= ce *nesdev, struct nes_cqp_r struct nes_qp *nesqp =3D cqp_request->cqp_callback_pointer; struct nes_adapter *nesadapter =3D nesdev->nesadapter; =20 @@ -29221,208 +29980,10 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/n= es/nes.c linux-3.1.4/drivers/infin =20 /* Free the control structures */ =20 -diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/nes_cm.c linux-3.1.4/dr= ivers/infiniband/hw/nes/nes_cm.c ---- linux-3.1.4/drivers/infiniband/hw/nes/nes_cm.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/nes/nes_cm.c 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -68,14 +68,14 @@ u32 cm_packets_dropped; - u32 cm_packets_retrans; - u32 cm_packets_created; - u32 cm_packets_received; --atomic_t cm_listens_created; --atomic_t cm_listens_destroyed; -+atomic_unchecked_t cm_listens_created; -+atomic_unchecked_t cm_listens_destroyed; - u32 cm_backlog_drops; --atomic_t cm_loopbacks; --atomic_t cm_nodes_created; --atomic_t cm_nodes_destroyed; --atomic_t cm_accel_dropped_pkts; --atomic_t cm_resets_recvd; -+atomic_unchecked_t cm_loopbacks; -+atomic_unchecked_t cm_nodes_created; -+atomic_unchecked_t cm_nodes_destroyed; -+atomic_unchecked_t cm_accel_dropped_pkts; -+atomic_unchecked_t cm_resets_recvd; -=20 - static inline int mini_cm_accelerated(struct nes_cm_core *, - struct nes_cm_node *); -@@ -151,13 +151,13 @@ static struct nes_cm_ops nes_cm_api =3D { -=20 - static struct nes_cm_core *g_cm_core; -=20 --atomic_t cm_connects; --atomic_t cm_accepts; --atomic_t cm_disconnects; --atomic_t cm_closes; --atomic_t cm_connecteds; --atomic_t cm_connect_reqs; --atomic_t cm_rejects; -+atomic_unchecked_t cm_connects; -+atomic_unchecked_t cm_accepts; -+atomic_unchecked_t cm_disconnects; -+atomic_unchecked_t cm_closes; -+atomic_unchecked_t cm_connecteds; -+atomic_unchecked_t cm_connect_reqs; -+atomic_unchecked_t cm_rejects; -=20 -=20 - /** -@@ -1045,7 +1045,7 @@ static int mini_cm_dec_refcnt_listen(str - kfree(listener); - listener =3D NULL; - ret =3D 0; -- atomic_inc(&cm_listens_destroyed); -+ atomic_inc_unchecked(&cm_listens_destroyed); - } else { - spin_unlock_irqrestore(&cm_core->listen_list_lock, flags); - } -@@ -1240,7 +1240,7 @@ static struct nes_cm_node *make_cm_node( - cm_node->rem_mac); -=20 - add_hte_node(cm_core, cm_node); -- atomic_inc(&cm_nodes_created); -+ atomic_inc_unchecked(&cm_nodes_created); -=20 - return cm_node; - } -@@ -1298,7 +1298,7 @@ static int rem_ref_cm_node(struct nes_cm - } -=20 - atomic_dec(&cm_core->node_cnt); -- atomic_inc(&cm_nodes_destroyed); -+ atomic_inc_unchecked(&cm_nodes_destroyed); - nesqp =3D cm_node->nesqp; - if (nesqp) { - nesqp->cm_node =3D NULL; -@@ -1365,7 +1365,7 @@ static int process_options(struct nes_cm -=20 - static void drop_packet(struct sk_buff *skb) - { -- atomic_inc(&cm_accel_dropped_pkts); -+ atomic_inc_unchecked(&cm_accel_dropped_pkts); - dev_kfree_skb_any(skb); - } -=20 -@@ -1428,7 +1428,7 @@ static void handle_rst_pkt(struct nes_cm - { -=20 - int reset =3D 0; /* whether to send reset in case of err.. */ -- atomic_inc(&cm_resets_recvd); -+ atomic_inc_unchecked(&cm_resets_recvd); - nes_debug(NES_DBG_CM, "Received Reset, cm_node =3D %p, state =3D %u." - " refcnt=3D%d\n", cm_node, cm_node->state, - atomic_read(&cm_node->ref_count)); -@@ -2057,7 +2057,7 @@ static struct nes_cm_node *mini_cm_conne - rem_ref_cm_node(cm_node->cm_core, cm_node); - return NULL; - } -- atomic_inc(&cm_loopbacks); -+ atomic_inc_unchecked(&cm_loopbacks); - loopbackremotenode->loopbackpartner =3D cm_node; - loopbackremotenode->tcp_cntxt.rcv_wscale =3D - NES_CM_DEFAULT_RCV_WND_SCALE; -@@ -2332,7 +2332,7 @@ static int mini_cm_recv_pkt(struct nes_c - add_ref_cm_node(cm_node); - } else if (cm_node->state =3D=3D NES_CM_STATE_TSA) { - rem_ref_cm_node(cm_core, cm_node); -- atomic_inc(&cm_accel_dropped_pkts); -+ atomic_inc_unchecked(&cm_accel_dropped_pkts); - dev_kfree_skb_any(skb); - break; - } -@@ -2638,7 +2638,7 @@ static int nes_cm_disconn_true(struct ne -=20 - if ((cm_id) && (cm_id->event_handler)) { - if (issue_disconn) { -- atomic_inc(&cm_disconnects); -+ atomic_inc_unchecked(&cm_disconnects); - cm_event.event =3D IW_CM_EVENT_DISCONNECT; - cm_event.status =3D disconn_status; - cm_event.local_addr =3D cm_id->local_addr; -@@ -2660,7 +2660,7 @@ static int nes_cm_disconn_true(struct ne - } -=20 - if (issue_close) { -- atomic_inc(&cm_closes); -+ atomic_inc_unchecked(&cm_closes); - nes_disconnect(nesqp, 1); -=20 - cm_id->provider_data =3D nesqp; -@@ -2791,7 +2791,7 @@ int nes_accept(struct iw_cm_id *cm_id, s -=20 - nes_debug(NES_DBG_CM, "QP%u, cm_node=3D%p, jiffies =3D %lu listener =3D= %p\n", - nesqp->hwqp.qp_id, cm_node, jiffies, cm_node->listener); -- atomic_inc(&cm_accepts); -+ atomic_inc_unchecked(&cm_accepts); -=20 - nes_debug(NES_DBG_CM, "netdev refcnt =3D %u.\n", - netdev_refcnt_read(nesvnic->netdev)); -@@ -3001,7 +3001,7 @@ int nes_reject(struct iw_cm_id *cm_id, c -=20 - struct nes_cm_core *cm_core; -=20 -- atomic_inc(&cm_rejects); -+ atomic_inc_unchecked(&cm_rejects); - cm_node =3D (struct nes_cm_node *) cm_id->provider_data; - loopback =3D cm_node->loopbackpartner; - cm_core =3D cm_node->cm_core; -@@ -3067,7 +3067,7 @@ int nes_connect(struct iw_cm_id *cm_id,=20 - ntohl(cm_id->local_addr.sin_addr.s_addr), - ntohs(cm_id->local_addr.sin_port)); -=20 -- atomic_inc(&cm_connects); -+ atomic_inc_unchecked(&cm_connects); - nesqp->active_conn =3D 1; -=20 - /* cache the cm_id in the qp */ -@@ -3173,7 +3173,7 @@ int nes_create_listen(struct iw_cm_id *c - g_cm_core->api->stop_listener(g_cm_core, (void *)cm_node); - return err; - } -- atomic_inc(&cm_listens_created); -+ atomic_inc_unchecked(&cm_listens_created); - } -=20 - cm_id->add_ref(cm_id); -@@ -3278,7 +3278,7 @@ static void cm_event_connected(struct ne - if (nesqp->destroyed) { - return; - } -- atomic_inc(&cm_connecteds); -+ atomic_inc_unchecked(&cm_connecteds); - nes_debug(NES_DBG_CM, "QP%u attempting to connect to 0x%08X:0x%04X on= " - " local port 0x%04X. jiffies =3D %lu.\n", - nesqp->hwqp.qp_id, -@@ -3493,7 +3493,7 @@ static void cm_event_reset(struct nes_cm -=20 - cm_id->add_ref(cm_id); - ret =3D cm_id->event_handler(cm_id, &cm_event); -- atomic_inc(&cm_closes); -+ atomic_inc_unchecked(&cm_closes); - cm_event.event =3D IW_CM_EVENT_CLOSE; - cm_event.status =3D 0; - cm_event.provider_data =3D cm_id->provider_data; -@@ -3529,7 +3529,7 @@ static void cm_event_mpa_req(struct nes_ - return; - cm_id =3D cm_node->cm_id; -=20 -- atomic_inc(&cm_connect_reqs); -+ atomic_inc_unchecked(&cm_connect_reqs); - nes_debug(NES_DBG_CM, "cm_node =3D %p - cm_id =3D %p, jiffies =3D %lu\= n", - cm_node, cm_id, jiffies); -=20 -@@ -3567,7 +3567,7 @@ static void cm_event_mpa_reject(struct n - return; - cm_id =3D cm_node->cm_id; -=20 -- atomic_inc(&cm_connect_reqs); -+ atomic_inc_unchecked(&cm_connect_reqs); - nes_debug(NES_DBG_CM, "cm_node =3D %p - cm_id =3D %p, jiffies =3D %lu\= n", - cm_node, cm_id, jiffies); -=20 -diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/nes.h linux-3.1.4/drive= rs/infiniband/hw/nes/nes.h ---- linux-3.1.4/drivers/infiniband/hw/nes/nes.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/nes/nes.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/infiniband/hw/nes/nes.h b/drivers/infiniband/hw/nes= /nes.h +index 6fe7987..68637b5 100644 +--- a/drivers/infiniband/hw/nes/nes.h ++++ b/drivers/infiniband/hw/nes/nes.h @@ -175,17 +175,17 @@ extern unsigned int nes_debug_level; extern unsigned int wqm_quanta; extern struct list_head nes_adapter_list; @@ -29474,10 +30035,211 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/n= es/nes.h linux-3.1.4/drivers/infin =20 extern u32 int_mod_timer_init; extern u32 int_mod_cq_depth_256; -diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/nes_nic.c linux-3.1.4/d= rivers/infiniband/hw/nes/nes_nic.c ---- linux-3.1.4/drivers/infiniband/hw/nes/nes_nic.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/nes/nes_nic.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -1274,31 +1274,31 @@ static void nes_netdev_get_ethtool_stats +diff --git a/drivers/infiniband/hw/nes/nes_cm.c b/drivers/infiniband/hw/= nes/nes_cm.c +index c118663..049a3ab 100644 +--- a/drivers/infiniband/hw/nes/nes_cm.c ++++ b/drivers/infiniband/hw/nes/nes_cm.c +@@ -68,14 +68,14 @@ u32 cm_packets_dropped; + u32 cm_packets_retrans; + u32 cm_packets_created; + u32 cm_packets_received; +-atomic_t cm_listens_created; +-atomic_t cm_listens_destroyed; ++atomic_unchecked_t cm_listens_created; ++atomic_unchecked_t cm_listens_destroyed; + u32 cm_backlog_drops; +-atomic_t cm_loopbacks; +-atomic_t cm_nodes_created; +-atomic_t cm_nodes_destroyed; +-atomic_t cm_accel_dropped_pkts; +-atomic_t cm_resets_recvd; ++atomic_unchecked_t cm_loopbacks; ++atomic_unchecked_t cm_nodes_created; ++atomic_unchecked_t cm_nodes_destroyed; ++atomic_unchecked_t cm_accel_dropped_pkts; ++atomic_unchecked_t cm_resets_recvd; +=20 + static inline int mini_cm_accelerated(struct nes_cm_core *, + struct nes_cm_node *); +@@ -151,13 +151,13 @@ static struct nes_cm_ops nes_cm_api =3D { +=20 + static struct nes_cm_core *g_cm_core; +=20 +-atomic_t cm_connects; +-atomic_t cm_accepts; +-atomic_t cm_disconnects; +-atomic_t cm_closes; +-atomic_t cm_connecteds; +-atomic_t cm_connect_reqs; +-atomic_t cm_rejects; ++atomic_unchecked_t cm_connects; ++atomic_unchecked_t cm_accepts; ++atomic_unchecked_t cm_disconnects; ++atomic_unchecked_t cm_closes; ++atomic_unchecked_t cm_connecteds; ++atomic_unchecked_t cm_connect_reqs; ++atomic_unchecked_t cm_rejects; +=20 +=20 + /** +@@ -1045,7 +1045,7 @@ static int mini_cm_dec_refcnt_listen(struct nes_cm= _core *cm_core, + kfree(listener); + listener =3D NULL; + ret =3D 0; +- atomic_inc(&cm_listens_destroyed); ++ atomic_inc_unchecked(&cm_listens_destroyed); + } else { + spin_unlock_irqrestore(&cm_core->listen_list_lock, flags); + } +@@ -1240,7 +1240,7 @@ static struct nes_cm_node *make_cm_node(struct nes= _cm_core *cm_core, + cm_node->rem_mac); +=20 + add_hte_node(cm_core, cm_node); +- atomic_inc(&cm_nodes_created); ++ atomic_inc_unchecked(&cm_nodes_created); +=20 + return cm_node; + } +@@ -1298,7 +1298,7 @@ static int rem_ref_cm_node(struct nes_cm_core *cm_= core, + } +=20 + atomic_dec(&cm_core->node_cnt); +- atomic_inc(&cm_nodes_destroyed); ++ atomic_inc_unchecked(&cm_nodes_destroyed); + nesqp =3D cm_node->nesqp; + if (nesqp) { + nesqp->cm_node =3D NULL; +@@ -1365,7 +1365,7 @@ static int process_options(struct nes_cm_node *cm_= node, u8 *optionsloc, +=20 + static void drop_packet(struct sk_buff *skb) + { +- atomic_inc(&cm_accel_dropped_pkts); ++ atomic_inc_unchecked(&cm_accel_dropped_pkts); + dev_kfree_skb_any(skb); + } +=20 +@@ -1428,7 +1428,7 @@ static void handle_rst_pkt(struct nes_cm_node *cm_= node, struct sk_buff *skb, + { +=20 + int reset =3D 0; /* whether to send reset in case of err.. */ +- atomic_inc(&cm_resets_recvd); ++ atomic_inc_unchecked(&cm_resets_recvd); + nes_debug(NES_DBG_CM, "Received Reset, cm_node =3D %p, state =3D %u." + " refcnt=3D%d\n", cm_node, cm_node->state, + atomic_read(&cm_node->ref_count)); +@@ -2057,7 +2057,7 @@ static struct nes_cm_node *mini_cm_connect(struct = nes_cm_core *cm_core, + rem_ref_cm_node(cm_node->cm_core, cm_node); + return NULL; + } +- atomic_inc(&cm_loopbacks); ++ atomic_inc_unchecked(&cm_loopbacks); + loopbackremotenode->loopbackpartner =3D cm_node; + loopbackremotenode->tcp_cntxt.rcv_wscale =3D + NES_CM_DEFAULT_RCV_WND_SCALE; +@@ -2332,7 +2332,7 @@ static int mini_cm_recv_pkt(struct nes_cm_core *cm= _core, + add_ref_cm_node(cm_node); + } else if (cm_node->state =3D=3D NES_CM_STATE_TSA) { + rem_ref_cm_node(cm_core, cm_node); +- atomic_inc(&cm_accel_dropped_pkts); ++ atomic_inc_unchecked(&cm_accel_dropped_pkts); + dev_kfree_skb_any(skb); + break; + } +@@ -2638,7 +2638,7 @@ static int nes_cm_disconn_true(struct nes_qp *nesq= p) +=20 + if ((cm_id) && (cm_id->event_handler)) { + if (issue_disconn) { +- atomic_inc(&cm_disconnects); ++ atomic_inc_unchecked(&cm_disconnects); + cm_event.event =3D IW_CM_EVENT_DISCONNECT; + cm_event.status =3D disconn_status; + cm_event.local_addr =3D cm_id->local_addr; +@@ -2660,7 +2660,7 @@ static int nes_cm_disconn_true(struct nes_qp *nesq= p) + } +=20 + if (issue_close) { +- atomic_inc(&cm_closes); ++ atomic_inc_unchecked(&cm_closes); + nes_disconnect(nesqp, 1); +=20 + cm_id->provider_data =3D nesqp; +@@ -2791,7 +2791,7 @@ int nes_accept(struct iw_cm_id *cm_id, struct iw_c= m_conn_param *conn_param) +=20 + nes_debug(NES_DBG_CM, "QP%u, cm_node=3D%p, jiffies =3D %lu listener =3D= %p\n", + nesqp->hwqp.qp_id, cm_node, jiffies, cm_node->listener); +- atomic_inc(&cm_accepts); ++ atomic_inc_unchecked(&cm_accepts); +=20 + nes_debug(NES_DBG_CM, "netdev refcnt =3D %u.\n", + netdev_refcnt_read(nesvnic->netdev)); +@@ -3001,7 +3001,7 @@ int nes_reject(struct iw_cm_id *cm_id, const void = *pdata, u8 pdata_len) +=20 + struct nes_cm_core *cm_core; +=20 +- atomic_inc(&cm_rejects); ++ atomic_inc_unchecked(&cm_rejects); + cm_node =3D (struct nes_cm_node *) cm_id->provider_data; + loopback =3D cm_node->loopbackpartner; + cm_core =3D cm_node->cm_core; +@@ -3067,7 +3067,7 @@ int nes_connect(struct iw_cm_id *cm_id, struct iw_= cm_conn_param *conn_param) + ntohl(cm_id->local_addr.sin_addr.s_addr), + ntohs(cm_id->local_addr.sin_port)); +=20 +- atomic_inc(&cm_connects); ++ atomic_inc_unchecked(&cm_connects); + nesqp->active_conn =3D 1; +=20 + /* cache the cm_id in the qp */ +@@ -3173,7 +3173,7 @@ int nes_create_listen(struct iw_cm_id *cm_id, int = backlog) + g_cm_core->api->stop_listener(g_cm_core, (void *)cm_node); + return err; + } +- atomic_inc(&cm_listens_created); ++ atomic_inc_unchecked(&cm_listens_created); + } +=20 + cm_id->add_ref(cm_id); +@@ -3278,7 +3278,7 @@ static void cm_event_connected(struct nes_cm_event= *event) + if (nesqp->destroyed) { + return; + } +- atomic_inc(&cm_connecteds); ++ atomic_inc_unchecked(&cm_connecteds); + nes_debug(NES_DBG_CM, "QP%u attempting to connect to 0x%08X:0x%04X on= " + " local port 0x%04X. jiffies =3D %lu.\n", + nesqp->hwqp.qp_id, +@@ -3493,7 +3493,7 @@ static void cm_event_reset(struct nes_cm_event *ev= ent) +=20 + cm_id->add_ref(cm_id); + ret =3D cm_id->event_handler(cm_id, &cm_event); +- atomic_inc(&cm_closes); ++ atomic_inc_unchecked(&cm_closes); + cm_event.event =3D IW_CM_EVENT_CLOSE; + cm_event.status =3D 0; + cm_event.provider_data =3D cm_id->provider_data; +@@ -3529,7 +3529,7 @@ static void cm_event_mpa_req(struct nes_cm_event *= event) + return; + cm_id =3D cm_node->cm_id; +=20 +- atomic_inc(&cm_connect_reqs); ++ atomic_inc_unchecked(&cm_connect_reqs); + nes_debug(NES_DBG_CM, "cm_node =3D %p - cm_id =3D %p, jiffies =3D %lu\= n", + cm_node, cm_id, jiffies); +=20 +@@ -3567,7 +3567,7 @@ static void cm_event_mpa_reject(struct nes_cm_even= t *event) + return; + cm_id =3D cm_node->cm_id; +=20 +- atomic_inc(&cm_connect_reqs); ++ atomic_inc_unchecked(&cm_connect_reqs); + nes_debug(NES_DBG_CM, "cm_node =3D %p - cm_id =3D %p, jiffies =3D %lu\= n", + cm_node, cm_id, jiffies); +=20 +diff --git a/drivers/infiniband/hw/nes/nes_nic.c b/drivers/infiniband/hw= /nes/nes_nic.c +index 9d7ffeb..a95dd7d 100644 +--- a/drivers/infiniband/hw/nes/nes_nic.c ++++ b/drivers/infiniband/hw/nes/nes_nic.c +@@ -1274,31 +1274,31 @@ static void nes_netdev_get_ethtool_stats(struct = net_device *netdev, target_stat_values[++index] =3D mh_detected; target_stat_values[++index] =3D mh_pauses_sent; target_stat_values[++index] =3D nesvnic->endnode_ipv4_tcp_retransmits; @@ -29527,9 +30289,10 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/nes= /nes_nic.c linux-3.1.4/drivers/i target_stat_values[++index] =3D nesadapter->free_4kpbl; target_stat_values[++index] =3D nesadapter->free_256pbl; target_stat_values[++index] =3D int_mod_timer_init; -diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/nes_verbs.c linux-3.1.4= /drivers/infiniband/hw/nes/nes_verbs.c ---- linux-3.1.4/drivers/infiniband/hw/nes/nes_verbs.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/nes/nes_verbs.c 2011-11-16 18:39:0= 7.000000000 -0500 +diff --git a/drivers/infiniband/hw/nes/nes_verbs.c b/drivers/infiniband/= hw/nes/nes_verbs.c +index 9f2f7d4..6d2fee2 100644 +--- a/drivers/infiniband/hw/nes/nes_verbs.c ++++ b/drivers/infiniband/hw/nes/nes_verbs.c @@ -46,9 +46,9 @@ =20 #include @@ -29543,7 +30306,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/= nes_verbs.c linux-3.1.4/drivers =20 static void nes_unregister_ofa_device(struct nes_ib_device *nesibdev); =20 -@@ -1131,7 +1131,7 @@ static struct ib_qp *nes_create_qp(struc +@@ -1131,7 +1131,7 @@ static struct ib_qp *nes_create_qp(struct ib_pd *i= bpd, if (init_attr->create_flags) return ERR_PTR(-EINVAL); =20 @@ -29552,7 +30315,7 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/nes/= nes_verbs.c linux-3.1.4/drivers switch (init_attr->qp_type) { case IB_QPT_RC: if (nes_drv_opt & NES_DRV_OPT_NO_INLINE_DATA) { -@@ -1460,7 +1460,7 @@ static int nes_destroy_qp(struct ib_qp * +@@ -1460,7 +1460,7 @@ static int nes_destroy_qp(struct ib_qp *ibqp) struct iw_cm_event cm_event; int ret; =20 @@ -29561,9 +30324,10 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/nes= /nes_verbs.c linux-3.1.4/drivers nesqp->destroyed =3D 1; =20 /* Blow away the connection if it exists. */ -diff -urNp linux-3.1.4/drivers/infiniband/hw/qib/qib.h linux-3.1.4/drive= rs/infiniband/hw/qib/qib.h ---- linux-3.1.4/drivers/infiniband/hw/qib/qib.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/infiniband/hw/qib/qib.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/infiniband/hw/qib/qib.h b/drivers/infiniband/hw/qib= /qib.h +index c9624ea..e025b66 100644 +--- a/drivers/infiniband/hw/qib/qib.h ++++ b/drivers/infiniband/hw/qib/qib.h @@ -51,6 +51,7 @@ #include #include @@ -29572,9 +30336,10 @@ diff -urNp linux-3.1.4/drivers/infiniband/hw/qib= /qib.h linux-3.1.4/drivers/infin =20 #include "qib_common.h" #include "qib_verbs.h" -diff -urNp linux-3.1.4/drivers/input/gameport/gameport.c linux-3.1.4/dri= vers/input/gameport/gameport.c ---- linux-3.1.4/drivers/input/gameport/gameport.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/input/gameport/gameport.c 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/drivers/input/gameport/gameport.c b/drivers/input/gameport/= gameport.c +index c351aa4..e6967c2 100644 +--- a/drivers/input/gameport/gameport.c ++++ b/drivers/input/gameport/gameport.c @@ -488,14 +488,14 @@ EXPORT_SYMBOL(gameport_set_phys); */ static void gameport_init_port(struct gameport *gameport) @@ -29592,10 +30357,11 @@ diff -urNp linux-3.1.4/drivers/input/gameport/g= ameport.c linux-3.1.4/drivers/inp gameport->dev.bus =3D &gameport_bus; gameport->dev.release =3D gameport_release_port; if (gameport->parent) -diff -urNp linux-3.1.4/drivers/input/input.c linux-3.1.4/drivers/input/i= nput.c ---- linux-3.1.4/drivers/input/input.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/input/input.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -1814,7 +1814,7 @@ static void input_cleanse_bitmasks(struc +diff --git a/drivers/input/input.c b/drivers/input/input.c +index da38d97..2aa0b79 100644 +--- a/drivers/input/input.c ++++ b/drivers/input/input.c +@@ -1814,7 +1814,7 @@ static void input_cleanse_bitmasks(struct input_de= v *dev) */ int input_register_device(struct input_dev *dev) { @@ -29604,7 +30370,7 @@ diff -urNp linux-3.1.4/drivers/input/input.c linu= x-3.1.4/drivers/input/input.c struct input_handler *handler; const char *path; int error; -@@ -1851,7 +1851,7 @@ int input_register_device(struct input_d +@@ -1851,7 +1851,7 @@ int input_register_device(struct input_dev *dev) dev->setkeycode =3D input_default_setkeycode; =20 dev_set_name(&dev->dev, "input%ld", @@ -29613,9 +30379,10 @@ diff -urNp linux-3.1.4/drivers/input/input.c lin= ux-3.1.4/drivers/input/input.c =20 error =3D device_add(&dev->dev); if (error) -diff -urNp linux-3.1.4/drivers/input/joystick/sidewinder.c linux-3.1.4/d= rivers/input/joystick/sidewinder.c ---- linux-3.1.4/drivers/input/joystick/sidewinder.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/input/joystick/sidewinder.c 2011-11-16 18:40:10.= 000000000 -0500 +diff --git a/drivers/input/joystick/sidewinder.c b/drivers/input/joystic= k/sidewinder.c +index b8d8611..15f8d2c 100644 +--- a/drivers/input/joystick/sidewinder.c ++++ b/drivers/input/joystick/sidewinder.c @@ -30,6 +30,7 @@ #include #include @@ -29633,10 +30400,11 @@ diff -urNp linux-3.1.4/drivers/input/joystick/s= idewinder.c linux-3.1.4/drivers/i i =3D sw_read_packet(sw->gameport, buf, sw->length, 0); =20 if (sw->type =3D=3D SW_ID_3DP && sw->length =3D=3D 66 && i !=3D 66) { = /* Broken packet, try to fix */ -diff -urNp linux-3.1.4/drivers/input/joystick/xpad.c linux-3.1.4/drivers= /input/joystick/xpad.c ---- linux-3.1.4/drivers/input/joystick/xpad.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/input/joystick/xpad.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -710,7 +710,7 @@ static void xpad_led_set(struct led_clas +diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad= .c +index d728875..844c89b 100644 +--- a/drivers/input/joystick/xpad.c ++++ b/drivers/input/joystick/xpad.c +@@ -710,7 +710,7 @@ static void xpad_led_set(struct led_classdev *led_cd= ev, =20 static int xpad_led_probe(struct usb_xpad *xpad) { @@ -29645,7 +30413,7 @@ diff -urNp linux-3.1.4/drivers/input/joystick/xpa= d.c linux-3.1.4/drivers/input/j long led_no; struct xpad_led *led; struct led_classdev *led_cdev; -@@ -723,7 +723,7 @@ static int xpad_led_probe(struct usb_xpa +@@ -723,7 +723,7 @@ static int xpad_led_probe(struct usb_xpad *xpad) if (!led) return -ENOMEM; =20 @@ -29654,10 +30422,11 @@ diff -urNp linux-3.1.4/drivers/input/joystick/x= pad.c linux-3.1.4/drivers/input/j =20 snprintf(led->name, sizeof(led->name), "xpad%ld", led_no); led->xpad =3D xpad; -diff -urNp linux-3.1.4/drivers/input/mousedev.c linux-3.1.4/drivers/inpu= t/mousedev.c ---- linux-3.1.4/drivers/input/mousedev.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/input/mousedev.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -763,7 +763,7 @@ static ssize_t mousedev_read(struct file +diff --git a/drivers/input/mousedev.c b/drivers/input/mousedev.c +index 0110b5a..d3ad144 100644 +--- a/drivers/input/mousedev.c ++++ b/drivers/input/mousedev.c +@@ -763,7 +763,7 @@ static ssize_t mousedev_read(struct file *file, char= __user *buffer, =20 spin_unlock_irq(&client->packet_lock); =20 @@ -29666,10 +30435,11 @@ diff -urNp linux-3.1.4/drivers/input/mousedev.c= linux-3.1.4/drivers/input/moused return -EFAULT; =20 return count; -diff -urNp linux-3.1.4/drivers/input/serio/serio.c linux-3.1.4/drivers/i= nput/serio/serio.c ---- linux-3.1.4/drivers/input/serio/serio.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/input/serio/serio.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -497,7 +497,7 @@ static void serio_release_port(struct de +diff --git a/drivers/input/serio/serio.c b/drivers/input/serio/serio.c +index ba70058..571d25d 100644 +--- a/drivers/input/serio/serio.c ++++ b/drivers/input/serio/serio.c +@@ -497,7 +497,7 @@ static void serio_release_port(struct device *dev) */ static void serio_init_port(struct serio *serio) { @@ -29678,7 +30448,7 @@ diff -urNp linux-3.1.4/drivers/input/serio/serio.= c linux-3.1.4/drivers/input/ser =20 __module_get(THIS_MODULE); =20 -@@ -508,7 +508,7 @@ static void serio_init_port(struct serio +@@ -508,7 +508,7 @@ static void serio_init_port(struct serio *serio) mutex_init(&serio->drv_mutex); device_initialize(&serio->dev); dev_set_name(&serio->dev, "serio%ld", @@ -29687,9 +30457,10 @@ diff -urNp linux-3.1.4/drivers/input/serio/serio= .c linux-3.1.4/drivers/input/ser serio->dev.bus =3D &serio_bus; serio->dev.release =3D serio_release_port; serio->dev.groups =3D serio_device_attr_groups; -diff -urNp linux-3.1.4/drivers/isdn/capi/capi.c linux-3.1.4/drivers/isdn= /capi/capi.c ---- linux-3.1.4/drivers/isdn/capi/capi.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/isdn/capi/capi.c 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/drivers/isdn/capi/capi.c b/drivers/isdn/capi/capi.c +index e44933d..9ba484a 100644 +--- a/drivers/isdn/capi/capi.c ++++ b/drivers/isdn/capi/capi.c @@ -83,8 +83,8 @@ struct capiminor { =20 struct capi20_appl *ap; @@ -29701,7 +30472,7 @@ diff -urNp linux-3.1.4/drivers/isdn/capi/capi.c l= inux-3.1.4/drivers/isdn/capi/ca =20 struct tty_port port; int ttyinstop; -@@ -397,7 +397,7 @@ gen_data_b3_resp_for(struct capiminor *m +@@ -397,7 +397,7 @@ gen_data_b3_resp_for(struct capiminor *mp, struct sk= _buff *skb) capimsg_setu16(s, 2, mp->ap->applid); capimsg_setu8 (s, 4, CAPI_DATA_B3); capimsg_setu8 (s, 5, CAPI_RESP); @@ -29710,7 +30481,7 @@ diff -urNp linux-3.1.4/drivers/isdn/capi/capi.c l= inux-3.1.4/drivers/isdn/capi/ca capimsg_setu32(s, 8, mp->ncci); capimsg_setu16(s, 12, datahandle); } -@@ -518,14 +518,14 @@ static void handle_minor_send(struct cap +@@ -518,14 +518,14 @@ static void handle_minor_send(struct capiminor *mp= ) mp->outbytes -=3D len; spin_unlock_bh(&mp->outlock); =20 @@ -29727,10 +30498,11 @@ diff -urNp linux-3.1.4/drivers/isdn/capi/capi.c= linux-3.1.4/drivers/isdn/capi/ca capimsg_setu32(skb->data, 8, mp->ncci); /* NCCI */ capimsg_setu32(skb->data, 12, (u32)(long)skb->data);/* Data32 */ capimsg_setu16(skb->data, 16, len); /* Data length */ -diff -urNp linux-3.1.4/drivers/isdn/gigaset/common.c linux-3.1.4/drivers= /isdn/gigaset/common.c ---- linux-3.1.4/drivers/isdn/gigaset/common.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/isdn/gigaset/common.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -723,7 +723,7 @@ struct cardstate *gigaset_initcs(struct=20 +diff --git a/drivers/isdn/gigaset/common.c b/drivers/isdn/gigaset/common= .c +index db621db..825ea1a 100644 +--- a/drivers/isdn/gigaset/common.c ++++ b/drivers/isdn/gigaset/common.c +@@ -723,7 +723,7 @@ struct cardstate *gigaset_initcs(struct gigaset_driv= er *drv, int channels, cs->commands_pending =3D 0; cs->cur_at_seq =3D 0; cs->gotfwver =3D -1; @@ -29739,9 +30511,10 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/comm= on.c linux-3.1.4/drivers/isdn/gi cs->dev =3D NULL; cs->tty =3D NULL; cs->tty_dev =3D NULL; -diff -urNp linux-3.1.4/drivers/isdn/gigaset/gigaset.h linux-3.1.4/driver= s/isdn/gigaset/gigaset.h ---- linux-3.1.4/drivers/isdn/gigaset/gigaset.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/isdn/gigaset/gigaset.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/drivers/isdn/gigaset/gigaset.h b/drivers/isdn/gigaset/gigas= et.h +index 212efaf..f187c6b 100644 +--- a/drivers/isdn/gigaset/gigaset.h ++++ b/drivers/isdn/gigaset/gigaset.h @@ -35,6 +35,7 @@ #include #include @@ -29759,10 +30532,11 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/gig= aset.h linux-3.1.4/drivers/isdn/g struct tty_struct *tty; struct tasklet_struct if_wake_tasklet; unsigned control_state; -diff -urNp linux-3.1.4/drivers/isdn/gigaset/interface.c linux-3.1.4/driv= ers/isdn/gigaset/interface.c ---- linux-3.1.4/drivers/isdn/gigaset/interface.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/isdn/gigaset/interface.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -162,9 +162,7 @@ static int if_open(struct tty_struct *tt +diff --git a/drivers/isdn/gigaset/interface.c b/drivers/isdn/gigaset/int= erface.c +index e35058b..5898a8b 100644 +--- a/drivers/isdn/gigaset/interface.c ++++ b/drivers/isdn/gigaset/interface.c +@@ -162,9 +162,7 @@ static int if_open(struct tty_struct *tty, struct fi= le *filp) } tty->driver_data =3D cs; =20 @@ -29773,7 +30547,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn spin_lock_irqsave(&cs->lock, flags); cs->tty =3D tty; spin_unlock_irqrestore(&cs->lock, flags); -@@ -192,10 +190,10 @@ static void if_close(struct tty_struct * +@@ -192,10 +190,10 @@ static void if_close(struct tty_struct *tty, struc= t file *filp) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -29786,7 +30560,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn spin_lock_irqsave(&cs->lock, flags); cs->tty =3D NULL; spin_unlock_irqrestore(&cs->lock, flags); -@@ -230,7 +228,7 @@ static int if_ioctl(struct tty_struct *t +@@ -230,7 +228,7 @@ static int if_ioctl(struct tty_struct *tty, if (!cs->connected) { gig_dbg(DEBUG_IF, "not connected"); retval =3D -ENODEV; @@ -29795,7 +30569,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else { retval =3D 0; -@@ -360,7 +358,7 @@ static int if_write(struct tty_struct *t +@@ -360,7 +358,7 @@ static int if_write(struct tty_struct *tty, const un= signed char *buf, int count) retval =3D -ENODEV; goto done; } @@ -29804,7 +30578,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); retval =3D -ENODEV; goto done; -@@ -413,7 +411,7 @@ static int if_write_room(struct tty_stru +@@ -413,7 +411,7 @@ static int if_write_room(struct tty_struct *tty) if (!cs->connected) { gig_dbg(DEBUG_IF, "not connected"); retval =3D -ENODEV; @@ -29813,7 +30587,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else if (cs->mstate !=3D MS_LOCKED) { dev_warn(cs->dev, "can't write to unlocked device\n"); -@@ -443,7 +441,7 @@ static int if_chars_in_buffer(struct tty +@@ -443,7 +441,7 @@ static int if_chars_in_buffer(struct tty_struct *tty= ) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); @@ -29822,7 +30596,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else if (cs->mstate !=3D MS_LOCKED) dev_warn(cs->dev, "can't write to unlocked device\n"); -@@ -471,7 +469,7 @@ static void if_throttle(struct tty_struc +@@ -471,7 +469,7 @@ static void if_throttle(struct tty_struct *tty) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -29831,7 +30605,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else gig_dbg(DEBUG_IF, "%s: not implemented\n", __func__); -@@ -495,7 +493,7 @@ static void if_unthrottle(struct tty_str +@@ -495,7 +493,7 @@ static void if_unthrottle(struct tty_struct *tty) =20 if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -29840,7 +30614,7 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/inter= face.c linux-3.1.4/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else gig_dbg(DEBUG_IF, "%s: not implemented\n", __func__); -@@ -526,7 +524,7 @@ static void if_set_termios(struct tty_st +@@ -526,7 +524,7 @@ static void if_set_termios(struct tty_struct *tty, s= truct ktermios *old) goto out; } =20 @@ -29849,10 +30623,11 @@ diff -urNp linux-3.1.4/drivers/isdn/gigaset/int= erface.c linux-3.1.4/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); goto out; } -diff -urNp linux-3.1.4/drivers/isdn/hardware/avm/b1.c linux-3.1.4/driver= s/isdn/hardware/avm/b1.c ---- linux-3.1.4/drivers/isdn/hardware/avm/b1.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/avm/b1.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -176,7 +176,7 @@ int b1_load_t4file(avmcard *card, capilo +diff --git a/drivers/isdn/hardware/avm/b1.c b/drivers/isdn/hardware/avm/= b1.c +index 2a57da59..e7a12ed 100644 +--- a/drivers/isdn/hardware/avm/b1.c ++++ b/drivers/isdn/hardware/avm/b1.c +@@ -176,7 +176,7 @@ int b1_load_t4file(avmcard *card, capiloaddatapart *= t4file) } if (left) { if (t4file->user) { @@ -29861,7 +30636,7 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/avm/= b1.c linux-3.1.4/drivers/isdn/h return -EFAULT; } else { memcpy(buf, dp, left); -@@ -224,7 +224,7 @@ int b1_load_config(avmcard *card, capilo +@@ -224,7 +224,7 @@ int b1_load_config(avmcard *card, capiloaddatapart *= config) } if (left) { if (config->user) { @@ -29870,10 +30645,11 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/av= m/b1.c linux-3.1.4/drivers/isdn/h return -EFAULT; } else { memcpy(buf, dp, left); -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/capidtmf.c linux-3.1.= 4/drivers/isdn/hardware/eicon/capidtmf.c ---- linux-3.1.4/drivers/isdn/hardware/eicon/capidtmf.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/capidtmf.c 2011-11-16 18:40:= 10.000000000 -0500 -@@ -498,6 +498,7 @@ void capidtmf_recv_block (t_capidtmf_sta +diff --git a/drivers/isdn/hardware/eicon/capidtmf.c b/drivers/isdn/hardw= are/eicon/capidtmf.c +index f130724..c373c68 100644 +--- a/drivers/isdn/hardware/eicon/capidtmf.c ++++ b/drivers/isdn/hardware/eicon/capidtmf.c +@@ -498,6 +498,7 @@ void capidtmf_recv_block (t_capidtmf_state *p_stat= e, byte *buffer, word leng byte goertzel_result_buffer[CAPIDTMF_RECV_TOTAL_FREQUENCY_COUNT]; short windowed_sample_buffer[CAPIDTMF_RECV_WINDOWED_SAMPLES]; =20 @@ -29881,9 +30657,10 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/eic= on/capidtmf.c linux-3.1.4/driver =20 if (p_state->recv.state & CAPIDTMF_RECV_STATE_DTMF_ACTIVE) { -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/capifunc.c linux-3.1.= 4/drivers/isdn/hardware/eicon/capifunc.c ---- linux-3.1.4/drivers/isdn/hardware/eicon/capifunc.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/capifunc.c 2011-11-16 18:40:= 10.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/capifunc.c b/drivers/isdn/hardw= are/eicon/capifunc.c +index 4d425c6..a9be6c4 100644 +--- a/drivers/isdn/hardware/eicon/capifunc.c ++++ b/drivers/isdn/hardware/eicon/capifunc.c @@ -1055,6 +1055,8 @@ static int divacapi_connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; @@ -29893,10 +30670,11 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/ei= con/capifunc.c linux-3.1.4/driver DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/diddfunc.c linux-3.1.= 4/drivers/isdn/hardware/eicon/diddfunc.c ---- linux-3.1.4/drivers/isdn/hardware/eicon/diddfunc.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/diddfunc.c 2011-11-16 18:40:= 10.000000000 -0500 -@@ -54,6 +54,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/diddfunc.c b/drivers/isdn/hardw= are/eicon/diddfunc.c +index 3029234..ef0d9e2 100644 +--- a/drivers/isdn/hardware/eicon/diddfunc.c ++++ b/drivers/isdn/hardware/eicon/diddfunc.c +@@ -54,6 +54,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -29905,10 +30683,11 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/ei= con/diddfunc.c linux-3.1.4/driver DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/divasfunc.c linux-3.1= .4/drivers/isdn/hardware/eicon/divasfunc.c ---- linux-3.1.4/drivers/isdn/hardware/eicon/divasfunc.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/divasfunc.c 2011-11-16 18:40= :10.000000000 -0500 -@@ -160,6 +160,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/divasfunc.c b/drivers/isdn/hard= ware/eicon/divasfunc.c +index 0bbee78..a0d0a01 100644 +--- a/drivers/isdn/hardware/eicon/divasfunc.c ++++ b/drivers/isdn/hardware/eicon/divasfunc.c +@@ -160,6 +160,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -29917,9 +30696,10 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/eic= on/divasfunc.c linux-3.1.4/drive DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/divasync.h linux-3.1.= 4/drivers/isdn/hardware/eicon/divasync.h ---- linux-3.1.4/drivers/isdn/hardware/eicon/divasync.h 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/divasync.h 2011-11-16 18:39:= 07.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/divasync.h b/drivers/isdn/hardw= are/eicon/divasync.h +index 85784a7..a19ca98 100644 +--- a/drivers/isdn/hardware/eicon/divasync.h ++++ b/drivers/isdn/hardware/eicon/divasync.h @@ -146,7 +146,7 @@ typedef struct _diva_didd_add_adapter { } diva_didd_add_adapter_t; typedef struct _diva_didd_remove_adapter { @@ -29929,10 +30709,11 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/ei= con/divasync.h linux-3.1.4/driver typedef struct _diva_didd_read_adapter_array { void * buffer; dword length; -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/idifunc.c linux-3.1.4= /drivers/isdn/hardware/eicon/idifunc.c ---- linux-3.1.4/drivers/isdn/hardware/eicon/idifunc.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/idifunc.c 2011-11-16 18:40:1= 0.000000000 -0500 -@@ -188,6 +188,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/idifunc.c b/drivers/isdn/hardwa= re/eicon/idifunc.c +index db87d51..7d09acf 100644 +--- a/drivers/isdn/hardware/eicon/idifunc.c ++++ b/drivers/isdn/hardware/eicon/idifunc.c +@@ -188,6 +188,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -29941,9 +30722,10 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/eic= on/idifunc.c linux-3.1.4/drivers DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/message.c linux-3.1.4= /drivers/isdn/hardware/eicon/message.c ---- linux-3.1.4/drivers/isdn/hardware/eicon/message.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/message.c 2011-11-16 18:40:1= 0.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/message.c b/drivers/isdn/hardwa= re/eicon/message.c +index a339598..b6a8bfc 100644 +--- a/drivers/isdn/hardware/eicon/message.c ++++ b/drivers/isdn/hardware/eicon/message.c @@ -4886,6 +4886,8 @@ static void sig_ind(PLCI *plci) dword d; word w; @@ -29953,7 +30735,7 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/eico= n/message.c linux-3.1.4/drivers a =3D plci->adapter; Id =3D ((word)plci->Id<<8)|a->Id; PUT_WORD(&SS_Ind[4],0x0000); -@@ -7480,6 +7482,8 @@ static word add_b1(PLCI *plci, API_PARSE +@@ -7480,6 +7482,8 @@ static word add_b1(PLCI *plci, API_PARSE *bp, word= b_channel_info, word j, n, w; dword d; =20 @@ -29962,7 +30744,7 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/eico= n/message.c linux-3.1.4/drivers =20 for(i=3D0;i<8;i++) bp_parms[i].length =3D 0; for(i=3D0;i<2;i++) global_config[i].length =3D 0; -@@ -7954,6 +7958,8 @@ static word add_b23(PLCI *plci, API_PARS +@@ -7954,6 +7958,8 @@ static word add_b23(PLCI *plci, API_PARSE *bp) const byte llc3[] =3D {4,3,2,2,6,6,0}; const byte header[] =3D {0,2,3,3,0,0,0}; =20 @@ -29971,7 +30753,7 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/eico= n/message.c linux-3.1.4/drivers for(i=3D0;i<8;i++) bp_parms[i].length =3D 0; for(i=3D0;i<6;i++) b2_config_parms[i].length =3D 0; for(i=3D0;i<5;i++) b3_config_parms[i].length =3D 0; -@@ -14741,6 +14747,8 @@ static void group_optimization(DIVA_CAPI +@@ -14741,6 +14747,8 @@ static void group_optimization(DIVA_CAPI_ADAPTER= * a, PLCI * plci) word appl_number_group_type[MAX_APPL]; PLCI *auxplci; =20 @@ -29980,10 +30762,11 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/ei= con/message.c linux-3.1.4/drivers set_group_ind_mask (plci); /* all APPLs within this inc. call are all= owed to dial in */ =20 if(!a->group_optimization_enabled) -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/mntfunc.c linux-3.1.4= /drivers/isdn/hardware/eicon/mntfunc.c ---- linux-3.1.4/drivers/isdn/hardware/eicon/mntfunc.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/mntfunc.c 2011-11-16 18:40:1= 0.000000000 -0500 -@@ -79,6 +79,8 @@ static int DIVA_INIT_FUNCTION connect_di +diff --git a/drivers/isdn/hardware/eicon/mntfunc.c b/drivers/isdn/hardwa= re/eicon/mntfunc.c +index a564b75..f3cf8b5 100644 +--- a/drivers/isdn/hardware/eicon/mntfunc.c ++++ b/drivers/isdn/hardware/eicon/mntfunc.c +@@ -79,6 +79,8 @@ static int DIVA_INIT_FUNCTION connect_didd(void) IDI_SYNC_REQ req; DESCRIPTOR DIDD_Table[MAX_DESCRIPTORS]; =20 @@ -29992,9 +30775,10 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/eic= on/mntfunc.c linux-3.1.4/drivers DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); =20 for (x =3D 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.1.4/drivers/isdn/hardware/eicon/xdi_adapter.h linux-3= .1.4/drivers/isdn/hardware/eicon/xdi_adapter.h ---- linux-3.1.4/drivers/isdn/hardware/eicon/xdi_adapter.h 2011-11-11 15:= 19:27.000000000 -0500 -+++ linux-3.1.4/drivers/isdn/hardware/eicon/xdi_adapter.h 2011-11-16 18:= 39:07.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/xdi_adapter.h b/drivers/isdn/ha= rdware/eicon/xdi_adapter.h +index a3bd163..8956575 100644 +--- a/drivers/isdn/hardware/eicon/xdi_adapter.h ++++ b/drivers/isdn/hardware/eicon/xdi_adapter.h @@ -44,7 +44,7 @@ typedef struct _xdi_mbox_t { typedef struct _diva_os_idi_adapter_interface { diva_init_card_proc_t cleanup_adapter_proc; @@ -30004,10 +30788,11 @@ diff -urNp linux-3.1.4/drivers/isdn/hardware/ei= con/xdi_adapter.h linux-3.1.4/dri =20 typedef struct _diva_os_xdi_adapter { struct list_head link; -diff -urNp linux-3.1.4/drivers/isdn/i4l/isdn_common.c linux-3.1.4/driver= s/isdn/i4l/isdn_common.c ---- linux-3.1.4/drivers/isdn/i4l/isdn_common.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/isdn/i4l/isdn_common.c 2011-11-16 18:40:10.00000= 0000 -0500 -@@ -1286,6 +1286,8 @@ isdn_ioctl(struct file *file, uint cmd,=20 +diff --git a/drivers/isdn/i4l/isdn_common.c b/drivers/isdn/i4l/isdn_comm= on.c +index 6ed82ad..b05ac05 100644 +--- a/drivers/isdn/i4l/isdn_common.c ++++ b/drivers/isdn/i4l/isdn_common.c +@@ -1286,6 +1286,8 @@ isdn_ioctl(struct file *file, uint cmd, ulong arg) } iocpar; void __user *argp =3D (void __user *)arg; =20 @@ -30016,10 +30801,11 @@ diff -urNp linux-3.1.4/drivers/isdn/i4l/isdn_co= mmon.c linux-3.1.4/drivers/isdn/i #define name iocpar.name #define bname iocpar.bname #define iocts iocpar.iocts -diff -urNp linux-3.1.4/drivers/isdn/icn/icn.c linux-3.1.4/drivers/isdn/i= cn/icn.c ---- linux-3.1.4/drivers/isdn/icn/icn.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/isdn/icn/icn.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -1045,7 +1045,7 @@ icn_writecmd(const u_char * buf, int len +diff --git a/drivers/isdn/icn/icn.c b/drivers/isdn/icn/icn.c +index 1f355bb..43f1fea 100644 +--- a/drivers/isdn/icn/icn.c ++++ b/drivers/isdn/icn/icn.c +@@ -1045,7 +1045,7 @@ icn_writecmd(const u_char * buf, int len, int user= , icn_card * card) if (count > len) count =3D len; if (user) { @@ -30028,9 +30814,10 @@ diff -urNp linux-3.1.4/drivers/isdn/icn/icn.c li= nux-3.1.4/drivers/isdn/icn/icn.c return -EFAULT; } else memcpy(msg, buf, count); -diff -urNp linux-3.1.4/drivers/lguest/core.c linux-3.1.4/drivers/lguest/= core.c ---- linux-3.1.4/drivers/lguest/core.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/lguest/core.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/lguest/core.c b/drivers/lguest/core.c +index 2535933..09a8e86 100644 +--- a/drivers/lguest/core.c ++++ b/drivers/lguest/core.c @@ -92,9 +92,17 @@ static __init int map_switcher(void) * it's worked so far. The end address needs +1 because __get_vm_area * allocates an extra guard page, so we need space for that. @@ -30058,9 +30845,10 @@ diff -urNp linux-3.1.4/drivers/lguest/core.c lin= ux-3.1.4/drivers/lguest/core.c end_switcher_text - start_switcher_text); =20 printk(KERN_INFO "lguest: mapped switcher at %p\n", -diff -urNp linux-3.1.4/drivers/lguest/x86/core.c linux-3.1.4/drivers/lgu= est/x86/core.c ---- linux-3.1.4/drivers/lguest/x86/core.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/lguest/x86/core.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/drivers/lguest/x86/core.c b/drivers/lguest/x86/core.c +index 65af42f..530c87a 100644 +--- a/drivers/lguest/x86/core.c ++++ b/drivers/lguest/x86/core.c @@ -59,7 +59,7 @@ static struct { /* Offset from where switcher.S was compiled to where we've copied it *= / static unsigned long switcher_offset(void) @@ -30070,7 +30858,7 @@ diff -urNp linux-3.1.4/drivers/lguest/x86/core.c = linux-3.1.4/drivers/lguest/x86/ } =20 /* This cpu's struct lguest_pages. */ -@@ -100,7 +100,13 @@ static void copy_in_guest_info(struct lg +@@ -100,7 +100,13 @@ static void copy_in_guest_info(struct lg_cpu *cpu, = struct lguest_pages *pages) * These copies are pretty cheap, so we do them unconditionally: */ /* Save the current Host top-level page directory. */ @@ -30102,9 +30890,10 @@ diff -urNp linux-3.1.4/drivers/lguest/x86/core.c= linux-3.1.4/drivers/lguest/x86/ lguest_entry.segment =3D LGUEST_CS; =20 /* -diff -urNp linux-3.1.4/drivers/lguest/x86/switcher_32.S linux-3.1.4/driv= ers/lguest/x86/switcher_32.S ---- linux-3.1.4/drivers/lguest/x86/switcher_32.S 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/lguest/x86/switcher_32.S 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/drivers/lguest/x86/switcher_32.S b/drivers/lguest/x86/switc= her_32.S +index 40634b0..4f5855e 100644 +--- a/drivers/lguest/x86/switcher_32.S ++++ b/drivers/lguest/x86/switcher_32.S @@ -87,6 +87,7 @@ #include #include @@ -30163,10 +30952,11 @@ diff -urNp linux-3.1.4/drivers/lguest/x86/switc= her_32.S linux-3.1.4/drivers/lgue =20 // Every interrupt can come to us here // But we must truly tell each apart. -diff -urNp linux-3.1.4/drivers/macintosh/macio_asic.c linux-3.1.4/driver= s/macintosh/macio_asic.c ---- linux-3.1.4/drivers/macintosh/macio_asic.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/macintosh/macio_asic.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -748,7 +748,7 @@ static void __devexit macio_pci_remove(s +diff --git a/drivers/macintosh/macio_asic.c b/drivers/macintosh/macio_as= ic.c +index 4daf9e5..b8d1d0f 100644 +--- a/drivers/macintosh/macio_asic.c ++++ b/drivers/macintosh/macio_asic.c +@@ -748,7 +748,7 @@ static void __devexit macio_pci_remove(struct pci_de= v* pdev) * MacIO is matched against any Apple ID, it's probe() function * will then decide wether it applies or not */ @@ -30175,67 +30965,11 @@ diff -urNp linux-3.1.4/drivers/macintosh/macio_= asic.c linux-3.1.4/drivers/macint .vendor =3D PCI_VENDOR_ID_APPLE, .device =3D PCI_ANY_ID, .subvendor =3D PCI_ANY_ID, -diff -urNp linux-3.1.4/drivers/md/dm.c linux-3.1.4/drivers/md/dm.c ---- linux-3.1.4/drivers/md/dm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/md/dm.c 2011-11-16 18:39:07.000000000 -0500 -@@ -165,9 +165,9 @@ struct mapped_device { - /* - * Event handling. - */ -- atomic_t event_nr; -+ atomic_unchecked_t event_nr; - wait_queue_head_t eventq; -- atomic_t uevent_seq; -+ atomic_unchecked_t uevent_seq; - struct list_head uevent_list; - spinlock_t uevent_lock; /* Protect access to uevent_list */ -=20 -@@ -1843,8 +1843,8 @@ static struct mapped_device *alloc_dev(i - rwlock_init(&md->map_lock); - atomic_set(&md->holders, 1); - atomic_set(&md->open_count, 0); -- atomic_set(&md->event_nr, 0); -- atomic_set(&md->uevent_seq, 0); -+ atomic_set_unchecked(&md->event_nr, 0); -+ atomic_set_unchecked(&md->uevent_seq, 0); - INIT_LIST_HEAD(&md->uevent_list); - spin_lock_init(&md->uevent_lock); -=20 -@@ -1978,7 +1978,7 @@ static void event_callback(void *context -=20 - dm_send_uevents(&uevents, &disk_to_dev(md->disk)->kobj); -=20 -- atomic_inc(&md->event_nr); -+ atomic_inc_unchecked(&md->event_nr); - wake_up(&md->eventq); - } -=20 -@@ -2614,18 +2614,18 @@ int dm_kobject_uevent(struct mapped_devi -=20 - uint32_t dm_next_uevent_seq(struct mapped_device *md) - { -- return atomic_add_return(1, &md->uevent_seq); -+ return atomic_add_return_unchecked(1, &md->uevent_seq); - } -=20 - uint32_t dm_get_event_nr(struct mapped_device *md) - { -- return atomic_read(&md->event_nr); -+ return atomic_read_unchecked(&md->event_nr); - } -=20 - int dm_wait_event(struct mapped_device *md, int event_nr) - { - return wait_event_interruptible(md->eventq, -- (event_nr !=3D atomic_read(&md->event_nr))); -+ (event_nr !=3D atomic_read_unchecked(&md->event_nr))); - } -=20 - void dm_uevent_add(struct mapped_device *md, struct list_head *elist) -diff -urNp linux-3.1.4/drivers/md/dm-ioctl.c linux-3.1.4/drivers/md/dm-i= octl.c ---- linux-3.1.4/drivers/md/dm-ioctl.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/md/dm-ioctl.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -1578,7 +1578,7 @@ static int validate_params(uint cmd, str +diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c +index 2e9a3ca..c2fb229 100644 +--- a/drivers/md/dm-ioctl.c ++++ b/drivers/md/dm-ioctl.c +@@ -1578,7 +1578,7 @@ static int validate_params(uint cmd, struct dm_ioc= tl *param) cmd =3D=3D DM_LIST_VERSIONS_CMD) return 0; =20 @@ -30244,9 +30978,10 @@ diff -urNp linux-3.1.4/drivers/md/dm-ioctl.c lin= ux-3.1.4/drivers/md/dm-ioctl.c if (!*param->name) { DMWARN("name not supplied when creating device"); return -EINVAL; -diff -urNp linux-3.1.4/drivers/md/dm-raid1.c linux-3.1.4/drivers/md/dm-r= aid1.c ---- linux-3.1.4/drivers/md/dm-raid1.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/md/dm-raid1.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/md/dm-raid1.c b/drivers/md/dm-raid1.c +index 9bfd057..01180bc 100644 +--- a/drivers/md/dm-raid1.c ++++ b/drivers/md/dm-raid1.c @@ -40,7 +40,7 @@ enum dm_raid1_error { =20 struct mirror { @@ -30256,7 +30991,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-raid1.c linu= x-3.1.4/drivers/md/dm-raid1.c unsigned long error_type; struct dm_dev *dev; sector_t offset; -@@ -185,7 +185,7 @@ static struct mirror *get_valid_mirror(s +@@ -185,7 +185,7 @@ static struct mirror *get_valid_mirror(struct mirror= _set *ms) struct mirror *m; =20 for (m =3D ms->mirror; m < ms->mirror + ms->nr_mirrors; m++) @@ -30265,7 +31000,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-raid1.c linu= x-3.1.4/drivers/md/dm-raid1.c return m; =20 return NULL; -@@ -217,7 +217,7 @@ static void fail_mirror(struct mirror *m +@@ -217,7 +217,7 @@ static void fail_mirror(struct mirror *m, enum dm_ra= id1_error error_type) * simple way to tell if a device has encountered * errors. */ @@ -30274,7 +31009,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-raid1.c linu= x-3.1.4/drivers/md/dm-raid1.c =20 if (test_and_set_bit(error_type, &m->error_type)) return; -@@ -408,7 +408,7 @@ static struct mirror *choose_mirror(stru +@@ -408,7 +408,7 @@ static struct mirror *choose_mirror(struct mirror_se= t *ms, sector_t sector) struct mirror *m =3D get_default_mirror(ms); =20 do { @@ -30292,7 +31027,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-raid1.c linu= x-3.1.4/drivers/md/dm-raid1.c } =20 static int mirror_available(struct mirror_set *ms, struct bio *bio) -@@ -559,7 +559,7 @@ static void do_reads(struct mirror_set * +@@ -559,7 +559,7 @@ static void do_reads(struct mirror_set *ms, struct b= io_list *reads) */ if (likely(region_in_sync(ms, region, 1))) m =3D choose_mirror(ms, bio->bi_sector); @@ -30301,7 +31036,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-raid1.c linu= x-3.1.4/drivers/md/dm-raid1.c m =3D NULL; =20 if (likely(m)) -@@ -937,7 +937,7 @@ static int get_mirror(struct mirror_set=20 +@@ -937,7 +937,7 @@ static int get_mirror(struct mirror_set *ms, struct = dm_target *ti, } =20 ms->mirror[mirror].ms =3D ms; @@ -30310,7 +31045,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-raid1.c linu= x-3.1.4/drivers/md/dm-raid1.c ms->mirror[mirror].error_type =3D 0; ms->mirror[mirror].offset =3D offset; =20 -@@ -1347,7 +1347,7 @@ static void mirror_resume(struct dm_targ +@@ -1347,7 +1347,7 @@ static void mirror_resume(struct dm_target *ti) */ static char device_status_char(struct mirror *m) { @@ -30319,9 +31054,10 @@ diff -urNp linux-3.1.4/drivers/md/dm-raid1.c lin= ux-3.1.4/drivers/md/dm-raid1.c return 'A'; =20 return (test_bit(DM_RAID1_FLUSH_ERROR, &(m->error_type))) ? 'F' : -diff -urNp linux-3.1.4/drivers/md/dm-stripe.c linux-3.1.4/drivers/md/dm-= stripe.c ---- linux-3.1.4/drivers/md/dm-stripe.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/md/dm-stripe.c 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/drivers/md/dm-stripe.c b/drivers/md/dm-stripe.c +index 3d80cf0..b77cc47 100644 +--- a/drivers/md/dm-stripe.c ++++ b/drivers/md/dm-stripe.c @@ -20,7 +20,7 @@ struct stripe { struct dm_dev *dev; sector_t physical_start; @@ -30331,7 +31067,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-stripe.c lin= ux-3.1.4/drivers/md/dm-stripe.c }; =20 struct stripe_c { -@@ -192,7 +192,7 @@ static int stripe_ctr(struct dm_target * +@@ -192,7 +192,7 @@ static int stripe_ctr(struct dm_target *ti, unsigned= int argc, char **argv) kfree(sc); return r; } @@ -30340,7 +31076,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-stripe.c lin= ux-3.1.4/drivers/md/dm-stripe.c } =20 ti->private =3D sc; -@@ -314,7 +314,7 @@ static int stripe_status(struct dm_targe +@@ -314,7 +314,7 @@ static int stripe_status(struct dm_target *ti, DMEMIT("%d ", sc->stripes); for (i =3D 0; i < sc->stripes; i++) { DMEMIT("%s ", sc->stripe[i].dev->name); @@ -30349,7 +31085,7 @@ diff -urNp linux-3.1.4/drivers/md/dm-stripe.c lin= ux-3.1.4/drivers/md/dm-stripe.c 'D' : 'A'; } buffer[i] =3D '\0'; -@@ -361,8 +361,8 @@ static int stripe_end_io(struct dm_targe +@@ -361,8 +361,8 @@ static int stripe_end_io(struct dm_target *ti, struc= t bio *bio, */ for (i =3D 0; i < sc->stripes; i++) if (!strcmp(sc->stripe[i].dev->name, major_minor)) { @@ -30360,10 +31096,11 @@ diff -urNp linux-3.1.4/drivers/md/dm-stripe.c l= inux-3.1.4/drivers/md/dm-stripe.c DM_IO_ERROR_THRESHOLD) schedule_work(&sc->trigger_event); } -diff -urNp linux-3.1.4/drivers/md/dm-table.c linux-3.1.4/drivers/md/dm-t= able.c ---- linux-3.1.4/drivers/md/dm-table.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/md/dm-table.c 2011-11-16 18:39:07.000000000 -050= 0 -@@ -389,7 +389,7 @@ static int device_area_is_invalid(struct +diff --git a/drivers/md/dm-table.c b/drivers/md/dm-table.c +index bc04518..7a83b81 100644 +--- a/drivers/md/dm-table.c ++++ b/drivers/md/dm-table.c +@@ -389,7 +389,7 @@ static int device_area_is_invalid(struct dm_target *= ti, struct dm_dev *dev, if (!dev_size) return 0; =20 @@ -30372,9 +31109,68 @@ diff -urNp linux-3.1.4/drivers/md/dm-table.c lin= ux-3.1.4/drivers/md/dm-table.c DMWARN("%s: %s too small for target: " "start=3D%llu, len=3D%llu, dev_size=3D%llu", dm_device_name(ti->table->md), bdevname(bdev, b), -diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.4/drivers/md/md.c ---- linux-3.1.4/drivers/md/md.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/md/md.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/md/dm.c b/drivers/md/dm.c +index 52b39f3..83a8b6b 100644 +--- a/drivers/md/dm.c ++++ b/drivers/md/dm.c +@@ -165,9 +165,9 @@ struct mapped_device { + /* + * Event handling. + */ +- atomic_t event_nr; ++ atomic_unchecked_t event_nr; + wait_queue_head_t eventq; +- atomic_t uevent_seq; ++ atomic_unchecked_t uevent_seq; + struct list_head uevent_list; + spinlock_t uevent_lock; /* Protect access to uevent_list */ +=20 +@@ -1843,8 +1843,8 @@ static struct mapped_device *alloc_dev(int minor) + rwlock_init(&md->map_lock); + atomic_set(&md->holders, 1); + atomic_set(&md->open_count, 0); +- atomic_set(&md->event_nr, 0); +- atomic_set(&md->uevent_seq, 0); ++ atomic_set_unchecked(&md->event_nr, 0); ++ atomic_set_unchecked(&md->uevent_seq, 0); + INIT_LIST_HEAD(&md->uevent_list); + spin_lock_init(&md->uevent_lock); +=20 +@@ -1978,7 +1978,7 @@ static void event_callback(void *context) +=20 + dm_send_uevents(&uevents, &disk_to_dev(md->disk)->kobj); +=20 +- atomic_inc(&md->event_nr); ++ atomic_inc_unchecked(&md->event_nr); + wake_up(&md->eventq); + } +=20 +@@ -2614,18 +2614,18 @@ int dm_kobject_uevent(struct mapped_device *md, = enum kobject_action action, +=20 + uint32_t dm_next_uevent_seq(struct mapped_device *md) + { +- return atomic_add_return(1, &md->uevent_seq); ++ return atomic_add_return_unchecked(1, &md->uevent_seq); + } +=20 + uint32_t dm_get_event_nr(struct mapped_device *md) + { +- return atomic_read(&md->event_nr); ++ return atomic_read_unchecked(&md->event_nr); + } +=20 + int dm_wait_event(struct mapped_device *md, int event_nr) + { + return wait_event_interruptible(md->eventq, +- (event_nr !=3D atomic_read(&md->event_nr))); ++ (event_nr !=3D atomic_read_unchecked(&md->event_nr))); + } +=20 + void dm_uevent_add(struct mapped_device *md, struct list_head *elist) +diff --git a/drivers/md/md.c b/drivers/md/md.c +index 5c95ccb..217fa57 100644 +--- a/drivers/md/md.c ++++ b/drivers/md/md.c @@ -280,10 +280,10 @@ EXPORT_SYMBOL_GPL(md_trim_bio); * start build, activate spare */ @@ -30397,7 +31193,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c wake_up(&md_event_waiters); } =20 -@@ -1531,7 +1531,7 @@ static int super_1_load(mdk_rdev_t *rdev +@@ -1531,7 +1531,7 @@ static int super_1_load(mdk_rdev_t *rdev, mdk_rdev= _t *refdev, int minor_version) =20 rdev->preferred_minor =3D 0xffff; rdev->data_offset =3D le64_to_cpu(sb->data_offset); @@ -30406,7 +31202,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c =20 rdev->sb_size =3D le32_to_cpu(sb->max_dev) * 2 + 256; bmask =3D queue_logical_block_size(rdev->bdev->bd_disk->queue)-1; -@@ -1748,7 +1748,7 @@ static void super_1_sync(mddev_t *mddev, +@@ -1748,7 +1748,7 @@ static void super_1_sync(mddev_t *mddev, mdk_rdev_= t *rdev) else sb->resync_offset =3D cpu_to_le64(0); =20 @@ -30415,7 +31211,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c =20 sb->raid_disks =3D cpu_to_le32(mddev->raid_disks); sb->size =3D cpu_to_le64(mddev->dev_sectors); -@@ -2643,7 +2643,7 @@ __ATTR(state, S_IRUGO|S_IWUSR, state_sho +@@ -2643,7 +2643,7 @@ __ATTR(state, S_IRUGO|S_IWUSR, state_show, state_s= tore); static ssize_t errors_show(mdk_rdev_t *rdev, char *page) { @@ -30424,7 +31220,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c } =20 static ssize_t -@@ -2652,7 +2652,7 @@ errors_store(mdk_rdev_t *rdev, const cha +@@ -2652,7 +2652,7 @@ errors_store(mdk_rdev_t *rdev, const char *buf, si= ze_t len) char *e; unsigned long n =3D simple_strtoul(buf, &e, 10); if (*buf && (*e =3D=3D 0 || *e =3D=3D '\n')) { @@ -30444,7 +31240,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c =20 INIT_LIST_HEAD(&rdev->same_set); init_waitqueue_head(&rdev->blocked_wait); -@@ -6667,7 +6667,7 @@ static int md_seq_show(struct seq_file * +@@ -6667,7 +6667,7 @@ static int md_seq_show(struct seq_file *seq, void = *v) =20 spin_unlock(&pers_lock); seq_printf(seq, "\n"); @@ -30453,7 +31249,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c return 0; } if (v =3D=3D (void*)2) { -@@ -6756,7 +6756,7 @@ static int md_seq_show(struct seq_file * +@@ -6756,7 +6756,7 @@ static int md_seq_show(struct seq_file *seq, void = *v) chunk_kb ? "KB" : "B"); if (bitmap->file) { seq_printf(seq, ", file: "); @@ -30462,7 +31258,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c } =20 seq_printf(seq, "\n"); -@@ -6787,7 +6787,7 @@ static int md_seq_open(struct inode *ino +@@ -6787,7 +6787,7 @@ static int md_seq_open(struct inode *inode, struct= file *file) return error; =20 seq =3D file->private_data; @@ -30471,7 +31267,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c return error; } =20 -@@ -6801,7 +6801,7 @@ static unsigned int mdstat_poll(struct f +@@ -6801,7 +6801,7 @@ static unsigned int mdstat_poll(struct file *filp,= poll_table *wait) /* always allow read */ mask =3D POLLIN | POLLRDNORM; =20 @@ -30480,7 +31276,7 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1.= 4/drivers/md/md.c mask |=3D POLLERR | POLLPRI; return mask; } -@@ -6845,7 +6845,7 @@ static int is_mddev_idle(mddev_t *mddev, +@@ -6845,7 +6845,7 @@ static int is_mddev_idle(mddev_t *mddev, int init) struct gendisk *disk =3D rdev->bdev->bd_contains->bd_disk; curr_events =3D (int)part_stat_read(&disk->part0, sectors[0]) + (int)part_stat_read(&disk->part0, sectors[1]) - @@ -30489,9 +31285,10 @@ diff -urNp linux-3.1.4/drivers/md/md.c linux-3.1= .4/drivers/md/md.c /* sync IO will cause sync_io to increase before the disk_stats * as sync_io is counted when a request starts, and * disk_stats is counted when it completes. -diff -urNp linux-3.1.4/drivers/md/md.h linux-3.1.4/drivers/md/md.h ---- linux-3.1.4/drivers/md/md.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/md/md.h 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/md/md.h b/drivers/md/md.h +index 0a309dc..7e01d7f 100644 +--- a/drivers/md/md.h ++++ b/drivers/md/md.h @@ -124,13 +124,13 @@ struct mdk_rdev_s * only maintained for arrays that * support hot removal @@ -30508,7 +31305,7 @@ diff -urNp linux-3.1.4/drivers/md/md.h linux-3.1.= 4/drivers/md/md.h * for reporting to userspace and storing * in superblock. */ -@@ -415,7 +415,7 @@ static inline void rdev_dec_pending(mdk_ +@@ -415,7 +415,7 @@ static inline void rdev_dec_pending(mdk_rdev_t *rdev= , mddev_t *mddev) =20 static inline void md_sync_acct(struct block_device *bdev, unsigned lon= g nr_sectors) { @@ -30517,10 +31314,33 @@ diff -urNp linux-3.1.4/drivers/md/md.h linux-3.= 1.4/drivers/md/md.h } =20 struct mdk_personality -diff -urNp linux-3.1.4/drivers/md/raid10.c linux-3.1.4/drivers/md/raid10= .c ---- linux-3.1.4/drivers/md/raid10.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/md/raid10.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1423,7 +1423,7 @@ static void end_sync_read(struct bio *bi +diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c +index d9587df..83a0dc3 100644 +--- a/drivers/md/raid1.c ++++ b/drivers/md/raid1.c +@@ -1541,7 +1541,7 @@ static int fix_sync_read_error(r1bio_t *r1_bio) + if (r1_sync_page_io(rdev, sect, s, + bio->bi_io_vec[idx].bv_page, + READ) !=3D 0) +- atomic_add(s, &rdev->corrected_errors); ++ atomic_add_unchecked(s, &rdev->corrected_errors); + } + sectors -=3D s; + sect +=3D s; +@@ -1754,7 +1754,7 @@ static void fix_read_error(conf_t *conf, int read_= disk, + test_bit(In_sync, &rdev->flags)) { + if (r1_sync_page_io(rdev, sect, s, + conf->tmppage, READ)) { +- atomic_add(s, &rdev->corrected_errors); ++ atomic_add_unchecked(s, &rdev->corrected_errors); + printk(KERN_INFO + "md/raid1:%s: read error corrected " + "(%d sectors at %llu on %s)\n", +diff --git a/drivers/md/raid10.c b/drivers/md/raid10.c +index 1d44228..98db57d 100644 +--- a/drivers/md/raid10.c ++++ b/drivers/md/raid10.c +@@ -1423,7 +1423,7 @@ static void end_sync_read(struct bio *bio, int err= or) /* The write handler will notice the lack of * R10BIO_Uptodate and record any errors etc */ @@ -30529,7 +31349,7 @@ diff -urNp linux-3.1.4/drivers/md/raid10.c linux-= 3.1.4/drivers/md/raid10.c &conf->mirrors[d].rdev->corrected_errors); =20 /* for reconstruct, we always reschedule after a read. -@@ -1723,7 +1723,7 @@ static void check_decay_read_errors(mdde +@@ -1723,7 +1723,7 @@ static void check_decay_read_errors(mddev_t *mddev= , mdk_rdev_t *rdev) { struct timespec cur_time_mon; unsigned long hours_since_last; @@ -30538,7 +31358,7 @@ diff -urNp linux-3.1.4/drivers/md/raid10.c linux-= 3.1.4/drivers/md/raid10.c =20 ktime_get_ts(&cur_time_mon); =20 -@@ -1745,9 +1745,9 @@ static void check_decay_read_errors(mdde +@@ -1745,9 +1745,9 @@ static void check_decay_read_errors(mddev_t *mddev= , mdk_rdev_t *rdev) * overflowing the shift of read_errors by hours_since_last. */ if (hours_since_last >=3D 8 * sizeof(read_errors)) @@ -30550,7 +31370,7 @@ diff -urNp linux-3.1.4/drivers/md/raid10.c linux-= 3.1.4/drivers/md/raid10.c } =20 static int r10_sync_page_io(mdk_rdev_t *rdev, sector_t sector, -@@ -1797,8 +1797,8 @@ static void fix_read_error(conf_t *conf, +@@ -1797,8 +1797,8 @@ static void fix_read_error(conf_t *conf, mddev_t *= mddev, r10bio_t *r10_bio) return; =20 check_decay_read_errors(mddev, rdev); @@ -30561,7 +31381,7 @@ diff -urNp linux-3.1.4/drivers/md/raid10.c linux-= 3.1.4/drivers/md/raid10.c char b[BDEVNAME_SIZE]; bdevname(rdev->bdev, b); =20 -@@ -1806,7 +1806,7 @@ static void fix_read_error(conf_t *conf, +@@ -1806,7 +1806,7 @@ static void fix_read_error(conf_t *conf, mddev_t *= mddev, r10bio_t *r10_bio) "md/raid10:%s: %s: Raid device exceeded " "read_error threshold [cur %d:max %d]\n", mdname(mddev), b, @@ -30570,7 +31390,7 @@ diff -urNp linux-3.1.4/drivers/md/raid10.c linux-= 3.1.4/drivers/md/raid10.c printk(KERN_NOTICE "md/raid10:%s: %s: Failing raid device\n", mdname(mddev), b); -@@ -1951,7 +1951,7 @@ static void fix_read_error(conf_t *conf, +@@ -1951,7 +1951,7 @@ static void fix_read_error(conf_t *conf, mddev_t *= mddev, r10bio_t *r10_bio) (unsigned long long)( sect + rdev->data_offset), bdevname(rdev->bdev, b)); @@ -30579,31 +31399,11 @@ diff -urNp linux-3.1.4/drivers/md/raid10.c linu= x-3.1.4/drivers/md/raid10.c } =20 rdev_dec_pending(rdev, mddev); -diff -urNp linux-3.1.4/drivers/md/raid1.c linux-3.1.4/drivers/md/raid1.c ---- linux-3.1.4/drivers/md/raid1.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/md/raid1.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1541,7 +1541,7 @@ static int fix_sync_read_error(r1bio_t * - if (r1_sync_page_io(rdev, sect, s, - bio->bi_io_vec[idx].bv_page, - READ) !=3D 0) -- atomic_add(s, &rdev->corrected_errors); -+ atomic_add_unchecked(s, &rdev->corrected_errors); - } - sectors -=3D s; - sect +=3D s; -@@ -1754,7 +1754,7 @@ static void fix_read_error(conf_t *conf, - test_bit(In_sync, &rdev->flags)) { - if (r1_sync_page_io(rdev, sect, s, - conf->tmppage, READ)) { -- atomic_add(s, &rdev->corrected_errors); -+ atomic_add_unchecked(s, &rdev->corrected_errors); - printk(KERN_INFO - "md/raid1:%s: read error corrected " - "(%d sectors at %llu on %s)\n", -diff -urNp linux-3.1.4/drivers/md/raid5.c linux-3.1.4/drivers/md/raid5.c ---- linux-3.1.4/drivers/md/raid5.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/md/raid5.c 2011-11-16 18:40:10.000000000 -0500 -@@ -1616,19 +1616,19 @@ static void raid5_end_read_request(struc +diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c +index b6200c3..02e8702 100644 +--- a/drivers/md/raid5.c ++++ b/drivers/md/raid5.c +@@ -1616,19 +1616,19 @@ static void raid5_end_read_request(struct bio * = bi, int error) (unsigned long long)(sh->sector + rdev->data_offset), bdevname(rdev->bdev, b)); @@ -30627,7 +31427,7 @@ diff -urNp linux-3.1.4/drivers/md/raid5.c linux-3= .1.4/drivers/md/raid5.c if (conf->mddev->degraded >=3D conf->max_degraded) printk_ratelimited( KERN_WARNING -@@ -1648,7 +1648,7 @@ static void raid5_end_read_request(struc +@@ -1648,7 +1648,7 @@ static void raid5_end_read_request(struct bio * bi= , int error) (unsigned long long)(sh->sector + rdev->data_offset), bdn); @@ -30636,7 +31436,7 @@ diff -urNp linux-3.1.4/drivers/md/raid5.c linux-3= .1.4/drivers/md/raid5.c > conf->max_nr_stripes) printk(KERN_WARNING "md/raid:%s: Too many read errors, failing device %s.\n", -@@ -1978,6 +1978,7 @@ static sector_t compute_blocknr(struct s +@@ -1978,6 +1978,7 @@ static sector_t compute_blocknr(struct stripe_head= *sh, int i, int previous) sector_t r_sector; struct stripe_head sh2; =20 @@ -30644,10 +31444,11 @@ diff -urNp linux-3.1.4/drivers/md/raid5.c linux= -3.1.4/drivers/md/raid5.c =20 chunk_offset =3D sector_div(new_sector, sectors_per_chunk); stripe =3D new_sector; -diff -urNp linux-3.1.4/drivers/media/common/saa7146_hlp.c linux-3.1.4/dr= ivers/media/common/saa7146_hlp.c ---- linux-3.1.4/drivers/media/common/saa7146_hlp.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/media/common/saa7146_hlp.c 2011-11-16 18:40:10.0= 00000000 -0500 -@@ -353,6 +353,8 @@ static void calculate_clipping_registers +diff --git a/drivers/media/common/saa7146_hlp.c b/drivers/media/common/s= aa7146_hlp.c +index 1d1d8d2..6c6837a 100644 +--- a/drivers/media/common/saa7146_hlp.c ++++ b/drivers/media/common/saa7146_hlp.c +@@ -353,6 +353,8 @@ static void calculate_clipping_registers_rect(struct= saa7146_dev *dev, struct sa =20 int x[32], y[32], w[32], h[32]; =20 @@ -30656,9 +31457,10 @@ diff -urNp linux-3.1.4/drivers/media/common/saa7= 146_hlp.c linux-3.1.4/drivers/me /* clear out memory */ memset(&line_list[0], 0x00, sizeof(u32)*32); memset(&pixel_list[0], 0x00, sizeof(u32)*32); -diff -urNp linux-3.1.4/drivers/media/dvb/ddbridge/ddbridge-core.c linux-= 3.1.4/drivers/media/dvb/ddbridge/ddbridge-core.c ---- linux-3.1.4/drivers/media/dvb/ddbridge/ddbridge-core.c 2011-11-11 15= :19:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/ddbridge/ddbridge-core.c 2011-11-16 18= :39:07.000000000 -0500 +diff --git a/drivers/media/dvb/ddbridge/ddbridge-core.c b/drivers/media/= dvb/ddbridge/ddbridge-core.c +index 573d540..16f78f3 100644 +--- a/drivers/media/dvb/ddbridge/ddbridge-core.c ++++ b/drivers/media/dvb/ddbridge/ddbridge-core.c @@ -1675,7 +1675,7 @@ static struct ddb_info ddb_v6 =3D { .subvendor =3D _subvend, .subdevice =3D _subdev, \ .driver_data =3D (unsigned long)&_driverdata } @@ -30668,10 +31470,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/ddbrid= ge/ddbridge-core.c linux-3.1.4/dr DDB_ID(DDVID, 0x0002, DDVID, 0x0001, ddb_octopus), DDB_ID(DDVID, 0x0003, DDVID, 0x0001, ddb_octopus), DDB_ID(DDVID, 0x0003, DDVID, 0x0002, ddb_octopus_le), -diff -urNp linux-3.1.4/drivers/media/dvb/dvb-core/dvb_ca_en50221.c linux= -3.1.4/drivers/media/dvb/dvb-core/dvb_ca_en50221.c ---- linux-3.1.4/drivers/media/dvb/dvb-core/dvb_ca_en50221.c 2011-11-11 1= 5:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/dvb-core/dvb_ca_en50221.c 2011-11-16 1= 8:40:10.000000000 -0500 -@@ -590,6 +590,8 @@ static int dvb_ca_en50221_read_data(stru +diff --git a/drivers/media/dvb/dvb-core/dvb_ca_en50221.c b/drivers/media= /dvb/dvb-core/dvb_ca_en50221.c +index 7ea517b..252fe54 100644 +--- a/drivers/media/dvb/dvb-core/dvb_ca_en50221.c ++++ b/drivers/media/dvb/dvb-core/dvb_ca_en50221.c +@@ -590,6 +590,8 @@ static int dvb_ca_en50221_read_data(struct dvb_ca_pr= ivate *ca, int slot, u8 * eb u8 buf[HOST_LINK_BUF_SIZE]; int i; =20 @@ -30680,7 +31483,7 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-core= /dvb_ca_en50221.c linux-3.1.4/d dprintk("%s\n", __func__); =20 /* check if we have space for a link buf in the rx_buffer */ -@@ -1285,6 +1287,8 @@ static ssize_t dvb_ca_en50221_io_write(s +@@ -1285,6 +1287,8 @@ static ssize_t dvb_ca_en50221_io_write(struct file= *file, unsigned long timeout; int written; =20 @@ -30689,9 +31492,10 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-cor= e/dvb_ca_en50221.c linux-3.1.4/d dprintk("%s\n", __func__); =20 /* Incoming packet has a 2 byte header. hdr[0] =3D slot_id, hdr[1] =3D= connection_id */ -diff -urNp linux-3.1.4/drivers/media/dvb/dvb-core/dvb_demux.h linux-3.1.= 4/drivers/media/dvb/dvb-core/dvb_demux.h ---- linux-3.1.4/drivers/media/dvb/dvb-core/dvb_demux.h 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/dvb-core/dvb_demux.h 2011-11-17 18:34:= 32.000000000 -0500 +diff --git a/drivers/media/dvb/dvb-core/dvb_demux.h b/drivers/media/dvb/= dvb-core/dvb_demux.h +index a7d876f..8c21b61 100644 +--- a/drivers/media/dvb/dvb-core/dvb_demux.h ++++ b/drivers/media/dvb/dvb-core/dvb_demux.h @@ -73,7 +73,7 @@ struct dvb_demux_feed { union { dmx_ts_cb ts; @@ -30701,10 +31505,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-co= re/dvb_demux.h linux-3.1.4/driver =20 struct dvb_demux *demux; void *priv; -diff -urNp linux-3.1.4/drivers/media/dvb/dvb-core/dvbdev.c linux-3.1.4/d= rivers/media/dvb/dvb-core/dvbdev.c ---- linux-3.1.4/drivers/media/dvb/dvb-core/dvbdev.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/dvb-core/dvbdev.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -192,7 +192,7 @@ int dvb_register_device(struct dvb_adapt +diff --git a/drivers/media/dvb/dvb-core/dvbdev.c b/drivers/media/dvb/dvb= -core/dvbdev.c +index f732877..d38c35a 100644 +--- a/drivers/media/dvb/dvb-core/dvbdev.c ++++ b/drivers/media/dvb/dvb-core/dvbdev.c +@@ -192,7 +192,7 @@ int dvb_register_device(struct dvb_adapter *adap, st= ruct dvb_device **pdvbdev, const struct dvb_device *template, void *priv, int type) { struct dvb_device *dvbdev; @@ -30713,10 +31518,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-co= re/dvbdev.c linux-3.1.4/drivers/m struct device *clsdev; int minor; int id; -diff -urNp linux-3.1.4/drivers/media/dvb/dvb-usb/cxusb.c linux-3.1.4/dri= vers/media/dvb/dvb-usb/cxusb.c ---- linux-3.1.4/drivers/media/dvb/dvb-usb/cxusb.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/dvb-usb/cxusb.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -1059,7 +1059,7 @@ static struct dib0070_config dib7070p_di +diff --git a/drivers/media/dvb/dvb-usb/cxusb.c b/drivers/media/dvb/dvb-u= sb/cxusb.c +index acb5fb2..2413f1d 100644 +--- a/drivers/media/dvb/dvb-usb/cxusb.c ++++ b/drivers/media/dvb/dvb-usb/cxusb.c +@@ -1059,7 +1059,7 @@ static struct dib0070_config dib7070p_dib0070_conf= ig =3D { struct dib0700_adapter_state { int (*set_param_save) (struct dvb_frontend *, struct dvb_frontend_parameters *); @@ -30725,10 +31531,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-us= b/cxusb.c linux-3.1.4/drivers/med =20 static int dib7070_set_param_override(struct dvb_frontend *fe, struct dvb_frontend_parameters *fep) -diff -urNp linux-3.1.4/drivers/media/dvb/dvb-usb/dib0700_core.c linux-3.= 1.4/drivers/media/dvb/dvb-usb/dib0700_core.c ---- linux-3.1.4/drivers/media/dvb/dvb-usb/dib0700_core.c 2011-11-11 15:1= 9:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/dvb-usb/dib0700_core.c 2011-11-16 18:4= 0:10.000000000 -0500 -@@ -478,6 +478,8 @@ int dib0700_download_firmware(struct usb +diff --git a/drivers/media/dvb/dvb-usb/dib0700_core.c b/drivers/media/dv= b/dvb-usb/dib0700_core.c +index a224e94..503b76a 100644 +--- a/drivers/media/dvb/dvb-usb/dib0700_core.c ++++ b/drivers/media/dvb/dvb-usb/dib0700_core.c +@@ -478,6 +478,8 @@ int dib0700_download_firmware(struct usb_device *ude= v, const struct firmware *fw if (!buf) return -ENOMEM; =20 @@ -30737,9 +31544,10 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-usb= /dib0700_core.c linux-3.1.4/driv while ((ret =3D dvb_usb_get_hexline(fw, &hx, &pos)) > 0) { deb_fwdata("writing to address 0x%08x (buffer: 0x%02x %02x)\n", hx.addr, hx.len, hx.chk); -diff -urNp linux-3.1.4/drivers/media/dvb/dvb-usb/dw2102.c linux-3.1.4/dr= ivers/media/dvb/dvb-usb/dw2102.c ---- linux-3.1.4/drivers/media/dvb/dvb-usb/dw2102.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/dvb-usb/dw2102.c 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/drivers/media/dvb/dvb-usb/dw2102.c b/drivers/media/dvb/dvb-= usb/dw2102.c +index 058b231..183d2b3 100644 +--- a/drivers/media/dvb/dvb-usb/dw2102.c ++++ b/drivers/media/dvb/dvb-usb/dw2102.c @@ -95,7 +95,7 @@ struct su3000_state { =20 struct s6x0_state { @@ -30749,10 +31557,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-us= b/dw2102.c linux-3.1.4/drivers/me =20 /* debug */ static int dvb_usb_dw2102_debug; -diff -urNp linux-3.1.4/drivers/media/dvb/dvb-usb/lmedm04.c linux-3.1.4/d= rivers/media/dvb/dvb-usb/lmedm04.c ---- linux-3.1.4/drivers/media/dvb/dvb-usb/lmedm04.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/dvb-usb/lmedm04.c 2011-11-16 18:40:10.= 000000000 -0500 -@@ -742,6 +742,7 @@ static int lme2510_download_firmware(str +diff --git a/drivers/media/dvb/dvb-usb/lmedm04.c b/drivers/media/dvb/dvb= -usb/lmedm04.c +index 37b1469..28a6f6f 100644 +--- a/drivers/media/dvb/dvb-usb/lmedm04.c ++++ b/drivers/media/dvb/dvb-usb/lmedm04.c +@@ -742,6 +742,7 @@ static int lme2510_download_firmware(struct usb_devi= ce *dev, usb_control_msg(dev, usb_rcvctrlpipe(dev, 0), 0x06, 0x80, 0x0200, 0x00, data, 0x0109, 1000); =20 @@ -30760,7 +31569,7 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-usb/= lmedm04.c linux-3.1.4/drivers/m =20 data[0] =3D 0x8a; len_in =3D 1; -@@ -764,6 +765,8 @@ static void lme_coldreset(struct usb_dev +@@ -764,6 +765,8 @@ static void lme_coldreset(struct usb_device *dev) int ret =3D 0, len_in; u8 data[512] =3D {0}; =20 @@ -30769,9 +31578,10 @@ diff -urNp linux-3.1.4/drivers/media/dvb/dvb-usb= /lmedm04.c linux-3.1.4/drivers/m data[0] =3D 0x0a; len_in =3D 1; info("FRM Firmware Cold Reset"); -diff -urNp linux-3.1.4/drivers/media/dvb/frontends/dib3000.h linux-3.1.4= /drivers/media/dvb/frontends/dib3000.h ---- linux-3.1.4/drivers/media/dvb/frontends/dib3000.h 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/frontends/dib3000.h 2011-11-17 18:38:0= 5.000000000 -0500 +diff --git a/drivers/media/dvb/frontends/dib3000.h b/drivers/media/dvb/f= rontends/dib3000.h +index ba91735..4261d84 100644 +--- a/drivers/media/dvb/frontends/dib3000.h ++++ b/drivers/media/dvb/frontends/dib3000.h @@ -39,7 +39,7 @@ struct dib_fe_xfer_ops int (*fifo_ctrl)(struct dvb_frontend *fe, int onoff); int (*pid_ctrl)(struct dvb_frontend *fe, int index, int pid, int onoff= ); @@ -30781,10 +31591,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/fronte= nds/dib3000.h linux-3.1.4/drivers =20 #if defined(CONFIG_DVB_DIB3000MB) || (defined(CONFIG_DVB_DIB3000MB_MODU= LE) && defined(MODULE)) extern struct dvb_frontend* dib3000mb_attach(const struct dib3000_confi= g* config, -diff -urNp linux-3.1.4/drivers/media/dvb/frontends/mb86a16.c linux-3.1.4= /drivers/media/dvb/frontends/mb86a16.c ---- linux-3.1.4/drivers/media/dvb/frontends/mb86a16.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/frontends/mb86a16.c 2011-11-16 18:40:1= 0.000000000 -0500 -@@ -1060,6 +1060,8 @@ static int mb86a16_set_fe(struct mb86a16 +diff --git a/drivers/media/dvb/frontends/mb86a16.c b/drivers/media/dvb/f= rontends/mb86a16.c +index c283112..7f367a7 100644 +--- a/drivers/media/dvb/frontends/mb86a16.c ++++ b/drivers/media/dvb/frontends/mb86a16.c +@@ -1060,6 +1060,8 @@ static int mb86a16_set_fe(struct mb86a16_state *st= ate) int ret =3D -1; int sync; =20 @@ -30793,10 +31604,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/fronte= nds/mb86a16.c linux-3.1.4/drivers dprintk(verbose, MB86A16_INFO, 1, "freq=3D%d Mhz, symbrt=3D%d Ksps", s= tate->frequency, state->srate); =20 fcp =3D 3000; -diff -urNp linux-3.1.4/drivers/media/dvb/frontends/or51211.c linux-3.1.4= /drivers/media/dvb/frontends/or51211.c ---- linux-3.1.4/drivers/media/dvb/frontends/or51211.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/frontends/or51211.c 2011-11-16 18:40:1= 0.000000000 -0500 -@@ -113,6 +113,8 @@ static int or51211_load_firmware (struct +diff --git a/drivers/media/dvb/frontends/or51211.c b/drivers/media/dvb/f= rontends/or51211.c +index c709ce6..b3fe620 100644 +--- a/drivers/media/dvb/frontends/or51211.c ++++ b/drivers/media/dvb/frontends/or51211.c +@@ -113,6 +113,8 @@ static int or51211_load_firmware (struct dvb_fronten= d* fe, u8 tudata[585]; int i; =20 @@ -30805,10 +31617,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/fronte= nds/or51211.c linux-3.1.4/drivers dprintk("Firmware is %zd bytes\n",fw->size); =20 /* Get eprom data */ -diff -urNp linux-3.1.4/drivers/media/dvb/ngene/ngene-cards.c linux-3.1.4= /drivers/media/dvb/ngene/ngene-cards.c ---- linux-3.1.4/drivers/media/dvb/ngene/ngene-cards.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/media/dvb/ngene/ngene-cards.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -477,7 +477,7 @@ static struct ngene_info ngene_info_m780 +diff --git a/drivers/media/dvb/ngene/ngene-cards.c b/drivers/media/dvb/n= gene/ngene-cards.c +index 0564192..75b16f5 100644 +--- a/drivers/media/dvb/ngene/ngene-cards.c ++++ b/drivers/media/dvb/ngene/ngene-cards.c +@@ -477,7 +477,7 @@ static struct ngene_info ngene_info_m780 =3D { =20 /**********************************************************************= ******/ =20 @@ -30817,10 +31630,11 @@ diff -urNp linux-3.1.4/drivers/media/dvb/ngene/= ngene-cards.c linux-3.1.4/drivers NGENE_ID(0x18c3, 0xabc3, ngene_info_cineS2), NGENE_ID(0x18c3, 0xabc4, ngene_info_cineS2), NGENE_ID(0x18c3, 0xdb01, ngene_info_satixS2), -diff -urNp linux-3.1.4/drivers/media/radio/radio-cadet.c linux-3.1.4/dri= vers/media/radio/radio-cadet.c ---- linux-3.1.4/drivers/media/radio/radio-cadet.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/media/radio/radio-cadet.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -326,6 +326,8 @@ static ssize_t cadet_read(struct file *f +diff --git a/drivers/media/radio/radio-cadet.c b/drivers/media/radio/rad= io-cadet.c +index 16a089f..ab1667d 100644 +--- a/drivers/media/radio/radio-cadet.c ++++ b/drivers/media/radio/radio-cadet.c +@@ -326,6 +326,8 @@ static ssize_t cadet_read(struct file *file, char __= user *data, size_t count, lo unsigned char readbuf[RDS_BUFFER]; int i =3D 0; =20 @@ -30829,9 +31643,10 @@ diff -urNp linux-3.1.4/drivers/media/radio/radio= -cadet.c linux-3.1.4/drivers/med mutex_lock(&dev->lock); if (dev->rdsstat =3D=3D 0) { dev->rdsstat =3D 1; -diff -urNp linux-3.1.4/drivers/media/video/au0828/au0828.h linux-3.1.4/d= rivers/media/video/au0828/au0828.h ---- linux-3.1.4/drivers/media/video/au0828/au0828.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/media/video/au0828/au0828.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/drivers/media/video/au0828/au0828.h b/drivers/media/video/a= u0828/au0828.h +index 9cde353..8c6a1c3 100644 +--- a/drivers/media/video/au0828/au0828.h ++++ b/drivers/media/video/au0828/au0828.h @@ -191,7 +191,7 @@ struct au0828_dev { =20 /* I2C */ @@ -30841,10 +31656,11 @@ diff -urNp linux-3.1.4/drivers/media/video/au08= 28/au0828.h linux-3.1.4/drivers/m struct i2c_client i2c_client; u32 i2c_rc; =20 -diff -urNp linux-3.1.4/drivers/media/video/cx18/cx18-driver.c linux-3.1.= 4/drivers/media/video/cx18/cx18-driver.c ---- linux-3.1.4/drivers/media/video/cx18/cx18-driver.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/cx18/cx18-driver.c 2011-11-16 18:40:= 10.000000000 -0500 -@@ -327,6 +327,8 @@ void cx18_read_eeprom(struct cx18 *cx, s +diff --git a/drivers/media/video/cx18/cx18-driver.c b/drivers/media/vide= o/cx18/cx18-driver.c +index 9e2f870..22e3a08 100644 +--- a/drivers/media/video/cx18/cx18-driver.c ++++ b/drivers/media/video/cx18/cx18-driver.c +@@ -327,6 +327,8 @@ void cx18_read_eeprom(struct cx18 *cx, struct tveepr= om *tv) struct i2c_client c; u8 eedata[256]; =20 @@ -30853,10 +31669,11 @@ diff -urNp linux-3.1.4/drivers/media/video/cx18= /cx18-driver.c linux-3.1.4/driver memset(&c, 0, sizeof(c)); strlcpy(c.name, "cx18 tveeprom tmp", sizeof(c.name)); c.adapter =3D &cx->i2c_adap[0]; -diff -urNp linux-3.1.4/drivers/media/video/cx23885/cx23885-input.c linux= -3.1.4/drivers/media/video/cx23885/cx23885-input.c ---- linux-3.1.4/drivers/media/video/cx23885/cx23885-input.c 2011-11-11 1= 5:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/cx23885/cx23885-input.c 2011-11-16 1= 8:40:10.000000000 -0500 -@@ -53,6 +53,8 @@ static void cx23885_input_process_measur +diff --git a/drivers/media/video/cx23885/cx23885-input.c b/drivers/media= /video/cx23885/cx23885-input.c +index ce765e3..f9e1b04 100644 +--- a/drivers/media/video/cx23885/cx23885-input.c ++++ b/drivers/media/video/cx23885/cx23885-input.c +@@ -53,6 +53,8 @@ static void cx23885_input_process_measurements(struct = cx23885_dev *dev, bool handle =3D false; struct ir_raw_event ir_core_event[64]; =20 @@ -30865,10 +31682,11 @@ diff -urNp linux-3.1.4/drivers/media/video/cx23= 885/cx23885-input.c linux-3.1.4/d do { num =3D 0; v4l2_subdev_call(dev->sd_ir, ir, rx_read, (u8 *) ir_core_event, -diff -urNp linux-3.1.4/drivers/media/video/cx88/cx88-alsa.c linux-3.1.4/= drivers/media/video/cx88/cx88-alsa.c ---- linux-3.1.4/drivers/media/video/cx88/cx88-alsa.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/media/video/cx88/cx88-alsa.c 2011-11-16 18:39:07= .000000000 -0500 -@@ -766,7 +766,7 @@ static struct snd_kcontrol_new snd_cx88_ +diff --git a/drivers/media/video/cx88/cx88-alsa.c b/drivers/media/video/= cx88/cx88-alsa.c +index 68d1240..46b32eb 100644 +--- a/drivers/media/video/cx88/cx88-alsa.c ++++ b/drivers/media/video/cx88/cx88-alsa.c +@@ -766,7 +766,7 @@ static struct snd_kcontrol_new snd_cx88_alc_switch =3D= { * Only boards with eeprom and byte 1 at eeprom=3D1 have it */ =20 @@ -30877,10 +31695,11 @@ diff -urNp linux-3.1.4/drivers/media/video/cx88= /cx88-alsa.c linux-3.1.4/drivers/ {0x14f1,0x8801,PCI_ANY_ID,PCI_ANY_ID,0,0,0}, {0x14f1,0x8811,PCI_ANY_ID,PCI_ANY_ID,0,0,0}, {0, } -diff -urNp linux-3.1.4/drivers/media/video/pvrusb2/pvrusb2-eeprom.c linu= x-3.1.4/drivers/media/video/pvrusb2/pvrusb2-eeprom.c ---- linux-3.1.4/drivers/media/video/pvrusb2/pvrusb2-eeprom.c 2011-11-11 = 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/pvrusb2/pvrusb2-eeprom.c 2011-11-16 = 18:40:10.000000000 -0500 -@@ -120,6 +120,8 @@ int pvr2_eeprom_analyze(struct pvr2_hdw=20 +diff --git a/drivers/media/video/pvrusb2/pvrusb2-eeprom.c b/drivers/medi= a/video/pvrusb2/pvrusb2-eeprom.c +index 9515f3a..c9ecb85 100644 +--- a/drivers/media/video/pvrusb2/pvrusb2-eeprom.c ++++ b/drivers/media/video/pvrusb2/pvrusb2-eeprom.c +@@ -120,6 +120,8 @@ int pvr2_eeprom_analyze(struct pvr2_hdw *hdw) u8 *eeprom; struct tveeprom tvdata; =20 @@ -30889,9 +31708,10 @@ diff -urNp linux-3.1.4/drivers/media/video/pvrus= b2/pvrusb2-eeprom.c linux-3.1.4/ memset(&tvdata,0,sizeof(tvdata)); =20 eeprom =3D pvr2_eeprom_fetch(hdw); -diff -urNp linux-3.1.4/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.= h linux-3.1.4/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h ---- linux-3.1.4/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h 2011-= 11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h 2011-= 11-16 18:39:07.000000000 -0500 +diff --git a/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h b/driver= s/media/video/pvrusb2/pvrusb2-hdw-internal.h +index 305e6aa..0143317 100644 +--- a/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h ++++ b/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h @@ -196,7 +196,7 @@ struct pvr2_hdw { =20 /* I2C stuff */ @@ -30901,10 +31721,11 @@ diff -urNp linux-3.1.4/drivers/media/video/pvru= sb2/pvrusb2-hdw-internal.h linux- pvr2_i2c_func i2c_func[PVR2_I2C_FUNC_CNT]; int i2c_cx25840_hack_state; int i2c_linked; -diff -urNp linux-3.1.4/drivers/media/video/saa7134/saa6752hs.c linux-3.1= .4/drivers/media/video/saa7134/saa6752hs.c ---- linux-3.1.4/drivers/media/video/saa7134/saa6752hs.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/saa7134/saa6752hs.c 2011-11-16 18:40= :10.000000000 -0500 -@@ -682,6 +682,8 @@ static int saa6752hs_init(struct v4l2_su +diff --git a/drivers/media/video/saa7134/saa6752hs.c b/drivers/media/vid= eo/saa7134/saa6752hs.c +index f9f29cc..5a2e330 100644 +--- a/drivers/media/video/saa7134/saa6752hs.c ++++ b/drivers/media/video/saa7134/saa6752hs.c +@@ -682,6 +682,8 @@ static int saa6752hs_init(struct v4l2_subdev *sd, u3= 2 leading_null_bytes) unsigned char localPAT[256]; unsigned char localPMT[256]; =20 @@ -30913,10 +31734,11 @@ diff -urNp linux-3.1.4/drivers/media/video/saa7= 134/saa6752hs.c linux-3.1.4/drive /* Set video format - must be done first as it resets other settings *= / set_reg8(client, 0x41, h->video_format); =20 -diff -urNp linux-3.1.4/drivers/media/video/saa7164/saa7164-cmd.c linux-3= .1.4/drivers/media/video/saa7164/saa7164-cmd.c ---- linux-3.1.4/drivers/media/video/saa7164/saa7164-cmd.c 2011-11-11 15:= 19:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/saa7164/saa7164-cmd.c 2011-11-16 18:= 40:10.000000000 -0500 -@@ -88,6 +88,8 @@ int saa7164_irq_dequeue(struct saa7164_d +diff --git a/drivers/media/video/saa7164/saa7164-cmd.c b/drivers/media/v= ideo/saa7164/saa7164-cmd.c +index 62fac7f..f29e0b9 100644 +--- a/drivers/media/video/saa7164/saa7164-cmd.c ++++ b/drivers/media/video/saa7164/saa7164-cmd.c +@@ -88,6 +88,8 @@ int saa7164_irq_dequeue(struct saa7164_dev *dev) u8 tmp[512]; dprintk(DBGLVL_CMD, "%s()\n", __func__); =20 @@ -30925,7 +31747,7 @@ diff -urNp linux-3.1.4/drivers/media/video/saa716= 4/saa7164-cmd.c linux-3.1.4/dri /* While any outstand message on the bus exists... */ do { =20 -@@ -141,6 +143,8 @@ int saa7164_cmd_dequeue(struct saa7164_d +@@ -141,6 +143,8 @@ int saa7164_cmd_dequeue(struct saa7164_dev *dev) u8 tmp[512]; dprintk(DBGLVL_CMD, "%s()\n", __func__); =20 @@ -30934,10 +31756,11 @@ diff -urNp linux-3.1.4/drivers/media/video/saa7= 164/saa7164-cmd.c linux-3.1.4/dri while (loop) { =20 struct tmComResInfo tRsp =3D { 0, 0, 0, 0, 0, 0 }; -diff -urNp linux-3.1.4/drivers/media/video/timblogiw.c linux-3.1.4/drive= rs/media/video/timblogiw.c ---- linux-3.1.4/drivers/media/video/timblogiw.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/media/video/timblogiw.c 2011-11-17 18:36:32.0000= 00000 -0500 -@@ -744,7 +744,7 @@ static int timblogiw_mmap(struct file *f +diff --git a/drivers/media/video/timblogiw.c b/drivers/media/video/timbl= ogiw.c +index 84cd1b6..f741e07 100644 +--- a/drivers/media/video/timblogiw.c ++++ b/drivers/media/video/timblogiw.c +@@ -744,7 +744,7 @@ static int timblogiw_mmap(struct file *file, struct = vm_area_struct *vma) =20 /* Platform device functions */ =20 @@ -30946,7 +31769,7 @@ diff -urNp linux-3.1.4/drivers/media/video/timblo= giw.c linux-3.1.4/drivers/media .vidioc_querycap =3D timblogiw_querycap, .vidioc_enum_fmt_vid_cap =3D timblogiw_enum_fmt, .vidioc_g_fmt_vid_cap =3D timblogiw_g_fmt, -@@ -766,7 +766,7 @@ static __devinitconst struct v4l2_ioctl_ +@@ -766,7 +766,7 @@ static __devinitconst struct v4l2_ioctl_ops timblogi= w_ioctl_ops =3D { .vidioc_enum_framesizes =3D timblogiw_enum_framesizes, }; =20 @@ -30955,10 +31778,11 @@ diff -urNp linux-3.1.4/drivers/media/video/timb= logiw.c linux-3.1.4/drivers/media .owner =3D THIS_MODULE, .open =3D timblogiw_open, .release =3D timblogiw_close, -diff -urNp linux-3.1.4/drivers/media/video/usbvision/usbvision-core.c li= nux-3.1.4/drivers/media/video/usbvision/usbvision-core.c ---- linux-3.1.4/drivers/media/video/usbvision/usbvision-core.c 2011-11-1= 1 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/usbvision/usbvision-core.c 2011-11-1= 6 18:40:10.000000000 -0500 -@@ -707,6 +707,8 @@ static enum parse_state usbvision_parse_ +diff --git a/drivers/media/video/usbvision/usbvision-core.c b/drivers/me= dia/video/usbvision/usbvision-core.c +index f344411..6ae9974 100644 +--- a/drivers/media/video/usbvision/usbvision-core.c ++++ b/drivers/media/video/usbvision/usbvision-core.c +@@ -707,6 +707,8 @@ static enum parse_state usbvision_parse_compress(str= uct usb_usbvision *usbvision unsigned char rv, gv, bv; static unsigned char *Y, *U, *V; =20 @@ -30967,9 +31791,10 @@ diff -urNp linux-3.1.4/drivers/media/video/usbvi= sion/usbvision-core.c linux-3.1. frame =3D usbvision->cur_frame; image_size =3D frame->frmwidth * frame->frmheight; if ((frame->v4l2_format.format =3D=3D V4L2_PIX_FMT_YUV422P) || -diff -urNp linux-3.1.4/drivers/media/video/videobuf-dma-sg.c linux-3.1.4= /drivers/media/video/videobuf-dma-sg.c ---- linux-3.1.4/drivers/media/video/videobuf-dma-sg.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/media/video/videobuf-dma-sg.c 2011-11-16 18:40:1= 0.000000000 -0500 +diff --git a/drivers/media/video/videobuf-dma-sg.c b/drivers/media/video= /videobuf-dma-sg.c +index f300dea..04834ba 100644 +--- a/drivers/media/video/videobuf-dma-sg.c ++++ b/drivers/media/video/videobuf-dma-sg.c @@ -607,6 +607,8 @@ void *videobuf_sg_alloc(size_t size) { struct videobuf_queue q; @@ -30979,10 +31804,11 @@ diff -urNp linux-3.1.4/drivers/media/video/vide= obuf-dma-sg.c linux-3.1.4/drivers /* Required to make generic handler to call __videobuf_alloc */ q.int_ops =3D &sg_ops; =20 -diff -urNp linux-3.1.4/drivers/message/fusion/mptbase.c linux-3.1.4/driv= ers/message/fusion/mptbase.c ---- linux-3.1.4/drivers/message/fusion/mptbase.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/message/fusion/mptbase.c 2011-11-16 18:40:10.000= 000000 -0500 -@@ -6681,8 +6681,13 @@ static int mpt_iocinfo_proc_show(struct=20 +diff --git a/drivers/message/fusion/mptbase.c b/drivers/message/fusion/m= ptbase.c +index 7956a10..f39232f 100644 +--- a/drivers/message/fusion/mptbase.c ++++ b/drivers/message/fusion/mptbase.c +@@ -6681,8 +6681,13 @@ static int mpt_iocinfo_proc_show(struct seq_file = *m, void *v) seq_printf(m, " MaxChainDepth =3D 0x%02x frames\n", ioc->facts.MaxCha= inDepth); seq_printf(m, " MinBlockSize =3D 0x%02x bytes\n", 4*ioc->facts.BlockS= ize); =20 @@ -30996,10 +31822,11 @@ diff -urNp linux-3.1.4/drivers/message/fusion/m= ptbase.c linux-3.1.4/drivers/mess /* * Rounding UP to nearest 4-kB boundary here... */ -diff -urNp linux-3.1.4/drivers/message/fusion/mptsas.c linux-3.1.4/drive= rs/message/fusion/mptsas.c ---- linux-3.1.4/drivers/message/fusion/mptsas.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/message/fusion/mptsas.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -439,6 +439,23 @@ mptsas_is_end_device(struct mptsas_devin +diff --git a/drivers/message/fusion/mptsas.c b/drivers/message/fusion/mp= tsas.c +index 7596aec..f7ae9aa 100644 +--- a/drivers/message/fusion/mptsas.c ++++ b/drivers/message/fusion/mptsas.c +@@ -439,6 +439,23 @@ mptsas_is_end_device(struct mptsas_devinfo * attach= ed) return 0; } =20 @@ -31023,7 +31850,7 @@ diff -urNp linux-3.1.4/drivers/message/fusion/mpt= sas.c linux-3.1.4/drivers/messa /* no mutex */ static void mptsas_port_delete(MPT_ADAPTER *ioc, struct mptsas_portinfo_details * p= ort_details) -@@ -477,23 +494,6 @@ mptsas_get_rphy(struct mptsas_phyinfo *p +@@ -477,23 +494,6 @@ mptsas_get_rphy(struct mptsas_phyinfo *phy_info) return NULL; } =20 @@ -31047,9 +31874,10 @@ diff -urNp linux-3.1.4/drivers/message/fusion/mp= tsas.c linux-3.1.4/drivers/messa static inline struct sas_port * mptsas_get_port(struct mptsas_phyinfo *phy_info) { -diff -urNp linux-3.1.4/drivers/message/fusion/mptscsih.c linux-3.1.4/dri= vers/message/fusion/mptscsih.c ---- linux-3.1.4/drivers/message/fusion/mptscsih.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/message/fusion/mptscsih.c 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/drivers/message/fusion/mptscsih.c b/drivers/message/fusion/= mptscsih.c +index ce61a57..3da8862 100644 +--- a/drivers/message/fusion/mptscsih.c ++++ b/drivers/message/fusion/mptscsih.c @@ -1268,15 +1268,16 @@ mptscsih_info(struct Scsi_Host *SChost) =20 h =3D shost_priv(SChost); @@ -31075,10 +31903,11 @@ diff -urNp linux-3.1.4/drivers/message/fusion/m= ptscsih.c linux-3.1.4/drivers/mes =20 return h->info_kbuf; } -diff -urNp linux-3.1.4/drivers/message/i2o/i2o_config.c linux-3.1.4/driv= ers/message/i2o/i2o_config.c ---- linux-3.1.4/drivers/message/i2o/i2o_config.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/message/i2o/i2o_config.c 2011-11-16 18:40:10.000= 000000 -0500 -@@ -781,6 +781,8 @@ static int i2o_cfg_passthru(unsigned lon +diff --git a/drivers/message/i2o/i2o_config.c b/drivers/message/i2o/i2o_= config.c +index 098de2b..fbb922c 100644 +--- a/drivers/message/i2o/i2o_config.c ++++ b/drivers/message/i2o/i2o_config.c +@@ -781,6 +781,8 @@ static int i2o_cfg_passthru(unsigned long arg) struct i2o_message *msg; unsigned int iop; =20 @@ -31087,9 +31916,10 @@ diff -urNp linux-3.1.4/drivers/message/i2o/i2o_c= onfig.c linux-3.1.4/drivers/mess if (get_user(iop, &cmd->iop) || get_user(user_msg, &cmd->msg)) return -EFAULT; =20 -diff -urNp linux-3.1.4/drivers/message/i2o/i2o_proc.c linux-3.1.4/driver= s/message/i2o/i2o_proc.c ---- linux-3.1.4/drivers/message/i2o/i2o_proc.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/message/i2o/i2o_proc.c 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/drivers/message/i2o/i2o_proc.c b/drivers/message/i2o/i2o_pr= oc.c +index 07dbeaf..5533142 100644 +--- a/drivers/message/i2o/i2o_proc.c ++++ b/drivers/message/i2o/i2o_proc.c @@ -255,13 +255,6 @@ static char *scsi_devices[] =3D { "Array Controller Device" }; @@ -31104,7 +31934,7 @@ diff -urNp linux-3.1.4/drivers/message/i2o/i2o_pr= oc.c linux-3.1.4/drivers/messag static int i2o_report_query_status(struct seq_file *seq, int block_stat= us, char *group) { -@@ -838,8 +831,7 @@ static int i2o_seq_show_ddm_table(struct +@@ -838,8 +831,7 @@ static int i2o_seq_show_ddm_table(struct seq_file *s= eq, void *v) =20 seq_printf(seq, "%-#7x", ddm_table.i2o_vendor_id); seq_printf(seq, "%-#8x", ddm_table.module_id); @@ -31114,7 +31944,7 @@ diff -urNp linux-3.1.4/drivers/message/i2o/i2o_pr= oc.c linux-3.1.4/drivers/messag seq_printf(seq, "%9d ", ddm_table.data_size); seq_printf(seq, "%8d", ddm_table.code_size); =20 -@@ -940,8 +932,8 @@ static int i2o_seq_show_drivers_stored(s +@@ -940,8 +932,8 @@ static int i2o_seq_show_drivers_stored(struct seq_fi= le *seq, void *v) =20 seq_printf(seq, "%-#7x", dst->i2o_vendor_id); seq_printf(seq, "%-#8x", dst->module_id); @@ -31125,7 +31955,7 @@ diff -urNp linux-3.1.4/drivers/message/i2o/i2o_pr= oc.c linux-3.1.4/drivers/messag seq_printf(seq, "%8d ", dst->module_size); seq_printf(seq, "%8d ", dst->mpb_size); seq_printf(seq, "0x%04x", dst->module_flags); -@@ -1272,14 +1264,10 @@ static int i2o_seq_show_dev_identity(str +@@ -1272,14 +1264,10 @@ static int i2o_seq_show_dev_identity(struct seq_= file *seq, void *v) seq_printf(seq, "Device Class : %s\n", i2o_get_class_name(work16[0]))= ; seq_printf(seq, "Owner TID : %0#5x\n", work16[2]); seq_printf(seq, "Parent TID : %0#5x\n", work16[3]); @@ -31144,7 +31974,7 @@ diff -urNp linux-3.1.4/drivers/message/i2o/i2o_pr= oc.c linux-3.1.4/drivers/messag =20 seq_printf(seq, "Serial number : "); print_serial_number(seq, (u8 *) (work32 + 16), -@@ -1324,10 +1312,8 @@ static int i2o_seq_show_ddm_identity(str +@@ -1324,10 +1312,8 @@ static int i2o_seq_show_ddm_identity(struct seq_f= ile *seq, void *v) } =20 seq_printf(seq, "Registering DDM TID : 0x%03x\n", result.ddm_tid); @@ -31157,7 +31987,7 @@ diff -urNp linux-3.1.4/drivers/message/i2o/i2o_pr= oc.c linux-3.1.4/drivers/messag =20 seq_printf(seq, "Serial number : "); print_serial_number(seq, result.serial_number, sizeof(result) - 36); -@@ -1358,14 +1344,10 @@ static int i2o_seq_show_uinfo(struct seq +@@ -1358,14 +1344,10 @@ static int i2o_seq_show_uinfo(struct seq_file *s= eq, void *v) return 0; } =20 @@ -31176,10 +32006,11 @@ diff -urNp linux-3.1.4/drivers/message/i2o/i2o_= proc.c linux-3.1.4/drivers/messag =20 return 0; } -diff -urNp linux-3.1.4/drivers/message/i2o/iop.c linux-3.1.4/drivers/mes= sage/i2o/iop.c ---- linux-3.1.4/drivers/message/i2o/iop.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/message/i2o/iop.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -111,10 +111,10 @@ u32 i2o_cntxt_list_add(struct i2o_contro +diff --git a/drivers/message/i2o/iop.c b/drivers/message/i2o/iop.c +index a8c08f3..155fe3d 100644 +--- a/drivers/message/i2o/iop.c ++++ b/drivers/message/i2o/iop.c +@@ -111,10 +111,10 @@ u32 i2o_cntxt_list_add(struct i2o_controller * c, = void *ptr) =20 spin_lock_irqsave(&c->context_list_lock, flags); =20 @@ -31193,7 +32024,7 @@ diff -urNp linux-3.1.4/drivers/message/i2o/iop.c = linux-3.1.4/drivers/message/i2o =20 list_add(&entry->list, &c->context_list); =20 -@@ -1077,7 +1077,7 @@ struct i2o_controller *i2o_iop_alloc(voi +@@ -1077,7 +1077,7 @@ struct i2o_controller *i2o_iop_alloc(void) =20 #if BITS_PER_LONG =3D=3D 64 spin_lock_init(&c->context_list_lock); @@ -31202,9 +32033,10 @@ diff -urNp linux-3.1.4/drivers/message/i2o/iop.c= linux-3.1.4/drivers/message/i2o INIT_LIST_HEAD(&c->context_list); #endif =20 -diff -urNp linux-3.1.4/drivers/mfd/ab3100-core.c linux-3.1.4/drivers/mfd= /ab3100-core.c ---- linux-3.1.4/drivers/mfd/ab3100-core.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/mfd/ab3100-core.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/drivers/mfd/ab3100-core.c b/drivers/mfd/ab3100-core.c +index a20e1c4..4f57255 100644 +--- a/drivers/mfd/ab3100-core.c ++++ b/drivers/mfd/ab3100-core.c @@ -809,7 +809,7 @@ struct ab_family_id { char *name; }; @@ -31214,9 +32046,10 @@ diff -urNp linux-3.1.4/drivers/mfd/ab3100-core.c= linux-3.1.4/drivers/mfd/ab3100- /* AB3100 */ { .id =3D 0xc0, -diff -urNp linux-3.1.4/drivers/mfd/abx500-core.c linux-3.1.4/drivers/mfd= /abx500-core.c ---- linux-3.1.4/drivers/mfd/abx500-core.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/mfd/abx500-core.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/drivers/mfd/abx500-core.c b/drivers/mfd/abx500-core.c +index f12720d..3c251fd 100644 +--- a/drivers/mfd/abx500-core.c ++++ b/drivers/mfd/abx500-core.c @@ -14,7 +14,7 @@ static LIST_HEAD(abx500_list); =20 struct abx500_device_entry { @@ -31226,9 +32059,10 @@ diff -urNp linux-3.1.4/drivers/mfd/abx500-core.c= linux-3.1.4/drivers/mfd/abx500- struct device *dev; }; =20 -diff -urNp linux-3.1.4/drivers/mfd/janz-cmodio.c linux-3.1.4/drivers/mfd= /janz-cmodio.c ---- linux-3.1.4/drivers/mfd/janz-cmodio.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/mfd/janz-cmodio.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/drivers/mfd/janz-cmodio.c b/drivers/mfd/janz-cmodio.c +index 5c2a06a..8fa077c 100644 +--- a/drivers/mfd/janz-cmodio.c ++++ b/drivers/mfd/janz-cmodio.c @@ -13,6 +13,7 @@ =20 #include @@ -31237,10 +32071,11 @@ diff -urNp linux-3.1.4/drivers/mfd/janz-cmodio.= c linux-3.1.4/drivers/mfd/janz-cm #include #include #include -diff -urNp linux-3.1.4/drivers/mfd/wm8350-i2c.c linux-3.1.4/drivers/mfd/= wm8350-i2c.c ---- linux-3.1.4/drivers/mfd/wm8350-i2c.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/mfd/wm8350-i2c.c 2011-11-16 18:40:10.000000000 -= 0500 -@@ -44,6 +44,8 @@ static int wm8350_i2c_write_device(struc +diff --git a/drivers/mfd/wm8350-i2c.c b/drivers/mfd/wm8350-i2c.c +index 5fe5de1..af64f53 100644 +--- a/drivers/mfd/wm8350-i2c.c ++++ b/drivers/mfd/wm8350-i2c.c +@@ -44,6 +44,8 @@ static int wm8350_i2c_write_device(struct wm8350 *wm83= 50, char reg, u8 msg[(WM8350_MAX_REGISTER << 1) + 1]; int ret; =20 @@ -31249,10 +32084,11 @@ diff -urNp linux-3.1.4/drivers/mfd/wm8350-i2c.c= linux-3.1.4/drivers/mfd/wm8350-i if (bytes > ((WM8350_MAX_REGISTER << 1) + 1)) return -EINVAL; =20 -diff -urNp linux-3.1.4/drivers/misc/lis3lv02d/lis3lv02d.c linux-3.1.4/dr= ivers/misc/lis3lv02d/lis3lv02d.c ---- linux-3.1.4/drivers/misc/lis3lv02d/lis3lv02d.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/misc/lis3lv02d/lis3lv02d.c 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -437,7 +437,7 @@ static irqreturn_t lis302dl_interrupt(in +diff --git a/drivers/misc/lis3lv02d/lis3lv02d.c b/drivers/misc/lis3lv02d= /lis3lv02d.c +index 8b51cd6..f628f8d 100644 +--- a/drivers/misc/lis3lv02d/lis3lv02d.c ++++ b/drivers/misc/lis3lv02d/lis3lv02d.c +@@ -437,7 +437,7 @@ static irqreturn_t lis302dl_interrupt(int irq, void = *dummy) * the lid is closed. This leads to interrupts as soon as a little mov= e * is done. */ @@ -31261,7 +32097,7 @@ diff -urNp linux-3.1.4/drivers/misc/lis3lv02d/lis= 3lv02d.c linux-3.1.4/drivers/mi =20 wake_up_interruptible(&lis3_dev.misc_wait); kill_fasync(&lis3_dev.async_queue, SIGIO, POLL_IN); -@@ -520,7 +520,7 @@ static int lis3lv02d_misc_open(struct in +@@ -520,7 +520,7 @@ static int lis3lv02d_misc_open(struct inode *inode, = struct file *file) if (lis3_dev.pm_dev) pm_runtime_get_sync(lis3_dev.pm_dev); =20 @@ -31270,7 +32106,7 @@ diff -urNp linux-3.1.4/drivers/misc/lis3lv02d/lis= 3lv02d.c linux-3.1.4/drivers/mi return 0; } =20 -@@ -547,7 +547,7 @@ static ssize_t lis3lv02d_misc_read(struc +@@ -547,7 +547,7 @@ static ssize_t lis3lv02d_misc_read(struct file *file= , char __user *buf, add_wait_queue(&lis3_dev.misc_wait, &wait); while (true) { set_current_state(TASK_INTERRUPTIBLE); @@ -31288,9 +32124,10 @@ diff -urNp linux-3.1.4/drivers/misc/lis3lv02d/li= s3lv02d.c linux-3.1.4/drivers/mi return POLLIN | POLLRDNORM; return 0; } -diff -urNp linux-3.1.4/drivers/misc/lis3lv02d/lis3lv02d.h linux-3.1.4/dr= ivers/misc/lis3lv02d/lis3lv02d.h ---- linux-3.1.4/drivers/misc/lis3lv02d/lis3lv02d.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/misc/lis3lv02d/lis3lv02d.h 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/drivers/misc/lis3lv02d/lis3lv02d.h b/drivers/misc/lis3lv02d= /lis3lv02d.h +index a193958..4d7ecd2 100644 +--- a/drivers/misc/lis3lv02d/lis3lv02d.h ++++ b/drivers/misc/lis3lv02d/lis3lv02d.h @@ -265,7 +265,7 @@ struct lis3lv02d { struct input_polled_dev *idev; /* input device */ struct platform_device *pdev; /* platform device */ @@ -31300,10 +32137,11 @@ diff -urNp linux-3.1.4/drivers/misc/lis3lv02d/l= is3lv02d.h linux-3.1.4/drivers/mi union axis_conversion ac; /* hw -> logical axis */ int mapped_btns[3]; =20 -diff -urNp linux-3.1.4/drivers/misc/sgi-gru/gruhandles.c linux-3.1.4/dri= vers/misc/sgi-gru/gruhandles.c ---- linux-3.1.4/drivers/misc/sgi-gru/gruhandles.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/misc/sgi-gru/gruhandles.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -44,8 +44,8 @@ static void update_mcs_stats(enum mcs_op +diff --git a/drivers/misc/sgi-gru/gruhandles.c b/drivers/misc/sgi-gru/gr= uhandles.c +index 2f30bad..c4c13d0 100644 +--- a/drivers/misc/sgi-gru/gruhandles.c ++++ b/drivers/misc/sgi-gru/gruhandles.c +@@ -44,8 +44,8 @@ static void update_mcs_stats(enum mcs_op op, unsigned = long clks) unsigned long nsec; =20 nsec =3D CLKS2NSEC(clks); @@ -31314,9 +32152,10 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-gru/gruh= andles.c linux-3.1.4/drivers/mis if (mcs_op_statistics[op].max < nsec) mcs_op_statistics[op].max =3D nsec; } -diff -urNp linux-3.1.4/drivers/misc/sgi-gru/gruprocfs.c linux-3.1.4/driv= ers/misc/sgi-gru/gruprocfs.c ---- linux-3.1.4/drivers/misc/sgi-gru/gruprocfs.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/misc/sgi-gru/gruprocfs.c 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/drivers/misc/sgi-gru/gruprocfs.c b/drivers/misc/sgi-gru/gru= procfs.c +index 7768b87..f8aac38 100644 +--- a/drivers/misc/sgi-gru/gruprocfs.c ++++ b/drivers/misc/sgi-gru/gruprocfs.c @@ -32,9 +32,9 @@ =20 #define printstat(s, f) printstat_val(s, &gru_stats.f, #f) @@ -31329,7 +32168,7 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-gru/grupr= ocfs.c linux-3.1.4/drivers/misc =20 seq_printf(s, "%16lu %s\n", val, id); } -@@ -134,8 +134,8 @@ static int mcs_statistics_show(struct se +@@ -134,8 +134,8 @@ static int mcs_statistics_show(struct seq_file *s, v= oid *p) =20 seq_printf(s, "%-20s%12s%12s%12s\n", "#id", "count", "aver-clks", "max= -clks"); for (op =3D 0; op < mcsop_last; op++) { @@ -31340,9 +32179,10 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-gru/grup= rocfs.c linux-3.1.4/drivers/misc max =3D mcs_op_statistics[op].max; seq_printf(s, "%-20s%12ld%12ld%12ld\n", id[op], count, count ? total / count : 0, max); -diff -urNp linux-3.1.4/drivers/misc/sgi-gru/grutables.h linux-3.1.4/driv= ers/misc/sgi-gru/grutables.h ---- linux-3.1.4/drivers/misc/sgi-gru/grutables.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/misc/sgi-gru/grutables.h 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/drivers/misc/sgi-gru/grutables.h b/drivers/misc/sgi-gru/gru= tables.h +index 5c3ce24..4915ccb 100644 +--- a/drivers/misc/sgi-gru/grutables.h ++++ b/drivers/misc/sgi-gru/grutables.h @@ -167,82 +167,82 @@ extern unsigned int gru_max_gids; * GRU statistics. */ @@ -31502,7 +32342,7 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-gru/gruta= bles.h linux-3.1.4/drivers/misc =20 }; =20 -@@ -251,8 +251,8 @@ enum mcs_op {cchop_allocate, cchop_start +@@ -251,8 +251,8 @@ enum mcs_op {cchop_allocate, cchop_start, cchop_inte= rrupt, cchop_interrupt_sync, tghop_invalidate, mcsop_last}; =20 struct mcs_op_statistic { @@ -31513,7 +32353,7 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-gru/gruta= bles.h linux-3.1.4/drivers/misc unsigned long max; }; =20 -@@ -275,7 +275,7 @@ extern struct mcs_op_statistic mcs_op_st +@@ -275,7 +275,7 @@ extern struct mcs_op_statistic mcs_op_statistics[mcs= op_last]; =20 #define STAT(id) do { \ if (gru_options & OPT_STATS) \ @@ -31522,9 +32362,23 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-gru/grut= ables.h linux-3.1.4/drivers/misc } while (0) =20 #ifdef CONFIG_SGI_GRU_DEBUG -diff -urNp linux-3.1.4/drivers/misc/sgi-xp/xpc.h linux-3.1.4/drivers/mis= c/sgi-xp/xpc.h ---- linux-3.1.4/drivers/misc/sgi-xp/xpc.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/misc/sgi-xp/xpc.h 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/drivers/misc/sgi-xp/xp.h b/drivers/misc/sgi-xp/xp.h +index 851b2f2..a4ec097 100644 +--- a/drivers/misc/sgi-xp/xp.h ++++ b/drivers/misc/sgi-xp/xp.h +@@ -289,7 +289,7 @@ struct xpc_interface { + xpc_notify_func, void *); + void (*received) (short, int, void *); + enum xp_retval (*partid_to_nasids) (short, void *); +-}; ++} __no_const; +=20 + extern struct xpc_interface xpc_interface; +=20 +diff --git a/drivers/misc/sgi-xp/xpc.h b/drivers/misc/sgi-xp/xpc.h +index b94d5f7..7f494c5 100644 +--- a/drivers/misc/sgi-xp/xpc.h ++++ b/drivers/misc/sgi-xp/xpc.h @@ -835,6 +835,7 @@ struct xpc_arch_operations { void (*received_payload) (struct xpc_channel *, void *); void (*notify_senders_of_disconnect) (struct xpc_channel *); @@ -31533,7 +32387,7 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-xp/xpc.h = linux-3.1.4/drivers/misc/sgi-xp =20 /* struct xpc_partition act_state values (for XPC HB) */ =20 -@@ -876,7 +877,7 @@ extern struct xpc_registration xpc_regis +@@ -876,7 +877,7 @@ extern struct xpc_registration xpc_registrations[]; /* found in xpc_main.c */ extern struct device *xpc_part; extern struct device *xpc_chan; @@ -31542,10 +32396,11 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-xp/xpc.= h linux-3.1.4/drivers/misc/sgi-xp extern int xpc_disengage_timelimit; extern int xpc_disengage_timedout; extern int xpc_activate_IRQ_rcvd; -diff -urNp linux-3.1.4/drivers/misc/sgi-xp/xpc_main.c linux-3.1.4/driver= s/misc/sgi-xp/xpc_main.c ---- linux-3.1.4/drivers/misc/sgi-xp/xpc_main.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/misc/sgi-xp/xpc_main.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -162,7 +162,7 @@ static struct notifier_block xpc_die_not +diff --git a/drivers/misc/sgi-xp/xpc_main.c b/drivers/misc/sgi-xp/xpc_ma= in.c +index 8d082b4..aa749ae 100644 +--- a/drivers/misc/sgi-xp/xpc_main.c ++++ b/drivers/misc/sgi-xp/xpc_main.c +@@ -162,7 +162,7 @@ static struct notifier_block xpc_die_notifier =3D { .notifier_call =3D xpc_system_die, }; =20 @@ -31554,22 +32409,11 @@ diff -urNp linux-3.1.4/drivers/misc/sgi-xp/xpc_= main.c linux-3.1.4/drivers/misc/s =20 /* * Timer function to enforce the timelimit on the partition disengage. -diff -urNp linux-3.1.4/drivers/misc/sgi-xp/xp.h linux-3.1.4/drivers/misc= /sgi-xp/xp.h ---- linux-3.1.4/drivers/misc/sgi-xp/xp.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/misc/sgi-xp/xp.h 2011-11-16 18:39:07.000000000 -= 0500 -@@ -289,7 +289,7 @@ struct xpc_interface { - xpc_notify_func, void *); - void (*received) (short, int, void *); - enum xp_retval (*partid_to_nasids) (short, void *); --}; -+} __no_const; -=20 - extern struct xpc_interface xpc_interface; -=20 -diff -urNp linux-3.1.4/drivers/mmc/host/sdhci-pci.c linux-3.1.4/drivers/= mmc/host/sdhci-pci.c ---- linux-3.1.4/drivers/mmc/host/sdhci-pci.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/mmc/host/sdhci-pci.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -542,7 +542,7 @@ static const struct sdhci_pci_fixes sdhc +diff --git a/drivers/mmc/host/sdhci-pci.c b/drivers/mmc/host/sdhci-pci.c +index 26c5286..292d261 100644 +--- a/drivers/mmc/host/sdhci-pci.c ++++ b/drivers/mmc/host/sdhci-pci.c +@@ -542,7 +542,7 @@ static const struct sdhci_pci_fixes sdhci_via =3D { .probe =3D via_probe, }; =20 @@ -31578,10 +32422,11 @@ diff -urNp linux-3.1.4/drivers/mmc/host/sdhci-p= ci.c linux-3.1.4/drivers/mmc/host { .vendor =3D PCI_VENDOR_ID_RICOH, .device =3D PCI_DEVICE_ID_RICOH_R5C822, -diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmdset_0001.c linux-3.1.4/d= rivers/mtd/chips/cfi_cmdset_0001.c ---- linux-3.1.4/drivers/mtd/chips/cfi_cmdset_0001.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/mtd/chips/cfi_cmdset_0001.c 2011-11-16 18:40:10.= 000000000 -0500 -@@ -757,6 +757,8 @@ static int chip_ready (struct map_info * +diff --git a/drivers/mtd/chips/cfi_cmdset_0001.c b/drivers/mtd/chips/cfi= _cmdset_0001.c +index e1e122f..d99a6ea 100644 +--- a/drivers/mtd/chips/cfi_cmdset_0001.c ++++ b/drivers/mtd/chips/cfi_cmdset_0001.c +@@ -757,6 +757,8 @@ static int chip_ready (struct map_info *map, struct = flchip *chip, unsigned long struct cfi_pri_intelext *cfip =3D cfi->cmdset_priv; unsigned long timeo =3D jiffies + HZ; =20 @@ -31590,7 +32435,7 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmds= et_0001.c linux-3.1.4/drivers/m /* Prevent setting state FL_SYNCING for chip in suspended state. */ if (mode =3D=3D FL_SYNCING && chip->oldstate !=3D FL_READY) goto sleep; -@@ -1653,6 +1655,8 @@ static int __xipram do_write_buffer(stru +@@ -1653,6 +1655,8 @@ static int __xipram do_write_buffer(struct map_inf= o *map, struct flchip *chip, unsigned long initial_adr; int initial_len =3D len; =20 @@ -31599,7 +32444,7 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmds= et_0001.c linux-3.1.4/drivers/m wbufsize =3D cfi_interleave(cfi) << cfi->cfiq->MaxBufWriteSize; adr +=3D chip->start; initial_adr =3D adr; -@@ -1871,6 +1875,8 @@ static int __xipram do_erase_oneblock(st +@@ -1871,6 +1875,8 @@ static int __xipram do_erase_oneblock(struct map_i= nfo *map, struct flchip *chip, int retries =3D 3; int ret; =20 @@ -31608,10 +32453,11 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cm= dset_0001.c linux-3.1.4/drivers/m adr +=3D chip->start; =20 retry: -diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmdset_0020.c linux-3.1.4/d= rivers/mtd/chips/cfi_cmdset_0020.c ---- linux-3.1.4/drivers/mtd/chips/cfi_cmdset_0020.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/mtd/chips/cfi_cmdset_0020.c 2011-11-16 18:40:10.= 000000000 -0500 -@@ -255,6 +255,8 @@ static inline int do_read_onechip(struct +diff --git a/drivers/mtd/chips/cfi_cmdset_0020.c b/drivers/mtd/chips/cfi= _cmdset_0020.c +index 179814a..abe9d60 100644 +--- a/drivers/mtd/chips/cfi_cmdset_0020.c ++++ b/drivers/mtd/chips/cfi_cmdset_0020.c +@@ -255,6 +255,8 @@ static inline int do_read_onechip(struct map_info *m= ap, struct flchip *chip, lof unsigned long cmd_addr; struct cfi_private *cfi =3D map->fldrv_priv; =20 @@ -31620,7 +32466,7 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmds= et_0020.c linux-3.1.4/drivers/m adr +=3D chip->start; =20 /* Ensure cmd read/writes are aligned. */ -@@ -429,6 +431,8 @@ static inline int do_write_buffer(struct +@@ -429,6 +431,8 @@ static inline int do_write_buffer(struct map_info *m= ap, struct flchip *chip, DECLARE_WAITQUEUE(wait, current); int wbufsize, z; =20 @@ -31629,7 +32475,7 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmds= et_0020.c linux-3.1.4/drivers/m /* M58LW064A requires bus alignment for buffer wriets -- saw */ if (adr & (map_bankwidth(map)-1)) return -EINVAL; -@@ -743,6 +747,8 @@ static inline int do_erase_oneblock(stru +@@ -743,6 +747,8 @@ static inline int do_erase_oneblock(struct map_info = *map, struct flchip *chip, u DECLARE_WAITQUEUE(wait, current); int ret =3D 0; =20 @@ -31638,7 +32484,7 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmds= et_0020.c linux-3.1.4/drivers/m adr +=3D chip->start; =20 /* Let's determine this according to the interleave only once */ -@@ -1048,6 +1054,8 @@ static inline int do_lock_oneblock(struc +@@ -1048,6 +1054,8 @@ static inline int do_lock_oneblock(struct map_info= *map, struct flchip *chip, un unsigned long timeo =3D jiffies + HZ; DECLARE_WAITQUEUE(wait, current); =20 @@ -31647,7 +32493,7 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cmds= et_0020.c linux-3.1.4/drivers/m adr +=3D chip->start; =20 /* Let's determine this according to the interleave only once */ -@@ -1197,6 +1205,8 @@ static inline int do_unlock_oneblock(str +@@ -1197,6 +1205,8 @@ static inline int do_unlock_oneblock(struct map_in= fo *map, struct flchip *chip, unsigned long timeo =3D jiffies + HZ; DECLARE_WAITQUEUE(wait, current); =20 @@ -31656,10 +32502,11 @@ diff -urNp linux-3.1.4/drivers/mtd/chips/cfi_cm= dset_0020.c linux-3.1.4/drivers/m adr +=3D chip->start; =20 /* Let's determine this according to the interleave only once */ -diff -urNp linux-3.1.4/drivers/mtd/devices/doc2000.c linux-3.1.4/drivers= /mtd/devices/doc2000.c ---- linux-3.1.4/drivers/mtd/devices/doc2000.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/mtd/devices/doc2000.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -776,7 +776,7 @@ static int doc_write(struct mtd_info *mt +diff --git a/drivers/mtd/devices/doc2000.c b/drivers/mtd/devices/doc2000= .c +index f7fbf60..9866457 100644 +--- a/drivers/mtd/devices/doc2000.c ++++ b/drivers/mtd/devices/doc2000.c +@@ -776,7 +776,7 @@ static int doc_write(struct mtd_info *mtd, loff_t to= , size_t len, =20 /* The ECC will not be calculated correctly if less than 512 is writt= en */ /* DBB- @@ -31668,10 +32515,11 @@ diff -urNp linux-3.1.4/drivers/mtd/devices/doc2= 000.c linux-3.1.4/drivers/mtd/dev printk(KERN_WARNING "ECC needs a full sector write (adr: %lx size %lx)\n", (long) to, (long) len); -diff -urNp linux-3.1.4/drivers/mtd/devices/doc2001.c linux-3.1.4/drivers= /mtd/devices/doc2001.c ---- linux-3.1.4/drivers/mtd/devices/doc2001.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/mtd/devices/doc2001.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -393,7 +393,7 @@ static int doc_read (struct mtd_info *mt +diff --git a/drivers/mtd/devices/doc2001.c b/drivers/mtd/devices/doc2001= .c +index 241192f..d0c35a3 100644 +--- a/drivers/mtd/devices/doc2001.c ++++ b/drivers/mtd/devices/doc2001.c +@@ -393,7 +393,7 @@ static int doc_read (struct mtd_info *mtd, loff_t fr= om, size_t len, struct Nand *mychip =3D &this->chips[from >> (this->chipshift)]; =20 /* Don't allow read past end of device */ @@ -31680,10 +32528,11 @@ diff -urNp linux-3.1.4/drivers/mtd/devices/doc2= 001.c linux-3.1.4/drivers/mtd/dev return -EINVAL; =20 /* Don't allow a single read to cross a 512-byte block boundary */ -diff -urNp linux-3.1.4/drivers/mtd/ftl.c linux-3.1.4/drivers/mtd/ftl.c ---- linux-3.1.4/drivers/mtd/ftl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/mtd/ftl.c 2011-11-16 18:40:10.000000000 -0500 -@@ -474,6 +474,8 @@ static int copy_erase_unit(partition_t * +diff --git a/drivers/mtd/ftl.c b/drivers/mtd/ftl.c +index 037b399..225a71d 100644 +--- a/drivers/mtd/ftl.c ++++ b/drivers/mtd/ftl.c +@@ -474,6 +474,8 @@ static int copy_erase_unit(partition_t *part, uint16= _t srcunit, loff_t offset; uint16_t srcunitswap =3D cpu_to_le16(srcunit); =20 @@ -31692,10 +32541,11 @@ diff -urNp linux-3.1.4/drivers/mtd/ftl.c linux-= 3.1.4/drivers/mtd/ftl.c eun =3D &part->EUNInfo[srcunit]; xfer =3D &part->XferInfo[xferunit]; DEBUG(2, "ftl_cs: copying block 0x%x to 0x%x\n", -diff -urNp linux-3.1.4/drivers/mtd/inftlcore.c linux-3.1.4/drivers/mtd/i= nftlcore.c ---- linux-3.1.4/drivers/mtd/inftlcore.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/mtd/inftlcore.c 2011-11-16 18:40:10.000000000 -0= 500 -@@ -259,6 +259,8 @@ static u16 INFTL_foldchain(struct INFTLr +diff --git a/drivers/mtd/inftlcore.c b/drivers/mtd/inftlcore.c +index d7592e6..31c505c 100644 +--- a/drivers/mtd/inftlcore.c ++++ b/drivers/mtd/inftlcore.c +@@ -259,6 +259,8 @@ static u16 INFTL_foldchain(struct INFTLrecord *inftl= , unsigned thisVUC, unsigned struct inftl_oob oob; size_t retlen; =20 @@ -31704,10 +32554,11 @@ diff -urNp linux-3.1.4/drivers/mtd/inftlcore.c = linux-3.1.4/drivers/mtd/inftlcore DEBUG(MTD_DEBUG_LEVEL3, "INFTL: INFTL_foldchain(inftl=3D%p,thisVUC=3D%= d," "pending=3D%d)\n", inftl, thisVUC, pendingblock); =20 -diff -urNp linux-3.1.4/drivers/mtd/inftlmount.c linux-3.1.4/drivers/mtd/= inftlmount.c ---- linux-3.1.4/drivers/mtd/inftlmount.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/mtd/inftlmount.c 2011-11-16 18:40:10.000000000 -= 0500 -@@ -53,6 +53,8 @@ static int find_boot_record(struct INFTL +diff --git a/drivers/mtd/inftlmount.c b/drivers/mtd/inftlmount.c +index 104052e..6232be5 100644 +--- a/drivers/mtd/inftlmount.c ++++ b/drivers/mtd/inftlmount.c +@@ -53,6 +53,8 @@ static int find_boot_record(struct INFTLrecord *inftl) struct INFTLPartition *ip; size_t retlen; =20 @@ -31716,10 +32567,11 @@ diff -urNp linux-3.1.4/drivers/mtd/inftlmount.c= linux-3.1.4/drivers/mtd/inftlmou DEBUG(MTD_DEBUG_LEVEL3, "INFTL: find_boot_record(inftl=3D%p)\n", inftl= ); =20 /* -diff -urNp linux-3.1.4/drivers/mtd/lpddr/qinfo_probe.c linux-3.1.4/drive= rs/mtd/lpddr/qinfo_probe.c ---- linux-3.1.4/drivers/mtd/lpddr/qinfo_probe.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/mtd/lpddr/qinfo_probe.c 2011-11-16 18:40:10.0000= 00000 -0500 -@@ -106,6 +106,8 @@ static int lpddr_pfow_present(struct map +diff --git a/drivers/mtd/lpddr/qinfo_probe.c b/drivers/mtd/lpddr/qinfo_p= robe.c +index dbfe17b..c7b0918 100644 +--- a/drivers/mtd/lpddr/qinfo_probe.c ++++ b/drivers/mtd/lpddr/qinfo_probe.c +@@ -106,6 +106,8 @@ static int lpddr_pfow_present(struct map_info *map, = struct lpddr_private *lpddr) { map_word pfow_val[4]; =20 @@ -31728,10 +32580,11 @@ diff -urNp linux-3.1.4/drivers/mtd/lpddr/qinfo_= probe.c linux-3.1.4/drivers/mtd/l /* Check identification string */ pfow_val[0] =3D map_read(map, map->pfow_base + PFOW_QUERY_STRING_P); pfow_val[1] =3D map_read(map, map->pfow_base + PFOW_QUERY_STRING_F); -diff -urNp linux-3.1.4/drivers/mtd/mtdchar.c linux-3.1.4/drivers/mtd/mtd= char.c ---- linux-3.1.4/drivers/mtd/mtdchar.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/mtd/mtdchar.c 2011-11-16 18:40:10.000000000 -050= 0 -@@ -554,6 +554,8 @@ static int mtd_ioctl(struct file *file,=20 +diff --git a/drivers/mtd/mtdchar.c b/drivers/mtd/mtdchar.c +index 49e20a4..60fbfa5 100644 +--- a/drivers/mtd/mtdchar.c ++++ b/drivers/mtd/mtdchar.c +@@ -554,6 +554,8 @@ static int mtd_ioctl(struct file *file, u_int cmd, u= _long arg) u_long size; struct mtd_info_user info; =20 @@ -31740,9 +32593,10 @@ diff -urNp linux-3.1.4/drivers/mtd/mtdchar.c lin= ux-3.1.4/drivers/mtd/mtdchar.c DEBUG(MTD_DEBUG_LEVEL0, "MTD_ioctl\n"); =20 size =3D (cmd & IOCSIZE_MASK) >> IOCSIZE_SHIFT; -diff -urNp linux-3.1.4/drivers/mtd/nand/denali.c linux-3.1.4/drivers/mtd= /nand/denali.c ---- linux-3.1.4/drivers/mtd/nand/denali.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/mtd/nand/denali.c 2011-11-16 18:39:07.000000000 = -0500 +diff --git a/drivers/mtd/nand/denali.c b/drivers/mtd/nand/denali.c +index d527621..2491fab 100644 +--- a/drivers/mtd/nand/denali.c ++++ b/drivers/mtd/nand/denali.c @@ -26,6 +26,7 @@ #include #include @@ -31751,10 +32605,11 @@ diff -urNp linux-3.1.4/drivers/mtd/nand/denali.= c linux-3.1.4/drivers/mtd/nand/de =20 #include "denali.h" =20 -diff -urNp linux-3.1.4/drivers/mtd/nftlcore.c linux-3.1.4/drivers/mtd/nf= tlcore.c ---- linux-3.1.4/drivers/mtd/nftlcore.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/mtd/nftlcore.c 2011-11-16 18:40:10.000000000 -05= 00 -@@ -264,6 +264,8 @@ static u16 NFTL_foldchain (struct NFTLre +diff --git a/drivers/mtd/nftlcore.c b/drivers/mtd/nftlcore.c +index b155666..611b801 100644 +--- a/drivers/mtd/nftlcore.c ++++ b/drivers/mtd/nftlcore.c +@@ -264,6 +264,8 @@ static u16 NFTL_foldchain (struct NFTLrecord *nftl, = unsigned thisVUC, unsigned p int inplace =3D 1; size_t retlen; =20 @@ -31763,9 +32618,10 @@ diff -urNp linux-3.1.4/drivers/mtd/nftlcore.c li= nux-3.1.4/drivers/mtd/nftlcore.c memset(BlockMap, 0xff, sizeof(BlockMap)); memset(BlockFreeFound, 0, sizeof(BlockFreeFound)); =20 -diff -urNp linux-3.1.4/drivers/mtd/nftlmount.c linux-3.1.4/drivers/mtd/n= ftlmount.c ---- linux-3.1.4/drivers/mtd/nftlmount.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/mtd/nftlmount.c 2011-11-16 18:40:10.000000000 -0= 500 +diff --git a/drivers/mtd/nftlmount.c b/drivers/mtd/nftlmount.c +index e3cd1ff..0ea79a3 100644 +--- a/drivers/mtd/nftlmount.c ++++ b/drivers/mtd/nftlmount.c @@ -24,6 +24,7 @@ #include #include @@ -31774,7 +32630,7 @@ diff -urNp linux-3.1.4/drivers/mtd/nftlmount.c li= nux-3.1.4/drivers/mtd/nftlmount #include #include #include -@@ -45,6 +46,8 @@ static int find_boot_record(struct NFTLr +@@ -45,6 +46,8 @@ static int find_boot_record(struct NFTLrecord *nftl) struct mtd_info *mtd =3D nftl->mbd.mtd; unsigned int i; =20 @@ -31783,9 +32639,10 @@ diff -urNp linux-3.1.4/drivers/mtd/nftlmount.c l= inux-3.1.4/drivers/mtd/nftlmount /* Assume logical EraseSize =3D=3D physical erasesize for start= ing the scan. We'll sort it out later if we find a MediaHeader which says otherwi= se */ /* Actually, we won't. The new DiskOnChip driver has already scanned -diff -urNp linux-3.1.4/drivers/mtd/ubi/build.c linux-3.1.4/drivers/mtd/u= bi/build.c ---- linux-3.1.4/drivers/mtd/ubi/build.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/mtd/ubi/build.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c +index 6c3fb5a..c542a81 100644 +--- a/drivers/mtd/ubi/build.c ++++ b/drivers/mtd/ubi/build.c @@ -1311,7 +1311,7 @@ module_exit(ubi_exit); static int __init bytes_str_to_int(const char *str) { @@ -31795,7 +32652,7 @@ diff -urNp linux-3.1.4/drivers/mtd/ubi/build.c li= nux-3.1.4/drivers/mtd/ubi/build =20 result =3D simple_strtoul(str, &endp, 0); if (str =3D=3D endp || result >=3D INT_MAX) { -@@ -1322,11 +1322,11 @@ static int __init bytes_str_to_int(const +@@ -1322,11 +1322,11 @@ static int __init bytes_str_to_int(const char *s= tr) =20 switch (*endp) { case 'G': @@ -31810,7 +32667,7 @@ diff -urNp linux-3.1.4/drivers/mtd/ubi/build.c li= nux-3.1.4/drivers/mtd/ubi/build if (endp[1] =3D=3D 'i' && endp[2] =3D=3D 'B') endp +=3D 2; case '\0': -@@ -1337,7 +1337,13 @@ static int __init bytes_str_to_int(const +@@ -1337,7 +1337,13 @@ static int __init bytes_str_to_int(const char *st= r) return -EINVAL; } =20 @@ -31825,10 +32682,11 @@ diff -urNp linux-3.1.4/drivers/mtd/ubi/build.c = linux-3.1.4/drivers/mtd/ubi/build } =20 /** -diff -urNp linux-3.1.4/drivers/net/atlx/atl2.c linux-3.1.4/drivers/net/a= tlx/atl2.c ---- linux-3.1.4/drivers/net/atlx/atl2.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/net/atlx/atl2.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -2857,7 +2857,7 @@ static void atl2_force_ps(struct atl2_hw +diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c +index d4f7dda..d627d46 100644 +--- a/drivers/net/atlx/atl2.c ++++ b/drivers/net/atlx/atl2.c +@@ -2857,7 +2857,7 @@ static void atl2_force_ps(struct atl2_hw *hw) */ =20 #define ATL2_PARAM(X, desc) \ @@ -31837,10 +32695,11 @@ diff -urNp linux-3.1.4/drivers/net/atlx/atl2.c = linux-3.1.4/drivers/net/atlx/atl2 MODULE_PARM(X, "1-" __MODULE_STRING(ATL2_MAX_NIC) "i"); \ MODULE_PARM_DESC(X, desc); #else -diff -urNp linux-3.1.4/drivers/net/bna/bfa_ioc_ct.c linux-3.1.4/drivers/= net/bna/bfa_ioc_ct.c ---- linux-3.1.4/drivers/net/bna/bfa_ioc_ct.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/net/bna/bfa_ioc_ct.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -48,7 +48,21 @@ static void bfa_ioc_ct_sync_ack(struct b +diff --git a/drivers/net/bna/bfa_ioc_ct.c b/drivers/net/bna/bfa_ioc_ct.c +index 87aecdf..ec23470 100644 +--- a/drivers/net/bna/bfa_ioc_ct.c ++++ b/drivers/net/bna/bfa_ioc_ct.c +@@ -48,7 +48,21 @@ static void bfa_ioc_ct_sync_ack(struct bfa_ioc *ioc); static bool bfa_ioc_ct_sync_complete(struct bfa_ioc *ioc); static enum bfa_status bfa_ioc_ct_pll_init(void __iomem *rb, bool fcmod= e); =20 @@ -31884,10 +32743,11 @@ diff -urNp linux-3.1.4/drivers/net/bna/bfa_ioc_= ct.c linux-3.1.4/drivers/net/bna/ ioc->ioc_hwif =3D &nw_hwif_ct; } =20 -diff -urNp linux-3.1.4/drivers/net/bna/bnad.c linux-3.1.4/drivers/net/bn= a/bnad.c ---- linux-3.1.4/drivers/net/bna/bnad.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/net/bna/bnad.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -1673,7 +1673,14 @@ bnad_setup_tx(struct bnad *bnad, uint tx +diff --git a/drivers/net/bna/bnad.c b/drivers/net/bna/bnad.c +index 8e35b25..c39f205 100644 +--- a/drivers/net/bna/bnad.c ++++ b/drivers/net/bna/bnad.c +@@ -1673,7 +1673,14 @@ bnad_setup_tx(struct bnad *bnad, uint tx_id) struct bna_intr_info *intr_info =3D &res_info[BNA_TX_RES_INTR_T_TXCMPL].res_u.intr_info; struct bna_tx_config *tx_config =3D &bnad->tx_config[tx_id]; @@ -31903,7 +32763,7 @@ diff -urNp linux-3.1.4/drivers/net/bna/bnad.c lin= ux-3.1.4/drivers/net/bna/bnad.c struct bna_tx *tx; unsigned long flags; =20 -@@ -1682,13 +1689,6 @@ bnad_setup_tx(struct bnad *bnad, uint tx +@@ -1682,13 +1689,6 @@ bnad_setup_tx(struct bnad *bnad, uint tx_id) tx_config->txq_depth =3D bnad->txq_depth; tx_config->tx_type =3D BNA_TX_T_REGULAR; =20 @@ -31917,7 +32777,7 @@ diff -urNp linux-3.1.4/drivers/net/bna/bnad.c lin= ux-3.1.4/drivers/net/bna/bnad.c /* Get BNA's resource requirement for one tx object */ spin_lock_irqsave(&bnad->bna_lock, flags); bna_tx_res_req(bnad->num_txq_per_tx, -@@ -1819,21 +1819,21 @@ bnad_setup_rx(struct bnad *bnad, uint rx +@@ -1819,21 +1819,21 @@ bnad_setup_rx(struct bnad *bnad, uint rx_id) struct bna_intr_info *intr_info =3D &res_info[BNA_RX_RES_T_INTR].res_u.intr_info; struct bna_rx_config *rx_config =3D &bnad->rx_config[rx_id]; @@ -31948,9 +32808,10 @@ diff -urNp linux-3.1.4/drivers/net/bna/bnad.c li= nux-3.1.4/drivers/net/bna/bnad.c /* Get BNA's resource requirement for one Rx object */ spin_lock_irqsave(&bnad->bna_lock, flags); bna_rx_res_req(rx_config, res_info); -diff -urNp linux-3.1.4/drivers/net/bnx2.c linux-3.1.4/drivers/net/bnx2.c ---- linux-3.1.4/drivers/net/bnx2.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/bnx2.c 2011-11-16 18:40:11.000000000 -0500 +diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c +index 4b2b570..31033f4 100644 +--- a/drivers/net/bnx2.c ++++ b/drivers/net/bnx2.c @@ -5877,6 +5877,8 @@ bnx2_test_nvram(struct bnx2 *bp) int rc =3D 0; u32 magic, csum; @@ -31960,10 +32821,11 @@ diff -urNp linux-3.1.4/drivers/net/bnx2.c linux= -3.1.4/drivers/net/bnx2.c if ((rc =3D bnx2_nvram_read(bp, 0, data, 4)) !=3D 0) goto test_nvram_done; =20 -diff -urNp linux-3.1.4/drivers/net/bnx2x/bnx2x_ethtool.c linux-3.1.4/dri= vers/net/bnx2x/bnx2x_ethtool.c ---- linux-3.1.4/drivers/net/bnx2x/bnx2x_ethtool.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/net/bnx2x/bnx2x_ethtool.c 2011-11-16 18:40:11.00= 0000000 -0500 -@@ -1943,6 +1943,8 @@ static int bnx2x_test_nvram(struct bnx2x +diff --git a/drivers/net/bnx2x/bnx2x_ethtool.c b/drivers/net/bnx2x/bnx2x= _ethtool.c +index cf3e479..5dc0ecc 100644 +--- a/drivers/net/bnx2x/bnx2x_ethtool.c ++++ b/drivers/net/bnx2x/bnx2x_ethtool.c +@@ -1943,6 +1943,8 @@ static int bnx2x_test_nvram(struct bnx2x *bp) int i, rc; u32 magic, crc; =20 @@ -31972,9 +32834,10 @@ diff -urNp linux-3.1.4/drivers/net/bnx2x/bnx2x_e= thtool.c linux-3.1.4/drivers/net if (BP_NOMCP(bp)) return 0; =20 -diff -urNp linux-3.1.4/drivers/net/bnx2x/bnx2x_sp.h linux-3.1.4/drivers/= net/bnx2x/bnx2x_sp.h ---- linux-3.1.4/drivers/net/bnx2x/bnx2x_sp.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/net/bnx2x/bnx2x_sp.h 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/drivers/net/bnx2x/bnx2x_sp.h b/drivers/net/bnx2x/bnx2x_sp.h +index 9a517c2..a50cfcb 100644 +--- a/drivers/net/bnx2x/bnx2x_sp.h ++++ b/drivers/net/bnx2x/bnx2x_sp.h @@ -449,7 +449,7 @@ struct bnx2x_rx_mode_obj { =20 int (*wait_comp)(struct bnx2x *bp, @@ -31984,10 +32847,11 @@ diff -urNp linux-3.1.4/drivers/net/bnx2x/bnx2x_= sp.h linux-3.1.4/drivers/net/bnx2 =20 /********************** Set multicast group ***************************= ********/ =20 -diff -urNp linux-3.1.4/drivers/net/cxgb3/l2t.h linux-3.1.4/drivers/net/c= xgb3/l2t.h ---- linux-3.1.4/drivers/net/cxgb3/l2t.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/net/cxgb3/l2t.h 2011-11-16 18:39:07.000000000 -0= 500 -@@ -87,7 +87,7 @@ typedef void (*arp_failure_handler_func) +diff --git a/drivers/net/cxgb3/l2t.h b/drivers/net/cxgb3/l2t.h +index c5f5479..2e8c260 100644 +--- a/drivers/net/cxgb3/l2t.h ++++ b/drivers/net/cxgb3/l2t.h +@@ -87,7 +87,7 @@ typedef void (*arp_failure_handler_func)(struct t3cdev= * dev, */ struct l2t_skb_cb { arp_failure_handler_func arp_failure_handler; @@ -31996,10 +32860,11 @@ diff -urNp linux-3.1.4/drivers/net/cxgb3/l2t.h = linux-3.1.4/drivers/net/cxgb3/l2t =20 #define L2T_SKB_CB(skb) ((struct l2t_skb_cb *)(skb)->cb) =20 -diff -urNp linux-3.1.4/drivers/net/cxgb4/cxgb4_main.c linux-3.1.4/driver= s/net/cxgb4/cxgb4_main.c ---- linux-3.1.4/drivers/net/cxgb4/cxgb4_main.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/net/cxgb4/cxgb4_main.c 2011-11-16 18:40:22.00000= 0000 -0500 -@@ -3396,6 +3396,8 @@ static int __devinit enable_msix(struct=20 +diff --git a/drivers/net/cxgb4/cxgb4_main.c b/drivers/net/cxgb4/cxgb4_ma= in.c +index b4efa29..c5f2703 100644 +--- a/drivers/net/cxgb4/cxgb4_main.c ++++ b/drivers/net/cxgb4/cxgb4_main.c +@@ -3396,6 +3396,8 @@ static int __devinit enable_msix(struct adapter *a= dap) unsigned int nchan =3D adap->params.nports; struct msix_entry entries[MAX_INGQ + 1]; =20 @@ -32008,10 +32873,11 @@ diff -urNp linux-3.1.4/drivers/net/cxgb4/cxgb4_= main.c linux-3.1.4/drivers/net/cx for (i =3D 0; i < ARRAY_SIZE(entries); ++i) entries[i].entry =3D i; =20 -diff -urNp linux-3.1.4/drivers/net/cxgb4/t4_hw.c linux-3.1.4/drivers/net= /cxgb4/t4_hw.c ---- linux-3.1.4/drivers/net/cxgb4/t4_hw.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/net/cxgb4/t4_hw.c 2011-11-16 18:40:22.000000000 = -0500 -@@ -362,6 +362,8 @@ static int get_vpd_params(struct adapter +diff --git a/drivers/net/cxgb4/t4_hw.c b/drivers/net/cxgb4/t4_hw.c +index d1ec111..12735bc 100644 +--- a/drivers/net/cxgb4/t4_hw.c ++++ b/drivers/net/cxgb4/t4_hw.c +@@ -362,6 +362,8 @@ static int get_vpd_params(struct adapter *adapter, s= truct vpd_params *p) u8 vpd[VPD_LEN], csum; unsigned int vpdr_len, kw_offset, id_len; =20 @@ -32020,10 +32886,11 @@ diff -urNp linux-3.1.4/drivers/net/cxgb4/t4_hw.= c linux-3.1.4/drivers/net/cxgb4/t ret =3D pci_read_vpd(adapter->pdev, VPD_BASE, sizeof(vpd), vpd); if (ret < 0) return ret; -diff -urNp linux-3.1.4/drivers/net/e1000e/82571.c linux-3.1.4/drivers/ne= t/e1000e/82571.c ---- linux-3.1.4/drivers/net/e1000e/82571.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/net/e1000e/82571.c 2011-11-16 18:39:07.000000000= -0500 -@@ -239,7 +239,7 @@ static s32 e1000_init_mac_params_82571(s +diff --git a/drivers/net/e1000e/82571.c b/drivers/net/e1000e/82571.c +index 536b3a5..e6f8dcc 100644 +--- a/drivers/net/e1000e/82571.c ++++ b/drivers/net/e1000e/82571.c +@@ -239,7 +239,7 @@ static s32 e1000_init_mac_params_82571(struct e1000_= adapter *adapter) { struct e1000_hw *hw =3D &adapter->hw; struct e1000_mac_info *mac =3D &hw->mac; @@ -32032,10 +32899,11 @@ diff -urNp linux-3.1.4/drivers/net/e1000e/82571= .c linux-3.1.4/drivers/net/e1000e u32 swsm =3D 0; u32 swsm2 =3D 0; bool force_clear_smbi =3D false; -diff -urNp linux-3.1.4/drivers/net/e1000e/es2lan.c linux-3.1.4/drivers/n= et/e1000e/es2lan.c ---- linux-3.1.4/drivers/net/e1000e/es2lan.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/net/e1000e/es2lan.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -205,7 +205,7 @@ static s32 e1000_init_mac_params_80003es +diff --git a/drivers/net/e1000e/es2lan.c b/drivers/net/e1000e/es2lan.c +index e4f4225..24da2ea 100644 +--- a/drivers/net/e1000e/es2lan.c ++++ b/drivers/net/e1000e/es2lan.c +@@ -205,7 +205,7 @@ static s32 e1000_init_mac_params_80003es2lan(struct = e1000_adapter *adapter) { struct e1000_hw *hw =3D &adapter->hw; struct e1000_mac_info *mac =3D &hw->mac; @@ -32044,9 +32912,10 @@ diff -urNp linux-3.1.4/drivers/net/e1000e/es2lan= .c linux-3.1.4/drivers/net/e1000 =20 /* Set media type */ switch (adapter->pdev->device) { -diff -urNp linux-3.1.4/drivers/net/e1000e/hw.h linux-3.1.4/drivers/net/e= 1000e/hw.h ---- linux-3.1.4/drivers/net/e1000e/hw.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/net/e1000e/hw.h 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/drivers/net/e1000e/hw.h b/drivers/net/e1000e/hw.h +index 2967039..ca8c40c 100644 +--- a/drivers/net/e1000e/hw.h ++++ b/drivers/net/e1000e/hw.h @@ -778,6 +778,7 @@ struct e1000_mac_operations { void (*write_vfta)(struct e1000_hw *, u32, u32); s32 (*read_mac_addr)(struct e1000_hw *); @@ -32093,9 +32962,10 @@ diff -urNp linux-3.1.4/drivers/net/e1000e/hw.h l= inux-3.1.4/drivers/net/e1000e/hw =20 enum e1000_nvm_type type; enum e1000_nvm_override override; -diff -urNp linux-3.1.4/drivers/net/fealnx.c linux-3.1.4/drivers/net/feal= nx.c ---- linux-3.1.4/drivers/net/fealnx.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/fealnx.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/net/fealnx.c b/drivers/net/fealnx.c +index fa8677c..196356f 100644 +--- a/drivers/net/fealnx.c ++++ b/drivers/net/fealnx.c @@ -150,7 +150,7 @@ struct chip_info { int flags; }; @@ -32105,10 +32975,11 @@ diff -urNp linux-3.1.4/drivers/net/fealnx.c lin= ux-3.1.4/drivers/net/fealnx.c { "100/10M Ethernet PCI Adapter", HAS_MII_XCVR }, { "100/10M Ethernet PCI Adapter", HAS_CHIP_XCVR }, { "1000/100/10M Ethernet PCI Adapter", HAS_MII_XCVR }, -diff -urNp linux-3.1.4/drivers/net/hamradio/6pack.c linux-3.1.4/drivers/= net/hamradio/6pack.c ---- linux-3.1.4/drivers/net/hamradio/6pack.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/net/hamradio/6pack.c 2011-11-16 18:40:22.0000000= 00 -0500 -@@ -463,6 +463,8 @@ static void sixpack_receive_buf(struct t +diff --git a/drivers/net/hamradio/6pack.c b/drivers/net/hamradio/6pack.c +index 2a5a34d..be871cc 100644 +--- a/drivers/net/hamradio/6pack.c ++++ b/drivers/net/hamradio/6pack.c +@@ -463,6 +463,8 @@ static void sixpack_receive_buf(struct tty_struct *t= ty, unsigned char buf[512]; int count1; =20 @@ -32117,9 +32988,10 @@ diff -urNp linux-3.1.4/drivers/net/hamradio/6pac= k.c linux-3.1.4/drivers/net/hamr if (!count) return; =20 -diff -urNp linux-3.1.4/drivers/net/igb/e1000_hw.h linux-3.1.4/drivers/ne= t/igb/e1000_hw.h ---- linux-3.1.4/drivers/net/igb/e1000_hw.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/net/igb/e1000_hw.h 2011-11-16 18:39:07.000000000= -0500 +diff --git a/drivers/net/igb/e1000_hw.h b/drivers/net/igb/e1000_hw.h +index 4519a13..f97fcd0 100644 +--- a/drivers/net/igb/e1000_hw.h ++++ b/drivers/net/igb/e1000_hw.h @@ -314,6 +314,7 @@ struct e1000_mac_operations { s32 (*read_mac_addr)(struct e1000_hw *); s32 (*get_speed_and_duplex)(struct e1000_hw *, u16 *, u16 *); @@ -32188,9 +33060,10 @@ diff -urNp linux-3.1.4/drivers/net/igb/e1000_hw.= h linux-3.1.4/drivers/net/igb/e1 struct e1000_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-3.1.4/drivers/net/igbvf/vf.h linux-3.1.4/drivers/net/ig= bvf/vf.h ---- linux-3.1.4/drivers/net/igbvf/vf.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/net/igbvf/vf.h 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/drivers/net/igbvf/vf.h b/drivers/net/igbvf/vf.h +index d7ed58f..64cde36 100644 +--- a/drivers/net/igbvf/vf.h ++++ b/drivers/net/igbvf/vf.h @@ -189,9 +189,10 @@ struct e1000_mac_operations { s32 (*read_mac_addr)(struct e1000_hw *); s32 (*set_vfta)(struct e1000_hw *, u16, bool); @@ -32220,10 +33093,11 @@ diff -urNp linux-3.1.4/drivers/net/igbvf/vf.h l= inux-3.1.4/drivers/net/igbvf/vf.h struct e1000_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-3.1.4/drivers/net/ixgb/ixgb_main.c linux-3.1.4/drivers/= net/ixgb/ixgb_main.c ---- linux-3.1.4/drivers/net/ixgb/ixgb_main.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/net/ixgb/ixgb_main.c 2011-11-16 18:40:22.0000000= 00 -0500 -@@ -1070,6 +1070,8 @@ ixgb_set_multi(struct net_device *netdev +diff --git a/drivers/net/ixgb/ixgb_main.c b/drivers/net/ixgb/ixgb_main.c +index 6a130eb..1aeb9e4 100644 +--- a/drivers/net/ixgb/ixgb_main.c ++++ b/drivers/net/ixgb/ixgb_main.c +@@ -1070,6 +1070,8 @@ ixgb_set_multi(struct net_device *netdev) u32 rctl; int i; =20 @@ -32232,9 +33106,10 @@ diff -urNp linux-3.1.4/drivers/net/ixgb/ixgb_mai= n.c linux-3.1.4/drivers/net/ixgb /* Check for Promiscuous and All Multicast modes */ =20 rctl =3D IXGB_READ_REG(hw, RCTL); -diff -urNp linux-3.1.4/drivers/net/ixgb/ixgb_param.c linux-3.1.4/drivers= /net/ixgb/ixgb_param.c ---- linux-3.1.4/drivers/net/ixgb/ixgb_param.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/net/ixgb/ixgb_param.c 2011-11-16 18:40:22.000000= 000 -0500 +diff --git a/drivers/net/ixgb/ixgb_param.c b/drivers/net/ixgb/ixgb_param= .c +index dd7fbeb..44b9bbf 100644 +--- a/drivers/net/ixgb/ixgb_param.c ++++ b/drivers/net/ixgb/ixgb_param.c @@ -261,6 +261,9 @@ void __devinit ixgb_check_options(struct ixgb_adapter *adapter) { @@ -32245,9 +33120,10 @@ diff -urNp linux-3.1.4/drivers/net/ixgb/ixgb_par= am.c linux-3.1.4/drivers/net/ixg if (bd >=3D IXGB_MAX_NIC) { pr_notice("Warning: no configuration for board #%i\n", bd); pr_notice("Using defaults for all values\n"); -diff -urNp linux-3.1.4/drivers/net/ixgbe/ixgbe_type.h linux-3.1.4/driver= s/net/ixgbe/ixgbe_type.h ---- linux-3.1.4/drivers/net/ixgbe/ixgbe_type.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/net/ixgbe/ixgbe_type.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/drivers/net/ixgbe/ixgbe_type.h b/drivers/net/ixgbe/ixgbe_ty= pe.h +index e0d970e..1cfdea5 100644 +--- a/drivers/net/ixgbe/ixgbe_type.h ++++ b/drivers/net/ixgbe/ixgbe_type.h @@ -2642,6 +2642,7 @@ struct ixgbe_eeprom_operations { s32 (*update_checksum)(struct ixgbe_hw *); u16 (*calc_checksum)(struct ixgbe_hw *); @@ -32311,9 +33187,10 @@ diff -urNp linux-3.1.4/drivers/net/ixgbe/ixgbe_t= ype.h linux-3.1.4/drivers/net/ix struct ixgbe_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-3.1.4/drivers/net/ixgbevf/vf.h linux-3.1.4/drivers/net/= ixgbevf/vf.h ---- linux-3.1.4/drivers/net/ixgbevf/vf.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/net/ixgbevf/vf.h 2011-11-16 18:39:07.000000000 -= 0500 +diff --git a/drivers/net/ixgbevf/vf.h b/drivers/net/ixgbevf/vf.h +index 10306b4..28df758 100644 +--- a/drivers/net/ixgbevf/vf.h ++++ b/drivers/net/ixgbevf/vf.h @@ -70,6 +70,7 @@ struct ixgbe_mac_operations { s32 (*clear_vfta)(struct ixgbe_hw *); s32 (*set_vfta)(struct ixgbe_hw *, u32, u32, bool); @@ -32348,10 +33225,11 @@ diff -urNp linux-3.1.4/drivers/net/ixgbevf/vf.h= linux-3.1.4/drivers/net/ixgbevf/ struct ixgbe_mbx_stats stats; u32 timeout; u32 udelay; -diff -urNp linux-3.1.4/drivers/net/ksz884x.c linux-3.1.4/drivers/net/ksz= 884x.c ---- linux-3.1.4/drivers/net/ksz884x.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/net/ksz884x.c 2011-11-16 18:40:22.000000000 -050= 0 -@@ -6533,6 +6533,8 @@ static void netdev_get_ethtool_stats(str +diff --git a/drivers/net/ksz884x.c b/drivers/net/ksz884x.c +index 27418d3..adf15bb 100644 +--- a/drivers/net/ksz884x.c ++++ b/drivers/net/ksz884x.c +@@ -6533,6 +6533,8 @@ static void netdev_get_ethtool_stats(struct net_de= vice *dev, int rc; u64 counter[TOTAL_PORT_COUNTER_NUM]; =20 @@ -32360,9 +33238,10 @@ diff -urNp linux-3.1.4/drivers/net/ksz884x.c lin= ux-3.1.4/drivers/net/ksz884x.c mutex_lock(&hw_priv->lock); n =3D SWITCH_PORT_NUM; for (i =3D 0, p =3D port->first_port; i < port->mib_port_cnt; i++, p++= ) { -diff -urNp linux-3.1.4/drivers/net/mlx4/main.c linux-3.1.4/drivers/net/m= lx4/main.c ---- linux-3.1.4/drivers/net/mlx4/main.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/net/mlx4/main.c 2011-11-16 18:40:22.000000000 -0= 500 +diff --git a/drivers/net/mlx4/main.c b/drivers/net/mlx4/main.c +index f0ee35d..3831c8a 100644 +--- a/drivers/net/mlx4/main.c ++++ b/drivers/net/mlx4/main.c @@ -40,6 +40,7 @@ #include #include @@ -32371,7 +33250,7 @@ diff -urNp linux-3.1.4/drivers/net/mlx4/main.c li= nux-3.1.4/drivers/net/mlx4/main =20 #include #include -@@ -762,6 +763,8 @@ static int mlx4_init_hca(struct mlx4_dev +@@ -762,6 +763,8 @@ static int mlx4_init_hca(struct mlx4_dev *dev) u64 icm_size; int err; =20 @@ -32380,10 +33259,11 @@ diff -urNp linux-3.1.4/drivers/net/mlx4/main.c = linux-3.1.4/drivers/net/mlx4/main err =3D mlx4_QUERY_FW(dev); if (err) { if (err =3D=3D -EACCES) -diff -urNp linux-3.1.4/drivers/net/niu.c linux-3.1.4/drivers/net/niu.c ---- linux-3.1.4/drivers/net/niu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/niu.c 2011-11-16 18:40:22.000000000 -0500 -@@ -9061,6 +9061,8 @@ static void __devinit niu_try_msix(struc +diff --git a/drivers/net/niu.c b/drivers/net/niu.c +index ed47585..5e5be8f 100644 +--- a/drivers/net/niu.c ++++ b/drivers/net/niu.c +@@ -9061,6 +9061,8 @@ static void __devinit niu_try_msix(struct niu *np,= u8 *ldg_num_map) int i, num_irqs, err; u8 first_ldg; =20 @@ -32392,9 +33272,10 @@ diff -urNp linux-3.1.4/drivers/net/niu.c linux-3= .1.4/drivers/net/niu.c first_ldg =3D (NIU_NUM_LDG / parent->num_ports) * np->port; for (i =3D 0; i < (NIU_NUM_LDG / parent->num_ports); i++) ldg_num_map[i] =3D first_ldg + i; -diff -urNp linux-3.1.4/drivers/net/pcnet32.c linux-3.1.4/drivers/net/pcn= et32.c ---- linux-3.1.4/drivers/net/pcnet32.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/net/pcnet32.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/net/pcnet32.c b/drivers/net/pcnet32.c +index 80b6f36..5cd8938 100644 +--- a/drivers/net/pcnet32.c ++++ b/drivers/net/pcnet32.c @@ -270,7 +270,7 @@ struct pcnet32_private { struct sk_buff **rx_skbuff; dma_addr_t *tx_dma_addr; @@ -32404,7 +33285,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c spinlock_t lock; /* Guard lock */ unsigned int cur_rx, cur_tx; /* The next free ring entry */ unsigned int rx_ring_size; /* current rx ring size */ -@@ -460,9 +460,9 @@ static void pcnet32_netif_start(struct n +@@ -460,9 +460,9 @@ static void pcnet32_netif_start(struct net_device *d= ev) u16 val; =20 netif_wake_queue(dev); @@ -32416,7 +33297,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c napi_enable(&lp->napi); } =20 -@@ -730,7 +730,7 @@ static u32 pcnet32_get_link(struct net_d +@@ -730,7 +730,7 @@ static u32 pcnet32_get_link(struct net_device *dev) r =3D mii_link_ok(&lp->mii_if); } else if (lp->chip_version >=3D PCNET32_79C970A) { ulong ioaddr =3D dev->base_addr; /* card base I/O address */ @@ -32425,7 +33306,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } else { /* can not detect link on really old chips */ r =3D 1; } -@@ -792,7 +792,7 @@ static int pcnet32_set_ringparam(struct=20 +@@ -792,7 +792,7 @@ static int pcnet32_set_ringparam(struct net_device *= dev, pcnet32_netif_stop(dev); =20 spin_lock_irqsave(&lp->lock, flags); @@ -32434,7 +33315,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 size =3D min(ering->tx_pending, (unsigned int)TX_MAX_RING_SIZE); =20 -@@ -868,7 +868,7 @@ static void pcnet32_ethtool_test(struct=20 +@@ -868,7 +868,7 @@ static void pcnet32_ethtool_test(struct net_device *= dev, static int pcnet32_loopback_test(struct net_device *dev, uint64_t * dat= a1) { struct pcnet32_private *lp =3D netdev_priv(dev); @@ -32443,7 +33324,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c ulong ioaddr =3D dev->base_addr; /* card base I/O address */ struct sk_buff *skb; /* sk buff */ int x, i; /* counters */ -@@ -888,21 +888,21 @@ static int pcnet32_loopback_test(struct=20 +@@ -888,21 +888,21 @@ static int pcnet32_loopback_test(struct net_device= *dev, uint64_t * data1) pcnet32_netif_stop(dev); =20 spin_lock_irqsave(&lp->lock, flags); @@ -32470,7 +33351,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 /* Initialize Transmit buffers. */ size =3D data_len + 15; -@@ -947,10 +947,10 @@ static int pcnet32_loopback_test(struct=20 +@@ -947,10 +947,10 @@ static int pcnet32_loopback_test(struct net_device= *dev, uint64_t * data1) =20 /* set int loopback in CSR15 */ x =3D a->read_csr(ioaddr, CSR15) & 0xfffc; @@ -32483,7 +33364,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 /* Check status of descriptors */ for (x =3D 0; x < numbuffs; x++) { -@@ -969,7 +969,7 @@ static int pcnet32_loopback_test(struct=20 +@@ -969,7 +969,7 @@ static int pcnet32_loopback_test(struct net_device *= dev, uint64_t * data1) } } =20 @@ -32501,7 +33382,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } spin_unlock_irqrestore(&lp->lock, flags); =20 -@@ -1026,7 +1026,7 @@ static int pcnet32_set_phys_id(struct ne +@@ -1026,7 +1026,7 @@ static int pcnet32_set_phys_id(struct net_device *= dev, enum ethtool_phys_id_state state) { struct pcnet32_private *lp =3D netdev_priv(dev); @@ -32510,7 +33391,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c ulong ioaddr =3D dev->base_addr; unsigned long flags; int i; -@@ -1067,7 +1067,7 @@ static int pcnet32_suspend(struct net_de +@@ -1067,7 +1067,7 @@ static int pcnet32_suspend(struct net_device *dev,= unsigned long *flags, { int csr5; struct pcnet32_private *lp =3D netdev_priv(dev); @@ -32519,7 +33400,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c ulong ioaddr =3D dev->base_addr; int ticks; =20 -@@ -1324,8 +1324,8 @@ static int pcnet32_poll(struct napi_stru +@@ -1324,8 +1324,8 @@ static int pcnet32_poll(struct napi_struct *napi, = int budget) spin_lock_irqsave(&lp->lock, flags); if (pcnet32_tx(dev)) { /* reset the chip to clear the error condition, then restart */ @@ -32530,7 +33411,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c pcnet32_restart(dev, CSR0_START); netif_wake_queue(dev); } -@@ -1337,12 +1337,12 @@ static int pcnet32_poll(struct napi_stru +@@ -1337,12 +1337,12 @@ static int pcnet32_poll(struct napi_struct *napi= , int budget) __napi_complete(napi); =20 /* clear interrupt masks */ @@ -32546,7 +33427,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 spin_unlock_irqrestore(&lp->lock, flags); } -@@ -1365,7 +1365,7 @@ static void pcnet32_get_regs(struct net_ +@@ -1365,7 +1365,7 @@ static void pcnet32_get_regs(struct net_device *de= v, struct ethtool_regs *regs, int i, csr0; u16 *buff =3D ptr; struct pcnet32_private *lp =3D netdev_priv(dev); @@ -32555,7 +33436,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c ulong ioaddr =3D dev->base_addr; unsigned long flags; =20 -@@ -1401,9 +1401,9 @@ static void pcnet32_get_regs(struct net_ +@@ -1401,9 +1401,9 @@ static void pcnet32_get_regs(struct net_device *de= v, struct ethtool_regs *regs, for (j =3D 0; j < PCNET32_MAX_PHYS; j++) { if (lp->phymask & (1 << j)) { for (i =3D 0; i < PCNET32_REGS_PER_PHY; i++) { @@ -32567,7 +33448,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } } } -@@ -1785,7 +1785,7 @@ pcnet32_probe1(unsigned long ioaddr, int +@@ -1785,7 +1785,7 @@ pcnet32_probe1(unsigned long ioaddr, int shared, s= truct pci_dev *pdev) ((cards_found >=3D MAX_UNITS) || full_duplex[cards_found])) lp->options |=3D PCNET32_PORT_FD; =20 @@ -32576,7 +33457,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 /* prior to register_netdev, dev->name is not yet correct */ if (pcnet32_alloc_ring(dev, pci_name(lp->pci_dev))) { -@@ -1844,7 +1844,7 @@ pcnet32_probe1(unsigned long ioaddr, int +@@ -1844,7 +1844,7 @@ pcnet32_probe1(unsigned long ioaddr, int shared, s= truct pci_dev *pdev) if (lp->mii) { /* lp->phycount and lp->phymask are set to 0 by memset above */ =20 @@ -32585,7 +33466,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c /* scan for PHYs */ for (i =3D 0; i < PCNET32_MAX_PHYS; i++) { unsigned short id1, id2; -@@ -1864,7 +1864,7 @@ pcnet32_probe1(unsigned long ioaddr, int +@@ -1864,7 +1864,7 @@ pcnet32_probe1(unsigned long ioaddr, int shared, s= truct pci_dev *pdev) pr_info("Found PHY %04x:%04x at address %d\n", id1, id2, i); } @@ -32594,7 +33475,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c if (lp->phycount > 1) lp->options |=3D PCNET32_PORT_MII; } -@@ -2020,10 +2020,10 @@ static int pcnet32_open(struct net_devic +@@ -2020,10 +2020,10 @@ static int pcnet32_open(struct net_device *dev) } =20 /* Reset the PCNET32 */ @@ -32607,7 +33488,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 netif_printk(lp, ifup, KERN_DEBUG, dev, "%s() irq %d tx/rx rings %#x/%#x init %#x\n", -@@ -2032,14 +2032,14 @@ static int pcnet32_open(struct net_devic +@@ -2032,14 +2032,14 @@ static int pcnet32_open(struct net_device *dev) (u32) (lp->init_dma_addr)); =20 /* set/reset autoselect bit */ @@ -32625,7 +33506,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c if (lp->options & PCNET32_PORT_FD) { val |=3D 1; if (lp->options =3D=3D (PCNET32_PORT_FD | PCNET32_PORT_AUI)) -@@ -2049,14 +2049,14 @@ static int pcnet32_open(struct net_devic +@@ -2049,14 +2049,14 @@ static int pcnet32_open(struct net_device *dev) if (lp->chip_version =3D=3D 0x2627) val |=3D 3; } @@ -32643,7 +33524,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 /* Allied Telesyn AT 2700/2701 FX are 100Mbit only and do not negotiat= e */ if (pdev && pdev->subsystem_vendor =3D=3D PCI_VENDOR_ID_AT && -@@ -2075,24 +2075,24 @@ static int pcnet32_open(struct net_devic +@@ -2075,24 +2075,24 @@ static int pcnet32_open(struct net_device *dev) * duplex, and/or enable auto negotiation, and clear DANAS */ if (lp->mii && !(lp->options & PCNET32_PORT_ASEL)) { @@ -32676,7 +33557,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } } } else { -@@ -2105,10 +2105,10 @@ static int pcnet32_open(struct net_devic +@@ -2105,10 +2105,10 @@ static int pcnet32_open(struct net_device *dev) * There is really no good other way to handle multiple PHYs * other than turning off all automatics */ @@ -32691,7 +33572,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 if (!(lp->options & PCNET32_PORT_ASEL)) { /* setup ecmd */ -@@ -2118,7 +2118,7 @@ static int pcnet32_open(struct net_devic +@@ -2118,7 +2118,7 @@ static int pcnet32_open(struct net_device *dev) ethtool_cmd_speed_set(&ecmd, (lp->options & PCNET32_PORT_100) ? SPEED_100 : SPEED_10); @@ -32700,7 +33581,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 if (lp->options & PCNET32_PORT_FD) { ecmd.duplex =3D DUPLEX_FULL; -@@ -2127,7 +2127,7 @@ static int pcnet32_open(struct net_devic +@@ -2127,7 +2127,7 @@ static int pcnet32_open(struct net_device *dev) ecmd.duplex =3D DUPLEX_HALF; bcr9 |=3D ~(1 << 0); } @@ -32709,7 +33590,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } =20 for (i =3D 0; i < PCNET32_MAX_PHYS; i++) { -@@ -2158,9 +2158,9 @@ static int pcnet32_open(struct net_devic +@@ -2158,9 +2158,9 @@ static int pcnet32_open(struct net_device *dev) =20 #ifdef DO_DXSUFLO if (lp->dxsuflo) { /* Disable transmit stop on underflow */ @@ -32721,7 +33602,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } #endif =20 -@@ -2176,11 +2176,11 @@ static int pcnet32_open(struct net_devic +@@ -2176,11 +2176,11 @@ static int pcnet32_open(struct net_device *dev) napi_enable(&lp->napi); =20 /* Re-initialize the PCNET32, and start it when done. */ @@ -32737,7 +33618,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 netif_start_queue(dev); =20 -@@ -2192,19 +2192,19 @@ static int pcnet32_open(struct net_devic +@@ -2192,19 +2192,19 @@ static int pcnet32_open(struct net_device *dev) =20 i =3D 0; while (i++ < 100) @@ -32769,7 +33650,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 err_free_irq: spin_unlock_irqrestore(&lp->lock, flags); -@@ -2323,7 +2323,7 @@ static void pcnet32_restart(struct net_d +@@ -2323,7 +2323,7 @@ static void pcnet32_restart(struct net_device *dev= , unsigned int csr0_bits) =20 /* wait for stop */ for (i =3D 0; i < 100; i++) @@ -32778,7 +33659,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c break; =20 if (i >=3D 100) -@@ -2335,13 +2335,13 @@ static void pcnet32_restart(struct net_d +@@ -2335,13 +2335,13 @@ static void pcnet32_restart(struct net_device *d= ev, unsigned int csr0_bits) return; =20 /* ReInit Ring */ @@ -32795,7 +33676,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } =20 static void pcnet32_tx_timeout(struct net_device *dev) -@@ -2353,8 +2353,8 @@ static void pcnet32_tx_timeout(struct ne +@@ -2353,8 +2353,8 @@ static void pcnet32_tx_timeout(struct net_device *= dev) /* Transmitter timeout, serious problems. */ if (pcnet32_debug & NETIF_MSG_DRV) pr_err("%s: transmit timed out, status %4.4x, resetting\n", @@ -32806,7 +33687,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c dev->stats.tx_errors++; if (netif_msg_tx_err(lp)) { int i; -@@ -2397,7 +2397,7 @@ static netdev_tx_t pcnet32_start_xmit(st +@@ -2397,7 +2397,7 @@ static netdev_tx_t pcnet32_start_xmit(struct sk_bu= ff *skb, =20 netif_printk(lp, tx_queued, KERN_DEBUG, dev, "%s() called, csr0 %4.4x\n", @@ -32815,7 +33696,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 /* Default status -- will not enable Successful-TxDone * interrupt when that option is available to us. -@@ -2427,7 +2427,7 @@ static netdev_tx_t pcnet32_start_xmit(st +@@ -2427,7 +2427,7 @@ static netdev_tx_t pcnet32_start_xmit(struct sk_bu= ff *skb, dev->stats.tx_bytes +=3D skb->len; =20 /* Trigger an immediate send poll. */ @@ -32868,7 +33749,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 spin_unlock(&lp->lock); =20 -@@ -2520,20 +2520,20 @@ static int pcnet32_close(struct net_devi +@@ -2520,20 +2520,20 @@ static int pcnet32_close(struct net_device *dev) =20 spin_lock_irqsave(&lp->lock, flags); =20 @@ -32893,7 +33774,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 spin_unlock_irqrestore(&lp->lock, flags); =20 -@@ -2556,7 +2556,7 @@ static struct net_device_stats *pcnet32_ +@@ -2556,7 +2556,7 @@ static struct net_device_stats *pcnet32_get_stats(= struct net_device *dev) unsigned long flags; =20 spin_lock_irqsave(&lp->lock, flags); @@ -32902,7 +33783,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c spin_unlock_irqrestore(&lp->lock, flags); =20 return &dev->stats; -@@ -2577,10 +2577,10 @@ static void pcnet32_load_multicast(struc +@@ -2577,10 +2577,10 @@ static void pcnet32_load_multicast(struct net_de= vice *dev) if (dev->flags & IFF_ALLMULTI) { ib->filter[0] =3D cpu_to_le32(~0U); ib->filter[1] =3D cpu_to_le32(~0U); @@ -32917,7 +33798,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c return; } /* clear the multicast filter */ -@@ -2594,7 +2594,7 @@ static void pcnet32_load_multicast(struc +@@ -2594,7 +2594,7 @@ static void pcnet32_load_multicast(struct net_devi= ce *dev) mcast_table[crc >> 4] |=3D cpu_to_le16(1 << (crc & 0xf)); } for (i =3D 0; i < 4; i++) @@ -32926,7 +33807,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c le16_to_cpu(mcast_table[i])); } =20 -@@ -2609,28 +2609,28 @@ static void pcnet32_set_multicast_list(s +@@ -2609,28 +2609,28 @@ static void pcnet32_set_multicast_list(struct ne= t_device *dev) =20 spin_lock_irqsave(&lp->lock, flags); suspended =3D pcnet32_suspend(dev, &flags, 0); @@ -32961,7 +33842,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c pcnet32_restart(dev, CSR0_NORMAL); netif_wake_queue(dev); } -@@ -2648,8 +2648,8 @@ static int mdio_read(struct net_device * +@@ -2648,8 +2648,8 @@ static int mdio_read(struct net_device *dev, int p= hy_id, int reg_num) if (!lp->mii) return 0; =20 @@ -32972,7 +33853,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c =20 return val_out; } -@@ -2663,8 +2663,8 @@ static void mdio_write(struct net_device +@@ -2663,8 +2663,8 @@ static void mdio_write(struct net_device *dev, int= phy_id, int reg_num, int val) if (!lp->mii) return; =20 @@ -32983,7 +33864,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } =20 static int pcnet32_ioctl(struct net_device *dev, struct ifreq *rq, int = cmd) -@@ -2741,7 +2741,7 @@ static void pcnet32_check_media(struct n +@@ -2741,7 +2741,7 @@ static void pcnet32_check_media(struct net_device = *dev, int verbose) curr_link =3D mii_link_ok(&lp->mii_if); } else { ulong ioaddr =3D dev->base_addr; /* card base I/O address */ @@ -32992,7 +33873,7 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c linu= x-3.1.4/drivers/net/pcnet32.c } if (!curr_link) { if (prev_link || verbose) { -@@ -2764,13 +2764,13 @@ static void pcnet32_check_media(struct n +@@ -2764,13 +2764,13 @@ static void pcnet32_check_media(struct net_devic= e *dev, int verbose) (ecmd.duplex =3D=3D DUPLEX_FULL) ? "full" : "half"); } @@ -33008,10 +33889,11 @@ diff -urNp linux-3.1.4/drivers/net/pcnet32.c li= nux-3.1.4/drivers/net/pcnet32.c } } else { netif_info(lp, link, dev, "link up\n"); -diff -urNp linux-3.1.4/drivers/net/ppp_generic.c linux-3.1.4/drivers/net= /ppp_generic.c ---- linux-3.1.4/drivers/net/ppp_generic.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/net/ppp_generic.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -987,7 +987,6 @@ ppp_net_ioctl(struct net_device *dev, st +diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c +index edfa15d..002bfa9 100644 +--- a/drivers/net/ppp_generic.c ++++ b/drivers/net/ppp_generic.c +@@ -987,7 +987,6 @@ ppp_net_ioctl(struct net_device *dev, struct ifreq *= ifr, int cmd) void __user *addr =3D (void __user *) ifr->ifr_ifru.ifru_data; struct ppp_stats stats; struct ppp_comp_stats cstats; @@ -33019,7 +33901,7 @@ diff -urNp linux-3.1.4/drivers/net/ppp_generic.c = linux-3.1.4/drivers/net/ppp_gen =20 switch (cmd) { case SIOCGPPPSTATS: -@@ -1009,8 +1008,7 @@ ppp_net_ioctl(struct net_device *dev, st +@@ -1009,8 +1008,7 @@ ppp_net_ioctl(struct net_device *dev, struct ifreq= *ifr, int cmd) break; =20 case SIOCGPPPVER: @@ -33029,9 +33911,10 @@ diff -urNp linux-3.1.4/drivers/net/ppp_generic.c= linux-3.1.4/drivers/net/ppp_gen break; err =3D 0; break; -diff -urNp linux-3.1.4/drivers/net/r8169.c linux-3.1.4/drivers/net/r8169= .c ---- linux-3.1.4/drivers/net/r8169.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/r8169.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c +index 6d657ca..d1be94b 100644 +--- a/drivers/net/r8169.c ++++ b/drivers/net/r8169.c @@ -663,12 +663,12 @@ struct rtl8169_private { struct mdio_ops { void (*write)(void __iomem *, int, int); @@ -33047,10 +33930,11 @@ diff -urNp linux-3.1.4/drivers/net/r8169.c linu= x-3.1.4/drivers/net/r8169.c =20 int (*set_speed)(struct net_device *, u8 aneg, u16 sp, u8 dpx, u32 adv= ); int (*get_settings)(struct net_device *, struct ethtool_cmd *); -diff -urNp linux-3.1.4/drivers/net/sis190.c linux-3.1.4/drivers/net/sis1= 90.c ---- linux-3.1.4/drivers/net/sis190.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/sis190.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1624,7 +1624,7 @@ static int __devinit sis190_get_mac_addr +diff --git a/drivers/net/sis190.c b/drivers/net/sis190.c +index 3c0f131..17f8b02 100644 +--- a/drivers/net/sis190.c ++++ b/drivers/net/sis190.c +@@ -1624,7 +1624,7 @@ static int __devinit sis190_get_mac_addr_from_eepr= om(struct pci_dev *pdev, static int __devinit sis190_get_mac_addr_from_apc(struct pci_dev *pdev, struct net_device *dev) { @@ -33059,9 +33943,10 @@ diff -urNp linux-3.1.4/drivers/net/sis190.c linu= x-3.1.4/drivers/net/sis190.c struct sis190_private *tp =3D netdev_priv(dev); struct pci_dev *isa_bridge; u8 reg, tmp8; -diff -urNp linux-3.1.4/drivers/net/sundance.c linux-3.1.4/drivers/net/su= ndance.c ---- linux-3.1.4/drivers/net/sundance.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/net/sundance.c 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/drivers/net/sundance.c b/drivers/net/sundance.c +index 4793df8..44c9849 100644 +--- a/drivers/net/sundance.c ++++ b/drivers/net/sundance.c @@ -218,7 +218,7 @@ enum { struct pci_id_info { const char *name; @@ -33071,9 +33956,10 @@ diff -urNp linux-3.1.4/drivers/net/sundance.c li= nux-3.1.4/drivers/net/sundance.c {"D-Link DFE-550TX FAST Ethernet Adapter"}, {"D-Link DFE-550FX 100Mbps Fiber-optics Adapter"}, {"D-Link DFE-580TX 4 port Server Adapter"}, -diff -urNp linux-3.1.4/drivers/net/tg3.h linux-3.1.4/drivers/net/tg3.h ---- linux-3.1.4/drivers/net/tg3.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/tg3.h 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h +index 2ea456d..3ad9523 100644 +--- a/drivers/net/tg3.h ++++ b/drivers/net/tg3.h @@ -134,6 +134,7 @@ #define CHIPREV_ID_5750_A0 0x4000 #define CHIPREV_ID_5750_A1 0x4001 @@ -33082,10 +33968,11 @@ diff -urNp linux-3.1.4/drivers/net/tg3.h linux-= 3.1.4/drivers/net/tg3.h #define CHIPREV_ID_5750_C2 0x4202 #define CHIPREV_ID_5752_A0_HW 0x5000 #define CHIPREV_ID_5752_A0 0x6000 -diff -urNp linux-3.1.4/drivers/net/tokenring/abyss.c linux-3.1.4/drivers= /net/tokenring/abyss.c ---- linux-3.1.4/drivers/net/tokenring/abyss.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/net/tokenring/abyss.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -451,10 +451,12 @@ static struct pci_driver abyss_driver =3D=20 +diff --git a/drivers/net/tokenring/abyss.c b/drivers/net/tokenring/abyss= .c +index 515f122..41dd273 100644 +--- a/drivers/net/tokenring/abyss.c ++++ b/drivers/net/tokenring/abyss.c +@@ -451,10 +451,12 @@ static struct pci_driver abyss_driver =3D { =20 static int __init abyss_init (void) { @@ -33101,10 +33988,11 @@ diff -urNp linux-3.1.4/drivers/net/tokenring/ab= yss.c linux-3.1.4/drivers/net/tok =20 return pci_register_driver(&abyss_driver); } -diff -urNp linux-3.1.4/drivers/net/tokenring/madgemc.c linux-3.1.4/drive= rs/net/tokenring/madgemc.c ---- linux-3.1.4/drivers/net/tokenring/madgemc.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/net/tokenring/madgemc.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -744,9 +744,11 @@ static struct mca_driver madgemc_driver=20 +diff --git a/drivers/net/tokenring/madgemc.c b/drivers/net/tokenring/mad= gemc.c +index 6153cfd..cf69c1c 100644 +--- a/drivers/net/tokenring/madgemc.c ++++ b/drivers/net/tokenring/madgemc.c +@@ -744,9 +744,11 @@ static struct mca_driver madgemc_driver =3D { =20 static int __init madgemc_init (void) { @@ -33119,9 +34007,10 @@ diff -urNp linux-3.1.4/drivers/net/tokenring/mad= gemc.c linux-3.1.4/drivers/net/t =20 return mca_register_driver (&madgemc_driver); } -diff -urNp linux-3.1.4/drivers/net/tokenring/proteon.c linux-3.1.4/drive= rs/net/tokenring/proteon.c ---- linux-3.1.4/drivers/net/tokenring/proteon.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/net/tokenring/proteon.c 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/net/tokenring/proteon.c b/drivers/net/tokenring/pro= teon.c +index 8d362e6..f91cc52 100644 +--- a/drivers/net/tokenring/proteon.c ++++ b/drivers/net/tokenring/proteon.c @@ -353,9 +353,11 @@ static int __init proteon_init(void) struct platform_device *pdev; int i, num =3D 0, err =3D 0; @@ -33137,9 +34026,10 @@ diff -urNp linux-3.1.4/drivers/net/tokenring/pro= teon.c linux-3.1.4/drivers/net/t =20 err =3D platform_driver_register(&proteon_driver); if (err) -diff -urNp linux-3.1.4/drivers/net/tokenring/skisa.c linux-3.1.4/drivers= /net/tokenring/skisa.c ---- linux-3.1.4/drivers/net/tokenring/skisa.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/net/tokenring/skisa.c 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/drivers/net/tokenring/skisa.c b/drivers/net/tokenring/skisa= .c +index 46db5c5..37c1536 100644 +--- a/drivers/net/tokenring/skisa.c ++++ b/drivers/net/tokenring/skisa.c @@ -363,9 +363,11 @@ static int __init sk_isa_init(void) struct platform_device *pdev; int i, num =3D 0, err =3D 0; @@ -33155,10 +34045,11 @@ diff -urNp linux-3.1.4/drivers/net/tokenring/sk= isa.c linux-3.1.4/drivers/net/tok =20 err =3D platform_driver_register(&sk_isa_driver); if (err) -diff -urNp linux-3.1.4/drivers/net/tulip/de2104x.c linux-3.1.4/drivers/n= et/tulip/de2104x.c ---- linux-3.1.4/drivers/net/tulip/de2104x.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/net/tulip/de2104x.c 2011-11-16 18:40:22.00000000= 0 -0500 -@@ -1795,6 +1795,8 @@ static void __devinit de21041_get_srom_i +diff --git a/drivers/net/tulip/de2104x.c b/drivers/net/tulip/de2104x.c +index ce90efc..2676f89 100644 +--- a/drivers/net/tulip/de2104x.c ++++ b/drivers/net/tulip/de2104x.c +@@ -1795,6 +1795,8 @@ static void __devinit de21041_get_srom_info (struc= t de_private *de) struct de_srom_info_leaf *il; void *bufp; =20 @@ -33167,10 +34058,11 @@ diff -urNp linux-3.1.4/drivers/net/tulip/de2104= x.c linux-3.1.4/drivers/net/tulip /* download entire eeprom */ for (i =3D 0; i < DE_EEPROM_WORDS; i++) ((__le16 *)ee_data)[i] =3D -diff -urNp linux-3.1.4/drivers/net/tulip/de4x5.c linux-3.1.4/drivers/net= /tulip/de4x5.c ---- linux-3.1.4/drivers/net/tulip/de4x5.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/net/tulip/de4x5.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -5397,7 +5397,7 @@ de4x5_ioctl(struct net_device *dev, stru +diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c +index 959b410..c97fac2 100644 +--- a/drivers/net/tulip/de4x5.c ++++ b/drivers/net/tulip/de4x5.c +@@ -5397,7 +5397,7 @@ de4x5_ioctl(struct net_device *dev, struct ifreq *= rq, int cmd) for (i=3D0; idev_addr[i]; } @@ -33179,7 +34071,7 @@ diff -urNp linux-3.1.4/drivers/net/tulip/de4x5.c = linux-3.1.4/drivers/net/tulip/d break; =20 case DE4X5_SET_HWADDR: /* Set the hardware address */ -@@ -5437,7 +5437,7 @@ de4x5_ioctl(struct net_device *dev, stru +@@ -5437,7 +5437,7 @@ de4x5_ioctl(struct net_device *dev, struct ifreq *= rq, int cmd) spin_lock_irqsave(&lp->lock, flags); memcpy(&statbuf, &lp->pktStats, ioc->len); spin_unlock_irqrestore(&lp->lock, flags); @@ -33188,10 +34080,11 @@ diff -urNp linux-3.1.4/drivers/net/tulip/de4x5.= c linux-3.1.4/drivers/net/tulip/d return -EFAULT; break; } -diff -urNp linux-3.1.4/drivers/net/tulip/eeprom.c linux-3.1.4/drivers/ne= t/tulip/eeprom.c ---- linux-3.1.4/drivers/net/tulip/eeprom.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/net/tulip/eeprom.c 2011-11-16 18:39:07.000000000= -0500 -@@ -81,7 +81,7 @@ static struct eeprom_fixup eeprom_fixups +diff --git a/drivers/net/tulip/eeprom.c b/drivers/net/tulip/eeprom.c +index fa5eee9..e074432 100644 +--- a/drivers/net/tulip/eeprom.c ++++ b/drivers/net/tulip/eeprom.c +@@ -81,7 +81,7 @@ static struct eeprom_fixup eeprom_fixups[] __devinitda= ta =3D { {NULL}}; =20 =20 @@ -33200,9 +34093,10 @@ diff -urNp linux-3.1.4/drivers/net/tulip/eeprom.= c linux-3.1.4/drivers/net/tulip/ "21140 non-MII", "21140 MII PHY", "21142 Serial PHY", -diff -urNp linux-3.1.4/drivers/net/tulip/winbond-840.c linux-3.1.4/drive= rs/net/tulip/winbond-840.c ---- linux-3.1.4/drivers/net/tulip/winbond-840.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/net/tulip/winbond-840.c 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/net/tulip/winbond-840.c b/drivers/net/tulip/winbond= -840.c +index 862eadf..3eee1e6 100644 +--- a/drivers/net/tulip/winbond-840.c ++++ b/drivers/net/tulip/winbond-840.c @@ -236,7 +236,7 @@ struct pci_id_info { int drv_flags; /* Driver use, intended as capability flags. */ }; @@ -33212,9 +34106,10 @@ diff -urNp linux-3.1.4/drivers/net/tulip/winbond= -840.c linux-3.1.4/drivers/net/t { /* Sometime a Level-One switch card. */ "Winbond W89c840", CanHaveMII | HasBrokenTx | FDXOnNoMII}, { "Winbond W89c840", CanHaveMII | HasBrokenTx}, -diff -urNp linux-3.1.4/drivers/net/usb/hso.c linux-3.1.4/drivers/net/usb= /hso.c ---- linux-3.1.4/drivers/net/usb/hso.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/net/usb/hso.c 2011-11-16 18:39:07.000000000 -050= 0 +diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c +index 304fe78..db112fa 100644 +--- a/drivers/net/usb/hso.c ++++ b/drivers/net/usb/hso.c @@ -71,7 +71,7 @@ #include #include @@ -33233,7 +34128,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c spinlock_t serial_lock; =20 int (*write_data) (struct hso_serial *serial); -@@ -1190,7 +1190,7 @@ static void put_rxbuf_data_and_resubmit_ +@@ -1190,7 +1190,7 @@ static void put_rxbuf_data_and_resubmit_ctrl_urb(s= truct hso_serial *serial) struct urb *urb; =20 urb =3D serial->rx_urb[0]; @@ -33242,7 +34137,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c count =3D put_rxbuf_data(urb, serial); if (count =3D=3D -1) return; -@@ -1226,7 +1226,7 @@ static void hso_std_serial_read_bulk_cal +@@ -1226,7 +1226,7 @@ static void hso_std_serial_read_bulk_callback(stru= ct urb *urb) DUMP1(urb->transfer_buffer, urb->actual_length); =20 /* Anyone listening? */ @@ -33251,7 +34146,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c return; =20 if (status =3D=3D 0) { -@@ -1311,8 +1311,7 @@ static int hso_serial_open(struct tty_st +@@ -1311,8 +1311,7 @@ static int hso_serial_open(struct tty_struct *tty,= struct file *filp) spin_unlock_irq(&serial->serial_lock); =20 /* check for port already opened, if not set the termios */ @@ -33261,7 +34156,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c serial->rx_state =3D RX_IDLE; /* Force default termio settings */ _hso_serial_set_termios(tty, NULL); -@@ -1324,7 +1323,7 @@ static int hso_serial_open(struct tty_st +@@ -1324,7 +1323,7 @@ static int hso_serial_open(struct tty_struct *tty,= struct file *filp) result =3D hso_start_serial_device(serial->parent, GFP_KERNEL); if (result) { hso_stop_serial_device(serial->parent); @@ -33270,7 +34165,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c kref_put(&serial->parent->ref, hso_serial_ref_free); } } else { -@@ -1361,10 +1360,10 @@ static void hso_serial_close(struct tty_ +@@ -1361,10 +1360,10 @@ static void hso_serial_close(struct tty_struct *= tty, struct file *filp) =20 /* reset the rts and dtr */ /* do the actual close */ @@ -33284,7 +34179,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c spin_lock_irq(&serial->serial_lock); if (serial->tty =3D=3D tty) { serial->tty->driver_data =3D NULL; -@@ -1446,7 +1445,7 @@ static void hso_serial_set_termios(struc +@@ -1446,7 +1445,7 @@ static void hso_serial_set_termios(struct tty_stru= ct *tty, struct ktermios *old) =20 /* the actual setup */ spin_lock_irqsave(&serial->serial_lock, flags); @@ -33293,7 +34188,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c _hso_serial_set_termios(tty, old); else tty->termios =3D old; -@@ -1905,7 +1904,7 @@ static void intr_callback(struct urb *ur +@@ -1905,7 +1904,7 @@ static void intr_callback(struct urb *urb) D1("Pending read interrupt on port %d\n", i); spin_lock(&serial->serial_lock); if (serial->rx_state =3D=3D RX_IDLE && @@ -33302,7 +34197,7 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c linu= x-3.1.4/drivers/net/usb/hso.c /* Setup and send a ctrl req read on * port i */ if (!serial->rx_urb_filled[0]) { -@@ -3098,7 +3097,7 @@ static int hso_resume(struct usb_interfa +@@ -3098,7 +3097,7 @@ static int hso_resume(struct usb_interface *iface) /* Start all serial ports */ for (i =3D 0; i < HSO_SERIAL_TTY_MINORS; i++) { if (serial_table[i] && (serial_table[i]->interface =3D=3D iface)) { @@ -33311,10 +34206,11 @@ diff -urNp linux-3.1.4/drivers/net/usb/hso.c li= nux-3.1.4/drivers/net/usb/hso.c result =3D hso_start_serial_device(serial_table[i], GFP_NOIO); hso_kick_transmit(dev2ser(serial_table[i])); -diff -urNp linux-3.1.4/drivers/net/vmxnet3/vmxnet3_ethtool.c linux-3.1.4= /drivers/net/vmxnet3/vmxnet3_ethtool.c ---- linux-3.1.4/drivers/net/vmxnet3/vmxnet3_ethtool.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/net/vmxnet3/vmxnet3_ethtool.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -601,8 +601,7 @@ vmxnet3_set_rss_indir(struct net_device=20 +diff --git a/drivers/net/vmxnet3/vmxnet3_ethtool.c b/drivers/net/vmxnet3= /vmxnet3_ethtool.c +index 27400ed..c796e05 100644 +--- a/drivers/net/vmxnet3/vmxnet3_ethtool.c ++++ b/drivers/net/vmxnet3/vmxnet3_ethtool.c +@@ -601,8 +601,7 @@ vmxnet3_set_rss_indir(struct net_device *netdev, * Return with error code if any of the queue indices * is out of range */ @@ -33324,9 +34220,10 @@ diff -urNp linux-3.1.4/drivers/net/vmxnet3/vmxne= t3_ethtool.c linux-3.1.4/drivers return -EINVAL; } =20 -diff -urNp linux-3.1.4/drivers/net/vxge/vxge-config.h linux-3.1.4/driver= s/net/vxge/vxge-config.h ---- linux-3.1.4/drivers/net/vxge/vxge-config.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/net/vxge/vxge-config.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/drivers/net/vxge/vxge-config.h b/drivers/net/vxge/vxge-conf= ig.h +index dd36258..e47fd31 100644 +--- a/drivers/net/vxge/vxge-config.h ++++ b/drivers/net/vxge/vxge-config.h @@ -514,7 +514,7 @@ struct vxge_hw_uld_cbs { void (*link_down)(struct __vxge_hw_device *devh); void (*crit_err)(struct __vxge_hw_device *devh, @@ -33336,10 +34233,11 @@ diff -urNp linux-3.1.4/drivers/net/vxge/vxge-co= nfig.h linux-3.1.4/drivers/net/vx =20 /* * struct __vxge_hw_blockpool_entry - Block private data structure -diff -urNp linux-3.1.4/drivers/net/vxge/vxge-main.c linux-3.1.4/drivers/= net/vxge/vxge-main.c ---- linux-3.1.4/drivers/net/vxge/vxge-main.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/net/vxge/vxge-main.c 2011-11-16 18:40:22.0000000= 00 -0500 -@@ -100,6 +100,8 @@ static inline void VXGE_COMPLETE_VPATH_T +diff --git a/drivers/net/vxge/vxge-main.c b/drivers/net/vxge/vxge-main.c +index 178348a2..18bb433 100644 +--- a/drivers/net/vxge/vxge-main.c ++++ b/drivers/net/vxge/vxge-main.c +@@ -100,6 +100,8 @@ static inline void VXGE_COMPLETE_VPATH_TX(struct vxg= e_fifo *fifo) struct sk_buff *completed[NR_SKB_COMPLETED]; int more; =20 @@ -33348,7 +34246,7 @@ diff -urNp linux-3.1.4/drivers/net/vxge/vxge-main= .c linux-3.1.4/drivers/net/vxge do { more =3D 0; skb_ptr =3D completed; -@@ -1915,6 +1917,8 @@ static enum vxge_hw_status vxge_rth_conf +@@ -1915,6 +1917,8 @@ static enum vxge_hw_status vxge_rth_configure(stru= ct vxgedev *vdev) u8 mtable[256] =3D {0}; /* CPU to vpath mapping */ int index; =20 @@ -33357,9 +34255,10 @@ diff -urNp linux-3.1.4/drivers/net/vxge/vxge-mai= n.c linux-3.1.4/drivers/net/vxge /* * Filling * - itable with bucket numbers -diff -urNp linux-3.1.4/drivers/net/vxge/vxge-traffic.h linux-3.1.4/drive= rs/net/vxge/vxge-traffic.h ---- linux-3.1.4/drivers/net/vxge/vxge-traffic.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/net/vxge/vxge-traffic.h 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/net/vxge/vxge-traffic.h b/drivers/net/vxge/vxge-tra= ffic.h +index 4a518a3..936b334 100644 +--- a/drivers/net/vxge/vxge-traffic.h ++++ b/drivers/net/vxge/vxge-traffic.h @@ -2088,7 +2088,7 @@ struct vxge_hw_mempool_cbs { struct vxge_hw_mempool_dma *dma_object, u32 index, @@ -33369,10 +34268,11 @@ diff -urNp linux-3.1.4/drivers/net/vxge/vxge-tr= affic.h linux-3.1.4/drivers/net/v =20 #define VXGE_HW_VIRTUAL_PATH_HANDLE(vpath) \ ((struct __vxge_hw_vpath_handle *)(vpath)->vpath_handles.next) -diff -urNp linux-3.1.4/drivers/net/wan/hdlc_x25.c linux-3.1.4/drivers/ne= t/wan/hdlc_x25.c ---- linux-3.1.4/drivers/net/wan/hdlc_x25.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/net/wan/hdlc_x25.c 2011-11-16 18:39:07.000000000= -0500 -@@ -134,16 +134,16 @@ static netdev_tx_t x25_xmit(struct sk_bu +diff --git a/drivers/net/wan/hdlc_x25.c b/drivers/net/wan/hdlc_x25.c +index 56aeb01..547f71f 100644 +--- a/drivers/net/wan/hdlc_x25.c ++++ b/drivers/net/wan/hdlc_x25.c +@@ -134,16 +134,16 @@ static netdev_tx_t x25_xmit(struct sk_buff *skb, s= truct net_device *dev) =20 static int x25_open(struct net_device *dev) { @@ -33397,10 +34297,11 @@ diff -urNp linux-3.1.4/drivers/net/wan/hdlc_x25= .c linux-3.1.4/drivers/net/wan/hd result =3D lapb_register(dev, &cb); if (result !=3D LAPB_OK) return result; -diff -urNp linux-3.1.4/drivers/net/wimax/i2400m/usb-fw.c linux-3.1.4/dri= vers/net/wimax/i2400m/usb-fw.c ---- linux-3.1.4/drivers/net/wimax/i2400m/usb-fw.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/net/wimax/i2400m/usb-fw.c 2011-11-16 18:40:22.00= 0000000 -0500 -@@ -287,6 +287,8 @@ ssize_t i2400mu_bus_bm_wait_for_ack(stru +diff --git a/drivers/net/wimax/i2400m/usb-fw.c b/drivers/net/wimax/i2400= m/usb-fw.c +index 1fda46c..f2858f2 100644 +--- a/drivers/net/wimax/i2400m/usb-fw.c ++++ b/drivers/net/wimax/i2400m/usb-fw.c +@@ -287,6 +287,8 @@ ssize_t i2400mu_bus_bm_wait_for_ack(struct i2400m *i= 2400m, int do_autopm =3D 1; DECLARE_COMPLETION_ONSTACK(notif_completion); =20 @@ -33409,10 +34310,11 @@ diff -urNp linux-3.1.4/drivers/net/wimax/i2400m= /usb-fw.c linux-3.1.4/drivers/net d_fnstart(8, dev, "(i2400m %p ack %p size %zu)\n", i2400m, ack, ack_size); BUG_ON(_ack =3D=3D i2400m->bm_ack_buf); -diff -urNp linux-3.1.4/drivers/net/wireless/airo.c linux-3.1.4/drivers/n= et/wireless/airo.c ---- linux-3.1.4/drivers/net/wireless/airo.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/net/wireless/airo.c 2011-11-16 18:40:22.00000000= 0 -0500 -@@ -3003,6 +3003,8 @@ static void airo_process_scan_results (s +diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c +index e1b3e3c..e413f18 100644 +--- a/drivers/net/wireless/airo.c ++++ b/drivers/net/wireless/airo.c +@@ -3003,6 +3003,8 @@ static void airo_process_scan_results (struct airo= _info *ai) { BSSListElement * loop_net; BSSListElement * tmp_net; =20 @@ -33421,7 +34323,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/airo.= c linux-3.1.4/drivers/net/wirel /* Blow away current list of scan results */ list_for_each_entry_safe (loop_net, tmp_net, &ai->network_list, list) = { list_move_tail (&loop_net->list, &ai->network_free_list); -@@ -3794,6 +3796,8 @@ static u16 setup_card(struct airo_info * +@@ -3794,6 +3796,8 @@ static u16 setup_card(struct airo_info *ai, u8 *ma= c, int lock) WepKeyRid wkr; int rc; =20 @@ -33430,7 +34332,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/airo.= c linux-3.1.4/drivers/net/wirel memset( &mySsid, 0, sizeof( mySsid ) ); kfree (ai->flash); ai->flash =3D NULL; -@@ -4753,6 +4757,8 @@ static int proc_stats_rid_open( struct i +@@ -4753,6 +4757,8 @@ static int proc_stats_rid_open( struct inode *inod= e, __le32 *vals =3D stats.vals; int len; =20 @@ -33439,7 +34341,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/airo.= c linux-3.1.4/drivers/net/wirel if ((file->private_data =3D kzalloc(sizeof(struct proc_data ), GFP_KER= NEL)) =3D=3D NULL) return -ENOMEM; data =3D file->private_data; -@@ -5476,6 +5482,8 @@ static int proc_BSSList_open( struct ino +@@ -5476,6 +5482,8 @@ static int proc_BSSList_open( struct inode *inode,= struct file *file ) { /* If doLoseSync is not 1, we won't do a Lose Sync */ int doLoseSync =3D -1; =20 @@ -33448,7 +34350,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/airo.= c linux-3.1.4/drivers/net/wirel if ((file->private_data =3D kzalloc(sizeof(struct proc_data ), GFP_KER= NEL)) =3D=3D NULL) return -ENOMEM; data =3D file->private_data; -@@ -7181,6 +7189,8 @@ static int airo_get_aplist(struct net_de +@@ -7181,6 +7189,8 @@ static int airo_get_aplist(struct net_device *dev, int i; int loseSync =3D capable(CAP_NET_ADMIN) ? 1: -1; =20 @@ -33457,7 +34359,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/airo.= c linux-3.1.4/drivers/net/wirel qual =3D kmalloc(IW_MAX_AP * sizeof(*qual), GFP_KERNEL); if (!qual) return -ENOMEM; -@@ -7741,6 +7751,8 @@ static void airo_read_wireless_stats(str +@@ -7741,6 +7751,8 @@ static void airo_read_wireless_stats(struct airo_i= nfo *local) CapabilityRid cap_rid; __le32 *vals =3D stats_rid.vals; =20 @@ -33466,10 +34368,23 @@ diff -urNp linux-3.1.4/drivers/net/wireless/air= o.c linux-3.1.4/drivers/net/wirel /* Get stats out of the card */ clear_bit(JOB_WSTATS, &local->jobs); if (local->power.event) { -diff -urNp linux-3.1.4/drivers/net/wireless/ath/ath5k/debug.c linux-3.1.= 4/drivers/net/wireless/ath/ath5k/debug.c ---- linux-3.1.4/drivers/net/wireless/ath/ath5k/debug.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ath/ath5k/debug.c 2011-11-16 19:08:= 21.000000000 -0500 -@@ -203,6 +203,8 @@ static ssize_t read_file_beacon(struct f +diff --git a/drivers/net/wireless/ath/ath.h b/drivers/net/wireless/ath/a= th.h +index 17c4b56..00d836f 100644 +--- a/drivers/net/wireless/ath/ath.h ++++ b/drivers/net/wireless/ath/ath.h +@@ -121,6 +121,7 @@ struct ath_ops { + void (*write_flush) (void *); + u32 (*rmw)(void *, u32 reg_offset, u32 set, u32 clr); + }; ++typedef struct ath_ops __no_const ath_ops_no_const; +=20 + struct ath_common; + struct ath_bus_ops; +diff --git a/drivers/net/wireless/ath/ath5k/debug.c b/drivers/net/wirele= ss/ath/ath5k/debug.c +index ccca724..7afbadc 100644 +--- a/drivers/net/wireless/ath/ath5k/debug.c ++++ b/drivers/net/wireless/ath/ath5k/debug.c +@@ -203,6 +203,8 @@ static ssize_t read_file_beacon(struct file *file, c= har __user *user_buf, unsigned int v; u64 tsf; =20 @@ -33478,7 +34393,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th5k/debug.c linux-3.1.4/driver v =3D ath5k_hw_reg_read(ah, AR5K_BEACON); len +=3D snprintf(buf + len, sizeof(buf) - len, "%-24s0x%08x\tintval: %d\tTIM: 0x%x\n", -@@ -321,6 +323,8 @@ static ssize_t read_file_debug(struct fi +@@ -321,6 +323,8 @@ static ssize_t read_file_debug(struct file *file, ch= ar __user *user_buf, unsigned int len =3D 0; unsigned int i; =20 @@ -33487,7 +34402,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th5k/debug.c linux-3.1.4/driver len +=3D snprintf(buf + len, sizeof(buf) - len, "DEBUG LEVEL: 0x%08x\n\n", ah->debug.level); =20 -@@ -492,6 +496,8 @@ static ssize_t read_file_misc(struct fil +@@ -492,6 +496,8 @@ static ssize_t read_file_misc(struct file *file, cha= r __user *user_buf, unsigned int len =3D 0; u32 filt =3D ath5k_hw_get_rx_filter(ah); =20 @@ -33496,7 +34411,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th5k/debug.c linux-3.1.4/driver len +=3D snprintf(buf + len, sizeof(buf) - len, "bssid-mask: %pM\n", ah->bssidmask); len +=3D snprintf(buf + len, sizeof(buf) - len, "filter-flags: 0x%x ", -@@ -548,6 +554,8 @@ static ssize_t read_file_frameerrors(str +@@ -548,6 +554,8 @@ static ssize_t read_file_frameerrors(struct file *fi= le, char __user *user_buf, unsigned int len =3D 0; int i; =20 @@ -33505,7 +34420,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th5k/debug.c linux-3.1.4/driver len +=3D snprintf(buf + len, sizeof(buf) - len, "RX\n---------------------\n"); len +=3D snprintf(buf + len, sizeof(buf) - len, "CRC\t%u\t(%u%%)\n", -@@ -665,6 +673,8 @@ static ssize_t read_file_ani(struct file +@@ -665,6 +673,8 @@ static ssize_t read_file_ani(struct file *file, char= __user *user_buf, char buf[700]; unsigned int len =3D 0; =20 @@ -33514,7 +34429,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th5k/debug.c linux-3.1.4/driver len +=3D snprintf(buf + len, sizeof(buf) - len, "HW has PHY error counters:\t%s\n", ah->ah_capabilities.cap_has_phyerr_counters ? -@@ -829,6 +839,8 @@ static ssize_t read_file_queue(struct fi +@@ -829,6 +839,8 @@ static ssize_t read_file_queue(struct file *file, ch= ar __user *user_buf, struct ath5k_buf *bf, *bf0; int i, n; =20 @@ -33523,10 +34438,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath= /ath5k/debug.c linux-3.1.4/driver len +=3D snprintf(buf + len, sizeof(buf) - len, "available txbuffers: %d\n", ah->txbuf_len); =20 -diff -urNp linux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_calib.c lin= ux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_calib.c ---- linux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_calib.c 2011-11-11= 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_calib.c 2011-11-16= 18:40:22.000000000 -0500 -@@ -758,6 +758,8 @@ static void ar9003_hw_tx_iq_cal_post_pro +diff --git a/drivers/net/wireless/ath/ath9k/ar9003_calib.c b/drivers/net= /wireless/ath/ath9k/ar9003_calib.c +index 7c2aaad..ad14dee 100644 +--- a/drivers/net/wireless/ath/ath9k/ar9003_calib.c ++++ b/drivers/net/wireless/ath/ath9k/ar9003_calib.c +@@ -758,6 +758,8 @@ static void ar9003_hw_tx_iq_cal_post_proc(struct ath= _hw *ah) int i, im, j; int nmeasurement; =20 @@ -33535,10 +34451,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath= /ath9k/ar9003_calib.c linux-3.1.4 for (i =3D 0; i < AR9300_MAX_CHAINS; i++) { if (ah->txchainmask & (1 << i)) num_chains++; -diff -urNp linux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_paprd.c lin= ux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_paprd.c ---- linux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_paprd.c 2011-11-11= 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ath/ath9k/ar9003_paprd.c 2011-11-16= 18:40:22.000000000 -0500 -@@ -406,6 +406,8 @@ static bool create_pa_curve(u32 *data_L, +diff --git a/drivers/net/wireless/ath/ath9k/ar9003_paprd.c b/drivers/net= /wireless/ath/ath9k/ar9003_paprd.c +index f80d1d6..08b773d 100644 +--- a/drivers/net/wireless/ath/ath9k/ar9003_paprd.c ++++ b/drivers/net/wireless/ath/ath9k/ar9003_paprd.c +@@ -406,6 +406,8 @@ static bool create_pa_curve(u32 *data_L, u32 *data_U= , u32 *pa_table, u16 *gain) int theta_low_bin =3D 0; int i; =20 @@ -33547,10 +34464,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath= /ath9k/ar9003_paprd.c linux-3.1.4 /* disregard any bin that contains <=3D 16 samples */ thresh_accum_cnt =3D 16; scale_factor =3D 5; -diff -urNp linux-3.1.4/drivers/net/wireless/ath/ath9k/debug.c linux-3.1.= 4/drivers/net/wireless/ath/ath9k/debug.c ---- linux-3.1.4/drivers/net/wireless/ath/ath9k/debug.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ath/ath9k/debug.c 2011-11-16 18:40:= 22.000000000 -0500 -@@ -387,6 +387,8 @@ static ssize_t read_file_interrupt(struc +diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wirele= ss/ath/ath9k/debug.c +index d1eb896..8b67cd4 100644 +--- a/drivers/net/wireless/ath/ath9k/debug.c ++++ b/drivers/net/wireless/ath/ath9k/debug.c +@@ -387,6 +387,8 @@ static ssize_t read_file_interrupt(struct file *file= , char __user *user_buf, char buf[512]; unsigned int len =3D 0; =20 @@ -33559,7 +34477,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th9k/debug.c linux-3.1.4/driver if (sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_EDMA) { len +=3D snprintf(buf + len, sizeof(buf) - len, "%8s: %10u\n", "RXLP", sc->debug.stats.istats.rxlp); -@@ -477,6 +479,8 @@ static ssize_t read_file_wiphy(struct fi +@@ -477,6 +479,8 @@ static ssize_t read_file_wiphy(struct file *file, ch= ar __user *user_buf, u8 addr[ETH_ALEN]; u32 tmp; =20 @@ -33568,10 +34486,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath= /ath9k/debug.c linux-3.1.4/driver len +=3D snprintf(buf + len, sizeof(buf) - len, "%s (chan=3D%d center-freq: %d MHz channel-type: %d (%s))\n", wiphy_name(sc->hw->wiphy), -diff -urNp linux-3.1.4/drivers/net/wireless/ath/ath9k/htc_drv_debug.c li= nux-3.1.4/drivers/net/wireless/ath/ath9k/htc_drv_debug.c ---- linux-3.1.4/drivers/net/wireless/ath/ath9k/htc_drv_debug.c 2011-11-1= 1 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ath/ath9k/htc_drv_debug.c 2011-11-1= 6 18:40:22.000000000 -0500 -@@ -31,6 +31,8 @@ static ssize_t read_file_tgt_int_stats(s +diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_debug.c b/drivers/ne= t/wireless/ath/ath9k/htc_drv_debug.c +index d3ff33c..309398e 100644 +--- a/drivers/net/wireless/ath/ath9k/htc_drv_debug.c ++++ b/drivers/net/wireless/ath/ath9k/htc_drv_debug.c +@@ -31,6 +31,8 @@ static ssize_t read_file_tgt_int_stats(struct file *fi= le, char __user *user_buf, unsigned int len =3D 0; int ret =3D 0; =20 @@ -33580,7 +34499,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th9k/htc_drv_debug.c linux-3.1. memset(&cmd_rsp, 0, sizeof(cmd_rsp)); =20 ath9k_htc_ps_wakeup(priv); -@@ -89,6 +91,8 @@ static ssize_t read_file_tgt_tx_stats(st +@@ -89,6 +91,8 @@ static ssize_t read_file_tgt_tx_stats(struct file *fil= e, char __user *user_buf, unsigned int len =3D 0; int ret =3D 0; =20 @@ -33589,7 +34508,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th9k/htc_drv_debug.c linux-3.1. memset(&cmd_rsp, 0, sizeof(cmd_rsp)); =20 ath9k_htc_ps_wakeup(priv); -@@ -159,6 +163,8 @@ static ssize_t read_file_tgt_rx_stats(st +@@ -159,6 +163,8 @@ static ssize_t read_file_tgt_rx_stats(struct file *f= ile, char __user *user_buf, unsigned int len =3D 0; int ret =3D 0; =20 @@ -33598,7 +34517,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th9k/htc_drv_debug.c linux-3.1. memset(&cmd_rsp, 0, sizeof(cmd_rsp)); =20 ath9k_htc_ps_wakeup(priv); -@@ -203,6 +209,8 @@ static ssize_t read_file_xmit(struct fil +@@ -203,6 +209,8 @@ static ssize_t read_file_xmit(struct file *file, cha= r __user *user_buf, char buf[512]; unsigned int len =3D 0; =20 @@ -33607,7 +34526,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th9k/htc_drv_debug.c linux-3.1. len +=3D snprintf(buf + len, sizeof(buf) - len, "%20s : %10u\n", "Buffers queued", priv->debug.tx_stats.buf_queued); -@@ -376,6 +384,8 @@ static ssize_t read_file_slot(struct fil +@@ -376,6 +384,8 @@ static ssize_t read_file_slot(struct file *file, cha= r __user *user_buf, char buf[512]; unsigned int len =3D 0; =20 @@ -33616,7 +34535,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/a= th9k/htc_drv_debug.c linux-3.1. spin_lock_bh(&priv->tx.tx_lock); =20 len +=3D snprintf(buf + len, sizeof(buf) - len, "TX slot bitmap : "); -@@ -411,6 +421,8 @@ static ssize_t read_file_queue(struct fi +@@ -411,6 +421,8 @@ static ssize_t read_file_queue(struct file *file, ch= ar __user *user_buf, char buf[512]; unsigned int len =3D 0; =20 @@ -33625,9 +34544,10 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath/= ath9k/htc_drv_debug.c linux-3.1. len +=3D snprintf(buf + len, sizeof(buf) - len, "%20s : %10u\n", "Mgmt endpoint", skb_queue_len(&priv->tx.mgmt_ep_queue)); =20 -diff -urNp linux-3.1.4/drivers/net/wireless/ath/ath9k/hw.h linux-3.1.4/d= rivers/net/wireless/ath/ath9k/hw.h ---- linux-3.1.4/drivers/net/wireless/ath/ath9k/hw.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ath/ath9k/hw.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/drivers/net/wireless/ath/ath9k/hw.h b/drivers/net/wireless/= ath/ath9k/hw.h +index c798890..c19a8fb 100644 +--- a/drivers/net/wireless/ath/ath9k/hw.h ++++ b/drivers/net/wireless/ath/ath9k/hw.h @@ -588,7 +588,7 @@ struct ath_hw_private_ops { =20 /* ANI */ @@ -33655,21 +34575,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ath= /ath9k/hw.h linux-3.1.4/drivers/n =20 struct ieee80211_hw *hw; struct ath_common common; -diff -urNp linux-3.1.4/drivers/net/wireless/ath/ath.h linux-3.1.4/driver= s/net/wireless/ath/ath.h ---- linux-3.1.4/drivers/net/wireless/ath/ath.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ath/ath.h 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -121,6 +121,7 @@ struct ath_ops { - void (*write_flush) (void *); - u32 (*rmw)(void *, u32 reg_offset, u32 set, u32 clr); - }; -+typedef struct ath_ops __no_const ath_ops_no_const; -=20 - struct ath_common; - struct ath_bus_ops; -diff -urNp linux-3.1.4/drivers/net/wireless/ipw2x00/ipw2100.c linux-3.1.= 4/drivers/net/wireless/ipw2x00/ipw2100.c ---- linux-3.1.4/drivers/net/wireless/ipw2x00/ipw2100.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ipw2x00/ipw2100.c 2011-11-16 18:40:= 22.000000000 -0500 -@@ -2102,6 +2102,8 @@ static int ipw2100_set_essid(struct ipw2 +diff --git a/drivers/net/wireless/ipw2x00/ipw2100.c b/drivers/net/wirele= ss/ipw2x00/ipw2100.c +index ef9ad79..f5f8d80 100644 +--- a/drivers/net/wireless/ipw2x00/ipw2100.c ++++ b/drivers/net/wireless/ipw2x00/ipw2100.c +@@ -2102,6 +2102,8 @@ static int ipw2100_set_essid(struct ipw2100_priv *= priv, char *essid, int err; DECLARE_SSID_BUF(ssid); =20 @@ -33678,7 +34588,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ipw2x= 00/ipw2100.c linux-3.1.4/driver IPW_DEBUG_HC("SSID: '%s'\n", print_ssid(ssid, essid, ssid_len)); =20 if (ssid_len) -@@ -5451,6 +5453,8 @@ static int ipw2100_set_key(struct ipw210 +@@ -5451,6 +5453,8 @@ static int ipw2100_set_key(struct ipw2100_priv *pr= iv, struct ipw2100_wep_key *wep_key =3D (void *)cmd.host_command_parameter= s; int err; =20 @@ -33687,10 +34597,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ipw= 2x00/ipw2100.c linux-3.1.4/driver IPW_DEBUG_HC("WEP_KEY_INFO: index =3D %d, len =3D %d/%d\n", idx, keylen, len); =20 -diff -urNp linux-3.1.4/drivers/net/wireless/ipw2x00/libipw_rx.c linux-3.= 1.4/drivers/net/wireless/ipw2x00/libipw_rx.c ---- linux-3.1.4/drivers/net/wireless/ipw2x00/libipw_rx.c 2011-11-11 15:1= 9:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/ipw2x00/libipw_rx.c 2011-11-16 18:4= 0:22.000000000 -0500 -@@ -1565,6 +1565,8 @@ static void libipw_process_probe_respons +diff --git a/drivers/net/wireless/ipw2x00/libipw_rx.c b/drivers/net/wire= less/ipw2x00/libipw_rx.c +index 32a9966..de69787 100644 +--- a/drivers/net/wireless/ipw2x00/libipw_rx.c ++++ b/drivers/net/wireless/ipw2x00/libipw_rx.c +@@ -1565,6 +1565,8 @@ static void libipw_process_probe_response(struct l= ibipw_device unsigned long flags; DECLARE_SSID_BUF(ssid); =20 @@ -33699,10 +34610,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/ipw= 2x00/libipw_rx.c linux-3.1.4/driv LIBIPW_DEBUG_SCAN("'%s' (%pM" "): %c%c%c%c %c%c%c%c-%c%c%c%c %c%c%c%c\n", print_ssid(ssid, info_element->data, info_element->len), -diff -urNp linux-3.1.4/drivers/net/wireless/iwlegacy/iwl3945-base.c linu= x-3.1.4/drivers/net/wireless/iwlegacy/iwl3945-base.c ---- linux-3.1.4/drivers/net/wireless/iwlegacy/iwl3945-base.c 2011-11-11 = 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/iwlegacy/iwl3945-base.c 2011-11-16 = 18:39:07.000000000 -0500 -@@ -3687,7 +3687,9 @@ static int iwl3945_pci_probe(struct pci_ +diff --git a/drivers/net/wireless/iwlegacy/iwl3945-base.c b/drivers/net/= wireless/iwlegacy/iwl3945-base.c +index 66ee1562..b90412b 100644 +--- a/drivers/net/wireless/iwlegacy/iwl3945-base.c ++++ b/drivers/net/wireless/iwlegacy/iwl3945-base.c +@@ -3687,7 +3687,9 @@ static int iwl3945_pci_probe(struct pci_dev *pdev,= const struct pci_device_id *e */ if (iwl3945_mod_params.disable_hw_scan) { IWL_DEBUG_INFO(priv, "Disabling hw_scan\n"); @@ -33713,10 +34625,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/iwl= egacy/iwl3945-base.c linux-3.1.4/ } =20 IWL_DEBUG_INFO(priv, "*** LOAD DRIVER ***\n"); -diff -urNp linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-agn-rs.c linux-3= .1.4/drivers/net/wireless/iwlwifi/iwl-agn-rs.c ---- linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-agn-rs.c 2011-11-11 15:= 19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-agn-rs.c 2011-11-16 18:= 40:22.000000000 -0500 -@@ -920,6 +920,8 @@ static void rs_tx_status(void *priv_r, s +diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wir= eless/iwlwifi/iwl-agn-rs.c +index 3789ff4..22ab151 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c ++++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +@@ -920,6 +920,8 @@ static void rs_tx_status(void *priv_r, struct ieee80= 211_supported_band *sband, struct iwl_station_priv *sta_priv =3D (void *)sta->drv_priv; struct iwl_rxon_context *ctx =3D sta_priv->common.ctx; =20 @@ -33725,7 +34638,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/iwlwi= fi/iwl-agn-rs.c linux-3.1.4/dri IWL_DEBUG_RATE_LIMIT(priv, "get frame ack response, update rate scale = window\n"); =20 /* Treat uninitialized rate scaling data same as non-existing. */ -@@ -2931,6 +2933,8 @@ static void rs_fill_link_cmd(struct iwl_ +@@ -2931,6 +2933,8 @@ static void rs_fill_link_cmd(struct iwl_priv *priv= , container_of(lq_sta, struct iwl_station_priv, lq_sta); struct iwl_link_quality_cmd *lq_cmd =3D &lq_sta->lq; =20 @@ -33734,10 +34647,26 @@ diff -urNp linux-3.1.4/drivers/net/wireless/iwl= wifi/iwl-agn-rs.c linux-3.1.4/dri /* Override starting rate (index 0) if needed for debug purposes */ rs_dbgfs_set_mcs(lq_sta, &new_rate, index); =20 -diff -urNp linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-debugfs.c linux-= 3.1.4/drivers/net/wireless/iwlwifi/iwl-debugfs.c ---- linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-debugfs.c 2011-11-11 15= :19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-debugfs.c 2011-11-16 18= :40:22.000000000 -0500 -@@ -561,6 +561,8 @@ static ssize_t iwl_dbgfs_status_read(str +diff --git a/drivers/net/wireless/iwlwifi/iwl-debug.h b/drivers/net/wire= less/iwlwifi/iwl-debug.h +index f9a407e..a6f2bb7 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-debug.h ++++ b/drivers/net/wireless/iwlwifi/iwl-debug.h +@@ -68,8 +68,8 @@ do { \ + } while (0) +=20 + #else +-#define IWL_DEBUG(__priv, level, fmt, args...) +-#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) ++#define IWL_DEBUG(__priv, level, fmt, args...) do {} while (0) ++#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) do {} while (0) + static inline void iwl_print_hex_dump(struct iwl_priv *priv, int level, + const void *p, u32 len) + {} +diff --git a/drivers/net/wireless/iwlwifi/iwl-debugfs.c b/drivers/net/wi= reless/iwlwifi/iwl-debugfs.c +index ec1485b..900c3bd 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-debugfs.c ++++ b/drivers/net/wireless/iwlwifi/iwl-debugfs.c +@@ -561,6 +561,8 @@ static ssize_t iwl_dbgfs_status_read(struct file *fi= le, int pos =3D 0; const size_t bufsz =3D sizeof(buf); =20 @@ -33746,7 +34675,7 @@ diff -urNp linux-3.1.4/drivers/net/wireless/iwlwi= fi/iwl-debugfs.c linux-3.1.4/dr pos +=3D scnprintf(buf + pos, bufsz - pos, "STATUS_HCMD_ACTIVE:\t %d\n= ", test_bit(STATUS_HCMD_ACTIVE, &priv->status)); pos +=3D scnprintf(buf + pos, bufsz - pos, "STATUS_INT_ENABLED:\t %d\n= ", -@@ -693,6 +695,8 @@ static ssize_t iwl_dbgfs_qos_read(struct +@@ -693,6 +695,8 @@ static ssize_t iwl_dbgfs_qos_read(struct file *file,= char __user *user_buf, char buf[256 * NUM_IWL_RXON_CTX]; const size_t bufsz =3D sizeof(buf); =20 @@ -33755,24 +34684,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/iwl= wifi/iwl-debugfs.c linux-3.1.4/dr for_each_context(priv, ctx) { pos +=3D scnprintf(buf + pos, bufsz - pos, "context %d:\n", ctx->ctxid); -diff -urNp linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-debug.h linux-3.= 1.4/drivers/net/wireless/iwlwifi/iwl-debug.h ---- linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-debug.h 2011-11-11 15:1= 9:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/iwlwifi/iwl-debug.h 2011-11-16 18:3= 9:07.000000000 -0500 -@@ -68,8 +68,8 @@ do { =20 - } while (0) -=20 - #else --#define IWL_DEBUG(__priv, level, fmt, args...) --#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) -+#define IWL_DEBUG(__priv, level, fmt, args...) do {} while (0) -+#define IWL_DEBUG_LIMIT(__priv, level, fmt, args...) do {} while (0) - static inline void iwl_print_hex_dump(struct iwl_priv *priv, int level, - const void *p, u32 len) - {} -diff -urNp linux-3.1.4/drivers/net/wireless/iwmc3200wifi/debugfs.c linux= -3.1.4/drivers/net/wireless/iwmc3200wifi/debugfs.c ---- linux-3.1.4/drivers/net/wireless/iwmc3200wifi/debugfs.c 2011-11-11 1= 5:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/iwmc3200wifi/debugfs.c 2011-11-16 1= 8:40:22.000000000 -0500 -@@ -327,6 +327,8 @@ static ssize_t iwm_debugfs_fw_err_read(s +diff --git a/drivers/net/wireless/iwmc3200wifi/debugfs.c b/drivers/net/w= ireless/iwmc3200wifi/debugfs.c +index 0a0cc96..fd49ad8 100644 +--- a/drivers/net/wireless/iwmc3200wifi/debugfs.c ++++ b/drivers/net/wireless/iwmc3200wifi/debugfs.c +@@ -327,6 +327,8 @@ static ssize_t iwm_debugfs_fw_err_read(struct file *= filp, int buf_len =3D 512; size_t len =3D 0; =20 @@ -33781,10 +34697,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/iwm= c3200wifi/debugfs.c linux-3.1.4/d if (*ppos !=3D 0) return 0; if (count < sizeof(buf)) -diff -urNp linux-3.1.4/drivers/net/wireless/mac80211_hwsim.c linux-3.1.4= /drivers/net/wireless/mac80211_hwsim.c ---- linux-3.1.4/drivers/net/wireless/mac80211_hwsim.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/mac80211_hwsim.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -1670,9 +1670,11 @@ static int __init init_mac80211_hwsim(vo +diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireles= s/mac80211_hwsim.c +index 031cd89..bdc8435 100644 +--- a/drivers/net/wireless/mac80211_hwsim.c ++++ b/drivers/net/wireless/mac80211_hwsim.c +@@ -1670,9 +1670,11 @@ static int __init init_mac80211_hwsim(void) return -EINVAL; =20 if (fake_hw_scan) { @@ -33799,9 +34716,10 @@ diff -urNp linux-3.1.4/drivers/net/wireless/mac8= 0211_hwsim.c linux-3.1.4/drivers } =20 spin_lock_init(&hwsim_radio_lock); -diff -urNp linux-3.1.4/drivers/net/wireless/mwifiex/main.h linux-3.1.4/d= rivers/net/wireless/mwifiex/main.h ---- linux-3.1.4/drivers/net/wireless/mwifiex/main.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/mwifiex/main.h 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/drivers/net/wireless/mwifiex/main.h b/drivers/net/wireless/= mwifiex/main.h +index 2215c3c..64e6a47 100644 +--- a/drivers/net/wireless/mwifiex/main.h ++++ b/drivers/net/wireless/mwifiex/main.h @@ -560,7 +560,7 @@ struct mwifiex_if_ops { =20 void (*update_mp_end_port) (struct mwifiex_adapter *, u16); @@ -33811,10 +34729,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/mwi= fiex/main.h linux-3.1.4/drivers/n =20 struct mwifiex_adapter { struct mwifiex_private *priv[MWIFIEX_MAX_BSS_NUM]; -diff -urNp linux-3.1.4/drivers/net/wireless/rndis_wlan.c linux-3.1.4/dri= vers/net/wireless/rndis_wlan.c ---- linux-3.1.4/drivers/net/wireless/rndis_wlan.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/rndis_wlan.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -1277,7 +1277,7 @@ static int set_rts_threshold(struct usbn +diff --git a/drivers/net/wireless/rndis_wlan.c b/drivers/net/wireless/rn= dis_wlan.c +index 29f9389..f6d2ce0 100644 +--- a/drivers/net/wireless/rndis_wlan.c ++++ b/drivers/net/wireless/rndis_wlan.c +@@ -1277,7 +1277,7 @@ static int set_rts_threshold(struct usbnet *usbdev= , u32 rts_threshold) =20 netdev_dbg(usbdev->net, "%s(): %i\n", __func__, rts_threshold); =20 @@ -33823,10 +34742,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/rnd= is_wlan.c linux-3.1.4/drivers/net rts_threshold =3D 2347; =20 tmp =3D cpu_to_le32(rts_threshold); -diff -urNp linux-3.1.4/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.= c linux-3.1.4/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c ---- linux-3.1.4/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c 2011-= 11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c 2011-= 11-16 18:40:22.000000000 -0500 -@@ -837,6 +837,8 @@ bool _rtl92c_phy_sw_chnl_step_by_step(st +diff --git a/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c b/driver= s/net/wireless/rtlwifi/rtl8192c/phy_common.c +index 3b11642..d6bb049 100644 +--- a/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c ++++ b/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c +@@ -837,6 +837,8 @@ bool _rtl92c_phy_sw_chnl_step_by_step(struct ieee802= 11_hw *hw, u8 rfpath; u8 num_total_rfpath =3D rtlphy->num_total_rfpath; =20 @@ -33835,9 +34755,10 @@ diff -urNp linux-3.1.4/drivers/net/wireless/rtlw= ifi/rtl8192c/phy_common.c linux- precommoncmdcnt =3D 0; _rtl92c_phy_set_sw_chnl_cmdarray(precommoncmd, precommoncmdcnt++, MAX_PRECMD_CNT, -diff -urNp linux-3.1.4/drivers/net/wireless/wl1251/wl1251.h linux-3.1.4/= drivers/net/wireless/wl1251/wl1251.h ---- linux-3.1.4/drivers/net/wireless/wl1251/wl1251.h 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/wl1251/wl1251.h 2011-11-16 18:39:07= .000000000 -0500 +diff --git a/drivers/net/wireless/wl1251/wl1251.h b/drivers/net/wireless= /wl1251/wl1251.h +index a77f1bb..c608b2b 100644 +--- a/drivers/net/wireless/wl1251/wl1251.h ++++ b/drivers/net/wireless/wl1251/wl1251.h @@ -266,7 +266,7 @@ struct wl1251_if_operations { void (*reset)(struct wl1251 *wl); void (*enable_irq)(struct wl1251 *wl); @@ -33847,10 +34768,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/wl1= 251/wl1251.h linux-3.1.4/drivers/ =20 struct wl1251 { struct ieee80211_hw *hw; -diff -urNp linux-3.1.4/drivers/net/wireless/wl12xx/spi.c linux-3.1.4/dri= vers/net/wireless/wl12xx/spi.c ---- linux-3.1.4/drivers/net/wireless/wl12xx/spi.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/net/wireless/wl12xx/spi.c 2011-11-16 18:40:22.00= 0000000 -0500 -@@ -281,6 +281,8 @@ static void wl1271_spi_raw_write(struct=20 +diff --git a/drivers/net/wireless/wl12xx/spi.c b/drivers/net/wireless/wl= 12xx/spi.c +index e0b3736..4b466e6 100644 +--- a/drivers/net/wireless/wl12xx/spi.c ++++ b/drivers/net/wireless/wl12xx/spi.c +@@ -281,6 +281,8 @@ static void wl1271_spi_raw_write(struct wl1271 *wl, = int addr, void *buf, u32 chunk_len; int i; =20 @@ -33859,10 +34781,11 @@ diff -urNp linux-3.1.4/drivers/net/wireless/wl1= 2xx/spi.c linux-3.1.4/drivers/net WARN_ON(len > WL1271_AGGR_BUFFER_SIZE); =20 spi_message_init(&m); -diff -urNp linux-3.1.4/drivers/oprofile/buffer_sync.c linux-3.1.4/driver= s/oprofile/buffer_sync.c ---- linux-3.1.4/drivers/oprofile/buffer_sync.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/oprofile/buffer_sync.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -343,7 +343,7 @@ static void add_data(struct op_entry *en +diff --git a/drivers/oprofile/buffer_sync.c b/drivers/oprofile/buffer_sy= nc.c +index f34b5b2..b5abb9f 100644 +--- a/drivers/oprofile/buffer_sync.c ++++ b/drivers/oprofile/buffer_sync.c +@@ -343,7 +343,7 @@ static void add_data(struct op_entry *entry, struct = mm_struct *mm) if (cookie =3D=3D NO_COOKIE) offset =3D pc; if (cookie =3D=3D INVALID_COOKIE) { @@ -33871,7 +34794,7 @@ diff -urNp linux-3.1.4/drivers/oprofile/buffer_sy= nc.c linux-3.1.4/drivers/oprofi offset =3D pc; } if (cookie !=3D last_cookie) { -@@ -387,14 +387,14 @@ add_sample(struct mm_struct *mm, struct=20 +@@ -387,14 +387,14 @@ add_sample(struct mm_struct *mm, struct op_sample = *s, int in_kernel) /* add userspace sample */ =20 if (!mm) { @@ -33897,10 +34820,11 @@ diff -urNp linux-3.1.4/drivers/oprofile/buffer_= sync.c linux-3.1.4/drivers/oprofi } } release_mm(mm); -diff -urNp linux-3.1.4/drivers/oprofile/event_buffer.c linux-3.1.4/drive= rs/oprofile/event_buffer.c ---- linux-3.1.4/drivers/oprofile/event_buffer.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/oprofile/event_buffer.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -53,7 +53,7 @@ void add_event_entry(unsigned long value +diff --git a/drivers/oprofile/event_buffer.c b/drivers/oprofile/event_bu= ffer.c +index dd87e86..bc0148c 100644 +--- a/drivers/oprofile/event_buffer.c ++++ b/drivers/oprofile/event_buffer.c +@@ -53,7 +53,7 @@ void add_event_entry(unsigned long value) } =20 if (buffer_pos =3D=3D buffer_size) { @@ -33909,10 +34833,11 @@ diff -urNp linux-3.1.4/drivers/oprofile/event_b= uffer.c linux-3.1.4/drivers/oprof return; } =20 -diff -urNp linux-3.1.4/drivers/oprofile/oprof.c linux-3.1.4/drivers/opro= file/oprof.c ---- linux-3.1.4/drivers/oprofile/oprof.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/oprofile/oprof.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -110,7 +110,7 @@ static void switch_worker(struct work_st +diff --git a/drivers/oprofile/oprof.c b/drivers/oprofile/oprof.c +index dccd863..8d35669 100644 +--- a/drivers/oprofile/oprof.c ++++ b/drivers/oprofile/oprof.c +@@ -110,7 +110,7 @@ static void switch_worker(struct work_struct *work) if (oprofile_ops.switch_events()) return; =20 @@ -33921,21 +34846,10 @@ diff -urNp linux-3.1.4/drivers/oprofile/oprof.c= linux-3.1.4/drivers/oprofile/opr start_switch_worker(); } =20 -diff -urNp linux-3.1.4/drivers/oprofile/oprofilefs.c linux-3.1.4/drivers= /oprofile/oprofilefs.c ---- linux-3.1.4/drivers/oprofile/oprofilefs.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/oprofile/oprofilefs.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -186,7 +186,7 @@ static const struct file_operations atom -=20 -=20 - int oprofilefs_create_ro_atomic(struct super_block *sb, struct dentry *= root, -- char const *name, atomic_t *val) -+ char const *name, atomic_unchecked_t *val) - { - return __oprofilefs_create_file(sb, root, name, - &atomic_ro_fops, 0444, val); -diff -urNp linux-3.1.4/drivers/oprofile/oprofile_stats.c linux-3.1.4/dri= vers/oprofile/oprofile_stats.c ---- linux-3.1.4/drivers/oprofile/oprofile_stats.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/oprofile/oprofile_stats.c 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/drivers/oprofile/oprofile_stats.c b/drivers/oprofile/oprofi= le_stats.c +index 917d28e..d62d981 100644 +--- a/drivers/oprofile/oprofile_stats.c ++++ b/drivers/oprofile/oprofile_stats.c @@ -30,11 +30,11 @@ void oprofile_reset_stats(void) cpu_buf->sample_invalid_eip =3D 0; } @@ -33953,9 +34867,10 @@ diff -urNp linux-3.1.4/drivers/oprofile/oprofile= _stats.c linux-3.1.4/drivers/opr } =20 =20 -diff -urNp linux-3.1.4/drivers/oprofile/oprofile_stats.h linux-3.1.4/dri= vers/oprofile/oprofile_stats.h ---- linux-3.1.4/drivers/oprofile/oprofile_stats.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/oprofile/oprofile_stats.h 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/drivers/oprofile/oprofile_stats.h b/drivers/oprofile/oprofi= le_stats.h +index 38b6fc0..b5cbfce 100644 +--- a/drivers/oprofile/oprofile_stats.h ++++ b/drivers/oprofile/oprofile_stats.h @@ -13,11 +13,11 @@ #include =20 @@ -33973,10 +34888,24 @@ diff -urNp linux-3.1.4/drivers/oprofile/oprofil= e_stats.h linux-3.1.4/drivers/opr }; =20 extern struct oprofile_stat_struct oprofile_stats; -diff -urNp linux-3.1.4/drivers/parport/procfs.c linux-3.1.4/drivers/parp= ort/procfs.c ---- linux-3.1.4/drivers/parport/procfs.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/parport/procfs.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -64,7 +64,7 @@ static int do_active_device(ctl_table *t +diff --git a/drivers/oprofile/oprofilefs.c b/drivers/oprofile/oprofilefs= .c +index e9ff6f7..28e259a 100644 +--- a/drivers/oprofile/oprofilefs.c ++++ b/drivers/oprofile/oprofilefs.c +@@ -186,7 +186,7 @@ static const struct file_operations atomic_ro_fops =3D= { +=20 +=20 + int oprofilefs_create_ro_atomic(struct super_block *sb, struct dentry *= root, +- char const *name, atomic_t *val) ++ char const *name, atomic_unchecked_t *val) + { + return __oprofilefs_create_file(sb, root, name, + &atomic_ro_fops, 0444, val); +diff --git a/drivers/parport/procfs.c b/drivers/parport/procfs.c +index 3f56bc0..707d642 100644 +--- a/drivers/parport/procfs.c ++++ b/drivers/parport/procfs.c +@@ -64,7 +64,7 @@ static int do_active_device(ctl_table *table, int writ= e, =20 *ppos +=3D len; =20 @@ -33985,7 +34914,7 @@ diff -urNp linux-3.1.4/drivers/parport/procfs.c l= inux-3.1.4/drivers/parport/proc } =20 #ifdef CONFIG_PARPORT_1284 -@@ -106,7 +106,7 @@ static int do_autoprobe(ctl_table *table +@@ -106,7 +106,7 @@ static int do_autoprobe(ctl_table *table, int write, =20 *ppos +=3D len; =20 @@ -33994,9 +34923,10 @@ diff -urNp linux-3.1.4/drivers/parport/procfs.c = linux-3.1.4/drivers/parport/proc } #endif /* IEEE1284.3 support. */ =20 -diff -urNp linux-3.1.4/drivers/pci/hotplug/cpci_hotplug.h linux-3.1.4/dr= ivers/pci/hotplug/cpci_hotplug.h ---- linux-3.1.4/drivers/pci/hotplug/cpci_hotplug.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/pci/hotplug/cpci_hotplug.h 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/drivers/pci/hotplug/cpci_hotplug.h b/drivers/pci/hotplug/cp= ci_hotplug.h +index 9fff878..ad0ad53 100644 +--- a/drivers/pci/hotplug/cpci_hotplug.h ++++ b/drivers/pci/hotplug/cpci_hotplug.h @@ -59,7 +59,7 @@ struct cpci_hp_controller_ops { int (*hardware_test) (struct slot* slot, u32 value); u8 (*get_power) (struct slot* slot); @@ -34006,10 +34936,11 @@ diff -urNp linux-3.1.4/drivers/pci/hotplug/cpci= _hotplug.h linux-3.1.4/drivers/pc =20 struct cpci_hp_controller { unsigned int irq; -diff -urNp linux-3.1.4/drivers/pci/hotplug/cpqphp_nvram.c linux-3.1.4/dr= ivers/pci/hotplug/cpqphp_nvram.c ---- linux-3.1.4/drivers/pci/hotplug/cpqphp_nvram.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/pci/hotplug/cpqphp_nvram.c 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -428,9 +428,13 @@ static u32 store_HRT (void __iomem *rom_ +diff --git a/drivers/pci/hotplug/cpqphp_nvram.c b/drivers/pci/hotplug/cp= qphp_nvram.c +index 76ba8a1..20ca857 100644 +--- a/drivers/pci/hotplug/cpqphp_nvram.c ++++ b/drivers/pci/hotplug/cpqphp_nvram.c +@@ -428,9 +428,13 @@ static u32 store_HRT (void __iomem *rom_start) =20 void compaq_nvram_init (void __iomem *rom_start) { @@ -34023,9 +34954,10 @@ diff -urNp linux-3.1.4/drivers/pci/hotplug/cpqph= p_nvram.c linux-3.1.4/drivers/pc dbg("int15 entry =3D %p\n", compaq_int15_entry_point); =20 /* initialize our int15 lock */ -diff -urNp linux-3.1.4/drivers/pci/pcie/aspm.c linux-3.1.4/drivers/pci/p= cie/aspm.c ---- linux-3.1.4/drivers/pci/pcie/aspm.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/pci/pcie/aspm.c 2011-11-16 18:39:07.000000000 -0= 500 +diff --git a/drivers/pci/pcie/aspm.c b/drivers/pci/pcie/aspm.c +index cbfbab1..6a9fced 100644 +--- a/drivers/pci/pcie/aspm.c ++++ b/drivers/pci/pcie/aspm.c @@ -27,9 +27,9 @@ #define MODULE_PARAM_PREFIX "pcie_aspm." =20 @@ -34039,10 +34971,11 @@ diff -urNp linux-3.1.4/drivers/pci/pcie/aspm.c = linux-3.1.4/drivers/pci/pcie/aspm #define ASPM_STATE_L0S (ASPM_STATE_L0S_UP | ASPM_STATE_L0S_DW) #define ASPM_STATE_ALL (ASPM_STATE_L0S | ASPM_STATE_L1) =20 -diff -urNp linux-3.1.4/drivers/pci/probe.c linux-3.1.4/drivers/pci/probe= .c ---- linux-3.1.4/drivers/pci/probe.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/pci/probe.c 2011-11-16 18:39:07.000000000 -0500 -@@ -136,7 +136,7 @@ int __pci_read_base(struct pci_dev *dev, +diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c +index 6ab6bd3..72bdc69 100644 +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -136,7 +136,7 @@ int __pci_read_base(struct pci_dev *dev, enum pci_ba= r_type type, u32 l, sz, mask; u16 orig_cmd; =20 @@ -34051,10 +34984,11 @@ diff -urNp linux-3.1.4/drivers/pci/probe.c linu= x-3.1.4/drivers/pci/probe.c =20 if (!dev->mmio_always_on) { pci_read_config_word(dev, PCI_COMMAND, &orig_cmd); -diff -urNp linux-3.1.4/drivers/pci/proc.c linux-3.1.4/drivers/pci/proc.c ---- linux-3.1.4/drivers/pci/proc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/pci/proc.c 2011-11-16 18:40:22.000000000 -0500 -@@ -476,7 +476,16 @@ static const struct file_operations proc +diff --git a/drivers/pci/proc.c b/drivers/pci/proc.c +index 27911b5..5b6db88 100644 +--- a/drivers/pci/proc.c ++++ b/drivers/pci/proc.c +@@ -476,7 +476,16 @@ static const struct file_operations proc_bus_pci_de= v_operations =3D { static int __init pci_proc_init(void) { struct pci_dev *dev =3D NULL; @@ -34071,10 +35005,11 @@ diff -urNp linux-3.1.4/drivers/pci/proc.c linux= -3.1.4/drivers/pci/proc.c proc_create("devices", 0, proc_bus_pci_dir, &proc_bus_pci_dev_operations); proc_initialized =3D 1; -diff -urNp linux-3.1.4/drivers/pci/xen-pcifront.c linux-3.1.4/drivers/pc= i/xen-pcifront.c ---- linux-3.1.4/drivers/pci/xen-pcifront.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/pci/xen-pcifront.c 2011-11-16 18:40:22.000000000= -0500 -@@ -187,6 +187,8 @@ static int pcifront_bus_read(struct pci_ +diff --git a/drivers/pci/xen-pcifront.c b/drivers/pci/xen-pcifront.c +index 90832a9..419089a 100644 +--- a/drivers/pci/xen-pcifront.c ++++ b/drivers/pci/xen-pcifront.c +@@ -187,6 +187,8 @@ static int pcifront_bus_read(struct pci_bus *bus, un= signed int devfn, struct pcifront_sd *sd =3D bus->sysdata; struct pcifront_device *pdev =3D pcifront_get_pdev(sd); =20 @@ -34083,7 +35018,7 @@ diff -urNp linux-3.1.4/drivers/pci/xen-pcifront.c= linux-3.1.4/drivers/pci/xen-pc if (verbose_request) dev_info(&pdev->xdev->dev, "read dev=3D%04x:%02x:%02x.%01x - offset %x size %d\n", -@@ -226,6 +228,8 @@ static int pcifront_bus_write(struct pci +@@ -226,6 +228,8 @@ static int pcifront_bus_write(struct pci_bus *bus, u= nsigned int devfn, struct pcifront_sd *sd =3D bus->sysdata; struct pcifront_device *pdev =3D pcifront_get_pdev(sd); =20 @@ -34092,7 +35027,7 @@ diff -urNp linux-3.1.4/drivers/pci/xen-pcifront.c= linux-3.1.4/drivers/pci/xen-pc if (verbose_request) dev_info(&pdev->xdev->dev, "write dev=3D%04x:%02x:%02x.%01x - " -@@ -258,6 +262,8 @@ static int pci_frontend_enable_msix(stru +@@ -258,6 +262,8 @@ static int pci_frontend_enable_msix(struct pci_dev *= dev, struct pcifront_device *pdev =3D pcifront_get_pdev(sd); struct msi_desc *entry; =20 @@ -34101,7 +35036,7 @@ diff -urNp linux-3.1.4/drivers/pci/xen-pcifront.c= linux-3.1.4/drivers/pci/xen-pc if (nvec > SH_INFO_MAX_VEC) { dev_err(&dev->dev, "too much vector for pci frontend: %x." " Increase SH_INFO_MAX_VEC.\n", nvec); -@@ -309,6 +315,8 @@ static void pci_frontend_disable_msix(st +@@ -309,6 +315,8 @@ static void pci_frontend_disable_msix(struct pci_dev= *dev) struct pcifront_sd *sd =3D dev->bus->sysdata; struct pcifront_device *pdev =3D pcifront_get_pdev(sd); =20 @@ -34110,7 +35045,7 @@ diff -urNp linux-3.1.4/drivers/pci/xen-pcifront.c= linux-3.1.4/drivers/pci/xen-pc err =3D do_pci_op(pdev, &op); =20 /* What should do for error ? */ -@@ -328,6 +336,8 @@ static int pci_frontend_enable_msi(struc +@@ -328,6 +336,8 @@ static int pci_frontend_enable_msi(struct pci_dev *d= ev, int vector[]) struct pcifront_sd *sd =3D dev->bus->sysdata; struct pcifront_device *pdev =3D pcifront_get_pdev(sd); =20 @@ -34119,9 +35054,10 @@ diff -urNp linux-3.1.4/drivers/pci/xen-pcifront.= c linux-3.1.4/drivers/pci/xen-pc err =3D do_pci_op(pdev, &op); if (likely(!err)) { vector[0] =3D op.value; -diff -urNp linux-3.1.4/drivers/platform/x86/thinkpad_acpi.c linux-3.1.4/= drivers/platform/x86/thinkpad_acpi.c ---- linux-3.1.4/drivers/platform/x86/thinkpad_acpi.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/platform/x86/thinkpad_acpi.c 2011-12-02 17:38:47= .000000000 -0500 +diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86= /thinkpad_acpi.c +index 7bd829f..a3237ad 100644 +--- a/drivers/platform/x86/thinkpad_acpi.c ++++ b/drivers/platform/x86/thinkpad_acpi.c @@ -2094,7 +2094,7 @@ static int hotkey_mask_get(void) return 0; } @@ -34131,7 +35067,7 @@ diff -urNp linux-3.1.4/drivers/platform/x86/think= pad_acpi.c linux-3.1.4/drivers/ { /* log only what the user can fix... */ const u32 wantedmask =3D hotkey_driver_mask & -@@ -2325,11 +2325,6 @@ static void hotkey_read_nvram(struct tp_ +@@ -2325,11 +2325,6 @@ static void hotkey_read_nvram(struct tp_nvram_sta= te *n, const u32 m) } } =20 @@ -34143,7 +35079,7 @@ diff -urNp linux-3.1.4/drivers/platform/x86/think= pad_acpi.c linux-3.1.4/drivers/ #define TPACPI_COMPARE_KEY(__scancode, __member) \ do { \ if ((event_mask & (1 << __scancode)) && \ -@@ -2343,36 +2338,42 @@ static void hotkey_compare_and_issue_eve +@@ -2343,36 +2338,42 @@ static void hotkey_compare_and_issue_event(struc= t tp_nvram_state *oldn, tpacpi_hotkey_send_key(__scancode); \ } while (0) =20 @@ -34210,7 +35146,7 @@ diff -urNp linux-3.1.4/drivers/platform/x86/think= pad_acpi.c linux-3.1.4/drivers/ TPACPI_COMPARE_KEY(TP_ACPI_HOTKEYSCAN_THINKPAD, thinkpad_toggle); TPACPI_COMPARE_KEY(TP_ACPI_HOTKEYSCAN_FNSPACE, zoom_toggle); TPACPI_COMPARE_KEY(TP_ACPI_HOTKEYSCAN_FNF7, display_toggle); -@@ -2406,7 +2407,7 @@ static void hotkey_compare_and_issue_eve +@@ -2406,7 +2407,7 @@ static void hotkey_compare_and_issue_event(struct = tp_nvram_state *oldn, oldn->volume_level !=3D newn->volume_level) { /* recently muted, or repeated mute keypress, or * multiple presses ending in mute */ @@ -34219,7 +35155,7 @@ diff -urNp linux-3.1.4/drivers/platform/x86/think= pad_acpi.c linux-3.1.4/drivers/ TPACPI_MAY_SEND_KEY(TP_ACPI_HOTKEYSCAN_MUTE); } } else { -@@ -2416,7 +2417,7 @@ static void hotkey_compare_and_issue_eve +@@ -2416,7 +2417,7 @@ static void hotkey_compare_and_issue_event(struct = tp_nvram_state *oldn, TPACPI_MAY_SEND_KEY(TP_ACPI_HOTKEYSCAN_VOLUMEUP); } if (oldn->volume_level !=3D newn->volume_level) { @@ -34228,7 +35164,7 @@ diff -urNp linux-3.1.4/drivers/platform/x86/think= pad_acpi.c linux-3.1.4/drivers/ } else if (oldn->volume_toggle !=3D newn->volume_toggle) { /* repeated vol up/down keypress at end of scale ? */ if (newn->volume_level =3D=3D 0) -@@ -2429,7 +2430,8 @@ static void hotkey_compare_and_issue_eve +@@ -2429,7 +2430,8 @@ static void hotkey_compare_and_issue_event(struct = tp_nvram_state *oldn, /* handle brightness */ if (oldn->brightness_level !=3D newn->brightness_level) { issue_brightnesschange(oldn->brightness_level, @@ -34238,7 +35174,7 @@ diff -urNp linux-3.1.4/drivers/platform/x86/think= pad_acpi.c linux-3.1.4/drivers/ } else if (oldn->brightness_toggle !=3D newn->brightness_toggle) { /* repeated key presses that didn't change state */ if (newn->brightness_level =3D=3D 0) -@@ -2438,10 +2440,10 @@ static void hotkey_compare_and_issue_eve +@@ -2438,10 +2440,10 @@ static void hotkey_compare_and_issue_event(struc= t tp_nvram_state *oldn, && !tp_features.bright_unkfw) TPACPI_MAY_SEND_KEY(TP_ACPI_HOTKEYSCAN_FNHOME); } @@ -34250,9 +35186,10 @@ diff -urNp linux-3.1.4/drivers/platform/x86/thin= kpad_acpi.c linux-3.1.4/drivers/ =20 /* * Polling driver -diff -urNp linux-3.1.4/drivers/pnp/pnpbios/bioscalls.c linux-3.1.4/drive= rs/pnp/pnpbios/bioscalls.c ---- linux-3.1.4/drivers/pnp/pnpbios/bioscalls.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/pnp/pnpbios/bioscalls.c 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/pnp/pnpbios/bioscalls.c b/drivers/pnp/pnpbios/biosc= alls.c +index b859d16..5cc6b1a 100644 +--- a/drivers/pnp/pnpbios/bioscalls.c ++++ b/drivers/pnp/pnpbios/bioscalls.c @@ -59,7 +59,7 @@ do { \ set_desc_limit(&gdt[(selname) >> 3], (size) - 1); \ } while(0) @@ -34262,7 +35199,7 @@ diff -urNp linux-3.1.4/drivers/pnp/pnpbios/biosca= lls.c linux-3.1.4/drivers/pnp/p (unsigned long)__va(0x400UL), PAGE_SIZE - 0x400 - 1); =20 /* -@@ -96,7 +96,10 @@ static inline u16 call_pnp_bios(u16 func +@@ -96,7 +96,10 @@ static inline u16 call_pnp_bios(u16 func, u16 arg1, u= 16 arg2, u16 arg3, =20 cpu =3D get_cpu(); save_desc_40 =3D get_cpu_gdt_table(cpu)[0x40 / 8]; @@ -34273,7 +35210,7 @@ diff -urNp linux-3.1.4/drivers/pnp/pnpbios/biosca= lls.c linux-3.1.4/drivers/pnp/p =20 /* On some boxes IRQ's during PnP BIOS calls are deadly. */ spin_lock_irqsave(&pnp_bios_lock, flags); -@@ -134,7 +137,10 @@ static inline u16 call_pnp_bios(u16 func +@@ -134,7 +137,10 @@ static inline u16 call_pnp_bios(u16 func, u16 arg1,= u16 arg2, u16 arg3, :"memory"); spin_unlock_irqrestore(&pnp_bios_lock, flags); =20 @@ -34284,7 +35221,7 @@ diff -urNp linux-3.1.4/drivers/pnp/pnpbios/biosca= lls.c linux-3.1.4/drivers/pnp/p put_cpu(); =20 /* If we get here and this is set then the PnP BIOS faulted on us. */ -@@ -468,7 +474,7 @@ int pnp_bios_read_escd(char *data, u32 n +@@ -468,7 +474,7 @@ int pnp_bios_read_escd(char *data, u32 nvram_base) return status; } =20 @@ -34293,7 +35230,7 @@ diff -urNp linux-3.1.4/drivers/pnp/pnpbios/biosca= lls.c linux-3.1.4/drivers/pnp/p { int i; =20 -@@ -476,6 +482,8 @@ void pnpbios_calls_init(union pnp_bios_i +@@ -476,6 +482,8 @@ void pnpbios_calls_init(union pnp_bios_install_struc= t *header) pnp_bios_callpoint.offset =3D header->fields.pm16offset; pnp_bios_callpoint.segment =3D PNP_CS16; =20 @@ -34302,17 +35239,18 @@ diff -urNp linux-3.1.4/drivers/pnp/pnpbios/bios= calls.c linux-3.1.4/drivers/pnp/p for_each_possible_cpu(i) { struct desc_struct *gdt =3D get_cpu_gdt_table(i); if (!gdt) -@@ -487,4 +495,6 @@ void pnpbios_calls_init(union pnp_bios_i +@@ -487,4 +495,6 @@ void pnpbios_calls_init(union pnp_bios_install_struc= t *header) set_desc_base(&gdt[GDT_ENTRY_PNPBIOS_DS], (unsigned long)__va(header->fields.pm16dseg)); } + + pax_close_kernel(); } -diff -urNp linux-3.1.4/drivers/pnp/resource.c linux-3.1.4/drivers/pnp/re= source.c ---- linux-3.1.4/drivers/pnp/resource.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/pnp/resource.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -360,7 +360,7 @@ int pnp_check_irq(struct pnp_dev *dev, s +diff --git a/drivers/pnp/resource.c b/drivers/pnp/resource.c +index b0ecacb..7c9da2e 100644 +--- a/drivers/pnp/resource.c ++++ b/drivers/pnp/resource.c +@@ -360,7 +360,7 @@ int pnp_check_irq(struct pnp_dev *dev, struct resour= ce *res) return 1; =20 /* check if the resource is valid */ @@ -34321,7 +35259,7 @@ diff -urNp linux-3.1.4/drivers/pnp/resource.c lin= ux-3.1.4/drivers/pnp/resource.c return 0; =20 /* check if the resource is reserved */ -@@ -424,7 +424,7 @@ int pnp_check_dma(struct pnp_dev *dev, s +@@ -424,7 +424,7 @@ int pnp_check_dma(struct pnp_dev *dev, struct resour= ce *res) return 1; =20 /* check if the resource is valid */ @@ -34330,9 +35268,10 @@ diff -urNp linux-3.1.4/drivers/pnp/resource.c li= nux-3.1.4/drivers/pnp/resource.c return 0; =20 /* check if the resource is reserved */ -diff -urNp linux-3.1.4/drivers/power/bq27x00_battery.c linux-3.1.4/drive= rs/power/bq27x00_battery.c ---- linux-3.1.4/drivers/power/bq27x00_battery.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/power/bq27x00_battery.c 2011-11-16 18:39:07.0000= 00000 -0500 +diff --git a/drivers/power/bq27x00_battery.c b/drivers/power/bq27x00_bat= tery.c +index bb16f5b..c751eef 100644 +--- a/drivers/power/bq27x00_battery.c ++++ b/drivers/power/bq27x00_battery.c @@ -67,7 +67,7 @@ struct bq27x00_device_info; struct bq27x00_access_methods { @@ -34342,10 +35281,11 @@ diff -urNp linux-3.1.4/drivers/power/bq27x00_ba= ttery.c linux-3.1.4/drivers/power =20 enum bq27x00_chip { BQ27000, BQ27500 }; =20 -diff -urNp linux-3.1.4/drivers/regulator/max8660.c linux-3.1.4/drivers/r= egulator/max8660.c ---- linux-3.1.4/drivers/regulator/max8660.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/regulator/max8660.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -383,8 +383,10 @@ static int __devinit max8660_probe(struc +diff --git a/drivers/regulator/max8660.c b/drivers/regulator/max8660.c +index 33f5d9a..d957d3f 100644 +--- a/drivers/regulator/max8660.c ++++ b/drivers/regulator/max8660.c +@@ -383,8 +383,10 @@ static int __devinit max8660_probe(struct i2c_clien= t *client, max8660->shadow_regs[MAX8660_OVER1] =3D 5; } else { /* Otherwise devices can be toggled via software */ @@ -34358,10 +35298,11 @@ diff -urNp linux-3.1.4/drivers/regulator/max866= 0.c linux-3.1.4/drivers/regulator } =20 /* -diff -urNp linux-3.1.4/drivers/regulator/mc13892-regulator.c linux-3.1.4= /drivers/regulator/mc13892-regulator.c ---- linux-3.1.4/drivers/regulator/mc13892-regulator.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/regulator/mc13892-regulator.c 2011-11-16 18:39:0= 7.000000000 -0500 -@@ -564,10 +564,12 @@ static int __devinit mc13892_regulator_p +diff --git a/drivers/regulator/mc13892-regulator.c b/drivers/regulator/m= c13892-regulator.c +index 3285d41..ab7c22a 100644 +--- a/drivers/regulator/mc13892-regulator.c ++++ b/drivers/regulator/mc13892-regulator.c +@@ -564,10 +564,12 @@ static int __devinit mc13892_regulator_probe(struc= t platform_device *pdev) } mc13xxx_unlock(mc13892); =20 @@ -34376,9 +35317,10 @@ diff -urNp linux-3.1.4/drivers/regulator/mc13892= -regulator.c linux-3.1.4/drivers for (i =3D 0; i < pdata->num_regulators; i++) { init_data =3D &pdata->regulators[i]; priv->regulators[i] =3D regulator_register( -diff -urNp linux-3.1.4/drivers/rtc/rtc-dev.c linux-3.1.4/drivers/rtc/rtc= -dev.c ---- linux-3.1.4/drivers/rtc/rtc-dev.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/rtc/rtc-dev.c 2011-11-16 18:40:22.000000000 -050= 0 +diff --git a/drivers/rtc/rtc-dev.c b/drivers/rtc/rtc-dev.c +index cace6d3..f623fda 100644 +--- a/drivers/rtc/rtc-dev.c ++++ b/drivers/rtc/rtc-dev.c @@ -14,6 +14,7 @@ #include #include @@ -34387,7 +35329,7 @@ diff -urNp linux-3.1.4/drivers/rtc/rtc-dev.c linu= x-3.1.4/drivers/rtc/rtc-dev.c #include "rtc-core.h" =20 static dev_t rtc_devt; -@@ -345,6 +346,8 @@ static long rtc_dev_ioctl(struct file *f +@@ -345,6 +346,8 @@ static long rtc_dev_ioctl(struct file *file, if (copy_from_user(&tm, uarg, sizeof(tm))) return -EFAULT; =20 @@ -34396,9 +35338,23 @@ diff -urNp linux-3.1.4/drivers/rtc/rtc-dev.c lin= ux-3.1.4/drivers/rtc/rtc-dev.c return rtc_set_time(rtc, &tm); =20 case RTC_PIE_ON: -diff -urNp linux-3.1.4/drivers/scsi/aacraid/aacraid.h linux-3.1.4/driver= s/scsi/aacraid/aacraid.h ---- linux-3.1.4/drivers/scsi/aacraid/aacraid.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/scsi/aacraid/aacraid.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c +index f66c33b..7ae5823 100644 +--- a/drivers/scsi/BusLogic.c ++++ b/drivers/scsi/BusLogic.c +@@ -962,6 +962,8 @@ static int __init BusLogic_InitializeFlashPointProbe= Info(struct BusLogic_HostAda + static void __init BusLogic_InitializeProbeInfoList(struct BusLogic_Hos= tAdapter + *PrototypeHostAdapter) + { ++ pax_track_stack(); ++ + /* + If a PCI BIOS is present, interrogate it for MultiMaster and FlashP= oint + Host Adapters; otherwise, default to the standard ISA MultiMaster p= robe. +diff --git a/drivers/scsi/aacraid/aacraid.h b/drivers/scsi/aacraid/aacra= id.h +index ffb5878..e6d785c 100644 +--- a/drivers/scsi/aacraid/aacraid.h ++++ b/drivers/scsi/aacraid/aacraid.h @@ -492,7 +492,7 @@ struct adapter_ops int (*adapter_scsi)(struct fib * fib, struct scsi_cmnd * cmd); /* Administrative operations */ @@ -34408,10 +35364,11 @@ diff -urNp linux-3.1.4/drivers/scsi/aacraid/aac= raid.h linux-3.1.4/drivers/scsi/a =20 /* * Define which interrupt handler needs to be installed -diff -urNp linux-3.1.4/drivers/scsi/aacraid/commctrl.c linux-3.1.4/drive= rs/scsi/aacraid/commctrl.c ---- linux-3.1.4/drivers/scsi/aacraid/commctrl.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/scsi/aacraid/commctrl.c 2011-11-16 18:40:22.0000= 00000 -0500 -@@ -482,6 +482,7 @@ static int aac_send_raw_srb(struct aac_d +diff --git a/drivers/scsi/aacraid/commctrl.c b/drivers/scsi/aacraid/comm= ctrl.c +index 8a0b330..b4286de 100644 +--- a/drivers/scsi/aacraid/commctrl.c ++++ b/drivers/scsi/aacraid/commctrl.c +@@ -482,6 +482,7 @@ static int aac_send_raw_srb(struct aac_dev* dev, voi= d __user * arg) u32 actual_fibsize64, actual_fibsize =3D 0; int i; =20 @@ -34419,10 +35376,11 @@ diff -urNp linux-3.1.4/drivers/scsi/aacraid/com= mctrl.c linux-3.1.4/drivers/scsi/ =20 if (dev->in_reset) { dprintk((KERN_DEBUG"aacraid: send raw srb -EBUSY\n")); -diff -urNp linux-3.1.4/drivers/scsi/aacraid/linit.c linux-3.1.4/drivers/= scsi/aacraid/linit.c ---- linux-3.1.4/drivers/scsi/aacraid/linit.c 2011-11-26 19:57:29.0000000= 00 -0500 -+++ linux-3.1.4/drivers/scsi/aacraid/linit.c 2011-11-26 20:00:43.0000000= 00 -0500 -@@ -93,7 +93,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_ +diff --git a/drivers/scsi/aacraid/linit.c b/drivers/scsi/aacraid/linit.c +index c7b6fed..4db0569 100644 +--- a/drivers/scsi/aacraid/linit.c ++++ b/drivers/scsi/aacraid/linit.c +@@ -93,7 +93,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_tbl) =3D { #elif defined(__devinitconst) static const struct pci_device_id aac_pci_tbl[] __devinitconst =3D { #else @@ -34431,10 +35389,11 @@ diff -urNp linux-3.1.4/drivers/scsi/aacraid/lin= it.c linux-3.1.4/drivers/scsi/aac #endif { 0x1028, 0x0001, 0x1028, 0x0001, 0, 0, 0 }, /* PERC 2/Si (Iguana/PERC= 2Si) */ { 0x1028, 0x0002, 0x1028, 0x0002, 0, 0, 1 }, /* PERC 3/Di (Opal/PERC3D= i) */ -diff -urNp linux-3.1.4/drivers/scsi/aic94xx/aic94xx_init.c linux-3.1.4/d= rivers/scsi/aic94xx/aic94xx_init.c ---- linux-3.1.4/drivers/scsi/aic94xx/aic94xx_init.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/scsi/aic94xx/aic94xx_init.c 2011-11-16 18:39:07.= 000000000 -0500 -@@ -1012,7 +1012,7 @@ static struct sas_domain_function_templa +diff --git a/drivers/scsi/aic94xx/aic94xx_init.c b/drivers/scsi/aic94xx/= aic94xx_init.c +index d5ff142..49c0ebb 100644 +--- a/drivers/scsi/aic94xx/aic94xx_init.c ++++ b/drivers/scsi/aic94xx/aic94xx_init.c +@@ -1012,7 +1012,7 @@ static struct sas_domain_function_template aic94xx= _transport_functions =3D { .lldd_control_phy =3D asd_control_phy, }; =20 @@ -34443,22 +35402,24 @@ diff -urNp linux-3.1.4/drivers/scsi/aic94xx/aic= 94xx_init.c linux-3.1.4/drivers/s {PCI_DEVICE(PCI_VENDOR_ID_ADAPTEC2, 0x410),0, 0, 1}, {PCI_DEVICE(PCI_VENDOR_ID_ADAPTEC2, 0x412),0, 0, 1}, {PCI_DEVICE(PCI_VENDOR_ID_ADAPTEC2, 0x416),0, 0, 1}, -diff -urNp linux-3.1.4/drivers/scsi/bfa/bfad.c linux-3.1.4/drivers/scsi/= bfa/bfad.c ---- linux-3.1.4/drivers/scsi/bfa/bfad.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/scsi/bfa/bfad.c 2011-11-16 19:01:15.000000000 -0= 500 -@@ -1019,6 +1019,8 @@ bfad_start_ops(struct bfad_s *bfad) { - struct bfad_vport_s *vport, *vport_new; - struct bfa_fcs_driver_info_s driver_info; +diff --git a/drivers/scsi/bfa/bfa.h b/drivers/scsi/bfa/bfa.h +index a796de9..1ef20e1 100644 +--- a/drivers/scsi/bfa/bfa.h ++++ b/drivers/scsi/bfa/bfa.h +@@ -196,7 +196,7 @@ struct bfa_hwif_s { + u32 *end); + int cpe_vec_q0; + int rme_vec_q0; +-}; ++} __no_const; + typedef void (*bfa_cb_iocfc_t) (void *cbarg, enum bfa_status status); =20 -+ pax_track_stack(); -+ - /* Limit min/max. xfer size to [64k-32MB] */ - if (max_xfer_size < BFAD_MIN_SECTORS >> 1) - max_xfer_size =3D BFAD_MIN_SECTORS >> 1; -diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcpim.c linux-3.1.4/drivers/= scsi/bfa/bfa_fcpim.c ---- linux-3.1.4/drivers/scsi/bfa/bfa_fcpim.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/scsi/bfa/bfa_fcpim.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -4179,7 +4179,7 @@ bfa_itn_create(struct bfa_s *bfa, struct + struct bfa_faa_cbfn_s { +diff --git a/drivers/scsi/bfa/bfa_fcpim.c b/drivers/scsi/bfa/bfa_fcpim.c +index e07bd47..dbd260a 100644 +--- a/drivers/scsi/bfa/bfa_fcpim.c ++++ b/drivers/scsi/bfa/bfa_fcpim.c +@@ -4179,7 +4179,7 @@ bfa_itn_create(struct bfa_s *bfa, struct bfa_rport= _s *rport, void (*isr)(struct bfa_s *bfa, struct bfi_msg_s *m)) { struct bfa_fcp_mod_s *fcp =3D BFA_FCP_MOD(bfa); @@ -34467,9 +35428,10 @@ diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcpi= m.c linux-3.1.4/drivers/scsi/bfa =20 itn =3D BFA_ITN_FROM_TAG(fcp, rport->rport_tag); itn->isr =3D isr; -diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcpim.h linux-3.1.4/drivers/= scsi/bfa/bfa_fcpim.h ---- linux-3.1.4/drivers/scsi/bfa/bfa_fcpim.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/scsi/bfa/bfa_fcpim.h 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/drivers/scsi/bfa/bfa_fcpim.h b/drivers/scsi/bfa/bfa_fcpim.h +index 1080bcb..a3b39e3 100644 +--- a/drivers/scsi/bfa/bfa_fcpim.h ++++ b/drivers/scsi/bfa/bfa_fcpim.h @@ -37,6 +37,7 @@ struct bfa_iotag_s { struct bfa_itn_s { bfa_isr_func_t isr; @@ -34487,10 +35449,11 @@ diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcp= im.h linux-3.1.4/drivers/scsi/bfa int num_ioim_reqs; int num_fwtio_reqs; int num_itns; -diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcs_lport.c linux-3.1.4/driv= ers/scsi/bfa/bfa_fcs_lport.c ---- linux-3.1.4/drivers/scsi/bfa/bfa_fcs_lport.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/scsi/bfa/bfa_fcs_lport.c 2011-11-16 18:40:22.000= 000000 -0500 -@@ -1700,6 +1700,8 @@ bfa_fcs_lport_fdmi_build_rhba_pyld(struc +diff --git a/drivers/scsi/bfa/bfa_fcs_lport.c b/drivers/scsi/bfa/bfa_fcs= _lport.c +index d4f951f..197c350 100644 +--- a/drivers/scsi/bfa/bfa_fcs_lport.c ++++ b/drivers/scsi/bfa/bfa_fcs_lport.c +@@ -1700,6 +1700,8 @@ bfa_fcs_lport_fdmi_build_rhba_pyld(struct bfa_fcs_= lport_fdmi_s *fdmi, u8 *pyld) u16 len, count; u16 templen; =20 @@ -34499,7 +35462,7 @@ diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcs_l= port.c linux-3.1.4/drivers/scsi /* * get hba attributes */ -@@ -1977,6 +1979,8 @@ bfa_fcs_lport_fdmi_build_portattr_block( +@@ -1977,6 +1979,8 @@ bfa_fcs_lport_fdmi_build_portattr_block(struct bfa= _fcs_lport_fdmi_s *fdmi, u8 count =3D 0; u16 templen; =20 @@ -34508,10 +35471,11 @@ diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcs= _lport.c linux-3.1.4/drivers/scsi /* * get port attributes */ -diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcs_rport.c linux-3.1.4/driv= ers/scsi/bfa/bfa_fcs_rport.c ---- linux-3.1.4/drivers/scsi/bfa/bfa_fcs_rport.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/scsi/bfa/bfa_fcs_rport.c 2011-11-16 18:40:22.000= 000000 -0500 -@@ -1871,6 +1871,8 @@ bfa_fcs_rport_process_rpsc(struct bfa_fc +diff --git a/drivers/scsi/bfa/bfa_fcs_rport.c b/drivers/scsi/bfa/bfa_fcs= _rport.c +index 52628d5..f89d033 100644 +--- a/drivers/scsi/bfa/bfa_fcs_rport.c ++++ b/drivers/scsi/bfa/bfa_fcs_rport.c +@@ -1871,6 +1871,8 @@ bfa_fcs_rport_process_rpsc(struct bfa_fcs_rport_s = *rport, struct fc_rpsc_speed_info_s speeds; struct bfa_port_attr_s pport_attr; =20 @@ -34520,21 +35484,10 @@ diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_fcs= _rport.c linux-3.1.4/drivers/scsi bfa_trc(port->fcs, rx_fchs->s_id); bfa_trc(port->fcs, rx_fchs->d_id); =20 -diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa.h linux-3.1.4/drivers/scsi/b= fa/bfa.h ---- linux-3.1.4/drivers/scsi/bfa/bfa.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/scsi/bfa/bfa.h 2011-11-16 18:39:07.000000000 -05= 00 -@@ -196,7 +196,7 @@ struct bfa_hwif_s { - u32 *end); - int cpe_vec_q0; - int rme_vec_q0; --}; -+} __no_const; - typedef void (*bfa_cb_iocfc_t) (void *cbarg, enum bfa_status status); -=20 - struct bfa_faa_cbfn_s { -diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_ioc.h linux-3.1.4/drivers/sc= si/bfa/bfa_ioc.h ---- linux-3.1.4/drivers/scsi/bfa/bfa_ioc.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/scsi/bfa/bfa_ioc.h 2011-11-16 18:39:07.000000000= -0500 +diff --git a/drivers/scsi/bfa/bfa_ioc.h b/drivers/scsi/bfa/bfa_ioc.h +index 546d46b..642fa5b 100644 +--- a/drivers/scsi/bfa/bfa_ioc.h ++++ b/drivers/scsi/bfa/bfa_ioc.h @@ -258,7 +258,7 @@ struct bfa_ioc_cbfn_s { bfa_ioc_disable_cbfn_t disable_cbfn; bfa_ioc_hbfail_cbfn_t hbfail_cbfn; @@ -34553,22 +35506,24 @@ diff -urNp linux-3.1.4/drivers/scsi/bfa/bfa_ioc= .h linux-3.1.4/drivers/scsi/bfa/b =20 /* * Queue element to wait for room in request queue. FIFO order is -diff -urNp linux-3.1.4/drivers/scsi/BusLogic.c linux-3.1.4/drivers/scsi/= BusLogic.c ---- linux-3.1.4/drivers/scsi/BusLogic.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/scsi/BusLogic.c 2011-11-16 18:40:22.000000000 -0= 500 -@@ -962,6 +962,8 @@ static int __init BusLogic_InitializeFla - static void __init BusLogic_InitializeProbeInfoList(struct BusLogic_Hos= tAdapter - *PrototypeHostAdapter) - { +diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c +index 66fb725..0fe05ab 100644 +--- a/drivers/scsi/bfa/bfad.c ++++ b/drivers/scsi/bfa/bfad.c +@@ -1019,6 +1019,8 @@ bfad_start_ops(struct bfad_s *bfad) { + struct bfad_vport_s *vport, *vport_new; + struct bfa_fcs_driver_info_s driver_info; +=20 + pax_track_stack(); + - /* - If a PCI BIOS is present, interrogate it for MultiMaster and FlashP= oint - Host Adapters; otherwise, default to the standard ISA MultiMaster p= robe. -diff -urNp linux-3.1.4/drivers/scsi/dpt_i2o.c linux-3.1.4/drivers/scsi/d= pt_i2o.c ---- linux-3.1.4/drivers/scsi/dpt_i2o.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/scsi/dpt_i2o.c 2011-11-16 18:40:22.000000000 -05= 00 -@@ -1811,6 +1811,8 @@ static int adpt_i2o_passthru(adpt_hba* p + /* Limit min/max. xfer size to [64k-32MB] */ + if (max_xfer_size < BFAD_MIN_SECTORS >> 1) + max_xfer_size =3D BFAD_MIN_SECTORS >> 1; +diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c +index b4f6c9a..0eb1938 100644 +--- a/drivers/scsi/dpt_i2o.c ++++ b/drivers/scsi/dpt_i2o.c +@@ -1811,6 +1811,8 @@ static int adpt_i2o_passthru(adpt_hba* pHba, u32 _= _user *arg) dma_addr_t addr; ulong flags =3D 0; =20 @@ -34577,7 +35532,7 @@ diff -urNp linux-3.1.4/drivers/scsi/dpt_i2o.c lin= ux-3.1.4/drivers/scsi/dpt_i2o.c memset(&msg, 0, MAX_MESSAGE_SIZE*4); // get user msg size in u32s=20 if(get_user(size, &user_msg[0])){ -@@ -2317,6 +2319,8 @@ static s32 adpt_scsi_to_i2o(adpt_hba* pH +@@ -2317,6 +2319,8 @@ static s32 adpt_scsi_to_i2o(adpt_hba* pHba, struct= scsi_cmnd* cmd, struct adpt_d s32 rcode; dma_addr_t addr; =20 @@ -34586,10 +35541,11 @@ diff -urNp linux-3.1.4/drivers/scsi/dpt_i2o.c l= inux-3.1.4/drivers/scsi/dpt_i2o.c memset(msg, 0 , sizeof(msg)); len =3D scsi_bufflen(cmd); direction =3D 0x00000000;=09 -diff -urNp linux-3.1.4/drivers/scsi/eata.c linux-3.1.4/drivers/scsi/eata= .c ---- linux-3.1.4/drivers/scsi/eata.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/eata.c 2011-11-16 18:40:22.000000000 -0500 -@@ -1087,6 +1087,8 @@ static int port_detect(unsigned long por +diff --git a/drivers/scsi/eata.c b/drivers/scsi/eata.c +index 94de889..ca4f0cf 100644 +--- a/drivers/scsi/eata.c ++++ b/drivers/scsi/eata.c +@@ -1087,6 +1087,8 @@ static int port_detect(unsigned long port_base, un= signed int j, struct hostdata *ha; char name[16]; =20 @@ -34598,10 +35554,11 @@ diff -urNp linux-3.1.4/drivers/scsi/eata.c linu= x-3.1.4/drivers/scsi/eata.c sprintf(name, "%s%d", driver_name, j); =20 if (!request_region(port_base, REGION_SIZE, driver_name)) { -diff -urNp linux-3.1.4/drivers/scsi/fcoe/fcoe_ctlr.c linux-3.1.4/drivers= /scsi/fcoe/fcoe_ctlr.c ---- linux-3.1.4/drivers/scsi/fcoe/fcoe_ctlr.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/scsi/fcoe/fcoe_ctlr.c 2011-11-16 18:40:22.000000= 000 -0500 -@@ -2503,6 +2503,8 @@ static int fcoe_ctlr_vn_recv(struct fcoe +diff --git a/drivers/scsi/fcoe/fcoe_ctlr.c b/drivers/scsi/fcoe/fcoe_ctlr= .c +index c74c4b8..c41ca3f 100644 +--- a/drivers/scsi/fcoe/fcoe_ctlr.c ++++ b/drivers/scsi/fcoe/fcoe_ctlr.c +@@ -2503,6 +2503,8 @@ static int fcoe_ctlr_vn_recv(struct fcoe_ctlr *fip= , struct sk_buff *skb) } buf; int rc; =20 @@ -34610,9 +35567,10 @@ diff -urNp linux-3.1.4/drivers/scsi/fcoe/fcoe_ct= lr.c linux-3.1.4/drivers/scsi/fc fiph =3D (struct fip_header *)skb->data; sub =3D fiph->fip_subcode; =20 -diff -urNp linux-3.1.4/drivers/scsi/gdth.c linux-3.1.4/drivers/scsi/gdth= .c ---- linux-3.1.4/drivers/scsi/gdth.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/gdth.c 2011-11-16 18:40:22.000000000 -0500 +diff --git a/drivers/scsi/gdth.c b/drivers/scsi/gdth.c +index 3242bca..45a83e7 100644 +--- a/drivers/scsi/gdth.c ++++ b/drivers/scsi/gdth.c @@ -4107,6 +4107,8 @@ static int ioc_lockdrv(void __user *arg) unsigned long flags; gdth_ha_str *ha; @@ -34622,7 +35580,7 @@ diff -urNp linux-3.1.4/drivers/scsi/gdth.c linux-= 3.1.4/drivers/scsi/gdth.c if (copy_from_user(&ldrv, arg, sizeof(gdth_ioctl_lockdrv))) return -EFAULT; ha =3D gdth_find_ha(ldrv.ionode); -@@ -4139,6 +4141,8 @@ static int ioc_resetdrv(void __user *arg +@@ -4139,6 +4141,8 @@ static int ioc_resetdrv(void __user *arg, char *cm= nd) gdth_ha_str *ha; int rval; =20 @@ -34631,7 +35589,7 @@ diff -urNp linux-3.1.4/drivers/scsi/gdth.c linux-= 3.1.4/drivers/scsi/gdth.c if (copy_from_user(&res, arg, sizeof(gdth_ioctl_reset)) || res.number >=3D MAX_HDRIVES) return -EFAULT; -@@ -4174,6 +4178,8 @@ static int ioc_general(void __user *arg, +@@ -4174,6 +4178,8 @@ static int ioc_general(void __user *arg, char *cmn= d) gdth_ha_str *ha; int rval; =20 @@ -34650,10 +35608,11 @@ diff -urNp linux-3.1.4/drivers/scsi/gdth.c linu= x-3.1.4/drivers/scsi/gdth.c memset(cmnd, 0xff, MAX_COMMAND_SIZE); =20 TRACE2(("gdth_flush() hanum %d\n", ha->hanum)); -diff -urNp linux-3.1.4/drivers/scsi/gdth_proc.c linux-3.1.4/drivers/scsi= /gdth_proc.c ---- linux-3.1.4/drivers/scsi/gdth_proc.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/scsi/gdth_proc.c 2011-11-16 18:40:22.000000000 -= 0500 -@@ -47,6 +47,9 @@ static int gdth_set_asc_info(struct Scsi +diff --git a/drivers/scsi/gdth_proc.c b/drivers/scsi/gdth_proc.c +index 6527543..81e4fe2 100644 +--- a/drivers/scsi/gdth_proc.c ++++ b/drivers/scsi/gdth_proc.c +@@ -47,6 +47,9 @@ static int gdth_set_asc_info(struct Scsi_Host *host, c= har *buffer, u64 paddr; =20 char cmnd[MAX_COMMAND_SIZE]; @@ -34663,7 +35622,7 @@ diff -urNp linux-3.1.4/drivers/scsi/gdth_proc.c l= inux-3.1.4/drivers/scsi/gdth_pr memset(cmnd, 0xff, 12); memset(&gdtcmd, 0, sizeof(gdth_cmd_str)); =20 -@@ -175,6 +178,8 @@ static int gdth_get_info(char *buffer,ch +@@ -175,6 +178,8 @@ static int gdth_get_info(char *buffer,char **start,o= ff_t offset,int length, gdth_hget_str *phg; char cmnd[MAX_COMMAND_SIZE]; =20 @@ -34672,9 +35631,10 @@ diff -urNp linux-3.1.4/drivers/scsi/gdth_proc.c = linux-3.1.4/drivers/scsi/gdth_pr gdtcmd =3D kmalloc(sizeof(*gdtcmd), GFP_KERNEL); estr =3D kmalloc(sizeof(*estr), GFP_KERNEL); if (!gdtcmd || !estr) -diff -urNp linux-3.1.4/drivers/scsi/hosts.c linux-3.1.4/drivers/scsi/hos= ts.c ---- linux-3.1.4/drivers/scsi/hosts.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/hosts.c 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/scsi/hosts.c b/drivers/scsi/hosts.c +index 351dc0b..951dc32 100644 +--- a/drivers/scsi/hosts.c ++++ b/drivers/scsi/hosts.c @@ -42,7 +42,7 @@ #include "scsi_logging.h" =20 @@ -34684,7 +35644,7 @@ diff -urNp linux-3.1.4/drivers/scsi/hosts.c linux= -3.1.4/drivers/scsi/hosts.c =20 =20 static void scsi_host_cls_release(struct device *dev) -@@ -357,7 +357,7 @@ struct Scsi_Host *scsi_host_alloc(struct +@@ -357,7 +357,7 @@ struct Scsi_Host *scsi_host_alloc(struct scsi_host_t= emplate *sht, int privsize) * subtract one because we increment first then return, but we need to * know what the next host number was before increment */ @@ -34693,10 +35653,11 @@ diff -urNp linux-3.1.4/drivers/scsi/hosts.c lin= ux-3.1.4/drivers/scsi/hosts.c shost->dma_channel =3D 0xff; =20 /* These three are default values which can be overridden */ -diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux-3.1.4/drivers/scsi/hpsa= .c ---- linux-3.1.4/drivers/scsi/hpsa.c 2011-11-26 19:57:29.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/hpsa.c 2011-11-26 20:00:43.000000000 -0500 -@@ -499,7 +499,7 @@ static inline u32 next_command(struct ct +diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c +index 418ce83..7ee1225 100644 +--- a/drivers/scsi/hpsa.c ++++ b/drivers/scsi/hpsa.c +@@ -499,7 +499,7 @@ static inline u32 next_command(struct ctlr_info *h) u32 a; =20 if (unlikely(!(h->transMethod & CFGTBL_Trans_Performant))) @@ -34705,7 +35666,7 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux-= 3.1.4/drivers/scsi/hpsa.c =20 if ((*(h->reply_pool_head) & 1) =3D=3D (h->reply_pool_wraparound)) { a =3D *(h->reply_pool_head); /* Next cmd in ring buffer */ -@@ -2956,7 +2956,7 @@ static void start_io(struct ctlr_info *h +@@ -2956,7 +2956,7 @@ static void start_io(struct ctlr_info *h) while (!list_empty(&h->reqQ)) { c =3D list_entry(h->reqQ.next, struct CommandList, list); /* can't do anything if fifo is full */ @@ -34714,7 +35675,7 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux-= 3.1.4/drivers/scsi/hpsa.c dev_warn(&h->pdev->dev, "fifo full\n"); break; } -@@ -2966,7 +2966,7 @@ static void start_io(struct ctlr_info *h +@@ -2966,7 +2966,7 @@ static void start_io(struct ctlr_info *h) h->Qdepth--; =20 /* Tell the controller execute command */ @@ -34723,7 +35684,7 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux-= 3.1.4/drivers/scsi/hpsa.c =20 /* Put job onto the completed Q */ addQ(&h->cmpQ, c); -@@ -2975,17 +2975,17 @@ static void start_io(struct ctlr_info *h +@@ -2975,17 +2975,17 @@ static void start_io(struct ctlr_info *h) =20 static inline unsigned long get_next_completion(struct ctlr_info *h) { @@ -34744,7 +35705,7 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux-= 3.1.4/drivers/scsi/hpsa.c (h->interrupts_enabled =3D=3D 0); } =20 -@@ -3882,7 +3882,7 @@ static int __devinit hpsa_pci_init(struc +@@ -3882,7 +3882,7 @@ static int __devinit hpsa_pci_init(struct ctlr_inf= o *h) if (prod_index < 0) return -ENODEV; h->product_name =3D products[prod_index].product_name; @@ -34792,7 +35753,7 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux-= 3.1.4/drivers/scsi/hpsa.c =20 hpsa_hba_inquiry(h); hpsa_register_scsi(h); /* hook ourselves into SCSI subsystem */ -@@ -4292,7 +4292,7 @@ static void hpsa_shutdown(struct pci_dev +@@ -4292,7 +4292,7 @@ static void hpsa_shutdown(struct pci_dev *pdev) * To write all data in the battery backed cache to disks */ hpsa_flush_cache(h); @@ -34801,7 +35762,7 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux-= 3.1.4/drivers/scsi/hpsa.c free_irq(h->intr[h->intr_mode], h); #ifdef CONFIG_PCI_MSI if (h->msix_vector) -@@ -4455,7 +4455,7 @@ static __devinit void hpsa_enter_perform +@@ -4455,7 +4455,7 @@ static __devinit void hpsa_enter_performant_mode(s= truct ctlr_info *h, return; } /* Change the access methods to the performant access methods */ @@ -34810,9 +35771,10 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.c linux= -3.1.4/drivers/scsi/hpsa.c h->transMethod =3D CFGTBL_Trans_Performant; } =20 -diff -urNp linux-3.1.4/drivers/scsi/hpsa.h linux-3.1.4/drivers/scsi/hpsa= .h ---- linux-3.1.4/drivers/scsi/hpsa.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/hpsa.h 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/scsi/hpsa.h b/drivers/scsi/hpsa.h +index 7f53cea..a8c7188 100644 +--- a/drivers/scsi/hpsa.h ++++ b/drivers/scsi/hpsa.h @@ -73,7 +73,7 @@ struct ctlr_info { unsigned int msix_vector; unsigned int msi_vector; @@ -34822,9 +35784,10 @@ diff -urNp linux-3.1.4/drivers/scsi/hpsa.h linux= -3.1.4/drivers/scsi/hpsa.h =20 /* queue and queue Info */ struct list_head reqQ; -diff -urNp linux-3.1.4/drivers/scsi/ips.h linux-3.1.4/drivers/scsi/ips.h ---- linux-3.1.4/drivers/scsi/ips.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/ips.h 2011-11-16 18:39:07.000000000 -0500 +diff --git a/drivers/scsi/ips.h b/drivers/scsi/ips.h +index f2df059..a3a9930 100644 +--- a/drivers/scsi/ips.h ++++ b/drivers/scsi/ips.h @@ -1027,7 +1027,7 @@ typedef struct { int (*intr)(struct ips_ha *); void (*enableint)(struct ips_ha *); @@ -34834,9 +35797,10 @@ diff -urNp linux-3.1.4/drivers/scsi/ips.h linux-= 3.1.4/drivers/scsi/ips.h =20 typedef struct ips_ha { uint8_t ha_id[IPS_MAX_CHANNELS+1]; -diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch.c linux-3.1.4/drivers/= scsi/libfc/fc_exch.c ---- linux-3.1.4/drivers/scsi/libfc/fc_exch.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/scsi/libfc/fc_exch.c 2011-11-16 18:39:07.0000000= 00 -0500 +diff --git a/drivers/scsi/libfc/fc_exch.c b/drivers/scsi/libfc/fc_exch.c +index d261e98..1e00f35 100644 +--- a/drivers/scsi/libfc/fc_exch.c ++++ b/drivers/scsi/libfc/fc_exch.c @@ -105,12 +105,12 @@ struct fc_exch_mgr { * all together if not used XXX */ @@ -34856,7 +35820,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib } stats; }; =20 -@@ -718,7 +718,7 @@ static struct fc_exch *fc_exch_em_alloc( +@@ -718,7 +718,7 @@ static struct fc_exch *fc_exch_em_alloc(struct fc_lp= ort *lport, /* allocate memory for exchange */ ep =3D mempool_alloc(mp->ep_pool, GFP_ATOMIC); if (!ep) { @@ -34874,7 +35838,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib mempool_free(ep, mp->ep_pool); return NULL; } -@@ -922,7 +922,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -922,7 +922,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, xid =3D ntohs(fh->fh_ox_id); /* we originated exch */ ep =3D fc_exch_find(mp, xid); if (!ep) { @@ -34883,7 +35847,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib reject =3D FC_RJT_OX_ID; goto out; } -@@ -952,7 +952,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -952,7 +952,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, ep =3D fc_exch_find(mp, xid); if ((f_ctl & FC_FC_FIRST_SEQ) && fc_sof_is_init(fr_sof(fp))) { if (ep) { @@ -34892,7 +35856,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib reject =3D FC_RJT_RX_ID; goto rel; } -@@ -963,7 +963,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -963,7 +963,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, } xid =3D ep->xid; /* get our XID */ } else if (!ep) { @@ -34901,7 +35865,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib reject =3D FC_RJT_RX_ID; /* XID not found */ goto out; } -@@ -980,7 +980,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -980,7 +980,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(str= uct fc_lport *lport, } else { sp =3D &ep->seq; if (sp->id !=3D fh->fh_seq_id) { @@ -34910,7 +35874,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib if (f_ctl & FC_FC_END_SEQ) { /* * Update sequence_id based on incoming last -@@ -1430,22 +1430,22 @@ static void fc_exch_recv_seq_resp(struct +@@ -1430,22 +1430,22 @@ static void fc_exch_recv_seq_resp(struct fc_exch= _mgr *mp, struct fc_frame *fp) =20 ep =3D fc_exch_find(mp, ntohs(fh->fh_ox_id)); if (!ep) { @@ -34937,7 +35901,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib goto rel; } sof =3D fr_sof(fp); -@@ -1454,7 +1454,7 @@ static void fc_exch_recv_seq_resp(struct +@@ -1454,7 +1454,7 @@ static void fc_exch_recv_seq_resp(struct fc_exch_m= gr *mp, struct fc_frame *fp) sp->ssb_stat |=3D SSB_ST_RESP; sp->id =3D fh->fh_seq_id; } else if (sp->id !=3D fh->fh_seq_id) { @@ -34946,7 +35910,7 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_exch= .c linux-3.1.4/drivers/scsi/lib goto rel; } =20 -@@ -1518,9 +1518,9 @@ static void fc_exch_recv_resp(struct fc_ +@@ -1518,9 +1518,9 @@ static void fc_exch_recv_resp(struct fc_exch_mgr *= mp, struct fc_frame *fp) sp =3D fc_seq_lookup_orig(mp, fp); /* doesn't hold sequence */ =20 if (!sp) @@ -34958,10 +35922,11 @@ diff -urNp linux-3.1.4/drivers/scsi/libfc/fc_ex= ch.c linux-3.1.4/drivers/scsi/lib =20 fc_frame_free(fp); } -diff -urNp linux-3.1.4/drivers/scsi/libsas/sas_ata.c linux-3.1.4/drivers= /scsi/libsas/sas_ata.c ---- linux-3.1.4/drivers/scsi/libsas/sas_ata.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/scsi/libsas/sas_ata.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -368,7 +368,7 @@ static struct ata_port_operations sas_sa +diff --git a/drivers/scsi/libsas/sas_ata.c b/drivers/scsi/libsas/sas_ata= .c +index db9238f..4378ed2 100644 +--- a/drivers/scsi/libsas/sas_ata.c ++++ b/drivers/scsi/libsas/sas_ata.c +@@ -368,7 +368,7 @@ static struct ata_port_operations sas_sata_ops =3D { .postreset =3D ata_std_postreset, .error_handler =3D ata_std_error_handler, .post_internal_cmd =3D sas_ata_post_internal, @@ -34970,10 +35935,44 @@ diff -urNp linux-3.1.4/drivers/scsi/libsas/sas_= ata.c linux-3.1.4/drivers/scsi/li .qc_prep =3D ata_noop_qc_prep, .qc_issue =3D sas_ata_qc_issue, .qc_fill_rtf =3D sas_ata_qc_fill_rtf, -diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.1.4/driv= ers/scsi/lpfc/lpfc_debugfs.c ---- linux-3.1.4/drivers/scsi/lpfc/lpfc_debugfs.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/scsi/lpfc/lpfc_debugfs.c 2011-11-16 18:40:22.000= 000000 -0500 -@@ -105,7 +105,7 @@ MODULE_PARM_DESC(lpfc_debugfs_mask_disc_ +diff --git a/drivers/scsi/lpfc/lpfc.h b/drivers/scsi/lpfc/lpfc.h +index c088a36..01c73b0 100644 +--- a/drivers/scsi/lpfc/lpfc.h ++++ b/drivers/scsi/lpfc/lpfc.h +@@ -425,7 +425,7 @@ struct lpfc_vport { + struct dentry *debug_nodelist; + struct dentry *vport_debugfs_root; + struct lpfc_debugfs_trc *disc_trc; +- atomic_t disc_trc_cnt; ++ atomic_unchecked_t disc_trc_cnt; + #endif + uint8_t stat_data_enabled; + uint8_t stat_data_blocked; +@@ -835,8 +835,8 @@ struct lpfc_hba { + struct timer_list fabric_block_timer; + unsigned long bit_flags; + #define FABRIC_COMANDS_BLOCKED 0 +- atomic_t num_rsrc_err; +- atomic_t num_cmd_success; ++ atomic_unchecked_t num_rsrc_err; ++ atomic_unchecked_t num_cmd_success; + unsigned long last_rsrc_error_time; + unsigned long last_ramp_down_time; + unsigned long last_ramp_up_time; +@@ -850,7 +850,7 @@ struct lpfc_hba { + struct dentry *debug_dumpDif; /* BlockGuard BPL*/ + struct dentry *debug_slow_ring_trc; + struct lpfc_debugfs_trc *slow_ring_trc; +- atomic_t slow_ring_trc_cnt; ++ atomic_unchecked_t slow_ring_trc_cnt; + /* iDiag debugfs sub-directory */ + struct dentry *idiag_root; + struct dentry *idiag_pci_cfg; +diff --git a/drivers/scsi/lpfc/lpfc_debugfs.c b/drivers/scsi/lpfc/lpfc_d= ebugfs.c +index a0424dd..2499b6b 100644 +--- a/drivers/scsi/lpfc/lpfc_debugfs.c ++++ b/drivers/scsi/lpfc/lpfc_debugfs.c +@@ -105,7 +105,7 @@ MODULE_PARM_DESC(lpfc_debugfs_mask_disc_trc, =20 #include =20 @@ -34982,7 +35981,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_deb= ugfs.c linux-3.1.4/drivers/scsi static unsigned long lpfc_debugfs_start_time =3D 0L; =20 /* iDiag */ -@@ -146,7 +146,7 @@ lpfc_debugfs_disc_trc_data(struct lpfc_v +@@ -146,7 +146,7 @@ lpfc_debugfs_disc_trc_data(struct lpfc_vport *vport,= char *buf, int size) lpfc_debugfs_enable =3D 0; =20 len =3D 0; @@ -34991,7 +35990,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_deb= ugfs.c linux-3.1.4/drivers/scsi (lpfc_debugfs_max_disc_trc - 1); for (i =3D index; i < lpfc_debugfs_max_disc_trc; i++) { dtp =3D vport->disc_trc + i; -@@ -212,7 +212,7 @@ lpfc_debugfs_slow_ring_trc_data(struct l +@@ -212,7 +212,7 @@ lpfc_debugfs_slow_ring_trc_data(struct lpfc_hba *phb= a, char *buf, int size) lpfc_debugfs_enable =3D 0; =20 len =3D 0; @@ -35000,7 +35999,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_deb= ugfs.c linux-3.1.4/drivers/scsi (lpfc_debugfs_max_slow_ring_trc - 1); for (i =3D index; i < lpfc_debugfs_max_slow_ring_trc; i++) { dtp =3D phba->slow_ring_trc + i; -@@ -635,14 +635,14 @@ lpfc_debugfs_disc_trc(struct lpfc_vport=20 +@@ -635,14 +635,14 @@ lpfc_debugfs_disc_trc(struct lpfc_vport *vport, in= t mask, char *fmt, !vport || !vport->disc_trc) return; =20 @@ -35017,7 +36016,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_deb= ugfs.c linux-3.1.4/drivers/scsi dtp->jif =3D jiffies; #endif return; -@@ -673,14 +673,14 @@ lpfc_debugfs_slow_ring_trc(struct lpfc_h +@@ -673,14 +673,14 @@ lpfc_debugfs_slow_ring_trc(struct lpfc_hba *phba, = char *fmt, !phba || !phba->slow_ring_trc) return; =20 @@ -35034,7 +36033,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_deb= ugfs.c linux-3.1.4/drivers/scsi dtp->jif =3D jiffies; #endif return; -@@ -3828,7 +3828,7 @@ lpfc_debugfs_initialize(struct lpfc_vpor +@@ -3828,7 +3828,7 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport) "slow_ring buffer\n"); goto debug_failed; } @@ -35043,7 +36042,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_deb= ugfs.c linux-3.1.4/drivers/scsi memset(phba->slow_ring_trc, 0, (sizeof(struct lpfc_debugfs_trc) * lpfc_debugfs_max_slow_ring_trc)); -@@ -3874,7 +3874,7 @@ lpfc_debugfs_initialize(struct lpfc_vpor +@@ -3874,7 +3874,7 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport) "buffer\n"); goto debug_failed; } @@ -35052,41 +36051,10 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_d= ebugfs.c linux-3.1.4/drivers/scsi =20 snprintf(name, sizeof(name), "discovery_trace"); vport->debug_disc_trc =3D -diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc.h linux-3.1.4/drivers/scsi= /lpfc/lpfc.h ---- linux-3.1.4/drivers/scsi/lpfc/lpfc.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/scsi/lpfc/lpfc.h 2011-11-16 18:39:07.000000000 -= 0500 -@@ -425,7 +425,7 @@ struct lpfc_vport { - struct dentry *debug_nodelist; - struct dentry *vport_debugfs_root; - struct lpfc_debugfs_trc *disc_trc; -- atomic_t disc_trc_cnt; -+ atomic_unchecked_t disc_trc_cnt; - #endif - uint8_t stat_data_enabled; - uint8_t stat_data_blocked; -@@ -835,8 +835,8 @@ struct lpfc_hba { - struct timer_list fabric_block_timer; - unsigned long bit_flags; - #define FABRIC_COMANDS_BLOCKED 0 -- atomic_t num_rsrc_err; -- atomic_t num_cmd_success; -+ atomic_unchecked_t num_rsrc_err; -+ atomic_unchecked_t num_cmd_success; - unsigned long last_rsrc_error_time; - unsigned long last_ramp_down_time; - unsigned long last_ramp_up_time; -@@ -850,7 +850,7 @@ struct lpfc_hba { - struct dentry *debug_dumpDif; /* BlockGuard BPL*/ - struct dentry *debug_slow_ring_trc; - struct lpfc_debugfs_trc *slow_ring_trc; -- atomic_t slow_ring_trc_cnt; -+ atomic_unchecked_t slow_ring_trc_cnt; - /* iDiag debugfs sub-directory */ - struct dentry *idiag_root; - struct dentry *idiag_pci_cfg; -diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_init.c linux-3.1.4/drivers= /scsi/lpfc/lpfc_init.c ---- linux-3.1.4/drivers/scsi/lpfc/lpfc_init.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/scsi/lpfc/lpfc_init.c 2011-11-16 18:39:07.000000= 000 -0500 +diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init= .c +index a3c8200..31e562e 100644 +--- a/drivers/scsi/lpfc/lpfc_init.c ++++ b/drivers/scsi/lpfc/lpfc_init.c @@ -9969,8 +9969,10 @@ lpfc_init(void) printk(LPFC_COPYRIGHT "\n"); =20 @@ -35100,10 +36068,11 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_i= nit.c linux-3.1.4/drivers/scsi/lp } lpfc_transport_template =3D fc_attach_transport(&lpfc_transport_functions); -diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_scsi.c linux-3.1.4/drivers= /scsi/lpfc/lpfc_scsi.c ---- linux-3.1.4/drivers/scsi/lpfc/lpfc_scsi.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/scsi/lpfc/lpfc_scsi.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -297,7 +297,7 @@ lpfc_rampdown_queue_depth(struct lpfc_hb +diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi= .c +index eadd241..26c8e0f 100644 +--- a/drivers/scsi/lpfc/lpfc_scsi.c ++++ b/drivers/scsi/lpfc/lpfc_scsi.c +@@ -297,7 +297,7 @@ lpfc_rampdown_queue_depth(struct lpfc_hba *phba) uint32_t evt_posted; =20 spin_lock_irqsave(&phba->hbalock, flags); @@ -35112,7 +36081,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_scs= i.c linux-3.1.4/drivers/scsi/lp phba->last_rsrc_error_time =3D jiffies; =20 if ((phba->last_ramp_down_time + QUEUE_RAMP_DOWN_INTERVAL) > jiffies) = { -@@ -338,7 +338,7 @@ lpfc_rampup_queue_depth(struct lpfc_vpor +@@ -338,7 +338,7 @@ lpfc_rampup_queue_depth(struct lpfc_vport *vport, unsigned long flags; struct lpfc_hba *phba =3D vport->phba; uint32_t evt_posted; @@ -35121,7 +36090,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_scs= i.c linux-3.1.4/drivers/scsi/lp =20 if (vport->cfg_lun_queue_depth <=3D queue_depth) return; -@@ -382,8 +382,8 @@ lpfc_ramp_down_queue_handler(struct lpfc +@@ -382,8 +382,8 @@ lpfc_ramp_down_queue_handler(struct lpfc_hba *phba) unsigned long num_rsrc_err, num_cmd_success; int i; =20 @@ -35132,7 +36101,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_scs= i.c linux-3.1.4/drivers/scsi/lp =20 vports =3D lpfc_create_vport_work_array(phba); if (vports !=3D NULL) -@@ -403,8 +403,8 @@ lpfc_ramp_down_queue_handler(struct lpfc +@@ -403,8 +403,8 @@ lpfc_ramp_down_queue_handler(struct lpfc_hba *phba) } } lpfc_destroy_vport_work_array(phba, vports); @@ -35143,7 +36112,7 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_scs= i.c linux-3.1.4/drivers/scsi/lp } =20 /** -@@ -438,8 +438,8 @@ lpfc_ramp_up_queue_handler(struct lpfc_h +@@ -438,8 +438,8 @@ lpfc_ramp_up_queue_handler(struct lpfc_hba *phba) } } lpfc_destroy_vport_work_array(phba, vports); @@ -35154,10 +36123,11 @@ diff -urNp linux-3.1.4/drivers/scsi/lpfc/lpfc_s= csi.c linux-3.1.4/drivers/scsi/lp } =20 /** -diff -urNp linux-3.1.4/drivers/scsi/megaraid/megaraid_mbox.c linux-3.1.4= /drivers/scsi/megaraid/megaraid_mbox.c ---- linux-3.1.4/drivers/scsi/megaraid/megaraid_mbox.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/megaraid/megaraid_mbox.c 2011-11-16 18:40:2= 2.000000000 -0500 -@@ -3503,6 +3503,8 @@ megaraid_cmm_register(adapter_t *adapter +diff --git a/drivers/scsi/megaraid/megaraid_mbox.c b/drivers/scsi/megara= id/megaraid_mbox.c +index 2e6619e..fa64494 100644 +--- a/drivers/scsi/megaraid/megaraid_mbox.c ++++ b/drivers/scsi/megaraid/megaraid_mbox.c +@@ -3503,6 +3503,8 @@ megaraid_cmm_register(adapter_t *adapter) int rval; int i; =20 @@ -35166,10 +36136,11 @@ diff -urNp linux-3.1.4/drivers/scsi/megaraid/me= garaid_mbox.c linux-3.1.4/drivers // Allocate memory for the base list of scb for management module. adapter->uscb_list =3D kcalloc(MBOX_MAX_USER_CMDS, sizeof(scb_t), GFP_= KERNEL); =20 -diff -urNp linux-3.1.4/drivers/scsi/osd/osd_initiator.c linux-3.1.4/driv= ers/scsi/osd/osd_initiator.c ---- linux-3.1.4/drivers/scsi/osd/osd_initiator.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/scsi/osd/osd_initiator.c 2011-11-16 18:40:22.000= 000000 -0500 -@@ -97,6 +97,8 @@ static int _osd_get_print_system_info(st +diff --git a/drivers/scsi/osd/osd_initiator.c b/drivers/scsi/osd/osd_ini= tiator.c +index 86afb13f..c912398 100644 +--- a/drivers/scsi/osd/osd_initiator.c ++++ b/drivers/scsi/osd/osd_initiator.c +@@ -97,6 +97,8 @@ static int _osd_get_print_system_info(struct osd_dev *= od, int nelem =3D ARRAY_SIZE(get_attrs), a =3D 0; int ret; =20 @@ -35178,10 +36149,11 @@ diff -urNp linux-3.1.4/drivers/scsi/osd/osd_ini= tiator.c linux-3.1.4/drivers/scsi or =3D osd_start_request(od, GFP_KERNEL); if (!or) return -ENOMEM; -diff -urNp linux-3.1.4/drivers/scsi/pmcraid.c linux-3.1.4/drivers/scsi/p= mcraid.c ---- linux-3.1.4/drivers/scsi/pmcraid.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/scsi/pmcraid.c 2011-11-16 18:39:07.000000000 -05= 00 -@@ -201,8 +201,8 @@ static int pmcraid_slave_alloc(struct sc +diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c +index d079f9a..d26072c 100644 +--- a/drivers/scsi/pmcraid.c ++++ b/drivers/scsi/pmcraid.c +@@ -201,8 +201,8 @@ static int pmcraid_slave_alloc(struct scsi_device *s= csi_dev) res->scsi_dev =3D scsi_dev; scsi_dev->hostdata =3D res; res->change_detected =3D 0; @@ -35192,7 +36164,7 @@ diff -urNp linux-3.1.4/drivers/scsi/pmcraid.c lin= ux-3.1.4/drivers/scsi/pmcraid.c rc =3D 0; } spin_unlock_irqrestore(&pinstance->resource_lock, lock_flags); -@@ -2677,9 +2677,9 @@ static int pmcraid_error_handler(struct=20 +@@ -2677,9 +2677,9 @@ static int pmcraid_error_handler(struct pmcraid_cm= d *cmd) =20 /* If this was a SCSI read/write command keep count of errors */ if (SCSI_CMD_TYPE(scsi_cmd->cmnd[0]) =3D=3D SCSI_READ_CMD) @@ -35222,7 +36194,7 @@ diff -urNp linux-3.1.4/drivers/scsi/pmcraid.c lin= ux-3.1.4/drivers/scsi/pmcraid.c pinstance->num_hrrq; =20 if (request_size) { -@@ -4498,7 +4498,7 @@ static void pmcraid_worker_function(stru +@@ -4498,7 +4498,7 @@ static void pmcraid_worker_function(struct work_st= ruct *workp) =20 pinstance =3D container_of(workp, struct pmcraid_instance, worker_q); /* add resources only after host is added into system */ @@ -35231,7 +36203,7 @@ diff -urNp linux-3.1.4/drivers/scsi/pmcraid.c lin= ux-3.1.4/drivers/scsi/pmcraid.c return; =20 fw_version =3D be16_to_cpu(pinstance->inq_data->fw_version); -@@ -5332,8 +5332,8 @@ static int __devinit pmcraid_init_instan +@@ -5332,8 +5332,8 @@ static int __devinit pmcraid_init_instance( init_waitqueue_head(&pinstance->reset_wait_q); =20 atomic_set(&pinstance->outstanding_cmds, 0); @@ -35251,9 +36223,10 @@ diff -urNp linux-3.1.4/drivers/scsi/pmcraid.c li= nux-3.1.4/drivers/scsi/pmcraid.c schedule_work(&pinstance->worker_q); return rc; =20 -diff -urNp linux-3.1.4/drivers/scsi/pmcraid.h linux-3.1.4/drivers/scsi/p= mcraid.h ---- linux-3.1.4/drivers/scsi/pmcraid.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/scsi/pmcraid.h 2011-11-16 18:39:07.000000000 -05= 00 +diff --git a/drivers/scsi/pmcraid.h b/drivers/scsi/pmcraid.h +index f920baf..4417389 100644 +--- a/drivers/scsi/pmcraid.h ++++ b/drivers/scsi/pmcraid.h @@ -749,7 +749,7 @@ struct pmcraid_instance { struct pmcraid_isr_param hrrq_vector[PMCRAID_NUM_MSIX_VECTORS]; =20 @@ -35283,9 +36256,10 @@ diff -urNp linux-3.1.4/drivers/scsi/pmcraid.h li= nux-3.1.4/drivers/scsi/pmcraid.h =20 /* To indicate add/delete/modify during CCN */ u8 change_detected; -diff -urNp linux-3.1.4/drivers/scsi/qla2xxx/qla_def.h linux-3.1.4/driver= s/scsi/qla2xxx/qla_def.h ---- linux-3.1.4/drivers/scsi/qla2xxx/qla_def.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/scsi/qla2xxx/qla_def.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_d= ef.h +index a03eaf4..a6b3fd9 100644 +--- a/drivers/scsi/qla2xxx/qla_def.h ++++ b/drivers/scsi/qla2xxx/qla_def.h @@ -2244,7 +2244,7 @@ struct isp_operations { int (*get_flash_version) (struct scsi_qla_host *, void *); int (*start_scsi) (srb_t *); @@ -35295,9 +36269,10 @@ diff -urNp linux-3.1.4/drivers/scsi/qla2xxx/qla_= def.h linux-3.1.4/drivers/scsi/q =20 /* MSI-X Support ******************************************************= *******/ =20 -diff -urNp linux-3.1.4/drivers/scsi/qla4xxx/ql4_def.h linux-3.1.4/driver= s/scsi/qla4xxx/ql4_def.h ---- linux-3.1.4/drivers/scsi/qla4xxx/ql4_def.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/scsi/qla4xxx/ql4_def.h 2011-11-16 18:39:07.00000= 0000 -0500 +diff --git a/drivers/scsi/qla4xxx/ql4_def.h b/drivers/scsi/qla4xxx/ql4_d= ef.h +index 473c5c8..4e2f24a 100644 +--- a/drivers/scsi/qla4xxx/ql4_def.h ++++ b/drivers/scsi/qla4xxx/ql4_def.h @@ -256,7 +256,7 @@ struct ddb_entry { atomic_t retry_relogin_timer; /* Min Time between relogins * (4000 only) */ @@ -35307,10 +36282,11 @@ diff -urNp linux-3.1.4/drivers/scsi/qla4xxx/ql4= _def.h linux-3.1.4/drivers/scsi/q * retried */ =20 uint16_t port; -diff -urNp linux-3.1.4/drivers/scsi/qla4xxx/ql4_init.c linux-3.1.4/drive= rs/scsi/qla4xxx/ql4_init.c ---- linux-3.1.4/drivers/scsi/qla4xxx/ql4_init.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/scsi/qla4xxx/ql4_init.c 2011-11-16 18:39:07.0000= 00000 -0500 -@@ -680,7 +680,7 @@ static struct ddb_entry * qla4xxx_alloc_ +diff --git a/drivers/scsi/qla4xxx/ql4_init.c b/drivers/scsi/qla4xxx/ql4_= init.c +index 42ed5db..0262f9e 100644 +--- a/drivers/scsi/qla4xxx/ql4_init.c ++++ b/drivers/scsi/qla4xxx/ql4_init.c +@@ -680,7 +680,7 @@ static struct ddb_entry * qla4xxx_alloc_ddb(struct s= csi_qla_host *ha, ddb_entry->fw_ddb_index =3D fw_ddb_index; atomic_set(&ddb_entry->retry_relogin_timer, INVALID_ENTRY); atomic_set(&ddb_entry->relogin_timer, 0); @@ -35319,7 +36295,7 @@ diff -urNp linux-3.1.4/drivers/scsi/qla4xxx/ql4_i= nit.c linux-3.1.4/drivers/scsi/ atomic_set(&ddb_entry->state, DDB_STATE_ONLINE); list_add_tail(&ddb_entry->list, &ha->ddb_list); ha->fw_ddb_index_map[fw_ddb_index] =3D ddb_entry; -@@ -1433,7 +1433,7 @@ int qla4xxx_process_ddb_changed(struct s +@@ -1433,7 +1433,7 @@ int qla4xxx_process_ddb_changed(struct scsi_qla_ho= st *ha, uint32_t fw_ddb_index, if ((ddb_entry->fw_ddb_device_state =3D=3D DDB_DS_SESSION_ACTIVE) && (atomic_read(&ddb_entry->state) !=3D DDB_STATE_ONLINE)) { atomic_set(&ddb_entry->state, DDB_STATE_ONLINE); @@ -35328,10 +36304,11 @@ diff -urNp linux-3.1.4/drivers/scsi/qla4xxx/ql4= _init.c linux-3.1.4/drivers/scsi/ atomic_set(&ddb_entry->relogin_timer, 0); clear_bit(DF_RELOGIN, &ddb_entry->flags); iscsi_unblock_session(ddb_entry->sess); -diff -urNp linux-3.1.4/drivers/scsi/qla4xxx/ql4_os.c linux-3.1.4/drivers= /scsi/qla4xxx/ql4_os.c ---- linux-3.1.4/drivers/scsi/qla4xxx/ql4_os.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/scsi/qla4xxx/ql4_os.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -811,13 +811,13 @@ static void qla4xxx_timer(struct scsi_ql +diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os= .c +index f2364ec..44c42b1 100644 +--- a/drivers/scsi/qla4xxx/ql4_os.c ++++ b/drivers/scsi/qla4xxx/ql4_os.c +@@ -811,13 +811,13 @@ static void qla4xxx_timer(struct scsi_qla_host *ha= ) ddb_entry->fw_ddb_device_state =3D=3D DDB_DS_SESSION_FAILED) { /* Reset retry relogin timer */ @@ -35347,10 +36324,11 @@ diff -urNp linux-3.1.4/drivers/scsi/qla4xxx/ql4= _os.c linux-3.1.4/drivers/scsi/ql relogin_retry_count)) ); start_dpc++; -diff -urNp linux-3.1.4/drivers/scsi/scsi.c linux-3.1.4/drivers/scsi/scsi= .c ---- linux-3.1.4/drivers/scsi/scsi.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/scsi.c 2011-11-16 18:39:07.000000000 -0500 -@@ -655,7 +655,7 @@ int scsi_dispatch_cmd(struct scsi_cmnd * +diff --git a/drivers/scsi/scsi.c b/drivers/scsi/scsi.c +index 2aeb2e9..46e3925 100644 +--- a/drivers/scsi/scsi.c ++++ b/drivers/scsi/scsi.c +@@ -655,7 +655,7 @@ int scsi_dispatch_cmd(struct scsi_cmnd *cmd) unsigned long timeout; int rtn =3D 0; =20 @@ -35359,10 +36337,11 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi.c linu= x-3.1.4/drivers/scsi/scsi.c =20 /* check if the device is still usable */ if (unlikely(cmd->device->sdev_state =3D=3D SDEV_DEL)) { -diff -urNp linux-3.1.4/drivers/scsi/scsi_debug.c linux-3.1.4/drivers/scs= i/scsi_debug.c ---- linux-3.1.4/drivers/scsi/scsi_debug.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/scsi/scsi_debug.c 2011-11-16 18:40:22.000000000 = -0500 -@@ -1493,6 +1493,8 @@ static int resp_mode_select(struct scsi_ +diff --git a/drivers/scsi/scsi_debug.c b/drivers/scsi/scsi_debug.c +index 6888b2c..45befa1 100644 +--- a/drivers/scsi/scsi_debug.c ++++ b/drivers/scsi/scsi_debug.c +@@ -1493,6 +1493,8 @@ static int resp_mode_select(struct scsi_cmnd * scp= , int mselect6, unsigned char arr[SDEBUG_MAX_MSELECT_SZ]; unsigned char *cmd =3D (unsigned char *)scp->cmnd; =20 @@ -35371,7 +36350,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_debug.c = linux-3.1.4/drivers/scsi/scsi_d if ((errsts =3D check_readiness(scp, 1, devip))) return errsts; memset(arr, 0, sizeof(arr)); -@@ -1590,6 +1592,8 @@ static int resp_log_sense(struct scsi_cm +@@ -1590,6 +1592,8 @@ static int resp_log_sense(struct scsi_cmnd * scp, unsigned char arr[SDEBUG_MAX_LSENSE_SZ]; unsigned char *cmd =3D (unsigned char *)scp->cmnd; =20 @@ -35380,10 +36359,11 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_debug.= c linux-3.1.4/drivers/scsi/scsi_d if ((errsts =3D check_readiness(scp, 1, devip))) return errsts; memset(arr, 0, sizeof(arr)); -diff -urNp linux-3.1.4/drivers/scsi/scsi_lib.c linux-3.1.4/drivers/scsi/= scsi_lib.c ---- linux-3.1.4/drivers/scsi/scsi_lib.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/scsi/scsi_lib.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -1413,7 +1413,7 @@ static void scsi_kill_request(struct req +diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c +index b4d43ae..26edd69 100644 +--- a/drivers/scsi/scsi_lib.c ++++ b/drivers/scsi/scsi_lib.c +@@ -1413,7 +1413,7 @@ static void scsi_kill_request(struct request *req,= struct request_queue *q) shost =3D sdev->host; scsi_init_cmd_errh(cmd); cmd->result =3D DID_NO_CONNECT << 16; @@ -35392,7 +36372,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_lib.c li= nux-3.1.4/drivers/scsi/scsi_lib =20 /* * SCSI request completion path will do scsi_device_unbusy(), -@@ -1439,9 +1439,9 @@ static void scsi_softirq_done(struct req +@@ -1439,9 +1439,9 @@ static void scsi_softirq_done(struct request *rq) =20 INIT_LIST_HEAD(&cmd->eh_entry); =20 @@ -35404,10 +36384,11 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_lib.c = linux-3.1.4/drivers/scsi/scsi_lib =20 disposition =3D scsi_decide_disposition(cmd); if (disposition !=3D SUCCESS && -diff -urNp linux-3.1.4/drivers/scsi/scsi_sysfs.c linux-3.1.4/drivers/scs= i/scsi_sysfs.c ---- linux-3.1.4/drivers/scsi/scsi_sysfs.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/scsi/scsi_sysfs.c 2011-11-16 18:39:07.000000000 = -0500 -@@ -622,7 +622,7 @@ show_iostat_##field(struct device *dev,=20 +diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c +index e0bd3f7..816b8a6 100644 +--- a/drivers/scsi/scsi_sysfs.c ++++ b/drivers/scsi/scsi_sysfs.c +@@ -622,7 +622,7 @@ show_iostat_##field(struct device *dev, struct devic= e_attribute *attr, \ char *buf) \ { \ struct scsi_device *sdev =3D to_scsi_device(dev); \ @@ -35416,10 +36397,11 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_sysfs.= c linux-3.1.4/drivers/scsi/scsi_s return snprintf(buf, 20, "0x%llx\n", count); \ } \ static DEVICE_ATTR(field, S_IRUGO, show_iostat_##field, NULL) -diff -urNp linux-3.1.4/drivers/scsi/scsi_tgt_lib.c linux-3.1.4/drivers/s= csi/scsi_tgt_lib.c ---- linux-3.1.4/drivers/scsi/scsi_tgt_lib.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/scsi/scsi_tgt_lib.c 2011-11-16 18:39:07.00000000= 0 -0500 -@@ -362,7 +362,7 @@ static int scsi_map_user_pages(struct sc +diff --git a/drivers/scsi/scsi_tgt_lib.c b/drivers/scsi/scsi_tgt_lib.c +index 84a1fdf..693b0d6 100644 +--- a/drivers/scsi/scsi_tgt_lib.c ++++ b/drivers/scsi/scsi_tgt_lib.c +@@ -362,7 +362,7 @@ static int scsi_map_user_pages(struct scsi_tgt_cmd *= tcmd, struct scsi_cmnd *cmd, int err; =20 dprintk("%lx %u\n", uaddr, len); @@ -35428,10 +36410,11 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_tgt_li= b.c linux-3.1.4/drivers/scsi/scsi if (err) { /* * TODO: need to fixup sg_tablesize, max_segment_size, -diff -urNp linux-3.1.4/drivers/scsi/scsi_transport_fc.c linux-3.1.4/driv= ers/scsi/scsi_transport_fc.c ---- linux-3.1.4/drivers/scsi/scsi_transport_fc.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/scsi/scsi_transport_fc.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -484,7 +484,7 @@ static DECLARE_TRANSPORT_CLASS(fc_vport_ +diff --git a/drivers/scsi/scsi_transport_fc.c b/drivers/scsi/scsi_transp= ort_fc.c +index 1b21491..1b7f60e 100644 +--- a/drivers/scsi/scsi_transport_fc.c ++++ b/drivers/scsi/scsi_transport_fc.c +@@ -484,7 +484,7 @@ static DECLARE_TRANSPORT_CLASS(fc_vport_class, * Netlink Infrastructure */ =20 @@ -35449,7 +36432,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpor= t_fc.c linux-3.1.4/drivers/scsi } EXPORT_SYMBOL(fc_get_event_number); =20 -@@ -645,7 +645,7 @@ static __init int fc_transport_init(void +@@ -645,7 +645,7 @@ static __init int fc_transport_init(void) { int error; =20 @@ -35458,7 +36441,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpor= t_fc.c linux-3.1.4/drivers/scsi =20 error =3D transport_class_register(&fc_host_class); if (error) -@@ -835,7 +835,7 @@ static int fc_str_to_dev_loss(const char +@@ -835,7 +835,7 @@ static int fc_str_to_dev_loss(const char *buf, unsig= ned long *val) char *cp; =20 *val =3D simple_strtoul(buf, &cp, 0); @@ -35467,9 +36450,10 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpo= rt_fc.c linux-3.1.4/drivers/scsi return -EINVAL; /* * Check for overflow; dev_loss_tmo is u32 -diff -urNp linux-3.1.4/drivers/scsi/scsi_transport_iscsi.c linux-3.1.4/d= rivers/scsi/scsi_transport_iscsi.c ---- linux-3.1.4/drivers/scsi/scsi_transport_iscsi.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/scsi/scsi_transport_iscsi.c 2011-11-16 18:39:07.= 000000000 -0500 +diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_tra= nsport_iscsi.c +index 3fd16d7..ba0871f 100644 +--- a/drivers/scsi/scsi_transport_iscsi.c ++++ b/drivers/scsi/scsi_transport_iscsi.c @@ -83,7 +83,7 @@ struct iscsi_internal { struct device_attribute *session_attrs[ISCSI_SESSION_ATTRS + 1]; }; @@ -35479,7 +36463,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpor= t_iscsi.c linux-3.1.4/drivers/s static struct workqueue_struct *iscsi_eh_timer_workq; =20 /* -@@ -761,7 +761,7 @@ int iscsi_add_session(struct iscsi_cls_s +@@ -761,7 +761,7 @@ int iscsi_add_session(struct iscsi_cls_session *sess= ion, unsigned int target_id) int err; =20 ihost =3D shost->shost_data; @@ -35488,7 +36472,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpor= t_iscsi.c linux-3.1.4/drivers/s =20 if (id =3D=3D ISCSI_MAX_TARGET) { for (id =3D 0; id < ISCSI_MAX_TARGET; id++) { -@@ -2200,7 +2200,7 @@ static __init int iscsi_transport_init(v +@@ -2200,7 +2200,7 @@ static __init int iscsi_transport_init(void) printk(KERN_INFO "Loading iSCSI transport class v%s.\n", ISCSI_TRANSPORT_VERSION); =20 @@ -35497,9 +36481,10 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpo= rt_iscsi.c linux-3.1.4/drivers/s =20 err =3D class_register(&iscsi_transport_class); if (err) -diff -urNp linux-3.1.4/drivers/scsi/scsi_transport_srp.c linux-3.1.4/dri= vers/scsi/scsi_transport_srp.c ---- linux-3.1.4/drivers/scsi/scsi_transport_srp.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/scsi/scsi_transport_srp.c 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/drivers/scsi/scsi_transport_srp.c b/drivers/scsi/scsi_trans= port_srp.c +index 21a045e..ec89e03 100644 +--- a/drivers/scsi/scsi_transport_srp.c ++++ b/drivers/scsi/scsi_transport_srp.c @@ -33,7 +33,7 @@ #include "scsi_transport_srp_internal.h" =20 @@ -35509,7 +36494,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpor= t_srp.c linux-3.1.4/drivers/scs }; #define to_srp_host_attrs(host) ((struct srp_host_attrs *)(host)->shost= _data) =20 -@@ -62,7 +62,7 @@ static int srp_host_setup(struct transpo +@@ -62,7 +62,7 @@ static int srp_host_setup(struct transport_container *= tc, struct device *dev, struct Scsi_Host *shost =3D dev_to_shost(dev); struct srp_host_attrs *srp_host =3D to_srp_host_attrs(shost); =20 @@ -35518,7 +36503,7 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transpor= t_srp.c linux-3.1.4/drivers/scs return 0; } =20 -@@ -211,7 +211,7 @@ struct srp_rport *srp_rport_add(struct S +@@ -211,7 +211,7 @@ struct srp_rport *srp_rport_add(struct Scsi_Host *sh= ost, memcpy(rport->port_id, ids->port_id, sizeof(rport->port_id)); rport->roles =3D ids->roles; =20 @@ -35527,10 +36512,11 @@ diff -urNp linux-3.1.4/drivers/scsi/scsi_transp= ort_srp.c linux-3.1.4/drivers/scs dev_set_name(&rport->dev, "port-%d:%d", shost->host_no, id); =20 transport_setup_device(&rport->dev); -diff -urNp linux-3.1.4/drivers/scsi/sg.c linux-3.1.4/drivers/scsi/sg.c ---- linux-3.1.4/drivers/scsi/sg.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/scsi/sg.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1075,7 +1075,7 @@ sg_ioctl(struct file *filp, unsigned int +diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c +index 909ed9e..1ae290a 100644 +--- a/drivers/scsi/sg.c ++++ b/drivers/scsi/sg.c +@@ -1075,7 +1075,7 @@ sg_ioctl(struct file *filp, unsigned int cmd_in, u= nsigned long arg) sdp->disk->disk_name, MKDEV(SCSI_GENERIC_MAJOR, sdp->index), NULL, @@ -35557,10 +36543,11 @@ diff -urNp linux-3.1.4/drivers/scsi/sg.c linux-= 3.1.4/drivers/scsi/sg.c =20 sg_proc_sgp =3D proc_mkdir(sg_proc_sg_dirname, NULL); if (!sg_proc_sgp) -diff -urNp linux-3.1.4/drivers/scsi/sym53c8xx_2/sym_glue.c linux-3.1.4/d= rivers/scsi/sym53c8xx_2/sym_glue.c ---- linux-3.1.4/drivers/scsi/sym53c8xx_2/sym_glue.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/scsi/sym53c8xx_2/sym_glue.c 2011-11-16 18:40:22.= 000000000 -0500 -@@ -1756,6 +1756,8 @@ static int __devinit sym2_probe(struct p +diff --git a/drivers/scsi/sym53c8xx_2/sym_glue.c b/drivers/scsi/sym53c8x= x_2/sym_glue.c +index b4543f5..e1b34b8 100644 +--- a/drivers/scsi/sym53c8xx_2/sym_glue.c ++++ b/drivers/scsi/sym53c8xx_2/sym_glue.c +@@ -1756,6 +1756,8 @@ static int __devinit sym2_probe(struct pci_dev *pd= ev, int do_iounmap =3D 0; int do_disable_device =3D 1; =20 @@ -35569,10 +36556,11 @@ diff -urNp linux-3.1.4/drivers/scsi/sym53c8xx_2= /sym_glue.c linux-3.1.4/drivers/s memset(&sym_dev, 0, sizeof(sym_dev)); memset(&nvram, 0, sizeof(nvram)); sym_dev.pdev =3D pdev; -diff -urNp linux-3.1.4/drivers/scsi/vmw_pvscsi.c linux-3.1.4/drivers/scs= i/vmw_pvscsi.c ---- linux-3.1.4/drivers/scsi/vmw_pvscsi.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/scsi/vmw_pvscsi.c 2011-11-16 18:40:22.000000000 = -0500 -@@ -447,6 +447,8 @@ static void pvscsi_setup_all_rings(const +diff --git a/drivers/scsi/vmw_pvscsi.c b/drivers/scsi/vmw_pvscsi.c +index a18996d..fe993cb 100644 +--- a/drivers/scsi/vmw_pvscsi.c ++++ b/drivers/scsi/vmw_pvscsi.c +@@ -447,6 +447,8 @@ static void pvscsi_setup_all_rings(const struct pvsc= si_adapter *adapter) dma_addr_t base; unsigned i; =20 @@ -35581,22 +36569,11 @@ diff -urNp linux-3.1.4/drivers/scsi/vmw_pvscsi.= c linux-3.1.4/drivers/scsi/vmw_pv cmd.ringsStatePPN =3D adapter->ringStatePA >> PAGE_SHIFT; cmd.reqRingNumPages =3D adapter->req_pages; cmd.cmpRingNumPages =3D adapter->cmp_pages; -diff -urNp linux-3.1.4/drivers/spi/spi.c linux-3.1.4/drivers/spi/spi.c ---- linux-3.1.4/drivers/spi/spi.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/spi/spi.c 2011-11-16 18:39:07.000000000 -0500 -@@ -1023,7 +1023,7 @@ int spi_bus_unlock(struct spi_master *ma - EXPORT_SYMBOL_GPL(spi_bus_unlock); -=20 - /* portable code must never pass more than 32 bytes */ --#define SPI_BUFSIZ max(32,SMP_CACHE_BYTES) -+#define SPI_BUFSIZ max(32UL,SMP_CACHE_BYTES) -=20 - static u8 *buf; -=20 -diff -urNp linux-3.1.4/drivers/spi/spi-dw-pci.c linux-3.1.4/drivers/spi/= spi-dw-pci.c ---- linux-3.1.4/drivers/spi/spi-dw-pci.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/spi/spi-dw-pci.c 2011-11-16 18:39:07.000000000 -= 0500 -@@ -148,7 +148,7 @@ static int spi_resume(struct pci_dev *pd +diff --git a/drivers/spi/spi-dw-pci.c b/drivers/spi/spi-dw-pci.c +index c5f37f0..898d202 100644 +--- a/drivers/spi/spi-dw-pci.c ++++ b/drivers/spi/spi-dw-pci.c +@@ -148,7 +148,7 @@ static int spi_resume(struct pci_dev *pdev) #define spi_resume NULL #endif =20 @@ -35605,10 +36582,24 @@ diff -urNp linux-3.1.4/drivers/spi/spi-dw-pci.c= linux-3.1.4/drivers/spi/spi-dw-p /* Intel MID platform SPI controller 0 */ { PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x0800) }, {}, -diff -urNp linux-3.1.4/drivers/staging/ath6kl/os/linux/ar6000_drv.c linu= x-3.1.4/drivers/staging/ath6kl/os/linux/ar6000_drv.c ---- linux-3.1.4/drivers/staging/ath6kl/os/linux/ar6000_drv.c 2011-11-11 = 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/staging/ath6kl/os/linux/ar6000_drv.c 2011-11-16 = 18:39:07.000000000 -0500 -@@ -362,7 +362,7 @@ static struct ar_cookie s_ar_cookie_mem[ +diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c +index 4d1b9f5..8408fe3 100644 +--- a/drivers/spi/spi.c ++++ b/drivers/spi/spi.c +@@ -1023,7 +1023,7 @@ int spi_bus_unlock(struct spi_master *master) + EXPORT_SYMBOL_GPL(spi_bus_unlock); +=20 + /* portable code must never pass more than 32 bytes */ +-#define SPI_BUFSIZ max(32,SMP_CACHE_BYTES) ++#define SPI_BUFSIZ max(32UL,SMP_CACHE_BYTES) +=20 + static u8 *buf; +=20 +diff --git a/drivers/staging/ath6kl/os/linux/ar6000_drv.c b/drivers/stag= ing/ath6kl/os/linux/ar6000_drv.c +index 32ee39a..3004c3d 100644 +--- a/drivers/staging/ath6kl/os/linux/ar6000_drv.c ++++ b/drivers/staging/ath6kl/os/linux/ar6000_drv.c +@@ -362,7 +362,7 @@ static struct ar_cookie s_ar_cookie_mem[MAX_COOKIE_N= UM]; (((ar)->arTargetType =3D=3D TARGET_TYPE_AR6003) ? AR6003_HOST_I= NTEREST_ITEM_ADDRESS(item) : 0)) =20 =20 @@ -35617,10 +36608,11 @@ diff -urNp linux-3.1.4/drivers/staging/ath6kl/o= s/linux/ar6000_drv.c linux-3.1.4/ .ndo_init =3D NULL, .ndo_open =3D ar6000_open, .ndo_stop =3D ar6000_close, -diff -urNp linux-3.1.4/drivers/staging/ath6kl/os/linux/include/ar6k_pal.= h linux-3.1.4/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h ---- linux-3.1.4/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h 2011-= 11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h 2011-= 11-16 18:39:07.000000000 -0500 -@@ -30,7 +30,7 @@ typedef bool (*ar6k_pal_recv_pkt_t)(void +diff --git a/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h b/driver= s/staging/ath6kl/os/linux/include/ar6k_pal.h +index 39e0873..0925710 100644 +--- a/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h ++++ b/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h +@@ -30,7 +30,7 @@ typedef bool (*ar6k_pal_recv_pkt_t)(void *pHciPalInfo,= void *skb); typedef struct ar6k_pal_config_s { ar6k_pal_recv_pkt_t fpar6k_pal_recv_pkt; @@ -35629,10 +36621,11 @@ diff -urNp linux-3.1.4/drivers/staging/ath6kl/o= s/linux/include/ar6k_pal.h linux- =20 void register_pal_cb(ar6k_pal_config_t *palConfig_p); #endif /* _AR6K_PAL_H_ */ -diff -urNp linux-3.1.4/drivers/staging/brcm80211/brcmfmac/dhd_linux.c li= nux-3.1.4/drivers/staging/brcm80211/brcmfmac/dhd_linux.c ---- linux-3.1.4/drivers/staging/brcm80211/brcmfmac/dhd_linux.c 2011-11-1= 1 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/staging/brcm80211/brcmfmac/dhd_linux.c 2011-11-1= 6 18:39:07.000000000 -0500 -@@ -451,14 +451,14 @@ static void brcmf_op_if(struct brcmf_if=20 +diff --git a/drivers/staging/brcm80211/brcmfmac/dhd_linux.c b/drivers/st= aging/brcm80211/brcmfmac/dhd_linux.c +index 05dada9..96171c6 100644 +--- a/drivers/staging/brcm80211/brcmfmac/dhd_linux.c ++++ b/drivers/staging/brcm80211/brcmfmac/dhd_linux.c +@@ -451,14 +451,14 @@ static void brcmf_op_if(struct brcmf_if *ifp) free_netdev(ifp->net); } /* Allocate etherdev, including space for private structure */ @@ -35649,7 +36642,7 @@ diff -urNp linux-3.1.4/drivers/staging/brcm80211/= brcmfmac/dhd_linux.c linux-3.1. err =3D brcmf_net_attach(&drvr_priv->pub, ifp->idx); if (err !=3D 0) { BRCMF_ERROR(("%s: brcmf_net_attach failed, " -@@ -1279,7 +1279,7 @@ struct brcmf_pub *brcmf_attach(struct br +@@ -1279,7 +1279,7 @@ struct brcmf_pub *brcmf_attach(struct brcmf_bus *b= us, uint bus_hdrlen) BRCMF_TRACE(("%s: Enter\n", __func__)); =20 /* Allocate etherdev, including space for private structure */ @@ -35658,7 +36651,7 @@ diff -urNp linux-3.1.4/drivers/staging/brcm80211/= brcmfmac/dhd_linux.c linux-3.1. if (!net) { BRCMF_ERROR(("%s: OOM - alloc_etherdev\n", __func__)); goto fail; -@@ -1295,7 +1295,7 @@ struct brcmf_pub *brcmf_attach(struct br +@@ -1295,7 +1295,7 @@ struct brcmf_pub *brcmf_attach(struct brcmf_bus *b= us, uint bus_hdrlen) /* * Save the brcmf_info into the priv */ @@ -35667,7 +36660,7 @@ diff -urNp linux-3.1.4/drivers/staging/brcm80211/= brcmfmac/dhd_linux.c linux-3.1. =20 /* Set network interface name if it was provided as module parameter *= / if (iface_name[0]) { -@@ -1352,7 +1352,7 @@ struct brcmf_pub *brcmf_attach(struct br +@@ -1352,7 +1352,7 @@ struct brcmf_pub *brcmf_attach(struct brcmf_bus *b= us, uint bus_hdrlen) /* * Save the brcmf_info into the priv */ @@ -35676,9 +36669,10 @@ diff -urNp linux-3.1.4/drivers/staging/brcm80211= /brcmfmac/dhd_linux.c linux-3.1. =20 #if defined(CONFIG_PM_SLEEP) atomic_set(&brcmf_mmc_suspend, false); -diff -urNp linux-3.1.4/drivers/staging/brcm80211/brcmfmac/sdio_host.h li= nux-3.1.4/drivers/staging/brcm80211/brcmfmac/sdio_host.h ---- linux-3.1.4/drivers/staging/brcm80211/brcmfmac/sdio_host.h 2011-11-1= 1 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/staging/brcm80211/brcmfmac/sdio_host.h 2011-11-1= 6 18:39:07.000000000 -0500 +diff --git a/drivers/staging/brcm80211/brcmfmac/sdio_host.h b/drivers/st= aging/brcm80211/brcmfmac/sdio_host.h +index d345472..cedb19e 100644 +--- a/drivers/staging/brcm80211/brcmfmac/sdio_host.h ++++ b/drivers/staging/brcm80211/brcmfmac/sdio_host.h @@ -263,7 +263,7 @@ struct brcmf_sdioh_driver { u16 func, uint bustype, u32 regsva, void *param); /* detach from device */ @@ -35688,9 +36682,10 @@ diff -urNp linux-3.1.4/drivers/staging/brcm80211= /brcmfmac/sdio_host.h linux-3.1. =20 struct sdioh_info; =20 -diff -urNp linux-3.1.4/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h = linux-3.1.4/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h ---- linux-3.1.4/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h 2011-11= -11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h 2011-11= -16 18:39:07.000000000 -0500 +diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h b/drivers/= staging/brcm80211/brcmsmac/phy/phy_int.h +index a01b01c..b3f721c 100644 +--- a/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h ++++ b/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h @@ -591,7 +591,7 @@ struct phy_func_ptr { initfn_t carrsuppr; rxsigpwrfn_t rxsigpwr; @@ -35700,10 +36695,11 @@ diff -urNp linux-3.1.4/drivers/staging/brcm8021= 1/brcmsmac/phy/phy_int.h linux-3. =20 struct brcms_phy { struct brcms_phy_pub pubpi_ro; -diff -urNp linux-3.1.4/drivers/staging/et131x/et1310_tx.c linux-3.1.4/dr= ivers/staging/et131x/et1310_tx.c ---- linux-3.1.4/drivers/staging/et131x/et1310_tx.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/staging/et131x/et1310_tx.c 2011-11-16 18:39:07.0= 00000000 -0500 -@@ -635,11 +635,11 @@ inline void et131x_free_send_packet(stru +diff --git a/drivers/staging/et131x/et1310_tx.c b/drivers/staging/et131x= /et1310_tx.c +index 8fb3051..a8b6c67 100644 +--- a/drivers/staging/et131x/et1310_tx.c ++++ b/drivers/staging/et131x/et1310_tx.c +@@ -635,11 +635,11 @@ inline void et131x_free_send_packet(struct et131x_= adapter *etdev, struct net_device_stats *stats =3D &etdev->net_stats; =20 if (tcb->flags & fMP_DEST_BROAD) @@ -35718,9 +36714,10 @@ diff -urNp linux-3.1.4/drivers/staging/et131x/et= 1310_tx.c linux-3.1.4/drivers/st =20 if (tcb->skb) { stats->tx_bytes +=3D tcb->skb->len; -diff -urNp linux-3.1.4/drivers/staging/et131x/et131x_adapter.h linux-3.1= .4/drivers/staging/et131x/et131x_adapter.h ---- linux-3.1.4/drivers/staging/et131x/et131x_adapter.h 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/drivers/staging/et131x/et131x_adapter.h 2011-11-16 18:39= :07.000000000 -0500 +diff --git a/drivers/staging/et131x/et131x_adapter.h b/drivers/staging/e= t131x/et131x_adapter.h +index 408c50b..fd65e9f 100644 +--- a/drivers/staging/et131x/et131x_adapter.h ++++ b/drivers/staging/et131x/et131x_adapter.h @@ -106,11 +106,11 @@ struct ce_stats { * operations */ @@ -35736,10 +36733,11 @@ diff -urNp linux-3.1.4/drivers/staging/et131x/e= t131x_adapter.h linux-3.1.4/drive u32 norcvbuf; /* # Rx packets discarded */ u32 noxmtbuf; /* # Tx packets discarded */ =20 -diff -urNp linux-3.1.4/drivers/staging/hv/channel.c linux-3.1.4/drivers/= staging/hv/channel.c ---- linux-3.1.4/drivers/staging/hv/channel.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/staging/hv/channel.c 2011-11-16 18:39:07.0000000= 00 -0500 -@@ -447,8 +447,8 @@ int vmbus_establish_gpadl(struct vmbus_c +diff --git a/drivers/staging/hv/channel.c b/drivers/staging/hv/channel.c +index 455f47a..86205ff 100644 +--- a/drivers/staging/hv/channel.c ++++ b/drivers/staging/hv/channel.c +@@ -447,8 +447,8 @@ int vmbus_establish_gpadl(struct vmbus_channel *chan= nel, void *kbuffer, int ret =3D 0; int t; =20 @@ -35750,10 +36748,11 @@ diff -urNp linux-3.1.4/drivers/staging/hv/chann= el.c linux-3.1.4/drivers/staging/ =20 ret =3D create_gpadl_header(kbuffer, size, &msginfo, &msgcount); if (ret) -diff -urNp linux-3.1.4/drivers/staging/hv/hv.c linux-3.1.4/drivers/stagi= ng/hv/hv.c ---- linux-3.1.4/drivers/staging/hv/hv.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/staging/hv/hv.c 2011-11-16 18:39:07.000000000 -0= 500 -@@ -132,7 +132,7 @@ static u64 do_hypercall(u64 control, voi +diff --git a/drivers/staging/hv/hv.c b/drivers/staging/hv/hv.c +index 824f816..a800af7 100644 +--- a/drivers/staging/hv/hv.c ++++ b/drivers/staging/hv/hv.c +@@ -132,7 +132,7 @@ static u64 do_hypercall(u64 control, void *input, vo= id *output) u64 output_address =3D (output) ? virt_to_phys(output) : 0; u32 output_address_hi =3D output_address >> 32; u32 output_address_lo =3D output_address & 0xFFFFFFFF; @@ -35762,10 +36761,11 @@ diff -urNp linux-3.1.4/drivers/staging/hv/hv.c = linux-3.1.4/drivers/staging/hv/hv =20 __asm__ __volatile__ ("call *%8" : "=3Dd"(hv_status_hi), "=3Da"(hv_status_lo) : "d" (control_hi), -diff -urNp linux-3.1.4/drivers/staging/hv/hv_mouse.c linux-3.1.4/drivers= /staging/hv/hv_mouse.c ---- linux-3.1.4/drivers/staging/hv/hv_mouse.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/staging/hv/hv_mouse.c 2011-11-16 18:39:07.000000= 000 -0500 -@@ -878,8 +878,10 @@ static void reportdesc_callback(struct h +diff --git a/drivers/staging/hv/hv_mouse.c b/drivers/staging/hv/hv_mouse= .c +index d957fc2..43cedd9 100644 +--- a/drivers/staging/hv/hv_mouse.c ++++ b/drivers/staging/hv/hv_mouse.c +@@ -878,8 +878,10 @@ static void reportdesc_callback(struct hv_device *d= ev, void *packet, u32 len) if (hid_dev) { DPRINT_INFO(INPUTVSC_DRV, "hid_device created"); =20 @@ -35778,9 +36778,10 @@ diff -urNp linux-3.1.4/drivers/staging/hv/hv_mou= se.c linux-3.1.4/drivers/staging =20 hid_dev->bus =3D BUS_VIRTUAL; hid_dev->vendor =3D input_device_ctx->device_info.vendor; -diff -urNp linux-3.1.4/drivers/staging/hv/hyperv_vmbus.h linux-3.1.4/dri= vers/staging/hv/hyperv_vmbus.h ---- linux-3.1.4/drivers/staging/hv/hyperv_vmbus.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/staging/hv/hyperv_vmbus.h 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/drivers/staging/hv/hyperv_vmbus.h b/drivers/staging/hv/hype= rv_vmbus.h +index 349ad80..3f75719 100644 +--- a/drivers/staging/hv/hyperv_vmbus.h ++++ b/drivers/staging/hv/hyperv_vmbus.h @@ -559,7 +559,7 @@ enum vmbus_connect_state { struct vmbus_connection { enum vmbus_connect_state conn_state; @@ -35790,9 +36791,10 @@ diff -urNp linux-3.1.4/drivers/staging/hv/hyperv= _vmbus.h linux-3.1.4/drivers/sta =20 /* * Represents channel interrupts. Each bit position represents a -diff -urNp linux-3.1.4/drivers/staging/hv/rndis_filter.c linux-3.1.4/dri= vers/staging/hv/rndis_filter.c ---- linux-3.1.4/drivers/staging/hv/rndis_filter.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/staging/hv/rndis_filter.c 2011-11-16 18:39:07.00= 0000000 -0500 +diff --git a/drivers/staging/hv/rndis_filter.c b/drivers/staging/hv/rndi= s_filter.c +index dbb5201..d6047c6 100644 +--- a/drivers/staging/hv/rndis_filter.c ++++ b/drivers/staging/hv/rndis_filter.c @@ -43,7 +43,7 @@ struct rndis_device { =20 enum rndis_device_state state; @@ -35802,7 +36804,7 @@ diff -urNp linux-3.1.4/drivers/staging/hv/rndis_f= ilter.c linux-3.1.4/drivers/sta =20 spinlock_t request_lock; struct list_head req_list; -@@ -117,7 +117,7 @@ static struct rndis_request *get_rndis_r +@@ -117,7 +117,7 @@ static struct rndis_request *get_rndis_request(struc= t rndis_device *dev, * template */ set =3D &rndis_msg->msg.set_req; @@ -35811,7 +36813,7 @@ diff -urNp linux-3.1.4/drivers/staging/hv/rndis_f= ilter.c linux-3.1.4/drivers/sta =20 /* Add to the request list */ spin_lock_irqsave(&dev->request_lock, flags); -@@ -622,7 +622,7 @@ static void rndis_filter_halt_device(str +@@ -622,7 +622,7 @@ static void rndis_filter_halt_device(struct rndis_de= vice *dev) =20 /* Setup the rndis set */ halt =3D &request->request_msg.msg.halt_req; @@ -35820,10 +36822,11 @@ diff -urNp linux-3.1.4/drivers/staging/hv/rndis= _filter.c linux-3.1.4/drivers/sta =20 /* Ignore return since this msg is optional. */ rndis_filter_send_request(dev, request); -diff -urNp linux-3.1.4/drivers/staging/hv/vmbus_drv.c linux-3.1.4/driver= s/staging/hv/vmbus_drv.c ---- linux-3.1.4/drivers/staging/hv/vmbus_drv.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/staging/hv/vmbus_drv.c 2011-11-16 18:39:07.00000= 0000 -0500 -@@ -660,11 +660,11 @@ int vmbus_child_device_register(struct h +diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_d= rv.c +index 1c949f5..7a8b104 100644 +--- a/drivers/staging/hv/vmbus_drv.c ++++ b/drivers/staging/hv/vmbus_drv.c +@@ -660,11 +660,11 @@ int vmbus_child_device_register(struct hv_device *= child_device_obj) { int ret =3D 0; =20 @@ -35837,9 +36840,10 @@ diff -urNp linux-3.1.4/drivers/staging/hv/vmbus_= drv.c linux-3.1.4/drivers/stagin =20 /* The new device belongs to this bus */ child_device_obj->device.bus =3D &hv_bus; /* device->dev.bus; */ -diff -urNp linux-3.1.4/drivers/staging/iio/ring_generic.h linux-3.1.4/dr= ivers/staging/iio/ring_generic.h ---- linux-3.1.4/drivers/staging/iio/ring_generic.h 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/staging/iio/ring_generic.h 2011-11-16 18:39:07.0= 00000000 -0500 +diff --git a/drivers/staging/iio/ring_generic.h b/drivers/staging/iio/ri= ng_generic.h +index 3f26f71..fb5c787 100644 +--- a/drivers/staging/iio/ring_generic.h ++++ b/drivers/staging/iio/ring_generic.h @@ -62,7 +62,7 @@ struct iio_ring_access_funcs { =20 int (*is_enabled)(struct iio_ring_buffer *ring); @@ -35849,10 +36853,11 @@ diff -urNp linux-3.1.4/drivers/staging/iio/ring= _generic.h linux-3.1.4/drivers/st =20 struct iio_ring_setup_ops { int (*preenable)(struct iio_dev *); -diff -urNp linux-3.1.4/drivers/staging/mei/interface.c linux-3.1.4/drive= rs/staging/mei/interface.c ---- linux-3.1.4/drivers/staging/mei/interface.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/staging/mei/interface.c 2011-11-17 18:39:18.0000= 00000 -0500 -@@ -332,7 +332,7 @@ int mei_send_flow_control(struct mei_dev +diff --git a/drivers/staging/mei/interface.c b/drivers/staging/mei/inter= face.c +index cfec92d..a65dacf 100644 +--- a/drivers/staging/mei/interface.c ++++ b/drivers/staging/mei/interface.c +@@ -332,7 +332,7 @@ int mei_send_flow_control(struct mei_device *dev, st= ruct mei_cl *cl) mei_hdr->reserved =3D 0; =20 mei_flow_control =3D (struct hbm_flow_control *) &dev->wr_msg_buf[1]; @@ -35861,7 +36866,7 @@ diff -urNp linux-3.1.4/drivers/staging/mei/interf= ace.c linux-3.1.4/drivers/stagi mei_flow_control->host_addr =3D cl->host_client_id; mei_flow_control->me_addr =3D cl->me_client_id; mei_flow_control->cmd.cmd =3D MEI_FLOW_CONTROL_CMD; -@@ -396,7 +396,7 @@ int mei_disconnect(struct mei_device *de +@@ -396,7 +396,7 @@ int mei_disconnect(struct mei_device *dev, struct me= i_cl *cl) =20 mei_cli_disconnect =3D (struct hbm_client_disconnect_request *) &dev->wr_msg_buf[1]; @@ -35870,29 +36875,11 @@ diff -urNp linux-3.1.4/drivers/staging/mei/inte= rface.c linux-3.1.4/drivers/stagi mei_cli_disconnect->host_addr =3D cl->host_client_id; mei_cli_disconnect->me_addr =3D cl->me_client_id; mei_cli_disconnect->cmd.cmd =3D CLIENT_DISCONNECT_REQ_CMD; -diff -urNp linux-3.1.4/drivers/staging/octeon/ethernet.c linux-3.1.4/dri= vers/staging/octeon/ethernet.c ---- linux-3.1.4/drivers/staging/octeon/ethernet.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/staging/octeon/ethernet.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -258,11 +258,11 @@ static struct net_device_stats *cvm_oct_ - * since the RX tasklet also increments it. - */ - #ifdef CONFIG_64BIT -- atomic64_add(rx_status.dropped_packets, -- (atomic64_t *)&priv->stats.rx_dropped); -+ atomic64_add_unchecked(rx_status.dropped_packets, -+ (atomic64_unchecked_t *)&priv->stats.rx_dropped); - #else -- atomic_add(rx_status.dropped_packets, -- (atomic_t *)&priv->stats.rx_dropped); -+ atomic_add_unchecked(rx_status.dropped_packets, -+ (atomic_unchecked_t *)&priv->stats.rx_dropped); - #endif - } -=20 -diff -urNp linux-3.1.4/drivers/staging/octeon/ethernet-rx.c linux-3.1.4/= drivers/staging/octeon/ethernet-rx.c ---- linux-3.1.4/drivers/staging/octeon/ethernet-rx.c 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/staging/octeon/ethernet-rx.c 2011-11-16 18:39:07= .000000000 -0500 -@@ -420,11 +420,11 @@ static int cvm_oct_napi_poll(struct napi +diff --git a/drivers/staging/octeon/ethernet-rx.c b/drivers/staging/octe= on/ethernet-rx.c +index 8b307b4..a97ac91 100644 +--- a/drivers/staging/octeon/ethernet-rx.c ++++ b/drivers/staging/octeon/ethernet-rx.c +@@ -420,11 +420,11 @@ static int cvm_oct_napi_poll(struct napi_struct *n= api, int budget) /* Increment RX stats for virtual ports */ if (work->ipprt >=3D CVMX_PIP_NUM_INPUT_PORTS) { #ifdef CONFIG_64BIT @@ -35908,7 +36895,7 @@ diff -urNp linux-3.1.4/drivers/staging/octeon/eth= ernet-rx.c linux-3.1.4/drivers/ #endif } netif_receive_skb(skb); -@@ -436,9 +436,9 @@ static int cvm_oct_napi_poll(struct napi +@@ -436,9 +436,9 @@ static int cvm_oct_napi_poll(struct napi_struct *nap= i, int budget) dev->name); */ #ifdef CONFIG_64BIT @@ -35920,10 +36907,31 @@ diff -urNp linux-3.1.4/drivers/staging/octeon/e= thernet-rx.c linux-3.1.4/drivers/ #endif dev_kfree_skb_irq(skb); } -diff -urNp linux-3.1.4/drivers/staging/pohmelfs/inode.c linux-3.1.4/driv= ers/staging/pohmelfs/inode.c ---- linux-3.1.4/drivers/staging/pohmelfs/inode.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/staging/pohmelfs/inode.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -1861,7 +1861,7 @@ static int pohmelfs_fill_super(struct su +diff --git a/drivers/staging/octeon/ethernet.c b/drivers/staging/octeon/= ethernet.c +index a8f780e..aef1098 100644 +--- a/drivers/staging/octeon/ethernet.c ++++ b/drivers/staging/octeon/ethernet.c +@@ -258,11 +258,11 @@ static struct net_device_stats *cvm_oct_common_get= _stats(struct net_device *dev) + * since the RX tasklet also increments it. + */ + #ifdef CONFIG_64BIT +- atomic64_add(rx_status.dropped_packets, +- (atomic64_t *)&priv->stats.rx_dropped); ++ atomic64_add_unchecked(rx_status.dropped_packets, ++ (atomic64_unchecked_t *)&priv->stats.rx_dropped); + #else +- atomic_add(rx_status.dropped_packets, +- (atomic_t *)&priv->stats.rx_dropped); ++ atomic_add_unchecked(rx_status.dropped_packets, ++ (atomic_unchecked_t *)&priv->stats.rx_dropped); + #endif + } +=20 +diff --git a/drivers/staging/pohmelfs/inode.c b/drivers/staging/pohmelfs= /inode.c +index f3c6060..56bf826 100644 +--- a/drivers/staging/pohmelfs/inode.c ++++ b/drivers/staging/pohmelfs/inode.c +@@ -1861,7 +1861,7 @@ static int pohmelfs_fill_super(struct super_block = *sb, void *data, int silent) mutex_init(&psb->mcache_lock); psb->mcache_root =3D RB_ROOT; psb->mcache_timeout =3D msecs_to_jiffies(5000); @@ -35932,7 +36940,7 @@ diff -urNp linux-3.1.4/drivers/staging/pohmelfs/i= node.c linux-3.1.4/drivers/stag =20 psb->trans_max_pages =3D 100; =20 -@@ -1876,7 +1876,7 @@ static int pohmelfs_fill_super(struct su +@@ -1876,7 +1876,7 @@ static int pohmelfs_fill_super(struct super_block = *sb, void *data, int silent) INIT_LIST_HEAD(&psb->crypto_ready_list); INIT_LIST_HEAD(&psb->crypto_active_list); =20 @@ -35941,10 +36949,11 @@ diff -urNp linux-3.1.4/drivers/staging/pohmelfs= /inode.c linux-3.1.4/drivers/stag atomic_long_set(&psb->total_inodes, 0); =20 mutex_init(&psb->state_lock); -diff -urNp linux-3.1.4/drivers/staging/pohmelfs/mcache.c linux-3.1.4/dri= vers/staging/pohmelfs/mcache.c ---- linux-3.1.4/drivers/staging/pohmelfs/mcache.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/staging/pohmelfs/mcache.c 2011-11-16 18:39:07.00= 0000000 -0500 -@@ -121,7 +121,7 @@ struct pohmelfs_mcache *pohmelfs_mcache_ +diff --git a/drivers/staging/pohmelfs/mcache.c b/drivers/staging/pohmelf= s/mcache.c +index e22665c..a2a9390 100644 +--- a/drivers/staging/pohmelfs/mcache.c ++++ b/drivers/staging/pohmelfs/mcache.c +@@ -121,7 +121,7 @@ struct pohmelfs_mcache *pohmelfs_mcache_alloc(struct= pohmelfs_sb *psb, u64 start m->data =3D data; m->start =3D start; m->size =3D size; @@ -35953,9 +36962,10 @@ diff -urNp linux-3.1.4/drivers/staging/pohmelfs/= mcache.c linux-3.1.4/drivers/sta =20 mutex_lock(&psb->mcache_lock); err =3D pohmelfs_mcache_insert(psb, m); -diff -urNp linux-3.1.4/drivers/staging/pohmelfs/netfs.h linux-3.1.4/driv= ers/staging/pohmelfs/netfs.h ---- linux-3.1.4/drivers/staging/pohmelfs/netfs.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/staging/pohmelfs/netfs.h 2011-11-16 18:39:07.000= 000000 -0500 +diff --git a/drivers/staging/pohmelfs/netfs.h b/drivers/staging/pohmelfs= /netfs.h +index 985b6b7..7699e05 100644 +--- a/drivers/staging/pohmelfs/netfs.h ++++ b/drivers/staging/pohmelfs/netfs.h @@ -571,14 +571,14 @@ struct pohmelfs_config; struct pohmelfs_sb { struct rb_root mcache_root; @@ -35973,10 +36983,11 @@ diff -urNp linux-3.1.4/drivers/staging/pohmelfs= /netfs.h linux-3.1.4/drivers/stag =20 unsigned int crypto_attached_size; unsigned int crypto_align_size; -diff -urNp linux-3.1.4/drivers/staging/pohmelfs/trans.c linux-3.1.4/driv= ers/staging/pohmelfs/trans.c ---- linux-3.1.4/drivers/staging/pohmelfs/trans.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/staging/pohmelfs/trans.c 2011-11-16 18:39:07.000= 000000 -0500 -@@ -492,7 +492,7 @@ int netfs_trans_finish(struct netfs_tran +diff --git a/drivers/staging/pohmelfs/trans.c b/drivers/staging/pohmelfs= /trans.c +index 36a2535..0591bf4 100644 +--- a/drivers/staging/pohmelfs/trans.c ++++ b/drivers/staging/pohmelfs/trans.c +@@ -492,7 +492,7 @@ int netfs_trans_finish(struct netfs_trans *t, struct= pohmelfs_sb *psb) int err; struct netfs_cmd *cmd =3D t->iovec.iov_base; =20 @@ -35985,9 +36996,10 @@ diff -urNp linux-3.1.4/drivers/staging/pohmelfs/= trans.c linux-3.1.4/drivers/stag =20 cmd->size =3D t->iovec.iov_len - sizeof(struct netfs_cmd) + t->attached_size + t->attached_pages * sizeof(struct netfs_cmd); -diff -urNp linux-3.1.4/drivers/staging/rtl8712/rtl871x_io.h linux-3.1.4/= drivers/staging/rtl8712/rtl871x_io.h ---- linux-3.1.4/drivers/staging/rtl8712/rtl871x_io.h 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/staging/rtl8712/rtl871x_io.h 2011-11-16 18:39:07= .000000000 -0500 +diff --git a/drivers/staging/rtl8712/rtl871x_io.h b/drivers/staging/rtl8= 712/rtl871x_io.h +index b70cb2b..4db41a7 100644 +--- a/drivers/staging/rtl8712/rtl871x_io.h ++++ b/drivers/staging/rtl8712/rtl871x_io.h @@ -83,7 +83,7 @@ struct _io_ops { u8 *pmem); u32 (*_write_port)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, @@ -35997,10 +37009,11 @@ diff -urNp linux-3.1.4/drivers/staging/rtl8712/= rtl871x_io.h linux-3.1.4/drivers/ =20 struct io_req { struct list_head list; -diff -urNp linux-3.1.4/drivers/staging/sbe-2t3e3/netdev.c linux-3.1.4/dr= ivers/staging/sbe-2t3e3/netdev.c ---- linux-3.1.4/drivers/staging/sbe-2t3e3/netdev.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/drivers/staging/sbe-2t3e3/netdev.c 2011-11-16 18:39:08.0= 00000000 -0500 -@@ -51,7 +51,7 @@ int t3e3_ioctl(struct net_device *dev, s +diff --git a/drivers/staging/sbe-2t3e3/netdev.c b/drivers/staging/sbe-2t= 3e3/netdev.c +index c7b5e8b..783d6cb 100644 +--- a/drivers/staging/sbe-2t3e3/netdev.c ++++ b/drivers/staging/sbe-2t3e3/netdev.c +@@ -51,7 +51,7 @@ int t3e3_ioctl(struct net_device *dev, struct ifreq *i= fr, int cmd) t3e3_if_config(sc, cmd_2t3e3, (char *)¶m, &resp, &rlen); =20 if (rlen) @@ -36009,9 +37022,10 @@ diff -urNp linux-3.1.4/drivers/staging/sbe-2t3e3= /netdev.c linux-3.1.4/drivers/st return -EFAULT; =20 return 0; -diff -urNp linux-3.1.4/drivers/staging/usbip/usbip_common.h linux-3.1.4/= drivers/staging/usbip/usbip_common.h ---- linux-3.1.4/drivers/staging/usbip/usbip_common.h 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/staging/usbip/usbip_common.h 2011-11-16 18:39:08= .000000000 -0500 +diff --git a/drivers/staging/usbip/usbip_common.h b/drivers/staging/usbi= p/usbip_common.h +index be21617..0954e45 100644 +--- a/drivers/staging/usbip/usbip_common.h ++++ b/drivers/staging/usbip/usbip_common.h @@ -289,7 +289,7 @@ struct usbip_device { void (*shutdown)(struct usbip_device *); void (*reset)(struct usbip_device *); @@ -36021,9 +37035,10 @@ diff -urNp linux-3.1.4/drivers/staging/usbip/usb= ip_common.h linux-3.1.4/drivers/ }; =20 #if 0 -diff -urNp linux-3.1.4/drivers/staging/usbip/vhci.h linux-3.1.4/drivers/= staging/usbip/vhci.h ---- linux-3.1.4/drivers/staging/usbip/vhci.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/staging/usbip/vhci.h 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/drivers/staging/usbip/vhci.h b/drivers/staging/usbip/vhci.h +index 71a586e..4d8a91a 100644 +--- a/drivers/staging/usbip/vhci.h ++++ b/drivers/staging/usbip/vhci.h @@ -85,7 +85,7 @@ struct vhci_hcd { unsigned resuming:1; unsigned long re_timeout; @@ -36033,9 +37048,10 @@ diff -urNp linux-3.1.4/drivers/staging/usbip/vhc= i.h linux-3.1.4/drivers/staging/ =20 /* * NOTE: -diff -urNp linux-3.1.4/drivers/staging/usbip/vhci_hcd.c linux-3.1.4/driv= ers/staging/usbip/vhci_hcd.c ---- linux-3.1.4/drivers/staging/usbip/vhci_hcd.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/staging/usbip/vhci_hcd.c 2011-11-16 18:39:08.000= 000000 -0500 +diff --git a/drivers/staging/usbip/vhci_hcd.c b/drivers/staging/usbip/vh= ci_hcd.c +index 2ee97e2..0420b86 100644 +--- a/drivers/staging/usbip/vhci_hcd.c ++++ b/drivers/staging/usbip/vhci_hcd.c @@ -527,7 +527,7 @@ static void vhci_tx_urb(struct urb *urb) return; } @@ -36045,7 +37061,7 @@ diff -urNp linux-3.1.4/drivers/staging/usbip/vhci= _hcd.c linux-3.1.4/drivers/stag if (priv->seqnum =3D=3D 0xffff) dev_info(&urb->dev->dev, "seqnum max\n"); =20 -@@ -779,7 +779,7 @@ static int vhci_urb_dequeue(struct usb_h +@@ -779,7 +779,7 @@ static int vhci_urb_dequeue(struct usb_hcd *hcd, str= uct urb *urb, int status) return -ENOMEM; } =20 @@ -36054,7 +37070,7 @@ diff -urNp linux-3.1.4/drivers/staging/usbip/vhci= _hcd.c linux-3.1.4/drivers/stag if (unlink->seqnum =3D=3D 0xffff) pr_info("seqnum max\n"); =20 -@@ -969,7 +969,7 @@ static int vhci_start(struct usb_hcd *hc +@@ -969,7 +969,7 @@ static int vhci_start(struct usb_hcd *hcd) vdev->rhport =3D rhport; } =20 @@ -36063,10 +37079,11 @@ diff -urNp linux-3.1.4/drivers/staging/usbip/vh= ci_hcd.c linux-3.1.4/drivers/stag spin_lock_init(&vhci->lock); =20 hcd->power_budget =3D 0; /* no limit */ -diff -urNp linux-3.1.4/drivers/staging/usbip/vhci_rx.c linux-3.1.4/drive= rs/staging/usbip/vhci_rx.c ---- linux-3.1.4/drivers/staging/usbip/vhci_rx.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/staging/usbip/vhci_rx.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -76,7 +76,7 @@ static void vhci_recv_ret_submit(struct=20 +diff --git a/drivers/staging/usbip/vhci_rx.c b/drivers/staging/usbip/vhc= i_rx.c +index 09c44ab..6692d83 100644 +--- a/drivers/staging/usbip/vhci_rx.c ++++ b/drivers/staging/usbip/vhci_rx.c +@@ -76,7 +76,7 @@ static void vhci_recv_ret_submit(struct vhci_device *v= dev, if (!urb) { pr_err("cannot find a urb of seqnum %u\n", pdu->base.seqnum); pr_info("max seqnum %d\n", @@ -36075,10 +37092,11 @@ diff -urNp linux-3.1.4/drivers/staging/usbip/vh= ci_rx.c linux-3.1.4/drivers/stagi usbip_event_add(ud, VDEV_EVENT_ERROR_TCP); return; } -diff -urNp linux-3.1.4/drivers/staging/vt6655/hostap.c linux-3.1.4/drive= rs/staging/vt6655/hostap.c ---- linux-3.1.4/drivers/staging/vt6655/hostap.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/staging/vt6655/hostap.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -79,14 +79,13 @@ static int msglevel =20 +diff --git a/drivers/staging/vt6655/hostap.c b/drivers/staging/vt6655/ho= stap.c +index 7735027..30eed13 100644 +--- a/drivers/staging/vt6655/hostap.c ++++ b/drivers/staging/vt6655/hostap.c +@@ -79,14 +79,13 @@ static int msglevel =3DMSG_L= EVEL_INFO; * */ =20 @@ -36095,7 +37113,7 @@ diff -urNp linux-3.1.4/drivers/staging/vt6655/hos= tap.c linux-3.1.4/drivers/stagi =20 DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "%s: Enabling hostapd mode\n", d= ev->name); =20 -@@ -98,6 +97,8 @@ static int hostap_enable_hostapd(PSDevic +@@ -98,6 +97,8 @@ static int hostap_enable_hostapd(PSDevice pDevice, int= rtnl_locked) *apdev_priv =3D *pDevice; memcpy(pDevice->apdev->dev_addr, dev->dev_addr, ETH_ALEN); =20 @@ -36104,10 +37122,11 @@ diff -urNp linux-3.1.4/drivers/staging/vt6655/h= ostap.c linux-3.1.4/drivers/stagi pDevice->apdev->netdev_ops =3D &apdev_netdev_ops; =20 pDevice->apdev->type =3D ARPHRD_IEEE80211; -diff -urNp linux-3.1.4/drivers/staging/vt6656/hostap.c linux-3.1.4/drive= rs/staging/vt6656/hostap.c ---- linux-3.1.4/drivers/staging/vt6656/hostap.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/staging/vt6656/hostap.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -80,14 +80,13 @@ static int msglevel =20 +diff --git a/drivers/staging/vt6656/hostap.c b/drivers/staging/vt6656/ho= stap.c +index 51b5adf..098e320 100644 +--- a/drivers/staging/vt6656/hostap.c ++++ b/drivers/staging/vt6656/hostap.c +@@ -80,14 +80,13 @@ static int msglevel =3DMSG_L= EVEL_INFO; * */ =20 @@ -36124,7 +37143,7 @@ diff -urNp linux-3.1.4/drivers/staging/vt6656/hos= tap.c linux-3.1.4/drivers/stagi =20 DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "%s: Enabling hostapd mode\n", d= ev->name); =20 -@@ -99,6 +98,8 @@ static int hostap_enable_hostapd(PSDevic +@@ -99,6 +98,8 @@ static int hostap_enable_hostapd(PSDevice pDevice, int= rtnl_locked) *apdev_priv =3D *pDevice; memcpy(pDevice->apdev->dev_addr, dev->dev_addr, ETH_ALEN); =20 @@ -36133,10 +37152,11 @@ diff -urNp linux-3.1.4/drivers/staging/vt6656/h= ostap.c linux-3.1.4/drivers/stagi pDevice->apdev->netdev_ops =3D &apdev_netdev_ops; =20 pDevice->apdev->type =3D ARPHRD_IEEE80211; -diff -urNp linux-3.1.4/drivers/staging/wlan-ng/hfa384x_usb.c linux-3.1.4= /drivers/staging/wlan-ng/hfa384x_usb.c ---- linux-3.1.4/drivers/staging/wlan-ng/hfa384x_usb.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/staging/wlan-ng/hfa384x_usb.c 2011-11-16 18:39:0= 8.000000000 -0500 -@@ -204,7 +204,7 @@ static void unlocked_usbctlx_complete(hf +diff --git a/drivers/staging/wlan-ng/hfa384x_usb.c b/drivers/staging/wla= n-ng/hfa384x_usb.c +index 7843dfd..3db105f 100644 +--- a/drivers/staging/wlan-ng/hfa384x_usb.c ++++ b/drivers/staging/wlan-ng/hfa384x_usb.c +@@ -204,7 +204,7 @@ static void unlocked_usbctlx_complete(hfa384x_t *hw,= hfa384x_usbctlx_t *ctlx); =20 struct usbctlx_completor { int (*complete) (struct usbctlx_completor *); @@ -36145,9 +37165,10 @@ diff -urNp linux-3.1.4/drivers/staging/wlan-ng/h= fa384x_usb.c linux-3.1.4/drivers =20 static int hfa384x_usbctlx_complete_sync(hfa384x_t *hw, -diff -urNp linux-3.1.4/drivers/staging/zcache/tmem.c linux-3.1.4/drivers= /staging/zcache/tmem.c ---- linux-3.1.4/drivers/staging/zcache/tmem.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/staging/zcache/tmem.c 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/drivers/staging/zcache/tmem.c b/drivers/staging/zcache/tmem= .c +index 1ca66ea..76f1343 100644 +--- a/drivers/staging/zcache/tmem.c ++++ b/drivers/staging/zcache/tmem.c @@ -39,7 +39,7 @@ * A tmem host implementation must use this function to register callba= cks * for memory allocation. @@ -36157,7 +37178,7 @@ diff -urNp linux-3.1.4/drivers/staging/zcache/tme= m.c linux-3.1.4/drivers/staging =20 static void tmem_objnode_tree_init(void); =20 -@@ -53,7 +53,7 @@ void tmem_register_hostops(struct tmem_h +@@ -53,7 +53,7 @@ void tmem_register_hostops(struct tmem_hostops *m) * A tmem host implementation must use this function to register * callbacks for a page-accessible memory (PAM) implementation */ @@ -36166,9 +37187,10 @@ diff -urNp linux-3.1.4/drivers/staging/zcache/tm= em.c linux-3.1.4/drivers/staging =20 void tmem_register_pamops(struct tmem_pamops *m) { -diff -urNp linux-3.1.4/drivers/staging/zcache/tmem.h linux-3.1.4/drivers= /staging/zcache/tmem.h ---- linux-3.1.4/drivers/staging/zcache/tmem.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/staging/zcache/tmem.h 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/drivers/staging/zcache/tmem.h b/drivers/staging/zcache/tmem= .h +index ed147c4..94fc3c6 100644 +--- a/drivers/staging/zcache/tmem.h ++++ b/drivers/staging/zcache/tmem.h @@ -180,6 +180,7 @@ struct tmem_pamops { void (*new_obj)(struct tmem_obj *); int (*replace_in_obj)(void *, struct tmem_obj *); @@ -36185,10 +37207,11 @@ diff -urNp linux-3.1.4/drivers/staging/zcache/t= mem.h linux-3.1.4/drivers/staging extern void tmem_register_hostops(struct tmem_hostops *m); =20 /* core tmem accessor functions */ -diff -urNp linux-3.1.4/drivers/target/iscsi/iscsi_target.c linux-3.1.4/d= rivers/target/iscsi/iscsi_target.c ---- linux-3.1.4/drivers/target/iscsi/iscsi_target.c 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/drivers/target/iscsi/iscsi_target.c 2011-11-16 18:39:08.= 000000000 -0500 -@@ -1368,7 +1368,7 @@ static int iscsit_handle_data_out(struct +diff --git a/drivers/target/iscsi/iscsi_target.c b/drivers/target/iscsi/= iscsi_target.c +index 26a5d8b..74434f8 100644 +--- a/drivers/target/iscsi/iscsi_target.c ++++ b/drivers/target/iscsi/iscsi_target.c +@@ -1368,7 +1368,7 @@ static int iscsit_handle_data_out(struct iscsi_con= n *conn, unsigned char *buf) * outstanding_r2ts reaches zero, go ahead and send the delayed * TASK_ABORTED status. */ @@ -36197,10 +37220,11 @@ diff -urNp linux-3.1.4/drivers/target/iscsi/isc= si_target.c linux-3.1.4/drivers/t if (hdr->flags & ISCSI_FLAG_CMD_FINAL) if (--cmd->outstanding_r2ts < 1) { iscsit_stop_dataout_timer(cmd); -diff -urNp linux-3.1.4/drivers/target/target_core_alua.c linux-3.1.4/dri= vers/target/target_core_alua.c ---- linux-3.1.4/drivers/target/target_core_alua.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/target/target_core_alua.c 2011-11-16 18:40:29.00= 0000000 -0500 -@@ -723,6 +723,8 @@ static int core_alua_update_tpg_primary_ +diff --git a/drivers/target/target_core_alua.c b/drivers/target/target_c= ore_alua.c +index 8badcb4..94c9ac6 100644 +--- a/drivers/target/target_core_alua.c ++++ b/drivers/target/target_core_alua.c +@@ -723,6 +723,8 @@ static int core_alua_update_tpg_primary_metadata( char path[ALUA_METADATA_PATH_LEN]; int len; =20 @@ -36209,7 +37233,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _alua.c linux-3.1.4/drivers/tar memset(path, 0, ALUA_METADATA_PATH_LEN); =20 len =3D snprintf(md_buf, tg_pt_gp->tg_pt_gp_md_buf_len, -@@ -986,6 +988,8 @@ static int core_alua_update_tpg_secondar +@@ -986,6 +988,8 @@ static int core_alua_update_tpg_secondary_metadata( char path[ALUA_METADATA_PATH_LEN], wwn[ALUA_SECONDARY_METADATA_WWN_LEN= ]; int len; =20 @@ -36218,10 +37242,11 @@ diff -urNp linux-3.1.4/drivers/target/target_co= re_alua.c linux-3.1.4/drivers/tar memset(path, 0, ALUA_METADATA_PATH_LEN); memset(wwn, 0, ALUA_SECONDARY_METADATA_WWN_LEN); =20 -diff -urNp linux-3.1.4/drivers/target/target_core_cdb.c linux-3.1.4/driv= ers/target/target_core_cdb.c ---- linux-3.1.4/drivers/target/target_core_cdb.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/target/target_core_cdb.c 2011-11-16 18:40:29.000= 000000 -0500 -@@ -933,6 +933,8 @@ target_emulate_modesense(struct se_cmd * +diff --git a/drivers/target/target_core_cdb.c b/drivers/target/target_co= re_cdb.c +index f04d4ef..7de212b 100644 +--- a/drivers/target/target_core_cdb.c ++++ b/drivers/target/target_core_cdb.c +@@ -933,6 +933,8 @@ target_emulate_modesense(struct se_cmd *cmd, int ten= ) int length =3D 0; unsigned char buf[SE_MODE_PAGE_BUF]; =20 @@ -36230,10 +37255,11 @@ diff -urNp linux-3.1.4/drivers/target/target_co= re_cdb.c linux-3.1.4/drivers/targ memset(buf, 0, SE_MODE_PAGE_BUF); =20 switch (cdb[2] & 0x3f) { -diff -urNp linux-3.1.4/drivers/target/target_core_configfs.c linux-3.1.4= /drivers/target/target_core_configfs.c ---- linux-3.1.4/drivers/target/target_core_configfs.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/drivers/target/target_core_configfs.c 2011-11-16 19:04:3= 7.000000000 -0500 -@@ -1267,6 +1267,8 @@ static ssize_t target_core_dev_pr_show_a +diff --git a/drivers/target/target_core_configfs.c b/drivers/target/targ= et_core_configfs.c +index b2575d8..b6b28fd 100644 +--- a/drivers/target/target_core_configfs.c ++++ b/drivers/target/target_core_configfs.c +@@ -1267,6 +1267,8 @@ static ssize_t target_core_dev_pr_show_attr_res_pr= _registered_i_pts( ssize_t len =3D 0; int reg_count =3D 0, prf_isid; =20 @@ -36242,10 +37268,11 @@ diff -urNp linux-3.1.4/drivers/target/target_co= re_configfs.c linux-3.1.4/drivers if (!su_dev->se_dev_ptr) return -ENODEV; =20 -diff -urNp linux-3.1.4/drivers/target/target_core_pr.c linux-3.1.4/drive= rs/target/target_core_pr.c ---- linux-3.1.4/drivers/target/target_core_pr.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/target/target_core_pr.c 2011-11-16 18:40:29.0000= 00000 -0500 -@@ -918,6 +918,8 @@ static int __core_scsi3_check_aptpl_regi +diff --git a/drivers/target/target_core_pr.c b/drivers/target/target_cor= e_pr.c +index 7fd3a16..bc2fb3e 100644 +--- a/drivers/target/target_core_pr.c ++++ b/drivers/target/target_core_pr.c +@@ -918,6 +918,8 @@ static int __core_scsi3_check_aptpl_registration( unsigned char t_port[PR_APTPL_MAX_TPORT_LEN]; u16 tpgt; =20 @@ -36254,7 +37281,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _pr.c linux-3.1.4/drivers/targe memset(i_port, 0, PR_APTPL_MAX_IPORT_LEN); memset(t_port, 0, PR_APTPL_MAX_TPORT_LEN); /* -@@ -1867,6 +1869,8 @@ static int __core_scsi3_update_aptpl_buf +@@ -1867,6 +1869,8 @@ static int __core_scsi3_update_aptpl_buf( ssize_t len =3D 0; int reg_count =3D 0; =20 @@ -36263,7 +37290,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _pr.c linux-3.1.4/drivers/targe memset(buf, 0, pr_aptpl_buf_len); /* * Called to clear metadata once APTPL has been deactivated. -@@ -1989,6 +1993,8 @@ static int __core_scsi3_write_aptpl_to_f +@@ -1989,6 +1993,8 @@ static int __core_scsi3_write_aptpl_to_file( char path[512]; int ret; =20 @@ -36272,9 +37299,10 @@ diff -urNp linux-3.1.4/drivers/target/target_cor= e_pr.c linux-3.1.4/drivers/targe memset(iov, 0, sizeof(struct iovec)); memset(path, 0, 512); =20 -diff -urNp linux-3.1.4/drivers/target/target_core_tmr.c linux-3.1.4/driv= ers/target/target_core_tmr.c ---- linux-3.1.4/drivers/target/target_core_tmr.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/target/target_core_tmr.c 2011-11-16 18:39:08.000= 000000 -0500 +diff --git a/drivers/target/target_core_tmr.c b/drivers/target/target_co= re_tmr.c +index 5c1b8c5..0cb7d0e 100644 +--- a/drivers/target/target_core_tmr.c ++++ b/drivers/target/target_core_tmr.c @@ -255,7 +255,7 @@ static void core_tmr_drain_task_list( cmd->se_tfo->get_task_tag(cmd), cmd->pr_res_key, cmd->t_task_list_num, @@ -36302,10 +37330,11 @@ diff -urNp linux-3.1.4/drivers/target/target_co= re_tmr.c linux-3.1.4/drivers/targ spin_unlock_irqrestore(&cmd->t_state_lock, flags); =20 core_tmr_handle_tas_abort(tmr_nacl, cmd, tas, fe_count); -diff -urNp linux-3.1.4/drivers/target/target_core_transport.c linux-3.1.= 4/drivers/target/target_core_transport.c ---- linux-3.1.4/drivers/target/target_core_transport.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/drivers/target/target_core_transport.c 2011-11-16 18:39:= 08.000000000 -0500 -@@ -1445,7 +1445,7 @@ struct se_device *transport_add_device_t +diff --git a/drivers/target/target_core_transport.c b/drivers/target/tar= get_core_transport.c +index 013c100..8fd2e57 100644 +--- a/drivers/target/target_core_transport.c ++++ b/drivers/target/target_core_transport.c +@@ -1445,7 +1445,7 @@ struct se_device *transport_add_device_to_core_hba= ( =20 dev->queue_depth =3D dev_limits->queue_depth; atomic_set(&dev->depth_left, dev->queue_depth); @@ -36314,7 +37343,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _transport.c linux-3.1.4/driver =20 se_dev_set_default_attribs(dev, dev_limits); =20 -@@ -1633,7 +1633,7 @@ static int transport_check_alloc_task_at +@@ -1633,7 +1633,7 @@ static int transport_check_alloc_task_attr(struct = se_cmd *cmd) * Used to determine when ORDERED commands should go from * Dormant to Active status. */ @@ -36323,7 +37352,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _transport.c linux-3.1.4/driver smp_mb__after_atomic_inc(); pr_debug("Allocated se_ordered_id: %u for Task Attr: 0x%02x on %s\n", cmd->se_ordered_id, cmd->sam_task_attr, -@@ -1960,7 +1960,7 @@ static void transport_generic_request_fa +@@ -1960,7 +1960,7 @@ static void transport_generic_request_failure( " t_transport_active: %d t_transport_stop: %d" " t_transport_sent: %d\n", cmd->t_task_list_num, atomic_read(&cmd->t_task_cdbs_left), @@ -36344,7 +37373,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _transport.c linux-3.1.4/driver cmd->t_task_list_num) atomic_set(&cmd->transport_sent, 1); =20 -@@ -4665,7 +4665,7 @@ static void transport_generic_wait_for_t +@@ -4665,7 +4665,7 @@ static void transport_generic_wait_for_tasks( atomic_set(&cmd->transport_lun_stop, 0); } if (!atomic_read(&cmd->t_transport_active) || @@ -36353,7 +37382,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _transport.c linux-3.1.4/driver goto remove; =20 atomic_set(&cmd->t_transport_stop, 1); -@@ -4900,7 +4900,7 @@ int transport_check_aborted_status(struc +@@ -4900,7 +4900,7 @@ int transport_check_aborted_status(struct se_cmd *= cmd, int send_status) { int ret =3D 0; =20 @@ -36362,7 +37391,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _transport.c linux-3.1.4/driver if (!send_status || (cmd->se_cmd_flags & SCF_SENT_DELAYED_TAS)) return 1; -@@ -4937,7 +4937,7 @@ void transport_send_task_abort(struct se +@@ -4937,7 +4937,7 @@ void transport_send_task_abort(struct se_cmd *cmd) */ if (cmd->data_direction =3D=3D DMA_TO_DEVICE) { if (cmd->se_tfo->write_pending_status(cmd) !=3D 0) { @@ -36371,7 +37400,7 @@ diff -urNp linux-3.1.4/drivers/target/target_core= _transport.c linux-3.1.4/driver smp_mb__after_atomic_inc(); cmd->scsi_status =3D SAM_STAT_TASK_ABORTED; transport_new_cmd_failure(cmd); -@@ -5051,7 +5051,7 @@ static void transport_processing_shutdow +@@ -5051,7 +5051,7 @@ static void transport_processing_shutdown(struct s= e_device *dev) cmd->se_tfo->get_task_tag(cmd), cmd->t_task_list_num, atomic_read(&cmd->t_task_cdbs_left), @@ -36380,9 +37409,10 @@ diff -urNp linux-3.1.4/drivers/target/target_cor= e_transport.c linux-3.1.4/driver atomic_read(&cmd->t_transport_active), atomic_read(&cmd->t_transport_stop), atomic_read(&cmd->t_transport_sent)); -diff -urNp linux-3.1.4/drivers/telephony/ixj.c linux-3.1.4/drivers/telep= hony/ixj.c ---- linux-3.1.4/drivers/telephony/ixj.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/telephony/ixj.c 2011-11-16 18:40:29.000000000 -0= 500 +diff --git a/drivers/telephony/ixj.c b/drivers/telephony/ixj.c +index d5f923b..9c78228 100644 +--- a/drivers/telephony/ixj.c ++++ b/drivers/telephony/ixj.c @@ -4976,6 +4976,8 @@ static int ixj_daa_cid_read(IXJ *j) bool mContinue; char *pIn, *pOut; @@ -36392,9 +37422,10 @@ diff -urNp linux-3.1.4/drivers/telephony/ixj.c l= inux-3.1.4/drivers/telephony/ixj if (!SCI_Prepare(j)) return 0; =20 -diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c linux-3.1.4/drivers/tty/hv= c/hvcs.c ---- linux-3.1.4/drivers/tty/hvc/hvcs.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/tty/hvc/hvcs.c 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/drivers/tty/hvc/hvcs.c b/drivers/tty/hvc/hvcs.c +index 4c8b665..1d931eb 100644 +--- a/drivers/tty/hvc/hvcs.c ++++ b/drivers/tty/hvc/hvcs.c @@ -83,6 +83,7 @@ #include #include @@ -36412,7 +37443,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c =20 /* * Used to tell the driver kernel_thread what operations need to take -@@ -422,7 +423,7 @@ static ssize_t hvcs_vterm_state_store(st +@@ -422,7 +423,7 @@ static ssize_t hvcs_vterm_state_store(struct device = *dev, struct device_attribut =20 spin_lock_irqsave(&hvcsd->lock, flags); =20 @@ -36421,7 +37452,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c spin_unlock_irqrestore(&hvcsd->lock, flags); printk(KERN_INFO "HVCS: vterm state unchanged. " "The hvcs device node is still in use.\n"); -@@ -1145,7 +1146,7 @@ static int hvcs_open(struct tty_struct * +@@ -1145,7 +1146,7 @@ static int hvcs_open(struct tty_struct *tty, struc= t file *filp) if ((retval =3D hvcs_partner_connect(hvcsd))) goto error_release; =20 @@ -36439,7 +37470,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c hvcsd->todo_mask |=3D HVCS_SCHED_READ; spin_unlock_irqrestore(&hvcsd->lock, flags); =20 -@@ -1223,7 +1224,7 @@ static void hvcs_close(struct tty_struct +@@ -1223,7 +1224,7 @@ static void hvcs_close(struct tty_struct *tty, str= uct file *filp) hvcsd =3D tty->driver_data; =20 spin_lock_irqsave(&hvcsd->lock, flags); @@ -36448,7 +37479,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c =20 vio_disable_interrupts(hvcsd->vdev); =20 -@@ -1249,10 +1250,10 @@ static void hvcs_close(struct tty_struct +@@ -1249,10 +1250,10 @@ static void hvcs_close(struct tty_struct *tty, s= truct file *filp) free_irq(irq, hvcsd); kref_put(&hvcsd->kref, destroy_hvcs_struct); return; @@ -36461,7 +37492,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c } =20 spin_unlock_irqrestore(&hvcsd->lock, flags); -@@ -1268,7 +1269,7 @@ static void hvcs_hangup(struct tty_struc +@@ -1268,7 +1269,7 @@ static void hvcs_hangup(struct tty_struct * tty) =20 spin_lock_irqsave(&hvcsd->lock, flags); /* Preserve this so that we know how many kref refs to put */ @@ -36470,7 +37501,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c =20 /* * Don't kref put inside the spinlock because the destruction -@@ -1283,7 +1284,7 @@ static void hvcs_hangup(struct tty_struc +@@ -1283,7 +1284,7 @@ static void hvcs_hangup(struct tty_struct * tty) hvcsd->tty->driver_data =3D NULL; hvcsd->tty =3D NULL; =20 @@ -36479,7 +37510,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c =20 /* This will drop any buffered data on the floor which is OK in a hang= up * scenario. */ -@@ -1354,7 +1355,7 @@ static int hvcs_write(struct tty_struct=20 +@@ -1354,7 +1355,7 @@ static int hvcs_write(struct tty_struct *tty, * the middle of a write operation? This is a crummy place to do this * but we want to keep it all in the spinlock. */ @@ -36488,7 +37519,7 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c lin= ux-3.1.4/drivers/tty/hvc/hvcs.c spin_unlock_irqrestore(&hvcsd->lock, flags); return -ENODEV; } -@@ -1428,7 +1429,7 @@ static int hvcs_write_room(struct tty_st +@@ -1428,7 +1429,7 @@ static int hvcs_write_room(struct tty_struct *tty) { struct hvcs_struct *hvcsd =3D tty->driver_data; =20 @@ -36497,9 +37528,10 @@ diff -urNp linux-3.1.4/drivers/tty/hvc/hvcs.c li= nux-3.1.4/drivers/tty/hvc/hvcs.c return 0; =20 return HVCS_BUFF_LEN - hvcsd->chars_in_buffer; -diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty.c linux-3.1.4/drivers/= tty/ipwireless/tty.c ---- linux-3.1.4/drivers/tty/ipwireless/tty.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/tty/ipwireless/tty.c 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/drivers/tty/ipwireless/tty.c b/drivers/tty/ipwireless/tty.c +index ef92869..f4ebd88 100644 +--- a/drivers/tty/ipwireless/tty.c ++++ b/drivers/tty/ipwireless/tty.c @@ -29,6 +29,7 @@ #include #include @@ -36517,7 +37549,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi unsigned int control_lines; struct mutex ipw_tty_mutex; int tx_bytes_queued; -@@ -127,10 +128,10 @@ static int ipw_open(struct tty_struct *l +@@ -127,10 +128,10 @@ static int ipw_open(struct tty_struct *linux_tty, = struct file *filp) mutex_unlock(&tty->ipw_tty_mutex); return -ENODEV; } @@ -36530,7 +37562,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi =20 tty->linux_tty =3D linux_tty; linux_tty->driver_data =3D tty; -@@ -146,9 +147,7 @@ static int ipw_open(struct tty_struct *l +@@ -146,9 +147,7 @@ static int ipw_open(struct tty_struct *linux_tty, st= ruct file *filp) =20 static void do_ipw_close(struct ipw_tty *tty) { @@ -36541,7 +37573,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi struct tty_struct *linux_tty =3D tty->linux_tty; =20 if (linux_tty !=3D NULL) { -@@ -169,7 +168,7 @@ static void ipw_hangup(struct tty_struct +@@ -169,7 +168,7 @@ static void ipw_hangup(struct tty_struct *linux_tty) return; =20 mutex_lock(&tty->ipw_tty_mutex); @@ -36550,7 +37582,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi mutex_unlock(&tty->ipw_tty_mutex); return; } -@@ -198,7 +197,7 @@ void ipwireless_tty_received(struct ipw_ +@@ -198,7 +197,7 @@ void ipwireless_tty_received(struct ipw_tty *tty, un= signed char *data, return; } =20 @@ -36559,7 +37591,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi mutex_unlock(&tty->ipw_tty_mutex); return; } -@@ -240,7 +239,7 @@ static int ipw_write(struct tty_struct * +@@ -240,7 +239,7 @@ static int ipw_write(struct tty_struct *linux_tty, return -ENODEV; =20 mutex_lock(&tty->ipw_tty_mutex); @@ -36568,7 +37600,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi mutex_unlock(&tty->ipw_tty_mutex); return -EINVAL; } -@@ -280,7 +279,7 @@ static int ipw_write_room(struct tty_str +@@ -280,7 +279,7 @@ static int ipw_write_room(struct tty_struct *linux_t= ty) if (!tty) return -ENODEV; =20 @@ -36577,7 +37609,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi return -EINVAL; =20 room =3D IPWIRELESS_TX_QUEUE_SIZE - tty->tx_bytes_queued; -@@ -322,7 +321,7 @@ static int ipw_chars_in_buffer(struct tt +@@ -322,7 +321,7 @@ static int ipw_chars_in_buffer(struct tty_struct *li= nux_tty) if (!tty) return 0; =20 @@ -36586,7 +37618,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi return 0; =20 return tty->tx_bytes_queued; -@@ -403,7 +402,7 @@ static int ipw_tiocmget(struct tty_struc +@@ -403,7 +402,7 @@ static int ipw_tiocmget(struct tty_struct *linux_tty= ) if (!tty) return -ENODEV; =20 @@ -36595,7 +37627,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi return -EINVAL; =20 return get_control_lines(tty); -@@ -419,7 +418,7 @@ ipw_tiocmset(struct tty_struct *linux_tt +@@ -419,7 +418,7 @@ ipw_tiocmset(struct tty_struct *linux_tty, if (!tty) return -ENODEV; =20 @@ -36604,7 +37636,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi return -EINVAL; =20 return set_control_lines(tty, set, clear); -@@ -433,7 +432,7 @@ static int ipw_ioctl(struct tty_struct * +@@ -433,7 +432,7 @@ static int ipw_ioctl(struct tty_struct *linux_tty, if (!tty) return -ENODEV; =20 @@ -36613,7 +37645,7 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/tty= .c linux-3.1.4/drivers/tty/ipwi return -EINVAL; =20 /* FIXME: Exactly how is the tty object locked here .. */ -@@ -582,7 +581,7 @@ void ipwireless_tty_free(struct ipw_tty=20 +@@ -582,7 +581,7 @@ void ipwireless_tty_free(struct ipw_tty *tty) against a parallel ioctl etc */ mutex_lock(&ttyj->ipw_tty_mutex); } @@ -36622,10 +37654,11 @@ diff -urNp linux-3.1.4/drivers/tty/ipwireless/t= ty.c linux-3.1.4/drivers/tty/ipwi do_ipw_close(ttyj); ipwireless_disassociate_network_ttys(network, ttyj->channel_idx); -diff -urNp linux-3.1.4/drivers/tty/n_gsm.c linux-3.1.4/drivers/tty/n_gsm= .c ---- linux-3.1.4/drivers/tty/n_gsm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/tty/n_gsm.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1625,7 +1625,7 @@ static struct gsm_dlci *gsm_dlci_alloc(s +diff --git a/drivers/tty/n_gsm.c b/drivers/tty/n_gsm.c +index 8a50e4e..7d9ca3d 100644 +--- a/drivers/tty/n_gsm.c ++++ b/drivers/tty/n_gsm.c +@@ -1625,7 +1625,7 @@ static struct gsm_dlci *gsm_dlci_alloc(struct gsm_= mux *gsm, int addr) kref_init(&dlci->ref); mutex_init(&dlci->mutex); dlci->fifo =3D &dlci->_fifo; @@ -36634,10 +37667,11 @@ diff -urNp linux-3.1.4/drivers/tty/n_gsm.c linu= x-3.1.4/drivers/tty/n_gsm.c kfree(dlci); return NULL; } -diff -urNp linux-3.1.4/drivers/tty/n_tty.c linux-3.1.4/drivers/tty/n_tty= .c ---- linux-3.1.4/drivers/tty/n_tty.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/tty/n_tty.c 2011-11-16 18:39:08.000000000 -0500 -@@ -2123,6 +2123,7 @@ void n_tty_inherit_ops(struct tty_ldisc_ +diff --git a/drivers/tty/n_tty.c b/drivers/tty/n_tty.c +index 39d6ab6..eb97f41 100644 +--- a/drivers/tty/n_tty.c ++++ b/drivers/tty/n_tty.c +@@ -2123,6 +2123,7 @@ void n_tty_inherit_ops(struct tty_ldisc_ops *ops) { *ops =3D tty_ldisc_N_TTY; ops->owner =3D NULL; @@ -36646,9 +37680,10 @@ diff -urNp linux-3.1.4/drivers/tty/n_tty.c linux= -3.1.4/drivers/tty/n_tty.c + ops->flags =3D 0; } EXPORT_SYMBOL_GPL(n_tty_inherit_ops); -diff -urNp linux-3.1.4/drivers/tty/pty.c linux-3.1.4/drivers/tty/pty.c ---- linux-3.1.4/drivers/tty/pty.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/tty/pty.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/drivers/tty/pty.c b/drivers/tty/pty.c +index e18604b..a7d5a11 100644 +--- a/drivers/tty/pty.c ++++ b/drivers/tty/pty.c @@ -773,8 +773,10 @@ static void __init unix98_pty_init(void) register_sysctl_table(pty_root_table); =20 @@ -36661,10 +37696,11 @@ diff -urNp linux-3.1.4/drivers/tty/pty.c linux-= 3.1.4/drivers/tty/pty.c =20 cdev_init(&ptmx_cdev, &ptmx_fops); if (cdev_add(&ptmx_cdev, MKDEV(TTYAUX_MAJOR, 2), 1) || -diff -urNp linux-3.1.4/drivers/tty/rocket.c linux-3.1.4/drivers/tty/rock= et.c ---- linux-3.1.4/drivers/tty/rocket.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/tty/rocket.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1277,6 +1277,8 @@ static int get_ports(struct r_port *info +diff --git a/drivers/tty/rocket.c b/drivers/tty/rocket.c +index 6a1241c..d04ab0d 100644 +--- a/drivers/tty/rocket.c ++++ b/drivers/tty/rocket.c +@@ -1277,6 +1277,8 @@ static int get_ports(struct r_port *info, struct r= ocket_ports __user *retports) struct rocket_ports tmp; int board; =20 @@ -36673,9 +37709,10 @@ diff -urNp linux-3.1.4/drivers/tty/rocket.c linu= x-3.1.4/drivers/tty/rocket.c if (!retports) return -EFAULT; memset(&tmp, 0, sizeof (tmp)); -diff -urNp linux-3.1.4/drivers/tty/serial/kgdboc.c linux-3.1.4/drivers/t= ty/serial/kgdboc.c ---- linux-3.1.4/drivers/tty/serial/kgdboc.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/drivers/tty/serial/kgdboc.c 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/drivers/tty/serial/kgdboc.c b/drivers/tty/serial/kgdboc.c +index 87e7e6c..89744e0 100644 +--- a/drivers/tty/serial/kgdboc.c ++++ b/drivers/tty/serial/kgdboc.c @@ -23,8 +23,9 @@ #define MAX_CONFIG_LEN 40 =20 @@ -36749,7 +37786,7 @@ diff -urNp linux-3.1.4/drivers/tty/serial/kgdboc.= c linux-3.1.4/drivers/tty/seria return 0; =20 return configure_kgdboc(); -@@ -261,7 +268,7 @@ static int param_set_kgdboc_var(const ch +@@ -261,7 +268,7 @@ static int param_set_kgdboc_var(const char *kmessage= , struct kernel_param *kp) if (config[len - 1] =3D=3D '\n') config[len - 1] =3D '\0'; =20 @@ -36774,10 +37811,11 @@ diff -urNp linux-3.1.4/drivers/tty/serial/kgdbo= c.c linux-3.1.4/drivers/tty/seria #ifdef CONFIG_KGDB_SERIAL_CONSOLE /* This is only available if kgdboc is a built in for early debugging *= / static int __init kgdboc_early_init(char *opt) -diff -urNp linux-3.1.4/drivers/tty/serial/mfd.c linux-3.1.4/drivers/tty/= serial/mfd.c ---- linux-3.1.4/drivers/tty/serial/mfd.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/tty/serial/mfd.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -1423,7 +1423,7 @@ static void serial_hsu_remove(struct pci +diff --git a/drivers/tty/serial/mfd.c b/drivers/tty/serial/mfd.c +index cab52f4..29fc6aa 100644 +--- a/drivers/tty/serial/mfd.c ++++ b/drivers/tty/serial/mfd.c +@@ -1423,7 +1423,7 @@ static void serial_hsu_remove(struct pci_dev *pdev= ) } =20 /* First 3 are UART ports, and the 4th is the DMA */ @@ -36786,10 +37824,11 @@ diff -urNp linux-3.1.4/drivers/tty/serial/mfd.c= linux-3.1.4/drivers/tty/serial/m { PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x081B) }, { PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x081C) }, { PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x081D) }, -diff -urNp linux-3.1.4/drivers/tty/serial/mrst_max3110.c linux-3.1.4/dri= vers/tty/serial/mrst_max3110.c ---- linux-3.1.4/drivers/tty/serial/mrst_max3110.c 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/drivers/tty/serial/mrst_max3110.c 2011-11-16 18:40:29.00= 0000000 -0500 -@@ -393,6 +393,8 @@ static void max3110_con_receive(struct u +diff --git a/drivers/tty/serial/mrst_max3110.c b/drivers/tty/serial/mrst= _max3110.c +index 23bc743..d425c07 100644 +--- a/drivers/tty/serial/mrst_max3110.c ++++ b/drivers/tty/serial/mrst_max3110.c +@@ -393,6 +393,8 @@ static void max3110_con_receive(struct uart_max3110 = *max) int loop =3D 1, num, total =3D 0; u8 recv_buf[512], *pbuf; =20 @@ -36798,9 +37837,10 @@ diff -urNp linux-3.1.4/drivers/tty/serial/mrst_m= ax3110.c linux-3.1.4/drivers/tty pbuf =3D recv_buf; do { num =3D max3110_read_multi(max, pbuf); -diff -urNp linux-3.1.4/drivers/tty/tty_io.c linux-3.1.4/drivers/tty/tty_= io.c ---- linux-3.1.4/drivers/tty/tty_io.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/tty/tty_io.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c +index 1a890e2..1d8139c 100644 +--- a/drivers/tty/tty_io.c ++++ b/drivers/tty/tty_io.c @@ -3238,7 +3238,7 @@ EXPORT_SYMBOL_GPL(get_current_tty); =20 void tty_default_fops(struct file_operations *fops) @@ -36810,10 +37850,11 @@ diff -urNp linux-3.1.4/drivers/tty/tty_io.c lin= ux-3.1.4/drivers/tty/tty_io.c } =20 /* -diff -urNp linux-3.1.4/drivers/tty/tty_ldisc.c linux-3.1.4/drivers/tty/t= ty_ldisc.c ---- linux-3.1.4/drivers/tty/tty_ldisc.c 2011-11-26 19:57:29.000000000 -0= 500 -+++ linux-3.1.4/drivers/tty/tty_ldisc.c 2011-11-26 20:00:43.000000000 -0= 500 -@@ -75,7 +75,7 @@ static void put_ldisc(struct tty_ldisc * +diff --git a/drivers/tty/tty_ldisc.c b/drivers/tty/tty_ldisc.c +index a76c808..ecbc743 100644 +--- a/drivers/tty/tty_ldisc.c ++++ b/drivers/tty/tty_ldisc.c +@@ -75,7 +75,7 @@ static void put_ldisc(struct tty_ldisc *ld) if (atomic_dec_and_lock(&ld->users, &tty_ldisc_lock)) { struct tty_ldisc_ops *ldo =3D ld->ops; =20 @@ -36822,7 +37863,7 @@ diff -urNp linux-3.1.4/drivers/tty/tty_ldisc.c li= nux-3.1.4/drivers/tty/tty_ldisc module_put(ldo->owner); spin_unlock_irqrestore(&tty_ldisc_lock, flags); =20 -@@ -110,7 +110,7 @@ int tty_register_ldisc(int disc, struct=20 +@@ -110,7 +110,7 @@ int tty_register_ldisc(int disc, struct tty_ldisc_op= s *new_ldisc) spin_lock_irqsave(&tty_ldisc_lock, flags); tty_ldiscs[disc] =3D new_ldisc; new_ldisc->num =3D disc; @@ -36840,7 +37881,7 @@ diff -urNp linux-3.1.4/drivers/tty/tty_ldisc.c li= nux-3.1.4/drivers/tty/tty_ldisc ret =3D -EBUSY; else tty_ldiscs[disc] =3D NULL; -@@ -159,7 +159,7 @@ static struct tty_ldisc_ops *get_ldops(i +@@ -159,7 +159,7 @@ static struct tty_ldisc_ops *get_ldops(int disc) if (ldops) { ret =3D ERR_PTR(-EAGAIN); if (try_module_get(ldops->owner)) { @@ -36849,7 +37890,7 @@ diff -urNp linux-3.1.4/drivers/tty/tty_ldisc.c li= nux-3.1.4/drivers/tty/tty_ldisc ret =3D ldops; } } -@@ -172,7 +172,7 @@ static void put_ldops(struct tty_ldisc_o +@@ -172,7 +172,7 @@ static void put_ldops(struct tty_ldisc_ops *ldops) unsigned long flags; =20 spin_lock_irqsave(&tty_ldisc_lock, flags); @@ -36858,10 +37899,11 @@ diff -urNp linux-3.1.4/drivers/tty/tty_ldisc.c = linux-3.1.4/drivers/tty/tty_ldisc module_put(ldops->owner); spin_unlock_irqrestore(&tty_ldisc_lock, flags); } -diff -urNp linux-3.1.4/drivers/tty/vt/keyboard.c linux-3.1.4/drivers/tty= /vt/keyboard.c ---- linux-3.1.4/drivers/tty/vt/keyboard.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/tty/vt/keyboard.c 2011-11-16 18:40:29.000000000 = -0500 -@@ -656,6 +656,16 @@ static void k_spec(struct vc_data *vc, u +diff --git a/drivers/tty/vt/keyboard.c b/drivers/tty/vt/keyboard.c +index 3761ccf..2c613b3 100644 +--- a/drivers/tty/vt/keyboard.c ++++ b/drivers/tty/vt/keyboard.c +@@ -656,6 +656,16 @@ static void k_spec(struct vc_data *vc, unsigned cha= r value, char up_flag) kbd->kbdmode =3D=3D VC_OFF) && value !=3D KVAL(K_SAK)) return; /* SAK is allowed even in raw mode */ @@ -36878,10 +37920,11 @@ diff -urNp linux-3.1.4/drivers/tty/vt/keyboard.= c linux-3.1.4/drivers/tty/vt/keyb fn_handler[value](vc); } =20 -diff -urNp linux-3.1.4/drivers/tty/vt/vt.c linux-3.1.4/drivers/tty/vt/vt= .c ---- linux-3.1.4/drivers/tty/vt/vt.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/tty/vt/vt.c 2011-11-16 18:39:08.000000000 -0500 -@@ -259,7 +259,7 @@ EXPORT_SYMBOL_GPL(unregister_vt_notifier +diff --git a/drivers/tty/vt/vt.c b/drivers/tty/vt/vt.c +index b3915b7..e716839 100644 +--- a/drivers/tty/vt/vt.c ++++ b/drivers/tty/vt/vt.c +@@ -259,7 +259,7 @@ EXPORT_SYMBOL_GPL(unregister_vt_notifier); =20 static void notify_write(struct vc_data *vc, unsigned int unicode) { @@ -36890,10 +37933,11 @@ diff -urNp linux-3.1.4/drivers/tty/vt/vt.c linu= x-3.1.4/drivers/tty/vt/vt.c atomic_notifier_call_chain(&vt_notifier_list, VT_WRITE, ¶m); } =20 -diff -urNp linux-3.1.4/drivers/tty/vt/vt_ioctl.c linux-3.1.4/drivers/tty= /vt/vt_ioctl.c ---- linux-3.1.4/drivers/tty/vt/vt_ioctl.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/tty/vt/vt_ioctl.c 2011-11-16 18:40:29.000000000 = -0500 -@@ -207,9 +207,6 @@ do_kdsk_ioctl(int cmd, struct kbentry __ +diff --git a/drivers/tty/vt/vt_ioctl.c b/drivers/tty/vt/vt_ioctl.c +index 5e096f4..0da1363 100644 +--- a/drivers/tty/vt/vt_ioctl.c ++++ b/drivers/tty/vt/vt_ioctl.c +@@ -207,9 +207,6 @@ do_kdsk_ioctl(int cmd, struct kbentry __user *user_k= be, int perm, struct kbd_str if (copy_from_user(&tmp, user_kbe, sizeof(struct kbentry))) return -EFAULT; =20 @@ -36903,7 +37947,7 @@ diff -urNp linux-3.1.4/drivers/tty/vt/vt_ioctl.c = linux-3.1.4/drivers/tty/vt/vt_i switch (cmd) { case KDGKBENT: key_map =3D key_maps[s]; -@@ -221,6 +218,9 @@ do_kdsk_ioctl(int cmd, struct kbentry __ +@@ -221,6 +218,9 @@ do_kdsk_ioctl(int cmd, struct kbentry __user *user_k= be, int perm, struct kbd_str val =3D (i ? K_HOLE : K_NOSUCHMAP); return put_user(val, &user_kbe->kb_value); case KDSKBENT: @@ -36913,7 +37957,7 @@ diff -urNp linux-3.1.4/drivers/tty/vt/vt_ioctl.c = linux-3.1.4/drivers/tty/vt/vt_i if (!perm) return -EPERM; if (!i && v =3D=3D K_NOSUCHMAP) { -@@ -322,9 +322,6 @@ do_kdgkb_ioctl(int cmd, struct kbsentry=20 +@@ -322,9 +322,6 @@ do_kdgkb_ioctl(int cmd, struct kbsentry __user *user= _kdgkb, int perm) int i, j, k; int ret; =20 @@ -36923,7 +37967,7 @@ diff -urNp linux-3.1.4/drivers/tty/vt/vt_ioctl.c = linux-3.1.4/drivers/tty/vt/vt_i kbs =3D kmalloc(sizeof(*kbs), GFP_KERNEL); if (!kbs) { ret =3D -ENOMEM; -@@ -358,6 +355,9 @@ do_kdgkb_ioctl(int cmd, struct kbsentry=20 +@@ -358,6 +355,9 @@ do_kdgkb_ioctl(int cmd, struct kbsentry __user *user= _kdgkb, int perm) kfree(kbs); return ((p && *p) ? -EOVERFLOW : 0); case KDSKBSENT: @@ -36933,9 +37977,10 @@ diff -urNp linux-3.1.4/drivers/tty/vt/vt_ioctl.c= linux-3.1.4/drivers/tty/vt/vt_i if (!perm) { ret =3D -EPERM; goto reterr; -diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.1.4/drivers/uio/uio.c ---- linux-3.1.4/drivers/uio/uio.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/drivers/uio/uio.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/drivers/uio/uio.c b/drivers/uio/uio.c +index d2efe82..9440ab6 100644 +--- a/drivers/uio/uio.c ++++ b/drivers/uio/uio.c @@ -25,6 +25,7 @@ #include #include @@ -36957,7 +38002,7 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.= 1.4/drivers/uio/uio.c struct uio_info *info; struct kobject *map_dir; struct kobject *portio_dir; -@@ -242,7 +243,7 @@ static ssize_t show_event(struct device=20 +@@ -242,7 +243,7 @@ static ssize_t show_event(struct device *dev, struct device_attribute *attr, char *buf) { struct uio_device *idev =3D dev_get_drvdata(dev); @@ -36966,7 +38011,7 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.= 1.4/drivers/uio/uio.c } =20 static struct device_attribute uio_class_attributes[] =3D { -@@ -408,7 +409,7 @@ void uio_event_notify(struct uio_info *i +@@ -408,7 +409,7 @@ void uio_event_notify(struct uio_info *info) { struct uio_device *idev =3D info->uio_dev; =20 @@ -36975,7 +38020,7 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.= 1.4/drivers/uio/uio.c wake_up_interruptible(&idev->wait); kill_fasync(&idev->async_queue, SIGIO, POLL_IN); } -@@ -461,7 +462,7 @@ static int uio_open(struct inode *inode, +@@ -461,7 +462,7 @@ static int uio_open(struct inode *inode, struct file= *filep) } =20 listener->dev =3D idev; @@ -36984,7 +38029,7 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.= 1.4/drivers/uio/uio.c filep->private_data =3D listener; =20 if (idev->info->open) { -@@ -512,7 +513,7 @@ static unsigned int uio_poll(struct file +@@ -512,7 +513,7 @@ static unsigned int uio_poll(struct file *filep, pol= l_table *wait) return -EIO; =20 poll_wait(filep, &idev->wait, wait); @@ -36993,7 +38038,7 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.= 1.4/drivers/uio/uio.c return POLLIN | POLLRDNORM; return 0; } -@@ -537,7 +538,7 @@ static ssize_t uio_read(struct file *fil +@@ -537,7 +538,7 @@ static ssize_t uio_read(struct file *filep, char __u= ser *buf, do { set_current_state(TASK_INTERRUPTIBLE); =20 @@ -37002,7 +38047,7 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.= 1.4/drivers/uio/uio.c if (event_count !=3D listener->event_count) { if (copy_to_user(buf, &event_count, count)) retval =3D -EFAULT; -@@ -606,13 +607,13 @@ static int uio_find_mem_index(struct vm_ +@@ -606,13 +607,13 @@ static int uio_find_mem_index(struct vm_area_struc= t *vma) static void uio_vma_open(struct vm_area_struct *vma) { struct uio_device *idev =3D vma->vm_private_data; @@ -37018,7 +38063,7 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-3.= 1.4/drivers/uio/uio.c } =20 static int uio_vma_fault(struct vm_area_struct *vma, struct vm_fault *v= mf) -@@ -823,7 +824,7 @@ int __uio_register_device(struct module=20 +@@ -823,7 +824,7 @@ int __uio_register_device(struct module *owner, idev->owner =3D owner; idev->info =3D info; init_waitqueue_head(&idev->wait); @@ -37027,10 +38072,11 @@ diff -urNp linux-3.1.4/drivers/uio/uio.c linux-= 3.1.4/drivers/uio/uio.c =20 ret =3D uio_get_minor(idev); if (ret) -diff -urNp linux-3.1.4/drivers/usb/atm/cxacru.c linux-3.1.4/drivers/usb/= atm/cxacru.c ---- linux-3.1.4/drivers/usb/atm/cxacru.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/usb/atm/cxacru.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -473,7 +473,7 @@ static ssize_t cxacru_sysfs_store_adsl_c +diff --git a/drivers/usb/atm/cxacru.c b/drivers/usb/atm/cxacru.c +index a845f8b..4f54072 100644 +--- a/drivers/usb/atm/cxacru.c ++++ b/drivers/usb/atm/cxacru.c +@@ -473,7 +473,7 @@ static ssize_t cxacru_sysfs_store_adsl_config(struct= device *dev, ret =3D sscanf(buf + pos, "%x=3D%x%n", &index, &value, &tmp); if (ret < 2) return -EINVAL; @@ -37039,10 +38085,11 @@ diff -urNp linux-3.1.4/drivers/usb/atm/cxacru.c= linux-3.1.4/drivers/usb/atm/cxac return -EINVAL; pos +=3D tmp; =20 -diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c linux-3.1.4/drivers/usb/= atm/usbatm.c ---- linux-3.1.4/drivers/usb/atm/usbatm.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/drivers/usb/atm/usbatm.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -333,7 +333,7 @@ static void usbatm_extract_one_cell(stru +diff --git a/drivers/usb/atm/usbatm.c b/drivers/usb/atm/usbatm.c +index d3448ca..d2864ca 100644 +--- a/drivers/usb/atm/usbatm.c ++++ b/drivers/usb/atm/usbatm.c +@@ -333,7 +333,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char if (printk_ratelimit()) atm_warn(instance, "%s: OAM not supported (vpi %d, vci %d)!\n", __func__, vpi, vci); @@ -37051,7 +38098,7 @@ diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c l= inux-3.1.4/drivers/usb/atm/usba return; } =20 -@@ -361,7 +361,7 @@ static void usbatm_extract_one_cell(stru +@@ -361,7 +361,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char if (length > ATM_MAX_AAL5_PDU) { atm_rldbg(instance, "%s: bogus length %u (vcc: 0x%p)!\n", __func__, length, vcc); @@ -37060,7 +38107,7 @@ diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c l= inux-3.1.4/drivers/usb/atm/usba goto out; } =20 -@@ -370,14 +370,14 @@ static void usbatm_extract_one_cell(stru +@@ -370,14 +370,14 @@ static void usbatm_extract_one_cell(struct usbatm_= data *instance, unsigned char if (sarb->len < pdu_length) { atm_rldbg(instance, "%s: bogus pdu_length %u (sarb->len: %u, vcc: 0x= %p)!\n", __func__, pdu_length, sarb->len, vcc); @@ -37077,7 +38124,7 @@ diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c l= inux-3.1.4/drivers/usb/atm/usba goto out; } =20 -@@ -387,7 +387,7 @@ static void usbatm_extract_one_cell(stru +@@ -387,7 +387,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char if (printk_ratelimit()) atm_err(instance, "%s: no memory for skb (length: %u)!\n", __func__, length); @@ -37086,7 +38133,7 @@ diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c l= inux-3.1.4/drivers/usb/atm/usba goto out; } =20 -@@ -412,7 +412,7 @@ static void usbatm_extract_one_cell(stru +@@ -412,7 +412,7 @@ static void usbatm_extract_one_cell(struct usbatm_da= ta *instance, unsigned char =20 vcc->push(vcc, skb); =20 @@ -37095,7 +38142,7 @@ diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c l= inux-3.1.4/drivers/usb/atm/usba out: skb_trim(sarb, 0); } -@@ -615,7 +615,7 @@ static void usbatm_tx_process(unsigned l +@@ -615,7 +615,7 @@ static void usbatm_tx_process(unsigned long data) struct atm_vcc *vcc =3D UDSL_SKB(skb)->atm.vcc; =20 usbatm_pop(vcc, skb); @@ -37104,7 +38151,7 @@ diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c l= inux-3.1.4/drivers/usb/atm/usba =20 skb =3D skb_dequeue(&instance->sndqueue); } -@@ -773,11 +773,11 @@ static int usbatm_atm_proc_read(struct a +@@ -773,11 +773,11 @@ static int usbatm_atm_proc_read(struct atm_dev *at= m_dev, loff_t * pos, char *pag if (!left--) return sprintf(page, "AAL5: tx %d ( %d err ), rx %d ( %d err, %d drop )\n", @@ -37121,9 +38168,10 @@ diff -urNp linux-3.1.4/drivers/usb/atm/usbatm.c = linux-3.1.4/drivers/usb/atm/usba =20 if (!left--) { if (instance->disconnected) -diff -urNp linux-3.1.4/drivers/usb/core/devices.c linux-3.1.4/drivers/us= b/core/devices.c ---- linux-3.1.4/drivers/usb/core/devices.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/usb/core/devices.c 2011-11-16 18:39:08.000000000= -0500 +diff --git a/drivers/usb/core/devices.c b/drivers/usb/core/devices.c +index 0149c09..f108812 100644 +--- a/drivers/usb/core/devices.c ++++ b/drivers/usb/core/devices.c @@ -126,7 +126,7 @@ static const char format_endpt[] =3D * time it gets called. */ @@ -37133,7 +38181,7 @@ diff -urNp linux-3.1.4/drivers/usb/core/devices.c= linux-3.1.4/drivers/usb/core/d wait_queue_head_t wait; } device_event =3D { .count =3D ATOMIC_INIT(1), -@@ -164,7 +164,7 @@ static const struct class_info clas_info +@@ -164,7 +164,7 @@ static const struct class_info clas_info[] =3D { =20 void usbfs_conn_disc_event(void) { @@ -37142,7 +38190,7 @@ diff -urNp linux-3.1.4/drivers/usb/core/devices.c= linux-3.1.4/drivers/usb/core/d wake_up(&device_event.wait); } =20 -@@ -648,7 +648,7 @@ static unsigned int usb_device_poll(stru +@@ -648,7 +648,7 @@ static unsigned int usb_device_poll(struct file *fil= e, =20 poll_wait(file, &device_event.wait, wait); =20 @@ -37151,10 +38199,11 @@ diff -urNp linux-3.1.4/drivers/usb/core/devices= .c linux-3.1.4/drivers/usb/core/d if (file->f_version !=3D event_count) { file->f_version =3D event_count; return POLLIN | POLLRDNORM; -diff -urNp linux-3.1.4/drivers/usb/core/message.c linux-3.1.4/drivers/us= b/core/message.c ---- linux-3.1.4/drivers/usb/core/message.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/drivers/usb/core/message.c 2011-11-16 18:39:08.000000000= -0500 -@@ -869,8 +869,8 @@ char *usb_cache_string(struct usb_device +diff --git a/drivers/usb/core/message.c b/drivers/usb/core/message.c +index 0b5ec23..0da3d76 100644 +--- a/drivers/usb/core/message.c ++++ b/drivers/usb/core/message.c +@@ -869,8 +869,8 @@ char *usb_cache_string(struct usb_device *udev, int = index) buf =3D kmalloc(MAX_USB_STRING_SIZE, GFP_NOIO); if (buf) { len =3D usb_string(udev, index, buf, MAX_USB_STRING_SIZE); @@ -37165,10 +38214,11 @@ diff -urNp linux-3.1.4/drivers/usb/core/message= .c linux-3.1.4/drivers/usb/core/m if (!smallbuf) return buf; memcpy(smallbuf, buf, len); -diff -urNp linux-3.1.4/drivers/usb/early/ehci-dbgp.c linux-3.1.4/drivers= /usb/early/ehci-dbgp.c ---- linux-3.1.4/drivers/usb/early/ehci-dbgp.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/usb/early/ehci-dbgp.c 2011-11-16 18:39:08.000000= 000 -0500 -@@ -97,7 +97,8 @@ static inline u32 dbgp_len_update(u32 x, +diff --git a/drivers/usb/early/ehci-dbgp.c b/drivers/usb/early/ehci-dbgp= .c +index 1fc8f12..20647c1 100644 +--- a/drivers/usb/early/ehci-dbgp.c ++++ b/drivers/usb/early/ehci-dbgp.c +@@ -97,7 +97,8 @@ static inline u32 dbgp_len_update(u32 x, u32 len) =20 #ifdef CONFIG_KGDB static struct kgdb_io kgdbdbgp_io_ops; @@ -37178,7 +38228,7 @@ diff -urNp linux-3.1.4/drivers/usb/early/ehci-dbg= p.c linux-3.1.4/drivers/usb/ear #else #define dbgp_kgdb_mode (0) #endif -@@ -1035,6 +1036,13 @@ static struct kgdb_io kgdbdbgp_io_ops =3D=20 +@@ -1035,6 +1036,13 @@ static struct kgdb_io kgdbdbgp_io_ops =3D { .write_char =3D kgdbdbgp_write_char, }; =20 @@ -37192,7 +38242,7 @@ diff -urNp linux-3.1.4/drivers/usb/early/ehci-dbg= p.c linux-3.1.4/drivers/usb/ear static int kgdbdbgp_wait_time; =20 static int __init kgdbdbgp_parse_config(char *str) -@@ -1050,8 +1058,10 @@ static int __init kgdbdbgp_parse_config( +@@ -1050,8 +1058,10 @@ static int __init kgdbdbgp_parse_config(char *str= ) ptr++; kgdbdbgp_wait_time =3D simple_strtoul(ptr, &ptr, 10); } @@ -37205,10 +38255,11 @@ diff -urNp linux-3.1.4/drivers/usb/early/ehci-d= bgp.c linux-3.1.4/drivers/usb/ear =20 return 0; } -diff -urNp linux-3.1.4/drivers/usb/host/xhci-mem.c linux-3.1.4/drivers/u= sb/host/xhci-mem.c ---- linux-3.1.4/drivers/usb/host/xhci-mem.c 2011-11-26 19:57:29.00000000= 0 -0500 -+++ linux-3.1.4/drivers/usb/host/xhci-mem.c 2011-11-26 20:00:43.00000000= 0 -0500 -@@ -1685,6 +1685,8 @@ static int xhci_check_trb_in_td_math(str +diff --git a/drivers/usb/host/xhci-mem.c b/drivers/usb/host/xhci-mem.c +index d718033..6075579 100644 +--- a/drivers/usb/host/xhci-mem.c ++++ b/drivers/usb/host/xhci-mem.c +@@ -1685,6 +1685,8 @@ static int xhci_check_trb_in_td_math(struct xhci_h= cd *xhci, gfp_t mem_flags) unsigned int num_tests; int i, ret; =20 @@ -37217,9 +38268,10 @@ diff -urNp linux-3.1.4/drivers/usb/host/xhci-mem= .c linux-3.1.4/drivers/usb/host/ num_tests =3D ARRAY_SIZE(simple_test_vector); for (i =3D 0; i < num_tests; i++) { ret =3D xhci_test_trb_in_td(xhci, -diff -urNp linux-3.1.4/drivers/usb/wusbcore/wa-hc.h linux-3.1.4/drivers/= usb/wusbcore/wa-hc.h ---- linux-3.1.4/drivers/usb/wusbcore/wa-hc.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/usb/wusbcore/wa-hc.h 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/drivers/usb/wusbcore/wa-hc.h b/drivers/usb/wusbcore/wa-hc.h +index d6bea3e..60b250e 100644 +--- a/drivers/usb/wusbcore/wa-hc.h ++++ b/drivers/usb/wusbcore/wa-hc.h @@ -192,7 +192,7 @@ struct wahc { struct list_head xfer_delayed_list; spinlock_t xfer_list_lock; @@ -37229,7 +38281,7 @@ diff -urNp linux-3.1.4/drivers/usb/wusbcore/wa-hc= .h linux-3.1.4/drivers/usb/wusb }; =20 =20 -@@ -246,7 +246,7 @@ static inline void wa_init(struct wahc * +@@ -246,7 +246,7 @@ static inline void wa_init(struct wahc *wa) INIT_LIST_HEAD(&wa->xfer_delayed_list); spin_lock_init(&wa->xfer_list_lock); INIT_WORK(&wa->xfer_work, wa_urb_enqueue_run); @@ -37238,9 +38290,10 @@ diff -urNp linux-3.1.4/drivers/usb/wusbcore/wa-h= c.h linux-3.1.4/drivers/usb/wusb } =20 /** -diff -urNp linux-3.1.4/drivers/usb/wusbcore/wa-xfer.c linux-3.1.4/driver= s/usb/wusbcore/wa-xfer.c ---- linux-3.1.4/drivers/usb/wusbcore/wa-xfer.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/usb/wusbcore/wa-xfer.c 2011-11-16 18:39:08.00000= 0000 -0500 +diff --git a/drivers/usb/wusbcore/wa-xfer.c b/drivers/usb/wusbcore/wa-xf= er.c +index 4193345..49ae93d 100644 +--- a/drivers/usb/wusbcore/wa-xfer.c ++++ b/drivers/usb/wusbcore/wa-xfer.c @@ -295,7 +295,7 @@ out: */ static void wa_xfer_id_init(struct wa_xfer *xfer) @@ -37250,10 +38303,11 @@ diff -urNp linux-3.1.4/drivers/usb/wusbcore/wa-= xfer.c linux-3.1.4/drivers/usb/wu } =20 /* -diff -urNp linux-3.1.4/drivers/vhost/vhost.c linux-3.1.4/drivers/vhost/v= host.c ---- linux-3.1.4/drivers/vhost/vhost.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/vhost/vhost.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -629,7 +629,7 @@ static long vhost_set_memory(struct vhos +diff --git a/drivers/vhost/vhost.c b/drivers/vhost/vhost.c +index c14c42b..f955cc2 100644 +--- a/drivers/vhost/vhost.c ++++ b/drivers/vhost/vhost.c +@@ -629,7 +629,7 @@ static long vhost_set_memory(struct vhost_dev *d, st= ruct vhost_memory __user *m) return 0; } =20 @@ -37262,9 +38316,10 @@ diff -urNp linux-3.1.4/drivers/vhost/vhost.c lin= ux-3.1.4/drivers/vhost/vhost.c { struct file *eventfp, *filep =3D NULL, *pollstart =3D NULL, *pollstop =3D NULL; -diff -urNp linux-3.1.4/drivers/video/aty/aty128fb.c linux-3.1.4/drivers/= video/aty/aty128fb.c ---- linux-3.1.4/drivers/video/aty/aty128fb.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/drivers/video/aty/aty128fb.c 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/drivers/video/aty/aty128fb.c b/drivers/video/aty/aty128fb.c +index b0b2ac3..89a4399 100644 +--- a/drivers/video/aty/aty128fb.c ++++ b/drivers/video/aty/aty128fb.c @@ -148,7 +148,7 @@ enum { }; =20 @@ -37274,10 +38329,11 @@ diff -urNp linux-3.1.4/drivers/video/aty/aty128= fb.c linux-3.1.4/drivers/video/at "AGP", "PCI", "PRO AGP", -diff -urNp linux-3.1.4/drivers/video/fbcmap.c linux-3.1.4/drivers/video/= fbcmap.c ---- linux-3.1.4/drivers/video/fbcmap.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/video/fbcmap.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -285,8 +285,7 @@ int fb_set_user_cmap(struct fb_cmap_user +diff --git a/drivers/video/fbcmap.c b/drivers/video/fbcmap.c +index 5c3960d..15cf8fc 100644 +--- a/drivers/video/fbcmap.c ++++ b/drivers/video/fbcmap.c +@@ -285,8 +285,7 @@ int fb_set_user_cmap(struct fb_cmap_user *cmap, stru= ct fb_info *info) rc =3D -ENODEV; goto out; } @@ -37287,10 +38343,11 @@ diff -urNp linux-3.1.4/drivers/video/fbcmap.c l= inux-3.1.4/drivers/video/fbcmap.c rc =3D -EINVAL; goto out1; } -diff -urNp linux-3.1.4/drivers/video/fbmem.c linux-3.1.4/drivers/video/f= bmem.c ---- linux-3.1.4/drivers/video/fbmem.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/video/fbmem.c 2011-11-16 18:40:29.000000000 -050= 0 -@@ -428,7 +428,7 @@ static void fb_do_show_logo(struct fb_in +diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c +index ad93629..ca6a218 100644 +--- a/drivers/video/fbmem.c ++++ b/drivers/video/fbmem.c +@@ -428,7 +428,7 @@ static void fb_do_show_logo(struct fb_info *info, st= ruct fb_image *image, image->dx +=3D image->width + 8; } } else if (rotate =3D=3D FB_ROTATE_UD) { @@ -37299,7 +38356,7 @@ diff -urNp linux-3.1.4/drivers/video/fbmem.c linu= x-3.1.4/drivers/video/fbmem.c info->fbops->fb_imageblit(info, image); image->dx -=3D image->width + 8; } -@@ -440,7 +440,7 @@ static void fb_do_show_logo(struct fb_in +@@ -440,7 +440,7 @@ static void fb_do_show_logo(struct fb_info *info, st= ruct fb_image *image, image->dy +=3D image->height + 8; } } else if (rotate =3D=3D FB_ROTATE_CCW) { @@ -37308,7 +38365,7 @@ diff -urNp linux-3.1.4/drivers/video/fbmem.c linu= x-3.1.4/drivers/video/fbmem.c info->fbops->fb_imageblit(info, image); image->dy -=3D image->height + 8; } -@@ -939,6 +939,8 @@ fb_set_var(struct fb_info *info, struct=20 +@@ -939,6 +939,8 @@ fb_set_var(struct fb_info *info, struct fb_var_scree= ninfo *var) int flags =3D info->flags; int ret =3D 0; =20 @@ -37317,7 +38374,7 @@ diff -urNp linux-3.1.4/drivers/video/fbmem.c linu= x-3.1.4/drivers/video/fbmem.c if (var->activate & FB_ACTIVATE_INV_MODE) { struct fb_videomode mode1, mode2; =20 -@@ -1064,6 +1066,8 @@ static long do_fb_ioctl(struct fb_info * +@@ -1064,6 +1066,8 @@ static long do_fb_ioctl(struct fb_info *info, unsi= gned int cmd, void __user *argp =3D (void __user *)arg; long ret =3D 0; =20 @@ -37326,7 +38383,7 @@ diff -urNp linux-3.1.4/drivers/video/fbmem.c linu= x-3.1.4/drivers/video/fbmem.c switch (cmd) { case FBIOGET_VSCREENINFO: if (!lock_fb_info(info)) -@@ -1143,7 +1147,7 @@ static long do_fb_ioctl(struct fb_info * +@@ -1143,7 +1147,7 @@ static long do_fb_ioctl(struct fb_info *info, unsi= gned int cmd, return -EFAULT; if (con2fb.console < 1 || con2fb.console > MAX_NR_CONSOLES) return -EINVAL; @@ -37335,9 +38392,10 @@ diff -urNp linux-3.1.4/drivers/video/fbmem.c lin= ux-3.1.4/drivers/video/fbmem.c return -EINVAL; if (!registered_fb[con2fb.framebuffer]) request_module("fb%d", con2fb.framebuffer); -diff -urNp linux-3.1.4/drivers/video/geode/gx1fb_core.c linux-3.1.4/driv= ers/video/geode/gx1fb_core.c ---- linux-3.1.4/drivers/video/geode/gx1fb_core.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/drivers/video/geode/gx1fb_core.c 2011-11-16 18:39:08.000= 000000 -0500 +diff --git a/drivers/video/geode/gx1fb_core.c b/drivers/video/geode/gx1f= b_core.c +index 5a5d092..265c5ed 100644 +--- a/drivers/video/geode/gx1fb_core.c ++++ b/drivers/video/geode/gx1fb_core.c @@ -29,7 +29,7 @@ static int crt_option =3D 1; static char panel_option[32] =3D ""; =20 @@ -37347,9 +38405,10 @@ diff -urNp linux-3.1.4/drivers/video/geode/gx1fb= _core.c linux-3.1.4/drivers/vide /* 640x480-60 VESA */ { NULL, 60, 640, 480, 39682, 48, 16, 33, 10, 96, 2, 0, FB_VMODE_NONINTERLACED, FB_MODE_IS_VESA }, -diff -urNp linux-3.1.4/drivers/video/gxt4500.c linux-3.1.4/drivers/video= /gxt4500.c ---- linux-3.1.4/drivers/video/gxt4500.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/video/gxt4500.c 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/drivers/video/gxt4500.c b/drivers/video/gxt4500.c +index 896e53d..4d87d0b 100644 +--- a/drivers/video/gxt4500.c ++++ b/drivers/video/gxt4500.c @@ -156,7 +156,7 @@ struct gxt4500_par { static char *mode_option; =20 @@ -37359,7 +38418,7 @@ diff -urNp linux-3.1.4/drivers/video/gxt4500.c li= nux-3.1.4/drivers/video/gxt4500 .refresh =3D 60, .xres =3D 1280, .yres =3D 1024, -@@ -581,7 +581,7 @@ static int gxt4500_blank(int blank, stru +@@ -581,7 +581,7 @@ static int gxt4500_blank(int blank, struct fb_info *= info) return 0; } =20 @@ -37368,10 +38427,11 @@ diff -urNp linux-3.1.4/drivers/video/gxt4500.c = linux-3.1.4/drivers/video/gxt4500 .id =3D "IBM GXT4500P", .type =3D FB_TYPE_PACKED_PIXELS, .visual =3D FB_VISUAL_PSEUDOCOLOR, -diff -urNp linux-3.1.4/drivers/video/i810/i810_accel.c linux-3.1.4/drive= rs/video/i810/i810_accel.c ---- linux-3.1.4/drivers/video/i810/i810_accel.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/video/i810/i810_accel.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -73,6 +73,7 @@ static inline int wait_for_space(struct=20 +diff --git a/drivers/video/i810/i810_accel.c b/drivers/video/i810/i810_a= ccel.c +index 7672d2e..b56437f 100644 +--- a/drivers/video/i810/i810_accel.c ++++ b/drivers/video/i810/i810_accel.c +@@ -73,6 +73,7 @@ static inline int wait_for_space(struct fb_info *info,= u32 space) } } printk("ringbuffer lockup!!!\n"); @@ -37379,10 +38439,11 @@ diff -urNp linux-3.1.4/drivers/video/i810/i810_= accel.c linux-3.1.4/drivers/video i810_report_error(mmio);=20 par->dev_flags |=3D LOCKUP; info->pixmap.scan_align =3D 1; -diff -urNp linux-3.1.4/drivers/video/i810/i810_main.c linux-3.1.4/driver= s/video/i810/i810_main.c ---- linux-3.1.4/drivers/video/i810/i810_main.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/drivers/video/i810/i810_main.c 2011-11-16 18:39:08.00000= 0000 -0500 -@@ -97,7 +97,7 @@ static int i810fb_blank (int blank_ +diff --git a/drivers/video/i810/i810_main.c b/drivers/video/i810/i810_ma= in.c +index 318f6fb..9a389c1 100644 +--- a/drivers/video/i810/i810_main.c ++++ b/drivers/video/i810/i810_main.c +@@ -97,7 +97,7 @@ static int i810fb_blank (int blank_mode, struct f= b_info *info); static void i810fb_release_resource (struct fb_info *info, struct= i810fb_par *par); =20 /* PCI */ @@ -37391,9 +38452,10 @@ diff -urNp linux-3.1.4/drivers/video/i810/i810_m= ain.c linux-3.1.4/drivers/video/ "Intel(R) 810 Framebuffer Device" , "Intel(R) 810-DC100 Framebuffer Device" , "Intel(R) 810E Framebuffer Device" , -diff -urNp linux-3.1.4/drivers/video/jz4740_fb.c linux-3.1.4/drivers/vid= eo/jz4740_fb.c ---- linux-3.1.4/drivers/video/jz4740_fb.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/drivers/video/jz4740_fb.c 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/drivers/video/jz4740_fb.c b/drivers/video/jz4740_fb.c +index de36693..3c63fc2 100644 +--- a/drivers/video/jz4740_fb.c ++++ b/drivers/video/jz4740_fb.c @@ -136,7 +136,7 @@ struct jzfb { uint32_t pseudo_palette[16]; }; @@ -37403,9 +38465,10 @@ diff -urNp linux-3.1.4/drivers/video/jz4740_fb.c= linux-3.1.4/drivers/video/jz474 .id =3D "JZ4740 FB", .type =3D FB_TYPE_PACKED_PIXELS, .visual =3D FB_VISUAL_TRUECOLOR, -diff -urNp linux-3.1.4/drivers/video/logo/logo_linux_clut224.ppm linux-3= .1.4/drivers/video/logo/logo_linux_clut224.ppm ---- linux-3.1.4/drivers/video/logo/logo_linux_clut224.ppm 2011-11-11 15:= 19:27.000000000 -0500 -+++ linux-3.1.4/drivers/video/logo/logo_linux_clut224.ppm 2011-11-16 18:= 40:29.000000000 -0500 +diff --git a/drivers/video/logo/logo_linux_clut224.ppm b/drivers/video/l= ogo/logo_linux_clut224.ppm +index 3c14e43..eafa544 100644 +--- a/drivers/video/logo/logo_linux_clut224.ppm ++++ b/drivers/video/logo/logo_linux_clut224.ppm @@ -1,1604 +1,1123 @@ P3 -# Standard 224-color Linux logo @@ -40131,10 +41194,11 @@ diff -urNp linux-3.1.4/drivers/video/logo/logo_= linux_clut224.ppm linux-3.1.4/dri +4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 +4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 +4 4 4 4 4 4 -diff -urNp linux-3.1.4/drivers/video/udlfb.c linux-3.1.4/drivers/video/u= dlfb.c ---- linux-3.1.4/drivers/video/udlfb.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/drivers/video/udlfb.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -585,11 +585,11 @@ int dlfb_handle_damage(struct dlfb_data=20 +diff --git a/drivers/video/udlfb.c b/drivers/video/udlfb.c +index 087fc99..f85ed76 100644 +--- a/drivers/video/udlfb.c ++++ b/drivers/video/udlfb.c +@@ -585,11 +585,11 @@ int dlfb_handle_damage(struct dlfb_data *dev, int = x, int y, dlfb_urb_completion(urb); =20 error: @@ -40150,7 +41214,7 @@ diff -urNp linux-3.1.4/drivers/video/udlfb.c linu= x-3.1.4/drivers/video/udlfb.c >> 10)), /* Kcycles */ &dev->cpu_kcycles_used); =20 -@@ -710,11 +710,11 @@ static void dlfb_dpy_deferred_io(struct=20 +@@ -710,11 +710,11 @@ static void dlfb_dpy_deferred_io(struct fb_info *i= nfo, dlfb_urb_completion(urb); =20 error: @@ -40166,7 +41230,7 @@ diff -urNp linux-3.1.4/drivers/video/udlfb.c linu= x-3.1.4/drivers/video/udlfb.c >> 10)), /* Kcycles */ &dev->cpu_kcycles_used); } -@@ -1306,7 +1306,7 @@ static ssize_t metrics_bytes_rendered_sh +@@ -1306,7 +1306,7 @@ static ssize_t metrics_bytes_rendered_show(struct = device *fbdev, struct fb_info *fb_info =3D dev_get_drvdata(fbdev); struct dlfb_data *dev =3D fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -40175,7 +41239,7 @@ diff -urNp linux-3.1.4/drivers/video/udlfb.c linu= x-3.1.4/drivers/video/udlfb.c } =20 static ssize_t metrics_bytes_identical_show(struct device *fbdev, -@@ -1314,7 +1314,7 @@ static ssize_t metrics_bytes_identical_s +@@ -1314,7 +1314,7 @@ static ssize_t metrics_bytes_identical_show(struct= device *fbdev, struct fb_info *fb_info =3D dev_get_drvdata(fbdev); struct dlfb_data *dev =3D fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -40184,7 +41248,7 @@ diff -urNp linux-3.1.4/drivers/video/udlfb.c linu= x-3.1.4/drivers/video/udlfb.c } =20 static ssize_t metrics_bytes_sent_show(struct device *fbdev, -@@ -1322,7 +1322,7 @@ static ssize_t metrics_bytes_sent_show(s +@@ -1322,7 +1322,7 @@ static ssize_t metrics_bytes_sent_show(struct devi= ce *fbdev, struct fb_info *fb_info =3D dev_get_drvdata(fbdev); struct dlfb_data *dev =3D fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -40193,7 +41257,7 @@ diff -urNp linux-3.1.4/drivers/video/udlfb.c linu= x-3.1.4/drivers/video/udlfb.c } =20 static ssize_t metrics_cpu_kcycles_used_show(struct device *fbdev, -@@ -1330,7 +1330,7 @@ static ssize_t metrics_cpu_kcycles_used_ +@@ -1330,7 +1330,7 @@ static ssize_t metrics_cpu_kcycles_used_show(struc= t device *fbdev, struct fb_info *fb_info =3D dev_get_drvdata(fbdev); struct dlfb_data *dev =3D fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -40202,7 +41266,7 @@ diff -urNp linux-3.1.4/drivers/video/udlfb.c linu= x-3.1.4/drivers/video/udlfb.c } =20 static ssize_t edid_show( -@@ -1387,10 +1387,10 @@ static ssize_t metrics_reset_store(struc +@@ -1387,10 +1387,10 @@ static ssize_t metrics_reset_store(struct device= *fbdev, struct fb_info *fb_info =3D dev_get_drvdata(fbdev); struct dlfb_data *dev =3D fb_info->par; =20 @@ -40217,9 +41281,10 @@ diff -urNp linux-3.1.4/drivers/video/udlfb.c lin= ux-3.1.4/drivers/video/udlfb.c =20 return count; } -diff -urNp linux-3.1.4/drivers/video/uvesafb.c linux-3.1.4/drivers/video= /uvesafb.c ---- linux-3.1.4/drivers/video/uvesafb.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/drivers/video/uvesafb.c 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/drivers/video/uvesafb.c b/drivers/video/uvesafb.c +index 7f8472c..9842e87 100644 +--- a/drivers/video/uvesafb.c ++++ b/drivers/video/uvesafb.c @@ -19,6 +19,7 @@ #include #include @@ -40237,7 +41302,7 @@ diff -urNp linux-3.1.4/drivers/video/uvesafb.c li= nux-3.1.4/drivers/video/uvesafb } =20 /* -@@ -569,10 +570,32 @@ static int __devinit uvesafb_vbe_getpmi( +@@ -569,10 +570,32 @@ static int __devinit uvesafb_vbe_getpmi(struct uve= safb_ktask *task, if ((task->t.regs.eax & 0xffff) !=3D 0x4f || task->t.regs.es < 0xc000)= { par->pmi_setpal =3D par->ypan =3D 0; } else { @@ -40282,7 +41347,7 @@ diff -urNp linux-3.1.4/drivers/video/uvesafb.c li= nux-3.1.4/drivers/video/uvesafb framebuffer_release(info); return err; } -@@ -1847,6 +1875,12 @@ static int uvesafb_remove(struct platfor +@@ -1847,6 +1875,12 @@ static int uvesafb_remove(struct platform_device = *dev) kfree(par->vbe_state_orig); if (par->vbe_state_saved) kfree(par->vbe_state_saved); @@ -40295,9 +41360,10 @@ diff -urNp linux-3.1.4/drivers/video/uvesafb.c l= inux-3.1.4/drivers/video/uvesafb } =20 framebuffer_release(info); -diff -urNp linux-3.1.4/drivers/video/vesafb.c linux-3.1.4/drivers/video/= vesafb.c ---- linux-3.1.4/drivers/video/vesafb.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/drivers/video/vesafb.c 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/drivers/video/vesafb.c b/drivers/video/vesafb.c +index 501b340..86bd4cf 100644 +--- a/drivers/video/vesafb.c ++++ b/drivers/video/vesafb.c @@ -9,6 +9,7 @@ */ =20 @@ -40306,7 +41372,7 @@ diff -urNp linux-3.1.4/drivers/video/vesafb.c lin= ux-3.1.4/drivers/video/vesafb.c #include #include #include -@@ -52,8 +53,8 @@ static int vram_remap __initdata; /*=20 +@@ -52,8 +53,8 @@ static int vram_remap __initdata; /* Set amount of = memory to be used */ static int vram_total __initdata; /* Set total amount of memory */ static int pmi_setpal __read_mostly =3D 1; /* pmi for palette changes= ??? */ static int ypan __read_mostly; /* 0..nothing, 1..ypan, 2..ywra= p */ @@ -40317,7 +41383,7 @@ diff -urNp linux-3.1.4/drivers/video/vesafb.c lin= ux-3.1.4/drivers/video/vesafb.c static int depth __read_mostly; static int vga_compat __read_mostly; /* --------------------------------------------------------------------= - */ -@@ -233,6 +234,7 @@ static int __init vesafb_probe(struct pl +@@ -233,6 +234,7 @@ static int __init vesafb_probe(struct platform_devic= e *dev) unsigned int size_vmode; unsigned int size_remap; unsigned int size_total; @@ -40325,7 +41391,7 @@ diff -urNp linux-3.1.4/drivers/video/vesafb.c lin= ux-3.1.4/drivers/video/vesafb.c =20 if (screen_info.orig_video_isVGA !=3D VIDEO_TYPE_VLFB) return -ENODEV; -@@ -275,10 +277,6 @@ static int __init vesafb_probe(struct pl +@@ -275,10 +277,6 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) size_remap =3D size_total; vesafb_fix.smem_len =3D size_remap; =20 @@ -40336,7 +41402,7 @@ diff -urNp linux-3.1.4/drivers/video/vesafb.c lin= ux-3.1.4/drivers/video/vesafb.c if (!request_mem_region(vesafb_fix.smem_start, size_total, "vesafb")) = { printk(KERN_WARNING "vesafb: cannot reserve video memory at 0x%lx\n", -@@ -307,9 +305,21 @@ static int __init vesafb_probe(struct pl +@@ -307,9 +305,21 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) printk(KERN_INFO "vesafb: mode is %dx%dx%d, linelength=3D%d, pages=3D%= d\n", vesafb_defined.xres, vesafb_defined.yres, vesafb_defined.bits_p= er_pixel, vesafb_fix.line_length, screen_info.pages); =20 @@ -40360,7 +41426,7 @@ diff -urNp linux-3.1.4/drivers/video/vesafb.c lin= ux-3.1.4/drivers/video/vesafb.c } =20 if (screen_info.vesapm_seg < 0xc000) -@@ -317,9 +327,25 @@ static int __init vesafb_probe(struct pl +@@ -317,9 +327,25 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) =20 if (ypan || pmi_setpal) { unsigned short *pmi_base; @@ -40388,7 +41454,7 @@ diff -urNp linux-3.1.4/drivers/video/vesafb.c lin= ux-3.1.4/drivers/video/vesafb.c printk(KERN_INFO "vesafb: pmi: set display start =3D %p, set palette = =3D %p\n",pmi_start,pmi_pal); if (pmi_base[3]) { printk(KERN_INFO "vesafb: pmi: ports =3D "); -@@ -488,6 +514,11 @@ static int __init vesafb_probe(struct pl +@@ -488,6 +514,11 @@ static int __init vesafb_probe(struct platform_devi= ce *dev) info->node, info->fix.id); return 0; err: @@ -40400,9 +41466,10 @@ diff -urNp linux-3.1.4/drivers/video/vesafb.c li= nux-3.1.4/drivers/video/vesafb.c if (info->screen_base) iounmap(info->screen_base); framebuffer_release(info); -diff -urNp linux-3.1.4/drivers/video/via/via_clock.h linux-3.1.4/drivers= /video/via/via_clock.h ---- linux-3.1.4/drivers/video/via/via_clock.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/drivers/video/via/via_clock.h 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/drivers/video/via/via_clock.h b/drivers/video/via/via_clock= .h +index 88714ae..16c2e11 100644 +--- a/drivers/video/via/via_clock.h ++++ b/drivers/video/via/via_clock.h @@ -56,7 +56,7 @@ struct via_clock { =20 void (*set_engine_pll_state)(u8 state); @@ -40412,10 +41479,11 @@ diff -urNp linux-3.1.4/drivers/video/via/via_cl= ock.h linux-3.1.4/drivers/video/v =20 =20 static inline u32 get_pll_internal_frequency(u32 ref_freq, -diff -urNp linux-3.1.4/drivers/virtio/virtio_balloon.c linux-3.1.4/drive= rs/virtio/virtio_balloon.c ---- linux-3.1.4/drivers/virtio/virtio_balloon.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/drivers/virtio/virtio_balloon.c 2011-11-16 18:40:29.0000= 00000 -0500 -@@ -174,6 +174,8 @@ static void update_balloon_stats(struct=20 +diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_bal= loon.c +index e058ace..2424d93 100644 +--- a/drivers/virtio/virtio_balloon.c ++++ b/drivers/virtio/virtio_balloon.c +@@ -174,6 +174,8 @@ static void update_balloon_stats(struct virtio_ballo= on *vb) struct sysinfo i; int idx =3D 0; =20 @@ -40424,9 +41492,10 @@ diff -urNp linux-3.1.4/drivers/virtio/virtio_bal= loon.c linux-3.1.4/drivers/virti all_vm_events(events); si_meminfo(&i); =20 -diff -urNp linux-3.1.4/drivers/xen/xen-pciback/conf_space.h linux-3.1.4/= drivers/xen/xen-pciback/conf_space.h ---- linux-3.1.4/drivers/xen/xen-pciback/conf_space.h 2011-11-11 15:19:27= .000000000 -0500 -+++ linux-3.1.4/drivers/xen/xen-pciback/conf_space.h 2011-11-16 18:39:08= .000000000 -0500 +diff --git a/drivers/xen/xen-pciback/conf_space.h b/drivers/xen/xen-pcib= ack/conf_space.h +index e56c934..fc22f4b 100644 +--- a/drivers/xen/xen-pciback/conf_space.h ++++ b/drivers/xen/xen-pciback/conf_space.h @@ -44,15 +44,15 @@ struct config_field { struct { conf_dword_write write; @@ -40446,10 +41515,11 @@ diff -urNp linux-3.1.4/drivers/xen/xen-pciback/= conf_space.h linux-3.1.4/drivers/ } u; struct list_head list; }; -diff -urNp linux-3.1.4/fs/9p/vfs_inode.c linux-3.1.4/fs/9p/vfs_inode.c ---- linux-3.1.4/fs/9p/vfs_inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/9p/vfs_inode.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1288,7 +1288,7 @@ static void *v9fs_vfs_follow_link(struct +diff --git a/fs/9p/vfs_inode.c b/fs/9p/vfs_inode.c +index e3c03db..93b0172 100644 +--- a/fs/9p/vfs_inode.c ++++ b/fs/9p/vfs_inode.c +@@ -1288,7 +1288,7 @@ static void *v9fs_vfs_follow_link(struct dentry *d= entry, struct nameidata *nd) void v9fs_vfs_put_link(struct dentry *dentry, struct nameidata *nd, void *p) { @@ -40458,10 +41528,24 @@ diff -urNp linux-3.1.4/fs/9p/vfs_inode.c linux-= 3.1.4/fs/9p/vfs_inode.c =20 P9_DPRINTK(P9_DEBUG_VFS, " %s %s\n", dentry->d_name.name, IS_ERR(s) ? "" : s); -diff -urNp linux-3.1.4/fs/aio.c linux-3.1.4/fs/aio.c ---- linux-3.1.4/fs/aio.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/aio.c 2011-11-16 18:40:29.000000000 -0500 -@@ -119,7 +119,7 @@ static int aio_setup_ring(struct kioctx=20 +diff --git a/fs/Kconfig.binfmt b/fs/Kconfig.binfmt +index 79e2ca7..5828ad1 100644 +--- a/fs/Kconfig.binfmt ++++ b/fs/Kconfig.binfmt +@@ -86,7 +86,7 @@ config HAVE_AOUT +=20 + config BINFMT_AOUT + tristate "Kernel support for a.out and ECOFF binaries" +- depends on HAVE_AOUT ++ depends on HAVE_AOUT && BROKEN + ---help--- + A.out (Assembler.OUTput) is a set of formats for libraries and + executables used in the earliest versions of UNIX. Linux used +diff --git a/fs/aio.c b/fs/aio.c +index e29ec48..f083e5e 100644 +--- a/fs/aio.c ++++ b/fs/aio.c +@@ -119,7 +119,7 @@ static int aio_setup_ring(struct kioctx *ctx) size +=3D sizeof(struct io_event) * nr_events; nr_pages =3D (size + PAGE_SIZE-1) >> PAGE_SHIFT; =20 @@ -40470,7 +41554,7 @@ diff -urNp linux-3.1.4/fs/aio.c linux-3.1.4/fs/ai= o.c return -EINVAL; =20 nr_events =3D (PAGE_SIZE * nr_pages - sizeof(struct aio_ring)) / sizeo= f(struct io_event); -@@ -1088,6 +1088,8 @@ static int read_events(struct kioctx *ct +@@ -1088,6 +1088,8 @@ static int read_events(struct kioctx *ctx, struct aio_timeout to; int retry =3D 0; =20 @@ -40479,7 +41563,7 @@ diff -urNp linux-3.1.4/fs/aio.c linux-3.1.4/fs/ai= o.c /* needed to zero any padding within an entry (there shouldn't be=20 * any, but C is fun! */ -@@ -1381,22 +1383,27 @@ static ssize_t aio_fsync(struct kiocb *i +@@ -1381,22 +1383,27 @@ static ssize_t aio_fsync(struct kiocb *iocb) static ssize_t aio_setup_vectored_rw(int type, struct kiocb *kiocb, boo= l compat) { ssize_t ret; @@ -40509,10 +41593,11 @@ diff -urNp linux-3.1.4/fs/aio.c linux-3.1.4/fs/= aio.c kiocb->ki_nr_segs =3D kiocb->ki_nbytes; kiocb->ki_cur_seg =3D 0; /* ki_nbytes/left now reflect bytes instead of segs */ -diff -urNp linux-3.1.4/fs/attr.c linux-3.1.4/fs/attr.c ---- linux-3.1.4/fs/attr.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/attr.c 2011-11-16 18:40:29.000000000 -0500 -@@ -98,6 +98,7 @@ int inode_newsize_ok(const struct inode=20 +diff --git a/fs/attr.c b/fs/attr.c +index 538e279..046cc6d 100644 +--- a/fs/attr.c ++++ b/fs/attr.c +@@ -98,6 +98,7 @@ int inode_newsize_ok(const struct inode *inode, loff_t= offset) unsigned long limit; =20 limit =3D rlimit(RLIMIT_FSIZE); @@ -40520,10 +41605,11 @@ diff -urNp linux-3.1.4/fs/attr.c linux-3.1.4/fs= /attr.c if (limit !=3D RLIM_INFINITY && offset > limit) goto out_sig; if (offset > inode->i_sb->s_maxbytes) -diff -urNp linux-3.1.4/fs/autofs4/waitq.c linux-3.1.4/fs/autofs4/waitq.c ---- linux-3.1.4/fs/autofs4/waitq.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/autofs4/waitq.c 2011-11-16 18:39:08.000000000 -0500 -@@ -60,7 +60,7 @@ static int autofs4_write(struct file *fi +diff --git a/fs/autofs4/waitq.c b/fs/autofs4/waitq.c +index e1fbdee..cd5ea56 100644 +--- a/fs/autofs4/waitq.c ++++ b/fs/autofs4/waitq.c +@@ -60,7 +60,7 @@ static int autofs4_write(struct file *file, const void= *addr, int bytes) { unsigned long sigpipe, flags; mm_segment_t fs; @@ -40532,10 +41618,11 @@ diff -urNp linux-3.1.4/fs/autofs4/waitq.c linux= -3.1.4/fs/autofs4/waitq.c ssize_t wr =3D 0; =20 /** WARNING: this is not safe for writing more than PIPE_BUF bytes! **= / -diff -urNp linux-3.1.4/fs/befs/linuxvfs.c linux-3.1.4/fs/befs/linuxvfs.c ---- linux-3.1.4/fs/befs/linuxvfs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/befs/linuxvfs.c 2011-11-16 18:39:08.000000000 -0500 -@@ -503,7 +503,7 @@ static void befs_put_link(struct dentry=20 +diff --git a/fs/befs/linuxvfs.c b/fs/befs/linuxvfs.c +index 720d885..012e7f0 100644 +--- a/fs/befs/linuxvfs.c ++++ b/fs/befs/linuxvfs.c +@@ -503,7 +503,7 @@ static void befs_put_link(struct dentry *dentry, str= uct nameidata *nd, void *p) { befs_inode_info *befs_ino =3D BEFS_I(dentry->d_inode); if (befs_ino->i_flags & BEFS_LONG_SYMLINK) { @@ -40544,9 +41631,10 @@ diff -urNp linux-3.1.4/fs/befs/linuxvfs.c linux-= 3.1.4/fs/befs/linuxvfs.c if (!IS_ERR(link)) kfree(link); } -diff -urNp linux-3.1.4/fs/binfmt_aout.c linux-3.1.4/fs/binfmt_aout.c ---- linux-3.1.4/fs/binfmt_aout.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/binfmt_aout.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/binfmt_aout.c b/fs/binfmt_aout.c +index a6395bd..a5b24c4 100644 +--- a/fs/binfmt_aout.c ++++ b/fs/binfmt_aout.c @@ -16,6 +16,7 @@ #include #include @@ -40555,7 +41643,7 @@ diff -urNp linux-3.1.4/fs/binfmt_aout.c linux-3.1= .4/fs/binfmt_aout.c #include #include #include -@@ -86,6 +87,8 @@ static int aout_core_dump(struct coredum +@@ -86,6 +87,8 @@ static int aout_core_dump(struct coredump_params *cprm= ) #endif # define START_STACK(u) ((void __user *)u.start_stack) =20 @@ -40564,7 +41652,7 @@ diff -urNp linux-3.1.4/fs/binfmt_aout.c linux-3.1= .4/fs/binfmt_aout.c fs =3D get_fs(); set_fs(KERNEL_DS); has_dumped =3D 1; -@@ -97,10 +100,12 @@ static int aout_core_dump(struct coredum +@@ -97,10 +100,12 @@ static int aout_core_dump(struct coredump_params *c= prm) =20 /* If the size of the dump file exceeds the rlimit, then see what would= happen if we wrote the stack, but not the data area. */ @@ -40577,7 +41665,7 @@ diff -urNp linux-3.1.4/fs/binfmt_aout.c linux-3.1= .4/fs/binfmt_aout.c if ((dump.u_ssize + 1) * PAGE_SIZE > cprm->limit) dump.u_ssize =3D 0; =20 -@@ -234,6 +239,8 @@ static int load_aout_binary(struct linux +@@ -234,6 +239,8 @@ static int load_aout_binary(struct linux_binprm * bp= rm, struct pt_regs * regs) rlim =3D rlimit(RLIMIT_DATA); if (rlim >=3D RLIM_INFINITY) rlim =3D ~0; @@ -40586,7 +41674,7 @@ diff -urNp linux-3.1.4/fs/binfmt_aout.c linux-3.1= .4/fs/binfmt_aout.c if (ex.a_data + ex.a_bss > rlim) return -ENOMEM; =20 -@@ -262,6 +269,27 @@ static int load_aout_binary(struct linux +@@ -262,6 +269,27 @@ static int load_aout_binary(struct linux_binprm * b= prm, struct pt_regs * regs) install_exec_creds(bprm); current->flags &=3D ~PF_FORKNOEXEC; =20 @@ -40614,7 +41702,7 @@ diff -urNp linux-3.1.4/fs/binfmt_aout.c linux-3.1= .4/fs/binfmt_aout.c if (N_MAGIC(ex) =3D=3D OMAGIC) { unsigned long text_addr, map_size; loff_t pos; -@@ -334,7 +362,7 @@ static int load_aout_binary(struct linux +@@ -334,7 +362,7 @@ static int load_aout_binary(struct linux_binprm * bp= rm, struct pt_regs * regs) =20 down_write(¤t->mm->mmap_sem); error =3D do_mmap(bprm->file, N_DATADDR(ex), ex.a_data, @@ -40623,10 +41711,11 @@ diff -urNp linux-3.1.4/fs/binfmt_aout.c linux-3= .1.4/fs/binfmt_aout.c MAP_FIXED | MAP_PRIVATE | MAP_DENYWRITE | MAP_EXECUTABLE, fd_offset + ex.a_text); up_write(¤t->mm->mmap_sem); -diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.4/fs/binfmt_elf.c ---- linux-3.1.4/fs/binfmt_elf.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/binfmt_elf.c 2011-11-16 18:40:29.000000000 -0500 -@@ -51,6 +51,10 @@ static int elf_core_dump(struct coredump +diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c +index 21ac5ee..171b1d0 100644 +--- a/fs/binfmt_elf.c ++++ b/fs/binfmt_elf.c +@@ -51,6 +51,10 @@ static int elf_core_dump(struct coredump_params *cprm= ); #define elf_core_dump NULL #endif =20 @@ -40637,7 +41726,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c #if ELF_EXEC_PAGESIZE > PAGE_SIZE #define ELF_MIN_ALIGN ELF_EXEC_PAGESIZE #else -@@ -70,6 +74,11 @@ static struct linux_binfmt elf_format =3D=20 +@@ -70,6 +74,11 @@ static struct linux_binfmt elf_format =3D { .load_binary =3D load_elf_binary, .load_shlib =3D load_elf_library, .core_dump =3D elf_core_dump, @@ -40649,7 +41738,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c .min_coredump =3D ELF_EXEC_PAGESIZE, }; =20 -@@ -77,6 +86,8 @@ static struct linux_binfmt elf_format =3D=20 +@@ -77,6 +86,8 @@ static struct linux_binfmt elf_format =3D { =20 static int set_brk(unsigned long start, unsigned long end) { @@ -40658,7 +41747,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c start =3D ELF_PAGEALIGN(start); end =3D ELF_PAGEALIGN(end); if (end > start) { -@@ -87,7 +98,7 @@ static int set_brk(unsigned long start,=20 +@@ -87,7 +98,7 @@ static int set_brk(unsigned long start, unsigned long = end) if (BAD_ADDR(addr)) return addr; } @@ -40667,7 +41756,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c return 0; } =20 -@@ -148,12 +159,15 @@ create_elf_tables(struct linux_binprm *b +@@ -148,12 +159,15 @@ create_elf_tables(struct linux_binprm *bprm, struc= t elfhdr *exec, elf_addr_t __user *u_rand_bytes; const char *k_platform =3D ELF_PLATFORM; const char *k_base_platform =3D ELF_BASE_PLATFORM; @@ -40684,7 +41773,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c =20 /* * In some cases (e.g. Hyper-Threading), we want to avoid L1 -@@ -195,8 +209,12 @@ create_elf_tables(struct linux_binprm *b +@@ -195,8 +209,12 @@ create_elf_tables(struct linux_binprm *bprm, struct= elfhdr *exec, * Generate 16 random bytes for userspace PRNG seeding. */ get_random_bytes(k_rand_bytes, sizeof(k_rand_bytes)); @@ -40699,7 +41788,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c if (__copy_to_user(u_rand_bytes, k_rand_bytes, sizeof(k_rand_bytes))) return -EFAULT; =20 -@@ -308,9 +326,11 @@ create_elf_tables(struct linux_binprm *b +@@ -308,9 +326,11 @@ create_elf_tables(struct linux_binprm *bprm, struct= elfhdr *exec, return -EFAULT; current->mm->env_end =3D p; =20 @@ -40712,7 +41801,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c return -EFAULT; return 0; } -@@ -381,10 +401,10 @@ static unsigned long load_elf_interp(str +@@ -381,10 +401,10 @@ static unsigned long load_elf_interp(struct elfhdr= *interp_elf_ex, { struct elf_phdr *elf_phdata; struct elf_phdr *eppnt; @@ -40725,7 +41814,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c unsigned long total_size; int retval, i, size; =20 -@@ -430,6 +450,11 @@ static unsigned long load_elf_interp(str +@@ -430,6 +450,11 @@ static unsigned long load_elf_interp(struct elfhdr = *interp_elf_ex, goto out_close; } =20 @@ -40737,7 +41826,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c eppnt =3D elf_phdata; for (i =3D 0; i < interp_elf_ex->e_phnum; i++, eppnt++) { if (eppnt->p_type =3D=3D PT_LOAD) { -@@ -473,8 +498,8 @@ static unsigned long load_elf_interp(str +@@ -473,8 +498,8 @@ static unsigned long load_elf_interp(struct elfhdr *= interp_elf_ex, k =3D load_addr + eppnt->p_vaddr; if (BAD_ADDR(k) || eppnt->p_filesz > eppnt->p_memsz || @@ -40942,7 +42031,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c /* * These are the functions used to load ELF style executables and share= d * libraries. There is no binary dependent code anywhere else. -@@ -544,6 +756,11 @@ static unsigned long randomize_stack_top +@@ -544,6 +756,11 @@ static unsigned long randomize_stack_top(unsigned l= ong stack_top) { unsigned int random_variable =3D 0; =20 @@ -40954,7 +42043,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c if ((current->flags & PF_RANDOMIZE) && !(current->personality & ADDR_NO_RANDOMIZE)) { random_variable =3D get_random_int() & STACK_RND_MASK; -@@ -562,7 +779,7 @@ static int load_elf_binary(struct linux_ +@@ -562,7 +779,7 @@ static int load_elf_binary(struct linux_binprm *bprm= , struct pt_regs *regs) unsigned long load_addr =3D 0, load_bias =3D 0; int load_addr_set =3D 0; char * elf_interpreter =3D NULL; @@ -40963,7 +42052,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c struct elf_phdr *elf_ppnt, *elf_phdata; unsigned long elf_bss, elf_brk; int retval, i; -@@ -572,11 +789,11 @@ static int load_elf_binary(struct linux_ +@@ -572,11 +789,11 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) unsigned long start_code, end_code, start_data, end_data; unsigned long reloc_func_desc __maybe_unused =3D 0; int executable_stack =3D EXSTACK_DEFAULT; @@ -40976,7 +42065,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c =20 loc =3D kmalloc(sizeof(*loc), GFP_KERNEL); if (!loc) { -@@ -713,11 +930,81 @@ static int load_elf_binary(struct linux_ +@@ -713,11 +930,81 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) =20 /* OK, This is the point of no return */ current->flags &=3D ~PF_FORKNOEXEC; @@ -41059,7 +42148,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c if (elf_read_implies_exec(loc->elf_ex, executable_stack)) current->personality |=3D READ_IMPLIES_EXEC; =20 -@@ -808,6 +1095,20 @@ static int load_elf_binary(struct linux_ +@@ -808,6 +1095,20 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) #else load_bias =3D ELF_PAGESTART(ELF_ET_DYN_BASE - vaddr); #endif @@ -41080,7 +42169,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c } =20 error =3D elf_map(bprm->file, load_bias + vaddr, elf_ppnt, -@@ -840,9 +1141,9 @@ static int load_elf_binary(struct linux_ +@@ -840,9 +1141,9 @@ static int load_elf_binary(struct linux_binprm *bpr= m, struct pt_regs *regs) * allowed task size. Note that p_filesz must always be * <=3D p_memsz so it is only necessary to check p_memsz. */ @@ -41093,7 +42182,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c /* set_brk can never work. Avoid overflows. */ send_sig(SIGKILL, current, 0); retval =3D -EINVAL; -@@ -870,6 +1171,11 @@ static int load_elf_binary(struct linux_ +@@ -870,6 +1171,11 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) start_data +=3D load_bias; end_data +=3D load_bias; =20 @@ -41105,7 +42194,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c /* Calling set_brk effectively mmaps the pages that we need * for the bss and break sections. We must do this before * mapping in the interpreter, to make sure it doesn't wind -@@ -881,9 +1187,11 @@ static int load_elf_binary(struct linux_ +@@ -881,9 +1187,11 @@ static int load_elf_binary(struct linux_binprm *bp= rm, struct pt_regs *regs) goto out_free_dentry; } if (likely(elf_bss !=3D elf_brk) && unlikely(padzero(elf_bss))) { @@ -41129,7 +42218,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c { #define FILTER(type) (mm_flags & (1UL << MMF_DUMP_##type)) =20 -@@ -1132,7 +1440,7 @@ static unsigned long vma_dump_size(struc +@@ -1132,7 +1440,7 @@ static unsigned long vma_dump_size(struct vm_area_= struct *vma, if (vma->vm_file =3D=3D NULL) return 0; =20 @@ -41138,7 +42227,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c goto whole; =20 /* -@@ -1354,9 +1662,9 @@ static void fill_auxv_note(struct memelf +@@ -1354,9 +1662,9 @@ static void fill_auxv_note(struct memelfnote *note= , struct mm_struct *mm) { elf_addr_t *auxv =3D (elf_addr_t *) mm->saved_auxv; int i =3D 0; @@ -41150,7 +42239,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c fill_note(note, "CORE", NT_AUXV, i * sizeof(elf_addr_t), auxv); } =20 -@@ -1862,14 +2170,14 @@ static void fill_extnum_info(struct elfh +@@ -1862,14 +2170,14 @@ static void fill_extnum_info(struct elfhdr *elf,= struct elf_shdr *shdr4extnum, } =20 static size_t elf_core_vma_data_size(struct vm_area_struct *gate_vma, @@ -41167,7 +42256,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c return size; } =20 -@@ -1963,7 +2271,7 @@ static int elf_core_dump(struct coredump +@@ -1963,7 +2271,7 @@ static int elf_core_dump(struct coredump_params *c= prm) =20 dataoff =3D offset =3D roundup(offset, ELF_EXEC_PAGESIZE); =20 @@ -41176,7 +42265,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c offset +=3D elf_core_extra_data_size(); e_shoff =3D offset; =20 -@@ -1977,10 +2285,12 @@ static int elf_core_dump(struct coredump +@@ -1977,10 +2285,12 @@ static int elf_core_dump(struct coredump_params = *cprm) offset =3D dataoff; =20 size +=3D sizeof(*elf); @@ -41189,7 +42278,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c if (size > cprm->limit || !dump_write(cprm->file, phdr4note, sizeof(*phdr4note))) goto end_coredump; -@@ -1994,7 +2304,7 @@ static int elf_core_dump(struct coredump +@@ -1994,7 +2304,7 @@ static int elf_core_dump(struct coredump_params *c= prm) phdr.p_offset =3D offset; phdr.p_vaddr =3D vma->vm_start; phdr.p_paddr =3D 0; @@ -41198,7 +42287,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c phdr.p_memsz =3D vma->vm_end - vma->vm_start; offset +=3D phdr.p_filesz; phdr.p_flags =3D vma->vm_flags & VM_READ ? PF_R : 0; -@@ -2005,6 +2315,7 @@ static int elf_core_dump(struct coredump +@@ -2005,6 +2315,7 @@ static int elf_core_dump(struct coredump_params *c= prm) phdr.p_align =3D ELF_EXEC_PAGESIZE; =20 size +=3D sizeof(phdr); @@ -41206,7 +42295,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c if (size > cprm->limit || !dump_write(cprm->file, &phdr, sizeof(phdr))) goto end_coredump; -@@ -2029,7 +2340,7 @@ static int elf_core_dump(struct coredump +@@ -2029,7 +2340,7 @@ static int elf_core_dump(struct coredump_params *c= prm) unsigned long addr; unsigned long end; =20 @@ -41215,7 +42304,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c =20 for (addr =3D vma->vm_start; addr < end; addr +=3D PAGE_SIZE) { struct page *page; -@@ -2038,6 +2349,7 @@ static int elf_core_dump(struct coredump +@@ -2038,6 +2349,7 @@ static int elf_core_dump(struct coredump_params *c= prm) page =3D get_dump_page(addr); if (page) { void *kaddr =3D kmap(page); @@ -41223,7 +42312,7 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.1.= 4/fs/binfmt_elf.c stop =3D ((size +=3D PAGE_SIZE) > cprm->limit) || !dump_write(cprm->file, kaddr, PAGE_SIZE); -@@ -2055,6 +2367,7 @@ static int elf_core_dump(struct coredump +@@ -2055,6 +2367,7 @@ static int elf_core_dump(struct coredump_params *c= prm) =20 if (e_phnum =3D=3D PN_XNUM) { size +=3D sizeof(*shdr4extnum); @@ -41329,10 +42418,11 @@ diff -urNp linux-3.1.4/fs/binfmt_elf.c linux-3.= 1.4/fs/binfmt_elf.c static int __init init_elf_binfmt(void) { return register_binfmt(&elf_format); -diff -urNp linux-3.1.4/fs/binfmt_flat.c linux-3.1.4/fs/binfmt_flat.c ---- linux-3.1.4/fs/binfmt_flat.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/binfmt_flat.c 2011-11-16 18:39:08.000000000 -0500 -@@ -567,7 +567,9 @@ static int load_flat_file(struct linux_b +diff --git a/fs/binfmt_flat.c b/fs/binfmt_flat.c +index 1bffbe0..c8c283e 100644 +--- a/fs/binfmt_flat.c ++++ b/fs/binfmt_flat.c +@@ -567,7 +567,9 @@ static int load_flat_file(struct linux_binprm * bprm= , realdatastart =3D (unsigned long) -ENOMEM; printk("Unable to allocate RAM for process data, errno %d\n", (int)-realdatastart); @@ -41342,7 +42432,7 @@ diff -urNp linux-3.1.4/fs/binfmt_flat.c linux-3.1= .4/fs/binfmt_flat.c ret =3D realdatastart; goto err; } -@@ -591,8 +593,10 @@ static int load_flat_file(struct linux_b +@@ -591,8 +593,10 @@ static int load_flat_file(struct linux_binprm * bpr= m, } if (IS_ERR_VALUE(result)) { printk("Unable to read data+bss, errno %d\n", (int)-result); @@ -41353,7 +42443,7 @@ diff -urNp linux-3.1.4/fs/binfmt_flat.c linux-3.1= .4/fs/binfmt_flat.c ret =3D result; goto err; } -@@ -661,8 +665,10 @@ static int load_flat_file(struct linux_b +@@ -661,8 +665,10 @@ static int load_flat_file(struct linux_binprm * bpr= m, } if (IS_ERR_VALUE(result)) { printk("Unable to read code+data+bss, errno %d\n",(int)-result); @@ -41364,10 +42454,11 @@ diff -urNp linux-3.1.4/fs/binfmt_flat.c linux-3= .1.4/fs/binfmt_flat.c ret =3D result; goto err; } -diff -urNp linux-3.1.4/fs/bio.c linux-3.1.4/fs/bio.c ---- linux-3.1.4/fs/bio.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/bio.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1233,7 +1233,7 @@ static void bio_copy_kern_endio(struct b +diff --git a/fs/bio.c b/fs/bio.c +index 9bfade8..782f3b9 100644 +--- a/fs/bio.c ++++ b/fs/bio.c +@@ -1233,7 +1233,7 @@ static void bio_copy_kern_endio(struct bio *bio, i= nt err) const int read =3D bio_data_dir(bio) =3D=3D READ; struct bio_map_data *bmd =3D bio->bi_private; int i; @@ -41376,10 +42467,11 @@ diff -urNp linux-3.1.4/fs/bio.c linux-3.1.4/fs/= bio.c =20 __bio_for_each_segment(bvec, bio, i, 0) { char *addr =3D page_address(bvec->bv_page); -diff -urNp linux-3.1.4/fs/block_dev.c linux-3.1.4/fs/block_dev.c ---- linux-3.1.4/fs/block_dev.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/block_dev.c 2011-11-16 18:39:08.000000000 -0500 -@@ -681,7 +681,7 @@ static bool bd_may_claim(struct block_de +diff --git a/fs/block_dev.c b/fs/block_dev.c +index 1c44b8d..e2507b4 100644 +--- a/fs/block_dev.c ++++ b/fs/block_dev.c +@@ -681,7 +681,7 @@ static bool bd_may_claim(struct block_device *bdev, = struct block_device *whole, else if (bdev->bd_contains =3D=3D bdev) return true; /* is a whole device which isn't held */ =20 @@ -41388,10 +42480,11 @@ diff -urNp linux-3.1.4/fs/block_dev.c linux-3.1= .4/fs/block_dev.c return true; /* is a partition of a device that is being partitione= d */ else if (whole->bd_holder !=3D NULL) return false; /* is a partition of a held device */ -diff -urNp linux-3.1.4/fs/btrfs/ctree.c linux-3.1.4/fs/btrfs/ctree.c ---- linux-3.1.4/fs/btrfs/ctree.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/btrfs/ctree.c 2011-11-16 18:39:08.000000000 -0500 -@@ -488,9 +488,12 @@ static noinline int __btrfs_cow_block(st +diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c +index 011cab3..9ace713 100644 +--- a/fs/btrfs/ctree.c ++++ b/fs/btrfs/ctree.c +@@ -488,9 +488,12 @@ static noinline int __btrfs_cow_block(struct btrfs_= trans_handle *trans, free_extent_buffer(buf); add_root_to_dirty_list(root); } else { @@ -41407,9 +42500,10 @@ diff -urNp linux-3.1.4/fs/btrfs/ctree.c linux-3.= 1.4/fs/btrfs/ctree.c parent_start =3D 0; =20 WARN_ON(trans->transid !=3D btrfs_header_generation(parent)); -diff -urNp linux-3.1.4/fs/btrfs/inode.c linux-3.1.4/fs/btrfs/inode.c ---- linux-3.1.4/fs/btrfs/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/btrfs/inode.c 2011-11-17 18:12:11.000000000 -0500 +diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c +index b2d004a..6bb543d 100644 +--- a/fs/btrfs/inode.c ++++ b/fs/btrfs/inode.c @@ -6922,7 +6922,7 @@ fail: return -ENOMEM; } @@ -41419,7 +42513,7 @@ diff -urNp linux-3.1.4/fs/btrfs/inode.c linux-3.1= .4/fs/btrfs/inode.c struct dentry *dentry, struct kstat *stat) { struct inode *inode =3D dentry->d_inode; -@@ -6934,6 +6934,14 @@ static int btrfs_getattr(struct vfsmount +@@ -6934,6 +6934,14 @@ static int btrfs_getattr(struct vfsmount *mnt, return 0; } =20 @@ -41434,10 +42528,11 @@ diff -urNp linux-3.1.4/fs/btrfs/inode.c linux-3= .1.4/fs/btrfs/inode.c /* * If a file is moved, it will inherit the cow and compression flags of= the new * directory. -diff -urNp linux-3.1.4/fs/btrfs/ioctl.c linux-3.1.4/fs/btrfs/ioctl.c ---- linux-3.1.4/fs/btrfs/ioctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/btrfs/ioctl.c 2011-11-16 18:40:29.000000000 -0500 -@@ -2704,9 +2704,12 @@ long btrfs_ioctl_space_info(struct btrfs +diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c +index dae5dfe..6aa01b1 100644 +--- a/fs/btrfs/ioctl.c ++++ b/fs/btrfs/ioctl.c +@@ -2704,9 +2704,12 @@ long btrfs_ioctl_space_info(struct btrfs_root *ro= ot, void __user *arg) for (i =3D 0; i < num_types; i++) { struct btrfs_space_info *tmp; =20 @@ -41450,7 +42545,7 @@ diff -urNp linux-3.1.4/fs/btrfs/ioctl.c linux-3.1= .4/fs/btrfs/ioctl.c info =3D NULL; rcu_read_lock(); list_for_each_entry_rcu(tmp, &root->fs_info->space_info, -@@ -2728,15 +2731,12 @@ long btrfs_ioctl_space_info(struct btrfs +@@ -2728,15 +2731,12 @@ long btrfs_ioctl_space_info(struct btrfs_root *r= oot, void __user *arg) memcpy(dest, &space, sizeof(space)); dest++; space_args.total_spaces++; @@ -41467,10 +42562,11 @@ diff -urNp linux-3.1.4/fs/btrfs/ioctl.c linux-3= .1.4/fs/btrfs/ioctl.c (arg + sizeof(struct btrfs_ioctl_space_args)); =20 if (copy_to_user(user_dest, dest_orig, alloc_size)) -diff -urNp linux-3.1.4/fs/btrfs/relocation.c linux-3.1.4/fs/btrfs/reloca= tion.c ---- linux-3.1.4/fs/btrfs/relocation.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/btrfs/relocation.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -1242,7 +1242,7 @@ static int __update_reloc_root(struct bt +diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c +index 59bb176..be9977d 100644 +--- a/fs/btrfs/relocation.c ++++ b/fs/btrfs/relocation.c +@@ -1242,7 +1242,7 @@ static int __update_reloc_root(struct btrfs_root *= root, int del) } spin_unlock(&rc->reloc_root_tree.lock); =20 @@ -41479,10 +42575,11 @@ diff -urNp linux-3.1.4/fs/btrfs/relocation.c li= nux-3.1.4/fs/btrfs/relocation.c =20 if (!del) { spin_lock(&rc->reloc_root_tree.lock); -diff -urNp linux-3.1.4/fs/cachefiles/bind.c linux-3.1.4/fs/cachefiles/bi= nd.c ---- linux-3.1.4/fs/cachefiles/bind.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cachefiles/bind.c 2011-11-16 18:39:08.000000000 -0500 -@@ -39,13 +39,11 @@ int cachefiles_daemon_bind(struct cachef +diff --git a/fs/cachefiles/bind.c b/fs/cachefiles/bind.c +index 622f469..e8d2d55 100644 +--- a/fs/cachefiles/bind.c ++++ b/fs/cachefiles/bind.c +@@ -39,13 +39,11 @@ int cachefiles_daemon_bind(struct cachefiles_cache *= cache, char *args) args); =20 /* start by checking things over */ @@ -41498,10 +42595,11 @@ diff -urNp linux-3.1.4/fs/cachefiles/bind.c lin= ux-3.1.4/fs/cachefiles/bind.c cache->bcull_percent < cache->brun_percent && cache->brun_percent < 100); =20 -diff -urNp linux-3.1.4/fs/cachefiles/daemon.c linux-3.1.4/fs/cachefiles/= daemon.c ---- linux-3.1.4/fs/cachefiles/daemon.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/fs/cachefiles/daemon.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -196,7 +196,7 @@ static ssize_t cachefiles_daemon_read(st +diff --git a/fs/cachefiles/daemon.c b/fs/cachefiles/daemon.c +index 0a1467b..6a53245 100644 +--- a/fs/cachefiles/daemon.c ++++ b/fs/cachefiles/daemon.c +@@ -196,7 +196,7 @@ static ssize_t cachefiles_daemon_read(struct file *f= ile, char __user *_buffer, if (n > buflen) return -EMSGSIZE; =20 @@ -41510,7 +42608,7 @@ diff -urNp linux-3.1.4/fs/cachefiles/daemon.c lin= ux-3.1.4/fs/cachefiles/daemon.c return -EFAULT; =20 return n; -@@ -222,7 +222,7 @@ static ssize_t cachefiles_daemon_write(s +@@ -222,7 +222,7 @@ static ssize_t cachefiles_daemon_write(struct file *= file, if (test_bit(CACHEFILES_DEAD, &cache->flags)) return -EIO; =20 @@ -41519,7 +42617,7 @@ diff -urNp linux-3.1.4/fs/cachefiles/daemon.c lin= ux-3.1.4/fs/cachefiles/daemon.c return -EOPNOTSUPP; =20 /* drag the command string into the kernel so we can parse it */ -@@ -386,7 +386,7 @@ static int cachefiles_daemon_fstop(struc +@@ -386,7 +386,7 @@ static int cachefiles_daemon_fstop(struct cachefiles= _cache *cache, char *args) if (args[0] !=3D '%' || args[1] !=3D '\0') return -EINVAL; =20 @@ -41528,7 +42626,7 @@ diff -urNp linux-3.1.4/fs/cachefiles/daemon.c lin= ux-3.1.4/fs/cachefiles/daemon.c return cachefiles_daemon_range_error(cache, args); =20 cache->fstop_percent =3D fstop; -@@ -458,7 +458,7 @@ static int cachefiles_daemon_bstop(struc +@@ -458,7 +458,7 @@ static int cachefiles_daemon_bstop(struct cachefiles= _cache *cache, char *args) if (args[0] !=3D '%' || args[1] !=3D '\0') return -EINVAL; =20 @@ -41537,9 +42635,10 @@ diff -urNp linux-3.1.4/fs/cachefiles/daemon.c li= nux-3.1.4/fs/cachefiles/daemon.c return cachefiles_daemon_range_error(cache, args); =20 cache->bstop_percent =3D bstop; -diff -urNp linux-3.1.4/fs/cachefiles/internal.h linux-3.1.4/fs/cachefile= s/internal.h ---- linux-3.1.4/fs/cachefiles/internal.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/fs/cachefiles/internal.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/fs/cachefiles/internal.h b/fs/cachefiles/internal.h +index bd6bc1b..b627b53 100644 +--- a/fs/cachefiles/internal.h ++++ b/fs/cachefiles/internal.h @@ -57,7 +57,7 @@ struct cachefiles_cache { wait_queue_head_t daemon_pollwq; /* poll waitqueue for daemon */ struct rb_root active_nodes; /* active nodes (can't be culled) */ @@ -41549,7 +42648,7 @@ diff -urNp linux-3.1.4/fs/cachefiles/internal.h l= inux-3.1.4/fs/cachefiles/intern unsigned frun_percent; /* when to stop culling (% files) */ unsigned fcull_percent; /* when to start culling (% files) */ unsigned fstop_percent; /* when to stop allocating (% files) */ -@@ -169,19 +169,19 @@ extern int cachefiles_check_in_use(struc +@@ -169,19 +169,19 @@ extern int cachefiles_check_in_use(struct cachefil= es_cache *cache, * proc.c */ #ifdef CONFIG_CACHEFILES_HISTOGRAM @@ -41574,9 +42673,10 @@ diff -urNp linux-3.1.4/fs/cachefiles/internal.h = linux-3.1.4/fs/cachefiles/intern } =20 #else -diff -urNp linux-3.1.4/fs/cachefiles/namei.c linux-3.1.4/fs/cachefiles/n= amei.c ---- linux-3.1.4/fs/cachefiles/namei.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/cachefiles/namei.c 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/fs/cachefiles/namei.c b/fs/cachefiles/namei.c +index a0358c2..d6137f2 100644 +--- a/fs/cachefiles/namei.c ++++ b/fs/cachefiles/namei.c @@ -318,7 +318,7 @@ try_again: /* first step is to make up a grave dentry in the graveyard */ sprintf(nbuffer, "%08x%08x", @@ -41586,9 +42686,10 @@ diff -urNp linux-3.1.4/fs/cachefiles/namei.c lin= ux-3.1.4/fs/cachefiles/namei.c =20 /* do the multiway lock magic */ trap =3D lock_rename(cache->graveyard, dir); -diff -urNp linux-3.1.4/fs/cachefiles/proc.c linux-3.1.4/fs/cachefiles/pr= oc.c ---- linux-3.1.4/fs/cachefiles/proc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cachefiles/proc.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/cachefiles/proc.c b/fs/cachefiles/proc.c +index eccd339..4c1d995 100644 +--- a/fs/cachefiles/proc.c ++++ b/fs/cachefiles/proc.c @@ -14,9 +14,9 @@ #include #include "internal.h" @@ -41602,7 +42703,7 @@ diff -urNp linux-3.1.4/fs/cachefiles/proc.c linux= -3.1.4/fs/cachefiles/proc.c =20 /* * display the latency histogram -@@ -35,9 +35,9 @@ static int cachefiles_histogram_show(str +@@ -35,9 +35,9 @@ static int cachefiles_histogram_show(struct seq_file *= m, void *v) return 0; default: index =3D (unsigned long) v - 3; @@ -41615,10 +42716,11 @@ diff -urNp linux-3.1.4/fs/cachefiles/proc.c lin= ux-3.1.4/fs/cachefiles/proc.c if (x =3D=3D 0 && y =3D=3D 0 && z =3D=3D 0) return 0; =20 -diff -urNp linux-3.1.4/fs/cachefiles/rdwr.c linux-3.1.4/fs/cachefiles/rd= wr.c ---- linux-3.1.4/fs/cachefiles/rdwr.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cachefiles/rdwr.c 2011-11-16 18:39:08.000000000 -0500 -@@ -945,7 +945,7 @@ int cachefiles_write_page(struct fscache +diff --git a/fs/cachefiles/rdwr.c b/fs/cachefiles/rdwr.c +index 0e3c092..818480e 100644 +--- a/fs/cachefiles/rdwr.c ++++ b/fs/cachefiles/rdwr.c +@@ -945,7 +945,7 @@ int cachefiles_write_page(struct fscache_storage *op= , struct page *page) old_fs =3D get_fs(); set_fs(KERNEL_DS); ret =3D file->f_op->write( @@ -41627,10 +42729,11 @@ diff -urNp linux-3.1.4/fs/cachefiles/rdwr.c lin= ux-3.1.4/fs/cachefiles/rdwr.c set_fs(old_fs); kunmap(page); if (ret !=3D len) -diff -urNp linux-3.1.4/fs/ceph/dir.c linux-3.1.4/fs/ceph/dir.c ---- linux-3.1.4/fs/ceph/dir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ceph/dir.c 2011-11-16 18:39:08.000000000 -0500 -@@ -244,7 +244,7 @@ static int ceph_readdir(struct file *fil +diff --git a/fs/ceph/dir.c b/fs/ceph/dir.c +index 382abc9..bd89646 100644 +--- a/fs/ceph/dir.c ++++ b/fs/ceph/dir.c +@@ -244,7 +244,7 @@ static int ceph_readdir(struct file *filp, void *dir= ent, filldir_t filldir) struct ceph_fs_client *fsc =3D ceph_inode_to_client(inode); struct ceph_mds_client *mdsc =3D fsc->mdsc; unsigned frag =3D fpos_frag(filp->f_pos); @@ -41639,10 +42742,11 @@ diff -urNp linux-3.1.4/fs/ceph/dir.c linux-3.1.= 4/fs/ceph/dir.c int err; u32 ftype; struct ceph_mds_reply_info_parsed *rinfo; -diff -urNp linux-3.1.4/fs/cifs/cifs_debug.c linux-3.1.4/fs/cifs/cifs_deb= ug.c ---- linux-3.1.4/fs/cifs/cifs_debug.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cifs/cifs_debug.c 2011-11-16 18:39:08.000000000 -0500 -@@ -265,8 +265,8 @@ static ssize_t cifs_stats_proc_write(str +diff --git a/fs/cifs/cifs_debug.c b/fs/cifs/cifs_debug.c +index 6d40656..bc1f825 100644 +--- a/fs/cifs/cifs_debug.c ++++ b/fs/cifs/cifs_debug.c +@@ -265,8 +265,8 @@ static ssize_t cifs_stats_proc_write(struct file *fi= le, =20 if (c =3D=3D '1' || c =3D=3D 'y' || c =3D=3D 'Y' || c =3D=3D '0') { #ifdef CONFIG_CIFS_STATS2 @@ -41653,7 +42757,7 @@ diff -urNp linux-3.1.4/fs/cifs/cifs_debug.c linux= -3.1.4/fs/cifs/cifs_debug.c #endif /* CONFIG_CIFS_STATS2 */ spin_lock(&cifs_tcp_ses_lock); list_for_each(tmp1, &cifs_tcp_ses_list) { -@@ -279,25 +279,25 @@ static ssize_t cifs_stats_proc_write(str +@@ -279,25 +279,25 @@ static ssize_t cifs_stats_proc_write(struct file *= file, tcon =3D list_entry(tmp3, struct cifs_tcon, tcon_list); @@ -41698,7 +42802,7 @@ diff -urNp linux-3.1.4/fs/cifs/cifs_debug.c linux= -3.1.4/fs/cifs/cifs_debug.c } } } -@@ -327,8 +327,8 @@ static int cifs_stats_proc_show(struct s +@@ -327,8 +327,8 @@ static int cifs_stats_proc_show(struct seq_file *m, = void *v) smBufAllocCount.counter, cifs_min_small); #ifdef CONFIG_CIFS_STATS2 seq_printf(m, "Total Large %d Small %d Allocations\n", @@ -41709,7 +42813,7 @@ diff -urNp linux-3.1.4/fs/cifs/cifs_debug.c linux= -3.1.4/fs/cifs/cifs_debug.c #endif /* CONFIG_CIFS_STATS2 */ =20 seq_printf(m, "Operations (MIDs): %d\n", atomic_read(&midCount)); -@@ -357,41 +357,41 @@ static int cifs_stats_proc_show(struct s +@@ -357,41 +357,41 @@ static int cifs_stats_proc_show(struct seq_file *m= , void *v) if (tcon->need_reconnect) seq_puts(m, "\tDISCONNECTED "); seq_printf(m, "\nSMBs: %d Oplock Breaks: %d", @@ -41771,9 +42875,10 @@ diff -urNp linux-3.1.4/fs/cifs/cifs_debug.c linu= x-3.1.4/fs/cifs/cifs_debug.c } } } -diff -urNp linux-3.1.4/fs/cifs/cifsfs.c linux-3.1.4/fs/cifs/cifsfs.c ---- linux-3.1.4/fs/cifs/cifsfs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cifs/cifsfs.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c +index 54b8f1e..f6a4c00 100644 +--- a/fs/cifs/cifsfs.c ++++ b/fs/cifs/cifsfs.c @@ -981,7 +981,7 @@ cifs_init_request_bufs(void) cifs_req_cachep =3D kmem_cache_create("cifs_request", CIFSMaxBufSize + @@ -41803,9 +42908,10 @@ diff -urNp linux-3.1.4/fs/cifs/cifsfs.c linux-3.= 1.4/fs/cifs/cifsfs.c #endif /* CONFIG_CIFS_STATS2 */ =20 atomic_set(&midCount, 0); -diff -urNp linux-3.1.4/fs/cifs/cifsglob.h linux-3.1.4/fs/cifs/cifsglob.h ---- linux-3.1.4/fs/cifs/cifsglob.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cifs/cifsglob.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h +index 95dad9d..fe7af1a 100644 +--- a/fs/cifs/cifsglob.h ++++ b/fs/cifs/cifsglob.h @@ -381,28 +381,28 @@ struct cifs_tcon { __u16 Flags; /* optional support bits */ enum statusEnum tidStatus; @@ -41857,7 +42963,7 @@ diff -urNp linux-3.1.4/fs/cifs/cifsglob.h linux-3= .1.4/fs/cifs/cifsglob.h #ifdef CONFIG_CIFS_STATS2 unsigned long long time_writes; unsigned long long time_reads; -@@ -613,7 +613,7 @@ convert_delimiter(char *path, char delim +@@ -613,7 +613,7 @@ convert_delimiter(char *path, char delim) } =20 #ifdef CONFIG_CIFS_STATS @@ -41866,7 +42972,7 @@ diff -urNp linux-3.1.4/fs/cifs/cifsglob.h linux-3= .1.4/fs/cifs/cifsglob.h =20 static inline void cifs_stats_bytes_written(struct cifs_tcon *tcon, unsigned int bytes) -@@ -953,8 +953,8 @@ GLOBAL_EXTERN atomic_t tconInfoReconnect +@@ -953,8 +953,8 @@ GLOBAL_EXTERN atomic_t tconInfoReconnectCount; /* Various Debug counters */ GLOBAL_EXTERN atomic_t bufAllocCount; /* current number allocated *= / #ifdef CONFIG_CIFS_STATS2 @@ -41877,9 +42983,10 @@ diff -urNp linux-3.1.4/fs/cifs/cifsglob.h linux-= 3.1.4/fs/cifs/cifsglob.h #endif GLOBAL_EXTERN atomic_t smBufAllocCount; GLOBAL_EXTERN atomic_t midCount; -diff -urNp linux-3.1.4/fs/cifs/link.c linux-3.1.4/fs/cifs/link.c ---- linux-3.1.4/fs/cifs/link.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cifs/link.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/cifs/link.c b/fs/cifs/link.c +index db3f18c..1f5955e 100644 +--- a/fs/cifs/link.c ++++ b/fs/cifs/link.c @@ -593,7 +593,7 @@ symlink_exit: =20 void cifs_put_link(struct dentry *direntry, struct nameidata *nd, void = *cookie) @@ -41889,9 +42996,10 @@ diff -urNp linux-3.1.4/fs/cifs/link.c linux-3.1.= 4/fs/cifs/link.c if (!IS_ERR(p)) kfree(p); } -diff -urNp linux-3.1.4/fs/cifs/misc.c linux-3.1.4/fs/cifs/misc.c ---- linux-3.1.4/fs/cifs/misc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/cifs/misc.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/cifs/misc.c b/fs/cifs/misc.c +index 7c16933..c8212b5 100644 +--- a/fs/cifs/misc.c ++++ b/fs/cifs/misc.c @@ -156,7 +156,7 @@ cifs_buf_get(void) memset(ret_buf, 0, sizeof(struct smb_hdr) + 3); atomic_inc(&bufAllocCount); @@ -41910,9 +43018,10 @@ diff -urNp linux-3.1.4/fs/cifs/misc.c linux-3.1.= 4/fs/cifs/misc.c #endif /* CONFIG_CIFS_STATS2 */ =20 } -diff -urNp linux-3.1.4/fs/coda/cache.c linux-3.1.4/fs/coda/cache.c ---- linux-3.1.4/fs/coda/cache.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/coda/cache.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/coda/cache.c b/fs/coda/cache.c +index 6901578..d402eb5 100644 +--- a/fs/coda/cache.c ++++ b/fs/coda/cache.c @@ -24,7 +24,7 @@ #include "coda_linux.h" #include "coda_cache.h" @@ -41922,7 +43031,7 @@ diff -urNp linux-3.1.4/fs/coda/cache.c linux-3.1.= 4/fs/coda/cache.c =20 /* replace or extend an acl cache hit */ void coda_cache_enter(struct inode *inode, int mask) -@@ -32,7 +32,7 @@ void coda_cache_enter(struct inode *inod +@@ -32,7 +32,7 @@ void coda_cache_enter(struct inode *inode, int mask) struct coda_inode_info *cii =3D ITOC(inode); =20 spin_lock(&cii->c_lock); @@ -41931,7 +43040,7 @@ diff -urNp linux-3.1.4/fs/coda/cache.c linux-3.1.= 4/fs/coda/cache.c if (cii->c_uid !=3D current_fsuid()) { cii->c_uid =3D current_fsuid(); cii->c_cached_perm =3D mask; -@@ -46,14 +46,14 @@ void coda_cache_clear_inode(struct inode +@@ -46,14 +46,14 @@ void coda_cache_clear_inode(struct inode *inode) { struct coda_inode_info *cii =3D ITOC(inode); spin_lock(&cii->c_lock); @@ -41948,7 +43057,7 @@ diff -urNp linux-3.1.4/fs/coda/cache.c linux-3.1.= 4/fs/coda/cache.c } =20 =20 -@@ -66,7 +66,7 @@ int coda_cache_check(struct inode *inode +@@ -66,7 +66,7 @@ int coda_cache_check(struct inode *inode, int mask) spin_lock(&cii->c_lock); hit =3D (mask & cii->c_cached_perm) =3D=3D mask && cii->c_uid =3D=3D current_fsuid() && @@ -41957,27 +43066,11 @@ diff -urNp linux-3.1.4/fs/coda/cache.c linux-3.= 1.4/fs/coda/cache.c spin_unlock(&cii->c_lock); =20 return hit; -diff -urNp linux-3.1.4/fs/compat_binfmt_elf.c linux-3.1.4/fs/compat_binf= mt_elf.c ---- linux-3.1.4/fs/compat_binfmt_elf.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/fs/compat_binfmt_elf.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -30,11 +30,13 @@ - #undef elf_phdr - #undef elf_shdr - #undef elf_note -+#undef elf_dyn - #undef elf_addr_t - #define elfhdr elf32_hdr - #define elf_phdr elf32_phdr - #define elf_shdr elf32_shdr - #define elf_note elf32_note -+#define elf_dyn Elf32_Dyn - #define elf_addr_t Elf32_Addr -=20 - /* -diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs/compat.c ---- linux-3.1.4/fs/compat.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/compat.c 2011-11-16 18:40:29.000000000 -0500 -@@ -133,8 +133,8 @@ asmlinkage long compat_sys_utimes(const=20 +diff --git a/fs/compat.c b/fs/compat.c +index 58b1da4..afcd9b8 100644 +--- a/fs/compat.c ++++ b/fs/compat.c +@@ -133,8 +133,8 @@ asmlinkage long compat_sys_utimes(const char __user = *filename, struct compat_tim static int cp_compat_stat(struct kstat *stat, struct compat_stat __user= *ubuf) { compat_ino_t ino =3D stat->ino; @@ -41988,7 +43081,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c int err; =20 SET_UID(uid, stat->uid); -@@ -508,7 +508,7 @@ compat_sys_io_setup(unsigned nr_reqs, u3 +@@ -508,7 +508,7 @@ compat_sys_io_setup(unsigned nr_reqs, u32 __user *ct= x32p) =20 set_fs(KERNEL_DS); /* The __user pointer cast is valid because of the set_fs() */ @@ -41997,7 +43090,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c set_fs(oldfs); /* truncating is ok because it's a user address */ if (!ret) -@@ -566,7 +566,7 @@ ssize_t compat_rw_copy_check_uvector(int +@@ -566,7 +566,7 @@ ssize_t compat_rw_copy_check_uvector(int type, goto out; =20 ret =3D -EINVAL; @@ -42014,7 +43107,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c int result; }; =20 -@@ -865,6 +866,10 @@ static int compat_fillonedir(void *__buf +@@ -865,6 +866,10 @@ static int compat_fillonedir(void *__buf, const cha= r *name, int namlen, buf->result =3D -EOVERFLOW; return -EOVERFLOW; } @@ -42025,7 +43118,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c buf->result++; dirent =3D buf->dirent; if (!access_ok(VERIFY_WRITE, dirent, -@@ -897,6 +902,7 @@ asmlinkage long compat_sys_old_readdir(u +@@ -897,6 +902,7 @@ asmlinkage long compat_sys_old_readdir(unsigned int = fd, =20 buf.result =3D 0; buf.dirent =3D dirent; @@ -42041,7 +43134,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c int count; int error; }; -@@ -938,6 +945,10 @@ static int compat_filldir(void *__buf, c +@@ -938,6 +945,10 @@ static int compat_filldir(void *__buf, const char *= name, int namlen, buf->error =3D -EOVERFLOW; return -EOVERFLOW; } @@ -42052,7 +43145,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c dirent =3D buf->previous; if (dirent) { if (__put_user(offset, &dirent->d_off)) -@@ -985,6 +996,7 @@ asmlinkage long compat_sys_getdents(unsi +@@ -985,6 +996,7 @@ asmlinkage long compat_sys_getdents(unsigned int fd, buf.previous =3D NULL; buf.count =3D count; buf.error =3D 0; @@ -42068,7 +43161,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c int count; int error; }; -@@ -1022,6 +1035,10 @@ static int compat_filldir64(void * __buf +@@ -1022,6 +1035,10 @@ static int compat_filldir64(void * __buf, const c= har * name, int namlen, loff_t buf->error =3D -EINVAL; /* only used if we fail.. */ if (reclen > buf->count) return -EINVAL; @@ -42079,7 +43172,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c dirent =3D buf->previous; =20 if (dirent) { -@@ -1073,13 +1090,14 @@ asmlinkage long compat_sys_getdents64(un +@@ -1073,13 +1090,14 @@ asmlinkage long compat_sys_getdents64(unsigned i= nt fd, buf.previous =3D NULL; buf.count =3D count; buf.error =3D 0; @@ -42095,7 +43188,7 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/fs= /compat.c if (__put_user_unaligned(d_off, &lastdirent->d_off)) error =3D -EFAULT; else -@@ -1446,6 +1464,8 @@ int compat_core_sys_select(int n, compat +@@ -1446,6 +1464,8 @@ int compat_core_sys_select(int n, compat_ulong_t _= _user *inp, struct fdtable *fdt; long stack_fds[SELECT_STACK_ALLOC/sizeof(long)]; =20 @@ -42104,10 +43197,29 @@ diff -urNp linux-3.1.4/fs/compat.c linux-3.1.4/= fs/compat.c if (n < 0) goto out_nofds; =20 -diff -urNp linux-3.1.4/fs/compat_ioctl.c linux-3.1.4/fs/compat_ioctl.c ---- linux-3.1.4/fs/compat_ioctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/compat_ioctl.c 2011-11-16 18:39:08.000000000 -0500 -@@ -210,6 +210,8 @@ static int do_video_set_spu_palette(unsi +diff --git a/fs/compat_binfmt_elf.c b/fs/compat_binfmt_elf.c +index 112e45a..b59845b 100644 +--- a/fs/compat_binfmt_elf.c ++++ b/fs/compat_binfmt_elf.c +@@ -30,11 +30,13 @@ + #undef elf_phdr + #undef elf_shdr + #undef elf_note ++#undef elf_dyn + #undef elf_addr_t + #define elfhdr elf32_hdr + #define elf_phdr elf32_phdr + #define elf_shdr elf32_shdr + #define elf_note elf32_note ++#define elf_dyn Elf32_Dyn + #define elf_addr_t Elf32_Addr +=20 + /* +diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c +index 51352de..93292ff 100644 +--- a/fs/compat_ioctl.c ++++ b/fs/compat_ioctl.c +@@ -210,6 +210,8 @@ static int do_video_set_spu_palette(unsigned int fd,= unsigned int cmd, =20 err =3D get_user(palp, &up->palette); err |=3D get_user(length, &up->length); @@ -42116,7 +43228,7 @@ diff -urNp linux-3.1.4/fs/compat_ioctl.c linux-3.= 1.4/fs/compat_ioctl.c =20 up_native =3D compat_alloc_user_space(sizeof(struct video_spu_palette)= ); err =3D put_user(compat_ptr(palp), &up_native->palette); -@@ -621,7 +623,7 @@ static int serial_struct_ioctl(unsigned=20 +@@ -621,7 +623,7 @@ static int serial_struct_ioctl(unsigned fd, unsigned= cmd, return -EFAULT; if (__get_user(udata, &ss32->iomem_base)) return -EFAULT; @@ -42125,7 +43237,7 @@ diff -urNp linux-3.1.4/fs/compat_ioctl.c linux-3.= 1.4/fs/compat_ioctl.c if (__get_user(ss.iomem_reg_shift, &ss32->iomem_reg_shi= ft) || __get_user(ss.port_high, &ss32->port_high)) return -EFAULT; -@@ -796,7 +798,7 @@ static int compat_ioctl_preallocate(stru +@@ -796,7 +798,7 @@ static int compat_ioctl_preallocate(struct file *fil= e, copy_in_user(&p->l_len, &p32->l_len, sizeof(s64)) || copy_in_user(&p->l_sysid, &p32->l_sysid, sizeof(s32)) || copy_in_user(&p->l_pid, &p32->l_pid, sizeof(u32)) || @@ -42134,7 +43246,7 @@ diff -urNp linux-3.1.4/fs/compat_ioctl.c linux-3.= 1.4/fs/compat_ioctl.c return -EFAULT; =20 return ioctl_preallocate(file, p); -@@ -1644,8 +1646,8 @@ asmlinkage long compat_sys_ioctl(unsigne +@@ -1644,8 +1646,8 @@ asmlinkage long compat_sys_ioctl(unsigned int fd, = unsigned int cmd, static int __init init_sys32_ioctl_cmp(const void *p, const void *q) { unsigned int a, b; @@ -42145,10 +43257,11 @@ diff -urNp linux-3.1.4/fs/compat_ioctl.c linux-= 3.1.4/fs/compat_ioctl.c if (a > b) return 1; if (a < b) -diff -urNp linux-3.1.4/fs/configfs/dir.c linux-3.1.4/fs/configfs/dir.c ---- linux-3.1.4/fs/configfs/dir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/configfs/dir.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1575,7 +1575,8 @@ static int configfs_readdir(struct file=20 +diff --git a/fs/configfs/dir.c b/fs/configfs/dir.c +index 9a37a9b..35792b6 100644 +--- a/fs/configfs/dir.c ++++ b/fs/configfs/dir.c +@@ -1575,7 +1575,8 @@ static int configfs_readdir(struct file * filp, vo= id * dirent, filldir_t filldir } for (p=3Dq->next; p!=3D &parent_sd->s_children; p=3Dp->next) { struct configfs_dirent *next; @@ -42158,7 +43271,7 @@ diff -urNp linux-3.1.4/fs/configfs/dir.c linux-3.= 1.4/fs/configfs/dir.c int len; struct inode *inode =3D NULL; =20 -@@ -1585,7 +1586,12 @@ static int configfs_readdir(struct file=20 +@@ -1585,7 +1586,12 @@ static int configfs_readdir(struct file * filp, v= oid * dirent, filldir_t filldir continue; =20 name =3D configfs_get_name(next); @@ -42172,10 +43285,11 @@ diff -urNp linux-3.1.4/fs/configfs/dir.c linux-= 3.1.4/fs/configfs/dir.c =20 /* * We'll have a dentry and an inode for -diff -urNp linux-3.1.4/fs/dcache.c linux-3.1.4/fs/dcache.c ---- linux-3.1.4/fs/dcache.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/dcache.c 2011-11-16 18:39:08.000000000 -0500 -@@ -2998,7 +2998,7 @@ void __init vfs_caches_init(unsigned lon +diff --git a/fs/dcache.c b/fs/dcache.c +index a88948b..1e32160 100644 +--- a/fs/dcache.c ++++ b/fs/dcache.c +@@ -2998,7 +2998,7 @@ void __init vfs_caches_init(unsigned long mempages= ) mempages -=3D reserve; =20 names_cachep =3D kmem_cache_create("names_cache", PATH_MAX, 0, @@ -42184,10 +43298,11 @@ diff -urNp linux-3.1.4/fs/dcache.c linux-3.1.4/= fs/dcache.c =20 dcache_init(); inode_init(); -diff -urNp linux-3.1.4/fs/ecryptfs/inode.c linux-3.1.4/fs/ecryptfs/inode= .c ---- linux-3.1.4/fs/ecryptfs/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ecryptfs/inode.c 2011-11-16 18:39:08.000000000 -0500 -@@ -681,7 +681,7 @@ static int ecryptfs_readlink_lower(struc +diff --git a/fs/ecryptfs/inode.c b/fs/ecryptfs/inode.c +index 11f8582..7b633bd 100644 +--- a/fs/ecryptfs/inode.c ++++ b/fs/ecryptfs/inode.c +@@ -681,7 +681,7 @@ static int ecryptfs_readlink_lower(struct dentry *de= ntry, char **buf, old_fs =3D get_fs(); set_fs(get_ds()); rc =3D lower_dentry->d_inode->i_op->readlink(lower_dentry, @@ -42196,7 +43311,7 @@ diff -urNp linux-3.1.4/fs/ecryptfs/inode.c linux-= 3.1.4/fs/ecryptfs/inode.c lower_bufsiz); set_fs(old_fs); if (rc < 0) -@@ -727,7 +727,7 @@ static void *ecryptfs_follow_link(struct +@@ -727,7 +727,7 @@ static void *ecryptfs_follow_link(struct dentry *den= try, struct nameidata *nd) } old_fs =3D get_fs(); set_fs(get_ds()); @@ -42214,9 +43329,10 @@ diff -urNp linux-3.1.4/fs/ecryptfs/inode.c linux= -3.1.4/fs/ecryptfs/inode.c if (!IS_ERR(buf)) { /* Free the char* */ kfree(buf); -diff -urNp linux-3.1.4/fs/ecryptfs/miscdev.c linux-3.1.4/fs/ecryptfs/mis= cdev.c ---- linux-3.1.4/fs/ecryptfs/miscdev.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/ecryptfs/miscdev.c 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/fs/ecryptfs/miscdev.c b/fs/ecryptfs/miscdev.c +index 940a82e..63af89e 100644 +--- a/fs/ecryptfs/miscdev.c ++++ b/fs/ecryptfs/miscdev.c @@ -328,7 +328,7 @@ check_list: goto out_unlock_msg_ctx; i =3D 5; @@ -42226,10 +43342,11 @@ diff -urNp linux-3.1.4/fs/ecryptfs/miscdev.c li= nux-3.1.4/fs/ecryptfs/miscdev.c goto out_unlock_msg_ctx; i +=3D packet_length_size; if (copy_to_user(&buf[i], msg_ctx->msg, msg_ctx->msg_size)) -diff -urNp linux-3.1.4/fs/ecryptfs/read_write.c linux-3.1.4/fs/ecryptfs/= read_write.c ---- linux-3.1.4/fs/ecryptfs/read_write.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/fs/ecryptfs/read_write.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -48,7 +48,7 @@ int ecryptfs_write_lower(struct inode *e +diff --git a/fs/ecryptfs/read_write.c b/fs/ecryptfs/read_write.c +index 3745f7c..89cc7a3 100644 +--- a/fs/ecryptfs/read_write.c ++++ b/fs/ecryptfs/read_write.c +@@ -48,7 +48,7 @@ int ecryptfs_write_lower(struct inode *ecryptfs_inode,= char *data, return -EIO; fs_save =3D get_fs(); set_fs(get_ds()); @@ -42238,7 +43355,7 @@ diff -urNp linux-3.1.4/fs/ecryptfs/read_write.c l= inux-3.1.4/fs/ecryptfs/read_wri set_fs(fs_save); mark_inode_dirty_sync(ecryptfs_inode); return rc; -@@ -235,7 +235,7 @@ int ecryptfs_read_lower(char *data, loff +@@ -235,7 +235,7 @@ int ecryptfs_read_lower(char *data, loff_t offset, s= ize_t size, return -EIO; fs_save =3D get_fs(); set_fs(get_ds()); @@ -42247,9 +43364,10 @@ diff -urNp linux-3.1.4/fs/ecryptfs/read_write.c = linux-3.1.4/fs/ecryptfs/read_wri set_fs(fs_save); return rc; } -diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/exec.c ---- linux-3.1.4/fs/exec.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/exec.c 2011-11-17 18:40:47.000000000 -0500 +diff --git a/fs/exec.c b/fs/exec.c +index 25dcbe5..4ffaa78 100644 +--- a/fs/exec.c ++++ b/fs/exec.c @@ -55,12 +55,24 @@ #include #include @@ -42284,7 +43402,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c =20 /* The maximal length of core_pattern is also specified in sysctl.c */ =20 -@@ -188,18 +200,10 @@ static struct page *get_arg_page(struct=20 +@@ -188,18 +200,10 @@ static struct page *get_arg_page(struct linux_binp= rm *bprm, unsigned long pos, int write) { struct page *page; @@ -42306,7 +43424,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c return NULL; =20 if (write) { -@@ -274,6 +278,11 @@ static int __bprm_mm_init(struct linux_b +@@ -274,6 +278,11 @@ static int __bprm_mm_init(struct linux_binprm *bprm= ) vma->vm_end =3D STACK_TOP_MAX; vma->vm_start =3D vma->vm_end - PAGE_SIZE; vma->vm_flags =3D VM_STACK_FLAGS | VM_STACK_INCOMPLETE_SETUP; @@ -42318,7 +43436,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c vma->vm_page_prot =3D vm_get_page_prot(vma->vm_flags); INIT_LIST_HEAD(&vma->anon_vma_chain); =20 -@@ -288,6 +297,12 @@ static int __bprm_mm_init(struct linux_b +@@ -288,6 +297,12 @@ static int __bprm_mm_init(struct linux_binprm *bprm= ) mm->stack_vm =3D mm->total_vm =3D 1; up_write(&mm->mmap_sem); bprm->p =3D vma->vm_end - sizeof(void *); @@ -42352,7 +43470,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c { const char __user *native; =20 -@@ -417,14 +420,14 @@ static const char __user *get_user_arg_p +@@ -417,14 +420,14 @@ static const char __user *get_user_arg_ptr(struct = user_arg_ptr argv, int nr) compat_uptr_t compat; =20 if (get_user(compat, argv.ptr.compat + nr)) @@ -42369,7 +43487,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c =20 return native; } -@@ -443,7 +446,7 @@ static int count(struct user_arg_ptr arg +@@ -443,7 +446,7 @@ static int count(struct user_arg_ptr argv, int max) if (!p) break; =20 @@ -42378,7 +43496,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c return -EFAULT; =20 if (i++ >=3D max) -@@ -477,7 +480,7 @@ static int copy_strings(int argc, struct +@@ -477,7 +480,7 @@ static int copy_strings(int argc, struct user_arg_pt= r argv, =20 ret =3D -EFAULT; str =3D get_user_arg_ptr(argv, argc); @@ -42387,7 +43505,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c goto out; =20 len =3D strnlen_user(str, MAX_ARG_STRLEN); -@@ -559,7 +562,7 @@ int copy_strings_kernel(int argc, const=20 +@@ -559,7 +562,7 @@ int copy_strings_kernel(int argc, const char *const = *__argv, int r; mm_segment_t oldfs =3D get_fs(); struct user_arg_ptr argv =3D { @@ -42396,7 +43514,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c }; =20 set_fs(KERNEL_DS); -@@ -594,7 +597,8 @@ static int shift_arg_pages(struct vm_are +@@ -594,7 +597,8 @@ static int shift_arg_pages(struct vm_area_struct *vm= a, unsigned long shift) unsigned long new_end =3D old_end - shift; struct mmu_gather tlb; =20 @@ -42406,7 +43524,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c =20 /* * ensure there are no vmas between where we want to go -@@ -603,6 +607,10 @@ static int shift_arg_pages(struct vm_are +@@ -603,6 +607,10 @@ static int shift_arg_pages(struct vm_area_struct *v= ma, unsigned long shift) if (vma !=3D find_vma(mm, new_start)) return -EFAULT; =20 @@ -42417,7 +43535,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c /* * cover the whole range: [new_start, old_end) */ -@@ -683,10 +691,6 @@ int setup_arg_pages(struct linux_binprm=20 +@@ -683,10 +691,6 @@ int setup_arg_pages(struct linux_binprm *bprm, stack_top =3D arch_align_stack(stack_top); stack_top =3D PAGE_ALIGN(stack_top); =20 @@ -42428,7 +43546,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c stack_shift =3D vma->vm_end - stack_top; =20 bprm->p -=3D stack_shift; -@@ -698,8 +702,28 @@ int setup_arg_pages(struct linux_binprm=20 +@@ -698,8 +702,28 @@ int setup_arg_pages(struct linux_binprm *bprm, bprm->exec -=3D stack_shift; =20 down_write(&mm->mmap_sem); @@ -42457,7 +43575,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c /* * Adjust stack execute permissions; explicitly enable for * EXSTACK_ENABLE_X, disable for EXSTACK_DISABLE_X and leave alone -@@ -718,13 +742,6 @@ int setup_arg_pages(struct linux_binprm=20 +@@ -718,13 +742,6 @@ int setup_arg_pages(struct linux_binprm *bprm, goto out_unlock; BUG_ON(prev !=3D vma); =20 @@ -42471,7 +43589,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c /* mprotect_fixup is overkill to remove the temporary stack flags */ vma->vm_flags &=3D ~VM_STACK_INCOMPLETE_SETUP; =20 -@@ -805,7 +822,7 @@ int kernel_read(struct file *file, loff_ +@@ -805,7 +822,7 @@ int kernel_read(struct file *file, loff_t offset, old_fs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -42480,7 +43598,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c set_fs(old_fs); return result; } -@@ -1251,7 +1268,7 @@ int check_unsafe_exec(struct linux_binpr +@@ -1251,7 +1268,7 @@ int check_unsafe_exec(struct linux_binprm *bprm) } rcu_read_unlock(); =20 @@ -42489,7 +43607,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c bprm->unsafe |=3D LSM_UNSAFE_SHARE; } else { res =3D -EAGAIN; -@@ -1454,6 +1471,11 @@ static int do_execve_common(const char * +@@ -1454,6 +1471,11 @@ static int do_execve_common(const char *filename, struct user_arg_ptr envp, struct pt_regs *regs) { @@ -42501,7 +43619,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c struct linux_binprm *bprm; struct file *file; struct files_struct *displaced; -@@ -1461,6 +1483,8 @@ static int do_execve_common(const char * +@@ -1461,6 +1483,8 @@ static int do_execve_common(const char *filename, int retval; const struct cred *cred =3D current_cred(); =20 @@ -42510,7 +43628,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c /* * We move the actual failure in case of RLIMIT_NPROC excess from * set*uid() to execve() because too many poorly written programs -@@ -1507,6 +1531,16 @@ static int do_execve_common(const char * +@@ -1507,6 +1531,16 @@ static int do_execve_common(const char *filename, bprm->filename =3D filename; bprm->interp =3D filename; =20 @@ -42527,7 +43645,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c retval =3D bprm_mm_init(bprm); if (retval) goto out_file; -@@ -1536,9 +1570,40 @@ static int do_execve_common(const char * +@@ -1536,9 +1570,40 @@ static int do_execve_common(const char *filename, if (retval < 0) goto out; =20 @@ -42569,7 +43687,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c =20 /* execve succeeded */ current->fs->in_exec =3D 0; -@@ -1549,6 +1614,14 @@ static int do_execve_common(const char * +@@ -1549,6 +1614,14 @@ static int do_execve_common(const char *filename, put_files_struct(displaced); return retval; =20 @@ -42584,7 +43702,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c out: if (bprm->mm) { acct_arg_size(bprm, 0); -@@ -1622,7 +1695,7 @@ static int expand_corename(struct core_n +@@ -1622,7 +1695,7 @@ static int expand_corename(struct core_name *cn) { char *old_corename =3D cn->corename; =20 @@ -42593,7 +43711,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c cn->corename =3D krealloc(old_corename, cn->size, GFP_KERNEL); =20 if (!cn->corename) { -@@ -1719,7 +1792,7 @@ static int format_corename(struct core_n +@@ -1719,7 +1792,7 @@ static int format_corename(struct core_name *cn, l= ong signr) int pid_in_pattern =3D 0; int err =3D 0; =20 @@ -42821,7 +43939,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c static int zap_process(struct task_struct *start, int exit_code) { struct task_struct *t; -@@ -2027,17 +2312,17 @@ static void wait_for_dump_helpers(struct +@@ -2027,17 +2312,17 @@ static void wait_for_dump_helpers(struct file *f= ile) pipe =3D file->f_path.dentry->d_inode->i_pipe; =20 pipe_lock(pipe); @@ -42844,7 +43962,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c pipe_unlock(pipe); =20 } -@@ -2098,7 +2383,7 @@ void do_coredump(long signr, int exit_co +@@ -2098,7 +2383,7 @@ void do_coredump(long signr, int exit_code, struct= pt_regs *regs) int retval =3D 0; int flag =3D 0; int ispipe; @@ -42853,7 +43971,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c struct coredump_params cprm =3D { .signr =3D signr, .regs =3D regs, -@@ -2113,6 +2398,9 @@ void do_coredump(long signr, int exit_co +@@ -2113,6 +2398,9 @@ void do_coredump(long signr, int exit_code, struct= pt_regs *regs) =20 audit_core_dumps(signr); =20 @@ -42863,7 +43981,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c binfmt =3D mm->binfmt; if (!binfmt || !binfmt->core_dump) goto fail; -@@ -2180,7 +2468,7 @@ void do_coredump(long signr, int exit_co +@@ -2180,7 +2468,7 @@ void do_coredump(long signr, int exit_code, struct= pt_regs *regs) } cprm.limit =3D RLIM_INFINITY; =20 @@ -42872,7 +43990,7 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs/e= xec.c if (core_pipe_limit && (core_pipe_limit < dump_count)) { printk(KERN_WARNING "Pid %d(%s) over core_pipe_limit\n", task_tgid_vnr(current), current->comm); -@@ -2207,6 +2495,8 @@ void do_coredump(long signr, int exit_co +@@ -2207,6 +2495,8 @@ void do_coredump(long signr, int exit_code, struct= pt_regs *regs) } else { struct inode *inode; =20 @@ -42899,10 +44017,11 @@ diff -urNp linux-3.1.4/fs/exec.c linux-3.1.4/fs= /exec.c } EXPORT_SYMBOL(dump_write); =20 -diff -urNp linux-3.1.4/fs/ext2/balloc.c linux-3.1.4/fs/ext2/balloc.c ---- linux-3.1.4/fs/ext2/balloc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ext2/balloc.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1192,7 +1192,7 @@ static int ext2_has_free_blocks(struct e +diff --git a/fs/ext2/balloc.c b/fs/ext2/balloc.c +index 8f44cef..cb07120 100644 +--- a/fs/ext2/balloc.c ++++ b/fs/ext2/balloc.c +@@ -1192,7 +1192,7 @@ static int ext2_has_free_blocks(struct ext2_sb_inf= o *sbi) =20 free_blocks =3D percpu_counter_read_positive(&sbi->s_freeblocks_counte= r); root_blocks =3D le32_to_cpu(sbi->s_es->s_r_blocks_count); @@ -42911,10 +44030,11 @@ diff -urNp linux-3.1.4/fs/ext2/balloc.c linux-3= .1.4/fs/ext2/balloc.c sbi->s_resuid !=3D current_fsuid() && (sbi->s_resgid =3D=3D 0 || !in_group_p (sbi->s_resgid))) { return 0; -diff -urNp linux-3.1.4/fs/ext3/balloc.c linux-3.1.4/fs/ext3/balloc.c ---- linux-3.1.4/fs/ext3/balloc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ext3/balloc.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1446,7 +1446,7 @@ static int ext3_has_free_blocks(struct e +diff --git a/fs/ext3/balloc.c b/fs/ext3/balloc.c +index 6386d76..0a266b1 100644 +--- a/fs/ext3/balloc.c ++++ b/fs/ext3/balloc.c +@@ -1446,7 +1446,7 @@ static int ext3_has_free_blocks(struct ext3_sb_inf= o *sbi) =20 free_blocks =3D percpu_counter_read_positive(&sbi->s_freeblocks_counte= r); root_blocks =3D le32_to_cpu(sbi->s_es->s_r_blocks_count); @@ -42923,10 +44043,11 @@ diff -urNp linux-3.1.4/fs/ext3/balloc.c linux-3= .1.4/fs/ext3/balloc.c sbi->s_resuid !=3D current_fsuid() && (sbi->s_resgid =3D=3D 0 || !in_group_p (sbi->s_resgid))) { return 0; -diff -urNp linux-3.1.4/fs/ext4/balloc.c linux-3.1.4/fs/ext4/balloc.c ---- linux-3.1.4/fs/ext4/balloc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ext4/balloc.c 2011-11-16 18:40:29.000000000 -0500 -@@ -394,8 +394,8 @@ static int ext4_has_free_blocks(struct e +diff --git a/fs/ext4/balloc.c b/fs/ext4/balloc.c +index f8224ad..fbef97c 100644 +--- a/fs/ext4/balloc.c ++++ b/fs/ext4/balloc.c +@@ -394,8 +394,8 @@ static int ext4_has_free_blocks(struct ext4_sb_info = *sbi, /* Hm, nope. Are (enough) root reserved blocks available? */ if (sbi->s_resuid =3D=3D current_fsuid() || ((sbi->s_resgid !=3D 0) && in_group_p(sbi->s_resgid)) || @@ -42937,9 +44058,10 @@ diff -urNp linux-3.1.4/fs/ext4/balloc.c linux-3.= 1.4/fs/ext4/balloc.c =20 if (free_blocks >=3D (nblocks + dirty_blocks)) return 1; -diff -urNp linux-3.1.4/fs/ext4/ext4.h linux-3.1.4/fs/ext4/ext4.h ---- linux-3.1.4/fs/ext4/ext4.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ext4/ext4.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h +index 5c38120..2291d18 100644 +--- a/fs/ext4/ext4.h ++++ b/fs/ext4/ext4.h @@ -1180,19 +1180,19 @@ struct ext4_sb_info { unsigned long s_mb_last_start; =20 @@ -42970,10 +44092,11 @@ diff -urNp linux-3.1.4/fs/ext4/ext4.h linux-3.1= .4/fs/ext4/ext4.h atomic_t s_lock_busy; =20 /* locality groups */ -diff -urNp linux-3.1.4/fs/ext4/file.c linux-3.1.4/fs/ext4/file.c ---- linux-3.1.4/fs/ext4/file.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ext4/file.c 2011-11-16 18:40:29.000000000 -0500 -@@ -181,8 +181,8 @@ static int ext4_file_open(struct inode * +diff --git a/fs/ext4/file.c b/fs/ext4/file.c +index e4095e9..1c006c5 100644 +--- a/fs/ext4/file.c ++++ b/fs/ext4/file.c +@@ -181,8 +181,8 @@ static int ext4_file_open(struct inode * inode, stru= ct file * filp) path.dentry =3D mnt->mnt_root; cp =3D d_path(&path, buf, sizeof(buf)); if (!IS_ERR(cp)) { @@ -42984,9 +44107,10 @@ diff -urNp linux-3.1.4/fs/ext4/file.c linux-3.1.= 4/fs/ext4/file.c ext4_mark_super_dirty(sb); } } -diff -urNp linux-3.1.4/fs/ext4/ioctl.c linux-3.1.4/fs/ext4/ioctl.c ---- linux-3.1.4/fs/ext4/ioctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ext4/ioctl.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/ext4/ioctl.c b/fs/ext4/ioctl.c +index f18bfe3..43759b1 100644 +--- a/fs/ext4/ioctl.c ++++ b/fs/ext4/ioctl.c @@ -348,7 +348,7 @@ mext_out: if (!blk_queue_discard(q)) return -EOPNOTSUPP; @@ -43005,10 +44129,11 @@ diff -urNp linux-3.1.4/fs/ext4/ioctl.c linux-3.= 1.4/fs/ext4/ioctl.c sizeof(range))) return -EFAULT; =20 -diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.1.4/fs/ext4/mballoc.c ---- linux-3.1.4/fs/ext4/mballoc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ext4/mballoc.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1795,7 +1795,7 @@ void ext4_mb_simple_scan_group(struct ex +diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c +index 17a5a57..b6be3c5 100644 +--- a/fs/ext4/mballoc.c ++++ b/fs/ext4/mballoc.c +@@ -1795,7 +1795,7 @@ void ext4_mb_simple_scan_group(struct ext4_allocat= ion_context *ac, BUG_ON(ac->ac_b_ex.fe_len !=3D ac->ac_g_ex.fe_len); =20 if (EXT4_SB(sb)->s_mb_stats) @@ -43026,7 +44151,7 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.= 1.4/fs/ext4/mballoc.c goto repeat; } } -@@ -2132,6 +2132,8 @@ static int ext4_mb_seq_groups_show(struc +@@ -2132,6 +2132,8 @@ static int ext4_mb_seq_groups_show(struct seq_file= *seq, void *v) ext4_grpblk_t counters[16]; } sg; =20 @@ -43035,7 +44160,7 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.= 1.4/fs/ext4/mballoc.c group--; if (group =3D=3D 0) seq_printf(seq, "#%-5s: %-5s %-5s %-5s " -@@ -2573,25 +2575,25 @@ int ext4_mb_release(struct super_block * +@@ -2573,25 +2575,25 @@ int ext4_mb_release(struct super_block *sb) if (sbi->s_mb_stats) { ext4_msg(sb, KERN_INFO, "mballoc: %u blocks %u reqs (%u success)", @@ -43071,7 +44196,7 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.= 1.4/fs/ext4/mballoc.c } =20 free_percpu(sbi->s_locality_groups); -@@ -3070,16 +3072,16 @@ static void ext4_mb_collect_stats(struct +@@ -3070,16 +3072,16 @@ static void ext4_mb_collect_stats(struct ext4_al= location_context *ac) struct ext4_sb_info *sbi =3D EXT4_SB(ac->ac_sb); =20 if (sbi->s_mb_stats && ac->ac_g_ex.fe_len > 1) { @@ -43094,7 +44219,7 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.= 1.4/fs/ext4/mballoc.c } =20 if (ac->ac_op =3D=3D EXT4_MB_HISTORY_ALLOC) -@@ -3477,7 +3479,7 @@ ext4_mb_new_inode_pa(struct ext4_allocat +@@ -3477,7 +3479,7 @@ ext4_mb_new_inode_pa(struct ext4_allocation_contex= t *ac) trace_ext4_mb_new_inode_pa(ac, pa); =20 ext4_mb_use_inode_pa(ac, pa); @@ -43103,7 +44228,7 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.= 1.4/fs/ext4/mballoc.c =20 ei =3D EXT4_I(ac->ac_inode); grp =3D ext4_get_group_info(sb, ac->ac_b_ex.fe_group); -@@ -3537,7 +3539,7 @@ ext4_mb_new_group_pa(struct ext4_allocat +@@ -3537,7 +3539,7 @@ ext4_mb_new_group_pa(struct ext4_allocation_contex= t *ac) trace_ext4_mb_new_group_pa(ac, pa); =20 ext4_mb_use_group_pa(ac, pa); @@ -43112,7 +44237,7 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.= 1.4/fs/ext4/mballoc.c =20 grp =3D ext4_get_group_info(sb, ac->ac_b_ex.fe_group); lg =3D ac->ac_lg; -@@ -3625,7 +3627,7 @@ ext4_mb_release_inode_pa(struct ext4_bud +@@ -3625,7 +3627,7 @@ ext4_mb_release_inode_pa(struct ext4_buddy *e4b, s= truct buffer_head *bitmap_bh, * from the bitmap and continue. */ } @@ -43121,7 +44246,7 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-3.= 1.4/fs/ext4/mballoc.c =20 return err; } -@@ -3643,7 +3645,7 @@ ext4_mb_release_group_pa(struct ext4_bud +@@ -3643,7 +3645,7 @@ ext4_mb_release_group_pa(struct ext4_buddy *e4b, ext4_get_group_no_and_offset(sb, pa->pa_pstart, &group, &bit); BUG_ON(group !=3D e4b->bd_group && pa->pa_len !=3D 0); mb_free_blocks(pa->pa_inode, e4b, bit, pa->pa_len); @@ -43130,10 +44255,11 @@ diff -urNp linux-3.1.4/fs/ext4/mballoc.c linux-= 3.1.4/fs/ext4/mballoc.c trace_ext4_mballoc_discard(sb, NULL, group, bit, pa->pa_len); =20 return 0; -diff -urNp linux-3.1.4/fs/fcntl.c linux-3.1.4/fs/fcntl.c ---- linux-3.1.4/fs/fcntl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fcntl.c 2011-11-16 23:40:25.000000000 -0500 -@@ -224,6 +224,11 @@ int __f_setown(struct file *filp, struct +diff --git a/fs/fcntl.c b/fs/fcntl.c +index 22764c7..86372c9 100644 +--- a/fs/fcntl.c ++++ b/fs/fcntl.c +@@ -224,6 +224,11 @@ int __f_setown(struct file *filp, struct pid *pid, = enum pid_type type, if (err) return err; =20 @@ -43154,7 +44280,7 @@ diff -urNp linux-3.1.4/fs/fcntl.c linux-3.1.4/fs/= fcntl.c struct f_owner_ex owner; struct pid *pid; int type; -@@ -306,7 +311,7 @@ static int f_setown_ex(struct file *filp +@@ -306,7 +311,7 @@ static int f_setown_ex(struct file *filp, unsigned l= ong arg) =20 static int f_getown_ex(struct file *filp, unsigned long arg) { @@ -43163,7 +44289,7 @@ diff -urNp linux-3.1.4/fs/fcntl.c linux-3.1.4/fs/= fcntl.c struct f_owner_ex owner; int ret =3D 0; =20 -@@ -348,6 +353,7 @@ static long do_fcntl(int fd, unsigned in +@@ -348,6 +353,7 @@ static long do_fcntl(int fd, unsigned int cmd, unsig= ned long arg, switch (cmd) { case F_DUPFD: case F_DUPFD_CLOEXEC: @@ -43171,10 +44297,11 @@ diff -urNp linux-3.1.4/fs/fcntl.c linux-3.1.4/f= s/fcntl.c if (arg >=3D rlimit(RLIMIT_NOFILE)) break; err =3D alloc_fd(arg, cmd =3D=3D F_DUPFD_CLOEXEC ? O_CLOEXEC : 0); -diff -urNp linux-3.1.4/fs/fifo.c linux-3.1.4/fs/fifo.c ---- linux-3.1.4/fs/fifo.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fifo.c 2011-11-16 18:39:08.000000000 -0500 -@@ -58,10 +58,10 @@ static int fifo_open(struct inode *inode +diff --git a/fs/fifo.c b/fs/fifo.c +index b1a524d..4ee270e 100644 +--- a/fs/fifo.c ++++ b/fs/fifo.c +@@ -58,10 +58,10 @@ static int fifo_open(struct inode *inode, struct fil= e *filp) */ filp->f_op =3D &read_pipefifo_fops; pipe->r_counter++; @@ -43187,7 +44314,7 @@ diff -urNp linux-3.1.4/fs/fifo.c linux-3.1.4/fs/f= ifo.c if ((filp->f_flags & O_NONBLOCK)) { /* suppress POLLHUP until we have * seen a writer */ -@@ -81,15 +81,15 @@ static int fifo_open(struct inode *inode +@@ -81,15 +81,15 @@ static int fifo_open(struct inode *inode, struct fil= e *filp) * errno=3DENXIO when there is no process reading the FIFO. */ ret =3D -ENXIO; @@ -43206,7 +44333,7 @@ diff -urNp linux-3.1.4/fs/fifo.c linux-3.1.4/fs/f= ifo.c wait_for_partner(inode, &pipe->r_counter); if (signal_pending(current)) goto err_wr; -@@ -105,11 +105,11 @@ static int fifo_open(struct inode *inode +@@ -105,11 +105,11 @@ static int fifo_open(struct inode *inode, struct f= ile *filp) */ filp->f_op =3D &rdwr_pipefifo_fops; =20 @@ -43221,7 +44348,7 @@ diff -urNp linux-3.1.4/fs/fifo.c linux-3.1.4/fs/f= ifo.c wake_up_partner(inode); break; =20 -@@ -123,19 +123,19 @@ static int fifo_open(struct inode *inode +@@ -123,19 +123,19 @@ static int fifo_open(struct inode *inode, struct f= ile *filp) return 0; =20 err_rd: @@ -43244,9 +44371,10 @@ diff -urNp linux-3.1.4/fs/fifo.c linux-3.1.4/fs/= fifo.c free_pipe_info(inode); =20 err_nocleanup: -diff -urNp linux-3.1.4/fs/file.c linux-3.1.4/fs/file.c ---- linux-3.1.4/fs/file.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/file.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/file.c b/fs/file.c +index 4c6992d..104cdea 100644 +--- a/fs/file.c ++++ b/fs/file.c @@ -15,6 +15,7 @@ #include #include @@ -43255,7 +44383,7 @@ diff -urNp linux-3.1.4/fs/file.c linux-3.1.4/fs/f= ile.c #include #include #include -@@ -254,6 +255,7 @@ int expand_files(struct files_struct *fi +@@ -254,6 +255,7 @@ int expand_files(struct files_struct *files, int nr) * N.B. For clone tasks sharing a files structure, this test * will limit the total number of files that can be opened. */ @@ -43263,10 +44391,11 @@ diff -urNp linux-3.1.4/fs/file.c linux-3.1.4/fs= /file.c if (nr >=3D rlimit(RLIMIT_NOFILE)) return -EMFILE; =20 -diff -urNp linux-3.1.4/fs/filesystems.c linux-3.1.4/fs/filesystems.c ---- linux-3.1.4/fs/filesystems.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/filesystems.c 2011-11-16 18:40:29.000000000 -0500 -@@ -274,7 +274,12 @@ struct file_system_type *get_fs_type(con +diff --git a/fs/filesystems.c b/fs/filesystems.c +index 0845f84..7b4ebef 100644 +--- a/fs/filesystems.c ++++ b/fs/filesystems.c +@@ -274,7 +274,12 @@ struct file_system_type *get_fs_type(const char *na= me) int len =3D dot ? dot - name : strlen(name); =20 fs =3D __get_fs_type(name, len); @@ -43279,10 +44408,104 @@ diff -urNp linux-3.1.4/fs/filesystems.c linux-= 3.1.4/fs/filesystems.c fs =3D __get_fs_type(name, len); =20 if (dot && fs && !(fs->fs_flags & FS_HAS_SUBTYPE)) { -diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-3.1.4/fs/fscache/cookie= .c ---- linux-3.1.4/fs/fscache/cookie.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fscache/cookie.c 2011-11-16 18:39:08.000000000 -0500 -@@ -68,11 +68,11 @@ struct fscache_cookie *__fscache_acquire +diff --git a/fs/fs_struct.c b/fs/fs_struct.c +index 78b519c..212c0d0 100644 +--- a/fs/fs_struct.c ++++ b/fs/fs_struct.c +@@ -4,6 +4,7 @@ + #include + #include + #include ++#include + #include "internal.h" +=20 + static inline void path_get_longterm(struct path *path) +@@ -31,6 +32,7 @@ void set_fs_root(struct fs_struct *fs, struct path *pa= th) + old_root =3D fs->root; + fs->root =3D *path; + path_get_longterm(path); ++ gr_set_chroot_entries(current, path); + write_seqcount_end(&fs->seq); + spin_unlock(&fs->lock); + if (old_root.dentry) +@@ -74,6 +76,7 @@ void chroot_fs_refs(struct path *old_root, struct path= *new_root) + && fs->root.mnt =3D=3D old_root->mnt) { + path_get_longterm(new_root); + fs->root =3D *new_root; ++ gr_set_chroot_entries(p, new_root); + count++; + } + if (fs->pwd.dentry =3D=3D old_root->dentry +@@ -109,7 +112,8 @@ void exit_fs(struct task_struct *tsk) + spin_lock(&fs->lock); + write_seqcount_begin(&fs->seq); + tsk->fs =3D NULL; +- kill =3D !--fs->users; ++ gr_clear_chroot_entries(tsk); ++ kill =3D !atomic_dec_return(&fs->users); + write_seqcount_end(&fs->seq); + spin_unlock(&fs->lock); + task_unlock(tsk); +@@ -123,7 +127,7 @@ struct fs_struct *copy_fs_struct(struct fs_struct *o= ld) + struct fs_struct *fs =3D kmem_cache_alloc(fs_cachep, GFP_KERNEL); + /* We don't need to lock fs - think why ;-) */ + if (fs) { +- fs->users =3D 1; ++ atomic_set(&fs->users, 1); + fs->in_exec =3D 0; + spin_lock_init(&fs->lock); + seqcount_init(&fs->seq); +@@ -132,6 +136,9 @@ struct fs_struct *copy_fs_struct(struct fs_struct *o= ld) + spin_lock(&old->lock); + fs->root =3D old->root; + path_get_longterm(&fs->root); ++ /* instead of calling gr_set_chroot_entries here, ++ we call it from every caller of this function ++ */ + fs->pwd =3D old->pwd; + path_get_longterm(&fs->pwd); + spin_unlock(&old->lock); +@@ -150,8 +157,9 @@ int unshare_fs_struct(void) +=20 + task_lock(current); + spin_lock(&fs->lock); +- kill =3D !--fs->users; ++ kill =3D !atomic_dec_return(&fs->users); + current->fs =3D new_fs; ++ gr_set_chroot_entries(current, &new_fs->root); + spin_unlock(&fs->lock); + task_unlock(current); +=20 +@@ -170,7 +178,7 @@ EXPORT_SYMBOL(current_umask); +=20 + /* to be mentioned only in INIT_TASK */ + struct fs_struct init_fs =3D { +- .users =3D 1, ++ .users =3D ATOMIC_INIT(1), + .lock =3D __SPIN_LOCK_UNLOCKED(init_fs.lock), + .seq =3D SEQCNT_ZERO, + .umask =3D 0022, +@@ -186,12 +194,13 @@ void daemonize_fs_struct(void) + task_lock(current); +=20 + spin_lock(&init_fs.lock); +- init_fs.users++; ++ atomic_inc(&init_fs.users); + spin_unlock(&init_fs.lock); +=20 + spin_lock(&fs->lock); + current->fs =3D &init_fs; +- kill =3D !--fs->users; ++ gr_set_chroot_entries(current, ¤t->fs->root); ++ kill =3D !atomic_dec_return(&fs->users); + spin_unlock(&fs->lock); +=20 + task_unlock(current); +diff --git a/fs/fscache/cookie.c b/fs/fscache/cookie.c +index 9905350..02eaec4 100644 +--- a/fs/fscache/cookie.c ++++ b/fs/fscache/cookie.c +@@ -68,11 +68,11 @@ struct fscache_cookie *__fscache_acquire_cookie( parent ? (char *) parent->def->name : "", def->name, netfs_data); =20 @@ -43296,7 +44519,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c _leave(" [no parent]"); return NULL; } -@@ -87,7 +87,7 @@ struct fscache_cookie *__fscache_acquire +@@ -87,7 +87,7 @@ struct fscache_cookie *__fscache_acquire_cookie( /* allocate and initialise a cookie */ cookie =3D kmem_cache_alloc(fscache_cookie_jar, GFP_KERNEL); if (!cookie) { @@ -43305,7 +44528,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c _leave(" [ENOMEM]"); return NULL; } -@@ -109,13 +109,13 @@ struct fscache_cookie *__fscache_acquire +@@ -109,13 +109,13 @@ struct fscache_cookie *__fscache_acquire_cookie( =20 switch (cookie->def->type) { case FSCACHE_COOKIE_TYPE_INDEX: @@ -43322,7 +44545,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c break; } =20 -@@ -126,13 +126,13 @@ struct fscache_cookie *__fscache_acquire +@@ -126,13 +126,13 @@ struct fscache_cookie *__fscache_acquire_cookie( if (fscache_acquire_non_index_cookie(cookie) < 0) { atomic_dec(&parent->n_children); __fscache_cookie_put(cookie); @@ -43338,7 +44561,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c _leave(" =3D %p", cookie); return cookie; } -@@ -168,7 +168,7 @@ static int fscache_acquire_non_index_coo +@@ -168,7 +168,7 @@ static int fscache_acquire_non_index_cookie(struct f= scache_cookie *cookie) cache =3D fscache_select_cache_for_object(cookie->parent); if (!cache) { up_read(&fscache_addremove_sem); @@ -43347,7 +44570,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c _leave(" =3D -ENOMEDIUM [no cache]"); return -ENOMEDIUM; } -@@ -256,12 +256,12 @@ static int fscache_alloc_object(struct f +@@ -256,12 +256,12 @@ static int fscache_alloc_object(struct fscache_cac= he *cache, object =3D cache->ops->alloc_object(cache, cookie); fscache_stat_d(&fscache_n_cop_alloc_object); if (IS_ERR(object)) { @@ -43362,7 +44585,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c =20 object->debug_id =3D atomic_inc_return(&fscache_object_debug_id); =20 -@@ -377,10 +377,10 @@ void __fscache_update_cookie(struct fsca +@@ -377,10 +377,10 @@ void __fscache_update_cookie(struct fscache_cookie= *cookie) struct fscache_object *object; struct hlist_node *_p; =20 @@ -43375,7 +44598,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c _leave(" [no cookie]"); return; } -@@ -414,12 +414,12 @@ void __fscache_relinquish_cookie(struct=20 +@@ -414,12 +414,12 @@ void __fscache_relinquish_cookie(struct fscache_co= okie *cookie, int retire) struct fscache_object *object; unsigned long event; =20 @@ -43391,7 +44614,7 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux-= 3.1.4/fs/fscache/cookie.c _leave(" [no cookie]"); return; } -@@ -435,7 +435,7 @@ void __fscache_relinquish_cookie(struct=20 +@@ -435,7 +435,7 @@ void __fscache_relinquish_cookie(struct fscache_cook= ie *cookie, int retire) =20 /* wait for the cookie to finish being instantiated (or to fail) */ if (test_bit(FSCACHE_COOKIE_CREATING, &cookie->flags)) { @@ -43400,9 +44623,10 @@ diff -urNp linux-3.1.4/fs/fscache/cookie.c linux= -3.1.4/fs/fscache/cookie.c wait_on_bit(&cookie->flags, FSCACHE_COOKIE_CREATING, fscache_wait_bit, TASK_UNINTERRUPTIBLE); } -diff -urNp linux-3.1.4/fs/fscache/internal.h linux-3.1.4/fs/fscache/inte= rnal.h ---- linux-3.1.4/fs/fscache/internal.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/fscache/internal.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/fs/fscache/internal.h b/fs/fscache/internal.h +index f6aad48..88dcf26 100644 +--- a/fs/fscache/internal.h ++++ b/fs/fscache/internal.h @@ -144,94 +144,94 @@ extern void fscache_proc_cleanup(void); extern atomic_t fscache_n_ops_processed[FSCACHE_MAX_THREADS]; extern atomic_t fscache_n_objs_processed[FSCACHE_MAX_THREADS]; @@ -43586,7 +44810,7 @@ diff -urNp linux-3.1.4/fs/fscache/internal.h linu= x-3.1.4/fs/fscache/internal.h =20 extern atomic_t fscache_n_cop_alloc_object; extern atomic_t fscache_n_cop_lookup_object; -@@ -255,6 +255,11 @@ static inline void fscache_stat(atomic_t +@@ -255,6 +255,11 @@ static inline void fscache_stat(atomic_t *stat) atomic_inc(stat); } =20 @@ -43598,7 +44822,7 @@ diff -urNp linux-3.1.4/fs/fscache/internal.h linu= x-3.1.4/fs/fscache/internal.h static inline void fscache_stat_d(atomic_t *stat) { atomic_dec(stat); -@@ -267,6 +272,7 @@ extern const struct file_operations fsca +@@ -267,6 +272,7 @@ extern const struct file_operations fscache_stats_fo= ps; =20 #define __fscache_stat(stat) (NULL) #define fscache_stat(stat) do {} while (0) @@ -43606,10 +44830,11 @@ diff -urNp linux-3.1.4/fs/fscache/internal.h li= nux-3.1.4/fs/fscache/internal.h #define fscache_stat_d(stat) do {} while (0) #endif =20 -diff -urNp linux-3.1.4/fs/fscache/object.c linux-3.1.4/fs/fscache/object= .c ---- linux-3.1.4/fs/fscache/object.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fscache/object.c 2011-11-16 18:39:08.000000000 -0500 -@@ -128,7 +128,7 @@ static void fscache_object_state_machine +diff --git a/fs/fscache/object.c b/fs/fscache/object.c +index b6b897c..0ffff9c 100644 +--- a/fs/fscache/object.c ++++ b/fs/fscache/object.c +@@ -128,7 +128,7 @@ static void fscache_object_state_machine(struct fsca= che_object *object) /* update the object metadata on disk */ case FSCACHE_OBJECT_UPDATING: clear_bit(FSCACHE_OBJECT_EV_UPDATE, &object->events); @@ -43618,7 +44843,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c fscache_stat(&fscache_n_cop_update_object); object->cache->ops->update_object(object); fscache_stat_d(&fscache_n_cop_update_object); -@@ -217,7 +217,7 @@ static void fscache_object_state_machine +@@ -217,7 +217,7 @@ static void fscache_object_state_machine(struct fsca= che_object *object) spin_lock(&object->lock); object->state =3D FSCACHE_OBJECT_DEAD; spin_unlock(&object->lock); @@ -43627,7 +44852,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c goto terminal_transit; =20 /* handle the parent cache of this object being withdrawn from -@@ -232,7 +232,7 @@ static void fscache_object_state_machine +@@ -232,7 +232,7 @@ static void fscache_object_state_machine(struct fsca= che_object *object) spin_lock(&object->lock); object->state =3D FSCACHE_OBJECT_DEAD; spin_unlock(&object->lock); @@ -43636,7 +44861,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c goto terminal_transit; =20 /* complain about the object being woken up once it is -@@ -461,7 +461,7 @@ static void fscache_lookup_object(struct +@@ -461,7 +461,7 @@ static void fscache_lookup_object(struct fscache_obj= ect *object) parent->cookie->def->name, cookie->def->name, object->cache->tag->name); =20 @@ -43645,7 +44870,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c fscache_stat(&fscache_n_cop_lookup_object); ret =3D object->cache->ops->lookup_object(object); fscache_stat_d(&fscache_n_cop_lookup_object); -@@ -472,7 +472,7 @@ static void fscache_lookup_object(struct +@@ -472,7 +472,7 @@ static void fscache_lookup_object(struct fscache_obj= ect *object) if (ret =3D=3D -ETIMEDOUT) { /* probably stuck behind another object, so move this one to * the back of the queue */ @@ -43654,7 +44879,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c set_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events); } =20 -@@ -495,7 +495,7 @@ void fscache_object_lookup_negative(stru +@@ -495,7 +495,7 @@ void fscache_object_lookup_negative(struct fscache_o= bject *object) =20 spin_lock(&object->lock); if (object->state =3D=3D FSCACHE_OBJECT_LOOKING_UP) { @@ -43663,7 +44888,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c =20 /* transit here to allow write requests to begin stacking up * and read requests to begin returning ENODATA */ -@@ -541,7 +541,7 @@ void fscache_obtained_object(struct fsca +@@ -541,7 +541,7 @@ void fscache_obtained_object(struct fscache_object *= object) * result, in which case there may be data available */ spin_lock(&object->lock); if (object->state =3D=3D FSCACHE_OBJECT_LOOKING_UP) { @@ -43672,7 +44897,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c =20 clear_bit(FSCACHE_COOKIE_NO_DATA_YET, &cookie->flags); =20 -@@ -555,7 +555,7 @@ void fscache_obtained_object(struct fsca +@@ -555,7 +555,7 @@ void fscache_obtained_object(struct fscache_object *= object) set_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events); } else { ASSERTCMP(object->state, =3D=3D, FSCACHE_OBJECT_CREATING); @@ -43681,7 +44906,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c =20 object->state =3D FSCACHE_OBJECT_AVAILABLE; spin_unlock(&object->lock); -@@ -602,7 +602,7 @@ static void fscache_object_available(str +@@ -602,7 +602,7 @@ static void fscache_object_available(struct fscache_= object *object) fscache_enqueue_dependents(object); =20 fscache_hist(fscache_obj_instantiate_histogram, object->lookup_jif); @@ -43690,7 +44915,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c =20 _leave(""); } -@@ -861,7 +861,7 @@ enum fscache_checkaux fscache_check_aux( +@@ -861,7 +861,7 @@ enum fscache_checkaux fscache_check_aux(struct fscac= he_object *object, enum fscache_checkaux result; =20 if (!object->cookie->def->check_aux) { @@ -43699,7 +44924,7 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux-= 3.1.4/fs/fscache/object.c return FSCACHE_CHECKAUX_OKAY; } =20 -@@ -870,17 +870,17 @@ enum fscache_checkaux fscache_check_aux( +@@ -870,17 +870,17 @@ enum fscache_checkaux fscache_check_aux(struct fsc= ache_object *object, switch (result) { /* entry okay as is */ case FSCACHE_CHECKAUX_OKAY: @@ -43720,9 +44945,10 @@ diff -urNp linux-3.1.4/fs/fscache/object.c linux= -3.1.4/fs/fscache/object.c break; =20 default: -diff -urNp linux-3.1.4/fs/fscache/operation.c linux-3.1.4/fs/fscache/ope= ration.c ---- linux-3.1.4/fs/fscache/operation.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/fs/fscache/operation.c 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/fs/fscache/operation.c b/fs/fscache/operation.c +index 30afdfa..2256596 100644 +--- a/fs/fscache/operation.c ++++ b/fs/fscache/operation.c @@ -17,7 +17,7 @@ #include #include "internal.h" @@ -43732,7 +44958,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c EXPORT_SYMBOL(fscache_op_debug_id); =20 /** -@@ -38,7 +38,7 @@ void fscache_enqueue_operation(struct fs +@@ -38,7 +38,7 @@ void fscache_enqueue_operation(struct fscache_operatio= n *op) ASSERTCMP(op->object->state, >=3D, FSCACHE_OBJECT_AVAILABLE); ASSERTCMP(atomic_read(&op->usage), >, 0); =20 @@ -43741,7 +44967,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c switch (op->flags & FSCACHE_OP_TYPE) { case FSCACHE_OP_ASYNC: _debug("queue async"); -@@ -69,7 +69,7 @@ static void fscache_run_op(struct fscach +@@ -69,7 +69,7 @@ static void fscache_run_op(struct fscache_object *obje= ct, wake_up_bit(&op->flags, FSCACHE_OP_WAITING); if (op->processor) fscache_enqueue_operation(op); @@ -43750,7 +44976,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c } =20 /* -@@ -98,11 +98,11 @@ int fscache_submit_exclusive_op(struct f +@@ -98,11 +98,11 @@ int fscache_submit_exclusive_op(struct fscache_objec= t *object, if (object->n_ops > 1) { atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -43764,7 +44990,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c fscache_start_operations(object); } else { ASSERTCMP(object->n_in_progress, =3D=3D, 0); -@@ -118,7 +118,7 @@ int fscache_submit_exclusive_op(struct f +@@ -118,7 +118,7 @@ int fscache_submit_exclusive_op(struct fscache_objec= t *object, object->n_exclusive++; /* reads and writes must wait */ atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -43773,7 +44999,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c ret =3D 0; } else { /* not allowed to submit ops in any other state */ -@@ -203,11 +203,11 @@ int fscache_submit_op(struct fscache_obj +@@ -203,11 +203,11 @@ int fscache_submit_op(struct fscache_object *objec= t, if (object->n_exclusive > 0) { atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -43787,7 +45013,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c fscache_start_operations(object); } else { ASSERTCMP(object->n_exclusive, =3D=3D, 0); -@@ -219,12 +219,12 @@ int fscache_submit_op(struct fscache_obj +@@ -219,12 +219,12 @@ int fscache_submit_op(struct fscache_object *objec= t, object->n_ops++; atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -43802,7 +45028,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c ret =3D -ENOBUFS; } else if (!test_bit(FSCACHE_IOERROR, &object->cache->flags)) { fscache_report_unexpected_submission(object, op, ostate); -@@ -294,7 +294,7 @@ int fscache_cancel_op(struct fscache_ope +@@ -294,7 +294,7 @@ int fscache_cancel_op(struct fscache_operation *op) =20 ret =3D -EBUSY; if (!list_empty(&op->pend_link)) { @@ -43811,7 +45037,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c list_del_init(&op->pend_link); object->n_ops--; if (test_bit(FSCACHE_OP_EXCLUSIVE, &op->flags)) -@@ -331,7 +331,7 @@ void fscache_put_operation(struct fscach +@@ -331,7 +331,7 @@ void fscache_put_operation(struct fscache_operation = *op) if (test_and_set_bit(FSCACHE_OP_DEAD, &op->flags)) BUG(); =20 @@ -43820,7 +45046,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c =20 if (op->release) { op->release(op); -@@ -348,7 +348,7 @@ void fscache_put_operation(struct fscach +@@ -348,7 +348,7 @@ void fscache_put_operation(struct fscache_operation = *op) * lock, and defer it otherwise */ if (!spin_trylock(&object->lock)) { _debug("defer put"); @@ -43829,7 +45055,7 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c lin= ux-3.1.4/fs/fscache/operation.c =20 cache =3D object->cache; spin_lock(&cache->op_gc_list_lock); -@@ -410,7 +410,7 @@ void fscache_operation_gc(struct work_st +@@ -410,7 +410,7 @@ void fscache_operation_gc(struct work_struct *work) =20 _debug("GC DEFERRED REL OBJ%x OP%x", object->debug_id, op->debug_id); @@ -43838,10 +45064,11 @@ diff -urNp linux-3.1.4/fs/fscache/operation.c l= inux-3.1.4/fs/fscache/operation.c =20 ASSERTCMP(atomic_read(&op->usage), =3D=3D, 0); =20 -diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.1.4/fs/fscache/page.c ---- linux-3.1.4/fs/fscache/page.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fscache/page.c 2011-11-16 18:39:08.000000000 -0500 -@@ -60,7 +60,7 @@ bool __fscache_maybe_release_page(struct +diff --git a/fs/fscache/page.c b/fs/fscache/page.c +index 3f7a59b..cf196cc 100644 +--- a/fs/fscache/page.c ++++ b/fs/fscache/page.c +@@ -60,7 +60,7 @@ bool __fscache_maybe_release_page(struct fscache_cooki= e *cookie, val =3D radix_tree_lookup(&cookie->stores, page->index); if (!val) { rcu_read_unlock(); @@ -43850,7 +45077,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c __fscache_uncache_page(cookie, page); return true; } -@@ -90,11 +90,11 @@ bool __fscache_maybe_release_page(struct +@@ -90,11 +90,11 @@ bool __fscache_maybe_release_page(struct fscache_coo= kie *cookie, spin_unlock(&cookie->stores_lock); =20 if (xpage) { @@ -43874,7 +45101,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c return false; } EXPORT_SYMBOL(__fscache_maybe_release_page); -@@ -131,7 +131,7 @@ static void fscache_end_page_write(struc +@@ -131,7 +131,7 @@ static void fscache_end_page_write(struct fscache_ob= ject *object, FSCACHE_COOKIE_STORING_TAG); if (!radix_tree_tag_get(&cookie->stores, page->index, FSCACHE_COOKIE_PENDING_TAG)) { @@ -43883,7 +45110,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c xpage =3D radix_tree_delete(&cookie->stores, page->index); } spin_unlock(&cookie->stores_lock); -@@ -152,7 +152,7 @@ static void fscache_attr_changed_op(stru +@@ -152,7 +152,7 @@ static void fscache_attr_changed_op(struct fscache_o= peration *op) =20 _enter("{OBJ%x OP%x}", object->debug_id, op->debug_id); =20 @@ -43892,7 +45119,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 if (fscache_object_is_active(object)) { fscache_stat(&fscache_n_cop_attr_changed); -@@ -177,11 +177,11 @@ int __fscache_attr_changed(struct fscach +@@ -177,11 +177,11 @@ int __fscache_attr_changed(struct fscache_cookie *= cookie) =20 ASSERTCMP(cookie->def->type, !=3D, FSCACHE_COOKIE_TYPE_INDEX); =20 @@ -43906,7 +45133,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c _leave(" =3D -ENOMEM"); return -ENOMEM; } -@@ -199,7 +199,7 @@ int __fscache_attr_changed(struct fscach +@@ -199,7 +199,7 @@ int __fscache_attr_changed(struct fscache_cookie *co= okie) if (fscache_submit_exclusive_op(object, op) < 0) goto nobufs; spin_unlock(&cookie->lock); @@ -43915,7 +45142,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c fscache_put_operation(op); _leave(" =3D 0"); return 0; -@@ -207,7 +207,7 @@ int __fscache_attr_changed(struct fscach +@@ -207,7 +207,7 @@ int __fscache_attr_changed(struct fscache_cookie *co= okie) nobufs: spin_unlock(&cookie->lock); kfree(op); @@ -43924,7 +45151,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c _leave(" =3D %d", -ENOBUFS); return -ENOBUFS; } -@@ -243,7 +243,7 @@ static struct fscache_retrieval *fscache +@@ -243,7 +243,7 @@ static struct fscache_retrieval *fscache_alloc_retri= eval( /* allocate a retrieval operation and attempt to submit it */ op =3D kzalloc(sizeof(*op), GFP_NOIO); if (!op) { @@ -43933,7 +45160,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c return NULL; } =20 -@@ -271,13 +271,13 @@ static int fscache_wait_for_deferred_loo +@@ -271,13 +271,13 @@ static int fscache_wait_for_deferred_lookup(struct= fscache_cookie *cookie) return 0; } =20 @@ -43949,7 +45176,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c _leave(" =3D -ERESTARTSYS"); return -ERESTARTSYS; } -@@ -295,8 +295,8 @@ static int fscache_wait_for_deferred_loo +@@ -295,8 +295,8 @@ static int fscache_wait_for_deferred_lookup(struct f= scache_cookie *cookie) */ static int fscache_wait_for_retrieval_activation(struct fscache_object = *object, struct fscache_retrieval *op, @@ -43960,7 +45187,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c { int ret; =20 -@@ -304,7 +304,7 @@ static int fscache_wait_for_retrieval_ac +@@ -304,7 +304,7 @@ static int fscache_wait_for_retrieval_activation(str= uct fscache_object *object, goto check_if_dead; =20 _debug(">>> WT"); @@ -43969,7 +45196,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c if (wait_on_bit(&op->op.flags, FSCACHE_OP_WAITING, fscache_wait_bit_interruptible, TASK_INTERRUPTIBLE) < 0) { -@@ -321,7 +321,7 @@ static int fscache_wait_for_retrieval_ac +@@ -321,7 +321,7 @@ static int fscache_wait_for_retrieval_activation(str= uct fscache_object *object, =20 check_if_dead: if (unlikely(fscache_object_is_dead(object))) { @@ -43978,7 +45205,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c return -ENOBUFS; } return 0; -@@ -348,7 +348,7 @@ int __fscache_read_or_alloc_page(struct=20 +@@ -348,7 +348,7 @@ int __fscache_read_or_alloc_page(struct fscache_cook= ie *cookie, =20 _enter("%p,%p,,,", cookie, page); =20 @@ -43987,7 +45214,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 if (hlist_empty(&cookie->backing_objects)) goto nobufs; -@@ -381,7 +381,7 @@ int __fscache_read_or_alloc_page(struct=20 +@@ -381,7 +381,7 @@ int __fscache_read_or_alloc_page(struct fscache_cook= ie *cookie, goto nobufs_unlock; spin_unlock(&cookie->lock); =20 @@ -43996,7 +45223,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 /* pin the netfs read context in case we need to do the actual netfs * read because we've encountered a cache read failure */ -@@ -411,15 +411,15 @@ int __fscache_read_or_alloc_page(struct=20 +@@ -411,15 +411,15 @@ int __fscache_read_or_alloc_page(struct fscache_co= okie *cookie, =20 error: if (ret =3D=3D -ENOMEM) @@ -44026,7 +45253,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c _leave(" =3D -ENOBUFS"); return -ENOBUFS; } -@@ -467,7 +467,7 @@ int __fscache_read_or_alloc_pages(struct +@@ -467,7 +467,7 @@ int __fscache_read_or_alloc_pages(struct fscache_coo= kie *cookie, =20 _enter("%p,,%d,,,", cookie, *nr_pages); =20 @@ -44035,7 +45262,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 if (hlist_empty(&cookie->backing_objects)) goto nobufs; -@@ -497,7 +497,7 @@ int __fscache_read_or_alloc_pages(struct +@@ -497,7 +497,7 @@ int __fscache_read_or_alloc_pages(struct fscache_coo= kie *cookie, goto nobufs_unlock; spin_unlock(&cookie->lock); =20 @@ -44044,7 +45271,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 /* pin the netfs read context in case we need to do the actual netfs * read because we've encountered a cache read failure */ -@@ -527,15 +527,15 @@ int __fscache_read_or_alloc_pages(struct +@@ -527,15 +527,15 @@ int __fscache_read_or_alloc_pages(struct fscache_c= ookie *cookie, =20 error: if (ret =3D=3D -ENOMEM) @@ -44074,7 +45301,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c _leave(" =3D -ENOBUFS"); return -ENOBUFS; } -@@ -569,7 +569,7 @@ int __fscache_alloc_page(struct fscache_ +@@ -569,7 +569,7 @@ int __fscache_alloc_page(struct fscache_cookie *cook= ie, =20 _enter("%p,%p,,,", cookie, page); =20 @@ -44083,7 +45310,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 if (hlist_empty(&cookie->backing_objects)) goto nobufs; -@@ -595,7 +595,7 @@ int __fscache_alloc_page(struct fscache_ +@@ -595,7 +595,7 @@ int __fscache_alloc_page(struct fscache_cookie *cook= ie, goto nobufs_unlock; spin_unlock(&cookie->lock); =20 @@ -44092,7 +45319,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 ret =3D fscache_wait_for_retrieval_activation( object, op, -@@ -611,11 +611,11 @@ int __fscache_alloc_page(struct fscache_ +@@ -611,11 +611,11 @@ int __fscache_alloc_page(struct fscache_cookie *co= okie, =20 error: if (ret =3D=3D -ERESTARTSYS) @@ -44116,7 +45343,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c _leave(" =3D -ENOBUFS"); return -ENOBUFS; } -@@ -666,7 +666,7 @@ static void fscache_write_op(struct fsca +@@ -666,7 +666,7 @@ static void fscache_write_op(struct fscache_operatio= n *_op) =20 spin_lock(&cookie->stores_lock); =20 @@ -44125,7 +45352,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 /* find a page to store */ page =3D NULL; -@@ -677,7 +677,7 @@ static void fscache_write_op(struct fsca +@@ -677,7 +677,7 @@ static void fscache_write_op(struct fscache_operatio= n *_op) page =3D results[0]; _debug("gang %d [%lx]", n, page->index); if (page->index > op->store_limit) { @@ -44134,7 +45361,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c goto superseded; } =20 -@@ -689,7 +689,7 @@ static void fscache_write_op(struct fsca +@@ -689,7 +689,7 @@ static void fscache_write_op(struct fscache_operatio= n *_op) spin_unlock(&cookie->stores_lock); spin_unlock(&object->lock); =20 @@ -44143,7 +45370,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c fscache_stat(&fscache_n_cop_write_page); ret =3D object->cache->ops->write_page(op, page); fscache_stat_d(&fscache_n_cop_write_page); -@@ -757,7 +757,7 @@ int __fscache_write_page(struct fscache_ +@@ -757,7 +757,7 @@ int __fscache_write_page(struct fscache_cookie *cook= ie, ASSERTCMP(cookie->def->type, !=3D, FSCACHE_COOKIE_TYPE_INDEX); ASSERT(PageFsCache(page)); =20 @@ -44152,7 +45379,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 op =3D kzalloc(sizeof(*op), GFP_NOIO); if (!op) -@@ -808,7 +808,7 @@ int __fscache_write_page(struct fscache_ +@@ -808,7 +808,7 @@ int __fscache_write_page(struct fscache_cookie *cook= ie, spin_unlock(&cookie->stores_lock); spin_unlock(&object->lock); =20 @@ -44161,7 +45388,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c op->store_limit =3D object->store_limit; =20 if (fscache_submit_op(object, &op->op) < 0) -@@ -816,8 +816,8 @@ int __fscache_write_page(struct fscache_ +@@ -816,8 +816,8 @@ int __fscache_write_page(struct fscache_cookie *cook= ie, =20 spin_unlock(&cookie->lock); radix_tree_preload_end(); @@ -44172,7 +45399,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 /* the work queue now carries its own ref on the object */ fscache_put_operation(&op->op); -@@ -825,14 +825,14 @@ int __fscache_write_page(struct fscache_ +@@ -825,14 +825,14 @@ int __fscache_write_page(struct fscache_cookie *co= okie, return 0; =20 already_queued: @@ -44206,7 +45433,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c _leave(" =3D -ENOMEM"); return -ENOMEM; } -@@ -876,7 +876,7 @@ void __fscache_uncache_page(struct fscac +@@ -876,7 +876,7 @@ void __fscache_uncache_page(struct fscache_cookie *c= ookie, struct page *page) ASSERTCMP(cookie->def->type, !=3D, FSCACHE_COOKIE_TYPE_INDEX); ASSERTCMP(page, !=3D, NULL); =20 @@ -44215,7 +45442,7 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3.= 1.4/fs/fscache/page.c =20 /* cache withdrawal may beat us to it */ if (!PageFsCache(page)) -@@ -929,7 +929,7 @@ void fscache_mark_pages_cached(struct fs +@@ -929,7 +929,7 @@ void fscache_mark_pages_cached(struct fscache_retrie= val *op, unsigned long loop; =20 #ifdef CONFIG_FSCACHE_STATS @@ -44224,9 +45451,10 @@ diff -urNp linux-3.1.4/fs/fscache/page.c linux-3= .1.4/fs/fscache/page.c #endif =20 for (loop =3D 0; loop < pagevec->nr; loop++) { -diff -urNp linux-3.1.4/fs/fscache/stats.c linux-3.1.4/fs/fscache/stats.c ---- linux-3.1.4/fs/fscache/stats.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fscache/stats.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/fscache/stats.c b/fs/fscache/stats.c +index 4765190..2a067f2 100644 +--- a/fs/fscache/stats.c ++++ b/fs/fscache/stats.c @@ -18,95 +18,95 @@ /* * operation counters @@ -44412,7 +45640,7 @@ diff -urNp linux-3.1.4/fs/fscache/stats.c linux-3= .1.4/fs/fscache/stats.c =20 atomic_t fscache_n_cop_alloc_object; atomic_t fscache_n_cop_lookup_object; -@@ -133,113 +133,113 @@ static int fscache_stats_show(struct seq +@@ -133,113 +133,113 @@ static int fscache_stats_show(struct seq_file *m= , void *v) seq_puts(m, "FS-Cache statistics\n"); =20 seq_printf(m, "Cookies: idx=3D%u dat=3D%u spc=3D%u\n", @@ -44602,101 +45830,10 @@ diff -urNp linux-3.1.4/fs/fscache/stats.c linu= x-3.1.4/fs/fscache/stats.c =20 seq_printf(m, "CacheOp: alo=3D%d luo=3D%d luc=3D%d gro=3D%d\n", atomic_read(&fscache_n_cop_alloc_object), -diff -urNp linux-3.1.4/fs/fs_struct.c linux-3.1.4/fs/fs_struct.c ---- linux-3.1.4/fs/fs_struct.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fs_struct.c 2011-11-16 18:40:29.000000000 -0500 -@@ -4,6 +4,7 @@ - #include - #include - #include -+#include - #include "internal.h" -=20 - static inline void path_get_longterm(struct path *path) -@@ -31,6 +32,7 @@ void set_fs_root(struct fs_struct *fs, s - old_root =3D fs->root; - fs->root =3D *path; - path_get_longterm(path); -+ gr_set_chroot_entries(current, path); - write_seqcount_end(&fs->seq); - spin_unlock(&fs->lock); - if (old_root.dentry) -@@ -74,6 +76,7 @@ void chroot_fs_refs(struct path *old_roo - && fs->root.mnt =3D=3D old_root->mnt) { - path_get_longterm(new_root); - fs->root =3D *new_root; -+ gr_set_chroot_entries(p, new_root); - count++; - } - if (fs->pwd.dentry =3D=3D old_root->dentry -@@ -109,7 +112,8 @@ void exit_fs(struct task_struct *tsk) - spin_lock(&fs->lock); - write_seqcount_begin(&fs->seq); - tsk->fs =3D NULL; -- kill =3D !--fs->users; -+ gr_clear_chroot_entries(tsk); -+ kill =3D !atomic_dec_return(&fs->users); - write_seqcount_end(&fs->seq); - spin_unlock(&fs->lock); - task_unlock(tsk); -@@ -123,7 +127,7 @@ struct fs_struct *copy_fs_struct(struct=20 - struct fs_struct *fs =3D kmem_cache_alloc(fs_cachep, GFP_KERNEL); - /* We don't need to lock fs - think why ;-) */ - if (fs) { -- fs->users =3D 1; -+ atomic_set(&fs->users, 1); - fs->in_exec =3D 0; - spin_lock_init(&fs->lock); - seqcount_init(&fs->seq); -@@ -132,6 +136,9 @@ struct fs_struct *copy_fs_struct(struct=20 - spin_lock(&old->lock); - fs->root =3D old->root; - path_get_longterm(&fs->root); -+ /* instead of calling gr_set_chroot_entries here, -+ we call it from every caller of this function -+ */ - fs->pwd =3D old->pwd; - path_get_longterm(&fs->pwd); - spin_unlock(&old->lock); -@@ -150,8 +157,9 @@ int unshare_fs_struct(void) -=20 - task_lock(current); - spin_lock(&fs->lock); -- kill =3D !--fs->users; -+ kill =3D !atomic_dec_return(&fs->users); - current->fs =3D new_fs; -+ gr_set_chroot_entries(current, &new_fs->root); - spin_unlock(&fs->lock); - task_unlock(current); -=20 -@@ -170,7 +178,7 @@ EXPORT_SYMBOL(current_umask); -=20 - /* to be mentioned only in INIT_TASK */ - struct fs_struct init_fs =3D { -- .users =3D 1, -+ .users =3D ATOMIC_INIT(1), - .lock =3D __SPIN_LOCK_UNLOCKED(init_fs.lock), - .seq =3D SEQCNT_ZERO, - .umask =3D 0022, -@@ -186,12 +194,13 @@ void daemonize_fs_struct(void) - task_lock(current); -=20 - spin_lock(&init_fs.lock); -- init_fs.users++; -+ atomic_inc(&init_fs.users); - spin_unlock(&init_fs.lock); -=20 - spin_lock(&fs->lock); - current->fs =3D &init_fs; -- kill =3D !--fs->users; -+ gr_set_chroot_entries(current, ¤t->fs->root); -+ kill =3D !atomic_dec_return(&fs->users); - spin_unlock(&fs->lock); -=20 - task_unlock(current); -diff -urNp linux-3.1.4/fs/fuse/cuse.c linux-3.1.4/fs/fuse/cuse.c ---- linux-3.1.4/fs/fuse/cuse.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fuse/cuse.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/fuse/cuse.c b/fs/fuse/cuse.c +index b6cca47..ec782c3 100644 +--- a/fs/fuse/cuse.c ++++ b/fs/fuse/cuse.c @@ -586,10 +586,12 @@ static int __init cuse_init(void) INIT_LIST_HEAD(&cuse_conntbl[i]); =20 @@ -44714,10 +45851,11 @@ diff -urNp linux-3.1.4/fs/fuse/cuse.c linux-3.1= .4/fs/fuse/cuse.c =20 cuse_class =3D class_create(THIS_MODULE, "cuse"); if (IS_ERR(cuse_class)) -diff -urNp linux-3.1.4/fs/fuse/dev.c linux-3.1.4/fs/fuse/dev.c ---- linux-3.1.4/fs/fuse/dev.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fuse/dev.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1242,7 +1242,7 @@ static ssize_t fuse_dev_splice_read(stru +diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c +index 5cb8614..6865b11 100644 +--- a/fs/fuse/dev.c ++++ b/fs/fuse/dev.c +@@ -1242,7 +1242,7 @@ static ssize_t fuse_dev_splice_read(struct file *i= n, loff_t *ppos, ret =3D 0; pipe_lock(pipe); =20 @@ -44726,10 +45864,11 @@ diff -urNp linux-3.1.4/fs/fuse/dev.c linux-3.1.= 4/fs/fuse/dev.c send_sig(SIGPIPE, current, 0); if (!ret) ret =3D -EPIPE; -diff -urNp linux-3.1.4/fs/fuse/dir.c linux-3.1.4/fs/fuse/dir.c ---- linux-3.1.4/fs/fuse/dir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/fuse/dir.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1147,7 +1147,7 @@ static char *read_link(struct dentry *de +diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c +index 9f63e49..d8a64c0 100644 +--- a/fs/fuse/dir.c ++++ b/fs/fuse/dir.c +@@ -1147,7 +1147,7 @@ static char *read_link(struct dentry *dentry) return link; } =20 @@ -44738,9 +45877,10 @@ diff -urNp linux-3.1.4/fs/fuse/dir.c linux-3.1.4= /fs/fuse/dir.c { if (!IS_ERR(link)) free_page((unsigned long) link); -diff -urNp linux-3.1.4/fs/gfs2/inode.c linux-3.1.4/fs/gfs2/inode.c ---- linux-3.1.4/fs/gfs2/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/gfs2/inode.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c +index 900cf98..3896726 100644 +--- a/fs/gfs2/inode.c ++++ b/fs/gfs2/inode.c @@ -1517,7 +1517,7 @@ out: =20 static void gfs2_put_link(struct dentry *dentry, struct nameidata *nd, = void *p) @@ -44750,10 +45890,11 @@ diff -urNp linux-3.1.4/fs/gfs2/inode.c linux-3.= 1.4/fs/gfs2/inode.c if (!IS_ERR(s)) kfree(s); } -diff -urNp linux-3.1.4/fs/hfs/btree.c linux-3.1.4/fs/hfs/btree.c ---- linux-3.1.4/fs/hfs/btree.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/hfs/btree.c 2011-11-18 18:48:11.000000000 -0500 -@@ -46,11 +46,27 @@ struct hfs_btree *hfs_btree_open(struct=20 +diff --git a/fs/hfs/btree.c b/fs/hfs/btree.c +index 3ebc437..eb23952 100644 +--- a/fs/hfs/btree.c ++++ b/fs/hfs/btree.c +@@ -46,11 +46,27 @@ struct hfs_btree *hfs_btree_open(struct super_block = *sb, u32 id, btree_keycmp ke case HFS_EXT_CNID: hfs_inode_read_fork(tree->inode, mdb->drXTExtRec, mdb->drXTFlSize, mdb->drXTFlSize, be32_to_cpu(mdb->drXTClpSiz)); @@ -44781,7 +45922,7 @@ diff -urNp linux-3.1.4/fs/hfs/btree.c linux-3.1.4= /fs/hfs/btree.c tree->inode->i_mapping->a_ops =3D &hfs_btree_aops; break; default: -@@ -59,11 +75,6 @@ struct hfs_btree *hfs_btree_open(struct=20 +@@ -59,11 +75,6 @@ struct hfs_btree *hfs_btree_open(struct super_block *= sb, u32 id, btree_keycmp ke } unlock_new_inode(tree->inode); =20 @@ -44793,10 +45934,11 @@ diff -urNp linux-3.1.4/fs/hfs/btree.c linux-3.1= .4/fs/hfs/btree.c mapping =3D tree->inode->i_mapping; page =3D read_mapping_page(mapping, 0, NULL); if (IS_ERR(page)) -diff -urNp linux-3.1.4/fs/hfsplus/catalog.c linux-3.1.4/fs/hfsplus/catal= og.c ---- linux-3.1.4/fs/hfsplus/catalog.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/hfsplus/catalog.c 2011-11-16 19:23:09.000000000 -0500 -@@ -179,6 +179,8 @@ int hfsplus_find_cat(struct super_block=20 +diff --git a/fs/hfsplus/catalog.c b/fs/hfsplus/catalog.c +index 4dfbfec..947c9c2 100644 +--- a/fs/hfsplus/catalog.c ++++ b/fs/hfsplus/catalog.c +@@ -179,6 +179,8 @@ int hfsplus_find_cat(struct super_block *sb, u32 cni= d, int err; u16 type; =20 @@ -44805,7 +45947,7 @@ diff -urNp linux-3.1.4/fs/hfsplus/catalog.c linux= -3.1.4/fs/hfsplus/catalog.c hfsplus_cat_build_key(sb, fd->search_key, cnid, NULL); err =3D hfs_brec_read(fd, &tmp, sizeof(hfsplus_cat_entry)); if (err) -@@ -210,6 +212,8 @@ int hfsplus_create_cat(u32 cnid, struct=20 +@@ -210,6 +212,8 @@ int hfsplus_create_cat(u32 cnid, struct inode *dir, int entry_size; int err; =20 @@ -44823,10 +45965,11 @@ diff -urNp linux-3.1.4/fs/hfsplus/catalog.c lin= ux-3.1.4/fs/hfsplus/catalog.c dprint(DBG_CAT_MOD, "rename_cat: %u - %lu,%s - %lu,%s\n", cnid, src_dir->i_ino, src_name->name, dst_dir->i_ino, dst_name->name); -diff -urNp linux-3.1.4/fs/hfsplus/dir.c linux-3.1.4/fs/hfsplus/dir.c ---- linux-3.1.4/fs/hfsplus/dir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/hfsplus/dir.c 2011-11-16 18:40:29.000000000 -0500 -@@ -131,6 +131,8 @@ static int hfsplus_readdir(struct file * +diff --git a/fs/hfsplus/dir.c b/fs/hfsplus/dir.c +index 25b2443..09a3341 100644 +--- a/fs/hfsplus/dir.c ++++ b/fs/hfsplus/dir.c +@@ -131,6 +131,8 @@ static int hfsplus_readdir(struct file *filp, void *= dirent, filldir_t filldir) struct hfsplus_readdir_data *rd; u16 type; =20 @@ -44835,10 +45978,11 @@ diff -urNp linux-3.1.4/fs/hfsplus/dir.c linux-3= .1.4/fs/hfsplus/dir.c if (filp->f_pos >=3D inode->i_size) return 0; =20 -diff -urNp linux-3.1.4/fs/hfsplus/inode.c linux-3.1.4/fs/hfsplus/inode.c ---- linux-3.1.4/fs/hfsplus/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/hfsplus/inode.c 2011-11-16 18:40:29.000000000 -0500 -@@ -501,6 +501,8 @@ int hfsplus_cat_read_inode(struct inode=20 +diff --git a/fs/hfsplus/inode.c b/fs/hfsplus/inode.c +index 4cc1e3a..ad0f70b 100644 +--- a/fs/hfsplus/inode.c ++++ b/fs/hfsplus/inode.c +@@ -501,6 +501,8 @@ int hfsplus_cat_read_inode(struct inode *inode, stru= ct hfs_find_data *fd) int res =3D 0; u16 type; =20 @@ -44847,7 +45991,7 @@ diff -urNp linux-3.1.4/fs/hfsplus/inode.c linux-3= .1.4/fs/hfsplus/inode.c type =3D hfs_bnode_read_u16(fd->bnode, fd->entryoffset); =20 HFSPLUS_I(inode)->linkid =3D 0; -@@ -564,6 +566,8 @@ int hfsplus_cat_write_inode(struct inode +@@ -564,6 +566,8 @@ int hfsplus_cat_write_inode(struct inode *inode) struct hfs_find_data fd; hfsplus_cat_entry entry; =20 @@ -44856,10 +46000,11 @@ diff -urNp linux-3.1.4/fs/hfsplus/inode.c linux= -3.1.4/fs/hfsplus/inode.c if (HFSPLUS_IS_RSRC(inode)) main_inode =3D HFSPLUS_I(inode)->rsrc_inode; =20 -diff -urNp linux-3.1.4/fs/hfsplus/ioctl.c linux-3.1.4/fs/hfsplus/ioctl.c ---- linux-3.1.4/fs/hfsplus/ioctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/hfsplus/ioctl.c 2011-11-16 18:40:29.000000000 -0500 -@@ -122,6 +122,8 @@ int hfsplus_setxattr(struct dentry *dent +diff --git a/fs/hfsplus/ioctl.c b/fs/hfsplus/ioctl.c +index fbaa669..c548cd0 100644 +--- a/fs/hfsplus/ioctl.c ++++ b/fs/hfsplus/ioctl.c +@@ -122,6 +122,8 @@ int hfsplus_setxattr(struct dentry *dentry, const ch= ar *name, struct hfsplus_cat_file *file; int res; =20 @@ -44868,7 +46013,7 @@ diff -urNp linux-3.1.4/fs/hfsplus/ioctl.c linux-3= .1.4/fs/hfsplus/ioctl.c if (!S_ISREG(inode->i_mode) || HFSPLUS_IS_RSRC(inode)) return -EOPNOTSUPP; =20 -@@ -166,6 +168,8 @@ ssize_t hfsplus_getxattr(struct dentry * +@@ -166,6 +168,8 @@ ssize_t hfsplus_getxattr(struct dentry *dentry, cons= t char *name, struct hfsplus_cat_file *file; ssize_t res =3D 0; =20 @@ -44877,10 +46022,11 @@ diff -urNp linux-3.1.4/fs/hfsplus/ioctl.c linux= -3.1.4/fs/hfsplus/ioctl.c if (!S_ISREG(inode->i_mode) || HFSPLUS_IS_RSRC(inode)) return -EOPNOTSUPP; =20 -diff -urNp linux-3.1.4/fs/hfsplus/super.c linux-3.1.4/fs/hfsplus/super.c ---- linux-3.1.4/fs/hfsplus/super.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/hfsplus/super.c 2011-11-16 19:23:30.000000000 -0500 -@@ -347,6 +347,8 @@ static int hfsplus_fill_super(struct sup +diff --git a/fs/hfsplus/super.c b/fs/hfsplus/super.c +index d24a9b6..dd9b3dd 100644 +--- a/fs/hfsplus/super.c ++++ b/fs/hfsplus/super.c +@@ -347,6 +347,8 @@ static int hfsplus_fill_super(struct super_block *sb= , void *data, int silent) u64 last_fs_block, last_fs_page; int err; =20 @@ -44889,10 +46035,11 @@ diff -urNp linux-3.1.4/fs/hfsplus/super.c linux= -3.1.4/fs/hfsplus/super.c err =3D -EINVAL; sbi =3D kzalloc(sizeof(*sbi), GFP_KERNEL); if (!sbi) -diff -urNp linux-3.1.4/fs/hugetlbfs/inode.c linux-3.1.4/fs/hugetlbfs/ino= de.c ---- linux-3.1.4/fs/hugetlbfs/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/hugetlbfs/inode.c 2011-11-16 18:40:29.000000000 -0500 -@@ -915,7 +915,7 @@ static struct file_system_type hugetlbfs +diff --git a/fs/hugetlbfs/inode.c b/fs/hugetlbfs/inode.c +index ec88953..cb5e98e 100644 +--- a/fs/hugetlbfs/inode.c ++++ b/fs/hugetlbfs/inode.c +@@ -915,7 +915,7 @@ static struct file_system_type hugetlbfs_fs_type =3D= { .kill_sb =3D kill_litter_super, }; =20 @@ -44901,9 +46048,10 @@ diff -urNp linux-3.1.4/fs/hugetlbfs/inode.c linu= x-3.1.4/fs/hugetlbfs/inode.c =20 static int can_do_hugetlb_shm(void) { -diff -urNp linux-3.1.4/fs/inode.c linux-3.1.4/fs/inode.c ---- linux-3.1.4/fs/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/inode.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/inode.c b/fs/inode.c +index ec79246..054c36a 100644 +--- a/fs/inode.c ++++ b/fs/inode.c @@ -787,8 +787,8 @@ unsigned int get_next_ino(void) =20 #ifdef CONFIG_SMP @@ -44915,10 +46063,11 @@ diff -urNp linux-3.1.4/fs/inode.c linux-3.1.4/f= s/inode.c =20 res =3D next - LAST_INO_BATCH; } -diff -urNp linux-3.1.4/fs/jbd/checkpoint.c linux-3.1.4/fs/jbd/checkpoint= .c ---- linux-3.1.4/fs/jbd/checkpoint.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/jbd/checkpoint.c 2011-11-16 18:40:29.000000000 -0500 -@@ -358,6 +358,8 @@ int log_do_checkpoint(journal_t *journal +diff --git a/fs/jbd/checkpoint.c b/fs/jbd/checkpoint.c +index f94fc48..3bb8d30 100644 +--- a/fs/jbd/checkpoint.c ++++ b/fs/jbd/checkpoint.c +@@ -358,6 +358,8 @@ int log_do_checkpoint(journal_t *journal) tid_t this_tid; int result; =20 @@ -44927,10 +46076,11 @@ diff -urNp linux-3.1.4/fs/jbd/checkpoint.c linu= x-3.1.4/fs/jbd/checkpoint.c jbd_debug(1, "Start checkpoint\n"); =20 /* -diff -urNp linux-3.1.4/fs/jffs2/compr_rtime.c linux-3.1.4/fs/jffs2/compr= _rtime.c ---- linux-3.1.4/fs/jffs2/compr_rtime.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/fs/jffs2/compr_rtime.c 2011-11-16 18:40:29.000000000 -05= 00 -@@ -37,6 +37,8 @@ static int jffs2_rtime_compress(unsigned +diff --git a/fs/jffs2/compr_rtime.c b/fs/jffs2/compr_rtime.c +index 16a5047..88ff6ca 100644 +--- a/fs/jffs2/compr_rtime.c ++++ b/fs/jffs2/compr_rtime.c +@@ -37,6 +37,8 @@ static int jffs2_rtime_compress(unsigned char *data_in= , int outpos =3D 0; int pos=3D0; =20 @@ -44939,7 +46089,7 @@ diff -urNp linux-3.1.4/fs/jffs2/compr_rtime.c lin= ux-3.1.4/fs/jffs2/compr_rtime.c memset(positions,0,sizeof(positions)); =20 while (pos < (*sourcelen) && outpos <=3D (*dstlen)-2) { -@@ -78,6 +80,8 @@ static int jffs2_rtime_decompress(unsign +@@ -78,6 +80,8 @@ static int jffs2_rtime_decompress(unsigned char *data_= in, int outpos =3D 0; int pos=3D0; =20 @@ -44948,10 +46098,11 @@ diff -urNp linux-3.1.4/fs/jffs2/compr_rtime.c l= inux-3.1.4/fs/jffs2/compr_rtime.c memset(positions,0,sizeof(positions)); =20 while (outposflags & JFFS2_SB_FLAG_BUILDING)); =20 @@ -44998,9 +46152,10 @@ diff -urNp linux-3.1.4/fs/jffs2/xattr.c linux-3.= 1.4/fs/jffs2/xattr.c /* Phase.1 : Merge same xref */ for (i=3D0; i < XREF_TMPHASH_SIZE; i++) xref_tmphash[i] =3D NULL; -diff -urNp linux-3.1.4/fs/jfs/super.c linux-3.1.4/fs/jfs/super.c ---- linux-3.1.4/fs/jfs/super.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/jfs/super.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/jfs/super.c b/fs/jfs/super.c +index 06c8a67..589dbbd 100644 +--- a/fs/jfs/super.c ++++ b/fs/jfs/super.c @@ -803,7 +803,7 @@ static int __init init_jfs_fs(void) =20 jfs_inode_cachep =3D @@ -45010,22 +46165,11 @@ diff -urNp linux-3.1.4/fs/jfs/super.c linux-3.1= .4/fs/jfs/super.c init_once); if (jfs_inode_cachep =3D=3D NULL) return -ENOMEM; -diff -urNp linux-3.1.4/fs/Kconfig.binfmt linux-3.1.4/fs/Kconfig.binfmt ---- linux-3.1.4/fs/Kconfig.binfmt 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/Kconfig.binfmt 2011-11-16 18:39:08.000000000 -0500 -@@ -86,7 +86,7 @@ config HAVE_AOUT -=20 - config BINFMT_AOUT - tristate "Kernel support for a.out and ECOFF binaries" -- depends on HAVE_AOUT -+ depends on HAVE_AOUT && BROKEN - ---help--- - A.out (Assembler.OUTput) is a set of formats for libraries and - executables used in the earliest versions of UNIX. Linux used -diff -urNp linux-3.1.4/fs/libfs.c linux-3.1.4/fs/libfs.c ---- linux-3.1.4/fs/libfs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/libfs.c 2011-11-16 18:39:08.000000000 -0500 -@@ -165,6 +165,9 @@ int dcache_readdir(struct file * filp, v +diff --git a/fs/libfs.c b/fs/libfs.c +index c18e9a1..0b04e2c 100644 +--- a/fs/libfs.c ++++ b/fs/libfs.c +@@ -165,6 +165,9 @@ int dcache_readdir(struct file * filp, void * dirent= , filldir_t filldir) =20 for (p=3Dq->next; p !=3D &dentry->d_subdirs; p=3Dp->next) { struct dentry *next; @@ -45035,7 +46179,7 @@ diff -urNp linux-3.1.4/fs/libfs.c linux-3.1.4/fs/= libfs.c next =3D list_entry(p, struct dentry, d_u.d_child); spin_lock_nested(&next->d_lock, DENTRY_D_LOCK_NESTED); if (!simple_positive(next)) { -@@ -174,7 +177,12 @@ int dcache_readdir(struct file * filp, v +@@ -174,7 +177,12 @@ int dcache_readdir(struct file * filp, void * diren= t, filldir_t filldir) =20 spin_unlock(&next->d_lock); spin_unlock(&dentry->d_lock); @@ -45049,10 +46193,11 @@ diff -urNp linux-3.1.4/fs/libfs.c linux-3.1.4/f= s/libfs.c next->d_name.len, filp->f_pos,=20 next->d_inode->i_ino,=20 dt_type(next->d_inode)) < 0) -diff -urNp linux-3.1.4/fs/lockd/clntproc.c linux-3.1.4/fs/lockd/clntproc= .c ---- linux-3.1.4/fs/lockd/clntproc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/lockd/clntproc.c 2011-11-16 18:40:29.000000000 -0500 -@@ -36,11 +36,11 @@ static const struct rpc_call_ops nlmclnt +diff --git a/fs/lockd/clntproc.c b/fs/lockd/clntproc.c +index 8392cb8..ae8ed40 100644 +--- a/fs/lockd/clntproc.c ++++ b/fs/lockd/clntproc.c +@@ -36,11 +36,11 @@ static const struct rpc_call_ops nlmclnt_cancel_ops; /* * Cookie counter for NLM requests */ @@ -45066,7 +46211,7 @@ diff -urNp linux-3.1.4/fs/lockd/clntproc.c linux-= 3.1.4/fs/lockd/clntproc.c =20 memcpy(c->data, &cookie, 4); c->len=3D4; -@@ -621,6 +621,8 @@ nlmclnt_reclaim(struct nlm_host *host, s +@@ -621,6 +621,8 @@ nlmclnt_reclaim(struct nlm_host *host, struct file_l= ock *fl) struct nlm_rqst reqst, *req; int status; =20 @@ -45075,10 +46220,11 @@ diff -urNp linux-3.1.4/fs/lockd/clntproc.c linu= x-3.1.4/fs/lockd/clntproc.c req =3D &reqst; memset(req, 0, sizeof(*req)); locks_init_lock(&req->a_args.lock.fl); -diff -urNp linux-3.1.4/fs/locks.c linux-3.1.4/fs/locks.c ---- linux-3.1.4/fs/locks.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/locks.c 2011-11-16 18:39:08.000000000 -0500 -@@ -2022,16 +2022,16 @@ void locks_remove_flock(struct file *fil +diff --git a/fs/locks.c b/fs/locks.c +index 703f545..150a552 100644 +--- a/fs/locks.c ++++ b/fs/locks.c +@@ -2022,16 +2022,16 @@ void locks_remove_flock(struct file *filp) return; =20 if (filp->f_op && filp->f_op->flock) { @@ -45099,10 +46245,11 @@ diff -urNp linux-3.1.4/fs/locks.c linux-3.1.4/f= s/locks.c } =20 lock_flocks(); -diff -urNp linux-3.1.4/fs/logfs/super.c linux-3.1.4/fs/logfs/super.c ---- linux-3.1.4/fs/logfs/super.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/logfs/super.c 2011-11-16 18:40:29.000000000 -0500 -@@ -266,6 +266,8 @@ static int logfs_recover_sb(struct super +diff --git a/fs/logfs/super.c b/fs/logfs/super.c +index ce03a18..ac8c14f 100644 +--- a/fs/logfs/super.c ++++ b/fs/logfs/super.c +@@ -266,6 +266,8 @@ static int logfs_recover_sb(struct super_block *sb) struct logfs_disk_super _ds1, *ds1 =3D &_ds1; int err, valid0, valid1; =20 @@ -45111,17 +46258,148 @@ diff -urNp linux-3.1.4/fs/logfs/super.c linux-= 3.1.4/fs/logfs/super.c /* read first superblock */ err =3D wbuf_read(sb, super->s_sb_ofs[0], sizeof(*ds0), ds0); if (err) -diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/namei.c ---- linux-3.1.4/fs/namei.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/namei.c 2011-11-17 00:36:54.000000000 -0500 -@@ -283,14 +283,22 @@ int generic_permission(struct inode *ino +diff --git a/fs/minix/bitmap.c b/fs/minix/bitmap.c +index 3f32bcb..7c82c29 100644 +--- a/fs/minix/bitmap.c ++++ b/fs/minix/bitmap.c +@@ -20,10 +20,11 @@ static const int nibblemap[] =3D { 4,3,3,2,3,2,2,1,3= ,2,2,1,2,1,1,0 }; +=20 + static DEFINE_SPINLOCK(bitmap_lock); +=20 +-static unsigned long count_free(struct buffer_head *map[], unsigned num= blocks, __u32 numbits) ++static unsigned long count_free(struct buffer_head *map[], unsigned blo= cksize, __u32 numbits) + { + unsigned i, j, sum =3D 0; + struct buffer_head *bh; ++ unsigned numblocks =3D minix_blocks_needed(numbits, blocksize); + =20 + for (i=3D0; is_zmap, sbi->s_zmap_blocks, +- sbi->s_nzones - sbi->s_firstdatazone + 1) ++ struct minix_sb_info *sbi =3D minix_sb(sb); ++ u32 bits =3D sbi->s_nzones - (sbi->s_firstdatazone + 1); ++ ++ return (count_free(sbi->s_zmap, sb->s_blocksize, bits) + << sbi->s_log_zone_size); + } +=20 +@@ -273,7 +276,10 @@ struct inode *minix_new_inode(const struct inode *d= ir, int mode, int *error) + return inode; + } +=20 +-unsigned long minix_count_free_inodes(struct minix_sb_info *sbi) ++unsigned long minix_count_free_inodes(struct super_block *sb) + { +- return count_free(sbi->s_imap, sbi->s_imap_blocks, sbi->s_ninodes + 1)= ; ++ struct minix_sb_info *sbi =3D minix_sb(sb); ++ u32 bits =3D sbi->s_ninodes + 1; ++ ++ return count_free(sbi->s_imap, sb->s_blocksize, bits); + } +diff --git a/fs/minix/inode.c b/fs/minix/inode.c +index e7d23e2..1ed1351 100644 +--- a/fs/minix/inode.c ++++ b/fs/minix/inode.c +@@ -279,6 +279,27 @@ static int minix_fill_super(struct super_block *s, = void *data, int silent) + else if (sbi->s_mount_state & MINIX_ERROR_FS) + printk("MINIX-fs: mounting file system with errors, " + "running fsck is recommended\n"); ++ ++ /* Apparently minix can create filesystems that allocate more blocks f= or ++ * the bitmaps than needed. We simply ignore that, but verify it didn= 't ++ * create one with not enough blocks and bail out if so. ++ */ ++ block =3D minix_blocks_needed(sbi->s_ninodes, s->s_blocksize); ++ if (sbi->s_imap_blocks < block) { ++ printk("MINIX-fs: file system does not have enough " ++ "imap blocks allocated. Refusing to mount\n"); ++ goto out_iput; ++ } ++ ++ block =3D minix_blocks_needed( ++ (sbi->s_nzones - (sbi->s_firstdatazone + 1)), ++ s->s_blocksize); ++ if (sbi->s_zmap_blocks < block) { ++ printk("MINIX-fs: file system does not have enough " ++ "zmap blocks allocated. Refusing to mount.\n"); ++ goto out_iput; ++ } ++ + return 0; +=20 + out_iput: +@@ -339,10 +360,10 @@ static int minix_statfs(struct dentry *dentry, str= uct kstatfs *buf) + buf->f_type =3D sb->s_magic; + buf->f_bsize =3D sb->s_blocksize; + buf->f_blocks =3D (sbi->s_nzones - sbi->s_firstdatazone) << sbi->s_log= _zone_size; +- buf->f_bfree =3D minix_count_free_blocks(sbi); ++ buf->f_bfree =3D minix_count_free_blocks(sb); + buf->f_bavail =3D buf->f_bfree; + buf->f_files =3D sbi->s_ninodes; +- buf->f_ffree =3D minix_count_free_inodes(sbi); ++ buf->f_ffree =3D minix_count_free_inodes(sb); + buf->f_namelen =3D sbi->s_namelen; + buf->f_fsid.val[0] =3D (u32)id; + buf->f_fsid.val[1] =3D (u32)(id >> 32); +diff --git a/fs/minix/minix.h b/fs/minix/minix.h +index 341e212..6415fe0 100644 +--- a/fs/minix/minix.h ++++ b/fs/minix/minix.h +@@ -48,10 +48,10 @@ extern struct minix_inode * minix_V1_raw_inode(struc= t super_block *, ino_t, stru + extern struct minix2_inode * minix_V2_raw_inode(struct super_block *, i= no_t, struct buffer_head **); + extern struct inode * minix_new_inode(const struct inode *, int, int *)= ; + extern void minix_free_inode(struct inode * inode); +-extern unsigned long minix_count_free_inodes(struct minix_sb_info *sbi)= ; ++extern unsigned long minix_count_free_inodes(struct super_block *sb); + extern int minix_new_block(struct inode * inode); + extern void minix_free_block(struct inode *inode, unsigned long block); +-extern unsigned long minix_count_free_blocks(struct minix_sb_info *sbi)= ; ++extern unsigned long minix_count_free_blocks(struct super_block *sb); + extern int minix_getattr(struct vfsmount *, struct dentry *, struct kst= at *); + extern int minix_prepare_chunk(struct page *page, loff_t pos, unsigned = len); +=20 +@@ -88,6 +88,11 @@ static inline struct minix_inode_info *minix_i(struct= inode *inode) + return list_entry(inode, struct minix_inode_info, vfs_inode); + } +=20 ++static inline unsigned minix_blocks_needed(unsigned bits, unsigned bloc= ksize) ++{ ++ return DIV_ROUND_UP(bits, blocksize * 8); ++} ++ + #if defined(CONFIG_MINIX_FS_NATIVE_ENDIAN) && \ + defined(CONFIG_MINIX_FS_BIG_ENDIAN_16BIT_INDEXED) +=20 +diff --git a/fs/namei.c b/fs/namei.c +index 3d15072..c1ddf9c 100644 +--- a/fs/namei.c ++++ b/fs/namei.c +@@ -281,16 +281,32 @@ int generic_permission(struct inode *inode, int ma= sk) + if (ret !=3D -EACCES) + return ret; +=20 ++#ifdef CONFIG_GRKERNSEC ++ /* we'll block if we have to log due to a denied capability use */ ++ if (mask & MAY_NOT_BLOCK) ++ return -ECHILD; ++#endif ++ if (S_ISDIR(inode->i_mode)) { /* DACs are overridable for directories */ - if (ns_capable(inode_userns(inode), CAP_DAC_OVERRIDE)) - return 0; if (!(mask & MAY_WRITE)) - if (ns_capable(inode_userns(inode), CAP_DAC_READ_SEARCH)) +- if (ns_capable(inode_userns(inode), CAP_DAC_READ_SEARCH)) ++ if (ns_capable_nolog(inode_userns(inode), CAP_DAC_OVERRIDE) || ++ ns_capable(inode_userns(inode), CAP_DAC_READ_SEARCH)) return 0; + if (ns_capable(inode_userns(inode), CAP_DAC_OVERRIDE)) + return 0; @@ -45132,14 +46410,15 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/f= s/namei.c + */ + mask &=3D MAY_READ | MAY_WRITE | MAY_EXEC; + if (mask =3D=3D MAY_READ) -+ if (ns_capable(inode_userns(inode), CAP_DAC_READ_SEARCH)) ++ if (ns_capable_nolog(inode_userns(inode), CAP_DAC_OVERRIDE) || ++ ns_capable(inode_userns(inode), CAP_DAC_READ_SEARCH)) + return 0; + + /* * Read/write DACs are always overridable. * Executable DACs are overridable when there is * at least one exec bit set. -@@ -299,14 +307,6 @@ int generic_permission(struct inode *ino +@@ -299,14 +315,6 @@ int generic_permission(struct inode *inode, int mas= k) if (ns_capable(inode_userns(inode), CAP_DAC_OVERRIDE)) return 0; =20 @@ -45154,7 +46433,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c return -EACCES; } =20 -@@ -653,11 +653,19 @@ follow_link(struct path *link, struct na +@@ -653,11 +661,19 @@ follow_link(struct path *link, struct nameidata *n= d, void **p) return error; } =20 @@ -45175,30 +46454,45 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/f= s/namei.c error =3D 0; if (s) error =3D __vfs_follow_link(nd, s); -@@ -1622,6 +1630,12 @@ static int path_lookupat(int dfd, const=20 +@@ -1622,6 +1638,21 @@ static int path_lookupat(int dfd, const char *nam= e, if (!err) err =3D complete_walk(nd); =20 -+ if (!(nd->flags & LOOKUP_PARENT) && !gr_acl_handle_hidden_file(nd->pat= h.dentry, nd->path.mnt)) { -+ if (!err) -+ path_put(&nd->path); -+ err =3D -ENOENT; ++ if (!(nd->flags & LOOKUP_PARENT)) { ++#ifdef CONFIG_GRKERNSEC ++ if (flags & LOOKUP_RCU) { ++ if (!err) ++ path_put(&nd->path); ++ err =3D -ECHILD; ++ } else ++#endif ++ if (!gr_acl_handle_hidden_file(nd->path.dentry, nd->path.mnt)) { ++ if (!err) ++ path_put(&nd->path); ++ err =3D -ENOENT; ++ } + } + if (!err && nd->flags & LOOKUP_DIRECTORY) { if (!nd->inode->i_op->lookup) { path_put(&nd->path); -@@ -1649,6 +1663,9 @@ static int do_path_lookup(int dfd, const +@@ -1649,6 +1680,15 @@ static int do_path_lookup(int dfd, const char *na= me, retval =3D path_lookupat(dfd, name, flags | LOOKUP_REVAL, nd); =20 if (likely(!retval)) { -+ if (*name !=3D '/' && nd->path.dentry && nd->inode && !gr_chroot_fchd= ir(nd->path.dentry, nd->path.mnt)) -+ return -ENOENT; ++ if (*name !=3D '/' && nd->path.dentry && nd->inode) { ++#ifdef CONFIG_GRKERNSEC ++ if (flags & LOOKUP_RCU) ++ return -ECHILD; ++#endif ++ if (!gr_chroot_fchdir(nd->path.dentry, nd->path.mnt)) ++ return -ENOENT; ++ } + if (unlikely(!audit_dummy_context())) { if (nd->path.dentry && nd->inode) audit_inode(name, nd->path.dentry); -@@ -2049,7 +2066,27 @@ static int may_open(struct path *path, i +@@ -2049,7 +2089,27 @@ static int may_open(struct path *path, int acc_mo= de, int flag) /* * Ensure there are no outstanding leases on the file. */ @@ -45227,10 +46521,16 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/f= s/namei.c } =20 static int handle_truncate(struct file *filp) -@@ -2110,6 +2147,10 @@ static struct file *do_last(struct namei +@@ -2110,6 +2170,16 @@ static struct file *do_last(struct nameidata *nd,= struct path *path, error =3D complete_walk(nd); if (error) return ERR_PTR(error); ++#ifdef CONFIG_GRKERNSEC ++ if (nd->flags & LOOKUP_RCU) { ++ error =3D -ECHILD; ++ goto exit; ++ } ++#endif + if (!gr_acl_handle_hidden_file(nd->path.dentry, nd->path.mnt)) { + error =3D -ENOENT; + goto exit; @@ -45238,10 +46538,16 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/f= s/namei.c audit_inode(pathname, nd->path.dentry); if (open_flag & O_CREAT) { error =3D -EISDIR; -@@ -2120,6 +2161,10 @@ static struct file *do_last(struct namei +@@ -2120,6 +2190,16 @@ static struct file *do_last(struct nameidata *nd,= struct path *path, error =3D complete_walk(nd); if (error) return ERR_PTR(error); ++#ifdef CONFIG_GRKERNSEC ++ if (nd->flags & LOOKUP_RCU) { ++ error =3D -ECHILD; ++ goto exit; ++ } ++#endif + if (!gr_acl_handle_hidden_file(dir, nd->path.mnt)) { + error =3D -ENOENT; + goto exit; @@ -45249,19 +46555,24 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/f= s/namei.c audit_inode(pathname, dir); goto ok; } -@@ -2142,6 +2187,11 @@ static struct file *do_last(struct namei +@@ -2141,6 +2221,16 @@ static struct file *do_last(struct nameidata *nd,= struct path *path, + error =3D complete_walk(nd); if (error) return ERR_PTR(-ECHILD); -=20 ++#ifdef CONFIG_GRKERNSEC ++ if (nd->flags & LOOKUP_RCU) { ++ error =3D -ECHILD; ++ goto exit; ++ } ++#endif + if (!gr_acl_handle_hidden_file(nd->path.dentry, nd->path.mnt)) { + error =3D -ENOENT; + goto exit; + } -+ +=20 error =3D -ENOTDIR; if (nd->flags & LOOKUP_DIRECTORY) { - if (!nd->inode->i_op->lookup) -@@ -2181,6 +2231,12 @@ static struct file *do_last(struct namei +@@ -2181,6 +2271,12 @@ static struct file *do_last(struct nameidata *nd,= struct path *path, /* Negative dentry, just create the file */ if (!dentry->d_inode) { int mode =3D op->mode; @@ -45274,7 +46585,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c if (!IS_POSIXACL(dir->d_inode)) mode &=3D ~current_umask(); /* -@@ -2204,6 +2260,8 @@ static struct file *do_last(struct namei +@@ -2204,6 +2300,8 @@ static struct file *do_last(struct nameidata *nd, = struct path *path, error =3D vfs_create(dir->d_inode, dentry, mode, nd); if (error) goto exit_mutex_unlock; @@ -45283,7 +46594,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c mutex_unlock(&dir->d_inode->i_mutex); dput(nd->path.dentry); nd->path.dentry =3D dentry; -@@ -2213,6 +2271,19 @@ static struct file *do_last(struct namei +@@ -2213,6 +2311,19 @@ static struct file *do_last(struct nameidata *nd,= struct path *path, /* * It already exists. */ @@ -45303,7 +46614,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c mutex_unlock(&dir->d_inode->i_mutex); audit_inode(pathname, path->dentry); =20 -@@ -2425,6 +2496,11 @@ struct dentry *kern_path_create(int dfd, +@@ -2425,6 +2536,11 @@ struct dentry *kern_path_create(int dfd, const ch= ar *pathname, struct path *path *path =3D nd.path; return dentry; eexist: @@ -45315,7 +46626,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c dput(dentry); dentry =3D ERR_PTR(-EEXIST); fail: -@@ -2447,6 +2523,20 @@ struct dentry *user_path_create(int dfd, +@@ -2447,6 +2563,20 @@ struct dentry *user_path_create(int dfd, const ch= ar __user *pathname, struct pat } EXPORT_SYMBOL(user_path_create); =20 @@ -45336,7 +46647,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c int vfs_mknod(struct inode *dir, struct dentry *dentry, int mode, dev_t= dev) { int error =3D may_create(dir, dentry); -@@ -2514,6 +2604,17 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const +@@ -2514,6 +2644,17 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const char __u= ser *, filename, int, mode, error =3D mnt_want_write(path.mnt); if (error) goto out_dput; @@ -45354,7 +46665,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c error =3D security_path_mknod(&path, dentry, mode, dev); if (error) goto out_drop_write; -@@ -2531,6 +2632,9 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const +@@ -2531,6 +2672,9 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const char __us= er *, filename, int, mode, } out_drop_write: mnt_drop_write(path.mnt); @@ -45364,7 +46675,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c out_dput: dput(dentry); mutex_unlock(&path.dentry->d_inode->i_mutex); -@@ -2580,12 +2684,21 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const +@@ -2580,12 +2724,21 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const char __= user *, pathname, int, mode) error =3D mnt_want_write(path.mnt); if (error) goto out_dput; @@ -45386,7 +46697,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c out_dput: dput(dentry); mutex_unlock(&path.dentry->d_inode->i_mutex); -@@ -2665,6 +2778,8 @@ static long do_rmdir(int dfd, const char +@@ -2665,6 +2818,8 @@ static long do_rmdir(int dfd, const char __user *p= athname) char * name; struct dentry *dentry; struct nameidata nd; @@ -45395,7 +46706,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c =20 error =3D user_path_parent(dfd, pathname, &nd, &name); if (error) -@@ -2693,6 +2808,15 @@ static long do_rmdir(int dfd, const char +@@ -2693,6 +2848,15 @@ static long do_rmdir(int dfd, const char __user *= pathname) error =3D -ENOENT; goto exit3; } @@ -45411,7 +46722,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c error =3D mnt_want_write(nd.path.mnt); if (error) goto exit3; -@@ -2700,6 +2824,8 @@ static long do_rmdir(int dfd, const char +@@ -2700,6 +2864,8 @@ static long do_rmdir(int dfd, const char __user *p= athname) if (error) goto exit4; error =3D vfs_rmdir(nd.path.dentry->d_inode, dentry); @@ -45420,7 +46731,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c exit4: mnt_drop_write(nd.path.mnt); exit3: -@@ -2762,6 +2888,8 @@ static long do_unlinkat(int dfd, const c +@@ -2762,6 +2928,8 @@ static long do_unlinkat(int dfd, const char __user= *pathname) struct dentry *dentry; struct nameidata nd; struct inode *inode =3D NULL; @@ -45429,7 +46740,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c =20 error =3D user_path_parent(dfd, pathname, &nd, &name); if (error) -@@ -2784,6 +2912,16 @@ static long do_unlinkat(int dfd, const c +@@ -2784,6 +2952,16 @@ static long do_unlinkat(int dfd, const char __use= r *pathname) if (!inode) goto slashes; ihold(inode); @@ -45446,7 +46757,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c error =3D mnt_want_write(nd.path.mnt); if (error) goto exit2; -@@ -2791,6 +2929,8 @@ static long do_unlinkat(int dfd, const c +@@ -2791,6 +2969,8 @@ static long do_unlinkat(int dfd, const char __user= *pathname) if (error) goto exit3; error =3D vfs_unlink(nd.path.dentry->d_inode, dentry); @@ -45455,7 +46766,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c exit3: mnt_drop_write(nd.path.mnt); exit2: -@@ -2866,10 +3006,18 @@ SYSCALL_DEFINE3(symlinkat, const char __ +@@ -2866,10 +3046,18 @@ SYSCALL_DEFINE3(symlinkat, const char __user *, = oldname, error =3D mnt_want_write(path.mnt); if (error) goto out_dput; @@ -45474,15 +46785,15 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/f= s/namei.c out_drop_write: mnt_drop_write(path.mnt); out_dput: -@@ -2941,6 +3089,7 @@ SYSCALL_DEFINE5(linkat, int, olddfd, con +@@ -2941,6 +3129,7 @@ SYSCALL_DEFINE5(linkat, int, olddfd, const char __= user *, oldname, { struct dentry *new_dentry; struct path old_path, new_path; -+ char *to; ++ char *to =3D NULL; int how =3D 0; int error; =20 -@@ -2964,7 +3113,7 @@ SYSCALL_DEFINE5(linkat, int, olddfd, con +@@ -2964,7 +3153,7 @@ SYSCALL_DEFINE5(linkat, int, olddfd, const char __= user *, oldname, if (error) return error; =20 @@ -45491,7 +46802,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c error =3D PTR_ERR(new_dentry); if (IS_ERR(new_dentry)) goto out; -@@ -2975,13 +3124,30 @@ SYSCALL_DEFINE5(linkat, int, olddfd, con +@@ -2975,13 +3164,30 @@ SYSCALL_DEFINE5(linkat, int, olddfd, const char = __user *, oldname, error =3D mnt_want_write(new_path.mnt); if (error) goto out_dput; @@ -45522,7 +46833,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c dput(new_dentry); mutex_unlock(&new_path.dentry->d_inode->i_mutex); path_put(&new_path); -@@ -3153,6 +3319,8 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -3153,6 +3359,8 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char = __user *, oldname, char *to; int error; =20 @@ -45531,7 +46842,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c error =3D user_path_parent(olddfd, oldname, &oldnd, &from); if (error) goto exit; -@@ -3209,6 +3377,12 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -3209,6 +3417,12 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char= __user *, oldname, if (new_dentry =3D=3D trap) goto exit5; =20 @@ -45544,7 +46855,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c error =3D mnt_want_write(oldnd.path.mnt); if (error) goto exit5; -@@ -3218,6 +3392,9 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -3218,6 +3432,9 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char = __user *, oldname, goto exit6; error =3D vfs_rename(old_dir->d_inode, old_dentry, new_dir->d_inode, new_dentry); @@ -45554,7 +46865,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c exit6: mnt_drop_write(oldnd.path.mnt); exit5: -@@ -3243,6 +3420,8 @@ SYSCALL_DEFINE2(rename, const char __use +@@ -3243,6 +3460,8 @@ SYSCALL_DEFINE2(rename, const char __user *, oldna= me, const char __user *, newna =20 int vfs_readlink(struct dentry *dentry, char __user *buffer, int buflen= , const char *link) { @@ -45563,7 +46874,7 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/fs/= namei.c int len; =20 len =3D PTR_ERR(link); -@@ -3252,7 +3431,14 @@ int vfs_readlink(struct dentry *dentry,=20 +@@ -3252,7 +3471,14 @@ int vfs_readlink(struct dentry *dentry, char __us= er *buffer, int buflen, const c len =3D strlen(link); if (len > (unsigned) buflen) len =3D buflen; @@ -45579,10 +46890,11 @@ diff -urNp linux-3.1.4/fs/namei.c linux-3.1.4/f= s/namei.c len =3D -EFAULT; out: return len; -diff -urNp linux-3.1.4/fs/namespace.c linux-3.1.4/fs/namespace.c ---- linux-3.1.4/fs/namespace.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/namespace.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1329,6 +1329,9 @@ static int do_umount(struct vfsmount *mn +diff --git a/fs/namespace.c b/fs/namespace.c +index e5e1c7d..019609e 100644 +--- a/fs/namespace.c ++++ b/fs/namespace.c +@@ -1329,6 +1329,9 @@ static int do_umount(struct vfsmount *mnt, int fla= gs) if (!(sb->s_flags & MS_RDONLY)) retval =3D do_remount_sb(sb, MS_RDONLY, NULL, 0); up_write(&sb->s_umount); @@ -45592,7 +46904,7 @@ diff -urNp linux-3.1.4/fs/namespace.c linux-3.1.4= /fs/namespace.c return retval; } =20 -@@ -1348,6 +1351,9 @@ static int do_umount(struct vfsmount *mn +@@ -1348,6 +1351,9 @@ static int do_umount(struct vfsmount *mnt, int fla= gs) br_write_unlock(vfsmount_lock); up_write(&namespace_sem); release_mounts(&umount_list); @@ -45602,7 +46914,7 @@ diff -urNp linux-3.1.4/fs/namespace.c linux-3.1.4= /fs/namespace.c return retval; } =20 -@@ -2339,6 +2345,16 @@ long do_mount(char *dev_name, char *dir_ +@@ -2339,6 +2345,16 @@ long do_mount(char *dev_name, char *dir_name, cha= r *type_page, MS_NOATIME | MS_NODIRATIME | MS_RELATIME| MS_KERNMOUNT | MS_STRICTATIME); =20 @@ -45619,7 +46931,7 @@ diff -urNp linux-3.1.4/fs/namespace.c linux-3.1.4= /fs/namespace.c if (flags & MS_REMOUNT) retval =3D do_remount(&path, flags & ~MS_REMOUNT, mnt_flags, data_page); -@@ -2353,6 +2369,9 @@ long do_mount(char *dev_name, char *dir_ +@@ -2353,6 +2369,9 @@ long do_mount(char *dev_name, char *dir_name, char= *type_page, dev_name, data_page); dput_out: path_put(&path); @@ -45629,7 +46941,7 @@ diff -urNp linux-3.1.4/fs/namespace.c linux-3.1.4= /fs/namespace.c return retval; } =20 -@@ -2576,6 +2595,11 @@ SYSCALL_DEFINE2(pivot_root, const char _ +@@ -2576,6 +2595,11 @@ SYSCALL_DEFINE2(pivot_root, const char __user *, = new_root, if (error) goto out2; =20 @@ -45641,10 +46953,11 @@ diff -urNp linux-3.1.4/fs/namespace.c linux-3.1= .4/fs/namespace.c get_fs_root(current->fs, &root); error =3D lock_mount(&old); if (error) -diff -urNp linux-3.1.4/fs/ncpfs/dir.c linux-3.1.4/fs/ncpfs/dir.c ---- linux-3.1.4/fs/ncpfs/dir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ncpfs/dir.c 2011-11-16 18:40:29.000000000 -0500 -@@ -299,6 +299,8 @@ ncp_lookup_validate(struct dentry *dentr +diff --git a/fs/ncpfs/dir.c b/fs/ncpfs/dir.c +index 9c51f62..503b252 100644 +--- a/fs/ncpfs/dir.c ++++ b/fs/ncpfs/dir.c +@@ -299,6 +299,8 @@ ncp_lookup_validate(struct dentry *dentry, struct na= meidata *nd) int res, val =3D 0, len; __u8 __name[NCP_MAXPATHLEN + 1]; =20 @@ -45653,7 +46966,7 @@ diff -urNp linux-3.1.4/fs/ncpfs/dir.c linux-3.1.4= /fs/ncpfs/dir.c if (dentry =3D=3D dentry->d_sb->s_root) return 1; =20 -@@ -844,6 +846,8 @@ static struct dentry *ncp_lookup(struct=20 +@@ -844,6 +846,8 @@ static struct dentry *ncp_lookup(struct inode *dir, = struct dentry *dentry, struc int error, res, len; __u8 __name[NCP_MAXPATHLEN + 1]; =20 @@ -45662,7 +46975,7 @@ diff -urNp linux-3.1.4/fs/ncpfs/dir.c linux-3.1.4= /fs/ncpfs/dir.c error =3D -EIO; if (!ncp_conn_valid(server)) goto finished; -@@ -931,6 +935,8 @@ int ncp_create_new(struct inode *dir, st +@@ -931,6 +935,8 @@ int ncp_create_new(struct inode *dir, struct dentry = *dentry, int mode, PPRINTK("ncp_create_new: creating %s/%s, mode=3D%x\n", dentry->d_parent->d_name.name, dentry->d_name.name, mode); =20 @@ -45671,7 +46984,7 @@ diff -urNp linux-3.1.4/fs/ncpfs/dir.c linux-3.1.4= /fs/ncpfs/dir.c ncp_age_dentry(server, dentry); len =3D sizeof(__name); error =3D ncp_io2vol(server, __name, &len, dentry->d_name.name, -@@ -992,6 +998,8 @@ static int ncp_mkdir(struct inode *dir,=20 +@@ -992,6 +998,8 @@ static int ncp_mkdir(struct inode *dir, struct dentr= y *dentry, int mode) int error, len; __u8 __name[NCP_MAXPATHLEN + 1]; =20 @@ -45680,7 +46993,7 @@ diff -urNp linux-3.1.4/fs/ncpfs/dir.c linux-3.1.4= /fs/ncpfs/dir.c DPRINTK("ncp_mkdir: making %s/%s\n", dentry->d_parent->d_name.name, dentry->d_name.name); =20 -@@ -1140,6 +1148,8 @@ static int ncp_rename(struct inode *old_ +@@ -1140,6 +1148,8 @@ static int ncp_rename(struct inode *old_dir, struc= t dentry *old_dentry, int old_len, new_len; __u8 __old_name[NCP_MAXPATHLEN + 1], __new_name[NCP_MAXPATHLEN + 1]; =20 @@ -45689,10 +47002,11 @@ diff -urNp linux-3.1.4/fs/ncpfs/dir.c linux-3.1= .4/fs/ncpfs/dir.c DPRINTK("ncp_rename: %s/%s to %s/%s\n", old_dentry->d_parent->d_name.name, old_dentry->d_name.name, new_dentry->d_parent->d_name.name, new_dentry->d_name.name); -diff -urNp linux-3.1.4/fs/ncpfs/inode.c linux-3.1.4/fs/ncpfs/inode.c ---- linux-3.1.4/fs/ncpfs/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ncpfs/inode.c 2011-11-16 18:40:29.000000000 -0500 -@@ -461,6 +461,8 @@ static int ncp_fill_super(struct super_b +diff --git a/fs/ncpfs/inode.c b/fs/ncpfs/inode.c +index 202f370..9d4565e 100644 +--- a/fs/ncpfs/inode.c ++++ b/fs/ncpfs/inode.c +@@ -461,6 +461,8 @@ static int ncp_fill_super(struct super_block *sb, vo= id *raw_data, int silent) #endif struct ncp_entry_info finfo; =20 @@ -45701,10 +47015,11 @@ diff -urNp linux-3.1.4/fs/ncpfs/inode.c linux-3= .1.4/fs/ncpfs/inode.c memset(&data, 0, sizeof(data)); server =3D kzalloc(sizeof(struct ncp_server), GFP_KERNEL); if (!server) -diff -urNp linux-3.1.4/fs/nfs/blocklayout/blocklayout.c linux-3.1.4/fs/n= fs/blocklayout/blocklayout.c ---- linux-3.1.4/fs/nfs/blocklayout/blocklayout.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/fs/nfs/blocklayout/blocklayout.c 2011-11-16 18:39:08.000= 000000 -0500 -@@ -90,7 +90,7 @@ static int is_writable(struct pnfs_block +diff --git a/fs/nfs/blocklayout/blocklayout.c b/fs/nfs/blocklayout/block= layout.c +index 281ae95..dd895b9 100644 +--- a/fs/nfs/blocklayout/blocklayout.c ++++ b/fs/nfs/blocklayout/blocklayout.c +@@ -90,7 +90,7 @@ static int is_writable(struct pnfs_block_extent *be, s= ector_t isect) */ struct parallel_io { struct kref refcnt; @@ -45713,10 +47028,11 @@ diff -urNp linux-3.1.4/fs/nfs/blocklayout/block= layout.c linux-3.1.4/fs/nfs/block void (*pnfs_callback) (void *data); void *data; }; -diff -urNp linux-3.1.4/fs/nfs/inode.c linux-3.1.4/fs/nfs/inode.c ---- linux-3.1.4/fs/nfs/inode.c 2011-11-26 19:57:29.000000000 -0500 -+++ linux-3.1.4/fs/nfs/inode.c 2011-11-26 20:00:43.000000000 -0500 -@@ -150,7 +150,7 @@ static void nfs_zap_caches_locked(struct +diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c +index 679d2f5..ef1ffec 100644 +--- a/fs/nfs/inode.c ++++ b/fs/nfs/inode.c +@@ -150,7 +150,7 @@ static void nfs_zap_caches_locked(struct inode *inod= e) nfsi->attrtimeo =3D NFS_MINATTRTIMEO(inode); nfsi->attrtimeo_timestamp =3D jiffies; =20 @@ -45725,7 +47041,7 @@ diff -urNp linux-3.1.4/fs/nfs/inode.c linux-3.1.4= /fs/nfs/inode.c if (S_ISREG(mode) || S_ISDIR(mode) || S_ISLNK(mode)) nfsi->cache_validity |=3D NFS_INO_INVALID_ATTR|NFS_INO_INVALID_DATA|N= FS_INO_INVALID_ACCESS|NFS_INO_INVALID_ACL|NFS_INO_REVAL_PAGECACHE; else -@@ -1002,16 +1002,16 @@ static int nfs_size_need_update(const st +@@ -1002,16 +1002,16 @@ static int nfs_size_need_update(const struct ino= de *inode, const struct nfs_fatt return nfs_size_to_loff_t(fattr->size) > i_size_read(inode); } =20 @@ -45745,10 +47061,11 @@ diff -urNp linux-3.1.4/fs/nfs/inode.c linux-3.1= .4/fs/nfs/inode.c } =20 void nfs_fattr_init(struct nfs_fattr *fattr) -diff -urNp linux-3.1.4/fs/nfsd/nfs4state.c linux-3.1.4/fs/nfsd/nfs4state= .c ---- linux-3.1.4/fs/nfsd/nfs4state.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/nfsd/nfs4state.c 2011-11-16 18:40:29.000000000 -0500 -@@ -3999,6 +3999,8 @@ nfsd4_lock(struct svc_rqst *rqstp, struc +diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c +index 6f8bcc7..8f823c5 100644 +--- a/fs/nfsd/nfs4state.c ++++ b/fs/nfsd/nfs4state.c +@@ -3999,6 +3999,8 @@ nfsd4_lock(struct svc_rqst *rqstp, struct nfsd4_co= mpound_state *cstate, unsigned int strhashval; int err; =20 @@ -45757,10 +47074,11 @@ diff -urNp linux-3.1.4/fs/nfsd/nfs4state.c linu= x-3.1.4/fs/nfsd/nfs4state.c dprintk("NFSD: nfsd4_lock: start=3D%Ld length=3D%Ld\n", (long long) lock->lk_offset, (long long) lock->lk_length); -diff -urNp linux-3.1.4/fs/nfsd/nfs4xdr.c linux-3.1.4/fs/nfsd/nfs4xdr.c ---- linux-3.1.4/fs/nfsd/nfs4xdr.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/nfsd/nfs4xdr.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1875,6 +1875,8 @@ nfsd4_encode_fattr(struct svc_fh *fhp, s +diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c +index f810996..cec8977 100644 +--- a/fs/nfsd/nfs4xdr.c ++++ b/fs/nfsd/nfs4xdr.c +@@ -1875,6 +1875,8 @@ nfsd4_encode_fattr(struct svc_fh *fhp, struct svc_= export *exp, .dentry =3D dentry, }; =20 @@ -45769,10 +47087,11 @@ diff -urNp linux-3.1.4/fs/nfsd/nfs4xdr.c linux-= 3.1.4/fs/nfsd/nfs4xdr.c BUG_ON(bmval1 & NFSD_WRITEONLY_ATTRS_WORD1); BUG_ON(bmval0 & ~nfsd_suppattrs0(minorversion)); BUG_ON(bmval1 & ~nfsd_suppattrs1(minorversion)); -diff -urNp linux-3.1.4/fs/nfsd/vfs.c linux-3.1.4/fs/nfsd/vfs.c ---- linux-3.1.4/fs/nfsd/vfs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/nfsd/vfs.c 2011-11-16 18:39:08.000000000 -0500 -@@ -896,7 +896,7 @@ nfsd_vfs_read(struct svc_rqst *rqstp, st +diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c +index acf88ae..4fd6245 100644 +--- a/fs/nfsd/vfs.c ++++ b/fs/nfsd/vfs.c +@@ -896,7 +896,7 @@ nfsd_vfs_read(struct svc_rqst *rqstp, struct svc_fh = *fhp, struct file *file, } else { oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -45781,7 +47100,7 @@ diff -urNp linux-3.1.4/fs/nfsd/vfs.c linux-3.1.4/= fs/nfsd/vfs.c set_fs(oldfs); } =20 -@@ -1000,7 +1000,7 @@ nfsd_vfs_write(struct svc_rqst *rqstp, s +@@ -1000,7 +1000,7 @@ nfsd_vfs_write(struct svc_rqst *rqstp, struct svc_= fh *fhp, struct file *file, =20 /* Write the data. */ oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -45790,7 +47109,7 @@ diff -urNp linux-3.1.4/fs/nfsd/vfs.c linux-3.1.4/= fs/nfsd/vfs.c set_fs(oldfs); if (host_err < 0) goto out_nfserr; -@@ -1535,7 +1535,7 @@ nfsd_readlink(struct svc_rqst *rqstp, st +@@ -1535,7 +1535,7 @@ nfsd_readlink(struct svc_rqst *rqstp, struct svc_f= h *fhp, char *buf, int *lenp) */ =20 oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -45799,10 +47118,11 @@ diff -urNp linux-3.1.4/fs/nfsd/vfs.c linux-3.1.= 4/fs/nfsd/vfs.c set_fs(oldfs); =20 if (host_err < 0) -diff -urNp linux-3.1.4/fs/notify/fanotify/fanotify_user.c linux-3.1.4/fs= /notify/fanotify/fanotify_user.c ---- linux-3.1.4/fs/notify/fanotify/fanotify_user.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/fs/notify/fanotify/fanotify_user.c 2011-11-16 18:39:08.0= 00000000 -0500 -@@ -276,7 +276,8 @@ static ssize_t copy_event_to_user(struct +diff --git a/fs/notify/fanotify/fanotify_user.c b/fs/notify/fanotify/fan= otify_user.c +index 9fde1c0..14e8827 100644 +--- a/fs/notify/fanotify/fanotify_user.c ++++ b/fs/notify/fanotify/fanotify_user.c +@@ -276,7 +276,8 @@ static ssize_t copy_event_to_user(struct fsnotify_gr= oup *group, goto out_close_fd; =20 ret =3D -EFAULT; @@ -45812,10 +47132,11 @@ diff -urNp linux-3.1.4/fs/notify/fanotify/fanot= ify_user.c linux-3.1.4/fs/notify/ fanotify_event_metadata.event_len)) goto out_kill_access_response; =20 -diff -urNp linux-3.1.4/fs/notify/notification.c linux-3.1.4/fs/notify/no= tification.c ---- linux-3.1.4/fs/notify/notification.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/fs/notify/notification.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -57,7 +57,7 @@ static struct kmem_cache *fsnotify_event +diff --git a/fs/notify/notification.c b/fs/notify/notification.c +index ee18815..7aa5d01 100644 +--- a/fs/notify/notification.c ++++ b/fs/notify/notification.c +@@ -57,7 +57,7 @@ static struct kmem_cache *fsnotify_event_holder_cachep= ; * get set to 0 so it will never get 'freed' */ static struct fsnotify_event *q_overflow_event; @@ -45824,7 +47145,7 @@ diff -urNp linux-3.1.4/fs/notify/notification.c l= inux-3.1.4/fs/notify/notificati =20 /** * fsnotify_get_cookie - return a unique cookie for use in synchronizin= g events. -@@ -65,7 +65,7 @@ static atomic_t fsnotify_sync_cookie =3D A +@@ -65,7 +65,7 @@ static atomic_t fsnotify_sync_cookie =3D ATOMIC_INIT(0= ); */ u32 fsnotify_get_cookie(void) { @@ -45833,9 +47154,10 @@ diff -urNp linux-3.1.4/fs/notify/notification.c = linux-3.1.4/fs/notify/notificati } EXPORT_SYMBOL_GPL(fsnotify_get_cookie); =20 -diff -urNp linux-3.1.4/fs/ntfs/dir.c linux-3.1.4/fs/ntfs/dir.c ---- linux-3.1.4/fs/ntfs/dir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ntfs/dir.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/ntfs/dir.c b/fs/ntfs/dir.c +index 99e3610..02c1068 100644 +--- a/fs/ntfs/dir.c ++++ b/fs/ntfs/dir.c @@ -1329,7 +1329,7 @@ find_next_index_buffer: ia =3D (INDEX_ALLOCATION*)(kaddr + (ia_pos & ~PAGE_CACHE_MASK & ~(s64)(ndir->itype.index.block_size - 1))); @@ -45845,10 +47167,11 @@ diff -urNp linux-3.1.4/fs/ntfs/dir.c linux-3.1.= 4/fs/ntfs/dir.c ntfs_error(sb, "Out of bounds check failed. Corrupt directory " "inode 0x%lx or driver bug.", vdir->i_ino); goto err_out; -diff -urNp linux-3.1.4/fs/ntfs/file.c linux-3.1.4/fs/ntfs/file.c ---- linux-3.1.4/fs/ntfs/file.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ntfs/file.c 2011-11-16 18:39:08.000000000 -0500 -@@ -2229,6 +2229,6 @@ const struct inode_operations ntfs_file_ +diff --git a/fs/ntfs/file.c b/fs/ntfs/file.c +index c587e2d..3641eaa 100644 +--- a/fs/ntfs/file.c ++++ b/fs/ntfs/file.c +@@ -2229,6 +2229,6 @@ const struct inode_operations ntfs_file_inode_ops = =3D { #endif /* NTFS_RW */ }; =20 @@ -45857,10 +47180,11 @@ diff -urNp linux-3.1.4/fs/ntfs/file.c linux-3.1= .4/fs/ntfs/file.c =20 -const struct inode_operations ntfs_empty_inode_ops =3D {}; +const struct inode_operations ntfs_empty_inode_ops __read_only; -diff -urNp linux-3.1.4/fs/ocfs2/localalloc.c linux-3.1.4/fs/ocfs2/locala= lloc.c ---- linux-3.1.4/fs/ocfs2/localalloc.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/ocfs2/localalloc.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -1283,7 +1283,7 @@ static int ocfs2_local_alloc_slide_windo +diff --git a/fs/ocfs2/localalloc.c b/fs/ocfs2/localalloc.c +index 210c352..a174f83 100644 +--- a/fs/ocfs2/localalloc.c ++++ b/fs/ocfs2/localalloc.c +@@ -1283,7 +1283,7 @@ static int ocfs2_local_alloc_slide_window(struct o= cfs2_super *osb, goto bail; } =20 @@ -45869,10 +47193,11 @@ diff -urNp linux-3.1.4/fs/ocfs2/localalloc.c li= nux-3.1.4/fs/ocfs2/localalloc.c =20 bail: if (handle) -diff -urNp linux-3.1.4/fs/ocfs2/namei.c linux-3.1.4/fs/ocfs2/namei.c ---- linux-3.1.4/fs/ocfs2/namei.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ocfs2/namei.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1063,6 +1063,8 @@ static int ocfs2_rename(struct inode *ol +diff --git a/fs/ocfs2/namei.c b/fs/ocfs2/namei.c +index 53aa41e..d7df9f1 100644 +--- a/fs/ocfs2/namei.c ++++ b/fs/ocfs2/namei.c +@@ -1063,6 +1063,8 @@ static int ocfs2_rename(struct inode *old_dir, struct ocfs2_dir_lookup_result orphan_insert =3D { NULL, }; struct ocfs2_dir_lookup_result target_insert =3D { NULL, }; =20 @@ -45881,9 +47206,10 @@ diff -urNp linux-3.1.4/fs/ocfs2/namei.c linux-3.= 1.4/fs/ocfs2/namei.c /* At some point it might be nice to break this function up a * bit. */ =20 -diff -urNp linux-3.1.4/fs/ocfs2/ocfs2.h linux-3.1.4/fs/ocfs2/ocfs2.h ---- linux-3.1.4/fs/ocfs2/ocfs2.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ocfs2/ocfs2.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/ocfs2/ocfs2.h b/fs/ocfs2/ocfs2.h +index 4092858..51c70ff 100644 +--- a/fs/ocfs2/ocfs2.h ++++ b/fs/ocfs2/ocfs2.h @@ -235,11 +235,11 @@ enum ocfs2_vol_state =20 struct ocfs2_alloc_stats @@ -45901,10 +47227,11 @@ diff -urNp linux-3.1.4/fs/ocfs2/ocfs2.h linux-3= .1.4/fs/ocfs2/ocfs2.h }; =20 enum ocfs2_local_alloc_state -diff -urNp linux-3.1.4/fs/ocfs2/suballoc.c linux-3.1.4/fs/ocfs2/suballoc= .c ---- linux-3.1.4/fs/ocfs2/suballoc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ocfs2/suballoc.c 2011-11-16 18:39:08.000000000 -0500 -@@ -872,7 +872,7 @@ static int ocfs2_reserve_suballoc_bits(s +diff --git a/fs/ocfs2/suballoc.c b/fs/ocfs2/suballoc.c +index ba5d97e..c77db25 100644 +--- a/fs/ocfs2/suballoc.c ++++ b/fs/ocfs2/suballoc.c +@@ -872,7 +872,7 @@ static int ocfs2_reserve_suballoc_bits(struct ocfs2_= super *osb, mlog_errno(status); goto bail; } @@ -45913,7 +47240,7 @@ diff -urNp linux-3.1.4/fs/ocfs2/suballoc.c linux-= 3.1.4/fs/ocfs2/suballoc.c =20 /* You should never ask for this much metadata */ BUG_ON(bits_wanted > -@@ -2008,7 +2008,7 @@ int ocfs2_claim_metadata(handle_t *handl +@@ -2008,7 +2008,7 @@ int ocfs2_claim_metadata(handle_t *handle, mlog_errno(status); goto bail; } @@ -45922,7 +47249,7 @@ diff -urNp linux-3.1.4/fs/ocfs2/suballoc.c linux-= 3.1.4/fs/ocfs2/suballoc.c =20 *suballoc_loc =3D res.sr_bg_blkno; *suballoc_bit_start =3D res.sr_bit_offset; -@@ -2172,7 +2172,7 @@ int ocfs2_claim_new_inode_at_loc(handle_ +@@ -2172,7 +2172,7 @@ int ocfs2_claim_new_inode_at_loc(handle_t *handle, trace_ocfs2_claim_new_inode_at_loc((unsigned long long)di_blkno, res->sr_bits); =20 @@ -45931,7 +47258,7 @@ diff -urNp linux-3.1.4/fs/ocfs2/suballoc.c linux-= 3.1.4/fs/ocfs2/suballoc.c =20 BUG_ON(res->sr_bits !=3D 1); =20 -@@ -2214,7 +2214,7 @@ int ocfs2_claim_new_inode(handle_t *hand +@@ -2214,7 +2214,7 @@ int ocfs2_claim_new_inode(handle_t *handle, mlog_errno(status); goto bail; } @@ -45940,7 +47267,7 @@ diff -urNp linux-3.1.4/fs/ocfs2/suballoc.c linux-= 3.1.4/fs/ocfs2/suballoc.c =20 BUG_ON(res.sr_bits !=3D 1); =20 -@@ -2318,7 +2318,7 @@ int __ocfs2_claim_clusters(handle_t *han +@@ -2318,7 +2318,7 @@ int __ocfs2_claim_clusters(handle_t *handle, cluster_start, num_clusters); if (!status) @@ -45949,7 +47276,7 @@ diff -urNp linux-3.1.4/fs/ocfs2/suballoc.c linux-= 3.1.4/fs/ocfs2/suballoc.c } else { if (min_clusters > (osb->bitmap_cpg - 1)) { /* The only paths asking for contiguousness -@@ -2344,7 +2344,7 @@ int __ocfs2_claim_clusters(handle_t *han +@@ -2344,7 +2344,7 @@ int __ocfs2_claim_clusters(handle_t *handle, ocfs2_desc_bitmap_to_cluster_off(ac->ac_inode, res.sr_bg_blkno, res.sr_bit_offset); @@ -45958,10 +47285,11 @@ diff -urNp linux-3.1.4/fs/ocfs2/suballoc.c linu= x-3.1.4/fs/ocfs2/suballoc.c *num_clusters =3D res.sr_bits; } } -diff -urNp linux-3.1.4/fs/ocfs2/super.c linux-3.1.4/fs/ocfs2/super.c ---- linux-3.1.4/fs/ocfs2/super.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ocfs2/super.c 2011-11-16 18:39:08.000000000 -0500 -@@ -300,11 +300,11 @@ static int ocfs2_osb_dump(struct ocfs2_s +diff --git a/fs/ocfs2/super.c b/fs/ocfs2/super.c +index 56f6102..1433c29 100644 +--- a/fs/ocfs2/super.c ++++ b/fs/ocfs2/super.c +@@ -300,11 +300,11 @@ static int ocfs2_osb_dump(struct ocfs2_super *osb,= char *buf, int len) "%10s =3D> GlobalAllocs: %d LocalAllocs: %d " "SubAllocs: %d LAWinMoves: %d SAExtends: %d\n", "Stats", @@ -45978,7 +47306,7 @@ diff -urNp linux-3.1.4/fs/ocfs2/super.c linux-3.1= .4/fs/ocfs2/super.c =20 out +=3D snprintf(buf + out, len - out, "%10s =3D> State: %u Descriptor: %llu Size: %u bits " -@@ -2112,11 +2112,11 @@ static int ocfs2_initialize_super(struct +@@ -2112,11 +2112,11 @@ static int ocfs2_initialize_super(struct super_b= lock *sb, spin_lock_init(&osb->osb_xattr_lock); ocfs2_init_steal_slots(osb); =20 @@ -45995,9 +47323,10 @@ diff -urNp linux-3.1.4/fs/ocfs2/super.c linux-3.= 1.4/fs/ocfs2/super.c =20 /* Copy the blockcheck stats from the superblock probe */ osb->osb_ecc_stats =3D *stats; -diff -urNp linux-3.1.4/fs/ocfs2/symlink.c linux-3.1.4/fs/ocfs2/symlink.c ---- linux-3.1.4/fs/ocfs2/symlink.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/ocfs2/symlink.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/ocfs2/symlink.c b/fs/ocfs2/symlink.c +index 5d22872..523db20 100644 +--- a/fs/ocfs2/symlink.c ++++ b/fs/ocfs2/symlink.c @@ -142,7 +142,7 @@ bail: =20 static void ocfs2_fast_put_link(struct dentry *dentry, struct nameidata= *nd, void *cookie) @@ -46007,10 +47336,11 @@ diff -urNp linux-3.1.4/fs/ocfs2/symlink.c linux= -3.1.4/fs/ocfs2/symlink.c if (!IS_ERR(link)) kfree(link); } -diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs/open.c ---- linux-3.1.4/fs/open.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/open.c 2011-11-17 19:07:55.000000000 -0500 -@@ -112,6 +112,10 @@ static long do_sys_truncate(const char _ +diff --git a/fs/open.c b/fs/open.c +index f711921..28d5958 100644 +--- a/fs/open.c ++++ b/fs/open.c +@@ -112,6 +112,10 @@ static long do_sys_truncate(const char __user *path= name, loff_t length) error =3D locks_verify_truncate(inode, NULL, length); if (!error) error =3D security_path_truncate(&path); @@ -46021,7 +47351,7 @@ diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs/o= pen.c if (!error) error =3D do_truncate(path.dentry, length, 0, NULL); =20 -@@ -358,6 +362,9 @@ SYSCALL_DEFINE3(faccessat, int, dfd, con +@@ -358,6 +362,9 @@ SYSCALL_DEFINE3(faccessat, int, dfd, const char __us= er *, filename, int, mode) if (__mnt_is_readonly(path.mnt)) res =3D -EROFS; =20 @@ -46031,7 +47361,7 @@ diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs/o= pen.c out_path_release: path_put(&path); out: -@@ -384,6 +391,8 @@ SYSCALL_DEFINE1(chdir, const char __user +@@ -384,6 +391,8 @@ SYSCALL_DEFINE1(chdir, const char __user *, filename= ) if (error) goto dput_and_out; =20 @@ -46040,7 +47370,7 @@ diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs/o= pen.c set_fs_pwd(current->fs, &path); =20 dput_and_out: -@@ -410,6 +419,13 @@ SYSCALL_DEFINE1(fchdir, unsigned int, fd +@@ -410,6 +419,13 @@ SYSCALL_DEFINE1(fchdir, unsigned int, fd) goto out_putf; =20 error =3D inode_permission(inode, MAY_EXEC | MAY_CHDIR); @@ -46054,7 +47384,7 @@ diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs/o= pen.c if (!error) set_fs_pwd(current->fs, &file->f_path); out_putf: -@@ -438,7 +454,13 @@ SYSCALL_DEFINE1(chroot, const char __use +@@ -438,7 +454,13 @@ SYSCALL_DEFINE1(chroot, const char __user *, filena= me) if (error) goto dput_and_out; =20 @@ -46068,7 +47398,7 @@ diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs/o= pen.c error =3D 0; dput_and_out: path_put(&path); -@@ -456,6 +478,16 @@ static int chmod_common(struct path *pat +@@ -456,6 +478,16 @@ static int chmod_common(struct path *path, umode_t = mode) if (error) return error; mutex_lock(&inode->i_mutex); @@ -46085,7 +47415,7 @@ diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs/o= pen.c error =3D security_path_chmod(path->dentry, path->mnt, mode); if (error) goto out_unlock; -@@ -506,6 +538,9 @@ static int chown_common(struct path *pat +@@ -506,6 +538,9 @@ static int chown_common(struct path *path, uid_t use= r, gid_t group) int error; struct iattr newattrs; =20 @@ -46095,10 +47425,11 @@ diff -urNp linux-3.1.4/fs/open.c linux-3.1.4/fs= /open.c newattrs.ia_valid =3D ATTR_CTIME; if (user !=3D (uid_t) -1) { newattrs.ia_valid |=3D ATTR_UID; -diff -urNp linux-3.1.4/fs/partitions/ldm.c linux-3.1.4/fs/partitions/ldm= .c ---- linux-3.1.4/fs/partitions/ldm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/partitions/ldm.c 2011-11-17 19:08:15.000000000 -0500 -@@ -1322,7 +1322,7 @@ static bool ldm_frag_add (const u8 *data +diff --git a/fs/partitions/ldm.c b/fs/partitions/ldm.c +index af9fdf0..75b15c3 100644 +--- a/fs/partitions/ldm.c ++++ b/fs/partitions/ldm.c +@@ -1322,7 +1322,7 @@ static bool ldm_frag_add (const u8 *data, int size= , struct list_head *frags) goto found; } =20 @@ -46107,9 +47438,10 @@ diff -urNp linux-3.1.4/fs/partitions/ldm.c linux= -3.1.4/fs/partitions/ldm.c if (!f) { ldm_crit ("Out of memory."); return false; -diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/pipe.c ---- linux-3.1.4/fs/pipe.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/pipe.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/pipe.c b/fs/pipe.c +index 0e0be1d..f62a72d 100644 +--- a/fs/pipe.c ++++ b/fs/pipe.c @@ -420,9 +420,9 @@ redo: } if (bufs) /* More to do? */ @@ -46122,7 +47454,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c /* syscall merging: Usually we must not sleep * if O_NONBLOCK is set, or if we got some data. * But if a writer sleeps in kernel space, then -@@ -481,7 +481,7 @@ pipe_write(struct kiocb *iocb, const str +@@ -481,7 +481,7 @@ pipe_write(struct kiocb *iocb, const struct iovec *_= iov, mutex_lock(&inode->i_mutex); pipe =3D inode->i_pipe; =20 @@ -46152,7 +47484,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c } out: mutex_unlock(&inode->i_mutex); -@@ -685,7 +685,7 @@ pipe_poll(struct file *filp, poll_table=20 +@@ -685,7 +685,7 @@ pipe_poll(struct file *filp, poll_table *wait) mask =3D 0; if (filp->f_mode & FMODE_READ) { mask =3D (nrbufs > 0) ? POLLIN | POLLRDNORM : 0; @@ -46161,7 +47493,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c mask |=3D POLLHUP; } =20 -@@ -695,7 +695,7 @@ pipe_poll(struct file *filp, poll_table=20 +@@ -695,7 +695,7 @@ pipe_poll(struct file *filp, poll_table *wait) * Most Unices do not set POLLERR for FIFOs but on Linux they * behave exactly like pipes for poll(). */ @@ -46170,7 +47502,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c mask |=3D POLLERR; } =20 -@@ -709,10 +709,10 @@ pipe_release(struct inode *inode, int de +@@ -709,10 +709,10 @@ pipe_release(struct inode *inode, int decr, int de= cw) =20 mutex_lock(&inode->i_mutex); pipe =3D inode->i_pipe; @@ -46184,7 +47516,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c free_pipe_info(inode); } else { wake_up_interruptible_sync_poll(&pipe->wait, POLLIN | POLLOUT | POLLR= DNORM | POLLWRNORM | POLLERR | POLLHUP); -@@ -802,7 +802,7 @@ pipe_read_open(struct inode *inode, stru +@@ -802,7 +802,7 @@ pipe_read_open(struct inode *inode, struct file *fil= p) =20 if (inode->i_pipe) { ret =3D 0; @@ -46193,7 +47525,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c } =20 mutex_unlock(&inode->i_mutex); -@@ -819,7 +819,7 @@ pipe_write_open(struct inode *inode, str +@@ -819,7 +819,7 @@ pipe_write_open(struct inode *inode, struct file *fi= lp) =20 if (inode->i_pipe) { ret =3D 0; @@ -46202,7 +47534,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c } =20 mutex_unlock(&inode->i_mutex); -@@ -837,9 +837,9 @@ pipe_rdwr_open(struct inode *inode, stru +@@ -837,9 +837,9 @@ pipe_rdwr_open(struct inode *inode, struct file *fil= p) if (inode->i_pipe) { ret =3D 0; if (filp->f_mode & FMODE_READ) @@ -46223,7 +47555,7 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/p= ipe.c =20 /* * pipefs_dname() is called from d_path(). -@@ -961,7 +961,8 @@ static struct inode * get_pipe_inode(voi +@@ -961,7 +961,8 @@ static struct inode * get_pipe_inode(void) goto fail_iput; inode->i_pipe =3D pipe; =20 @@ -46233,9 +47565,41 @@ diff -urNp linux-3.1.4/fs/pipe.c linux-3.1.4/fs/= pipe.c inode->i_fop =3D &rdwr_pipefifo_fops; =20 /* -diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1.4/fs/proc/array.c ---- linux-3.1.4/fs/proc/array.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/array.c 2011-11-17 18:42:02.000000000 -0500 +diff --git a/fs/proc/Kconfig b/fs/proc/Kconfig +index 15af622..0e9f4467 100644 +--- a/fs/proc/Kconfig ++++ b/fs/proc/Kconfig +@@ -30,12 +30,12 @@ config PROC_FS +=20 + config PROC_KCORE + bool "/proc/kcore support" if !ARM +- depends on PROC_FS && MMU ++ depends on PROC_FS && MMU && !GRKERNSEC_PROC_ADD +=20 + config PROC_VMCORE + bool "/proc/vmcore support" +- depends on PROC_FS && CRASH_DUMP +- default y ++ depends on PROC_FS && CRASH_DUMP && !GRKERNSEC ++ default n + help + Exports the dump image of crashed kernel in ELF format. +=20 +@@ -59,8 +59,8 @@ config PROC_SYSCTL + limited in memory. +=20 + config PROC_PAGE_MONITOR +- default y +- depends on PROC_FS && MMU ++ default n ++ depends on PROC_FS && MMU && !GRKERNSEC + bool "Enable /proc page monitoring" if EXPERT + help + Various /proc files exist to monitor process memory utilization: +diff --git a/fs/proc/array.c b/fs/proc/array.c +index 3a1dafd..c7fed72 100644 +--- a/fs/proc/array.c ++++ b/fs/proc/array.c @@ -60,6 +60,7 @@ #include #include @@ -46244,7 +47608,7 @@ diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1.= 4/fs/proc/array.c #include #include #include -@@ -337,6 +338,21 @@ static void task_cpus_allowed(struct seq +@@ -337,6 +338,21 @@ static void task_cpus_allowed(struct seq_file *m, s= truct task_struct *task) seq_putc(m, '\n'); } =20 @@ -46266,7 +47630,7 @@ diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1.= 4/fs/proc/array.c int proc_pid_status(struct seq_file *m, struct pid_namespace *ns, struct pid *pid, struct task_struct *task) { -@@ -354,9 +370,24 @@ int proc_pid_status(struct seq_file *m,=20 +@@ -354,9 +370,24 @@ int proc_pid_status(struct seq_file *m, struct pid_= namespace *ns, task_cpus_allowed(m, task); cpuset_task_status_allowed(m, task); task_context_switch_counts(m, task); @@ -46291,7 +47655,7 @@ diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1.= 4/fs/proc/array.c static int do_task_stat(struct seq_file *m, struct pid_namespace *ns, struct pid *pid, struct task_struct *task, int whole) { -@@ -378,6 +409,8 @@ static int do_task_stat(struct seq_file=20 +@@ -378,6 +409,8 @@ static int do_task_stat(struct seq_file *m, struct p= id_namespace *ns, char tcomm[sizeof(task->comm)]; unsigned long flags; =20 @@ -46300,7 +47664,7 @@ diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1.= 4/fs/proc/array.c state =3D *get_task_state(task); vsize =3D eip =3D esp =3D 0; permitted =3D ptrace_may_access(task, PTRACE_MODE_READ); -@@ -449,6 +482,19 @@ static int do_task_stat(struct seq_file=20 +@@ -449,6 +482,19 @@ static int do_task_stat(struct seq_file *m, struct = pid_namespace *ns, gtime =3D task->gtime; } =20 @@ -46320,7 +47684,7 @@ diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1.= 4/fs/proc/array.c /* scale priority and nice values from timeslices to -20..20 */ /* to make it look like a "normal" Unix priority/nice value */ priority =3D task_prio(task); -@@ -489,9 +535,15 @@ static int do_task_stat(struct seq_file=20 +@@ -489,9 +535,15 @@ static int do_task_stat(struct seq_file *m, struct = pid_namespace *ns, vsize, mm ? get_mm_rss(mm) : 0, rsslim, @@ -46336,7 +47700,7 @@ diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1.= 4/fs/proc/array.c esp, eip, /* The signal information here is obsolete. -@@ -544,3 +596,18 @@ int proc_pid_statm(struct seq_file *m, s +@@ -544,3 +596,18 @@ int proc_pid_statm(struct seq_file *m, struct pid_n= amespace *ns, =20 return 0; } @@ -46355,9 +47719,10 @@ diff -urNp linux-3.1.4/fs/proc/array.c linux-3.1= .4/fs/proc/array.c + return sprintf(buffer, "%pI4\n", &curr_ip); +} +#endif -diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4/fs/proc/base.c ---- linux-3.1.4/fs/proc/base.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/base.c 2011-11-17 18:43:19.000000000 -0500 +diff --git a/fs/proc/base.c b/fs/proc/base.c +index 5eb0206..7e0dc06 100644 +--- a/fs/proc/base.c ++++ b/fs/proc/base.c @@ -107,6 +107,22 @@ struct pid_entry { union proc_op op; }; @@ -46381,7 +47746,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c #define NOD(NAME, MODE, IOP, FOP, OP) { \ .name =3D (NAME), \ .len =3D sizeof(NAME) - 1, \ -@@ -209,6 +225,9 @@ static struct mm_struct *__check_mem_per +@@ -209,6 +225,9 @@ static struct mm_struct *__check_mem_permission(stru= ct task_struct *task) if (task =3D=3D current) return mm; =20 @@ -46391,7 +47756,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c /* * If current is actively ptrace'ing, and would also be * permitted to freshly attach with ptrace now, permit it. -@@ -282,6 +301,9 @@ static int proc_pid_cmdline(struct task_ +@@ -282,6 +301,9 @@ static int proc_pid_cmdline(struct task_struct *task= , char * buffer) if (!mm->arg_end) goto out_mm; /* Shh! No looking before we're done */ =20 @@ -46430,7 +47795,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c do { nwords +=3D 2; } while (mm->saved_auxv[nwords - 2] !=3D 0); /* AT_NULL */ -@@ -328,7 +366,7 @@ static int proc_pid_auxv(struct task_str +@@ -328,7 +366,7 @@ static int proc_pid_auxv(struct task_struct *task, c= har *buffer) } =20 =20 @@ -46439,7 +47804,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c /* * Provides a wchan file via kallsyms in a proper one-value-per-file fo= rmat. * Returns the resolved symbol. If that fails, simply return the addre= ss. -@@ -367,7 +405,7 @@ static void unlock_trace(struct task_str +@@ -367,7 +405,7 @@ static void unlock_trace(struct task_struct *task) mutex_unlock(&task->signal->cred_guard_mutex); } =20 @@ -46448,7 +47813,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c =20 #define MAX_STACK_TRACE_DEPTH 64 =20 -@@ -558,7 +596,7 @@ static int proc_pid_limits(struct task_s +@@ -558,7 +596,7 @@ static int proc_pid_limits(struct task_struct *task,= char *buffer) return count; } =20 @@ -46457,7 +47822,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c static int proc_pid_syscall(struct task_struct *task, char *buffer) { long nr; -@@ -587,7 +625,7 @@ static int proc_pid_syscall(struct task_ +@@ -587,7 +625,7 @@ static int proc_pid_syscall(struct task_struct *task= , char *buffer) /**********************************************************************= **/ =20 /* permission checks */ @@ -46466,7 +47831,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c { struct task_struct *task; int allowed =3D 0; -@@ -597,7 +635,10 @@ static int proc_fd_access_allowed(struct +@@ -597,7 +635,10 @@ static int proc_fd_access_allowed(struct inode *ino= de) */ task =3D get_proc_task(inode); if (task) { @@ -46478,7 +47843,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c put_task_struct(task); } return allowed; -@@ -978,6 +1019,9 @@ static ssize_t environ_read(struct file=20 +@@ -978,6 +1019,9 @@ static ssize_t environ_read(struct file *file, char= __user *buf, if (!task) goto out_no_task; =20 @@ -46488,7 +47853,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c ret =3D -ENOMEM; page =3D (char *)__get_free_page(GFP_TEMPORARY); if (!page) -@@ -1613,7 +1657,7 @@ static void *proc_pid_follow_link(struct +@@ -1613,7 +1657,7 @@ static void *proc_pid_follow_link(struct dentry *d= entry, struct nameidata *nd) path_put(&nd->path); =20 /* Are we allowed to snoop on the tasks file descriptors? */ @@ -46497,7 +47862,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c goto out; =20 error =3D PROC_I(inode)->op.proc_get_link(inode, &nd->path); -@@ -1652,8 +1696,18 @@ static int proc_pid_readlink(struct dent +@@ -1652,8 +1696,18 @@ static int proc_pid_readlink(struct dentry * dent= ry, char __user * buffer, int b struct path path; =20 /* Are we allowed to snoop on the tasks file descriptors? */ @@ -46518,7 +47883,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c =20 error =3D PROC_I(inode)->op.proc_get_link(inode, &path); if (error) -@@ -1718,7 +1772,11 @@ struct inode *proc_pid_make_inode(struct +@@ -1718,7 +1772,11 @@ struct inode *proc_pid_make_inode(struct super_bl= ock * sb, struct task_struct *t rcu_read_lock(); cred =3D __task_cred(task); inode->i_uid =3D cred->euid; @@ -46530,7 +47895,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c rcu_read_unlock(); } security_task_to_inode(task, inode); -@@ -1736,6 +1794,9 @@ int pid_getattr(struct vfsmount *mnt, st +@@ -1736,6 +1794,9 @@ int pid_getattr(struct vfsmount *mnt, struct dentr= y *dentry, struct kstat *stat) struct inode *inode =3D dentry->d_inode; struct task_struct *task; const struct cred *cred; @@ -46540,7 +47905,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c =20 generic_fillattr(inode, stat); =20 -@@ -1743,13 +1804,41 @@ int pid_getattr(struct vfsmount *mnt, st +@@ -1743,13 +1804,41 @@ int pid_getattr(struct vfsmount *mnt, struct den= try *dentry, struct kstat *stat) stat->uid =3D 0; stat->gid =3D 0; task =3D pid_task(proc_pid(inode), PIDTYPE_PID); @@ -46583,7 +47948,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c } rcu_read_unlock(); return 0; -@@ -1786,11 +1875,20 @@ int pid_revalidate(struct dentry *dentry +@@ -1786,11 +1875,20 @@ int pid_revalidate(struct dentry *dentry, struct= nameidata *nd) =20 if (task) { if ((inode->i_mode =3D=3D (S_IFDIR|S_IRUGO|S_IXUGO)) || @@ -46604,7 +47969,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c rcu_read_unlock(); } else { inode->i_uid =3D 0; -@@ -1908,7 +2006,8 @@ static int proc_fd_info(struct inode *in +@@ -1908,7 +2006,8 @@ static int proc_fd_info(struct inode *inode, struc= t path *path, char *info) int fd =3D proc_fd(inode); =20 if (task) { @@ -46614,7 +47979,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c put_task_struct(task); } if (files) { -@@ -2176,11 +2275,21 @@ static const struct file_operations proc +@@ -2176,11 +2275,21 @@ static const struct file_operations proc_fd_oper= ations =3D { */ static int proc_fd_permission(struct inode *inode, int mask) { @@ -46638,7 +48003,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c return rv; } =20 -@@ -2290,6 +2399,9 @@ static struct dentry *proc_pident_lookup +@@ -2290,6 +2399,9 @@ static struct dentry *proc_pident_lookup(struct in= ode *dir, if (!task) goto out_no_task; =20 @@ -46648,7 +48013,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c /* * Yes, it does not scale. And it should not. Don't add * new entries into /proc// without very good reasons. -@@ -2334,6 +2446,9 @@ static int proc_pident_readdir(struct fi +@@ -2334,6 +2446,9 @@ static int proc_pident_readdir(struct file *filp, if (!task) goto out_no_task; =20 @@ -46658,7 +48023,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c ret =3D 0; i =3D filp->f_pos; switch (i) { -@@ -2604,7 +2719,7 @@ static void *proc_self_follow_link(struc +@@ -2604,7 +2719,7 @@ static void *proc_self_follow_link(struct dentry *= dentry, struct nameidata *nd) static void proc_self_put_link(struct dentry *dentry, struct nameidata = *nd, void *cookie) { @@ -46667,7 +48032,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c if (!IS_ERR(s)) __putname(s); } -@@ -2802,7 +2917,7 @@ static const struct pid_entry tgid_base_ +@@ -2802,7 +2917,7 @@ static const struct pid_entry tgid_base_stuff[] =3D= { REG("autogroup", S_IRUGO|S_IWUSR, proc_pid_sched_autogroup_operations= ), #endif REG("comm", S_IRUGO|S_IWUSR, proc_pid_set_comm_operations), @@ -46676,7 +48041,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c INF("syscall", S_IRUGO, proc_pid_syscall), #endif INF("cmdline", S_IRUGO, proc_pid_cmdline), -@@ -2827,10 +2942,10 @@ static const struct pid_entry tgid_base_ +@@ -2827,10 +2942,10 @@ static const struct pid_entry tgid_base_stuff[] = =3D { #ifdef CONFIG_SECURITY DIR("attr", S_IRUGO|S_IXUGO, proc_attr_dir_inode_operations, pro= c_attr_dir_operations), #endif @@ -46689,7 +48054,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c ONE("stack", S_IRUGO, proc_pid_stack), #endif #ifdef CONFIG_SCHEDSTATS -@@ -2864,6 +2979,9 @@ static const struct pid_entry tgid_base_ +@@ -2864,6 +2979,9 @@ static const struct pid_entry tgid_base_stuff[] =3D= { #ifdef CONFIG_HARDWALL INF("hardwall", S_IRUGO, proc_pid_hardwall), #endif @@ -46699,7 +48064,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c }; =20 static int proc_tgid_base_readdir(struct file * filp, -@@ -2989,7 +3107,14 @@ static struct dentry *proc_pid_instantia +@@ -2989,7 +3107,14 @@ static struct dentry *proc_pid_instantiate(struct= inode *dir, if (!inode) goto out; =20 @@ -46714,7 +48079,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c inode->i_op =3D &proc_tgid_base_inode_operations; inode->i_fop =3D &proc_tgid_base_operations; inode->i_flags|=3DS_IMMUTABLE; -@@ -3031,7 +3156,14 @@ struct dentry *proc_pid_lookup(struct in +@@ -3031,7 +3156,14 @@ struct dentry *proc_pid_lookup(struct inode *dir,= struct dentry * dentry, struct if (!task) goto out; =20 @@ -46729,7 +48094,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c put_task_struct(task); out: return result; -@@ -3096,6 +3228,11 @@ int proc_pid_readdir(struct file * filp, +@@ -3096,6 +3228,11 @@ int proc_pid_readdir(struct file * filp, void * d= irent, filldir_t filldir) { unsigned int nr; struct task_struct *reaper; @@ -46741,7 +48106,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c struct tgid_iter iter; struct pid_namespace *ns; =20 -@@ -3119,8 +3256,27 @@ int proc_pid_readdir(struct file * filp, +@@ -3119,8 +3256,27 @@ int proc_pid_readdir(struct file * filp, void * d= irent, filldir_t filldir) for (iter =3D next_tgid(ns, iter); iter.task; iter.tgid +=3D 1, iter =3D next_tgid(ns, iter)) { @@ -46770,7 +48135,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c put_task_struct(iter.task); goto out; } -@@ -3148,7 +3304,7 @@ static const struct pid_entry tid_base_s +@@ -3148,7 +3304,7 @@ static const struct pid_entry tid_base_stuff[] =3D= { REG("sched", S_IRUGO|S_IWUSR, proc_pid_sched_operations), #endif REG("comm", S_IRUGO|S_IWUSR, proc_pid_set_comm_operations), @@ -46779,7 +48144,7 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1.4= /fs/proc/base.c INF("syscall", S_IRUGO, proc_pid_syscall), #endif INF("cmdline", S_IRUGO, proc_pid_cmdline), -@@ -3172,10 +3328,10 @@ static const struct pid_entry tid_base_s +@@ -3172,10 +3328,10 @@ static const struct pid_entry tid_base_stuff[] =3D= { #ifdef CONFIG_SECURITY DIR("attr", S_IRUGO|S_IXUGO, proc_attr_dir_inode_operations, proc= _attr_dir_operations), #endif @@ -46792,10 +48157,11 @@ diff -urNp linux-3.1.4/fs/proc/base.c linux-3.1= .4/fs/proc/base.c ONE("stack", S_IRUGO, proc_pid_stack), #endif #ifdef CONFIG_SCHEDSTATS -diff -urNp linux-3.1.4/fs/proc/cmdline.c linux-3.1.4/fs/proc/cmdline.c ---- linux-3.1.4/fs/proc/cmdline.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/cmdline.c 2011-11-16 18:40:29.000000000 -0500 -@@ -23,7 +23,11 @@ static const struct file_operations cmdl +diff --git a/fs/proc/cmdline.c b/fs/proc/cmdline.c +index 82676e3..5f8518a 100644 +--- a/fs/proc/cmdline.c ++++ b/fs/proc/cmdline.c +@@ -23,7 +23,11 @@ static const struct file_operations cmdline_proc_fops= =3D { =20 static int __init proc_cmdline_init(void) { @@ -46807,10 +48173,11 @@ diff -urNp linux-3.1.4/fs/proc/cmdline.c linux-= 3.1.4/fs/proc/cmdline.c return 0; } module_init(proc_cmdline_init); -diff -urNp linux-3.1.4/fs/proc/devices.c linux-3.1.4/fs/proc/devices.c ---- linux-3.1.4/fs/proc/devices.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/devices.c 2011-11-16 18:40:29.000000000 -0500 -@@ -64,7 +64,11 @@ static const struct file_operations proc +diff --git a/fs/proc/devices.c b/fs/proc/devices.c +index b143471..bb105e5 100644 +--- a/fs/proc/devices.c ++++ b/fs/proc/devices.c +@@ -64,7 +64,11 @@ static const struct file_operations proc_devinfo_oper= ations =3D { =20 static int __init proc_devices_init(void) { @@ -46822,9 +48189,10 @@ diff -urNp linux-3.1.4/fs/proc/devices.c linux-3= .1.4/fs/proc/devices.c return 0; } module_init(proc_devices_init); -diff -urNp linux-3.1.4/fs/proc/inode.c linux-3.1.4/fs/proc/inode.c ---- linux-3.1.4/fs/proc/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/inode.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/proc/inode.c b/fs/proc/inode.c +index 7ed72d6..d5f061a 100644 +--- a/fs/proc/inode.c ++++ b/fs/proc/inode.c @@ -18,12 +18,18 @@ #include #include @@ -46844,7 +48212,7 @@ diff -urNp linux-3.1.4/fs/proc/inode.c linux-3.1.= 4/fs/proc/inode.c static void proc_evict_inode(struct inode *inode) { struct proc_dir_entry *de; -@@ -49,6 +55,13 @@ static void proc_evict_inode(struct inod +@@ -49,6 +55,13 @@ static void proc_evict_inode(struct inode *inode) ns_ops =3D PROC_I(inode)->ns_ops; if (ns_ops && ns_ops->put) ns_ops->put(PROC_I(inode)->ns); @@ -46858,7 +48226,7 @@ diff -urNp linux-3.1.4/fs/proc/inode.c linux-3.1.= 4/fs/proc/inode.c } =20 static struct kmem_cache * proc_inode_cachep; -@@ -440,7 +453,11 @@ struct inode *proc_get_inode(struct supe +@@ -440,7 +453,11 @@ struct inode *proc_get_inode(struct super_block *sb= , struct proc_dir_entry *de) if (de->mode) { inode->i_mode =3D de->mode; inode->i_uid =3D de->uid; @@ -46870,10 +48238,11 @@ diff -urNp linux-3.1.4/fs/proc/inode.c linux-3.= 1.4/fs/proc/inode.c } if (de->size) inode->i_size =3D de->size; -diff -urNp linux-3.1.4/fs/proc/internal.h linux-3.1.4/fs/proc/internal.h ---- linux-3.1.4/fs/proc/internal.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/internal.h 2011-11-16 18:40:29.000000000 -0500 -@@ -51,6 +51,9 @@ extern int proc_pid_status(struct seq_fi +diff --git a/fs/proc/internal.h b/fs/proc/internal.h +index 7838e5c..ff92cbc 100644 +--- a/fs/proc/internal.h ++++ b/fs/proc/internal.h +@@ -51,6 +51,9 @@ extern int proc_pid_status(struct seq_file *m, struct = pid_namespace *ns, struct pid *pid, struct task_struct *task); extern int proc_pid_statm(struct seq_file *m, struct pid_namespace *ns, struct pid *pid, struct task_struct *task); @@ -46883,40 +48252,11 @@ diff -urNp linux-3.1.4/fs/proc/internal.h linux= -3.1.4/fs/proc/internal.h extern loff_t mem_lseek(struct file *file, loff_t offset, int orig); =20 extern const struct file_operations proc_maps_operations; -diff -urNp linux-3.1.4/fs/proc/Kconfig linux-3.1.4/fs/proc/Kconfig ---- linux-3.1.4/fs/proc/Kconfig 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/Kconfig 2011-11-16 18:40:29.000000000 -0500 -@@ -30,12 +30,12 @@ config PROC_FS -=20 - config PROC_KCORE - bool "/proc/kcore support" if !ARM -- depends on PROC_FS && MMU -+ depends on PROC_FS && MMU && !GRKERNSEC_PROC_ADD -=20 - config PROC_VMCORE - bool "/proc/vmcore support" -- depends on PROC_FS && CRASH_DUMP -- default y -+ depends on PROC_FS && CRASH_DUMP && !GRKERNSEC -+ default n - help - Exports the dump image of crashed kernel in ELF format. -=20 -@@ -59,8 +59,8 @@ config PROC_SYSCTL - limited in memory. -=20 - config PROC_PAGE_MONITOR -- default y -- depends on PROC_FS && MMU -+ default n -+ depends on PROC_FS && MMU && !GRKERNSEC - bool "Enable /proc page monitoring" if EXPERT - help - Various /proc files exist to monitor process memory utilization: -diff -urNp linux-3.1.4/fs/proc/kcore.c linux-3.1.4/fs/proc/kcore.c ---- linux-3.1.4/fs/proc/kcore.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/kcore.c 2011-11-16 18:40:29.000000000 -0500 -@@ -321,6 +321,8 @@ static void elf_kcore_store_hdr(char *bu +diff --git a/fs/proc/kcore.c b/fs/proc/kcore.c +index d245cb2..7e645bd 100644 +--- a/fs/proc/kcore.c ++++ b/fs/proc/kcore.c +@@ -321,6 +321,8 @@ static void elf_kcore_store_hdr(char *bufp, int nphd= r, int dataoff) off_t offset =3D 0; struct kcore_list *m; =20 @@ -46925,7 +48265,7 @@ diff -urNp linux-3.1.4/fs/proc/kcore.c linux-3.1.= 4/fs/proc/kcore.c /* setup ELF header */ elf =3D (struct elfhdr *) bufp; bufp +=3D sizeof(struct elfhdr); -@@ -478,9 +480,10 @@ read_kcore(struct file *file, char __use +@@ -478,9 +480,10 @@ read_kcore(struct file *file, char __user *buffer, = size_t buflen, loff_t *fpos) * the addresses in the elf_phdr on our list. */ start =3D kc_offset_to_vaddr(*fpos - elf_buflen); @@ -46938,14 +48278,12 @@ diff -urNp linux-3.1.4/fs/proc/kcore.c linux-3.= 1.4/fs/proc/kcore.c while (buflen) { struct kcore_list *m; =20 -@@ -509,20 +512,23 @@ read_kcore(struct file *file, char __use +@@ -509,20 +512,23 @@ read_kcore(struct file *file, char __user *buffer,= size_t buflen, loff_t *fpos) kfree(elf_buf); } else { if (kern_addr_valid(start)) { - unsigned long n; -+ char *elf_buf; -+ mm_segment_t oldfs; -=20 +- - n =3D copy_to_user(buffer, (char *)start, tsz); - /* - * We cannot distingush between fault on source @@ -46956,6 +48294,9 @@ diff -urNp linux-3.1.4/fs/proc/kcore.c linux-3.1.= 4/fs/proc/kcore.c - if (n) {=20 - if (clear_user(buffer + tsz - n, - n)) ++ char *elf_buf; ++ mm_segment_t oldfs; ++ + elf_buf =3D kmalloc(tsz, GFP_KERNEL); + if (!elf_buf) + return -ENOMEM; @@ -46973,7 +48314,7 @@ diff -urNp linux-3.1.4/fs/proc/kcore.c linux-3.1.= 4/fs/proc/kcore.c } else { if (clear_user(buffer, tsz)) return -EFAULT; -@@ -542,6 +548,9 @@ read_kcore(struct file *file, char __use +@@ -542,6 +548,9 @@ read_kcore(struct file *file, char __user *buffer, s= ize_t buflen, loff_t *fpos) =20 static int open_kcore(struct inode *inode, struct file *filp) { @@ -46983,10 +48324,11 @@ diff -urNp linux-3.1.4/fs/proc/kcore.c linux-3.= 1.4/fs/proc/kcore.c if (!capable(CAP_SYS_RAWIO)) return -EPERM; if (kcore_need_update) -diff -urNp linux-3.1.4/fs/proc/meminfo.c linux-3.1.4/fs/proc/meminfo.c ---- linux-3.1.4/fs/proc/meminfo.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/meminfo.c 2011-11-16 18:40:29.000000000 -0500 -@@ -29,6 +29,8 @@ static int meminfo_proc_show(struct seq_ +diff --git a/fs/proc/meminfo.c b/fs/proc/meminfo.c +index 5861741..32c53bc 100644 +--- a/fs/proc/meminfo.c ++++ b/fs/proc/meminfo.c +@@ -29,6 +29,8 @@ static int meminfo_proc_show(struct seq_file *m, void = *v) unsigned long pages[NR_LRU_LISTS]; int lru; =20 @@ -46995,7 +48337,7 @@ diff -urNp linux-3.1.4/fs/proc/meminfo.c linux-3.= 1.4/fs/proc/meminfo.c /* * display in kilobytes. */ -@@ -157,7 +159,7 @@ static int meminfo_proc_show(struct seq_ +@@ -157,7 +159,7 @@ static int meminfo_proc_show(struct seq_file *m, voi= d *v) vmi.used >> 10, vmi.largest_chunk >> 10 #ifdef CONFIG_MEMORY_FAILURE @@ -47004,10 +48346,11 @@ diff -urNp linux-3.1.4/fs/proc/meminfo.c linux-= 3.1.4/fs/proc/meminfo.c #endif #ifdef CONFIG_TRANSPARENT_HUGEPAGE ,K(global_page_state(NR_ANON_TRANSPARENT_HUGEPAGES) * -diff -urNp linux-3.1.4/fs/proc/nommu.c linux-3.1.4/fs/proc/nommu.c ---- linux-3.1.4/fs/proc/nommu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/nommu.c 2011-11-16 18:39:08.000000000 -0500 -@@ -66,7 +66,7 @@ static int nommu_region_show(struct seq_ +diff --git a/fs/proc/nommu.c b/fs/proc/nommu.c +index b1822dd..df622cb 100644 +--- a/fs/proc/nommu.c ++++ b/fs/proc/nommu.c +@@ -66,7 +66,7 @@ static int nommu_region_show(struct seq_file *m, struc= t vm_region *region) if (len < 1) len =3D 1; seq_printf(m, "%*c", len, ' '); @@ -47016,10 +48359,11 @@ diff -urNp linux-3.1.4/fs/proc/nommu.c linux-3.= 1.4/fs/proc/nommu.c } =20 seq_putc(m, '\n'); -diff -urNp linux-3.1.4/fs/proc/proc_net.c linux-3.1.4/fs/proc/proc_net.c ---- linux-3.1.4/fs/proc/proc_net.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/proc_net.c 2011-11-16 18:40:29.000000000 -0500 -@@ -105,6 +105,17 @@ static struct net *get_proc_task_net(str +diff --git a/fs/proc/proc_net.c b/fs/proc/proc_net.c +index f738024..876984a 100644 +--- a/fs/proc/proc_net.c ++++ b/fs/proc/proc_net.c +@@ -105,6 +105,17 @@ static struct net *get_proc_task_net(struct inode *= dir) struct task_struct *task; struct nsproxy *ns; struct net *net =3D NULL; @@ -47037,9 +48381,10 @@ diff -urNp linux-3.1.4/fs/proc/proc_net.c linux-= 3.1.4/fs/proc/proc_net.c =20 rcu_read_lock(); task =3D pid_task(proc_pid(dir), PIDTYPE_PID); -diff -urNp linux-3.1.4/fs/proc/proc_sysctl.c linux-3.1.4/fs/proc/proc_sy= sctl.c ---- linux-3.1.4/fs/proc/proc_sysctl.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/proc/proc_sysctl.c 2011-11-18 18:45:33.000000000 -050= 0 +diff --git a/fs/proc/proc_sysctl.c b/fs/proc/proc_sysctl.c +index 1a77dbe..56ec911 100644 +--- a/fs/proc/proc_sysctl.c ++++ b/fs/proc/proc_sysctl.c @@ -8,11 +8,13 @@ #include #include "internal.h" @@ -47056,7 +48401,7 @@ diff -urNp linux-3.1.4/fs/proc/proc_sysctl.c linu= x-3.1.4/fs/proc/proc_sysctl.c =20 static struct inode *proc_sys_make_inode(struct super_block *sb, struct ctl_table_header *head, struct ctl_table *table) -@@ -121,8 +123,14 @@ static struct dentry *proc_sys_lookup(st +@@ -121,8 +123,14 @@ static struct dentry *proc_sys_lookup(struct inode = *dir, struct dentry *dentry, =20 err =3D NULL; d_set_d_op(dentry, &proc_sys_dentry_operations); @@ -47071,7 +48416,7 @@ diff -urNp linux-3.1.4/fs/proc/proc_sysctl.c linu= x-3.1.4/fs/proc/proc_sysctl.c out: sysctl_head_finish(head); return err; -@@ -202,6 +210,9 @@ static int proc_sys_fill_cache(struct fi +@@ -202,6 +210,9 @@ static int proc_sys_fill_cache(struct file *filp, vo= id *dirent, return -ENOMEM; } else { d_set_d_op(child, &proc_sys_dentry_operations); @@ -47081,7 +48426,7 @@ diff -urNp linux-3.1.4/fs/proc/proc_sysctl.c linu= x-3.1.4/fs/proc/proc_sysctl.c d_add(child, inode); } } else { -@@ -230,6 +241,9 @@ static int scan(struct ctl_table_header=20 +@@ -230,6 +241,9 @@ static int scan(struct ctl_table_header *head, ctl_t= able *table, if (*pos < file->f_pos) continue; =20 @@ -47091,7 +48436,7 @@ diff -urNp linux-3.1.4/fs/proc/proc_sysctl.c linu= x-3.1.4/fs/proc/proc_sysctl.c res =3D proc_sys_fill_cache(file, dirent, filldir, head, table); if (res) return res; -@@ -355,6 +369,9 @@ static int proc_sys_getattr(struct vfsmo +@@ -355,6 +369,9 @@ static int proc_sys_getattr(struct vfsmount *mnt, st= ruct dentry *dentry, struct if (IS_ERR(head)) return PTR_ERR(head); =20 @@ -47101,7 +48446,7 @@ diff -urNp linux-3.1.4/fs/proc/proc_sysctl.c linu= x-3.1.4/fs/proc/proc_sysctl.c generic_fillattr(inode, stat); if (table) stat->mode =3D (stat->mode & S_IFMT) | table->mode; -@@ -370,17 +387,18 @@ static const struct file_operations proc +@@ -370,17 +387,18 @@ static const struct file_operations proc_sys_file_= operations =3D { }; =20 static const struct file_operations proc_sys_dir_file_operations =3D { @@ -47122,9 +48467,10 @@ diff -urNp linux-3.1.4/fs/proc/proc_sysctl.c lin= ux-3.1.4/fs/proc/proc_sysctl.c .lookup =3D proc_sys_lookup, .permission =3D proc_sys_permission, .setattr =3D proc_sys_setattr, -diff -urNp linux-3.1.4/fs/proc/root.c linux-3.1.4/fs/proc/root.c ---- linux-3.1.4/fs/proc/root.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/root.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/proc/root.c b/fs/proc/root.c +index 9a8a2b7..3018df6 100644 +--- a/fs/proc/root.c ++++ b/fs/proc/root.c @@ -123,7 +123,15 @@ void __init proc_root_init(void) #ifdef CONFIG_PROC_DEVICETREE proc_device_tree_init(); @@ -47141,10 +48487,11 @@ diff -urNp linux-3.1.4/fs/proc/root.c linux-3.1= .4/fs/proc/root.c proc_sys_init(); } =20 -diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3.1.4/fs/proc/task_mmu.c ---- linux-3.1.4/fs/proc/task_mmu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/task_mmu.c 2011-11-16 18:40:29.000000000 -0500 -@@ -51,8 +51,13 @@ void task_mem(struct seq_file *m, struct +diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c +index c7d4ee6..41c5564 100644 +--- a/fs/proc/task_mmu.c ++++ b/fs/proc/task_mmu.c +@@ -51,8 +51,13 @@ void task_mem(struct seq_file *m, struct mm_struct *m= m) "VmExe:\t%8lu kB\n" "VmLib:\t%8lu kB\n" "VmPTE:\t%8lu kB\n" @@ -47160,7 +48507,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c (total_vm - mm->reserved_vm) << (PAGE_SHIFT-10), mm->locked_vm << (PAGE_SHIFT-10), hiwater_rss << (PAGE_SHIFT-10), -@@ -60,7 +65,13 @@ void task_mem(struct seq_file *m, struct +@@ -60,7 +65,13 @@ void task_mem(struct seq_file *m, struct mm_struct *m= m) data << (PAGE_SHIFT-10), mm->stack_vm << (PAGE_SHIFT-10), text, lib, (PTRS_PER_PTE*sizeof(pte_t)*mm->nr_ptes) >> 10, @@ -47175,7 +48522,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c } =20 unsigned long task_vsize(struct mm_struct *mm) -@@ -207,6 +218,12 @@ static int do_maps_open(struct inode *in +@@ -207,6 +218,12 @@ static int do_maps_open(struct inode *inode, struct= file *file, return ret; } =20 @@ -47188,7 +48535,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c static void show_map_vma(struct seq_file *m, struct vm_area_struct *vma= ) { struct mm_struct *mm =3D vma->vm_mm; -@@ -225,13 +242,13 @@ static void show_map_vma(struct seq_file +@@ -225,13 +242,13 @@ static void show_map_vma(struct seq_file *m, struc= t vm_area_struct *vma) pgoff =3D ((loff_t)vma->vm_pgoff) << PAGE_SHIFT; } =20 @@ -47207,7 +48554,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c =20 seq_printf(m, "%08lx-%08lx %c%c%c%c %08llx %02x:%02x %lu %n", start, -@@ -240,7 +257,11 @@ static void show_map_vma(struct seq_file +@@ -240,7 +257,11 @@ static void show_map_vma(struct seq_file *m, struct= vm_area_struct *vma) flags & VM_WRITE ? 'w' : '-', flags & VM_EXEC ? 'x' : '-', flags & VM_MAYSHARE ? 's' : 'p', @@ -47219,7 +48566,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c MAJOR(dev), MINOR(dev), ino, &len); =20 /* -@@ -249,7 +270,7 @@ static void show_map_vma(struct seq_file +@@ -249,7 +270,7 @@ static void show_map_vma(struct seq_file *m, struct = vm_area_struct *vma) */ if (file) { pad_len_spaces(m, len); @@ -47228,7 +48575,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c } else { const char *name =3D arch_vma_name(vma); if (!name) { -@@ -257,8 +278,9 @@ static void show_map_vma(struct seq_file +@@ -257,8 +278,9 @@ static void show_map_vma(struct seq_file *m, struct = vm_area_struct *vma) if (vma->vm_start <=3D mm->brk && vma->vm_end >=3D mm->start_brk) { name =3D "[heap]"; @@ -47240,7 +48587,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c name =3D "[stack]"; } } else { -@@ -433,11 +455,16 @@ static int show_smap(struct seq_file *m, +@@ -433,11 +455,16 @@ static int show_smap(struct seq_file *m, void *v) }; =20 memset(&mss, 0, sizeof mss); @@ -47262,7 +48609,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c show_map_vma(m, vma); =20 seq_printf(m, -@@ -455,7 +482,11 @@ static int show_smap(struct seq_file *m, +@@ -455,7 +482,11 @@ static int show_smap(struct seq_file *m, void *v) "KernelPageSize: %8lu kB\n" "MMUPageSize: %8lu kB\n" "Locked: %8lu kB\n", @@ -47274,7 +48621,7 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux-3= .1.4/fs/proc/task_mmu.c mss.resident >> 10, (unsigned long)(mss.pss >> (10 + PSS_SHIFT)), mss.shared_clean >> 10, -@@ -1031,7 +1062,7 @@ static int show_numa_map(struct seq_file +@@ -1031,7 +1062,7 @@ static int show_numa_map(struct seq_file *m, void = *v) =20 if (file) { seq_printf(m, " file=3D"); @@ -47283,10 +48630,11 @@ diff -urNp linux-3.1.4/fs/proc/task_mmu.c linux= -3.1.4/fs/proc/task_mmu.c } else if (vma->vm_start <=3D mm->brk && vma->vm_end >=3D mm->start_br= k) { seq_printf(m, " heap"); } else if (vma->vm_start <=3D mm->start_stack && -diff -urNp linux-3.1.4/fs/proc/task_nommu.c linux-3.1.4/fs/proc/task_nom= mu.c ---- linux-3.1.4/fs/proc/task_nommu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/proc/task_nommu.c 2011-11-16 18:39:08.000000000 -0500 -@@ -51,7 +51,7 @@ void task_mem(struct seq_file *m, struct +diff --git a/fs/proc/task_nommu.c b/fs/proc/task_nommu.c +index 980de54..2a4db5f 100644 +--- a/fs/proc/task_nommu.c ++++ b/fs/proc/task_nommu.c +@@ -51,7 +51,7 @@ void task_mem(struct seq_file *m, struct mm_struct *mm= ) else bytes +=3D kobjsize(mm); =09 @@ -47295,7 +48643,7 @@ diff -urNp linux-3.1.4/fs/proc/task_nommu.c linux= -3.1.4/fs/proc/task_nommu.c sbytes +=3D kobjsize(current->fs); else bytes +=3D kobjsize(current->fs); -@@ -166,7 +166,7 @@ static int nommu_vma_show(struct seq_fil +@@ -166,7 +166,7 @@ static int nommu_vma_show(struct seq_file *m, struct= vm_area_struct *vma) =20 if (file) { pad_len_spaces(m, len); @@ -47304,10 +48652,11 @@ diff -urNp linux-3.1.4/fs/proc/task_nommu.c lin= ux-3.1.4/fs/proc/task_nommu.c } else if (mm) { if (vma->vm_start <=3D mm->start_stack && vma->vm_end >=3D mm->start_stack) { -diff -urNp linux-3.1.4/fs/quota/netlink.c linux-3.1.4/fs/quota/netlink.c ---- linux-3.1.4/fs/quota/netlink.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/quota/netlink.c 2011-11-16 18:39:08.000000000 -0500 -@@ -33,7 +33,7 @@ static struct genl_family quota_genl_fam +diff --git a/fs/quota/netlink.c b/fs/quota/netlink.c +index d67908b..d13f6a6 100644 +--- a/fs/quota/netlink.c ++++ b/fs/quota/netlink.c +@@ -33,7 +33,7 @@ static struct genl_family quota_genl_family =3D { void quota_send_warning(short type, unsigned int id, dev_t dev, const char warntype) { @@ -47316,7 +48665,7 @@ diff -urNp linux-3.1.4/fs/quota/netlink.c linux-3= .1.4/fs/quota/netlink.c struct sk_buff *skb; void *msg_head; int ret; -@@ -49,7 +49,7 @@ void quota_send_warning(short type, unsi +@@ -49,7 +49,7 @@ void quota_send_warning(short type, unsigned int id, d= ev_t dev, "VFS: Not enough memory to send quota warning.\n"); return; } @@ -47325,9 +48674,10 @@ diff -urNp linux-3.1.4/fs/quota/netlink.c linux-= 3.1.4/fs/quota/netlink.c "a_genl_family, 0, QUOTA_NL_C_WARNING); if (!msg_head) { printk(KERN_ERR -diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/fs/readdir.c ---- linux-3.1.4/fs/readdir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/readdir.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/readdir.c b/fs/readdir.c +index 356f715..c918d38 100644 +--- a/fs/readdir.c ++++ b/fs/readdir.c @@ -17,6 +17,7 @@ #include #include @@ -47344,7 +48694,7 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/f= s/readdir.c int result; }; =20 -@@ -84,6 +86,10 @@ static int fillonedir(void * __buf, cons +@@ -84,6 +86,10 @@ static int fillonedir(void * __buf, const char * name= , int namlen, loff_t offset buf->result =3D -EOVERFLOW; return -EOVERFLOW; } @@ -47355,7 +48705,7 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/f= s/readdir.c buf->result++; dirent =3D buf->dirent; if (!access_ok(VERIFY_WRITE, dirent, -@@ -116,6 +122,7 @@ SYSCALL_DEFINE3(old_readdir, unsigned in +@@ -116,6 +122,7 @@ SYSCALL_DEFINE3(old_readdir, unsigned int, fd, =20 buf.result =3D 0; buf.dirent =3D dirent; @@ -47371,7 +48721,7 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/f= s/readdir.c int count; int error; }; -@@ -163,6 +171,10 @@ static int filldir(void * __buf, const c +@@ -163,6 +171,10 @@ static int filldir(void * __buf, const char * name,= int namlen, loff_t offset, buf->error =3D -EOVERFLOW; return -EOVERFLOW; } @@ -47382,7 +48732,7 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/f= s/readdir.c dirent =3D buf->previous; if (dirent) { if (__put_user(offset, &dirent->d_off)) -@@ -210,6 +222,7 @@ SYSCALL_DEFINE3(getdents, unsigned int,=20 +@@ -210,6 +222,7 @@ SYSCALL_DEFINE3(getdents, unsigned int, fd, buf.previous =3D NULL; buf.count =3D count; buf.error =3D 0; @@ -47398,7 +48748,7 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/f= s/readdir.c int count; int error; }; -@@ -244,6 +258,10 @@ static int filldir64(void * __buf, const +@@ -244,6 +258,10 @@ static int filldir64(void * __buf, const char * nam= e, int namlen, loff_t offset, buf->error =3D -EINVAL; /* only used if we fail.. */ if (reclen > buf->count) return -EINVAL; @@ -47409,7 +48759,7 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/f= s/readdir.c dirent =3D buf->previous; if (dirent) { if (__put_user(offset, &dirent->d_off)) -@@ -291,6 +309,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int +@@ -291,6 +309,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int, fd, =20 buf.current_dir =3D dirent; buf.previous =3D NULL; @@ -47417,7 +48767,7 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4/f= s/readdir.c buf.count =3D count; buf.error =3D 0; =20 -@@ -299,7 +318,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int +@@ -299,7 +318,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int, fd, error =3D buf.error; lastdirent =3D buf.previous; if (lastdirent) { @@ -47426,10 +48776,11 @@ diff -urNp linux-3.1.4/fs/readdir.c linux-3.1.4= /fs/readdir.c if (__put_user(d_off, &lastdirent->d_off)) error =3D -EFAULT; else -diff -urNp linux-3.1.4/fs/reiserfs/dir.c linux-3.1.4/fs/reiserfs/dir.c ---- linux-3.1.4/fs/reiserfs/dir.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/reiserfs/dir.c 2011-11-16 18:40:29.000000000 -0500 -@@ -75,6 +75,8 @@ int reiserfs_readdir_dentry(struct dentr +diff --git a/fs/reiserfs/dir.c b/fs/reiserfs/dir.c +index 133e935..349ef18 100644 +--- a/fs/reiserfs/dir.c ++++ b/fs/reiserfs/dir.c +@@ -75,6 +75,8 @@ int reiserfs_readdir_dentry(struct dentry *dentry, voi= d *dirent, struct reiserfs_dir_entry de; int ret =3D 0; =20 @@ -47438,10 +48789,11 @@ diff -urNp linux-3.1.4/fs/reiserfs/dir.c linux-= 3.1.4/fs/reiserfs/dir.c reiserfs_write_lock(inode->i_sb); =20 reiserfs_check_lock_depth(inode->i_sb, "readdir"); -diff -urNp linux-3.1.4/fs/reiserfs/do_balan.c linux-3.1.4/fs/reiserfs/do= _balan.c ---- linux-3.1.4/fs/reiserfs/do_balan.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/fs/reiserfs/do_balan.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -2051,7 +2051,7 @@ void do_balance(struct tree_balance *tb, +diff --git a/fs/reiserfs/do_balan.c b/fs/reiserfs/do_balan.c +index 60c0804..d814f98 100644 +--- a/fs/reiserfs/do_balan.c ++++ b/fs/reiserfs/do_balan.c +@@ -2051,7 +2051,7 @@ void do_balance(struct tree_balance *tb, /* tree_b= alance structure */ return; } =20 @@ -47450,10 +48802,11 @@ diff -urNp linux-3.1.4/fs/reiserfs/do_balan.c l= inux-3.1.4/fs/reiserfs/do_balan.c do_balance_starts(tb); =20 /* balance leaf returns 0 except if combining L R and S into -diff -urNp linux-3.1.4/fs/reiserfs/journal.c linux-3.1.4/fs/reiserfs/jou= rnal.c ---- linux-3.1.4/fs/reiserfs/journal.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/reiserfs/journal.c 2011-11-16 18:40:29.000000000 -050= 0 -@@ -2289,6 +2289,8 @@ static struct buffer_head *reiserfs_brea +diff --git a/fs/reiserfs/journal.c b/fs/reiserfs/journal.c +index a159ba5..0396a76 100644 +--- a/fs/reiserfs/journal.c ++++ b/fs/reiserfs/journal.c +@@ -2289,6 +2289,8 @@ static struct buffer_head *reiserfs_breada(struct = block_device *dev, struct buffer_head *bh; int i, j; =20 @@ -47462,10 +48815,11 @@ diff -urNp linux-3.1.4/fs/reiserfs/journal.c li= nux-3.1.4/fs/reiserfs/journal.c bh =3D __getblk(dev, block, bufsize); if (buffer_uptodate(bh)) return (bh); -diff -urNp linux-3.1.4/fs/reiserfs/namei.c linux-3.1.4/fs/reiserfs/namei= .c ---- linux-3.1.4/fs/reiserfs/namei.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/reiserfs/namei.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1225,6 +1225,8 @@ static int reiserfs_rename(struct inode=20 +diff --git a/fs/reiserfs/namei.c b/fs/reiserfs/namei.c +index ef39232..0fa91ba 100644 +--- a/fs/reiserfs/namei.c ++++ b/fs/reiserfs/namei.c +@@ -1225,6 +1225,8 @@ static int reiserfs_rename(struct inode *old_dir, = struct dentry *old_dentry, unsigned long savelink =3D 1; struct timespec ctime; =20 @@ -47474,10 +48828,11 @@ diff -urNp linux-3.1.4/fs/reiserfs/namei.c linu= x-3.1.4/fs/reiserfs/namei.c /* three balancings: (1) old name removal, (2) new name insertion and (3) maybe "save" link insertion stat data updates: (1) old directory, -diff -urNp linux-3.1.4/fs/reiserfs/procfs.c linux-3.1.4/fs/reiserfs/proc= fs.c ---- linux-3.1.4/fs/reiserfs/procfs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/reiserfs/procfs.c 2011-11-16 18:40:29.000000000 -0500 -@@ -113,7 +113,7 @@ static int show_super(struct seq_file *m +diff --git a/fs/reiserfs/procfs.c b/fs/reiserfs/procfs.c +index 7a99811..2c9286f 100644 +--- a/fs/reiserfs/procfs.c ++++ b/fs/reiserfs/procfs.c +@@ -113,7 +113,7 @@ static int show_super(struct seq_file *m, struct sup= er_block *sb) "SMALL_TAILS " : "NO_TAILS ", replay_only(sb) ? "REPLAY_ONLY " : "", convert_reiserfs(sb) ? "CONV " : "", @@ -47486,7 +48841,7 @@ diff -urNp linux-3.1.4/fs/reiserfs/procfs.c linux= -3.1.4/fs/reiserfs/procfs.c SF(s_disk_reads), SF(s_disk_writes), SF(s_fix_nodes), SF(s_do_balance), SF(s_unneeded_left_neighbor), SF(s_good_search_by_key_reada), SF(s_bmaps), -@@ -299,6 +299,8 @@ static int show_journal(struct seq_file=20 +@@ -299,6 +299,8 @@ static int show_journal(struct seq_file *m, struct s= uper_block *sb) struct journal_params *jp =3D &rs->s_v1.s_journal; char b[BDEVNAME_SIZE]; =20 @@ -47495,10 +48850,11 @@ diff -urNp linux-3.1.4/fs/reiserfs/procfs.c lin= ux-3.1.4/fs/reiserfs/procfs.c seq_printf(m, /* on-disk fields */ "jp_journal_1st_block: \t%i\n" "jp_journal_dev: \t%s[%x]\n" -diff -urNp linux-3.1.4/fs/reiserfs/stree.c linux-3.1.4/fs/reiserfs/stree= .c ---- linux-3.1.4/fs/reiserfs/stree.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/reiserfs/stree.c 2011-11-16 18:40:29.000000000 -0500 -@@ -1196,6 +1196,8 @@ int reiserfs_delete_item(struct reiserfs +diff --git a/fs/reiserfs/stree.c b/fs/reiserfs/stree.c +index 313d39d..3a5811b 100644 +--- a/fs/reiserfs/stree.c ++++ b/fs/reiserfs/stree.c +@@ -1196,6 +1196,8 @@ int reiserfs_delete_item(struct reiserfs_transacti= on_handle *th, int iter =3D 0; #endif =20 @@ -47507,7 +48863,7 @@ diff -urNp linux-3.1.4/fs/reiserfs/stree.c linux-= 3.1.4/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); =20 init_tb_struct(th, &s_del_balance, sb, path, -@@ -1333,6 +1335,8 @@ void reiserfs_delete_solid_item(struct r +@@ -1333,6 +1335,8 @@ void reiserfs_delete_solid_item(struct reiserfs_tr= ansaction_handle *th, int retval; int quota_cut_bytes =3D 0; =20 @@ -47516,7 +48872,7 @@ diff -urNp linux-3.1.4/fs/reiserfs/stree.c linux-= 3.1.4/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); =20 le_key2cpu_key(&cpu_key, key); -@@ -1562,6 +1566,8 @@ int reiserfs_cut_from_item(struct reiser +@@ -1562,6 +1566,8 @@ int reiserfs_cut_from_item(struct reiserfs_transac= tion_handle *th, int quota_cut_bytes; loff_t tail_pos =3D 0; =20 @@ -47525,7 +48881,7 @@ diff -urNp linux-3.1.4/fs/reiserfs/stree.c linux-= 3.1.4/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); =20 init_tb_struct(th, &s_cut_balance, inode->i_sb, path, -@@ -1957,6 +1963,8 @@ int reiserfs_paste_into_item(struct reis +@@ -1957,6 +1963,8 @@ int reiserfs_paste_into_item(struct reiserfs_trans= action_handle *th, struct tree int retval; int fs_gen; =20 @@ -47534,7 +48890,7 @@ diff -urNp linux-3.1.4/fs/reiserfs/stree.c linux-= 3.1.4/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); =20 fs_gen =3D get_generation(inode->i_sb); -@@ -2045,6 +2053,8 @@ int reiserfs_insert_item(struct reiserfs +@@ -2045,6 +2053,8 @@ int reiserfs_insert_item(struct reiserfs_transacti= on_handle *th, int fs_gen =3D 0; int quota_bytes =3D 0; =20 @@ -47543,10 +48899,11 @@ diff -urNp linux-3.1.4/fs/reiserfs/stree.c linu= x-3.1.4/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); =20 if (inode) { /* Do we count quotas for item? */ -diff -urNp linux-3.1.4/fs/reiserfs/super.c linux-3.1.4/fs/reiserfs/super= .c ---- linux-3.1.4/fs/reiserfs/super.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/reiserfs/super.c 2011-11-16 18:40:29.000000000 -0500 -@@ -927,6 +927,8 @@ static int reiserfs_parse_options(struct +diff --git a/fs/reiserfs/super.c b/fs/reiserfs/super.c +index 14363b9..dd95a04 100644 +--- a/fs/reiserfs/super.c ++++ b/fs/reiserfs/super.c +@@ -927,6 +927,8 @@ static int reiserfs_parse_options(struct super_block= *s, char *options, /* strin {.option_name =3D NULL} }; =20 @@ -47555,9 +48912,10 @@ diff -urNp linux-3.1.4/fs/reiserfs/super.c linux= -3.1.4/fs/reiserfs/super.c *blocks =3D 0; if (!options || !*options) /* use default configuration: create tails, journaling on, no -diff -urNp linux-3.1.4/fs/select.c linux-3.1.4/fs/select.c ---- linux-3.1.4/fs/select.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/select.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/select.c b/fs/select.c +index d33418f..f8e06bc 100644 +--- a/fs/select.c ++++ b/fs/select.c @@ -20,6 +20,7 @@ #include #include @@ -47566,7 +48924,7 @@ diff -urNp linux-3.1.4/fs/select.c linux-3.1.4/fs= /select.c #include /* for STICKY_TIMEOUTS */ #include #include -@@ -403,6 +404,8 @@ int do_select(int n, fd_set_bits *fds, s +@@ -403,6 +404,8 @@ int do_select(int n, fd_set_bits *fds, struct timesp= ec *end_time) int retval, i, timed_out =3D 0; unsigned long slack =3D 0; =20 @@ -47575,7 +48933,7 @@ diff -urNp linux-3.1.4/fs/select.c linux-3.1.4/fs= /select.c rcu_read_lock(); retval =3D max_select_fd(n, fds); rcu_read_unlock(); -@@ -528,6 +531,8 @@ int core_sys_select(int n, fd_set __user +@@ -528,6 +531,8 @@ int core_sys_select(int n, fd_set __user *inp, fd_se= t __user *outp, /* Allocate small arguments on the stack to save memory and be faster = */ long stack_fds[SELECT_STACK_ALLOC/sizeof(long)]; =20 @@ -47584,7 +48942,7 @@ diff -urNp linux-3.1.4/fs/select.c linux-3.1.4/fs= /select.c ret =3D -EINVAL; if (n < 0) goto out_nofds; -@@ -837,6 +842,9 @@ int do_sys_poll(struct pollfd __user *uf +@@ -837,6 +842,9 @@ int do_sys_poll(struct pollfd __user *ufds, unsigned= int nfds, struct poll_list *walk =3D head; unsigned long todo =3D nfds; =20 @@ -47594,10 +48952,11 @@ diff -urNp linux-3.1.4/fs/select.c linux-3.1.4/= fs/select.c if (nfds > rlimit(RLIMIT_NOFILE)) return -EINVAL; =20 -diff -urNp linux-3.1.4/fs/seq_file.c linux-3.1.4/fs/seq_file.c ---- linux-3.1.4/fs/seq_file.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/seq_file.c 2011-11-16 18:39:08.000000000 -0500 -@@ -76,7 +76,8 @@ static int traverse(struct seq_file *m,=20 +diff --git a/fs/seq_file.c b/fs/seq_file.c +index 05d6b0e..ee96362 100644 +--- a/fs/seq_file.c ++++ b/fs/seq_file.c +@@ -76,7 +76,8 @@ static int traverse(struct seq_file *m, loff_t offset) return 0; } if (!m->buf) { @@ -47607,7 +48966,7 @@ diff -urNp linux-3.1.4/fs/seq_file.c linux-3.1.4/= fs/seq_file.c if (!m->buf) return -ENOMEM; } -@@ -116,7 +117,8 @@ static int traverse(struct seq_file *m,=20 +@@ -116,7 +117,8 @@ static int traverse(struct seq_file *m, loff_t offse= t) Eoverflow: m->op->stop(m, p); kfree(m->buf); @@ -47617,7 +48976,7 @@ diff -urNp linux-3.1.4/fs/seq_file.c linux-3.1.4/= fs/seq_file.c return !m->buf ? -ENOMEM : -EAGAIN; } =20 -@@ -169,7 +171,8 @@ ssize_t seq_read(struct file *file, char +@@ -169,7 +171,8 @@ ssize_t seq_read(struct file *file, char __user *buf= , size_t size, loff_t *ppos) m->version =3D file->f_version; /* grab buffer if we didn't have one */ if (!m->buf) { @@ -47627,7 +48986,7 @@ diff -urNp linux-3.1.4/fs/seq_file.c linux-3.1.4/= fs/seq_file.c if (!m->buf) goto Enomem; } -@@ -210,7 +213,8 @@ ssize_t seq_read(struct file *file, char +@@ -210,7 +213,8 @@ ssize_t seq_read(struct file *file, char __user *buf= , size_t size, loff_t *ppos) goto Fill; m->op->stop(m, p); kfree(m->buf); @@ -47637,7 +48996,7 @@ diff -urNp linux-3.1.4/fs/seq_file.c linux-3.1.4/= fs/seq_file.c if (!m->buf) goto Enomem; m->count =3D 0; -@@ -549,7 +553,7 @@ static void single_stop(struct seq_file=20 +@@ -549,7 +553,7 @@ static void single_stop(struct seq_file *p, void *v) int single_open(struct file *file, int (*show)(struct seq_file *, void = *), void *data) { @@ -47646,10 +49005,11 @@ diff -urNp linux-3.1.4/fs/seq_file.c linux-3.1.= 4/fs/seq_file.c int res =3D -ENOMEM; =20 if (op) { -diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs/splice.c ---- linux-3.1.4/fs/splice.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/splice.c 2011-11-16 18:40:29.000000000 -0500 -@@ -194,7 +194,7 @@ ssize_t splice_to_pipe(struct pipe_inode +diff --git a/fs/splice.c b/fs/splice.c +index fa2defa..9a697a5 100644 +--- a/fs/splice.c ++++ b/fs/splice.c +@@ -194,7 +194,7 @@ ssize_t splice_to_pipe(struct pipe_inode_info *pipe, pipe_lock(pipe); =20 for (;;) { @@ -47658,7 +49018,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c send_sig(SIGPIPE, current, 0); if (!ret) ret =3D -EPIPE; -@@ -248,9 +248,9 @@ ssize_t splice_to_pipe(struct pipe_inode +@@ -248,9 +248,9 @@ ssize_t splice_to_pipe(struct pipe_inode_info *pipe, do_wakeup =3D 0; } =20 @@ -47670,7 +49030,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c } =20 pipe_unlock(pipe); -@@ -320,6 +320,8 @@ __generic_file_splice_read(struct file * +@@ -320,6 +320,8 @@ __generic_file_splice_read(struct file *in, loff_t *= ppos, .spd_release =3D spd_release_page, }; =20 @@ -47679,7 +49039,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; =20 -@@ -560,7 +562,7 @@ static ssize_t kernel_readv(struct file=20 +@@ -560,7 +562,7 @@ static ssize_t kernel_readv(struct file *file, const= struct iovec *vec, old_fs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -47688,7 +49048,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c set_fs(old_fs); =20 return res; -@@ -575,7 +577,7 @@ static ssize_t kernel_write(struct file=20 +@@ -575,7 +577,7 @@ static ssize_t kernel_write(struct file *file, const= char *buf, size_t count, old_fs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -47697,7 +49057,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c set_fs(old_fs); =20 return res; -@@ -603,6 +605,8 @@ ssize_t default_file_splice_read(struct=20 +@@ -603,6 +605,8 @@ ssize_t default_file_splice_read(struct file *in, lo= ff_t *ppos, .spd_release =3D spd_release_page, }; =20 @@ -47706,7 +49066,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; =20 -@@ -626,7 +630,7 @@ ssize_t default_file_splice_read(struct=20 +@@ -626,7 +630,7 @@ ssize_t default_file_splice_read(struct file *in, lo= ff_t *ppos, goto err; =20 this_len =3D min_t(size_t, len, PAGE_CACHE_SIZE - offset); @@ -47728,7 +49088,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c return 0; =20 if (sd->flags & SPLICE_F_NONBLOCK) -@@ -1182,7 +1186,7 @@ ssize_t splice_direct_to_actor(struct fi +@@ -1182,7 +1186,7 @@ ssize_t splice_direct_to_actor(struct file *in, st= ruct splice_desc *sd, * out of the pipe right after the splice_to_pipe(). So set * PIPE_READERS appropriately. */ @@ -47737,7 +49097,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c =20 current->splice_pipe =3D pipe; } -@@ -1619,6 +1623,8 @@ static long vmsplice_to_pipe(struct file +@@ -1619,6 +1623,8 @@ static long vmsplice_to_pipe(struct file *file, co= nst struct iovec __user *iov, }; long ret; =20 @@ -47746,7 +49106,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c pipe =3D get_pipe_info(file); if (!pipe) return -EBADF; -@@ -1734,9 +1740,9 @@ static int ipipe_prep(struct pipe_inode_ +@@ -1734,9 +1740,9 @@ static int ipipe_prep(struct pipe_inode_info *pipe= , unsigned int flags) ret =3D -ERESTARTSYS; break; } @@ -47758,7 +49118,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c if (flags & SPLICE_F_NONBLOCK) { ret =3D -EAGAIN; break; -@@ -1768,7 +1774,7 @@ static int opipe_prep(struct pipe_inode_ +@@ -1768,7 +1774,7 @@ static int opipe_prep(struct pipe_inode_info *pipe= , unsigned int flags) pipe_lock(pipe); =20 while (pipe->nrbufs >=3D pipe->buffers) { @@ -47767,7 +49127,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c send_sig(SIGPIPE, current, 0); ret =3D -EPIPE; break; -@@ -1781,9 +1787,9 @@ static int opipe_prep(struct pipe_inode_ +@@ -1781,9 +1787,9 @@ static int opipe_prep(struct pipe_inode_info *pipe= , unsigned int flags) ret =3D -ERESTARTSYS; break; } @@ -47796,7 +49156,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c break; =20 /* -@@ -1923,7 +1929,7 @@ static int link_pipe(struct pipe_inode_i +@@ -1923,7 +1929,7 @@ static int link_pipe(struct pipe_inode_info *ipipe= , pipe_double_lock(ipipe, opipe); =20 do { @@ -47805,7 +49165,7 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/fs= /splice.c send_sig(SIGPIPE, current, 0); if (!ret) ret =3D -EPIPE; -@@ -1968,7 +1974,7 @@ static int link_pipe(struct pipe_inode_i +@@ -1968,7 +1974,7 @@ static int link_pipe(struct pipe_inode_info *ipipe= , * return EAGAIN if we have the potential of some data in the * future, otherwise just return 0 */ @@ -47814,10 +49174,11 @@ diff -urNp linux-3.1.4/fs/splice.c linux-3.1.4/= fs/splice.c ret =3D -EAGAIN; =20 pipe_unlock(ipipe); -diff -urNp linux-3.1.4/fs/sysfs/file.c linux-3.1.4/fs/sysfs/file.c ---- linux-3.1.4/fs/sysfs/file.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/sysfs/file.c 2011-11-16 18:39:08.000000000 -0500 -@@ -37,7 +37,7 @@ static DEFINE_SPINLOCK(sysfs_open_dirent +diff --git a/fs/sysfs/file.c b/fs/sysfs/file.c +index 1ad8c93..6633545 100644 +--- a/fs/sysfs/file.c ++++ b/fs/sysfs/file.c +@@ -37,7 +37,7 @@ static DEFINE_SPINLOCK(sysfs_open_dirent_lock); =20 struct sysfs_open_dirent { atomic_t refcnt; @@ -47826,7 +49187,7 @@ diff -urNp linux-3.1.4/fs/sysfs/file.c linux-3.1.= 4/fs/sysfs/file.c wait_queue_head_t poll; struct list_head buffers; /* goes through sysfs_buffer.list */ }; -@@ -81,7 +81,7 @@ static int fill_read_buffer(struct dentr +@@ -81,7 +81,7 @@ static int fill_read_buffer(struct dentry * dentry, st= ruct sysfs_buffer * buffer if (!sysfs_get_active(attr_sd)) return -ENODEV; =20 @@ -47835,7 +49196,7 @@ diff -urNp linux-3.1.4/fs/sysfs/file.c linux-3.1.= 4/fs/sysfs/file.c count =3D ops->show(kobj, attr_sd->s_attr.attr, buffer->page); =20 sysfs_put_active(attr_sd); -@@ -287,7 +287,7 @@ static int sysfs_get_open_dirent(struct=20 +@@ -287,7 +287,7 @@ static int sysfs_get_open_dirent(struct sysfs_dirent= *sd, return -ENOMEM; =20 atomic_set(&new_od->refcnt, 0); @@ -47844,7 +49205,7 @@ diff -urNp linux-3.1.4/fs/sysfs/file.c linux-3.1.= 4/fs/sysfs/file.c init_waitqueue_head(&new_od->poll); INIT_LIST_HEAD(&new_od->buffers); goto retry; -@@ -432,7 +432,7 @@ static unsigned int sysfs_poll(struct fi +@@ -432,7 +432,7 @@ static unsigned int sysfs_poll(struct file *filp, po= ll_table *wait) =20 sysfs_put_active(attr_sd); =20 @@ -47853,7 +49214,7 @@ diff -urNp linux-3.1.4/fs/sysfs/file.c linux-3.1.= 4/fs/sysfs/file.c goto trigger; =20 return DEFAULT_POLLMASK; -@@ -451,7 +451,7 @@ void sysfs_notify_dirent(struct sysfs_di +@@ -451,7 +451,7 @@ void sysfs_notify_dirent(struct sysfs_dirent *sd) =20 od =3D sd->s_attr.open; if (od) { @@ -47862,9 +49223,10 @@ diff -urNp linux-3.1.4/fs/sysfs/file.c linux-3.1= .4/fs/sysfs/file.c wake_up_interruptible(&od->poll); } =20 -diff -urNp linux-3.1.4/fs/sysfs/mount.c linux-3.1.4/fs/sysfs/mount.c ---- linux-3.1.4/fs/sysfs/mount.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/sysfs/mount.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/sysfs/mount.c b/fs/sysfs/mount.c +index e34f0d9..740ea7b 100644 +--- a/fs/sysfs/mount.c ++++ b/fs/sysfs/mount.c @@ -36,7 +36,11 @@ struct sysfs_dirent sysfs_root =3D { .s_name =3D "", .s_count =3D ATOMIC_INIT(1), @@ -47877,10 +49239,11 @@ diff -urNp linux-3.1.4/fs/sysfs/mount.c linux-3= .1.4/fs/sysfs/mount.c .s_ino =3D 1, }; =20 -diff -urNp linux-3.1.4/fs/sysfs/symlink.c linux-3.1.4/fs/sysfs/symlink.c ---- linux-3.1.4/fs/sysfs/symlink.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/sysfs/symlink.c 2011-11-16 18:39:08.000000000 -0500 -@@ -286,7 +286,7 @@ static void *sysfs_follow_link(struct de +diff --git a/fs/sysfs/symlink.c b/fs/sysfs/symlink.c +index a7ac78f..02158e1 100644 +--- a/fs/sysfs/symlink.c ++++ b/fs/sysfs/symlink.c +@@ -286,7 +286,7 @@ static void *sysfs_follow_link(struct dentry *dentry= , struct nameidata *nd) =20 static void sysfs_put_link(struct dentry *dentry, struct nameidata *nd,= void *cookie) { @@ -47889,10 +49252,11 @@ diff -urNp linux-3.1.4/fs/sysfs/symlink.c linux= -3.1.4/fs/sysfs/symlink.c if (!IS_ERR(page)) free_page((unsigned long)page); } -diff -urNp linux-3.1.4/fs/udf/inode.c linux-3.1.4/fs/udf/inode.c ---- linux-3.1.4/fs/udf/inode.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/udf/inode.c 2011-11-16 18:40:29.000000000 -0500 -@@ -560,6 +560,8 @@ static struct buffer_head *inode_getblk( +diff --git a/fs/udf/inode.c b/fs/udf/inode.c +index 1d1358e..408bedb 100644 +--- a/fs/udf/inode.c ++++ b/fs/udf/inode.c +@@ -560,6 +560,8 @@ static struct buffer_head *inode_getblk(struct inode= *inode, sector_t block, int goal =3D 0, pgoal =3D iinfo->i_location.logicalBlockNum; int lastblock =3D 0; =20 @@ -47901,10 +49265,11 @@ diff -urNp linux-3.1.4/fs/udf/inode.c linux-3.1= .4/fs/udf/inode.c prev_epos.offset =3D udf_file_entry_alloc_offset(inode); prev_epos.block =3D iinfo->i_location; prev_epos.bh =3D NULL; -diff -urNp linux-3.1.4/fs/udf/misc.c linux-3.1.4/fs/udf/misc.c ---- linux-3.1.4/fs/udf/misc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/udf/misc.c 2011-11-16 18:39:08.000000000 -0500 -@@ -286,7 +286,7 @@ void udf_new_tag(char *data, uint16_t id +diff --git a/fs/udf/misc.c b/fs/udf/misc.c +index 9215700..bf1f68e 100644 +--- a/fs/udf/misc.c ++++ b/fs/udf/misc.c +@@ -286,7 +286,7 @@ void udf_new_tag(char *data, uint16_t ident, uint16_= t version, uint16_t snum, =20 u8 udf_tag_checksum(const struct tag *t) { @@ -47913,9 +49278,10 @@ diff -urNp linux-3.1.4/fs/udf/misc.c linux-3.1.4= /fs/udf/misc.c u8 checksum =3D 0; int i; for (i =3D 0; i < sizeof(struct tag); ++i) -diff -urNp linux-3.1.4/fs/utimes.c linux-3.1.4/fs/utimes.c ---- linux-3.1.4/fs/utimes.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/utimes.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/utimes.c b/fs/utimes.c +index ba653f3..06ea4b1 100644 +--- a/fs/utimes.c ++++ b/fs/utimes.c @@ -1,6 +1,7 @@ #include #include @@ -47924,7 +49290,7 @@ diff -urNp linux-3.1.4/fs/utimes.c linux-3.1.4/fs= /utimes.c #include #include #include -@@ -101,6 +102,12 @@ static int utimes_common(struct path *pa +@@ -101,6 +102,12 @@ static int utimes_common(struct path *path, struct = timespec *times) goto mnt_drop_write_and_out; } } @@ -47937,23 +49303,10 @@ diff -urNp linux-3.1.4/fs/utimes.c linux-3.1.4/= fs/utimes.c mutex_lock(&inode->i_mutex); error =3D notify_change(path->dentry, &newattrs); mutex_unlock(&inode->i_mutex); -diff -urNp linux-3.1.4/fs/xattr_acl.c linux-3.1.4/fs/xattr_acl.c ---- linux-3.1.4/fs/xattr_acl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/xattr_acl.c 2011-11-16 18:39:08.000000000 -0500 -@@ -17,8 +17,8 @@ - struct posix_acl * - posix_acl_from_xattr(const void *value, size_t size) - { -- posix_acl_xattr_header *header =3D (posix_acl_xattr_header *)value; -- posix_acl_xattr_entry *entry =3D (posix_acl_xattr_entry *)(header+1), = *end; -+ const posix_acl_xattr_header *header =3D (const posix_acl_xattr_header= *)value; -+ const posix_acl_xattr_entry *entry =3D (const posix_acl_xattr_entry *)= (header+1), *end; - int count; - struct posix_acl *acl; - struct posix_acl_entry *acl_e; -diff -urNp linux-3.1.4/fs/xattr.c linux-3.1.4/fs/xattr.c ---- linux-3.1.4/fs/xattr.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/xattr.c 2011-11-16 18:40:29.000000000 -0500 +diff --git a/fs/xattr.c b/fs/xattr.c +index f060663..def7007 100644 +--- a/fs/xattr.c ++++ b/fs/xattr.c @@ -254,7 +254,7 @@ EXPORT_SYMBOL_GPL(vfs_removexattr); * Extended attribute SET operations */ @@ -47963,7 +49316,7 @@ diff -urNp linux-3.1.4/fs/xattr.c linux-3.1.4/fs/= xattr.c size_t size, int flags) { int error; -@@ -278,7 +278,13 @@ setxattr(struct dentry *d, const char __ +@@ -278,7 +278,13 @@ setxattr(struct dentry *d, const char __user *name,= const void __user *value, return PTR_ERR(kvalue); } =20 @@ -47978,7 +49331,7 @@ diff -urNp linux-3.1.4/fs/xattr.c linux-3.1.4/fs/= xattr.c kfree(kvalue); return error; } -@@ -295,7 +301,7 @@ SYSCALL_DEFINE5(setxattr, const char __u +@@ -295,7 +301,7 @@ SYSCALL_DEFINE5(setxattr, const char __user *, pathn= ame, return error; error =3D mnt_want_write(path.mnt); if (!error) { @@ -47987,7 +49340,7 @@ diff -urNp linux-3.1.4/fs/xattr.c linux-3.1.4/fs/= xattr.c mnt_drop_write(path.mnt); } path_put(&path); -@@ -314,7 +320,7 @@ SYSCALL_DEFINE5(lsetxattr, const char __ +@@ -314,7 +320,7 @@ SYSCALL_DEFINE5(lsetxattr, const char __user *, path= name, return error; error =3D mnt_want_write(path.mnt); if (!error) { @@ -47996,7 +49349,7 @@ diff -urNp linux-3.1.4/fs/xattr.c linux-3.1.4/fs/= xattr.c mnt_drop_write(path.mnt); } path_put(&path); -@@ -325,17 +331,15 @@ SYSCALL_DEFINE5(fsetxattr, int, fd, cons +@@ -325,17 +331,15 @@ SYSCALL_DEFINE5(fsetxattr, int, fd, const char __u= ser *, name, const void __user *,value, size_t, size, int, flags) { struct file *f; @@ -48016,9 +49369,25 @@ diff -urNp linux-3.1.4/fs/xattr.c linux-3.1.4/fs= /xattr.c mnt_drop_write(f->f_path.mnt); } fput(f); -diff -urNp linux-3.1.4/fs/xfs/xfs_bmap.c linux-3.1.4/fs/xfs/xfs_bmap.c ---- linux-3.1.4/fs/xfs/xfs_bmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/xfs/xfs_bmap.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/xattr_acl.c b/fs/xattr_acl.c +index 8d5a506..7f62712 100644 +--- a/fs/xattr_acl.c ++++ b/fs/xattr_acl.c +@@ -17,8 +17,8 @@ + struct posix_acl * + posix_acl_from_xattr(const void *value, size_t size) + { +- posix_acl_xattr_header *header =3D (posix_acl_xattr_header *)value; +- posix_acl_xattr_entry *entry =3D (posix_acl_xattr_entry *)(header+1), = *end; ++ const posix_acl_xattr_header *header =3D (const posix_acl_xattr_header= *)value; ++ const posix_acl_xattr_entry *entry =3D (const posix_acl_xattr_entry *)= (header+1), *end; + int count; + struct posix_acl *acl; + struct posix_acl_entry *acl_e; +diff --git a/fs/xfs/xfs_bmap.c b/fs/xfs/xfs_bmap.c +index 452a291..91a95f3b 100644 +--- a/fs/xfs/xfs_bmap.c ++++ b/fs/xfs/xfs_bmap.c @@ -250,7 +250,7 @@ xfs_bmap_validate_ret( int nmap, int ret_nmap); @@ -48028,9 +49397,10 @@ diff -urNp linux-3.1.4/fs/xfs/xfs_bmap.c linux-3= .1.4/fs/xfs/xfs_bmap.c #endif /* DEBUG */ =20 STATIC int -diff -urNp linux-3.1.4/fs/xfs/xfs_dir2_sf.c linux-3.1.4/fs/xfs/xfs_dir2_= sf.c ---- linux-3.1.4/fs/xfs/xfs_dir2_sf.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/xfs/xfs_dir2_sf.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/xfs/xfs_dir2_sf.c b/fs/xfs/xfs_dir2_sf.c +index 79d05e8..e3e5861 100644 +--- a/fs/xfs/xfs_dir2_sf.c ++++ b/fs/xfs/xfs_dir2_sf.c @@ -852,7 +852,15 @@ xfs_dir2_sf_getdents( } =20 @@ -48048,9 +49418,10 @@ diff -urNp linux-3.1.4/fs/xfs/xfs_dir2_sf.c linu= x-3.1.4/fs/xfs/xfs_dir2_sf.c off & 0x7fffffff, ino, DT_UNKNOWN)) { *offset =3D off & 0x7fffffff; return 0; -diff -urNp linux-3.1.4/fs/xfs/xfs_ioctl.c linux-3.1.4/fs/xfs/xfs_ioctl.c ---- linux-3.1.4/fs/xfs/xfs_ioctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/xfs/xfs_ioctl.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/xfs/xfs_ioctl.c b/fs/xfs/xfs_ioctl.c +index f7ce7de..e1a5db0 100644 +--- a/fs/xfs/xfs_ioctl.c ++++ b/fs/xfs/xfs_ioctl.c @@ -128,7 +128,7 @@ xfs_find_handle( } =20 @@ -48060,9 +49431,10 @@ diff -urNp linux-3.1.4/fs/xfs/xfs_ioctl.c linux-= 3.1.4/fs/xfs/xfs_ioctl.c copy_to_user(hreq->ohandlen, &hsize, sizeof(__s32))) goto out_put; =20 -diff -urNp linux-3.1.4/fs/xfs/xfs_iops.c linux-3.1.4/fs/xfs/xfs_iops.c ---- linux-3.1.4/fs/xfs/xfs_iops.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/fs/xfs/xfs_iops.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/fs/xfs/xfs_iops.c b/fs/xfs/xfs_iops.c +index 673704f..74315c5 100644 +--- a/fs/xfs/xfs_iops.c ++++ b/fs/xfs/xfs_iops.c @@ -446,7 +446,7 @@ xfs_vn_put_link( struct nameidata *nd, void *p) @@ -48072,9 +49444,10 @@ diff -urNp linux-3.1.4/fs/xfs/xfs_iops.c linux-3= .1.4/fs/xfs/xfs_iops.c =20 if (!IS_ERR(s)) kfree(s); -diff -urNp linux-3.1.4/fs/xfs/xfs_vnodeops.c linux-3.1.4/fs/xfs/xfs_vnod= eops.c ---- linux-3.1.4/fs/xfs/xfs_vnodeops.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/fs/xfs/xfs_vnodeops.c 2011-11-18 18:54:56.000000000 -050= 0 +diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c +index 51fc429..a728e71 100644 +--- a/fs/xfs/xfs_vnodeops.c ++++ b/fs/xfs/xfs_vnodeops.c @@ -123,13 +123,17 @@ xfs_readlink( =20 xfs_ilock(ip, XFS_ILOCK_SHARED); @@ -48096,1603 +49469,2581 @@ diff -urNp linux-3.1.4/fs/xfs/xfs_vnodeops.= c linux-3.1.4/fs/xfs/xfs_vnodeops.c if (ip->i_df.if_flags & XFS_IFINLINE) { memcpy(link, ip->i_df.if_u1.if_data, pathlen); link[pathlen] =3D '\0'; -diff -urNp linux-3.1.4/grsecurity/gracl_alloc.c linux-3.1.4/grsecurity/g= racl_alloc.c ---- linux-3.1.4/grsecurity/gracl_alloc.c 1969-12-31 19:00:00.000000000 -= 0500 -+++ linux-3.1.4/grsecurity/gracl_alloc.c 2011-11-16 18:40:31.000000000 -= 0500 -@@ -0,0 +1,105 @@ -+#include -+#include -+#include -+#include -+#include -+#include -+ -+static unsigned long alloc_stack_next =3D 1; -+static unsigned long alloc_stack_size =3D 1; -+static void **alloc_stack; +diff --git a/grsecurity/Kconfig b/grsecurity/Kconfig +new file mode 100644 +index 0000000..9629731 +--- /dev/null ++++ b/grsecurity/Kconfig +@@ -0,0 +1,1037 @@ ++# ++# grecurity configuration ++# + -+static __inline__ int -+alloc_pop(void) -+{ -+ if (alloc_stack_next =3D=3D 1) -+ return 0; ++menu "Grsecurity" + -+ kfree(alloc_stack[alloc_stack_next - 2]); ++config GRKERNSEC ++ bool "Grsecurity" ++ select CRYPTO ++ select CRYPTO_SHA256 ++ help ++ If you say Y here, you will be able to configure many features ++ that will enhance the security of your system. It is highly ++ recommended that you say Y here and read through the help ++ for each option so that you fully understand the features and ++ can evaluate their usefulness for your machine. + -+ alloc_stack_next--; ++choice ++ prompt "Security Level" ++ depends on GRKERNSEC ++ default GRKERNSEC_CUSTOM + -+ return 1; -+} ++config GRKERNSEC_LOW ++ bool "Low" ++ select GRKERNSEC_LINK ++ select GRKERNSEC_FIFO ++ select GRKERNSEC_RANDNET ++ select GRKERNSEC_DMESG ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_CHDIR + -+static __inline__ int -+alloc_push(void *buf) -+{ -+ if (alloc_stack_next >=3D alloc_stack_size) -+ return 1; ++ help ++ If you choose this option, several of the grsecurity options will ++ be enabled that will give you greater protection against a number ++ of attacks, while assuring that none of your software will have any ++ conflicts with the additional security measures. If you run a lot ++ of unusual software, or you are having problems with the higher ++ security levels, you should say Y here. With this option, the ++ following features are enabled: + -+ alloc_stack[alloc_stack_next - 1] =3D buf; ++ - Linking restrictions ++ - FIFO restrictions ++ - Restricted dmesg ++ - Enforced chdir("/") on chroot ++ - Runtime module disabling + -+ alloc_stack_next++; ++config GRKERNSEC_MEDIUM ++ bool "Medium" ++ select PAX ++ select PAX_EI_PAX ++ select PAX_PT_PAX_FLAGS ++ select PAX_HAVE_ACL_FLAGS ++ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_SYSCTL ++ select GRKERNSEC_LINK ++ select GRKERNSEC_FIFO ++ select GRKERNSEC_DMESG ++ select GRKERNSEC_RANDNET ++ select GRKERNSEC_FORKFAIL ++ select GRKERNSEC_TIME ++ select GRKERNSEC_SIGNAL ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_UNIX ++ select GRKERNSEC_CHROOT_MOUNT ++ select GRKERNSEC_CHROOT_PIVOT ++ select GRKERNSEC_CHROOT_DOUBLE ++ select GRKERNSEC_CHROOT_CHDIR ++ select GRKERNSEC_CHROOT_MKNOD ++ select GRKERNSEC_PROC ++ select GRKERNSEC_PROC_USERGROUP ++ select PAX_RANDUSTACK ++ select PAX_ASLR ++ select PAX_RANDMMAP ++ select PAX_REFCOUNT if (X86 || SPARC64) ++ select PAX_USERCOPY if ((X86 || SPARC || PPC || ARM) && (SLAB || SLUB = || SLOB)) + -+ return 0; -+} ++ help ++ If you say Y here, several features in addition to those included ++ in the low additional security level will be enabled. These ++ features provide even more security to your system, though in rare ++ cases they may be incompatible with very old or poorly written ++ software. If you enable this option, make sure that your auth ++ service (identd) is running as gid 1001. With this option,=20 ++ the following features (in addition to those provided in the=20 ++ low additional security level) will be enabled: + -+void * -+acl_alloc(unsigned long len) -+{ -+ void *ret =3D NULL; ++ - Failed fork logging ++ - Time change logging ++ - Signal logging ++ - Deny mounts in chroot ++ - Deny double chrooting ++ - Deny sysctl writes in chroot ++ - Deny mknod in chroot ++ - Deny access to abstract AF_UNIX sockets out of chroot ++ - Deny pivot_root in chroot ++ - Denied reads/writes of /dev/kmem, /dev/mem, and /dev/port ++ - /proc restrictions with special GID set to 10 (usually wheel) ++ - Address Space Layout Randomization (ASLR) ++ - Prevent exploitation of most refcount overflows ++ - Bounds checking of copying between the kernel and userland + -+ if (!len || len > PAGE_SIZE) -+ goto out; ++config GRKERNSEC_HIGH ++ bool "High" ++ select GRKERNSEC_LINK ++ select GRKERNSEC_FIFO ++ select GRKERNSEC_DMESG ++ select GRKERNSEC_FORKFAIL ++ select GRKERNSEC_TIME ++ select GRKERNSEC_SIGNAL ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_SHMAT ++ select GRKERNSEC_CHROOT_UNIX ++ select GRKERNSEC_CHROOT_MOUNT ++ select GRKERNSEC_CHROOT_FCHDIR ++ select GRKERNSEC_CHROOT_PIVOT ++ select GRKERNSEC_CHROOT_DOUBLE ++ select GRKERNSEC_CHROOT_CHDIR ++ select GRKERNSEC_CHROOT_MKNOD ++ select GRKERNSEC_CHROOT_CAPS ++ select GRKERNSEC_CHROOT_SYSCTL ++ select GRKERNSEC_CHROOT_FINDTASK ++ select GRKERNSEC_SYSFS_RESTRICT ++ select GRKERNSEC_PROC ++ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) ++ select GRKERNSEC_HIDESYM ++ select GRKERNSEC_BRUTE ++ select GRKERNSEC_PROC_USERGROUP ++ select GRKERNSEC_KMEM ++ select GRKERNSEC_RESLOG ++ select GRKERNSEC_RANDNET ++ select GRKERNSEC_PROC_ADD ++ select GRKERNSEC_CHROOT_CHMOD ++ select GRKERNSEC_CHROOT_NICE ++ select GRKERNSEC_AUDIT_MOUNT ++ select GRKERNSEC_MODHARDEN if (MODULES) ++ select GRKERNSEC_HARDEN_PTRACE ++ select GRKERNSEC_VM86 if (X86_32) ++ select GRKERNSEC_KERN_LOCKOUT if (X86 || ARM || PPC || SPARC) ++ select PAX ++ select PAX_RANDUSTACK ++ select PAX_ASLR ++ select PAX_RANDMMAP ++ select PAX_NOEXEC ++ select PAX_MPROTECT ++ select PAX_EI_PAX ++ select PAX_PT_PAX_FLAGS ++ select PAX_HAVE_ACL_FLAGS ++ select PAX_KERNEXEC if ((PPC || X86) && (!X86_32 || X86_WP_WORKS_OK) &= & !XEN) ++ select PAX_MEMORY_UDEREF if (X86 && !XEN) ++ select PAX_RANDKSTACK if (X86_TSC && X86) ++ select PAX_SEGMEXEC if (X86_32) ++ select PAX_PAGEEXEC ++ select PAX_EMUPLT if (ALPHA || PARISC || SPARC) ++ select PAX_EMUTRAMP if (PARISC) ++ select PAX_EMUSIGRT if (PARISC) ++ select PAX_ETEXECRELOCS if (ALPHA || IA64 || PARISC) ++ select PAX_ELFRELOCS if (PAX_ETEXECRELOCS || (IA64 || PPC || X86)) ++ select PAX_REFCOUNT if (X86 || SPARC64) ++ select PAX_USERCOPY if ((X86 || PPC || SPARC || ARM) && (SLAB || SLUB = || SLOB)) ++ help ++ If you say Y here, many of the features of grsecurity will be ++ enabled, which will protect you against many kinds of attacks ++ against your system. The heightened security comes at a cost ++ of an increased chance of incompatibilities with rare software ++ on your machine. Since this security level enables PaX, you should ++ view and read about the PaX ++ project. While you are there, download chpax and run it on ++ binaries that cause problems with PaX. Also remember that ++ since the /proc restrictions are enabled, you must run your ++ identd as gid 1001. This security level enables the following=20 ++ features in addition to those listed in the low and medium=20 ++ security levels: + -+ ret =3D kmalloc(len, GFP_KERNEL); ++ - Additional /proc restrictions ++ - Chmod restrictions in chroot ++ - No signals, ptrace, or viewing of processes outside of chroot ++ - Capability restrictions in chroot ++ - Deny fchdir out of chroot ++ - Priority restrictions in chroot ++ - Segmentation-based implementation of PaX ++ - Mprotect restrictions ++ - Removal of addresses from /proc//[smaps|maps|stat] ++ - Kernel stack randomization ++ - Mount/unmount/remount logging ++ - Kernel symbol hiding ++ - Hardening of module auto-loading ++ - Ptrace restrictions ++ - Restricted vm86 mode ++ - Restricted sysfs/debugfs ++ - Active kernel exploit response + -+ if (ret) { -+ if (alloc_push(ret)) { -+ kfree(ret); -+ ret =3D NULL; -+ } -+ } ++config GRKERNSEC_CUSTOM ++ bool "Custom" ++ help ++ If you say Y here, you will be able to configure every grsecurity ++ option, which allows you to enable many more features that aren't ++ covered in the basic security levels. These additional features ++ include TPE, socket restrictions, and the sysctl system for ++ grsecurity. It is advised that you read through the help for ++ each option to determine its usefulness in your situation. + -+out: -+ return ret; -+} ++endchoice + -+void * -+acl_alloc_num(unsigned long num, unsigned long len) -+{ -+ if (!len || (num > (PAGE_SIZE / len))) -+ return NULL; ++menu "Address Space Protection" ++depends on GRKERNSEC + -+ return acl_alloc(num * len); -+} ++config GRKERNSEC_KMEM ++ bool "Deny reading/writing to /dev/kmem, /dev/mem, and /dev/port" ++ select STRICT_DEVMEM if (X86 || ARM || TILE || S390) ++ help ++ If you say Y here, /dev/kmem and /dev/mem won't be allowed to ++ be written to or read from to modify or leak the contents of the run= ning ++ kernel. /dev/port will also not be allowed to be opened. If you hav= e module ++ support disabled, enabling this will close up four ways that are ++ currently used to insert malicious code into the running kernel. ++ Even with all these features enabled, we still highly recommend that ++ you use the RBAC system, as it is still possible for an attacker to ++ modify the running kernel through privileged I/O granted by ioperm/i= opl. ++ If you are not using XFree86, you may be able to stop this additiona= l ++ case by enabling the 'Disable privileged I/O' option. Though nothing ++ legitimately writes to /dev/kmem, XFree86 does need to write to /dev= /mem, ++ but only to video memory, which is the only writing we allow in this ++ case. If /dev/kmem or /dev/mem are mmaped without PROT_WRITE, they = will ++ not be allowed to mprotect it with PROT_WRITE later. ++ It is highly recommended that you say Y here if you meet all the ++ conditions above. + -+void -+acl_free_all(void) -+{ -+ if (gr_acl_is_enabled() || !alloc_stack) -+ return; ++config GRKERNSEC_VM86 ++ bool "Restrict VM86 mode" ++ depends on X86_32 + -+ while (alloc_pop()) ; ++ help ++ If you say Y here, only processes with CAP_SYS_RAWIO will be able to ++ make use of a special execution mode on 32bit x86 processors called ++ Virtual 8086 (VM86) mode. XFree86 may need vm86 mode for certain ++ video cards and will still work with this option enabled. The purpo= se ++ of the option is to prevent exploitation of emulation errors in ++ virtualization of vm86 mode like the one discovered in VMWare in 200= 9. ++ Nearly all users should be able to enable this option. + -+ if (alloc_stack) { -+ if ((alloc_stack_size * sizeof (void *)) <=3D PAGE_SIZE) -+ kfree(alloc_stack); -+ else -+ vfree(alloc_stack); -+ } ++config GRKERNSEC_IO ++ bool "Disable privileged I/O" ++ depends on X86 ++ select RTC_CLASS ++ select RTC_INTF_DEV ++ select RTC_DRV_CMOS + -+ alloc_stack =3D NULL; -+ alloc_stack_size =3D 1; -+ alloc_stack_next =3D 1; ++ help ++ If you say Y here, all ioperm and iopl calls will return an error. ++ Ioperm and iopl can be used to modify the running kernel. ++ Unfortunately, some programs need this access to operate properly, ++ the most notable of which are XFree86 and hwclock. hwclock can be ++ remedied by having RTC support in the kernel, so real-time=20 ++ clock support is enabled if this option is enabled, to ensure=20 ++ that hwclock operates correctly. XFree86 still will not=20 ++ operate correctly with this option enabled, so DO NOT CHOOSE Y=20 ++ IF YOU USE XFree86. If you use XFree86 and you still want to=20 ++ protect your kernel against modification, use the RBAC system. + -+ return; -+} ++config GRKERNSEC_PROC_MEMMAP ++ bool "Remove addresses from /proc//[smaps|maps|stat]" ++ default y if (PAX_NOEXEC || PAX_ASLR) ++ depends on PAX_NOEXEC || PAX_ASLR ++ help ++ If you say Y here, the /proc//maps and /proc//stat files w= ill ++ give no information about the addresses of its mappings if ++ PaX features that rely on random addresses are enabled on the task. ++ If you use PaX it is greatly recommended that you say Y here as it ++ closes up a hole that makes the full ASLR useless for suid ++ binaries. + -+int -+acl_alloc_stack_init(unsigned long size) -+{ -+ if ((size * sizeof (void *)) <=3D PAGE_SIZE) -+ alloc_stack =3D -+ (void **) kmalloc(size * sizeof (void *), GFP_KERNEL); -+ else -+ alloc_stack =3D (void **) vmalloc(size * sizeof (void *)); ++config GRKERNSEC_BRUTE ++ bool "Deter exploit bruteforcing" ++ help ++ If you say Y here, attempts to bruteforce exploits against forking ++ daemons such as apache or sshd, as well as against suid/sgid binarie= s ++ will be deterred. When a child of a forking daemon is killed by PaX ++ or crashes due to an illegal instruction or other suspicious signal, ++ the parent process will be delayed 30 seconds upon every subsequent ++ fork until the administrator is able to assess the situation and ++ restart the daemon. ++ In the suid/sgid case, the attempt is logged, the user has all their ++ processes terminated, and they are prevented from executing any furt= her ++ processes for 15 minutes. ++ It is recommended that you also enable signal logging in the auditin= g ++ section so that logs are generated when a process triggers a suspici= ous ++ signal. ++ If the sysctl option is enabled, a sysctl option with name ++ "deter_bruteforce" is created. + -+ alloc_stack_size =3D size; + -+ if (!alloc_stack) -+ return 0; -+ else -+ return 1; -+} -diff -urNp linux-3.1.4/grsecurity/gracl.c linux-3.1.4/grsecurity/gracl.c ---- linux-3.1.4/grsecurity/gracl.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.1.4/grsecurity/gracl.c 2011-11-16 19:31:00.000000000 -0500 -@@ -0,0 +1,4156 @@ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include ++config GRKERNSEC_MODHARDEN ++ bool "Harden module auto-loading" ++ depends on MODULES ++ help ++ If you say Y here, module auto-loading in response to use of some ++ feature implemented by an unloaded module will be restricted to ++ root users. Enabling this option helps defend against attacks=20 ++ by unprivileged users who abuse the auto-loading behavior to=20 ++ cause a vulnerable module to load that is then exploited. + -+#include -+#include -+#include ++ If this option prevents a legitimate use of auto-loading for a=20 ++ non-root user, the administrator can execute modprobe manually=20 ++ with the exact name of the module mentioned in the alert log. ++ Alternatively, the administrator can add the module to the list ++ of modules loaded at boot by modifying init scripts. + -+static struct acl_role_db acl_role_set; -+static struct name_db name_set; -+static struct inodev_db inodev_set; ++ Modification of init scripts will most likely be needed on=20 ++ Ubuntu servers with encrypted home directory support enabled, ++ as the first non-root user logging in will cause the ecb(aes), ++ ecb(aes)-all, cbc(aes), and cbc(aes)-all modules to be loaded. + -+/* for keeping track of userspace pointers used for subjects, so we -+ can share references in the kernel as well -+*/ ++config GRKERNSEC_HIDESYM ++ bool "Hide kernel symbols" ++ help ++ If you say Y here, getting information on loaded modules, and ++ displaying all kernel symbols through a syscall will be restricted ++ to users with CAP_SYS_MODULE. For software compatibility reasons, ++ /proc/kallsyms will be restricted to the root user. The RBAC ++ system can hide that entry even from root. + -+static struct path real_root; ++ This option also prevents leaking of kernel addresses through ++ several /proc entries. + -+static struct acl_subj_map_db subj_map_set; ++ Note that this option is only effective provided the following ++ conditions are met: ++ 1) The kernel using grsecurity is not precompiled by some distributi= on ++ 2) You have also enabled GRKERNSEC_DMESG ++ 3) You are using the RBAC system and hiding other files such as your ++ kernel image and System.map. Alternatively, enabling this option ++ causes the permissions on /boot, /lib/modules, and the kernel ++ source directory to change at compile time to prevent=20 ++ reading by non-root users. ++ If the above conditions are met, this option will aid in providing a ++ useful protection against local kernel exploitation of overflows ++ and arbitrary read/write vulnerabilities. + -+static struct acl_role_label *default_role; -+ -+static struct acl_role_label *role_list; -+ -+static u16 acl_sp_role_value; ++config GRKERNSEC_KERN_LOCKOUT ++ bool "Active kernel exploit response" ++ depends on X86 || ARM || PPC || SPARC ++ help ++ If you say Y here, when a PaX alert is triggered due to suspicious ++ activity in the kernel (from KERNEXEC/UDEREF/USERCOPY) ++ or an OOPs occurs due to bad memory accesses, instead of just ++ terminating the offending process (and potentially allowing ++ a subsequent exploit from the same user), we will take one of two ++ actions: ++ If the user was root, we will panic the system ++ If the user was non-root, we will log the attempt, terminate ++ all processes owned by the user, then prevent them from creating ++ any new processes until the system is restarted ++ This deters repeated kernel exploitation/bruteforcing attempts ++ and is useful for later forensics. + -+extern char *gr_shared_page[4]; -+static DEFINE_MUTEX(gr_dev_mutex); -+DEFINE_RWLOCK(gr_inode_lock); ++endmenu ++menu "Role Based Access Control Options" ++depends on GRKERNSEC + -+struct gr_arg *gr_usermode; ++config GRKERNSEC_RBAC_DEBUG ++ bool + -+static unsigned int gr_status __read_only =3D GR_STATUS_INIT; ++config GRKERNSEC_NO_RBAC ++ bool "Disable RBAC system" ++ help ++ If you say Y here, the /dev/grsec device will be removed from the ke= rnel, ++ preventing the RBAC system from being enabled. You should only say = Y ++ here if you have no intention of using the RBAC system, so as to pre= vent ++ an attacker with root access from misusing the RBAC system to hide f= iles ++ and processes when loadable module support and /dev/[k]mem have been ++ locked down. + -+extern int chkpw(struct gr_arg *entry, unsigned char *salt, unsigned ch= ar *sum); -+extern void gr_clear_learn_entries(void); ++config GRKERNSEC_ACL_HIDEKERN ++ bool "Hide kernel processes" ++ help ++ If you say Y here, all kernel threads will be hidden to all ++ processes but those whose subject has the "view hidden processes" ++ flag. + -+#ifdef CONFIG_GRKERNSEC_RESLOG -+extern void gr_log_resource(const struct task_struct *task, -+ const int res, const unsigned long wanted, const int gt); -+#endif ++config GRKERNSEC_ACL_MAXTRIES ++ int "Maximum tries before password lockout" ++ default 3 ++ help ++ This option enforces the maximum number of times a user can attempt ++ to authorize themselves with the grsecurity RBAC system before being ++ denied the ability to attempt authorization again for a specified ti= me. ++ The lower the number, the harder it will be to brute-force a passwor= d. + -+unsigned char *gr_system_salt; -+unsigned char *gr_system_sum; ++config GRKERNSEC_ACL_TIMEOUT ++ int "Time to wait after max password tries, in seconds" ++ default 30 ++ help ++ This option specifies the time the user must wait after attempting t= o ++ authorize to the RBAC system with the maximum number of invalid ++ passwords. The higher the number, the harder it will be to brute-fo= rce ++ a password. + -+static struct sprole_pw **acl_special_roles =3D NULL; -+static __u16 num_sprole_pws =3D 0; ++endmenu ++menu "Filesystem Protections" ++depends on GRKERNSEC + -+static struct acl_role_label *kernel_role =3D NULL; ++config GRKERNSEC_PROC ++ bool "Proc restrictions" ++ help ++ If you say Y here, the permissions of the /proc filesystem ++ will be altered to enhance system security and privacy. You MUST ++ choose either a user only restriction or a user and group restrict= ion. ++ Depending upon the option you choose, you can either restrict users = to ++ see only the processes they themselves run, or choose a group that c= an ++ view all processes and files normally restricted to root if you choo= se ++ the "restrict to user only" option. NOTE: If you're running identd = as ++ a non-root user, you will have to run it as the group you specify he= re. + -+static unsigned int gr_auth_attempts =3D 0; -+static unsigned long gr_auth_expires =3D 0UL; ++config GRKERNSEC_PROC_USER ++ bool "Restrict /proc to user only" ++ depends on GRKERNSEC_PROC ++ help ++ If you say Y here, non-root users will only be able to view their ow= n ++ processes, and restricts them from viewing network-related informati= on, ++ and viewing kernel symbol and module information. + -+#ifdef CONFIG_NET -+extern struct vfsmount *sock_mnt; -+#endif ++config GRKERNSEC_PROC_USERGROUP ++ bool "Allow special group" ++ depends on GRKERNSEC_PROC && !GRKERNSEC_PROC_USER ++ help ++ If you say Y here, you will be able to select a group that will be ++ able to view all processes and network-related information. = If you've ++ enabled GRKERNSEC_HIDESYM, kernel and symbol information may = still ++ remain hidden. This option is useful if you want to run iden= td as ++ a non-root user. + -+extern struct vfsmount *pipe_mnt; -+extern struct vfsmount *shm_mnt; -+#ifdef CONFIG_HUGETLBFS -+extern struct vfsmount *hugetlbfs_vfsmount; -+#endif ++config GRKERNSEC_PROC_GID ++ int "GID for special group" ++ depends on GRKERNSEC_PROC_USERGROUP ++ default 1001 + -+static struct acl_object_label *fakefs_obj_rw; -+static struct acl_object_label *fakefs_obj_rwx; ++config GRKERNSEC_PROC_ADD ++ bool "Additional restrictions" ++ depends on GRKERNSEC_PROC_USER || GRKERNSEC_PROC_USERGROUP ++ help ++ If you say Y here, additional restrictions will be placed on ++ /proc that keep normal users from viewing device information and=20 ++ slabinfo information that could be useful for exploits. + -+extern int gr_init_uidset(void); -+extern void gr_free_uidset(void); -+extern void gr_remove_uid(uid_t uid); -+extern int gr_find_uid(uid_t uid); ++config GRKERNSEC_LINK ++ bool "Linking restrictions" ++ help ++ If you say Y here, /tmp race exploits will be prevented, since users ++ will no longer be able to follow symlinks owned by other users in ++ world-writable +t directories (e.g. /tmp), unless the owner of the ++ symlink is the owner of the directory. users will also not be ++ able to hardlink to files they do not own. If the sysctl option is ++ enabled, a sysctl option with name "linking_restrictions" is created= . + -+DECLARE_BRLOCK(vfsmount_lock); ++config GRKERNSEC_FIFO ++ bool "FIFO restrictions" ++ help ++ If you say Y here, users will not be able to write to FIFOs they don= 't ++ own in world-writable +t directories (e.g. /tmp), unless the owner o= f ++ the FIFO is the same owner of the directory it's held in. If the sy= sctl ++ option is enabled, a sysctl option with name "fifo_restrictions" is ++ created. + -+__inline__ int -+gr_acl_is_enabled(void) -+{ -+ return (gr_status & GR_READY); -+} ++config GRKERNSEC_SYSFS_RESTRICT ++ bool "Sysfs/debugfs restriction" ++ depends on SYSFS ++ help ++ If you say Y here, sysfs (the pseudo-filesystem mounted at /sys) and ++ any filesystem normally mounted under it (e.g. debugfs) will only ++ be accessible by root. These filesystems generally provide access ++ to hardware and debug information that isn't appropriate for unprivi= leged ++ users of the system. Sysfs and debugfs have also become a large sou= rce ++ of new vulnerabilities, ranging from infoleaks to local compromise. ++ There has been very little oversight with an eye toward security inv= olved ++ in adding new exporters of information to these filesystems, so thei= r ++ use is discouraged. ++ This option is equivalent to a chmod 0700 of the mount paths. + -+#ifdef CONFIG_BTRFS_FS -+extern dev_t get_btrfs_dev_from_inode(struct inode *inode); -+extern int btrfs_getattr(struct vfsmount *mnt, struct dentry *dentry, s= truct kstat *stat); -+#endif ++config GRKERNSEC_ROFS ++ bool "Runtime read-only mount protection" ++ help ++ If you say Y here, a sysctl option with name "romount_protect" will ++ be created. By setting this option to 1 at runtime, filesystems ++ will be protected in the following ways: ++ * No new writable mounts will be allowed ++ * Existing read-only mounts won't be able to be remounted read/write ++ * Write operations will be denied on all block devices ++ This option acts independently of grsec_lock: once it is set to 1, ++ it cannot be turned off. Therefore, please be mindful of the result= ing ++ behavior if this option is enabled in an init script on a read-only ++ filesystem. This feature is mainly intended for secure embedded sys= tems. + -+static inline dev_t __get_dev(const struct dentry *dentry) -+{ -+#ifdef CONFIG_BTRFS_FS -+ if (dentry->d_inode->i_op && dentry->d_inode->i_op->getattr =3D=3D &bt= rfs_getattr) -+ return get_btrfs_dev_from_inode(dentry->d_inode); -+ else -+#endif -+ return dentry->d_inode->i_sb->s_dev; -+} ++config GRKERNSEC_CHROOT ++ bool "Chroot jail restrictions" ++ help ++ If you say Y here, you will be able to choose several options that w= ill ++ make breaking out of a chrooted jail much more difficult. If you ++ encounter no software incompatibilities with the following options, = it ++ is recommended that you enable each one. + -+dev_t gr_get_dev_from_dentry(struct dentry *dentry) -+{ -+ return __get_dev(dentry); -+} ++config GRKERNSEC_CHROOT_MOUNT ++ bool "Deny mounts" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to ++ mount or remount filesystems. If the sysctl option is enabled, a ++ sysctl option with name "chroot_deny_mount" is created. + -+static char gr_task_roletype_to_char(struct task_struct *task) -+{ -+ switch (task->role->roletype & -+ (GR_ROLE_DEFAULT | GR_ROLE_USER | GR_ROLE_GROUP | -+ GR_ROLE_SPECIAL)) { -+ case GR_ROLE_DEFAULT: -+ return 'D'; -+ case GR_ROLE_USER: -+ return 'U'; -+ case GR_ROLE_GROUP: -+ return 'G'; -+ case GR_ROLE_SPECIAL: -+ return 'S'; -+ } ++config GRKERNSEC_CHROOT_DOUBLE ++ bool "Deny double-chroots" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to chr= oot ++ again outside the chroot. This is a widely used method of breaking ++ out of a chroot jail and should not be allowed. If the sysctl=20 ++ option is enabled, a sysctl option with name=20 ++ "chroot_deny_chroot" is created. + -+ return 'X'; -+} ++config GRKERNSEC_CHROOT_PIVOT ++ bool "Deny pivot_root in chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to use ++ a function called pivot_root() that was introduced in Linux 2.3.41. = It ++ works similar to chroot in that it changes the root filesystem. Thi= s ++ function could be misused in a chrooted process to attempt to break = out ++ of the chroot, and therefore should not be allowed. If the sysctl ++ option is enabled, a sysctl option with name "chroot_deny_pivot" is ++ created. + -+char gr_roletype_to_char(void) -+{ -+ return gr_task_roletype_to_char(current); -+} ++config GRKERNSEC_CHROOT_CHDIR ++ bool "Enforce chdir(\"/\") on all chroots" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, the current working directory of all newly-chroot= ed ++ applications will be set to the the root directory of the chroot. ++ The man page on chroot(2) states: ++ Note that this call does not change the current working ++ directory, so that `.' can be outside the tree rooted at ++ `/'. In particular, the super-user can escape from a ++ `chroot jail' by doing `mkdir foo; chroot foo; cd ..'. + -+__inline__ int -+gr_acl_tpe_check(void) -+{ -+ if (unlikely(!(gr_status & GR_READY))) -+ return 0; -+ if (current->role->roletype & GR_ROLE_TPE) -+ return 1; -+ else -+ return 0; -+} ++ It is recommended that you say Y here, since it's not known to break ++ any software. If the sysctl option is enabled, a sysctl option with ++ name "chroot_enforce_chdir" is created. + -+int -+gr_handle_rawio(const struct inode *inode) -+{ -+#ifdef CONFIG_GRKERNSEC_CHROOT_CAPS -+ if (inode && S_ISBLK(inode->i_mode) && -+ grsec_enable_chroot_caps && proc_is_chrooted(current) && -+ !capable(CAP_SYS_RAWIO)) -+ return 1; -+#endif -+ return 0; -+} ++config GRKERNSEC_CHROOT_CHMOD ++ bool "Deny (f)chmod +s" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to chm= od ++ or fchmod files to make them have suid or sgid bits. This protects ++ against another published method of breaking a chroot. If the sysct= l ++ option is enabled, a sysctl option with name "chroot_deny_chmod" is ++ created. + -+static int -+gr_streq(const char *a, const char *b, const unsigned int lena, const u= nsigned int lenb) -+{ -+ if (likely(lena !=3D lenb)) -+ return 0; ++config GRKERNSEC_CHROOT_FCHDIR ++ bool "Deny fchdir out of chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, a well-known method of breaking chroots by fchdir= 'ing ++ to a file descriptor of the chrooting process that points to a direc= tory ++ outside the filesystem will be stopped. If the sysctl option ++ is enabled, a sysctl option with name "chroot_deny_fchdir" is create= d. + -+ return !memcmp(a, b, lena); -+} ++config GRKERNSEC_CHROOT_MKNOD ++ bool "Deny mknod" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be allowed to ++ mknod. The problem with using mknod inside a chroot is that it ++ would allow an attacker to create a device entry that is the same ++ as one on the physical root of your system, which could range from ++ anything from the console device to a device for your harddrive (whi= ch ++ they could then use to wipe the drive or steal data). It is recomme= nded ++ that you say Y here, unless you run into software incompatibilities. ++ If the sysctl option is enabled, a sysctl option with name ++ "chroot_deny_mknod" is created. + -+static int prepend(char **buffer, int *buflen, const char *str, int nam= elen) -+{ -+ *buflen -=3D namelen; -+ if (*buflen < 0) -+ return -ENAMETOOLONG; -+ *buffer -=3D namelen; -+ memcpy(*buffer, str, namelen); -+ return 0; -+} ++config GRKERNSEC_CHROOT_SHMAT ++ bool "Deny shmat() out of chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to att= ach ++ to shared memory segments that were created outside of the chroot ja= il. ++ It is recommended that you say Y here. If the sysctl option is enab= led, ++ a sysctl option with name "chroot_deny_shmat" is created. + -+static int prepend_name(char **buffer, int *buflen, struct qstr *name) -+{ -+ return prepend(buffer, buflen, name->name, name->len); -+} ++config GRKERNSEC_CHROOT_UNIX ++ bool "Deny access to abstract AF_UNIX sockets out of chroot" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to ++ connect to abstract (meaning not belonging to a filesystem) Unix ++ domain sockets that were bound outside of a chroot. It is recommend= ed ++ that you say Y here. If the sysctl option is enabled, a sysctl opti= on ++ with name "chroot_deny_unix" is created. + -+static int prepend_path(const struct path *path, struct path *root, -+ char **buffer, int *buflen) -+{ -+ struct dentry *dentry =3D path->dentry; -+ struct vfsmount *vfsmnt =3D path->mnt; -+ bool slash =3D false; -+ int error =3D 0; ++config GRKERNSEC_CHROOT_FINDTASK ++ bool "Protect outside processes" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to ++ kill, send signals with fcntl, ptrace, capget, getpgid, setpgid,=20 ++ getsid, or view any process outside of the chroot. If the sysctl ++ option is enabled, a sysctl option with name "chroot_findtask" is ++ created. + -+ while (dentry !=3D root->dentry || vfsmnt !=3D root->mnt) { -+ struct dentry * parent; ++config GRKERNSEC_CHROOT_NICE ++ bool "Restrict priority changes" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, processes inside a chroot will not be able to rai= se ++ the priority of processes in the chroot, or alter the priority of ++ processes outside the chroot. This provides more security than simp= ly ++ removing CAP_SYS_NICE from the process' capability set. If the ++ sysctl option is enabled, a sysctl option with name "chroot_restrict= _nice" ++ is created. + -+ if (dentry =3D=3D vfsmnt->mnt_root || IS_ROOT(dentry)) { -+ /* Global root? */ -+ if (vfsmnt->mnt_parent =3D=3D vfsmnt) { -+ goto out; -+ } -+ dentry =3D vfsmnt->mnt_mountpoint; -+ vfsmnt =3D vfsmnt->mnt_parent; -+ continue; -+ } -+ parent =3D dentry->d_parent; -+ prefetch(parent); -+ spin_lock(&dentry->d_lock); -+ error =3D prepend_name(buffer, buflen, &dentry->d_name); -+ spin_unlock(&dentry->d_lock); -+ if (!error) -+ error =3D prepend(buffer, buflen, "/", 1); -+ if (error) -+ break; ++config GRKERNSEC_CHROOT_SYSCTL ++ bool "Deny sysctl writes" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, an attacker in a chroot will not be able to ++ write to sysctl entries, either by sysctl(2) or through a /proc ++ interface. It is strongly recommended that you say Y here. If the ++ sysctl option is enabled, a sysctl option with name ++ "chroot_deny_sysctl" is created. + -+ slash =3D true; -+ dentry =3D parent; -+ } ++config GRKERNSEC_CHROOT_CAPS ++ bool "Capability restrictions" ++ depends on GRKERNSEC_CHROOT ++ help ++ If you say Y here, the capabilities on all processes within a ++ chroot jail will be lowered to stop module insertion, raw i/o, ++ system and net admin tasks, rebooting the system, modifying immutabl= e ++ files, modifying IPC owned by another, and changing the system time. ++ This is left an option because it can break some apps. Disable this ++ if your chrooted apps are having problems performing those kinds of ++ tasks. If the sysctl option is enabled, a sysctl option with ++ name "chroot_caps" is created. + -+out: -+ if (!error && !slash) -+ error =3D prepend(buffer, buflen, "/", 1); ++endmenu ++menu "Kernel Auditing" ++depends on GRKERNSEC + -+ return error; -+} ++config GRKERNSEC_AUDIT_GROUP ++ bool "Single group for auditing" ++ help ++ If you say Y here, the exec, chdir, and (un)mount logging features ++ will only operate on a group you specify. This option is recommende= d ++ if you only want to watch certain users instead of having a large ++ amount of logs from the entire system. If the sysctl option is enab= led, ++ a sysctl option with name "audit_group" is created. + -+/* this must be called with vfsmount_lock and rename_lock held */ ++config GRKERNSEC_AUDIT_GID ++ int "GID for auditing" ++ depends on GRKERNSEC_AUDIT_GROUP ++ default 1007 + -+static char *__our_d_path(const struct path *path, struct path *root, -+ char *buf, int buflen) -+{ -+ char *res =3D buf + buflen; -+ int error; ++config GRKERNSEC_EXECLOG ++ bool "Exec logging" ++ help ++ If you say Y here, all execve() calls will be logged (since the ++ other exec*() calls are frontends to execve(), all execution ++ will be logged). Useful for shell-servers that like to keep track ++ of their users. If the sysctl option is enabled, a sysctl option wi= th ++ name "exec_logging" is created. ++ WARNING: This option when enabled will produce a LOT of logs, especi= ally ++ on an active system. + -+ prepend(&res, &buflen, "\0", 1); -+ error =3D prepend_path(path, root, &res, &buflen); -+ if (error) -+ return ERR_PTR(error); ++config GRKERNSEC_RESLOG ++ bool "Resource logging" ++ help ++ If you say Y here, all attempts to overstep resource limits will ++ be logged with the resource name, the requested size, and the curren= t ++ limit. It is highly recommended that you say Y here. If the sysctl ++ option is enabled, a sysctl option with name "resource_logging" is ++ created. If the RBAC system is enabled, the sysctl value is ignored= . + -+ return res; -+} ++config GRKERNSEC_CHROOT_EXECLOG ++ bool "Log execs within chroot" ++ help ++ If you say Y here, all executions inside a chroot jail will be logge= d ++ to syslog. This can cause a large amount of logs if certain ++ applications (eg. djb's daemontools) are installed on the system, an= d ++ is therefore left as an option. If the sysctl option is enabled, a ++ sysctl option with name "chroot_execlog" is created. + -+static char * -+gen_full_path(struct path *path, struct path *root, char *buf, int bufl= en) -+{ -+ char *retval; ++config GRKERNSEC_AUDIT_PTRACE ++ bool "Ptrace logging" ++ help ++ If you say Y here, all attempts to attach to a process via ptrace ++ will be logged. If the sysctl option is enabled, a sysctl option ++ with name "audit_ptrace" is created. + -+ retval =3D __our_d_path(path, root, buf, buflen); -+ if (unlikely(IS_ERR(retval))) -+ retval =3D strcpy(buf, ""); -+ else if (unlikely(retval[1] =3D=3D '/' && retval[2] =3D=3D '\0')) -+ retval[1] =3D '\0'; ++config GRKERNSEC_AUDIT_CHDIR ++ bool "Chdir logging" ++ help ++ If you say Y here, all chdir() calls will be logged. If the sysctl ++ option is enabled, a sysctl option with name "audit_chdir" is creat= ed. + -+ return retval; -+} ++config GRKERNSEC_AUDIT_MOUNT ++ bool "(Un)Mount logging" ++ help ++ If you say Y here, all mounts and unmounts will be logged. If the ++ sysctl option is enabled, a sysctl option with name "audit_mount" is ++ created. + -+static char * -+__d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmn= t, -+ char *buf, int buflen) -+{ -+ struct path path; -+ char *res; -+ -+ path.dentry =3D (struct dentry *)dentry; -+ path.mnt =3D (struct vfsmount *)vfsmnt; ++config GRKERNSEC_SIGNAL ++ bool "Signal logging" ++ help ++ If you say Y here, certain important signals will be logged, such as ++ SIGSEGV, which will as a result inform you of when a error in a prog= ram ++ occurred, which in some cases could mean a possible exploit attempt. ++ If the sysctl option is enabled, a sysctl option with name ++ "signal_logging" is created. + -+ /* we can use real_root.dentry, real_root.mnt, because this is only ca= lled -+ by the RBAC system */ -+ res =3D gen_full_path(&path, &real_root, buf, buflen); ++config GRKERNSEC_FORKFAIL ++ bool "Fork failure logging" ++ help ++ If you say Y here, all failed fork() attempts will be logged. ++ This could suggest a fork bomb, or someone attempting to overstep ++ their process limit. If the sysctl option is enabled, a sysctl opti= on ++ with name "forkfail_logging" is created. + -+ return res; -+} ++config GRKERNSEC_TIME ++ bool "Time change logging" ++ help ++ If you say Y here, any changes of the system clock will be logged. ++ If the sysctl option is enabled, a sysctl option with name ++ "timechange_logging" is created. + -+static char * -+d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmnt, -+ char *buf, int buflen) -+{ -+ char *res; -+ struct path path; -+ struct path root; -+ struct task_struct *reaper =3D &init_task; ++config GRKERNSEC_PROC_IPADDR ++ bool "/proc//ipaddr support" ++ help ++ If you say Y here, a new entry will be added to each /proc/ ++ directory that contains the IP address of the person using the task. ++ The IP is carried across local TCP and AF_UNIX stream sockets. ++ This information can be useful for IDS/IPSes to perform remote respo= nse ++ to a local attack. The entry is readable by only the owner of the ++ process (and root if he has CAP_DAC_OVERRIDE, which can be removed v= ia ++ the RBAC system), and thus does not create privacy concerns. + -+ path.dentry =3D (struct dentry *)dentry; -+ path.mnt =3D (struct vfsmount *)vfsmnt; ++config GRKERNSEC_RWXMAP_LOG ++ bool 'Denied RWX mmap/mprotect logging' ++ depends on PAX_MPROTECT && !PAX_EMUPLT && !PAX_EMUSIGRT ++ help ++ If you say Y here, calls to mmap() and mprotect() with explicit ++ usage of PROT_WRITE and PROT_EXEC together will be logged when ++ denied by the PAX_MPROTECT feature. If the sysctl option is ++ enabled, a sysctl option with name "rwxmap_logging" is created. + -+ /* we can't use real_root.dentry, real_root.mnt, because they belong o= nly to the RBAC system */ -+ get_fs_root(reaper->fs, &root); ++config GRKERNSEC_AUDIT_TEXTREL ++ bool 'ELF text relocations logging (READ HELP)' ++ depends on PAX_MPROTECT ++ help ++ If you say Y here, text relocations will be logged with the filename ++ of the offending library or binary. The purpose of the feature is ++ to help Linux distribution developers get rid of libraries and ++ binaries that need text relocations which hinder the future progress ++ of PaX. Only Linux distribution developers should say Y here, and ++ never on a production machine, as this option creates an information ++ leak that could aid an attacker in defeating the randomization of ++ a single memory region. If the sysctl option is enabled, a sysctl ++ option with name "audit_textrel" is created. + -+ write_seqlock(&rename_lock); -+ br_read_lock(vfsmount_lock); -+ res =3D gen_full_path(&path, &root, buf, buflen); -+ br_read_unlock(vfsmount_lock); -+ write_sequnlock(&rename_lock); ++endmenu + -+ path_put(&root); -+ return res; -+} ++menu "Executable Protections" ++depends on GRKERNSEC + -+static char * -+gr_to_filename_rbac(const struct dentry *dentry, const struct vfsmount = *mnt) -+{ -+ char *ret; -+ write_seqlock(&rename_lock); -+ br_read_lock(vfsmount_lock); -+ ret =3D __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_p= rocessor_id()), -+ PAGE_SIZE); -+ br_read_unlock(vfsmount_lock); -+ write_sequnlock(&rename_lock); -+ return ret; -+} ++config GRKERNSEC_DMESG ++ bool "Dmesg(8) restriction" ++ help ++ If you say Y here, non-root users will not be able to use dmesg(8) ++ to view up to the last 4kb of messages in the kernel's log buffer. ++ The kernel's log buffer often contains kernel addresses and other ++ identifying information useful to an attacker in fingerprinting a ++ system for a targeted exploit. ++ If the sysctl option is enabled, a sysctl option with name "dmesg" i= s ++ created. + -+static char * -+gr_to_proc_filename_rbac(const struct dentry *dentry, const struct vfsm= ount *mnt) -+{ -+ char *ret; -+ char *buf; -+ int buflen; ++config GRKERNSEC_HARDEN_PTRACE ++ bool "Deter ptrace-based process snooping" ++ help ++ If you say Y here, TTY sniffers and other malicious monitoring ++ programs implemented through ptrace will be defeated. If you ++ have been using the RBAC system, this option has already been ++ enabled for several years for all users, with the ability to make ++ fine-grained exceptions. + -+ write_seqlock(&rename_lock); -+ br_read_lock(vfsmount_lock); -+ buf =3D per_cpu_ptr(gr_shared_page[0], smp_processor_id()); -+ ret =3D __d_real_path(dentry, mnt, buf, PAGE_SIZE - 6); -+ buflen =3D (int)(ret - buf); -+ if (buflen >=3D 5) -+ prepend(&ret, &buflen, "/proc", 5); -+ else -+ ret =3D strcpy(buf, ""); -+ br_read_unlock(vfsmount_lock); -+ write_sequnlock(&rename_lock); -+ return ret; -+} ++ This option only affects the ability of non-root users to ptrace ++ processes that are not a descendent of the ptracing process. ++ This means that strace ./binary and gdb ./binary will still work, ++ but attaching to arbitrary processes will not. If the sysctl ++ option is enabled, a sysctl option with name "harden_ptrace" is ++ created. + -+char * -+gr_to_filename_nolock(const struct dentry *dentry, const struct vfsmoun= t *mnt) -+{ -+ return __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_pr= ocessor_id()), -+ PAGE_SIZE); -+} ++config GRKERNSEC_TPE ++ bool "Trusted Path Execution (TPE)" ++ help ++ If you say Y here, you will be able to choose a gid to add to the ++ supplementary groups of users you want to mark as "untrusted." ++ These users will not be able to execute any files that are not in ++ root-owned directories writable only by root. If the sysctl option ++ is enabled, a sysctl option with name "tpe" is created. + -+char * -+gr_to_filename(const struct dentry *dentry, const struct vfsmount *mnt) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++config GRKERNSEC_TPE_ALL ++ bool "Partially restrict all non-root users" ++ depends on GRKERNSEC_TPE ++ help ++ If you say Y here, all non-root users will be covered under ++ a weaker TPE restriction. This is separate from, and in addition to= , ++ the main TPE options that you have selected elsewhere. Thus, if a ++ "trusted" GID is chosen, this restriction applies to even that GID. ++ Under this restriction, all non-root users will only be allowed to ++ execute files in directories they own that are not group or ++ world-writable, or in directories owned by root and writable only by ++ root. If the sysctl option is enabled, a sysctl option with name ++ "tpe_restrict_all" is created. + -+char * -+gr_to_filename1(const struct dentry *dentry, const struct vfsmount *mnt= ) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[1], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++config GRKERNSEC_TPE_INVERT ++ bool "Invert GID option" ++ depends on GRKERNSEC_TPE ++ help ++ If you say Y here, the group you specify in the TPE configuration wi= ll ++ decide what group TPE restrictions will be *disabled* for. This ++ option is useful if you want TPE restrictions to be applied to most ++ users on the system. If the sysctl option is enabled, a sysctl opti= on ++ with name "tpe_invert" is created. Unlike other sysctl options, thi= s ++ entry will default to on for backward-compatibility. + -+char * -+gr_to_filename2(const struct dentry *dentry, const struct vfsmount *mnt= ) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[2], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++config GRKERNSEC_TPE_GID ++ int "GID for untrusted users" ++ depends on GRKERNSEC_TPE && !GRKERNSEC_TPE_INVERT ++ default 1005 ++ help ++ Setting this GID determines what group TPE restrictions will be ++ *enabled* for. If the sysctl option is enabled, a sysctl option ++ with name "tpe_gid" is created. + -+char * -+gr_to_filename3(const struct dentry *dentry, const struct vfsmount *mnt= ) -+{ -+ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[3], smp_pro= cessor_id()), -+ PAGE_SIZE); -+} ++config GRKERNSEC_TPE_GID ++ int "GID for trusted users" ++ depends on GRKERNSEC_TPE && GRKERNSEC_TPE_INVERT ++ default 1005 ++ help ++ Setting this GID determines what group TPE restrictions will be ++ *disabled* for. If the sysctl option is enabled, a sysctl option ++ with name "tpe_gid" is created. + -+__inline__ __u32 -+to_gr_audit(const __u32 reqmode) -+{ -+ /* masks off auditable permission flags, then shifts them to create -+ auditing flags, and adds the special case of append auditing if -+ we're requesting write */ -+ return (((reqmode & ~GR_AUDITS) << 10) | ((reqmode & GR_WRITE) ? GR_AU= DIT_APPEND : 0)); -+} ++endmenu ++menu "Network Protections" ++depends on GRKERNSEC + -+struct acl_subject_label * -+lookup_subject_map(const struct acl_subject_label *userp) -+{ -+ unsigned int index =3D shash(userp, subj_map_set.s_size); -+ struct subject_map *match; ++config GRKERNSEC_RANDNET ++ bool "Larger entropy pools" ++ help ++ If you say Y here, the entropy pools used for many features of Linux ++ and grsecurity will be doubled in size. Since several grsecurity ++ features use additional randomness, it is recommended that you say Y ++ here. Saying Y here has a similar effect as modifying ++ /proc/sys/kernel/random/poolsize. + -+ match =3D subj_map_set.s_hash[index]; ++config GRKERNSEC_BLACKHOLE ++ bool "TCP/UDP blackhole and LAST_ACK DoS prevention" ++ depends on NET ++ help ++ If you say Y here, neither TCP resets nor ICMP ++ destination-unreachable packets will be sent in response to packets ++ sent to ports for which no associated listening process exists. ++ This feature supports both IPV4 and IPV6 and exempts the=20 ++ loopback interface from blackholing. Enabling this feature=20 ++ makes a host more resilient to DoS attacks and reduces network ++ visibility against scanners. + -+ while (match && match->user !=3D userp) -+ match =3D match->next; ++ The blackhole feature as-implemented is equivalent to the FreeBSD ++ blackhole feature, as it prevents RST responses to all packets, not ++ just SYNs. Under most application behavior this causes no ++ problems, but applications (like haproxy) may not close certain ++ connections in a way that cleanly terminates them on the remote ++ end, leaving the remote host in LAST_ACK state. Because of this ++ side-effect and to prevent intentional LAST_ACK DoSes, this ++ feature also adds automatic mitigation against such attacks. ++ The mitigation drastically reduces the amount of time a socket ++ can spend in LAST_ACK state. If you're using haproxy and not ++ all servers it connects to have this option enabled, consider ++ disabling this feature on the haproxy host. + -+ if (match !=3D NULL) -+ return match->kernel; -+ else -+ return NULL; -+} ++ If the sysctl option is enabled, two sysctl options with names ++ "ip_blackhole" and "lastack_retries" will be created. ++ While "ip_blackhole" takes the standard zero/non-zero on/off ++ toggle, "lastack_retries" uses the same kinds of values as ++ "tcp_retries1" and "tcp_retries2". The default value of 4 ++ prevents a socket from lasting more than 45 seconds in LAST_ACK ++ state. + -+static void -+insert_subj_map_entry(struct subject_map *subjmap) -+{ -+ unsigned int index =3D shash(subjmap->user, subj_map_set.s_size); -+ struct subject_map **curr; ++config GRKERNSEC_SOCKET ++ bool "Socket restrictions" ++ depends on NET ++ help ++ If you say Y here, you will be able to choose from several options. ++ If you assign a GID on your system and add it to the supplementary ++ groups of users you want to restrict socket access to, this patch ++ will perform up to three things, based on the option(s) you choose. + -+ subjmap->prev =3D NULL; ++config GRKERNSEC_SOCKET_ALL ++ bool "Deny any sockets to group" ++ depends on GRKERNSEC_SOCKET ++ help ++ If you say Y here, you will be able to choose a GID of whose users w= ill ++ be unable to connect to other hosts from your machine or run server ++ applications from your machine. If the sysctl option is enabled, a ++ sysctl option with name "socket_all" is created. + -+ curr =3D &subj_map_set.s_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D subjmap; ++config GRKERNSEC_SOCKET_ALL_GID ++ int "GID to deny all sockets for" ++ depends on GRKERNSEC_SOCKET_ALL ++ default 1004 ++ help ++ Here you can choose the GID to disable socket access for. Remember t= o ++ add the users you want socket access disabled for to the GID ++ specified here. If the sysctl option is enabled, a sysctl option ++ with name "socket_all_gid" is created. + -+ subjmap->next =3D *curr; -+ *curr =3D subjmap; ++config GRKERNSEC_SOCKET_CLIENT ++ bool "Deny client sockets to group" ++ depends on GRKERNSEC_SOCKET ++ help ++ If you say Y here, you will be able to choose a GID of whose users w= ill ++ be unable to connect to other hosts from your machine, but will be ++ able to run servers. If this option is enabled, all users in the gr= oup ++ you specify will have to use passive mode when initiating ftp transf= ers ++ from the shell on your machine. If the sysctl option is enabled, a ++ sysctl option with name "socket_client" is created. + -+ return; -+} ++config GRKERNSEC_SOCKET_CLIENT_GID ++ int "GID to deny client sockets for" ++ depends on GRKERNSEC_SOCKET_CLIENT ++ default 1003 ++ help ++ Here you can choose the GID to disable client socket access for. ++ Remember to add the users you want client socket access disabled for= to ++ the GID specified here. If the sysctl option is enabled, a sysctl ++ option with name "socket_client_gid" is created. + -+static struct acl_role_label * -+lookup_acl_role_label(const struct task_struct *task, const uid_t uid, -+ const gid_t gid) -+{ -+ unsigned int index =3D rhash(uid, GR_ROLE_USER, acl_role_set.r_size); -+ struct acl_role_label *match; -+ struct role_allowed_ip *ipp; -+ unsigned int x; -+ u32 curr_ip =3D task->signal->curr_ip; ++config GRKERNSEC_SOCKET_SERVER ++ bool "Deny server sockets to group" ++ depends on GRKERNSEC_SOCKET ++ help ++ If you say Y here, you will be able to choose a GID of whose users w= ill ++ be unable to run server applications from your machine. If the sysc= tl ++ option is enabled, a sysctl option with name "socket_server" is crea= ted. + -+ task->signal->saved_ip =3D curr_ip; ++config GRKERNSEC_SOCKET_SERVER_GID ++ int "GID to deny server sockets for" ++ depends on GRKERNSEC_SOCKET_SERVER ++ default 1002 ++ help ++ Here you can choose the GID to disable server socket access for. ++ Remember to add the users you want server socket access disabled for= to ++ the GID specified here. If the sysctl option is enabled, a sysctl ++ option with name "socket_server_gid" is created. + -+ match =3D acl_role_set.r_hash[index]; ++endmenu ++menu "Sysctl support" ++depends on GRKERNSEC && SYSCTL + -+ while (match) { -+ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_USER)) =3D=3D (GR_RO= LE_DOMAIN | GR_ROLE_USER)) { -+ for (x =3D 0; x < match->domain_child_num; x++) { -+ if (match->domain_children[x] =3D=3D uid) -+ goto found; -+ } -+ } else if (match->uidgid =3D=3D uid && match->roletype & GR_ROLE_USER= ) -+ break; -+ match =3D match->next; -+ } -+found: -+ if (match =3D=3D NULL) { -+ try_group: -+ index =3D rhash(gid, GR_ROLE_GROUP, acl_role_set.r_size); -+ match =3D acl_role_set.r_hash[index]; ++config GRKERNSEC_SYSCTL ++ bool "Sysctl support" ++ help ++ If you say Y here, you will be able to change the options that ++ grsecurity runs with at bootup, without having to recompile your ++ kernel. You can echo values to files in /proc/sys/kernel/grsecurity ++ to enable (1) or disable (0) various features. All the sysctl entri= es ++ are mutable until the "grsec_lock" entry is set to a non-zero value. ++ All features enabled in the kernel configuration are disabled at boo= t ++ if you do not say Y to the "Turn on features by default" option. ++ All options should be set at startup, and the grsec_lock entry shoul= d ++ be set to a non-zero value after all the options are set. ++ *THIS IS EXTREMELY IMPORTANT* + -+ while (match) { -+ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_GROUP)) =3D=3D (GR_= ROLE_DOMAIN | GR_ROLE_GROUP)) { -+ for (x =3D 0; x < match->domain_child_num; x++) { -+ if (match->domain_children[x] =3D=3D gid) -+ goto found2; -+ } -+ } else if (match->uidgid =3D=3D gid && match->roletype & GR_ROLE_GRO= UP) -+ break; -+ match =3D match->next; -+ } -+found2: -+ if (match =3D=3D NULL) -+ match =3D default_role; -+ if (match->allowed_ips =3D=3D NULL) -+ return match; -+ else { -+ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { -+ if (likely -+ ((ntohl(curr_ip) & ipp->netmask) =3D=3D -+ (ntohl(ipp->addr) & ipp->netmask))) -+ return match; -+ } -+ match =3D default_role; -+ } -+ } else if (match->allowed_ips =3D=3D NULL) { -+ return match; -+ } else { -+ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { -+ if (likely -+ ((ntohl(curr_ip) & ipp->netmask) =3D=3D -+ (ntohl(ipp->addr) & ipp->netmask))) -+ return match; -+ } -+ goto try_group; -+ } ++config GRKERNSEC_SYSCTL_DISTRO ++ bool "Extra sysctl support for distro makers (READ HELP)" ++ depends on GRKERNSEC_SYSCTL && GRKERNSEC_IO ++ help ++ If you say Y here, additional sysctl options will be created ++ for features that affect processes running as root. Therefore, ++ it is critical when using this option that the grsec_lock entry be ++ enabled after boot. Only distros with prebuilt kernel packages ++ with this option enabled that can ensure grsec_lock is enabled ++ after boot should use this option. ++ *Failure to set grsec_lock after boot makes all grsec features ++ this option covers useless* + -+ return match; -+} ++ Currently this option creates the following sysctl entries: ++ "Disable Privileged I/O": "disable_priv_io"=09 + -+struct acl_subject_label * -+lookup_acl_subj_label(const ino_t ino, const dev_t dev, -+ const struct acl_role_label *role) -+{ -+ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); -+ struct acl_subject_label *match; ++config GRKERNSEC_SYSCTL_ON ++ bool "Turn on features by default" ++ depends on GRKERNSEC_SYSCTL ++ help ++ If you say Y here, instead of having all features enabled in the ++ kernel configuration disabled at boot time, the features will be ++ enabled at boot time. It is recommended you say Y here unless ++ there is some reason you would want all sysctl-tunable features to ++ be disabled by default. As mentioned elsewhere, it is important ++ to enable the grsec_lock entry once you have finished modifying ++ the sysctl entries. + -+ match =3D role->subj_hash[index]; ++endmenu ++menu "Logging Options" ++depends on GRKERNSEC + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ (match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++config GRKERNSEC_FLOODTIME ++ int "Seconds in between log messages (minimum)" ++ default 10 ++ help ++ This option allows you to enforce the number of seconds between ++ grsecurity log messages. The default should be suitable for most ++ people, however, if you choose to change it, choose a value small en= ough ++ to allow informative logs to be produced, but large enough to ++ prevent flooding. + -+ if (match && !(match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++config GRKERNSEC_FLOODBURST ++ int "Number of messages in a burst (maximum)" ++ default 6 ++ help ++ This option allows you to choose the maximum number of messages allo= wed ++ within the flood time interval you chose in a separate option. The ++ default should be suitable for most people, however if you find that ++ many of your logs are being interpreted as flooding, you may want to ++ raise this value. + -+struct acl_subject_label * -+lookup_acl_subj_label_deleted(const ino_t ino, const dev_t dev, -+ const struct acl_role_label *role) -+{ -+ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); -+ struct acl_subject_label *match; ++endmenu + -+ match =3D role->subj_hash[index]; ++endmenu +diff --git a/grsecurity/Makefile b/grsecurity/Makefile +new file mode 100644 +index 0000000..be9ae3a +--- /dev/null ++++ b/grsecurity/Makefile +@@ -0,0 +1,36 @@ ++# grsecurity's ACL system was originally written in 2001 by Michael Dal= ton ++# during 2001-2009 it has been completely redesigned by Brad Spengler ++# into an RBAC system ++# ++# All code in this directory and various hooks inserted throughout the = kernel ++# are copyright Brad Spengler - Open Source Security, Inc., and release= d=20 ++# under the GPL v2 or higher + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ !(match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } -+ -+ if (match && (match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++obj-y =3D grsec_chdir.o grsec_chroot.o grsec_exec.o grsec_fifo.o grsec_= fork.o \ ++ grsec_mount.o grsec_sig.o grsec_sysctl.o \ ++ grsec_time.o grsec_tpe.o grsec_link.o grsec_pax.o grsec_ptrace.o + -+static struct acl_object_label * -+lookup_acl_obj_label(const ino_t ino, const dev_t dev, -+ const struct acl_subject_label *subj) -+{ -+ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); -+ struct acl_object_label *match; ++obj-$(CONFIG_GRKERNSEC) +=3D grsec_init.o grsum.o gracl.o gracl_segv.o = \ ++ gracl_cap.o gracl_alloc.o gracl_shm.o grsec_mem.o gracl_fs.o \ ++ gracl_learn.o grsec_log.o ++obj-$(CONFIG_GRKERNSEC_RESLOG) +=3D gracl_res.o + -+ match =3D subj->obj_hash[index]; ++ifdef CONFIG_NET ++obj-y +=3D grsec_sock.o ++obj-$(CONFIG_GRKERNSEC) +=3D gracl_ip.o ++endif + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ (match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++ifndef CONFIG_GRKERNSEC ++obj-y +=3D grsec_disabled.o ++endif + -+ if (match && !(match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++ifdef CONFIG_GRKERNSEC_HIDESYM ++extra-y :=3D grsec_hidesym.o ++$(obj)/grsec_hidesym.o: ++ @-chmod -f 500 /boot ++ @-chmod -f 500 /lib/modules ++ @-chmod -f 500 /lib64/modules ++ @-chmod -f 500 /lib32/modules ++ @-chmod -f 700 . ++ @echo ' grsec: protected kernel image paths' ++endif +diff --git a/grsecurity/gracl.c b/grsecurity/gracl.c +new file mode 100644 +index 0000000..09258e0 +--- /dev/null ++++ b/grsecurity/gracl.c +@@ -0,0 +1,4156 @@ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include + -+static struct acl_object_label * -+lookup_acl_obj_label_create(const ino_t ino, const dev_t dev, -+ const struct acl_subject_label *subj) -+{ -+ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); -+ struct acl_object_label *match; ++#include ++#include ++#include + -+ match =3D subj->obj_hash[index]; ++static struct acl_role_db acl_role_set; ++static struct name_db name_set; ++static struct inodev_db inodev_set; + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ !(match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++/* for keeping track of userspace pointers used for subjects, so we ++ can share references in the kernel as well ++*/ + -+ if (match && (match->mode & GR_DELETED)) -+ return match; ++static struct path real_root; + -+ match =3D subj->obj_hash[index]; ++static struct acl_subj_map_db subj_map_set; + -+ while (match && (match->inode !=3D ino || match->device !=3D dev || -+ (match->mode & GR_DELETED))) { -+ match =3D match->next; -+ } ++static struct acl_role_label *default_role; + -+ if (match && !(match->mode & GR_DELETED)) -+ return match; -+ else -+ return NULL; -+} ++static struct acl_role_label *role_list; + -+static struct name_entry * -+lookup_name_entry(const char *name) -+{ -+ unsigned int len =3D strlen(name); -+ unsigned int key =3D full_name_hash(name, len); -+ unsigned int index =3D key % name_set.n_size; -+ struct name_entry *match; ++static u16 acl_sp_role_value; + -+ match =3D name_set.n_hash[index]; ++extern char *gr_shared_page[4]; ++static DEFINE_MUTEX(gr_dev_mutex); ++DEFINE_RWLOCK(gr_inode_lock); + -+ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len))) -+ match =3D match->next; ++struct gr_arg *gr_usermode; + -+ return match; -+} ++static unsigned int gr_status __read_only =3D GR_STATUS_INIT; + -+static struct name_entry * -+lookup_name_entry_create(const char *name) -+{ -+ unsigned int len =3D strlen(name); -+ unsigned int key =3D full_name_hash(name, len); -+ unsigned int index =3D key % name_set.n_size; -+ struct name_entry *match; ++extern int chkpw(struct gr_arg *entry, unsigned char *salt, unsigned ch= ar *sum); ++extern void gr_clear_learn_entries(void); + -+ match =3D name_set.n_hash[index]; ++#ifdef CONFIG_GRKERNSEC_RESLOG ++extern void gr_log_resource(const struct task_struct *task, ++ const int res, const unsigned long wanted, const int gt); ++#endif + -+ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || -+ !match->deleted)) -+ match =3D match->next; ++unsigned char *gr_system_salt; ++unsigned char *gr_system_sum; + -+ if (match && match->deleted) -+ return match; ++static struct sprole_pw **acl_special_roles =3D NULL; ++static __u16 num_sprole_pws =3D 0; + -+ match =3D name_set.n_hash[index]; ++static struct acl_role_label *kernel_role =3D NULL; + -+ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || -+ match->deleted)) -+ match =3D match->next; ++static unsigned int gr_auth_attempts =3D 0; ++static unsigned long gr_auth_expires =3D 0UL; + -+ if (match && !match->deleted) -+ return match; -+ else -+ return NULL; -+} ++#ifdef CONFIG_NET ++extern struct vfsmount *sock_mnt; ++#endif + -+static struct inodev_entry * -+lookup_inodev_entry(const ino_t ino, const dev_t dev) -+{ -+ unsigned int index =3D fhash(ino, dev, inodev_set.i_size); -+ struct inodev_entry *match; ++extern struct vfsmount *pipe_mnt; ++extern struct vfsmount *shm_mnt; ++#ifdef CONFIG_HUGETLBFS ++extern struct vfsmount *hugetlbfs_vfsmount; ++#endif + -+ match =3D inodev_set.i_hash[index]; ++static struct acl_object_label *fakefs_obj_rw; ++static struct acl_object_label *fakefs_obj_rwx; + -+ while (match && (match->nentry->inode !=3D ino || match->nentry->devic= e !=3D dev)) -+ match =3D match->next; ++extern int gr_init_uidset(void); ++extern void gr_free_uidset(void); ++extern void gr_remove_uid(uid_t uid); ++extern int gr_find_uid(uid_t uid); + -+ return match; -+} ++DECLARE_BRLOCK(vfsmount_lock); + -+static void -+insert_inodev_entry(struct inodev_entry *entry) ++__inline__ int ++gr_acl_is_enabled(void) +{ -+ unsigned int index =3D fhash(entry->nentry->inode, entry->nentry->devi= ce, -+ inodev_set.i_size); -+ struct inodev_entry **curr; -+ -+ entry->prev =3D NULL; ++ return (gr_status & GR_READY); ++} + -+ curr =3D &inodev_set.i_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D entry; -+=09 -+ entry->next =3D *curr; -+ *curr =3D entry; ++#ifdef CONFIG_BTRFS_FS ++extern dev_t get_btrfs_dev_from_inode(struct inode *inode); ++extern int btrfs_getattr(struct vfsmount *mnt, struct dentry *dentry, s= truct kstat *stat); ++#endif + -+ return; ++static inline dev_t __get_dev(const struct dentry *dentry) ++{ ++#ifdef CONFIG_BTRFS_FS ++ if (dentry->d_inode->i_op && dentry->d_inode->i_op->getattr =3D=3D &bt= rfs_getattr) ++ return get_btrfs_dev_from_inode(dentry->d_inode); ++ else ++#endif ++ return dentry->d_inode->i_sb->s_dev; +} + -+static void -+__insert_acl_role_label(struct acl_role_label *role, uid_t uidgid) ++dev_t gr_get_dev_from_dentry(struct dentry *dentry) +{ -+ unsigned int index =3D -+ rhash(uidgid, role->roletype & (GR_ROLE_USER | GR_ROLE_GROUP), acl= _role_set.r_size); -+ struct acl_role_label **curr; -+ struct acl_role_label *tmp; -+ -+ curr =3D &acl_role_set.r_hash[index]; -+ -+ /* if role was already inserted due to domains and already has -+ a role in the same bucket as it attached, then we need to -+ combine these two buckets -+ */ -+ if (role->next) { -+ tmp =3D role->next; -+ while (tmp->next) -+ tmp =3D tmp->next; -+ tmp->next =3D *curr; -+ } else -+ role->next =3D *curr; -+ *curr =3D role; -+ -+ return; ++ return __get_dev(dentry); +} + -+static void -+insert_acl_role_label(struct acl_role_label *role) ++static char gr_task_roletype_to_char(struct task_struct *task) +{ -+ int i; -+ -+ if (role_list =3D=3D NULL) { -+ role_list =3D role; -+ role->prev =3D NULL; -+ } else { -+ role->prev =3D role_list; -+ role_list =3D role; ++ switch (task->role->roletype & ++ (GR_ROLE_DEFAULT | GR_ROLE_USER | GR_ROLE_GROUP | ++ GR_ROLE_SPECIAL)) { ++ case GR_ROLE_DEFAULT: ++ return 'D'; ++ case GR_ROLE_USER: ++ return 'U'; ++ case GR_ROLE_GROUP: ++ return 'G'; ++ case GR_ROLE_SPECIAL: ++ return 'S'; + } -+=09 -+ /* used for hash chains */ -+ role->next =3D NULL; + -+ if (role->roletype & GR_ROLE_DOMAIN) { -+ for (i =3D 0; i < role->domain_child_num; i++) -+ __insert_acl_role_label(role, role->domain_children[i]); -+ } else -+ __insert_acl_role_label(role, role->uidgid); ++ return 'X'; +} -+ =09 -+static int -+insert_name_entry(char *name, const ino_t inode, const dev_t device, __= u8 deleted) -+{ -+ struct name_entry **curr, *nentry; -+ struct inodev_entry *ientry; -+ unsigned int len =3D strlen(name); -+ unsigned int key =3D full_name_hash(name, len); -+ unsigned int index =3D key % name_set.n_size; -+ -+ curr =3D &name_set.n_hash[index]; -+ -+ while (*curr && ((*curr)->key !=3D key || !gr_streq((*curr)->name, nam= e, (*curr)->len, len))) -+ curr =3D &((*curr)->next); + -+ if (*curr !=3D NULL) -+ return 1; ++char gr_roletype_to_char(void) ++{ ++ return gr_task_roletype_to_char(current); ++} + -+ nentry =3D acl_alloc(sizeof (struct name_entry)); -+ if (nentry =3D=3D NULL) ++__inline__ int ++gr_acl_tpe_check(void) ++{ ++ if (unlikely(!(gr_status & GR_READY))) + return 0; -+ ientry =3D acl_alloc(sizeof (struct inodev_entry)); -+ if (ientry =3D=3D NULL) ++ if (current->role->roletype & GR_ROLE_TPE) ++ return 1; ++ else + return 0; -+ ientry->nentry =3D nentry; -+ -+ nentry->key =3D key; -+ nentry->name =3D name; -+ nentry->inode =3D inode; -+ nentry->device =3D device; -+ nentry->len =3D len; -+ nentry->deleted =3D deleted; -+ -+ nentry->prev =3D NULL; -+ curr =3D &name_set.n_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D nentry; -+ nentry->next =3D *curr; -+ *curr =3D nentry; -+ -+ /* insert us into the table searchable by inode/dev */ -+ insert_inodev_entry(ientry); -+ -+ return 1; +} + -+static void -+insert_acl_obj_label(struct acl_object_label *obj, -+ struct acl_subject_label *subj) ++int ++gr_handle_rawio(const struct inode *inode) +{ -+ unsigned int index =3D -+ fhash(obj->inode, obj->device, subj->obj_hash_size); -+ struct acl_object_label **curr; ++#ifdef CONFIG_GRKERNSEC_CHROOT_CAPS ++ if (inode && S_ISBLK(inode->i_mode) && ++ grsec_enable_chroot_caps && proc_is_chrooted(current) && ++ !capable(CAP_SYS_RAWIO)) ++ return 1; ++#endif ++ return 0; ++} + -+=09 -+ obj->prev =3D NULL; ++static int ++gr_streq(const char *a, const char *b, const unsigned int lena, const u= nsigned int lenb) ++{ ++ if (likely(lena !=3D lenb)) ++ return 0; + -+ curr =3D &subj->obj_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D obj; ++ return !memcmp(a, b, lena); ++} + -+ obj->next =3D *curr; -+ *curr =3D obj; ++static int prepend(char **buffer, int *buflen, const char *str, int nam= elen) ++{ ++ *buflen -=3D namelen; ++ if (*buflen < 0) ++ return -ENAMETOOLONG; ++ *buffer -=3D namelen; ++ memcpy(*buffer, str, namelen); ++ return 0; ++} + -+ return; ++static int prepend_name(char **buffer, int *buflen, struct qstr *name) ++{ ++ return prepend(buffer, buflen, name->name, name->len); +} + -+static void -+insert_acl_subj_label(struct acl_subject_label *obj, -+ struct acl_role_label *role) ++static int prepend_path(const struct path *path, struct path *root, ++ char **buffer, int *buflen) +{ -+ unsigned int index =3D fhash(obj->inode, obj->device, role->subj_hash_= size); -+ struct acl_subject_label **curr; ++ struct dentry *dentry =3D path->dentry; ++ struct vfsmount *vfsmnt =3D path->mnt; ++ bool slash =3D false; ++ int error =3D 0; + -+ obj->prev =3D NULL; ++ while (dentry !=3D root->dentry || vfsmnt !=3D root->mnt) { ++ struct dentry * parent; + -+ curr =3D &role->subj_hash[index]; -+ if (*curr !=3D NULL) -+ (*curr)->prev =3D obj; ++ if (dentry =3D=3D vfsmnt->mnt_root || IS_ROOT(dentry)) { ++ /* Global root? */ ++ if (vfsmnt->mnt_parent =3D=3D vfsmnt) { ++ goto out; ++ } ++ dentry =3D vfsmnt->mnt_mountpoint; ++ vfsmnt =3D vfsmnt->mnt_parent; ++ continue; ++ } ++ parent =3D dentry->d_parent; ++ prefetch(parent); ++ spin_lock(&dentry->d_lock); ++ error =3D prepend_name(buffer, buflen, &dentry->d_name); ++ spin_unlock(&dentry->d_lock); ++ if (!error) ++ error =3D prepend(buffer, buflen, "/", 1); ++ if (error) ++ break; + -+ obj->next =3D *curr; -+ *curr =3D obj; ++ slash =3D true; ++ dentry =3D parent; ++ } + -+ return; ++out: ++ if (!error && !slash) ++ error =3D prepend(buffer, buflen, "/", 1); ++ ++ return error; +} + -+/* allocating chained hash tables, so optimal size is where lambda ~ 1 = */ ++/* this must be called with vfsmount_lock and rename_lock held */ + -+static void * -+create_table(__u32 * len, int elementsize) ++static char *__our_d_path(const struct path *path, struct path *root, ++ char *buf, int buflen) +{ -+ unsigned int table_sizes[] =3D { -+ 7, 13, 31, 61, 127, 251, 509, 1021, 2039, 4093, 8191, 16381, -+ 32749, 65521, 131071, 262139, 524287, 1048573, 2097143, -+ 4194301, 8388593, 16777213, 33554393, 67108859 -+ }; -+ void *newtable =3D NULL; -+ unsigned int pwr =3D 0; ++ char *res =3D buf + buflen; ++ int error; + -+ while ((pwr < ((sizeof (table_sizes) / sizeof (table_sizes[0])) - 1)) = && -+ table_sizes[pwr] <=3D *len) -+ pwr++; ++ prepend(&res, &buflen, "\0", 1); ++ error =3D prepend_path(path, root, &res, &buflen); ++ if (error) ++ return ERR_PTR(error); + -+ if (table_sizes[pwr] <=3D *len || (table_sizes[pwr] > ULONG_MAX / elem= entsize)) -+ return newtable; ++ return res; ++} + -+ if ((table_sizes[pwr] * elementsize) <=3D PAGE_SIZE) -+ newtable =3D -+ kmalloc(table_sizes[pwr] * elementsize, GFP_KERNEL); -+ else -+ newtable =3D vmalloc(table_sizes[pwr] * elementsize); ++static char * ++gen_full_path(struct path *path, struct path *root, char *buf, int bufl= en) ++{ ++ char *retval; + -+ *len =3D table_sizes[pwr]; ++ retval =3D __our_d_path(path, root, buf, buflen); ++ if (unlikely(IS_ERR(retval))) ++ retval =3D strcpy(buf, ""); ++ else if (unlikely(retval[1] =3D=3D '/' && retval[2] =3D=3D '\0')) ++ retval[1] =3D '\0'; + -+ return newtable; ++ return retval; +} + -+static int -+init_variables(const struct gr_arg *arg) ++static char * ++__d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmn= t, ++ char *buf, int buflen) +{ -+ struct task_struct *reaper =3D &init_task; -+ unsigned int stacksize; ++ struct path path; ++ char *res; + -+ subj_map_set.s_size =3D arg->role_db.num_subjects; -+ acl_role_set.r_size =3D arg->role_db.num_roles + arg->role_db.num_doma= in_children; -+ name_set.n_size =3D arg->role_db.num_objects; -+ inodev_set.i_size =3D arg->role_db.num_objects; ++ path.dentry =3D (struct dentry *)dentry; ++ path.mnt =3D (struct vfsmount *)vfsmnt; + -+ if (!subj_map_set.s_size || !acl_role_set.r_size || -+ !name_set.n_size || !inodev_set.i_size) -+ return 1; ++ /* we can use real_root.dentry, real_root.mnt, because this is only ca= lled ++ by the RBAC system */ ++ res =3D gen_full_path(&path, &real_root, buf, buflen); + -+ if (!gr_init_uidset()) -+ return 1; ++ return res; ++} + -+ /* set up the stack that holds allocation info */ ++static char * ++d_real_path(const struct dentry *dentry, const struct vfsmount *vfsmnt, ++ char *buf, int buflen) ++{ ++ char *res; ++ struct path path; ++ struct path root; ++ struct task_struct *reaper =3D &init_task; + -+ stacksize =3D arg->role_db.num_pointers + 5; ++ path.dentry =3D (struct dentry *)dentry; ++ path.mnt =3D (struct vfsmount *)vfsmnt; + -+ if (!acl_alloc_stack_init(stacksize)) -+ return 1; ++ /* we can't use real_root.dentry, real_root.mnt, because they belong o= nly to the RBAC system */ ++ get_fs_root(reaper->fs, &root); + -+ /* grab reference for the real root dentry and vfsmount */ -+ get_fs_root(reaper->fs, &real_root); -+=09 -+#ifdef CONFIG_GRKERNSEC_RBAC_DEBUG -+ printk(KERN_ALERT "Obtained real root device=3D%d, inode=3D%lu\n", __g= et_dev(real_root.dentry), real_root.dentry->d_inode->i_ino); -+#endif ++ write_seqlock(&rename_lock); ++ br_read_lock(vfsmount_lock); ++ res =3D gen_full_path(&path, &root, buf, buflen); ++ br_read_unlock(vfsmount_lock); ++ write_sequnlock(&rename_lock); + -+ fakefs_obj_rw =3D acl_alloc(sizeof(struct acl_object_label)); -+ if (fakefs_obj_rw =3D=3D NULL) -+ return 1; -+ fakefs_obj_rw->mode =3D GR_FIND | GR_READ | GR_WRITE; -+ -+ fakefs_obj_rwx =3D acl_alloc(sizeof(struct acl_object_label)); -+ if (fakefs_obj_rwx =3D=3D NULL) -+ return 1; -+ fakefs_obj_rwx->mode =3D GR_FIND | GR_READ | GR_WRITE | GR_EXEC; -+ -+ subj_map_set.s_hash =3D -+ (struct subject_map **) create_table(&subj_map_set.s_size, sizeof(= void *)); -+ acl_role_set.r_hash =3D -+ (struct acl_role_label **) create_table(&acl_role_set.r_size, size= of(void *)); -+ name_set.n_hash =3D (struct name_entry **) create_table(&name_set.n_si= ze, sizeof(void *)); -+ inodev_set.i_hash =3D -+ (struct inodev_entry **) create_table(&inodev_set.i_size, sizeof(v= oid *)); -+ -+ if (!subj_map_set.s_hash || !acl_role_set.r_hash || -+ !name_set.n_hash || !inodev_set.i_hash) -+ return 1; -+ -+ memset(subj_map_set.s_hash, 0, -+ sizeof(struct subject_map *) * subj_map_set.s_size); -+ memset(acl_role_set.r_hash, 0, -+ sizeof (struct acl_role_label *) * acl_role_set.r_size); -+ memset(name_set.n_hash, 0, -+ sizeof (struct name_entry *) * name_set.n_size); -+ memset(inodev_set.i_hash, 0, -+ sizeof (struct inodev_entry *) * inodev_set.i_size); -+ -+ return 0; ++ path_put(&root); ++ return res; +} + -+/* free information not needed after startup -+ currently contains user->kernel pointer mappings for subjects -+*/ ++static char * ++gr_to_filename_rbac(const struct dentry *dentry, const struct vfsmount = *mnt) ++{ ++ char *ret; ++ write_seqlock(&rename_lock); ++ br_read_lock(vfsmount_lock); ++ ret =3D __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_p= rocessor_id()), ++ PAGE_SIZE); ++ br_read_unlock(vfsmount_lock); ++ write_sequnlock(&rename_lock); ++ return ret; ++} + -+static void -+free_init_variables(void) ++static char * ++gr_to_proc_filename_rbac(const struct dentry *dentry, const struct vfsm= ount *mnt) +{ -+ __u32 i; ++ char *ret; ++ char *buf; ++ int buflen; + -+ if (subj_map_set.s_hash) { -+ for (i =3D 0; i < subj_map_set.s_size; i++) { -+ if (subj_map_set.s_hash[i]) { -+ kfree(subj_map_set.s_hash[i]); -+ subj_map_set.s_hash[i] =3D NULL; -+ } -+ } ++ write_seqlock(&rename_lock); ++ br_read_lock(vfsmount_lock); ++ buf =3D per_cpu_ptr(gr_shared_page[0], smp_processor_id()); ++ ret =3D __d_real_path(dentry, mnt, buf, PAGE_SIZE - 6); ++ buflen =3D (int)(ret - buf); ++ if (buflen >=3D 5) ++ prepend(&ret, &buflen, "/proc", 5); ++ else ++ ret =3D strcpy(buf, ""); ++ br_read_unlock(vfsmount_lock); ++ write_sequnlock(&rename_lock); ++ return ret; ++} + -+ if ((subj_map_set.s_size * sizeof (struct subject_map *)) <=3D -+ PAGE_SIZE) -+ kfree(subj_map_set.s_hash); -+ else -+ vfree(subj_map_set.s_hash); -+ } ++char * ++gr_to_filename_nolock(const struct dentry *dentry, const struct vfsmoun= t *mnt) ++{ ++ return __d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0],smp_pr= ocessor_id()), ++ PAGE_SIZE); ++} + -+ return; ++char * ++gr_to_filename(const struct dentry *dentry, const struct vfsmount *mnt) ++{ ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[0], smp_pro= cessor_id()), ++ PAGE_SIZE); +} + -+static void -+free_variables(void) ++char * ++gr_to_filename1(const struct dentry *dentry, const struct vfsmount *mnt= ) +{ -+ struct acl_subject_label *s; -+ struct acl_role_label *r; -+ struct task_struct *task, *task2; -+ unsigned int x; ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[1], smp_pro= cessor_id()), ++ PAGE_SIZE); ++} + -+ gr_clear_learn_entries(); ++char * ++gr_to_filename2(const struct dentry *dentry, const struct vfsmount *mnt= ) ++{ ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[2], smp_pro= cessor_id()), ++ PAGE_SIZE); ++} + -+ read_lock(&tasklist_lock); -+ do_each_thread(task2, task) { -+ task->acl_sp_role =3D 0; -+ task->acl_role_id =3D 0; -+ task->acl =3D NULL; -+ task->role =3D NULL; -+ } while_each_thread(task2, task); -+ read_unlock(&tasklist_lock); ++char * ++gr_to_filename3(const struct dentry *dentry, const struct vfsmount *mnt= ) ++{ ++ return d_real_path(dentry, mnt, per_cpu_ptr(gr_shared_page[3], smp_pro= cessor_id()), ++ PAGE_SIZE); ++} + -+ /* release the reference to the real root dentry and vfsmount */ -+ path_put(&real_root); ++__inline__ __u32 ++to_gr_audit(const __u32 reqmode) ++{ ++ /* masks off auditable permission flags, then shifts them to create ++ auditing flags, and adds the special case of append auditing if ++ we're requesting write */ ++ return (((reqmode & ~GR_AUDITS) << 10) | ((reqmode & GR_WRITE) ? GR_AU= DIT_APPEND : 0)); ++} + -+ /* free all object hash tables */ ++struct acl_subject_label * ++lookup_subject_map(const struct acl_subject_label *userp) ++{ ++ unsigned int index =3D shash(userp, subj_map_set.s_size); ++ struct subject_map *match; + -+ FOR_EACH_ROLE_START(r) -+ if (r->subj_hash =3D=3D NULL) -+ goto next_role; -+ FOR_EACH_SUBJECT_START(r, s, x) -+ if (s->obj_hash =3D=3D NULL) -+ break; -+ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) -+ kfree(s->obj_hash); -+ else -+ vfree(s->obj_hash); -+ FOR_EACH_SUBJECT_END(s, x) -+ FOR_EACH_NESTED_SUBJECT_START(r, s) -+ if (s->obj_hash =3D=3D NULL) -+ break; -+ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) -+ kfree(s->obj_hash); -+ else -+ vfree(s->obj_hash); -+ FOR_EACH_NESTED_SUBJECT_END(s) -+ if ((r->subj_hash_size * sizeof (struct acl_subject_label *)) <=3D PA= GE_SIZE) -+ kfree(r->subj_hash); -+ else -+ vfree(r->subj_hash); -+ r->subj_hash =3D NULL; -+next_role: -+ FOR_EACH_ROLE_END(r) ++ match =3D subj_map_set.s_hash[index]; + -+ acl_free_all(); ++ while (match && match->user !=3D userp) ++ match =3D match->next; + -+ if (acl_role_set.r_hash) { -+ if ((acl_role_set.r_size * sizeof (struct acl_role_label *)) <=3D -+ PAGE_SIZE) -+ kfree(acl_role_set.r_hash); -+ else -+ vfree(acl_role_set.r_hash); -+ } -+ if (name_set.n_hash) { -+ if ((name_set.n_size * sizeof (struct name_entry *)) <=3D -+ PAGE_SIZE) -+ kfree(name_set.n_hash); -+ else -+ vfree(name_set.n_hash); -+ } ++ if (match !=3D NULL) ++ return match->kernel; ++ else ++ return NULL; ++} + -+ if (inodev_set.i_hash) { -+ if ((inodev_set.i_size * sizeof (struct inodev_entry *)) <=3D -+ PAGE_SIZE) -+ kfree(inodev_set.i_hash); -+ else -+ vfree(inodev_set.i_hash); -+ } ++static void ++insert_subj_map_entry(struct subject_map *subjmap) ++{ ++ unsigned int index =3D shash(subjmap->user, subj_map_set.s_size); ++ struct subject_map **curr; + -+ gr_free_uidset(); ++ subjmap->prev =3D NULL; + -+ memset(&name_set, 0, sizeof (struct name_db)); -+ memset(&inodev_set, 0, sizeof (struct inodev_db)); -+ memset(&acl_role_set, 0, sizeof (struct acl_role_db)); -+ memset(&subj_map_set, 0, sizeof (struct acl_subj_map_db)); ++ curr =3D &subj_map_set.s_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D subjmap; + -+ default_role =3D NULL; -+ role_list =3D NULL; ++ subjmap->next =3D *curr; ++ *curr =3D subjmap; + + return; +} + -+static __u32 -+count_user_objs(struct acl_object_label *userp) ++static struct acl_role_label * ++lookup_acl_role_label(const struct task_struct *task, const uid_t uid, ++ const gid_t gid) +{ -+ struct acl_object_label o_tmp; -+ __u32 num =3D 0; ++ unsigned int index =3D rhash(uid, GR_ROLE_USER, acl_role_set.r_size); ++ struct acl_role_label *match; ++ struct role_allowed_ip *ipp; ++ unsigned int x; ++ u32 curr_ip =3D task->signal->curr_ip; + -+ while (userp) { -+ if (copy_from_user(&o_tmp, userp, -+ sizeof (struct acl_object_label))) ++ task->signal->saved_ip =3D curr_ip; ++ ++ match =3D acl_role_set.r_hash[index]; ++ ++ while (match) { ++ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_USER)) =3D=3D (GR_RO= LE_DOMAIN | GR_ROLE_USER)) { ++ for (x =3D 0; x < match->domain_child_num; x++) { ++ if (match->domain_children[x] =3D=3D uid) ++ goto found; ++ } ++ } else if (match->uidgid =3D=3D uid && match->roletype & GR_ROLE_USER= ) + break; ++ match =3D match->next; ++ } ++found: ++ if (match =3D=3D NULL) { ++ try_group: ++ index =3D rhash(gid, GR_ROLE_GROUP, acl_role_set.r_size); ++ match =3D acl_role_set.r_hash[index]; + -+ userp =3D o_tmp.prev; -+ num++; ++ while (match) { ++ if ((match->roletype & (GR_ROLE_DOMAIN | GR_ROLE_GROUP)) =3D=3D (GR_= ROLE_DOMAIN | GR_ROLE_GROUP)) { ++ for (x =3D 0; x < match->domain_child_num; x++) { ++ if (match->domain_children[x] =3D=3D gid) ++ goto found2; ++ } ++ } else if (match->uidgid =3D=3D gid && match->roletype & GR_ROLE_GRO= UP) ++ break; ++ match =3D match->next; ++ } ++found2: ++ if (match =3D=3D NULL) ++ match =3D default_role; ++ if (match->allowed_ips =3D=3D NULL) ++ return match; ++ else { ++ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { ++ if (likely ++ ((ntohl(curr_ip) & ipp->netmask) =3D=3D ++ (ntohl(ipp->addr) & ipp->netmask))) ++ return match; ++ } ++ match =3D default_role; ++ } ++ } else if (match->allowed_ips =3D=3D NULL) { ++ return match; ++ } else { ++ for (ipp =3D match->allowed_ips; ipp; ipp =3D ipp->next) { ++ if (likely ++ ((ntohl(curr_ip) & ipp->netmask) =3D=3D ++ (ntohl(ipp->addr) & ipp->netmask))) ++ return match; ++ } ++ goto try_group; + } + -+ return num; ++ return match; +} + -+static struct acl_subject_label * -+do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role); -+ -+static int -+copy_user_glob(struct acl_object_label *obj) ++struct acl_subject_label * ++lookup_acl_subj_label(const ino_t ino, const dev_t dev, ++ const struct acl_role_label *role) +{ -+ struct acl_object_label *g_tmp, **guser; -+ unsigned int len; -+ char *tmp; -+ -+ if (obj->globbed =3D=3D NULL) -+ return 0; -+ -+ guser =3D &obj->globbed; -+ while (*guser) { -+ g_tmp =3D (struct acl_object_label *) -+ acl_alloc(sizeof (struct acl_object_label)); -+ if (g_tmp =3D=3D NULL) -+ return -ENOMEM; ++ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); ++ struct acl_subject_label *match; + -+ if (copy_from_user(g_tmp, *guser, -+ sizeof (struct acl_object_label))) -+ return -EFAULT; ++ match =3D role->subj_hash[index]; + -+ len =3D strnlen_user(g_tmp->filename, PATH_MAX); ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ (match->mode & GR_DELETED))) { ++ match =3D match->next; ++ } + -+ if (!len || len >=3D PATH_MAX) -+ return -EINVAL; ++ if (match && !(match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; ++} + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return -ENOMEM; ++struct acl_subject_label * ++lookup_acl_subj_label_deleted(const ino_t ino, const dev_t dev, ++ const struct acl_role_label *role) ++{ ++ unsigned int index =3D fhash(ino, dev, role->subj_hash_size); ++ struct acl_subject_label *match; + -+ if (copy_from_user(tmp, g_tmp->filename, len)) -+ return -EFAULT; -+ tmp[len-1] =3D '\0'; -+ g_tmp->filename =3D tmp; ++ match =3D role->subj_hash[index]; + -+ *guser =3D g_tmp; -+ guser =3D &(g_tmp->next); ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ !(match->mode & GR_DELETED))) { ++ match =3D match->next; + } + -+ return 0; ++ if (match && (match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; +} + -+static int -+copy_user_objs(struct acl_object_label *userp, struct acl_subject_label= *subj, -+ struct acl_role_label *role) ++static struct acl_object_label * ++lookup_acl_obj_label(const ino_t ino, const dev_t dev, ++ const struct acl_subject_label *subj) +{ -+ struct acl_object_label *o_tmp; -+ unsigned int len; -+ int ret; -+ char *tmp; -+ -+ while (userp) { -+ if ((o_tmp =3D (struct acl_object_label *) -+ acl_alloc(sizeof (struct acl_object_label))) =3D=3D NULL) -+ return -ENOMEM; -+ -+ if (copy_from_user(o_tmp, userp, -+ sizeof (struct acl_object_label))) -+ return -EFAULT; ++ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); ++ struct acl_object_label *match; + -+ userp =3D o_tmp->prev; ++ match =3D subj->obj_hash[index]; + -+ len =3D strnlen_user(o_tmp->filename, PATH_MAX); ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ (match->mode & GR_DELETED))) { ++ match =3D match->next; ++ } + -+ if (!len || len >=3D PATH_MAX) -+ return -EINVAL; ++ if (match && !(match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; ++} + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return -ENOMEM; ++static struct acl_object_label * ++lookup_acl_obj_label_create(const ino_t ino, const dev_t dev, ++ const struct acl_subject_label *subj) ++{ ++ unsigned int index =3D fhash(ino, dev, subj->obj_hash_size); ++ struct acl_object_label *match; + -+ if (copy_from_user(tmp, o_tmp->filename, len)) -+ return -EFAULT; -+ tmp[len-1] =3D '\0'; -+ o_tmp->filename =3D tmp; ++ match =3D subj->obj_hash[index]; + -+ insert_acl_obj_label(o_tmp, subj); -+ if (!insert_name_entry(o_tmp->filename, o_tmp->inode, -+ o_tmp->device, (o_tmp->mode & GR_DELETED) ? 1 : 0)) -+ return -ENOMEM; ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ !(match->mode & GR_DELETED))) { ++ match =3D match->next; ++ } + -+ ret =3D copy_user_glob(o_tmp); -+ if (ret) -+ return ret; ++ if (match && (match->mode & GR_DELETED)) ++ return match; + -+ if (o_tmp->nested) { -+ o_tmp->nested =3D do_copy_user_subj(o_tmp->nested, role); -+ if (IS_ERR(o_tmp->nested)) -+ return PTR_ERR(o_tmp->nested); ++ match =3D subj->obj_hash[index]; + -+ /* insert into nested subject list */ -+ o_tmp->nested->next =3D role->hash->first; -+ role->hash->first =3D o_tmp->nested; -+ } ++ while (match && (match->inode !=3D ino || match->device !=3D dev || ++ (match->mode & GR_DELETED))) { ++ match =3D match->next; + } + -+ return 0; ++ if (match && !(match->mode & GR_DELETED)) ++ return match; ++ else ++ return NULL; +} + -+static __u32 -+count_user_subjs(struct acl_subject_label *userp) ++static struct name_entry * ++lookup_name_entry(const char *name) +{ -+ struct acl_subject_label s_tmp; -+ __u32 num =3D 0; ++ unsigned int len =3D strlen(name); ++ unsigned int key =3D full_name_hash(name, len); ++ unsigned int index =3D key % name_set.n_size; ++ struct name_entry *match; + -+ while (userp) { -+ if (copy_from_user(&s_tmp, userp, -+ sizeof (struct acl_subject_label))) -+ break; ++ match =3D name_set.n_hash[index]; + -+ userp =3D s_tmp.prev; -+ /* do not count nested subjects against this count, since -+ they are not included in the hash table, but are -+ attached to objects. We have already counted -+ the subjects in userspace for the allocation=20 -+ stack -+ */ -+ if (!(s_tmp.mode & GR_NESTED)) -+ num++; -+ } ++ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len))) ++ match =3D match->next; + -+ return num; ++ return match; +} + -+static int -+copy_user_allowedips(struct acl_role_label *rolep) ++static struct name_entry * ++lookup_name_entry_create(const char *name) +{ -+ struct role_allowed_ip *ruserip, *rtmp =3D NULL, *rlast; -+ -+ ruserip =3D rolep->allowed_ips; -+ -+ while (ruserip) { -+ rlast =3D rtmp; ++ unsigned int len =3D strlen(name); ++ unsigned int key =3D full_name_hash(name, len); ++ unsigned int index =3D key % name_set.n_size; ++ struct name_entry *match; + -+ if ((rtmp =3D (struct role_allowed_ip *) -+ acl_alloc(sizeof (struct role_allowed_ip))) =3D=3D NULL) -+ return -ENOMEM; ++ match =3D name_set.n_hash[index]; + -+ if (copy_from_user(rtmp, ruserip, -+ sizeof (struct role_allowed_ip))) -+ return -EFAULT; ++ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || ++ !match->deleted)) ++ match =3D match->next; + -+ ruserip =3D rtmp->prev; ++ if (match && match->deleted) ++ return match; + -+ if (!rlast) { -+ rtmp->prev =3D NULL; -+ rolep->allowed_ips =3D rtmp; -+ } else { -+ rlast->next =3D rtmp; -+ rtmp->prev =3D rlast; -+ } ++ match =3D name_set.n_hash[index]; + -+ if (!ruserip) -+ rtmp->next =3D NULL; -+ } ++ while (match && (match->key !=3D key || !gr_streq(match->name, name, m= atch->len, len) || ++ match->deleted)) ++ match =3D match->next; + -+ return 0; ++ if (match && !match->deleted) ++ return match; ++ else ++ return NULL; +} + -+static int -+copy_user_transitions(struct acl_role_label *rolep) ++static struct inodev_entry * ++lookup_inodev_entry(const ino_t ino, const dev_t dev) +{ -+ struct role_transition *rusertp, *rtmp =3D NULL, *rlast; -+=09 -+ unsigned int len; -+ char *tmp; ++ unsigned int index =3D fhash(ino, dev, inodev_set.i_size); ++ struct inodev_entry *match; + -+ rusertp =3D rolep->transitions; ++ match =3D inodev_set.i_hash[index]; + -+ while (rusertp) { -+ rlast =3D rtmp; ++ while (match && (match->nentry->inode !=3D ino || match->nentry->devic= e !=3D dev)) ++ match =3D match->next; + -+ if ((rtmp =3D (struct role_transition *) -+ acl_alloc(sizeof (struct role_transition))) =3D=3D NULL) -+ return -ENOMEM; ++ return match; ++} + -+ if (copy_from_user(rtmp, rusertp, -+ sizeof (struct role_transition))) -+ return -EFAULT; ++static void ++insert_inodev_entry(struct inodev_entry *entry) ++{ ++ unsigned int index =3D fhash(entry->nentry->inode, entry->nentry->devi= ce, ++ inodev_set.i_size); ++ struct inodev_entry **curr; + -+ rusertp =3D rtmp->prev; ++ entry->prev =3D NULL; + -+ len =3D strnlen_user(rtmp->rolename, GR_SPROLE_LEN); ++ curr =3D &inodev_set.i_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D entry; ++=09 ++ entry->next =3D *curr; ++ *curr =3D entry; + -+ if (!len || len >=3D GR_SPROLE_LEN) -+ return -EINVAL; ++ return; ++} + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return -ENOMEM; ++static void ++__insert_acl_role_label(struct acl_role_label *role, uid_t uidgid) ++{ ++ unsigned int index =3D ++ rhash(uidgid, role->roletype & (GR_ROLE_USER | GR_ROLE_GROUP), acl= _role_set.r_size); ++ struct acl_role_label **curr; ++ struct acl_role_label *tmp; + -+ if (copy_from_user(tmp, rtmp->rolename, len)) -+ return -EFAULT; -+ tmp[len-1] =3D '\0'; -+ rtmp->rolename =3D tmp; ++ curr =3D &acl_role_set.r_hash[index]; + -+ if (!rlast) { -+ rtmp->prev =3D NULL; -+ rolep->transitions =3D rtmp; -+ } else { -+ rlast->next =3D rtmp; -+ rtmp->prev =3D rlast; -+ } ++ /* if role was already inserted due to domains and already has ++ a role in the same bucket as it attached, then we need to ++ combine these two buckets ++ */ ++ if (role->next) { ++ tmp =3D role->next; ++ while (tmp->next) ++ tmp =3D tmp->next; ++ tmp->next =3D *curr; ++ } else ++ role->next =3D *curr; ++ *curr =3D role; + -+ if (!rusertp) -+ rtmp->next =3D NULL; ++ return; ++} ++ ++static void ++insert_acl_role_label(struct acl_role_label *role) ++{ ++ int i; ++ ++ if (role_list =3D=3D NULL) { ++ role_list =3D role; ++ role->prev =3D NULL; ++ } else { ++ role->prev =3D role_list; ++ role_list =3D role; + } ++=09 ++ /* used for hash chains */ ++ role->next =3D NULL; + -+ return 0; ++ if (role->roletype & GR_ROLE_DOMAIN) { ++ for (i =3D 0; i < role->domain_child_num; i++) ++ __insert_acl_role_label(role, role->domain_children[i]); ++ } else ++ __insert_acl_role_label(role, role->uidgid); +} -+ -+static struct acl_subject_label * -+do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role) ++ =09 ++static int ++insert_name_entry(char *name, const ino_t inode, const dev_t device, __= u8 deleted) +{ -+ struct acl_subject_label *s_tmp =3D NULL, *s_tmp2; -+ unsigned int len; -+ char *tmp; -+ __u32 num_objs; -+ struct acl_ip_label **i_tmp, *i_utmp2; -+ struct gr_hash_struct ghash; -+ struct subject_map *subjmap; -+ unsigned int i_num; -+ int err; ++ struct name_entry **curr, *nentry; ++ struct inodev_entry *ientry; ++ unsigned int len =3D strlen(name); ++ unsigned int key =3D full_name_hash(name, len); ++ unsigned int index =3D key % name_set.n_size; + -+ s_tmp =3D lookup_subject_map(userp); ++ curr =3D &name_set.n_hash[index]; + -+ /* we've already copied this subject into the kernel, just return -+ the reference to it, and don't copy it over again -+ */ -+ if (s_tmp) -+ return(s_tmp); ++ while (*curr && ((*curr)->key !=3D key || !gr_streq((*curr)->name, nam= e, (*curr)->len, len))) ++ curr =3D &((*curr)->next); + -+ if ((s_tmp =3D (struct acl_subject_label *) -+ acl_alloc(sizeof (struct acl_subject_label))) =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); ++ if (*curr !=3D NULL) ++ return 1; + -+ subjmap =3D (struct subject_map *)kmalloc(sizeof (struct subject_map),= GFP_KERNEL); -+ if (subjmap =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); ++ nentry =3D acl_alloc(sizeof (struct name_entry)); ++ if (nentry =3D=3D NULL) ++ return 0; ++ ientry =3D acl_alloc(sizeof (struct inodev_entry)); ++ if (ientry =3D=3D NULL) ++ return 0; ++ ientry->nentry =3D nentry; + -+ subjmap->user =3D userp; -+ subjmap->kernel =3D s_tmp; -+ insert_subj_map_entry(subjmap); ++ nentry->key =3D key; ++ nentry->name =3D name; ++ nentry->inode =3D inode; ++ nentry->device =3D device; ++ nentry->len =3D len; ++ nentry->deleted =3D deleted; + -+ if (copy_from_user(s_tmp, userp, -+ sizeof (struct acl_subject_label))) -+ return ERR_PTR(-EFAULT); ++ nentry->prev =3D NULL; ++ curr =3D &name_set.n_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D nentry; ++ nentry->next =3D *curr; ++ *curr =3D nentry; + -+ len =3D strnlen_user(s_tmp->filename, PATH_MAX); ++ /* insert us into the table searchable by inode/dev */ ++ insert_inodev_entry(ientry); + -+ if (!len || len >=3D PATH_MAX) -+ return ERR_PTR(-EINVAL); ++ return 1; ++} + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); ++static void ++insert_acl_obj_label(struct acl_object_label *obj, ++ struct acl_subject_label *subj) ++{ ++ unsigned int index =3D ++ fhash(obj->inode, obj->device, subj->obj_hash_size); ++ struct acl_object_label **curr; + -+ if (copy_from_user(tmp, s_tmp->filename, len)) -+ return ERR_PTR(-EFAULT); -+ tmp[len-1] =3D '\0'; -+ s_tmp->filename =3D tmp; ++=09 ++ obj->prev =3D NULL; + -+ if (!strcmp(s_tmp->filename, "/")) -+ role->root_label =3D s_tmp; ++ curr =3D &subj->obj_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D obj; + -+ if (copy_from_user(&ghash, s_tmp->hash, sizeof(struct gr_hash_struct))= ) -+ return ERR_PTR(-EFAULT); ++ obj->next =3D *curr; ++ *curr =3D obj; + -+ /* copy user and group transition tables */ ++ return; ++} + -+ if (s_tmp->user_trans_num) { -+ uid_t *uidlist; ++static void ++insert_acl_subj_label(struct acl_subject_label *obj, ++ struct acl_role_label *role) ++{ ++ unsigned int index =3D fhash(obj->inode, obj->device, role->subj_hash_= size); ++ struct acl_subject_label **curr; + -+ uidlist =3D (uid_t *)acl_alloc_num(s_tmp->user_trans_num, sizeof(uid_= t)); -+ if (uidlist =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); -+ if (copy_from_user(uidlist, s_tmp->user_transitions, s_tmp->user_tran= s_num * sizeof(uid_t))) -+ return ERR_PTR(-EFAULT); ++ obj->prev =3D NULL; + -+ s_tmp->user_transitions =3D uidlist; -+ } ++ curr =3D &role->subj_hash[index]; ++ if (*curr !=3D NULL) ++ (*curr)->prev =3D obj; + -+ if (s_tmp->group_trans_num) { -+ gid_t *gidlist; ++ obj->next =3D *curr; ++ *curr =3D obj; + -+ gidlist =3D (gid_t *)acl_alloc_num(s_tmp->group_trans_num, sizeof(gid= _t)); -+ if (gidlist =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); -+ if (copy_from_user(gidlist, s_tmp->group_transitions, s_tmp->group_tr= ans_num * sizeof(gid_t))) -+ return ERR_PTR(-EFAULT); ++ return; ++} + -+ s_tmp->group_transitions =3D gidlist; -+ } ++/* allocating chained hash tables, so optimal size is where lambda ~ 1 = */ + -+ /* set up object hash table */ -+ num_objs =3D count_user_objs(ghash.first); ++static void * ++create_table(__u32 * len, int elementsize) ++{ ++ unsigned int table_sizes[] =3D { ++ 7, 13, 31, 61, 127, 251, 509, 1021, 2039, 4093, 8191, 16381, ++ 32749, 65521, 131071, 262139, 524287, 1048573, 2097143, ++ 4194301, 8388593, 16777213, 33554393, 67108859 ++ }; ++ void *newtable =3D NULL; ++ unsigned int pwr =3D 0; + -+ s_tmp->obj_hash_size =3D num_objs; -+ s_tmp->obj_hash =3D -+ (struct acl_object_label **) -+ create_table(&(s_tmp->obj_hash_size), sizeof(void *)); ++ while ((pwr < ((sizeof (table_sizes) / sizeof (table_sizes[0])) - 1)) = && ++ table_sizes[pwr] <=3D *len) ++ pwr++; + -+ if (!s_tmp->obj_hash) -+ return ERR_PTR(-ENOMEM); ++ if (table_sizes[pwr] <=3D *len || (table_sizes[pwr] > ULONG_MAX / elem= entsize)) ++ return newtable; + -+ memset(s_tmp->obj_hash, 0, -+ s_tmp->obj_hash_size * -+ sizeof (struct acl_object_label *)); ++ if ((table_sizes[pwr] * elementsize) <=3D PAGE_SIZE) ++ newtable =3D ++ kmalloc(table_sizes[pwr] * elementsize, GFP_KERNEL); ++ else ++ newtable =3D vmalloc(table_sizes[pwr] * elementsize); + -+ /* add in objects */ -+ err =3D copy_user_objs(ghash.first, s_tmp, role); ++ *len =3D table_sizes[pwr]; + -+ if (err) -+ return ERR_PTR(err); ++ return newtable; ++} + -+ /* set pointer for parent subject */ -+ if (s_tmp->parent_subject) { -+ s_tmp2 =3D do_copy_user_subj(s_tmp->parent_subject, role); ++static int ++init_variables(const struct gr_arg *arg) ++{ ++ struct task_struct *reaper =3D &init_task; ++ unsigned int stacksize; + -+ if (IS_ERR(s_tmp2)) -+ return s_tmp2; ++ subj_map_set.s_size =3D arg->role_db.num_subjects; ++ acl_role_set.r_size =3D arg->role_db.num_roles + arg->role_db.num_doma= in_children; ++ name_set.n_size =3D arg->role_db.num_objects; ++ inodev_set.i_size =3D arg->role_db.num_objects; + -+ s_tmp->parent_subject =3D s_tmp2; -+ } ++ if (!subj_map_set.s_size || !acl_role_set.r_size || ++ !name_set.n_size || !inodev_set.i_size) ++ return 1; + -+ /* add in ip acls */ ++ if (!gr_init_uidset()) ++ return 1; + -+ if (!s_tmp->ip_num) { -+ s_tmp->ips =3D NULL; -+ goto insert; -+ } ++ /* set up the stack that holds allocation info */ + -+ i_tmp =3D -+ (struct acl_ip_label **) acl_alloc_num(s_tmp->ip_num, -+ sizeof (struct acl_ip_label *)); ++ stacksize =3D arg->role_db.num_pointers + 5; + -+ if (!i_tmp) -+ return ERR_PTR(-ENOMEM); ++ if (!acl_alloc_stack_init(stacksize)) ++ return 1; + -+ for (i_num =3D 0; i_num < s_tmp->ip_num; i_num++) { -+ *(i_tmp + i_num) =3D -+ (struct acl_ip_label *) -+ acl_alloc(sizeof (struct acl_ip_label)); -+ if (!*(i_tmp + i_num)) -+ return ERR_PTR(-ENOMEM); ++ /* grab reference for the real root dentry and vfsmount */ ++ get_fs_root(reaper->fs, &real_root); ++=09 ++#ifdef CONFIG_GRKERNSEC_RBAC_DEBUG ++ printk(KERN_ALERT "Obtained real root device=3D%d, inode=3D%lu\n", __g= et_dev(real_root.dentry), real_root.dentry->d_inode->i_ino); ++#endif + -+ if (copy_from_user -+ (&i_utmp2, s_tmp->ips + i_num, -+ sizeof (struct acl_ip_label *))) -+ return ERR_PTR(-EFAULT); ++ fakefs_obj_rw =3D acl_alloc(sizeof(struct acl_object_label)); ++ if (fakefs_obj_rw =3D=3D NULL) ++ return 1; ++ fakefs_obj_rw->mode =3D GR_FIND | GR_READ | GR_WRITE; + -+ if (copy_from_user -+ (*(i_tmp + i_num), i_utmp2, -+ sizeof (struct acl_ip_label))) -+ return ERR_PTR(-EFAULT); -+ =09 -+ if ((*(i_tmp + i_num))->iface =3D=3D NULL) -+ continue; ++ fakefs_obj_rwx =3D acl_alloc(sizeof(struct acl_object_label)); ++ if (fakefs_obj_rwx =3D=3D NULL) ++ return 1; ++ fakefs_obj_rwx->mode =3D GR_FIND | GR_READ | GR_WRITE | GR_EXEC; + -+ len =3D strnlen_user((*(i_tmp + i_num))->iface, IFNAMSIZ); -+ if (!len || len >=3D IFNAMSIZ) -+ return ERR_PTR(-EINVAL); -+ tmp =3D acl_alloc(len); -+ if (tmp =3D=3D NULL) -+ return ERR_PTR(-ENOMEM); -+ if (copy_from_user(tmp, (*(i_tmp + i_num))->iface, len)) -+ return ERR_PTR(-EFAULT); -+ (*(i_tmp + i_num))->iface =3D tmp; -+ } ++ subj_map_set.s_hash =3D ++ (struct subject_map **) create_table(&subj_map_set.s_size, sizeof(= void *)); ++ acl_role_set.r_hash =3D ++ (struct acl_role_label **) create_table(&acl_role_set.r_size, size= of(void *)); ++ name_set.n_hash =3D (struct name_entry **) create_table(&name_set.n_si= ze, sizeof(void *)); ++ inodev_set.i_hash =3D ++ (struct inodev_entry **) create_table(&inodev_set.i_size, sizeof(v= oid *)); + -+ s_tmp->ips =3D i_tmp; ++ if (!subj_map_set.s_hash || !acl_role_set.r_hash || ++ !name_set.n_hash || !inodev_set.i_hash) ++ return 1; + -+insert: -+ if (!insert_name_entry(s_tmp->filename, s_tmp->inode, -+ s_tmp->device, (s_tmp->mode & GR_DELETED) ? 1 : 0)) -+ return ERR_PTR(-ENOMEM); ++ memset(subj_map_set.s_hash, 0, ++ sizeof(struct subject_map *) * subj_map_set.s_size); ++ memset(acl_role_set.r_hash, 0, ++ sizeof (struct acl_role_label *) * acl_role_set.r_size); ++ memset(name_set.n_hash, 0, ++ sizeof (struct name_entry *) * name_set.n_size); ++ memset(inodev_set.i_hash, 0, ++ sizeof (struct inodev_entry *) * inodev_set.i_size); + -+ return s_tmp; ++ return 0; +} + -+static int -+copy_user_subjs(struct acl_subject_label *userp, struct acl_role_label = *role) -+{ -+ struct acl_subject_label s_pre; -+ struct acl_subject_label * ret; -+ int err; ++/* free information not needed after startup ++ currently contains user->kernel pointer mappings for subjects ++*/ + -+ while (userp) { -+ if (copy_from_user(&s_pre, userp, -+ sizeof (struct acl_subject_label))) -+ return -EFAULT; -+ =09 -+ /* do not add nested subjects here, add -+ while parsing objects -+ */ ++static void ++free_init_variables(void) ++{ ++ __u32 i; + -+ if (s_pre.mode & GR_NESTED) { -+ userp =3D s_pre.prev; -+ continue; ++ if (subj_map_set.s_hash) { ++ for (i =3D 0; i < subj_map_set.s_size; i++) { ++ if (subj_map_set.s_hash[i]) { ++ kfree(subj_map_set.s_hash[i]); ++ subj_map_set.s_hash[i] =3D NULL; ++ } + } + -+ ret =3D do_copy_user_subj(userp, role); -+ -+ err =3D PTR_ERR(ret); -+ if (IS_ERR(ret)) -+ return err; -+ -+ insert_acl_subj_label(ret, role); -+ -+ userp =3D s_pre.prev; ++ if ((subj_map_set.s_size * sizeof (struct subject_map *)) <=3D ++ PAGE_SIZE) ++ kfree(subj_map_set.s_hash); ++ else ++ vfree(subj_map_set.s_hash); + } + -+ return 0; ++ return; +} + -+static int -+copy_user_acl(struct gr_arg *arg) ++static void ++free_variables(void) +{ -+ struct acl_role_label *r_tmp =3D NULL, **r_utmp, *r_utmp2; -+ struct sprole_pw *sptmp; -+ struct gr_hash_struct *ghash; -+ uid_t *domainlist; -+ unsigned int r_num; -+ unsigned int len; -+ char *tmp; -+ int err =3D 0; -+ __u16 i; -+ __u32 num_subjs; ++ struct acl_subject_label *s; ++ struct acl_role_label *r; ++ struct task_struct *task, *task2; ++ unsigned int x; + -+ /* we need a default and kernel role */ -+ if (arg->role_db.num_roles < 2) -+ return -EINVAL; ++ gr_clear_learn_entries(); + -+ /* copy special role authentication info from userspace */ ++ read_lock(&tasklist_lock); ++ do_each_thread(task2, task) { ++ task->acl_sp_role =3D 0; ++ task->acl_role_id =3D 0; ++ task->acl =3D NULL; ++ task->role =3D NULL; ++ } while_each_thread(task2, task); ++ read_unlock(&tasklist_lock); + -+ num_sprole_pws =3D arg->num_sprole_pws; -+ acl_special_roles =3D (struct sprole_pw **) acl_alloc_num(num_sprole_p= ws, sizeof(struct sprole_pw *)); ++ /* release the reference to the real root dentry and vfsmount */ ++ path_put(&real_root); + -+ if (!acl_special_roles) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } ++ /* free all object hash tables */ + -+ for (i =3D 0; i < num_sprole_pws; i++) { -+ sptmp =3D (struct sprole_pw *) acl_alloc(sizeof(struct sprole_pw)); -+ if (!sptmp) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } -+ if (copy_from_user(sptmp, arg->sprole_pws + i, -+ sizeof (struct sprole_pw))) { -+ err =3D -EFAULT; -+ goto cleanup; -+ } ++ FOR_EACH_ROLE_START(r) ++ if (r->subj_hash =3D=3D NULL) ++ goto next_role; ++ FOR_EACH_SUBJECT_START(r, s, x) ++ if (s->obj_hash =3D=3D NULL) ++ break; ++ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) ++ kfree(s->obj_hash); ++ else ++ vfree(s->obj_hash); ++ FOR_EACH_SUBJECT_END(s, x) ++ FOR_EACH_NESTED_SUBJECT_START(r, s) ++ if (s->obj_hash =3D=3D NULL) ++ break; ++ if ((s->obj_hash_size * sizeof (struct acl_object_label *)) <=3D PAG= E_SIZE) ++ kfree(s->obj_hash); ++ else ++ vfree(s->obj_hash); ++ FOR_EACH_NESTED_SUBJECT_END(s) ++ if ((r->subj_hash_size * sizeof (struct acl_subject_label *)) <=3D PA= GE_SIZE) ++ kfree(r->subj_hash); ++ else ++ vfree(r->subj_hash); ++ r->subj_hash =3D NULL; ++next_role: ++ FOR_EACH_ROLE_END(r) + -+ len =3D -+ strnlen_user(sptmp->rolename, GR_SPROLE_LEN); ++ acl_free_all(); + -+ if (!len || len >=3D GR_SPROLE_LEN) { -+ err =3D -EINVAL; -+ goto cleanup; -+ } ++ if (acl_role_set.r_hash) { ++ if ((acl_role_set.r_size * sizeof (struct acl_role_label *)) <=3D ++ PAGE_SIZE) ++ kfree(acl_role_set.r_hash); ++ else ++ vfree(acl_role_set.r_hash); ++ } ++ if (name_set.n_hash) { ++ if ((name_set.n_size * sizeof (struct name_entry *)) <=3D ++ PAGE_SIZE) ++ kfree(name_set.n_hash); ++ else ++ vfree(name_set.n_hash); ++ } + -+ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) { -+ err =3D -ENOMEM; -+ goto cleanup; -+ } ++ if (inodev_set.i_hash) { ++ if ((inodev_set.i_size * sizeof (struct inodev_entry *)) <=3D ++ PAGE_SIZE) ++ kfree(inodev_set.i_hash); ++ else ++ vfree(inodev_set.i_hash); ++ } ++ ++ gr_free_uidset(); ++ ++ memset(&name_set, 0, sizeof (struct name_db)); ++ memset(&inodev_set, 0, sizeof (struct inodev_db)); ++ memset(&acl_role_set, 0, sizeof (struct acl_role_db)); ++ memset(&subj_map_set, 0, sizeof (struct acl_subj_map_db)); ++ ++ default_role =3D NULL; ++ role_list =3D NULL; ++ ++ return; ++} ++ ++static __u32 ++count_user_objs(struct acl_object_label *userp) ++{ ++ struct acl_object_label o_tmp; ++ __u32 num =3D 0; ++ ++ while (userp) { ++ if (copy_from_user(&o_tmp, userp, ++ sizeof (struct acl_object_label))) ++ break; ++ ++ userp =3D o_tmp.prev; ++ num++; ++ } ++ ++ return num; ++} ++ ++static struct acl_subject_label * ++do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role); ++ ++static int ++copy_user_glob(struct acl_object_label *obj) ++{ ++ struct acl_object_label *g_tmp, **guser; ++ unsigned int len; ++ char *tmp; ++ ++ if (obj->globbed =3D=3D NULL) ++ return 0; ++ ++ guser =3D &obj->globbed; ++ while (*guser) { ++ g_tmp =3D (struct acl_object_label *) ++ acl_alloc(sizeof (struct acl_object_label)); ++ if (g_tmp =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(g_tmp, *guser, ++ sizeof (struct acl_object_label))) ++ return -EFAULT; ++ ++ len =3D strnlen_user(g_tmp->filename, PATH_MAX); ++ ++ if (!len || len >=3D PATH_MAX) ++ return -EINVAL; ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(tmp, g_tmp->filename, len)) ++ return -EFAULT; ++ tmp[len-1] =3D '\0'; ++ g_tmp->filename =3D tmp; ++ ++ *guser =3D g_tmp; ++ guser =3D &(g_tmp->next); ++ } ++ ++ return 0; ++} ++ ++static int ++copy_user_objs(struct acl_object_label *userp, struct acl_subject_label= *subj, ++ struct acl_role_label *role) ++{ ++ struct acl_object_label *o_tmp; ++ unsigned int len; ++ int ret; ++ char *tmp; ++ ++ while (userp) { ++ if ((o_tmp =3D (struct acl_object_label *) ++ acl_alloc(sizeof (struct acl_object_label))) =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(o_tmp, userp, ++ sizeof (struct acl_object_label))) ++ return -EFAULT; ++ ++ userp =3D o_tmp->prev; ++ ++ len =3D strnlen_user(o_tmp->filename, PATH_MAX); ++ ++ if (!len || len >=3D PATH_MAX) ++ return -EINVAL; ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(tmp, o_tmp->filename, len)) ++ return -EFAULT; ++ tmp[len-1] =3D '\0'; ++ o_tmp->filename =3D tmp; ++ ++ insert_acl_obj_label(o_tmp, subj); ++ if (!insert_name_entry(o_tmp->filename, o_tmp->inode, ++ o_tmp->device, (o_tmp->mode & GR_DELETED) ? 1 : 0)) ++ return -ENOMEM; ++ ++ ret =3D copy_user_glob(o_tmp); ++ if (ret) ++ return ret; ++ ++ if (o_tmp->nested) { ++ o_tmp->nested =3D do_copy_user_subj(o_tmp->nested, role); ++ if (IS_ERR(o_tmp->nested)) ++ return PTR_ERR(o_tmp->nested); ++ ++ /* insert into nested subject list */ ++ o_tmp->nested->next =3D role->hash->first; ++ role->hash->first =3D o_tmp->nested; ++ } ++ } ++ ++ return 0; ++} ++ ++static __u32 ++count_user_subjs(struct acl_subject_label *userp) ++{ ++ struct acl_subject_label s_tmp; ++ __u32 num =3D 0; ++ ++ while (userp) { ++ if (copy_from_user(&s_tmp, userp, ++ sizeof (struct acl_subject_label))) ++ break; ++ ++ userp =3D s_tmp.prev; ++ /* do not count nested subjects against this count, since ++ they are not included in the hash table, but are ++ attached to objects. We have already counted ++ the subjects in userspace for the allocation=20 ++ stack ++ */ ++ if (!(s_tmp.mode & GR_NESTED)) ++ num++; ++ } ++ ++ return num; ++} ++ ++static int ++copy_user_allowedips(struct acl_role_label *rolep) ++{ ++ struct role_allowed_ip *ruserip, *rtmp =3D NULL, *rlast; ++ ++ ruserip =3D rolep->allowed_ips; ++ ++ while (ruserip) { ++ rlast =3D rtmp; ++ ++ if ((rtmp =3D (struct role_allowed_ip *) ++ acl_alloc(sizeof (struct role_allowed_ip))) =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(rtmp, ruserip, ++ sizeof (struct role_allowed_ip))) ++ return -EFAULT; ++ ++ ruserip =3D rtmp->prev; ++ ++ if (!rlast) { ++ rtmp->prev =3D NULL; ++ rolep->allowed_ips =3D rtmp; ++ } else { ++ rlast->next =3D rtmp; ++ rtmp->prev =3D rlast; ++ } ++ ++ if (!ruserip) ++ rtmp->next =3D NULL; ++ } ++ ++ return 0; ++} ++ ++static int ++copy_user_transitions(struct acl_role_label *rolep) ++{ ++ struct role_transition *rusertp, *rtmp =3D NULL, *rlast; ++=09 ++ unsigned int len; ++ char *tmp; ++ ++ rusertp =3D rolep->transitions; ++ ++ while (rusertp) { ++ rlast =3D rtmp; ++ ++ if ((rtmp =3D (struct role_transition *) ++ acl_alloc(sizeof (struct role_transition))) =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(rtmp, rusertp, ++ sizeof (struct role_transition))) ++ return -EFAULT; ++ ++ rusertp =3D rtmp->prev; ++ ++ len =3D strnlen_user(rtmp->rolename, GR_SPROLE_LEN); ++ ++ if (!len || len >=3D GR_SPROLE_LEN) ++ return -EINVAL; ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return -ENOMEM; ++ ++ if (copy_from_user(tmp, rtmp->rolename, len)) ++ return -EFAULT; ++ tmp[len-1] =3D '\0'; ++ rtmp->rolename =3D tmp; ++ ++ if (!rlast) { ++ rtmp->prev =3D NULL; ++ rolep->transitions =3D rtmp; ++ } else { ++ rlast->next =3D rtmp; ++ rtmp->prev =3D rlast; ++ } ++ ++ if (!rusertp) ++ rtmp->next =3D NULL; ++ } ++ ++ return 0; ++} ++ ++static struct acl_subject_label * ++do_copy_user_subj(struct acl_subject_label *userp, struct acl_role_labe= l *role) ++{ ++ struct acl_subject_label *s_tmp =3D NULL, *s_tmp2; ++ unsigned int len; ++ char *tmp; ++ __u32 num_objs; ++ struct acl_ip_label **i_tmp, *i_utmp2; ++ struct gr_hash_struct ghash; ++ struct subject_map *subjmap; ++ unsigned int i_num; ++ int err; ++ ++ s_tmp =3D lookup_subject_map(userp); ++ ++ /* we've already copied this subject into the kernel, just return ++ the reference to it, and don't copy it over again ++ */ ++ if (s_tmp) ++ return(s_tmp); ++ ++ if ((s_tmp =3D (struct acl_subject_label *) ++ acl_alloc(sizeof (struct acl_subject_label))) =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ ++ subjmap =3D (struct subject_map *)kmalloc(sizeof (struct subject_map),= GFP_KERNEL); ++ if (subjmap =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ ++ subjmap->user =3D userp; ++ subjmap->kernel =3D s_tmp; ++ insert_subj_map_entry(subjmap); ++ ++ if (copy_from_user(s_tmp, userp, ++ sizeof (struct acl_subject_label))) ++ return ERR_PTR(-EFAULT); ++ ++ len =3D strnlen_user(s_tmp->filename, PATH_MAX); ++ ++ if (!len || len >=3D PATH_MAX) ++ return ERR_PTR(-EINVAL); ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ ++ if (copy_from_user(tmp, s_tmp->filename, len)) ++ return ERR_PTR(-EFAULT); ++ tmp[len-1] =3D '\0'; ++ s_tmp->filename =3D tmp; ++ ++ if (!strcmp(s_tmp->filename, "/")) ++ role->root_label =3D s_tmp; ++ ++ if (copy_from_user(&ghash, s_tmp->hash, sizeof(struct gr_hash_struct))= ) ++ return ERR_PTR(-EFAULT); ++ ++ /* copy user and group transition tables */ ++ ++ if (s_tmp->user_trans_num) { ++ uid_t *uidlist; ++ ++ uidlist =3D (uid_t *)acl_alloc_num(s_tmp->user_trans_num, sizeof(uid_= t)); ++ if (uidlist =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ if (copy_from_user(uidlist, s_tmp->user_transitions, s_tmp->user_tran= s_num * sizeof(uid_t))) ++ return ERR_PTR(-EFAULT); ++ ++ s_tmp->user_transitions =3D uidlist; ++ } ++ ++ if (s_tmp->group_trans_num) { ++ gid_t *gidlist; ++ ++ gidlist =3D (gid_t *)acl_alloc_num(s_tmp->group_trans_num, sizeof(gid= _t)); ++ if (gidlist =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ if (copy_from_user(gidlist, s_tmp->group_transitions, s_tmp->group_tr= ans_num * sizeof(gid_t))) ++ return ERR_PTR(-EFAULT); ++ ++ s_tmp->group_transitions =3D gidlist; ++ } ++ ++ /* set up object hash table */ ++ num_objs =3D count_user_objs(ghash.first); ++ ++ s_tmp->obj_hash_size =3D num_objs; ++ s_tmp->obj_hash =3D ++ (struct acl_object_label **) ++ create_table(&(s_tmp->obj_hash_size), sizeof(void *)); ++ ++ if (!s_tmp->obj_hash) ++ return ERR_PTR(-ENOMEM); ++ ++ memset(s_tmp->obj_hash, 0, ++ s_tmp->obj_hash_size * ++ sizeof (struct acl_object_label *)); ++ ++ /* add in objects */ ++ err =3D copy_user_objs(ghash.first, s_tmp, role); ++ ++ if (err) ++ return ERR_PTR(err); ++ ++ /* set pointer for parent subject */ ++ if (s_tmp->parent_subject) { ++ s_tmp2 =3D do_copy_user_subj(s_tmp->parent_subject, role); ++ ++ if (IS_ERR(s_tmp2)) ++ return s_tmp2; ++ ++ s_tmp->parent_subject =3D s_tmp2; ++ } ++ ++ /* add in ip acls */ ++ ++ if (!s_tmp->ip_num) { ++ s_tmp->ips =3D NULL; ++ goto insert; ++ } ++ ++ i_tmp =3D ++ (struct acl_ip_label **) acl_alloc_num(s_tmp->ip_num, ++ sizeof (struct acl_ip_label *)); ++ ++ if (!i_tmp) ++ return ERR_PTR(-ENOMEM); ++ ++ for (i_num =3D 0; i_num < s_tmp->ip_num; i_num++) { ++ *(i_tmp + i_num) =3D ++ (struct acl_ip_label *) ++ acl_alloc(sizeof (struct acl_ip_label)); ++ if (!*(i_tmp + i_num)) ++ return ERR_PTR(-ENOMEM); ++ ++ if (copy_from_user ++ (&i_utmp2, s_tmp->ips + i_num, ++ sizeof (struct acl_ip_label *))) ++ return ERR_PTR(-EFAULT); ++ ++ if (copy_from_user ++ (*(i_tmp + i_num), i_utmp2, ++ sizeof (struct acl_ip_label))) ++ return ERR_PTR(-EFAULT); ++ =09 ++ if ((*(i_tmp + i_num))->iface =3D=3D NULL) ++ continue; ++ ++ len =3D strnlen_user((*(i_tmp + i_num))->iface, IFNAMSIZ); ++ if (!len || len >=3D IFNAMSIZ) ++ return ERR_PTR(-EINVAL); ++ tmp =3D acl_alloc(len); ++ if (tmp =3D=3D NULL) ++ return ERR_PTR(-ENOMEM); ++ if (copy_from_user(tmp, (*(i_tmp + i_num))->iface, len)) ++ return ERR_PTR(-EFAULT); ++ (*(i_tmp + i_num))->iface =3D tmp; ++ } ++ ++ s_tmp->ips =3D i_tmp; ++ ++insert: ++ if (!insert_name_entry(s_tmp->filename, s_tmp->inode, ++ s_tmp->device, (s_tmp->mode & GR_DELETED) ? 1 : 0)) ++ return ERR_PTR(-ENOMEM); ++ ++ return s_tmp; ++} ++ ++static int ++copy_user_subjs(struct acl_subject_label *userp, struct acl_role_label = *role) ++{ ++ struct acl_subject_label s_pre; ++ struct acl_subject_label * ret; ++ int err; ++ ++ while (userp) { ++ if (copy_from_user(&s_pre, userp, ++ sizeof (struct acl_subject_label))) ++ return -EFAULT; ++ =09 ++ /* do not add nested subjects here, add ++ while parsing objects ++ */ ++ ++ if (s_pre.mode & GR_NESTED) { ++ userp =3D s_pre.prev; ++ continue; ++ } ++ ++ ret =3D do_copy_user_subj(userp, role); ++ ++ err =3D PTR_ERR(ret); ++ if (IS_ERR(ret)) ++ return err; ++ ++ insert_acl_subj_label(ret, role); ++ ++ userp =3D s_pre.prev; ++ } ++ ++ return 0; ++} ++ ++static int ++copy_user_acl(struct gr_arg *arg) ++{ ++ struct acl_role_label *r_tmp =3D NULL, **r_utmp, *r_utmp2; ++ struct sprole_pw *sptmp; ++ struct gr_hash_struct *ghash; ++ uid_t *domainlist; ++ unsigned int r_num; ++ unsigned int len; ++ char *tmp; ++ int err =3D 0; ++ __u16 i; ++ __u32 num_subjs; ++ ++ /* we need a default and kernel role */ ++ if (arg->role_db.num_roles < 2) ++ return -EINVAL; ++ ++ /* copy special role authentication info from userspace */ ++ ++ num_sprole_pws =3D arg->num_sprole_pws; ++ acl_special_roles =3D (struct sprole_pw **) acl_alloc_num(num_sprole_p= ws, sizeof(struct sprole_pw *)); ++ ++ if (!acl_special_roles) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ ++ for (i =3D 0; i < num_sprole_pws; i++) { ++ sptmp =3D (struct sprole_pw *) acl_alloc(sizeof(struct sprole_pw)); ++ if (!sptmp) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } ++ if (copy_from_user(sptmp, arg->sprole_pws + i, ++ sizeof (struct sprole_pw))) { ++ err =3D -EFAULT; ++ goto cleanup; ++ } ++ ++ len =3D ++ strnlen_user(sptmp->rolename, GR_SPROLE_LEN); ++ ++ if (!len || len >=3D GR_SPROLE_LEN) { ++ err =3D -EINVAL; ++ goto cleanup; ++ } ++ ++ if ((tmp =3D (char *) acl_alloc(len)) =3D=3D NULL) { ++ err =3D -ENOMEM; ++ goto cleanup; ++ } + + if (copy_from_user(tmp, sptmp->rolename, len)) { + err =3D -EFAULT; @@ -52365,9 +54716,122 @@ diff -urNp linux-3.1.4/grsecurity/gracl.c linux= -3.1.4/grsecurity/gracl.c +EXPORT_SYMBOL(gr_check_group_change); +#endif + -diff -urNp linux-3.1.4/grsecurity/gracl_cap.c linux-3.1.4/grsecurity/gra= cl_cap.c ---- linux-3.1.4/grsecurity/gracl_cap.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/gracl_cap.c 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/grsecurity/gracl_alloc.c b/grsecurity/gracl_alloc.c +new file mode 100644 +index 0000000..34fefda +--- /dev/null ++++ b/grsecurity/gracl_alloc.c +@@ -0,0 +1,105 @@ ++#include ++#include ++#include ++#include ++#include ++#include ++ ++static unsigned long alloc_stack_next =3D 1; ++static unsigned long alloc_stack_size =3D 1; ++static void **alloc_stack; ++ ++static __inline__ int ++alloc_pop(void) ++{ ++ if (alloc_stack_next =3D=3D 1) ++ return 0; ++ ++ kfree(alloc_stack[alloc_stack_next - 2]); ++ ++ alloc_stack_next--; ++ ++ return 1; ++} ++ ++static __inline__ int ++alloc_push(void *buf) ++{ ++ if (alloc_stack_next >=3D alloc_stack_size) ++ return 1; ++ ++ alloc_stack[alloc_stack_next - 1] =3D buf; ++ ++ alloc_stack_next++; ++ ++ return 0; ++} ++ ++void * ++acl_alloc(unsigned long len) ++{ ++ void *ret =3D NULL; ++ ++ if (!len || len > PAGE_SIZE) ++ goto out; ++ ++ ret =3D kmalloc(len, GFP_KERNEL); ++ ++ if (ret) { ++ if (alloc_push(ret)) { ++ kfree(ret); ++ ret =3D NULL; ++ } ++ } ++ ++out: ++ return ret; ++} ++ ++void * ++acl_alloc_num(unsigned long num, unsigned long len) ++{ ++ if (!len || (num > (PAGE_SIZE / len))) ++ return NULL; ++ ++ return acl_alloc(num * len); ++} ++ ++void ++acl_free_all(void) ++{ ++ if (gr_acl_is_enabled() || !alloc_stack) ++ return; ++ ++ while (alloc_pop()) ; ++ ++ if (alloc_stack) { ++ if ((alloc_stack_size * sizeof (void *)) <=3D PAGE_SIZE) ++ kfree(alloc_stack); ++ else ++ vfree(alloc_stack); ++ } ++ ++ alloc_stack =3D NULL; ++ alloc_stack_size =3D 1; ++ alloc_stack_next =3D 1; ++ ++ return; ++} ++ ++int ++acl_alloc_stack_init(unsigned long size) ++{ ++ if ((size * sizeof (void *)) <=3D PAGE_SIZE) ++ alloc_stack =3D ++ (void **) kmalloc(size * sizeof (void *), GFP_KERNEL); ++ else ++ alloc_stack =3D (void **) vmalloc(size * sizeof (void *)); ++ ++ alloc_stack_size =3D size; ++ ++ if (!alloc_stack) ++ return 0; ++ else ++ return 1; ++} +diff --git a/grsecurity/gracl_cap.c b/grsecurity/gracl_cap.c +new file mode 100644 +index 0000000..955ddfb +--- /dev/null ++++ b/grsecurity/gracl_cap.c @@ -0,0 +1,101 @@ +#include +#include @@ -52470,9 +54934,11 @@ diff -urNp linux-3.1.4/grsecurity/gracl_cap.c li= nux-3.1.4/grsecurity/gracl_cap.c + return 0; +} + -diff -urNp linux-3.1.4/grsecurity/gracl_fs.c linux-3.1.4/grsecurity/grac= l_fs.c ---- linux-3.1.4/grsecurity/gracl_fs.c 1969-12-31 19:00:00.000000000 -050= 0 -+++ linux-3.1.4/grsecurity/gracl_fs.c 2011-11-17 00:25:32.000000000 -050= 0 +diff --git a/grsecurity/gracl_fs.c b/grsecurity/gracl_fs.c +new file mode 100644 +index 0000000..4eda5c3 +--- /dev/null ++++ b/grsecurity/gracl_fs.c @@ -0,0 +1,433 @@ +#include +#include @@ -52907,9 +55373,11 @@ diff -urNp linux-3.1.4/grsecurity/gracl_fs.c lin= ux-3.1.4/grsecurity/gracl_fs.c + + return 0; +} -diff -urNp linux-3.1.4/grsecurity/gracl_ip.c linux-3.1.4/grsecurity/grac= l_ip.c ---- linux-3.1.4/grsecurity/gracl_ip.c 1969-12-31 19:00:00.000000000 -050= 0 -+++ linux-3.1.4/grsecurity/gracl_ip.c 2011-11-16 18:40:31.000000000 -050= 0 +diff --git a/grsecurity/gracl_ip.c b/grsecurity/gracl_ip.c +new file mode 100644 +index 0000000..17050ca +--- /dev/null ++++ b/grsecurity/gracl_ip.c @@ -0,0 +1,381 @@ +#include +#include @@ -53292,9 +55760,11 @@ diff -urNp linux-3.1.4/grsecurity/gracl_ip.c lin= ux-3.1.4/grsecurity/gracl_ip.c + + return gr_search_connectbind(GR_CONNECT | GR_CONNECTOVERRIDE, sk, &sin= , SOCK_DGRAM); +} -diff -urNp linux-3.1.4/grsecurity/gracl_learn.c linux-3.1.4/grsecurity/g= racl_learn.c ---- linux-3.1.4/grsecurity/gracl_learn.c 1969-12-31 19:00:00.000000000 -= 0500 -+++ linux-3.1.4/grsecurity/gracl_learn.c 2011-11-16 18:40:31.000000000 -= 0500 +diff --git a/grsecurity/gracl_learn.c b/grsecurity/gracl_learn.c +new file mode 100644 +index 0000000..25f54ef +--- /dev/null ++++ b/grsecurity/gracl_learn.c @@ -0,0 +1,207 @@ +#include +#include @@ -53503,9 +55973,11 @@ diff -urNp linux-3.1.4/grsecurity/gracl_learn.c = linux-3.1.4/grsecurity/gracl_lea + .release =3D close_learn, + .poll =3D poll_learn, +}; -diff -urNp linux-3.1.4/grsecurity/gracl_res.c linux-3.1.4/grsecurity/gra= cl_res.c ---- linux-3.1.4/grsecurity/gracl_res.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/gracl_res.c 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/grsecurity/gracl_res.c b/grsecurity/gracl_res.c +new file mode 100644 +index 0000000..39645c9 +--- /dev/null ++++ b/grsecurity/gracl_res.c @@ -0,0 +1,68 @@ +#include +#include @@ -53575,9 +56047,11 @@ diff -urNp linux-3.1.4/grsecurity/gracl_res.c li= nux-3.1.4/grsecurity/gracl_res.c + rcu_read_unlock(); + return; +} -diff -urNp linux-3.1.4/grsecurity/gracl_segv.c linux-3.1.4/grsecurity/gr= acl_segv.c ---- linux-3.1.4/grsecurity/gracl_segv.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/gracl_segv.c 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/grsecurity/gracl_segv.c b/grsecurity/gracl_segv.c +new file mode 100644 +index 0000000..5556be3 +--- /dev/null ++++ b/grsecurity/gracl_segv.c @@ -0,0 +1,299 @@ +#include +#include @@ -53878,9 +56352,11 @@ diff -urNp linux-3.1.4/grsecurity/gracl_segv.c l= inux-3.1.4/grsecurity/gracl_segv + + return; +} -diff -urNp linux-3.1.4/grsecurity/gracl_shm.c linux-3.1.4/grsecurity/gra= cl_shm.c ---- linux-3.1.4/grsecurity/gracl_shm.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/gracl_shm.c 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/grsecurity/gracl_shm.c b/grsecurity/gracl_shm.c +new file mode 100644 +index 0000000..9d83a69 +--- /dev/null ++++ b/grsecurity/gracl_shm.c @@ -0,0 +1,40 @@ +#include +#include @@ -53922,9 +56398,11 @@ diff -urNp linux-3.1.4/grsecurity/gracl_shm.c li= nux-3.1.4/grsecurity/gracl_shm.c + + return 1; +} -diff -urNp linux-3.1.4/grsecurity/grsec_chdir.c linux-3.1.4/grsecurity/g= rsec_chdir.c ---- linux-3.1.4/grsecurity/grsec_chdir.c 1969-12-31 19:00:00.000000000 -= 0500 -+++ linux-3.1.4/grsecurity/grsec_chdir.c 2011-11-16 18:40:31.000000000 -= 0500 +diff --git a/grsecurity/grsec_chdir.c b/grsecurity/grsec_chdir.c +new file mode 100644 +index 0000000..bc0be01 +--- /dev/null ++++ b/grsecurity/grsec_chdir.c @@ -0,0 +1,19 @@ +#include +#include @@ -53945,9 +56423,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_chdir.c = linux-3.1.4/grsecurity/grsec_chd +#endif + return; +} -diff -urNp linux-3.1.4/grsecurity/grsec_chroot.c linux-3.1.4/grsecurity/= grsec_chroot.c ---- linux-3.1.4/grsecurity/grsec_chroot.c 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-3.1.4/grsecurity/grsec_chroot.c 2011-11-16 18:40:31.000000000 = -0500 +diff --git a/grsecurity/grsec_chroot.c b/grsecurity/grsec_chroot.c +new file mode 100644 +index 0000000..a2dc675 +--- /dev/null ++++ b/grsecurity/grsec_chroot.c @@ -0,0 +1,351 @@ +#include +#include @@ -54300,9 +56780,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_chroot.c= linux-3.1.4/grsecurity/grsec_ch +#endif + return 0; +} -diff -urNp linux-3.1.4/grsecurity/grsec_disabled.c linux-3.1.4/grsecurit= y/grsec_disabled.c ---- linux-3.1.4/grsecurity/grsec_disabled.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-3.1.4/grsecurity/grsec_disabled.c 2011-11-17 00:16:25.00000000= 0 -0500 +diff --git a/grsecurity/grsec_disabled.c b/grsecurity/grsec_disabled.c +new file mode 100644 +index 0000000..d81a586 +--- /dev/null ++++ b/grsecurity/grsec_disabled.c @@ -0,0 +1,439 @@ +#include +#include @@ -54743,9 +57225,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_disabled= .c linux-3.1.4/grsecurity/grsec_ +EXPORT_SYMBOL(gr_check_user_change); +EXPORT_SYMBOL(gr_check_group_change); +#endif -diff -urNp linux-3.1.4/grsecurity/grsec_exec.c linux-3.1.4/grsecurity/gr= sec_exec.c ---- linux-3.1.4/grsecurity/grsec_exec.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/grsec_exec.c 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/grsecurity/grsec_exec.c b/grsecurity/grsec_exec.c +new file mode 100644 +index 0000000..2b05ada +--- /dev/null ++++ b/grsecurity/grsec_exec.c @@ -0,0 +1,146 @@ +#include +#include @@ -54893,9 +57377,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_exec.c l= inux-3.1.4/grsecurity/grsec_exec + +EXPORT_SYMBOL(gr_is_capable); +EXPORT_SYMBOL(gr_is_capable_nolog); -diff -urNp linux-3.1.4/grsecurity/grsec_fifo.c linux-3.1.4/grsecurity/gr= sec_fifo.c ---- linux-3.1.4/grsecurity/grsec_fifo.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/grsec_fifo.c 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/grsecurity/grsec_fifo.c b/grsecurity/grsec_fifo.c +new file mode 100644 +index 0000000..d3ee748 +--- /dev/null ++++ b/grsecurity/grsec_fifo.c @@ -0,0 +1,24 @@ +#include +#include @@ -54921,9 +57407,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_fifo.c l= inux-3.1.4/grsecurity/grsec_fifo +#endif + return 0; +} -diff -urNp linux-3.1.4/grsecurity/grsec_fork.c linux-3.1.4/grsecurity/gr= sec_fork.c ---- linux-3.1.4/grsecurity/grsec_fork.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/grsec_fork.c 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/grsecurity/grsec_fork.c b/grsecurity/grsec_fork.c +new file mode 100644 +index 0000000..8ca18bf +--- /dev/null ++++ b/grsecurity/grsec_fork.c @@ -0,0 +1,23 @@ +#include +#include @@ -54948,9 +57436,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_fork.c l= inux-3.1.4/grsecurity/grsec_fork +#endif + return; +} -diff -urNp linux-3.1.4/grsecurity/grsec_init.c linux-3.1.4/grsecurity/gr= sec_init.c ---- linux-3.1.4/grsecurity/grsec_init.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/grsec_init.c 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/grsecurity/grsec_init.c b/grsecurity/grsec_init.c +new file mode 100644 +index 0000000..356ef00 +--- /dev/null ++++ b/grsecurity/grsec_init.c @@ -0,0 +1,269 @@ +#include +#include @@ -55221,9 +57711,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_init.c l= inux-3.1.4/grsecurity/grsec_init + + return; +} -diff -urNp linux-3.1.4/grsecurity/grsec_link.c linux-3.1.4/grsecurity/gr= sec_link.c ---- linux-3.1.4/grsecurity/grsec_link.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/grsec_link.c 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/grsecurity/grsec_link.c b/grsecurity/grsec_link.c +new file mode 100644 +index 0000000..3efe141 +--- /dev/null ++++ b/grsecurity/grsec_link.c @@ -0,0 +1,43 @@ +#include +#include @@ -55268,9 +57760,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_link.c l= inux-3.1.4/grsecurity/grsec_link +#endif + return 0; +} -diff -urNp linux-3.1.4/grsecurity/grsec_log.c linux-3.1.4/grsecurity/grs= ec_log.c ---- linux-3.1.4/grsecurity/grsec_log.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/grsec_log.c 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/grsecurity/grsec_log.c b/grsecurity/grsec_log.c +new file mode 100644 +index 0000000..a45d2e9 +--- /dev/null ++++ b/grsecurity/grsec_log.c @@ -0,0 +1,322 @@ +#include +#include @@ -55594,9 +58088,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_log.c li= nux-3.1.4/grsecurity/grsec_log.c + gr_log_end(audit, 1); + END_LOCKS(audit); +} -diff -urNp linux-3.1.4/grsecurity/grsec_mem.c linux-3.1.4/grsecurity/grs= ec_mem.c ---- linux-3.1.4/grsecurity/grsec_mem.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/grsec_mem.c 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/grsecurity/grsec_mem.c b/grsecurity/grsec_mem.c +new file mode 100644 +index 0000000..6c0416b +--- /dev/null ++++ b/grsecurity/grsec_mem.c @@ -0,0 +1,33 @@ +#include +#include @@ -55631,9 +58127,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_mem.c li= nux-3.1.4/grsecurity/grsec_mem.c + gr_log_noargs(GR_DONT_AUDIT, GR_VM86_MSG); + return; +} -diff -urNp linux-3.1.4/grsecurity/grsec_mount.c linux-3.1.4/grsecurity/g= rsec_mount.c ---- linux-3.1.4/grsecurity/grsec_mount.c 1969-12-31 19:00:00.000000000 -= 0500 -+++ linux-3.1.4/grsecurity/grsec_mount.c 2011-11-16 18:40:31.000000000 -= 0500 +diff --git a/grsecurity/grsec_mount.c b/grsecurity/grsec_mount.c +new file mode 100644 +index 0000000..2131422 +--- /dev/null ++++ b/grsecurity/grsec_mount.c @@ -0,0 +1,62 @@ +#include +#include @@ -55697,9 +58195,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_mount.c = linux-3.1.4/grsecurity/grsec_mou +#endif + return 0; +} -diff -urNp linux-3.1.4/grsecurity/grsec_pax.c linux-3.1.4/grsecurity/grs= ec_pax.c ---- linux-3.1.4/grsecurity/grsec_pax.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/grsec_pax.c 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/grsecurity/grsec_pax.c b/grsecurity/grsec_pax.c +new file mode 100644 +index 0000000..a3b12a0 +--- /dev/null ++++ b/grsecurity/grsec_pax.c @@ -0,0 +1,36 @@ +#include +#include @@ -55737,9 +58237,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_pax.c li= nux-3.1.4/grsecurity/grsec_pax.c +#endif + return; +} -diff -urNp linux-3.1.4/grsecurity/grsec_ptrace.c linux-3.1.4/grsecurity/= grsec_ptrace.c ---- linux-3.1.4/grsecurity/grsec_ptrace.c 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-3.1.4/grsecurity/grsec_ptrace.c 2011-11-16 18:40:31.000000000 = -0500 +diff --git a/grsecurity/grsec_ptrace.c b/grsecurity/grsec_ptrace.c +new file mode 100644 +index 0000000..472c1d6 +--- /dev/null ++++ b/grsecurity/grsec_ptrace.c @@ -0,0 +1,14 @@ +#include +#include @@ -55755,9 +58257,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_ptrace.c= linux-3.1.4/grsecurity/grsec_pt +#endif + return; +} -diff -urNp linux-3.1.4/grsecurity/grsec_sig.c linux-3.1.4/grsecurity/grs= ec_sig.c ---- linux-3.1.4/grsecurity/grsec_sig.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/grsec_sig.c 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/grsecurity/grsec_sig.c b/grsecurity/grsec_sig.c +new file mode 100644 +index 0000000..cf090b3 +--- /dev/null ++++ b/grsecurity/grsec_sig.c @@ -0,0 +1,206 @@ +#include +#include @@ -55965,9 +58469,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_sig.c li= nux-3.1.4/grsecurity/grsec_sig.c +#endif + return 0; +} -diff -urNp linux-3.1.4/grsecurity/grsec_sock.c linux-3.1.4/grsecurity/gr= sec_sock.c ---- linux-3.1.4/grsecurity/grsec_sock.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/grsec_sock.c 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/grsecurity/grsec_sock.c b/grsecurity/grsec_sock.c +new file mode 100644 +index 0000000..4030d57 +--- /dev/null ++++ b/grsecurity/grsec_sock.c @@ -0,0 +1,244 @@ +#include +#include @@ -56213,9 +58719,11 @@ diff -urNp linux-3.1.4/grsecurity/grsec_sock.c l= inux-3.1.4/grsecurity/grsec_sock +#endif + return 0; +} -diff -urNp linux-3.1.4/grsecurity/grsec_sysctl.c linux-3.1.4/grsecurity/= grsec_sysctl.c ---- linux-3.1.4/grsecurity/grsec_sysctl.c 1969-12-31 19:00:00.000000000 = -0500 -+++ linux-3.1.4/grsecurity/grsec_sysctl.c 2011-11-16 18:40:31.000000000 = -0500 +diff --git a/grsecurity/grsec_sysctl.c b/grsecurity/grsec_sysctl.c +new file mode 100644 +index 0000000..174668f +--- /dev/null ++++ b/grsecurity/grsec_sysctl.c @@ -0,0 +1,433 @@ +#include +#include @@ -56399,1469 +58907,395 @@ diff -urNp linux-3.1.4/grsecurity/grsec_sysc= tl.c linux-3.1.4/grsecurity/grsec_sy + { + .procname =3D "chroot_enforce_chdir", + .data =3D &grsec_enable_chroot_chdir, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_CHMOD -+ { -+ .procname =3D "chroot_deny_chmod", -+ .data =3D &grsec_enable_chroot_chmod, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_MKNOD -+ { -+ .procname =3D "chroot_deny_mknod", -+ .data =3D &grsec_enable_chroot_mknod, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_NICE -+ { -+ .procname =3D "chroot_restrict_nice", -+ .data =3D &grsec_enable_chroot_nice, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_EXECLOG -+ { -+ .procname =3D "chroot_execlog", -+ .data =3D &grsec_enable_chroot_execlog, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_CAPS -+ { -+ .procname =3D "chroot_caps", -+ .data =3D &grsec_enable_chroot_caps, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_SYSCTL -+ { -+ .procname =3D "chroot_deny_sysctl", -+ .data =3D &grsec_enable_chroot_sysctl, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_TPE -+ { -+ .procname =3D "tpe", -+ .data =3D &grsec_enable_tpe, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .procname =3D "tpe_gid", -+ .data =3D &grsec_tpe_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_TPE_INVERT -+ { -+ .procname =3D "tpe_invert", -+ .data =3D &grsec_enable_tpe_invert, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_TPE_ALL -+ { -+ .procname =3D "tpe_restrict_all", -+ .data =3D &grsec_enable_tpe_all, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_SOCKET_ALL -+ { -+ .procname =3D "socket_all", -+ .data =3D &grsec_enable_socket_all, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .procname =3D "socket_all_gid", -+ .data =3D &grsec_socket_all_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_SOCKET_CLIENT -+ { -+ .procname =3D "socket_client", -+ .data =3D &grsec_enable_socket_client, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .procname =3D "socket_client_gid", -+ .data =3D &grsec_socket_client_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_SOCKET_SERVER -+ { -+ .procname =3D "socket_server", -+ .data =3D &grsec_enable_socket_server, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .procname =3D "socket_server_gid", -+ .data =3D &grsec_socket_server_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_GROUP -+ { -+ .procname =3D "audit_group", -+ .data =3D &grsec_enable_group, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+ { -+ .procname =3D "audit_gid", -+ .data =3D &grsec_audit_gid, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_CHDIR -+ { -+ .procname =3D "audit_chdir", -+ .data =3D &grsec_enable_chdir, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_MOUNT -+ { -+ .procname =3D "audit_mount", -+ .data =3D &grsec_enable_mount, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_TEXTREL -+ { -+ .procname =3D "audit_textrel", -+ .data =3D &grsec_enable_audit_textrel, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_DMESG -+ { -+ .procname =3D "dmesg", -+ .data =3D &grsec_enable_dmesg, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_CHROOT_FINDTASK -+ { -+ .procname =3D "chroot_findtask", -+ .data =3D &grsec_enable_chroot_findtask, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_RESLOG -+ { -+ .procname =3D "resource_logging", -+ .data =3D &grsec_resource_logging, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_AUDIT_PTRACE -+ { -+ .procname =3D "audit_ptrace", -+ .data =3D &grsec_enable_audit_ptrace, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_HARDEN_PTRACE -+ { -+ .procname =3D "harden_ptrace", -+ .data =3D &grsec_enable_harden_ptrace, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+ { -+ .procname =3D "grsec_lock", -+ .data =3D &grsec_lock, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec, -+ }, -+#endif -+#ifdef CONFIG_GRKERNSEC_ROFS -+ { -+ .procname =3D "romount_protect", -+ .data =3D &grsec_enable_rofs, -+ .maxlen =3D sizeof(int), -+ .mode =3D 0600, -+ .proc_handler =3D &proc_dointvec_minmax, -+ .extra1 =3D &one, -+ .extra2 =3D &one, -+ }, -+#endif -+ { } -+}; -+#endif -diff -urNp linux-3.1.4/grsecurity/grsec_time.c linux-3.1.4/grsecurity/gr= sec_time.c ---- linux-3.1.4/grsecurity/grsec_time.c 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/grsecurity/grsec_time.c 2011-11-16 18:40:31.000000000 -0= 500 -@@ -0,0 +1,16 @@ -+#include -+#include -+#include -+#include -+ -+void -+gr_log_timechange(void) -+{ -+#ifdef CONFIG_GRKERNSEC_TIME -+ if (grsec_enable_time) -+ gr_log_noargs(GR_DONT_AUDIT_GOOD, GR_TIME_MSG); -+#endif -+ return; -+} -+ -+EXPORT_SYMBOL(gr_log_timechange); -diff -urNp linux-3.1.4/grsecurity/grsec_tpe.c linux-3.1.4/grsecurity/grs= ec_tpe.c ---- linux-3.1.4/grsecurity/grsec_tpe.c 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/grsecurity/grsec_tpe.c 2011-11-16 18:40:31.000000000 -05= 00 -@@ -0,0 +1,39 @@ -+#include -+#include -+#include -+#include -+#include -+ -+extern int gr_acl_tpe_check(void); -+ -+int -+gr_tpe_allow(const struct file *file) -+{ -+#ifdef CONFIG_GRKERNSEC -+ struct inode *inode =3D file->f_path.dentry->d_parent->d_inode; -+ const struct cred *cred =3D current_cred(); -+ -+ if (cred->uid && ((grsec_enable_tpe && -+#ifdef CONFIG_GRKERNSEC_TPE_INVERT -+ ((grsec_enable_tpe_invert && !in_group_p(grsec_tpe_gid)) || -+ (!grsec_enable_tpe_invert && in_group_p(grsec_tpe_gid))) -+#else -+ in_group_p(grsec_tpe_gid) -+#endif -+ ) || gr_acl_tpe_check()) && -+ (inode->i_uid || (!inode->i_uid && ((inode->i_mode & S_IWGRP) || -+ (inode->i_mode & S_IWOTH))))) { -+ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); -+ return 0; -+ } -+#ifdef CONFIG_GRKERNSEC_TPE_ALL -+ if (cred->uid && grsec_enable_tpe && grsec_enable_tpe_all && -+ ((inode->i_uid && (inode->i_uid !=3D cred->uid)) || -+ (inode->i_mode & S_IWGRP) || (inode->i_mode & S_IWOTH))) { -+ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); -+ return 0; -+ } -+#endif -+#endif -+ return 1; -+} -diff -urNp linux-3.1.4/grsecurity/grsum.c linux-3.1.4/grsecurity/grsum.c ---- linux-3.1.4/grsecurity/grsum.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.1.4/grsecurity/grsum.c 2011-11-16 18:40:31.000000000 -0500 -@@ -0,0 +1,61 @@ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+ -+#if !defined(CONFIG_CRYPTO) || defined(CONFIG_CRYPTO_MODULE) || !define= d(CONFIG_CRYPTO_SHA256) || defined(CONFIG_CRYPTO_SHA256_MODULE) -+#error "crypto and sha256 must be built into the kernel" -+#endif -+ -+int -+chkpw(struct gr_arg *entry, unsigned char *salt, unsigned char *sum) -+{ -+ char *p; -+ struct crypto_hash *tfm; -+ struct hash_desc desc; -+ struct scatterlist sg; -+ unsigned char temp_sum[GR_SHA_LEN]; -+ volatile int retval =3D 0; -+ volatile int dummy =3D 0; -+ unsigned int i; -+ -+ sg_init_table(&sg, 1); -+ -+ tfm =3D crypto_alloc_hash("sha256", 0, CRYPTO_ALG_ASYNC); -+ if (IS_ERR(tfm)) { -+ /* should never happen, since sha256 should be built in */ -+ return 1; -+ } -+ -+ desc.tfm =3D tfm; -+ desc.flags =3D 0; -+ -+ crypto_hash_init(&desc); -+ -+ p =3D salt; -+ sg_set_buf(&sg, p, GR_SALT_LEN); -+ crypto_hash_update(&desc, &sg, sg.length); -+ -+ p =3D entry->pw; -+ sg_set_buf(&sg, p, strlen(p)); -+=09 -+ crypto_hash_update(&desc, &sg, sg.length); -+ -+ crypto_hash_final(&desc, temp_sum); -+ -+ memset(entry->pw, 0, GR_PW_LEN); -+ -+ for (i =3D 0; i < GR_SHA_LEN; i++) -+ if (sum[i] !=3D temp_sum[i]) -+ retval =3D 1; -+ else -+ dummy =3D 1; // waste a cycle -+ -+ crypto_free_hash(tfm); -+ -+ return retval; -+} -diff -urNp linux-3.1.4/grsecurity/Kconfig linux-3.1.4/grsecurity/Kconfig ---- linux-3.1.4/grsecurity/Kconfig 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.1.4/grsecurity/Kconfig 2011-11-16 18:40:31.000000000 -0500 -@@ -0,0 +1,1037 @@ -+# -+# grecurity configuration -+# -+ -+menu "Grsecurity" -+ -+config GRKERNSEC -+ bool "Grsecurity" -+ select CRYPTO -+ select CRYPTO_SHA256 -+ help -+ If you say Y here, you will be able to configure many features -+ that will enhance the security of your system. It is highly -+ recommended that you say Y here and read through the help -+ for each option so that you fully understand the features and -+ can evaluate their usefulness for your machine. -+ -+choice -+ prompt "Security Level" -+ depends on GRKERNSEC -+ default GRKERNSEC_CUSTOM -+ -+config GRKERNSEC_LOW -+ bool "Low" -+ select GRKERNSEC_LINK -+ select GRKERNSEC_FIFO -+ select GRKERNSEC_RANDNET -+ select GRKERNSEC_DMESG -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_CHDIR -+ -+ help -+ If you choose this option, several of the grsecurity options will -+ be enabled that will give you greater protection against a number -+ of attacks, while assuring that none of your software will have any -+ conflicts with the additional security measures. If you run a lot -+ of unusual software, or you are having problems with the higher -+ security levels, you should say Y here. With this option, the -+ following features are enabled: -+ -+ - Linking restrictions -+ - FIFO restrictions -+ - Restricted dmesg -+ - Enforced chdir("/") on chroot -+ - Runtime module disabling -+ -+config GRKERNSEC_MEDIUM -+ bool "Medium" -+ select PAX -+ select PAX_EI_PAX -+ select PAX_PT_PAX_FLAGS -+ select PAX_HAVE_ACL_FLAGS -+ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_SYSCTL -+ select GRKERNSEC_LINK -+ select GRKERNSEC_FIFO -+ select GRKERNSEC_DMESG -+ select GRKERNSEC_RANDNET -+ select GRKERNSEC_FORKFAIL -+ select GRKERNSEC_TIME -+ select GRKERNSEC_SIGNAL -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_UNIX -+ select GRKERNSEC_CHROOT_MOUNT -+ select GRKERNSEC_CHROOT_PIVOT -+ select GRKERNSEC_CHROOT_DOUBLE -+ select GRKERNSEC_CHROOT_CHDIR -+ select GRKERNSEC_CHROOT_MKNOD -+ select GRKERNSEC_PROC -+ select GRKERNSEC_PROC_USERGROUP -+ select PAX_RANDUSTACK -+ select PAX_ASLR -+ select PAX_RANDMMAP -+ select PAX_REFCOUNT if (X86 || SPARC64) -+ select PAX_USERCOPY if ((X86 || SPARC || PPC || ARM) && (SLAB || SLUB = || SLOB)) -+ -+ help -+ If you say Y here, several features in addition to those included -+ in the low additional security level will be enabled. These -+ features provide even more security to your system, though in rare -+ cases they may be incompatible with very old or poorly written -+ software. If you enable this option, make sure that your auth -+ service (identd) is running as gid 1001. With this option,=20 -+ the following features (in addition to those provided in the=20 -+ low additional security level) will be enabled: -+ -+ - Failed fork logging -+ - Time change logging -+ - Signal logging -+ - Deny mounts in chroot -+ - Deny double chrooting -+ - Deny sysctl writes in chroot -+ - Deny mknod in chroot -+ - Deny access to abstract AF_UNIX sockets out of chroot -+ - Deny pivot_root in chroot -+ - Denied reads/writes of /dev/kmem, /dev/mem, and /dev/port -+ - /proc restrictions with special GID set to 10 (usually wheel) -+ - Address Space Layout Randomization (ASLR) -+ - Prevent exploitation of most refcount overflows -+ - Bounds checking of copying between the kernel and userland -+ -+config GRKERNSEC_HIGH -+ bool "High" -+ select GRKERNSEC_LINK -+ select GRKERNSEC_FIFO -+ select GRKERNSEC_DMESG -+ select GRKERNSEC_FORKFAIL -+ select GRKERNSEC_TIME -+ select GRKERNSEC_SIGNAL -+ select GRKERNSEC_CHROOT -+ select GRKERNSEC_CHROOT_SHMAT -+ select GRKERNSEC_CHROOT_UNIX -+ select GRKERNSEC_CHROOT_MOUNT -+ select GRKERNSEC_CHROOT_FCHDIR -+ select GRKERNSEC_CHROOT_PIVOT -+ select GRKERNSEC_CHROOT_DOUBLE -+ select GRKERNSEC_CHROOT_CHDIR -+ select GRKERNSEC_CHROOT_MKNOD -+ select GRKERNSEC_CHROOT_CAPS -+ select GRKERNSEC_CHROOT_SYSCTL -+ select GRKERNSEC_CHROOT_FINDTASK -+ select GRKERNSEC_SYSFS_RESTRICT -+ select GRKERNSEC_PROC -+ select GRKERNSEC_PROC_MEMMAP if (PAX_NOEXEC || PAX_ASLR) -+ select GRKERNSEC_HIDESYM -+ select GRKERNSEC_BRUTE -+ select GRKERNSEC_PROC_USERGROUP -+ select GRKERNSEC_KMEM -+ select GRKERNSEC_RESLOG -+ select GRKERNSEC_RANDNET -+ select GRKERNSEC_PROC_ADD -+ select GRKERNSEC_CHROOT_CHMOD -+ select GRKERNSEC_CHROOT_NICE -+ select GRKERNSEC_AUDIT_MOUNT -+ select GRKERNSEC_MODHARDEN if (MODULES) -+ select GRKERNSEC_HARDEN_PTRACE -+ select GRKERNSEC_VM86 if (X86_32) -+ select GRKERNSEC_KERN_LOCKOUT if (X86 || ARM || PPC || SPARC) -+ select PAX -+ select PAX_RANDUSTACK -+ select PAX_ASLR -+ select PAX_RANDMMAP -+ select PAX_NOEXEC -+ select PAX_MPROTECT -+ select PAX_EI_PAX -+ select PAX_PT_PAX_FLAGS -+ select PAX_HAVE_ACL_FLAGS -+ select PAX_KERNEXEC if ((PPC || X86) && (!X86_32 || X86_WP_WORKS_OK) &= & !XEN) -+ select PAX_MEMORY_UDEREF if (X86 && !XEN) -+ select PAX_RANDKSTACK if (X86_TSC && X86) -+ select PAX_SEGMEXEC if (X86_32) -+ select PAX_PAGEEXEC -+ select PAX_EMUPLT if (ALPHA || PARISC || SPARC) -+ select PAX_EMUTRAMP if (PARISC) -+ select PAX_EMUSIGRT if (PARISC) -+ select PAX_ETEXECRELOCS if (ALPHA || IA64 || PARISC) -+ select PAX_ELFRELOCS if (PAX_ETEXECRELOCS || (IA64 || PPC || X86)) -+ select PAX_REFCOUNT if (X86 || SPARC64) -+ select PAX_USERCOPY if ((X86 || PPC || SPARC || ARM) && (SLAB || SLUB = || SLOB)) -+ help -+ If you say Y here, many of the features of grsecurity will be -+ enabled, which will protect you against many kinds of attacks -+ against your system. The heightened security comes at a cost -+ of an increased chance of incompatibilities with rare software -+ on your machine. Since this security level enables PaX, you should -+ view and read about the PaX -+ project. While you are there, download chpax and run it on -+ binaries that cause problems with PaX. Also remember that -+ since the /proc restrictions are enabled, you must run your -+ identd as gid 1001. This security level enables the following=20 -+ features in addition to those listed in the low and medium=20 -+ security levels: -+ -+ - Additional /proc restrictions -+ - Chmod restrictions in chroot -+ - No signals, ptrace, or viewing of processes outside of chroot -+ - Capability restrictions in chroot -+ - Deny fchdir out of chroot -+ - Priority restrictions in chroot -+ - Segmentation-based implementation of PaX -+ - Mprotect restrictions -+ - Removal of addresses from /proc//[smaps|maps|stat] -+ - Kernel stack randomization -+ - Mount/unmount/remount logging -+ - Kernel symbol hiding -+ - Hardening of module auto-loading -+ - Ptrace restrictions -+ - Restricted vm86 mode -+ - Restricted sysfs/debugfs -+ - Active kernel exploit response -+ -+config GRKERNSEC_CUSTOM -+ bool "Custom" -+ help -+ If you say Y here, you will be able to configure every grsecurity -+ option, which allows you to enable many more features that aren't -+ covered in the basic security levels. These additional features -+ include TPE, socket restrictions, and the sysctl system for -+ grsecurity. It is advised that you read through the help for -+ each option to determine its usefulness in your situation. -+ -+endchoice -+ -+menu "Address Space Protection" -+depends on GRKERNSEC -+ -+config GRKERNSEC_KMEM -+ bool "Deny reading/writing to /dev/kmem, /dev/mem, and /dev/port" -+ select STRICT_DEVMEM if (X86 || ARM || TILE || S390) -+ help -+ If you say Y here, /dev/kmem and /dev/mem won't be allowed to -+ be written to or read from to modify or leak the contents of the run= ning -+ kernel. /dev/port will also not be allowed to be opened. If you hav= e module -+ support disabled, enabling this will close up four ways that are -+ currently used to insert malicious code into the running kernel. -+ Even with all these features enabled, we still highly recommend that -+ you use the RBAC system, as it is still possible for an attacker to -+ modify the running kernel through privileged I/O granted by ioperm/i= opl. -+ If you are not using XFree86, you may be able to stop this additiona= l -+ case by enabling the 'Disable privileged I/O' option. Though nothing -+ legitimately writes to /dev/kmem, XFree86 does need to write to /dev= /mem, -+ but only to video memory, which is the only writing we allow in this -+ case. If /dev/kmem or /dev/mem are mmaped without PROT_WRITE, they = will -+ not be allowed to mprotect it with PROT_WRITE later. -+ It is highly recommended that you say Y here if you meet all the -+ conditions above. -+ -+config GRKERNSEC_VM86 -+ bool "Restrict VM86 mode" -+ depends on X86_32 -+ -+ help -+ If you say Y here, only processes with CAP_SYS_RAWIO will be able to -+ make use of a special execution mode on 32bit x86 processors called -+ Virtual 8086 (VM86) mode. XFree86 may need vm86 mode for certain -+ video cards and will still work with this option enabled. The purpo= se -+ of the option is to prevent exploitation of emulation errors in -+ virtualization of vm86 mode like the one discovered in VMWare in 200= 9. -+ Nearly all users should be able to enable this option. -+ -+config GRKERNSEC_IO -+ bool "Disable privileged I/O" -+ depends on X86 -+ select RTC_CLASS -+ select RTC_INTF_DEV -+ select RTC_DRV_CMOS -+ -+ help -+ If you say Y here, all ioperm and iopl calls will return an error. -+ Ioperm and iopl can be used to modify the running kernel. -+ Unfortunately, some programs need this access to operate properly, -+ the most notable of which are XFree86 and hwclock. hwclock can be -+ remedied by having RTC support in the kernel, so real-time=20 -+ clock support is enabled if this option is enabled, to ensure=20 -+ that hwclock operates correctly. XFree86 still will not=20 -+ operate correctly with this option enabled, so DO NOT CHOOSE Y=20 -+ IF YOU USE XFree86. If you use XFree86 and you still want to=20 -+ protect your kernel against modification, use the RBAC system. -+ -+config GRKERNSEC_PROC_MEMMAP -+ bool "Remove addresses from /proc//[smaps|maps|stat]" -+ default y if (PAX_NOEXEC || PAX_ASLR) -+ depends on PAX_NOEXEC || PAX_ASLR -+ help -+ If you say Y here, the /proc//maps and /proc//stat files w= ill -+ give no information about the addresses of its mappings if -+ PaX features that rely on random addresses are enabled on the task. -+ If you use PaX it is greatly recommended that you say Y here as it -+ closes up a hole that makes the full ASLR useless for suid -+ binaries. -+ -+config GRKERNSEC_BRUTE -+ bool "Deter exploit bruteforcing" -+ help -+ If you say Y here, attempts to bruteforce exploits against forking -+ daemons such as apache or sshd, as well as against suid/sgid binarie= s -+ will be deterred. When a child of a forking daemon is killed by PaX -+ or crashes due to an illegal instruction or other suspicious signal, -+ the parent process will be delayed 30 seconds upon every subsequent -+ fork until the administrator is able to assess the situation and -+ restart the daemon. -+ In the suid/sgid case, the attempt is logged, the user has all their -+ processes terminated, and they are prevented from executing any furt= her -+ processes for 15 minutes. -+ It is recommended that you also enable signal logging in the auditin= g -+ section so that logs are generated when a process triggers a suspici= ous -+ signal. -+ If the sysctl option is enabled, a sysctl option with name -+ "deter_bruteforce" is created. -+ -+ -+config GRKERNSEC_MODHARDEN -+ bool "Harden module auto-loading" -+ depends on MODULES -+ help -+ If you say Y here, module auto-loading in response to use of some -+ feature implemented by an unloaded module will be restricted to -+ root users. Enabling this option helps defend against attacks=20 -+ by unprivileged users who abuse the auto-loading behavior to=20 -+ cause a vulnerable module to load that is then exploited. -+ -+ If this option prevents a legitimate use of auto-loading for a=20 -+ non-root user, the administrator can execute modprobe manually=20 -+ with the exact name of the module mentioned in the alert log. -+ Alternatively, the administrator can add the module to the list -+ of modules loaded at boot by modifying init scripts. -+ -+ Modification of init scripts will most likely be needed on=20 -+ Ubuntu servers with encrypted home directory support enabled, -+ as the first non-root user logging in will cause the ecb(aes), -+ ecb(aes)-all, cbc(aes), and cbc(aes)-all modules to be loaded. -+ -+config GRKERNSEC_HIDESYM -+ bool "Hide kernel symbols" -+ help -+ If you say Y here, getting information on loaded modules, and -+ displaying all kernel symbols through a syscall will be restricted -+ to users with CAP_SYS_MODULE. For software compatibility reasons, -+ /proc/kallsyms will be restricted to the root user. The RBAC -+ system can hide that entry even from root. -+ -+ This option also prevents leaking of kernel addresses through -+ several /proc entries. -+ -+ Note that this option is only effective provided the following -+ conditions are met: -+ 1) The kernel using grsecurity is not precompiled by some distributi= on -+ 2) You have also enabled GRKERNSEC_DMESG -+ 3) You are using the RBAC system and hiding other files such as your -+ kernel image and System.map. Alternatively, enabling this option -+ causes the permissions on /boot, /lib/modules, and the kernel -+ source directory to change at compile time to prevent=20 -+ reading by non-root users. -+ If the above conditions are met, this option will aid in providing a -+ useful protection against local kernel exploitation of overflows -+ and arbitrary read/write vulnerabilities. -+ -+config GRKERNSEC_KERN_LOCKOUT -+ bool "Active kernel exploit response" -+ depends on X86 || ARM || PPC || SPARC -+ help -+ If you say Y here, when a PaX alert is triggered due to suspicious -+ activity in the kernel (from KERNEXEC/UDEREF/USERCOPY) -+ or an OOPs occurs due to bad memory accesses, instead of just -+ terminating the offending process (and potentially allowing -+ a subsequent exploit from the same user), we will take one of two -+ actions: -+ If the user was root, we will panic the system -+ If the user was non-root, we will log the attempt, terminate -+ all processes owned by the user, then prevent them from creating -+ any new processes until the system is restarted -+ This deters repeated kernel exploitation/bruteforcing attempts -+ and is useful for later forensics. -+ -+endmenu -+menu "Role Based Access Control Options" -+depends on GRKERNSEC -+ -+config GRKERNSEC_RBAC_DEBUG -+ bool -+ -+config GRKERNSEC_NO_RBAC -+ bool "Disable RBAC system" -+ help -+ If you say Y here, the /dev/grsec device will be removed from the ke= rnel, -+ preventing the RBAC system from being enabled. You should only say = Y -+ here if you have no intention of using the RBAC system, so as to pre= vent -+ an attacker with root access from misusing the RBAC system to hide f= iles -+ and processes when loadable module support and /dev/[k]mem have been -+ locked down. -+ -+config GRKERNSEC_ACL_HIDEKERN -+ bool "Hide kernel processes" -+ help -+ If you say Y here, all kernel threads will be hidden to all -+ processes but those whose subject has the "view hidden processes" -+ flag. -+ -+config GRKERNSEC_ACL_MAXTRIES -+ int "Maximum tries before password lockout" -+ default 3 -+ help -+ This option enforces the maximum number of times a user can attempt -+ to authorize themselves with the grsecurity RBAC system before being -+ denied the ability to attempt authorization again for a specified ti= me. -+ The lower the number, the harder it will be to brute-force a passwor= d. -+ -+config GRKERNSEC_ACL_TIMEOUT -+ int "Time to wait after max password tries, in seconds" -+ default 30 -+ help -+ This option specifies the time the user must wait after attempting t= o -+ authorize to the RBAC system with the maximum number of invalid -+ passwords. The higher the number, the harder it will be to brute-fo= rce -+ a password. -+ -+endmenu -+menu "Filesystem Protections" -+depends on GRKERNSEC -+ -+config GRKERNSEC_PROC -+ bool "Proc restrictions" -+ help -+ If you say Y here, the permissions of the /proc filesystem -+ will be altered to enhance system security and privacy. You MUST -+ choose either a user only restriction or a user and group restrict= ion. -+ Depending upon the option you choose, you can either restrict users = to -+ see only the processes they themselves run, or choose a group that c= an -+ view all processes and files normally restricted to root if you choo= se -+ the "restrict to user only" option. NOTE: If you're running identd = as -+ a non-root user, you will have to run it as the group you specify he= re. -+ -+config GRKERNSEC_PROC_USER -+ bool "Restrict /proc to user only" -+ depends on GRKERNSEC_PROC -+ help -+ If you say Y here, non-root users will only be able to view their ow= n -+ processes, and restricts them from viewing network-related informati= on, -+ and viewing kernel symbol and module information. -+ -+config GRKERNSEC_PROC_USERGROUP -+ bool "Allow special group" -+ depends on GRKERNSEC_PROC && !GRKERNSEC_PROC_USER -+ help -+ If you say Y here, you will be able to select a group that will be -+ able to view all processes and network-related information. = If you've -+ enabled GRKERNSEC_HIDESYM, kernel and symbol information may = still -+ remain hidden. This option is useful if you want to run iden= td as -+ a non-root user. -+ -+config GRKERNSEC_PROC_GID -+ int "GID for special group" -+ depends on GRKERNSEC_PROC_USERGROUP -+ default 1001 -+ -+config GRKERNSEC_PROC_ADD -+ bool "Additional restrictions" -+ depends on GRKERNSEC_PROC_USER || GRKERNSEC_PROC_USERGROUP -+ help -+ If you say Y here, additional restrictions will be placed on -+ /proc that keep normal users from viewing device information and=20 -+ slabinfo information that could be useful for exploits. -+ -+config GRKERNSEC_LINK -+ bool "Linking restrictions" -+ help -+ If you say Y here, /tmp race exploits will be prevented, since users -+ will no longer be able to follow symlinks owned by other users in -+ world-writable +t directories (e.g. /tmp), unless the owner of the -+ symlink is the owner of the directory. users will also not be -+ able to hardlink to files they do not own. If the sysctl option is -+ enabled, a sysctl option with name "linking_restrictions" is created= . -+ -+config GRKERNSEC_FIFO -+ bool "FIFO restrictions" -+ help -+ If you say Y here, users will not be able to write to FIFOs they don= 't -+ own in world-writable +t directories (e.g. /tmp), unless the owner o= f -+ the FIFO is the same owner of the directory it's held in. If the sy= sctl -+ option is enabled, a sysctl option with name "fifo_restrictions" is -+ created. -+ -+config GRKERNSEC_SYSFS_RESTRICT -+ bool "Sysfs/debugfs restriction" -+ depends on SYSFS -+ help -+ If you say Y here, sysfs (the pseudo-filesystem mounted at /sys) and -+ any filesystem normally mounted under it (e.g. debugfs) will only -+ be accessible by root. These filesystems generally provide access -+ to hardware and debug information that isn't appropriate for unprivi= leged -+ users of the system. Sysfs and debugfs have also become a large sou= rce -+ of new vulnerabilities, ranging from infoleaks to local compromise. -+ There has been very little oversight with an eye toward security inv= olved -+ in adding new exporters of information to these filesystems, so thei= r -+ use is discouraged. -+ This option is equivalent to a chmod 0700 of the mount paths. -+ -+config GRKERNSEC_ROFS -+ bool "Runtime read-only mount protection" -+ help -+ If you say Y here, a sysctl option with name "romount_protect" will -+ be created. By setting this option to 1 at runtime, filesystems -+ will be protected in the following ways: -+ * No new writable mounts will be allowed -+ * Existing read-only mounts won't be able to be remounted read/write -+ * Write operations will be denied on all block devices -+ This option acts independently of grsec_lock: once it is set to 1, -+ it cannot be turned off. Therefore, please be mindful of the result= ing -+ behavior if this option is enabled in an init script on a read-only -+ filesystem. This feature is mainly intended for secure embedded sys= tems. -+ -+config GRKERNSEC_CHROOT -+ bool "Chroot jail restrictions" -+ help -+ If you say Y here, you will be able to choose several options that w= ill -+ make breaking out of a chrooted jail much more difficult. If you -+ encounter no software incompatibilities with the following options, = it -+ is recommended that you enable each one. -+ -+config GRKERNSEC_CHROOT_MOUNT -+ bool "Deny mounts" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to -+ mount or remount filesystems. If the sysctl option is enabled, a -+ sysctl option with name "chroot_deny_mount" is created. -+ -+config GRKERNSEC_CHROOT_DOUBLE -+ bool "Deny double-chroots" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to chr= oot -+ again outside the chroot. This is a widely used method of breaking -+ out of a chroot jail and should not be allowed. If the sysctl=20 -+ option is enabled, a sysctl option with name=20 -+ "chroot_deny_chroot" is created. -+ -+config GRKERNSEC_CHROOT_PIVOT -+ bool "Deny pivot_root in chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to use -+ a function called pivot_root() that was introduced in Linux 2.3.41. = It -+ works similar to chroot in that it changes the root filesystem. Thi= s -+ function could be misused in a chrooted process to attempt to break = out -+ of the chroot, and therefore should not be allowed. If the sysctl -+ option is enabled, a sysctl option with name "chroot_deny_pivot" is -+ created. -+ -+config GRKERNSEC_CHROOT_CHDIR -+ bool "Enforce chdir(\"/\") on all chroots" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, the current working directory of all newly-chroot= ed -+ applications will be set to the the root directory of the chroot. -+ The man page on chroot(2) states: -+ Note that this call does not change the current working -+ directory, so that `.' can be outside the tree rooted at -+ `/'. In particular, the super-user can escape from a -+ `chroot jail' by doing `mkdir foo; chroot foo; cd ..'. -+ -+ It is recommended that you say Y here, since it's not known to break -+ any software. If the sysctl option is enabled, a sysctl option with -+ name "chroot_enforce_chdir" is created. -+ -+config GRKERNSEC_CHROOT_CHMOD -+ bool "Deny (f)chmod +s" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to chm= od -+ or fchmod files to make them have suid or sgid bits. This protects -+ against another published method of breaking a chroot. If the sysct= l -+ option is enabled, a sysctl option with name "chroot_deny_chmod" is -+ created. -+ -+config GRKERNSEC_CHROOT_FCHDIR -+ bool "Deny fchdir out of chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, a well-known method of breaking chroots by fchdir= 'ing -+ to a file descriptor of the chrooting process that points to a direc= tory -+ outside the filesystem will be stopped. If the sysctl option -+ is enabled, a sysctl option with name "chroot_deny_fchdir" is create= d. -+ -+config GRKERNSEC_CHROOT_MKNOD -+ bool "Deny mknod" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be allowed to -+ mknod. The problem with using mknod inside a chroot is that it -+ would allow an attacker to create a device entry that is the same -+ as one on the physical root of your system, which could range from -+ anything from the console device to a device for your harddrive (whi= ch -+ they could then use to wipe the drive or steal data). It is recomme= nded -+ that you say Y here, unless you run into software incompatibilities. -+ If the sysctl option is enabled, a sysctl option with name -+ "chroot_deny_mknod" is created. -+ -+config GRKERNSEC_CHROOT_SHMAT -+ bool "Deny shmat() out of chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to att= ach -+ to shared memory segments that were created outside of the chroot ja= il. -+ It is recommended that you say Y here. If the sysctl option is enab= led, -+ a sysctl option with name "chroot_deny_shmat" is created. -+ -+config GRKERNSEC_CHROOT_UNIX -+ bool "Deny access to abstract AF_UNIX sockets out of chroot" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to -+ connect to abstract (meaning not belonging to a filesystem) Unix -+ domain sockets that were bound outside of a chroot. It is recommend= ed -+ that you say Y here. If the sysctl option is enabled, a sysctl opti= on -+ with name "chroot_deny_unix" is created. -+ -+config GRKERNSEC_CHROOT_FINDTASK -+ bool "Protect outside processes" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to -+ kill, send signals with fcntl, ptrace, capget, getpgid, setpgid,=20 -+ getsid, or view any process outside of the chroot. If the sysctl -+ option is enabled, a sysctl option with name "chroot_findtask" is -+ created. -+ -+config GRKERNSEC_CHROOT_NICE -+ bool "Restrict priority changes" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, processes inside a chroot will not be able to rai= se -+ the priority of processes in the chroot, or alter the priority of -+ processes outside the chroot. This provides more security than simp= ly -+ removing CAP_SYS_NICE from the process' capability set. If the -+ sysctl option is enabled, a sysctl option with name "chroot_restrict= _nice" -+ is created. -+ -+config GRKERNSEC_CHROOT_SYSCTL -+ bool "Deny sysctl writes" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, an attacker in a chroot will not be able to -+ write to sysctl entries, either by sysctl(2) or through a /proc -+ interface. It is strongly recommended that you say Y here. If the -+ sysctl option is enabled, a sysctl option with name -+ "chroot_deny_sysctl" is created. -+ -+config GRKERNSEC_CHROOT_CAPS -+ bool "Capability restrictions" -+ depends on GRKERNSEC_CHROOT -+ help -+ If you say Y here, the capabilities on all processes within a -+ chroot jail will be lowered to stop module insertion, raw i/o, -+ system and net admin tasks, rebooting the system, modifying immutabl= e -+ files, modifying IPC owned by another, and changing the system time. -+ This is left an option because it can break some apps. Disable this -+ if your chrooted apps are having problems performing those kinds of -+ tasks. If the sysctl option is enabled, a sysctl option with -+ name "chroot_caps" is created. -+ -+endmenu -+menu "Kernel Auditing" -+depends on GRKERNSEC -+ -+config GRKERNSEC_AUDIT_GROUP -+ bool "Single group for auditing" -+ help -+ If you say Y here, the exec, chdir, and (un)mount logging features -+ will only operate on a group you specify. This option is recommende= d -+ if you only want to watch certain users instead of having a large -+ amount of logs from the entire system. If the sysctl option is enab= led, -+ a sysctl option with name "audit_group" is created. -+ -+config GRKERNSEC_AUDIT_GID -+ int "GID for auditing" -+ depends on GRKERNSEC_AUDIT_GROUP -+ default 1007 -+ -+config GRKERNSEC_EXECLOG -+ bool "Exec logging" -+ help -+ If you say Y here, all execve() calls will be logged (since the -+ other exec*() calls are frontends to execve(), all execution -+ will be logged). Useful for shell-servers that like to keep track -+ of their users. If the sysctl option is enabled, a sysctl option wi= th -+ name "exec_logging" is created. -+ WARNING: This option when enabled will produce a LOT of logs, especi= ally -+ on an active system. -+ -+config GRKERNSEC_RESLOG -+ bool "Resource logging" -+ help -+ If you say Y here, all attempts to overstep resource limits will -+ be logged with the resource name, the requested size, and the curren= t -+ limit. It is highly recommended that you say Y here. If the sysctl -+ option is enabled, a sysctl option with name "resource_logging" is -+ created. If the RBAC system is enabled, the sysctl value is ignored= . -+ -+config GRKERNSEC_CHROOT_EXECLOG -+ bool "Log execs within chroot" -+ help -+ If you say Y here, all executions inside a chroot jail will be logge= d -+ to syslog. This can cause a large amount of logs if certain -+ applications (eg. djb's daemontools) are installed on the system, an= d -+ is therefore left as an option. If the sysctl option is enabled, a -+ sysctl option with name "chroot_execlog" is created. -+ -+config GRKERNSEC_AUDIT_PTRACE -+ bool "Ptrace logging" -+ help -+ If you say Y here, all attempts to attach to a process via ptrace -+ will be logged. If the sysctl option is enabled, a sysctl option -+ with name "audit_ptrace" is created. -+ -+config GRKERNSEC_AUDIT_CHDIR -+ bool "Chdir logging" -+ help -+ If you say Y here, all chdir() calls will be logged. If the sysctl -+ option is enabled, a sysctl option with name "audit_chdir" is creat= ed. -+ -+config GRKERNSEC_AUDIT_MOUNT -+ bool "(Un)Mount logging" -+ help -+ If you say Y here, all mounts and unmounts will be logged. If the -+ sysctl option is enabled, a sysctl option with name "audit_mount" is -+ created. -+ -+config GRKERNSEC_SIGNAL -+ bool "Signal logging" -+ help -+ If you say Y here, certain important signals will be logged, such as -+ SIGSEGV, which will as a result inform you of when a error in a prog= ram -+ occurred, which in some cases could mean a possible exploit attempt. -+ If the sysctl option is enabled, a sysctl option with name -+ "signal_logging" is created. -+ -+config GRKERNSEC_FORKFAIL -+ bool "Fork failure logging" -+ help -+ If you say Y here, all failed fork() attempts will be logged. -+ This could suggest a fork bomb, or someone attempting to overstep -+ their process limit. If the sysctl option is enabled, a sysctl opti= on -+ with name "forkfail_logging" is created. -+ -+config GRKERNSEC_TIME -+ bool "Time change logging" -+ help -+ If you say Y here, any changes of the system clock will be logged. -+ If the sysctl option is enabled, a sysctl option with name -+ "timechange_logging" is created. -+ -+config GRKERNSEC_PROC_IPADDR -+ bool "/proc//ipaddr support" -+ help -+ If you say Y here, a new entry will be added to each /proc/ -+ directory that contains the IP address of the person using the task. -+ The IP is carried across local TCP and AF_UNIX stream sockets. -+ This information can be useful for IDS/IPSes to perform remote respo= nse -+ to a local attack. The entry is readable by only the owner of the -+ process (and root if he has CAP_DAC_OVERRIDE, which can be removed v= ia -+ the RBAC system), and thus does not create privacy concerns. -+ -+config GRKERNSEC_RWXMAP_LOG -+ bool 'Denied RWX mmap/mprotect logging' -+ depends on PAX_MPROTECT && !PAX_EMUPLT && !PAX_EMUSIGRT -+ help -+ If you say Y here, calls to mmap() and mprotect() with explicit -+ usage of PROT_WRITE and PROT_EXEC together will be logged when -+ denied by the PAX_MPROTECT feature. If the sysctl option is -+ enabled, a sysctl option with name "rwxmap_logging" is created. -+ -+config GRKERNSEC_AUDIT_TEXTREL -+ bool 'ELF text relocations logging (READ HELP)' -+ depends on PAX_MPROTECT -+ help -+ If you say Y here, text relocations will be logged with the filename -+ of the offending library or binary. The purpose of the feature is -+ to help Linux distribution developers get rid of libraries and -+ binaries that need text relocations which hinder the future progress -+ of PaX. Only Linux distribution developers should say Y here, and -+ never on a production machine, as this option creates an information -+ leak that could aid an attacker in defeating the randomization of -+ a single memory region. If the sysctl option is enabled, a sysctl -+ option with name "audit_textrel" is created. -+ -+endmenu -+ -+menu "Executable Protections" -+depends on GRKERNSEC -+ -+config GRKERNSEC_DMESG -+ bool "Dmesg(8) restriction" -+ help -+ If you say Y here, non-root users will not be able to use dmesg(8) -+ to view up to the last 4kb of messages in the kernel's log buffer. -+ The kernel's log buffer often contains kernel addresses and other -+ identifying information useful to an attacker in fingerprinting a -+ system for a targeted exploit. -+ If the sysctl option is enabled, a sysctl option with name "dmesg" i= s -+ created. -+ -+config GRKERNSEC_HARDEN_PTRACE -+ bool "Deter ptrace-based process snooping" -+ help -+ If you say Y here, TTY sniffers and other malicious monitoring -+ programs implemented through ptrace will be defeated. If you -+ have been using the RBAC system, this option has already been -+ enabled for several years for all users, with the ability to make -+ fine-grained exceptions. -+ -+ This option only affects the ability of non-root users to ptrace -+ processes that are not a descendent of the ptracing process. -+ This means that strace ./binary and gdb ./binary will still work, -+ but attaching to arbitrary processes will not. If the sysctl -+ option is enabled, a sysctl option with name "harden_ptrace" is -+ created. -+ -+config GRKERNSEC_TPE -+ bool "Trusted Path Execution (TPE)" -+ help -+ If you say Y here, you will be able to choose a gid to add to the -+ supplementary groups of users you want to mark as "untrusted." -+ These users will not be able to execute any files that are not in -+ root-owned directories writable only by root. If the sysctl option -+ is enabled, a sysctl option with name "tpe" is created. -+ -+config GRKERNSEC_TPE_ALL -+ bool "Partially restrict all non-root users" -+ depends on GRKERNSEC_TPE -+ help -+ If you say Y here, all non-root users will be covered under -+ a weaker TPE restriction. This is separate from, and in addition to= , -+ the main TPE options that you have selected elsewhere. Thus, if a -+ "trusted" GID is chosen, this restriction applies to even that GID. -+ Under this restriction, all non-root users will only be allowed to -+ execute files in directories they own that are not group or -+ world-writable, or in directories owned by root and writable only by -+ root. If the sysctl option is enabled, a sysctl option with name -+ "tpe_restrict_all" is created. -+ -+config GRKERNSEC_TPE_INVERT -+ bool "Invert GID option" -+ depends on GRKERNSEC_TPE -+ help -+ If you say Y here, the group you specify in the TPE configuration wi= ll -+ decide what group TPE restrictions will be *disabled* for. This -+ option is useful if you want TPE restrictions to be applied to most -+ users on the system. If the sysctl option is enabled, a sysctl opti= on -+ with name "tpe_invert" is created. Unlike other sysctl options, thi= s -+ entry will default to on for backward-compatibility. -+ -+config GRKERNSEC_TPE_GID -+ int "GID for untrusted users" -+ depends on GRKERNSEC_TPE && !GRKERNSEC_TPE_INVERT -+ default 1005 -+ help -+ Setting this GID determines what group TPE restrictions will be -+ *enabled* for. If the sysctl option is enabled, a sysctl option -+ with name "tpe_gid" is created. -+ -+config GRKERNSEC_TPE_GID -+ int "GID for trusted users" -+ depends on GRKERNSEC_TPE && GRKERNSEC_TPE_INVERT -+ default 1005 -+ help -+ Setting this GID determines what group TPE restrictions will be -+ *disabled* for. If the sysctl option is enabled, a sysctl option -+ with name "tpe_gid" is created. -+ -+endmenu -+menu "Network Protections" -+depends on GRKERNSEC -+ -+config GRKERNSEC_RANDNET -+ bool "Larger entropy pools" -+ help -+ If you say Y here, the entropy pools used for many features of Linux -+ and grsecurity will be doubled in size. Since several grsecurity -+ features use additional randomness, it is recommended that you say Y -+ here. Saying Y here has a similar effect as modifying -+ /proc/sys/kernel/random/poolsize. -+ -+config GRKERNSEC_BLACKHOLE -+ bool "TCP/UDP blackhole and LAST_ACK DoS prevention" -+ depends on NET -+ help -+ If you say Y here, neither TCP resets nor ICMP -+ destination-unreachable packets will be sent in response to packets -+ sent to ports for which no associated listening process exists. -+ This feature supports both IPV4 and IPV6 and exempts the=20 -+ loopback interface from blackholing. Enabling this feature=20 -+ makes a host more resilient to DoS attacks and reduces network -+ visibility against scanners. -+ -+ The blackhole feature as-implemented is equivalent to the FreeBSD -+ blackhole feature, as it prevents RST responses to all packets, not -+ just SYNs. Under most application behavior this causes no -+ problems, but applications (like haproxy) may not close certain -+ connections in a way that cleanly terminates them on the remote -+ end, leaving the remote host in LAST_ACK state. Because of this -+ side-effect and to prevent intentional LAST_ACK DoSes, this -+ feature also adds automatic mitigation against such attacks. -+ The mitigation drastically reduces the amount of time a socket -+ can spend in LAST_ACK state. If you're using haproxy and not -+ all servers it connects to have this option enabled, consider -+ disabling this feature on the haproxy host. -+ -+ If the sysctl option is enabled, two sysctl options with names -+ "ip_blackhole" and "lastack_retries" will be created. -+ While "ip_blackhole" takes the standard zero/non-zero on/off -+ toggle, "lastack_retries" uses the same kinds of values as -+ "tcp_retries1" and "tcp_retries2". The default value of 4 -+ prevents a socket from lasting more than 45 seconds in LAST_ACK -+ state. -+ -+config GRKERNSEC_SOCKET -+ bool "Socket restrictions" -+ depends on NET -+ help -+ If you say Y here, you will be able to choose from several options. -+ If you assign a GID on your system and add it to the supplementary -+ groups of users you want to restrict socket access to, this patch -+ will perform up to three things, based on the option(s) you choose. -+ -+config GRKERNSEC_SOCKET_ALL -+ bool "Deny any sockets to group" -+ depends on GRKERNSEC_SOCKET -+ help -+ If you say Y here, you will be able to choose a GID of whose users w= ill -+ be unable to connect to other hosts from your machine or run server -+ applications from your machine. If the sysctl option is enabled, a -+ sysctl option with name "socket_all" is created. -+ -+config GRKERNSEC_SOCKET_ALL_GID -+ int "GID to deny all sockets for" -+ depends on GRKERNSEC_SOCKET_ALL -+ default 1004 -+ help -+ Here you can choose the GID to disable socket access for. Remember t= o -+ add the users you want socket access disabled for to the GID -+ specified here. If the sysctl option is enabled, a sysctl option -+ with name "socket_all_gid" is created. ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_CHMOD ++ { ++ .procname =3D "chroot_deny_chmod", ++ .data =3D &grsec_enable_chroot_chmod, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_MKNOD ++ { ++ .procname =3D "chroot_deny_mknod", ++ .data =3D &grsec_enable_chroot_mknod, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_NICE ++ { ++ .procname =3D "chroot_restrict_nice", ++ .data =3D &grsec_enable_chroot_nice, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_EXECLOG ++ { ++ .procname =3D "chroot_execlog", ++ .data =3D &grsec_enable_chroot_execlog, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_CAPS ++ { ++ .procname =3D "chroot_caps", ++ .data =3D &grsec_enable_chroot_caps, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_SYSCTL ++ { ++ .procname =3D "chroot_deny_sysctl", ++ .data =3D &grsec_enable_chroot_sysctl, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_TPE ++ { ++ .procname =3D "tpe", ++ .data =3D &grsec_enable_tpe, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .procname =3D "tpe_gid", ++ .data =3D &grsec_tpe_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_TPE_INVERT ++ { ++ .procname =3D "tpe_invert", ++ .data =3D &grsec_enable_tpe_invert, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_TPE_ALL ++ { ++ .procname =3D "tpe_restrict_all", ++ .data =3D &grsec_enable_tpe_all, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_SOCKET_ALL ++ { ++ .procname =3D "socket_all", ++ .data =3D &grsec_enable_socket_all, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .procname =3D "socket_all_gid", ++ .data =3D &grsec_socket_all_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_SOCKET_CLIENT ++ { ++ .procname =3D "socket_client", ++ .data =3D &grsec_enable_socket_client, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .procname =3D "socket_client_gid", ++ .data =3D &grsec_socket_client_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_SOCKET_SERVER ++ { ++ .procname =3D "socket_server", ++ .data =3D &grsec_enable_socket_server, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .procname =3D "socket_server_gid", ++ .data =3D &grsec_socket_server_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_GROUP ++ { ++ .procname =3D "audit_group", ++ .data =3D &grsec_enable_group, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++ { ++ .procname =3D "audit_gid", ++ .data =3D &grsec_audit_gid, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_CHDIR ++ { ++ .procname =3D "audit_chdir", ++ .data =3D &grsec_enable_chdir, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_MOUNT ++ { ++ .procname =3D "audit_mount", ++ .data =3D &grsec_enable_mount, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_TEXTREL ++ { ++ .procname =3D "audit_textrel", ++ .data =3D &grsec_enable_audit_textrel, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_DMESG ++ { ++ .procname =3D "dmesg", ++ .data =3D &grsec_enable_dmesg, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_CHROOT_FINDTASK ++ { ++ .procname =3D "chroot_findtask", ++ .data =3D &grsec_enable_chroot_findtask, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_RESLOG ++ { ++ .procname =3D "resource_logging", ++ .data =3D &grsec_resource_logging, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_AUDIT_PTRACE ++ { ++ .procname =3D "audit_ptrace", ++ .data =3D &grsec_enable_audit_ptrace, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_HARDEN_PTRACE ++ { ++ .procname =3D "harden_ptrace", ++ .data =3D &grsec_enable_harden_ptrace, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++ { ++ .procname =3D "grsec_lock", ++ .data =3D &grsec_lock, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec, ++ }, ++#endif ++#ifdef CONFIG_GRKERNSEC_ROFS ++ { ++ .procname =3D "romount_protect", ++ .data =3D &grsec_enable_rofs, ++ .maxlen =3D sizeof(int), ++ .mode =3D 0600, ++ .proc_handler =3D &proc_dointvec_minmax, ++ .extra1 =3D &one, ++ .extra2 =3D &one, ++ }, ++#endif ++ { } ++}; ++#endif +diff --git a/grsecurity/grsec_time.c b/grsecurity/grsec_time.c +new file mode 100644 +index 0000000..0dc13c3 +--- /dev/null ++++ b/grsecurity/grsec_time.c +@@ -0,0 +1,16 @@ ++#include ++#include ++#include ++#include + -+config GRKERNSEC_SOCKET_CLIENT -+ bool "Deny client sockets to group" -+ depends on GRKERNSEC_SOCKET -+ help -+ If you say Y here, you will be able to choose a GID of whose users w= ill -+ be unable to connect to other hosts from your machine, but will be -+ able to run servers. If this option is enabled, all users in the gr= oup -+ you specify will have to use passive mode when initiating ftp transf= ers -+ from the shell on your machine. If the sysctl option is enabled, a -+ sysctl option with name "socket_client" is created. ++void ++gr_log_timechange(void) ++{ ++#ifdef CONFIG_GRKERNSEC_TIME ++ if (grsec_enable_time) ++ gr_log_noargs(GR_DONT_AUDIT_GOOD, GR_TIME_MSG); ++#endif ++ return; ++} + -+config GRKERNSEC_SOCKET_CLIENT_GID -+ int "GID to deny client sockets for" -+ depends on GRKERNSEC_SOCKET_CLIENT -+ default 1003 -+ help -+ Here you can choose the GID to disable client socket access for. -+ Remember to add the users you want client socket access disabled for= to -+ the GID specified here. If the sysctl option is enabled, a sysctl -+ option with name "socket_client_gid" is created. ++EXPORT_SYMBOL(gr_log_timechange); +diff --git a/grsecurity/grsec_tpe.c b/grsecurity/grsec_tpe.c +new file mode 100644 +index 0000000..4a78774 +--- /dev/null ++++ b/grsecurity/grsec_tpe.c +@@ -0,0 +1,39 @@ ++#include ++#include ++#include ++#include ++#include + -+config GRKERNSEC_SOCKET_SERVER -+ bool "Deny server sockets to group" -+ depends on GRKERNSEC_SOCKET -+ help -+ If you say Y here, you will be able to choose a GID of whose users w= ill -+ be unable to run server applications from your machine. If the sysc= tl -+ option is enabled, a sysctl option with name "socket_server" is crea= ted. ++extern int gr_acl_tpe_check(void); + -+config GRKERNSEC_SOCKET_SERVER_GID -+ int "GID to deny server sockets for" -+ depends on GRKERNSEC_SOCKET_SERVER -+ default 1002 -+ help -+ Here you can choose the GID to disable server socket access for. -+ Remember to add the users you want server socket access disabled for= to -+ the GID specified here. If the sysctl option is enabled, a sysctl -+ option with name "socket_server_gid" is created. ++int ++gr_tpe_allow(const struct file *file) ++{ ++#ifdef CONFIG_GRKERNSEC ++ struct inode *inode =3D file->f_path.dentry->d_parent->d_inode; ++ const struct cred *cred =3D current_cred(); + -+endmenu -+menu "Sysctl support" -+depends on GRKERNSEC && SYSCTL ++ if (cred->uid && ((grsec_enable_tpe && ++#ifdef CONFIG_GRKERNSEC_TPE_INVERT ++ ((grsec_enable_tpe_invert && !in_group_p(grsec_tpe_gid)) || ++ (!grsec_enable_tpe_invert && in_group_p(grsec_tpe_gid))) ++#else ++ in_group_p(grsec_tpe_gid) ++#endif ++ ) || gr_acl_tpe_check()) && ++ (inode->i_uid || (!inode->i_uid && ((inode->i_mode & S_IWGRP) || ++ (inode->i_mode & S_IWOTH))))) { ++ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); ++ return 0; ++ } ++#ifdef CONFIG_GRKERNSEC_TPE_ALL ++ if (cred->uid && grsec_enable_tpe && grsec_enable_tpe_all && ++ ((inode->i_uid && (inode->i_uid !=3D cred->uid)) || ++ (inode->i_mode & S_IWGRP) || (inode->i_mode & S_IWOTH))) { ++ gr_log_fs_generic(GR_DONT_AUDIT, GR_EXEC_TPE_MSG, file->f_path.dentry= , file->f_path.mnt); ++ return 0; ++ } ++#endif ++#endif ++ return 1; ++} +diff --git a/grsecurity/grsum.c b/grsecurity/grsum.c +new file mode 100644 +index 0000000..9f7b1ac +--- /dev/null ++++ b/grsecurity/grsum.c +@@ -0,0 +1,61 @@ ++#include ++#include ++#include ++#include ++#include ++#include ++#include + -+config GRKERNSEC_SYSCTL -+ bool "Sysctl support" -+ help -+ If you say Y here, you will be able to change the options that -+ grsecurity runs with at bootup, without having to recompile your -+ kernel. You can echo values to files in /proc/sys/kernel/grsecurity -+ to enable (1) or disable (0) various features. All the sysctl entri= es -+ are mutable until the "grsec_lock" entry is set to a non-zero value. -+ All features enabled in the kernel configuration are disabled at boo= t -+ if you do not say Y to the "Turn on features by default" option. -+ All options should be set at startup, and the grsec_lock entry shoul= d -+ be set to a non-zero value after all the options are set. -+ *THIS IS EXTREMELY IMPORTANT* + -+config GRKERNSEC_SYSCTL_DISTRO -+ bool "Extra sysctl support for distro makers (READ HELP)" -+ depends on GRKERNSEC_SYSCTL && GRKERNSEC_IO -+ help -+ If you say Y here, additional sysctl options will be created -+ for features that affect processes running as root. Therefore, -+ it is critical when using this option that the grsec_lock entry be -+ enabled after boot. Only distros with prebuilt kernel packages -+ with this option enabled that can ensure grsec_lock is enabled -+ after boot should use this option. -+ *Failure to set grsec_lock after boot makes all grsec features -+ this option covers useless* ++#if !defined(CONFIG_CRYPTO) || defined(CONFIG_CRYPTO_MODULE) || !define= d(CONFIG_CRYPTO_SHA256) || defined(CONFIG_CRYPTO_SHA256_MODULE) ++#error "crypto and sha256 must be built into the kernel" ++#endif + -+ Currently this option creates the following sysctl entries: -+ "Disable Privileged I/O": "disable_priv_io"=09 ++int ++chkpw(struct gr_arg *entry, unsigned char *salt, unsigned char *sum) ++{ ++ char *p; ++ struct crypto_hash *tfm; ++ struct hash_desc desc; ++ struct scatterlist sg; ++ unsigned char temp_sum[GR_SHA_LEN]; ++ volatile int retval =3D 0; ++ volatile int dummy =3D 0; ++ unsigned int i; + -+config GRKERNSEC_SYSCTL_ON -+ bool "Turn on features by default" -+ depends on GRKERNSEC_SYSCTL -+ help -+ If you say Y here, instead of having all features enabled in the -+ kernel configuration disabled at boot time, the features will be -+ enabled at boot time. It is recommended you say Y here unless -+ there is some reason you would want all sysctl-tunable features to -+ be disabled by default. As mentioned elsewhere, it is important -+ to enable the grsec_lock entry once you have finished modifying -+ the sysctl entries. ++ sg_init_table(&sg, 1); + -+endmenu -+menu "Logging Options" -+depends on GRKERNSEC ++ tfm =3D crypto_alloc_hash("sha256", 0, CRYPTO_ALG_ASYNC); ++ if (IS_ERR(tfm)) { ++ /* should never happen, since sha256 should be built in */ ++ return 1; ++ } + -+config GRKERNSEC_FLOODTIME -+ int "Seconds in between log messages (minimum)" -+ default 10 -+ help -+ This option allows you to enforce the number of seconds between -+ grsecurity log messages. The default should be suitable for most -+ people, however, if you choose to change it, choose a value small en= ough -+ to allow informative logs to be produced, but large enough to -+ prevent flooding. ++ desc.tfm =3D tfm; ++ desc.flags =3D 0; + -+config GRKERNSEC_FLOODBURST -+ int "Number of messages in a burst (maximum)" -+ default 6 -+ help -+ This option allows you to choose the maximum number of messages allo= wed -+ within the flood time interval you chose in a separate option. The -+ default should be suitable for most people, however if you find that -+ many of your logs are being interpreted as flooding, you may want to -+ raise this value. ++ crypto_hash_init(&desc); + -+endmenu ++ p =3D salt; ++ sg_set_buf(&sg, p, GR_SALT_LEN); ++ crypto_hash_update(&desc, &sg, sg.length); + -+endmenu -diff -urNp linux-3.1.4/grsecurity/Makefile linux-3.1.4/grsecurity/Makefi= le ---- linux-3.1.4/grsecurity/Makefile 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.1.4/grsecurity/Makefile 2011-11-16 18:40:31.000000000 -0500 -@@ -0,0 +1,36 @@ -+# grsecurity's ACL system was originally written in 2001 by Michael Dal= ton -+# during 2001-2009 it has been completely redesigned by Brad Spengler -+# into an RBAC system -+# -+# All code in this directory and various hooks inserted throughout the = kernel -+# are copyright Brad Spengler - Open Source Security, Inc., and release= d=20 -+# under the GPL v2 or higher ++ p =3D entry->pw; ++ sg_set_buf(&sg, p, strlen(p)); ++=09 ++ crypto_hash_update(&desc, &sg, sg.length); + -+obj-y =3D grsec_chdir.o grsec_chroot.o grsec_exec.o grsec_fifo.o grsec_= fork.o \ -+ grsec_mount.o grsec_sig.o grsec_sysctl.o \ -+ grsec_time.o grsec_tpe.o grsec_link.o grsec_pax.o grsec_ptrace.o ++ crypto_hash_final(&desc, temp_sum); + -+obj-$(CONFIG_GRKERNSEC) +=3D grsec_init.o grsum.o gracl.o gracl_segv.o = \ -+ gracl_cap.o gracl_alloc.o gracl_shm.o grsec_mem.o gracl_fs.o \ -+ gracl_learn.o grsec_log.o -+obj-$(CONFIG_GRKERNSEC_RESLOG) +=3D gracl_res.o ++ memset(entry->pw, 0, GR_PW_LEN); + -+ifdef CONFIG_NET -+obj-y +=3D grsec_sock.o -+obj-$(CONFIG_GRKERNSEC) +=3D gracl_ip.o -+endif ++ for (i =3D 0; i < GR_SHA_LEN; i++) ++ if (sum[i] !=3D temp_sum[i]) ++ retval =3D 1; ++ else ++ dummy =3D 1; // waste a cycle + -+ifndef CONFIG_GRKERNSEC -+obj-y +=3D grsec_disabled.o -+endif ++ crypto_free_hash(tfm); + -+ifdef CONFIG_GRKERNSEC_HIDESYM -+extra-y :=3D grsec_hidesym.o -+$(obj)/grsec_hidesym.o: -+ @-chmod -f 500 /boot -+ @-chmod -f 500 /lib/modules -+ @-chmod -f 500 /lib64/modules -+ @-chmod -f 500 /lib32/modules -+ @-chmod -f 700 . -+ @echo ' grsec: protected kernel image paths' -+endif -diff -urNp linux-3.1.4/include/acpi/acpi_bus.h linux-3.1.4/include/acpi/= acpi_bus.h ---- linux-3.1.4/include/acpi/acpi_bus.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/acpi/acpi_bus.h 2011-11-16 18:39:08.000000000 -0= 500 ++ return retval; ++} +diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h +index 6cd5b64..f620d2d 100644 +--- a/include/acpi/acpi_bus.h ++++ b/include/acpi/acpi_bus.h @@ -107,7 +107,7 @@ struct acpi_device_ops { acpi_op_bind bind; acpi_op_unbind unbind; @@ -57871,9 +59305,10 @@ diff -urNp linux-3.1.4/include/acpi/acpi_bus.h l= inux-3.1.4/include/acpi/acpi_bus =20 #define ACPI_DRIVER_ALL_NOTIFY_EVENTS 0x1 /* system AND device events *= / =20 -diff -urNp linux-3.1.4/include/asm-generic/atomic-long.h linux-3.1.4/inc= lude/asm-generic/atomic-long.h ---- linux-3.1.4/include/asm-generic/atomic-long.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/include/asm-generic/atomic-long.h 2011-11-16 18:39:08.00= 0000000 -0500 +diff --git a/include/asm-generic/atomic-long.h b/include/asm-generic/ato= mic-long.h +index b7babf0..71e4e74 100644 +--- a/include/asm-generic/atomic-long.h ++++ b/include/asm-generic/atomic-long.h @@ -22,6 +22,12 @@ =20 typedef atomic64_t atomic_long_t; @@ -57887,7 +59322,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm #define ATOMIC_LONG_INIT(i) ATOMIC64_INIT(i) =20 static inline long atomic_long_read(atomic_long_t *l) -@@ -31,6 +37,15 @@ static inline long atomic_long_read(atom +@@ -31,6 +37,15 @@ static inline long atomic_long_read(atomic_long_t *l) return (long)atomic64_read(v); } =20 @@ -57903,7 +59338,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_set(atomic_long_t *l, long i) { atomic64_t *v =3D (atomic64_t *)l; -@@ -38,6 +53,15 @@ static inline void atomic_long_set(atomi +@@ -38,6 +53,15 @@ static inline void atomic_long_set(atomic_long_t *l, = long i) atomic64_set(v, i); } =20 @@ -57919,7 +59354,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_inc(atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -45,6 +69,15 @@ static inline void atomic_long_inc(atomi +@@ -45,6 +69,15 @@ static inline void atomic_long_inc(atomic_long_t *l) atomic64_inc(v); } =20 @@ -57935,7 +59370,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_dec(atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -52,6 +85,15 @@ static inline void atomic_long_dec(atomi +@@ -52,6 +85,15 @@ static inline void atomic_long_dec(atomic_long_t *l) atomic64_dec(v); } =20 @@ -57951,7 +59386,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_add(long i, atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -59,6 +101,15 @@ static inline void atomic_long_add(long=20 +@@ -59,6 +101,15 @@ static inline void atomic_long_add(long i, atomic_lo= ng_t *l) atomic64_add(i, v); } =20 @@ -57967,7 +59402,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_sub(long i, atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -66,6 +117,15 @@ static inline void atomic_long_sub(long=20 +@@ -66,6 +117,15 @@ static inline void atomic_long_sub(long i, atomic_lo= ng_t *l) atomic64_sub(i, v); } =20 @@ -57983,7 +59418,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline int atomic_long_sub_and_test(long i, atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -115,6 +175,15 @@ static inline long atomic_long_inc_retur +@@ -115,6 +175,15 @@ static inline long atomic_long_inc_return(atomic_lo= ng_t *l) return (long)atomic64_inc_return(v); } =20 @@ -57999,7 +59434,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline long atomic_long_dec_return(atomic_long_t *l) { atomic64_t *v =3D (atomic64_t *)l; -@@ -140,6 +209,12 @@ static inline long atomic_long_add_unles +@@ -140,6 +209,12 @@ static inline long atomic_long_add_unless(atomic_lo= ng_t *l, long a, long u) =20 typedef atomic_t atomic_long_t; =20 @@ -58012,7 +59447,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm #define ATOMIC_LONG_INIT(i) ATOMIC_INIT(i) static inline long atomic_long_read(atomic_long_t *l) { -@@ -148,6 +223,15 @@ static inline long atomic_long_read(atom +@@ -148,6 +223,15 @@ static inline long atomic_long_read(atomic_long_t *= l) return (long)atomic_read(v); } =20 @@ -58028,7 +59463,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_set(atomic_long_t *l, long i) { atomic_t *v =3D (atomic_t *)l; -@@ -155,6 +239,15 @@ static inline void atomic_long_set(atomi +@@ -155,6 +239,15 @@ static inline void atomic_long_set(atomic_long_t *l= , long i) atomic_set(v, i); } =20 @@ -58044,7 +59479,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_inc(atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -162,6 +255,15 @@ static inline void atomic_long_inc(atomi +@@ -162,6 +255,15 @@ static inline void atomic_long_inc(atomic_long_t *l= ) atomic_inc(v); } =20 @@ -58060,7 +59495,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_dec(atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -169,6 +271,15 @@ static inline void atomic_long_dec(atomi +@@ -169,6 +271,15 @@ static inline void atomic_long_dec(atomic_long_t *l= ) atomic_dec(v); } =20 @@ -58076,7 +59511,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_add(long i, atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -176,6 +287,15 @@ static inline void atomic_long_add(long=20 +@@ -176,6 +287,15 @@ static inline void atomic_long_add(long i, atomic_l= ong_t *l) atomic_add(i, v); } =20 @@ -58092,7 +59527,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline void atomic_long_sub(long i, atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -183,6 +303,15 @@ static inline void atomic_long_sub(long=20 +@@ -183,6 +303,15 @@ static inline void atomic_long_sub(long i, atomic_l= ong_t *l) atomic_sub(i, v); } =20 @@ -58108,7 +59543,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline int atomic_long_sub_and_test(long i, atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -232,6 +361,15 @@ static inline long atomic_long_inc_retur +@@ -232,6 +361,15 @@ static inline long atomic_long_inc_return(atomic_lo= ng_t *l) return (long)atomic_inc_return(v); } =20 @@ -58124,7 +59559,7 @@ diff -urNp linux-3.1.4/include/asm-generic/atomic= -long.h linux-3.1.4/include/asm static inline long atomic_long_dec_return(atomic_long_t *l) { atomic_t *v =3D (atomic_t *)l; -@@ -255,4 +393,49 @@ static inline long atomic_long_add_unles +@@ -255,4 +393,49 @@ static inline long atomic_long_add_unless(atomic_lo= ng_t *l, long a, long u) =20 #endif /* BITS_PER_LONG =3D=3D 64 */ =20 @@ -58174,9 +59609,10 @@ diff -urNp linux-3.1.4/include/asm-generic/atomi= c-long.h linux-3.1.4/include/asm +#endif + #endif /* _ASM_GENERIC_ATOMIC_LONG_H */ -diff -urNp linux-3.1.4/include/asm-generic/cache.h linux-3.1.4/include/a= sm-generic/cache.h ---- linux-3.1.4/include/asm-generic/cache.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/asm-generic/cache.h 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/include/asm-generic/cache.h b/include/asm-generic/cache.h +index 1bfcfe5..e04c5c9 100644 +--- a/include/asm-generic/cache.h ++++ b/include/asm-generic/cache.h @@ -6,7 +6,7 @@ * cache lines need to provide their own cache.h. */ @@ -58187,9 +59623,10 @@ diff -urNp linux-3.1.4/include/asm-generic/cache= .h linux-3.1.4/include/asm-gener +#define L1_CACHE_BYTES (1UL << L1_CACHE_SHIFT) =20 #endif /* __ASM_GENERIC_CACHE_H */ -diff -urNp linux-3.1.4/include/asm-generic/int-l64.h linux-3.1.4/include= /asm-generic/int-l64.h ---- linux-3.1.4/include/asm-generic/int-l64.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/include/asm-generic/int-l64.h 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/include/asm-generic/int-l64.h b/include/asm-generic/int-l64= .h +index 1ca3efc..e3dc852 100644 +--- a/include/asm-generic/int-l64.h ++++ b/include/asm-generic/int-l64.h @@ -46,6 +46,8 @@ typedef unsigned int u32; typedef signed long s64; typedef unsigned long u64; @@ -58199,9 +59636,10 @@ diff -urNp linux-3.1.4/include/asm-generic/int-l= 64.h linux-3.1.4/include/asm-gen #define S8_C(x) x #define U8_C(x) x ## U #define S16_C(x) x -diff -urNp linux-3.1.4/include/asm-generic/int-ll64.h linux-3.1.4/includ= e/asm-generic/int-ll64.h ---- linux-3.1.4/include/asm-generic/int-ll64.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/include/asm-generic/int-ll64.h 2011-11-16 18:39:08.00000= 0000 -0500 +diff --git a/include/asm-generic/int-ll64.h b/include/asm-generic/int-ll= 64.h +index f394147..b6152b9 100644 +--- a/include/asm-generic/int-ll64.h ++++ b/include/asm-generic/int-ll64.h @@ -51,6 +51,8 @@ typedef unsigned int u32; typedef signed long long s64; typedef unsigned long long u64; @@ -58211,9 +59649,10 @@ diff -urNp linux-3.1.4/include/asm-generic/int-l= l64.h linux-3.1.4/include/asm-ge #define S8_C(x) x #define U8_C(x) x ## U #define S16_C(x) x -diff -urNp linux-3.1.4/include/asm-generic/kmap_types.h linux-3.1.4/incl= ude/asm-generic/kmap_types.h ---- linux-3.1.4/include/asm-generic/kmap_types.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/include/asm-generic/kmap_types.h 2011-11-16 18:39:08.000= 000000 -0500 +diff --git a/include/asm-generic/kmap_types.h b/include/asm-generic/kmap= _types.h +index 0232ccb..13d9165 100644 +--- a/include/asm-generic/kmap_types.h ++++ b/include/asm-generic/kmap_types.h @@ -29,10 +29,11 @@ KMAP_D(16) KM_IRQ_PTE, KMAP_D(17) KM_NMI, KMAP_D(18) KM_NMI_PTE, @@ -58227,27 +59666,10 @@ diff -urNp linux-3.1.4/include/asm-generic/kmap= _types.h linux-3.1.4/include/asm- }; =20 #undef KMAP_D -diff -urNp linux-3.1.4/include/asm-generic/pgtable.h linux-3.1.4/include= /asm-generic/pgtable.h ---- linux-3.1.4/include/asm-generic/pgtable.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/include/asm-generic/pgtable.h 2011-11-16 18:39:08.000000= 000 -0500 -@@ -443,6 +443,14 @@ static inline int pmd_write(pmd_t pmd) - #endif /* __HAVE_ARCH_PMD_WRITE */ - #endif -=20 -+#ifndef __HAVE_ARCH_PAX_OPEN_KERNEL -+static inline unsigned long pax_open_kernel(void) { return 0; } -+#endif -+ -+#ifndef __HAVE_ARCH_PAX_CLOSE_KERNEL -+static inline unsigned long pax_close_kernel(void) { return 0; } -+#endif -+ - #endif /* !__ASSEMBLY__ */ -=20 - #endif /* _ASM_GENERIC_PGTABLE_H */ -diff -urNp linux-3.1.4/include/asm-generic/pgtable-nopmd.h linux-3.1.4/i= nclude/asm-generic/pgtable-nopmd.h ---- linux-3.1.4/include/asm-generic/pgtable-nopmd.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/include/asm-generic/pgtable-nopmd.h 2011-11-16 18:39:08.= 000000000 -0500 +diff --git a/include/asm-generic/pgtable-nopmd.h b/include/asm-generic/p= gtable-nopmd.h +index 725612b..9cc513a 100644 +--- a/include/asm-generic/pgtable-nopmd.h ++++ b/include/asm-generic/pgtable-nopmd.h @@ -1,14 +1,19 @@ #ifndef _PGTABLE_NOPMD_H #define _PGTABLE_NOPMD_H @@ -58284,9 +59706,10 @@ diff -urNp linux-3.1.4/include/asm-generic/pgtab= le-nopmd.h linux-3.1.4/include/a /* * The "pud_xxx()" functions here are trivial for a folded two-level * setup: the pmd is never bad, and a pmd always exists (as it's folded -diff -urNp linux-3.1.4/include/asm-generic/pgtable-nopud.h linux-3.1.4/i= nclude/asm-generic/pgtable-nopud.h ---- linux-3.1.4/include/asm-generic/pgtable-nopud.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/include/asm-generic/pgtable-nopud.h 2011-11-16 18:39:08.= 000000000 -0500 +diff --git a/include/asm-generic/pgtable-nopud.h b/include/asm-generic/p= gtable-nopud.h +index 810431d..ccc3638 100644 +--- a/include/asm-generic/pgtable-nopud.h ++++ b/include/asm-generic/pgtable-nopud.h @@ -1,10 +1,15 @@ #ifndef _PGTABLE_NOPUD_H #define _PGTABLE_NOPUD_H @@ -58317,9 +59740,29 @@ diff -urNp linux-3.1.4/include/asm-generic/pgtab= le-nopud.h linux-3.1.4/include/a /* * The "pgd_xxx()" functions here are trivial for a folded two-level * setup: the pud is never bad, and a pud always exists (as it's folded -diff -urNp linux-3.1.4/include/asm-generic/vmlinux.lds.h linux-3.1.4/inc= lude/asm-generic/vmlinux.lds.h ---- linux-3.1.4/include/asm-generic/vmlinux.lds.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/include/asm-generic/vmlinux.lds.h 2011-11-16 18:39:08.00= 0000000 -0500 +diff --git a/include/asm-generic/pgtable.h b/include/asm-generic/pgtable= .h +index 76bff2b..c7a14e2 100644 +--- a/include/asm-generic/pgtable.h ++++ b/include/asm-generic/pgtable.h +@@ -443,6 +443,14 @@ static inline int pmd_write(pmd_t pmd) + #endif /* __HAVE_ARCH_PMD_WRITE */ + #endif +=20 ++#ifndef __HAVE_ARCH_PAX_OPEN_KERNEL ++static inline unsigned long pax_open_kernel(void) { return 0; } ++#endif ++ ++#ifndef __HAVE_ARCH_PAX_CLOSE_KERNEL ++static inline unsigned long pax_close_kernel(void) { return 0; } ++#endif ++ + #endif /* !__ASSEMBLY__ */ +=20 + #endif /* _ASM_GENERIC_PGTABLE_H */ +diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vml= inux.lds.h +index db22d13..1f2e3e1 100644 +--- a/include/asm-generic/vmlinux.lds.h ++++ b/include/asm-generic/vmlinux.lds.h @@ -217,6 +217,7 @@ .rodata : AT(ADDR(.rodata) - LOAD_OFFSET) { \ VMLINUX_SYMBOL(__start_rodata) =3D .; \ @@ -58351,30 +59794,10 @@ diff -urNp linux-3.1.4/include/asm-generic/vmli= nux.lds.h linux-3.1.4/include/asm =20 /** * PERCPU_SECTION - define output section for percpu area, simple versi= on -diff -urNp linux-3.1.4/include/drm/drm_crtc_helper.h linux-3.1.4/include= /drm/drm_crtc_helper.h ---- linux-3.1.4/include/drm/drm_crtc_helper.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/include/drm/drm_crtc_helper.h 2011-11-16 18:39:08.000000= 000 -0500 -@@ -74,7 +74,7 @@ struct drm_crtc_helper_funcs { -=20 - /* disable crtc when not in use - more explicit than dpms off */ - void (*disable)(struct drm_crtc *crtc); --}; -+} __no_const; -=20 - struct drm_encoder_helper_funcs { - void (*dpms)(struct drm_encoder *encoder, int mode); -@@ -95,7 +95,7 @@ struct drm_encoder_helper_funcs { - struct drm_connector *connector); - /* disable encoder when not in use - more explicit than dpms off */ - void (*disable)(struct drm_encoder *encoder); --}; -+} __no_const; -=20 - struct drm_connector_helper_funcs { - int (*get_modes)(struct drm_connector *connector); -diff -urNp linux-3.1.4/include/drm/drmP.h linux-3.1.4/include/drm/drmP.h ---- linux-3.1.4/include/drm/drmP.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/drm/drmP.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/drm/drmP.h b/include/drm/drmP.h +index 9b7c2bb..76b7d1e 100644 +--- a/include/drm/drmP.h ++++ b/include/drm/drmP.h @@ -73,6 +73,7 @@ #include #include @@ -58401,9 +59824,45 @@ diff -urNp linux-3.1.4/include/drm/drmP.h linux-= 3.1.4/include/drm/drmP.h /*@} */ =20 struct list_head filelist; -diff -urNp linux-3.1.4/include/drm/ttm/ttm_memory.h linux-3.1.4/include/= drm/ttm/ttm_memory.h ---- linux-3.1.4/include/drm/ttm/ttm_memory.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/include/drm/ttm/ttm_memory.h 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/include/drm/drm_crtc_helper.h b/include/drm/drm_crtc_helper= .h +index 73b0712..0b7ef2f 100644 +--- a/include/drm/drm_crtc_helper.h ++++ b/include/drm/drm_crtc_helper.h +@@ -74,7 +74,7 @@ struct drm_crtc_helper_funcs { +=20 + /* disable crtc when not in use - more explicit than dpms off */ + void (*disable)(struct drm_crtc *crtc); +-}; ++} __no_const; +=20 + struct drm_encoder_helper_funcs { + void (*dpms)(struct drm_encoder *encoder, int mode); +@@ -95,7 +95,7 @@ struct drm_encoder_helper_funcs { + struct drm_connector *connector); + /* disable encoder when not in use - more explicit than dpms off */ + void (*disable)(struct drm_encoder *encoder); +-}; ++} __no_const; +=20 + struct drm_connector_helper_funcs { + int (*get_modes)(struct drm_connector *connector); +diff --git a/include/drm/drm_mode.h b/include/drm/drm_mode.h +index c4961ea..53dfa109 100644 +--- a/include/drm/drm_mode.h ++++ b/include/drm/drm_mode.h +@@ -233,6 +233,8 @@ struct drm_mode_fb_cmd { + #define DRM_MODE_FB_DIRTY_ANNOTATE_FILL 0x02 + #define DRM_MODE_FB_DIRTY_FLAGS 0x03 +=20 ++#define DRM_MODE_FB_DIRTY_MAX_CLIPS 256 ++ + /* + * Mark a region of a framebuffer as dirty. + * +diff --git a/include/drm/ttm/ttm_memory.h b/include/drm/ttm/ttm_memory.h +index 26c1f78..6722682 100644 +--- a/include/drm/ttm/ttm_memory.h ++++ b/include/drm/ttm/ttm_memory.h @@ -47,7 +47,7 @@ =20 struct ttm_mem_shrink { @@ -58413,9 +59872,10 @@ diff -urNp linux-3.1.4/include/drm/ttm/ttm_memor= y.h linux-3.1.4/include/drm/ttm/ =20 /** * struct ttm_mem_global - Global memory accounting structure. -diff -urNp linux-3.1.4/include/linux/a.out.h linux-3.1.4/include/linux/a= .out.h ---- linux-3.1.4/include/linux/a.out.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/a.out.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/linux/a.out.h b/include/linux/a.out.h +index e86dfca..40cc55f 100644 +--- a/include/linux/a.out.h ++++ b/include/linux/a.out.h @@ -39,6 +39,14 @@ enum machine_type { M_MIPS2 =3D 152 /* MIPS R6000/R4000 binary */ }; @@ -58431,9 +59891,10 @@ diff -urNp linux-3.1.4/include/linux/a.out.h lin= ux-3.1.4/include/linux/a.out.h #if !defined (N_MAGIC) #define N_MAGIC(exec) ((exec).a_info & 0xffff) #endif -diff -urNp linux-3.1.4/include/linux/atmdev.h linux-3.1.4/include/linux/= atmdev.h ---- linux-3.1.4/include/linux/atmdev.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/atmdev.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/atmdev.h b/include/linux/atmdev.h +index 49a83ca..df96b54 100644 +--- a/include/linux/atmdev.h ++++ b/include/linux/atmdev.h @@ -237,7 +237,7 @@ struct compat_atm_iobuf { #endif =20 @@ -58443,9 +59904,10 @@ diff -urNp linux-3.1.4/include/linux/atmdev.h li= nux-3.1.4/include/linux/atmdev.h __AAL_STAT_ITEMS #undef __HANDLE_ITEM }; -diff -urNp linux-3.1.4/include/linux/binfmts.h linux-3.1.4/include/linux= /binfmts.h ---- linux-3.1.4/include/linux/binfmts.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/linux/binfmts.h 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/include/linux/binfmts.h b/include/linux/binfmts.h +index fd88a39..f4d0bad 100644 +--- a/include/linux/binfmts.h ++++ b/include/linux/binfmts.h @@ -88,6 +88,7 @@ struct linux_binfmt { int (*load_binary)(struct linux_binprm *, struct pt_regs * regs); int (*load_shlib)(struct file *); @@ -58454,9 +59916,10 @@ diff -urNp linux-3.1.4/include/linux/binfmts.h l= inux-3.1.4/include/linux/binfmts unsigned long min_coredump; /* minimal dump size */ }; =20 -diff -urNp linux-3.1.4/include/linux/blkdev.h linux-3.1.4/include/linux/= blkdev.h ---- linux-3.1.4/include/linux/blkdev.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/blkdev.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h +index 7fbaa91..5e6a460 100644 +--- a/include/linux/blkdev.h ++++ b/include/linux/blkdev.h @@ -1321,7 +1321,7 @@ struct block_device_operations { /* this callback is with swap_lock and sometimes page table lock held = */ void (*swap_slot_free_notify) (struct block_device *, unsigned long); @@ -58466,9 +59929,10 @@ diff -urNp linux-3.1.4/include/linux/blkdev.h li= nux-3.1.4/include/linux/blkdev.h =20 extern int __blkdev_driver_ioctl(struct block_device *, fmode_t, unsign= ed int, unsigned long); -diff -urNp linux-3.1.4/include/linux/blktrace_api.h linux-3.1.4/include/= linux/blktrace_api.h ---- linux-3.1.4/include/linux/blktrace_api.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/include/linux/blktrace_api.h 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/include/linux/blktrace_api.h b/include/linux/blktrace_api.h +index 8e9e4bc..88bd457 100644 +--- a/include/linux/blktrace_api.h ++++ b/include/linux/blktrace_api.h @@ -162,7 +162,7 @@ struct blk_trace { struct dentry *dir; struct dentry *dropped_file; @@ -58478,9 +59942,10 @@ diff -urNp linux-3.1.4/include/linux/blktrace_ap= i.h linux-3.1.4/include/linux/bl }; =20 extern int blk_trace_ioctl(struct block_device *, unsigned, char __user= *); -diff -urNp linux-3.1.4/include/linux/byteorder/little_endian.h linux-3.1= .4/include/linux/byteorder/little_endian.h ---- linux-3.1.4/include/linux/byteorder/little_endian.h 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/include/linux/byteorder/little_endian.h 2011-11-16 18:39= :08.000000000 -0500 +diff --git a/include/linux/byteorder/little_endian.h b/include/linux/byt= eorder/little_endian.h +index 83195fb..0b0f77d 100644 +--- a/include/linux/byteorder/little_endian.h ++++ b/include/linux/byteorder/little_endian.h @@ -42,51 +42,51 @@ =20 static inline __le64 __cpu_to_le64p(const __u64 *p) @@ -58545,9 +60010,10 @@ diff -urNp linux-3.1.4/include/linux/byteorder/l= ittle_endian.h linux-3.1.4/inclu } #define __cpu_to_le64s(x) do { (void)(x); } while (0) #define __le64_to_cpus(x) do { (void)(x); } while (0) -diff -urNp linux-3.1.4/include/linux/cache.h linux-3.1.4/include/linux/c= ache.h ---- linux-3.1.4/include/linux/cache.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/cache.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/linux/cache.h b/include/linux/cache.h +index 4c57065..4307975 100644 +--- a/include/linux/cache.h ++++ b/include/linux/cache.h @@ -16,6 +16,10 @@ #define __read_mostly #endif @@ -58559,9 +60025,10 @@ diff -urNp linux-3.1.4/include/linux/cache.h lin= ux-3.1.4/include/linux/cache.h #ifndef ____cacheline_aligned #define ____cacheline_aligned __attribute__((__aligned__(SMP_CACHE_BYTE= S))) #endif -diff -urNp linux-3.1.4/include/linux/capability.h linux-3.1.4/include/li= nux/capability.h ---- linux-3.1.4/include/linux/capability.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/linux/capability.h 2011-11-16 18:40:31.000000000= -0500 +diff --git a/include/linux/capability.h b/include/linux/capability.h +index c421123..e343179 100644 +--- a/include/linux/capability.h ++++ b/include/linux/capability.h @@ -547,6 +547,9 @@ extern bool capable(int cap); extern bool ns_capable(struct user_namespace *ns, int cap); extern bool task_ns_capable(struct task_struct *t, int cap); @@ -58572,9 +60039,10 @@ diff -urNp linux-3.1.4/include/linux/capability.= h linux-3.1.4/include/linux/capa =20 /* audit system wants to get cap info from files as well */ extern int get_vfs_caps_from_disk(const struct dentry *dentry, struct c= pu_vfs_cap_data *cpu_caps); -diff -urNp linux-3.1.4/include/linux/cleancache.h linux-3.1.4/include/li= nux/cleancache.h ---- linux-3.1.4/include/linux/cleancache.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/linux/cleancache.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/include/linux/cleancache.h b/include/linux/cleancache.h +index 04ffb2e..6799180 100644 +--- a/include/linux/cleancache.h ++++ b/include/linux/cleancache.h @@ -31,7 +31,7 @@ struct cleancache_ops { void (*flush_page)(int, struct cleancache_filekey, pgoff_t); void (*flush_inode)(int, struct cleancache_filekey); @@ -58584,9 +60052,10 @@ diff -urNp linux-3.1.4/include/linux/cleancache.= h linux-3.1.4/include/linux/clea =20 extern struct cleancache_ops cleancache_register_ops(struct cleancache_ops *ops); -diff -urNp linux-3.1.4/include/linux/compiler-gcc4.h linux-3.1.4/include= /linux/compiler-gcc4.h ---- linux-3.1.4/include/linux/compiler-gcc4.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/include/linux/compiler-gcc4.h 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/include/linux/compiler-gcc4.h b/include/linux/compiler-gcc4= .h +index dfadc96..c0e70c1 100644 +--- a/include/linux/compiler-gcc4.h ++++ b/include/linux/compiler-gcc4.h @@ -31,6 +31,12 @@ =20 =20 @@ -58612,9 +60081,10 @@ diff -urNp linux-3.1.4/include/linux/compiler-gc= c4.h linux-3.1.4/include/linux/c #endif =20 #if __GNUC_MINOR__ > 0 -diff -urNp linux-3.1.4/include/linux/compiler.h linux-3.1.4/include/linu= x/compiler.h ---- linux-3.1.4/include/linux/compiler.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/compiler.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/include/linux/compiler.h b/include/linux/compiler.h +index 320d6c9..8573a1c 100644 +--- a/include/linux/compiler.h ++++ b/include/linux/compiler.h @@ -5,31 +5,62 @@ =20 #ifdef __CHECKER__ @@ -58678,7 +60148,7 @@ diff -urNp linux-3.1.4/include/linux/compiler.h l= inux-3.1.4/include/linux/compil # define __chk_user_ptr(x) (void)0 # define __chk_io_ptr(x) (void)0 # define __builtin_warning(x, y...) (1) -@@ -39,7 +70,9 @@ extern void __chk_io_ptr(const volatile=20 +@@ -39,7 +70,9 @@ extern void __chk_io_ptr(const volatile void __iomem *= ); # define __release(x) (void)0 # define __cond_lock(x,c) (c) # define __percpu @@ -58688,7 +60158,7 @@ diff -urNp linux-3.1.4/include/linux/compiler.h l= inux-3.1.4/include/linux/compil #endif =20 #ifdef __KERNEL__ -@@ -264,6 +297,14 @@ void ftrace_likely_update(struct ftrace_ +@@ -264,6 +297,14 @@ void ftrace_likely_update(struct ftrace_branch_data= *f, int val, int expect); # define __attribute_const__ /* unimplemented */ #endif =20 @@ -58703,7 +60173,7 @@ diff -urNp linux-3.1.4/include/linux/compiler.h l= inux-3.1.4/include/linux/compil /* * Tell gcc if a function is cold. The compiler will assume any path * directly leading to the call is unlikely. -@@ -273,6 +314,22 @@ void ftrace_likely_update(struct ftrace_ +@@ -273,6 +314,22 @@ void ftrace_likely_update(struct ftrace_branch_data= *f, int val, int expect); #define __cold #endif =20 @@ -58726,7 +60196,7 @@ diff -urNp linux-3.1.4/include/linux/compiler.h l= inux-3.1.4/include/linux/compil /* Simple shorthand for a section definition */ #ifndef __section # define __section(S) __attribute__ ((__section__(#S))) -@@ -306,6 +363,7 @@ void ftrace_likely_update(struct ftrace_ +@@ -306,6 +363,7 @@ void ftrace_likely_update(struct ftrace_branch_data = *f, int val, int expect); * use is to mediate communication between process-level code and irq/N= MI * handlers, all running on the same CPU. */ @@ -58735,10 +60205,11 @@ diff -urNp linux-3.1.4/include/linux/compiler.h= linux-3.1.4/include/linux/compil +#define ACCESS_ONCE_RW(x) (*(volatile typeof(x) *)&(x)) =20 #endif /* __LINUX_COMPILER_H */ -diff -urNp linux-3.1.4/include/linux/cpuset.h linux-3.1.4/include/linux/= cpuset.h ---- linux-3.1.4/include/linux/cpuset.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/cpuset.h 2011-11-16 18:39:08.000000000 -05= 00 -@@ -118,7 +118,7 @@ static inline void put_mems_allowed(void +diff --git a/include/linux/cpuset.h b/include/linux/cpuset.h +index e9eaec5..bfeb9bb 100644 +--- a/include/linux/cpuset.h ++++ b/include/linux/cpuset.h +@@ -118,7 +118,7 @@ static inline void put_mems_allowed(void) * nodemask. */ smp_mb(); @@ -58747,9 +60218,10 @@ diff -urNp linux-3.1.4/include/linux/cpuset.h li= nux-3.1.4/include/linux/cpuset.h } =20 static inline void set_mems_allowed(nodemask_t nodemask) -diff -urNp linux-3.1.4/include/linux/crypto.h linux-3.1.4/include/linux/= crypto.h ---- linux-3.1.4/include/linux/crypto.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/crypto.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/crypto.h b/include/linux/crypto.h +index e5e468e..f079672 100644 +--- a/include/linux/crypto.h ++++ b/include/linux/crypto.h @@ -361,7 +361,7 @@ struct cipher_tfm { const u8 *key, unsigned int keylen); void (*cit_encrypt_one)(struct crypto_tfm *tfm, u8 *dst, const u8 *src= ); @@ -58775,9 +60247,10 @@ diff -urNp linux-3.1.4/include/linux/crypto.h li= nux-3.1.4/include/linux/crypto.h =20 #define crt_ablkcipher crt_u.ablkcipher #define crt_aead crt_u.aead -diff -urNp linux-3.1.4/include/linux/decompress/mm.h linux-3.1.4/include= /linux/decompress/mm.h ---- linux-3.1.4/include/linux/decompress/mm.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/include/linux/decompress/mm.h 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/include/linux/decompress/mm.h b/include/linux/decompress/mm= .h +index 7925bf0..d5143d2 100644 +--- a/include/linux/decompress/mm.h ++++ b/include/linux/decompress/mm.h @@ -77,7 +77,7 @@ static void free(void *where) * warnings when not needed (indeed large_malloc / large_free are not * needed by inflate */ @@ -58787,9 +60260,10 @@ diff -urNp linux-3.1.4/include/linux/decompress/= mm.h linux-3.1.4/include/linux/d #define free(a) kfree(a) =20 #define large_malloc(a) vmalloc(a) -diff -urNp linux-3.1.4/include/linux/dma-mapping.h linux-3.1.4/include/l= inux/dma-mapping.h ---- linux-3.1.4/include/linux/dma-mapping.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/linux/dma-mapping.h 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h +index 347fdc3..cd01657 100644 +--- a/include/linux/dma-mapping.h ++++ b/include/linux/dma-mapping.h @@ -42,7 +42,7 @@ struct dma_map_ops { int (*dma_supported)(struct device *dev, u64 mask); int (*set_dma_mask)(struct device *dev, u64 mask); @@ -58799,9 +60273,10 @@ diff -urNp linux-3.1.4/include/linux/dma-mapping= .h linux-3.1.4/include/linux/dma =20 #define DMA_BIT_MASK(n) (((n) =3D=3D 64) ? ~0ULL : ((1ULL<<(n))-1)) =20 -diff -urNp linux-3.1.4/include/linux/efi.h linux-3.1.4/include/linux/efi= .h ---- linux-3.1.4/include/linux/efi.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/efi.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/efi.h b/include/linux/efi.h +index 2362a0b..cfaf8fcc 100644 +--- a/include/linux/efi.h ++++ b/include/linux/efi.h @@ -446,7 +446,7 @@ struct efivar_operations { efi_get_variable_t *get_variable; efi_get_next_variable_t *get_next_variable; @@ -58811,9 +60286,10 @@ diff -urNp linux-3.1.4/include/linux/efi.h linux= -3.1.4/include/linux/efi.h =20 struct efivars { /* -diff -urNp linux-3.1.4/include/linux/elf.h linux-3.1.4/include/linux/elf= .h ---- linux-3.1.4/include/linux/elf.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/elf.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/elf.h b/include/linux/elf.h +index 110821c..cb14c08 100644 +--- a/include/linux/elf.h ++++ b/include/linux/elf.h @@ -49,6 +49,17 @@ typedef __s64 Elf64_Sxword; #define PT_GNU_EH_FRAME 0x6474e550 =20 @@ -58886,10 +60362,11 @@ diff -urNp linux-3.1.4/include/linux/elf.h linu= x-3.1.4/include/linux/elf.h =20 #endif =20 -diff -urNp linux-3.1.4/include/linux/filter.h linux-3.1.4/include/linux/= filter.h ---- linux-3.1.4/include/linux/filter.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/filter.h 2011-11-20 19:21:53.000000000 -05= 00 -@@ -134,6 +134,7 @@ struct sock_fprog { /* Required for SO_A +diff --git a/include/linux/filter.h b/include/linux/filter.h +index 741956f..f02f482 100644 +--- a/include/linux/filter.h ++++ b/include/linux/filter.h +@@ -134,6 +134,7 @@ struct sock_fprog { /* Required for SO_ATTACH_FILTER= . */ =20 struct sk_buff; struct sock; @@ -58907,9 +60384,10 @@ diff -urNp linux-3.1.4/include/linux/filter.h li= nux-3.1.4/include/linux/filter.h struct rcu_head rcu; struct sock_filter insns[0]; }; -diff -urNp linux-3.1.4/include/linux/firewire.h linux-3.1.4/include/linu= x/firewire.h ---- linux-3.1.4/include/linux/firewire.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/firewire.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/include/linux/firewire.h b/include/linux/firewire.h +index 84ccf8e..2e9b14c 100644 +--- a/include/linux/firewire.h ++++ b/include/linux/firewire.h @@ -428,7 +428,7 @@ struct fw_iso_context { union { fw_iso_callback_t sc; @@ -58919,9 +60397,37 @@ diff -urNp linux-3.1.4/include/linux/firewire.h = linux-3.1.4/include/linux/firewi void *callback_data; }; =20 -diff -urNp linux-3.1.4/include/linux/fscache-cache.h linux-3.1.4/include= /linux/fscache-cache.h ---- linux-3.1.4/include/linux/fscache-cache.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/include/linux/fscache-cache.h 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/include/linux/fs.h b/include/linux/fs.h +index 277f497..9be66a4 100644 +--- a/include/linux/fs.h ++++ b/include/linux/fs.h +@@ -1588,7 +1588,8 @@ struct file_operations { + int (*setlease)(struct file *, long, struct file_lock **); + long (*fallocate)(struct file *file, int mode, loff_t offset, + loff_t len); +-}; ++} __do_const; ++typedef struct file_operations __no_const file_operations_no_const; +=20 + struct inode_operations { + struct dentry * (*lookup) (struct inode *,struct dentry *, struct name= idata *); +diff --git a/include/linux/fs_struct.h b/include/linux/fs_struct.h +index 003dc0f..3c4ea97 100644 +--- a/include/linux/fs_struct.h ++++ b/include/linux/fs_struct.h +@@ -6,7 +6,7 @@ + #include +=20 + struct fs_struct { +- int users; ++ atomic_t users; + spinlock_t lock; + seqcount_t seq; + int umask; +diff --git a/include/linux/fscache-cache.h b/include/linux/fscache-cache= .h +index af095b5..cf1220c 100644 +--- a/include/linux/fscache-cache.h ++++ b/include/linux/fscache-cache.h @@ -102,7 +102,7 @@ struct fscache_operation { fscache_operation_release_t release; }; @@ -58931,7 +60437,7 @@ diff -urNp linux-3.1.4/include/linux/fscache-cach= e.h linux-3.1.4/include/linux/f extern void fscache_op_work_func(struct work_struct *work); =20 extern void fscache_enqueue_operation(struct fscache_operation *); -@@ -122,7 +122,7 @@ static inline void fscache_operation_ini +@@ -122,7 +122,7 @@ static inline void fscache_operation_init(struct fsc= ache_operation *op, { INIT_WORK(&op->work, fscache_op_work_func); atomic_set(&op->usage, 1); @@ -58940,23 +60446,11 @@ diff -urNp linux-3.1.4/include/linux/fscache-ca= che.h linux-3.1.4/include/linux/f op->processor =3D processor; op->release =3D release; INIT_LIST_HEAD(&op->pend_link); -diff -urNp linux-3.1.4/include/linux/fs.h linux-3.1.4/include/linux/fs.h ---- linux-3.1.4/include/linux/fs.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/fs.h 2011-11-16 23:39:39.000000000 -0500 -@@ -1588,7 +1588,8 @@ struct file_operations { - int (*setlease)(struct file *, long, struct file_lock **); - long (*fallocate)(struct file *file, int mode, loff_t offset, - loff_t len); --}; -+} __do_const; -+typedef struct file_operations __no_const file_operations_no_const; -=20 - struct inode_operations { - struct dentry * (*lookup) (struct inode *,struct dentry *, struct name= idata *); -diff -urNp linux-3.1.4/include/linux/fsnotify.h linux-3.1.4/include/linu= x/fsnotify.h ---- linux-3.1.4/include/linux/fsnotify.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/fsnotify.h 2011-11-16 18:39:08.000000000 -= 0500 -@@ -314,7 +314,7 @@ static inline void fsnotify_change(struc +diff --git a/include/linux/fsnotify.h b/include/linux/fsnotify.h +index 2a53f10..0187fdf 100644 +--- a/include/linux/fsnotify.h ++++ b/include/linux/fsnotify.h +@@ -314,7 +314,7 @@ static inline void fsnotify_change(struct dentry *de= ntry, unsigned int ia_valid) */ static inline const unsigned char *fsnotify_oldname_init(const unsigned= char *name) { @@ -58965,21 +60459,10 @@ diff -urNp linux-3.1.4/include/linux/fsnotify.h= linux-3.1.4/include/linux/fsnoti } =20 /* -diff -urNp linux-3.1.4/include/linux/fs_struct.h linux-3.1.4/include/lin= ux/fs_struct.h ---- linux-3.1.4/include/linux/fs_struct.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/include/linux/fs_struct.h 2011-11-16 18:39:08.000000000 = -0500 -@@ -6,7 +6,7 @@ - #include -=20 - struct fs_struct { -- int users; -+ atomic_t users; - spinlock_t lock; - seqcount_t seq; - int umask; -diff -urNp linux-3.1.4/include/linux/ftrace_event.h linux-3.1.4/include/= linux/ftrace_event.h ---- linux-3.1.4/include/linux/ftrace_event.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/include/linux/ftrace_event.h 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/include/linux/ftrace_event.h b/include/linux/ftrace_event.h +index 96efa67..1261547 100644 +--- a/include/linux/ftrace_event.h ++++ b/include/linux/ftrace_event.h @@ -97,7 +97,7 @@ struct trace_event_functions { trace_print_func raw; trace_print_func hex; @@ -58989,7 +60472,7 @@ diff -urNp linux-3.1.4/include/linux/ftrace_event= .h linux-3.1.4/include/linux/ft =20 struct trace_event { struct hlist_node node; -@@ -252,7 +252,7 @@ extern int trace_define_field(struct ftr +@@ -252,7 +252,7 @@ extern int trace_define_field(struct ftrace_event_ca= ll *call, const char *type, extern int trace_add_event_call(struct ftrace_event_call *call); extern void trace_remove_event_call(struct ftrace_event_call *call); =20 @@ -58998,9 +60481,10 @@ diff -urNp linux-3.1.4/include/linux/ftrace_even= t.h linux-3.1.4/include/linux/ft =20 int trace_set_clr_event(const char *system, const char *event, int set)= ; =20 -diff -urNp linux-3.1.4/include/linux/genhd.h linux-3.1.4/include/linux/g= enhd.h ---- linux-3.1.4/include/linux/genhd.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/genhd.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/linux/genhd.h b/include/linux/genhd.h +index 02fa469..a15f279 100644 +--- a/include/linux/genhd.h ++++ b/include/linux/genhd.h @@ -184,7 +184,7 @@ struct gendisk { struct kobject *slave_dir; =20 @@ -59010,9 +60494,11 @@ diff -urNp linux-3.1.4/include/linux/genhd.h lin= ux-3.1.4/include/linux/genhd.h struct disk_events *ev; #ifdef CONFIG_BLK_DEV_INTEGRITY struct blk_integrity *integrity; -diff -urNp linux-3.1.4/include/linux/gracl.h linux-3.1.4/include/linux/g= racl.h ---- linux-3.1.4/include/linux/gracl.h 1969-12-31 19:00:00.000000000 -050= 0 -+++ linux-3.1.4/include/linux/gracl.h 2011-11-16 18:40:31.000000000 -050= 0 +diff --git a/include/linux/gracl.h b/include/linux/gracl.h +new file mode 100644 +index 0000000..0dc3943 +--- /dev/null ++++ b/include/linux/gracl.h @@ -0,0 +1,317 @@ +#ifndef GR_ACL_H +#define GR_ACL_H @@ -59331,9 +60817,11 @@ diff -urNp linux-3.1.4/include/linux/gracl.h lin= ux-3.1.4/include/linux/gracl.h + +#endif + -diff -urNp linux-3.1.4/include/linux/gralloc.h linux-3.1.4/include/linux= /gralloc.h ---- linux-3.1.4/include/linux/gralloc.h 1969-12-31 19:00:00.000000000 -0= 500 -+++ linux-3.1.4/include/linux/gralloc.h 2011-11-16 18:40:31.000000000 -0= 500 +diff --git a/include/linux/gralloc.h b/include/linux/gralloc.h +new file mode 100644 +index 0000000..323ecf2 +--- /dev/null ++++ b/include/linux/gralloc.h @@ -0,0 +1,9 @@ +#ifndef __GRALLOC_H +#define __GRALLOC_H @@ -59344,9 +60832,11 @@ diff -urNp linux-3.1.4/include/linux/gralloc.h l= inux-3.1.4/include/linux/gralloc +void *acl_alloc_num(unsigned long num, unsigned long len); + +#endif -diff -urNp linux-3.1.4/include/linux/grdefs.h linux-3.1.4/include/linux/= grdefs.h ---- linux-3.1.4/include/linux/grdefs.h 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/include/linux/grdefs.h 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/include/linux/grdefs.h b/include/linux/grdefs.h +new file mode 100644 +index 0000000..b30e9bc +--- /dev/null ++++ b/include/linux/grdefs.h @@ -0,0 +1,140 @@ +#ifndef GRDEFS_H +#define GRDEFS_H @@ -59488,9 +60978,11 @@ diff -urNp linux-3.1.4/include/linux/grdefs.h li= nux-3.1.4/include/linux/grdefs.h +}; + +#endif -diff -urNp linux-3.1.4/include/linux/grinternal.h linux-3.1.4/include/li= nux/grinternal.h ---- linux-3.1.4/include/linux/grinternal.h 1969-12-31 19:00:00.000000000= -0500 -+++ linux-3.1.4/include/linux/grinternal.h 2011-11-16 18:40:31.000000000= -0500 +diff --git a/include/linux/grinternal.h b/include/linux/grinternal.h +new file mode 100644 +index 0000000..60cda84 +--- /dev/null ++++ b/include/linux/grinternal.h @@ -0,0 +1,220 @@ +#ifndef __GRINTERNAL_H +#define __GRINTERNAL_H @@ -59712,9 +61204,11 @@ diff -urNp linux-3.1.4/include/linux/grinternal.= h linux-3.1.4/include/linux/grin +#endif + +#endif -diff -urNp linux-3.1.4/include/linux/grmsg.h linux-3.1.4/include/linux/g= rmsg.h ---- linux-3.1.4/include/linux/grmsg.h 1969-12-31 19:00:00.000000000 -050= 0 -+++ linux-3.1.4/include/linux/grmsg.h 2011-11-16 18:40:31.000000000 -050= 0 +diff --git a/include/linux/grmsg.h b/include/linux/grmsg.h +new file mode 100644 +index 0000000..9d5fd4a +--- /dev/null ++++ b/include/linux/grmsg.h @@ -0,0 +1,108 @@ +#define DEFAULTSECMSG "%.256s[%.16s:%d] uid/euid:%u/%u gid/egid:%u/%u, = parent %.256s[%.16s:%d] uid/euid:%u/%u gid/egid:%u/%u" +#define GR_ACL_PROCACCT_MSG "%.256s[%.16s:%d] IP:%pI4 TTY:%.64s uid/eui= d:%u/%u gid/egid:%u/%u run time:[%ud %uh %um %us] cpu time:[%ud %uh %um %= us] %s with exit code %ld, parent %.256s[%.16s:%d] IP:%pI4 TTY:%.64s uid/= euid:%u/%u gid/egid:%u/%u" @@ -59824,9 +61318,11 @@ diff -urNp linux-3.1.4/include/linux/grmsg.h lin= ux-3.1.4/include/linux/grmsg.h +#define GR_VM86_MSG "denied use of vm86 by " +#define GR_PTRACE_AUDIT_MSG "process %.950s(%.16s:%d) attached to via p= trace by " +#define GR_INIT_TRANSFER_MSG "persistent special role transferred privi= lege to init by " -diff -urNp linux-3.1.4/include/linux/grsecurity.h linux-3.1.4/include/li= nux/grsecurity.h ---- linux-3.1.4/include/linux/grsecurity.h 1969-12-31 19:00:00.000000000= -0500 -+++ linux-3.1.4/include/linux/grsecurity.h 2011-11-17 00:16:10.000000000= -0500 +diff --git a/include/linux/grsecurity.h b/include/linux/grsecurity.h +new file mode 100644 +index 0000000..bd25f72 +--- /dev/null ++++ b/include/linux/grsecurity.h @@ -0,0 +1,228 @@ +#ifndef GR_SECURITY_H +#define GR_SECURITY_H @@ -60056,9 +61552,11 @@ diff -urNp linux-3.1.4/include/linux/grsecurity.= h linux-3.1.4/include/linux/grse +#endif + +#endif -diff -urNp linux-3.1.4/include/linux/grsock.h linux-3.1.4/include/linux/= grsock.h ---- linux-3.1.4/include/linux/grsock.h 1969-12-31 19:00:00.000000000 -05= 00 -+++ linux-3.1.4/include/linux/grsock.h 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/include/linux/grsock.h b/include/linux/grsock.h +new file mode 100644 +index 0000000..e7ffaaf +--- /dev/null ++++ b/include/linux/grsock.h @@ -0,0 +1,19 @@ +#ifndef __GRSOCK_H +#define __GRSOCK_H @@ -60079,9 +61577,10 @@ diff -urNp linux-3.1.4/include/linux/grsock.h li= nux-3.1.4/include/linux/grsock.h + const int protocol); + +#endif -diff -urNp linux-3.1.4/include/linux/hid.h linux-3.1.4/include/linux/hid= .h ---- linux-3.1.4/include/linux/hid.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/hid.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/hid.h b/include/linux/hid.h +index 9cf8e7a..5ec94d0 100644 +--- a/include/linux/hid.h ++++ b/include/linux/hid.h @@ -676,7 +676,7 @@ struct hid_ll_driver { unsigned int code, int value); =20 @@ -60091,10 +61590,11 @@ diff -urNp linux-3.1.4/include/linux/hid.h linu= x-3.1.4/include/linux/hid.h =20 #define PM_HINT_FULLON 1<<5 #define PM_HINT_NORMAL 1<<1 -diff -urNp linux-3.1.4/include/linux/highmem.h linux-3.1.4/include/linux= /highmem.h ---- linux-3.1.4/include/linux/highmem.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/linux/highmem.h 2011-11-16 18:39:08.000000000 -0= 500 -@@ -185,6 +185,18 @@ static inline void clear_highpage(struct +diff --git a/include/linux/highmem.h b/include/linux/highmem.h +index 3a93f73..b19d0b3 100644 +--- a/include/linux/highmem.h ++++ b/include/linux/highmem.h +@@ -185,6 +185,18 @@ static inline void clear_highpage(struct page *page= ) kunmap_atomic(kaddr, KM_USER0); } =20 @@ -60113,9 +61613,10 @@ diff -urNp linux-3.1.4/include/linux/highmem.h l= inux-3.1.4/include/linux/highmem static inline void zero_user_segments(struct page *page, unsigned start1, unsigned end1, unsigned start2, unsigned end2) -diff -urNp linux-3.1.4/include/linux/i2c.h linux-3.1.4/include/linux/i2c= .h ---- linux-3.1.4/include/linux/i2c.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/i2c.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/i2c.h b/include/linux/i2c.h +index a6c652e..1f5878f 100644 +--- a/include/linux/i2c.h ++++ b/include/linux/i2c.h @@ -346,6 +346,7 @@ struct i2c_algorithm { /* To determine what the adapter supports */ u32 (*functionality) (struct i2c_adapter *); @@ -60124,9 +61625,10 @@ diff -urNp linux-3.1.4/include/linux/i2c.h linux= -3.1.4/include/linux/i2c.h =20 /* * i2c_adapter is the structure used to identify a physical i2c bus alo= ng -diff -urNp linux-3.1.4/include/linux/i2o.h linux-3.1.4/include/linux/i2o= .h ---- linux-3.1.4/include/linux/i2o.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/i2o.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/i2o.h b/include/linux/i2o.h +index a6deef4..c56a7f2 100644 +--- a/include/linux/i2o.h ++++ b/include/linux/i2o.h @@ -564,7 +564,7 @@ struct i2o_controller { struct i2o_device *exec; /* Executive */ #if BITS_PER_LONG =3D=3D 64 @@ -60136,10 +61638,11 @@ diff -urNp linux-3.1.4/include/linux/i2o.h linu= x-3.1.4/include/linux/i2o.h struct list_head context_list; /* list of context id's and pointers */ #endif -diff -urNp linux-3.1.4/include/linux/init.h linux-3.1.4/include/linux/in= it.h ---- linux-3.1.4/include/linux/init.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/init.h 2011-11-16 18:39:08.000000000 -0500 -@@ -293,13 +293,13 @@ void __init parse_early_options(char *cm +diff --git a/include/linux/init.h b/include/linux/init.h +index 9146f39..885354d 100644 +--- a/include/linux/init.h ++++ b/include/linux/init.h +@@ -293,13 +293,13 @@ void __init parse_early_options(char *cmdline); =20 /* Each module must use one module_init(). */ #define module_init(initfn) \ @@ -60155,9 +61658,10 @@ diff -urNp linux-3.1.4/include/linux/init.h linu= x-3.1.4/include/linux/init.h { return exitfn; } \ void cleanup_module(void) __attribute__((alias(#exitfn))); =20 -diff -urNp linux-3.1.4/include/linux/init_task.h linux-3.1.4/include/lin= ux/init_task.h ---- linux-3.1.4/include/linux/init_task.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/include/linux/init_task.h 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/include/linux/init_task.h b/include/linux/init_task.h +index d14e058..4162929 100644 +--- a/include/linux/init_task.h ++++ b/include/linux/init_task.h @@ -126,6 +126,12 @@ extern struct cred init_cred; # define INIT_PERF_EVENTS(tsk) #endif @@ -60179,9 +61683,10 @@ diff -urNp linux-3.1.4/include/linux/init_task.h= linux-3.1.4/include/linux/init_ .fs =3D &init_fs, \ .files =3D &init_files, \ .signal =3D &init_signals, \ -diff -urNp linux-3.1.4/include/linux/intel-iommu.h linux-3.1.4/include/l= inux/intel-iommu.h ---- linux-3.1.4/include/linux/intel-iommu.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/linux/intel-iommu.h 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/include/linux/intel-iommu.h b/include/linux/intel-iommu.h +index 9310c69..6ebb244 100644 +--- a/include/linux/intel-iommu.h ++++ b/include/linux/intel-iommu.h @@ -296,7 +296,7 @@ struct iommu_flush { u8 fm, u64 type); void (*flush_iotlb)(struct intel_iommu *iommu, u16 did, u64 addr, @@ -60191,9 +61696,10 @@ diff -urNp linux-3.1.4/include/linux/intel-iommu= .h linux-3.1.4/include/linux/int =20 enum { SR_DMAR_FECTL_REG, -diff -urNp linux-3.1.4/include/linux/interrupt.h linux-3.1.4/include/lin= ux/interrupt.h ---- linux-3.1.4/include/linux/interrupt.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/include/linux/interrupt.h 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h +index f51a81b..adfcb44 100644 +--- a/include/linux/interrupt.h ++++ b/include/linux/interrupt.h @@ -425,7 +425,7 @@ enum /* map softirq index to softirq name. update 'softirq_to_name' in * kernel/softirq.c when adding a new softirq. @@ -60203,7 +61709,7 @@ diff -urNp linux-3.1.4/include/linux/interrupt.h = linux-3.1.4/include/linux/inter =20 /* softirq mask and active fields moved to irq_cpustat_t in * asm/hardirq.h to get better cache usage. KAO -@@ -433,12 +433,12 @@ extern char *softirq_to_name[NR_SOFTIRQS +@@ -433,12 +433,12 @@ extern char *softirq_to_name[NR_SOFTIRQS]; =20 struct softirq_action { @@ -60218,9 +61724,10 @@ diff -urNp linux-3.1.4/include/linux/interrupt.h= linux-3.1.4/include/linux/inter extern void softirq_init(void); static inline void __raise_softirq_irqoff(unsigned int nr) { -diff -urNp linux-3.1.4/include/linux/kallsyms.h linux-3.1.4/include/linu= x/kallsyms.h ---- linux-3.1.4/include/linux/kallsyms.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/kallsyms.h 2011-11-16 18:40:31.000000000 -= 0500 +diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h +index 0df513b..fe901a2 100644 +--- a/include/linux/kallsyms.h ++++ b/include/linux/kallsyms.h @@ -15,7 +15,8 @@ =20 struct module; @@ -60231,7 +61738,7 @@ diff -urNp linux-3.1.4/include/linux/kallsyms.h l= inux-3.1.4/include/linux/kallsy /* Lookup the address for a symbol. Returns 0 if not found. */ unsigned long kallsyms_lookup_name(const char *name); =20 -@@ -99,6 +100,16 @@ static inline int lookup_symbol_attrs(un +@@ -99,6 +100,16 @@ static inline int lookup_symbol_attrs(unsigned long = addr, unsigned long *size, u /* Stupid that this does nothing, but I didn't create this mess. */ #define __print_symbol(fmt, addr) #endif /*CONFIG_KALLSYMS*/ @@ -60248,9 +61755,10 @@ diff -urNp linux-3.1.4/include/linux/kallsyms.h = linux-3.1.4/include/linux/kallsy =20 /* This macro allows us to keep printk typechecking */ static void __check_printsym_format(const char *fmt, ...) -diff -urNp linux-3.1.4/include/linux/kgdb.h linux-3.1.4/include/linux/kg= db.h ---- linux-3.1.4/include/linux/kgdb.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/kgdb.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/kgdb.h b/include/linux/kgdb.h +index fa39183..40160be 100644 +--- a/include/linux/kgdb.h ++++ b/include/linux/kgdb.h @@ -53,7 +53,7 @@ extern int kgdb_connected; extern int kgdb_io_module_registered; =20 @@ -60278,10 +61786,11 @@ diff -urNp linux-3.1.4/include/linux/kgdb.h lin= ux-3.1.4/include/linux/kgdb.h =20 extern struct kgdb_arch arch_kgdb_ops; =20 -diff -urNp linux-3.1.4/include/linux/kmod.h linux-3.1.4/include/linux/km= od.h ---- linux-3.1.4/include/linux/kmod.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/kmod.h 2011-11-16 18:40:31.000000000 -0500 -@@ -34,6 +34,8 @@ extern char modprobe_path[]; /* for sysc +diff --git a/include/linux/kmod.h b/include/linux/kmod.h +index 0da38cf..d23f05f 100644 +--- a/include/linux/kmod.h ++++ b/include/linux/kmod.h +@@ -34,6 +34,8 @@ extern char modprobe_path[]; /* for sysctl */ * usually useless though. */ extern int __request_module(bool wait, const char *name, ...) \ __attribute__((format(printf, 2, 3))); @@ -60290,10 +61799,11 @@ diff -urNp linux-3.1.4/include/linux/kmod.h lin= ux-3.1.4/include/linux/kmod.h #define request_module(mod...) __request_module(true, mod) #define request_module_nowait(mod...) __request_module(false, mod) #define try_then_request_module(x, mod...) \ -diff -urNp linux-3.1.4/include/linux/kvm_host.h linux-3.1.4/include/linu= x/kvm_host.h ---- linux-3.1.4/include/linux/kvm_host.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/kvm_host.h 2011-11-16 18:39:08.000000000 -= 0500 -@@ -308,7 +308,7 @@ void kvm_vcpu_uninit(struct kvm_vcpu *vc +diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h +index eabb21a..3f030f4 100644 +--- a/include/linux/kvm_host.h ++++ b/include/linux/kvm_host.h +@@ -308,7 +308,7 @@ void kvm_vcpu_uninit(struct kvm_vcpu *vcpu); void vcpu_load(struct kvm_vcpu *vcpu); void vcpu_put(struct kvm_vcpu *vcpu); =20 @@ -60302,7 +61812,7 @@ diff -urNp linux-3.1.4/include/linux/kvm_host.h l= inux-3.1.4/include/linux/kvm_ho struct module *module); void kvm_exit(void); =20 -@@ -454,7 +454,7 @@ int kvm_arch_vcpu_ioctl_set_guest_debug( +@@ -454,7 +454,7 @@ int kvm_arch_vcpu_ioctl_set_guest_debug(struct kvm_v= cpu *vcpu, struct kvm_guest_debug *dbg); int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu, struct kvm_run *kvm_= run); =20 @@ -60311,9 +61821,10 @@ diff -urNp linux-3.1.4/include/linux/kvm_host.h = linux-3.1.4/include/linux/kvm_ho void kvm_arch_exit(void); =20 int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu); -diff -urNp linux-3.1.4/include/linux/libata.h linux-3.1.4/include/linux/= libata.h ---- linux-3.1.4/include/linux/libata.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/libata.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/libata.h b/include/linux/libata.h +index efd6f98..5f5fd37 100644 +--- a/include/linux/libata.h ++++ b/include/linux/libata.h @@ -909,7 +909,7 @@ struct ata_port_operations { * fields must be pointers. */ @@ -60323,9 +61834,10 @@ diff -urNp linux-3.1.4/include/linux/libata.h li= nux-3.1.4/include/linux/libata.h =20 struct ata_port_info { unsigned long flags; -diff -urNp linux-3.1.4/include/linux/mca.h linux-3.1.4/include/linux/mca= .h ---- linux-3.1.4/include/linux/mca.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/mca.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/mca.h b/include/linux/mca.h +index 3797270..7765ede 100644 +--- a/include/linux/mca.h ++++ b/include/linux/mca.h @@ -80,7 +80,7 @@ struct mca_bus_accessor_functions { int region); void * (*mca_transform_memory)(struct mca_device *, @@ -60335,9 +61847,10 @@ diff -urNp linux-3.1.4/include/linux/mca.h linux= -3.1.4/include/linux/mca.h =20 struct mca_bus { u64 default_dma_mask; -diff -urNp linux-3.1.4/include/linux/memory.h linux-3.1.4/include/linux/= memory.h ---- linux-3.1.4/include/linux/memory.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/memory.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/memory.h b/include/linux/memory.h +index 935699b..11042cc 100644 +--- a/include/linux/memory.h ++++ b/include/linux/memory.h @@ -144,7 +144,7 @@ struct memory_accessor { size_t count); ssize_t (*write)(struct memory_accessor *, const char *buf, @@ -60347,9 +61860,10 @@ diff -urNp linux-3.1.4/include/linux/memory.h li= nux-3.1.4/include/linux/memory.h =20 /* * Kernel text modification mutex, used for code patching. Users of thi= s lock -diff -urNp linux-3.1.4/include/linux/mfd/abx500.h linux-3.1.4/include/li= nux/mfd/abx500.h ---- linux-3.1.4/include/linux/mfd/abx500.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/linux/mfd/abx500.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/include/linux/mfd/abx500.h b/include/linux/mfd/abx500.h +index 896b5e4..1159ad0 100644 +--- a/include/linux/mfd/abx500.h ++++ b/include/linux/mfd/abx500.h @@ -234,6 +234,7 @@ struct abx500_ops { int (*event_registers_startup_state_get) (struct device *, u8 *); int (*startup_irq_enabled) (struct device *, unsigned int); @@ -60358,10 +61872,11 @@ diff -urNp linux-3.1.4/include/linux/mfd/abx500= .h linux-3.1.4/include/linux/mfd/ =20 int abx500_register_ops(struct device *core_dev, struct abx500_ops *ops= ); void abx500_remove_ops(struct device *dev); -diff -urNp linux-3.1.4/include/linux/mm.h linux-3.1.4/include/linux/mm.h ---- linux-3.1.4/include/linux/mm.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/mm.h 2011-11-16 18:39:08.000000000 -0500 -@@ -114,7 +114,14 @@ extern unsigned int kobjsize(const void=20 +diff --git a/include/linux/mm.h b/include/linux/mm.h +index fedc5f0..7cedb6d 100644 +--- a/include/linux/mm.h ++++ b/include/linux/mm.h +@@ -114,7 +114,14 @@ extern unsigned int kobjsize(const void *objp); =20 #define VM_CAN_NONLINEAR 0x08000000 /* Has ->fault & does nonlinear pag= es */ #define VM_MIXEDMAP 0x10000000 /* Can contain "struct page" and pure PF= N pages */ @@ -60411,7 +61926,7 @@ diff -urNp linux-3.1.4/include/linux/mm.h linux-3= .1.4/include/linux/mm.h extern unsigned long move_page_tables(struct vm_area_struct *vma, unsigned long old_addr, struct vm_area_struct *new_vma, unsigned long new_addr, unsigned long len); -@@ -1133,6 +1112,15 @@ static inline void sync_mm_rss(struct ta +@@ -1133,6 +1112,15 @@ static inline void sync_mm_rss(struct task_struct= *task, struct mm_struct *mm) } #endif =20 @@ -60435,7 +61950,7 @@ diff -urNp linux-3.1.4/include/linux/mm.h linux-3= .1.4/include/linux/mm.h =20 extern unsigned long do_brk(unsigned long, unsigned long); =20 -@@ -1474,6 +1463,10 @@ extern struct vm_area_struct * find_vma( +@@ -1474,6 +1463,10 @@ extern struct vm_area_struct * find_vma(struct mm= _struct * mm, unsigned long add extern struct vm_area_struct * find_vma_prev(struct mm_struct * mm, uns= igned long addr, struct vm_area_struct **pprev); =20 @@ -60446,7 +61961,7 @@ diff -urNp linux-3.1.4/include/linux/mm.h linux-3= .1.4/include/linux/mm.h /* Look up the first VMA which intersects the interval start_addr..end_= addr-1, NULL if none. Assume start_addr < end_addr. */ static inline struct vm_area_struct * find_vma_intersection(struct mm_s= truct * mm, unsigned long start_addr, unsigned long end_addr) -@@ -1490,15 +1483,6 @@ static inline unsigned long vma_pages(st +@@ -1490,15 +1483,6 @@ static inline unsigned long vma_pages(struct vm_a= rea_struct *vma) return (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; } =20 @@ -60462,7 +61977,7 @@ diff -urNp linux-3.1.4/include/linux/mm.h linux-3= .1.4/include/linux/mm.h struct vm_area_struct *find_extend_vma(struct mm_struct *, unsigned lon= g addr); int remap_pfn_range(struct vm_area_struct *, unsigned long addr, unsigned long pfn, unsigned long size, pgprot_t); -@@ -1612,7 +1596,7 @@ extern int unpoison_memory(unsigned long +@@ -1612,7 +1596,7 @@ extern int unpoison_memory(unsigned long pfn); extern int sysctl_memory_failure_early_kill; extern int sysctl_memory_failure_recovery; extern void shake_page(struct page *p, int access); @@ -60471,7 +61986,7 @@ diff -urNp linux-3.1.4/include/linux/mm.h linux-3= .1.4/include/linux/mm.h extern int soft_offline_page(struct page *page, int flags); =20 extern void dump_page(struct page *page); -@@ -1626,5 +1610,11 @@ extern void copy_user_huge_page(struct p +@@ -1626,5 +1610,11 @@ extern void copy_user_huge_page(struct page *dst,= struct page *src, unsigned int pages_per_huge_page); #endif /* CONFIG_TRANSPARENT_HUGEPAGE || CONFIG_HUGETLBFS */ =20 @@ -60483,9 +61998,10 @@ diff -urNp linux-3.1.4/include/linux/mm.h linux-= 3.1.4/include/linux/mm.h + #endif /* __KERNEL__ */ #endif /* _LINUX_MM_H */ -diff -urNp linux-3.1.4/include/linux/mm_types.h linux-3.1.4/include/linu= x/mm_types.h ---- linux-3.1.4/include/linux/mm_types.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/mm_types.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h +index 10a2f62..c8fa287 100644 +--- a/include/linux/mm_types.h ++++ b/include/linux/mm_types.h @@ -230,6 +230,8 @@ struct vm_area_struct { #ifdef CONFIG_NUMA struct mempolicy *vm_policy; /* NUMA policy for the VMA */ @@ -60520,10 +62036,11 @@ diff -urNp linux-3.1.4/include/linux/mm_types.h= linux-3.1.4/include/linux/mm_typ }; =20 static inline void mm_init_cpumask(struct mm_struct *mm) -diff -urNp linux-3.1.4/include/linux/mmu_notifier.h linux-3.1.4/include/= linux/mmu_notifier.h ---- linux-3.1.4/include/linux/mmu_notifier.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/include/linux/mmu_notifier.h 2011-11-16 18:39:08.0000000= 00 -0500 -@@ -255,12 +255,12 @@ static inline void mmu_notifier_mm_destr +diff --git a/include/linux/mmu_notifier.h b/include/linux/mmu_notifier.h +index 1d1b1e1..2a13c78 100644 +--- a/include/linux/mmu_notifier.h ++++ b/include/linux/mmu_notifier.h +@@ -255,12 +255,12 @@ static inline void mmu_notifier_mm_destroy(struct = mm_struct *mm) */ #define ptep_clear_flush_notify(__vma, __address, __ptep) \ ({ \ @@ -60539,9 +62056,10 @@ diff -urNp linux-3.1.4/include/linux/mmu_notifie= r.h linux-3.1.4/include/linux/mm }) =20 #define pmdp_clear_flush_notify(__vma, __address, __pmdp) \ -diff -urNp linux-3.1.4/include/linux/mmzone.h linux-3.1.4/include/linux/= mmzone.h ---- linux-3.1.4/include/linux/mmzone.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/mmzone.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h +index be1ac8d..26868ce 100644 +--- a/include/linux/mmzone.h ++++ b/include/linux/mmzone.h @@ -356,7 +356,7 @@ struct zone { unsigned long flags; /* zone flags, see below */ =20 @@ -60551,9 +62069,10 @@ diff -urNp linux-3.1.4/include/linux/mmzone.h li= nux-3.1.4/include/linux/mmzone.h =20 /* * The target ratio of ACTIVE_ANON to INACTIVE_ANON pages on -diff -urNp linux-3.1.4/include/linux/mod_devicetable.h linux-3.1.4/inclu= de/linux/mod_devicetable.h ---- linux-3.1.4/include/linux/mod_devicetable.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/include/linux/mod_devicetable.h 2011-11-16 18:39:08.0000= 00000 -0500 +diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicet= able.h +index ae28e93..1ac2233 100644 +--- a/include/linux/mod_devicetable.h ++++ b/include/linux/mod_devicetable.h @@ -12,7 +12,7 @@ typedef unsigned long kernel_ulong_t; #endif @@ -60572,9 +62091,10 @@ diff -urNp linux-3.1.4/include/linux/mod_devicet= able.h linux-3.1.4/include/linux =20 struct hid_device_id { __u16 bus; -diff -urNp linux-3.1.4/include/linux/module.h linux-3.1.4/include/linux/= module.h ---- linux-3.1.4/include/linux/module.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/module.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/module.h b/include/linux/module.h +index 1c30087..fc2a442 100644 +--- a/include/linux/module.h ++++ b/include/linux/module.h @@ -16,6 +16,7 @@ #include #include @@ -60618,7 +62138,7 @@ diff -urNp linux-3.1.4/include/linux/module.h lin= ux-3.1.4/include/linux/module.h #endif #ifdef CONFIG_FTRACE_MCOUNT_RECORD unsigned int num_ftrace_callsites; -@@ -445,16 +447,46 @@ bool is_module_address(unsigned long add +@@ -445,16 +447,46 @@ bool is_module_address(unsigned long addr); bool is_module_percpu_address(unsigned long addr); bool is_module_text_address(unsigned long addr); =20 @@ -60669,10 +62189,11 @@ diff -urNp linux-3.1.4/include/linux/module.h l= inux-3.1.4/include/linux/module.h } =20 /* Search for module by name: must hold module_mutex. */ -diff -urNp linux-3.1.4/include/linux/moduleloader.h linux-3.1.4/include/= linux/moduleloader.h ---- linux-3.1.4/include/linux/moduleloader.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/include/linux/moduleloader.h 2011-11-16 18:39:08.0000000= 00 -0500 -@@ -25,9 +25,21 @@ unsigned int arch_mod_section_prepend(st +diff --git a/include/linux/moduleloader.h b/include/linux/moduleloader.h +index b2be02e..6a9fdb1 100644 +--- a/include/linux/moduleloader.h ++++ b/include/linux/moduleloader.h +@@ -25,9 +25,21 @@ unsigned int arch_mod_section_prepend(struct module *= mod, unsigned int section); sections. Returns NULL on failure. */ void *module_alloc(unsigned long size); =20 @@ -60694,10 +62215,11 @@ diff -urNp linux-3.1.4/include/linux/moduleload= er.h linux-3.1.4/include/linux/mo /* Apply the given relocation to the (simplified) ELF. Return -error or 0. */ int apply_relocate(Elf_Shdr *sechdrs, -diff -urNp linux-3.1.4/include/linux/moduleparam.h linux-3.1.4/include/l= inux/moduleparam.h ---- linux-3.1.4/include/linux/moduleparam.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/linux/moduleparam.h 2011-11-16 18:39:08.00000000= 0 -0500 -@@ -255,7 +255,7 @@ static inline void __kernel_param_unlock +diff --git a/include/linux/moduleparam.h b/include/linux/moduleparam.h +index ddaae98..3c70938 100644 +--- a/include/linux/moduleparam.h ++++ b/include/linux/moduleparam.h +@@ -255,7 +255,7 @@ static inline void __kernel_param_unlock(void) * @len is usually just sizeof(string). */ #define module_param_string(name, string, len, perm) \ @@ -60706,7 +62228,7 @@ diff -urNp linux-3.1.4/include/linux/moduleparam.= h linux-3.1.4/include/linux/mod =3D { len, string }; \ __module_param_call(MODULE_PARAM_PREFIX, name, \ ¶m_ops_string, \ -@@ -370,7 +370,7 @@ extern int param_get_invbool(char *buffe +@@ -370,7 +370,7 @@ extern int param_get_invbool(char *buffer, const str= uct kernel_param *kp); * module_param_named() for why this might be necessary. */ #define module_param_array_named(name, array, type, nump, perm) \ @@ -60715,9 +62237,10 @@ diff -urNp linux-3.1.4/include/linux/moduleparam= .h linux-3.1.4/include/linux/mod =3D { .max =3D ARRAY_SIZE(array), .num =3D nump, = \ .ops =3D ¶m_ops_##type, \ .elemsize =3D sizeof(array[0]), .elem =3D array }; \ -diff -urNp linux-3.1.4/include/linux/namei.h linux-3.1.4/include/linux/n= amei.h ---- linux-3.1.4/include/linux/namei.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/namei.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/linux/namei.h b/include/linux/namei.h +index ffc0213..2c1f2cb 100644 +--- a/include/linux/namei.h ++++ b/include/linux/namei.h @@ -24,7 +24,7 @@ struct nameidata { unsigned seq; int last_type; @@ -60742,9 +62265,10 @@ diff -urNp linux-3.1.4/include/linux/namei.h lin= ux-3.1.4/include/linux/namei.h { return nd->saved_names[nd->depth]; } -diff -urNp linux-3.1.4/include/linux/netdevice.h linux-3.1.4/include/lin= ux/netdevice.h ---- linux-3.1.4/include/linux/netdevice.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/include/linux/netdevice.h 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h +index ddee79b..67af106 100644 +--- a/include/linux/netdevice.h ++++ b/include/linux/netdevice.h @@ -944,6 +944,7 @@ struct net_device_ops { int (*ndo_set_features)(struct net_device *dev, u32 features); @@ -60753,9 +62277,11 @@ diff -urNp linux-3.1.4/include/linux/netdevice.h= linux-3.1.4/include/linux/netde =20 /* * The DEVICE structure. -diff -urNp linux-3.1.4/include/linux/netfilter/xt_gradm.h linux-3.1.4/in= clude/linux/netfilter/xt_gradm.h ---- linux-3.1.4/include/linux/netfilter/xt_gradm.h 1969-12-31 19:00:00.0= 00000000 -0500 -+++ linux-3.1.4/include/linux/netfilter/xt_gradm.h 2011-11-16 18:40:31.0= 00000000 -0500 +diff --git a/include/linux/netfilter/xt_gradm.h b/include/linux/netfilte= r/xt_gradm.h +new file mode 100644 +index 0000000..33f4af8 +--- /dev/null ++++ b/include/linux/netfilter/xt_gradm.h @@ -0,0 +1,9 @@ +#ifndef _LINUX_NETFILTER_XT_GRADM_H +#define _LINUX_NETFILTER_XT_GRADM_H 1 @@ -60766,9 +62292,10 @@ diff -urNp linux-3.1.4/include/linux/netfilter/x= t_gradm.h linux-3.1.4/include/li +}; + +#endif -diff -urNp linux-3.1.4/include/linux/of_pdt.h linux-3.1.4/include/linux/= of_pdt.h ---- linux-3.1.4/include/linux/of_pdt.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/of_pdt.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/of_pdt.h b/include/linux/of_pdt.h +index c65a18a..0c05f3a 100644 +--- a/include/linux/of_pdt.h ++++ b/include/linux/of_pdt.h @@ -32,7 +32,7 @@ struct of_pdt_ops { =20 /* return 0 on success; fill in 'len' with number of bytes in path */ @@ -60778,10 +62305,11 @@ diff -urNp linux-3.1.4/include/linux/of_pdt.h l= inux-3.1.4/include/linux/of_pdt.h =20 extern void *prom_early_alloc(unsigned long size); =20 -diff -urNp linux-3.1.4/include/linux/oprofile.h linux-3.1.4/include/linu= x/oprofile.h ---- linux-3.1.4/include/linux/oprofile.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/oprofile.h 2011-11-16 18:39:08.000000000 -= 0500 -@@ -139,9 +139,9 @@ int oprofilefs_create_ulong(struct super +diff --git a/include/linux/oprofile.h b/include/linux/oprofile.h +index 49c8727..34d2ae1 100644 +--- a/include/linux/oprofile.h ++++ b/include/linux/oprofile.h +@@ -139,9 +139,9 @@ int oprofilefs_create_ulong(struct super_block * sb,= struct dentry * root, int oprofilefs_create_ro_ulong(struct super_block * sb, struct dentry *= root, char const * name, ulong * val); =20 @@ -60793,9 +62321,10 @@ diff -urNp linux-3.1.4/include/linux/oprofile.h = linux-3.1.4/include/linux/oprofi =20 /** create a directory */ struct dentry * oprofilefs_mkdir(struct super_block * sb, struct dentry= * root, -diff -urNp linux-3.1.4/include/linux/padata.h linux-3.1.4/include/linux/= padata.h ---- linux-3.1.4/include/linux/padata.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/padata.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/padata.h b/include/linux/padata.h +index 4633b2f..988bc08 100644 +--- a/include/linux/padata.h ++++ b/include/linux/padata.h @@ -129,7 +129,7 @@ struct parallel_data { struct padata_instance *pinst; struct padata_parallel_queue __percpu *pqueue; @@ -60805,9 +62334,10 @@ diff -urNp linux-3.1.4/include/linux/padata.h li= nux-3.1.4/include/linux/padata.h atomic_t reorder_objects; atomic_t refcnt; unsigned int max_seq_nr; -diff -urNp linux-3.1.4/include/linux/perf_event.h linux-3.1.4/include/li= nux/perf_event.h ---- linux-3.1.4/include/linux/perf_event.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/linux/perf_event.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h +index c816075..cd28c4d 100644 +--- a/include/linux/perf_event.h ++++ b/include/linux/perf_event.h @@ -745,8 +745,8 @@ struct perf_event { =20 enum perf_event_active_state state; @@ -60830,9 +62360,10 @@ diff -urNp linux-3.1.4/include/linux/perf_event.= h linux-3.1.4/include/linux/perf =20 /* * Protect attach/detach and child_list: -diff -urNp linux-3.1.4/include/linux/pipe_fs_i.h linux-3.1.4/include/lin= ux/pipe_fs_i.h ---- linux-3.1.4/include/linux/pipe_fs_i.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/include/linux/pipe_fs_i.h 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/include/linux/pipe_fs_i.h b/include/linux/pipe_fs_i.h +index 77257c9..51d473a 100644 +--- a/include/linux/pipe_fs_i.h ++++ b/include/linux/pipe_fs_i.h @@ -46,9 +46,9 @@ struct pipe_buffer { struct pipe_inode_info { wait_queue_head_t wait; @@ -60846,10 +62377,11 @@ diff -urNp linux-3.1.4/include/linux/pipe_fs_i.= h linux-3.1.4/include/linux/pipe_ unsigned int r_counter; unsigned int w_counter; struct page *tmp_page; -diff -urNp linux-3.1.4/include/linux/pm_runtime.h linux-3.1.4/include/li= nux/pm_runtime.h ---- linux-3.1.4/include/linux/pm_runtime.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/linux/pm_runtime.h 2011-11-16 18:39:08.000000000= -0500 -@@ -99,7 +99,7 @@ static inline bool pm_runtime_callbacks_ +diff --git a/include/linux/pm_runtime.h b/include/linux/pm_runtime.h +index daac05d..c6802ce 100644 +--- a/include/linux/pm_runtime.h ++++ b/include/linux/pm_runtime.h +@@ -99,7 +99,7 @@ static inline bool pm_runtime_callbacks_present(struct= device *dev) =20 static inline void pm_runtime_mark_last_busy(struct device *dev) { @@ -60858,9 +62390,10 @@ diff -urNp linux-3.1.4/include/linux/pm_runtime.= h linux-3.1.4/include/linux/pm_r } =20 #else /* !CONFIG_PM_RUNTIME */ -diff -urNp linux-3.1.4/include/linux/poison.h linux-3.1.4/include/linux/= poison.h ---- linux-3.1.4/include/linux/poison.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/poison.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/poison.h b/include/linux/poison.h +index 79159de..f1233a9 100644 +--- a/include/linux/poison.h ++++ b/include/linux/poison.h @@ -19,8 +19,8 @@ * under normal circumstances, used to verify that nobody uses * non-initialized list entries. @@ -60872,9 +62405,10 @@ diff -urNp linux-3.1.4/include/linux/poison.h li= nux-3.1.4/include/linux/poison.h =20 /********** include/linux/timer.h **********/ /* -diff -urNp linux-3.1.4/include/linux/preempt.h linux-3.1.4/include/linux= /preempt.h ---- linux-3.1.4/include/linux/preempt.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/linux/preempt.h 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/include/linux/preempt.h b/include/linux/preempt.h +index 58969b2..ead129b 100644 +--- a/include/linux/preempt.h ++++ b/include/linux/preempt.h @@ -123,7 +123,7 @@ struct preempt_ops { void (*sched_in)(struct preempt_notifier *notifier, int cpu); void (*sched_out)(struct preempt_notifier *notifier, @@ -60884,10 +62418,11 @@ diff -urNp linux-3.1.4/include/linux/preempt.h = linux-3.1.4/include/linux/preempt =20 /** * preempt_notifier - key for installing preemption notifiers -diff -urNp linux-3.1.4/include/linux/proc_fs.h linux-3.1.4/include/linux= /proc_fs.h ---- linux-3.1.4/include/linux/proc_fs.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/linux/proc_fs.h 2011-11-16 18:40:31.000000000 -0= 500 -@@ -155,6 +155,19 @@ static inline struct proc_dir_entry *pro +diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h +index 643b96c..ef55a9c 100644 +--- a/include/linux/proc_fs.h ++++ b/include/linux/proc_fs.h +@@ -155,6 +155,19 @@ static inline struct proc_dir_entry *proc_create(co= nst char *name, mode_t mode, return proc_create_data(name, mode, parent, proc_fops, NULL); } =20 @@ -60916,10 +62451,11 @@ diff -urNp linux-3.1.4/include/linux/proc_fs.h = linux-3.1.4/include/linux/proc_fs =20 struct ctl_table_header; struct ctl_table; -diff -urNp linux-3.1.4/include/linux/ptrace.h linux-3.1.4/include/linux/= ptrace.h ---- linux-3.1.4/include/linux/ptrace.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/ptrace.h 2011-11-16 18:40:31.000000000 -05= 00 -@@ -129,10 +129,10 @@ extern void __ptrace_unlink(struct task_ +diff --git a/include/linux/ptrace.h b/include/linux/ptrace.h +index 800f113..af90cc8 100644 +--- a/include/linux/ptrace.h ++++ b/include/linux/ptrace.h +@@ -129,10 +129,10 @@ extern void __ptrace_unlink(struct task_struct *ch= ild); extern void exit_ptrace(struct task_struct *tracer); #define PTRACE_MODE_READ 1 #define PTRACE_MODE_ATTACH 2 @@ -60932,9 +62468,10 @@ diff -urNp linux-3.1.4/include/linux/ptrace.h li= nux-3.1.4/include/linux/ptrace.h =20 static inline int ptrace_reparented(struct task_struct *child) { -diff -urNp linux-3.1.4/include/linux/random.h linux-3.1.4/include/linux/= random.h ---- linux-3.1.4/include/linux/random.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/random.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/random.h b/include/linux/random.h +index d13059f..2eaafaa 100644 +--- a/include/linux/random.h ++++ b/include/linux/random.h @@ -69,12 +69,17 @@ void srandom32(u32 seed); =20 u32 prandom32(struct rnd_state *); @@ -60954,10 +62491,11 @@ diff -urNp linux-3.1.4/include/linux/random.h l= inux-3.1.4/include/linux/random.h } =20 /** -diff -urNp linux-3.1.4/include/linux/reboot.h linux-3.1.4/include/linux/= reboot.h ---- linux-3.1.4/include/linux/reboot.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/reboot.h 2011-11-16 18:39:08.000000000 -05= 00 -@@ -52,9 +52,9 @@ extern int unregister_reboot_notifier(st +diff --git a/include/linux/reboot.h b/include/linux/reboot.h +index e0879a7..a12f962 100644 +--- a/include/linux/reboot.h ++++ b/include/linux/reboot.h +@@ -52,9 +52,9 @@ extern int unregister_reboot_notifier(struct notifier_= block *); * Architecture-specific implementations of sys_reboot commands. */ =20 @@ -60970,7 +62508,7 @@ diff -urNp linux-3.1.4/include/linux/reboot.h lin= ux-3.1.4/include/linux/reboot.h =20 extern void machine_shutdown(void); struct pt_regs; -@@ -65,9 +65,9 @@ extern void machine_crash_shutdown(struc +@@ -65,9 +65,9 @@ extern void machine_crash_shutdown(struct pt_regs *); */ =20 extern void kernel_restart_prepare(char *cmd); @@ -60992,10 +62530,11 @@ diff -urNp linux-3.1.4/include/linux/reboot.h l= inux-3.1.4/include/linux/reboot.h #include =20 #endif -diff -urNp linux-3.1.4/include/linux/reiserfs_fs.h linux-3.1.4/include/l= inux/reiserfs_fs.h ---- linux-3.1.4/include/linux/reiserfs_fs.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/linux/reiserfs_fs.h 2011-11-16 18:39:08.00000000= 0 -0500 -@@ -1406,7 +1406,7 @@ static inline loff_t max_reiserfs_offset +diff --git a/include/linux/reiserfs_fs.h b/include/linux/reiserfs_fs.h +index 96d465f..b084e05 100644 +--- a/include/linux/reiserfs_fs.h ++++ b/include/linux/reiserfs_fs.h +@@ -1406,7 +1406,7 @@ static inline loff_t max_reiserfs_offset(struct in= ode *inode) #define REISERFS_USER_MEM 1 /* reiserfs user memory mode */ =20 #define fs_generation(s) (REISERFS_SB(s)->s_generation_counter) @@ -61004,9 +62543,10 @@ diff -urNp linux-3.1.4/include/linux/reiserfs_fs= .h linux-3.1.4/include/linux/rei #define FILESYSTEM_CHANGED_TB(tb) (get_generation((tb)->tb_sb) !=3D (t= b)->fs_gen) #define __fs_changed(gen,s) (gen !=3D get_generation (s)) #define fs_changed(gen,s) \ -diff -urNp linux-3.1.4/include/linux/reiserfs_fs_sb.h linux-3.1.4/includ= e/linux/reiserfs_fs_sb.h ---- linux-3.1.4/include/linux/reiserfs_fs_sb.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/include/linux/reiserfs_fs_sb.h 2011-11-16 18:39:08.00000= 0000 -0500 +diff --git a/include/linux/reiserfs_fs_sb.h b/include/linux/reiserfs_fs_= sb.h +index 52c83b6..18ed7eb 100644 +--- a/include/linux/reiserfs_fs_sb.h ++++ b/include/linux/reiserfs_fs_sb.h @@ -386,7 +386,7 @@ struct reiserfs_sb_info { /* Comment? -Hans */ wait_queue_head_t s_wait; @@ -61016,9 +62556,10 @@ diff -urNp linux-3.1.4/include/linux/reiserfs_fs= _sb.h linux-3.1.4/include/linux/ // tree gets re-balanced unsigned long s_properties; /* File system properties. Currently holds on-disk FS format */ -diff -urNp linux-3.1.4/include/linux/relay.h linux-3.1.4/include/linux/r= elay.h ---- linux-3.1.4/include/linux/relay.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/relay.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/linux/relay.h b/include/linux/relay.h +index 14a86bc..17d0700 100644 +--- a/include/linux/relay.h ++++ b/include/linux/relay.h @@ -159,7 +159,7 @@ struct rchan_callbacks * The callback should return 0 if successful, negative if not. */ @@ -61028,9 +62569,10 @@ diff -urNp linux-3.1.4/include/linux/relay.h lin= ux-3.1.4/include/linux/relay.h =20 /* * CONFIG_RELAY kernel API, kernel/relay.c -diff -urNp linux-3.1.4/include/linux/rfkill.h linux-3.1.4/include/linux/= rfkill.h ---- linux-3.1.4/include/linux/rfkill.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/rfkill.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/linux/rfkill.h b/include/linux/rfkill.h +index c6c6084..5bf1212 100644 +--- a/include/linux/rfkill.h ++++ b/include/linux/rfkill.h @@ -147,6 +147,7 @@ struct rfkill_ops { void (*query)(struct rfkill *rfkill, void *data); int (*set_block)(void *data, bool blocked); @@ -61039,10 +62581,11 @@ diff -urNp linux-3.1.4/include/linux/rfkill.h l= inux-3.1.4/include/linux/rfkill.h =20 #if defined(CONFIG_RFKILL) || defined(CONFIG_RFKILL_MODULE) /** -diff -urNp linux-3.1.4/include/linux/rmap.h linux-3.1.4/include/linux/rm= ap.h ---- linux-3.1.4/include/linux/rmap.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/rmap.h 2011-11-16 18:39:08.000000000 -0500 -@@ -119,8 +119,8 @@ static inline void anon_vma_unlock(struc +diff --git a/include/linux/rmap.h b/include/linux/rmap.h +index 2148b12..519b820 100644 +--- a/include/linux/rmap.h ++++ b/include/linux/rmap.h +@@ -119,8 +119,8 @@ static inline void anon_vma_unlock(struct anon_vma *= anon_vma) void anon_vma_init(void); /* create anon_vma_cachep */ int anon_vma_prepare(struct vm_area_struct *); void unlink_anon_vmas(struct vm_area_struct *); @@ -61053,9 +62596,10 @@ diff -urNp linux-3.1.4/include/linux/rmap.h linu= x-3.1.4/include/linux/rmap.h void __anon_vma_link(struct vm_area_struct *); =20 static inline void anon_vma_merge(struct vm_area_struct *vma, -diff -urNp linux-3.1.4/include/linux/sched.h linux-3.1.4/include/linux/s= ched.h ---- linux-3.1.4/include/linux/sched.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/sched.h 2011-11-16 18:40:31.000000000 -050= 0 +diff --git a/include/linux/sched.h b/include/linux/sched.h +index 41d0237..5a64056 100644 +--- a/include/linux/sched.h ++++ b/include/linux/sched.h @@ -100,6 +100,7 @@ struct bio_list; struct fs_struct; struct perf_event_context; @@ -61260,7 +62804,7 @@ diff -urNp linux-3.1.4/include/linux/sched.h linu= x-3.1.4/include/linux/sched.h extern struct task_struct *find_task_by_pid_ns(pid_t nr, struct pid_namespace *ns); =20 -@@ -2243,7 +2338,7 @@ extern void __cleanup_sighand(struct sig +@@ -2243,7 +2338,7 @@ extern void __cleanup_sighand(struct sighand_struc= t *); extern void exit_itimers(struct signal_struct *); extern void flush_itimer_signals(void); =20 @@ -61269,7 +62813,7 @@ diff -urNp linux-3.1.4/include/linux/sched.h linu= x-3.1.4/include/linux/sched.h =20 extern void daemonize(const char *, ...); extern int allow_signal(int); -@@ -2408,13 +2503,17 @@ static inline unsigned long *end_of_stac +@@ -2408,13 +2503,17 @@ static inline unsigned long *end_of_stack(struct= task_struct *p) =20 #endif =20 @@ -61289,9 +62833,10 @@ diff -urNp linux-3.1.4/include/linux/sched.h lin= ux-3.1.4/include/linux/sched.h extern void thread_info_cache_init(void); =20 #ifdef CONFIG_DEBUG_STACK_USAGE -diff -urNp linux-3.1.4/include/linux/screen_info.h linux-3.1.4/include/l= inux/screen_info.h ---- linux-3.1.4/include/linux/screen_info.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/linux/screen_info.h 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/include/linux/screen_info.h b/include/linux/screen_info.h +index 899fbb4..1cb4138 100644 +--- a/include/linux/screen_info.h ++++ b/include/linux/screen_info.h @@ -43,7 +43,8 @@ struct screen_info { __u16 pages; /* 0x32 */ __u16 vesa_attributes; /* 0x34 */ @@ -61302,9 +62847,10 @@ diff -urNp linux-3.1.4/include/linux/screen_info= .h linux-3.1.4/include/linux/scr } __attribute__((packed)); =20 #define VIDEO_TYPE_MDA 0x10 /* Monochrome Text Display */ -diff -urNp linux-3.1.4/include/linux/security.h linux-3.1.4/include/linu= x/security.h ---- linux-3.1.4/include/linux/security.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/security.h 2011-11-16 18:40:31.000000000 -= 0500 +diff --git a/include/linux/security.h b/include/linux/security.h +index ebd2a53..2d949ae 100644 +--- a/include/linux/security.h ++++ b/include/linux/security.h @@ -36,6 +36,7 @@ #include #include @@ -61313,9 +62859,10 @@ diff -urNp linux-3.1.4/include/linux/security.h = linux-3.1.4/include/linux/securi #include =20 /* Maximum number of letters for an LSM name string */ -diff -urNp linux-3.1.4/include/linux/seq_file.h linux-3.1.4/include/linu= x/seq_file.h ---- linux-3.1.4/include/linux/seq_file.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/seq_file.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/include/linux/seq_file.h b/include/linux/seq_file.h +index be720cd..a0e1b94 100644 +--- a/include/linux/seq_file.h ++++ b/include/linux/seq_file.h @@ -33,6 +33,7 @@ struct seq_operations { void * (*next) (struct seq_file *m, void *v, loff_t *pos); int (*show) (struct seq_file *m, void *v); @@ -61324,10 +62871,11 @@ diff -urNp linux-3.1.4/include/linux/seq_file.h= linux-3.1.4/include/linux/seq_fi =20 #define SEQ_SKIP 1 =20 -diff -urNp linux-3.1.4/include/linux/shm.h linux-3.1.4/include/linux/shm= .h ---- linux-3.1.4/include/linux/shm.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/shm.h 2011-11-16 18:59:58.000000000 -0500 -@@ -98,6 +98,10 @@ struct shmid_kernel /* private to the ke +diff --git a/include/linux/shm.h b/include/linux/shm.h +index 92808b8..c28cac4 100644 +--- a/include/linux/shm.h ++++ b/include/linux/shm.h +@@ -98,6 +98,10 @@ struct shmid_kernel /* private to the kernel */ =20 /* The task created the shm object. NULL if the task is dead. */ struct task_struct *shm_creator; @@ -61338,10 +62886,11 @@ diff -urNp linux-3.1.4/include/linux/shm.h linu= x-3.1.4/include/linux/shm.h }; =20 /* shm_mode upper byte flags */ -diff -urNp linux-3.1.4/include/linux/skbuff.h linux-3.1.4/include/linux/= skbuff.h ---- linux-3.1.4/include/linux/skbuff.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/skbuff.h 2011-11-16 18:39:08.000000000 -05= 00 -@@ -610,7 +610,7 @@ static inline struct skb_shared_hwtstamp +diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h +index 0f96646..cfb757a 100644 +--- a/include/linux/skbuff.h ++++ b/include/linux/skbuff.h +@@ -610,7 +610,7 @@ static inline struct skb_shared_hwtstamps *skb_hwtst= amps(struct sk_buff *skb) */ static inline int skb_queue_empty(const struct sk_buff_head *list) { @@ -61350,7 +62899,7 @@ diff -urNp linux-3.1.4/include/linux/skbuff.h lin= ux-3.1.4/include/linux/skbuff.h } =20 /** -@@ -623,7 +623,7 @@ static inline int skb_queue_empty(const=20 +@@ -623,7 +623,7 @@ static inline int skb_queue_empty(const struct sk_bu= ff_head *list) static inline bool skb_queue_is_last(const struct sk_buff_head *list, const struct sk_buff *skb) { @@ -61359,7 +62908,7 @@ diff -urNp linux-3.1.4/include/linux/skbuff.h lin= ux-3.1.4/include/linux/skbuff.h } =20 /** -@@ -636,7 +636,7 @@ static inline bool skb_queue_is_last(con +@@ -636,7 +636,7 @@ static inline bool skb_queue_is_last(const struct sk= _buff_head *list, static inline bool skb_queue_is_first(const struct sk_buff_head *list, const struct sk_buff *skb) { @@ -61368,7 +62917,7 @@ diff -urNp linux-3.1.4/include/linux/skbuff.h lin= ux-3.1.4/include/linux/skbuff.h } =20 /** -@@ -1458,7 +1458,7 @@ static inline int pskb_network_may_pull( +@@ -1458,7 +1458,7 @@ static inline int pskb_network_may_pull(struct sk_= buff *skb, unsigned int len) * NET_IP_ALIGN(2) + ethernet_header(14) + IP_header(20/40) + ports(8) */ #ifndef NET_SKB_PAD @@ -61377,27 +62926,10 @@ diff -urNp linux-3.1.4/include/linux/skbuff.h l= inux-3.1.4/include/linux/skbuff.h #endif =20 extern int ___pskb_trim(struct sk_buff *skb, unsigned int len); -diff -urNp linux-3.1.4/include/linux/slab_def.h linux-3.1.4/include/linu= x/slab_def.h ---- linux-3.1.4/include/linux/slab_def.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/slab_def.h 2011-11-16 18:39:08.000000000 -= 0500 -@@ -68,10 +68,10 @@ struct kmem_cache { - unsigned long node_allocs; - unsigned long node_frees; - unsigned long node_overflow; -- atomic_t allochit; -- atomic_t allocmiss; -- atomic_t freehit; -- atomic_t freemiss; -+ atomic_unchecked_t allochit; -+ atomic_unchecked_t allocmiss; -+ atomic_unchecked_t freehit; -+ atomic_unchecked_t freemiss; -=20 - /* - * If debugging is enabled, then the allocator can add additional -diff -urNp linux-3.1.4/include/linux/slab.h linux-3.1.4/include/linux/sl= ab.h ---- linux-3.1.4/include/linux/slab.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/linux/slab.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/linux/slab.h b/include/linux/slab.h +index 573c809..e84c132 100644 +--- a/include/linux/slab.h ++++ b/include/linux/slab.h @@ -11,12 +11,20 @@ =20 #include @@ -61436,7 +62968,7 @@ diff -urNp linux-3.1.4/include/linux/slab.h linux= -3.1.4/include/linux/slab.h =20 /* * struct kmem_cache related prototypes -@@ -161,6 +172,7 @@ void * __must_check krealloc(const void=20 +@@ -161,6 +172,7 @@ void * __must_check krealloc(const void *, size_t, g= fp_t); void kfree(const void *); void kzfree(const void *); size_t ksize(const void *); @@ -61444,7 +62976,7 @@ diff -urNp linux-3.1.4/include/linux/slab.h linux= -3.1.4/include/linux/slab.h =20 /* * Allocator specific definitions. These are mainly used to establish o= ptimized -@@ -353,4 +365,59 @@ static inline void *kzalloc_node(size_t=20 +@@ -353,4 +365,59 @@ static inline void *kzalloc_node(size_t size, gfp_t= flags, int node) =20 void __init kmem_cache_init_late(void); =20 @@ -61504,9 +63036,29 @@ diff -urNp linux-3.1.4/include/linux/slab.h linu= x-3.1.4/include/linux/slab.h +}) + #endif /* _LINUX_SLAB_H */ -diff -urNp linux-3.1.4/include/linux/slub_def.h linux-3.1.4/include/linu= x/slub_def.h ---- linux-3.1.4/include/linux/slub_def.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/slub_def.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/include/linux/slab_def.h b/include/linux/slab_def.h +index d00e0ba..1b3bf7b 100644 +--- a/include/linux/slab_def.h ++++ b/include/linux/slab_def.h +@@ -68,10 +68,10 @@ struct kmem_cache { + unsigned long node_allocs; + unsigned long node_frees; + unsigned long node_overflow; +- atomic_t allochit; +- atomic_t allocmiss; +- atomic_t freehit; +- atomic_t freemiss; ++ atomic_unchecked_t allochit; ++ atomic_unchecked_t allocmiss; ++ atomic_unchecked_t freehit; ++ atomic_unchecked_t freemiss; +=20 + /* + * If debugging is enabled, then the allocator can add additional +diff --git a/include/linux/slub_def.h b/include/linux/slub_def.h +index f58d641..c56bf9c 100644 +--- a/include/linux/slub_def.h ++++ b/include/linux/slub_def.h @@ -85,7 +85,7 @@ struct kmem_cache { struct kmem_cache_order_objects max; struct kmem_cache_order_objects min; @@ -61516,7 +63068,7 @@ diff -urNp linux-3.1.4/include/linux/slub_def.h l= inux-3.1.4/include/linux/slub_d void (*ctor)(void *); int inuse; /* Offset to metadata */ int align; /* Alignment */ -@@ -211,7 +211,7 @@ static __always_inline struct kmem_cache +@@ -211,7 +211,7 @@ static __always_inline struct kmem_cache *kmalloc_sl= ab(size_t size) } =20 void *kmem_cache_alloc(struct kmem_cache *, gfp_t); @@ -61525,9 +63077,10 @@ diff -urNp linux-3.1.4/include/linux/slub_def.h = linux-3.1.4/include/linux/slub_d =20 static __always_inline void * kmalloc_order(size_t size, gfp_t flags, unsigned int order) -diff -urNp linux-3.1.4/include/linux/sonet.h linux-3.1.4/include/linux/s= onet.h ---- linux-3.1.4/include/linux/sonet.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/sonet.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/linux/sonet.h b/include/linux/sonet.h +index de8832d..0147b46 100644 +--- a/include/linux/sonet.h ++++ b/include/linux/sonet.h @@ -61,7 +61,7 @@ struct sonet_stats { #include =20 @@ -61537,10 +63090,11 @@ diff -urNp linux-3.1.4/include/linux/sonet.h li= nux-3.1.4/include/linux/sonet.h __SONET_ITEMS #undef __HANDLE_ITEM }; -diff -urNp linux-3.1.4/include/linux/sunrpc/clnt.h linux-3.1.4/include/l= inux/sunrpc/clnt.h ---- linux-3.1.4/include/linux/sunrpc/clnt.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/linux/sunrpc/clnt.h 2011-11-16 18:39:08.00000000= 0 -0500 -@@ -169,9 +169,9 @@ static inline unsigned short rpc_get_por +diff --git a/include/linux/sunrpc/clnt.h b/include/linux/sunrpc/clnt.h +index db7bcaf..1aca77e 100644 +--- a/include/linux/sunrpc/clnt.h ++++ b/include/linux/sunrpc/clnt.h +@@ -169,9 +169,9 @@ static inline unsigned short rpc_get_port(const stru= ct sockaddr *sap) { switch (sap->sa_family) { case AF_INET: @@ -61552,7 +63106,7 @@ diff -urNp linux-3.1.4/include/linux/sunrpc/clnt.= h linux-3.1.4/include/linux/sun } return 0; } -@@ -204,7 +204,7 @@ static inline bool __rpc_cmp_addr4(const +@@ -204,7 +204,7 @@ static inline bool __rpc_cmp_addr4(const struct sock= addr *sap1, static inline bool __rpc_copy_addr4(struct sockaddr *dst, const struct sockaddr *src) { @@ -61561,7 +63115,7 @@ diff -urNp linux-3.1.4/include/linux/sunrpc/clnt.= h linux-3.1.4/include/linux/sun struct sockaddr_in *dsin =3D (struct sockaddr_in *) dst; =20 dsin->sin_family =3D ssin->sin_family; -@@ -301,7 +301,7 @@ static inline u32 rpc_get_scope_id(const +@@ -301,7 +301,7 @@ static inline u32 rpc_get_scope_id(const struct sock= addr *sa) if (sa->sa_family !=3D AF_INET6) return 0; =20 @@ -61570,9 +63124,10 @@ diff -urNp linux-3.1.4/include/linux/sunrpc/clnt= .h linux-3.1.4/include/linux/sun } =20 #endif /* __KERNEL__ */ -diff -urNp linux-3.1.4/include/linux/sunrpc/sched.h linux-3.1.4/include/= linux/sunrpc/sched.h ---- linux-3.1.4/include/linux/sunrpc/sched.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/include/linux/sunrpc/sched.h 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/include/linux/sunrpc/sched.h b/include/linux/sunrpc/sched.h +index e775689..9e206d9 100644 +--- a/include/linux/sunrpc/sched.h ++++ b/include/linux/sunrpc/sched.h @@ -105,6 +105,7 @@ struct rpc_call_ops { void (*rpc_call_done)(struct rpc_task *, void *); void (*rpc_release)(void *); @@ -61581,9 +63136,10 @@ diff -urNp linux-3.1.4/include/linux/sunrpc/sche= d.h linux-3.1.4/include/linux/su =20 struct rpc_task_setup { struct rpc_task *task; -diff -urNp linux-3.1.4/include/linux/sunrpc/svc_rdma.h linux-3.1.4/inclu= de/linux/sunrpc/svc_rdma.h ---- linux-3.1.4/include/linux/sunrpc/svc_rdma.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/include/linux/sunrpc/svc_rdma.h 2011-11-16 18:39:08.0000= 00000 -0500 +diff --git a/include/linux/sunrpc/svc_rdma.h b/include/linux/sunrpc/svc_= rdma.h +index c14fe86..393245e 100644 +--- a/include/linux/sunrpc/svc_rdma.h ++++ b/include/linux/sunrpc/svc_rdma.h @@ -53,15 +53,15 @@ extern unsigned int svcrdma_ord; extern unsigned int svcrdma_max_requests; extern unsigned int svcrdma_max_req_size; @@ -61609,9 +63165,10 @@ diff -urNp linux-3.1.4/include/linux/sunrpc/svc_= rdma.h linux-3.1.4/include/linux =20 #define RPCRDMA_VERSION 1 =20 -diff -urNp linux-3.1.4/include/linux/sysctl.h linux-3.1.4/include/linux/= sysctl.h ---- linux-3.1.4/include/linux/sysctl.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/sysctl.h 2011-11-16 18:40:31.000000000 -05= 00 +diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h +index 11684d9..0d245eb 100644 +--- a/include/linux/sysctl.h ++++ b/include/linux/sysctl.h @@ -155,7 +155,11 @@ enum KERN_PANIC_ON_NMI=3D76, /* int: whether we will panic on an unrecovere= d */ }; @@ -61625,7 +63182,7 @@ diff -urNp linux-3.1.4/include/linux/sysctl.h lin= ux-3.1.4/include/linux/sysctl.h =20 /* CTL_VM names: */ enum -@@ -967,6 +971,8 @@ typedef int proc_handler (struct ctl_tab +@@ -967,6 +971,8 @@ typedef int proc_handler (struct ctl_table *ctl, int= write, =20 extern int proc_dostring(struct ctl_table *, int, void __user *, size_t *, loff_t *); @@ -61634,9 +63191,10 @@ diff -urNp linux-3.1.4/include/linux/sysctl.h li= nux-3.1.4/include/linux/sysctl.h extern int proc_dointvec(struct ctl_table *, int, void __user *, size_t *, loff_t *); extern int proc_dointvec_minmax(struct ctl_table *, int, -diff -urNp linux-3.1.4/include/linux/tty_ldisc.h linux-3.1.4/include/lin= ux/tty_ldisc.h ---- linux-3.1.4/include/linux/tty_ldisc.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/include/linux/tty_ldisc.h 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/include/linux/tty_ldisc.h b/include/linux/tty_ldisc.h +index ff7dc08..893e1bd 100644 +--- a/include/linux/tty_ldisc.h ++++ b/include/linux/tty_ldisc.h @@ -148,7 +148,7 @@ struct tty_ldisc_ops { =20 struct module *owner; @@ -61646,9 +63204,10 @@ diff -urNp linux-3.1.4/include/linux/tty_ldisc.h= linux-3.1.4/include/linux/tty_l }; =20 struct tty_ldisc { -diff -urNp linux-3.1.4/include/linux/types.h linux-3.1.4/include/linux/t= ypes.h ---- linux-3.1.4/include/linux/types.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/linux/types.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/linux/types.h b/include/linux/types.h +index 176da8c..e45e473 100644 +--- a/include/linux/types.h ++++ b/include/linux/types.h @@ -213,10 +213,26 @@ typedef struct { int counter; } atomic_t; @@ -61676,10 +63235,11 @@ diff -urNp linux-3.1.4/include/linux/types.h li= nux-3.1.4/include/linux/types.h #endif =20 struct list_head { -diff -urNp linux-3.1.4/include/linux/uaccess.h linux-3.1.4/include/linux= /uaccess.h ---- linux-3.1.4/include/linux/uaccess.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/linux/uaccess.h 2011-11-16 18:39:08.000000000 -0= 500 -@@ -76,11 +76,11 @@ static inline unsigned long __copy_from_ +diff --git a/include/linux/uaccess.h b/include/linux/uaccess.h +index 5ca0951..ab496a5 100644 +--- a/include/linux/uaccess.h ++++ b/include/linux/uaccess.h +@@ -76,11 +76,11 @@ static inline unsigned long __copy_from_user_nocache= (void *to, long ret; \ mm_segment_t old_fs =3D get_fs(); \ \ @@ -61694,9 +63254,10 @@ diff -urNp linux-3.1.4/include/linux/uaccess.h l= inux-3.1.4/include/linux/uaccess ret; \ }) =20 -diff -urNp linux-3.1.4/include/linux/unaligned/access_ok.h linux-3.1.4/i= nclude/linux/unaligned/access_ok.h ---- linux-3.1.4/include/linux/unaligned/access_ok.h 2011-11-11 15:19:27.= 000000000 -0500 -+++ linux-3.1.4/include/linux/unaligned/access_ok.h 2011-11-16 18:39:08.= 000000000 -0500 +diff --git a/include/linux/unaligned/access_ok.h b/include/linux/unalign= ed/access_ok.h +index 99c1b4d..bb94261 100644 +--- a/include/linux/unaligned/access_ok.h ++++ b/include/linux/unaligned/access_ok.h @@ -6,32 +6,32 @@ =20 static inline u16 get_unaligned_le16(const void *p) @@ -61736,9 +63297,10 @@ diff -urNp linux-3.1.4/include/linux/unaligned/a= ccess_ok.h linux-3.1.4/include/l } =20 static inline void put_unaligned_le16(u16 val, void *p) -diff -urNp linux-3.1.4/include/linux/vermagic.h linux-3.1.4/include/linu= x/vermagic.h ---- linux-3.1.4/include/linux/vermagic.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/linux/vermagic.h 2011-11-16 18:54:54.000000000 -= 0500 +diff --git a/include/linux/vermagic.h b/include/linux/vermagic.h +index cf97b5b..40ebc87 100644 +--- a/include/linux/vermagic.h ++++ b/include/linux/vermagic.h @@ -26,9 +26,35 @@ #define MODULE_ARCH_VERMAGIC "" #endif @@ -61776,10 +63338,11 @@ diff -urNp linux-3.1.4/include/linux/vermagic.h= linux-3.1.4/include/linux/vermag + MODULE_PAX_REFCOUNT MODULE_CONSTIFY_PLUGIN MODULE_STACKLEAK_PLUGIN \ + MODULE_GRSEC =20 -diff -urNp linux-3.1.4/include/linux/vmalloc.h linux-3.1.4/include/linux= /vmalloc.h ---- linux-3.1.4/include/linux/vmalloc.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/linux/vmalloc.h 2011-11-16 18:39:08.000000000 -0= 500 -@@ -14,6 +14,11 @@ struct vm_area_struct; /* vma defining=20 +diff --git a/include/linux/vmalloc.h b/include/linux/vmalloc.h +index 687fb11..b342358 100644 +--- a/include/linux/vmalloc.h ++++ b/include/linux/vmalloc.h +@@ -14,6 +14,11 @@ struct vm_area_struct; /* vma defining user mapping = in mm_types.h */ #define VM_USERMAP 0x00000008 /* suitable for remap_vmalloc_range */ #define VM_VPAGES 0x00000010 /* buffer for pages was vmalloc'ed */ #define VM_UNLIST 0x00000020 /* vm_struct is not listed in vmlist */ @@ -61791,7 +63354,7 @@ diff -urNp linux-3.1.4/include/linux/vmalloc.h li= nux-3.1.4/include/linux/vmalloc /* bits [20..32] reserved for arch specific ioremap internals */ =20 /* -@@ -156,4 +161,103 @@ pcpu_free_vm_areas(struct vm_struct **vm +@@ -156,4 +161,103 @@ pcpu_free_vm_areas(struct vm_struct **vms, int nr_= vms) # endif #endif =20 @@ -61895,10 +63458,11 @@ diff -urNp linux-3.1.4/include/linux/vmalloc.h = linux-3.1.4/include/linux/vmalloc +}) + #endif /* _LINUX_VMALLOC_H */ -diff -urNp linux-3.1.4/include/linux/vmstat.h linux-3.1.4/include/linux/= vmstat.h ---- linux-3.1.4/include/linux/vmstat.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/linux/vmstat.h 2011-11-16 18:39:08.000000000 -05= 00 -@@ -87,18 +87,18 @@ static inline void vm_events_fold_cpu(in +diff --git a/include/linux/vmstat.h b/include/linux/vmstat.h +index 65efb92..137adbb 100644 +--- a/include/linux/vmstat.h ++++ b/include/linux/vmstat.h +@@ -87,18 +87,18 @@ static inline void vm_events_fold_cpu(int cpu) /* * Zone based page accounting with per cpu differentials. */ @@ -61921,7 +63485,7 @@ diff -urNp linux-3.1.4/include/linux/vmstat.h lin= ux-3.1.4/include/linux/vmstat.h #ifdef CONFIG_SMP if (x < 0) x =3D 0; -@@ -109,7 +109,7 @@ static inline unsigned long global_page_ +@@ -109,7 +109,7 @@ static inline unsigned long global_page_state(enum z= one_stat_item item) static inline unsigned long zone_page_state(struct zone *zone, enum zone_stat_item item) { @@ -61930,7 +63494,7 @@ diff -urNp linux-3.1.4/include/linux/vmstat.h lin= ux-3.1.4/include/linux/vmstat.h #ifdef CONFIG_SMP if (x < 0) x =3D 0; -@@ -126,7 +126,7 @@ static inline unsigned long zone_page_st +@@ -126,7 +126,7 @@ static inline unsigned long zone_page_state(struct z= one *zone, static inline unsigned long zone_page_state_snapshot(struct zone *zone, enum zone_stat_item item) { @@ -61939,7 +63503,7 @@ diff -urNp linux-3.1.4/include/linux/vmstat.h lin= ux-3.1.4/include/linux/vmstat.h =20 #ifdef CONFIG_SMP int cpu; -@@ -221,8 +221,8 @@ static inline void __mod_zone_page_state +@@ -221,8 +221,8 @@ static inline void __mod_zone_page_state(struct zone= *zone, =20 static inline void __inc_zone_state(struct zone *zone, enum zone_stat_i= tem item) { @@ -61950,7 +63514,7 @@ diff -urNp linux-3.1.4/include/linux/vmstat.h lin= ux-3.1.4/include/linux/vmstat.h } =20 static inline void __inc_zone_page_state(struct page *page, -@@ -233,8 +233,8 @@ static inline void __inc_zone_page_state +@@ -233,8 +233,8 @@ static inline void __inc_zone_page_state(struct page= *page, =20 static inline void __dec_zone_state(struct zone *zone, enum zone_stat_i= tem item) { @@ -61961,9 +63525,10 @@ diff -urNp linux-3.1.4/include/linux/vmstat.h li= nux-3.1.4/include/linux/vmstat.h } =20 static inline void __dec_zone_page_state(struct page *page, -diff -urNp linux-3.1.4/include/media/saa7146_vv.h linux-3.1.4/include/me= dia/saa7146_vv.h ---- linux-3.1.4/include/media/saa7146_vv.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/media/saa7146_vv.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/include/media/saa7146_vv.h b/include/media/saa7146_vv.h +index 4aeff96..b378cdc 100644 +--- a/include/media/saa7146_vv.h ++++ b/include/media/saa7146_vv.h @@ -163,7 +163,7 @@ struct saa7146_ext_vv int (*std_callback)(struct saa7146_dev*, struct saa7146_standard *); =20 @@ -61973,10 +63538,11 @@ diff -urNp linux-3.1.4/include/media/saa7146_vv= .h linux-3.1.4/include/media/saa7 /* pointer to the saa7146 core ops */ const struct v4l2_ioctl_ops *core_ops; =20 -diff -urNp linux-3.1.4/include/media/v4l2-dev.h linux-3.1.4/include/medi= a/v4l2-dev.h ---- linux-3.1.4/include/media/v4l2-dev.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/media/v4l2-dev.h 2011-11-16 18:39:08.000000000 -= 0500 -@@ -56,7 +56,7 @@ int v4l2_prio_check(struct v4l2_prio_sta +diff --git a/include/media/v4l2-dev.h b/include/media/v4l2-dev.h +index c7c40f1..4f01585 100644 +--- a/include/media/v4l2-dev.h ++++ b/include/media/v4l2-dev.h +@@ -56,7 +56,7 @@ int v4l2_prio_check(struct v4l2_prio_state *global, en= um v4l2_priority local); =20 =20 struct v4l2_file_operations { @@ -61993,9 +63559,10 @@ diff -urNp linux-3.1.4/include/media/v4l2-dev.h = linux-3.1.4/include/media/v4l2-d =20 /* * Newer version of video_device, handled by videodev2.c -diff -urNp linux-3.1.4/include/media/v4l2-ioctl.h linux-3.1.4/include/me= dia/v4l2-ioctl.h ---- linux-3.1.4/include/media/v4l2-ioctl.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/media/v4l2-ioctl.h 2011-11-17 18:44:20.000000000= -0500 +diff --git a/include/media/v4l2-ioctl.h b/include/media/v4l2-ioctl.h +index dd9f1e7..8c4dd86 100644 +--- a/include/media/v4l2-ioctl.h ++++ b/include/media/v4l2-ioctl.h @@ -272,7 +272,7 @@ struct v4l2_ioctl_ops { long (*vidioc_default) (struct file *file, void *fh, bool valid_prio, int cmd, void *arg); @@ -62005,9 +63572,10 @@ diff -urNp linux-3.1.4/include/media/v4l2-ioctl.= h linux-3.1.4/include/media/v4l2 =20 /* v4l debugging and diagnostics */ =20 -diff -urNp linux-3.1.4/include/net/caif/caif_hsi.h linux-3.1.4/include/n= et/caif/caif_hsi.h ---- linux-3.1.4/include/net/caif/caif_hsi.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/net/caif/caif_hsi.h 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/include/net/caif/caif_hsi.h b/include/net/caif/caif_hsi.h +index c5dedd8..a93b07b 100644 +--- a/include/net/caif/caif_hsi.h ++++ b/include/net/caif/caif_hsi.h @@ -94,7 +94,7 @@ struct cfhsi_drv { void (*rx_done_cb) (struct cfhsi_drv *drv); void (*wake_up_cb) (struct cfhsi_drv *drv); @@ -62017,9 +63585,10 @@ diff -urNp linux-3.1.4/include/net/caif/caif_hsi= .h linux-3.1.4/include/net/caif/ =20 /* Structure implemented by HSI device. */ struct cfhsi_dev { -diff -urNp linux-3.1.4/include/net/caif/cfctrl.h linux-3.1.4/include/net= /caif/cfctrl.h ---- linux-3.1.4/include/net/caif/cfctrl.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/include/net/caif/cfctrl.h 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/include/net/caif/cfctrl.h b/include/net/caif/cfctrl.h +index 9e5425b..8136ffc 100644 +--- a/include/net/caif/cfctrl.h ++++ b/include/net/caif/cfctrl.h @@ -52,7 +52,7 @@ struct cfctrl_rsp { void (*radioset_rsp)(void); void (*reject_rsp)(struct cflayer *layer, u8 linkid, @@ -62040,10 +63609,11 @@ diff -urNp linux-3.1.4/include/net/caif/cfctrl.= h linux-3.1.4/include/net/caif/cf struct list_head list; /* Protects from simultaneous access to first_req list */ spinlock_t info_list_lock; -diff -urNp linux-3.1.4/include/net/flow.h linux-3.1.4/include/net/flow.h ---- linux-3.1.4/include/net/flow.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/flow.h 2011-11-16 18:39:08.000000000 -0500 -@@ -207,6 +207,6 @@ extern struct flow_cache_object *flow_ca +diff --git a/include/net/flow.h b/include/net/flow.h +index a094477..bc91db1 100644 +--- a/include/net/flow.h ++++ b/include/net/flow.h +@@ -207,6 +207,6 @@ extern struct flow_cache_object *flow_cache_lookup( u8 dir, flow_resolve_t resolver, void *ctx); =20 extern void flow_cache_flush(void); @@ -62051,9 +63621,10 @@ diff -urNp linux-3.1.4/include/net/flow.h linux-= 3.1.4/include/net/flow.h +extern atomic_unchecked_t flow_cache_genid; =20 #endif -diff -urNp linux-3.1.4/include/net/inetpeer.h linux-3.1.4/include/net/in= etpeer.h ---- linux-3.1.4/include/net/inetpeer.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/net/inetpeer.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/net/inetpeer.h b/include/net/inetpeer.h +index 78c83e6..db3518d 100644 +--- a/include/net/inetpeer.h ++++ b/include/net/inetpeer.h @@ -47,8 +47,8 @@ struct inet_peer { */ union { @@ -62065,7 +63636,7 @@ diff -urNp linux-3.1.4/include/net/inetpeer.h lin= ux-3.1.4/include/net/inetpeer.h __u32 tcp_ts; __u32 tcp_ts_stamp; }; -@@ -112,11 +112,11 @@ static inline int inet_getid(struct inet +@@ -112,11 +112,11 @@ static inline int inet_getid(struct inet_peer *p, = int more) more++; inet_peer_refcheck(p); do { @@ -62079,10 +63650,11 @@ diff -urNp linux-3.1.4/include/net/inetpeer.h l= inux-3.1.4/include/net/inetpeer.h return new; } =20 -diff -urNp linux-3.1.4/include/net/ip_fib.h linux-3.1.4/include/net/ip_f= ib.h ---- linux-3.1.4/include/net/ip_fib.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/ip_fib.h 2011-11-16 18:39:08.000000000 -0500 -@@ -146,7 +146,7 @@ extern __be32 fib_info_update_nh_saddr(s +diff --git a/include/net/ip_fib.h b/include/net/ip_fib.h +index 10422ef..662570f 100644 +--- a/include/net/ip_fib.h ++++ b/include/net/ip_fib.h +@@ -146,7 +146,7 @@ extern __be32 fib_info_update_nh_saddr(struct net *n= et, struct fib_nh *nh); =20 #define FIB_RES_SADDR(net, res) \ ((FIB_RES_NH(res).nh_saddr_genid =3D=3D \ @@ -62091,9 +63663,10 @@ diff -urNp linux-3.1.4/include/net/ip_fib.h linu= x-3.1.4/include/net/ip_fib.h FIB_RES_NH(res).nh_saddr : \ fib_info_update_nh_saddr((net), &FIB_RES_NH(res))) #define FIB_RES_GW(res) (FIB_RES_NH(res).nh_gw) -diff -urNp linux-3.1.4/include/net/ip_vs.h linux-3.1.4/include/net/ip_vs= .h ---- linux-3.1.4/include/net/ip_vs.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/ip_vs.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h +index 8fa4430..05dd772 100644 +--- a/include/net/ip_vs.h ++++ b/include/net/ip_vs.h @@ -509,7 +509,7 @@ struct ip_vs_conn { struct ip_vs_conn *control; /* Master control connection *= / atomic_t n_control; /* Number of controlled ones *= / @@ -62112,9 +63685,10 @@ diff -urNp linux-3.1.4/include/net/ip_vs.h linux= -3.1.4/include/net/ip_vs.h atomic_t weight; /* server weight */ =20 atomic_t refcnt; /* reference counter */ -diff -urNp linux-3.1.4/include/net/irda/ircomm_core.h linux-3.1.4/includ= e/net/irda/ircomm_core.h ---- linux-3.1.4/include/net/irda/ircomm_core.h 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/include/net/irda/ircomm_core.h 2011-11-16 18:39:08.00000= 0000 -0500 +diff --git a/include/net/irda/ircomm_core.h b/include/net/irda/ircomm_co= re.h +index 69b610a..fe3962c 100644 +--- a/include/net/irda/ircomm_core.h ++++ b/include/net/irda/ircomm_core.h @@ -51,7 +51,7 @@ typedef struct { int (*connect_response)(struct ircomm_cb *, struct sk_buff *); int (*disconnect_request)(struct ircomm_cb *, struct sk_buff *,=20 @@ -62124,9 +63698,10 @@ diff -urNp linux-3.1.4/include/net/irda/ircomm_c= ore.h linux-3.1.4/include/net/ir =20 struct ircomm_cb { irda_queue_t queue; -diff -urNp linux-3.1.4/include/net/irda/ircomm_tty.h linux-3.1.4/include= /net/irda/ircomm_tty.h ---- linux-3.1.4/include/net/irda/ircomm_tty.h 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/include/net/irda/ircomm_tty.h 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/include/net/irda/ircomm_tty.h b/include/net/irda/ircomm_tty= .h +index 59ba38bc..d515662 100644 +--- a/include/net/irda/ircomm_tty.h ++++ b/include/net/irda/ircomm_tty.h @@ -35,6 +35,7 @@ #include #include @@ -62146,9 +63721,10 @@ diff -urNp linux-3.1.4/include/net/irda/ircomm_t= ty.h linux-3.1.4/include/net/ird =20 /* Protect concurent access to : * o self->open_count -diff -urNp linux-3.1.4/include/net/iucv/af_iucv.h linux-3.1.4/include/ne= t/iucv/af_iucv.h ---- linux-3.1.4/include/net/iucv/af_iucv.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/net/iucv/af_iucv.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/include/net/iucv/af_iucv.h b/include/net/iucv/af_iucv.h +index f82a1e8..82d81e8 100644 +--- a/include/net/iucv/af_iucv.h ++++ b/include/net/iucv/af_iucv.h @@ -87,7 +87,7 @@ struct iucv_sock { struct iucv_sock_list { struct hlist_head head; @@ -62158,9 +63734,10 @@ diff -urNp linux-3.1.4/include/net/iucv/af_iucv.= h linux-3.1.4/include/net/iucv/a }; =20 unsigned int iucv_sock_poll(struct file *file, struct socket *sock, -diff -urNp linux-3.1.4/include/net/lapb.h linux-3.1.4/include/net/lapb.h ---- linux-3.1.4/include/net/lapb.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/lapb.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/net/lapb.h b/include/net/lapb.h +index 96cb5dd..25e8d4f 100644 +--- a/include/net/lapb.h ++++ b/include/net/lapb.h @@ -95,7 +95,7 @@ struct lapb_cb { struct sk_buff_head write_queue; struct sk_buff_head ack_queue; @@ -62170,9 +63747,10 @@ diff -urNp linux-3.1.4/include/net/lapb.h linux-= 3.1.4/include/net/lapb.h =20 /* FRMR control information */ struct lapb_frame frmr_data; -diff -urNp linux-3.1.4/include/net/neighbour.h linux-3.1.4/include/net/n= eighbour.h ---- linux-3.1.4/include/net/neighbour.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/net/neighbour.h 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/include/net/neighbour.h b/include/net/neighbour.h +index 2720884..3aa5c25 100644 +--- a/include/net/neighbour.h ++++ b/include/net/neighbour.h @@ -122,7 +122,7 @@ struct neigh_ops { void (*error_report)(struct neighbour *, struct sk_buff *); int (*output)(struct neighbour *, struct sk_buff *); @@ -62182,10 +63760,11 @@ diff -urNp linux-3.1.4/include/net/neighbour.h = linux-3.1.4/include/net/neighbour =20 struct pneigh_entry { struct pneigh_entry *next; -diff -urNp linux-3.1.4/include/net/netlink.h linux-3.1.4/include/net/net= link.h ---- linux-3.1.4/include/net/netlink.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/net/netlink.h 2011-11-16 18:39:08.000000000 -050= 0 -@@ -562,7 +562,7 @@ static inline void *nlmsg_get_pos(struct +diff --git a/include/net/netlink.h b/include/net/netlink.h +index 98c1854..d4add7b 100644 +--- a/include/net/netlink.h ++++ b/include/net/netlink.h +@@ -562,7 +562,7 @@ static inline void *nlmsg_get_pos(struct sk_buff *sk= b) static inline void nlmsg_trim(struct sk_buff *skb, const void *mark) { if (mark) @@ -62194,9 +63773,10 @@ diff -urNp linux-3.1.4/include/net/netlink.h lin= ux-3.1.4/include/net/netlink.h } =20 /** -diff -urNp linux-3.1.4/include/net/netns/ipv4.h linux-3.1.4/include/net/= netns/ipv4.h ---- linux-3.1.4/include/net/netns/ipv4.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/net/netns/ipv4.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/include/net/netns/ipv4.h b/include/net/netns/ipv4.h +index d786b4f..4c3dd41 100644 +--- a/include/net/netns/ipv4.h ++++ b/include/net/netns/ipv4.h @@ -56,8 +56,8 @@ struct netns_ipv4 { =20 unsigned int sysctl_ping_group_range[2]; @@ -62208,9 +63788,10 @@ diff -urNp linux-3.1.4/include/net/netns/ipv4.h = linux-3.1.4/include/net/netns/ip =20 #ifdef CONFIG_IP_MROUTE #ifndef CONFIG_IP_MROUTE_MULTIPLE_TABLES -diff -urNp linux-3.1.4/include/net/sctp/sctp.h linux-3.1.4/include/net/s= ctp/sctp.h ---- linux-3.1.4/include/net/sctp/sctp.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/net/sctp/sctp.h 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h +index 6a72a58..e6a127d 100644 +--- a/include/net/sctp/sctp.h ++++ b/include/net/sctp/sctp.h @@ -318,9 +318,9 @@ do { \ =20 #else /* SCTP_DEBUG */ @@ -62224,9 +63805,10 @@ diff -urNp linux-3.1.4/include/net/sctp/sctp.h l= inux-3.1.4/include/net/sctp/sctp #define SCTP_ENABLE_DEBUG #define SCTP_DISABLE_DEBUG #define SCTP_ASSERT(expr, str, func) -diff -urNp linux-3.1.4/include/net/sock.h linux-3.1.4/include/net/sock.h ---- linux-3.1.4/include/net/sock.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/sock.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/net/sock.h b/include/net/sock.h +index 8e4062f..77b041e 100644 +--- a/include/net/sock.h ++++ b/include/net/sock.h @@ -278,7 +278,7 @@ struct sock { #ifdef CONFIG_RPS __u32 sk_rxhash; @@ -62236,7 +63818,7 @@ diff -urNp linux-3.1.4/include/net/sock.h linux-3= .1.4/include/net/sock.h int sk_rcvbuf; =20 struct sk_filter __rcu *sk_filter; -@@ -1391,7 +1391,7 @@ static inline void sk_nocaps_add(struct=20 +@@ -1391,7 +1391,7 @@ static inline void sk_nocaps_add(struct sock *sk, = int flags) } =20 static inline int skb_do_copy_data_nocache(struct sock *sk, struct sk_b= uff *skb, @@ -62245,9 +63827,10 @@ diff -urNp linux-3.1.4/include/net/sock.h linux-= 3.1.4/include/net/sock.h int copy, int offset) { if (skb->ip_summed =3D=3D CHECKSUM_NONE) { -diff -urNp linux-3.1.4/include/net/tcp.h linux-3.1.4/include/net/tcp.h ---- linux-3.1.4/include/net/tcp.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/tcp.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/net/tcp.h b/include/net/tcp.h +index acc620a..f4d99c6 100644 +--- a/include/net/tcp.h ++++ b/include/net/tcp.h @@ -1401,8 +1401,8 @@ enum tcp_seq_states { struct tcp_seq_afinfo { char *name; @@ -62259,9 +63842,10 @@ diff -urNp linux-3.1.4/include/net/tcp.h linux-3= .1.4/include/net/tcp.h }; =20 struct tcp_iter_state { -diff -urNp linux-3.1.4/include/net/udp.h linux-3.1.4/include/net/udp.h ---- linux-3.1.4/include/net/udp.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/udp.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/net/udp.h b/include/net/udp.h +index 67ea6fc..e42aee8 100644 +--- a/include/net/udp.h ++++ b/include/net/udp.h @@ -234,8 +234,8 @@ struct udp_seq_afinfo { char *name; sa_family_t family; @@ -62273,9 +63857,10 @@ diff -urNp linux-3.1.4/include/net/udp.h linux-3= .1.4/include/net/udp.h }; =20 struct udp_iter_state { -diff -urNp linux-3.1.4/include/net/xfrm.h linux-3.1.4/include/net/xfrm.h ---- linux-3.1.4/include/net/xfrm.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/net/xfrm.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/net/xfrm.h b/include/net/xfrm.h +index b203e14..1df3991 100644 +--- a/include/net/xfrm.h ++++ b/include/net/xfrm.h @@ -505,7 +505,7 @@ struct xfrm_policy { struct timer_list timer; =20 @@ -62285,9 +63870,10 @@ diff -urNp linux-3.1.4/include/net/xfrm.h linux-= 3.1.4/include/net/xfrm.h u32 priority; u32 index; struct xfrm_mark mark; -diff -urNp linux-3.1.4/include/rdma/iw_cm.h linux-3.1.4/include/rdma/iw_= cm.h ---- linux-3.1.4/include/rdma/iw_cm.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/rdma/iw_cm.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/rdma/iw_cm.h b/include/rdma/iw_cm.h +index 2d0191c..a55797d 100644 +--- a/include/rdma/iw_cm.h ++++ b/include/rdma/iw_cm.h @@ -120,7 +120,7 @@ struct iw_cm_verbs { int backlog); =20 @@ -62297,9 +63883,10 @@ diff -urNp linux-3.1.4/include/rdma/iw_cm.h linu= x-3.1.4/include/rdma/iw_cm.h =20 /** * iw_create_cm_id - Create an IW CM identifier. -diff -urNp linux-3.1.4/include/scsi/libfc.h linux-3.1.4/include/scsi/lib= fc.h ---- linux-3.1.4/include/scsi/libfc.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/scsi/libfc.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/scsi/libfc.h b/include/scsi/libfc.h +index 7d96829..4ba78d3 100644 +--- a/include/scsi/libfc.h ++++ b/include/scsi/libfc.h @@ -758,6 +758,7 @@ struct libfc_function_template { */ void (*disc_stop_final) (struct fc_lport *); @@ -62317,9 +63904,10 @@ diff -urNp linux-3.1.4/include/scsi/libfc.h linu= x-3.1.4/include/scsi/libfc.h u8 link_up; u8 qfull; enum fc_lport_state state; -diff -urNp linux-3.1.4/include/scsi/scsi_device.h linux-3.1.4/include/sc= si/scsi_device.h ---- linux-3.1.4/include/scsi/scsi_device.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/scsi/scsi_device.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h +index d371c3c..e228a8c 100644 +--- a/include/scsi/scsi_device.h ++++ b/include/scsi/scsi_device.h @@ -161,9 +161,9 @@ struct scsi_device { unsigned int max_device_blocked; /* what device_blocked counts down fr= om */ #define SCSI_DEFAULT_DEVICE_BLOCKED 3 @@ -62333,9 +63921,10 @@ diff -urNp linux-3.1.4/include/scsi/scsi_device.= h linux-3.1.4/include/scsi/scsi_ =20 struct device sdev_gendev, sdev_dev; -diff -urNp linux-3.1.4/include/scsi/scsi_transport_fc.h linux-3.1.4/incl= ude/scsi/scsi_transport_fc.h ---- linux-3.1.4/include/scsi/scsi_transport_fc.h 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/include/scsi/scsi_transport_fc.h 2011-11-16 18:39:08.000= 000000 -0500 +diff --git a/include/scsi/scsi_transport_fc.h b/include/scsi/scsi_transp= ort_fc.h +index 2a65167..91e01f8 100644 +--- a/include/scsi/scsi_transport_fc.h ++++ b/include/scsi/scsi_transport_fc.h @@ -711,7 +711,7 @@ struct fc_function_template { unsigned long show_host_system_hostname:1; =20 @@ -62345,9 +63934,10 @@ diff -urNp linux-3.1.4/include/scsi/scsi_transpo= rt_fc.h linux-3.1.4/include/scsi =20 =20 /** -diff -urNp linux-3.1.4/include/sound/ak4xxx-adda.h linux-3.1.4/include/s= ound/ak4xxx-adda.h ---- linux-3.1.4/include/sound/ak4xxx-adda.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/include/sound/ak4xxx-adda.h 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/include/sound/ak4xxx-adda.h b/include/sound/ak4xxx-adda.h +index 030b87c..98a6954 100644 +--- a/include/sound/ak4xxx-adda.h ++++ b/include/sound/ak4xxx-adda.h @@ -35,7 +35,7 @@ struct snd_ak4xxx_ops { void (*write)(struct snd_akm4xxx *ak, int chip, unsigned char reg, unsigned char val); @@ -62357,9 +63947,10 @@ diff -urNp linux-3.1.4/include/sound/ak4xxx-adda= .h linux-3.1.4/include/sound/ak4 =20 #define AK4XXX_IMAGE_SIZE (AK4XXX_MAX_CHIPS * 16) /* 64 bytes */ =20 -diff -urNp linux-3.1.4/include/sound/hwdep.h linux-3.1.4/include/sound/h= wdep.h ---- linux-3.1.4/include/sound/hwdep.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/sound/hwdep.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/sound/hwdep.h b/include/sound/hwdep.h +index 8c05e47..2b5df97 100644 +--- a/include/sound/hwdep.h ++++ b/include/sound/hwdep.h @@ -49,7 +49,7 @@ struct snd_hwdep_ops { struct snd_hwdep_dsp_status *status); int (*dsp_load)(struct snd_hwdep *hw, @@ -62369,9 +63960,10 @@ diff -urNp linux-3.1.4/include/sound/hwdep.h lin= ux-3.1.4/include/sound/hwdep.h =20 struct snd_hwdep { struct snd_card *card; -diff -urNp linux-3.1.4/include/sound/info.h linux-3.1.4/include/sound/in= fo.h ---- linux-3.1.4/include/sound/info.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/sound/info.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/sound/info.h b/include/sound/info.h +index 4e94cf1..76748b1 100644 +--- a/include/sound/info.h ++++ b/include/sound/info.h @@ -44,7 +44,7 @@ struct snd_info_entry_text { struct snd_info_buffer *buffer); void (*write)(struct snd_info_entry *entry, @@ -62381,9 +63973,10 @@ diff -urNp linux-3.1.4/include/sound/info.h linu= x-3.1.4/include/sound/info.h =20 struct snd_info_entry_ops { int (*open)(struct snd_info_entry *entry, -diff -urNp linux-3.1.4/include/sound/pcm.h linux-3.1.4/include/sound/pcm= .h ---- linux-3.1.4/include/sound/pcm.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/sound/pcm.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/sound/pcm.h b/include/sound/pcm.h +index 57e71fa..a2c7534 100644 +--- a/include/sound/pcm.h ++++ b/include/sound/pcm.h @@ -81,6 +81,7 @@ struct snd_pcm_ops { int (*mmap)(struct snd_pcm_substream *substream, struct vm_area_struct= *vma); int (*ack)(struct snd_pcm_substream *substream); @@ -62392,9 +63985,10 @@ diff -urNp linux-3.1.4/include/sound/pcm.h linux= -3.1.4/include/sound/pcm.h =20 /* * -diff -urNp linux-3.1.4/include/sound/sb16_csp.h linux-3.1.4/include/soun= d/sb16_csp.h ---- linux-3.1.4/include/sound/sb16_csp.h 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/include/sound/sb16_csp.h 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/include/sound/sb16_csp.h b/include/sound/sb16_csp.h +index af1b49e..a5d55a5 100644 +--- a/include/sound/sb16_csp.h ++++ b/include/sound/sb16_csp.h @@ -146,7 +146,7 @@ struct snd_sb_csp_ops { int (*csp_start) (struct snd_sb_csp * p, int sample_width, int channel= s); int (*csp_stop) (struct snd_sb_csp * p); @@ -62404,9 +63998,10 @@ diff -urNp linux-3.1.4/include/sound/sb16_csp.h = linux-3.1.4/include/sound/sb16_c =20 /* * CSP private data -diff -urNp linux-3.1.4/include/sound/soc.h linux-3.1.4/include/sound/soc= .h ---- linux-3.1.4/include/sound/soc.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/include/sound/soc.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/include/sound/soc.h b/include/sound/soc.h +index aa19f5a..a5b8208 100644 +--- a/include/sound/soc.h ++++ b/include/sound/soc.h @@ -676,7 +676,7 @@ struct snd_soc_platform_driver { /* platform IO - used for platform DAPM */ unsigned int (*read)(struct snd_soc_platform *, unsigned int); @@ -62416,9 +64011,10 @@ diff -urNp linux-3.1.4/include/sound/soc.h linux= -3.1.4/include/sound/soc.h =20 struct snd_soc_platform { const char *name; -diff -urNp linux-3.1.4/include/sound/ymfpci.h linux-3.1.4/include/sound/= ymfpci.h ---- linux-3.1.4/include/sound/ymfpci.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/include/sound/ymfpci.h 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/include/sound/ymfpci.h b/include/sound/ymfpci.h +index 444cd6b..3327cc5 100644 +--- a/include/sound/ymfpci.h ++++ b/include/sound/ymfpci.h @@ -358,7 +358,7 @@ struct snd_ymfpci { spinlock_t reg_lock; spinlock_t voice_lock; @@ -62428,9 +64024,10 @@ diff -urNp linux-3.1.4/include/sound/ymfpci.h li= nux-3.1.4/include/sound/ymfpci.h struct snd_info_entry *proc_entry; const struct firmware *dsp_microcode; const struct firmware *controller_microcode; -diff -urNp linux-3.1.4/include/target/target_core_base.h linux-3.1.4/inc= lude/target/target_core_base.h ---- linux-3.1.4/include/target/target_core_base.h 2011-11-11 15:19:27.00= 0000000 -0500 -+++ linux-3.1.4/include/target/target_core_base.h 2011-11-16 18:39:08.00= 0000000 -0500 +diff --git a/include/target/target_core_base.h b/include/target/target_c= ore_base.h +index 2704065..e10f3ef 100644 +--- a/include/target/target_core_base.h ++++ b/include/target/target_core_base.h @@ -356,7 +356,7 @@ struct t10_reservation_ops { int (*t10_seq_non_holder)(struct se_cmd *, unsigned char *, u32); int (*t10_pr_register)(struct se_cmd *); @@ -62460,9 +64057,10 @@ diff -urNp linux-3.1.4/include/target/target_cor= e_base.h linux-3.1.4/include/tar atomic_t dev_tur_active; atomic_t execute_tasks; atomic_t dev_status_thr_count; -diff -urNp linux-3.1.4/include/trace/events/irq.h linux-3.1.4/include/tr= ace/events/irq.h ---- linux-3.1.4/include/trace/events/irq.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/include/trace/events/irq.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/include/trace/events/irq.h b/include/trace/events/irq.h +index 1c09820..7f5ec79 100644 +--- a/include/trace/events/irq.h ++++ b/include/trace/events/irq.h @@ -36,7 +36,7 @@ struct softirq_action; */ TRACE_EVENT(irq_handler_entry, @@ -62481,9 +64079,10 @@ diff -urNp linux-3.1.4/include/trace/events/irq.= h linux-3.1.4/include/trace/even =20 TP_ARGS(irq, action, ret), =20 -diff -urNp linux-3.1.4/include/video/udlfb.h linux-3.1.4/include/video/u= dlfb.h ---- linux-3.1.4/include/video/udlfb.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/include/video/udlfb.h 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/include/video/udlfb.h b/include/video/udlfb.h +index 69d485a..dd0bee7 100644 +--- a/include/video/udlfb.h ++++ b/include/video/udlfb.h @@ -51,10 +51,10 @@ struct dlfb_data { int base8; u32 pseudo_palette[256]; @@ -62499,9 +64098,10 @@ diff -urNp linux-3.1.4/include/video/udlfb.h lin= ux-3.1.4/include/video/udlfb.h }; =20 #define NR_USB_REQUEST_I2C_SUB_IO 0x02 -diff -urNp linux-3.1.4/include/video/uvesafb.h linux-3.1.4/include/video= /uvesafb.h ---- linux-3.1.4/include/video/uvesafb.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/include/video/uvesafb.h 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/include/video/uvesafb.h b/include/video/uvesafb.h +index 0993a22..32ba2fe 100644 +--- a/include/video/uvesafb.h ++++ b/include/video/uvesafb.h @@ -177,6 +177,7 @@ struct uvesafb_par { u8 ypan; /* 0 - nothing, 1 - ypan, 2 - ywrap */ u8 pmi_setpal; /* PMI for palette changes */ @@ -62510,10 +64110,24 @@ diff -urNp linux-3.1.4/include/video/uvesafb.h = linux-3.1.4/include/video/uvesafb void *pmi_start; void *pmi_pal; u8 *vbe_state_orig; /* -diff -urNp linux-3.1.4/init/do_mounts.c linux-3.1.4/init/do_mounts.c ---- linux-3.1.4/init/do_mounts.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/init/do_mounts.c 2011-11-16 18:39:08.000000000 -0500 -@@ -287,11 +287,11 @@ static void __init get_fs_names(char *pa +diff --git a/init/Kconfig b/init/Kconfig +index d627783..693a9f3 100644 +--- a/init/Kconfig ++++ b/init/Kconfig +@@ -1202,7 +1202,7 @@ config SLUB_DEBUG +=20 + config COMPAT_BRK + bool "Disable heap randomization" +- default y ++ default n + help + Randomizing heap placement makes heap exploits harder, but it + also breaks ancient binaries (including anything libc5 based). +diff --git a/init/do_mounts.c b/init/do_mounts.c +index c0851a8..4f8977d 100644 +--- a/init/do_mounts.c ++++ b/init/do_mounts.c +@@ -287,11 +287,11 @@ static void __init get_fs_names(char *page) =20 static int __init do_mount_root(char *name, char *fs, int flags, void *= data) { @@ -62527,7 +64141,7 @@ diff -urNp linux-3.1.4/init/do_mounts.c linux-3.1= .4/init/do_mounts.c ROOT_DEV =3D current->fs->pwd.mnt->mnt_sb->s_dev; printk(KERN_INFO "VFS: Mounted root (%s filesystem)%s on device %u:%u.\n", -@@ -383,18 +383,18 @@ void __init change_floppy(char *fmt, ... +@@ -383,18 +383,18 @@ void __init change_floppy(char *fmt, ...) va_start(args, fmt); vsprintf(buf, fmt, args); va_end(args); @@ -62558,9 +64172,10 @@ diff -urNp linux-3.1.4/init/do_mounts.c linux-3.= 1.4/init/do_mounts.c + sys_mount((char __force_user *)".", (char __force_user *)"/", NULL, MS= _MOVE, NULL); + sys_chroot((const char __force_user *)"."); } -diff -urNp linux-3.1.4/init/do_mounts.h linux-3.1.4/init/do_mounts.h ---- linux-3.1.4/init/do_mounts.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/init/do_mounts.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/init/do_mounts.h b/init/do_mounts.h +index f5b978a..69dbfe8 100644 +--- a/init/do_mounts.h ++++ b/init/do_mounts.h @@ -15,15 +15,15 @@ extern int root_mountflags; =20 static inline int create_dev(char *name, dev_t dev) @@ -62589,9 +64204,10 @@ diff -urNp linux-3.1.4/init/do_mounts.h linux-3.= 1.4/init/do_mounts.h return 0; if (!S_ISBLK(stat.st_mode)) return 0; -diff -urNp linux-3.1.4/init/do_mounts_initrd.c linux-3.1.4/init/do_mount= s_initrd.c ---- linux-3.1.4/init/do_mounts_initrd.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/init/do_mounts_initrd.c 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/init/do_mounts_initrd.c b/init/do_mounts_initrd.c +index 3098a38..253064e 100644 +--- a/init/do_mounts_initrd.c ++++ b/init/do_mounts_initrd.c @@ -44,13 +44,13 @@ static void __init handle_initrd(void) create_dev("/dev/root.old", Root_RAM0); /* mount initrd on rootfs' /root */ @@ -62666,9 +64282,10 @@ diff -urNp linux-3.1.4/init/do_mounts_initrd.c l= inux-3.1.4/init/do_mounts_initrd + sys_unlink((const char __force_user *)"/initrd.image"); return 0; } -diff -urNp linux-3.1.4/init/do_mounts_md.c linux-3.1.4/init/do_mounts_md= .c ---- linux-3.1.4/init/do_mounts_md.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/init/do_mounts_md.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/init/do_mounts_md.c b/init/do_mounts_md.c +index 32c4799..c27ee74 100644 +--- a/init/do_mounts_md.c ++++ b/init/do_mounts_md.c @@ -170,7 +170,7 @@ static void __init md_setup_drive(void) partitioned ? "_d" : "", minor, md_setup_args[ent].device_names); @@ -62696,9 +64313,10 @@ diff -urNp linux-3.1.4/init/do_mounts_md.c linux= -3.1.4/init/do_mounts_md.c if (fd >=3D 0) { sys_ioctl(fd, RAID_AUTORUN, raid_autopart); sys_close(fd); -diff -urNp linux-3.1.4/init/initramfs.c linux-3.1.4/init/initramfs.c ---- linux-3.1.4/init/initramfs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/init/initramfs.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/init/initramfs.c b/init/initramfs.c +index 2531811..040d4d4 100644 +--- a/init/initramfs.c ++++ b/init/initramfs.c @@ -74,7 +74,7 @@ static void __init free_hash(void) } } @@ -62726,7 +64344,7 @@ diff -urNp linux-3.1.4/init/initramfs.c linux-3.1= .4/init/initramfs.c } return 0; } -@@ -280,11 +280,11 @@ static void __init clean_path(char *path +@@ -280,11 +280,11 @@ static void __init clean_path(char *path, mode_t m= ode) { struct stat st; =20 @@ -62807,22 +64425,11 @@ diff -urNp linux-3.1.4/init/initramfs.c linux-3= .1.4/init/initramfs.c state =3D SkipIt; next_state =3D Reset; return 0; -diff -urNp linux-3.1.4/init/Kconfig linux-3.1.4/init/Kconfig ---- linux-3.1.4/init/Kconfig 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/init/Kconfig 2011-11-16 18:39:08.000000000 -0500 -@@ -1202,7 +1202,7 @@ config SLUB_DEBUG -=20 - config COMPAT_BRK - bool "Disable heap randomization" -- default y -+ default n - help - Randomizing heap placement makes heap exploits harder, but it - also breaks ancient binaries (including anything libc5 based). -diff -urNp linux-3.1.4/init/main.c linux-3.1.4/init/main.c ---- linux-3.1.4/init/main.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/init/main.c 2011-11-16 18:40:44.000000000 -0500 -@@ -96,6 +96,8 @@ static inline void mark_rodata_ro(void)=20 +diff --git a/init/main.c b/init/main.c +index 03b408d..5777f59 100644 +--- a/init/main.c ++++ b/init/main.c +@@ -96,6 +96,8 @@ static inline void mark_rodata_ro(void) { } extern void tc_init(void); #endif =20 @@ -62831,7 +64438,7 @@ diff -urNp linux-3.1.4/init/main.c linux-3.1.4/in= it/main.c /* * Debug helper: via this flag we know that we are in 'early bootup cod= e' * where only the boot processor is running with IRQ disabled. This me= ans -@@ -149,6 +151,49 @@ static int __init set_reset_devices(char +@@ -149,6 +151,49 @@ static int __init set_reset_devices(char *str) =20 __setup("reset_devices", set_reset_devices); =20 @@ -62881,7 +64488,7 @@ diff -urNp linux-3.1.4/init/main.c linux-3.1.4/in= it/main.c static const char * argv_init[MAX_INIT_ARGS+2] =3D { "init", NULL, }; const char * envp_init[MAX_INIT_ENVS+2] =3D { "HOME=3D/", "TERM=3Dlinux= ", NULL, }; static const char *panic_later, *panic_param; -@@ -678,6 +723,7 @@ int __init_or_module do_one_initcall(ini +@@ -678,6 +723,7 @@ int __init_or_module do_one_initcall(initcall_t fn) { int count =3D preempt_count(); int ret; @@ -62889,7 +64496,7 @@ diff -urNp linux-3.1.4/init/main.c linux-3.1.4/in= it/main.c =20 if (initcall_debug) ret =3D do_one_initcall_debug(fn); -@@ -690,15 +736,15 @@ int __init_or_module do_one_initcall(ini +@@ -690,15 +736,15 @@ int __init_or_module do_one_initcall(initcall_t fn= ) sprintf(msgbuf, "error code %d ", ret); =20 if (preempt_count() !=3D count) { @@ -62909,7 +64516,7 @@ diff -urNp linux-3.1.4/init/main.c linux-3.1.4/in= it/main.c } =20 return ret; -@@ -817,7 +863,7 @@ static int __init kernel_init(void * unu +@@ -817,7 +863,7 @@ static int __init kernel_init(void * unused) do_basic_setup(); =20 /* Open the /dev/console on the rootfs, this should never fail */ @@ -62918,7 +64525,7 @@ diff -urNp linux-3.1.4/init/main.c linux-3.1.4/in= it/main.c printk(KERN_WARNING "Warning: unable to open an initial console.\n"); =20 (void) sys_dup(0); -@@ -830,11 +876,13 @@ static int __init kernel_init(void * unu +@@ -830,11 +876,13 @@ static int __init kernel_init(void * unused) if (!ramdisk_execute_command) ramdisk_execute_command =3D "/init"; =20 @@ -62933,10 +64540,11 @@ diff -urNp linux-3.1.4/init/main.c linux-3.1.4/= init/main.c /* * Ok, we have completed the initial bootup, and * we're essentially up and running. Get rid of the -diff -urNp linux-3.1.4/ipc/mqueue.c linux-3.1.4/ipc/mqueue.c ---- linux-3.1.4/ipc/mqueue.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/ipc/mqueue.c 2011-11-16 18:40:44.000000000 -0500 -@@ -156,6 +156,7 @@ static struct inode *mqueue_get_inode(st +diff --git a/ipc/mqueue.c b/ipc/mqueue.c +index ed049ea..6442f7f 100644 +--- a/ipc/mqueue.c ++++ b/ipc/mqueue.c +@@ -156,6 +156,7 @@ static struct inode *mqueue_get_inode(struct super_b= lock *sb, mq_bytes =3D (mq_msg_tblsz + (info->attr.mq_maxmsg * info->attr.mq_msgsize)); =20 @@ -62944,10 +64552,11 @@ diff -urNp linux-3.1.4/ipc/mqueue.c linux-3.1.4= /ipc/mqueue.c spin_lock(&mq_lock); if (u->mq_bytes + mq_bytes < u->mq_bytes || u->mq_bytes + mq_bytes > task_rlimit(p, RLIMIT_MSGQUEUE)) { -diff -urNp linux-3.1.4/ipc/msg.c linux-3.1.4/ipc/msg.c ---- linux-3.1.4/ipc/msg.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/ipc/msg.c 2011-11-16 18:39:08.000000000 -0500 -@@ -309,18 +309,19 @@ static inline int msg_security(struct ke +diff --git a/ipc/msg.c b/ipc/msg.c +index 7385de2..a8180e0 100644 +--- a/ipc/msg.c ++++ b/ipc/msg.c +@@ -309,18 +309,19 @@ static inline int msg_security(struct kern_ipc_per= m *ipcp, int msgflg) return security_msg_queue_associate(msq, msgflg); } =20 @@ -62972,10 +64581,11 @@ diff -urNp linux-3.1.4/ipc/msg.c linux-3.1.4/ip= c/msg.c msg_params.key =3D key; msg_params.flg =3D msgflg; =20 -diff -urNp linux-3.1.4/ipc/sem.c linux-3.1.4/ipc/sem.c ---- linux-3.1.4/ipc/sem.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/ipc/sem.c 2011-11-16 18:40:44.000000000 -0500 -@@ -318,10 +318,15 @@ static inline int sem_more_checks(struct +diff --git a/ipc/sem.c b/ipc/sem.c +index c8e00f8..1135c4e 100644 +--- a/ipc/sem.c ++++ b/ipc/sem.c +@@ -318,10 +318,15 @@ static inline int sem_more_checks(struct kern_ipc_= perm *ipcp, return 0; } =20 @@ -62992,7 +64602,7 @@ diff -urNp linux-3.1.4/ipc/sem.c linux-3.1.4/ipc/= sem.c struct ipc_params sem_params; =20 ns =3D current->nsproxy->ipc_ns; -@@ -329,10 +334,6 @@ SYSCALL_DEFINE3(semget, key_t, key, int, +@@ -329,10 +334,6 @@ SYSCALL_DEFINE3(semget, key_t, key, int, nsems, int= , semflg) if (nsems < 0 || nsems > ns->sc_semmsl) return -EINVAL; =20 @@ -63003,7 +64613,7 @@ diff -urNp linux-3.1.4/ipc/sem.c linux-3.1.4/ipc/= sem.c sem_params.key =3D key; sem_params.flg =3D semflg; sem_params.u.nsems =3D nsems; -@@ -848,6 +849,8 @@ static int semctl_main(struct ipc_namesp +@@ -848,6 +849,8 @@ static int semctl_main(struct ipc_namespace *ns, int= semid, int semnum, int nsems; struct list_head tasks; =20 @@ -63012,7 +64622,7 @@ diff -urNp linux-3.1.4/ipc/sem.c linux-3.1.4/ipc/= sem.c sma =3D sem_lock_check(ns, semid); if (IS_ERR(sma)) return PTR_ERR(sma); -@@ -1295,6 +1298,8 @@ SYSCALL_DEFINE4(semtimedop, int, semid,=20 +@@ -1295,6 +1298,8 @@ SYSCALL_DEFINE4(semtimedop, int, semid, struct sem= buf __user *, tsops, struct ipc_namespace *ns; struct list_head tasks; =20 @@ -63021,10 +64631,11 @@ diff -urNp linux-3.1.4/ipc/sem.c linux-3.1.4/ip= c/sem.c ns =3D current->nsproxy->ipc_ns; =20 if (nsops < 1 || semid < 0) -diff -urNp linux-3.1.4/ipc/shm.c linux-3.1.4/ipc/shm.c ---- linux-3.1.4/ipc/shm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/ipc/shm.c 2011-11-16 18:40:44.000000000 -0500 -@@ -69,6 +69,14 @@ static void shm_destroy (struct ipc_name +diff --git a/ipc/shm.c b/ipc/shm.c +index 02ecf2c..c8f5627 100644 +--- a/ipc/shm.c ++++ b/ipc/shm.c +@@ -69,6 +69,14 @@ static void shm_destroy (struct ipc_namespace *ns, st= ruct shmid_kernel *shp); static int sysvipc_shm_proc_show(struct seq_file *s, void *it); #endif =20 @@ -63039,7 +64650,7 @@ diff -urNp linux-3.1.4/ipc/shm.c linux-3.1.4/ipc/= shm.c void shm_init_ns(struct ipc_namespace *ns) { ns->shm_ctlmax =3D SHMMAX; -@@ -508,6 +516,14 @@ static int newseg(struct ipc_namespace * +@@ -508,6 +516,14 @@ static int newseg(struct ipc_namespace *ns, struct = ipc_params *params) shp->shm_lprid =3D 0; shp->shm_atim =3D shp->shm_dtim =3D 0; shp->shm_ctim =3D get_seconds(); @@ -63054,7 +64665,7 @@ diff -urNp linux-3.1.4/ipc/shm.c linux-3.1.4/ipc/= shm.c shp->shm_segsz =3D size; shp->shm_nattch =3D 0; shp->shm_file =3D file; -@@ -559,18 +575,19 @@ static inline int shm_more_checks(struct +@@ -559,18 +575,19 @@ static inline int shm_more_checks(struct kern_ipc_= perm *ipcp, return 0; } =20 @@ -63079,7 +64690,7 @@ diff -urNp linux-3.1.4/ipc/shm.c linux-3.1.4/ipc/= shm.c shm_params.key =3D key; shm_params.flg =3D shmflg; shm_params.u.size =3D size; -@@ -870,8 +887,6 @@ SYSCALL_DEFINE3(shmctl, int, shmid, int, +@@ -870,8 +887,6 @@ SYSCALL_DEFINE3(shmctl, int, shmid, int, cmd, struct= shmid_ds __user *, buf) case SHM_LOCK: case SHM_UNLOCK: { @@ -63088,7 +64699,7 @@ diff -urNp linux-3.1.4/ipc/shm.c linux-3.1.4/ipc/= shm.c lru_add_drain_all(); /* drain pagevecs to lru lists */ =20 shp =3D shm_lock_check(ns, shmid); -@@ -1004,9 +1019,21 @@ long do_shmat(int shmid, char __user *sh +@@ -1004,9 +1019,21 @@ long do_shmat(int shmid, char __user *shmaddr, in= t shmflg, ulong *raddr) if (err) goto out_unlock; =20 @@ -63110,10 +64721,11 @@ diff -urNp linux-3.1.4/ipc/shm.c linux-3.1.4/ip= c/shm.c size =3D i_size_read(path.dentry->d_inode); shm_unlock(shp); =20 -diff -urNp linux-3.1.4/kernel/acct.c linux-3.1.4/kernel/acct.c ---- linux-3.1.4/kernel/acct.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/acct.c 2011-11-16 18:39:08.000000000 -0500 -@@ -570,7 +570,7 @@ static void do_acct_process(struct bsd_a +diff --git a/kernel/acct.c b/kernel/acct.c +index fa7eb3d..7faf116 100644 +--- a/kernel/acct.c ++++ b/kernel/acct.c +@@ -570,7 +570,7 @@ static void do_acct_process(struct bsd_acct_struct *= acct, */ flim =3D current->signal->rlim[RLIMIT_FSIZE].rlim_cur; current->signal->rlim[RLIMIT_FSIZE].rlim_cur =3D RLIM_INFINITY; @@ -63122,9 +64734,10 @@ diff -urNp linux-3.1.4/kernel/acct.c linux-3.1.4= /kernel/acct.c sizeof(acct_t), &file->f_pos); current->signal->rlim[RLIMIT_FSIZE].rlim_cur =3D flim; set_fs(fs); -diff -urNp linux-3.1.4/kernel/audit.c linux-3.1.4/kernel/audit.c ---- linux-3.1.4/kernel/audit.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/audit.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/audit.c b/kernel/audit.c +index 0a1355c..dca420f 100644 +--- a/kernel/audit.c ++++ b/kernel/audit.c @@ -115,7 +115,7 @@ u32 audit_sig_sid =3D 0; 3) suppressed due to audit_rate_limit 4) suppressed due to audit_backlog_limit @@ -63152,7 +64765,7 @@ diff -urNp linux-3.1.4/kernel/audit.c linux-3.1.4= /kernel/audit.c audit_rate_limit, audit_backlog_limit); audit_panic(message); -@@ -689,7 +689,7 @@ static int audit_receive_msg(struct sk_b +@@ -689,7 +689,7 @@ static int audit_receive_msg(struct sk_buff *skb, st= ruct nlmsghdr *nlh) status_set.pid =3D audit_pid; status_set.rate_limit =3D audit_rate_limit; status_set.backlog_limit =3D audit_backlog_limit; @@ -63161,10 +64774,11 @@ diff -urNp linux-3.1.4/kernel/audit.c linux-3.1= .4/kernel/audit.c status_set.backlog =3D skb_queue_len(&audit_skb_queue); audit_send_reply(NETLINK_CB(skb).pid, seq, AUDIT_GET, 0, 0, &status_set, sizeof(status_set)); -diff -urNp linux-3.1.4/kernel/auditsc.c linux-3.1.4/kernel/auditsc.c ---- linux-3.1.4/kernel/auditsc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/auditsc.c 2011-11-16 18:39:08.000000000 -0500 -@@ -2118,7 +2118,7 @@ int auditsc_get_stamp(struct audit_conte +diff --git a/kernel/auditsc.c b/kernel/auditsc.c +index ce4b054..8139ed7 100644 +--- a/kernel/auditsc.c ++++ b/kernel/auditsc.c +@@ -2118,7 +2118,7 @@ int auditsc_get_stamp(struct audit_context *ctx, } =20 /* global counter which is incremented every time something logs in */ @@ -63173,7 +64787,7 @@ diff -urNp linux-3.1.4/kernel/auditsc.c linux-3.1= .4/kernel/auditsc.c =20 /** * audit_set_loginuid - set a task's audit_context loginuid -@@ -2131,7 +2131,7 @@ static atomic_t session_id =3D ATOMIC_INIT +@@ -2131,7 +2131,7 @@ static atomic_t session_id =3D ATOMIC_INIT(0); */ int audit_set_loginuid(struct task_struct *task, uid_t loginuid) { @@ -63182,10 +64796,11 @@ diff -urNp linux-3.1.4/kernel/auditsc.c linux-3= .1.4/kernel/auditsc.c struct audit_context *context =3D task->audit_context; =20 if (context && context->in_syscall) { -diff -urNp linux-3.1.4/kernel/capability.c linux-3.1.4/kernel/capability= .c ---- linux-3.1.4/kernel/capability.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/capability.c 2011-11-16 18:40:44.000000000 -0500 -@@ -202,6 +202,9 @@ SYSCALL_DEFINE2(capget, cap_user_header_ +diff --git a/kernel/capability.c b/kernel/capability.c +index 283c529..36ac81e 100644 +--- a/kernel/capability.c ++++ b/kernel/capability.c +@@ -202,6 +202,9 @@ SYSCALL_DEFINE2(capget, cap_user_header_t, header, c= ap_user_data_t, dataptr) * before modification is attempted and the application * fails. */ @@ -63195,7 +64810,7 @@ diff -urNp linux-3.1.4/kernel/capability.c linux-= 3.1.4/kernel/capability.c if (copy_to_user(dataptr, kdata, tocopy * sizeof(struct __user_cap_data_struct))) { return -EFAULT; -@@ -374,7 +377,7 @@ bool ns_capable(struct user_namespace *n +@@ -374,7 +377,7 @@ bool ns_capable(struct user_namespace *ns, int cap) BUG(); } =20 @@ -63204,7 +64819,7 @@ diff -urNp linux-3.1.4/kernel/capability.c linux-= 3.1.4/kernel/capability.c current->flags |=3D PF_SUPERPRIV; return true; } -@@ -382,6 +385,27 @@ bool ns_capable(struct user_namespace *n +@@ -382,6 +385,27 @@ bool ns_capable(struct user_namespace *ns, int cap) } EXPORT_SYMBOL(ns_capable); =20 @@ -63232,7 +64847,7 @@ diff -urNp linux-3.1.4/kernel/capability.c linux-= 3.1.4/kernel/capability.c /** * task_ns_capable - Determine whether current task has a superior * capability targeted at a specific task's user namespace. -@@ -396,6 +420,12 @@ bool task_ns_capable(struct task_struct=20 +@@ -396,6 +420,12 @@ bool task_ns_capable(struct task_struct *t, int cap= ) } EXPORT_SYMBOL(task_ns_capable); =20 @@ -63245,9 +64860,10 @@ diff -urNp linux-3.1.4/kernel/capability.c linux= -3.1.4/kernel/capability.c /** * nsown_capable - Check superior capability to one's own user_ns * @cap: The capability in question -diff -urNp linux-3.1.4/kernel/cgroup.c linux-3.1.4/kernel/cgroup.c ---- linux-3.1.4/kernel/cgroup.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/cgroup.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/cgroup.c b/kernel/cgroup.c +index 1d2b6ce..87bf267 100644 +--- a/kernel/cgroup.c ++++ b/kernel/cgroup.c @@ -595,6 +595,8 @@ static struct css_set *find_css_set( struct hlist_head *hhead; struct cg_cgroup_link *link; @@ -63257,9 +64873,10 @@ diff -urNp linux-3.1.4/kernel/cgroup.c linux-3.1= .4/kernel/cgroup.c /* First see if we already have a cgroup group that matches * the desired set */ read_lock(&css_set_lock); -diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.4/kernel/compat.c ---- linux-3.1.4/kernel/compat.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/compat.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/compat.c b/kernel/compat.c +index e2435ee..8e82199 100644 +--- a/kernel/compat.c ++++ b/kernel/compat.c @@ -13,6 +13,7 @@ =20 #include @@ -63268,7 +64885,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c #include #include #include -@@ -167,7 +168,7 @@ static long compat_nanosleep_restart(str +@@ -167,7 +168,7 @@ static long compat_nanosleep_restart(struct restart_= block *restart) mm_segment_t oldfs; long ret; =20 @@ -63277,7 +64894,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c oldfs =3D get_fs(); set_fs(KERNEL_DS); ret =3D hrtimer_nanosleep_restart(restart); -@@ -199,7 +200,7 @@ asmlinkage long compat_sys_nanosleep(str +@@ -199,7 +200,7 @@ asmlinkage long compat_sys_nanosleep(struct compat_t= imespec __user *rqtp, oldfs =3D get_fs(); set_fs(KERNEL_DS); ret =3D hrtimer_nanosleep(&tu, @@ -63286,7 +64903,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c HRTIMER_MODE_REL, CLOCK_MONOTONIC); set_fs(oldfs); =20 -@@ -308,7 +309,7 @@ asmlinkage long compat_sys_sigpending(co +@@ -308,7 +309,7 @@ asmlinkage long compat_sys_sigpending(compat_old_sig= set_t __user *set) mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -63295,7 +64912,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(old_fs); if (ret =3D=3D 0) ret =3D put_user(s, set); -@@ -331,8 +332,8 @@ asmlinkage long compat_sys_sigprocmask(i +@@ -331,8 +332,8 @@ asmlinkage long compat_sys_sigprocmask(int how, comp= at_old_sigset_t __user *set, old_fs =3D get_fs(); set_fs(KERNEL_DS); ret =3D sys_sigprocmask(how, @@ -63306,7 +64923,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(old_fs); if (ret =3D=3D 0) if (oset) -@@ -369,7 +370,7 @@ asmlinkage long compat_sys_old_getrlimit +@@ -369,7 +370,7 @@ asmlinkage long compat_sys_old_getrlimit(unsigned in= t resource, mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -63315,7 +64932,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(old_fs); =20 if (!ret) { -@@ -441,7 +442,7 @@ asmlinkage long compat_sys_getrusage(int +@@ -441,7 +442,7 @@ asmlinkage long compat_sys_getrusage(int who, struct= compat_rusage __user *ru) mm_segment_t old_fs =3D get_fs(); =20 set_fs(KERNEL_DS); @@ -63324,7 +64941,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(old_fs); =20 if (ret) -@@ -468,8 +469,8 @@ compat_sys_wait4(compat_pid_t pid, compa +@@ -468,8 +469,8 @@ compat_sys_wait4(compat_pid_t pid, compat_uint_t __u= ser *stat_addr, int options, set_fs (KERNEL_DS); ret =3D sys_wait4(pid, (stat_addr ? @@ -63335,7 +64952,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs (old_fs); =20 if (ret > 0) { -@@ -494,8 +495,8 @@ asmlinkage long compat_sys_waitid(int wh +@@ -494,8 +495,8 @@ asmlinkage long compat_sys_waitid(int which, compat_= pid_t pid, memset(&info, 0, sizeof(info)); =20 set_fs(KERNEL_DS); @@ -63346,7 +64963,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(old_fs); =20 if ((ret < 0) || (info.si_signo =3D=3D 0)) -@@ -625,8 +626,8 @@ long compat_sys_timer_settime(timer_t ti +@@ -625,8 +626,8 @@ long compat_sys_timer_settime(timer_t timer_id, int = flags, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_timer_settime(timer_id, flags, @@ -63357,7 +64974,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(oldfs); if (!err && old && put_compat_itimerspec(old, &oldts)) return -EFAULT; -@@ -643,7 +644,7 @@ long compat_sys_timer_gettime(timer_t ti +@@ -643,7 +644,7 @@ long compat_sys_timer_gettime(timer_t timer_id, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_timer_gettime(timer_id, @@ -63366,7 +64983,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(oldfs); if (!err && put_compat_itimerspec(setting, &ts)) return -EFAULT; -@@ -662,7 +663,7 @@ long compat_sys_clock_settime(clockid_t=20 +@@ -662,7 +663,7 @@ long compat_sys_clock_settime(clockid_t which_clock, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_settime(which_clock, @@ -63375,7 +64992,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(oldfs); return err; } -@@ -677,7 +678,7 @@ long compat_sys_clock_gettime(clockid_t=20 +@@ -677,7 +678,7 @@ long compat_sys_clock_gettime(clockid_t which_clock, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_gettime(which_clock, @@ -63384,7 +65001,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(oldfs); if (!err && put_compat_timespec(&ts, tp)) return -EFAULT; -@@ -697,7 +698,7 @@ long compat_sys_clock_adjtime(clockid_t=20 +@@ -697,7 +698,7 @@ long compat_sys_clock_adjtime(clockid_t which_clock, =20 oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -63393,7 +65010,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(oldfs); =20 err =3D compat_put_timex(utp, &txc); -@@ -717,7 +718,7 @@ long compat_sys_clock_getres(clockid_t w +@@ -717,7 +718,7 @@ long compat_sys_clock_getres(clockid_t which_clock, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_getres(which_clock, @@ -63402,7 +65019,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c set_fs(oldfs); if (!err && tp && put_compat_timespec(&ts, tp)) return -EFAULT; -@@ -729,9 +730,9 @@ static long compat_clock_nanosleep_resta +@@ -729,9 +730,9 @@ static long compat_clock_nanosleep_restart(struct re= start_block *restart) long err; mm_segment_t oldfs; struct timespec tu; @@ -63414,7 +65031,7 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1.= 4/kernel/compat.c oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D clock_nanosleep_restart(restart); -@@ -763,8 +764,8 @@ long compat_sys_clock_nanosleep(clockid_ +@@ -763,8 +764,8 @@ long compat_sys_clock_nanosleep(clockid_t which_cloc= k, int flags, oldfs =3D get_fs(); set_fs(KERNEL_DS); err =3D sys_clock_nanosleep(which_clock, flags, @@ -63425,9 +65042,10 @@ diff -urNp linux-3.1.4/kernel/compat.c linux-3.1= .4/kernel/compat.c set_fs(oldfs); =20 if ((err =3D=3D -ERESTART_RESTARTBLOCK) && rmtp && -diff -urNp linux-3.1.4/kernel/configs.c linux-3.1.4/kernel/configs.c ---- linux-3.1.4/kernel/configs.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/configs.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/configs.c b/kernel/configs.c +index 42e8fa0..9e7406b 100644 +--- a/kernel/configs.c ++++ b/kernel/configs.c @@ -74,8 +74,19 @@ static int __init ikconfig_init(void) struct proc_dir_entry *entry; =20 @@ -63448,10 +65066,11 @@ diff -urNp linux-3.1.4/kernel/configs.c linux-3= .1.4/kernel/configs.c if (!entry) return -ENOMEM; =20 -diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.4/kernel/cred.c ---- linux-3.1.4/kernel/cred.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/cred.c 2011-11-16 18:40:44.000000000 -0500 -@@ -158,6 +158,8 @@ static void put_cred_rcu(struct rcu_head +diff --git a/kernel/cred.c b/kernel/cred.c +index 8ef31f5..f63d997 100644 +--- a/kernel/cred.c ++++ b/kernel/cred.c +@@ -158,6 +158,8 @@ static void put_cred_rcu(struct rcu_head *rcu) */ void __put_cred(struct cred *cred) { @@ -63469,7 +65088,7 @@ diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.4/= kernel/cred.c kdebug("exit_creds(%u,%p,%p,{%d,%d})", tsk->pid, tsk->real_cred, tsk->= cred, atomic_read(&tsk->cred->usage), read_cred_subscribers(tsk->cred)); -@@ -220,6 +224,8 @@ const struct cred *get_task_cred(struct=20 +@@ -220,6 +224,8 @@ const struct cred *get_task_cred(struct task_struct = *task) { const struct cred *cred; =20 @@ -63505,7 +65124,7 @@ diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.4/= kernel/cred.c #ifdef CONFIG_KEYS tgcred =3D kmalloc(sizeof(*tgcred), GFP_KERNEL); if (!tgcred) -@@ -385,6 +397,8 @@ int copy_creds(struct task_struct *p, un +@@ -385,6 +397,8 @@ int copy_creds(struct task_struct *p, unsigned long = clone_flags) struct cred *new; int ret; =20 @@ -63541,7 +65160,7 @@ diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.4/= kernel/cred.c kdebug("abort_creds(%p{%d,%d})", new, atomic_read(&new->usage), read_cred_subscribers(new)); -@@ -572,6 +592,8 @@ const struct cred *override_creds(const=20 +@@ -572,6 +592,8 @@ const struct cred *override_creds(const struct cred = *new) { const struct cred *old =3D current->cred; =20 @@ -63550,7 +65169,7 @@ diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.4/= kernel/cred.c kdebug("override_creds(%p{%d,%d})", new, atomic_read(&new->usage), read_cred_subscribers(new)); -@@ -601,6 +623,8 @@ void revert_creds(const struct cred *old +@@ -601,6 +623,8 @@ void revert_creds(const struct cred *old) { const struct cred *override =3D current->cred; =20 @@ -63559,7 +65178,7 @@ diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.4/= kernel/cred.c kdebug("revert_creds(%p{%d,%d})", old, atomic_read(&old->usage), read_cred_subscribers(old)); -@@ -647,6 +671,8 @@ struct cred *prepare_kernel_cred(struct=20 +@@ -647,6 +671,8 @@ struct cred *prepare_kernel_cred(struct task_struct = *daemon) const struct cred *old; struct cred *new; =20 @@ -63577,7 +65196,7 @@ diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.4/= kernel/cred.c return security_kernel_act_as(new, secid); } EXPORT_SYMBOL(set_security_override); -@@ -720,6 +748,8 @@ int set_security_override_from_ctx(struc +@@ -720,6 +748,8 @@ int set_security_override_from_ctx(struct cred *new,= const char *secctx) u32 secid; int ret; =20 @@ -63586,10 +65205,11 @@ diff -urNp linux-3.1.4/kernel/cred.c linux-3.1.= 4/kernel/cred.c ret =3D security_secctx_to_secid(secctx, strlen(secctx), &secid); if (ret < 0) return ret; -diff -urNp linux-3.1.4/kernel/debug/debug_core.c linux-3.1.4/kernel/debu= g/debug_core.c ---- linux-3.1.4/kernel/debug/debug_core.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/kernel/debug/debug_core.c 2011-11-16 18:39:08.000000000 = -0500 -@@ -119,7 +119,7 @@ static DEFINE_RAW_SPINLOCK(dbg_slave_loc +diff --git a/kernel/debug/debug_core.c b/kernel/debug/debug_core.c +index 0d7c087..01b8cef 100644 +--- a/kernel/debug/debug_core.c ++++ b/kernel/debug/debug_core.c +@@ -119,7 +119,7 @@ static DEFINE_RAW_SPINLOCK(dbg_slave_lock); */ static atomic_t masters_in_kgdb; static atomic_t slaves_in_kgdb; @@ -63627,7 +65247,7 @@ diff -urNp linux-3.1.4/kernel/debug/debug_core.c = linux-3.1.4/kernel/debug/debug_ if (kgdb_info[sstep_cpu].task) kgdb_sstep_pid =3D kgdb_info[sstep_cpu].task->pid; else -@@ -834,18 +834,18 @@ static void kgdb_unregister_callbacks(vo +@@ -834,18 +834,18 @@ static void kgdb_unregister_callbacks(void) static void kgdb_tasklet_bpt(unsigned long ing) { kgdb_breakpoint(); @@ -63649,10 +65269,11 @@ diff -urNp linux-3.1.4/kernel/debug/debug_core.= c linux-3.1.4/kernel/debug/debug_ tasklet_schedule(&kgdb_tasklet_breakpoint); } EXPORT_SYMBOL_GPL(kgdb_schedule_breakpoint); -diff -urNp linux-3.1.4/kernel/debug/kdb/kdb_main.c linux-3.1.4/kernel/de= bug/kdb/kdb_main.c ---- linux-3.1.4/kernel/debug/kdb/kdb_main.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/kernel/debug/kdb/kdb_main.c 2011-11-16 18:39:08.00000000= 0 -0500 -@@ -1980,7 +1980,7 @@ static int kdb_lsmod(int argc, const cha +diff --git a/kernel/debug/kdb/kdb_main.c b/kernel/debug/kdb/kdb_main.c +index 63786e7..0780cac 100644 +--- a/kernel/debug/kdb/kdb_main.c ++++ b/kernel/debug/kdb/kdb_main.c +@@ -1980,7 +1980,7 @@ static int kdb_lsmod(int argc, const char **argv) list_for_each_entry(mod, kdb_modules, list) { =20 kdb_printf("%-20s%8u 0x%p ", mod->name, @@ -63661,7 +65282,7 @@ diff -urNp linux-3.1.4/kernel/debug/kdb/kdb_main.= c linux-3.1.4/kernel/debug/kdb/ #ifdef CONFIG_MODULE_UNLOAD kdb_printf("%4d ", module_refcount(mod)); #endif -@@ -1990,7 +1990,7 @@ static int kdb_lsmod(int argc, const cha +@@ -1990,7 +1990,7 @@ static int kdb_lsmod(int argc, const char **argv) kdb_printf(" (Loading)"); else kdb_printf(" (Live)"); @@ -63670,10 +65291,11 @@ diff -urNp linux-3.1.4/kernel/debug/kdb/kdb_mai= n.c linux-3.1.4/kernel/debug/kdb/ =20 #ifdef CONFIG_MODULE_UNLOAD { -diff -urNp linux-3.1.4/kernel/events/core.c linux-3.1.4/kernel/events/co= re.c ---- linux-3.1.4/kernel/events/core.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/events/core.c 2011-11-16 18:39:08.000000000 -0500 -@@ -172,7 +172,7 @@ int perf_proc_update_handler(struct ctl_ +diff --git a/kernel/events/core.c b/kernel/events/core.c +index 0f85778..0d43716 100644 +--- a/kernel/events/core.c ++++ b/kernel/events/core.c +@@ -172,7 +172,7 @@ int perf_proc_update_handler(struct ctl_table *table= , int write, return 0; } =20 @@ -63682,7 +65304,7 @@ diff -urNp linux-3.1.4/kernel/events/core.c linux= -3.1.4/kernel/events/core.c =20 static void cpu_ctx_sched_out(struct perf_cpu_context *cpuctx, enum event_type_t event_type); -@@ -2535,7 +2535,7 @@ static void __perf_event_read(void *info +@@ -2535,7 +2535,7 @@ static void __perf_event_read(void *info) =20 static inline u64 perf_event_count(struct perf_event *event) { @@ -63691,7 +65313,7 @@ diff -urNp linux-3.1.4/kernel/events/core.c linux= -3.1.4/kernel/events/core.c } =20 static u64 perf_event_read(struct perf_event *event) -@@ -3060,9 +3060,9 @@ u64 perf_event_read_value(struct perf_ev +@@ -3060,9 +3060,9 @@ u64 perf_event_read_value(struct perf_event *event= , u64 *enabled, u64 *running) mutex_lock(&event->child_mutex); total +=3D perf_event_read(event); *enabled +=3D event->total_time_enabled + @@ -63703,7 +65325,7 @@ diff -urNp linux-3.1.4/kernel/events/core.c linux= -3.1.4/kernel/events/core.c =20 list_for_each_entry(child, &event->child_list, child_list) { total +=3D perf_event_read(child); -@@ -3448,10 +3448,10 @@ void perf_event_update_userpage(struct p +@@ -3448,10 +3448,10 @@ void perf_event_update_userpage(struct perf_even= t *event) userpg->offset -=3D local64_read(&event->hw.prev_count); =20 userpg->time_enabled =3D enabled + @@ -63716,7 +65338,7 @@ diff -urNp linux-3.1.4/kernel/events/core.c linux= -3.1.4/kernel/events/core.c =20 barrier(); ++userpg->lock; -@@ -3822,11 +3822,11 @@ static void perf_output_read_one(struct=20 +@@ -3822,11 +3822,11 @@ static void perf_output_read_one(struct perf_out= put_handle *handle, values[n++] =3D perf_event_count(event); if (read_format & PERF_FORMAT_TOTAL_TIME_ENABLED) { values[n++] =3D enabled + @@ -63730,7 +65352,7 @@ diff -urNp linux-3.1.4/kernel/events/core.c linux= -3.1.4/kernel/events/core.c } if (read_format & PERF_FORMAT_ID) values[n++] =3D primary_event_id(event); -@@ -4477,12 +4477,12 @@ static void perf_event_mmap_event(struct +@@ -4477,12 +4477,12 @@ static void perf_event_mmap_event(struct perf_mm= ap_event *mmap_event) * need to add enough zero bytes after the string to handle * the 64bit alignment we do later. */ @@ -63745,7 +65367,7 @@ diff -urNp linux-3.1.4/kernel/events/core.c linux= -3.1.4/kernel/events/core.c if (IS_ERR(name)) { name =3D strncpy(tmp, "//toolong", sizeof(tmp)); goto got_name; -@@ -5833,7 +5833,7 @@ perf_event_alloc(struct perf_event_attr=20 +@@ -5833,7 +5833,7 @@ perf_event_alloc(struct perf_event_attr *attr, int= cpu, event->parent =3D parent_event; =20 event->ns =3D get_pid_ns(current->nsproxy->pid_ns); @@ -63754,7 +65376,7 @@ diff -urNp linux-3.1.4/kernel/events/core.c linux= -3.1.4/kernel/events/core.c =20 event->state =3D PERF_EVENT_STATE_INACTIVE; =20 -@@ -6355,10 +6355,10 @@ static void sync_child_event(struct perf +@@ -6355,10 +6355,10 @@ static void sync_child_event(struct perf_event *= child_event, /* * Add back the child's count to the parent's count: */ @@ -63768,9 +65390,10 @@ diff -urNp linux-3.1.4/kernel/events/core.c linu= x-3.1.4/kernel/events/core.c &parent_event->child_total_time_running); =20 /* -diff -urNp linux-3.1.4/kernel/exit.c linux-3.1.4/kernel/exit.c ---- linux-3.1.4/kernel/exit.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/exit.c 2011-11-16 19:33:48.000000000 -0500 +diff --git a/kernel/exit.c b/kernel/exit.c +index 2913b35..86c7364 100644 +--- a/kernel/exit.c ++++ b/kernel/exit.c @@ -57,6 +57,10 @@ #include #include @@ -63782,7 +65405,7 @@ diff -urNp linux-3.1.4/kernel/exit.c linux-3.1.4/= kernel/exit.c static void exit_mm(struct task_struct * tsk); =20 static void __unhash_process(struct task_struct *p, bool group_dead) -@@ -168,6 +172,10 @@ void release_task(struct task_struct * p +@@ -168,6 +172,10 @@ void release_task(struct task_struct * p) struct task_struct *leader; int zap_leader; repeat: @@ -63870,10 +65493,11 @@ diff -urNp linux-3.1.4/kernel/exit.c linux-3.1.= 4/kernel/exit.c exit_mm(tsk); =20 if (group_dead) -diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/kernel/fork.c ---- linux-3.1.4/kernel/fork.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/fork.c 2011-11-16 19:36:31.000000000 -0500 -@@ -285,7 +285,7 @@ static struct task_struct *dup_task_stru +diff --git a/kernel/fork.c b/kernel/fork.c +index 8e6b6f4..9dccf00 100644 +--- a/kernel/fork.c ++++ b/kernel/fork.c +@@ -285,7 +285,7 @@ static struct task_struct *dup_task_struct(struct ta= sk_struct *orig) *stackend =3D STACK_END_MAGIC; /* for overflow detection */ =20 #ifdef CONFIG_CC_STACKPROTECTOR @@ -63962,7 +65586,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c =20 down_write(&oldmm->mmap_sem); flush_cache_dup_mm(oldmm); -@@ -327,8 +391,8 @@ static int dup_mmap(struct mm_struct *mm +@@ -327,8 +391,8 @@ static int dup_mmap(struct mm_struct *mm, struct mm_= struct *oldmm) mm->locked_vm =3D 0; mm->mmap =3D NULL; mm->mmap_cache =3D NULL; @@ -63973,7 +65597,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c mm->map_count =3D 0; cpumask_clear(mm_cpumask(mm)); mm->mm_rb =3D RB_ROOT; -@@ -344,8 +408,6 @@ static int dup_mmap(struct mm_struct *mm +@@ -344,8 +408,6 @@ static int dup_mmap(struct mm_struct *mm, struct mm_= struct *oldmm) =20 prev =3D NULL; for (mpnt =3D oldmm->mmap; mpnt; mpnt =3D mpnt->vm_next) { @@ -63982,7 +65606,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c if (mpnt->vm_flags & VM_DONTCOPY) { long pages =3D vma_pages(mpnt); mm->total_vm -=3D pages; -@@ -353,55 +415,13 @@ static int dup_mmap(struct mm_struct *mm +@@ -353,55 +415,13 @@ static int dup_mmap(struct mm_struct *mm, struct m= m_struct *oldmm) -pages); continue; } @@ -64042,7 +65666,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c * Link in the new vma and copy the page table entries. */ *pprev =3D tmp; -@@ -422,6 +442,31 @@ static int dup_mmap(struct mm_struct *mm +@@ -422,6 +442,31 @@ static int dup_mmap(struct mm_struct *mm, struct mm= _struct *oldmm) if (retval) goto out; } @@ -64089,7 +65713,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c } =20 static inline int mm_alloc_pgd(struct mm_struct *mm) -@@ -837,13 +874,14 @@ static int copy_fs(unsigned long clone_f +@@ -837,13 +874,14 @@ static int copy_fs(unsigned long clone_flags, stru= ct task_struct *tsk) spin_unlock(&fs->lock); return -EAGAIN; } @@ -64105,7 +65729,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c return 0; } =20 -@@ -1105,6 +1143,9 @@ static struct task_struct *copy_process( +@@ -1105,6 +1143,9 @@ static struct task_struct *copy_process(unsigned l= ong clone_flags, DEBUG_LOCKS_WARN_ON(!p->softirqs_enabled); #endif retval =3D -EAGAIN; @@ -64115,7 +65739,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c if (atomic_read(&p->real_cred->user->processes) >=3D task_rlimit(p, RLIMIT_NPROC)) { if (!capable(CAP_SYS_ADMIN) && !capable(CAP_SYS_RESOURCE) && -@@ -1264,6 +1305,8 @@ static struct task_struct *copy_process( +@@ -1264,6 +1305,8 @@ static struct task_struct *copy_process(unsigned l= ong clone_flags, if (clone_flags & CLONE_THREAD) p->tgid =3D current->tgid; =20 @@ -64142,7 +65766,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c if (clone_flags & CLONE_VFORK) { p->vfork_done =3D &vfork; init_completion(&vfork); -@@ -1637,7 +1684,7 @@ static int unshare_fs(unsigned long unsh +@@ -1637,7 +1684,7 @@ static int unshare_fs(unsigned long unshare_flags,= struct fs_struct **new_fsp) return 0; =20 /* don't need lock here; in the worst case we'll do useless copy */ @@ -64151,7 +65775,7 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4/= kernel/fork.c return 0; =20 *new_fsp =3D copy_fs_struct(fs); -@@ -1726,7 +1773,8 @@ SYSCALL_DEFINE1(unshare, unsigned long,=20 +@@ -1726,7 +1773,8 @@ SYSCALL_DEFINE1(unshare, unsigned long, unshare_fl= ags) fs =3D current->fs; spin_lock(&fs->lock); current->fs =3D new_fs; @@ -64161,9 +65785,10 @@ diff -urNp linux-3.1.4/kernel/fork.c linux-3.1.4= /kernel/fork.c new_fs =3D NULL; else new_fs =3D fs; -diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.4/kernel/futex.c ---- linux-3.1.4/kernel/futex.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/futex.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/futex.c b/kernel/futex.c +index 11cbe05..9ff191b 100644 +--- a/kernel/futex.c ++++ b/kernel/futex.c @@ -54,6 +54,7 @@ #include #include @@ -64172,7 +65797,7 @@ diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.4= /kernel/futex.c #include #include #include -@@ -238,6 +239,11 @@ get_futex_key(u32 __user *uaddr, int fsh +@@ -238,6 +239,11 @@ get_futex_key(u32 __user *uaddr, int fshared, union= futex_key *key, int rw) struct page *page, *page_head; int err, ro =3D 0; =20 @@ -64184,7 +65809,7 @@ diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.4= /kernel/futex.c /* * The futex address must be "naturally" aligned. */ -@@ -1863,6 +1869,8 @@ static int futex_wait(u32 __user *uaddr, +@@ -1863,6 +1869,8 @@ static int futex_wait(u32 __user *uaddr, unsigned = int flags, u32 val, struct futex_q q =3D futex_q_init; int ret; =20 @@ -64193,7 +65818,7 @@ diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.4= /kernel/futex.c if (!bitset) return -EINVAL; q.bitset =3D bitset; -@@ -2259,6 +2267,8 @@ static int futex_wait_requeue_pi(u32 __u +@@ -2259,6 +2267,8 @@ static int futex_wait_requeue_pi(u32 __user *uaddr= , unsigned int flags, struct futex_q q =3D futex_q_init; int res, ret; =20 @@ -64202,7 +65827,7 @@ diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.4= /kernel/futex.c if (!bitset) return -EINVAL; =20 -@@ -2431,7 +2441,9 @@ SYSCALL_DEFINE3(get_robust_list, int, pi +@@ -2431,7 +2441,9 @@ SYSCALL_DEFINE3(get_robust_list, int, pid, { struct robust_list_head __user *head; unsigned long ret; @@ -64212,7 +65837,7 @@ diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.4= /kernel/futex.c =20 if (!futex_cmpxchg_enabled) return -ENOSYS; -@@ -2447,6 +2459,10 @@ SYSCALL_DEFINE3(get_robust_list, int, pi +@@ -2447,6 +2459,10 @@ SYSCALL_DEFINE3(get_robust_list, int, pid, if (!p) goto err_unlock; ret =3D -EPERM; @@ -64223,7 +65848,7 @@ diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.4= /kernel/futex.c pcred =3D __task_cred(p); /* If victim is in different user_ns, then uids are not comparable, so we must have CAP_SYS_PTRACE */ -@@ -2461,6 +2477,7 @@ SYSCALL_DEFINE3(get_robust_list, int, pi +@@ -2461,6 +2477,7 @@ SYSCALL_DEFINE3(get_robust_list, int, pid, !ns_capable(pcred->user->user_ns, CAP_SYS_PTRACE)) goto err_unlock; ok: @@ -64251,9 +65876,10 @@ diff -urNp linux-3.1.4/kernel/futex.c linux-3.1.= 4/kernel/futex.c =20 for (i =3D 0; i < ARRAY_SIZE(futex_queues); i++) { plist_head_init(&futex_queues[i].chain); -diff -urNp linux-3.1.4/kernel/futex_compat.c linux-3.1.4/kernel/futex_co= mpat.c ---- linux-3.1.4/kernel/futex_compat.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/kernel/futex_compat.c 2011-11-16 18:40:44.000000000 -050= 0 +diff --git a/kernel/futex_compat.c b/kernel/futex_compat.c +index 5f9e689..03afa21 100644 +--- a/kernel/futex_compat.c ++++ b/kernel/futex_compat.c @@ -10,6 +10,7 @@ #include #include @@ -64262,7 +65888,7 @@ diff -urNp linux-3.1.4/kernel/futex_compat.c linu= x-3.1.4/kernel/futex_compat.c =20 #include =20 -@@ -136,7 +137,10 @@ compat_sys_get_robust_list(int pid, comp +@@ -136,7 +137,10 @@ compat_sys_get_robust_list(int pid, compat_uptr_t _= _user *head_ptr, { struct compat_robust_list_head __user *head; unsigned long ret; @@ -64274,7 +65900,7 @@ diff -urNp linux-3.1.4/kernel/futex_compat.c linu= x-3.1.4/kernel/futex_compat.c =20 if (!futex_cmpxchg_enabled) return -ENOSYS; -@@ -152,6 +156,10 @@ compat_sys_get_robust_list(int pid, comp +@@ -152,6 +156,10 @@ compat_sys_get_robust_list(int pid, compat_uptr_t _= _user *head_ptr, if (!p) goto err_unlock; ret =3D -EPERM; @@ -64285,7 +65911,7 @@ diff -urNp linux-3.1.4/kernel/futex_compat.c linu= x-3.1.4/kernel/futex_compat.c pcred =3D __task_cred(p); /* If victim is in different user_ns, then uids are not comparable, so we must have CAP_SYS_PTRACE */ -@@ -166,6 +174,7 @@ compat_sys_get_robust_list(int pid, comp +@@ -166,6 +174,7 @@ compat_sys_get_robust_list(int pid, compat_uptr_t __= user *head_ptr, !ns_capable(pcred->user->user_ns, CAP_SYS_PTRACE)) goto err_unlock; ok: @@ -64293,9 +65919,10 @@ diff -urNp linux-3.1.4/kernel/futex_compat.c lin= ux-3.1.4/kernel/futex_compat.c head =3D p->compat_robust_list; rcu_read_unlock(); } -diff -urNp linux-3.1.4/kernel/gcov/base.c linux-3.1.4/kernel/gcov/base.c ---- linux-3.1.4/kernel/gcov/base.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/gcov/base.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/gcov/base.c b/kernel/gcov/base.c +index 9b22d03..6295b62 100644 +--- a/kernel/gcov/base.c ++++ b/kernel/gcov/base.c @@ -102,11 +102,6 @@ void gcov_enable_events(void) } =20 @@ -64308,7 +65935,7 @@ diff -urNp linux-3.1.4/kernel/gcov/base.c linux-3= .1.4/kernel/gcov/base.c /* Update list and generate events when modules are unloaded. */ static int gcov_module_notifier(struct notifier_block *nb, unsigned lon= g event, void *data) -@@ -121,7 +116,7 @@ static int gcov_module_notifier(struct n +@@ -121,7 +116,7 @@ static int gcov_module_notifier(struct notifier_bloc= k *nb, unsigned long event, prev =3D NULL; /* Remove entries located in module from linked list. */ for (info =3D gcov_info_head; info; info =3D info->next) { @@ -64317,9 +65944,10 @@ diff -urNp linux-3.1.4/kernel/gcov/base.c linux-= 3.1.4/kernel/gcov/base.c if (prev) prev->next =3D info->next; else -diff -urNp linux-3.1.4/kernel/hrtimer.c linux-3.1.4/kernel/hrtimer.c ---- linux-3.1.4/kernel/hrtimer.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/hrtimer.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c +index a9205e3..1c6f5c0 100644 +--- a/kernel/hrtimer.c ++++ b/kernel/hrtimer.c @@ -1391,7 +1391,7 @@ void hrtimer_peek_ahead_timers(void) local_irq_restore(flags); } @@ -64329,10 +65957,11 @@ diff -urNp linux-3.1.4/kernel/hrtimer.c linux-3= .1.4/kernel/hrtimer.c { hrtimer_peek_ahead_timers(); } -diff -urNp linux-3.1.4/kernel/jump_label.c linux-3.1.4/kernel/jump_label= .c ---- linux-3.1.4/kernel/jump_label.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/jump_label.c 2011-11-16 18:39:08.000000000 -0500 -@@ -55,7 +55,9 @@ jump_label_sort_entries(struct jump_entr +diff --git a/kernel/jump_label.c b/kernel/jump_label.c +index a8ce450..5519bce 100644 +--- a/kernel/jump_label.c ++++ b/kernel/jump_label.c +@@ -55,7 +55,9 @@ jump_label_sort_entries(struct jump_entry *start, stru= ct jump_entry *stop) =20 size =3D (((unsigned long)stop - (unsigned long)start) / sizeof(struct jump_entry)); @@ -64342,7 +65971,7 @@ diff -urNp linux-3.1.4/kernel/jump_label.c linux-= 3.1.4/kernel/jump_label.c } =20 static void jump_label_update(struct jump_label_key *key, int enable); -@@ -297,10 +299,12 @@ static void jump_label_invalidate_module +@@ -297,10 +299,12 @@ static void jump_label_invalidate_module_init(stru= ct module *mod) struct jump_entry *iter_stop =3D iter_start + mod->num_jump_entries; struct jump_entry *iter; =20 @@ -64355,9 +65984,10 @@ diff -urNp linux-3.1.4/kernel/jump_label.c linux= -3.1.4/kernel/jump_label.c } =20 static int -diff -urNp linux-3.1.4/kernel/kallsyms.c linux-3.1.4/kernel/kallsyms.c ---- linux-3.1.4/kernel/kallsyms.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/kallsyms.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c +index 079f1d3..a407562 100644 +--- a/kernel/kallsyms.c ++++ b/kernel/kallsyms.c @@ -11,6 +11,9 @@ * Changed the compression method from stem compression to "table = lookup" * compression (see scripts/kallsyms.c for a more complete descrip= tion) @@ -64368,7 +65998,7 @@ diff -urNp linux-3.1.4/kernel/kallsyms.c linux-3.= 1.4/kernel/kallsyms.c #include #include #include -@@ -53,12 +56,33 @@ extern const unsigned long kallsyms_mark +@@ -53,12 +56,33 @@ extern const unsigned long kallsyms_markers[] __attr= ibute__((weak)); =20 static inline int is_kernel_inittext(unsigned long addr) { @@ -64402,7 +66032,7 @@ diff -urNp linux-3.1.4/kernel/kallsyms.c linux-3.= 1.4/kernel/kallsyms.c static inline int is_kernel_text(unsigned long addr) { if ((addr >=3D (unsigned long)_stext && addr <=3D (unsigned long)_etex= t) || -@@ -69,13 +93,28 @@ static inline int is_kernel_text(unsigne +@@ -69,13 +93,28 @@ static inline int is_kernel_text(unsigned long addr) =20 static inline int is_kernel(unsigned long addr) { @@ -64431,7 +66061,7 @@ diff -urNp linux-3.1.4/kernel/kallsyms.c linux-3.= 1.4/kernel/kallsyms.c if (all_var) return is_kernel(addr); =20 -@@ -454,7 +493,6 @@ static unsigned long get_ksymbol_core(st +@@ -454,7 +493,6 @@ static unsigned long get_ksymbol_core(struct kallsym= _iter *iter) =20 static void reset_iter(struct kallsym_iter *iter, loff_t new_pos) { @@ -64439,7 +66069,7 @@ diff -urNp linux-3.1.4/kernel/kallsyms.c linux-3.= 1.4/kernel/kallsyms.c iter->nameoff =3D get_symbol_offset(new_pos); iter->pos =3D new_pos; } -@@ -502,6 +540,11 @@ static int s_show(struct seq_file *m, vo +@@ -502,6 +540,11 @@ static int s_show(struct seq_file *m, void *p) { struct kallsym_iter *iter =3D m->private; =20 @@ -64451,7 +66081,7 @@ diff -urNp linux-3.1.4/kernel/kallsyms.c linux-3.= 1.4/kernel/kallsyms.c /* Some debugging symbols have no name. Ignore them. */ if (!iter->name[0]) return 0; -@@ -540,7 +583,7 @@ static int kallsyms_open(struct inode *i +@@ -540,7 +583,7 @@ static int kallsyms_open(struct inode *inode, struct= file *file) struct kallsym_iter *iter; int ret; =20 @@ -64460,10 +66090,11 @@ diff -urNp linux-3.1.4/kernel/kallsyms.c linux-= 3.1.4/kernel/kallsyms.c if (!iter) return -ENOMEM; reset_iter(iter, 0); -diff -urNp linux-3.1.4/kernel/kexec.c linux-3.1.4/kernel/kexec.c ---- linux-3.1.4/kernel/kexec.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/kexec.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1033,7 +1033,8 @@ asmlinkage long compat_sys_kexec_load(un +diff --git a/kernel/kexec.c b/kernel/kexec.c +index 296fbc8..84cb857 100644 +--- a/kernel/kexec.c ++++ b/kernel/kexec.c +@@ -1033,7 +1033,8 @@ asmlinkage long compat_sys_kexec_load(unsigned lon= g entry, unsigned long flags) { struct compat_kexec_segment in; @@ -64473,10 +66104,11 @@ diff -urNp linux-3.1.4/kernel/kexec.c linux-3.1= .4/kernel/kexec.c unsigned long i, result; =20 /* Don't allow clients that don't understand the native -diff -urNp linux-3.1.4/kernel/kmod.c linux-3.1.4/kernel/kmod.c ---- linux-3.1.4/kernel/kmod.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/kmod.c 2011-11-16 18:40:44.000000000 -0500 -@@ -73,13 +73,12 @@ char modprobe_path[KMOD_PATH_LEN] =3D "/sb +diff --git a/kernel/kmod.c b/kernel/kmod.c +index a4bea97..7a1ae9a 100644 +--- a/kernel/kmod.c ++++ b/kernel/kmod.c +@@ -73,13 +73,12 @@ char modprobe_path[KMOD_PATH_LEN] =3D "/sbin/modprob= e"; * If module auto-loading support is disabled then this function * becomes a no-operation. */ @@ -64492,7 +66124,7 @@ diff -urNp linux-3.1.4/kernel/kmod.c linux-3.1.4/= kernel/kmod.c static char *envp[] =3D { "HOME=3D/", "TERM=3Dlinux", "PATH=3D/sbin:/usr/sbin:/bin:/usr/bin", -@@ -88,9 +87,7 @@ int __request_module(bool wait, const ch +@@ -88,9 +87,7 @@ int __request_module(bool wait, const char *fmt, ...) #define MAX_KMOD_CONCURRENT 50 /* Completely arbitrary value - KAO */ static int kmod_loop_msg; =20 @@ -64503,7 +66135,7 @@ diff -urNp linux-3.1.4/kernel/kmod.c linux-3.1.4/= kernel/kmod.c if (ret >=3D MODULE_NAME_LEN) return -ENAMETOOLONG; =20 -@@ -98,6 +95,20 @@ int __request_module(bool wait, const ch +@@ -98,6 +95,20 @@ int __request_module(bool wait, const char *fmt, ...) if (ret) return ret; =20 @@ -64524,7 +66156,7 @@ diff -urNp linux-3.1.4/kernel/kmod.c linux-3.1.4/= kernel/kmod.c /* If modprobe needs a service that is in a module, we get a recursive * loop. Limit the number of running kmod threads to max_threads/2 or * MAX_KMOD_CONCURRENT, whichever is the smaller. A cleaner method -@@ -133,6 +144,47 @@ int __request_module(bool wait, const ch +@@ -133,6 +144,47 @@ int __request_module(bool wait, const char *fmt, ..= .) atomic_dec(&kmod_concurrent); return ret; } @@ -64581,10 +66213,11 @@ diff -urNp linux-3.1.4/kernel/kmod.c linux-3.1.= 4/kernel/kmod.c =20 /* * If ret is 0, either ____call_usermodehelper failed and the -diff -urNp linux-3.1.4/kernel/kprobes.c linux-3.1.4/kernel/kprobes.c ---- linux-3.1.4/kernel/kprobes.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/kprobes.c 2011-11-16 18:39:08.000000000 -0500 -@@ -185,7 +185,7 @@ static kprobe_opcode_t __kprobes *__get_ +diff --git a/kernel/kprobes.c b/kernel/kprobes.c +index b30fd54..11821ec 100644 +--- a/kernel/kprobes.c ++++ b/kernel/kprobes.c +@@ -185,7 +185,7 @@ static kprobe_opcode_t __kprobes *__get_insn_slot(st= ruct kprobe_insn_cache *c) * kernel image and loaded module images reside. This is required * so x86_64 can correctly handle the %rip-relative fixups. */ @@ -64593,7 +66226,7 @@ diff -urNp linux-3.1.4/kernel/kprobes.c linux-3.1= .4/kernel/kprobes.c if (!kip->insns) { kfree(kip); return NULL; -@@ -225,7 +225,7 @@ static int __kprobes collect_one_slot(st +@@ -225,7 +225,7 @@ static int __kprobes collect_one_slot(struct kprobe_= insn_page *kip, int idx) */ if (!list_is_singular(&kip->list)) { list_del(&kip->list); @@ -64611,7 +66244,7 @@ diff -urNp linux-3.1.4/kernel/kprobes.c linux-3.1= .4/kernel/kprobes.c const char *symbol_name; void *addr; struct kprobe_blackpoint *kb; -@@ -2075,7 +2075,7 @@ static int __kprobes show_kprobe_addr(st +@@ -2075,7 +2075,7 @@ static int __kprobes show_kprobe_addr(struct seq_f= ile *pi, void *v) const char *sym =3D NULL; unsigned int i =3D *(loff_t *) v; unsigned long offset =3D 0; @@ -64620,9 +66253,10 @@ diff -urNp linux-3.1.4/kernel/kprobes.c linux-3.= 1.4/kernel/kprobes.c =20 head =3D &kprobe_table[i]; preempt_disable(); -diff -urNp linux-3.1.4/kernel/lockdep.c linux-3.1.4/kernel/lockdep.c ---- linux-3.1.4/kernel/lockdep.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/lockdep.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/lockdep.c b/kernel/lockdep.c +index 91d67ce..ac259df 100644 +--- a/kernel/lockdep.c ++++ b/kernel/lockdep.c @@ -583,6 +583,10 @@ static int static_obj(void *obj) end =3D (unsigned long) &_end, addr =3D (unsigned long) obj; @@ -64634,7 +66268,7 @@ diff -urNp linux-3.1.4/kernel/lockdep.c linux-3.1= .4/kernel/lockdep.c /* * static variable? */ -@@ -718,6 +722,7 @@ register_lock_class(struct lockdep_map * +@@ -718,6 +722,7 @@ register_lock_class(struct lockdep_map *lock, unsign= ed int subclass, int force) if (!static_obj(lock->key)) { debug_locks_off(); printk("INFO: trying to register non-static key.\n"); @@ -64642,7 +66276,7 @@ diff -urNp linux-3.1.4/kernel/lockdep.c linux-3.1= .4/kernel/lockdep.c printk("the code is fine but needs lockdep annotation.\n"); printk("turning off the locking correctness validator.\n"); dump_stack(); -@@ -2948,7 +2953,7 @@ static int __lock_acquire(struct lockdep +@@ -2948,7 +2953,7 @@ static int __lock_acquire(struct lockdep_map *lock= , unsigned int subclass, if (!class) return 0; } @@ -64651,10 +66285,11 @@ diff -urNp linux-3.1.4/kernel/lockdep.c linux-3= .1.4/kernel/lockdep.c if (very_verbose(class)) { printk("\nacquire class [%p] %s", class->key, class->name); if (class->name_version > 1) -diff -urNp linux-3.1.4/kernel/lockdep_proc.c linux-3.1.4/kernel/lockdep_= proc.c ---- linux-3.1.4/kernel/lockdep_proc.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/kernel/lockdep_proc.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -39,7 +39,7 @@ static void l_stop(struct seq_file *m, v +diff --git a/kernel/lockdep_proc.c b/kernel/lockdep_proc.c +index 71edd2f..e0542a5 100644 +--- a/kernel/lockdep_proc.c ++++ b/kernel/lockdep_proc.c +@@ -39,7 +39,7 @@ static void l_stop(struct seq_file *m, void *v) =20 static void print_name(struct seq_file *m, struct lock_class *class) { @@ -64663,9 +66298,10 @@ diff -urNp linux-3.1.4/kernel/lockdep_proc.c lin= ux-3.1.4/kernel/lockdep_proc.c const char *name =3D class->name; =20 if (!name) { -diff -urNp linux-3.1.4/kernel/module.c linux-3.1.4/kernel/module.c ---- linux-3.1.4/kernel/module.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/module.c 2011-12-02 17:38:47.000000000 -0500 +diff --git a/kernel/module.c b/kernel/module.c +index 04379f92..fba2faf 100644 +--- a/kernel/module.c ++++ b/kernel/module.c @@ -58,6 +58,7 @@ #include #include @@ -64674,7 +66310,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 #define CREATE_TRACE_POINTS #include -@@ -119,7 +120,8 @@ static BLOCKING_NOTIFIER_HEAD(module_not +@@ -119,7 +120,8 @@ static BLOCKING_NOTIFIER_HEAD(module_notify_list); =20 /* Bounds of module allocation, for speeding __module_address. * Protected by module_mutex. */ @@ -64684,7 +66320,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 int register_module_notifier(struct notifier_block * nb) { -@@ -284,7 +286,7 @@ bool each_symbol_section(bool (*fn)(cons +@@ -284,7 +286,7 @@ bool each_symbol_section(bool (*fn)(const struct sym= search *arr, return true; =20 list_for_each_entry_rcu(mod, &modules, list) { @@ -64693,7 +66329,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c { mod->syms, mod->syms + mod->num_syms, mod->crcs, NOT_GPL_ONLY, false }, { mod->gpl_syms, mod->gpl_syms + mod->num_gpl_syms, -@@ -306,7 +308,7 @@ bool each_symbol_section(bool (*fn)(cons +@@ -306,7 +308,7 @@ bool each_symbol_section(bool (*fn)(const struct sym= search *arr, #endif }; =20 @@ -64702,7 +66338,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c return true; } return false; -@@ -438,7 +440,7 @@ static inline void __percpu *mod_percpu( +@@ -438,7 +440,7 @@ static inline void __percpu *mod_percpu(struct modul= e *mod) static int percpu_modalloc(struct module *mod, unsigned long size, unsigned long align) { @@ -64720,7 +66356,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c static inline bool sect_empty(const Elf_Shdr *sect) { return !(sect->sh_flags & SHF_ALLOC) || sect->sh_size =3D=3D 0; -@@ -1649,21 +1651,21 @@ static void set_section_ro_nx(void *base +@@ -1649,21 +1651,21 @@ static void set_section_ro_nx(void *base, =20 static void unset_module_core_ro_nx(struct module *mod) { @@ -64792,7 +66428,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c set_memory_ro); } } -@@ -1748,16 +1750,19 @@ static void free_module(struct module *m +@@ -1748,16 +1750,19 @@ static void free_module(struct module *mod) =20 /* This may be NULL, but that's OK */ unset_module_init_ro_nx(mod); @@ -64815,7 +66451,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 #ifdef CONFIG_MPU update_protections(current->mm); -@@ -1826,10 +1831,31 @@ static int simplify_symbols(struct modul +@@ -1826,10 +1831,31 @@ static int simplify_symbols(struct module *mod, = const struct load_info *info) unsigned int i; int ret =3D 0; const struct kernel_symbol *ksym; @@ -64847,7 +66483,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c switch (sym[i].st_shndx) { case SHN_COMMON: /* We compiled with -fno-common. These are not -@@ -1850,7 +1876,9 @@ static int simplify_symbols(struct modul +@@ -1850,7 +1876,9 @@ static int simplify_symbols(struct module *mod, co= nst struct load_info *info) ksym =3D resolve_symbol_wait(mod, info, name); /* Ok if resolved. */ if (ksym && !IS_ERR(ksym)) { @@ -64857,7 +66493,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c break; } =20 -@@ -1869,11 +1897,20 @@ static int simplify_symbols(struct modul +@@ -1869,11 +1897,20 @@ static int simplify_symbols(struct module *mod, = const struct load_info *info) secbase =3D (unsigned long)mod_percpu(mod); else secbase =3D info->sechdrs[sym[i].st_shndx].sh_addr; @@ -64878,7 +66514,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c return ret; } =20 -@@ -1977,22 +2014,12 @@ static void layout_sections(struct modul +@@ -1977,22 +2014,12 @@ static void layout_sections(struct module *mod, = struct load_info *info) || s->sh_entsize !=3D ~0UL || strstarts(sname, ".init")) continue; @@ -64905,7 +66541,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c } =20 DEBUGP("Init section allocation order:\n"); -@@ -2006,23 +2033,13 @@ static void layout_sections(struct modul +@@ -2006,23 +2033,13 @@ static void layout_sections(struct module *mod, = struct load_info *info) || s->sh_entsize !=3D ~0UL || !strstarts(sname, ".init")) continue; @@ -64934,7 +66570,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c } } =20 -@@ -2187,7 +2204,7 @@ static void layout_symtab(struct module=20 +@@ -2187,7 +2204,7 @@ static void layout_symtab(struct module *mod, stru= ct load_info *info) =20 /* Put symbol section at end of init part of module. */ symsect->sh_flags |=3D SHF_ALLOC; @@ -64943,7 +66579,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c info->index.sym) | INIT_OFFSET_MASK; DEBUGP("\t%s\n", info->secstrings + symsect->sh_name); =20 -@@ -2204,19 +2221,19 @@ static void layout_symtab(struct module=20 +@@ -2204,19 +2221,19 @@ static void layout_symtab(struct module *mod, st= ruct load_info *info) } =20 /* Append room for core symbols at end of core part. */ @@ -64968,7 +66604,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c } =20 static void add_kallsyms(struct module *mod, const struct load_info *in= fo) -@@ -2232,11 +2249,13 @@ static void add_kallsyms(struct module * +@@ -2232,11 +2249,13 @@ static void add_kallsyms(struct module *mod, con= st struct load_info *info) /* Make sure we get permanent strtab: don't use info->strtab. */ mod->strtab =3D (void *)info->sechdrs[info->index.str].sh_addr; =20 @@ -64983,7 +66619,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c src =3D mod->symtab; *dst =3D *src; for (ndst =3D i =3D 1; i < mod->num_symtab; ++i, ++src) { -@@ -2249,10 +2268,12 @@ static void add_kallsyms(struct module * +@@ -2249,10 +2268,12 @@ static void add_kallsyms(struct module *mod, con= st struct load_info *info) } mod->core_num_syms =3D ndst; =20 @@ -64997,7 +66633,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c } #else static inline void layout_symtab(struct module *mod, struct load_info *= info) -@@ -2286,17 +2307,33 @@ void * __weak module_alloc(unsigned long +@@ -2286,17 +2307,33 @@ void * __weak module_alloc(unsigned long size) return size =3D=3D 0 ? NULL : vmalloc_exec(size); } =20 @@ -65036,7 +66672,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c mutex_unlock(&module_mutex); } return ret; -@@ -2474,8 +2511,14 @@ static struct module *setup_load_info(st +@@ -2474,8 +2511,14 @@ static struct module *setup_load_info(struct load= _info *info) static int check_modinfo(struct module *mod, struct load_info *info) { const char *modmagic =3D get_modinfo(info, "vermagic"); @@ -65051,7 +66687,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c /* This is allowed: modprobe --force will invalidate it. */ if (!modmagic) { err =3D try_to_force_load(mod, "bad vermagic"); -@@ -2495,7 +2538,7 @@ static int check_modinfo(struct module * +@@ -2495,7 +2538,7 @@ static int check_modinfo(struct module *mod, struc= t load_info *info) } =20 /* Set up license info based on the info section */ @@ -65060,7 +66696,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 return 0; } -@@ -2589,7 +2632,7 @@ static int move_module(struct module *mo +@@ -2589,7 +2632,7 @@ static int move_module(struct module *mod, struct = load_info *info) void *ptr; =20 /* Do the allocs. */ @@ -65069,7 +66705,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c /* * The pointer to this block is stored in the module structure * which is inside the block. Just mark it as not being a -@@ -2599,23 +2642,50 @@ static int move_module(struct module *mo +@@ -2599,23 +2642,50 @@ static int move_module(struct module *mod, struc= t load_info *info) if (!ptr) return -ENOMEM; =20 @@ -65128,7 +66764,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 /* Transfer each section which specifies SHF_ALLOC */ DEBUGP("final section addresses:\n"); -@@ -2626,16 +2696,45 @@ static int move_module(struct module *mo +@@ -2626,16 +2696,45 @@ static int move_module(struct module *mod, struc= t load_info *info) if (!(shdr->sh_flags & SHF_ALLOC)) continue; =20 @@ -65181,7 +66817,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c DEBUGP("\t0x%lx %s\n", shdr->sh_addr, info->secstrings + shdr->sh_name); } -@@ -2686,12 +2785,12 @@ static void flush_module_icache(const st +@@ -2686,12 +2785,12 @@ static void flush_module_icache(const struct mod= ule *mod) * Do it before processing of module parameters, so the module * can provide parameter accessor functions of its own. */ @@ -65200,7 +66836,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 set_fs(old_fs); } -@@ -2771,8 +2870,10 @@ static void module_deallocate(struct mod +@@ -2771,8 +2870,10 @@ static void module_deallocate(struct module *mod,= struct load_info *info) { kfree(info->strmap); percpu_modfree(mod); @@ -65213,7 +66849,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c } =20 int __weak module_finalize(const Elf_Ehdr *hdr, -@@ -2836,9 +2937,38 @@ static struct module *load_module(void _ +@@ -2836,9 +2937,38 @@ static struct module *load_module(void __user *um= od, if (err) goto free_unload; =20 @@ -65252,7 +66888,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c /* Fix up syms, so that st_value is a pointer to location. */ err =3D simplify_symbols(mod, &info); if (err < 0) -@@ -2854,13 +2984,6 @@ static struct module *load_module(void _ +@@ -2854,13 +2984,6 @@ static struct module *load_module(void __user *um= od, =20 flush_module_icache(mod); =20 @@ -65266,7 +66902,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c /* Mark state as coming so strong_try_module_get() ignores us. */ mod->state =3D MODULE_STATE_COMING; =20 -@@ -2920,11 +3043,10 @@ static struct module *load_module(void _ +@@ -2920,11 +3043,10 @@ static struct module *load_module(void __user *u= mod, unlock: mutex_unlock(&module_mutex); synchronize_sched(); @@ -65279,7 +66915,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c free_unload: module_unload_free(mod); free_module: -@@ -2965,16 +3087,16 @@ SYSCALL_DEFINE3(init_module, void __user +@@ -2965,16 +3087,16 @@ SYSCALL_DEFINE3(init_module, void __user *, umod= , MODULE_STATE_COMING, mod); =20 /* Set RO and NX regions for core */ @@ -65304,7 +66940,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 do_mod_ctors(mod); /* Start the module */ -@@ -3020,11 +3142,12 @@ SYSCALL_DEFINE3(init_module, void __user +@@ -3020,11 +3142,12 @@ SYSCALL_DEFINE3(init_module, void __user *, umod= , mod->strtab =3D mod->core_strtab; #endif unset_module_init_ro_nx(mod); @@ -65322,7 +66958,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c mutex_unlock(&module_mutex); =20 return 0; -@@ -3055,10 +3178,16 @@ static const char *get_ksymbol(struct mo +@@ -3055,10 +3178,16 @@ static const char *get_ksymbol(struct module *mo= d, unsigned long nextval; =20 /* At worse, next value is at end of module */ @@ -65342,7 +66978,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 /* Scan for closest preceding symbol, and next symbol. (ELF starts real symbols at 1). */ -@@ -3304,7 +3433,7 @@ static int m_show(struct seq_file *m, vo +@@ -3304,7 +3433,7 @@ static int m_show(struct seq_file *m, void *p) char buf[8]; =20 seq_printf(m, "%s %u", @@ -65351,7 +66987,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c print_unload_info(m, mod); =20 /* Informative for users. */ -@@ -3313,7 +3442,7 @@ static int m_show(struct seq_file *m, vo +@@ -3313,7 +3442,7 @@ static int m_show(struct seq_file *m, void *p) mod->state =3D=3D MODULE_STATE_COMING ? "Loading": "Live"); /* Used by oprofile and other similar tools. */ @@ -65360,7 +66996,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c =20 /* Taints info */ if (mod->taints) -@@ -3349,7 +3478,17 @@ static const struct file_operations proc +@@ -3349,7 +3478,17 @@ static const struct file_operations proc_modules_= operations =3D { =20 static int __init proc_modules_init(void) { @@ -65378,7 +67014,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c return 0; } module_init(proc_modules_init); -@@ -3408,12 +3547,12 @@ struct module *__module_address(unsigned +@@ -3408,12 +3547,12 @@ struct module *__module_address(unsigned long ad= dr) { struct module *mod; =20 @@ -65394,7 +67030,7 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.1.= 4/kernel/module.c return mod; return NULL; } -@@ -3447,11 +3586,20 @@ bool is_module_text_address(unsigned lon +@@ -3447,11 +3586,20 @@ bool is_module_text_address(unsigned long addr) */ struct module *__module_text_address(unsigned long addr) { @@ -65418,41 +67054,11 @@ diff -urNp linux-3.1.4/kernel/module.c linux-3.= 1.4/kernel/module.c mod =3D NULL; } return mod; -diff -urNp linux-3.1.4/kernel/mutex.c linux-3.1.4/kernel/mutex.c ---- linux-3.1.4/kernel/mutex.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/mutex.c 2011-11-16 18:39:08.000000000 -0500 -@@ -198,7 +198,7 @@ __mutex_lock_common(struct mutex *lock,=20 - spin_lock_mutex(&lock->wait_lock, flags); -=20 - debug_mutex_lock_common(lock, &waiter); -- debug_mutex_add_waiter(lock, &waiter, task_thread_info(task)); -+ debug_mutex_add_waiter(lock, &waiter, task); -=20 - /* add waiting tasks to the end of the waitqueue (FIFO): */ - list_add_tail(&waiter.list, &lock->wait_list); -@@ -227,8 +227,7 @@ __mutex_lock_common(struct mutex *lock,=20 - * TASK_UNINTERRUPTIBLE case.) - */ - if (unlikely(signal_pending_state(state, task))) { -- mutex_remove_waiter(lock, &waiter, -- task_thread_info(task)); -+ mutex_remove_waiter(lock, &waiter, task); - mutex_release(&lock->dep_map, 1, ip); - spin_unlock_mutex(&lock->wait_lock, flags); -=20 -@@ -249,7 +248,7 @@ __mutex_lock_common(struct mutex *lock,=20 - done: - lock_acquired(&lock->dep_map, ip); - /* got the lock - rejoice! */ -- mutex_remove_waiter(lock, &waiter, current_thread_info()); -+ mutex_remove_waiter(lock, &waiter, task); - mutex_set_owner(lock); -=20 - /* set it to 0 if there are no waiters left: */ -diff -urNp linux-3.1.4/kernel/mutex-debug.c linux-3.1.4/kernel/mutex-deb= ug.c ---- linux-3.1.4/kernel/mutex-debug.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/mutex-debug.c 2011-11-16 18:39:08.000000000 -0500 -@@ -49,21 +49,21 @@ void debug_mutex_free_waiter(struct mute +diff --git a/kernel/mutex-debug.c b/kernel/mutex-debug.c +index 73da83a..fe46e99 100644 +--- a/kernel/mutex-debug.c ++++ b/kernel/mutex-debug.c +@@ -49,21 +49,21 @@ void debug_mutex_free_waiter(struct mutex_waiter *wa= iter) } =20 void debug_mutex_add_waiter(struct mutex *lock, struct mutex_waiter *wa= iter, @@ -65480,10 +67086,11 @@ diff -urNp linux-3.1.4/kernel/mutex-debug.c lin= ux-3.1.4/kernel/mutex-debug.c =20 list_del_init(&waiter->list); waiter->task =3D NULL; -diff -urNp linux-3.1.4/kernel/mutex-debug.h linux-3.1.4/kernel/mutex-deb= ug.h ---- linux-3.1.4/kernel/mutex-debug.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/mutex-debug.h 2011-11-16 18:39:08.000000000 -0500 -@@ -20,9 +20,9 @@ extern void debug_mutex_wake_waiter(stru +diff --git a/kernel/mutex-debug.h b/kernel/mutex-debug.h +index 0799fd3..d06ae3b 100644 +--- a/kernel/mutex-debug.h ++++ b/kernel/mutex-debug.h +@@ -20,9 +20,9 @@ extern void debug_mutex_wake_waiter(struct mutex *lock= , extern void debug_mutex_free_waiter(struct mutex_waiter *waiter); extern void debug_mutex_add_waiter(struct mutex *lock, struct mutex_waiter *waiter, @@ -65495,10 +67102,43 @@ diff -urNp linux-3.1.4/kernel/mutex-debug.h lin= ux-3.1.4/kernel/mutex-debug.h extern void debug_mutex_unlock(struct mutex *lock); extern void debug_mutex_init(struct mutex *lock, const char *name, struct lock_class_key *key); -diff -urNp linux-3.1.4/kernel/padata.c linux-3.1.4/kernel/padata.c ---- linux-3.1.4/kernel/padata.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/padata.c 2011-11-16 18:39:08.000000000 -0500 -@@ -132,10 +132,10 @@ int padata_do_parallel(struct padata_ins +diff --git a/kernel/mutex.c b/kernel/mutex.c +index d607ed5..58d0a52 100644 +--- a/kernel/mutex.c ++++ b/kernel/mutex.c +@@ -198,7 +198,7 @@ __mutex_lock_common(struct mutex *lock, long state, = unsigned int subclass, + spin_lock_mutex(&lock->wait_lock, flags); +=20 + debug_mutex_lock_common(lock, &waiter); +- debug_mutex_add_waiter(lock, &waiter, task_thread_info(task)); ++ debug_mutex_add_waiter(lock, &waiter, task); +=20 + /* add waiting tasks to the end of the waitqueue (FIFO): */ + list_add_tail(&waiter.list, &lock->wait_list); +@@ -227,8 +227,7 @@ __mutex_lock_common(struct mutex *lock, long state, = unsigned int subclass, + * TASK_UNINTERRUPTIBLE case.) + */ + if (unlikely(signal_pending_state(state, task))) { +- mutex_remove_waiter(lock, &waiter, +- task_thread_info(task)); ++ mutex_remove_waiter(lock, &waiter, task); + mutex_release(&lock->dep_map, 1, ip); + spin_unlock_mutex(&lock->wait_lock, flags); +=20 +@@ -249,7 +248,7 @@ __mutex_lock_common(struct mutex *lock, long state, = unsigned int subclass, + done: + lock_acquired(&lock->dep_map, ip); + /* got the lock - rejoice! */ +- mutex_remove_waiter(lock, &waiter, current_thread_info()); ++ mutex_remove_waiter(lock, &waiter, task); + mutex_set_owner(lock); +=20 + /* set it to 0 if there are no waiters left: */ +diff --git a/kernel/padata.c b/kernel/padata.c +index b91941d..0871d60 100644 +--- a/kernel/padata.c ++++ b/kernel/padata.c +@@ -132,10 +132,10 @@ int padata_do_parallel(struct padata_instance *pin= st, padata->pd =3D pd; padata->cb_cpu =3D cb_cpu; =20 @@ -65512,7 +67152,7 @@ diff -urNp linux-3.1.4/kernel/padata.c linux-3.1.= 4/kernel/padata.c =20 target_cpu =3D padata_cpu_hash(padata); queue =3D per_cpu_ptr(pd->pqueue, target_cpu); -@@ -444,7 +444,7 @@ static struct parallel_data *padata_allo +@@ -444,7 +444,7 @@ static struct parallel_data *padata_alloc_pd(struct = padata_instance *pinst, padata_init_pqueues(pd); padata_init_squeues(pd); setup_timer(&pd->timer, padata_reorder_timer, (unsigned long)pd); @@ -65521,10 +67161,11 @@ diff -urNp linux-3.1.4/kernel/padata.c linux-3.= 1.4/kernel/padata.c atomic_set(&pd->reorder_objects, 0); atomic_set(&pd->refcnt, 0); pd->pinst =3D pinst; -diff -urNp linux-3.1.4/kernel/panic.c linux-3.1.4/kernel/panic.c ---- linux-3.1.4/kernel/panic.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/panic.c 2011-11-16 18:40:44.000000000 -0500 -@@ -371,7 +371,7 @@ static void warn_slowpath_common(const c +diff --git a/kernel/panic.c b/kernel/panic.c +index d7bb697..9ef9f19 100644 +--- a/kernel/panic.c ++++ b/kernel/panic.c +@@ -371,7 +371,7 @@ static void warn_slowpath_common(const char *file, i= nt line, void *caller, const char *board; =20 printk(KERN_WARNING "------------[ cut here ]------------\n"); @@ -65543,9 +67184,10 @@ diff -urNp linux-3.1.4/kernel/panic.c linux-3.1.= 4/kernel/panic.c __builtin_return_address(0)); } EXPORT_SYMBOL(__stack_chk_fail); -diff -urNp linux-3.1.4/kernel/pid.c linux-3.1.4/kernel/pid.c ---- linux-3.1.4/kernel/pid.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/pid.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/pid.c b/kernel/pid.c +index e432057..a2b2ac5 100644 +--- a/kernel/pid.c ++++ b/kernel/pid.c @@ -33,6 +33,7 @@ #include #include @@ -65554,7 +67196,7 @@ diff -urNp linux-3.1.4/kernel/pid.c linux-3.1.4/k= ernel/pid.c #include #include #include -@@ -45,7 +46,7 @@ struct pid init_struct_pid =3D INIT_STRUCT +@@ -45,7 +46,7 @@ struct pid init_struct_pid =3D INIT_STRUCT_PID; =20 int pid_max =3D PID_MAX_DEFAULT; =20 @@ -65580,7 +67222,7 @@ diff -urNp linux-3.1.4/kernel/pid.c linux-3.1.4/k= ernel/pid.c } =20 struct task_struct *find_task_by_vpid(pid_t vnr) -@@ -427,6 +435,12 @@ struct task_struct *find_task_by_vpid(pi +@@ -427,6 +435,12 @@ struct task_struct *find_task_by_vpid(pid_t vnr) return find_task_by_pid_ns(vnr, current->nsproxy->pid_ns); } =20 @@ -65593,9 +67235,10 @@ diff -urNp linux-3.1.4/kernel/pid.c linux-3.1.4/= kernel/pid.c struct pid *get_task_pid(struct task_struct *task, enum pid_type type) { struct pid *pid; -diff -urNp linux-3.1.4/kernel/posix-cpu-timers.c linux-3.1.4/kernel/posi= x-cpu-timers.c ---- linux-3.1.4/kernel/posix-cpu-timers.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/kernel/posix-cpu-timers.c 2011-11-16 18:40:44.000000000 = -0500 +diff --git a/kernel/posix-cpu-timers.c b/kernel/posix-cpu-timers.c +index 640ded8..3dafb85 100644 +--- a/kernel/posix-cpu-timers.c ++++ b/kernel/posix-cpu-timers.c @@ -6,6 +6,7 @@ #include #include @@ -65621,9 +67264,10 @@ diff -urNp linux-3.1.4/kernel/posix-cpu-timers.c= linux-3.1.4/kernel/posix-cpu-ti .clock_getres =3D thread_cpu_clock_getres, .clock_get =3D thread_cpu_clock_get, .timer_create =3D thread_cpu_timer_create, -diff -urNp linux-3.1.4/kernel/posix-timers.c linux-3.1.4/kernel/posix-ti= mers.c ---- linux-3.1.4/kernel/posix-timers.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/kernel/posix-timers.c 2011-11-16 18:40:44.000000000 -050= 0 +diff --git a/kernel/posix-timers.c b/kernel/posix-timers.c +index 4556182..9335419 100644 +--- a/kernel/posix-timers.c ++++ b/kernel/posix-timers.c @@ -43,6 +43,7 @@ #include #include @@ -65641,7 +67285,7 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c linu= x-3.1.4/kernel/posix-timers.c =20 /* * These ones are defined below. -@@ -227,7 +228,7 @@ static int posix_get_boottime(const cloc +@@ -227,7 +228,7 @@ static int posix_get_boottime(const clockid_t which_= clock, struct timespec *tp) */ static __init int init_posix_timers(void) { @@ -65650,7 +67294,7 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c linu= x-3.1.4/kernel/posix-timers.c .clock_getres =3D hrtimer_get_res, .clock_get =3D posix_clock_realtime_get, .clock_set =3D posix_clock_realtime_set, -@@ -239,7 +240,7 @@ static __init int init_posix_timers(void +@@ -239,7 +240,7 @@ static __init int init_posix_timers(void) .timer_get =3D common_timer_get, .timer_del =3D common_timer_del, }; @@ -65659,7 +67303,7 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c linu= x-3.1.4/kernel/posix-timers.c .clock_getres =3D hrtimer_get_res, .clock_get =3D posix_ktime_get_ts, .nsleep =3D common_nsleep, -@@ -249,19 +250,19 @@ static __init int init_posix_timers(void +@@ -249,19 +250,19 @@ static __init int init_posix_timers(void) .timer_get =3D common_timer_get, .timer_del =3D common_timer_del, }; @@ -65683,7 +67327,7 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c linu= x-3.1.4/kernel/posix-timers.c .clock_getres =3D hrtimer_get_res, .clock_get =3D posix_get_boottime, .nsleep =3D common_nsleep, -@@ -272,6 +273,8 @@ static __init int init_posix_timers(void +@@ -272,6 +273,8 @@ static __init int init_posix_timers(void) .timer_del =3D common_timer_del, }; =20 @@ -65692,7 +67336,7 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c linu= x-3.1.4/kernel/posix-timers.c posix_timers_register_clock(CLOCK_REALTIME, &clock_realtime); posix_timers_register_clock(CLOCK_MONOTONIC, &clock_monotonic); posix_timers_register_clock(CLOCK_MONOTONIC_RAW, &clock_monotonic_raw)= ; -@@ -473,7 +476,7 @@ void posix_timers_register_clock(const c +@@ -473,7 +476,7 @@ void posix_timers_register_clock(const clockid_t clo= ck_id, return; } =20 @@ -65701,7 +67345,7 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c linu= x-3.1.4/kernel/posix-timers.c } EXPORT_SYMBOL_GPL(posix_timers_register_clock); =20 -@@ -519,9 +522,9 @@ static struct k_clock *clockid_to_kclock +@@ -519,9 +522,9 @@ static struct k_clock *clockid_to_kclock(const clock= id_t id) return (id & CLOCKFD_MASK) =3D=3D CLOCKFD ? &clock_posix_dynamic : &clock_posix_cpu; =20 @@ -65713,7 +67357,7 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c linu= x-3.1.4/kernel/posix-timers.c } =20 static int common_timer_create(struct k_itimer *new_timer) -@@ -959,6 +962,13 @@ SYSCALL_DEFINE2(clock_settime, const clo +@@ -959,6 +962,13 @@ SYSCALL_DEFINE2(clock_settime, const clockid_t, whi= ch_clock, if (copy_from_user(&new_tp, tp, sizeof (*tp))) return -EFAULT; =20 @@ -65727,10 +67371,11 @@ diff -urNp linux-3.1.4/kernel/posix-timers.c li= nux-3.1.4/kernel/posix-timers.c return kc->clock_set(which_clock, &new_tp); } =20 -diff -urNp linux-3.1.4/kernel/power/poweroff.c linux-3.1.4/kernel/power/= poweroff.c ---- linux-3.1.4/kernel/power/poweroff.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/kernel/power/poweroff.c 2011-11-16 18:39:08.000000000 -0= 500 -@@ -37,7 +37,7 @@ static struct sysrq_key_op sysrq_powerof +diff --git a/kernel/power/poweroff.c b/kernel/power/poweroff.c +index d523593..68197a4 100644 +--- a/kernel/power/poweroff.c ++++ b/kernel/power/poweroff.c +@@ -37,7 +37,7 @@ static struct sysrq_key_op sysrq_poweroff_op =3D { .enable_mask =3D SYSRQ_ENABLE_BOOT, }; =20 @@ -65739,10 +67384,11 @@ diff -urNp linux-3.1.4/kernel/power/poweroff.c = linux-3.1.4/kernel/power/poweroff { register_sysrq_key('o', &sysrq_poweroff_op); return 0; -diff -urNp linux-3.1.4/kernel/power/process.c linux-3.1.4/kernel/power/p= rocess.c ---- linux-3.1.4/kernel/power/process.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/kernel/power/process.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -41,6 +41,7 @@ static int try_to_freeze_tasks(bool sig_ +diff --git a/kernel/power/process.c b/kernel/power/process.c +index 0cf3a27..5481be4 100644 +--- a/kernel/power/process.c ++++ b/kernel/power/process.c +@@ -41,6 +41,7 @@ static int try_to_freeze_tasks(bool sig_only) u64 elapsed_csecs64; unsigned int elapsed_csecs; bool wakeup =3D false; @@ -65750,7 +67396,7 @@ diff -urNp linux-3.1.4/kernel/power/process.c lin= ux-3.1.4/kernel/power/process.c =20 do_gettimeofday(&start); =20 -@@ -51,6 +52,8 @@ static int try_to_freeze_tasks(bool sig_ +@@ -51,6 +52,8 @@ static int try_to_freeze_tasks(bool sig_only) =20 while (true) { todo =3D 0; @@ -65759,7 +67405,7 @@ diff -urNp linux-3.1.4/kernel/power/process.c lin= ux-3.1.4/kernel/power/process.c read_lock(&tasklist_lock); do_each_thread(g, p) { if (frozen(p) || !freezable(p)) -@@ -71,9 +74,13 @@ static int try_to_freeze_tasks(bool sig_ +@@ -71,9 +74,13 @@ static int try_to_freeze_tasks(bool sig_only) * try_to_stop() after schedule() in ptrace/signal * stop sees TIF_FREEZE. */ @@ -65775,7 +67421,7 @@ diff -urNp linux-3.1.4/kernel/power/process.c lin= ux-3.1.4/kernel/power/process.c } while_each_thread(g, p); read_unlock(&tasklist_lock); =20 -@@ -82,7 +89,7 @@ static int try_to_freeze_tasks(bool sig_ +@@ -82,7 +89,7 @@ static int try_to_freeze_tasks(bool sig_only) todo +=3D wq_busy; } =20 @@ -65784,10 +67430,11 @@ diff -urNp linux-3.1.4/kernel/power/process.c l= inux-3.1.4/kernel/power/process.c break; =20 if (pm_wakeup_pending()) { -diff -urNp linux-3.1.4/kernel/printk.c linux-3.1.4/kernel/printk.c ---- linux-3.1.4/kernel/printk.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/printk.c 2011-11-16 19:38:11.000000000 -0500 -@@ -313,6 +313,11 @@ static int check_syslog_permissions(int=20 +diff --git a/kernel/printk.c b/kernel/printk.c +index 28a40d8..2411bec 100644 +--- a/kernel/printk.c ++++ b/kernel/printk.c +@@ -313,6 +313,11 @@ static int check_syslog_permissions(int type, bool = from_file) if (from_file && type !=3D SYSLOG_ACTION_OPEN) return 0; =20 @@ -65799,9 +67446,10 @@ diff -urNp linux-3.1.4/kernel/printk.c linux-3.1= .4/kernel/printk.c if (syslog_action_restricted(type)) { if (capable(CAP_SYSLOG)) return 0; -diff -urNp linux-3.1.4/kernel/profile.c linux-3.1.4/kernel/profile.c ---- linux-3.1.4/kernel/profile.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/profile.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/profile.c b/kernel/profile.c +index 961b389..c451353 100644 +--- a/kernel/profile.c ++++ b/kernel/profile.c @@ -39,7 +39,7 @@ struct profile_hit { /* Oprofile timer tick hook */ static int (*timer_hook)(struct pt_regs *) __read_mostly; @@ -65820,7 +67468,7 @@ diff -urNp linux-3.1.4/kernel/profile.c linux-3.1= .4/kernel/profile.c hits[i].hits =3D hits[i].pc =3D 0; } } -@@ -342,9 +342,9 @@ static void do_profile_hits(int type, vo +@@ -342,9 +342,9 @@ static void do_profile_hits(int type, void *__pc, un= signed int nr_hits) * Add the current hit(s) and flush the write-queue out * to the global buffer: */ @@ -65832,7 +67480,7 @@ diff -urNp linux-3.1.4/kernel/profile.c linux-3.1= .4/kernel/profile.c hits[i].pc =3D hits[i].hits =3D 0; } out: -@@ -419,7 +419,7 @@ static void do_profile_hits(int type, vo +@@ -419,7 +419,7 @@ static void do_profile_hits(int type, void *__pc, un= signed int nr_hits) { unsigned long pc; pc =3D ((unsigned long)__pc - (unsigned long)_stext) >> prof_shift; @@ -65841,7 +67489,7 @@ diff -urNp linux-3.1.4/kernel/profile.c linux-3.1= .4/kernel/profile.c } #endif /* !CONFIG_SMP */ =20 -@@ -517,7 +517,7 @@ read_profile(struct file *file, char __u +@@ -517,7 +517,7 @@ read_profile(struct file *file, char __user *buf, si= ze_t count, loff_t *ppos) return -EFAULT; buf++; p++; count--; read++; } @@ -65850,7 +67498,7 @@ diff -urNp linux-3.1.4/kernel/profile.c linux-3.1= .4/kernel/profile.c if (copy_to_user(buf, (void *)pnt, count)) return -EFAULT; read +=3D count; -@@ -548,7 +548,7 @@ static ssize_t write_profile(struct file +@@ -548,7 +548,7 @@ static ssize_t write_profile(struct file *file, cons= t char __user *buf, } #endif profile_discard_flip_buffers(); @@ -65859,10 +67507,11 @@ diff -urNp linux-3.1.4/kernel/profile.c linux-3= .1.4/kernel/profile.c return count; } =20 -diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.4/kernel/ptrace.c ---- linux-3.1.4/kernel/ptrace.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/ptrace.c 2011-11-16 19:50:22.000000000 -0500 -@@ -161,7 +161,8 @@ int ptrace_check_attach(struct task_stru +diff --git a/kernel/ptrace.c b/kernel/ptrace.c +index a70d2a5..cbd4b4f 100644 +--- a/kernel/ptrace.c ++++ b/kernel/ptrace.c +@@ -161,7 +161,8 @@ int ptrace_check_attach(struct task_struct *child, b= ool ignore_state) return ret; } =20 @@ -65872,7 +67521,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c { const struct cred *cred =3D current_cred(), *tcred; =20 -@@ -187,7 +188,8 @@ int __ptrace_may_access(struct task_stru +@@ -187,7 +188,8 @@ int __ptrace_may_access(struct task_struct *task, un= signed int mode) cred->gid =3D=3D tcred->sgid && cred->gid =3D=3D tcred->gid)) goto ok; @@ -65893,7 +67542,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c return -EPERM; =20 return security_ptrace_access_check(task, mode); -@@ -206,7 +210,16 @@ bool ptrace_may_access(struct task_struc +@@ -206,7 +210,16 @@ bool ptrace_may_access(struct task_struct *task, un= signed int mode) { int err; task_lock(task); @@ -65911,7 +67560,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c task_unlock(task); return !err; } -@@ -251,7 +264,7 @@ static int ptrace_attach(struct task_str +@@ -251,7 +264,7 @@ static int ptrace_attach(struct task_struct *task, l= ong request, goto out; =20 task_lock(task); @@ -65920,7 +67569,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c task_unlock(task); if (retval) goto unlock_creds; -@@ -266,7 +279,7 @@ static int ptrace_attach(struct task_str +@@ -266,7 +279,7 @@ static int ptrace_attach(struct task_struct *task, l= ong request, task->ptrace =3D PT_PTRACED; if (seize) task->ptrace |=3D PT_SEIZED; @@ -65929,7 +67578,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c task->ptrace |=3D PT_PTRACE_CAP; =20 __ptrace_link(task, current); -@@ -461,6 +474,8 @@ int ptrace_readdata(struct task_struct * +@@ -461,6 +474,8 @@ int ptrace_readdata(struct task_struct *tsk, unsigne= d long src, char __user *dst { int copied =3D 0; =20 @@ -65938,7 +67587,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c while (len > 0) { char buf[128]; int this_len, retval; -@@ -472,7 +487,7 @@ int ptrace_readdata(struct task_struct * +@@ -472,7 +487,7 @@ int ptrace_readdata(struct task_struct *tsk, unsigne= d long src, char __user *dst break; return -EIO; } @@ -65947,7 +67596,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c return -EFAULT; copied +=3D retval; src +=3D retval; -@@ -486,6 +501,8 @@ int ptrace_writedata(struct task_struct=20 +@@ -486,6 +501,8 @@ int ptrace_writedata(struct task_struct *tsk, char _= _user *src, unsigned long ds { int copied =3D 0; =20 @@ -65956,7 +67605,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c while (len > 0) { char buf[128]; int this_len, retval; -@@ -669,10 +686,12 @@ int ptrace_request(struct task_struct *c +@@ -669,10 +686,12 @@ int ptrace_request(struct task_struct *child, long= request, bool seized =3D child->ptrace & PT_SEIZED; int ret =3D -EIO; siginfo_t siginfo, *si; @@ -65970,7 +67619,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c switch (request) { case PTRACE_PEEKTEXT: case PTRACE_PEEKDATA: -@@ -871,14 +890,21 @@ SYSCALL_DEFINE4(ptrace, long, request, l +@@ -871,14 +890,21 @@ SYSCALL_DEFINE4(ptrace, long, request, long, pid, = unsigned long, addr, goto out; } =20 @@ -65993,7 +67642,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c goto out_put_task_struct; } =20 -@@ -904,7 +930,7 @@ int generic_ptrace_peekdata(struct task_ +@@ -904,7 +930,7 @@ int generic_ptrace_peekdata(struct task_struct *tsk,= unsigned long addr, copied =3D access_process_vm(tsk, addr, &tmp, sizeof(tmp), 0); if (copied !=3D sizeof(tmp)) return -EIO; @@ -66002,7 +67651,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c } =20 int generic_ptrace_pokedata(struct task_struct *tsk, unsigned long addr= , -@@ -927,6 +953,8 @@ int compat_ptrace_request(struct task_st +@@ -927,6 +953,8 @@ int compat_ptrace_request(struct task_struct *child,= compat_long_t request, siginfo_t siginfo; int ret; =20 @@ -66011,7 +67660,7 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.1.= 4/kernel/ptrace.c switch (request) { case PTRACE_PEEKTEXT: case PTRACE_PEEKDATA: -@@ -1014,14 +1042,21 @@ asmlinkage long compat_sys_ptrace(compat +@@ -1014,14 +1042,21 @@ asmlinkage long compat_sys_ptrace(compat_long_t = request, compat_long_t pid, goto out; } =20 @@ -66034,10 +67683,11 @@ diff -urNp linux-3.1.4/kernel/ptrace.c linux-3.= 1.4/kernel/ptrace.c goto out_put_task_struct; } =20 -diff -urNp linux-3.1.4/kernel/rcutorture.c linux-3.1.4/kernel/rcutorture= .c ---- linux-3.1.4/kernel/rcutorture.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/rcutorture.c 2011-11-16 18:39:08.000000000 -0500 -@@ -138,12 +138,12 @@ static DEFINE_PER_CPU(long [RCU_TORTURE_ +diff --git a/kernel/rcutorture.c b/kernel/rcutorture.c +index 98f51b1..30b950c 100644 +--- a/kernel/rcutorture.c ++++ b/kernel/rcutorture.c +@@ -138,12 +138,12 @@ static DEFINE_PER_CPU(long [RCU_TORTURE_PIPE_LEN += 1], rcu_torture_count) =3D { 0 }; static DEFINE_PER_CPU(long [RCU_TORTURE_PIPE_LEN + 1], rcu_torture_batc= h) =3D { 0 }; @@ -66088,7 +67738,7 @@ diff -urNp linux-3.1.4/kernel/rcutorture.c linux-= 3.1.4/kernel/rcutorture.c if (++rp->rtort_pipe_count >=3D RCU_TORTURE_PIPE_LEN) { rp->rtort_mbtest =3D 0; rcu_torture_free(rp); -@@ -407,7 +407,7 @@ static void rcu_sync_torture_deferred_fr +@@ -407,7 +407,7 @@ static void rcu_sync_torture_deferred_free(struct rc= u_torture *p) i =3D rp->rtort_pipe_count; if (i > RCU_TORTURE_PIPE_LEN) i =3D RCU_TORTURE_PIPE_LEN; @@ -66106,7 +67756,7 @@ diff -urNp linux-3.1.4/kernel/rcutorture.c linux-= 3.1.4/kernel/rcutorture.c old_rp->rtort_pipe_count++; cur_ops->deferred_free(old_rp); } -@@ -950,7 +950,7 @@ static void rcu_torture_timer(unsigned l +@@ -950,7 +950,7 @@ static void rcu_torture_timer(unsigned long unused) return; } if (p->rtort_mbtest =3D=3D 0) @@ -66197,9 +67847,10 @@ diff -urNp linux-3.1.4/kernel/rcutorture.c linux= -3.1.4/kernel/rcutorture.c for_each_possible_cpu(cpu) { for (i =3D 0; i < RCU_TORTURE_PIPE_LEN + 1; i++) { per_cpu(rcu_torture_count, cpu)[i] =3D 0; -diff -urNp linux-3.1.4/kernel/rcutree.c linux-3.1.4/kernel/rcutree.c ---- linux-3.1.4/kernel/rcutree.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/rcutree.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/rcutree.c b/kernel/rcutree.c +index ba06207..85d8ba8 100644 +--- a/kernel/rcutree.c ++++ b/kernel/rcutree.c @@ -356,9 +356,9 @@ void rcu_enter_nohz(void) } /* CPUs seeing atomic_inc() must see prior RCU read-side crit sects */ @@ -66264,7 +67915,7 @@ diff -urNp linux-3.1.4/kernel/rcutree.c linux-3.1= .4/kernel/rcutree.c return 0; } =20 -@@ -484,7 +484,7 @@ static int rcu_implicit_dynticks_qs(stru +@@ -484,7 +484,7 @@ static int rcu_implicit_dynticks_qs(struct rcu_data = *rdp) unsigned long curr; unsigned long snap; =20 @@ -66273,7 +67924,7 @@ diff -urNp linux-3.1.4/kernel/rcutree.c linux-3.1= .4/kernel/rcutree.c snap =3D (unsigned long)rdp->dynticks_snap; =20 /* -@@ -1470,7 +1470,7 @@ __rcu_process_callbacks(struct rcu_state +@@ -1470,7 +1470,7 @@ __rcu_process_callbacks(struct rcu_state *rsp, str= uct rcu_data *rdp) /* * Do softirq processing for the current CPU. */ @@ -66282,9 +67933,10 @@ diff -urNp linux-3.1.4/kernel/rcutree.c linux-3.= 1.4/kernel/rcutree.c { __rcu_process_callbacks(&rcu_sched_state, &__get_cpu_var(rcu_sched_data)); -diff -urNp linux-3.1.4/kernel/rcutree.h linux-3.1.4/kernel/rcutree.h ---- linux-3.1.4/kernel/rcutree.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/rcutree.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/rcutree.h b/kernel/rcutree.h +index 01b2ccd..4f5d80a 100644 +--- a/kernel/rcutree.h ++++ b/kernel/rcutree.h @@ -86,7 +86,7 @@ struct rcu_dynticks { int dynticks_nesting; /* Track irq/process nesting level. */ @@ -66294,9 +67946,10 @@ diff -urNp linux-3.1.4/kernel/rcutree.h linux-3.= 1.4/kernel/rcutree.h }; =20 /* RCU's kthread states for tracing. */ -diff -urNp linux-3.1.4/kernel/rcutree_plugin.h linux-3.1.4/kernel/rcutre= e_plugin.h ---- linux-3.1.4/kernel/rcutree_plugin.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/kernel/rcutree_plugin.h 2011-12-02 17:38:47.000000000 -0= 500 +diff --git a/kernel/rcutree_plugin.h b/kernel/rcutree_plugin.h +index 8aafbb8..2fca109 100644 +--- a/kernel/rcutree_plugin.h ++++ b/kernel/rcutree_plugin.h @@ -822,7 +822,7 @@ void synchronize_rcu_expedited(void) =20 /* Clean up and exit. */ @@ -66306,7 +67959,7 @@ diff -urNp linux-3.1.4/kernel/rcutree_plugin.h li= nux-3.1.4/kernel/rcutree_plugin unlock_mb_ret: mutex_unlock(&sync_rcu_preempt_exp_mutex); mb_ret: -@@ -1774,8 +1774,8 @@ EXPORT_SYMBOL_GPL(synchronize_sched_expe +@@ -1774,8 +1774,8 @@ EXPORT_SYMBOL_GPL(synchronize_sched_expedited); =20 #else /* #ifndef CONFIG_SMP */ =20 @@ -66368,10 +68021,11 @@ diff -urNp linux-3.1.4/kernel/rcutree_plugin.h = linux-3.1.4/kernel/rcutree_plugin thatcpu).dynticks); smp_mb(); /* Order sampling of snap with end of grace period. */ if ((snap & 0x1) !=3D 0) { -diff -urNp linux-3.1.4/kernel/rcutree_trace.c linux-3.1.4/kernel/rcutree= _trace.c ---- linux-3.1.4/kernel/rcutree_trace.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/kernel/rcutree_trace.c 2011-12-02 17:38:47.000000000 -05= 00 -@@ -74,7 +74,7 @@ static void print_one_rcu_data(struct se +diff --git a/kernel/rcutree_trace.c b/kernel/rcutree_trace.c +index 3b0c098..43ba2d8 100644 +--- a/kernel/rcutree_trace.c ++++ b/kernel/rcutree_trace.c +@@ -74,7 +74,7 @@ static void print_one_rcu_data(struct seq_file *m, str= uct rcu_data *rdp) rdp->qs_pending); #ifdef CONFIG_NO_HZ seq_printf(m, " dt=3D%d/%d/%d df=3D%lu", @@ -66380,7 +68034,7 @@ diff -urNp linux-3.1.4/kernel/rcutree_trace.c lin= ux-3.1.4/kernel/rcutree_trace.c rdp->dynticks->dynticks_nesting, rdp->dynticks->dynticks_nmi_nesting, rdp->dynticks_fqs); -@@ -148,7 +148,7 @@ static void print_one_rcu_data_csv(struc +@@ -148,7 +148,7 @@ static void print_one_rcu_data_csv(struct seq_file *= m, struct rcu_data *rdp) rdp->qs_pending); #ifdef CONFIG_NO_HZ seq_printf(m, ",%d,%d,%d,%lu", @@ -66389,10 +68043,11 @@ diff -urNp linux-3.1.4/kernel/rcutree_trace.c l= inux-3.1.4/kernel/rcutree_trace.c rdp->dynticks->dynticks_nesting, rdp->dynticks->dynticks_nmi_nesting, rdp->dynticks_fqs); -diff -urNp linux-3.1.4/kernel/relay.c linux-3.1.4/kernel/relay.c ---- linux-3.1.4/kernel/relay.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/relay.c 2011-11-16 18:40:44.000000000 -0500 -@@ -1236,6 +1236,8 @@ static ssize_t subbuf_splice_actor(struc +diff --git a/kernel/relay.c b/kernel/relay.c +index 859ea5a..096e2fe 100644 +--- a/kernel/relay.c ++++ b/kernel/relay.c +@@ -1236,6 +1236,8 @@ static ssize_t subbuf_splice_actor(struct file *in= , }; ssize_t ret; =20 @@ -66401,10 +68056,11 @@ diff -urNp linux-3.1.4/kernel/relay.c linux-3.1= .4/kernel/relay.c if (rbuf->subbufs_produced =3D=3D rbuf->subbufs_consumed) return 0; if (splice_grow_spd(pipe, &spd)) -diff -urNp linux-3.1.4/kernel/resource.c linux-3.1.4/kernel/resource.c ---- linux-3.1.4/kernel/resource.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/resource.c 2011-11-16 18:40:44.000000000 -0500 -@@ -141,8 +141,18 @@ static const struct file_operations proc +diff --git a/kernel/resource.c b/kernel/resource.c +index c8dc249..f1e2359 100644 +--- a/kernel/resource.c ++++ b/kernel/resource.c +@@ -141,8 +141,18 @@ static const struct file_operations proc_iomem_oper= ations =3D { =20 static int __init ioresources_init(void) { @@ -66423,9 +68079,10 @@ diff -urNp linux-3.1.4/kernel/resource.c linux-3= .1.4/kernel/resource.c return 0; } __initcall(ioresources_init); -diff -urNp linux-3.1.4/kernel/rtmutex-tester.c linux-3.1.4/kernel/rtmute= x-tester.c ---- linux-3.1.4/kernel/rtmutex-tester.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/kernel/rtmutex-tester.c 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/kernel/rtmutex-tester.c b/kernel/rtmutex-tester.c +index 5c9ccd3..a35e22b 100644 +--- a/kernel/rtmutex-tester.c ++++ b/kernel/rtmutex-tester.c @@ -20,7 +20,7 @@ #define MAX_RT_TEST_MUTEXES 8 =20 @@ -66435,7 +68092,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester =20 struct test_thread_data { int opcode; -@@ -61,7 +61,7 @@ static int handle_op(struct test_thread_ +@@ -61,7 +61,7 @@ static int handle_op(struct test_thread_data *td, int = lockwakeup) =20 case RTTEST_LOCKCONT: td->mutexes[td->opdata] =3D 1; @@ -66444,7 +68101,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester return 0; =20 case RTTEST_RESET: -@@ -74,7 +74,7 @@ static int handle_op(struct test_thread_ +@@ -74,7 +74,7 @@ static int handle_op(struct test_thread_data *td, int = lockwakeup) return 0; =20 case RTTEST_RESETEVENT: @@ -66453,7 +68110,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester return 0; =20 default: -@@ -91,9 +91,9 @@ static int handle_op(struct test_thread_ +@@ -91,9 +91,9 @@ static int handle_op(struct test_thread_data *td, int = lockwakeup) return ret; =20 td->mutexes[id] =3D 1; @@ -66465,7 +68122,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester td->mutexes[id] =3D 4; return 0; =20 -@@ -104,9 +104,9 @@ static int handle_op(struct test_thread_ +@@ -104,9 +104,9 @@ static int handle_op(struct test_thread_data *td, in= t lockwakeup) return ret; =20 td->mutexes[id] =3D 1; @@ -66477,7 +68134,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester td->mutexes[id] =3D ret ? 0 : 4; return ret ? -EINTR : 0; =20 -@@ -115,9 +115,9 @@ static int handle_op(struct test_thread_ +@@ -115,9 +115,9 @@ static int handle_op(struct test_thread_data *td, in= t lockwakeup) if (id < 0 || id >=3D MAX_RT_TEST_MUTEXES || td->mutexes[id] !=3D 4) return ret; =20 @@ -66489,7 +68146,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester td->mutexes[id] =3D 0; return 0; =20 -@@ -164,7 +164,7 @@ void schedule_rt_mutex_test(struct rt_mu +@@ -164,7 +164,7 @@ void schedule_rt_mutex_test(struct rt_mutex *mutex) break; =20 td->mutexes[dat] =3D 2; @@ -66498,7 +68155,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester break; =20 default: -@@ -184,7 +184,7 @@ void schedule_rt_mutex_test(struct rt_mu +@@ -184,7 +184,7 @@ void schedule_rt_mutex_test(struct rt_mutex *mutex) return; =20 td->mutexes[dat] =3D 3; @@ -66507,7 +68164,7 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c li= nux-3.1.4/kernel/rtmutex-tester break; =20 case RTTEST_LOCKNOWAIT: -@@ -196,7 +196,7 @@ void schedule_rt_mutex_test(struct rt_mu +@@ -196,7 +196,7 @@ void schedule_rt_mutex_test(struct rt_mutex *mutex) return; =20 td->mutexes[dat] =3D 1; @@ -66516,30 +68173,10 @@ diff -urNp linux-3.1.4/kernel/rtmutex-tester.c = linux-3.1.4/kernel/rtmutex-tester return; =20 default: -diff -urNp linux-3.1.4/kernel/sched_autogroup.c linux-3.1.4/kernel/sched= _autogroup.c ---- linux-3.1.4/kernel/sched_autogroup.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/kernel/sched_autogroup.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -7,7 +7,7 @@ -=20 - unsigned int __read_mostly sysctl_sched_autogroup_enabled =3D 1; - static struct autogroup autogroup_default; --static atomic_t autogroup_seq_nr; -+static atomic_unchecked_t autogroup_seq_nr; -=20 - static void __init autogroup_init(struct task_struct *init_task) - { -@@ -78,7 +78,7 @@ static inline struct autogroup *autogrou -=20 - kref_init(&ag->kref); - init_rwsem(&ag->lock); -- ag->id =3D atomic_inc_return(&autogroup_seq_nr); -+ ag->id =3D atomic_inc_return_unchecked(&autogroup_seq_nr); - ag->tg =3D tg; - #ifdef CONFIG_RT_GROUP_SCHED - /* -diff -urNp linux-3.1.4/kernel/sched.c linux-3.1.4/kernel/sched.c ---- linux-3.1.4/kernel/sched.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/sched.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/sched.c b/kernel/sched.c +index b50b0f0..1c6c591 100644 +--- a/kernel/sched.c ++++ b/kernel/sched.c @@ -4264,6 +4264,8 @@ static void __sched __schedule(void) struct rq *rq; int cpu; @@ -66549,7 +68186,7 @@ diff -urNp linux-3.1.4/kernel/sched.c linux-3.1.4= /kernel/sched.c need_resched: preempt_disable(); cpu =3D smp_processor_id(); -@@ -4950,6 +4952,8 @@ int can_nice(const struct task_struct *p +@@ -4950,6 +4952,8 @@ int can_nice(const struct task_struct *p, const in= t nice) /* convert nice value [19,-20] to rlimit style value [1,40] */ int nice_rlim =3D 20 - nice; =20 @@ -66576,10 +68213,33 @@ diff -urNp linux-3.1.4/kernel/sched.c linux-3.1= .4/kernel/sched.c /* can't set/change the rt policy */ if (policy !=3D p->policy && !rlim_rtprio) return -EPERM; -diff -urNp linux-3.1.4/kernel/sched_fair.c linux-3.1.4/kernel/sched_fair= .c ---- linux-3.1.4/kernel/sched_fair.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/sched_fair.c 2011-11-16 18:39:08.000000000 -0500 -@@ -4062,7 +4062,7 @@ static void nohz_idle_balance(int this_c +diff --git a/kernel/sched_autogroup.c b/kernel/sched_autogroup.c +index 429242f..d7cca82 100644 +--- a/kernel/sched_autogroup.c ++++ b/kernel/sched_autogroup.c +@@ -7,7 +7,7 @@ +=20 + unsigned int __read_mostly sysctl_sched_autogroup_enabled =3D 1; + static struct autogroup autogroup_default; +-static atomic_t autogroup_seq_nr; ++static atomic_unchecked_t autogroup_seq_nr; +=20 + static void __init autogroup_init(struct task_struct *init_task) + { +@@ -78,7 +78,7 @@ static inline struct autogroup *autogroup_create(void) +=20 + kref_init(&ag->kref); + init_rwsem(&ag->lock); +- ag->id =3D atomic_inc_return(&autogroup_seq_nr); ++ ag->id =3D atomic_inc_return_unchecked(&autogroup_seq_nr); + ag->tg =3D tg; + #ifdef CONFIG_RT_GROUP_SCHED + /* +diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c +index bc8ee99..b6f6492 100644 +--- a/kernel/sched_fair.c ++++ b/kernel/sched_fair.c +@@ -4062,7 +4062,7 @@ static void nohz_idle_balance(int this_cpu, enum c= pu_idle_type idle) { } * run_rebalance_domains is triggered when needed from the scheduler ti= ck. * Also triggered for nohz idle balancing (with nohz_balancing_kick set= ). */ @@ -66588,10 +68248,11 @@ diff -urNp linux-3.1.4/kernel/sched_fair.c linu= x-3.1.4/kernel/sched_fair.c { int this_cpu =3D smp_processor_id(); struct rq *this_rq =3D cpu_rq(this_cpu); -diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.4/kernel/signal.c ---- linux-3.1.4/kernel/signal.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/signal.c 2011-11-16 19:30:04.000000000 -0500 -@@ -45,12 +45,12 @@ static struct kmem_cache *sigqueue_cache +diff --git a/kernel/signal.c b/kernel/signal.c +index 291c970..304bd03 100644 +--- a/kernel/signal.c ++++ b/kernel/signal.c +@@ -45,12 +45,12 @@ static struct kmem_cache *sigqueue_cachep; =20 int print_fatal_signals __read_mostly; =20 @@ -66606,7 +68267,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c { /* Is it explicitly or implicitly ignored? */ return handler =3D=3D SIG_IGN || -@@ -60,7 +60,7 @@ static int sig_handler_ignored(void __us +@@ -60,7 +60,7 @@ static int sig_handler_ignored(void __user *handler, i= nt sig) static int sig_task_ignored(struct task_struct *t, int sig, int from_ancestor_ns) { @@ -66615,7 +68276,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c =20 handler =3D sig_handler(t, sig); =20 -@@ -364,6 +364,9 @@ __sigqueue_alloc(int sig, struct task_st +@@ -364,6 +364,9 @@ __sigqueue_alloc(int sig, struct task_struct *t, gfp= _t flags, int override_rlimi atomic_inc(&user->sigpending); rcu_read_unlock(); =20 @@ -66625,7 +68286,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c if (override_rlimit || atomic_read(&user->sigpending) <=3D task_rlimit(t, RLIMIT_SIGPENDING)) { -@@ -488,7 +491,7 @@ flush_signal_handlers(struct task_struct +@@ -488,7 +491,7 @@ flush_signal_handlers(struct task_struct *t, int for= ce_default) =20 int unhandled_signal(struct task_struct *tsk, int sig) { @@ -66634,7 +68295,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c if (is_global_init(tsk)) return 1; if (handler !=3D SIG_IGN && handler !=3D SIG_DFL) -@@ -815,6 +818,13 @@ static int check_kill_permission(int sig +@@ -815,6 +818,13 @@ static int check_kill_permission(int sig, struct si= ginfo *info, } } =20 @@ -66648,7 +68309,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c return security_task_kill(t, info, sig, 0); } =20 -@@ -1165,7 +1175,7 @@ __group_send_sig_info(int sig, struct si +@@ -1165,7 +1175,7 @@ __group_send_sig_info(int sig, struct siginfo *inf= o, struct task_struct *p) return send_signal(sig, info, p, 1); } =20 @@ -66657,7 +68318,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c specific_send_sig_info(int sig, struct siginfo *info, struct task_struc= t *t) { return send_signal(sig, info, t, 0); -@@ -1202,6 +1212,7 @@ force_sig_info(int sig, struct siginfo * +@@ -1202,6 +1212,7 @@ force_sig_info(int sig, struct siginfo *info, stru= ct task_struct *t) unsigned long int flags; int ret, blocked, ignored; struct k_sigaction *action; @@ -66665,7 +68326,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c =20 spin_lock_irqsave(&t->sighand->siglock, flags); action =3D &t->sighand->action[sig-1]; -@@ -1216,9 +1227,18 @@ force_sig_info(int sig, struct siginfo * +@@ -1216,9 +1227,18 @@ force_sig_info(int sig, struct siginfo *info, str= uct task_struct *t) } if (action->sa.sa_handler =3D=3D SIG_DFL) t->signal->flags &=3D ~SIGNAL_UNKILLABLE; @@ -66684,7 +68345,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c return ret; } =20 -@@ -1285,8 +1305,11 @@ int group_send_sig_info(int sig, struct=20 +@@ -1285,8 +1305,11 @@ int group_send_sig_info(int sig, struct siginfo *= info, struct task_struct *p) ret =3D check_kill_permission(sig, info, p); rcu_read_unlock(); =20 @@ -66697,7 +68358,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c =20 return ret; } -@@ -1909,6 +1932,8 @@ static void ptrace_do_notify(int signr,=20 +@@ -1909,6 +1932,8 @@ static void ptrace_do_notify(int signr, int exit_c= ode, int why) { siginfo_t info; =20 @@ -66706,7 +68367,7 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.1.= 4/kernel/signal.c memset(&info, 0, sizeof info); info.si_signo =3D signr; info.si_code =3D exit_code; -@@ -2748,7 +2773,15 @@ do_send_specific(pid_t tgid, pid_t pid,=20 +@@ -2748,7 +2773,15 @@ do_send_specific(pid_t tgid, pid_t pid, int sig, = struct siginfo *info) int error =3D -ESRCH; =20 rcu_read_lock(); @@ -66723,10 +68384,11 @@ diff -urNp linux-3.1.4/kernel/signal.c linux-3.= 1.4/kernel/signal.c if (p && (tgid <=3D 0 || task_tgid_vnr(p) =3D=3D tgid)) { error =3D check_kill_permission(sig, info, p); /* -diff -urNp linux-3.1.4/kernel/smp.c linux-3.1.4/kernel/smp.c ---- linux-3.1.4/kernel/smp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/smp.c 2011-11-16 18:39:08.000000000 -0500 -@@ -580,22 +580,22 @@ int smp_call_function(smp_call_func_t fu +diff --git a/kernel/smp.c b/kernel/smp.c +index fb67dfa..f819e2e 100644 +--- a/kernel/smp.c ++++ b/kernel/smp.c +@@ -580,22 +580,22 @@ int smp_call_function(smp_call_func_t func, void *= info, int wait) } EXPORT_SYMBOL(smp_call_function); =20 @@ -66753,10 +68415,11 @@ diff -urNp linux-3.1.4/kernel/smp.c linux-3.1.4= /kernel/smp.c { raw_spin_unlock_irq(&call_function.lock); } -diff -urNp linux-3.1.4/kernel/softirq.c linux-3.1.4/kernel/softirq.c ---- linux-3.1.4/kernel/softirq.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/softirq.c 2011-11-16 18:39:08.000000000 -0500 -@@ -56,7 +56,7 @@ static struct softirq_action softirq_vec +diff --git a/kernel/softirq.c b/kernel/softirq.c +index fca82c3..1db9690 100644 +--- a/kernel/softirq.c ++++ b/kernel/softirq.c +@@ -56,7 +56,7 @@ static struct softirq_action softirq_vec[NR_SOFTIRQS] = __cacheline_aligned_in_smp =20 DEFINE_PER_CPU(struct task_struct *, ksoftirqd); =20 @@ -66788,7 +68451,7 @@ diff -urNp linux-3.1.4/kernel/softirq.c linux-3.1= .4/kernel/softirq.c } =20 /* -@@ -441,7 +443,7 @@ void __tasklet_hi_schedule_first(struct=20 +@@ -441,7 +443,7 @@ void __tasklet_hi_schedule_first(struct tasklet_stru= ct *t) =20 EXPORT_SYMBOL(__tasklet_hi_schedule_first); =20 @@ -66797,7 +68460,7 @@ diff -urNp linux-3.1.4/kernel/softirq.c linux-3.1= .4/kernel/softirq.c { struct tasklet_struct *list; =20 -@@ -476,7 +478,7 @@ static void tasklet_action(struct softir +@@ -476,7 +478,7 @@ static void tasklet_action(struct softirq_action *a) } } =20 @@ -66806,10 +68469,11 @@ diff -urNp linux-3.1.4/kernel/softirq.c linux-3= .1.4/kernel/softirq.c { struct tasklet_struct *list; =20 -diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4/kernel/sys.c ---- linux-3.1.4/kernel/sys.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/sys.c 2011-11-16 18:40:44.000000000 -0500 -@@ -157,6 +157,12 @@ static int set_one_prio(struct task_stru +diff --git a/kernel/sys.c b/kernel/sys.c +index 1dbbe69..e96e1dd 100644 +--- a/kernel/sys.c ++++ b/kernel/sys.c +@@ -157,6 +157,12 @@ static int set_one_prio(struct task_struct *p, int = niceval, int error) error =3D -EACCES; goto out; } @@ -66822,7 +68486,7 @@ diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4/k= ernel/sys.c no_nice =3D security_task_setnice(p, niceval); if (no_nice) { error =3D no_nice; -@@ -571,6 +577,9 @@ SYSCALL_DEFINE2(setregid, gid_t, rgid, g +@@ -571,6 +577,9 @@ SYSCALL_DEFINE2(setregid, gid_t, rgid, gid_t, egid) goto error; } =20 @@ -66843,7 +68507,7 @@ diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4/k= ernel/sys.c if (nsown_capable(CAP_SETGID)) new->gid =3D new->egid =3D new->sgid =3D new->fsgid =3D gid; else if (gid =3D=3D old->gid || gid =3D=3D old->sgid) -@@ -687,6 +700,9 @@ SYSCALL_DEFINE2(setreuid, uid_t, ruid, u +@@ -687,6 +700,9 @@ SYSCALL_DEFINE2(setreuid, uid_t, ruid, uid_t, euid) goto error; } =20 @@ -66866,7 +68530,7 @@ diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4/k= ernel/sys.c if (nsown_capable(CAP_SETUID)) { new->suid =3D new->uid =3D uid; if (uid !=3D old->uid) { -@@ -785,6 +807,9 @@ SYSCALL_DEFINE3(setresuid, uid_t, ruid,=20 +@@ -785,6 +807,9 @@ SYSCALL_DEFINE3(setresuid, uid_t, ruid, uid_t, euid,= uid_t, suid) goto error; } =20 @@ -66876,7 +68540,7 @@ diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4/k= ernel/sys.c if (ruid !=3D (uid_t) -1) { new->uid =3D ruid; if (ruid !=3D old->uid) { -@@ -849,6 +874,9 @@ SYSCALL_DEFINE3(setresgid, gid_t, rgid,=20 +@@ -849,6 +874,9 @@ SYSCALL_DEFINE3(setresgid, gid_t, rgid, gid_t, egid,= gid_t, sgid) goto error; } =20 @@ -66921,7 +68585,19 @@ diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4/= kernel/sys.c abort_creds(new); return old_fsgid; =20 -@@ -1242,19 +1278,19 @@ SYSCALL_DEFINE1(olduname, struct oldold_ +@@ -1188,7 +1224,10 @@ static int override_release(char __user *release,= int len) + } + v =3D ((LINUX_VERSION_CODE >> 8) & 0xff) + 40; + snprintf(buf, len, "2.6.%u%s", v, rest); +- ret =3D copy_to_user(release, buf, len); ++ if (len > sizeof(buf)) ++ ret =3D -EFAULT; ++ else ++ ret =3D copy_to_user(release, buf, len); + } + return ret; + } +@@ -1242,19 +1281,19 @@ SYSCALL_DEFINE1(olduname, struct oldold_utsname = __user *, name) return -EFAULT; =20 down_read(&uts_sem); @@ -66946,7 +68622,7 @@ diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4/k= ernel/sys.c __OLD_UTS_LEN); error |=3D __put_user(0, name->machine + __OLD_UTS_LEN); up_read(&uts_sem); -@@ -1717,7 +1753,7 @@ SYSCALL_DEFINE5(prctl, int, option, unsi +@@ -1717,7 +1756,7 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long,= arg2, unsigned long, arg3, error =3D get_dumpable(me->mm); break; case PR_SET_DUMPABLE: @@ -66955,75 +68631,10 @@ diff -urNp linux-3.1.4/kernel/sys.c linux-3.1.4= /kernel/sys.c error =3D -EINVAL; break; } -diff -urNp linux-3.1.4/kernel/sysctl_binary.c linux-3.1.4/kernel/sysctl_= binary.c ---- linux-3.1.4/kernel/sysctl_binary.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/kernel/sysctl_binary.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -989,7 +989,7 @@ static ssize_t bin_intvec(struct file *f - int i; -=20 - set_fs(KERNEL_DS); -- result =3D vfs_read(file, buffer, BUFSZ - 1, &pos); -+ result =3D vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &po= s); - set_fs(old_fs); - if (result < 0) - goto out_kfree; -@@ -1034,7 +1034,7 @@ static ssize_t bin_intvec(struct file *f - } -=20 - set_fs(KERNEL_DS); -- result =3D vfs_write(file, buffer, str - buffer, &pos); -+ result =3D vfs_write(file, (const char __force_user *)buffer, str - b= uffer, &pos); - set_fs(old_fs); - if (result < 0) - goto out_kfree; -@@ -1067,7 +1067,7 @@ static ssize_t bin_ulongvec(struct file=20 - int i; -=20 - set_fs(KERNEL_DS); -- result =3D vfs_read(file, buffer, BUFSZ - 1, &pos); -+ result =3D vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &po= s); - set_fs(old_fs); - if (result < 0) - goto out_kfree; -@@ -1112,7 +1112,7 @@ static ssize_t bin_ulongvec(struct file=20 - } -=20 - set_fs(KERNEL_DS); -- result =3D vfs_write(file, buffer, str - buffer, &pos); -+ result =3D vfs_write(file, (const char __force_user *)buffer, str - b= uffer, &pos); - set_fs(old_fs); - if (result < 0) - goto out_kfree; -@@ -1138,7 +1138,7 @@ static ssize_t bin_uuid(struct file *fil - int i; -=20 - set_fs(KERNEL_DS); -- result =3D vfs_read(file, buf, sizeof(buf) - 1, &pos); -+ result =3D vfs_read(file, (char __force_user *)buf, sizeof(buf) - 1, = &pos); - set_fs(old_fs); - if (result < 0) - goto out; -@@ -1185,7 +1185,7 @@ static ssize_t bin_dn_node_address(struc - __le16 dnaddr; -=20 - set_fs(KERNEL_DS); -- result =3D vfs_read(file, buf, sizeof(buf) - 1, &pos); -+ result =3D vfs_read(file, (char __force_user *)buf, sizeof(buf) - 1, = &pos); - set_fs(old_fs); - if (result < 0) - goto out; -@@ -1233,7 +1233,7 @@ static ssize_t bin_dn_node_address(struc - le16_to_cpu(dnaddr) & 0x3ff); -=20 - set_fs(KERNEL_DS); -- result =3D vfs_write(file, buf, len, &pos); -+ result =3D vfs_write(file, (const char __force_user *)buf, len, &pos)= ; - set_fs(old_fs); - if (result < 0) - goto out; -diff -urNp linux-3.1.4/kernel/sysctl.c linux-3.1.4/kernel/sysctl.c ---- linux-3.1.4/kernel/sysctl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/sysctl.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/kernel/sysctl.c b/kernel/sysctl.c +index 11d65b5..6957b37 100644 +--- a/kernel/sysctl.c ++++ b/kernel/sysctl.c @@ -85,6 +85,13 @@ =20 =20 @@ -67038,7 +68649,7 @@ diff -urNp linux-3.1.4/kernel/sysctl.c linux-3.1.= 4/kernel/sysctl.c =20 /* External variables not in a header file. */ extern int sysctl_overcommit_memory; -@@ -197,6 +204,7 @@ static int sysrq_sysctl_handler(ctl_tabl +@@ -197,6 +204,7 @@ static int sysrq_sysctl_handler(ctl_table *table, in= t write, } =20 #endif @@ -67153,7 +68764,7 @@ diff -urNp linux-3.1.4/kernel/sysctl.c linux-3.1.= 4/kernel/sysctl.c =20 if (root->permissions) mode =3D root->permissions(root, current->nsproxy, table); -@@ -2113,6 +2173,16 @@ int proc_dostring(struct ctl_table *tabl +@@ -2113,6 +2173,16 @@ int proc_dostring(struct ctl_table *table, int wr= ite, buffer, lenp, ppos); } =20 @@ -67170,7 +68781,7 @@ diff -urNp linux-3.1.4/kernel/sysctl.c linux-3.1.= 4/kernel/sysctl.c static size_t proc_skip_spaces(char **buf) { size_t ret; -@@ -2218,6 +2288,8 @@ static int proc_put_long(void __user **b +@@ -2218,6 +2288,8 @@ static int proc_put_long(void __user **buf, size_t= *size, unsigned long val, len =3D strlen(tmp); if (len > *size) len =3D *size; @@ -67179,7 +68790,7 @@ diff -urNp linux-3.1.4/kernel/sysctl.c linux-3.1.= 4/kernel/sysctl.c if (copy_to_user(*buf, tmp, len)) return -EFAULT; *size -=3D len; -@@ -2534,8 +2606,11 @@ static int __do_proc_doulongvec_minmax(v +@@ -2534,8 +2606,11 @@ static int __do_proc_doulongvec_minmax(void *data= , struct ctl_table *table, int *i =3D val; } else { val =3D convdiv * (*i) / convmul; @@ -67192,7 +68803,7 @@ diff -urNp linux-3.1.4/kernel/sysctl.c linux-3.1.= 4/kernel/sysctl.c err =3D proc_put_long(&buffer, &left, val, false); if (err) break; -@@ -2930,6 +3005,12 @@ int proc_dostring(struct ctl_table *tabl +@@ -2930,6 +3005,12 @@ int proc_dostring(struct ctl_table *table, int wr= ite, return -ENOSYS; } =20 @@ -67213,10 +68824,78 @@ diff -urNp linux-3.1.4/kernel/sysctl.c linux-3.= 1.4/kernel/sysctl.c EXPORT_SYMBOL(proc_doulongvec_minmax); EXPORT_SYMBOL(proc_doulongvec_ms_jiffies_minmax); EXPORT_SYMBOL(register_sysctl_table); -diff -urNp linux-3.1.4/kernel/sysctl_check.c linux-3.1.4/kernel/sysctl_c= heck.c ---- linux-3.1.4/kernel/sysctl_check.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/kernel/sysctl_check.c 2011-11-16 18:40:44.000000000 -050= 0 -@@ -129,6 +129,7 @@ int sysctl_check_table(struct nsproxy *n +diff --git a/kernel/sysctl_binary.c b/kernel/sysctl_binary.c +index e8bffbe..2344401 100644 +--- a/kernel/sysctl_binary.c ++++ b/kernel/sysctl_binary.c +@@ -989,7 +989,7 @@ static ssize_t bin_intvec(struct file *file, + int i; +=20 + set_fs(KERNEL_DS); +- result =3D vfs_read(file, buffer, BUFSZ - 1, &pos); ++ result =3D vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &po= s); + set_fs(old_fs); + if (result < 0) + goto out_kfree; +@@ -1034,7 +1034,7 @@ static ssize_t bin_intvec(struct file *file, + } +=20 + set_fs(KERNEL_DS); +- result =3D vfs_write(file, buffer, str - buffer, &pos); ++ result =3D vfs_write(file, (const char __force_user *)buffer, str - b= uffer, &pos); + set_fs(old_fs); + if (result < 0) + goto out_kfree; +@@ -1067,7 +1067,7 @@ static ssize_t bin_ulongvec(struct file *file, + int i; +=20 + set_fs(KERNEL_DS); +- result =3D vfs_read(file, buffer, BUFSZ - 1, &pos); ++ result =3D vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &po= s); + set_fs(old_fs); + if (result < 0) + goto out_kfree; +@@ -1112,7 +1112,7 @@ static ssize_t bin_ulongvec(struct file *file, + } +=20 + set_fs(KERNEL_DS); +- result =3D vfs_write(file, buffer, str - buffer, &pos); ++ result =3D vfs_write(file, (const char __force_user *)buffer, str - b= uffer, &pos); + set_fs(old_fs); + if (result < 0) + goto out_kfree; +@@ -1138,7 +1138,7 @@ static ssize_t bin_uuid(struct file *file, + int i; +=20 + set_fs(KERNEL_DS); +- result =3D vfs_read(file, buf, sizeof(buf) - 1, &pos); ++ result =3D vfs_read(file, (char __force_user *)buf, sizeof(buf) - 1, = &pos); + set_fs(old_fs); + if (result < 0) + goto out; +@@ -1185,7 +1185,7 @@ static ssize_t bin_dn_node_address(struct file *fi= le, + __le16 dnaddr; +=20 + set_fs(KERNEL_DS); +- result =3D vfs_read(file, buf, sizeof(buf) - 1, &pos); ++ result =3D vfs_read(file, (char __force_user *)buf, sizeof(buf) - 1, = &pos); + set_fs(old_fs); + if (result < 0) + goto out; +@@ -1233,7 +1233,7 @@ static ssize_t bin_dn_node_address(struct file *fi= le, + le16_to_cpu(dnaddr) & 0x3ff); +=20 + set_fs(KERNEL_DS); +- result =3D vfs_write(file, buf, len, &pos); ++ result =3D vfs_write(file, (const char __force_user *)buf, len, &pos)= ; + set_fs(old_fs); + if (result < 0) + goto out; +diff --git a/kernel/sysctl_check.c b/kernel/sysctl_check.c +index 362da65..ab8ef8c 100644 +--- a/kernel/sysctl_check.c ++++ b/kernel/sysctl_check.c +@@ -129,6 +129,7 @@ int sysctl_check_table(struct nsproxy *namespaces, s= truct ctl_table *table) set_fail(&fail, table, "Directory with extra2"); } else { if ((table->proc_handler =3D=3D proc_dostring) || @@ -67224,9 +68903,10 @@ diff -urNp linux-3.1.4/kernel/sysctl_check.c lin= ux-3.1.4/kernel/sysctl_check.c (table->proc_handler =3D=3D proc_dointvec) || (table->proc_handler =3D=3D proc_dointvec_minmax) || (table->proc_handler =3D=3D proc_dointvec_jiffies) || -diff -urNp linux-3.1.4/kernel/taskstats.c linux-3.1.4/kernel/taskstats.c ---- linux-3.1.4/kernel/taskstats.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/taskstats.c 2011-11-16 19:35:09.000000000 -0500 +diff --git a/kernel/taskstats.c b/kernel/taskstats.c +index e660464..c8b9e67 100644 +--- a/kernel/taskstats.c ++++ b/kernel/taskstats.c @@ -27,9 +27,12 @@ #include #include @@ -67250,9 +68930,26 @@ diff -urNp linux-3.1.4/kernel/taskstats.c linux-= 3.1.4/kernel/taskstats.c if (info->attrs[TASKSTATS_CMD_ATTR_REGISTER_CPUMASK]) return cmd_attr_register_cpumask(info); else if (info->attrs[TASKSTATS_CMD_ATTR_DEREGISTER_CPUMASK]) -diff -urNp linux-3.1.4/kernel/time/alarmtimer.c linux-3.1.4/kernel/time/= alarmtimer.c ---- linux-3.1.4/kernel/time/alarmtimer.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/kernel/time/alarmtimer.c 2011-11-16 18:39:08.000000000 -= 0500 +diff --git a/kernel/time.c b/kernel/time.c +index d776062..fa8d186 100644 +--- a/kernel/time.c ++++ b/kernel/time.c +@@ -163,6 +163,11 @@ int do_sys_settimeofday(const struct timespec *tv, = const struct timezone *tz) + return error; +=20 + if (tz) { ++ /* we log in do_settimeofday called below, so don't log twice ++ */ ++ if (!tv) ++ gr_log_timechange(); ++ + /* SMP safe, global irq locking makes it work. */ + sys_tz =3D *tz; + update_vsyscall_tz(); +diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c +index ea5e1a9..8b8df07 100644 +--- a/kernel/time/alarmtimer.c ++++ b/kernel/time/alarmtimer.c @@ -693,7 +693,7 @@ static int __init alarmtimer_init(void) { int error =3D 0; @@ -67262,10 +68959,11 @@ diff -urNp linux-3.1.4/kernel/time/alarmtimer.c= linux-3.1.4/kernel/time/alarmtim .clock_getres =3D alarm_clock_getres, .clock_get =3D alarm_clock_get, .timer_create =3D alarm_timer_create, -diff -urNp linux-3.1.4/kernel/time/tick-broadcast.c linux-3.1.4/kernel/t= ime/tick-broadcast.c ---- linux-3.1.4/kernel/time/tick-broadcast.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/kernel/time/tick-broadcast.c 2011-11-16 18:39:08.0000000= 00 -0500 -@@ -115,7 +115,7 @@ int tick_device_uses_broadcast(struct cl +diff --git a/kernel/time/tick-broadcast.c b/kernel/time/tick-broadcast.c +index c7218d1..5f4ecc6 100644 +--- a/kernel/time/tick-broadcast.c ++++ b/kernel/time/tick-broadcast.c +@@ -115,7 +115,7 @@ int tick_device_uses_broadcast(struct clock_event_de= vice *dev, int cpu) * then clear the broadcast bit. */ if (!(dev->features & CLOCK_EVT_FEAT_C3STOP)) { @@ -67274,9 +68972,10 @@ diff -urNp linux-3.1.4/kernel/time/tick-broadcas= t.c linux-3.1.4/kernel/time/tick =20 cpumask_clear_cpu(cpu, tick_get_broadcast_mask()); tick_broadcast_clear_oneshot(cpu); -diff -urNp linux-3.1.4/kernel/time/timekeeping.c linux-3.1.4/kernel/time= /timekeeping.c ---- linux-3.1.4/kernel/time/timekeeping.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/kernel/time/timekeeping.c 2011-11-16 18:40:44.000000000 = -0500 +diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c +index 2b021b0e..b673a32 100644 +--- a/kernel/time/timekeeping.c ++++ b/kernel/time/timekeeping.c @@ -14,6 +14,7 @@ #include #include @@ -67285,7 +68984,7 @@ diff -urNp linux-3.1.4/kernel/time/timekeeping.c = linux-3.1.4/kernel/time/timekee #include #include #include -@@ -361,6 +362,8 @@ int do_settimeofday(const struct timespe +@@ -361,6 +362,8 @@ int do_settimeofday(const struct timespec *tv) if ((unsigned long)tv->tv_nsec >=3D NSEC_PER_SEC) return -EINVAL; =20 @@ -67294,10 +68993,11 @@ diff -urNp linux-3.1.4/kernel/time/timekeeping.= c linux-3.1.4/kernel/time/timekee write_seqlock_irqsave(&xtime_lock, flags); =20 timekeeping_forward_now(); -diff -urNp linux-3.1.4/kernel/time/timer_list.c linux-3.1.4/kernel/time/= timer_list.c ---- linux-3.1.4/kernel/time/timer_list.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/kernel/time/timer_list.c 2011-11-16 18:40:44.000000000 -= 0500 -@@ -38,12 +38,16 @@ DECLARE_PER_CPU(struct hrtimer_cpu_base, +diff --git a/kernel/time/timer_list.c b/kernel/time/timer_list.c +index 3258455..f35227d 100644 +--- a/kernel/time/timer_list.c ++++ b/kernel/time/timer_list.c +@@ -38,12 +38,16 @@ DECLARE_PER_CPU(struct hrtimer_cpu_base, hrtimer_bas= es); =20 static void print_name_offset(struct seq_file *m, void *sym) { @@ -67326,7 +69026,7 @@ diff -urNp linux-3.1.4/kernel/time/timer_list.c l= inux-3.1.4/kernel/time/timer_li SEQ_printf(m, " .index: %d\n", base->index); SEQ_printf(m, " .resolution: %Lu nsecs\n", -@@ -293,7 +301,11 @@ static int __init init_timer_list_procfs +@@ -293,7 +301,11 @@ static int __init init_timer_list_procfs(void) { struct proc_dir_entry *pe; =20 @@ -67338,9 +69038,10 @@ diff -urNp linux-3.1.4/kernel/time/timer_list.c = linux-3.1.4/kernel/time/timer_li if (!pe) return -ENOMEM; return 0; -diff -urNp linux-3.1.4/kernel/time/timer_stats.c linux-3.1.4/kernel/time= /timer_stats.c ---- linux-3.1.4/kernel/time/timer_stats.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/kernel/time/timer_stats.c 2011-11-16 18:40:44.000000000 = -0500 +diff --git a/kernel/time/timer_stats.c b/kernel/time/timer_stats.c +index a5d0a3a..60c7948 100644 +--- a/kernel/time/timer_stats.c ++++ b/kernel/time/timer_stats.c @@ -116,7 +116,7 @@ static ktime_t time_start, time_stop; static unsigned long nr_entries; static struct entry entries[MAX_ENTRIES]; @@ -67359,7 +69060,7 @@ diff -urNp linux-3.1.4/kernel/time/timer_stats.c = linux-3.1.4/kernel/time/timer_s } =20 static struct entry *alloc_entry(void) -@@ -261,7 +261,7 @@ void timer_stats_update_stats(void *time +@@ -261,7 +261,7 @@ void timer_stats_update_stats(void *timer, pid_t pid= , void *startf, if (likely(entry)) entry->count++; else @@ -67368,7 +69069,7 @@ diff -urNp linux-3.1.4/kernel/time/timer_stats.c = linux-3.1.4/kernel/time/timer_s =20 out_unlock: raw_spin_unlock_irqrestore(lock, flags); -@@ -269,12 +269,16 @@ void timer_stats_update_stats(void *time +@@ -269,12 +269,16 @@ void timer_stats_update_stats(void *timer, pid_t p= id, void *startf, =20 static void print_name_offset(struct seq_file *m, unsigned long addr) { @@ -67385,7 +69086,7 @@ diff -urNp linux-3.1.4/kernel/time/timer_stats.c = linux-3.1.4/kernel/time/timer_s } =20 static int tstats_show(struct seq_file *m, void *v) -@@ -300,9 +304,9 @@ static int tstats_show(struct seq_file * +@@ -300,9 +304,9 @@ static int tstats_show(struct seq_file *m, void *v) =20 seq_puts(m, "Timer Stats Version: v0.2\n"); seq_printf(m, "Sample period: %ld.%03ld s\n", period.tv_sec, ms); @@ -67397,7 +69098,7 @@ diff -urNp linux-3.1.4/kernel/time/timer_stats.c = linux-3.1.4/kernel/time/timer_s =20 for (i =3D 0; i < nr_entries; i++) { entry =3D entries + i; -@@ -417,7 +421,11 @@ static int __init init_tstats_procfs(voi +@@ -417,7 +421,11 @@ static int __init init_tstats_procfs(void) { struct proc_dir_entry *pe; =20 @@ -67409,24 +69110,10 @@ diff -urNp linux-3.1.4/kernel/time/timer_stats.= c linux-3.1.4/kernel/time/timer_s if (!pe) return -ENOMEM; return 0; -diff -urNp linux-3.1.4/kernel/time.c linux-3.1.4/kernel/time.c ---- linux-3.1.4/kernel/time.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/time.c 2011-11-16 18:40:44.000000000 -0500 -@@ -163,6 +163,11 @@ int do_sys_settimeofday(const struct tim - return error; -=20 - if (tz) { -+ /* we log in do_settimeofday called below, so don't log twice -+ */ -+ if (!tv) -+ gr_log_timechange(); -+ - /* SMP safe, global irq locking makes it work. */ - sys_tz =3D *tz; - update_vsyscall_tz(); -diff -urNp linux-3.1.4/kernel/timer.c linux-3.1.4/kernel/timer.c ---- linux-3.1.4/kernel/timer.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/timer.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/kernel/timer.c b/kernel/timer.c +index 8cff361..0fb5cd8 100644 +--- a/kernel/timer.c ++++ b/kernel/timer.c @@ -1304,7 +1304,7 @@ void update_process_times(int user_tick) /* * This function runs timers and the timer-tq in bottom half context. @@ -67436,10 +69123,11 @@ diff -urNp linux-3.1.4/kernel/timer.c linux-3.1= .4/kernel/timer.c { struct tvec_base *base =3D __this_cpu_read(tvec_bases); =20 -diff -urNp linux-3.1.4/kernel/trace/blktrace.c linux-3.1.4/kernel/trace/= blktrace.c ---- linux-3.1.4/kernel/trace/blktrace.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/kernel/trace/blktrace.c 2011-11-16 18:39:08.000000000 -0= 500 -@@ -323,7 +323,7 @@ static ssize_t blk_dropped_read(struct f +diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c +index 7c910a5..8b72104 100644 +--- a/kernel/trace/blktrace.c ++++ b/kernel/trace/blktrace.c +@@ -323,7 +323,7 @@ static ssize_t blk_dropped_read(struct file *filp, c= har __user *buffer, struct blk_trace *bt =3D filp->private_data; char buf[16]; =20 @@ -67448,7 +69136,7 @@ diff -urNp linux-3.1.4/kernel/trace/blktrace.c li= nux-3.1.4/kernel/trace/blktrace =20 return simple_read_from_buffer(buffer, count, ppos, buf, strlen(buf)); } -@@ -388,7 +388,7 @@ static int blk_subbuf_start_callback(str +@@ -388,7 +388,7 @@ static int blk_subbuf_start_callback(struct rchan_bu= f *buf, void *subbuf, return 1; =20 bt =3D buf->chan->private_data; @@ -67457,7 +69145,7 @@ diff -urNp linux-3.1.4/kernel/trace/blktrace.c li= nux-3.1.4/kernel/trace/blktrace return 0; } =20 -@@ -489,7 +489,7 @@ int do_blk_trace_setup(struct request_qu +@@ -489,7 +489,7 @@ int do_blk_trace_setup(struct request_queue *q, char= *name, dev_t dev, =20 bt->dir =3D dir; bt->dev =3D dev; @@ -67466,10 +69154,11 @@ diff -urNp linux-3.1.4/kernel/trace/blktrace.c = linux-3.1.4/kernel/trace/blktrace =20 ret =3D -EIO; bt->dropped_file =3D debugfs_create_file("dropped", 0444, dir, bt, -diff -urNp linux-3.1.4/kernel/trace/ftrace.c linux-3.1.4/kernel/trace/ft= race.c ---- linux-3.1.4/kernel/trace/ftrace.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/kernel/trace/ftrace.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -1585,12 +1585,17 @@ ftrace_code_disable(struct module *mod,=20 +diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c +index c3e4575..cd9c767 100644 +--- a/kernel/trace/ftrace.c ++++ b/kernel/trace/ftrace.c +@@ -1585,12 +1585,17 @@ ftrace_code_disable(struct module *mod, struct d= yn_ftrace *rec) if (unlikely(ftrace_disabled)) return 0; =20 @@ -67489,7 +69178,7 @@ diff -urNp linux-3.1.4/kernel/trace/ftrace.c linu= x-3.1.4/kernel/trace/ftrace.c } =20 /* -@@ -2607,7 +2612,7 @@ static void ftrace_free_entry_rcu(struct +@@ -2607,7 +2612,7 @@ static void ftrace_free_entry_rcu(struct rcu_head = *rhp) =20 int register_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops= , @@ -67498,10 +69187,11 @@ diff -urNp linux-3.1.4/kernel/trace/ftrace.c li= nux-3.1.4/kernel/trace/ftrace.c { struct ftrace_func_probe *entry; struct ftrace_page *pg; -diff -urNp linux-3.1.4/kernel/trace/trace.c linux-3.1.4/kernel/trace/tra= ce.c ---- linux-3.1.4/kernel/trace/trace.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/kernel/trace/trace.c 2011-11-16 18:40:44.000000000 -0500 -@@ -3451,6 +3451,8 @@ static ssize_t tracing_splice_read_pipe( +diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c +index 17a2d44..85907e2 100644 +--- a/kernel/trace/trace.c ++++ b/kernel/trace/trace.c +@@ -3451,6 +3451,8 @@ static ssize_t tracing_splice_read_pipe(struct fil= e *filp, size_t rem; unsigned int i; =20 @@ -67510,7 +69200,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace.c linux= -3.1.4/kernel/trace/trace.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; =20 -@@ -3926,6 +3928,8 @@ tracing_buffers_splice_read(struct file=20 +@@ -3926,6 +3928,8 @@ tracing_buffers_splice_read(struct file *file, lof= f_t *ppos, int entries, size, i; size_t ret; =20 @@ -67519,7 +69209,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace.c linux= -3.1.4/kernel/trace/trace.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; =20 -@@ -4093,10 +4097,9 @@ static const struct file_operations trac +@@ -4093,10 +4097,9 @@ static const struct file_operations tracing_dyn_i= nfo_fops =3D { }; #endif =20 @@ -67543,10 +69233,11 @@ diff -urNp linux-3.1.4/kernel/trace/trace.c lin= ux-3.1.4/kernel/trace/trace.c static int once; struct dentry *d_tracer; =20 -diff -urNp linux-3.1.4/kernel/trace/trace_events.c linux-3.1.4/kernel/tr= ace/trace_events.c ---- linux-3.1.4/kernel/trace/trace_events.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/kernel/trace/trace_events.c 2011-11-16 18:39:08.00000000= 0 -0500 -@@ -1300,10 +1300,6 @@ static LIST_HEAD(ftrace_module_file_list +diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c +index 581876f..a91e569 100644 +--- a/kernel/trace/trace_events.c ++++ b/kernel/trace/trace_events.c +@@ -1300,10 +1300,6 @@ static LIST_HEAD(ftrace_module_file_list); struct ftrace_module_file_ops { struct list_head list; struct module *mod; @@ -67557,7 +69248,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_events.= c linux-3.1.4/kernel/trace/trac }; =20 static struct ftrace_module_file_ops * -@@ -1324,17 +1320,12 @@ trace_create_file_ops(struct module *mod +@@ -1324,17 +1320,12 @@ trace_create_file_ops(struct module *mod) =20 file_ops->mod =3D mod; =20 @@ -67581,7 +69272,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_events.= c linux-3.1.4/kernel/trace/trac =20 list_add(&file_ops->list, &ftrace_module_file_list); =20 -@@ -1358,8 +1349,8 @@ static void trace_module_add_events(stru +@@ -1358,8 +1349,8 @@ static void trace_module_add_events(struct module = *mod) =20 for_each_event(call, start, end) { __trace_add_event_call(*call, mod, @@ -67592,10 +69283,11 @@ diff -urNp linux-3.1.4/kernel/trace/trace_event= s.c linux-3.1.4/kernel/trace/trac } } =20 -diff -urNp linux-3.1.4/kernel/trace/trace_kprobe.c linux-3.1.4/kernel/tr= ace/trace_kprobe.c ---- linux-3.1.4/kernel/trace/trace_kprobe.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/kernel/trace/trace_kprobe.c 2011-11-16 18:39:08.00000000= 0 -0500 -@@ -217,7 +217,7 @@ static __kprobes void FETCH_FUNC_NAME(me +diff --git a/kernel/trace/trace_kprobe.c b/kernel/trace/trace_kprobe.c +index 00d527c..7c5b1a3 100644 +--- a/kernel/trace/trace_kprobe.c ++++ b/kernel/trace/trace_kprobe.c +@@ -217,7 +217,7 @@ static __kprobes void FETCH_FUNC_NAME(memory, string= )(struct pt_regs *regs, long ret; int maxlen =3D get_rloc_len(*(u32 *)dest); u8 *dst =3D get_rloc_data(dest); @@ -67604,7 +69296,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_kprobe.= c linux-3.1.4/kernel/trace/trac mm_segment_t old_fs =3D get_fs(); if (!maxlen) return; -@@ -229,7 +229,7 @@ static __kprobes void FETCH_FUNC_NAME(me +@@ -229,7 +229,7 @@ static __kprobes void FETCH_FUNC_NAME(memory, string= )(struct pt_regs *regs, pagefault_disable(); do ret =3D __copy_from_user_inatomic(dst++, src++, 1); @@ -67613,7 +69305,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_kprobe.= c linux-3.1.4/kernel/trace/trac dst[-1] =3D '\0'; pagefault_enable(); set_fs(old_fs); -@@ -238,7 +238,7 @@ static __kprobes void FETCH_FUNC_NAME(me +@@ -238,7 +238,7 @@ static __kprobes void FETCH_FUNC_NAME(memory, string= )(struct pt_regs *regs, ((u8 *)get_rloc_data(dest))[0] =3D '\0'; *(u32 *)dest =3D make_data_rloc(0, get_rloc_offs(*(u32 *)dest)); } else @@ -67622,7 +69314,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_kprobe.= c linux-3.1.4/kernel/trace/trac get_rloc_offs(*(u32 *)dest)); } /* Return the length of string -- including null terminal byte */ -@@ -252,7 +252,7 @@ static __kprobes void FETCH_FUNC_NAME(me +@@ -252,7 +252,7 @@ static __kprobes void FETCH_FUNC_NAME(memory, string= _size)(struct pt_regs *regs, set_fs(KERNEL_DS); pagefault_disable(); do { @@ -67631,9 +69323,10 @@ diff -urNp linux-3.1.4/kernel/trace/trace_kprobe= .c linux-3.1.4/kernel/trace/trac len++; } while (c && ret =3D=3D 0 && len < MAX_STRING_SIZE); pagefault_enable(); -diff -urNp linux-3.1.4/kernel/trace/trace_mmiotrace.c linux-3.1.4/kernel= /trace/trace_mmiotrace.c ---- linux-3.1.4/kernel/trace/trace_mmiotrace.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/kernel/trace/trace_mmiotrace.c 2011-11-16 18:39:08.00000= 0000 -0500 +diff --git a/kernel/trace/trace_mmiotrace.c b/kernel/trace/trace_mmiotra= ce.c +index fd3c8aa..5f324a6 100644 +--- a/kernel/trace/trace_mmiotrace.c ++++ b/kernel/trace/trace_mmiotrace.c @@ -24,7 +24,7 @@ struct header_iter { static struct trace_array *mmio_trace_array; static bool overrun_detected; @@ -67643,7 +69336,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_mmiotra= ce.c linux-3.1.4/kernel/trace/t =20 static void mmio_reset_data(struct trace_array *tr) { -@@ -127,7 +127,7 @@ static void mmio_close(struct trace_iter +@@ -127,7 +127,7 @@ static void mmio_close(struct trace_iterator *iter) =20 static unsigned long count_overruns(struct trace_iterator *iter) { @@ -67652,7 +69345,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_mmiotra= ce.c linux-3.1.4/kernel/trace/t unsigned long over =3D ring_buffer_overruns(iter->tr->buffer); =20 if (over > prev_overruns) -@@ -317,7 +317,7 @@ static void __trace_mmiotrace_rw(struct=20 +@@ -317,7 +317,7 @@ static void __trace_mmiotrace_rw(struct trace_array = *tr, event =3D trace_buffer_lock_reserve(buffer, TRACE_MMIO_RW, sizeof(*entry), 0, pc); if (!event) { @@ -67661,7 +69354,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_mmiotra= ce.c linux-3.1.4/kernel/trace/t return; } entry =3D ring_buffer_event_data(event); -@@ -347,7 +347,7 @@ static void __trace_mmiotrace_map(struct +@@ -347,7 +347,7 @@ static void __trace_mmiotrace_map(struct trace_array= *tr, event =3D trace_buffer_lock_reserve(buffer, TRACE_MMIO_MAP, sizeof(*entry), 0, pc); if (!event) { @@ -67670,10 +69363,11 @@ diff -urNp linux-3.1.4/kernel/trace/trace_mmiot= race.c linux-3.1.4/kernel/trace/t return; } entry =3D ring_buffer_event_data(event); -diff -urNp linux-3.1.4/kernel/trace/trace_output.c linux-3.1.4/kernel/tr= ace/trace_output.c ---- linux-3.1.4/kernel/trace/trace_output.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/kernel/trace/trace_output.c 2011-11-16 18:39:08.00000000= 0 -0500 -@@ -278,7 +278,7 @@ int trace_seq_path(struct trace_seq *s,=20 +diff --git a/kernel/trace/trace_output.c b/kernel/trace/trace_output.c +index 5199930..26c73a0 100644 +--- a/kernel/trace/trace_output.c ++++ b/kernel/trace/trace_output.c +@@ -278,7 +278,7 @@ int trace_seq_path(struct trace_seq *s, struct path = *path) =20 p =3D d_path(path, s->buffer + s->len, PAGE_SIZE - s->len); if (!IS_ERR(p)) { @@ -67682,9 +69376,10 @@ diff -urNp linux-3.1.4/kernel/trace/trace_output= .c linux-3.1.4/kernel/trace/trac if (p) { s->len =3D p - s->buffer; return 1; -diff -urNp linux-3.1.4/kernel/trace/trace_stack.c linux-3.1.4/kernel/tra= ce/trace_stack.c ---- linux-3.1.4/kernel/trace/trace_stack.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/kernel/trace/trace_stack.c 2011-11-16 18:39:08.000000000= -0500 +diff --git a/kernel/trace/trace_stack.c b/kernel/trace/trace_stack.c +index 77575b3..6e623d1 100644 +--- a/kernel/trace/trace_stack.c ++++ b/kernel/trace/trace_stack.c @@ -50,7 +50,7 @@ static inline void check_stack(void) return; =20 @@ -67694,9 +69389,10 @@ diff -urNp linux-3.1.4/kernel/trace/trace_stack.= c linux-3.1.4/kernel/trace/trace return; =20 local_irq_save(flags); -diff -urNp linux-3.1.4/kernel/trace/trace_workqueue.c linux-3.1.4/kernel= /trace/trace_workqueue.c ---- linux-3.1.4/kernel/trace/trace_workqueue.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/kernel/trace/trace_workqueue.c 2011-11-16 18:39:08.00000= 0000 -0500 +diff --git a/kernel/trace/trace_workqueue.c b/kernel/trace/trace_workque= ue.c +index 209b379..7f76423 100644 +--- a/kernel/trace/trace_workqueue.c ++++ b/kernel/trace/trace_workqueue.c @@ -22,7 +22,7 @@ struct cpu_workqueue_stats { int cpu; pid_t pid; @@ -67715,7 +69411,7 @@ diff -urNp linux-3.1.4/kernel/trace/trace_workque= ue.c linux-3.1.4/kernel/trace/t goto found; } } -@@ -210,7 +210,7 @@ static int workqueue_stat_show(struct se +@@ -210,7 +210,7 @@ static int workqueue_stat_show(struct seq_file *s, v= oid *p) tsk =3D get_pid_task(pid, PIDTYPE_PID); if (tsk) { seq_printf(s, "%3d %6d %6u %s\n", cws->cpu, @@ -67724,10 +69420,23 @@ diff -urNp linux-3.1.4/kernel/trace/trace_workq= ueue.c linux-3.1.4/kernel/trace/t tsk->comm); put_task_struct(tsk); } -diff -urNp linux-3.1.4/lib/bitmap.c linux-3.1.4/lib/bitmap.c ---- linux-3.1.4/lib/bitmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/bitmap.c 2011-11-16 18:39:08.000000000 -0500 -@@ -419,7 +419,7 @@ int __bitmap_parse(const char *buf, unsi +diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug +index c0cb9c4..f33aa89 100644 +--- a/lib/Kconfig.debug ++++ b/lib/Kconfig.debug +@@ -1091,6 +1091,7 @@ config LATENCYTOP + depends on DEBUG_KERNEL + depends on STACKTRACE_SUPPORT + depends on PROC_FS ++ depends on !GRKERNSEC_HIDESYM + select FRAME_POINTER if !MIPS && !PPC && !S390 && !MICROBLAZE + select KALLSYMS + select KALLSYMS_ALL +diff --git a/lib/bitmap.c b/lib/bitmap.c +index 2f4412e..a557e27 100644 +--- a/lib/bitmap.c ++++ b/lib/bitmap.c +@@ -419,7 +419,7 @@ int __bitmap_parse(const char *buf, unsigned int buf= len, { int c, old_c, totaldigits, ndigits, nchunks, nbits; u32 chunk; @@ -67736,7 +69445,7 @@ diff -urNp linux-3.1.4/lib/bitmap.c linux-3.1.4/l= ib/bitmap.c =20 bitmap_zero(maskp, nmaskbits); =20 -@@ -504,7 +504,7 @@ int bitmap_parse_user(const char __user=20 +@@ -504,7 +504,7 @@ int bitmap_parse_user(const char __user *ubuf, { if (!access_ok(VERIFY_READ, ubuf, ulen)) return -EFAULT; @@ -67745,7 +69454,7 @@ diff -urNp linux-3.1.4/lib/bitmap.c linux-3.1.4/l= ib/bitmap.c } EXPORT_SYMBOL(bitmap_parse_user); =20 -@@ -594,7 +594,7 @@ static int __bitmap_parselist(const char +@@ -594,7 +594,7 @@ static int __bitmap_parselist(const char *buf, unsig= ned int buflen, { unsigned a, b; int c, old_c, totaldigits; @@ -67754,7 +69463,7 @@ diff -urNp linux-3.1.4/lib/bitmap.c linux-3.1.4/l= ib/bitmap.c int exp_digit, in_range; =20 totaldigits =3D c =3D 0; -@@ -694,7 +694,7 @@ int bitmap_parselist_user(const char __u +@@ -694,7 +694,7 @@ int bitmap_parselist_user(const char __user *ubuf, { if (!access_ok(VERIFY_READ, ubuf, ulen)) return -EFAULT; @@ -67763,10 +69472,11 @@ diff -urNp linux-3.1.4/lib/bitmap.c linux-3.1.4= /lib/bitmap.c ulen, 1, maskp, nmaskbits); } EXPORT_SYMBOL(bitmap_parselist_user); -diff -urNp linux-3.1.4/lib/bug.c linux-3.1.4/lib/bug.c ---- linux-3.1.4/lib/bug.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/bug.c 2011-11-16 18:39:08.000000000 -0500 -@@ -133,6 +133,8 @@ enum bug_trap_type report_bug(unsigned l +diff --git a/lib/bug.c b/lib/bug.c +index 1955209..cbbb2ad 100644 +--- a/lib/bug.c ++++ b/lib/bug.c +@@ -133,6 +133,8 @@ enum bug_trap_type report_bug(unsigned long bugaddr,= struct pt_regs *regs) return BUG_TRAP_TYPE_NONE; =20 bug =3D find_bug(bugaddr); @@ -67775,10 +69485,11 @@ diff -urNp linux-3.1.4/lib/bug.c linux-3.1.4/li= b/bug.c =20 file =3D NULL; line =3D 0; -diff -urNp linux-3.1.4/lib/debugobjects.c linux-3.1.4/lib/debugobjects.c ---- linux-3.1.4/lib/debugobjects.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/debugobjects.c 2011-11-16 18:39:08.000000000 -0500 -@@ -284,7 +284,7 @@ static void debug_object_is_on_stack(voi +diff --git a/lib/debugobjects.c b/lib/debugobjects.c +index a78b7c6..2c73084 100644 +--- a/lib/debugobjects.c ++++ b/lib/debugobjects.c +@@ -284,7 +284,7 @@ static void debug_object_is_on_stack(void *addr, int= onstack) if (limit > 4) return; =20 @@ -67787,9 +69498,10 @@ diff -urNp linux-3.1.4/lib/debugobjects.c linux-= 3.1.4/lib/debugobjects.c if (is_on_stack =3D=3D onstack) return; =20 -diff -urNp linux-3.1.4/lib/devres.c linux-3.1.4/lib/devres.c ---- linux-3.1.4/lib/devres.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/devres.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/lib/devres.c b/lib/devres.c +index 7c0e953..f642b5c 100644 +--- a/lib/devres.c ++++ b/lib/devres.c @@ -80,7 +80,7 @@ EXPORT_SYMBOL(devm_ioremap_nocache); void devm_iounmap(struct device *dev, void __iomem *addr) { @@ -67799,7 +69511,7 @@ diff -urNp linux-3.1.4/lib/devres.c linux-3.1.4/l= ib/devres.c iounmap(addr); } EXPORT_SYMBOL(devm_iounmap); -@@ -141,7 +141,7 @@ void devm_ioport_unmap(struct device *de +@@ -141,7 +141,7 @@ void devm_ioport_unmap(struct device *dev, void __io= mem *addr) { ioport_unmap(addr); WARN_ON(devres_destroy(dev, devm_ioport_map_release, @@ -67808,9 +69520,10 @@ diff -urNp linux-3.1.4/lib/devres.c linux-3.1.4/= lib/devres.c } EXPORT_SYMBOL(devm_ioport_unmap); =20 -diff -urNp linux-3.1.4/lib/dma-debug.c linux-3.1.4/lib/dma-debug.c ---- linux-3.1.4/lib/dma-debug.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/dma-debug.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/lib/dma-debug.c b/lib/dma-debug.c +index db07bfd..719b5ab 100644 +--- a/lib/dma-debug.c ++++ b/lib/dma-debug.c @@ -870,7 +870,7 @@ out: =20 static void check_for_stack(struct device *dev, void *addr) @@ -67820,9 +69533,10 @@ diff -urNp linux-3.1.4/lib/dma-debug.c linux-3.1= .4/lib/dma-debug.c err_printk(dev, NULL, "DMA-API: device driver maps memory from" "stack [addr=3D%p]\n", addr); } -diff -urNp linux-3.1.4/lib/extable.c linux-3.1.4/lib/extable.c ---- linux-3.1.4/lib/extable.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/extable.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/lib/extable.c b/lib/extable.c +index 4cac81e..63e9b8f 100644 +--- a/lib/extable.c ++++ b/lib/extable.c @@ -13,6 +13,7 @@ #include #include @@ -67831,7 +69545,7 @@ diff -urNp linux-3.1.4/lib/extable.c linux-3.1.4/= lib/extable.c =20 #ifndef ARCH_HAS_SORT_EXTABLE /* -@@ -36,8 +37,10 @@ static int cmp_ex(const void *a, const v +@@ -36,8 +37,10 @@ static int cmp_ex(const void *a, const void *b) void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) { @@ -67842,9 +69556,10 @@ diff -urNp linux-3.1.4/lib/extable.c linux-3.1.4= /lib/extable.c } =20 #ifdef CONFIG_MODULES -diff -urNp linux-3.1.4/lib/inflate.c linux-3.1.4/lib/inflate.c ---- linux-3.1.4/lib/inflate.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/inflate.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/lib/inflate.c b/lib/inflate.c +index 013a761..c28f3fc 100644 +--- a/lib/inflate.c ++++ b/lib/inflate.c @@ -269,7 +269,7 @@ static void free(void *where) malloc_ptr =3D free_mem_ptr; } @@ -67854,20 +69569,10 @@ diff -urNp linux-3.1.4/lib/inflate.c linux-3.1.= 4/lib/inflate.c #define free(a) kfree(a) #endif =20 -diff -urNp linux-3.1.4/lib/Kconfig.debug linux-3.1.4/lib/Kconfig.debug ---- linux-3.1.4/lib/Kconfig.debug 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/Kconfig.debug 2011-11-16 18:40:44.000000000 -0500 -@@ -1091,6 +1091,7 @@ config LATENCYTOP - depends on DEBUG_KERNEL - depends on STACKTRACE_SUPPORT - depends on PROC_FS -+ depends on !GRKERNSEC_HIDESYM - select FRAME_POINTER if !MIPS && !PPC && !S390 && !MICROBLAZE - select KALLSYMS - select KALLSYMS_ALL -diff -urNp linux-3.1.4/lib/kref.c linux-3.1.4/lib/kref.c ---- linux-3.1.4/lib/kref.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/kref.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/lib/kref.c b/lib/kref.c +index 3efb882..8492f4c 100644 +--- a/lib/kref.c ++++ b/lib/kref.c @@ -52,7 +52,7 @@ void kref_get(struct kref *kref) */ int kref_put(struct kref *kref, void (*release)(struct kref *kref)) @@ -67877,9 +69582,10 @@ diff -urNp linux-3.1.4/lib/kref.c linux-3.1.4/li= b/kref.c WARN_ON(release =3D=3D (void (*)(struct kref *))kfree); =20 if (atomic_dec_and_test(&kref->refcount)) { -diff -urNp linux-3.1.4/lib/radix-tree.c linux-3.1.4/lib/radix-tree.c ---- linux-3.1.4/lib/radix-tree.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/radix-tree.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/lib/radix-tree.c b/lib/radix-tree.c +index a2f9da5..3bcadb6 100644 +--- a/lib/radix-tree.c ++++ b/lib/radix-tree.c @@ -80,7 +80,7 @@ struct radix_tree_preload { int nr; struct radix_tree_node *nodes[RADIX_TREE_MAX_PATH]; @@ -67889,9 +69595,10 @@ diff -urNp linux-3.1.4/lib/radix-tree.c linux-3.= 1.4/lib/radix-tree.c =20 static inline void *ptr_to_indirect(void *ptr) { -diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.1.4/lib/vsprintf.c ---- linux-3.1.4/lib/vsprintf.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/lib/vsprintf.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/lib/vsprintf.c b/lib/vsprintf.c +index d7222a9..2172edc 100644 +--- a/lib/vsprintf.c ++++ b/lib/vsprintf.c @@ -16,6 +16,9 @@ * - scnprintf and vscnprintf */ @@ -67902,7 +69609,7 @@ diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.1.4= /lib/vsprintf.c #include #include #include -@@ -432,7 +435,7 @@ char *symbol_string(char *buf, char *end +@@ -432,7 +435,7 @@ char *symbol_string(char *buf, char *end, void *ptr, char sym[KSYM_SYMBOL_LEN]; if (ext =3D=3D 'B') sprint_backtrace(sym, value); @@ -67911,7 +69618,7 @@ diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.1.4= /lib/vsprintf.c sprint_symbol(sym, value); else kallsyms_lookup(value, NULL, NULL, NULL, sym); -@@ -796,7 +799,11 @@ char *uuid_string(char *buf, char *end,=20 +@@ -796,7 +799,11 @@ char *uuid_string(char *buf, char *end, const u8 *a= ddr, return string(buf, end, uuid, spec); } =20 @@ -67932,7 +69639,7 @@ diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.1.4= /lib/vsprintf.c * - 'R' For decoded struct resource, e.g., [mem 0x0-0x1f 64bit pref] * - 'r' For raw struct resource, e.g., [mem 0x0-0x1f flags 0x201] * - 'M' For a 6-byte MAC address, it prints the address in the -@@ -854,12 +863,12 @@ char *pointer(const char *fmt, char *buf +@@ -854,12 +863,12 @@ char *pointer(const char *fmt, char *buf, char *en= d, void *ptr, { if (!ptr && *fmt !=3D 'K') { /* @@ -67947,7 +69654,7 @@ diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.1.4= /lib/vsprintf.c } =20 switch (*fmt) { -@@ -869,6 +878,13 @@ char *pointer(const char *fmt, char *buf +@@ -869,6 +878,13 @@ char *pointer(const char *fmt, char *buf, char *end= , void *ptr, /* Fallthrough */ case 'S': case 's': @@ -67961,7 +69668,7 @@ diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.1.4= /lib/vsprintf.c case 'B': return symbol_string(buf, end, ptr, spec, *fmt); case 'R': -@@ -1627,11 +1643,11 @@ int bstr_printf(char *buf, size_t size,=20 +@@ -1627,11 +1643,11 @@ int bstr_printf(char *buf, size_t size, const ch= ar *fmt, const u32 *bin_buf) typeof(type) value; \ if (sizeof(type) =3D=3D 8) { \ args =3D PTR_ALIGN(args, sizeof(u32)); \ @@ -67976,7 +69683,7 @@ diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.1.4= /lib/vsprintf.c } \ args +=3D sizeof(type); \ value; \ -@@ -1694,7 +1710,7 @@ int bstr_printf(char *buf, size_t size,=20 +@@ -1694,7 +1710,7 @@ int bstr_printf(char *buf, size_t size, const char= *fmt, const u32 *bin_buf) case FORMAT_TYPE_STR: { const char *str_arg =3D args; args +=3D strlen(str_arg) + 1; @@ -67985,192 +69692,36 @@ diff -urNp linux-3.1.4/lib/vsprintf.c linux-3.= 1.4/lib/vsprintf.c break; } =20 -diff -urNp linux-3.1.4/localversion-grsec linux-3.1.4/localversion-grsec ---- linux-3.1.4/localversion-grsec 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.1.4/localversion-grsec 2011-11-16 18:40:44.000000000 -0500 +diff --git a/localversion-grsec b/localversion-grsec +new file mode 100644 +index 0000000..7cd6065 +--- /dev/null ++++ b/localversion-grsec @@ -0,0 +1 @@ +-grsec -diff -urNp linux-3.1.4/Makefile linux-3.1.4/Makefile ---- linux-3.1.4/Makefile 2011-11-29 18:06:31.000000000 -0500 -+++ linux-3.1.4/Makefile 2011-12-02 17:38:47.000000000 -0500 -@@ -245,8 +245,9 @@ CONFIG_SHELL :=3D $(shell if [ -x "$$BASH" -=20 - HOSTCC =3D gcc - HOSTCXX =3D g++ --HOSTCFLAGS =3D -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fo= mit-frame-pointer --HOSTCXXFLAGS =3D -O2 -+HOSTCFLAGS =3D -Wall -W -Wmissing-prototypes -Wstrict-prototypes -Wno= -unused-parameter -Wno-missing-field-initializers -O2 -fomit-frame-pointe= r -fno-delete-null-pointer-checks -+HOSTCLFAGS +=3D $(call cc-option, -Wno-empty-body) -+HOSTCXXFLAGS =3D -O2 -Wall -W -fno-delete-null-pointer-checks -=20 - # Decide whether to build built-in, modular, or both. - # Normally, just do built-in. -@@ -407,8 +408,8 @@ export RCS_TAR_IGNORE :=3D --exclude SCCS=20 - # Rules shared between *config targets and build targets -=20 - # Basic helpers built in scripts/ --PHONY +=3D scripts_basic --scripts_basic: -+PHONY +=3D scripts_basic gcc-plugins -+scripts_basic: gcc-plugins - $(Q)$(MAKE) $(build)=3Dscripts/basic - $(Q)rm -f .tmp_quiet_recordmcount -=20 -@@ -564,6 +565,42 @@ else - KBUILD_CFLAGS +=3D -O2 - endif -=20 -+ifndef DISABLE_PAX_PLUGINS -+ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-plugin.sh "$(HOSTC= C)" "$(CC)"), y) -+ifndef DISABLE_PAX_CONSTIFY_PLUGIN -+CONSTIFY_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/constify_plugin.so= -DCONSTIFY_PLUGIN -+endif -+ifdef CONFIG_PAX_MEMORY_STACKLEAK -+STACKLEAK_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/stackleak_plugin.= so -DSTACKLEAK_PLUGIN -+STACKLEAK_PLUGIN +=3D -fplugin-arg-stackleak_plugin-track-lowest-sp=3D1= 00 -+endif -+ifdef CONFIG_KALLOCSTAT_PLUGIN -+KALLOCSTAT_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kallocstat_plugi= n.so -+endif -+ifdef CONFIG_PAX_KERNEXEC_PLUGIN -+KERNEXEC_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/kernexec_plugin.so -+KERNEXEC_PLUGIN +=3D -fplugin-arg-kernexec_plugin-method=3D$(CONFIG_PAX= _KERNEXEC_PLUGIN_METHOD) -+endif -+ifdef CONFIG_CHECKER_PLUGIN -+ifeq ($(call cc-ifversion, -ge, 0406, y), y) -+CHECKER_PLUGIN :=3D -fplugin=3D$(objtree)/tools/gcc/checker_plugin.so -= DCHECKER_PLUGIN -+endif -+endif -+GCC_PLUGINS :=3D $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN) $(KALLOCSTAT_PL= UGIN) $(KERNEXEC_PLUGIN) $(CHECKER_PLUGIN) -+export CONSTIFY_PLUGIN STACKLEAK_PLUGIN KERNEXEC_PLUGIN CHECKER_PLUGIN -+gcc-plugins: -+ $(Q)$(MAKE) $(build)=3Dtools/gcc -+else -+gcc-plugins: -+ifeq ($(call cc-ifversion, -ge, 0405, y), y) -+ $(error Your gcc installation does not support plugins. If the necess= ary headers for plugin support are missing, they should be installed. On= Debian, apt-get install gcc--plugin-dev. If you choose to ignore t= his error and lessen the improvements provided by this patch, re-run make= with the DISABLE_PAX_PLUGINS=3Dy argument.)) -+else -+ $(Q)echo "warning, your gcc version does not support plugins, you shou= ld upgrade it to gcc 4.5 at least" -+endif -+ $(Q)echo "PAX_MEMORY_STACKLEAK and other features will be less secure" -+endif -+endif -+ - include $(srctree)/arch/$(SRCARCH)/Makefile -=20 - ifneq ($(CONFIG_FRAME_WARN),0) -@@ -708,7 +745,7 @@ export mod_strip_cmd -=20 -=20 - ifeq ($(KBUILD_EXTMOD),) --core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ -+core-y +=3D kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ -=20 - vmlinux-dirs :=3D $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ - $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ -@@ -932,6 +969,7 @@ vmlinux.o: $(modpost-init) $(vmlinux-mai -=20 - # The actual objects are generated when descending,=20 - # make sure no implicit rule kicks in -+$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): KBUILD_CFLAGS += =3D $(GCC_PLUGINS) - $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): $(vmlinux-dirs)= ; -=20 - # Handle descending into subdirectories listed in $(vmlinux-dirs) -@@ -941,7 +979,7 @@ $(sort $(vmlinux-init) $(vmlinux-main))=20 - # Error messages still appears in the original language -=20 - PHONY +=3D $(vmlinux-dirs) --$(vmlinux-dirs): prepare scripts -+$(vmlinux-dirs): gcc-plugins prepare scripts - $(Q)$(MAKE) $(build)=3D$@ -=20 - # Store (new) KERNELRELASE string in include/config/kernel.release -@@ -986,6 +1024,7 @@ prepare0: archprepare FORCE - $(Q)$(MAKE) $(build)=3D. missing-syscalls -=20 - # All the preparing.. -+prepare: KBUILD_CFLAGS :=3D $(filter-out $(GCC_PLUGINS),$(KBUILD_CFLAGS= )) - prepare: prepare0 -=20 - # Generate some files -@@ -1087,6 +1126,7 @@ all: modules - # using awk while concatenating to the final file. -=20 - PHONY +=3D modules -+modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) - modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builti= n - $(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=3D$(objtree)/%/modules.order) = > $(objtree)/modules.order - @$(kecho) ' Building modules, stage 2.'; -@@ -1102,7 +1142,7 @@ modules.builtin: $(vmlinux-dirs:%=3D%/modu -=20 - # Target to prepare building external modules - PHONY +=3D modules_prepare --modules_prepare: prepare scripts -+modules_prepare: gcc-plugins prepare scripts -=20 - # Target to install modules - PHONY +=3D modules_install -@@ -1198,7 +1238,7 @@ distclean: mrproper - @find $(srctree) $(RCS_FIND_IGNORE) \ - \( -name '*.orig' -o -name '*.rej' -o -name '*~' \ - -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \ -- -o -name '.*.rej' -o -size 0 \ -+ -o -name '.*.rej' -o -name '*.so' -o -size 0 \ - -o -name '*%' -o -name '.*.cmd' -o -name 'core' \) \ - -type f -print | xargs rm -f -=20 -@@ -1360,6 +1400,7 @@ PHONY +=3D $(module-dirs) modules - $(module-dirs): crmodverdir $(objtree)/Module.symvers - $(Q)$(MAKE) $(build)=3D$(patsubst _module_%,%,$@) -=20 -+modules: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) - modules: $(module-dirs) - @$(kecho) ' Building modules, stage 2.'; - $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost -@@ -1486,17 +1527,19 @@ else - target-dir =3D $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@)) - endif +diff --git a/mm/Kconfig b/mm/Kconfig +index f2f1ca1..0645f06 100644 +--- a/mm/Kconfig ++++ b/mm/Kconfig +@@ -238,10 +238,10 @@ config KSM + root has set /sys/kernel/mm/ksm/run to 1 (if CONFIG_SYSFS is set). =20 --%.s: %.c prepare scripts FORCE -+%.s: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%.s: %.c gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) - %.i: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) --%.o: %.c prepare scripts FORCE -+%.o: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%.o: %.c gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) - %.lst: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) --%.s: %.S prepare scripts FORCE -+%.s: %.S gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) --%.o: %.S prepare scripts FORCE -+%.o: %.S gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) - %.symtypes: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=3D$(build-dir) $(target-dir)$(notdir $@) -@@ -1506,11 +1549,13 @@ endif - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ - $(build)=3D$(build-dir) --%/: prepare scripts FORCE -+%/: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%/: gcc-plugins prepare scripts FORCE - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ - $(build)=3D$(build-dir) --%.ko: prepare scripts FORCE -+%.ko: KBUILD_CFLAGS +=3D $(GCC_PLUGINS) -+%.ko: gcc-plugins prepare scripts FORCE - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=3D$(if $(CONFIG_MODULES),1) \ - $(build)=3D$(build-dir) $(@:.ko=3D.o) -diff -urNp linux-3.1.4/mm/filemap.c linux-3.1.4/mm/filemap.c ---- linux-3.1.4/mm/filemap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/filemap.c 2011-11-16 18:40:44.000000000 -0500 -@@ -1784,7 +1784,7 @@ int generic_file_mmap(struct file * file + config DEFAULT_MMAP_MIN_ADDR +- int "Low address space to protect from user allocation" ++ int "Low address space to protect from user allocation" + depends on MMU +- default 4096 +- help ++ default 65536 ++ help + This is the portion of low virtual memory which should be protected + from userspace allocation. Keeping a user from writing to low pages + can help reduce the impact of kernel NULL pointer bugs. +diff --git a/mm/filemap.c b/mm/filemap.c +index 7771871..91bcdb4 100644 +--- a/mm/filemap.c ++++ b/mm/filemap.c +@@ -1784,7 +1784,7 @@ int generic_file_mmap(struct file * file, struct v= m_area_struct * vma) struct address_space *mapping =3D file->f_mapping; =20 if (!mapping->a_ops->readpage) @@ -68179,7 +69730,7 @@ diff -urNp linux-3.1.4/mm/filemap.c linux-3.1.4/m= m/filemap.c file_accessed(file); vma->vm_ops =3D &generic_file_vm_ops; vma->vm_flags |=3D VM_CAN_NONLINEAR; -@@ -2190,6 +2190,7 @@ inline int generic_write_checks(struct f +@@ -2190,6 +2190,7 @@ inline int generic_write_checks(struct file *file,= loff_t *pos, size_t *count, i *pos =3D i_size_read(inode); =20 if (limit !=3D RLIM_INFINITY) { @@ -68187,10 +69738,11 @@ diff -urNp linux-3.1.4/mm/filemap.c linux-3.1.4= /mm/filemap.c if (*pos >=3D limit) { send_sig(SIGXFSZ, current, 0); return -EFBIG; -diff -urNp linux-3.1.4/mm/fremap.c linux-3.1.4/mm/fremap.c ---- linux-3.1.4/mm/fremap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/fremap.c 2011-11-16 18:39:08.000000000 -0500 -@@ -156,6 +156,11 @@ SYSCALL_DEFINE5(remap_file_pages, unsign +diff --git a/mm/fremap.c b/mm/fremap.c +index b8e0e2d..076e171 100644 +--- a/mm/fremap.c ++++ b/mm/fremap.c +@@ -156,6 +156,11 @@ SYSCALL_DEFINE5(remap_file_pages, unsigned long, st= art, unsigned long, size, retry: vma =3D find_vma(mm, start); =20 @@ -68202,9 +69754,10 @@ diff -urNp linux-3.1.4/mm/fremap.c linux-3.1.4/m= m/fremap.c /* * Make sure the vma is shared, that it supports prefaulting, * and that the remapped range is valid and fully within -diff -urNp linux-3.1.4/mm/highmem.c linux-3.1.4/mm/highmem.c ---- linux-3.1.4/mm/highmem.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/highmem.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/mm/highmem.c b/mm/highmem.c +index 5ef672c..d7660f4 100644 +--- a/mm/highmem.c ++++ b/mm/highmem.c @@ -125,9 +125,10 @@ static void flush_all_zero_pkmaps(void) * So no dangers, even with speculative execution. */ @@ -68230,9 +69783,10 @@ diff -urNp linux-3.1.4/mm/highmem.c linux-3.1.4/= mm/highmem.c pkmap_count[last_pkmap_nr] =3D 1; set_page_address(page, (void *)vaddr); =20 -diff -urNp linux-3.1.4/mm/huge_memory.c linux-3.1.4/mm/huge_memory.c ---- linux-3.1.4/mm/huge_memory.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/huge_memory.c 2011-12-02 17:38:47.000000000 -0500 +diff --git a/mm/huge_memory.c b/mm/huge_memory.c +index d819d93..468e18f 100644 +--- a/mm/huge_memory.c ++++ b/mm/huge_memory.c @@ -702,7 +702,7 @@ out: * run pte_offset_map on the pmd, if an huge pmd could * materialize from under us from a different thread. @@ -68242,7 +69796,7 @@ diff -urNp linux-3.1.4/mm/huge_memory.c linux-3.1= .4/mm/huge_memory.c return VM_FAULT_OOM; /* if an huge pmd materialized from under us just retry later */ if (unlikely(pmd_trans_huge(*pmd))) -@@ -829,7 +829,7 @@ static int do_huge_pmd_wp_page_fallback( +@@ -829,7 +829,7 @@ static int do_huge_pmd_wp_page_fallback(struct mm_st= ruct *mm, =20 for (i =3D 0; i < HPAGE_PMD_NR; i++) { copy_user_highpage(pages[i], page + i, @@ -68251,10 +69805,11 @@ diff -urNp linux-3.1.4/mm/huge_memory.c linux-3= .1.4/mm/huge_memory.c __SetPageUptodate(pages[i]); cond_resched(); } -diff -urNp linux-3.1.4/mm/hugetlb.c linux-3.1.4/mm/hugetlb.c ---- linux-3.1.4/mm/hugetlb.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/hugetlb.c 2011-11-16 18:39:08.000000000 -0500 -@@ -2346,6 +2346,27 @@ static int unmap_ref_private(struct mm_s +diff --git a/mm/hugetlb.c b/mm/hugetlb.c +index dae27ba..e8d42be 100644 +--- a/mm/hugetlb.c ++++ b/mm/hugetlb.c +@@ -2346,6 +2346,27 @@ static int unmap_ref_private(struct mm_struct *mm= , struct vm_area_struct *vma, return 1; } =20 @@ -68305,7 +69860,7 @@ diff -urNp linux-3.1.4/mm/hugetlb.c linux-3.1.4/m= m/hugetlb.c if ((flags & FAULT_FLAG_WRITE) && !(vma->vm_flags & VM_SHARED)) { /* Optimization, do the COW without a second fault */ ret =3D hugetlb_cow(mm, vma, address, ptep, new_pte, page); -@@ -2627,6 +2657,10 @@ int hugetlb_fault(struct mm_struct *mm,=20 +@@ -2627,6 +2657,10 @@ int hugetlb_fault(struct mm_struct *mm, struct vm= _area_struct *vma, static DEFINE_MUTEX(hugetlb_instantiation_mutex); struct hstate *h =3D hstate_vma(vma); =20 @@ -68316,7 +69871,7 @@ diff -urNp linux-3.1.4/mm/hugetlb.c linux-3.1.4/m= m/hugetlb.c ptep =3D huge_pte_offset(mm, address); if (ptep) { entry =3D huge_ptep_get(ptep); -@@ -2638,6 +2672,26 @@ int hugetlb_fault(struct mm_struct *mm,=20 +@@ -2638,6 +2672,26 @@ int hugetlb_fault(struct mm_struct *mm, struct vm= _area_struct *vma, VM_FAULT_SET_HINDEX(h - hstates); } =20 @@ -68343,10 +69898,11 @@ diff -urNp linux-3.1.4/mm/hugetlb.c linux-3.1.4= /mm/hugetlb.c ptep =3D huge_pte_alloc(mm, address, huge_page_size(h)); if (!ptep) return VM_FAULT_OOM; -diff -urNp linux-3.1.4/mm/internal.h linux-3.1.4/mm/internal.h ---- linux-3.1.4/mm/internal.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/internal.h 2011-11-16 18:39:08.000000000 -0500 -@@ -95,6 +95,7 @@ extern void putback_lru_page(struct page +diff --git a/mm/internal.h b/mm/internal.h +index 2189af4..f2ca332 100644 +--- a/mm/internal.h ++++ b/mm/internal.h +@@ -95,6 +95,7 @@ extern void putback_lru_page(struct page *page); * in mm/page_alloc.c */ extern void __free_pages_bootmem(struct page *page, unsigned int order)= ; @@ -68354,27 +69910,11 @@ diff -urNp linux-3.1.4/mm/internal.h linux-3.1.= 4/mm/internal.h extern void prep_compound_page(struct page *page, unsigned long order); #ifdef CONFIG_MEMORY_FAILURE extern bool is_free_buddy_page(struct page *page); -diff -urNp linux-3.1.4/mm/Kconfig linux-3.1.4/mm/Kconfig ---- linux-3.1.4/mm/Kconfig 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/Kconfig 2011-11-17 18:57:00.000000000 -0500 -@@ -238,10 +238,10 @@ config KSM - root has set /sys/kernel/mm/ksm/run to 1 (if CONFIG_SYSFS is set). -=20 - config DEFAULT_MMAP_MIN_ADDR -- int "Low address space to protect from user allocation" -+ int "Low address space to protect from user allocation" - depends on MMU -- default 4096 -- help -+ default 65536 -+ help - This is the portion of low virtual memory which should be protected - from userspace allocation. Keeping a user from writing to low pages - can help reduce the impact of kernel NULL pointer bugs. -diff -urNp linux-3.1.4/mm/kmemleak.c linux-3.1.4/mm/kmemleak.c ---- linux-3.1.4/mm/kmemleak.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/kmemleak.c 2011-11-16 18:40:44.000000000 -0500 -@@ -357,7 +357,7 @@ static void print_unreferenced(struct se +diff --git a/mm/kmemleak.c b/mm/kmemleak.c +index d6880f5..ed77913 100644 +--- a/mm/kmemleak.c ++++ b/mm/kmemleak.c +@@ -357,7 +357,7 @@ static void print_unreferenced(struct seq_file *seq, =20 for (i =3D 0; i < object->trace_len; i++) { void *ptr =3D (void *)object->trace[i]; @@ -68383,10 +69923,11 @@ diff -urNp linux-3.1.4/mm/kmemleak.c linux-3.1.= 4/mm/kmemleak.c } } =20 -diff -urNp linux-3.1.4/mm/maccess.c linux-3.1.4/mm/maccess.c ---- linux-3.1.4/mm/maccess.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/maccess.c 2011-11-16 18:39:08.000000000 -0500 -@@ -26,7 +26,7 @@ long __probe_kernel_read(void *dst, cons +diff --git a/mm/maccess.c b/mm/maccess.c +index 4cee182..e00511d 100644 +--- a/mm/maccess.c ++++ b/mm/maccess.c +@@ -26,7 +26,7 @@ long __probe_kernel_read(void *dst, const void *src, s= ize_t size) set_fs(KERNEL_DS); pagefault_disable(); ret =3D __copy_from_user_inatomic(dst, @@ -68395,7 +69936,7 @@ diff -urNp linux-3.1.4/mm/maccess.c linux-3.1.4/m= m/maccess.c pagefault_enable(); set_fs(old_fs); =20 -@@ -53,7 +53,7 @@ long __probe_kernel_write(void *dst, con +@@ -53,7 +53,7 @@ long __probe_kernel_write(void *dst, const void *src, = size_t size) =20 set_fs(KERNEL_DS); pagefault_disable(); @@ -68404,10 +69945,11 @@ diff -urNp linux-3.1.4/mm/maccess.c linux-3.1.4= /mm/maccess.c pagefault_enable(); set_fs(old_fs); =20 -diff -urNp linux-3.1.4/mm/madvise.c linux-3.1.4/mm/madvise.c ---- linux-3.1.4/mm/madvise.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/madvise.c 2011-11-16 18:39:08.000000000 -0500 -@@ -45,6 +45,10 @@ static long madvise_behavior(struct vm_a +diff --git a/mm/madvise.c b/mm/madvise.c +index 74bf193..feb6fd3 100644 +--- a/mm/madvise.c ++++ b/mm/madvise.c +@@ -45,6 +45,10 @@ static long madvise_behavior(struct vm_area_struct * = vma, pgoff_t pgoff; unsigned long new_flags =3D vma->vm_flags; =20 @@ -68432,7 +69974,7 @@ diff -urNp linux-3.1.4/mm/madvise.c linux-3.1.4/m= m/madvise.c vma->vm_flags =3D new_flags; =20 out: -@@ -168,6 +179,11 @@ static long madvise_dontneed(struct vm_a +@@ -168,6 +179,11 @@ static long madvise_dontneed(struct vm_area_struct = * vma, struct vm_area_struct ** prev, unsigned long start, unsigned long end) { @@ -68444,7 +69986,7 @@ diff -urNp linux-3.1.4/mm/madvise.c linux-3.1.4/m= m/madvise.c *prev =3D vma; if (vma->vm_flags & (VM_LOCKED|VM_HUGETLB|VM_PFNMAP)) return -EINVAL; -@@ -180,6 +196,21 @@ static long madvise_dontneed(struct vm_a +@@ -180,6 +196,21 @@ static long madvise_dontneed(struct vm_area_struct = * vma, zap_page_range(vma, start, end - start, &details); } else zap_page_range(vma, start, end - start, NULL); @@ -68466,7 +70008,7 @@ diff -urNp linux-3.1.4/mm/madvise.c linux-3.1.4/m= m/madvise.c return 0; } =20 -@@ -376,6 +407,16 @@ SYSCALL_DEFINE3(madvise, unsigned long,=20 +@@ -376,6 +407,16 @@ SYSCALL_DEFINE3(madvise, unsigned long, start, size= _t, len_in, int, behavior) if (end < start) goto out; =20 @@ -68483,10 +70025,96 @@ diff -urNp linux-3.1.4/mm/madvise.c linux-3.1.4= /mm/madvise.c error =3D 0; if (end =3D=3D start) goto out; -diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm/memory.c ---- linux-3.1.4/mm/memory.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/memory.c 2011-11-16 18:39:08.000000000 -0500 -@@ -457,8 +457,12 @@ static inline void free_pmd_range(struct +diff --git a/mm/memory-failure.c b/mm/memory-failure.c +index 2b43ba0..fc09657 100644 +--- a/mm/memory-failure.c ++++ b/mm/memory-failure.c +@@ -60,7 +60,7 @@ int sysctl_memory_failure_early_kill __read_mostly =3D= 0; +=20 + int sysctl_memory_failure_recovery __read_mostly =3D 1; +=20 +-atomic_long_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INIT(0); ++atomic_long_unchecked_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INI= T(0); +=20 + #if defined(CONFIG_HWPOISON_INJECT) || defined(CONFIG_HWPOISON_INJECT_M= ODULE) +=20 +@@ -201,7 +201,7 @@ static int kill_proc_ao(struct task_struct *t, unsig= ned long addr, int trapno, + si.si_signo =3D SIGBUS; + si.si_errno =3D 0; + si.si_code =3D BUS_MCEERR_AO; +- si.si_addr =3D (void *)addr; ++ si.si_addr =3D (void __user *)addr; + #ifdef __ARCH_SI_TRAPNO + si.si_trapno =3D trapno; + #endif +@@ -1009,7 +1009,7 @@ int __memory_failure(unsigned long pfn, int trapno= , int flags) + } +=20 + nr_pages =3D 1 << compound_trans_order(hpage); +- atomic_long_add(nr_pages, &mce_bad_pages); ++ atomic_long_add_unchecked(nr_pages, &mce_bad_pages); +=20 + /* + * We need/can do nothing about count=3D0 pages. +@@ -1039,7 +1039,7 @@ int __memory_failure(unsigned long pfn, int trapno= , int flags) + if (!PageHWPoison(hpage) + || (hwpoison_filter(p) && TestClearPageHWPoison(p)) + || (p !=3D hpage && TestSetPageHWPoison(hpage))) { +- atomic_long_sub(nr_pages, &mce_bad_pages); ++ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); + return 0; + } + set_page_hwpoison_huge_page(hpage); +@@ -1097,7 +1097,7 @@ int __memory_failure(unsigned long pfn, int trapno= , int flags) + } + if (hwpoison_filter(p)) { + if (TestClearPageHWPoison(p)) +- atomic_long_sub(nr_pages, &mce_bad_pages); ++ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); + unlock_page(hpage); + put_page(hpage); + return 0; +@@ -1314,7 +1314,7 @@ int unpoison_memory(unsigned long pfn) + return 0; + } + if (TestClearPageHWPoison(p)) +- atomic_long_sub(nr_pages, &mce_bad_pages); ++ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); + pr_info("MCE: Software-unpoisoned free page %#lx\n", pfn); + return 0; + } +@@ -1328,7 +1328,7 @@ int unpoison_memory(unsigned long pfn) + */ + if (TestClearPageHWPoison(page)) { + pr_info("MCE: Software-unpoisoned page %#lx\n", pfn); +- atomic_long_sub(nr_pages, &mce_bad_pages); ++ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); + freeit =3D 1; + if (PageHuge(page)) + clear_page_hwpoison_huge_page(page); +@@ -1441,7 +1441,7 @@ static int soft_offline_huge_page(struct page *pag= e, int flags) + } + done: + if (!PageHWPoison(hpage)) +- atomic_long_add(1 << compound_trans_order(hpage), &mce_bad_pages); ++ atomic_long_add_unchecked(1 << compound_trans_order(hpage), &mce_bad_= pages); + set_page_hwpoison_huge_page(hpage); + dequeue_hwpoisoned_huge_page(hpage); + /* keep elevated page count for bad page */ +@@ -1572,7 +1572,7 @@ int soft_offline_page(struct page *page, int flags= ) + return ret; +=20 + done: +- atomic_long_add(1, &mce_bad_pages); ++ atomic_long_add_unchecked(1, &mce_bad_pages); + SetPageHWPoison(page); + /* keep elevated page count for bad page */ + return ret; +diff --git a/mm/memory.c b/mm/memory.c +index b2b8731..6080174 100644 +--- a/mm/memory.c ++++ b/mm/memory.c +@@ -457,8 +457,12 @@ static inline void free_pmd_range(struct mmu_gather= *tlb, pud_t *pud, return; =20 pmd =3D pmd_offset(pud, start); @@ -68499,7 +70127,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c } =20 static inline void free_pud_range(struct mmu_gather *tlb, pgd_t *pgd, -@@ -489,9 +493,12 @@ static inline void free_pud_range(struct +@@ -489,9 +493,12 @@ static inline void free_pud_range(struct mmu_gather= *tlb, pgd_t *pgd, if (end - 1 > ceiling - 1) return; =20 @@ -68525,7 +70153,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c /** * __get_user_pages() - pin user pages in memory * @tsk: task_struct of target task -@@ -1644,10 +1645,10 @@ int __get_user_pages(struct task_struct=20 +@@ -1644,10 +1645,10 @@ int __get_user_pages(struct task_struct *tsk, st= ruct mm_struct *mm, (VM_MAYREAD | VM_MAYWRITE) : (VM_READ | VM_WRITE); i =3D 0; =20 @@ -68538,7 +70166,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c if (!vma && in_gate_area(mm, start)) { unsigned long pg =3D start & PAGE_MASK; pgd_t *pgd; -@@ -1695,7 +1696,7 @@ int __get_user_pages(struct task_struct=20 +@@ -1695,7 +1696,7 @@ int __get_user_pages(struct task_struct *tsk, stru= ct mm_struct *mm, goto next_page; } =20 @@ -68547,7 +70175,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c (vma->vm_flags & (VM_IO | VM_PFNMAP)) || !(vm_flags & vma->vm_flags)) return i ? : -EFAULT; -@@ -1722,11 +1723,6 @@ int __get_user_pages(struct task_struct=20 +@@ -1722,11 +1723,6 @@ int __get_user_pages(struct task_struct *tsk, str= uct mm_struct *mm, int ret; unsigned int fault_flags =3D 0; =20 @@ -68568,7 +70196,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c return i; } EXPORT_SYMBOL(__get_user_pages); -@@ -2007,6 +2003,10 @@ static int insert_page(struct vm_area_st +@@ -2007,6 +2003,10 @@ static int insert_page(struct vm_area_struct *vma= , unsigned long addr, page_add_file_rmap(page); set_pte_at(mm, addr, pte, mk_pte(page, prot)); =20 @@ -68602,7 +70230,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c vma->vm_flags |=3D VM_INSERTPAGE; return insert_page(vma, addr, page, vma->vm_page_prot); } -@@ -2130,6 +2142,7 @@ int vm_insert_mixed(struct vm_area_struc +@@ -2130,6 +2142,7 @@ int vm_insert_mixed(struct vm_area_struct *vma, un= signed long addr, unsigned long pfn) { BUG_ON(!(vma->vm_flags & VM_MIXEDMAP)); @@ -68610,7 +70238,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c =20 if (addr < vma->vm_start || addr >=3D vma->vm_end) return -EFAULT; -@@ -2445,6 +2458,186 @@ static inline void cow_user_page(struct=20 +@@ -2445,6 +2458,186 @@ static inline void cow_user_page(struct page *ds= t, struct page *src, unsigned lo copy_user_highpage(dst, src, va, vma); } =20 @@ -68821,7 +70449,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c /* Free the old page.. */ new_page =3D old_page; ret |=3D VM_FAULT_WRITE; -@@ -2986,6 +3189,11 @@ static int do_swap_page(struct mm_struct +@@ -2986,6 +3189,11 @@ static int do_swap_page(struct mm_struct *mm, str= uct vm_area_struct *vma, swap_free(entry); if (vm_swap_full() || (vma->vm_flags & VM_LOCKED) || PageMlocked(page)= ) try_to_free_swap(page); @@ -68833,7 +70461,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c unlock_page(page); if (swapcache) { /* -@@ -3009,6 +3217,11 @@ static int do_swap_page(struct mm_struct +@@ -3009,6 +3217,11 @@ static int do_swap_page(struct mm_struct *mm, str= uct vm_area_struct *vma, =20 /* No need to invalidate - it was non-present before */ update_mmu_cache(vma, address, page_table); @@ -68886,7 +70514,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c * We enter with non-exclusive mmap_sem (to exclude vma changes, * but allow concurrent faults), and pte mapped but not yet locked. * We return with mmap_sem still held, but pte unmapped and unlocked. -@@ -3070,27 +3249,23 @@ static int do_anonymous_page(struct mm_s +@@ -3070,27 +3249,23 @@ static int do_anonymous_page(struct mm_struct *m= m, struct vm_area_struct *vma, unsigned long address, pte_t *page_table, pmd_t *pmd, unsigned int flags) { @@ -68919,7 +70547,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c if (unlikely(anon_vma_prepare(vma))) goto oom; page =3D alloc_zeroed_user_highpage_movable(vma, address); -@@ -3109,6 +3284,11 @@ static int do_anonymous_page(struct mm_s +@@ -3109,6 +3284,11 @@ static int do_anonymous_page(struct mm_struct *mm= , struct vm_area_struct *vma, if (!pte_none(*page_table)) goto release; =20 @@ -68944,7 +70572,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c unlock: pte_unmap_unlock(page_table, ptl); return 0; -@@ -3259,6 +3445,12 @@ static int __do_fault(struct mm_struct * +@@ -3259,6 +3445,12 @@ static int __do_fault(struct mm_struct *mm, struc= t vm_area_struct *vma, */ /* Only go through if we didn't race with anybody else... */ if (likely(pte_same(*page_table, orig_pte))) { @@ -68957,7 +70585,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c flush_icache_page(vma, page); entry =3D mk_pte(page, vma->vm_page_prot); if (flags & FAULT_FLAG_WRITE) -@@ -3278,6 +3470,14 @@ static int __do_fault(struct mm_struct * +@@ -3278,6 +3470,14 @@ static int __do_fault(struct mm_struct *mm, struc= t vm_area_struct *vma, =20 /* no need to invalidate: a not-present page won't be cached */ update_mmu_cache(vma, address, page_table); @@ -68972,7 +70600,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c } else { if (cow_page) mem_cgroup_uncharge_page(cow_page); -@@ -3431,6 +3631,12 @@ int handle_pte_fault(struct mm_struct *m +@@ -3431,6 +3631,12 @@ int handle_pte_fault(struct mm_struct *mm, if (flags & FAULT_FLAG_WRITE) flush_tlb_fix_spurious_fault(vma, address); } @@ -68985,7 +70613,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c unlock: pte_unmap_unlock(pte, ptl); return 0; -@@ -3447,6 +3653,10 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3447,6 +3653,10 @@ int handle_mm_fault(struct mm_struct *mm, struct = vm_area_struct *vma, pmd_t *pmd; pte_t *pte; =20 @@ -68996,7 +70624,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c __set_current_state(TASK_RUNNING); =20 count_vm_event(PGFAULT); -@@ -3458,6 +3668,34 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3458,6 +3668,34 @@ int handle_mm_fault(struct mm_struct *mm, struct = vm_area_struct *vma, if (unlikely(is_vm_hugetlb_page(vma))) return hugetlb_fault(mm, vma, address, flags); =20 @@ -69031,7 +70659,7 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/mm= /memory.c pgd =3D pgd_offset(mm, address); pud =3D pud_alloc(mm, pgd, address); if (!pud) -@@ -3487,7 +3725,7 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3487,7 +3725,7 @@ int handle_mm_fault(struct mm_struct *mm, struct v= m_area_struct *vma, * run pte_offset_map on the pmd, if an huge pmd could * materialize from under us from a different thread. */ @@ -69049,94 +70677,11 @@ diff -urNp linux-3.1.4/mm/memory.c linux-3.1.4/= mm/memory.c /* * Make sure the vDSO gets into every core dump. * Dumping its contents makes post-mortem fully interpretable later -diff -urNp linux-3.1.4/mm/memory-failure.c linux-3.1.4/mm/memory-failure= .c ---- linux-3.1.4/mm/memory-failure.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/memory-failure.c 2011-11-16 18:39:08.000000000 -0500 -@@ -60,7 +60,7 @@ int sysctl_memory_failure_early_kill __r -=20 - int sysctl_memory_failure_recovery __read_mostly =3D 1; -=20 --atomic_long_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INIT(0); -+atomic_long_unchecked_t mce_bad_pages __read_mostly =3D ATOMIC_LONG_INI= T(0); -=20 - #if defined(CONFIG_HWPOISON_INJECT) || defined(CONFIG_HWPOISON_INJECT_M= ODULE) -=20 -@@ -201,7 +201,7 @@ static int kill_proc_ao(struct task_stru - si.si_signo =3D SIGBUS; - si.si_errno =3D 0; - si.si_code =3D BUS_MCEERR_AO; -- si.si_addr =3D (void *)addr; -+ si.si_addr =3D (void __user *)addr; - #ifdef __ARCH_SI_TRAPNO - si.si_trapno =3D trapno; - #endif -@@ -1009,7 +1009,7 @@ int __memory_failure(unsigned long pfn,=20 - } -=20 - nr_pages =3D 1 << compound_trans_order(hpage); -- atomic_long_add(nr_pages, &mce_bad_pages); -+ atomic_long_add_unchecked(nr_pages, &mce_bad_pages); -=20 - /* - * We need/can do nothing about count=3D0 pages. -@@ -1039,7 +1039,7 @@ int __memory_failure(unsigned long pfn,=20 - if (!PageHWPoison(hpage) - || (hwpoison_filter(p) && TestClearPageHWPoison(p)) - || (p !=3D hpage && TestSetPageHWPoison(hpage))) { -- atomic_long_sub(nr_pages, &mce_bad_pages); -+ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); - return 0; - } - set_page_hwpoison_huge_page(hpage); -@@ -1097,7 +1097,7 @@ int __memory_failure(unsigned long pfn,=20 - } - if (hwpoison_filter(p)) { - if (TestClearPageHWPoison(p)) -- atomic_long_sub(nr_pages, &mce_bad_pages); -+ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); - unlock_page(hpage); - put_page(hpage); - return 0; -@@ -1314,7 +1314,7 @@ int unpoison_memory(unsigned long pfn) - return 0; - } - if (TestClearPageHWPoison(p)) -- atomic_long_sub(nr_pages, &mce_bad_pages); -+ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); - pr_info("MCE: Software-unpoisoned free page %#lx\n", pfn); - return 0; - } -@@ -1328,7 +1328,7 @@ int unpoison_memory(unsigned long pfn) - */ - if (TestClearPageHWPoison(page)) { - pr_info("MCE: Software-unpoisoned page %#lx\n", pfn); -- atomic_long_sub(nr_pages, &mce_bad_pages); -+ atomic_long_sub_unchecked(nr_pages, &mce_bad_pages); - freeit =3D 1; - if (PageHuge(page)) - clear_page_hwpoison_huge_page(page); -@@ -1441,7 +1441,7 @@ static int soft_offline_huge_page(struct - } - done: - if (!PageHWPoison(hpage)) -- atomic_long_add(1 << compound_trans_order(hpage), &mce_bad_pages); -+ atomic_long_add_unchecked(1 << compound_trans_order(hpage), &mce_bad_= pages); - set_page_hwpoison_huge_page(hpage); - dequeue_hwpoisoned_huge_page(hpage); - /* keep elevated page count for bad page */ -@@ -1572,7 +1572,7 @@ int soft_offline_page(struct page *page, - return ret; -=20 - done: -- atomic_long_add(1, &mce_bad_pages); -+ atomic_long_add_unchecked(1, &mce_bad_pages); - SetPageHWPoison(page); - /* keep elevated page count for bad page */ - return ret; -diff -urNp linux-3.1.4/mm/mempolicy.c linux-3.1.4/mm/mempolicy.c ---- linux-3.1.4/mm/mempolicy.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/mempolicy.c 2011-11-16 18:40:44.000000000 -0500 -@@ -639,6 +639,10 @@ static int mbind_range(struct mm_struct=20 +diff --git a/mm/mempolicy.c b/mm/mempolicy.c +index 9c51f9f..a9416cf 100644 +--- a/mm/mempolicy.c ++++ b/mm/mempolicy.c +@@ -639,6 +639,10 @@ static int mbind_range(struct mm_struct *mm, unsign= ed long start, unsigned long vmstart; unsigned long vmend; =20 @@ -69147,7 +70692,7 @@ diff -urNp linux-3.1.4/mm/mempolicy.c linux-3.1.4= /mm/mempolicy.c vma =3D find_vma_prev(mm, start, &prev); if (!vma || vma->vm_start > start) return -EFAULT; -@@ -669,6 +673,16 @@ static int mbind_range(struct mm_struct=20 +@@ -669,6 +673,16 @@ static int mbind_range(struct mm_struct *mm, unsign= ed long start, err =3D policy_vma(vma, new_pol); if (err) goto out; @@ -69164,7 +70709,7 @@ diff -urNp linux-3.1.4/mm/mempolicy.c linux-3.1.4= /mm/mempolicy.c } =20 out: -@@ -1102,6 +1116,17 @@ static long do_mbind(unsigned long start +@@ -1102,6 +1116,17 @@ static long do_mbind(unsigned long start, unsigne= d long len, =20 if (end < start) return -EINVAL; @@ -69182,7 +70727,7 @@ diff -urNp linux-3.1.4/mm/mempolicy.c linux-3.1.4= /mm/mempolicy.c if (end =3D=3D start) return 0; =20 -@@ -1320,6 +1345,14 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pi +@@ -1320,6 +1345,14 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pid, unsign= ed long, maxnode, if (!mm) goto out; =20 @@ -69197,7 +70742,7 @@ diff -urNp linux-3.1.4/mm/mempolicy.c linux-3.1.4= /mm/mempolicy.c /* * Check if this process has the right to modify the specified * process. The right exists if the process has administrative -@@ -1329,8 +1362,7 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pi +@@ -1329,8 +1362,7 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pid, unsigne= d long, maxnode, rcu_read_lock(); tcred =3D __task_cred(task); if (cred->euid !=3D tcred->suid && cred->euid !=3D tcred->uid && @@ -69207,10 +70752,11 @@ diff -urNp linux-3.1.4/mm/mempolicy.c linux-3.1= .4/mm/mempolicy.c rcu_read_unlock(); err =3D -EPERM; goto out; -diff -urNp linux-3.1.4/mm/migrate.c linux-3.1.4/mm/migrate.c ---- linux-3.1.4/mm/migrate.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/migrate.c 2011-11-16 18:40:44.000000000 -0500 -@@ -1124,6 +1124,8 @@ static int do_pages_move(struct mm_struc +diff --git a/mm/migrate.c b/mm/migrate.c +index 14d0a6a..81ffe69 100644 +--- a/mm/migrate.c ++++ b/mm/migrate.c +@@ -1124,6 +1124,8 @@ static int do_pages_move(struct mm_struct *mm, str= uct task_struct *task, unsigned long chunk_start; int err; =20 @@ -69219,7 +70765,7 @@ diff -urNp linux-3.1.4/mm/migrate.c linux-3.1.4/m= m/migrate.c task_nodes =3D cpuset_mems_allowed(task); =20 err =3D -ENOMEM; -@@ -1308,6 +1310,14 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid,=20 +@@ -1308,6 +1310,14 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, unsigned = long, nr_pages, if (!mm) return -EINVAL; =20 @@ -69234,7 +70780,7 @@ diff -urNp linux-3.1.4/mm/migrate.c linux-3.1.4/m= m/migrate.c /* * Check if this process has the right to modify the specified * process. The right exists if the process has administrative -@@ -1317,8 +1327,7 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid,=20 +@@ -1317,8 +1327,7 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, unsigned l= ong, nr_pages, rcu_read_lock(); tcred =3D __task_cred(task); if (cred->euid !=3D tcred->suid && cred->euid !=3D tcred->uid && @@ -69244,9 +70790,10 @@ diff -urNp linux-3.1.4/mm/migrate.c linux-3.1.4/= mm/migrate.c rcu_read_unlock(); err =3D -EPERM; goto out; -diff -urNp linux-3.1.4/mm/mlock.c linux-3.1.4/mm/mlock.c ---- linux-3.1.4/mm/mlock.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/mlock.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/mm/mlock.c b/mm/mlock.c +index 048260c..57f4a4e 100644 +--- a/mm/mlock.c ++++ b/mm/mlock.c @@ -13,6 +13,7 @@ #include #include @@ -69255,7 +70802,7 @@ diff -urNp linux-3.1.4/mm/mlock.c linux-3.1.4/mm/= mlock.c #include #include #include -@@ -377,6 +378,9 @@ static int do_mlock(unsigned long start, +@@ -377,6 +378,9 @@ static int do_mlock(unsigned long start, size_t len,= int on) return -EINVAL; if (end =3D=3D start) return 0; @@ -69265,7 +70812,7 @@ diff -urNp linux-3.1.4/mm/mlock.c linux-3.1.4/mm/= mlock.c vma =3D find_vma_prev(current->mm, start, &prev); if (!vma || vma->vm_start > start) return -ENOMEM; -@@ -387,6 +391,11 @@ static int do_mlock(unsigned long start, +@@ -387,6 +391,11 @@ static int do_mlock(unsigned long start, size_t len= , int on) for (nstart =3D start ; ; ) { vm_flags_t newflags; =20 @@ -69277,7 +70824,7 @@ diff -urNp linux-3.1.4/mm/mlock.c linux-3.1.4/mm/= mlock.c /* Here we know that vma->vm_start <=3D nstart < vma->vm_end. */ =20 newflags =3D vma->vm_flags | VM_LOCKED; -@@ -492,6 +501,7 @@ SYSCALL_DEFINE2(mlock, unsigned long, st +@@ -492,6 +501,7 @@ SYSCALL_DEFINE2(mlock, unsigned long, start, size_t,= len) lock_limit >>=3D PAGE_SHIFT; =20 /* check against resource limits */ @@ -69285,7 +70832,7 @@ diff -urNp linux-3.1.4/mm/mlock.c linux-3.1.4/mm/= mlock.c if ((locked <=3D lock_limit) || capable(CAP_IPC_LOCK)) error =3D do_mlock(start, len, 1); up_write(¤t->mm->mmap_sem); -@@ -515,17 +525,23 @@ SYSCALL_DEFINE2(munlock, unsigned long,=20 +@@ -515,17 +525,23 @@ SYSCALL_DEFINE2(munlock, unsigned long, start, siz= e_t, len) static int do_mlockall(int flags) { struct vm_area_struct * vma, * prev =3D NULL; @@ -69320,9 +70867,10 @@ diff -urNp linux-3.1.4/mm/mlock.c linux-3.1.4/mm= /mlock.c if (!(flags & MCL_CURRENT) || (current->mm->total_vm <=3D lock_limit) = || capable(CAP_IPC_LOCK)) ret =3D do_mlockall(flags); -diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/mmap.c ---- linux-3.1.4/mm/mmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/mmap.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/mm/mmap.c b/mm/mmap.c +index a65efd4..17d61ff 100644 +--- a/mm/mmap.c ++++ b/mm/mmap.c @@ -46,6 +46,16 @@ #define arch_rebalance_pgtables(addr, len) (addr) #endif @@ -69340,7 +70888,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c static void unmap_region(struct mm_struct *mm, struct vm_area_struct *vma, struct vm_area_struct *prev, unsigned long start, unsigned long end); -@@ -71,22 +81,32 @@ static void unmap_region(struct mm_struc +@@ -71,22 +81,32 @@ static void unmap_region(struct mm_struct *mm, * x: (no) no x: (no) yes x: (no) yes x: (yes) yes * */ @@ -69376,7 +70924,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * Make sure vm_committed_as in one cacheline and not cacheline shared = with * other variables. It can be updated by several CPUs frequently. -@@ -228,6 +248,7 @@ static struct vm_area_struct *remove_vma +@@ -228,6 +248,7 @@ static struct vm_area_struct *remove_vma(struct vm_a= rea_struct *vma) struct vm_area_struct *next =3D vma->vm_next; =20 might_sleep(); @@ -69418,7 +70966,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (is_mergeable_vma(vma, file, vm_flags) && is_mergeable_anon_vma(anon_vma, vma->anon_vma, vma)) { pgoff_t vm_pglen; -@@ -750,13 +784,20 @@ can_vma_merge_after(struct vm_area_struc +@@ -750,13 +784,20 @@ can_vma_merge_after(struct vm_area_struct *vma, un= signed long vm_flags, struct vm_area_struct *vma_merge(struct mm_struct *mm, struct vm_area_struct *prev, unsigned long addr, unsigned long end, unsigned long vm_flags, @@ -69440,7 +70988,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * We later require that vma->vm_flags =3D=3D vm_flags, * so this tests vma->vm_flags & VM_SPECIAL, too. -@@ -772,6 +813,15 @@ struct vm_area_struct *vma_merge(struct=20 +@@ -772,6 +813,15 @@ struct vm_area_struct *vma_merge(struct mm_struct *= mm, if (next && next->vm_end =3D=3D end) /* cases 6, 7, 8 */ next =3D next->vm_next; =20 @@ -69456,7 +71004,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * Can it merge with the predecessor? */ -@@ -791,9 +841,24 @@ struct vm_area_struct *vma_merge(struct=20 +@@ -791,9 +841,24 @@ struct vm_area_struct *vma_merge(struct mm_struct *= mm, /* cases 1, 6 */ err =3D vma_adjust(prev, prev->vm_start, next->vm_end, prev->vm_pgoff, NULL); @@ -69482,7 +71030,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (err) return NULL; khugepaged_enter_vma_merge(prev); -@@ -807,12 +872,27 @@ struct vm_area_struct *vma_merge(struct=20 +@@ -807,12 +872,27 @@ struct vm_area_struct *vma_merge(struct mm_struct = *mm, mpol_equal(policy, vma_policy(next)) && can_vma_merge_before(next, vm_flags, anon_vma, file, pgoff+pglen)) { @@ -69528,7 +71076,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c mm->stack_vm +=3D pages; if (flags & (VM_RESERVED|VM_IO)) mm->reserved_vm +=3D pages; -@@ -955,7 +1032,7 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -955,7 +1032,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsi= gned long addr, * (the exception is when the underlying filesystem is noexec * mounted, in which case we dont add PROT_EXEC.) */ @@ -69537,7 +71085,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (!(file && (file->f_path.mnt->mnt_flags & MNT_NOEXEC))) prot |=3D PROT_EXEC; =20 -@@ -981,7 +1058,7 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -981,7 +1058,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsi= gned long addr, /* Obtain the address to map to. we verify (or select) it and ensure * that it represents a valid section of the address space. */ @@ -69546,7 +71094,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (addr & ~PAGE_MASK) return addr; =20 -@@ -992,6 +1069,36 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -992,6 +1069,36 @@ unsigned long do_mmap_pgoff(struct file *file, uns= igned long addr, vm_flags =3D calc_vm_prot_bits(prot) | calc_vm_flag_bits(flags) | mm->def_flags | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC; =20 @@ -69583,7 +71131,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (flags & MAP_LOCKED) if (!can_do_mlock()) return -EPERM; -@@ -1003,6 +1110,7 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -1003,6 +1110,7 @@ unsigned long do_mmap_pgoff(struct file *file, uns= igned long addr, locked +=3D mm->locked_vm; lock_limit =3D rlimit(RLIMIT_MEMLOCK); lock_limit >>=3D PAGE_SHIFT; @@ -69591,7 +71139,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (locked > lock_limit && !capable(CAP_IPC_LOCK)) return -EAGAIN; } -@@ -1073,6 +1181,9 @@ unsigned long do_mmap_pgoff(struct file=20 +@@ -1073,6 +1181,9 @@ unsigned long do_mmap_pgoff(struct file *file, uns= igned long addr, if (error) return error; =20 @@ -69601,7 +71149,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c return mmap_region(file, addr, len, flags, vm_flags, pgoff); } EXPORT_SYMBOL(do_mmap_pgoff); -@@ -1153,7 +1264,7 @@ int vma_wants_writenotify(struct vm_area +@@ -1153,7 +1264,7 @@ int vma_wants_writenotify(struct vm_area_struct *v= ma) vm_flags_t vm_flags =3D vma->vm_flags; =20 /* If it was private or non-writable, the write bit is already clear *= / @@ -69610,7 +71158,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c return 0; =20 /* The backer wishes to know when pages are first written to? */ -@@ -1202,14 +1313,24 @@ unsigned long mmap_region(struct file *f +@@ -1202,14 +1313,24 @@ unsigned long mmap_region(struct file *file, uns= igned long addr, unsigned long charged =3D 0; struct inode *inode =3D file ? file->f_path.dentry->d_inode : NULL; =20 @@ -69752,7 +71300,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* Get an address range which is currently unmapped. * For shmat() with addr=3D0. * -@@ -1374,18 +1568,23 @@ arch_get_unmapped_area(struct file *filp +@@ -1374,18 +1568,23 @@ arch_get_unmapped_area(struct file *filp, unsign= ed long addr, if (flags & MAP_FIXED) return addr; =20 @@ -69835,7 +71383,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c mm->free_area_cache =3D addr; mm->cached_hole_size =3D ~0UL; } -@@ -1441,7 +1646,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1441,7 +1646,7 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, { struct vm_area_struct *vma; struct mm_struct *mm =3D current->mm; @@ -69844,7 +71392,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c =20 /* requested length too big for entire address space */ if (len > TASK_SIZE) -@@ -1450,13 +1655,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1450,13 +1655,18 @@ arch_get_unmapped_area_topdown(struct file *filp= , const unsigned long addr0, if (flags & MAP_FIXED) return addr; =20 @@ -69867,7 +71415,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c } =20 /* check if free_area_cache is useful for us */ -@@ -1471,7 +1681,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1471,7 +1681,7 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, /* make sure it can fit in the remaining address space */ if (addr > len) { vma =3D find_vma(mm, addr-len); @@ -69876,7 +71424,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr-len); } -@@ -1488,7 +1698,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1488,7 +1698,7 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, * return with success: */ vma =3D find_vma(mm, addr); @@ -69885,7 +71433,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* remember the address as a hint for next time */ return (mm->free_area_cache =3D addr); =20 -@@ -1497,8 +1707,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1497,8 +1707,8 @@ arch_get_unmapped_area_topdown(struct file *filp, = const unsigned long addr0, mm->cached_hole_size =3D vma->vm_start - addr; =20 /* try just below the current vma->vm_start */ @@ -69933,7 +71481,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * Is this a new hole at the highest possible address? */ -@@ -1529,8 +1753,10 @@ void arch_unmap_area_topdown(struct mm_s +@@ -1529,8 +1753,10 @@ void arch_unmap_area_topdown(struct mm_struct *mm= , unsigned long addr) mm->free_area_cache =3D addr; =20 /* dont allow allocations above current base */ @@ -69974,7 +71522,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * Verify that the stack growth is acceptable and * update accounting. This is shared with both the -@@ -1654,6 +1902,7 @@ static int acct_stack_growth(struct vm_a +@@ -1654,6 +1902,7 @@ static int acct_stack_growth(struct vm_area_struct= *vma, unsigned long size, uns return -ENOMEM; =20 /* Stack limit test */ @@ -69982,7 +71530,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (size > ACCESS_ONCE(rlim[RLIMIT_STACK].rlim_cur)) return -ENOMEM; =20 -@@ -1664,6 +1913,7 @@ static int acct_stack_growth(struct vm_a +@@ -1664,6 +1913,7 @@ static int acct_stack_growth(struct vm_area_struct= *vma, unsigned long size, uns locked =3D mm->locked_vm + grow; limit =3D ACCESS_ONCE(rlim[RLIMIT_MEMLOCK].rlim_cur); limit >>=3D PAGE_SHIFT; @@ -69990,7 +71538,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (locked > limit && !capable(CAP_IPC_LOCK)) return -ENOMEM; } -@@ -1694,37 +1944,48 @@ static int acct_stack_growth(struct vm_a +@@ -1694,37 +1944,48 @@ static int acct_stack_growth(struct vm_area_stru= ct *vma, unsigned long size, uns * PA-RISC uses this for its stack; IA64 for its Register Backing Store= . * vma is the last one with address > vma->vm_end. Have to extend vma. */ @@ -70048,7 +71596,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c unsigned long size, grow; =20 size =3D address - vma->vm_start; -@@ -1739,6 +2000,8 @@ int expand_upwards(struct vm_area_struct +@@ -1739,6 +2000,8 @@ int expand_upwards(struct vm_area_struct *vma, uns= igned long address) } } } @@ -70057,7 +71605,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c vma_unlock_anon_vma(vma); khugepaged_enter_vma_merge(vma); return error; -@@ -1752,6 +2015,8 @@ int expand_downwards(struct vm_area_stru +@@ -1752,6 +2015,8 @@ int expand_downwards(struct vm_area_struct *vma, unsigned long address) { int error; @@ -70066,7 +71614,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c =20 /* * We must make sure the anon_vma is allocated -@@ -1765,6 +2030,15 @@ int expand_downwards(struct vm_area_stru +@@ -1765,6 +2030,15 @@ int expand_downwards(struct vm_area_struct *vma, if (error) return error; =20 @@ -70082,7 +71630,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c vma_lock_anon_vma(vma); =20 /* -@@ -1774,9 +2048,17 @@ int expand_downwards(struct vm_area_stru +@@ -1774,9 +2048,17 @@ int expand_downwards(struct vm_area_struct *vma, */ =20 /* Somebody else might have raced and expanded it already */ @@ -70101,7 +71649,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c size =3D vma->vm_end - address; grow =3D (vma->vm_start - address) >> PAGE_SHIFT; =20 -@@ -1786,11 +2068,22 @@ int expand_downwards(struct vm_area_stru +@@ -1786,11 +2068,22 @@ int expand_downwards(struct vm_area_struct *vma, if (!error) { vma->vm_start =3D address; vma->vm_pgoff -=3D grow; @@ -70124,7 +71672,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c khugepaged_enter_vma_merge(vma); return error; } -@@ -1860,6 +2153,13 @@ static void remove_vma_list(struct mm_st +@@ -1860,6 +2153,13 @@ static void remove_vma_list(struct mm_struct *mm,= struct vm_area_struct *vma) do { long nrpages =3D vma_pages(vma); =20 @@ -70138,7 +71686,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c mm->total_vm -=3D nrpages; vm_stat_account(mm, vma->vm_flags, vma->vm_file, -nrpages); vma =3D remove_vma(vma); -@@ -1905,6 +2205,16 @@ detach_vmas_to_be_unmapped(struct mm_str +@@ -1905,6 +2205,16 @@ detach_vmas_to_be_unmapped(struct mm_struct *mm, = struct vm_area_struct *vma, insertion_point =3D (prev ? &prev->vm_next : &mm->mmap); vma->vm_prev =3D NULL; do { @@ -70155,7 +71703,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c rb_erase(&vma->vm_rb, &mm->mm_rb); mm->map_count--; tail_vma =3D vma; -@@ -1933,14 +2243,33 @@ static int __split_vma(struct mm_struct=20 +@@ -1933,14 +2243,33 @@ static int __split_vma(struct mm_struct * mm, st= ruct vm_area_struct * vma, struct vm_area_struct *new; int err =3D -ENOMEM; =20 @@ -70189,7 +71737,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* most fields are the same, copy all, and then fixup */ *new =3D *vma; =20 -@@ -1953,6 +2282,22 @@ static int __split_vma(struct mm_struct=20 +@@ -1953,6 +2282,22 @@ static int __split_vma(struct mm_struct * mm, str= uct vm_area_struct * vma, new->vm_pgoff +=3D ((addr - vma->vm_start) >> PAGE_SHIFT); } =20 @@ -70212,7 +71760,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c pol =3D mpol_dup(vma_policy(vma)); if (IS_ERR(pol)) { err =3D PTR_ERR(pol); -@@ -1978,6 +2323,42 @@ static int __split_vma(struct mm_struct=20 +@@ -1978,6 +2323,42 @@ static int __split_vma(struct mm_struct * mm, str= uct vm_area_struct * vma, else err =3D vma_adjust(vma, vma->vm_start, addr, vma->vm_pgoff, new); =20 @@ -70255,7 +71803,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* Success. */ if (!err) return 0; -@@ -1990,10 +2371,18 @@ static int __split_vma(struct mm_struct=20 +@@ -1990,10 +2371,18 @@ static int __split_vma(struct mm_struct * mm, st= ruct vm_area_struct * vma, removed_exe_file_vma(mm); fput(new->vm_file); } @@ -70275,7 +71823,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c kmem_cache_free(vm_area_cachep, new); out_err: return err; -@@ -2006,6 +2395,15 @@ static int __split_vma(struct mm_struct=20 +@@ -2006,6 +2395,15 @@ static int __split_vma(struct mm_struct * mm, str= uct vm_area_struct * vma, int split_vma(struct mm_struct *mm, struct vm_area_struct *vma, unsigned long addr, int new_below) { @@ -70291,7 +71839,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (mm->map_count >=3D sysctl_max_map_count) return -ENOMEM; =20 -@@ -2017,11 +2415,30 @@ int split_vma(struct mm_struct *mm, stru +@@ -2017,11 +2415,30 @@ int split_vma(struct mm_struct *mm, struct vm_ar= ea_struct *vma, * work. This now handles partial unmappings. * Jeremy Fitzhardinge */ @@ -70322,7 +71870,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if ((start & ~PAGE_MASK) || start > TASK_SIZE || len > TASK_SIZE-start= ) return -EINVAL; =20 -@@ -2096,6 +2513,8 @@ int do_munmap(struct mm_struct *mm, unsi +@@ -2096,6 +2513,8 @@ int do_munmap(struct mm_struct *mm, unsigned long = start, size_t len) /* Fix up all other VM information */ remove_vma_list(mm, vma); =20 @@ -70331,7 +71879,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c return 0; } =20 -@@ -2108,22 +2527,18 @@ SYSCALL_DEFINE2(munmap, unsigned long, a +@@ -2108,22 +2527,18 @@ SYSCALL_DEFINE2(munmap, unsigned long, addr, siz= e_t, len) =20 profile_munmap(addr); =20 @@ -70360,7 +71908,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * this is really a simplified "do_mmap". it only handles * anonymous maps. eventually we may be able to do some -@@ -2137,6 +2552,7 @@ unsigned long do_brk(unsigned long addr, +@@ -2137,6 +2552,7 @@ unsigned long do_brk(unsigned long addr, unsigned = long len) struct rb_node ** rb_link, * rb_parent; pgoff_t pgoff =3D addr >> PAGE_SHIFT; int error; @@ -70368,7 +71916,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c =20 len =3D PAGE_ALIGN(len); if (!len) -@@ -2148,16 +2564,30 @@ unsigned long do_brk(unsigned long addr, +@@ -2148,16 +2564,30 @@ unsigned long do_brk(unsigned long addr, unsigne= d long len) =20 flags =3D VM_DATA_DEFAULT_FLAGS | VM_ACCOUNT | mm->def_flags; =20 @@ -70400,7 +71948,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c locked +=3D mm->locked_vm; lock_limit =3D rlimit(RLIMIT_MEMLOCK); lock_limit >>=3D PAGE_SHIFT; -@@ -2174,22 +2604,22 @@ unsigned long do_brk(unsigned long addr, +@@ -2174,22 +2604,22 @@ unsigned long do_brk(unsigned long addr, unsigne= d long len) /* * Clear old maps. this also does some error checking for us */ @@ -70427,7 +71975,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c return -ENOMEM; =20 /* Can we just expand an old private anonymous mapping? */ -@@ -2203,7 +2633,7 @@ unsigned long do_brk(unsigned long addr, +@@ -2203,7 +2633,7 @@ unsigned long do_brk(unsigned long addr, unsigned = long len) */ vma =3D kmem_cache_zalloc(vm_area_cachep, GFP_KERNEL); if (!vma) { @@ -70436,7 +71984,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c return -ENOMEM; } =20 -@@ -2217,11 +2647,12 @@ unsigned long do_brk(unsigned long addr, +@@ -2217,11 +2647,12 @@ unsigned long do_brk(unsigned long addr, unsigne= d long len) vma_link(mm, vma, prev, rb_link, rb_parent); out: perf_event_mmap(vma); @@ -70463,7 +72011,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c =20 BUG_ON(mm->nr_ptes > (FIRST_USER_ADDRESS+PMD_SIZE-1)>>PMD_SHIFT); } -@@ -2283,6 +2716,13 @@ int insert_vm_struct(struct mm_struct *=20 +@@ -2283,6 +2716,13 @@ int insert_vm_struct(struct mm_struct * mm, struc= t vm_area_struct * vma) struct vm_area_struct * __vma, * prev; struct rb_node ** rb_link, * rb_parent; =20 @@ -70477,7 +72025,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * The vm_pgoff of a purely anonymous vma should be irrelevant * until its first write fault, when page's anon_vma and index -@@ -2305,7 +2745,22 @@ int insert_vm_struct(struct mm_struct *=20 +@@ -2305,7 +2745,22 @@ int insert_vm_struct(struct mm_struct * mm, struc= t vm_area_struct * vma) if ((vma->vm_flags & VM_ACCOUNT) && security_vm_enough_memory_mm(mm, vma_pages(vma))) return -ENOMEM; @@ -70500,7 +72048,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c return 0; } =20 -@@ -2323,6 +2778,8 @@ struct vm_area_struct *copy_vma(struct v +@@ -2323,6 +2778,8 @@ struct vm_area_struct *copy_vma(struct vm_area_str= uct **vmap, struct rb_node **rb_link, *rb_parent; struct mempolicy *pol; =20 @@ -70509,7 +72057,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * If anonymous vma has not yet been faulted, update new pgoff * to match new location, to increase its chance of merging. -@@ -2373,6 +2830,39 @@ struct vm_area_struct *copy_vma(struct v +@@ -2373,6 +2830,39 @@ struct vm_area_struct *copy_vma(struct vm_area_st= ruct **vmap, return NULL; } =20 @@ -70549,7 +72097,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c /* * Return true if the calling process may expand its vm space by the pa= ssed * number of pages -@@ -2383,7 +2873,7 @@ int may_expand_vm(struct mm_struct *mm,=20 +@@ -2383,7 +2873,7 @@ int may_expand_vm(struct mm_struct *mm, unsigned l= ong npages) unsigned long lim; =20 lim =3D rlimit(RLIMIT_AS) >> PAGE_SHIFT; @@ -70558,7 +72106,7 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/m= map.c if (cur + npages > lim) return 0; return 1; -@@ -2454,6 +2944,22 @@ int install_special_mapping(struct mm_st +@@ -2454,6 +2944,22 @@ int install_special_mapping(struct mm_struct *mm, vma->vm_start =3D addr; vma->vm_end =3D addr + len; =20 @@ -70581,9 +72129,10 @@ diff -urNp linux-3.1.4/mm/mmap.c linux-3.1.4/mm/= mmap.c vma->vm_flags =3D vm_flags | mm->def_flags | VM_DONTEXPAND; vma->vm_page_prot =3D vm_get_page_prot(vma->vm_flags); =20 -diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/mm/mprotect.c ---- linux-3.1.4/mm/mprotect.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/mprotect.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/mm/mprotect.c b/mm/mprotect.c +index 5a688a2..27e031c 100644 +--- a/mm/mprotect.c ++++ b/mm/mprotect.c @@ -23,10 +23,16 @@ #include #include @@ -70601,7 +72150,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c =20 #ifndef pgprot_modify static inline pgprot_t pgprot_modify(pgprot_t oldprot, pgprot_t newprot= ) -@@ -141,6 +147,48 @@ static void change_protection(struct vm_ +@@ -141,6 +147,48 @@ static void change_protection(struct vm_area_struct= *vma, flush_tlb_range(vma, start, end); } =20 @@ -70650,7 +72199,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c int mprotect_fixup(struct vm_area_struct *vma, struct vm_area_struct **ppre= v, unsigned long start, unsigned long end, unsigned long newflags) -@@ -153,11 +201,29 @@ mprotect_fixup(struct vm_area_struct *vm +@@ -153,11 +201,29 @@ mprotect_fixup(struct vm_area_struct *vma, struct = vm_area_struct **pprev, int error; int dirty_accountable =3D 0; =20 @@ -70680,7 +72229,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c /* * If we make a private mapping writable we increase our commit; * but (without finer accounting) cannot reduce our commit if we -@@ -174,6 +240,42 @@ mprotect_fixup(struct vm_area_struct *vm +@@ -174,6 +240,42 @@ mprotect_fixup(struct vm_area_struct *vma, struct v= m_area_struct **pprev, } } =20 @@ -70746,7 +72295,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c =20 if (vma_wants_writenotify(vma)) { vma->vm_page_prot =3D vm_get_page_prot(newflags & ~VM_SHARED); -@@ -248,6 +362,17 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -248,6 +362,17 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, siz= e_t, len, end =3D start + len; if (end <=3D start) return -ENOMEM; @@ -70764,7 +72313,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c if (!arch_validate_prot(prot)) return -EINVAL; =20 -@@ -255,7 +380,7 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -255,7 +380,7 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, size= _t, len, /* * Does the application expect PROT_READ to imply PROT_EXEC: */ @@ -70773,7 +72322,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c prot |=3D PROT_EXEC; =20 vm_flags =3D calc_vm_prot_bits(prot); -@@ -287,6 +412,11 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -287,6 +412,11 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, siz= e_t, len, if (start > vma->vm_start) prev =3D vma; =20 @@ -70785,7 +72334,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c for (nstart =3D start ; ; ) { unsigned long newflags; =20 -@@ -296,6 +426,14 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -296,6 +426,14 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, siz= e_t, len, =20 /* newflags >> 4 shift VM_MAY% in place of VM_% */ if ((newflags & ~(newflags >> 4)) & (VM_READ | VM_WRITE | VM_EXEC)) { @@ -70800,7 +72349,7 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.4/= mm/mprotect.c error =3D -EACCES; goto out; } -@@ -310,6 +448,9 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -310,6 +448,9 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, size= _t, len, error =3D mprotect_fixup(vma, &prev, nstart, tmp, newflags); if (error) goto out; @@ -70810,10 +72359,11 @@ diff -urNp linux-3.1.4/mm/mprotect.c linux-3.1.= 4/mm/mprotect.c nstart =3D tmp; =20 if (nstart < prev->vm_end) -diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/mm/mremap.c ---- linux-3.1.4/mm/mremap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/mremap.c 2011-11-16 18:39:08.000000000 -0500 -@@ -113,6 +113,12 @@ static void move_ptes(struct vm_area_str +diff --git a/mm/mremap.c b/mm/mremap.c +index 506fa44..ccc0ba9 100644 +--- a/mm/mremap.c ++++ b/mm/mremap.c +@@ -113,6 +113,12 @@ static void move_ptes(struct vm_area_struct *vma, p= md_t *old_pmd, continue; pte =3D ptep_clear_flush(vma, old_addr, old_pte); pte =3D move_pte(pte, new_vma->vm_page_prot, old_addr, new_addr); @@ -70826,7 +72376,7 @@ diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/mm= /mremap.c set_pte_at(mm, new_addr, new_pte, pte); } =20 -@@ -272,6 +278,11 @@ static struct vm_area_struct *vma_to_res +@@ -272,6 +278,11 @@ static struct vm_area_struct *vma_to_resize(unsigne= d long addr, if (is_vm_hugetlb_page(vma)) goto Einval; =20 @@ -70838,7 +72388,7 @@ diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/mm= /mremap.c /* We can't remap across vm area boundaries */ if (old_len > vma->vm_end - addr) goto Efault; -@@ -328,20 +339,25 @@ static unsigned long mremap_to(unsigned=20 +@@ -328,20 +339,25 @@ static unsigned long mremap_to(unsigned long addr, unsigned long ret =3D -EINVAL; unsigned long charged =3D 0; unsigned long map_flags; @@ -70869,7 +72419,7 @@ diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/mm= /mremap.c goto out; =20 ret =3D security_file_mmap(NULL, 0, 0, 0, new_addr, 1); -@@ -413,6 +429,7 @@ unsigned long do_mremap(unsigned long ad +@@ -413,6 +429,7 @@ unsigned long do_mremap(unsigned long addr, struct vm_area_struct *vma; unsigned long ret =3D -EINVAL; unsigned long charged =3D 0; @@ -70877,7 +72427,7 @@ diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/mm= /mremap.c =20 if (flags & ~(MREMAP_FIXED | MREMAP_MAYMOVE)) goto out; -@@ -431,6 +448,17 @@ unsigned long do_mremap(unsigned long ad +@@ -431,6 +448,17 @@ unsigned long do_mremap(unsigned long addr, if (!new_len) goto out; =20 @@ -70895,7 +72445,7 @@ diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/mm= /mremap.c if (flags & MREMAP_FIXED) { if (flags & MREMAP_MAYMOVE) ret =3D mremap_to(addr, old_len, new_addr, new_len); -@@ -480,6 +508,7 @@ unsigned long do_mremap(unsigned long ad +@@ -480,6 +508,7 @@ unsigned long do_mremap(unsigned long addr, addr + new_len); } ret =3D addr; @@ -70903,7 +72453,7 @@ diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/mm= /mremap.c goto out; } } -@@ -506,7 +535,13 @@ unsigned long do_mremap(unsigned long ad +@@ -506,7 +535,13 @@ unsigned long do_mremap(unsigned long addr, ret =3D security_file_mmap(NULL, 0, 0, 0, new_addr, 1); if (ret) goto out; @@ -70917,10 +72467,11 @@ diff -urNp linux-3.1.4/mm/mremap.c linux-3.1.4/= mm/mremap.c } out: if (ret & ~PAGE_MASK) -diff -urNp linux-3.1.4/mm/nobootmem.c linux-3.1.4/mm/nobootmem.c ---- linux-3.1.4/mm/nobootmem.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/nobootmem.c 2011-11-16 18:39:08.000000000 -0500 -@@ -110,19 +110,30 @@ static void __init __free_pages_memory(u +diff --git a/mm/nobootmem.c b/mm/nobootmem.c +index 6e93dc7..c98df0c 100644 +--- a/mm/nobootmem.c ++++ b/mm/nobootmem.c +@@ -110,19 +110,30 @@ static void __init __free_pages_memory(unsigned lo= ng start, unsigned long end) unsigned long __init free_all_memory_core_early(int nodeid) { int i; @@ -70953,10 +72504,11 @@ diff -urNp linux-3.1.4/mm/nobootmem.c linux-3.1= .4/mm/nobootmem.c =20 return count; } -diff -urNp linux-3.1.4/mm/nommu.c linux-3.1.4/mm/nommu.c ---- linux-3.1.4/mm/nommu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/nommu.c 2011-11-16 18:39:08.000000000 -0500 -@@ -62,7 +62,6 @@ int sysctl_overcommit_memory =3D OVERCOMMI +diff --git a/mm/nommu.c b/mm/nommu.c +index 4358032..e79b99f 100644 +--- a/mm/nommu.c ++++ b/mm/nommu.c +@@ -62,7 +62,6 @@ int sysctl_overcommit_memory =3D OVERCOMMIT_GUESS; /* = heuristic overcommit */ int sysctl_overcommit_ratio =3D 50; /* default is 50% */ int sysctl_max_map_count =3D DEFAULT_MAX_MAP_COUNT; int sysctl_nr_trim_pages =3D CONFIG_NOMMU_INITIAL_TRIM_EXCESS; @@ -70964,7 +72516,7 @@ diff -urNp linux-3.1.4/mm/nommu.c linux-3.1.4/mm/= nommu.c =20 atomic_long_t mmap_pages_allocated; =20 -@@ -825,15 +824,6 @@ struct vm_area_struct *find_vma(struct m +@@ -825,15 +824,6 @@ struct vm_area_struct *find_vma(struct mm_struct *m= m, unsigned long addr) EXPORT_SYMBOL(find_vma); =20 /* @@ -70980,7 +72532,7 @@ diff -urNp linux-3.1.4/mm/nommu.c linux-3.1.4/mm/= nommu.c * expand a stack to a given address * - not supported under NOMMU conditions */ -@@ -1553,6 +1543,7 @@ int split_vma(struct mm_struct *mm, stru +@@ -1553,6 +1543,7 @@ int split_vma(struct mm_struct *mm, struct vm_area= _struct *vma, =20 /* most fields are the same, copy all, and then fixup */ *new =3D *vma; @@ -70988,10 +72540,11 @@ diff -urNp linux-3.1.4/mm/nommu.c linux-3.1.4/m= m/nommu.c *region =3D *vma->vm_region; new->vm_region =3D region; =20 -diff -urNp linux-3.1.4/mm/oom_kill.c linux-3.1.4/mm/oom_kill.c ---- linux-3.1.4/mm/oom_kill.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/oom_kill.c 2011-11-18 18:44:21.000000000 -0500 -@@ -162,7 +162,7 @@ static bool oom_unkillable_task(struct t +diff --git a/mm/oom_kill.c b/mm/oom_kill.c +index 626303b..e9a1785 100644 +--- a/mm/oom_kill.c ++++ b/mm/oom_kill.c +@@ -162,7 +162,7 @@ static bool oom_unkillable_task(struct task_struct *= p, unsigned int oom_badness(struct task_struct *p, struct mem_cgroup *mem, const nodemask_t *nodemask, unsigned long totalpages) { @@ -71000,9 +72553,10 @@ diff -urNp linux-3.1.4/mm/oom_kill.c linux-3.1.4= /mm/oom_kill.c =20 if (oom_unkillable_task(p, mem, nodemask)) return 0; -diff -urNp linux-3.1.4/mm/page_alloc.c linux-3.1.4/mm/page_alloc.c ---- linux-3.1.4/mm/page_alloc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/page_alloc.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/mm/page_alloc.c b/mm/page_alloc.c +index 6e8ecb6..50b8879 100644 +--- a/mm/page_alloc.c ++++ b/mm/page_alloc.c @@ -340,7 +340,7 @@ out: * This usage means that zero-order pages may not be compound. */ @@ -71012,7 +72566,7 @@ diff -urNp linux-3.1.4/mm/page_alloc.c linux-3.1.= 4/mm/page_alloc.c { __free_pages_ok(page, compound_order(page)); } -@@ -653,6 +653,10 @@ static bool free_pages_prepare(struct pa +@@ -653,6 +653,10 @@ static bool free_pages_prepare(struct page *page, u= nsigned int order) int i; int bad =3D 0; =20 @@ -71023,7 +72577,7 @@ diff -urNp linux-3.1.4/mm/page_alloc.c linux-3.1.= 4/mm/page_alloc.c trace_mm_page_free_direct(page, order); kmemcheck_free_shadow(page, order); =20 -@@ -668,6 +672,12 @@ static bool free_pages_prepare(struct pa +@@ -668,6 +672,12 @@ static bool free_pages_prepare(struct page *page, u= nsigned int order) debug_check_no_obj_freed(page_address(page), PAGE_SIZE << order); } @@ -71036,7 +72590,7 @@ diff -urNp linux-3.1.4/mm/page_alloc.c linux-3.1.= 4/mm/page_alloc.c arch_free_page(page, order); kernel_map_pages(page, 1 << order, 0); =20 -@@ -783,8 +793,10 @@ static int prep_new_page(struct page *pa +@@ -783,8 +793,10 @@ static int prep_new_page(struct page *page, int ord= er, gfp_t gfp_flags) arch_alloc_page(page, order); kernel_map_pages(page, 1 << order, 1); =20 @@ -71047,7 +72601,7 @@ diff -urNp linux-3.1.4/mm/page_alloc.c linux-3.1.= 4/mm/page_alloc.c =20 if (order && (gfp_flags & __GFP_COMP)) prep_compound_page(page, order); -@@ -2539,6 +2551,8 @@ void show_free_areas(unsigned int filter +@@ -2539,6 +2551,8 @@ void show_free_areas(unsigned int filter) int cpu; struct zone *zone; =20 @@ -71056,7 +72610,7 @@ diff -urNp linux-3.1.4/mm/page_alloc.c linux-3.1.= 4/mm/page_alloc.c for_each_populated_zone(zone) { if (skip_free_areas_node(filter, zone_to_nid(zone))) continue; -@@ -3350,7 +3364,13 @@ static int pageblock_is_reserved(unsigne +@@ -3350,7 +3364,13 @@ static int pageblock_is_reserved(unsigned long st= art_pfn, unsigned long end_pfn) unsigned long pfn; =20 for (pfn =3D start_pfn; pfn < end_pfn; pfn++) { @@ -71070,10 +72624,11 @@ diff -urNp linux-3.1.4/mm/page_alloc.c linux-3.= 1.4/mm/page_alloc.c return 1; } return 0; -diff -urNp linux-3.1.4/mm/percpu.c linux-3.1.4/mm/percpu.c ---- linux-3.1.4/mm/percpu.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/percpu.c 2011-11-16 18:39:08.000000000 -0500 -@@ -121,7 +121,7 @@ static unsigned int pcpu_first_unit_cpu=20 +diff --git a/mm/percpu.c b/mm/percpu.c +index bf80e55..c7c3f9a 100644 +--- a/mm/percpu.c ++++ b/mm/percpu.c +@@ -121,7 +121,7 @@ static unsigned int pcpu_first_unit_cpu __read_mostl= y; static unsigned int pcpu_last_unit_cpu __read_mostly; =20 /* the address of the first chunk which starts with the kernel static a= rea */ @@ -71082,10 +72637,11 @@ diff -urNp linux-3.1.4/mm/percpu.c linux-3.1.4/= mm/percpu.c EXPORT_SYMBOL_GPL(pcpu_base_addr); =20 static const int *pcpu_unit_map __read_mostly; /* cpu -> unit */ -diff -urNp linux-3.1.4/mm/rmap.c linux-3.1.4/mm/rmap.c ---- linux-3.1.4/mm/rmap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/rmap.c 2011-11-16 18:39:08.000000000 -0500 -@@ -152,6 +152,10 @@ int anon_vma_prepare(struct vm_area_stru +diff --git a/mm/rmap.c b/mm/rmap.c +index 8005080..198c2cd 100644 +--- a/mm/rmap.c ++++ b/mm/rmap.c +@@ -152,6 +152,10 @@ int anon_vma_prepare(struct vm_area_struct *vma) struct anon_vma *anon_vma =3D vma->anon_vma; struct anon_vma_chain *avc; =20 @@ -71096,7 +72652,7 @@ diff -urNp linux-3.1.4/mm/rmap.c linux-3.1.4/mm/r= map.c might_sleep(); if (unlikely(!anon_vma)) { struct mm_struct *mm =3D vma->vm_mm; -@@ -161,6 +165,12 @@ int anon_vma_prepare(struct vm_area_stru +@@ -161,6 +165,12 @@ int anon_vma_prepare(struct vm_area_struct *vma) if (!avc) goto out_enomem; =20 @@ -71109,7 +72665,7 @@ diff -urNp linux-3.1.4/mm/rmap.c linux-3.1.4/mm/r= map.c anon_vma =3D find_mergeable_anon_vma(vma); allocated =3D NULL; if (!anon_vma) { -@@ -174,6 +184,21 @@ int anon_vma_prepare(struct vm_area_stru +@@ -174,6 +184,21 @@ int anon_vma_prepare(struct vm_area_struct *vma) /* page_table_lock to protect against threads */ spin_lock(&mm->page_table_lock); if (likely(!vma->anon_vma)) { @@ -71131,7 +72687,7 @@ diff -urNp linux-3.1.4/mm/rmap.c linux-3.1.4/mm/r= map.c vma->anon_vma =3D anon_vma; avc->anon_vma =3D anon_vma; avc->vma =3D vma; -@@ -187,12 +212,24 @@ int anon_vma_prepare(struct vm_area_stru +@@ -187,12 +212,24 @@ int anon_vma_prepare(struct vm_area_struct *vma) =20 if (unlikely(allocated)) put_anon_vma(allocated); @@ -71156,7 +72712,7 @@ diff -urNp linux-3.1.4/mm/rmap.c linux-3.1.4/mm/r= map.c anon_vma_chain_free(avc); out_enomem: return -ENOMEM; -@@ -243,7 +280,7 @@ static void anon_vma_chain_link(struct v +@@ -243,7 +280,7 @@ static void anon_vma_chain_link(struct vm_area_struc= t *vma, * Attach the anon_vmas from src to dst. * Returns 0 on success, -ENOMEM on failure. */ @@ -71165,7 +72721,7 @@ diff -urNp linux-3.1.4/mm/rmap.c linux-3.1.4/mm/r= map.c { struct anon_vma_chain *avc, *pavc; struct anon_vma *root =3D NULL; -@@ -276,7 +313,7 @@ int anon_vma_clone(struct vm_area_struct +@@ -276,7 +313,7 @@ int anon_vma_clone(struct vm_area_struct *dst, struc= t vm_area_struct *src) * the corresponding VMA in the parent process is attached to. * Returns 0 on success, non-zero on failure. */ @@ -71174,9 +72730,10 @@ diff -urNp linux-3.1.4/mm/rmap.c linux-3.1.4/mm/= rmap.c { struct anon_vma_chain *avc; struct anon_vma *anon_vma; -diff -urNp linux-3.1.4/mm/shmem.c linux-3.1.4/mm/shmem.c ---- linux-3.1.4/mm/shmem.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/shmem.c 2011-11-16 19:28:28.000000000 -0500 +diff --git a/mm/shmem.c b/mm/shmem.c +index 32f6763..431c405 100644 +--- a/mm/shmem.c ++++ b/mm/shmem.c @@ -31,7 +31,7 @@ #include #include @@ -71195,7 +72752,7 @@ diff -urNp linux-3.1.4/mm/shmem.c linux-3.1.4/mm/= shmem.c =20 struct shmem_xattr { struct list_head list; /* anchored by shmem_inode_info->xattr_list */ -@@ -769,6 +769,8 @@ static struct page *shmem_swapin(swp_ent +@@ -769,6 +769,8 @@ static struct page *shmem_swapin(swp_entry_t swap, g= fp_t gfp, struct mempolicy mpol, *spol; struct vm_area_struct pvma; =20 @@ -71204,7 +72761,7 @@ diff -urNp linux-3.1.4/mm/shmem.c linux-3.1.4/mm/= shmem.c spol =3D mpol_cond_copy(&mpol, mpol_shared_policy_lookup(&info->policy, index)); =20 -@@ -2149,8 +2151,7 @@ int shmem_fill_super(struct super_block=20 +@@ -2149,8 +2151,7 @@ int shmem_fill_super(struct super_block *sb, void = *data, int silent) int err =3D -ENOMEM; =20 /* Round up to L1_CACHE_BYTES to resist false sharing */ @@ -71214,9 +72771,10 @@ diff -urNp linux-3.1.4/mm/shmem.c linux-3.1.4/mm= /shmem.c if (!sbinfo) return -ENOMEM; =20 -diff -urNp linux-3.1.4/mm/slab.c linux-3.1.4/mm/slab.c ---- linux-3.1.4/mm/slab.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/slab.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/mm/slab.c b/mm/slab.c +index 6d90a09..3cab423 100644 +--- a/mm/slab.c ++++ b/mm/slab.c @@ -151,7 +151,7 @@ =20 /* Legal flag mask for kmem_cache_create(). */ @@ -71244,7 +72802,7 @@ diff -urNp linux-3.1.4/mm/slab.c linux-3.1.4/mm/s= lab.c #define CACHE_CACHE 0 #define SIZE_AC MAX_NUMNODES #define SIZE_L3 (2 * MAX_NUMNODES) -@@ -389,10 +389,10 @@ static void kmem_list3_init(struct kmem_ +@@ -389,10 +389,10 @@ static void kmem_list3_init(struct kmem_list3 *par= ent) if ((x)->max_freeable < i) \ (x)->max_freeable =3D i; \ } while (0) @@ -71259,7 +72817,7 @@ diff -urNp linux-3.1.4/mm/slab.c linux-3.1.4/mm/s= lab.c #else #define STATS_INC_ACTIVE(x) do { } while (0) #define STATS_DEC_ACTIVE(x) do { } while (0) -@@ -538,7 +538,7 @@ static inline void *index_to_obj(struct=20 +@@ -538,7 +538,7 @@ static inline void *index_to_obj(struct kmem_cache *= cache, struct slab *slab, * reciprocal_divide(offset, cache->reciprocal_buffer_size) */ static inline unsigned int obj_to_index(const struct kmem_cache *cache, @@ -71304,7 +72862,7 @@ diff -urNp linux-3.1.4/mm/slab.c linux-3.1.4/mm/s= lab.c NULL); } #ifdef CONFIG_ZONE_DMA -@@ -4324,10 +4324,10 @@ static int s_show(struct seq_file *m, vo +@@ -4324,10 +4324,10 @@ static int s_show(struct seq_file *m, void *p) } /* cpu stats */ { @@ -71319,7 +72877,7 @@ diff -urNp linux-3.1.4/mm/slab.c linux-3.1.4/mm/s= lab.c =20 seq_printf(m, " : cpustat %6lu %6lu %6lu %6lu", allochit, allocmiss, freehit, freemiss); -@@ -4584,15 +4584,70 @@ static const struct file_operations proc +@@ -4584,15 +4584,70 @@ static const struct file_operations proc_slabsta= ts_operations =3D { =20 static int __init slab_proc_init(void) { @@ -71392,9 +72950,10 @@ diff -urNp linux-3.1.4/mm/slab.c linux-3.1.4/mm/= slab.c /** * ksize - get the actual amount of memory allocated for a given object * @objp: Pointer to the object -diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/slob.c ---- linux-3.1.4/mm/slob.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/slob.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/mm/slob.c b/mm/slob.c +index bf39181..727f7a3 100644 +--- a/mm/slob.c ++++ b/mm/slob.c @@ -29,7 +29,7 @@ * If kmalloc is asked for objects of PAGE_SIZE or larger, it calls * alloc_pages() directly, allocating compound pages so the page order @@ -71431,7 +72990,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c } =20 static inline void set_slob_page(struct slob_page *sp) -@@ -150,7 +152,7 @@ static inline void clear_slob_page(struc +@@ -150,7 +152,7 @@ static inline void clear_slob_page(struct slob_page = *sp) =20 static inline struct slob_page *slob_page(const void *addr) { @@ -71440,7 +72999,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c } =20 /* -@@ -210,7 +212,7 @@ static void set_slob(slob_t *s, slobidx_ +@@ -210,7 +212,7 @@ static void set_slob(slob_t *s, slobidx_t size, slob= _t *next) /* * Return the size of a slob block. */ @@ -71467,7 +73026,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c { return !((unsigned long)slob_next(s) & ~PAGE_MASK); } -@@ -254,6 +256,7 @@ static void *slob_new_pages(gfp_t gfp, i +@@ -254,6 +256,7 @@ static void *slob_new_pages(gfp_t gfp, int order, in= t node) if (!page) return NULL; =20 @@ -71475,7 +73034,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c return page_address(page); } =20 -@@ -370,11 +373,11 @@ static void *slob_alloc(size_t size, gfp +@@ -370,11 +373,11 @@ static void *slob_alloc(size_t size, gfp_t gfp, in= t align, int node) if (!b) return NULL; sp =3D slob_page(b); @@ -71501,7 +73060,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c void *ret; =20 gfp &=3D gfp_allowed_mask; -@@ -494,7 +496,10 @@ void *__kmalloc_node(size_t size, gfp_t=20 +@@ -494,7 +496,10 @@ void *__kmalloc_node(size_t size, gfp_t gfp, int no= de) =20 if (!m) return NULL; @@ -71513,7 +73072,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c ret =3D (void *)m + align; =20 trace_kmalloc_node(_RET_IP_, ret, -@@ -506,16 +511,25 @@ void *__kmalloc_node(size_t size, gfp_t=20 +@@ -506,16 +511,25 @@ void *__kmalloc_node(size_t size, gfp_t gfp, int n= ode) gfp |=3D __GFP_COMP; ret =3D slob_new_pages(gfp, order, node); if (ret) { @@ -71653,7 +73212,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c } EXPORT_SYMBOL(ksize); =20 -@@ -571,8 +664,13 @@ struct kmem_cache *kmem_cache_create(con +@@ -571,8 +664,13 @@ struct kmem_cache *kmem_cache_create(const char *na= me, size_t size, { struct kmem_cache *c; =20 @@ -71667,7 +73226,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c =20 if (c) { c->name =3D name; -@@ -614,17 +712,25 @@ void *kmem_cache_alloc_node(struct kmem_ +@@ -614,17 +712,25 @@ void *kmem_cache_alloc_node(struct kmem_cache *c, = gfp_t flags, int node) =20 lockdep_trace_alloc(flags); =20 @@ -71712,7 +73271,7 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/s= lob.c } =20 static void kmem_rcu_free(struct rcu_head *head) -@@ -652,17 +764,31 @@ static void kmem_rcu_free(struct rcu_hea +@@ -652,17 +764,31 @@ static void kmem_rcu_free(struct rcu_head *head) =20 void kmem_cache_free(struct kmem_cache *c, void *b) { @@ -71747,9 +73306,10 @@ diff -urNp linux-3.1.4/mm/slob.c linux-3.1.4/mm/= slob.c } EXPORT_SYMBOL(kmem_cache_free); =20 -diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/slub.c ---- linux-3.1.4/mm/slub.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/slub.c 2011-11-16 19:27:25.000000000 -0500 +diff --git a/mm/slub.c b/mm/slub.c +index 7c54fe8..0bb4ac5 100644 +--- a/mm/slub.c ++++ b/mm/slub.c @@ -208,7 +208,7 @@ struct track { =20 enum track_item { TRACK_ALLOC, TRACK_FREE }; @@ -71759,7 +73319,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c static int sysfs_slab_add(struct kmem_cache *); static int sysfs_slab_alias(struct kmem_cache *, const char *); static void sysfs_slab_remove(struct kmem_cache *); -@@ -556,7 +556,7 @@ static void print_track(const char *s, s +@@ -556,7 +556,7 @@ static void print_track(const char *s, struct track = *t) if (!t->addr) return; =20 @@ -71768,7 +73328,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c s, (void *)t->addr, jiffies - t->when, t->cpu, t->pid); #ifdef CONFIG_STACKTRACE { -@@ -2456,6 +2456,8 @@ void kmem_cache_free(struct kmem_cache * +@@ -2456,6 +2456,8 @@ void kmem_cache_free(struct kmem_cache *s, void *x= ) =20 page =3D virt_to_head_page(x); =20 @@ -71786,7 +73346,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c =20 /* * Calculate the order of allocation given an slab object size. -@@ -2912,7 +2914,7 @@ static int kmem_cache_open(struct kmem_c +@@ -2912,7 +2914,7 @@ static int kmem_cache_open(struct kmem_cache *s, * list to avoid pounding the page allocator excessively. */ set_min_partial(s, ilog2(s->size)); @@ -71795,7 +73355,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c #ifdef CONFIG_NUMA s->remote_node_defrag_ratio =3D 1000; #endif -@@ -3017,8 +3019,7 @@ static inline int kmem_cache_close(struc +@@ -3017,8 +3019,7 @@ static inline int kmem_cache_close(struct kmem_cac= he *s) void kmem_cache_destroy(struct kmem_cache *s) { down_write(&slub_lock); @@ -71805,7 +73365,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c list_del(&s->list); if (kmem_cache_close(s)) { printk(KERN_ERR "SLUB %s: %s called for cache that " -@@ -3228,6 +3229,50 @@ void *__kmalloc_node(size_t size, gfp_t=20 +@@ -3228,6 +3229,50 @@ void *__kmalloc_node(size_t size, gfp_t flags, in= t node) EXPORT_SYMBOL(__kmalloc_node); #endif =20 @@ -71856,7 +73416,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c size_t ksize(const void *object) { struct page *page; -@@ -3502,7 +3547,7 @@ static void __init kmem_cache_bootstrap_ +@@ -3502,7 +3547,7 @@ static void __init kmem_cache_bootstrap_fixup(stru= ct kmem_cache *s) int node; =20 list_add(&s->list, &slab_caches); @@ -71886,7 +73446,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c caches++; } =20 -@@ -3697,7 +3742,7 @@ static int slab_unmergeable(struct kmem_ +@@ -3697,7 +3742,7 @@ static int slab_unmergeable(struct kmem_cache *s) /* * We may have set a slab to be unmergeable during bootstrap. */ @@ -71895,7 +73455,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c return 1; =20 return 0; -@@ -3756,7 +3801,7 @@ struct kmem_cache *kmem_cache_create(con +@@ -3756,7 +3801,7 @@ struct kmem_cache *kmem_cache_create(const char *n= ame, size_t size, down_write(&slub_lock); s =3D find_mergeable(size, align, flags, name, ctor); if (s) { @@ -71904,7 +73464,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c /* * Adjust the object sizes so that we clear * the complete object on kzalloc. -@@ -3765,7 +3810,7 @@ struct kmem_cache *kmem_cache_create(con +@@ -3765,7 +3810,7 @@ struct kmem_cache *kmem_cache_create(const char *n= ame, size_t size, s->inuse =3D max_t(int, s->inuse, ALIGN(size, sizeof(void *))); =20 if (sysfs_slab_alias(s, name)) { @@ -71913,7 +73473,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c goto err; } up_write(&slub_lock); -@@ -3893,7 +3938,7 @@ void *__kmalloc_node_track_caller(size_t +@@ -3893,7 +3938,7 @@ void *__kmalloc_node_track_caller(size_t size, gfp= _t gfpflags, } #endif =20 @@ -71946,7 +73506,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c } SLAB_ATTR_RO(aliases); =20 -@@ -5025,6 +5070,7 @@ static char *create_unique_id(struct kme +@@ -5025,6 +5070,7 @@ static char *create_unique_id(struct kmem_cache *s= ) return name; } =20 @@ -71954,7 +73514,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c static int sysfs_slab_add(struct kmem_cache *s) { int err; -@@ -5087,6 +5133,7 @@ static void sysfs_slab_remove(struct kme +@@ -5087,6 +5133,7 @@ static void sysfs_slab_remove(struct kmem_cache *s= ) kobject_del(&s->kobj); kobject_put(&s->kobj); } @@ -71970,7 +73530,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c static int sysfs_slab_alias(struct kmem_cache *s, const char *name) { struct saved_alias *al; -@@ -5122,6 +5170,7 @@ static int sysfs_slab_alias(struct kmem_ +@@ -5122,6 +5170,7 @@ static int sysfs_slab_alias(struct kmem_cache *s, = const char *name) alias_list =3D al; return 0; } @@ -71978,7 +73538,7 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/s= lub.c =20 static int __init slab_sysfs_init(void) { -@@ -5257,7 +5306,13 @@ static const struct file_operations proc +@@ -5257,7 +5306,13 @@ static const struct file_operations proc_slabinfo= _operations =3D { =20 static int __init slab_proc_init(void) { @@ -71993,9 +73553,10 @@ diff -urNp linux-3.1.4/mm/slub.c linux-3.1.4/mm/= slub.c return 0; } module_init(slab_proc_init); -diff -urNp linux-3.1.4/mm/swap.c linux-3.1.4/mm/swap.c ---- linux-3.1.4/mm/swap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/swap.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/mm/swap.c b/mm/swap.c +index 87627f1..8a9eb34 100644 +--- a/mm/swap.c ++++ b/mm/swap.c @@ -31,6 +31,7 @@ #include #include @@ -72004,7 +73565,7 @@ diff -urNp linux-3.1.4/mm/swap.c linux-3.1.4/mm/s= wap.c =20 #include "internal.h" =20 -@@ -71,6 +72,8 @@ static void __put_compound_page(struct p +@@ -71,6 +72,8 @@ static void __put_compound_page(struct page *page) =20 __page_cache_release(page); dtor =3D get_compound_page_dtor(page); @@ -72013,9 +73574,10 @@ diff -urNp linux-3.1.4/mm/swap.c linux-3.1.4/mm/= swap.c (*dtor)(page); } =20 -diff -urNp linux-3.1.4/mm/swapfile.c linux-3.1.4/mm/swapfile.c ---- linux-3.1.4/mm/swapfile.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/swapfile.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/mm/swapfile.c b/mm/swapfile.c +index 17bc224..1677059 100644 +--- a/mm/swapfile.c ++++ b/mm/swapfile.c @@ -62,7 +62,7 @@ static DEFINE_MUTEX(swapon_mutex); =20 static DECLARE_WAIT_QUEUE_HEAD(proc_poll_wait); @@ -72025,7 +73587,7 @@ diff -urNp linux-3.1.4/mm/swapfile.c linux-3.1.4/= mm/swapfile.c =20 static inline unsigned char swap_count(unsigned char ent) { -@@ -1671,7 +1671,7 @@ SYSCALL_DEFINE1(swapoff, const char __us +@@ -1671,7 +1671,7 @@ SYSCALL_DEFINE1(swapoff, const char __user *, spec= ialfile) } filp_close(swap_file, NULL); err =3D 0; @@ -72034,7 +73596,7 @@ diff -urNp linux-3.1.4/mm/swapfile.c linux-3.1.4/= mm/swapfile.c wake_up_interruptible(&proc_poll_wait); =20 out_dput: -@@ -1687,8 +1687,8 @@ static unsigned swaps_poll(struct file * +@@ -1687,8 +1687,8 @@ static unsigned swaps_poll(struct file *file, poll= _table *wait) =20 poll_wait(file, &proc_poll_wait, wait); =20 @@ -72045,7 +73607,7 @@ diff -urNp linux-3.1.4/mm/swapfile.c linux-3.1.4/= mm/swapfile.c return POLLIN | POLLRDNORM | POLLERR | POLLPRI; } =20 -@@ -1786,7 +1786,7 @@ static int swaps_open(struct inode *inod +@@ -1786,7 +1786,7 @@ static int swaps_open(struct inode *inode, struct = file *file) return ret; =20 seq =3D file->private_data; @@ -72054,7 +73616,7 @@ diff -urNp linux-3.1.4/mm/swapfile.c linux-3.1.4/= mm/swapfile.c return 0; } =20 -@@ -2124,7 +2124,7 @@ SYSCALL_DEFINE2(swapon, const char __use +@@ -2124,7 +2124,7 @@ SYSCALL_DEFINE2(swapon, const char __user *, speci= alfile, int, swap_flags) (p->flags & SWP_DISCARDABLE) ? "D" : ""); =20 mutex_unlock(&swapon_mutex); @@ -72063,9 +73625,10 @@ diff -urNp linux-3.1.4/mm/swapfile.c linux-3.1.4= /mm/swapfile.c wake_up_interruptible(&proc_poll_wait); =20 if (S_ISREG(inode->i_mode)) -diff -urNp linux-3.1.4/mm/util.c linux-3.1.4/mm/util.c ---- linux-3.1.4/mm/util.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/util.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/mm/util.c b/mm/util.c +index 88ea1bd..0f1dfdb 100644 +--- a/mm/util.c ++++ b/mm/util.c @@ -114,6 +114,7 @@ EXPORT_SYMBOL(memdup_user); * allocated buffer. Use this if you don't want to free the buffer imme= diately * like, for example, with RCU. @@ -72082,7 +73645,7 @@ diff -urNp linux-3.1.4/mm/util.c linux-3.1.4/mm/u= til.c void *krealloc(const void *p, size_t new_size, gfp_t flags) { void *ret; -@@ -243,6 +245,12 @@ void __vma_link_list(struct mm_struct *m +@@ -243,6 +245,12 @@ void __vma_link_list(struct mm_struct *mm, struct v= m_area_struct *vma, void arch_pick_mmap_layout(struct mm_struct *mm) { mm->mmap_base =3D TASK_UNMAPPED_BASE; @@ -72095,10 +73658,11 @@ diff -urNp linux-3.1.4/mm/util.c linux-3.1.4/mm= /util.c mm->get_unmapped_area =3D arch_get_unmapped_area; mm->unmap_area =3D arch_unmap_area; } -diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/mm/vmalloc.c ---- linux-3.1.4/mm/vmalloc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/vmalloc.c 2011-11-16 18:40:44.000000000 -0500 -@@ -39,8 +39,19 @@ static void vunmap_pte_range(pmd_t *pmd, +diff --git a/mm/vmalloc.c b/mm/vmalloc.c +index 56faf31..75c1a4c 100644 +--- a/mm/vmalloc.c ++++ b/mm/vmalloc.c +@@ -39,8 +39,19 @@ static void vunmap_pte_range(pmd_t *pmd, unsigned lon= g addr, unsigned long end) =20 pte =3D pte_offset_kernel(pmd, addr); do { @@ -72120,7 +73684,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c } while (pte++, addr +=3D PAGE_SIZE, addr !=3D end); } =20 -@@ -91,6 +102,7 @@ static int vmap_pte_range(pmd_t *pmd, un +@@ -91,6 +102,7 @@ static int vmap_pte_range(pmd_t *pmd, unsigned long a= ddr, unsigned long end, pgprot_t prot, struct page **pages, int *nr) { pte_t *pte; @@ -72128,7 +73692,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c =20 /* * nr is a running index into the array which helps higher level -@@ -100,17 +112,30 @@ static int vmap_pte_range(pmd_t *pmd, un +@@ -100,17 +112,30 @@ static int vmap_pte_range(pmd_t *pmd, unsigned lon= g addr, pte =3D pte_alloc_kernel(pmd, addr); if (!pte) return -ENOMEM; @@ -72164,7 +73728,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c } =20 static int vmap_pmd_range(pud_t *pud, unsigned long addr, -@@ -191,11 +216,20 @@ int is_vmalloc_or_module_addr(const void +@@ -191,11 +216,20 @@ int is_vmalloc_or_module_addr(const void *x) * and fall back on vmalloc() if that fails. Others * just put it in the vmalloc space. */ @@ -72186,7 +73750,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c return is_vmalloc_addr(x); } =20 -@@ -216,8 +250,14 @@ struct page *vmalloc_to_page(const void=20 +@@ -216,8 +250,14 @@ struct page *vmalloc_to_page(const void *vmalloc_ad= dr) =20 if (!pgd_none(*pgd)) { pud_t *pud =3D pud_offset(pgd, addr); @@ -72201,7 +73765,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c if (!pmd_none(*pmd)) { pte_t *ptep, pte; =20 -@@ -1294,6 +1334,16 @@ static struct vm_struct *__get_vm_area_n +@@ -1294,6 +1334,16 @@ static struct vm_struct *__get_vm_area_node(unsig= ned long size, struct vm_struct *area; =20 BUG_ON(in_interrupt()); @@ -72218,7 +73782,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c if (flags & VM_IOREMAP) { int bit =3D fls(size); =20 -@@ -1526,6 +1576,11 @@ void *vmap(struct page **pages, unsigned +@@ -1526,6 +1576,11 @@ void *vmap(struct page **pages, unsigned int coun= t, if (count > totalram_pages) return NULL; =20 @@ -72230,7 +73794,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c area =3D get_vm_area_caller((count << PAGE_SHIFT), flags, __builtin_return_address(0)); if (!area) -@@ -1627,6 +1682,13 @@ void *__vmalloc_node_range(unsigned long +@@ -1627,6 +1682,13 @@ void *__vmalloc_node_range(unsigned long size, un= signed long align, if (!size || (size >> PAGE_SHIFT) > totalram_pages) return NULL; =20 @@ -72244,7 +73808,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c area =3D __get_vm_area_node(size, align, VM_ALLOC | VM_UNLIST, start, end, node, gfp_mask, caller); =20 -@@ -1672,6 +1734,7 @@ static void *__vmalloc_node(unsigned lon +@@ -1672,6 +1734,7 @@ static void *__vmalloc_node(unsigned long size, un= signed long align, gfp_mask, prot, node, caller); } =20 @@ -72252,7 +73816,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c void *__vmalloc(unsigned long size, gfp_t gfp_mask, pgprot_t prot) { return __vmalloc_node(size, 1, gfp_mask, prot, -1, -@@ -1695,6 +1758,7 @@ static inline void *__vmalloc_node_flags +@@ -1695,6 +1758,7 @@ static inline void *__vmalloc_node_flags(unsigned = long size, * For tight control over page level allocator and protection flags * use __vmalloc() instead. */ @@ -72321,7 +73885,7 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/m= m/vmalloc.c void *vmalloc_32_user(unsigned long size) { struct vm_struct *area; -@@ -2091,6 +2161,8 @@ int remap_vmalloc_range(struct vm_area_s +@@ -2091,6 +2161,8 @@ int remap_vmalloc_range(struct vm_area_struct *vma= , void *addr, unsigned long uaddr =3D vma->vm_start; unsigned long usize =3D vma->vm_end - vma->vm_start; =20 @@ -72330,9 +73894,10 @@ diff -urNp linux-3.1.4/mm/vmalloc.c linux-3.1.4/= mm/vmalloc.c if ((PAGE_SIZE-1) & (unsigned long)addr) return -EINVAL; =20 -diff -urNp linux-3.1.4/mm/vmstat.c linux-3.1.4/mm/vmstat.c ---- linux-3.1.4/mm/vmstat.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/mm/vmstat.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/mm/vmstat.c b/mm/vmstat.c +index d52b13d..381d1ac 100644 +--- a/mm/vmstat.c ++++ b/mm/vmstat.c @@ -78,7 +78,7 @@ void vm_events_fold_cpu(int cpu) * * vm_stat contains the global counters @@ -72385,10 +73950,11 @@ diff -urNp linux-3.1.4/mm/vmstat.c linux-3.1.4/= mm/vmstat.c #endif return 0; } -diff -urNp linux-3.1.4/net/8021q/vlan.c linux-3.1.4/net/8021q/vlan.c ---- linux-3.1.4/net/8021q/vlan.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/8021q/vlan.c 2011-11-16 18:39:08.000000000 -0500 -@@ -588,8 +588,7 @@ static int vlan_ioctl_handler(struct net +diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c +index 8970ba1..e3361fe 100644 +--- a/net/8021q/vlan.c ++++ b/net/8021q/vlan.c +@@ -588,8 +588,7 @@ static int vlan_ioctl_handler(struct net *net, void = __user *arg) err =3D -EPERM; if (!capable(CAP_NET_ADMIN)) break; @@ -72398,10 +73964,11 @@ diff -urNp linux-3.1.4/net/8021q/vlan.c linux-3= .1.4/net/8021q/vlan.c struct vlan_net *vn; =20 vn =3D net_generic(net, vlan_net_id); -diff -urNp linux-3.1.4/net/9p/trans_fd.c linux-3.1.4/net/9p/trans_fd.c ---- linux-3.1.4/net/9p/trans_fd.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/9p/trans_fd.c 2011-11-16 18:39:08.000000000 -0500 -@@ -423,7 +423,7 @@ static int p9_fd_write(struct p9_client=20 +diff --git a/net/9p/trans_fd.c b/net/9p/trans_fd.c +index fdfdb57..38d368c 100644 +--- a/net/9p/trans_fd.c ++++ b/net/9p/trans_fd.c +@@ -423,7 +423,7 @@ static int p9_fd_write(struct p9_client *client, voi= d *v, int len) oldfs =3D get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -72410,9 +73977,10 @@ diff -urNp linux-3.1.4/net/9p/trans_fd.c linux-3= .1.4/net/9p/trans_fd.c set_fs(oldfs); =20 if (ret <=3D 0 && ret !=3D -ERESTARTSYS && ret !=3D -EAGAIN) -diff -urNp linux-3.1.4/net/9p/trans_virtio.c linux-3.1.4/net/9p/trans_vi= rtio.c ---- linux-3.1.4/net/9p/trans_virtio.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/net/9p/trans_virtio.c 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/net/9p/trans_virtio.c b/net/9p/trans_virtio.c +index e317583..3c8aeaf 100644 +--- a/net/9p/trans_virtio.c ++++ b/net/9p/trans_virtio.c @@ -327,7 +327,7 @@ req_retry_pinned: } else { char *pbuf; @@ -72431,10 +73999,11 @@ diff -urNp linux-3.1.4/net/9p/trans_virtio.c li= nux-3.1.4/net/9p/trans_virtio.c else pbuf =3D req->tc->pkbuf; =20 -diff -urNp linux-3.1.4/net/atm/atm_misc.c linux-3.1.4/net/atm/atm_misc.c ---- linux-3.1.4/net/atm/atm_misc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/atm/atm_misc.c 2011-11-16 18:39:08.000000000 -0500 -@@ -17,7 +17,7 @@ int atm_charge(struct atm_vcc *vcc, int=20 +diff --git a/net/atm/atm_misc.c b/net/atm/atm_misc.c +index f41f026..fe76ea8 100644 +--- a/net/atm/atm_misc.c ++++ b/net/atm/atm_misc.c +@@ -17,7 +17,7 @@ int atm_charge(struct atm_vcc *vcc, int truesize) if (atomic_read(&sk_atm(vcc)->sk_rmem_alloc) <=3D sk_atm(vcc)->sk_rcvb= uf) return 1; atm_return(vcc, truesize); @@ -72443,7 +74012,7 @@ diff -urNp linux-3.1.4/net/atm/atm_misc.c linux-3= .1.4/net/atm/atm_misc.c return 0; } EXPORT_SYMBOL(atm_charge); -@@ -39,7 +39,7 @@ struct sk_buff *atm_alloc_charge(struct=20 +@@ -39,7 +39,7 @@ struct sk_buff *atm_alloc_charge(struct atm_vcc *vcc, = int pdu_size, } } atm_return(vcc, guess); @@ -72470,9 +74039,10 @@ diff -urNp linux-3.1.4/net/atm/atm_misc.c linux-= 3.1.4/net/atm/atm_misc.c __SONET_ITEMS #undef __HANDLE_ITEM } -diff -urNp linux-3.1.4/net/atm/lec.h linux-3.1.4/net/atm/lec.h ---- linux-3.1.4/net/atm/lec.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/atm/lec.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/atm/lec.h b/net/atm/lec.h +index dfc0719..47c5322 100644 +--- a/net/atm/lec.h ++++ b/net/atm/lec.h @@ -48,7 +48,7 @@ struct lane2_ops { const u8 *tlvs, u32 sizeoftlvs); void (*associate_indicator) (struct net_device *dev, const u8 *mac_add= r, @@ -72482,9 +74052,10 @@ diff -urNp linux-3.1.4/net/atm/lec.h linux-3.1.4= /net/atm/lec.h =20 /* * ATM LAN Emulation supports both LLC & Dix Ethernet EtherType -diff -urNp linux-3.1.4/net/atm/mpc.h linux-3.1.4/net/atm/mpc.h ---- linux-3.1.4/net/atm/mpc.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/atm/mpc.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/atm/mpc.h b/net/atm/mpc.h +index 0919a88..a23d54e 100644 +--- a/net/atm/mpc.h ++++ b/net/atm/mpc.h @@ -33,7 +33,7 @@ struct mpoa_client { struct mpc_parameters parameters; /* parameters for this client */ =20 @@ -72494,10 +74065,11 @@ diff -urNp linux-3.1.4/net/atm/mpc.h linux-3.1.= 4/net/atm/mpc.h }; =20 =20 -diff -urNp linux-3.1.4/net/atm/mpoa_caches.c linux-3.1.4/net/atm/mpoa_ca= ches.c ---- linux-3.1.4/net/atm/mpoa_caches.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/net/atm/mpoa_caches.c 2011-11-16 18:40:44.000000000 -050= 0 -@@ -255,6 +255,8 @@ static void check_resolving_entries(stru +diff --git a/net/atm/mpoa_caches.c b/net/atm/mpoa_caches.c +index d1b2d9a..7cc2219 100644 +--- a/net/atm/mpoa_caches.c ++++ b/net/atm/mpoa_caches.c +@@ -255,6 +255,8 @@ static void check_resolving_entries(struct mpoa_clie= nt *client) struct timeval now; struct k_message msg; =20 @@ -72506,10 +74078,11 @@ diff -urNp linux-3.1.4/net/atm/mpoa_caches.c li= nux-3.1.4/net/atm/mpoa_caches.c do_gettimeofday(&now); =20 read_lock_bh(&client->ingress_lock); -diff -urNp linux-3.1.4/net/atm/proc.c linux-3.1.4/net/atm/proc.c ---- linux-3.1.4/net/atm/proc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/atm/proc.c 2011-11-16 18:39:08.000000000 -0500 -@@ -45,9 +45,9 @@ static void add_stats(struct seq_file *s +diff --git a/net/atm/proc.c b/net/atm/proc.c +index 0d020de..011c7bb 100644 +--- a/net/atm/proc.c ++++ b/net/atm/proc.c +@@ -45,9 +45,9 @@ static void add_stats(struct seq_file *seq, const char= *aal, const struct k_atm_aal_stats *stats) { seq_printf(seq, "%s ( %d %d %d %d %d )", aal, @@ -72522,9 +74095,10 @@ diff -urNp linux-3.1.4/net/atm/proc.c linux-3.1.= 4/net/atm/proc.c } =20 static void atm_dev_info(struct seq_file *seq, const struct atm_dev *de= v) -diff -urNp linux-3.1.4/net/atm/resources.c linux-3.1.4/net/atm/resources= .c ---- linux-3.1.4/net/atm/resources.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/atm/resources.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/atm/resources.c b/net/atm/resources.c +index 23f45ce..c748f1a 100644 +--- a/net/atm/resources.c ++++ b/net/atm/resources.c @@ -160,7 +160,7 @@ EXPORT_SYMBOL(atm_dev_deregister); static void copy_aal_stats(struct k_atm_aal_stats *from, struct atm_aal_stats *to) @@ -72534,7 +74108,7 @@ diff -urNp linux-3.1.4/net/atm/resources.c linux-= 3.1.4/net/atm/resources.c __AAL_STAT_ITEMS #undef __HANDLE_ITEM } -@@ -168,7 +168,7 @@ static void copy_aal_stats(struct k_atm_ +@@ -168,7 +168,7 @@ static void copy_aal_stats(struct k_atm_aal_stats *f= rom, static void subtract_aal_stats(struct k_atm_aal_stats *from, struct atm_aal_stats *to) { @@ -72543,10 +74117,11 @@ diff -urNp linux-3.1.4/net/atm/resources.c linu= x-3.1.4/net/atm/resources.c __AAL_STAT_ITEMS #undef __HANDLE_ITEM } -diff -urNp linux-3.1.4/net/batman-adv/hard-interface.c linux-3.1.4/net/b= atman-adv/hard-interface.c ---- linux-3.1.4/net/batman-adv/hard-interface.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/net/batman-adv/hard-interface.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -347,8 +347,8 @@ int hardif_enable_interface(struct hard_ +diff --git a/net/batman-adv/hard-interface.c b/net/batman-adv/hard-inter= face.c +index db7aacf..991e539 100644 +--- a/net/batman-adv/hard-interface.c ++++ b/net/batman-adv/hard-interface.c +@@ -347,8 +347,8 @@ int hardif_enable_interface(struct hard_iface *hard_= iface, hard_iface->batman_adv_ptype.dev =3D hard_iface->net_dev; dev_add_pack(&hard_iface->batman_adv_ptype); =20 @@ -72557,10 +74132,11 @@ diff -urNp linux-3.1.4/net/batman-adv/hard-inte= rface.c linux-3.1.4/net/batman-ad bat_info(hard_iface->soft_iface, "Adding interface: %s\n", hard_iface->net_dev->name); =20 -diff -urNp linux-3.1.4/net/batman-adv/routing.c linux-3.1.4/net/batman-a= dv/routing.c ---- linux-3.1.4/net/batman-adv/routing.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/batman-adv/routing.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -656,7 +656,7 @@ void receive_bat_packet(const struct eth +diff --git a/net/batman-adv/routing.c b/net/batman-adv/routing.c +index 0f32c81..82d1895 100644 +--- a/net/batman-adv/routing.c ++++ b/net/batman-adv/routing.c +@@ -656,7 +656,7 @@ void receive_bat_packet(const struct ethhdr *ethhdr, return; =20 /* could be changed by schedule_own_packet() */ @@ -72569,10 +74145,11 @@ diff -urNp linux-3.1.4/net/batman-adv/routing.c= linux-3.1.4/net/batman-adv/routi =20 has_directlink_flag =3D (batman_packet->flags & DIRECTLINK ? 1 : 0); =20 -diff -urNp linux-3.1.4/net/batman-adv/send.c linux-3.1.4/net/batman-adv/= send.c ---- linux-3.1.4/net/batman-adv/send.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/net/batman-adv/send.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -326,7 +326,7 @@ void schedule_own_packet(struct hard_ifa +diff --git a/net/batman-adv/send.c b/net/batman-adv/send.c +index 58d1447..2a66c8c 100644 +--- a/net/batman-adv/send.c ++++ b/net/batman-adv/send.c +@@ -326,7 +326,7 @@ void schedule_own_packet(struct hard_iface *hard_ifa= ce) =20 /* change sequence number to network order */ batman_packet->seqno =3D @@ -72581,7 +74158,7 @@ diff -urNp linux-3.1.4/net/batman-adv/send.c linu= x-3.1.4/net/batman-adv/send.c =20 batman_packet->ttvn =3D atomic_read(&bat_priv->ttvn); batman_packet->tt_crc =3D htons((uint16_t)atomic_read(&bat_priv->tt_cr= c)); -@@ -343,7 +343,7 @@ void schedule_own_packet(struct hard_ifa +@@ -343,7 +343,7 @@ void schedule_own_packet(struct hard_iface *hard_ifa= ce) else batman_packet->gw_flags =3D NO_FLAGS; =20 @@ -72590,10 +74167,11 @@ diff -urNp linux-3.1.4/net/batman-adv/send.c li= nux-3.1.4/net/batman-adv/send.c =20 slide_own_bcast_window(hard_iface); send_time =3D own_send_time(bat_priv); -diff -urNp linux-3.1.4/net/batman-adv/soft-interface.c linux-3.1.4/net/b= atman-adv/soft-interface.c ---- linux-3.1.4/net/batman-adv/soft-interface.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/net/batman-adv/soft-interface.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -632,7 +632,7 @@ static int interface_tx(struct sk_buff * +diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-inter= face.c +index 05dd351..2ecd19b 100644 +--- a/net/batman-adv/soft-interface.c ++++ b/net/batman-adv/soft-interface.c +@@ -632,7 +632,7 @@ static int interface_tx(struct sk_buff *skb, struct = net_device *soft_iface) =20 /* set broadcast sequence number */ bcast_packet->seqno =3D @@ -72602,7 +74180,7 @@ diff -urNp linux-3.1.4/net/batman-adv/soft-interf= ace.c linux-3.1.4/net/batman-ad =20 add_bcast_packet_to_list(bat_priv, skb, 1); =20 -@@ -824,7 +824,7 @@ struct net_device *softif_create(const c +@@ -824,7 +824,7 @@ struct net_device *softif_create(const char *name) atomic_set(&bat_priv->batman_queue_left, BATMAN_QUEUE_LEN); =20 atomic_set(&bat_priv->mesh_state, MESH_INACTIVE); @@ -72611,9 +74189,10 @@ diff -urNp linux-3.1.4/net/batman-adv/soft-inter= face.c linux-3.1.4/net/batman-ad atomic_set(&bat_priv->ttvn, 0); atomic_set(&bat_priv->tt_local_changes, 0); atomic_set(&bat_priv->tt_ogm_append_cnt, 0); -diff -urNp linux-3.1.4/net/batman-adv/types.h linux-3.1.4/net/batman-adv= /types.h ---- linux-3.1.4/net/batman-adv/types.h 2011-11-26 19:57:29.000000000 -05= 00 -+++ linux-3.1.4/net/batman-adv/types.h 2011-11-26 20:00:43.000000000 -05= 00 +diff --git a/net/batman-adv/types.h b/net/batman-adv/types.h +index 51a0db7..b8a62be 100644 +--- a/net/batman-adv/types.h ++++ b/net/batman-adv/types.h @@ -38,8 +38,8 @@ struct hard_iface { int16_t if_num; char if_status; @@ -72634,10 +74213,11 @@ diff -urNp linux-3.1.4/net/batman-adv/types.h l= inux-3.1.4/net/batman-adv/types.h atomic_t bcast_queue_left; atomic_t batman_queue_left; atomic_t ttvn; /* tranlation table version number */ -diff -urNp linux-3.1.4/net/batman-adv/unicast.c linux-3.1.4/net/batman-a= dv/unicast.c ---- linux-3.1.4/net/batman-adv/unicast.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/batman-adv/unicast.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -264,7 +264,7 @@ int frag_send_skb(struct sk_buff *skb, s +diff --git a/net/batman-adv/unicast.c b/net/batman-adv/unicast.c +index 32b125f..f1447e0 100644 +--- a/net/batman-adv/unicast.c ++++ b/net/batman-adv/unicast.c +@@ -264,7 +264,7 @@ int frag_send_skb(struct sk_buff *skb, struct bat_pr= iv *bat_priv, frag1->flags =3D UNI_FRAG_HEAD | large_tail; frag2->flags =3D large_tail; =20 @@ -72646,10 +74226,11 @@ diff -urNp linux-3.1.4/net/batman-adv/unicast.c= linux-3.1.4/net/batman-adv/unica frag1->seqno =3D htons(seqno - 1); frag2->seqno =3D htons(seqno); =20 -diff -urNp linux-3.1.4/net/bluetooth/hci_conn.c linux-3.1.4/net/bluetoot= h/hci_conn.c ---- linux-3.1.4/net/bluetooth/hci_conn.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/bluetooth/hci_conn.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -218,7 +218,7 @@ void hci_le_start_enc(struct hci_conn *c +diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c +index ea7f031..0615edc 100644 +--- a/net/bluetooth/hci_conn.c ++++ b/net/bluetooth/hci_conn.c +@@ -218,7 +218,7 @@ void hci_le_start_enc(struct hci_conn *conn, __le16 = ediv, __u8 rand[8], cp.handle =3D cpu_to_le16(conn->handle); memcpy(cp.ltk, ltk, sizeof(cp.ltk)); cp.ediv =3D ediv; @@ -72658,7 +74239,7 @@ diff -urNp linux-3.1.4/net/bluetooth/hci_conn.c l= inux-3.1.4/net/bluetooth/hci_co =20 hci_send_cmd(hdev, HCI_OP_LE_START_ENC, sizeof(cp), &cp); } -@@ -234,7 +234,7 @@ void hci_le_ltk_reply(struct hci_conn *c +@@ -234,7 +234,7 @@ void hci_le_ltk_reply(struct hci_conn *conn, u8 ltk[= 16]) memset(&cp, 0, sizeof(cp)); =20 cp.handle =3D cpu_to_le16(conn->handle); @@ -72667,10 +74248,11 @@ diff -urNp linux-3.1.4/net/bluetooth/hci_conn.c= linux-3.1.4/net/bluetooth/hci_co =20 hci_send_cmd(hdev, HCI_OP_LE_LTK_REPLY, sizeof(cp), &cp); } -diff -urNp linux-3.1.4/net/bridge/br_multicast.c linux-3.1.4/net/bridge/= br_multicast.c ---- linux-3.1.4/net/bridge/br_multicast.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/net/bridge/br_multicast.c 2011-11-16 18:39:08.000000000 = -0500 -@@ -1485,7 +1485,7 @@ static int br_multicast_ipv6_rcv(struct=20 +diff --git a/net/bridge/br_multicast.c b/net/bridge/br_multicast.c +index 995cbe0..c056d6c 100644 +--- a/net/bridge/br_multicast.c ++++ b/net/bridge/br_multicast.c +@@ -1485,7 +1485,7 @@ static int br_multicast_ipv6_rcv(struct net_bridge= *br, nexthdr =3D ip6h->nexthdr; offset =3D ipv6_skip_exthdr(skb, sizeof(*ip6h), &nexthdr); =20 @@ -72679,10 +74261,11 @@ diff -urNp linux-3.1.4/net/bridge/br_multicast.= c linux-3.1.4/net/bridge/br_multi return 0; =20 /* Okay, we found ICMPv6 header */ -diff -urNp linux-3.1.4/net/bridge/netfilter/ebtables.c linux-3.1.4/net/b= ridge/netfilter/ebtables.c ---- linux-3.1.4/net/bridge/netfilter/ebtables.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/net/bridge/netfilter/ebtables.c 2011-11-16 18:40:44.0000= 00000 -0500 -@@ -1513,7 +1513,7 @@ static int do_ebt_get_ctl(struct sock *s +diff --git a/net/bridge/netfilter/ebtables.c b/net/bridge/netfilter/ebta= bles.c +index 5864cc4..94cab18 100644 +--- a/net/bridge/netfilter/ebtables.c ++++ b/net/bridge/netfilter/ebtables.c +@@ -1513,7 +1513,7 @@ static int do_ebt_get_ctl(struct sock *sk, int cmd= , void __user *user, int *len) tmp.valid_hooks =3D t->table->valid_hooks; } mutex_unlock(&ebt_mutex); @@ -72691,7 +74274,7 @@ diff -urNp linux-3.1.4/net/bridge/netfilter/ebtab= les.c linux-3.1.4/net/bridge/ne BUGPRINT("c2u Didn't work\n"); ret =3D -EFAULT; break; -@@ -1781,6 +1781,8 @@ static int compat_copy_everything_to_use +@@ -1781,6 +1781,8 @@ static int compat_copy_everything_to_user(struct e= bt_table *t, int ret; void __user *pos; =20 @@ -72700,9 +74283,10 @@ diff -urNp linux-3.1.4/net/bridge/netfilter/ebta= bles.c linux-3.1.4/net/bridge/ne memset(&tinfo, 0, sizeof(tinfo)); =20 if (cmd =3D=3D EBT_SO_GET_ENTRIES) { -diff -urNp linux-3.1.4/net/caif/caif_socket.c linux-3.1.4/net/caif/caif_= socket.c ---- linux-3.1.4/net/caif/caif_socket.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/caif/caif_socket.c 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/net/caif/caif_socket.c b/net/caif/caif_socket.c +index a986280..13444a1 100644 +--- a/net/caif/caif_socket.c ++++ b/net/caif/caif_socket.c @@ -48,19 +48,20 @@ static struct dentry *debugfsdir; #ifdef CONFIG_DEBUG_FS struct debug_fs_counter { @@ -72734,7 +74318,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c #define dbfs_atomic_dec(v) atomic_dec_return(v) #else #define dbfs_atomic_inc(v) 0 -@@ -161,7 +162,7 @@ static int caif_queue_rcv_skb(struct soc +@@ -161,7 +162,7 @@ static int caif_queue_rcv_skb(struct sock *sk, struc= t sk_buff *skb) atomic_read(&cf_sk->sk.sk_rmem_alloc), sk_rcvbuf_lowwater(cf_sk)); set_rx_flow_off(cf_sk); @@ -72743,7 +74327,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c caif_flow_ctrl(sk, CAIF_MODEMCMD_FLOW_OFF_REQ); } =20 -@@ -172,7 +173,7 @@ static int caif_queue_rcv_skb(struct soc +@@ -172,7 +173,7 @@ static int caif_queue_rcv_skb(struct sock *sk, struc= t sk_buff *skb) set_rx_flow_off(cf_sk); if (net_ratelimit()) pr_debug("sending flow OFF due to rmem_schedule\n"); @@ -72752,7 +74336,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c caif_flow_ctrl(sk, CAIF_MODEMCMD_FLOW_OFF_REQ); } skb->dev =3D NULL; -@@ -233,14 +234,14 @@ static void caif_ctrl_cb(struct cflayer=20 +@@ -233,14 +234,14 @@ static void caif_ctrl_cb(struct cflayer *layr, switch (flow) { case CAIF_CTRLCMD_FLOW_ON_IND: /* OK from modem to start sending again */ @@ -72769,7 +74353,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c set_tx_flow_off(cf_sk); cf_sk->sk.sk_state_change(&cf_sk->sk); break; -@@ -249,7 +250,7 @@ static void caif_ctrl_cb(struct cflayer=20 +@@ -249,7 +250,7 @@ static void caif_ctrl_cb(struct cflayer *layr, /* We're now connected */ caif_client_register_refcnt(&cf_sk->layer, cfsk_hold, cfsk_put); @@ -72778,7 +74362,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c cf_sk->sk.sk_state =3D CAIF_CONNECTED; set_tx_flow_on(cf_sk); cf_sk->sk.sk_state_change(&cf_sk->sk); -@@ -263,7 +264,7 @@ static void caif_ctrl_cb(struct cflayer=20 +@@ -263,7 +264,7 @@ static void caif_ctrl_cb(struct cflayer *layr, =20 case CAIF_CTRLCMD_INIT_FAIL_RSP: /* Connect request failed */ @@ -72787,7 +74371,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c cf_sk->sk.sk_err =3D ECONNREFUSED; cf_sk->sk.sk_state =3D CAIF_DISCONNECTED; cf_sk->sk.sk_shutdown =3D SHUTDOWN_MASK; -@@ -277,7 +278,7 @@ static void caif_ctrl_cb(struct cflayer=20 +@@ -277,7 +278,7 @@ static void caif_ctrl_cb(struct cflayer *layr, =20 case CAIF_CTRLCMD_REMOTE_SHUTDOWN_IND: /* Modem has closed this connection, or device is down. */ @@ -72796,7 +74380,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c cf_sk->sk.sk_shutdown =3D SHUTDOWN_MASK; cf_sk->sk.sk_err =3D ECONNRESET; set_rx_flow_on(cf_sk); -@@ -297,7 +298,7 @@ static void caif_check_flow_release(stru +@@ -297,7 +298,7 @@ static void caif_check_flow_release(struct sock *sk) return; =20 if (atomic_read(&sk->sk_rmem_alloc) <=3D sk_rcvbuf_lowwater(cf_sk)) { @@ -72805,7 +74389,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c set_rx_flow_on(cf_sk); caif_flow_ctrl(sk, CAIF_MODEMCMD_FLOW_ON_REQ); } -@@ -854,7 +855,7 @@ static int caif_connect(struct socket *s +@@ -854,7 +855,7 @@ static int caif_connect(struct socket *sock, struct = sockaddr *uaddr, /*ifindex =3D id of the interface.*/ cf_sk->conn_req.ifindex =3D cf_sk->sk.sk_bound_dev_if; =20 @@ -72814,7 +74398,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c cf_sk->layer.receive =3D caif_sktrecv_cb; =20 err =3D caif_connect_client(sock_net(sk), &cf_sk->conn_req, -@@ -943,7 +944,7 @@ static int caif_release(struct socket *s +@@ -943,7 +944,7 @@ static int caif_release(struct socket *sock) spin_unlock_bh(&sk->sk_receive_queue.lock); sock->sk =3D NULL; =20 @@ -72823,7 +74407,7 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c lin= ux-3.1.4/net/caif/caif_socket.c =20 WARN_ON(IS_ERR(cf_sk->debugfs_socket_dir)); if (cf_sk->debugfs_socket_dir !=3D NULL) -@@ -1122,7 +1123,7 @@ static int caif_create(struct net *net,=20 +@@ -1122,7 +1123,7 @@ static int caif_create(struct net *net, struct soc= ket *sock, int protocol, cf_sk->conn_req.protocol =3D protocol; /* Increase the number of sockets created. */ dbfs_atomic_inc(&cnt.caif_nr_socks); @@ -72832,9 +74416,10 @@ diff -urNp linux-3.1.4/net/caif/caif_socket.c li= nux-3.1.4/net/caif/caif_socket.c #ifdef CONFIG_DEBUG_FS if (!IS_ERR(debugfsdir)) { =20 -diff -urNp linux-3.1.4/net/caif/cfctrl.c linux-3.1.4/net/caif/cfctrl.c ---- linux-3.1.4/net/caif/cfctrl.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/caif/cfctrl.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/net/caif/cfctrl.c b/net/caif/cfctrl.c +index e22671b..6598ea0 100644 +--- a/net/caif/cfctrl.c ++++ b/net/caif/cfctrl.c @@ -9,6 +9,7 @@ #include #include @@ -72854,7 +74439,7 @@ diff -urNp linux-3.1.4/net/caif/cfctrl.c linux-3.= 1.4/net/caif/cfctrl.c this->serv.layer.receive =3D cfctrl_recv; sprintf(this->serv.layer.name, "ctrl"); this->serv.layer.ctrlcmd =3D cfctrl_ctrlcmd; -@@ -132,8 +133,8 @@ static void cfctrl_insert_req(struct cfc +@@ -132,8 +133,8 @@ static void cfctrl_insert_req(struct cfctrl *ctrl, struct cfctrl_request_info *req) { spin_lock_bh(&ctrl->info_list_lock); @@ -72865,7 +74450,7 @@ diff -urNp linux-3.1.4/net/caif/cfctrl.c linux-3.= 1.4/net/caif/cfctrl.c list_add_tail(&req->list, &ctrl->list); spin_unlock_bh(&ctrl->info_list_lock); } -@@ -151,7 +152,7 @@ static struct cfctrl_request_info *cfctr +@@ -151,7 +152,7 @@ static struct cfctrl_request_info *cfctrl_remove_req= (struct cfctrl *ctrl, if (p !=3D first) pr_warn("Requests are not received in order\n"); =20 @@ -72874,7 +74459,7 @@ diff -urNp linux-3.1.4/net/caif/cfctrl.c linux-3.= 1.4/net/caif/cfctrl.c p->sequence_no); list_del(&p->list); goto out; -@@ -364,6 +365,7 @@ static int cfctrl_recv(struct cflayer *l +@@ -364,6 +365,7 @@ static int cfctrl_recv(struct cflayer *layer, struct= cfpkt *pkt) struct cfctrl *cfctrl =3D container_obj(layer); struct cfctrl_request_info rsp, *req; =20 @@ -72882,10 +74467,11 @@ diff -urNp linux-3.1.4/net/caif/cfctrl.c linux-= 3.1.4/net/caif/cfctrl.c =20 cfpkt_extr_head(pkt, &cmdrsp, 1); cmd =3D cmdrsp & CFCTRL_CMD_MASK; -diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/net/compat.c ---- linux-3.1.4/net/compat.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/compat.c 2011-11-16 18:39:08.000000000 -0500 -@@ -70,9 +70,9 @@ int get_compat_msghdr(struct msghdr *kms +diff --git a/net/compat.c b/net/compat.c +index c578d93..257fab7 100644 +--- a/net/compat.c ++++ b/net/compat.c +@@ -70,9 +70,9 @@ int get_compat_msghdr(struct msghdr *kmsg, struct comp= at_msghdr __user *umsg) __get_user(kmsg->msg_controllen, &umsg->msg_controllen) || __get_user(kmsg->msg_flags, &umsg->msg_flags)) return -EFAULT; @@ -72898,7 +74484,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c return 0; } =20 -@@ -84,7 +84,7 @@ int verify_compat_iovec(struct msghdr *k +@@ -84,7 +84,7 @@ int verify_compat_iovec(struct msghdr *kern_msg, struc= t iovec *kern_iov, =20 if (kern_msg->msg_namelen) { if (mode =3D=3D VERIFY_READ) { @@ -72907,7 +74493,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c kern_msg->msg_namelen, kern_address); if (err < 0) -@@ -95,7 +95,7 @@ int verify_compat_iovec(struct msghdr *k +@@ -95,7 +95,7 @@ int verify_compat_iovec(struct msghdr *kern_msg, struc= t iovec *kern_iov, kern_msg->msg_name =3D NULL; =20 tot_len =3D iov_from_user_compat_to_kern(kern_iov, @@ -72916,7 +74502,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c kern_msg->msg_iovlen); if (tot_len >=3D 0) kern_msg->msg_iov =3D kern_iov; -@@ -115,20 +115,20 @@ int verify_compat_iovec(struct msghdr *k +@@ -115,20 +115,20 @@ int verify_compat_iovec(struct msghdr *kern_msg, s= truct iovec *kern_iov, =20 #define CMSG_COMPAT_FIRSTHDR(msg) \ (((msg)->msg_controllen) >=3D sizeof(struct compat_cmsghdr) ? \ @@ -72940,7 +74526,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c msg->msg_controllen) return NULL; return (struct compat_cmsghdr __user *)ptr; -@@ -220,7 +220,7 @@ int put_cmsg_compat(struct msghdr *kmsg, +@@ -220,7 +220,7 @@ int put_cmsg_compat(struct msghdr *kmsg, int level, = int type, int len, void *dat { struct compat_timeval ctv; struct compat_timespec cts[3]; @@ -72949,7 +74535,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c struct compat_cmsghdr cmhdr; int cmlen; =20 -@@ -272,7 +272,7 @@ int put_cmsg_compat(struct msghdr *kmsg, +@@ -272,7 +272,7 @@ int put_cmsg_compat(struct msghdr *kmsg, int level, = int type, int len, void *dat =20 void scm_detach_fds_compat(struct msghdr *kmsg, struct scm_cookie *scm) { @@ -72958,7 +74544,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c int fdmax =3D (kmsg->msg_controllen - sizeof(struct compat_cmsghdr)) /= sizeof(int); int fdnum =3D scm->fp->count; struct file **fp =3D scm->fp->fp; -@@ -369,7 +369,7 @@ static int do_set_sock_timeout(struct so +@@ -369,7 +369,7 @@ static int do_set_sock_timeout(struct socket *sock, = int level, return -EFAULT; old_fs =3D get_fs(); set_fs(KERNEL_DS); @@ -72967,7 +74553,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c set_fs(old_fs); =20 return err; -@@ -430,7 +430,7 @@ static int do_get_sock_timeout(struct so +@@ -430,7 +430,7 @@ static int do_get_sock_timeout(struct socket *sock, = int level, int optname, len =3D sizeof(ktime); old_fs =3D get_fs(); set_fs(KERNEL_DS); @@ -72976,7 +74562,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c set_fs(old_fs); =20 if (!err) { -@@ -565,7 +565,7 @@ int compat_mc_setsockopt(struct sock *so +@@ -565,7 +565,7 @@ int compat_mc_setsockopt(struct sock *sock, int leve= l, int optname, case MCAST_JOIN_GROUP: case MCAST_LEAVE_GROUP: { @@ -72985,7 +74571,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c struct group_req __user *kgr =3D compat_alloc_user_space(sizeof(struct group_req)); u32 interface; -@@ -586,7 +586,7 @@ int compat_mc_setsockopt(struct sock *so +@@ -586,7 +586,7 @@ int compat_mc_setsockopt(struct sock *sock, int leve= l, int optname, case MCAST_BLOCK_SOURCE: case MCAST_UNBLOCK_SOURCE: { @@ -72994,7 +74580,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c struct group_source_req __user *kgsr =3D compat_alloc_user_space( sizeof(struct group_source_req)); u32 interface; -@@ -607,7 +607,7 @@ int compat_mc_setsockopt(struct sock *so +@@ -607,7 +607,7 @@ int compat_mc_setsockopt(struct sock *sock, int leve= l, int optname, } case MCAST_MSFILTER: { @@ -73003,7 +74589,7 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4/n= et/compat.c struct group_filter __user *kgf; u32 interface, fmode, numsrc; =20 -@@ -645,7 +645,7 @@ int compat_mc_getsockopt(struct sock *so +@@ -645,7 +645,7 @@ int compat_mc_getsockopt(struct sock *sock, int leve= l, int optname, char __user *optval, int __user *optlen, int (*getsockopt)(struct sock *, int, int, char __user *, int __user *= )) { @@ -73012,10 +74598,11 @@ diff -urNp linux-3.1.4/net/compat.c linux-3.1.4= /net/compat.c struct group_filter __user *kgf; int __user *koptlen; u32 interface, fmode, numsrc; -diff -urNp linux-3.1.4/net/core/datagram.c linux-3.1.4/net/core/datagram= .c ---- linux-3.1.4/net/core/datagram.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/datagram.c 2011-11-16 18:39:08.000000000 -0500 -@@ -285,7 +285,7 @@ int skb_kill_datagram(struct sock *sk, s +diff --git a/net/core/datagram.c b/net/core/datagram.c +index 18ac112..fe95ed9 100644 +--- a/net/core/datagram.c ++++ b/net/core/datagram.c +@@ -285,7 +285,7 @@ int skb_kill_datagram(struct sock *sk, struct sk_buf= f *skb, unsigned int flags) } =20 kfree_skb(skb); @@ -73024,10 +74611,11 @@ diff -urNp linux-3.1.4/net/core/datagram.c linu= x-3.1.4/net/core/datagram.c sk_mem_reclaim_partial(sk); =20 return err; -diff -urNp linux-3.1.4/net/core/dev.c linux-3.1.4/net/core/dev.c ---- linux-3.1.4/net/core/dev.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/dev.c 2011-11-16 18:40:44.000000000 -0500 -@@ -1135,10 +1135,14 @@ void dev_load(struct net *net, const cha +diff --git a/net/core/dev.c b/net/core/dev.c +index ae5cf2d..2c950a1 100644 +--- a/net/core/dev.c ++++ b/net/core/dev.c +@@ -1135,10 +1135,14 @@ void dev_load(struct net *net, const char *name) if (no_module && capable(CAP_NET_ADMIN)) no_module =3D request_module("netdev-%s", name); if (no_module && capable(CAP_SYS_MODULE)) { @@ -73042,7 +74630,7 @@ diff -urNp linux-3.1.4/net/core/dev.c linux-3.1.4= /net/core/dev.c } } EXPORT_SYMBOL(dev_load); -@@ -1977,7 +1981,7 @@ static int illegal_highdma(struct net_de +@@ -1977,7 +1981,7 @@ static int illegal_highdma(struct net_device *dev,= struct sk_buff *skb) =20 struct dev_gso_cb { void (*destructor)(struct sk_buff *skb); @@ -73060,7 +74648,7 @@ diff -urNp linux-3.1.4/net/core/dev.c linux-3.1.4= /net/core/dev.c { struct softnet_data *sd =3D &__get_cpu_var(softnet_data); =20 -@@ -3779,7 +3783,7 @@ void netif_napi_del(struct napi_struct * +@@ -3779,7 +3783,7 @@ void netif_napi_del(struct napi_struct *napi) } EXPORT_SYMBOL(netif_napi_del); =20 @@ -73069,9 +74657,10 @@ diff -urNp linux-3.1.4/net/core/dev.c linux-3.1.= 4/net/core/dev.c { struct softnet_data *sd =3D &__get_cpu_var(softnet_data); unsigned long time_limit =3D jiffies + 2; -diff -urNp linux-3.1.4/net/core/flow.c linux-3.1.4/net/core/flow.c ---- linux-3.1.4/net/core/flow.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/flow.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/core/flow.c b/net/core/flow.c +index 555a456..de48421 100644 +--- a/net/core/flow.c ++++ b/net/core/flow.c @@ -61,7 +61,7 @@ struct flow_cache { struct timer_list rnd_timer; }; @@ -73081,7 +74670,7 @@ diff -urNp linux-3.1.4/net/core/flow.c linux-3.1.= 4/net/core/flow.c EXPORT_SYMBOL(flow_cache_genid); static struct flow_cache flow_cache_global; static struct kmem_cache *flow_cachep __read_mostly; -@@ -86,7 +86,7 @@ static void flow_cache_new_hashrnd(unsig +@@ -86,7 +86,7 @@ static void flow_cache_new_hashrnd(unsigned long arg) =20 static int flow_entry_valid(struct flow_cache_entry *fle) { @@ -73090,7 +74679,7 @@ diff -urNp linux-3.1.4/net/core/flow.c linux-3.1.= 4/net/core/flow.c return 0; if (fle->object && !fle->object->ops->check(fle->object)) return 0; -@@ -259,7 +259,7 @@ flow_cache_lookup(struct net *net, const +@@ -259,7 +259,7 @@ flow_cache_lookup(struct net *net, const struct flow= i *key, u16 family, u8 dir, hlist_add_head(&fle->u.hlist, &fcp->hash_table[hash]); fcp->hash_count++; } @@ -73108,10 +74697,11 @@ diff -urNp linux-3.1.4/net/core/flow.c linux-3.= 1.4/net/core/flow.c if (!IS_ERR(flo)) fle->object =3D flo; else -diff -urNp linux-3.1.4/net/core/iovec.c linux-3.1.4/net/core/iovec.c ---- linux-3.1.4/net/core/iovec.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/iovec.c 2011-11-16 18:39:08.000000000 -0500 -@@ -42,7 +42,7 @@ int verify_iovec(struct msghdr *m, struc +diff --git a/net/core/iovec.c b/net/core/iovec.c +index c40f27e..7f49254 100644 +--- a/net/core/iovec.c ++++ b/net/core/iovec.c +@@ -42,7 +42,7 @@ int verify_iovec(struct msghdr *m, struct iovec *iov, = struct sockaddr *address, if (m->msg_namelen) { if (mode =3D=3D VERIFY_READ) { void __user *namep; @@ -73120,7 +74710,7 @@ diff -urNp linux-3.1.4/net/core/iovec.c linux-3.1= .4/net/core/iovec.c err =3D move_addr_to_kernel(namep, m->msg_namelen, address); if (err < 0) -@@ -54,7 +54,7 @@ int verify_iovec(struct msghdr *m, struc +@@ -54,7 +54,7 @@ int verify_iovec(struct msghdr *m, struct iovec *iov, = struct sockaddr *address, } =20 size =3D m->msg_iovlen * sizeof(struct iovec); @@ -73129,9 +74719,10 @@ diff -urNp linux-3.1.4/net/core/iovec.c linux-3.= 1.4/net/core/iovec.c return -EFAULT; =20 m->msg_iov =3D iov; -diff -urNp linux-3.1.4/net/core/rtnetlink.c linux-3.1.4/net/core/rtnetli= nk.c ---- linux-3.1.4/net/core/rtnetlink.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/rtnetlink.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c +index 99d9e95..209bae2 100644 +--- a/net/core/rtnetlink.c ++++ b/net/core/rtnetlink.c @@ -57,7 +57,7 @@ struct rtnl_link { rtnl_doit_func doit; rtnl_dumpit_func dumpit; @@ -73141,9 +74732,10 @@ diff -urNp linux-3.1.4/net/core/rtnetlink.c linu= x-3.1.4/net/core/rtnetlink.c =20 static DEFINE_MUTEX(rtnl_mutex); static u16 min_ifinfo_dump_size; -diff -urNp linux-3.1.4/net/core/scm.c linux-3.1.4/net/core/scm.c ---- linux-3.1.4/net/core/scm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/scm.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/core/scm.c b/net/core/scm.c +index 811b53f..5d6c343 100644 +--- a/net/core/scm.c ++++ b/net/core/scm.c @@ -218,7 +218,7 @@ EXPORT_SYMBOL(__scm_send); int put_cmsg(struct msghdr * msg, int level, int type, int len, void *d= ata) { @@ -73153,7 +74745,7 @@ diff -urNp linux-3.1.4/net/core/scm.c linux-3.1.4= /net/core/scm.c struct cmsghdr cmhdr; int cmlen =3D CMSG_LEN(len); int err; -@@ -241,7 +241,7 @@ int put_cmsg(struct msghdr * msg, int le +@@ -241,7 +241,7 @@ int put_cmsg(struct msghdr * msg, int level, int typ= e, int len, void *data) err =3D -EFAULT; if (copy_to_user(cm, &cmhdr, sizeof cmhdr)) goto out; @@ -73171,7 +74763,7 @@ diff -urNp linux-3.1.4/net/core/scm.c linux-3.1.4= /net/core/scm.c =20 int fdmax =3D 0; int fdnum =3D scm->fp->count; -@@ -277,7 +277,7 @@ void scm_detach_fds(struct msghdr *msg,=20 +@@ -277,7 +277,7 @@ void scm_detach_fds(struct msghdr *msg, struct scm_c= ookie *scm) if (fdnum < fdmax) fdmax =3D fdnum; =20 @@ -73180,10 +74772,11 @@ diff -urNp linux-3.1.4/net/core/scm.c linux-3.1= .4/net/core/scm.c i++, cmfptr++) { int new_fd; -diff -urNp linux-3.1.4/net/core/skbuff.c linux-3.1.4/net/core/skbuff.c ---- linux-3.1.4/net/core/skbuff.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/skbuff.c 2011-11-16 18:40:44.000000000 -0500 -@@ -1650,6 +1650,8 @@ int skb_splice_bits(struct sk_buff *skb, +diff --git a/net/core/skbuff.c b/net/core/skbuff.c +index 387703f..035abcf 100644 +--- a/net/core/skbuff.c ++++ b/net/core/skbuff.c +@@ -1650,6 +1650,8 @@ int skb_splice_bits(struct sk_buff *skb, unsigned = int offset, struct sock *sk =3D skb->sk; int ret =3D 0; =20 @@ -73192,10 +74785,11 @@ diff -urNp linux-3.1.4/net/core/skbuff.c linux-= 3.1.4/net/core/skbuff.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; =20 -diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.4/net/core/sock.c ---- linux-3.1.4/net/core/sock.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/core/sock.c 2011-11-16 18:40:44.000000000 -0500 -@@ -293,7 +293,7 @@ int sock_queue_rcv_skb(struct sock *sk,=20 +diff --git a/net/core/sock.c b/net/core/sock.c +index 11d67b3..df26d4b 100644 +--- a/net/core/sock.c ++++ b/net/core/sock.c +@@ -293,7 +293,7 @@ int sock_queue_rcv_skb(struct sock *sk, struct sk_bu= ff *skb) */ if (atomic_read(&sk->sk_rmem_alloc) + skb->truesize >=3D (unsigned)sk->sk_rcvbuf) { @@ -73204,7 +74798,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c trace_sock_rcvqueue_full(sk, skb); return -ENOMEM; } -@@ -303,7 +303,7 @@ int sock_queue_rcv_skb(struct sock *sk,=20 +@@ -303,7 +303,7 @@ int sock_queue_rcv_skb(struct sock *sk, struct sk_bu= ff *skb) return err; =20 if (!sk_rmem_schedule(sk, skb->truesize)) { @@ -73213,7 +74807,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c return -ENOBUFS; } =20 -@@ -323,7 +323,7 @@ int sock_queue_rcv_skb(struct sock *sk,=20 +@@ -323,7 +323,7 @@ int sock_queue_rcv_skb(struct sock *sk, struct sk_bu= ff *skb) skb_dst_force(skb); =20 spin_lock_irqsave(&list->lock, flags); @@ -73222,7 +74816,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c __skb_queue_tail(list, skb); spin_unlock_irqrestore(&list->lock, flags); =20 -@@ -343,7 +343,7 @@ int sk_receive_skb(struct sock *sk, stru +@@ -343,7 +343,7 @@ int sk_receive_skb(struct sock *sk, struct sk_buff *= skb, const int nested) skb->dev =3D NULL; =20 if (sk_rcvqueues_full(sk, skb)) { @@ -73231,7 +74825,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c goto discard_and_relse; } if (nested) -@@ -361,7 +361,7 @@ int sk_receive_skb(struct sock *sk, stru +@@ -361,7 +361,7 @@ int sk_receive_skb(struct sock *sk, struct sk_buff *= skb, const int nested) mutex_release(&sk->sk_lock.dep_map, 1, _RET_IP_); } else if (sk_add_backlog(sk, skb)) { bh_unlock_sock(sk); @@ -73240,7 +74834,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c goto discard_and_relse; } =20 -@@ -924,7 +924,7 @@ int sock_getsockopt(struct socket *sock, +@@ -924,7 +924,7 @@ int sock_getsockopt(struct socket *sock, int level, = int optname, if (len > sizeof(peercred)) len =3D sizeof(peercred); cred_to_ucred(sk->sk_peer_pid, sk->sk_peer_cred, &peercred); @@ -73249,7 +74843,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c return -EFAULT; goto lenout; } -@@ -937,7 +937,7 @@ int sock_getsockopt(struct socket *sock, +@@ -937,7 +937,7 @@ int sock_getsockopt(struct socket *sock, int level, = int optname, return -ENOTCONN; if (lv < len) return -EINVAL; @@ -73258,7 +74852,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c return -EFAULT; goto lenout; } -@@ -970,7 +970,7 @@ int sock_getsockopt(struct socket *sock, +@@ -970,7 +970,7 @@ int sock_getsockopt(struct socket *sock, int level, = int optname, =20 if (len > lv) len =3D lv; @@ -73267,7 +74861,7 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.1.= 4/net/core/sock.c return -EFAULT; lenout: if (put_user(len, optlen)) -@@ -2029,7 +2029,7 @@ void sock_init_data(struct socket *sock, +@@ -2029,7 +2029,7 @@ void sock_init_data(struct socket *sock, struct so= ck *sk) */ smp_wmb(); atomic_set(&sk->sk_refcnt, 1); @@ -73276,10 +74870,11 @@ diff -urNp linux-3.1.4/net/core/sock.c linux-3.= 1.4/net/core/sock.c } EXPORT_SYMBOL(sock_init_data); =20 -diff -urNp linux-3.1.4/net/decnet/sysctl_net_decnet.c linux-3.1.4/net/de= cnet/sysctl_net_decnet.c ---- linux-3.1.4/net/decnet/sysctl_net_decnet.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/net/decnet/sysctl_net_decnet.c 2011-11-16 18:39:08.00000= 0000 -0500 -@@ -174,7 +174,7 @@ static int dn_node_address_handler(ctl_t +diff --git a/net/decnet/sysctl_net_decnet.c b/net/decnet/sysctl_net_decn= et.c +index 02e75d1..9a57a7c 100644 +--- a/net/decnet/sysctl_net_decnet.c ++++ b/net/decnet/sysctl_net_decnet.c +@@ -174,7 +174,7 @@ static int dn_node_address_handler(ctl_table *table,= int write, =20 if (len > *lenp) len =3D *lenp; =20 @@ -73288,7 +74883,7 @@ diff -urNp linux-3.1.4/net/decnet/sysctl_net_decn= et.c linux-3.1.4/net/decnet/sys return -EFAULT; =20 *lenp =3D len; -@@ -237,7 +237,7 @@ static int dn_def_dev_handler(ctl_table=20 +@@ -237,7 +237,7 @@ static int dn_def_dev_handler(ctl_table *table, int = write, =20 if (len > *lenp) len =3D *lenp; =20 @@ -73297,9 +74892,10 @@ diff -urNp linux-3.1.4/net/decnet/sysctl_net_dec= net.c linux-3.1.4/net/decnet/sys return -EFAULT; =20 *lenp =3D len; -diff -urNp linux-3.1.4/net/econet/Kconfig linux-3.1.4/net/econet/Kconfig ---- linux-3.1.4/net/econet/Kconfig 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/econet/Kconfig 2011-11-16 18:40:44.000000000 -0500 +diff --git a/net/econet/Kconfig b/net/econet/Kconfig +index 39a2d29..f39c0fe 100644 +--- a/net/econet/Kconfig ++++ b/net/econet/Kconfig @@ -4,7 +4,7 @@ =20 config ECONET @@ -73309,10 +74905,11 @@ diff -urNp linux-3.1.4/net/econet/Kconfig linux= -3.1.4/net/econet/Kconfig ---help--- Econet is a fairly old and slow networking protocol mainly used by Acorn computers to access file and print servers. It uses native -diff -urNp linux-3.1.4/net/ipv4/fib_frontend.c linux-3.1.4/net/ipv4/fib_= frontend.c ---- linux-3.1.4/net/ipv4/fib_frontend.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/net/ipv4/fib_frontend.c 2011-11-16 18:39:08.000000000 -0= 500 -@@ -970,12 +970,12 @@ static int fib_inetaddr_event(struct not +diff --git a/net/ipv4/fib_frontend.c b/net/ipv4/fib_frontend.c +index 92fc5f6..b790d91 100644 +--- a/net/ipv4/fib_frontend.c ++++ b/net/ipv4/fib_frontend.c +@@ -970,12 +970,12 @@ static int fib_inetaddr_event(struct notifier_bloc= k *this, unsigned long event, #ifdef CONFIG_IP_ROUTE_MULTIPATH fib_sync_up(dev); #endif @@ -73327,7 +74924,7 @@ diff -urNp linux-3.1.4/net/ipv4/fib_frontend.c li= nux-3.1.4/net/ipv4/fib_frontend if (ifa->ifa_dev->ifa_list =3D=3D NULL) { /* Last address was deleted from this interface. * Disable IP. -@@ -1011,7 +1011,7 @@ static int fib_netdev_event(struct notif +@@ -1011,7 +1011,7 @@ static int fib_netdev_event(struct notifier_block = *this, unsigned long event, vo #ifdef CONFIG_IP_ROUTE_MULTIPATH fib_sync_up(dev); #endif @@ -73336,10 +74933,11 @@ diff -urNp linux-3.1.4/net/ipv4/fib_frontend.c = linux-3.1.4/net/ipv4/fib_frontend rt_cache_flush(dev_net(dev), -1); break; case NETDEV_DOWN: -diff -urNp linux-3.1.4/net/ipv4/fib_semantics.c linux-3.1.4/net/ipv4/fib= _semantics.c ---- linux-3.1.4/net/ipv4/fib_semantics.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/ipv4/fib_semantics.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -699,7 +699,7 @@ __be32 fib_info_update_nh_saddr(struct n +diff --git a/net/ipv4/fib_semantics.c b/net/ipv4/fib_semantics.c +index 80106d8..232e898 100644 +--- a/net/ipv4/fib_semantics.c ++++ b/net/ipv4/fib_semantics.c +@@ -699,7 +699,7 @@ __be32 fib_info_update_nh_saddr(struct net *net, str= uct fib_nh *nh) nh->nh_saddr =3D inet_select_addr(nh->nh_dev, nh->nh_gw, nh->nh_parent->fib_scope); @@ -73348,10 +74946,11 @@ diff -urNp linux-3.1.4/net/ipv4/fib_semantics.c= linux-3.1.4/net/ipv4/fib_semanti =20 return nh->nh_saddr; } -diff -urNp linux-3.1.4/net/ipv4/inet_diag.c linux-3.1.4/net/ipv4/inet_di= ag.c ---- linux-3.1.4/net/ipv4/inet_diag.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/inet_diag.c 2011-11-16 18:40:44.000000000 -0500 -@@ -114,8 +114,14 @@ static int inet_csk_diag_fill(struct soc +diff --git a/net/ipv4/inet_diag.c b/net/ipv4/inet_diag.c +index 389a2e6..ac1c1de 100644 +--- a/net/ipv4/inet_diag.c ++++ b/net/ipv4/inet_diag.c +@@ -114,8 +114,14 @@ static int inet_csk_diag_fill(struct sock *sk, r->idiag_retrans =3D 0; =20 r->id.idiag_if =3D sk->sk_bound_dev_if; @@ -73366,7 +74965,7 @@ diff -urNp linux-3.1.4/net/ipv4/inet_diag.c linux= -3.1.4/net/ipv4/inet_diag.c =20 r->id.idiag_sport =3D inet->inet_sport; r->id.idiag_dport =3D inet->inet_dport; -@@ -201,8 +207,15 @@ static int inet_twsk_diag_fill(struct in +@@ -201,8 +207,15 @@ static int inet_twsk_diag_fill(struct inet_timewait= _sock *tw, r->idiag_family =3D tw->tw_family; r->idiag_retrans =3D 0; r->id.idiag_if =3D tw->tw_bound_dev_if; @@ -73382,7 +74981,7 @@ diff -urNp linux-3.1.4/net/ipv4/inet_diag.c linux= -3.1.4/net/ipv4/inet_diag.c r->id.idiag_sport =3D tw->tw_sport; r->id.idiag_dport =3D tw->tw_dport; r->id.idiag_src[0] =3D tw->tw_rcv_saddr; -@@ -285,12 +298,14 @@ static int inet_diag_get_exact(struct sk +@@ -285,12 +298,14 @@ static int inet_diag_get_exact(struct sk_buff *in_= skb, if (sk =3D=3D NULL) goto unlock; =20 @@ -73397,7 +74996,7 @@ diff -urNp linux-3.1.4/net/ipv4/inet_diag.c linux= -3.1.4/net/ipv4/inet_diag.c =20 err =3D -ENOMEM; rep =3D alloc_skb(NLMSG_SPACE((sizeof(struct inet_diag_msg) + -@@ -580,8 +595,14 @@ static int inet_diag_fill_req(struct sk_ +@@ -580,8 +595,14 @@ static int inet_diag_fill_req(struct sk_buff *skb, = struct sock *sk, r->idiag_retrans =3D req->retrans; =20 r->id.idiag_if =3D sk->sk_bound_dev_if; @@ -73412,9 +75011,10 @@ diff -urNp linux-3.1.4/net/ipv4/inet_diag.c linu= x-3.1.4/net/ipv4/inet_diag.c =20 tmo =3D req->expires - jiffies; if (tmo < 0) -diff -urNp linux-3.1.4/net/ipv4/inet_hashtables.c linux-3.1.4/net/ipv4/i= net_hashtables.c ---- linux-3.1.4/net/ipv4/inet_hashtables.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/net/ipv4/inet_hashtables.c 2011-11-16 18:40:44.000000000= -0500 +diff --git a/net/ipv4/inet_hashtables.c b/net/ipv4/inet_hashtables.c +index 984ec65..97ac518 100644 +--- a/net/ipv4/inet_hashtables.c ++++ b/net/ipv4/inet_hashtables.c @@ -18,12 +18,15 @@ #include #include @@ -73440,10 +75040,11 @@ diff -urNp linux-3.1.4/net/ipv4/inet_hashtables= .c linux-3.1.4/net/ipv4/inet_hash if (tw) { inet_twsk_deschedule(tw, death_row); while (twrefcnt) { -diff -urNp linux-3.1.4/net/ipv4/inetpeer.c linux-3.1.4/net/ipv4/inetpeer= .c ---- linux-3.1.4/net/ipv4/inetpeer.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/inetpeer.c 2011-11-16 19:18:22.000000000 -0500 -@@ -400,6 +400,8 @@ struct inet_peer *inet_getpeer(const str +diff --git a/net/ipv4/inetpeer.c b/net/ipv4/inetpeer.c +index 86f13c67..0bce60f 100644 +--- a/net/ipv4/inetpeer.c ++++ b/net/ipv4/inetpeer.c +@@ -400,6 +400,8 @@ struct inet_peer *inet_getpeer(const struct inetpeer= _addr *daddr, int create) unsigned int sequence; int invalidated, gccnt =3D 0; =20 @@ -73463,40 +75064,11 @@ diff -urNp linux-3.1.4/net/ipv4/inetpeer.c linu= x-3.1.4/net/ipv4/inetpeer.c (daddr->family =3D=3D AF_INET) ? secure_ip_id(daddr->addr.a4) : secure_ipv6_id(daddr->addr.a6)); -diff -urNp linux-3.1.4/net/ipv4/ipconfig.c linux-3.1.4/net/ipv4/ipconfig= .c ---- linux-3.1.4/net/ipv4/ipconfig.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/ipconfig.c 2011-11-16 18:39:08.000000000 -0500 -@@ -313,7 +313,7 @@ static int __init ic_devinet_ioctl(unsig -=20 - mm_segment_t oldfs =3D get_fs(); - set_fs(get_ds()); -- res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __user *) arg); -+ res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __force_user *) ar= g); - set_fs(oldfs); - return res; - } -@@ -324,7 +324,7 @@ static int __init ic_dev_ioctl(unsigned=20 -=20 - mm_segment_t oldfs =3D get_fs(); - set_fs(get_ds()); -- res =3D dev_ioctl(&init_net, cmd, (struct ifreq __user *) arg); -+ res =3D dev_ioctl(&init_net, cmd, (struct ifreq __force_user *) arg); - set_fs(oldfs); - return res; - } -@@ -335,7 +335,7 @@ static int __init ic_route_ioctl(unsigne -=20 - mm_segment_t oldfs =3D get_fs(); - set_fs(get_ds()); -- res =3D ip_rt_ioctl(&init_net, cmd, (void __user *) arg); -+ res =3D ip_rt_ioctl(&init_net, cmd, (void __force_user *) arg); - set_fs(oldfs); - return res; - } -diff -urNp linux-3.1.4/net/ipv4/ip_fragment.c linux-3.1.4/net/ipv4/ip_fr= agment.c ---- linux-3.1.4/net/ipv4/ip_fragment.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/ipv4/ip_fragment.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -316,7 +316,7 @@ static inline int ip_frag_too_far(struct +diff --git a/net/ipv4/ip_fragment.c b/net/ipv4/ip_fragment.c +index 0e0ab98..2ed7dd5 100644 +--- a/net/ipv4/ip_fragment.c ++++ b/net/ipv4/ip_fragment.c +@@ -316,7 +316,7 @@ static inline int ip_frag_too_far(struct ipq *qp) return 0; =20 start =3D qp->rid; @@ -73505,10 +75077,11 @@ diff -urNp linux-3.1.4/net/ipv4/ip_fragment.c l= inux-3.1.4/net/ipv4/ip_fragment.c qp->rid =3D end; =20 rc =3D qp->q.fragments && (end - start) > max; -diff -urNp linux-3.1.4/net/ipv4/ip_sockglue.c linux-3.1.4/net/ipv4/ip_so= ckglue.c ---- linux-3.1.4/net/ipv4/ip_sockglue.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/ipv4/ip_sockglue.c 2011-11-16 18:40:44.000000000 -05= 00 -@@ -1073,6 +1073,8 @@ static int do_ip_getsockopt(struct sock=20 +diff --git a/net/ipv4/ip_sockglue.c b/net/ipv4/ip_sockglue.c +index 8905e92..0b179fb 100644 +--- a/net/ipv4/ip_sockglue.c ++++ b/net/ipv4/ip_sockglue.c +@@ -1073,6 +1073,8 @@ static int do_ip_getsockopt(struct sock *sk, int l= evel, int optname, int val; int len; =20 @@ -73517,7 +75090,7 @@ diff -urNp linux-3.1.4/net/ipv4/ip_sockglue.c lin= ux-3.1.4/net/ipv4/ip_sockglue.c if (level !=3D SOL_IP) return -EOPNOTSUPP; =20 -@@ -1110,7 +1112,8 @@ static int do_ip_getsockopt(struct sock=20 +@@ -1110,7 +1112,8 @@ static int do_ip_getsockopt(struct sock *sk, int l= evel, int optname, len =3D min_t(unsigned int, len, opt->optlen); if (put_user(len, optlen)) return -EFAULT; @@ -73527,7 +75100,7 @@ diff -urNp linux-3.1.4/net/ipv4/ip_sockglue.c lin= ux-3.1.4/net/ipv4/ip_sockglue.c return -EFAULT; return 0; } -@@ -1238,7 +1241,7 @@ static int do_ip_getsockopt(struct sock=20 +@@ -1238,7 +1241,7 @@ static int do_ip_getsockopt(struct sock *sk, int l= evel, int optname, if (sk->sk_type !=3D SOCK_STREAM) return -ENOPROTOOPT; =20 @@ -73536,10 +75109,42 @@ diff -urNp linux-3.1.4/net/ipv4/ip_sockglue.c l= inux-3.1.4/net/ipv4/ip_sockglue.c msg.msg_controllen =3D len; msg.msg_flags =3D flags; =20 -diff -urNp linux-3.1.4/net/ipv4/netfilter/nf_nat_snmp_basic.c linux-3.1.= 4/net/ipv4/netfilter/nf_nat_snmp_basic.c ---- linux-3.1.4/net/ipv4/netfilter/nf_nat_snmp_basic.c 2011-11-11 15:19:= 27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/netfilter/nf_nat_snmp_basic.c 2011-11-16 18:39:= 08.000000000 -0500 -@@ -399,7 +399,7 @@ static unsigned char asn1_octets_decode( +diff --git a/net/ipv4/ipconfig.c b/net/ipv4/ipconfig.c +index 472a8c4..6507cd4 100644 +--- a/net/ipv4/ipconfig.c ++++ b/net/ipv4/ipconfig.c +@@ -313,7 +313,7 @@ static int __init ic_devinet_ioctl(unsigned int cmd,= struct ifreq *arg) +=20 + mm_segment_t oldfs =3D get_fs(); + set_fs(get_ds()); +- res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __user *) arg); ++ res =3D devinet_ioctl(&init_net, cmd, (struct ifreq __force_user *) ar= g); + set_fs(oldfs); + return res; + } +@@ -324,7 +324,7 @@ static int __init ic_dev_ioctl(unsigned int cmd, str= uct ifreq *arg) +=20 + mm_segment_t oldfs =3D get_fs(); + set_fs(get_ds()); +- res =3D dev_ioctl(&init_net, cmd, (struct ifreq __user *) arg); ++ res =3D dev_ioctl(&init_net, cmd, (struct ifreq __force_user *) arg); + set_fs(oldfs); + return res; + } +@@ -335,7 +335,7 @@ static int __init ic_route_ioctl(unsigned int cmd, s= truct rtentry *arg) +=20 + mm_segment_t oldfs =3D get_fs(); + set_fs(get_ds()); +- res =3D ip_rt_ioctl(&init_net, cmd, (void __user *) arg); ++ res =3D ip_rt_ioctl(&init_net, cmd, (void __force_user *) arg); + set_fs(oldfs); + return res; + } +diff --git a/net/ipv4/netfilter/nf_nat_snmp_basic.c b/net/ipv4/netfilter= /nf_nat_snmp_basic.c +index 076b7c8..9c8d038 100644 +--- a/net/ipv4/netfilter/nf_nat_snmp_basic.c ++++ b/net/ipv4/netfilter/nf_nat_snmp_basic.c +@@ -399,7 +399,7 @@ static unsigned char asn1_octets_decode(struct asn1_= ctx *ctx, =20 *len =3D 0; =20 @@ -73548,10 +75153,11 @@ diff -urNp linux-3.1.4/net/ipv4/netfilter/nf_na= t_snmp_basic.c linux-3.1.4/net/ip if (*octets =3D=3D NULL) { if (net_ratelimit()) pr_notice("OOM in bsalg (%d)\n", __LINE__); -diff -urNp linux-3.1.4/net/ipv4/ping.c linux-3.1.4/net/ipv4/ping.c ---- linux-3.1.4/net/ipv4/ping.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/ping.c 2011-11-16 18:39:08.000000000 -0500 -@@ -837,7 +837,7 @@ static void ping_format_sock(struct sock +diff --git a/net/ipv4/ping.c b/net/ipv4/ping.c +index 39b403f..8e6a0a8 100644 +--- a/net/ipv4/ping.c ++++ b/net/ipv4/ping.c +@@ -837,7 +837,7 @@ static void ping_format_sock(struct sock *sp, struct= seq_file *f, sk_rmem_alloc_get(sp), 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), atomic_read(&sp->sk_refcnt), sp, @@ -73560,10 +75166,11 @@ diff -urNp linux-3.1.4/net/ipv4/ping.c linux-3.= 1.4/net/ipv4/ping.c } =20 static int ping_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.1.4/net/ipv4/raw.c linux-3.1.4/net/ipv4/raw.c ---- linux-3.1.4/net/ipv4/raw.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/raw.c 2011-11-17 18:58:40.000000000 -0500 -@@ -302,7 +302,7 @@ static int raw_rcv_skb(struct sock * sk, +diff --git a/net/ipv4/raw.c b/net/ipv4/raw.c +index 61714bd..c9cee6d 100644 +--- a/net/ipv4/raw.c ++++ b/net/ipv4/raw.c +@@ -302,7 +302,7 @@ static int raw_rcv_skb(struct sock * sk, struct sk_b= uff * skb) int raw_rcv(struct sock *sk, struct sk_buff *skb) { if (!xfrm4_policy_check(sk, XFRM_POLICY_IN, skb)) { @@ -73594,7 +75201,7 @@ diff -urNp linux-3.1.4/net/ipv4/raw.c linux-3.1.4= /net/ipv4/raw.c =20 if (get_user(len, optlen)) goto out; -@@ -756,8 +760,8 @@ static int raw_geticmpfilter(struct sock +@@ -756,8 +760,8 @@ static int raw_geticmpfilter(struct sock *sk, char _= _user *optval, int __user *o if (len > sizeof(struct icmp_filter)) len =3D sizeof(struct icmp_filter); ret =3D -EFAULT; @@ -73605,7 +75212,7 @@ diff -urNp linux-3.1.4/net/ipv4/raw.c linux-3.1.4= /net/ipv4/raw.c goto out; ret =3D 0; out: return ret; -@@ -985,7 +989,13 @@ static void raw_sock_seq_show(struct seq +@@ -985,7 +989,13 @@ static void raw_sock_seq_show(struct seq_file *seq,= struct sock *sp, int i) sk_wmem_alloc_get(sp), sk_rmem_alloc_get(sp), 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -73620,10 +75227,11 @@ diff -urNp linux-3.1.4/net/ipv4/raw.c linux-3.1= .4/net/ipv4/raw.c } =20 static int raw_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.1.4/net/ipv4/route.c linux-3.1.4/net/ipv4/route.c ---- linux-3.1.4/net/ipv4/route.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/route.c 2011-11-16 18:39:08.000000000 -0500 -@@ -308,7 +308,7 @@ static inline unsigned int rt_hash(__be3 +diff --git a/net/ipv4/route.c b/net/ipv4/route.c +index 075212e..8713a00 100644 +--- a/net/ipv4/route.c ++++ b/net/ipv4/route.c +@@ -308,7 +308,7 @@ static inline unsigned int rt_hash(__be32 daddr, __b= e32 saddr, int idx, =20 static inline int rt_genid(struct net *net) { @@ -73632,7 +75240,7 @@ diff -urNp linux-3.1.4/net/ipv4/route.c linux-3.1= .4/net/ipv4/route.c } =20 #ifdef CONFIG_PROC_FS -@@ -837,7 +837,7 @@ static void rt_cache_invalidate(struct n +@@ -837,7 +837,7 @@ static void rt_cache_invalidate(struct net *net) unsigned char shuffle; =20 get_random_bytes(&shuffle, sizeof(shuffle)); @@ -73650,10 +75258,11 @@ diff -urNp linux-3.1.4/net/ipv4/route.c linux-3= .1.4/net/ipv4/route.c if (peer->tcp_ts_stamp) { ts =3D peer->tcp_ts; tsage =3D get_seconds() - peer->tcp_ts_stamp; -diff -urNp linux-3.1.4/net/ipv4/tcp.c linux-3.1.4/net/ipv4/tcp.c ---- linux-3.1.4/net/ipv4/tcp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/tcp.c 2011-11-16 18:40:44.000000000 -0500 -@@ -2122,6 +2122,8 @@ static int do_tcp_setsockopt(struct sock +diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c +index 46febca..98b73a4 100644 +--- a/net/ipv4/tcp.c ++++ b/net/ipv4/tcp.c +@@ -2122,6 +2122,8 @@ static int do_tcp_setsockopt(struct sock *sk, int = level, int val; int err =3D 0; =20 @@ -73662,7 +75271,7 @@ diff -urNp linux-3.1.4/net/ipv4/tcp.c linux-3.1.4= /net/ipv4/tcp.c /* These are data/string values, all the others are ints */ switch (optname) { case TCP_CONGESTION: { -@@ -2501,6 +2503,8 @@ static int do_tcp_getsockopt(struct sock +@@ -2501,6 +2503,8 @@ static int do_tcp_getsockopt(struct sock *sk, int = level, struct tcp_sock *tp =3D tcp_sk(sk); int val, len; =20 @@ -73671,9 +75280,10 @@ diff -urNp linux-3.1.4/net/ipv4/tcp.c linux-3.1.= 4/net/ipv4/tcp.c if (get_user(len, optlen)) return -EFAULT; =20 -diff -urNp linux-3.1.4/net/ipv4/tcp_ipv4.c linux-3.1.4/net/ipv4/tcp_ipv4= .c ---- linux-3.1.4/net/ipv4/tcp_ipv4.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/tcp_ipv4.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c +index 7963e03..c44f5d0 100644 +--- a/net/ipv4/tcp_ipv4.c ++++ b/net/ipv4/tcp_ipv4.c @@ -87,6 +87,9 @@ int sysctl_tcp_tw_reuse __read_mostly; int sysctl_tcp_low_latency __read_mostly; EXPORT_SYMBOL(sysctl_tcp_low_latency); @@ -73684,7 +75294,7 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_ipv4.c linux-= 3.1.4/net/ipv4/tcp_ipv4.c =20 #ifdef CONFIG_TCP_MD5SIG static struct tcp_md5sig_key *tcp_v4_md5_do_lookup(struct sock *sk, -@@ -1622,6 +1625,9 @@ int tcp_v4_do_rcv(struct sock *sk, struc +@@ -1622,6 +1625,9 @@ int tcp_v4_do_rcv(struct sock *sk, struct sk_buff = *skb) return 0; =20 reset: @@ -73728,7 +75338,7 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_ipv4.c linux-= 3.1.4/net/ipv4/tcp_ipv4.c tcp_v4_send_reset(NULL, skb); } =20 -@@ -2403,7 +2420,11 @@ static void get_openreq4(struct sock *sk +@@ -2403,7 +2420,11 @@ static void get_openreq4(struct sock *sk, struct = request_sock *req, 0, /* non standard timer */ 0, /* open_requests have no inode */ atomic_read(&sk->sk_refcnt), @@ -73740,7 +75350,7 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_ipv4.c linux-= 3.1.4/net/ipv4/tcp_ipv4.c len); } =20 -@@ -2453,7 +2474,12 @@ static void get_tcp4_sock(struct sock *s +@@ -2453,7 +2474,12 @@ static void get_tcp4_sock(struct sock *sk, struct= seq_file *f, int i, int *len) sock_i_uid(sk), icsk->icsk_probes_out, sock_i_ino(sk), @@ -73754,7 +75364,7 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_ipv4.c linux-= 3.1.4/net/ipv4/tcp_ipv4.c jiffies_to_clock_t(icsk->icsk_rto), jiffies_to_clock_t(icsk->icsk_ack.ato), (icsk->icsk_ack.quick << 1) | icsk->icsk_ack.pingpong, -@@ -2481,7 +2507,13 @@ static void get_timewait4_sock(struct in +@@ -2481,7 +2507,13 @@ static void get_timewait4_sock(struct inet_timewa= it_sock *tw, " %02X %08X:%08X %02X:%08lX %08X %5d %8d %d %d %pK%n", i, src, srcp, dest, destp, tw->tw_substate, 0, 0, 3, jiffies_to_clock_t(ttd), 0, 0, 0, 0, @@ -73769,9 +75379,10 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_ipv4.c linux= -3.1.4/net/ipv4/tcp_ipv4.c } =20 #define TMPSZ 150 -diff -urNp linux-3.1.4/net/ipv4/tcp_minisocks.c linux-3.1.4/net/ipv4/tcp= _minisocks.c ---- linux-3.1.4/net/ipv4/tcp_minisocks.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/ipv4/tcp_minisocks.c 2011-11-16 18:40:44.000000000 -= 0500 +diff --git a/net/ipv4/tcp_minisocks.c b/net/ipv4/tcp_minisocks.c +index 0ce3d06..e182e59 100644 +--- a/net/ipv4/tcp_minisocks.c ++++ b/net/ipv4/tcp_minisocks.c @@ -27,6 +27,10 @@ #include #include @@ -73794,10 +75405,11 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_minisocks.c= linux-3.1.4/net/ipv4/tcp_minisoc if (!(flg & TCP_FLAG_RST)) req->rsk_ops->send_reset(sk, skb); =20 -diff -urNp linux-3.1.4/net/ipv4/tcp_output.c linux-3.1.4/net/ipv4/tcp_ou= tput.c ---- linux-3.1.4/net/ipv4/tcp_output.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/net/ipv4/tcp_output.c 2011-11-16 18:40:44.000000000 -050= 0 -@@ -2421,6 +2421,8 @@ struct sk_buff *tcp_make_synack(struct s +diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c +index 882e0b0..2eba47f 100644 +--- a/net/ipv4/tcp_output.c ++++ b/net/ipv4/tcp_output.c +@@ -2421,6 +2421,8 @@ struct sk_buff *tcp_make_synack(struct sock *sk, s= truct dst_entry *dst, int mss; int s_data_desired =3D 0; =20 @@ -73806,10 +75418,11 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_output.c li= nux-3.1.4/net/ipv4/tcp_output.c if (cvp !=3D NULL && cvp->s_data_constant && cvp->s_data_desired) s_data_desired =3D cvp->s_data_desired; skb =3D sock_wmalloc(sk, MAX_TCP_HEADER + 15 + s_data_desired, 1, GFP_= ATOMIC); -diff -urNp linux-3.1.4/net/ipv4/tcp_probe.c linux-3.1.4/net/ipv4/tcp_pro= be.c ---- linux-3.1.4/net/ipv4/tcp_probe.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/tcp_probe.c 2011-11-16 18:39:08.000000000 -0500 -@@ -202,7 +202,7 @@ static ssize_t tcpprobe_read(struct file +diff --git a/net/ipv4/tcp_probe.c b/net/ipv4/tcp_probe.c +index 85ee7eb..53277ab 100644 +--- a/net/ipv4/tcp_probe.c ++++ b/net/ipv4/tcp_probe.c +@@ -202,7 +202,7 @@ static ssize_t tcpprobe_read(struct file *file, char= __user *buf, if (cnt + width >=3D len) break; =20 @@ -73818,9 +75431,10 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_probe.c linu= x-3.1.4/net/ipv4/tcp_probe.c return -EFAULT; cnt +=3D width; } -diff -urNp linux-3.1.4/net/ipv4/tcp_timer.c linux-3.1.4/net/ipv4/tcp_tim= er.c ---- linux-3.1.4/net/ipv4/tcp_timer.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/tcp_timer.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/net/ipv4/tcp_timer.c b/net/ipv4/tcp_timer.c +index ecd44b0..b32fba6 100644 +--- a/net/ipv4/tcp_timer.c ++++ b/net/ipv4/tcp_timer.c @@ -22,6 +22,10 @@ #include #include @@ -73832,7 +75446,7 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_timer.c linux= -3.1.4/net/ipv4/tcp_timer.c int sysctl_tcp_syn_retries __read_mostly =3D TCP_SYN_RETRIES; int sysctl_tcp_synack_retries __read_mostly =3D TCP_SYNACK_RETRIES; int sysctl_tcp_keepalive_time __read_mostly =3D TCP_KEEPALIVE_TIME; -@@ -199,6 +203,13 @@ static int tcp_write_timeout(struct sock +@@ -199,6 +203,13 @@ static int tcp_write_timeout(struct sock *sk) } } =20 @@ -73846,9 +75460,10 @@ diff -urNp linux-3.1.4/net/ipv4/tcp_timer.c linu= x-3.1.4/net/ipv4/tcp_timer.c if (retransmits_timed_out(sk, retry_until, syn_set ? 0 : icsk->icsk_user_timeout, syn_set)) { /* Has it gone just too far? */ -diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1.4/net/ipv4/udp.c ---- linux-3.1.4/net/ipv4/udp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv4/udp.c 2011-11-16 19:17:54.000000000 -0500 +diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c +index 1b5a193..bd354b0 100644 +--- a/net/ipv4/udp.c ++++ b/net/ipv4/udp.c @@ -86,6 +86,7 @@ #include #include @@ -73878,7 +75493,7 @@ diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1.4= /net/ipv4/udp.c /* * This routine is called by the ICMP module when it gets some * sort of error condition. If err < 0 then the socket should -@@ -856,9 +864,18 @@ int udp_sendmsg(struct kiocb *iocb, stru +@@ -856,9 +864,18 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk= , struct msghdr *msg, dport =3D usin->sin_port; if (dport =3D=3D 0) return -EINVAL; @@ -73897,7 +75512,7 @@ diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1.4= /net/ipv4/udp.c daddr =3D inet->inet_daddr; dport =3D inet->inet_dport; /* Open fast path for connected socket. -@@ -1099,7 +1116,7 @@ static unsigned int first_packet_length( +@@ -1099,7 +1116,7 @@ static unsigned int first_packet_length(struct soc= k *sk) udp_lib_checksum_complete(skb)) { UDP_INC_STATS_BH(sock_net(sk), UDP_MIB_INERRORS, IS_UDPLITE(sk)); @@ -73917,7 +75532,7 @@ diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1.4= /net/ipv4/udp.c ulen =3D skb->len - sizeof(struct udphdr); if (len > ulen) len =3D ulen; -@@ -1485,7 +1506,7 @@ int udp_queue_rcv_skb(struct sock *sk, s +@@ -1485,7 +1506,7 @@ int udp_queue_rcv_skb(struct sock *sk, struct sk_b= uff *skb) =20 drop: UDP_INC_STATS_BH(sock_net(sk), UDP_MIB_INERRORS, is_udplite); @@ -73926,7 +75541,7 @@ diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1.4= /net/ipv4/udp.c kfree_skb(skb); return -1; } -@@ -1504,7 +1525,7 @@ static void flush_stack(struct sock **st +@@ -1504,7 +1525,7 @@ static void flush_stack(struct sock **stack, unsig= ned int count, skb1 =3D (i =3D=3D final) ? skb : skb_clone(skb, GFP_ATOMIC); =20 if (!skb1) { @@ -73935,7 +75550,7 @@ diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1.4= /net/ipv4/udp.c UDP_INC_STATS_BH(sock_net(sk), UDP_MIB_RCVBUFERRORS, IS_UDPLITE(sk)); UDP_INC_STATS_BH(sock_net(sk), UDP_MIB_INERRORS, -@@ -1673,6 +1694,9 @@ int __udp4_lib_rcv(struct sk_buff *skb,=20 +@@ -1673,6 +1694,9 @@ int __udp4_lib_rcv(struct sk_buff *skb, struct udp= _table *udptable, goto csum_error; =20 UDP_INC_STATS_BH(net, UDP_MIB_NOPORTS, proto =3D=3D IPPROTO_UDPLITE); @@ -73945,7 +75560,7 @@ diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1.4= /net/ipv4/udp.c icmp_send(skb, ICMP_DEST_UNREACH, ICMP_PORT_UNREACH, 0); =20 /* -@@ -2100,8 +2124,13 @@ static void udp4_format_sock(struct sock +@@ -2100,8 +2124,13 @@ static void udp4_format_sock(struct sock *sp, str= uct seq_file *f, sk_wmem_alloc_get(sp), sk_rmem_alloc_get(sp), 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -73961,10 +75576,11 @@ diff -urNp linux-3.1.4/net/ipv4/udp.c linux-3.1= .4/net/ipv4/udp.c } =20 int udp4_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.1.4/net/ipv6/addrconf.c linux-3.1.4/net/ipv6/addrconf= .c ---- linux-3.1.4/net/ipv6/addrconf.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv6/addrconf.c 2011-11-16 18:39:08.000000000 -0500 -@@ -2083,7 +2083,7 @@ int addrconf_set_dstaddr(struct net *net +diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c +index 12368c5..fbf899f 100644 +--- a/net/ipv6/addrconf.c ++++ b/net/ipv6/addrconf.c +@@ -2083,7 +2083,7 @@ int addrconf_set_dstaddr(struct net *net, void __u= ser *arg) p.iph.ihl =3D 5; p.iph.protocol =3D IPPROTO_IPV6; p.iph.ttl =3D 64; @@ -73973,10 +75589,11 @@ diff -urNp linux-3.1.4/net/ipv6/addrconf.c linu= x-3.1.4/net/ipv6/addrconf.c =20 if (ops->ndo_do_ioctl) { mm_segment_t oldfs =3D get_fs(); -diff -urNp linux-3.1.4/net/ipv6/inet6_connection_sock.c linux-3.1.4/net/= ipv6/inet6_connection_sock.c ---- linux-3.1.4/net/ipv6/inet6_connection_sock.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/net/ipv6/inet6_connection_sock.c 2011-11-16 18:39:08.000= 000000 -0500 -@@ -178,7 +178,7 @@ void __inet6_csk_dst_store(struct sock * +diff --git a/net/ipv6/inet6_connection_sock.c b/net/ipv6/inet6_connectio= n_sock.c +index 8a58e8c..8b5e631 100644 +--- a/net/ipv6/inet6_connection_sock.c ++++ b/net/ipv6/inet6_connection_sock.c +@@ -178,7 +178,7 @@ void __inet6_csk_dst_store(struct sock *sk, struct d= st_entry *dst, #ifdef CONFIG_XFRM { struct rt6_info *rt =3D (struct rt6_info *)dst; @@ -73985,7 +75602,7 @@ diff -urNp linux-3.1.4/net/ipv6/inet6_connection_= sock.c linux-3.1.4/net/ipv6/ine } #endif } -@@ -193,7 +193,7 @@ struct dst_entry *__inet6_csk_dst_check( +@@ -193,7 +193,7 @@ struct dst_entry *__inet6_csk_dst_check(struct sock = *sk, u32 cookie) #ifdef CONFIG_XFRM if (dst) { struct rt6_info *rt =3D (struct rt6_info *)dst; @@ -73994,10 +75611,11 @@ diff -urNp linux-3.1.4/net/ipv6/inet6_connectio= n_sock.c linux-3.1.4/net/ipv6/ine __sk_dst_reset(sk); dst =3D NULL; } -diff -urNp linux-3.1.4/net/ipv6/ipv6_sockglue.c linux-3.1.4/net/ipv6/ipv= 6_sockglue.c ---- linux-3.1.4/net/ipv6/ipv6_sockglue.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/ipv6/ipv6_sockglue.c 2011-11-16 18:40:44.000000000 -= 0500 -@@ -129,6 +129,8 @@ static int do_ipv6_setsockopt(struct soc +diff --git a/net/ipv6/ipv6_sockglue.c b/net/ipv6/ipv6_sockglue.c +index 2fbda5f..26ed683 100644 +--- a/net/ipv6/ipv6_sockglue.c ++++ b/net/ipv6/ipv6_sockglue.c +@@ -129,6 +129,8 @@ static int do_ipv6_setsockopt(struct sock *sk, int l= evel, int optname, int val, valbool; int retv =3D -ENOPROTOOPT; =20 @@ -74006,7 +75624,7 @@ diff -urNp linux-3.1.4/net/ipv6/ipv6_sockglue.c l= inux-3.1.4/net/ipv6/ipv6_sockgl if (optval =3D=3D NULL) val=3D0; else { -@@ -919,6 +921,8 @@ static int do_ipv6_getsockopt(struct soc +@@ -919,6 +921,8 @@ static int do_ipv6_getsockopt(struct sock *sk, int l= evel, int optname, int len; int val; =20 @@ -74015,7 +75633,7 @@ diff -urNp linux-3.1.4/net/ipv6/ipv6_sockglue.c l= inux-3.1.4/net/ipv6/ipv6_sockgl if (ip6_mroute_opt(optname)) return ip6_mroute_getsockopt(sk, optname, optval, optlen); =20 -@@ -960,7 +964,7 @@ static int do_ipv6_getsockopt(struct soc +@@ -960,7 +964,7 @@ static int do_ipv6_getsockopt(struct sock *sk, int l= evel, int optname, if (sk->sk_type !=3D SOCK_STREAM) return -ENOPROTOOPT; =20 @@ -74024,10 +75642,11 @@ diff -urNp linux-3.1.4/net/ipv6/ipv6_sockglue.c= linux-3.1.4/net/ipv6/ipv6_sockgl msg.msg_controllen =3D len; msg.msg_flags =3D flags; =20 -diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1.4/net/ipv6/raw.c ---- linux-3.1.4/net/ipv6/raw.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv6/raw.c 2011-11-16 18:40:44.000000000 -0500 -@@ -376,7 +376,7 @@ static inline int rawv6_rcv_skb(struct s +diff --git a/net/ipv6/raw.c b/net/ipv6/raw.c +index 343852e..c92bd15 100644 +--- a/net/ipv6/raw.c ++++ b/net/ipv6/raw.c +@@ -376,7 +376,7 @@ static inline int rawv6_rcv_skb(struct sock * sk, st= ruct sk_buff * skb) { if ((raw6_sk(sk)->checksum || rcu_dereference_raw(sk->sk_filter)) && skb_checksum_complete(skb)) { @@ -74036,7 +75655,7 @@ diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1.4= /net/ipv6/raw.c kfree_skb(skb); return NET_RX_DROP; } -@@ -403,7 +403,7 @@ int rawv6_rcv(struct sock *sk, struct sk +@@ -403,7 +403,7 @@ int rawv6_rcv(struct sock *sk, struct sk_buff *skb) struct raw6_sock *rp =3D raw6_sk(sk); =20 if (!xfrm6_policy_check(sk, XFRM_POLICY_IN, skb)) { @@ -74045,7 +75664,7 @@ diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1.4= /net/ipv6/raw.c kfree_skb(skb); return NET_RX_DROP; } -@@ -427,7 +427,7 @@ int rawv6_rcv(struct sock *sk, struct sk +@@ -427,7 +427,7 @@ int rawv6_rcv(struct sock *sk, struct sk_buff *skb) =20 if (inet->hdrincl) { if (skb_checksum_complete(skb)) { @@ -74063,7 +75682,7 @@ diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1.4= /net/ipv6/raw.c struct flowi6 *fl6, struct dst_entry **dstp, unsigned int flags) { -@@ -742,6 +742,8 @@ static int rawv6_sendmsg(struct kiocb *i +@@ -742,6 +742,8 @@ static int rawv6_sendmsg(struct kiocb *iocb, struct = sock *sk, u16 proto; int err; =20 @@ -74089,7 +75708,7 @@ diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1.4= /net/ipv6/raw.c return 0; default: return -ENOPROTOOPT; -@@ -927,6 +932,7 @@ static int rawv6_geticmpfilter(struct so +@@ -927,6 +932,7 @@ static int rawv6_geticmpfilter(struct sock *sk, int = level, int optname, char __user *optval, int __user *optlen) { int len; @@ -74097,7 +75716,7 @@ diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1.4= /net/ipv6/raw.c =20 switch (optname) { case ICMPV6_FILTER: -@@ -938,7 +944,8 @@ static int rawv6_geticmpfilter(struct so +@@ -938,7 +944,8 @@ static int rawv6_geticmpfilter(struct sock *sk, int = level, int optname, len =3D sizeof(struct icmp6_filter); if (put_user(len, optlen)) return -EFAULT; @@ -74107,7 +75726,7 @@ diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1.4= /net/ipv6/raw.c return -EFAULT; return 0; default: -@@ -1245,7 +1252,13 @@ static void raw6_sock_seq_show(struct se +@@ -1245,7 +1252,13 @@ static void raw6_sock_seq_show(struct seq_file *s= eq, struct sock *sp, int i) 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -74122,10 +75741,11 @@ diff -urNp linux-3.1.4/net/ipv6/raw.c linux-3.1= .4/net/ipv6/raw.c } =20 static int raw6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.1.4/net/ipv6/tcp_ipv6.c linux-3.1.4/net/ipv6/tcp_ipv6= .c ---- linux-3.1.4/net/ipv6/tcp_ipv6.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv6/tcp_ipv6.c 2011-11-16 18:40:44.000000000 -0500 -@@ -93,6 +93,10 @@ static struct tcp_md5sig_key *tcp_v6_md5 +diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c +index 7b8fc57..c6185da 100644 +--- a/net/ipv6/tcp_ipv6.c ++++ b/net/ipv6/tcp_ipv6.c +@@ -93,6 +93,10 @@ static struct tcp_md5sig_key *tcp_v6_md5_do_lookup(st= ruct sock *sk, } #endif =20 @@ -74136,7 +75756,7 @@ diff -urNp linux-3.1.4/net/ipv6/tcp_ipv6.c linux-= 3.1.4/net/ipv6/tcp_ipv6.c static void tcp_v6_hash(struct sock *sk) { if (sk->sk_state !=3D TCP_CLOSE) { -@@ -1647,6 +1651,9 @@ static int tcp_v6_do_rcv(struct sock *sk +@@ -1647,6 +1651,9 @@ static int tcp_v6_do_rcv(struct sock *sk, struct s= k_buff *skb) return 0; =20 reset: @@ -74146,7 +75766,7 @@ diff -urNp linux-3.1.4/net/ipv6/tcp_ipv6.c linux-= 3.1.4/net/ipv6/tcp_ipv6.c tcp_v6_send_reset(sk, skb); discard: if (opt_skb) -@@ -1726,12 +1733,20 @@ static int tcp_v6_rcv(struct sk_buff *sk +@@ -1726,12 +1733,20 @@ static int tcp_v6_rcv(struct sk_buff *skb) TCP_SKB_CB(skb)->sacked =3D 0; =20 sk =3D __inet6_lookup_skb(&tcp_hashinfo, skb, th->source, th->dest); @@ -74180,7 +75800,7 @@ diff -urNp linux-3.1.4/net/ipv6/tcp_ipv6.c linux-= 3.1.4/net/ipv6/tcp_ipv6.c tcp_v6_send_reset(NULL, skb); } =20 -@@ -2039,7 +2058,13 @@ static void get_openreq6(struct seq_file +@@ -2039,7 +2058,13 @@ static void get_openreq6(struct seq_file *seq, uid, 0, /* non standard timer */ 0, /* open_requests have no inode */ @@ -74195,7 +75815,7 @@ diff -urNp linux-3.1.4/net/ipv6/tcp_ipv6.c linux-= 3.1.4/net/ipv6/tcp_ipv6.c } =20 static void get_tcp6_sock(struct seq_file *seq, struct sock *sp, int i) -@@ -2089,7 +2114,12 @@ static void get_tcp6_sock(struct seq_fil +@@ -2089,7 +2114,12 @@ static void get_tcp6_sock(struct seq_file *seq, s= truct sock *sp, int i) sock_i_uid(sp), icsk->icsk_probes_out, sock_i_ino(sp), @@ -74209,7 +75829,7 @@ diff -urNp linux-3.1.4/net/ipv6/tcp_ipv6.c linux-= 3.1.4/net/ipv6/tcp_ipv6.c jiffies_to_clock_t(icsk->icsk_rto), jiffies_to_clock_t(icsk->icsk_ack.ato), (icsk->icsk_ack.quick << 1 ) | icsk->icsk_ack.pingpong, -@@ -2124,7 +2154,13 @@ static void get_timewait6_sock(struct se +@@ -2124,7 +2154,13 @@ static void get_timewait6_sock(struct seq_file *s= eq, dest->s6_addr32[2], dest->s6_addr32[3], destp, tw->tw_substate, 0, 0, 3, jiffies_to_clock_t(ttd), 0, 0, 0, 0, @@ -74224,9 +75844,10 @@ diff -urNp linux-3.1.4/net/ipv6/tcp_ipv6.c linux= -3.1.4/net/ipv6/tcp_ipv6.c } =20 static int tcp6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.1.4/net/ipv6/udp.c linux-3.1.4/net/ipv6/udp.c ---- linux-3.1.4/net/ipv6/udp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/ipv6/udp.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c +index bb95e8e..ae0ee80 100644 +--- a/net/ipv6/udp.c ++++ b/net/ipv6/udp.c @@ -50,6 +50,10 @@ #include #include "udp_impl.h" @@ -74238,7 +75859,7 @@ diff -urNp linux-3.1.4/net/ipv6/udp.c linux-3.1.4= /net/ipv6/udp.c int ipv6_rcv_saddr_equal(const struct sock *sk, const struct sock *sk2) { const struct in6_addr *sk_rcv_saddr6 =3D &inet6_sk(sk)->rcv_saddr; -@@ -548,7 +552,7 @@ int udpv6_queue_rcv_skb(struct sock * sk +@@ -548,7 +552,7 @@ int udpv6_queue_rcv_skb(struct sock * sk, struct sk_= buff *skb) =20 return 0; drop: @@ -74247,7 +75868,7 @@ diff -urNp linux-3.1.4/net/ipv6/udp.c linux-3.1.4= /net/ipv6/udp.c drop_no_sk_drops_inc: UDP6_INC_STATS_BH(sock_net(sk), UDP_MIB_INERRORS, is_udplite); kfree_skb(skb); -@@ -624,7 +628,7 @@ static void flush_stack(struct sock **st +@@ -624,7 +628,7 @@ static void flush_stack(struct sock **stack, unsigne= d int count, continue; } drop: @@ -74256,7 +75877,7 @@ diff -urNp linux-3.1.4/net/ipv6/udp.c linux-3.1.4= /net/ipv6/udp.c UDP6_INC_STATS_BH(sock_net(sk), UDP_MIB_RCVBUFERRORS, IS_UDPLITE(sk)); UDP6_INC_STATS_BH(sock_net(sk), -@@ -779,6 +783,9 @@ int __udp6_lib_rcv(struct sk_buff *skb,=20 +@@ -779,6 +783,9 @@ int __udp6_lib_rcv(struct sk_buff *skb, struct udp_t= able *udptable, UDP6_INC_STATS_BH(net, UDP_MIB_NOPORTS, proto =3D=3D IPPROTO_UDPLITE); =20 @@ -74266,7 +75887,7 @@ diff -urNp linux-3.1.4/net/ipv6/udp.c linux-3.1.4= /net/ipv6/udp.c icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_PORT_UNREACH, 0); =20 kfree_skb(skb); -@@ -795,7 +802,7 @@ int __udp6_lib_rcv(struct sk_buff *skb,=20 +@@ -795,7 +802,7 @@ int __udp6_lib_rcv(struct sk_buff *skb, struct udp_t= able *udptable, if (!sock_owned_by_user(sk)) udpv6_queue_rcv_skb(sk, skb); else if (sk_add_backlog(sk, skb)) { @@ -74275,7 +75896,7 @@ diff -urNp linux-3.1.4/net/ipv6/udp.c linux-3.1.4= /net/ipv6/udp.c bh_unlock_sock(sk); sock_put(sk); goto discard; -@@ -1406,8 +1413,13 @@ static void udp6_sock_seq_show(struct se +@@ -1406,8 +1413,13 @@ static void udp6_sock_seq_show(struct seq_file *s= eq, struct sock *sp, int bucket 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -74291,10 +75912,11 @@ diff -urNp linux-3.1.4/net/ipv6/udp.c linux-3.1= .4/net/ipv6/udp.c } =20 int udp6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty.c linux-3.1.4/net/irda= /ircomm/ircomm_tty.c ---- linux-3.1.4/net/irda/ircomm/ircomm_tty.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/net/irda/ircomm/ircomm_tty.c 2011-11-16 18:39:08.0000000= 00 -0500 -@@ -282,16 +282,16 @@ static int ircomm_tty_block_til_ready(st +diff --git a/net/irda/ircomm/ircomm_tty.c b/net/irda/ircomm/ircomm_tty.c +index b3cc8b3..baa02d0 100644 +--- a/net/irda/ircomm/ircomm_tty.c ++++ b/net/irda/ircomm/ircomm_tty.c +@@ -282,16 +282,16 @@ static int ircomm_tty_block_til_ready(struct ircom= m_tty_cb *self, add_wait_queue(&self->open_wait, &wait); =20 IRDA_DEBUG(2, "%s(%d):block_til_ready before block on %s open_count=3D= %d\n", @@ -74314,7 +75936,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ =20 while (1) { if (tty->termios->c_cflag & CBAUD) { -@@ -331,7 +331,7 @@ static int ircomm_tty_block_til_ready(st +@@ -331,7 +331,7 @@ static int ircomm_tty_block_til_ready(struct ircomm_= tty_cb *self, } =20 IRDA_DEBUG(1, "%s(%d):block_til_ready blocking on %s open_count=3D%d\= n", @@ -74323,7 +75945,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ =20 schedule(); } -@@ -342,13 +342,13 @@ static int ircomm_tty_block_til_ready(st +@@ -342,13 +342,13 @@ static int ircomm_tty_block_til_ready(struct ircom= m_tty_cb *self, if (extra_count) { /* ++ is not atomic, so this should be protected - Jean II */ spin_lock_irqsave(&self->spinlock, flags); @@ -74340,7 +75962,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ =20 if (!retval) self->flags |=3D ASYNC_NORMAL_ACTIVE; -@@ -417,14 +417,14 @@ static int ircomm_tty_open(struct tty_st +@@ -417,14 +417,14 @@ static int ircomm_tty_open(struct tty_struct *tty,= struct file *filp) } /* ++ is not atomic, so this should be protected - Jean II */ spin_lock_irqsave(&self->spinlock, flags); @@ -74357,7 +75979,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ =20 /* Not really used by us, but lets do it anyway */ self->tty->low_latency =3D (self->flags & ASYNC_LOW_LATENCY) ? 1 : 0; -@@ -510,7 +510,7 @@ static void ircomm_tty_close(struct tty_ +@@ -510,7 +510,7 @@ static void ircomm_tty_close(struct tty_struct *tty,= struct file *filp) return; } =20 @@ -74366,7 +75988,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ /* * Uh, oh. tty->count is 1, which means that the tty * structure will be freed. state->count should always -@@ -520,16 +520,16 @@ static void ircomm_tty_close(struct tty_ +@@ -520,16 +520,16 @@ static void ircomm_tty_close(struct tty_struct *tt= y, struct file *filp) */ IRDA_DEBUG(0, "%s(), bad serial port count; " "tty->count is 1, state->count is %d\n", __func__ , @@ -74389,7 +76011,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ spin_unlock_irqrestore(&self->spinlock, flags); =20 IRDA_DEBUG(0, "%s(), open count > 0\n", __func__ ); -@@ -561,7 +561,7 @@ static void ircomm_tty_close(struct tty_ +@@ -561,7 +561,7 @@ static void ircomm_tty_close(struct tty_struct *tty,= struct file *filp) tty->closing =3D 0; self->tty =3D NULL; =20 @@ -74398,7 +76020,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ if (self->close_delay) schedule_timeout_interruptible(self->close_delay); wake_up_interruptible(&self->open_wait); -@@ -1013,7 +1013,7 @@ static void ircomm_tty_hangup(struct tty +@@ -1013,7 +1013,7 @@ static void ircomm_tty_hangup(struct tty_struct *t= ty) spin_lock_irqsave(&self->spinlock, flags); self->flags &=3D ~ASYNC_NORMAL_ACTIVE; self->tty =3D NULL; @@ -74407,7 +76029,7 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_tty= .c linux-3.1.4/net/irda/ircomm/ spin_unlock_irqrestore(&self->spinlock, flags); =20 wake_up_interruptible(&self->open_wait); -@@ -1360,7 +1360,7 @@ static void ircomm_tty_line_info(struct=20 +@@ -1360,7 +1360,7 @@ static void ircomm_tty_line_info(struct ircomm_tty= _cb *self, struct seq_file *m) seq_putc(m, '\n'); =20 seq_printf(m, "Role: %s\n", self->client ? "client" : "server"); @@ -74416,10 +76038,11 @@ diff -urNp linux-3.1.4/net/irda/ircomm/ircomm_t= ty.c linux-3.1.4/net/irda/ircomm/ seq_printf(m, "Max data size: %d\n", self->max_data_size); seq_printf(m, "Max header size: %d\n", self->max_header_size); =20 -diff -urNp linux-3.1.4/net/iucv/af_iucv.c linux-3.1.4/net/iucv/af_iucv.c ---- linux-3.1.4/net/iucv/af_iucv.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/iucv/af_iucv.c 2011-11-16 18:39:08.000000000 -0500 -@@ -648,10 +648,10 @@ static int iucv_sock_autobind(struct soc +diff --git a/net/iucv/af_iucv.c b/net/iucv/af_iucv.c +index e2013e4..edfc1e3 100644 +--- a/net/iucv/af_iucv.c ++++ b/net/iucv/af_iucv.c +@@ -648,10 +648,10 @@ static int iucv_sock_autobind(struct sock *sk) =20 write_lock_bh(&iucv_sk_list.lock); =20 @@ -74432,10 +76055,11 @@ diff -urNp linux-3.1.4/net/iucv/af_iucv.c linux= -3.1.4/net/iucv/af_iucv.c } =20 write_unlock_bh(&iucv_sk_list.lock); -diff -urNp linux-3.1.4/net/key/af_key.c linux-3.1.4/net/key/af_key.c ---- linux-3.1.4/net/key/af_key.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/key/af_key.c 2011-11-16 18:40:44.000000000 -0500 -@@ -2481,6 +2481,8 @@ static int pfkey_migrate(struct sock *sk +diff --git a/net/key/af_key.c b/net/key/af_key.c +index 1e733e9..c84de2f 100644 +--- a/net/key/af_key.c ++++ b/net/key/af_key.c +@@ -2481,6 +2481,8 @@ static int pfkey_migrate(struct sock *sk, struct s= k_buff *skb, struct xfrm_migrate m[XFRM_MAX_DEPTH]; struct xfrm_kmaddress k; =20 @@ -74444,7 +76068,7 @@ diff -urNp linux-3.1.4/net/key/af_key.c linux-3.1= .4/net/key/af_key.c if (!present_and_same_family(ext_hdrs[SADB_EXT_ADDRESS_SRC - 1], ext_hdrs[SADB_EXT_ADDRESS_DST - 1]) || !ext_hdrs[SADB_X_EXT_POLICY - 1]) { -@@ -3016,10 +3018,10 @@ static int pfkey_send_policy_notify(stru +@@ -3016,10 +3018,10 @@ static int pfkey_send_policy_notify(struct xfrm_= policy *xp, int dir, const struc static u32 get_acqseq(void) { u32 res; @@ -74457,10 +76081,11 @@ diff -urNp linux-3.1.4/net/key/af_key.c linux-3= .1.4/net/key/af_key.c } while (!res); return res; } -diff -urNp linux-3.1.4/net/lapb/lapb_iface.c linux-3.1.4/net/lapb/lapb_i= face.c ---- linux-3.1.4/net/lapb/lapb_iface.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/net/lapb/lapb_iface.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -158,7 +158,7 @@ int lapb_register(struct net_device *dev +diff --git a/net/lapb/lapb_iface.c b/net/lapb/lapb_iface.c +index 956b7e4..f01d328 100644 +--- a/net/lapb/lapb_iface.c ++++ b/net/lapb/lapb_iface.c +@@ -158,7 +158,7 @@ int lapb_register(struct net_device *dev, struct lap= b_register_struct *callbacks goto out; =20 lapb->dev =3D dev; @@ -74469,7 +76094,7 @@ diff -urNp linux-3.1.4/net/lapb/lapb_iface.c linu= x-3.1.4/net/lapb/lapb_iface.c =20 __lapb_insert_cb(lapb); =20 -@@ -380,32 +380,32 @@ int lapb_data_received(struct net_device +@@ -380,32 +380,32 @@ int lapb_data_received(struct net_device *dev, str= uct sk_buff *skb) =20 void lapb_connect_confirmation(struct lapb_cb *lapb, int reason) { @@ -74512,7 +76137,7 @@ diff -urNp linux-3.1.4/net/lapb/lapb_iface.c linu= x-3.1.4/net/lapb/lapb_iface.c =20 kfree_skb(skb); return NET_RX_SUCCESS; /* For now; must be !=3D NET_RX_DROP */ -@@ -415,8 +415,8 @@ int lapb_data_transmit(struct lapb_cb *l +@@ -415,8 +415,8 @@ int lapb_data_transmit(struct lapb_cb *lapb, struct = sk_buff *skb) { int used =3D 0; =20 @@ -74523,10 +76148,11 @@ diff -urNp linux-3.1.4/net/lapb/lapb_iface.c li= nux-3.1.4/net/lapb/lapb_iface.c used =3D 1; } =20 -diff -urNp linux-3.1.4/net/mac80211/debugfs_sta.c linux-3.1.4/net/mac802= 11/debugfs_sta.c ---- linux-3.1.4/net/mac80211/debugfs_sta.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/net/mac80211/debugfs_sta.c 2011-11-16 18:40:44.000000000= -0500 -@@ -140,6 +140,8 @@ static ssize_t sta_agg_status_read(struc +diff --git a/net/mac80211/debugfs_sta.c b/net/mac80211/debugfs_sta.c +index a01d213..6a1f1ab 100644 +--- a/net/mac80211/debugfs_sta.c ++++ b/net/mac80211/debugfs_sta.c +@@ -140,6 +140,8 @@ static ssize_t sta_agg_status_read(struct file *file= , char __user *userbuf, struct tid_ampdu_rx *tid_rx; struct tid_ampdu_tx *tid_tx; =20 @@ -74535,7 +76161,7 @@ diff -urNp linux-3.1.4/net/mac80211/debugfs_sta.c= linux-3.1.4/net/mac80211/debug rcu_read_lock(); =20 p +=3D scnprintf(p, sizeof(buf) + buf - p, "next dialog_token: %#02x\n= ", -@@ -240,6 +242,8 @@ static ssize_t sta_ht_capa_read(struct f +@@ -240,6 +242,8 @@ static ssize_t sta_ht_capa_read(struct file *file, c= har __user *userbuf, struct sta_info *sta =3D file->private_data; struct ieee80211_sta_ht_cap *htc =3D &sta->sta.ht_cap; =20 @@ -74544,9 +76170,10 @@ diff -urNp linux-3.1.4/net/mac80211/debugfs_sta.= c linux-3.1.4/net/mac80211/debug p +=3D scnprintf(p, sizeof(buf) + buf - p, "ht %ssupported\n", htc->ht_supported ? "" : "not "); if (htc->ht_supported) { -diff -urNp linux-3.1.4/net/mac80211/ieee80211_i.h linux-3.1.4/net/mac802= 11/ieee80211_i.h ---- linux-3.1.4/net/mac80211/ieee80211_i.h 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/net/mac80211/ieee80211_i.h 2011-11-16 18:39:08.000000000= -0500 +diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h +index 9fab144..7f0fc14 100644 +--- a/net/mac80211/ieee80211_i.h ++++ b/net/mac80211/ieee80211_i.h @@ -27,6 +27,7 @@ #include #include @@ -74564,10 +76191,11 @@ diff -urNp linux-3.1.4/net/mac80211/ieee80211_i= .h linux-3.1.4/net/mac80211/ieee8 int monitors, cooked_mntrs; /* number of interfaces with corresponding FIF_ flags */ int fif_fcsfail, fif_plcpfail, fif_control, fif_other_bss, fif_pspoll, -diff -urNp linux-3.1.4/net/mac80211/iface.c linux-3.1.4/net/mac80211/ifa= ce.c ---- linux-3.1.4/net/mac80211/iface.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/mac80211/iface.c 2011-11-16 18:39:08.000000000 -0500 -@@ -211,7 +211,7 @@ static int ieee80211_do_open(struct net_ +diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c +index 556e7e6..120dcaf 100644 +--- a/net/mac80211/iface.c ++++ b/net/mac80211/iface.c +@@ -211,7 +211,7 @@ static int ieee80211_do_open(struct net_device *dev,= bool coming_up) break; } =20 @@ -74576,7 +76204,7 @@ diff -urNp linux-3.1.4/net/mac80211/iface.c linux= -3.1.4/net/mac80211/iface.c res =3D drv_start(local); if (res) goto err_del_bss; -@@ -235,7 +235,7 @@ static int ieee80211_do_open(struct net_ +@@ -235,7 +235,7 @@ static int ieee80211_do_open(struct net_device *dev,= bool coming_up) memcpy(dev->perm_addr, dev->dev_addr, ETH_ALEN); =20 if (!is_valid_ether_addr(dev->dev_addr)) { @@ -74585,7 +76213,7 @@ diff -urNp linux-3.1.4/net/mac80211/iface.c linux= -3.1.4/net/mac80211/iface.c drv_stop(local); return -EADDRNOTAVAIL; } -@@ -327,7 +327,7 @@ static int ieee80211_do_open(struct net_ +@@ -327,7 +327,7 @@ static int ieee80211_do_open(struct net_device *dev,= bool coming_up) mutex_unlock(&local->mtx); =20 if (coming_up) @@ -74594,7 +76222,7 @@ diff -urNp linux-3.1.4/net/mac80211/iface.c linux= -3.1.4/net/mac80211/iface.c =20 if (hw_reconf_flags) { ieee80211_hw_config(local, hw_reconf_flags); -@@ -347,7 +347,7 @@ static int ieee80211_do_open(struct net_ +@@ -347,7 +347,7 @@ static int ieee80211_do_open(struct net_device *dev,= bool coming_up) err_del_interface: drv_remove_interface(local, &sdata->vif); err_stop: @@ -74603,7 +76231,7 @@ diff -urNp linux-3.1.4/net/mac80211/iface.c linux= -3.1.4/net/mac80211/iface.c drv_stop(local); err_del_bss: sdata->bss =3D NULL; -@@ -474,7 +474,7 @@ static void ieee80211_do_stop(struct iee +@@ -474,7 +474,7 @@ static void ieee80211_do_stop(struct ieee80211_sub_i= f_data *sdata, } =20 if (going_down) @@ -74612,7 +76240,7 @@ diff -urNp linux-3.1.4/net/mac80211/iface.c linux= -3.1.4/net/mac80211/iface.c =20 switch (sdata->vif.type) { case NL80211_IFTYPE_AP_VLAN: -@@ -533,7 +533,7 @@ static void ieee80211_do_stop(struct iee +@@ -533,7 +533,7 @@ static void ieee80211_do_stop(struct ieee80211_sub_i= f_data *sdata, =20 ieee80211_recalc_ps(local, -1); =20 @@ -74621,10 +76249,11 @@ diff -urNp linux-3.1.4/net/mac80211/iface.c lin= ux-3.1.4/net/mac80211/iface.c if (local->ops->napi_poll) napi_disable(&local->napi); ieee80211_clear_tx_pending(local); -diff -urNp linux-3.1.4/net/mac80211/main.c linux-3.1.4/net/mac80211/main= .c ---- linux-3.1.4/net/mac80211/main.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/mac80211/main.c 2011-11-16 18:39:08.000000000 -0500 -@@ -209,7 +209,7 @@ int ieee80211_hw_config(struct ieee80211 +diff --git a/net/mac80211/main.c b/net/mac80211/main.c +index acb4423..278c8e5 100644 +--- a/net/mac80211/main.c ++++ b/net/mac80211/main.c +@@ -209,7 +209,7 @@ int ieee80211_hw_config(struct ieee80211_local *loca= l, u32 changed) local->hw.conf.power_level =3D power; } =20 @@ -74633,10 +76262,11 @@ diff -urNp linux-3.1.4/net/mac80211/main.c linu= x-3.1.4/net/mac80211/main.c ret =3D drv_config(local, changed); /* * Goal: -diff -urNp linux-3.1.4/net/mac80211/mlme.c linux-3.1.4/net/mac80211/mlme= .c ---- linux-3.1.4/net/mac80211/mlme.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/mac80211/mlme.c 2011-11-16 18:40:44.000000000 -0500 -@@ -1464,6 +1464,8 @@ static bool ieee80211_assoc_success(stru +diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c +index 0f48368..d48e688 100644 +--- a/net/mac80211/mlme.c ++++ b/net/mac80211/mlme.c +@@ -1464,6 +1464,8 @@ static bool ieee80211_assoc_success(struct ieee802= 11_work *wk, bool have_higher_than_11mbit =3D false; u16 ap_ht_cap_flags; =20 @@ -74645,10 +76275,11 @@ diff -urNp linux-3.1.4/net/mac80211/mlme.c linu= x-3.1.4/net/mac80211/mlme.c /* AssocResp and ReassocResp have identical structure */ =20 aid =3D le16_to_cpu(mgmt->u.assoc_resp.aid); -diff -urNp linux-3.1.4/net/mac80211/pm.c linux-3.1.4/net/mac80211/pm.c ---- linux-3.1.4/net/mac80211/pm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/mac80211/pm.c 2011-11-16 18:39:08.000000000 -0500 -@@ -34,7 +34,7 @@ int __ieee80211_suspend(struct ieee80211 +diff --git a/net/mac80211/pm.c b/net/mac80211/pm.c +index 6326d34..7225f61 100644 +--- a/net/mac80211/pm.c ++++ b/net/mac80211/pm.c +@@ -34,7 +34,7 @@ int __ieee80211_suspend(struct ieee80211_hw *hw, struc= t cfg80211_wowlan *wowlan) struct ieee80211_sub_if_data *sdata; struct sta_info *sta; =20 @@ -74657,7 +76288,7 @@ diff -urNp linux-3.1.4/net/mac80211/pm.c linux-3.= 1.4/net/mac80211/pm.c goto suspend; =20 ieee80211_scan_cancel(local); -@@ -72,7 +72,7 @@ int __ieee80211_suspend(struct ieee80211 +@@ -72,7 +72,7 @@ int __ieee80211_suspend(struct ieee80211_hw *hw, struc= t cfg80211_wowlan *wowlan) cancel_work_sync(&local->dynamic_ps_enable_work); del_timer_sync(&local->dynamic_ps_timer); =20 @@ -74666,7 +76297,7 @@ diff -urNp linux-3.1.4/net/mac80211/pm.c linux-3.= 1.4/net/mac80211/pm.c if (local->wowlan) { int err =3D drv_suspend(local, wowlan); if (err < 0) { -@@ -129,7 +129,7 @@ int __ieee80211_suspend(struct ieee80211 +@@ -129,7 +129,7 @@ int __ieee80211_suspend(struct ieee80211_hw *hw, str= uct cfg80211_wowlan *wowlan) } =20 /* stop hardware - this must stop RX */ @@ -74675,10 +76306,11 @@ diff -urNp linux-3.1.4/net/mac80211/pm.c linux-= 3.1.4/net/mac80211/pm.c ieee80211_stop_device(local); =20 suspend: -diff -urNp linux-3.1.4/net/mac80211/rate.c linux-3.1.4/net/mac80211/rate= .c ---- linux-3.1.4/net/mac80211/rate.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/mac80211/rate.c 2011-11-16 18:39:08.000000000 -0500 -@@ -371,7 +371,7 @@ int ieee80211_init_rate_ctrl_alg(struct=20 +diff --git a/net/mac80211/rate.c b/net/mac80211/rate.c +index 3d5a2cb..b17ad48 100644 +--- a/net/mac80211/rate.c ++++ b/net/mac80211/rate.c +@@ -371,7 +371,7 @@ int ieee80211_init_rate_ctrl_alg(struct ieee80211_lo= cal *local, =20 ASSERT_RTNL(); =20 @@ -74687,10 +76319,11 @@ diff -urNp linux-3.1.4/net/mac80211/rate.c linu= x-3.1.4/net/mac80211/rate.c return -EBUSY; =20 if (local->hw.flags & IEEE80211_HW_HAS_RATE_CONTROL) { -diff -urNp linux-3.1.4/net/mac80211/rc80211_pid_debugfs.c linux-3.1.4/ne= t/mac80211/rc80211_pid_debugfs.c ---- linux-3.1.4/net/mac80211/rc80211_pid_debugfs.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/net/mac80211/rc80211_pid_debugfs.c 2011-11-16 18:39:08.0= 00000000 -0500 -@@ -192,7 +192,7 @@ static ssize_t rate_control_pid_events_r +diff --git a/net/mac80211/rc80211_pid_debugfs.c b/net/mac80211/rc80211_p= id_debugfs.c +index 4851e9e..d860e05 100644 +--- a/net/mac80211/rc80211_pid_debugfs.c ++++ b/net/mac80211/rc80211_pid_debugfs.c +@@ -192,7 +192,7 @@ static ssize_t rate_control_pid_events_read(struct f= ile *file, char __user *buf, =20 spin_unlock_irqrestore(&events->lock, status); =20 @@ -74699,10 +76332,11 @@ diff -urNp linux-3.1.4/net/mac80211/rc80211_pid= _debugfs.c linux-3.1.4/net/mac802 return -EFAULT; =20 return p; -diff -urNp linux-3.1.4/net/mac80211/util.c linux-3.1.4/net/mac80211/util= .c ---- linux-3.1.4/net/mac80211/util.c 2011-11-26 19:57:29.000000000 -0500 -+++ linux-3.1.4/net/mac80211/util.c 2011-11-26 20:00:43.000000000 -0500 -@@ -1170,7 +1170,7 @@ int ieee80211_reconfig(struct ieee80211_ +diff --git a/net/mac80211/util.c b/net/mac80211/util.c +index fd031e8..84fbfcf 100644 +--- a/net/mac80211/util.c ++++ b/net/mac80211/util.c +@@ -1170,7 +1170,7 @@ int ieee80211_reconfig(struct ieee80211_local *loc= al) drv_set_coverage_class(local, hw->wiphy->coverage_class); =20 /* everything else happens only if HW was up & running */ @@ -74711,10 +76345,44 @@ diff -urNp linux-3.1.4/net/mac80211/util.c linu= x-3.1.4/net/mac80211/util.c goto wake_up; =20 /* -diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_conn.c linux-3.1.4/net/n= etfilter/ipvs/ip_vs_conn.c ---- linux-3.1.4/net/netfilter/ipvs/ip_vs_conn.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/net/netfilter/ipvs/ip_vs_conn.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -556,7 +556,7 @@ ip_vs_bind_dest(struct ip_vs_conn *cp, s +diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig +index 32bff6d..d0cf986 100644 +--- a/net/netfilter/Kconfig ++++ b/net/netfilter/Kconfig +@@ -781,6 +781,16 @@ config NETFILTER_XT_MATCH_ESP +=20 + To compile it as a module, choose M here. If unsure, say N. +=20 ++config NETFILTER_XT_MATCH_GRADM ++ tristate '"gradm" match support' ++ depends on NETFILTER_XTABLES && NETFILTER_ADVANCED ++ depends on GRKERNSEC && !GRKERNSEC_NO_RBAC ++ ---help--- ++ The gradm match allows to match on grsecurity RBAC being enabled. ++ It is useful when iptables rules are applied early on bootup to ++ prevent connections to the machine (except from a trusted host) ++ while the RBAC system is disabled. ++ + config NETFILTER_XT_MATCH_HASHLIMIT + tristate '"hashlimit" match support' + depends on (IP6_NF_IPTABLES || IP6_NF_IPTABLES=3Dn) +diff --git a/net/netfilter/Makefile b/net/netfilter/Makefile +index 1a02853..5d8c22e 100644 +--- a/net/netfilter/Makefile ++++ b/net/netfilter/Makefile +@@ -81,6 +81,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_DCCP) +=3D xt_dccp.o + obj-$(CONFIG_NETFILTER_XT_MATCH_DEVGROUP) +=3D xt_devgroup.o + obj-$(CONFIG_NETFILTER_XT_MATCH_DSCP) +=3D xt_dscp.o + obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) +=3D xt_esp.o ++obj-$(CONFIG_NETFILTER_XT_MATCH_GRADM) +=3D xt_gradm.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HASHLIMIT) +=3D xt_hashlimit.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HELPER) +=3D xt_helper.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HL) +=3D xt_hl.o +diff --git a/net/netfilter/ipvs/ip_vs_conn.c b/net/netfilter/ipvs/ip_vs_= conn.c +index 12571fb..fb73976 100644 +--- a/net/netfilter/ipvs/ip_vs_conn.c ++++ b/net/netfilter/ipvs/ip_vs_conn.c +@@ -556,7 +556,7 @@ ip_vs_bind_dest(struct ip_vs_conn *cp, struct ip_vs_= dest *dest) /* Increase the refcnt counter of the dest */ atomic_inc(&dest->refcnt); =20 @@ -74723,7 +76391,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= onn.c linux-3.1.4/net/netfilter if (cp->protocol !=3D IPPROTO_UDP) conn_flags &=3D ~IP_VS_CONN_F_ONE_PACKET; /* Bind with the destination and its corresponding transmitter */ -@@ -869,7 +869,7 @@ ip_vs_conn_new(const struct ip_vs_conn_p +@@ -869,7 +869,7 @@ ip_vs_conn_new(const struct ip_vs_conn_param *p, atomic_set(&cp->refcnt, 1); =20 atomic_set(&cp->n_control, 0); @@ -74732,7 +76400,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= onn.c linux-3.1.4/net/netfilter =20 atomic_inc(&ipvs->conn_count); if (flags & IP_VS_CONN_F_NO_CPORT) -@@ -1149,7 +1149,7 @@ static inline int todrop_entry(struct ip +@@ -1149,7 +1149,7 @@ static inline int todrop_entry(struct ip_vs_conn *= cp) =20 /* Don't drop the entry if its number of incoming packets is not located in [0, 8] */ @@ -74741,10 +76409,11 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs= _conn.c linux-3.1.4/net/netfilter if (i > 8 || i < 0) return 0; =20 if (!todrop_rate[i]) return 0; -diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_core.c linux-3.1.4/net/n= etfilter/ipvs/ip_vs_core.c ---- linux-3.1.4/net/netfilter/ipvs/ip_vs_core.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/net/netfilter/ipvs/ip_vs_core.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -563,7 +563,7 @@ int ip_vs_leave(struct ip_vs_service *sv +diff --git a/net/netfilter/ipvs/ip_vs_core.c b/net/netfilter/ipvs/ip_vs_= core.c +index 4f77bb1..5d0bc26 100644 +--- a/net/netfilter/ipvs/ip_vs_core.c ++++ b/net/netfilter/ipvs/ip_vs_core.c +@@ -563,7 +563,7 @@ int ip_vs_leave(struct ip_vs_service *svc, struct sk= _buff *skb, ret =3D cp->packet_xmit(skb, cp, pd->pp); /* do not touch skb anymore */ =20 @@ -74753,7 +76422,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= ore.c linux-3.1.4/net/netfilter ip_vs_conn_put(cp); return ret; } -@@ -1612,7 +1612,7 @@ ip_vs_in(unsigned int hooknum, struct sk +@@ -1612,7 +1612,7 @@ ip_vs_in(unsigned int hooknum, struct sk_buff *skb= , int af) if (cp->flags & IP_VS_CONN_F_ONE_PACKET) pkts =3D sysctl_sync_threshold(ipvs); else @@ -74762,10 +76431,11 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs= _core.c linux-3.1.4/net/netfilter =20 if ((ipvs->sync_state & IP_VS_STATE_MASTER) && cp->protocol =3D=3D IPPROTO_SCTP) { -diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_ctl.c linux-3.1.4/net/ne= tfilter/ipvs/ip_vs_ctl.c ---- linux-3.1.4/net/netfilter/ipvs/ip_vs_ctl.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/net/netfilter/ipvs/ip_vs_ctl.c 2011-11-16 19:13:12.00000= 0000 -0500 -@@ -782,7 +782,7 @@ __ip_vs_update_dest(struct ip_vs_service +diff --git a/net/netfilter/ipvs/ip_vs_ctl.c b/net/netfilter/ipvs/ip_vs_c= tl.c +index e3be48b..d658c8c 100644 +--- a/net/netfilter/ipvs/ip_vs_ctl.c ++++ b/net/netfilter/ipvs/ip_vs_ctl.c +@@ -782,7 +782,7 @@ __ip_vs_update_dest(struct ip_vs_service *svc, struc= t ip_vs_dest *dest, ip_vs_rs_hash(ipvs, dest); write_unlock_bh(&ipvs->rs_lock); } @@ -74774,7 +76444,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= tl.c linux-3.1.4/net/netfilter/ =20 /* bind the service */ if (!dest->svc) { -@@ -2027,7 +2027,7 @@ static int ip_vs_info_seq_show(struct se +@@ -2027,7 +2027,7 @@ static int ip_vs_info_seq_show(struct seq_file *se= q, void *v) " %-7s %-6d %-10d %-10d\n", &dest->addr.in6, ntohs(dest->port), @@ -74783,7 +76453,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= tl.c linux-3.1.4/net/netfilter/ atomic_read(&dest->weight), atomic_read(&dest->activeconns), atomic_read(&dest->inactconns)); -@@ -2038,7 +2038,7 @@ static int ip_vs_info_seq_show(struct se +@@ -2038,7 +2038,7 @@ static int ip_vs_info_seq_show(struct seq_file *se= q, void *v) "%-7s %-6d %-10d %-10d\n", ntohl(dest->addr.ip), ntohs(dest->port), @@ -74792,7 +76462,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= tl.c linux-3.1.4/net/netfilter/ atomic_read(&dest->weight), atomic_read(&dest->activeconns), atomic_read(&dest->inactconns)); -@@ -2285,6 +2285,8 @@ do_ip_vs_set_ctl(struct sock *sk, int cm +@@ -2285,6 +2285,8 @@ do_ip_vs_set_ctl(struct sock *sk, int cmd, void __= user *user, unsigned int len) struct ip_vs_dest_user_kern udest; struct netns_ipvs *ipvs =3D net_ipvs(net); =20 @@ -74801,7 +76471,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= tl.c linux-3.1.4/net/netfilter/ if (!capable(CAP_NET_ADMIN)) return -EPERM; =20 -@@ -2508,7 +2510,7 @@ __ip_vs_get_dest_entries(struct net *net +@@ -2508,7 +2510,7 @@ __ip_vs_get_dest_entries(struct net *net, const st= ruct ip_vs_get_dests *get, =20 entry.addr =3D dest->addr.ip; entry.port =3D dest->port; @@ -74810,7 +76480,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_c= tl.c linux-3.1.4/net/netfilter/ entry.weight =3D atomic_read(&dest->weight); entry.u_threshold =3D dest->u_threshold; entry.l_threshold =3D dest->l_threshold; -@@ -3041,7 +3043,7 @@ static int ip_vs_genl_fill_dest(struct s +@@ -3041,7 +3043,7 @@ static int ip_vs_genl_fill_dest(struct sk_buff *sk= b, struct ip_vs_dest *dest) NLA_PUT_U16(skb, IPVS_DEST_ATTR_PORT, dest->port); =20 NLA_PUT_U32(skb, IPVS_DEST_ATTR_FWD_METHOD, @@ -74819,9 +76489,10 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_= ctl.c linux-3.1.4/net/netfilter/ NLA_PUT_U32(skb, IPVS_DEST_ATTR_WEIGHT, atomic_read(&dest->weight)); NLA_PUT_U32(skb, IPVS_DEST_ATTR_U_THRESH, dest->u_threshold); NLA_PUT_U32(skb, IPVS_DEST_ATTR_L_THRESH, dest->l_threshold); -diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_sync.c linux-3.1.4/net/n= etfilter/ipvs/ip_vs_sync.c ---- linux-3.1.4/net/netfilter/ipvs/ip_vs_sync.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/net/netfilter/ipvs/ip_vs_sync.c 2011-11-16 18:39:08.0000= 00000 -0500 +diff --git a/net/netfilter/ipvs/ip_vs_sync.c b/net/netfilter/ipvs/ip_vs_= sync.c +index 3cdd479..116afa8 100644 +--- a/net/netfilter/ipvs/ip_vs_sync.c ++++ b/net/netfilter/ipvs/ip_vs_sync.c @@ -649,7 +649,7 @@ control: * i.e only increment in_pkts for Templates. */ @@ -74831,7 +76502,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_s= ync.c linux-3.1.4/net/netfilter =20 if (pkts % sysctl_sync_period(ipvs) !=3D 1) return; -@@ -795,7 +795,7 @@ static void ip_vs_proc_conn(struct net * +@@ -795,7 +795,7 @@ static void ip_vs_proc_conn(struct net *net, struct = ip_vs_conn_param *param, =20 if (opt) memcpy(&cp->in_seq, opt, sizeof(*opt)); @@ -74840,10 +76511,11 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs= _sync.c linux-3.1.4/net/netfilter cp->state =3D state; cp->old_state =3D cp->state; /* -diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_xmit.c linux-3.1.4/net/n= etfilter/ipvs/ip_vs_xmit.c ---- linux-3.1.4/net/netfilter/ipvs/ip_vs_xmit.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/net/netfilter/ipvs/ip_vs_xmit.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -1151,7 +1151,7 @@ ip_vs_icmp_xmit(struct sk_buff *skb, str +diff --git a/net/netfilter/ipvs/ip_vs_xmit.c b/net/netfilter/ipvs/ip_vs_= xmit.c +index ee319a4..8a285ee 100644 +--- a/net/netfilter/ipvs/ip_vs_xmit.c ++++ b/net/netfilter/ipvs/ip_vs_xmit.c +@@ -1151,7 +1151,7 @@ ip_vs_icmp_xmit(struct sk_buff *skb, struct ip_vs_= conn *cp, else rc =3D NF_ACCEPT; /* do not touch skb anymore */ @@ -74852,7 +76524,7 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs_x= mit.c linux-3.1.4/net/netfilter goto out; } =20 -@@ -1272,7 +1272,7 @@ ip_vs_icmp_xmit_v6(struct sk_buff *skb,=20 +@@ -1272,7 +1272,7 @@ ip_vs_icmp_xmit_v6(struct sk_buff *skb, struct ip_= vs_conn *cp, else rc =3D NF_ACCEPT; /* do not touch skb anymore */ @@ -74861,40 +76533,10 @@ diff -urNp linux-3.1.4/net/netfilter/ipvs/ip_vs= _xmit.c linux-3.1.4/net/netfilter goto out; } =20 -diff -urNp linux-3.1.4/net/netfilter/Kconfig linux-3.1.4/net/netfilter/K= config ---- linux-3.1.4/net/netfilter/Kconfig 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/net/netfilter/Kconfig 2011-11-16 18:40:44.000000000 -050= 0 -@@ -781,6 +781,16 @@ config NETFILTER_XT_MATCH_ESP -=20 - To compile it as a module, choose M here. If unsure, say N. -=20 -+config NETFILTER_XT_MATCH_GRADM -+ tristate '"gradm" match support' -+ depends on NETFILTER_XTABLES && NETFILTER_ADVANCED -+ depends on GRKERNSEC && !GRKERNSEC_NO_RBAC -+ ---help--- -+ The gradm match allows to match on grsecurity RBAC being enabled. -+ It is useful when iptables rules are applied early on bootup to -+ prevent connections to the machine (except from a trusted host) -+ while the RBAC system is disabled. -+ - config NETFILTER_XT_MATCH_HASHLIMIT - tristate '"hashlimit" match support' - depends on (IP6_NF_IPTABLES || IP6_NF_IPTABLES=3Dn) -diff -urNp linux-3.1.4/net/netfilter/Makefile linux-3.1.4/net/netfilter/= Makefile ---- linux-3.1.4/net/netfilter/Makefile 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/netfilter/Makefile 2011-11-16 18:40:44.000000000 -05= 00 -@@ -81,6 +81,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_DCCP) +=3D - obj-$(CONFIG_NETFILTER_XT_MATCH_DEVGROUP) +=3D xt_devgroup.o - obj-$(CONFIG_NETFILTER_XT_MATCH_DSCP) +=3D xt_dscp.o - obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) +=3D xt_esp.o -+obj-$(CONFIG_NETFILTER_XT_MATCH_GRADM) +=3D xt_gradm.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HASHLIMIT) +=3D xt_hashlimit.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HELPER) +=3D xt_helper.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HL) +=3D xt_hl.o -diff -urNp linux-3.1.4/net/netfilter/nfnetlink_log.c linux-3.1.4/net/net= filter/nfnetlink_log.c ---- linux-3.1.4/net/netfilter/nfnetlink_log.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/net/netfilter/nfnetlink_log.c 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/net/netfilter/nfnetlink_log.c b/net/netfilter/nfnetlink_log= .c +index 2d8158a..5dca296 100644 +--- a/net/netfilter/nfnetlink_log.c ++++ b/net/netfilter/nfnetlink_log.c @@ -70,7 +70,7 @@ struct nfulnl_instance { }; =20 @@ -74904,7 +76546,7 @@ diff -urNp linux-3.1.4/net/netfilter/nfnetlink_lo= g.c linux-3.1.4/net/netfilter/n =20 #define INSTANCE_BUCKETS 16 static struct hlist_head instance_table[INSTANCE_BUCKETS]; -@@ -505,7 +505,7 @@ __build_packet_message(struct nfulnl_ins +@@ -505,7 +505,7 @@ __build_packet_message(struct nfulnl_instance *inst, /* global sequence number */ if (inst->flags & NFULNL_CFG_F_SEQ_GLOBAL) NLA_PUT_BE32(inst->skb, NFULA_SEQ_GLOBAL, @@ -74913,9 +76555,11 @@ diff -urNp linux-3.1.4/net/netfilter/nfnetlink_l= og.c linux-3.1.4/net/netfilter/n =20 if (data_len) { struct nlattr *nla; -diff -urNp linux-3.1.4/net/netfilter/xt_gradm.c linux-3.1.4/net/netfilte= r/xt_gradm.c ---- linux-3.1.4/net/netfilter/xt_gradm.c 1969-12-31 19:00:00.000000000 -= 0500 -+++ linux-3.1.4/net/netfilter/xt_gradm.c 2011-11-16 18:40:44.000000000 -= 0500 +diff --git a/net/netfilter/xt_gradm.c b/net/netfilter/xt_gradm.c +new file mode 100644 +index 0000000..6905327 +--- /dev/null ++++ b/net/netfilter/xt_gradm.c @@ -0,0 +1,51 @@ +/* + * gradm match for netfilter @@ -74968,9 +76612,10 @@ diff -urNp linux-3.1.4/net/netfilter/xt_gradm.c = linux-3.1.4/net/netfilter/xt_gra +MODULE_LICENSE("GPL"); +MODULE_ALIAS("ipt_gradm"); +MODULE_ALIAS("ip6t_gradm"); -diff -urNp linux-3.1.4/net/netfilter/xt_statistic.c linux-3.1.4/net/netf= ilter/xt_statistic.c ---- linux-3.1.4/net/netfilter/xt_statistic.c 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/net/netfilter/xt_statistic.c 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/net/netfilter/xt_statistic.c b/net/netfilter/xt_statistic.c +index 42ecb71..8d687c0 100644 +--- a/net/netfilter/xt_statistic.c ++++ b/net/netfilter/xt_statistic.c @@ -18,7 +18,7 @@ #include =20 @@ -74980,7 +76625,7 @@ diff -urNp linux-3.1.4/net/netfilter/xt_statistic= .c linux-3.1.4/net/netfilter/xt } ____cacheline_aligned_in_smp; =20 MODULE_LICENSE("GPL"); -@@ -41,9 +41,9 @@ statistic_mt(const struct sk_buff *skb,=20 +@@ -41,9 +41,9 @@ statistic_mt(const struct sk_buff *skb, struct xt_acti= on_param *par) break; case XT_STATISTIC_MODE_NTH: do { @@ -74992,7 +76637,7 @@ diff -urNp linux-3.1.4/net/netfilter/xt_statistic= .c linux-3.1.4/net/netfilter/xt if (nval =3D=3D 0) ret =3D !ret; break; -@@ -63,7 +63,7 @@ static int statistic_mt_check(const stru +@@ -63,7 +63,7 @@ static int statistic_mt_check(const struct xt_mtchk_pa= ram *par) info->master =3D kzalloc(sizeof(*info->master), GFP_KERNEL); if (info->master =3D=3D NULL) return -ENOMEM; @@ -75001,10 +76646,11 @@ diff -urNp linux-3.1.4/net/netfilter/xt_statist= ic.c linux-3.1.4/net/netfilter/xt =20 return 0; } -diff -urNp linux-3.1.4/net/netlink/af_netlink.c linux-3.1.4/net/netlink/= af_netlink.c ---- linux-3.1.4/net/netlink/af_netlink.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/netlink/af_netlink.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -742,7 +742,7 @@ static void netlink_overrun(struct sock=20 +diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c +index 0a4db02..604f748 100644 +--- a/net/netlink/af_netlink.c ++++ b/net/netlink/af_netlink.c +@@ -742,7 +742,7 @@ static void netlink_overrun(struct sock *sk) sk->sk_error_report(sk); } } @@ -75013,7 +76659,7 @@ diff -urNp linux-3.1.4/net/netlink/af_netlink.c l= inux-3.1.4/net/netlink/af_netli } =20 static struct sock *netlink_getsockbypid(struct sock *ssk, u32 pid) -@@ -2000,7 +2000,7 @@ static int netlink_seq_show(struct seq_f +@@ -2000,7 +2000,7 @@ static int netlink_seq_show(struct seq_file *seq, = void *v) sk_wmem_alloc_get(s), nlk->cb, atomic_read(&s->sk_refcnt), @@ -75022,10 +76668,11 @@ diff -urNp linux-3.1.4/net/netlink/af_netlink.c= linux-3.1.4/net/netlink/af_netli sock_i_ino(s) ); =20 -diff -urNp linux-3.1.4/net/netrom/af_netrom.c linux-3.1.4/net/netrom/af_= netrom.c ---- linux-3.1.4/net/netrom/af_netrom.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/netrom/af_netrom.c 2011-11-16 18:40:44.000000000 -05= 00 -@@ -839,6 +839,7 @@ static int nr_getname(struct socket *soc +diff --git a/net/netrom/af_netrom.c b/net/netrom/af_netrom.c +index 732152f..60bb09e 100644 +--- a/net/netrom/af_netrom.c ++++ b/net/netrom/af_netrom.c +@@ -839,6 +839,7 @@ static int nr_getname(struct socket *sock, struct so= ckaddr *uaddr, struct sock *sk =3D sock->sk; struct nr_sock *nr =3D nr_sk(sk); =20 @@ -75033,7 +76680,7 @@ diff -urNp linux-3.1.4/net/netrom/af_netrom.c lin= ux-3.1.4/net/netrom/af_netrom.c lock_sock(sk); if (peer !=3D 0) { if (sk->sk_state !=3D TCP_ESTABLISHED) { -@@ -853,7 +854,6 @@ static int nr_getname(struct socket *soc +@@ -853,7 +854,6 @@ static int nr_getname(struct socket *sock, struct so= ckaddr *uaddr, *uaddr_len =3D sizeof(struct full_sockaddr_ax25); } else { sax->fsa_ax25.sax25_family =3D AF_NETROM; @@ -75041,10 +76688,11 @@ diff -urNp linux-3.1.4/net/netrom/af_netrom.c l= inux-3.1.4/net/netrom/af_netrom.c sax->fsa_ax25.sax25_call =3D nr->source_addr; *uaddr_len =3D sizeof(struct sockaddr_ax25); } -diff -urNp linux-3.1.4/net/packet/af_packet.c linux-3.1.4/net/packet/af_= packet.c ---- linux-3.1.4/net/packet/af_packet.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/packet/af_packet.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -954,7 +954,7 @@ static int packet_rcv(struct sk_buff *sk +diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c +index fabb4fa..e146b73 100644 +--- a/net/packet/af_packet.c ++++ b/net/packet/af_packet.c +@@ -954,7 +954,7 @@ static int packet_rcv(struct sk_buff *skb, struct ne= t_device *dev, =20 spin_lock(&sk->sk_receive_queue.lock); po->stats.tp_packets++; @@ -75053,7 +76701,7 @@ diff -urNp linux-3.1.4/net/packet/af_packet.c lin= ux-3.1.4/net/packet/af_packet.c __skb_queue_tail(&sk->sk_receive_queue, skb); spin_unlock(&sk->sk_receive_queue.lock); sk->sk_data_ready(sk, skb->len); -@@ -963,7 +963,7 @@ static int packet_rcv(struct sk_buff *sk +@@ -963,7 +963,7 @@ static int packet_rcv(struct sk_buff *skb, struct ne= t_device *dev, drop_n_acct: spin_lock(&sk->sk_receive_queue.lock); po->stats.tp_drops++; @@ -75062,7 +76710,7 @@ diff -urNp linux-3.1.4/net/packet/af_packet.c lin= ux-3.1.4/net/packet/af_packet.c spin_unlock(&sk->sk_receive_queue.lock); =20 drop_n_restore: -@@ -2479,7 +2479,7 @@ static int packet_getsockopt(struct sock +@@ -2479,7 +2479,7 @@ static int packet_getsockopt(struct socket *sock, = int level, int optname, case PACKET_HDRLEN: if (len > sizeof(int)) len =3D sizeof(int); @@ -75071,7 +76719,7 @@ diff -urNp linux-3.1.4/net/packet/af_packet.c lin= ux-3.1.4/net/packet/af_packet.c return -EFAULT; switch (val) { case TPACKET_V1: -@@ -2526,7 +2526,7 @@ static int packet_getsockopt(struct sock +@@ -2526,7 +2526,7 @@ static int packet_getsockopt(struct socket *sock, = int level, int optname, =20 if (put_user(len, optlen)) return -EFAULT; @@ -75080,10 +76728,11 @@ diff -urNp linux-3.1.4/net/packet/af_packet.c l= inux-3.1.4/net/packet/af_packet.c return -EFAULT; return 0; } -diff -urNp linux-3.1.4/net/phonet/af_phonet.c linux-3.1.4/net/phonet/af_= phonet.c ---- linux-3.1.4/net/phonet/af_phonet.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/phonet/af_phonet.c 2011-11-16 18:40:44.000000000 -05= 00 -@@ -41,7 +41,7 @@ static struct phonet_protocol *phonet_pr +diff --git a/net/phonet/af_phonet.c b/net/phonet/af_phonet.c +index c6fffd9..a7ffa0c 100644 +--- a/net/phonet/af_phonet.c ++++ b/net/phonet/af_phonet.c +@@ -41,7 +41,7 @@ static struct phonet_protocol *phonet_proto_get(unsign= ed int protocol) { struct phonet_protocol *pp; =20 @@ -75092,7 +76741,7 @@ diff -urNp linux-3.1.4/net/phonet/af_phonet.c lin= ux-3.1.4/net/phonet/af_phonet.c return NULL; =20 rcu_read_lock(); -@@ -469,7 +469,7 @@ int __init_or_module phonet_proto_regist +@@ -469,7 +469,7 @@ int __init_or_module phonet_proto_register(unsigned = int protocol, { int err =3D 0; =20 @@ -75101,10 +76750,11 @@ diff -urNp linux-3.1.4/net/phonet/af_phonet.c l= inux-3.1.4/net/phonet/af_phonet.c return -EINVAL; =20 err =3D proto_register(pp->prot, 1); -diff -urNp linux-3.1.4/net/phonet/pep.c linux-3.1.4/net/phonet/pep.c ---- linux-3.1.4/net/phonet/pep.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/phonet/pep.c 2011-11-16 18:39:08.000000000 -0500 -@@ -387,7 +387,7 @@ static int pipe_do_rcv(struct sock *sk,=20 +diff --git a/net/phonet/pep.c b/net/phonet/pep.c +index f17fd84..edffce8 100644 +--- a/net/phonet/pep.c ++++ b/net/phonet/pep.c +@@ -387,7 +387,7 @@ static int pipe_do_rcv(struct sock *sk, struct sk_bu= ff *skb) =20 case PNS_PEP_CTRL_REQ: if (skb_queue_len(&pn->ctrlreq_queue) >=3D PNPIPE_CTRLREQ_MAX) { @@ -75113,7 +76763,7 @@ diff -urNp linux-3.1.4/net/phonet/pep.c linux-3.1= .4/net/phonet/pep.c break; } __skb_pull(skb, 4); -@@ -408,7 +408,7 @@ static int pipe_do_rcv(struct sock *sk,=20 +@@ -408,7 +408,7 @@ static int pipe_do_rcv(struct sock *sk, struct sk_bu= ff *skb) } =20 if (pn->rx_credits =3D=3D 0) { @@ -75122,7 +76772,7 @@ diff -urNp linux-3.1.4/net/phonet/pep.c linux-3.1= .4/net/phonet/pep.c err =3D -ENOBUFS; break; } -@@ -556,7 +556,7 @@ static int pipe_handler_do_rcv(struct so +@@ -556,7 +556,7 @@ static int pipe_handler_do_rcv(struct sock *sk, stru= ct sk_buff *skb) } =20 if (pn->rx_credits =3D=3D 0) { @@ -75131,10 +76781,11 @@ diff -urNp linux-3.1.4/net/phonet/pep.c linux-3= .1.4/net/phonet/pep.c err =3D NET_RX_DROP; break; } -diff -urNp linux-3.1.4/net/phonet/socket.c linux-3.1.4/net/phonet/socket= .c ---- linux-3.1.4/net/phonet/socket.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/phonet/socket.c 2011-11-16 18:40:44.000000000 -0500 -@@ -612,8 +612,13 @@ static int pn_sock_seq_show(struct seq_f +diff --git a/net/phonet/socket.c b/net/phonet/socket.c +index ab07711..9d4ac5d 100644 +--- a/net/phonet/socket.c ++++ b/net/phonet/socket.c +@@ -612,8 +612,13 @@ static int pn_sock_seq_show(struct seq_file *seq, v= oid *v) pn->resource, sk->sk_state, sk_wmem_alloc_get(sk), sk_rmem_alloc_get(sk), sock_i_uid(sk), sock_i_ino(sk), @@ -75150,9 +76801,10 @@ diff -urNp linux-3.1.4/net/phonet/socket.c linux= -3.1.4/net/phonet/socket.c } seq_printf(seq, "%*s\n", 127 - len, ""); return 0; -diff -urNp linux-3.1.4/net/rds/cong.c linux-3.1.4/net/rds/cong.c ---- linux-3.1.4/net/rds/cong.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/cong.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/rds/cong.c b/net/rds/cong.c +index 6daaa49..fbf6af5 100644 +--- a/net/rds/cong.c ++++ b/net/rds/cong.c @@ -77,7 +77,7 @@ * finds that the saved generation number is smaller than the global ge= neration * number, it wakes up the process. @@ -75162,7 +76814,7 @@ diff -urNp linux-3.1.4/net/rds/cong.c linux-3.1.4= /net/rds/cong.c =20 /* * Congestion monitoring -@@ -232,7 +232,7 @@ void rds_cong_map_updated(struct rds_con +@@ -232,7 +232,7 @@ void rds_cong_map_updated(struct rds_cong_map *map, = uint64_t portmask) rdsdebug("waking map %p for %pI4\n", map, &map->m_addr); rds_stats_inc(s_cong_update_received); @@ -75180,21 +76832,10 @@ diff -urNp linux-3.1.4/net/rds/cong.c linux-3.1= .4/net/rds/cong.c =20 if (likely(*recent =3D=3D gen)) return 0; -diff -urNp linux-3.1.4/net/rds/ib_cm.c linux-3.1.4/net/rds/ib_cm.c ---- linux-3.1.4/net/rds/ib_cm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/ib_cm.c 2011-11-16 18:39:08.000000000 -0500 -@@ -720,7 +720,7 @@ void rds_ib_conn_shutdown(struct rds_con - /* Clear the ACK state */ - clear_bit(IB_ACK_IN_FLIGHT, &ic->i_ack_flags); - #ifdef KERNEL_HAS_ATOMIC64 -- atomic64_set(&ic->i_ack_next, 0); -+ atomic64_set_unchecked(&ic->i_ack_next, 0); - #else - ic->i_ack_next =3D 0; - #endif -diff -urNp linux-3.1.4/net/rds/ib.h linux-3.1.4/net/rds/ib.h ---- linux-3.1.4/net/rds/ib.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/ib.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/rds/ib.h b/net/rds/ib.h +index edfaaaf..8c89879 100644 +--- a/net/rds/ib.h ++++ b/net/rds/ib.h @@ -128,7 +128,7 @@ struct rds_ib_connection { /* sending acks */ unsigned long i_ack_flags; @@ -75204,10 +76845,24 @@ diff -urNp linux-3.1.4/net/rds/ib.h linux-3.1.4= /net/rds/ib.h #else spinlock_t i_ack_lock; /* protect i_ack_next */ u64 i_ack_next; /* next ACK to send */ -diff -urNp linux-3.1.4/net/rds/ib_recv.c linux-3.1.4/net/rds/ib_recv.c ---- linux-3.1.4/net/rds/ib_recv.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/ib_recv.c 2011-11-16 18:39:08.000000000 -0500 -@@ -592,7 +592,7 @@ static u64 rds_ib_get_ack(struct rds_ib_ +diff --git a/net/rds/ib_cm.c b/net/rds/ib_cm.c +index cd67026..0b9a54a 100644 +--- a/net/rds/ib_cm.c ++++ b/net/rds/ib_cm.c +@@ -720,7 +720,7 @@ void rds_ib_conn_shutdown(struct rds_connection *con= n) + /* Clear the ACK state */ + clear_bit(IB_ACK_IN_FLIGHT, &ic->i_ack_flags); + #ifdef KERNEL_HAS_ATOMIC64 +- atomic64_set(&ic->i_ack_next, 0); ++ atomic64_set_unchecked(&ic->i_ack_next, 0); + #else + ic->i_ack_next =3D 0; + #endif +diff --git a/net/rds/ib_recv.c b/net/rds/ib_recv.c +index e29e0ca..fa3a6a3 100644 +--- a/net/rds/ib_recv.c ++++ b/net/rds/ib_recv.c +@@ -592,7 +592,7 @@ static u64 rds_ib_get_ack(struct rds_ib_connection *= ic) static void rds_ib_set_ack(struct rds_ib_connection *ic, u64 seq, int ack_required) { @@ -75216,7 +76871,7 @@ diff -urNp linux-3.1.4/net/rds/ib_recv.c linux-3.= 1.4/net/rds/ib_recv.c if (ack_required) { smp_mb__before_clear_bit(); set_bit(IB_ACK_REQUESTED, &ic->i_ack_flags); -@@ -604,7 +604,7 @@ static u64 rds_ib_get_ack(struct rds_ib_ +@@ -604,7 +604,7 @@ static u64 rds_ib_get_ack(struct rds_ib_connection *= ic) clear_bit(IB_ACK_REQUESTED, &ic->i_ack_flags); smp_mb__after_clear_bit(); =20 @@ -75225,21 +76880,10 @@ diff -urNp linux-3.1.4/net/rds/ib_recv.c linux-= 3.1.4/net/rds/ib_recv.c } #endif =20 -diff -urNp linux-3.1.4/net/rds/iw_cm.c linux-3.1.4/net/rds/iw_cm.c ---- linux-3.1.4/net/rds/iw_cm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/iw_cm.c 2011-11-16 18:39:08.000000000 -0500 -@@ -663,7 +663,7 @@ void rds_iw_conn_shutdown(struct rds_con - /* Clear the ACK state */ - clear_bit(IB_ACK_IN_FLIGHT, &ic->i_ack_flags); - #ifdef KERNEL_HAS_ATOMIC64 -- atomic64_set(&ic->i_ack_next, 0); -+ atomic64_set_unchecked(&ic->i_ack_next, 0); - #else - ic->i_ack_next =3D 0; - #endif -diff -urNp linux-3.1.4/net/rds/iw.h linux-3.1.4/net/rds/iw.h ---- linux-3.1.4/net/rds/iw.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/iw.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/rds/iw.h b/net/rds/iw.h +index 04ce3b1..48119a6 100644 +--- a/net/rds/iw.h ++++ b/net/rds/iw.h @@ -134,7 +134,7 @@ struct rds_iw_connection { /* sending acks */ unsigned long i_ack_flags; @@ -75249,10 +76893,24 @@ diff -urNp linux-3.1.4/net/rds/iw.h linux-3.1.4= /net/rds/iw.h #else spinlock_t i_ack_lock; /* protect i_ack_next */ u64 i_ack_next; /* next ACK to send */ -diff -urNp linux-3.1.4/net/rds/iw_rdma.c linux-3.1.4/net/rds/iw_rdma.c ---- linux-3.1.4/net/rds/iw_rdma.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/iw_rdma.c 2011-11-16 18:40:44.000000000 -0500 -@@ -184,6 +184,8 @@ int rds_iw_update_cm_id(struct rds_iw_de +diff --git a/net/rds/iw_cm.c b/net/rds/iw_cm.c +index 9556d28..f046d0e 100644 +--- a/net/rds/iw_cm.c ++++ b/net/rds/iw_cm.c +@@ -663,7 +663,7 @@ void rds_iw_conn_shutdown(struct rds_connection *con= n) + /* Clear the ACK state */ + clear_bit(IB_ACK_IN_FLIGHT, &ic->i_ack_flags); + #ifdef KERNEL_HAS_ATOMIC64 +- atomic64_set(&ic->i_ack_next, 0); ++ atomic64_set_unchecked(&ic->i_ack_next, 0); + #else + ic->i_ack_next =3D 0; + #endif +diff --git a/net/rds/iw_rdma.c b/net/rds/iw_rdma.c +index 4e1de17..d121708 100644 +--- a/net/rds/iw_rdma.c ++++ b/net/rds/iw_rdma.c +@@ -184,6 +184,8 @@ int rds_iw_update_cm_id(struct rds_iw_device *rds_iw= dev, struct rdma_cm_id *cm_i struct rdma_cm_id *pcm_id; int rc; =20 @@ -75261,10 +76919,11 @@ diff -urNp linux-3.1.4/net/rds/iw_rdma.c linux-= 3.1.4/net/rds/iw_rdma.c src_addr =3D (struct sockaddr_in *)&cm_id->route.addr.src_addr; dst_addr =3D (struct sockaddr_in *)&cm_id->route.addr.dst_addr; =20 -diff -urNp linux-3.1.4/net/rds/iw_recv.c linux-3.1.4/net/rds/iw_recv.c ---- linux-3.1.4/net/rds/iw_recv.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/iw_recv.c 2011-11-16 18:39:08.000000000 -0500 -@@ -427,7 +427,7 @@ static u64 rds_iw_get_ack(struct rds_iw_ +diff --git a/net/rds/iw_recv.c b/net/rds/iw_recv.c +index 5e57347..3916042 100644 +--- a/net/rds/iw_recv.c ++++ b/net/rds/iw_recv.c +@@ -427,7 +427,7 @@ static u64 rds_iw_get_ack(struct rds_iw_connection *= ic) static void rds_iw_set_ack(struct rds_iw_connection *ic, u64 seq, int ack_required) { @@ -75273,7 +76932,7 @@ diff -urNp linux-3.1.4/net/rds/iw_recv.c linux-3.= 1.4/net/rds/iw_recv.c if (ack_required) { smp_mb__before_clear_bit(); set_bit(IB_ACK_REQUESTED, &ic->i_ack_flags); -@@ -439,7 +439,7 @@ static u64 rds_iw_get_ack(struct rds_iw_ +@@ -439,7 +439,7 @@ static u64 rds_iw_get_ack(struct rds_iw_connection *= ic) clear_bit(IB_ACK_REQUESTED, &ic->i_ack_flags); smp_mb__after_clear_bit(); =20 @@ -75282,10 +76941,11 @@ diff -urNp linux-3.1.4/net/rds/iw_recv.c linux-= 3.1.4/net/rds/iw_recv.c } #endif =20 -diff -urNp linux-3.1.4/net/rds/tcp.c linux-3.1.4/net/rds/tcp.c ---- linux-3.1.4/net/rds/tcp.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/tcp.c 2011-11-16 18:39:08.000000000 -0500 -@@ -58,7 +58,7 @@ void rds_tcp_nonagle(struct socket *sock +diff --git a/net/rds/tcp.c b/net/rds/tcp.c +index 8e0a320..ee8e38f 100644 +--- a/net/rds/tcp.c ++++ b/net/rds/tcp.c +@@ -58,7 +58,7 @@ void rds_tcp_nonagle(struct socket *sock) int val =3D 1; =20 set_fs(KERNEL_DS); @@ -75294,10 +76954,11 @@ diff -urNp linux-3.1.4/net/rds/tcp.c linux-3.1.= 4/net/rds/tcp.c sizeof(val)); set_fs(oldfs); } -diff -urNp linux-3.1.4/net/rds/tcp_send.c linux-3.1.4/net/rds/tcp_send.c ---- linux-3.1.4/net/rds/tcp_send.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rds/tcp_send.c 2011-11-16 18:39:08.000000000 -0500 -@@ -43,7 +43,7 @@ static void rds_tcp_cork(struct socket * +diff --git a/net/rds/tcp_send.c b/net/rds/tcp_send.c +index 1b4fd68..2234175 100644 +--- a/net/rds/tcp_send.c ++++ b/net/rds/tcp_send.c +@@ -43,7 +43,7 @@ static void rds_tcp_cork(struct socket *sock, int val) =20 oldfs =3D get_fs(); set_fs(KERNEL_DS); @@ -75306,10 +76967,11 @@ diff -urNp linux-3.1.4/net/rds/tcp_send.c linux= -3.1.4/net/rds/tcp_send.c sizeof(val)); set_fs(oldfs); } -diff -urNp linux-3.1.4/net/rxrpc/af_rxrpc.c linux-3.1.4/net/rxrpc/af_rxr= pc.c ---- linux-3.1.4/net/rxrpc/af_rxrpc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/af_rxrpc.c 2011-11-16 18:39:08.000000000 -0500 -@@ -39,7 +39,7 @@ static const struct proto_ops rxrpc_rpc_ +diff --git a/net/rxrpc/af_rxrpc.c b/net/rxrpc/af_rxrpc.c +index 74c064c..fdec26f 100644 +--- a/net/rxrpc/af_rxrpc.c ++++ b/net/rxrpc/af_rxrpc.c +@@ -39,7 +39,7 @@ static const struct proto_ops rxrpc_rpc_ops; __be32 rxrpc_epoch; =20 /* current debugging ID */ @@ -75318,10 +76980,11 @@ diff -urNp linux-3.1.4/net/rxrpc/af_rxrpc.c lin= ux-3.1.4/net/rxrpc/af_rxrpc.c =20 /* count of skbs currently in use */ atomic_t rxrpc_n_skbs; -diff -urNp linux-3.1.4/net/rxrpc/ar-ack.c linux-3.1.4/net/rxrpc/ar-ack.c ---- linux-3.1.4/net/rxrpc/ar-ack.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/ar-ack.c 2011-11-16 18:40:44.000000000 -0500 -@@ -175,7 +175,7 @@ static void rxrpc_resend(struct rxrpc_ca +diff --git a/net/rxrpc/ar-ack.c b/net/rxrpc/ar-ack.c +index f99cfce..3682692 100644 +--- a/net/rxrpc/ar-ack.c ++++ b/net/rxrpc/ar-ack.c +@@ -175,7 +175,7 @@ static void rxrpc_resend(struct rxrpc_call *call) =20 _enter("{%d,%d,%d,%d},", call->acks_hard, call->acks_unacked, @@ -75330,7 +76993,7 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-ack.c linux-3= .1.4/net/rxrpc/ar-ack.c CIRC_CNT(call->acks_head, call->acks_tail, call->acks_winsz)); =20 stop =3D 0; -@@ -199,7 +199,7 @@ static void rxrpc_resend(struct rxrpc_ca +@@ -199,7 +199,7 @@ static void rxrpc_resend(struct rxrpc_call *call) =20 /* each Tx packet has a new serial number */ sp->hdr.serial =3D @@ -75339,7 +77002,7 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-ack.c linux-3= .1.4/net/rxrpc/ar-ack.c =20 hdr =3D (struct rxrpc_header *) txb->head; hdr->serial =3D sp->hdr.serial; -@@ -403,7 +403,7 @@ static void rxrpc_rotate_tx_window(struc +@@ -403,7 +403,7 @@ static void rxrpc_rotate_tx_window(struct rxrpc_call= *call, u32 hard) */ static void rxrpc_clear_tx_window(struct rxrpc_call *call) { @@ -75357,7 +77020,7 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-ack.c linux-3= .1.4/net/rxrpc/ar-ack.c =20 _proto("Rx ACK %%%u { m=3D%hu f=3D#%u p=3D#%u s=3D%%%u r=3D%s n=3D%u = }", latest, -@@ -842,6 +842,8 @@ void rxrpc_process_call(struct work_stru +@@ -842,6 +842,8 @@ void rxrpc_process_call(struct work_struct *work) u32 abort_code =3D RX_PROTOCOL_ERROR; u8 *acks =3D NULL; =20 @@ -75366,7 +77029,7 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-ack.c linux-3= .1.4/net/rxrpc/ar-ack.c //printk("\n--------------------\n"); _enter("{%d,%s,%lx} [%lu]", call->debug_id, rxrpc_call_states[call->state], call->events, -@@ -1161,7 +1163,7 @@ void rxrpc_process_call(struct work_stru +@@ -1161,7 +1163,7 @@ void rxrpc_process_call(struct work_struct *work) goto maybe_reschedule; =20 send_ACK_with_skew: @@ -75393,10 +77056,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-ack.c linux= -3.1.4/net/rxrpc/ar-ack.c _proto("Tx %s %%%u", rxrpc_pkts[hdr.type], ntohl(hdr.serial)); send_message_2: =20 -diff -urNp linux-3.1.4/net/rxrpc/ar-call.c linux-3.1.4/net/rxrpc/ar-call= .c ---- linux-3.1.4/net/rxrpc/ar-call.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/ar-call.c 2011-11-16 18:39:08.000000000 -0500 -@@ -83,7 +83,7 @@ static struct rxrpc_call *rxrpc_alloc_ca +diff --git a/net/rxrpc/ar-call.c b/net/rxrpc/ar-call.c +index bf656c2..48f9d27 100644 +--- a/net/rxrpc/ar-call.c ++++ b/net/rxrpc/ar-call.c +@@ -83,7 +83,7 @@ static struct rxrpc_call *rxrpc_alloc_call(gfp_t gfp) spin_lock_init(&call->lock); rwlock_init(&call->state_lock); atomic_set(&call->usage, 1); @@ -75405,10 +77069,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-call.c linu= x-3.1.4/net/rxrpc/ar-call.c call->state =3D RXRPC_CALL_CLIENT_SEND_REQUEST; =20 memset(&call->sock_node, 0xed, sizeof(call->sock_node)); -diff -urNp linux-3.1.4/net/rxrpc/ar-connection.c linux-3.1.4/net/rxrpc/a= r-connection.c ---- linux-3.1.4/net/rxrpc/ar-connection.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/net/rxrpc/ar-connection.c 2011-11-16 18:39:08.000000000 = -0500 -@@ -206,7 +206,7 @@ static struct rxrpc_connection *rxrpc_al +diff --git a/net/rxrpc/ar-connection.c b/net/rxrpc/ar-connection.c +index 4106ca9..a338d7a 100644 +--- a/net/rxrpc/ar-connection.c ++++ b/net/rxrpc/ar-connection.c +@@ -206,7 +206,7 @@ static struct rxrpc_connection *rxrpc_alloc_connecti= on(gfp_t gfp) rwlock_init(&conn->lock); spin_lock_init(&conn->state_lock); atomic_set(&conn->usage, 1); @@ -75417,10 +77082,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-connection.= c linux-3.1.4/net/rxrpc/ar-connec conn->avail_calls =3D RXRPC_MAXCALLS; conn->size_align =3D 4; conn->header_size =3D sizeof(struct rxrpc_header); -diff -urNp linux-3.1.4/net/rxrpc/ar-connevent.c linux-3.1.4/net/rxrpc/ar= -connevent.c ---- linux-3.1.4/net/rxrpc/ar-connevent.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/rxrpc/ar-connevent.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -109,7 +109,7 @@ static int rxrpc_abort_connection(struct +diff --git a/net/rxrpc/ar-connevent.c b/net/rxrpc/ar-connevent.c +index e7ed43a..6afa140 100644 +--- a/net/rxrpc/ar-connevent.c ++++ b/net/rxrpc/ar-connevent.c +@@ -109,7 +109,7 @@ static int rxrpc_abort_connection(struct rxrpc_conne= ction *conn, =20 len =3D iov[0].iov_len + iov[1].iov_len; =20 @@ -75429,10 +77095,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-connevent.c= linux-3.1.4/net/rxrpc/ar-conneve _proto("Tx CONN ABORT %%%u { %d }", ntohl(hdr.serial), abort_code); =20 ret =3D kernel_sendmsg(conn->trans->local->socket, &msg, iov, 2, len); -diff -urNp linux-3.1.4/net/rxrpc/ar-input.c linux-3.1.4/net/rxrpc/ar-inp= ut.c ---- linux-3.1.4/net/rxrpc/ar-input.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/ar-input.c 2011-11-16 18:39:08.000000000 -0500 -@@ -340,9 +340,9 @@ void rxrpc_fast_process_packet(struct rx +diff --git a/net/rxrpc/ar-input.c b/net/rxrpc/ar-input.c +index 1a2b0633..e8d1382 100644 +--- a/net/rxrpc/ar-input.c ++++ b/net/rxrpc/ar-input.c +@@ -340,9 +340,9 @@ void rxrpc_fast_process_packet(struct rxrpc_call *ca= ll, struct sk_buff *skb) /* track the latest serial number on this connection for ACK packet * information */ serial =3D ntohl(sp->hdr.serial); @@ -75444,9 +77111,10 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-input.c linu= x-3.1.4/net/rxrpc/ar-input.c serial); =20 /* request ACK generation for any ACK or DATA packet that requests -diff -urNp linux-3.1.4/net/rxrpc/ar-internal.h linux-3.1.4/net/rxrpc/ar-= internal.h ---- linux-3.1.4/net/rxrpc/ar-internal.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/net/rxrpc/ar-internal.h 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/net/rxrpc/ar-internal.h b/net/rxrpc/ar-internal.h +index 8e22bd3..f66d1c0 100644 +--- a/net/rxrpc/ar-internal.h ++++ b/net/rxrpc/ar-internal.h @@ -272,8 +272,8 @@ struct rxrpc_connection { int error; /* error code for local abort */ int debug_id; /* debug ID for printks */ @@ -75467,7 +77135,7 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-internal.h li= nux-3.1.4/net/rxrpc/ar-internal u32 abort_code; /* local/remote abort code */ enum { /* current state of call */ RXRPC_CALL_CLIENT_SEND_REQUEST, /* - client sending request phase */ -@@ -420,7 +420,7 @@ static inline void rxrpc_abort_call(stru +@@ -420,7 +420,7 @@ static inline void rxrpc_abort_call(struct rxrpc_cal= l *call, u32 abort_code) */ extern atomic_t rxrpc_n_skbs; extern __be32 rxrpc_epoch; @@ -75476,10 +77144,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-internal.h = linux-3.1.4/net/rxrpc/ar-internal extern struct workqueue_struct *rxrpc_workqueue; =20 /* -diff -urNp linux-3.1.4/net/rxrpc/ar-local.c linux-3.1.4/net/rxrpc/ar-loc= al.c ---- linux-3.1.4/net/rxrpc/ar-local.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/ar-local.c 2011-11-16 18:39:08.000000000 -0500 -@@ -45,7 +45,7 @@ struct rxrpc_local *rxrpc_alloc_local(st +diff --git a/net/rxrpc/ar-local.c b/net/rxrpc/ar-local.c +index 87f7135..74d3703 100644 +--- a/net/rxrpc/ar-local.c ++++ b/net/rxrpc/ar-local.c +@@ -45,7 +45,7 @@ struct rxrpc_local *rxrpc_alloc_local(struct sockaddr_= rxrpc *srx) spin_lock_init(&local->lock); rwlock_init(&local->services_lock); atomic_set(&local->usage, 1); @@ -75488,10 +77157,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-local.c lin= ux-3.1.4/net/rxrpc/ar-local.c memcpy(&local->srx, srx, sizeof(*srx)); } =20 -diff -urNp linux-3.1.4/net/rxrpc/ar-output.c linux-3.1.4/net/rxrpc/ar-ou= tput.c ---- linux-3.1.4/net/rxrpc/ar-output.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/net/rxrpc/ar-output.c 2011-11-16 18:39:08.000000000 -050= 0 -@@ -681,9 +681,9 @@ static int rxrpc_send_data(struct kiocb=20 +diff --git a/net/rxrpc/ar-output.c b/net/rxrpc/ar-output.c +index 5f22e26..e5bd20f 100644 +--- a/net/rxrpc/ar-output.c ++++ b/net/rxrpc/ar-output.c +@@ -681,9 +681,9 @@ static int rxrpc_send_data(struct kiocb *iocb, sp->hdr.cid =3D call->cid; sp->hdr.callNumber =3D call->call_id; sp->hdr.seq =3D @@ -75503,10 +77173,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-output.c li= nux-3.1.4/net/rxrpc/ar-output.c sp->hdr.type =3D RXRPC_PACKET_TYPE_DATA; sp->hdr.userStatus =3D 0; sp->hdr.securityIndex =3D conn->security_ix; -diff -urNp linux-3.1.4/net/rxrpc/ar-peer.c linux-3.1.4/net/rxrpc/ar-peer= .c ---- linux-3.1.4/net/rxrpc/ar-peer.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/ar-peer.c 2011-11-16 18:39:08.000000000 -0500 -@@ -72,7 +72,7 @@ static struct rxrpc_peer *rxrpc_alloc_pe +diff --git a/net/rxrpc/ar-peer.c b/net/rxrpc/ar-peer.c +index 2754f09..b20e38f 100644 +--- a/net/rxrpc/ar-peer.c ++++ b/net/rxrpc/ar-peer.c +@@ -72,7 +72,7 @@ static struct rxrpc_peer *rxrpc_alloc_peer(struct sock= addr_rxrpc *srx, INIT_LIST_HEAD(&peer->error_targets); spin_lock_init(&peer->lock); atomic_set(&peer->usage, 1); @@ -75515,10 +77186,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-peer.c linu= x-3.1.4/net/rxrpc/ar-peer.c memcpy(&peer->srx, srx, sizeof(*srx)); =20 rxrpc_assess_MTU_size(peer); -diff -urNp linux-3.1.4/net/rxrpc/ar-proc.c linux-3.1.4/net/rxrpc/ar-proc= .c ---- linux-3.1.4/net/rxrpc/ar-proc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/ar-proc.c 2011-11-16 18:39:08.000000000 -0500 -@@ -164,8 +164,8 @@ static int rxrpc_connection_seq_show(str +diff --git a/net/rxrpc/ar-proc.c b/net/rxrpc/ar-proc.c +index 38047f7..9f48511 100644 +--- a/net/rxrpc/ar-proc.c ++++ b/net/rxrpc/ar-proc.c +@@ -164,8 +164,8 @@ static int rxrpc_connection_seq_show(struct seq_file= *seq, void *v) atomic_read(&conn->usage), rxrpc_conn_states[conn->state], key_serial(conn->key), @@ -75529,10 +77201,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-proc.c linu= x-3.1.4/net/rxrpc/ar-proc.c =20 return 0; } -diff -urNp linux-3.1.4/net/rxrpc/ar-transport.c linux-3.1.4/net/rxrpc/ar= -transport.c ---- linux-3.1.4/net/rxrpc/ar-transport.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/rxrpc/ar-transport.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -47,7 +47,7 @@ static struct rxrpc_transport *rxrpc_all +diff --git a/net/rxrpc/ar-transport.c b/net/rxrpc/ar-transport.c +index 92df566..87ec1bf 100644 +--- a/net/rxrpc/ar-transport.c ++++ b/net/rxrpc/ar-transport.c +@@ -47,7 +47,7 @@ static struct rxrpc_transport *rxrpc_alloc_transport(s= truct rxrpc_local *local, spin_lock_init(&trans->client_lock); rwlock_init(&trans->conn_lock); atomic_set(&trans->usage, 1); @@ -75541,10 +77214,11 @@ diff -urNp linux-3.1.4/net/rxrpc/ar-transport.c= linux-3.1.4/net/rxrpc/ar-transpo =20 if (peer->srx.transport.family =3D=3D AF_INET) { switch (peer->srx.transport_type) { -diff -urNp linux-3.1.4/net/rxrpc/rxkad.c linux-3.1.4/net/rxrpc/rxkad.c ---- linux-3.1.4/net/rxrpc/rxkad.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/rxrpc/rxkad.c 2011-11-16 18:40:44.000000000 -0500 -@@ -211,6 +211,8 @@ static int rxkad_secure_packet_encrypt(c +diff --git a/net/rxrpc/rxkad.c b/net/rxrpc/rxkad.c +index 7635107..5000b71 100644 +--- a/net/rxrpc/rxkad.c ++++ b/net/rxrpc/rxkad.c +@@ -211,6 +211,8 @@ static int rxkad_secure_packet_encrypt(const struct = rxrpc_call *call, u16 check; int nsg; =20 @@ -75553,7 +77227,7 @@ diff -urNp linux-3.1.4/net/rxrpc/rxkad.c linux-3.= 1.4/net/rxrpc/rxkad.c sp =3D rxrpc_skb(skb); =20 _enter(""); -@@ -338,6 +340,8 @@ static int rxkad_verify_packet_auth(cons +@@ -338,6 +340,8 @@ static int rxkad_verify_packet_auth(const struct rxr= pc_call *call, u16 check; int nsg; =20 @@ -75562,7 +77236,7 @@ diff -urNp linux-3.1.4/net/rxrpc/rxkad.c linux-3.= 1.4/net/rxrpc/rxkad.c _enter(""); =20 sp =3D rxrpc_skb(skb); -@@ -610,7 +614,7 @@ static int rxkad_issue_challenge(struct=20 +@@ -610,7 +614,7 @@ static int rxkad_issue_challenge(struct rxrpc_connec= tion *conn) =20 len =3D iov[0].iov_len + iov[1].iov_len; =20 @@ -75571,7 +77245,7 @@ diff -urNp linux-3.1.4/net/rxrpc/rxkad.c linux-3.= 1.4/net/rxrpc/rxkad.c _proto("Tx CHALLENGE %%%u", ntohl(hdr.serial)); =20 ret =3D kernel_sendmsg(conn->trans->local->socket, &msg, iov, 2, len); -@@ -660,7 +664,7 @@ static int rxkad_send_response(struct rx +@@ -660,7 +664,7 @@ static int rxkad_send_response(struct rxrpc_connecti= on *conn, =20 len =3D iov[0].iov_len + iov[1].iov_len + iov[2].iov_len; =20 @@ -75580,10 +77254,24 @@ diff -urNp linux-3.1.4/net/rxrpc/rxkad.c linux-= 3.1.4/net/rxrpc/rxkad.c _proto("Tx RESPONSE %%%u", ntohl(hdr->serial)); =20 ret =3D kernel_sendmsg(conn->trans->local->socket, &msg, iov, 3, len); -diff -urNp linux-3.1.4/net/sctp/proc.c linux-3.1.4/net/sctp/proc.c ---- linux-3.1.4/net/sctp/proc.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/sctp/proc.c 2011-11-16 18:40:44.000000000 -0500 -@@ -318,7 +318,8 @@ static int sctp_assocs_seq_show(struct s +diff --git a/net/sctp/auth.c b/net/sctp/auth.c +index 865e68f..bf81204 100644 +--- a/net/sctp/auth.c ++++ b/net/sctp/auth.c +@@ -82,7 +82,7 @@ static struct sctp_auth_bytes *sctp_auth_create_key(__= u32 key_len, gfp_t gfp) + struct sctp_auth_bytes *key; +=20 + /* Verify that we are not going to overflow INT_MAX */ +- if ((INT_MAX - key_len) < sizeof(struct sctp_auth_bytes)) ++ if (key_len > (INT_MAX - sizeof(struct sctp_auth_bytes))) + return NULL; +=20 + /* Allocate the shared key */ +diff --git a/net/sctp/proc.c b/net/sctp/proc.c +index 05a6ce2..c8bf836 100644 +--- a/net/sctp/proc.c ++++ b/net/sctp/proc.c +@@ -318,7 +318,8 @@ static int sctp_assocs_seq_show(struct seq_file *seq= , void *v) seq_printf(seq, "%8pK %8pK %-3d %-3d %-2d %-4d " "%4d %8d %8d %7d %5lu %-5d %5d ", @@ -75593,10 +77281,11 @@ diff -urNp linux-3.1.4/net/sctp/proc.c linux-3.= 1.4/net/sctp/proc.c assoc->state, hash, assoc->assoc_id, assoc->sndbuf_used, -diff -urNp linux-3.1.4/net/sctp/socket.c linux-3.1.4/net/sctp/socket.c ---- linux-3.1.4/net/sctp/socket.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/sctp/socket.c 2011-11-16 18:39:08.000000000 -0500 -@@ -4575,7 +4575,7 @@ static int sctp_getsockopt_peer_addrs(st +diff --git a/net/sctp/socket.c b/net/sctp/socket.c +index 836aa63..d779d7b 100644 +--- a/net/sctp/socket.c ++++ b/net/sctp/socket.c +@@ -4575,7 +4575,7 @@ static int sctp_getsockopt_peer_addrs(struct sock = *sk, int len, addrlen =3D sctp_get_af_specific(temp.sa.sa_family)->sockaddr_len; if (space_left < addrlen) return -ENOMEM; @@ -75605,9 +77294,10 @@ diff -urNp linux-3.1.4/net/sctp/socket.c linux-3= .1.4/net/sctp/socket.c return -EFAULT; to +=3D addrlen; cnt++; -diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/net/socket.c ---- linux-3.1.4/net/socket.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/socket.c 2011-11-16 18:40:44.000000000 -0500 +diff --git a/net/socket.c b/net/socket.c +index ffe92ca..8057b85 100644 +--- a/net/socket.c ++++ b/net/socket.c @@ -88,6 +88,7 @@ #include #include @@ -75625,7 +77315,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c static int sock_no_open(struct inode *irrelevant, struct file *dontcare= ); static ssize_t sock_aio_read(struct kiocb *iocb, const struct iovec *io= v, unsigned long nr_segs, loff_t pos); -@@ -321,7 +324,7 @@ static struct dentry *sockfs_mount(struc +@@ -321,7 +324,7 @@ static struct dentry *sockfs_mount(struct file_syste= m_type *fs_type, &sockfs_dentry_operations, SOCKFS_MAGIC); } =20 @@ -75634,7 +77324,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c =20 static struct file_system_type sock_fs_type =3D { .name =3D "sockfs", -@@ -1187,6 +1190,8 @@ int __sock_create(struct net *net, int f +@@ -1187,6 +1190,8 @@ int __sock_create(struct net *net, int family, int= type, int protocol, return -EAFNOSUPPORT; if (type < 0 || type >=3D SOCK_MAX) return -EINVAL; @@ -75643,7 +77333,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c =20 /* Compatibility. =20 -@@ -1319,6 +1324,16 @@ SYSCALL_DEFINE3(socket, int, family, int +@@ -1319,6 +1324,16 @@ SYSCALL_DEFINE3(socket, int, family, int, type, i= nt, protocol) if (SOCK_NONBLOCK !=3D O_NONBLOCK && (flags & SOCK_NONBLOCK)) flags =3D (flags & ~SOCK_NONBLOCK) | O_NONBLOCK; =20 @@ -75660,7 +77350,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c retval =3D sock_create(family, type, protocol, &sock); if (retval < 0) goto out; -@@ -1431,6 +1446,14 @@ SYSCALL_DEFINE3(bind, int, fd, struct so +@@ -1431,6 +1446,14 @@ SYSCALL_DEFINE3(bind, int, fd, struct sockaddr __= user *, umyaddr, int, addrlen) if (sock) { err =3D move_addr_to_kernel(umyaddr, addrlen, (struct sockaddr *)&add= ress); if (err >=3D 0) { @@ -75675,7 +77365,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c err =3D security_socket_bind(sock, (struct sockaddr *)&address, addrlen); -@@ -1439,6 +1462,7 @@ SYSCALL_DEFINE3(bind, int, fd, struct so +@@ -1439,6 +1462,7 @@ SYSCALL_DEFINE3(bind, int, fd, struct sockaddr __u= ser *, umyaddr, int, addrlen) (struct sockaddr *) &address, addrlen); } @@ -75683,7 +77373,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c fput_light(sock->file, fput_needed); } return err; -@@ -1462,10 +1486,20 @@ SYSCALL_DEFINE2(listen, int, fd, int, ba +@@ -1462,10 +1486,20 @@ SYSCALL_DEFINE2(listen, int, fd, int, backlog) if ((unsigned)backlog > somaxconn) backlog =3D somaxconn; =20 @@ -75704,7 +77394,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c fput_light(sock->file, fput_needed); } return err; -@@ -1509,6 +1543,18 @@ SYSCALL_DEFINE4(accept4, int, fd, struct +@@ -1509,6 +1543,18 @@ SYSCALL_DEFINE4(accept4, int, fd, struct sockaddr= __user *, upeer_sockaddr, newsock->type =3D sock->type; newsock->ops =3D sock->ops; =20 @@ -75723,7 +77413,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c /* * We don't need try_module_get here, as the listening socket (sock) * has the protocol module (sock->ops->owner) held. -@@ -1547,6 +1593,8 @@ SYSCALL_DEFINE4(accept4, int, fd, struct +@@ -1547,6 +1593,8 @@ SYSCALL_DEFINE4(accept4, int, fd, struct sockaddr = __user *, upeer_sockaddr, fd_install(newfd, newfile); err =3D newfd; =20 @@ -75732,7 +77422,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c out_put: fput_light(sock->file, fput_needed); out: -@@ -1579,6 +1627,7 @@ SYSCALL_DEFINE3(connect, int, fd, struct +@@ -1579,6 +1627,7 @@ SYSCALL_DEFINE3(connect, int, fd, struct sockaddr = __user *, uservaddr, int, addrlen) { struct socket *sock; @@ -75740,7 +77430,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c struct sockaddr_storage address; int err, fput_needed; =20 -@@ -1589,6 +1638,17 @@ SYSCALL_DEFINE3(connect, int, fd, struct +@@ -1589,6 +1638,17 @@ SYSCALL_DEFINE3(connect, int, fd, struct sockaddr= __user *, uservaddr, if (err < 0) goto out_put; =20 @@ -75758,7 +77448,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c err =3D security_socket_connect(sock, (struct sockaddr *)&address, addrlen= ); if (err) -@@ -1890,6 +1950,8 @@ static int __sys_sendmsg(struct socket * +@@ -1890,6 +1950,8 @@ static int __sys_sendmsg(struct socket *sock, stru= ct msghdr __user *msg, unsigned char *ctl_buf =3D ctl; int err, ctl_len, iov_size, total_len; =20 @@ -75767,7 +77457,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c err =3D -EFAULT; if (MSG_CMSG_COMPAT & flags) { if (get_compat_msghdr(msg_sys, msg_compat)) -@@ -1950,7 +2012,7 @@ static int __sys_sendmsg(struct socket * +@@ -1950,7 +2012,7 @@ static int __sys_sendmsg(struct socket *sock, stru= ct msghdr __user *msg, * checking falls down on this. */ if (copy_from_user(ctl_buf, @@ -75776,7 +77466,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c ctl_len)) goto out_freectl; msg_sys->msg_control =3D ctl_buf; -@@ -2120,7 +2182,7 @@ static int __sys_recvmsg(struct socket * +@@ -2120,7 +2182,7 @@ static int __sys_recvmsg(struct socket *sock, stru= ct msghdr __user *msg, * kernel msghdr to use the kernel address space) */ =20 @@ -75785,7 +77475,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c uaddr_len =3D COMPAT_NAMELEN(msg); if (MSG_CMSG_COMPAT & flags) { err =3D verify_compat_iovec(msg_sys, iov, -@@ -2748,7 +2810,7 @@ static int ethtool_ioctl(struct net *net +@@ -2748,7 +2810,7 @@ static int ethtool_ioctl(struct net *net, struct c= ompat_ifreq __user *ifr32) } =20 ifr =3D compat_alloc_user_space(buf_size); @@ -75794,7 +77484,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c =20 if (copy_in_user(&ifr->ifr_name, &ifr32->ifr_name, IFNAMSIZ)) return -EFAULT; -@@ -2772,12 +2834,12 @@ static int ethtool_ioctl(struct net *net +@@ -2772,12 +2834,12 @@ static int ethtool_ioctl(struct net *net, struct= compat_ifreq __user *ifr32) offsetof(struct ethtool_rxnfc, fs.ring_cookie)); =20 if (copy_in_user(rxnfc, compat_rxnfc, @@ -75811,7 +77501,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c copy_in_user(&rxnfc->rule_cnt, &compat_rxnfc->rule_cnt, sizeof(rxnfc->rule_cnt))) return -EFAULT; -@@ -2789,12 +2851,12 @@ static int ethtool_ioctl(struct net *net +@@ -2789,12 +2851,12 @@ static int ethtool_ioctl(struct net *net, struct= compat_ifreq __user *ifr32) =20 if (convert_out) { if (copy_in_user(compat_rxnfc, rxnfc, @@ -75828,7 +77518,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c copy_in_user(&compat_rxnfc->rule_cnt, &rxnfc->rule_cnt, sizeof(rxnfc->rule_cnt))) return -EFAULT; -@@ -2864,7 +2926,7 @@ static int bond_ioctl(struct net *net, u +@@ -2864,7 +2926,7 @@ static int bond_ioctl(struct net *net, unsigned in= t cmd, old_fs =3D get_fs(); set_fs(KERNEL_DS); err =3D dev_ioctl(net, cmd, @@ -75837,7 +77527,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c set_fs(old_fs); =20 return err; -@@ -2973,7 +3035,7 @@ static int compat_sioc_ifmap(struct net=20 +@@ -2973,7 +3035,7 @@ static int compat_sioc_ifmap(struct net *net, unsi= gned int cmd, =20 old_fs =3D get_fs(); set_fs(KERNEL_DS); @@ -75846,7 +77536,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c set_fs(old_fs); =20 if (cmd =3D=3D SIOCGIFMAP && !err) { -@@ -3078,7 +3140,7 @@ static int routing_ioctl(struct net *net +@@ -3078,7 +3140,7 @@ static int routing_ioctl(struct net *net, struct s= ocket *sock, ret |=3D __get_user(rtdev, &(ur4->rt_dev)); if (rtdev) { ret |=3D copy_from_user(devname, compat_ptr(rtdev), 15); @@ -75855,7 +77545,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c devname[15] =3D 0; } else r4.rt_dev =3D NULL; -@@ -3318,8 +3380,8 @@ int kernel_getsockopt(struct socket *soc +@@ -3318,8 +3380,8 @@ int kernel_getsockopt(struct socket *sock, int lev= el, int optname, int __user *uoptlen; int err; =20 @@ -75866,7 +77556,7 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4/n= et/socket.c =20 set_fs(KERNEL_DS); if (level =3D=3D SOL_SOCKET) -@@ -3339,7 +3401,7 @@ int kernel_setsockopt(struct socket *soc +@@ -3339,7 +3401,7 @@ int kernel_setsockopt(struct socket *sock, int lev= el, int optname, char __user *uoptval; int err; =20 @@ -75875,10 +77565,11 @@ diff -urNp linux-3.1.4/net/socket.c linux-3.1.4= /net/socket.c =20 set_fs(KERNEL_DS); if (level =3D=3D SOL_SOCKET) -diff -urNp linux-3.1.4/net/sunrpc/sched.c linux-3.1.4/net/sunrpc/sched.c ---- linux-3.1.4/net/sunrpc/sched.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/sunrpc/sched.c 2011-11-16 18:39:08.000000000 -0500 -@@ -238,9 +238,9 @@ static int rpc_wait_bit_killable(void *w +diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c +index d12ffa5..0b5a6e2 100644 +--- a/net/sunrpc/sched.c ++++ b/net/sunrpc/sched.c +@@ -238,9 +238,9 @@ static int rpc_wait_bit_killable(void *word) #ifdef RPC_DEBUG static void rpc_task_set_debuginfo(struct rpc_task *task) { @@ -75890,10 +77581,11 @@ diff -urNp linux-3.1.4/net/sunrpc/sched.c linux= -3.1.4/net/sunrpc/sched.c } #else static inline void rpc_task_set_debuginfo(struct rpc_task *task) -diff -urNp linux-3.1.4/net/sunrpc/svcsock.c linux-3.1.4/net/sunrpc/svcso= ck.c ---- linux-3.1.4/net/sunrpc/svcsock.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/sunrpc/svcsock.c 2011-11-16 18:39:08.000000000 -0500 -@@ -394,7 +394,7 @@ static int svc_partial_recvfrom(struct s +diff --git a/net/sunrpc/svcsock.c b/net/sunrpc/svcsock.c +index 767d494..fe17e9d 100644 +--- a/net/sunrpc/svcsock.c ++++ b/net/sunrpc/svcsock.c +@@ -394,7 +394,7 @@ static int svc_partial_recvfrom(struct svc_rqst *rqs= tp, int buflen, unsigned int base) { size_t save_iovlen; @@ -75902,10 +77594,11 @@ diff -urNp linux-3.1.4/net/sunrpc/svcsock.c lin= ux-3.1.4/net/sunrpc/svcsock.c unsigned int i; int ret; =20 -diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma.c linux-3.1.4/net/su= nrpc/xprtrdma/svc_rdma.c ---- linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma.c 2011-11-16 18:39:08.00000= 0000 -0500 -@@ -61,15 +61,15 @@ unsigned int svcrdma_max_req_size =3D RPCR +diff --git a/net/sunrpc/xprtrdma/svc_rdma.c b/net/sunrpc/xprtrdma/svc_rd= ma.c +index 09af4fa..77110a9 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma.c ++++ b/net/sunrpc/xprtrdma/svc_rdma.c +@@ -61,15 +61,15 @@ unsigned int svcrdma_max_req_size =3D RPCRDMA_MAX_RE= Q_SIZE; static unsigned int min_max_inline =3D 4096; static unsigned int max_max_inline =3D 65536; =20 @@ -75930,7 +77623,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma.c linux-3.1.4/net/sunrpc/xpr =20 /* Temporary NFS request map and context caches */ struct kmem_cache *svc_rdma_map_cachep; -@@ -109,7 +109,7 @@ static int read_reset_stat(ctl_table *ta +@@ -109,7 +109,7 @@ static int read_reset_stat(ctl_table *table, int wri= te, len -=3D *ppos; if (len > *lenp) len =3D *lenp; @@ -75939,7 +77632,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma.c linux-3.1.4/net/sunrpc/xpr return -EFAULT; *lenp =3D len; *ppos +=3D len; -@@ -150,63 +150,63 @@ static ctl_table svcrdma_parm_table[] =3D=20 +@@ -150,63 +150,63 @@ static ctl_table svcrdma_parm_table[] =3D { { .procname =3D "rdma_stat_read", .data =3D &rdma_stat_read, @@ -76012,9 +77705,10 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_r= dma.c linux-3.1.4/net/sunrpc/xpr .mode =3D 0644, .proc_handler =3D read_reset_stat, }, -diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c linux-3.1= .4/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c ---- linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c 2011-11-11 15:19= :27.000000000 -0500 -+++ linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c 2011-11-16 18:39= :08.000000000 -0500 +diff --git a/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c b/net/sunrpc/xprtrd= ma/svc_rdma_recvfrom.c +index df67211..c354b13 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c ++++ b/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c @@ -499,7 +499,7 @@ next_sge: svc_rdma_put_context(ctxt, 0); goto out; @@ -76024,7 +77718,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma_recvfrom.c linux-3.1.4/net/s =20 if (read_wr.num_sge < chl_map->ch[ch_no].count) { chl_map->ch[ch_no].count -=3D read_wr.num_sge; -@@ -609,7 +609,7 @@ int svc_rdma_recvfrom(struct svc_rqst *r +@@ -609,7 +609,7 @@ int svc_rdma_recvfrom(struct svc_rqst *rqstp) dto_q); list_del_init(&ctxt->dto_q); } else { @@ -76033,7 +77727,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma_recvfrom.c linux-3.1.4/net/s clear_bit(XPT_DATA, &xprt->xpt_flags); ctxt =3D NULL; } -@@ -629,7 +629,7 @@ int svc_rdma_recvfrom(struct svc_rqst *r +@@ -629,7 +629,7 @@ int svc_rdma_recvfrom(struct svc_rqst *rqstp) dprintk("svcrdma: processing ctxt=3D%p on xprt=3D%p, rqstp=3D%p, statu= s=3D%d\n", ctxt, rdma_xprt, rqstp, ctxt->wc_status); BUG_ON(ctxt->wc_status !=3D IB_WC_SUCCESS); @@ -76042,10 +77736,11 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_= rdma_recvfrom.c linux-3.1.4/net/s =20 /* Build up the XDR from the receive buffers. */ rdma_build_arg_xdr(rqstp, ctxt, ctxt->byte_len); -diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_sendto.c linux-3.1.4= /net/sunrpc/xprtrdma/svc_rdma_sendto.c ---- linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_sendto.c 2011-11-11 15:19:2= 7.000000000 -0500 -+++ linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_sendto.c 2011-11-16 18:39:0= 8.000000000 -0500 -@@ -362,7 +362,7 @@ static int send_write(struct svcxprt_rdm +diff --git a/net/sunrpc/xprtrdma/svc_rdma_sendto.c b/net/sunrpc/xprtrdma= /svc_rdma_sendto.c +index 249a835..fb2794b 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma_sendto.c ++++ b/net/sunrpc/xprtrdma/svc_rdma_sendto.c +@@ -362,7 +362,7 @@ static int send_write(struct svcxprt_rdma *xprt, str= uct svc_rqst *rqstp, write_wr.wr.rdma.remote_addr =3D to; =20 /* Post It */ @@ -76054,10 +77749,11 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_= rdma_sendto.c linux-3.1.4/net/sun if (svc_rdma_send(xprt, &write_wr)) goto err; return 0; -diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_transport.c linux-3.= 1.4/net/sunrpc/xprtrdma/svc_rdma_transport.c ---- linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_transport.c 2011-11-11 15:1= 9:27.000000000 -0500 -+++ linux-3.1.4/net/sunrpc/xprtrdma/svc_rdma_transport.c 2011-11-16 18:3= 9:08.000000000 -0500 -@@ -299,7 +299,7 @@ static void rq_cq_reap(struct svcxprt_rd +diff --git a/net/sunrpc/xprtrdma/svc_rdma_transport.c b/net/sunrpc/xprtr= dma/svc_rdma_transport.c +index a385430..32254ea 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma_transport.c ++++ b/net/sunrpc/xprtrdma/svc_rdma_transport.c +@@ -299,7 +299,7 @@ static void rq_cq_reap(struct svcxprt_rdma *xprt) return; =20 ib_req_notify_cq(xprt->sc_rq_cq, IB_CQ_NEXT_COMP); @@ -76066,7 +77762,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma_transport.c linux-3.1.4/net/ =20 while ((ret =3D ib_poll_cq(xprt->sc_rq_cq, 1, &wc)) > 0) { ctxt =3D (struct svc_rdma_op_ctxt *)(unsigned long)wc.wr_id; -@@ -321,7 +321,7 @@ static void rq_cq_reap(struct svcxprt_rd +@@ -321,7 +321,7 @@ static void rq_cq_reap(struct svcxprt_rdma *xprt) } =20 if (ctxt) @@ -76075,7 +77771,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma_transport.c linux-3.1.4/net/ =20 set_bit(XPT_DATA, &xprt->sc_xprt.xpt_flags); /* -@@ -393,7 +393,7 @@ static void sq_cq_reap(struct svcxprt_rd +@@ -393,7 +393,7 @@ static void sq_cq_reap(struct svcxprt_rdma *xprt) return; =20 ib_req_notify_cq(xprt->sc_sq_cq, IB_CQ_NEXT_COMP); @@ -76084,7 +77780,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma_transport.c linux-3.1.4/net/ while ((ret =3D ib_poll_cq(cq, 1, &wc)) > 0) { if (wc.status !=3D IB_WC_SUCCESS) /* Close the transport */ -@@ -411,7 +411,7 @@ static void sq_cq_reap(struct svcxprt_rd +@@ -411,7 +411,7 @@ static void sq_cq_reap(struct svcxprt_rdma *xprt) } =20 if (ctxt) @@ -76093,7 +77789,7 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_rd= ma_transport.c linux-3.1.4/net/ } =20 static void sq_comp_handler(struct ib_cq *cq, void *cq_context) -@@ -1273,7 +1273,7 @@ int svc_rdma_send(struct svcxprt_rdma *x +@@ -1273,7 +1273,7 @@ int svc_rdma_send(struct svcxprt_rdma *xprt, struc= t ib_send_wr *wr) spin_lock_bh(&xprt->sc_lock); if (xprt->sc_sq_depth < atomic_read(&xprt->sc_sq_count) + wr_count) { spin_unlock_bh(&xprt->sc_lock); @@ -76102,10 +77798,11 @@ diff -urNp linux-3.1.4/net/sunrpc/xprtrdma/svc_= rdma_transport.c linux-3.1.4/net/ =20 /* See if we can opportunistically reap SQ WR to make room */ sq_cq_reap(xprt); -diff -urNp linux-3.1.4/net/sysctl_net.c linux-3.1.4/net/sysctl_net.c ---- linux-3.1.4/net/sysctl_net.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/sysctl_net.c 2011-11-16 18:40:44.000000000 -0500 -@@ -46,7 +46,7 @@ static int net_ctl_permissions(struct ct +diff --git a/net/sysctl_net.c b/net/sysctl_net.c +index ca84212..3aa338f 100644 +--- a/net/sysctl_net.c ++++ b/net/sysctl_net.c +@@ -46,7 +46,7 @@ static int net_ctl_permissions(struct ctl_table_root *= root, struct ctl_table *table) { /* Allow network administrator to have same access as root. */ @@ -76114,10 +77811,11 @@ diff -urNp linux-3.1.4/net/sysctl_net.c linux-3= .1.4/net/sysctl_net.c int mode =3D (table->mode >> 6) & 7; return (mode << 6) | (mode << 3) | mode; } -diff -urNp linux-3.1.4/net/tipc/link.c linux-3.1.4/net/tipc/link.c ---- linux-3.1.4/net/tipc/link.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/tipc/link.c 2011-11-16 18:39:08.000000000 -0500 -@@ -1170,7 +1170,7 @@ static int link_send_sections_long(struc +diff --git a/net/tipc/link.c b/net/tipc/link.c +index f89570c..016cf63 100644 +--- a/net/tipc/link.c ++++ b/net/tipc/link.c +@@ -1170,7 +1170,7 @@ static int link_send_sections_long(struct tipc_por= t *sender, struct tipc_msg fragm_hdr; struct sk_buff *buf, *buf_chain, *prev; u32 fragm_crs, fragm_rest, hsz, sect_rest; @@ -76144,10 +77842,11 @@ diff -urNp linux-3.1.4/net/tipc/link.c linux-3.= 1.4/net/tipc/link.c sect_crs +=3D sz; sect_rest -=3D sz; fragm_crs +=3D sz; -diff -urNp linux-3.1.4/net/tipc/msg.c linux-3.1.4/net/tipc/msg.c ---- linux-3.1.4/net/tipc/msg.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/tipc/msg.c 2011-11-16 18:39:08.000000000 -0500 -@@ -99,7 +99,7 @@ int tipc_msg_build(struct tipc_msg *hdr, +diff --git a/net/tipc/msg.c b/net/tipc/msg.c +index 83d5096..dcba497 100644 +--- a/net/tipc/msg.c ++++ b/net/tipc/msg.c +@@ -99,7 +99,7 @@ int tipc_msg_build(struct tipc_msg *hdr, struct iovec = const *msg_sect, msg_sect[cnt].iov_len); else skb_copy_to_linear_data_offset(*buf, pos, @@ -76156,10 +77855,11 @@ diff -urNp linux-3.1.4/net/tipc/msg.c linux-3.1= .4/net/tipc/msg.c msg_sect[cnt].iov_len); pos +=3D msg_sect[cnt].iov_len; } -diff -urNp linux-3.1.4/net/tipc/subscr.c linux-3.1.4/net/tipc/subscr.c ---- linux-3.1.4/net/tipc/subscr.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/tipc/subscr.c 2011-11-16 18:39:08.000000000 -0500 -@@ -101,7 +101,7 @@ static void subscr_send_event(struct sub +diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c +index 6cf7268..7a488ce 100644 +--- a/net/tipc/subscr.c ++++ b/net/tipc/subscr.c +@@ -101,7 +101,7 @@ static void subscr_send_event(struct subscription *s= ub, { struct iovec msg_sect; =20 @@ -76168,10 +77868,11 @@ diff -urNp linux-3.1.4/net/tipc/subscr.c linux-= 3.1.4/net/tipc/subscr.c msg_sect.iov_len =3D sizeof(struct tipc_event); =20 sub->evt.event =3D htohl(event, sub->swap); -diff -urNp linux-3.1.4/net/unix/af_unix.c linux-3.1.4/net/unix/af_unix.c ---- linux-3.1.4/net/unix/af_unix.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/unix/af_unix.c 2011-11-16 19:17:17.000000000 -0500 -@@ -767,6 +767,12 @@ static struct sock *unix_find_other(stru +diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c +index ec68e1c..fdd792f 100644 +--- a/net/unix/af_unix.c ++++ b/net/unix/af_unix.c +@@ -767,6 +767,12 @@ static struct sock *unix_find_other(struct net *net= , err =3D -ECONNREFUSED; if (!S_ISSOCK(inode->i_mode)) goto put_fail; @@ -76184,7 +77885,7 @@ diff -urNp linux-3.1.4/net/unix/af_unix.c linux-3= .1.4/net/unix/af_unix.c u =3D unix_find_socket_byinode(inode); if (!u) goto put_fail; -@@ -787,6 +793,13 @@ static struct sock *unix_find_other(stru +@@ -787,6 +793,13 @@ static struct sock *unix_find_other(struct net *net= , if (u) { struct dentry *dentry; dentry =3D unix_sk(u)->dentry; @@ -76198,7 +77899,7 @@ diff -urNp linux-3.1.4/net/unix/af_unix.c linux-3= .1.4/net/unix/af_unix.c if (dentry) touch_atime(unix_sk(u)->mnt, dentry); } else -@@ -869,11 +882,18 @@ static int unix_bind(struct socket *sock +@@ -869,11 +882,18 @@ static int unix_bind(struct socket *sock, struct s= ockaddr *uaddr, int addr_len) err =3D security_path_mknod(&path, dentry, mode, 0); if (err) goto out_mknod_drop_write; @@ -76217,9 +77918,10 @@ diff -urNp linux-3.1.4/net/unix/af_unix.c linux-= 3.1.4/net/unix/af_unix.c mutex_unlock(&path.dentry->d_inode->i_mutex); dput(path.dentry); path.dentry =3D dentry; -diff -urNp linux-3.1.4/net/wireless/core.h linux-3.1.4/net/wireless/core= .h ---- linux-3.1.4/net/wireless/core.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/wireless/core.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/net/wireless/core.h b/net/wireless/core.h +index 8672e02..48782dd 100644 +--- a/net/wireless/core.h ++++ b/net/wireless/core.h @@ -27,7 +27,7 @@ struct cfg80211_registered_device { struct mutex mtx; =20 @@ -76229,10 +77931,11 @@ diff -urNp linux-3.1.4/net/wireless/core.h linu= x-3.1.4/net/wireless/core.h struct rfkill *rfkill; struct work_struct rfkill_sync; =20 -diff -urNp linux-3.1.4/net/wireless/wext-core.c linux-3.1.4/net/wireless= /wext-core.c ---- linux-3.1.4/net/wireless/wext-core.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/net/wireless/wext-core.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -746,8 +746,7 @@ static int ioctl_standard_iw_point(struc +diff --git a/net/wireless/wext-core.c b/net/wireless/wext-core.c +index fdbc23c..212d53e 100644 +--- a/net/wireless/wext-core.c ++++ b/net/wireless/wext-core.c +@@ -746,8 +746,7 @@ static int ioctl_standard_iw_point(struct iw_point *= iwp, unsigned int cmd, */ =20 /* Support for very large requests */ @@ -76242,7 +77945,7 @@ diff -urNp linux-3.1.4/net/wireless/wext-core.c l= inux-3.1.4/net/wireless/wext-co /* Allow userspace to GET more than max so * we can support any size GET requests. * There is still a limit : -ENOMEM. -@@ -784,22 +783,6 @@ static int ioctl_standard_iw_point(struc +@@ -784,22 +783,6 @@ static int ioctl_standard_iw_point(struct iw_point = *iwp, unsigned int cmd, } } =20 @@ -76265,10 +77968,11 @@ diff -urNp linux-3.1.4/net/wireless/wext-core.c= linux-3.1.4/net/wireless/wext-co err =3D handler(dev, info, (union iwreq_data *) iwp, extra); =20 iwp->length +=3D essid_compat; -diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c linux-3.1.4/net/xfrm/xfrm_= policy.c ---- linux-3.1.4/net/xfrm/xfrm_policy.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/net/xfrm/xfrm_policy.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -299,7 +299,7 @@ static void xfrm_policy_kill(struct xfrm +diff --git a/net/xfrm/xfrm_policy.c b/net/xfrm/xfrm_policy.c +index 552df27..8e7f238 100644 +--- a/net/xfrm/xfrm_policy.c ++++ b/net/xfrm/xfrm_policy.c +@@ -299,7 +299,7 @@ static void xfrm_policy_kill(struct xfrm_policy *pol= icy) { policy->walk.dead =3D 1; =20 @@ -76277,7 +77981,7 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c lin= ux-3.1.4/net/xfrm/xfrm_policy.c =20 if (del_timer(&policy->timer)) xfrm_pol_put(policy); -@@ -583,7 +583,7 @@ int xfrm_policy_insert(int dir, struct x +@@ -583,7 +583,7 @@ int xfrm_policy_insert(int dir, struct xfrm_policy *= policy, int excl) hlist_add_head(&policy->bydst, chain); xfrm_pol_hold(policy); net->xfrm.policy_count[dir]++; @@ -76295,7 +77999,7 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c lin= ux-3.1.4/net/xfrm/xfrm_policy.c xfrm_dst_alloc_copy(void **target, const void *src, int size) { if (!*target) { -@@ -1542,7 +1542,7 @@ xfrm_dst_alloc_copy(void **target, const +@@ -1542,7 +1542,7 @@ xfrm_dst_alloc_copy(void **target, const void *src= , int size) return 0; } =20 @@ -76304,7 +78008,7 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c lin= ux-3.1.4/net/xfrm/xfrm_policy.c xfrm_dst_update_parent(struct dst_entry *dst, const struct xfrm_selecto= r *sel) { #ifdef CONFIG_XFRM_SUB_POLICY -@@ -1554,7 +1554,7 @@ xfrm_dst_update_parent(struct dst_entry=20 +@@ -1554,7 +1554,7 @@ xfrm_dst_update_parent(struct dst_entry *dst, cons= t struct xfrm_selector *sel) #endif } =20 @@ -76313,7 +78017,7 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c lin= ux-3.1.4/net/xfrm/xfrm_policy.c xfrm_dst_update_origin(struct dst_entry *dst, const struct flowi *fl) { #ifdef CONFIG_XFRM_SUB_POLICY -@@ -1648,7 +1648,7 @@ xfrm_resolve_and_create_bundle(struct xf +@@ -1648,7 +1648,7 @@ xfrm_resolve_and_create_bundle(struct xfrm_policy = **pols, int num_pols, =20 xdst->num_pols =3D num_pols; memcpy(xdst->pols, pols, sizeof(struct xfrm_policy*) * num_pols); @@ -76322,7 +78026,7 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c lin= ux-3.1.4/net/xfrm/xfrm_policy.c =20 return xdst; } -@@ -2335,7 +2335,7 @@ static int xfrm_bundle_ok(struct xfrm_ds +@@ -2335,7 +2335,7 @@ static int xfrm_bundle_ok(struct xfrm_dst *first) if (xdst->xfrm_genid !=3D dst->xfrm->genid) return 0; if (xdst->num_pols > 0 && @@ -76331,7 +78035,7 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c lin= ux-3.1.4/net/xfrm/xfrm_policy.c return 0; =20 mtu =3D dst_mtu(dst->child); -@@ -2870,7 +2870,7 @@ static int xfrm_policy_migrate(struct xf +@@ -2870,7 +2870,7 @@ static int xfrm_policy_migrate(struct xfrm_policy = *pol, sizeof(pol->xfrm_vec[i].saddr)); pol->xfrm_vec[i].encap_family =3D mp->new_family; /* flush bundles */ @@ -76340,10 +78044,11 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_policy.c l= inux-3.1.4/net/xfrm/xfrm_policy.c } } =20 -diff -urNp linux-3.1.4/net/xfrm/xfrm_user.c linux-3.1.4/net/xfrm/xfrm_us= er.c ---- linux-3.1.4/net/xfrm/xfrm_user.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/net/xfrm/xfrm_user.c 2011-11-16 18:40:44.000000000 -0500 -@@ -1394,6 +1394,8 @@ static int copy_to_user_tmpl(struct xfrm +diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c +index 0256b8a..9341ef6 100644 +--- a/net/xfrm/xfrm_user.c ++++ b/net/xfrm/xfrm_user.c +@@ -1394,6 +1394,8 @@ static int copy_to_user_tmpl(struct xfrm_policy *x= p, struct sk_buff *skb) struct xfrm_user_tmpl vec[XFRM_MAX_DEPTH]; int i; =20 @@ -76352,7 +78057,7 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_user.c linux= -3.1.4/net/xfrm/xfrm_user.c if (xp->xfrm_nr =3D=3D 0) return 0; =20 -@@ -2062,6 +2064,8 @@ static int xfrm_do_migrate(struct sk_buf +@@ -2062,6 +2064,8 @@ static int xfrm_do_migrate(struct sk_buff *skb, st= ruct nlmsghdr *nlh, int err; int n =3D 0; =20 @@ -76361,10 +78066,58 @@ diff -urNp linux-3.1.4/net/xfrm/xfrm_user.c lin= ux-3.1.4/net/xfrm/xfrm_user.c if (attrs[XFRMA_MIGRATE] =3D=3D NULL) return -EINVAL; =20 -diff -urNp linux-3.1.4/scripts/basic/fixdep.c linux-3.1.4/scripts/basic/= fixdep.c ---- linux-3.1.4/scripts/basic/fixdep.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/scripts/basic/fixdep.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -161,7 +161,7 @@ static unsigned int strhash(const char * +diff --git a/scripts/Makefile.build b/scripts/Makefile.build +index a0fd502..a8e6e83 100644 +--- a/scripts/Makefile.build ++++ b/scripts/Makefile.build +@@ -109,7 +109,7 @@ endif + endif +=20 + # Do not include host rules unless needed +-ifneq ($(hostprogs-y)$(hostprogs-m),) ++ifneq ($(hostprogs-y)$(hostprogs-m)$(hostlibs-y)$(hostlibs-m),) + include scripts/Makefile.host + endif +=20 +diff --git a/scripts/Makefile.clean b/scripts/Makefile.clean +index 686cb0d..9d653bf 100644 +--- a/scripts/Makefile.clean ++++ b/scripts/Makefile.clean +@@ -43,7 +43,8 @@ subdir-ymn :=3D $(addprefix $(obj)/,$(subdir-ymn)) + __clean-files :=3D $(extra-y) $(always) \ + $(targets) $(clean-files) \ + $(host-progs) \ +- $(hostprogs-y) $(hostprogs-m) $(hostprogs-) ++ $(hostprogs-y) $(hostprogs-m) $(hostprogs-) \ ++ $(hostlibs-y) $(hostlibs-m) $(hostlibs-) +=20 + __clean-files :=3D $(filter-out $(no-clean-files), $(__clean-files)) +=20 +diff --git a/scripts/Makefile.host b/scripts/Makefile.host +index 1ac414f..a1c1451 100644 +--- a/scripts/Makefile.host ++++ b/scripts/Makefile.host +@@ -31,6 +31,7 @@ + # Note: Shared libraries consisting of C++ files are not supported +=20 + __hostprogs :=3D $(sort $(hostprogs-y) $(hostprogs-m)) ++__hostlibs :=3D $(sort $(hostlibs-y) $(hostlibs-m)) +=20 + # C code + # Executables compiled from a single .c file +@@ -54,6 +55,7 @@ host-cxxobjs :=3D $(sort $(foreach m,$(host-cxxmulti),= $($(m)-cxxobjs))) + # Shared libaries (only .c supported) + # Shared libraries (.so) - all .so files referenced in "xxx-objs" + host-cshlib :=3D $(sort $(filter %.so, $(host-cobjs))) ++host-cshlib +=3D $(sort $(filter %.so, $(__hostlibs))) + # Remove .so files from "xxx-objs" + host-cobjs :=3D $(filter-out %.so,$(host-cobjs)) +=20 +diff --git a/scripts/basic/fixdep.c b/scripts/basic/fixdep.c +index 291228e..6c55203 100644 +--- a/scripts/basic/fixdep.c ++++ b/scripts/basic/fixdep.c +@@ -161,7 +161,7 @@ static unsigned int strhash(const char *str, unsigne= d int sz) /* * Lookup a value in the configuration string. */ @@ -76386,7 +78139,7 @@ diff -urNp linux-3.1.4/scripts/basic/fixdep.c lin= ux-3.1.4/scripts/basic/fixdep.c =20 if (is_defined_config(m, slen, hash)) return; -@@ -235,9 +235,9 @@ static void use_config(const char *m, in +@@ -235,9 +235,9 @@ static void use_config(const char *m, int slen) =20 static void parse_config_file(const char *map, size_t len) { @@ -76407,60 +78160,19 @@ diff -urNp linux-3.1.4/scripts/basic/fixdep.c l= inux-3.1.4/scripts/basic/fixdep.c =20 if (*p !=3D INT_CONF) { fprintf(stderr, "fixdep: sizeof(int) !=3D 4 or wrong endianess? %#x\n= ", -diff -urNp linux-3.1.4/scripts/gcc-plugin.sh linux-3.1.4/scripts/gcc-plu= gin.sh ---- linux-3.1.4/scripts/gcc-plugin.sh 1969-12-31 19:00:00.000000000 -050= 0 -+++ linux-3.1.4/scripts/gcc-plugin.sh 2011-11-20 19:21:53.000000000 -050= 0 +diff --git a/scripts/gcc-plugin.sh b/scripts/gcc-plugin.sh +new file mode 100644 +index 0000000..8729101 +--- /dev/null ++++ b/scripts/gcc-plugin.sh @@ -0,0 +1,2 @@ +#!/bin/sh +echo -e "#include \"gcc-plugin.h\"\n#include \"tree.h\"\n#include \"tm.= h\"\n#include \"rtl.h\"" | $1 -x c -shared - -o /dev/null -I`$2 -print-fi= le-name=3Dplugin`/include >/dev/null 2>&1 && echo "y" -diff -urNp linux-3.1.4/scripts/Makefile.build linux-3.1.4/scripts/Makefi= le.build ---- linux-3.1.4/scripts/Makefile.build 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/scripts/Makefile.build 2011-11-16 18:40:44.000000000 -05= 00 -@@ -109,7 +109,7 @@ endif - endif -=20 - # Do not include host rules unless needed --ifneq ($(hostprogs-y)$(hostprogs-m),) -+ifneq ($(hostprogs-y)$(hostprogs-m)$(hostlibs-y)$(hostlibs-m),) - include scripts/Makefile.host - endif -=20 -diff -urNp linux-3.1.4/scripts/Makefile.clean linux-3.1.4/scripts/Makefi= le.clean ---- linux-3.1.4/scripts/Makefile.clean 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/scripts/Makefile.clean 2011-11-16 18:39:08.000000000 -05= 00 -@@ -43,7 +43,8 @@ subdir-ymn :=3D $(addprefix $(obj)/,$(subd - __clean-files :=3D $(extra-y) $(always) \ - $(targets) $(clean-files) \ - $(host-progs) \ -- $(hostprogs-y) $(hostprogs-m) $(hostprogs-) -+ $(hostprogs-y) $(hostprogs-m) $(hostprogs-) \ -+ $(hostlibs-y) $(hostlibs-m) $(hostlibs-) -=20 - __clean-files :=3D $(filter-out $(no-clean-files), $(__clean-files)) -=20 -diff -urNp linux-3.1.4/scripts/Makefile.host linux-3.1.4/scripts/Makefil= e.host ---- linux-3.1.4/scripts/Makefile.host 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/scripts/Makefile.host 2011-11-16 18:39:08.000000000 -050= 0 -@@ -31,6 +31,7 @@ - # Note: Shared libraries consisting of C++ files are not supported -=20 - __hostprogs :=3D $(sort $(hostprogs-y) $(hostprogs-m)) -+__hostlibs :=3D $(sort $(hostlibs-y) $(hostlibs-m)) -=20 - # C code - # Executables compiled from a single .c file -@@ -54,6 +55,7 @@ host-cxxobjs :=3D $(sort $(foreach m,$(hos - # Shared libaries (only .c supported) - # Shared libraries (.so) - all .so files referenced in "xxx-objs" - host-cshlib :=3D $(sort $(filter %.so, $(host-cobjs))) -+host-cshlib +=3D $(sort $(filter %.so, $(__hostlibs))) - # Remove .so files from "xxx-objs" - host-cobjs :=3D $(filter-out %.so,$(host-cobjs)) -=20 -diff -urNp linux-3.1.4/scripts/mod/file2alias.c linux-3.1.4/scripts/mod/= file2alias.c ---- linux-3.1.4/scripts/mod/file2alias.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/scripts/mod/file2alias.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -72,7 +72,7 @@ static void device_id_check(const char * +diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c +index e26e2fb..f84937b 100644 +--- a/scripts/mod/file2alias.c ++++ b/scripts/mod/file2alias.c +@@ -72,7 +72,7 @@ static void device_id_check(const char *modname, const= char *device_id, unsigned long size, unsigned long id_size, void *symval) { @@ -76469,7 +78181,7 @@ diff -urNp linux-3.1.4/scripts/mod/file2alias.c l= inux-3.1.4/scripts/mod/file2ali =20 if (size % id_size || size < id_size) { if (cross_build !=3D 0) -@@ -102,7 +102,7 @@ static void device_id_check(const char * +@@ -102,7 +102,7 @@ static void device_id_check(const char *modname, con= st char *device_id, /* USB is special because the bcdDevice can be matched against a numeri= c range */ /* Looks like "usb:vNpNdNdcNdscNdpNicNiscNipN" */ static void do_usb_entry(struct usb_device_id *id, @@ -76478,7 +78190,7 @@ diff -urNp linux-3.1.4/scripts/mod/file2alias.c l= inux-3.1.4/scripts/mod/file2ali unsigned char range_lo, unsigned char range_hi, unsigned char max, struct module *mod) { -@@ -203,7 +203,7 @@ static void do_usb_entry_multi(struct us +@@ -203,7 +203,7 @@ static void do_usb_entry_multi(struct usb_device_id = *id, struct module *mod) { unsigned int devlo, devhi; unsigned char chi, clo, max; @@ -76487,7 +78199,7 @@ diff -urNp linux-3.1.4/scripts/mod/file2alias.c l= inux-3.1.4/scripts/mod/file2ali =20 id->match_flags =3D TO_NATIVE(id->match_flags); id->idVendor =3D TO_NATIVE(id->idVendor); -@@ -437,7 +437,7 @@ static void do_pnp_device_entry(void *sy +@@ -437,7 +437,7 @@ static void do_pnp_device_entry(void *symval, unsign= ed long size, for (i =3D 0; i < count; i++) { const char *id =3D (char *)devs[i].id; char acpi_id[sizeof(devs[0].id)]; @@ -76496,7 +78208,7 @@ diff -urNp linux-3.1.4/scripts/mod/file2alias.c l= inux-3.1.4/scripts/mod/file2ali =20 buf_printf(&mod->dev_table_buf, "MODULE_ALIAS(\"pnp:d%s*\");\n", id); -@@ -467,7 +467,7 @@ static void do_pnp_card_entries(void *sy +@@ -467,7 +467,7 @@ static void do_pnp_card_entries(void *symval, unsign= ed long size, =20 for (j =3D 0; j < PNP_MAX_DEVICES; j++) { const char *id =3D (char *)card->devs[j].id; @@ -76505,7 +78217,7 @@ diff -urNp linux-3.1.4/scripts/mod/file2alias.c l= inux-3.1.4/scripts/mod/file2ali int dup =3D 0; =20 if (!id[0]) -@@ -493,7 +493,7 @@ static void do_pnp_card_entries(void *sy +@@ -493,7 +493,7 @@ static void do_pnp_card_entries(void *symval, unsign= ed long size, /* add an individual alias for every device entry */ if (!dup) { char acpi_id[sizeof(card->devs[0].id)]; @@ -76514,7 +78226,7 @@ diff -urNp linux-3.1.4/scripts/mod/file2alias.c l= inux-3.1.4/scripts/mod/file2ali =20 buf_printf(&mod->dev_table_buf, "MODULE_ALIAS(\"pnp:d%s*\");\n", id); -@@ -786,7 +786,7 @@ static void dmi_ascii_filter(char *d, co +@@ -786,7 +786,7 @@ static void dmi_ascii_filter(char *d, const char *s) static int do_dmi_entry(const char *filename, struct dmi_system_id *id, char *alias) { @@ -76523,9 +78235,10 @@ diff -urNp linux-3.1.4/scripts/mod/file2alias.c = linux-3.1.4/scripts/mod/file2ali =20 sprintf(alias, "dmi*"); =20 -diff -urNp linux-3.1.4/scripts/mod/modpost.c linux-3.1.4/scripts/mod/mod= post.c ---- linux-3.1.4/scripts/mod/modpost.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/scripts/mod/modpost.c 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c +index a509ff8..5822633 100644 +--- a/scripts/mod/modpost.c ++++ b/scripts/mod/modpost.c @@ -919,6 +919,7 @@ enum mismatch { ANY_INIT_TO_ANY_EXIT, ANY_EXIT_TO_ANY_INIT, @@ -76534,7 +78247,7 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.c linu= x-3.1.4/scripts/mod/modpost.c }; =20 struct sectioncheck { -@@ -1027,6 +1028,12 @@ const struct sectioncheck sectioncheck[] +@@ -1027,6 +1028,12 @@ const struct sectioncheck sectioncheck[] =3D { .tosec =3D { INIT_SECTIONS, EXIT_SECTIONS, NULL }, .mismatch =3D EXPORT_TO_INIT_EXIT, .symbol_white_list =3D { DEFAULT_SYMBOL_WHITE_LIST, NULL }, @@ -76547,7 +78260,7 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.c linu= x-3.1.4/scripts/mod/modpost.c } }; =20 -@@ -1149,10 +1156,10 @@ static Elf_Sym *find_elf_symbol(struct e +@@ -1149,10 +1156,10 @@ static Elf_Sym *find_elf_symbol(struct elf_info = *elf, Elf64_Sword addr, continue; if (ELF_ST_TYPE(sym->st_info) =3D=3D STT_SECTION) continue; @@ -76560,7 +78273,7 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.c linu= x-3.1.4/scripts/mod/modpost.c if (d < 0) d =3D addr - sym->st_value; if (d < distance) { -@@ -1431,6 +1438,14 @@ static void report_sec_mismatch(const ch +@@ -1431,6 +1438,14 @@ static void report_sec_mismatch(const char *modna= me, tosym, prl_to, prl_to, tosym); free(prl_to); break; @@ -76575,7 +78288,7 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.c linu= x-3.1.4/scripts/mod/modpost.c } fprintf(stderr, "\n"); } -@@ -1656,7 +1671,7 @@ static void section_rel(const char *modn +@@ -1656,7 +1671,7 @@ static void section_rel(const char *modname, struc= t elf_info *elf, static void check_sec_ref(struct module *mod, const char *modname, struct elf_info *elf) { @@ -76584,7 +78297,7 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.c linu= x-3.1.4/scripts/mod/modpost.c Elf_Shdr *sechdrs =3D elf->sechdrs; =20 /* Walk through all sections */ -@@ -1754,7 +1769,7 @@ void __attribute__((format(printf, 2, 3) +@@ -1754,7 +1769,7 @@ void __attribute__((format(printf, 2, 3))) buf_pri= ntf(struct buffer *buf, va_end(ap); } =20 @@ -76593,7 +78306,7 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.c linu= x-3.1.4/scripts/mod/modpost.c { if (buf->size - buf->pos < len) { buf->size +=3D len + SZ; -@@ -1966,7 +1981,7 @@ static void write_if_changed(struct buff +@@ -1966,7 +1981,7 @@ static void write_if_changed(struct buffer *b, con= st char *fname) if (fstat(fileno(file), &st) < 0) goto close_write; =20 @@ -76602,10 +78315,11 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.c li= nux-3.1.4/scripts/mod/modpost.c goto close_write; =20 tmp =3D NOFAIL(malloc(b->pos)); -diff -urNp linux-3.1.4/scripts/mod/modpost.h linux-3.1.4/scripts/mod/mod= post.h ---- linux-3.1.4/scripts/mod/modpost.h 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/scripts/mod/modpost.h 2011-11-16 18:39:08.000000000 -050= 0 -@@ -92,15 +92,15 @@ void *do_nofail(void *ptr, const char *e +diff --git a/scripts/mod/modpost.h b/scripts/mod/modpost.h +index 2031119..b5433af 100644 +--- a/scripts/mod/modpost.h ++++ b/scripts/mod/modpost.h +@@ -92,15 +92,15 @@ void *do_nofail(void *ptr, const char *expr); =20 struct buffer { char *p; @@ -76624,10 +78338,11 @@ diff -urNp linux-3.1.4/scripts/mod/modpost.h li= nux-3.1.4/scripts/mod/modpost.h =20 struct module { struct module *next; -diff -urNp linux-3.1.4/scripts/mod/sumversion.c linux-3.1.4/scripts/mod/= sumversion.c ---- linux-3.1.4/scripts/mod/sumversion.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/scripts/mod/sumversion.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -470,7 +470,7 @@ static void write_version(const char *fi +diff --git a/scripts/mod/sumversion.c b/scripts/mod/sumversion.c +index 9dfcd6d..099068e 100644 +--- a/scripts/mod/sumversion.c ++++ b/scripts/mod/sumversion.c +@@ -470,7 +470,7 @@ static void write_version(const char *filename, cons= t char *sum, goto out; } =20 @@ -76636,9 +78351,10 @@ diff -urNp linux-3.1.4/scripts/mod/sumversion.c = linux-3.1.4/scripts/mod/sumversi warn("writing sum in %s failed: %s\n", filename, strerror(errno)); goto out; -diff -urNp linux-3.1.4/scripts/pnmtologo.c linux-3.1.4/scripts/pnmtologo= .c ---- linux-3.1.4/scripts/pnmtologo.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/scripts/pnmtologo.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/scripts/pnmtologo.c b/scripts/pnmtologo.c +index 5c11312..72742b5 100644 +--- a/scripts/pnmtologo.c ++++ b/scripts/pnmtologo.c @@ -237,14 +237,14 @@ static void write_header(void) fprintf(out, " * Linux logo %s\n", logoname); fputs(" */\n\n", out); @@ -76665,107 +78381,10 @@ diff -urNp linux-3.1.4/scripts/pnmtologo.c lin= ux-3.1.4/scripts/pnmtologo.c logoname); write_hex_cnt =3D 0; for (i =3D 0; i < logo_clutsize; i++) { -diff -urNp linux-3.1.4/security/apparmor/lsm.c linux-3.1.4/security/appa= rmor/lsm.c ---- linux-3.1.4/security/apparmor/lsm.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/security/apparmor/lsm.c 2011-11-16 18:40:44.000000000 -0= 500 -@@ -621,7 +621,7 @@ static int apparmor_task_setrlimit(struc - return error; - } -=20 --static struct security_operations apparmor_ops =3D { -+static struct security_operations apparmor_ops __read_only =3D { - .name =3D "apparmor", -=20 - .ptrace_access_check =3D apparmor_ptrace_access_check, -diff -urNp linux-3.1.4/security/commoncap.c linux-3.1.4/security/commonc= ap.c ---- linux-3.1.4/security/commoncap.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/security/commoncap.c 2011-11-16 18:40:44.000000000 -0500 -@@ -28,6 +28,7 @@ - #include - #include - #include -+#include -=20 - /* - * If a non-root user executes a setuid-root binary in -@@ -58,7 +59,7 @@ int cap_netlink_send(struct sock *sk, st -=20 - int cap_netlink_recv(struct sk_buff *skb, int cap) - { -- if (!cap_raised(current_cap(), cap)) -+ if (!cap_raised(current_cap(), cap) || !gr_is_capable(cap)) - return -EPERM; - return 0; - } -@@ -575,6 +576,9 @@ int cap_bprm_secureexec(struct linux_bin - { - const struct cred *cred =3D current_cred(); -=20 -+ if (gr_acl_enable_at_secure()) -+ return 1; -+ - if (cred->uid !=3D 0) { - if (bprm->cap_effective) - return 1; -diff -urNp linux-3.1.4/security/integrity/ima/ima_api.c linux-3.1.4/secu= rity/integrity/ima/ima_api.c ---- linux-3.1.4/security/integrity/ima/ima_api.c 2011-11-11 15:19:27.000= 000000 -0500 -+++ linux-3.1.4/security/integrity/ima/ima_api.c 2011-11-16 18:39:08.000= 000000 -0500 -@@ -75,7 +75,7 @@ void ima_add_violation(struct inode *ino - int result; -=20 - /* can overflow, only indicator */ -- atomic_long_inc(&ima_htable.violations); -+ atomic_long_inc_unchecked(&ima_htable.violations); -=20 - entry =3D kmalloc(sizeof(*entry), GFP_KERNEL); - if (!entry) { -diff -urNp linux-3.1.4/security/integrity/ima/ima_fs.c linux-3.1.4/secur= ity/integrity/ima/ima_fs.c ---- linux-3.1.4/security/integrity/ima/ima_fs.c 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/security/integrity/ima/ima_fs.c 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -28,12 +28,12 @@ - static int valid_policy =3D 1; - #define TMPBUFLEN 12 - static ssize_t ima_show_htable_value(char __user *buf, size_t count, -- loff_t *ppos, atomic_long_t *val) -+ loff_t *ppos, atomic_long_unchecked_t *val) - { - char tmpbuf[TMPBUFLEN]; - ssize_t len; -=20 -- len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read(val)); -+ len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read_uncheck= ed(val)); - return simple_read_from_buffer(buf, count, ppos, tmpbuf, len); - } -=20 -diff -urNp linux-3.1.4/security/integrity/ima/ima.h linux-3.1.4/security= /integrity/ima/ima.h ---- linux-3.1.4/security/integrity/ima/ima.h 2011-11-11 15:19:27.0000000= 00 -0500 -+++ linux-3.1.4/security/integrity/ima/ima.h 2011-11-16 18:39:08.0000000= 00 -0500 -@@ -85,8 +85,8 @@ void ima_add_violation(struct inode *ino - extern spinlock_t ima_queue_lock; -=20 - struct ima_h_table { -- atomic_long_t len; /* number of stored measurements in the list */ -- atomic_long_t violations; -+ atomic_long_unchecked_t len; /* number of stored measurements in the l= ist */ -+ atomic_long_unchecked_t violations; - struct hlist_head queue[IMA_MEASURE_HTABLE_SIZE]; - }; - extern struct ima_h_table ima_htable; -diff -urNp linux-3.1.4/security/integrity/ima/ima_queue.c linux-3.1.4/se= curity/integrity/ima/ima_queue.c ---- linux-3.1.4/security/integrity/ima/ima_queue.c 2011-11-11 15:19:27.0= 00000000 -0500 -+++ linux-3.1.4/security/integrity/ima/ima_queue.c 2011-11-16 18:39:08.0= 00000000 -0500 -@@ -79,7 +79,7 @@ static int ima_add_digest_entry(struct i - INIT_LIST_HEAD(&qe->later); - list_add_tail_rcu(&qe->later, &ima_measurements); -=20 -- atomic_long_inc(&ima_htable.len); -+ atomic_long_inc_unchecked(&ima_htable.len); - key =3D ima_hash_key(entry->digest); - hlist_add_head_rcu(&qe->hnext, &ima_htable.queue[key]); - return 0; -diff -urNp linux-3.1.4/security/Kconfig linux-3.1.4/security/Kconfig ---- linux-3.1.4/security/Kconfig 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/security/Kconfig 2011-12-02 17:38:47.000000000 -0500 +diff --git a/security/Kconfig b/security/Kconfig +index e0f08b5..7388edd 100644 +--- a/security/Kconfig ++++ b/security/Kconfig @@ -4,6 +4,586 @@ =20 menu "Security options" @@ -77362,9 +78981,114 @@ diff -urNp linux-3.1.4/security/Kconfig linux-3= .1.4/security/Kconfig default 65536 help This is the portion of low virtual memory which should be protected -diff -urNp linux-3.1.4/security/keys/compat.c linux-3.1.4/security/keys/= compat.c ---- linux-3.1.4/security/keys/compat.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/security/keys/compat.c 2011-11-16 18:39:08.000000000 -05= 00 +diff --git a/security/apparmor/lsm.c b/security/apparmor/lsm.c +index 3783202..1852837 100644 +--- a/security/apparmor/lsm.c ++++ b/security/apparmor/lsm.c +@@ -621,7 +621,7 @@ static int apparmor_task_setrlimit(struct task_struc= t *task, + return error; + } +=20 +-static struct security_operations apparmor_ops =3D { ++static struct security_operations apparmor_ops __read_only =3D { + .name =3D "apparmor", +=20 + .ptrace_access_check =3D apparmor_ptrace_access_check, +diff --git a/security/commoncap.c b/security/commoncap.c +index a93b3b7..4410df9 100644 +--- a/security/commoncap.c ++++ b/security/commoncap.c +@@ -28,6 +28,7 @@ + #include + #include + #include ++#include +=20 + /* + * If a non-root user executes a setuid-root binary in +@@ -58,7 +59,7 @@ int cap_netlink_send(struct sock *sk, struct sk_buff *= skb) +=20 + int cap_netlink_recv(struct sk_buff *skb, int cap) + { +- if (!cap_raised(current_cap(), cap)) ++ if (!cap_raised(current_cap(), cap) || !gr_is_capable(cap)) + return -EPERM; + return 0; + } +@@ -575,6 +576,9 @@ int cap_bprm_secureexec(struct linux_binprm *bprm) + { + const struct cred *cred =3D current_cred(); +=20 ++ if (gr_acl_enable_at_secure()) ++ return 1; ++ + if (cred->uid !=3D 0) { + if (bprm->cap_effective) + return 1; +diff --git a/security/integrity/ima/ima.h b/security/integrity/ima/ima.h +index 08408bd..67e6e78 100644 +--- a/security/integrity/ima/ima.h ++++ b/security/integrity/ima/ima.h +@@ -85,8 +85,8 @@ void ima_add_violation(struct inode *inode, const unsi= gned char *filename, + extern spinlock_t ima_queue_lock; +=20 + struct ima_h_table { +- atomic_long_t len; /* number of stored measurements in the list */ +- atomic_long_t violations; ++ atomic_long_unchecked_t len; /* number of stored measurements in the l= ist */ ++ atomic_long_unchecked_t violations; + struct hlist_head queue[IMA_MEASURE_HTABLE_SIZE]; + }; + extern struct ima_h_table ima_htable; +diff --git a/security/integrity/ima/ima_api.c b/security/integrity/ima/i= ma_api.c +index da36d2c..e1e1965 100644 +--- a/security/integrity/ima/ima_api.c ++++ b/security/integrity/ima/ima_api.c +@@ -75,7 +75,7 @@ void ima_add_violation(struct inode *inode, const unsi= gned char *filename, + int result; +=20 + /* can overflow, only indicator */ +- atomic_long_inc(&ima_htable.violations); ++ atomic_long_inc_unchecked(&ima_htable.violations); +=20 + entry =3D kmalloc(sizeof(*entry), GFP_KERNEL); + if (!entry) { +diff --git a/security/integrity/ima/ima_fs.c b/security/integrity/ima/im= a_fs.c +index ef21b96..d53e674 100644 +--- a/security/integrity/ima/ima_fs.c ++++ b/security/integrity/ima/ima_fs.c +@@ -28,12 +28,12 @@ + static int valid_policy =3D 1; + #define TMPBUFLEN 12 + static ssize_t ima_show_htable_value(char __user *buf, size_t count, +- loff_t *ppos, atomic_long_t *val) ++ loff_t *ppos, atomic_long_unchecked_t *val) + { + char tmpbuf[TMPBUFLEN]; + ssize_t len; +=20 +- len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read(val)); ++ len =3D scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read_uncheck= ed(val)); + return simple_read_from_buffer(buf, count, ppos, tmpbuf, len); + } +=20 +diff --git a/security/integrity/ima/ima_queue.c b/security/integrity/ima= /ima_queue.c +index 8e28f04..d5951b1 100644 +--- a/security/integrity/ima/ima_queue.c ++++ b/security/integrity/ima/ima_queue.c +@@ -79,7 +79,7 @@ static int ima_add_digest_entry(struct ima_template_en= try *entry) + INIT_LIST_HEAD(&qe->later); + list_add_tail_rcu(&qe->later, &ima_measurements); +=20 +- atomic_long_inc(&ima_htable.len); ++ atomic_long_inc_unchecked(&ima_htable.len); + key =3D ima_hash_key(entry->digest); + hlist_add_head_rcu(&qe->hnext, &ima_htable.queue[key]); + return 0; +diff --git a/security/keys/compat.c b/security/keys/compat.c +index 338b510..a235861 100644 +--- a/security/keys/compat.c ++++ b/security/keys/compat.c @@ -44,7 +44,7 @@ long compat_keyctl_instantiate_key_iov( if (ret =3D=3D 0) goto no_payload_free; @@ -77374,10 +79098,11 @@ diff -urNp linux-3.1.4/security/keys/compat.c l= inux-3.1.4/security/keys/compat.c =20 if (iov !=3D iovstack) kfree(iov); -diff -urNp linux-3.1.4/security/keys/keyctl.c linux-3.1.4/security/keys/= keyctl.c ---- linux-3.1.4/security/keys/keyctl.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/security/keys/keyctl.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -921,7 +921,7 @@ static int keyctl_change_reqkey_auth(str +diff --git a/security/keys/keyctl.c b/security/keys/keyctl.c +index eca5191..da9c7f0 100644 +--- a/security/keys/keyctl.c ++++ b/security/keys/keyctl.c +@@ -921,7 +921,7 @@ static int keyctl_change_reqkey_auth(struct key *key= ) /* * Copy the iovec data from userspace */ @@ -77386,7 +79111,7 @@ diff -urNp linux-3.1.4/security/keys/keyctl.c lin= ux-3.1.4/security/keys/keyctl.c unsigned ioc) { for (; ioc > 0; ioc--) { -@@ -943,7 +943,7 @@ static long copy_from_user_iovec(void *b +@@ -943,7 +943,7 @@ static long copy_from_user_iovec(void *buffer, const= struct iovec *iov, * If successful, 0 will be returned. */ long keyctl_instantiate_key_common(key_serial_t id, @@ -77395,7 +79120,7 @@ diff -urNp linux-3.1.4/security/keys/keyctl.c lin= ux-3.1.4/security/keys/keyctl.c unsigned ioc, size_t plen, key_serial_t ringid) -@@ -1038,7 +1038,7 @@ long keyctl_instantiate_key(key_serial_t +@@ -1038,7 +1038,7 @@ long keyctl_instantiate_key(key_serial_t id, [0].iov_len =3D plen }; =20 @@ -77404,7 +79129,7 @@ diff -urNp linux-3.1.4/security/keys/keyctl.c lin= ux-3.1.4/security/keys/keyctl.c } =20 return keyctl_instantiate_key_common(id, NULL, 0, 0, ringid); -@@ -1071,7 +1071,7 @@ long keyctl_instantiate_key_iov(key_seri +@@ -1071,7 +1071,7 @@ long keyctl_instantiate_key_iov(key_serial_t id, if (ret =3D=3D 0) goto no_payload_free; =20 @@ -77413,10 +79138,11 @@ diff -urNp linux-3.1.4/security/keys/keyctl.c l= inux-3.1.4/security/keys/keyctl.c =20 if (iov !=3D iovstack) kfree(iov); -diff -urNp linux-3.1.4/security/keys/keyring.c linux-3.1.4/security/keys= /keyring.c ---- linux-3.1.4/security/keys/keyring.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/security/keys/keyring.c 2011-11-16 18:39:08.000000000 -0= 500 -@@ -214,15 +214,15 @@ static long keyring_read(const struct ke +diff --git a/security/keys/keyring.c b/security/keys/keyring.c +index 30e242f..ec111ab 100644 +--- a/security/keys/keyring.c ++++ b/security/keys/keyring.c +@@ -214,15 +214,15 @@ static long keyring_read(const struct key *keyring= , ret =3D -EFAULT; =20 for (loop =3D 0; loop < klist->nkeys; loop++) { @@ -77435,10 +79161,11 @@ diff -urNp linux-3.1.4/security/keys/keyring.c = linux-3.1.4/security/keys/keyring goto error; =20 buflen -=3D tmp; -diff -urNp linux-3.1.4/security/min_addr.c linux-3.1.4/security/min_addr= .c ---- linux-3.1.4/security/min_addr.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/security/min_addr.c 2011-11-16 18:40:44.000000000 -0500 -@@ -14,6 +14,7 @@ unsigned long dac_mmap_min_addr =3D CONFIG +diff --git a/security/min_addr.c b/security/min_addr.c +index f728728..6457a0c 100644 +--- a/security/min_addr.c ++++ b/security/min_addr.c +@@ -14,6 +14,7 @@ unsigned long dac_mmap_min_addr =3D CONFIG_DEFAULT_MMA= P_MIN_ADDR; */ static void update_mmap_min_addr(void) { @@ -77454,10 +79181,11 @@ diff -urNp linux-3.1.4/security/min_addr.c linu= x-3.1.4/security/min_addr.c } =20 /* -diff -urNp linux-3.1.4/security/security.c linux-3.1.4/security/security= .c ---- linux-3.1.4/security/security.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/security/security.c 2011-11-16 18:40:44.000000000 -0500 -@@ -25,8 +25,8 @@ static __initdata char chosen_lsm[SECURI +diff --git a/security/security.c b/security/security.c +index d9e1533..91427f2 100644 +--- a/security/security.c ++++ b/security/security.c +@@ -25,8 +25,8 @@ static __initdata char chosen_lsm[SECURITY_NAME_MAX + = 1] =3D /* things that live in capability.c */ extern void __init security_fixup_ops(struct security_operations *ops); =20 @@ -77478,9 +79206,10 @@ diff -urNp linux-3.1.4/security/security.c linux= -3.1.4/security/security.c } =20 /* Save user chosen LSM */ -diff -urNp linux-3.1.4/security/selinux/hooks.c linux-3.1.4/security/sel= inux/hooks.c ---- linux-3.1.4/security/selinux/hooks.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/security/selinux/hooks.c 2011-11-16 18:40:44.000000000 -= 0500 +diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c +index 266a229..61bd553 100644 +--- a/security/selinux/hooks.c ++++ b/security/selinux/hooks.c @@ -93,7 +93,6 @@ #define NUM_SEL_MNT_OPTS 5 =20 @@ -77489,7 +79218,7 @@ diff -urNp linux-3.1.4/security/selinux/hooks.c l= inux-3.1.4/security/selinux/hoo =20 /* SECMARK reference count */ atomic_t selinux_secmark_refcount =3D ATOMIC_INIT(0); -@@ -5455,7 +5454,7 @@ static int selinux_key_getsecurity(struc +@@ -5455,7 +5454,7 @@ static int selinux_key_getsecurity(struct key *key= , char **_buffer) =20 #endif =20 @@ -77498,10 +79227,11 @@ diff -urNp linux-3.1.4/security/selinux/hooks.c= linux-3.1.4/security/selinux/hoo .name =3D "selinux", =20 .ptrace_access_check =3D selinux_ptrace_access_check, -diff -urNp linux-3.1.4/security/selinux/include/xfrm.h linux-3.1.4/secur= ity/selinux/include/xfrm.h ---- linux-3.1.4/security/selinux/include/xfrm.h 2011-11-11 15:19:27.0000= 00000 -0500 -+++ linux-3.1.4/security/selinux/include/xfrm.h 2011-11-16 18:39:08.0000= 00000 -0500 -@@ -48,7 +48,7 @@ int selinux_xfrm_decode_session(struct s +diff --git a/security/selinux/include/xfrm.h b/security/selinux/include/= xfrm.h +index b43813c..74be837 100644 +--- a/security/selinux/include/xfrm.h ++++ b/security/selinux/include/xfrm.h +@@ -48,7 +48,7 @@ int selinux_xfrm_decode_session(struct sk_buff *skb, u= 32 *sid, int ckall); =20 static inline void selinux_xfrm_notify_policyload(void) { @@ -77510,10 +79240,11 @@ diff -urNp linux-3.1.4/security/selinux/include= /xfrm.h linux-3.1.4/security/seli } #else static inline int selinux_xfrm_enabled(void) -diff -urNp linux-3.1.4/security/selinux/ss/services.c linux-3.1.4/securi= ty/selinux/ss/services.c ---- linux-3.1.4/security/selinux/ss/services.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/security/selinux/ss/services.c 2011-11-16 18:40:44.00000= 0000 -0500 -@@ -1814,6 +1814,8 @@ int security_load_policy(void *data, siz +diff --git a/security/selinux/ss/services.c b/security/selinux/ss/servic= es.c +index f6917bc..8e8713e 100644 +--- a/security/selinux/ss/services.c ++++ b/security/selinux/ss/services.c +@@ -1814,6 +1814,8 @@ int security_load_policy(void *data, size_t len) int rc =3D 0; struct policy_file file =3D { data, len }, *fp =3D &file; =20 @@ -77522,10 +79253,11 @@ diff -urNp linux-3.1.4/security/selinux/ss/serv= ices.c linux-3.1.4/security/selin if (!ss_initialized) { avtab_cache_init(); rc =3D policydb_read(&policydb, fp); -diff -urNp linux-3.1.4/security/smack/smack_lsm.c linux-3.1.4/security/s= mack/smack_lsm.c ---- linux-3.1.4/security/smack/smack_lsm.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/security/smack/smack_lsm.c 2011-11-16 18:39:08.000000000= -0500 -@@ -3393,7 +3393,7 @@ static int smack_inode_getsecctx(struct=20 +diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c +index b9c5e14..20ab779 100644 +--- a/security/smack/smack_lsm.c ++++ b/security/smack/smack_lsm.c +@@ -3393,7 +3393,7 @@ static int smack_inode_getsecctx(struct inode *ino= de, void **ctx, u32 *ctxlen) return 0; } =20 @@ -77534,10 +79266,11 @@ diff -urNp linux-3.1.4/security/smack/smack_lsm= .c linux-3.1.4/security/smack/sma .name =3D "smack", =20 .ptrace_access_check =3D smack_ptrace_access_check, -diff -urNp linux-3.1.4/security/tomoyo/tomoyo.c linux-3.1.4/security/tom= oyo/tomoyo.c ---- linux-3.1.4/security/tomoyo/tomoyo.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/security/tomoyo/tomoyo.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -446,7 +446,7 @@ static int tomoyo_sb_pivotroot(struct pa +diff --git a/security/tomoyo/tomoyo.c b/security/tomoyo/tomoyo.c +index f776400..f95b158c 100644 +--- a/security/tomoyo/tomoyo.c ++++ b/security/tomoyo/tomoyo.c +@@ -446,7 +446,7 @@ static int tomoyo_sb_pivotroot(struct path *old_path= , struct path *new_path) * tomoyo_security_ops is a "struct security_operations" which is used = for * registering TOMOYO. */ @@ -77546,9 +79279,10 @@ diff -urNp linux-3.1.4/security/tomoyo/tomoyo.c = linux-3.1.4/security/tomoyo/tomo .name =3D "tomoyo", .cred_alloc_blank =3D tomoyo_cred_alloc_blank, .cred_prepare =3D tomoyo_cred_prepare, -diff -urNp linux-3.1.4/sound/aoa/codecs/onyx.c linux-3.1.4/sound/aoa/cod= ecs/onyx.c ---- linux-3.1.4/sound/aoa/codecs/onyx.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/sound/aoa/codecs/onyx.c 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/sound/aoa/codecs/onyx.c b/sound/aoa/codecs/onyx.c +index 3687a6c..652565e 100644 +--- a/sound/aoa/codecs/onyx.c ++++ b/sound/aoa/codecs/onyx.c @@ -54,7 +54,7 @@ struct onyx { spdif_locked:1, analog_locked:1, @@ -77558,7 +79292,7 @@ diff -urNp linux-3.1.4/sound/aoa/codecs/onyx.c li= nux-3.1.4/sound/aoa/codecs/onyx struct codec_info *codec_info; =20 /* mutex serializes concurrent access to the device -@@ -753,7 +753,7 @@ static int onyx_open(struct codec_info_i +@@ -753,7 +753,7 @@ static int onyx_open(struct codec_info_item *cii, struct onyx *onyx =3D cii->codec_data; =20 mutex_lock(&onyx->mutex); @@ -77567,7 +79301,7 @@ diff -urNp linux-3.1.4/sound/aoa/codecs/onyx.c li= nux-3.1.4/sound/aoa/codecs/onyx mutex_unlock(&onyx->mutex); =20 return 0; -@@ -765,8 +765,7 @@ static int onyx_close(struct codec_info_ +@@ -765,8 +765,7 @@ static int onyx_close(struct codec_info_item *cii, struct onyx *onyx =3D cii->codec_data; =20 mutex_lock(&onyx->mutex); @@ -77577,9 +79311,10 @@ diff -urNp linux-3.1.4/sound/aoa/codecs/onyx.c l= inux-3.1.4/sound/aoa/codecs/onyx onyx->spdif_locked =3D onyx->analog_locked =3D 0; mutex_unlock(&onyx->mutex); =20 -diff -urNp linux-3.1.4/sound/aoa/codecs/onyx.h linux-3.1.4/sound/aoa/cod= ecs/onyx.h ---- linux-3.1.4/sound/aoa/codecs/onyx.h 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/sound/aoa/codecs/onyx.h 2011-11-16 18:39:08.000000000 -0= 500 +diff --git a/sound/aoa/codecs/onyx.h b/sound/aoa/codecs/onyx.h +index ffd2025..df062c9 100644 +--- a/sound/aoa/codecs/onyx.h ++++ b/sound/aoa/codecs/onyx.h @@ -11,6 +11,7 @@ #include #include @@ -77588,10 +79323,11 @@ diff -urNp linux-3.1.4/sound/aoa/codecs/onyx.h = linux-3.1.4/sound/aoa/codecs/onyx =20 /* PCM3052 register definitions */ =20 -diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c linux-3.1.4/sound/core/o= ss/pcm_oss.c ---- linux-3.1.4/sound/core/oss/pcm_oss.c 2011-11-11 15:19:27.000000000 -= 0500 -+++ linux-3.1.4/sound/core/oss/pcm_oss.c 2011-11-16 18:39:08.000000000 -= 0500 -@@ -1189,10 +1189,10 @@ snd_pcm_sframes_t snd_pcm_oss_write3(str +diff --git a/sound/core/oss/pcm_oss.c b/sound/core/oss/pcm_oss.c +index 23c34a0..a2673a5 100644 +--- a/sound/core/oss/pcm_oss.c ++++ b/sound/core/oss/pcm_oss.c +@@ -1189,10 +1189,10 @@ snd_pcm_sframes_t snd_pcm_oss_write3(struct snd_= pcm_substream *substream, const if (in_kernel) { mm_segment_t fs; fs =3D snd_enter_user(); @@ -77604,7 +79340,7 @@ diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c l= inux-3.1.4/sound/core/oss/pcm_o } if (ret !=3D -EPIPE && ret !=3D -ESTRPIPE) break; -@@ -1234,10 +1234,10 @@ snd_pcm_sframes_t snd_pcm_oss_read3(stru +@@ -1234,10 +1234,10 @@ snd_pcm_sframes_t snd_pcm_oss_read3(struct snd_p= cm_substream *substream, char *p if (in_kernel) { mm_segment_t fs; fs =3D snd_enter_user(); @@ -77617,7 +79353,7 @@ diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c l= inux-3.1.4/sound/core/oss/pcm_o } if (ret =3D=3D -EPIPE) { if (runtime->status->state =3D=3D SNDRV_PCM_STATE_DRAINING) { -@@ -1337,7 +1337,7 @@ static ssize_t snd_pcm_oss_write2(struct +@@ -1337,7 +1337,7 @@ static ssize_t snd_pcm_oss_write2(struct snd_pcm_s= ubstream *substream, const cha struct snd_pcm_plugin_channel *channels; size_t oss_frame_bytes =3D (runtime->oss.plugin_first->src_width * ru= ntime->oss.plugin_first->src_format.channels) / 8; if (!in_kernel) { @@ -77626,7 +79362,7 @@ diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c l= inux-3.1.4/sound/core/oss/pcm_o return -EFAULT; buf =3D runtime->oss.buffer; } -@@ -1407,7 +1407,7 @@ static ssize_t snd_pcm_oss_write1(struct +@@ -1407,7 +1407,7 @@ static ssize_t snd_pcm_oss_write1(struct snd_pcm_s= ubstream *substream, const cha } } else { tmp =3D snd_pcm_oss_write2(substream, @@ -77635,7 +79371,7 @@ diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c l= inux-3.1.4/sound/core/oss/pcm_o runtime->oss.period_bytes, 0); if (tmp <=3D 0) goto err; -@@ -1433,7 +1433,7 @@ static ssize_t snd_pcm_oss_read2(struct=20 +@@ -1433,7 +1433,7 @@ static ssize_t snd_pcm_oss_read2(struct snd_pcm_su= bstream *substream, char *buf, struct snd_pcm_runtime *runtime =3D substream->runtime; snd_pcm_sframes_t frames, frames1; #ifdef CONFIG_SND_PCM_OSS_PLUGINS @@ -77644,7 +79380,7 @@ diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c l= inux-3.1.4/sound/core/oss/pcm_o if (runtime->oss.plugin_first) { struct snd_pcm_plugin_channel *channels; size_t oss_frame_bytes =3D (runtime->oss.plugin_last->dst_width * run= time->oss.plugin_last->dst_format.channels) / 8; -@@ -1495,7 +1495,7 @@ static ssize_t snd_pcm_oss_read1(struct=20 +@@ -1495,7 +1495,7 @@ static ssize_t snd_pcm_oss_read1(struct snd_pcm_su= bstream *substream, char __use xfer +=3D tmp; runtime->oss.buffer_used -=3D tmp; } else { @@ -77653,7 +79389,7 @@ diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c l= inux-3.1.4/sound/core/oss/pcm_o runtime->oss.period_bytes, 0); if (tmp <=3D 0) goto err; -@@ -1663,7 +1663,7 @@ static int snd_pcm_oss_sync(struct snd_p +@@ -1663,7 +1663,7 @@ static int snd_pcm_oss_sync(struct snd_pcm_oss_fil= e *pcm_oss_file) size1); size1 /=3D runtime->channels; /* frames */ fs =3D snd_enter_user(); @@ -77662,10 +79398,11 @@ diff -urNp linux-3.1.4/sound/core/oss/pcm_oss.c= linux-3.1.4/sound/core/oss/pcm_o snd_leave_user(fs); } } else if (runtime->access =3D=3D SNDRV_PCM_ACCESS_RW_NONINTERLEAVED= ) { -diff -urNp linux-3.1.4/sound/core/pcm_compat.c linux-3.1.4/sound/core/pc= m_compat.c ---- linux-3.1.4/sound/core/pcm_compat.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/sound/core/pcm_compat.c 2011-11-16 18:39:08.000000000 -0= 500 -@@ -31,7 +31,7 @@ static int snd_pcm_ioctl_delay_compat(st +diff --git a/sound/core/pcm_compat.c b/sound/core/pcm_compat.c +index 91cdf94..4085161 100644 +--- a/sound/core/pcm_compat.c ++++ b/sound/core/pcm_compat.c +@@ -31,7 +31,7 @@ static int snd_pcm_ioctl_delay_compat(struct snd_pcm_s= ubstream *substream, int err; =20 fs =3D snd_enter_user(); @@ -77674,10 +79411,11 @@ diff -urNp linux-3.1.4/sound/core/pcm_compat.c = linux-3.1.4/sound/core/pcm_compat snd_leave_user(fs); if (err < 0) return err; -diff -urNp linux-3.1.4/sound/core/pcm_native.c linux-3.1.4/sound/core/pc= m_native.c ---- linux-3.1.4/sound/core/pcm_native.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/sound/core/pcm_native.c 2011-11-16 18:39:08.000000000 -0= 500 -@@ -2770,11 +2770,11 @@ int snd_pcm_kernel_ioctl(struct snd_pcm_ +diff --git a/sound/core/pcm_native.c b/sound/core/pcm_native.c +index 1c6be91..c761a59 100644 +--- a/sound/core/pcm_native.c ++++ b/sound/core/pcm_native.c +@@ -2770,11 +2770,11 @@ int snd_pcm_kernel_ioctl(struct snd_pcm_substrea= m *substream, switch (substream->stream) { case SNDRV_PCM_STREAM_PLAYBACK: result =3D snd_pcm_playback_ioctl1(NULL, substream, cmd, @@ -77691,9 +79429,10 @@ diff -urNp linux-3.1.4/sound/core/pcm_native.c l= inux-3.1.4/sound/core/pcm_native break; default: result =3D -EINVAL; -diff -urNp linux-3.1.4/sound/core/seq/seq_device.c linux-3.1.4/sound/cor= e/seq/seq_device.c ---- linux-3.1.4/sound/core/seq/seq_device.c 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/sound/core/seq/seq_device.c 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/sound/core/seq/seq_device.c b/sound/core/seq/seq_device.c +index 1f99767..14636533 100644 +--- a/sound/core/seq/seq_device.c ++++ b/sound/core/seq/seq_device.c @@ -63,7 +63,7 @@ struct ops_list { int argsize; /* argument size */ =20 @@ -77703,7 +79442,7 @@ diff -urNp linux-3.1.4/sound/core/seq/seq_device.= c linux-3.1.4/sound/core/seq/se =20 /* registred devices */ struct list_head dev_list; /* list of devices */ -@@ -332,7 +332,7 @@ int snd_seq_device_register_driver(char=20 +@@ -332,7 +332,7 @@ int snd_seq_device_register_driver(char *id, struct = snd_seq_dev_ops *entry, =20 mutex_lock(&ops->reg_mutex); /* copy driver operators */ @@ -77712,7 +79451,7 @@ diff -urNp linux-3.1.4/sound/core/seq/seq_device.= c linux-3.1.4/sound/core/seq/se ops->driver |=3D DRIVER_LOADED; ops->argsize =3D argsize; =20 -@@ -462,7 +462,7 @@ static int init_device(struct snd_seq_de +@@ -462,7 +462,7 @@ static int init_device(struct snd_seq_device *dev, s= truct ops_list *ops) dev->name, ops->id, ops->argsize, dev->argsize); return -EINVAL; } @@ -77721,7 +79460,7 @@ diff -urNp linux-3.1.4/sound/core/seq/seq_device.= c linux-3.1.4/sound/core/seq/se dev->status =3D SNDRV_SEQ_DEVICE_REGISTERED; ops->num_init_devices++; } else { -@@ -489,7 +489,7 @@ static int free_device(struct snd_seq_de +@@ -489,7 +489,7 @@ static int free_device(struct snd_seq_device *dev, s= truct ops_list *ops) dev->name, ops->id, ops->argsize, dev->argsize); return -EINVAL; } @@ -77730,9 +79469,10 @@ diff -urNp linux-3.1.4/sound/core/seq/seq_device= .c linux-3.1.4/sound/core/seq/se dev->status =3D SNDRV_SEQ_DEVICE_FREE; dev->driver_data =3D NULL; ops->num_init_devices--; -diff -urNp linux-3.1.4/sound/drivers/mts64.c linux-3.1.4/sound/drivers/m= ts64.c ---- linux-3.1.4/sound/drivers/mts64.c 2011-11-11 15:19:27.000000000 -050= 0 -+++ linux-3.1.4/sound/drivers/mts64.c 2011-11-16 18:39:08.000000000 -050= 0 +diff --git a/sound/drivers/mts64.c b/sound/drivers/mts64.c +index 8539ab0..be8a121 100644 +--- a/sound/drivers/mts64.c ++++ b/sound/drivers/mts64.c @@ -28,6 +28,7 @@ #include #include @@ -77750,7 +79490,7 @@ diff -urNp linux-3.1.4/sound/drivers/mts64.c linu= x-3.1.4/sound/drivers/mts64.c int current_midi_output_port; int current_midi_input_port; u8 mode[MTS64_NUM_INPUT_PORTS]; -@@ -696,7 +697,7 @@ static int snd_mts64_rawmidi_open(struct +@@ -696,7 +697,7 @@ static int snd_mts64_rawmidi_open(struct snd_rawmidi= _substream *substream) { struct mts64 *mts =3D substream->rmidi->private_data; =20 @@ -77759,7 +79499,7 @@ diff -urNp linux-3.1.4/sound/drivers/mts64.c linu= x-3.1.4/sound/drivers/mts64.c /* We don't need a spinlock here, because this is just called=20 if the device has not been opened before.=20 So there aren't any IRQs from the device */ -@@ -704,7 +705,7 @@ static int snd_mts64_rawmidi_open(struct +@@ -704,7 +705,7 @@ static int snd_mts64_rawmidi_open(struct snd_rawmidi= _substream *substream) =20 msleep(50); } @@ -77768,7 +79508,7 @@ diff -urNp linux-3.1.4/sound/drivers/mts64.c linu= x-3.1.4/sound/drivers/mts64.c =20 return 0; } -@@ -714,8 +715,7 @@ static int snd_mts64_rawmidi_close(struc +@@ -714,8 +715,7 @@ static int snd_mts64_rawmidi_close(struct snd_rawmid= i_substream *substream) struct mts64 *mts =3D substream->rmidi->private_data; unsigned long flags; =20 @@ -77778,7 +79518,7 @@ diff -urNp linux-3.1.4/sound/drivers/mts64.c linu= x-3.1.4/sound/drivers/mts64.c /* We need the spinlock_irqsave here because we can still have IRQs at this point */ spin_lock_irqsave(&mts->lock, flags); -@@ -724,8 +724,8 @@ static int snd_mts64_rawmidi_close(struc +@@ -724,8 +724,8 @@ static int snd_mts64_rawmidi_close(struct snd_rawmid= i_substream *substream) =20 msleep(500); =20 @@ -77789,10 +79529,11 @@ diff -urNp linux-3.1.4/sound/drivers/mts64.c li= nux-3.1.4/sound/drivers/mts64.c =20 return 0; } -diff -urNp linux-3.1.4/sound/drivers/opl4/opl4_lib.c linux-3.1.4/sound/d= rivers/opl4/opl4_lib.c ---- linux-3.1.4/sound/drivers/opl4/opl4_lib.c 2011-11-11 15:19:27.000000= 000 -0500 -+++ linux-3.1.4/sound/drivers/opl4/opl4_lib.c 2011-11-16 18:39:08.000000= 000 -0500 -@@ -28,7 +28,7 @@ MODULE_AUTHOR("Clemens Ladisch "); MODULE_DESCRIPTION("OPL4 driver"); MODULE_LICENSE("GPL"); =20 @@ -77801,9 +79542,10 @@ diff -urNp linux-3.1.4/sound/drivers/opl4/opl4_l= ib.c linux-3.1.4/sound/drivers/o { int timeout =3D 10; while ((inb(opl4->fm_port) & OPL4_STATUS_BUSY) && --timeout > 0) -diff -urNp linux-3.1.4/sound/drivers/portman2x4.c linux-3.1.4/sound/driv= ers/portman2x4.c ---- linux-3.1.4/sound/drivers/portman2x4.c 2011-11-11 15:19:27.000000000= -0500 -+++ linux-3.1.4/sound/drivers/portman2x4.c 2011-11-16 18:39:08.000000000= -0500 +diff --git a/sound/drivers/portman2x4.c b/sound/drivers/portman2x4.c +index f2b0ba2..429efc5 100644 +--- a/sound/drivers/portman2x4.c ++++ b/sound/drivers/portman2x4.c @@ -47,6 +47,7 @@ #include #include @@ -77821,10 +79563,11 @@ diff -urNp linux-3.1.4/sound/drivers/portman2x4= .c linux-3.1.4/sound/drivers/port int mode[PORTMAN_NUM_INPUT_PORTS]; struct snd_rawmidi_substream *midi_input[PORTMAN_NUM_INPUT_PORTS]; }; -diff -urNp linux-3.1.4/sound/firewire/amdtp.c linux-3.1.4/sound/firewire= /amdtp.c ---- linux-3.1.4/sound/firewire/amdtp.c 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/sound/firewire/amdtp.c 2011-11-16 18:39:08.000000000 -05= 00 -@@ -371,7 +371,7 @@ static void queue_out_packet(struct amdt +diff --git a/sound/firewire/amdtp.c b/sound/firewire/amdtp.c +index 87657dd..a8268d4 100644 +--- a/sound/firewire/amdtp.c ++++ b/sound/firewire/amdtp.c +@@ -371,7 +371,7 @@ static void queue_out_packet(struct amdtp_out_stream= *s, unsigned int cycle) ptr =3D s->pcm_buffer_pointer + data_blocks; if (ptr >=3D pcm->runtime->buffer_size) ptr -=3D pcm->runtime->buffer_size; @@ -77842,10 +79585,11 @@ diff -urNp linux-3.1.4/sound/firewire/amdtp.c l= inux-3.1.4/sound/firewire/amdtp.c (fw_parent_device(s->unit)->card->node_id & 0x3f) << 24; } EXPORT_SYMBOL(amdtp_out_stream_update); -diff -urNp linux-3.1.4/sound/firewire/amdtp.h linux-3.1.4/sound/firewire= /amdtp.h ---- linux-3.1.4/sound/firewire/amdtp.h 2011-11-11 15:19:27.000000000 -05= 00 -+++ linux-3.1.4/sound/firewire/amdtp.h 2011-11-16 18:39:08.000000000 -05= 00 -@@ -146,7 +146,7 @@ static inline void amdtp_out_stream_pcm_ +diff --git a/sound/firewire/amdtp.h b/sound/firewire/amdtp.h +index 537a9cb..8e8c8e9 100644 +--- a/sound/firewire/amdtp.h ++++ b/sound/firewire/amdtp.h +@@ -146,7 +146,7 @@ static inline void amdtp_out_stream_pcm_prepare(stru= ct amdtp_out_stream *s) static inline void amdtp_out_stream_pcm_trigger(struct amdtp_out_stream= *s, struct snd_pcm_substream *pcm) { @@ -77854,10 +79598,11 @@ diff -urNp linux-3.1.4/sound/firewire/amdtp.h l= inux-3.1.4/sound/firewire/amdtp.h } =20 /** -diff -urNp linux-3.1.4/sound/firewire/isight.c linux-3.1.4/sound/firewir= e/isight.c ---- linux-3.1.4/sound/firewire/isight.c 2011-11-11 15:19:27.000000000 -0= 500 -+++ linux-3.1.4/sound/firewire/isight.c 2011-11-16 18:39:08.000000000 -0= 500 -@@ -97,7 +97,7 @@ static void isight_update_pointers(struc +diff --git a/sound/firewire/isight.c b/sound/firewire/isight.c +index 4400308..261e9f3 100644 +--- a/sound/firewire/isight.c ++++ b/sound/firewire/isight.c +@@ -97,7 +97,7 @@ static void isight_update_pointers(struct isight *isig= ht, unsigned int count) ptr +=3D count; if (ptr >=3D runtime->buffer_size) ptr -=3D runtime->buffer_size; @@ -77866,7 +79611,7 @@ diff -urNp linux-3.1.4/sound/firewire/isight.c li= nux-3.1.4/sound/firewire/isight =20 isight->period_counter +=3D count; if (isight->period_counter >=3D runtime->period_size) { -@@ -308,7 +308,7 @@ static int isight_hw_params(struct snd_p +@@ -308,7 +308,7 @@ static int isight_hw_params(struct snd_pcm_substream= *substream, if (err < 0) return err; =20 @@ -77875,7 +79620,7 @@ diff -urNp linux-3.1.4/sound/firewire/isight.c li= nux-3.1.4/sound/firewire/isight =20 return 0; } -@@ -341,7 +341,7 @@ static int isight_hw_free(struct snd_pcm +@@ -341,7 +341,7 @@ static int isight_hw_free(struct snd_pcm_substream *= substream) { struct isight *isight =3D substream->private_data; =20 @@ -77884,7 +79629,7 @@ diff -urNp linux-3.1.4/sound/firewire/isight.c li= nux-3.1.4/sound/firewire/isight =20 mutex_lock(&isight->mutex); isight_stop_streaming(isight); -@@ -434,10 +434,10 @@ static int isight_trigger(struct snd_pcm +@@ -434,10 +434,10 @@ static int isight_trigger(struct snd_pcm_substream= *substream, int cmd) =20 switch (cmd) { case SNDRV_PCM_TRIGGER_START: @@ -77897,9 +79642,10 @@ diff -urNp linux-3.1.4/sound/firewire/isight.c l= inux-3.1.4/sound/firewire/isight break; default: return -EINVAL; -diff -urNp linux-3.1.4/sound/isa/cmi8330.c linux-3.1.4/sound/isa/cmi8330= .c ---- linux-3.1.4/sound/isa/cmi8330.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/sound/isa/cmi8330.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/sound/isa/cmi8330.c b/sound/isa/cmi8330.c +index fe79a16..4d9714e 100644 +--- a/sound/isa/cmi8330.c ++++ b/sound/isa/cmi8330.c @@ -172,7 +172,7 @@ struct snd_cmi8330 { =20 struct snd_pcm *pcm; @@ -77909,9 +79655,10 @@ diff -urNp linux-3.1.4/sound/isa/cmi8330.c linux= -3.1.4/sound/isa/cmi8330.c snd_pcm_open_callback_t open; void *private_data; /* sb or wss */ } streams[2]; -diff -urNp linux-3.1.4/sound/oss/sb_audio.c linux-3.1.4/sound/oss/sb_aud= io.c ---- linux-3.1.4/sound/oss/sb_audio.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/sound/oss/sb_audio.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/sound/oss/sb_audio.c b/sound/oss/sb_audio.c +index 733b014..56ce96f 100644 +--- a/sound/oss/sb_audio.c ++++ b/sound/oss/sb_audio.c @@ -901,7 +901,7 @@ sb16_copy_from_user(int dev, buf16 =3D (signed short *)(localbuf + localoffs); while (c) @@ -77921,9 +79668,10 @@ diff -urNp linux-3.1.4/sound/oss/sb_audio.c linu= x-3.1.4/sound/oss/sb_audio.c if (copy_from_user(lbuf8, userbuf+useroffs + p, locallen)) -diff -urNp linux-3.1.4/sound/oss/swarm_cs4297a.c linux-3.1.4/sound/oss/s= warm_cs4297a.c ---- linux-3.1.4/sound/oss/swarm_cs4297a.c 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/sound/oss/swarm_cs4297a.c 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/sound/oss/swarm_cs4297a.c b/sound/oss/swarm_cs4297a.c +index 09d4648..cf234c7 100644 +--- a/sound/oss/swarm_cs4297a.c ++++ b/sound/oss/swarm_cs4297a.c @@ -2606,7 +2606,6 @@ static int __init cs4297a_init(void) { struct cs4297a_state *s; @@ -77958,9 +79706,10 @@ diff -urNp linux-3.1.4/sound/oss/swarm_cs4297a.c= linux-3.1.4/sound/oss/swarm_cs4 =20 list_add(&s->list, &cs4297a_devs); =20 -diff -urNp linux-3.1.4/sound/pci/hda/hda_codec.h linux-3.1.4/sound/pci/h= da/hda_codec.h ---- linux-3.1.4/sound/pci/hda/hda_codec.h 2011-11-11 15:19:27.000000000 = -0500 -+++ linux-3.1.4/sound/pci/hda/hda_codec.h 2011-11-16 18:39:08.000000000 = -0500 +diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h +index 755f2b0..5c12361 100644 +--- a/sound/pci/hda/hda_codec.h ++++ b/sound/pci/hda/hda_codec.h @@ -611,7 +611,7 @@ struct hda_bus_ops { /* notify power-up/down from codec to controller */ void (*pm_notify)(struct hda_bus *bus); @@ -77996,9 +79745,10 @@ diff -urNp linux-3.1.4/sound/pci/hda/hda_codec.h= linux-3.1.4/sound/pci/hda/hda_c =20 /* PCM to create, set by patch_ops.build_pcms callback */ unsigned int num_pcms; -diff -urNp linux-3.1.4/sound/pci/ice1712/ice1712.h linux-3.1.4/sound/pci= /ice1712/ice1712.h ---- linux-3.1.4/sound/pci/ice1712/ice1712.h 2011-11-11 15:19:27.00000000= 0 -0500 -+++ linux-3.1.4/sound/pci/ice1712/ice1712.h 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/sound/pci/ice1712/ice1712.h b/sound/pci/ice1712/ice1712.h +index 0da778a..bc38b84 100644 +--- a/sound/pci/ice1712/ice1712.h ++++ b/sound/pci/ice1712/ice1712.h @@ -269,7 +269,7 @@ struct snd_ak4xxx_private { unsigned int mask_flags; /* total mask bits */ struct snd_akm4xxx_ops { @@ -78017,10 +79767,11 @@ diff -urNp linux-3.1.4/sound/pci/ice1712/ice171= 2.h linux-3.1.4/sound/pci/ice1712 }; =20 =20 -diff -urNp linux-3.1.4/sound/pci/ymfpci/ymfpci_main.c linux-3.1.4/sound/= pci/ymfpci/ymfpci_main.c ---- linux-3.1.4/sound/pci/ymfpci/ymfpci_main.c 2011-11-11 15:19:27.00000= 0000 -0500 -+++ linux-3.1.4/sound/pci/ymfpci/ymfpci_main.c 2011-11-16 18:39:08.00000= 0000 -0500 -@@ -202,8 +202,8 @@ static void snd_ymfpci_hw_stop(struct sn +diff --git a/sound/pci/ymfpci/ymfpci_main.c b/sound/pci/ymfpci/ymfpci_ma= in.c +index f3260e6..4a285d8 100644 +--- a/sound/pci/ymfpci/ymfpci_main.c ++++ b/sound/pci/ymfpci/ymfpci_main.c +@@ -202,8 +202,8 @@ static void snd_ymfpci_hw_stop(struct snd_ymfpci *ch= ip) if ((snd_ymfpci_readl(chip, YDSXGR_STATUS) & 2) =3D=3D 0) break; } @@ -78031,7 +79782,7 @@ diff -urNp linux-3.1.4/sound/pci/ymfpci/ymfpci_ma= in.c linux-3.1.4/sound/pci/ymfp wake_up(&chip->interrupt_sleep); } __end: -@@ -787,7 +787,7 @@ static void snd_ymfpci_irq_wait(struct s +@@ -787,7 +787,7 @@ static void snd_ymfpci_irq_wait(struct snd_ymfpci *c= hip) continue; init_waitqueue_entry(&wait, current); add_wait_queue(&chip->interrupt_sleep, &wait); @@ -78040,7 +79791,7 @@ diff -urNp linux-3.1.4/sound/pci/ymfpci/ymfpci_ma= in.c linux-3.1.4/sound/pci/ymfp schedule_timeout_uninterruptible(msecs_to_jiffies(50)); remove_wait_queue(&chip->interrupt_sleep, &wait); } -@@ -825,8 +825,8 @@ static irqreturn_t snd_ymfpci_interrupt( +@@ -825,8 +825,8 @@ static irqreturn_t snd_ymfpci_interrupt(int irq, voi= d *dev_id) snd_ymfpci_writel(chip, YDSXGR_MODE, mode); spin_unlock(&chip->reg_lock); =20 @@ -78051,7 +79802,7 @@ diff -urNp linux-3.1.4/sound/pci/ymfpci/ymfpci_ma= in.c linux-3.1.4/sound/pci/ymfp wake_up(&chip->interrupt_sleep); } } -@@ -2363,7 +2363,7 @@ int __devinit snd_ymfpci_create(struct s +@@ -2363,7 +2363,7 @@ int __devinit snd_ymfpci_create(struct snd_card *c= ard, spin_lock_init(&chip->reg_lock); spin_lock_init(&chip->voice_lock); init_waitqueue_head(&chip->interrupt_sleep); @@ -78060,10 +79811,11 @@ diff -urNp linux-3.1.4/sound/pci/ymfpci/ymfpci_= main.c linux-3.1.4/sound/pci/ymfp chip->card =3D card; chip->pci =3D pci; chip->irq =3D -1; -diff -urNp linux-3.1.4/sound/soc/soc-pcm.c linux-3.1.4/sound/soc/soc-pcm= .c ---- linux-3.1.4/sound/soc/soc-pcm.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/sound/soc/soc-pcm.c 2011-11-16 18:39:08.000000000 -0500 -@@ -568,7 +568,7 @@ static snd_pcm_uframes_t soc_pcm_pointer +diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c +index 2879c88..224159e 100644 +--- a/sound/soc/soc-pcm.c ++++ b/sound/soc/soc-pcm.c +@@ -568,7 +568,7 @@ static snd_pcm_uframes_t soc_pcm_pointer(struct snd_= pcm_substream *substream) } =20 /* ASoC PCM operations */ @@ -78072,9 +79824,10 @@ diff -urNp linux-3.1.4/sound/soc/soc-pcm.c linux= -3.1.4/sound/soc/soc-pcm.c .open =3D soc_pcm_open, .close =3D soc_pcm_close, .hw_params =3D soc_pcm_hw_params, -diff -urNp linux-3.1.4/sound/usb/card.h linux-3.1.4/sound/usb/card.h ---- linux-3.1.4/sound/usb/card.h 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/sound/usb/card.h 2011-11-16 18:39:08.000000000 -0500 +diff --git a/sound/usb/card.h b/sound/usb/card.h +index ae4251d..0961361 100644 +--- a/sound/usb/card.h ++++ b/sound/usb/card.h @@ -44,6 +44,7 @@ struct snd_urb_ops { int (*prepare_sync)(struct snd_usb_substream *subs, struct snd_pcm_run= time *runtime, struct urb *u); int (*retire_sync)(struct snd_usb_substream *subs, struct snd_pcm_runt= ime *runtime, struct urb *u); @@ -78092,9 +79845,38 @@ diff -urNp linux-3.1.4/sound/usb/card.h linux-3.= 1.4/sound/usb/card.h }; =20 struct snd_usb_stream { -diff -urNp linux-3.1.4/tools/gcc/checker_plugin.c linux-3.1.4/tools/gcc/= checker_plugin.c ---- linux-3.1.4/tools/gcc/checker_plugin.c 1969-12-31 19:00:00.000000000= -0500 -+++ linux-3.1.4/tools/gcc/checker_plugin.c 2011-12-02 17:38:47.000000000= -0500 +diff --git a/tools/gcc/Makefile b/tools/gcc/Makefile +new file mode 100644 +index 0000000..b044b80 +--- /dev/null ++++ b/tools/gcc/Makefile +@@ -0,0 +1,21 @@ ++#CC :=3D gcc ++#PLUGIN_SOURCE_FILES :=3D pax_plugin.c ++#PLUGIN_OBJECT_FILES :=3D $(patsubst %.c,%.o,$(PLUGIN_SOURCE_FILES)) ++GCCPLUGINS_DIR :=3D $(shell $(CC) -print-file-name=3Dplugin) ++#CFLAGS +=3D -I$(GCCPLUGINS_DIR)/include -fPIC -O2 -Wall -W ++ ++HOST_EXTRACFLAGS +=3D -I$(GCCPLUGINS_DIR)/include ++ ++hostlibs-y :=3D constify_plugin.so ++hostlibs-$(CONFIG_PAX_MEMORY_STACKLEAK) +=3D stackleak_plugin.so ++hostlibs-$(CONFIG_KALLOCSTAT_PLUGIN) +=3D kallocstat_plugin.so ++hostlibs-$(CONFIG_PAX_KERNEXEC_PLUGIN) +=3D kernexec_plugin.so ++hostlibs-$(CONFIG_CHECKER_PLUGIN) +=3D checker_plugin.so ++ ++always :=3D $(hostlibs-y) ++ ++constify_plugin-objs :=3D constify_plugin.o ++stackleak_plugin-objs :=3D stackleak_plugin.o ++kallocstat_plugin-objs :=3D kallocstat_plugin.o ++kernexec_plugin-objs :=3D kernexec_plugin.o ++checker_plugin-objs :=3D checker_plugin.o +diff --git a/tools/gcc/checker_plugin.c b/tools/gcc/checker_plugin.c +new file mode 100644 +index 0000000..d41b5af +--- /dev/null ++++ b/tools/gcc/checker_plugin.c @@ -0,0 +1,171 @@ +/* + * Copyright 2011 by the PaX Team @@ -78267,9 +80049,11 @@ diff -urNp linux-3.1.4/tools/gcc/checker_plugin.= c linux-3.1.4/tools/gcc/checker_ + + return 0; +} -diff -urNp linux-3.1.4/tools/gcc/constify_plugin.c linux-3.1.4/tools/gcc= /constify_plugin.c ---- linux-3.1.4/tools/gcc/constify_plugin.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-3.1.4/tools/gcc/constify_plugin.c 2011-11-16 18:39:08.00000000= 0 -0500 +diff --git a/tools/gcc/constify_plugin.c b/tools/gcc/constify_plugin.c +new file mode 100644 +index 0000000..5b07edd +--- /dev/null ++++ b/tools/gcc/constify_plugin.c @@ -0,0 +1,303 @@ +/* + * Copyright 2011 by Emese Revfy @@ -78574,9 +80358,11 @@ diff -urNp linux-3.1.4/tools/gcc/constify_plugin= .c linux-3.1.4/tools/gcc/constif + + return 0; +} -diff -urNp linux-3.1.4/tools/gcc/kallocstat_plugin.c linux-3.1.4/tools/g= cc/kallocstat_plugin.c ---- linux-3.1.4/tools/gcc/kallocstat_plugin.c 1969-12-31 19:00:00.000000= 000 -0500 -+++ linux-3.1.4/tools/gcc/kallocstat_plugin.c 2011-11-16 18:39:08.000000= 000 -0500 +diff --git a/tools/gcc/kallocstat_plugin.c b/tools/gcc/kallocstat_plugin= .c +new file mode 100644 +index 0000000..a5eabce +--- /dev/null ++++ b/tools/gcc/kallocstat_plugin.c @@ -0,0 +1,167 @@ +/* + * Copyright 2011 by the PaX Team @@ -78745,9 +80531,11 @@ diff -urNp linux-3.1.4/tools/gcc/kallocstat_plug= in.c linux-3.1.4/tools/gcc/kallo + + return 0; +} -diff -urNp linux-3.1.4/tools/gcc/kernexec_plugin.c linux-3.1.4/tools/gcc= /kernexec_plugin.c ---- linux-3.1.4/tools/gcc/kernexec_plugin.c 1969-12-31 19:00:00.00000000= 0 -0500 -+++ linux-3.1.4/tools/gcc/kernexec_plugin.c 2011-12-02 17:38:47.00000000= 0 -0500 +diff --git a/tools/gcc/kernexec_plugin.c b/tools/gcc/kernexec_plugin.c +new file mode 100644 +index 0000000..51f747e +--- /dev/null ++++ b/tools/gcc/kernexec_plugin.c @@ -0,0 +1,348 @@ +/* + * Copyright 2011 by the PaX Team @@ -79097,34 +80885,11 @@ diff -urNp linux-3.1.4/tools/gcc/kernexec_plugi= n.c linux-3.1.4/tools/gcc/kernexe + + return 0; +} -diff -urNp linux-3.1.4/tools/gcc/Makefile linux-3.1.4/tools/gcc/Makefile ---- linux-3.1.4/tools/gcc/Makefile 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.1.4/tools/gcc/Makefile 2011-11-16 20:37:08.000000000 -0500 -@@ -0,0 +1,21 @@ -+#CC :=3D gcc -+#PLUGIN_SOURCE_FILES :=3D pax_plugin.c -+#PLUGIN_OBJECT_FILES :=3D $(patsubst %.c,%.o,$(PLUGIN_SOURCE_FILES)) -+GCCPLUGINS_DIR :=3D $(shell $(CC) -print-file-name=3Dplugin) -+#CFLAGS +=3D -I$(GCCPLUGINS_DIR)/include -fPIC -O2 -Wall -W -+ -+HOST_EXTRACFLAGS +=3D -I$(GCCPLUGINS_DIR)/include -+ -+hostlibs-y :=3D constify_plugin.so -+hostlibs-$(CONFIG_PAX_MEMORY_STACKLEAK) +=3D stackleak_plugin.so -+hostlibs-$(CONFIG_KALLOCSTAT_PLUGIN) +=3D kallocstat_plugin.so -+hostlibs-$(CONFIG_PAX_KERNEXEC_PLUGIN) +=3D kernexec_plugin.so -+hostlibs-$(CONFIG_CHECKER_PLUGIN) +=3D checker_plugin.so -+ -+always :=3D $(hostlibs-y) -+ -+constify_plugin-objs :=3D constify_plugin.o -+stackleak_plugin-objs :=3D stackleak_plugin.o -+kallocstat_plugin-objs :=3D kallocstat_plugin.o -+kernexec_plugin-objs :=3D kernexec_plugin.o -+checker_plugin-objs :=3D checker_plugin.o -diff -urNp linux-3.1.4/tools/gcc/stackleak_plugin.c linux-3.1.4/tools/gc= c/stackleak_plugin.c ---- linux-3.1.4/tools/gcc/stackleak_plugin.c 1969-12-31 19:00:00.0000000= 00 -0500 -+++ linux-3.1.4/tools/gcc/stackleak_plugin.c 2011-11-16 18:39:08.0000000= 00 -0500 +diff --git a/tools/gcc/stackleak_plugin.c b/tools/gcc/stackleak_plugin.c +new file mode 100644 +index 0000000..41dd4b1 +--- /dev/null ++++ b/tools/gcc/stackleak_plugin.c @@ -0,0 +1,291 @@ +/* + * Copyright 2011 by the PaX Team @@ -79417,9 +81182,10 @@ diff -urNp linux-3.1.4/tools/gcc/stackleak_plugi= n.c linux-3.1.4/tools/gcc/stackl + + return 0; +} -diff -urNp linux-3.1.4/tools/perf/util/include/asm/alternative-asm.h lin= ux-3.1.4/tools/perf/util/include/asm/alternative-asm.h ---- linux-3.1.4/tools/perf/util/include/asm/alternative-asm.h 2011-11-11= 15:19:27.000000000 -0500 -+++ linux-3.1.4/tools/perf/util/include/asm/alternative-asm.h 2011-12-02= 17:38:47.000000000 -0500 +diff --git a/tools/perf/util/include/asm/alternative-asm.h b/tools/perf/= util/include/asm/alternative-asm.h +index 6789d78..4afd019 100644 +--- a/tools/perf/util/include/asm/alternative-asm.h ++++ b/tools/perf/util/include/asm/alternative-asm.h @@ -5,4 +5,7 @@ =20 #define altinstruction_entry # @@ -79428,10 +81194,11 @@ diff -urNp linux-3.1.4/tools/perf/util/include/= asm/alternative-asm.h linux-3.1.4 + .endm + #endif -diff -urNp linux-3.1.4/usr/gen_init_cpio.c linux-3.1.4/usr/gen_init_cpio= .c ---- linux-3.1.4/usr/gen_init_cpio.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/usr/gen_init_cpio.c 2011-11-16 18:39:08.000000000 -0500 -@@ -303,7 +303,7 @@ static int cpio_mkfile(const char *name, +diff --git a/usr/gen_init_cpio.c b/usr/gen_init_cpio.c +index af0f22f..9a7d479 100644 +--- a/usr/gen_init_cpio.c ++++ b/usr/gen_init_cpio.c +@@ -303,7 +303,7 @@ static int cpio_mkfile(const char *name, const char = *location, int retval; int rc =3D -1; int namesize; @@ -79440,7 +81207,7 @@ diff -urNp linux-3.1.4/usr/gen_init_cpio.c linux-= 3.1.4/usr/gen_init_cpio.c =20 mode |=3D S_IFREG; =20 -@@ -392,9 +392,10 @@ static char *cpio_replace_env(char *new_ +@@ -392,9 +392,10 @@ static char *cpio_replace_env(char *new_location) *env_var =3D *expanded =3D '\0'; strncat(env_var, start + 2, end - start - 2); strncat(expanded, new_location, start - new_loca= tion); @@ -79453,9 +81220,10 @@ diff -urNp linux-3.1.4/usr/gen_init_cpio.c linux= -3.1.4/usr/gen_init_cpio.c } else break; } -diff -urNp linux-3.1.4/virt/kvm/kvm_main.c linux-3.1.4/virt/kvm/kvm_main= .c ---- linux-3.1.4/virt/kvm/kvm_main.c 2011-11-11 15:19:27.000000000 -0500 -+++ linux-3.1.4/virt/kvm/kvm_main.c 2011-11-16 18:39:08.000000000 -0500 +diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c +index aefdda3..8e8fbb9 100644 +--- a/virt/kvm/kvm_main.c ++++ b/virt/kvm/kvm_main.c @@ -73,7 +73,7 @@ LIST_HEAD(vm_list); =20 static cpumask_var_t cpus_hardware_enabled; @@ -79465,7 +81233,7 @@ diff -urNp linux-3.1.4/virt/kvm/kvm_main.c linux-= 3.1.4/virt/kvm/kvm_main.c =20 struct kmem_cache *kvm_vcpu_cache; EXPORT_SYMBOL_GPL(kvm_vcpu_cache); -@@ -2266,7 +2266,7 @@ static void hardware_enable_nolock(void=20 +@@ -2266,7 +2266,7 @@ static void hardware_enable_nolock(void *junk) =20 if (r) { cpumask_clear_cpu(cpu, cpus_hardware_enabled); @@ -79487,7 +81255,7 @@ diff -urNp linux-3.1.4/virt/kvm/kvm_main.c linux-= 3.1.4/virt/kvm/kvm_main.c hardware_disable_all_nolock(); r =3D -EBUSY; } -@@ -2588,7 +2588,7 @@ static void kvm_sched_out(struct preempt +@@ -2588,7 +2588,7 @@ static void kvm_sched_out(struct preempt_notifier = *pn, kvm_arch_vcpu_put(vcpu); } =20 @@ -79496,7 +81264,7 @@ diff -urNp linux-3.1.4/virt/kvm/kvm_main.c linux-= 3.1.4/virt/kvm/kvm_main.c struct module *module) { int r; -@@ -2651,7 +2651,7 @@ int kvm_init(void *opaque, unsigned vcpu +@@ -2651,7 +2651,7 @@ int kvm_init(void *opaque, unsigned vcpu_size, uns= igned vcpu_align, if (!vcpu_align) vcpu_align =3D __alignof__(struct kvm_vcpu); kvm_vcpu_cache =3D kmem_cache_create("kvm_vcpu", vcpu_size, vcpu_align= , @@ -79505,7 +81273,7 @@ diff -urNp linux-3.1.4/virt/kvm/kvm_main.c linux-= 3.1.4/virt/kvm/kvm_main.c if (!kvm_vcpu_cache) { r =3D -ENOMEM; goto out_free_3; -@@ -2661,9 +2661,11 @@ int kvm_init(void *opaque, unsigned vcpu +@@ -2661,9 +2661,11 @@ int kvm_init(void *opaque, unsigned vcpu_size, un= signed vcpu_align, if (r) goto out_free; =20