diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2011-11-22 09:31:20 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2011-11-22 09:31:20 +0000 |
commit | 16adb43e460bf8a7e8d3d34b5aee74e2e56c8088 (patch) | |
tree | 9bd56f10dc865590bc38df60d269a5452d47fd2b | |
parent | 30153ff3b13acd029a177a03c9fbe6ed6ec671b0 (diff) | |
download | aports-16adb43e460bf8a7e8d3d34b5aee74e2e56c8088.tar.bz2 aports-16adb43e460bf8a7e8d3d34b5aee74e2e56c8088.tar.xz |
main/*-grsec: upgrade to kernel 3.0.10 and rebase grsecurity patch
based on grsecurity-2.2.2-3.0.9-201111161802
-rw-r--r-- | main/dahdi-linux-grsec/APKBUILD | 4 | ||||
-rw-r--r-- | main/linux-grsec/APKBUILD | 10 | ||||
-rw-r--r-- | main/linux-grsec/grsecurity-2.2.2-3.0.10-unofficial.patch (renamed from main/linux-grsec/grsecurity-2.2.2-3.0.9-201111121310.patch) | 24074 | ||||
-rw-r--r-- | main/open-iscsi-grsec/APKBUILD | 6 | ||||
-rw-r--r-- | main/open-iscsi-grsec/Makefile-Alpine-kernels-support.patch | 2 | ||||
-rw-r--r-- | main/open-vm-tools-grsec/APKBUILD | 4 | ||||
-rw-r--r-- | main/xtables-addons-grsec/APKBUILD | 4 |
7 files changed, 12811 insertions, 11293 deletions
diff --git a/main/dahdi-linux-grsec/APKBUILD b/main/dahdi-linux-grsec/APKBUILD index f3ed843ce9..d807fe25c8 100644 --- a/main/dahdi-linux-grsec/APKBUILD +++ b/main/dahdi-linux-grsec/APKBUILD @@ -2,8 +2,8 @@ # Maintainer: Timo Teras <timo.teras@iki.fi> _flavor=grsec -_kver=3.0.9 -_kpkgrel=2 +_kver=3.0.10 +_kpkgrel=0 _mypkgrel=0 # verify the kernel version before entering chroot diff --git a/main/linux-grsec/APKBUILD b/main/linux-grsec/APKBUILD index 36ce8257ef..7b0261f04a 100644 --- a/main/linux-grsec/APKBUILD +++ b/main/linux-grsec/APKBUILD @@ -2,9 +2,9 @@ _flavor=grsec pkgname=linux-${_flavor} -pkgver=3.0.9 +pkgver=3.0.10 _kernver=3.0 -pkgrel=2 +pkgrel=0 pkgdesc="Linux kernel with grsecurity" url=http://grsecurity.net depends="mkinitfs linux-firmware" @@ -14,7 +14,7 @@ _config=${config:-kernelconfig.${CARCH}} install= source="ftp://ftp.kernel.org/pub/linux/kernel/v3.0/linux-$_kernver.tar.bz2 ftp://ftp.kernel.org/pub/linux/kernel/v3.0/patch-$pkgver.bz2 - grsecurity-2.2.2-3.0.9-201111121310.patch + grsecurity-2.2.2-3.0.10-unofficial.patch grsec-timblogiw-noconst.patch 0001-ip_gre-dont-increase-dev-needed_headroom-on-a-live-d.patch @@ -139,8 +139,8 @@ dev() { } md5sums="398e95866794def22b12dfbc15ce89c0 linux-3.0.tar.bz2 -0154d21e63d3f14fc1084cdb130fab2d patch-3.0.9.bz2 -32508aac1ff87cdc72227c86141ed549 grsecurity-2.2.2-3.0.9-201111121310.patch +8e0391dd935d838ee3023ab9daa6b447 patch-3.0.10.bz2 +cb9aa7ec8c615a5c3ba730ac951da9d2 grsecurity-2.2.2-3.0.10-unofficial.patch c41cf0ee9794f393423c6b2093072260 grsec-timblogiw-noconst.patch ebb99ef6ad8cd2d9fd8f49d5c5849057 0001-ip_gre-dont-increase-dev-needed_headroom-on-a-live-d.patch 776adeeb5272093574f8836c5037dd7d 0004-arp-flush-arp-cache-on-device-change.patch diff --git a/main/linux-grsec/grsecurity-2.2.2-3.0.9-201111121310.patch b/main/linux-grsec/grsecurity-2.2.2-3.0.10-unofficial.patch index 036623b69d..ad5496b8f7 100644 --- a/main/linux-grsec/grsecurity-2.2.2-3.0.9-201111121310.patch +++ b/main/linux-grsec/grsecurity-2.2.2-3.0.10-unofficial.patch @@ -1,7 +1,352 @@ -diff -urNp linux-3.0.9/arch/alpha/include/asm/elf.h linux-3.0.9/arch/alpha/include/asm/elf.h ---- linux-3.0.9/arch/alpha/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/alpha/include/asm/elf.h 2011-11-12 12:47:13.000000000 -0500 -@@ -90,6 +90,13 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_N +diff --git a/Documentation/dontdiff b/Documentation/dontdiff +index dfa6fc6..cdef560 100644 +--- a/Documentation/dontdiff ++++ b/Documentation/dontdiff +@@ -5,6 +5,7 @@ + *.cis + *.cpio + *.csp ++*.dbg + *.dsp + *.dvi + *.elf +@@ -48,9 +49,11 @@ + *.tab.h + *.tex + *.ver ++*.vim + *.xml + *.xz + *_MODULES ++*_reg_safe.h + *_vga16.c + *~ + \#*# +@@ -70,6 +73,7 @@ Kerntypes + Module.markers + Module.symvers + PENDING ++PERF* + SCCS + System.map* + TAGS +@@ -98,14 +102,18 @@ 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 +@@ -126,12 +134,14 @@ 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 + hpet_example + hugepage-mmap + hugepage-shm +@@ -146,7 +156,7 @@ int32.c + int4.c + int8.c + kallsyms +-kconfig ++kern_constants.h + keywords.c + ksym.c* + ksym.h* +@@ -154,7 +164,6 @@ kxgettext + lkc_defs.h + lex.c + lex.*.c +-linux + logo_*.c + logo_*_clut224.c + logo_*_mono.c +@@ -166,7 +175,6 @@ machtypes.h + map + map_hugetlb + maui_boot.h +-media + mconf + miboot* + mk_elfconfig +@@ -174,6 +182,7 @@ mkboot + mkbugboot + mkcpustr + mkdep ++mkpiggy + mkprep + mkregtable + mktables +@@ -209,6 +218,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 +229,7 @@ setup + setup.bin + setup.elf + sImage ++slabinfo + sm_tbl* + split-include + syscalltab.h +@@ -229,6 +240,7 @@ tftpboot.img + timeconst.h + times.h* + trix_boot.h ++user_constants.h + utsrelease.h* + vdso-syms.lds + vdso.lds +@@ -246,7 +258,9 @@ vmlinux + vmlinux-* + vmlinux.aout + vmlinux.bin.all ++vmlinux.bin.bz2 + vmlinux.lds ++vmlinux.relocs + vmlinuz + voffset.h + vsyscall.lds +@@ -254,6 +268,7 @@ vsyscall_32.lds + wanxlfw.inc + uImage + unifdef ++utsrelease.h + wakeup.bin + wakeup.elf + wakeup.lds +diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt +index aa47be7..1fbd18f 100644 +--- a/Documentation/kernel-parameters.txt ++++ b/Documentation/kernel-parameters.txt +@@ -1883,6 +1883,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. + ++ 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= 0/1 to disable/enable PaX softmode on boot already. ++ + pcbit= [HW,ISDN] + + pcd. [PARIDE] +diff --git a/Makefile b/Makefile +index 36036d1..167a8c6 100644 +--- a/Makefile ++++ b/Makefile +@@ -245,8 +245,9 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \ + + HOSTCC = gcc + HOSTCXX = g++ +-HOSTCFLAGS = -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer +-HOSTCXXFLAGS = -O2 ++HOSTCFLAGS = -Wall -W -Wmissing-prototypes -Wstrict-prototypes -Wno-unused-parameter -Wno-missing-field-initializers -O2 -fomit-frame-pointer -fno-delete-null-pointer-checks ++HOSTCFLAGS += $(call cc-option, -Wno-empty-body) ++HOSTCXXFLAGS = -O2 -fno-delete-null-pointer-checks + + # Decide whether to build built-in, modular, or both. + # Normally, just do built-in. +@@ -365,10 +366,12 @@ LINUXINCLUDE := -I$(srctree)/arch/$(hdr-arch)/include \ + KBUILD_CPPFLAGS := -D__KERNEL__ + + KBUILD_CFLAGS := -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs \ ++ -W -Wno-unused-parameter -Wno-missing-field-initializers \ + -fno-strict-aliasing -fno-common \ + -Werror-implicit-function-declaration \ + -Wno-format-security \ + -fno-delete-null-pointer-checks ++KBUILD_CFLAGS += $(call cc-option, -Wno-empty-body) + KBUILD_AFLAGS_KERNEL := + KBUILD_CFLAGS_KERNEL := + KBUILD_AFLAGS := -D__ASSEMBLY__ +@@ -407,8 +410,8 @@ export RCS_TAR_IGNORE := --exclude SCCS --exclude BitKeeper --exclude .svn --exc + # Rules shared between *config targets and build targets + + # Basic helpers built in scripts/ +-PHONY += scripts_basic +-scripts_basic: ++PHONY += scripts_basic gcc-plugins ++scripts_basic: gcc-plugins + $(Q)$(MAKE) $(build)=scripts/basic + $(Q)rm -f .tmp_quiet_recordmcount + +@@ -564,6 +567,36 @@ else + KBUILD_CFLAGS += -O2 + endif + ++ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-plugin.sh "$(HOSTCC)" "$(CC)"), y) ++CONSTIFY_PLUGIN := -fplugin=$(objtree)/tools/gcc/constify_plugin.so -DCONSTIFY_PLUGIN ++ifdef CONFIG_PAX_MEMORY_STACKLEAK ++STACKLEAK_PLUGIN := -fplugin=$(objtree)/tools/gcc/stackleak_plugin.so -fplugin-arg-stackleak_plugin-track-lowest-sp=100 ++endif ++ifdef CONFIG_KALLOCSTAT_PLUGIN ++KALLOCSTAT_PLUGIN := -fplugin=$(objtree)/tools/gcc/kallocstat_plugin.so ++endif ++ifdef CONFIG_PAX_KERNEXEC_PLUGIN ++KERNEXEC_PLUGIN := -fplugin=$(objtree)/tools/gcc/kernexec_plugin.so ++endif ++ifdef CONFIG_CHECKER_PLUGIN ++ifeq ($(call cc-ifversion, -ge, 0406, y), y) ++CHECKER_PLUGIN := -fplugin=$(objtree)/tools/gcc/checker_plugin.so -DCHECKER_PLUGIN ++endif ++endif ++GCC_PLUGINS := $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN) $(KALLOCSTAT_PLUGIN) $(KERNEXEC_PLUGIN) $(CHECKER_PLUGIN) ++export CONSTIFY_PLUGIN STACKLEAK_PLUGIN KERNEXEC_PLUGIN CHECKER_PLUGIN ++gcc-plugins: ++ $(Q)$(MAKE) $(build)=tools/gcc ++else ++gcc-plugins: ++ifeq ($(call cc-ifversion, -ge, 0405, y), y) ++ $(error Your gcc installation does not support plugins. If the necessary headers for plugin support are missing, they should be installed. On Debian, apt-get install gcc-<ver>-plugin-dev.)) ++else ++ $(Q)echo "warning, your gcc version does not support plugins, you should upgrade it to gcc 4.5 at least" ++endif ++ $(Q)echo "PAX_MEMORY_STACKLEAK and constification will be less secure" ++endif ++ + include $(srctree)/arch/$(SRCARCH)/Makefile + + ifneq ($(CONFIG_FRAME_WARN),0) +@@ -708,7 +741,7 @@ export mod_strip_cmd + + + ifeq ($(KBUILD_EXTMOD),) +-core-y += kernel/ mm/ fs/ ipc/ security/ crypto/ block/ ++core-y += kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ + + vmlinux-dirs := $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ + $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ +@@ -932,6 +965,7 @@ vmlinux.o: $(modpost-init) $(vmlinux-main) FORCE + + # The actual objects are generated when descending, + # make sure no implicit rule kicks in ++$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): KBUILD_CFLAGS += $(GCC_PLUGINS) + $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): $(vmlinux-dirs) ; + + # Handle descending into subdirectories listed in $(vmlinux-dirs) +@@ -941,7 +975,7 @@ $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): $(vmlinux-dirs) ; + # Error messages still appears in the original language + + PHONY += $(vmlinux-dirs) +-$(vmlinux-dirs): prepare scripts ++$(vmlinux-dirs): gcc-plugins prepare scripts + $(Q)$(MAKE) $(build)=$@ + + # Store (new) KERNELRELASE string in include/config/kernel.release +@@ -986,6 +1020,7 @@ prepare0: archprepare FORCE + $(Q)$(MAKE) $(build)=. missing-syscalls + + # All the preparing.. ++prepare: KBUILD_CFLAGS := $(filter-out $(GCC_PLUGINS),$(KBUILD_CFLAGS)) + prepare: prepare0 + + # Generate some files +@@ -1087,6 +1122,7 @@ all: modules + # using awk while concatenating to the final file. + + PHONY += modules ++modules: KBUILD_CFLAGS += $(GCC_PLUGINS) + modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin + $(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=$(objtree)/%/modules.order) > $(objtree)/modules.order + @$(kecho) ' Building modules, stage 2.'; +@@ -1102,7 +1138,7 @@ modules.builtin: $(vmlinux-dirs:%=%/modules.builtin) + + # Target to prepare building external modules + PHONY += modules_prepare +-modules_prepare: prepare scripts ++modules_prepare: gcc-plugins prepare scripts + + # Target to install modules + PHONY += modules_install +@@ -1198,7 +1234,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 + +@@ -1359,6 +1395,7 @@ PHONY += $(module-dirs) modules + $(module-dirs): crmodverdir $(objtree)/Module.symvers + $(Q)$(MAKE) $(build)=$(patsubst _module_%,%,$@) + ++modules: KBUILD_CFLAGS += $(GCC_PLUGINS) + modules: $(module-dirs) + @$(kecho) ' Building modules, stage 2.'; + $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost +@@ -1485,17 +1522,19 @@ else + target-dir = $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@)) + endif + +-%.s: %.c prepare scripts FORCE ++%.s: KBUILD_CFLAGS += $(GCC_PLUGINS) ++%.s: %.c gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) + %.i: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) +-%.o: %.c prepare scripts FORCE ++%.o: KBUILD_CFLAGS += $(GCC_PLUGINS) ++%.o: %.c gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) + %.lst: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) +-%.s: %.S prepare scripts FORCE ++%.s: %.S gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) +-%.o: %.S prepare scripts FORCE ++%.o: %.S gcc-plugins prepare scripts FORCE + $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) + %.symtypes: %.c prepare scripts FORCE + $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) +@@ -1505,11 +1544,13 @@ endif + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \ + $(build)=$(build-dir) +-%/: prepare scripts FORCE ++%/: KBUILD_CFLAGS += $(GCC_PLUGINS) ++%/: gcc-plugins prepare scripts FORCE + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \ + $(build)=$(build-dir) +-%.ko: prepare scripts FORCE ++%.ko: KBUILD_CFLAGS += $(GCC_PLUGINS) ++%.ko: gcc-plugins prepare scripts FORCE + $(cmd_crmodverdir) + $(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \ + $(build)=$(build-dir) $(@:.ko=.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]; #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x1000000) @@ -15,9 +360,10 @@ diff -urNp linux-3.0.9/arch/alpha/include/asm/elf.h linux-3.0.9/arch/alpha/inclu /* $0 is set by ld.so to a pointer to a function which might be 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.0.9/arch/alpha/include/asm/pgtable.h linux-3.0.9/arch/alpha/include/asm/pgtable.h ---- linux-3.0.9/arch/alpha/include/asm/pgtable.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/alpha/include/asm/pgtable.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/alpha/include/asm/pgtable.h b/arch/alpha/include/asm/pgtable.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 +382,11 @@ diff -urNp linux-3.0.9/arch/alpha/include/asm/pgtable.h linux-3.0.9/arch/alpha/i #define PAGE_KERNEL __pgprot(_PAGE_VALID | _PAGE_ASM | _PAGE_KRE | _PAGE_KWE) #define _PAGE_NORMAL(x) __pgprot(_PAGE_VALID | __ACCESS_BITS | (x)) -diff -urNp linux-3.0.9/arch/alpha/kernel/module.c linux-3.0.9/arch/alpha/kernel/module.c ---- linux-3.0.9/arch/alpha/kernel/module.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/alpha/kernel/module.c 2011-11-12 12:47:13.000000000 -0500 -@@ -182,7 +182,7 @@ apply_relocate_add(Elf64_Shdr *sechdrs, +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, /* The small sections were sorted to the end of the segment. The following should definitely cover them. */ @@ -48,10 +395,11 @@ diff -urNp linux-3.0.9/arch/alpha/kernel/module.c linux-3.0.9/arch/alpha/kernel/ got = sechdrs[me->arch.gotsecindex].sh_addr; for (i = 0; i < n; i++) { -diff -urNp linux-3.0.9/arch/alpha/kernel/osf_sys.c linux-3.0.9/arch/alpha/kernel/osf_sys.c ---- linux-3.0.9/arch/alpha/kernel/osf_sys.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/alpha/kernel/osf_sys.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1145,7 +1145,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 326f0a2..baed83e 100644 +--- a/arch/alpha/kernel/osf_sys.c ++++ b/arch/alpha/kernel/osf_sys.c +@@ -1145,7 +1145,7 @@ arch_get_unmapped_area_1(unsigned long addr, unsigned long len, /* At this point: (!vma || addr < vma->vm_end). */ if (limit - len < addr) return -ENOMEM; @@ -60,7 +408,7 @@ diff -urNp linux-3.0.9/arch/alpha/kernel/osf_sys.c linux-3.0.9/arch/alpha/kernel return addr; addr = vma->vm_end; vma = vma->vm_next; -@@ -1181,6 +1181,10 @@ arch_get_unmapped_area(struct file *filp +@@ -1181,6 +1181,10 @@ arch_get_unmapped_area(struct file *filp, unsigned long addr, merely specific addresses, but regions of memory -- perhaps this feature should be incorporated into all ports? */ @@ -71,7 +419,7 @@ diff -urNp linux-3.0.9/arch/alpha/kernel/osf_sys.c linux-3.0.9/arch/alpha/kernel if (addr) { addr = arch_get_unmapped_area_1 (PAGE_ALIGN(addr), len, limit); if (addr != (unsigned long) -ENOMEM) -@@ -1188,8 +1192,8 @@ arch_get_unmapped_area(struct file *filp +@@ -1188,8 +1192,8 @@ arch_get_unmapped_area(struct file *filp, unsigned long addr, } /* Next, try allocating at TASK_UNMAPPED_BASE. */ @@ -82,10 +430,11 @@ diff -urNp linux-3.0.9/arch/alpha/kernel/osf_sys.c linux-3.0.9/arch/alpha/kernel if (addr != (unsigned long) -ENOMEM) return addr; -diff -urNp linux-3.0.9/arch/alpha/mm/fault.c linux-3.0.9/arch/alpha/mm/fault.c ---- linux-3.0.9/arch/alpha/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/alpha/mm/fault.c 2011-11-12 12:47:13.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 fadd5f8..3168191 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); } @@ -210,7 +559,7 @@ diff -urNp linux-3.0.9/arch/alpha/mm/fault.c linux-3.0.9/arch/alpha/mm/fault.c /* * 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 = SEGV_ACCERR; if (cause < 0) { @@ -241,10 +590,11 @@ diff -urNp linux-3.0.9/arch/alpha/mm/fault.c linux-3.0.9/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.0.9/arch/arm/include/asm/elf.h linux-3.0.9/arch/arm/include/asm/elf.h ---- linux-3.0.9/arch/arm/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/include/asm/elf.h 2011-11-12 12:47:13.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_gregset_t *elfregs); the loader. We need to make sure that it is out of the way of the program that it will "exec", and that there is sufficient room for the brk. */ @@ -260,7 +610,7 @@ diff -urNp linux-3.0.9/arch/arm/include/asm/elf.h linux-3.0.9/arch/arm/include/a /* When the program starts, a1 contains a pointer to a function to be registered with atexit, as per the SVR4 ABI. A value of 0 means we -@@ -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_gregset_t *elfregs); extern void elf_set_personality(const struct elf32_hdr *); #define SET_PERSONALITY(ex) elf_set_personality(&(ex)) @@ -271,9 +621,10 @@ diff -urNp linux-3.0.9/arch/arm/include/asm/elf.h linux-3.0.9/arch/arm/include/a extern int vectors_user_mapping(void); #define arch_setup_additional_pages(bprm, uses_interp) vectors_user_mapping() #define ARCH_HAS_SETUP_ADDITIONAL_PAGES -diff -urNp linux-3.0.9/arch/arm/include/asm/kmap_types.h linux-3.0.9/arch/arm/include/asm/kmap_types.h ---- linux-3.0.9/arch/arm/include/asm/kmap_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/include/asm/kmap_types.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/arm/include/asm/kmap_types.h b/arch/arm/include/asm/kmap_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 +633,10 @@ diff -urNp linux-3.0.9/arch/arm/include/asm/kmap_types.h linux-3.0.9/arch/arm/in KM_TYPE_NR }; -diff -urNp linux-3.0.9/arch/arm/include/asm/uaccess.h linux-3.0.9/arch/arm/include/asm/uaccess.h ---- linux-3.0.9/arch/arm/include/asm/uaccess.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/include/asm/uaccess.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/arm/include/asm/uaccess.h b/arch/arm/include/asm/uaccess.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 +672,7 @@ diff -urNp linux-3.0.9/arch/arm/include/asm/uaccess.h linux-3.0.9/arch/arm/inclu extern unsigned long __must_check __copy_to_user_std(void __user *to, const void *from, unsigned long n); extern unsigned long __must_check __clear_user(void __user *addr, unsigned long n); extern unsigned long __must_check __clear_user_std(void __user *addr, unsigned long n); -@@ -403,6 +420,9 @@ extern unsigned long __must_check __strn +@@ -403,6 +420,9 @@ extern unsigned long __must_check __strnlen_user(const char __user *s, long n); static inline unsigned long __must_check copy_from_user(void *to, const void __user *from, unsigned long n) { @@ -330,7 +682,7 @@ diff -urNp linux-3.0.9/arch/arm/include/asm/uaccess.h linux-3.0.9/arch/arm/inclu if (access_ok(VERIFY_READ, from, n)) n = __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_user(void *to, const void __u static inline unsigned long __must_check copy_to_user(void __user *to, const void *from, unsigned long n) { @@ -340,9 +692,10 @@ diff -urNp linux-3.0.9/arch/arm/include/asm/uaccess.h linux-3.0.9/arch/arm/inclu if (access_ok(VERIFY_WRITE, to, n)) n = __copy_to_user(to, from, n); return n; -diff -urNp linux-3.0.9/arch/arm/kernel/armksyms.c linux-3.0.9/arch/arm/kernel/armksyms.c ---- linux-3.0.9/arch/arm/kernel/armksyms.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/kernel/armksyms.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/arm/kernel/armksyms.c b/arch/arm/kernel/armksyms.c +index acca35a..f7debc1 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 +707,10 @@ diff -urNp linux-3.0.9/arch/arm/kernel/armksyms.c linux-3.0.9/arch/arm/kernel/ar EXPORT_SYMBOL(__clear_user); EXPORT_SYMBOL(__get_user_1); -diff -urNp linux-3.0.9/arch/arm/kernel/process.c linux-3.0.9/arch/arm/kernel/process.c ---- linux-3.0.9/arch/arm/kernel/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/kernel/process.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c +index 5e1e541..6af2d90 100644 +--- a/arch/arm/kernel/process.c ++++ b/arch/arm/kernel/process.c @@ -28,7 +28,6 @@ #include <linux/tick.h> #include <linux/utsname.h> @@ -365,7 +719,7 @@ diff -urNp linux-3.0.9/arch/arm/kernel/process.c linux-3.0.9/arch/arm/kernel/pro #include <linux/hw_breakpoint.h> #include <asm/cacheflush.h> -@@ -479,12 +478,6 @@ unsigned long get_wchan(struct task_stru +@@ -479,12 +478,6 @@ unsigned long get_wchan(struct task_struct *p) return 0; } @@ -378,10 +732,11 @@ diff -urNp linux-3.0.9/arch/arm/kernel/process.c linux-3.0.9/arch/arm/kernel/pro #ifdef CONFIG_MMU /* * The vectors page is always readable from user space for the -diff -urNp linux-3.0.9/arch/arm/kernel/traps.c linux-3.0.9/arch/arm/kernel/traps.c ---- linux-3.0.9/arch/arm/kernel/traps.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/kernel/traps.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 6807cb1..552fd48 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 thread_info *thread, struct pt static DEFINE_SPINLOCK(die_lock); @@ -390,7 +745,7 @@ diff -urNp linux-3.0.9/arch/arm/kernel/traps.c linux-3.0.9/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 +755,10 @@ diff -urNp linux-3.0.9/arch/arm/kernel/traps.c linux-3.0.9/arch/arm/kernel/traps if (ret != NOTIFY_STOP) do_exit(SIGSEGV); } -diff -urNp linux-3.0.9/arch/arm/lib/copy_from_user.S linux-3.0.9/arch/arm/lib/copy_from_user.S ---- linux-3.0.9/arch/arm/lib/copy_from_user.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/lib/copy_from_user.S 2011-11-12 12:47:13.000000000 -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 +782,10 @@ diff -urNp linux-3.0.9/arch/arm/lib/copy_from_user.S linux-3.0.9/arch/arm/lib/co .pushsection .fixup,"ax" .align 0 -diff -urNp linux-3.0.9/arch/arm/lib/copy_to_user.S linux-3.0.9/arch/arm/lib/copy_to_user.S ---- linux-3.0.9/arch/arm/lib/copy_to_user.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/lib/copy_to_user.S 2011-11-12 12:47:13.000000000 -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 +809,10 @@ diff -urNp linux-3.0.9/arch/arm/lib/copy_to_user.S linux-3.0.9/arch/arm/lib/copy ENDPROC(__copy_to_user_std) .pushsection .fixup,"ax" -diff -urNp linux-3.0.9/arch/arm/lib/uaccess.S linux-3.0.9/arch/arm/lib/uaccess.S ---- linux-3.0.9/arch/arm/lib/uaccess.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/lib/uaccess.S 2011-11-12 12:47:13.000000000 -0500 +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 @@ #define PAGE_SHIFT 12 @@ -464,7 +822,7 @@ diff -urNp linux-3.0.9/arch/arm/lib/uaccess.S linux-3.0.9/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 @@ -473,7 +831,7 @@ diff -urNp linux-3.0.9/arch/arm/lib/uaccess.S linux-3.0.9/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 +848,7 @@ diff -urNp linux-3.0.9/arch/arm/lib/uaccess.S linux-3.0.9/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 @@ -499,7 +857,7 @@ diff -urNp linux-3.0.9/arch/arm/lib/uaccess.S linux-3.0.9/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 +866,10 @@ diff -urNp linux-3.0.9/arch/arm/lib/uaccess.S linux-3.0.9/arch/arm/lib/uaccess.S .pushsection .fixup,"ax" .align 0 -diff -urNp linux-3.0.9/arch/arm/lib/uaccess_with_memcpy.c linux-3.0.9/arch/arm/lib/uaccess_with_memcpy.c ---- linux-3.0.9/arch/arm/lib/uaccess_with_memcpy.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/lib/uaccess_with_memcpy.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/arm/lib/uaccess_with_memcpy.c b/arch/arm/lib/uaccess_with_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: } @@ -520,10 +879,11 @@ diff -urNp linux-3.0.9/arch/arm/lib/uaccess_with_memcpy.c linux-3.0.9/arch/arm/l { /* * This test is stubbed out of the main function above to keep -diff -urNp linux-3.0.9/arch/arm/mach-ux500/mbox-db5500.c linux-3.0.9/arch/arm/mach-ux500/mbox-db5500.c ---- linux-3.0.9/arch/arm/mach-ux500/mbox-db5500.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/mach-ux500/mbox-db5500.c 2011-11-12 12:47:13.000000000 -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/mbox-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); } @@ -532,10 +892,11 @@ diff -urNp linux-3.0.9/arch/arm/mach-ux500/mbox-db5500.c linux-3.0.9/arch/arm/ma static int mbox_show(struct seq_file *s, void *data) { -diff -urNp linux-3.0.9/arch/arm/mm/fault.c linux-3.0.9/arch/arm/mm/fault.c ---- linux-3.0.9/arch/arm/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/mm/fault.c 2011-11-12 12:47:13.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 bc0e1d8..9f27107 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 long addr, } #endif @@ -549,7 +910,7 @@ diff -urNp linux-3.0.9/arch/arm/mm/fault.c linux-3.0.9/arch/arm/mm/fault.c tsk->thread.address = addr; tsk->thread.error_code = fsr; tsk->thread.trap_no = 14; -@@ -379,6 +386,33 @@ do_page_fault(unsigned long addr, unsign +@@ -379,6 +386,33 @@ do_page_fault(unsigned long addr, unsigned int fsr, struct pt_regs *regs) } #endif /* CONFIG_MMU */ @@ -583,10 +944,11 @@ diff -urNp linux-3.0.9/arch/arm/mm/fault.c linux-3.0.9/arch/arm/mm/fault.c /* * First Level Translation Fault Handler * -diff -urNp linux-3.0.9/arch/arm/mm/mmap.c linux-3.0.9/arch/arm/mm/mmap.c ---- linux-3.0.9/arch/arm/mm/mmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/arm/mm/mmap.c 2011-11-12 12:47:13.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 long addr, if (len > TASK_SIZE) return -ENOMEM; @@ -597,7 +959,7 @@ diff -urNp linux-3.0.9/arch/arm/mm/mmap.c linux-3.0.9/arch/arm/mm/mmap.c if (addr) { if (do_align) addr = 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 long addr, addr = PAGE_ALIGN(addr); vma = find_vma(mm, addr); @@ -635,10 +997,11 @@ diff -urNp linux-3.0.9/arch/arm/mm/mmap.c linux-3.0.9/arch/arm/mm/mmap.c /* * Remember the place where we stopped the search: */ -diff -urNp linux-3.0.9/arch/avr32/include/asm/elf.h linux-3.0.9/arch/avr32/include/asm/elf.h ---- linux-3.0.9/arch/avr32/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/avr32/include/asm/elf.h 2011-11-12 12:47:13.000000000 -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 program that it will "exec", and that there is sufficient room for the brk. */ @@ -654,9 +1017,10 @@ diff -urNp linux-3.0.9/arch/avr32/include/asm/elf.h linux-3.0.9/arch/avr32/inclu /* 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.0.9/arch/avr32/include/asm/kmap_types.h linux-3.0.9/arch/avr32/include/asm/kmap_types.h ---- linux-3.0.9/arch/avr32/include/asm/kmap_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/avr32/include/asm/kmap_types.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/avr32/include/asm/kmap_types.h b/arch/avr32/include/asm/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 +1031,11 @@ diff -urNp linux-3.0.9/arch/avr32/include/asm/kmap_types.h linux-3.0.9/arch/avr3 }; #undef D -diff -urNp linux-3.0.9/arch/avr32/mm/fault.c linux-3.0.9/arch/avr32/mm/fault.c ---- linux-3.0.9/arch/avr32/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/avr32/mm/fault.c 2011-11-12 12:47:13.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 f7040a1..16169bf 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 *regs, int trap) int exception_trace = 1; @@ -711,9 +1076,10 @@ diff -urNp linux-3.0.9/arch/avr32/mm/fault.c linux-3.0.9/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.0.9/arch/frv/include/asm/kmap_types.h linux-3.0.9/arch/frv/include/asm/kmap_types.h ---- linux-3.0.9/arch/frv/include/asm/kmap_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/frv/include/asm/kmap_types.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/frv/include/asm/kmap_types.h b/arch/frv/include/asm/kmap_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 +1088,11 @@ diff -urNp linux-3.0.9/arch/frv/include/asm/kmap_types.h linux-3.0.9/arch/frv/in KM_TYPE_NR }; -diff -urNp linux-3.0.9/arch/frv/mm/elf-fdpic.c linux-3.0.9/arch/frv/mm/elf-fdpic.c ---- linux-3.0.9/arch/frv/mm/elf-fdpic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/frv/mm/elf-fdpic.c 2011-11-12 12:47:13.000000000 -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 = PAGE_ALIGN(addr); vma = find_vma(current->mm, addr); @@ -735,7 +1102,7 @@ diff -urNp linux-3.0.9/arch/frv/mm/elf-fdpic.c linux-3.0.9/arch/frv/mm/elf-fdpic goto success; } -@@ -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 = vma->vm_next) { if (addr > limit) break; @@ -744,7 +1111,7 @@ diff -urNp linux-3.0.9/arch/frv/mm/elf-fdpic.c linux-3.0.9/arch/frv/mm/elf-fdpic goto success; addr = 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 *filp, unsigned long addr, unsi for (; vma; vma = vma->vm_next) { if (addr > limit) break; @@ -753,9 +1120,10 @@ diff -urNp linux-3.0.9/arch/frv/mm/elf-fdpic.c linux-3.0.9/arch/frv/mm/elf-fdpic goto success; addr = vma->vm_end; } -diff -urNp linux-3.0.9/arch/ia64/include/asm/elf.h linux-3.0.9/arch/ia64/include/asm/elf.h ---- linux-3.0.9/arch/ia64/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/include/asm/elf.h 2011-11-12 12:47:13.000000000 -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 +1138,10 @@ diff -urNp linux-3.0.9/arch/ia64/include/asm/elf.h linux-3.0.9/arch/ia64/include #define PT_IA_64_UNWIND 0x70000001 /* IA-64 relocations: */ -diff -urNp linux-3.0.9/arch/ia64/include/asm/pgtable.h linux-3.0.9/arch/ia64/include/asm/pgtable.h ---- linux-3.0.9/arch/ia64/include/asm/pgtable.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/include/asm/pgtable.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/ia64/include/asm/pgtable.h b/arch/ia64/include/asm/pgtable.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 <davidm@hpl.hp.com> */ @@ -800,10 +1169,11 @@ diff -urNp linux-3.0.9/arch/ia64/include/asm/pgtable.h linux-3.0.9/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.0.9/arch/ia64/include/asm/spinlock.h linux-3.0.9/arch/ia64/include/asm/spinlock.h ---- linux-3.0.9/arch/ia64/include/asm/spinlock.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/include/asm/spinlock.h 2011-11-12 12:47:13.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/spinlock.h +index 1a91c91..120e693 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 = (unsigned short *)&lock->lock + 1, tmp; asm volatile ("ld2.bias %0=[%1]" : "=r"(tmp) : "r"(p)); @@ -812,10 +1182,11 @@ diff -urNp linux-3.0.9/arch/ia64/include/asm/spinlock.h linux-3.0.9/arch/ia64/in } static __always_inline void __ticket_spin_unlock_wait(arch_spinlock_t *lock) -diff -urNp linux-3.0.9/arch/ia64/include/asm/uaccess.h linux-3.0.9/arch/ia64/include/asm/uaccess.h ---- linux-3.0.9/arch/ia64/include/asm/uaccess.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/include/asm/uaccess.h 2011-11-12 12:47:13.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/uaccess.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 = (from); \ long __cu_len = (n); \ \ @@ -824,7 +1195,7 @@ diff -urNp linux-3.0.9/arch/ia64/include/asm/uaccess.h linux-3.0.9/arch/ia64/inc __cu_len = __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 = (n); \ \ __chk_user_ptr(__cu_from); \ @@ -833,9 +1204,10 @@ diff -urNp linux-3.0.9/arch/ia64/include/asm/uaccess.h linux-3.0.9/arch/ia64/inc __cu_len = __copy_user((__force void __user *) __cu_to, __cu_from, __cu_len); \ __cu_len; \ }) -diff -urNp linux-3.0.9/arch/ia64/kernel/module.c linux-3.0.9/arch/ia64/kernel/module.c ---- linux-3.0.9/arch/ia64/kernel/module.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/kernel/module.c 2011-11-12 12:47:13.000000000 -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) @@ -846,7 +1218,7 @@ diff -urNp linux-3.0.9/arch/ia64/kernel/module.c linux-3.0.9/arch/ia64/kernel/mo unw_remove_unwind_table(mod->arch.init_unw_table); mod->arch.init_unw_table = NULL; } -@@ -502,15 +501,39 @@ module_frob_arch_sections (Elf_Ehdr *ehd +@@ -502,15 +501,39 @@ module_frob_arch_sections (Elf_Ehdr *ehdr, Elf_Shdr *sechdrs, char *secstrings, } static inline int @@ -888,7 +1260,7 @@ diff -urNp linux-3.0.9/arch/ia64/kernel/module.c linux-3.0.9/arch/ia64/kernel/mo } 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; case RV_BDREL: @@ -904,7 +1276,7 @@ diff -urNp linux-3.0.9/arch/ia64/kernel/module.c linux-3.0.9/arch/ia64/kernel/mo break; case RV_LTV: -@@ -828,15 +858,15 @@ apply_relocate_add (Elf64_Shdr *sechdrs, +@@ -828,15 +858,15 @@ apply_relocate_add (Elf64_Shdr *sechdrs, const char *strtab, unsigned int symind * addresses have been selected... */ uint64_t gp; @@ -924,10 +1296,11 @@ diff -urNp linux-3.0.9/arch/ia64/kernel/module.c linux-3.0.9/arch/ia64/kernel/mo mod->arch.gp = gp; DEBUGP("%s: placing gp at 0x%lx\n", __func__, gp); } -diff -urNp linux-3.0.9/arch/ia64/kernel/sys_ia64.c linux-3.0.9/arch/ia64/kernel/sys_ia64.c ---- linux-3.0.9/arch/ia64/kernel/sys_ia64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/kernel/sys_ia64.c 2011-11-12 12:47:13.000000000 -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 long addr, unsigned long len if (REGION_NUMBER(addr) == RGN_HPAGE) addr = 0; #endif @@ -941,7 +1314,7 @@ diff -urNp linux-3.0.9/arch/ia64/kernel/sys_ia64.c linux-3.0.9/arch/ia64/kernel/ if (!addr) addr = mm->free_area_cache; -@@ -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 = find_vma(mm, addr); ; vma = vma->vm_next) { /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr || RGN_MAP_LIMIT - len < REGION_OFFSET(addr)) { @@ -959,9 +1332,10 @@ diff -urNp linux-3.0.9/arch/ia64/kernel/sys_ia64.c linux-3.0.9/arch/ia64/kernel/ /* Remember the address where we stopped this search: */ mm->free_area_cache = addr + len; return addr; -diff -urNp linux-3.0.9/arch/ia64/kernel/vmlinux.lds.S linux-3.0.9/arch/ia64/kernel/vmlinux.lds.S ---- linux-3.0.9/arch/ia64/kernel/vmlinux.lds.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/kernel/vmlinux.lds.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/ia64/kernel/vmlinux.lds.S b/arch/ia64/kernel/vmlinux.lds.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: */ . = ALIGN(PERCPU_PAGE_SIZE); @@ -971,10 +1345,11 @@ diff -urNp linux-3.0.9/arch/ia64/kernel/vmlinux.lds.S linux-3.0.9/arch/ia64/kern /* * ensure percpu data fits * into percpu page size -diff -urNp linux-3.0.9/arch/ia64/mm/fault.c linux-3.0.9/arch/ia64/mm/fault.c ---- linux-3.0.9/arch/ia64/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/mm/fault.c 2011-11-12 12:47:13.000000000 -0500 -@@ -73,6 +73,23 @@ mapped_kernel_page_is_present (unsigned +diff --git a/arch/ia64/mm/fault.c b/arch/ia64/mm/fault.c +index 20b3593..58762be 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); } @@ -998,7 +1373,7 @@ diff -urNp linux-3.0.9/arch/ia64/mm/fault.c linux-3.0.9/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 = ( (((isr >> IA64_ISR_X_BIT) & 1UL) << VM_EXEC_BIT) | (((isr >> IA64_ISR_W_BIT) & 1UL) << VM_WRITE_BIT)); @@ -1023,10 +1398,11 @@ diff -urNp linux-3.0.9/arch/ia64/mm/fault.c linux-3.0.9/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.0.9/arch/ia64/mm/hugetlbpage.c linux-3.0.9/arch/ia64/mm/hugetlbpage.c ---- linux-3.0.9/arch/ia64/mm/hugetlbpage.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/mm/hugetlbpage.c 2011-11-12 12:47:13.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 +1411,10 @@ diff -urNp linux-3.0.9/arch/ia64/mm/hugetlbpage.c linux-3.0.9/arch/ia64/mm/huget return addr; addr = ALIGN(vmm->vm_end, HPAGE_SIZE); } -diff -urNp linux-3.0.9/arch/ia64/mm/init.c linux-3.0.9/arch/ia64/mm/init.c ---- linux-3.0.9/arch/ia64/mm/init.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/ia64/mm/init.c 2011-11-12 12:47:13.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 = current->thread.rbs_bot & PAGE_MASK; vma->vm_end = vma->vm_start + PAGE_SIZE; @@ -1058,9 +1435,10 @@ diff -urNp linux-3.0.9/arch/ia64/mm/init.c linux-3.0.9/arch/ia64/mm/init.c vma->vm_page_prot = vm_get_page_prot(vma->vm_flags); down_write(¤t->mm->mmap_sem); if (insert_vm_struct(current->mm, vma)) { -diff -urNp linux-3.0.9/arch/m32r/lib/usercopy.c linux-3.0.9/arch/m32r/lib/usercopy.c ---- linux-3.0.9/arch/m32r/lib/usercopy.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/m32r/lib/usercopy.c 2011-11-12 12:47:13.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 +1449,7 @@ diff -urNp linux-3.0.9/arch/m32r/lib/usercopy.c linux-3.0.9/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, +@@ -23,6 +26,9 @@ __generic_copy_to_user(void __user *to, const void *from, unsigned long n) unsigned long __generic_copy_from_user(void *to, const void __user *from, unsigned long n) { @@ -1081,9 +1459,10 @@ diff -urNp linux-3.0.9/arch/m32r/lib/usercopy.c linux-3.0.9/arch/m32r/lib/userco prefetchw(to); if (access_ok(VERIFY_READ, from, n)) __copy_user_zeroing(to,from,n); -diff -urNp linux-3.0.9/arch/mips/include/asm/elf.h linux-3.0.9/arch/mips/include/asm/elf.h ---- linux-3.0.9/arch/mips/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/include/asm/elf.h 2011-11-12 12:47:13.000000000 -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 +1484,11 @@ diff -urNp linux-3.0.9/arch/mips/include/asm/elf.h linux-3.0.9/arch/mips/include -#define arch_randomize_brk arch_randomize_brk - #endif /* _ASM_ELF_H */ -diff -urNp linux-3.0.9/arch/mips/include/asm/page.h linux-3.0.9/arch/mips/include/asm/page.h ---- linux-3.0.9/arch/mips/include/asm/page.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/include/asm/page.h 2011-11-12 12:47:13.000000000 -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_high << 32)) @@ -1117,9 +1497,10 @@ diff -urNp linux-3.0.9/arch/mips/include/asm/page.h linux-3.0.9/arch/mips/includ #else typedef struct { unsigned long long pte; } pte_t; #define pte_val(x) ((x).pte) -diff -urNp linux-3.0.9/arch/mips/include/asm/system.h linux-3.0.9/arch/mips/include/asm/system.h ---- linux-3.0.9/arch/mips/include/asm/system.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/include/asm/system.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/mips/include/asm/system.h b/arch/mips/include/asm/system.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 +1509,11 @@ diff -urNp linux-3.0.9/arch/mips/include/asm/system.h linux-3.0.9/arch/mips/incl +#define arch_align_stack(x) ((x) & ~0xfUL) #endif /* _ASM_SYSTEM_H */ -diff -urNp linux-3.0.9/arch/mips/kernel/binfmt_elfn32.c linux-3.0.9/arch/mips/kernel/binfmt_elfn32.c ---- linux-3.0.9/arch/mips/kernel/binfmt_elfn32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/kernel/binfmt_elfn32.c 2011-11-12 12:47:13.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..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) @@ -1145,10 +1527,11 @@ diff -urNp linux-3.0.9/arch/mips/kernel/binfmt_elfn32.c linux-3.0.9/arch/mips/ke #include <asm/processor.h> #include <linux/module.h> #include <linux/elfcore.h> -diff -urNp linux-3.0.9/arch/mips/kernel/binfmt_elfo32.c linux-3.0.9/arch/mips/kernel/binfmt_elfo32.c ---- linux-3.0.9/arch/mips/kernel/binfmt_elfo32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/kernel/binfmt_elfo32.c 2011-11-12 12:47:13.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..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) @@ -1162,10 +1545,11 @@ diff -urNp linux-3.0.9/arch/mips/kernel/binfmt_elfo32.c linux-3.0.9/arch/mips/ke #include <asm/processor.h> /* -diff -urNp linux-3.0.9/arch/mips/kernel/process.c linux-3.0.9/arch/mips/kernel/process.c ---- linux-3.0.9/arch/mips/kernel/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/kernel/process.c 2011-11-12 12:47:13.000000000 -0500 -@@ -473,15 +473,3 @@ unsigned long get_wchan(struct task_stru +diff --git a/arch/mips/kernel/process.c b/arch/mips/kernel/process.c +index d2112d3..142ad93 100644 +--- a/arch/mips/kernel/process.c ++++ b/arch/mips/kernel/process.c +@@ -473,15 +473,3 @@ unsigned long get_wchan(struct task_struct *task) out: return pc; } @@ -1181,9 +1565,10 @@ diff -urNp linux-3.0.9/arch/mips/kernel/process.c linux-3.0.9/arch/mips/kernel/p - - return sp & ALMASK; -} -diff -urNp linux-3.0.9/arch/mips/mm/fault.c linux-3.0.9/arch/mips/mm/fault.c ---- linux-3.0.9/arch/mips/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/mm/fault.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/mips/mm/fault.c b/arch/mips/mm/fault.c +index 137ee76..1bc42da 100644 +--- a/arch/mips/mm/fault.c ++++ b/arch/mips/mm/fault.c @@ -28,6 +28,23 @@ #include <asm/highmem.h> /* For VMALLOC_END */ #include <linux/kdebug.h> @@ -1208,10 +1593,11 @@ diff -urNp linux-3.0.9/arch/mips/mm/fault.c linux-3.0.9/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.0.9/arch/mips/mm/mmap.c linux-3.0.9/arch/mips/mm/mmap.c ---- linux-3.0.9/arch/mips/mm/mmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/mips/mm/mmap.c 2011-11-12 12:47:13.000000000 -0500 -@@ -48,14 +48,18 @@ unsigned long arch_get_unmapped_area(str +diff --git a/arch/mips/mm/mmap.c b/arch/mips/mm/mmap.c +index ae3c20a..8e2402e 100644 +--- a/arch/mips/mm/mmap.c ++++ b/arch/mips/mm/mmap.c +@@ -48,14 +48,18 @@ unsigned long arch_get_unmapped_area(struct file *filp, unsigned long addr, do_color_align = 0; if (filp || (flags & MAP_SHARED)) do_color_align = 1; @@ -1232,7 +1618,7 @@ diff -urNp linux-3.0.9/arch/mips/mm/mmap.c linux-3.0.9/arch/mips/mm/mmap.c return addr; } addr = current->mm->mmap_base; -@@ -68,7 +72,7 @@ unsigned long arch_get_unmapped_area(str +@@ -68,7 +72,7 @@ unsigned long arch_get_unmapped_area(struct file *filp, unsigned long addr, /* At this point: (!vmm || addr < vmm->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1241,7 +1627,7 @@ diff -urNp linux-3.0.9/arch/mips/mm/mmap.c linux-3.0.9/arch/mips/mm/mmap.c return addr; addr = vmm->vm_end; if (do_color_align) -@@ -93,30 +97,3 @@ void arch_pick_mmap_layout(struct mm_str +@@ -93,30 +97,3 @@ void arch_pick_mmap_layout(struct mm_struct *mm) mm->get_unmapped_area = arch_get_unmapped_area; mm->unmap_area = arch_unmap_area; } @@ -1272,10 +1658,11 @@ diff -urNp linux-3.0.9/arch/mips/mm/mmap.c linux-3.0.9/arch/mips/mm/mmap.c - - return ret; -} -diff -urNp linux-3.0.9/arch/parisc/include/asm/elf.h linux-3.0.9/arch/parisc/include/asm/elf.h ---- linux-3.0.9/arch/parisc/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/parisc/include/asm/elf.h 2011-11-12 12:47:13.000000000 -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... */ #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE + 0x01000000) @@ -1289,9 +1676,10 @@ diff -urNp linux-3.0.9/arch/parisc/include/asm/elf.h linux-3.0.9/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.0.9/arch/parisc/include/asm/pgtable.h linux-3.0.9/arch/parisc/include/asm/pgtable.h ---- linux-3.0.9/arch/parisc/include/asm/pgtable.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/parisc/include/asm/pgtable.h 2011-11-12 12:47:13.000000000 -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_READ | _PAGE_EXEC |_PAGE_ACCESSED) #define PAGE_COPY PAGE_EXECREAD @@ -1310,9 +1698,10 @@ diff -urNp linux-3.0.9/arch/parisc/include/asm/pgtable.h linux-3.0.9/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.0.9/arch/parisc/kernel/module.c linux-3.0.9/arch/parisc/kernel/module.c ---- linux-3.0.9/arch/parisc/kernel/module.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/parisc/kernel/module.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/parisc/kernel/module.c b/arch/parisc/kernel/module.c +index cedbbb8..f9c332e 100644 +--- a/arch/parisc/kernel/module.c ++++ b/arch/parisc/kernel/module.c @@ -98,16 +98,38 @@ /* three functions to determine where in the module core @@ -1356,28 +1745,27 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/module.c linux-3.0.9/arch/parisc/kerne } 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, } /* align things a bit */ - me->core_size = ALIGN(me->core_size, 16); - me->arch.got_offset = me->core_size; - me->core_size += gots * sizeof(struct got_entry); -- -- me->core_size = ALIGN(me->core_size, 16); -- me->arch.fdesc_offset = me->core_size; -- me->core_size += fdescs * sizeof(Elf_Fdesc); + me->core_size_rw = ALIGN(me->core_size_rw, 16); + me->arch.got_offset = me->core_size_rw; + me->core_size_rw += gots * sizeof(struct got_entry); -+ + +- me->core_size = ALIGN(me->core_size, 16); +- me->arch.fdesc_offset = me->core_size; +- me->core_size += fdescs * sizeof(Elf_Fdesc); + me->core_size_rw = ALIGN(me->core_size_rw, 16); + me->arch.fdesc_offset = me->core_size_rw; + me->core_size_rw += fdescs * sizeof(Elf_Fdesc); me->arch.got_max = gots; me->arch.fdesc_max = fdescs; -@@ -397,7 +419,7 @@ static Elf64_Word get_got(struct module +@@ -397,7 +419,7 @@ static Elf64_Word get_got(struct module *me, unsigned long value, long addend) BUG_ON(value == 0); @@ -1386,7 +1774,7 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/module.c linux-3.0.9/arch/parisc/kerne for (i = 0; got[i].addr; i++) if (got[i].addr == value) goto out; -@@ -415,7 +437,7 @@ static Elf64_Word get_got(struct module +@@ -415,7 +437,7 @@ static Elf64_Word get_got(struct module *me, unsigned long value, long addend) #ifdef CONFIG_64BIT static Elf_Addr get_fdesc(struct module *me, unsigned long value) { @@ -1395,7 +1783,7 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/module.c linux-3.0.9/arch/parisc/kerne if (!value) { printk(KERN_ERR "%s: zero OPD requested!\n", me->name); -@@ -433,7 +455,7 @@ static Elf_Addr get_fdesc(struct module +@@ -433,7 +455,7 @@ static Elf_Addr get_fdesc(struct module *me, unsigned long value) /* Create new one */ fdesc->addr = value; @@ -1413,10 +1801,11 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/module.c linux-3.0.9/arch/parisc/kerne DEBUGP("register_unwind_table(), sect = %d at 0x%p - 0x%p (gp=0x%lx)\n", me->arch.unwind_section, table, end, gp); -diff -urNp linux-3.0.9/arch/parisc/kernel/sys_parisc.c linux-3.0.9/arch/parisc/kernel/sys_parisc.c ---- linux-3.0.9/arch/parisc/kernel/sys_parisc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/parisc/kernel/sys_parisc.c 2011-11-12 12:47:13.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_parisc.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 addr, unsigned long len) /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1425,7 +1814,7 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/sys_parisc.c linux-3.0.9/arch/parisc/k return addr; addr = 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_space *mapping, /* At this point: (!vma || addr < vma->vm_end). */ if (TASK_SIZE - len < addr) return -ENOMEM; @@ -1434,7 +1823,7 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/sys_parisc.c linux-3.0.9/arch/parisc/k return addr; addr = 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) @@ -1443,10 +1832,11 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/sys_parisc.c linux-3.0.9/arch/parisc/k if (filp) { addr = get_shared_area(filp->f_mapping, addr, len, pgoff); -diff -urNp linux-3.0.9/arch/parisc/kernel/traps.c linux-3.0.9/arch/parisc/kernel/traps.c ---- linux-3.0.9/arch/parisc/kernel/traps.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/parisc/kernel/traps.c 2011-11-12 12:47:13.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 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) down_read(¤t->mm->mmap_sem); vma = find_vma(current->mm,regs->iaoq[0]); @@ -1457,9 +1847,10 @@ diff -urNp linux-3.0.9/arch/parisc/kernel/traps.c linux-3.0.9/arch/parisc/kernel fault_address = regs->iaoq[0]; fault_space = regs->iasq[0]; -diff -urNp linux-3.0.9/arch/parisc/mm/fault.c linux-3.0.9/arch/parisc/mm/fault.c ---- linux-3.0.9/arch/parisc/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/parisc/mm/fault.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/parisc/mm/fault.c b/arch/parisc/mm/fault.c +index 18162ce..4d274ba 100644 +--- a/arch/parisc/mm/fault.c ++++ b/arch/parisc/mm/fault.c @@ -15,6 +15,7 @@ #include <linux/sched.h> #include <linux/interrupt.h> @@ -1468,7 +1859,7 @@ diff -urNp linux-3.0.9/arch/parisc/mm/fault.c linux-3.0.9/arch/parisc/mm/fault.c #include <asm/uaccess.h> #include <asm/traps.h> -@@ -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) { @@ -1477,7 +1868,7 @@ diff -urNp linux-3.0.9/arch/parisc/mm/fault.c linux-3.0.9/arch/parisc/mm/fault.c return VM_EXEC; switch (inst & 0xf0000000) { -@@ -138,6 +139,116 @@ parisc_acctyp(unsigned long code, unsign +@@ -138,6 +139,116 @@ parisc_acctyp(unsigned long code, unsigned int inst) } #endif @@ -1629,10 +2020,11 @@ diff -urNp linux-3.0.9/arch/parisc/mm/fault.c linux-3.0.9/arch/parisc/mm/fault.c /* * If for any reason at all we couldn't handle the fault, make -diff -urNp linux-3.0.9/arch/powerpc/include/asm/elf.h linux-3.0.9/arch/powerpc/include/asm/elf.h ---- linux-3.0.9/arch/powerpc/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/elf.h 2011-11-12 12:47:13.000000000 -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/elf.h +index 2b917c6..9859a0c 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_NVSRHALFREG]; the loader. We need to make sure that it is out of the way of the program that it will "exec", and that there is sufficient room for the brk. */ @@ -1654,7 +2046,7 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/elf.h linux-3.0.9/arch/powerpc/i /* * 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))) @@ -1664,9 +2056,10 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/elf.h linux-3.0.9/arch/powerpc/i #endif /* __KERNEL__ */ /* -diff -urNp linux-3.0.9/arch/powerpc/include/asm/kmap_types.h linux-3.0.9/arch/powerpc/include/asm/kmap_types.h ---- linux-3.0.9/arch/powerpc/include/asm/kmap_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/kmap_types.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/include/asm/kmap_types.h b/arch/powerpc/include/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, @@ -1675,10 +2068,11 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/kmap_types.h linux-3.0.9/arch/po KM_TYPE_NR }; -diff -urNp linux-3.0.9/arch/powerpc/include/asm/mman.h linux-3.0.9/arch/powerpc/include/asm/mman.h ---- linux-3.0.9/arch/powerpc/include/asm/mman.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/mman.h 2011-11-12 12:47:13.000000000 -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(unsigned long prot) } #define arch_calc_vm_prot_bits(prot) arch_calc_vm_prot_bits(prot) @@ -1687,33 +2081,10 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/mman.h linux-3.0.9/arch/powerpc/ { return (vm_flags & VM_SAO) ? __pgprot(_PAGE_SAO) : __pgprot(0); } -diff -urNp linux-3.0.9/arch/powerpc/include/asm/page_64.h linux-3.0.9/arch/powerpc/include/asm/page_64.h ---- linux-3.0.9/arch/powerpc/include/asm/page_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/page_64.h 2011-11-12 12:47:13.000000000 -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) - - #define VM_STACK_DEFAULT_FLAGS64 (VM_READ | VM_WRITE | \ - VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) - -+#ifndef CONFIG_PAX_PAGEEXEC - #define VM_STACK_DEFAULT_FLAGS \ - (is_32bit_task() ? \ - VM_STACK_DEFAULT_FLAGS32 : VM_STACK_DEFAULT_FLAGS64) -+#endif - - #include <asm-generic/getorder.h> - -diff -urNp linux-3.0.9/arch/powerpc/include/asm/page.h linux-3.0.9/arch/powerpc/include/asm/page.h ---- linux-3.0.9/arch/powerpc/include/asm/page.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/page.h 2011-11-12 12:47:13.000000000 -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. @@ -1736,9 +2107,35 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/page.h linux-3.0.9/arch/powerpc/ #ifndef __ASSEMBLY__ #undef STRICT_MM_TYPECHECKS -diff -urNp linux-3.0.9/arch/powerpc/include/asm/pgtable.h linux-3.0.9/arch/powerpc/include/asm/pgtable.h ---- linux-3.0.9/arch/powerpc/include/asm/pgtable.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/pgtable.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/include/asm/page_64.h b/arch/powerpc/include/asm/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) + + #define VM_STACK_DEFAULT_FLAGS64 (VM_READ | VM_WRITE | \ + VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) + ++#ifndef CONFIG_PAX_PAGEEXEC + #define VM_STACK_DEFAULT_FLAGS \ + (is_32bit_task() ? \ + VM_STACK_DEFAULT_FLAGS32 : VM_STACK_DEFAULT_FLAGS64) ++#endif + + #include <asm-generic/getorder.h> + +diff --git a/arch/powerpc/include/asm/pgtable.h b/arch/powerpc/include/asm/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__ @@ -1747,9 +2144,10 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/pgtable.h linux-3.0.9/arch/power #ifndef __ASSEMBLY__ #include <asm/processor.h> /* For TASK_SIZE */ #include <asm/mmu.h> -diff -urNp linux-3.0.9/arch/powerpc/include/asm/pte-hash32.h linux-3.0.9/arch/powerpc/include/asm/pte-hash32.h ---- linux-3.0.9/arch/powerpc/include/asm/pte-hash32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/pte-hash32.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/include/asm/pte-hash32.h b/arch/powerpc/include/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 */ @@ -1758,9 +2156,10 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/pte-hash32.h linux-3.0.9/arch/po #define _PAGE_COHERENT 0x010 /* M: enforce memory coherence (SMP systems) */ #define _PAGE_NO_CACHE 0x020 /* I: cache inhibit */ #define _PAGE_WRITETHRU 0x040 /* W: cache write-through */ -diff -urNp linux-3.0.9/arch/powerpc/include/asm/reg.h linux-3.0.9/arch/powerpc/include/asm/reg.h ---- linux-3.0.9/arch/powerpc/include/asm/reg.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/reg.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h +index c5cae0d..7cd4581 100644 +--- a/arch/powerpc/include/asm/reg.h ++++ b/arch/powerpc/include/asm/reg.h @@ -209,6 +209,7 @@ #define SPRN_DBCR 0x136 /* e300 Data Breakpoint Control Reg */ #define SPRN_DSISR 0x012 /* Data Storage Interrupt Status Register */ @@ -1769,10 +2168,11 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/reg.h linux-3.0.9/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.0.9/arch/powerpc/include/asm/system.h linux-3.0.9/arch/powerpc/include/asm/system.h ---- linux-3.0.9/arch/powerpc/include/asm/system.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/system.h 2011-11-12 12:47:13.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/asm/system.h +index 2dc595d..30cb50d 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 old, unsigned long new, #define cmpxchg64_local(ptr, o, n) __cmpxchg64_local_generic((ptr), (o), (n)) #endif @@ -1781,9 +2181,10 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/system.h linux-3.0.9/arch/powerp /* Used in very early kernel initialization. */ extern unsigned long reloc_offset(void); -diff -urNp linux-3.0.9/arch/powerpc/include/asm/uaccess.h linux-3.0.9/arch/powerpc/include/asm/uaccess.h ---- linux-3.0.9/arch/powerpc/include/asm/uaccess.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/include/asm/uaccess.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/include/asm/uaccess.h b/arch/powerpc/include/asm/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 @@ -1846,7 +2247,7 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/uaccess.h linux-3.0.9/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_inatomic(void *to, if (ret == 0) return 0; } @@ -1857,7 +2258,7 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/uaccess.h linux-3.0.9/arch/power return __copy_tofrom_user((__force void __user *)to, from, n); } -@@ -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 == 0) return 0; } @@ -1868,7 +2269,7 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/uaccess.h linux-3.0.9/arch/power return __copy_tofrom_user(to, (__force const void __user *)from, n); } -@@ -439,6 +403,92 @@ static inline unsigned long __copy_to_us +@@ -439,6 +403,92 @@ static inline unsigned long __copy_to_user(void __user *to, return __copy_to_user_inatomic(to, from, size); } @@ -1961,9 +2362,10 @@ diff -urNp linux-3.0.9/arch/powerpc/include/asm/uaccess.h linux-3.0.9/arch/power extern unsigned long __clear_user(void __user *addr, unsigned long size); static inline unsigned long clear_user(void __user *addr, unsigned long size) -diff -urNp linux-3.0.9/arch/powerpc/kernel/exceptions-64e.S linux-3.0.9/arch/powerpc/kernel/exceptions-64e.S ---- linux-3.0.9/arch/powerpc/kernel/exceptions-64e.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/exceptions-64e.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/kernel/exceptions-64e.S b/arch/powerpc/kernel/exceptions-64e.S +index d24d440..e0c0a37 100644 +--- a/arch/powerpc/kernel/exceptions-64e.S ++++ b/arch/powerpc/kernel/exceptions-64e.S @@ -567,6 +567,7 @@ storage_fault_common: std r14,_DAR(r1) std r15,_DSISR(r1) @@ -1982,9 +2384,10 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/exceptions-64e.S linux-3.0.9/arch/pow addi r3,r1,STACK_FRAME_OVERHEAD ld r4,_DAR(r1) bl .bad_page_fault -diff -urNp linux-3.0.9/arch/powerpc/kernel/exceptions-64s.S linux-3.0.9/arch/powerpc/kernel/exceptions-64s.S ---- linux-3.0.9/arch/powerpc/kernel/exceptions-64s.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/exceptions-64s.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/kernel/exceptions-64s.S b/arch/powerpc/kernel/exceptions-64s.S +index a85f487..6a07bde 100644 +--- a/arch/powerpc/kernel/exceptions-64s.S ++++ b/arch/powerpc/kernel/exceptions-64s.S @@ -956,10 +956,10 @@ handle_page_fault: 11: ld r4,_DAR(r1) ld r5,_DSISR(r1) @@ -1997,41 +2400,10 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/exceptions-64s.S linux-3.0.9/arch/pow mr r5,r3 addi r3,r1,STACK_FRAME_OVERHEAD lwz r4,_DAR(r1) -diff -urNp linux-3.0.9/arch/powerpc/kernel/module_32.c linux-3.0.9/arch/powerpc/kernel/module_32.c ---- linux-3.0.9/arch/powerpc/kernel/module_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/module_32.c 2011-11-12 12:47:13.000000000 -0500 -@@ -162,7 +162,7 @@ int module_frob_arch_sections(Elf32_Ehdr - me->arch.core_plt_section = 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; - } - -@@ -203,11 +203,16 @@ static uint32_t do_plt_call(void *locati - - DEBUGP("Doing plt for call to 0x%x at 0x%x\n", val, (unsigned int)location); - /* Init, or core PLT? */ -- if (location >= mod->module_core -- && location < mod->module_core + mod->core_size) -+ if ((location >= mod->module_core_rx && location < mod->module_core_rx + mod->core_size_rx) || -+ (location >= mod->module_core_rw && location < mod->module_core_rw + mod->core_size_rw)) - entry = (void *)sechdrs[mod->arch.core_plt_section].sh_addr; -- else -+ else if ((location >= mod->module_init_rx && location < mod->module_init_rx + mod->init_size_rx) || -+ (location >= mod->module_init_rw && location < mod->module_init_rw + mod->init_size_rw)) - entry = (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; -+ } - - /* Find this entry, or if that fails, the next avail. entry */ - while (entry->jump[0]) { -diff -urNp linux-3.0.9/arch/powerpc/kernel/module.c linux-3.0.9/arch/powerpc/kernel/module.c ---- linux-3.0.9/arch/powerpc/kernel/module.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/module.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/kernel/module.c b/arch/powerpc/kernel/module.c +index 49cee9d..e8be236 100644 +--- a/arch/powerpc/kernel/module.c ++++ b/arch/powerpc/kernel/module.c @@ -31,11 +31,24 @@ LIST_HEAD(module_bug_list); @@ -2057,7 +2429,7 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/module.c linux-3.0.9/arch/powerpc/ker return vmalloc_exec(size); } -@@ -45,6 +58,13 @@ void module_free(struct module *mod, voi +@@ -45,6 +58,13 @@ void module_free(struct module *mod, void *module_region) vfree(module_region); } @@ -2071,9 +2443,43 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/module.c linux-3.0.9/arch/powerpc/ker static const Elf_Shdr *find_section(const Elf_Ehdr *hdr, const Elf_Shdr *sechdrs, const char *name) -diff -urNp linux-3.0.9/arch/powerpc/kernel/process.c linux-3.0.9/arch/powerpc/kernel/process.c ---- linux-3.0.9/arch/powerpc/kernel/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/process.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/kernel/module_32.c b/arch/powerpc/kernel/module_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 = 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; + } + +@@ -203,11 +203,16 @@ static uint32_t do_plt_call(void *location, + + DEBUGP("Doing plt for call to 0x%x at 0x%x\n", val, (unsigned int)location); + /* Init, or core PLT? */ +- if (location >= mod->module_core +- && location < mod->module_core + mod->core_size) ++ if ((location >= mod->module_core_rx && location < mod->module_core_rx + mod->core_size_rx) || ++ (location >= mod->module_core_rw && location < mod->module_core_rw + mod->core_size_rw)) + entry = (void *)sechdrs[mod->arch.core_plt_section].sh_addr; +- else ++ else if ((location >= mod->module_init_rx && location < mod->module_init_rx + mod->init_size_rx) || ++ (location >= mod->module_init_rw && location < mod->module_init_rw + mod->init_size_rw)) + entry = (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; ++ } + + /* Find this entry, or if that fails, the next avail. entry */ + while (entry->jump[0]) { +diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process.c +index 91e52df..8bfc682 100644 +--- a/arch/powerpc/kernel/process.c ++++ b/arch/powerpc/kernel/process.c @@ -676,8 +676,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 @@ -2085,7 +2491,7 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/process.c linux-3.0.9/arch/powerpc/ke #endif show_stack(current, (unsigned long *) regs->gpr[1]); if (!user_mode(regs)) -@@ -1183,10 +1183,10 @@ void show_stack(struct task_struct *tsk, +@@ -1183,10 +1183,10 @@ void show_stack(struct task_struct *tsk, unsigned long *stack) newsp = stack[0]; ip = stack[STACK_FRAME_LR_SAVE]; if (!firstframe || ip != lr) { @@ -2098,7 +2504,7 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/process.c linux-3.0.9/arch/powerpc/ke (void *)current->ret_stack[curr_frame].ret); curr_frame--; } -@@ -1206,7 +1206,7 @@ void show_stack(struct task_struct *tsk, +@@ -1206,7 +1206,7 @@ void show_stack(struct task_struct *tsk, unsigned long *stack) struct pt_regs *regs = (struct pt_regs *) (sp + STACK_FRAME_OVERHEAD); lr = regs->link; @@ -2166,10 +2572,11 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/process.c linux-3.0.9/arch/powerpc/ke - - return ret; -} -diff -urNp linux-3.0.9/arch/powerpc/kernel/signal_32.c linux-3.0.9/arch/powerpc/kernel/signal_32.c ---- linux-3.0.9/arch/powerpc/kernel/signal_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/signal_32.c 2011-11-12 12:47:13.000000000 -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/signal_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_sigaction *ka, /* Save user registers on the stack */ frame = &rt_sf->uc.uc_mcontext; addr = frame; @@ -2178,10 +2585,11 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/signal_32.c linux-3.0.9/arch/powerpc/ if (save_user_regs(regs, frame, 0, 1)) goto badframe; regs->link = current->mm->context.vdso_base + vdso32_rt_sigtramp; -diff -urNp linux-3.0.9/arch/powerpc/kernel/signal_64.c linux-3.0.9/arch/powerpc/kernel/signal_64.c ---- linux-3.0.9/arch/powerpc/kernel/signal_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/signal_64.c 2011-11-12 12:47:13.000000000 -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/signal_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 = 0; /* Set up to return from userspace. */ @@ -2190,9 +2598,10 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/signal_64.c linux-3.0.9/arch/powerpc/ regs->link = current->mm->context.vdso_base + vdso64_rt_sigtramp; } else { err |= setup_trampoline(__NR_rt_sigreturn, &frame->tramp[0]); -diff -urNp linux-3.0.9/arch/powerpc/kernel/traps.c linux-3.0.9/arch/powerpc/kernel/traps.c ---- linux-3.0.9/arch/powerpc/kernel/traps.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/traps.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c +index 1a01414..ce48876 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 @@ -2202,7 +2611,7 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/traps.c linux-3.0.9/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 +@@ -171,6 +173,8 @@ int die(const char *str, struct pt_regs *regs, long err) if (panic_on_oops) panic("Fatal exception"); @@ -2211,9 +2620,10 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/traps.c linux-3.0.9/arch/powerpc/kern oops_exit(); do_exit(err); -diff -urNp linux-3.0.9/arch/powerpc/kernel/vdso.c linux-3.0.9/arch/powerpc/kernel/vdso.c ---- linux-3.0.9/arch/powerpc/kernel/vdso.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/kernel/vdso.c 2011-11-12 12:47:13.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 <asm/firmware.h> #include <asm/vdso.h> @@ -2222,7 +2632,7 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/vdso.c linux-3.0.9/arch/powerpc/kerne #include "setup.h" -@@ -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 = VDSO32_MBASE; #endif @@ -2231,7 +2641,7 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/vdso.c linux-3.0.9/arch/powerpc/kerne /* 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 = get_unmapped_area(NULL, vdso_base, (vdso_pages << PAGE_SHIFT) + ((VDSO_ALIGNMENT - 1) & PAGE_MASK), @@ -2240,9 +2650,10 @@ diff -urNp linux-3.0.9/arch/powerpc/kernel/vdso.c linux-3.0.9/arch/powerpc/kerne if (IS_ERR_VALUE(vdso_base)) { rc = vdso_base; goto fail_mmapsem; -diff -urNp linux-3.0.9/arch/powerpc/lib/usercopy_64.c linux-3.0.9/arch/powerpc/lib/usercopy_64.c ---- linux-3.0.9/arch/powerpc/lib/usercopy_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/lib/usercopy_64.c 2011-11-12 12:47:13.000000000 -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 <linux/module.h> #include <asm/uaccess.h> @@ -2266,7 +2677,7 @@ diff -urNp linux-3.0.9/arch/powerpc/lib/usercopy_64.c linux-3.0.9/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; } @@ -2274,9 +2685,10 @@ diff -urNp linux-3.0.9/arch/powerpc/lib/usercopy_64.c linux-3.0.9/arch/powerpc/l -EXPORT_SYMBOL(copy_to_user); EXPORT_SYMBOL(copy_in_user); -diff -urNp linux-3.0.9/arch/powerpc/mm/fault.c linux-3.0.9/arch/powerpc/mm/fault.c ---- linux-3.0.9/arch/powerpc/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/mm/fault.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/powerpc/mm/fault.c b/arch/powerpc/mm/fault.c +index ad35f66..a9f6aac 100644 +--- a/arch/powerpc/mm/fault.c ++++ b/arch/powerpc/mm/fault.c @@ -32,6 +32,10 @@ #include <linux/perf_event.h> #include <linux/magic.h> @@ -2296,7 +2708,7 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/fault.c linux-3.0.9/arch/powerpc/mm/fault #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 *regs) } #endif @@ -2330,7 +2742,7 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/fault.c linux-3.0.9/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, unsigned long address, * indicate errors in DSISR but can validly be set in SRR1. */ if (trap == 0x400) @@ -2381,10 +2793,11 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/fault.c linux-3.0.9/arch/powerpc/mm/fault _exception(SIGSEGV, regs, code, address); return 0; } -diff -urNp linux-3.0.9/arch/powerpc/mm/mmap_64.c linux-3.0.9/arch/powerpc/mm/mmap_64.c ---- linux-3.0.9/arch/powerpc/mm/mmap_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/mm/mmap_64.c 2011-11-12 12:47:13.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 = TASK_UNMAPPED_BASE; @@ -2407,10 +2820,11 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/mmap_64.c linux-3.0.9/arch/powerpc/mm/mma mm->get_unmapped_area = arch_get_unmapped_area_topdown; mm->unmap_area = arch_unmap_area_topdown; } -diff -urNp linux-3.0.9/arch/powerpc/mm/slice.c linux-3.0.9/arch/powerpc/mm/slice.c ---- linux-3.0.9/arch/powerpc/mm/slice.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/powerpc/mm/slice.c 2011-11-12 12:47:13.000000000 -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, unsigned long addr, if ((mm->task_size - len) < addr) return 0; vma = find_vma(mm, addr); @@ -2428,7 +2842,7 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/slice.c linux-3.0.9/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(struct mm_struct *mm, } } @@ -2446,7 +2860,7 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/slice.c linux-3.0.9/arch/powerpc/mm/slice /* Check for hit with different page size */ mask = 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 = find_vma(mm, addr); @@ -2455,7 +2869,7 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/slice.c linux-3.0.9/arch/powerpc/mm/slice /* remember the address as a hint for next time */ if (use_cache) mm->free_area_cache = 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 = vma->vm_start - addr; /* try just below the current vma->vm_start */ @@ -2464,7 +2878,7 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/slice.c linux-3.0.9/arch/powerpc/mm/slice } /* -@@ -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; @@ -2476,9 +2890,10 @@ diff -urNp linux-3.0.9/arch/powerpc/mm/slice.c linux-3.0.9/arch/powerpc/mm/slice /* If hint, make sure it matches our alignment restrictions */ if (!fixed && addr) { addr = _ALIGN_UP(addr, 1ul << pshift); -diff -urNp linux-3.0.9/arch/s390/include/asm/elf.h linux-3.0.9/arch/s390/include/asm/elf.h ---- linux-3.0.9/arch/s390/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/s390/include/asm/elf.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/s390/include/asm/elf.h b/arch/s390/include/asm/elf.h +index 64b61bf..7ec1411 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 program that it will "exec", and that there is sufficient room for the brk. */ @@ -2504,10 +2919,11 @@ diff -urNp linux-3.0.9/arch/s390/include/asm/elf.h linux-3.0.9/arch/s390/include -#define arch_randomize_brk arch_randomize_brk - #endif -diff -urNp linux-3.0.9/arch/s390/include/asm/system.h linux-3.0.9/arch/s390/include/asm/system.h ---- linux-3.0.9/arch/s390/include/asm/system.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/s390/include/asm/system.h 2011-11-12 12:47:13.000000000 -0500 -@@ -255,7 +255,7 @@ extern void (*_machine_restart)(char *co +diff --git a/arch/s390/include/asm/system.h b/arch/s390/include/asm/system.h +index d382629..3c80d03 100644 +--- a/arch/s390/include/asm/system.h ++++ b/arch/s390/include/asm/system.h +@@ -255,7 +255,7 @@ extern void (*_machine_restart)(char *command); extern void (*_machine_halt)(void); extern void (*_machine_power_off)(void); @@ -2516,9 +2932,10 @@ diff -urNp linux-3.0.9/arch/s390/include/asm/system.h linux-3.0.9/arch/s390/incl static inline int tprot(unsigned long addr) { -diff -urNp linux-3.0.9/arch/s390/include/asm/uaccess.h linux-3.0.9/arch/s390/include/asm/uaccess.h ---- linux-3.0.9/arch/s390/include/asm/uaccess.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/s390/include/asm/uaccess.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/s390/include/asm/uaccess.h b/arch/s390/include/asm/uaccess.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) { @@ -2530,7 +2947,7 @@ diff -urNp linux-3.0.9/arch/s390/include/asm/uaccess.h linux-3.0.9/arch/s390/inc if (access_ok(VERIFY_WRITE, to, n)) n = __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, unsigned long n) static inline unsigned long __must_check __copy_from_user(void *to, const void __user *from, unsigned long n) { @@ -2540,7 +2957,7 @@ diff -urNp linux-3.0.9/arch/s390/include/asm/uaccess.h linux-3.0.9/arch/s390/inc if (__builtin_constant_p(n) && (n <= 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, unsigned long n) unsigned int sz = __compiletime_object_size(to); might_fault(); @@ -2551,10 +2968,11 @@ diff -urNp linux-3.0.9/arch/s390/include/asm/uaccess.h linux-3.0.9/arch/s390/inc if (unlikely(sz != -1 && sz < n)) { copy_from_user_overflow(); return n; -diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/module.c ---- linux-3.0.9/arch/s390/kernel/module.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/s390/kernel/module.c 2011-11-12 12:47:13.000000000 -0500 -@@ -168,11 +168,11 @@ module_frob_arch_sections(Elf_Ehdr *hdr, +diff --git a/arch/s390/kernel/module.c b/arch/s390/kernel/module.c +index f7167ee..e22b6d5 100644 +--- a/arch/s390/kernel/module.c ++++ b/arch/s390/kernel/module.c +@@ -168,11 +168,11 @@ module_frob_arch_sections(Elf_Ehdr *hdr, Elf_Shdr *sechdrs, /* Increase core size by size of got & plt and set start offsets for got and plt. */ @@ -2571,7 +2989,7 @@ diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/mo return 0; } -@@ -258,7 +258,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -258,7 +258,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab, if (info->got_initialized == 0) { Elf_Addr *gotent; @@ -2580,7 +2998,7 @@ diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/mo info->got_offset; *gotent = val; info->got_initialized = 1; -@@ -282,7 +282,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -282,7 +282,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab, else if (r_type == R_390_GOTENT || r_type == R_390_GOTPLTENT) *(unsigned int *) loc = @@ -2589,7 +3007,7 @@ diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/mo else if (r_type == R_390_GOT64 || r_type == R_390_GOTPLT64) *(unsigned long *) loc = val; -@@ -296,7 +296,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -296,7 +296,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab, case R_390_PLTOFF64: /* 16 bit offset from GOT to PLT. */ if (info->plt_initialized == 0) { unsigned int *ip; @@ -2598,7 +3016,7 @@ diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/mo info->plt_offset; #ifndef CONFIG_64BIT ip[0] = 0x0d105810; /* basr 1,0; l 1,6(1); br 1 */ -@@ -321,7 +321,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -321,7 +321,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab, val - loc + 0xffffUL < 0x1ffffeUL) || (r_type == R_390_PLT32DBL && val - loc + 0xffffffffULL < 0x1fffffffeULL))) @@ -2607,7 +3025,7 @@ diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/mo me->arch.plt_offset + info->plt_offset; val += rela->r_addend - loc; -@@ -343,7 +343,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -343,7 +343,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab, case R_390_GOTOFF32: /* 32 bit offset to GOT. */ case R_390_GOTOFF64: /* 64 bit offset to GOT. */ val = val + rela->r_addend - @@ -2616,7 +3034,7 @@ diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/mo if (r_type == R_390_GOTOFF16) *(unsigned short *) loc = val; else if (r_type == R_390_GOTOFF32) -@@ -353,7 +353,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base +@@ -353,7 +353,7 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab, 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. */ @@ -2625,10 +3043,11 @@ diff -urNp linux-3.0.9/arch/s390/kernel/module.c linux-3.0.9/arch/s390/kernel/mo rela->r_addend - loc; if (r_type == R_390_GOTPC) *(unsigned int *) loc = val; -diff -urNp linux-3.0.9/arch/s390/kernel/process.c linux-3.0.9/arch/s390/kernel/process.c ---- linux-3.0.9/arch/s390/kernel/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/s390/kernel/process.c 2011-11-12 12:47:13.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; } @@ -2668,10 +3087,11 @@ diff -urNp linux-3.0.9/arch/s390/kernel/process.c linux-3.0.9/arch/s390/kernel/p - return base; - return ret; -} -diff -urNp linux-3.0.9/arch/s390/kernel/setup.c linux-3.0.9/arch/s390/kernel/setup.c ---- linux-3.0.9/arch/s390/kernel/setup.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/s390/kernel/setup.c 2011-11-12 12:47:13.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 0c35dee..540939a 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); @@ -2680,10 +3100,11 @@ diff -urNp linux-3.0.9/arch/s390/kernel/setup.c linux-3.0.9/arch/s390/kernel/set EXPORT_SYMBOL_GPL(user_mode); static int set_amode_and_uaccess(unsigned long user_amode, -diff -urNp linux-3.0.9/arch/s390/mm/mmap.c linux-3.0.9/arch/s390/mm/mmap.c ---- linux-3.0.9/arch/s390/mm/mmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/s390/mm/mmap.c 2011-11-12 12:47:13.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 = TASK_UNMAPPED_BASE; @@ -2706,7 +3127,7 @@ diff -urNp linux-3.0.9/arch/s390/mm/mmap.c linux-3.0.9/arch/s390/mm/mmap.c mm->get_unmapped_area = arch_get_unmapped_area_topdown; mm->unmap_area = 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 = TASK_UNMAPPED_BASE; @@ -2729,9 +3150,10 @@ diff -urNp linux-3.0.9/arch/s390/mm/mmap.c linux-3.0.9/arch/s390/mm/mmap.c mm->get_unmapped_area = s390_get_unmapped_area_topdown; mm->unmap_area = arch_unmap_area_topdown; } -diff -urNp linux-3.0.9/arch/score/include/asm/system.h linux-3.0.9/arch/score/include/asm/system.h ---- linux-3.0.9/arch/score/include/asm/system.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/score/include/asm/system.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/score/include/asm/system.h b/arch/score/include/asm/system.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) @@ -2741,10 +3163,11 @@ diff -urNp linux-3.0.9/arch/score/include/asm/system.h linux-3.0.9/arch/score/in #define mb() barrier() #define rmb() barrier() -diff -urNp linux-3.0.9/arch/score/kernel/process.c linux-3.0.9/arch/score/kernel/process.c ---- linux-3.0.9/arch/score/kernel/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/score/kernel/process.c 2011-11-12 12:47:13.000000000 -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) return task_pt_regs(task)->cp0_epc; } @@ -2753,10 +3176,11 @@ diff -urNp linux-3.0.9/arch/score/kernel/process.c linux-3.0.9/arch/score/kernel -{ - return sp; -} -diff -urNp linux-3.0.9/arch/sh/mm/mmap.c linux-3.0.9/arch/sh/mm/mmap.c ---- linux-3.0.9/arch/sh/mm/mmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sh/mm/mmap.c 2011-11-12 12:47:13.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 = PAGE_ALIGN(addr); vma = find_vma(mm, addr); @@ -2775,7 +3199,7 @@ diff -urNp linux-3.0.9/arch/sh/mm/mmap.c linux-3.0.9/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, const unsigned long addr0, addr = PAGE_ALIGN(addr); vma = find_vma(mm, addr); @@ -2785,7 +3209,7 @@ diff -urNp linux-3.0.9/arch/sh/mm/mmap.c linux-3.0.9/arch/sh/mm/mmap.c return addr; } -@@ -179,7 +177,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -179,7 +177,7 @@ arch_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 = find_vma(mm, addr-len); @@ -2794,7 +3218,7 @@ diff -urNp linux-3.0.9/arch/sh/mm/mmap.c linux-3.0.9/arch/sh/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache = 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; @@ -2817,7 +3241,7 @@ diff -urNp linux-3.0.9/arch/sh/mm/mmap.c linux-3.0.9/arch/sh/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache = addr); } -@@ -209,10 +207,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -209,10 +207,8 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, mm->cached_hole_size = vma->vm_start - addr; /* try just below the current vma->vm_start */ @@ -2830,9 +3254,23 @@ diff -urNp linux-3.0.9/arch/sh/mm/mmap.c linux-3.0.9/arch/sh/mm/mmap.c bottomup: /* -diff -urNp linux-3.0.9/arch/sparc/include/asm/atomic_64.h linux-3.0.9/arch/sparc/include/asm/atomic_64.h ---- linux-3.0.9/arch/sparc/include/asm/atomic_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/atomic_64.h 2011-11-12 12:47:13.000000000 -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) += arch/sparc/oprofile/ + # Export what is needed by arch/sparc/boot/Makefile + export VMLINUX_INIT VMLINUX_MAIN + VMLINUX_INIT := $(head-y) $(init-y) +-VMLINUX_MAIN := $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ block/ ++VMLINUX_MAIN := $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ + VMLINUX_MAIN += $(patsubst %/, %/lib.a, $(libs-y)) $(libs-y) + VMLINUX_MAIN += $(drivers-y) $(net-y) + +diff --git a/arch/sparc/include/asm/atomic_64.h b/arch/sparc/include/asm/atomic_64.h +index bdb2ff8..0e3008f 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) } @@ -2874,7 +3312,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/atomic_64.h linux-3.0.9/arch/sparc extern int atomic_sub_ret(int, atomic_t *); extern long atomic64_sub_ret(long, atomic64_t *); -@@ -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) #define atomic_inc_return(v) atomic_add_ret(1, v) @@ -2904,7 +3342,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/atomic_64.h linux-3.0.9/arch/sparc /* * 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) == 0) @@ -2915,7 +3353,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/atomic_64.h linux-3.0.9/arch/sparc #define atomic64_inc_and_test(v) (atomic64_inc_return(v) == 0) #define atomic_sub_and_test(i, v) (atomic_sub_ret(i, v) == 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) == 0) #define atomic_inc(v) atomic_add(1, v) @@ -2985,7 +3423,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/atomic_64.h linux-3.0.9/arch/sparc } #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, 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)) @@ -3025,9 +3463,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/atomic_64.h linux-3.0.9/arch/sparc } #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) -diff -urNp linux-3.0.9/arch/sparc/include/asm/cache.h linux-3.0.9/arch/sparc/include/asm/cache.h ---- linux-3.0.9/arch/sparc/include/asm/cache.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/cache.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/include/asm/cache.h b/arch/sparc/include/asm/cache.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) @@ -3037,9 +3476,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/cache.h linux-3.0.9/arch/sparc/inc #ifdef CONFIG_SPARC32 #define SMP_CACHE_BYTES_SHIFT 5 -diff -urNp linux-3.0.9/arch/sparc/include/asm/elf_32.h linux-3.0.9/arch/sparc/include/asm/elf_32.h ---- linux-3.0.9/arch/sparc/include/asm/elf_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/elf_32.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/include/asm/elf_32.h b/arch/sparc/include/asm/elf_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 { #define ELF_ET_DYN_BASE (TASK_UNMAPPED_BASE) @@ -3054,9 +3494,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/elf_32.h linux-3.0.9/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 userspace on Sparc. */ -diff -urNp linux-3.0.9/arch/sparc/include/asm/elf_64.h linux-3.0.9/arch/sparc/include/asm/elf_64.h ---- linux-3.0.9/arch/sparc/include/asm/elf_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/elf_64.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/include/asm/elf_64.h b/arch/sparc/include/asm/elf_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 @@ -3071,9 +3512,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/elf_64.h linux-3.0.9/arch/sparc/in extern unsigned long sparc64_elf_hwcap; #define ELF_HWCAP sparc64_elf_hwcap -diff -urNp linux-3.0.9/arch/sparc/include/asm/pgtable_32.h linux-3.0.9/arch/sparc/include/asm/pgtable_32.h ---- linux-3.0.9/arch/sparc/include/asm/pgtable_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/pgtable_32.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/include/asm/pgtable_32.h b/arch/sparc/include/asm/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) @@ -3105,9 +3547,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/pgtable_32.h linux-3.0.9/arch/spar extern unsigned long page_kernel; #ifdef MODULE -diff -urNp linux-3.0.9/arch/sparc/include/asm/pgtsrmmu.h linux-3.0.9/arch/sparc/include/asm/pgtsrmmu.h ---- linux-3.0.9/arch/sparc/include/asm/pgtsrmmu.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/pgtsrmmu.h 2011-11-12 12:47:13.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 | \ @@ -3122,10 +3565,11 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/pgtsrmmu.h linux-3.0.9/arch/sparc/ #define SRMMU_PAGE_KERNEL __pgprot(SRMMU_VALID | SRMMU_CACHE | SRMMU_PRIV | \ SRMMU_DIRTY | SRMMU_REF) -diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/arch/sparc/include/asm/spinlock_64.h ---- linux-3.0.9/arch/sparc/include/asm/spinlock_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/spinlock_64.h 2011-11-12 12:47:13.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/asm/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_spinlock_t *lock, unsigned long fla /* Multi-reader locks, these are much saner than the 32-bit Sparc ones... */ @@ -3147,7 +3591,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/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 *lock) " .previous" : "=&r" (tmp1), "=&r" (tmp2) : "r" (lock) @@ -3160,7 +3604,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/arch/spa { int tmp1, tmp2; -@@ -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" @@ -3174,7 +3618,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/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; } @@ -3195,7 +3639,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/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 *lock) : "memory"); } @@ -3204,7 +3648,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/arch/spa { unsigned long mask, tmp1, tmp2; -@@ -177,7 +192,7 @@ static void inline arch_write_lock(arch_ +@@ -177,7 +192,7 @@ static void inline arch_write_lock(arch_rwlock_t *lock) : "memory"); } @@ -3213,7 +3657,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/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"); } @@ -3222,9 +3666,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/spinlock_64.h linux-3.0.9/arch/spa { unsigned long mask, tmp1, tmp2, result; -diff -urNp linux-3.0.9/arch/sparc/include/asm/thread_info_32.h linux-3.0.9/arch/sparc/include/asm/thread_info_32.h ---- linux-3.0.9/arch/sparc/include/asm/thread_info_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/thread_info_32.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/include/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; @@ -3234,9 +3679,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/thread_info_32.h linux-3.0.9/arch/ }; /* -diff -urNp linux-3.0.9/arch/sparc/include/asm/thread_info_64.h linux-3.0.9/arch/sparc/include/asm/thread_info_64.h ---- linux-3.0.9/arch/sparc/include/asm/thread_info_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/thread_info_64.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/include/asm/thread_info_64.h b/arch/sparc/include/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; @@ -3246,10 +3692,29 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/thread_info_64.h linux-3.0.9/arch/ unsigned long fpregs[0] __attribute__ ((aligned(64))); }; -diff -urNp linux-3.0.9/arch/sparc/include/asm/uaccess_32.h linux-3.0.9/arch/sparc/include/asm/uaccess_32.h ---- linux-3.0.9/arch/sparc/include/asm/uaccess_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/uaccess_32.h 2011-11-12 12:47:13.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/uaccess.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 <linux/types.h> ++extern void check_object_size(const void *ptr, unsigned long n, bool to); ++#endif ++#endif ++ + #if defined(__sparc__) && defined(__arch64__) + #include <asm/uaccess_64.h> + #else +diff --git a/arch/sparc/include/asm/uaccess_32.h b/arch/sparc/include/asm/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 static inline unsigned long copy_to_user(void __user *to, const void *from, unsigned long n) { @@ -3300,9 +3765,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/uaccess_32.h linux-3.0.9/arch/spar return __copy_user((__force void __user *) to, from, n); } -diff -urNp linux-3.0.9/arch/sparc/include/asm/uaccess_64.h linux-3.0.9/arch/sparc/include/asm/uaccess_64.h ---- linux-3.0.9/arch/sparc/include/asm/uaccess_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/uaccess_64.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/include/asm/uaccess_64.h b/arch/sparc/include/asm/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 <linux/compiler.h> #include <linux/string.h> @@ -3311,7 +3777,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/uaccess_64.h linux-3.0.9/arch/spar #include <asm/asi.h> #include <asm/system.h> #include <asm/spitfire.h> -@@ -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) { @@ -3328,7 +3794,7 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/uaccess_64.h linux-3.0.9/arch/spar if (unlikely(ret)) ret = copy_from_user_fixup(to, from, size); -@@ -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) { @@ -3345,26 +3811,10 @@ diff -urNp linux-3.0.9/arch/sparc/include/asm/uaccess_64.h linux-3.0.9/arch/spar if (unlikely(ret)) ret = copy_to_user_fixup(to, from, size); return ret; -diff -urNp linux-3.0.9/arch/sparc/include/asm/uaccess.h linux-3.0.9/arch/sparc/include/asm/uaccess.h ---- linux-3.0.9/arch/sparc/include/asm/uaccess.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/include/asm/uaccess.h 2011-11-12 12:47:13.000000000 -0500 -@@ -1,5 +1,13 @@ - #ifndef ___ASM_SPARC_UACCESS_H - #define ___ASM_SPARC_UACCESS_H -+ -+#ifdef __KERNEL__ -+#ifndef __ASSEMBLY__ -+#include <linux/types.h> -+extern void check_object_size(const void *ptr, unsigned long n, bool to); -+#endif -+#endif -+ - #if defined(__sparc__) && defined(__arch64__) - #include <asm/uaccess_64.h> - #else -diff -urNp linux-3.0.9/arch/sparc/kernel/Makefile linux-3.0.9/arch/sparc/kernel/Makefile ---- linux-3.0.9/arch/sparc/kernel/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/Makefile 2011-11-12 12:47:13.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 @@ # @@ -3374,9 +3824,10 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/Makefile linux-3.0.9/arch/sparc/kernel/ extra-y := head_$(BITS).o extra-y += init_task.o -diff -urNp linux-3.0.9/arch/sparc/kernel/process_32.c linux-3.0.9/arch/sparc/kernel/process_32.c ---- linux-3.0.9/arch/sparc/kernel/process_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/process_32.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/kernel/process_32.c b/arch/sparc/kernel/process_32.c +index c8cc461..4e2b1b4 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], @@ -3403,7 +3854,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/process_32.c linux-3.0.9/arch/sparc/ker 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 long *_ksp) rw = (struct reg_window32 *) fp; pc = rw->ins[7]; printk("[%08lx : ", pc); @@ -3412,10 +3863,11 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/process_32.c linux-3.0.9/arch/sparc/ker fp = rw->ins[6]; } while (++count < 16); printk("\n"); -diff -urNp linux-3.0.9/arch/sparc/kernel/process_64.c linux-3.0.9/arch/sparc/kernel/process_64.c ---- linux-3.0.9/arch/sparc/kernel/process_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/process_64.c 2011-11-12 12:47:13.000000000 -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 c158a95..f041966 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) @@ -3441,7 +3893,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/process_64.c linux-3.0.9/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)); if (gp->tstate & TSTATE_PRIV) { @@ -3450,10 +3902,11 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/process_64.c linux-3.0.9/arch/sparc/ker (void *) gp->tpc, (void *) gp->o7, (void *) gp->i7, -diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_32.c linux-3.0.9/arch/sparc/kernel/sys_sparc_32.c ---- linux-3.0.9/arch/sparc/kernel/sys_sparc_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/sys_sparc_32.c 2011-11-12 12:47:13.000000000 -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_sparc_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) @@ -3462,7 +3915,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_32.c linux-3.0.9/arch/sparc/k if (flags & MAP_SHARED) addr = 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; @@ -3471,10 +3924,11 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_32.c linux-3.0.9/arch/sparc/k return addr; addr = vmm->vm_end; if (flags & MAP_SHARED) -diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c ---- linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c 2011-11-12 12:47:13.000000000 -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_sparc_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 *filp, unsigned long addr, unsi /* We do not accept a shared mapping if it would violate * cache aliasing constraints. */ @@ -3483,7 +3937,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/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 *filp, unsigned long addr, unsi if (filp || (flags & MAP_SHARED)) do_color_align = 1; @@ -3494,7 +3948,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/k if (addr) { if (do_color_align) addr = 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 = PAGE_ALIGN(addr); vma = find_vma(mm, addr); @@ -3531,7 +3985,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/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, const unsigned long addr0, /* We do not accept a shared mapping if it would violate * cache aliasing constraints. */ @@ -3540,7 +3994,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/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, const unsigned long addr0, addr = PAGE_ALIGN(addr); vma = find_vma(mm, addr); @@ -3550,7 +4004,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/k return addr; } -@@ -258,7 +260,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -258,7 +260,7 @@ arch_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 = find_vma(mm, addr-len); @@ -3559,7 +4013,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/k /* remember the address as a hint for next time */ return (mm->free_area_cache = 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; @@ -3582,7 +4036,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/k /* remember the address as a hint for next time */ return (mm->free_area_cache = addr); } -@@ -288,10 +290,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -288,10 +290,8 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, mm->cached_hole_size = vma->vm_start - addr; /* try just below the current vma->vm_start */ @@ -3595,7 +4049,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/k 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 == RLIM_INFINITY || sysctl_legacy_va_layout) { mm->mmap_base = TASK_UNMAPPED_BASE + random_factor; @@ -3608,7 +4062,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/k mm->get_unmapped_area = arch_get_unmapped_area; mm->unmap_area = 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 = (task_size / 6 * 5); mm->mmap_base = PAGE_ALIGN(task_size - gap - random_factor); @@ -3621,10 +4075,11 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/sys_sparc_64.c linux-3.0.9/arch/sparc/k mm->get_unmapped_area = arch_get_unmapped_area_topdown; mm->unmap_area = arch_unmap_area_topdown; } -diff -urNp linux-3.0.9/arch/sparc/kernel/traps_32.c linux-3.0.9/arch/sparc/kernel/traps_32.c ---- linux-3.0.9/arch/sparc/kernel/traps_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/traps_32.c 2011-11-12 12:47:13.000000000 -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") @@ -3633,7 +4088,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_32.c linux-3.0.9/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) >= PAGE_OFFSET) && !(((unsigned long) rw) & 0x7)) { @@ -3653,10 +4108,11 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_32.c linux-3.0.9/arch/sparc/kerne do_exit(SIGSEGV); } -diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/arch/sparc/kernel/traps_64.c ---- linux-3.0.9/arch/sparc/kernel/traps_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/traps_64.c 2011-11-12 12:47:13.000000000 -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); @@ -3665,7 +4121,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/arch/sparc/kerne } } -@@ -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) lvl -= 0x100; if (regs->tstate & TSTATE_PRIV) { @@ -3678,7 +4134,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/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]; @@ -3696,7 +4152,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/arch/sparc/kerne dump_tl1_traplog((struct tl1_traplog *)(regs + 1)); 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 *regs, 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()); @@ -3705,7 +4161,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/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); @@ -3714,7 +4170,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/arch/sparc/kerne panic("Irrecoverable Cheetah+ parity error."); } -@@ -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); @@ -3723,7 +4179,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/arch/sparc/kerne } 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) printk(KERN_EMERG "SUN4V-ITLB: Error at TPC[%lx], tl %d\n", regs->tpc, tl); @@ -3735,7 +4191,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/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) printk(KERN_EMERG "SUN4V-DTLB: Error at TPC[%lx], tl %d\n", regs->tpc, tl); @@ -3747,7 +4203,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/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, unsigned long *_ksp) fp = (unsigned long)sf->fp + STACK_BIAS; } @@ -3763,7 +4219,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/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(struct reg_window *rw) return (struct reg_window *) (fp + STACK_BIAS); } @@ -3772,7 +4228,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/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)) { @@ -3781,7 +4237,7 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/arch/sparc/kerne (void *) rw->ins[7]); rw = 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 *regs) } user_instruction_dump ((unsigned int __user *) regs->tpc); } @@ -3793,10 +4249,11 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/traps_64.c linux-3.0.9/arch/sparc/kerne do_exit(SIGSEGV); } EXPORT_SYMBOL(die_if_kernel); -diff -urNp linux-3.0.9/arch/sparc/kernel/unaligned_64.c linux-3.0.9/arch/sparc/kernel/unaligned_64.c ---- linux-3.0.9/arch/sparc/kernel/unaligned_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/kernel/unaligned_64.c 2011-11-12 12:47:13.000000000 -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/unaligned_64.c +index 9043106..22ca20a 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); if (__ratelimit(&ratelimit)) { @@ -3805,9 +4262,23 @@ diff -urNp linux-3.0.9/arch/sparc/kernel/unaligned_64.c linux-3.0.9/arch/sparc/k regs->tpc, (void *) regs->tpc); } } -diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/arch/sparc/lib/atomic_64.S ---- linux-3.0.9/arch/sparc/lib/atomic_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/lib/atomic_64.S 2011-11-12 12:47:13.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 @@ + # + + asflags-y := -ansi -DST_DIV0=0x02 +-ccflags-y := -Werror ++#ccflags-y := -Werror + + lib-$(CONFIG_SPARC32) += mul.o rem.o sdiv.o udiv.o umul.o urem.o ashrdi3.o + lib-$(CONFIG_SPARC32) += 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 = increment, %o1 = atomic_ptr */ BACKOFF_SETUP(%o2) @@ -3822,7 +4293,7 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/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 = increment, %o1 = at +@@ -28,12 +33,32 @@ atomic_add: /* %o0 = increment, %o1 = atomic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_add, .-atomic_add @@ -3856,7 +4327,7 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/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 = decrement, %o1 = at +@@ -43,12 +68,32 @@ atomic_sub: /* %o0 = decrement, %o1 = atomic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_sub, .-atomic_sub @@ -3890,7 +4361,7 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/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 = increment, %o1 +@@ -58,12 +103,33 @@ atomic_add_ret: /* %o0 = increment, %o1 = atomic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic_add_ret, .-atomic_add_ret @@ -3925,7 +4396,7 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/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 = decrement, %o1 +@@ -78,7 +144,12 @@ atomic_sub_ret: /* %o0 = decrement, %o1 = atomic_ptr */ atomic64_add: /* %o0 = increment, %o1 = atomic_ptr */ BACKOFF_SETUP(%o2) 1: ldx [%o1], %g1 @@ -3939,7 +4410,7 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/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 = increment, %o1 = +@@ -88,12 +159,32 @@ atomic64_add: /* %o0 = increment, %o1 = atomic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_add, .-atomic64_add @@ -3973,7 +4444,7 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/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 = decrement, %o1 = +@@ -103,12 +194,32 @@ atomic64_sub: /* %o0 = decrement, %o1 = atomic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_sub, .-atomic64_sub @@ -4007,7 +4478,7 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/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 = increment, %o +@@ -118,12 +229,33 @@ atomic64_add_ret: /* %o0 = increment, %o1 = atomic_ptr */ 2: BACKOFF_SPIN(%o2, %o3, 1b) .size atomic64_add_ret, .-atomic64_add_ret @@ -4042,9 +4513,10 @@ diff -urNp linux-3.0.9/arch/sparc/lib/atomic_64.S linux-3.0.9/arch/sparc/lib/ato casx [%o1], %g1, %g7 cmp %g1, %g7 bne,pn %xcc, BACKOFF_LABEL(2f, 1b) -diff -urNp linux-3.0.9/arch/sparc/lib/ksyms.c linux-3.0.9/arch/sparc/lib/ksyms.c ---- linux-3.0.9/arch/sparc/lib/ksyms.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/lib/ksyms.c 2011-11-12 12:47:13.000000000 -0500 +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); /* Atomic counter implementation. */ @@ -4064,33 +4536,23 @@ diff -urNp linux-3.0.9/arch/sparc/lib/ksyms.c linux-3.0.9/arch/sparc/lib/ksyms.c EXPORT_SYMBOL(atomic64_sub_ret); /* Atomic bit operations. */ -diff -urNp linux-3.0.9/arch/sparc/lib/Makefile linux-3.0.9/arch/sparc/lib/Makefile ---- linux-3.0.9/arch/sparc/lib/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/lib/Makefile 2011-11-12 12:47:13.000000000 -0500 +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 @@ # - asflags-y := -ansi -DST_DIV0=0x02 + asflags-y := -ansi -ccflags-y := -Werror +#ccflags-y := -Werror - lib-$(CONFIG_SPARC32) += mul.o rem.o sdiv.o udiv.o umul.o urem.o ashrdi3.o - lib-$(CONFIG_SPARC32) += memcpy.o memset.o -diff -urNp linux-3.0.9/arch/sparc/Makefile linux-3.0.9/arch/sparc/Makefile ---- linux-3.0.9/arch/sparc/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -75,7 +75,7 @@ drivers-$(CONFIG_OPROFILE) += arch/sparc - # Export what is needed by arch/sparc/boot/Makefile - export VMLINUX_INIT VMLINUX_MAIN - VMLINUX_INIT := $(head-y) $(init-y) --VMLINUX_MAIN := $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ block/ -+VMLINUX_MAIN := $(core-y) kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ - VMLINUX_MAIN += $(patsubst %/, %/lib.a, $(libs-y)) $(libs-y) - VMLINUX_MAIN += $(drivers-y) $(net-y) - -diff -urNp linux-3.0.9/arch/sparc/mm/fault_32.c linux-3.0.9/arch/sparc/mm/fault_32.c ---- linux-3.0.9/arch/sparc/mm/fault_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/mm/fault_32.c 2011-11-12 12:47:13.000000000 -0500 + obj-$(CONFIG_SPARC64) += ultra.o tlb.o tsb.o + obj-y += fault_$(BITS).o +diff --git a/arch/sparc/mm/fault_32.c b/arch/sparc/mm/fault_32.c +index 7543ddb..60a8b0b 100644 +--- a/arch/sparc/mm/fault_32.c ++++ b/arch/sparc/mm/fault_32.c @@ -22,6 +22,9 @@ #include <linux/interrupt.h> #include <linux/module.h> @@ -4101,7 +4563,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/fault_32.c linux-3.0.9/arch/sparc/mm/fault_ #include <asm/system.h> #include <asm/page.h> -@@ -209,6 +212,268 @@ static unsigned long compute_si_addr(str +@@ -209,6 +212,268 @@ static unsigned long compute_si_addr(struct pt_regs *regs, int text_fault) return safe_compute_effective_address(regs, insn); } @@ -4395,9 +4857,10 @@ diff -urNp linux-3.0.9/arch/sparc/mm/fault_32.c linux-3.0.9/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.0.9/arch/sparc/mm/fault_64.c linux-3.0.9/arch/sparc/mm/fault_64.c ---- linux-3.0.9/arch/sparc/mm/fault_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/mm/fault_64.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/sparc/mm/fault_64.c b/arch/sparc/mm/fault_64.c +index f92ce56..869924b 100644 +--- a/arch/sparc/mm/fault_64.c ++++ b/arch/sparc/mm/fault_64.c @@ -21,6 +21,9 @@ #include <linux/kprobes.h> #include <linux/kdebug.h> @@ -4408,7 +4871,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/fault_64.c linux-3.0.9/arch/sparc/mm/fault_ #include <asm/page.h> #include <asm/pgtable.h> -@@ -74,7 +77,7 @@ static void __kprobes bad_kernel_pc(stru +@@ -74,7 +77,7 @@ static void __kprobes bad_kernel_pc(struct pt_regs *regs, 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]); @@ -4417,7 +4880,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/fault_64.c linux-3.0.9/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_address(struct pt_regs *regs, show_regs(regs); } @@ -4875,7 +5338,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/fault_64.c linux-3.0.9/arch/sparc/mm/fault_ asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs) { struct mm_struct *mm = current->mm; -@@ -340,6 +794,29 @@ asmlinkage void __kprobes do_sparc64_fau +@@ -340,6 +794,29 @@ asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs) if (!vma) goto bad_area; @@ -4905,9 +5368,10 @@ diff -urNp linux-3.0.9/arch/sparc/mm/fault_64.c linux-3.0.9/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.0.9/arch/sparc/mm/hugetlbpage.c linux-3.0.9/arch/sparc/mm/hugetlbpage.c ---- linux-3.0.9/arch/sparc/mm/hugetlbpage.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/mm/hugetlbpage.c 2011-11-12 12:47:13.000000000 -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; @@ -4917,7 +5381,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/hugetlbpage.c linux-3.0.9/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 = find_vma(mm, addr-len); @@ -4926,7 +5390,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/hugetlbpage.c linux-3.0.9/arch/sparc/mm/hug /* remember the address as a hint for next time */ return (mm->free_area_cache = addr-len); } -@@ -116,16 +116,17 @@ hugetlb_get_unmapped_area_topdown(struct +@@ -116,16 +116,17 @@ hugetlb_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, if (unlikely(mm->mmap_base < len)) goto bottomup; @@ -4946,7 +5410,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/hugetlbpage.c linux-3.0.9/arch/sparc/mm/hug /* remember the address as a hint for next time */ return (mm->free_area_cache = 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 = vma->vm_start - addr; /* try just below the current vma->vm_start */ @@ -4957,7 +5421,7 @@ diff -urNp linux-3.0.9/arch/sparc/mm/hugetlbpage.c linux-3.0.9/arch/sparc/mm/hug bottomup: /* -@@ -182,8 +183,7 @@ hugetlb_get_unmapped_area(struct file *f +@@ -182,8 +183,7 @@ hugetlb_get_unmapped_area(struct file *file, unsigned long addr, if (addr) { addr = ALIGN(addr, HPAGE_SIZE); vma = find_vma(mm, addr); @@ -4967,9 +5431,10 @@ diff -urNp linux-3.0.9/arch/sparc/mm/hugetlbpage.c linux-3.0.9/arch/sparc/mm/hug return addr; } if (mm->get_unmapped_area == arch_get_unmapped_area) -diff -urNp linux-3.0.9/arch/sparc/mm/init_32.c linux-3.0.9/arch/sparc/mm/init_32.c ---- linux-3.0.9/arch/sparc/mm/init_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/mm/init_32.c 2011-11-12 12:47:13.000000000 -0500 +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); @@ -5004,21 +5469,10 @@ diff -urNp linux-3.0.9/arch/sparc/mm/init_32.c linux-3.0.9/arch/sparc/mm/init_32 protection_map[12] = PAGE_READONLY; protection_map[13] = PAGE_READONLY; protection_map[14] = PAGE_SHARED; -diff -urNp linux-3.0.9/arch/sparc/mm/Makefile linux-3.0.9/arch/sparc/mm/Makefile ---- linux-3.0.9/arch/sparc/mm/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/mm/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -2,7 +2,7 @@ - # - - asflags-y := -ansi --ccflags-y := -Werror -+#ccflags-y := -Werror - - obj-$(CONFIG_SPARC64) += ultra.o tlb.o tsb.o - obj-y += fault_$(BITS).o -diff -urNp linux-3.0.9/arch/sparc/mm/srmmu.c linux-3.0.9/arch/sparc/mm/srmmu.c ---- linux-3.0.9/arch/sparc/mm/srmmu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/sparc/mm/srmmu.c 2011-11-12 12:47:13.000000000 -0500 +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 = pgprot_val(SRMMU_PAGE_SHARED); BTFIXUPSET_INT(page_copy, pgprot_val(SRMMU_PAGE_COPY)); @@ -5033,9 +5487,25 @@ diff -urNp linux-3.0.9/arch/sparc/mm/srmmu.c linux-3.0.9/arch/sparc/mm/srmmu.c BTFIXUPSET_INT(page_kernel, pgprot_val(SRMMU_PAGE_KERNEL)); page_kernel = pgprot_val(SRMMU_PAGE_KERNEL); -diff -urNp linux-3.0.9/arch/um/include/asm/kmap_types.h linux-3.0.9/arch/um/include/asm/kmap_types.h ---- linux-3.0.9/arch/um/include/asm/kmap_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/um/include/asm/kmap_types.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/um/Makefile b/arch/um/Makefile +index fab8121..389e108 100644 +--- a/arch/um/Makefile ++++ b/arch/um/Makefile +@@ -49,6 +49,10 @@ USER_CFLAGS = $(patsubst $(KERNEL_DEFINES),,$(patsubst -D__KERNEL__,,\ + $(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \ + $(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=64 + ++ifdef CONSTIFY_PLUGIN ++USER_CFLAGS += $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-constify ++endif ++ + include $(srctree)/$(ARCH_DIR)/Makefile-$(SUBARCH) + + #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, @@ -5044,9 +5514,10 @@ diff -urNp linux-3.0.9/arch/um/include/asm/kmap_types.h linux-3.0.9/arch/um/incl KM_TYPE_NR }; -diff -urNp linux-3.0.9/arch/um/include/asm/page.h linux-3.0.9/arch/um/include/asm/page.h ---- linux-3.0.9/arch/um/include/asm/page.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/um/include/asm/page.h 2011-11-12 12:47:13.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)) @@ -5057,9 +5528,10 @@ diff -urNp linux-3.0.9/arch/um/include/asm/page.h linux-3.0.9/arch/um/include/as #ifndef __ASSEMBLY__ struct page; -diff -urNp linux-3.0.9/arch/um/kernel/process.c linux-3.0.9/arch/um/kernel/process.c ---- linux-3.0.9/arch/um/kernel/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/um/kernel/process.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/um/kernel/process.c b/arch/um/kernel/process.c +index fab4371..dfaf1a5 100644 +--- a/arch/um/kernel/process.c ++++ b/arch/um/kernel/process.c @@ -404,22 +404,6 @@ int singlestepping(void * t) return 2; } @@ -5083,23 +5555,10 @@ diff -urNp linux-3.0.9/arch/um/kernel/process.c linux-3.0.9/arch/um/kernel/proce unsigned long get_wchan(struct task_struct *p) { unsigned long stack_page, sp, ip; -diff -urNp linux-3.0.9/arch/um/Makefile linux-3.0.9/arch/um/Makefile ---- linux-3.0.9/arch/um/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/um/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -49,6 +49,10 @@ USER_CFLAGS = $(patsubst $(KERNEL_DEFINE - $(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \ - $(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=64 - -+ifdef CONSTIFY_PLUGIN -+USER_CFLAGS += $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-constify -+endif -+ - include $(srctree)/$(ARCH_DIR)/Makefile-$(SUBARCH) - - #This will adjust *FLAGS accordingly to the platform. -diff -urNp linux-3.0.9/arch/um/sys-i386/shared/sysdep/system.h linux-3.0.9/arch/um/sys-i386/shared/sysdep/system.h ---- linux-3.0.9/arch/um/sys-i386/shared/sysdep/system.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/um/sys-i386/shared/sysdep/system.h 2011-11-12 12:47:13.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 @@ -5109,9 +5568,10 @@ diff -urNp linux-3.0.9/arch/um/sys-i386/shared/sysdep/system.h linux-3.0.9/arch/ void default_idle(void); -diff -urNp linux-3.0.9/arch/um/sys-i386/syscalls.c linux-3.0.9/arch/um/sys-i386/syscalls.c ---- linux-3.0.9/arch/um/sys-i386/syscalls.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/um/sys-i386/syscalls.c 2011-11-12 12:47:13.000000000 -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" @@ -5134,9 +5594,10 @@ diff -urNp linux-3.0.9/arch/um/sys-i386/syscalls.c linux-3.0.9/arch/um/sys-i386/ /* * The prototype on i386 is: * -diff -urNp linux-3.0.9/arch/um/sys-x86_64/shared/sysdep/system.h linux-3.0.9/arch/um/sys-x86_64/shared/sysdep/system.h ---- linux-3.0.9/arch/um/sys-x86_64/shared/sysdep/system.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/um/sys-x86_64/shared/sysdep/system.h 2011-11-12 12:47:13.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 @@ -5146,10 +5607,179 @@ diff -urNp linux-3.0.9/arch/um/sys-x86_64/shared/sysdep/system.h linux-3.0.9/arc void default_idle(void); -diff -urNp linux-3.0.9/arch/x86/boot/bitops.h linux-3.0.9/arch/x86/boot/bitops.h ---- linux-3.0.9/arch/x86/boot/bitops.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/bitops.h 2011-11-12 12:47:13.000000000 -0500 -@@ -26,7 +26,7 @@ static inline int variable_test_bit(int +diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig +index 37357a5..a246776 100644 +--- a/arch/x86/Kconfig ++++ b/arch/x86/Kconfig +@@ -229,7 +229,7 @@ config X86_HT + + config X86_32_LAZY_GS + def_bool y +- depends on X86_32 && !CC_STACKPROTECTOR ++ depends on X86_32 && !CC_STACKPROTECTOR && !PAX_MEMORY_UDEREF + + config ARCH_HWEIGHT_CFLAGS + string +@@ -1018,7 +1018,7 @@ choice + + 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 +@@ -1055,7 +1055,7 @@ config NOHIGHMEM + + 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. +@@ -1109,7 +1109,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 +@@ -1483,6 +1483,7 @@ config SECCOMP + + 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 +@@ -1540,6 +1541,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. + +@@ -1603,6 +1605,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 +@@ -1634,9 +1637,10 @@ config HOTPLUG_CPU + Say N if you want to disable CPU hotplug. + + 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. + +diff --git a/arch/x86/Kconfig.cpu b/arch/x86/Kconfig.cpu +index 6a7cfdf..2730244 100644 +--- a/arch/x86/Kconfig.cpu ++++ b/arch/x86/Kconfig.cpu +@@ -338,7 +338,7 @@ config X86_PPRO_FENCE + + config X86_F00F_BUG + def_bool y +- depends on M586MMX || M586TSC || M586 || M486 || M386 ++ depends on (M586MMX || M586TSC || M586 || M486 || M386) && !PAX_KERNEXEC + + config X86_INVD_BUG + def_bool y +@@ -362,7 +362,7 @@ config X86_POPAD_OK + + config X86_ALIGNMENT_16 + def_bool y +- depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MELAN || 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 + + config X86_INTEL_USERCOPY + def_bool y +@@ -408,7 +408,7 @@ config X86_CMPXCHG64 + # generates cmov. + config X86_CMOV + def_bool y +- depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || 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 || MEFFICEON || X86_64 || MATOM || MGEODE_LX) + + 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 + + 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..c1ca0df 100644 +--- a/arch/x86/Makefile ++++ b/arch/x86/Makefile +@@ -44,6 +44,7 @@ ifeq ($(CONFIG_X86_32),y) + else + BITS := 64 + UTS_MACHINE := x86_64 ++ biarch := $(call cc-option,-m64) + CHECKFLAGS += -D__x86_64__ -m64 + + KBUILD_AFLAGS += -m64 +@@ -195,3 +196,12 @@ define archhelp + echo ' FDARGS="..." arguments for the booted kernel' + echo ' FDINITRD=file 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 f7cb086..69c1acd 100644 +--- a/arch/x86/boot/Makefile ++++ b/arch/x86/boot/Makefile +@@ -69,6 +69,9 @@ KBUILD_CFLAGS := $(LINUXINCLUDE) -g -Os -D_SETUP -D__KERNEL__ \ + $(call cc-option, -fno-stack-protector) \ + $(call cc-option, -mpreferred-stack-boundary=2) + KBUILD_CFLAGS += $(call cc-option, -m32) ++ifdef CONSTIFY_PLUGIN ++KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-constify ++endif + KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ + GCOV_PROFILE := n + +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 = (const u32 *)addr; @@ -5158,7 +5788,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/bitops.h linux-3.0.9/arch/x86/boot/bitops.h return v; } -@@ -37,7 +37,7 @@ static inline int variable_test_bit(int +@@ -37,7 +37,7 @@ static inline int variable_test_bit(int nr, const void *addr) static inline void set_bit(int nr, void *addr) { @@ -5167,9 +5797,10 @@ diff -urNp linux-3.0.9/arch/x86/boot/bitops.h linux-3.0.9/arch/x86/boot/bitops.h } #endif /* BOOT_BITOPS_H */ -diff -urNp linux-3.0.9/arch/x86/boot/boot.h linux-3.0.9/arch/x86/boot/boot.h ---- linux-3.0.9/arch/x86/boot/boot.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/boot.h 2011-11-12 12:47:13.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) { @@ -5179,7 +5810,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/boot.h linux-3.0.9/arch/x86/boot/boot.h return seg; } -@@ -181,7 +181,7 @@ static inline void wrgs32(u32 v, addr_t +@@ -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; @@ -5188,9 +5819,24 @@ diff -urNp linux-3.0.9/arch/x86/boot/boot.h linux-3.0.9/arch/x86/boot/boot.h : "=qm" (diff), "+D" (s1), "+S" (s2), "+c" (len)); return diff; } -diff -urNp linux-3.0.9/arch/x86/boot/compressed/head_32.S linux-3.0.9/arch/x86/boot/compressed/head_32.S ---- linux-3.0.9/arch/x86/boot/compressed/head_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/compressed/head_32.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/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) := -mcmodel=small + KBUILD_CFLAGS += $(cflags-y) + KBUILD_CFLAGS += $(call cc-option,-ffreestanding) + KBUILD_CFLAGS += $(call cc-option,-fno-stack-protector) ++ifdef CONSTIFY_PLUGIN ++KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-constify ++endif + + KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ + GCOV_PROFILE := n +diff --git a/arch/x86/boot/compressed/head_32.S b/arch/x86/boot/compressed/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 @@ -5219,9 +5865,10 @@ diff -urNp linux-3.0.9/arch/x86/boot/compressed/head_32.S linux-3.0.9/arch/x86/b addl %ebx, -__PAGE_OFFSET(%ebx, %ecx) jmp 1b 2: -diff -urNp linux-3.0.9/arch/x86/boot/compressed/head_64.S linux-3.0.9/arch/x86/boot/compressed/head_64.S ---- linux-3.0.9/arch/x86/boot/compressed/head_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/compressed/head_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/boot/compressed/head_64.S b/arch/x86/boot/compressed/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 @@ -5240,22 +5887,10 @@ diff -urNp linux-3.0.9/arch/x86/boot/compressed/head_64.S linux-3.0.9/arch/x86/b #endif /* Target address to relocate to for decompression */ -diff -urNp linux-3.0.9/arch/x86/boot/compressed/Makefile linux-3.0.9/arch/x86/boot/compressed/Makefile ---- linux-3.0.9/arch/x86/boot/compressed/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/compressed/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -14,6 +14,9 @@ cflags-$(CONFIG_X86_64) := -mcmodel=smal - KBUILD_CFLAGS += $(cflags-y) - KBUILD_CFLAGS += $(call cc-option,-ffreestanding) - KBUILD_CFLAGS += $(call cc-option,-fno-stack-protector) -+ifdef CONSTIFY_PLUGIN -+KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-constify -+endif - - KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ - GCOV_PROFILE := n -diff -urNp linux-3.0.9/arch/x86/boot/compressed/misc.c linux-3.0.9/arch/x86/boot/compressed/misc.c ---- linux-3.0.9/arch/x86/boot/compressed/misc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/compressed/misc.c 2011-11-12 12:47:13.000000000 -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 @@ -5265,7 +5900,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/compressed/misc.c linux-3.0.9/arch/x86/boot #else dest = (void *)(phdr->p_paddr); #endif -@@ -363,7 +363,7 @@ asmlinkage void decompress_kernel(void * +@@ -363,7 +363,7 @@ asmlinkage void decompress_kernel(void *rmode, memptr heap, error("Destination address too large"); #endif #ifndef CONFIG_RELOCATABLE @@ -5274,9 +5909,10 @@ diff -urNp linux-3.0.9/arch/x86/boot/compressed/misc.c linux-3.0.9/arch/x86/boot error("Wrong destination address"); #endif -diff -urNp linux-3.0.9/arch/x86/boot/compressed/relocs.c linux-3.0.9/arch/x86/boot/compressed/relocs.c ---- linux-3.0.9/arch/x86/boot/compressed/relocs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/compressed/relocs.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/boot/compressed/relocs.c b/arch/x86/boot/compressed/relocs.c +index 89bbf4e..869908e 100644 +--- a/arch/x86/boot/compressed/relocs.c ++++ b/arch/x86/boot/compressed/relocs.c @@ -13,8 +13,11 @@ static void die(char *fmt, ...); @@ -5429,7 +6065,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/compressed/relocs.c linux-3.0.9/arch/x86/bo struct section *sec = &secs[i]; if (sec->shdr.sh_type != 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 *rel, Elf32_Sym *sym)) !is_rel_reloc(sym_name(sym_strtab, sym))) { continue; } @@ -5452,7 +6088,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/compressed/relocs.c linux-3.0.9/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) static void emit_relocs(int as_text) { @@ -5469,9 +6105,10 @@ diff -urNp linux-3.0.9/arch/x86/boot/compressed/relocs.c linux-3.0.9/arch/x86/bo read_shdrs(fp); read_strtabs(fp); read_symtabs(fp); -diff -urNp linux-3.0.9/arch/x86/boot/cpucheck.c linux-3.0.9/arch/x86/boot/cpucheck.c ---- linux-3.0.9/arch/x86/boot/cpucheck.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/cpucheck.c 2011-11-12 12:47:13.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 = -1, fsw = -1; u32 cr0; @@ -5526,7 +6163,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/cpucheck.c linux-3.0.9/arch/x86/boot/cpuche : "+a" (eax), "=c" (cpu.flags[6]), "=d" (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 = MSR_K7_HWCR; u32 eax, edx; @@ -5538,7 +6175,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/cpucheck.c linux-3.0.9/arch/x86/boot/cpuche get_flags(); /* Make sure it really did something */ err = 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 = MSR_VIA_FCR; u32 eax, edx; @@ -5550,7 +6187,7 @@ diff -urNp linux-3.0.9/arch/x86/boot/cpucheck.c linux-3.0.9/arch/x86/boot/cpuche set_bit(X86_FEATURE_CX8, cpu.flags); err = 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_ptr, u32 **err_flags_ptr) u32 eax, edx; u32 level = 1; @@ -5567,10 +6204,11 @@ diff -urNp linux-3.0.9/arch/x86/boot/cpucheck.c linux-3.0.9/arch/x86/boot/cpuche err = check_flags(); } -diff -urNp linux-3.0.9/arch/x86/boot/header.S linux-3.0.9/arch/x86/boot/header.S ---- linux-3.0.9/arch/x86/boot/header.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/header.S 2011-11-12 12:47:13.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 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 @@ -5579,22 +6217,10 @@ diff -urNp linux-3.0.9/arch/x86/boot/header.S linux-3.0.9/arch/x86/boot/header.S #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.0.9/arch/x86/boot/Makefile linux-3.0.9/arch/x86/boot/Makefile ---- linux-3.0.9/arch/x86/boot/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -69,6 +69,9 @@ KBUILD_CFLAGS := $(LINUXINCLUDE) -g -Os - $(call cc-option, -fno-stack-protector) \ - $(call cc-option, -mpreferred-stack-boundary=2) - KBUILD_CFLAGS += $(call cc-option, -m32) -+ifdef CONSTIFY_PLUGIN -+KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) -fplugin-arg-constify_plugin-no-constify -+endif - KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ - GCOV_PROFILE := n - -diff -urNp linux-3.0.9/arch/x86/boot/memory.c linux-3.0.9/arch/x86/boot/memory.c ---- linux-3.0.9/arch/x86/boot/memory.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/memory.c 2011-11-12 12:47:13.000000000 -0500 +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 @@ static int detect_memory_e820(void) @@ -5604,9 +6230,22 @@ diff -urNp linux-3.0.9/arch/x86/boot/memory.c linux-3.0.9/arch/x86/boot/memory.c struct biosregs ireg, oreg; struct e820entry *desc = boot_params.e820_map; static struct e820entry buf; /* static so it is zeroed */ -diff -urNp linux-3.0.9/arch/x86/boot/video.c linux-3.0.9/arch/x86/boot/video.c ---- linux-3.0.9/arch/x86/boot/video.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/video.c 2011-11-12 12:47:13.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) + + boot_params.screen_info.vesapm_seg = oreg.es; + boot_params.screen_info.vesapm_off = oreg.di; ++ boot_params.screen_info.vesapm_size = oreg.cx; + } + + /* +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) { @@ -5616,20 +6255,10 @@ diff -urNp linux-3.0.9/arch/x86/boot/video.c linux-3.0.9/arch/x86/boot/video.c int key; unsigned int v; -diff -urNp linux-3.0.9/arch/x86/boot/video-vesa.c linux-3.0.9/arch/x86/boot/video-vesa.c ---- linux-3.0.9/arch/x86/boot/video-vesa.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/boot/video-vesa.c 2011-11-12 12:47:13.000000000 -0500 -@@ -200,6 +200,7 @@ static void vesa_store_pm_info(void) - - boot_params.screen_info.vesapm_seg = oreg.es; - boot_params.screen_info.vesapm_off = oreg.di; -+ boot_params.screen_info.vesapm_size = oreg.cx; - } - - /* -diff -urNp linux-3.0.9/arch/x86/crypto/aes-x86_64-asm_64.S linux-3.0.9/arch/x86/crypto/aes-x86_64-asm_64.S ---- linux-3.0.9/arch/x86/crypto/aes-x86_64-asm_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/crypto/aes-x86_64-asm_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/crypto/aes-x86_64-asm_64.S b/arch/x86/crypto/aes-x86_64-asm_64.S +index 5b577d5..eb7f25e 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. */ @@ -5648,9 +6277,10 @@ diff -urNp linux-3.0.9/arch/x86/crypto/aes-x86_64-asm_64.S linux-3.0.9/arch/x86/ #define epilogue(r1,r2,r3,r4,r5,r6,r7,r8,r9) \ movq r1,r2; \ movq r3,r4; \ -diff -urNp linux-3.0.9/arch/x86/crypto/salsa20-x86_64-asm_64.S linux-3.0.9/arch/x86/crypto/salsa20-x86_64-asm_64.S ---- linux-3.0.9/arch/x86/crypto/salsa20-x86_64-asm_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/crypto/salsa20-x86_64-asm_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/crypto/salsa20-x86_64-asm_64.S b/arch/x86/crypto/salsa20-x86_64-asm_64.S +index 6214a9b..5c0f959 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 <asm/alternative-asm.h> + @@ -5679,9 +6309,10 @@ diff -urNp linux-3.0.9/arch/x86/crypto/salsa20-x86_64-asm_64.S linux-3.0.9/arch/ mov %rsi,%rdx + pax_force_retaddr ret -diff -urNp linux-3.0.9/arch/x86/crypto/twofish-x86_64-asm_64.S linux-3.0.9/arch/x86/crypto/twofish-x86_64-asm_64.S ---- linux-3.0.9/arch/x86/crypto/twofish-x86_64-asm_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/crypto/twofish-x86_64-asm_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/crypto/twofish-x86_64-asm_64.S b/arch/x86/crypto/twofish-x86_64-asm_64.S +index 573aa10..7289973 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 @@ -5704,10 +6335,11 @@ diff -urNp linux-3.0.9/arch/x86/crypto/twofish-x86_64-asm_64.S linux-3.0.9/arch/ movq $1,%rax + pax_force_retaddr ret -diff -urNp linux-3.0.9/arch/x86/ia32/ia32_aout.c linux-3.0.9/arch/x86/ia32/ia32_aout.c ---- linux-3.0.9/arch/x86/ia32/ia32_aout.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/ia32/ia32_aout.c 2011-11-12 12:47:13.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; @@ -5716,9 +6348,90 @@ diff -urNp linux-3.0.9/arch/x86/ia32/ia32_aout.c linux-3.0.9/arch/x86/ia32/ia32_ fs = get_fs(); set_fs(KERNEL_DS); has_dumped = 1; -diff -urNp linux-3.0.9/arch/x86/ia32/ia32entry.S linux-3.0.9/arch/x86/ia32/ia32entry.S ---- linux-3.0.9/arch/x86/ia32/ia32entry.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/ia32/ia32entry.S 2011-11-12 12:47:13.000000000 -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 = get_fs(); + set_fs(KERNEL_DS); +- ret = do_sigaltstack(uss_ptr ? &uss : NULL, &uoss, regs->sp); ++ ret = do_sigaltstack(uss_ptr ? (const stack_t __force_user *)&uss : NULL, (stack_t __force_user *)&uoss, regs->sp); + set_fs(seg); + if (ret >= 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_ia32 __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; + +@@ -395,7 +395,7 @@ static void __user *get_sigframe(struct k_sigaction *ka, struct pt_regs *regs, + + if (used_math()) { + sp = sp - sig_xstate_ia32_size; +- *fpstate = (struct _fpstate_ia32 *) sp; ++ *fpstate = (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 -= frame_size; + /* Align the stack pointer according to the i386 ABI, + * i.e. so that on function entry ((sp + 4) & 15) == 0. */ +- sp = ((sp + 4) & -16ul) - 4; ++ sp = ((sp - 12) & -16ul) - 4; + return (void __user *) sp; + } + +@@ -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); + + 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 + }; + + frame = get_sigframe(ka, regs, sizeof(*frame), &fpstate); +@@ -533,16 +533,18 @@ int ia32_setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, + + if (ka->sa.sa_flags & SA_RESTORER) + restorer = ka->sa.sa_restorer; ++ else if (current->mm->context.vdso) ++ /* Return stub is in 32bit vsyscall page */ ++ restorer = VDSO32_SYMBOL(current->mm->context.vdso, rt_sigreturn); + else +- restorer = VDSO32_SYMBOL(current->mm->context.vdso, +- rt_sigreturn); ++ restorer = &frame->retcode; + put_user_ex(ptr_to_compat(restorer), &frame->pretcode); + + /* + * 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); + + if (err) +diff --git a/arch/x86/ia32/ia32entry.S b/arch/x86/ia32/ia32entry.S +index c1870dd..c60154f 100644 +--- a/arch/x86/ia32/ia32entry.S ++++ b/arch/x86/ia32/ia32entry.S @@ -13,7 +13,9 @@ #include <asm/thread_info.h> #include <asm/segment.h> @@ -5887,7 +6600,7 @@ diff -urNp linux-3.0.9/arch/x86/ia32/ia32entry.S linux-3.0.9/arch/x86/ia32/ia32e /* * No need to follow this irqs on/off section: the syscall * disabled irqs and here we enable it straight after entry: -@@ -441,6 +498,9 @@ ia32_tracesys: +@@ -441,6 +498,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 @@ -5905,89 +6618,11 @@ diff -urNp linux-3.0.9/arch/x86/ia32/ia32entry.S linux-3.0.9/arch/x86/ia32/ia32e ret CFI_ENDPROC -diff -urNp linux-3.0.9/arch/x86/ia32/ia32_signal.c linux-3.0.9/arch/x86/ia32/ia32_signal.c ---- linux-3.0.9/arch/x86/ia32/ia32_signal.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/ia32/ia32_signal.c 2011-11-12 12:47:13.000000000 -0500 -@@ -167,7 +167,7 @@ asmlinkage long sys32_sigaltstack(const - } - seg = get_fs(); - set_fs(KERNEL_DS); -- ret = do_sigaltstack(uss_ptr ? &uss : NULL, &uoss, regs->sp); -+ ret = do_sigaltstack(uss_ptr ? (const stack_t __force_user *)&uss : NULL, (stack_t __force_user *)&uoss, regs->sp); - set_fs(seg); - if (ret >= 0 && uoss_ptr) { - if (!access_ok(VERIFY_WRITE, uoss_ptr, sizeof(stack_ia32_t))) -@@ -374,7 +374,7 @@ static int ia32_setup_sigcontext(struct - */ - 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; - -@@ -395,7 +395,7 @@ static void __user *get_sigframe(struct - - if (used_math()) { - sp = sp - sig_xstate_ia32_size; -- *fpstate = (struct _fpstate_ia32 *) sp; -+ *fpstate = (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 - sp -= frame_size; - /* Align the stack pointer according to the i386 ABI, - * i.e. so that on function entry ((sp + 4) & 15) == 0. */ -- sp = ((sp + 4) & -16ul) - 4; -+ sp = ((sp - 12) & -16ul) - 4; - return (void __user *) sp; - } - -@@ -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); - - if (err) -@@ -503,7 +503,7 @@ int ia32_setup_rt_frame(int sig, struct - 0xb8, - __NR_ia32_rt_sigreturn, - 0x80cd, -- 0, -+ 0 - }; - - frame = get_sigframe(ka, regs, sizeof(*frame), &fpstate); -@@ -533,16 +533,18 @@ int ia32_setup_rt_frame(int sig, struct - - if (ka->sa.sa_flags & SA_RESTORER) - restorer = ka->sa.sa_restorer; -+ else if (current->mm->context.vdso) -+ /* Return stub is in 32bit vsyscall page */ -+ restorer = VDSO32_SYMBOL(current->mm->context.vdso, rt_sigreturn); - else -- restorer = VDSO32_SYMBOL(current->mm->context.vdso, -- rt_sigreturn); -+ restorer = &frame->retcode; - put_user_ex(ptr_to_compat(restorer), &frame->pretcode); - - /* - * 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); - - if (err) -diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/arch/x86/ia32/sys_ia32.c ---- linux-3.0.9/arch/x86/ia32/sys_ia32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/ia32/sys_ia32.c 2011-11-12 12:47:13.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 5852519..ac198bc 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, unsigned long offset_low, */ static int cp_stat64(struct stat64 __user *ubuf, struct kstat *stat) { @@ -5998,7 +6633,7 @@ diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/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 = sys_rt_sigprocmask(how, @@ -6009,7 +6644,7 @@ diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/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); } @@ -6018,7 +6653,7 @@ diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/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_pid_t pid, mm_segment_t old_fs = get_fs(); set_fs(KERNEL_DS); @@ -6027,7 +6662,7 @@ diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/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 = get_fs(); set_fs(KERNEL_DS); @@ -6036,7 +6671,7 @@ diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/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 sig, if (copy_siginfo_from_user32(&info, uinfo)) return -EFAULT; set_fs(KERNEL_DS); @@ -6045,7 +6680,7 @@ diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/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; set_fs(KERNEL_DS); @@ -6054,9 +6689,10 @@ diff -urNp linux-3.0.9/arch/x86/ia32/sys_ia32.c linux-3.0.9/arch/x86/ia32/sys_ia count); set_fs(old_fs); -diff -urNp linux-3.0.9/arch/x86/include/asm/alternative-asm.h linux-3.0.9/arch/x86/include/asm/alternative-asm.h ---- linux-3.0.9/arch/x86/include/asm/alternative-asm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/alternative-asm.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/alternative-asm.h b/arch/x86/include/asm/alternative-asm.h +index 94d420b..f7854e1 100644 +--- a/arch/x86/include/asm/alternative-asm.h ++++ b/arch/x86/include/asm/alternative-asm.h @@ -15,6 +15,20 @@ .endm #endif @@ -6078,10 +6714,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/alternative-asm.h linux-3.0.9/arch/x .macro altinstruction_entry orig alt feature orig_len alt_len .align 8 .quad \orig -diff -urNp linux-3.0.9/arch/x86/include/asm/alternative.h linux-3.0.9/arch/x86/include/asm/alternative.h ---- linux-3.0.9/arch/x86/include/asm/alternative.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/alternative.h 2011-11-12 12:47:13.000000000 -0500 -@@ -93,7 +93,7 @@ static inline int alternatives_text_rese +diff --git a/arch/x86/include/asm/alternative.h b/arch/x86/include/asm/alternative.h +index bf535f9..ae78f95 100644 +--- a/arch/x86/include/asm/alternative.h ++++ b/arch/x86/include/asm/alternative.h +@@ -93,7 +93,7 @@ static inline int alternatives_text_reserved(void *start, void *end) ".section .discard,\"aw\",@progbits\n" \ " .byte 0xff + (664f-663f) - (662b-661b)\n" /* rlen <= slen */ \ ".previous\n" \ @@ -6090,10 +6727,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/alternative.h linux-3.0.9/arch/x86/i "663:\n\t" newinstr "\n664:\n" /* replacement */ \ ".previous" -diff -urNp linux-3.0.9/arch/x86/include/asm/apic.h linux-3.0.9/arch/x86/include/asm/apic.h ---- linux-3.0.9/arch/x86/include/asm/apic.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/apic.h 2011-11-12 12:47:13.000000000 -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 244ac77..0963a9d 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) #ifdef CONFIG_X86_LOCAL_APIC @@ -6102,10 +6740,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/apic.h linux-3.0.9/arch/x86/include/ extern int local_apic_timer_c2_ok; extern int disable_apic; -diff -urNp linux-3.0.9/arch/x86/include/asm/apm.h linux-3.0.9/arch/x86/include/asm/apm.h ---- linux-3.0.9/arch/x86/include/asm/apm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/apm.h 2011-11-12 12:47:13.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" @@ -6114,7 +6753,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/apm.h linux-3.0.9/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, u32 ebx_in, __asm__ __volatile__(APM_DO_ZERO_SEGS "pushl %%edi\n\t" "pushl %%ebp\n\t" @@ -6123,9 +6762,426 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/apm.h linux-3.0.9/arch/x86/include/a "setc %%bl\n\t" "popl %%ebp\n\t" "popl %%edi\n\t" -diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/include/asm/atomic64_32.h ---- linux-3.0.9/arch/x86/include/asm/atomic64_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/atomic64_32.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/atomic.h b/arch/x86/include/asm/atomic.h +index 952a826..8a9371d 100644 +--- a/arch/x86/include/asm/atomic.h ++++ b/arch/x86/include/asm/atomic.h +@@ -22,7 +22,18 @@ + */ + static inline int atomic_read(const atomic_t *v) + { +- return (*(volatile int *)&(v)->counter); ++ return (*(volatile const int *)&(v)->counter); ++} ++ ++/** ++ * atomic_read_unchecked - read atomic variable ++ * @v: pointer of type atomic_unchecked_t ++ * ++ * Atomically reads the value of @v. ++ */ ++static inline int atomic_read_unchecked(const atomic_unchecked_t *v) ++{ ++ return (*(volatile const int *)&(v)->counter); + } + + /** +@@ -38,6 +49,18 @@ static inline void atomic_set(atomic_t *v, int i) + } + + /** ++ * 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 atomic_set_unchecked(atomic_unchecked_t *v, int i) ++{ ++ v->counter = i; ++} ++ ++/** + * atomic_add - add integer to atomic variable + * @i: integer value to add + * @v: pointer of type atomic_t +@@ -46,7 +69,29 @@ static inline void atomic_set(atomic_t *v, int i) + */ + static inline void atomic_add(int i, atomic_t *v) + { +- asm volatile(LOCK_PREFIX "addl %1,%0" ++ asm volatile(LOCK_PREFIX "addl %1,%0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ LOCK_PREFIX "subl %1,%0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ : "+m" (v->counter) ++ : "ir" (i)); ++} ++ ++/** ++ * atomic_add_unchecked - add integer to atomic variable ++ * @i: integer value to add ++ * @v: pointer of type atomic_unchecked_t ++ * ++ * Atomically adds @i to @v. ++ */ ++static inline void atomic_add_unchecked(int i, atomic_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, atomic_t *v) + */ + static inline void atomic_sub(int i, atomic_t *v) + { +- asm volatile(LOCK_PREFIX "subl %1,%0" ++ asm volatile(LOCK_PREFIX "subl %1,%0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ LOCK_PREFIX "addl %1,%0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ : "+m" (v->counter) ++ : "ir" (i)); ++} ++ ++/** ++ * atomic_sub_unchecked - subtract integer from atomic variable ++ * @i: integer value to subtract ++ * @v: pointer of type atomic_unchecked_t ++ * ++ * Atomically subtracts @i from @v. ++ */ ++static inline void atomic_sub_unchecked(int i, atomic_unchecked_t *v) ++{ ++ asm volatile(LOCK_PREFIX "subl %1,%0\n" + : "+m" (v->counter) + : "ir" (i)); + } +@@ -78,7 +145,16 @@ static inline int atomic_sub_and_test(int i, atomic_t *v) + { + unsigned char c; + +- 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 "addl %2,%0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ "sete %1\n" + : "+m" (v->counter), "=qm" (c) + : "ir" (i) : "memory"); + return c; +@@ -92,7 +168,27 @@ static inline int atomic_sub_and_test(int i, atomic_t *v) + */ + static inline void atomic_inc(atomic_t *v) + { +- asm volatile(LOCK_PREFIX "incl %0" ++ asm volatile(LOCK_PREFIX "incl %0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ LOCK_PREFIX "decl %0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ : "+m" (v->counter)); ++} ++ ++/** ++ * atomic_inc_unchecked - increment atomic variable ++ * @v: pointer of type atomic_unchecked_t ++ * ++ * Atomically increments @v by 1. ++ */ ++static inline void atomic_inc_unchecked(atomic_unchecked_t *v) ++{ ++ asm volatile(LOCK_PREFIX "incl %0\n" + : "+m" (v->counter)); + } + +@@ -104,7 +200,27 @@ static inline void atomic_inc(atomic_t *v) + */ + static inline void atomic_dec(atomic_t *v) + { +- asm volatile(LOCK_PREFIX "decl %0" ++ asm volatile(LOCK_PREFIX "decl %0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ LOCK_PREFIX "incl %0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ : "+m" (v->counter)); ++} ++ ++/** ++ * atomic_dec_unchecked - decrement atomic variable ++ * @v: pointer of type atomic_unchecked_t ++ * ++ * Atomically decrements @v by 1. ++ */ ++static inline void atomic_dec_unchecked(atomic_unchecked_t *v) ++{ ++ asm volatile(LOCK_PREFIX "decl %0\n" + : "+m" (v->counter)); + } + +@@ -120,7 +236,16 @@ static inline int atomic_dec_and_test(atomic_t *v) + { + unsigned char c; + +- asm volatile(LOCK_PREFIX "decl %0; sete %1" ++ asm volatile(LOCK_PREFIX "decl %0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ LOCK_PREFIX "incl %0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ "sete %1\n" + : "+m" (v->counter), "=qm" (c) + : : "memory"); + return c != 0; +@@ -138,7 +263,35 @@ static inline int atomic_inc_and_test(atomic_t *v) + { + unsigned char c; + +- asm volatile(LOCK_PREFIX "incl %0; sete %1" ++ asm volatile(LOCK_PREFIX "incl %0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ LOCK_PREFIX "decl %0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ "sete %1\n" ++ : "+m" (v->counter), "=qm" (c) ++ : : "memory"); ++ return c != 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), "=qm" (c) + : : "memory"); + return c != 0; +@@ -157,7 +310,16 @@ static inline int atomic_add_negative(int i, atomic_t *v) + { + unsigned char c; + +- 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 "subl %2,%0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ "sets %1\n" + : "+m" (v->counter), "=qm" (c) + : "ir" (i) : "memory"); + return c; +@@ -180,6 +342,46 @@ static inline int atomic_add_return(int i, atomic_t *v) + #endif + /* Modern 486+ processor */ + __i = i; ++ asm volatile(LOCK_PREFIX "xaddl %0, %1\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ "movl %0, %1\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ : "+r" (i), "+m" (v->counter) ++ : : "memory"); ++ return i + __i; ++ ++#ifdef CONFIG_M386 ++no_xadd: /* Legacy 386 processor */ ++ local_irq_save(flags); ++ __i = 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 ++ * @i: integer value to add ++ * ++ * Atomically adds @i to @v and returns @i + @v ++ */ ++static inline int atomic_add_return_unchecked(int i, atomic_unchecked_t *v) ++{ ++ int __i; ++#ifdef CONFIG_M386 ++ unsigned long flags; ++ if (unlikely(boot_cpu_data.x86 <= 3)) ++ goto no_xadd; ++#endif ++ /* Modern 486+ processor */ ++ __i = i; + asm volatile(LOCK_PREFIX "xaddl %0, %1" + : "+r" (i), "+m" (v->counter) + : : "memory"); +@@ -208,6 +410,10 @@ static inline int atomic_sub_return(int i, atomic_t *v) + } + + #define atomic_inc_return(v) (atomic_add_return(1, v)) ++static inline int atomic_inc_return_unchecked(atomic_unchecked_t *v) ++{ ++ return atomic_add_return_unchecked(1, v); ++} + #define atomic_dec_return(v) (atomic_sub_return(1, v)) + + 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); + } + ++static inline int atomic_cmpxchg_unchecked(atomic_unchecked_t *v, int old, int new) ++{ ++ return cmpxchg(&v->counter, old, new); ++} ++ + static inline int atomic_xchg(atomic_t *v, int new) + { + return xchg(&v->counter, new); + } + ++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,21 +447,77 @@ static inline int atomic_xchg(atomic_t *v, int new) + */ + static inline int atomic_add_unless(atomic_t *v, int a, int u) + { +- int c, old; ++ int c, old, new; + c = atomic_read(v); + for (;;) { +- if (unlikely(c == (u))) ++ if (unlikely(c == u)) + break; +- old = atomic_cmpxchg((v), c, c + (a)); ++ ++ asm volatile("addl %2,%0\n" ++ ++#ifdef CONFIG_PAX_REFCOUNT ++ "jno 0f\n" ++ "subl %2,%0\n" ++ "int $4\n0:\n" ++ _ASM_EXTABLE(0b, 0b) ++#endif ++ ++ : "=r" (new) ++ : "0" (c), "ir" (a)); ++ ++ old = atomic_cmpxchg(v, c, new); + if (likely(old == c)) + break; + c = old; + } +- return c != (u); ++ return c != u; + } + + #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) + ++/** ++ * 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 = hint, new; ++ ++ /* sanity test, should be removed by compiler if hint is a constant */ ++ if (!hint) ++ return atomic_inc_not_zero(v); ++ ++ 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 ++ ++ : "=r" (new) ++ : "0" (c)); ++ ++ val = atomic_cmpxchg(v, c, new); ++ if (val == c) ++ return 1; ++ c = val; ++ } while (c); ++ ++ return 0; ++} ++ + /* + * atomic_dec_if_positive - decrement by 1 if old value positive + * @v: pointer of type atomic_t +diff --git a/arch/x86/include/asm/atomic64_32.h b/arch/x86/include/asm/atomic64_32.h +index 2a934aa..42d2411 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; @@ -6141,7 +7197,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/i #define ATOMIC64_INIT(val) { (val) } #ifdef CONFIG_X86_CMPXCHG64 -@@ -38,6 +46,21 @@ static inline long long atomic64_cmpxchg +@@ -38,6 +46,21 @@ static inline long long atomic64_cmpxchg(atomic64_t *v, long long o, long long n } /** @@ -6163,7 +7219,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/i * 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 +@@ -77,6 +100,24 @@ static inline void atomic64_set(atomic64_t *v, long long i) } /** @@ -6188,7 +7244,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/i * atomic64_read - read atomic64 variable * @v: pointer to type atomic64_t * -@@ -93,6 +134,22 @@ static inline long long atomic64_read(at +@@ -93,6 +134,22 @@ static inline long long atomic64_read(atomic64_t *v) } /** @@ -6211,7 +7267,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/i * 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 +@@ -108,6 +165,22 @@ static inline long long atomic64_add_return(long long i, atomic64_t *v) return i; } @@ -6234,7 +7290,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/i /* * Other variants with different arithmetic operators: */ -@@ -131,6 +204,17 @@ static inline long long atomic64_inc_ret +@@ -131,6 +204,17 @@ static inline long long atomic64_inc_return(atomic64_t *v) return a; } @@ -6252,7 +7308,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/i static inline long long atomic64_dec_return(atomic64_t *v) { long long a; -@@ -159,6 +243,22 @@ static inline long long atomic64_add(lon +@@ -159,6 +243,22 @@ static inline long long atomic64_add(long long i, atomic64_t *v) } /** @@ -6275,9 +7331,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_32.h linux-3.0.9/arch/x86/i * atomic64_sub - subtract the atomic64 variable * @i: integer value to subtract * @v: pointer to type atomic64_t -diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/include/asm/atomic64_64.h ---- linux-3.0.9/arch/x86/include/asm/atomic64_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/atomic64_64.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/atomic64_64.h b/arch/x86/include/asm/atomic64_64.h +index 49fd1ea..8c58977 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) @@ -6299,7 +7356,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i } /** -@@ -34,6 +46,18 @@ static inline void atomic64_set(atomic64 +@@ -34,6 +46,18 @@ static inline void atomic64_set(atomic64_t *v, long i) } /** @@ -6318,7 +7375,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i * atomic64_add - add integer to atomic64 variable * @i: integer value to add * @v: pointer to type atomic64_t -@@ -42,6 +66,28 @@ static inline void atomic64_set(atomic64 +@@ -42,6 +66,28 @@ static inline void atomic64_set(atomic64_t *v, long i) */ static inline void atomic64_add(long i, atomic64_t *v) { @@ -6347,7 +7404,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i asm volatile(LOCK_PREFIX "addq %1,%0" : "=m" (v->counter) : "er" (i), "m" (v->counter)); -@@ -56,7 +102,29 @@ static inline void atomic64_add(long i, +@@ -56,7 +102,29 @@ static inline void atomic64_add(long i, atomic64_t *v) */ static inline void atomic64_sub(long i, atomic64_t *v) { @@ -6378,7 +7435,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i : "=m" (v->counter) : "er" (i), "m" (v->counter)); } -@@ -74,7 +142,16 @@ static inline int atomic64_sub_and_test( +@@ -74,7 +142,16 @@ static inline int atomic64_sub_and_test(long i, atomic64_t *v) { unsigned char c; @@ -6396,7 +7453,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i : "=m" (v->counter), "=qm" (c) : "er" (i), "m" (v->counter) : "memory"); return c; -@@ -88,6 +165,27 @@ static inline int atomic64_sub_and_test( +@@ -88,6 +165,27 @@ static inline int atomic64_sub_and_test(long i, atomic64_t *v) */ static inline void atomic64_inc(atomic64_t *v) { @@ -6424,7 +7481,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i asm volatile(LOCK_PREFIX "incq %0" : "=m" (v->counter) : "m" (v->counter)); -@@ -101,7 +199,28 @@ static inline void atomic64_inc(atomic64 +@@ -101,7 +199,28 @@ static inline void atomic64_inc(atomic64_t *v) */ static inline void atomic64_dec(atomic64_t *v) { @@ -6454,7 +7511,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i : "=m" (v->counter) : "m" (v->counter)); } -@@ -118,7 +237,16 @@ static inline int atomic64_dec_and_test( +@@ -118,7 +237,16 @@ static inline int atomic64_dec_and_test(atomic64_t *v) { unsigned char c; @@ -6472,7 +7529,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i : "=m" (v->counter), "=qm" (c) : "m" (v->counter) : "memory"); return c != 0; -@@ -136,7 +264,16 @@ static inline int atomic64_inc_and_test( +@@ -136,7 +264,16 @@ static inline int atomic64_inc_and_test(atomic64_t *v) { unsigned char c; @@ -6490,7 +7547,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i : "=m" (v->counter), "=qm" (c) : "m" (v->counter) : "memory"); return c != 0; -@@ -155,7 +292,16 @@ static inline int atomic64_add_negative( +@@ -155,7 +292,16 @@ static inline int atomic64_add_negative(long i, atomic64_t *v) { unsigned char c; @@ -6508,7 +7565,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i : "=m" (v->counter), "=qm" (c) : "er" (i), "m" (v->counter) : "memory"); return c; -@@ -171,7 +317,31 @@ static inline int atomic64_add_negative( +@@ -171,7 +317,31 @@ static inline int atomic64_add_negative(long i, atomic64_t *v) static inline long atomic64_add_return(long i, atomic64_t *v) { long __i = i; @@ -6541,7 +7598,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i : "+r" (i), "+m" (v->counter) : : "memory"); return i + __i; -@@ -183,6 +353,10 @@ static inline long atomic64_sub_return(l +@@ -183,6 +353,10 @@ static inline long atomic64_sub_return(long i, atomic64_t *v) } #define atomic64_inc_return(v) (atomic64_add_return(1, (v))) @@ -6552,7 +7609,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i #define atomic64_dec_return(v) (atomic64_sub_return(1, (v))) static inline long atomic64_cmpxchg(atomic64_t *v, long old, long new) -@@ -190,6 +364,11 @@ static inline long atomic64_cmpxchg(atom +@@ -190,6 +364,11 @@ static inline long atomic64_cmpxchg(atomic64_t *v, long old, long new) return cmpxchg(&v->counter, old, new); } @@ -6564,7 +7621,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i static inline long atomic64_xchg(atomic64_t *v, long new) { return xchg(&v->counter, new); -@@ -206,17 +385,30 @@ static inline long atomic64_xchg(atomic6 +@@ -206,17 +385,30 @@ static inline long atomic64_xchg(atomic64_t *v, long new) */ static inline int atomic64_add_unless(atomic64_t *v, long a, long u) { @@ -6599,424 +7656,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/atomic64_64.h linux-3.0.9/arch/x86/i } #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) -diff -urNp linux-3.0.9/arch/x86/include/asm/atomic.h linux-3.0.9/arch/x86/include/asm/atomic.h ---- linux-3.0.9/arch/x86/include/asm/atomic.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/atomic.h 2011-11-12 12:47:13.000000000 -0500 -@@ -22,7 +22,18 @@ - */ - static inline int atomic_read(const atomic_t *v) - { -- return (*(volatile int *)&(v)->counter); -+ return (*(volatile const int *)&(v)->counter); -+} -+ -+/** -+ * atomic_read_unchecked - read atomic variable -+ * @v: pointer of type atomic_unchecked_t -+ * -+ * Atomically reads the value of @v. -+ */ -+static inline int atomic_read_unchecked(const atomic_unchecked_t *v) -+{ -+ return (*(volatile const int *)&(v)->counter); - } - - /** -@@ -38,6 +49,18 @@ static inline void atomic_set(atomic_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 atomic_set_unchecked(atomic_unchecked_t *v, int i) -+{ -+ v->counter = i; -+} -+ -+/** - * atomic_add - add integer to atomic variable - * @i: integer value to add - * @v: pointer of type atomic_t -@@ -46,7 +69,29 @@ static inline void atomic_set(atomic_t * - */ - static inline void atomic_add(int i, atomic_t *v) - { -- asm volatile(LOCK_PREFIX "addl %1,%0" -+ asm volatile(LOCK_PREFIX "addl %1,%0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ LOCK_PREFIX "subl %1,%0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ : "+m" (v->counter) -+ : "ir" (i)); -+} -+ -+/** -+ * atomic_add_unchecked - add integer to atomic variable -+ * @i: integer value to add -+ * @v: pointer of type atomic_unchecked_t -+ * -+ * Atomically adds @i to @v. -+ */ -+static inline void atomic_add_unchecked(int i, atomic_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 - */ - static inline void atomic_sub(int i, atomic_t *v) - { -- asm volatile(LOCK_PREFIX "subl %1,%0" -+ asm volatile(LOCK_PREFIX "subl %1,%0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ LOCK_PREFIX "addl %1,%0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ : "+m" (v->counter) -+ : "ir" (i)); -+} -+ -+/** -+ * atomic_sub_unchecked - subtract integer from atomic variable -+ * @i: integer value to subtract -+ * @v: pointer of type atomic_unchecked_t -+ * -+ * Atomically subtracts @i from @v. -+ */ -+static inline void atomic_sub_unchecked(int i, atomic_unchecked_t *v) -+{ -+ asm volatile(LOCK_PREFIX "subl %1,%0\n" - : "+m" (v->counter) - : "ir" (i)); - } -@@ -78,7 +145,16 @@ static inline int atomic_sub_and_test(in - { - unsigned char c; - -- 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 "addl %2,%0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ "sete %1\n" - : "+m" (v->counter), "=qm" (c) - : "ir" (i) : "memory"); - return c; -@@ -92,7 +168,27 @@ static inline int atomic_sub_and_test(in - */ - static inline void atomic_inc(atomic_t *v) - { -- asm volatile(LOCK_PREFIX "incl %0" -+ asm volatile(LOCK_PREFIX "incl %0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ LOCK_PREFIX "decl %0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ : "+m" (v->counter)); -+} -+ -+/** -+ * atomic_inc_unchecked - increment atomic variable -+ * @v: pointer of type atomic_unchecked_t -+ * -+ * Atomically increments @v by 1. -+ */ -+static inline void atomic_inc_unchecked(atomic_unchecked_t *v) -+{ -+ asm volatile(LOCK_PREFIX "incl %0\n" - : "+m" (v->counter)); - } - -@@ -104,7 +200,27 @@ static inline void atomic_inc(atomic_t * - */ - static inline void atomic_dec(atomic_t *v) - { -- asm volatile(LOCK_PREFIX "decl %0" -+ asm volatile(LOCK_PREFIX "decl %0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ LOCK_PREFIX "incl %0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ : "+m" (v->counter)); -+} -+ -+/** -+ * atomic_dec_unchecked - decrement atomic variable -+ * @v: pointer of type atomic_unchecked_t -+ * -+ * Atomically decrements @v by 1. -+ */ -+static inline void atomic_dec_unchecked(atomic_unchecked_t *v) -+{ -+ asm volatile(LOCK_PREFIX "decl %0\n" - : "+m" (v->counter)); - } - -@@ -120,7 +236,16 @@ static inline int atomic_dec_and_test(at - { - unsigned char c; - -- asm volatile(LOCK_PREFIX "decl %0; sete %1" -+ asm volatile(LOCK_PREFIX "decl %0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ LOCK_PREFIX "incl %0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ "sete %1\n" - : "+m" (v->counter), "=qm" (c) - : : "memory"); - return c != 0; -@@ -138,7 +263,35 @@ static inline int atomic_inc_and_test(at - { - unsigned char c; - -- asm volatile(LOCK_PREFIX "incl %0; sete %1" -+ asm volatile(LOCK_PREFIX "incl %0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ LOCK_PREFIX "decl %0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ "sete %1\n" -+ : "+m" (v->counter), "=qm" (c) -+ : : "memory"); -+ return c != 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), "=qm" (c) - : : "memory"); - return c != 0; -@@ -157,7 +310,16 @@ static inline int atomic_add_negative(in - { - unsigned char c; - -- 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 "subl %2,%0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ "sets %1\n" - : "+m" (v->counter), "=qm" (c) - : "ir" (i) : "memory"); - return c; -@@ -180,6 +342,46 @@ static inline int atomic_add_return(int - #endif - /* Modern 486+ processor */ - __i = i; -+ asm volatile(LOCK_PREFIX "xaddl %0, %1\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ "movl %0, %1\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ : "+r" (i), "+m" (v->counter) -+ : : "memory"); -+ return i + __i; -+ -+#ifdef CONFIG_M386 -+no_xadd: /* Legacy 386 processor */ -+ local_irq_save(flags); -+ __i = 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 -+ * @i: integer value to add -+ * -+ * Atomically adds @i to @v and returns @i + @v -+ */ -+static inline int atomic_add_return_unchecked(int i, atomic_unchecked_t *v) -+{ -+ int __i; -+#ifdef CONFIG_M386 -+ unsigned long flags; -+ if (unlikely(boot_cpu_data.x86 <= 3)) -+ goto no_xadd; -+#endif -+ /* Modern 486+ processor */ -+ __i = i; - asm volatile(LOCK_PREFIX "xaddl %0, %1" - : "+r" (i), "+m" (v->counter) - : : "memory"); -@@ -208,6 +410,10 @@ static inline int atomic_sub_return(int - } - - #define atomic_inc_return(v) (atomic_add_return(1, v)) -+static inline int atomic_inc_return_unchecked(atomic_unchecked_t *v) -+{ -+ return atomic_add_return_unchecked(1, v); -+} - #define atomic_dec_return(v) (atomic_sub_return(1, v)) - - static inline int atomic_cmpxchg(atomic_t *v, int old, int new) -@@ -215,11 +421,21 @@ static inline int atomic_cmpxchg(atomic_ - return cmpxchg(&v->counter, old, new); - } - -+static inline int atomic_cmpxchg_unchecked(atomic_unchecked_t *v, int old, int new) -+{ -+ return cmpxchg(&v->counter, old, new); -+} -+ - static inline int atomic_xchg(atomic_t *v, int new) - { - return xchg(&v->counter, new); - } - -+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,21 +447,77 @@ static inline int atomic_xchg(atomic_t * - */ - static inline int atomic_add_unless(atomic_t *v, int a, int u) - { -- int c, old; -+ int c, old, new; - c = atomic_read(v); - for (;;) { -- if (unlikely(c == (u))) -+ if (unlikely(c == u)) - break; -- old = atomic_cmpxchg((v), c, c + (a)); -+ -+ asm volatile("addl %2,%0\n" -+ -+#ifdef CONFIG_PAX_REFCOUNT -+ "jno 0f\n" -+ "subl %2,%0\n" -+ "int $4\n0:\n" -+ _ASM_EXTABLE(0b, 0b) -+#endif -+ -+ : "=r" (new) -+ : "0" (c), "ir" (a)); -+ -+ old = atomic_cmpxchg(v, c, new); - if (likely(old == c)) - break; - c = old; - } -- return c != (u); -+ return c != u; - } - - #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) - -+/** -+ * 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 = hint, new; -+ -+ /* sanity test, should be removed by compiler if hint is a constant */ -+ if (!hint) -+ return atomic_inc_not_zero(v); -+ -+ 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 -+ -+ : "=r" (new) -+ : "0" (c)); -+ -+ val = atomic_cmpxchg(v, c, new); -+ if (val == c) -+ return 1; -+ c = val; -+ } while (c); -+ -+ return 0; -+} -+ - /* - * atomic_dec_if_positive - decrement by 1 if old value positive - * @v: pointer of type atomic_t -diff -urNp linux-3.0.9/arch/x86/include/asm/bitops.h linux-3.0.9/arch/x86/include/asm/bitops.h ---- linux-3.0.9/arch/x86/include/asm/bitops.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/bitops.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/bitops.h b/arch/x86/include/asm/bitops.h +index 69d5813..0b1900e 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. */ @@ -7026,9 +7669,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/bitops.h linux-3.0.9/arch/x86/includ #define CONST_MASK(nr) (1 << ((nr) & 7)) /** -diff -urNp linux-3.0.9/arch/x86/include/asm/boot.h linux-3.0.9/arch/x86/include/asm/boot.h ---- linux-3.0.9/arch/x86/include/asm/boot.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/boot.h 2011-11-12 12:47:13.000000000 -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 <asm/pgtable_types.h> @@ -7046,21 +7690,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/boot.h linux-3.0.9/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.0.9/arch/x86/include/asm/cacheflush.h linux-3.0.9/arch/x86/include/asm/cacheflush.h ---- linux-3.0.9/arch/x86/include/asm/cacheflush.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/cacheflush.h 2011-11-12 12:47:13.000000000 -0500 -@@ -26,7 +26,7 @@ static inline unsigned long get_page_mem - unsigned long pg_flags = pg->flags & _PGMT_MASK; - - if (pg_flags == _PGMT_DEFAULT) -- return -1; -+ return ~0UL; - else if (pg_flags == _PGMT_WC) - return _PAGE_CACHE_WC; - else if (pg_flags == _PGMT_UC_MINUS) -diff -urNp linux-3.0.9/arch/x86/include/asm/cache.h linux-3.0.9/arch/x86/include/asm/cache.h ---- linux-3.0.9/arch/x86/include/asm/cache.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/cache.h 2011-11-12 12:47:13.000000000 -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 @@ /* L1 cache line size */ @@ -7077,10 +7710,24 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/cache.h linux-3.0.9/arch/x86/include #ifdef CONFIG_X86_VSMP #ifdef CONFIG_SMP -diff -urNp linux-3.0.9/arch/x86/include/asm/checksum_32.h linux-3.0.9/arch/x86/include/asm/checksum_32.h ---- linux-3.0.9/arch/x86/include/asm/checksum_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/checksum_32.h 2011-11-12 12:47:13.000000000 -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/cacheflush.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 page *pg) + unsigned long pg_flags = pg->flags & _PGMT_MASK; + + if (pg_flags == _PGMT_DEFAULT) +- return -1; ++ return ~0UL; + else if (pg_flags == _PGMT_WC) + return _PAGE_CACHE_WC; + else if (pg_flags == _PGMT_UC_MINUS) +diff --git a/arch/x86/include/asm/checksum_32.h b/arch/x86/include/asm/checksum_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 void *src, void *dst, int len, __wsum sum, int *src_err_ptr, int *dst_err_ptr); @@ -7095,7 +7742,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/checksum_32.h linux-3.0.9/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(); @@ -7104,7 +7751,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/checksum_32.h linux-3.0.9/arch/x86/i len, sum, err_ptr, NULL); } -@@ -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 void *src, { might_sleep(); if (access_ok(VERIFY_WRITE, dst, len)) @@ -7113,10 +7760,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/checksum_32.h linux-3.0.9/arch/x86/i len, sum, NULL, err_ptr); if (len) -diff -urNp linux-3.0.9/arch/x86/include/asm/cpufeature.h linux-3.0.9/arch/x86/include/asm/cpufeature.h ---- linux-3.0.9/arch/x86/include/asm/cpufeature.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/cpufeature.h 2011-11-12 12:47:13.000000000 -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/cpufeature.h +index 71cc380..071cbbb 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" @@ -7125,25 +7773,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/cpufeature.h linux-3.0.9/arch/x86/in "3: movb $1,%0\n" "4:\n" ".previous\n" -diff -urNp linux-3.0.9/arch/x86/include/asm/desc_defs.h linux-3.0.9/arch/x86/include/asm/desc_defs.h ---- linux-3.0.9/arch/x86/include/asm/desc_defs.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/desc_defs.h 2011-11-12 12:47:13.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)); - -diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/asm/desc.h ---- linux-3.0.9/arch/x86/include/asm/desc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/desc.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/desc.h b/arch/x86/include/asm/desc.h +index 7b439d9..1b5aa91 100644 +--- a/arch/x86/include/asm/desc.h ++++ b/arch/x86/include/asm/desc.h @@ -4,6 +4,7 @@ #include <asm/desc_defs.h> #include <asm/ldt.h> @@ -7152,7 +7785,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ #include <linux/smp.h> -@@ -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 desc->type = (info->read_exec_only ^ 1) << 1; desc->type |= info->contents << 2; @@ -7160,7 +7793,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ desc->s = 1; desc->dpl = 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 } extern struct desc_ptr idt_descr; @@ -7181,7 +7814,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ } #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, unsigned char type, unsigned long base, unsigned dpl, unsigned flags, unsigned short seg) { @@ -7198,7 +7831,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ } #endif -@@ -115,12 +118,16 @@ static inline void paravirt_free_ldt(str +@@ -115,12 +118,16 @@ static inline void paravirt_free_ldt(struct desc_struct *ldt, unsigned entries) static inline void native_write_idt_entry(gate_desc *idt, int entry, const gate_desc *gate) { @@ -7215,7 +7848,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ } 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 = sizeof(*gdt); break; } @@ -7225,7 +7858,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ } static inline void pack_descriptor(struct desc_struct *desc, unsigned long base, -@@ -207,7 +216,9 @@ static inline void native_set_ldt(const +@@ -207,7 +216,9 @@ static inline void native_set_ldt(const void *addr, unsigned int entries) static inline void native_load_tr_desc(void) { @@ -7235,7 +7868,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ } 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_struct *t, unsigned int cpu) struct desc_struct *gdt = get_cpu_gdt_table(cpu); unsigned int i; @@ -7246,7 +7879,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ } #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 = (limit >> 16) & 0xf; } @@ -7255,7 +7888,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/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. */ @@ -7264,7 +7897,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/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. */ @@ -7287,7 +7920,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/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, void *addr) static inline void set_task_gate(unsigned int n, unsigned int gdt_entry) { BUG_ON((unsigned)n > 0xFF); @@ -7322,9 +7955,27 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/desc.h linux-3.0.9/arch/x86/include/ +#endif + #endif /* _ASM_X86_DESC_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/e820.h linux-3.0.9/arch/x86/include/asm/e820.h ---- linux-3.0.9/arch/x86/include/asm/e820.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/e820.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/desc_defs.h b/arch/x86/include/asm/desc_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)); + +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 @@ -7334,9 +7985,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/e820.h linux-3.0.9/arch/x86/include/ #define BIOS_END 0x00100000 #define BIOS_ROM_BASE 0xffe00000 -diff -urNp linux-3.0.9/arch/x86/include/asm/elf.h linux-3.0.9/arch/x86/include/asm/elf.h ---- linux-3.0.9/arch/x86/include/asm/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/elf.h 2011-11-12 12:47:13.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 program that it will "exec", and that there is sufficient room for the brk. */ @@ -7383,7 +8035,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/elf.h linux-3.0.9/arch/x86/include/a #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 @@ -7391,9 +8043,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/elf.h linux-3.0.9/arch/x86/include/a -#define arch_randomize_brk arch_randomize_brk - #endif /* _ASM_X86_ELF_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/emergency-restart.h linux-3.0.9/arch/x86/include/asm/emergency-restart.h ---- linux-3.0.9/arch/x86/include/asm/emergency-restart.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/emergency-restart.h 2011-11-12 12:47:13.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 { extern enum reboot_type reboot_type; @@ -7402,9 +8055,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/emergency-restart.h linux-3.0.9/arch +extern void machine_emergency_restart(void) __noreturn; #endif /* _ASM_X86_EMERGENCY_RESTART_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/futex.h linux-3.0.9/arch/x86/include/asm/futex.h ---- linux-3.0.9/arch/x86/include/asm/futex.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/futex.h 2011-11-12 12:47:13.000000000 -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 <asm/system.h> @@ -7434,7 +8088,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/futex.h linux-3.0.9/arch/x86/include : "r" (oparg), "i" (-EFAULT), "1" (0)) static inline int futex_atomic_op_inuser(int encoded_op, u32 __user *uaddr) -@@ -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) switch (op) { case FUTEX_OP_SET: @@ -7447,7 +8101,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/futex.h linux-3.0.9/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(u32 *uval, u32 __user *uaddr, if (!access_ok(VERIFY_WRITE, uaddr, sizeof(u32))) return -EFAULT; @@ -7463,9 +8117,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/futex.h linux-3.0.9/arch/x86/include : "i" (-EFAULT), "r" (newval), "1" (oldval) : "memory" ); -diff -urNp linux-3.0.9/arch/x86/include/asm/hw_irq.h linux-3.0.9/arch/x86/include/asm/hw_irq.h ---- linux-3.0.9/arch/x86/include/asm/hw_irq.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/hw_irq.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/hw_irq.h b/arch/x86/include/asm/hw_irq.h +index bb9efe8..c6da984 100644 +--- a/arch/x86/include/asm/hw_irq.h ++++ b/arch/x86/include/asm/hw_irq.h @@ -137,8 +137,8 @@ extern void setup_ioapic_dest(void); extern void enable_IO_APIC(void); @@ -7477,10 +8132,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/hw_irq.h linux-3.0.9/arch/x86/includ /* EISA */ extern void eisa_set_level_irq(unsigned int irq); -diff -urNp linux-3.0.9/arch/x86/include/asm/i387.h linux-3.0.9/arch/x86/include/asm/i387.h ---- linux-3.0.9/arch/x86/include/asm/i387.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/i387.h 2011-11-12 12:47:13.000000000 -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; @@ -7492,7 +8148,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/i387.h linux-3.0.9/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_struct __user *fx) { int err; @@ -7504,7 +8160,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/i387.h linux-3.0.9/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 */ /* We need a safe address that is cheap to find and that is already @@ -7520,7 +8176,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/i387.h linux-3.0.9/arch/x86/include/ /* * 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 = current_thread_info(); preempt_disable(); if (me->status & TS_USEDFPU) @@ -7529,9 +8185,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/i387.h linux-3.0.9/arch/x86/include/ else clts(); } -diff -urNp linux-3.0.9/arch/x86/include/asm/io.h linux-3.0.9/arch/x86/include/asm/io.h ---- linux-3.0.9/arch/x86/include/asm/io.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/io.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/io.h b/arch/x86/include/asm/io.h +index d02804d..f0a62d9 100644 +--- a/arch/x86/include/asm/io.h ++++ b/arch/x86/include/asm/io.h @@ -196,6 +196,17 @@ extern void set_iounmap_nonlazy(void); #include <linux/vmalloc.h> @@ -7550,10 +8207,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/io.h linux-3.0.9/arch/x86/include/as /* * Convert a virtual cached pointer to an uncached pointer */ -diff -urNp linux-3.0.9/arch/x86/include/asm/irqflags.h linux-3.0.9/arch/x86/include/asm/irqflags.h ---- linux-3.0.9/arch/x86/include/asm/irqflags.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/irqflags.h 2011-11-12 12:47:13.000000000 -0500 -@@ -140,6 +140,11 @@ static inline unsigned long arch_local_i +diff --git a/arch/x86/include/asm/irqflags.h b/arch/x86/include/asm/irqflags.h +index 5745ce8..949fb75 100644 +--- a/arch/x86/include/asm/irqflags.h ++++ b/arch/x86/include/asm/irqflags.h +@@ -140,6 +140,11 @@ static inline unsigned long arch_local_irq_save(void) sti; \ sysexit @@ -7565,9 +8223,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/irqflags.h linux-3.0.9/arch/x86/incl #else #define INTERRUPT_RETURN iret #define ENABLE_INTERRUPTS_SYSEXIT sti; sysexit -diff -urNp linux-3.0.9/arch/x86/include/asm/kprobes.h linux-3.0.9/arch/x86/include/asm/kprobes.h ---- linux-3.0.9/arch/x86/include/asm/kprobes.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/kprobes.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/kprobes.h b/arch/x86/include/asm/kprobes.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 @@ -7584,9 +8243,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/kprobes.h linux-3.0.9/arch/x86/inclu #define flush_insn_slot(p) do { } while (0) -diff -urNp linux-3.0.9/arch/x86/include/asm/kvm_host.h linux-3.0.9/arch/x86/include/asm/kvm_host.h ---- linux-3.0.9/arch/x86/include/asm/kvm_host.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/kvm_host.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h +index d2ac8e2..39db8ad 100644 +--- a/arch/x86/include/asm/kvm_host.h ++++ b/arch/x86/include/asm/kvm_host.h @@ -441,7 +441,7 @@ struct kvm_arch { unsigned int n_used_mmu_pages; unsigned int n_requested_mmu_pages; @@ -7605,9 +8265,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/kvm_host.h linux-3.0.9/arch/x86/incl struct kvm_arch_async_pf { u32 token; -diff -urNp linux-3.0.9/arch/x86/include/asm/local.h linux-3.0.9/arch/x86/include/asm/local.h ---- linux-3.0.9/arch/x86/include/asm/local.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/local.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/local.h b/arch/x86/include/asm/local.h +index 2e99724..e6110cc 100644 +--- a/arch/x86/include/asm/local.h ++++ b/arch/x86/include/asm/local.h @@ -18,26 +18,58 @@ typedef struct { static inline void local_inc(local_t *l) @@ -7671,7 +8332,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/local.h linux-3.0.9/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; @@ -7689,7 +8350,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/local.h linux-3.0.9/arch/x86/include : "+m" (l->a.counter), "=qm" (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; @@ -7707,7 +8368,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/local.h linux-3.0.9/arch/x86/include : "+m" (l->a.counter), "=qm" (c) : : "memory"); return c != 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; @@ -7725,7 +8386,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/local.h linux-3.0.9/arch/x86/include : "+m" (l->a.counter), "=qm" (c) : : "memory"); return c != 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; @@ -7743,7 +8404,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/local.h linux-3.0.9/arch/x86/include : "+m" (l->a.counter), "=qm" (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 = i; @@ -7760,9 +8421,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/local.h linux-3.0.9/arch/x86/include : "+r" (i), "+m" (l->a.counter) : : "memory"); return i + __i; -diff -urNp linux-3.0.9/arch/x86/include/asm/mman.h linux-3.0.9/arch/x86/include/asm/mman.h ---- linux-3.0.9/arch/x86/include/asm/mman.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/mman.h 2011-11-12 12:47:13.000000000 -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 @@ #include <asm-generic/mman.h> @@ -7778,10 +8440,45 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/mman.h linux-3.0.9/arch/x86/include/ +#endif + #endif /* _ASM_X86_MMAN_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/mmu_context.h linux-3.0.9/arch/x86/include/asm/mmu_context.h ---- linux-3.0.9/arch/x86/include/asm/mmu_context.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/mmu_context.h 2011-11-12 12:47:13.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 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. + */ + typedef struct { +- void *ldt; ++ struct desc_struct *ldt; + int size; + + #ifdef CONFIG_X86_64 +@@ -18,7 +18,19 @@ typedef struct { + #endif + + 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; + + #ifdef CONFIG_SMP +diff --git a/arch/x86/include/asm/mmu_context.h b/arch/x86/include/asm/mmu_context.h +index 8b5393e..b6d1178 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); static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_struct *tsk) { @@ -7800,7 +8497,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/mmu_context.h linux-3.0.9/arch/x86/i #ifdef CONFIG_SMP if (percpu_read(cpu_tlbstate.state) == 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 = smp_processor_id(); @@ -7831,7 +8528,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/mmu_context.h linux-3.0.9/arch/x86/i /* 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 != next->context.ldt)) load_LDT_nolock(&next->context); @@ -7871,7 +8568,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/mmu_context.h linux-3.0.9/arch/x86/i percpu_write(cpu_tlbstate.state, TLBSTATE_OK); BUG_ON(percpu_read(cpu_tlbstate.active_mm) != next); -@@ -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. */ @@ -7901,42 +8598,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/mmu_context.h linux-3.0.9/arch/x86/i } #define activate_mm(prev, next) \ -diff -urNp linux-3.0.9/arch/x86/include/asm/mmu.h linux-3.0.9/arch/x86/include/asm/mmu.h ---- linux-3.0.9/arch/x86/include/asm/mmu.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/mmu.h 2011-11-12 12:47:13.000000000 -0500 -@@ -9,7 +9,7 @@ - * we put the segment information here. - */ - typedef struct { -- void *ldt; -+ struct desc_struct *ldt; - int size; - - #ifdef CONFIG_X86_64 -@@ -18,7 +18,19 @@ typedef struct { - #endif - - 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; - - #ifdef CONFIG_SMP -diff -urNp linux-3.0.9/arch/x86/include/asm/module.h linux-3.0.9/arch/x86/include/asm/module.h ---- linux-3.0.9/arch/x86/include/asm/module.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/module.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/module.h b/arch/x86/include/asm/module.h +index 9eae775..c5ec276 100644 +--- a/arch/x86/include/asm/module.h ++++ b/arch/x86/include/asm/module.h @@ -5,6 +5,7 @@ #ifdef CONFIG_X86_64 @@ -7966,9 +8631,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/module.h linux-3.0.9/arch/x86/includ +#define MODULE_ARCH_VERMAGIC MODULE_PROC_FAMILY MODULE_PAX_KERNEXEC MODULE_PAX_UDEREF + #endif /* _ASM_X86_MODULE_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/page_64_types.h linux-3.0.9/arch/x86/include/asm/page_64_types.h ---- linux-3.0.9/arch/x86/include/asm/page_64_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/page_64_types.h 2011-11-12 12:47:13.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); /* duplicated to the one in bootmem.h */ @@ -7978,10 +8644,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/page_64_types.h linux-3.0.9/arch/x86 extern unsigned long __phys_addr(unsigned long); #define __phys_reloc_hide(x) (x) -diff -urNp linux-3.0.9/arch/x86/include/asm/paravirt.h linux-3.0.9/arch/x86/include/asm/paravirt.h ---- linux-3.0.9/arch/x86/include/asm/paravirt.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/paravirt.h 2011-11-12 12:47:13.000000000 -0500 -@@ -658,6 +658,18 @@ static inline void set_pgd(pgd_t *pgdp, +diff --git a/arch/x86/include/asm/paravirt.h b/arch/x86/include/asm/paravirt.h +index ebbc4d8..38597f4 100644 +--- a/arch/x86/include/asm/paravirt.h ++++ b/arch/x86/include/asm/paravirt.h +@@ -658,6 +658,18 @@ static inline void set_pgd(pgd_t *pgdp, pgd_t pgd) val); } @@ -8000,7 +8667,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/paravirt.h linux-3.0.9/arch/x86/incl static inline void pgd_clear(pgd_t *pgdp) { set_pgd(pgdp, __pgd(0)); -@@ -739,6 +751,21 @@ static inline void __set_fixmap(unsigned +@@ -739,6 +751,21 @@ static inline void __set_fixmap(unsigned /* enum fixed_addresses */ idx, pv_mmu_ops.set_fixmap(idx, phys, flags); } @@ -8053,9 +8720,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/paravirt.h linux-3.0.9/arch/x86/incl #endif /* CONFIG_X86_32 */ #endif /* __ASSEMBLY__ */ -diff -urNp linux-3.0.9/arch/x86/include/asm/paravirt_types.h linux-3.0.9/arch/x86/include/asm/paravirt_types.h ---- linux-3.0.9/arch/x86/include/asm/paravirt_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/paravirt_types.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/paravirt_types.h b/arch/x86/include/asm/paravirt_types.h +index 8288509..437d0ff 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, @@ -8127,10 +8795,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/paravirt_types.h linux-3.0.9/arch/x8 /* 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.0.9/arch/x86/include/asm/pgalloc.h linux-3.0.9/arch/x86/include/asm/pgalloc.h ---- linux-3.0.9/arch/x86/include/asm/pgalloc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgalloc.h 2011-11-12 12:47:13.000000000 -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/pgalloc.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_struct *mm, pmd_t *pmd, pte_t *pte) { paravirt_alloc_pte(mm, __pa(pte) >> PAGE_SHIFT); @@ -8144,10 +8813,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgalloc.h linux-3.0.9/arch/x86/inclu set_pmd(pmd, __pmd(__pa(pte) | _PAGE_TABLE)); } -diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable-2level.h linux-3.0.9/arch/x86/include/asm/pgtable-2level.h ---- linux-3.0.9/arch/x86/include/asm/pgtable-2level.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable-2level.h 2011-11-12 12:47:13.000000000 -0500 -@@ -18,7 +18,9 @@ static inline void native_set_pte(pte_t +diff --git a/arch/x86/include/asm/pgtable-2level.h b/arch/x86/include/asm/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) static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) { @@ -8157,88 +8827,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable-2level.h linux-3.0.9/arch/x8 } static inline void native_set_pte_atomic(pte_t *ptep, pte_t pte) -diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_32.h linux-3.0.9/arch/x86/include/asm/pgtable_32.h ---- linux-3.0.9/arch/x86/include/asm/pgtable_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable_32.h 2011-11-12 12:47:13.000000000 -0500 -@@ -25,9 +25,6 @@ - struct mm_struct; - struct vm_area_struct; - --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 <asm/pgtable-2level.h> - #endif - -+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) - -@@ -74,6 +79,9 @@ do { \ - - #endif /* !__ASSEMBLY__ */ - -+#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.0.9/arch/x86/include/asm/pgtable_32_types.h linux-3.0.9/arch/x86/include/asm/pgtable_32_types.h ---- linux-3.0.9/arch/x86/include/asm/pgtable_32_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable_32_types.h 2011-11-12 12:47:13.000000000 -0500 -@@ -8,7 +8,7 @@ - */ - #ifdef CONFIG_X86_PAE - # include <asm/pgtable-3level_types.h> --# define PMD_SIZE (1UL << PMD_SHIFT) -+# define PMD_SIZE (_AC(1, UL) << PMD_SHIFT) - # define PMD_MASK (~(PMD_SIZE - 1)) - #else - # include <asm/pgtable-2level_types.h> -@@ -46,6 +46,19 @@ extern bool __vmalloc_start_set; /* set - # define VMALLOC_END (FIXADDR_START - 2 * PAGE_SIZE) - #endif - -+#ifdef CONFIG_PAX_KERNEXEC -+#ifndef __ASSEMBLY__ -+extern unsigned char MODULES_EXEC_VADDR[]; -+extern unsigned char MODULES_EXEC_END[]; -+#endif -+#include <asm/boot.h> -+#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.0.9/arch/x86/include/asm/pgtable-3level.h linux-3.0.9/arch/x86/include/asm/pgtable-3level.h ---- linux-3.0.9/arch/x86/include/asm/pgtable-3level.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable-3level.h 2011-11-12 12:47:13.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/asm/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) static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) { @@ -8255,67 +8848,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable-3level.h linux-3.0.9/arch/x8 } /* -diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_64.h linux-3.0.9/arch/x86/include/asm/pgtable_64.h ---- linux-3.0.9/arch/x86/include/asm/pgtable_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable_64.h 2011-11-12 12:47:13.000000000 -0500 -@@ -16,10 +16,13 @@ - - 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]; - - #define swapper_pg_dir init_level4_pgt - -@@ -61,7 +64,9 @@ static inline void native_set_pte_atomic - - static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) - { -+ pax_open_kernel(); - *pmdp = pmd; -+ pax_close_kernel(); - } - - static inline void native_pmd_clear(pmd_t *pmd) -@@ -107,6 +112,13 @@ static inline void native_pud_clear(pud_ - - static inline void native_set_pgd(pgd_t *pgdp, pgd_t pgd) - { -+ pax_open_kernel(); -+ *pgdp = pgd; -+ pax_close_kernel(); -+} -+ -+static inline void native_set_pgd_batched(pgd_t *pgdp, pgd_t pgd) -+{ - *pgdp = pgd; - } - -diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_64_types.h linux-3.0.9/arch/x86/include/asm/pgtable_64_types.h ---- linux-3.0.9/arch/x86/include/asm/pgtable_64_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable_64_types.h 2011-11-12 12:47:13.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) - - #endif /* _ASM_X86_PGTABLE_64_DEFS_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable.h linux-3.0.9/arch/x86/include/asm/pgtable.h ---- linux-3.0.9/arch/x86/include/asm/pgtable.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable.h 2011-11-12 12:47:13.000000000 -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/pgtable.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); #ifndef __PAGETABLE_PUD_FOLDED #define set_pgd(pgdp, pgd) native_set_pgd(pgdp, pgd) @@ -8323,7 +8860,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable.h linux-3.0.9/arch/x86/inclu #define pgd_clear(pgd) native_pgd_clear(pgd) #endif -@@ -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); #define arch_end_context_switch(prev) do {} while(0) @@ -8375,7 +8912,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable.h linux-3.0.9/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 +@@ -196,9 +236,29 @@ static inline pte_t pte_wrprotect(pte_t pte) return pte_clear_flags(pte, _PAGE_RW); } @@ -8406,7 +8943,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable.h linux-3.0.9/arch/x86/inclu } static inline pte_t pte_mkdirty(pte_t pte) -@@ -390,6 +450,15 @@ pte_t *populate_extra_pte(unsigned long +@@ -390,6 +450,15 @@ pte_t *populate_extra_pte(unsigned long vaddr); #endif #ifndef __ASSEMBLY__ @@ -8422,7 +8959,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable.h linux-3.0.9/arch/x86/inclu #include <linux/mm_types.h> 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) static inline int pgd_bad(pgd_t pgd) { @@ -8466,7 +9003,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable.h linux-3.0.9/arch/x86/inclu #ifndef __ASSEMBLY__ 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_struct *mm, * dst and src can be on the same page, but the range must not overlap, * and must not cross a page boundary. */ @@ -8492,9 +9029,149 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable.h linux-3.0.9/arch/x86/inclu #include <asm-generic/pgtable.h> #endif /* __ASSEMBLY__ */ -diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_types.h linux-3.0.9/arch/x86/include/asm/pgtable_types.h ---- linux-3.0.9/arch/x86/include/asm/pgtable_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/pgtable_types.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/pgtable_32.h b/arch/x86/include/asm/pgtable_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; + +-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 <asm/pgtable-2level.h> + #endif + ++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) + +@@ -74,6 +79,9 @@ do { \ + + #endif /* !__ASSEMBLY__ */ + ++#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 <asm/pgtable-3level_types.h> +-# define PMD_SIZE (1UL << PMD_SHIFT) ++# define PMD_SIZE (_AC(1, UL) << PMD_SHIFT) + # define PMD_MASK (~(PMD_SIZE - 1)) + #else + # include <asm/pgtable-2level_types.h> +@@ -46,6 +46,19 @@ extern bool __vmalloc_start_set; /* set once high_memory is set */ + # define VMALLOC_END (FIXADDR_START - 2 * PAGE_SIZE) + #endif + ++#ifdef CONFIG_PAX_KERNEXEC ++#ifndef __ASSEMBLY__ ++extern unsigned char MODULES_EXEC_VADDR[]; ++extern unsigned char MODULES_EXEC_END[]; ++#endif ++#include <asm/boot.h> ++#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/pgtable_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 @@ + + 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]; + + #define swapper_pg_dir init_level4_pgt + +@@ -61,7 +64,9 @@ static inline void native_set_pte_atomic(pte_t *ptep, pte_t pte) + + static inline void native_set_pmd(pmd_t *pmdp, pmd_t pmd) + { ++ pax_open_kernel(); + *pmdp = pmd; ++ pax_close_kernel(); + } + + static inline void native_pmd_clear(pmd_t *pmd) +@@ -107,6 +112,13 @@ static inline void native_pud_clear(pud_t *pud) + + static inline void native_set_pgd(pgd_t *pgdp, pgd_t pgd) + { ++ pax_open_kernel(); ++ *pgdp = pgd; ++ pax_close_kernel(); ++} ++ ++static inline void native_set_pgd_batched(pgd_t *pgdp, pgd_t pgd) ++{ + *pgdp = pgd; + } + +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) + + #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 d56187c..8e16dc8 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 */ @@ -8564,7 +9241,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_types.h linux-3.0.9/arch/x86 #define PGD_IDENT_ATTR 0x001 /* PRESENT (no other attributes) */ #endif -@@ -205,7 +208,17 @@ static inline pgdval_t pgd_flags(pgd_t p +@@ -205,7 +208,17 @@ static inline pgdval_t pgd_flags(pgd_t pgd) { return native_pgd_val(pgd) & PTE_FLAGS_MASK; } @@ -8582,7 +9259,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_types.h linux-3.0.9/arch/x86 #if PAGETABLE_LEVELS > 3 typedef struct { pudval_t pud; } pud_t; -@@ -219,8 +232,6 @@ static inline pudval_t native_pud_val(pu +@@ -219,8 +232,6 @@ static inline pudval_t native_pud_val(pud_t pud) return pud.pud; } #else @@ -8591,7 +9268,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_types.h linux-3.0.9/arch/x86 static inline pudval_t native_pud_val(pud_t pud) { return native_pgd_val(pud.pgd); -@@ -240,8 +251,6 @@ static inline pmdval_t native_pmd_val(pm +@@ -240,8 +251,6 @@ static inline pmdval_t native_pmd_val(pmd_t pmd) return pmd.pmd; } #else @@ -8608,9 +9285,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/pgtable_types.h linux-3.0.9/arch/x86 #define pgprot_writecombine pgprot_writecombine extern pgprot_t pgprot_writecombine(pgprot_t prot); -diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/include/asm/processor.h ---- linux-3.0.9/arch/x86/include/asm/processor.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/processor.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/processor.h +index 2193715..fa70b92 100644 +--- a/arch/x86/include/asm/processor.h ++++ b/arch/x86/include/asm/processor.h @@ -266,7 +266,7 @@ struct tss_struct { } ____cacheline_aligned; @@ -8620,7 +9298,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc /* * Save the original ist values for checking stack pointers during debugging -@@ -860,11 +860,18 @@ static inline void spin_lock_prefetch(co +@@ -860,11 +860,18 @@ static inline void spin_lock_prefetch(const void *x) */ #define TASK_SIZE PAGE_OFFSET #define TASK_SIZE_MAX TASK_SIZE @@ -8641,7 +9319,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc .vm86_info = NULL, \ .sysenter_cs = __KERNEL_CS, \ .io_bitmap_ptr = NULL, \ -@@ -878,7 +885,7 @@ static inline void spin_lock_prefetch(co +@@ -878,7 +885,7 @@ static inline void spin_lock_prefetch(const void *x) */ #define INIT_TSS { \ .x86_tss = { \ @@ -8650,7 +9328,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc .ss0 = __KERNEL_DS, \ .ss1 = __KERNEL_CS, \ .io_bitmap_base = INVALID_IO_BITMAP_OFFSET, \ -@@ -889,11 +896,7 @@ static inline void spin_lock_prefetch(co +@@ -889,11 +896,7 @@ static inline void spin_lock_prefetch(const void *x) extern unsigned long thread_saved_pc(struct task_struct *tsk); #define THREAD_SIZE_LONGS (THREAD_SIZE/sizeof(unsigned long)) @@ -8663,7 +9341,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc /* * The below -8 is to reserve 8 bytes on top of the ring0 stack. -@@ -908,7 +911,7 @@ extern unsigned long thread_saved_pc(str +@@ -908,7 +911,7 @@ extern unsigned long thread_saved_pc(struct task_struct *tsk); #define task_pt_regs(task) \ ({ \ struct pt_regs *__regs__; \ @@ -8672,7 +9350,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc __regs__ - 1; \ }) -@@ -918,13 +921,13 @@ extern unsigned long thread_saved_pc(str +@@ -918,13 +921,13 @@ extern unsigned long thread_saved_pc(struct task_struct *tsk); /* * User space process size. 47bits minus one guard page. */ @@ -8688,7 +9366,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc #define TASK_SIZE (test_thread_flag(TIF_IA32) ? \ IA32_PAGE_OFFSET : TASK_SIZE_MAX) -@@ -935,11 +938,11 @@ extern unsigned long thread_saved_pc(str +@@ -935,11 +938,11 @@ extern unsigned long thread_saved_pc(struct task_struct *tsk); #define STACK_TOP_MAX TASK_SIZE_MAX #define INIT_THREAD { \ @@ -8702,7 +9380,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc } /* -@@ -961,6 +964,10 @@ extern void start_thread(struct pt_regs +@@ -961,6 +964,10 @@ extern void start_thread(struct pt_regs *regs, unsigned long new_ip, */ #define TASK_UNMAPPED_BASE (PAGE_ALIGN(TASK_SIZE / 3)) @@ -8713,10 +9391,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/processor.h linux-3.0.9/arch/x86/inc #define KSTK_EIP(task) (task_pt_regs(task)->ip) /* Get/set a process' ability to use the timestamp counter instruction */ -diff -urNp linux-3.0.9/arch/x86/include/asm/ptrace.h linux-3.0.9/arch/x86/include/asm/ptrace.h ---- linux-3.0.9/arch/x86/include/asm/ptrace.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/ptrace.h 2011-11-12 12:47:13.000000000 -0500 -@@ -153,28 +153,29 @@ static inline unsigned long regs_return_ +diff --git a/arch/x86/include/asm/ptrace.h b/arch/x86/include/asm/ptrace.h +index 94e7618..55ac793 100644 +--- a/arch/x86/include/asm/ptrace.h ++++ b/arch/x86/include/asm/ptrace.h +@@ -153,28 +153,29 @@ static inline unsigned long regs_return_value(struct pt_regs *regs) } /* @@ -8752,9 +9431,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/ptrace.h linux-3.0.9/arch/x86/includ #endif } -diff -urNp linux-3.0.9/arch/x86/include/asm/reboot.h linux-3.0.9/arch/x86/include/asm/reboot.h ---- linux-3.0.9/arch/x86/include/asm/reboot.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/reboot.h 2011-11-12 12:47:13.000000000 -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; @@ -8781,10 +9461,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/reboot.h linux-3.0.9/arch/x86/includ /* These must match dispatch_table in reboot_32.S */ #define MRR_BIOS 0 #define MRR_APM 1 -diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/arch/x86/include/asm/rwsem.h ---- linux-3.0.9/arch/x86/include/asm/rwsem.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/rwsem.h 2011-11-12 12:47:13.000000000 -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 *sem) { asm volatile("# beginning down_read\n\t" LOCK_PREFIX _ASM_INC "(%1)\n\t" @@ -8799,7 +9480,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/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_semaphore *sem) "1:\n\t" " mov %1,%2\n\t" " add %3,%2\n\t" @@ -8814,7 +9495,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/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_semaphore *sem, int subclass) long tmp; asm volatile("# beginning down_write\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -8829,7 +9510,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/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 *sem) long tmp; asm volatile("# beginning __up_read\n\t" LOCK_PREFIX " xadd %1,(%2)\n\t" @@ -8844,7 +9525,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/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" @@ -8859,7 +9540,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/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_semaphore *sem) { asm volatile("# beginning __downgrade_write\n\t" LOCK_PREFIX _ASM_ADD "%2,(%1)\n\t" @@ -8874,7 +9555,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/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_semaphore *sem) */ static inline void rwsem_atomic_add(long delta, struct rw_semaphore *sem) { @@ -8891,7 +9572,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/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 = delta; @@ -8908,9 +9589,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/rwsem.h linux-3.0.9/arch/x86/include : "+r" (tmp), "+m" (sem->count) : : "memory"); -diff -urNp linux-3.0.9/arch/x86/include/asm/segment.h linux-3.0.9/arch/x86/include/asm/segment.h ---- linux-3.0.9/arch/x86/include/asm/segment.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/segment.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/segment.h b/arch/x86/include/asm/segment.h +index cd84f72..d909986 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 ] @@ -8977,10 +9659,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/segment.h linux-3.0.9/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.0.9/arch/x86/include/asm/smp.h linux-3.0.9/arch/x86/include/asm/smp.h ---- linux-3.0.9/arch/x86/include/asm/smp.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/smp.h 2011-11-12 12:47:13.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); @@ -8998,7 +9681,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/smp.h linux-3.0.9/arch/x86/include/a /* 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); #elif defined(CONFIG_X86_64_SMP) @@ -9015,10 +9698,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/smp.h linux-3.0.9/arch/x86/include/a #define safe_smp_processor_id() smp_processor_id() #endif -diff -urNp linux-3.0.9/arch/x86/include/asm/spinlock.h linux-3.0.9/arch/x86/include/asm/spinlock.h ---- linux-3.0.9/arch/x86/include/asm/spinlock.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/spinlock.h 2011-11-12 12:47:13.000000000 -0500 -@@ -249,6 +249,14 @@ static inline int arch_write_can_lock(ar +diff --git a/arch/x86/include/asm/spinlock.h b/arch/x86/include/asm/spinlock.h +index 3089f70..db20eed 100644 +--- a/arch/x86/include/asm/spinlock.h ++++ b/arch/x86/include/asm/spinlock.h +@@ -249,6 +249,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 " subl $1,(%0)\n\t" @@ -9033,7 +9717,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/spinlock.h linux-3.0.9/arch/x86/incl "jns 1f\n" "call __read_lock_failed\n\t" "1:\n" -@@ -258,6 +266,14 @@ static inline void arch_read_lock(arch_r +@@ -258,6 +266,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 " subl %1,(%0)\n\t" @@ -9048,7 +9732,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/spinlock.h linux-3.0.9/arch/x86/incl "jz 1f\n" "call __write_lock_failed\n\t" "1:\n" -@@ -286,12 +302,29 @@ static inline int arch_write_trylock(arc +@@ -286,12 +302,29 @@ static inline int arch_write_trylock(arch_rwlock_t *lock) static inline void arch_read_unlock(arch_rwlock_t *rw) { @@ -9080,9 +9764,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/spinlock.h linux-3.0.9/arch/x86/incl : "+m" (rw->lock) : "i" (RW_LOCK_BIAS) : "memory"); } -diff -urNp linux-3.0.9/arch/x86/include/asm/stackprotector.h linux-3.0.9/arch/x86/include/asm/stackprotector.h ---- linux-3.0.9/arch/x86/include/asm/stackprotector.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/stackprotector.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/stackprotector.h b/arch/x86/include/asm/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. */ @@ -9092,7 +9777,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/stackprotector.h linux-3.0.9/arch/x8 /* * 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 cpu) static inline void load_stack_canary_segment(void) { @@ -9101,9 +9786,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/stackprotector.h linux-3.0.9/arch/x8 asm volatile ("mov %0, %%gs" : : "r" (0)); #endif } -diff -urNp linux-3.0.9/arch/x86/include/asm/stacktrace.h linux-3.0.9/arch/x86/include/asm/stacktrace.h ---- linux-3.0.9/arch/x86/include/asm/stacktrace.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/stacktrace.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/stacktrace.h b/arch/x86/include/asm/stacktrace.h +index 70bbe39..4ae2bd4 100644 +--- a/arch/x86/include/asm/stacktrace.h ++++ b/arch/x86/include/asm/stacktrace.h @@ -11,28 +11,20 @@ extern int kstack_depth_to_print; @@ -9154,10 +9840,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/stacktrace.h linux-3.0.9/arch/x86/in }; void dump_trace(struct task_struct *tsk, struct pt_regs *regs, -diff -urNp linux-3.0.9/arch/x86/include/asm/sys_ia32.h linux-3.0.9/arch/x86/include/asm/sys_ia32.h ---- linux-3.0.9/arch/x86/include/asm/sys_ia32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/sys_ia32.h 2011-11-12 12:47:13.000000000 -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_sigset_t __user *, compat_sigset_t __user *, unsigned int); asmlinkage long sys32_alarm(unsigned int); @@ -9166,9 +9853,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/sys_ia32.h linux-3.0.9/arch/x86/incl asmlinkage long sys32_sysfs(int, u32, u32); asmlinkage long sys32_sched_rr_get_interval(compat_pid_t, -diff -urNp linux-3.0.9/arch/x86/include/asm/system.h linux-3.0.9/arch/x86/include/asm/system.h ---- linux-3.0.9/arch/x86/include/asm/system.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/system.h 2011-11-12 12:47:13.000000000 -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" \ @@ -9187,7 +9875,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/system.h linux-3.0.9/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" : "=r" (__limit) : "r" (segment)); @@ -9211,9 +9899,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/system.h linux-3.0.9/arch/x86/includ /* * Force strict CPU ordering. -diff -urNp linux-3.0.9/arch/x86/include/asm/thread_info.h linux-3.0.9/arch/x86/include/asm/thread_info.h ---- linux-3.0.9/arch/x86/include/asm/thread_info.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/thread_info.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/thread_info.h b/arch/x86/include/asm/thread_info.h +index 1f2e61e..05e6f1e 100644 +--- a/arch/x86/include/asm/thread_info.h ++++ b/arch/x86/include/asm/thread_info.h @@ -10,6 +10,7 @@ #include <linux/compiler.h> #include <asm/page.h> @@ -9320,7 +10009,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/thread_info.h linux-3.0.9/arch/x86/i /* * macros/functions for gaining access to the thread information structure * preempt_count needs to be 1 initially, until the scheduler is functional. -@@ -216,21 +205,8 @@ static inline struct thread_info *curren +@@ -216,21 +205,8 @@ static inline struct thread_info *current_thread_info(void) #ifndef __ASSEMBLY__ DECLARE_PER_CPU(unsigned long, kernel_stack); @@ -9361,10 +10050,234 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/thread_info.h linux-3.0.9/arch/x86/i + #endif #endif /* _ASM_X86_THREAD_INFO_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_32.h linux-3.0.9/arch/x86/include/asm/uaccess_32.h ---- linux-3.0.9/arch/x86/include/asm/uaccess_32.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/uaccess_32.h 2011-11-12 12:47:13.000000000 -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/uaccess.h +index 99ddd14..e31427c 100644 +--- a/arch/x86/include/asm/uaccess.h ++++ b/arch/x86/include/asm/uaccess.h +@@ -7,12 +7,15 @@ + #include <linux/compiler.h> + #include <linux/thread_info.h> + #include <linux/string.h> ++#include <linux/sched.h> + #include <asm/asm.h> + #include <asm/page.h> + + #define VERIFY_READ 0 + #define VERIFY_WRITE 1 + ++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() == USER_DS, checking is performed, with +@@ -28,7 +31,12 @@ + + #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 = (x)) ++#endif + + #define segment_eq(a, b) ((a).seg == (b).seg) + +@@ -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) == 0)) ++#define __access_ok(type, addr, size) (likely(__range_not_ok(addr, size) == 0)) ++#define access_ok(type, addr, size) \ ++({ \ ++ long __size = size; \ ++ unsigned long __addr = (unsigned long)addr; \ ++ unsigned long __addr_ao = __addr & PAGE_MASK; \ ++ unsigned long __end_ao = __addr + __size - 1; \ ++ bool __ret_ao = __range_not_ok(__addr, __size) == 0; \ ++ if (__ret_ao && unlikely((__end_ao ^ __addr_ao) & PAGE_MASK)) { \ ++ while(__addr_ao <= __end_ao) { \ ++ char __c_ao; \ ++ __addr_ao += PAGE_SIZE; \ ++ if (__size > PAGE_SIZE) \ ++ cond_resched(); \ ++ if (__get_user(__c_ao, (char __user *)__addr)) \ ++ break; \ ++ if (type != VERIFY_WRITE) { \ ++ __addr = __addr_ao; \ ++ continue; \ ++ } \ ++ if (__put_user(__c_ao, (char __user *)__addr)) \ ++ break; \ ++ __addr = __addr_ao; \ ++ } \ ++ } \ ++ __ret_ao; \ ++}) + + /* + * 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 : "=a" (__ret_pu) \ + : "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx") + +- ++#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 + + #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)) + + #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 = x; \ ++ __pu_val = (x); \ + switch (sizeof(*(ptr))) { \ + case 1: \ + __put_user_x(1, __pu_val, ptr, __ret_pu); \ +@@ -373,7 +415,7 @@ do { \ + } while (0) + + #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) \ +- : "=r" (err), ltype(x) \ ++ : "=r" (err), ltype (x) \ + : "m" (__m(addr)), "i" (errret), "0" (err)) + + #define __get_user_size_ex(x, ptr, size) \ +@@ -406,7 +448,7 @@ do { \ + } while (0) + + #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) = (__force __typeof__(*(ptr)))__gu_val; \ ++ (x) = (__typeof__(*(ptr)))__gu_val; \ + __gu_err; \ + }) + + /* 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 = (unsigned long)(x); \ ++ if (____x < PAX_USER_SHADOW_BASE) \ ++ ____x += PAX_USER_SHADOW_BASE; \ ++ (void __user *)____x; \ ++}) ++#else ++#define ____m(x) (x) ++#endif ++#define __m(x) (*(struct __large_struct __user *)____m(x)) + + /* + * 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) \ + : "=r"(err) \ +- : ltype(x), "m" (__m(addr)), "i" (errret), "0" (err)) ++ : ltype (x), "m" (__m(addr)), "i" (errret), "0" (err)) + + #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. + */ + ++#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 + + /** + * __put_user: - Write a simple value into user space, with less checking. +@@ -510,8 +567,12 @@ struct __large_struct { unsigned long buf[100]; }; + * Returns zero on success, or -EFAULT on error. + */ + ++#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 + + #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) = (__force __typeof__(*(ptr)))__gue_val; \ ++ (x) = (__typeof__(*(ptr)))__gue_val; \ + } while (0) + + #ifdef CONFIG_X86_WP_WORKS_OK +diff --git a/arch/x86/include/asm/uaccess_32.h b/arch/x86/include/asm/uaccess_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_nocache_nozero static __always_inline unsigned long __must_check __copy_to_user_inatomic(void __user *to, const void *from, unsigned long n) { @@ -9376,7 +10289,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_32.h linux-3.0.9/arch/x86/in if (__builtin_constant_p(n)) { unsigned long ret; -@@ -61,6 +66,8 @@ __copy_to_user_inatomic(void __user *to, +@@ -61,6 +66,8 @@ __copy_to_user_inatomic(void __user *to, const void *from, unsigned long n) return ret; } } @@ -9385,7 +10298,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_32.h linux-3.0.9/arch/x86/in return __copy_to_user_ll(to, from, n); } -@@ -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(); @@ -9415,7 +10328,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_32.h linux-3.0.9/arch/x86/in if (__builtin_constant_p(n)) { unsigned long ret; -@@ -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; } } @@ -9424,7 +10337,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_32.h linux-3.0.9/arch/x86/in return __copy_from_user_ll(to, from, n); } -@@ -159,6 +178,10 @@ static __always_inline unsigned long __c +@@ -159,6 +178,10 @@ static __always_inline unsigned long __copy_from_user_nocache(void *to, const void __user *from, unsigned long n) { might_fault(); @@ -9462,7 +10375,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_32.h linux-3.0.9/arch/x86/in 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 ; @@ -9531,9 +10444,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_32.h linux-3.0.9/arch/x86/in return n; } -diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/include/asm/uaccess_64.h ---- linux-3.0.9/arch/x86/include/asm/uaccess_64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/uaccess_64.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/include/asm/uaccess_64.h b/arch/x86/include/asm/uaccess_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 <asm/alternative.h> #include <asm/cpufeature.h> @@ -9544,7 +10458,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in /* * 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, unsigned len) return ret; } @@ -9584,7 +10498,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in return n; } -@@ -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(); @@ -9816,7 +10730,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in ret, "b", "b", "=q", 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 __user *src, unsigned size) } case 2: { u16 tmp; @@ -9825,7 +10739,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in ret, "w", "w", "=r", 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 __user *src, unsigned size) case 4: { u32 tmp; @@ -9834,7 +10748,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in ret, "l", "k", "=r", 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 __user *src, unsigned size) } case 8: { u64 tmp; @@ -9843,7 +10757,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in ret, "q", "", "=r", 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 __user *src, unsigned size) return ret; } default: @@ -9862,7 +10776,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in } } -@@ -221,33 +320,72 @@ __must_check unsigned long __clear_user( +@@ -221,33 +320,72 @@ __must_check unsigned long __clear_user(void __user *mem, unsigned long len); static __must_check __always_inline int __copy_from_user_inatomic(void *dst, const void __user *src, unsigned size) { @@ -9945,231 +10859,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess_64.h linux-3.0.9/arch/x86/in +copy_user_handle_tail(char __user *to, char __user *from, unsigned len, unsigned zerorest); #endif /* _ASM_X86_UACCESS_64_H */ -diff -urNp linux-3.0.9/arch/x86/include/asm/uaccess.h linux-3.0.9/arch/x86/include/asm/uaccess.h ---- linux-3.0.9/arch/x86/include/asm/uaccess.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/uaccess.h 2011-11-12 12:47:13.000000000 -0500 -@@ -7,12 +7,15 @@ - #include <linux/compiler.h> - #include <linux/thread_info.h> - #include <linux/string.h> -+#include <linux/sched.h> - #include <asm/asm.h> - #include <asm/page.h> - - #define VERIFY_READ 0 - #define VERIFY_WRITE 1 - -+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() == USER_DS, checking is performed, with -@@ -28,7 +31,12 @@ - - #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 = (x)) -+#endif - - #define segment_eq(a, b) ((a).seg == (b).seg) - -@@ -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) == 0)) -+#define __access_ok(type, addr, size) (likely(__range_not_ok(addr, size) == 0)) -+#define access_ok(type, addr, size) \ -+({ \ -+ long __size = size; \ -+ unsigned long __addr = (unsigned long)addr; \ -+ unsigned long __addr_ao = __addr & PAGE_MASK; \ -+ unsigned long __end_ao = __addr + __size - 1; \ -+ bool __ret_ao = __range_not_ok(__addr, __size) == 0; \ -+ if (__ret_ao && unlikely((__end_ao ^ __addr_ao) & PAGE_MASK)) { \ -+ while(__addr_ao <= __end_ao) { \ -+ char __c_ao; \ -+ __addr_ao += PAGE_SIZE; \ -+ if (__size > PAGE_SIZE) \ -+ cond_resched(); \ -+ if (__get_user(__c_ao, (char __user *)__addr)) \ -+ break; \ -+ if (type != VERIFY_WRITE) { \ -+ __addr = __addr_ao; \ -+ continue; \ -+ } \ -+ if (__put_user(__c_ao, (char __user *)__addr)) \ -+ break; \ -+ __addr = __addr_ao; \ -+ } \ -+ } \ -+ __ret_ao; \ -+}) - - /* - * 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 : "=a" (__ret_pu) \ - : "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx") - -- -+#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 - - #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)) - - #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 = x; \ -+ __pu_val = (x); \ - switch (sizeof(*(ptr))) { \ - case 1: \ - __put_user_x(1, __pu_val, ptr, __ret_pu); \ -@@ -373,7 +415,7 @@ do { \ - } while (0) - - #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) \ -- : "=r" (err), ltype(x) \ -+ : "=r" (err), ltype (x) \ - : "m" (__m(addr)), "i" (errret), "0" (err)) - - #define __get_user_size_ex(x, ptr, size) \ -@@ -406,7 +448,7 @@ do { \ - } while (0) - - #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) = (__force __typeof__(*(ptr)))__gu_val; \ -+ (x) = (__typeof__(*(ptr)))__gu_val; \ - __gu_err; \ - }) - - /* 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 = (unsigned long)(x); \ -+ if (____x < PAX_USER_SHADOW_BASE) \ -+ ____x += PAX_USER_SHADOW_BASE; \ -+ (void __user *)____x; \ -+}) -+#else -+#define ____m(x) (x) -+#endif -+#define __m(x) (*(struct __large_struct __user *)____m(x)) - - /* - * 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) \ - : "=r"(err) \ -- : ltype(x), "m" (__m(addr)), "i" (errret), "0" (err)) -+ : ltype (x), "m" (__m(addr)), "i" (errret), "0" (err)) - - #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. - */ - -+#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 - - /** - * __put_user: - Write a simple value into user space, with less checking. -@@ -510,8 +567,12 @@ struct __large_struct { unsigned long bu - * Returns zero on success, or -EFAULT on error. - */ - -+#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 - - #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) = (__force __typeof__(*(ptr)))__gue_val; \ -+ (x) = (__typeof__(*(ptr)))__gue_val; \ - } while (0) - - #ifdef CONFIG_X86_WP_WORKS_OK -diff -urNp linux-3.0.9/arch/x86/include/asm/vdso.h linux-3.0.9/arch/x86/include/asm/vdso.h ---- linux-3.0.9/arch/x86/include/asm/vdso.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/vdso.h 2011-11-12 12:47:13.000000000 -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) \ ({ \ @@ -10179,9 +10872,10 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/vdso.h linux-3.0.9/arch/x86/include/ }) #endif -diff -urNp linux-3.0.9/arch/x86/include/asm/x86_init.h linux-3.0.9/arch/x86/include/asm/x86_init.h ---- linux-3.0.9/arch/x86/include/asm/x86_init.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/x86_init.h 2011-11-12 12:47:13.000000000 -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); @@ -10299,10 +10993,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/x86_init.h linux-3.0.9/arch/x86/incl extern struct x86_init_ops x86_init; extern struct x86_cpuinit_ops x86_cpuinit; -diff -urNp linux-3.0.9/arch/x86/include/asm/xsave.h linux-3.0.9/arch/x86/include/asm/xsave.h ---- linux-3.0.9/arch/x86/include/asm/xsave.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/include/asm/xsave.h 2011-11-12 12:47:13.000000000 -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 __user *buf) { int err; @@ -10314,7 +11009,7 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/xsave.h linux-3.0.9/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 mask) { int err; @@ -10331,136 +11026,11 @@ diff -urNp linux-3.0.9/arch/x86/include/asm/xsave.h linux-3.0.9/arch/x86/include __asm__ __volatile__("1: .byte " REX_PREFIX "0x0f,0xae,0x2f\n" "2:\n" ".section .fixup,\"ax\"\n" -diff -urNp linux-3.0.9/arch/x86/Kconfig linux-3.0.9/arch/x86/Kconfig ---- linux-3.0.9/arch/x86/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/Kconfig 2011-11-12 12:47:13.000000000 -0500 -@@ -229,7 +229,7 @@ config X86_HT - - config X86_32_LAZY_GS - def_bool y -- depends on X86_32 && !CC_STACKPROTECTOR -+ depends on X86_32 && !CC_STACKPROTECTOR && !PAX_MEMORY_UDEREF - - config ARCH_HWEIGHT_CFLAGS - string -@@ -1018,7 +1018,7 @@ choice - - 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 -@@ -1055,7 +1055,7 @@ config NOHIGHMEM - - 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. -@@ -1109,7 +1109,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 -@@ -1483,6 +1483,7 @@ config SECCOMP - - 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 -@@ -1540,6 +1541,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. - -@@ -1603,6 +1605,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 -@@ -1634,9 +1637,10 @@ config HOTPLUG_CPU - Say N if you want to disable CPU hotplug. - - 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. - -diff -urNp linux-3.0.9/arch/x86/Kconfig.cpu linux-3.0.9/arch/x86/Kconfig.cpu ---- linux-3.0.9/arch/x86/Kconfig.cpu 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/Kconfig.cpu 2011-11-12 12:47:13.000000000 -0500 -@@ -338,7 +338,7 @@ config X86_PPRO_FENCE - - config X86_F00F_BUG - def_bool y -- depends on M586MMX || M586TSC || M586 || M486 || M386 -+ depends on (M586MMX || M586TSC || M586 || M486 || M386) && !PAX_KERNEXEC - - config X86_INVD_BUG - def_bool y -@@ -362,7 +362,7 @@ config X86_POPAD_OK - - config X86_ALIGNMENT_16 - def_bool y -- depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MELAN || 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 - - config X86_INTEL_USERCOPY - def_bool y -@@ -408,7 +408,7 @@ config X86_CMPXCHG64 - # generates cmov. - config X86_CMOV - def_bool y -- depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || 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 || MEFFICEON || X86_64 || MATOM || MGEODE_LX) - - config X86_MINIMUM_CPU_FAMILY - int -diff -urNp linux-3.0.9/arch/x86/Kconfig.debug linux-3.0.9/arch/x86/Kconfig.debug ---- linux-3.0.9/arch/x86/Kconfig.debug 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/Kconfig.debug 2011-11-12 12:47:13.000000000 -0500 -@@ -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 - - 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.0.9/arch/x86/kernel/acpi/realmode/Makefile linux-3.0.9/arch/x86/kernel/acpi/realmode/Makefile ---- linux-3.0.9/arch/x86/kernel/acpi/realmode/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/acpi/realmode/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -41,6 +41,9 @@ KBUILD_CFLAGS := $(LINUXINCLUDE) -g -Os +diff --git a/arch/x86/kernel/acpi/realmode/Makefile b/arch/x86/kernel/acpi/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 := $(LINUXINCLUDE) -g -Os -D_SETUP -D_WAKEUP -D__KERNEL__ \ $(call cc-option, -fno-stack-protector) \ $(call cc-option, -mpreferred-stack-boundary=2) KBUILD_CFLAGS += $(call cc-option, -m32) @@ -10470,9 +11040,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/acpi/realmode/Makefile linux-3.0.9/arch/x KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ GCOV_PROFILE := n -diff -urNp linux-3.0.9/arch/x86/kernel/acpi/realmode/wakeup.S linux-3.0.9/arch/x86/kernel/acpi/realmode/wakeup.S ---- linux-3.0.9/arch/x86/kernel/acpi/realmode/wakeup.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/acpi/realmode/wakeup.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/acpi/realmode/wakeup.S b/arch/x86/kernel/acpi/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... */ @@ -10491,9 +11062,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/acpi/realmode/wakeup.S linux-3.0.9/arch/x #else pushw $0 pushw trampoline_segment -diff -urNp linux-3.0.9/arch/x86/kernel/acpi/sleep.c linux-3.0.9/arch/x86/kernel/acpi/sleep.c ---- linux-3.0.9/arch/x86/kernel/acpi/sleep.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/acpi/sleep.c 2011-11-12 12:47:13.000000000 -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 = trampoline_address() >> 4; #ifdef CONFIG_SMP @@ -10507,9 +11079,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/acpi/sleep.c linux-3.0.9/arch/x86/kernel/ initial_gs = per_cpu_offset(smp_processor_id()); #endif initial_code = (unsigned long)wakeup_long64; -diff -urNp linux-3.0.9/arch/x86/kernel/acpi/wakeup_32.S linux-3.0.9/arch/x86/kernel/acpi/wakeup_32.S ---- linux-3.0.9/arch/x86/kernel/acpi/wakeup_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/acpi/wakeup_32.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/acpi/wakeup_32.S b/arch/x86/kernel/acpi/wakeup_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 @@ -10526,10 +11099,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/acpi/wakeup_32.S linux-3.0.9/arch/x86/ker bogus_magic: jmp bogus_magic -diff -urNp linux-3.0.9/arch/x86/kernel/alternative.c linux-3.0.9/arch/x86/kernel/alternative.c ---- linux-3.0.9/arch/x86/kernel/alternative.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/alternative.c 2011-11-12 12:47:13.000000000 -0500 -@@ -313,7 +313,7 @@ static void alternatives_smp_lock(const +diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative.c +index a81f2d5..f6c90fb 100644 +--- a/arch/x86/kernel/alternative.c ++++ b/arch/x86/kernel/alternative.c +@@ -313,7 +313,7 @@ static void alternatives_smp_lock(const s32 *start, const s32 *end, if (!*poff || ptr < text || ptr >= text_end) continue; /* turn DS segment override prefix into lock prefix */ @@ -10538,7 +11112,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/alternative.c linux-3.0.9/arch/x86/kernel text_poke(ptr, ((unsigned char []){0xf0}), 1); }; mutex_unlock(&text_mutex); -@@ -334,7 +334,7 @@ static void alternatives_smp_unlock(cons +@@ -334,7 +334,7 @@ static void alternatives_smp_unlock(const s32 *start, const s32 *end, if (!*poff || ptr < text || ptr >= text_end) continue; /* turn lock prefix into DS segment override prefix */ @@ -10547,7 +11121,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/alternative.c linux-3.0.9/arch/x86/kernel text_poke(ptr, ((unsigned char []){0x3E}), 1); }; mutex_unlock(&text_mutex); -@@ -503,7 +503,7 @@ void __init_or_module apply_paravirt(str +@@ -503,7 +503,7 @@ void __init_or_module apply_paravirt(struct paravirt_patch_site *start, BUG_ON(p->len > MAX_PATCH_LEN); /* prep the buffer with the original instructions */ @@ -10556,7 +11130,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/alternative.c linux-3.0.9/arch/x86/kernel used = pv_init_ops.patch(p->instrtype, p->clobbers, insnbuf, (unsigned long)p->instr, p->len); -@@ -571,7 +571,7 @@ void __init alternative_instructions(voi +@@ -571,7 +571,7 @@ void __init alternative_instructions(void) if (smp_alt_once) free_init_pages("SMP alternatives", (unsigned long)__smp_locks, @@ -10565,7 +11139,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/alternative.c linux-3.0.9/arch/x86/kernel restart_nmi(); } -@@ -588,13 +588,17 @@ void __init alternative_instructions(voi +@@ -588,13 +588,17 @@ void __init alternative_instructions(void) * instructions. And on the local CPU you need to be protected again NMI or MCE * handlers seeing an inconsistent instruction while you patch. */ @@ -10585,7 +11159,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/alternative.c linux-3.0.9/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. */ -@@ -616,36 +620,22 @@ void *__init_or_module text_poke_early(v +@@ -616,36 +620,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) { @@ -10630,9 +11204,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/alternative.c linux-3.0.9/arch/x86/kernel return addr; } -diff -urNp linux-3.0.9/arch/x86/kernel/apic/apic.c linux-3.0.9/arch/x86/kernel/apic/apic.c ---- linux-3.0.9/arch/x86/kernel/apic/apic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/apic/apic.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c +index b9338b8..0df3f9d 100644 +--- a/arch/x86/kernel/apic/apic.c ++++ b/arch/x86/kernel/apic/apic.c @@ -173,7 +173,7 @@ int first_system_vector = 0xfe; /* * Debug level, exported for io_apic.c @@ -10642,7 +11217,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apic/apic.c linux-3.0.9/arch/x86/kernel/a int pic_mode; -@@ -1834,7 +1834,7 @@ void smp_error_interrupt(struct pt_regs +@@ -1834,7 +1834,7 @@ void smp_error_interrupt(struct pt_regs *regs) apic_write(APIC_ESR, 0); v1 = apic_read(APIC_ESR); ack_APIC_irq(); @@ -10651,7 +11226,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apic/apic.c linux-3.0.9/arch/x86/kernel/a apic_printk(APIC_DEBUG, KERN_DEBUG "APIC error on CPU%d: %02x(%02x)", smp_processor_id(), v0 , v1); -@@ -2190,6 +2190,8 @@ static int __cpuinit apic_cluster_num(vo +@@ -2190,6 +2190,8 @@ static int __cpuinit apic_cluster_num(void) u16 *bios_cpu_apicid; DECLARE_BITMAP(clustermap, NUM_APIC_CLUSTERS); @@ -10660,10 +11235,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apic/apic.c linux-3.0.9/arch/x86/kernel/a bios_cpu_apicid = early_per_cpu_ptr(x86_bios_cpu_apicid); bitmap_zero(clustermap, NUM_APIC_CLUSTERS); -diff -urNp linux-3.0.9/arch/x86/kernel/apic/io_apic.c linux-3.0.9/arch/x86/kernel/apic/io_apic.c ---- linux-3.0.9/arch/x86/kernel/apic/io_apic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/apic/io_apic.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1028,7 +1028,7 @@ int IO_APIC_get_PCI_irq_vector(int bus, +diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c +index e529339..2457731 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); @@ -10681,7 +11257,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apic/io_apic.c linux-3.0.9/arch/x86/kerne { raw_spin_unlock(&vector_lock); } -@@ -2364,7 +2364,7 @@ static void ack_apic_edge(struct irq_dat +@@ -2364,7 +2364,7 @@ static void ack_apic_edge(struct irq_data *data) ack_APIC_irq(); } @@ -10690,7 +11266,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apic/io_apic.c linux-3.0.9/arch/x86/kerne /* * IO-APIC versions below 0x20 don't support EOI register. -@@ -2472,7 +2472,7 @@ static void ack_apic_level(struct irq_da +@@ -2472,7 +2472,7 @@ static void ack_apic_level(struct irq_data *data) * at the cpu. */ if (!(v & (1 << (i & 0x1f)))) { @@ -10699,9 +11275,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apic/io_apic.c linux-3.0.9/arch/x86/kerne eoi_ioapic_irq(irq, cfg); } -diff -urNp linux-3.0.9/arch/x86/kernel/apm_32.c linux-3.0.9/arch/x86/kernel/apm_32.c ---- linux-3.0.9/arch/x86/kernel/apm_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/apm_32.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/apm_32.c b/arch/x86/kernel/apm_32.c +index 965a766..3b2cc55 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. @@ -10734,7 +11311,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apm_32.c linux-3.0.9/arch/x86/kernel/apm_ put_cpu(); return call->eax & 0xff; -@@ -667,7 +674,10 @@ static long __apm_bios_call_simple(void +@@ -667,7 +674,10 @@ static long __apm_bios_call_simple(void *_call) BUG_ON(cpu != 0); gdt = get_cpu_gdt_table(cpu); save_desc_40 = gdt[0x40 / 8]; @@ -10745,7 +11322,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apm_32.c linux-3.0.9/arch/x86/kernel/apm_ apm_irq_save(flags); APM_DO_SAVE_SEGS; -@@ -675,7 +685,11 @@ static long __apm_bios_call_simple(void +@@ -675,7 +685,11 @@ static long __apm_bios_call_simple(void *_call) &call->eax); APM_DO_RESTORE_SEGS; apm_irq_restore(flags); @@ -10773,20 +11350,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/apm_32.c linux-3.0.9/arch/x86/kernel/apm_ proc_create("apm", 0, NULL, &apm_file_ops); -diff -urNp linux-3.0.9/arch/x86/kernel/asm-offsets_64.c linux-3.0.9/arch/x86/kernel/asm-offsets_64.c ---- linux-3.0.9/arch/x86/kernel/asm-offsets_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/asm-offsets_64.c 2011-11-12 12:47:13.000000000 -0500 -@@ -69,6 +69,7 @@ int main(void) - BLANK(); - #undef ENTRY - -+ DEFINE(TSS_size, sizeof(struct tss_struct)); - OFFSET(TSS_ist, tss_struct, x86_tss.ist); - BLANK(); - -diff -urNp linux-3.0.9/arch/x86/kernel/asm-offsets.c linux-3.0.9/arch/x86/kernel/asm-offsets.c ---- linux-3.0.9/arch/x86/kernel/asm-offsets.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/asm-offsets.c 2011-11-12 12:47:13.000000000 -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); @@ -10823,10 +11390,38 @@ diff -urNp linux-3.0.9/arch/x86/kernel/asm-offsets.c linux-3.0.9/arch/x86/kernel #ifdef CONFIG_XEN BLANK(); OFFSET(XEN_vcpu_info_mask, vcpu_info, evtchn_upcall_mask); -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/amd.c linux-3.0.9/arch/x86/kernel/cpu/amd.c ---- linux-3.0.9/arch/x86/kernel/cpu/amd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/amd.c 2011-11-12 12:47:13.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-offsets_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 + ++ DEFINE(TSS_size, sizeof(struct tss_struct)); + OFFSET(TSS_ist, tss_struct, x86_tss.ist); + BLANK(); + +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 = -pg + CFLAGS_REMOVE_perf_event.o = -pg + endif + +-# Make sure load_percpu_segment has no stackprotector +-nostackp := $(call cc-option, -fno-stack-protector) +-CFLAGS_common.o := $(nostackp) +- + obj-y := intel_cacheinfo.o scattered.o topology.o + obj-y += proc.o capflags.o powerflags.o common.o + obj-y += 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) */ @@ -10835,10 +11430,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/amd.c linux-3.0.9/arch/x86/kernel/cpu /* Duron Rev A0 */ if (c->x86_model == 3 && c->x86_mask == 0) size = 64; -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/common.c linux-3.0.9/arch/x86/kernel/cpu/common.c ---- linux-3.0.9/arch/x86/kernel/cpu/common.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/common.c 2011-11-12 12:47:13.000000000 -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 22a073d..bfb3195 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_cpu = { static const struct cpu_dev *this_cpu __cpuinitdata = &default_cpu; @@ -10908,7 +11504,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/common.c linux-3.0.9/arch/x86/kernel/ gdt_descr.size = 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_x86 *c) /* Filter out anything that depends on CPUID levels we don't have */ filter_cpuid_features(c, true); @@ -10919,7 +11515,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/common.c linux-3.0.9/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=", setup_disablecpuid); @@ -10929,7 +11525,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/common.c linux-3.0.9/arch/x86/kernel/ #ifdef CONFIG_X86_64 struct desc_ptr idt_descr = { NR_VECTORS * 16 - 1, (unsigned long) idt_table }; -@@ -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 = EXPORT_PER_CPU_SYMBOL(current_task); DEFINE_PER_CPU(unsigned long, kernel_stack) = @@ -10938,7 +11534,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/common.c linux-3.0.9/arch/x86/kernel/ EXPORT_PER_CPU_SYMBOL(kernel_stack); DEFINE_PER_CPU(char *, irq_stack_ptr) = -@@ -1099,7 +1052,7 @@ struct pt_regs * __cpuinit idle_regs(str +@@ -1099,7 +1052,7 @@ struct pt_regs * __cpuinit idle_regs(struct pt_regs *regs) { memset(regs, 0, sizeof(struct pt_regs)); regs->fs = __KERNEL_PERCPU; @@ -10982,10 +11578,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/common.c linux-3.0.9/arch/x86/kernel/ struct thread_struct *thread = &curr->thread; if (cpumask_test_and_set_cpu(cpu, cpu_initialized_mask)) { -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/intel.c linux-3.0.9/arch/x86/kernel/cpu/intel.c ---- linux-3.0.9/arch/x86/kernel/cpu/intel.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/intel.c 2011-11-12 12:47:13.000000000 -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. */ @@ -10994,23 +11591,25 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/intel.c linux-3.0.9/arch/x86/kernel/c load_idt(&idt_descr); } #endif -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/Makefile linux-3.0.9/arch/x86/kernel/cpu/Makefile ---- linux-3.0.9/arch/x86/kernel/cpu/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -8,10 +8,6 @@ CFLAGS_REMOVE_common.o = -pg - CFLAGS_REMOVE_perf_event.o = -pg - endif - --# Make sure load_percpu_segment has no stackprotector --nostackp := $(call cc-option, -fno-stack-protector) --CFLAGS_common.o := $(nostackp) -- - obj-y := intel_cacheinfo.o scattered.o topology.o - obj-y += proc.o capflags.o powerflags.o common.o - obj-y += vmware.o hypervisor.o sched.o mshyperv.o -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c ---- linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/cpu/mcheck/mce-inject.c b/arch/x86/kernel/cpu/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 = mce_write; ++ pax_open_kernel(); ++ *(void **)&mce_chrdev_ops.write = 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/mcheck/mce.c +index ff1ae9b..f2d105b 100644 +--- a/arch/x86/kernel/cpu/mcheck/mce.c ++++ b/arch/x86/kernel/cpu/mcheck/mce.c @@ -46,6 +46,7 @@ #include <asm/ipi.h> #include <asm/mce.h> @@ -11041,7 +11640,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c linux-3.0.9/arch/x86/ker /* Panic in progress. Enable interrupts and wait for final IPI */ static void wait_for_panic(void) -@@ -263,7 +264,7 @@ static void mce_panic(char *msg, struct +@@ -263,7 +264,7 @@ static void mce_panic(char *msg, struct mce *final, char *exp) /* * Make sure only one CPU runs in machine check panic */ @@ -11050,7 +11649,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c linux-3.0.9/arch/x86/ker wait_for_panic(); barrier(); -@@ -271,7 +272,7 @@ static void mce_panic(char *msg, struct +@@ -271,7 +272,7 @@ static void mce_panic(char *msg, struct mce *final, char *exp) console_verbose(); } else { /* Don't log too much for fake panic */ @@ -11068,7 +11667,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c linux-3.0.9/arch/x86/ker wait_for_panic(); if (!monarch_timeout) goto out; -@@ -1452,14 +1453,14 @@ void __cpuinit mcheck_cpu_init(struct cp +@@ -1452,14 +1453,14 @@ void __cpuinit mcheck_cpu_init(struct cpuinfo_x86 *c) */ static DEFINE_SPINLOCK(mce_state_lock); @@ -11085,7 +11684,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c linux-3.0.9/arch/x86/ker spin_unlock(&mce_state_lock); return -EBUSY; -@@ -1467,7 +1468,7 @@ static int mce_open(struct inode *inode, +@@ -1467,7 +1468,7 @@ static int mce_open(struct inode *inode, struct file *file) if (file->f_flags & O_EXCL) open_exclu = 1; @@ -11094,7 +11693,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c linux-3.0.9/arch/x86/ker spin_unlock(&mce_state_lock); -@@ -1478,7 +1479,7 @@ static int mce_release(struct inode *ino +@@ -1478,7 +1479,7 @@ static int mce_release(struct inode *inode, struct file *file) { spin_lock(&mce_state_lock); @@ -11112,23 +11711,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce.c linux-3.0.9/arch/x86/ker atomic_set(&mce_executing, 0); atomic_set(&mce_callin, 0); atomic_set(&global_nwo, 0); -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce-inject.c linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce-inject.c ---- linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce-inject.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/mcheck/mce-inject.c 2011-11-12 12:47:13.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 = mce_write; -+ pax_open_kernel(); -+ *(void **)&mce_chrdev_ops.write = mce_write; -+ pax_close_kernel(); - register_die_notifier(&mce_raise_nb); - return 0; - } -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mtrr/main.c linux-3.0.9/arch/x86/kernel/cpu/mtrr/main.c ---- linux-3.0.9/arch/x86/kernel/cpu/mtrr/main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/mtrr/main.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/cpu/mtrr/main.c b/arch/x86/kernel/cpu/mtrr/main.c +index 3d17bc7..b106841 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; @@ -11138,9 +11724,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mtrr/main.c linux-3.0.9/arch/x86/kern const struct mtrr_ops *mtrr_if; -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mtrr/mtrr.h linux-3.0.9/arch/x86/kernel/cpu/mtrr/mtrr.h ---- linux-3.0.9/arch/x86/kernel/cpu/mtrr/mtrr.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/mtrr/mtrr.h 2011-11-12 12:47:13.000000000 -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); @@ -11150,10 +11737,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/mtrr/mtrr.h linux-3.0.9/arch/x86/kern extern int generic_get_free_region(unsigned long base, unsigned long size, int replace_reg); -diff -urNp linux-3.0.9/arch/x86/kernel/cpu/perf_event.c linux-3.0.9/arch/x86/kernel/cpu/perf_event.c ---- linux-3.0.9/arch/x86/kernel/cpu/perf_event.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/cpu/perf_event.c 2011-11-12 12:47:13.000000000 -0500 -@@ -781,6 +781,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 bf6d692..90ee554 100644 +--- a/arch/x86/kernel/cpu/perf_event.c ++++ b/arch/x86/kernel/cpu/perf_event.c +@@ -781,6 +781,8 @@ static int x86_schedule_events(struct cpu_hw_events *cpuc, int n, int *assign) int i, j, w, wmax, num = 0; struct hw_perf_event *hwc; @@ -11162,7 +11750,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/perf_event.c linux-3.0.9/arch/x86/ker bitmap_zero(used_mask, X86_PMC_IDX_MAX); for (i = 0; i < n; i++) { -@@ -1875,7 +1877,7 @@ perf_callchain_user(struct perf_callchai +@@ -1875,7 +1877,7 @@ perf_callchain_user(struct perf_callchain_entry *entry, struct pt_regs *regs) break; perf_callchain_store(entry, frame.return_address); @@ -11171,10 +11759,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/cpu/perf_event.c linux-3.0.9/arch/x86/ker } } -diff -urNp linux-3.0.9/arch/x86/kernel/crash.c linux-3.0.9/arch/x86/kernel/crash.c ---- linux-3.0.9/arch/x86/kernel/crash.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/crash.c 2011-11-12 12:47:13.000000000 -0500 -@@ -42,7 +42,7 @@ static void kdump_nmi_callback(int cpu, +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_args *args) regs = args->regs; #ifdef CONFIG_X86_32 @@ -11183,9 +11772,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/crash.c linux-3.0.9/arch/x86/kernel/crash crash_fixup_ss_esp(&fixed_regs, regs); regs = &fixed_regs; } -diff -urNp linux-3.0.9/arch/x86/kernel/doublefault_32.c linux-3.0.9/arch/x86/kernel/doublefault_32.c ---- linux-3.0.9/arch/x86/kernel/doublefault_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/doublefault_32.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/doublefault_32.c b/arch/x86/kernel/doublefault_32.c +index 37250fe..bf2ec74 100644 +--- a/arch/x86/kernel/doublefault_32.c ++++ b/arch/x86/kernel/doublefault_32.c @@ -11,7 +11,7 @@ #define DOUBLEFAULT_STACKSIZE (1024) @@ -11204,7 +11794,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/doublefault_32.c linux-3.0.9/arch/x86/ker printk(KERN_EMERG "PANIC: double fault, gdt at %08lx [%d bytes]\n", gdt, gdt_desc.size); -@@ -58,10 +58,10 @@ struct tss_struct doublefault_tss __cach +@@ -58,10 +58,10 @@ struct tss_struct doublefault_tss __cacheline_aligned = { /* 0x2 bit is always set */ .flags = X86_EFLAGS_SF | 0x2, .sp = STACK_START, @@ -11217,129 +11807,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/doublefault_32.c linux-3.0.9/arch/x86/ker .fs = __KERNEL_PERCPU, .__cr3 = __pa_nodebug(swapper_pg_dir), -diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack_32.c linux-3.0.9/arch/x86/kernel/dumpstack_32.c ---- linux-3.0.9/arch/x86/kernel/dumpstack_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/dumpstack_32.c 2011-11-12 12:47:13.000000000 -0500 -@@ -38,15 +38,13 @@ void dump_trace(struct task_struct *task - bp = stack_frame(task, regs); - - for (;;) { -- struct thread_info *context; -+ void *stack_start = (void *)((unsigned long)stack & ~(THREAD_SIZE-1)); - -- context = (struct thread_info *) -- ((unsigned long)stack & (~(THREAD_SIZE - 1))); -- bp = ops->walk_stack(context, stack, bp, ops, data, NULL, &graph); -+ bp = ops->walk_stack(task, stack_start, stack, bp, ops, data, NULL, &graph); - -- stack = (unsigned long *)context->previous_esp; -- if (!stack) -+ if (stack_start == task_stack_page(task)) - break; -+ stack = *(unsigned long **)stack_start; - if (ops->stack(data, "IRQ") < 0) - break; - touch_nmi_watchdog(); -@@ -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.. - */ -- if (!user_mode_vm(regs)) { -+ if (!user_mode(regs)) { - unsigned int code_prologue = code_bytes * 43 / 64; - unsigned int code_len = code_bytes; - unsigned char c; - u8 *ip; -+ unsigned long cs_base = get_desc_base(&get_cpu_gdt_table(smp_processor_id())[(0xffff & regs->cs) >> 3]); - - printk(KERN_EMERG "Stack:\n"); - show_stack_log_lvl(NULL, regs, ®s->sp, 0, KERN_EMERG); - - printk(KERN_EMERG "Code: "); - -- ip = (u8 *)regs->ip - code_prologue; -+ ip = (u8 *)regs->ip - code_prologue + cs_base; - if (ip < (u8 *)PAGE_OFFSET || probe_kernel_address(ip, c)) { - /* try starting at IP */ -- ip = (u8 *)regs->ip; -+ ip = (u8 *)regs->ip + cs_base; - code_len = code_len - code_prologue + 1; - } - for (i = 0; i < code_len; i++, ip++) { -@@ -119,7 +118,7 @@ void show_registers(struct pt_regs *regs - printk(" Bad EIP value."); - break; - } -- if (ip == (u8 *)regs->ip) -+ if (ip == (u8 *)regs->ip + cs_base) - printk("<%02x> ", c); - else - printk("%02x ", c); -@@ -132,6 +131,7 @@ int is_valid_bugaddr(unsigned long ip) - { - unsigned short ud2; - -+ ip = ktla_ktva(ip); - if (ip < PAGE_OFFSET) - return 0; - if (probe_kernel_address((unsigned short *)ip, ud2)) -diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack_64.c linux-3.0.9/arch/x86/kernel/dumpstack_64.c ---- linux-3.0.9/arch/x86/kernel/dumpstack_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/dumpstack_64.c 2011-11-12 12:47:13.000000000 -0500 -@@ -147,9 +147,9 @@ void dump_trace(struct task_struct *task - unsigned long *irq_stack_end = - (unsigned long *)per_cpu(irq_stack_ptr, cpu); - unsigned used = 0; -- struct thread_info *tinfo; - int graph = 0; - unsigned long dummy; -+ void *stack_start; - - if (!task) - task = current; -@@ -167,10 +167,10 @@ void dump_trace(struct task_struct *task - * current stack address. If the stacks consist of nested - * exceptions - */ -- tinfo = task_thread_info(task); - for (;;) { - char *id; - unsigned long *estack_end; -+ - estack_end = in_exception_stack(cpu, (unsigned long)stack, - &used, &id); - -@@ -178,7 +178,7 @@ void dump_trace(struct task_struct *task - if (ops->stack(data, id) < 0) - break; - -- bp = ops->walk_stack(tinfo, stack, bp, ops, -+ bp = ops->walk_stack(task, estack_end - EXCEPTION_STKSZ, stack, bp, ops, - data, estack_end, &graph); - ops->stack(data, "<EOE>"); - /* -@@ -197,7 +197,7 @@ void dump_trace(struct task_struct *task - if (in_irq_stack(stack, irq_stack, irq_stack_end)) { - if (ops->stack(data, "IRQ") < 0) - break; -- bp = ops->walk_stack(tinfo, stack, bp, -+ bp = ops->walk_stack(task, irq_stack, stack, bp, - ops, data, irq_stack_end, &graph); - /* - * We link to the next stack (which would be -@@ -218,7 +218,8 @@ void dump_trace(struct task_struct *task - /* - * This handles the process stack: - */ -- bp = ops->walk_stack(tinfo, stack, bp, ops, data, NULL, &graph); -+ stack_start = (void *)((unsigned long)stack & ~(THREAD_SIZE-1)); -+ bp = ops->walk_stack(task, stack_start, stack, bp, ops, data, NULL, &graph); - put_cpu(); - } - EXPORT_SYMBOL(dump_trace); -diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/dumpstack.c ---- linux-3.0.9/arch/x86/kernel/dumpstack.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/dumpstack.c 2011-11-12 12:47:13.000000000 -0500 +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 @@ -11350,7 +11821,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d #include <linux/kallsyms.h> #include <linux/kprobes.h> #include <linux/uaccess.h> -@@ -35,9 +38,8 @@ void printk_address(unsigned long addres +@@ -35,9 +38,8 @@ void printk_address(unsigned long address, int reliable) static void print_ftrace_graph_addr(unsigned long addr, void *data, const struct stacktrace_ops *ops, @@ -11361,7 +11832,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d unsigned long ret_addr; int index = task->curr_ret_stack; -@@ -58,7 +60,7 @@ print_ftrace_graph_addr(unsigned long ad +@@ -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, @@ -11370,7 +11841,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d { } #endif -@@ -69,10 +71,8 @@ print_ftrace_graph_addr(unsigned long ad +@@ -69,10 +71,8 @@ print_ftrace_graph_addr(unsigned long addr, void *data, * severe exception (double fault, nmi, stack fault, debug, mce) hardware stack */ @@ -11382,7 +11853,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d if (end) { if (p < end && p >= (end-THREAD_SIZE)) return 1; -@@ -83,14 +83,14 @@ static inline int valid_stack_ptr(struct +@@ -83,14 +83,14 @@ static inline int valid_stack_ptr(struct thread_info *tinfo, } unsigned long @@ -11399,7 +11870,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d unsigned long addr; addr = *stack; -@@ -102,7 +102,7 @@ print_context_stack(struct thread_info * +@@ -102,7 +102,7 @@ print_context_stack(struct thread_info *tinfo, } else { ops->address(data, addr, 0); } @@ -11408,7 +11879,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d } stack++; } -@@ -111,7 +111,7 @@ print_context_stack(struct thread_info * +@@ -111,7 +111,7 @@ print_context_stack(struct thread_info *tinfo, EXPORT_SYMBOL_GPL(print_context_stack); unsigned long @@ -11417,7 +11888,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d 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 +@@ -119,7 +119,7 @@ print_context_stack_bp(struct thread_info *tinfo, struct stack_frame *frame = (struct stack_frame *)bp; unsigned long *ret_addr = &frame->return_address; @@ -11426,7 +11897,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d unsigned long addr = *ret_addr; if (!__kernel_text_address(addr)) -@@ -128,7 +128,7 @@ print_context_stack_bp(struct thread_inf +@@ -128,7 +128,7 @@ print_context_stack_bp(struct thread_info *tinfo, ops->address(data, addr, 1); frame = frame->next_frame; ret_addr = &frame->return_address; @@ -11453,7 +11924,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d 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 +@@ -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"); @@ -11465,7 +11936,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d } int __kprobes __die(const char *str, struct pt_regs *regs, long err) -@@ -269,7 +274,7 @@ int __kprobes __die(const char *str, str +@@ -269,7 +274,7 @@ int __kprobes __die(const char *str, struct pt_regs *regs, long err) show_registers(regs); #ifdef CONFIG_X86_32 @@ -11474,7 +11945,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d sp = regs->sp; ss = regs->ss & 0xffff; } else { -@@ -297,7 +302,7 @@ void die(const char *str, struct pt_regs +@@ -297,7 +302,7 @@ void die(const char *str, struct pt_regs *regs, long err) unsigned long flags = oops_begin(); int sig = SIGSEGV; @@ -11483,9 +11954,132 @@ diff -urNp linux-3.0.9/arch/x86/kernel/dumpstack.c linux-3.0.9/arch/x86/kernel/d report_bug(regs->ip, regs); if (__die(str, regs, err)) -diff -urNp linux-3.0.9/arch/x86/kernel/early_printk.c linux-3.0.9/arch/x86/kernel/early_printk.c ---- linux-3.0.9/arch/x86/kernel/early_printk.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/early_printk.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/dumpstack_32.c b/arch/x86/kernel/dumpstack_32.c +index 3b97a80..2d7ebd5 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 = stack_frame(task, regs); + + for (;;) { +- struct thread_info *context; ++ void *stack_start = (void *)((unsigned long)stack & ~(THREAD_SIZE-1)); + +- context = (struct thread_info *) +- ((unsigned long)stack & (~(THREAD_SIZE - 1))); +- bp = ops->walk_stack(context, stack, bp, ops, data, NULL, &graph); ++ bp = ops->walk_stack(task, stack_start, stack, bp, ops, data, NULL, &graph); + +- stack = (unsigned long *)context->previous_esp; +- if (!stack) ++ if (stack_start == task_stack_page(task)) + break; ++ stack = *(unsigned long **)stack_start; + if (ops->stack(data, "IRQ") < 0) + break; + touch_nmi_watchdog(); +@@ -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.. + */ +- if (!user_mode_vm(regs)) { ++ if (!user_mode(regs)) { + unsigned int code_prologue = code_bytes * 43 / 64; + unsigned int code_len = code_bytes; + unsigned char c; + u8 *ip; ++ unsigned long cs_base = get_desc_base(&get_cpu_gdt_table(smp_processor_id())[(0xffff & regs->cs) >> 3]); + + printk(KERN_EMERG "Stack:\n"); + show_stack_log_lvl(NULL, regs, ®s->sp, 0, KERN_EMERG); + + printk(KERN_EMERG "Code: "); + +- ip = (u8 *)regs->ip - code_prologue; ++ ip = (u8 *)regs->ip - code_prologue + cs_base; + if (ip < (u8 *)PAGE_OFFSET || probe_kernel_address(ip, c)) { + /* try starting at IP */ +- ip = (u8 *)regs->ip; ++ ip = (u8 *)regs->ip + cs_base; + code_len = code_len - code_prologue + 1; + } + for (i = 0; i < code_len; i++, ip++) { +@@ -119,7 +118,7 @@ void show_registers(struct pt_regs *regs) + printk(" Bad EIP value."); + break; + } +- if (ip == (u8 *)regs->ip) ++ if (ip == (u8 *)regs->ip + cs_base) + printk("<%02x> ", c); + else + printk("%02x ", c); +@@ -132,6 +131,7 @@ int is_valid_bugaddr(unsigned long ip) + { + unsigned short ud2; + ++ ip = ktla_ktva(ip); + if (ip < PAGE_OFFSET) + return 0; + if (probe_kernel_address((unsigned short *)ip, ud2)) +diff --git a/arch/x86/kernel/dumpstack_64.c b/arch/x86/kernel/dumpstack_64.c +index e71c98d..8d00db8 100644 +--- a/arch/x86/kernel/dumpstack_64.c ++++ b/arch/x86/kernel/dumpstack_64.c +@@ -147,9 +147,9 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs, + unsigned long *irq_stack_end = + (unsigned long *)per_cpu(irq_stack_ptr, cpu); + unsigned used = 0; +- struct thread_info *tinfo; + int graph = 0; + unsigned long dummy; ++ void *stack_start; + + if (!task) + task = current; +@@ -167,10 +167,10 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs, + * current stack address. If the stacks consist of nested + * exceptions + */ +- tinfo = task_thread_info(task); + for (;;) { + char *id; + unsigned long *estack_end; ++ + estack_end = in_exception_stack(cpu, (unsigned long)stack, + &used, &id); + +@@ -178,7 +178,7 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs, + if (ops->stack(data, id) < 0) + break; + +- bp = ops->walk_stack(tinfo, stack, bp, ops, ++ bp = ops->walk_stack(task, estack_end - EXCEPTION_STKSZ, stack, bp, ops, + data, estack_end, &graph); + ops->stack(data, "<EOE>"); + /* +@@ -197,7 +197,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; +- bp = ops->walk_stack(tinfo, stack, bp, ++ bp = ops->walk_stack(task, irq_stack, stack, bp, + ops, data, irq_stack_end, &graph); + /* + * We link to the next stack (which would be +@@ -218,7 +218,8 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs, + /* + * This handles the process stack: + */ +- bp = ops->walk_stack(tinfo, stack, bp, ops, data, NULL, &graph); ++ stack_start = (void *)((unsigned long)stack & ~(THREAD_SIZE-1)); ++ bp = ops->walk_stack(task, stack_start, stack, bp, ops, data, NULL, &graph); + put_cpu(); + } + EXPORT_SYMBOL(dump_trace); +diff --git a/arch/x86/kernel/early_printk.c b/arch/x86/kernel/early_printk.c +index cd28a35..2601699 100644 +--- a/arch/x86/kernel/early_printk.c ++++ b/arch/x86/kernel/early_printk.c @@ -7,6 +7,7 @@ #include <linux/pci_regs.h> #include <linux/pci_ids.h> @@ -11494,7 +12088,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/early_printk.c linux-3.0.9/arch/x86/kerne #include <asm/io.h> #include <asm/processor.h> #include <asm/fcntl.h> -@@ -179,6 +180,8 @@ asmlinkage void early_printk(const char +@@ -179,6 +180,8 @@ asmlinkage void early_printk(const char *fmt, ...) int n; va_list ap; @@ -11503,9 +12097,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/early_printk.c linux-3.0.9/arch/x86/kerne va_start(ap, fmt); n = vscnprintf(buf, sizeof(buf), fmt, ap); early_console->write(early_console, buf, n); -diff -urNp linux-3.0.9/arch/x86/kernel/entry_32.S linux-3.0.9/arch/x86/kernel/entry_32.S ---- linux-3.0.9/arch/x86/kernel/entry_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/entry_32.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/entry_32.S b/arch/x86/kernel/entry_32.S +index 5c1a9197..6bc1991 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 @@ -12156,7 +12751,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/entry_32.S linux-3.0.9/arch/x86/kernel/en /* * End of kprobes section */ -@@ -1113,7 +1362,7 @@ BUILD_INTERRUPT3(xen_hvm_callback_vector +@@ -1113,7 +1362,7 @@ BUILD_INTERRUPT3(xen_hvm_callback_vector, XEN_HVM_EVTCHN_CALLBACK, ENTRY(mcount) ret @@ -12283,9 +12878,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/entry_32.S linux-3.0.9/arch/x86/kernel/en #endif /* -diff -urNp linux-3.0.9/arch/x86/kernel/entry_64.S linux-3.0.9/arch/x86/kernel/entry_64.S ---- linux-3.0.9/arch/x86/kernel/entry_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/entry_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/entry_64.S b/arch/x86/kernel/entry_64.S +index 8a445a0..f4d3cbd 100644 +--- a/arch/x86/kernel/entry_64.S ++++ b/arch/x86/kernel/entry_64.S @@ -53,6 +53,8 @@ #include <asm/paravirt.h> #include <asm/ftrace.h> @@ -12838,7 +13434,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/entry_64.S linux-3.0.9/arch/x86/kernel/en je retint_kernel /* Interrupt came from user space */ -@@ -847,12 +1141,16 @@ retint_swapgs: /* return to user-space +@@ -847,12 +1141,16 @@ retint_swapgs: /* return to user-space */ * The iretq could re-enable interrupts: */ DISABLE_INTERRUPTS(CLBR_ANY) @@ -13059,7 +13655,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/entry_64.S linux-3.0.9/arch/x86/kernel/en #ifdef CONFIG_XEN zeroentry xen_hypervisor_callback xen_do_hypervisor_callback -@@ -1253,7 +1611,7 @@ ENTRY(xen_do_hypervisor_callback) # do +@@ -1253,7 +1611,7 @@ ENTRY(xen_do_hypervisor_callback) # do_hypervisor_callback(struct *pt_regs) decl PER_CPU_VAR(irq_count) jmp error_exit CFI_ENDPROC @@ -13216,10 +13812,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/entry_64.S linux-3.0.9/arch/x86/kernel/en /* * End of kprobes section -diff -urNp linux-3.0.9/arch/x86/kernel/ftrace.c linux-3.0.9/arch/x86/kernel/ftrace.c ---- linux-3.0.9/arch/x86/kernel/ftrace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/ftrace.c 2011-11-12 12:47:13.000000000 -0500 -@@ -126,7 +126,7 @@ static void *mod_code_ip; /* holds the +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 */ static unsigned nmi_wait_count; @@ -13228,7 +13825,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ftrace.c linux-3.0.9/arch/x86/kernel/ftra 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) r = snprintf(buf, size, "%u %u", nmi_wait_count, @@ -13249,7 +13846,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ftrace.c linux-3.0.9/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]; @@ -13258,7 +13855,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ftrace.c linux-3.0.9/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; @@ -13267,7 +13864,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ftrace.c linux-3.0.9/arch/x86/kernel/ftra new = ftrace_call_replace(ip, (unsigned long)func); ret = ftrace_modify_code(ip, old, new); -@@ -353,6 +357,8 @@ static int ftrace_mod_jmp(unsigned long +@@ -353,6 +357,8 @@ static int ftrace_mod_jmp(unsigned long ip, { unsigned char code[MCOUNT_INSN_SIZE]; @@ -13276,9 +13873,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ftrace.c linux-3.0.9/arch/x86/kernel/ftra if (probe_kernel_read(code, (void *)ip, MCOUNT_INSN_SIZE)) return -EFAULT; -diff -urNp linux-3.0.9/arch/x86/kernel/head32.c linux-3.0.9/arch/x86/kernel/head32.c ---- linux-3.0.9/arch/x86/kernel/head32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/head32.c 2011-11-12 12:47:13.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 <asm/io_apic.h> #include <asm/bios_ebda.h> @@ -13296,9 +13894,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head32.c linux-3.0.9/arch/x86/kernel/head #ifdef CONFIG_BLK_DEV_INITRD /* Reserve INITRD */ -diff -urNp linux-3.0.9/arch/x86/kernel/head_32.S linux-3.0.9/arch/x86/kernel/head_32.S ---- linux-3.0.9/arch/x86/kernel/head_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/head_32.S 2011-11-12 12:47:13.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) @@ -13325,7 +13924,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head_32.S linux-3.0.9/arch/x86/kernel/hea /* Number of possible pages in the lowmem region */ LOWMEM_PAGES = (((1<<32) - __PAGE_OFFSET) >> PAGE_SHIFT) -@@ -77,6 +79,12 @@ INIT_MAP_SIZE = PAGE_TABLE_SIZE(KERNEL_P +@@ -77,6 +79,12 @@ INIT_MAP_SIZE = PAGE_TABLE_SIZE(KERNEL_PAGES) * PAGE_SIZE RESERVE_BRK(pagetables, INIT_MAP_SIZE) /* @@ -13635,9 +14234,9 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head_32.S linux-3.0.9/arch/x86/kernel/hea ENTRY(stack_start) - .long init_thread_union+THREAD_SIZE + .long init_thread_union+THREAD_SIZE-8 -+ -+ready: .byte 0 ++ready: .byte 0 ++ +.section .rodata,"a",@progbits early_recursion_flag: .long 0 @@ -13733,9 +14332,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head_32.S linux-3.0.9/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.0.9/arch/x86/kernel/head_64.S linux-3.0.9/arch/x86/kernel/head_64.S ---- linux-3.0.9/arch/x86/kernel/head_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/head_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/head_64.S b/arch/x86/kernel/head_64.S +index e11e394..d5a4a69 100644 +--- a/arch/x86/kernel/head_64.S ++++ b/arch/x86/kernel/head_64.S @@ -19,6 +19,7 @@ #include <asm/cache.h> #include <asm/processor-flags.h> @@ -13744,7 +14344,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head_64.S linux-3.0.9/arch/x86/kernel/hea #ifdef CONFIG_PARAVIRT #include <asm/asm-offsets.h> -@@ -38,6 +39,10 @@ L4_PAGE_OFFSET = pgd_index(__PAGE_OFFSET +@@ -38,6 +39,10 @@ L4_PAGE_OFFSET = pgd_index(__PAGE_OFFSET) L3_PAGE_OFFSET = pud_index(__PAGE_OFFSET) L4_START_KERNEL = pgd_index(__START_KERNEL_map) L3_START_KERNEL = pud_index(__START_KERNEL_map) @@ -13770,12 +14370,9 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head_64.S linux-3.0.9/arch/x86/kernel/hea - 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) - +- - 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) - +- - /* Add an Identity mapping if I am above 1G */ - leaq _text(%rip), %rdi - andq $PMD_PAGE_MASK, %rdi @@ -13784,11 +14381,14 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head_64.S linux-3.0.9/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) + - leaq (level2_spare_pgt - __START_KERNEL_map + _KERNPG_TABLE)(%rbp), %rdx - 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) + - movq %rdi, %rax - shrq $PMD_SHIFT, %rax - andq $(PTRS_PER_PMD - 1), %rax @@ -14005,9 +14605,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/head_64.S linux-3.0.9/arch/x86/kernel/hea __PAGE_ALIGNED_BSS .align PAGE_SIZE -diff -urNp linux-3.0.9/arch/x86/kernel/i386_ksyms_32.c linux-3.0.9/arch/x86/kernel/i386_ksyms_32.c ---- linux-3.0.9/arch/x86/kernel/i386_ksyms_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/i386_ksyms_32.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/i386_ksyms_32.c b/arch/x86/kernel/i386_ksyms_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 @@ -14029,9 +14630,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/i386_ksyms_32.c linux-3.0.9/arch/x86/kern +#ifdef CONFIG_PAX_KERNEXEC +EXPORT_SYMBOL(__LOAD_PHYSICAL_ADDR); +#endif -diff -urNp linux-3.0.9/arch/x86/kernel/i8259.c linux-3.0.9/arch/x86/kernel/i8259.c ---- linux-3.0.9/arch/x86/kernel/i8259.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/i8259.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/i8259.c b/arch/x86/kernel/i8259.c +index 65b8f5c..a938251 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 |= irqmask; @@ -14041,10 +14643,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/i8259.c linux-3.0.9/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.0.9/arch/x86/kernel/init_task.c linux-3.0.9/arch/x86/kernel/init_task.c ---- linux-3.0.9/arch/x86/kernel/init_task.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/init_task.c 2011-11-12 12:47:13.000000000 -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 = INIT_SIGHAND(init_sighand); * way process stacks are handled. This is done by having a special * "init_task" linker map entry.. */ @@ -14062,9 +14665,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/init_task.c linux-3.0.9/arch/x86/kernel/i - +struct tss_struct init_tss[NR_CPUS] ____cacheline_internodealigned_in_smp = { [0 ... NR_CPUS-1] = INIT_TSS }; +EXPORT_SYMBOL(init_tss); -diff -urNp linux-3.0.9/arch/x86/kernel/ioport.c linux-3.0.9/arch/x86/kernel/ioport.c ---- linux-3.0.9/arch/x86/kernel/ioport.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/ioport.c 2011-11-12 12:47:13.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 <linux/sched.h> #include <linux/kernel.h> @@ -14073,7 +14677,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ioport.c linux-3.0.9/arch/x86/kernel/iopo #include <linux/errno.h> #include <linux/types.h> #include <linux/ioport.h> -@@ -28,6 +29,12 @@ asmlinkage long sys_ioperm(unsigned long +@@ -28,6 +29,12 @@ asmlinkage long sys_ioperm(unsigned long from, unsigned long num, int turn_on) if ((from + num <= from) || (from + num > IO_BITMAP_BITS)) return -EINVAL; @@ -14086,7 +14690,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ioport.c linux-3.0.9/arch/x86/kernel/iopo if (turn_on && !capable(CAP_SYS_RAWIO)) return -EPERM; -@@ -54,7 +61,7 @@ asmlinkage long sys_ioperm(unsigned long +@@ -54,7 +61,7 @@ asmlinkage long sys_ioperm(unsigned long from, unsigned long num, int turn_on) * because the ->io_bitmap_max value must match the bitmap * contents: */ @@ -14095,7 +14699,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ioport.c linux-3.0.9/arch/x86/kernel/iopo 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 *regs) return -EINVAL; /* Trying to gain more privileges? */ if (level > old) { @@ -14108,9 +14712,48 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ioport.c linux-3.0.9/arch/x86/kernel/iopo if (!capable(CAP_SYS_RAWIO)) return -EPERM; } -diff -urNp linux-3.0.9/arch/x86/kernel/irq_32.c linux-3.0.9/arch/x86/kernel/irq_32.c ---- linux-3.0.9/arch/x86/kernel/irq_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/irq_32.c 2011-11-12 12:47:13.000000000 -0500 +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 <asm/mce.h> + #include <asm/hw_irq.h> + +-atomic_t irq_err_count; ++atomic_unchecked_t irq_err_count; + + /* Function pointer for generic interrupt vector handling */ + void (*x86_platform_ipi_callback)(void) = NULL; +@@ -116,9 +116,9 @@ int arch_show_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_err_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_mis_count)); + #endif + return 0; + } +@@ -158,10 +158,10 @@ u64 arch_irq_stat_cpu(unsigned int cpu) + + u64 arch_irq_stat(void) + { +- u64 sum = atomic_read(&irq_err_count); ++ u64 sum = atomic_read_unchecked(&irq_err_count); + + #ifdef CONFIG_X86_IO_APIC +- sum += atomic_read(&irq_mis_count); ++ sum += 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 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" : "=r" (sp) : "0" (THREAD_SIZE - 1)); @@ -14120,7 +14763,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/irq_32.c linux-3.0.9/arch/x86/kernel/irq_ } static void print_stack_overflow(void) -@@ -54,8 +54,8 @@ static inline void print_stack_overflow( +@@ -54,8 +54,8 @@ static inline void print_stack_overflow(void) { } * per-CPU IRQ handling contexts (thread information and stack) */ union irq_ctx { @@ -14131,7 +14774,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/irq_32.c linux-3.0.9/arch/x86/kernel/irq_ } __attribute__((aligned(THREAD_SIZE))); static DEFINE_PER_CPU(union irq_ctx *, hardirq_ctx); -@@ -75,10 +75,9 @@ static void call_on_stack(void *func, vo +@@ -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) { @@ -14143,7 +14786,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/irq_32.c linux-3.0.9/arch/x86/kernel/irq_ irqctx = __this_cpu_read(hardirq_ctx); /* -@@ -87,21 +86,16 @@ execute_on_irq_stack(int overflow, struc +@@ -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) */ @@ -14171,7 +14814,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/irq_32.c linux-3.0.9/arch/x86/kernel/irq_ if (unlikely(overflow)) call_on_stack(print_stack_overflow, isp); -@@ -113,6 +107,11 @@ execute_on_irq_stack(int overflow, struc +@@ -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"); @@ -14183,7 +14826,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/irq_32.c linux-3.0.9/arch/x86/kernel/irq_ return 1; } -@@ -121,29 +120,11 @@ execute_on_irq_stack(int overflow, struc +@@ -121,29 +120,11 @@ execute_on_irq_stack(int overflow, struct irq_desc *desc, int irq) */ void __cpuinit irq_ctx_init(int cpu) { @@ -14250,47 +14893,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/irq_32.c linux-3.0.9/arch/x86/kernel/irq_ /* * Shouldn't happen, we returned above if in_interrupt(): */ -diff -urNp linux-3.0.9/arch/x86/kernel/irq.c linux-3.0.9/arch/x86/kernel/irq.c ---- linux-3.0.9/arch/x86/kernel/irq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/irq.c 2011-11-12 12:47:13.000000000 -0500 -@@ -17,7 +17,7 @@ - #include <asm/mce.h> - #include <asm/hw_irq.h> - --atomic_t irq_err_count; -+atomic_unchecked_t irq_err_count; - - /* Function pointer for generic interrupt vector handling */ - void (*x86_platform_ipi_callback)(void) = NULL; -@@ -116,9 +116,9 @@ int arch_show_interrupts(struct seq_file - 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_err_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_mis_count)); - #endif - return 0; - } -@@ -158,10 +158,10 @@ u64 arch_irq_stat_cpu(unsigned int cpu) - - u64 arch_irq_stat(void) - { -- u64 sum = atomic_read(&irq_err_count); -+ u64 sum = atomic_read_unchecked(&irq_err_count); - - #ifdef CONFIG_X86_IO_APIC -- sum += atomic_read(&irq_mis_count); -+ sum += atomic_read_unchecked(&irq_mis_count); - #endif - return sum; - } -diff -urNp linux-3.0.9/arch/x86/kernel/kgdb.c linux-3.0.9/arch/x86/kernel/kgdb.c ---- linux-3.0.9/arch/x86/kernel/kgdb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/kgdb.c 2011-11-12 12:47:13.000000000 -0500 -@@ -124,11 +124,11 @@ char *dbg_get_reg(int regno, void *mem, +diff --git a/arch/x86/kernel/kgdb.c b/arch/x86/kernel/kgdb.c +index 5f9ecff..122d84b 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: @@ -14304,7 +14911,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kgdb.c linux-3.0.9/arch/x86/kernel/kgdb.c *(unsigned long *)mem = 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 signo, int err_code, case 'k': /* clear the trace bit */ linux_regs->flags &= ~X86_EFLAGS_TF; @@ -14319,7 +14926,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kgdb.c linux-3.0.9/arch/x86/kernel/kgdb.c raw_smp_processor_id()); } -@@ -534,7 +534,7 @@ static int __kgdb_notify(struct die_args +@@ -534,7 +534,7 @@ static int __kgdb_notify(struct die_args *args, unsigned long cmd) return NOTIFY_DONE; case DIE_DEBUG: @@ -14328,10 +14935,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kgdb.c linux-3.0.9/arch/x86/kernel/kgdb.c if (user_mode(regs)) return single_step_cont(regs, args); break; -diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kprobes.c ---- linux-3.0.9/arch/x86/kernel/kprobes.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/kprobes.c 2011-11-12 12:47:13.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(void *from, void *to, u8 op) } __attribute__((packed)) *insn; insn = (struct __arch_relative_insn *)from; @@ -14343,7 +14951,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr } /* 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 *opcodes) kprobe_opcode_t opcode; kprobe_opcode_t *orig_opcodes = opcodes; @@ -14352,7 +14960,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr return 0; /* Page fault may occur on this address. */ 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); @@ -14362,7 +14970,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr #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 != newdisp); /* Sanity check. */ disp = (u8 *) dest + insn_offset_displacement(&insn); @@ -14372,7 +14980,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/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 kprobe *p) */ __copy_instruction(p->ainsn.insn, p->addr, 0); @@ -14387,7 +14995,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr } 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. */ @@ -14396,7 +15004,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/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 == BREAKPOINT_INSTRUCTION) regs->ip = (unsigned long)p->addr; else @@ -14405,7 +15013,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr } /* -@@ -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; } @@ -14414,7 +15022,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/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_holder(void) " movq %rax, 152(%rsp)\n" RESTORE_REGS_STRING " popfq\n" @@ -14424,7 +15032,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/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 = stack_addr(regs); @@ -14433,7 +15041,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr unsigned long orig_ip = (unsigned long)p->addr; kprobe_opcode_t *insn = p->ainsn.insn; -@@ -1001,7 +1011,7 @@ int __kprobes kprobe_exceptions_notify(s +@@ -1001,7 +1011,7 @@ int __kprobes kprobe_exceptions_notify(struct notifier_block *self, struct die_args *args = data; int ret = NOTIFY_DONE; @@ -14442,7 +15050,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr return ret; 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. */ @@ -14451,7 +15059,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr if (abs(rel) > 0x7fffffff) return -ERANGE; -@@ -1404,11 +1414,11 @@ int __kprobes arch_prepare_optimized_kpr +@@ -1404,11 +1414,11 @@ int __kprobes arch_prepare_optimized_kprobe(struct optimized_kprobe *op) synthesize_set_arg1(buf + TMPL_MOVE_IDX, (unsigned long)op); /* Set probe function call */ @@ -14465,7 +15073,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr 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)); /* Backup instructions which will be replaced by jump address */ @@ -14474,10 +15082,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kprobes.c linux-3.0.9/arch/x86/kernel/kpr RELATIVE_ADDR_SIZE); insn_buf[0] = RELATIVEJUMP_OPCODE; -diff -urNp linux-3.0.9/arch/x86/kernel/kvm.c linux-3.0.9/arch/x86/kernel/kvm.c ---- linux-3.0.9/arch/x86/kernel/kvm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/kvm.c 2011-11-12 12:47:13.000000000 -0500 -@@ -426,6 +426,7 @@ static void __init paravirt_ops_setup(vo +diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c +index 33c07b0..188cc41 100644 +--- a/arch/x86/kernel/kvm.c ++++ b/arch/x86/kernel/kvm.c +@@ -426,6 +426,7 @@ static void __init paravirt_ops_setup(void) pv_mmu_ops.set_pud = kvm_set_pud; #if PAGETABLE_LEVELS == 4 pv_mmu_ops.set_pgd = kvm_set_pgd; @@ -14485,10 +15094,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/kvm.c linux-3.0.9/arch/x86/kernel/kvm.c #endif #endif pv_mmu_ops.flush_tlb_user = kvm_flush_tlb; -diff -urNp linux-3.0.9/arch/x86/kernel/ldt.c linux-3.0.9/arch/x86/kernel/ldt.c ---- linux-3.0.9/arch/x86/kernel/ldt.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/ldt.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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(); @@ -14504,7 +15114,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ldt.c linux-3.0.9/arch/x86/kernel/ldt.c #endif } if (oldsize) { -@@ -95,7 +95,7 @@ static inline int copy_ldt(mm_context_t +@@ -95,7 +95,7 @@ static inline int copy_ldt(mm_context_t *new, mm_context_t *old) return err; for (i = 0; i < old->size; i++) @@ -14513,7 +15123,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ldt.c linux-3.0.9/arch/x86/kernel/ldt.c return 0; } -@@ -116,6 +116,24 @@ int init_new_context(struct task_struct +@@ -116,6 +116,24 @@ int init_new_context(struct task_struct *tsk, struct mm_struct *mm) retval = copy_ldt(&mm->context, &old_mm->context); mutex_unlock(&old_mm->context.lock); } @@ -14538,7 +15148,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ldt.c linux-3.0.9/arch/x86/kernel/ldt.c return retval; } -@@ -230,6 +248,13 @@ static int write_ldt(void __user *ptr, u +@@ -230,6 +248,13 @@ static int write_ldt(void __user *ptr, unsigned long bytecount, int oldmode) } } @@ -14552,9 +15162,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ldt.c linux-3.0.9/arch/x86/kernel/ldt.c fill_ldt(&ldt, &ldt_info); if (oldmode) ldt.avl = 0; -diff -urNp linux-3.0.9/arch/x86/kernel/machine_kexec_32.c linux-3.0.9/arch/x86/kernel/machine_kexec_32.c ---- linux-3.0.9/arch/x86/kernel/machine_kexec_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/machine_kexec_32.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/machine_kexec_32.c b/arch/x86/kernel/machine_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 <asm/cacheflush.h> #include <asm/debugreg.h> @@ -14564,7 +15175,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/machine_kexec_32.c linux-3.0.9/arch/x86/k { struct desc_ptr curidt; -@@ -39,7 +39,7 @@ static void set_idt(void *newidt, __u16 +@@ -39,7 +39,7 @@ static void set_idt(void *newidt, __u16 limit) } @@ -14582,10 +15193,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/machine_kexec_32.c linux-3.0.9/arch/x86/k relocate_kernel_ptr = control_page; page_list[PA_CONTROL_PAGE] = __pa(control_page); -diff -urNp linux-3.0.9/arch/x86/kernel/microcode_intel.c linux-3.0.9/arch/x86/kernel/microcode_intel.c ---- linux-3.0.9/arch/x86/kernel/microcode_intel.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/microcode_intel.c 2011-11-12 12:47:13.000000000 -0500 -@@ -440,13 +440,13 @@ static enum ucode_state request_microcod +diff --git a/arch/x86/kernel/microcode_intel.c b/arch/x86/kernel/microcode_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 cpu, struct device *device) static int get_ucode_user(void *to, const void *from, size_t n) { @@ -14601,9 +15213,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/microcode_intel.c linux-3.0.9/arch/x86/ke } static void microcode_fini_cpu(int cpu) -diff -urNp linux-3.0.9/arch/x86/kernel/module.c linux-3.0.9/arch/x86/kernel/module.c ---- linux-3.0.9/arch/x86/kernel/module.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/module.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/module.c b/arch/x86/kernel/module.c +index 52f256f..8bf1485 100644 +--- a/arch/x86/kernel/module.c ++++ b/arch/x86/kernel/module.c @@ -36,21 +36,66 @@ #define DEBUGP(fmt...) #endif @@ -14711,7 +15324,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/module.c linux-3.0.9/arch/x86/kernel/modu break; default: printk(KERN_ERR "module %s: Unknown relocation: %u\n", -@@ -146,21 +197,30 @@ int apply_relocate_add(Elf64_Shdr *sechd +@@ -146,21 +197,30 @@ int apply_relocate_add(Elf64_Shdr *sechdrs, case R_X86_64_NONE: break; case R_X86_64_64: @@ -14742,9 +15355,23 @@ diff -urNp linux-3.0.9/arch/x86/kernel/module.c linux-3.0.9/arch/x86/kernel/modu #if 0 if ((s64)val != *(s32 *)loc) goto overflow; -diff -urNp linux-3.0.9/arch/x86/kernel/paravirt.c linux-3.0.9/arch/x86/kernel/paravirt.c ---- linux-3.0.9/arch/x86/kernel/paravirt.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/paravirt.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/paravirt-spinlocks.c b/arch/x86/kernel/paravirt-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, unsigned long flags) + arch_spin_lock(lock); + } + +-struct pv_lock_ops pv_lock_ops = { ++struct pv_lock_ops pv_lock_ops __read_only = { + #ifdef CONFIG_SMP + .spin_is_locked = __ticket_spin_is_locked, + .spin_is_contended = __ticket_spin_is_contended, +diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c +index 869e1ae..2b82740 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; @@ -14755,7 +15382,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/paravirt.c linux-3.0.9/arch/x86/kernel/pa 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 void *target, * corresponding structure. */ static void *get_call_destination(u8 type) { @@ -14764,7 +15391,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/paravirt.c linux-3.0.9/arch/x86/kernel/pa .pv_init_ops = pv_init_ops, .pv_time_ops = pv_time_ops, .pv_cpu_ops = pv_cpu_ops, -@@ -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 = pv_lock_ops, #endif }; @@ -14774,7 +15401,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/paravirt.c linux-3.0.9/arch/x86/kernel/pa return *((void **)&tmpl + type); } -@@ -145,15 +151,19 @@ unsigned paravirt_patch_default(u8 type, +@@ -145,15 +151,19 @@ unsigned paravirt_patch_default(u8 type, u16 clobbers, void *insnbuf, if (opfunc == NULL) /* If there's no function, patch it with a ud2a (BUG) */ ret = paravirt_patch_insns(insnbuf, len, ud2a, ud2a+sizeof(ud2a)); @@ -14797,7 +15424,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/paravirt.c linux-3.0.9/arch/x86/kernel/pa else if (type == PARAVIRT_PATCH(pv_cpu_ops.iret) || type == 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, unsigned len, if (insn_len > len || start == NULL) insn_len = len; else @@ -14893,21 +15520,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/paravirt.c linux-3.0.9/arch/x86/kernel/pa }; EXPORT_SYMBOL_GPL(pv_time_ops); -diff -urNp linux-3.0.9/arch/x86/kernel/paravirt-spinlocks.c linux-3.0.9/arch/x86/kernel/paravirt-spinlocks.c ---- linux-3.0.9/arch/x86/kernel/paravirt-spinlocks.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/paravirt-spinlocks.c 2011-11-12 12:47:13.000000000 -0500 -@@ -13,7 +13,7 @@ default_spin_lock_flags(arch_spinlock_t - arch_spin_lock(lock); - } - --struct pv_lock_ops pv_lock_ops = { -+struct pv_lock_ops pv_lock_ops __read_only = { - #ifdef CONFIG_SMP - .spin_is_locked = __ticket_spin_is_locked, - .spin_is_contended = __ticket_spin_is_contended, -diff -urNp linux-3.0.9/arch/x86/kernel/pci-iommu_table.c linux-3.0.9/arch/x86/kernel/pci-iommu_table.c ---- linux-3.0.9/arch/x86/kernel/pci-iommu_table.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/pci-iommu_table.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/pci-iommu_table.c b/arch/x86/kernel/pci-iommu_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 <asm/iommu_table.h> #include <linux/string.h> @@ -14917,7 +15533,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/pci-iommu_table.c linux-3.0.9/arch/x86/ke #define DEBUG 1 -@@ -51,6 +51,8 @@ void __init check_iommu_entries(struct i +@@ -51,6 +51,8 @@ void __init check_iommu_entries(struct iommu_table_entry *start, { struct iommu_table_entry *p, *q, *x; @@ -14926,10 +15542,152 @@ diff -urNp linux-3.0.9/arch/x86/kernel/pci-iommu_table.c linux-3.0.9/arch/x86/ke /* Simple cyclic dependency checker. */ for (p = start; p < finish; p++) { q = find_dependents_of(start, finish, p); -diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/process_32.c ---- linux-3.0.9/arch/x86/kernel/process_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/process_32.c 2011-11-12 12:47:13.000000000 -0500 -@@ -65,6 +65,7 @@ asmlinkage void ret_from_fork(void) __as +diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c +index e1ba8cb..70a03a0 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) + + void free_thread_info(struct thread_info *ti) + { +- free_thread_xstate(ti->task); + free_pages((unsigned long)ti, get_order(THREAD_SIZE)); + } + ++static struct kmem_cache *task_struct_cachep; ++ + void arch_task_cache_init(void) + { +- task_xstate_cachep = +- kmem_cache_create("task_xstate", xstate_size, ++ /* create a slab on which task_structs can be allocated */ ++ task_struct_cachep = ++ kmem_cache_create("task_struct", sizeof(struct task_struct), ++ ARCH_MIN_TASKALIGN, SLAB_PANIC | SLAB_NOTRACK, NULL); ++ ++ task_xstate_cachep = ++ 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); + } + + /* +@@ -70,7 +87,7 @@ void exit_thread(void) + unsigned long *bp = t->io_bitmap_ptr; + + if (bp) { +- struct tss_struct *tss = &per_cpu(init_tss, get_cpu()); ++ struct tss_struct *tss = init_tss + get_cpu(); + + t->io_bitmap_ptr = NULL; + clear_thread_flag(TIF_IO_BITMAP); +@@ -106,7 +123,7 @@ void show_regs_common(void) + + 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 = current; + ++#if defined(CONFIG_X86_32) && !defined(CONFIG_CC_STACKPROTECTOR) && !defined(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, unsigned long flags) + regs.di = (unsigned long) arg; + + #ifdef CONFIG_X86_32 +- regs.ds = __USER_DS; +- regs.es = __USER_DS; ++ regs.ds = __KERNEL_DS; ++ regs.es = __KERNEL_DS; + regs.fs = __KERNEL_PERCPU; +- regs.gs = __KERNEL_STACK_CANARY; ++ savesegment(gs, regs.gs); + #else + regs.ss = __KERNEL_DS; + #endif +@@ -403,7 +423,7 @@ void default_idle(void) + EXPORT_SYMBOL(default_idle); + #endif + +-void stop_this_cpu(void *dummy) ++__noreturn void stop_this_cpu(void *dummy) + { + local_irq_disable(); + /* +@@ -668,16 +688,37 @@ static int __init idle_setup(char *str) + } + early_param("idle", idle_setup); + +-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 -= get_random_int() % 8192; +- return sp & ~0xf; +-} ++ struct thread_struct *thread = ¤t->thread; ++ unsigned long time; + +-unsigned long arch_randomize_brk(struct mm_struct *mm) +-{ +- unsigned long range_end = 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 &= 0x3EUL; ++ time <<= 2; ++#elif defined(CONFIG_X86_64) ++ time &= 0xFUL; ++ time <<= 4; ++#else ++ time &= 0x1FUL; ++ time <<= 3; ++#endif ++ ++ thread->sp0 ^= 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 a3d0dc5..6a414ba 100644 +--- a/arch/x86/kernel/process_32.c ++++ b/arch/x86/kernel/process_32.c +@@ -65,6 +65,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]; @@ -14937,7 +15695,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/ } #ifndef CONFIG_SMP -@@ -126,15 +127,14 @@ void __show_regs(struct pt_regs *regs, i +@@ -126,15 +127,14 @@ void __show_regs(struct pt_regs *regs, int all) unsigned long sp; unsigned short ss, gs; @@ -14955,7 +15713,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/ show_regs_common(); -@@ -196,13 +196,14 @@ int copy_thread(unsigned long clone_flag +@@ -196,13 +196,14 @@ int copy_thread(unsigned long clone_flags, unsigned long sp, struct task_struct *tsk; int err; @@ -14971,7 +15729,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/ p->thread.ip = (unsigned long) ret_from_fork; -@@ -292,7 +293,7 @@ __switch_to(struct task_struct *prev_p, +@@ -292,7 +293,7 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p) struct thread_struct *prev = &prev_p->thread, *next = &next_p->thread; int cpu = smp_processor_id(); @@ -14980,7 +15738,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/ bool preload_fpu; /* never put a printk in __switch_to... printk() calls wake_up*() indirectly */ -@@ -327,6 +328,10 @@ __switch_to(struct task_struct *prev_p, +@@ -327,6 +328,10 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p) */ lazy_save_gs(prev->gs); @@ -14991,7 +15749,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/ /* * Load the per-thread Thread-Local Storage descriptor. */ -@@ -362,6 +367,9 @@ __switch_to(struct task_struct *prev_p, +@@ -362,6 +367,9 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p) */ arch_end_context_switch(next_p); @@ -15001,7 +15759,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/ if (preload_fpu) __math_state_restore(); -@@ -371,8 +379,6 @@ __switch_to(struct task_struct *prev_p, +@@ -371,8 +379,6 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p) if (prev->gs | next->gs) lazy_load_gs(next->gs); @@ -15010,14 +15768,15 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_32.c linux-3.0.9/arch/x86/kernel/ return prev_p; } -@@ -402,4 +408,3 @@ unsigned long get_wchan(struct task_stru +@@ -402,4 +408,3 @@ unsigned long get_wchan(struct task_struct *p) } while (count++ < 16); return 0; } - -diff -urNp linux-3.0.9/arch/x86/kernel/process_64.c linux-3.0.9/arch/x86/kernel/process_64.c ---- linux-3.0.9/arch/x86/kernel/process_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/process_64.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/process_64.c b/arch/x86/kernel/process_64.c +index ca6f7ab..5d3f0e1 100644 +--- a/arch/x86/kernel/process_64.c ++++ b/arch/x86/kernel/process_64.c @@ -87,7 +87,7 @@ static void __exit_idle(void) void exit_idle(void) { @@ -15027,7 +15786,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_64.c linux-3.0.9/arch/x86/kernel/ return; __exit_idle(); } -@@ -260,8 +260,7 @@ int copy_thread(unsigned long clone_flag +@@ -260,8 +260,7 @@ int copy_thread(unsigned long clone_flags, unsigned long sp, struct pt_regs *childregs; struct task_struct *me = current; @@ -15037,7 +15796,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_64.c linux-3.0.9/arch/x86/kernel/ *childregs = *regs; childregs->ax = 0; -@@ -273,6 +272,7 @@ int copy_thread(unsigned long clone_flag +@@ -273,6 +272,7 @@ int copy_thread(unsigned long clone_flags, unsigned long sp, p->thread.sp = (unsigned long) childregs; p->thread.sp0 = (unsigned long) (childregs+1); p->thread.usersp = me->thread.usersp; @@ -15045,7 +15804,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_64.c linux-3.0.9/arch/x86/kernel/ set_tsk_thread_flag(p, TIF_FORK); -@@ -375,7 +375,7 @@ __switch_to(struct task_struct *prev_p, +@@ -375,7 +375,7 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p) struct thread_struct *prev = &prev_p->thread; struct thread_struct *next = &next_p->thread; int cpu = smp_processor_id(); @@ -15054,7 +15813,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_64.c linux-3.0.9/arch/x86/kernel/ unsigned fsindex, gsindex; bool preload_fpu; -@@ -471,10 +471,9 @@ __switch_to(struct task_struct *prev_p, +@@ -471,10 +471,9 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p) prev->usersp = percpu_read(old_rsp); percpu_write(old_rsp, next->usersp); percpu_write(current_task, next_p); @@ -15067,7 +15826,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_64.c linux-3.0.9/arch/x86/kernel/ /* * Now maybe reload the debug registers and handle I/O bitmaps -@@ -536,12 +535,11 @@ unsigned long get_wchan(struct task_stru +@@ -536,12 +535,11 @@ unsigned long get_wchan(struct task_struct *p) if (!p || p == current || p->state == TASK_RUNNING) return 0; stack = (unsigned long)task_stack_page(p); @@ -15082,150 +15841,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/process_64.c linux-3.0.9/arch/x86/kernel/ return 0; ip = *(u64 *)(fp+8); if (!in_sched_functions(ip)) -diff -urNp linux-3.0.9/arch/x86/kernel/process.c linux-3.0.9/arch/x86/kernel/process.c ---- linux-3.0.9/arch/x86/kernel/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/process.c 2011-11-12 12:47:13.000000000 -0500 -@@ -48,16 +48,33 @@ void free_thread_xstate(struct task_stru - - void free_thread_info(struct thread_info *ti) - { -- free_thread_xstate(ti->task); - free_pages((unsigned long)ti, get_order(THREAD_SIZE)); - } - -+static struct kmem_cache *task_struct_cachep; -+ - void arch_task_cache_init(void) - { -- task_xstate_cachep = -- kmem_cache_create("task_xstate", xstate_size, -+ /* create a slab on which task_structs can be allocated */ -+ task_struct_cachep = -+ kmem_cache_create("task_struct", sizeof(struct task_struct), -+ ARCH_MIN_TASKALIGN, SLAB_PANIC | SLAB_NOTRACK, NULL); -+ -+ task_xstate_cachep = -+ 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); - } - - /* -@@ -70,7 +87,7 @@ void exit_thread(void) - unsigned long *bp = t->io_bitmap_ptr; - - if (bp) { -- struct tss_struct *tss = &per_cpu(init_tss, get_cpu()); -+ struct tss_struct *tss = init_tss + get_cpu(); - - t->io_bitmap_ptr = NULL; - clear_thread_flag(TIF_IO_BITMAP); -@@ -106,7 +123,7 @@ void show_regs_common(void) - - 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 = current; - -+#if defined(CONFIG_X86_32) && !defined(CONFIG_CC_STACKPROTECTOR) && !defined(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 = (unsigned long) arg; - - #ifdef CONFIG_X86_32 -- regs.ds = __USER_DS; -- regs.es = __USER_DS; -+ regs.ds = __KERNEL_DS; -+ regs.es = __KERNEL_DS; - regs.fs = __KERNEL_PERCPU; -- regs.gs = __KERNEL_STACK_CANARY; -+ savesegment(gs, regs.gs); - #else - regs.ss = __KERNEL_DS; - #endif -@@ -403,7 +423,7 @@ void default_idle(void) - EXPORT_SYMBOL(default_idle); - #endif - --void stop_this_cpu(void *dummy) -+__noreturn void stop_this_cpu(void *dummy) - { - local_irq_disable(); - /* -@@ -668,16 +688,37 @@ static int __init idle_setup(char *str) - } - early_param("idle", idle_setup); - --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 -= get_random_int() % 8192; -- return sp & ~0xf; --} -+ struct thread_struct *thread = ¤t->thread; -+ unsigned long time; - --unsigned long arch_randomize_brk(struct mm_struct *mm) --{ -- unsigned long range_end = 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 &= 0x3EUL; -+ time <<= 2; -+#elif defined(CONFIG_X86_64) -+ time &= 0xFUL; -+ time <<= 4; -+#else -+ time &= 0x1FUL; -+ time <<= 3; -+#endif -+ -+ thread->sp0 ^= 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.0.9/arch/x86/kernel/ptrace.c linux-3.0.9/arch/x86/kernel/ptrace.c ---- linux-3.0.9/arch/x86/kernel/ptrace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/ptrace.c 2011-11-12 12:47:13.000000000 -0500 -@@ -821,7 +821,7 @@ long arch_ptrace(struct task_struct *chi +diff --git a/arch/x86/kernel/ptrace.c b/arch/x86/kernel/ptrace.c +index 807c2a2..6350c3e 100644 +--- a/arch/x86/kernel/ptrace.c ++++ b/arch/x86/kernel/ptrace.c +@@ -821,7 +821,7 @@ long arch_ptrace(struct task_struct *child, long request, unsigned long addr, unsigned long data) { int ret; @@ -15234,7 +15854,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ptrace.c linux-3.0.9/arch/x86/kernel/ptra switch (request) { /* read the word at location addr in the USER area. */ -@@ -906,14 +906,14 @@ long arch_ptrace(struct task_struct *chi +@@ -906,14 +906,14 @@ long arch_ptrace(struct task_struct *child, long request, if ((int) addr < 0) return -EIO; ret = do_get_thread_area(child, addr, @@ -15251,7 +15871,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ptrace.c linux-3.0.9/arch/x86/kernel/ptra break; #endif -@@ -1330,7 +1330,7 @@ static void fill_sigtrap_info(struct tas +@@ -1330,7 +1330,7 @@ static void fill_sigtrap_info(struct task_struct *tsk, memset(info, 0, sizeof(*info)); info->si_signo = SIGTRAP; info->si_code = si_code; @@ -15260,10 +15880,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/ptrace.c linux-3.0.9/arch/x86/kernel/ptra } void user_single_step_siginfo(struct task_struct *tsk, -diff -urNp linux-3.0.9/arch/x86/kernel/pvclock.c linux-3.0.9/arch/x86/kernel/pvclock.c ---- linux-3.0.9/arch/x86/kernel/pvclock.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/pvclock.c 2011-11-12 12:47:13.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_time_info *src) return pv_tsc_khz; } @@ -15277,7 +15898,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/pvclock.c linux-3.0.9/arch/x86/kernel/pvc } cycle_t pvclock_clocksource_read(struct pvclock_vcpu_time_info *src) -@@ -121,11 +121,11 @@ cycle_t pvclock_clocksource_read(struct +@@ -121,11 +121,11 @@ cycle_t pvclock_clocksource_read(struct pvclock_vcpu_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 hold. */ @@ -15291,9 +15912,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/pvclock.c linux-3.0.9/arch/x86/kernel/pvc } while (unlikely(last != ret)); return ret; -diff -urNp linux-3.0.9/arch/x86/kernel/reboot.c linux-3.0.9/arch/x86/kernel/reboot.c ---- linux-3.0.9/arch/x86/kernel/reboot.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/reboot.c 2011-11-12 12:47:13.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); @@ -15323,7 +15945,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/reboot.c linux-3.0.9/arch/x86/kernel/rebo local_irq_disable(); /* 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. */ @@ -15340,7 +15962,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/reboot.c linux-3.0.9/arch/x86/kernel/rebo /* GDT[0]: GDT self-pointer */ lowmem_gdt[0] = -@@ -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); /* Jump to the identity-mapped low memory code */ @@ -15374,7 +15996,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/reboot.c linux-3.0.9/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 keyboard * controller and doing that */ @@ -15399,7 +16021,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/reboot.c linux-3.0.9/arch/x86/kernel/rebo { printk("machine restart\n"); -@@ -662,7 +692,7 @@ static void native_machine_restart(char +@@ -662,7 +692,7 @@ static void native_machine_restart(char *__unused) __machine_emergency_restart(0); } @@ -15417,7 +16039,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/reboot.c linux-3.0.9/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); @@ -15425,10 +16047,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/reboot.c linux-3.0.9/arch/x86/kernel/rebo } struct machine_ops machine_ops = { -diff -urNp linux-3.0.9/arch/x86/kernel/setup.c linux-3.0.9/arch/x86/kernel/setup.c ---- linux-3.0.9/arch/x86/kernel/setup.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/setup.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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) switch (data->type) { case SETUP_E820_EXT: @@ -15466,9 +16089,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/setup.c linux-3.0.9/arch/x86/kernel/setup data_resource.end = virt_to_phys(_edata)-1; bss_resource.start = virt_to_phys(&__bss_start); bss_resource.end = virt_to_phys(&__bss_stop)-1; -diff -urNp linux-3.0.9/arch/x86/kernel/setup_percpu.c linux-3.0.9/arch/x86/kernel/setup_percpu.c ---- linux-3.0.9/arch/x86/kernel/setup_percpu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/setup_percpu.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/setup_percpu.c b/arch/x86/kernel/setup_percpu.c +index 71f4727..16dc9f7 100644 +--- a/arch/x86/kernel/setup_percpu.c ++++ b/arch/x86/kernel/setup_percpu.c @@ -21,19 +21,17 @@ #include <asm/cpu.h> #include <asm/stackprotector.h> @@ -15493,7 +16117,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/setup_percpu.c linux-3.0.9/arch/x86/kerne [0 ... NR_CPUS-1] = 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; @@ -15532,10 +16156,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/setup_percpu.c linux-3.0.9/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.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/signal.c ---- linux-3.0.9/arch/x86/kernel/signal.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/signal.c 2011-11-12 12:47:13.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 40a2493..2348ff2 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) == 0. */ @@ -15544,7 +16169,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/sign #else /* !CONFIG_X86_32 */ sp = 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_regs *regs, size_t frame_size, * Return an always-bogus address instead so we will die with SIGSEGV. */ if (onsigstack && !likely(on_sig_stack(sp))) @@ -15558,7 +16183,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/sign 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, sigset_t *set, } if (current->mm->context.vdso) @@ -15570,7 +16195,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/sign if (ka->sa.sa_flags & SA_RESTORER) restorer = ka->sa.sa_restorer; -@@ -324,7 +324,7 @@ __setup_frame(int sig, struct k_sigactio +@@ -324,7 +324,7 @@ __setup_frame(int sig, struct k_sigaction *ka, sigset_t *set, * reasons and because gdb uses it as a signature to notice * signal handler stack frames. */ @@ -15579,7 +16204,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/sign 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_sigaction *ka, siginfo_t *info, err |= __copy_to_user(&frame->uc.uc_sigmask, set, sizeof(*set)); /* Set up to return from userspace. */ @@ -15591,7 +16216,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/sign if (ka->sa.sa_flags & SA_RESTORER) restorer = 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_sigaction *ka, siginfo_t *info, * reasons and because gdb uses it as a signature to notice * signal handler stack frames. */ @@ -15600,7 +16225,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/sign } put_user_catch(err); if (err) -@@ -769,6 +772,8 @@ static void do_signal(struct pt_regs *re +@@ -769,6 +772,8 @@ static void do_signal(struct pt_regs *regs) int signr; sigset_t *oldset; @@ -15609,7 +16234,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/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 -@@ -776,7 +781,7 @@ static void do_signal(struct pt_regs *re +@@ -776,7 +781,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. */ @@ -15618,10 +16243,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/signal.c linux-3.0.9/arch/x86/kernel/sign return; if (current_thread_info()->status & TS_RESTORE_SIGMASK) -diff -urNp linux-3.0.9/arch/x86/kernel/smpboot.c linux-3.0.9/arch/x86/kernel/smpboot.c ---- linux-3.0.9/arch/x86/kernel/smpboot.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/smpboot.c 2011-11-12 12:47:13.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 9fd3137..290be8c 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 cpu) set_idle_for_cpu(cpu, c_idle.idle); do_rest: per_cpu(current_task, cpu) = c_idle.idle; @@ -15645,7 +16271,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/smpboot.c linux-3.0.9/arch/x86/kernel/smp initial_code = (unsigned long)start_secondary; stack_start = c_idle.idle->thread.sp; -@@ -861,6 +864,12 @@ int __cpuinit native_cpu_up(unsigned int +@@ -861,6 +864,12 @@ int __cpuinit native_cpu_up(unsigned int cpu) per_cpu(cpu_state, cpu) = CPU_UP_PREPARE; @@ -15658,10 +16284,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/smpboot.c linux-3.0.9/arch/x86/kernel/smp err = do_boot_cpu(apicid, cpu); if (err) { pr_debug("do_boot_cpu failed %d\n", err); -diff -urNp linux-3.0.9/arch/x86/kernel/step.c linux-3.0.9/arch/x86/kernel/step.c ---- linux-3.0.9/arch/x86/kernel/step.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/step.c 2011-11-12 12:47:13.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 7977f0c..6b8651b 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_struct *child, struct pt_regs *re struct desc_struct *desc; unsigned long base; @@ -15674,7 +16301,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/step.c linux-3.0.9/arch/x86/kernel/step.c addr = -1L; /* bogus selector, access would fault */ else { desc = 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 += base; } mutex_unlock(&child->mm->context.lock); @@ -15684,7 +16311,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/step.c linux-3.0.9/arch/x86/kernel/step.c 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 *child, struct pt_regs *regs) unsigned char opcode[15]; unsigned long addr = convert_ip_to_linear(child, regs); @@ -15694,7 +16321,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/step.c linux-3.0.9/arch/x86/kernel/step.c copied = access_process_vm(child, addr, opcode, sizeof(opcode), 0); for (i = 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 *child, struct pt_regs *regs) #ifdef CONFIG_X86_64 case 0x40 ... 0x4f: @@ -15703,17 +16330,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/step.c linux-3.0.9/arch/x86/kernel/step.c /* 32-bit mode: register increment */ return 0; /* 64-bit mode: REX prefix */ -diff -urNp linux-3.0.9/arch/x86/kernel/syscall_table_32.S linux-3.0.9/arch/x86/kernel/syscall_table_32.S ---- linux-3.0.9/arch/x86/kernel/syscall_table_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/syscall_table_32.S 2011-11-12 12:47:13.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 restarting */ - .long sys_exit -diff -urNp linux-3.0.9/arch/x86/kernel/sys_i386_32.c linux-3.0.9/arch/x86/kernel/sys_i386_32.c ---- linux-3.0.9/arch/x86/kernel/sys_i386_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/sys_i386_32.c 2011-11-12 12:47:13.000000000 -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 @@ #include <asm/syscalls.h> @@ -15726,12 +16346,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_i386_32.c linux-3.0.9/arch/x86/kernel - const char *const argv[], - const char *const envp[]) +int i386_mmap_check(unsigned long addr, unsigned long len, unsigned long flags) - { -- long __res; -- asm volatile ("int $0x80" -- : "=a" (__res) -- : "0" (__NR_execve), "b" (filename), "c" (argv), "d" (envp) : "memory"); -- return __res; ++{ + unsigned long pax_task_size = TASK_SIZE; + +#ifdef CONFIG_PAX_SEGMEXEC @@ -15839,7 +16454,12 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_i386_32.c linux-3.0.9/arch/x86/kernel +arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, + const unsigned long len, const unsigned long pgoff, + const unsigned long flags) -+{ + { +- long __res; +- asm volatile ("int $0x80" +- : "=a" (__res) +- : "0" (__NR_execve), "b" (filename), "c" (argv), "d" (envp) : "memory"); +- return __res; + struct vm_area_struct *vma; + struct mm_struct *mm = current->mm; + unsigned long base = mm->mmap_base, addr = addr0, pax_task_size = TASK_SIZE; @@ -15951,9 +16571,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_i386_32.c linux-3.0.9/arch/x86/kernel + + return addr; } -diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/arch/x86/kernel/sys_x86_64.c ---- linux-3.0.9/arch/x86/kernel/sys_x86_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/sys_x86_64.c 2011-11-12 12:47:13.000000000 -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; } @@ -15965,7 +16586,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/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, unsigned long *begin, *begin = new_begin; } } else { @@ -15974,7 +16595,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/arch/x86/kernel/ *end = 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 long addr, if (flags & MAP_FIXED) return addr; @@ -16006,7 +16627,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/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, const unsigned long addr0, { struct vm_area_struct *vma; struct mm_struct *mm = current->mm; @@ -16015,7 +16636,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/arch/x86/kernel/ /* 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; @@ -16038,7 +16659,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/arch/x86/kernel/ } /* 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, const unsigned long addr0, /* make sure it can fit in the remaining address space */ if (addr > len) { vma = find_vma(mm, addr-len); @@ -16047,7 +16668,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/arch/x86/kernel/ /* remember the address as a hint for next time */ return mm->free_area_cache = 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, const unsigned long addr0, * return with success: */ vma = find_vma(mm, addr); @@ -16056,7 +16677,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/arch/x86/kernel/ /* remember the address as a hint for next time */ return mm->free_area_cache = addr; -@@ -188,8 +196,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -188,8 +196,8 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, mm->cached_hole_size = vma->vm_start - addr; /* try just below the current vma->vm_start */ @@ -16091,9 +16712,19 @@ diff -urNp linux-3.0.9/arch/x86/kernel/sys_x86_64.c linux-3.0.9/arch/x86/kernel/ mm->cached_hole_size = ~0UL; return addr; -diff -urNp linux-3.0.9/arch/x86/kernel/tboot.c linux-3.0.9/arch/x86/kernel/tboot.c ---- linux-3.0.9/arch/x86/kernel/tboot.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/tboot.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/syscall_table_32.S b/arch/x86/kernel/syscall_table_32.S +index fbb0a04..357e192 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 restarting */ + .long sys_exit +diff --git a/arch/x86/kernel/tboot.c b/arch/x86/kernel/tboot.c +index 30ac65d..0ace0a1 100644 +--- a/arch/x86/kernel/tboot.c ++++ b/arch/x86/kernel/tboot.c @@ -217,7 +217,7 @@ static int tboot_setup_sleep(void) void tboot_shutdown(u32 shutdown_type) @@ -16112,7 +16743,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/tboot.c linux-3.0.9/arch/x86/kernel/tboot shutdown(); /* should not reach here */ -@@ -296,7 +296,7 @@ void tboot_sleep(u8 sleep_state, u32 pm1 +@@ -296,7 +296,7 @@ void tboot_sleep(u8 sleep_state, u32 pm1a_control, u32 pm1b_control) tboot_shutdown(acpi_shutdown_map[sleep_state]); } @@ -16121,7 +16752,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/tboot.c linux-3.0.9/arch/x86/kernel/tboot static int tboot_wait_for_aps(int num_aps) { -@@ -320,9 +320,9 @@ static int __cpuinit tboot_cpu_callback( +@@ -320,9 +320,9 @@ static int __cpuinit tboot_cpu_callback(struct notifier_block *nfb, { switch (action) { case CPU_DYING: @@ -16142,10 +16773,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/tboot.c linux-3.0.9/arch/x86/kernel/tboot register_hotcpu_notifier(&tboot_cpu_notifier); return 0; } -diff -urNp linux-3.0.9/arch/x86/kernel/time.c linux-3.0.9/arch/x86/kernel/time.c ---- linux-3.0.9/arch/x86/kernel/time.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/time.c 2011-11-12 12:47:13.000000000 -0500 -@@ -30,9 +30,9 @@ unsigned long profile_pc(struct pt_regs +diff --git a/arch/x86/kernel/time.c b/arch/x86/kernel/time.c +index 00cbb27..472a348 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 = instruction_pointer(regs); @@ -16157,7 +16789,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/time.c linux-3.0.9/arch/x86/kernel/time.c #else unsigned long *sp = (unsigned long *)kernel_stack_pointer(regs); -@@ -41,11 +41,17 @@ unsigned long profile_pc(struct pt_regs +@@ -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. */ @@ -16175,10 +16807,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/time.c linux-3.0.9/arch/x86/kernel/time.c } return pc; } -diff -urNp linux-3.0.9/arch/x86/kernel/tls.c linux-3.0.9/arch/x86/kernel/tls.c ---- linux-3.0.9/arch/x86/kernel/tls.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/tls.c 2011-11-12 12:47:13.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; @@ -16190,9 +16823,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/tls.c linux-3.0.9/arch/x86/kernel/tls.c set_tls_desc(p, idx, &info, 1); return 0; -diff -urNp linux-3.0.9/arch/x86/kernel/trampoline_32.S linux-3.0.9/arch/x86/kernel/trampoline_32.S ---- linux-3.0.9/arch/x86/kernel/trampoline_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/trampoline_32.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/trampoline_32.S b/arch/x86/kernel/trampoline_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 <asm/segment.h> #include <asm/page_types.h> @@ -16215,9 +16849,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/trampoline_32.S linux-3.0.9/arch/x86/kern # 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.0.9/arch/x86/kernel/trampoline_64.S linux-3.0.9/arch/x86/kernel/trampoline_64.S ---- linux-3.0.9/arch/x86/kernel/trampoline_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/trampoline_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/trampoline_64.S b/arch/x86/kernel/trampoline_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 @@ -16236,9 +16871,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/trampoline_64.S linux-3.0.9/arch/x86/kern .long tgdt - r_base .short 0 .quad 0x00cf9b000000ffff # __KERNEL32_CS -diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps.c ---- linux-3.0.9/arch/x86/kernel/traps.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/traps.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c +index b9b6716..98109ef 100644 +--- a/arch/x86/kernel/traps.c ++++ b/arch/x86/kernel/traps.c @@ -70,12 +70,6 @@ asmlinkage int system_call(void); /* Do we ignore FPU interrupts ? */ @@ -16252,7 +16888,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps #endif 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) } static void __kprobes @@ -16268,7 +16904,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/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 @@ -16307,7 +16943,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps return; #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 error_code) conditional_sti(regs); #ifdef CONFIG_X86_32 @@ -16354,7 +16990,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps die("general protection fault", regs, error_code); } -@@ -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) { @@ -16372,7 +17008,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps nmi_enter(); 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); @@ -16381,7 +17017,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/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. */ @@ -16390,7 +17026,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps tsk->thread.debugreg6 &= ~DR_STEP; set_tsk_thread_flag(tsk, TIF_SINGLESTEP); regs->flags &= ~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); @@ -16399,7 +17035,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps { if (!fixup_exception(regs)) { task->thread.error_code = 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 = current_thread_info(); @@ -16418,9 +17054,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/traps.c linux-3.0.9/arch/x86/kernel/traps if (!tsk_used_math(tsk)) { local_irq_enable(); -diff -urNp linux-3.0.9/arch/x86/kernel/verify_cpu.S linux-3.0.9/arch/x86/kernel/verify_cpu.S ---- linux-3.0.9/arch/x86/kernel/verify_cpu.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/verify_cpu.S 2011-11-12 12:47:13.000000000 -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 @@ -16429,9 +17066,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/verify_cpu.S linux-3.0.9/arch/x86/kernel/ * * verify_cpu, returns the status of longmode and SSE in register %eax. * 0: Success 1: Failure -diff -urNp linux-3.0.9/arch/x86/kernel/vm86_32.c linux-3.0.9/arch/x86/kernel/vm86_32.c ---- linux-3.0.9/arch/x86/kernel/vm86_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/vm86_32.c 2011-11-12 12:47:13.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 <linux/ptrace.h> #include <linux/audit.h> @@ -16440,7 +17078,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vm86_32.c linux-3.0.9/arch/x86/kernel/vm8 #include <asm/uaccess.h> #include <asm/io.h> -@@ -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_regs *regs) do_exit(SIGSEGV); } @@ -16449,7 +17087,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vm86_32.c linux-3.0.9/arch/x86/kernel/vm8 current->thread.sp0 = current->thread.saved_sp0; current->thread.sysenter_cs = __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, struct pt_regs *regs) struct task_struct *tsk; int tmp, ret = -EPERM; @@ -16463,7 +17101,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vm86_32.c linux-3.0.9/arch/x86/kernel/vm8 tsk = 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; @@ -16478,7 +17116,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vm86_32.c linux-3.0.9/arch/x86/kernel/vm8 tsk = 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 *info, struct task_struct *tsk tsk->thread.saved_fs = info->regs32->fs; tsk->thread.saved_gs = get_user_gs(info->regs32); @@ -16487,7 +17125,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vm86_32.c linux-3.0.9/arch/x86/kernel/vm8 tsk->thread.sp0 = (unsigned long) &info->VM86_TSS_ESP0; if (cpu_has_sep) tsk->thread.sysenter_cs = 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, int i, goto cannot_handle; if (i == 0x21 && is_revectored(AH(regs), &KVM86->int21_revectored)) goto cannot_handle; @@ -16496,9 +17134,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vm86_32.c linux-3.0.9/arch/x86/kernel/vm8 if (get_user(segoffs, intr_ptr)) goto cannot_handle; if ((segoffs >> 16) == BIOSSEG) -diff -urNp linux-3.0.9/arch/x86/kernel/vmlinux.lds.S linux-3.0.9/arch/x86/kernel/vmlinux.lds.S ---- linux-3.0.9/arch/x86/kernel/vmlinux.lds.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/vmlinux.lds.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/vmlinux.lds.S b/arch/x86/kernel/vmlinux.lds.S +index 89aed99..597976c 100644 +--- a/arch/x86/kernel/vmlinux.lds.S ++++ b/arch/x86/kernel/vmlinux.lds.S @@ -26,6 +26,13 @@ #include <asm/page_types.h> #include <asm/cache.h> @@ -16577,7 +17216,8 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vmlinux.lds.S linux-3.0.9/arch/x86/kernel - NOTES :text :note + . += __KERNEL_TEXT_OFFSET; -+ + +- EXCEPTION_TABLE(16) :text = 0x9090 +#ifdef CONFIG_X86_32 + . = ALIGN(PAGE_SIZE); + .module.text : AT(ADDR(.module.text) - LOAD_OFFSET) { @@ -16613,8 +17253,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vmlinux.lds.S linux-3.0.9/arch/x86/kernel + + . = ALIGN(PAGE_SIZE); + NOTES :rodata :note - -- EXCEPTION_TABLE(16) :text = 0x9090 ++ + EXCEPTION_TABLE(16) :rodata #if defined(CONFIG_DEBUG_RODATA) @@ -16761,9 +17400,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vmlinux.lds.S linux-3.0.9/arch/x86/kernel "kernel image bigger than KERNEL_IMAGE_SIZE"); #ifdef CONFIG_SMP -diff -urNp linux-3.0.9/arch/x86/kernel/vsyscall_64.c linux-3.0.9/arch/x86/kernel/vsyscall_64.c ---- linux-3.0.9/arch/x86/kernel/vsyscall_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/vsyscall_64.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/vsyscall_64.c b/arch/x86/kernel/vsyscall_64.c +index 3e68218..d34500c 100644 +--- a/arch/x86/kernel/vsyscall_64.c ++++ b/arch/x86/kernel/vsyscall_64.c @@ -53,7 +53,7 @@ DEFINE_VVAR(int, vgetcpu_mode); DEFINE_VVAR(struct vsyscall_gtod_data, vsyscall_gtod_data) = { @@ -16773,7 +17413,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vsyscall_64.c linux-3.0.9/arch/x86/kernel }; void update_vsyscall_tz(void) -@@ -231,7 +231,7 @@ static long __vsyscall(3) venosys_1(void +@@ -231,7 +231,7 @@ static long __vsyscall(3) venosys_1(void) static ctl_table kernel_table2[] = { { .procname = "vsyscall64", .data = &vsyscall_gtod_data.sysctl_enabled, .maxlen = sizeof(int), @@ -16782,9 +17422,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/vsyscall_64.c linux-3.0.9/arch/x86/kernel .proc_handler = proc_dointvec }, {} }; -diff -urNp linux-3.0.9/arch/x86/kernel/x8664_ksyms_64.c linux-3.0.9/arch/x86/kernel/x8664_ksyms_64.c ---- linux-3.0.9/arch/x86/kernel/x8664_ksyms_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/x8664_ksyms_64.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kernel/x8664_ksyms_64.c b/arch/x86/kernel/x8664_ksyms_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); @@ -16794,10 +17435,11 @@ diff -urNp linux-3.0.9/arch/x86/kernel/x8664_ksyms_64.c linux-3.0.9/arch/x86/ker EXPORT_SYMBOL(copy_page); EXPORT_SYMBOL(clear_page); -diff -urNp linux-3.0.9/arch/x86/kernel/xsave.c linux-3.0.9/arch/x86/kernel/xsave.c ---- linux-3.0.9/arch/x86/kernel/xsave.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kernel/xsave.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 __user *buf, fx_sw_user->xstate_size > fx_sw_user->extended_size) return -EINVAL; @@ -16815,7 +17457,7 @@ diff -urNp linux-3.0.9/arch/x86/kernel/xsave.c linux-3.0.9/arch/x86/kernel/xsave } /* -@@ -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 = restore_user_xstate(buf); else @@ -16824,9 +17466,10 @@ diff -urNp linux-3.0.9/arch/x86/kernel/xsave.c linux-3.0.9/arch/x86/kernel/xsave buf); if (unlikely(err)) { /* -diff -urNp linux-3.0.9/arch/x86/kvm/emulate.c linux-3.0.9/arch/x86/kvm/emulate.c ---- linux-3.0.9/arch/x86/kvm/emulate.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kvm/emulate.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c +index adc9867..eb4ab62 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) @@ -16861,9 +17504,10 @@ diff -urNp linux-3.0.9/arch/x86/kvm/emulate.c linux-3.0.9/arch/x86/kvm/emulate.c switch ((_dst).bytes) { \ case 1: \ ____emulate_2op(_op,_src,_dst,_eflags,_bx,_by,"b",u8); \ -diff -urNp linux-3.0.9/arch/x86/kvm/lapic.c linux-3.0.9/arch/x86/kvm/lapic.c ---- linux-3.0.9/arch/x86/kvm/lapic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kvm/lapic.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c +index 2b2255b..38f6b7f 100644 +--- a/arch/x86/kvm/lapic.c ++++ b/arch/x86/kvm/lapic.c @@ -53,7 +53,7 @@ #define APIC_BUS_CYCLE_NS 1 @@ -16873,10 +17517,11 @@ diff -urNp linux-3.0.9/arch/x86/kvm/lapic.c linux-3.0.9/arch/x86/kvm/lapic.c #define APIC_LVT_NUM 6 /* 14 is the version for Xeon and Pentium 8.4.8*/ -diff -urNp linux-3.0.9/arch/x86/kvm/mmu.c linux-3.0.9/arch/x86/kvm/mmu.c ---- linux-3.0.9/arch/x86/kvm/mmu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kvm/mmu.c 2011-11-12 12:47:13.000000000 -0500 -@@ -3238,7 +3238,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu * +diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c +index aee3862..fcf787e 100644 +--- a/arch/x86/kvm/mmu.c ++++ b/arch/x86/kvm/mmu.c +@@ -3238,7 +3238,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu *vcpu, gpa_t gpa, pgprintk("%s: gpa %llx bytes %d\n", __func__, gpa, bytes); @@ -16885,7 +17530,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/mmu.c linux-3.0.9/arch/x86/kvm/mmu.c /* * Assume that the pte write on a page table of the same type -@@ -3270,7 +3270,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu * +@@ -3270,7 +3270,7 @@ void kvm_mmu_pte_write(struct kvm_vcpu *vcpu, gpa_t gpa, } spin_lock(&vcpu->kvm->mmu_lock); @@ -16894,9 +17539,10 @@ diff -urNp linux-3.0.9/arch/x86/kvm/mmu.c linux-3.0.9/arch/x86/kvm/mmu.c gentry = 0; kvm_mmu_free_some_pages(vcpu); ++vcpu->kvm->stat.mmu_pte_write; -diff -urNp linux-3.0.9/arch/x86/kvm/paging_tmpl.h linux-3.0.9/arch/x86/kvm/paging_tmpl.h ---- linux-3.0.9/arch/x86/kvm/paging_tmpl.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kvm/paging_tmpl.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h +index 9d03ad4..e9ee87c 100644 +--- a/arch/x86/kvm/paging_tmpl.h ++++ b/arch/x86/kvm/paging_tmpl.h @@ -182,7 +182,7 @@ walk: break; } @@ -16906,7 +17552,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/paging_tmpl.h linux-3.0.9/arch/x86/kvm/pagin if (unlikely(__copy_from_user(&pte, ptep_user, sizeof(pte)))) { present = false; break; -@@ -583,6 +583,8 @@ static int FNAME(page_fault)(struct kvm_ +@@ -583,6 +583,8 @@ static int FNAME(page_fault)(struct kvm_vcpu *vcpu, gva_t addr, u32 error_code, unsigned long mmu_seq; bool map_writable; @@ -16915,7 +17561,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/paging_tmpl.h linux-3.0.9/arch/x86/kvm/pagin pgprintk("%s: addr %lx err %x\n", __func__, addr, error_code); r = mmu_topup_memory_caches(vcpu); -@@ -703,7 +705,7 @@ static void FNAME(invlpg)(struct kvm_vcp +@@ -703,7 +705,7 @@ static void FNAME(invlpg)(struct kvm_vcpu *vcpu, gva_t gva) if (need_flush) kvm_flush_remote_tlbs(vcpu->kvm); @@ -16924,10 +17570,11 @@ diff -urNp linux-3.0.9/arch/x86/kvm/paging_tmpl.h linux-3.0.9/arch/x86/kvm/pagin spin_unlock(&vcpu->kvm->mmu_lock); -diff -urNp linux-3.0.9/arch/x86/kvm/svm.c linux-3.0.9/arch/x86/kvm/svm.c ---- linux-3.0.9/arch/x86/kvm/svm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kvm/svm.c 2011-11-12 12:47:13.000000000 -0500 -@@ -3377,7 +3377,11 @@ static void reload_tss(struct kvm_vcpu * +diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c +index 506e4fe..e947b49 100644 +--- a/arch/x86/kvm/svm.c ++++ b/arch/x86/kvm/svm.c +@@ -3377,7 +3377,11 @@ static void reload_tss(struct kvm_vcpu *vcpu) int cpu = raw_smp_processor_id(); struct svm_cpu_data *sd = per_cpu(svm_data, cpu); @@ -16939,7 +17586,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/svm.c linux-3.0.9/arch/x86/kvm/svm.c load_TR_desc(); } -@@ -3755,6 +3759,10 @@ static void svm_vcpu_run(struct kvm_vcpu +@@ -3755,6 +3759,10 @@ static void svm_vcpu_run(struct kvm_vcpu *vcpu) #endif #endif @@ -16950,9 +17597,10 @@ diff -urNp linux-3.0.9/arch/x86/kvm/svm.c linux-3.0.9/arch/x86/kvm/svm.c reload_tss(vcpu); local_irq_disable(); -diff -urNp linux-3.0.9/arch/x86/kvm/vmx.c linux-3.0.9/arch/x86/kvm/vmx.c ---- linux-3.0.9/arch/x86/kvm/vmx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kvm/vmx.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c +index d48ec60..21f490a 100644 +--- a/arch/x86/kvm/vmx.c ++++ b/arch/x86/kvm/vmx.c @@ -797,7 +797,11 @@ static void reload_tss(void) struct desc_struct *descs; @@ -16979,7 +17627,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/vmx.c linux-3.0.9/arch/x86/kvm/vmx.c if (enable_ept && !cpu_has_vmx_ept_2m_page()) kvm_disable_largepages(); -@@ -2814,7 +2821,7 @@ static int vmx_vcpu_setup(struct vcpu_vm +@@ -2814,7 +2821,7 @@ static int vmx_vcpu_setup(struct vcpu_vmx *vmx) vmcs_writel(HOST_IDTR_BASE, dt.address); /* 22.2.4 */ asm("mov $.Lkvm_vmx_return, %0" : "=r"(kvm_vmx_return)); @@ -16988,7 +17636,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/vmx.c linux-3.0.9/arch/x86/kvm/vmx.c vmcs_write32(VM_EXIT_MSR_STORE_COUNT, 0); vmcs_write32(VM_EXIT_MSR_LOAD_COUNT, 0); vmcs_write64(VM_EXIT_MSR_LOAD_ADDR, __pa(vmx->msr_autoload.host)); -@@ -4211,6 +4218,12 @@ static void __noclone vmx_vcpu_run(struc +@@ -4211,6 +4218,12 @@ static void __noclone vmx_vcpu_run(struct kvm_vcpu *vcpu) "jmp .Lkvm_vmx_return \n\t" ".Llaunched: " __ex(ASM_VMX_VMRESUME) "\n\t" ".Lkvm_vmx_return: " @@ -17001,7 +17649,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/vmx.c linux-3.0.9/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" -@@ -4259,6 +4272,11 @@ static void __noclone vmx_vcpu_run(struc +@@ -4259,6 +4272,11 @@ static void __noclone vmx_vcpu_run(struct kvm_vcpu *vcpu) #endif [cr2]"i"(offsetof(struct vcpu_vmx, vcpu.arch.cr2)), [wordsize]"i"(sizeof(ulong)) @@ -17013,7 +17661,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/vmx.c linux-3.0.9/arch/x86/kvm/vmx.c : "cc", "memory" , R"ax", R"bx", R"di", R"si" #ifdef CONFIG_X86_64 -@@ -4276,7 +4294,16 @@ static void __noclone vmx_vcpu_run(struc +@@ -4276,7 +4294,16 @@ static void __noclone vmx_vcpu_run(struct kvm_vcpu *vcpu) vmx->idt_vectoring_info = vmcs_read32(IDT_VECTORING_INFO_FIELD); @@ -17031,10 +17679,11 @@ diff -urNp linux-3.0.9/arch/x86/kvm/vmx.c linux-3.0.9/arch/x86/kvm/vmx.c vmx->launched = 1; vmx->exit_reason = vmcs_read32(VM_EXIT_REASON); -diff -urNp linux-3.0.9/arch/x86/kvm/x86.c linux-3.0.9/arch/x86/kvm/x86.c ---- linux-3.0.9/arch/x86/kvm/x86.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/kvm/x86.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1313,8 +1313,8 @@ static int xen_hvm_config(struct kvm_vcp +diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c +index 77c9d86..3562941 100644 +--- a/arch/x86/kvm/x86.c ++++ b/arch/x86/kvm/x86.c +@@ -1313,8 +1313,8 @@ static int xen_hvm_config(struct kvm_vcpu *vcpu, u64 data) { struct kvm *kvm = vcpu->kvm; int lm = is_long_mode(vcpu); @@ -17045,7 +17694,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/x86.c linux-3.0.9/arch/x86/kvm/x86.c u8 blob_size = lm ? kvm->arch.xen_hvm_config.blob_size_64 : kvm->arch.xen_hvm_config.blob_size_32; u32 page_num = data & ~PAGE_MASK; -@@ -2057,6 +2057,8 @@ long kvm_arch_dev_ioctl(struct file *fil +@@ -2057,6 +2057,8 @@ long kvm_arch_dev_ioctl(struct file *filp, if (n < msr_list.nmsrs) goto out; r = -EFAULT; @@ -17054,7 +17703,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/x86.c linux-3.0.9/arch/x86/kvm/x86.c if (copy_to_user(user_msr_list->indices, &msrs_to_save, num_msrs_to_save * sizeof(u32))) goto out; -@@ -2229,15 +2231,20 @@ static int kvm_vcpu_ioctl_set_cpuid2(str +@@ -2229,15 +2231,20 @@ static int kvm_vcpu_ioctl_set_cpuid2(struct kvm_vcpu *vcpu, struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 __user *entries) { @@ -17078,7 +17727,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/x86.c linux-3.0.9/arch/x86/kvm/x86.c vcpu->arch.cpuid_nent = cpuid->nent; kvm_apic_set_version(vcpu); kvm_x86_ops->cpuid_update(vcpu); -@@ -2252,15 +2259,19 @@ static int kvm_vcpu_ioctl_get_cpuid2(str +@@ -2252,15 +2259,19 @@ static int kvm_vcpu_ioctl_get_cpuid2(struct kvm_vcpu *vcpu, struct kvm_cpuid2 *cpuid, struct kvm_cpuid_entry2 __user *entries) { @@ -17101,7 +17750,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/x86.c linux-3.0.9/arch/x86/kvm/x86.c return 0; out: -@@ -2579,7 +2590,7 @@ static int kvm_vcpu_ioctl_set_lapic(stru +@@ -2579,7 +2590,7 @@ static int kvm_vcpu_ioctl_set_lapic(struct kvm_vcpu *vcpu, static int kvm_vcpu_ioctl_interrupt(struct kvm_vcpu *vcpu, struct kvm_interrupt *irq) { @@ -17110,7 +17759,7 @@ diff -urNp linux-3.0.9/arch/x86/kvm/x86.c linux-3.0.9/arch/x86/kvm/x86.c return -EINVAL; if (irqchip_in_kernel(vcpu->kvm)) return -ENXIO; -@@ -4878,7 +4889,7 @@ void kvm_after_handle_nmi(struct kvm_vcp +@@ -4878,7 +4889,7 @@ void kvm_after_handle_nmi(struct kvm_vcpu *vcpu) } EXPORT_SYMBOL_GPL(kvm_after_handle_nmi); @@ -17119,10 +17768,11 @@ diff -urNp linux-3.0.9/arch/x86/kvm/x86.c linux-3.0.9/arch/x86/kvm/x86.c { int r; struct kvm_x86_ops *ops = (struct kvm_x86_ops *)opaque; -diff -urNp linux-3.0.9/arch/x86/lguest/boot.c linux-3.0.9/arch/x86/lguest/boot.c ---- linux-3.0.9/arch/x86/lguest/boot.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lguest/boot.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1176,9 +1176,10 @@ static __init int early_put_chars(u32 vt +diff --git a/arch/x86/lguest/boot.c b/arch/x86/lguest/boot.c +index db832fd..7e9e620 100644 +--- a/arch/x86/lguest/boot.c ++++ b/arch/x86/lguest/boot.c +@@ -1176,9 +1176,10 @@ static __init int early_put_chars(u32 vtermno, const char *buf, int count) * Rebooting also tells the Host we're finished, but the RESTART flag tells the * Launcher to reboot us. */ @@ -17134,9 +17784,10 @@ diff -urNp linux-3.0.9/arch/x86/lguest/boot.c linux-3.0.9/arch/x86/lguest/boot.c } /*G:050 -diff -urNp linux-3.0.9/arch/x86/lib/atomic64_32.c linux-3.0.9/arch/x86/lib/atomic64_32.c ---- linux-3.0.9/arch/x86/lib/atomic64_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/atomic64_32.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/atomic64_32.c b/arch/x86/lib/atomic64_32.c +index 540179e..e9ff0ea 100644 +--- a/arch/x86/lib/atomic64_32.c ++++ b/arch/x86/lib/atomic64_32.c @@ -8,18 +8,30 @@ long long atomic64_read_cx8(long long, const atomic64_t *v); @@ -17215,9 +17866,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/atomic64_32.c linux-3.0.9/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.0.9/arch/x86/lib/atomic64_386_32.S linux-3.0.9/arch/x86/lib/atomic64_386_32.S ---- linux-3.0.9/arch/x86/lib/atomic64_386_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/atomic64_386_32.S 2011-11-12 12:47:13.000000000 -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 @@ -17473,9 +18125,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/atomic64_386_32.S linux-3.0.9/arch/x86/lib/a js 1f movl %eax, (v) movl %edx, 4(v) -diff -urNp linux-3.0.9/arch/x86/lib/atomic64_cx8_32.S linux-3.0.9/arch/x86/lib/atomic64_cx8_32.S ---- linux-3.0.9/arch/x86/lib/atomic64_cx8_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/atomic64_cx8_32.S 2011-11-12 12:47:13.000000000 -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 @@ -17697,9 +18350,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/atomic64_cx8_32.S linux-3.0.9/arch/x86/lib/a ret 4: testl %edx, %edx -diff -urNp linux-3.0.9/arch/x86/lib/checksum_32.S linux-3.0.9/arch/x86/lib/checksum_32.S ---- linux-3.0.9/arch/x86/lib/checksum_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/checksum_32.S 2011-11-12 12:47:13.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 <linux/linkage.h> #include <asm/dwarf2.h> @@ -17710,7 +18364,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/checksum_32.S linux-3.0.9/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, #define ARGBASE 16 #define FP 12 @@ -17944,9 +18598,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/checksum_32.S linux-3.0.9/arch/x86/lib/check #undef ROUND #undef ROUND1 -diff -urNp linux-3.0.9/arch/x86/lib/clear_page_64.S linux-3.0.9/arch/x86/lib/clear_page_64.S ---- linux-3.0.9/arch/x86/lib/clear_page_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/clear_page_64.S 2011-11-12 12:47:13.000000000 -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 @@ -17980,9 +18635,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/clear_page_64.S linux-3.0.9/arch/x86/lib/cle 1: .byte 0xeb /* jmp <disp8> */ .byte (clear_page_c - clear_page) - (2f - 1b) /* offset */ 2: .byte 0xeb /* jmp <disp8> */ -diff -urNp linux-3.0.9/arch/x86/lib/cmpxchg16b_emu.S linux-3.0.9/arch/x86/lib/cmpxchg16b_emu.S ---- linux-3.0.9/arch/x86/lib/cmpxchg16b_emu.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/cmpxchg16b_emu.S 2011-11-12 12:47:13.000000000 -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: popf @@ -17997,9 +18653,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/cmpxchg16b_emu.S linux-3.0.9/arch/x86/lib/cm ret CFI_ENDPROC -diff -urNp linux-3.0.9/arch/x86/lib/copy_page_64.S linux-3.0.9/arch/x86/lib/copy_page_64.S ---- linux-3.0.9/arch/x86/lib/copy_page_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/copy_page_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/copy_page_64.S b/arch/x86/lib/copy_page_64.S +index 6fec2d1..f162fee 100644 +--- a/arch/x86/lib/copy_page_64.S ++++ b/arch/x86/lib/copy_page_64.S @@ -2,12 +2,14 @@ #include <linux/linkage.h> @@ -18032,9 +18689,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/copy_page_64.S linux-3.0.9/arch/x86/lib/copy 1: .byte 0xeb /* jmp <disp8> */ .byte (copy_page_c - copy_page) - (2f - 1b) /* offset */ 2: -diff -urNp linux-3.0.9/arch/x86/lib/copy_user_64.S linux-3.0.9/arch/x86/lib/copy_user_64.S ---- linux-3.0.9/arch/x86/lib/copy_user_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/copy_user_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/copy_user_64.S b/arch/x86/lib/copy_user_64.S +index 0248402..416b737 100644 +--- a/arch/x86/lib/copy_user_64.S ++++ b/arch/x86/lib/copy_user_64.S @@ -16,6 +16,7 @@ #include <asm/thread_info.h> #include <asm/cpufeature.h> @@ -18127,9 +18785,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/copy_user_64.S linux-3.0.9/arch/x86/lib/copy ret .section .fixup,"ax" -diff -urNp linux-3.0.9/arch/x86/lib/copy_user_nocache_64.S linux-3.0.9/arch/x86/lib/copy_user_nocache_64.S ---- linux-3.0.9/arch/x86/lib/copy_user_nocache_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/copy_user_nocache_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/copy_user_nocache_64.S b/arch/x86/lib/copy_user_nocache_64.S +index cb0c112..8433392 100644 +--- a/arch/x86/lib/copy_user_nocache_64.S ++++ b/arch/x86/lib/copy_user_nocache_64.S @@ -8,12 +8,14 @@ #include <linux/linkage.h> @@ -18169,9 +18828,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/copy_user_nocache_64.S linux-3.0.9/arch/x86/ ret .section .fixup,"ax" -diff -urNp linux-3.0.9/arch/x86/lib/csum-copy_64.S linux-3.0.9/arch/x86/lib/csum-copy_64.S ---- linux-3.0.9/arch/x86/lib/csum-copy_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/csum-copy_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/csum-copy_64.S b/arch/x86/lib/csum-copy_64.S +index fb903b7..dd8c022 100644 +--- a/arch/x86/lib/csum-copy_64.S ++++ b/arch/x86/lib/csum-copy_64.S @@ -8,6 +8,7 @@ #include <linux/linkage.h> #include <asm/dwarf2.h> @@ -18188,10 +18848,11 @@ diff -urNp linux-3.0.9/arch/x86/lib/csum-copy_64.S linux-3.0.9/arch/x86/lib/csum ret CFI_RESTORE_STATE -diff -urNp linux-3.0.9/arch/x86/lib/csum-wrappers_64.c linux-3.0.9/arch/x86/lib/csum-wrappers_64.c ---- linux-3.0.9/arch/x86/lib/csum-wrappers_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/csum-wrappers_64.c 2011-11-12 12:47:13.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-wrappers_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, void *dst, len -= 2; } } @@ -18206,7 +18867,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/csum-wrappers_64.c linux-3.0.9/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 __user *dst, } *errp = 0; @@ -18221,9 +18882,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/csum-wrappers_64.c linux-3.0.9/arch/x86/lib/ len, isum, NULL, errp); } EXPORT_SYMBOL(csum_partial_copy_to_user); -diff -urNp linux-3.0.9/arch/x86/lib/getuser.S linux-3.0.9/arch/x86/lib/getuser.S ---- linux-3.0.9/arch/x86/lib/getuser.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/getuser.S 2011-11-12 12:47:13.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 <asm/asm-offsets.h> #include <asm/thread_info.h> @@ -18347,9 +19009,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/getuser.S linux-3.0.9/arch/x86/lib/getuser.S ret CFI_ENDPROC END(bad_get_user) -diff -urNp linux-3.0.9/arch/x86/lib/insn.c linux-3.0.9/arch/x86/lib/insn.c ---- linux-3.0.9/arch/x86/lib/insn.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/insn.c 2011-11-12 12:47:13.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 <linux/string.h> #include <asm/inat.h> @@ -18373,9 +19036,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/insn.c linux-3.0.9/arch/x86/lib/insn.c insn->x86_64 = x86_64 ? 1 : 0; insn->opnd_bytes = 4; if (x86_64) -diff -urNp linux-3.0.9/arch/x86/lib/iomap_copy_64.S linux-3.0.9/arch/x86/lib/iomap_copy_64.S ---- linux-3.0.9/arch/x86/lib/iomap_copy_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/iomap_copy_64.S 2011-11-12 12:47:13.000000000 -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 @@ #include <linux/linkage.h> @@ -18392,9 +19056,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/iomap_copy_64.S linux-3.0.9/arch/x86/lib/iom ret CFI_ENDPROC ENDPROC(__iowrite32_copy) -diff -urNp linux-3.0.9/arch/x86/lib/memcpy_64.S linux-3.0.9/arch/x86/lib/memcpy_64.S ---- linux-3.0.9/arch/x86/lib/memcpy_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/memcpy_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/memcpy_64.S b/arch/x86/lib/memcpy_64.S +index efbf2a0..8090894 100644 +--- a/arch/x86/lib/memcpy_64.S ++++ b/arch/x86/lib/memcpy_64.S @@ -34,6 +34,7 @@ rep movsq movl %edx, %ecx @@ -18443,9 +19108,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/memcpy_64.S linux-3.0.9/arch/x86/lib/memcpy_ retq CFI_ENDPROC ENDPROC(memcpy) -diff -urNp linux-3.0.9/arch/x86/lib/memmove_64.S linux-3.0.9/arch/x86/lib/memmove_64.S ---- linux-3.0.9/arch/x86/lib/memmove_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/memmove_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/memmove_64.S b/arch/x86/lib/memmove_64.S +index d0ec9c2..e5d0a9f 100644 +--- a/arch/x86/lib/memmove_64.S ++++ b/arch/x86/lib/memmove_64.S @@ -9,6 +9,7 @@ #include <linux/linkage.h> #include <asm/dwarf2.h> @@ -18470,9 +19136,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/memmove_64.S linux-3.0.9/arch/x86/lib/memmov retq .Lmemmove_end_forward_efs: .previous -diff -urNp linux-3.0.9/arch/x86/lib/memset_64.S linux-3.0.9/arch/x86/lib/memset_64.S ---- linux-3.0.9/arch/x86/lib/memset_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/memset_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/memset_64.S b/arch/x86/lib/memset_64.S +index 79bd454..24b3780 100644 +--- a/arch/x86/lib/memset_64.S ++++ b/arch/x86/lib/memset_64.S @@ -31,6 +31,7 @@ movl %r8d,%ecx rep stosb @@ -18497,10 +19164,11 @@ diff -urNp linux-3.0.9/arch/x86/lib/memset_64.S linux-3.0.9/arch/x86/lib/memset_ ret CFI_RESTORE_STATE -diff -urNp linux-3.0.9/arch/x86/lib/mmx_32.c linux-3.0.9/arch/x86/lib/mmx_32.c ---- linux-3.0.9/arch/x86/lib/mmx_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/mmx_32.c 2011-11-12 12:47:13.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 len) { void *p; int i; @@ -18508,7 +19176,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/mmx_32.c linux-3.0.9/arch/x86/lib/mmx_32.c 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(); __asm__ __volatile__ ( @@ -18615,7 +19283,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/mmx_32.c linux-3.0.9/arch/x86/lib/mmx_32.c kernel_fpu_begin(); -@@ -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__( @@ -18815,9 +19483,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/mmx_32.c linux-3.0.9/arch/x86/lib/mmx_32.c from += 64; to += 64; -diff -urNp linux-3.0.9/arch/x86/lib/msr-reg.S linux-3.0.9/arch/x86/lib/msr-reg.S ---- linux-3.0.9/arch/x86/lib/msr-reg.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/msr-reg.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/msr-reg.S b/arch/x86/lib/msr-reg.S +index 69fa106..234ac7f 100644 +--- a/arch/x86/lib/msr-reg.S ++++ b/arch/x86/lib/msr-reg.S @@ -3,6 +3,7 @@ #include <asm/dwarf2.h> #include <asm/asm.h> @@ -18834,9 +19503,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/msr-reg.S linux-3.0.9/arch/x86/lib/msr-reg.S ret 3: CFI_RESTORE_STATE -diff -urNp linux-3.0.9/arch/x86/lib/putuser.S linux-3.0.9/arch/x86/lib/putuser.S ---- linux-3.0.9/arch/x86/lib/putuser.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/putuser.S 2011-11-12 12:47:13.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 <asm/thread_info.h> #include <asm/errno.h> @@ -18976,9 +19646,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/putuser.S linux-3.0.9/arch/x86/lib/putuser.S #endif xor %eax,%eax EXIT -diff -urNp linux-3.0.9/arch/x86/lib/rwlock_64.S linux-3.0.9/arch/x86/lib/rwlock_64.S ---- linux-3.0.9/arch/x86/lib/rwlock_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/rwlock_64.S 2011-11-12 12:47:13.000000000 -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) @@ -18995,9 +19666,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/rwlock_64.S linux-3.0.9/arch/x86/lib/rwlock_ ret CFI_ENDPROC END(__read_lock_failed) -diff -urNp linux-3.0.9/arch/x86/lib/rwsem_64.S linux-3.0.9/arch/x86/lib/rwsem_64.S ---- linux-3.0.9/arch/x86/lib/rwsem_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/rwsem_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/rwsem_64.S b/arch/x86/lib/rwsem_64.S +index 6774397..79f43de 100644 +--- a/arch/x86/lib/rwsem_64.S ++++ b/arch/x86/lib/rwsem_64.S @@ -51,6 +51,7 @@ ENTRY(call_rwsem_down_read_failed) popq_cfi %rdx CFI_RESTORE rdx @@ -19032,9 +19704,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/rwsem_64.S linux-3.0.9/arch/x86/lib/rwsem_64 ret CFI_ENDPROC ENDPROC(call_rwsem_downgrade_wake) -diff -urNp linux-3.0.9/arch/x86/lib/thunk_64.S linux-3.0.9/arch/x86/lib/thunk_64.S ---- linux-3.0.9/arch/x86/lib/thunk_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/thunk_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/lib/thunk_64.S b/arch/x86/lib/thunk_64.S +index 782b082..d3b6318 100644 +--- a/arch/x86/lib/thunk_64.S ++++ b/arch/x86/lib/thunk_64.S @@ -10,7 +10,8 @@ #include <asm/dwarf2.h> #include <asm/calling.h> @@ -19053,9 +19726,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/thunk_64.S linux-3.0.9/arch/x86/lib/thunk_64 + pax_force_retaddr + ret CFI_ENDPROC -diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/arch/x86/lib/usercopy_32.c ---- linux-3.0.9/arch/x86/lib/usercopy_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/usercopy_32.c 2011-11-12 12:47:13.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" \ @@ -19078,7 +19752,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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, +@@ -200,6 +202,7 @@ long strnlen_user(const char __user *s, long n) might_fault(); __asm__ __volatile__( @@ -19086,7 +19760,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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, +@@ -208,6 +211,7 @@ long strnlen_user(const char __user *s, long n) " subl %%ecx,%0\n" " addl %0,%%eax\n" "1:\n" @@ -19103,7 +19777,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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 *from, unsigned long size) " .align 2,0x90\n" "3: movl 0(%4), %%eax\n" "4: movl 4(%4), %%edx\n" @@ -19156,7 +19830,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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 *from, unsigned long size) " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -19276,7 +19950,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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 __user *from, unsigned long size) int d0, d1; __asm__ __volatile__( " .align 2,0x90\n" @@ -19336,7 +20010,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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 __user *from, unsigned long size) " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -19348,7 +20022,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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_nocache(void *to, __asm__ __volatile__( " .align 2,0x90\n" @@ -19408,7 +20082,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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_nocache(void *to, " shrl $2, %0\n" " andl $3, %%eax\n" " cld\n" @@ -19420,7 +20094,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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(void *to, __asm__ __volatile__( " .align 2,0x90\n" @@ -19480,7 +20154,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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" @@ -19492,7 +20166,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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(void *to, */ unsigned long __copy_user_zeroing_intel(void *to, const void __user *from, unsigned long size); @@ -19564,7 +20238,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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)) @@ -19577,7 +20251,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/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(void *to, const void __user *fr if (n > 64 && cpu_has_xmm2) n = __copy_user_intel_nocache(to, from, n); else @@ -19676,9 +20350,10 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_32.c linux-3.0.9/arch/x86/lib/userc +} +EXPORT_SYMBOL(set_fs); +#endif -diff -urNp linux-3.0.9/arch/x86/lib/usercopy_64.c linux-3.0.9/arch/x86/lib/usercopy_64.c ---- linux-3.0.9/arch/x86/lib/usercopy_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/lib/usercopy_64.c 2011-11-12 12:47:13.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) { @@ -19692,7 +20367,7 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_64.c linux-3.0.9/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, unsigned long size) { long __d0; might_fault(); @@ -19737,34 +20412,11 @@ diff -urNp linux-3.0.9/arch/x86/lib/usercopy_64.c linux-3.0.9/arch/x86/lib/userc { char c; unsigned zero_len; -diff -urNp linux-3.0.9/arch/x86/Makefile linux-3.0.9/arch/x86/Makefile ---- linux-3.0.9/arch/x86/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/Makefile 2011-11-12 12:47:13.000000000 -0500 -@@ -44,6 +44,7 @@ ifeq ($(CONFIG_X86_32),y) - else - BITS := 64 - UTS_MACHINE := x86_64 -+ biarch := $(call cc-option,-m64) - CHECKFLAGS += -D__x86_64__ -m64 - - KBUILD_AFLAGS += -m64 -@@ -195,3 +196,12 @@ define archhelp - echo ' FDARGS="..." arguments for the booted kernel' - echo ' FDINITRD=file 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.0.9/arch/x86/mm/extable.c linux-3.0.9/arch/x86/mm/extable.c ---- linux-3.0.9/arch/x86/mm/extable.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/extable.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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; #ifdef CONFIG_PNPBIOS @@ -19773,9 +20425,10 @@ diff -urNp linux-3.0.9/arch/x86/mm/extable.c linux-3.0.9/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 = 1; -diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c ---- linux-3.0.9/arch/x86/mm/fault.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/fault.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c +index 2dbf6bf..4a744ee 100644 +--- a/arch/x86/mm/fault.c ++++ b/arch/x86/mm/fault.c @@ -13,10 +13,18 @@ #include <linux/perf_event.h> /* perf_sw_event */ #include <linux/hugetlb.h> /* hstate_index_to_shift */ @@ -19795,7 +20448,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c /* * Page fault error code bits: -@@ -54,7 +62,7 @@ static inline int __kprobes notify_page_ +@@ -54,7 +62,7 @@ static inline int __kprobes notify_page_fault(struct pt_regs *regs) int ret = 0; /* kprobe_running() needs smp_processor_id() */ @@ -19804,7 +20457,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c preempt_disable(); if (kprobe_running() && kprobe_fault_handler(regs, 14)) ret = 1; -@@ -115,7 +123,10 @@ check_prefetch_opcode(struct pt_regs *re +@@ -115,7 +123,10 @@ check_prefetch_opcode(struct pt_regs *regs, unsigned char *instr, return !instr_lo || (instr_lo>>1) == 1; case 0x00: /* Prefetch instruction is 0x0F0D or 0x0F18 */ @@ -19816,7 +20469,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c return 0; *prefetch = (instr_lo == 0xF) && -@@ -149,7 +160,10 @@ is_prefetch(struct pt_regs *regs, unsign +@@ -149,7 +160,10 @@ is_prefetch(struct pt_regs *regs, unsigned long error_code, unsigned long addr) while (instr < max_instr) { unsigned char opcode; @@ -19828,7 +20481,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c break; instr++; -@@ -180,6 +194,30 @@ force_sig_info_fault(int si_signo, int s +@@ -180,6 +194,30 @@ force_sig_info_fault(int si_signo, int si_code, unsigned long address, force_sig_info(si_signo, &info, tsk); } @@ -19897,7 +20550,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c if (!ret) break; -@@ -276,6 +331,11 @@ static noinline __kprobes int vmalloc_fa +@@ -276,6 +331,11 @@ static noinline __kprobes int vmalloc_fault(unsigned long address) * an interrupt in the middle of a task switch.. */ pgd_paddr = read_cr3(); @@ -19909,7 +20562,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c pmd_k = vmalloc_sync_one(__va(pgd_paddr), address); if (!pmd_k) return -1; -@@ -371,7 +431,14 @@ static noinline __kprobes int vmalloc_fa +@@ -371,7 +431,14 @@ static noinline __kprobes int vmalloc_fault(unsigned long address) * happen within a race in page table update. In the later * case just flush: */ @@ -19924,7 +20577,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c pgd_ref = pgd_offset_k(address); if (pgd_none(*pgd_ref)) return -1; -@@ -533,7 +600,7 @@ static int is_errata93(struct pt_regs *r +@@ -533,7 +600,7 @@ static int is_errata93(struct pt_regs *regs, unsigned long address) static int is_errata100(struct pt_regs *regs, unsigned long address) { #ifdef CONFIG_X86_64 @@ -19933,7 +20586,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c return 1; #endif return 0; -@@ -560,7 +627,7 @@ static int is_f00f_bug(struct pt_regs *r +@@ -560,7 +627,7 @@ static int is_f00f_bug(struct pt_regs *regs, unsigned long address) } static const char nx_warning[] = KERN_CRIT @@ -19942,7 +20595,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c static void show_fault_oops(struct pt_regs *regs, unsigned long error_code, -@@ -569,14 +636,25 @@ show_fault_oops(struct pt_regs *regs, un +@@ -569,14 +636,25 @@ show_fault_oops(struct pt_regs *regs, unsigned long error_code, if (!oops_may_print()) return; @@ -19970,7 +20623,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c printk(KERN_ALERT "BUG: unable to handle kernel "); if (address < PAGE_SIZE) -@@ -702,6 +780,66 @@ __bad_area_nosemaphore(struct pt_regs *r +@@ -702,6 +780,66 @@ __bad_area_nosemaphore(struct pt_regs *regs, unsigned long error_code, unsigned long address, int si_code) { struct task_struct *tsk = current; @@ -20037,7 +20690,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c /* User mode accesses just cause a SIGSEGV */ if (error_code & PF_USER) { -@@ -871,6 +1009,99 @@ static int spurious_fault_check(unsigned +@@ -871,6 +1009,99 @@ static int spurious_fault_check(unsigned long error_code, pte_t *pte) return 1; } @@ -20147,7 +20800,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c if (error_code & PF_WRITE) { /* write, present and write, not present: */ if (unlikely(!(vma->vm_flags & VM_WRITE))) -@@ -976,19 +1210,33 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -976,19 +1210,33 @@ do_page_fault(struct pt_regs *regs, unsigned long error_code) { struct vm_area_struct *vma; struct task_struct *tsk; @@ -20185,7 +20838,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/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. -@@ -1048,7 +1296,7 @@ do_page_fault(struct pt_regs *regs, unsi +@@ -1048,7 +1296,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: */ @@ -20442,10 +21095,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/fault.c linux-3.0.9/arch/x86/mm/fault.c + + return ret ? -EFAULT : 0; +} -diff -urNp linux-3.0.9/arch/x86/mm/gup.c linux-3.0.9/arch/x86/mm/gup.c ---- linux-3.0.9/arch/x86/mm/gup.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/gup.c 2011-11-12 12:47:13.000000000 -0500 -@@ -253,7 +253,7 @@ int __get_user_pages_fast(unsigned long +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 nr_pages, int write, addr = start; len = (unsigned long) nr_pages << PAGE_SHIFT; end = start + len; @@ -20454,10 +21108,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/gup.c linux-3.0.9/arch/x86/mm/gup.c (void __user *)start, len))) return 0; -diff -urNp linux-3.0.9/arch/x86/mm/highmem_32.c linux-3.0.9/arch/x86/mm/highmem_32.c ---- linux-3.0.9/arch/x86/mm/highmem_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/highmem_32.c 2011-11-12 12:47:13.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 prot) idx = type + KM_TYPE_NR*smp_processor_id(); vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); BUG_ON(!pte_none(*(kmap_pte-idx))); @@ -20468,10 +21123,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/highmem_32.c linux-3.0.9/arch/x86/mm/highmem_ return (void *)vaddr; } -diff -urNp linux-3.0.9/arch/x86/mm/hugetlbpage.c linux-3.0.9/arch/x86/mm/hugetlbpage.c ---- linux-3.0.9/arch/x86/mm/hugetlbpage.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/hugetlbpage.c 2011-11-12 12:47:13.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_bottomup(struct file *file, struct hstate *h = hstate_file(file); struct mm_struct *mm = current->mm; struct vm_area_struct *vma; @@ -20531,7 +21187,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/hugetlbpage.c linux-3.0.9/arch/x86/mm/hugetlb } static unsigned long hugetlb_get_unmapped_area_topdown(struct file *file, -@@ -308,10 +316,9 @@ static unsigned long hugetlb_get_unmappe +@@ -308,10 +316,9 @@ static unsigned long hugetlb_get_unmapped_area_topdown(struct file *file, { struct hstate *h = hstate_file(file); struct mm_struct *mm = current->mm; @@ -20544,7 +21200,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/hugetlbpage.c linux-3.0.9/arch/x86/mm/hugetlb /* 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_topdown(struct file *file, largest_hole = 0; mm->free_area_cache = base; } @@ -20647,7 +21303,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/hugetlbpage.c linux-3.0.9/arch/x86/mm/hugetlb mm->free_area_cache = base; mm->cached_hole_size = ~0UL; -@@ -399,10 +406,19 @@ hugetlb_get_unmapped_area(struct file *f +@@ -399,10 +406,19 @@ hugetlb_get_unmapped_area(struct file *file, unsigned long addr, struct hstate *h = hstate_file(file); struct mm_struct *mm = current->mm; struct vm_area_struct *vma; @@ -20668,7 +21324,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/hugetlbpage.c linux-3.0.9/arch/x86/mm/hugetlb return -ENOMEM; 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, unsigned long addr, if (addr) { addr = ALIGN(addr, huge_page_size(h)); vma = find_vma(mm, addr); @@ -20678,9 +21334,146 @@ diff -urNp linux-3.0.9/arch/x86/mm/hugetlbpage.c linux-3.0.9/arch/x86/mm/hugetlb return addr; } if (mm->get_unmapped_area == arch_get_unmapped_area) -diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/arch/x86/mm/init_32.c ---- linux-3.0.9/arch/x86/mm/init_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/init_32.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/mm/init.c b/arch/x86/mm/init.c +index 87488b9..9ee65f6 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_pse, + int use_gbpages) + { +- unsigned long puds, pmds, ptes, tables, start = 0, good_end = end; ++ unsigned long puds, pmds, ptes, tables, start = 0x100000, good_end = end; + phys_addr_t base; + + puds = (end + PUD_SIZE - 1) >> PUD_SHIFT; +@@ -312,12 +312,34 @@ unsigned long __init_refok init_memory_mapping(unsigned long start, + */ + int devmem_is_allowed(unsigned long pagenr) + { +- if (pagenr <= 256) ++#ifdef CONFIG_GRKERNSEC_KMEM ++ /* allow BDA */ ++ if (!pagenr) ++ return 1; ++ /* allow EBDA */ ++ if ((0x9f000 >> PAGE_SHIFT) == 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) <= pagenr && pagenr < (ISA_END_ADDRESS >> PAGE_SHIFT)) + return 1; ++#ifdef CONFIG_GRKERNSEC_KMEM ++ /* throw out everything else below 1MB */ ++ if (pagenr <= 256) ++ return 0; ++#endif + if (iomem_is_exclusive(pagenr << PAGE_SHIFT)) + return 0; + if (!page_is_ram(pagenr)) + return 1; ++ + return 0; + } + +@@ -372,6 +394,86 @@ void free_init_pages(char *what, unsigned long begin, unsigned long end) + + 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 = paravirt_enabled() ? ktva_ktla(0xffffffff) : (unsigned long)&_etext; ++ limit = (limit - 1UL) >> PAGE_SHIFT; ++ ++ memset(__LOAD_PHYSICAL_ADDR + PAGE_OFFSET, POISON_FREE_INITMEM, PAGE_SIZE); ++ for (cpu = 0; cpu < NR_CPUS; cpu++) { ++ pack_descriptor(&d, get_desc_base(&get_cpu_gdt_table(cpu)[GDT_ENTRY_KERNEL_CS]), limit, 0x9B, 0xC); ++ write_gdt_entry(get_cpu_gdt_table(cpu), GDT_ENTRY_KERNEL_CS, &d, DESCTYPE_S); ++ } ++ ++ /* PaX: make KERNEL_CS read-only */ ++ addr = PFN_ALIGN(ktla_ktva((unsigned long)&_text)); ++ if (!paravirt_enabled()) ++ set_memory_ro(addr, (PFN_ALIGN(_sdata) - addr) >> PAGE_SHIFT); ++/* ++ for (addr = ktla_ktva((unsigned long)&_text); addr < (unsigned long)&_sdata; addr += PMD_SIZE) { ++ pgd = pgd_offset_k(addr); ++ pud = pud_offset(pgd, addr); ++ pmd = 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_ALIGN(__init_begin)) >> PAGE_SHIFT); ++/* ++ for (addr = (unsigned long)&__init_begin; addr < (unsigned long)&__init_end; addr += PMD_SIZE) { ++ pgd = pgd_offset_k(addr); ++ pud = pud_offset(pgd, addr); ++ pmd = 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 - MODULES_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 = __START_KERNEL_map; addr < __START_KERNEL_map + KERNEL_IMAGE_SIZE; addr += PMD_SIZE) { ++ pgd = pgd_offset_k(addr); ++ pud = pud_offset(pgd, addr); ++ pmd = pmd_offset(pud, addr); ++ if (!pmd_present(*pmd)) ++ continue; ++ if ((unsigned long)_text <= 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 = (unsigned long)__va(__pa(__START_KERNEL_map)); ++ end = addr + KERNEL_IMAGE_SIZE; ++ for (; addr < end; addr += PMD_SIZE) { ++ pgd = pgd_offset_k(addr); ++ pud = pud_offset(pgd, addr); ++ pmd = pmd_offset(pud, addr); ++ if (!pmd_present(*pmd)) ++ continue; ++ if ((unsigned long)__va(__pa(_text)) <= addr && addr < (unsigned long)__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) } @@ -20718,7 +21511,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/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 *pmd) page_table = (pte_t *)alloc_low_page(); paravirt_alloc_pte(&init_mm, __pa(page_table) >> PAGE_SHIFT); @@ -20747,7 +21540,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/arch/x86/mm/init_32.c pmd_t * __init populate_extra_pmd(unsigned long vaddr) { int pgd_idx = 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; @@ -20755,7 +21548,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/arch/x86/mm/init_32.c pmd_t *pmd; pte_t *pte = NULL; -@@ -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 = pgd_base + pgd_idx; for ( ; (pgd_idx < PTRS_PER_PGD) && (vaddr != end); pgd++, pgd_idx++) { @@ -20771,7 +21564,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/arch/x86/mm/init_32.c for (; (pmd_idx < PTRS_PER_PMD) && (vaddr != end); pmd++, pmd_idx++) { pte = 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, unsigned long end, pgd_t *pgd_base) } } @@ -20796,7 +21589,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/arch/x86/mm/init_32.c } /* -@@ -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 = end; unsigned long start_pfn, end_pfn; pgd_t *pgd_base = swapper_pg_dir; @@ -20871,7 +21664,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/arch/x86/mm/init_32.c prot = PAGE_KERNEL_EXEC; 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) pud = pud_offset(pgd, va); pmd = pmd_offset(pud, va); @@ -20880,7 +21673,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/arch/x86/mm/init_32.c break; pte = 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(void) static void __init pagetable_init(void) { @@ -20955,10 +21748,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_32.c linux-3.0.9/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.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c ---- linux-3.0.9/arch/x86/mm/init_64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/init_64.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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. */ @@ -20967,7 +21761,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c EXPORT_SYMBOL_GPL(__supported_pte_mask); 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, unsigned long end) for (address = start; address <= end; address += PGDIR_SIZE) { const pgd_t *pgd_ref = pgd_offset_k(address); @@ -20990,7 +21784,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/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 = &pgd_page_get_mm(page)->page_table_lock; spin_lock(pgt_lock); @@ -20998,7 +21792,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c 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) != pgd_page_vaddr(*pgd_ref)); @@ -21009,7 +21803,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c } spin_unlock(&pgd_lock); } -@@ -203,7 +217,9 @@ void set_pte_vaddr_pud(pud_t *pud_page, +@@ -203,7 +217,9 @@ void set_pte_vaddr_pud(pud_t *pud_page, unsigned long vaddr, pte_t new_pte) pmd = fill_pmd(pud, vaddr); pte = fill_pte(pmd, vaddr); @@ -21019,7 +21813,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c /* * 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 long phys, unsigned long size, pgd = pgd_offset_k((unsigned long)__va(phys)); if (pgd_none(*pgd)) { pud = (pud_t *) spp_getpage(); @@ -21036,7 +21830,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c } pmd = 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 *phys) if (pfn >= pgt_buf_top) panic("alloc_low_page: ran out of memory"); @@ -21045,7 +21839,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c clear_page(adr); *phys = 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) phys = __pa(virt); left = phys & (PAGE_SIZE - 1); @@ -21078,7 +21872,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c }; 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) const char *arch_vma_name(struct vm_area_struct *vma) { @@ -21087,145 +21881,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/init_64.c linux-3.0.9/arch/x86/mm/init_64.c return "[vdso]"; if (vma == &gate_vma) return "[vsyscall]"; -diff -urNp linux-3.0.9/arch/x86/mm/init.c linux-3.0.9/arch/x86/mm/init.c ---- linux-3.0.9/arch/x86/mm/init.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/init.c 2011-11-12 12:47:13.000000000 -0500 -@@ -31,7 +31,7 @@ int direct_gbpages - static void __init find_early_table_space(unsigned long end, int use_pse, - int use_gbpages) - { -- unsigned long puds, pmds, ptes, tables, start = 0, good_end = end; -+ unsigned long puds, pmds, ptes, tables, start = 0x100000, good_end = end; - phys_addr_t base; - - puds = (end + PUD_SIZE - 1) >> PUD_SHIFT; -@@ -312,12 +312,34 @@ unsigned long __init_refok init_memory_m - */ - int devmem_is_allowed(unsigned long pagenr) - { -- if (pagenr <= 256) -+#ifdef CONFIG_GRKERNSEC_KMEM -+ /* allow BDA */ -+ if (!pagenr) -+ return 1; -+ /* allow EBDA */ -+ if ((0x9f000 >> PAGE_SHIFT) == 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) <= pagenr && pagenr < (ISA_END_ADDRESS >> PAGE_SHIFT)) - return 1; -+#ifdef CONFIG_GRKERNSEC_KMEM -+ /* throw out everything else below 1MB */ -+ if (pagenr <= 256) -+ return 0; -+#endif - if (iomem_is_exclusive(pagenr << PAGE_SHIFT)) - return 0; - if (!page_is_ram(pagenr)) - return 1; -+ - return 0; - } - -@@ -372,6 +394,86 @@ void free_init_pages(char *what, unsigne - - 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 = paravirt_enabled() ? ktva_ktla(0xffffffff) : (unsigned long)&_etext; -+ limit = (limit - 1UL) >> PAGE_SHIFT; -+ -+ memset(__LOAD_PHYSICAL_ADDR + PAGE_OFFSET, POISON_FREE_INITMEM, PAGE_SIZE); -+ for (cpu = 0; cpu < NR_CPUS; cpu++) { -+ pack_descriptor(&d, get_desc_base(&get_cpu_gdt_table(cpu)[GDT_ENTRY_KERNEL_CS]), limit, 0x9B, 0xC); -+ write_gdt_entry(get_cpu_gdt_table(cpu), GDT_ENTRY_KERNEL_CS, &d, DESCTYPE_S); -+ } -+ -+ /* PaX: make KERNEL_CS read-only */ -+ addr = PFN_ALIGN(ktla_ktva((unsigned long)&_text)); -+ if (!paravirt_enabled()) -+ set_memory_ro(addr, (PFN_ALIGN(_sdata) - addr) >> PAGE_SHIFT); -+/* -+ for (addr = ktla_ktva((unsigned long)&_text); addr < (unsigned long)&_sdata; addr += PMD_SIZE) { -+ pgd = pgd_offset_k(addr); -+ pud = pud_offset(pgd, addr); -+ pmd = 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_ALIGN(__init_begin)) >> PAGE_SHIFT); -+/* -+ for (addr = (unsigned long)&__init_begin; addr < (unsigned long)&__init_end; addr += PMD_SIZE) { -+ pgd = pgd_offset_k(addr); -+ pud = pud_offset(pgd, addr); -+ pmd = 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 - MODULES_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 = __START_KERNEL_map; addr < __START_KERNEL_map + KERNEL_IMAGE_SIZE; addr += PMD_SIZE) { -+ pgd = pgd_offset_k(addr); -+ pud = pud_offset(pgd, addr); -+ pmd = pmd_offset(pud, addr); -+ if (!pmd_present(*pmd)) -+ continue; -+ if ((unsigned long)_text <= 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 = (unsigned long)__va(__pa(__START_KERNEL_map)); -+ end = addr + KERNEL_IMAGE_SIZE; -+ for (; addr < end; addr += PMD_SIZE) { -+ pgd = pgd_offset_k(addr); -+ pud = pud_offset(pgd, addr); -+ pmd = pmd_offset(pud, addr); -+ if (!pmd_present(*pmd)) -+ continue; -+ if ((unsigned long)__va(__pa(_text)) <= addr && addr < (unsigned long)__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.0.9/arch/x86/mm/iomap_32.c linux-3.0.9/arch/x86/mm/iomap_32.c ---- linux-3.0.9/arch/x86/mm/iomap_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/iomap_32.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = kmap_atomic_idx_push(); idx = type + KM_TYPE_NR * smp_processor_id(); vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); @@ -21237,10 +21897,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/iomap_32.c linux-3.0.9/arch/x86/mm/iomap_32.c arch_flush_lazy_mmu_mode(); return (void *)vaddr; -diff -urNp linux-3.0.9/arch/x86/mm/ioremap.c linux-3.0.9/arch/x86/mm/ioremap.c ---- linux-3.0.9/arch/x86/mm/ioremap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/ioremap.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = phys_addr >> PAGE_SHIFT; pfn <= last_pfn; pfn++) { int is_ram = page_is_ram(pfn); @@ -21249,7 +21910,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/ioremap.c linux-3.0.9/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 *str) early_param("early_ioremap_debug", early_ioremap_debug_setup); static __initdata int after_paging_init; @@ -21268,10 +21929,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/ioremap.c linux-3.0.9/arch/x86/mm/ioremap.c /* * The boot-ioremap range spans multiple pmds, for which -diff -urNp linux-3.0.9/arch/x86/mm/kmemcheck/kmemcheck.c linux-3.0.9/arch/x86/mm/kmemcheck/kmemcheck.c ---- linux-3.0.9/arch/x86/mm/kmemcheck/kmemcheck.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/kmemcheck/kmemcheck.c 2011-11-12 12:47:13.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/kmemcheck.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. */ @@ -21283,10 +21945,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/kmemcheck/kmemcheck.c linux-3.0.9/arch/x86/mm return false; pte = kmemcheck_pte_lookup(address); -diff -urNp linux-3.0.9/arch/x86/mm/mmap.c linux-3.0.9/arch/x86/mm/mmap.c ---- linux-3.0.9/arch/x86/mm/mmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/mmap.c 2011-11-12 12:47:13.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()) @@ -21341,7 +22004,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/mmap.c linux-3.0.9/arch/x86/mm/mmap.c return TASK_UNMAPPED_BASE + mmap_rnd(); } -@@ -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()) { @@ -21367,10 +22030,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/mmap.c linux-3.0.9/arch/x86/mm/mmap.c mm->get_unmapped_area = arch_get_unmapped_area_topdown; mm->unmap_area = arch_unmap_area_topdown; } -diff -urNp linux-3.0.9/arch/x86/mm/mmio-mod.c linux-3.0.9/arch/x86/mm/mmio-mod.c ---- linux-3.0.9/arch/x86/mm/mmio-mod.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/mmio-mod.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 3adff7d..47e9fe9 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_regs *regs, break; default: { @@ -21379,7 +22043,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/mmio-mod.c linux-3.0.9/arch/x86/mm/mmio-mod.c my_trace->opcode = MMIO_UNKNOWN_OP; my_trace->width = 0; my_trace->value = (*ip) << 16 | *(ip + 1) << 8 | -@@ -235,7 +235,7 @@ static void post(struct kmmio_probe *p, +@@ -235,7 +235,7 @@ static void post(struct kmmio_probe *p, unsigned long condition, static void ioremap_trace_core(resource_size_t offset, unsigned long size, void __iomem *addr) { @@ -21388,7 +22052,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/mmio-mod.c linux-3.0.9/arch/x86/mm/mmio-mod.c struct remap_trace *trace = kmalloc(sizeof(*trace), GFP_KERNEL); /* These are page-unaligned. */ struct mmiotrace_map map = { -@@ -259,7 +259,7 @@ static void ioremap_trace_core(resource_ +@@ -259,7 +259,7 @@ static void ioremap_trace_core(resource_size_t offset, unsigned long size, .private = trace }, .phys = offset, @@ -21397,10 +22061,24 @@ diff -urNp linux-3.0.9/arch/x86/mm/mmio-mod.c linux-3.0.9/arch/x86/mm/mmio-mod.c }; map.map_id = trace->id; -diff -urNp linux-3.0.9/arch/x86/mm/pageattr.c linux-3.0.9/arch/x86/mm/pageattr.c ---- linux-3.0.9/arch/x86/mm/pageattr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/pageattr.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 e1d1069..2251ff3 100644 +--- a/arch/x86/mm/pageattr-test.c ++++ b/arch/x86/mm/pageattr-test.c +@@ -36,7 +36,7 @@ enum { + + static int pte_testbit(pte_t pte) + { +- return pte_flags(pte) & _PAGE_UNUSED1; ++ return pte_flags(pte) & _PAGE_CPA_TEST; + } + + 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 prot, unsigned long address, */ #ifdef CONFIG_PCI_BIOS if (pcibios_enabled && within(pfn, BIOS_BEGIN >> PAGE_SHIFT, BIOS_END >> PAGE_SHIFT)) @@ -21409,7 +22087,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pageattr.c linux-3.0.9/arch/x86/mm/pageattr.c #endif /* -@@ -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 */ @@ -21422,7 +22100,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pageattr.c linux-3.0.9/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 prot, unsigned long address, if (within(pfn, __pa((unsigned long)__start_rodata) >> PAGE_SHIFT, __pa((unsigned long)__end_rodata) >> PAGE_SHIFT)) pgprot_val(forbidden) |= _PAGE_RW; @@ -21430,7 +22108,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pageattr.c linux-3.0.9/arch/x86/mm/pageattr.c #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 @@ -21484,21 +22162,10 @@ diff -urNp linux-3.0.9/arch/x86/mm/pageattr.c linux-3.0.9/arch/x86/mm/pageattr.c } static int -diff -urNp linux-3.0.9/arch/x86/mm/pageattr-test.c linux-3.0.9/arch/x86/mm/pageattr-test.c ---- linux-3.0.9/arch/x86/mm/pageattr-test.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/pageattr-test.c 2011-11-12 12:47:13.000000000 -0500 -@@ -36,7 +36,7 @@ enum { - - static int pte_testbit(pte_t pte) - { -- return pte_flags(pte) & _PAGE_UNUSED1; -+ return pte_flags(pte) & _PAGE_CPA_TEST; - } - - struct split_state { -diff -urNp linux-3.0.9/arch/x86/mm/pat.c linux-3.0.9/arch/x86/mm/pat.c ---- linux-3.0.9/arch/x86/mm/pat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/pat.c 2011-11-12 12:47:13.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) if (!entry) { @@ -21508,7 +22175,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pat.c linux-3.0.9/arch/x86/mm/pat.c return -EINVAL; } -@@ -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 @@ -21519,7 +22186,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pat.c linux-3.0.9/arch/x86/mm/pat.c return 0; } cursor += 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", @@ -21528,7 +22195,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pat.c linux-3.0.9/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, +@@ -593,7 +593,7 @@ static int reserve_pfn_range(u64 paddr, unsigned long size, pgprot_t *vma_prot, if (want_flags != flags) { printk(KERN_WARNING "%s:%d map pfn RAM range req %s for %Lx-%Lx, got %s\n", @@ -21537,7 +22204,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pat.c linux-3.0.9/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, +@@ -615,7 +615,7 @@ static int reserve_pfn_range(u64 paddr, unsigned long 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", @@ -21546,10 +22213,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/pat.c linux-3.0.9/arch/x86/mm/pat.c cattr_name(want_flags), (unsigned long long)paddr, (unsigned long long)(paddr + size), -diff -urNp linux-3.0.9/arch/x86/mm/pf_in.c linux-3.0.9/arch/x86/mm/pf_in.c ---- linux-3.0.9/arch/x86/mm/pf_in.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/pf_in.c 2011-11-12 12:47:13.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 = OTHERS; @@ -21558,7 +22226,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pf_in.c linux-3.0.9/arch/x86/mm/pf_in.c p += skip_prefix(p, &prf); p += get_opcode(p, &opcode); -@@ -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; @@ -21567,7 +22235,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pf_in.c linux-3.0.9/arch/x86/mm/pf_in.c p += skip_prefix(p, &prf); p += get_opcode(p, &opcode); -@@ -191,7 +191,7 @@ unsigned int get_ins_mem_width(unsigned +@@ -191,7 +191,7 @@ unsigned int get_ins_mem_width(unsigned long ins_addr) struct prefix_bits prf; int i; @@ -21576,7 +22244,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pf_in.c linux-3.0.9/arch/x86/mm/pf_in.c p += skip_prefix(p, &prf); p += get_opcode(p, &opcode); -@@ -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; @@ -21585,7 +22253,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pf_in.c linux-3.0.9/arch/x86/mm/pf_in.c p += skip_prefix(p, &prf); p += get_opcode(p, &opcode); for (i = 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; @@ -21594,27 +22262,11 @@ diff -urNp linux-3.0.9/arch/x86/mm/pf_in.c linux-3.0.9/arch/x86/mm/pf_in.c p += skip_prefix(p, &prf); p += get_opcode(p, &opcode); for (i = 0; i < ARRAY_SIZE(imm_wop); i++) -diff -urNp linux-3.0.9/arch/x86/mm/pgtable_32.c linux-3.0.9/arch/x86/mm/pgtable_32.c ---- linux-3.0.9/arch/x86/mm/pgtable_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/pgtable_32.c 2011-11-12 12:47:13.000000000 -0500 -@@ -48,10 +48,13 @@ void set_pte_vaddr(unsigned long vaddr, - return; - } - pte = 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(); - - /* - * It's enough to flush this one mapping. -diff -urNp linux-3.0.9/arch/x86/mm/pgtable.c linux-3.0.9/arch/x86/mm/pgtable.c ---- linux-3.0.9/arch/x86/mm/pgtable.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/pgtable.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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); } @@ -21640,7 +22292,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pgtable.c linux-3.0.9/arch/x86/mm/pgtable.c +#else + *dst++ = *src++; +#endif - ++ +} +#endif + @@ -21661,7 +22313,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pgtable.c linux-3.0.9/arch/x86/mm/pgtable.c +#define pyd_offset(mm ,address) pud_offset((mm), (address)) +#define PYD_SIZE PUD_SIZE +#endif -+ + +#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) {} @@ -21695,7 +22347,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pgtable.c linux-3.0.9/arch/x86/mm/pgtable.c void pud_populate(struct mm_struct *mm, pud_t *pudp, pmd_t *pmd) { -@@ -170,36 +213,38 @@ void pud_populate(struct mm_struct *mm, +@@ -170,36 +213,38 @@ void pud_populate(struct mm_struct *mm, pud_t *pudp, pmd_t *pmd) */ flush_tlb_mm(mm); } @@ -21745,7 +22397,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/pgtable.c linux-3.0.9/arch/x86/mm/pgtable.c return -ENOMEM; } -@@ -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. */ @@ -21859,9 +22511,28 @@ diff -urNp linux-3.0.9/arch/x86/mm/pgtable.c linux-3.0.9/arch/x86/mm/pgtable.c pgd_dtor(pgd); paravirt_pgd_free(mm, pgd); free_page((unsigned long)pgd); -diff -urNp linux-3.0.9/arch/x86/mm/setup_nx.c linux-3.0.9/arch/x86/mm/setup_nx.c ---- linux-3.0.9/arch/x86/mm/setup_nx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/setup_nx.c 2011-11-12 12:47:13.000000000 -0500 +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 = 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(); + + /* + * 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 <asm/pgtable.h> #include <asm/proto.h> @@ -21873,7 +22544,7 @@ diff -urNp linux-3.0.9/arch/x86/mm/setup_nx.c linux-3.0.9/arch/x86/mm/setup_nx.c /* * noexec = 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); @@ -21891,9 +22562,10 @@ diff -urNp linux-3.0.9/arch/x86/mm/setup_nx.c linux-3.0.9/arch/x86/mm/setup_nx.c __supported_pte_mask &= ~_PAGE_NX; } -diff -urNp linux-3.0.9/arch/x86/mm/tlb.c linux-3.0.9/arch/x86/mm/tlb.c ---- linux-3.0.9/arch/x86/mm/tlb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/mm/tlb.c 2011-11-12 12:47:13.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, @@ -21906,31 +22578,10 @@ diff -urNp linux-3.0.9/arch/x86/mm/tlb.c linux-3.0.9/arch/x86/mm/tlb.c } EXPORT_SYMBOL_GPL(leave_mm); -diff -urNp linux-3.0.9/arch/x86/net/bpf_jit_comp.c linux-3.0.9/arch/x86/net/bpf_jit_comp.c ---- linux-3.0.9/arch/x86/net/bpf_jit_comp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/net/bpf_jit_comp.c 2011-11-12 12:47:13.000000000 -0500 -@@ -589,7 +589,9 @@ cond_branch: f_offset = addrs[i + filt - module_free(NULL, image); - return; - } -+ pax_open_kernel(); - memcpy(image + proglen, temp, ilen); -+ pax_close_kernel(); - } - proglen += ilen; - addrs[i] = proglen; -@@ -609,7 +611,7 @@ cond_branch: f_offset = addrs[i + filt - break; - } - if (proglen == oldproglen) { -- image = module_alloc(max_t(unsigned int, -+ image = module_alloc_exec(max_t(unsigned int, - proglen, - sizeof(struct work_struct))); - if (!image) -diff -urNp linux-3.0.9/arch/x86/net/bpf_jit.S linux-3.0.9/arch/x86/net/bpf_jit.S ---- linux-3.0.9/arch/x86/net/bpf_jit.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/net/bpf_jit.S 2011-11-12 12:47:13.000000000 -0500 +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 <linux/linkage.h> @@ -22008,10 +22659,34 @@ diff -urNp linux-3.0.9/arch/x86/net/bpf_jit.S linux-3.0.9/arch/x86/net/bpf_jit.S xchg %eax,%ebx + pax_force_retaddr ret -diff -urNp linux-3.0.9/arch/x86/oprofile/backtrace.c linux-3.0.9/arch/x86/oprofile/backtrace.c ---- linux-3.0.9/arch/x86/oprofile/backtrace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/oprofile/backtrace.c 2011-11-12 12:47:13.000000000 -0500 -@@ -83,11 +83,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..e32d0f0 100644 +--- a/arch/x86/net/bpf_jit_comp.c ++++ b/arch/x86/net/bpf_jit_comp.c +@@ -589,7 +589,9 @@ cond_branch: f_offset = addrs[i + filter[i].jf] - addrs[i]; + module_free(NULL, image); + return; + } ++ pax_open_kernel(); + memcpy(image + proglen, temp, ilen); ++ pax_close_kernel(); + } + proglen += ilen; + addrs[i] = proglen; +@@ -609,7 +611,7 @@ cond_branch: f_offset = addrs[i + filter[i].jf] - addrs[i]; + break; + } + if (proglen == oldproglen) { +- image = module_alloc(max_t(unsigned int, ++ image = module_alloc_exec(max_t(unsigned int, + proglen, + sizeof(struct work_struct))); + if (!image) +diff --git a/arch/x86/oprofile/backtrace.c b/arch/x86/oprofile/backtrace.c +index 32f78eb..9074017 100644 +--- a/arch/x86/oprofile/backtrace.c ++++ b/arch/x86/oprofile/backtrace.c +@@ -83,11 +83,11 @@ dump_user_backtrace_32(struct stack_frame_ia32 *head) struct stack_frame_ia32 *fp; unsigned long bytes; @@ -22025,7 +22700,7 @@ diff -urNp linux-3.0.9/arch/x86/oprofile/backtrace.c linux-3.0.9/arch/x86/oprofi oprofile_add_trace(bufhead[0].return_address); -@@ -129,7 +129,7 @@ static struct stack_frame *dump_user_bac +@@ -129,7 +129,7 @@ static struct stack_frame *dump_user_backtrace(struct stack_frame *head) struct stack_frame bufhead[2]; unsigned long bytes; @@ -22034,7 +22709,7 @@ diff -urNp linux-3.0.9/arch/x86/oprofile/backtrace.c linux-3.0.9/arch/x86/oprofi if (bytes != sizeof(bufhead)) return NULL; -@@ -148,7 +148,7 @@ x86_backtrace(struct pt_regs * const reg +@@ -148,7 +148,7 @@ x86_backtrace(struct pt_regs * const regs, unsigned int depth) { struct stack_frame *head = (struct stack_frame *)frame_pointer(regs); @@ -22043,9 +22718,10 @@ diff -urNp linux-3.0.9/arch/x86/oprofile/backtrace.c linux-3.0.9/arch/x86/oprofi unsigned long stack = kernel_stack_pointer(regs); if (depth) dump_trace(NULL, regs, (unsigned long *)stack, 0, -diff -urNp linux-3.0.9/arch/x86/pci/mrst.c linux-3.0.9/arch/x86/pci/mrst.c ---- linux-3.0.9/arch/x86/pci/mrst.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/pci/mrst.c 2011-11-12 12:47:13.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(); @@ -22057,9 +22733,10 @@ diff -urNp linux-3.0.9/arch/x86/pci/mrst.c linux-3.0.9/arch/x86/pci/mrst.c /* Continue with standard init */ return 1; } -diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c ---- linux-3.0.9/arch/x86/pci/pcbios.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/pci/pcbios.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/pci/pcbios.c b/arch/x86/pci/pcbios.c +index a5f7d0d..f7a8a1b 100644 +--- a/arch/x86/pci/pcbios.c ++++ b/arch/x86/pci/pcbios.c @@ -79,50 +79,93 @@ union bios32 { static struct { unsigned long address; @@ -22195,7 +22872,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c : "memory"); local_irq_restore(flags); -@@ -188,7 +234,10 @@ static int pci_bios_read(unsigned int se +@@ -188,7 +234,10 @@ static int pci_bios_read(unsigned int seg, unsigned int bus, switch (len) { case 1: @@ -22207,7 +22884,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -197,7 +246,8 @@ static int pci_bios_read(unsigned int se +@@ -197,7 +246,8 @@ static int pci_bios_read(unsigned int seg, unsigned int bus, : "1" (PCIBIOS_READ_CONFIG_BYTE), "b" (bx), "D" ((long)reg), @@ -22217,7 +22894,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c /* * Zero-extend the result beyond 8 bits, do not trust the * BIOS having done it: -@@ -205,7 +255,10 @@ static int pci_bios_read(unsigned int se +@@ -205,7 +255,10 @@ static int pci_bios_read(unsigned int seg, unsigned int bus, *value &= 0xff; break; case 2: @@ -22229,7 +22906,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -214,7 +267,8 @@ static int pci_bios_read(unsigned int se +@@ -214,7 +267,8 @@ static int pci_bios_read(unsigned int seg, unsigned int bus, : "1" (PCIBIOS_READ_CONFIG_WORD), "b" (bx), "D" ((long)reg), @@ -22239,7 +22916,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c /* * Zero-extend the result beyond 16 bits, do not trust the * BIOS having done it: -@@ -222,7 +276,10 @@ static int pci_bios_read(unsigned int se +@@ -222,7 +276,10 @@ static int pci_bios_read(unsigned int seg, unsigned int bus, *value &= 0xffff; break; case 4: @@ -22251,7 +22928,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -231,7 +288,8 @@ static int pci_bios_read(unsigned int se +@@ -231,7 +288,8 @@ static int pci_bios_read(unsigned int seg, unsigned int bus, : "1" (PCIBIOS_READ_CONFIG_DWORD), "b" (bx), "D" ((long)reg), @@ -22261,7 +22938,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c break; } -@@ -254,7 +312,10 @@ static int pci_bios_write(unsigned int s +@@ -254,7 +312,10 @@ static int pci_bios_write(unsigned int seg, unsigned int bus, switch (len) { case 1: @@ -22273,7 +22950,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -263,10 +324,14 @@ static int pci_bios_write(unsigned int s +@@ -263,10 +324,14 @@ static int pci_bios_write(unsigned int seg, unsigned int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -22290,7 +22967,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -275,10 +340,14 @@ static int pci_bios_write(unsigned int s +@@ -275,10 +340,14 @@ static int pci_bios_write(unsigned int seg, unsigned int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -22307,7 +22984,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -287,7 +356,8 @@ static int pci_bios_write(unsigned int s +@@ -287,7 +356,8 @@ static int pci_bios_write(unsigned int seg, unsigned int bus, "c" (value), "b" (bx), "D" ((long)reg), @@ -22317,7 +22994,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c break; } -@@ -392,10 +462,13 @@ struct irq_routing_table * pcibios_get_i +@@ -392,10 +462,13 @@ struct irq_routing_table * pcibios_get_irq_routing_table(void) DBG("PCI: Fetching IRQ routing table... "); __asm__("push %%es\n\t" @@ -22332,7 +23009,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -406,7 +479,8 @@ struct irq_routing_table * pcibios_get_i +@@ -406,7 +479,8 @@ struct irq_routing_table * pcibios_get_irq_routing_table(void) "1" (0), "D" ((long) &opt), "S" (&pci_indirect), @@ -22342,7 +23019,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c : "memory"); DBG("OK ret=%d, size=%d, map=%x\n", ret, opt.size, map); if (ret & 0xff00) -@@ -430,7 +504,10 @@ int pcibios_set_irq_routing(struct pci_d +@@ -430,7 +504,10 @@ int pcibios_set_irq_routing(struct pci_dev *dev, int pin, int irq) { int ret; @@ -22354,7 +23031,7 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c "jc 1f\n\t" "xor %%ah, %%ah\n" "1:" -@@ -438,7 +515,8 @@ int pcibios_set_irq_routing(struct pci_d +@@ -438,7 +515,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)), @@ -22364,9 +23041,10 @@ diff -urNp linux-3.0.9/arch/x86/pci/pcbios.c linux-3.0.9/arch/x86/pci/pcbios.c return !(ret & 0xff00); } EXPORT_SYMBOL(pcibios_set_irq_routing); -diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_32.c linux-3.0.9/arch/x86/platform/efi/efi_32.c ---- linux-3.0.9/arch/x86/platform/efi/efi_32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/platform/efi/efi_32.c 2011-11-12 12:47:13.000000000 -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 @@ */ @@ -22381,10 +23059,11 @@ diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_32.c linux-3.0.9/arch/x86/platf - unsigned long temp; struct desc_ptr gdt_descr; -- local_irq_save(efi_rt_eflags); +#ifdef CONFIG_PAX_KERNEXEC + struct desc_struct d; +#endif ++ + local_irq_save(efi_rt_eflags); - /* - * If I don't have PAE, I should just duplicate two entries in page @@ -22392,8 +23071,7 @@ diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_32.c linux-3.0.9/arch/x86/platf - * page directory. - */ - cr4 = read_cr4_safe(); -+ local_irq_save(efi_rt_eflags); - +- - if (cr4 & X86_CR4_PAE) { - efi_bak_pg_dir_pointer[0].pgd = - swapper_pg_dir[pgd_index(0)].pgd; @@ -22464,9 +23142,10 @@ diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_32.c linux-3.0.9/arch/x86/platf /* * After the lock is released, the original page table is restored. -diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_stub_32.S linux-3.0.9/arch/x86/platform/efi/efi_stub_32.S ---- linux-3.0.9/arch/x86/platform/efi/efi_stub_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/platform/efi/efi_stub_32.S 2011-11-12 12:47:13.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 @@ */ @@ -22575,9 +23254,10 @@ diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_stub_32.S linux-3.0.9/arch/x86/ saved_return_addr: .long 0 efi_rt_function_ptr: -diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_stub_64.S linux-3.0.9/arch/x86/platform/efi/efi_stub_64.S ---- linux-3.0.9/arch/x86/platform/efi/efi_stub_64.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/platform/efi/efi_stub_64.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/platform/efi/efi_stub_64.S b/arch/x86/platform/efi/efi_stub_64.S +index 4c07cca..3092c81 100644 +--- a/arch/x86/platform/efi/efi_stub_64.S ++++ b/arch/x86/platform/efi/efi_stub_64.S @@ -7,6 +7,7 @@ */ @@ -22641,9 +23321,10 @@ diff -urNp linux-3.0.9/arch/x86/platform/efi/efi_stub_64.S linux-3.0.9/arch/x86/ + pax_force_retaddr ret ENDPROC(efi_call6) -diff -urNp linux-3.0.9/arch/x86/platform/mrst/mrst.c linux-3.0.9/arch/x86/platform/mrst/mrst.c ---- linux-3.0.9/arch/x86/platform/mrst/mrst.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/platform/mrst/mrst.c 2011-11-12 12:47:13.000000000 -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) } @@ -22663,10 +23344,11 @@ diff -urNp linux-3.0.9/arch/x86/platform/mrst/mrst.c linux-3.0.9/arch/x86/platfo } /* -diff -urNp linux-3.0.9/arch/x86/platform/uv/tlb_uv.c linux-3.0.9/arch/x86/platform/uv/tlb_uv.c ---- linux-3.0.9/arch/x86/platform/uv/tlb_uv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/platform/uv/tlb_uv.c 2011-11-12 12:47:13.000000000 -0500 -@@ -370,6 +370,8 @@ static void reset_with_ipi(struct bau_ta +diff --git a/arch/x86/platform/uv/tlb_uv.c b/arch/x86/platform/uv/tlb_uv.c +index 82cff4a..ceceb7c 100644 +--- a/arch/x86/platform/uv/tlb_uv.c ++++ b/arch/x86/platform/uv/tlb_uv.c +@@ -370,6 +370,8 @@ static void reset_with_ipi(struct bau_targ_hubmask *distribution, int sender) cpumask_t mask; struct reset_args reset_args; @@ -22675,9 +23357,10 @@ diff -urNp linux-3.0.9/arch/x86/platform/uv/tlb_uv.c linux-3.0.9/arch/x86/platfo reset_args.sender = sender; cpus_clear(mask); /* find a single cpu for each uvhub in this distribution mask */ -diff -urNp linux-3.0.9/arch/x86/power/cpu.c linux-3.0.9/arch/x86/power/cpu.c ---- linux-3.0.9/arch/x86/power/cpu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/power/cpu.c 2011-11-12 12:47:13.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) { @@ -22697,9 +23380,10 @@ diff -urNp linux-3.0.9/arch/x86/power/cpu.c linux-3.0.9/arch/x86/power/cpu.c syscall_init(); /* This sets MSR_*STAR and related */ #endif -diff -urNp linux-3.0.9/arch/x86/vdso/Makefile linux-3.0.9/arch/x86/vdso/Makefile ---- linux-3.0.9/arch/x86/vdso/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/vdso/Makefile 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/vdso/Makefile b/arch/x86/vdso/Makefile +index bef0bc9..8495be8 100644 +--- a/arch/x86/vdso/Makefile ++++ b/arch/x86/vdso/Makefile @@ -136,7 +136,7 @@ quiet_cmd_vdso = VDSO $@ -Wl,-T,$(filter %.lds,$^) $(filter %.o,$^) && \ sh $(srctree)/$(src)/checkundef.sh '$(NM)' '$@' @@ -22709,9 +23393,10 @@ diff -urNp linux-3.0.9/arch/x86/vdso/Makefile linux-3.0.9/arch/x86/vdso/Makefile GCOV_PROFILE := n # -diff -urNp linux-3.0.9/arch/x86/vdso/vdso32-setup.c linux-3.0.9/arch/x86/vdso/vdso32-setup.c ---- linux-3.0.9/arch/x86/vdso/vdso32-setup.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/vdso/vdso32-setup.c 2011-11-12 12:47:13.000000000 -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 <asm/tlbflush.h> #include <asm/vdso.h> @@ -22720,7 +23405,7 @@ diff -urNp linux-3.0.9/arch/x86/vdso/vdso32-setup.c linux-3.0.9/arch/x86/vdso/vd enum { VDSO_DISABLED = 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 = get_cpu(); @@ -22738,7 +23423,7 @@ diff -urNp linux-3.0.9/arch/x86/vdso/vdso32-setup.c linux-3.0.9/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_binprm *bprm, int uses_interp) if (compat) addr = VDSO_HIGH_BASE; else { @@ -22755,7 +23440,7 @@ diff -urNp linux-3.0.9/arch/x86/vdso/vdso32-setup.c linux-3.0.9/arch/x86/vdso/vd 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_binprm *bprm, int uses_interp) } current_thread_info()->sysenter_return = @@ -22785,7 +23470,7 @@ diff -urNp linux-3.0.9/arch/x86/vdso/vdso32-setup.c linux-3.0.9/arch/x86/vdso/vd return NULL; } -@@ -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. */ @@ -22794,9 +23479,10 @@ diff -urNp linux-3.0.9/arch/x86/vdso/vdso32-setup.c linux-3.0.9/arch/x86/vdso/vd return &gate_vma; return NULL; } -diff -urNp linux-3.0.9/arch/x86/vdso/vma.c linux-3.0.9/arch/x86/vdso/vma.c ---- linux-3.0.9/arch/x86/vdso/vma.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/vdso/vma.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/vdso/vma.c b/arch/x86/vdso/vma.c +index 7abd2be..32c057d 100644 +--- a/arch/x86/vdso/vma.c ++++ b/arch/x86/vdso/vma.c @@ -15,18 +15,19 @@ #include <asm/proto.h> #include <asm/vdso.h> @@ -22846,7 +23532,7 @@ diff -urNp linux-3.0.9/arch/x86/vdso/vma.c linux-3.0.9/arch/x86/vdso/vma.c } subsys_initcall(init_vdso_vars); -@@ -80,37 +81,35 @@ int arch_setup_additional_pages(struct l +@@ -80,37 +81,35 @@ int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp) unsigned long addr; int ret; @@ -22899,9 +23585,10 @@ diff -urNp linux-3.0.9/arch/x86/vdso/vma.c linux-3.0.9/arch/x86/vdso/vma.c - return 0; -} -__setup("vdso=", vdso_setup); -diff -urNp linux-3.0.9/arch/x86/xen/enlighten.c linux-3.0.9/arch/x86/xen/enlighten.c ---- linux-3.0.9/arch/x86/xen/enlighten.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/xen/enlighten.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c +index 0fb662a..0033c99 100644 +--- a/arch/x86/xen/enlighten.c ++++ b/arch/x86/xen/enlighten.c @@ -85,8 +85,6 @@ EXPORT_SYMBOL_GPL(xen_start_info); struct shared_info xen_dummy_shared_info; @@ -22911,7 +23598,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/enlighten.c linux-3.0.9/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); -@@ -1010,7 +1008,7 @@ static const struct pv_apic_ops xen_apic +@@ -1010,7 +1008,7 @@ static const struct pv_apic_ops xen_apic_ops __initconst = { #endif }; @@ -22941,7 +23628,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/enlighten.c linux-3.0.9/arch/x86/xen/enlight { xen_reboot(SHUTDOWN_poweroff); } -@@ -1134,7 +1132,17 @@ asmlinkage void __init xen_start_kernel( +@@ -1134,7 +1132,17 @@ asmlinkage void __init xen_start_kernel(void) __userpte_alloc_gfp &= ~__GFP_HIGHMEM; /* Work out if we support NX */ @@ -22960,7 +23647,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/enlighten.c linux-3.0.9/arch/x86/xen/enlight xen_setup_features(); -@@ -1165,13 +1173,6 @@ asmlinkage void __init xen_start_kernel( +@@ -1165,13 +1173,6 @@ asmlinkage void __init xen_start_kernel(void) machine_ops = xen_machine_ops; @@ -22974,10 +23661,11 @@ diff -urNp linux-3.0.9/arch/x86/xen/enlighten.c linux-3.0.9/arch/x86/xen/enlight xen_smp_init(); #ifdef CONFIG_ACPI_NUMA -diff -urNp linux-3.0.9/arch/x86/xen/mmu.c linux-3.0.9/arch/x86/xen/mmu.c ---- linux-3.0.9/arch/x86/xen/mmu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/xen/mmu.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1683,6 +1683,8 @@ pgd_t * __init xen_setup_kernel_pagetabl +diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c +index 5f76c0a..809e8b5 100644 +--- a/arch/x86/xen/mmu.c ++++ b/arch/x86/xen/mmu.c +@@ -1683,6 +1683,8 @@ pgd_t * __init xen_setup_kernel_pagetable(pgd_t *pgd, convert_pfn_mfn(init_level4_pgt); convert_pfn_mfn(level3_ident_pgt); convert_pfn_mfn(level3_kernel_pgt); @@ -22986,7 +23674,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/mmu.c linux-3.0.9/arch/x86/xen/mmu.c l3 = m2v(pgd[pgd_index(__START_KERNEL_map)].pgd); l2 = m2v(l3[pud_index(__START_KERNEL_map)].pud); -@@ -1701,7 +1703,10 @@ pgd_t * __init xen_setup_kernel_pagetabl +@@ -1701,7 +1703,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); @@ -22997,7 +23685,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/mmu.c linux-3.0.9/arch/x86/xen/mmu.c set_page_prot(level2_kernel_pgt, PAGE_KERNEL_RO); set_page_prot(level2_fixmap_pgt, PAGE_KERNEL_RO); -@@ -1913,6 +1918,7 @@ static void __init xen_post_allocator_in +@@ -1913,6 +1918,7 @@ static void __init xen_post_allocator_init(void) pv_mmu_ops.set_pud = xen_set_pud; #if PAGETABLE_LEVELS == 4 pv_mmu_ops.set_pgd = xen_set_pgd; @@ -23005,7 +23693,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/mmu.c linux-3.0.9/arch/x86/xen/mmu.c #endif /* This will work as long as patching hasn't happened yet -@@ -1994,6 +2000,7 @@ static const struct pv_mmu_ops xen_mmu_o +@@ -1994,6 +2000,7 @@ static const struct pv_mmu_ops xen_mmu_ops __initconst = { .pud_val = PV_CALLEE_SAVE(xen_pud_val), .make_pud = PV_CALLEE_SAVE(xen_make_pud), .set_pgd = xen_set_pgd_hyper, @@ -23013,10 +23701,11 @@ diff -urNp linux-3.0.9/arch/x86/xen/mmu.c linux-3.0.9/arch/x86/xen/mmu.c .alloc_pud = xen_alloc_pmd_init, .release_pud = xen_release_pmd_init, -diff -urNp linux-3.0.9/arch/x86/xen/smp.c linux-3.0.9/arch/x86/xen/smp.c ---- linux-3.0.9/arch/x86/xen/smp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/xen/smp.c 2011-11-12 12:47:13.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 d4fc6d4..117a268 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() != 0); native_smp_prepare_boot_cpu(); @@ -23028,7 +23717,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/smp.c linux-3.0.9/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 task_struct *idle) gdt = get_cpu_gdt_table(cpu); ctxt->flags = VGCF_IN_KERNEL; @@ -23044,7 +23733,7 @@ diff -urNp linux-3.0.9/arch/x86/xen/smp.c linux-3.0.9/arch/x86/xen/smp.c #else ctxt->gs_base_kernel = 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; per_cpu(current_task, cpu) = idle; @@ -23060,9 +23749,10 @@ diff -urNp linux-3.0.9/arch/x86/xen/smp.c linux-3.0.9/arch/x86/xen/smp.c #endif xen_setup_runstate_info(cpu); xen_setup_timer(cpu); -diff -urNp linux-3.0.9/arch/x86/xen/xen-asm_32.S linux-3.0.9/arch/x86/xen/xen-asm_32.S ---- linux-3.0.9/arch/x86/xen/xen-asm_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/xen/xen-asm_32.S 2011-11-12 12:47:13.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=4 # bytes pushed onto stack @@ -23084,9 +23774,10 @@ diff -urNp linux-3.0.9/arch/x86/xen/xen-asm_32.S linux-3.0.9/arch/x86/xen/xen-as #else movl xen_vcpu, %eax #endif -diff -urNp linux-3.0.9/arch/x86/xen/xen-head.S linux-3.0.9/arch/x86/xen/xen-head.S ---- linux-3.0.9/arch/x86/xen/xen-head.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/xen/xen-head.S 2011-11-12 12:47:13.000000000 -0500 +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 @@ -23105,9 +23796,10 @@ diff -urNp linux-3.0.9/arch/x86/xen/xen-head.S linux-3.0.9/arch/x86/xen/xen-head #else mov %rsi,xen_start_info mov $init_thread_union+THREAD_SIZE,%rsp -diff -urNp linux-3.0.9/arch/x86/xen/xen-ops.h linux-3.0.9/arch/x86/xen/xen-ops.h ---- linux-3.0.9/arch/x86/xen/xen-ops.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/arch/x86/xen/xen-ops.h 2011-11-12 12:47:13.000000000 -0500 +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[]; @@ -23117,10 +23809,11 @@ diff -urNp linux-3.0.9/arch/x86/xen/xen-ops.h linux-3.0.9/arch/x86/xen/xen-ops.h struct trap_info; void xen_copy_trap_info(struct trap_info *traps); -diff -urNp linux-3.0.9/block/blk-iopoll.c linux-3.0.9/block/blk-iopoll.c ---- linux-3.0.9/block/blk-iopoll.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/block/blk-iopoll.c 2011-11-12 12:47:13.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); @@ -23129,10 +23822,11 @@ diff -urNp linux-3.0.9/block/blk-iopoll.c linux-3.0.9/block/blk-iopoll.c { struct list_head *list = &__get_cpu_var(blk_cpu_iopoll); int rearm = 0, budget = blk_iopoll_budget; -diff -urNp linux-3.0.9/block/blk-map.c linux-3.0.9/block/blk-map.c ---- linux-3.0.9/block/blk-map.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/block/blk-map.c 2011-11-12 12:47:13.000000000 -0500 -@@ -301,7 +301,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; @@ -23141,10 +23835,11 @@ diff -urNp linux-3.0.9/block/blk-map.c linux-3.0.9/block/blk-map.c if (do_copy) bio = bio_copy_kern(q, kbuf, len, gfp_mask, reading); else -diff -urNp linux-3.0.9/block/blk-softirq.c linux-3.0.9/block/blk-softirq.c ---- linux-3.0.9/block/blk-softirq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/block/blk-softirq.c 2011-11-12 12:47:13.000000000 -0500 -@@ -17,7 +17,7 @@ static DEFINE_PER_CPU(struct list_head, +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 them * while passing them to the queue registered handler. */ @@ -23153,10 +23848,11 @@ diff -urNp linux-3.0.9/block/blk-softirq.c linux-3.0.9/block/blk-softirq.c { struct list_head *cpu_list, local_list; -diff -urNp linux-3.0.9/block/bsg.c linux-3.0.9/block/bsg.c ---- linux-3.0.9/block/bsg.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/block/bsg.c 2011-11-12 12:47:13.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 0c8b64a..0115e08 100644 +--- a/block/bsg.c ++++ b/block/bsg.c +@@ -176,16 +176,24 @@ static int blk_fill_sgv4_hdr_rq(struct request_queue *q, struct request *rq, struct sg_io_v4 *hdr, struct bsg_device *bd, fmode_t has_write_perm) { @@ -23183,7 +23879,7 @@ diff -urNp linux-3.0.9/block/bsg.c linux-3.0.9/block/bsg.c if (hdr->subprotocol == BSG_SUB_PROTOCOL_SCSI_CMD) { if (blk_verify_command(rq->cmd, has_write_perm)) return -EPERM; -@@ -249,7 +257,7 @@ bsg_map_hdr(struct bsg_device *bd, struc +@@ -249,7 +257,7 @@ bsg_map_hdr(struct bsg_device *bd, struct sg_io_v4 *hdr, fmode_t has_write_perm, struct request *rq, *next_rq = NULL; int ret, rw; unsigned int dxfer_len; @@ -23192,7 +23888,7 @@ diff -urNp linux-3.0.9/block/bsg.c linux-3.0.9/block/bsg.c struct bsg_class_device *bcd = &q->bsg_dev; /* if the LLD has been removed then the bsg_unregister_queue will -@@ -291,7 +299,7 @@ bsg_map_hdr(struct bsg_device *bd, struc +@@ -291,7 +299,7 @@ bsg_map_hdr(struct bsg_device *bd, struct sg_io_v4 *hdr, fmode_t has_write_perm, rq->next_rq = next_rq; next_rq->cmd_type = rq->cmd_type; @@ -23201,7 +23897,7 @@ diff -urNp linux-3.0.9/block/bsg.c linux-3.0.9/block/bsg.c ret = blk_rq_map_user(q, next_rq, NULL, dxferp, hdr->din_xfer_len, GFP_KERNEL); if (ret) -@@ -300,10 +308,10 @@ bsg_map_hdr(struct bsg_device *bd, struc +@@ -300,10 +308,10 @@ bsg_map_hdr(struct bsg_device *bd, struct sg_io_v4 *hdr, fmode_t has_write_perm, if (hdr->dout_xfer_len) { dxfer_len = hdr->dout_xfer_len; @@ -23214,7 +23910,7 @@ diff -urNp linux-3.0.9/block/bsg.c linux-3.0.9/block/bsg.c } else dxfer_len = 0; -@@ -445,7 +453,7 @@ static int blk_complete_sgv4_hdr_rq(stru +@@ -445,7 +453,7 @@ static int blk_complete_sgv4_hdr_rq(struct request *rq, struct sg_io_v4 *hdr, int len = min_t(unsigned int, hdr->max_response_len, rq->sense_len); @@ -23223,10 +23919,11 @@ diff -urNp linux-3.0.9/block/bsg.c linux-3.0.9/block/bsg.c rq->sense, len); if (!ret) hdr->response_len = len; -diff -urNp linux-3.0.9/block/compat_ioctl.c linux-3.0.9/block/compat_ioctl.c ---- linux-3.0.9/block/compat_ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/block/compat_ioctl.c 2011-11-12 12:47:13.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 cc3eb78..2ffe28d 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 |= __get_user(f->spec1, &uf->spec1); err |= __get_user(f->fmt_gap, &uf->fmt_gap); err |= __get_user(name, &uf->name); @@ -23235,9 +23932,10 @@ diff -urNp linux-3.0.9/block/compat_ioctl.c linux-3.0.9/block/compat_ioctl.c if (err) { err = -EFAULT; goto out; -diff -urNp linux-3.0.9/block/scsi_ioctl.c linux-3.0.9/block/scsi_ioctl.c ---- linux-3.0.9/block/scsi_ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/block/scsi_ioctl.c 2011-11-12 12:47:13.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 *rq, struct sg_io_hdr *hdr, fmode_t mode) @@ -23260,7 +23958,7 @@ diff -urNp linux-3.0.9/block/scsi_ioctl.c linux-3.0.9/block/scsi_ioctl.c if (blk_verify_command(rq->cmd, mode & FMODE_WRITE)) return -EPERM; -@@ -432,6 +444,8 @@ int sg_scsi_ioctl(struct request_queue * +@@ -432,6 +444,8 @@ int sg_scsi_ioctl(struct request_queue *q, struct gendisk *disk, fmode_t mode, int err; unsigned int in_len, out_len, bytes, opcode, cmdlen; char *buffer = NULL, sense[SCSI_SENSE_BUFFERSIZE]; @@ -23269,7 +23967,7 @@ diff -urNp linux-3.0.9/block/scsi_ioctl.c linux-3.0.9/block/scsi_ioctl.c 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 gendisk *disk, fmode_t mode, */ err = -EFAULT; rq->cmd_len = cmdlen; @@ -23289,9 +23987,10 @@ diff -urNp linux-3.0.9/block/scsi_ioctl.c linux-3.0.9/block/scsi_ioctl.c if (in_len && copy_from_user(buffer, sic->data + cmdlen, in_len)) goto error; -diff -urNp linux-3.0.9/crypto/cryptd.c linux-3.0.9/crypto/cryptd.c ---- linux-3.0.9/crypto/cryptd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/crypto/cryptd.c 2011-11-12 12:47:13.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 { struct cryptd_blkcipher_request_ctx { @@ -23310,10 +24009,11 @@ diff -urNp linux-3.0.9/crypto/cryptd.c linux-3.0.9/crypto/cryptd.c static void cryptd_queue_worker(struct work_struct *work); -diff -urNp linux-3.0.9/crypto/gf128mul.c linux-3.0.9/crypto/gf128mul.c ---- linux-3.0.9/crypto/gf128mul.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/crypto/gf128mul.c 2011-11-12 12:47:13.000000000 -0500 -@@ -182,7 +182,7 @@ void gf128mul_lle(be128 *r, const be128 +diff --git a/crypto/gf128mul.c b/crypto/gf128mul.c +index df35e4c..5276607 100644 +--- a/crypto/gf128mul.c ++++ b/crypto/gf128mul.c +@@ -182,7 +182,7 @@ void gf128mul_lle(be128 *r, const be128 *b) for (i = 0; i < 7; ++i) gf128mul_x_lle(&p[i + 1], &p[i]); @@ -23322,7 +24022,7 @@ diff -urNp linux-3.0.9/crypto/gf128mul.c linux-3.0.9/crypto/gf128mul.c for (i = 0;;) { u8 ch = ((u8 *)b)[15 - i]; -@@ -220,7 +220,7 @@ void gf128mul_bbe(be128 *r, const be128 +@@ -220,7 +220,7 @@ void gf128mul_bbe(be128 *r, const be128 *b) for (i = 0; i < 7; ++i) gf128mul_x_bbe(&p[i + 1], &p[i]); @@ -23331,10 +24031,11 @@ diff -urNp linux-3.0.9/crypto/gf128mul.c linux-3.0.9/crypto/gf128mul.c for (i = 0;;) { u8 ch = ((u8 *)b)[i]; -diff -urNp linux-3.0.9/crypto/serpent.c linux-3.0.9/crypto/serpent.c ---- linux-3.0.9/crypto/serpent.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/crypto/serpent.c 2011-11-12 12:47:13.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, const u8 *key, u32 r0,r1,r2,r3,r4; int i; @@ -23343,166 +24044,10 @@ diff -urNp linux-3.0.9/crypto/serpent.c linux-3.0.9/crypto/serpent.c /* Copy key, add padding */ for (i = 0; i < keylen; ++i) -diff -urNp linux-3.0.9/Documentation/dontdiff linux-3.0.9/Documentation/dontdiff ---- linux-3.0.9/Documentation/dontdiff 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/Documentation/dontdiff 2011-11-12 12:47:13.000000000 -0500 -@@ -5,6 +5,7 @@ - *.cis - *.cpio - *.csp -+*.dbg - *.dsp - *.dvi - *.elf -@@ -48,9 +49,11 @@ - *.tab.h - *.tex - *.ver -+*.vim - *.xml - *.xz - *_MODULES -+*_reg_safe.h - *_vga16.c - *~ - \#*# -@@ -70,6 +73,7 @@ Kerntypes - Module.markers - Module.symvers - PENDING -+PERF* - SCCS - System.map* - TAGS -@@ -98,14 +102,18 @@ 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 -@@ -126,12 +134,14 @@ 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 - hpet_example - hugepage-mmap - hugepage-shm -@@ -146,7 +156,7 @@ int32.c - int4.c - int8.c - kallsyms --kconfig -+kern_constants.h - keywords.c - ksym.c* - ksym.h* -@@ -154,7 +164,6 @@ kxgettext - lkc_defs.h - lex.c - lex.*.c --linux - logo_*.c - logo_*_clut224.c - logo_*_mono.c -@@ -166,7 +175,6 @@ machtypes.h - map - map_hugetlb - maui_boot.h --media - mconf - miboot* - mk_elfconfig -@@ -174,6 +182,7 @@ mkboot - mkbugboot - mkcpustr - mkdep -+mkpiggy - mkprep - mkregtable - mktables -@@ -209,6 +218,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 +229,7 @@ setup - setup.bin - setup.elf - sImage -+slabinfo - sm_tbl* - split-include - syscalltab.h -@@ -229,6 +240,7 @@ tftpboot.img - timeconst.h - times.h* - trix_boot.h -+user_constants.h - utsrelease.h* - vdso-syms.lds - vdso.lds -@@ -246,7 +258,9 @@ vmlinux - vmlinux-* - vmlinux.aout - vmlinux.bin.all -+vmlinux.bin.bz2 - vmlinux.lds -+vmlinux.relocs - vmlinuz - voffset.h - vsyscall.lds -@@ -254,6 +268,7 @@ vsyscall_32.lds - wanxlfw.inc - uImage - unifdef -+utsrelease.h - wakeup.bin - wakeup.elf - wakeup.lds -diff -urNp linux-3.0.9/Documentation/kernel-parameters.txt linux-3.0.9/Documentation/kernel-parameters.txt ---- linux-3.0.9/Documentation/kernel-parameters.txt 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/Documentation/kernel-parameters.txt 2011-11-12 12:47:13.000000000 -0500 -@@ -1883,6 +1883,13 @@ bytes respectively. Such letter suffixes - the specified number of seconds. This is to be used if - your oopses keep scrolling off the screen. - -+ 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= 0/1 to disable/enable PaX softmode on boot already. -+ - pcbit= [HW,ISDN] - - pcd. [PARIDE] -diff -urNp linux-3.0.9/drivers/acpi/apei/cper.c linux-3.0.9/drivers/acpi/apei/cper.c ---- linux-3.0.9/drivers/acpi/apei/cper.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/acpi/apei/cper.c 2011-11-12 12:47:13.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) @@ -23520,9 +24065,10 @@ diff -urNp linux-3.0.9/drivers/acpi/apei/cper.c linux-3.0.9/drivers/acpi/apei/cp } EXPORT_SYMBOL_GPL(cper_next_record_id); -diff -urNp linux-3.0.9/drivers/acpi/ec_sys.c linux-3.0.9/drivers/acpi/ec_sys.c ---- linux-3.0.9/drivers/acpi/ec_sys.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/acpi/ec_sys.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/acpi/ec_sys.c b/drivers/acpi/ec_sys.c +index 05b4420..f1cc3da 100644 +--- a/drivers/acpi/ec_sys.c ++++ b/drivers/acpi/ec_sys.c @@ -11,6 +11,7 @@ #include <linux/kernel.h> #include <linux/acpi.h> @@ -23531,7 +24077,7 @@ diff -urNp linux-3.0.9/drivers/acpi/ec_sys.c linux-3.0.9/drivers/acpi/ec_sys.c #include "internal.h" MODULE_AUTHOR("Thomas Renninger <trenn@suse.de>"); -@@ -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 = ((struct seq_file *)f->private_data)->private; */ unsigned int size = EC_SPACE_SIZE; @@ -23540,7 +24086,7 @@ diff -urNp linux-3.0.9/drivers/acpi/ec_sys.c linux-3.0.9/drivers/acpi/ec_sys.c loff_t init_off = *off; int err = 0; -@@ -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 = count; while (size) { @@ -23553,7 +24099,7 @@ diff -urNp linux-3.0.9/drivers/acpi/ec_sys.c linux-3.0.9/drivers/acpi/ec_sys.c *off += 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, unsigned int size = count; loff_t init_off = *off; @@ -23561,7 +24107,7 @@ diff -urNp linux-3.0.9/drivers/acpi/ec_sys.c linux-3.0.9/drivers/acpi/ec_sys.c int err = 0; if (*off >= 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, } while (size) { @@ -23572,35 +24118,36 @@ diff -urNp linux-3.0.9/drivers/acpi/ec_sys.c linux-3.0.9/drivers/acpi/ec_sys.c err = ec_write(*off, byte_write); if (err) return err; -diff -urNp linux-3.0.9/drivers/acpi/proc.c linux-3.0.9/drivers/acpi/proc.c ---- linux-3.0.9/drivers/acpi/proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/acpi/proc.c 2011-11-12 12:47:13.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] = ""; - unsigned int len = count; -- ++ char strbuf[5] = {0}; + - if (len > 4) - len = 4; - if (len < 0) -- return -EFAULT; -+ char strbuf[5] = {0}; - -- if (copy_from_user(strbuf, buffer, len)) + if (count > 4) + count = 4; + if (copy_from_user(strbuf, buffer, count)) return -EFAULT; +- +- if (copy_from_user(strbuf, buffer, len)) +- return -EFAULT; - strbuf[len] = '\0'; - sscanf(strbuf, "%s", str); + strbuf[count] = '\0'; 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; @@ -23609,10 +24156,11 @@ diff -urNp linux-3.0.9/drivers/acpi/proc.c linux-3.0.9/drivers/acpi/proc.c if (device_can_wakeup(&dev->dev)) { bool enable = !device_may_wakeup(&dev->dev); device_set_wakeup_enable(&dev->dev, enable); -diff -urNp linux-3.0.9/drivers/acpi/processor_driver.c linux-3.0.9/drivers/acpi/processor_driver.c ---- linux-3.0.9/drivers/acpi/processor_driver.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/acpi/processor_driver.c 2011-11-12 12:47:13.000000000 -0500 -@@ -473,7 +473,7 @@ static int __cpuinit acpi_processor_add( +diff --git a/drivers/acpi/processor_driver.c b/drivers/acpi/processor_driver.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 @@ -23621,10 +24169,11 @@ diff -urNp linux-3.0.9/drivers/acpi/processor_driver.c linux-3.0.9/drivers/acpi/ /* * Buggy BIOS check -diff -urNp linux-3.0.9/drivers/ata/libata-core.c linux-3.0.9/drivers/ata/libata-core.c ---- linux-3.0.9/drivers/ata/libata-core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ata/libata-core.c 2011-11-12 12:47:13.000000000 -0500 -@@ -4753,7 +4753,7 @@ void ata_qc_free(struct ata_queued_cmd * +diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c +index 000d03a..36c5da0 100644 +--- a/drivers/ata/libata-core.c ++++ b/drivers/ata/libata-core.c +@@ -4753,7 +4753,7 @@ void ata_qc_free(struct ata_queued_cmd *qc) struct ata_port *ap; unsigned int tag; @@ -23633,7 +24182,7 @@ diff -urNp linux-3.0.9/drivers/ata/libata-core.c linux-3.0.9/drivers/ata/libata- ap = qc->ap; qc->flags = 0; -@@ -4769,7 +4769,7 @@ void __ata_qc_complete(struct ata_queued +@@ -4769,7 +4769,7 @@ void __ata_qc_complete(struct ata_queued_cmd *qc) struct ata_port *ap; struct ata_link *link; @@ -23642,7 +24191,7 @@ diff -urNp linux-3.0.9/drivers/ata/libata-core.c linux-3.0.9/drivers/ata/libata- WARN_ON_ONCE(!(qc->flags & ATA_QCFLAG_ACTIVE)); ap = qc->ap; link = qc->dev->link; -@@ -5774,6 +5774,7 @@ static void ata_finalize_port_ops(struct +@@ -5774,6 +5774,7 @@ static void ata_finalize_port_ops(struct ata_port_operations *ops) return; spin_lock(&lock); @@ -23650,7 +24199,7 @@ diff -urNp linux-3.0.9/drivers/ata/libata-core.c linux-3.0.9/drivers/ata/libata- for (cur = ops->inherits; cur; cur = cur->inherits) { void **inherit = (void **)cur; -@@ -5787,8 +5788,9 @@ static void ata_finalize_port_ops(struct +@@ -5787,8 +5788,9 @@ static void ata_finalize_port_ops(struct ata_port_operations *ops) if (IS_ERR(*pp)) *pp = NULL; @@ -23661,9 +24210,10 @@ diff -urNp linux-3.0.9/drivers/ata/libata-core.c linux-3.0.9/drivers/ata/libata- spin_unlock(&lock); } -diff -urNp linux-3.0.9/drivers/ata/libata-eh.c linux-3.0.9/drivers/ata/libata-eh.c ---- linux-3.0.9/drivers/ata/libata-eh.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ata/libata-eh.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c +index 7f099d6..0d42651 100644 +--- a/drivers/ata/libata-eh.c ++++ b/drivers/ata/libata-eh.c @@ -2518,6 +2518,8 @@ void ata_eh_report(struct ata_port *ap) { struct ata_link *link; @@ -23673,10 +24223,11 @@ diff -urNp linux-3.0.9/drivers/ata/libata-eh.c linux-3.0.9/drivers/ata/libata-eh ata_for_each_link(link, ap, HOST_FIRST) ata_eh_link_report(link); } -diff -urNp linux-3.0.9/drivers/ata/pata_arasan_cf.c linux-3.0.9/drivers/ata/pata_arasan_cf.c ---- linux-3.0.9/drivers/ata/pata_arasan_cf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ata/pata_arasan_cf.c 2011-11-12 12:47:13.000000000 -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) { @@ -23687,10 +24238,11 @@ diff -urNp linux-3.0.9/drivers/ata/pata_arasan_cf.c linux-3.0.9/drivers/ata/pata ap->pio_mask = 0; } if (pdata->quirk & CF_BROKEN_MWDMA) -diff -urNp linux-3.0.9/drivers/atm/adummy.c linux-3.0.9/drivers/atm/adummy.c ---- linux-3.0.9/drivers/atm/adummy.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/adummy.c 2011-11-12 12:47:13.000000000 -0500 -@@ -114,7 +114,7 @@ adummy_send(struct atm_vcc *vcc, struct +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); @@ -23699,10 +24251,11 @@ diff -urNp linux-3.0.9/drivers/atm/adummy.c linux-3.0.9/drivers/atm/adummy.c return 0; } -diff -urNp linux-3.0.9/drivers/atm/ambassador.c linux-3.0.9/drivers/atm/ambassador.c ---- linux-3.0.9/drivers/atm/ambassador.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/ambassador.c 2011-11-12 12:47:13.000000000 -0500 -@@ -454,7 +454,7 @@ static void tx_complete (amb_dev * dev, +diff --git a/drivers/atm/ambassador.c b/drivers/atm/ambassador.c +index a5fcb1e..4da3c32 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); // VC layer stats @@ -23711,7 +24264,7 @@ diff -urNp linux-3.0.9/drivers/atm/ambassador.c linux-3.0.9/drivers/atm/ambassad // free the descriptor kfree (tx_descr); -@@ -495,7 +495,7 @@ static void rx_complete (amb_dev * dev, +@@ -495,7 +495,7 @@ static void rx_complete (amb_dev * dev, rx_out * rx) { dump_skb ("<<<", vc, skb); // VC layer stats @@ -23720,7 +24273,7 @@ diff -urNp linux-3.0.9/drivers/atm/ambassador.c linux-3.0.9/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, +@@ -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? @@ -23729,7 +24282,7 @@ diff -urNp linux-3.0.9/drivers/atm/ambassador.c linux-3.0.9/drivers/atm/ambassad } } else { -@@ -1342,7 +1342,7 @@ static int amb_send (struct atm_vcc * at +@@ -1342,7 +1342,7 @@ static int amb_send (struct atm_vcc * atm_vcc, struct sk_buff * skb) { } if (check_area (skb->data, skb->len)) { @@ -23738,10 +24291,11 @@ diff -urNp linux-3.0.9/drivers/atm/ambassador.c linux-3.0.9/drivers/atm/ambassad return -ENOMEM; // ? } -diff -urNp linux-3.0.9/drivers/atm/atmtcp.c linux-3.0.9/drivers/atm/atmtcp.c ---- linux-3.0.9/drivers/atm/atmtcp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/atmtcp.c 2011-11-12 12:47:13.000000000 -0500 -@@ -207,7 +207,7 @@ static int atmtcp_v_send(struct atm_vcc +diff --git a/drivers/atm/atmtcp.c b/drivers/atm/atmtcp.c +index 0b06250..9a7e2d8 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; @@ -23750,7 +24304,7 @@ diff -urNp linux-3.0.9/drivers/atm/atmtcp.c linux-3.0.9/drivers/atm/atmtcp.c return -ENOLINK; } size = skb->len+sizeof(struct atmtcp_hdr); -@@ -215,7 +215,7 @@ static int atmtcp_v_send(struct atm_vcc +@@ -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); @@ -23759,7 +24313,7 @@ diff -urNp linux-3.0.9/drivers/atm/atmtcp.c linux-3.0.9/drivers/atm/atmtcp.c return -ENOBUFS; } hdr = (void *) skb_put(new_skb,sizeof(struct atmtcp_hdr)); -@@ -226,8 +226,8 @@ static int atmtcp_v_send(struct atm_vcc +@@ -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); @@ -23770,7 +24324,7 @@ diff -urNp linux-3.0.9/drivers/atm/atmtcp.c linux-3.0.9/drivers/atm/atmtcp.c return 0; } -@@ -301,7 +301,7 @@ static int atmtcp_c_send(struct atm_vcc +@@ -301,7 +301,7 @@ static int atmtcp_c_send(struct atm_vcc *vcc,struct sk_buff *skb) out_vcc = find_vcc(dev, ntohs(hdr->vpi), ntohs(hdr->vci)); read_unlock(&vcc_sklist_lock); if (!out_vcc) { @@ -23779,7 +24333,7 @@ diff -urNp linux-3.0.9/drivers/atm/atmtcp.c linux-3.0.9/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 +@@ -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); @@ -23790,9 +24344,10 @@ diff -urNp linux-3.0.9/drivers/atm/atmtcp.c linux-3.0.9/drivers/atm/atmtcp.c done: if (vcc->pop) vcc->pop(vcc,skb); else dev_kfree_skb(skb); -diff -urNp linux-3.0.9/drivers/atm/eni.c linux-3.0.9/drivers/atm/eni.c ---- linux-3.0.9/drivers/atm/eni.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/eni.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/atm/eni.c b/drivers/atm/eni.c +index 3230ea0..ffa1fa1 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); @@ -23829,7 +24384,7 @@ diff -urNp linux-3.0.9/drivers/atm/eni.c linux-3.0.9/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); @@ -23847,10 +24402,11 @@ diff -urNp linux-3.0.9/drivers/atm/eni.c linux-3.0.9/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.0.9/drivers/atm/firestream.c linux-3.0.9/drivers/atm/firestream.c ---- linux-3.0.9/drivers/atm/firestream.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/firestream.c 2011-11-12 12:47:13.000000000 -0500 -@@ -749,7 +749,7 @@ static void process_txdone_queue (struct +diff --git a/drivers/atm/firestream.c b/drivers/atm/firestream.c +index ef7a658..04b6ef8 100644 +--- a/drivers/atm/firestream.c ++++ b/drivers/atm/firestream.c +@@ -749,7 +749,7 @@ static void process_txdone_queue (struct fs_dev *dev, struct queue *q) } } @@ -23859,7 +24415,7 @@ diff -urNp linux-3.0.9/drivers/atm/firestream.c linux-3.0.9/drivers/atm/firestre fs_dprintk (FS_DEBUG_TXMEM, "i"); fs_dprintk (FS_DEBUG_ALLOC, "Free t-skb: %p\n", skb); -@@ -816,7 +816,7 @@ static void process_incoming (struct fs_ +@@ -816,7 +816,7 @@ static void process_incoming (struct fs_dev *dev, struct queue *q) #endif skb_put (skb, qe->p1 & 0xffff); ATM_SKB(skb)->vcc = atm_vcc; @@ -23868,7 +24424,7 @@ diff -urNp linux-3.0.9/drivers/atm/firestream.c linux-3.0.9/drivers/atm/firestre __net_timestamp(skb); fs_dprintk (FS_DEBUG_ALLOC, "Free rec-skb: %p (pushed)\n", skb); atm_vcc->push (atm_vcc, skb); -@@ -837,12 +837,12 @@ static void process_incoming (struct fs_ +@@ -837,12 +837,12 @@ static void process_incoming (struct fs_dev *dev, struct queue *q) kfree (pe); } if (atm_vcc) @@ -23883,10 +24439,11 @@ diff -urNp linux-3.0.9/drivers/atm/firestream.c linux-3.0.9/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", -diff -urNp linux-3.0.9/drivers/atm/fore200e.c linux-3.0.9/drivers/atm/fore200e.c ---- linux-3.0.9/drivers/atm/fore200e.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/fore200e.c 2011-11-12 12:47:13.000000000 -0500 -@@ -933,9 +933,9 @@ fore200e_tx_irq(struct fore200e* fore200 +diff --git a/drivers/atm/fore200e.c b/drivers/atm/fore200e.c +index bc9e702..ce4742a 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) @@ -23898,7 +24455,7 @@ diff -urNp linux-3.0.9/drivers/atm/fore200e.c linux-3.0.9/drivers/atm/fore200e.c } } -@@ -1084,7 +1084,7 @@ fore200e_push_rpd(struct fore200e* fore2 +@@ -1084,7 +1084,7 @@ fore200e_push_rpd(struct fore200e* fore200e, struct atm_vcc* vcc, struct rpd* rp if (skb == NULL) { DPRINTK(2, "unable to alloc new skb, rx PDU length = %d\n", pdu_len); @@ -23907,7 +24464,7 @@ diff -urNp linux-3.0.9/drivers/atm/fore200e.c linux-3.0.9/drivers/atm/fore200e.c return -ENOMEM; } -@@ -1127,14 +1127,14 @@ fore200e_push_rpd(struct fore200e* fore2 +@@ -1127,14 +1127,14 @@ fore200e_push_rpd(struct fore200e* fore200e, struct atm_vcc* vcc, struct rpd* rp dev_kfree_skb_any(skb); @@ -23924,7 +24481,7 @@ diff -urNp linux-3.0.9/drivers/atm/fore200e.c linux-3.0.9/drivers/atm/fore200e.c ASSERT(atomic_read(&sk_atm(vcc)->sk_wmem_alloc) >= 0); -@@ -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); @@ -23933,7 +24490,7 @@ diff -urNp linux-3.0.9/drivers/atm/fore200e.c linux-3.0.9/drivers/atm/fore200e.c } } -@@ -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; } @@ -23942,10 +24499,11 @@ diff -urNp linux-3.0.9/drivers/atm/fore200e.c linux-3.0.9/drivers/atm/fore200e.c fore200e->tx_sat++; DPRINTK(2, "tx queue of device %s is saturated, PDU dropped - heartbeat is %08x\n", -diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/drivers/atm/he.c ---- linux-3.0.9/drivers/atm/he.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/he.c 2011-11-12 12:47:13.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) if (RBRQ_HBUF_ERR(he_dev->rbrq_head)) { hprintk("HBUF_ERR! (cid 0x%x)\n", cid); @@ -23954,7 +24512,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/drivers/atm/he.c goto return_host_buffers; } -@@ -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); @@ -23963,7 +24521,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/drivers/atm/he.c goto return_host_buffers; } -@@ -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); @@ -23972,7 +24530,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/drivers/atm/he.c 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); @@ -23981,7 +24539,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/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); @@ -23990,7 +24548,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/drivers/atm/he.c return -EINVAL; } -@@ -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); @@ -23999,7 +24557,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/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); @@ -24008,7 +24566,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/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); @@ -24017,7 +24575,7 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/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); @@ -24026,10 +24584,11 @@ diff -urNp linux-3.0.9/drivers/atm/he.c linux-3.0.9/drivers/atm/he.c return 0; } -diff -urNp linux-3.0.9/drivers/atm/horizon.c linux-3.0.9/drivers/atm/horizon.c ---- linux-3.0.9/drivers/atm/horizon.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/horizon.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1034,7 +1034,7 @@ static void rx_schedule (hrz_dev * dev, +diff --git a/drivers/atm/horizon.c b/drivers/atm/horizon.c +index d58e3fc..92b6e00 100644 +--- a/drivers/atm/horizon.c ++++ b/drivers/atm/horizon.c +@@ -1034,7 +1034,7 @@ static void rx_schedule (hrz_dev * dev, int irq) { { struct atm_vcc * vcc = ATM_SKB(skb)->vcc; // VC layer stats @@ -24038,7 +24597,7 @@ diff -urNp linux-3.0.9/drivers/atm/horizon.c linux-3.0.9/drivers/atm/horizon.c __net_timestamp(skb); // end of our responsibility vcc->push (vcc, skb); -@@ -1186,7 +1186,7 @@ static void tx_schedule (hrz_dev * const +@@ -1186,7 +1186,7 @@ static void tx_schedule (hrz_dev * const dev, int irq) { dev->tx_iovec = NULL; // VC layer stats @@ -24047,10 +24606,11 @@ diff -urNp linux-3.0.9/drivers/atm/horizon.c linux-3.0.9/drivers/atm/horizon.c // free the skb hrz_kfree_skb (skb); -diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c ---- linux-3.0.9/drivers/atm/idt77252.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/idt77252.c 2011-11-12 12:47:13.000000000 -0500 -@@ -811,7 +811,7 @@ drain_scq(struct idt77252_dev *card, str +diff --git a/drivers/atm/idt77252.c b/drivers/atm/idt77252.c +index 1f8d724..aa37fff 100644 +--- a/drivers/atm/idt77252.c ++++ b/drivers/atm/idt77252.c +@@ -811,7 +811,7 @@ drain_scq(struct idt77252_dev *card, struct vc_map *vc) else dev_kfree_skb(skb); @@ -24059,7 +24619,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c } atomic_dec(&scq->used); -@@ -1074,13 +1074,13 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1074,13 +1074,13 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_entry *rsqe) if ((sb = dev_alloc_skb(64)) == NULL) { printk("%s: Can't allocate buffers for aal0.\n", card->name); @@ -24075,7 +24635,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c dev_kfree_skb(sb); break; } -@@ -1097,7 +1097,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1097,7 +1097,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_entry *rsqe) ATM_SKB(sb)->vcc = vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -24084,7 +24644,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c cell += ATM_CELL_PAYLOAD; } -@@ -1134,13 +1134,13 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1134,13 +1134,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); @@ -24100,7 +24660,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c return; } if (skb_queue_len(&rpp->queue) > 1) { -@@ -1151,7 +1151,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1151,7 +1151,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_entry *rsqe) RXPRINTK("%s: Can't alloc RX skb.\n", card->name); recycle_rx_pool_skb(card, rpp); @@ -24109,7 +24669,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c return; } if (!atm_charge(vcc, skb->truesize)) { -@@ -1170,7 +1170,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1170,7 +1170,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_entry *rsqe) __net_timestamp(skb); vcc->push(vcc, skb); @@ -24118,7 +24678,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c return; } -@@ -1192,7 +1192,7 @@ dequeue_rx(struct idt77252_dev *card, st +@@ -1192,7 +1192,7 @@ dequeue_rx(struct idt77252_dev *card, struct rsq_entry *rsqe) __net_timestamp(skb); vcc->push(vcc, skb); @@ -24127,7 +24687,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c 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 != ATM_AAL0) { RPRINTK("%s: raw cell for non AAL0 vc %u.%u\n", card->name, vpi, vci); @@ -24144,7 +24704,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c goto drop; } -@@ -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 = vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -24153,7 +24713,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c 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) if (vc == NULL) { printk("%s: NULL connection in send().\n", card->name); @@ -24169,7 +24729,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c 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); @@ -24186,7 +24746,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c 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_buff *skb, int oam) err = queue_skb(card, vc, skb, oam); if (err) { @@ -24195,7 +24755,7 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c 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 = dev_alloc_skb(64); if (!skb) { printk("%s: Out of memory in send_oam().\n", card->name); @@ -24204,10 +24764,11 @@ diff -urNp linux-3.0.9/drivers/atm/idt77252.c linux-3.0.9/drivers/atm/idt77252.c return -ENOMEM; } atomic_add(skb->truesize, &sk_atm(vcc)->sk_wmem_alloc); -diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c ---- linux-3.0.9/drivers/atm/iphase.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/iphase.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1120,7 +1120,7 @@ static int rx_pkt(struct atm_dev *dev) +diff --git a/drivers/atm/iphase.c b/drivers/atm/iphase.c +index dee4f01..bec4c50 100644 +--- a/drivers/atm/iphase.c ++++ b/drivers/atm/iphase.c +@@ -1120,7 +1120,7 @@ static int rx_pkt(struct atm_dev *dev) status = (u_short) (buf_desc_ptr->desc_mode); if (status & (RX_CER | RX_PTE | RX_OFL)) { @@ -24216,7 +24777,7 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c IF_ERR(printk("IA: bad packet, dropping it");) if (status & RX_CER) { IF_ERR(printk(" cause: packet CRC error\n");) -@@ -1143,7 +1143,7 @@ static int rx_pkt(struct atm_dev *dev) +@@ -1143,7 +1143,7 @@ static int rx_pkt(struct atm_dev *dev) len = dma_addr - buf_addr; if (len > iadev->rx_buf_sz) { printk("Over %d bytes sdu received, dropped!!!\n", iadev->rx_buf_sz); @@ -24225,7 +24786,7 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c goto out_free_desc; } -@@ -1293,7 +1293,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1293,7 +1293,7 @@ static void rx_dle_intr(struct atm_dev *dev) ia_vcc = INPH_IA_VCC(vcc); if (ia_vcc == NULL) { @@ -24234,7 +24795,7 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c dev_kfree_skb_any(skb); atm_return(vcc, atm_guess_pdu2truesize(len)); goto INCR_DLE; -@@ -1305,7 +1305,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1305,7 +1305,7 @@ static void rx_dle_intr(struct atm_dev *dev) if ((length > iadev->rx_buf_sz) || (length > (skb->len - sizeof(struct cpcs_trailer)))) { @@ -24243,7 +24804,7 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c IF_ERR(printk("rx_dle_intr: Bad AAL5 trailer %d (skb len %d)", length, skb->len);) dev_kfree_skb_any(skb); -@@ -1321,7 +1321,7 @@ static void rx_dle_intr(struct atm_dev * +@@ -1321,7 +1321,7 @@ static void rx_dle_intr(struct atm_dev *dev) IF_RX(printk("rx_dle_intr: skb push");) vcc->push(vcc,skb); @@ -24252,7 +24813,7 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c iadev->rx_pkt_cnt++; } INCR_DLE: -@@ -2801,15 +2801,15 @@ static int ia_ioctl(struct atm_dev *dev, +@@ -2801,15 +2801,15 @@ static int ia_ioctl(struct atm_dev *dev, unsigned int cmd, void __user *arg) { struct k_sonet_stats *stats; stats = &PRIV(_ia_dev[board])->sonet_stats; @@ -24277,7 +24838,7 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c } ia_cmds.status = 0; break; -@@ -2914,7 +2914,7 @@ static int ia_pkt_tx (struct atm_vcc *vc +@@ -2914,7 +2914,7 @@ static int ia_pkt_tx (struct atm_vcc *vcc, struct sk_buff *skb) { if ((desc == 0) || (desc > iadev->num_tx_desc)) { IF_ERR(printk(DEV_LABEL "invalid desc for send: %d\n", desc);) @@ -24286,7 +24847,7 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c if (vcc->pop) vcc->pop(vcc, skb); else -@@ -3019,14 +3019,14 @@ static int ia_pkt_tx (struct atm_vcc *vc +@@ -3019,14 +3019,14 @@ static int ia_pkt_tx (struct atm_vcc *vcc, struct sk_buff *skb) { ATM_DESC(skb) = vcc->vci; skb_queue_tail(&iadev->tx_dma_q, skb); @@ -24303,10 +24864,11 @@ diff -urNp linux-3.0.9/drivers/atm/iphase.c linux-3.0.9/drivers/atm/iphase.c if (iavcc->vc_desc_cnt > 10) { vcc->tx_quota = vcc->tx_quota * 3 / 4; printk("Tx1: vcc->tx_quota = %d \n", (u32)vcc->tx_quota ); -diff -urNp linux-3.0.9/drivers/atm/lanai.c linux-3.0.9/drivers/atm/lanai.c ---- linux-3.0.9/drivers/atm/lanai.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/lanai.c 2011-11-12 12:47:13.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 4e8ba56..900a2ab 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); @@ -24315,7 +24877,7 @@ diff -urNp linux-3.0.9/drivers/atm/lanai.c linux-3.0.9/drivers/atm/lanai.c } /* 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, int endptr) ATM_SKB(skb)->vcc = lvcc->rx.atmvcc; __net_timestamp(skb); lvcc->rx.atmvcc->push(lvcc->rx.atmvcc, skb); @@ -24324,7 +24886,7 @@ diff -urNp linux-3.0.9/drivers/atm/lanai.c linux-3.0.9/drivers/atm/lanai.c out: lvcc->rx.buf.ptr = 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++; @@ -24333,7 +24895,7 @@ diff -urNp linux-3.0.9/drivers/atm/lanai.c linux-3.0.9/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); @@ -24342,7 +24904,7 @@ diff -urNp linux-3.0.9/drivers/atm/lanai.c linux-3.0.9/drivers/atm/lanai.c lvcc->stats.x.aal5.service_trash++; bytes = (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); @@ -24351,7 +24913,7 @@ diff -urNp linux-3.0.9/drivers/atm/lanai.c linux-3.0.9/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); @@ -24360,10 +24922,11 @@ diff -urNp linux-3.0.9/drivers/atm/lanai.c linux-3.0.9/drivers/atm/lanai.c lvcc->stats.x.aal5.service_rxcrc++; lvcc->rx.buf.ptr = &lvcc->rx.buf.start[SERVICE_GET_END(s) * 4]; cardvcc_write(lvcc, SERVICE_GET_END(s), vcc_rxreadptr); -diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c ---- linux-3.0.9/drivers/atm/nicstar.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/nicstar.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1654,7 +1654,7 @@ static int ns_send(struct atm_vcc *vcc, +diff --git a/drivers/atm/nicstar.c b/drivers/atm/nicstar.c +index 6b313ee..3891287 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 = (vc_map *) vcc->dev_data) == NULL) { printk("nicstar%d: vcc->dev_data == NULL on ns_send().\n", card->index); @@ -24372,7 +24935,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1662,7 +1662,7 @@ static int ns_send(struct atm_vcc *vcc, +@@ -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); @@ -24381,7 +24944,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1670,14 +1670,14 @@ static int ns_send(struct atm_vcc *vcc, +@@ -1670,14 +1670,14 @@ static int ns_send(struct atm_vcc *vcc, struct sk_buff *skb) if (vcc->qos.aal != ATM_AAL5 && vcc->qos.aal != ATM_AAL0) { printk("nicstar%d: Only AAL0 and AAL5 are supported.\n", card->index); @@ -24398,7 +24961,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c dev_kfree_skb_any(skb); return -EINVAL; } -@@ -1725,11 +1725,11 @@ static int ns_send(struct atm_vcc *vcc, +@@ -1725,11 +1725,11 @@ static int ns_send(struct atm_vcc *vcc, struct sk_buff *skb) } if (push_scqe(card, vc, scq, &scqe, skb) != 0) { @@ -24412,7 +24975,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c 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); @@ -24429,7 +24992,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/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 * rsqe) ATM_SKB(sb)->vcc = vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -24438,7 +25001,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c cell += ATM_CELL_PAYLOAD; } -@@ -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 * rsqe) if (iovb == NULL) { printk("nicstar%d: Out of iovec buffers.\n", card->index); @@ -24447,7 +25010,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/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 * rsqe) small or large buffer itself. */ } else if (NS_PRV_IOVCNT(iovb) >= NS_MAX_IOVECS) { printk("nicstar%d: received too big AAL5 SDU.\n", card->index); @@ -24456,7 +25019,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c recycle_iovec_rx_bufs(card, (struct iovec *)iovb->data, NS_MAX_IOVECS); NS_PRV_IOVCNT(iovb) = 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 * rsqe) ("nicstar%d: Expected a small buffer, and this is not one.\n", card->index); which_list(card, skb); @@ -24465,7 +25028,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c recycle_rx_buf(card, skb); vc->rx_iov = 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 * rsqe) ("nicstar%d: Expected a large buffer, and this is not one.\n", card->index); which_list(card, skb); @@ -24474,7 +25037,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c recycle_iovec_rx_bufs(card, (struct iovec *)iovb->data, NS_PRV_IOVCNT(iovb)); vc->rx_iov = 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 * rsqe) printk(" - PDU size mismatch.\n"); else printk(".\n"); @@ -24483,7 +25046,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c recycle_iovec_rx_bufs(card, (struct iovec *)iovb->data, NS_PRV_IOVCNT(iovb)); vc->rx_iov = 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 * rsqe) /* skb points to a small buffer */ if (!atm_charge(vcc, skb->truesize)) { push_rxbufs(card, skb); @@ -24492,7 +25055,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/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 * rsqe) ATM_SKB(skb)->vcc = vcc; __net_timestamp(skb); vcc->push(vcc, skb); @@ -24501,7 +25064,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c } } else if (NS_PRV_IOVCNT(iovb) == 2) { /* One small plus one large 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 * rsqe) if (len <= NS_SMBUFSIZE) { if (!atm_charge(vcc, sb->truesize)) { push_rxbufs(card, sb); @@ -24510,7 +25073,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/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 * rsqe) ATM_SKB(sb)->vcc = vcc; __net_timestamp(sb); vcc->push(vcc, sb); @@ -24519,7 +25082,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c } 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 * rsqe) if (!atm_charge(vcc, skb->truesize)) { push_rxbufs(card, skb); @@ -24528,7 +25091,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/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 * rsqe) ATM_SKB(skb)->vcc = vcc; __net_timestamp(skb); vcc->push(vcc, skb); @@ -24537,7 +25100,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c } 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 * rsqe) printk ("nicstar%d: Out of huge buffers.\n", card->index); @@ -24546,7 +25109,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/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 * rsqe) card->hbpool.count++; } else dev_kfree_skb_any(hb); @@ -24555,7 +25118,7 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c } else { /* Copy the small buffer to the huge buffer */ sb = (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 * rsqe) #endif /* NS_USE_DESTRUCTORS */ __net_timestamp(hb); vcc->push(vcc, hb); @@ -24564,9 +25127,10 @@ diff -urNp linux-3.0.9/drivers/atm/nicstar.c linux-3.0.9/drivers/atm/nicstar.c } } -diff -urNp linux-3.0.9/drivers/atm/solos-pci.c linux-3.0.9/drivers/atm/solos-pci.c ---- linux-3.0.9/drivers/atm/solos-pci.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/solos-pci.c 2011-11-12 12:47:13.000000000 -0500 +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); @@ -24576,7 +25140,7 @@ diff -urNp linux-3.0.9/drivers/atm/solos-pci.c linux-3.0.9/drivers/atm/solos-pci break; 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]; @@ -24585,7 +25149,7 @@ diff -urNp linux-3.0.9/drivers/atm/solos-pci.c linux-3.0.9/drivers/atm/solos-pci len = buf->len; for (i = 0; i < len; i++){ if(i % 8 == 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 = SKB_CB(oldskb)->vcc; if (vcc) { @@ -24594,9 +25158,10 @@ diff -urNp linux-3.0.9/drivers/atm/solos-pci.c linux-3.0.9/drivers/atm/solos-pci solos_pop(vcc, oldskb); } else dev_kfree_skb_irq(oldskb); -diff -urNp linux-3.0.9/drivers/atm/suni.c linux-3.0.9/drivers/atm/suni.c ---- linux-3.0.9/drivers/atm/suni.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/suni.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/atm/suni.c b/drivers/atm/suni.c +index 41c56ea..83df600 100644 +--- a/drivers/atm/suni.c ++++ b/drivers/atm/suni.c @@ -50,8 +50,8 @@ static DEFINE_SPINLOCK(sunis_lock); @@ -24608,10 +25173,11 @@ diff -urNp linux-3.0.9/drivers/atm/suni.c linux-3.0.9/drivers/atm/suni.c static void suni_hz(unsigned long from_timer) -diff -urNp linux-3.0.9/drivers/atm/uPD98402.c linux-3.0.9/drivers/atm/uPD98402.c ---- linux-3.0.9/drivers/atm/uPD98402.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/uPD98402.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 c45ae05..ed6f0c4 100644 +--- a/drivers/atm/uPD98402.c ++++ b/drivers/atm/uPD98402.c +@@ -42,7 +42,7 @@ static int fetch_stats(struct atm_dev *dev,struct sonet_stats __user *arg,int ze struct sonet_stats tmp; int error = 0; @@ -24620,7 +25186,7 @@ diff -urNp linux-3.0.9/drivers/atm/uPD98402.c linux-3.0.9/drivers/atm/uPD98402.c sonet_copy_stats(&PRIV(dev)->sonet_stats,&tmp); if (arg) error = 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,unsigned int cmd,void __user *arg) #define ADD_LIMITED(s,v) \ @@ -24633,7 +25199,7 @@ diff -urNp linux-3.0.9/drivers/atm/uPD98402.c linux-3.0.9/drivers/atm/uPD98402.c static void stat_event(struct atm_dev *dev) -@@ -194,7 +194,7 @@ static void uPD98402_int(struct atm_dev +@@ -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 */ @@ -24642,7 +25208,7 @@ diff -urNp linux-3.0.9/drivers/atm/uPD98402.c linux-3.0.9/drivers/atm/uPD98402.c &PRIV(dev)->sonet_stats.uncorr_hcs); } if ((reason & uPD98402_INT_RFO) && -@@ -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 */ @@ -24655,10 +25221,11 @@ diff -urNp linux-3.0.9/drivers/atm/uPD98402.c linux-3.0.9/drivers/atm/uPD98402.c return 0; } -diff -urNp linux-3.0.9/drivers/atm/zatm.c linux-3.0.9/drivers/atm/zatm.c ---- linux-3.0.9/drivers/atm/zatm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/atm/zatm.c 2011-11-12 12:47:13.000000000 -0500 -@@ -459,7 +459,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy +diff --git a/drivers/atm/zatm.c b/drivers/atm/zatm.c +index 6249179..b062f45 100644 +--- a/drivers/atm/zatm.c ++++ b/drivers/atm/zatm.c +@@ -459,7 +459,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy[0],dummy[1]); } if (!size) { dev_kfree_skb_irq(skb); @@ -24667,7 +25234,7 @@ diff -urNp linux-3.0.9/drivers/atm/zatm.c linux-3.0.9/drivers/atm/zatm.c continue; } if (!atm_charge(vcc,skb->truesize)) { -@@ -469,7 +469,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy +@@ -469,7 +469,7 @@ printk("dummy: 0x%08lx, 0x%08lx\n",dummy[0],dummy[1]); skb->len = size; ATM_SKB(skb)->vcc = vcc; vcc->push(vcc,skb); @@ -24676,7 +25243,7 @@ diff -urNp linux-3.0.9/drivers/atm/zatm.c linux-3.0.9/drivers/atm/zatm.c } zout(pos & 0xffff,MTA(mbx)); #if 0 /* probably a stupid idea */ -@@ -733,7 +733,7 @@ if (*ZATM_PRV_DSC(skb) != (uPD98401_TXPD +@@ -733,7 +733,7 @@ if (*ZATM_PRV_DSC(skb) != (uPD98401_TXPD_V | uPD98401_TXPD_DP | skb_queue_head(&zatm_vcc->backlog,skb); break; } @@ -24685,9 +25252,10 @@ diff -urNp linux-3.0.9/drivers/atm/zatm.c linux-3.0.9/drivers/atm/zatm.c wake_up(&zatm_vcc->tx_wait); } -diff -urNp linux-3.0.9/drivers/base/devtmpfs.c linux-3.0.9/drivers/base/devtmpfs.c ---- linux-3.0.9/drivers/base/devtmpfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/base/devtmpfs.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/base/devtmpfs.c b/drivers/base/devtmpfs.c +index 82bbb59..f9af954 100644 +--- a/drivers/base/devtmpfs.c ++++ b/drivers/base/devtmpfs.c @@ -357,7 +357,7 @@ int devtmpfs_mount(const char *mntdir) if (!dev_mnt) return 0; @@ -24697,9 +25265,10 @@ diff -urNp linux-3.0.9/drivers/base/devtmpfs.c linux-3.0.9/drivers/base/devtmpfs if (err) printk(KERN_INFO "devtmpfs: error mounting %i\n", err); else -diff -urNp linux-3.0.9/drivers/base/power/wakeup.c linux-3.0.9/drivers/base/power/wakeup.c ---- linux-3.0.9/drivers/base/power/wakeup.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/base/power/wakeup.c 2011-11-12 12:47:13.000000000 -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. @@ -24717,7 +25286,7 @@ diff -urNp linux-3.0.9/drivers/base/power/wakeup.c linux-3.0.9/drivers/base/powe *cnt = (comb >> IN_PROGRESS_BITS); *inpr = 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_source *ws) ws->last_time = ktime_get(); /* Increment the counter of events in progress. */ @@ -24726,7 +25295,7 @@ diff -urNp linux-3.0.9/drivers/base/power/wakeup.c linux-3.0.9/drivers/base/powe } /** -@@ -440,7 +440,7 @@ static void wakeup_source_deactivate(str +@@ -440,7 +440,7 @@ static void wakeup_source_deactivate(struct wakeup_source *ws) * Increment the counter of registered wakeup events and decrement the * couter of wakeup events in progress simultaneously. */ @@ -24735,10 +25304,24 @@ diff -urNp linux-3.0.9/drivers/base/power/wakeup.c linux-3.0.9/drivers/base/powe } /** -diff -urNp linux-3.0.9/drivers/block/cciss.c linux-3.0.9/drivers/block/cciss.c ---- linux-3.0.9/drivers/block/cciss.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/cciss.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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(DAC960_Controller_T + unsigned long flags; + int Channel, TargetID; + ++ pax_track_stack(); ++ + if (!init_dma_loaf(Controller->PCIDevice, &local_dma, + 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_device *bdev, fmode_t mode, int err; u32 cp; @@ -24786,7 +25369,7 @@ diff -urNp linux-3.0.9/drivers/block/cciss.c linux-3.0.9/drivers/block/cciss.c (h->interrupts_enabled == 0)); } -@@ -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; if (unlikely(!(h->transMethod & CFGTBL_Trans_Performant))) @@ -24795,7 +25378,7 @@ diff -urNp linux-3.0.9/drivers/block/cciss.c linux-3.0.9/drivers/block/cciss.c if ((*(h->reply_pool_head) & 1) == (h->reply_pool_wraparound)) { a = *(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_performant_mode(ctlr_info_t *h) trans_support & CFGTBL_Trans_use_short_tags); /* Change the access methods to the performant access methods */ @@ -24804,7 +25387,7 @@ diff -urNp linux-3.0.9/drivers/block/cciss.c linux-3.0.9/drivers/block/cciss.c h->transMethod = CFGTBL_Trans_Performant; 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 = products[prod_index].product_name; @@ -24852,7 +25435,7 @@ diff -urNp linux-3.0.9/drivers/block/cciss.c linux-3.0.9/drivers/block/cciss.c /* Get the firmware version */ inq_buff = 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 != IO_OK) dev_warn(&h->pdev->dev, "Error flushing cache\n"); @@ -24861,9 +25444,10 @@ diff -urNp linux-3.0.9/drivers/block/cciss.c linux-3.0.9/drivers/block/cciss.c free_irq(h->intr[PERF_MODE_INT], h); } -diff -urNp linux-3.0.9/drivers/block/cciss.h linux-3.0.9/drivers/block/cciss.h ---- linux-3.0.9/drivers/block/cciss.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/cciss.h 2011-11-12 12:47:13.000000000 -0500 +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]; @@ -24873,10 +25457,11 @@ diff -urNp linux-3.0.9/drivers/block/cciss.h linux-3.0.9/drivers/block/cciss.h /* queue and queue Info */ struct list_head reqQ; -diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/drivers/block/cpqarray.c ---- linux-3.0.9/drivers/block/cpqarray.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/cpqarray.c 2011-11-12 12:47:13.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; } @@ -24885,7 +25470,7 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/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); /* Enable IRQ now that spinlock and rate limit timer are set up */ @@ -24903,7 +25488,7 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/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 = intr; sprintf(hba[ctlr]->devname, "ida%d", nr_ctlr); hba[ctlr]->product_name = products[j].product_name; @@ -24912,7 +25497,7 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/drivers/block/cpqarr hba[ctlr]->ctlr = ctlr; hba[ctlr]->board_id = board_id; hba[ctlr]->pci_dev = 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; @@ -24939,7 +25524,7 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/drivers/block/cpqarr /* Get onto the completion Q */ addQ(&h->cmpQ, c); -@@ -1050,7 +1052,7 @@ static irqreturn_t do_ida_intr(int irq, +@@ -1050,7 +1052,7 @@ static irqreturn_t do_ida_intr(int irq, void *dev_id) unsigned long flags; __u32 a,a1; @@ -24948,7 +25533,7 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/drivers/block/cpqarr /* Is this interrupt for us? */ if (istat == 0) return IRQ_NONE; -@@ -1061,7 +1063,7 @@ static irqreturn_t do_ida_intr(int irq, +@@ -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) { @@ -24980,7 +25565,7 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/drivers/block/cpqarr complete = pollcomplete(ctlr); pci_unmap_single(info_p->pci_dev, (dma_addr_t) c->req.sg[0].addr, -@@ -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. */ @@ -25001,9 +25586,10 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.c linux-3.0.9/drivers/block/cpqarr if (done == 0) { udelay(10); /* a short fixed delay */ } else -diff -urNp linux-3.0.9/drivers/block/cpqarray.h linux-3.0.9/drivers/block/cpqarray.h ---- linux-3.0.9/drivers/block/cpqarray.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/cpqarray.h 2011-11-12 12:47:13.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; @@ -25013,21 +25599,10 @@ diff -urNp linux-3.0.9/drivers/block/cpqarray.h linux-3.0.9/drivers/block/cpqarr cmdlist_t *reqQ; cmdlist_t *cmpQ; -diff -urNp linux-3.0.9/drivers/block/DAC960.c linux-3.0.9/drivers/block/DAC960.c ---- linux-3.0.9/drivers/block/DAC960.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/DAC960.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1980,6 +1980,8 @@ static bool DAC960_V1_ReadDeviceConfigur - unsigned long flags; - int Channel, TargetID; - -+ pax_track_stack(); -+ - if (!init_dma_loaf(Controller->PCIDevice, &local_dma, - DAC960_V1_MaxChannels*(sizeof(DAC960_V1_DCDB_T) + - sizeof(DAC960_SCSI_Inquiry_T) + -diff -urNp linux-3.0.9/drivers/block/drbd/drbd_int.h linux-3.0.9/drivers/block/drbd/drbd_int.h ---- linux-3.0.9/drivers/block/drbd/drbd_int.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/drbd/drbd_int.h 2011-11-12 12:47:13.000000000 -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; @@ -25046,7 +25621,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_int.h linux-3.0.9/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, static inline void drbd_tcp_cork(struct socket *sock) { @@ -25085,10 +25660,11 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_int.h linux-3.0.9/drivers/block/d } void drbd_bump_write_ordering(struct drbd_conf *mdev, enum write_ordering_e wo); -diff -urNp linux-3.0.9/drivers/block/drbd/drbd_main.c linux-3.0.9/drivers/block/drbd/drbd_main.c ---- linux-3.0.9/drivers/block/drbd/drbd_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/drbd/drbd_main.c 2011-11-12 12:47:13.000000000 -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_main.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 = sector; p.block_id = block_id; p.blksize = blksize; @@ -25097,7 +25673,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_main.c linux-3.0.9/drivers/block/ 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, struct drbd_request *req) p.sector = cpu_to_be64(req->sector); p.block_id = (unsigned long)req; p.seq_num = cpu_to_be32(req->seq_num = @@ -25106,7 +25682,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_main.c linux-3.0.9/drivers/block/ dp_flags = bio_flags_to_wire(mdev, req->master_bio->bi_rw); -@@ -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); @@ -25115,7 +25691,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_main.c linux-3.0.9/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 +@@ -3063,8 +3063,8 @@ void drbd_mdev_cleanup(struct drbd_conf *mdev) mdev->receiver.t_state); /* no need to lock it, I'm the only thread alive */ @@ -25126,10 +25702,11 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_main.c linux-3.0.9/drivers/block/ mdev->al_writ_cnt = mdev->bm_writ_cnt = mdev->read_cnt = -diff -urNp linux-3.0.9/drivers/block/drbd/drbd_nl.c linux-3.0.9/drivers/block/drbd/drbd_nl.c ---- linux-3.0.9/drivers/block/drbd/drbd_nl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/drbd/drbd_nl.c 2011-11-12 12:47:13.000000000 -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 515bcd9..7ff5ae0 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); } @@ -25138,7 +25715,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_nl.c linux-3.0.9/drivers/block/dr 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, union drbd_state state) cn_reply->id.idx = CN_IDX_DRBD; cn_reply->id.val = CN_VAL_DRBD; @@ -25147,7 +25724,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_nl.c linux-3.0.9/drivers/block/dr cn_reply->ack = 0; /* not used here. */ cn_reply->len = 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 = CN_IDX_DRBD; cn_reply->id.val = CN_VAL_DRBD; @@ -25156,7 +25733,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_nl.c linux-3.0.9/drivers/block/dr cn_reply->ack = 0; /* not used here. */ cn_reply->len = 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 = CN_IDX_DRBD; cn_reply->id.val = CN_VAL_DRBD; @@ -25165,7 +25742,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_nl.c linux-3.0.9/drivers/block/dr cn_reply->ack = 0; // not used here. cn_reply->len = 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 *mdev) cn_reply->id.idx = CN_IDX_DRBD; cn_reply->id.val = CN_VAL_DRBD; @@ -25174,9 +25751,10 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_nl.c linux-3.0.9/drivers/block/dr cn_reply->ack = 0; /* not used here. */ cn_reply->len = sizeof(struct drbd_nl_cfg_reply) + (int)((char *)tl - (char *)reply->tag_list); -diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/block/drbd/drbd_receiver.c ---- linux-3.0.9/drivers/block/drbd/drbd_receiver.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/drbd/drbd_receiver.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/block/drbd/drbd_receiver.c b/drivers/block/drbd/drbd_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 = mdev->net_conf->timeout*HZ/10; sock->sk->sk_rcvtimeo = MAX_SCHEDULE_TIMEOUT; @@ -25186,7 +25764,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl mdev->peer_seq = 0; 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(struct drbd_conf *mdev, do { next_epoch = NULL; @@ -25195,7 +25773,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl 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(struct drbd_conf *mdev, rv = FE_DESTROYED; } else { epoch->flags = 0; @@ -25204,7 +25782,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl /* atomic_set(&epoch->active, 0); is already zero */ if (rv == FE_STILL_LIVE) rv = FE_RECYCLED; -@@ -1191,14 +1191,14 @@ static int receive_Barrier(struct drbd_c +@@ -1191,14 +1191,14 @@ static int receive_Barrier(struct drbd_conf *mdev, enum drbd_packets cmd, unsign drbd_wait_ee_list_empty(mdev, &mdev->active_ee); drbd_flush(mdev); @@ -25221,7 +25799,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl D_ASSERT(atomic_read(&epoch->active) == 0); D_ASSERT(epoch->flags == 0); -@@ -1210,11 +1210,11 @@ static int receive_Barrier(struct drbd_c +@@ -1210,11 +1210,11 @@ static int receive_Barrier(struct drbd_conf *mdev, enum drbd_packets cmd, unsign } epoch->flags = 0; @@ -25235,7 +25813,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl list_add(&epoch->list, &mdev->current_epoch->list); mdev->current_epoch = 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, enum drbd_packets cmd, unsigned spin_unlock(&mdev->peer_seq_lock); drbd_send_ack_dp(mdev, P_NEG_ACK, p, data_size); @@ -25244,7 +25822,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl return drbd_drain_block(mdev, data_size); } -@@ -1689,7 +1689,7 @@ static int receive_Data(struct drbd_conf +@@ -1689,7 +1689,7 @@ static int receive_Data(struct drbd_conf *mdev, enum drbd_packets cmd, unsigned spin_lock(&mdev->epoch_lock); e->epoch = mdev->current_epoch; @@ -25253,7 +25831,7 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl atomic_inc(&e->epoch->active); spin_unlock(&mdev->epoch_lock); -@@ -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)); /* ok, no more ee's on the fly, it is safe to reset the epoch_size */ @@ -25262,10 +25840,11 @@ diff -urNp linux-3.0.9/drivers/block/drbd/drbd_receiver.c linux-3.0.9/drivers/bl D_ASSERT(list_empty(&mdev->current_epoch->list)); } -diff -urNp linux-3.0.9/drivers/block/loop.c linux-3.0.9/drivers/block/loop.c ---- linux-3.0.9/drivers/block/loop.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/loop.c 2011-11-12 12:47:13.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 2ebacf0..9d79297 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 = get_fs(); set_fs(get_ds()); @@ -25274,10 +25853,11 @@ diff -urNp linux-3.0.9/drivers/block/loop.c linux-3.0.9/drivers/block/loop.c set_fs(old_fs); if (likely(bw == len)) return 0; -diff -urNp linux-3.0.9/drivers/block/nbd.c linux-3.0.9/drivers/block/nbd.c ---- linux-3.0.9/drivers/block/nbd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/block/nbd.c 2011-11-12 12:47:13.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; @@ -25286,7 +25866,7 @@ diff -urNp linux-3.0.9/drivers/block/nbd.c linux-3.0.9/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) { @@ -25295,10 +25875,33 @@ diff -urNp linux-3.0.9/drivers/block/nbd.c linux-3.0.9/drivers/block/nbd.c switch (cmd) { case NBD_DISCONNECT: { struct request sreq; -diff -urNp linux-3.0.9/drivers/char/agp/frontend.c linux-3.0.9/drivers/char/agp/frontend.c ---- linux-3.0.9/drivers/char/agp/frontend.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/agp/frontend.c 2011-11-12 12:47:13.000000000 -0500 -@@ -817,7 +817,7 @@ static int agpioc_reserve_wrap(struct ag +diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig +index 49502bc..7b818aa 100644 +--- a/drivers/char/Kconfig ++++ b/drivers/char/Kconfig +@@ -8,7 +8,8 @@ source "drivers/tty/Kconfig" + + 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 + + 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_private *priv, void __user *arg) if (copy_from_user(&reserve, arg, sizeof(struct agp_region))) return -EFAULT; @@ -25307,9 +25910,10 @@ diff -urNp linux-3.0.9/drivers/char/agp/frontend.c linux-3.0.9/drivers/char/agp/ return -EFAULT; client = agp_find_client_by_pid(reserve.pid); -diff -urNp linux-3.0.9/drivers/char/briq_panel.c linux-3.0.9/drivers/char/briq_panel.c ---- linux-3.0.9/drivers/char/briq_panel.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/briq_panel.c 2011-11-12 12:47:13.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 <linux/types.h> #include <linux/errno.h> @@ -25326,7 +25930,7 @@ diff -urNp linux-3.0.9/drivers/char/briq_panel.c linux-3.0.9/drivers/char/briq_p 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; @@ -25343,7 +25947,7 @@ diff -urNp linux-3.0.9/drivers/char/briq_panel.c linux-3.0.9/drivers/char/briq_p if (esc) { set_led(c); esc = 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, const char __user *buf, size_ buf++; } update_vfd(); @@ -25351,10 +25955,11 @@ diff -urNp linux-3.0.9/drivers/char/briq_panel.c linux-3.0.9/drivers/char/briq_p return len; } -diff -urNp linux-3.0.9/drivers/char/genrtc.c linux-3.0.9/drivers/char/genrtc.c ---- linux-3.0.9/drivers/char/genrtc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/genrtc.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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) { case RTC_PLL_GET: @@ -25362,10 +25967,11 @@ diff -urNp linux-3.0.9/drivers/char/genrtc.c linux-3.0.9/drivers/char/genrtc.c if (get_rtc_pll(&pll)) return -EINVAL; else -diff -urNp linux-3.0.9/drivers/char/hpet.c linux-3.0.9/drivers/char/hpet.c ---- linux-3.0.9/drivers/char/hpet.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/hpet.c 2011-11-12 12:47:13.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 34d6a1c..7b38c5b 100644 +--- a/drivers/char/hpet.c ++++ b/drivers/char/hpet.c +@@ -572,7 +572,7 @@ static inline unsigned long hpet_time_div(struct hpets *hpets, } static int @@ -25374,9 +25980,10 @@ diff -urNp linux-3.0.9/drivers/char/hpet.c linux-3.0.9/drivers/char/hpet.c struct hpet_info *info) { struct hpet_timer __iomem *timer; -diff -urNp linux-3.0.9/drivers/char/ipmi/ipmi_msghandler.c linux-3.0.9/drivers/char/ipmi/ipmi_msghandler.c ---- linux-3.0.9/drivers/char/ipmi/ipmi_msghandler.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/ipmi/ipmi_msghandler.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/char/ipmi/ipmi_msghandler.c b/drivers/char/ipmi/ipmi_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]; @@ -25398,7 +26005,7 @@ diff -urNp linux-3.0.9/drivers/char/ipmi/ipmi_msghandler.c linux-3.0.9/drivers/c 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 *handlers, INIT_LIST_HEAD(&intf->cmd_rcvrs); init_waitqueue_head(&intf->waitq); for (i = 0; i < IPMI_NUM_STATS; i++) @@ -25416,9 +26023,10 @@ diff -urNp linux-3.0.9/drivers/char/ipmi/ipmi_msghandler.c linux-3.0.9/drivers/c si = (struct ipmi_system_interface_addr *) &addr; si->addr_type = IPMI_SYSTEM_INTERFACE_ADDR_TYPE; si->channel = IPMI_BMC_CHANNEL; -diff -urNp linux-3.0.9/drivers/char/ipmi/ipmi_si_intf.c linux-3.0.9/drivers/char/ipmi/ipmi_si_intf.c ---- linux-3.0.9/drivers/char/ipmi/ipmi_si_intf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/ipmi/ipmi_si_intf.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_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; @@ -25440,7 +26048,7 @@ diff -urNp linux-3.0.9/drivers/char/ipmi/ipmi_si_intf.c linux-3.0.9/drivers/char #define SI_MAX_PARMS 4 -@@ -3230,7 +3230,7 @@ static int try_smi_init(struct smi_info +@@ -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 = 0; for (i = 0; i < SI_NUM_STATS; i++) @@ -25449,31 +26057,11 @@ diff -urNp linux-3.0.9/drivers/char/ipmi/ipmi_si_intf.c linux-3.0.9/drivers/char new_smi->interrupt_disabled = 1; atomic_set(&new_smi->stop_operation, 0); -diff -urNp linux-3.0.9/drivers/char/Kconfig linux-3.0.9/drivers/char/Kconfig ---- linux-3.0.9/drivers/char/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/Kconfig 2011-11-12 12:47:13.000000000 -0500 -@@ -8,7 +8,8 @@ source "drivers/tty/Kconfig" - - 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 - - source "drivers/s390/char/Kconfig" -diff -urNp linux-3.0.9/drivers/char/mbcs.c linux-3.0.9/drivers/char/mbcs.c ---- linux-3.0.9/drivers/char/mbcs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/mbcs.c 2011-11-12 12:47:13.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; } @@ -25482,9 +26070,10 @@ diff -urNp linux-3.0.9/drivers/char/mbcs.c linux-3.0.9/drivers/char/mbcs.c { .part_num = MBCS_PART_NUM, .mfg_num = MBCS_MFG_NUM, -diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/drivers/char/mem.c ---- linux-3.0.9/drivers/char/mem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/mem.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/char/mem.c b/drivers/char/mem.c +index 8fc04b4..f1a9ee2 100644 +--- a/drivers/char/mem.c ++++ b/drivers/char/mem.c @@ -18,6 +18,7 @@ #include <linux/raw.h> #include <linux/tty.h> @@ -25504,7 +26093,7 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/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) while (cursor < to) { if (!devmem_is_allowed(pfn)) { @@ -25518,7 +26107,7 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/drivers/char/mem.c return 0; } cursor += 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; } @@ -25530,7 +26119,7 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/drivers/char/mem.c #else static inline int range_is_allowed(unsigned long pfn, unsigned long size) { -@@ -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 __user *buf, while (count > 0) { unsigned long remaining; @@ -25538,7 +26127,7 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/drivers/char/mem.c sz = size_inside_page(p, count); -@@ -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 __user *buf, if (!ptr) return -EFAULT; @@ -25563,7 +26152,7 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/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 __user *buf, size_t count, loff_t *ppos) { unsigned long p = *ppos; @@ -25574,7 +26163,7 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/drivers/char/mem.c read = 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 __user *buf, } #endif while (low_count > 0) { @@ -25583,7 +26172,7 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/drivers/char/mem.c sz = size_inside_page(p, low_count); /* -@@ -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 = xlate_dev_kmem_ptr((char *)p); @@ -25617,10 +26206,11 @@ diff -urNp linux-3.0.9/drivers/char/mem.c linux-3.0.9/drivers/char/mem.c }; static int memory_open(struct inode *inode, struct file *filp) -diff -urNp linux-3.0.9/drivers/char/nvram.c linux-3.0.9/drivers/char/nvram.c ---- linux-3.0.9/drivers/char/nvram.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/nvram.c 2011-11-12 12:47:13.000000000 -0500 -@@ -246,7 +246,7 @@ static ssize_t nvram_read(struct file *f +diff --git a/drivers/char/nvram.c b/drivers/char/nvram.c +index 166f1e7..c579d46 100644 +--- a/drivers/char/nvram.c ++++ b/drivers/char/nvram.c +@@ -246,7 +246,7 @@ static ssize_t nvram_read(struct file *file, char __user *buf, spin_unlock_irq(&rtc_lock); @@ -25629,9 +26219,10 @@ diff -urNp linux-3.0.9/drivers/char/nvram.c linux-3.0.9/drivers/char/nvram.c return -EFAULT; *ppos = i; -diff -urNp linux-3.0.9/drivers/char/random.c linux-3.0.9/drivers/char/random.c ---- linux-3.0.9/drivers/char/random.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/random.c 2011-11-12 12:47:13.000000000 -0500 +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 @@ -25664,7 +26255,7 @@ diff -urNp linux-3.0.9/drivers/char/random.c linux-3.0.9/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_store *r, void __user *buf, extract_buf(r, tmp); i = min_t(int, nbytes, EXTRACT_SIZE); @@ -25682,9 +26273,10 @@ diff -urNp linux-3.0.9/drivers/char/random.c linux-3.0.9/drivers/char/random.c static int max_write_thresh = INPUT_POOL_WORDS * 32; static char sysctl_bootid[16]; -diff -urNp linux-3.0.9/drivers/char/sonypi.c linux-3.0.9/drivers/char/sonypi.c ---- linux-3.0.9/drivers/char/sonypi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/sonypi.c 2011-11-12 12:47:13.000000000 -0500 +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 <asm/uaccess.h> #include <asm/io.h> @@ -25702,7 +26294,7 @@ diff -urNp linux-3.0.9/drivers/char/sonypi.c linux-3.0.9/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 *filp, int on) static int sonypi_misc_release(struct inode *inode, struct file *file) { mutex_lock(&sonypi_device.lock); @@ -25711,7 +26303,7 @@ diff -urNp linux-3.0.9/drivers/char/sonypi.c linux-3.0.9/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, struct file *file) { mutex_lock(&sonypi_device.lock); /* Flush input queue on first open */ @@ -25723,10 +26315,33 @@ diff -urNp linux-3.0.9/drivers/char/sonypi.c linux-3.0.9/drivers/char/sonypi.c mutex_unlock(&sonypi_device.lock); return 0; -diff -urNp linux-3.0.9/drivers/char/tpm/tpm_bios.c linux-3.0.9/drivers/char/tpm/tpm_bios.c ---- linux-3.0.9/drivers/char/tpm/tpm_bios.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/tpm/tpm_bios.c 2011-11-12 12:47:13.000000000 -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 b85ee76..4d81778 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, const char *buf, + chip->vendor.req_complete_val) + goto out_recv; + +- if ((status == chip->vendor.req_canceled)) { ++ if (status == chip->vendor.req_canceled) { + dev_err(chip->dev, "Operation Canceled\n"); + rc = -ECANCELED; + goto out; +@@ -847,6 +847,8 @@ ssize_t tpm_show_pubek(struct device *dev, struct device_attribute *attr, + + struct tpm_chip *chip = dev_get_drvdata(dev); + ++ pax_track_stack(); ++ + tpm_cmd.header.in = tpm_readpubek_header; + err = 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 = addr; if ((event->event_type == 0 && event->event_size == 0) || @@ -25735,7 +26350,7 @@ diff -urNp linux-3.0.9/drivers/char/tpm/tpm_bios.c linux-3.0.9/drivers/char/tpm/ return NULL; return addr; -@@ -198,7 +198,7 @@ static void *tpm_bios_measurements_next( +@@ -198,7 +198,7 @@ static void *tpm_bios_measurements_next(struct seq_file *m, void *v, return NULL; if ((event->event_type == 0 && event->event_size == 0) || @@ -25744,7 +26359,7 @@ diff -urNp linux-3.0.9/drivers/char/tpm/tpm_bios.c linux-3.0.9/drivers/char/tpm/ return NULL; (*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; for (i = 0; i < sizeof(struct tcpa_event) + event->event_size; i++) @@ -25754,7 +26369,7 @@ diff -urNp linux-3.0.9/drivers/char/tpm/tpm_bios.c linux-3.0.9/drivers/char/tpm/ return 0; } -@@ -410,8 +411,13 @@ static int read_log(struct tpm_bios_log +@@ -410,8 +411,13 @@ static int read_log(struct tpm_bios_log *log) log->bios_event_log_end = log->bios_event_log + len; virt = acpi_os_map_memory(start, len); @@ -25769,31 +26384,11 @@ diff -urNp linux-3.0.9/drivers/char/tpm/tpm_bios.c linux-3.0.9/drivers/char/tpm/ acpi_os_unmap_memory(virt, len); return 0; -diff -urNp linux-3.0.9/drivers/char/tpm/tpm.c linux-3.0.9/drivers/char/tpm/tpm.c ---- linux-3.0.9/drivers/char/tpm/tpm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/tpm/tpm.c 2011-11-12 12:47:13.000000000 -0500 -@@ -414,7 +414,7 @@ static ssize_t tpm_transmit(struct tpm_c - chip->vendor.req_complete_val) - goto out_recv; - -- if ((status == chip->vendor.req_canceled)) { -+ if (status == chip->vendor.req_canceled) { - dev_err(chip->dev, "Operation Canceled\n"); - rc = -ECANCELED; - goto out; -@@ -847,6 +847,8 @@ ssize_t tpm_show_pubek(struct device *de - - struct tpm_chip *chip = dev_get_drvdata(dev); - -+ pax_track_stack(); -+ - tpm_cmd.header.in = tpm_readpubek_header; - err = transmit_cmd(chip, &tpm_cmd, READ_PUBEK_RESULT_SIZE, - "attempting to read the PUBEK"); -diff -urNp linux-3.0.9/drivers/char/virtio_console.c linux-3.0.9/drivers/char/virtio_console.c ---- linux-3.0.9/drivers/char/virtio_console.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/char/virtio_console.c 2011-11-12 12:47:13.000000000 -0500 -@@ -555,7 +555,7 @@ static ssize_t fill_readbuf(struct port +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; @@ -25802,7 +26397,7 @@ diff -urNp linux-3.0.9/drivers/char/virtio_console.c linux-3.0.9/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, char __user *ubuf, if (!port_has_data(port) && !port->host_connected) return 0; @@ -25811,10 +26406,11 @@ diff -urNp linux-3.0.9/drivers/char/virtio_console.c linux-3.0.9/drivers/char/vi } static ssize_t port_fops_write(struct file *filp, const char __user *ubuf, -diff -urNp linux-3.0.9/drivers/crypto/hifn_795x.c linux-3.0.9/drivers/crypto/hifn_795x.c ---- linux-3.0.9/drivers/crypto/hifn_795x.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/crypto/hifn_795x.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1655,6 +1655,8 @@ static int hifn_test(struct hifn_device +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; @@ -25823,10 +26419,11 @@ diff -urNp linux-3.0.9/drivers/crypto/hifn_795x.c linux-3.0.9/drivers/crypto/hif memset(src, 0, sizeof(src)); memset(ctx.key, 0, sizeof(ctx.key)); -diff -urNp linux-3.0.9/drivers/crypto/padlock-aes.c linux-3.0.9/drivers/crypto/padlock-aes.c ---- linux-3.0.9/drivers/crypto/padlock-aes.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/crypto/padlock-aes.c 2011-11-12 12:47:13.000000000 -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; @@ -25835,9 +26432,10 @@ diff -urNp linux-3.0.9/drivers/crypto/padlock-aes.c linux-3.0.9/drivers/crypto/p if (key_len % 8) { *flags |= CRYPTO_TFM_RES_BAD_KEY_LEN; return -EINVAL; -diff -urNp linux-3.0.9/drivers/dma/ioat/dma_v3.c linux-3.0.9/drivers/dma/ioat/dma_v3.c ---- linux-3.0.9/drivers/dma/ioat/dma_v3.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/dma/ioat/dma_v3.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/dma/ioat/dma_v3.c b/drivers/dma/ioat/dma_v3.c +index d845dc4..fec8664 100644 +--- a/drivers/dma/ioat/dma_v3.c ++++ b/drivers/dma/ioat/dma_v3.c @@ -73,10 +73,10 @@ /* provide a lookup table for setting the source address in the base or * extended descriptor of an xor or pq descriptor @@ -25853,10 +26451,11 @@ diff -urNp linux-3.0.9/drivers/dma/ioat/dma_v3.c linux-3.0.9/drivers/dma/ioat/dm static dma_addr_t xor_get_src(struct ioat_raw_descriptor *descs[2], int idx) { -diff -urNp linux-3.0.9/drivers/edac/amd64_edac.c linux-3.0.9/drivers/edac/amd64_edac.c ---- linux-3.0.9/drivers/edac/amd64_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/amd64_edac.c 2011-11-12 12:47:13.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(struct pci_dev *pdev) * PCI core identifies what devices are on a system during boot, and then * inquiry this table to see if this driver is for a given device found. */ @@ -25865,10 +26464,11 @@ diff -urNp linux-3.0.9/drivers/edac/amd64_edac.c linux-3.0.9/drivers/edac/amd64_ { .vendor = PCI_VENDOR_ID_AMD, .device = PCI_DEVICE_ID_AMD_K8_NB_MEMCTL, -diff -urNp linux-3.0.9/drivers/edac/amd76x_edac.c linux-3.0.9/drivers/edac/amd76x_edac.c ---- linux-3.0.9/drivers/edac/amd76x_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/amd76x_edac.c 2011-11-12 12:47:13.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_dev *pdev) edac_mc_free(mci); } @@ -25877,10 +26477,11 @@ diff -urNp linux-3.0.9/drivers/edac/amd76x_edac.c linux-3.0.9/drivers/edac/amd76 { PCI_VEND_DEV(AMD, FE_GATE_700C), PCI_ANY_ID, PCI_ANY_ID, 0, 0, AMD762}, -diff -urNp linux-3.0.9/drivers/edac/e752x_edac.c linux-3.0.9/drivers/edac/e752x_edac.c ---- linux-3.0.9/drivers/edac/e752x_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/e752x_edac.c 2011-11-12 12:47:13.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); } @@ -25889,10 +26490,11 @@ diff -urNp linux-3.0.9/drivers/edac/e752x_edac.c linux-3.0.9/drivers/edac/e752x_ { PCI_VEND_DEV(INTEL, 7520_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, E7520}, -diff -urNp linux-3.0.9/drivers/edac/e7xxx_edac.c linux-3.0.9/drivers/edac/e7xxx_edac.c ---- linux-3.0.9/drivers/edac/e7xxx_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/e7xxx_edac.c 2011-11-12 12:47:13.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_dev *pdev) edac_mc_free(mci); } @@ -25901,10 +26503,11 @@ diff -urNp linux-3.0.9/drivers/edac/e7xxx_edac.c linux-3.0.9/drivers/edac/e7xxx_ { PCI_VEND_DEV(INTEL, 7205_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, E7205}, -diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/edac_pci_sysfs.c ---- linux-3.0.9/drivers/edac/edac_pci_sysfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/edac_pci_sysfs.c 2011-11-12 12:47:13.000000000 -0500 -@@ -26,8 +26,8 @@ static int edac_pci_log_pe = 1; /* log +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 = 1; /* log PCI parity errors */ static int edac_pci_log_npe = 1; /* log PCI non-parity error errors */ static int edac_pci_poll_msec = 1000; /* one second workq period */ @@ -25915,7 +26518,7 @@ diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/ed static struct kobject *edac_pci_top_main_kobj; static atomic_t edac_pci_sysfs_refcount = 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)); @@ -25924,7 +26527,7 @@ diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/ed } 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)); @@ -25933,7 +26536,7 @@ diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/ed } 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)); @@ -25942,7 +26545,7 @@ diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/ed } } -@@ -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)); @@ -25951,7 +26554,7 @@ diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/ed } 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)); @@ -25960,7 +26563,7 @@ diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/ed } 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)); @@ -25987,10 +26590,11 @@ diff -urNp linux-3.0.9/drivers/edac/edac_pci_sysfs.c linux-3.0.9/drivers/edac/ed panic("EDAC: PCI Parity Error"); } } -diff -urNp linux-3.0.9/drivers/edac/i3000_edac.c linux-3.0.9/drivers/edac/i3000_edac.c ---- linux-3.0.9/drivers/edac/i3000_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i3000_edac.c 2011-11-12 12:47:13.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_dev *pdev) edac_mc_free(mci); } @@ -25999,10 +26603,11 @@ diff -urNp linux-3.0.9/drivers/edac/i3000_edac.c linux-3.0.9/drivers/edac/i3000_ { PCI_VEND_DEV(INTEL, 3000_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I3000}, -diff -urNp linux-3.0.9/drivers/edac/i3200_edac.c linux-3.0.9/drivers/edac/i3200_edac.c ---- linux-3.0.9/drivers/edac/i3200_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i3200_edac.c 2011-11-12 12:47:13.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_dev *pdev) edac_mc_free(mci); } @@ -26011,10 +26616,11 @@ diff -urNp linux-3.0.9/drivers/edac/i3200_edac.c linux-3.0.9/drivers/edac/i3200_ { PCI_VEND_DEV(INTEL, 3200_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I3200}, -diff -urNp linux-3.0.9/drivers/edac/i5000_edac.c linux-3.0.9/drivers/edac/i5000_edac.c ---- linux-3.0.9/drivers/edac/i5000_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i5000_edac.c 2011-11-12 12:47:13.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. */ @@ -26023,10 +26629,11 @@ diff -urNp linux-3.0.9/drivers/edac/i5000_edac.c linux-3.0.9/drivers/edac/i5000_ {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_I5000_DEV16), .driver_data = I5000P}, -diff -urNp linux-3.0.9/drivers/edac/i5100_edac.c linux-3.0.9/drivers/edac/i5100_edac.c ---- linux-3.0.9/drivers/edac/i5100_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i5100_edac.c 2011-11-12 12:47:13.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); } @@ -26035,10 +26642,11 @@ diff -urNp linux-3.0.9/drivers/edac/i5100_edac.c linux-3.0.9/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.0.9/drivers/edac/i5400_edac.c linux-3.0.9/drivers/edac/i5400_edac.c ---- linux-3.0.9/drivers/edac/i5400_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i5400_edac.c 2011-11-12 12:47:13.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. */ @@ -26047,10 +26655,11 @@ diff -urNp linux-3.0.9/drivers/edac/i5400_edac.c linux-3.0.9/drivers/edac/i5400_ {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_5400_ERR)}, {0,} /* 0 terminated list. */ }; -diff -urNp linux-3.0.9/drivers/edac/i7300_edac.c linux-3.0.9/drivers/edac/i7300_edac.c ---- linux-3.0.9/drivers/edac/i7300_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i7300_edac.c 2011-11-12 12:47:13.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 */ @@ -26059,10 +26668,11 @@ diff -urNp linux-3.0.9/drivers/edac/i7300_edac.c linux-3.0.9/drivers/edac/i7300_ {PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_I7300_MCH_ERR)}, {0,} /* 0 terminated list. */ }; -diff -urNp linux-3.0.9/drivers/edac/i7core_edac.c linux-3.0.9/drivers/edac/i7core_edac.c ---- linux-3.0.9/drivers/edac/i7core_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i7core_edac.c 2011-11-12 12:47:13.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[] = { /* * pci_device_id table for which devices we are looking for */ @@ -26071,10 +26681,11 @@ diff -urNp linux-3.0.9/drivers/edac/i7core_edac.c linux-3.0.9/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_LINK0)}, {0,} /* 0 terminated list. */ -diff -urNp linux-3.0.9/drivers/edac/i82443bxgx_edac.c linux-3.0.9/drivers/edac/i82443bxgx_edac.c ---- linux-3.0.9/drivers/edac/i82443bxgx_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i82443bxgx_edac.c 2011-11-12 12:47:13.000000000 -0500 -@@ -380,7 +380,7 @@ static void __devexit i82443bxgx_edacmc_ +diff --git a/drivers/edac/i82443bxgx_edac.c b/drivers/edac/i82443bxgx_edac.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(struct pci_dev *pdev) EXPORT_SYMBOL_GPL(i82443bxgx_edacmc_remove_one); @@ -26083,10 +26694,11 @@ diff -urNp linux-3.0.9/drivers/edac/i82443bxgx_edac.c linux-3.0.9/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.0.9/drivers/edac/i82860_edac.c linux-3.0.9/drivers/edac/i82860_edac.c ---- linux-3.0.9/drivers/edac/i82860_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i82860_edac.c 2011-11-12 12:47:13.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_dev *pdev) edac_mc_free(mci); } @@ -26095,10 +26707,11 @@ diff -urNp linux-3.0.9/drivers/edac/i82860_edac.c linux-3.0.9/drivers/edac/i8286 { PCI_VEND_DEV(INTEL, 82860_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82860}, -diff -urNp linux-3.0.9/drivers/edac/i82875p_edac.c linux-3.0.9/drivers/edac/i82875p_edac.c ---- linux-3.0.9/drivers/edac/i82875p_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i82875p_edac.c 2011-11-12 12:47:13.000000000 -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); } @@ -26107,10 +26720,11 @@ diff -urNp linux-3.0.9/drivers/edac/i82875p_edac.c linux-3.0.9/drivers/edac/i828 { PCI_VEND_DEV(INTEL, 82875_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82875P}, -diff -urNp linux-3.0.9/drivers/edac/i82975x_edac.c linux-3.0.9/drivers/edac/i82975x_edac.c ---- linux-3.0.9/drivers/edac/i82975x_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/i82975x_edac.c 2011-11-12 12:47:13.000000000 -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); } @@ -26119,9 +26733,10 @@ diff -urNp linux-3.0.9/drivers/edac/i82975x_edac.c linux-3.0.9/drivers/edac/i829 { PCI_VEND_DEV(INTEL, 82975_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0, I82975X -diff -urNp linux-3.0.9/drivers/edac/mce_amd.h linux-3.0.9/drivers/edac/mce_amd.h ---- linux-3.0.9/drivers/edac/mce_amd.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/mce_amd.h 2011-11-12 12:47:13.000000000 -0500 +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); @@ -26131,10 +26746,11 @@ diff -urNp linux-3.0.9/drivers/edac/mce_amd.h linux-3.0.9/drivers/edac/mce_amd.h void amd_report_gart_errors(bool); void amd_register_ecc_decoder(void (*f)(int, struct mce *, u32)); -diff -urNp linux-3.0.9/drivers/edac/r82600_edac.c linux-3.0.9/drivers/edac/r82600_edac.c ---- linux-3.0.9/drivers/edac/r82600_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/r82600_edac.c 2011-11-12 12:47:13.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_dev *pdev) edac_mc_free(mci); } @@ -26143,10 +26759,11 @@ diff -urNp linux-3.0.9/drivers/edac/r82600_edac.c linux-3.0.9/drivers/edac/r8260 { PCI_DEVICE(PCI_VENDOR_ID_RADISYS, R82600_BRIDGE_ID) }, -diff -urNp linux-3.0.9/drivers/edac/x38_edac.c linux-3.0.9/drivers/edac/x38_edac.c ---- linux-3.0.9/drivers/edac/x38_edac.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/edac/x38_edac.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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); } @@ -26155,9 +26772,10 @@ diff -urNp linux-3.0.9/drivers/edac/x38_edac.c linux-3.0.9/drivers/edac/x38_edac { PCI_VEND_DEV(INTEL, X38_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0, X38}, -diff -urNp linux-3.0.9/drivers/firewire/core-card.c linux-3.0.9/drivers/firewire/core-card.c ---- linux-3.0.9/drivers/firewire/core-card.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/firewire/core-card.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/firewire/core-card.c b/drivers/firewire/core-card.c +index 29d2423..6c48b3a 100644 +--- a/drivers/firewire/core-card.c ++++ b/drivers/firewire/core-card.c @@ -657,7 +657,7 @@ void fw_card_release(struct kref *kref) void fw_core_remove_card(struct fw_card *card) @@ -26167,10 +26785,11 @@ diff -urNp linux-3.0.9/drivers/firewire/core-card.c linux-3.0.9/drivers/firewire card->driver->update_phy_reg(card, 4, PHY_LINK_ACTIVE | PHY_CONTENDER, 0); -diff -urNp linux-3.0.9/drivers/firewire/core-cdev.c linux-3.0.9/drivers/firewire/core-cdev.c ---- linux-3.0.9/drivers/firewire/core-cdev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/firewire/core-cdev.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1313,8 +1313,7 @@ static int init_iso_resource(struct clie +diff --git a/drivers/firewire/core-cdev.c b/drivers/firewire/core-cdev.c +index e6ad3bb..2f89ef8 100644 +--- a/drivers/firewire/core-cdev.c ++++ b/drivers/firewire/core-cdev.c +@@ -1313,8 +1313,7 @@ static int init_iso_resource(struct client *client, int ret; if ((request->channels == 0 && request->bandwidth == 0) || @@ -26180,20 +26799,10 @@ diff -urNp linux-3.0.9/drivers/firewire/core-cdev.c linux-3.0.9/drivers/firewire return -EINVAL; r = kmalloc(sizeof(*r), GFP_KERNEL); -diff -urNp linux-3.0.9/drivers/firewire/core.h linux-3.0.9/drivers/firewire/core.h ---- linux-3.0.9/drivers/firewire/core.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/firewire/core.h 2011-11-12 12:47:13.000000000 -0500 -@@ -101,6 +101,7 @@ struct fw_card_driver { - - int (*stop_iso)(struct fw_iso_context *ctx); - }; -+typedef struct fw_card_driver __no_const fw_card_driver_no_const; - - void fw_card_initialize(struct fw_card *card, - const struct fw_card_driver *driver, struct device *device); -diff -urNp linux-3.0.9/drivers/firewire/core-transaction.c linux-3.0.9/drivers/firewire/core-transaction.c ---- linux-3.0.9/drivers/firewire/core-transaction.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/firewire/core-transaction.c 2011-11-12 12:47:13.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 <linux/timer.h> #include <linux/types.h> @@ -26202,7 +26811,7 @@ diff -urNp linux-3.0.9/drivers/firewire/core-transaction.c linux-3.0.9/drivers/f #include <asm/byteorder.h> -@@ -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 tcode, int destination_id, struct transaction_callback_data d; struct fw_transaction t; @@ -26211,9 +26820,22 @@ diff -urNp linux-3.0.9/drivers/firewire/core-transaction.c linux-3.0.9/drivers/f init_timer_on_stack(&t.split_timeout_timer); init_completion(&d.done); d.payload = payload; -diff -urNp linux-3.0.9/drivers/firmware/dmi_scan.c linux-3.0.9/drivers/firmware/dmi_scan.c ---- linux-3.0.9/drivers/firmware/dmi_scan.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/firmware/dmi_scan.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/firewire/core.h b/drivers/firewire/core.h +index 0fe4e4e..1edf73c 100644 +--- a/drivers/firewire/core.h ++++ b/drivers/firewire/core.h +@@ -101,6 +101,7 @@ struct fw_card_driver { + + int (*stop_iso)(struct fw_iso_context *ctx); + }; ++typedef struct fw_card_driver __no_const fw_card_driver_no_const; + + 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) } } @@ -26226,7 +26848,7 @@ diff -urNp linux-3.0.9/drivers/firmware/dmi_scan.c linux-3.0.9/drivers/firmware/ p = dmi_ioremap(0xF0000, 0x10000); if (p == 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 == NULL) return -1; @@ -26235,9 +26857,10 @@ diff -urNp linux-3.0.9/drivers/firmware/dmi_scan.c linux-3.0.9/drivers/firmware/ iounmap(buf); return 0; -diff -urNp linux-3.0.9/drivers/gpio/vr41xx_giu.c linux-3.0.9/drivers/gpio/vr41xx_giu.c ---- linux-3.0.9/drivers/gpio/vr41xx_giu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpio/vr41xx_giu.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/gpio/vr41xx_giu.c b/drivers/gpio/vr41xx_giu.c +index a365be0..a629755 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); @@ -26247,10 +26870,11 @@ diff -urNp linux-3.0.9/drivers/gpio/vr41xx_giu.c linux-3.0.9/drivers/gpio/vr41xx return -EINVAL; } -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/drm_crtc.c ---- linux-3.0.9/drivers/gpu/drm/drm_crtc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_crtc.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1372,7 +1372,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 82db185..c935ce3 100644 +--- a/drivers/gpu/drm/drm_crtc.c ++++ b/drivers/gpu/drm/drm_crtc.c +@@ -1372,7 +1372,7 @@ int drm_mode_getconnector(struct drm_device *dev, void *data, */ if ((out_resp->count_modes >= mode_count) && mode_count) { copied = 0; @@ -26259,7 +26883,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/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, -@@ -1387,8 +1387,8 @@ int drm_mode_getconnector(struct drm_dev +@@ -1387,8 +1387,8 @@ int drm_mode_getconnector(struct drm_device *dev, void *data, if ((out_resp->count_props >= props_count) && props_count) { copied = 0; @@ -26270,7 +26894,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr for (i = 0; i < DRM_CONNECTOR_MAX_PROPERTY; i++) { if (connector->property_ids[i] != 0) { if (put_user(connector->property_ids[i], -@@ -1410,7 +1410,7 @@ int drm_mode_getconnector(struct drm_dev +@@ -1410,7 +1410,7 @@ int drm_mode_getconnector(struct drm_device *dev, void *data, if ((out_resp->count_encoders >= encoders_count) && encoders_count) { copied = 0; @@ -26279,7 +26903,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr for (i = 0; i < DRM_CONNECTOR_MAX_ENCODER; i++) { if (connector->encoder_ids[i] != 0) { if (put_user(connector->encoder_ids[i], -@@ -1569,7 +1569,7 @@ int drm_mode_setcrtc(struct drm_device * +@@ -1569,7 +1569,7 @@ int drm_mode_setcrtc(struct drm_device *dev, void *data, } for (i = 0; i < crtc_req->count_connectors; i++) { @@ -26288,7 +26912,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr if (get_user(out_id, &set_connectors_ptr[i])) { ret = -EFAULT; goto out; -@@ -1850,7 +1850,7 @@ int drm_mode_dirtyfb_ioctl(struct drm_de +@@ -1850,7 +1850,7 @@ int drm_mode_dirtyfb_ioctl(struct drm_device *dev, fb = obj_to_fb(obj); num_clips = r->num_clips; @@ -26297,7 +26921,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr if (!num_clips != !clips_ptr) { ret = -EINVAL; -@@ -2270,7 +2270,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2270,7 +2270,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *dev, out_resp->flags = property->flags; if ((out_resp->count_values >= value_count) && value_count) { @@ -26306,7 +26930,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr for (i = 0; i < value_count; i++) { if (copy_to_user(values_ptr + i, &property->values[i], sizeof(uint64_t))) { ret = -EFAULT; -@@ -2283,7 +2283,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2283,7 +2283,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *dev, if (property->flags & DRM_MODE_PROP_ENUM) { if ((out_resp->count_enum_blobs >= enum_count) && enum_count) { copied = 0; @@ -26315,7 +26939,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr list_for_each_entry(prop_enum, &property->enum_blob_list, head) { if (copy_to_user(&enum_ptr[copied].value, &prop_enum->value, sizeof(uint64_t))) { -@@ -2306,7 +2306,7 @@ int drm_mode_getproperty_ioctl(struct dr +@@ -2306,7 +2306,7 @@ int drm_mode_getproperty_ioctl(struct drm_device *dev, if ((out_resp->count_enum_blobs >= blob_count) && blob_count) { copied = 0; blob_id_ptr = (uint32_t *)(unsigned long)out_resp->enum_blob_ptr; @@ -26324,7 +26948,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr list_for_each_entry(prop_blob, &property->enum_blob_list, head) { if (put_user(prop_blob->base.id, blob_id_ptr + copied)) { -@@ -2367,7 +2367,7 @@ int drm_mode_getblob_ioctl(struct drm_de +@@ -2367,7 +2367,7 @@ int drm_mode_getblob_ioctl(struct drm_device *dev, struct drm_mode_get_blob *out_resp = data; struct drm_property_blob *blob; int ret = 0; @@ -26333,7 +26957,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr if (!drm_core_check_feature(dev, DRIVER_MODESET)) return -EINVAL; -@@ -2381,7 +2381,7 @@ int drm_mode_getblob_ioctl(struct drm_de +@@ -2381,7 +2381,7 @@ int drm_mode_getblob_ioctl(struct drm_device *dev, blob = obj_to_blob(obj); if (out_resp->length == blob->length) { @@ -26342,10 +26966,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc.c linux-3.0.9/drivers/gpu/drm/dr if (copy_to_user(blob_ptr, blob->data, blob->length)){ ret = -EFAULT; goto done; -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc_helper.c linux-3.0.9/drivers/gpu/drm/drm_crtc_helper.c ---- linux-3.0.9/drivers/gpu/drm/drm_crtc_helper.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_crtc_helper.c 2011-11-12 12:47:13.000000000 -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_crtc_helper.c +index 9236965..f9ea6cd 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 = 1; @@ -26354,7 +26979,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc_helper.c linux-3.0.9/drivers/gpu dev = crtc->dev; -@@ -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 = true; @@ -26363,9 +26988,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_crtc_helper.c linux-3.0.9/drivers/gpu crtc->enabled = drm_helper_crtc_in_use(crtc); if (!crtc->enabled) return true; -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_drv.c linux-3.0.9/drivers/gpu/drm/drm_drv.c ---- linux-3.0.9/drivers/gpu/drm/drm_drv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_drv.c 2011-11-12 12:47:13.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 @@ -26384,10 +27010,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_drv.c linux-3.0.9/drivers/gpu/drm/drm ++file_priv->ioctl_count; DRM_DEBUG("pid=%d, cmd=0x%02x, nr=0x%02x, dev 0x%lx, auth=%d\n", -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_fops.c linux-3.0.9/drivers/gpu/drm/drm_fops.c ---- linux-3.0.9/drivers/gpu/drm/drm_fops.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_fops.c 2011-11-12 12:47:13.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) } for (i = 0; i < ARRAY_SIZE(dev->counts); i++) @@ -26396,7 +27023,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_fops.c linux-3.0.9/drivers/gpu/drm/dr dev->sigdata.lock = NULL; -@@ -134,8 +134,8 @@ int drm_open(struct inode *inode, struct +@@ -134,8 +134,8 @@ int drm_open(struct inode *inode, struct file *filp) retcode = drm_open_helper(inode, filp, dev); if (!retcode) { @@ -26407,7 +27034,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_fops.c linux-3.0.9/drivers/gpu/drm/dr retcode = 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 *filp) mutex_lock(&drm_global_mutex); @@ -26416,7 +27043,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_fops.c linux-3.0.9/drivers/gpu/drm/dr 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 *filp) DRM_DEBUG("pid = %d, device = 0x%lx, open_count = %d\n", task_pid_nr(current), (long)old_encode_dev(file_priv->minor->device), @@ -26425,7 +27052,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_fops.c linux-3.0.9/drivers/gpu/drm/dr /* 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 *filp) * End inline drm_release */ @@ -26436,9 +27063,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_fops.c linux-3.0.9/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.0.9/drivers/gpu/drm/drm_global.c linux-3.0.9/drivers/gpu/drm/drm_global.c ---- linux-3.0.9/drivers/gpu/drm/drm_global.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_global.c 2011-11-12 12:47:13.000000000 -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; @@ -26466,7 +27094,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_global.c linux-3.0.9/drivers/gpu/drm/ } } -@@ -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 *ref) void *object; mutex_lock(&item->mutex); @@ -26475,7 +27103,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_global.c linux-3.0.9/drivers/gpu/drm/ item->object = kzalloc(ref->size, GFP_KERNEL); if (unlikely(item->object == NULL)) { ret = -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 *ref) goto out_err; } @@ -26484,7 +27112,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_global.c linux-3.0.9/drivers/gpu/drm/ ref->object = item->object; object = 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_reference *ref) struct drm_global_item *item = &glob[ref->global_type]; mutex_lock(&item->mutex); @@ -26496,10 +27124,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_global.c linux-3.0.9/drivers/gpu/drm/ ref->release(ref); item->object = NULL; } -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_info.c linux-3.0.9/drivers/gpu/drm/drm_info.c ---- linux-3.0.9/drivers/gpu/drm/drm_info.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_info.c 2011-11-12 12:47:13.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; @@ -26518,7 +27147,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_info.c linux-3.0.9/drivers/gpu/drm/dr const char *type; int i; -@@ -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 = r_list->map; if (!map) continue; @@ -26527,7 +27156,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_info.c linux-3.0.9/drivers/gpu/drm/dr type = "??"; else type = 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' : '-', @@ -26539,10 +27168,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_info.c linux-3.0.9/drivers/gpu/drm/dr #if defined(__i386__) pgprot = pgprot_val(vma->vm_page_prot); -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_ioc32.c linux-3.0.9/drivers/gpu/drm/drm_ioc32.c ---- linux-3.0.9/drivers/gpu/drm/drm_ioc32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_ioc32.c 2011-11-12 12:47:13.000000000 -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, unsigned int cmd, request = compat_alloc_user_space(nbytes); if (!access_ok(VERIFY_WRITE, request, nbytes)) return -EFAULT; @@ -26551,7 +27181,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_ioc32.c linux-3.0.9/drivers/gpu/drm/d 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, unsigned int cmd, request = compat_alloc_user_space(nbytes); if (!access_ok(VERIFY_WRITE, request, nbytes)) return -EFAULT; @@ -26560,10 +27190,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_ioc32.c linux-3.0.9/drivers/gpu/drm/d if (__put_user(count, &request->count) || __put_user(list, &request->list)) -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_ioctl.c linux-3.0.9/drivers/gpu/drm/drm_ioctl.c ---- linux-3.0.9/drivers/gpu/drm/drm_ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_ioctl.c 2011-11-12 12:47:13.000000000 -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 = (file_priv->master->lock.hw_lock ? file_priv->master->lock.hw_lock->lock : 0); else @@ -26572,10 +27203,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_ioctl.c linux-3.0.9/drivers/gpu/drm/d stats->data[i].type = dev->types[i]; } -diff -urNp linux-3.0.9/drivers/gpu/drm/drm_lock.c linux-3.0.9/drivers/gpu/drm/drm_lock.c ---- linux-3.0.9/drivers/gpu/drm/drm_lock.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/drm_lock.c 2011-11-12 12:47:13.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, struct drm_file *file_priv) if (drm_lock_take(&master->lock, lock->context)) { master->lock.file_priv = file_priv; master->lock.lock_time = jiffies; @@ -26584,7 +27216,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_lock.c linux-3.0.9/drivers/gpu/drm/dr break; /* Got lock */ } -@@ -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, struct drm_file *file_priv) return -EINVAL; } @@ -26593,10 +27225,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/drm_lock.c linux-3.0.9/drivers/gpu/drm/dr if (drm_lock_free(&master->lock, lock->context)) { /* FIXME: Should really bail out here. */ -diff -urNp linux-3.0.9/drivers/gpu/drm/i810/i810_dma.c linux-3.0.9/drivers/gpu/drm/i810/i810_dma.c ---- linux-3.0.9/drivers/gpu/drm/i810/i810_dma.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i810/i810_dma.c 2011-11-12 12:47:13.000000000 -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, void *data, dma->buflist[vertex->idx], vertex->discard, vertex->used); @@ -26607,7 +27240,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i810/i810_dma.c linux-3.0.9/drivers/gpu/d sarea_priv->last_enqueue = dev_priv->counter - 1; sarea_priv->last_dispatch = (int)hw_status[5]; -@@ -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, void *data, i810_dma_dispatch_mc(dev, dma->buflist[mc->idx], mc->used, mc->last_render); @@ -26618,9 +27251,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i810/i810_dma.c linux-3.0.9/drivers/gpu/d sarea_priv->last_enqueue = dev_priv->counter - 1; sarea_priv->last_dispatch = (int)hw_status[5]; -diff -urNp linux-3.0.9/drivers/gpu/drm/i810/i810_drv.h linux-3.0.9/drivers/gpu/drm/i810/i810_drv.h ---- linux-3.0.9/drivers/gpu/drm/i810/i810_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i810/i810_drv.h 2011-11-12 12:47:13.000000000 -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; @@ -26632,10 +27266,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i810/i810_drv.h linux-3.0.9/drivers/gpu/d int front_offset; } drm_i810_private_t; -diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_debugfs.c linux-3.0.9/drivers/gpu/drm/i915/i915_debugfs.c ---- linux-3.0.9/drivers/gpu/drm/i915/i915_debugfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i915/i915_debugfs.c 2011-11-12 12:47:13.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 e36efdc..e917798 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, void *data) I915_READ(GTIMR)); } seq_printf(m, "Interrupts received: %d\n", @@ -26644,7 +27279,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_debugfs.c linux-3.0.9/drivers/g for (i = 0; i < I915_NUM_RINGS; i++) { if (IS_GEN6(dev)) { seq_printf(m, "Graphics Interrupt mask (%s): %08x\n", -@@ -1147,7 +1147,7 @@ static int i915_opregion(struct seq_file +@@ -1147,7 +1147,7 @@ static int i915_opregion(struct seq_file *m, void *unused) return ret; if (opregion->header) @@ -26653,10 +27288,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_debugfs.c linux-3.0.9/drivers/g mutex_unlock(&dev->struct_mutex); -diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_dma.c linux-3.0.9/drivers/gpu/drm/i915/i915_dma.c ---- linux-3.0.9/drivers/gpu/drm/i915/i915_dma.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i915/i915_dma.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1169,7 +1169,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 7eef6e1..f8b411e 100644 +--- a/drivers/gpu/drm/i915/i915_dma.c ++++ b/drivers/gpu/drm/i915/i915_dma.c +@@ -1169,7 +1169,7 @@ static bool i915_switcheroo_can_switch(struct pci_dev *pdev) bool can_switch; spin_lock(&dev->count_lock); @@ -26665,9 +27301,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_dma.c linux-3.0.9/drivers/gpu/d spin_unlock(&dev->count_lock); return can_switch; } -diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_drv.h linux-3.0.9/drivers/gpu/drm/i915/i915_drv.h ---- linux-3.0.9/drivers/gpu/drm/i915/i915_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i915/i915_drv.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h +index ce7914c..2e5f051 100644 +--- a/drivers/gpu/drm/i915/i915_drv.h ++++ b/drivers/gpu/drm/i915/i915_drv.h @@ -219,7 +219,7 @@ struct drm_i915_display_funcs { /* render clock increase/decrease */ /* display clock increase/decrease */ @@ -26695,7 +27332,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_drv.h linux-3.0.9/drivers/gpu/d }; #define to_intel_bo(x) container_of(x, struct drm_i915_gem_object, base) -@@ -1247,7 +1247,7 @@ extern int intel_setup_gmbus(struct drm_ +@@ -1247,7 +1247,7 @@ extern int intel_setup_gmbus(struct drm_device *dev); extern void intel_teardown_gmbus(struct drm_device *dev); extern void intel_gmbus_set_speed(struct i2c_adapter *adapter, int speed); extern void intel_gmbus_force_bit(struct i2c_adapter *adapter, bool force_bit); @@ -26704,10 +27341,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_drv.h linux-3.0.9/drivers/gpu/d { return container_of(adapter, struct intel_gmbus, adapter)->force_bit; } -diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_gem_execbuffer.c linux-3.0.9/drivers/gpu/drm/i915/i915_gem_execbuffer.c ---- linux-3.0.9/drivers/gpu/drm/i915/i915_gem_execbuffer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i915/i915_gem_execbuffer.c 2011-11-12 12:47:13.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/drm/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_gem_object *obj, i915_gem_clflush_object(obj); if (obj->base.pending_write_domain) @@ -26716,10 +27354,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_gem_execbuffer.c linux-3.0.9/dr /* The actual obj->write_domain will be updated with * pending_write_domain after we emit the accumulated flush for all -diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c ---- linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c 2011-11-12 12:47:13.000000000 -0500 -@@ -473,7 +473,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 9b1d669..d88e72c 100644 +--- a/drivers/gpu/drm/i915/i915_irq.c ++++ b/drivers/gpu/drm/i915/i915_irq.c +@@ -473,7 +473,7 @@ static irqreturn_t ivybridge_irq_handler(DRM_IRQ_ARGS) u32 de_iir, gt_iir, de_ier, pch_iir, pm_iir; struct drm_i915_master_private *master_priv; @@ -26728,7 +27367,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c linux-3.0.9/drivers/gpu/d /* disable master interrupt before clearing iir */ de_ier = I915_READ(DEIER); -@@ -563,7 +563,7 @@ static irqreturn_t ironlake_irq_handler( +@@ -563,7 +563,7 @@ static irqreturn_t ironlake_irq_handler(DRM_IRQ_ARGS) struct drm_i915_master_private *master_priv; u32 bsd_usr_interrupt = GT_BSD_USER_INTERRUPT; @@ -26737,7 +27376,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c linux-3.0.9/drivers/gpu/d if (IS_GEN6(dev)) bsd_usr_interrupt = GT_GEN6_BSD_USER_INTERRUPT; -@@ -1226,7 +1226,7 @@ static irqreturn_t i915_driver_irq_handl +@@ -1226,7 +1226,7 @@ static irqreturn_t i915_driver_irq_handler(DRM_IRQ_ARGS) int ret = IRQ_NONE, pipe; bool blc_event = false; @@ -26746,7 +27385,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c linux-3.0.9/drivers/gpu/d iir = I915_READ(IIR); -@@ -1735,7 +1735,7 @@ static void ironlake_irq_preinstall(stru +@@ -1735,7 +1735,7 @@ static void ironlake_irq_preinstall(struct drm_device *dev) { drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; @@ -26755,7 +27394,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c linux-3.0.9/drivers/gpu/d INIT_WORK(&dev_priv->hotplug_work, i915_hotplug_work_func); INIT_WORK(&dev_priv->error_work, i915_error_work_func); -@@ -1899,7 +1899,7 @@ static void i915_driver_irq_preinstall(s +@@ -1899,7 +1899,7 @@ static void i915_driver_irq_preinstall(struct drm_device * dev) drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; int pipe; @@ -26764,10 +27403,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/i915_irq.c linux-3.0.9/drivers/gpu/d INIT_WORK(&dev_priv->hotplug_work, i915_hotplug_work_func); INIT_WORK(&dev_priv->error_work, i915_error_work_func); -diff -urNp linux-3.0.9/drivers/gpu/drm/i915/intel_display.c linux-3.0.9/drivers/gpu/drm/i915/intel_display.c ---- linux-3.0.9/drivers/gpu/drm/i915/intel_display.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/i915/intel_display.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1961,7 +1961,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 cbf4c4c..76e1edc 100644 +--- a/drivers/gpu/drm/i915/intel_display.c ++++ b/drivers/gpu/drm/i915/intel_display.c +@@ -1961,7 +1961,7 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y, wait_event(dev_priv->pending_flip_queue, atomic_read(&dev_priv->mm.wedged) || @@ -26776,7 +27416,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/intel_display.c linux-3.0.9/drivers/ /* Big Hammer, we also need to ensure that any pending * MI_WAIT_FOR_EVENT inside a user batch buffer on the -@@ -2548,7 +2548,7 @@ static void intel_crtc_wait_for_pending_ +@@ -2548,7 +2548,7 @@ static void intel_crtc_wait_for_pending_flips(struct drm_crtc *crtc) obj = to_intel_framebuffer(crtc->fb)->obj; dev_priv = crtc->dev->dev_private; wait_event(dev_priv->pending_flip_queue, @@ -26785,7 +27425,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/intel_display.c linux-3.0.9/drivers/ } static bool intel_crtc_driving_pch(struct drm_crtc *crtc) -@@ -6225,7 +6225,7 @@ static void do_intel_finish_page_flip(st +@@ -6225,7 +6225,7 @@ static void do_intel_finish_page_flip(struct drm_device *dev, atomic_clear_mask(1 << intel_crtc->plane, &obj->pending_flip.counter); @@ -26794,7 +27434,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/intel_display.c linux-3.0.9/drivers/ wake_up(&dev_priv->pending_flip_queue); schedule_work(&work->work); -@@ -6514,7 +6514,7 @@ static int intel_crtc_page_flip(struct d +@@ -6514,7 +6514,7 @@ static int intel_crtc_page_flip(struct drm_crtc *crtc, /* Block clients from rendering to the new back buffer until * the flip occurs and the object is no longer visible. */ @@ -26803,7 +27443,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/intel_display.c linux-3.0.9/drivers/ ret = dev_priv->display.queue_flip(dev, crtc, fb, obj); if (ret) -@@ -6527,7 +6527,7 @@ static int intel_crtc_page_flip(struct d +@@ -6527,7 +6527,7 @@ static int intel_crtc_page_flip(struct drm_crtc *crtc, return 0; cleanup_pending: @@ -26812,9 +27452,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/i915/intel_display.c linux-3.0.9/drivers/ cleanup_objs: drm_gem_object_unreference(&work->old_fb_obj->base); drm_gem_object_unreference(&obj->base); -diff -urNp linux-3.0.9/drivers/gpu/drm/mga/mga_drv.h linux-3.0.9/drivers/gpu/drm/mga/mga_drv.h ---- linux-3.0.9/drivers/gpu/drm/mga/mga_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/mga/mga_drv.h 2011-11-12 12:47:13.000000000 -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; @@ -26827,10 +27468,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/mga/mga_drv.h linux-3.0.9/drivers/gpu/drm u32 next_fence_to_post; unsigned int fb_cpp; -diff -urNp linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c ---- linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c 2011-11-12 12:47:13.000000000 -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 != 0) return 0; @@ -26839,7 +27481,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c linux-3.0.9/drivers/gpu/drm } -@@ -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); @@ -26848,7 +27490,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c linux-3.0.9/drivers/gpu/drm drm_handle_vblank(dev, 0); handled = 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) != (prim_end & ~0x03)) MGA_WRITE(MGA_PRIMEND, prim_end); @@ -26857,7 +27499,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c linux-3.0.9/drivers/gpu/drm DRM_WAKEUP(&dev_priv->fence_queue); handled = 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, unsigned int *sequence) * using fences. */ DRM_WAIT_ON(ret, dev_priv->fence_queue, 3 * DRM_HZ, @@ -26866,9 +27508,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/mga/mga_irq.c linux-3.0.9/drivers/gpu/drm - *sequence) <= (1 << 23))); *sequence = cur_fence; -diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_bios.c linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_bios.c ---- linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_bios.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_bios.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/gpu/drm/nouveau/nouveau_bios.c b/drivers/gpu/drm/nouveau/nouveau_bios.c +index 729d5fd..2d52506 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_bios.c ++++ b/drivers/gpu/drm/nouveau/nouveau_bios.c @@ -200,7 +200,7 @@ struct methods { const char desc[8]; void (*loadbios)(struct drm_device *, uint8_t *); @@ -26878,7 +27521,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_bios.c linux-3.0.9/driver static struct methods shadow_methods[] = { { "PRAMIN", load_vbios_pramin, true }, -@@ -5488,7 +5488,7 @@ parse_bit_displayport_tbl_entry(struct d +@@ -5488,7 +5488,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 bit_entry *); @@ -26887,9 +27530,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_bios.c linux-3.0.9/driver #define BIT_TABLE(id, funcid) ((struct bit_table){ id, parse_bit_##funcid##_tbl_entry }) -diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_drv.h linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_drv.h ---- linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_drv.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/gpu/drm/nouveau/nouveau_drv.h b/drivers/gpu/drm/nouveau/nouveau_drv.h +index 9c56331..3809ea8 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_drv.h ++++ b/drivers/gpu/drm/nouveau/nouveau_drv.h @@ -227,7 +227,7 @@ struct nouveau_channel { struct list_head pending; uint32_t sequence; @@ -26942,10 +27586,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_drv.h linux-3.0.9/drivers } ttm; struct { -diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_fence.c linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_fence.c ---- linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_fence.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_fence.c 2011-11-12 12:47:13.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/nouveau/nouveau_fence.c +index 56f06b0..3d0f7dd 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 = nvchan_rd32(chan, 0x48); else @@ -26954,19 +27599,20 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_fence.c linux-3.0.9/drive if (chan->fence.sequence_ack == sequence) goto out; -@@ -544,7 +544,7 @@ nouveau_fence_channel_init(struct nouvea +@@ -542,7 +542,7 @@ nouveau_fence_channel_init(struct nouveau_channel *chan) + return ret; + } - INIT_LIST_HEAD(&chan->fence.pending); - spin_lock_init(&chan->fence.lock); - atomic_set(&chan->fence.last_sequence_irq, 0); + atomic_set_unchecked(&chan->fence.last_sequence_irq, 0); return 0; } -diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_gem.c linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_gem.c ---- linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_gem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_gem.c 2011-11-12 12:47:13.000000000 -0500 -@@ -249,7 +249,7 @@ validate_init(struct nouveau_channel *ch +diff --git a/drivers/gpu/drm/nouveau/nouveau_gem.c b/drivers/gpu/drm/nouveau/nouveau_gem.c +index b52e460..bb5bb3c 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_gem.c ++++ b/drivers/gpu/drm/nouveau/nouveau_gem.c +@@ -249,7 +249,7 @@ validate_init(struct nouveau_channel *chan, struct drm_file *file_priv, int trycnt = 0; int ret, i; @@ -26975,10 +27621,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_gem.c linux-3.0.9/drivers retry: if (++trycnt > 100000) { NV_ERROR(dev, "%s failed and gave up.\n", __func__); -diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_state.c linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_state.c ---- linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_state.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_state.c 2011-11-12 12:47:13.000000000 -0500 -@@ -488,7 +488,7 @@ static bool nouveau_switcheroo_can_switc +diff --git a/drivers/gpu/drm/nouveau/nouveau_state.c b/drivers/gpu/drm/nouveau/nouveau_state.c +index 731acea..1b3c064 100644 +--- a/drivers/gpu/drm/nouveau/nouveau_state.c ++++ b/drivers/gpu/drm/nouveau/nouveau_state.c +@@ -488,7 +488,7 @@ static bool nouveau_switcheroo_can_switch(struct pci_dev *pdev) bool can_switch; spin_lock(&dev->count_lock); @@ -26987,9 +27634,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nouveau_state.c linux-3.0.9/drive spin_unlock(&dev->count_lock); return can_switch; } -diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nv04_graph.c linux-3.0.9/drivers/gpu/drm/nouveau/nv04_graph.c ---- linux-3.0.9/drivers/gpu/drm/nouveau/nv04_graph.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/nouveau/nv04_graph.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/gpu/drm/nouveau/nv04_graph.c b/drivers/gpu/drm/nouveau/nv04_graph.c +index 3626ee7..c60f0db 100644 +--- a/drivers/gpu/drm/nouveau/nv04_graph.c ++++ b/drivers/gpu/drm/nouveau/nv04_graph.c @@ -560,7 +560,7 @@ static int nv04_graph_mthd_set_ref(struct nouveau_channel *chan, u32 class, u32 mthd, u32 data) @@ -26999,10 +27647,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/nouveau/nv04_graph.c linux-3.0.9/drivers/ return 0; } -diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_cce.c linux-3.0.9/drivers/gpu/drm/r128/r128_cce.c ---- linux-3.0.9/drivers/gpu/drm/r128/r128_cce.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/r128/r128_cce.c 2011-11-12 12:47:13.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 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) /* GH: Simple idle check. */ @@ -27011,9 +27660,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_cce.c linux-3.0.9/drivers/gpu/d /* 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.0.9/drivers/gpu/drm/r128/r128_drv.h linux-3.0.9/drivers/gpu/drm/r128/r128_drv.h ---- linux-3.0.9/drivers/gpu/drm/r128/r128_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/r128/r128_drv.h 2011-11-12 12:47:13.000000000 -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; @@ -27031,10 +27681,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_drv.h linux-3.0.9/drivers/gpu/d u32 color_fmt; unsigned int front_offset; -diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_irq.c linux-3.0.9/drivers/gpu/drm/r128/r128_irq.c ---- linux-3.0.9/drivers/gpu/drm/r128/r128_irq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/r128/r128_irq.c 2011-11-12 12:47:13.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 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, int crtc) if (crtc != 0) return 0; @@ -27043,7 +27694,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_irq.c linux-3.0.9/drivers/gpu/d } 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); @@ -27052,10 +27703,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_irq.c linux-3.0.9/drivers/gpu/d drm_handle_vblank(dev, 0); return IRQ_HANDLED; } -diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_state.c linux-3.0.9/drivers/gpu/drm/r128/r128_state.c ---- linux-3.0.9/drivers/gpu/drm/r128/r128_state.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/r128/r128_state.c 2011-11-12 12:47:13.000000000 -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/r128_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, static void r128_cce_performance_boxes(drm_r128_private_t *dev_priv) { @@ -27068,10 +27720,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/r128/r128_state.c linux-3.0.9/drivers/gpu } #endif -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/atom.c linux-3.0.9/drivers/gpu/drm/radeon/atom.c ---- linux-3.0.9/drivers/gpu/drm/radeon/atom.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/atom.c 2011-11-12 12:47:13.000000000 -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 9a0aee2..4e5010c 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; @@ -27080,10 +27733,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/atom.c linux-3.0.9/drivers/gpu/drm ctx->card = card; ctx->bios = bios; -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/mkregtable.c linux-3.0.9/drivers/gpu/drm/radeon/mkregtable.c ---- linux-3.0.9/drivers/gpu/drm/radeon/mkregtable.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/mkregtable.c 2011-11-12 12:47:13.000000000 -0500 -@@ -637,14 +637,14 @@ static int parser_auth(struct table *t, +diff --git a/drivers/gpu/drm/radeon/mkregtable.c b/drivers/gpu/drm/radeon/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]; @@ -27100,10 +27754,33 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/mkregtable.c linux-3.0.9/drivers/g if (regcomp (&mask_rex, "(0x[0-9a-fA-F]*) *([_a-zA-Z0-9]*)", REG_EXTENDED)) { -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_atombios.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_atombios.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_atombios.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_atombios.c 2011-11-12 12:47:13.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/radeon.h +index 59d72d0..3621b94 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; + + /* + * 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_table(struct drm_device *dev) struct radeon_gpio_rec gpio; struct radeon_hpd hpd; @@ -27112,10 +27789,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_atombios.c linux-3.0.9/driv if (!atom_parse_data_header(ctx, index, &size, &frev, &crev, &data_offset)) return false; -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_device.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_device.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_device.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_device.c 2011-11-12 12:47:13.000000000 -0500 -@@ -678,7 +678,7 @@ static bool radeon_switcheroo_can_switch +diff --git a/drivers/gpu/drm/radeon/radeon_device.c b/drivers/gpu/drm/radeon/radeon_device.c +index 440e6ec..8f7f68b 100644 +--- a/drivers/gpu/drm/radeon/radeon_device.c ++++ b/drivers/gpu/drm/radeon/radeon_device.c +@@ -678,7 +678,7 @@ static bool radeon_switcheroo_can_switch(struct pci_dev *pdev) bool can_switch; spin_lock(&dev->count_lock); @@ -27124,10 +27802,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_device.c linux-3.0.9/driver spin_unlock(&dev->count_lock); return can_switch; } -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_display.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_display.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_display.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_display.c 2011-11-12 12:47:13.000000000 -0500 -@@ -946,6 +946,8 @@ void radeon_compute_pll_legacy(struct ra +diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/radeon/radeon_display.c +index ed085ce..dabdad7 100644 +--- a/drivers/gpu/drm/radeon/radeon_display.c ++++ b/drivers/gpu/drm/radeon/radeon_display.c +@@ -946,6 +946,8 @@ void radeon_compute_pll_legacy(struct radeon_pll *pll, uint32_t post_div; u32 pll_out_min, pll_out_max; @@ -27136,9 +27815,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_display.c linux-3.0.9/drive DRM_DEBUG_KMS("PLL freq %llu %u %u\n", freq, pll->min_ref_div, pll->max_ref_div); freq = freq * 1000; -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_drv.h linux-3.0.9/drivers/gpu/drm/radeon/radeon_drv.h ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_drv.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/gpu/drm/radeon/radeon_drv.h b/drivers/gpu/drm/radeon/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 { /* SW interrupt */ @@ -27148,10 +27828,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_drv.h linux-3.0.9/drivers/g int vblank_crtc; uint32_t irq_enable_reg; uint32_t r500_disp_irq_reg; -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_fence.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_fence.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_fence.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_fence.c 2011-11-12 12:47:13.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/radeon/radeon_fence.c +index 021d2b6..7969575 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, struct radeon_fence *fence) write_unlock_irqrestore(&rdev->fence_drv.lock, irq_flags); return 0; } @@ -27160,7 +27841,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_fence.c linux-3.0.9/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 *rdev) return r; } radeon_fence_write(rdev, 0); @@ -27169,31 +27850,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_fence.c linux-3.0.9/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.0.9/drivers/gpu/drm/radeon/radeon.h linux-3.0.9/drivers/gpu/drm/radeon/radeon.h ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon.h 2011-11-12 12:47:13.000000000 -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; - - /* - * Asic structures -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_ioc32.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_ioc32.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_ioc32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_ioc32.c 2011-11-12 12:47:13.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/radeon/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 *file, unsigned int cmd, request = compat_alloc_user_space(sizeof(*request)); if (!access_ok(VERIFY_WRITE, request, sizeof(*request)) || __put_user(req32.param, &request->param) @@ -27202,10 +27863,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_ioc32.c linux-3.0.9/drivers &request->value)) return -EFAULT; -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_irq.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_irq.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_irq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_irq.c 2011-11-12 12:47:13.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/radeon/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; @@ -27216,7 +27878,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_irq.c linux-3.0.9/drivers/g 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 = (drm_radeon_private_t *) dev->dev_private; @@ -27225,10 +27887,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_irq.c linux-3.0.9/drivers/g DRM_INIT_WAITQUEUE(&dev_priv->swi_queue); dev->max_vblank_count = 0x001fffff; -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_state.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_state.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_state.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_state.c 2011-11-12 12:47:13.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/radeon/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 = RADEON_NR_SAREA_CLIPRECTS; @@ -27237,7 +27900,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_state.c linux-3.0.9/drivers sarea_priv->nbox * sizeof(depth_boxes[0]))) return -EFAULT; -@@ -3031,7 +3031,7 @@ static int radeon_cp_getparam(struct drm +@@ -3031,7 +3031,7 @@ static int radeon_cp_getparam(struct drm_device *dev, void *data, struct drm_fil { drm_radeon_private_t *dev_priv = dev->dev_private; drm_radeon_getparam_t *param = data; @@ -27246,10 +27909,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_state.c linux-3.0.9/drivers DRM_DEBUG("pid=%d\n", DRM_CURRENTPID); -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_ttm.c linux-3.0.9/drivers/gpu/drm/radeon/radeon_ttm.c ---- linux-3.0.9/drivers/gpu/drm/radeon/radeon_ttm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/radeon_ttm.c 2011-11-12 12:47:13.000000000 -0500 -@@ -649,8 +649,10 @@ int radeon_mmap(struct file *filp, struc +diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c +index 3e9b41b..8619b10 100644 +--- a/drivers/gpu/drm/radeon/radeon_ttm.c ++++ b/drivers/gpu/drm/radeon/radeon_ttm.c +@@ -649,8 +649,10 @@ int radeon_mmap(struct file *filp, struct vm_area_struct *vma) } if (unlikely(ttm_vm_ops == NULL)) { ttm_vm_ops = vma->vm_ops; @@ -27262,10 +27926,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/radeon_ttm.c linux-3.0.9/drivers/g } vma->vm_ops = &radeon_ttm_vm_ops; return 0; -diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/rs690.c linux-3.0.9/drivers/gpu/drm/radeon/rs690.c ---- linux-3.0.9/drivers/gpu/drm/radeon/rs690.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/radeon/rs690.c 2011-11-12 12:47:13.000000000 -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/rs690.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_device *rdev, if (rdev->pm.max_bandwidth.full > rdev->pm.sideport_bandwidth.full && rdev->pm.sideport_bandwidth.full) rdev->pm.max_bandwidth = rdev->pm.sideport_bandwidth; @@ -27278,10 +27943,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/radeon/rs690.c linux-3.0.9/drivers/gpu/dr } else { if (rdev->pm.max_bandwidth.full > rdev->pm.k8_bandwidth.full && rdev->pm.k8_bandwidth.full) -diff -urNp linux-3.0.9/drivers/gpu/drm/ttm/ttm_page_alloc.c linux-3.0.9/drivers/gpu/drm/ttm/ttm_page_alloc.c ---- linux-3.0.9/drivers/gpu/drm/ttm/ttm_page_alloc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/ttm/ttm_page_alloc.c 2011-11-12 12:47:13.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 d948575..059a928 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) { @@ -27293,9 +27959,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/ttm/ttm_page_alloc.c linux-3.0.9/drivers/ struct ttm_page_pool *pool; int shrink_pages = sc->nr_to_scan; -diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_drv.h linux-3.0.9/drivers/gpu/drm/via/via_drv.h ---- linux-3.0.9/drivers/gpu/drm/via/via_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/via/via_drv.h 2011-11-12 12:47:13.000000000 -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]; @@ -27314,10 +27981,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_drv.h linux-3.0.9/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.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/drivers/gpu/drm/via/via_irq.c ---- linux-3.0.9/drivers/gpu/drm/via/via_irq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/via/via_irq.c 2011-11-12 12:47:13.000000000 -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, int crtc) if (crtc != 0) return 0; @@ -27326,7 +27994,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/drivers/gpu/drm } 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) status = VIA_READ(VIA_REG_INTERRUPT); if (status & VIA_IRQ_VBLANK_PENDING) { @@ -27337,7 +28005,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/drivers/gpu/drm do_gettimeofday(&cur_vblank); if (dev_priv->last_vblank_valid) { dev_priv->usec_per_vblank = -@@ -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 = cur_vblank; dev_priv->last_vblank_valid = 1; } @@ -27346,7 +28014,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/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) for (i = 0; i < dev_priv->num_irqs; ++i) { if (status & cur_irq->pending_mask) { @@ -27355,7 +28023,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/drivers/gpu/drm DRM_WAKEUP(&cur_irq->irq_queue); handled = 1; if (dev_priv->irq_map[drm_via_irq_dma0_td] == 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, unsigned int irq, int force_sequence DRM_WAIT_ON(ret, cur_irq->irq_queue, 3 * DRM_HZ, ((VIA_READ(masks[irq][2]) & masks[irq][3]) == masks[irq][4])); @@ -27369,7 +28037,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/drivers/gpu/drm *sequence) <= (1 << 23))); } *sequence = 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 *dev) } for (i = 0; i < dev_priv->num_irqs; ++i) { @@ -27378,7 +28046,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/drivers/gpu/drm cur_irq->enable_mask = dev_priv->irq_masks[i][0]; cur_irq->pending_mask = 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 += @@ -27387,9 +28055,10 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/via/via_irq.c linux-3.0.9/drivers/gpu/drm irqwait->request.type &= ~_DRM_VBLANK_RELATIVE; case VIA_IRQ_ABSOLUTE: break; -diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h ---- linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h b/drivers/gpu/drm/vmwgfx/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. */ @@ -27399,10 +28068,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_drv.h linux-3.0.9/drivers/g wait_queue_head_t fence_queue; wait_queue_head_t fifo_queue; atomic_t fence_queue_waiters; -diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c ---- linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c 2011-11-12 12:47:13.000000000 -0500 -@@ -610,7 +610,7 @@ int vmw_execbuf_ioctl(struct drm_device +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c b/drivers/gpu/drm/vmwgfx/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; @@ -27411,10 +28081,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c linux-3.0.9/drive void *cmd; uint32_t sequence; struct vmw_sw_context *sw_context = &dev_priv->ctx; -diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c ---- linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c 2011-11-12 12:47:13.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/vmwgfx/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)) @@ -27423,10 +28094,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fence.c linux-3.0.9/drivers else { fence = list_first_entry(&queue->head, struct vmw_fence, head); -diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c ---- linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c 2011-11-12 12:47:13.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/vmwgfx/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, struct vmw_fifo_state *fifo) (unsigned int) min, (unsigned int) fifo->capabilities); @@ -27435,7 +28107,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c linux-3.0.9/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); @@ -27444,7 +28116,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c linux-3.0.9/drivers/ } else { need_bounce = 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) fm = vmw_fifo_reserve(dev_priv, bytes); if (unlikely(fm == NULL)) { @@ -27453,7 +28125,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c linux-3.0.9/drivers/ ret = -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) } do { @@ -27462,10 +28134,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c linux-3.0.9/drivers/ } while (*sequence == 0); if (!(fifo_state->capabilities & SVGA_FIFO_CAP_FENCE)) { -diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c ---- linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c 2011-11-12 12:47:13.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/vmwgfx/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. */ @@ -27474,7 +28147,7 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c linux-3.0.9/drivers/g > VMW_FENCE_WRAP); 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, if (fifo_idle) down_read(&fifo_state->rwsem); @@ -27483,10 +28156,11 @@ diff -urNp linux-3.0.9/drivers/gpu/drm/vmwgfx/vmwgfx_irq.c linux-3.0.9/drivers/g ret = 0; for (;;) { -diff -urNp linux-3.0.9/drivers/hid/hid-core.c linux-3.0.9/drivers/hid/hid-core.c ---- linux-3.0.9/drivers/hid/hid-core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/hid/hid-core.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1940,7 +1940,7 @@ static bool hid_ignore(struct hid_device +diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c +index 4f81d20..4b5f337 100644 +--- a/drivers/hid/hid-core.c ++++ b/drivers/hid/hid-core.c +@@ -1940,7 +1940,7 @@ static bool hid_ignore(struct hid_device *hdev) int hid_add_device(struct hid_device *hdev) { @@ -27495,7 +28169,7 @@ diff -urNp linux-3.0.9/drivers/hid/hid-core.c linux-3.0.9/drivers/hid/hid-core.c int ret; if (WARN_ON(hdev->status & HID_STAT_ADDED)) -@@ -1955,7 +1955,7 @@ int hid_add_device(struct hid_device *hd +@@ -1955,7 +1955,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, @@ -27504,10 +28178,11 @@ diff -urNp linux-3.0.9/drivers/hid/hid-core.c linux-3.0.9/drivers/hid/hid-core.c hid_debug_register(hdev, dev_name(&hdev->dev)); ret = device_add(&hdev->dev); -diff -urNp linux-3.0.9/drivers/hid/usbhid/hiddev.c linux-3.0.9/drivers/hid/usbhid/hiddev.c ---- linux-3.0.9/drivers/hid/usbhid/hiddev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/hid/usbhid/hiddev.c 2011-11-12 12:47:13.000000000 -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; case HIDIOCAPPLICATION: @@ -27516,10 +28191,11 @@ diff -urNp linux-3.0.9/drivers/hid/usbhid/hiddev.c linux-3.0.9/drivers/hid/usbhi break; for (i = 0; i < hid->maxcollection; i++) -diff -urNp linux-3.0.9/drivers/hwmon/acpi_power_meter.c linux-3.0.9/drivers/hwmon/acpi_power_meter.c ---- linux-3.0.9/drivers/hwmon/acpi_power_meter.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/hwmon/acpi_power_meter.c 2011-11-12 12:47:13.000000000 -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 device_attribute *devattr, return res; temp /= 1000; @@ -27528,9 +28204,10 @@ diff -urNp linux-3.0.9/drivers/hwmon/acpi_power_meter.c linux-3.0.9/drivers/hwmo mutex_lock(&resource->lock); resource->trip[attr->index - 7] = temp; -diff -urNp linux-3.0.9/drivers/hwmon/sht15.c linux-3.0.9/drivers/hwmon/sht15.c ---- linux-3.0.9/drivers/hwmon/sht15.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/hwmon/sht15.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/hwmon/sht15.c b/drivers/hwmon/sht15.c +index cf4330b..8ea6aeb 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; @@ -27540,7 +28217,7 @@ diff -urNp linux-3.0.9/drivers/hwmon/sht15.c linux-3.0.9/drivers/hwmon/sht15.c }; /** -@@ -509,13 +509,13 @@ static int sht15_measurement(struct sht1 +@@ -509,13 +509,13 @@ static int sht15_measurement(struct sht15_data *data, return ret; gpio_direction_input(data->pdata->gpio_data); @@ -27556,7 +28233,7 @@ diff -urNp linux-3.0.9/drivers/hwmon/sht15.c linux-3.0.9/drivers/hwmon/sht15.c schedule_work(&data->read_work); } ret = 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, void *d) /* First disable the interrupt */ disable_irq_nosync(irq); @@ -27565,7 +28242,7 @@ diff -urNp linux-3.0.9/drivers/hwmon/sht15.c linux-3.0.9/drivers/hwmon/sht15.c /* Then schedule a reading work struct */ if (data->state != 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! */ @@ -27579,10 +28256,11 @@ diff -urNp linux-3.0.9/drivers/hwmon/sht15.c linux-3.0.9/drivers/hwmon/sht15.c return; } -diff -urNp linux-3.0.9/drivers/hwmon/w83791d.c linux-3.0.9/drivers/hwmon/w83791d.c ---- linux-3.0.9/drivers/hwmon/w83791d.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/hwmon/w83791d.c 2011-11-12 12:47:13.000000000 -0500 -@@ -329,8 +329,8 @@ static int w83791d_detect(struct i2c_cli +diff --git a/drivers/hwmon/w83791d.c b/drivers/hwmon/w83791d.c +index 17cf1ab..8c2844e 100644 +--- a/drivers/hwmon/w83791d.c ++++ b/drivers/hwmon/w83791d.c +@@ -329,8 +329,8 @@ static int w83791d_detect(struct i2c_client *client, struct i2c_board_info *info); static int w83791d_remove(struct i2c_client *client); @@ -27593,9 +28271,10 @@ diff -urNp linux-3.0.9/drivers/hwmon/w83791d.c linux-3.0.9/drivers/hwmon/w83791d static struct w83791d_data *w83791d_update_device(struct device *dev); #ifdef DEBUG -diff -urNp linux-3.0.9/drivers/i2c/busses/i2c-amd756-s4882.c linux-3.0.9/drivers/i2c/busses/i2c-amd756-s4882.c ---- linux-3.0.9/drivers/i2c/busses/i2c-amd756-s4882.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/i2c/busses/i2c-amd756-s4882.c 2011-11-12 12:47:13.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; @@ -27605,9 +28284,10 @@ diff -urNp linux-3.0.9/drivers/i2c/busses/i2c-amd756-s4882.c linux-3.0.9/drivers /* Wrapper access functions for multiplexed SMBus */ static DEFINE_MUTEX(amd756_lock); -diff -urNp linux-3.0.9/drivers/i2c/busses/i2c-nforce2-s4985.c linux-3.0.9/drivers/i2c/busses/i2c-nforce2-s4985.c ---- linux-3.0.9/drivers/i2c/busses/i2c-nforce2-s4985.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/i2c/busses/i2c-nforce2-s4985.c 2011-11-12 12:47:13.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; @@ -27617,9 +28297,10 @@ diff -urNp linux-3.0.9/drivers/i2c/busses/i2c-nforce2-s4985.c linux-3.0.9/driver /* Wrapper access functions for multiplexed SMBus */ static DEFINE_MUTEX(nforce2_lock); -diff -urNp linux-3.0.9/drivers/i2c/i2c-mux.c linux-3.0.9/drivers/i2c/i2c-mux.c ---- linux-3.0.9/drivers/i2c/i2c-mux.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/i2c/i2c-mux.c 2011-11-12 12:47:13.000000000 -0500 +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 { @@ -27629,10 +28310,11 @@ diff -urNp linux-3.0.9/drivers/i2c/i2c-mux.c linux-3.0.9/drivers/i2c/i2c-mux.c struct i2c_adapter *parent; void *mux_dev; /* the mux chip/device */ -diff -urNp linux-3.0.9/drivers/ide/aec62xx.c linux-3.0.9/drivers/ide/aec62xx.c ---- linux-3.0.9/drivers/ide/aec62xx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/aec62xx.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .cable_detect = atp86x_cable_detect, }; @@ -27641,10 +28323,11 @@ diff -urNp linux-3.0.9/drivers/ide/aec62xx.c linux-3.0.9/drivers/ide/aec62xx.c { /* 0: AEC6210 */ .name = DRV_NAME, .init_chipset = init_chipset_aec62xx, -diff -urNp linux-3.0.9/drivers/ide/alim15x3.c linux-3.0.9/drivers/ide/alim15x3.c ---- linux-3.0.9/drivers/ide/alim15x3.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/alim15x3.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .dma_sff_read_status = ide_dma_sff_read_status, }; @@ -27653,10 +28336,11 @@ diff -urNp linux-3.0.9/drivers/ide/alim15x3.c linux-3.0.9/drivers/ide/alim15x3.c .name = DRV_NAME, .init_chipset = init_chipset_ali15x3, .init_hwif = init_hwif_ali15x3, -diff -urNp linux-3.0.9/drivers/ide/amd74xx.c linux-3.0.9/drivers/ide/amd74xx.c ---- linux-3.0.9/drivers/ide/amd74xx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/amd74xx.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .udma_mask = udma, \ } @@ -27665,10 +28349,11 @@ diff -urNp linux-3.0.9/drivers/ide/amd74xx.c linux-3.0.9/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.0.9/drivers/ide/atiixp.c linux-3.0.9/drivers/ide/atiixp.c ---- linux-3.0.9/drivers/ide/atiixp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/atiixp.c 2011-11-12 12:47:13.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 = { .cable_detect = atiixp_cable_detect, }; @@ -27677,10 +28362,11 @@ diff -urNp linux-3.0.9/drivers/ide/atiixp.c linux-3.0.9/drivers/ide/atiixp.c { /* 0: IXP200/300/400/700 */ .name = DRV_NAME, .enablebits = {{0x48,0x01,0x00}, {0x48,0x08,0x00}}, -diff -urNp linux-3.0.9/drivers/ide/cmd64x.c linux-3.0.9/drivers/ide/cmd64x.c ---- linux-3.0.9/drivers/ide/cmd64x.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/cmd64x.c 2011-11-12 12:47:13.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 = { .dma_sff_read_status = ide_dma_sff_read_status, }; @@ -27689,10 +28375,11 @@ diff -urNp linux-3.0.9/drivers/ide/cmd64x.c linux-3.0.9/drivers/ide/cmd64x.c { /* 0: CMD643 */ .name = DRV_NAME, .init_chipset = init_chipset_cmd64x, -diff -urNp linux-3.0.9/drivers/ide/cs5520.c linux-3.0.9/drivers/ide/cs5520.c ---- linux-3.0.9/drivers/ide/cs5520.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/cs5520.c 2011-11-12 12:47:13.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 = { .set_dma_mode = cs5520_set_dma_mode, }; @@ -27701,10 +28388,11 @@ diff -urNp linux-3.0.9/drivers/ide/cs5520.c linux-3.0.9/drivers/ide/cs5520.c .name = DRV_NAME, .enablebits = { { 0x60, 0x01, 0x01 }, { 0x60, 0x02, 0x02 } }, .port_ops = &cs5520_port_ops, -diff -urNp linux-3.0.9/drivers/ide/cs5530.c linux-3.0.9/drivers/ide/cs5530.c ---- linux-3.0.9/drivers/ide/cs5530.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/cs5530.c 2011-11-12 12:47:13.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 = { .udma_filter = cs5530_udma_filter, }; @@ -27713,10 +28401,11 @@ diff -urNp linux-3.0.9/drivers/ide/cs5530.c linux-3.0.9/drivers/ide/cs5530.c .name = DRV_NAME, .init_chipset = init_chipset_cs5530, .init_hwif = init_hwif_cs5530, -diff -urNp linux-3.0.9/drivers/ide/cs5535.c linux-3.0.9/drivers/ide/cs5535.c ---- linux-3.0.9/drivers/ide/cs5535.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/cs5535.c 2011-11-12 12:47:13.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 = { .cable_detect = cs5535_cable_detect, }; @@ -27725,10 +28414,11 @@ diff -urNp linux-3.0.9/drivers/ide/cs5535.c linux-3.0.9/drivers/ide/cs5535.c .name = DRV_NAME, .port_ops = &cs5535_port_ops, .host_flags = IDE_HFLAG_SINGLE | IDE_HFLAG_POST_SET_MODE, -diff -urNp linux-3.0.9/drivers/ide/cy82c693.c linux-3.0.9/drivers/ide/cy82c693.c ---- linux-3.0.9/drivers/ide/cy82c693.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/cy82c693.c 2011-11-12 12:47:13.000000000 -0500 -@@ -161,7 +161,7 @@ static const struct ide_port_ops cy82c69 +diff --git a/drivers/ide/cy82c693.c b/drivers/ide/cy82c693.c +index 3be60da..93c1104 100644 +--- a/drivers/ide/cy82c693.c ++++ b/drivers/ide/cy82c693.c +@@ -161,7 +161,7 @@ static const struct ide_port_ops cy82c693_port_ops = { .set_dma_mode = cy82c693_set_dma_mode, }; @@ -27737,10 +28427,11 @@ diff -urNp linux-3.0.9/drivers/ide/cy82c693.c linux-3.0.9/drivers/ide/cy82c693.c .name = DRV_NAME, .init_iops = init_iops_cy82c693, .port_ops = &cy82c693_port_ops, -diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c ---- linux-3.0.9/drivers/ide/hpt366.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/hpt366.c 2011-11-12 12:47:13.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 = { } }; @@ -27749,7 +28440,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT36x", .chip_type = HPT36x, .udma_mask = HPT366_ALLOW_ATA66_3 ? (HPT366_ALLOW_ATA66_4 ? ATA_UDMA4 : 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 = { .timings = &hpt36x_timings }; @@ -27758,7 +28449,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT370", .chip_type = HPT370, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27767,7 +28458,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT370A", .chip_type = HPT370A, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27776,7 +28467,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT374", .chip_type = HPT374, .udma_mask = ATA_UDMA5, -@@ -475,7 +475,7 @@ static const struct hpt_info hpt374 __de +@@ -475,7 +475,7 @@ static const struct hpt_info hpt374 __devinitdata = { .timings = &hpt37x_timings }; @@ -27785,7 +28476,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT372", .chip_type = HPT372, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27794,7 +28485,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT372A", .chip_type = HPT372A, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27803,7 +28494,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT302", .chip_type = HPT302, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27812,7 +28503,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT371", .chip_type = HPT371, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27821,7 +28512,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT372N", .chip_type = HPT372N, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27830,7 +28521,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT302N", .chip_type = HPT302N, .udma_mask = 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 = { .timings = &hpt37x_timings }; @@ -27839,7 +28530,7 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c .chip_name = "HPT371N", .chip_type = HPT371N, .udma_mask = 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 = { .dma_sff_read_status = ide_dma_sff_read_status, }; @@ -27848,10 +28539,11 @@ diff -urNp linux-3.0.9/drivers/ide/hpt366.c linux-3.0.9/drivers/ide/hpt366.c { /* 0: HPT36x */ .name = DRV_NAME, .init_chipset = init_chipset_hpt366, -diff -urNp linux-3.0.9/drivers/ide/ide-cd.c linux-3.0.9/drivers/ide/ide-cd.c ---- linux-3.0.9/drivers/ide/ide-cd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/ide-cd.c 2011-11-12 12:47:13.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, struct request *rq) alignment = queue_dma_alignment(q) | q->dma_pad_mask; if ((unsigned long)buf & alignment || blk_rq_bytes(rq) & q->dma_pad_mask @@ -27860,10 +28552,11 @@ diff -urNp linux-3.0.9/drivers/ide/ide-cd.c linux-3.0.9/drivers/ide/ide-cd.c drive->dma = 0; } } -diff -urNp linux-3.0.9/drivers/ide/ide-floppy.c linux-3.0.9/drivers/ide/ide-floppy.c ---- linux-3.0.9/drivers/ide/ide-floppy.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/ide-floppy.c 2011-11-12 12:47:13.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 *drive) u8 pc_buf[256], header_len, desc_cnt; int i, rc = 1, blocks, length; @@ -27872,10 +28565,11 @@ diff -urNp linux-3.0.9/drivers/ide/ide-floppy.c linux-3.0.9/drivers/ide/ide-flop ide_debug_log(IDE_DBG_FUNC, "enter"); drive->bios_cyl = 0; -diff -urNp linux-3.0.9/drivers/ide/ide-pci-generic.c linux-3.0.9/drivers/ide/ide-pci-generic.c ---- linux-3.0.9/drivers/ide/ide-pci-generic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/ide-pci-generic.c 2011-11-12 12:47:13.000000000 -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 = { .udma_mask = ATA_UDMA6, \ } @@ -27884,10 +28578,11 @@ diff -urNp linux-3.0.9/drivers/ide/ide-pci-generic.c linux-3.0.9/drivers/ide/ide /* 0: Unknown */ DECLARE_GENERIC_PCI_DEV(0), -diff -urNp linux-3.0.9/drivers/ide/it8172.c linux-3.0.9/drivers/ide/it8172.c ---- linux-3.0.9/drivers/ide/it8172.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/it8172.c 2011-11-12 12:47:13.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 = { .set_dma_mode = it8172_set_dma_mode, }; @@ -27896,10 +28591,11 @@ diff -urNp linux-3.0.9/drivers/ide/it8172.c linux-3.0.9/drivers/ide/it8172.c .name = DRV_NAME, .port_ops = &it8172_port_ops, .enablebits = { {0x41, 0x80, 0x80}, {0x00, 0x00, 0x00} }, -diff -urNp linux-3.0.9/drivers/ide/it8213.c linux-3.0.9/drivers/ide/it8213.c ---- linux-3.0.9/drivers/ide/it8213.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/it8213.c 2011-11-12 12:47:13.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 = { .cable_detect = it8213_cable_detect, }; @@ -27908,10 +28604,11 @@ diff -urNp linux-3.0.9/drivers/ide/it8213.c linux-3.0.9/drivers/ide/it8213.c .name = DRV_NAME, .enablebits = { {0x41, 0x80, 0x80} }, .port_ops = &it8213_port_ops, -diff -urNp linux-3.0.9/drivers/ide/it821x.c linux-3.0.9/drivers/ide/it821x.c ---- linux-3.0.9/drivers/ide/it821x.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/it821x.c 2011-11-12 12:47:13.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 = { .cable_detect = it821x_cable_detect, }; @@ -27920,10 +28617,11 @@ diff -urNp linux-3.0.9/drivers/ide/it821x.c linux-3.0.9/drivers/ide/it821x.c .name = DRV_NAME, .init_chipset = init_chipset_it821x, .init_hwif = init_hwif_it821x, -diff -urNp linux-3.0.9/drivers/ide/jmicron.c linux-3.0.9/drivers/ide/jmicron.c ---- linux-3.0.9/drivers/ide/jmicron.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/jmicron.c 2011-11-12 12:47:13.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 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 = { .cable_detect = jmicron_cable_detect, }; @@ -27932,10 +28630,11 @@ diff -urNp linux-3.0.9/drivers/ide/jmicron.c linux-3.0.9/drivers/ide/jmicron.c .name = DRV_NAME, .enablebits = { { 0x40, 0x01, 0x01 }, { 0x40, 0x10, 0x10 } }, .port_ops = &jmicron_port_ops, -diff -urNp linux-3.0.9/drivers/ide/ns87415.c linux-3.0.9/drivers/ide/ns87415.c ---- linux-3.0.9/drivers/ide/ns87415.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/ns87415.c 2011-11-12 12:47:13.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 = { .dma_sff_read_status = superio_dma_sff_read_status, }; @@ -27944,10 +28643,11 @@ diff -urNp linux-3.0.9/drivers/ide/ns87415.c linux-3.0.9/drivers/ide/ns87415.c .name = DRV_NAME, .init_hwif = init_hwif_ns87415, .tp_ops = &ns87415_tp_ops, -diff -urNp linux-3.0.9/drivers/ide/opti621.c linux-3.0.9/drivers/ide/opti621.c ---- linux-3.0.9/drivers/ide/opti621.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/opti621.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .set_pio_mode = opti621_set_pio_mode, }; @@ -27956,10 +28656,11 @@ diff -urNp linux-3.0.9/drivers/ide/opti621.c linux-3.0.9/drivers/ide/opti621.c .name = DRV_NAME, .enablebits = { {0x45, 0x80, 0x00}, {0x40, 0x08, 0x00} }, .port_ops = &opti621_port_ops, -diff -urNp linux-3.0.9/drivers/ide/pdc202xx_new.c linux-3.0.9/drivers/ide/pdc202xx_new.c ---- linux-3.0.9/drivers/ide/pdc202xx_new.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/pdc202xx_new.c 2011-11-12 12:47:13.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 = { .udma_mask = udma, \ } @@ -27968,10 +28669,11 @@ diff -urNp linux-3.0.9/drivers/ide/pdc202xx_new.c linux-3.0.9/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.0.9/drivers/ide/pdc202xx_old.c linux-3.0.9/drivers/ide/pdc202xx_old.c ---- linux-3.0.9/drivers/ide/pdc202xx_old.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/pdc202xx_old.c 2011-11-12 12:47:13.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 = { .max_sectors = sectors, \ } @@ -27980,10 +28682,11 @@ diff -urNp linux-3.0.9/drivers/ide/pdc202xx_old.c linux-3.0.9/drivers/ide/pdc202 { /* 0: PDC20246 */ .name = DRV_NAME, .init_chipset = init_chipset_pdc202xx, -diff -urNp linux-3.0.9/drivers/ide/piix.c linux-3.0.9/drivers/ide/piix.c ---- linux-3.0.9/drivers/ide/piix.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/piix.c 2011-11-12 12:47:13.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 = { .udma_mask = udma, \ } @@ -27992,10 +28695,11 @@ diff -urNp linux-3.0.9/drivers/ide/piix.c linux-3.0.9/drivers/ide/piix.c /* 0: MPIIX */ { /* * MPIIX actually has only a single IDE channel mapped to -diff -urNp linux-3.0.9/drivers/ide/rz1000.c linux-3.0.9/drivers/ide/rz1000.c ---- linux-3.0.9/drivers/ide/rz1000.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/rz1000.c 2011-11-12 12:47:13.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 pci_dev *dev) } } @@ -28004,10 +28708,11 @@ diff -urNp linux-3.0.9/drivers/ide/rz1000.c linux-3.0.9/drivers/ide/rz1000.c .name = DRV_NAME, .host_flags = IDE_HFLAG_NO_DMA, }; -diff -urNp linux-3.0.9/drivers/ide/sc1200.c linux-3.0.9/drivers/ide/sc1200.c ---- linux-3.0.9/drivers/ide/sc1200.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/sc1200.c 2011-11-12 12:47:13.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 = { .dma_sff_read_status = ide_dma_sff_read_status, }; @@ -28016,10 +28721,11 @@ diff -urNp linux-3.0.9/drivers/ide/sc1200.c linux-3.0.9/drivers/ide/sc1200.c .name = DRV_NAME, .port_ops = &sc1200_port_ops, .dma_ops = &sc1200_dma_ops, -diff -urNp linux-3.0.9/drivers/ide/scc_pata.c linux-3.0.9/drivers/ide/scc_pata.c ---- linux-3.0.9/drivers/ide/scc_pata.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/scc_pata.c 2011-11-12 12:47:13.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 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 = { .dma_sff_read_status = scc_dma_sff_read_status, }; @@ -28028,10 +28734,11 @@ diff -urNp linux-3.0.9/drivers/ide/scc_pata.c linux-3.0.9/drivers/ide/scc_pata.c .name = "sccIDE", .init_iops = init_iops_scc, .init_dma = scc_init_dma, -diff -urNp linux-3.0.9/drivers/ide/serverworks.c linux-3.0.9/drivers/ide/serverworks.c ---- linux-3.0.9/drivers/ide/serverworks.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/serverworks.c 2011-11-12 12:47:13.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 = { .cable_detect = svwks_cable_detect, }; @@ -28040,10 +28747,11 @@ diff -urNp linux-3.0.9/drivers/ide/serverworks.c linux-3.0.9/drivers/ide/serverw { /* 0: OSB4 */ .name = DRV_NAME, .init_chipset = init_chipset_svwks, -diff -urNp linux-3.0.9/drivers/ide/setup-pci.c linux-3.0.9/drivers/ide/setup-pci.c ---- linux-3.0.9/drivers/ide/setup-pci.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/setup-pci.c 2011-11-12 12:47:13.000000000 -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 pci_dev *dev2, int ret, i, n_ports = dev2 ? 4 : 2; struct ide_hw hw[4], *hws[] = { NULL, NULL, NULL, NULL }; @@ -28052,10 +28760,11 @@ diff -urNp linux-3.0.9/drivers/ide/setup-pci.c linux-3.0.9/drivers/ide/setup-pci for (i = 0; i < n_ports / 2; i++) { ret = ide_setup_pci_controller(pdev[i], d, !i); if (ret < 0) -diff -urNp linux-3.0.9/drivers/ide/siimage.c linux-3.0.9/drivers/ide/siimage.c ---- linux-3.0.9/drivers/ide/siimage.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/siimage.c 2011-11-12 12:47:13.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 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 = { .udma_mask = ATA_UDMA6, \ } @@ -28064,10 +28773,11 @@ diff -urNp linux-3.0.9/drivers/ide/siimage.c linux-3.0.9/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.0.9/drivers/ide/sis5513.c linux-3.0.9/drivers/ide/sis5513.c ---- linux-3.0.9/drivers/ide/sis5513.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/sis5513.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .cable_detect = sis_cable_detect, }; @@ -28076,10 +28786,11 @@ diff -urNp linux-3.0.9/drivers/ide/sis5513.c linux-3.0.9/drivers/ide/sis5513.c .name = DRV_NAME, .init_chipset = init_chipset_sis5513, .enablebits = { {0x4a, 0x02, 0x02}, {0x4a, 0x04, 0x04} }, -diff -urNp linux-3.0.9/drivers/ide/sl82c105.c linux-3.0.9/drivers/ide/sl82c105.c ---- linux-3.0.9/drivers/ide/sl82c105.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/sl82c105.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .dma_sff_read_status = ide_dma_sff_read_status, }; @@ -28088,10 +28799,11 @@ diff -urNp linux-3.0.9/drivers/ide/sl82c105.c linux-3.0.9/drivers/ide/sl82c105.c .name = DRV_NAME, .init_chipset = init_chipset_sl82c105, .enablebits = {{0x40,0x01,0x01}, {0x40,0x10,0x10}}, -diff -urNp linux-3.0.9/drivers/ide/slc90e66.c linux-3.0.9/drivers/ide/slc90e66.c ---- linux-3.0.9/drivers/ide/slc90e66.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/slc90e66.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .cable_detect = slc90e66_cable_detect, }; @@ -28100,10 +28812,11 @@ diff -urNp linux-3.0.9/drivers/ide/slc90e66.c linux-3.0.9/drivers/ide/slc90e66.c .name = DRV_NAME, .enablebits = { {0x41, 0x80, 0x80}, {0x43, 0x80, 0x80} }, .port_ops = &slc90e66_port_ops, -diff -urNp linux-3.0.9/drivers/ide/tc86c001.c linux-3.0.9/drivers/ide/tc86c001.c ---- linux-3.0.9/drivers/ide/tc86c001.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/tc86c001.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .dma_sff_read_status = ide_dma_sff_read_status, }; @@ -28112,10 +28825,11 @@ diff -urNp linux-3.0.9/drivers/ide/tc86c001.c linux-3.0.9/drivers/ide/tc86c001.c .name = DRV_NAME, .init_hwif = init_hwif_tc86c001, .port_ops = &tc86c001_port_ops, -diff -urNp linux-3.0.9/drivers/ide/triflex.c linux-3.0.9/drivers/ide/triflex.c ---- linux-3.0.9/drivers/ide/triflex.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/triflex.c 2011-11-12 12:47:13.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 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 = { .set_dma_mode = triflex_set_mode, }; @@ -28124,10 +28838,11 @@ diff -urNp linux-3.0.9/drivers/ide/triflex.c linux-3.0.9/drivers/ide/triflex.c .name = DRV_NAME, .enablebits = {{0x80, 0x01, 0x01}, {0x80, 0x02, 0x02}}, .port_ops = &triflex_port_ops, -diff -urNp linux-3.0.9/drivers/ide/trm290.c linux-3.0.9/drivers/ide/trm290.c ---- linux-3.0.9/drivers/ide/trm290.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/trm290.c 2011-11-12 12:47:13.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 = { .dma_check = trm290_dma_check, }; @@ -28136,10 +28851,11 @@ diff -urNp linux-3.0.9/drivers/ide/trm290.c linux-3.0.9/drivers/ide/trm290.c .name = DRV_NAME, .init_hwif = init_hwif_trm290, .tp_ops = &trm290_tp_ops, -diff -urNp linux-3.0.9/drivers/ide/via82cxxx.c linux-3.0.9/drivers/ide/via82cxxx.c ---- linux-3.0.9/drivers/ide/via82cxxx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/ide/via82cxxx.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = { .cable_detect = via82cxxx_cable_detect, }; @@ -28148,10 +28864,11 @@ diff -urNp linux-3.0.9/drivers/ide/via82cxxx.c linux-3.0.9/drivers/ide/via82cxxx .name = DRV_NAME, .init_chipset = init_chipset_via82cxxx, .enablebits = { { 0x40, 0x02, 0x02 }, { 0x40, 0x01, 0x01 } }, -diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/drivers/infiniband/core/cm.c ---- linux-3.0.9/drivers/infiniband/core/cm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/core/cm.c 2011-11-12 12:47:13.000000000 -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_GROUPS] struct cm_counter_group { struct kobject obj; @@ -28160,7 +28877,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/drivers/infiniba }; 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 *work, struct ib_mad_send_buf *msg = NULL; int ret; @@ -28169,7 +28886,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/drivers/infiniba counter[CM_REQ_COUNTER]); /* 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 *work) if (!cm_id_priv) return; @@ -28178,7 +28895,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/drivers/infiniba counter[CM_REP_COUNTER]); ret = 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 != IB_CM_REP_SENT && cm_id_priv->id.state != IB_CM_MRA_REP_RCVD) { spin_unlock_irq(&cm_id_priv->lock); @@ -28187,7 +28904,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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 = cm_acquire_id(dreq_msg->remote_comm_id, dreq_msg->local_comm_id); if (!cm_id_priv) { @@ -28196,7 +28913,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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: @@ -28205,7 +28922,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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: @@ -28214,7 +28931,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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 == IB_CM_MRA_LAP_RCVD) @@ -28223,7 +28940,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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: @@ -28232,7 +28949,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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: @@ -28241,7 +28958,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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: @@ -28250,7 +28967,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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 *work) cur_cm_id_priv = cm_insert_remote_sidr(cm_id_priv); if (cur_cm_id_priv) { spin_unlock_irq(&cm.lock); @@ -28259,7 +28976,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/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 != CM_REJ_COUNTER)) msg->retries = 1; @@ -28272,7 +28989,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/drivers/infiniba &port->counter_group[CM_XMIT_RETRIES]. counter[attr_index]); -@@ -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 *mad_agent, } attr_id = be16_to_cpu(mad_recv_wc->recv_buf.mad->mad_hdr.attr_id); @@ -28281,7 +28998,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/drivers/infiniba counter[attr_id - CM_ATTR_ID_OFFSET]); work = 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 = container_of(attr, struct cm_counter_attribute, attr); return sprintf(buf, "%ld\n", @@ -28290,9 +29007,10 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/cm.c linux-3.0.9/drivers/infiniba } static const struct sysfs_ops cm_counter_ops = { -diff -urNp linux-3.0.9/drivers/infiniband/core/fmr_pool.c linux-3.0.9/drivers/infiniband/core/fmr_pool.c ---- linux-3.0.9/drivers/infiniband/core/fmr_pool.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/core/fmr_pool.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/infiniband/core/fmr_pool.c b/drivers/infiniband/core/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 { struct task_struct *thread; @@ -28304,7 +29022,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/fmr_pool.c linux-3.0.9/drivers/in 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 = pool_ptr; do { @@ -28317,7 +29035,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/fmr_pool.c linux-3.0.9/drivers/in wake_up_interruptible(&pool->force_wait); 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) } set_current_state(TASK_INTERRUPTIBLE); @@ -28326,7 +29044,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/fmr_pool.c linux-3.0.9/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 = params->dirty_watermark; pool->dirty_len = 0; spin_lock_init(&pool->pool_lock); @@ -28337,7 +29055,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/fmr_pool.c linux-3.0.9/drivers/in init_waitqueue_head(&pool->force_wait); pool->thread = 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); @@ -28351,7 +29069,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/fmr_pool.c linux-3.0.9/drivers/in return -EINTR; 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 >= pool->dirty_watermark) { @@ -28360,10 +29078,11 @@ diff -urNp linux-3.0.9/drivers/infiniband/core/fmr_pool.c linux-3.0.9/drivers/in wake_up_process(pool->thread); } } -diff -urNp linux-3.0.9/drivers/infiniband/hw/cxgb4/mem.c linux-3.0.9/drivers/infiniband/hw/cxgb4/mem.c ---- linux-3.0.9/drivers/infiniband/hw/cxgb4/mem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/cxgb4/mem.c 2011-11-12 12:47:13.000000000 -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/cxgb4/mem.c +index 0347eed..0f0e4b1 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, u32 reset_tpt_entry, int err; struct fw_ri_tpte tpt; u32 stag_idx; @@ -28372,7 +29091,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/cxgb4/mem.c linux-3.0.9/drivers/inf 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, u32 reset_tpt_entry, &rdev->resource.tpt_fifo_lock); if (!stag_idx) return -ENOMEM; @@ -28381,10 +29100,11 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/cxgb4/mem.c linux-3.0.9/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.0.9/drivers/infiniband/hw/ipath/ipath_fs.c linux-3.0.9/drivers/infiniband/hw/ipath/ipath_fs.c ---- linux-3.0.9/drivers/infiniband/hw/ipath/ipath_fs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/ipath/ipath_fs.c 2011-11-12 12:47:13.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 *file, char __user *buf, struct infinipath_counters counters; struct ipath_devdata *dd; @@ -28393,10 +29113,11 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/ipath/ipath_fs.c linux-3.0.9/driver dd = file->f_path.dentry->d_inode->i_private; dd->ipath_f_read_counters(dd, &counters); -diff -urNp linux-3.0.9/drivers/infiniband/hw/ipath/ipath_rc.c linux-3.0.9/drivers/infiniband/hw/ipath/ipath_rc.c ---- linux-3.0.9/drivers/infiniband/hw/ipath/ipath_rc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/ipath/ipath_rc.c 2011-11-12 12:47:13.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; @@ -28405,7 +29126,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/ipath/ipath_rc.c linux-3.0.9/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, struct ipath_ib_header *hdr, IB_ACCESS_REMOTE_ATOMIC))) goto nack_acc_unlck; /* Perform atomic OP and save result. */ @@ -28419,10 +29140,11 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/ipath/ipath_rc.c linux-3.0.9/driver (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, be64_to_cpu(ateth->compare_data), sdata); -diff -urNp linux-3.0.9/drivers/infiniband/hw/ipath/ipath_ruc.c linux-3.0.9/drivers/infiniband/hw/ipath/ipath_ruc.c ---- linux-3.0.9/drivers/infiniband/hw/ipath/ipath_ruc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/ipath/ipath_ruc.c 2011-11-12 12:47:13.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/infiniband/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; @@ -28445,10 +29167,11 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/ipath/ipath_ruc.c linux-3.0.9/drive (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, sdata, wqe->wr.wr.atomic.swap); goto send_comp; -diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes.c linux-3.0.9/drivers/infiniband/hw/nes/nes.c ---- linux-3.0.9/drivers/infiniband/hw/nes/nes.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/nes/nes.c 2011-11-12 12:47:13.000000000 -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 request size to 256 Bytes"); LIST_HEAD(nes_adapter_list); static LIST_HEAD(nes_dev_list); @@ -28457,7 +29180,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes.c linux-3.0.9/drivers/infin 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_device *nesdev, struct nes_cqp_r struct nes_qp *nesqp = cqp_request->cqp_callback_pointer; struct nes_adapter *nesadapter = nesdev->nesadapter; @@ -28466,9 +29189,65 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes.c linux-3.0.9/drivers/infin /* Free the control structures */ -diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c ---- linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c 2011-11-12 12:47:13.000000000 -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; + +-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; +@@ -194,14 +194,14 @@ extern u32 cm_packets_created; + extern u32 cm_packets_received; + extern u32 cm_packets_dropped; + extern u32 cm_packets_retrans; +-extern atomic_t cm_listens_created; +-extern atomic_t cm_listens_destroyed; ++extern atomic_unchecked_t cm_listens_created; ++extern atomic_unchecked_t 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; + + 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 e74cdf9..4b5ca90 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; @@ -28512,7 +29291,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in /** -@@ -1045,7 +1045,7 @@ static int mini_cm_dec_refcnt_listen(str +@@ -1045,7 +1045,7 @@ static int mini_cm_dec_refcnt_listen(struct nes_cm_core *cm_core, kfree(listener); listener = NULL; ret = 0; @@ -28521,7 +29300,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in } else { spin_unlock_irqrestore(&cm_core->listen_list_lock, flags); } -@@ -1240,7 +1240,7 @@ static struct nes_cm_node *make_cm_node( +@@ -1240,7 +1240,7 @@ static struct nes_cm_node *make_cm_node(struct nes_cm_core *cm_core, cm_node->rem_mac); add_hte_node(cm_core, cm_node); @@ -28530,7 +29309,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in return cm_node; } -@@ -1298,7 +1298,7 @@ static int rem_ref_cm_node(struct nes_cm +@@ -1298,7 +1298,7 @@ static int rem_ref_cm_node(struct nes_cm_core *cm_core, } atomic_dec(&cm_core->node_cnt); @@ -28539,7 +29318,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nesqp = cm_node->nesqp; if (nesqp) { nesqp->cm_node = NULL; -@@ -1365,7 +1365,7 @@ static int process_options(struct nes_cm +@@ -1365,7 +1365,7 @@ static int process_options(struct nes_cm_node *cm_node, u8 *optionsloc, static void drop_packet(struct sk_buff *skb) { @@ -28548,7 +29327,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in dev_kfree_skb_any(skb); } -@@ -1428,7 +1428,7 @@ static void handle_rst_pkt(struct nes_cm +@@ -1428,7 +1428,7 @@ static void handle_rst_pkt(struct nes_cm_node *cm_node, struct sk_buff *skb, { int reset = 0; /* whether to send reset in case of err.. */ @@ -28557,7 +29336,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nes_debug(NES_DBG_CM, "Received Reset, cm_node = %p, state = %u." " refcnt=%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 +@@ -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; } @@ -28566,7 +29345,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in loopbackremotenode->loopbackpartner = cm_node; loopbackremotenode->tcp_cntxt.rcv_wscale = NES_CM_DEFAULT_RCV_WND_SCALE; -@@ -2332,7 +2332,7 @@ static int mini_cm_recv_pkt(struct nes_c +@@ -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 == NES_CM_STATE_TSA) { rem_ref_cm_node(cm_core, cm_node); @@ -28575,7 +29354,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in dev_kfree_skb_any(skb); break; } -@@ -2638,7 +2638,7 @@ static int nes_cm_disconn_true(struct ne +@@ -2638,7 +2638,7 @@ static int nes_cm_disconn_true(struct nes_qp *nesqp) if ((cm_id) && (cm_id->event_handler)) { if (issue_disconn) { @@ -28584,7 +29363,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in cm_event.event = IW_CM_EVENT_DISCONNECT; cm_event.status = disconn_status; cm_event.local_addr = cm_id->local_addr; -@@ -2660,7 +2660,7 @@ static int nes_cm_disconn_true(struct ne +@@ -2660,7 +2660,7 @@ static int nes_cm_disconn_true(struct nes_qp *nesqp) } if (issue_close) { @@ -28593,7 +29372,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nes_disconnect(nesqp, 1); cm_id->provider_data = nesqp; -@@ -2791,7 +2791,7 @@ int nes_accept(struct iw_cm_id *cm_id, s +@@ -2791,7 +2791,7 @@ int nes_accept(struct iw_cm_id *cm_id, struct iw_cm_conn_param *conn_param) nes_debug(NES_DBG_CM, "QP%u, cm_node=%p, jiffies = %lu listener = %p\n", nesqp->hwqp.qp_id, cm_node, jiffies, cm_node->listener); @@ -28602,7 +29381,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nes_debug(NES_DBG_CM, "netdev refcnt = %u.\n", netdev_refcnt_read(nesvnic->netdev)); -@@ -3001,7 +3001,7 @@ int nes_reject(struct iw_cm_id *cm_id, c +@@ -3001,7 +3001,7 @@ int nes_reject(struct iw_cm_id *cm_id, const void *pdata, u8 pdata_len) struct nes_cm_core *cm_core; @@ -28611,7 +29390,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in cm_node = (struct nes_cm_node *) cm_id->provider_data; loopback = cm_node->loopbackpartner; cm_core = cm_node->cm_core; -@@ -3067,7 +3067,7 @@ int nes_connect(struct iw_cm_id *cm_id, +@@ -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)); @@ -28620,7 +29399,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nesqp->active_conn = 1; /* cache the cm_id in the qp */ -@@ -3173,7 +3173,7 @@ int nes_create_listen(struct iw_cm_id *c +@@ -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; } @@ -28629,7 +29408,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in } cm_id->add_ref(cm_id); -@@ -3278,7 +3278,7 @@ static void cm_event_connected(struct ne +@@ -3278,7 +3278,7 @@ static void cm_event_connected(struct nes_cm_event *event) if (nesqp->destroyed) { return; } @@ -28638,7 +29417,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nes_debug(NES_DBG_CM, "QP%u attempting to connect to 0x%08X:0x%04X on" " local port 0x%04X. jiffies = %lu.\n", nesqp->hwqp.qp_id, -@@ -3493,7 +3493,7 @@ static void cm_event_reset(struct nes_cm +@@ -3493,7 +3493,7 @@ static void cm_event_reset(struct nes_cm_event *event) cm_id->add_ref(cm_id); ret = cm_id->event_handler(cm_id, &cm_event); @@ -28647,7 +29426,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in cm_event.event = IW_CM_EVENT_CLOSE; cm_event.status = 0; cm_event.provider_data = cm_id->provider_data; -@@ -3529,7 +3529,7 @@ static void cm_event_mpa_req(struct nes_ +@@ -3529,7 +3529,7 @@ static void cm_event_mpa_req(struct nes_cm_event *event) return; cm_id = cm_node->cm_id; @@ -28656,7 +29435,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nes_debug(NES_DBG_CM, "cm_node = %p - cm_id = %p, jiffies = %lu\n", cm_node, cm_id, jiffies); -@@ -3567,7 +3567,7 @@ static void cm_event_mpa_reject(struct n +@@ -3567,7 +3567,7 @@ static void cm_event_mpa_reject(struct nes_cm_event *event) return; cm_id = cm_node->cm_id; @@ -28665,64 +29444,11 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_cm.c linux-3.0.9/drivers/in nes_debug(NES_DBG_CM, "cm_node = %p - cm_id = %p, jiffies = %lu\n", cm_node, cm_id, jiffies); -diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes.h linux-3.0.9/drivers/infiniband/hw/nes/nes.h ---- linux-3.0.9/drivers/infiniband/hw/nes/nes.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/nes/nes.h 2011-11-12 12:47:13.000000000 -0500 -@@ -175,17 +175,17 @@ extern unsigned int nes_debug_level; - extern unsigned int wqm_quanta; - extern struct list_head nes_adapter_list; - --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; -@@ -194,14 +194,14 @@ extern u32 cm_packets_created; - extern u32 cm_packets_received; - extern u32 cm_packets_dropped; - extern u32 cm_packets_retrans; --extern atomic_t cm_listens_created; --extern atomic_t cm_listens_destroyed; -+extern atomic_unchecked_t cm_listens_created; -+extern atomic_unchecked_t 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; - - extern u32 int_mod_timer_init; - extern u32 int_mod_cq_depth_256; -diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_nic.c linux-3.0.9/drivers/infiniband/hw/nes/nes_nic.c ---- linux-3.0.9/drivers/infiniband/hw/nes/nes_nic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/nes/nes_nic.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1274,31 +1274,31 @@ 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 d3a1c41..2356add 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] = mh_detected; target_stat_values[++index] = mh_pauses_sent; target_stat_values[++index] = nesvnic->endnode_ipv4_tcp_retransmits; @@ -28772,9 +29498,10 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_nic.c linux-3.0.9/drivers/i target_stat_values[++index] = nesadapter->free_4kpbl; target_stat_values[++index] = nesadapter->free_256pbl; target_stat_values[++index] = int_mod_timer_init; -diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_verbs.c linux-3.0.9/drivers/infiniband/hw/nes/nes_verbs.c ---- linux-3.0.9/drivers/infiniband/hw/nes/nes_verbs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/nes/nes_verbs.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/infiniband/hw/nes/nes_verbs.c b/drivers/infiniband/hw/nes/nes_verbs.c +index 95ca93c..c992848 100644 +--- a/drivers/infiniband/hw/nes/nes_verbs.c ++++ b/drivers/infiniband/hw/nes/nes_verbs.c @@ -46,9 +46,9 @@ #include <rdma/ib_umem.h> @@ -28788,7 +29515,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_verbs.c linux-3.0.9/drivers static void nes_unregister_ofa_device(struct nes_ib_device *nesibdev); -@@ -1141,7 +1141,7 @@ static struct ib_qp *nes_create_qp(struc +@@ -1141,7 +1141,7 @@ static struct ib_qp *nes_create_qp(struct ib_pd *ibpd, if (init_attr->create_flags) return ERR_PTR(-EINVAL); @@ -28797,7 +29524,7 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_verbs.c linux-3.0.9/drivers switch (init_attr->qp_type) { case IB_QPT_RC: if (nes_drv_opt & NES_DRV_OPT_NO_INLINE_DATA) { -@@ -1470,7 +1470,7 @@ static int nes_destroy_qp(struct ib_qp * +@@ -1470,7 +1470,7 @@ static int nes_destroy_qp(struct ib_qp *ibqp) struct iw_cm_event cm_event; int ret; @@ -28806,9 +29533,10 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/nes/nes_verbs.c linux-3.0.9/drivers nesqp->destroyed = 1; /* Blow away the connection if it exists. */ -diff -urNp linux-3.0.9/drivers/infiniband/hw/qib/qib.h linux-3.0.9/drivers/infiniband/hw/qib/qib.h ---- linux-3.0.9/drivers/infiniband/hw/qib/qib.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/infiniband/hw/qib/qib.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/infiniband/hw/qib/qib.h b/drivers/infiniband/hw/qib/qib.h +index 769a1d9..7807648 100644 +--- a/drivers/infiniband/hw/qib/qib.h ++++ b/drivers/infiniband/hw/qib/qib.h @@ -51,6 +51,7 @@ #include <linux/completion.h> #include <linux/kref.h> @@ -28817,9 +29545,10 @@ diff -urNp linux-3.0.9/drivers/infiniband/hw/qib/qib.h linux-3.0.9/drivers/infin #include "qib_common.h" #include "qib_verbs.h" -diff -urNp linux-3.0.9/drivers/input/gameport/gameport.c linux-3.0.9/drivers/input/gameport/gameport.c ---- linux-3.0.9/drivers/input/gameport/gameport.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/input/gameport/gameport.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/input/gameport/gameport.c b/drivers/input/gameport/gameport.c +index 5b8f59d..7f36886 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) @@ -28837,10 +29566,11 @@ diff -urNp linux-3.0.9/drivers/input/gameport/gameport.c linux-3.0.9/drivers/inp gameport->dev.bus = &gameport_bus; gameport->dev.release = gameport_release_port; if (gameport->parent) -diff -urNp linux-3.0.9/drivers/input/input.c linux-3.0.9/drivers/input/input.c ---- linux-3.0.9/drivers/input/input.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/input/input.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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_dev *dev) */ int input_register_device(struct input_dev *dev) { @@ -28849,7 +29579,7 @@ diff -urNp linux-3.0.9/drivers/input/input.c linux-3.0.9/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 = input_default_setkeycode; dev_set_name(&dev->dev, "input%ld", @@ -28858,9 +29588,10 @@ diff -urNp linux-3.0.9/drivers/input/input.c linux-3.0.9/drivers/input/input.c error = device_add(&dev->dev); if (error) -diff -urNp linux-3.0.9/drivers/input/joystick/sidewinder.c linux-3.0.9/drivers/input/joystick/sidewinder.c ---- linux-3.0.9/drivers/input/joystick/sidewinder.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/input/joystick/sidewinder.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/input/joystick/sidewinder.c b/drivers/input/joystick/sidewinder.c +index b8d8611..15f8d2c 100644 +--- a/drivers/input/joystick/sidewinder.c ++++ b/drivers/input/joystick/sidewinder.c @@ -30,6 +30,7 @@ #include <linux/kernel.h> #include <linux/module.h> @@ -28878,10 +29609,11 @@ diff -urNp linux-3.0.9/drivers/input/joystick/sidewinder.c linux-3.0.9/drivers/i i = sw_read_packet(sw->gameport, buf, sw->length, 0); if (sw->type == SW_ID_3DP && sw->length == 66 && i != 66) { /* Broken packet, try to fix */ -diff -urNp linux-3.0.9/drivers/input/joystick/xpad.c linux-3.0.9/drivers/input/joystick/xpad.c ---- linux-3.0.9/drivers/input/joystick/xpad.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/input/joystick/xpad.c 2011-11-12 12:47:13.000000000 -0500 -@@ -689,7 +689,7 @@ static void xpad_led_set(struct led_clas +diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c +index 56abf3d..d8dd85d 100644 +--- a/drivers/input/joystick/xpad.c ++++ b/drivers/input/joystick/xpad.c +@@ -689,7 +689,7 @@ static void xpad_led_set(struct led_classdev *led_cdev, static int xpad_led_probe(struct usb_xpad *xpad) { @@ -28890,7 +29622,7 @@ diff -urNp linux-3.0.9/drivers/input/joystick/xpad.c linux-3.0.9/drivers/input/j long led_no; struct xpad_led *led; struct led_classdev *led_cdev; -@@ -702,7 +702,7 @@ static int xpad_led_probe(struct usb_xpa +@@ -702,7 +702,7 @@ static int xpad_led_probe(struct usb_xpad *xpad) if (!led) return -ENOMEM; @@ -28899,10 +29631,11 @@ diff -urNp linux-3.0.9/drivers/input/joystick/xpad.c linux-3.0.9/drivers/input/j snprintf(led->name, sizeof(led->name), "xpad%ld", led_no); led->xpad = xpad; -diff -urNp linux-3.0.9/drivers/input/mousedev.c linux-3.0.9/drivers/input/mousedev.c ---- linux-3.0.9/drivers/input/mousedev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/input/mousedev.c 2011-11-12 12:47:13.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, spin_unlock_irq(&client->packet_lock); @@ -28911,10 +29644,11 @@ diff -urNp linux-3.0.9/drivers/input/mousedev.c linux-3.0.9/drivers/input/moused return -EFAULT; return count; -diff -urNp linux-3.0.9/drivers/input/serio/serio.c linux-3.0.9/drivers/input/serio/serio.c ---- linux-3.0.9/drivers/input/serio/serio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/input/serio/serio.c 2011-11-12 12:47:13.000000000 -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) { @@ -28923,7 +29657,7 @@ diff -urNp linux-3.0.9/drivers/input/serio/serio.c linux-3.0.9/drivers/input/ser __module_get(THIS_MODULE); -@@ -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", @@ -28932,9 +29666,10 @@ diff -urNp linux-3.0.9/drivers/input/serio/serio.c linux-3.0.9/drivers/input/ser serio->dev.bus = &serio_bus; serio->dev.release = serio_release_port; serio->dev.groups = serio_device_attr_groups; -diff -urNp linux-3.0.9/drivers/isdn/capi/capi.c linux-3.0.9/drivers/isdn/capi/capi.c ---- linux-3.0.9/drivers/isdn/capi/capi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/capi/capi.c 2011-11-12 12:47:13.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 { struct capi20_appl *ap; @@ -28946,7 +29681,7 @@ diff -urNp linux-3.0.9/drivers/isdn/capi/capi.c linux-3.0.9/drivers/isdn/capi/ca 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); @@ -28955,7 +29690,7 @@ diff -urNp linux-3.0.9/drivers/isdn/capi/capi.c linux-3.0.9/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 -= len; spin_unlock_bh(&mp->outlock); @@ -28972,10 +29707,11 @@ diff -urNp linux-3.0.9/drivers/isdn/capi/capi.c linux-3.0.9/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.0.9/drivers/isdn/gigaset/common.c linux-3.0.9/drivers/isdn/gigaset/common.c ---- linux-3.0.9/drivers/isdn/gigaset/common.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/gigaset/common.c 2011-11-12 12:47:13.000000000 -0500 -@@ -723,7 +723,7 @@ struct cardstate *gigaset_initcs(struct +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_driver *drv, int channels, cs->commands_pending = 0; cs->cur_at_seq = 0; cs->gotfwver = -1; @@ -28984,9 +29720,10 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/common.c linux-3.0.9/drivers/isdn/gi cs->dev = NULL; cs->tty = NULL; cs->tty_dev = NULL; -diff -urNp linux-3.0.9/drivers/isdn/gigaset/gigaset.h linux-3.0.9/drivers/isdn/gigaset/gigaset.h ---- linux-3.0.9/drivers/isdn/gigaset/gigaset.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/gigaset/gigaset.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/isdn/gigaset/gigaset.h b/drivers/isdn/gigaset/gigaset.h +index 6dd3607..b66e23e 100644 +--- a/drivers/isdn/gigaset/gigaset.h ++++ b/drivers/isdn/gigaset/gigaset.h @@ -35,6 +35,7 @@ #include <linux/tty_driver.h> #include <linux/list.h> @@ -29004,10 +29741,11 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/gigaset.h linux-3.0.9/drivers/isdn/g struct tty_struct *tty; struct tasklet_struct if_wake_tasklet; unsigned control_state; -diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn/gigaset/interface.c ---- linux-3.0.9/drivers/isdn/gigaset/interface.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/gigaset/interface.c 2011-11-12 12:47:13.000000000 -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/interface.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 file *filp) } tty->driver_data = cs; @@ -29018,7 +29756,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn spin_lock_irqsave(&cs->lock, flags); cs->tty = 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, struct file *filp) if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -29031,7 +29769,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn spin_lock_irqsave(&cs->lock, flags); cs->tty = 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 = -ENODEV; @@ -29040,7 +29778,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else { retval = 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 unsigned char *buf, int count) retval = -ENODEV; goto done; } @@ -29049,7 +29787,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); retval = -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 = -ENODEV; @@ -29058,7 +29796,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else if (cs->mstate != 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) if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); @@ -29067,7 +29805,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); else if (cs->mstate != 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) if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -29076,7 +29814,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/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) if (!cs->connected) gig_dbg(DEBUG_IF, "not connected"); /* nothing to do */ @@ -29085,7 +29823,7 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/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, struct ktermios *old) goto out; } @@ -29094,10 +29832,11 @@ diff -urNp linux-3.0.9/drivers/isdn/gigaset/interface.c linux-3.0.9/drivers/isdn dev_warn(cs->dev, "%s: device not opened\n", __func__); goto out; } -diff -urNp linux-3.0.9/drivers/isdn/hardware/avm/b1.c linux-3.0.9/drivers/isdn/hardware/avm/b1.c ---- linux-3.0.9/drivers/isdn/hardware/avm/b1.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/avm/b1.c 2011-11-12 12:47:13.000000000 -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) { @@ -29106,7 +29845,7 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/avm/b1.c linux-3.0.9/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) { @@ -29115,10 +29854,11 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/avm/b1.c linux-3.0.9/drivers/isdn/h return -EFAULT; } else { memcpy(buf, dp, left); -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/capidtmf.c linux-3.0.9/drivers/isdn/hardware/eicon/capidtmf.c ---- linux-3.0.9/drivers/isdn/hardware/eicon/capidtmf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/capidtmf.c 2011-11-12 12:47:13.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/hardware/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_state, byte *buffer, word leng byte goertzel_result_buffer[CAPIDTMF_RECV_TOTAL_FREQUENCY_COUNT]; short windowed_sample_buffer[CAPIDTMF_RECV_WINDOWED_SAMPLES]; @@ -29126,9 +29866,10 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/capidtmf.c linux-3.0.9/driver if (p_state->recv.state & CAPIDTMF_RECV_STATE_DTMF_ACTIVE) { -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/capifunc.c linux-3.0.9/drivers/isdn/hardware/eicon/capifunc.c ---- linux-3.0.9/drivers/isdn/hardware/eicon/capifunc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/capifunc.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/capifunc.c b/drivers/isdn/hardware/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]; @@ -29138,10 +29879,11 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/capifunc.c linux-3.0.9/driver DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); for (x = 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/diddfunc.c linux-3.0.9/drivers/isdn/hardware/eicon/diddfunc.c ---- linux-3.0.9/drivers/isdn/hardware/eicon/diddfunc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/diddfunc.c 2011-11-12 12:47:13.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/hardware/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]; @@ -29150,10 +29892,11 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/diddfunc.c linux-3.0.9/driver DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); for (x = 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/divasfunc.c linux-3.0.9/drivers/isdn/hardware/eicon/divasfunc.c ---- linux-3.0.9/drivers/isdn/hardware/eicon/divasfunc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/divasfunc.c 2011-11-12 12:47:13.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/hardware/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]; @@ -29162,9 +29905,10 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/divasfunc.c linux-3.0.9/drive DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); for (x = 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/divasync.h linux-3.0.9/drivers/isdn/hardware/eicon/divasync.h ---- linux-3.0.9/drivers/isdn/hardware/eicon/divasync.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/divasync.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/divasync.h b/drivers/isdn/hardware/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 { @@ -29174,10 +29918,11 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/divasync.h linux-3.0.9/driver typedef struct _diva_didd_read_adapter_array { void * buffer; dword length; -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/idifunc.c linux-3.0.9/drivers/isdn/hardware/eicon/idifunc.c ---- linux-3.0.9/drivers/isdn/hardware/eicon/idifunc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/idifunc.c 2011-11-12 12:47:13.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/hardware/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]; @@ -29186,9 +29931,10 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/idifunc.c linux-3.0.9/drivers DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); for (x = 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/message.c linux-3.0.9/drivers/isdn/hardware/eicon/message.c ---- linux-3.0.9/drivers/isdn/hardware/eicon/message.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/message.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/message.c b/drivers/isdn/hardware/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; @@ -29198,7 +29944,7 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/message.c linux-3.0.9/drivers a = plci->adapter; Id = ((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; @@ -29207,7 +29953,7 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/message.c linux-3.0.9/drivers for(i=0;i<8;i++) bp_parms[i].length = 0; for(i=0;i<2;i++) global_config[i].length = 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[] = {4,3,2,2,6,6,0}; const byte header[] = {0,2,3,3,0,0,0}; @@ -29216,7 +29962,7 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/message.c linux-3.0.9/drivers for(i=0;i<8;i++) bp_parms[i].length = 0; for(i=0;i<6;i++) b2_config_parms[i].length = 0; for(i=0;i<5;i++) b3_config_parms[i].length = 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; @@ -29225,10 +29971,11 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/message.c linux-3.0.9/drivers set_group_ind_mask (plci); /* all APPLs within this inc. call are allowed to dial in */ if(!a->group_optimization_enabled) -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/mntfunc.c linux-3.0.9/drivers/isdn/hardware/eicon/mntfunc.c ---- linux-3.0.9/drivers/isdn/hardware/eicon/mntfunc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/mntfunc.c 2011-11-12 12:47:13.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/hardware/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]; @@ -29237,9 +29984,10 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/mntfunc.c linux-3.0.9/drivers DIVA_DIDD_Read(DIDD_Table, sizeof(DIDD_Table)); for (x = 0; x < MAX_DESCRIPTORS; x++) { -diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/xdi_adapter.h linux-3.0.9/drivers/isdn/hardware/eicon/xdi_adapter.h ---- linux-3.0.9/drivers/isdn/hardware/eicon/xdi_adapter.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/hardware/eicon/xdi_adapter.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/isdn/hardware/eicon/xdi_adapter.h b/drivers/isdn/hardware/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; @@ -29249,10 +29997,11 @@ diff -urNp linux-3.0.9/drivers/isdn/hardware/eicon/xdi_adapter.h linux-3.0.9/dri typedef struct _diva_os_xdi_adapter { struct list_head link; -diff -urNp linux-3.0.9/drivers/isdn/i4l/isdn_common.c linux-3.0.9/drivers/isdn/i4l/isdn_common.c ---- linux-3.0.9/drivers/isdn/i4l/isdn_common.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/i4l/isdn_common.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1286,6 +1286,8 @@ isdn_ioctl(struct file *file, uint cmd, +diff --git a/drivers/isdn/i4l/isdn_common.c b/drivers/isdn/i4l/isdn_common.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 = (void __user *)arg; @@ -29261,10 +30010,11 @@ diff -urNp linux-3.0.9/drivers/isdn/i4l/isdn_common.c linux-3.0.9/drivers/isdn/i #define name iocpar.name #define bname iocpar.bname #define iocts iocpar.iocts -diff -urNp linux-3.0.9/drivers/isdn/icn/icn.c linux-3.0.9/drivers/isdn/icn/icn.c ---- linux-3.0.9/drivers/isdn/icn/icn.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/isdn/icn/icn.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = len; if (user) { @@ -29273,9 +30023,10 @@ diff -urNp linux-3.0.9/drivers/isdn/icn/icn.c linux-3.0.9/drivers/isdn/icn/icn.c return -EFAULT; } else memcpy(msg, buf, count); -diff -urNp linux-3.0.9/drivers/lguest/core.c linux-3.0.9/drivers/lguest/core.c ---- linux-3.0.9/drivers/lguest/core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/lguest/core.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/lguest/core.c b/drivers/lguest/core.c +index efa2024..2e18d14 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. @@ -29303,9 +30054,10 @@ diff -urNp linux-3.0.9/drivers/lguest/core.c linux-3.0.9/drivers/lguest/core.c end_switcher_text - start_switcher_text); printk(KERN_INFO "lguest: mapped switcher at %p\n", -diff -urNp linux-3.0.9/drivers/lguest/x86/core.c linux-3.0.9/drivers/lguest/x86/core.c ---- linux-3.0.9/drivers/lguest/x86/core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/lguest/x86/core.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/lguest/x86/core.c b/drivers/lguest/x86/core.c +index 9f1659c..5352032 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) @@ -29315,7 +30067,7 @@ diff -urNp linux-3.0.9/drivers/lguest/x86/core.c linux-3.0.9/drivers/lguest/x86/ } /* 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. */ @@ -29347,9 +30099,10 @@ diff -urNp linux-3.0.9/drivers/lguest/x86/core.c linux-3.0.9/drivers/lguest/x86/ lguest_entry.segment = LGUEST_CS; /* -diff -urNp linux-3.0.9/drivers/lguest/x86/switcher_32.S linux-3.0.9/drivers/lguest/x86/switcher_32.S ---- linux-3.0.9/drivers/lguest/x86/switcher_32.S 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/lguest/x86/switcher_32.S 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/lguest/x86/switcher_32.S b/drivers/lguest/x86/switcher_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 <asm/page.h> #include <asm/segment.h> @@ -29408,10 +30161,11 @@ diff -urNp linux-3.0.9/drivers/lguest/x86/switcher_32.S linux-3.0.9/drivers/lgue // Every interrupt can come to us here // But we must truly tell each apart. -diff -urNp linux-3.0.9/drivers/macintosh/macio_asic.c linux-3.0.9/drivers/macintosh/macio_asic.c ---- linux-3.0.9/drivers/macintosh/macio_asic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/macintosh/macio_asic.c 2011-11-12 12:47:13.000000000 -0500 -@@ -748,7 +748,7 @@ static void __devexit macio_pci_remove(s +diff --git a/drivers/macintosh/macio_asic.c b/drivers/macintosh/macio_asic.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_dev* pdev) * MacIO is matched against any Apple ID, it's probe() function * will then decide wether it applies or not */ @@ -29420,67 +30174,11 @@ diff -urNp linux-3.0.9/drivers/macintosh/macio_asic.c linux-3.0.9/drivers/macint .vendor = PCI_VENDOR_ID_APPLE, .device = PCI_ANY_ID, .subvendor = PCI_ANY_ID, -diff -urNp linux-3.0.9/drivers/md/dm.c linux-3.0.9/drivers/md/dm.c ---- linux-3.0.9/drivers/md/dm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/dm.c 2011-11-12 12:47:13.000000000 -0500 -@@ -164,9 +164,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 */ - -@@ -1842,8 +1842,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); - -@@ -1977,7 +1977,7 @@ static void event_callback(void *context - - dm_send_uevents(&uevents, &disk_to_dev(md->disk)->kobj); - -- atomic_inc(&md->event_nr); -+ atomic_inc_unchecked(&md->event_nr); - wake_up(&md->eventq); - } - -@@ -2553,18 +2553,18 @@ int dm_kobject_uevent(struct mapped_devi - - 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); - } - - uint32_t dm_get_event_nr(struct mapped_device *md) - { -- return atomic_read(&md->event_nr); -+ return atomic_read_unchecked(&md->event_nr); - } - - int dm_wait_event(struct mapped_device *md, int event_nr) - { - return wait_event_interruptible(md->eventq, -- (event_nr != atomic_read(&md->event_nr))); -+ (event_nr != atomic_read_unchecked(&md->event_nr))); - } - - void dm_uevent_add(struct mapped_device *md, struct list_head *elist) -diff -urNp linux-3.0.9/drivers/md/dm-ioctl.c linux-3.0.9/drivers/md/dm-ioctl.c ---- linux-3.0.9/drivers/md/dm-ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/dm-ioctl.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1551,7 +1551,7 @@ static int validate_params(uint cmd, str +diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c +index 4cacdad..9b5929d 100644 +--- a/drivers/md/dm-ioctl.c ++++ b/drivers/md/dm-ioctl.c +@@ -1551,7 +1551,7 @@ static int validate_params(uint cmd, struct dm_ioctl *param) cmd == DM_LIST_VERSIONS_CMD) return 0; @@ -29489,9 +30187,10 @@ diff -urNp linux-3.0.9/drivers/md/dm-ioctl.c linux-3.0.9/drivers/md/dm-ioctl.c if (!*param->name) { DMWARN("name not supplied when creating device"); return -EINVAL; -diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/drivers/md/dm-raid1.c ---- linux-3.0.9/drivers/md/dm-raid1.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/dm-raid1.c 2011-11-12 12:47:13.000000000 -0500 +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 { struct mirror { @@ -29501,7 +30200,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/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; for (m = ms->mirror; m < ms->mirror + ms->nr_mirrors; m++) @@ -29510,7 +30209,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/drivers/md/dm-raid1.c return m; 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_raid1_error error_type) * simple way to tell if a device has encountered * errors. */ @@ -29519,7 +30218,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/drivers/md/dm-raid1.c 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_set *ms, sector_t sector) struct mirror *m = get_default_mirror(ms); do { @@ -29537,7 +30236,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/drivers/md/dm-raid1.c } 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 bio_list *reads) */ if (likely(region_in_sync(ms, region, 1))) m = choose_mirror(ms, bio->bi_sector); @@ -29546,7 +30245,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/drivers/md/dm-raid1.c m = NULL; if (likely(m)) -@@ -937,7 +937,7 @@ static int get_mirror(struct mirror_set +@@ -937,7 +937,7 @@ static int get_mirror(struct mirror_set *ms, struct dm_target *ti, } ms->mirror[mirror].ms = ms; @@ -29555,7 +30254,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/drivers/md/dm-raid1.c ms->mirror[mirror].error_type = 0; ms->mirror[mirror].offset = offset; -@@ -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) { @@ -29564,9 +30263,10 @@ diff -urNp linux-3.0.9/drivers/md/dm-raid1.c linux-3.0.9/drivers/md/dm-raid1.c return 'A'; return (test_bit(DM_RAID1_FLUSH_ERROR, &(m->error_type))) ? 'F' : -diff -urNp linux-3.0.9/drivers/md/dm-stripe.c linux-3.0.9/drivers/md/dm-stripe.c ---- linux-3.0.9/drivers/md/dm-stripe.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/dm-stripe.c 2011-11-12 12:47:13.000000000 -0500 +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; @@ -29576,7 +30276,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-stripe.c linux-3.0.9/drivers/md/dm-stripe.c }; 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; } @@ -29585,7 +30285,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-stripe.c linux-3.0.9/drivers/md/dm-stripe.c } ti->private = 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 = 0; i < sc->stripes; i++) { DMEMIT("%s ", sc->stripe[i].dev->name); @@ -29594,7 +30294,7 @@ diff -urNp linux-3.0.9/drivers/md/dm-stripe.c linux-3.0.9/drivers/md/dm-stripe.c 'D' : 'A'; } buffer[i] = '\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, struct bio *bio, */ for (i = 0; i < sc->stripes; i++) if (!strcmp(sc->stripe[i].dev->name, major_minor)) { @@ -29605,10 +30305,11 @@ diff -urNp linux-3.0.9/drivers/md/dm-stripe.c linux-3.0.9/drivers/md/dm-stripe.c DM_IO_ERROR_THRESHOLD) schedule_work(&sc->trigger_event); } -diff -urNp linux-3.0.9/drivers/md/dm-table.c linux-3.0.9/drivers/md/dm-table.c ---- linux-3.0.9/drivers/md/dm-table.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/dm-table.c 2011-11-12 12:47:13.000000000 -0500 -@@ -390,7 +390,7 @@ static int device_area_is_invalid(struct +diff --git a/drivers/md/dm-table.c b/drivers/md/dm-table.c +index ebdae6e..cc57e52 100644 +--- a/drivers/md/dm-table.c ++++ b/drivers/md/dm-table.c +@@ -390,7 +390,7 @@ static int device_area_is_invalid(struct dm_target *ti, struct dm_dev *dev, if (!dev_size) return 0; @@ -29617,9 +30318,68 @@ diff -urNp linux-3.0.9/drivers/md/dm-table.c linux-3.0.9/drivers/md/dm-table.c DMWARN("%s: %s too small for target: " "start=%llu, len=%llu, dev_size=%llu", dm_device_name(ti->table->md), bdevname(bdev, b), -diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c ---- linux-3.0.9/drivers/md/md.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/md.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/md/dm.c b/drivers/md/dm.c +index 41abc6d..1c6194f 100644 +--- a/drivers/md/dm.c ++++ b/drivers/md/dm.c +@@ -164,9 +164,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 */ + +@@ -1842,8 +1842,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); + +@@ -1977,7 +1977,7 @@ static void event_callback(void *context) + + dm_send_uevents(&uevents, &disk_to_dev(md->disk)->kobj); + +- atomic_inc(&md->event_nr); ++ atomic_inc_unchecked(&md->event_nr); + wake_up(&md->eventq); + } + +@@ -2553,18 +2553,18 @@ int dm_kobject_uevent(struct mapped_device *md, enum kobject_action action, + + 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); + } + + uint32_t dm_get_event_nr(struct mapped_device *md) + { +- return atomic_read(&md->event_nr); ++ return atomic_read_unchecked(&md->event_nr); + } + + int dm_wait_event(struct mapped_device *md, int event_nr) + { + return wait_event_interruptible(md->eventq, +- (event_nr != atomic_read(&md->event_nr))); ++ (event_nr != atomic_read_unchecked(&md->event_nr))); + } + + 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 bc83428..f605840 100644 +--- a/drivers/md/md.c ++++ b/drivers/md/md.c @@ -231,10 +231,10 @@ EXPORT_SYMBOL_GPL(bio_clone_mddev); * start build, activate spare */ @@ -29642,7 +30402,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c wake_up(&md_event_waiters); } -@@ -1475,7 +1475,7 @@ static int super_1_load(mdk_rdev_t *rdev +@@ -1475,7 +1475,7 @@ static int super_1_load(mdk_rdev_t *rdev, mdk_rdev_t *refdev, int minor_version) rdev->preferred_minor = 0xffff; rdev->data_offset = le64_to_cpu(sb->data_offset); @@ -29651,7 +30411,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c rdev->sb_size = le32_to_cpu(sb->max_dev) * 2 + 256; bmask = queue_logical_block_size(rdev->bdev->bd_disk->queue)-1; -@@ -1653,7 +1653,7 @@ static void super_1_sync(mddev_t *mddev, +@@ -1653,7 +1653,7 @@ static void super_1_sync(mddev_t *mddev, mdk_rdev_t *rdev) else sb->resync_offset = cpu_to_le64(0); @@ -29660,7 +30420,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c sb->raid_disks = cpu_to_le32(mddev->raid_disks); sb->size = cpu_to_le64(mddev->dev_sectors); -@@ -2446,7 +2446,7 @@ __ATTR(state, S_IRUGO|S_IWUSR, state_sho +@@ -2446,7 +2446,7 @@ __ATTR(state, S_IRUGO|S_IWUSR, state_show, state_store); static ssize_t errors_show(mdk_rdev_t *rdev, char *page) { @@ -29669,7 +30429,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c } static ssize_t -@@ -2455,7 +2455,7 @@ errors_store(mdk_rdev_t *rdev, const cha +@@ -2455,7 +2455,7 @@ errors_store(mdk_rdev_t *rdev, const char *buf, size_t len) char *e; unsigned long n = simple_strtoul(buf, &e, 10); if (*buf && (*e == 0 || *e == '\n')) { @@ -29689,7 +30449,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c INIT_LIST_HEAD(&rdev->same_set); init_waitqueue_head(&rdev->blocked_wait); -@@ -6440,7 +6440,7 @@ static int md_seq_show(struct seq_file * +@@ -6440,7 +6440,7 @@ static int md_seq_show(struct seq_file *seq, void *v) spin_unlock(&pers_lock); seq_printf(seq, "\n"); @@ -29698,7 +30458,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c return 0; } if (v == (void*)2) { -@@ -6529,7 +6529,7 @@ static int md_seq_show(struct seq_file * +@@ -6529,7 +6529,7 @@ static int md_seq_show(struct seq_file *seq, void *v) chunk_kb ? "KB" : "B"); if (bitmap->file) { seq_printf(seq, ", file: "); @@ -29707,7 +30467,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c } seq_printf(seq, "\n"); -@@ -6563,7 +6563,7 @@ static int md_seq_open(struct inode *ino +@@ -6563,7 +6563,7 @@ static int md_seq_open(struct inode *inode, struct file *file) else { struct seq_file *p = file->private_data; p->private = mi; @@ -29716,7 +30476,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c } return error; } -@@ -6579,7 +6579,7 @@ static unsigned int mdstat_poll(struct f +@@ -6579,7 +6579,7 @@ static unsigned int mdstat_poll(struct file *filp, poll_table *wait) /* always allow read */ mask = POLLIN | POLLRDNORM; @@ -29725,7 +30485,7 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/drivers/md/md.c mask |= POLLERR | POLLPRI; return mask; } -@@ -6623,7 +6623,7 @@ static int is_mddev_idle(mddev_t *mddev, +@@ -6623,7 +6623,7 @@ static int is_mddev_idle(mddev_t *mddev, int init) struct gendisk *disk = rdev->bdev->bd_contains->bd_disk; curr_events = (int)part_stat_read(&disk->part0, sectors[0]) + (int)part_stat_read(&disk->part0, sectors[1]) - @@ -29734,9 +30494,10 @@ diff -urNp linux-3.0.9/drivers/md/md.c linux-3.0.9/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.0.9/drivers/md/md.h linux-3.0.9/drivers/md/md.h ---- linux-3.0.9/drivers/md/md.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/md.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/md/md.h b/drivers/md/md.h +index ce4e328..93770e9 100644 +--- a/drivers/md/md.h ++++ b/drivers/md/md.h @@ -97,13 +97,13 @@ struct mdk_rdev_s * only maintained for arrays that * support hot removal @@ -29753,7 +30514,7 @@ diff -urNp linux-3.0.9/drivers/md/md.h linux-3.0.9/drivers/md/md.h * for reporting to userspace and storing * in superblock. */ -@@ -344,7 +344,7 @@ static inline void rdev_dec_pending(mdk_ +@@ -344,7 +344,7 @@ static inline void rdev_dec_pending(mdk_rdev_t *rdev, mddev_t *mddev) static inline void md_sync_acct(struct block_device *bdev, unsigned long nr_sectors) { @@ -29762,10 +30523,33 @@ diff -urNp linux-3.0.9/drivers/md/md.h linux-3.0.9/drivers/md/md.h } struct mdk_personality -diff -urNp linux-3.0.9/drivers/md/raid10.c linux-3.0.9/drivers/md/raid10.c ---- linux-3.0.9/drivers/md/raid10.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/raid10.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1186,7 +1186,7 @@ static void end_sync_read(struct bio *bi +diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c +index 3a9e59f..6ffbdd3 100644 +--- a/drivers/md/raid1.c ++++ b/drivers/md/raid1.c +@@ -1263,7 +1263,7 @@ static int fix_sync_read_error(r1bio_t *r1_bio) + rdev_dec_pending(rdev, mddev); + md_error(mddev, rdev); + } else +- atomic_add(s, &rdev->corrected_errors); ++ atomic_add_unchecked(s, &rdev->corrected_errors); + } + d = start; + while (d != r1_bio->read_disk) { +@@ -1492,7 +1492,7 @@ static void fix_read_error(conf_t *conf, int read_disk, + /* Well, this device is dead */ + md_error(mddev, rdev); + else { +- 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 17cb6ab..f448b35 100644 +--- a/drivers/md/raid10.c ++++ b/drivers/md/raid10.c +@@ -1186,7 +1186,7 @@ static void end_sync_read(struct bio *bio, int error) if (test_bit(BIO_UPTODATE, &bio->bi_flags)) set_bit(R10BIO_Uptodate, &r10_bio->state); else { @@ -29774,7 +30558,7 @@ diff -urNp linux-3.0.9/drivers/md/raid10.c linux-3.0.9/drivers/md/raid10.c &conf->mirrors[d].rdev->corrected_errors); if (!test_bit(MD_RECOVERY_SYNC, &conf->mddev->recovery)) md_error(r10_bio->mddev, -@@ -1394,7 +1394,7 @@ static void check_decay_read_errors(mdde +@@ -1394,7 +1394,7 @@ static void check_decay_read_errors(mddev_t *mddev, mdk_rdev_t *rdev) { struct timespec cur_time_mon; unsigned long hours_since_last; @@ -29783,7 +30567,7 @@ diff -urNp linux-3.0.9/drivers/md/raid10.c linux-3.0.9/drivers/md/raid10.c ktime_get_ts(&cur_time_mon); -@@ -1416,9 +1416,9 @@ static void check_decay_read_errors(mdde +@@ -1416,9 +1416,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 >= 8 * sizeof(read_errors)) @@ -29795,7 +30579,7 @@ diff -urNp linux-3.0.9/drivers/md/raid10.c linux-3.0.9/drivers/md/raid10.c } /* -@@ -1448,8 +1448,8 @@ static void fix_read_error(conf_t *conf, +@@ -1448,8 +1448,8 @@ static void fix_read_error(conf_t *conf, mddev_t *mddev, r10bio_t *r10_bio) return; check_decay_read_errors(mddev, rdev); @@ -29806,7 +30590,7 @@ diff -urNp linux-3.0.9/drivers/md/raid10.c linux-3.0.9/drivers/md/raid10.c char b[BDEVNAME_SIZE]; bdevname(rdev->bdev, b); -@@ -1457,7 +1457,7 @@ static void fix_read_error(conf_t *conf, +@@ -1457,7 +1457,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, @@ -29815,7 +30599,7 @@ diff -urNp linux-3.0.9/drivers/md/raid10.c linux-3.0.9/drivers/md/raid10.c printk(KERN_NOTICE "md/raid10:%s: %s: Failing raid device\n", mdname(mddev), b); -@@ -1520,7 +1520,7 @@ static void fix_read_error(conf_t *conf, +@@ -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(); @@ -29824,31 +30608,11 @@ diff -urNp linux-3.0.9/drivers/md/raid10.c linux-3.0.9/drivers/md/raid10.c if (sync_page_io(rdev, r10_bio->devs[sl].addr + sect, -diff -urNp linux-3.0.9/drivers/md/raid1.c linux-3.0.9/drivers/md/raid1.c ---- linux-3.0.9/drivers/md/raid1.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/raid1.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1263,7 +1263,7 @@ static int fix_sync_read_error(r1bio_t * - rdev_dec_pending(rdev, mddev); - md_error(mddev, rdev); - } else -- atomic_add(s, &rdev->corrected_errors); -+ atomic_add_unchecked(s, &rdev->corrected_errors); - } - d = start; - while (d != r1_bio->read_disk) { -@@ -1492,7 +1492,7 @@ static void fix_read_error(conf_t *conf, - /* Well, this device is dead */ - md_error(mddev, rdev); - else { -- 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.0.9/drivers/md/raid5.c linux-3.0.9/drivers/md/raid5.c ---- linux-3.0.9/drivers/md/raid5.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/md/raid5.c 2011-11-12 12:47:13.000000000 -0500 -@@ -550,7 +550,7 @@ static void ops_run_io(struct stripe_hea +diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c +index cbb50d3..6e20094 100644 +--- a/drivers/md/raid5.c ++++ b/drivers/md/raid5.c +@@ -550,7 +550,7 @@ static void ops_run_io(struct stripe_head *sh, struct stripe_head_state *s) bi->bi_next = NULL; if ((rw & WRITE) && test_bit(R5_ReWrite, &sh->dev[i].flags)) @@ -29857,7 +30621,7 @@ diff -urNp linux-3.0.9/drivers/md/raid5.c linux-3.0.9/drivers/md/raid5.c &rdev->corrected_errors); generic_make_request(bi); } else { -@@ -1596,15 +1596,15 @@ static void raid5_end_read_request(struc +@@ -1596,15 +1596,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); } @@ -29876,7 +30640,7 @@ diff -urNp linux-3.0.9/drivers/md/raid5.c linux-3.0.9/drivers/md/raid5.c if (conf->mddev->degraded >= conf->max_degraded) printk_rl(KERN_WARNING "md/raid:%s: read error not correctable " -@@ -1622,7 +1622,7 @@ static void raid5_end_read_request(struc +@@ -1622,7 +1622,7 @@ static void raid5_end_read_request(struct bio * bi, int error) (unsigned long long)(sh->sector + rdev->data_offset), bdn); @@ -29885,7 +30649,7 @@ diff -urNp linux-3.0.9/drivers/md/raid5.c linux-3.0.9/drivers/md/raid5.c > conf->max_nr_stripes) printk(KERN_WARNING "md/raid:%s: Too many read errors, failing device %s.\n", -@@ -1945,6 +1945,7 @@ static sector_t compute_blocknr(struct s +@@ -1945,6 +1945,7 @@ static sector_t compute_blocknr(struct stripe_head *sh, int i, int previous) sector_t r_sector; struct stripe_head sh2; @@ -29893,10 +30657,11 @@ diff -urNp linux-3.0.9/drivers/md/raid5.c linux-3.0.9/drivers/md/raid5.c chunk_offset = sector_div(new_sector, sectors_per_chunk); stripe = new_sector; -diff -urNp linux-3.0.9/drivers/media/common/saa7146_hlp.c linux-3.0.9/drivers/media/common/saa7146_hlp.c ---- linux-3.0.9/drivers/media/common/saa7146_hlp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/common/saa7146_hlp.c 2011-11-12 12:47:13.000000000 -0500 -@@ -353,6 +353,8 @@ static void calculate_clipping_registers +diff --git a/drivers/media/common/saa7146_hlp.c b/drivers/media/common/saa7146_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 int x[32], y[32], w[32], h[32]; @@ -29905,10 +30670,11 @@ diff -urNp linux-3.0.9/drivers/media/common/saa7146_hlp.c linux-3.0.9/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.0.9/drivers/media/dvb/dvb-core/dvb_ca_en50221.c linux-3.0.9/drivers/media/dvb/dvb-core/dvb_ca_en50221.c ---- linux-3.0.9/drivers/media/dvb/dvb-core/dvb_ca_en50221.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-core/dvb_ca_en50221.c 2011-11-12 12:47:13.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_private *ca, int slot, u8 * eb u8 buf[HOST_LINK_BUF_SIZE]; int i; @@ -29917,7 +30683,7 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-core/dvb_ca_en50221.c linux-3.0.9/d dprintk("%s\n", __func__); /* 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; @@ -29926,9 +30692,10 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-core/dvb_ca_en50221.c linux-3.0.9/d dprintk("%s\n", __func__); /* Incoming packet has a 2 byte header. hdr[0] = slot_id, hdr[1] = connection_id */ -diff -urNp linux-3.0.9/drivers/media/dvb/dvb-core/dvb_demux.h linux-3.0.9/drivers/media/dvb/dvb-core/dvb_demux.h ---- linux-3.0.9/drivers/media/dvb/dvb-core/dvb_demux.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-core/dvb_demux.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/media/dvb/dvb-core/dvb_demux.h b/drivers/media/dvb/dvb-core/dvb_demux.h +index a7d876f..8fee34d 100644 +--- a/drivers/media/dvb/dvb-core/dvb_demux.h ++++ b/drivers/media/dvb/dvb-core/dvb_demux.h @@ -68,12 +68,12 @@ struct dvb_demux_feed { union { struct dmx_ts_feed ts; @@ -29944,10 +30711,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-core/dvb_demux.h linux-3.0.9/driver struct dvb_demux *demux; void *priv; -diff -urNp linux-3.0.9/drivers/media/dvb/dvb-core/dvbdev.c linux-3.0.9/drivers/media/dvb/dvb-core/dvbdev.c ---- linux-3.0.9/drivers/media/dvb/dvb-core/dvbdev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-core/dvbdev.c 2011-11-12 12:47:13.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, struct dvb_device **pdvbdev, const struct dvb_device *template, void *priv, int type) { struct dvb_device *dvbdev; @@ -29956,10 +30724,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-core/dvbdev.c linux-3.0.9/drivers/m struct device *clsdev; int minor; int id; -diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/cxusb.c linux-3.0.9/drivers/media/dvb/dvb-usb/cxusb.c ---- linux-3.0.9/drivers/media/dvb/dvb-usb/cxusb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-usb/cxusb.c 2011-11-12 12:47:13.000000000 -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-usb/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_config = { struct dib0700_adapter_state { int (*set_param_save) (struct dvb_frontend *, struct dvb_frontend_parameters *); @@ -29968,10 +30737,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/cxusb.c linux-3.0.9/drivers/med static int dib7070_set_param_override(struct dvb_frontend *fe, struct dvb_frontend_parameters *fep) -diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/dib0700_core.c linux-3.0.9/drivers/media/dvb/dvb-usb/dib0700_core.c ---- linux-3.0.9/drivers/media/dvb/dvb-usb/dib0700_core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-usb/dib0700_core.c 2011-11-12 12:47:13.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/dvb/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 *udev, const struct firmware *fw if (!buf) return -ENOMEM; @@ -29980,9 +30750,10 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/dib0700_core.c linux-3.0.9/driv while ((ret = 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.0.9/drivers/media/dvb/dvb-usb/dibusb.h linux-3.0.9/drivers/media/dvb/dvb-usb/dibusb.h ---- linux-3.0.9/drivers/media/dvb/dvb-usb/dibusb.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-usb/dibusb.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/media/dvb/dvb-usb/dibusb.h b/drivers/media/dvb/dvb-usb/dibusb.h +index e47c321..b18237b 100644 +--- a/drivers/media/dvb/dvb-usb/dibusb.h ++++ b/drivers/media/dvb/dvb-usb/dibusb.h @@ -97,7 +97,7 @@ #define DIBUSB_IOCTL_CMD_DISABLE_STREAM 0x02 @@ -29992,9 +30763,10 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/dibusb.h linux-3.0.9/drivers/me int mt2060_present; u8 tuner_addr; }; -diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/dw2102.c linux-3.0.9/drivers/media/dvb/dvb-usb/dw2102.c ---- linux-3.0.9/drivers/media/dvb/dvb-usb/dw2102.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-usb/dw2102.c 2011-11-12 12:47:13.000000000 -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 { struct s6x0_state { @@ -30004,10 +30776,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/dw2102.c linux-3.0.9/drivers/me /* debug */ static int dvb_usb_dw2102_debug; -diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/lmedm04.c linux-3.0.9/drivers/media/dvb/dvb-usb/lmedm04.c ---- linux-3.0.9/drivers/media/dvb/dvb-usb/lmedm04.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/dvb-usb/lmedm04.c 2011-11-12 12:47:13.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_device *dev, usb_control_msg(dev, usb_rcvctrlpipe(dev, 0), 0x06, 0x80, 0x0200, 0x00, data, 0x0109, 1000); @@ -30015,7 +30788,7 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/lmedm04.c linux-3.0.9/drivers/m data[0] = 0x8a; len_in = 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 = 0, len_in; u8 data[512] = {0}; @@ -30024,9 +30797,10 @@ diff -urNp linux-3.0.9/drivers/media/dvb/dvb-usb/lmedm04.c linux-3.0.9/drivers/m data[0] = 0x0a; len_in = 1; info("FRM Firmware Cold Reset"); -diff -urNp linux-3.0.9/drivers/media/dvb/frontends/dib3000.h linux-3.0.9/drivers/media/dvb/frontends/dib3000.h ---- linux-3.0.9/drivers/media/dvb/frontends/dib3000.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/frontends/dib3000.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/media/dvb/frontends/dib3000.h b/drivers/media/dvb/frontends/dib3000.h +index ba91735..547ac27 100644 +--- a/drivers/media/dvb/frontends/dib3000.h ++++ b/drivers/media/dvb/frontends/dib3000.h @@ -40,10 +40,11 @@ struct dib_fe_xfer_ops int (*pid_ctrl)(struct dvb_frontend *fe, int index, int pid, int onoff); int (*tuner_pass_ctrl)(struct dvb_frontend *fe, int onoff, u8 pll_ctrl); @@ -30040,10 +30814,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/frontends/dib3000.h linux-3.0.9/drivers #else static inline struct dvb_frontend* dib3000mb_attach(const struct dib3000_config* config, struct i2c_adapter* i2c, struct dib_fe_xfer_ops *xfer_ops) -diff -urNp linux-3.0.9/drivers/media/dvb/frontends/dib3000mb.c linux-3.0.9/drivers/media/dvb/frontends/dib3000mb.c ---- linux-3.0.9/drivers/media/dvb/frontends/dib3000mb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/frontends/dib3000mb.c 2011-11-12 12:47:13.000000000 -0500 -@@ -756,7 +756,7 @@ static int dib3000mb_tuner_pass_ctrl(str +diff --git a/drivers/media/dvb/frontends/dib3000mb.c b/drivers/media/dvb/frontends/dib3000mb.c +index e80c597..0fd3f2c 100644 +--- a/drivers/media/dvb/frontends/dib3000mb.c ++++ b/drivers/media/dvb/frontends/dib3000mb.c +@@ -756,7 +756,7 @@ static int dib3000mb_tuner_pass_ctrl(struct dvb_frontend *fe, int onoff, u8 pll_ static struct dvb_frontend_ops dib3000mb_ops; struct dvb_frontend* dib3000mb_attach(const struct dib3000_config* config, @@ -30052,10 +30827,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/frontends/dib3000mb.c linux-3.0.9/drive { struct dib3000_state* state = NULL; -diff -urNp linux-3.0.9/drivers/media/dvb/frontends/mb86a16.c linux-3.0.9/drivers/media/dvb/frontends/mb86a16.c ---- linux-3.0.9/drivers/media/dvb/frontends/mb86a16.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/frontends/mb86a16.c 2011-11-12 12:47:13.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/frontends/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 *state) int ret = -1; int sync; @@ -30064,10 +30840,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/frontends/mb86a16.c linux-3.0.9/drivers dprintk(verbose, MB86A16_INFO, 1, "freq=%d Mhz, symbrt=%d Ksps", state->frequency, state->srate); fcp = 3000; -diff -urNp linux-3.0.9/drivers/media/dvb/frontends/or51211.c linux-3.0.9/drivers/media/dvb/frontends/or51211.c ---- linux-3.0.9/drivers/media/dvb/frontends/or51211.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/frontends/or51211.c 2011-11-12 12:47:13.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/frontends/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_frontend* fe, u8 tudata[585]; int i; @@ -30076,10 +30853,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/frontends/or51211.c linux-3.0.9/drivers dprintk("Firmware is %zd bytes\n",fw->size); /* Get eprom data */ -diff -urNp linux-3.0.9/drivers/media/dvb/ngene/ngene-cards.c linux-3.0.9/drivers/media/dvb/ngene/ngene-cards.c ---- linux-3.0.9/drivers/media/dvb/ngene/ngene-cards.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/dvb/ngene/ngene-cards.c 2011-11-12 12:47:13.000000000 -0500 -@@ -379,7 +379,7 @@ static struct ngene_info ngene_info_m780 +diff --git a/drivers/media/dvb/ngene/ngene-cards.c b/drivers/media/dvb/ngene/ngene-cards.c +index fcf4be9..6e5393b 100644 +--- a/drivers/media/dvb/ngene/ngene-cards.c ++++ b/drivers/media/dvb/ngene/ngene-cards.c +@@ -379,7 +379,7 @@ static struct ngene_info ngene_info_m780 = { /****************************************************************************/ @@ -30088,10 +30866,11 @@ diff -urNp linux-3.0.9/drivers/media/dvb/ngene/ngene-cards.c linux-3.0.9/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.0.9/drivers/media/video/cx18/cx18-driver.c linux-3.0.9/drivers/media/video/cx18/cx18-driver.c ---- linux-3.0.9/drivers/media/video/cx18/cx18-driver.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/cx18/cx18-driver.c 2011-11-12 12:47:13.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/video/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 tveeprom *tv) struct i2c_client c; u8 eedata[256]; @@ -30100,10 +30879,11 @@ diff -urNp linux-3.0.9/drivers/media/video/cx18/cx18-driver.c linux-3.0.9/driver memset(&c, 0, sizeof(c)); strlcpy(c.name, "cx18 tveeprom tmp", sizeof(c.name)); c.adapter = &cx->i2c_adap[0]; -diff -urNp linux-3.0.9/drivers/media/video/cx23885/cx23885-input.c linux-3.0.9/drivers/media/video/cx23885/cx23885-input.c ---- linux-3.0.9/drivers/media/video/cx23885/cx23885-input.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/cx23885/cx23885-input.c 2011-11-12 12:47:13.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 e97cafd..33db7bc 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 = false; struct ir_raw_event ir_core_event[64]; @@ -30112,10 +30892,11 @@ diff -urNp linux-3.0.9/drivers/media/video/cx23885/cx23885-input.c linux-3.0.9/d do { num = 0; v4l2_subdev_call(dev->sd_ir, ir, rx_read, (u8 *) ir_core_event, -diff -urNp linux-3.0.9/drivers/media/video/cx88/cx88-alsa.c linux-3.0.9/drivers/media/video/cx88/cx88-alsa.c ---- linux-3.0.9/drivers/media/video/cx88/cx88-alsa.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/cx88/cx88-alsa.c 2011-11-12 12:47:13.000000000 -0500 -@@ -764,7 +764,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 423c1af..1070601 100644 +--- a/drivers/media/video/cx88/cx88-alsa.c ++++ b/drivers/media/video/cx88/cx88-alsa.c +@@ -764,7 +764,7 @@ static struct snd_kcontrol_new snd_cx88_alc_switch = { * Only boards with eeprom and byte 1 at eeprom=1 have it */ @@ -30124,10 +30905,11 @@ diff -urNp linux-3.0.9/drivers/media/video/cx88/cx88-alsa.c linux-3.0.9/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.0.9/drivers/media/video/pvrusb2/pvrusb2-eeprom.c linux-3.0.9/drivers/media/video/pvrusb2/pvrusb2-eeprom.c ---- linux-3.0.9/drivers/media/video/pvrusb2/pvrusb2-eeprom.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/pvrusb2/pvrusb2-eeprom.c 2011-11-12 12:47:13.000000000 -0500 -@@ -120,6 +120,8 @@ int pvr2_eeprom_analyze(struct pvr2_hdw +diff --git a/drivers/media/video/pvrusb2/pvrusb2-eeprom.c b/drivers/media/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; @@ -30136,10 +30918,11 @@ diff -urNp linux-3.0.9/drivers/media/video/pvrusb2/pvrusb2-eeprom.c linux-3.0.9/ memset(&tvdata,0,sizeof(tvdata)); eeprom = pvr2_eeprom_fetch(hdw); -diff -urNp linux-3.0.9/drivers/media/video/saa7134/saa6752hs.c linux-3.0.9/drivers/media/video/saa7134/saa6752hs.c ---- linux-3.0.9/drivers/media/video/saa7134/saa6752hs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/saa7134/saa6752hs.c 2011-11-12 12:47:13.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/video/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, u32 leading_null_bytes) unsigned char localPAT[256]; unsigned char localPMT[256]; @@ -30148,10 +30931,11 @@ diff -urNp linux-3.0.9/drivers/media/video/saa7134/saa6752hs.c linux-3.0.9/drive /* Set video format - must be done first as it resets other settings */ set_reg8(client, 0x41, h->video_format); -diff -urNp linux-3.0.9/drivers/media/video/saa7164/saa7164-cmd.c linux-3.0.9/drivers/media/video/saa7164/saa7164-cmd.c ---- linux-3.0.9/drivers/media/video/saa7164/saa7164-cmd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/saa7164/saa7164-cmd.c 2011-11-12 12:47:13.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/video/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__); @@ -30160,7 +30944,7 @@ diff -urNp linux-3.0.9/drivers/media/video/saa7164/saa7164-cmd.c linux-3.0.9/dri /* While any outstand message on the bus exists... */ do { -@@ -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__); @@ -30169,10 +30953,11 @@ diff -urNp linux-3.0.9/drivers/media/video/saa7164/saa7164-cmd.c linux-3.0.9/dri while (loop) { struct tmComResInfo tRsp = { 0, 0, 0, 0, 0, 0 }; -diff -urNp linux-3.0.9/drivers/media/video/timblogiw.c linux-3.0.9/drivers/media/video/timblogiw.c ---- linux-3.0.9/drivers/media/video/timblogiw.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/timblogiw.c 2011-11-12 12:47:13.000000000 -0500 -@@ -745,7 +745,7 @@ static int timblogiw_mmap(struct file *f +diff --git a/drivers/media/video/timblogiw.c b/drivers/media/video/timblogiw.c +index fc611eb..45ccd26 100644 +--- a/drivers/media/video/timblogiw.c ++++ b/drivers/media/video/timblogiw.c +@@ -745,7 +745,7 @@ static int timblogiw_mmap(struct file *file, struct vm_area_struct *vma) /* Platform device functions */ @@ -30181,10 +30966,11 @@ diff -urNp linux-3.0.9/drivers/media/video/timblogiw.c linux-3.0.9/drivers/media .vidioc_querycap = timblogiw_querycap, .vidioc_enum_fmt_vid_cap = timblogiw_enum_fmt, .vidioc_g_fmt_vid_cap = timblogiw_g_fmt, -diff -urNp linux-3.0.9/drivers/media/video/usbvision/usbvision-core.c linux-3.0.9/drivers/media/video/usbvision/usbvision-core.c ---- linux-3.0.9/drivers/media/video/usbvision/usbvision-core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/usbvision/usbvision-core.c 2011-11-12 12:47:13.000000000 -0500 -@@ -707,6 +707,8 @@ static enum parse_state usbvision_parse_ +diff --git a/drivers/media/video/usbvision/usbvision-core.c b/drivers/media/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(struct usb_usbvision *usbvision unsigned char rv, gv, bv; static unsigned char *Y, *U, *V; @@ -30193,9 +30979,10 @@ diff -urNp linux-3.0.9/drivers/media/video/usbvision/usbvision-core.c linux-3.0. frame = usbvision->cur_frame; image_size = frame->frmwidth * frame->frmheight; if ((frame->v4l2_format.format == V4L2_PIX_FMT_YUV422P) || -diff -urNp linux-3.0.9/drivers/media/video/videobuf-dma-sg.c linux-3.0.9/drivers/media/video/videobuf-dma-sg.c ---- linux-3.0.9/drivers/media/video/videobuf-dma-sg.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/media/video/videobuf-dma-sg.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/media/video/videobuf-dma-sg.c b/drivers/media/video/videobuf-dma-sg.c +index ddb8f4b..35fce12 100644 +--- a/drivers/media/video/videobuf-dma-sg.c ++++ b/drivers/media/video/videobuf-dma-sg.c @@ -606,6 +606,8 @@ void *videobuf_sg_alloc(size_t size) { struct videobuf_queue q; @@ -30205,10 +30992,11 @@ diff -urNp linux-3.0.9/drivers/media/video/videobuf-dma-sg.c linux-3.0.9/drivers /* Required to make generic handler to call __videobuf_alloc */ q.int_ops = &sg_ops; -diff -urNp linux-3.0.9/drivers/message/fusion/mptbase.c linux-3.0.9/drivers/message/fusion/mptbase.c ---- linux-3.0.9/drivers/message/fusion/mptbase.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/message/fusion/mptbase.c 2011-11-12 12:47:13.000000000 -0500 -@@ -6681,8 +6681,13 @@ static int mpt_iocinfo_proc_show(struct +diff --git a/drivers/message/fusion/mptbase.c b/drivers/message/fusion/mptbase.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 = 0x%02x frames\n", ioc->facts.MaxChainDepth); seq_printf(m, " MinBlockSize = 0x%02x bytes\n", 4*ioc->facts.BlockSize); @@ -30222,10 +31010,11 @@ diff -urNp linux-3.0.9/drivers/message/fusion/mptbase.c linux-3.0.9/drivers/mess /* * Rounding UP to nearest 4-kB boundary here... */ -diff -urNp linux-3.0.9/drivers/message/fusion/mptsas.c linux-3.0.9/drivers/message/fusion/mptsas.c ---- linux-3.0.9/drivers/message/fusion/mptsas.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/message/fusion/mptsas.c 2011-11-12 12:47:13.000000000 -0500 -@@ -439,6 +439,23 @@ mptsas_is_end_device(struct mptsas_devin +diff --git a/drivers/message/fusion/mptsas.c b/drivers/message/fusion/mptsas.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 * attached) return 0; } @@ -30249,7 +31038,7 @@ diff -urNp linux-3.0.9/drivers/message/fusion/mptsas.c linux-3.0.9/drivers/messa /* no mutex */ static void mptsas_port_delete(MPT_ADAPTER *ioc, struct mptsas_portinfo_details * port_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; } @@ -30273,9 +31062,10 @@ diff -urNp linux-3.0.9/drivers/message/fusion/mptsas.c linux-3.0.9/drivers/messa static inline struct sas_port * mptsas_get_port(struct mptsas_phyinfo *phy_info) { -diff -urNp linux-3.0.9/drivers/message/fusion/mptscsih.c linux-3.0.9/drivers/message/fusion/mptscsih.c ---- linux-3.0.9/drivers/message/fusion/mptscsih.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/message/fusion/mptscsih.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/message/fusion/mptscsih.c b/drivers/message/fusion/mptscsih.c +index a1d4ee6..341d381 100644 +--- a/drivers/message/fusion/mptscsih.c ++++ b/drivers/message/fusion/mptscsih.c @@ -1268,15 +1268,16 @@ mptscsih_info(struct Scsi_Host *SChost) h = shost_priv(SChost); @@ -30301,10 +31091,11 @@ diff -urNp linux-3.0.9/drivers/message/fusion/mptscsih.c linux-3.0.9/drivers/mes return h->info_kbuf; } -diff -urNp linux-3.0.9/drivers/message/i2o/i2o_config.c linux-3.0.9/drivers/message/i2o/i2o_config.c ---- linux-3.0.9/drivers/message/i2o/i2o_config.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/message/i2o/i2o_config.c 2011-11-12 12:47:13.000000000 -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; @@ -30313,9 +31104,10 @@ diff -urNp linux-3.0.9/drivers/message/i2o/i2o_config.c linux-3.0.9/drivers/mess if (get_user(iop, &cmd->iop) || get_user(user_msg, &cmd->msg)) return -EFAULT; -diff -urNp linux-3.0.9/drivers/message/i2o/i2o_proc.c linux-3.0.9/drivers/message/i2o/i2o_proc.c ---- linux-3.0.9/drivers/message/i2o/i2o_proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/message/i2o/i2o_proc.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/message/i2o/i2o_proc.c b/drivers/message/i2o/i2o_proc.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[] = { "Array Controller Device" }; @@ -30330,7 +31122,7 @@ diff -urNp linux-3.0.9/drivers/message/i2o/i2o_proc.c linux-3.0.9/drivers/messag static int i2o_report_query_status(struct seq_file *seq, int block_status, 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 *seq, void *v) seq_printf(seq, "%-#7x", ddm_table.i2o_vendor_id); seq_printf(seq, "%-#8x", ddm_table.module_id); @@ -30340,7 +31132,7 @@ diff -urNp linux-3.0.9/drivers/message/i2o/i2o_proc.c linux-3.0.9/drivers/messag seq_printf(seq, "%9d ", ddm_table.data_size); seq_printf(seq, "%8d", ddm_table.code_size); -@@ -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_file *seq, void *v) seq_printf(seq, "%-#7x", dst->i2o_vendor_id); seq_printf(seq, "%-#8x", dst->module_id); @@ -30351,7 +31143,7 @@ diff -urNp linux-3.0.9/drivers/message/i2o/i2o_proc.c linux-3.0.9/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]); @@ -30370,7 +31162,7 @@ diff -urNp linux-3.0.9/drivers/message/i2o/i2o_proc.c linux-3.0.9/drivers/messag 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_file *seq, void *v) } seq_printf(seq, "Registering DDM TID : 0x%03x\n", result.ddm_tid); @@ -30383,7 +31175,7 @@ diff -urNp linux-3.0.9/drivers/message/i2o/i2o_proc.c linux-3.0.9/drivers/messag 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 *seq, void *v) return 0; } @@ -30402,10 +31194,11 @@ diff -urNp linux-3.0.9/drivers/message/i2o/i2o_proc.c linux-3.0.9/drivers/messag return 0; } -diff -urNp linux-3.0.9/drivers/message/i2o/iop.c linux-3.0.9/drivers/message/i2o/iop.c ---- linux-3.0.9/drivers/message/i2o/iop.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/message/i2o/iop.c 2011-11-12 12:47:13.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 090d2a3..5f24ef8 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) spin_lock_irqsave(&c->context_list_lock, flags); @@ -30419,7 +31212,7 @@ diff -urNp linux-3.0.9/drivers/message/i2o/iop.c linux-3.0.9/drivers/message/i2o list_add(&entry->list, &c->context_list); -@@ -1077,7 +1077,7 @@ struct i2o_controller *i2o_iop_alloc(voi +@@ -1077,7 +1077,7 @@ struct i2o_controller *i2o_iop_alloc(void) #if BITS_PER_LONG == 64 spin_lock_init(&c->context_list_lock); @@ -30428,9 +31221,10 @@ diff -urNp linux-3.0.9/drivers/message/i2o/iop.c linux-3.0.9/drivers/message/i2o INIT_LIST_HEAD(&c->context_list); #endif -diff -urNp linux-3.0.9/drivers/mfd/ab3100-core.c linux-3.0.9/drivers/mfd/ab3100-core.c ---- linux-3.0.9/drivers/mfd/ab3100-core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mfd/ab3100-core.c 2011-11-12 12:47:13.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; }; @@ -30440,9 +31234,10 @@ diff -urNp linux-3.0.9/drivers/mfd/ab3100-core.c linux-3.0.9/drivers/mfd/ab3100- /* AB3100 */ { .id = 0xc0, -diff -urNp linux-3.0.9/drivers/mfd/abx500-core.c linux-3.0.9/drivers/mfd/abx500-core.c ---- linux-3.0.9/drivers/mfd/abx500-core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mfd/abx500-core.c 2011-11-12 12:47:13.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); struct abx500_device_entry { @@ -30452,9 +31247,10 @@ diff -urNp linux-3.0.9/drivers/mfd/abx500-core.c linux-3.0.9/drivers/mfd/abx500- struct device *dev; }; -diff -urNp linux-3.0.9/drivers/mfd/janz-cmodio.c linux-3.0.9/drivers/mfd/janz-cmodio.c ---- linux-3.0.9/drivers/mfd/janz-cmodio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mfd/janz-cmodio.c 2011-11-12 12:47:13.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 @@ #include <linux/kernel.h> @@ -30463,10 +31259,11 @@ diff -urNp linux-3.0.9/drivers/mfd/janz-cmodio.c linux-3.0.9/drivers/mfd/janz-cm #include <linux/init.h> #include <linux/pci.h> #include <linux/interrupt.h> -diff -urNp linux-3.0.9/drivers/mfd/wm8350-i2c.c linux-3.0.9/drivers/mfd/wm8350-i2c.c ---- linux-3.0.9/drivers/mfd/wm8350-i2c.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mfd/wm8350-i2c.c 2011-11-12 12:47:13.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 *wm8350, char reg, u8 msg[(WM8350_MAX_REGISTER << 1) + 1]; int ret; @@ -30475,10 +31272,11 @@ diff -urNp linux-3.0.9/drivers/mfd/wm8350-i2c.c linux-3.0.9/drivers/mfd/wm8350-i if (bytes > ((WM8350_MAX_REGISTER << 1) + 1)) return -EINVAL; -diff -urNp linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.c linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.c ---- linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.c 2011-11-12 12:47:13.000000000 -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 move * is done. */ @@ -30487,7 +31285,7 @@ diff -urNp linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.c linux-3.0.9/drivers/mi 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); @@ -30496,7 +31294,7 @@ diff -urNp linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.c linux-3.0.9/drivers/mi return 0; } -@@ -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); @@ -30514,9 +31312,10 @@ diff -urNp linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.c linux-3.0.9/drivers/mi return POLLIN | POLLRDNORM; return 0; } -diff -urNp linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.h linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.h ---- linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.h 2011-11-12 12:47:13.000000000 -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 */ @@ -30526,10 +31325,11 @@ diff -urNp linux-3.0.9/drivers/misc/lis3lv02d/lis3lv02d.h linux-3.0.9/drivers/mi union axis_conversion ac; /* hw -> logical axis */ int mapped_btns[3]; -diff -urNp linux-3.0.9/drivers/misc/sgi-gru/gruhandles.c linux-3.0.9/drivers/misc/sgi-gru/gruhandles.c ---- linux-3.0.9/drivers/misc/sgi-gru/gruhandles.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/sgi-gru/gruhandles.c 2011-11-12 12:47:13.000000000 -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/gruhandles.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; nsec = CLKS2NSEC(clks); @@ -30540,9 +31340,10 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-gru/gruhandles.c linux-3.0.9/drivers/mis if (mcs_op_statistics[op].max < nsec) mcs_op_statistics[op].max = nsec; } -diff -urNp linux-3.0.9/drivers/misc/sgi-gru/gruprocfs.c linux-3.0.9/drivers/misc/sgi-gru/gruprocfs.c ---- linux-3.0.9/drivers/misc/sgi-gru/gruprocfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/sgi-gru/gruprocfs.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/misc/sgi-gru/gruprocfs.c b/drivers/misc/sgi-gru/gruprocfs.c +index 7768b87..f8aac38 100644 +--- a/drivers/misc/sgi-gru/gruprocfs.c ++++ b/drivers/misc/sgi-gru/gruprocfs.c @@ -32,9 +32,9 @@ #define printstat(s, f) printstat_val(s, &gru_stats.f, #f) @@ -30555,7 +31356,7 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-gru/gruprocfs.c linux-3.0.9/drivers/misc 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, void *p) seq_printf(s, "%-20s%12s%12s%12s\n", "#id", "count", "aver-clks", "max-clks"); for (op = 0; op < mcsop_last; op++) { @@ -30566,9 +31367,10 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-gru/gruprocfs.c linux-3.0.9/drivers/misc max = 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.0.9/drivers/misc/sgi-gru/grutables.h linux-3.0.9/drivers/misc/sgi-gru/grutables.h ---- linux-3.0.9/drivers/misc/sgi-gru/grutables.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/sgi-gru/grutables.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/misc/sgi-gru/grutables.h b/drivers/misc/sgi-gru/grutables.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. */ @@ -30728,7 +31530,7 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-gru/grutables.h linux-3.0.9/drivers/misc }; -@@ -251,8 +251,8 @@ enum mcs_op {cchop_allocate, cchop_start +@@ -251,8 +251,8 @@ enum mcs_op {cchop_allocate, cchop_start, cchop_interrupt, cchop_interrupt_sync, tghop_invalidate, mcsop_last}; struct mcs_op_statistic { @@ -30739,7 +31541,7 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-gru/grutables.h linux-3.0.9/drivers/misc unsigned long max; }; -@@ -275,7 +275,7 @@ extern struct mcs_op_statistic mcs_op_st +@@ -275,7 +275,7 @@ extern struct mcs_op_statistic mcs_op_statistics[mcsop_last]; #define STAT(id) do { \ if (gru_options & OPT_STATS) \ @@ -30748,9 +31550,23 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-gru/grutables.h linux-3.0.9/drivers/misc } while (0) #ifdef CONFIG_SGI_GRU_DEBUG -diff -urNp linux-3.0.9/drivers/misc/sgi-xp/xpc.h linux-3.0.9/drivers/misc/sgi-xp/xpc.h ---- linux-3.0.9/drivers/misc/sgi-xp/xpc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/sgi-xp/xpc.h 2011-11-12 12:47:13.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; + + extern struct xpc_interface xpc_interface; + +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 *); @@ -30759,7 +31575,7 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-xp/xpc.h linux-3.0.9/drivers/misc/sgi-xp /* struct xpc_partition act_state values (for XPC HB) */ -@@ -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; @@ -30768,10 +31584,11 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-xp/xpc.h linux-3.0.9/drivers/misc/sgi-xp extern int xpc_disengage_timelimit; extern int xpc_disengage_timedout; extern int xpc_activate_IRQ_rcvd; -diff -urNp linux-3.0.9/drivers/misc/sgi-xp/xpc_main.c linux-3.0.9/drivers/misc/sgi-xp/xpc_main.c ---- linux-3.0.9/drivers/misc/sgi-xp/xpc_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/sgi-xp/xpc_main.c 2011-11-12 12:47:13.000000000 -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_main.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 = { .notifier_call = xpc_system_die, }; @@ -30780,22 +31597,11 @@ diff -urNp linux-3.0.9/drivers/misc/sgi-xp/xpc_main.c linux-3.0.9/drivers/misc/s /* * Timer function to enforce the timelimit on the partition disengage. -diff -urNp linux-3.0.9/drivers/misc/sgi-xp/xp.h linux-3.0.9/drivers/misc/sgi-xp/xp.h ---- linux-3.0.9/drivers/misc/sgi-xp/xp.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/misc/sgi-xp/xp.h 2011-11-12 12:47:13.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; - - extern struct xpc_interface xpc_interface; - -diff -urNp linux-3.0.9/drivers/mmc/host/sdhci-pci.c linux-3.0.9/drivers/mmc/host/sdhci-pci.c ---- linux-3.0.9/drivers/mmc/host/sdhci-pci.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mmc/host/sdhci-pci.c 2011-11-12 12:47:13.000000000 -0500 -@@ -524,7 +524,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 936bbca..8ade4516 100644 +--- a/drivers/mmc/host/sdhci-pci.c ++++ b/drivers/mmc/host/sdhci-pci.c +@@ -524,7 +524,7 @@ static const struct sdhci_pci_fixes sdhci_via = { .probe = via_probe, }; @@ -30804,10 +31610,11 @@ diff -urNp linux-3.0.9/drivers/mmc/host/sdhci-pci.c linux-3.0.9/drivers/mmc/host { .vendor = PCI_VENDOR_ID_RICOH, .device = PCI_DEVICE_ID_RICOH_R5C822, -diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0001.c linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0001.c ---- linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0001.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0001.c 2011-11-12 12:47:13.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 = cfi->cmdset_priv; unsigned long timeo = jiffies + HZ; @@ -30816,7 +31623,7 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0001.c linux-3.0.9/drivers/m /* Prevent setting state FL_SYNCING for chip in suspended state. */ if (mode == FL_SYNCING && chip->oldstate != 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_info *map, struct flchip *chip, unsigned long initial_adr; int initial_len = len; @@ -30825,7 +31632,7 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0001.c linux-3.0.9/drivers/m wbufsize = cfi_interleave(cfi) << cfi->cfiq->MaxBufWriteSize; adr += chip->start; initial_adr = adr; -@@ -1871,6 +1875,8 @@ static int __xipram do_erase_oneblock(st +@@ -1871,6 +1875,8 @@ static int __xipram do_erase_oneblock(struct map_info *map, struct flchip *chip, int retries = 3; int ret; @@ -30834,10 +31641,11 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0001.c linux-3.0.9/drivers/m adr += chip->start; retry: -diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c ---- linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c 2011-11-12 12:47:13.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 *map, struct flchip *chip, lof unsigned long cmd_addr; struct cfi_private *cfi = map->fldrv_priv; @@ -30846,7 +31654,7 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c linux-3.0.9/drivers/m adr += chip->start; /* 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 *map, struct flchip *chip, DECLARE_WAITQUEUE(wait, current); int wbufsize, z; @@ -30855,7 +31663,7 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c linux-3.0.9/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 = 0; @@ -30864,7 +31672,7 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c linux-3.0.9/drivers/m adr += chip->start; /* 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 = jiffies + HZ; DECLARE_WAITQUEUE(wait, current); @@ -30873,7 +31681,7 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c linux-3.0.9/drivers/m adr += chip->start; /* 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_info *map, struct flchip *chip, unsigned long timeo = jiffies + HZ; DECLARE_WAITQUEUE(wait, current); @@ -30882,10 +31690,11 @@ diff -urNp linux-3.0.9/drivers/mtd/chips/cfi_cmdset_0020.c linux-3.0.9/drivers/m adr += chip->start; /* Let's determine this according to the interleave only once */ -diff -urNp linux-3.0.9/drivers/mtd/devices/doc2000.c linux-3.0.9/drivers/mtd/devices/doc2000.c ---- linux-3.0.9/drivers/mtd/devices/doc2000.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/devices/doc2000.c 2011-11-12 12:47:13.000000000 -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, /* The ECC will not be calculated correctly if less than 512 is written */ /* DBB- @@ -30894,10 +31703,11 @@ diff -urNp linux-3.0.9/drivers/mtd/devices/doc2000.c linux-3.0.9/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.0.9/drivers/mtd/devices/doc2001.c linux-3.0.9/drivers/mtd/devices/doc2001.c ---- linux-3.0.9/drivers/mtd/devices/doc2001.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/devices/doc2001.c 2011-11-12 12:47:13.000000000 -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 from, size_t len, struct Nand *mychip = &this->chips[from >> (this->chipshift)]; /* Don't allow read past end of device */ @@ -30906,10 +31716,11 @@ diff -urNp linux-3.0.9/drivers/mtd/devices/doc2001.c linux-3.0.9/drivers/mtd/dev return -EINVAL; /* Don't allow a single read to cross a 512-byte block boundary */ -diff -urNp linux-3.0.9/drivers/mtd/ftl.c linux-3.0.9/drivers/mtd/ftl.c ---- linux-3.0.9/drivers/mtd/ftl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/ftl.c 2011-11-12 12:47:13.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 = cpu_to_le16(srcunit); @@ -30918,10 +31729,11 @@ diff -urNp linux-3.0.9/drivers/mtd/ftl.c linux-3.0.9/drivers/mtd/ftl.c eun = &part->EUNInfo[srcunit]; xfer = &part->XferInfo[xferunit]; DEBUG(2, "ftl_cs: copying block 0x%x to 0x%x\n", -diff -urNp linux-3.0.9/drivers/mtd/inftlcore.c linux-3.0.9/drivers/mtd/inftlcore.c ---- linux-3.0.9/drivers/mtd/inftlcore.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/inftlcore.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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; @@ -30930,10 +31742,11 @@ diff -urNp linux-3.0.9/drivers/mtd/inftlcore.c linux-3.0.9/drivers/mtd/inftlcore DEBUG(MTD_DEBUG_LEVEL3, "INFTL: INFTL_foldchain(inftl=%p,thisVUC=%d," "pending=%d)\n", inftl, thisVUC, pendingblock); -diff -urNp linux-3.0.9/drivers/mtd/inftlmount.c linux-3.0.9/drivers/mtd/inftlmount.c ---- linux-3.0.9/drivers/mtd/inftlmount.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/inftlmount.c 2011-11-12 12:47:13.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; @@ -30942,10 +31755,11 @@ diff -urNp linux-3.0.9/drivers/mtd/inftlmount.c linux-3.0.9/drivers/mtd/inftlmou DEBUG(MTD_DEBUG_LEVEL3, "INFTL: find_boot_record(inftl=%p)\n", inftl); /* -diff -urNp linux-3.0.9/drivers/mtd/lpddr/qinfo_probe.c linux-3.0.9/drivers/mtd/lpddr/qinfo_probe.c ---- linux-3.0.9/drivers/mtd/lpddr/qinfo_probe.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/lpddr/qinfo_probe.c 2011-11-12 12:47:13.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_probe.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]; @@ -30954,10 +31768,11 @@ diff -urNp linux-3.0.9/drivers/mtd/lpddr/qinfo_probe.c linux-3.0.9/drivers/mtd/l /* Check identification string */ pfow_val[0] = map_read(map, map->pfow_base + PFOW_QUERY_STRING_P); pfow_val[1] = map_read(map, map->pfow_base + PFOW_QUERY_STRING_F); -diff -urNp linux-3.0.9/drivers/mtd/mtdchar.c linux-3.0.9/drivers/mtd/mtdchar.c ---- linux-3.0.9/drivers/mtd/mtdchar.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/mtdchar.c 2011-11-12 12:47:13.000000000 -0500 -@@ -554,6 +554,8 @@ static int mtd_ioctl(struct file *file, +diff --git a/drivers/mtd/mtdchar.c b/drivers/mtd/mtdchar.c +index 9f8658e..caf1155 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; @@ -30966,9 +31781,10 @@ diff -urNp linux-3.0.9/drivers/mtd/mtdchar.c linux-3.0.9/drivers/mtd/mtdchar.c DEBUG(MTD_DEBUG_LEVEL0, "MTD_ioctl\n"); size = (cmd & IOCSIZE_MASK) >> IOCSIZE_SHIFT; -diff -urNp linux-3.0.9/drivers/mtd/nand/denali.c linux-3.0.9/drivers/mtd/nand/denali.c ---- linux-3.0.9/drivers/mtd/nand/denali.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/nand/denali.c 2011-11-12 12:47:13.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 <linux/pci.h> #include <linux/mtd/mtd.h> @@ -30977,10 +31793,11 @@ diff -urNp linux-3.0.9/drivers/mtd/nand/denali.c linux-3.0.9/drivers/mtd/nand/de #include "denali.h" -diff -urNp linux-3.0.9/drivers/mtd/nftlcore.c linux-3.0.9/drivers/mtd/nftlcore.c ---- linux-3.0.9/drivers/mtd/nftlcore.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/nftlcore.c 2011-11-12 12:47:13.000000000 -0500 -@@ -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 = 1; size_t retlen; @@ -30989,9 +31806,10 @@ diff -urNp linux-3.0.9/drivers/mtd/nftlcore.c linux-3.0.9/drivers/mtd/nftlcore.c memset(BlockMap, 0xff, sizeof(BlockMap)); memset(BlockFreeFound, 0, sizeof(BlockFreeFound)); -diff -urNp linux-3.0.9/drivers/mtd/nftlmount.c linux-3.0.9/drivers/mtd/nftlmount.c ---- linux-3.0.9/drivers/mtd/nftlmount.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/nftlmount.c 2011-11-12 12:47:13.000000000 -0500 +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 <asm/errno.h> #include <linux/delay.h> @@ -31000,7 +31818,7 @@ diff -urNp linux-3.0.9/drivers/mtd/nftlmount.c linux-3.0.9/drivers/mtd/nftlmount #include <linux/mtd/mtd.h> #include <linux/mtd/nand.h> #include <linux/mtd/nftl.h> -@@ -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 = nftl->mbd.mtd; unsigned int i; @@ -31009,9 +31827,10 @@ diff -urNp linux-3.0.9/drivers/mtd/nftlmount.c linux-3.0.9/drivers/mtd/nftlmount /* Assume logical EraseSize == physical erasesize for starting the scan. We'll sort it out later if we find a MediaHeader which says otherwise */ /* Actually, we won't. The new DiskOnChip driver has already scanned -diff -urNp linux-3.0.9/drivers/mtd/ubi/build.c linux-3.0.9/drivers/mtd/ubi/build.c ---- linux-3.0.9/drivers/mtd/ubi/build.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/mtd/ubi/build.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c +index 65626c1..e1c2102 100644 +--- a/drivers/mtd/ubi/build.c ++++ b/drivers/mtd/ubi/build.c @@ -1287,7 +1287,7 @@ module_exit(ubi_exit); static int __init bytes_str_to_int(const char *str) { @@ -31021,7 +31840,7 @@ diff -urNp linux-3.0.9/drivers/mtd/ubi/build.c linux-3.0.9/drivers/mtd/ubi/build result = simple_strtoul(str, &endp, 0); if (str == endp || result >= INT_MAX) { -@@ -1298,11 +1298,11 @@ static int __init bytes_str_to_int(const +@@ -1298,11 +1298,11 @@ static int __init bytes_str_to_int(const char *str) switch (*endp) { case 'G': @@ -31036,7 +31855,7 @@ diff -urNp linux-3.0.9/drivers/mtd/ubi/build.c linux-3.0.9/drivers/mtd/ubi/build if (endp[1] == 'i' && endp[2] == 'B') endp += 2; case '\0': -@@ -1313,7 +1313,13 @@ static int __init bytes_str_to_int(const +@@ -1313,7 +1313,13 @@ static int __init bytes_str_to_int(const char *str) return -EINVAL; } @@ -31051,10 +31870,11 @@ diff -urNp linux-3.0.9/drivers/mtd/ubi/build.c linux-3.0.9/drivers/mtd/ubi/build } /** -diff -urNp linux-3.0.9/drivers/net/atlx/atl2.c linux-3.0.9/drivers/net/atlx/atl2.c ---- linux-3.0.9/drivers/net/atlx/atl2.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/atlx/atl2.c 2011-11-12 12:47:13.000000000 -0500 -@@ -2840,7 +2840,7 @@ static void atl2_force_ps(struct atl2_hw +diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c +index 16249e9..6b7a15b 100644 +--- a/drivers/net/atlx/atl2.c ++++ b/drivers/net/atlx/atl2.c +@@ -2840,7 +2840,7 @@ static void atl2_force_ps(struct atl2_hw *hw) */ #define ATL2_PARAM(X, desc) \ @@ -31063,10 +31883,11 @@ diff -urNp linux-3.0.9/drivers/net/atlx/atl2.c linux-3.0.9/drivers/net/atlx/atl2 MODULE_PARM(X, "1-" __MODULE_STRING(ATL2_MAX_NIC) "i"); \ MODULE_PARM_DESC(X, desc); #else -diff -urNp linux-3.0.9/drivers/net/bna/bfa_ioc_ct.c linux-3.0.9/drivers/net/bna/bfa_ioc_ct.c ---- linux-3.0.9/drivers/net/bna/bfa_ioc_ct.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/bna/bfa_ioc_ct.c 2011-11-12 12:47:13.000000000 -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 fcmode); @@ -31110,10 +31931,11 @@ diff -urNp linux-3.0.9/drivers/net/bna/bfa_ioc_ct.c linux-3.0.9/drivers/net/bna/ ioc->ioc_hwif = &nw_hwif_ct; } -diff -urNp linux-3.0.9/drivers/net/bna/bnad.c linux-3.0.9/drivers/net/bna/bnad.c ---- linux-3.0.9/drivers/net/bna/bnad.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/bna/bnad.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1681,7 +1681,14 @@ bnad_setup_tx(struct bnad *bnad, uint tx +diff --git a/drivers/net/bna/bnad.c b/drivers/net/bna/bnad.c +index 44e219c..7e9838d 100644 +--- a/drivers/net/bna/bnad.c ++++ b/drivers/net/bna/bnad.c +@@ -1681,7 +1681,14 @@ bnad_setup_tx(struct bnad *bnad, uint tx_id) struct bna_intr_info *intr_info = &res_info[BNA_TX_RES_INTR_T_TXCMPL].res_u.intr_info; struct bna_tx_config *tx_config = &bnad->tx_config[tx_id]; @@ -31129,7 +31951,7 @@ diff -urNp linux-3.0.9/drivers/net/bna/bnad.c linux-3.0.9/drivers/net/bna/bnad.c struct bna_tx *tx; unsigned long flags; -@@ -1690,13 +1697,6 @@ bnad_setup_tx(struct bnad *bnad, uint tx +@@ -1690,13 +1697,6 @@ bnad_setup_tx(struct bnad *bnad, uint tx_id) tx_config->txq_depth = bnad->txq_depth; tx_config->tx_type = BNA_TX_T_REGULAR; @@ -31143,7 +31965,7 @@ diff -urNp linux-3.0.9/drivers/net/bna/bnad.c linux-3.0.9/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, -@@ -1827,21 +1827,21 @@ bnad_setup_rx(struct bnad *bnad, uint rx +@@ -1827,21 +1827,21 @@ bnad_setup_rx(struct bnad *bnad, uint rx_id) struct bna_intr_info *intr_info = &res_info[BNA_RX_RES_T_INTR].res_u.intr_info; struct bna_rx_config *rx_config = &bnad->rx_config[rx_id]; @@ -31174,9 +31996,10 @@ diff -urNp linux-3.0.9/drivers/net/bna/bnad.c linux-3.0.9/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.0.9/drivers/net/bnx2.c linux-3.0.9/drivers/net/bnx2.c ---- linux-3.0.9/drivers/net/bnx2.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/bnx2.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c +index 74580bb..a293e8f 100644 +--- a/drivers/net/bnx2.c ++++ b/drivers/net/bnx2.c @@ -5831,6 +5831,8 @@ bnx2_test_nvram(struct bnx2 *bp) int rc = 0; u32 magic, csum; @@ -31186,10 +32009,11 @@ diff -urNp linux-3.0.9/drivers/net/bnx2.c linux-3.0.9/drivers/net/bnx2.c if ((rc = bnx2_nvram_read(bp, 0, data, 4)) != 0) goto test_nvram_done; -diff -urNp linux-3.0.9/drivers/net/bnx2x/bnx2x_ethtool.c linux-3.0.9/drivers/net/bnx2x/bnx2x_ethtool.c ---- linux-3.0.9/drivers/net/bnx2x/bnx2x_ethtool.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/bnx2x/bnx2x_ethtool.c 2011-11-12 12:47:13.000000000 -0500 -@@ -1705,6 +1705,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 727fe89..1d404ee 100644 +--- a/drivers/net/bnx2x/bnx2x_ethtool.c ++++ b/drivers/net/bnx2x/bnx2x_ethtool.c +@@ -1705,6 +1705,8 @@ static int bnx2x_test_nvram(struct bnx2x *bp) int i, rc; u32 magic, crc; @@ -31198,10 +32022,11 @@ diff -urNp linux-3.0.9/drivers/net/bnx2x/bnx2x_ethtool.c linux-3.0.9/drivers/net if (BP_NOMCP(bp)) return 0; -diff -urNp linux-3.0.9/drivers/net/can/mscan/mscan.c linux-3.0.9/drivers/net/can/mscan/mscan.c ---- linux-3.0.9/drivers/net/can/mscan/mscan.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/can/mscan/mscan.c 2011-11-12 12:47:13.000000000 -0500 -@@ -261,11 +261,13 @@ static netdev_tx_t mscan_start_xmit(stru +diff --git a/drivers/net/can/mscan/mscan.c b/drivers/net/can/mscan/mscan.c +index 92feac6..4cc6f44 100644 +--- a/drivers/net/can/mscan/mscan.c ++++ b/drivers/net/can/mscan/mscan.c +@@ -261,11 +261,13 @@ static netdev_tx_t mscan_start_xmit(struct sk_buff *skb, struct net_device *dev) void __iomem *data = ®s->tx.dsr1_0; u16 *payload = (u16 *)frame->data; @@ -31217,7 +32042,7 @@ diff -urNp linux-3.0.9/drivers/net/can/mscan/mscan.c linux-3.0.9/drivers/net/can } out_8(®s->tx.dlr, frame->can_dlc); -@@ -330,10 +332,13 @@ static void mscan_get_rx_frame(struct ne +@@ -330,10 +332,13 @@ static void mscan_get_rx_frame(struct net_device *dev, struct can_frame *frame) void __iomem *data = ®s->rx.dsr1_0; u16 *payload = (u16 *)frame->data; @@ -31232,10 +32057,11 @@ diff -urNp linux-3.0.9/drivers/net/can/mscan/mscan.c linux-3.0.9/drivers/net/can } out_8(®s->canrflg, MSCAN_RXF); -diff -urNp linux-3.0.9/drivers/net/cxgb3/l2t.h linux-3.0.9/drivers/net/cxgb3/l2t.h ---- linux-3.0.9/drivers/net/cxgb3/l2t.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/cxgb3/l2t.h 2011-11-12 12:47:13.000000000 -0500 -@@ -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 c4dd066..f49b7cf 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; @@ -31244,10 +32070,11 @@ diff -urNp linux-3.0.9/drivers/net/cxgb3/l2t.h linux-3.0.9/drivers/net/cxgb3/l2t #define L2T_SKB_CB(skb) ((struct l2t_skb_cb *)(skb)->cb) -diff -urNp linux-3.0.9/drivers/net/cxgb4/cxgb4_main.c linux-3.0.9/drivers/net/cxgb4/cxgb4_main.c ---- linux-3.0.9/drivers/net/cxgb4/cxgb4_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/cxgb4/cxgb4_main.c 2011-11-12 12:47:13.000000000 -0500 -@@ -3396,6 +3396,8 @@ static int __devinit enable_msix(struct +diff --git a/drivers/net/cxgb4/cxgb4_main.c b/drivers/net/cxgb4/cxgb4_main.c +index 7e3cfbe..da1b61a 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 *adap) unsigned int nchan = adap->params.nports; struct msix_entry entries[MAX_INGQ + 1]; @@ -31256,10 +32083,11 @@ diff -urNp linux-3.0.9/drivers/net/cxgb4/cxgb4_main.c linux-3.0.9/drivers/net/cx for (i = 0; i < ARRAY_SIZE(entries); ++i) entries[i].entry = i; -diff -urNp linux-3.0.9/drivers/net/cxgb4/t4_hw.c linux-3.0.9/drivers/net/cxgb4/t4_hw.c ---- linux-3.0.9/drivers/net/cxgb4/t4_hw.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/cxgb4/t4_hw.c 2011-11-12 12:47:13.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, struct vpd_params *p) u8 vpd[VPD_LEN], csum; unsigned int vpdr_len, kw_offset, id_len; @@ -31268,10 +32096,11 @@ diff -urNp linux-3.0.9/drivers/net/cxgb4/t4_hw.c linux-3.0.9/drivers/net/cxgb4/t ret = pci_read_vpd(adapter->pdev, VPD_BASE, sizeof(vpd), vpd); if (ret < 0) return ret; -diff -urNp linux-3.0.9/drivers/net/e1000e/82571.c linux-3.0.9/drivers/net/e1000e/82571.c ---- linux-3.0.9/drivers/net/e1000e/82571.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/e1000e/82571.c 2011-11-12 12:47:13.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 8295f21..9a2a54b 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 = &adapter->hw; struct e1000_mac_info *mac = &hw->mac; @@ -31280,10 +32109,11 @@ diff -urNp linux-3.0.9/drivers/net/e1000e/82571.c linux-3.0.9/drivers/net/e1000e u32 swsm = 0; u32 swsm2 = 0; bool force_clear_smbi = false; -diff -urNp linux-3.0.9/drivers/net/e1000e/es2lan.c linux-3.0.9/drivers/net/e1000e/es2lan.c ---- linux-3.0.9/drivers/net/e1000e/es2lan.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/e1000e/es2lan.c 2011-11-12 12:47:13.000000000 -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 f4bbeb2..e0c338a 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 = &adapter->hw; struct e1000_mac_info *mac = &hw->mac; @@ -31292,9 +32122,10 @@ diff -urNp linux-3.0.9/drivers/net/e1000e/es2lan.c linux-3.0.9/drivers/net/e1000 /* Set media type */ switch (adapter->pdev->device) { -diff -urNp linux-3.0.9/drivers/net/e1000e/hw.h linux-3.0.9/drivers/net/e1000e/hw.h ---- linux-3.0.9/drivers/net/e1000e/hw.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/e1000e/hw.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/net/e1000e/hw.h b/drivers/net/e1000e/hw.h +index 6c2fa83..268930d 100644 +--- a/drivers/net/e1000e/hw.h ++++ b/drivers/net/e1000e/hw.h @@ -776,6 +776,7 @@ struct e1000_mac_operations { void (*write_vfta)(struct e1000_hw *, u32, u32); s32 (*read_mac_addr)(struct e1000_hw *); @@ -31341,9 +32172,10 @@ diff -urNp linux-3.0.9/drivers/net/e1000e/hw.h linux-3.0.9/drivers/net/e1000e/hw enum e1000_nvm_type type; enum e1000_nvm_override override; -diff -urNp linux-3.0.9/drivers/net/fealnx.c linux-3.0.9/drivers/net/fealnx.c ---- linux-3.0.9/drivers/net/fealnx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/fealnx.c 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/net/fealnx.c b/drivers/net/fealnx.c +index dd54abe..fafe1ed2 100644 +--- a/drivers/net/fealnx.c ++++ b/drivers/net/fealnx.c @@ -150,7 +150,7 @@ struct chip_info { int flags; }; @@ -31353,10 +32185,11 @@ diff -urNp linux-3.0.9/drivers/net/fealnx.c linux-3.0.9/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.0.9/drivers/net/hamradio/6pack.c linux-3.0.9/drivers/net/hamradio/6pack.c ---- linux-3.0.9/drivers/net/hamradio/6pack.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/hamradio/6pack.c 2011-11-12 12:47:13.000000000 -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 0d28378..816c05c 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 *tty, unsigned char buf[512]; int count1; @@ -31365,9 +32198,10 @@ diff -urNp linux-3.0.9/drivers/net/hamradio/6pack.c linux-3.0.9/drivers/net/hamr if (!count) return; -diff -urNp linux-3.0.9/drivers/net/igb/e1000_hw.h linux-3.0.9/drivers/net/igb/e1000_hw.h ---- linux-3.0.9/drivers/net/igb/e1000_hw.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/igb/e1000_hw.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/net/igb/e1000_hw.h b/drivers/net/igb/e1000_hw.h +index 27153e8..c83eccc 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 *); @@ -31436,9 +32270,10 @@ diff -urNp linux-3.0.9/drivers/net/igb/e1000_hw.h linux-3.0.9/drivers/net/igb/e1 struct e1000_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-3.0.9/drivers/net/igbvf/vf.h linux-3.0.9/drivers/net/igbvf/vf.h ---- linux-3.0.9/drivers/net/igbvf/vf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/igbvf/vf.h 2011-11-12 12:47:13.000000000 -0500 +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); @@ -31468,10 +32303,11 @@ diff -urNp linux-3.0.9/drivers/net/igbvf/vf.h linux-3.0.9/drivers/net/igbvf/vf.h struct e1000_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-3.0.9/drivers/net/ixgb/ixgb_main.c linux-3.0.9/drivers/net/ixgb/ixgb_main.c ---- linux-3.0.9/drivers/net/ixgb/ixgb_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/ixgb/ixgb_main.c 2011-11-12 12:47:13.000000000 -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; @@ -31480,9 +32316,10 @@ diff -urNp linux-3.0.9/drivers/net/ixgb/ixgb_main.c linux-3.0.9/drivers/net/ixgb /* Check for Promiscuous and All Multicast modes */ rctl = IXGB_READ_REG(hw, RCTL); -diff -urNp linux-3.0.9/drivers/net/ixgb/ixgb_param.c linux-3.0.9/drivers/net/ixgb/ixgb_param.c ---- linux-3.0.9/drivers/net/ixgb/ixgb_param.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/ixgb/ixgb_param.c 2011-11-12 12:47:13.000000000 -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) { @@ -31493,9 +32330,10 @@ diff -urNp linux-3.0.9/drivers/net/ixgb/ixgb_param.c linux-3.0.9/drivers/net/ixg if (bd >= 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.0.9/drivers/net/ixgbe/ixgbe_type.h linux-3.0.9/drivers/net/ixgbe/ixgbe_type.h ---- linux-3.0.9/drivers/net/ixgbe/ixgbe_type.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/ixgbe/ixgbe_type.h 2011-11-12 12:47:13.000000000 -0500 +diff --git a/drivers/net/ixgbe/ixgbe_type.h b/drivers/net/ixgbe/ixgbe_type.h +index fa43f25..4ead8f7 100644 +--- a/drivers/net/ixgbe/ixgbe_type.h ++++ b/drivers/net/ixgbe/ixgbe_type.h @@ -2584,6 +2584,7 @@ struct ixgbe_eeprom_operations { s32 (*update_checksum)(struct ixgbe_hw *); u16 (*calc_checksum)(struct ixgbe_hw *); @@ -31559,9 +32397,10 @@ diff -urNp linux-3.0.9/drivers/net/ixgbe/ixgbe_type.h linux-3.0.9/drivers/net/ix struct ixgbe_mbx_stats stats; u32 timeout; u32 usec_delay; -diff -urNp linux-3.0.9/drivers/net/ixgbevf/vf.h linux-3.0.9/drivers/net/ixgbevf/vf.h ---- linux-3.0.9/drivers/net/ixgbevf/vf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/ixgbevf/vf.h 2011-11-12 12:47:13.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); @@ -31596,10 +32435,11 @@ diff -urNp linux-3.0.9/drivers/net/ixgbevf/vf.h linux-3.0.9/drivers/net/ixgbevf/ struct ixgbe_mbx_stats stats; u32 timeout; u32 udelay; -diff -urNp linux-3.0.9/drivers/net/ksz884x.c linux-3.0.9/drivers/net/ksz884x.c ---- linux-3.0.9/drivers/net/ksz884x.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/ksz884x.c 2011-11-12 12:47:14.000000000 -0500 -@@ -6534,6 +6534,8 @@ static void netdev_get_ethtool_stats(str +diff --git a/drivers/net/ksz884x.c b/drivers/net/ksz884x.c +index 41ea592..358ca61 100644 +--- a/drivers/net/ksz884x.c ++++ b/drivers/net/ksz884x.c +@@ -6534,6 +6534,8 @@ static void netdev_get_ethtool_stats(struct net_device *dev, int rc; u64 counter[TOTAL_PORT_COUNTER_NUM]; @@ -31608,9 +32448,10 @@ diff -urNp linux-3.0.9/drivers/net/ksz884x.c linux-3.0.9/drivers/net/ksz884x.c mutex_lock(&hw_priv->lock); n = SWITCH_PORT_NUM; for (i = 0, p = port->first_port; i < port->mib_port_cnt; i++, p++) { -diff -urNp linux-3.0.9/drivers/net/mlx4/main.c linux-3.0.9/drivers/net/mlx4/main.c ---- linux-3.0.9/drivers/net/mlx4/main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/mlx4/main.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/mlx4/main.c b/drivers/net/mlx4/main.c +index 3814fc9..7333446 100644 +--- a/drivers/net/mlx4/main.c ++++ b/drivers/net/mlx4/main.c @@ -40,6 +40,7 @@ #include <linux/dma-mapping.h> #include <linux/slab.h> @@ -31619,7 +32460,7 @@ diff -urNp linux-3.0.9/drivers/net/mlx4/main.c linux-3.0.9/drivers/net/mlx4/main #include <linux/mlx4/device.h> #include <linux/mlx4/doorbell.h> -@@ -764,6 +765,8 @@ static int mlx4_init_hca(struct mlx4_dev +@@ -764,6 +765,8 @@ static int mlx4_init_hca(struct mlx4_dev *dev) u64 icm_size; int err; @@ -31628,10 +32469,11 @@ diff -urNp linux-3.0.9/drivers/net/mlx4/main.c linux-3.0.9/drivers/net/mlx4/main err = mlx4_QUERY_FW(dev); if (err) { if (err == -EACCES) -diff -urNp linux-3.0.9/drivers/net/niu.c linux-3.0.9/drivers/net/niu.c ---- linux-3.0.9/drivers/net/niu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/niu.c 2011-11-12 12:47:14.000000000 -0500 -@@ -9056,6 +9056,8 @@ static void __devinit niu_try_msix(struc +diff --git a/drivers/net/niu.c b/drivers/net/niu.c +index 2f8c351..6a733b3 100644 +--- a/drivers/net/niu.c ++++ b/drivers/net/niu.c +@@ -9056,6 +9056,8 @@ static void __devinit niu_try_msix(struct niu *np, u8 *ldg_num_map) int i, num_irqs, err; u8 first_ldg; @@ -31640,9 +32482,10 @@ diff -urNp linux-3.0.9/drivers/net/niu.c linux-3.0.9/drivers/net/niu.c first_ldg = (NIU_NUM_LDG / parent->num_ports) * np->port; for (i = 0; i < (NIU_NUM_LDG / parent->num_ports); i++) ldg_num_map[i] = first_ldg + i; -diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c ---- linux-3.0.9/drivers/net/pcnet32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/pcnet32.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/pcnet32.c b/drivers/net/pcnet32.c +index b48aba9..8dfaf74 100644 +--- a/drivers/net/pcnet32.c ++++ b/drivers/net/pcnet32.c @@ -82,7 +82,7 @@ static int cards_found; /* * VLB I/O addresses @@ -31661,7 +32504,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/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 *dev) u16 val; netif_wake_queue(dev); @@ -31673,7 +32516,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c napi_enable(&lp->napi); } -@@ -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 = mii_link_ok(&lp->mii_if); } else if (lp->chip_version >= PCNET32_79C970A) { ulong ioaddr = dev->base_addr; /* card base I/O address */ @@ -31682,7 +32525,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } else { /* can not detect link on really old chips */ r = 1; } -@@ -792,7 +792,7 @@ static int pcnet32_set_ringparam(struct +@@ -792,7 +792,7 @@ static int pcnet32_set_ringparam(struct net_device *dev, pcnet32_netif_stop(dev); spin_lock_irqsave(&lp->lock, flags); @@ -31691,7 +32534,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c size = min(ering->tx_pending, (unsigned int)TX_MAX_RING_SIZE); -@@ -868,7 +868,7 @@ static void pcnet32_ethtool_test(struct +@@ -868,7 +868,7 @@ static void pcnet32_ethtool_test(struct net_device *dev, static int pcnet32_loopback_test(struct net_device *dev, uint64_t * data1) { struct pcnet32_private *lp = netdev_priv(dev); @@ -31700,7 +32543,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c ulong ioaddr = 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 +@@ -888,21 +888,21 @@ static int pcnet32_loopback_test(struct net_device *dev, uint64_t * data1) pcnet32_netif_stop(dev); spin_lock_irqsave(&lp->lock, flags); @@ -31727,7 +32570,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c /* Initialize Transmit buffers. */ size = data_len + 15; -@@ -947,10 +947,10 @@ static int pcnet32_loopback_test(struct +@@ -947,10 +947,10 @@ static int pcnet32_loopback_test(struct net_device *dev, uint64_t * data1) /* set int loopback in CSR15 */ x = a->read_csr(ioaddr, CSR15) & 0xfffc; @@ -31740,7 +32583,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c /* Check status of descriptors */ for (x = 0; x < numbuffs; x++) { -@@ -969,7 +969,7 @@ static int pcnet32_loopback_test(struct +@@ -969,7 +969,7 @@ static int pcnet32_loopback_test(struct net_device *dev, uint64_t * data1) } } @@ -31758,7 +32601,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } spin_unlock_irqrestore(&lp->lock, flags); -@@ -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 = netdev_priv(dev); @@ -31767,7 +32610,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c ulong ioaddr = 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 = netdev_priv(dev); @@ -31776,7 +32619,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c ulong ioaddr = dev->base_addr; int ticks; -@@ -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 */ @@ -31787,7 +32630,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/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); /* clear interrupt masks */ @@ -31803,7 +32646,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c 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 *dev, struct ethtool_regs *regs, int i, csr0; u16 *buff = ptr; struct pcnet32_private *lp = netdev_priv(dev); @@ -31812,7 +32655,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c ulong ioaddr = dev->base_addr; unsigned long flags; -@@ -1401,9 +1401,9 @@ static void pcnet32_get_regs(struct net_ +@@ -1401,9 +1401,9 @@ static void pcnet32_get_regs(struct net_device *dev, struct ethtool_regs *regs, for (j = 0; j < PCNET32_MAX_PHYS; j++) { if (lp->phymask & (1 << j)) { for (i = 0; i < PCNET32_REGS_PER_PHY; i++) { @@ -31824,7 +32667,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/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, struct pci_dev *pdev) ((cards_found >= MAX_UNITS) || full_duplex[cards_found])) lp->options |= PCNET32_PORT_FD; @@ -31833,7 +32676,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c /* 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, struct pci_dev *pdev) if (lp->mii) { /* lp->phycount and lp->phymask are set to 0 by memset above */ @@ -31842,7 +32685,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c /* scan for PHYs */ for (i = 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, struct pci_dev *pdev) pr_info("Found PHY %04x:%04x at address %d\n", id1, id2, i); } @@ -31851,7 +32694,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c if (lp->phycount > 1) lp->options |= 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) } /* Reset the PCNET32 */ @@ -31864,7 +32707,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c 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)); /* set/reset autoselect bit */ @@ -31882,7 +32725,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c if (lp->options & PCNET32_PORT_FD) { val |= 1; if (lp->options == (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 == 0x2627) val |= 3; } @@ -31900,7 +32743,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c /* Allied Telesyn AT 2700/2701 FX are 100Mbit only and do not negotiate */ if (pdev && pdev->subsystem_vendor == 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)) { @@ -31933,7 +32776,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/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 */ @@ -31948,7 +32791,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c 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); @@ -31957,7 +32800,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c if (lp->options & PCNET32_PORT_FD) { ecmd.duplex = 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 = DUPLEX_HALF; bcr9 |= ~(1 << 0); } @@ -31966,7 +32809,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } for (i = 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) #ifdef DO_DXSUFLO if (lp->dxsuflo) { /* Disable transmit stop on underflow */ @@ -31978,7 +32821,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } #endif -@@ -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); /* Re-initialize the PCNET32, and start it when done. */ @@ -31994,7 +32837,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c netif_start_queue(dev); -@@ -2192,19 +2192,19 @@ static int pcnet32_open(struct net_devic +@@ -2192,19 +2192,19 @@ static int pcnet32_open(struct net_device *dev) i = 0; while (i++ < 100) @@ -32026,7 +32869,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c 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) /* wait for stop */ for (i = 0; i < 100; i++) @@ -32035,7 +32878,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c break; if (i >= 100) -@@ -2335,13 +2335,13 @@ static void pcnet32_restart(struct net_d +@@ -2335,13 +2335,13 @@ static void pcnet32_restart(struct net_device *dev, unsigned int csr0_bits) return; /* ReInit Ring */ @@ -32052,7 +32895,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } 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", @@ -32063,7 +32906,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/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_buff *skb, netif_printk(lp, tx_queued, KERN_DEBUG, dev, "%s() called, csr0 %4.4x\n", @@ -32072,7 +32915,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c /* 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_buff *skb, dev->stats.tx_bytes += skb->len; /* Trigger an immediate send poll. */ @@ -32125,7 +32968,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c spin_unlock(&lp->lock); -@@ -2520,20 +2520,20 @@ static int pcnet32_close(struct net_devi +@@ -2520,20 +2520,20 @@ static int pcnet32_close(struct net_device *dev) spin_lock_irqsave(&lp->lock, flags); @@ -32150,7 +32993,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c spin_unlock_irqrestore(&lp->lock, flags); -@@ -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; spin_lock_irqsave(&lp->lock, flags); @@ -32159,7 +33002,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c spin_unlock_irqrestore(&lp->lock, flags); return &dev->stats; -@@ -2578,10 +2578,10 @@ static void pcnet32_load_multicast(struc +@@ -2578,10 +2578,10 @@ static void pcnet32_load_multicast(struct net_device *dev) if (dev->flags & IFF_ALLMULTI) { ib->filter[0] = cpu_to_le32(~0U); ib->filter[1] = cpu_to_le32(~0U); @@ -32174,7 +33017,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c return; } /* clear the multicast filter */ -@@ -2601,7 +2601,7 @@ static void pcnet32_load_multicast(struc +@@ -2601,7 +2601,7 @@ static void pcnet32_load_multicast(struct net_device *dev) mcast_table[crc >> 4] |= cpu_to_le16(1 << (crc & 0xf)); } for (i = 0; i < 4; i++) @@ -32183,7 +33026,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c le16_to_cpu(mcast_table[i])); } -@@ -2616,28 +2616,28 @@ static void pcnet32_set_multicast_list(s +@@ -2616,28 +2616,28 @@ static void pcnet32_set_multicast_list(struct net_device *dev) spin_lock_irqsave(&lp->lock, flags); suspended = pcnet32_suspend(dev, &flags, 0); @@ -32218,7 +33061,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c pcnet32_restart(dev, CSR0_NORMAL); netif_wake_queue(dev); } -@@ -2655,8 +2655,8 @@ static int mdio_read(struct net_device * +@@ -2655,8 +2655,8 @@ static int mdio_read(struct net_device *dev, int phy_id, int reg_num) if (!lp->mii) return 0; @@ -32229,7 +33072,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c return val_out; } -@@ -2670,8 +2670,8 @@ static void mdio_write(struct net_device +@@ -2670,8 +2670,8 @@ static void mdio_write(struct net_device *dev, int phy_id, int reg_num, int val) if (!lp->mii) return; @@ -32240,7 +33083,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } static int pcnet32_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) -@@ -2748,7 +2748,7 @@ static void pcnet32_check_media(struct n +@@ -2748,7 +2748,7 @@ static void pcnet32_check_media(struct net_device *dev, int verbose) curr_link = mii_link_ok(&lp->mii_if); } else { ulong ioaddr = dev->base_addr; /* card base I/O address */ @@ -32249,7 +33092,7 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } if (!curr_link) { if (prev_link || verbose) { -@@ -2771,13 +2771,13 @@ static void pcnet32_check_media(struct n +@@ -2771,13 +2771,13 @@ static void pcnet32_check_media(struct net_device *dev, int verbose) (ecmd.duplex == DUPLEX_FULL) ? "full" : "half"); } @@ -32265,10 +33108,11 @@ diff -urNp linux-3.0.9/drivers/net/pcnet32.c linux-3.0.9/drivers/net/pcnet32.c } } else { netif_info(lp, link, dev, "link up\n"); -diff -urNp linux-3.0.9/drivers/net/ppp_generic.c linux-3.0.9/drivers/net/ppp_generic.c ---- linux-3.0.9/drivers/net/ppp_generic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/ppp_generic.c 2011-11-12 12:47:14.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 4609bc0..b0e9d0a 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 = (void __user *) ifr->ifr_ifru.ifru_data; struct ppp_stats stats; struct ppp_comp_stats cstats; @@ -32276,7 +33120,7 @@ diff -urNp linux-3.0.9/drivers/net/ppp_generic.c linux-3.0.9/drivers/net/ppp_gen 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; case SIOCGPPPVER: @@ -32286,9 +33130,10 @@ diff -urNp linux-3.0.9/drivers/net/ppp_generic.c linux-3.0.9/drivers/net/ppp_gen break; err = 0; break; -diff -urNp linux-3.0.9/drivers/net/r8169.c linux-3.0.9/drivers/net/r8169.c ---- linux-3.0.9/drivers/net/r8169.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/r8169.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c +index 5f838ef..0ecfabe 100644 +--- a/drivers/net/r8169.c ++++ b/drivers/net/r8169.c @@ -645,12 +645,12 @@ struct rtl8169_private { struct mdio_ops { void (*write)(void __iomem *, int, int); @@ -32304,10 +33149,11 @@ diff -urNp linux-3.0.9/drivers/net/r8169.c linux-3.0.9/drivers/net/r8169.c 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.0.9/drivers/net/sis190.c linux-3.0.9/drivers/net/sis190.c ---- linux-3.0.9/drivers/net/sis190.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/sis190.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1623,7 +1623,7 @@ static int __devinit sis190_get_mac_addr +diff --git a/drivers/net/sis190.c b/drivers/net/sis190.c +index f6d26ab..054113f 100644 +--- a/drivers/net/sis190.c ++++ b/drivers/net/sis190.c +@@ -1623,7 +1623,7 @@ static int __devinit sis190_get_mac_addr_from_eeprom(struct pci_dev *pdev, static int __devinit sis190_get_mac_addr_from_apc(struct pci_dev *pdev, struct net_device *dev) { @@ -32316,9 +33162,10 @@ diff -urNp linux-3.0.9/drivers/net/sis190.c linux-3.0.9/drivers/net/sis190.c struct sis190_private *tp = netdev_priv(dev); struct pci_dev *isa_bridge; u8 reg, tmp8; -diff -urNp linux-3.0.9/drivers/net/sundance.c linux-3.0.9/drivers/net/sundance.c ---- linux-3.0.9/drivers/net/sundance.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/sundance.c 2011-11-12 12:47:14.000000000 -0500 +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; @@ -32328,9 +33175,10 @@ diff -urNp linux-3.0.9/drivers/net/sundance.c linux-3.0.9/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.0.9/drivers/net/tg3.h linux-3.0.9/drivers/net/tg3.h ---- linux-3.0.9/drivers/net/tg3.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tg3.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h +index 5b3d2f3..fd324d8 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 @@ -32339,10 +33187,11 @@ diff -urNp linux-3.0.9/drivers/net/tg3.h linux-3.0.9/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.0.9/drivers/net/tokenring/abyss.c linux-3.0.9/drivers/net/tokenring/abyss.c ---- linux-3.0.9/drivers/net/tokenring/abyss.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tokenring/abyss.c 2011-11-12 12:47:14.000000000 -0500 -@@ -451,10 +451,12 @@ static struct pci_driver abyss_driver = +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 = { static int __init abyss_init (void) { @@ -32358,10 +33207,11 @@ diff -urNp linux-3.0.9/drivers/net/tokenring/abyss.c linux-3.0.9/drivers/net/tok return pci_register_driver(&abyss_driver); } -diff -urNp linux-3.0.9/drivers/net/tokenring/madgemc.c linux-3.0.9/drivers/net/tokenring/madgemc.c ---- linux-3.0.9/drivers/net/tokenring/madgemc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tokenring/madgemc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -744,9 +744,11 @@ static struct mca_driver madgemc_driver +diff --git a/drivers/net/tokenring/madgemc.c b/drivers/net/tokenring/madgemc.c +index 2bedc0a..2bb69d3 100644 +--- a/drivers/net/tokenring/madgemc.c ++++ b/drivers/net/tokenring/madgemc.c +@@ -744,9 +744,11 @@ static struct mca_driver madgemc_driver = { static int __init madgemc_init (void) { @@ -32376,9 +33226,10 @@ diff -urNp linux-3.0.9/drivers/net/tokenring/madgemc.c linux-3.0.9/drivers/net/t return mca_register_driver (&madgemc_driver); } -diff -urNp linux-3.0.9/drivers/net/tokenring/proteon.c linux-3.0.9/drivers/net/tokenring/proteon.c ---- linux-3.0.9/drivers/net/tokenring/proteon.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tokenring/proteon.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/tokenring/proteon.c b/drivers/net/tokenring/proteon.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 = 0, err = 0; @@ -32394,9 +33245,10 @@ diff -urNp linux-3.0.9/drivers/net/tokenring/proteon.c linux-3.0.9/drivers/net/t err = platform_driver_register(&proteon_driver); if (err) -diff -urNp linux-3.0.9/drivers/net/tokenring/skisa.c linux-3.0.9/drivers/net/tokenring/skisa.c ---- linux-3.0.9/drivers/net/tokenring/skisa.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tokenring/skisa.c 2011-11-12 12:47:14.000000000 -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 = 0, err = 0; @@ -32412,10 +33264,11 @@ diff -urNp linux-3.0.9/drivers/net/tokenring/skisa.c linux-3.0.9/drivers/net/tok err = platform_driver_register(&sk_isa_driver); if (err) -diff -urNp linux-3.0.9/drivers/net/tulip/de2104x.c linux-3.0.9/drivers/net/tulip/de2104x.c ---- linux-3.0.9/drivers/net/tulip/de2104x.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tulip/de2104x.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1794,6 +1794,8 @@ static void __devinit de21041_get_srom_i +diff --git a/drivers/net/tulip/de2104x.c b/drivers/net/tulip/de2104x.c +index e2f6923..b9398d8 100644 +--- a/drivers/net/tulip/de2104x.c ++++ b/drivers/net/tulip/de2104x.c +@@ -1794,6 +1794,8 @@ static void __devinit de21041_get_srom_info (struct de_private *de) struct de_srom_info_leaf *il; void *bufp; @@ -32424,10 +33277,11 @@ diff -urNp linux-3.0.9/drivers/net/tulip/de2104x.c linux-3.0.9/drivers/net/tulip /* download entire eeprom */ for (i = 0; i < DE_EEPROM_WORDS; i++) ((__le16 *)ee_data)[i] = -diff -urNp linux-3.0.9/drivers/net/tulip/de4x5.c linux-3.0.9/drivers/net/tulip/de4x5.c ---- linux-3.0.9/drivers/net/tulip/de4x5.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tulip/de4x5.c 2011-11-12 12:47:14.000000000 -0500 -@@ -5401,7 +5401,7 @@ de4x5_ioctl(struct net_device *dev, stru +diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c +index efaa1d6..f763636 100644 +--- a/drivers/net/tulip/de4x5.c ++++ b/drivers/net/tulip/de4x5.c +@@ -5401,7 +5401,7 @@ de4x5_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) for (i=0; i<ETH_ALEN; i++) { tmp.addr[i] = dev->dev_addr[i]; } @@ -32436,7 +33290,7 @@ diff -urNp linux-3.0.9/drivers/net/tulip/de4x5.c linux-3.0.9/drivers/net/tulip/d break; case DE4X5_SET_HWADDR: /* Set the hardware address */ -@@ -5441,7 +5441,7 @@ de4x5_ioctl(struct net_device *dev, stru +@@ -5441,7 +5441,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); @@ -32445,10 +33299,11 @@ diff -urNp linux-3.0.9/drivers/net/tulip/de4x5.c linux-3.0.9/drivers/net/tulip/d return -EFAULT; break; } -diff -urNp linux-3.0.9/drivers/net/tulip/eeprom.c linux-3.0.9/drivers/net/tulip/eeprom.c ---- linux-3.0.9/drivers/net/tulip/eeprom.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tulip/eeprom.c 2011-11-12 12:47:14.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[] __devinitdata = { {NULL}}; @@ -32457,9 +33312,10 @@ diff -urNp linux-3.0.9/drivers/net/tulip/eeprom.c linux-3.0.9/drivers/net/tulip/ "21140 non-MII", "21140 MII PHY", "21142 Serial PHY", -diff -urNp linux-3.0.9/drivers/net/tulip/winbond-840.c linux-3.0.9/drivers/net/tulip/winbond-840.c ---- linux-3.0.9/drivers/net/tulip/winbond-840.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/tulip/winbond-840.c 2011-11-12 12:47:14.000000000 -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. */ }; @@ -32469,9 +33325,10 @@ diff -urNp linux-3.0.9/drivers/net/tulip/winbond-840.c linux-3.0.9/drivers/net/t { /* Sometime a Level-One switch card. */ "Winbond W89c840", CanHaveMII | HasBrokenTx | FDXOnNoMII}, { "Winbond W89c840", CanHaveMII | HasBrokenTx}, -diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c ---- linux-3.0.9/drivers/net/usb/hso.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/usb/hso.c 2011-11-12 12:47:14.000000000 -0500 +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 <asm/byteorder.h> #include <linux/serial_core.h> @@ -32490,7 +33347,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c spinlock_t serial_lock; 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(struct hso_serial *serial) struct urb *urb; urb = serial->rx_urb[0]; @@ -32499,7 +33356,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c count = put_rxbuf_data(urb, serial); if (count == -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(struct urb *urb) DUMP1(urb->transfer_buffer, urb->actual_length); /* Anyone listening? */ @@ -32508,7 +33365,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c return; if (status == 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); /* check for port already opened, if not set the termios */ @@ -32518,7 +33375,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c serial->rx_state = 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 = hso_start_serial_device(serial->parent, GFP_KERNEL); if (result) { hso_stop_serial_device(serial->parent); @@ -32527,7 +33384,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/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) /* reset the rts and dtr */ /* do the actual close */ @@ -32541,7 +33398,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c spin_lock_irq(&serial->serial_lock); if (serial->tty == tty) { serial->tty->driver_data = NULL; -@@ -1446,7 +1445,7 @@ static void hso_serial_set_termios(struc +@@ -1446,7 +1445,7 @@ static void hso_serial_set_termios(struct tty_struct *tty, struct ktermios *old) /* the actual setup */ spin_lock_irqsave(&serial->serial_lock, flags); @@ -32550,7 +33407,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c _hso_serial_set_termios(tty, old); else tty->termios = 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 == RX_IDLE && @@ -32559,7 +33416,7 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/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 = 0; i < HSO_SERIAL_TTY_MINORS; i++) { if (serial_table[i] && (serial_table[i]->interface == iface)) { @@ -32568,10 +33425,11 @@ diff -urNp linux-3.0.9/drivers/net/usb/hso.c linux-3.0.9/drivers/net/usb/hso.c result = hso_start_serial_device(serial_table[i], GFP_NOIO); hso_kick_transmit(dev2ser(serial_table[i])); -diff -urNp linux-3.0.9/drivers/net/vmxnet3/vmxnet3_ethtool.c linux-3.0.9/drivers/net/vmxnet3/vmxnet3_ethtool.c ---- linux-3.0.9/drivers/net/vmxnet3/vmxnet3_ethtool.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/vmxnet3/vmxnet3_ethtool.c 2011-11-12 12:47:14.000000000 -0500 -@@ -594,8 +594,7 @@ vmxnet3_set_rss_indir(struct net_device +diff --git a/drivers/net/vmxnet3/vmxnet3_ethtool.c b/drivers/net/vmxnet3/vmxnet3_ethtool.c +index dc959fe..5eb190d 100644 +--- a/drivers/net/vmxnet3/vmxnet3_ethtool.c ++++ b/drivers/net/vmxnet3/vmxnet3_ethtool.c +@@ -594,8 +594,7 @@ vmxnet3_set_rss_indir(struct net_device *netdev, * Return with error code if any of the queue indices * is out of range */ @@ -32581,9 +33439,10 @@ diff -urNp linux-3.0.9/drivers/net/vmxnet3/vmxnet3_ethtool.c linux-3.0.9/drivers return -EINVAL; } -diff -urNp linux-3.0.9/drivers/net/vxge/vxge-config.h linux-3.0.9/drivers/net/vxge/vxge-config.h ---- linux-3.0.9/drivers/net/vxge/vxge-config.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/vxge/vxge-config.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/vxge/vxge-config.h b/drivers/net/vxge/vxge-config.h +index 359b9b9..404aea6 100644 +--- a/drivers/net/vxge/vxge-config.h ++++ b/drivers/net/vxge/vxge-config.h @@ -512,7 +512,7 @@ struct vxge_hw_uld_cbs { void (*link_down)(struct __vxge_hw_device *devh); void (*crit_err)(struct __vxge_hw_device *devh, @@ -32593,10 +33452,11 @@ diff -urNp linux-3.0.9/drivers/net/vxge/vxge-config.h linux-3.0.9/drivers/net/vx /* * struct __vxge_hw_blockpool_entry - Block private data structure -diff -urNp linux-3.0.9/drivers/net/vxge/vxge-main.c linux-3.0.9/drivers/net/vxge/vxge-main.c ---- linux-3.0.9/drivers/net/vxge/vxge-main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/vxge/vxge-main.c 2011-11-12 12:47:14.000000000 -0500 -@@ -98,6 +98,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 8ab870a..91b9e61 100644 +--- a/drivers/net/vxge/vxge-main.c ++++ b/drivers/net/vxge/vxge-main.c +@@ -98,6 +98,8 @@ static inline void VXGE_COMPLETE_VPATH_TX(struct vxge_fifo *fifo) struct sk_buff *completed[NR_SKB_COMPLETED]; int more; @@ -32605,7 +33465,7 @@ diff -urNp linux-3.0.9/drivers/net/vxge/vxge-main.c linux-3.0.9/drivers/net/vxge do { more = 0; skb_ptr = completed; -@@ -1920,6 +1922,8 @@ static enum vxge_hw_status vxge_rth_conf +@@ -1920,6 +1922,8 @@ static enum vxge_hw_status vxge_rth_configure(struct vxgedev *vdev) u8 mtable[256] = {0}; /* CPU to vpath mapping */ int index; @@ -32614,9 +33474,10 @@ diff -urNp linux-3.0.9/drivers/net/vxge/vxge-main.c linux-3.0.9/drivers/net/vxge /* * Filling * - itable with bucket numbers -diff -urNp linux-3.0.9/drivers/net/vxge/vxge-traffic.h linux-3.0.9/drivers/net/vxge/vxge-traffic.h ---- linux-3.0.9/drivers/net/vxge/vxge-traffic.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/vxge/vxge-traffic.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/vxge/vxge-traffic.h b/drivers/net/vxge/vxge-traffic.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, @@ -32626,10 +33487,11 @@ diff -urNp linux-3.0.9/drivers/net/vxge/vxge-traffic.h linux-3.0.9/drivers/net/v #define VXGE_HW_VIRTUAL_PATH_HANDLE(vpath) \ ((struct __vxge_hw_vpath_handle *)(vpath)->vpath_handles.next) -diff -urNp linux-3.0.9/drivers/net/wan/cycx_x25.c linux-3.0.9/drivers/net/wan/cycx_x25.c ---- linux-3.0.9/drivers/net/wan/cycx_x25.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wan/cycx_x25.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1018,6 +1018,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 cf9e15f..9789469 100644 +--- a/drivers/net/wan/cycx_x25.c ++++ b/drivers/net/wan/cycx_x25.c +@@ -1018,6 +1018,8 @@ static void hex_dump(char *msg, unsigned char *p, int len) unsigned char hex[1024], * phex = hex; @@ -32638,10 +33500,11 @@ diff -urNp linux-3.0.9/drivers/net/wan/cycx_x25.c linux-3.0.9/drivers/net/wan/cy if (len >= (sizeof(hex) / 2)) len = (sizeof(hex) / 2) - 1; -diff -urNp linux-3.0.9/drivers/net/wan/hdlc_x25.c linux-3.0.9/drivers/net/wan/hdlc_x25.c ---- linux-3.0.9/drivers/net/wan/hdlc_x25.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wan/hdlc_x25.c 2011-11-12 12:47:14.000000000 -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 70527e5..02eedb6 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, struct net_device *dev) static int x25_open(struct net_device *dev) { @@ -32666,10 +33529,11 @@ diff -urNp linux-3.0.9/drivers/net/wan/hdlc_x25.c linux-3.0.9/drivers/net/wan/hd result = lapb_register(dev, &cb); if (result != LAPB_OK) return result; -diff -urNp linux-3.0.9/drivers/net/wimax/i2400m/usb-fw.c linux-3.0.9/drivers/net/wimax/i2400m/usb-fw.c ---- linux-3.0.9/drivers/net/wimax/i2400m/usb-fw.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wimax/i2400m/usb-fw.c 2011-11-12 12:47:14.000000000 -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/i2400m/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 *i2400m, int do_autopm = 1; DECLARE_COMPLETION_ONSTACK(notif_completion); @@ -32678,10 +33542,11 @@ diff -urNp linux-3.0.9/drivers/net/wimax/i2400m/usb-fw.c linux-3.0.9/drivers/net d_fnstart(8, dev, "(i2400m %p ack %p size %zu)\n", i2400m, ack, ack_size); BUG_ON(_ack == i2400m->bm_ack_buf); -diff -urNp linux-3.0.9/drivers/net/wireless/airo.c linux-3.0.9/drivers/net/wireless/airo.c ---- linux-3.0.9/drivers/net/wireless/airo.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/airo.c 2011-11-12 12:47:14.000000000 -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; @@ -32690,7 +33555,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/airo.c linux-3.0.9/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 *mac, int lock) WepKeyRid wkr; int rc; @@ -32699,7 +33564,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/airo.c linux-3.0.9/drivers/net/wirel memset( &mySsid, 0, sizeof( mySsid ) ); kfree (ai->flash); ai->flash = 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 *inode, __le32 *vals = stats.vals; int len; @@ -32708,7 +33573,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/airo.c linux-3.0.9/drivers/net/wirel if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) return -ENOMEM; data = 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 = -1; @@ -32717,7 +33582,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/airo.c linux-3.0.9/drivers/net/wirel if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) return -ENOMEM; data = 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 = capable(CAP_NET_ADMIN) ? 1: -1; @@ -32726,7 +33591,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/airo.c linux-3.0.9/drivers/net/wirel qual = 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_info *local) CapabilityRid cap_rid; __le32 *vals = stats_rid.vals; @@ -32735,10 +33600,23 @@ diff -urNp linux-3.0.9/drivers/net/wireless/airo.c linux-3.0.9/drivers/net/wirel /* Get stats out of the card */ clear_bit(JOB_WSTATS, &local->jobs); if (local->power.event) { -diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c ---- linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c 2011-11-12 12:47:14.000000000 -0500 -@@ -204,6 +204,8 @@ static ssize_t read_file_beacon(struct f +diff --git a/drivers/net/wireless/ath/ath.h b/drivers/net/wireless/ath/ath.h +index 7cf4317..0db3a44 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; + + struct ath_common; + struct ath_bus_ops; +diff --git a/drivers/net/wireless/ath/ath5k/debug.c b/drivers/net/wireless/ath/ath5k/debug.c +index 0bf7313..f232bfc 100644 +--- a/drivers/net/wireless/ath/ath5k/debug.c ++++ b/drivers/net/wireless/ath/ath5k/debug.c +@@ -204,6 +204,8 @@ static ssize_t read_file_beacon(struct file *file, char __user *user_buf, unsigned int v; u64 tsf; @@ -32747,7 +33625,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/driver v = ath5k_hw_reg_read(sc->ah, AR5K_BEACON); len += snprintf(buf+len, sizeof(buf)-len, "%-24s0x%08x\tintval: %d\tTIM: 0x%x\n", -@@ -323,6 +325,8 @@ static ssize_t read_file_debug(struct fi +@@ -323,6 +325,8 @@ static ssize_t read_file_debug(struct file *file, char __user *user_buf, unsigned int len = 0; unsigned int i; @@ -32756,7 +33634,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/driver len += snprintf(buf+len, sizeof(buf)-len, "DEBUG LEVEL: 0x%08x\n\n", sc->debug.level); -@@ -384,6 +388,8 @@ static ssize_t read_file_antenna(struct +@@ -384,6 +388,8 @@ static ssize_t read_file_antenna(struct file *file, char __user *user_buf, unsigned int i; unsigned int v; @@ -32765,7 +33643,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/driver len += snprintf(buf+len, sizeof(buf)-len, "antenna mode\t%d\n", sc->ah->ah_ant_mode); len += snprintf(buf+len, sizeof(buf)-len, "default antenna\t%d\n", -@@ -494,6 +500,8 @@ static ssize_t read_file_misc(struct fil +@@ -494,6 +500,8 @@ static ssize_t read_file_misc(struct file *file, char __user *user_buf, unsigned int len = 0; u32 filt = ath5k_hw_get_rx_filter(sc->ah); @@ -32774,7 +33652,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/driver len += snprintf(buf+len, sizeof(buf)-len, "bssid-mask: %pM\n", sc->bssidmask); len += snprintf(buf+len, sizeof(buf)-len, "filter-flags: 0x%x ", -@@ -550,6 +558,8 @@ static ssize_t read_file_frameerrors(str +@@ -550,6 +558,8 @@ static ssize_t read_file_frameerrors(struct file *file, char __user *user_buf, unsigned int len = 0; int i; @@ -32783,7 +33661,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/driver len += snprintf(buf+len, sizeof(buf)-len, "RX\n---------------------\n"); len += snprintf(buf+len, sizeof(buf)-len, "CRC\t%u\t(%u%%)\n", -@@ -667,6 +677,8 @@ static ssize_t read_file_ani(struct file +@@ -667,6 +677,8 @@ static ssize_t read_file_ani(struct file *file, char __user *user_buf, char buf[700]; unsigned int len = 0; @@ -32792,7 +33670,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/driver len += snprintf(buf+len, sizeof(buf)-len, "HW has PHY error counters:\t%s\n", sc->ah->ah_capabilities.cap_has_phyerr_counters ? -@@ -827,6 +839,8 @@ static ssize_t read_file_queue(struct fi +@@ -827,6 +839,8 @@ static ssize_t read_file_queue(struct file *file, char __user *user_buf, struct ath5k_buf *bf, *bf0; int i, n; @@ -32801,10 +33679,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath5k/debug.c linux-3.0.9/driver len += snprintf(buf+len, sizeof(buf)-len, "available txbuffers: %d\n", sc->txbuf_len); -diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_calib.c linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_calib.c ---- linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_calib.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_calib.c 2011-11-12 12:47:14.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; @@ -32813,10 +33692,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_calib.c linux-3.0.9 for (i = 0; i < AR9300_MAX_CHAINS; i++) { if (ah->txchainmask & (1 << i)) num_chains++; -diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_paprd.c linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_paprd.c ---- linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_paprd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_paprd.c 2011-11-12 12:47:14.000000000 -0500 -@@ -356,6 +356,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 e4d6a87..8ed13ba 100644 +--- a/drivers/net/wireless/ath/ath9k/ar9003_paprd.c ++++ b/drivers/net/wireless/ath/ath9k/ar9003_paprd.c +@@ -356,6 +356,8 @@ static bool create_pa_curve(u32 *data_L, u32 *data_U, u32 *pa_table, u16 *gain) int theta_low_bin = 0; int i; @@ -32825,10 +33705,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/ar9003_paprd.c linux-3.0.9 /* disregard any bin that contains <= 16 samples */ thresh_accum_cnt = 16; scale_factor = 5; -diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/debug.c linux-3.0.9/drivers/net/wireless/ath/ath9k/debug.c ---- linux-3.0.9/drivers/net/wireless/ath/ath9k/debug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ath/ath9k/debug.c 2011-11-12 12:47:14.000000000 -0500 -@@ -337,6 +337,8 @@ static ssize_t read_file_interrupt(struc +diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath/ath9k/debug.c +index d55ffd7..f7935a9 100644 +--- a/drivers/net/wireless/ath/ath9k/debug.c ++++ b/drivers/net/wireless/ath/ath9k/debug.c +@@ -337,6 +337,8 @@ static ssize_t read_file_interrupt(struct file *file, char __user *user_buf, char buf[512]; unsigned int len = 0; @@ -32837,7 +33718,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/debug.c linux-3.0.9/driver if (sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_EDMA) { len += snprintf(buf + len, sizeof(buf) - len, "%8s: %10u\n", "RXLP", sc->debug.stats.istats.rxlp); -@@ -427,6 +429,8 @@ static ssize_t read_file_wiphy(struct fi +@@ -427,6 +429,8 @@ static ssize_t read_file_wiphy(struct file *file, char __user *user_buf, u8 addr[ETH_ALEN]; u32 tmp; @@ -32846,10 +33727,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/debug.c linux-3.0.9/driver len += snprintf(buf + len, sizeof(buf) - len, "%s (chan=%d center-freq: %d MHz channel-type: %d (%s))\n", wiphy_name(sc->hw->wiphy), -diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c ---- linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c 2011-11-12 12:47:14.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/net/wireless/ath/ath9k/htc_drv_debug.c +index aa48b3a..947f9fa 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 *file, char __user *user_buf, unsigned int len = 0; int ret = 0; @@ -32858,7 +33740,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c linux-3.0. memset(&cmd_rsp, 0, sizeof(cmd_rsp)); 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 *file, char __user *user_buf, unsigned int len = 0; int ret = 0; @@ -32867,7 +33749,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c linux-3.0. memset(&cmd_rsp, 0, sizeof(cmd_rsp)); 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 *file, char __user *user_buf, unsigned int len = 0; int ret = 0; @@ -32876,7 +33758,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c linux-3.0. memset(&cmd_rsp, 0, sizeof(cmd_rsp)); 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, char __user *user_buf, char buf[512]; unsigned int len = 0; @@ -32885,7 +33767,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c linux-3.0. len += 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, char __user *user_buf, char buf[512]; unsigned int len = 0; @@ -32894,7 +33776,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c linux-3.0. spin_lock_bh(&priv->tx.tx_lock); len += 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, char __user *user_buf, char buf[512]; unsigned int len = 0; @@ -32903,9 +33785,10 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/htc_drv_debug.c linux-3.0. len += snprintf(buf + len, sizeof(buf) - len, "%20s : %10u\n", "Mgmt endpoint", skb_queue_len(&priv->tx.mgmt_ep_queue)); -diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/hw.h linux-3.0.9/drivers/net/wireless/ath/ath9k/hw.h ---- linux-3.0.9/drivers/net/wireless/ath/ath9k/hw.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ath/ath9k/hw.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/net/wireless/ath/ath9k/hw.h b/drivers/net/wireless/ath/ath9k/hw.h +index 939cc9d..67a3943 100644 +--- a/drivers/net/wireless/ath/ath9k/hw.h ++++ b/drivers/net/wireless/ath/ath9k/hw.h @@ -585,7 +585,7 @@ struct ath_hw_private_ops { /* ANI */ @@ -32933,21 +33816,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath9k/hw.h linux-3.0.9/drivers/n struct ieee80211_hw *hw; struct ath_common common; -diff -urNp linux-3.0.9/drivers/net/wireless/ath/ath.h linux-3.0.9/drivers/net/wireless/ath/ath.h ---- linux-3.0.9/drivers/net/wireless/ath/ath.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ath/ath.h 2011-11-12 12:47:14.000000000 -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; - - struct ath_common; - struct ath_bus_ops; -diff -urNp linux-3.0.9/drivers/net/wireless/ipw2x00/ipw2100.c linux-3.0.9/drivers/net/wireless/ipw2x00/ipw2100.c ---- linux-3.0.9/drivers/net/wireless/ipw2x00/ipw2100.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ipw2x00/ipw2100.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2100,6 +2100,8 @@ static int ipw2100_set_essid(struct ipw2 +diff --git a/drivers/net/wireless/ipw2x00/ipw2100.c b/drivers/net/wireless/ipw2x00/ipw2100.c +index 4430775..a509155 100644 +--- a/drivers/net/wireless/ipw2x00/ipw2100.c ++++ b/drivers/net/wireless/ipw2x00/ipw2100.c +@@ -2100,6 +2100,8 @@ static int ipw2100_set_essid(struct ipw2100_priv *priv, char *essid, int err; DECLARE_SSID_BUF(ssid); @@ -32956,7 +33829,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ipw2x00/ipw2100.c linux-3.0.9/driver IPW_DEBUG_HC("SSID: '%s'\n", print_ssid(ssid, essid, ssid_len)); if (ssid_len) -@@ -5449,6 +5451,8 @@ static int ipw2100_set_key(struct ipw210 +@@ -5449,6 +5451,8 @@ static int ipw2100_set_key(struct ipw2100_priv *priv, struct ipw2100_wep_key *wep_key = (void *)cmd.host_command_parameters; int err; @@ -32965,10 +33838,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ipw2x00/ipw2100.c linux-3.0.9/driver IPW_DEBUG_HC("WEP_KEY_INFO: index = %d, len = %d/%d\n", idx, keylen, len); -diff -urNp linux-3.0.9/drivers/net/wireless/ipw2x00/libipw_rx.c linux-3.0.9/drivers/net/wireless/ipw2x00/libipw_rx.c ---- linux-3.0.9/drivers/net/wireless/ipw2x00/libipw_rx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/ipw2x00/libipw_rx.c 2011-11-12 12:47:14.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/wireless/ipw2x00/libipw_rx.c +index e5ad76c..c8bd5b4 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 libipw_device unsigned long flags; DECLARE_SSID_BUF(ssid); @@ -32977,10 +33851,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/ipw2x00/libipw_rx.c linux-3.0.9/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.0.9/drivers/net/wireless/iwlegacy/iwl3945-base.c linux-3.0.9/drivers/net/wireless/iwlegacy/iwl3945-base.c ---- linux-3.0.9/drivers/net/wireless/iwlegacy/iwl3945-base.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/iwlegacy/iwl3945-base.c 2011-11-12 12:47:14.000000000 -0500 -@@ -3962,7 +3962,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 421d5c8..b66312e 100644 +--- a/drivers/net/wireless/iwlegacy/iwl3945-base.c ++++ b/drivers/net/wireless/iwlegacy/iwl3945-base.c +@@ -3962,7 +3962,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"); @@ -32991,10 +33866,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/iwlegacy/iwl3945-base.c linux-3.0.9/ } IWL_DEBUG_INFO(priv, "*** LOAD DRIVER ***\n"); -diff -urNp linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-agn-rs.c linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-agn-rs.c ---- linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-agn-rs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-agn-rs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -910,6 +910,8 @@ static void rs_tx_status(void *priv_r, s +diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +index 592b0cf..890faad 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c ++++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +@@ -910,6 +910,8 @@ static void rs_tx_status(void *priv_r, struct ieee80211_supported_band *sband, struct iwl_station_priv *sta_priv = (void *)sta->drv_priv; struct iwl_rxon_context *ctx = sta_priv->common.ctx; @@ -33003,7 +33879,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-agn-rs.c linux-3.0.9/dri IWL_DEBUG_RATE_LIMIT(priv, "get frame ack response, update rate scale window\n"); /* Treat uninitialized rate scaling data same as non-existing. */ -@@ -2918,6 +2920,8 @@ static void rs_fill_link_cmd(struct iwl_ +@@ -2918,6 +2920,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 = &lq_sta->lq; @@ -33012,10 +33888,26 @@ diff -urNp linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-agn-rs.c linux-3.0.9/dri /* Override starting rate (index 0) if needed for debug purposes */ rs_dbgfs_set_mcs(lq_sta, &new_rate, index); -diff -urNp linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debugfs.c linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debugfs.c ---- linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debugfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debugfs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -548,6 +548,8 @@ static ssize_t iwl_dbgfs_status_read(str +diff --git a/drivers/net/wireless/iwlwifi/iwl-debug.h b/drivers/net/wireless/iwlwifi/iwl-debug.h +index 2824ccb..b5630ca 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-debug.h ++++ b/drivers/net/wireless/iwlwifi/iwl-debug.h +@@ -68,8 +68,8 @@ do { \ + } while (0) + + #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/wireless/iwlwifi/iwl-debugfs.c +index 0e6a04b..39636b6 100644 +--- a/drivers/net/wireless/iwlwifi/iwl-debugfs.c ++++ b/drivers/net/wireless/iwlwifi/iwl-debugfs.c +@@ -548,6 +548,8 @@ static ssize_t iwl_dbgfs_status_read(struct file *file, int pos = 0; const size_t bufsz = sizeof(buf); @@ -33024,7 +33916,7 @@ diff -urNp linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debugfs.c linux-3.0.9/dr pos += scnprintf(buf + pos, bufsz - pos, "STATUS_HCMD_ACTIVE:\t %d\n", test_bit(STATUS_HCMD_ACTIVE, &priv->status)); pos += scnprintf(buf + pos, bufsz - pos, "STATUS_INT_ENABLED:\t %d\n", -@@ -680,6 +682,8 @@ static ssize_t iwl_dbgfs_qos_read(struct +@@ -680,6 +682,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 = sizeof(buf); @@ -33033,24 +33925,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debugfs.c linux-3.0.9/dr for_each_context(priv, ctx) { pos += scnprintf(buf + pos, bufsz - pos, "context %d:\n", ctx->ctxid); -diff -urNp linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debug.h linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debug.h ---- linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debug.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/iwlwifi/iwl-debug.h 2011-11-12 12:47:14.000000000 -0500 -@@ -68,8 +68,8 @@ do { - } while (0) - - #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.0.9/drivers/net/wireless/iwmc3200wifi/debugfs.c linux-3.0.9/drivers/net/wireless/iwmc3200wifi/debugfs.c ---- linux-3.0.9/drivers/net/wireless/iwmc3200wifi/debugfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/iwmc3200wifi/debugfs.c 2011-11-12 12:47:14.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/wireless/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 = 512; size_t len = 0; @@ -33059,10 +33938,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/iwmc3200wifi/debugfs.c linux-3.0.9/d if (*ppos != 0) return 0; if (count < sizeof(buf)) -diff -urNp linux-3.0.9/drivers/net/wireless/mac80211_hwsim.c linux-3.0.9/drivers/net/wireless/mac80211_hwsim.c ---- linux-3.0.9/drivers/net/wireless/mac80211_hwsim.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/mac80211_hwsim.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1260,9 +1260,11 @@ static int __init init_mac80211_hwsim(vo +diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c +index 9d4a40e..add74dd 100644 +--- a/drivers/net/wireless/mac80211_hwsim.c ++++ b/drivers/net/wireless/mac80211_hwsim.c +@@ -1260,9 +1260,11 @@ static int __init init_mac80211_hwsim(void) return -EINVAL; if (fake_hw_scan) { @@ -33077,10 +33957,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/mac80211_hwsim.c linux-3.0.9/drivers } spin_lock_init(&hwsim_radio_lock); -diff -urNp linux-3.0.9/drivers/net/wireless/rndis_wlan.c linux-3.0.9/drivers/net/wireless/rndis_wlan.c ---- linux-3.0.9/drivers/net/wireless/rndis_wlan.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/rndis_wlan.c 2011-11-12 12:47:14.000000000 -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/rndis_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) netdev_dbg(usbdev->net, "%s(): %i\n", __func__, rts_threshold); @@ -33089,10 +33970,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/rndis_wlan.c linux-3.0.9/drivers/net rts_threshold = 2347; tmp = cpu_to_le32(rts_threshold); -diff -urNp linux-3.0.9/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c linux-3.0.9/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c ---- linux-3.0.9/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c 2011-11-12 12:47:14.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/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c +index d2cc815..9579e62 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 ieee80211_hw *hw, u8 rfpath; u8 num_total_rfpath = rtlphy->num_total_rfpath; @@ -33101,9 +33983,10 @@ diff -urNp linux-3.0.9/drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c linux- precommoncmdcnt = 0; _rtl92c_phy_set_sw_chnl_cmdarray(precommoncmd, precommoncmdcnt++, MAX_PRECMD_CNT, -diff -urNp linux-3.0.9/drivers/net/wireless/wl1251/wl1251.h linux-3.0.9/drivers/net/wireless/wl1251/wl1251.h ---- linux-3.0.9/drivers/net/wireless/wl1251/wl1251.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/wl1251/wl1251.h 2011-11-12 12:47:14.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); @@ -33113,10 +33996,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/wl1251/wl1251.h linux-3.0.9/drivers/ struct wl1251 { struct ieee80211_hw *hw; -diff -urNp linux-3.0.9/drivers/net/wireless/wl12xx/spi.c linux-3.0.9/drivers/net/wireless/wl12xx/spi.c ---- linux-3.0.9/drivers/net/wireless/wl12xx/spi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/net/wireless/wl12xx/spi.c 2011-11-12 12:47:14.000000000 -0500 -@@ -280,6 +280,8 @@ static void wl1271_spi_raw_write(struct +diff --git a/drivers/net/wireless/wl12xx/spi.c b/drivers/net/wireless/wl12xx/spi.c +index 51662bb..354cd39 100644 +--- a/drivers/net/wireless/wl12xx/spi.c ++++ b/drivers/net/wireless/wl12xx/spi.c +@@ -280,6 +280,8 @@ static void wl1271_spi_raw_write(struct wl1271 *wl, int addr, void *buf, u32 chunk_len; int i; @@ -33125,10 +34009,11 @@ diff -urNp linux-3.0.9/drivers/net/wireless/wl12xx/spi.c linux-3.0.9/drivers/net WARN_ON(len > WL1271_AGGR_BUFFER_SIZE); spi_message_init(&m); -diff -urNp linux-3.0.9/drivers/oprofile/buffer_sync.c linux-3.0.9/drivers/oprofile/buffer_sync.c ---- linux-3.0.9/drivers/oprofile/buffer_sync.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/oprofile/buffer_sync.c 2011-11-12 12:47:14.000000000 -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_sync.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 == NO_COOKIE) offset = pc; if (cookie == INVALID_COOKIE) { @@ -33137,7 +34022,7 @@ diff -urNp linux-3.0.9/drivers/oprofile/buffer_sync.c linux-3.0.9/drivers/oprofi offset = pc; } if (cookie != last_cookie) { -@@ -387,14 +387,14 @@ add_sample(struct mm_struct *mm, struct +@@ -387,14 +387,14 @@ add_sample(struct mm_struct *mm, struct op_sample *s, int in_kernel) /* add userspace sample */ if (!mm) { @@ -33163,10 +34048,11 @@ diff -urNp linux-3.0.9/drivers/oprofile/buffer_sync.c linux-3.0.9/drivers/oprofi } } release_mm(mm); -diff -urNp linux-3.0.9/drivers/oprofile/event_buffer.c linux-3.0.9/drivers/oprofile/event_buffer.c ---- linux-3.0.9/drivers/oprofile/event_buffer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/oprofile/event_buffer.c 2011-11-12 12:47:14.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_buffer.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) } if (buffer_pos == buffer_size) { @@ -33175,10 +34061,11 @@ diff -urNp linux-3.0.9/drivers/oprofile/event_buffer.c linux-3.0.9/drivers/oprof return; } -diff -urNp linux-3.0.9/drivers/oprofile/oprof.c linux-3.0.9/drivers/oprofile/oprof.c ---- linux-3.0.9/drivers/oprofile/oprof.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/oprofile/oprof.c 2011-11-12 12:47:14.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; @@ -33187,21 +34074,10 @@ diff -urNp linux-3.0.9/drivers/oprofile/oprof.c linux-3.0.9/drivers/oprofile/opr start_switch_worker(); } -diff -urNp linux-3.0.9/drivers/oprofile/oprofilefs.c linux-3.0.9/drivers/oprofile/oprofilefs.c ---- linux-3.0.9/drivers/oprofile/oprofilefs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/oprofile/oprofilefs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -186,7 +186,7 @@ static const struct file_operations atom - - - 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.0.9/drivers/oprofile/oprofile_stats.c linux-3.0.9/drivers/oprofile/oprofile_stats.c ---- linux-3.0.9/drivers/oprofile/oprofile_stats.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/oprofile/oprofile_stats.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/oprofile/oprofile_stats.c b/drivers/oprofile/oprofile_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 = 0; } @@ -33219,9 +34095,10 @@ diff -urNp linux-3.0.9/drivers/oprofile/oprofile_stats.c linux-3.0.9/drivers/opr } -diff -urNp linux-3.0.9/drivers/oprofile/oprofile_stats.h linux-3.0.9/drivers/oprofile/oprofile_stats.h ---- linux-3.0.9/drivers/oprofile/oprofile_stats.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/oprofile/oprofile_stats.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/oprofile/oprofile_stats.h b/drivers/oprofile/oprofile_stats.h +index 0b54e46..a37c527 100644 +--- a/drivers/oprofile/oprofile_stats.h ++++ b/drivers/oprofile/oprofile_stats.h @@ -13,11 +13,11 @@ #include <asm/atomic.h> @@ -33239,10 +34116,24 @@ diff -urNp linux-3.0.9/drivers/oprofile/oprofile_stats.h linux-3.0.9/drivers/opr }; extern struct oprofile_stat_struct oprofile_stats; -diff -urNp linux-3.0.9/drivers/parport/procfs.c linux-3.0.9/drivers/parport/procfs.c ---- linux-3.0.9/drivers/parport/procfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/parport/procfs.c 2011-11-12 12:47:14.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 = { + + + 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 write, *ppos += len; @@ -33251,7 +34142,7 @@ diff -urNp linux-3.0.9/drivers/parport/procfs.c linux-3.0.9/drivers/parport/proc } #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, *ppos += len; @@ -33260,9 +34151,10 @@ diff -urNp linux-3.0.9/drivers/parport/procfs.c linux-3.0.9/drivers/parport/proc } #endif /* IEEE1284.3 support. */ -diff -urNp linux-3.0.9/drivers/pci/hotplug/cpci_hotplug.h linux-3.0.9/drivers/pci/hotplug/cpci_hotplug.h ---- linux-3.0.9/drivers/pci/hotplug/cpci_hotplug.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pci/hotplug/cpci_hotplug.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/pci/hotplug/cpci_hotplug.h b/drivers/pci/hotplug/cpci_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); @@ -33272,10 +34164,11 @@ diff -urNp linux-3.0.9/drivers/pci/hotplug/cpci_hotplug.h linux-3.0.9/drivers/pc struct cpci_hp_controller { unsigned int irq; -diff -urNp linux-3.0.9/drivers/pci/hotplug/cpqphp_nvram.c linux-3.0.9/drivers/pci/hotplug/cpqphp_nvram.c ---- linux-3.0.9/drivers/pci/hotplug/cpqphp_nvram.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pci/hotplug/cpqphp_nvram.c 2011-11-12 12:47:14.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/cpqphp_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) void compaq_nvram_init (void __iomem *rom_start) { @@ -33289,9 +34182,10 @@ diff -urNp linux-3.0.9/drivers/pci/hotplug/cpqphp_nvram.c linux-3.0.9/drivers/pc dbg("int15 entry = %p\n", compaq_int15_entry_point); /* initialize our int15 lock */ -diff -urNp linux-3.0.9/drivers/pci/pcie/aspm.c linux-3.0.9/drivers/pci/pcie/aspm.c ---- linux-3.0.9/drivers/pci/pcie/aspm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pci/pcie/aspm.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/pci/pcie/aspm.c b/drivers/pci/pcie/aspm.c +index 6892601..65aaa93 100644 +--- a/drivers/pci/pcie/aspm.c ++++ b/drivers/pci/pcie/aspm.c @@ -27,9 +27,9 @@ #define MODULE_PARAM_PREFIX "pcie_aspm." @@ -33305,10 +34199,11 @@ diff -urNp linux-3.0.9/drivers/pci/pcie/aspm.c linux-3.0.9/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) -diff -urNp linux-3.0.9/drivers/pci/probe.c linux-3.0.9/drivers/pci/probe.c ---- linux-3.0.9/drivers/pci/probe.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pci/probe.c 2011-11-12 12:47:14.000000000 -0500 -@@ -129,7 +129,7 @@ int __pci_read_base(struct pci_dev *dev, +diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c +index bafb3c3..5f91c5f 100644 +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -129,7 +129,7 @@ int __pci_read_base(struct pci_dev *dev, enum pci_bar_type type, u32 l, sz, mask; u16 orig_cmd; @@ -33317,10 +34212,11 @@ diff -urNp linux-3.0.9/drivers/pci/probe.c linux-3.0.9/drivers/pci/probe.c if (!dev->mmio_always_on) { pci_read_config_word(dev, PCI_COMMAND, &orig_cmd); -diff -urNp linux-3.0.9/drivers/pci/proc.c linux-3.0.9/drivers/pci/proc.c ---- linux-3.0.9/drivers/pci/proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pci/proc.c 2011-11-12 12:47:14.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_dev_operations = { static int __init pci_proc_init(void) { struct pci_dev *dev = NULL; @@ -33337,10 +34233,11 @@ diff -urNp linux-3.0.9/drivers/pci/proc.c linux-3.0.9/drivers/pci/proc.c proc_create("devices", 0, proc_bus_pci_dir, &proc_bus_pci_dev_operations); proc_initialized = 1; -diff -urNp linux-3.0.9/drivers/pci/xen-pcifront.c linux-3.0.9/drivers/pci/xen-pcifront.c ---- linux-3.0.9/drivers/pci/xen-pcifront.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pci/xen-pcifront.c 2011-11-12 12:47:14.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 d4e7a10..0790107 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, unsigned int devfn, struct pcifront_sd *sd = bus->sysdata; struct pcifront_device *pdev = pcifront_get_pdev(sd); @@ -33349,7 +34246,7 @@ diff -urNp linux-3.0.9/drivers/pci/xen-pcifront.c linux-3.0.9/drivers/pci/xen-pc if (verbose_request) dev_info(&pdev->xdev->dev, "read dev=%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, unsigned int devfn, struct pcifront_sd *sd = bus->sysdata; struct pcifront_device *pdev = pcifront_get_pdev(sd); @@ -33358,7 +34255,7 @@ diff -urNp linux-3.0.9/drivers/pci/xen-pcifront.c linux-3.0.9/drivers/pci/xen-pc if (verbose_request) dev_info(&pdev->xdev->dev, "write dev=%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 = pcifront_get_pdev(sd); struct msi_desc *entry; @@ -33367,7 +34264,7 @@ diff -urNp linux-3.0.9/drivers/pci/xen-pcifront.c linux-3.0.9/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 = dev->bus->sysdata; struct pcifront_device *pdev = pcifront_get_pdev(sd); @@ -33376,7 +34273,7 @@ diff -urNp linux-3.0.9/drivers/pci/xen-pcifront.c linux-3.0.9/drivers/pci/xen-pc err = do_pci_op(pdev, &op); /* 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 *dev, int vector[]) struct pcifront_sd *sd = dev->bus->sysdata; struct pcifront_device *pdev = pcifront_get_pdev(sd); @@ -33385,9 +34282,10 @@ diff -urNp linux-3.0.9/drivers/pci/xen-pcifront.c linux-3.0.9/drivers/pci/xen-pc err = do_pci_op(pdev, &op); if (likely(!err)) { vector[0] = op.value; -diff -urNp linux-3.0.9/drivers/platform/x86/thinkpad_acpi.c linux-3.0.9/drivers/platform/x86/thinkpad_acpi.c ---- linux-3.0.9/drivers/platform/x86/thinkpad_acpi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/platform/x86/thinkpad_acpi.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c +index 26c5b11..fa93a8b 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; } @@ -33397,9 +34295,10 @@ diff -urNp linux-3.0.9/drivers/platform/x86/thinkpad_acpi.c linux-3.0.9/drivers/ { /* log only what the user can fix... */ const u32 wantedmask = hotkey_driver_mask & -diff -urNp linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c ---- linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/pnp/pnpbios/bioscalls.c b/drivers/pnp/pnpbios/bioscalls.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) @@ -33409,7 +34308,7 @@ diff -urNp linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c linux-3.0.9/drivers/pnp/p (unsigned long)__va(0x400UL), PAGE_SIZE - 0x400 - 1); /* -@@ -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, u16 arg2, u16 arg3, cpu = get_cpu(); save_desc_40 = get_cpu_gdt_table(cpu)[0x40 / 8]; @@ -33420,7 +34319,7 @@ diff -urNp linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c linux-3.0.9/drivers/pnp/p /* 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); @@ -33431,7 +34330,7 @@ diff -urNp linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c linux-3.0.9/drivers/pnp/p put_cpu(); /* 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; } @@ -33440,7 +34339,7 @@ diff -urNp linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c linux-3.0.9/drivers/pnp/p { int i; -@@ -476,6 +482,8 @@ void pnpbios_calls_init(union pnp_bios_i +@@ -476,6 +482,8 @@ void pnpbios_calls_init(union pnp_bios_install_struct *header) pnp_bios_callpoint.offset = header->fields.pm16offset; pnp_bios_callpoint.segment = PNP_CS16; @@ -33449,17 +34348,18 @@ diff -urNp linux-3.0.9/drivers/pnp/pnpbios/bioscalls.c linux-3.0.9/drivers/pnp/p for_each_possible_cpu(i) { struct desc_struct *gdt = 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_struct *header) set_desc_base(&gdt[GDT_ENTRY_PNPBIOS_DS], (unsigned long)__va(header->fields.pm16dseg)); } + + pax_close_kernel(); } -diff -urNp linux-3.0.9/drivers/pnp/resource.c linux-3.0.9/drivers/pnp/resource.c ---- linux-3.0.9/drivers/pnp/resource.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/pnp/resource.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 resource *res) return 1; /* check if the resource is valid */ @@ -33468,7 +34368,7 @@ diff -urNp linux-3.0.9/drivers/pnp/resource.c linux-3.0.9/drivers/pnp/resource.c return 0; /* 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 resource *res) return 1; /* check if the resource is valid */ @@ -33477,9 +34377,10 @@ diff -urNp linux-3.0.9/drivers/pnp/resource.c linux-3.0.9/drivers/pnp/resource.c return 0; /* check if the resource is reserved */ -diff -urNp linux-3.0.9/drivers/power/bq27x00_battery.c linux-3.0.9/drivers/power/bq27x00_battery.c ---- linux-3.0.9/drivers/power/bq27x00_battery.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/power/bq27x00_battery.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/power/bq27x00_battery.c b/drivers/power/bq27x00_battery.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 { @@ -33489,10 +34390,11 @@ diff -urNp linux-3.0.9/drivers/power/bq27x00_battery.c linux-3.0.9/drivers/power enum bq27x00_chip { BQ27000, BQ27500 }; -diff -urNp linux-3.0.9/drivers/regulator/max8660.c linux-3.0.9/drivers/regulator/max8660.c ---- linux-3.0.9/drivers/regulator/max8660.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/regulator/max8660.c 2011-11-12 12:47:14.000000000 -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_client *client, max8660->shadow_regs[MAX8660_OVER1] = 5; } else { /* Otherwise devices can be toggled via software */ @@ -33505,10 +34407,11 @@ diff -urNp linux-3.0.9/drivers/regulator/max8660.c linux-3.0.9/drivers/regulator } /* -diff -urNp linux-3.0.9/drivers/regulator/mc13892-regulator.c linux-3.0.9/drivers/regulator/mc13892-regulator.c ---- linux-3.0.9/drivers/regulator/mc13892-regulator.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/regulator/mc13892-regulator.c 2011-11-12 12:47:14.000000000 -0500 -@@ -564,10 +564,12 @@ static int __devinit mc13892_regulator_p +diff --git a/drivers/regulator/mc13892-regulator.c b/drivers/regulator/mc13892-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(struct platform_device *pdev) } mc13xxx_unlock(mc13892); @@ -33523,9 +34426,10 @@ diff -urNp linux-3.0.9/drivers/regulator/mc13892-regulator.c linux-3.0.9/drivers for (i = 0; i < pdata->num_regulators; i++) { init_data = &pdata->regulators[i]; priv->regulators[i] = regulator_register( -diff -urNp linux-3.0.9/drivers/rtc/rtc-dev.c linux-3.0.9/drivers/rtc/rtc-dev.c ---- linux-3.0.9/drivers/rtc/rtc-dev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/rtc/rtc-dev.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/module.h> #include <linux/rtc.h> @@ -33534,7 +34438,7 @@ diff -urNp linux-3.0.9/drivers/rtc/rtc-dev.c linux-3.0.9/drivers/rtc/rtc-dev.c #include "rtc-core.h" 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; @@ -33543,9 +34447,23 @@ diff -urNp linux-3.0.9/drivers/rtc/rtc-dev.c linux-3.0.9/drivers/rtc/rtc-dev.c return rtc_set_time(rtc, &tm); case RTC_PIE_ON: -diff -urNp linux-3.0.9/drivers/scsi/aacraid/aacraid.h linux-3.0.9/drivers/scsi/aacraid/aacraid.h ---- linux-3.0.9/drivers/scsi/aacraid/aacraid.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/aacraid/aacraid.h 2011-11-12 12:47:14.000000000 -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_InitializeFlashPointProbeInfo(struct BusLogic_HostAda + static void __init BusLogic_InitializeProbeInfoList(struct BusLogic_HostAdapter + *PrototypeHostAdapter) + { ++ pax_track_stack(); ++ + /* + If a PCI BIOS is present, interrogate it for MultiMaster and FlashPoint + Host Adapters; otherwise, default to the standard ISA MultiMaster probe. +diff --git a/drivers/scsi/aacraid/aacraid.h b/drivers/scsi/aacraid/aacraid.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 */ @@ -33555,10 +34473,11 @@ diff -urNp linux-3.0.9/drivers/scsi/aacraid/aacraid.h linux-3.0.9/drivers/scsi/a /* * Define which interrupt handler needs to be installed -diff -urNp linux-3.0.9/drivers/scsi/aacraid/commctrl.c linux-3.0.9/drivers/scsi/aacraid/commctrl.c ---- linux-3.0.9/drivers/scsi/aacraid/commctrl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/aacraid/commctrl.c 2011-11-12 12:47:14.000000000 -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/commctrl.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, void __user * arg) u32 actual_fibsize64, actual_fibsize = 0; int i; @@ -33566,10 +34485,11 @@ diff -urNp linux-3.0.9/drivers/scsi/aacraid/commctrl.c linux-3.0.9/drivers/scsi/ if (dev->in_reset) { dprintk((KERN_DEBUG"aacraid: send raw srb -EBUSY\n")); -diff -urNp linux-3.0.9/drivers/scsi/aacraid/linit.c linux-3.0.9/drivers/scsi/aacraid/linit.c ---- linux-3.0.9/drivers/scsi/aacraid/linit.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/aacraid/linit.c 2011-11-12 12:47:14.000000000 -0500 -@@ -92,7 +92,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_ +diff --git a/drivers/scsi/aacraid/linit.c b/drivers/scsi/aacraid/linit.c +index 3382475..9c8d000 100644 +--- a/drivers/scsi/aacraid/linit.c ++++ b/drivers/scsi/aacraid/linit.c +@@ -92,7 +92,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_tbl) = { #elif defined(__devinitconst) static const struct pci_device_id aac_pci_tbl[] __devinitconst = { #else @@ -33578,10 +34498,11 @@ diff -urNp linux-3.0.9/drivers/scsi/aacraid/linit.c linux-3.0.9/drivers/scsi/aac #endif { 0x1028, 0x0001, 0x1028, 0x0001, 0, 0, 0 }, /* PERC 2/Si (Iguana/PERC2Si) */ { 0x1028, 0x0002, 0x1028, 0x0002, 0, 0, 1 }, /* PERC 3/Di (Opal/PERC3Di) */ -diff -urNp linux-3.0.9/drivers/scsi/aic94xx/aic94xx_init.c linux-3.0.9/drivers/scsi/aic94xx/aic94xx_init.c ---- linux-3.0.9/drivers/scsi/aic94xx/aic94xx_init.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/aic94xx/aic94xx_init.c 2011-11-12 12:47:14.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 = { .lldd_control_phy = asd_control_phy, }; @@ -33590,22 +34511,24 @@ diff -urNp linux-3.0.9/drivers/scsi/aic94xx/aic94xx_init.c linux-3.0.9/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.0.9/drivers/scsi/bfa/bfad.c linux-3.0.9/drivers/scsi/bfa/bfad.c ---- linux-3.0.9/drivers/scsi/bfa/bfad.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/bfa/bfad.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1032,6 +1032,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 7be6b5a..8f4ca40 100644 +--- a/drivers/scsi/bfa/bfa.h ++++ b/drivers/scsi/bfa/bfa.h +@@ -238,7 +238,7 @@ struct bfa_hwif_s { + u32 *nvecs, u32 *maxvec); + void (*hw_msix_get_rme_range) (struct bfa_s *bfa, u32 *start, + u32 *end); +-}; ++} __no_const; + typedef void (*bfa_cb_iocfc_t) (void *cbarg, enum bfa_status status); -+ pax_track_stack(); -+ - /* Fill the driver_info info to fcs*/ - memset(&driver_info, 0, sizeof(driver_info)); - strncpy(driver_info.version, BFAD_DRIVER_VERSION, -diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa_fcs_lport.c linux-3.0.9/drivers/scsi/bfa/bfa_fcs_lport.c ---- linux-3.0.9/drivers/scsi/bfa/bfa_fcs_lport.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/bfa/bfa_fcs_lport.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1559,6 +1559,8 @@ bfa_fcs_lport_fdmi_build_rhba_pyld(struc + struct bfa_iocfc_s { +diff --git a/drivers/scsi/bfa/bfa_fcs_lport.c b/drivers/scsi/bfa/bfa_fcs_lport.c +index 1d6be8c..38ceebc 100644 +--- a/drivers/scsi/bfa/bfa_fcs_lport.c ++++ b/drivers/scsi/bfa/bfa_fcs_lport.c +@@ -1559,6 +1559,8 @@ bfa_fcs_lport_fdmi_build_rhba_pyld(struct bfa_fcs_lport_fdmi_s *fdmi, u8 *pyld) u16 len, count; u16 templen; @@ -33614,7 +34537,7 @@ diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa_fcs_lport.c linux-3.0.9/drivers/scsi /* * get hba attributes */ -@@ -1836,6 +1838,8 @@ bfa_fcs_lport_fdmi_build_portattr_block( +@@ -1836,6 +1838,8 @@ bfa_fcs_lport_fdmi_build_portattr_block(struct bfa_fcs_lport_fdmi_s *fdmi, u8 count = 0; u16 templen; @@ -33623,10 +34546,11 @@ diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa_fcs_lport.c linux-3.0.9/drivers/scsi /* * get port attributes */ -diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa_fcs_rport.c linux-3.0.9/drivers/scsi/bfa/bfa_fcs_rport.c ---- linux-3.0.9/drivers/scsi/bfa/bfa_fcs_rport.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/bfa/bfa_fcs_rport.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1844,6 +1844,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 caaee6f..efce56b 100644 +--- a/drivers/scsi/bfa/bfa_fcs_rport.c ++++ b/drivers/scsi/bfa/bfa_fcs_rport.c +@@ -1844,6 +1844,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; @@ -33635,21 +34559,10 @@ diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa_fcs_rport.c linux-3.0.9/drivers/scsi bfa_trc(port->fcs, rx_fchs->s_id); bfa_trc(port->fcs, rx_fchs->d_id); -diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa.h linux-3.0.9/drivers/scsi/bfa/bfa.h ---- linux-3.0.9/drivers/scsi/bfa/bfa.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/bfa/bfa.h 2011-11-12 12:47:14.000000000 -0500 -@@ -238,7 +238,7 @@ struct bfa_hwif_s { - u32 *nvecs, u32 *maxvec); - void (*hw_msix_get_rme_range) (struct bfa_s *bfa, u32 *start, - u32 *end); --}; -+} __no_const; - typedef void (*bfa_cb_iocfc_t) (void *cbarg, enum bfa_status status); - - struct bfa_iocfc_s { -diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa_ioc.h linux-3.0.9/drivers/scsi/bfa/bfa_ioc.h ---- linux-3.0.9/drivers/scsi/bfa/bfa_ioc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/bfa/bfa_ioc.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/scsi/bfa/bfa_ioc.h b/drivers/scsi/bfa/bfa_ioc.h +index c85182a..fc0d4c0 100644 +--- a/drivers/scsi/bfa/bfa_ioc.h ++++ b/drivers/scsi/bfa/bfa_ioc.h @@ -196,7 +196,7 @@ struct bfa_ioc_cbfn_s { bfa_ioc_disable_cbfn_t disable_cbfn; bfa_ioc_hbfail_cbfn_t hbfail_cbfn; @@ -33668,22 +34581,24 @@ diff -urNp linux-3.0.9/drivers/scsi/bfa/bfa_ioc.h linux-3.0.9/drivers/scsi/bfa/b #define bfa_ioc_pcifn(__ioc) ((__ioc)->pcidev.pci_func) #define bfa_ioc_devid(__ioc) ((__ioc)->pcidev.device_id) -diff -urNp linux-3.0.9/drivers/scsi/BusLogic.c linux-3.0.9/drivers/scsi/BusLogic.c ---- linux-3.0.9/drivers/scsi/BusLogic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/BusLogic.c 2011-11-12 12:47:14.000000000 -0500 -@@ -962,6 +962,8 @@ static int __init BusLogic_InitializeFla - static void __init BusLogic_InitializeProbeInfoList(struct BusLogic_HostAdapter - *PrototypeHostAdapter) - { +diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c +index 59b5e9b..03a2bc1 100644 +--- a/drivers/scsi/bfa/bfad.c ++++ b/drivers/scsi/bfa/bfad.c +@@ -1032,6 +1032,8 @@ bfad_start_ops(struct bfad_s *bfad) { + struct bfad_vport_s *vport, *vport_new; + struct bfa_fcs_driver_info_s driver_info; + + pax_track_stack(); + - /* - If a PCI BIOS is present, interrogate it for MultiMaster and FlashPoint - Host Adapters; otherwise, default to the standard ISA MultiMaster probe. -diff -urNp linux-3.0.9/drivers/scsi/dpt_i2o.c linux-3.0.9/drivers/scsi/dpt_i2o.c ---- linux-3.0.9/drivers/scsi/dpt_i2o.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/dpt_i2o.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1811,6 +1811,8 @@ static int adpt_i2o_passthru(adpt_hba* p + /* Fill the driver_info info to fcs*/ + memset(&driver_info, 0, sizeof(driver_info)); + strncpy(driver_info.version, BFAD_DRIVER_VERSION, +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 = 0; @@ -33692,7 +34607,7 @@ diff -urNp linux-3.0.9/drivers/scsi/dpt_i2o.c linux-3.0.9/drivers/scsi/dpt_i2o.c memset(&msg, 0, MAX_MESSAGE_SIZE*4); // get user msg size in u32s 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; @@ -33701,10 +34616,11 @@ diff -urNp linux-3.0.9/drivers/scsi/dpt_i2o.c linux-3.0.9/drivers/scsi/dpt_i2o.c memset(msg, 0 , sizeof(msg)); len = scsi_bufflen(cmd); direction = 0x00000000; -diff -urNp linux-3.0.9/drivers/scsi/eata.c linux-3.0.9/drivers/scsi/eata.c ---- linux-3.0.9/drivers/scsi/eata.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/eata.c 2011-11-12 12:47:14.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, unsigned int j, struct hostdata *ha; char name[16]; @@ -33713,10 +34629,11 @@ diff -urNp linux-3.0.9/drivers/scsi/eata.c linux-3.0.9/drivers/scsi/eata.c sprintf(name, "%s%d", driver_name, j); if (!request_region(port_base, REGION_SIZE, driver_name)) { -diff -urNp linux-3.0.9/drivers/scsi/fcoe/fcoe_ctlr.c linux-3.0.9/drivers/scsi/fcoe/fcoe_ctlr.c ---- linux-3.0.9/drivers/scsi/fcoe/fcoe_ctlr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/fcoe/fcoe_ctlr.c 2011-11-12 12:47:14.000000000 -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; @@ -33725,9 +34642,10 @@ diff -urNp linux-3.0.9/drivers/scsi/fcoe/fcoe_ctlr.c linux-3.0.9/drivers/scsi/fc fiph = (struct fip_header *)skb->data; sub = fiph->fip_subcode; -diff -urNp linux-3.0.9/drivers/scsi/gdth.c linux-3.0.9/drivers/scsi/gdth.c ---- linux-3.0.9/drivers/scsi/gdth.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/gdth.c 2011-11-12 12:47:14.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; @@ -33737,7 +34655,7 @@ diff -urNp linux-3.0.9/drivers/scsi/gdth.c linux-3.0.9/drivers/scsi/gdth.c if (copy_from_user(&ldrv, arg, sizeof(gdth_ioctl_lockdrv))) return -EFAULT; ha = 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 *cmnd) gdth_ha_str *ha; int rval; @@ -33746,7 +34664,7 @@ diff -urNp linux-3.0.9/drivers/scsi/gdth.c linux-3.0.9/drivers/scsi/gdth.c if (copy_from_user(&res, arg, sizeof(gdth_ioctl_reset)) || res.number >= 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 *cmnd) gdth_ha_str *ha; int rval; @@ -33765,10 +34683,11 @@ diff -urNp linux-3.0.9/drivers/scsi/gdth.c linux-3.0.9/drivers/scsi/gdth.c memset(cmnd, 0xff, MAX_COMMAND_SIZE); TRACE2(("gdth_flush() hanum %d\n", ha->hanum)); -diff -urNp linux-3.0.9/drivers/scsi/gdth_proc.c linux-3.0.9/drivers/scsi/gdth_proc.c ---- linux-3.0.9/drivers/scsi/gdth_proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/gdth_proc.c 2011-11-12 12:47:14.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, char *buffer, u64 paddr; char cmnd[MAX_COMMAND_SIZE]; @@ -33778,7 +34697,7 @@ diff -urNp linux-3.0.9/drivers/scsi/gdth_proc.c linux-3.0.9/drivers/scsi/gdth_pr memset(cmnd, 0xff, 12); memset(&gdtcmd, 0, sizeof(gdth_cmd_str)); -@@ -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,off_t offset,int length, gdth_hget_str *phg; char cmnd[MAX_COMMAND_SIZE]; @@ -33787,9 +34706,10 @@ diff -urNp linux-3.0.9/drivers/scsi/gdth_proc.c linux-3.0.9/drivers/scsi/gdth_pr gdtcmd = kmalloc(sizeof(*gdtcmd), GFP_KERNEL); estr = kmalloc(sizeof(*estr), GFP_KERNEL); if (!gdtcmd || !estr) -diff -urNp linux-3.0.9/drivers/scsi/hosts.c linux-3.0.9/drivers/scsi/hosts.c ---- linux-3.0.9/drivers/scsi/hosts.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/hosts.c 2011-11-12 12:47:14.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" @@ -33799,7 +34719,7 @@ diff -urNp linux-3.0.9/drivers/scsi/hosts.c linux-3.0.9/drivers/scsi/hosts.c 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_template *sht, int privsize) * subtract one because we increment first then return, but we need to * know what the next host number was before increment */ @@ -33808,10 +34728,11 @@ diff -urNp linux-3.0.9/drivers/scsi/hosts.c linux-3.0.9/drivers/scsi/hosts.c shost->dma_channel = 0xff; /* These three are default values which can be overridden */ -diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c ---- linux-3.0.9/drivers/scsi/hpsa.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/hpsa.c 2011-11-12 12:47:14.000000000 -0500 -@@ -498,7 +498,7 @@ static inline u32 next_command(struct ct +diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c +index 6689d5d..9cbea58 100644 +--- a/drivers/scsi/hpsa.c ++++ b/drivers/scsi/hpsa.c +@@ -498,7 +498,7 @@ static inline u32 next_command(struct ctlr_info *h) u32 a; if (unlikely(!(h->transMethod & CFGTBL_Trans_Performant))) @@ -33820,7 +34741,7 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c if ((*(h->reply_pool_head) & 1) == (h->reply_pool_wraparound)) { a = *(h->reply_pool_head); /* Next cmd in ring buffer */ -@@ -2955,7 +2955,7 @@ static void start_io(struct ctlr_info *h +@@ -2955,7 +2955,7 @@ static void start_io(struct ctlr_info *h) while (!list_empty(&h->reqQ)) { c = list_entry(h->reqQ.next, struct CommandList, list); /* can't do anything if fifo is full */ @@ -33829,7 +34750,7 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c dev_warn(&h->pdev->dev, "fifo full\n"); break; } -@@ -2965,7 +2965,7 @@ static void start_io(struct ctlr_info *h +@@ -2965,7 +2965,7 @@ static void start_io(struct ctlr_info *h) h->Qdepth--; /* Tell the controller execute command */ @@ -33838,7 +34759,7 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c /* Put job onto the completed Q */ addQ(&h->cmpQ, c); -@@ -2974,17 +2974,17 @@ static void start_io(struct ctlr_info *h +@@ -2974,17 +2974,17 @@ static void start_io(struct ctlr_info *h) static inline unsigned long get_next_completion(struct ctlr_info *h) { @@ -33859,7 +34780,7 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c (h->interrupts_enabled == 0); } -@@ -3881,7 +3881,7 @@ static int __devinit hpsa_pci_init(struc +@@ -3881,7 +3881,7 @@ static int __devinit hpsa_pci_init(struct ctlr_info *h) if (prod_index < 0) return -ENODEV; h->product_name = products[prod_index].product_name; @@ -33907,7 +34828,7 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c hpsa_hba_inquiry(h); hpsa_register_scsi(h); /* hook ourselves into SCSI subsystem */ -@@ -4287,7 +4287,7 @@ static void hpsa_shutdown(struct pci_dev +@@ -4287,7 +4287,7 @@ static void hpsa_shutdown(struct pci_dev *pdev) * To write all data in the battery backed cache to disks */ hpsa_flush_cache(h); @@ -33916,7 +34837,7 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c free_irq(h->intr[h->intr_mode], h); #ifdef CONFIG_PCI_MSI if (h->msix_vector) -@@ -4450,7 +4450,7 @@ static __devinit void hpsa_enter_perform +@@ -4450,7 +4450,7 @@ static __devinit void hpsa_enter_performant_mode(struct ctlr_info *h, return; } /* Change the access methods to the performant access methods */ @@ -33925,9 +34846,10 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.c linux-3.0.9/drivers/scsi/hpsa.c h->transMethod = CFGTBL_Trans_Performant; } -diff -urNp linux-3.0.9/drivers/scsi/hpsa.h linux-3.0.9/drivers/scsi/hpsa.h ---- linux-3.0.9/drivers/scsi/hpsa.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/hpsa.h 2011-11-12 12:47:14.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; @@ -33937,9 +34859,10 @@ diff -urNp linux-3.0.9/drivers/scsi/hpsa.h linux-3.0.9/drivers/scsi/hpsa.h /* queue and queue Info */ struct list_head reqQ; -diff -urNp linux-3.0.9/drivers/scsi/ips.h linux-3.0.9/drivers/scsi/ips.h ---- linux-3.0.9/drivers/scsi/ips.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/ips.h 2011-11-12 12:47:14.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 *); @@ -33949,9 +34872,10 @@ diff -urNp linux-3.0.9/drivers/scsi/ips.h linux-3.0.9/drivers/scsi/ips.h typedef struct ips_ha { uint8_t ha_id[IPS_MAX_CHANNELS+1]; -diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/libfc/fc_exch.c ---- linux-3.0.9/drivers/scsi/libfc/fc_exch.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/libfc/fc_exch.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/scsi/libfc/fc_exch.c b/drivers/scsi/libfc/fc_exch.c +index 3b8a645..8455110 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 */ @@ -33971,7 +34895,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib } stats; }; -@@ -700,7 +700,7 @@ static struct fc_exch *fc_exch_em_alloc( +@@ -700,7 +700,7 @@ static struct fc_exch *fc_exch_em_alloc(struct fc_lport *lport, /* allocate memory for exchange */ ep = mempool_alloc(mp->ep_pool, GFP_ATOMIC); if (!ep) { @@ -33989,7 +34913,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib mempool_free(ep, mp->ep_pool); return NULL; } -@@ -906,7 +906,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -906,7 +906,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(struct fc_lport *lport, xid = ntohs(fh->fh_ox_id); /* we originated exch */ ep = fc_exch_find(mp, xid); if (!ep) { @@ -33998,7 +34922,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib reject = FC_RJT_OX_ID; goto out; } -@@ -936,7 +936,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -936,7 +936,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(struct fc_lport *lport, ep = fc_exch_find(mp, xid); if ((f_ctl & FC_FC_FIRST_SEQ) && fc_sof_is_init(fr_sof(fp))) { if (ep) { @@ -34007,7 +34931,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib reject = FC_RJT_RX_ID; goto rel; } -@@ -947,7 +947,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -947,7 +947,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(struct fc_lport *lport, } xid = ep->xid; /* get our XID */ } else if (!ep) { @@ -34016,7 +34940,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib reject = FC_RJT_RX_ID; /* XID not found */ goto out; } -@@ -964,7 +964,7 @@ static enum fc_pf_rjt_reason fc_seq_look +@@ -964,7 +964,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(struct fc_lport *lport, } else { sp = &ep->seq; if (sp->id != fh->fh_seq_id) { @@ -34025,7 +34949,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib reject = FC_RJT_SEQ_ID; /* sequence/exch should exist */ goto rel; } -@@ -1392,22 +1392,22 @@ static void fc_exch_recv_seq_resp(struct +@@ -1392,22 +1392,22 @@ static void fc_exch_recv_seq_resp(struct fc_exch_mgr *mp, struct fc_frame *fp) ep = fc_exch_find(mp, ntohs(fh->fh_ox_id)); if (!ep) { @@ -34052,7 +34976,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib goto rel; } sof = fr_sof(fp); -@@ -1416,7 +1416,7 @@ static void fc_exch_recv_seq_resp(struct +@@ -1416,7 +1416,7 @@ static void fc_exch_recv_seq_resp(struct fc_exch_mgr *mp, struct fc_frame *fp) sp->ssb_stat |= SSB_ST_RESP; sp->id = fh->fh_seq_id; } else if (sp->id != fh->fh_seq_id) { @@ -34061,7 +34985,7 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib goto rel; } -@@ -1480,9 +1480,9 @@ static void fc_exch_recv_resp(struct fc_ +@@ -1480,9 +1480,9 @@ static void fc_exch_recv_resp(struct fc_exch_mgr *mp, struct fc_frame *fp) sp = fc_seq_lookup_orig(mp, fp); /* doesn't hold sequence */ if (!sp) @@ -34073,10 +34997,11 @@ diff -urNp linux-3.0.9/drivers/scsi/libfc/fc_exch.c linux-3.0.9/drivers/scsi/lib fc_frame_free(fp); } -diff -urNp linux-3.0.9/drivers/scsi/libsas/sas_ata.c linux-3.0.9/drivers/scsi/libsas/sas_ata.c ---- linux-3.0.9/drivers/scsi/libsas/sas_ata.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/libsas/sas_ata.c 2011-11-12 12:47:14.000000000 -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 = { .postreset = ata_std_postreset, .error_handler = ata_std_error_handler, .post_internal_cmd = sas_ata_post_internal, @@ -34085,10 +35010,44 @@ diff -urNp linux-3.0.9/drivers/scsi/libsas/sas_ata.c linux-3.0.9/drivers/scsi/li .qc_prep = ata_noop_qc_prep, .qc_issue = sas_ata_qc_issue, .qc_fill_rtf = sas_ata_qc_fill_rtf, -diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c ---- linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -104,7 +104,7 @@ MODULE_PARM_DESC(lpfc_debugfs_mask_disc_ +diff --git a/drivers/scsi/lpfc/lpfc.h b/drivers/scsi/lpfc/lpfc.h +index 0441361..f2564e4 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; +@@ -832,8 +832,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; +@@ -847,7 +847,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_debugfs.c +index ffe82d1..108b526 100644 +--- a/drivers/scsi/lpfc/lpfc_debugfs.c ++++ b/drivers/scsi/lpfc/lpfc_debugfs.c +@@ -104,7 +104,7 @@ MODULE_PARM_DESC(lpfc_debugfs_mask_disc_trc, #include <linux/debugfs.h> @@ -34097,7 +35056,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi static unsigned long lpfc_debugfs_start_time = 0L; /* iDiag */ -@@ -141,7 +141,7 @@ lpfc_debugfs_disc_trc_data(struct lpfc_v +@@ -141,7 +141,7 @@ lpfc_debugfs_disc_trc_data(struct lpfc_vport *vport, char *buf, int size) lpfc_debugfs_enable = 0; len = 0; @@ -34106,7 +35065,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi (lpfc_debugfs_max_disc_trc - 1); for (i = index; i < lpfc_debugfs_max_disc_trc; i++) { dtp = vport->disc_trc + i; -@@ -202,7 +202,7 @@ lpfc_debugfs_slow_ring_trc_data(struct l +@@ -202,7 +202,7 @@ lpfc_debugfs_slow_ring_trc_data(struct lpfc_hba *phba, char *buf, int size) lpfc_debugfs_enable = 0; len = 0; @@ -34115,7 +35074,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi (lpfc_debugfs_max_slow_ring_trc - 1); for (i = index; i < lpfc_debugfs_max_slow_ring_trc; i++) { dtp = phba->slow_ring_trc + i; -@@ -380,6 +380,8 @@ lpfc_debugfs_dumpHBASlim_data(struct lpf +@@ -380,6 +380,8 @@ lpfc_debugfs_dumpHBASlim_data(struct lpfc_hba *phba, char *buf, int size) uint32_t *ptr; char buffer[1024]; @@ -34124,7 +35083,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi off = 0; spin_lock_irq(&phba->hbalock); -@@ -617,14 +619,14 @@ lpfc_debugfs_disc_trc(struct lpfc_vport +@@ -617,14 +619,14 @@ lpfc_debugfs_disc_trc(struct lpfc_vport *vport, int mask, char *fmt, !vport || !vport->disc_trc) return; @@ -34141,7 +35100,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi dtp->jif = jiffies; #endif return; -@@ -655,14 +657,14 @@ lpfc_debugfs_slow_ring_trc(struct lpfc_h +@@ -655,14 +657,14 @@ lpfc_debugfs_slow_ring_trc(struct lpfc_hba *phba, char *fmt, !phba || !phba->slow_ring_trc) return; @@ -34158,7 +35117,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi dtp->jif = jiffies; #endif return; -@@ -2606,7 +2608,7 @@ lpfc_debugfs_initialize(struct lpfc_vpor +@@ -2606,7 +2608,7 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport) "slow_ring buffer\n"); goto debug_failed; } @@ -34167,7 +35126,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi memset(phba->slow_ring_trc, 0, (sizeof(struct lpfc_debugfs_trc) * lpfc_debugfs_max_slow_ring_trc)); -@@ -2652,7 +2654,7 @@ lpfc_debugfs_initialize(struct lpfc_vpor +@@ -2652,7 +2654,7 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport) "buffer\n"); goto debug_failed; } @@ -34176,41 +35135,10 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_debugfs.c linux-3.0.9/drivers/scsi snprintf(name, sizeof(name), "discovery_trace"); vport->debug_disc_trc = -diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc.h linux-3.0.9/drivers/scsi/lpfc/lpfc.h ---- linux-3.0.9/drivers/scsi/lpfc/lpfc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/lpfc/lpfc.h 2011-11-12 12:47:14.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; -@@ -832,8 +832,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; -@@ -847,7 +847,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.0.9/drivers/scsi/lpfc/lpfc_init.c linux-3.0.9/drivers/scsi/lpfc/lpfc_init.c ---- linux-3.0.9/drivers/scsi/lpfc/lpfc_init.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/lpfc/lpfc_init.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c +index 027b797..8c56376 100644 +--- a/drivers/scsi/lpfc/lpfc_init.c ++++ b/drivers/scsi/lpfc/lpfc_init.c @@ -9971,8 +9971,10 @@ lpfc_init(void) printk(LPFC_COPYRIGHT "\n"); @@ -34224,10 +35152,11 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_init.c linux-3.0.9/drivers/scsi/lp } lpfc_transport_template = fc_attach_transport(&lpfc_transport_functions); -diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c ---- linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c 2011-11-12 12:47:14.000000000 -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; spin_lock_irqsave(&phba->hbalock, flags); @@ -34236,7 +35165,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c linux-3.0.9/drivers/scsi/lp phba->last_rsrc_error_time = jiffies; 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 = vport->phba; uint32_t evt_posted; @@ -34245,7 +35174,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c linux-3.0.9/drivers/scsi/lp if (vport->cfg_lun_queue_depth <= 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; @@ -34256,7 +35185,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c linux-3.0.9/drivers/scsi/lp vports = lpfc_create_vport_work_array(phba); if (vports != 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); @@ -34267,7 +35196,7 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c linux-3.0.9/drivers/scsi/lp } /** -@@ -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); @@ -34278,10 +35207,11 @@ diff -urNp linux-3.0.9/drivers/scsi/lpfc/lpfc_scsi.c linux-3.0.9/drivers/scsi/lp } /** -diff -urNp linux-3.0.9/drivers/scsi/megaraid/megaraid_mbox.c linux-3.0.9/drivers/scsi/megaraid/megaraid_mbox.c ---- linux-3.0.9/drivers/scsi/megaraid/megaraid_mbox.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/megaraid/megaraid_mbox.c 2011-11-12 12:47:14.000000000 -0500 -@@ -3503,6 +3503,8 @@ megaraid_cmm_register(adapter_t *adapter +diff --git a/drivers/scsi/megaraid/megaraid_mbox.c b/drivers/scsi/megaraid/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; @@ -34290,10 +35220,11 @@ diff -urNp linux-3.0.9/drivers/scsi/megaraid/megaraid_mbox.c linux-3.0.9/drivers // Allocate memory for the base list of scb for management module. adapter->uscb_list = kcalloc(MBOX_MAX_USER_CMDS, sizeof(scb_t), GFP_KERNEL); -diff -urNp linux-3.0.9/drivers/scsi/osd/osd_initiator.c linux-3.0.9/drivers/scsi/osd/osd_initiator.c ---- linux-3.0.9/drivers/scsi/osd/osd_initiator.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/osd/osd_initiator.c 2011-11-12 12:47:14.000000000 -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_initiator.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 = ARRAY_SIZE(get_attrs), a = 0; int ret; @@ -34302,10 +35233,11 @@ diff -urNp linux-3.0.9/drivers/scsi/osd/osd_initiator.c linux-3.0.9/drivers/scsi or = osd_start_request(od, GFP_KERNEL); if (!or) return -ENOMEM; -diff -urNp linux-3.0.9/drivers/scsi/pmcraid.c linux-3.0.9/drivers/scsi/pmcraid.c ---- linux-3.0.9/drivers/scsi/pmcraid.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/pmcraid.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 *scsi_dev) res->scsi_dev = scsi_dev; scsi_dev->hostdata = res; res->change_detected = 0; @@ -34316,7 +35248,7 @@ diff -urNp linux-3.0.9/drivers/scsi/pmcraid.c linux-3.0.9/drivers/scsi/pmcraid.c rc = 0; } spin_unlock_irqrestore(&pinstance->resource_lock, lock_flags); -@@ -2677,9 +2677,9 @@ static int pmcraid_error_handler(struct +@@ -2677,9 +2677,9 @@ static int pmcraid_error_handler(struct pmcraid_cmd *cmd) /* If this was a SCSI read/write command keep count of errors */ if (SCSI_CMD_TYPE(scsi_cmd->cmnd[0]) == SCSI_READ_CMD) @@ -34346,7 +35278,7 @@ diff -urNp linux-3.0.9/drivers/scsi/pmcraid.c linux-3.0.9/drivers/scsi/pmcraid.c pinstance->num_hrrq; if (request_size) { -@@ -4498,7 +4498,7 @@ static void pmcraid_worker_function(stru +@@ -4498,7 +4498,7 @@ static void pmcraid_worker_function(struct work_struct *workp) pinstance = container_of(workp, struct pmcraid_instance, worker_q); /* add resources only after host is added into system */ @@ -34355,7 +35287,7 @@ diff -urNp linux-3.0.9/drivers/scsi/pmcraid.c linux-3.0.9/drivers/scsi/pmcraid.c return; fw_version = 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); atomic_set(&pinstance->outstanding_cmds, 0); @@ -34375,9 +35307,10 @@ diff -urNp linux-3.0.9/drivers/scsi/pmcraid.c linux-3.0.9/drivers/scsi/pmcraid.c schedule_work(&pinstance->worker_q); return rc; -diff -urNp linux-3.0.9/drivers/scsi/pmcraid.h linux-3.0.9/drivers/scsi/pmcraid.h ---- linux-3.0.9/drivers/scsi/pmcraid.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/pmcraid.h 2011-11-12 12:47:14.000000000 -0500 +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]; @@ -34407,9 +35340,10 @@ diff -urNp linux-3.0.9/drivers/scsi/pmcraid.h linux-3.0.9/drivers/scsi/pmcraid.h /* To indicate add/delete/modify during CCN */ u8 change_detected; -diff -urNp linux-3.0.9/drivers/scsi/qla2xxx/qla_def.h linux-3.0.9/drivers/scsi/qla2xxx/qla_def.h ---- linux-3.0.9/drivers/scsi/qla2xxx/qla_def.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/qla2xxx/qla_def.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h +index cc5a792..033f807 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 *); @@ -34419,9 +35353,10 @@ diff -urNp linux-3.0.9/drivers/scsi/qla2xxx/qla_def.h linux-3.0.9/drivers/scsi/q /* MSI-X Support *************************************************************/ -diff -urNp linux-3.0.9/drivers/scsi/qla4xxx/ql4_def.h linux-3.0.9/drivers/scsi/qla4xxx/ql4_def.h ---- linux-3.0.9/drivers/scsi/qla4xxx/ql4_def.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/qla4xxx/ql4_def.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/scsi/qla4xxx/ql4_def.h b/drivers/scsi/qla4xxx/ql4_def.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) */ @@ -34431,10 +35366,11 @@ diff -urNp linux-3.0.9/drivers/scsi/qla4xxx/ql4_def.h linux-3.0.9/drivers/scsi/q * retried */ uint16_t port; -diff -urNp linux-3.0.9/drivers/scsi/qla4xxx/ql4_init.c linux-3.0.9/drivers/scsi/qla4xxx/ql4_init.c ---- linux-3.0.9/drivers/scsi/qla4xxx/ql4_init.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/qla4xxx/ql4_init.c 2011-11-12 12:47:14.000000000 -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 scsi_qla_host *ha, ddb_entry->fw_ddb_index = fw_ddb_index; atomic_set(&ddb_entry->retry_relogin_timer, INVALID_ENTRY); atomic_set(&ddb_entry->relogin_timer, 0); @@ -34443,7 +35379,7 @@ diff -urNp linux-3.0.9/drivers/scsi/qla4xxx/ql4_init.c linux-3.0.9/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] = 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_host *ha, uint32_t fw_ddb_index, if ((ddb_entry->fw_ddb_device_state == DDB_DS_SESSION_ACTIVE) && (atomic_read(&ddb_entry->state) != DDB_STATE_ONLINE)) { atomic_set(&ddb_entry->state, DDB_STATE_ONLINE); @@ -34452,10 +35388,11 @@ diff -urNp linux-3.0.9/drivers/scsi/qla4xxx/ql4_init.c linux-3.0.9/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.0.9/drivers/scsi/qla4xxx/ql4_os.c linux-3.0.9/drivers/scsi/qla4xxx/ql4_os.c ---- linux-3.0.9/drivers/scsi/qla4xxx/ql4_os.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/qla4xxx/ql4_os.c 2011-11-12 12:47:14.000000000 -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 == DDB_DS_SESSION_FAILED) { /* Reset retry relogin timer */ @@ -34471,10 +35408,11 @@ diff -urNp linux-3.0.9/drivers/scsi/qla4xxx/ql4_os.c linux-3.0.9/drivers/scsi/ql relogin_retry_count)) ); start_dpc++; -diff -urNp linux-3.0.9/drivers/scsi/scsi.c linux-3.0.9/drivers/scsi/scsi.c ---- linux-3.0.9/drivers/scsi/scsi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi.c 2011-11-12 12:47:14.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 = 0; @@ -34483,10 +35421,11 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi.c linux-3.0.9/drivers/scsi/scsi.c /* check if the device is still usable */ if (unlikely(cmd->device->sdev_state == SDEV_DEL)) { -diff -urNp linux-3.0.9/drivers/scsi/scsi_debug.c linux-3.0.9/drivers/scsi/scsi_debug.c ---- linux-3.0.9/drivers/scsi/scsi_debug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi_debug.c 2011-11-12 12:47:14.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 = (unsigned char *)scp->cmnd; @@ -34495,7 +35434,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_debug.c linux-3.0.9/drivers/scsi/scsi_d if ((errsts = 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 = (unsigned char *)scp->cmnd; @@ -34504,10 +35443,11 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_debug.c linux-3.0.9/drivers/scsi/scsi_d if ((errsts = check_readiness(scp, 1, devip))) return errsts; memset(arr, 0, sizeof(arr)); -diff -urNp linux-3.0.9/drivers/scsi/scsi_lib.c linux-3.0.9/drivers/scsi/scsi_lib.c ---- linux-3.0.9/drivers/scsi/scsi_lib.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi_lib.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1412,7 +1412,7 @@ static void scsi_kill_request(struct req +diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c +index f97acff..0c53d1f 100644 +--- a/drivers/scsi/scsi_lib.c ++++ b/drivers/scsi/scsi_lib.c +@@ -1412,7 +1412,7 @@ static void scsi_kill_request(struct request *req, struct request_queue *q) shost = sdev->host; scsi_init_cmd_errh(cmd); cmd->result = DID_NO_CONNECT << 16; @@ -34516,7 +35456,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_lib.c linux-3.0.9/drivers/scsi/scsi_lib /* * SCSI request completion path will do scsi_device_unbusy(), -@@ -1438,9 +1438,9 @@ static void scsi_softirq_done(struct req +@@ -1438,9 +1438,9 @@ static void scsi_softirq_done(struct request *rq) INIT_LIST_HEAD(&cmd->eh_entry); @@ -34528,10 +35468,11 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_lib.c linux-3.0.9/drivers/scsi/scsi_lib disposition = scsi_decide_disposition(cmd); if (disposition != SUCCESS && -diff -urNp linux-3.0.9/drivers/scsi/scsi_sysfs.c linux-3.0.9/drivers/scsi/scsi_sysfs.c ---- linux-3.0.9/drivers/scsi/scsi_sysfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi_sysfs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -622,7 +622,7 @@ show_iostat_##field(struct device *dev, +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 device_attribute *attr, \ char *buf) \ { \ struct scsi_device *sdev = to_scsi_device(dev); \ @@ -34540,10 +35481,11 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_sysfs.c linux-3.0.9/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.0.9/drivers/scsi/scsi_tgt_lib.c linux-3.0.9/drivers/scsi/scsi_tgt_lib.c ---- linux-3.0.9/drivers/scsi/scsi_tgt_lib.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi_tgt_lib.c 2011-11-12 12:47:14.000000000 -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; dprintk("%lx %u\n", uaddr, len); @@ -34552,10 +35494,11 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_tgt_lib.c linux-3.0.9/drivers/scsi/scsi if (err) { /* * TODO: need to fixup sg_tablesize, max_segment_size, -diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_fc.c linux-3.0.9/drivers/scsi/scsi_transport_fc.c ---- linux-3.0.9/drivers/scsi/scsi_transport_fc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi_transport_fc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -484,7 +484,7 @@ static DECLARE_TRANSPORT_CLASS(fc_vport_ +diff --git a/drivers/scsi/scsi_transport_fc.c b/drivers/scsi/scsi_transport_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 */ @@ -34573,7 +35516,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_fc.c linux-3.0.9/drivers/scsi } EXPORT_SYMBOL(fc_get_event_number); -@@ -645,7 +645,7 @@ static __init int fc_transport_init(void +@@ -645,7 +645,7 @@ static __init int fc_transport_init(void) { int error; @@ -34582,7 +35525,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_fc.c linux-3.0.9/drivers/scsi error = 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, unsigned long *val) char *cp; *val = simple_strtoul(buf, &cp, 0); @@ -34591,9 +35534,10 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_fc.c linux-3.0.9/drivers/scsi return -EINVAL; /* * Check for overflow; dev_loss_tmo is u32 -diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_iscsi.c linux-3.0.9/drivers/scsi/scsi_transport_iscsi.c ---- linux-3.0.9/drivers/scsi/scsi_transport_iscsi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi_transport_iscsi.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_transport_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]; }; @@ -34603,7 +35547,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_iscsi.c linux-3.0.9/drivers/s static struct workqueue_struct *iscsi_eh_timer_workq; /* -@@ -761,7 +761,7 @@ int iscsi_add_session(struct iscsi_cls_s +@@ -761,7 +761,7 @@ int iscsi_add_session(struct iscsi_cls_session *session, unsigned int target_id) int err; ihost = shost->shost_data; @@ -34612,7 +35556,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_iscsi.c linux-3.0.9/drivers/s if (id == ISCSI_MAX_TARGET) { for (id = 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); @@ -34621,9 +35565,10 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_iscsi.c linux-3.0.9/drivers/s err = class_register(&iscsi_transport_class); if (err) -diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_srp.c linux-3.0.9/drivers/scsi/scsi_transport_srp.c ---- linux-3.0.9/drivers/scsi/scsi_transport_srp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/scsi_transport_srp.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/scsi/scsi_transport_srp.c b/drivers/scsi/scsi_transport_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" @@ -34633,7 +35578,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_srp.c linux-3.0.9/drivers/scs }; #define to_srp_host_attrs(host) ((struct srp_host_attrs *)(host)->shost_data) -@@ -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 = dev_to_shost(dev); struct srp_host_attrs *srp_host = to_srp_host_attrs(shost); @@ -34642,7 +35587,7 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_srp.c linux-3.0.9/drivers/scs return 0; } -@@ -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 *shost, memcpy(rport->port_id, ids->port_id, sizeof(rport->port_id)); rport->roles = ids->roles; @@ -34651,10 +35596,11 @@ diff -urNp linux-3.0.9/drivers/scsi/scsi_transport_srp.c linux-3.0.9/drivers/scs dev_set_name(&rport->dev, "port-%d:%d", shost->host_no, id); transport_setup_device(&rport->dev); -diff -urNp linux-3.0.9/drivers/scsi/sg.c linux-3.0.9/drivers/scsi/sg.c ---- linux-3.0.9/drivers/scsi/sg.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/sg.c 2011-11-12 12:47:14.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, unsigned long arg) sdp->disk->disk_name, MKDEV(SCSI_GENERIC_MAJOR, sdp->index), NULL, @@ -34681,10 +35627,11 @@ diff -urNp linux-3.0.9/drivers/scsi/sg.c linux-3.0.9/drivers/scsi/sg.c sg_proc_sgp = proc_mkdir(sg_proc_sg_dirname, NULL); if (!sg_proc_sgp) -diff -urNp linux-3.0.9/drivers/scsi/sym53c8xx_2/sym_glue.c linux-3.0.9/drivers/scsi/sym53c8xx_2/sym_glue.c ---- linux-3.0.9/drivers/scsi/sym53c8xx_2/sym_glue.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/sym53c8xx_2/sym_glue.c 2011-11-12 12:47:14.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/sym53c8xx_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 *pdev, int do_iounmap = 0; int do_disable_device = 1; @@ -34693,10 +35640,11 @@ diff -urNp linux-3.0.9/drivers/scsi/sym53c8xx_2/sym_glue.c linux-3.0.9/drivers/s memset(&sym_dev, 0, sizeof(sym_dev)); memset(&nvram, 0, sizeof(nvram)); sym_dev.pdev = pdev; -diff -urNp linux-3.0.9/drivers/scsi/vmw_pvscsi.c linux-3.0.9/drivers/scsi/vmw_pvscsi.c ---- linux-3.0.9/drivers/scsi/vmw_pvscsi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/scsi/vmw_pvscsi.c 2011-11-12 12:47:14.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 pvscsi_adapter *adapter) dma_addr_t base; unsigned i; @@ -34705,10 +35653,11 @@ diff -urNp linux-3.0.9/drivers/scsi/vmw_pvscsi.c linux-3.0.9/drivers/scsi/vmw_pv cmd.ringsStatePPN = adapter->ringStatePA >> PAGE_SHIFT; cmd.reqRingNumPages = adapter->req_pages; cmd.cmpRingNumPages = adapter->cmp_pages; -diff -urNp linux-3.0.9/drivers/spi/dw_spi_pci.c linux-3.0.9/drivers/spi/dw_spi_pci.c ---- linux-3.0.9/drivers/spi/dw_spi_pci.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/spi/dw_spi_pci.c 2011-11-12 12:47:14.000000000 -0500 -@@ -148,7 +148,7 @@ static int spi_resume(struct pci_dev *pd +diff --git a/drivers/spi/dw_spi_pci.c b/drivers/spi/dw_spi_pci.c +index ad260aa..42becbe 100644 +--- a/drivers/spi/dw_spi_pci.c ++++ b/drivers/spi/dw_spi_pci.c +@@ -148,7 +148,7 @@ static int spi_resume(struct pci_dev *pdev) #define spi_resume NULL #endif @@ -34717,10 +35666,11 @@ diff -urNp linux-3.0.9/drivers/spi/dw_spi_pci.c linux-3.0.9/drivers/spi/dw_spi_p /* Intel MID platform SPI controller 0 */ { PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x0800) }, {}, -diff -urNp linux-3.0.9/drivers/spi/spi.c linux-3.0.9/drivers/spi/spi.c ---- linux-3.0.9/drivers/spi/spi.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/spi/spi.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1023,7 +1023,7 @@ int spi_bus_unlock(struct spi_master *ma +diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c +index 2e13a14..50d2130 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); /* portable code must never pass more than 32 bytes */ @@ -34729,10 +35679,11 @@ diff -urNp linux-3.0.9/drivers/spi/spi.c linux-3.0.9/drivers/spi/spi.c static u8 *buf; -diff -urNp linux-3.0.9/drivers/staging/ath6kl/os/linux/ar6000_drv.c linux-3.0.9/drivers/staging/ath6kl/os/linux/ar6000_drv.c ---- linux-3.0.9/drivers/staging/ath6kl/os/linux/ar6000_drv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/ath6kl/os/linux/ar6000_drv.c 2011-11-12 12:47:14.000000000 -0500 -@@ -362,7 +362,7 @@ static struct ar_cookie s_ar_cookie_mem[ +diff --git a/drivers/staging/ath6kl/os/linux/ar6000_drv.c b/drivers/staging/ath6kl/os/linux/ar6000_drv.c +index 62487a7..ceca52a 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_NUM]; (((ar)->arTargetType == TARGET_TYPE_AR6003) ? AR6003_HOST_INTEREST_ITEM_ADDRESS(item) : 0)) @@ -34741,10 +35692,11 @@ diff -urNp linux-3.0.9/drivers/staging/ath6kl/os/linux/ar6000_drv.c linux-3.0.9/ .ndo_init = NULL, .ndo_open = ar6000_open, .ndo_stop = ar6000_close, -diff -urNp linux-3.0.9/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h linux-3.0.9/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h ---- linux-3.0.9/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h 2011-11-12 12:47:14.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/drivers/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; @@ -34753,9 +35705,10 @@ diff -urNp linux-3.0.9/drivers/staging/ath6kl/os/linux/include/ar6k_pal.h linux- void register_pal_cb(ar6k_pal_config_t *palConfig_p); #endif /* _AR6K_PAL_H_ */ -diff -urNp linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c ---- linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/brcm80211/brcmfmac/dhd_linux.c b/drivers/staging/brcm80211/brcmfmac/dhd_linux.c +index f356c56..5c63ac9 100644 +--- a/drivers/staging/brcm80211/brcmfmac/dhd_linux.c ++++ b/drivers/staging/brcm80211/brcmfmac/dhd_linux.c @@ -853,14 +853,14 @@ static void dhd_op_if(dhd_if_t *ifp) free_netdev(ifp->net); } @@ -34773,7 +35726,7 @@ diff -urNp linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c linux-3.0. err = dhd_net_attach(&dhd->pub, ifp->idx); if (err != 0) { DHD_ERROR(("%s: dhd_net_attach failed, " -@@ -1872,7 +1872,7 @@ dhd_pub_t *dhd_attach(struct dhd_bus *bu +@@ -1872,7 +1872,7 @@ dhd_pub_t *dhd_attach(struct dhd_bus *bus, uint bus_hdrlen) strcpy(nv_path, nvram_path); /* Allocate etherdev, including space for private structure */ @@ -34782,7 +35735,7 @@ diff -urNp linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c linux-3.0. if (!net) { DHD_ERROR(("%s: OOM - alloc_etherdev\n", __func__)); goto fail; -@@ -1888,7 +1888,7 @@ dhd_pub_t *dhd_attach(struct dhd_bus *bu +@@ -1888,7 +1888,7 @@ dhd_pub_t *dhd_attach(struct dhd_bus *bus, uint bus_hdrlen) /* * Save the dhd_info into the priv */ @@ -34791,7 +35744,7 @@ diff -urNp linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c linux-3.0. /* Set network interface name if it was provided as module parameter */ if (iface_name[0]) { -@@ -2004,7 +2004,7 @@ dhd_pub_t *dhd_attach(struct dhd_bus *bu +@@ -2004,7 +2004,7 @@ dhd_pub_t *dhd_attach(struct dhd_bus *bus, uint bus_hdrlen) /* * Save the dhd_info into the priv */ @@ -34800,9 +35753,10 @@ diff -urNp linux-3.0.9/drivers/staging/brcm80211/brcmfmac/dhd_linux.c linux-3.0. #if defined(CUSTOMER_HW2) && defined(CONFIG_WIFI_CONTROL_FUNC) g_bus = bus; -diff -urNp linux-3.0.9/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h linux-3.0.9/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h ---- linux-3.0.9/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h b/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h +index 10cbf52..ec1cef9 100644 +--- a/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h ++++ b/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h @@ -593,7 +593,7 @@ struct phy_func_ptr { initfn_t carrsuppr; rxsigpwrfn_t rxsigpwr; @@ -34812,9 +35766,10 @@ diff -urNp linux-3.0.9/drivers/staging/brcm80211/brcmsmac/phy/wlc_phy_int.h linu typedef struct phy_func_ptr phy_func_ptr_t; struct phy_info { -diff -urNp linux-3.0.9/drivers/staging/brcm80211/include/bcmsdh.h linux-3.0.9/drivers/staging/brcm80211/include/bcmsdh.h ---- linux-3.0.9/drivers/staging/brcm80211/include/bcmsdh.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/brcm80211/include/bcmsdh.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/brcm80211/include/bcmsdh.h b/drivers/staging/brcm80211/include/bcmsdh.h +index 3b57dc1..ea9849d 100644 +--- a/drivers/staging/brcm80211/include/bcmsdh.h ++++ b/drivers/staging/brcm80211/include/bcmsdh.h @@ -185,7 +185,7 @@ typedef struct { u16 func, uint bustype, void *regsva, void *param); /* detach from device */ @@ -34824,10 +35779,11 @@ diff -urNp linux-3.0.9/drivers/staging/brcm80211/include/bcmsdh.h linux-3.0.9/dr /* platform specific/high level functions */ extern int bcmsdh_register(bcmsdh_driver_t *driver); -diff -urNp linux-3.0.9/drivers/staging/et131x/et1310_tx.c linux-3.0.9/drivers/staging/et131x/et1310_tx.c ---- linux-3.0.9/drivers/staging/et131x/et1310_tx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/et131x/et1310_tx.c 2011-11-12 12:47:14.000000000 -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 4241d2a..cd3b543 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 = &etdev->net_stats; if (tcb->flags & fMP_DEST_BROAD) @@ -34842,9 +35798,10 @@ diff -urNp linux-3.0.9/drivers/staging/et131x/et1310_tx.c linux-3.0.9/drivers/st if (tcb->skb) { stats->tx_bytes += tcb->skb->len; -diff -urNp linux-3.0.9/drivers/staging/et131x/et131x_adapter.h linux-3.0.9/drivers/staging/et131x/et131x_adapter.h ---- linux-3.0.9/drivers/staging/et131x/et131x_adapter.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/et131x/et131x_adapter.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/et131x/et131x_adapter.h b/drivers/staging/et131x/et131x_adapter.h +index c852f86..3d0b007 100644 +--- a/drivers/staging/et131x/et131x_adapter.h ++++ b/drivers/staging/et131x/et131x_adapter.h @@ -110,11 +110,11 @@ typedef struct _ce_stats_t { * operations */ @@ -34860,10 +35817,11 @@ diff -urNp linux-3.0.9/drivers/staging/et131x/et131x_adapter.h linux-3.0.9/drive u32 norcvbuf; /* # Rx packets discarded */ u32 noxmtbuf; /* # Tx packets discarded */ -diff -urNp linux-3.0.9/drivers/staging/hv/channel.c linux-3.0.9/drivers/staging/hv/channel.c ---- linux-3.0.9/drivers/staging/hv/channel.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/hv/channel.c 2011-11-12 12:47:14.000000000 -0500 -@@ -433,8 +433,8 @@ int vmbus_establish_gpadl(struct vmbus_c +diff --git a/drivers/staging/hv/channel.c b/drivers/staging/hv/channel.c +index d971bab..af9804b 100644 +--- a/drivers/staging/hv/channel.c ++++ b/drivers/staging/hv/channel.c +@@ -433,8 +433,8 @@ int vmbus_establish_gpadl(struct vmbus_channel *channel, void *kbuffer, int ret = 0; int t; @@ -34874,10 +35832,11 @@ diff -urNp linux-3.0.9/drivers/staging/hv/channel.c linux-3.0.9/drivers/staging/ ret = create_gpadl_header(kbuffer, size, &msginfo, &msgcount); if (ret) -diff -urNp linux-3.0.9/drivers/staging/hv/hv.c linux-3.0.9/drivers/staging/hv/hv.c ---- linux-3.0.9/drivers/staging/hv/hv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/hv/hv.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 a2cc091..0f09c39 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, void *output) u64 output_address = (output) ? virt_to_phys(output) : 0; u32 output_address_hi = output_address >> 32; u32 output_address_lo = output_address & 0xFFFFFFFF; @@ -34886,10 +35845,11 @@ diff -urNp linux-3.0.9/drivers/staging/hv/hv.c linux-3.0.9/drivers/staging/hv/hv __asm__ __volatile__ ("call *%8" : "=d"(hv_status_hi), "=a"(hv_status_lo) : "d" (control_hi), -diff -urNp linux-3.0.9/drivers/staging/hv/hv_mouse.c linux-3.0.9/drivers/staging/hv/hv_mouse.c ---- linux-3.0.9/drivers/staging/hv/hv_mouse.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/hv/hv_mouse.c 2011-11-12 12:47:14.000000000 -0500 -@@ -879,8 +879,10 @@ static void reportdesc_callback(struct h +diff --git a/drivers/staging/hv/hv_mouse.c b/drivers/staging/hv/hv_mouse.c +index 359e737..62de2d1 100644 +--- a/drivers/staging/hv/hv_mouse.c ++++ b/drivers/staging/hv/hv_mouse.c +@@ -879,8 +879,10 @@ static void reportdesc_callback(struct hv_device *dev, void *packet, u32 len) if (hid_dev) { DPRINT_INFO(INPUTVSC_DRV, "hid_device created"); @@ -34902,9 +35862,10 @@ diff -urNp linux-3.0.9/drivers/staging/hv/hv_mouse.c linux-3.0.9/drivers/staging hid_dev->bus = BUS_VIRTUAL; hid_dev->vendor = input_device_ctx->device_info.vendor; -diff -urNp linux-3.0.9/drivers/staging/hv/hyperv_vmbus.h linux-3.0.9/drivers/staging/hv/hyperv_vmbus.h ---- linux-3.0.9/drivers/staging/hv/hyperv_vmbus.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/hv/hyperv_vmbus.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/hv/hyperv_vmbus.h b/drivers/staging/hv/hyperv_vmbus.h +index bf30a42..f546434 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; @@ -34914,9 +35875,10 @@ diff -urNp linux-3.0.9/drivers/staging/hv/hyperv_vmbus.h linux-3.0.9/drivers/sta /* * Represents channel interrupts. Each bit position represents a -diff -urNp linux-3.0.9/drivers/staging/hv/rndis_filter.c linux-3.0.9/drivers/staging/hv/rndis_filter.c ---- linux-3.0.9/drivers/staging/hv/rndis_filter.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/hv/rndis_filter.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/hv/rndis_filter.c b/drivers/staging/hv/rndis_filter.c +index b47ebb3..f8bc62d 100644 +--- a/drivers/staging/hv/rndis_filter.c ++++ b/drivers/staging/hv/rndis_filter.c @@ -43,7 +43,7 @@ struct rndis_device { enum rndis_device_state state; @@ -34926,7 +35888,7 @@ diff -urNp linux-3.0.9/drivers/staging/hv/rndis_filter.c linux-3.0.9/drivers/sta 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(struct rndis_device *dev, * template */ set = &rndis_msg->msg.set_req; @@ -34935,7 +35897,7 @@ diff -urNp linux-3.0.9/drivers/staging/hv/rndis_filter.c linux-3.0.9/drivers/sta /* Add to the request list */ spin_lock_irqsave(&dev->request_lock, flags); -@@ -637,7 +637,7 @@ static void rndis_filter_halt_device(str +@@ -637,7 +637,7 @@ static void rndis_filter_halt_device(struct rndis_device *dev) /* Setup the rndis set */ halt = &request->request_msg.msg.halt_req; @@ -34944,10 +35906,11 @@ diff -urNp linux-3.0.9/drivers/staging/hv/rndis_filter.c linux-3.0.9/drivers/sta /* Ignore return since this msg is optional. */ rndis_filter_send_request(dev, request); -diff -urNp linux-3.0.9/drivers/staging/hv/vmbus_drv.c linux-3.0.9/drivers/staging/hv/vmbus_drv.c ---- linux-3.0.9/drivers/staging/hv/vmbus_drv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/hv/vmbus_drv.c 2011-11-12 12:47:14.000000000 -0500 -@@ -668,11 +668,11 @@ int vmbus_child_device_register(struct h +diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_drv.c +index ec1d38c..d7b474b 100644 +--- a/drivers/staging/hv/vmbus_drv.c ++++ b/drivers/staging/hv/vmbus_drv.c +@@ -668,11 +668,11 @@ int vmbus_child_device_register(struct hv_device *child_device_obj) { int ret = 0; @@ -34961,9 +35924,10 @@ diff -urNp linux-3.0.9/drivers/staging/hv/vmbus_drv.c linux-3.0.9/drivers/stagin /* The new device belongs to this bus */ child_device_obj->device.bus = &hv_bus; /* device->dev.bus; */ -diff -urNp linux-3.0.9/drivers/staging/iio/ring_generic.h linux-3.0.9/drivers/staging/iio/ring_generic.h ---- linux-3.0.9/drivers/staging/iio/ring_generic.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/iio/ring_generic.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/iio/ring_generic.h b/drivers/staging/iio/ring_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 { int (*is_enabled)(struct iio_ring_buffer *ring); @@ -34973,29 +35937,11 @@ diff -urNp linux-3.0.9/drivers/staging/iio/ring_generic.h linux-3.0.9/drivers/st struct iio_ring_setup_ops { int (*preenable)(struct iio_dev *); -diff -urNp linux-3.0.9/drivers/staging/octeon/ethernet.c linux-3.0.9/drivers/staging/octeon/ethernet.c ---- linux-3.0.9/drivers/staging/octeon/ethernet.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/octeon/ethernet.c 2011-11-12 12:47:14.000000000 -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 - } - -diff -urNp linux-3.0.9/drivers/staging/octeon/ethernet-rx.c linux-3.0.9/drivers/staging/octeon/ethernet-rx.c ---- linux-3.0.9/drivers/staging/octeon/ethernet-rx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/octeon/ethernet-rx.c 2011-11-12 12:47:14.000000000 -0500 -@@ -417,11 +417,11 @@ static int cvm_oct_napi_poll(struct napi +diff --git a/drivers/staging/octeon/ethernet-rx.c b/drivers/staging/octeon/ethernet-rx.c +index cb38f9e..6b137b2 100644 +--- a/drivers/staging/octeon/ethernet-rx.c ++++ b/drivers/staging/octeon/ethernet-rx.c +@@ -417,11 +417,11 @@ static int cvm_oct_napi_poll(struct napi_struct *napi, int budget) /* Increment RX stats for virtual ports */ if (work->ipprt >= CVMX_PIP_NUM_INPUT_PORTS) { #ifdef CONFIG_64BIT @@ -35011,7 +35957,7 @@ diff -urNp linux-3.0.9/drivers/staging/octeon/ethernet-rx.c linux-3.0.9/drivers/ #endif } netif_receive_skb(skb); -@@ -433,9 +433,9 @@ static int cvm_oct_napi_poll(struct napi +@@ -433,9 +433,9 @@ static int cvm_oct_napi_poll(struct napi_struct *napi, int budget) dev->name); */ #ifdef CONFIG_64BIT @@ -35023,10 +35969,31 @@ diff -urNp linux-3.0.9/drivers/staging/octeon/ethernet-rx.c linux-3.0.9/drivers/ #endif dev_kfree_skb_irq(skb); } -diff -urNp linux-3.0.9/drivers/staging/pohmelfs/inode.c linux-3.0.9/drivers/staging/pohmelfs/inode.c ---- linux-3.0.9/drivers/staging/pohmelfs/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/pohmelfs/inode.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1856,7 +1856,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 + } + +diff --git a/drivers/staging/pohmelfs/inode.c b/drivers/staging/pohmelfs/inode.c +index c0f0ac7..d214d36 100644 +--- a/drivers/staging/pohmelfs/inode.c ++++ b/drivers/staging/pohmelfs/inode.c +@@ -1856,7 +1856,7 @@ static int pohmelfs_fill_super(struct super_block *sb, void *data, int silent) mutex_init(&psb->mcache_lock); psb->mcache_root = RB_ROOT; psb->mcache_timeout = msecs_to_jiffies(5000); @@ -35035,7 +36002,7 @@ diff -urNp linux-3.0.9/drivers/staging/pohmelfs/inode.c linux-3.0.9/drivers/stag psb->trans_max_pages = 100; -@@ -1871,7 +1871,7 @@ static int pohmelfs_fill_super(struct su +@@ -1871,7 +1871,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); @@ -35044,10 +36011,11 @@ diff -urNp linux-3.0.9/drivers/staging/pohmelfs/inode.c linux-3.0.9/drivers/stag atomic_long_set(&psb->total_inodes, 0); mutex_init(&psb->state_lock); -diff -urNp linux-3.0.9/drivers/staging/pohmelfs/mcache.c linux-3.0.9/drivers/staging/pohmelfs/mcache.c ---- linux-3.0.9/drivers/staging/pohmelfs/mcache.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/pohmelfs/mcache.c 2011-11-12 12:47:14.000000000 -0500 -@@ -121,7 +121,7 @@ struct pohmelfs_mcache *pohmelfs_mcache_ +diff --git a/drivers/staging/pohmelfs/mcache.c b/drivers/staging/pohmelfs/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 = data; m->start = start; m->size = size; @@ -35056,9 +36024,10 @@ diff -urNp linux-3.0.9/drivers/staging/pohmelfs/mcache.c linux-3.0.9/drivers/sta mutex_lock(&psb->mcache_lock); err = pohmelfs_mcache_insert(psb, m); -diff -urNp linux-3.0.9/drivers/staging/pohmelfs/netfs.h linux-3.0.9/drivers/staging/pohmelfs/netfs.h ---- linux-3.0.9/drivers/staging/pohmelfs/netfs.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/pohmelfs/netfs.h 2011-11-12 12:47:14.000000000 -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; @@ -35076,10 +36045,11 @@ diff -urNp linux-3.0.9/drivers/staging/pohmelfs/netfs.h linux-3.0.9/drivers/stag unsigned int crypto_attached_size; unsigned int crypto_align_size; -diff -urNp linux-3.0.9/drivers/staging/pohmelfs/trans.c linux-3.0.9/drivers/staging/pohmelfs/trans.c ---- linux-3.0.9/drivers/staging/pohmelfs/trans.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/pohmelfs/trans.c 2011-11-12 12:47:14.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 = t->iovec.iov_base; @@ -35088,9 +36058,10 @@ diff -urNp linux-3.0.9/drivers/staging/pohmelfs/trans.c linux-3.0.9/drivers/stag cmd->size = t->iovec.iov_len - sizeof(struct netfs_cmd) + t->attached_size + t->attached_pages * sizeof(struct netfs_cmd); -diff -urNp linux-3.0.9/drivers/staging/rtl8712/rtl871x_io.h linux-3.0.9/drivers/staging/rtl8712/rtl871x_io.h ---- linux-3.0.9/drivers/staging/rtl8712/rtl871x_io.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/rtl8712/rtl871x_io.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/rtl8712/rtl871x_io.h b/drivers/staging/rtl8712/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, @@ -35100,10 +36071,11 @@ diff -urNp linux-3.0.9/drivers/staging/rtl8712/rtl871x_io.h linux-3.0.9/drivers/ struct io_req { struct list_head list; -diff -urNp linux-3.0.9/drivers/staging/sbe-2t3e3/netdev.c linux-3.0.9/drivers/staging/sbe-2t3e3/netdev.c ---- linux-3.0.9/drivers/staging/sbe-2t3e3/netdev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/sbe-2t3e3/netdev.c 2011-11-12 12:47:14.000000000 -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-2t3e3/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 *ifr, int cmd) t3e3_if_config(sc, cmd_2t3e3, (char *)¶m, &resp, &rlen); if (rlen) @@ -35112,10 +36084,11 @@ diff -urNp linux-3.0.9/drivers/staging/sbe-2t3e3/netdev.c linux-3.0.9/drivers/st return -EFAULT; return 0; -diff -urNp linux-3.0.9/drivers/staging/tty/stallion.c linux-3.0.9/drivers/staging/tty/stallion.c ---- linux-3.0.9/drivers/staging/tty/stallion.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/tty/stallion.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2406,6 +2406,8 @@ static int stl_getportstruct(struct stlp +diff --git a/drivers/staging/tty/stallion.c b/drivers/staging/tty/stallion.c +index 4fff5cd..8e5762a 100644 +--- a/drivers/staging/tty/stallion.c ++++ b/drivers/staging/tty/stallion.c +@@ -2406,6 +2406,8 @@ static int stl_getportstruct(struct stlport __user *arg) struct stlport stl_dummyport; struct stlport *portp; @@ -35124,9 +36097,10 @@ diff -urNp linux-3.0.9/drivers/staging/tty/stallion.c linux-3.0.9/drivers/stagin if (copy_from_user(&stl_dummyport, arg, sizeof(struct stlport))) return -EFAULT; portp = stl_getport(stl_dummyport.brdnr, stl_dummyport.panelnr, -diff -urNp linux-3.0.9/drivers/staging/usbip/usbip_common.h linux-3.0.9/drivers/staging/usbip/usbip_common.h ---- linux-3.0.9/drivers/staging/usbip/usbip_common.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/usbip/usbip_common.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/usbip/usbip_common.h b/drivers/staging/usbip/usbip_common.h +index 4a641c5..a3ed832 100644 +--- a/drivers/staging/usbip/usbip_common.h ++++ b/drivers/staging/usbip/usbip_common.h @@ -315,7 +315,7 @@ struct usbip_device { void (*shutdown)(struct usbip_device *); void (*reset)(struct usbip_device *); @@ -35136,9 +36110,10 @@ diff -urNp linux-3.0.9/drivers/staging/usbip/usbip_common.h linux-3.0.9/drivers/ }; void usbip_pack_pdu(struct usbip_header *pdu, struct urb *urb, int cmd, -diff -urNp linux-3.0.9/drivers/staging/usbip/vhci.h linux-3.0.9/drivers/staging/usbip/vhci.h ---- linux-3.0.9/drivers/staging/usbip/vhci.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/usbip/vhci.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/usbip/vhci.h b/drivers/staging/usbip/vhci.h +index d5bc8e7..3c0b221 100644 +--- a/drivers/staging/usbip/vhci.h ++++ b/drivers/staging/usbip/vhci.h @@ -94,7 +94,7 @@ struct vhci_hcd { unsigned resuming:1; unsigned long re_timeout; @@ -35148,9 +36123,10 @@ diff -urNp linux-3.0.9/drivers/staging/usbip/vhci.h linux-3.0.9/drivers/staging/ /* * NOTE: -diff -urNp linux-3.0.9/drivers/staging/usbip/vhci_hcd.c linux-3.0.9/drivers/staging/usbip/vhci_hcd.c ---- linux-3.0.9/drivers/staging/usbip/vhci_hcd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/usbip/vhci_hcd.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/usbip/vhci_hcd.c b/drivers/staging/usbip/vhci_hcd.c +index 76d7485..ab8524a 100644 +--- a/drivers/staging/usbip/vhci_hcd.c ++++ b/drivers/staging/usbip/vhci_hcd.c @@ -511,7 +511,7 @@ static void vhci_tx_urb(struct urb *urb) return; } @@ -35160,7 +36136,7 @@ diff -urNp linux-3.0.9/drivers/staging/usbip/vhci_hcd.c linux-3.0.9/drivers/stag if (priv->seqnum == 0xffff) dev_info(&urb->dev->dev, "seqnum max\n"); -@@ -765,7 +765,7 @@ static int vhci_urb_dequeue(struct usb_h +@@ -765,7 +765,7 @@ static int vhci_urb_dequeue(struct usb_hcd *hcd, struct urb *urb, int status) return -ENOMEM; } @@ -35169,7 +36145,7 @@ diff -urNp linux-3.0.9/drivers/staging/usbip/vhci_hcd.c linux-3.0.9/drivers/stag if (unlink->seqnum == 0xffff) pr_info("seqnum max\n"); -@@ -955,7 +955,7 @@ static int vhci_start(struct usb_hcd *hc +@@ -955,7 +955,7 @@ static int vhci_start(struct usb_hcd *hcd) vdev->rhport = rhport; } @@ -35178,10 +36154,11 @@ diff -urNp linux-3.0.9/drivers/staging/usbip/vhci_hcd.c linux-3.0.9/drivers/stag spin_lock_init(&vhci->lock); hcd->power_budget = 0; /* no limit */ -diff -urNp linux-3.0.9/drivers/staging/usbip/vhci_rx.c linux-3.0.9/drivers/staging/usbip/vhci_rx.c ---- linux-3.0.9/drivers/staging/usbip/vhci_rx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/usbip/vhci_rx.c 2011-11-12 12:47:14.000000000 -0500 -@@ -76,7 +76,7 @@ static void vhci_recv_ret_submit(struct +diff --git a/drivers/staging/usbip/vhci_rx.c b/drivers/staging/usbip/vhci_rx.c +index e42ce9d..b3ee231 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 *vdev, if (!urb) { pr_err("cannot find a urb of seqnum %u\n", pdu->base.seqnum); pr_info("max seqnum %d\n", @@ -35190,10 +36167,11 @@ diff -urNp linux-3.0.9/drivers/staging/usbip/vhci_rx.c linux-3.0.9/drivers/stagi usbip_event_add(ud, VDEV_EVENT_ERROR_TCP); return; } -diff -urNp linux-3.0.9/drivers/staging/vt6655/hostap.c linux-3.0.9/drivers/staging/vt6655/hostap.c ---- linux-3.0.9/drivers/staging/vt6655/hostap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/vt6655/hostap.c 2011-11-12 12:47:14.000000000 -0500 -@@ -79,14 +79,13 @@ static int msglevel +diff --git a/drivers/staging/vt6655/hostap.c b/drivers/staging/vt6655/hostap.c +index 7735027..30eed13 100644 +--- a/drivers/staging/vt6655/hostap.c ++++ b/drivers/staging/vt6655/hostap.c +@@ -79,14 +79,13 @@ static int msglevel =MSG_LEVEL_INFO; * */ @@ -35210,7 +36188,7 @@ diff -urNp linux-3.0.9/drivers/staging/vt6655/hostap.c linux-3.0.9/drivers/stagi DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "%s: Enabling hostapd mode\n", dev->name); -@@ -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 = *pDevice; memcpy(pDevice->apdev->dev_addr, dev->dev_addr, ETH_ALEN); @@ -35219,10 +36197,11 @@ diff -urNp linux-3.0.9/drivers/staging/vt6655/hostap.c linux-3.0.9/drivers/stagi pDevice->apdev->netdev_ops = &apdev_netdev_ops; pDevice->apdev->type = ARPHRD_IEEE80211; -diff -urNp linux-3.0.9/drivers/staging/vt6656/hostap.c linux-3.0.9/drivers/staging/vt6656/hostap.c ---- linux-3.0.9/drivers/staging/vt6656/hostap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/vt6656/hostap.c 2011-11-12 12:47:14.000000000 -0500 -@@ -80,14 +80,13 @@ static int msglevel +diff --git a/drivers/staging/vt6656/hostap.c b/drivers/staging/vt6656/hostap.c +index 51b5adf..098e320 100644 +--- a/drivers/staging/vt6656/hostap.c ++++ b/drivers/staging/vt6656/hostap.c +@@ -80,14 +80,13 @@ static int msglevel =MSG_LEVEL_INFO; * */ @@ -35239,7 +36218,7 @@ diff -urNp linux-3.0.9/drivers/staging/vt6656/hostap.c linux-3.0.9/drivers/stagi DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "%s: Enabling hostapd mode\n", dev->name); -@@ -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 = *pDevice; memcpy(pDevice->apdev->dev_addr, dev->dev_addr, ETH_ALEN); @@ -35248,10 +36227,11 @@ diff -urNp linux-3.0.9/drivers/staging/vt6656/hostap.c linux-3.0.9/drivers/stagi pDevice->apdev->netdev_ops = &apdev_netdev_ops; pDevice->apdev->type = ARPHRD_IEEE80211; -diff -urNp linux-3.0.9/drivers/staging/wlan-ng/hfa384x_usb.c linux-3.0.9/drivers/staging/wlan-ng/hfa384x_usb.c ---- linux-3.0.9/drivers/staging/wlan-ng/hfa384x_usb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/wlan-ng/hfa384x_usb.c 2011-11-12 12:47:14.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/wlan-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); struct usbctlx_completor { int (*complete) (struct usbctlx_completor *); @@ -35260,9 +36240,10 @@ diff -urNp linux-3.0.9/drivers/staging/wlan-ng/hfa384x_usb.c linux-3.0.9/drivers static int hfa384x_usbctlx_complete_sync(hfa384x_t *hw, -diff -urNp linux-3.0.9/drivers/staging/zcache/tmem.c linux-3.0.9/drivers/staging/zcache/tmem.c ---- linux-3.0.9/drivers/staging/zcache/tmem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/zcache/tmem.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/zcache/tmem.c b/drivers/staging/zcache/tmem.c +index e954d40..a04d842 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 callbacks * for memory allocation. @@ -35272,7 +36253,7 @@ diff -urNp linux-3.0.9/drivers/staging/zcache/tmem.c linux-3.0.9/drivers/staging static void tmem_objnode_tree_init(void); -@@ -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 */ @@ -35281,9 +36262,10 @@ diff -urNp linux-3.0.9/drivers/staging/zcache/tmem.c linux-3.0.9/drivers/staging void tmem_register_pamops(struct tmem_pamops *m) { -diff -urNp linux-3.0.9/drivers/staging/zcache/tmem.h linux-3.0.9/drivers/staging/zcache/tmem.h ---- linux-3.0.9/drivers/staging/zcache/tmem.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/staging/zcache/tmem.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/staging/zcache/tmem.h b/drivers/staging/zcache/tmem.h +index 2e07e21..6507d31 100644 +--- a/drivers/staging/zcache/tmem.h ++++ b/drivers/staging/zcache/tmem.h @@ -171,6 +171,7 @@ struct tmem_pamops { int (*get_data)(struct page *, void *, struct tmem_pool *); void (*free)(void *, struct tmem_pool *); @@ -35300,10 +36282,11 @@ diff -urNp linux-3.0.9/drivers/staging/zcache/tmem.h linux-3.0.9/drivers/staging extern void tmem_register_hostops(struct tmem_hostops *m); /* core tmem accessor functions */ -diff -urNp linux-3.0.9/drivers/target/target_core_alua.c linux-3.0.9/drivers/target/target_core_alua.c ---- linux-3.0.9/drivers/target/target_core_alua.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/target/target_core_alua.c 2011-11-12 12:47:14.000000000 -0500 -@@ -695,6 +695,8 @@ static int core_alua_update_tpg_primary_ +diff --git a/drivers/target/target_core_alua.c b/drivers/target/target_core_alua.c +index 86b3660..48c1b66 100644 +--- a/drivers/target/target_core_alua.c ++++ b/drivers/target/target_core_alua.c +@@ -695,6 +695,8 @@ static int core_alua_update_tpg_primary_metadata( char path[ALUA_METADATA_PATH_LEN]; int len; @@ -35312,7 +36295,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_alua.c linux-3.0.9/drivers/tar memset(path, 0, ALUA_METADATA_PATH_LEN); len = snprintf(md_buf, tg_pt_gp->tg_pt_gp_md_buf_len, -@@ -958,6 +960,8 @@ static int core_alua_update_tpg_secondar +@@ -958,6 +960,8 @@ static int core_alua_update_tpg_secondary_metadata( char path[ALUA_METADATA_PATH_LEN], wwn[ALUA_SECONDARY_METADATA_WWN_LEN]; int len; @@ -35321,10 +36304,11 @@ diff -urNp linux-3.0.9/drivers/target/target_core_alua.c linux-3.0.9/drivers/tar memset(path, 0, ALUA_METADATA_PATH_LEN); memset(wwn, 0, ALUA_SECONDARY_METADATA_WWN_LEN); -diff -urNp linux-3.0.9/drivers/target/target_core_cdb.c linux-3.0.9/drivers/target/target_core_cdb.c ---- linux-3.0.9/drivers/target/target_core_cdb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/target/target_core_cdb.c 2011-11-12 12:47:14.000000000 -0500 -@@ -838,6 +838,8 @@ target_emulate_modesense(struct se_cmd * +diff --git a/drivers/target/target_core_cdb.c b/drivers/target/target_core_cdb.c +index 7f19c8b..5f21663 100644 +--- a/drivers/target/target_core_cdb.c ++++ b/drivers/target/target_core_cdb.c +@@ -838,6 +838,8 @@ target_emulate_modesense(struct se_cmd *cmd, int ten) int length = 0; unsigned char buf[SE_MODE_PAGE_BUF]; @@ -35333,10 +36317,11 @@ diff -urNp linux-3.0.9/drivers/target/target_core_cdb.c linux-3.0.9/drivers/targ memset(buf, 0, SE_MODE_PAGE_BUF); switch (cdb[2] & 0x3f) { -diff -urNp linux-3.0.9/drivers/target/target_core_configfs.c linux-3.0.9/drivers/target/target_core_configfs.c ---- linux-3.0.9/drivers/target/target_core_configfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/target/target_core_configfs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1276,6 +1276,8 @@ static ssize_t target_core_dev_pr_show_a +diff --git a/drivers/target/target_core_configfs.c b/drivers/target/target_core_configfs.c +index 25c1f49..68cdbd0 100644 +--- a/drivers/target/target_core_configfs.c ++++ b/drivers/target/target_core_configfs.c +@@ -1276,6 +1276,8 @@ static ssize_t target_core_dev_pr_show_attr_res_pr_registered_i_pts( ssize_t len = 0; int reg_count = 0, prf_isid; @@ -35345,10 +36330,11 @@ diff -urNp linux-3.0.9/drivers/target/target_core_configfs.c linux-3.0.9/drivers if (!(su_dev->se_dev_ptr)) return -ENODEV; -diff -urNp linux-3.0.9/drivers/target/target_core_pr.c linux-3.0.9/drivers/target/target_core_pr.c ---- linux-3.0.9/drivers/target/target_core_pr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/target/target_core_pr.c 2011-11-12 12:47:14.000000000 -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_core_pr.c +index b662db3..d5e2e48 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; @@ -35357,7 +36343,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_pr.c linux-3.0.9/drivers/targe memset(i_port, 0, PR_APTPL_MAX_IPORT_LEN); memset(t_port, 0, PR_APTPL_MAX_TPORT_LEN); /* -@@ -1861,6 +1863,8 @@ static int __core_scsi3_update_aptpl_buf +@@ -1861,6 +1863,8 @@ static int __core_scsi3_update_aptpl_buf( ssize_t len = 0; int reg_count = 0; @@ -35366,7 +36352,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_pr.c linux-3.0.9/drivers/targe memset(buf, 0, pr_aptpl_buf_len); /* * Called to clear metadata once APTPL has been deactivated. -@@ -1983,6 +1987,8 @@ static int __core_scsi3_write_aptpl_to_f +@@ -1983,6 +1987,8 @@ static int __core_scsi3_write_aptpl_to_file( char path[512]; int ret; @@ -35375,9 +36361,10 @@ diff -urNp linux-3.0.9/drivers/target/target_core_pr.c linux-3.0.9/drivers/targe memset(iov, 0, sizeof(struct iovec)); memset(path, 0, 512); -diff -urNp linux-3.0.9/drivers/target/target_core_tmr.c linux-3.0.9/drivers/target/target_core_tmr.c ---- linux-3.0.9/drivers/target/target_core_tmr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/target/target_core_tmr.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/target/target_core_tmr.c b/drivers/target/target_core_tmr.c +index 179063d..7baed53 100644 +--- a/drivers/target/target_core_tmr.c ++++ b/drivers/target/target_core_tmr.c @@ -269,7 +269,7 @@ int core_tmr_lun_reset( CMD_TFO(cmd)->get_task_tag(cmd), cmd->pr_res_key, T_TASK(cmd)->t_task_cdbs, @@ -35405,10 +36392,11 @@ diff -urNp linux-3.0.9/drivers/target/target_core_tmr.c linux-3.0.9/drivers/targ spin_unlock_irqrestore(&T_TASK(cmd)->t_state_lock, flags); core_tmr_handle_tas_abort(tmr_nacl, cmd, tas, fe_count); -diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/drivers/target/target_core_transport.c ---- linux-3.0.9/drivers/target/target_core_transport.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/target/target_core_transport.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1681,7 +1681,7 @@ struct se_device *transport_add_device_t +diff --git a/drivers/target/target_core_transport.c b/drivers/target/target_core_transport.c +index 4b9b716..ec411b3 100644 +--- a/drivers/target/target_core_transport.c ++++ b/drivers/target/target_core_transport.c +@@ -1681,7 +1681,7 @@ struct se_device *transport_add_device_to_core_hba( dev->queue_depth = dev_limits->queue_depth; atomic_set(&dev->depth_left, dev->queue_depth); @@ -35417,7 +36405,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/driver se_dev_set_default_attribs(dev, dev_limits); -@@ -1882,7 +1882,7 @@ static int transport_check_alloc_task_at +@@ -1882,7 +1882,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. */ @@ -35426,7 +36414,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/driver smp_mb__after_atomic_inc(); DEBUG_STA("Allocated se_ordered_id: %u for Task Attr: 0x%02x on %s\n", cmd->se_ordered_id, cmd->sam_task_attr, -@@ -2169,7 +2169,7 @@ static void transport_generic_request_fa +@@ -2169,7 +2169,7 @@ static void transport_generic_request_failure( " t_transport_active: %d t_transport_stop: %d" " t_transport_sent: %d\n", T_TASK(cmd)->t_task_cdbs, atomic_read(&T_TASK(cmd)->t_task_cdbs_left), @@ -35447,7 +36435,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/driver T_TASK(cmd)->t_task_cdbs) atomic_set(&cmd->transport_sent, 1); -@@ -5568,7 +5568,7 @@ static void transport_generic_wait_for_t +@@ -5568,7 +5568,7 @@ static void transport_generic_wait_for_tasks( atomic_set(&T_TASK(cmd)->transport_lun_stop, 0); } if (!atomic_read(&T_TASK(cmd)->t_transport_active) || @@ -35456,7 +36444,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/driver goto remove; atomic_set(&T_TASK(cmd)->t_transport_stop, 1); -@@ -5797,7 +5797,7 @@ int transport_check_aborted_status(struc +@@ -5797,7 +5797,7 @@ int transport_check_aborted_status(struct se_cmd *cmd, int send_status) { int ret = 0; @@ -35465,7 +36453,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/driver if (!(send_status) || (cmd->se_cmd_flags & SCF_SENT_DELAYED_TAS)) return 1; -@@ -5825,7 +5825,7 @@ void transport_send_task_abort(struct se +@@ -5825,7 +5825,7 @@ void transport_send_task_abort(struct se_cmd *cmd) */ if (cmd->data_direction == DMA_TO_DEVICE) { if (CMD_TFO(cmd)->write_pending_status(cmd) != 0) { @@ -35474,7 +36462,7 @@ diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/driver smp_mb__after_atomic_inc(); cmd->scsi_status = SAM_STAT_TASK_ABORTED; transport_new_cmd_failure(cmd); -@@ -5949,7 +5949,7 @@ static void transport_processing_shutdow +@@ -5949,7 +5949,7 @@ static void transport_processing_shutdown(struct se_device *dev) CMD_TFO(cmd)->get_task_tag(cmd), T_TASK(cmd)->t_task_cdbs, atomic_read(&T_TASK(cmd)->t_task_cdbs_left), @@ -35483,9 +36471,10 @@ diff -urNp linux-3.0.9/drivers/target/target_core_transport.c linux-3.0.9/driver atomic_read(&T_TASK(cmd)->t_transport_active), atomic_read(&T_TASK(cmd)->t_transport_stop), atomic_read(&T_TASK(cmd)->t_transport_sent)); -diff -urNp linux-3.0.9/drivers/telephony/ixj.c linux-3.0.9/drivers/telephony/ixj.c ---- linux-3.0.9/drivers/telephony/ixj.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/telephony/ixj.c 2011-11-12 12:47:14.000000000 -0500 +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; @@ -35495,9 +36484,10 @@ diff -urNp linux-3.0.9/drivers/telephony/ixj.c linux-3.0.9/drivers/telephony/ixj if (!SCI_Prepare(j)) return 0; -diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c ---- linux-3.0.9/drivers/tty/hvc/hvcs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/hvc/hvcs.c 2011-11-12 12:47:14.000000000 -0500 +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 <asm/hvcserver.h> #include <asm/uaccess.h> @@ -35515,7 +36505,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c /* * 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 spin_lock_irqsave(&hvcsd->lock, flags); @@ -35524,7 +36514,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/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, struct file *filp) if ((retval = hvcs_partner_connect(hvcsd))) goto error_release; @@ -35542,7 +36532,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c hvcsd->todo_mask |= HVCS_SCHED_READ; spin_unlock_irqrestore(&hvcsd->lock, flags); -@@ -1223,7 +1224,7 @@ static void hvcs_close(struct tty_struct +@@ -1223,7 +1224,7 @@ static void hvcs_close(struct tty_struct *tty, struct file *filp) hvcsd = tty->driver_data; spin_lock_irqsave(&hvcsd->lock, flags); @@ -35551,7 +36541,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c vio_disable_interrupts(hvcsd->vdev); -@@ -1249,10 +1250,10 @@ static void hvcs_close(struct tty_struct +@@ -1249,10 +1250,10 @@ static void hvcs_close(struct tty_struct *tty, struct file *filp) free_irq(irq, hvcsd); kref_put(&hvcsd->kref, destroy_hvcs_struct); return; @@ -35564,7 +36554,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c } 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) spin_lock_irqsave(&hvcsd->lock, flags); /* Preserve this so that we know how many kref refs to put */ @@ -35573,7 +36563,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c /* * 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 = NULL; hvcsd->tty = NULL; @@ -35582,7 +36572,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c /* This will drop any buffered data on the floor which is OK in a hangup * scenario. */ -@@ -1354,7 +1355,7 @@ static int hvcs_write(struct tty_struct +@@ -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. */ @@ -35591,7 +36581,7 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/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 = tty->driver_data; @@ -35600,9 +36590,10 @@ diff -urNp linux-3.0.9/drivers/tty/hvc/hvcs.c linux-3.0.9/drivers/tty/hvc/hvcs.c return 0; return HVCS_BUFF_LEN - hvcsd->chars_in_buffer; -diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwireless/tty.c ---- linux-3.0.9/drivers/tty/ipwireless/tty.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/ipwireless/tty.c 2011-11-12 12:47:14.000000000 -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 <linux/tty_driver.h> #include <linux/tty_flip.h> @@ -35620,7 +36611,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/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; } @@ -35633,7 +36624,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi tty->linux_tty = linux_tty; linux_tty->driver_data = 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, struct file *filp) static void do_ipw_close(struct ipw_tty *tty) { @@ -35644,7 +36635,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi struct tty_struct *linux_tty = tty->linux_tty; if (linux_tty != 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; mutex_lock(&tty->ipw_tty_mutex); @@ -35653,7 +36644,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/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, unsigned char *data, return; } @@ -35662,7 +36653,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/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; mutex_lock(&tty->ipw_tty_mutex); @@ -35671,7 +36662,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/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_tty) if (!tty) return -ENODEV; @@ -35680,7 +36671,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi return -EINVAL; room = 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 *linux_tty) if (!tty) return 0; @@ -35689,7 +36680,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi return 0; 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; @@ -35698,7 +36689,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi return -EINVAL; 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; @@ -35707,7 +36698,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi return -EINVAL; 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; @@ -35716,7 +36707,7 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi return -EINVAL; /* FIXME: Exactly how is the tty object locked here .. */ -@@ -582,7 +581,7 @@ void ipwireless_tty_free(struct ipw_tty +@@ -582,7 +581,7 @@ void ipwireless_tty_free(struct ipw_tty *tty) against a parallel ioctl etc */ mutex_lock(&ttyj->ipw_tty_mutex); } @@ -35725,10 +36716,11 @@ diff -urNp linux-3.0.9/drivers/tty/ipwireless/tty.c linux-3.0.9/drivers/tty/ipwi do_ipw_close(ttyj); ipwireless_disassociate_network_ttys(network, ttyj->channel_idx); -diff -urNp linux-3.0.9/drivers/tty/n_gsm.c linux-3.0.9/drivers/tty/n_gsm.c ---- linux-3.0.9/drivers/tty/n_gsm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/n_gsm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1589,7 +1589,7 @@ static struct gsm_dlci *gsm_dlci_alloc(s +diff --git a/drivers/tty/n_gsm.c b/drivers/tty/n_gsm.c +index c0d34ad..67a388f 100644 +--- a/drivers/tty/n_gsm.c ++++ b/drivers/tty/n_gsm.c +@@ -1589,7 +1589,7 @@ static struct gsm_dlci *gsm_dlci_alloc(struct gsm_mux *gsm, int addr) return NULL; spin_lock_init(&dlci->lock); dlci->fifo = &dlci->_fifo; @@ -35737,10 +36729,11 @@ diff -urNp linux-3.0.9/drivers/tty/n_gsm.c linux-3.0.9/drivers/tty/n_gsm.c kfree(dlci); return NULL; } -diff -urNp linux-3.0.9/drivers/tty/n_tty.c linux-3.0.9/drivers/tty/n_tty.c ---- linux-3.0.9/drivers/tty/n_tty.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/n_tty.c 2011-11-12 12:47:14.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 c3954fb..674952c 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 = tty_ldisc_N_TTY; ops->owner = NULL; @@ -35749,9 +36742,10 @@ diff -urNp linux-3.0.9/drivers/tty/n_tty.c linux-3.0.9/drivers/tty/n_tty.c + ops->flags = 0; } EXPORT_SYMBOL_GPL(n_tty_inherit_ops); -diff -urNp linux-3.0.9/drivers/tty/pty.c linux-3.0.9/drivers/tty/pty.c ---- linux-3.0.9/drivers/tty/pty.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/pty.c 2011-11-12 12:47:14.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); @@ -35764,10 +36758,11 @@ diff -urNp linux-3.0.9/drivers/tty/pty.c linux-3.0.9/drivers/tty/pty.c cdev_init(&ptmx_cdev, &ptmx_fops); if (cdev_add(&ptmx_cdev, MKDEV(TTYAUX_MAJOR, 2), 1) || -diff -urNp linux-3.0.9/drivers/tty/rocket.c linux-3.0.9/drivers/tty/rocket.c ---- linux-3.0.9/drivers/tty/rocket.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/rocket.c 2011-11-12 12:47:14.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 13043e8..19f322b 100644 +--- a/drivers/tty/rocket.c ++++ b/drivers/tty/rocket.c +@@ -1277,6 +1277,8 @@ static int get_ports(struct r_port *info, struct rocket_ports __user *retports) struct rocket_ports tmp; int board; @@ -35776,9 +36771,10 @@ diff -urNp linux-3.0.9/drivers/tty/rocket.c linux-3.0.9/drivers/tty/rocket.c if (!retports) return -EFAULT; memset(&tmp, 0, sizeof (tmp)); -diff -urNp linux-3.0.9/drivers/tty/serial/kgdboc.c linux-3.0.9/drivers/tty/serial/kgdboc.c ---- linux-3.0.9/drivers/tty/serial/kgdboc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/serial/kgdboc.c 2011-11-12 12:47:14.000000000 -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 @@ -35852,7 +36848,7 @@ diff -urNp linux-3.0.9/drivers/tty/serial/kgdboc.c linux-3.0.9/drivers/tty/seria return 0; 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] == '\n') config[len - 1] = '\0'; @@ -35877,10 +36873,11 @@ diff -urNp linux-3.0.9/drivers/tty/serial/kgdboc.c linux-3.0.9/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.0.9/drivers/tty/serial/mfd.c linux-3.0.9/drivers/tty/serial/mfd.c ---- linux-3.0.9/drivers/tty/serial/mfd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/serial/mfd.c 2011-11-12 12:47:14.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) } /* First 3 are UART ports, and the 4th is the DMA */ @@ -35889,10 +36886,11 @@ diff -urNp linux-3.0.9/drivers/tty/serial/mfd.c linux-3.0.9/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.0.9/drivers/tty/serial/mrst_max3110.c linux-3.0.9/drivers/tty/serial/mrst_max3110.c ---- linux-3.0.9/drivers/tty/serial/mrst_max3110.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/serial/mrst_max3110.c 2011-11-12 12:47:14.000000000 -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 = 1, num, total = 0; u8 recv_buf[512], *pbuf; @@ -35901,9 +36899,10 @@ diff -urNp linux-3.0.9/drivers/tty/serial/mrst_max3110.c linux-3.0.9/drivers/tty pbuf = recv_buf; do { num = max3110_read_multi(max, pbuf); -diff -urNp linux-3.0.9/drivers/tty/tty_io.c linux-3.0.9/drivers/tty/tty_io.c ---- linux-3.0.9/drivers/tty/tty_io.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/tty_io.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c +index b44aef0..c5ad11d 100644 +--- a/drivers/tty/tty_io.c ++++ b/drivers/tty/tty_io.c @@ -3238,7 +3238,7 @@ EXPORT_SYMBOL_GPL(get_current_tty); void tty_default_fops(struct file_operations *fops) @@ -35913,10 +36912,11 @@ diff -urNp linux-3.0.9/drivers/tty/tty_io.c linux-3.0.9/drivers/tty/tty_io.c } /* -diff -urNp linux-3.0.9/drivers/tty/tty_ldisc.c linux-3.0.9/drivers/tty/tty_ldisc.c ---- linux-3.0.9/drivers/tty/tty_ldisc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/tty_ldisc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -74,7 +74,7 @@ static void put_ldisc(struct tty_ldisc * +diff --git a/drivers/tty/tty_ldisc.c b/drivers/tty/tty_ldisc.c +index ef925d5..6ddb00e 100644 +--- a/drivers/tty/tty_ldisc.c ++++ b/drivers/tty/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 = ld->ops; @@ -35925,7 +36925,7 @@ diff -urNp linux-3.0.9/drivers/tty/tty_ldisc.c linux-3.0.9/drivers/tty/tty_ldisc module_put(ldo->owner); spin_unlock_irqrestore(&tty_ldisc_lock, flags); -@@ -109,7 +109,7 @@ int tty_register_ldisc(int disc, struct +@@ -109,7 +109,7 @@ int tty_register_ldisc(int disc, struct tty_ldisc_ops *new_ldisc) spin_lock_irqsave(&tty_ldisc_lock, flags); tty_ldiscs[disc] = new_ldisc; new_ldisc->num = disc; @@ -35943,7 +36943,7 @@ diff -urNp linux-3.0.9/drivers/tty/tty_ldisc.c linux-3.0.9/drivers/tty/tty_ldisc ret = -EBUSY; else tty_ldiscs[disc] = 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 = ERR_PTR(-EAGAIN); if (try_module_get(ldops->owner)) { @@ -35952,7 +36952,7 @@ diff -urNp linux-3.0.9/drivers/tty/tty_ldisc.c linux-3.0.9/drivers/tty/tty_ldisc ret = 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; spin_lock_irqsave(&tty_ldisc_lock, flags); @@ -35961,10 +36961,11 @@ diff -urNp linux-3.0.9/drivers/tty/tty_ldisc.c linux-3.0.9/drivers/tty/tty_ldisc module_put(ldops->owner); spin_unlock_irqrestore(&tty_ldisc_lock, flags); } -diff -urNp linux-3.0.9/drivers/tty/vt/keyboard.c linux-3.0.9/drivers/tty/vt/keyboard.c ---- linux-3.0.9/drivers/tty/vt/keyboard.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/vt/keyboard.c 2011-11-12 12:47:14.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 char value, char up_flag) kbd->kbdmode == VC_OFF) && value != KVAL(K_SAK)) return; /* SAK is allowed even in raw mode */ @@ -35981,10 +36982,11 @@ diff -urNp linux-3.0.9/drivers/tty/vt/keyboard.c linux-3.0.9/drivers/tty/vt/keyb fn_handler[value](vc); } -diff -urNp linux-3.0.9/drivers/tty/vt/vt.c linux-3.0.9/drivers/tty/vt/vt.c ---- linux-3.0.9/drivers/tty/vt/vt.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/vt/vt.c 2011-11-12 12:47:14.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); static void notify_write(struct vc_data *vc, unsigned int unicode) { @@ -35993,10 +36995,11 @@ diff -urNp linux-3.0.9/drivers/tty/vt/vt.c linux-3.0.9/drivers/tty/vt/vt.c atomic_notifier_call_chain(&vt_notifier_list, VT_WRITE, ¶m); } -diff -urNp linux-3.0.9/drivers/tty/vt/vt_ioctl.c linux-3.0.9/drivers/tty/vt/vt_ioctl.c ---- linux-3.0.9/drivers/tty/vt/vt_ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/tty/vt/vt_ioctl.c 2011-11-12 12:47:14.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_kbe, int perm, struct kbd_str if (copy_from_user(&tmp, user_kbe, sizeof(struct kbentry))) return -EFAULT; @@ -36006,7 +37009,7 @@ diff -urNp linux-3.0.9/drivers/tty/vt/vt_ioctl.c linux-3.0.9/drivers/tty/vt/vt_i switch (cmd) { case KDGKBENT: key_map = 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_kbe, int perm, struct kbd_str val = (i ? K_HOLE : K_NOSUCHMAP); return put_user(val, &user_kbe->kb_value); case KDSKBENT: @@ -36016,7 +37019,7 @@ diff -urNp linux-3.0.9/drivers/tty/vt/vt_ioctl.c linux-3.0.9/drivers/tty/vt/vt_i if (!perm) return -EPERM; if (!i && v == K_NOSUCHMAP) { -@@ -322,9 +322,6 @@ do_kdgkb_ioctl(int cmd, struct kbsentry +@@ -322,9 +322,6 @@ do_kdgkb_ioctl(int cmd, struct kbsentry __user *user_kdgkb, int perm) int i, j, k; int ret; @@ -36026,7 +37029,7 @@ diff -urNp linux-3.0.9/drivers/tty/vt/vt_ioctl.c linux-3.0.9/drivers/tty/vt/vt_i kbs = kmalloc(sizeof(*kbs), GFP_KERNEL); if (!kbs) { ret = -ENOMEM; -@@ -358,6 +355,9 @@ do_kdgkb_ioctl(int cmd, struct kbsentry +@@ -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: @@ -36036,9 +37039,10 @@ diff -urNp linux-3.0.9/drivers/tty/vt/vt_ioctl.c linux-3.0.9/drivers/tty/vt/vt_i if (!perm) { ret = -EPERM; goto reterr; -diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/drivers/uio/uio.c ---- linux-3.0.9/drivers/uio/uio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/uio/uio.c 2011-11-12 12:47:14.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 <linux/kobject.h> #include <linux/cdev.h> @@ -36060,7 +37064,7 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/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 +@@ -242,7 +243,7 @@ static ssize_t show_event(struct device *dev, struct device_attribute *attr, char *buf) { struct uio_device *idev = dev_get_drvdata(dev); @@ -36069,7 +37073,7 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/drivers/uio/uio.c } static struct device_attribute uio_class_attributes[] = { -@@ -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 = info->uio_dev; @@ -36078,7 +37082,7 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/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) } listener->dev = idev; @@ -36087,7 +37091,7 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/drivers/uio/uio.c filep->private_data = listener; 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, poll_table *wait) return -EIO; poll_wait(filep, &idev->wait, wait); @@ -36096,7 +37100,7 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/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 __user *buf, do { set_current_state(TASK_INTERRUPTIBLE); @@ -36105,7 +37109,7 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/drivers/uio/uio.c if (event_count != listener->event_count) { if (copy_to_user(buf, &event_count, count)) retval = -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_struct *vma) static void uio_vma_open(struct vm_area_struct *vma) { struct uio_device *idev = vma->vm_private_data; @@ -36121,7 +37125,7 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/drivers/uio/uio.c } static int uio_vma_fault(struct vm_area_struct *vma, struct vm_fault *vmf) -@@ -823,7 +824,7 @@ int __uio_register_device(struct module +@@ -823,7 +824,7 @@ int __uio_register_device(struct module *owner, idev->owner = owner; idev->info = info; init_waitqueue_head(&idev->wait); @@ -36130,10 +37134,11 @@ diff -urNp linux-3.0.9/drivers/uio/uio.c linux-3.0.9/drivers/uio/uio.c ret = uio_get_minor(idev); if (ret) -diff -urNp linux-3.0.9/drivers/usb/atm/cxacru.c linux-3.0.9/drivers/usb/atm/cxacru.c ---- linux-3.0.9/drivers/usb/atm/cxacru.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/atm/cxacru.c 2011-11-12 12:47:14.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 = sscanf(buf + pos, "%x=%x%n", &index, &value, &tmp); if (ret < 2) return -EINVAL; @@ -36142,10 +37147,11 @@ diff -urNp linux-3.0.9/drivers/usb/atm/cxacru.c linux-3.0.9/drivers/usb/atm/cxac return -EINVAL; pos += tmp; -diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usbatm.c ---- linux-3.0.9/drivers/usb/atm/usbatm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/atm/usbatm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -332,7 +332,7 @@ static void usbatm_extract_one_cell(stru +diff --git a/drivers/usb/atm/usbatm.c b/drivers/usb/atm/usbatm.c +index 989e16e..32c4bc7 100644 +--- a/drivers/usb/atm/usbatm.c ++++ b/drivers/usb/atm/usbatm.c +@@ -332,7 +332,7 @@ static void usbatm_extract_one_cell(struct usbatm_data *instance, unsigned char if (printk_ratelimit()) atm_warn(instance, "%s: OAM not supported (vpi %d, vci %d)!\n", __func__, vpi, vci); @@ -36154,7 +37160,7 @@ diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usba return; } -@@ -360,7 +360,7 @@ static void usbatm_extract_one_cell(stru +@@ -360,7 +360,7 @@ static void usbatm_extract_one_cell(struct usbatm_data *instance, unsigned char if (length > ATM_MAX_AAL5_PDU) { atm_rldbg(instance, "%s: bogus length %u (vcc: 0x%p)!\n", __func__, length, vcc); @@ -36163,7 +37169,7 @@ diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usba goto out; } -@@ -369,14 +369,14 @@ static void usbatm_extract_one_cell(stru +@@ -369,14 +369,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); @@ -36180,7 +37186,7 @@ diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usba goto out; } -@@ -386,7 +386,7 @@ static void usbatm_extract_one_cell(stru +@@ -386,7 +386,7 @@ static void usbatm_extract_one_cell(struct usbatm_data *instance, unsigned char if (printk_ratelimit()) atm_err(instance, "%s: no memory for skb (length: %u)!\n", __func__, length); @@ -36189,7 +37195,7 @@ diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usba goto out; } -@@ -411,7 +411,7 @@ static void usbatm_extract_one_cell(stru +@@ -411,7 +411,7 @@ static void usbatm_extract_one_cell(struct usbatm_data *instance, unsigned char vcc->push(vcc, skb); @@ -36198,7 +37204,7 @@ diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usba out: skb_trim(sarb, 0); } -@@ -614,7 +614,7 @@ static void usbatm_tx_process(unsigned l +@@ -614,7 +614,7 @@ static void usbatm_tx_process(unsigned long data) struct atm_vcc *vcc = UDSL_SKB(skb)->atm.vcc; usbatm_pop(vcc, skb); @@ -36207,7 +37213,7 @@ diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usba skb = 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 *atm_dev, loff_t * pos, char *pag if (!left--) return sprintf(page, "AAL5: tx %d ( %d err ), rx %d ( %d err, %d drop )\n", @@ -36224,9 +37230,10 @@ diff -urNp linux-3.0.9/drivers/usb/atm/usbatm.c linux-3.0.9/drivers/usb/atm/usba if (!left--) { if (instance->disconnected) -diff -urNp linux-3.0.9/drivers/usb/core/devices.c linux-3.0.9/drivers/usb/core/devices.c ---- linux-3.0.9/drivers/usb/core/devices.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/core/devices.c 2011-11-12 12:47:14.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[] = * time it gets called. */ @@ -36236,7 +37243,7 @@ diff -urNp linux-3.0.9/drivers/usb/core/devices.c linux-3.0.9/drivers/usb/core/d wait_queue_head_t wait; } device_event = { .count = 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[] = { void usbfs_conn_disc_event(void) { @@ -36245,7 +37252,7 @@ diff -urNp linux-3.0.9/drivers/usb/core/devices.c linux-3.0.9/drivers/usb/core/d wake_up(&device_event.wait); } -@@ -648,7 +648,7 @@ static unsigned int usb_device_poll(stru +@@ -648,7 +648,7 @@ static unsigned int usb_device_poll(struct file *file, poll_wait(file, &device_event.wait, wait); @@ -36254,10 +37261,11 @@ diff -urNp linux-3.0.9/drivers/usb/core/devices.c linux-3.0.9/drivers/usb/core/d if (file->f_version != event_count) { file->f_version = event_count; return POLLIN | POLLRDNORM; -diff -urNp linux-3.0.9/drivers/usb/core/message.c linux-3.0.9/drivers/usb/core/message.c ---- linux-3.0.9/drivers/usb/core/message.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/core/message.c 2011-11-12 12:47:14.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 = kmalloc(MAX_USB_STRING_SIZE, GFP_NOIO); if (buf) { len = usb_string(udev, index, buf, MAX_USB_STRING_SIZE); @@ -36268,10 +37276,11 @@ diff -urNp linux-3.0.9/drivers/usb/core/message.c linux-3.0.9/drivers/usb/core/m if (!smallbuf) return buf; memcpy(smallbuf, buf, len); -diff -urNp linux-3.0.9/drivers/usb/early/ehci-dbgp.c linux-3.0.9/drivers/usb/early/ehci-dbgp.c ---- linux-3.0.9/drivers/usb/early/ehci-dbgp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/early/ehci-dbgp.c 2011-11-12 12:47:14.000000000 -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) #ifdef CONFIG_KGDB static struct kgdb_io kgdbdbgp_io_ops; @@ -36281,7 +37290,7 @@ diff -urNp linux-3.0.9/drivers/usb/early/ehci-dbgp.c linux-3.0.9/drivers/usb/ear #else #define dbgp_kgdb_mode (0) #endif -@@ -1035,6 +1036,13 @@ static struct kgdb_io kgdbdbgp_io_ops = +@@ -1035,6 +1036,13 @@ static struct kgdb_io kgdbdbgp_io_ops = { .write_char = kgdbdbgp_write_char, }; @@ -36295,7 +37304,7 @@ diff -urNp linux-3.0.9/drivers/usb/early/ehci-dbgp.c linux-3.0.9/drivers/usb/ear static int kgdbdbgp_wait_time; 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 = simple_strtoul(ptr, &ptr, 10); } @@ -36308,10 +37317,11 @@ diff -urNp linux-3.0.9/drivers/usb/early/ehci-dbgp.c linux-3.0.9/drivers/usb/ear return 0; } -diff -urNp linux-3.0.9/drivers/usb/host/xhci-mem.c linux-3.0.9/drivers/usb/host/xhci-mem.c ---- linux-3.0.9/drivers/usb/host/xhci-mem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/host/xhci-mem.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1690,6 +1690,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 104620b..af0338a 100644 +--- a/drivers/usb/host/xhci-mem.c ++++ b/drivers/usb/host/xhci-mem.c +@@ -1690,6 +1690,8 @@ static int xhci_check_trb_in_td_math(struct xhci_hcd *xhci, gfp_t mem_flags) unsigned int num_tests; int i, ret; @@ -36320,9 +37330,10 @@ diff -urNp linux-3.0.9/drivers/usb/host/xhci-mem.c linux-3.0.9/drivers/usb/host/ num_tests = ARRAY_SIZE(simple_test_vector); for (i = 0; i < num_tests; i++) { ret = xhci_test_trb_in_td(xhci, -diff -urNp linux-3.0.9/drivers/usb/wusbcore/wa-hc.h linux-3.0.9/drivers/usb/wusbcore/wa-hc.h ---- linux-3.0.9/drivers/usb/wusbcore/wa-hc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/wusbcore/wa-hc.h 2011-11-12 12:47:14.000000000 -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; @@ -36332,7 +37343,7 @@ diff -urNp linux-3.0.9/drivers/usb/wusbcore/wa-hc.h linux-3.0.9/drivers/usb/wusb }; -@@ -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); @@ -36341,9 +37352,10 @@ diff -urNp linux-3.0.9/drivers/usb/wusbcore/wa-hc.h linux-3.0.9/drivers/usb/wusb } /** -diff -urNp linux-3.0.9/drivers/usb/wusbcore/wa-xfer.c linux-3.0.9/drivers/usb/wusbcore/wa-xfer.c ---- linux-3.0.9/drivers/usb/wusbcore/wa-xfer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/usb/wusbcore/wa-xfer.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/usb/wusbcore/wa-xfer.c b/drivers/usb/wusbcore/wa-xfer.c +index 6ccd93a..8aad238 100644 +--- a/drivers/usb/wusbcore/wa-xfer.c ++++ b/drivers/usb/wusbcore/wa-xfer.c @@ -294,7 +294,7 @@ out: */ static void wa_xfer_id_init(struct wa_xfer *xfer) @@ -36353,10 +37365,11 @@ diff -urNp linux-3.0.9/drivers/usb/wusbcore/wa-xfer.c linux-3.0.9/drivers/usb/wu } /* -diff -urNp linux-3.0.9/drivers/vhost/vhost.c linux-3.0.9/drivers/vhost/vhost.c ---- linux-3.0.9/drivers/vhost/vhost.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/vhost/vhost.c 2011-11-12 12:47:14.000000000 -0500 -@@ -589,7 +589,7 @@ static int init_used(struct vhost_virtqu +diff --git a/drivers/vhost/vhost.c b/drivers/vhost/vhost.c +index ea966b3..7b64792 100644 +--- a/drivers/vhost/vhost.c ++++ b/drivers/vhost/vhost.c +@@ -589,7 +589,7 @@ static int init_used(struct vhost_virtqueue *vq, return get_user(vq->last_used_idx, &used->idx); } @@ -36365,9 +37378,10 @@ diff -urNp linux-3.0.9/drivers/vhost/vhost.c linux-3.0.9/drivers/vhost/vhost.c { struct file *eventfp, *filep = NULL, *pollstart = NULL, *pollstop = NULL; -diff -urNp linux-3.0.9/drivers/video/aty/aty128fb.c linux-3.0.9/drivers/video/aty/aty128fb.c ---- linux-3.0.9/drivers/video/aty/aty128fb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/aty/aty128fb.c 2011-11-12 12:47:14.000000000 -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 { }; @@ -36377,10 +37391,11 @@ diff -urNp linux-3.0.9/drivers/video/aty/aty128fb.c linux-3.0.9/drivers/video/at "AGP", "PCI", "PRO AGP", -diff -urNp linux-3.0.9/drivers/video/fbcmap.c linux-3.0.9/drivers/video/fbcmap.c ---- linux-3.0.9/drivers/video/fbcmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/fbcmap.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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, struct fb_info *info) rc = -ENODEV; goto out; } @@ -36390,10 +37405,11 @@ diff -urNp linux-3.0.9/drivers/video/fbcmap.c linux-3.0.9/drivers/video/fbcmap.c rc = -EINVAL; goto out1; } -diff -urNp linux-3.0.9/drivers/video/fbmem.c linux-3.0.9/drivers/video/fbmem.c ---- linux-3.0.9/drivers/video/fbmem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/fbmem.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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, struct fb_image *image, image->dx += image->width + 8; } } else if (rotate == FB_ROTATE_UD) { @@ -36402,7 +37418,7 @@ diff -urNp linux-3.0.9/drivers/video/fbmem.c linux-3.0.9/drivers/video/fbmem.c info->fbops->fb_imageblit(info, image); image->dx -= 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, struct fb_image *image, image->dy += image->height + 8; } } else if (rotate == FB_ROTATE_CCW) { @@ -36411,7 +37427,7 @@ diff -urNp linux-3.0.9/drivers/video/fbmem.c linux-3.0.9/drivers/video/fbmem.c info->fbops->fb_imageblit(info, image); image->dy -= image->height + 8; } -@@ -939,6 +939,8 @@ fb_set_var(struct fb_info *info, struct +@@ -939,6 +939,8 @@ fb_set_var(struct fb_info *info, struct fb_var_screeninfo *var) int flags = info->flags; int ret = 0; @@ -36420,7 +37436,7 @@ diff -urNp linux-3.0.9/drivers/video/fbmem.c linux-3.0.9/drivers/video/fbmem.c if (var->activate & FB_ACTIVATE_INV_MODE) { struct fb_videomode mode1, mode2; -@@ -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, unsigned int cmd, void __user *argp = (void __user *)arg; long ret = 0; @@ -36429,7 +37445,7 @@ diff -urNp linux-3.0.9/drivers/video/fbmem.c linux-3.0.9/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, unsigned int cmd, return -EFAULT; if (con2fb.console < 1 || con2fb.console > MAX_NR_CONSOLES) return -EINVAL; @@ -36438,9 +37454,10 @@ diff -urNp linux-3.0.9/drivers/video/fbmem.c linux-3.0.9/drivers/video/fbmem.c return -EINVAL; if (!registered_fb[con2fb.framebuffer]) request_module("fb%d", con2fb.framebuffer); -diff -urNp linux-3.0.9/drivers/video/geode/gx1fb_core.c linux-3.0.9/drivers/video/geode/gx1fb_core.c ---- linux-3.0.9/drivers/video/geode/gx1fb_core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/geode/gx1fb_core.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/video/geode/gx1fb_core.c b/drivers/video/geode/gx1fb_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 = 1; static char panel_option[32] = ""; @@ -36450,9 +37467,10 @@ diff -urNp linux-3.0.9/drivers/video/geode/gx1fb_core.c linux-3.0.9/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.0.9/drivers/video/gxt4500.c linux-3.0.9/drivers/video/gxt4500.c ---- linux-3.0.9/drivers/video/gxt4500.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/gxt4500.c 2011-11-12 12:47:14.000000000 -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; @@ -36462,7 +37480,7 @@ diff -urNp linux-3.0.9/drivers/video/gxt4500.c linux-3.0.9/drivers/video/gxt4500 .refresh = 60, .xres = 1280, .yres = 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; } @@ -36471,10 +37489,11 @@ diff -urNp linux-3.0.9/drivers/video/gxt4500.c linux-3.0.9/drivers/video/gxt4500 .id = "IBM GXT4500P", .type = FB_TYPE_PACKED_PIXELS, .visual = FB_VISUAL_PSEUDOCOLOR, -diff -urNp linux-3.0.9/drivers/video/i810/i810_accel.c linux-3.0.9/drivers/video/i810/i810_accel.c ---- linux-3.0.9/drivers/video/i810/i810_accel.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/i810/i810_accel.c 2011-11-12 12:47:14.000000000 -0500 -@@ -73,6 +73,7 @@ static inline int wait_for_space(struct +diff --git a/drivers/video/i810/i810_accel.c b/drivers/video/i810/i810_accel.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"); @@ -36482,10 +37501,11 @@ diff -urNp linux-3.0.9/drivers/video/i810/i810_accel.c linux-3.0.9/drivers/video i810_report_error(mmio); par->dev_flags |= LOCKUP; info->pixmap.scan_align = 1; -diff -urNp linux-3.0.9/drivers/video/i810/i810_main.c linux-3.0.9/drivers/video/i810/i810_main.c ---- linux-3.0.9/drivers/video/i810/i810_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/i810/i810_main.c 2011-11-12 12:47:14.000000000 -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_main.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 fb_info *info); static void i810fb_release_resource (struct fb_info *info, struct i810fb_par *par); /* PCI */ @@ -36494,9 +37514,10 @@ diff -urNp linux-3.0.9/drivers/video/i810/i810_main.c linux-3.0.9/drivers/video/ "Intel(R) 810 Framebuffer Device" , "Intel(R) 810-DC100 Framebuffer Device" , "Intel(R) 810E Framebuffer Device" , -diff -urNp linux-3.0.9/drivers/video/jz4740_fb.c linux-3.0.9/drivers/video/jz4740_fb.c ---- linux-3.0.9/drivers/video/jz4740_fb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/jz4740_fb.c 2011-11-12 12:47:14.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]; }; @@ -36506,9 +37527,10 @@ diff -urNp linux-3.0.9/drivers/video/jz4740_fb.c linux-3.0.9/drivers/video/jz474 .id = "JZ4740 FB", .type = FB_TYPE_PACKED_PIXELS, .visual = FB_VISUAL_TRUECOLOR, -diff -urNp linux-3.0.9/drivers/video/logo/logo_linux_clut224.ppm linux-3.0.9/drivers/video/logo/logo_linux_clut224.ppm ---- linux-3.0.9/drivers/video/logo/logo_linux_clut224.ppm 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/logo/logo_linux_clut224.ppm 2011-11-12 12:47:14.000000000 -0500 +diff --git a/drivers/video/logo/logo_linux_clut224.ppm b/drivers/video/logo/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 @@ -39234,10 +40256,11 @@ diff -urNp linux-3.0.9/drivers/video/logo/logo_linux_clut224.ppm linux-3.0.9/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.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c ---- linux-3.0.9/drivers/video/udlfb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/udlfb.c 2011-11-12 12:47:14.000000000 -0500 -@@ -586,11 +586,11 @@ int dlfb_handle_damage(struct dlfb_data +diff --git a/drivers/video/udlfb.c b/drivers/video/udlfb.c +index 816a4fd..5f1c678 100644 +--- a/drivers/video/udlfb.c ++++ b/drivers/video/udlfb.c +@@ -586,11 +586,11 @@ int dlfb_handle_damage(struct dlfb_data *dev, int x, int y, dlfb_urb_completion(urb); error: @@ -39253,7 +40276,7 @@ diff -urNp linux-3.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c >> 10)), /* Kcycles */ &dev->cpu_kcycles_used); -@@ -711,11 +711,11 @@ static void dlfb_dpy_deferred_io(struct +@@ -711,11 +711,11 @@ static void dlfb_dpy_deferred_io(struct fb_info *info, dlfb_urb_completion(urb); error: @@ -39269,7 +40292,7 @@ diff -urNp linux-3.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c >> 10)), /* Kcycles */ &dev->cpu_kcycles_used); } -@@ -1307,7 +1307,7 @@ static ssize_t metrics_bytes_rendered_sh +@@ -1307,7 +1307,7 @@ static ssize_t metrics_bytes_rendered_show(struct device *fbdev, struct fb_info *fb_info = dev_get_drvdata(fbdev); struct dlfb_data *dev = fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -39278,7 +40301,7 @@ diff -urNp linux-3.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c } static ssize_t metrics_bytes_identical_show(struct device *fbdev, -@@ -1315,7 +1315,7 @@ static ssize_t metrics_bytes_identical_s +@@ -1315,7 +1315,7 @@ static ssize_t metrics_bytes_identical_show(struct device *fbdev, struct fb_info *fb_info = dev_get_drvdata(fbdev); struct dlfb_data *dev = fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -39287,7 +40310,7 @@ diff -urNp linux-3.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c } static ssize_t metrics_bytes_sent_show(struct device *fbdev, -@@ -1323,7 +1323,7 @@ static ssize_t metrics_bytes_sent_show(s +@@ -1323,7 +1323,7 @@ static ssize_t metrics_bytes_sent_show(struct device *fbdev, struct fb_info *fb_info = dev_get_drvdata(fbdev); struct dlfb_data *dev = fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -39296,7 +40319,7 @@ diff -urNp linux-3.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c } static ssize_t metrics_cpu_kcycles_used_show(struct device *fbdev, -@@ -1331,7 +1331,7 @@ static ssize_t metrics_cpu_kcycles_used_ +@@ -1331,7 +1331,7 @@ static ssize_t metrics_cpu_kcycles_used_show(struct device *fbdev, struct fb_info *fb_info = dev_get_drvdata(fbdev); struct dlfb_data *dev = fb_info->par; return snprintf(buf, PAGE_SIZE, "%u\n", @@ -39305,7 +40328,7 @@ diff -urNp linux-3.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c } static ssize_t edid_show( -@@ -1388,10 +1388,10 @@ static ssize_t metrics_reset_store(struc +@@ -1388,10 +1388,10 @@ static ssize_t metrics_reset_store(struct device *fbdev, struct fb_info *fb_info = dev_get_drvdata(fbdev); struct dlfb_data *dev = fb_info->par; @@ -39320,9 +40343,10 @@ diff -urNp linux-3.0.9/drivers/video/udlfb.c linux-3.0.9/drivers/video/udlfb.c return count; } -diff -urNp linux-3.0.9/drivers/video/uvesafb.c linux-3.0.9/drivers/video/uvesafb.c ---- linux-3.0.9/drivers/video/uvesafb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/uvesafb.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/io.h> #include <linux/mutex.h> @@ -39340,7 +40364,7 @@ diff -urNp linux-3.0.9/drivers/video/uvesafb.c linux-3.0.9/drivers/video/uvesafb } /* -@@ -569,10 +570,32 @@ static int __devinit uvesafb_vbe_getpmi( +@@ -569,10 +570,32 @@ static int __devinit uvesafb_vbe_getpmi(struct uvesafb_ktask *task, if ((task->t.regs.eax & 0xffff) != 0x4f || task->t.regs.es < 0xc000) { par->pmi_setpal = par->ypan = 0; } else { @@ -39385,7 +40409,7 @@ diff -urNp linux-3.0.9/drivers/video/uvesafb.c linux-3.0.9/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); @@ -39398,9 +40422,10 @@ diff -urNp linux-3.0.9/drivers/video/uvesafb.c linux-3.0.9/drivers/video/uvesafb } framebuffer_release(info); -diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/drivers/video/vesafb.c ---- linux-3.0.9/drivers/video/vesafb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/vesafb.c 2011-11-12 12:47:14.000000000 -0500 +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 @@ */ @@ -39409,7 +40434,7 @@ diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/drivers/video/vesafb.c #include <linux/kernel.h> #include <linux/errno.h> #include <linux/string.h> -@@ -52,8 +53,8 @@ static int vram_remap __initdata; /* +@@ -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 = 1; /* pmi for palette changes ??? */ static int ypan __read_mostly; /* 0..nothing, 1..ypan, 2..ywrap */ @@ -39420,7 +40445,7 @@ diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/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_device *dev) unsigned int size_vmode; unsigned int size_remap; unsigned int size_total; @@ -39428,7 +40453,7 @@ diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/drivers/video/vesafb.c if (screen_info.orig_video_isVGA != 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_device *dev) size_remap = size_total; vesafb_fix.smem_len = size_remap; @@ -39439,7 +40464,7 @@ diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/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_device *dev) printk(KERN_INFO "vesafb: mode is %dx%dx%d, linelength=%d, pages=%d\n", vesafb_defined.xres, vesafb_defined.yres, vesafb_defined.bits_per_pixel, vesafb_fix.line_length, screen_info.pages); @@ -39463,7 +40488,7 @@ diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/drivers/video/vesafb.c } 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_device *dev) if (ypan || pmi_setpal) { unsigned short *pmi_base; @@ -39491,7 +40516,7 @@ diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/drivers/video/vesafb.c printk(KERN_INFO "vesafb: pmi: set display start = %p, set palette = %p\n",pmi_start,pmi_pal); if (pmi_base[3]) { printk(KERN_INFO "vesafb: pmi: ports = "); -@@ -488,6 +514,11 @@ static int __init vesafb_probe(struct pl +@@ -488,6 +514,11 @@ static int __init vesafb_probe(struct platform_device *dev) info->node, info->fix.id); return 0; err: @@ -39503,9 +40528,10 @@ diff -urNp linux-3.0.9/drivers/video/vesafb.c linux-3.0.9/drivers/video/vesafb.c if (info->screen_base) iounmap(info->screen_base); framebuffer_release(info); -diff -urNp linux-3.0.9/drivers/video/via/via_clock.h linux-3.0.9/drivers/video/via/via_clock.h ---- linux-3.0.9/drivers/video/via/via_clock.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/video/via/via_clock.h 2011-11-12 12:47:14.000000000 -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 { void (*set_engine_pll_state)(u8 state); @@ -39515,10 +40541,11 @@ diff -urNp linux-3.0.9/drivers/video/via/via_clock.h linux-3.0.9/drivers/video/v static inline u32 get_pll_internal_frequency(u32 ref_freq, -diff -urNp linux-3.0.9/drivers/virtio/virtio_balloon.c linux-3.0.9/drivers/virtio/virtio_balloon.c ---- linux-3.0.9/drivers/virtio/virtio_balloon.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/drivers/virtio/virtio_balloon.c 2011-11-12 12:47:14.000000000 -0500 -@@ -174,6 +174,8 @@ static void update_balloon_stats(struct +diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.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_balloon *vb) struct sysinfo i; int idx = 0; @@ -39527,10 +40554,11 @@ diff -urNp linux-3.0.9/drivers/virtio/virtio_balloon.c linux-3.0.9/drivers/virti all_vm_events(events); si_meminfo(&i); -diff -urNp linux-3.0.9/fs/9p/vfs_inode.c linux-3.0.9/fs/9p/vfs_inode.c ---- linux-3.0.9/fs/9p/vfs_inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/9p/vfs_inode.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1264,7 +1264,7 @@ static void *v9fs_vfs_follow_link(struct +diff --git a/fs/9p/vfs_inode.c b/fs/9p/vfs_inode.c +index c72e20c..b8a3f73 100644 +--- a/fs/9p/vfs_inode.c ++++ b/fs/9p/vfs_inode.c +@@ -1264,7 +1264,7 @@ static void *v9fs_vfs_follow_link(struct dentry *dentry, struct nameidata *nd) void v9fs_vfs_put_link(struct dentry *dentry, struct nameidata *nd, void *p) { @@ -39539,10 +40567,24 @@ diff -urNp linux-3.0.9/fs/9p/vfs_inode.c linux-3.0.9/fs/9p/vfs_inode.c P9_DPRINTK(P9_DEBUG_VFS, " %s %s\n", dentry->d_name.name, IS_ERR(s) ? "<error>" : s); -diff -urNp linux-3.0.9/fs/aio.c linux-3.0.9/fs/aio.c ---- linux-3.0.9/fs/aio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/aio.c 2011-11-12 12:47:14.000000000 -0500 -@@ -119,7 +119,7 @@ static int aio_setup_ring(struct kioctx +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 + + 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 += sizeof(struct io_event) * nr_events; nr_pages = (size + PAGE_SIZE-1) >> PAGE_SHIFT; @@ -39551,7 +40593,7 @@ diff -urNp linux-3.0.9/fs/aio.c linux-3.0.9/fs/aio.c return -EINVAL; nr_events = (PAGE_SIZE * nr_pages - sizeof(struct aio_ring)) / sizeof(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 = 0; @@ -39560,7 +40602,7 @@ diff -urNp linux-3.0.9/fs/aio.c linux-3.0.9/fs/aio.c /* needed to zero any padding within an entry (there shouldn't be * 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, bool compat) { ssize_t ret; @@ -39590,10 +40632,11 @@ diff -urNp linux-3.0.9/fs/aio.c linux-3.0.9/fs/aio.c kiocb->ki_nr_segs = kiocb->ki_nbytes; kiocb->ki_cur_seg = 0; /* ki_nbytes/left now reflect bytes instead of segs */ -diff -urNp linux-3.0.9/fs/attr.c linux-3.0.9/fs/attr.c ---- linux-3.0.9/fs/attr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/attr.c 2011-11-12 12:47:14.000000000 -0500 -@@ -98,6 +98,7 @@ int inode_newsize_ok(const struct inode +diff --git a/fs/attr.c b/fs/attr.c +index caf2aa5..bb3ef8c 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; limit = rlimit(RLIMIT_FSIZE); @@ -39601,10 +40644,11 @@ diff -urNp linux-3.0.9/fs/attr.c linux-3.0.9/fs/attr.c if (limit != RLIM_INFINITY && offset > limit) goto out_sig; if (offset > inode->i_sb->s_maxbytes) -diff -urNp linux-3.0.9/fs/autofs4/waitq.c linux-3.0.9/fs/autofs4/waitq.c ---- linux-3.0.9/fs/autofs4/waitq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/autofs4/waitq.c 2011-11-12 12:47:14.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 2543598..3707be9 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; @@ -39613,10 +40657,11 @@ diff -urNp linux-3.0.9/fs/autofs4/waitq.c linux-3.0.9/fs/autofs4/waitq.c ssize_t wr = 0; /** WARNING: this is not safe for writing more than PIPE_BUF bytes! **/ -diff -urNp linux-3.0.9/fs/befs/linuxvfs.c linux-3.0.9/fs/befs/linuxvfs.c ---- linux-3.0.9/fs/befs/linuxvfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/befs/linuxvfs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -503,7 +503,7 @@ static void befs_put_link(struct dentry +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, struct nameidata *nd, void *p) { befs_inode_info *befs_ino = BEFS_I(dentry->d_inode); if (befs_ino->i_flags & BEFS_LONG_SYMLINK) { @@ -39625,9 +40670,10 @@ diff -urNp linux-3.0.9/fs/befs/linuxvfs.c linux-3.0.9/fs/befs/linuxvfs.c if (!IS_ERR(link)) kfree(link); } -diff -urNp linux-3.0.9/fs/binfmt_aout.c linux-3.0.9/fs/binfmt_aout.c ---- linux-3.0.9/fs/binfmt_aout.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/binfmt_aout.c 2011-11-12 12:47:14.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 <linux/string.h> #include <linux/fs.h> @@ -39636,7 +40682,7 @@ diff -urNp linux-3.0.9/fs/binfmt_aout.c linux-3.0.9/fs/binfmt_aout.c #include <linux/stat.h> #include <linux/fcntl.h> #include <linux/ptrace.h> -@@ -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) @@ -39645,7 +40691,7 @@ diff -urNp linux-3.0.9/fs/binfmt_aout.c linux-3.0.9/fs/binfmt_aout.c fs = get_fs(); set_fs(KERNEL_DS); has_dumped = 1; -@@ -97,10 +100,12 @@ static int aout_core_dump(struct coredum +@@ -97,10 +100,12 @@ static int aout_core_dump(struct coredump_params *cprm) /* 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. */ @@ -39658,7 +40704,7 @@ diff -urNp linux-3.0.9/fs/binfmt_aout.c linux-3.0.9/fs/binfmt_aout.c if ((dump.u_ssize + 1) * PAGE_SIZE > cprm->limit) dump.u_ssize = 0; -@@ -234,6 +239,8 @@ static int load_aout_binary(struct linux +@@ -234,6 +239,8 @@ static int load_aout_binary(struct linux_binprm * bprm, struct pt_regs * regs) rlim = rlimit(RLIMIT_DATA); if (rlim >= RLIM_INFINITY) rlim = ~0; @@ -39667,7 +40713,7 @@ diff -urNp linux-3.0.9/fs/binfmt_aout.c linux-3.0.9/fs/binfmt_aout.c if (ex.a_data + ex.a_bss > rlim) return -ENOMEM; -@@ -262,6 +269,27 @@ static int load_aout_binary(struct linux +@@ -262,6 +269,27 @@ static int load_aout_binary(struct linux_binprm * bprm, struct pt_regs * regs) install_exec_creds(bprm); current->flags &= ~PF_FORKNOEXEC; @@ -39695,7 +40741,7 @@ diff -urNp linux-3.0.9/fs/binfmt_aout.c linux-3.0.9/fs/binfmt_aout.c if (N_MAGIC(ex) == 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 * bprm, struct pt_regs * regs) down_write(¤t->mm->mmap_sem); error = do_mmap(bprm->file, N_DATADDR(ex), ex.a_data, @@ -39704,10 +40750,11 @@ diff -urNp linux-3.0.9/fs/binfmt_aout.c linux-3.0.9/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.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c ---- linux-3.0.9/fs/binfmt_elf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/binfmt_elf.c 2011-11-12 12:47:14.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 9ba2ac7..4c69f25 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 @@ -39718,7 +40765,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/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 = +@@ -70,6 +74,11 @@ static struct linux_binfmt elf_format = { .load_binary = load_elf_binary, .load_shlib = load_elf_library, .core_dump = elf_core_dump, @@ -39730,7 +40777,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c .min_coredump = ELF_EXEC_PAGESIZE, }; -@@ -77,6 +86,8 @@ static struct linux_binfmt elf_format = +@@ -77,6 +86,8 @@ static struct linux_binfmt elf_format = { static int set_brk(unsigned long start, unsigned long end) { @@ -39739,7 +40786,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c start = ELF_PAGEALIGN(start); end = ELF_PAGEALIGN(end); if (end > start) { -@@ -87,7 +98,7 @@ static int set_brk(unsigned long start, +@@ -87,7 +98,7 @@ static int set_brk(unsigned long start, unsigned long end) if (BAD_ADDR(addr)) return addr; } @@ -39748,7 +40795,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c return 0; } -@@ -148,12 +159,15 @@ create_elf_tables(struct linux_binprm *b +@@ -148,12 +159,15 @@ create_elf_tables(struct linux_binprm *bprm, struct elfhdr *exec, elf_addr_t __user *u_rand_bytes; const char *k_platform = ELF_PLATFORM; const char *k_base_platform = ELF_BASE_PLATFORM; @@ -39765,7 +40812,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c /* * 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)); @@ -39780,7 +40827,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c if (__copy_to_user(u_rand_bytes, k_rand_bytes, sizeof(k_rand_bytes))) return -EFAULT; -@@ -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 = p; @@ -39793,7 +40840,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/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; @@ -39806,7 +40853,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c unsigned long total_size; int retval, i, size; -@@ -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; } @@ -39818,7 +40865,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c eppnt = elf_phdata; for (i = 0; i < interp_elf_ex->e_phnum; i++, eppnt++) { if (eppnt->p_type == 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 = load_addr + eppnt->p_vaddr; if (BAD_ADDR(k) || eppnt->p_filesz > eppnt->p_memsz || @@ -40023,7 +41070,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c /* * These are the functions used to load ELF style executables and shared * 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 long stack_top) { unsigned int random_variable = 0; @@ -40035,7 +41082,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c if ((current->flags & PF_RANDOMIZE) && !(current->personality & ADDR_NO_RANDOMIZE)) { random_variable = 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 = 0, load_bias = 0; int load_addr_set = 0; char * elf_interpreter = NULL; @@ -40044,7 +41091,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/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 *bprm, struct pt_regs *regs) unsigned long start_code, end_code, start_data, end_data; unsigned long reloc_func_desc __maybe_unused = 0; int executable_stack = EXSTACK_DEFAULT; @@ -40057,7 +41104,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c loc = kmalloc(sizeof(*loc), GFP_KERNEL); if (!loc) { -@@ -714,11 +931,81 @@ static int load_elf_binary(struct linux_ +@@ -714,11 +931,81 @@ static int load_elf_binary(struct linux_binprm *bprm, struct pt_regs *regs) /* OK, This is the point of no return */ current->flags &= ~PF_FORKNOEXEC; @@ -40140,7 +41187,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c if (elf_read_implies_exec(loc->elf_ex, executable_stack)) current->personality |= READ_IMPLIES_EXEC; -@@ -809,6 +1096,20 @@ static int load_elf_binary(struct linux_ +@@ -809,6 +1096,20 @@ static int load_elf_binary(struct linux_binprm *bprm, struct pt_regs *regs) #else load_bias = ELF_PAGESTART(ELF_ET_DYN_BASE - vaddr); #endif @@ -40161,7 +41208,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c } error = elf_map(bprm->file, load_bias + vaddr, elf_ppnt, -@@ -841,9 +1142,9 @@ static int load_elf_binary(struct linux_ +@@ -841,9 +1142,9 @@ static int load_elf_binary(struct linux_binprm *bprm, struct pt_regs *regs) * allowed task size. Note that p_filesz must always be * <= p_memsz so it is only necessary to check p_memsz. */ @@ -40174,7 +41221,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c /* set_brk can never work. Avoid overflows. */ send_sig(SIGKILL, current, 0); retval = -EINVAL; -@@ -871,6 +1172,11 @@ static int load_elf_binary(struct linux_ +@@ -871,6 +1172,11 @@ static int load_elf_binary(struct linux_binprm *bprm, struct pt_regs *regs) start_data += load_bias; end_data += load_bias; @@ -40186,7 +41233,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/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 -@@ -882,9 +1188,11 @@ static int load_elf_binary(struct linux_ +@@ -882,9 +1188,11 @@ static int load_elf_binary(struct linux_binprm *bprm, struct pt_regs *regs) goto out_free_dentry; } if (likely(elf_bss != elf_brk) && unlikely(padzero(elf_bss))) { @@ -40210,7 +41257,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c { #define FILTER(type) (mm_flags & (1UL << MMF_DUMP_##type)) -@@ -1133,7 +1441,7 @@ static unsigned long vma_dump_size(struc +@@ -1133,7 +1441,7 @@ static unsigned long vma_dump_size(struct vm_area_struct *vma, if (vma->vm_file == NULL) return 0; @@ -40219,7 +41266,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c goto whole; /* -@@ -1355,9 +1663,9 @@ static void fill_auxv_note(struct memelf +@@ -1355,9 +1663,9 @@ static void fill_auxv_note(struct memelfnote *note, struct mm_struct *mm) { elf_addr_t *auxv = (elf_addr_t *) mm->saved_auxv; int i = 0; @@ -40231,7 +41278,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c fill_note(note, "CORE", NT_AUXV, i * sizeof(elf_addr_t), auxv); } -@@ -1863,14 +2171,14 @@ static void fill_extnum_info(struct elfh +@@ -1863,14 +2171,14 @@ static void fill_extnum_info(struct elfhdr *elf, struct elf_shdr *shdr4extnum, } static size_t elf_core_vma_data_size(struct vm_area_struct *gate_vma, @@ -40248,7 +41295,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c return size; } -@@ -1964,7 +2272,7 @@ static int elf_core_dump(struct coredump +@@ -1964,7 +2272,7 @@ static int elf_core_dump(struct coredump_params *cprm) dataoff = offset = roundup(offset, ELF_EXEC_PAGESIZE); @@ -40257,7 +41304,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c offset += elf_core_extra_data_size(); e_shoff = offset; -@@ -1978,10 +2286,12 @@ static int elf_core_dump(struct coredump +@@ -1978,10 +2286,12 @@ static int elf_core_dump(struct coredump_params *cprm) offset = dataoff; size += sizeof(*elf); @@ -40270,7 +41317,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c if (size > cprm->limit || !dump_write(cprm->file, phdr4note, sizeof(*phdr4note))) goto end_coredump; -@@ -1995,7 +2305,7 @@ static int elf_core_dump(struct coredump +@@ -1995,7 +2305,7 @@ static int elf_core_dump(struct coredump_params *cprm) phdr.p_offset = offset; phdr.p_vaddr = vma->vm_start; phdr.p_paddr = 0; @@ -40279,7 +41326,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c phdr.p_memsz = vma->vm_end - vma->vm_start; offset += phdr.p_filesz; phdr.p_flags = vma->vm_flags & VM_READ ? PF_R : 0; -@@ -2006,6 +2316,7 @@ static int elf_core_dump(struct coredump +@@ -2006,6 +2316,7 @@ static int elf_core_dump(struct coredump_params *cprm) phdr.p_align = ELF_EXEC_PAGESIZE; size += sizeof(phdr); @@ -40287,7 +41334,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c if (size > cprm->limit || !dump_write(cprm->file, &phdr, sizeof(phdr))) goto end_coredump; -@@ -2030,7 +2341,7 @@ static int elf_core_dump(struct coredump +@@ -2030,7 +2341,7 @@ static int elf_core_dump(struct coredump_params *cprm) unsigned long addr; unsigned long end; @@ -40296,7 +41343,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c for (addr = vma->vm_start; addr < end; addr += PAGE_SIZE) { struct page *page; -@@ -2039,6 +2350,7 @@ static int elf_core_dump(struct coredump +@@ -2039,6 +2350,7 @@ static int elf_core_dump(struct coredump_params *cprm) page = get_dump_page(addr); if (page) { void *kaddr = kmap(page); @@ -40304,7 +41351,7 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c stop = ((size += PAGE_SIZE) > cprm->limit) || !dump_write(cprm->file, kaddr, PAGE_SIZE); -@@ -2056,6 +2368,7 @@ static int elf_core_dump(struct coredump +@@ -2056,6 +2368,7 @@ static int elf_core_dump(struct coredump_params *cprm) if (e_phnum == PN_XNUM) { size += sizeof(*shdr4extnum); @@ -40410,10 +41457,11 @@ diff -urNp linux-3.0.9/fs/binfmt_elf.c linux-3.0.9/fs/binfmt_elf.c static int __init init_elf_binfmt(void) { return register_binfmt(&elf_format); -diff -urNp linux-3.0.9/fs/binfmt_flat.c linux-3.0.9/fs/binfmt_flat.c ---- linux-3.0.9/fs/binfmt_flat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/binfmt_flat.c 2011-11-12 12:47:14.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 = (unsigned long) -ENOMEM; printk("Unable to allocate RAM for process data, errno %d\n", (int)-realdatastart); @@ -40423,7 +41471,7 @@ diff -urNp linux-3.0.9/fs/binfmt_flat.c linux-3.0.9/fs/binfmt_flat.c ret = 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 * bprm, } if (IS_ERR_VALUE(result)) { printk("Unable to read data+bss, errno %d\n", (int)-result); @@ -40434,7 +41482,7 @@ diff -urNp linux-3.0.9/fs/binfmt_flat.c linux-3.0.9/fs/binfmt_flat.c ret = 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 * bprm, } if (IS_ERR_VALUE(result)) { printk("Unable to read code+data+bss, errno %d\n",(int)-result); @@ -40445,10 +41493,11 @@ diff -urNp linux-3.0.9/fs/binfmt_flat.c linux-3.0.9/fs/binfmt_flat.c ret = result; goto err; } -diff -urNp linux-3.0.9/fs/bio.c linux-3.0.9/fs/bio.c ---- linux-3.0.9/fs/bio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/bio.c 2011-11-12 12:47:14.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, int err) const int read = bio_data_dir(bio) == READ; struct bio_map_data *bmd = bio->bi_private; int i; @@ -40457,10 +41506,11 @@ diff -urNp linux-3.0.9/fs/bio.c linux-3.0.9/fs/bio.c __bio_for_each_segment(bvec, bio, i, 0) { char *addr = page_address(bvec->bv_page); -diff -urNp linux-3.0.9/fs/block_dev.c linux-3.0.9/fs/block_dev.c ---- linux-3.0.9/fs/block_dev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/block_dev.c 2011-11-12 12:47:14.000000000 -0500 -@@ -671,7 +671,7 @@ static bool bd_may_claim(struct block_de +diff --git a/fs/block_dev.c b/fs/block_dev.c +index 34503ba..183ea30 100644 +--- a/fs/block_dev.c ++++ b/fs/block_dev.c +@@ -671,7 +671,7 @@ static bool bd_may_claim(struct block_device *bdev, struct block_device *whole, else if (bdev->bd_contains == bdev) return true; /* is a whole device which isn't held */ @@ -40469,10 +41519,11 @@ diff -urNp linux-3.0.9/fs/block_dev.c linux-3.0.9/fs/block_dev.c return true; /* is a partition of a device that is being partitioned */ else if (whole->bd_holder != NULL) return false; /* is a partition of a held device */ -diff -urNp linux-3.0.9/fs/btrfs/ctree.c linux-3.0.9/fs/btrfs/ctree.c ---- linux-3.0.9/fs/btrfs/ctree.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/btrfs/ctree.c 2011-11-12 12:47:14.000000000 -0500 -@@ -454,9 +454,12 @@ static noinline int __btrfs_cow_block(st +diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c +index 2e66786..528df52 100644 +--- a/fs/btrfs/ctree.c ++++ b/fs/btrfs/ctree.c +@@ -454,9 +454,12 @@ static noinline int __btrfs_cow_block(struct btrfs_trans_handle *trans, free_extent_buffer(buf); add_root_to_dirty_list(root); } else { @@ -40488,9 +41539,10 @@ diff -urNp linux-3.0.9/fs/btrfs/ctree.c linux-3.0.9/fs/btrfs/ctree.c parent_start = 0; WARN_ON(trans->transid != btrfs_header_generation(parent)); -diff -urNp linux-3.0.9/fs/btrfs/inode.c linux-3.0.9/fs/btrfs/inode.c ---- linux-3.0.9/fs/btrfs/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/btrfs/inode.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c +index d42e6bf..13fc60e 100644 +--- a/fs/btrfs/inode.c ++++ b/fs/btrfs/inode.c @@ -6896,7 +6896,7 @@ fail: return -ENOMEM; } @@ -40500,7 +41552,7 @@ diff -urNp linux-3.0.9/fs/btrfs/inode.c linux-3.0.9/fs/btrfs/inode.c struct dentry *dentry, struct kstat *stat) { struct inode *inode = dentry->d_inode; -@@ -6908,6 +6908,14 @@ static int btrfs_getattr(struct vfsmount +@@ -6908,6 +6908,14 @@ static int btrfs_getattr(struct vfsmount *mnt, return 0; } @@ -40515,10 +41567,11 @@ diff -urNp linux-3.0.9/fs/btrfs/inode.c linux-3.0.9/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.0.9/fs/btrfs/ioctl.c linux-3.0.9/fs/btrfs/ioctl.c ---- linux-3.0.9/fs/btrfs/ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/btrfs/ioctl.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2676,9 +2676,12 @@ long btrfs_ioctl_space_info(struct btrfs +diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c +index a3c4751..62d648b 100644 +--- a/fs/btrfs/ioctl.c ++++ b/fs/btrfs/ioctl.c +@@ -2676,9 +2676,12 @@ long btrfs_ioctl_space_info(struct btrfs_root *root, void __user *arg) for (i = 0; i < num_types; i++) { struct btrfs_space_info *tmp; @@ -40531,7 +41584,7 @@ diff -urNp linux-3.0.9/fs/btrfs/ioctl.c linux-3.0.9/fs/btrfs/ioctl.c info = NULL; rcu_read_lock(); list_for_each_entry_rcu(tmp, &root->fs_info->space_info, -@@ -2700,15 +2703,12 @@ long btrfs_ioctl_space_info(struct btrfs +@@ -2700,15 +2703,12 @@ long btrfs_ioctl_space_info(struct btrfs_root *root, void __user *arg) memcpy(dest, &space, sizeof(space)); dest++; space_args.total_spaces++; @@ -40548,10 +41601,11 @@ diff -urNp linux-3.0.9/fs/btrfs/ioctl.c linux-3.0.9/fs/btrfs/ioctl.c (arg + sizeof(struct btrfs_ioctl_space_args)); if (copy_to_user(user_dest, dest_orig, alloc_size)) -diff -urNp linux-3.0.9/fs/btrfs/relocation.c linux-3.0.9/fs/btrfs/relocation.c ---- linux-3.0.9/fs/btrfs/relocation.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/btrfs/relocation.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1242,7 +1242,7 @@ static int __update_reloc_root(struct bt +diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c +index 5e0a3dc..65b3c8f 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); @@ -40560,10 +41614,11 @@ diff -urNp linux-3.0.9/fs/btrfs/relocation.c linux-3.0.9/fs/btrfs/relocation.c if (!del) { spin_lock(&rc->reloc_root_tree.lock); -diff -urNp linux-3.0.9/fs/cachefiles/bind.c linux-3.0.9/fs/cachefiles/bind.c ---- linux-3.0.9/fs/cachefiles/bind.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cachefiles/bind.c 2011-11-12 12:47:14.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 a2603e7..4c28e75 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); /* start by checking things over */ @@ -40579,10 +41634,11 @@ diff -urNp linux-3.0.9/fs/cachefiles/bind.c linux-3.0.9/fs/cachefiles/bind.c cache->bcull_percent < cache->brun_percent && cache->brun_percent < 100); -diff -urNp linux-3.0.9/fs/cachefiles/daemon.c linux-3.0.9/fs/cachefiles/daemon.c ---- linux-3.0.9/fs/cachefiles/daemon.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cachefiles/daemon.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 *file, char __user *_buffer, if (n > buflen) return -EMSGSIZE; @@ -40591,7 +41647,7 @@ diff -urNp linux-3.0.9/fs/cachefiles/daemon.c linux-3.0.9/fs/cachefiles/daemon.c return -EFAULT; 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; @@ -40600,7 +41656,7 @@ diff -urNp linux-3.0.9/fs/cachefiles/daemon.c linux-3.0.9/fs/cachefiles/daemon.c return -EOPNOTSUPP; /* 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] != '%' || args[1] != '\0') return -EINVAL; @@ -40609,7 +41665,7 @@ diff -urNp linux-3.0.9/fs/cachefiles/daemon.c linux-3.0.9/fs/cachefiles/daemon.c return cachefiles_daemon_range_error(cache, args); cache->fstop_percent = 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] != '%' || args[1] != '\0') return -EINVAL; @@ -40618,9 +41674,10 @@ diff -urNp linux-3.0.9/fs/cachefiles/daemon.c linux-3.0.9/fs/cachefiles/daemon.c return cachefiles_daemon_range_error(cache, args); cache->bstop_percent = bstop; -diff -urNp linux-3.0.9/fs/cachefiles/internal.h linux-3.0.9/fs/cachefiles/internal.h ---- linux-3.0.9/fs/cachefiles/internal.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cachefiles/internal.h 2011-11-12 12:47:14.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) */ @@ -40630,7 +41687,7 @@ diff -urNp linux-3.0.9/fs/cachefiles/internal.h linux-3.0.9/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 cachefiles_cache *cache, * proc.c */ #ifdef CONFIG_CACHEFILES_HISTOGRAM @@ -40655,9 +41712,10 @@ diff -urNp linux-3.0.9/fs/cachefiles/internal.h linux-3.0.9/fs/cachefiles/intern } #else -diff -urNp linux-3.0.9/fs/cachefiles/namei.c linux-3.0.9/fs/cachefiles/namei.c ---- linux-3.0.9/fs/cachefiles/namei.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cachefiles/namei.c 2011-11-12 12:47:14.000000000 -0500 +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", @@ -40667,9 +41725,10 @@ diff -urNp linux-3.0.9/fs/cachefiles/namei.c linux-3.0.9/fs/cachefiles/namei.c /* do the multiway lock magic */ trap = lock_rename(cache->graveyard, dir); -diff -urNp linux-3.0.9/fs/cachefiles/proc.c linux-3.0.9/fs/cachefiles/proc.c ---- linux-3.0.9/fs/cachefiles/proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cachefiles/proc.c 2011-11-12 12:47:14.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 <linux/seq_file.h> #include "internal.h" @@ -40683,7 +41742,7 @@ diff -urNp linux-3.0.9/fs/cachefiles/proc.c linux-3.0.9/fs/cachefiles/proc.c /* * 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 = (unsigned long) v - 3; @@ -40696,10 +41755,11 @@ diff -urNp linux-3.0.9/fs/cachefiles/proc.c linux-3.0.9/fs/cachefiles/proc.c if (x == 0 && y == 0 && z == 0) return 0; -diff -urNp linux-3.0.9/fs/cachefiles/rdwr.c linux-3.0.9/fs/cachefiles/rdwr.c ---- linux-3.0.9/fs/cachefiles/rdwr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cachefiles/rdwr.c 2011-11-12 12:47:14.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 = get_fs(); set_fs(KERNEL_DS); ret = file->f_op->write( @@ -40708,10 +41768,11 @@ diff -urNp linux-3.0.9/fs/cachefiles/rdwr.c linux-3.0.9/fs/cachefiles/rdwr.c set_fs(old_fs); kunmap(page); if (ret != len) -diff -urNp linux-3.0.9/fs/ceph/dir.c linux-3.0.9/fs/ceph/dir.c ---- linux-3.0.9/fs/ceph/dir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ceph/dir.c 2011-11-12 12:47:14.000000000 -0500 -@@ -226,7 +226,7 @@ static int ceph_readdir(struct file *fil +diff --git a/fs/ceph/dir.c b/fs/ceph/dir.c +index ef8f08c..143819d 100644 +--- a/fs/ceph/dir.c ++++ b/fs/ceph/dir.c +@@ -226,7 +226,7 @@ static int ceph_readdir(struct file *filp, void *dirent, filldir_t filldir) struct ceph_fs_client *fsc = ceph_inode_to_client(inode); struct ceph_mds_client *mdsc = fsc->mdsc; unsigned frag = fpos_frag(filp->f_pos); @@ -40720,10 +41781,11 @@ diff -urNp linux-3.0.9/fs/ceph/dir.c linux-3.0.9/fs/ceph/dir.c int err; u32 ftype; struct ceph_mds_reply_info_parsed *rinfo; -diff -urNp linux-3.0.9/fs/cifs/cifs_debug.c linux-3.0.9/fs/cifs/cifs_debug.c ---- linux-3.0.9/fs/cifs/cifs_debug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cifs/cifs_debug.c 2011-11-12 12:47:14.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 2fe3cf1..6b1cf93 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 *file, if (c == '1' || c == 'y' || c == 'Y' || c == '0') { #ifdef CONFIG_CIFS_STATS2 @@ -40734,7 +41796,7 @@ diff -urNp linux-3.0.9/fs/cifs/cifs_debug.c linux-3.0.9/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 = list_entry(tmp3, struct cifs_tcon, tcon_list); @@ -40779,7 +41841,7 @@ diff -urNp linux-3.0.9/fs/cifs/cifs_debug.c linux-3.0.9/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", @@ -40790,7 +41852,7 @@ diff -urNp linux-3.0.9/fs/cifs/cifs_debug.c linux-3.0.9/fs/cifs/cifs_debug.c #endif /* CONFIG_CIFS_STATS2 */ 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", @@ -40852,9 +41914,10 @@ diff -urNp linux-3.0.9/fs/cifs/cifs_debug.c linux-3.0.9/fs/cifs/cifs_debug.c } } } -diff -urNp linux-3.0.9/fs/cifs/cifsfs.c linux-3.0.9/fs/cifs/cifsfs.c ---- linux-3.0.9/fs/cifs/cifsfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cifs/cifsfs.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c +index 53e7d72..aebb461 100644 +--- a/fs/cifs/cifsfs.c ++++ b/fs/cifs/cifsfs.c @@ -996,7 +996,7 @@ cifs_init_request_bufs(void) cifs_req_cachep = kmem_cache_create("cifs_request", CIFSMaxBufSize + @@ -40884,9 +41947,10 @@ diff -urNp linux-3.0.9/fs/cifs/cifsfs.c linux-3.0.9/fs/cifs/cifsfs.c #endif /* CONFIG_CIFS_STATS2 */ atomic_set(&midCount, 0); -diff -urNp linux-3.0.9/fs/cifs/cifsglob.h linux-3.0.9/fs/cifs/cifsglob.h ---- linux-3.0.9/fs/cifs/cifsglob.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cifs/cifsglob.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h +index 6255fa8..9473e98 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; @@ -40938,7 +42002,7 @@ diff -urNp linux-3.0.9/fs/cifs/cifsglob.h linux-3.0.9/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) } #ifdef CONFIG_CIFS_STATS @@ -40947,7 +42011,7 @@ diff -urNp linux-3.0.9/fs/cifs/cifsglob.h linux-3.0.9/fs/cifs/cifsglob.h static inline void cifs_stats_bytes_written(struct cifs_tcon *tcon, unsigned int bytes) -@@ -911,8 +911,8 @@ GLOBAL_EXTERN atomic_t tconInfoReconnect +@@ -911,8 +911,8 @@ GLOBAL_EXTERN atomic_t tconInfoReconnectCount; /* Various Debug counters */ GLOBAL_EXTERN atomic_t bufAllocCount; /* current number allocated */ #ifdef CONFIG_CIFS_STATS2 @@ -40958,9 +42022,10 @@ diff -urNp linux-3.0.9/fs/cifs/cifsglob.h linux-3.0.9/fs/cifs/cifsglob.h #endif GLOBAL_EXTERN atomic_t smBufAllocCount; GLOBAL_EXTERN atomic_t midCount; -diff -urNp linux-3.0.9/fs/cifs/link.c linux-3.0.9/fs/cifs/link.c ---- linux-3.0.9/fs/cifs/link.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cifs/link.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/cifs/link.c b/fs/cifs/link.c +index 556b1a0..f449af5 100644 +--- a/fs/cifs/link.c ++++ b/fs/cifs/link.c @@ -587,7 +587,7 @@ symlink_exit: void cifs_put_link(struct dentry *direntry, struct nameidata *nd, void *cookie) @@ -40970,9 +42035,10 @@ diff -urNp linux-3.0.9/fs/cifs/link.c linux-3.0.9/fs/cifs/link.c if (!IS_ERR(p)) kfree(p); } -diff -urNp linux-3.0.9/fs/cifs/misc.c linux-3.0.9/fs/cifs/misc.c ---- linux-3.0.9/fs/cifs/misc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/cifs/misc.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/cifs/misc.c b/fs/cifs/misc.c +index 03a1f49..43bfa57 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); @@ -40991,9 +42057,10 @@ diff -urNp linux-3.0.9/fs/cifs/misc.c linux-3.0.9/fs/cifs/misc.c #endif /* CONFIG_CIFS_STATS2 */ } -diff -urNp linux-3.0.9/fs/coda/cache.c linux-3.0.9/fs/coda/cache.c ---- linux-3.0.9/fs/coda/cache.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/coda/cache.c 2011-11-12 12:47:14.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" @@ -41003,7 +42070,7 @@ diff -urNp linux-3.0.9/fs/coda/cache.c linux-3.0.9/fs/coda/cache.c /* 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 = ITOC(inode); spin_lock(&cii->c_lock); @@ -41012,7 +42079,7 @@ diff -urNp linux-3.0.9/fs/coda/cache.c linux-3.0.9/fs/coda/cache.c if (cii->c_uid != current_fsuid()) { cii->c_uid = current_fsuid(); cii->c_cached_perm = 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 = ITOC(inode); spin_lock(&cii->c_lock); @@ -41029,7 +42096,7 @@ diff -urNp linux-3.0.9/fs/coda/cache.c linux-3.0.9/fs/coda/cache.c } -@@ -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 = (mask & cii->c_cached_perm) == mask && cii->c_uid == current_fsuid() && @@ -41038,27 +42105,11 @@ diff -urNp linux-3.0.9/fs/coda/cache.c linux-3.0.9/fs/coda/cache.c spin_unlock(&cii->c_lock); return hit; -diff -urNp linux-3.0.9/fs/compat_binfmt_elf.c linux-3.0.9/fs/compat_binfmt_elf.c ---- linux-3.0.9/fs/compat_binfmt_elf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/compat_binfmt_elf.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 - - /* -diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c ---- linux-3.0.9/fs/compat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/compat.c 2011-11-12 12:47:14.000000000 -0500 -@@ -133,8 +133,8 @@ asmlinkage long compat_sys_utimes(const +diff --git a/fs/compat.c b/fs/compat.c +index 0ea0083..e831a79 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 = stat->ino; @@ -41069,7 +42120,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c int err; 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 *ctx32p) set_fs(KERNEL_DS); /* The __user pointer cast is valid because of the set_fs() */ @@ -41078,7 +42129,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/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; ret = -EINVAL; @@ -41095,7 +42146,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c int result; }; -@@ -865,6 +866,10 @@ static int compat_fillonedir(void *__buf +@@ -865,6 +866,10 @@ static int compat_fillonedir(void *__buf, const char *name, int namlen, buf->result = -EOVERFLOW; return -EOVERFLOW; } @@ -41106,7 +42157,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c buf->result++; dirent = 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, buf.result = 0; buf.dirent = dirent; @@ -41122,7 +42173,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/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 = -EOVERFLOW; return -EOVERFLOW; } @@ -41133,7 +42184,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c dirent = 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 = NULL; buf.count = count; buf.error = 0; @@ -41149,7 +42200,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/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 char * name, int namlen, loff_t buf->error = -EINVAL; /* only used if we fail.. */ if (reclen > buf->count) return -EINVAL; @@ -41160,7 +42211,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c dirent = buf->previous; if (dirent) { -@@ -1073,13 +1090,14 @@ asmlinkage long compat_sys_getdents64(un +@@ -1073,13 +1090,14 @@ asmlinkage long compat_sys_getdents64(unsigned int fd, buf.previous = NULL; buf.count = count; buf.error = 0; @@ -41176,7 +42227,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c if (__put_user_unaligned(d_off, &lastdirent->d_off)) error = -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)]; @@ -41185,7 +42236,7 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c if (n < 0) goto out_nofds; -@@ -1904,7 +1924,7 @@ asmlinkage long compat_sys_nfsservctl(in +@@ -1904,7 +1924,7 @@ asmlinkage long compat_sys_nfsservctl(int cmd, oldfs = get_fs(); set_fs(KERNEL_DS); /* The __user pointer casts are valid because of the set_fs() */ @@ -41194,10 +42245,29 @@ diff -urNp linux-3.0.9/fs/compat.c linux-3.0.9/fs/compat.c set_fs(oldfs); if (err) -diff -urNp linux-3.0.9/fs/compat_ioctl.c linux-3.0.9/fs/compat_ioctl.c ---- linux-3.0.9/fs/compat_ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/compat_ioctl.c 2011-11-12 12:47:14.000000000 -0500 -@@ -208,6 +208,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 + + /* +diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c +index 61abb63..8db5637 100644 +--- a/fs/compat_ioctl.c ++++ b/fs/compat_ioctl.c +@@ -208,6 +208,8 @@ static int do_video_set_spu_palette(unsigned int fd, unsigned int cmd, err = get_user(palp, &up->palette); err |= get_user(length, &up->length); @@ -41206,7 +42276,7 @@ diff -urNp linux-3.0.9/fs/compat_ioctl.c linux-3.0.9/fs/compat_ioctl.c up_native = compat_alloc_user_space(sizeof(struct video_spu_palette)); err = put_user(compat_ptr(palp), &up_native->palette); -@@ -619,7 +621,7 @@ static int serial_struct_ioctl(unsigned +@@ -619,7 +621,7 @@ static int serial_struct_ioctl(unsigned fd, unsigned cmd, return -EFAULT; if (__get_user(udata, &ss32->iomem_base)) return -EFAULT; @@ -41215,7 +42285,7 @@ diff -urNp linux-3.0.9/fs/compat_ioctl.c linux-3.0.9/fs/compat_ioctl.c if (__get_user(ss.iomem_reg_shift, &ss32->iomem_reg_shift) || __get_user(ss.port_high, &ss32->port_high)) return -EFAULT; -@@ -794,7 +796,7 @@ static int compat_ioctl_preallocate(stru +@@ -794,7 +796,7 @@ static int compat_ioctl_preallocate(struct file *file, 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)) || @@ -41224,7 +42294,7 @@ diff -urNp linux-3.0.9/fs/compat_ioctl.c linux-3.0.9/fs/compat_ioctl.c return -EFAULT; return ioctl_preallocate(file, p); -@@ -1638,8 +1640,8 @@ asmlinkage long compat_sys_ioctl(unsigne +@@ -1638,8 +1640,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; @@ -41235,10 +42305,11 @@ diff -urNp linux-3.0.9/fs/compat_ioctl.c linux-3.0.9/fs/compat_ioctl.c if (a > b) return 1; if (a < b) -diff -urNp linux-3.0.9/fs/configfs/dir.c linux-3.0.9/fs/configfs/dir.c ---- linux-3.0.9/fs/configfs/dir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/configfs/dir.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1575,7 +1575,8 @@ static int configfs_readdir(struct file +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, void * dirent, filldir_t filldir } for (p=q->next; p!= &parent_sd->s_children; p=p->next) { struct configfs_dirent *next; @@ -41248,7 +42319,7 @@ diff -urNp linux-3.0.9/fs/configfs/dir.c linux-3.0.9/fs/configfs/dir.c int len; struct inode *inode = NULL; -@@ -1585,7 +1586,12 @@ static int configfs_readdir(struct file +@@ -1585,7 +1586,12 @@ static int configfs_readdir(struct file * filp, void * dirent, filldir_t filldir continue; name = configfs_get_name(next); @@ -41262,10 +42333,11 @@ diff -urNp linux-3.0.9/fs/configfs/dir.c linux-3.0.9/fs/configfs/dir.c /* * We'll have a dentry and an inode for -diff -urNp linux-3.0.9/fs/dcache.c linux-3.0.9/fs/dcache.c ---- linux-3.0.9/fs/dcache.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/dcache.c 2011-11-12 12:47:14.000000000 -0500 -@@ -3089,7 +3089,7 @@ void __init vfs_caches_init(unsigned lon +diff --git a/fs/dcache.c b/fs/dcache.c +index fbdcbca..ab87fb6 100644 +--- a/fs/dcache.c ++++ b/fs/dcache.c +@@ -3089,7 +3089,7 @@ void __init vfs_caches_init(unsigned long mempages) mempages -= reserve; names_cachep = kmem_cache_create("names_cache", PATH_MAX, 0, @@ -41274,10 +42346,11 @@ diff -urNp linux-3.0.9/fs/dcache.c linux-3.0.9/fs/dcache.c dcache_init(); inode_init(); -diff -urNp linux-3.0.9/fs/ecryptfs/inode.c linux-3.0.9/fs/ecryptfs/inode.c ---- linux-3.0.9/fs/ecryptfs/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ecryptfs/inode.c 2011-11-12 12:47:14.000000000 -0500 -@@ -704,7 +704,7 @@ static int ecryptfs_readlink_lower(struc +diff --git a/fs/ecryptfs/inode.c b/fs/ecryptfs/inode.c +index 4a4fad7..4969114 100644 +--- a/fs/ecryptfs/inode.c ++++ b/fs/ecryptfs/inode.c +@@ -704,7 +704,7 @@ static int ecryptfs_readlink_lower(struct dentry *dentry, char **buf, old_fs = get_fs(); set_fs(get_ds()); rc = lower_dentry->d_inode->i_op->readlink(lower_dentry, @@ -41286,7 +42359,7 @@ diff -urNp linux-3.0.9/fs/ecryptfs/inode.c linux-3.0.9/fs/ecryptfs/inode.c lower_bufsiz); set_fs(old_fs); if (rc < 0) -@@ -750,7 +750,7 @@ static void *ecryptfs_follow_link(struct +@@ -750,7 +750,7 @@ static void *ecryptfs_follow_link(struct dentry *dentry, struct nameidata *nd) } old_fs = get_fs(); set_fs(get_ds()); @@ -41304,9 +42377,10 @@ diff -urNp linux-3.0.9/fs/ecryptfs/inode.c linux-3.0.9/fs/ecryptfs/inode.c if (!IS_ERR(buf)) { /* Free the char* */ kfree(buf); -diff -urNp linux-3.0.9/fs/ecryptfs/miscdev.c linux-3.0.9/fs/ecryptfs/miscdev.c ---- linux-3.0.9/fs/ecryptfs/miscdev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ecryptfs/miscdev.c 2011-11-12 12:47:14.000000000 -0500 +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 = 5; @@ -41316,10 +42390,11 @@ diff -urNp linux-3.0.9/fs/ecryptfs/miscdev.c linux-3.0.9/fs/ecryptfs/miscdev.c goto out_unlock_msg_ctx; i += packet_length_size; if (copy_to_user(&buf[i], msg_ctx->msg, msg_ctx->msg_size)) -diff -urNp linux-3.0.9/fs/ecryptfs/read_write.c linux-3.0.9/fs/ecryptfs/read_write.c ---- linux-3.0.9/fs/ecryptfs/read_write.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ecryptfs/read_write.c 2011-11-12 12:47:14.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 = get_fs(); set_fs(get_ds()); @@ -41328,7 +42403,7 @@ diff -urNp linux-3.0.9/fs/ecryptfs/read_write.c linux-3.0.9/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, size_t size, return -EIO; fs_save = get_fs(); set_fs(get_ds()); @@ -41337,9 +42412,10 @@ diff -urNp linux-3.0.9/fs/ecryptfs/read_write.c linux-3.0.9/fs/ecryptfs/read_wri set_fs(fs_save); return rc; } -diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c ---- linux-3.0.9/fs/exec.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/exec.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/exec.c b/fs/exec.c +index 044c13f..717b6af 100644 +--- a/fs/exec.c ++++ b/fs/exec.c @@ -55,12 +55,24 @@ #include <linux/pipe_fs_i.h> #include <linux/oom.h> @@ -41374,7 +42450,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c /* The maximal length of core_pattern is also specified in sysctl.c */ -@@ -116,7 +128,7 @@ SYSCALL_DEFINE1(uselib, const char __use +@@ -116,7 +128,7 @@ SYSCALL_DEFINE1(uselib, const char __user *, library) char *tmp = getname(library); int error = PTR_ERR(tmp); static const struct open_flags uselib_flags = { @@ -41383,7 +42459,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c .acc_mode = MAY_READ | MAY_EXEC | MAY_OPEN, .intent = LOOKUP_OPEN }; -@@ -195,18 +207,10 @@ static struct page *get_arg_page(struct +@@ -195,18 +207,10 @@ static struct page *get_arg_page(struct linux_binprm *bprm, unsigned long pos, int write) { struct page *page; @@ -41405,7 +42481,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c return NULL; if (write) { -@@ -281,6 +285,11 @@ static int __bprm_mm_init(struct linux_b +@@ -281,6 +285,11 @@ static int __bprm_mm_init(struct linux_binprm *bprm) vma->vm_end = STACK_TOP_MAX; vma->vm_start = vma->vm_end - PAGE_SIZE; vma->vm_flags = VM_STACK_FLAGS | VM_STACK_INCOMPLETE_SETUP; @@ -41417,7 +42493,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c vma->vm_page_prot = vm_get_page_prot(vma->vm_flags); INIT_LIST_HEAD(&vma->anon_vma_chain); -@@ -295,6 +304,12 @@ static int __bprm_mm_init(struct linux_b +@@ -295,6 +304,12 @@ static int __bprm_mm_init(struct linux_binprm *bprm) mm->stack_vm = mm->total_vm = 1; up_write(&mm->mmap_sem); bprm->p = vma->vm_end - sizeof(void *); @@ -41451,7 +42527,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c { const char __user *native; -@@ -424,14 +427,14 @@ static const char __user *get_user_arg_p +@@ -424,14 +427,14 @@ static const char __user *get_user_arg_ptr(struct user_arg_ptr argv, int nr) compat_uptr_t compat; if (get_user(compat, argv.ptr.compat + nr)) @@ -41468,7 +42544,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c return native; } -@@ -450,7 +453,7 @@ static int count(struct user_arg_ptr arg +@@ -450,7 +453,7 @@ static int count(struct user_arg_ptr argv, int max) if (!p) break; @@ -41477,7 +42553,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c return -EFAULT; if (i++ >= max) -@@ -484,7 +487,7 @@ static int copy_strings(int argc, struct +@@ -484,7 +487,7 @@ static int copy_strings(int argc, struct user_arg_ptr argv, ret = -EFAULT; str = get_user_arg_ptr(argv, argc); @@ -41486,7 +42562,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c goto out; len = strnlen_user(str, MAX_ARG_STRLEN); -@@ -566,7 +569,7 @@ int copy_strings_kernel(int argc, const +@@ -566,7 +569,7 @@ int copy_strings_kernel(int argc, const char *const *__argv, int r; mm_segment_t oldfs = get_fs(); struct user_arg_ptr argv = { @@ -41495,7 +42571,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c }; set_fs(KERNEL_DS); -@@ -601,7 +604,8 @@ static int shift_arg_pages(struct vm_are +@@ -601,7 +604,8 @@ static int shift_arg_pages(struct vm_area_struct *vma, unsigned long shift) unsigned long new_end = old_end - shift; struct mmu_gather tlb; @@ -41505,7 +42581,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c /* * ensure there are no vmas between where we want to go -@@ -610,6 +614,10 @@ static int shift_arg_pages(struct vm_are +@@ -610,6 +614,10 @@ static int shift_arg_pages(struct vm_area_struct *vma, unsigned long shift) if (vma != find_vma(mm, new_start)) return -EFAULT; @@ -41516,7 +42592,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c /* * cover the whole range: [new_start, old_end) */ -@@ -690,10 +698,6 @@ int setup_arg_pages(struct linux_binprm +@@ -690,10 +698,6 @@ int setup_arg_pages(struct linux_binprm *bprm, stack_top = arch_align_stack(stack_top); stack_top = PAGE_ALIGN(stack_top); @@ -41527,7 +42603,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c stack_shift = vma->vm_end - stack_top; bprm->p -= stack_shift; -@@ -705,8 +709,28 @@ int setup_arg_pages(struct linux_binprm +@@ -705,8 +709,28 @@ int setup_arg_pages(struct linux_binprm *bprm, bprm->exec -= stack_shift; down_write(&mm->mmap_sem); @@ -41556,7 +42632,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c /* * Adjust stack execute permissions; explicitly enable for * EXSTACK_ENABLE_X, disable for EXSTACK_DISABLE_X and leave alone -@@ -725,13 +749,6 @@ int setup_arg_pages(struct linux_binprm +@@ -725,13 +749,6 @@ int setup_arg_pages(struct linux_binprm *bprm, goto out_unlock; BUG_ON(prev != vma); @@ -41579,7 +42655,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c .acc_mode = MAY_EXEC | MAY_OPEN, .intent = LOOKUP_OPEN }; -@@ -812,7 +829,7 @@ int kernel_read(struct file *file, loff_ +@@ -812,7 +829,7 @@ int kernel_read(struct file *file, loff_t offset, old_fs = get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -41588,7 +42664,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c set_fs(old_fs); return result; } -@@ -1236,7 +1253,7 @@ int check_unsafe_exec(struct linux_binpr +@@ -1236,7 +1253,7 @@ int check_unsafe_exec(struct linux_binprm *bprm) } rcu_read_unlock(); @@ -41597,7 +42673,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c bprm->unsafe |= LSM_UNSAFE_SHARE; } else { res = -EAGAIN; -@@ -1430,11 +1447,35 @@ static int do_execve_common(const char * +@@ -1430,11 +1447,35 @@ static int do_execve_common(const char *filename, struct user_arg_ptr envp, struct pt_regs *regs) { @@ -41633,7 +42709,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c retval = unshare_files(&displaced); if (retval) -@@ -1466,6 +1507,16 @@ static int do_execve_common(const char * +@@ -1466,6 +1507,16 @@ static int do_execve_common(const char *filename, bprm->filename = filename; bprm->interp = filename; @@ -41650,7 +42726,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c retval = bprm_mm_init(bprm); if (retval) goto out_file; -@@ -1495,9 +1546,40 @@ static int do_execve_common(const char * +@@ -1495,9 +1546,40 @@ static int do_execve_common(const char *filename, if (retval < 0) goto out; @@ -41692,7 +42768,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c /* execve succeeded */ current->fs->in_exec = 0; -@@ -1508,6 +1590,14 @@ static int do_execve_common(const char * +@@ -1508,6 +1590,14 @@ static int do_execve_common(const char *filename, put_files_struct(displaced); return retval; @@ -41707,7 +42783,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c out: if (bprm->mm) { acct_arg_size(bprm, 0); -@@ -1581,7 +1671,7 @@ static int expand_corename(struct core_n +@@ -1581,7 +1671,7 @@ static int expand_corename(struct core_name *cn) { char *old_corename = cn->corename; @@ -41716,7 +42792,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c cn->corename = krealloc(old_corename, cn->size, GFP_KERNEL); if (!cn->corename) { -@@ -1669,7 +1759,7 @@ static int format_corename(struct core_n +@@ -1669,7 +1759,7 @@ static int format_corename(struct core_name *cn, long signr) int pid_in_pattern = 0; int err = 0; @@ -41945,7 +43021,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c static int zap_process(struct task_struct *start, int exit_code) { struct task_struct *t; -@@ -1971,17 +2274,17 @@ static void wait_for_dump_helpers(struct +@@ -1971,17 +2274,17 @@ static void wait_for_dump_helpers(struct file *file) pipe = file->f_path.dentry->d_inode->i_pipe; pipe_lock(pipe); @@ -41968,7 +43044,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c pipe_unlock(pipe); } -@@ -2042,7 +2345,7 @@ void do_coredump(long signr, int exit_co +@@ -2042,7 +2345,7 @@ void do_coredump(long signr, int exit_code, struct pt_regs *regs) int retval = 0; int flag = 0; int ispipe; @@ -41977,7 +43053,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c struct coredump_params cprm = { .signr = signr, .regs = regs, -@@ -2057,6 +2360,9 @@ void do_coredump(long signr, int exit_co +@@ -2057,6 +2360,9 @@ void do_coredump(long signr, int exit_code, struct pt_regs *regs) audit_core_dumps(signr); @@ -41987,7 +43063,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c binfmt = mm->binfmt; if (!binfmt || !binfmt->core_dump) goto fail; -@@ -2097,6 +2403,8 @@ void do_coredump(long signr, int exit_co +@@ -2097,6 +2403,8 @@ void do_coredump(long signr, int exit_code, struct pt_regs *regs) goto fail_corename; } @@ -41996,7 +43072,7 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c if (ispipe) { int dump_count; char **helper_argv; -@@ -2124,7 +2432,7 @@ void do_coredump(long signr, int exit_co +@@ -2124,7 +2432,7 @@ void do_coredump(long signr, int exit_code, struct pt_regs *regs) } cprm.limit = RLIM_INFINITY; @@ -42023,10 +43099,11 @@ diff -urNp linux-3.0.9/fs/exec.c linux-3.0.9/fs/exec.c } EXPORT_SYMBOL(dump_write); -diff -urNp linux-3.0.9/fs/ext2/balloc.c linux-3.0.9/fs/ext2/balloc.c ---- linux-3.0.9/fs/ext2/balloc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext2/balloc.c 2011-11-12 12:47:14.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_info *sbi) free_blocks = percpu_counter_read_positive(&sbi->s_freeblocks_counter); root_blocks = le32_to_cpu(sbi->s_es->s_r_blocks_count); @@ -42035,10 +43112,11 @@ diff -urNp linux-3.0.9/fs/ext2/balloc.c linux-3.0.9/fs/ext2/balloc.c sbi->s_resuid != current_fsuid() && (sbi->s_resgid == 0 || !in_group_p (sbi->s_resgid))) { return 0; -diff -urNp linux-3.0.9/fs/ext3/balloc.c linux-3.0.9/fs/ext3/balloc.c ---- linux-3.0.9/fs/ext3/balloc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext3/balloc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1441,7 +1441,7 @@ static int ext3_has_free_blocks(struct e +diff --git a/fs/ext3/balloc.c b/fs/ext3/balloc.c +index fe52297..298e7dc 100644 +--- a/fs/ext3/balloc.c ++++ b/fs/ext3/balloc.c +@@ -1441,7 +1441,7 @@ static int ext3_has_free_blocks(struct ext3_sb_info *sbi) free_blocks = percpu_counter_read_positive(&sbi->s_freeblocks_counter); root_blocks = le32_to_cpu(sbi->s_es->s_r_blocks_count); @@ -42047,9 +43125,10 @@ diff -urNp linux-3.0.9/fs/ext3/balloc.c linux-3.0.9/fs/ext3/balloc.c sbi->s_resuid != current_fsuid() && (sbi->s_resgid == 0 || !in_group_p (sbi->s_resgid))) { return 0; -diff -urNp linux-3.0.9/fs/ext3/ioctl.c linux-3.0.9/fs/ext3/ioctl.c ---- linux-3.0.9/fs/ext3/ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext3/ioctl.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/ext3/ioctl.c b/fs/ext3/ioctl.c +index f4090bd..c7f4394 100644 +--- a/fs/ext3/ioctl.c ++++ b/fs/ext3/ioctl.c @@ -285,7 +285,7 @@ group_add_out: if (!capable(CAP_SYS_ADMIN)) return -EPERM; @@ -42068,10 +43147,11 @@ diff -urNp linux-3.0.9/fs/ext3/ioctl.c linux-3.0.9/fs/ext3/ioctl.c sizeof(range))) return -EFAULT; -diff -urNp linux-3.0.9/fs/ext4/balloc.c linux-3.0.9/fs/ext4/balloc.c ---- linux-3.0.9/fs/ext4/balloc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext4/balloc.c 2011-11-12 12:47:14.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 264f694..4100ab7 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 == current_fsuid() || ((sbi->s_resgid != 0) && in_group_p(sbi->s_resgid)) || @@ -42082,9 +43162,10 @@ diff -urNp linux-3.0.9/fs/ext4/balloc.c linux-3.0.9/fs/ext4/balloc.c if (free_blocks >= (nblocks + dirty_blocks)) return 1; -diff -urNp linux-3.0.9/fs/ext4/ext4.h linux-3.0.9/fs/ext4/ext4.h ---- linux-3.0.9/fs/ext4/ext4.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext4/ext4.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h +index 1a34c1c..0cbd418 100644 +--- a/fs/ext4/ext4.h ++++ b/fs/ext4/ext4.h @@ -1177,19 +1177,19 @@ struct ext4_sb_info { unsigned long s_mb_last_start; @@ -42115,10 +43196,11 @@ diff -urNp linux-3.0.9/fs/ext4/ext4.h linux-3.0.9/fs/ext4/ext4.h atomic_t s_lock_busy; /* locality groups */ -diff -urNp linux-3.0.9/fs/ext4/file.c linux-3.0.9/fs/ext4/file.c ---- linux-3.0.9/fs/ext4/file.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext4/file.c 2011-11-12 12:47:14.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 2c09723..0a9b79e 100644 +--- a/fs/ext4/file.c ++++ b/fs/ext4/file.c +@@ -181,8 +181,8 @@ static int ext4_file_open(struct inode * inode, struct file * filp) path.dentry = mnt->mnt_root; cp = d_path(&path, buf, sizeof(buf)); if (!IS_ERR(cp)) { @@ -42129,9 +43211,10 @@ diff -urNp linux-3.0.9/fs/ext4/file.c linux-3.0.9/fs/ext4/file.c ext4_mark_super_dirty(sb); } } -diff -urNp linux-3.0.9/fs/ext4/ioctl.c linux-3.0.9/fs/ext4/ioctl.c ---- linux-3.0.9/fs/ext4/ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext4/ioctl.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/ext4/ioctl.c b/fs/ext4/ioctl.c +index 808c554..46008d7 100644 +--- a/fs/ext4/ioctl.c ++++ b/fs/ext4/ioctl.c @@ -344,7 +344,7 @@ mext_out: if (!blk_queue_discard(q)) return -EOPNOTSUPP; @@ -42150,10 +43233,11 @@ diff -urNp linux-3.0.9/fs/ext4/ioctl.c linux-3.0.9/fs/ext4/ioctl.c sizeof(range))) return -EFAULT; -diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c ---- linux-3.0.9/fs/ext4/mballoc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ext4/mballoc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1793,7 +1793,7 @@ void ext4_mb_simple_scan_group(struct ex +diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c +index 0f1be7f..b795315 100644 +--- a/fs/ext4/mballoc.c ++++ b/fs/ext4/mballoc.c +@@ -1793,7 +1793,7 @@ void ext4_mb_simple_scan_group(struct ext4_allocation_context *ac, BUG_ON(ac->ac_b_ex.fe_len != ac->ac_g_ex.fe_len); if (EXT4_SB(sb)->s_mb_stats) @@ -42171,7 +43255,7 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c goto repeat; } } -@@ -2130,6 +2130,8 @@ static int ext4_mb_seq_groups_show(struc +@@ -2130,6 +2130,8 @@ static int ext4_mb_seq_groups_show(struct seq_file *seq, void *v) ext4_grpblk_t counters[16]; } sg; @@ -42180,7 +43264,7 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c group--; if (group == 0) seq_printf(seq, "#%-5s: %-5s %-5s %-5s " -@@ -2553,25 +2555,25 @@ int ext4_mb_release(struct super_block * +@@ -2553,25 +2555,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", @@ -42216,7 +43300,7 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c } free_percpu(sbi->s_locality_groups); -@@ -3041,16 +3043,16 @@ static void ext4_mb_collect_stats(struct +@@ -3041,16 +3043,16 @@ static void ext4_mb_collect_stats(struct ext4_allocation_context *ac) struct ext4_sb_info *sbi = EXT4_SB(ac->ac_sb); if (sbi->s_mb_stats && ac->ac_g_ex.fe_len > 1) { @@ -42239,7 +43323,7 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c } if (ac->ac_op == EXT4_MB_HISTORY_ALLOC) -@@ -3448,7 +3450,7 @@ ext4_mb_new_inode_pa(struct ext4_allocat +@@ -3448,7 +3450,7 @@ ext4_mb_new_inode_pa(struct ext4_allocation_context *ac) trace_ext4_mb_new_inode_pa(ac, pa); ext4_mb_use_inode_pa(ac, pa); @@ -42248,7 +43332,7 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c ei = EXT4_I(ac->ac_inode); grp = ext4_get_group_info(sb, ac->ac_b_ex.fe_group); -@@ -3508,7 +3510,7 @@ ext4_mb_new_group_pa(struct ext4_allocat +@@ -3508,7 +3510,7 @@ ext4_mb_new_group_pa(struct ext4_allocation_context *ac) trace_ext4_mb_new_group_pa(ac, pa); ext4_mb_use_group_pa(ac, pa); @@ -42257,7 +43341,7 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c grp = ext4_get_group_info(sb, ac->ac_b_ex.fe_group); lg = ac->ac_lg; -@@ -3595,7 +3597,7 @@ ext4_mb_release_inode_pa(struct ext4_bud +@@ -3595,7 +3597,7 @@ ext4_mb_release_inode_pa(struct ext4_buddy *e4b, struct buffer_head *bitmap_bh, * from the bitmap and continue. */ } @@ -42266,7 +43350,7 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c return err; } -@@ -3613,7 +3615,7 @@ ext4_mb_release_group_pa(struct ext4_bud +@@ -3613,7 +3615,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 != e4b->bd_group && pa->pa_len != 0); mb_free_blocks(pa->pa_inode, e4b, bit, pa->pa_len); @@ -42275,10 +43359,11 @@ diff -urNp linux-3.0.9/fs/ext4/mballoc.c linux-3.0.9/fs/ext4/mballoc.c trace_ext4_mballoc_discard(sb, NULL, group, bit, pa->pa_len); return 0; -diff -urNp linux-3.0.9/fs/fcntl.c linux-3.0.9/fs/fcntl.c ---- linux-3.0.9/fs/fcntl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fcntl.c 2011-11-12 12:47:14.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..227cfc5 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; @@ -42299,7 +43384,7 @@ diff -urNp linux-3.0.9/fs/fcntl.c linux-3.0.9/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 long arg) static int f_getown_ex(struct file *filp, unsigned long arg) { @@ -42308,7 +43393,7 @@ diff -urNp linux-3.0.9/fs/fcntl.c linux-3.0.9/fs/fcntl.c struct f_owner_ex owner; int ret = 0; -@@ -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, unsigned long arg, switch (cmd) { case F_DUPFD: case F_DUPFD_CLOEXEC: @@ -42333,10 +43418,11 @@ diff -urNp linux-3.0.9/fs/fcntl.c linux-3.0.9/fs/fcntl.c )); fasync_cache = kmem_cache_create("fasync_cache", -diff -urNp linux-3.0.9/fs/fifo.c linux-3.0.9/fs/fifo.c ---- linux-3.0.9/fs/fifo.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fifo.c 2011-11-12 12:47:14.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 file *filp) */ filp->f_op = &read_pipefifo_fops; pipe->r_counter++; @@ -42349,7 +43435,7 @@ diff -urNp linux-3.0.9/fs/fifo.c linux-3.0.9/fs/fifo.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 file *filp) * errno=ENXIO when there is no process reading the FIFO. */ ret = -ENXIO; @@ -42368,7 +43454,7 @@ diff -urNp linux-3.0.9/fs/fifo.c linux-3.0.9/fs/fifo.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 file *filp) */ filp->f_op = &rdwr_pipefifo_fops; @@ -42383,7 +43469,7 @@ diff -urNp linux-3.0.9/fs/fifo.c linux-3.0.9/fs/fifo.c wake_up_partner(inode); break; -@@ -123,19 +123,19 @@ static int fifo_open(struct inode *inode +@@ -123,19 +123,19 @@ static int fifo_open(struct inode *inode, struct file *filp) return 0; err_rd: @@ -42406,9 +43492,10 @@ diff -urNp linux-3.0.9/fs/fifo.c linux-3.0.9/fs/fifo.c free_pipe_info(inode); err_nocleanup: -diff -urNp linux-3.0.9/fs/file.c linux-3.0.9/fs/file.c ---- linux-3.0.9/fs/file.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/file.c 2011-11-12 12:47:14.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 <linux/slab.h> #include <linux/vmalloc.h> @@ -42417,7 +43504,7 @@ diff -urNp linux-3.0.9/fs/file.c linux-3.0.9/fs/file.c #include <linux/fdtable.h> #include <linux/bitops.h> #include <linux/interrupt.h> -@@ -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. */ @@ -42425,10 +43512,11 @@ diff -urNp linux-3.0.9/fs/file.c linux-3.0.9/fs/file.c if (nr >= rlimit(RLIMIT_NOFILE)) return -EMFILE; -diff -urNp linux-3.0.9/fs/filesystems.c linux-3.0.9/fs/filesystems.c ---- linux-3.0.9/fs/filesystems.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/filesystems.c 2011-11-12 12:47:14.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 *name) int len = dot ? dot - name : strlen(name); fs = __get_fs_type(name, len); @@ -42441,10 +43529,104 @@ diff -urNp linux-3.0.9/fs/filesystems.c linux-3.0.9/fs/filesystems.c fs = __get_fs_type(name, len); if (dot && fs && !(fs->fs_flags & FS_HAS_SUBTYPE)) { -diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c ---- linux-3.0.9/fs/fscache/cookie.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fscache/cookie.c 2011-11-12 12:47:14.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 <linux/path.h> + #include <linux/slab.h> + #include <linux/fs_struct.h> ++#include <linux/grsecurity.h> + #include "internal.h" + + static inline void path_get_longterm(struct path *path) +@@ -31,6 +32,7 @@ void set_fs_root(struct fs_struct *fs, struct path *path) + old_root = fs->root; + fs->root = *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 == old_root->mnt) { + path_get_longterm(new_root); + fs->root = *new_root; ++ gr_set_chroot_entries(p, new_root); + count++; + } + if (fs->pwd.dentry == 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 = NULL; +- kill = !--fs->users; ++ gr_clear_chroot_entries(tsk); ++ kill = !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 *old) + struct fs_struct *fs = kmem_cache_alloc(fs_cachep, GFP_KERNEL); + /* We don't need to lock fs - think why ;-) */ + if (fs) { +- fs->users = 1; ++ atomic_set(&fs->users, 1); + fs->in_exec = 0; + spin_lock_init(&fs->lock); + seqcount_init(&fs->seq); +@@ -132,6 +136,9 @@ struct fs_struct *copy_fs_struct(struct fs_struct *old) + spin_lock(&old->lock); + fs->root = 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 = old->pwd; + path_get_longterm(&fs->pwd); + spin_unlock(&old->lock); +@@ -150,8 +157,9 @@ int unshare_fs_struct(void) + + task_lock(current); + spin_lock(&fs->lock); +- kill = !--fs->users; ++ kill = !atomic_dec_return(&fs->users); + current->fs = new_fs; ++ gr_set_chroot_entries(current, &new_fs->root); + spin_unlock(&fs->lock); + task_unlock(current); + +@@ -170,7 +178,7 @@ EXPORT_SYMBOL(current_umask); + + /* to be mentioned only in INIT_TASK */ + struct fs_struct init_fs = { +- .users = 1, ++ .users = ATOMIC_INIT(1), + .lock = __SPIN_LOCK_UNLOCKED(init_fs.lock), + .seq = SEQCNT_ZERO, + .umask = 0022, +@@ -186,12 +194,13 @@ void daemonize_fs_struct(void) + task_lock(current); + + spin_lock(&init_fs.lock); +- init_fs.users++; ++ atomic_inc(&init_fs.users); + spin_unlock(&init_fs.lock); + + spin_lock(&fs->lock); + current->fs = &init_fs; +- kill = !--fs->users; ++ gr_set_chroot_entries(current, ¤t->fs->root); ++ kill = !atomic_dec_return(&fs->users); + spin_unlock(&fs->lock); + + 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 : "<no-parent>", def->name, netfs_data); @@ -42458,7 +43640,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/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 = kmem_cache_alloc(fscache_cookie_jar, GFP_KERNEL); if (!cookie) { @@ -42467,7 +43649,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/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( switch (cookie->def->type) { case FSCACHE_COOKIE_TYPE_INDEX: @@ -42484,7 +43666,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c break; } -@@ -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); @@ -42500,7 +43682,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c _leave(" = %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 fscache_cookie *cookie) cache = fscache_select_cache_for_object(cookie->parent); if (!cache) { up_read(&fscache_addremove_sem); @@ -42509,7 +43691,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c _leave(" = -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_cache *cache, object = cache->ops->alloc_object(cache, cookie); fscache_stat_d(&fscache_n_cop_alloc_object); if (IS_ERR(object)) { @@ -42524,7 +43706,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c object->debug_id = atomic_inc_return(&fscache_object_debug_id); -@@ -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; @@ -42537,7 +43719,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c _leave(" [no cookie]"); return; } -@@ -414,12 +414,12 @@ void __fscache_relinquish_cookie(struct +@@ -414,12 +414,12 @@ void __fscache_relinquish_cookie(struct fscache_cookie *cookie, int retire) struct fscache_object *object; unsigned long event; @@ -42553,7 +43735,7 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c _leave(" [no cookie]"); return; } -@@ -435,7 +435,7 @@ void __fscache_relinquish_cookie(struct +@@ -435,7 +435,7 @@ void __fscache_relinquish_cookie(struct fscache_cookie *cookie, int retire) /* wait for the cookie to finish being instantiated (or to fail) */ if (test_bit(FSCACHE_COOKIE_CREATING, &cookie->flags)) { @@ -42562,9 +43744,10 @@ diff -urNp linux-3.0.9/fs/fscache/cookie.c linux-3.0.9/fs/fscache/cookie.c wait_on_bit(&cookie->flags, FSCACHE_COOKIE_CREATING, fscache_wait_bit, TASK_UNINTERRUPTIBLE); } -diff -urNp linux-3.0.9/fs/fscache/internal.h linux-3.0.9/fs/fscache/internal.h ---- linux-3.0.9/fs/fscache/internal.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fscache/internal.h 2011-11-12 12:47:14.000000000 -0500 +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]; @@ -42748,7 +43931,7 @@ diff -urNp linux-3.0.9/fs/fscache/internal.h linux-3.0.9/fs/fscache/internal.h 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); } @@ -42760,7 +43943,7 @@ diff -urNp linux-3.0.9/fs/fscache/internal.h linux-3.0.9/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_fops; #define __fscache_stat(stat) (NULL) #define fscache_stat(stat) do {} while (0) @@ -42768,10 +43951,11 @@ diff -urNp linux-3.0.9/fs/fscache/internal.h linux-3.0.9/fs/fscache/internal.h #define fscache_stat_d(stat) do {} while (0) #endif -diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c ---- linux-3.0.9/fs/fscache/object.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fscache/object.c 2011-11-12 12:47:14.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 fscache_object *object) /* update the object metadata on disk */ case FSCACHE_OBJECT_UPDATING: clear_bit(FSCACHE_OBJECT_EV_UPDATE, &object->events); @@ -42780,7 +43964,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/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 fscache_object *object) spin_lock(&object->lock); object->state = FSCACHE_OBJECT_DEAD; spin_unlock(&object->lock); @@ -42789,7 +43973,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c goto terminal_transit; /* 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 fscache_object *object) spin_lock(&object->lock); object->state = FSCACHE_OBJECT_DEAD; spin_unlock(&object->lock); @@ -42798,7 +43982,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c goto terminal_transit; /* 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_object *object) parent->cookie->def->name, cookie->def->name, object->cache->tag->name); @@ -42807,7 +43991,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c fscache_stat(&fscache_n_cop_lookup_object); ret = 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_object *object) if (ret == -ETIMEDOUT) { /* probably stuck behind another object, so move this one to * the back of the queue */ @@ -42816,7 +44000,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c set_bit(FSCACHE_OBJECT_EV_REQUEUE, &object->events); } -@@ -495,7 +495,7 @@ void fscache_object_lookup_negative(stru +@@ -495,7 +495,7 @@ void fscache_object_lookup_negative(struct fscache_object *object) spin_lock(&object->lock); if (object->state == FSCACHE_OBJECT_LOOKING_UP) { @@ -42825,7 +44009,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c /* 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 == FSCACHE_OBJECT_LOOKING_UP) { @@ -42834,7 +44018,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c clear_bit(FSCACHE_COOKIE_NO_DATA_YET, &cookie->flags); -@@ -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, ==, FSCACHE_OBJECT_CREATING); @@ -42843,7 +44027,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c object->state = 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); fscache_hist(fscache_obj_instantiate_histogram, object->lookup_jif); @@ -42852,7 +44036,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c _leave(""); } -@@ -861,7 +861,7 @@ enum fscache_checkaux fscache_check_aux( +@@ -861,7 +861,7 @@ enum fscache_checkaux fscache_check_aux(struct fscache_object *object, enum fscache_checkaux result; if (!object->cookie->def->check_aux) { @@ -42861,7 +44045,7 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c return FSCACHE_CHECKAUX_OKAY; } -@@ -870,17 +870,17 @@ enum fscache_checkaux fscache_check_aux( +@@ -870,17 +870,17 @@ enum fscache_checkaux fscache_check_aux(struct fscache_object *object, switch (result) { /* entry okay as is */ case FSCACHE_CHECKAUX_OKAY: @@ -42882,9 +44066,10 @@ diff -urNp linux-3.0.9/fs/fscache/object.c linux-3.0.9/fs/fscache/object.c break; default: -diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c ---- linux-3.0.9/fs/fscache/operation.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fscache/operation.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/slab.h> #include "internal.h" @@ -42894,7 +44079,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c EXPORT_SYMBOL(fscache_op_debug_id); /** -@@ -38,7 +38,7 @@ void fscache_enqueue_operation(struct fs +@@ -38,7 +38,7 @@ void fscache_enqueue_operation(struct fscache_operation *op) ASSERTCMP(op->object->state, >=, FSCACHE_OBJECT_AVAILABLE); ASSERTCMP(atomic_read(&op->usage), >, 0); @@ -42903,7 +44088,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/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 *object, wake_up_bit(&op->flags, FSCACHE_OP_WAITING); if (op->processor) fscache_enqueue_operation(op); @@ -42912,7 +44097,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c } /* -@@ -98,11 +98,11 @@ int fscache_submit_exclusive_op(struct f +@@ -98,11 +98,11 @@ int fscache_submit_exclusive_op(struct fscache_object *object, if (object->n_ops > 1) { atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -42926,7 +44111,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c fscache_start_operations(object); } else { ASSERTCMP(object->n_in_progress, ==, 0); -@@ -118,7 +118,7 @@ int fscache_submit_exclusive_op(struct f +@@ -118,7 +118,7 @@ int fscache_submit_exclusive_op(struct fscache_object *object, object->n_exclusive++; /* reads and writes must wait */ atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -42935,7 +44120,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c ret = 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 *object, if (object->n_exclusive > 0) { atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -42949,7 +44134,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c fscache_start_operations(object); } else { ASSERTCMP(object->n_exclusive, ==, 0); -@@ -219,12 +219,12 @@ int fscache_submit_op(struct fscache_obj +@@ -219,12 +219,12 @@ int fscache_submit_op(struct fscache_object *object, object->n_ops++; atomic_inc(&op->usage); list_add_tail(&op->pend_link, &object->pending_ops); @@ -42964,7 +44149,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c ret = -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) ret = -EBUSY; if (!list_empty(&op->pend_link)) { @@ -42973,7 +44158,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/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(); @@ -42982,7 +44167,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c 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"); @@ -42991,7 +44176,7 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c cache = 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) _debug("GC DEFERRED REL OBJ%x OP%x", object->debug_id, op->debug_id); @@ -43000,10 +44185,11 @@ diff -urNp linux-3.0.9/fs/fscache/operation.c linux-3.0.9/fs/fscache/operation.c ASSERTCMP(atomic_read(&op->usage), ==, 0); -diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c ---- linux-3.0.9/fs/fscache/page.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fscache/page.c 2011-11-12 12:47:14.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_cookie *cookie, val = radix_tree_lookup(&cookie->stores, page->index); if (!val) { rcu_read_unlock(); @@ -43012,7 +44198,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/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_cookie *cookie, spin_unlock(&cookie->stores_lock); if (xpage) { @@ -43036,7 +44222,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/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_object *object, FSCACHE_COOKIE_STORING_TAG); if (!radix_tree_tag_get(&cookie->stores, page->index, FSCACHE_COOKIE_PENDING_TAG)) { @@ -43045,7 +44231,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c xpage = 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_operation *op) _enter("{OBJ%x OP%x}", object->debug_id, op->debug_id); @@ -43054,7 +44240,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c 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) ASSERTCMP(cookie->def->type, !=, FSCACHE_COOKIE_TYPE_INDEX); @@ -43068,7 +44254,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c _leave(" = -ENOMEM"); return -ENOMEM; } -@@ -199,7 +199,7 @@ int __fscache_attr_changed(struct fscach +@@ -199,7 +199,7 @@ int __fscache_attr_changed(struct fscache_cookie *cookie) if (fscache_submit_exclusive_op(object, op) < 0) goto nobufs; spin_unlock(&cookie->lock); @@ -43077,7 +44263,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c fscache_put_operation(op); _leave(" = 0"); return 0; -@@ -207,7 +207,7 @@ int __fscache_attr_changed(struct fscach +@@ -207,7 +207,7 @@ int __fscache_attr_changed(struct fscache_cookie *cookie) nobufs: spin_unlock(&cookie->lock); kfree(op); @@ -43086,7 +44272,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c _leave(" = %d", -ENOBUFS); return -ENOBUFS; } -@@ -243,7 +243,7 @@ static struct fscache_retrieval *fscache +@@ -243,7 +243,7 @@ static struct fscache_retrieval *fscache_alloc_retrieval( /* allocate a retrieval operation and attempt to submit it */ op = kzalloc(sizeof(*op), GFP_NOIO); if (!op) { @@ -43095,7 +44281,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c return NULL; } -@@ -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; } @@ -43111,7 +44297,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c _leave(" = -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 fscache_cookie *cookie) */ static int fscache_wait_for_retrieval_activation(struct fscache_object *object, struct fscache_retrieval *op, @@ -43122,7 +44308,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c { int ret; -@@ -304,7 +304,7 @@ static int fscache_wait_for_retrieval_ac +@@ -304,7 +304,7 @@ static int fscache_wait_for_retrieval_activation(struct fscache_object *object, goto check_if_dead; _debug(">>> WT"); @@ -43131,7 +44317,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/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(struct fscache_object *object, check_if_dead: if (unlikely(fscache_object_is_dead(object))) { @@ -43140,7 +44326,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c return -ENOBUFS; } return 0; -@@ -348,7 +348,7 @@ int __fscache_read_or_alloc_page(struct +@@ -348,7 +348,7 @@ int __fscache_read_or_alloc_page(struct fscache_cookie *cookie, _enter("%p,%p,,,", cookie, page); @@ -43149,7 +44335,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c if (hlist_empty(&cookie->backing_objects)) goto nobufs; -@@ -381,7 +381,7 @@ int __fscache_read_or_alloc_page(struct +@@ -381,7 +381,7 @@ int __fscache_read_or_alloc_page(struct fscache_cookie *cookie, goto nobufs_unlock; spin_unlock(&cookie->lock); @@ -43158,7 +44344,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c /* 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 +@@ -411,15 +411,15 @@ int __fscache_read_or_alloc_page(struct fscache_cookie *cookie, error: if (ret == -ENOMEM) @@ -43188,7 +44374,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c _leave(" = -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_cookie *cookie, _enter("%p,,%d,,,", cookie, *nr_pages); @@ -43197,7 +44383,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c 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_cookie *cookie, goto nobufs_unlock; spin_unlock(&cookie->lock); @@ -43206,7 +44392,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c /* 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_cookie *cookie, error: if (ret == -ENOMEM) @@ -43236,7 +44422,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c _leave(" = -ENOBUFS"); return -ENOBUFS; } -@@ -569,7 +569,7 @@ int __fscache_alloc_page(struct fscache_ +@@ -569,7 +569,7 @@ int __fscache_alloc_page(struct fscache_cookie *cookie, _enter("%p,%p,,,", cookie, page); @@ -43245,7 +44431,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c 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 *cookie, goto nobufs_unlock; spin_unlock(&cookie->lock); @@ -43254,7 +44440,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c ret = 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 *cookie, error: if (ret == -ERESTARTSYS) @@ -43278,7 +44464,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c _leave(" = -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_operation *_op) spin_lock(&cookie->stores_lock); @@ -43287,7 +44473,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c /* find a page to store */ page = NULL; -@@ -677,7 +677,7 @@ static void fscache_write_op(struct fsca +@@ -677,7 +677,7 @@ static void fscache_write_op(struct fscache_operation *_op) page = results[0]; _debug("gang %d [%lx]", n, page->index); if (page->index > op->store_limit) { @@ -43296,7 +44482,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c goto superseded; } -@@ -689,7 +689,7 @@ static void fscache_write_op(struct fsca +@@ -689,7 +689,7 @@ static void fscache_write_op(struct fscache_operation *_op) spin_unlock(&cookie->stores_lock); spin_unlock(&object->lock); @@ -43305,7 +44491,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c fscache_stat(&fscache_n_cop_write_page); ret = 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 *cookie, ASSERTCMP(cookie->def->type, !=, FSCACHE_COOKIE_TYPE_INDEX); ASSERT(PageFsCache(page)); @@ -43314,7 +44500,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c op = 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 *cookie, spin_unlock(&cookie->stores_lock); spin_unlock(&object->lock); @@ -43323,7 +44509,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c op->store_limit = object->store_limit; 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 *cookie, spin_unlock(&cookie->lock); radix_tree_preload_end(); @@ -43334,7 +44520,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c /* 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 *cookie, return 0; already_queued: @@ -43368,7 +44554,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c _leave(" = -ENOMEM"); return -ENOMEM; } -@@ -876,7 +876,7 @@ void __fscache_uncache_page(struct fscac +@@ -876,7 +876,7 @@ void __fscache_uncache_page(struct fscache_cookie *cookie, struct page *page) ASSERTCMP(cookie->def->type, !=, FSCACHE_COOKIE_TYPE_INDEX); ASSERTCMP(page, !=, NULL); @@ -43377,7 +44563,7 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c /* 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_retrieval *op, unsigned long loop; #ifdef CONFIG_FSCACHE_STATS @@ -43386,9 +44572,10 @@ diff -urNp linux-3.0.9/fs/fscache/page.c linux-3.0.9/fs/fscache/page.c #endif for (loop = 0; loop < pagevec->nr; loop++) { -diff -urNp linux-3.0.9/fs/fscache/stats.c linux-3.0.9/fs/fscache/stats.c ---- linux-3.0.9/fs/fscache/stats.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fscache/stats.c 2011-11-12 12:47:14.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 @@ -43574,7 +44761,7 @@ diff -urNp linux-3.0.9/fs/fscache/stats.c linux-3.0.9/fs/fscache/stats.c 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"); seq_printf(m, "Cookies: idx=%u dat=%u spc=%u\n", @@ -43764,101 +44951,10 @@ diff -urNp linux-3.0.9/fs/fscache/stats.c linux-3.0.9/fs/fscache/stats.c seq_printf(m, "CacheOp: alo=%d luo=%d luc=%d gro=%d\n", atomic_read(&fscache_n_cop_alloc_object), -diff -urNp linux-3.0.9/fs/fs_struct.c linux-3.0.9/fs/fs_struct.c ---- linux-3.0.9/fs/fs_struct.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fs_struct.c 2011-11-12 12:47:14.000000000 -0500 -@@ -4,6 +4,7 @@ - #include <linux/path.h> - #include <linux/slab.h> - #include <linux/fs_struct.h> -+#include <linux/grsecurity.h> - #include "internal.h" - - static inline void path_get_longterm(struct path *path) -@@ -31,6 +32,7 @@ void set_fs_root(struct fs_struct *fs, s - old_root = fs->root; - fs->root = *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 == old_root->mnt) { - path_get_longterm(new_root); - fs->root = *new_root; -+ gr_set_chroot_entries(p, new_root); - count++; - } - if (fs->pwd.dentry == 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 = NULL; -- kill = !--fs->users; -+ gr_clear_chroot_entries(tsk); -+ kill = !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 - struct fs_struct *fs = kmem_cache_alloc(fs_cachep, GFP_KERNEL); - /* We don't need to lock fs - think why ;-) */ - if (fs) { -- fs->users = 1; -+ atomic_set(&fs->users, 1); - fs->in_exec = 0; - spin_lock_init(&fs->lock); - seqcount_init(&fs->seq); -@@ -132,6 +136,9 @@ struct fs_struct *copy_fs_struct(struct - spin_lock(&old->lock); - fs->root = 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 = old->pwd; - path_get_longterm(&fs->pwd); - spin_unlock(&old->lock); -@@ -150,8 +157,9 @@ int unshare_fs_struct(void) - - task_lock(current); - spin_lock(&fs->lock); -- kill = !--fs->users; -+ kill = !atomic_dec_return(&fs->users); - current->fs = new_fs; -+ gr_set_chroot_entries(current, &new_fs->root); - spin_unlock(&fs->lock); - task_unlock(current); - -@@ -170,7 +178,7 @@ EXPORT_SYMBOL(current_umask); - - /* to be mentioned only in INIT_TASK */ - struct fs_struct init_fs = { -- .users = 1, -+ .users = ATOMIC_INIT(1), - .lock = __SPIN_LOCK_UNLOCKED(init_fs.lock), - .seq = SEQCNT_ZERO, - .umask = 0022, -@@ -186,12 +194,13 @@ void daemonize_fs_struct(void) - task_lock(current); - - spin_lock(&init_fs.lock); -- init_fs.users++; -+ atomic_inc(&init_fs.users); - spin_unlock(&init_fs.lock); - - spin_lock(&fs->lock); - current->fs = &init_fs; -- kill = !--fs->users; -+ gr_set_chroot_entries(current, ¤t->fs->root); -+ kill = !atomic_dec_return(&fs->users); - spin_unlock(&fs->lock); - - task_unlock(current); -diff -urNp linux-3.0.9/fs/fuse/cuse.c linux-3.0.9/fs/fuse/cuse.c ---- linux-3.0.9/fs/fuse/cuse.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fuse/cuse.c 2011-11-12 12:47:14.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]); @@ -43876,10 +44972,11 @@ diff -urNp linux-3.0.9/fs/fuse/cuse.c linux-3.0.9/fs/fuse/cuse.c cuse_class = class_create(THIS_MODULE, "cuse"); if (IS_ERR(cuse_class)) -diff -urNp linux-3.0.9/fs/fuse/dev.c linux-3.0.9/fs/fuse/dev.c ---- linux-3.0.9/fs/fuse/dev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fuse/dev.c 2011-11-12 12:47:14.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 *in, loff_t *ppos, ret = 0; pipe_lock(pipe); @@ -43888,10 +44985,11 @@ diff -urNp linux-3.0.9/fs/fuse/dev.c linux-3.0.9/fs/fuse/dev.c send_sig(SIGPIPE, current, 0); if (!ret) ret = -EPIPE; -diff -urNp linux-3.0.9/fs/fuse/dir.c linux-3.0.9/fs/fuse/dir.c ---- linux-3.0.9/fs/fuse/dir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/fuse/dir.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1148,7 +1148,7 @@ static char *read_link(struct dentry *de +diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c +index d5016071..c46675a 100644 +--- a/fs/fuse/dir.c ++++ b/fs/fuse/dir.c +@@ -1148,7 +1148,7 @@ static char *read_link(struct dentry *dentry) return link; } @@ -43900,9 +44998,10 @@ diff -urNp linux-3.0.9/fs/fuse/dir.c linux-3.0.9/fs/fuse/dir.c { if (!IS_ERR(link)) free_page((unsigned long) link); -diff -urNp linux-3.0.9/fs/gfs2/inode.c linux-3.0.9/fs/gfs2/inode.c ---- linux-3.0.9/fs/gfs2/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/gfs2/inode.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c +index 03e0c52..f9d0602 100644 +--- a/fs/gfs2/inode.c ++++ b/fs/gfs2/inode.c @@ -1525,7 +1525,7 @@ out: static void gfs2_put_link(struct dentry *dentry, struct nameidata *nd, void *p) @@ -43912,10 +45011,11 @@ diff -urNp linux-3.0.9/fs/gfs2/inode.c linux-3.0.9/fs/gfs2/inode.c if (!IS_ERR(s)) kfree(s); } -diff -urNp linux-3.0.9/fs/hfsplus/catalog.c linux-3.0.9/fs/hfsplus/catalog.c ---- linux-3.0.9/fs/hfsplus/catalog.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/hfsplus/catalog.c 2011-11-12 12:47:14.000000000 -0500 -@@ -179,6 +179,8 @@ int hfsplus_find_cat(struct super_block +diff --git a/fs/hfsplus/catalog.c b/fs/hfsplus/catalog.c +index b4ba1b3..6295691 100644 +--- a/fs/hfsplus/catalog.c ++++ b/fs/hfsplus/catalog.c +@@ -179,6 +179,8 @@ int hfsplus_find_cat(struct super_block *sb, u32 cnid, int err; u16 type; @@ -43924,7 +45024,7 @@ diff -urNp linux-3.0.9/fs/hfsplus/catalog.c linux-3.0.9/fs/hfsplus/catalog.c hfsplus_cat_build_key(sb, fd->search_key, cnid, NULL); err = hfs_brec_read(fd, &tmp, sizeof(hfsplus_cat_entry)); if (err) -@@ -210,6 +212,8 @@ int hfsplus_create_cat(u32 cnid, struct +@@ -210,6 +212,8 @@ int hfsplus_create_cat(u32 cnid, struct inode *dir, int entry_size; int err; @@ -43942,10 +45042,11 @@ diff -urNp linux-3.0.9/fs/hfsplus/catalog.c linux-3.0.9/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.0.9/fs/hfsplus/dir.c linux-3.0.9/fs/hfsplus/dir.c ---- linux-3.0.9/fs/hfsplus/dir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/hfsplus/dir.c 2011-11-12 12:47:14.000000000 -0500 -@@ -129,6 +129,8 @@ static int hfsplus_readdir(struct file * +diff --git a/fs/hfsplus/dir.c b/fs/hfsplus/dir.c +index 4df5059..00a2dcd 100644 +--- a/fs/hfsplus/dir.c ++++ b/fs/hfsplus/dir.c +@@ -129,6 +129,8 @@ static int hfsplus_readdir(struct file *filp, void *dirent, filldir_t filldir) struct hfsplus_readdir_data *rd; u16 type; @@ -43954,10 +45055,11 @@ diff -urNp linux-3.0.9/fs/hfsplus/dir.c linux-3.0.9/fs/hfsplus/dir.c if (filp->f_pos >= inode->i_size) return 0; -diff -urNp linux-3.0.9/fs/hfsplus/inode.c linux-3.0.9/fs/hfsplus/inode.c ---- linux-3.0.9/fs/hfsplus/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/hfsplus/inode.c 2011-11-12 12:47:14.000000000 -0500 -@@ -489,6 +489,8 @@ int hfsplus_cat_read_inode(struct inode +diff --git a/fs/hfsplus/inode.c b/fs/hfsplus/inode.c +index b248a6cf..2a81d50 100644 +--- a/fs/hfsplus/inode.c ++++ b/fs/hfsplus/inode.c +@@ -489,6 +489,8 @@ int hfsplus_cat_read_inode(struct inode *inode, struct hfs_find_data *fd) int res = 0; u16 type; @@ -43966,7 +45068,7 @@ diff -urNp linux-3.0.9/fs/hfsplus/inode.c linux-3.0.9/fs/hfsplus/inode.c type = hfs_bnode_read_u16(fd->bnode, fd->entryoffset); HFSPLUS_I(inode)->linkid = 0; -@@ -552,6 +554,8 @@ int hfsplus_cat_write_inode(struct inode +@@ -552,6 +554,8 @@ int hfsplus_cat_write_inode(struct inode *inode) struct hfs_find_data fd; hfsplus_cat_entry entry; @@ -43975,10 +45077,11 @@ diff -urNp linux-3.0.9/fs/hfsplus/inode.c linux-3.0.9/fs/hfsplus/inode.c if (HFSPLUS_IS_RSRC(inode)) main_inode = HFSPLUS_I(inode)->rsrc_inode; -diff -urNp linux-3.0.9/fs/hfsplus/ioctl.c linux-3.0.9/fs/hfsplus/ioctl.c ---- linux-3.0.9/fs/hfsplus/ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/hfsplus/ioctl.c 2011-11-12 12:47:14.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 char *name, struct hfsplus_cat_file *file; int res; @@ -43987,7 +45090,7 @@ diff -urNp linux-3.0.9/fs/hfsplus/ioctl.c linux-3.0.9/fs/hfsplus/ioctl.c if (!S_ISREG(inode->i_mode) || HFSPLUS_IS_RSRC(inode)) return -EOPNOTSUPP; -@@ -166,6 +168,8 @@ ssize_t hfsplus_getxattr(struct dentry * +@@ -166,6 +168,8 @@ ssize_t hfsplus_getxattr(struct dentry *dentry, const char *name, struct hfsplus_cat_file *file; ssize_t res = 0; @@ -43996,10 +45099,11 @@ diff -urNp linux-3.0.9/fs/hfsplus/ioctl.c linux-3.0.9/fs/hfsplus/ioctl.c if (!S_ISREG(inode->i_mode) || HFSPLUS_IS_RSRC(inode)) return -EOPNOTSUPP; -diff -urNp linux-3.0.9/fs/hfsplus/super.c linux-3.0.9/fs/hfsplus/super.c ---- linux-3.0.9/fs/hfsplus/super.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/hfsplus/super.c 2011-11-12 12:47:14.000000000 -0500 -@@ -340,6 +340,8 @@ static int hfsplus_fill_super(struct sup +diff --git a/fs/hfsplus/super.c b/fs/hfsplus/super.c +index c3a76fd..2fec62e 100644 +--- a/fs/hfsplus/super.c ++++ b/fs/hfsplus/super.c +@@ -340,6 +340,8 @@ static int hfsplus_fill_super(struct super_block *sb, void *data, int silent) struct nls_table *nls = NULL; int err; @@ -44008,10 +45112,11 @@ diff -urNp linux-3.0.9/fs/hfsplus/super.c linux-3.0.9/fs/hfsplus/super.c err = -EINVAL; sbi = kzalloc(sizeof(*sbi), GFP_KERNEL); if (!sbi) -diff -urNp linux-3.0.9/fs/hugetlbfs/inode.c linux-3.0.9/fs/hugetlbfs/inode.c ---- linux-3.0.9/fs/hugetlbfs/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/hugetlbfs/inode.c 2011-11-12 12:47:14.000000000 -0500 -@@ -914,7 +914,7 @@ static struct file_system_type hugetlbfs +diff --git a/fs/hugetlbfs/inode.c b/fs/hugetlbfs/inode.c +index 7aafeb8..8d823ef 100644 +--- a/fs/hugetlbfs/inode.c ++++ b/fs/hugetlbfs/inode.c +@@ -914,7 +914,7 @@ static struct file_system_type hugetlbfs_fs_type = { .kill_sb = kill_litter_super, }; @@ -44020,9 +45125,10 @@ diff -urNp linux-3.0.9/fs/hugetlbfs/inode.c linux-3.0.9/fs/hugetlbfs/inode.c static int can_do_hugetlb_shm(void) { -diff -urNp linux-3.0.9/fs/inode.c linux-3.0.9/fs/inode.c ---- linux-3.0.9/fs/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/inode.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/inode.c b/fs/inode.c +index 43566d1..ed49029 100644 +--- a/fs/inode.c ++++ b/fs/inode.c @@ -829,8 +829,8 @@ unsigned int get_next_ino(void) #ifdef CONFIG_SMP @@ -44034,10 +45140,11 @@ diff -urNp linux-3.0.9/fs/inode.c linux-3.0.9/fs/inode.c res = next - LAST_INO_BATCH; } -diff -urNp linux-3.0.9/fs/jbd/checkpoint.c linux-3.0.9/fs/jbd/checkpoint.c ---- linux-3.0.9/fs/jbd/checkpoint.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/jbd/checkpoint.c 2011-11-12 12:47:14.000000000 -0500 -@@ -350,6 +350,8 @@ int log_do_checkpoint(journal_t *journal +diff --git a/fs/jbd/checkpoint.c b/fs/jbd/checkpoint.c +index e4b87bc..37402f7 100644 +--- a/fs/jbd/checkpoint.c ++++ b/fs/jbd/checkpoint.c +@@ -350,6 +350,8 @@ int log_do_checkpoint(journal_t *journal) tid_t this_tid; int result; @@ -44046,10 +45153,11 @@ diff -urNp linux-3.0.9/fs/jbd/checkpoint.c linux-3.0.9/fs/jbd/checkpoint.c jbd_debug(1, "Start checkpoint\n"); /* -diff -urNp linux-3.0.9/fs/jffs2/compr_rtime.c linux-3.0.9/fs/jffs2/compr_rtime.c ---- linux-3.0.9/fs/jffs2/compr_rtime.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/jffs2/compr_rtime.c 2011-11-12 12:47:14.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 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 = 0; int pos=0; @@ -44058,7 +45166,7 @@ diff -urNp linux-3.0.9/fs/jffs2/compr_rtime.c linux-3.0.9/fs/jffs2/compr_rtime.c memset(positions,0,sizeof(positions)); while (pos < (*sourcelen) && outpos <= (*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 = 0; int pos=0; @@ -44067,10 +45175,11 @@ diff -urNp linux-3.0.9/fs/jffs2/compr_rtime.c linux-3.0.9/fs/jffs2/compr_rtime.c memset(positions,0,sizeof(positions)); while (outpos<destlen) { -diff -urNp linux-3.0.9/fs/jffs2/compr_rubin.c linux-3.0.9/fs/jffs2/compr_rubin.c ---- linux-3.0.9/fs/jffs2/compr_rubin.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/jffs2/compr_rubin.c 2011-11-12 12:47:14.000000000 -0500 -@@ -314,6 +314,8 @@ static int jffs2_dynrubin_compress(unsig +diff --git a/fs/jffs2/compr_rubin.c b/fs/jffs2/compr_rubin.c +index 9e7cec8..4713089 100644 +--- a/fs/jffs2/compr_rubin.c ++++ b/fs/jffs2/compr_rubin.c +@@ -314,6 +314,8 @@ static int jffs2_dynrubin_compress(unsigned char *data_in, int ret; uint32_t mysrclen, mydstlen; @@ -44079,10 +45188,11 @@ diff -urNp linux-3.0.9/fs/jffs2/compr_rubin.c linux-3.0.9/fs/jffs2/compr_rubin.c mysrclen = *sourcelen; mydstlen = *dstlen - 8; -diff -urNp linux-3.0.9/fs/jffs2/erase.c linux-3.0.9/fs/jffs2/erase.c ---- linux-3.0.9/fs/jffs2/erase.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/jffs2/erase.c 2011-11-12 12:47:14.000000000 -0500 -@@ -439,7 +439,8 @@ static void jffs2_mark_erased_block(stru +diff --git a/fs/jffs2/erase.c b/fs/jffs2/erase.c +index e513f19..2ab1351 100644 +--- a/fs/jffs2/erase.c ++++ b/fs/jffs2/erase.c +@@ -439,7 +439,8 @@ static void jffs2_mark_erased_block(struct jffs2_sb_info *c, struct jffs2_eraseb struct jffs2_unknown_node marker = { .magic = cpu_to_je16(JFFS2_MAGIC_BITMASK), .nodetype = cpu_to_je16(JFFS2_NODETYPE_CLEANMARKER), @@ -44092,10 +45202,11 @@ diff -urNp linux-3.0.9/fs/jffs2/erase.c linux-3.0.9/fs/jffs2/erase.c }; jffs2_prealloc_raw_node_refs(c, jeb, 1); -diff -urNp linux-3.0.9/fs/jffs2/wbuf.c linux-3.0.9/fs/jffs2/wbuf.c ---- linux-3.0.9/fs/jffs2/wbuf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/jffs2/wbuf.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1012,7 +1012,8 @@ static const struct jffs2_unknown_node o +diff --git a/fs/jffs2/wbuf.c b/fs/jffs2/wbuf.c +index 4515bea..178f2d6 100644 +--- a/fs/jffs2/wbuf.c ++++ b/fs/jffs2/wbuf.c +@@ -1012,7 +1012,8 @@ static const struct jffs2_unknown_node oob_cleanmarker = { .magic = constant_cpu_to_je16(JFFS2_MAGIC_BITMASK), .nodetype = constant_cpu_to_je16(JFFS2_NODETYPE_CLEANMARKER), @@ -44105,10 +45216,11 @@ diff -urNp linux-3.0.9/fs/jffs2/wbuf.c linux-3.0.9/fs/jffs2/wbuf.c }; /* -diff -urNp linux-3.0.9/fs/jffs2/xattr.c linux-3.0.9/fs/jffs2/xattr.c ---- linux-3.0.9/fs/jffs2/xattr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/jffs2/xattr.c 2011-11-12 12:47:14.000000000 -0500 -@@ -773,6 +773,8 @@ void jffs2_build_xattr_subsystem(struct +diff --git a/fs/jffs2/xattr.c b/fs/jffs2/xattr.c +index 3e93cdd..c8a80e1 100644 +--- a/fs/jffs2/xattr.c ++++ b/fs/jffs2/xattr.c +@@ -773,6 +773,8 @@ void jffs2_build_xattr_subsystem(struct jffs2_sb_info *c) BUG_ON(!(c->flags & JFFS2_SB_FLAG_BUILDING)); @@ -44117,9 +45229,10 @@ diff -urNp linux-3.0.9/fs/jffs2/xattr.c linux-3.0.9/fs/jffs2/xattr.c /* Phase.1 : Merge same xref */ for (i=0; i < XREF_TMPHASH_SIZE; i++) xref_tmphash[i] = NULL; -diff -urNp linux-3.0.9/fs/jfs/super.c linux-3.0.9/fs/jfs/super.c ---- linux-3.0.9/fs/jfs/super.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/jfs/super.c 2011-11-12 12:47:14.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) jfs_inode_cachep = @@ -44129,22 +45242,11 @@ diff -urNp linux-3.0.9/fs/jfs/super.c linux-3.0.9/fs/jfs/super.c init_once); if (jfs_inode_cachep == NULL) return -ENOMEM; -diff -urNp linux-3.0.9/fs/Kconfig.binfmt linux-3.0.9/fs/Kconfig.binfmt ---- linux-3.0.9/fs/Kconfig.binfmt 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/Kconfig.binfmt 2011-11-12 12:47:14.000000000 -0500 -@@ -86,7 +86,7 @@ config HAVE_AOUT - - 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.0.9/fs/libfs.c linux-3.0.9/fs/libfs.c ---- linux-3.0.9/fs/libfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/libfs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -163,6 +163,9 @@ int dcache_readdir(struct file * filp, v +diff --git a/fs/libfs.c b/fs/libfs.c +index 275ca474..4cf2811 100644 +--- a/fs/libfs.c ++++ b/fs/libfs.c +@@ -163,6 +163,9 @@ int dcache_readdir(struct file * filp, void * dirent, filldir_t filldir) for (p=q->next; p != &dentry->d_subdirs; p=p->next) { struct dentry *next; @@ -44154,7 +45256,7 @@ diff -urNp linux-3.0.9/fs/libfs.c linux-3.0.9/fs/libfs.c next = list_entry(p, struct dentry, d_u.d_child); spin_lock_nested(&next->d_lock, DENTRY_D_LOCK_NESTED); if (!simple_positive(next)) { -@@ -172,7 +175,12 @@ int dcache_readdir(struct file * filp, v +@@ -172,7 +175,12 @@ int dcache_readdir(struct file * filp, void * dirent, filldir_t filldir) spin_unlock(&next->d_lock); spin_unlock(&dentry->d_lock); @@ -44168,10 +45270,11 @@ diff -urNp linux-3.0.9/fs/libfs.c linux-3.0.9/fs/libfs.c next->d_name.len, filp->f_pos, next->d_inode->i_ino, dt_type(next->d_inode)) < 0) -diff -urNp linux-3.0.9/fs/lockd/clntproc.c linux-3.0.9/fs/lockd/clntproc.c ---- linux-3.0.9/fs/lockd/clntproc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/lockd/clntproc.c 2011-11-12 12:47:14.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 e374050..972f4de 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 */ @@ -44185,7 +45288,7 @@ diff -urNp linux-3.0.9/fs/lockd/clntproc.c linux-3.0.9/fs/lockd/clntproc.c memcpy(c->data, &cookie, 4); c->len=4; -@@ -620,6 +620,8 @@ nlmclnt_reclaim(struct nlm_host *host, s +@@ -620,6 +620,8 @@ nlmclnt_reclaim(struct nlm_host *host, struct file_lock *fl) struct nlm_rqst reqst, *req; int status; @@ -44194,10 +45297,11 @@ diff -urNp linux-3.0.9/fs/lockd/clntproc.c linux-3.0.9/fs/lockd/clntproc.c req = &reqst; memset(req, 0, sizeof(*req)); locks_init_lock(&req->a_args.lock.fl); -diff -urNp linux-3.0.9/fs/locks.c linux-3.0.9/fs/locks.c ---- linux-3.0.9/fs/locks.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/locks.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2043,16 +2043,16 @@ void locks_remove_flock(struct file *fil +diff --git a/fs/locks.c b/fs/locks.c +index b286539..d73d4af 100644 +--- a/fs/locks.c ++++ b/fs/locks.c +@@ -2043,16 +2043,16 @@ void locks_remove_flock(struct file *filp) return; if (filp->f_op && filp->f_op->flock) { @@ -44218,10 +45322,11 @@ diff -urNp linux-3.0.9/fs/locks.c linux-3.0.9/fs/locks.c } lock_flocks(); -diff -urNp linux-3.0.9/fs/logfs/super.c linux-3.0.9/fs/logfs/super.c ---- linux-3.0.9/fs/logfs/super.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/logfs/super.c 2011-11-12 12:47:14.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 = &_ds1; int err, valid0, valid1; @@ -44230,10 +45335,11 @@ diff -urNp linux-3.0.9/fs/logfs/super.c linux-3.0.9/fs/logfs/super.c /* read first superblock */ err = wbuf_read(sb, super->s_sb_ofs[0], sizeof(*ds0), ds0); if (err) -diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c ---- linux-3.0.9/fs/namei.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/namei.c 2011-11-12 12:47:14.000000000 -0500 -@@ -239,21 +239,23 @@ int generic_permission(struct inode *ino +diff --git a/fs/namei.c b/fs/namei.c +index f7593c0..581e14f 100644 +--- a/fs/namei.c ++++ b/fs/namei.c +@@ -239,21 +239,23 @@ int generic_permission(struct inode *inode, int mask, unsigned int flags, return ret; /* @@ -44266,7 +45372,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c return -EACCES; } -@@ -595,9 +597,12 @@ static inline int exec_permission(struct +@@ -595,9 +597,12 @@ static inline int exec_permission(struct inode *inode, unsigned int flags) if (ret == -ECHILD) return ret; @@ -44281,7 +45387,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c return ret; ok: -@@ -705,11 +710,19 @@ follow_link(struct path *link, struct na +@@ -705,11 +710,19 @@ follow_link(struct path *link, struct nameidata *nd, void **p) return error; } @@ -44302,7 +45408,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = 0; if (s) error = __vfs_follow_link(nd, s); -@@ -1606,6 +1619,12 @@ static int path_lookupat(int dfd, const +@@ -1606,6 +1619,12 @@ static int path_lookupat(int dfd, const char *name, if (!err) err = complete_walk(nd); @@ -44315,7 +45421,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c if (!err && nd->flags & LOOKUP_DIRECTORY) { if (!nd->inode->i_op->lookup) { path_put(&nd->path); -@@ -1633,6 +1652,9 @@ static int do_path_lookup(int dfd, const +@@ -1633,6 +1652,9 @@ static int do_path_lookup(int dfd, const char *name, retval = path_lookupat(dfd, name, flags | LOOKUP_REVAL, nd); if (likely(!retval)) { @@ -44325,7 +45431,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c if (unlikely(!audit_dummy_context())) { if (nd->path.dentry && nd->inode) audit_inode(name, nd->path.dentry); -@@ -1949,6 +1971,30 @@ int vfs_create(struct inode *dir, struct +@@ -1949,6 +1971,30 @@ int vfs_create(struct inode *dir, struct dentry *dentry, int mode, return error; } @@ -44356,7 +45462,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c static int may_open(struct path *path, int acc_mode, int flag) { struct dentry *dentry = path->dentry; -@@ -2001,7 +2047,27 @@ static int may_open(struct path *path, i +@@ -2001,7 +2047,27 @@ static int may_open(struct path *path, int acc_mode, int flag) /* * Ensure there are no outstanding leases on the file. */ @@ -44385,7 +45491,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c } static int handle_truncate(struct file *filp) -@@ -2027,30 +2093,6 @@ static int handle_truncate(struct file * +@@ -2027,30 +2093,6 @@ static int handle_truncate(struct file *filp) } /* @@ -44416,7 +45522,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c * Handle the last step of open() */ static struct file *do_last(struct nameidata *nd, struct path *path, -@@ -2059,6 +2101,7 @@ static struct file *do_last(struct namei +@@ -2059,6 +2101,7 @@ static struct file *do_last(struct nameidata *nd, struct path *path, struct dentry *dir = nd->path.dentry; struct dentry *dentry; int open_flag = op->open_flag; @@ -44424,7 +45530,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c int will_truncate = open_flag & O_TRUNC; int want_write = 0; int acc_mode = op->acc_mode; -@@ -2079,6 +2122,10 @@ static struct file *do_last(struct namei +@@ -2079,6 +2122,10 @@ static struct file *do_last(struct nameidata *nd, struct path *path, error = complete_walk(nd); if (error) return ERR_PTR(error); @@ -44435,7 +45541,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c audit_inode(pathname, nd->path.dentry); if (open_flag & O_CREAT) { error = -EISDIR; -@@ -2089,6 +2136,10 @@ static struct file *do_last(struct namei +@@ -2089,6 +2136,10 @@ static struct file *do_last(struct nameidata *nd, struct path *path, error = complete_walk(nd); if (error) return ERR_PTR(error); @@ -44446,7 +45552,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c audit_inode(pathname, dir); goto ok; } -@@ -2111,6 +2162,11 @@ static struct file *do_last(struct namei +@@ -2111,6 +2162,11 @@ static struct file *do_last(struct nameidata *nd, struct path *path, if (error) return ERR_PTR(-ECHILD); @@ -44458,7 +45564,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = -ENOTDIR; if (nd->flags & LOOKUP_DIRECTORY) { if (!nd->inode->i_op->lookup) -@@ -2150,6 +2206,12 @@ static struct file *do_last(struct namei +@@ -2150,6 +2206,12 @@ static struct file *do_last(struct nameidata *nd, struct path *path, /* Negative dentry, just create the file */ if (!dentry->d_inode) { int mode = op->mode; @@ -44471,7 +45577,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c if (!IS_POSIXACL(dir->d_inode)) mode &= ~current_umask(); /* -@@ -2173,6 +2235,8 @@ static struct file *do_last(struct namei +@@ -2173,6 +2235,8 @@ static struct file *do_last(struct nameidata *nd, struct path *path, error = vfs_create(dir->d_inode, dentry, mode, nd); if (error) goto exit_mutex_unlock; @@ -44480,7 +45586,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c mutex_unlock(&dir->d_inode->i_mutex); dput(nd->path.dentry); nd->path.dentry = dentry; -@@ -2182,6 +2246,19 @@ static struct file *do_last(struct namei +@@ -2182,6 +2246,19 @@ static struct file *do_last(struct nameidata *nd, struct path *path, /* * It already exists. */ @@ -44500,7 +45606,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c mutex_unlock(&dir->d_inode->i_mutex); audit_inode(pathname, path->dentry); -@@ -2398,6 +2475,10 @@ struct dentry *lookup_create(struct name +@@ -2398,6 +2475,10 @@ struct dentry *lookup_create(struct nameidata *nd, int is_dir) } return dentry; eexist: @@ -44511,7 +45617,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c dput(dentry); dentry = ERR_PTR(-EEXIST); fail: -@@ -2475,6 +2556,17 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const +@@ -2475,6 +2556,17 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const char __user *, filename, int, mode, error = may_mknod(mode); if (error) goto out_dput; @@ -44529,7 +45635,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = mnt_want_write(nd.path.mnt); if (error) goto out_dput; -@@ -2495,6 +2587,9 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const +@@ -2495,6 +2587,9 @@ SYSCALL_DEFINE4(mknodat, int, dfd, const char __user *, filename, int, mode, } out_drop_write: mnt_drop_write(nd.path.mnt); @@ -44539,7 +45645,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c out_dput: dput(dentry); out_unlock: -@@ -2547,6 +2642,11 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const +@@ -2547,6 +2642,11 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const char __user *, pathname, int, mode) if (IS_ERR(dentry)) goto out_unlock; @@ -44551,7 +45657,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c if (!IS_POSIXACL(nd.path.dentry->d_inode)) mode &= ~current_umask(); error = mnt_want_write(nd.path.mnt); -@@ -2558,6 +2658,10 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const +@@ -2558,6 +2658,10 @@ SYSCALL_DEFINE3(mkdirat, int, dfd, const char __user *, pathname, int, mode) error = vfs_mkdir(nd.path.dentry->d_inode, dentry, mode); out_drop_write: mnt_drop_write(nd.path.mnt); @@ -44562,7 +45668,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c out_dput: dput(dentry); out_unlock: -@@ -2640,6 +2744,8 @@ static long do_rmdir(int dfd, const char +@@ -2640,6 +2744,8 @@ static long do_rmdir(int dfd, const char __user *pathname) char * name; struct dentry *dentry; struct nameidata nd; @@ -44571,15 +45677,13 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = user_path_parent(dfd, pathname, &nd, &name); if (error) -@@ -2668,6 +2774,17 @@ static long do_rmdir(int dfd, const char +@@ -2668,6 +2774,15 @@ static long do_rmdir(int dfd, const char __user *pathname) error = -ENOENT; goto exit3; } + -+ if (dentry->d_inode->i_nlink <= 1) { -+ saved_ino = dentry->d_inode->i_ino; -+ saved_dev = gr_get_dev_from_dentry(dentry); -+ } ++ saved_ino = dentry->d_inode->i_ino; ++ saved_dev = gr_get_dev_from_dentry(dentry); + + if (!gr_acl_handle_rmdir(dentry, nd.path.mnt)) { + error = -EACCES; @@ -44589,7 +45693,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = mnt_want_write(nd.path.mnt); if (error) goto exit3; -@@ -2675,6 +2792,8 @@ static long do_rmdir(int dfd, const char +@@ -2675,6 +2790,8 @@ static long do_rmdir(int dfd, const char __user *pathname) if (error) goto exit4; error = vfs_rmdir(nd.path.dentry->d_inode, dentry); @@ -44598,7 +45702,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c exit4: mnt_drop_write(nd.path.mnt); exit3: -@@ -2737,6 +2856,8 @@ static long do_unlinkat(int dfd, const c +@@ -2737,6 +2854,8 @@ static long do_unlinkat(int dfd, const char __user *pathname) struct dentry *dentry; struct nameidata nd; struct inode *inode = NULL; @@ -44607,7 +45711,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = user_path_parent(dfd, pathname, &nd, &name); if (error) -@@ -2759,6 +2880,16 @@ static long do_unlinkat(int dfd, const c +@@ -2759,6 +2878,16 @@ static long do_unlinkat(int dfd, const char __user *pathname) if (!inode) goto slashes; ihold(inode); @@ -44624,7 +45728,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = mnt_want_write(nd.path.mnt); if (error) goto exit2; -@@ -2766,6 +2897,8 @@ static long do_unlinkat(int dfd, const c +@@ -2766,6 +2895,8 @@ static long do_unlinkat(int dfd, const char __user *pathname) if (error) goto exit3; error = vfs_unlink(nd.path.dentry->d_inode, dentry); @@ -44633,7 +45737,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c exit3: mnt_drop_write(nd.path.mnt); exit2: -@@ -2843,6 +2976,11 @@ SYSCALL_DEFINE3(symlinkat, const char __ +@@ -2843,6 +2974,11 @@ SYSCALL_DEFINE3(symlinkat, const char __user *, oldname, if (IS_ERR(dentry)) goto out_unlock; @@ -44645,7 +45749,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = mnt_want_write(nd.path.mnt); if (error) goto out_dput; -@@ -2850,6 +2988,8 @@ SYSCALL_DEFINE3(symlinkat, const char __ +@@ -2850,6 +2986,8 @@ SYSCALL_DEFINE3(symlinkat, const char __user *, oldname, if (error) goto out_drop_write; error = vfs_symlink(nd.path.dentry->d_inode, dentry, from); @@ -44654,7 +45758,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c out_drop_write: mnt_drop_write(nd.path.mnt); out_dput: -@@ -2958,6 +3098,20 @@ SYSCALL_DEFINE5(linkat, int, olddfd, con +@@ -2958,6 +3096,20 @@ SYSCALL_DEFINE5(linkat, int, olddfd, const char __user *, oldname, error = PTR_ERR(new_dentry); if (IS_ERR(new_dentry)) goto out_unlock; @@ -44675,7 +45779,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = mnt_want_write(nd.path.mnt); if (error) goto out_dput; -@@ -2965,6 +3119,8 @@ SYSCALL_DEFINE5(linkat, int, olddfd, con +@@ -2965,6 +3117,8 @@ SYSCALL_DEFINE5(linkat, int, olddfd, const char __user *, oldname, if (error) goto out_drop_write; error = vfs_link(old_path.dentry, nd.path.dentry->d_inode, new_dentry); @@ -44684,7 +45788,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c out_drop_write: mnt_drop_write(nd.path.mnt); out_dput: -@@ -3142,6 +3298,8 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -3142,6 +3296,8 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char __user *, oldname, char *to; int error; @@ -44693,7 +45797,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = user_path_parent(olddfd, oldname, &oldnd, &from); if (error) goto exit; -@@ -3198,6 +3356,12 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -3198,6 +3354,12 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char __user *, oldname, if (new_dentry == trap) goto exit5; @@ -44706,7 +45810,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c error = mnt_want_write(oldnd.path.mnt); if (error) goto exit5; -@@ -3207,6 +3371,9 @@ SYSCALL_DEFINE4(renameat, int, olddfd, c +@@ -3207,6 +3369,9 @@ SYSCALL_DEFINE4(renameat, int, olddfd, const char __user *, oldname, goto exit6; error = vfs_rename(old_dir->d_inode, old_dentry, new_dir->d_inode, new_dentry); @@ -44716,7 +45820,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c exit6: mnt_drop_write(oldnd.path.mnt); exit5: -@@ -3232,6 +3399,8 @@ SYSCALL_DEFINE2(rename, const char __use +@@ -3232,6 +3397,8 @@ SYSCALL_DEFINE2(rename, const char __user *, oldname, const char __user *, newna int vfs_readlink(struct dentry *dentry, char __user *buffer, int buflen, const char *link) { @@ -44725,7 +45829,7 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c int len; len = PTR_ERR(link); -@@ -3241,7 +3410,14 @@ int vfs_readlink(struct dentry *dentry, +@@ -3241,7 +3408,14 @@ int vfs_readlink(struct dentry *dentry, char __user *buffer, int buflen, const c len = strlen(link); if (len > (unsigned) buflen) len = buflen; @@ -44741,10 +45845,11 @@ diff -urNp linux-3.0.9/fs/namei.c linux-3.0.9/fs/namei.c len = -EFAULT; out: return len; -diff -urNp linux-3.0.9/fs/namespace.c linux-3.0.9/fs/namespace.c ---- linux-3.0.9/fs/namespace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/namespace.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1329,6 +1329,9 @@ static int do_umount(struct vfsmount *mn +diff --git a/fs/namespace.c b/fs/namespace.c +index 537dd96..672cd58 100644 +--- a/fs/namespace.c ++++ b/fs/namespace.c +@@ -1329,6 +1329,9 @@ static int do_umount(struct vfsmount *mnt, int flags) if (!(sb->s_flags & MS_RDONLY)) retval = do_remount_sb(sb, MS_RDONLY, NULL, 0); up_write(&sb->s_umount); @@ -44754,7 +45859,7 @@ diff -urNp linux-3.0.9/fs/namespace.c linux-3.0.9/fs/namespace.c return retval; } -@@ -1348,6 +1351,9 @@ static int do_umount(struct vfsmount *mn +@@ -1348,6 +1351,9 @@ static int do_umount(struct vfsmount *mnt, int flags) br_write_unlock(vfsmount_lock); up_write(&namespace_sem); release_mounts(&umount_list); @@ -44764,7 +45869,7 @@ diff -urNp linux-3.0.9/fs/namespace.c linux-3.0.9/fs/namespace.c return retval; } -@@ -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, char *type_page, MS_NOATIME | MS_NODIRATIME | MS_RELATIME| MS_KERNMOUNT | MS_STRICTATIME); @@ -44781,7 +45886,7 @@ diff -urNp linux-3.0.9/fs/namespace.c linux-3.0.9/fs/namespace.c if (flags & MS_REMOUNT) retval = 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); @@ -44791,7 +45896,7 @@ diff -urNp linux-3.0.9/fs/namespace.c linux-3.0.9/fs/namespace.c return retval; } -@@ -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; @@ -44803,10 +45908,11 @@ diff -urNp linux-3.0.9/fs/namespace.c linux-3.0.9/fs/namespace.c get_fs_root(current->fs, &root); error = lock_mount(&old); if (error) -diff -urNp linux-3.0.9/fs/ncpfs/dir.c linux-3.0.9/fs/ncpfs/dir.c ---- linux-3.0.9/fs/ncpfs/dir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ncpfs/dir.c 2011-11-12 12:47:14.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 nameidata *nd) int res, val = 0, len; __u8 __name[NCP_MAXPATHLEN + 1]; @@ -44815,7 +45921,7 @@ diff -urNp linux-3.0.9/fs/ncpfs/dir.c linux-3.0.9/fs/ncpfs/dir.c if (dentry == dentry->d_sb->s_root) return 1; -@@ -844,6 +846,8 @@ static struct dentry *ncp_lookup(struct +@@ -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]; @@ -44824,7 +45930,7 @@ diff -urNp linux-3.0.9/fs/ncpfs/dir.c linux-3.0.9/fs/ncpfs/dir.c error = -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=%x\n", dentry->d_parent->d_name.name, dentry->d_name.name, mode); @@ -44833,7 +45939,7 @@ diff -urNp linux-3.0.9/fs/ncpfs/dir.c linux-3.0.9/fs/ncpfs/dir.c ncp_age_dentry(server, dentry); len = sizeof(__name); error = ncp_io2vol(server, __name, &len, dentry->d_name.name, -@@ -992,6 +998,8 @@ static int ncp_mkdir(struct inode *dir, +@@ -992,6 +998,8 @@ static int ncp_mkdir(struct inode *dir, struct dentry *dentry, int mode) int error, len; __u8 __name[NCP_MAXPATHLEN + 1]; @@ -44842,7 +45948,7 @@ diff -urNp linux-3.0.9/fs/ncpfs/dir.c linux-3.0.9/fs/ncpfs/dir.c DPRINTK("ncp_mkdir: making %s/%s\n", dentry->d_parent->d_name.name, dentry->d_name.name); -@@ -1140,6 +1148,8 @@ static int ncp_rename(struct inode *old_ +@@ -1140,6 +1148,8 @@ static int ncp_rename(struct inode *old_dir, struct dentry *old_dentry, int old_len, new_len; __u8 __old_name[NCP_MAXPATHLEN + 1], __new_name[NCP_MAXPATHLEN + 1]; @@ -44851,10 +45957,11 @@ diff -urNp linux-3.0.9/fs/ncpfs/dir.c linux-3.0.9/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.0.9/fs/ncpfs/inode.c linux-3.0.9/fs/ncpfs/inode.c ---- linux-3.0.9/fs/ncpfs/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ncpfs/inode.c 2011-11-12 12:47:14.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, void *raw_data, int silent) #endif struct ncp_entry_info finfo; @@ -44863,10 +45970,11 @@ diff -urNp linux-3.0.9/fs/ncpfs/inode.c linux-3.0.9/fs/ncpfs/inode.c memset(&data, 0, sizeof(data)); server = kzalloc(sizeof(struct ncp_server), GFP_KERNEL); if (!server) -diff -urNp linux-3.0.9/fs/nfs/inode.c linux-3.0.9/fs/nfs/inode.c ---- linux-3.0.9/fs/nfs/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/nfs/inode.c 2011-11-12 12:47:14.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 6f4850d..875435e 100644 +--- a/fs/nfs/inode.c ++++ b/fs/nfs/inode.c +@@ -150,7 +150,7 @@ static void nfs_zap_caches_locked(struct inode *inode) nfsi->attrtimeo = NFS_MINATTRTIMEO(inode); nfsi->attrtimeo_timestamp = jiffies; @@ -44875,7 +45983,7 @@ diff -urNp linux-3.0.9/fs/nfs/inode.c linux-3.0.9/fs/nfs/inode.c if (S_ISREG(mode) || S_ISDIR(mode) || S_ISLNK(mode)) nfsi->cache_validity |= NFS_INO_INVALID_ATTR|NFS_INO_INVALID_DATA|NFS_INO_INVALID_ACCESS|NFS_INO_INVALID_ACL|NFS_INO_REVAL_PAGECACHE; else -@@ -1000,16 +1000,16 @@ static int nfs_size_need_update(const st +@@ -1000,16 +1000,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); } @@ -44895,10 +46003,11 @@ diff -urNp linux-3.0.9/fs/nfs/inode.c linux-3.0.9/fs/nfs/inode.c } void nfs_fattr_init(struct nfs_fattr *fattr) -diff -urNp linux-3.0.9/fs/nfsd/nfs4state.c linux-3.0.9/fs/nfsd/nfs4state.c ---- linux-3.0.9/fs/nfsd/nfs4state.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/nfsd/nfs4state.c 2011-11-12 12:47:14.000000000 -0500 -@@ -3804,6 +3804,8 @@ nfsd4_lock(struct svc_rqst *rqstp, struc +diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c +index ecd8152..88c2e01 100644 +--- a/fs/nfsd/nfs4state.c ++++ b/fs/nfsd/nfs4state.c +@@ -3804,6 +3804,8 @@ nfsd4_lock(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, unsigned int strhashval; int err; @@ -44907,10 +46016,11 @@ diff -urNp linux-3.0.9/fs/nfsd/nfs4state.c linux-3.0.9/fs/nfsd/nfs4state.c dprintk("NFSD: nfsd4_lock: start=%Ld length=%Ld\n", (long long) lock->lk_offset, (long long) lock->lk_length); -diff -urNp linux-3.0.9/fs/nfsd/nfs4xdr.c linux-3.0.9/fs/nfsd/nfs4xdr.c ---- linux-3.0.9/fs/nfsd/nfs4xdr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/nfsd/nfs4xdr.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1800,6 +1800,8 @@ nfsd4_encode_fattr(struct svc_fh *fhp, s +diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c +index 6c74097..4c3d4c8 100644 +--- a/fs/nfsd/nfs4xdr.c ++++ b/fs/nfsd/nfs4xdr.c +@@ -1800,6 +1800,8 @@ nfsd4_encode_fattr(struct svc_fh *fhp, struct svc_export *exp, .dentry = dentry, }; @@ -44919,10 +46029,11 @@ diff -urNp linux-3.0.9/fs/nfsd/nfs4xdr.c linux-3.0.9/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.0.9/fs/nfsd/vfs.c linux-3.0.9/fs/nfsd/vfs.c ---- linux-3.0.9/fs/nfsd/vfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/nfsd/vfs.c 2011-11-12 12:47:14.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 = get_fs(); set_fs(KERNEL_DS); @@ -44931,7 +46042,7 @@ diff -urNp linux-3.0.9/fs/nfsd/vfs.c linux-3.0.9/fs/nfsd/vfs.c set_fs(oldfs); } -@@ -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, /* Write the data. */ oldfs = get_fs(); set_fs(KERNEL_DS); @@ -44940,7 +46051,7 @@ diff -urNp linux-3.0.9/fs/nfsd/vfs.c linux-3.0.9/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_fh *fhp, char *buf, int *lenp) */ oldfs = get_fs(); set_fs(KERNEL_DS); @@ -44949,10 +46060,11 @@ diff -urNp linux-3.0.9/fs/nfsd/vfs.c linux-3.0.9/fs/nfsd/vfs.c set_fs(oldfs); if (host_err < 0) -diff -urNp linux-3.0.9/fs/notify/fanotify/fanotify_user.c linux-3.0.9/fs/notify/fanotify/fanotify_user.c ---- linux-3.0.9/fs/notify/fanotify/fanotify_user.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/notify/fanotify/fanotify_user.c 2011-11-12 12:47:14.000000000 -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/fanotify_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_group *group, goto out_close_fd; ret = -EFAULT; @@ -44962,10 +46074,11 @@ diff -urNp linux-3.0.9/fs/notify/fanotify/fanotify_user.c linux-3.0.9/fs/notify/ fanotify_event_metadata.event_len)) goto out_kill_access_response; -diff -urNp linux-3.0.9/fs/notify/notification.c linux-3.0.9/fs/notify/notification.c ---- linux-3.0.9/fs/notify/notification.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/notify/notification.c 2011-11-12 12:47:14.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 f39260f..79e6b04 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; @@ -44974,7 +46087,7 @@ diff -urNp linux-3.0.9/fs/notify/notification.c linux-3.0.9/fs/notify/notificati /** * fsnotify_get_cookie - return a unique cookie for use in synchronizing events. -@@ -65,7 +65,7 @@ static atomic_t fsnotify_sync_cookie = A +@@ -65,7 +65,7 @@ static atomic_t fsnotify_sync_cookie = ATOMIC_INIT(0); */ u32 fsnotify_get_cookie(void) { @@ -44983,9 +46096,10 @@ diff -urNp linux-3.0.9/fs/notify/notification.c linux-3.0.9/fs/notify/notificati } EXPORT_SYMBOL_GPL(fsnotify_get_cookie); -diff -urNp linux-3.0.9/fs/ntfs/dir.c linux-3.0.9/fs/ntfs/dir.c ---- linux-3.0.9/fs/ntfs/dir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ntfs/dir.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/ntfs/dir.c b/fs/ntfs/dir.c +index 0f48e7c..3cba773 100644 +--- a/fs/ntfs/dir.c ++++ b/fs/ntfs/dir.c @@ -1329,7 +1329,7 @@ find_next_index_buffer: ia = (INDEX_ALLOCATION*)(kaddr + (ia_pos & ~PAGE_CACHE_MASK & ~(s64)(ndir->itype.index.block_size - 1))); @@ -44995,10 +46109,11 @@ diff -urNp linux-3.0.9/fs/ntfs/dir.c linux-3.0.9/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.0.9/fs/ntfs/file.c linux-3.0.9/fs/ntfs/file.c ---- linux-3.0.9/fs/ntfs/file.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ntfs/file.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2222,6 +2222,6 @@ const struct inode_operations ntfs_file_ +diff --git a/fs/ntfs/file.c b/fs/ntfs/file.c +index f4b1057..a0e2493 100644 +--- a/fs/ntfs/file.c ++++ b/fs/ntfs/file.c +@@ -2222,6 +2222,6 @@ const struct inode_operations ntfs_file_inode_ops = { #endif /* NTFS_RW */ }; @@ -45007,10 +46122,11 @@ diff -urNp linux-3.0.9/fs/ntfs/file.c linux-3.0.9/fs/ntfs/file.c -const struct inode_operations ntfs_empty_inode_ops = {}; +const struct inode_operations ntfs_empty_inode_ops __read_only; -diff -urNp linux-3.0.9/fs/ocfs2/localalloc.c linux-3.0.9/fs/ocfs2/localalloc.c ---- linux-3.0.9/fs/ocfs2/localalloc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ocfs2/localalloc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 ocfs2_super *osb, goto bail; } @@ -45019,10 +46135,11 @@ diff -urNp linux-3.0.9/fs/ocfs2/localalloc.c linux-3.0.9/fs/ocfs2/localalloc.c bail: if (handle) -diff -urNp linux-3.0.9/fs/ocfs2/namei.c linux-3.0.9/fs/ocfs2/namei.c ---- linux-3.0.9/fs/ocfs2/namei.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ocfs2/namei.c 2011-11-12 12:47:14.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 e5d738c..318da56 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 = { NULL, }; struct ocfs2_dir_lookup_result target_insert = { NULL, }; @@ -45031,9 +46148,10 @@ diff -urNp linux-3.0.9/fs/ocfs2/namei.c linux-3.0.9/fs/ocfs2/namei.c /* At some point it might be nice to break this function up a * bit. */ -diff -urNp linux-3.0.9/fs/ocfs2/ocfs2.h linux-3.0.9/fs/ocfs2/ocfs2.h ---- linux-3.0.9/fs/ocfs2/ocfs2.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ocfs2/ocfs2.h 2011-11-12 12:47:14.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 struct ocfs2_alloc_stats @@ -45051,10 +46169,11 @@ diff -urNp linux-3.0.9/fs/ocfs2/ocfs2.h linux-3.0.9/fs/ocfs2/ocfs2.h }; enum ocfs2_local_alloc_state -diff -urNp linux-3.0.9/fs/ocfs2/suballoc.c linux-3.0.9/fs/ocfs2/suballoc.c ---- linux-3.0.9/fs/ocfs2/suballoc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ocfs2/suballoc.c 2011-11-12 12:47:14.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; } @@ -45063,7 +46182,7 @@ diff -urNp linux-3.0.9/fs/ocfs2/suballoc.c linux-3.0.9/fs/ocfs2/suballoc.c /* 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; } @@ -45072,7 +46191,7 @@ diff -urNp linux-3.0.9/fs/ocfs2/suballoc.c linux-3.0.9/fs/ocfs2/suballoc.c *suballoc_loc = res.sr_bg_blkno; *suballoc_bit_start = 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); @@ -45081,7 +46200,7 @@ diff -urNp linux-3.0.9/fs/ocfs2/suballoc.c linux-3.0.9/fs/ocfs2/suballoc.c BUG_ON(res->sr_bits != 1); -@@ -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; } @@ -45090,7 +46209,7 @@ diff -urNp linux-3.0.9/fs/ocfs2/suballoc.c linux-3.0.9/fs/ocfs2/suballoc.c BUG_ON(res.sr_bits != 1); -@@ -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) @@ -45099,7 +46218,7 @@ diff -urNp linux-3.0.9/fs/ocfs2/suballoc.c linux-3.0.9/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); @@ -45108,10 +46227,11 @@ diff -urNp linux-3.0.9/fs/ocfs2/suballoc.c linux-3.0.9/fs/ocfs2/suballoc.c *num_clusters = res.sr_bits; } } -diff -urNp linux-3.0.9/fs/ocfs2/super.c linux-3.0.9/fs/ocfs2/super.c ---- linux-3.0.9/fs/ocfs2/super.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ocfs2/super.c 2011-11-12 12:47:14.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 => GlobalAllocs: %d LocalAllocs: %d " "SubAllocs: %d LAWinMoves: %d SAExtends: %d\n", "Stats", @@ -45128,7 +46248,7 @@ diff -urNp linux-3.0.9/fs/ocfs2/super.c linux-3.0.9/fs/ocfs2/super.c out += snprintf(buf + out, len - out, "%10s => 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_block *sb, spin_lock_init(&osb->osb_xattr_lock); ocfs2_init_steal_slots(osb); @@ -45145,9 +46265,10 @@ diff -urNp linux-3.0.9/fs/ocfs2/super.c linux-3.0.9/fs/ocfs2/super.c /* Copy the blockcheck stats from the superblock probe */ osb->osb_ecc_stats = *stats; -diff -urNp linux-3.0.9/fs/ocfs2/symlink.c linux-3.0.9/fs/ocfs2/symlink.c ---- linux-3.0.9/fs/ocfs2/symlink.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/ocfs2/symlink.c 2011-11-12 12:47:14.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: static void ocfs2_fast_put_link(struct dentry *dentry, struct nameidata *nd, void *cookie) @@ -45157,10 +46278,11 @@ diff -urNp linux-3.0.9/fs/ocfs2/symlink.c linux-3.0.9/fs/ocfs2/symlink.c if (!IS_ERR(link)) kfree(link); } -diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c ---- linux-3.0.9/fs/open.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/open.c 2011-11-12 12:47:14.000000000 -0500 -@@ -112,6 +112,10 @@ static long do_sys_truncate(const char _ +diff --git a/fs/open.c b/fs/open.c +index b52cf01..b0a28a8 100644 +--- a/fs/open.c ++++ b/fs/open.c +@@ -112,6 +112,10 @@ static long do_sys_truncate(const char __user *pathname, loff_t length) error = locks_verify_truncate(inode, NULL, length); if (!error) error = security_path_truncate(&path); @@ -45171,7 +46293,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c if (!error) error = do_truncate(path.dentry, length, 0, NULL); -@@ -358,6 +362,9 @@ SYSCALL_DEFINE3(faccessat, int, dfd, con +@@ -358,6 +362,9 @@ SYSCALL_DEFINE3(faccessat, int, dfd, const char __user *, filename, int, mode) if (__mnt_is_readonly(path.mnt)) res = -EROFS; @@ -45181,7 +46303,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.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; @@ -45190,7 +46312,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c set_fs_pwd(current->fs, &path); 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; error = inode_permission(inode, MAY_EXEC | MAY_CHDIR); @@ -45204,7 +46326,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.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 *, filename) if (error) goto dput_and_out; @@ -45218,7 +46340,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c error = 0; dput_and_out: path_put(&path); -@@ -466,12 +488,25 @@ SYSCALL_DEFINE2(fchmod, unsigned int, fd +@@ -466,12 +488,25 @@ SYSCALL_DEFINE2(fchmod, unsigned int, fd, mode_t, mode) err = mnt_want_write_file(file); if (err) goto out_putf; @@ -45244,7 +46366,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c newattrs.ia_mode = (mode & S_IALLUGO) | (inode->i_mode & ~S_IALLUGO); newattrs.ia_valid = ATTR_MODE | ATTR_CTIME; err = notify_change(dentry, &newattrs); -@@ -499,12 +534,25 @@ SYSCALL_DEFINE3(fchmodat, int, dfd, cons +@@ -499,12 +534,25 @@ SYSCALL_DEFINE3(fchmodat, int, dfd, const char __user *, filename, mode_t, mode) error = mnt_want_write(path.mnt); if (error) goto dput_and_out; @@ -45270,7 +46392,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c newattrs.ia_mode = (mode & S_IALLUGO) | (inode->i_mode & ~S_IALLUGO); newattrs.ia_valid = ATTR_MODE | ATTR_CTIME; error = notify_change(path.dentry, &newattrs); -@@ -528,6 +576,9 @@ static int chown_common(struct path *pat +@@ -528,6 +576,9 @@ static int chown_common(struct path *path, uid_t user, gid_t group) int error; struct iattr newattrs; @@ -45280,7 +46402,7 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c newattrs.ia_valid = ATTR_CTIME; if (user != (uid_t) -1) { newattrs.ia_valid |= ATTR_UID; -@@ -998,7 +1049,10 @@ long do_sys_open(int dfd, const char __u +@@ -998,7 +1049,10 @@ long do_sys_open(int dfd, const char __user *filename, int flags, int mode) if (!IS_ERR(tmp)) { fd = get_unused_fd_flags(flags); if (fd >= 0) { @@ -45292,10 +46414,11 @@ diff -urNp linux-3.0.9/fs/open.c linux-3.0.9/fs/open.c if (IS_ERR(f)) { put_unused_fd(fd); fd = PTR_ERR(f); -diff -urNp linux-3.0.9/fs/partitions/ldm.c linux-3.0.9/fs/partitions/ldm.c ---- linux-3.0.9/fs/partitions/ldm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/partitions/ldm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 af9fdf0..6096bd6 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; } @@ -45303,7 +46426,7 @@ diff -urNp linux-3.0.9/fs/partitions/ldm.c linux-3.0.9/fs/partitions/ldm.c if (rec >= 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; } @@ -45312,9 +46435,10 @@ diff -urNp linux-3.0.9/fs/partitions/ldm.c linux-3.0.9/fs/partitions/ldm.c if (!f) { ldm_crit ("Out of memory."); return false; -diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c ---- linux-3.0.9/fs/pipe.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/pipe.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/pipe.c b/fs/pipe.c +index da42f7d..315f4e2 100644 +--- a/fs/pipe.c ++++ b/fs/pipe.c @@ -420,9 +420,9 @@ redo: } if (bufs) /* More to do? */ @@ -45327,7 +46451,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/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 -@@ -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 = inode->i_pipe; @@ -45357,7 +46481,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c } out: mutex_unlock(&inode->i_mutex); -@@ -685,7 +685,7 @@ pipe_poll(struct file *filp, poll_table +@@ -685,7 +685,7 @@ pipe_poll(struct file *filp, poll_table *wait) mask = 0; if (filp->f_mode & FMODE_READ) { mask = (nrbufs > 0) ? POLLIN | POLLRDNORM : 0; @@ -45366,7 +46490,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c mask |= POLLHUP; } -@@ -695,7 +695,7 @@ pipe_poll(struct file *filp, poll_table +@@ -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(). */ @@ -45375,7 +46499,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c mask |= POLLERR; } -@@ -709,10 +709,10 @@ pipe_release(struct inode *inode, int de +@@ -709,10 +709,10 @@ pipe_release(struct inode *inode, int decr, int decw) mutex_lock(&inode->i_mutex); pipe = inode->i_pipe; @@ -45389,7 +46513,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c free_pipe_info(inode); } else { wake_up_interruptible_sync_poll(&pipe->wait, POLLIN | POLLOUT | POLLRDNORM | 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 *filp) if (inode->i_pipe) { ret = 0; @@ -45398,7 +46522,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c } 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 *filp) if (inode->i_pipe) { ret = 0; @@ -45407,7 +46531,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c } 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 *filp) if (inode->i_pipe) { ret = 0; if (filp->f_mode & FMODE_READ) @@ -45428,7 +46552,7 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c /* * 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 = pipe; @@ -45438,9 +46562,41 @@ diff -urNp linux-3.0.9/fs/pipe.c linux-3.0.9/fs/pipe.c inode->i_fop = &rdwr_pipefifo_fops; /* -diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/fs/proc/array.c ---- linux-3.0.9/fs/proc/array.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/array.c 2011-11-12 12:47:14.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 + + config PROC_KCORE + bool "/proc/kcore support" if !ARM +- depends on PROC_FS && MMU ++ depends on PROC_FS && MMU && !GRKERNSEC_PROC_ADD + + 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. + +@@ -59,8 +59,8 @@ config PROC_SYSCTL + limited in memory. + + 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 9b45ee8..7389026 100644 +--- a/fs/proc/array.c ++++ b/fs/proc/array.c @@ -60,6 +60,7 @@ #include <linux/tty.h> #include <linux/string.h> @@ -45449,7 +46605,7 @@ diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/fs/proc/array.c #include <linux/proc_fs.h> #include <linux/ioport.h> #include <linux/uaccess.h> -@@ -337,6 +338,21 @@ static void task_cpus_allowed(struct seq +@@ -337,6 +338,21 @@ static void task_cpus_allowed(struct seq_file *m, struct task_struct *task) seq_putc(m, '\n'); } @@ -45471,7 +46627,7 @@ diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/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, +@@ -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); @@ -45496,7 +46652,7 @@ diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/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) { -@@ -375,9 +406,11 @@ static int do_task_stat(struct seq_file +@@ -375,9 +406,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 = 0; @@ -45509,7 +46665,7 @@ diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/fs/proc/array.c state = *get_task_state(task); vsize = eip = esp = 0; permitted = ptrace_may_access(task, PTRACE_MODE_READ); -@@ -449,6 +482,19 @@ static int do_task_stat(struct seq_file +@@ -449,6 +482,19 @@ static int do_task_stat(struct seq_file *m, struct pid_namespace *ns, gtime = task->gtime; } @@ -45529,7 +46685,7 @@ diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/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 = task_prio(task); -@@ -489,9 +535,15 @@ static int do_task_stat(struct seq_file +@@ -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, @@ -45545,7 +46701,7 @@ diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/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_namespace *ns, return 0; } @@ -45564,9 +46720,10 @@ diff -urNp linux-3.0.9/fs/proc/array.c linux-3.0.9/fs/proc/array.c + return sprintf(buffer, "%pI4\n", &curr_ip); +} +#endif -diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c ---- linux-3.0.9/fs/proc/base.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/base.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/proc/base.c b/fs/proc/base.c +index f039017..9d2507b 100644 +--- a/fs/proc/base.c ++++ b/fs/proc/base.c @@ -107,6 +107,22 @@ struct pid_entry { union proc_op op; }; @@ -45590,7 +46747,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c #define NOD(NAME, MODE, IOP, FOP, OP) { \ .name = (NAME), \ .len = 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(struct task_struct *task) if (task == current) return mm; @@ -45600,7 +46757,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/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 */ @@ -45639,7 +46796,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c do { nwords += 2; } while (mm->saved_auxv[nwords - 2] != 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, char *buffer) } @@ -45648,7 +46805,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c /* * Provides a wchan file via kallsyms in a proper one-value-per-file format. * Returns the resolved symbol. If that fails, simply return the address. -@@ -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); } @@ -45657,7 +46814,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c #define MAX_STACK_TRACE_DEPTH 64 -@@ -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; } @@ -45666,7 +46823,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/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) /************************************************************************/ /* permission checks */ @@ -45675,7 +46832,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c { struct task_struct *task; int allowed = 0; -@@ -597,7 +635,10 @@ static int proc_fd_access_allowed(struct +@@ -597,7 +635,10 @@ static int proc_fd_access_allowed(struct inode *inode) */ task = get_proc_task(inode); if (task) { @@ -45687,7 +46844,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c put_task_struct(task); } return allowed; -@@ -978,6 +1019,9 @@ static ssize_t environ_read(struct file +@@ -978,6 +1019,9 @@ static ssize_t environ_read(struct file *file, char __user *buf, if (!task) goto out_no_task; @@ -45697,7 +46854,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c ret = -ENOMEM; page = (char *)__get_free_page(GFP_TEMPORARY); if (!page) -@@ -1614,7 +1658,7 @@ static void *proc_pid_follow_link(struct +@@ -1614,7 +1658,7 @@ static void *proc_pid_follow_link(struct dentry *dentry, struct nameidata *nd) path_put(&nd->path); /* Are we allowed to snoop on the tasks file descriptors? */ @@ -45706,7 +46863,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c goto out; error = PROC_I(inode)->op.proc_get_link(inode, &nd->path); -@@ -1653,8 +1697,18 @@ static int proc_pid_readlink(struct dent +@@ -1653,8 +1697,18 @@ static int proc_pid_readlink(struct dentry * dentry, char __user * buffer, int b struct path path; /* Are we allowed to snoop on the tasks file descriptors? */ @@ -45727,7 +46884,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c error = PROC_I(inode)->op.proc_get_link(inode, &path); if (error) -@@ -1719,7 +1773,11 @@ struct inode *proc_pid_make_inode(struct +@@ -1719,7 +1773,11 @@ struct inode *proc_pid_make_inode(struct super_block * sb, struct task_struct *t rcu_read_lock(); cred = __task_cred(task); inode->i_uid = cred->euid; @@ -45739,7 +46896,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c rcu_read_unlock(); } security_task_to_inode(task, inode); -@@ -1737,6 +1795,9 @@ int pid_getattr(struct vfsmount *mnt, st +@@ -1737,6 +1795,9 @@ int pid_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat) struct inode *inode = dentry->d_inode; struct task_struct *task; const struct cred *cred; @@ -45749,7 +46906,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c generic_fillattr(inode, stat); -@@ -1744,13 +1805,41 @@ int pid_getattr(struct vfsmount *mnt, st +@@ -1744,13 +1805,41 @@ int pid_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat) stat->uid = 0; stat->gid = 0; task = pid_task(proc_pid(inode), PIDTYPE_PID); @@ -45792,7 +46949,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c } rcu_read_unlock(); return 0; -@@ -1787,11 +1876,20 @@ int pid_revalidate(struct dentry *dentry +@@ -1787,11 +1876,20 @@ int pid_revalidate(struct dentry *dentry, struct nameidata *nd) if (task) { if ((inode->i_mode == (S_IFDIR|S_IRUGO|S_IXUGO)) || @@ -45813,7 +46970,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c rcu_read_unlock(); } else { inode->i_uid = 0; -@@ -1909,7 +2007,8 @@ static int proc_fd_info(struct inode *in +@@ -1909,7 +2007,8 @@ static int proc_fd_info(struct inode *inode, struct path *path, char *info) int fd = proc_fd(inode); if (task) { @@ -45823,7 +46980,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c put_task_struct(task); } if (files) { -@@ -2177,11 +2276,21 @@ static const struct file_operations proc +@@ -2177,11 +2276,21 @@ static const struct file_operations proc_fd_operations = { */ static int proc_fd_permission(struct inode *inode, int mask, unsigned int flags) { @@ -45847,7 +47004,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c return rv; } -@@ -2291,6 +2400,9 @@ static struct dentry *proc_pident_lookup +@@ -2291,6 +2400,9 @@ static struct dentry *proc_pident_lookup(struct inode *dir, if (!task) goto out_no_task; @@ -45857,7 +47014,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c /* * Yes, it does not scale. And it should not. Don't add * new entries into /proc/<tgid>/ without very good reasons. -@@ -2335,6 +2447,9 @@ static int proc_pident_readdir(struct fi +@@ -2335,6 +2447,9 @@ static int proc_pident_readdir(struct file *filp, if (!task) goto out_no_task; @@ -45867,7 +47024,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c ret = 0; i = filp->f_pos; switch (i) { -@@ -2605,7 +2720,7 @@ static void *proc_self_follow_link(struc +@@ -2605,7 +2720,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) { @@ -45876,7 +47033,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c if (!IS_ERR(s)) __putname(s); } -@@ -2664,6 +2779,7 @@ static struct dentry *proc_base_instanti +@@ -2664,6 +2779,7 @@ static struct dentry *proc_base_instantiate(struct inode *dir, if (p->fop) inode->i_fop = p->fop; ei->op = p->op; @@ -45884,7 +47041,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c d_add(dentry, inode); error = NULL; out: -@@ -2803,7 +2919,7 @@ static const struct pid_entry tgid_base_ +@@ -2803,7 +2919,7 @@ static const struct pid_entry tgid_base_stuff[] = { REG("autogroup", S_IRUGO|S_IWUSR, proc_pid_sched_autogroup_operations), #endif REG("comm", S_IRUGO|S_IWUSR, proc_pid_set_comm_operations), @@ -45893,7 +47050,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c INF("syscall", S_IRUGO, proc_pid_syscall), #endif INF("cmdline", S_IRUGO, proc_pid_cmdline), -@@ -2828,10 +2944,10 @@ static const struct pid_entry tgid_base_ +@@ -2828,10 +2944,10 @@ static const struct pid_entry tgid_base_stuff[] = { #ifdef CONFIG_SECURITY DIR("attr", S_IRUGO|S_IXUGO, proc_attr_dir_inode_operations, proc_attr_dir_operations), #endif @@ -45906,7 +47063,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c ONE("stack", S_IRUGO, proc_pid_stack), #endif #ifdef CONFIG_SCHEDSTATS -@@ -2865,6 +2981,9 @@ static const struct pid_entry tgid_base_ +@@ -2865,6 +2981,9 @@ static const struct pid_entry tgid_base_stuff[] = { #ifdef CONFIG_HARDWALL INF("hardwall", S_IRUGO, proc_pid_hardwall), #endif @@ -45916,7 +47073,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c }; static int proc_tgid_base_readdir(struct file * filp, -@@ -2990,7 +3109,14 @@ static struct dentry *proc_pid_instantia +@@ -2990,7 +3109,14 @@ static struct dentry *proc_pid_instantiate(struct inode *dir, if (!inode) goto out; @@ -45931,7 +47088,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c inode->i_op = &proc_tgid_base_inode_operations; inode->i_fop = &proc_tgid_base_operations; inode->i_flags|=S_IMMUTABLE; -@@ -3032,7 +3158,14 @@ struct dentry *proc_pid_lookup(struct in +@@ -3032,7 +3158,14 @@ struct dentry *proc_pid_lookup(struct inode *dir, struct dentry * dentry, struct if (!task) goto out; @@ -45946,7 +47103,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c put_task_struct(task); out: return result; -@@ -3097,6 +3230,11 @@ int proc_pid_readdir(struct file * filp, +@@ -3097,6 +3230,11 @@ int proc_pid_readdir(struct file * filp, void * dirent, filldir_t filldir) { unsigned int nr; struct task_struct *reaper; @@ -45958,7 +47115,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c struct tgid_iter iter; struct pid_namespace *ns; -@@ -3120,8 +3258,27 @@ int proc_pid_readdir(struct file * filp, +@@ -3120,8 +3258,27 @@ int proc_pid_readdir(struct file * filp, void * dirent, filldir_t filldir) for (iter = next_tgid(ns, iter); iter.task; iter.tgid += 1, iter = next_tgid(ns, iter)) { @@ -45987,7 +47144,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c put_task_struct(iter.task); goto out; } -@@ -3149,7 +3306,7 @@ static const struct pid_entry tid_base_s +@@ -3149,7 +3306,7 @@ static const struct pid_entry tid_base_stuff[] = { REG("sched", S_IRUGO|S_IWUSR, proc_pid_sched_operations), #endif REG("comm", S_IRUGO|S_IWUSR, proc_pid_set_comm_operations), @@ -45996,7 +47153,7 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c INF("syscall", S_IRUGO, proc_pid_syscall), #endif INF("cmdline", S_IRUGO, proc_pid_cmdline), -@@ -3173,10 +3330,10 @@ static const struct pid_entry tid_base_s +@@ -3173,10 +3330,10 @@ static const struct pid_entry tid_base_stuff[] = { #ifdef CONFIG_SECURITY DIR("attr", S_IRUGO|S_IXUGO, proc_attr_dir_inode_operations, proc_attr_dir_operations), #endif @@ -46009,10 +47166,11 @@ diff -urNp linux-3.0.9/fs/proc/base.c linux-3.0.9/fs/proc/base.c ONE("stack", S_IRUGO, proc_pid_stack), #endif #ifdef CONFIG_SCHEDSTATS -diff -urNp linux-3.0.9/fs/proc/cmdline.c linux-3.0.9/fs/proc/cmdline.c ---- linux-3.0.9/fs/proc/cmdline.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/cmdline.c 2011-11-12 12:47:14.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 = { static int __init proc_cmdline_init(void) { @@ -46024,10 +47182,11 @@ diff -urNp linux-3.0.9/fs/proc/cmdline.c linux-3.0.9/fs/proc/cmdline.c return 0; } module_init(proc_cmdline_init); -diff -urNp linux-3.0.9/fs/proc/devices.c linux-3.0.9/fs/proc/devices.c ---- linux-3.0.9/fs/proc/devices.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/devices.c 2011-11-12 12:47:14.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_operations = { static int __init proc_devices_init(void) { @@ -46039,9 +47198,10 @@ diff -urNp linux-3.0.9/fs/proc/devices.c linux-3.0.9/fs/proc/devices.c return 0; } module_init(proc_devices_init); -diff -urNp linux-3.0.9/fs/proc/inode.c linux-3.0.9/fs/proc/inode.c ---- linux-3.0.9/fs/proc/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/inode.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/proc/inode.c b/fs/proc/inode.c +index 74b48cf..6542979 100644 +--- a/fs/proc/inode.c ++++ b/fs/proc/inode.c @@ -18,12 +18,18 @@ #include <linux/module.h> #include <linux/sysctl.h> @@ -46061,7 +47221,7 @@ diff -urNp linux-3.0.9/fs/proc/inode.c linux-3.0.9/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 = PROC_I(inode)->ns_ops; if (ns_ops && ns_ops->put) ns_ops->put(PROC_I(inode)->ns); @@ -46075,7 +47235,7 @@ diff -urNp linux-3.0.9/fs/proc/inode.c linux-3.0.9/fs/proc/inode.c } 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 = de->mode; inode->i_uid = de->uid; @@ -46087,10 +47247,11 @@ diff -urNp linux-3.0.9/fs/proc/inode.c linux-3.0.9/fs/proc/inode.c } if (de->size) inode->i_size = de->size; -diff -urNp linux-3.0.9/fs/proc/internal.h linux-3.0.9/fs/proc/internal.h ---- linux-3.0.9/fs/proc/internal.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/internal.h 2011-11-12 12:47:14.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); @@ -46100,40 +47261,11 @@ diff -urNp linux-3.0.9/fs/proc/internal.h linux-3.0.9/fs/proc/internal.h extern loff_t mem_lseek(struct file *file, loff_t offset, int orig); extern const struct file_operations proc_maps_operations; -diff -urNp linux-3.0.9/fs/proc/Kconfig linux-3.0.9/fs/proc/Kconfig ---- linux-3.0.9/fs/proc/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/Kconfig 2011-11-12 12:47:14.000000000 -0500 -@@ -30,12 +30,12 @@ config PROC_FS - - config PROC_KCORE - bool "/proc/kcore support" if !ARM -- depends on PROC_FS && MMU -+ depends on PROC_FS && MMU && !GRKERNSEC_PROC_ADD - - 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. - -@@ -59,8 +59,8 @@ config PROC_SYSCTL - limited in memory. - - 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.0.9/fs/proc/kcore.c linux-3.0.9/fs/proc/kcore.c ---- linux-3.0.9/fs/proc/kcore.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/kcore.c 2011-11-12 12:47:14.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 nphdr, int dataoff) off_t offset = 0; struct kcore_list *m; @@ -46142,7 +47274,7 @@ diff -urNp linux-3.0.9/fs/proc/kcore.c linux-3.0.9/fs/proc/kcore.c /* setup ELF header */ elf = (struct elfhdr *) bufp; bufp += 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 = kc_offset_to_vaddr(*fpos - elf_buflen); @@ -46155,14 +47287,12 @@ diff -urNp linux-3.0.9/fs/proc/kcore.c linux-3.0.9/fs/proc/kcore.c while (buflen) { struct kcore_list *m; -@@ -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; - +- - n = copy_to_user(buffer, (char *)start, tsz); - /* - * We cannot distingush between fault on source @@ -46173,6 +47303,9 @@ diff -urNp linux-3.0.9/fs/proc/kcore.c linux-3.0.9/fs/proc/kcore.c - if (n) { - if (clear_user(buffer + tsz - n, - n)) ++ char *elf_buf; ++ mm_segment_t oldfs; ++ + elf_buf = kmalloc(tsz, GFP_KERNEL); + if (!elf_buf) + return -ENOMEM; @@ -46190,7 +47323,7 @@ diff -urNp linux-3.0.9/fs/proc/kcore.c linux-3.0.9/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, size_t buflen, loff_t *fpos) static int open_kcore(struct inode *inode, struct file *filp) { @@ -46200,10 +47333,11 @@ diff -urNp linux-3.0.9/fs/proc/kcore.c linux-3.0.9/fs/proc/kcore.c if (!capable(CAP_SYS_RAWIO)) return -EPERM; if (kcore_need_update) -diff -urNp linux-3.0.9/fs/proc/meminfo.c linux-3.0.9/fs/proc/meminfo.c ---- linux-3.0.9/fs/proc/meminfo.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/meminfo.c 2011-11-12 12:47:14.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 ed257d1..dda1954 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; @@ -46212,7 +47346,7 @@ diff -urNp linux-3.0.9/fs/proc/meminfo.c linux-3.0.9/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, void *v) vmi.used >> 10, vmi.largest_chunk >> 10 #ifdef CONFIG_MEMORY_FAILURE @@ -46221,10 +47355,11 @@ diff -urNp linux-3.0.9/fs/proc/meminfo.c linux-3.0.9/fs/proc/meminfo.c #endif #ifdef CONFIG_TRANSPARENT_HUGEPAGE ,K(global_page_state(NR_ANON_TRANSPARENT_HUGEPAGES) * -diff -urNp linux-3.0.9/fs/proc/nommu.c linux-3.0.9/fs/proc/nommu.c ---- linux-3.0.9/fs/proc/nommu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/nommu.c 2011-11-12 12:47:14.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, struct vm_region *region) if (len < 1) len = 1; seq_printf(m, "%*c", len, ' '); @@ -46233,10 +47368,11 @@ diff -urNp linux-3.0.9/fs/proc/nommu.c linux-3.0.9/fs/proc/nommu.c } seq_putc(m, '\n'); -diff -urNp linux-3.0.9/fs/proc/proc_net.c linux-3.0.9/fs/proc/proc_net.c ---- linux-3.0.9/fs/proc/proc_net.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/proc_net.c 2011-11-12 12:47:14.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 9020ac1..15a7335 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 = NULL; @@ -46254,9 +47390,10 @@ diff -urNp linux-3.0.9/fs/proc/proc_net.c linux-3.0.9/fs/proc/proc_net.c rcu_read_lock(); task = pid_task(proc_pid(dir), PIDTYPE_PID); -diff -urNp linux-3.0.9/fs/proc/proc_sysctl.c linux-3.0.9/fs/proc/proc_sysctl.c ---- linux-3.0.9/fs/proc/proc_sysctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/proc_sysctl.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/proc/proc_sysctl.c b/fs/proc/proc_sysctl.c +index d167de3..0ede166 100644 +--- a/fs/proc/proc_sysctl.c ++++ b/fs/proc/proc_sysctl.c @@ -8,11 +8,13 @@ #include <linux/namei.h> #include "internal.h" @@ -46273,7 +47410,7 @@ diff -urNp linux-3.0.9/fs/proc/proc_sysctl.c linux-3.0.9/fs/proc/proc_sysctl.c 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, err = NULL; d_set_d_op(dentry, &proc_sys_dentry_operations); @@ -46288,7 +47425,7 @@ diff -urNp linux-3.0.9/fs/proc/proc_sysctl.c linux-3.0.9/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, void *dirent, return -ENOMEM; } else { d_set_d_op(child, &proc_sys_dentry_operations); @@ -46298,7 +47435,7 @@ diff -urNp linux-3.0.9/fs/proc/proc_sysctl.c linux-3.0.9/fs/proc/proc_sysctl.c d_add(child, inode); } } else { -@@ -230,6 +241,9 @@ static int scan(struct ctl_table_header +@@ -230,6 +241,9 @@ static int scan(struct ctl_table_header *head, ctl_table *table, if (*pos < file->f_pos) continue; @@ -46308,7 +47445,7 @@ diff -urNp linux-3.0.9/fs/proc/proc_sysctl.c linux-3.0.9/fs/proc/proc_sysctl.c res = 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, struct dentry *dentry, struct if (IS_ERR(head)) return PTR_ERR(head); @@ -46318,7 +47455,7 @@ diff -urNp linux-3.0.9/fs/proc/proc_sysctl.c linux-3.0.9/fs/proc/proc_sysctl.c generic_fillattr(inode, stat); if (table) stat->mode = (stat->mode & S_IFMT) | table->mode; -@@ -374,13 +391,13 @@ static const struct file_operations proc +@@ -374,13 +391,13 @@ static const struct file_operations proc_sys_dir_file_operations = { .llseek = generic_file_llseek, }; @@ -46334,9 +47471,10 @@ diff -urNp linux-3.0.9/fs/proc/proc_sysctl.c linux-3.0.9/fs/proc/proc_sysctl.c .lookup = proc_sys_lookup, .permission = proc_sys_permission, .setattr = proc_sys_setattr, -diff -urNp linux-3.0.9/fs/proc/root.c linux-3.0.9/fs/proc/root.c ---- linux-3.0.9/fs/proc/root.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/root.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/proc/root.c b/fs/proc/root.c +index d6c3b41..539f3bf 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(); @@ -46353,10 +47491,11 @@ diff -urNp linux-3.0.9/fs/proc/root.c linux-3.0.9/fs/proc/root.c proc_sys_init(); } -diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c ---- linux-3.0.9/fs/proc/task_mmu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/task_mmu.c 2011-11-12 12:47:14.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 *mm) "VmExe:\t%8lu kB\n" "VmLib:\t%8lu kB\n" "VmPTE:\t%8lu kB\n" @@ -46372,7 +47511,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/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 *mm) data << (PAGE_SHIFT-10), mm->stack_vm << (PAGE_SHIFT-10), text, lib, (PTRS_PER_PTE*sizeof(pte_t)*mm->nr_ptes) >> 10, @@ -46387,7 +47526,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c } 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; } @@ -46400,7 +47539,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c static void show_map_vma(struct seq_file *m, struct vm_area_struct *vma) { struct mm_struct *mm = 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, struct vm_area_struct *vma) pgoff = ((loff_t)vma->vm_pgoff) << PAGE_SHIFT; } @@ -46419,7 +47558,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c 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', @@ -46431,7 +47570,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c MAJOR(dev), MINOR(dev), ino, &len); /* -@@ -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); @@ -46440,7 +47579,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c } else { const char *name = 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 <= mm->brk && vma->vm_end >= mm->start_brk) { name = "[heap]"; @@ -46452,7 +47591,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c name = "[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) }; memset(&mss, 0, sizeof mss); @@ -46474,7 +47613,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c show_map_vma(m, vma); 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", @@ -46486,7 +47625,7 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/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) if (file) { seq_printf(m, " file="); @@ -46495,10 +47634,11 @@ diff -urNp linux-3.0.9/fs/proc/task_mmu.c linux-3.0.9/fs/proc/task_mmu.c } else if (vma->vm_start <= mm->brk && vma->vm_end >= mm->start_brk) { seq_printf(m, " heap"); } else if (vma->vm_start <= mm->start_stack && -diff -urNp linux-3.0.9/fs/proc/task_nommu.c linux-3.0.9/fs/proc/task_nommu.c ---- linux-3.0.9/fs/proc/task_nommu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/proc/task_nommu.c 2011-11-12 12:47:14.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 += kobjsize(mm); @@ -46507,7 +47647,7 @@ diff -urNp linux-3.0.9/fs/proc/task_nommu.c linux-3.0.9/fs/proc/task_nommu.c sbytes += kobjsize(current->fs); else bytes += 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) if (file) { pad_len_spaces(m, len); @@ -46516,10 +47656,11 @@ diff -urNp linux-3.0.9/fs/proc/task_nommu.c linux-3.0.9/fs/proc/task_nommu.c } else if (mm) { if (vma->vm_start <= mm->start_stack && vma->vm_end >= mm->start_stack) { -diff -urNp linux-3.0.9/fs/quota/netlink.c linux-3.0.9/fs/quota/netlink.c ---- linux-3.0.9/fs/quota/netlink.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/quota/netlink.c 2011-11-12 12:47:14.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 = { void quota_send_warning(short type, unsigned int id, dev_t dev, const char warntype) { @@ -46528,7 +47669,7 @@ diff -urNp linux-3.0.9/fs/quota/netlink.c linux-3.0.9/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, dev_t dev, "VFS: Not enough memory to send quota warning.\n"); return; } @@ -46537,9 +47678,10 @@ diff -urNp linux-3.0.9/fs/quota/netlink.c linux-3.0.9/fs/quota/netlink.c "a_genl_family, 0, QUOTA_NL_C_WARNING); if (!msg_head) { printk(KERN_ERR -diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/readdir.c ---- linux-3.0.9/fs/readdir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/readdir.c 2011-11-12 12:47:14.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 <linux/security.h> #include <linux/syscalls.h> @@ -46556,7 +47698,7 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/readdir.c int result; }; -@@ -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 = -EOVERFLOW; return -EOVERFLOW; } @@ -46567,7 +47709,7 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/readdir.c buf->result++; dirent = 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, buf.result = 0; buf.dirent = dirent; @@ -46583,7 +47725,7 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/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 = -EOVERFLOW; return -EOVERFLOW; } @@ -46594,7 +47736,7 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/readdir.c dirent = buf->previous; if (dirent) { if (__put_user(offset, &dirent->d_off)) -@@ -210,6 +222,7 @@ SYSCALL_DEFINE3(getdents, unsigned int, +@@ -210,6 +222,7 @@ SYSCALL_DEFINE3(getdents, unsigned int, fd, buf.previous = NULL; buf.count = count; buf.error = 0; @@ -46610,7 +47752,7 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/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 * name, int namlen, loff_t offset, buf->error = -EINVAL; /* only used if we fail.. */ if (reclen > buf->count) return -EINVAL; @@ -46621,7 +47763,7 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/readdir.c dirent = 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, buf.current_dir = dirent; buf.previous = NULL; @@ -46629,7 +47771,7 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/readdir.c buf.count = count; buf.error = 0; -@@ -299,7 +318,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int +@@ -299,7 +318,7 @@ SYSCALL_DEFINE3(getdents64, unsigned int, fd, error = buf.error; lastdirent = buf.previous; if (lastdirent) { @@ -46638,10 +47780,11 @@ diff -urNp linux-3.0.9/fs/readdir.c linux-3.0.9/fs/readdir.c if (__put_user(d_off, &lastdirent->d_off)) error = -EFAULT; else -diff -urNp linux-3.0.9/fs/reiserfs/dir.c linux-3.0.9/fs/reiserfs/dir.c ---- linux-3.0.9/fs/reiserfs/dir.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/reiserfs/dir.c 2011-11-12 12:47:14.000000000 -0500 -@@ -66,6 +66,8 @@ int reiserfs_readdir_dentry(struct dentr +diff --git a/fs/reiserfs/dir.c b/fs/reiserfs/dir.c +index 198dabf..94f661b 100644 +--- a/fs/reiserfs/dir.c ++++ b/fs/reiserfs/dir.c +@@ -66,6 +66,8 @@ int reiserfs_readdir_dentry(struct dentry *dentry, void *dirent, struct reiserfs_dir_entry de; int ret = 0; @@ -46650,10 +47793,11 @@ diff -urNp linux-3.0.9/fs/reiserfs/dir.c linux-3.0.9/fs/reiserfs/dir.c reiserfs_write_lock(inode->i_sb); reiserfs_check_lock_depth(inode->i_sb, "readdir"); -diff -urNp linux-3.0.9/fs/reiserfs/do_balan.c linux-3.0.9/fs/reiserfs/do_balan.c ---- linux-3.0.9/fs/reiserfs/do_balan.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/reiserfs/do_balan.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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_balance structure */ return; } @@ -46662,10 +47806,11 @@ diff -urNp linux-3.0.9/fs/reiserfs/do_balan.c linux-3.0.9/fs/reiserfs/do_balan.c do_balance_starts(tb); /* balance leaf returns 0 except if combining L R and S into -diff -urNp linux-3.0.9/fs/reiserfs/journal.c linux-3.0.9/fs/reiserfs/journal.c ---- linux-3.0.9/fs/reiserfs/journal.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/reiserfs/journal.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2299,6 +2299,8 @@ static struct buffer_head *reiserfs_brea +diff --git a/fs/reiserfs/journal.c b/fs/reiserfs/journal.c +index c5e82ec..1b37b0c 100644 +--- a/fs/reiserfs/journal.c ++++ b/fs/reiserfs/journal.c +@@ -2299,6 +2299,8 @@ static struct buffer_head *reiserfs_breada(struct block_device *dev, struct buffer_head *bh; int i, j; @@ -46674,10 +47819,11 @@ diff -urNp linux-3.0.9/fs/reiserfs/journal.c linux-3.0.9/fs/reiserfs/journal.c bh = __getblk(dev, block, bufsize); if (buffer_uptodate(bh)) return (bh); -diff -urNp linux-3.0.9/fs/reiserfs/namei.c linux-3.0.9/fs/reiserfs/namei.c ---- linux-3.0.9/fs/reiserfs/namei.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/reiserfs/namei.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1225,6 +1225,8 @@ static int reiserfs_rename(struct inode +diff --git a/fs/reiserfs/namei.c b/fs/reiserfs/namei.c +index 1186626..6a281dc 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 = 1; struct timespec ctime; @@ -46686,10 +47832,11 @@ diff -urNp linux-3.0.9/fs/reiserfs/namei.c linux-3.0.9/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.0.9/fs/reiserfs/procfs.c linux-3.0.9/fs/reiserfs/procfs.c ---- linux-3.0.9/fs/reiserfs/procfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/reiserfs/procfs.c 2011-11-12 12:47:14.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 super_block *sb) "SMALL_TAILS " : "NO_TAILS ", replay_only(sb) ? "REPLAY_ONLY " : "", convert_reiserfs(sb) ? "CONV " : "", @@ -46698,7 +47845,7 @@ diff -urNp linux-3.0.9/fs/reiserfs/procfs.c linux-3.0.9/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 +@@ -299,6 +299,8 @@ static int show_journal(struct seq_file *m, struct super_block *sb) struct journal_params *jp = &rs->s_v1.s_journal; char b[BDEVNAME_SIZE]; @@ -46707,10 +47854,11 @@ diff -urNp linux-3.0.9/fs/reiserfs/procfs.c linux-3.0.9/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.0.9/fs/reiserfs/stree.c linux-3.0.9/fs/reiserfs/stree.c ---- linux-3.0.9/fs/reiserfs/stree.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/reiserfs/stree.c 2011-11-12 12:47:14.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_transaction_handle *th, int iter = 0; #endif @@ -46719,7 +47867,7 @@ diff -urNp linux-3.0.9/fs/reiserfs/stree.c linux-3.0.9/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); 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_transaction_handle *th, int retval; int quota_cut_bytes = 0; @@ -46728,7 +47876,7 @@ diff -urNp linux-3.0.9/fs/reiserfs/stree.c linux-3.0.9/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); 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_transaction_handle *th, int quota_cut_bytes; loff_t tail_pos = 0; @@ -46737,7 +47885,7 @@ diff -urNp linux-3.0.9/fs/reiserfs/stree.c linux-3.0.9/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); 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_transaction_handle *th, struct tree int retval; int fs_gen; @@ -46746,7 +47894,7 @@ diff -urNp linux-3.0.9/fs/reiserfs/stree.c linux-3.0.9/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); fs_gen = 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_transaction_handle *th, int fs_gen = 0; int quota_bytes = 0; @@ -46755,10 +47903,11 @@ diff -urNp linux-3.0.9/fs/reiserfs/stree.c linux-3.0.9/fs/reiserfs/stree.c BUG_ON(!th->t_trans_id); if (inode) { /* Do we count quotas for item? */ -diff -urNp linux-3.0.9/fs/reiserfs/super.c linux-3.0.9/fs/reiserfs/super.c ---- linux-3.0.9/fs/reiserfs/super.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/reiserfs/super.c 2011-11-12 12:47:14.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 aa91089..c321513 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 = NULL} }; @@ -46767,9 +47916,10 @@ diff -urNp linux-3.0.9/fs/reiserfs/super.c linux-3.0.9/fs/reiserfs/super.c *blocks = 0; if (!options || !*options) /* use default configuration: create tails, journaling on, no -diff -urNp linux-3.0.9/fs/select.c linux-3.0.9/fs/select.c ---- linux-3.0.9/fs/select.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/select.c 2011-11-12 12:47:14.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 <linux/module.h> #include <linux/slab.h> @@ -46778,7 +47928,7 @@ diff -urNp linux-3.0.9/fs/select.c linux-3.0.9/fs/select.c #include <linux/personality.h> /* for STICKY_TIMEOUTS */ #include <linux/file.h> #include <linux/fdtable.h> -@@ -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 timespec *end_time) int retval, i, timed_out = 0; unsigned long slack = 0; @@ -46787,7 +47937,7 @@ diff -urNp linux-3.0.9/fs/select.c linux-3.0.9/fs/select.c rcu_read_lock(); retval = 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_set __user *outp, /* Allocate small arguments on the stack to save memory and be faster */ long stack_fds[SELECT_STACK_ALLOC/sizeof(long)]; @@ -46796,7 +47946,7 @@ diff -urNp linux-3.0.9/fs/select.c linux-3.0.9/fs/select.c ret = -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 = head; unsigned long todo = nfds; @@ -46806,10 +47956,11 @@ diff -urNp linux-3.0.9/fs/select.c linux-3.0.9/fs/select.c if (nfds > rlimit(RLIMIT_NOFILE)) return -EINVAL; -diff -urNp linux-3.0.9/fs/seq_file.c linux-3.0.9/fs/seq_file.c ---- linux-3.0.9/fs/seq_file.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/seq_file.c 2011-11-12 12:47:14.000000000 -0500 -@@ -76,7 +76,8 @@ static int traverse(struct seq_file *m, +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) { @@ -46819,7 +47970,7 @@ diff -urNp linux-3.0.9/fs/seq_file.c linux-3.0.9/fs/seq_file.c if (!m->buf) return -ENOMEM; } -@@ -116,7 +117,8 @@ static int traverse(struct seq_file *m, +@@ -116,7 +117,8 @@ static int traverse(struct seq_file *m, loff_t offset) Eoverflow: m->op->stop(m, p); kfree(m->buf); @@ -46829,7 +47980,7 @@ diff -urNp linux-3.0.9/fs/seq_file.c linux-3.0.9/fs/seq_file.c return !m->buf ? -ENOMEM : -EAGAIN; } -@@ -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 = file->f_version; /* grab buffer if we didn't have one */ if (!m->buf) { @@ -46839,7 +47990,7 @@ diff -urNp linux-3.0.9/fs/seq_file.c linux-3.0.9/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); @@ -46849,7 +48000,7 @@ diff -urNp linux-3.0.9/fs/seq_file.c linux-3.0.9/fs/seq_file.c if (!m->buf) goto Enomem; m->count = 0; -@@ -549,7 +553,7 @@ static void single_stop(struct seq_file +@@ -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) { @@ -46858,10 +48009,11 @@ diff -urNp linux-3.0.9/fs/seq_file.c linux-3.0.9/fs/seq_file.c int res = -ENOMEM; if (op) { -diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c ---- linux-3.0.9/fs/splice.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/splice.c 2011-11-12 12:47:14.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 aa866d3..757e92d 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); for (;;) { @@ -46870,7 +48022,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c send_sig(SIGPIPE, current, 0); if (!ret) ret = -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 = 0; } @@ -46882,7 +48034,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c } 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 = spd_release_page, }; @@ -46891,7 +48043,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; -@@ -560,7 +562,7 @@ static ssize_t kernel_readv(struct file +@@ -560,7 +562,7 @@ static ssize_t kernel_readv(struct file *file, const struct iovec *vec, old_fs = get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -46900,7 +48052,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c set_fs(old_fs); return res; -@@ -575,7 +577,7 @@ static ssize_t kernel_write(struct file +@@ -575,7 +577,7 @@ static ssize_t kernel_write(struct file *file, const char *buf, size_t count, old_fs = get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -46909,7 +48061,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c set_fs(old_fs); return res; -@@ -603,6 +605,8 @@ ssize_t default_file_splice_read(struct +@@ -603,6 +605,8 @@ ssize_t default_file_splice_read(struct file *in, loff_t *ppos, .spd_release = spd_release_page, }; @@ -46918,7 +48070,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; -@@ -626,7 +630,7 @@ ssize_t default_file_splice_read(struct +@@ -626,7 +630,7 @@ ssize_t default_file_splice_read(struct file *in, loff_t *ppos, goto err; this_len = min_t(size_t, len, PAGE_CACHE_SIZE - offset); @@ -46940,7 +48092,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c return 0; 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, struct splice_desc *sd, * out of the pipe right after the splice_to_pipe(). So set * PIPE_READERS appropriately. */ @@ -46949,7 +48101,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c current->splice_pipe = pipe; } -@@ -1619,6 +1623,8 @@ static long vmsplice_to_pipe(struct file +@@ -1619,6 +1623,8 @@ static long vmsplice_to_pipe(struct file *file, const struct iovec __user *iov, }; long ret; @@ -46958,7 +48110,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c pipe = 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 = -ERESTARTSYS; break; } @@ -46970,7 +48122,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c if (flags & SPLICE_F_NONBLOCK) { ret = -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); while (pipe->nrbufs >= pipe->buffers) { @@ -46979,7 +48131,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c send_sig(SIGPIPE, current, 0); ret = -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 = -ERESTARTSYS; break; } @@ -47008,7 +48160,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c break; /* -@@ -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); do { @@ -47017,7 +48169,7 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c send_sig(SIGPIPE, current, 0); if (!ret) ret = -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 */ @@ -47026,10 +48178,11 @@ diff -urNp linux-3.0.9/fs/splice.c linux-3.0.9/fs/splice.c ret = -EAGAIN; pipe_unlock(ipipe); -diff -urNp linux-3.0.9/fs/sysfs/file.c linux-3.0.9/fs/sysfs/file.c ---- linux-3.0.9/fs/sysfs/file.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/sysfs/file.c 2011-11-12 12:47:14.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); struct sysfs_open_dirent { atomic_t refcnt; @@ -47038,7 +48191,7 @@ diff -urNp linux-3.0.9/fs/sysfs/file.c linux-3.0.9/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, struct sysfs_buffer * buffer if (!sysfs_get_active(attr_sd)) return -ENODEV; @@ -47047,7 +48200,7 @@ diff -urNp linux-3.0.9/fs/sysfs/file.c linux-3.0.9/fs/sysfs/file.c count = ops->show(kobj, attr_sd->s_attr.attr, buffer->page); sysfs_put_active(attr_sd); -@@ -287,7 +287,7 @@ static int sysfs_get_open_dirent(struct +@@ -287,7 +287,7 @@ static int sysfs_get_open_dirent(struct sysfs_dirent *sd, return -ENOMEM; atomic_set(&new_od->refcnt, 0); @@ -47056,7 +48209,7 @@ diff -urNp linux-3.0.9/fs/sysfs/file.c linux-3.0.9/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, poll_table *wait) sysfs_put_active(attr_sd); @@ -47065,7 +48218,7 @@ diff -urNp linux-3.0.9/fs/sysfs/file.c linux-3.0.9/fs/sysfs/file.c goto trigger; 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) od = sd->s_attr.open; if (od) { @@ -47074,9 +48227,10 @@ diff -urNp linux-3.0.9/fs/sysfs/file.c linux-3.0.9/fs/sysfs/file.c wake_up_interruptible(&od->poll); } -diff -urNp linux-3.0.9/fs/sysfs/mount.c linux-3.0.9/fs/sysfs/mount.c ---- linux-3.0.9/fs/sysfs/mount.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/sysfs/mount.c 2011-11-12 12:47:14.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 = { .s_name = "", .s_count = ATOMIC_INIT(1), @@ -47089,10 +48243,11 @@ diff -urNp linux-3.0.9/fs/sysfs/mount.c linux-3.0.9/fs/sysfs/mount.c .s_ino = 1, }; -diff -urNp linux-3.0.9/fs/sysfs/symlink.c linux-3.0.9/fs/sysfs/symlink.c ---- linux-3.0.9/fs/sysfs/symlink.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/sysfs/symlink.c 2011-11-12 12:47:14.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) static void sysfs_put_link(struct dentry *dentry, struct nameidata *nd, void *cookie) { @@ -47101,10 +48256,11 @@ diff -urNp linux-3.0.9/fs/sysfs/symlink.c linux-3.0.9/fs/sysfs/symlink.c if (!IS_ERR(page)) free_page((unsigned long)page); } -diff -urNp linux-3.0.9/fs/udf/inode.c linux-3.0.9/fs/udf/inode.c ---- linux-3.0.9/fs/udf/inode.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/udf/inode.c 2011-11-12 12:47:14.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 = 0, pgoal = iinfo->i_location.logicalBlockNum; int lastblock = 0; @@ -47113,10 +48269,11 @@ diff -urNp linux-3.0.9/fs/udf/inode.c linux-3.0.9/fs/udf/inode.c prev_epos.offset = udf_file_entry_alloc_offset(inode); prev_epos.block = iinfo->i_location; prev_epos.bh = NULL; -diff -urNp linux-3.0.9/fs/udf/misc.c linux-3.0.9/fs/udf/misc.c ---- linux-3.0.9/fs/udf/misc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/udf/misc.c 2011-11-12 12:47:14.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, u8 udf_tag_checksum(const struct tag *t) { @@ -47125,9 +48282,10 @@ diff -urNp linux-3.0.9/fs/udf/misc.c linux-3.0.9/fs/udf/misc.c u8 checksum = 0; int i; for (i = 0; i < sizeof(struct tag); ++i) -diff -urNp linux-3.0.9/fs/utimes.c linux-3.0.9/fs/utimes.c ---- linux-3.0.9/fs/utimes.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/utimes.c 2011-11-12 12:47:14.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 <linux/compiler.h> #include <linux/file.h> @@ -47136,7 +48294,7 @@ diff -urNp linux-3.0.9/fs/utimes.c linux-3.0.9/fs/utimes.c #include <linux/linkage.h> #include <linux/mount.h> #include <linux/namei.h> -@@ -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; } } @@ -47149,23 +48307,10 @@ diff -urNp linux-3.0.9/fs/utimes.c linux-3.0.9/fs/utimes.c mutex_lock(&inode->i_mutex); error = notify_change(path->dentry, &newattrs); mutex_unlock(&inode->i_mutex); -diff -urNp linux-3.0.9/fs/xattr_acl.c linux-3.0.9/fs/xattr_acl.c ---- linux-3.0.9/fs/xattr_acl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/xattr_acl.c 2011-11-12 12:47:14.000000000 -0500 -@@ -17,8 +17,8 @@ - struct posix_acl * - posix_acl_from_xattr(const void *value, size_t size) - { -- posix_acl_xattr_header *header = (posix_acl_xattr_header *)value; -- posix_acl_xattr_entry *entry = (posix_acl_xattr_entry *)(header+1), *end; -+ const posix_acl_xattr_header *header = (const posix_acl_xattr_header *)value; -+ const posix_acl_xattr_entry *entry = (const posix_acl_xattr_entry *)(header+1), *end; - int count; - struct posix_acl *acl; - struct posix_acl_entry *acl_e; -diff -urNp linux-3.0.9/fs/xattr.c linux-3.0.9/fs/xattr.c ---- linux-3.0.9/fs/xattr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/xattr.c 2011-11-12 12:47:14.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 */ @@ -47175,7 +48320,7 @@ diff -urNp linux-3.0.9/fs/xattr.c linux-3.0.9/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); } @@ -47190,7 +48335,7 @@ diff -urNp linux-3.0.9/fs/xattr.c linux-3.0.9/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 *, pathname, return error; error = mnt_want_write(path.mnt); if (!error) { @@ -47199,7 +48344,7 @@ diff -urNp linux-3.0.9/fs/xattr.c linux-3.0.9/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 *, pathname, return error; error = mnt_want_write(path.mnt); if (!error) { @@ -47208,7 +48353,7 @@ diff -urNp linux-3.0.9/fs/xattr.c linux-3.0.9/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 __user *, name, const void __user *,value, size_t, size, int, flags) { struct file *f; @@ -47228,20 +48373,25 @@ diff -urNp linux-3.0.9/fs/xattr.c linux-3.0.9/fs/xattr.c mnt_drop_write(f->f_path.mnt); } fput(f); -diff -urNp linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl32.c linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl32.c ---- linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl32.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl32.c 2011-11-12 12:47:14.000000000 -0500 -@@ -73,6 +73,7 @@ xfs_compat_ioc_fsgeometry_v1( - xfs_fsop_geom_t fsgeo; - int error; - -+ memset(&fsgeo, 0, sizeof(fsgeo)); - error = xfs_fs_geometry(mp, &fsgeo, 3); - if (error) - return -error; -diff -urNp linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl.c linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl.c ---- linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl.c 2011-11-12 12:47:14.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 = (posix_acl_xattr_header *)value; +- posix_acl_xattr_entry *entry = (posix_acl_xattr_entry *)(header+1), *end; ++ const posix_acl_xattr_header *header = (const posix_acl_xattr_header *)value; ++ const posix_acl_xattr_entry *entry = (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 acca2c5..5c67296 100644 +--- a/fs/xfs/linux-2.6/xfs_ioctl.c ++++ b/fs/xfs/linux-2.6/xfs_ioctl.c @@ -128,7 +128,7 @@ xfs_find_handle( } @@ -47251,9 +48401,22 @@ diff -urNp linux-3.0.9/fs/xfs/linux-2.6/xfs_ioctl.c linux-3.0.9/fs/xfs/linux-2.6 copy_to_user(hreq->ohandlen, &hsize, sizeof(__s32))) goto out_put; -diff -urNp linux-3.0.9/fs/xfs/linux-2.6/xfs_iops.c linux-3.0.9/fs/xfs/linux-2.6/xfs_iops.c ---- linux-3.0.9/fs/xfs/linux-2.6/xfs_iops.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/xfs/linux-2.6/xfs_iops.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/xfs/linux-2.6/xfs_ioctl32.c b/fs/xfs/linux-2.6/xfs_ioctl32.c +index 54e623b..5c3fd7a 100644 +--- a/fs/xfs/linux-2.6/xfs_ioctl32.c ++++ b/fs/xfs/linux-2.6/xfs_ioctl32.c +@@ -73,6 +73,7 @@ xfs_compat_ioc_fsgeometry_v1( + xfs_fsop_geom_t fsgeo; + int error; + ++ memset(&fsgeo, 0, sizeof(fsgeo)); + error = 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 d44d92c..ef7ad2d 100644 +--- a/fs/xfs/linux-2.6/xfs_iops.c ++++ b/fs/xfs/linux-2.6/xfs_iops.c @@ -437,7 +437,7 @@ xfs_vn_put_link( struct nameidata *nd, void *p) @@ -47263,9 +48426,10 @@ diff -urNp linux-3.0.9/fs/xfs/linux-2.6/xfs_iops.c linux-3.0.9/fs/xfs/linux-2.6/ if (!IS_ERR(s)) kfree(s); -diff -urNp linux-3.0.9/fs/xfs/xfs_bmap.c linux-3.0.9/fs/xfs/xfs_bmap.c ---- linux-3.0.9/fs/xfs/xfs_bmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/xfs/xfs_bmap.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/xfs/xfs_bmap.c b/fs/xfs/xfs_bmap.c +index e546a33..08583b8 100644 +--- a/fs/xfs/xfs_bmap.c ++++ b/fs/xfs/xfs_bmap.c @@ -253,7 +253,7 @@ xfs_bmap_validate_ret( int nmap, int ret_nmap); @@ -47275,9 +48439,10 @@ diff -urNp linux-3.0.9/fs/xfs/xfs_bmap.c linux-3.0.9/fs/xfs/xfs_bmap.c #endif /* DEBUG */ STATIC int -diff -urNp linux-3.0.9/fs/xfs/xfs_dir2_sf.c linux-3.0.9/fs/xfs/xfs_dir2_sf.c ---- linux-3.0.9/fs/xfs/xfs_dir2_sf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/fs/xfs/xfs_dir2_sf.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/fs/xfs/xfs_dir2_sf.c b/fs/xfs/xfs_dir2_sf.c +index b1bae6b..5aa3993 100644 +--- a/fs/xfs/xfs_dir2_sf.c ++++ b/fs/xfs/xfs_dir2_sf.c @@ -780,7 +780,15 @@ xfs_dir2_sf_getdents( } @@ -47295,119 +48460,1097 @@ diff -urNp linux-3.0.9/fs/xfs/xfs_dir2_sf.c linux-3.0.9/fs/xfs/xfs_dir2_sf.c off & 0x7fffffff, ino, DT_UNKNOWN)) { *offset = off & 0x7fffffff; return 0; -diff -urNp linux-3.0.9/grsecurity/gracl_alloc.c linux-3.0.9/grsecurity/gracl_alloc.c ---- linux-3.0.9/grsecurity/gracl_alloc.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_alloc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -0,0 +1,105 @@ -+#include <linux/kernel.h> -+#include <linux/mm.h> -+#include <linux/slab.h> -+#include <linux/vmalloc.h> -+#include <linux/gracl.h> -+#include <linux/grsecurity.h> +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 unsigned long alloc_stack_next = 1; -+static unsigned long alloc_stack_size = 1; -+static void **alloc_stack; ++menu "Grsecurity" + -+static __inline__ int -+alloc_pop(void) -+{ -+ if (alloc_stack_next == 1) -+ return 0; ++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. + -+ kfree(alloc_stack[alloc_stack_next - 2]); ++choice ++ prompt "Security Level" ++ depends on GRKERNSEC ++ default GRKERNSEC_CUSTOM + -+ alloc_stack_next--; ++config GRKERNSEC_LOW ++ bool "Low" ++ select GRKERNSEC_LINK ++ select GRKERNSEC_FIFO ++ select GRKERNSEC_RANDNET ++ select GRKERNSEC_DMESG ++ select GRKERNSEC_CHROOT ++ select GRKERNSEC_CHROOT_CHDIR + -+ 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: + -+static __inline__ int -+alloc_push(void *buf) -+{ -+ if (alloc_stack_next >= alloc_stack_size) -+ return 1; ++ - Linking restrictions ++ - FIFO restrictions ++ - Restricted dmesg ++ - Enforced chdir("/") on chroot ++ - Runtime module disabling + -+ alloc_stack[alloc_stack_next - 1] = buf; ++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)) + -+ alloc_stack_next++; ++ 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, ++ the following features (in addition to those provided in the ++ low additional security level) will be enabled: + -+ return 0; -+} ++ - 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 + -+void * -+acl_alloc(unsigned long len) -+{ -+ void *ret = NULL; ++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 <http://pax.grsecurity.net> 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 ++ features in addition to those listed in the low and medium ++ security levels: + -+ if (!len || len > PAGE_SIZE) -+ goto out; ++ - 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/<pid>/[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 + -+ ret = kmalloc(len, GFP_KERNEL); ++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. + -+ if (ret) { -+ if (alloc_push(ret)) { -+ kfree(ret); -+ ret = NULL; -+ } -+ } ++endchoice + -+out: -+ return ret; -+} ++menu "Address Space Protection" ++depends on GRKERNSEC + -+void * -+acl_alloc_num(unsigned long num, unsigned long len) -+{ -+ if (!len || (num > (PAGE_SIZE / len))) -+ return NULL; ++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 running ++ kernel. /dev/port will also not be allowed to be opened. If you have 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/iopl. ++ If you are not using XFree86, you may be able to stop this additional ++ 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. + -+ return acl_alloc(num * len); -+} ++config GRKERNSEC_VM86 ++ bool "Restrict VM86 mode" ++ depends on X86_32 + -+void -+acl_free_all(void) -+{ -+ if (gr_acl_is_enabled() || !alloc_stack) -+ return; ++ 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 purpose ++ of the option is to prevent exploitation of emulation errors in ++ virtualization of vm86 mode like the one discovered in VMWare in 2009. ++ Nearly all users should be able to enable this option. + -+ while (alloc_pop()) ; ++config GRKERNSEC_IO ++ bool "Disable privileged I/O" ++ depends on X86 ++ select RTC_CLASS ++ select RTC_INTF_DEV ++ select RTC_DRV_CMOS + -+ if (alloc_stack) { -+ if ((alloc_stack_size * sizeof (void *)) <= PAGE_SIZE) -+ kfree(alloc_stack); -+ else -+ vfree(alloc_stack); -+ } ++ 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 ++ clock support is enabled if this option is enabled, to ensure ++ that hwclock operates correctly. XFree86 still will not ++ operate correctly with this option enabled, so DO NOT CHOOSE Y ++ IF YOU USE XFree86. If you use XFree86 and you still want to ++ protect your kernel against modification, use the RBAC system. + -+ alloc_stack = NULL; -+ alloc_stack_size = 1; -+ alloc_stack_next = 1; ++config GRKERNSEC_PROC_MEMMAP ++ bool "Remove addresses from /proc/<pid>/[smaps|maps|stat]" ++ default y if (PAX_NOEXEC || PAX_ASLR) ++ depends on PAX_NOEXEC || PAX_ASLR ++ help ++ If you say Y here, the /proc/<pid>/maps and /proc/<pid>/stat files will ++ 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. + -+ return; -+} ++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 binaries ++ 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 further ++ processes for 15 minutes. ++ It is recommended that you also enable signal logging in the auditing ++ section so that logs are generated when a process triggers a suspicious ++ signal. ++ If the sysctl option is enabled, a sysctl option with name ++ "deter_bruteforce" is created. + -+int -+acl_alloc_stack_init(unsigned long size) -+{ -+ if ((size * sizeof (void *)) <= PAGE_SIZE) -+ alloc_stack = -+ (void **) kmalloc(size * sizeof (void *), GFP_KERNEL); -+ else -+ alloc_stack = (void **) vmalloc(size * sizeof (void *)); + -+ alloc_stack_size = 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 ++ by unprivileged users who abuse the auto-loading behavior to ++ cause a vulnerable module to load that is then exploited. + -+ if (!alloc_stack) -+ return 0; -+ else -+ return 1; -+} -diff -urNp linux-3.0.9/grsecurity/gracl.c linux-3.0.9/grsecurity/gracl.c ---- linux-3.0.9/grsecurity/gracl.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl.c 2011-11-12 12:47:14.000000000 -0500 -@@ -0,0 +1,4154 @@ ++ If this option prevents a legitimate use of auto-loading for a ++ non-root user, the administrator can execute modprobe manually ++ 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 ++ 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 distribution ++ 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 ++ 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 kernel, ++ 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 prevent ++ an attacker with root access from misusing the RBAC system to hide files ++ 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 time. ++ The lower the number, the harder it will be to brute-force a password. ++ ++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 to ++ authorize to the RBAC system with the maximum number of invalid ++ passwords. The higher the number, the harder it will be to brute-force ++ 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 restriction. ++ Depending upon the option you choose, you can either restrict users to ++ see only the processes they themselves run, or choose a group that can ++ view all processes and files normally restricted to root if you choose ++ 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 here. ++ ++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 own ++ processes, and restricts them from viewing network-related information, ++ 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 ++ 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 of ++ the FIFO is the same owner of the directory it's held in. If the sysctl ++ 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 unprivileged ++ users of the system. Sysfs and debugfs have also become a large source ++ of new vulnerabilities, ranging from infoleaks to local compromise. ++ There has been very little oversight with an eye toward security involved ++ in adding new exporters of information to these filesystems, so their ++ 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 resulting ++ behavior if this option is enabled in an init script on a read-only ++ filesystem. This feature is mainly intended for secure embedded systems. ++ ++config GRKERNSEC_CHROOT ++ bool "Chroot jail restrictions" ++ help ++ If you say Y here, you will be able to choose several options that will ++ 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 chroot ++ 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 ++ option is enabled, a sysctl option with name ++ "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. This ++ 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-chrooted ++ 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 chmod ++ or fchmod files to make them have suid or sgid bits. This protects ++ against another published method of breaking a chroot. If the sysctl ++ 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 directory ++ outside the filesystem will be stopped. If the sysctl option ++ is enabled, a sysctl option with name "chroot_deny_fchdir" is created. ++ ++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 (which ++ they could then use to wipe the drive or steal data). It is recommended ++ 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 attach ++ to shared memory segments that were created outside of the chroot jail. ++ It is recommended that you say Y here. If the sysctl option is enabled, ++ 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 recommended ++ that you say Y here. If the sysctl option is enabled, a sysctl option ++ 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, ++ 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 raise ++ the priority of processes in the chroot, or alter the priority of ++ processes outside the chroot. This provides more security than simply ++ 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 immutable ++ 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 recommended ++ 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 enabled, ++ 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 with ++ name "exec_logging" is created. ++ WARNING: This option when enabled will produce a LOT of logs, especially ++ 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 current ++ 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 logged ++ to syslog. This can cause a large amount of logs if certain ++ applications (eg. djb's daemontools) are installed on the system, and ++ 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 created. ++ ++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 program ++ 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 option ++ 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/<pid>/ipaddr support" ++ help ++ If you say Y here, a new entry will be added to each /proc/<pid> ++ 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 response ++ 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 via ++ 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" is ++ 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 will ++ 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 option ++ with name "tpe_invert" is created. Unlike other sysctl options, this ++ 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 ++ loopback interface from blackholing. Enabling this feature ++ 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 will ++ 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 to ++ 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. ++ ++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 will ++ 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 group ++ you specify will have to use passive mode when initiating ftp transfers ++ from the shell on your machine. If the sysctl option is enabled, a ++ sysctl option with name "socket_client" is created. ++ ++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. ++ ++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 will ++ be unable to run server applications from your machine. If the sysctl ++ option is enabled, a sysctl option with name "socket_server" is created. ++ ++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. ++ ++endmenu ++menu "Sysctl support" ++depends on GRKERNSEC && SYSCTL ++ ++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 entries ++ are mutable until the "grsec_lock" entry is set to a non-zero value. ++ All features enabled in the kernel configuration are disabled at boot ++ 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 should ++ 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* ++ ++ Currently this option creates the following sysctl entries: ++ "Disable Privileged I/O": "disable_priv_io" ++ ++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. ++ ++endmenu ++menu "Logging Options" ++depends on GRKERNSEC ++ ++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 enough ++ to allow informative logs to be produced, but large enough to ++ prevent flooding. ++ ++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 allowed ++ 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. ++ ++endmenu ++ ++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 Dalton ++# 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 released ++# under the GPL v2 or higher ++ ++obj-y = 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 ++ ++obj-$(CONFIG_GRKERNSEC) += 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) += gracl_res.o ++ ++ifdef CONFIG_NET ++obj-y += grsec_sock.o ++obj-$(CONFIG_GRKERNSEC) += gracl_ip.o ++endif ++ ++ifndef CONFIG_GRKERNSEC ++obj-y += grsec_disabled.o ++endif ++ ++ifdef CONFIG_GRKERNSEC_HIDESYM ++extra-y := 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..8397b5f +--- /dev/null ++++ b/grsecurity/gracl.c +@@ -0,0 +1,4155 @@ +#include <linux/kernel.h> +#include <linux/module.h> +#include <linux/sched.h> @@ -50243,6 +52386,7 @@ diff -urNp linux-3.0.9/grsecurity/gracl.c linux-3.0.9/grsecurity/gracl.c +{ + struct name_entry *matchn; + struct inodev_entry *inodev; ++ struct inode *inode = new_dentry->d_inode; + ino_t old_ino = old_dentry->d_inode->i_ino; + dev_t old_dev = __get_dev(old_dentry); + @@ -50265,17 +52409,17 @@ diff -urNp linux-3.0.9/grsecurity/gracl.c linux-3.0.9/grsecurity/gracl.c + */ + + write_lock(&gr_inode_lock); -+ if (unlikely(replace && new_dentry->d_inode)) { -+ ino_t new_ino = new_dentry->d_inode->i_ino; ++ if (unlikely(replace && inode)) { ++ ino_t new_ino = inode->i_ino; + dev_t new_dev = __get_dev(new_dentry); + + inodev = lookup_inodev_entry(new_ino, new_dev); -+ if (inodev != NULL && (new_dentry->d_inode->i_nlink <= 1)) ++ if (inodev != NULL && ((inode->i_nlink <= 1) || S_ISDIR(inode->i_mode))) + do_handle_delete(inodev, new_ino, new_dev); + } + + inodev = lookup_inodev_entry(old_ino, old_dev); -+ if (inodev != NULL && (old_dentry->d_inode->i_nlink <= 1)) ++ if (inodev != NULL && ((old_dentry->d_inode->i_nlink <= 1) || S_ISDIR(old_dentry->d_inode->i_mode))) + do_handle_delete(inodev, old_ino, old_dev); + + if (unlikely((unsigned long)matchn)) @@ -51562,9 +53706,122 @@ diff -urNp linux-3.0.9/grsecurity/gracl.c linux-3.0.9/grsecurity/gracl.c +EXPORT_SYMBOL(gr_check_group_change); +#endif + -diff -urNp linux-3.0.9/grsecurity/gracl_cap.c linux-3.0.9/grsecurity/gracl_cap.c ---- linux-3.0.9/grsecurity/gracl_cap.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_cap.c 2011-11-12 12:47:14.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 <linux/kernel.h> ++#include <linux/mm.h> ++#include <linux/slab.h> ++#include <linux/vmalloc.h> ++#include <linux/gracl.h> ++#include <linux/grsecurity.h> ++ ++static unsigned long alloc_stack_next = 1; ++static unsigned long alloc_stack_size = 1; ++static void **alloc_stack; ++ ++static __inline__ int ++alloc_pop(void) ++{ ++ if (alloc_stack_next == 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 >= alloc_stack_size) ++ return 1; ++ ++ alloc_stack[alloc_stack_next - 1] = buf; ++ ++ alloc_stack_next++; ++ ++ return 0; ++} ++ ++void * ++acl_alloc(unsigned long len) ++{ ++ void *ret = NULL; ++ ++ if (!len || len > PAGE_SIZE) ++ goto out; ++ ++ ret = kmalloc(len, GFP_KERNEL); ++ ++ if (ret) { ++ if (alloc_push(ret)) { ++ kfree(ret); ++ ret = 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 *)) <= PAGE_SIZE) ++ kfree(alloc_stack); ++ else ++ vfree(alloc_stack); ++ } ++ ++ alloc_stack = NULL; ++ alloc_stack_size = 1; ++ alloc_stack_next = 1; ++ ++ return; ++} ++ ++int ++acl_alloc_stack_init(unsigned long size) ++{ ++ if ((size * sizeof (void *)) <= PAGE_SIZE) ++ alloc_stack = ++ (void **) kmalloc(size * sizeof (void *), GFP_KERNEL); ++ else ++ alloc_stack = (void **) vmalloc(size * sizeof (void *)); ++ ++ alloc_stack_size = 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 <linux/kernel.h> +#include <linux/module.h> @@ -51667,9 +53924,11 @@ diff -urNp linux-3.0.9/grsecurity/gracl_cap.c linux-3.0.9/grsecurity/gracl_cap.c + return 0; +} + -diff -urNp linux-3.0.9/grsecurity/gracl_fs.c linux-3.0.9/grsecurity/gracl_fs.c ---- linux-3.0.9/grsecurity/gracl_fs.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_fs.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/grsecurity/gracl_fs.c b/grsecurity/gracl_fs.c +new file mode 100644 +index 0000000..8ab588d +--- /dev/null ++++ b/grsecurity/gracl_fs.c @@ -0,0 +1,431 @@ +#include <linux/kernel.h> +#include <linux/sched.h> @@ -52102,9 +54361,11 @@ diff -urNp linux-3.0.9/grsecurity/gracl_fs.c linux-3.0.9/grsecurity/gracl_fs.c + + return 0; +} -diff -urNp linux-3.0.9/grsecurity/gracl_ip.c linux-3.0.9/grsecurity/gracl_ip.c ---- linux-3.0.9/grsecurity/gracl_ip.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_ip.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <asm/uaccess.h> @@ -52487,9 +54748,11 @@ diff -urNp linux-3.0.9/grsecurity/gracl_ip.c linux-3.0.9/grsecurity/gracl_ip.c + + return gr_search_connectbind(GR_CONNECT | GR_CONNECTOVERRIDE, sk, &sin, SOCK_DGRAM); +} -diff -urNp linux-3.0.9/grsecurity/gracl_learn.c linux-3.0.9/grsecurity/gracl_learn.c ---- linux-3.0.9/grsecurity/gracl_learn.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_learn.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/mm.h> @@ -52698,9 +54961,11 @@ diff -urNp linux-3.0.9/grsecurity/gracl_learn.c linux-3.0.9/grsecurity/gracl_lea + .release = close_learn, + .poll = poll_learn, +}; -diff -urNp linux-3.0.9/grsecurity/gracl_res.c linux-3.0.9/grsecurity/gracl_res.c ---- linux-3.0.9/grsecurity/gracl_res.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_res.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/sched.h> @@ -52770,9 +55035,11 @@ diff -urNp linux-3.0.9/grsecurity/gracl_res.c linux-3.0.9/grsecurity/gracl_res.c + rcu_read_unlock(); + return; +} -diff -urNp linux-3.0.9/grsecurity/gracl_segv.c linux-3.0.9/grsecurity/gracl_segv.c ---- linux-3.0.9/grsecurity/gracl_segv.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_segv.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/mm.h> @@ -52955,7 +55222,6 @@ diff -urNp linux-3.0.9/grsecurity/gracl_segv.c linux-3.0.9/grsecurity/gracl_segv +gr_handle_crash(struct task_struct *task, const int sig) +{ + struct acl_subject_label *curr; -+ struct acl_subject_label *curr2; + struct task_struct *tsk, *tsk2; + const struct cred *cred; + const struct cred *cred2; @@ -53002,15 +55268,16 @@ diff -urNp linux-3.0.9/grsecurity/gracl_segv.c linux-3.0.9/grsecurity/gracl_segv + } else { + gr_log_crash2(GR_DONT_AUDIT, GR_SEGVNOSUID_ACL_MSG, task, curr->res[GR_CRASH_RES].rlim_max); + read_lock(&tasklist_lock); ++ read_lock(&grsec_exec_file_lock); + do_each_thread(tsk2, tsk) { + if (likely(tsk != task)) { -+ curr2 = tsk->acl; -+ -+ if (curr2->device == curr->device && -+ curr2->inode == curr->inode) ++ // if this thread has the same subject as the one that triggered ++ // RES_CRASH and it's the same binary, kill it ++ if (tsk->acl == task->acl && tsk->exec_file == task->exec_file) + gr_fake_force_sig(SIGKILL, tsk); + } + } while_each_thread(tsk2, tsk); ++ read_unlock(&grsec_exec_file_lock); + read_unlock(&tasklist_lock); + } + rcu_read_unlock(); @@ -53073,9 +55340,11 @@ diff -urNp linux-3.0.9/grsecurity/gracl_segv.c linux-3.0.9/grsecurity/gracl_segv + + return; +} -diff -urNp linux-3.0.9/grsecurity/gracl_shm.c linux-3.0.9/grsecurity/gracl_shm.c ---- linux-3.0.9/grsecurity/gracl_shm.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/gracl_shm.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/mm.h> @@ -53117,9 +55386,11 @@ diff -urNp linux-3.0.9/grsecurity/gracl_shm.c linux-3.0.9/grsecurity/gracl_shm.c + + return 1; +} -diff -urNp linux-3.0.9/grsecurity/grsec_chdir.c linux-3.0.9/grsecurity/grsec_chdir.c ---- linux-3.0.9/grsecurity/grsec_chdir.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_chdir.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/sched.h> @@ -53140,9 +55411,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_chdir.c linux-3.0.9/grsecurity/grsec_chd +#endif + return; +} -diff -urNp linux-3.0.9/grsecurity/grsec_chroot.c linux-3.0.9/grsecurity/grsec_chroot.c ---- linux-3.0.9/grsecurity/grsec_chroot.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_chroot.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/module.h> @@ -53495,9 +55768,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_chroot.c linux-3.0.9/grsecurity/grsec_ch +#endif + return 0; +} -diff -urNp linux-3.0.9/grsecurity/grsec_disabled.c linux-3.0.9/grsecurity/grsec_disabled.c ---- linux-3.0.9/grsecurity/grsec_disabled.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_disabled.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/grsecurity/grsec_disabled.c b/grsecurity/grsec_disabled.c +new file mode 100644 +index 0000000..7cf9c87 +--- /dev/null ++++ b/grsecurity/grsec_disabled.c @@ -0,0 +1,439 @@ +#include <linux/kernel.h> +#include <linux/module.h> @@ -53938,9 +56213,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_disabled.c linux-3.0.9/grsecurity/grsec_ +EXPORT_SYMBOL(gr_check_user_change); +EXPORT_SYMBOL(gr_check_group_change); +#endif -diff -urNp linux-3.0.9/grsecurity/grsec_exec.c linux-3.0.9/grsecurity/grsec_exec.c ---- linux-3.0.9/grsecurity/grsec_exec.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_exec.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/sched.h> @@ -54088,9 +56365,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_exec.c linux-3.0.9/grsecurity/grsec_exec + +EXPORT_SYMBOL(gr_is_capable); +EXPORT_SYMBOL(gr_is_capable_nolog); -diff -urNp linux-3.0.9/grsecurity/grsec_fifo.c linux-3.0.9/grsecurity/grsec_fifo.c ---- linux-3.0.9/grsecurity/grsec_fifo.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_fifo.c 2011-11-12 12:47:14.000000000 -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 <linux/kernel.h> +#include <linux/sched.h> @@ -54116,9 +56395,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_fifo.c linux-3.0.9/grsecurity/grsec_fifo +#endif + return 0; +} -diff -urNp linux-3.0.9/grsecurity/grsec_fork.c linux-3.0.9/grsecurity/grsec_fork.c ---- linux-3.0.9/grsecurity/grsec_fork.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_fork.c 2011-11-12 12:47:14.000000000 -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 <linux/kernel.h> +#include <linux/sched.h> @@ -54143,9 +56424,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_fork.c linux-3.0.9/grsecurity/grsec_fork +#endif + return; +} -diff -urNp linux-3.0.9/grsecurity/grsec_init.c linux-3.0.9/grsecurity/grsec_init.c ---- linux-3.0.9/grsecurity/grsec_init.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_init.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/sched.h> @@ -54416,9 +56699,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_init.c linux-3.0.9/grsecurity/grsec_init + + return; +} -diff -urNp linux-3.0.9/grsecurity/grsec_link.c linux-3.0.9/grsecurity/grsec_link.c ---- linux-3.0.9/grsecurity/grsec_link.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_link.c 2011-11-12 12:47:14.000000000 -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 <linux/kernel.h> +#include <linux/sched.h> @@ -54463,10 +56748,12 @@ diff -urNp linux-3.0.9/grsecurity/grsec_link.c linux-3.0.9/grsecurity/grsec_link +#endif + return 0; +} -diff -urNp linux-3.0.9/grsecurity/grsec_log.c linux-3.0.9/grsecurity/grsec_log.c ---- linux-3.0.9/grsecurity/grsec_log.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_log.c 2011-11-12 12:47:14.000000000 -0500 -@@ -0,0 +1,315 @@ +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 <linux/kernel.h> +#include <linux/sched.h> +#include <linux/file.h> @@ -54588,12 +56875,15 @@ diff -urNp linux-3.0.9/grsecurity/grsec_log.c linux-3.0.9/grsecurity/grsec_log.c + return; +} + -+static void gr_log_end(int audit) ++static void gr_log_end(int audit, int append_default) +{ + char *buf = (audit == GR_DO_AUDIT) ? gr_audit_log_buf : gr_alert_log_buf; -+ unsigned int len = strlen(buf); + -+ snprintf(buf + len, PAGE_SIZE - len - 1, DEFAULTSECMSG, DEFAULTSECARGS(current, current_cred(), __task_cred(current->real_parent))); ++ if (append_default) { ++ unsigned int len = strlen(buf); ++ snprintf(buf + len, PAGE_SIZE - len - 1, DEFAULTSECMSG, DEFAULTSECARGS(current, current_cred(), __task_cred(current->real_parent))); ++ } ++ + printk("%s\n", buf); + + return; @@ -54779,12 +57069,18 @@ diff -urNp linux-3.0.9/grsecurity/grsec_log.c linux-3.0.9/grsecurity/grsec_log.c + gr_log_middle(audit, msg, ap); + } + va_end(ap); -+ gr_log_end(audit); ++ // these don't need DEFAULTSECARGS printed on the end ++ if (argtypes == GR_CRASH1 || argtypes == GR_CRASH2) ++ gr_log_end(audit, 0); ++ else ++ gr_log_end(audit, 1); + END_LOCKS(audit); +} -diff -urNp linux-3.0.9/grsecurity/grsec_mem.c linux-3.0.9/grsecurity/grsec_mem.c ---- linux-3.0.9/grsecurity/grsec_mem.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_mem.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/sched.h> @@ -54819,9 +57115,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_mem.c linux-3.0.9/grsecurity/grsec_mem.c + gr_log_noargs(GR_DONT_AUDIT, GR_VM86_MSG); + return; +} -diff -urNp linux-3.0.9/grsecurity/grsec_mount.c linux-3.0.9/grsecurity/grsec_mount.c ---- linux-3.0.9/grsecurity/grsec_mount.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_mount.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/sched.h> @@ -54885,9 +57183,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_mount.c linux-3.0.9/grsecurity/grsec_mou +#endif + return 0; +} -diff -urNp linux-3.0.9/grsecurity/grsec_pax.c linux-3.0.9/grsecurity/grsec_pax.c ---- linux-3.0.9/grsecurity/grsec_pax.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_pax.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/sched.h> @@ -54925,9 +57225,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_pax.c linux-3.0.9/grsecurity/grsec_pax.c +#endif + return; +} -diff -urNp linux-3.0.9/grsecurity/grsec_ptrace.c linux-3.0.9/grsecurity/grsec_ptrace.c ---- linux-3.0.9/grsecurity/grsec_ptrace.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_ptrace.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/sched.h> @@ -54943,9 +57245,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_ptrace.c linux-3.0.9/grsecurity/grsec_pt +#endif + return; +} -diff -urNp linux-3.0.9/grsecurity/grsec_sig.c linux-3.0.9/grsecurity/grsec_sig.c ---- linux-3.0.9/grsecurity/grsec_sig.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_sig.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/sched.h> @@ -55153,9 +57457,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_sig.c linux-3.0.9/grsecurity/grsec_sig.c +#endif + return 0; +} -diff -urNp linux-3.0.9/grsecurity/grsec_sock.c linux-3.0.9/grsecurity/grsec_sock.c ---- linux-3.0.9/grsecurity/grsec_sock.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_sock.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/module.h> @@ -55401,9 +57707,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_sock.c linux-3.0.9/grsecurity/grsec_sock +#endif + return 0; +} -diff -urNp linux-3.0.9/grsecurity/grsec_sysctl.c linux-3.0.9/grsecurity/grsec_sysctl.c ---- linux-3.0.9/grsecurity/grsec_sysctl.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_sysctl.c 2011-11-12 12:47:14.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 <linux/kernel.h> +#include <linux/sched.h> @@ -55838,9 +58146,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_sysctl.c linux-3.0.9/grsecurity/grsec_sy + { } +}; +#endif -diff -urNp linux-3.0.9/grsecurity/grsec_time.c linux-3.0.9/grsecurity/grsec_time.c ---- linux-3.0.9/grsecurity/grsec_time.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_time.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/sched.h> @@ -55858,9 +58168,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_time.c linux-3.0.9/grsecurity/grsec_time +} + +EXPORT_SYMBOL(gr_log_timechange); -diff -urNp linux-3.0.9/grsecurity/grsec_tpe.c linux-3.0.9/grsecurity/grsec_tpe.c ---- linux-3.0.9/grsecurity/grsec_tpe.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsec_tpe.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/kernel.h> +#include <linux/sched.h> @@ -55901,9 +58213,11 @@ diff -urNp linux-3.0.9/grsecurity/grsec_tpe.c linux-3.0.9/grsecurity/grsec_tpe.c +#endif + return 1; +} -diff -urNp linux-3.0.9/grsecurity/grsum.c linux-3.0.9/grsecurity/grsum.c ---- linux-3.0.9/grsecurity/grsum.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/grsum.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/err.h> +#include <linux/kernel.h> @@ -55966,1091 +58280,10 @@ diff -urNp linux-3.0.9/grsecurity/grsum.c linux-3.0.9/grsecurity/grsum.c + + return retval; +} -diff -urNp linux-3.0.9/grsecurity/Kconfig linux-3.0.9/grsecurity/Kconfig ---- linux-3.0.9/grsecurity/Kconfig 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/Kconfig 2011-11-12 12:47:14.000000000 -0500 -@@ -0,0 +1,1038 @@ -+# -+# 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, -+ the following features (in addition to those provided in the -+ 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 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 <http://pax.grsecurity.net> 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 -+ features in addition to those listed in the low and medium -+ 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/<pid>/[smaps|maps|stat] -+ - Kernel stack randomization -+ - Mount/unmount/remount logging -+ - Kernel symbol hiding -+ - Prevention of memory exhaustion-based exploits -+ - 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 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 via mmap or otherwise to modify the running kernel. -+ /dev/port will also not be allowed to be opened. If you have 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/iopl. -+ If you are not using XFree86, you may be able to stop this additional -+ 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 purpose -+ of the option is to prevent exploitation of emulation errors in -+ virtualization of vm86 mode like the one discovered in VMWare in 2009. -+ 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 -+ clock support is enabled if this option is enabled, to ensure -+ that hwclock operates correctly. XFree86 still will not -+ operate correctly with this option enabled, so DO NOT CHOOSE Y -+ IF YOU USE XFree86. If you use XFree86 and you still want to -+ protect your kernel against modification, use the RBAC system. -+ -+config GRKERNSEC_PROC_MEMMAP -+ bool "Remove addresses from /proc/<pid>/[smaps|maps|stat]" -+ default y if (PAX_NOEXEC || PAX_ASLR) -+ depends on PAX_NOEXEC || PAX_ASLR -+ help -+ If you say Y here, the /proc/<pid>/maps and /proc/<pid>/stat files will -+ 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 binaries -+ 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 further -+ processes for 15 minutes. -+ It is recommended that you also enable signal logging in the auditing -+ section so that logs are generated when a process triggers a suspicious -+ 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 -+ by unprivileged users who abuse the auto-loading behavior to -+ cause a vulnerable module to load that is then exploited. -+ -+ If this option prevents a legitimate use of auto-loading for a -+ non-root user, the administrator can execute modprobe manually -+ 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 -+ 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 distribution -+ 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 -+ 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 kernel, -+ 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 prevent -+ an attacker with root access from misusing the RBAC system to hide files -+ 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 time. -+ The lower the number, the harder it will be to brute-force a password. -+ -+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 to -+ authorize to the RBAC system with the maximum number of invalid -+ passwords. The higher the number, the harder it will be to brute-force -+ 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 restriction. -+ Depending upon the option you choose, you can either restrict users to -+ see only the processes they themselves run, or choose a group that can -+ view all processes and files normally restricted to root if you choose -+ 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 here. -+ -+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 own -+ processes, and restricts them from viewing network-related information, -+ 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 -+ 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 of -+ the FIFO is the same owner of the directory it's held in. If the sysctl -+ 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 unprivileged -+ users of the system. Sysfs and debugfs have also become a large source -+ of new vulnerabilities, ranging from infoleaks to local compromise. -+ There has been very little oversight with an eye toward security involved -+ in adding new exporters of information to these filesystems, so their -+ 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 resulting -+ behavior if this option is enabled in an init script on a read-only -+ filesystem. This feature is mainly intended for secure embedded systems. -+ -+config GRKERNSEC_CHROOT -+ bool "Chroot jail restrictions" -+ help -+ If you say Y here, you will be able to choose several options that will -+ 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 chroot -+ 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 -+ option is enabled, a sysctl option with name -+ "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. This -+ 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-chrooted -+ 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 chmod -+ or fchmod files to make them have suid or sgid bits. This protects -+ against another published method of breaking a chroot. If the sysctl -+ 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 directory -+ outside the filesystem will be stopped. If the sysctl option -+ is enabled, a sysctl option with name "chroot_deny_fchdir" is created. -+ -+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 (which -+ they could then use to wipe the drive or steal data). It is recommended -+ 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 attach -+ to shared memory segments that were created outside of the chroot jail. -+ It is recommended that you say Y here. If the sysctl option is enabled, -+ 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 recommended -+ that you say Y here. If the sysctl option is enabled, a sysctl option -+ 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, -+ 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 raise -+ the priority of processes in the chroot, or alter the priority of -+ processes outside the chroot. This provides more security than simply -+ 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 immutable -+ 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 recommended -+ 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 enabled, -+ 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 with -+ name "exec_logging" is created. -+ WARNING: This option when enabled will produce a LOT of logs, especially -+ 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 current -+ 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 logged -+ to syslog. This can cause a large amount of logs if certain -+ applications (eg. djb's daemontools) are installed on the system, and -+ 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 created. -+ -+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 program -+ 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 option -+ 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/<pid>/ipaddr support" -+ help -+ If you say Y here, a new entry will be added to each /proc/<pid> -+ 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 response -+ 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 via -+ 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" is -+ 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 will -+ 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 option -+ with name "tpe_invert" is created. Unlike other sysctl options, this -+ 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 -+ loopback interface from blackholing. Enabling this feature -+ 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 will -+ 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 to -+ 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. -+ -+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 will -+ 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 group -+ you specify will have to use passive mode when initiating ftp transfers -+ from the shell on your machine. If the sysctl option is enabled, a -+ sysctl option with name "socket_client" is created. -+ -+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. -+ -+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 will -+ be unable to run server applications from your machine. If the sysctl -+ option is enabled, a sysctl option with name "socket_server" is created. -+ -+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. -+ -+endmenu -+menu "Sysctl support" -+depends on GRKERNSEC && SYSCTL -+ -+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 entries -+ are mutable until the "grsec_lock" entry is set to a non-zero value. -+ All features enabled in the kernel configuration are disabled at boot -+ 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 should -+ 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* -+ -+ Currently this option creates the following sysctl entries: -+ "Disable Privileged I/O": "disable_priv_io" -+ -+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. -+ -+endmenu -+menu "Logging Options" -+depends on GRKERNSEC -+ -+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 enough -+ to allow informative logs to be produced, but large enough to -+ prevent flooding. -+ -+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 allowed -+ 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. -+ -+endmenu -+ -+endmenu -diff -urNp linux-3.0.9/grsecurity/Makefile linux-3.0.9/grsecurity/Makefile ---- linux-3.0.9/grsecurity/Makefile 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/grsecurity/Makefile 2011-11-12 12:47:14.000000000 -0500 -@@ -0,0 +1,36 @@ -+# grsecurity's ACL system was originally written in 2001 by Michael Dalton -+# 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 released -+# under the GPL v2 or higher -+ -+obj-y = 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 -+ -+obj-$(CONFIG_GRKERNSEC) += 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) += gracl_res.o -+ -+ifdef CONFIG_NET -+obj-y += grsec_sock.o -+obj-$(CONFIG_GRKERNSEC) += gracl_ip.o -+endif -+ -+ifndef CONFIG_GRKERNSEC -+obj-y += grsec_disabled.o -+endif -+ -+ifdef CONFIG_GRKERNSEC_HIDESYM -+extra-y := 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.0.9/include/acpi/acpi_bus.h linux-3.0.9/include/acpi/acpi_bus.h ---- linux-3.0.9/include/acpi/acpi_bus.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/acpi/acpi_bus.h 2011-11-12 12:47:14.000000000 -0500 +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; @@ -57060,9 +58293,10 @@ diff -urNp linux-3.0.9/include/acpi/acpi_bus.h linux-3.0.9/include/acpi/acpi_bus #define ACPI_DRIVER_ALL_NOTIFY_EVENTS 0x1 /* system AND device events */ -diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm-generic/atomic-long.h ---- linux-3.0.9/include/asm-generic/atomic-long.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/atomic-long.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/asm-generic/atomic-long.h b/include/asm-generic/atomic-long.h +index b7babf0..71e4e74 100644 +--- a/include/asm-generic/atomic-long.h ++++ b/include/asm-generic/atomic-long.h @@ -22,6 +22,12 @@ typedef atomic64_t atomic_long_t; @@ -57076,7 +58310,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm #define ATOMIC_LONG_INIT(i) ATOMIC64_INIT(i) 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); } @@ -57092,7 +58326,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_set(atomic_long_t *l, long i) { atomic64_t *v = (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); } @@ -57108,7 +58342,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_inc(atomic_long_t *l) { atomic64_t *v = (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); } @@ -57124,7 +58358,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_dec(atomic_long_t *l) { atomic64_t *v = (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); } @@ -57140,7 +58374,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_add(long i, atomic_long_t *l) { atomic64_t *v = (atomic64_t *)l; -@@ -59,6 +101,15 @@ static inline void atomic_long_add(long +@@ -59,6 +101,15 @@ static inline void atomic_long_add(long i, atomic_long_t *l) atomic64_add(i, v); } @@ -57156,7 +58390,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_sub(long i, atomic_long_t *l) { atomic64_t *v = (atomic64_t *)l; -@@ -66,6 +117,15 @@ static inline void atomic_long_sub(long +@@ -66,6 +117,15 @@ static inline void atomic_long_sub(long i, atomic_long_t *l) atomic64_sub(i, v); } @@ -57172,7 +58406,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline int atomic_long_sub_and_test(long i, atomic_long_t *l) { atomic64_t *v = (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_long_t *l) return (long)atomic64_inc_return(v); } @@ -57188,7 +58422,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline long atomic_long_dec_return(atomic_long_t *l) { atomic64_t *v = (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_long_t *l, long a, long u) typedef atomic_t atomic_long_t; @@ -57201,7 +58435,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/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); } @@ -57217,7 +58451,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_set(atomic_long_t *l, long i) { atomic_t *v = (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); } @@ -57233,7 +58467,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_inc(atomic_long_t *l) { atomic_t *v = (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); } @@ -57249,7 +58483,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_dec(atomic_long_t *l) { atomic_t *v = (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); } @@ -57265,7 +58499,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_add(long i, atomic_long_t *l) { atomic_t *v = (atomic_t *)l; -@@ -176,6 +287,15 @@ static inline void atomic_long_add(long +@@ -176,6 +287,15 @@ static inline void atomic_long_add(long i, atomic_long_t *l) atomic_add(i, v); } @@ -57281,7 +58515,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline void atomic_long_sub(long i, atomic_long_t *l) { atomic_t *v = (atomic_t *)l; -@@ -183,6 +303,15 @@ static inline void atomic_long_sub(long +@@ -183,6 +303,15 @@ static inline void atomic_long_sub(long i, atomic_long_t *l) atomic_sub(i, v); } @@ -57297,7 +58531,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline int atomic_long_sub_and_test(long i, atomic_long_t *l) { atomic_t *v = (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_long_t *l) return (long)atomic_inc_return(v); } @@ -57313,7 +58547,7 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm static inline long atomic_long_dec_return(atomic_long_t *l) { atomic_t *v = (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_long_t *l, long a, long u) #endif /* BITS_PER_LONG == 64 */ @@ -57363,9 +58597,10 @@ diff -urNp linux-3.0.9/include/asm-generic/atomic-long.h linux-3.0.9/include/asm +#endif + #endif /* _ASM_GENERIC_ATOMIC_LONG_H */ -diff -urNp linux-3.0.9/include/asm-generic/cache.h linux-3.0.9/include/asm-generic/cache.h ---- linux-3.0.9/include/asm-generic/cache.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/cache.h 2011-11-12 12:47:14.000000000 -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. */ @@ -57376,9 +58611,10 @@ diff -urNp linux-3.0.9/include/asm-generic/cache.h linux-3.0.9/include/asm-gener +#define L1_CACHE_BYTES (1UL << L1_CACHE_SHIFT) #endif /* __ASM_GENERIC_CACHE_H */ -diff -urNp linux-3.0.9/include/asm-generic/int-l64.h linux-3.0.9/include/asm-generic/int-l64.h ---- linux-3.0.9/include/asm-generic/int-l64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/int-l64.h 2011-11-12 12:47:14.000000000 -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; @@ -57388,9 +58624,10 @@ diff -urNp linux-3.0.9/include/asm-generic/int-l64.h linux-3.0.9/include/asm-gen #define S8_C(x) x #define U8_C(x) x ## U #define S16_C(x) x -diff -urNp linux-3.0.9/include/asm-generic/int-ll64.h linux-3.0.9/include/asm-generic/int-ll64.h ---- linux-3.0.9/include/asm-generic/int-ll64.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/int-ll64.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/asm-generic/int-ll64.h b/include/asm-generic/int-ll64.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; @@ -57400,9 +58637,10 @@ diff -urNp linux-3.0.9/include/asm-generic/int-ll64.h linux-3.0.9/include/asm-ge #define S8_C(x) x #define U8_C(x) x ## U #define S16_C(x) x -diff -urNp linux-3.0.9/include/asm-generic/kmap_types.h linux-3.0.9/include/asm-generic/kmap_types.h ---- linux-3.0.9/include/asm-generic/kmap_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/kmap_types.h 2011-11-12 12:47:14.000000000 -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, @@ -57416,27 +58654,10 @@ diff -urNp linux-3.0.9/include/asm-generic/kmap_types.h linux-3.0.9/include/asm- }; #undef KMAP_D -diff -urNp linux-3.0.9/include/asm-generic/pgtable.h linux-3.0.9/include/asm-generic/pgtable.h ---- linux-3.0.9/include/asm-generic/pgtable.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/pgtable.h 2011-11-12 12:47:14.000000000 -0500 -@@ -443,6 +443,14 @@ static inline int pmd_write(pmd_t pmd) - #endif /* __HAVE_ARCH_PMD_WRITE */ - #endif - -+#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__ */ - - #endif /* _ASM_GENERIC_PGTABLE_H */ -diff -urNp linux-3.0.9/include/asm-generic/pgtable-nopmd.h linux-3.0.9/include/asm-generic/pgtable-nopmd.h ---- linux-3.0.9/include/asm-generic/pgtable-nopmd.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/pgtable-nopmd.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/asm-generic/pgtable-nopmd.h b/include/asm-generic/pgtable-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 @@ -57473,9 +58694,10 @@ diff -urNp linux-3.0.9/include/asm-generic/pgtable-nopmd.h linux-3.0.9/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.0.9/include/asm-generic/pgtable-nopud.h linux-3.0.9/include/asm-generic/pgtable-nopud.h ---- linux-3.0.9/include/asm-generic/pgtable-nopud.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/pgtable-nopud.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/asm-generic/pgtable-nopud.h b/include/asm-generic/pgtable-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 @@ -57506,9 +58728,29 @@ diff -urNp linux-3.0.9/include/asm-generic/pgtable-nopud.h linux-3.0.9/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.0.9/include/asm-generic/vmlinux.lds.h linux-3.0.9/include/asm-generic/vmlinux.lds.h ---- linux-3.0.9/include/asm-generic/vmlinux.lds.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/asm-generic/vmlinux.lds.h 2011-11-12 12:47:14.000000000 -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 + ++#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__ */ + + #endif /* _ASM_GENERIC_PGTABLE_H */ +diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.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) = .; \ @@ -57540,30 +58782,10 @@ diff -urNp linux-3.0.9/include/asm-generic/vmlinux.lds.h linux-3.0.9/include/asm /** * PERCPU_SECTION - define output section for percpu area, simple version -diff -urNp linux-3.0.9/include/drm/drm_crtc_helper.h linux-3.0.9/include/drm/drm_crtc_helper.h ---- linux-3.0.9/include/drm/drm_crtc_helper.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/drm/drm_crtc_helper.h 2011-11-12 12:47:14.000000000 -0500 -@@ -74,7 +74,7 @@ struct drm_crtc_helper_funcs { - - /* disable crtc when not in use - more explicit than dpms off */ - void (*disable)(struct drm_crtc *crtc); --}; -+} __no_const; - - 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; - - struct drm_connector_helper_funcs { - int (*get_modes)(struct drm_connector *connector); -diff -urNp linux-3.0.9/include/drm/drmP.h linux-3.0.9/include/drm/drmP.h ---- linux-3.0.9/include/drm/drmP.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/drm/drmP.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/drm/drmP.h b/include/drm/drmP.h +index 738b3a5..eb6ba6f 100644 +--- a/include/drm/drmP.h ++++ b/include/drm/drmP.h @@ -73,6 +73,7 @@ #include <linux/workqueue.h> #include <linux/poll.h> @@ -57590,9 +58812,32 @@ diff -urNp linux-3.0.9/include/drm/drmP.h linux-3.0.9/include/drm/drmP.h /*@} */ struct list_head filelist; -diff -urNp linux-3.0.9/include/drm/ttm/ttm_memory.h linux-3.0.9/include/drm/ttm/ttm_memory.h ---- linux-3.0.9/include/drm/ttm/ttm_memory.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/drm/ttm/ttm_memory.h 2011-11-12 12:47:14.000000000 -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 { + + /* disable crtc when not in use - more explicit than dpms off */ + void (*disable)(struct drm_crtc *crtc); +-}; ++} __no_const; + + 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; + + 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 @@ struct ttm_mem_shrink { @@ -57602,9 +58847,10 @@ diff -urNp linux-3.0.9/include/drm/ttm/ttm_memory.h linux-3.0.9/include/drm/ttm/ /** * struct ttm_mem_global - Global memory accounting structure. -diff -urNp linux-3.0.9/include/linux/a.out.h linux-3.0.9/include/linux/a.out.h ---- linux-3.0.9/include/linux/a.out.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/a.out.h 2011-11-12 12:47:14.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 = 152 /* MIPS R6000/R4000 binary */ }; @@ -57620,9 +58866,10 @@ diff -urNp linux-3.0.9/include/linux/a.out.h linux-3.0.9/include/linux/a.out.h #if !defined (N_MAGIC) #define N_MAGIC(exec) ((exec).a_info & 0xffff) #endif -diff -urNp linux-3.0.9/include/linux/atmdev.h linux-3.0.9/include/linux/atmdev.h ---- linux-3.0.9/include/linux/atmdev.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/atmdev.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/atmdev.h b/include/linux/atmdev.h +index 381f4ce..6e875a6 100644 +--- a/include/linux/atmdev.h ++++ b/include/linux/atmdev.h @@ -237,7 +237,7 @@ struct compat_atm_iobuf { #endif @@ -57632,9 +58879,10 @@ diff -urNp linux-3.0.9/include/linux/atmdev.h linux-3.0.9/include/linux/atmdev.h __AAL_STAT_ITEMS #undef __HANDLE_ITEM }; -diff -urNp linux-3.0.9/include/linux/binfmts.h linux-3.0.9/include/linux/binfmts.h ---- linux-3.0.9/include/linux/binfmts.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/binfmts.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/binfmts.h b/include/linux/binfmts.h +index 8845613..e36114a 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 *); @@ -57643,9 +58891,10 @@ diff -urNp linux-3.0.9/include/linux/binfmts.h linux-3.0.9/include/linux/binfmts unsigned long min_coredump; /* minimal dump size */ }; -diff -urNp linux-3.0.9/include/linux/blkdev.h linux-3.0.9/include/linux/blkdev.h ---- linux-3.0.9/include/linux/blkdev.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/blkdev.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h +index 1a23722..83a14fd 100644 +--- a/include/linux/blkdev.h ++++ b/include/linux/blkdev.h @@ -1308,7 +1308,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); @@ -57655,9 +58904,10 @@ diff -urNp linux-3.0.9/include/linux/blkdev.h linux-3.0.9/include/linux/blkdev.h extern int __blkdev_driver_ioctl(struct block_device *, fmode_t, unsigned int, unsigned long); -diff -urNp linux-3.0.9/include/linux/blktrace_api.h linux-3.0.9/include/linux/blktrace_api.h ---- linux-3.0.9/include/linux/blktrace_api.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/blktrace_api.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/blktrace_api.h b/include/linux/blktrace_api.h +index 8c7c2de..390e06f 100644 +--- a/include/linux/blktrace_api.h ++++ b/include/linux/blktrace_api.h @@ -161,7 +161,7 @@ struct blk_trace { struct dentry *dir; struct dentry *dropped_file; @@ -57667,9 +58917,10 @@ diff -urNp linux-3.0.9/include/linux/blktrace_api.h linux-3.0.9/include/linux/bl }; extern int blk_trace_ioctl(struct block_device *, unsigned, char __user *); -diff -urNp linux-3.0.9/include/linux/byteorder/little_endian.h linux-3.0.9/include/linux/byteorder/little_endian.h ---- linux-3.0.9/include/linux/byteorder/little_endian.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/byteorder/little_endian.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/byteorder/little_endian.h b/include/linux/byteorder/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 @@ static inline __le64 __cpu_to_le64p(const __u64 *p) @@ -57734,9 +58985,10 @@ diff -urNp linux-3.0.9/include/linux/byteorder/little_endian.h linux-3.0.9/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.0.9/include/linux/cache.h linux-3.0.9/include/linux/cache.h ---- linux-3.0.9/include/linux/cache.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/cache.h 2011-11-12 12:47:14.000000000 -0500 +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 @@ -57748,9 +59000,10 @@ diff -urNp linux-3.0.9/include/linux/cache.h linux-3.0.9/include/linux/cache.h #ifndef ____cacheline_aligned #define ____cacheline_aligned __attribute__((__aligned__(SMP_CACHE_BYTES))) #endif -diff -urNp linux-3.0.9/include/linux/capability.h linux-3.0.9/include/linux/capability.h ---- linux-3.0.9/include/linux/capability.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/capability.h 2011-11-12 12:47:14.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); @@ -57761,9 +59014,10 @@ diff -urNp linux-3.0.9/include/linux/capability.h linux-3.0.9/include/linux/capa /* audit system wants to get cap info from files as well */ extern int get_vfs_caps_from_disk(const struct dentry *dentry, struct cpu_vfs_cap_data *cpu_caps); -diff -urNp linux-3.0.9/include/linux/cleancache.h linux-3.0.9/include/linux/cleancache.h ---- linux-3.0.9/include/linux/cleancache.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/cleancache.h 2011-11-12 12:47:14.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); @@ -57773,9 +59027,10 @@ diff -urNp linux-3.0.9/include/linux/cleancache.h linux-3.0.9/include/linux/clea extern struct cleancache_ops cleancache_register_ops(struct cleancache_ops *ops); -diff -urNp linux-3.0.9/include/linux/compiler-gcc4.h linux-3.0.9/include/linux/compiler-gcc4.h ---- linux-3.0.9/include/linux/compiler-gcc4.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/compiler-gcc4.h 2011-11-12 12:47:14.000000000 -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 @@ @@ -57801,9 +59056,10 @@ diff -urNp linux-3.0.9/include/linux/compiler-gcc4.h linux-3.0.9/include/linux/c #endif #if __GNUC_MINOR__ > 0 -diff -urNp linux-3.0.9/include/linux/compiler.h linux-3.0.9/include/linux/compiler.h ---- linux-3.0.9/include/linux/compiler.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/compiler.h 2011-11-12 12:47:14.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 @@ #ifdef __CHECKER__ @@ -57867,7 +59123,7 @@ diff -urNp linux-3.0.9/include/linux/compiler.h linux-3.0.9/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 +@@ -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 @@ -57877,7 +59133,7 @@ diff -urNp linux-3.0.9/include/linux/compiler.h linux-3.0.9/include/linux/compil #endif #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 @@ -57892,7 +59148,7 @@ diff -urNp linux-3.0.9/include/linux/compiler.h linux-3.0.9/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 @@ -57915,7 +59171,7 @@ diff -urNp linux-3.0.9/include/linux/compiler.h linux-3.0.9/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/NMI * handlers, all running on the same CPU. */ @@ -57924,10 +59180,11 @@ diff -urNp linux-3.0.9/include/linux/compiler.h linux-3.0.9/include/linux/compil +#define ACCESS_ONCE_RW(x) (*(volatile typeof(x) *)&(x)) #endif /* __LINUX_COMPILER_H */ -diff -urNp linux-3.0.9/include/linux/cpuset.h linux-3.0.9/include/linux/cpuset.h ---- linux-3.0.9/include/linux/cpuset.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/cpuset.h 2011-11-12 12:47:14.000000000 -0500 -@@ -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(); @@ -57936,9 +59193,10 @@ diff -urNp linux-3.0.9/include/linux/cpuset.h linux-3.0.9/include/linux/cpuset.h } static inline void set_mems_allowed(nodemask_t nodemask) -diff -urNp linux-3.0.9/include/linux/crypto.h linux-3.0.9/include/linux/crypto.h ---- linux-3.0.9/include/linux/crypto.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/crypto.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/crypto.h b/include/linux/crypto.h +index a6a7a1c..d4364d4 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); @@ -57964,9 +59222,10 @@ diff -urNp linux-3.0.9/include/linux/crypto.h linux-3.0.9/include/linux/crypto.h #define crt_ablkcipher crt_u.ablkcipher #define crt_aead crt_u.aead -diff -urNp linux-3.0.9/include/linux/decompress/mm.h linux-3.0.9/include/linux/decompress/mm.h ---- linux-3.0.9/include/linux/decompress/mm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/decompress/mm.h 2011-11-12 12:47:14.000000000 -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 */ @@ -57976,9 +59235,10 @@ diff -urNp linux-3.0.9/include/linux/decompress/mm.h linux-3.0.9/include/linux/d #define free(a) kfree(a) #define large_malloc(a) vmalloc(a) -diff -urNp linux-3.0.9/include/linux/dma-mapping.h linux-3.0.9/include/linux/dma-mapping.h ---- linux-3.0.9/include/linux/dma-mapping.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/dma-mapping.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h +index ba8319a..10d593f 100644 +--- a/include/linux/dma-mapping.h ++++ b/include/linux/dma-mapping.h @@ -50,7 +50,7 @@ struct dma_map_ops { int (*dma_supported)(struct device *dev, u64 mask); int (*set_dma_mask)(struct device *dev, u64 mask); @@ -57988,9 +59248,10 @@ diff -urNp linux-3.0.9/include/linux/dma-mapping.h linux-3.0.9/include/linux/dma #define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1)) -diff -urNp linux-3.0.9/include/linux/efi.h linux-3.0.9/include/linux/efi.h ---- linux-3.0.9/include/linux/efi.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/efi.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/efi.h b/include/linux/efi.h +index e376270..5c2338b 100644 +--- a/include/linux/efi.h ++++ b/include/linux/efi.h @@ -410,7 +410,7 @@ struct efivar_operations { efi_get_variable_t *get_variable; efi_get_next_variable_t *get_next_variable; @@ -58000,9 +59261,10 @@ diff -urNp linux-3.0.9/include/linux/efi.h linux-3.0.9/include/linux/efi.h struct efivars { /* -diff -urNp linux-3.0.9/include/linux/elf.h linux-3.0.9/include/linux/elf.h ---- linux-3.0.9/include/linux/elf.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/elf.h 2011-11-12 12:47:14.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 @@ -58075,9 +59337,10 @@ diff -urNp linux-3.0.9/include/linux/elf.h linux-3.0.9/include/linux/elf.h #endif -diff -urNp linux-3.0.9/include/linux/firewire.h linux-3.0.9/include/linux/firewire.h ---- linux-3.0.9/include/linux/firewire.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/firewire.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/firewire.h b/include/linux/firewire.h +index 5e6f427..953d4f8 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; @@ -58087,30 +59350,10 @@ diff -urNp linux-3.0.9/include/linux/firewire.h linux-3.0.9/include/linux/firewi void *callback_data; }; -diff -urNp linux-3.0.9/include/linux/fscache-cache.h linux-3.0.9/include/linux/fscache-cache.h ---- linux-3.0.9/include/linux/fscache-cache.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/fscache-cache.h 2011-11-12 12:47:14.000000000 -0500 -@@ -102,7 +102,7 @@ struct fscache_operation { - fscache_operation_release_t release; - }; - --extern atomic_t fscache_op_debug_id; -+extern atomic_unchecked_t fscache_op_debug_id; - extern void fscache_op_work_func(struct work_struct *work); - - extern void fscache_enqueue_operation(struct fscache_operation *); -@@ -122,7 +122,7 @@ static inline void fscache_operation_ini - { - INIT_WORK(&op->work, fscache_op_work_func); - atomic_set(&op->usage, 1); -- op->debug_id = atomic_inc_return(&fscache_op_debug_id); -+ op->debug_id = atomic_inc_return_unchecked(&fscache_op_debug_id); - op->processor = processor; - op->release = release; - INIT_LIST_HEAD(&op->pend_link); -diff -urNp linux-3.0.9/include/linux/fs.h linux-3.0.9/include/linux/fs.h ---- linux-3.0.9/include/linux/fs.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/fs.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/fs.h b/include/linux/fs.h +index b5b9792..caf64ce 100644 +--- a/include/linux/fs.h ++++ b/include/linux/fs.h @@ -109,6 +109,11 @@ struct inodes_stat_t { /* File was opened by fanotify and shouldn't generate fanotify events */ #define FMODE_NONOTIFY ((__force fmode_t)0x1000000) @@ -58133,21 +59376,10 @@ diff -urNp linux-3.0.9/include/linux/fs.h linux-3.0.9/include/linux/fs.h #define IPERM_FLAG_RCU 0x0001 -diff -urNp linux-3.0.9/include/linux/fsnotify.h linux-3.0.9/include/linux/fsnotify.h ---- linux-3.0.9/include/linux/fsnotify.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/fsnotify.h 2011-11-12 12:47:14.000000000 -0500 -@@ -314,7 +314,7 @@ static inline void fsnotify_change(struc - */ - static inline const unsigned char *fsnotify_oldname_init(const unsigned char *name) - { -- return kstrdup(name, GFP_KERNEL); -+ return (const unsigned char *)kstrdup((const char *)name, GFP_KERNEL); - } - - /* -diff -urNp linux-3.0.9/include/linux/fs_struct.h linux-3.0.9/include/linux/fs_struct.h ---- linux-3.0.9/include/linux/fs_struct.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/fs_struct.h 2011-11-12 12:47:14.000000000 -0500 +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 <linux/seqlock.h> @@ -58157,9 +59389,45 @@ diff -urNp linux-3.0.9/include/linux/fs_struct.h linux-3.0.9/include/linux/fs_st spinlock_t lock; seqcount_t seq; int umask; -diff -urNp linux-3.0.9/include/linux/ftrace_event.h linux-3.0.9/include/linux/ftrace_event.h ---- linux-3.0.9/include/linux/ftrace_event.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/ftrace_event.h 2011-11-12 12:47:14.000000000 -0500 +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; + }; + +-extern atomic_t fscache_op_debug_id; ++extern atomic_unchecked_t fscache_op_debug_id; + extern void fscache_op_work_func(struct work_struct *work); + + extern void fscache_enqueue_operation(struct fscache_operation *); +@@ -122,7 +122,7 @@ static inline void fscache_operation_init(struct fscache_operation *op, + { + INIT_WORK(&op->work, fscache_op_work_func); + atomic_set(&op->usage, 1); +- op->debug_id = atomic_inc_return(&fscache_op_debug_id); ++ op->debug_id = atomic_inc_return_unchecked(&fscache_op_debug_id); + op->processor = processor; + op->release = release; + INIT_LIST_HEAD(&op->pend_link); +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 *dentry, unsigned int ia_valid) + */ + static inline const unsigned char *fsnotify_oldname_init(const unsigned char *name) + { +- return kstrdup(name, GFP_KERNEL); ++ return (const unsigned char *)kstrdup((const char *)name, GFP_KERNEL); + } + + /* +diff --git a/include/linux/ftrace_event.h b/include/linux/ftrace_event.h +index 59d3ef1..a581c4f 100644 +--- a/include/linux/ftrace_event.h ++++ b/include/linux/ftrace_event.h @@ -96,7 +96,7 @@ struct trace_event_functions { trace_print_func raw; trace_print_func hex; @@ -58169,7 +59437,7 @@ diff -urNp linux-3.0.9/include/linux/ftrace_event.h linux-3.0.9/include/linux/ft struct trace_event { struct hlist_node node; -@@ -247,7 +247,7 @@ extern int trace_define_field(struct ftr +@@ -247,7 +247,7 @@ extern int trace_define_field(struct ftrace_event_call *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); @@ -58178,9 +59446,10 @@ diff -urNp linux-3.0.9/include/linux/ftrace_event.h linux-3.0.9/include/linux/ft int trace_set_clr_event(const char *system, const char *event, int set); -diff -urNp linux-3.0.9/include/linux/genhd.h linux-3.0.9/include/linux/genhd.h ---- linux-3.0.9/include/linux/genhd.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/genhd.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/genhd.h b/include/linux/genhd.h +index 300d758..3cf72e8 100644 +--- a/include/linux/genhd.h ++++ b/include/linux/genhd.h @@ -184,7 +184,7 @@ struct gendisk { struct kobject *slave_dir; @@ -58190,9 +59459,11 @@ diff -urNp linux-3.0.9/include/linux/genhd.h linux-3.0.9/include/linux/genhd.h struct disk_events *ev; #ifdef CONFIG_BLK_DEV_INTEGRITY struct blk_integrity *integrity; -diff -urNp linux-3.0.9/include/linux/gracl.h linux-3.0.9/include/linux/gracl.h ---- linux-3.0.9/include/linux/gracl.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/gracl.h 2011-11-12 12:47:14.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 @@ -58511,9 +59782,11 @@ diff -urNp linux-3.0.9/include/linux/gracl.h linux-3.0.9/include/linux/gracl.h + +#endif + -diff -urNp linux-3.0.9/include/linux/gralloc.h linux-3.0.9/include/linux/gralloc.h ---- linux-3.0.9/include/linux/gralloc.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/gralloc.h 2011-11-12 12:47:14.000000000 -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 @@ -58524,9 +59797,11 @@ diff -urNp linux-3.0.9/include/linux/gralloc.h linux-3.0.9/include/linux/gralloc +void *acl_alloc_num(unsigned long num, unsigned long len); + +#endif -diff -urNp linux-3.0.9/include/linux/grdefs.h linux-3.0.9/include/linux/grdefs.h ---- linux-3.0.9/include/linux/grdefs.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/grdefs.h 2011-11-12 12:47:14.000000000 -0500 +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 @@ -58668,9 +59943,11 @@ diff -urNp linux-3.0.9/include/linux/grdefs.h linux-3.0.9/include/linux/grdefs.h +}; + +#endif -diff -urNp linux-3.0.9/include/linux/grinternal.h linux-3.0.9/include/linux/grinternal.h ---- linux-3.0.9/include/linux/grinternal.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/grinternal.h 2011-11-12 12:47:14.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 @@ -58892,9 +60169,11 @@ diff -urNp linux-3.0.9/include/linux/grinternal.h linux-3.0.9/include/linux/grin +#endif + +#endif -diff -urNp linux-3.0.9/include/linux/grmsg.h linux-3.0.9/include/linux/grmsg.h ---- linux-3.0.9/include/linux/grmsg.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/grmsg.h 2011-11-12 12:47:14.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/euid:%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" @@ -59004,9 +60283,11 @@ diff -urNp linux-3.0.9/include/linux/grmsg.h linux-3.0.9/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 ptrace by " +#define GR_INIT_TRANSFER_MSG "persistent special role transferred privilege to init by " -diff -urNp linux-3.0.9/include/linux/grsecurity.h linux-3.0.9/include/linux/grsecurity.h ---- linux-3.0.9/include/linux/grsecurity.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/grsecurity.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/grsecurity.h b/include/linux/grsecurity.h +new file mode 100644 +index 0000000..9a067c3 +--- /dev/null ++++ b/include/linux/grsecurity.h @@ -0,0 +1,228 @@ +#ifndef GR_SECURITY_H +#define GR_SECURITY_H @@ -59236,9 +60517,11 @@ diff -urNp linux-3.0.9/include/linux/grsecurity.h linux-3.0.9/include/linux/grse +#endif + +#endif -diff -urNp linux-3.0.9/include/linux/grsock.h linux-3.0.9/include/linux/grsock.h ---- linux-3.0.9/include/linux/grsock.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/grsock.h 2011-11-12 12:47:14.000000000 -0500 +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 @@ -59259,9 +60542,10 @@ diff -urNp linux-3.0.9/include/linux/grsock.h linux-3.0.9/include/linux/grsock.h + const int protocol); + +#endif -diff -urNp linux-3.0.9/include/linux/hid.h linux-3.0.9/include/linux/hid.h ---- linux-3.0.9/include/linux/hid.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/hid.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/hid.h b/include/linux/hid.h +index 42f7e2f..da8098f 100644 +--- a/include/linux/hid.h ++++ b/include/linux/hid.h @@ -675,7 +675,7 @@ struct hid_ll_driver { unsigned int code, int value); @@ -59271,10 +60555,11 @@ diff -urNp linux-3.0.9/include/linux/hid.h linux-3.0.9/include/linux/hid.h #define PM_HINT_FULLON 1<<5 #define PM_HINT_NORMAL 1<<1 -diff -urNp linux-3.0.9/include/linux/highmem.h linux-3.0.9/include/linux/highmem.h ---- linux-3.0.9/include/linux/highmem.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/highmem.h 2011-11-12 12:47:14.000000000 -0500 -@@ -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); } @@ -59293,9 +60578,10 @@ diff -urNp linux-3.0.9/include/linux/highmem.h linux-3.0.9/include/linux/highmem static inline void zero_user_segments(struct page *page, unsigned start1, unsigned end1, unsigned start2, unsigned end2) -diff -urNp linux-3.0.9/include/linux/i2c.h linux-3.0.9/include/linux/i2c.h ---- linux-3.0.9/include/linux/i2c.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/i2c.h 2011-11-12 12:47:14.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 *); @@ -59304,9 +60590,10 @@ diff -urNp linux-3.0.9/include/linux/i2c.h linux-3.0.9/include/linux/i2c.h /* * i2c_adapter is the structure used to identify a physical i2c bus along -diff -urNp linux-3.0.9/include/linux/i2o.h linux-3.0.9/include/linux/i2o.h ---- linux-3.0.9/include/linux/i2o.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/i2o.h 2011-11-12 12:47:14.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 == 64 @@ -59316,10 +60603,11 @@ diff -urNp linux-3.0.9/include/linux/i2o.h linux-3.0.9/include/linux/i2o.h struct list_head context_list; /* list of context id's and pointers */ #endif -diff -urNp linux-3.0.9/include/linux/init.h linux-3.0.9/include/linux/init.h ---- linux-3.0.9/include/linux/init.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/init.h 2011-11-12 12:47:14.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); /* Each module must use one module_init(). */ #define module_init(initfn) \ @@ -59335,9 +60623,10 @@ diff -urNp linux-3.0.9/include/linux/init.h linux-3.0.9/include/linux/init.h { return exitfn; } \ void cleanup_module(void) __attribute__((alias(#exitfn))); -diff -urNp linux-3.0.9/include/linux/init_task.h linux-3.0.9/include/linux/init_task.h ---- linux-3.0.9/include/linux/init_task.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/init_task.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/init_task.h b/include/linux/init_task.h +index 580f70c..7213e59 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 @@ -59359,9 +60648,10 @@ diff -urNp linux-3.0.9/include/linux/init_task.h linux-3.0.9/include/linux/init_ .fs = &init_fs, \ .files = &init_files, \ .signal = &init_signals, \ -diff -urNp linux-3.0.9/include/linux/intel-iommu.h linux-3.0.9/include/linux/intel-iommu.h ---- linux-3.0.9/include/linux/intel-iommu.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/intel-iommu.h 2011-11-12 12:47:14.000000000 -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, @@ -59371,9 +60661,10 @@ diff -urNp linux-3.0.9/include/linux/intel-iommu.h linux-3.0.9/include/linux/int enum { SR_DMAR_FECTL_REG, -diff -urNp linux-3.0.9/include/linux/interrupt.h linux-3.0.9/include/linux/interrupt.h ---- linux-3.0.9/include/linux/interrupt.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/interrupt.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h +index b9490bf..f924abb 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. @@ -59383,7 +60674,7 @@ diff -urNp linux-3.0.9/include/linux/interrupt.h linux-3.0.9/include/linux/inter /* 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]; struct softirq_action { @@ -59398,9 +60689,10 @@ diff -urNp linux-3.0.9/include/linux/interrupt.h linux-3.0.9/include/linux/inter extern void softirq_init(void); static inline void __raise_softirq_irqoff(unsigned int nr) { -diff -urNp linux-3.0.9/include/linux/kallsyms.h linux-3.0.9/include/linux/kallsyms.h ---- linux-3.0.9/include/linux/kallsyms.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/kallsyms.h 2011-11-12 12:47:14.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 @@ struct module; @@ -59411,7 +60703,7 @@ diff -urNp linux-3.0.9/include/linux/kallsyms.h linux-3.0.9/include/linux/kallsy /* Lookup the address for a symbol. Returns 0 if not found. */ unsigned long kallsyms_lookup_name(const char *name); -@@ -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*/ @@ -59428,9 +60720,10 @@ diff -urNp linux-3.0.9/include/linux/kallsyms.h linux-3.0.9/include/linux/kallsy /* This macro allows us to keep printk typechecking */ static void __check_printsym_format(const char *fmt, ...) -diff -urNp linux-3.0.9/include/linux/kgdb.h linux-3.0.9/include/linux/kgdb.h ---- linux-3.0.9/include/linux/kgdb.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/kgdb.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/kgdb.h b/include/linux/kgdb.h +index 10ca03d..b8377b8 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; @@ -59458,10 +60751,11 @@ diff -urNp linux-3.0.9/include/linux/kgdb.h linux-3.0.9/include/linux/kgdb.h extern struct kgdb_arch arch_kgdb_ops; -diff -urNp linux-3.0.9/include/linux/kmod.h linux-3.0.9/include/linux/kmod.h ---- linux-3.0.9/include/linux/kmod.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/kmod.h 2011-11-12 12:47:14.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))); @@ -59470,10 +60764,11 @@ diff -urNp linux-3.0.9/include/linux/kmod.h linux-3.0.9/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.0.9/include/linux/kvm_host.h linux-3.0.9/include/linux/kvm_host.h ---- linux-3.0.9/include/linux/kvm_host.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/kvm_host.h 2011-11-12 12:47:14.000000000 -0500 -@@ -307,7 +307,7 @@ void kvm_vcpu_uninit(struct kvm_vcpu *vc +diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h +index 31ebb59..ac2ba16 100644 +--- a/include/linux/kvm_host.h ++++ b/include/linux/kvm_host.h +@@ -307,7 +307,7 @@ void kvm_vcpu_uninit(struct kvm_vcpu *vcpu); void vcpu_load(struct kvm_vcpu *vcpu); void vcpu_put(struct kvm_vcpu *vcpu); @@ -59482,7 +60777,7 @@ diff -urNp linux-3.0.9/include/linux/kvm_host.h linux-3.0.9/include/linux/kvm_ho struct module *module); void kvm_exit(void); -@@ -446,7 +446,7 @@ int kvm_arch_vcpu_ioctl_set_guest_debug( +@@ -446,7 +446,7 @@ int kvm_arch_vcpu_ioctl_set_guest_debug(struct kvm_vcpu *vcpu, struct kvm_guest_debug *dbg); int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run); @@ -59491,9 +60786,10 @@ diff -urNp linux-3.0.9/include/linux/kvm_host.h linux-3.0.9/include/linux/kvm_ho void kvm_arch_exit(void); int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu); -diff -urNp linux-3.0.9/include/linux/libata.h linux-3.0.9/include/linux/libata.h ---- linux-3.0.9/include/linux/libata.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/libata.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/libata.h b/include/linux/libata.h +index 5a9926b..a65f599 100644 +--- a/include/linux/libata.h ++++ b/include/linux/libata.h @@ -899,7 +899,7 @@ struct ata_port_operations { * fields must be pointers. */ @@ -59503,9 +60799,10 @@ diff -urNp linux-3.0.9/include/linux/libata.h linux-3.0.9/include/linux/libata.h struct ata_port_info { unsigned long flags; -diff -urNp linux-3.0.9/include/linux/mca.h linux-3.0.9/include/linux/mca.h ---- linux-3.0.9/include/linux/mca.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/mca.h 2011-11-12 12:47:14.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 *, @@ -59515,9 +60812,10 @@ diff -urNp linux-3.0.9/include/linux/mca.h linux-3.0.9/include/linux/mca.h struct mca_bus { u64 default_dma_mask; -diff -urNp linux-3.0.9/include/linux/memory.h linux-3.0.9/include/linux/memory.h ---- linux-3.0.9/include/linux/memory.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/memory.h 2011-11-12 12:47:14.000000000 -0500 +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, @@ -59527,9 +60825,10 @@ diff -urNp linux-3.0.9/include/linux/memory.h linux-3.0.9/include/linux/memory.h /* * Kernel text modification mutex, used for code patching. Users of this lock -diff -urNp linux-3.0.9/include/linux/mfd/abx500.h linux-3.0.9/include/linux/mfd/abx500.h ---- linux-3.0.9/include/linux/mfd/abx500.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/mfd/abx500.h 2011-11-12 12:47:14.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); @@ -59538,10 +60837,11 @@ diff -urNp linux-3.0.9/include/linux/mfd/abx500.h linux-3.0.9/include/linux/mfd/ int abx500_register_ops(struct device *core_dev, struct abx500_ops *ops); void abx500_remove_ops(struct device *dev); -diff -urNp linux-3.0.9/include/linux/mm.h linux-3.0.9/include/linux/mm.h ---- linux-3.0.9/include/linux/mm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/mm.h 2011-11-12 12:47:14.000000000 -0500 -@@ -113,7 +113,14 @@ extern unsigned int kobjsize(const void +diff --git a/include/linux/mm.h b/include/linux/mm.h +index 18eea05..9f9aec0 100644 +--- a/include/linux/mm.h ++++ b/include/linux/mm.h +@@ -113,7 +113,14 @@ extern unsigned int kobjsize(const void *objp); #define VM_CAN_NONLINEAR 0x08000000 /* Has ->fault & does nonlinear pages */ #define VM_MIXEDMAP 0x10000000 /* Can contain "struct page" and pure PFN pages */ @@ -59615,7 +60915,7 @@ diff -urNp linux-3.0.9/include/linux/mm.h linux-3.0.9/include/linux/mm.h extern unsigned long do_brk(unsigned long, unsigned long); -@@ -1509,6 +1498,10 @@ extern struct vm_area_struct * find_vma( +@@ -1509,6 +1498,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, unsigned long addr, struct vm_area_struct **pprev); @@ -59626,7 +60926,7 @@ diff -urNp linux-3.0.9/include/linux/mm.h linux-3.0.9/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_struct * mm, unsigned long start_addr, unsigned long end_addr) -@@ -1525,15 +1518,6 @@ static inline unsigned long vma_pages(st +@@ -1525,15 +1518,6 @@ static inline unsigned long vma_pages(struct vm_area_struct *vma) return (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; } @@ -59642,7 +60942,7 @@ diff -urNp linux-3.0.9/include/linux/mm.h linux-3.0.9/include/linux/mm.h struct vm_area_struct *find_extend_vma(struct mm_struct *, unsigned long addr); int remap_pfn_range(struct vm_area_struct *, unsigned long addr, unsigned long pfn, unsigned long size, pgprot_t); -@@ -1646,7 +1630,7 @@ extern int unpoison_memory(unsigned long +@@ -1646,7 +1630,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); @@ -59651,7 +60951,7 @@ diff -urNp linux-3.0.9/include/linux/mm.h linux-3.0.9/include/linux/mm.h extern int soft_offline_page(struct page *page, int flags); extern void dump_page(struct page *page); -@@ -1660,5 +1644,11 @@ extern void copy_user_huge_page(struct p +@@ -1660,5 +1644,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 */ @@ -59663,9 +60963,10 @@ diff -urNp linux-3.0.9/include/linux/mm.h linux-3.0.9/include/linux/mm.h + #endif /* __KERNEL__ */ #endif /* _LINUX_MM_H */ -diff -urNp linux-3.0.9/include/linux/mm_types.h linux-3.0.9/include/linux/mm_types.h ---- linux-3.0.9/include/linux/mm_types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/mm_types.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h +index 059839c..221ca49 100644 +--- a/include/linux/mm_types.h ++++ b/include/linux/mm_types.h @@ -198,6 +198,8 @@ struct vm_area_struct { #ifdef CONFIG_NUMA struct mempolicy *vm_policy; /* NUMA policy for the VMA */ @@ -59700,10 +61001,11 @@ diff -urNp linux-3.0.9/include/linux/mm_types.h linux-3.0.9/include/linux/mm_typ }; static inline void mm_init_cpumask(struct mm_struct *mm) -diff -urNp linux-3.0.9/include/linux/mmu_notifier.h linux-3.0.9/include/linux/mmu_notifier.h ---- linux-3.0.9/include/linux/mmu_notifier.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/mmu_notifier.h 2011-11-12 12:47:14.000000000 -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) \ ({ \ @@ -59719,9 +61021,10 @@ diff -urNp linux-3.0.9/include/linux/mmu_notifier.h linux-3.0.9/include/linux/mm }) #define pmdp_clear_flush_notify(__vma, __address, __pmdp) \ -diff -urNp linux-3.0.9/include/linux/mmzone.h linux-3.0.9/include/linux/mmzone.h ---- linux-3.0.9/include/linux/mmzone.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/mmzone.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h +index 9f7c3eb..6d94953 100644 +--- a/include/linux/mmzone.h ++++ b/include/linux/mmzone.h @@ -350,7 +350,7 @@ struct zone { unsigned long flags; /* zone flags, see below */ @@ -59731,9 +61034,10 @@ diff -urNp linux-3.0.9/include/linux/mmzone.h linux-3.0.9/include/linux/mmzone.h /* * The target ratio of ACTIVE_ANON to INACTIVE_ANON pages on -diff -urNp linux-3.0.9/include/linux/mod_devicetable.h linux-3.0.9/include/linux/mod_devicetable.h ---- linux-3.0.9/include/linux/mod_devicetable.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/mod_devicetable.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicetable.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 @@ -59752,9 +61056,10 @@ diff -urNp linux-3.0.9/include/linux/mod_devicetable.h linux-3.0.9/include/linux struct hid_device_id { __u16 bus; -diff -urNp linux-3.0.9/include/linux/module.h linux-3.0.9/include/linux/module.h ---- linux-3.0.9/include/linux/module.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/module.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/module.h b/include/linux/module.h +index d9ca2d5..ff42270 100644 +--- a/include/linux/module.h ++++ b/include/linux/module.h @@ -16,6 +16,7 @@ #include <linux/kobject.h> #include <linux/moduleparam.h> @@ -59798,7 +61103,7 @@ diff -urNp linux-3.0.9/include/linux/module.h linux-3.0.9/include/linux/module.h #endif #ifdef CONFIG_FTRACE_MCOUNT_RECORD unsigned int num_ftrace_callsites; -@@ -443,16 +445,46 @@ bool is_module_address(unsigned long add +@@ -443,16 +445,46 @@ bool is_module_address(unsigned long addr); bool is_module_percpu_address(unsigned long addr); bool is_module_text_address(unsigned long addr); @@ -59849,10 +61154,11 @@ diff -urNp linux-3.0.9/include/linux/module.h linux-3.0.9/include/linux/module.h } /* Search for module by name: must hold module_mutex. */ -diff -urNp linux-3.0.9/include/linux/moduleloader.h linux-3.0.9/include/linux/moduleloader.h ---- linux-3.0.9/include/linux/moduleloader.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/moduleloader.h 2011-11-12 12:47:14.000000000 -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); @@ -59874,10 +61180,11 @@ diff -urNp linux-3.0.9/include/linux/moduleloader.h linux-3.0.9/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.0.9/include/linux/moduleparam.h linux-3.0.9/include/linux/moduleparam.h ---- linux-3.0.9/include/linux/moduleparam.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/moduleparam.h 2011-11-12 12:47:14.000000000 -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) \ @@ -59886,7 +61193,7 @@ diff -urNp linux-3.0.9/include/linux/moduleparam.h linux-3.0.9/include/linux/mod = { 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 struct kernel_param *kp); * module_param_named() for why this might be necessary. */ #define module_param_array_named(name, array, type, nump, perm) \ @@ -59895,9 +61202,10 @@ diff -urNp linux-3.0.9/include/linux/moduleparam.h linux-3.0.9/include/linux/mod = { .max = ARRAY_SIZE(array), .num = nump, \ .ops = ¶m_ops_##type, \ .elemsize = sizeof(array[0]), .elem = array }; \ -diff -urNp linux-3.0.9/include/linux/namei.h linux-3.0.9/include/linux/namei.h ---- linux-3.0.9/include/linux/namei.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/namei.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/namei.h b/include/linux/namei.h +index 82ab16b..b8b7507 100644 +--- a/include/linux/namei.h ++++ b/include/linux/namei.h @@ -24,7 +24,7 @@ struct nameidata { unsigned seq; int last_type; @@ -59922,9 +61230,10 @@ diff -urNp linux-3.0.9/include/linux/namei.h linux-3.0.9/include/linux/namei.h { return nd->saved_names[nd->depth]; } -diff -urNp linux-3.0.9/include/linux/netdevice.h linux-3.0.9/include/linux/netdevice.h ---- linux-3.0.9/include/linux/netdevice.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/netdevice.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h +index 33b5968..f54dcc2 100644 +--- a/include/linux/netdevice.h ++++ b/include/linux/netdevice.h @@ -979,6 +979,7 @@ struct net_device_ops { int (*ndo_set_features)(struct net_device *dev, u32 features); @@ -59933,9 +61242,11 @@ diff -urNp linux-3.0.9/include/linux/netdevice.h linux-3.0.9/include/linux/netde /* * The DEVICE structure. -diff -urNp linux-3.0.9/include/linux/netfilter/xt_gradm.h linux-3.0.9/include/linux/netfilter/xt_gradm.h ---- linux-3.0.9/include/linux/netfilter/xt_gradm.h 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/include/linux/netfilter/xt_gradm.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/netfilter/xt_gradm.h b/include/linux/netfilter/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 @@ -59946,9 +61257,10 @@ diff -urNp linux-3.0.9/include/linux/netfilter/xt_gradm.h linux-3.0.9/include/li +}; + +#endif -diff -urNp linux-3.0.9/include/linux/of_pdt.h linux-3.0.9/include/linux/of_pdt.h ---- linux-3.0.9/include/linux/of_pdt.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/of_pdt.h 2011-11-12 12:47:14.000000000 -0500 +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 { /* return 0 on success; fill in 'len' with number of bytes in path */ @@ -59958,10 +61270,11 @@ diff -urNp linux-3.0.9/include/linux/of_pdt.h linux-3.0.9/include/linux/of_pdt.h extern void *prom_early_alloc(unsigned long size); -diff -urNp linux-3.0.9/include/linux/oprofile.h linux-3.0.9/include/linux/oprofile.h ---- linux-3.0.9/include/linux/oprofile.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/oprofile.h 2011-11-12 12:47:14.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 7f5cfd3..972690a 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); @@ -59973,9 +61286,10 @@ diff -urNp linux-3.0.9/include/linux/oprofile.h linux-3.0.9/include/linux/oprofi /** create a directory */ struct dentry * oprofilefs_mkdir(struct super_block * sb, struct dentry * root, -diff -urNp linux-3.0.9/include/linux/padata.h linux-3.0.9/include/linux/padata.h ---- linux-3.0.9/include/linux/padata.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/padata.h 2011-11-12 12:47:14.000000000 -0500 +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; @@ -59985,9 +61299,10 @@ diff -urNp linux-3.0.9/include/linux/padata.h linux-3.0.9/include/linux/padata.h atomic_t reorder_objects; atomic_t refcnt; unsigned int max_seq_nr; -diff -urNp linux-3.0.9/include/linux/perf_event.h linux-3.0.9/include/linux/perf_event.h ---- linux-3.0.9/include/linux/perf_event.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/perf_event.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h +index e0786e3..4bd9d78 100644 +--- a/include/linux/perf_event.h ++++ b/include/linux/perf_event.h @@ -761,8 +761,8 @@ struct perf_event { enum perf_event_active_state state; @@ -60010,9 +61325,10 @@ diff -urNp linux-3.0.9/include/linux/perf_event.h linux-3.0.9/include/linux/perf /* * Protect attach/detach and child_list: -diff -urNp linux-3.0.9/include/linux/pipe_fs_i.h linux-3.0.9/include/linux/pipe_fs_i.h ---- linux-3.0.9/include/linux/pipe_fs_i.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/pipe_fs_i.h 2011-11-12 12:47:14.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; @@ -60026,10 +61342,11 @@ diff -urNp linux-3.0.9/include/linux/pipe_fs_i.h linux-3.0.9/include/linux/pipe_ unsigned int r_counter; unsigned int w_counter; struct page *tmp_page; -diff -urNp linux-3.0.9/include/linux/pm_runtime.h linux-3.0.9/include/linux/pm_runtime.h ---- linux-3.0.9/include/linux/pm_runtime.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/pm_runtime.h 2011-11-12 12:47:14.000000000 -0500 -@@ -94,7 +94,7 @@ static inline bool pm_runtime_callbacks_ +diff --git a/include/linux/pm_runtime.h b/include/linux/pm_runtime.h +index 878cf84..cd967ec 100644 +--- a/include/linux/pm_runtime.h ++++ b/include/linux/pm_runtime.h +@@ -94,7 +94,7 @@ static inline bool pm_runtime_callbacks_present(struct device *dev) static inline void pm_runtime_mark_last_busy(struct device *dev) { @@ -60038,9 +61355,10 @@ diff -urNp linux-3.0.9/include/linux/pm_runtime.h linux-3.0.9/include/linux/pm_r } #else /* !CONFIG_PM_RUNTIME */ -diff -urNp linux-3.0.9/include/linux/poison.h linux-3.0.9/include/linux/poison.h ---- linux-3.0.9/include/linux/poison.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/poison.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/poison.h b/include/linux/poison.h +index 2110a81..13a11bb 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. @@ -60052,9 +61370,10 @@ diff -urNp linux-3.0.9/include/linux/poison.h linux-3.0.9/include/linux/poison.h /********** include/linux/timer.h **********/ /* -diff -urNp linux-3.0.9/include/linux/preempt.h linux-3.0.9/include/linux/preempt.h ---- linux-3.0.9/include/linux/preempt.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/preempt.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/preempt.h b/include/linux/preempt.h +index 2e681d9..7f461b6 100644 +--- a/include/linux/preempt.h ++++ b/include/linux/preempt.h @@ -115,7 +115,7 @@ struct preempt_ops { void (*sched_in)(struct preempt_notifier *notifier, int cpu); void (*sched_out)(struct preempt_notifier *notifier, @@ -60064,10 +61383,11 @@ diff -urNp linux-3.0.9/include/linux/preempt.h linux-3.0.9/include/linux/preempt /** * preempt_notifier - key for installing preemption notifiers -diff -urNp linux-3.0.9/include/linux/proc_fs.h linux-3.0.9/include/linux/proc_fs.h ---- linux-3.0.9/include/linux/proc_fs.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/proc_fs.h 2011-11-12 12:47:14.000000000 -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 e7576cf..2453391 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(const char *name, mode_t mode, return proc_create_data(name, mode, parent, proc_fops, NULL); } @@ -60096,10 +61416,11 @@ diff -urNp linux-3.0.9/include/linux/proc_fs.h linux-3.0.9/include/linux/proc_fs struct ctl_table_header; struct ctl_table; -diff -urNp linux-3.0.9/include/linux/ptrace.h linux-3.0.9/include/linux/ptrace.h ---- linux-3.0.9/include/linux/ptrace.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/ptrace.h 2011-11-12 12:47:14.000000000 -0500 -@@ -115,10 +115,10 @@ extern void __ptrace_unlink(struct task_ +diff --git a/include/linux/ptrace.h b/include/linux/ptrace.h +index 9178d5c..ff0a136 100644 +--- a/include/linux/ptrace.h ++++ b/include/linux/ptrace.h +@@ -115,10 +115,10 @@ extern void __ptrace_unlink(struct task_struct *child); extern void exit_ptrace(struct task_struct *tracer); #define PTRACE_MODE_READ 1 #define PTRACE_MODE_ATTACH 2 @@ -60112,9 +61433,10 @@ diff -urNp linux-3.0.9/include/linux/ptrace.h linux-3.0.9/include/linux/ptrace.h static inline int ptrace_reparented(struct task_struct *child) { -diff -urNp linux-3.0.9/include/linux/random.h linux-3.0.9/include/linux/random.h ---- linux-3.0.9/include/linux/random.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/random.h 2011-11-12 12:47:14.000000000 -0500 +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); u32 prandom32(struct rnd_state *); @@ -60134,10 +61456,11 @@ diff -urNp linux-3.0.9/include/linux/random.h linux-3.0.9/include/linux/random.h } /** -diff -urNp linux-3.0.9/include/linux/reboot.h linux-3.0.9/include/linux/reboot.h ---- linux-3.0.9/include/linux/reboot.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/reboot.h 2011-11-12 12:47:14.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 3005d5a..77c2dba 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. */ @@ -60150,7 +61473,7 @@ diff -urNp linux-3.0.9/include/linux/reboot.h linux-3.0.9/include/linux/reboot.h 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 *); */ extern void kernel_restart_prepare(char *cmd); @@ -60172,10 +61495,11 @@ diff -urNp linux-3.0.9/include/linux/reboot.h linux-3.0.9/include/linux/reboot.h #include <asm/emergency-restart.h> #endif -diff -urNp linux-3.0.9/include/linux/reiserfs_fs.h linux-3.0.9/include/linux/reiserfs_fs.h ---- linux-3.0.9/include/linux/reiserfs_fs.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/reiserfs_fs.h 2011-11-12 12:47:14.000000000 -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 eca75df..97897d4 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 inode *inode) #define REISERFS_USER_MEM 1 /* reiserfs user memory mode */ #define fs_generation(s) (REISERFS_SB(s)->s_generation_counter) @@ -60184,9 +61508,10 @@ diff -urNp linux-3.0.9/include/linux/reiserfs_fs.h linux-3.0.9/include/linux/rei #define FILESYSTEM_CHANGED_TB(tb) (get_generation((tb)->tb_sb) != (tb)->fs_gen) #define __fs_changed(gen,s) (gen != get_generation (s)) #define fs_changed(gen,s) \ -diff -urNp linux-3.0.9/include/linux/reiserfs_fs_sb.h linux-3.0.9/include/linux/reiserfs_fs_sb.h ---- linux-3.0.9/include/linux/reiserfs_fs_sb.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/reiserfs_fs_sb.h 2011-11-12 12:47:14.000000000 -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; @@ -60196,9 +61521,10 @@ diff -urNp linux-3.0.9/include/linux/reiserfs_fs_sb.h linux-3.0.9/include/linux/ // tree gets re-balanced unsigned long s_properties; /* File system properties. Currently holds on-disk FS format */ -diff -urNp linux-3.0.9/include/linux/relay.h linux-3.0.9/include/linux/relay.h ---- linux-3.0.9/include/linux/relay.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/relay.h 2011-11-12 12:47:14.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. */ @@ -60208,9 +61534,10 @@ diff -urNp linux-3.0.9/include/linux/relay.h linux-3.0.9/include/linux/relay.h /* * CONFIG_RELAY kernel API, kernel/relay.c -diff -urNp linux-3.0.9/include/linux/rfkill.h linux-3.0.9/include/linux/rfkill.h ---- linux-3.0.9/include/linux/rfkill.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/rfkill.h 2011-11-12 12:47:14.000000000 -0500 +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); @@ -60219,10 +61546,11 @@ diff -urNp linux-3.0.9/include/linux/rfkill.h linux-3.0.9/include/linux/rfkill.h #if defined(CONFIG_RFKILL) || defined(CONFIG_RFKILL_MODULE) /** -diff -urNp linux-3.0.9/include/linux/rmap.h linux-3.0.9/include/linux/rmap.h ---- linux-3.0.9/include/linux/rmap.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/rmap.h 2011-11-12 12:47:14.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 *); @@ -60233,9 +61561,10 @@ diff -urNp linux-3.0.9/include/linux/rmap.h linux-3.0.9/include/linux/rmap.h void __anon_vma_link(struct vm_area_struct *); static inline void anon_vma_merge(struct vm_area_struct *vma, -diff -urNp linux-3.0.9/include/linux/sched.h linux-3.0.9/include/linux/sched.h ---- linux-3.0.9/include/linux/sched.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/sched.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/sched.h b/include/linux/sched.h +index 4ef452b..f9c902f 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; @@ -60422,7 +61751,7 @@ diff -urNp linux-3.0.9/include/linux/sched.h linux-3.0.9/include/linux/sched.h /* Future-safe accessor for struct task_struct's cpus_allowed. */ #define tsk_cpus_allowed(tsk) (&(tsk)->cpus_allowed) -@@ -1768,6 +1860,7 @@ extern void thread_group_times(struct ta +@@ -1768,6 +1860,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 */ @@ -60448,7 +61777,7 @@ diff -urNp linux-3.0.9/include/linux/sched.h linux-3.0.9/include/linux/sched.h extern struct task_struct *find_task_by_pid_ns(pid_t nr, struct pid_namespace *ns); -@@ -2224,7 +2320,7 @@ extern void __cleanup_sighand(struct sig +@@ -2224,7 +2320,7 @@ extern void __cleanup_sighand(struct sighand_struct *); extern void exit_itimers(struct signal_struct *); extern void flush_itimer_signals(void); @@ -60457,7 +61786,7 @@ diff -urNp linux-3.0.9/include/linux/sched.h linux-3.0.9/include/linux/sched.h extern void daemonize(const char *, ...); extern int allow_signal(int); -@@ -2392,13 +2488,17 @@ static inline unsigned long *end_of_stac +@@ -2392,13 +2488,17 @@ static inline unsigned long *end_of_stack(struct task_struct *p) #endif @@ -60477,9 +61806,10 @@ diff -urNp linux-3.0.9/include/linux/sched.h linux-3.0.9/include/linux/sched.h extern void thread_info_cache_init(void); #ifdef CONFIG_DEBUG_STACK_USAGE -diff -urNp linux-3.0.9/include/linux/screen_info.h linux-3.0.9/include/linux/screen_info.h ---- linux-3.0.9/include/linux/screen_info.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/screen_info.h 2011-11-12 12:47:14.000000000 -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 */ @@ -60490,9 +61820,10 @@ diff -urNp linux-3.0.9/include/linux/screen_info.h linux-3.0.9/include/linux/scr } __attribute__((packed)); #define VIDEO_TYPE_MDA 0x10 /* Monochrome Text Display */ -diff -urNp linux-3.0.9/include/linux/security.h linux-3.0.9/include/linux/security.h ---- linux-3.0.9/include/linux/security.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/security.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/security.h b/include/linux/security.h +index 8ce59ef..09f5fc3 100644 +--- a/include/linux/security.h ++++ b/include/linux/security.h @@ -36,6 +36,7 @@ #include <linux/key.h> #include <linux/xfrm.h> @@ -60501,9 +61832,10 @@ diff -urNp linux-3.0.9/include/linux/security.h linux-3.0.9/include/linux/securi #include <net/flow.h> /* Maximum number of letters for an LSM name string */ -diff -urNp linux-3.0.9/include/linux/seq_file.h linux-3.0.9/include/linux/seq_file.h ---- linux-3.0.9/include/linux/seq_file.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/seq_file.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/seq_file.h b/include/linux/seq_file.h +index 03c0232..54a4671 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); @@ -60512,22 +61844,11 @@ diff -urNp linux-3.0.9/include/linux/seq_file.h linux-3.0.9/include/linux/seq_fi #define SEQ_SKIP 1 -diff -urNp linux-3.0.9/include/linux/shmem_fs.h linux-3.0.9/include/linux/shmem_fs.h ---- linux-3.0.9/include/linux/shmem_fs.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/shmem_fs.h 2011-11-12 12:47:14.000000000 -0500 -@@ -10,7 +10,7 @@ - - #define SHMEM_NR_DIRECT 16 - --#define SHMEM_SYMLINK_INLINE_LEN (SHMEM_NR_DIRECT * sizeof(swp_entry_t)) -+#define SHMEM_SYMLINK_INLINE_LEN 64 - - struct shmem_inode_info { - spinlock_t lock; -diff -urNp linux-3.0.9/include/linux/shm.h linux-3.0.9/include/linux/shm.h ---- linux-3.0.9/include/linux/shm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/shm.h 2011-11-12 12:47:14.000000000 -0500 -@@ -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; @@ -60538,10 +61859,24 @@ diff -urNp linux-3.0.9/include/linux/shm.h linux-3.0.9/include/linux/shm.h }; /* shm_mode upper byte flags */ -diff -urNp linux-3.0.9/include/linux/skbuff.h linux-3.0.9/include/linux/skbuff.h ---- linux-3.0.9/include/linux/skbuff.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/skbuff.h 2011-11-12 12:47:14.000000000 -0500 -@@ -592,7 +592,7 @@ static inline struct skb_shared_hwtstamp +diff --git a/include/linux/shmem_fs.h b/include/linux/shmem_fs.h +index aa08fa8..a533701 100644 +--- a/include/linux/shmem_fs.h ++++ b/include/linux/shmem_fs.h +@@ -10,7 +10,7 @@ + + #define SHMEM_NR_DIRECT 16 + +-#define SHMEM_SYMLINK_INLINE_LEN (SHMEM_NR_DIRECT * sizeof(swp_entry_t)) ++#define SHMEM_SYMLINK_INLINE_LEN 64 + + struct shmem_inode_info { + spinlock_t lock; +diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h +index b920a72..05c678b 100644 +--- a/include/linux/skbuff.h ++++ b/include/linux/skbuff.h +@@ -592,7 +592,7 @@ static inline struct skb_shared_hwtstamps *skb_hwtstamps(struct sk_buff *skb) */ static inline int skb_queue_empty(const struct sk_buff_head *list) { @@ -60550,7 +61885,7 @@ diff -urNp linux-3.0.9/include/linux/skbuff.h linux-3.0.9/include/linux/skbuff.h } /** -@@ -605,7 +605,7 @@ static inline int skb_queue_empty(const +@@ -605,7 +605,7 @@ static inline int skb_queue_empty(const struct sk_buff_head *list) static inline bool skb_queue_is_last(const struct sk_buff_head *list, const struct sk_buff *skb) { @@ -60559,7 +61894,7 @@ diff -urNp linux-3.0.9/include/linux/skbuff.h linux-3.0.9/include/linux/skbuff.h } /** -@@ -618,7 +618,7 @@ static inline bool skb_queue_is_last(con +@@ -618,7 +618,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) { @@ -60568,7 +61903,7 @@ diff -urNp linux-3.0.9/include/linux/skbuff.h linux-3.0.9/include/linux/skbuff.h } /** -@@ -1440,7 +1440,7 @@ static inline int pskb_network_may_pull( +@@ -1440,7 +1440,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 @@ -60577,27 +61912,10 @@ diff -urNp linux-3.0.9/include/linux/skbuff.h linux-3.0.9/include/linux/skbuff.h #endif extern int ___pskb_trim(struct sk_buff *skb, unsigned int len); -diff -urNp linux-3.0.9/include/linux/slab_def.h linux-3.0.9/include/linux/slab_def.h ---- linux-3.0.9/include/linux/slab_def.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/slab_def.h 2011-11-12 12:47:14.000000000 -0500 -@@ -96,10 +96,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; - - /* - * If debugging is enabled, then the allocator can add additional -diff -urNp linux-3.0.9/include/linux/slab.h linux-3.0.9/include/linux/slab.h ---- linux-3.0.9/include/linux/slab.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/slab.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/slab.h b/include/linux/slab.h +index ad4dd1c..0e42601 100644 +--- a/include/linux/slab.h ++++ b/include/linux/slab.h @@ -11,12 +11,20 @@ #include <linux/gfp.h> @@ -60636,7 +61954,7 @@ diff -urNp linux-3.0.9/include/linux/slab.h linux-3.0.9/include/linux/slab.h /* * struct kmem_cache related prototypes -@@ -141,6 +152,7 @@ void * __must_check krealloc(const void +@@ -141,6 +152,7 @@ void * __must_check krealloc(const void *, size_t, gfp_t); void kfree(const void *); void kzfree(const void *); size_t ksize(const void *); @@ -60644,7 +61962,7 @@ diff -urNp linux-3.0.9/include/linux/slab.h linux-3.0.9/include/linux/slab.h /* * Allocator specific definitions. These are mainly used to establish optimized -@@ -333,4 +345,59 @@ static inline void *kzalloc_node(size_t +@@ -333,4 +345,59 @@ static inline void *kzalloc_node(size_t size, gfp_t flags, int node) void __init kmem_cache_init_late(void); @@ -60704,9 +62022,29 @@ diff -urNp linux-3.0.9/include/linux/slab.h linux-3.0.9/include/linux/slab.h +}) + #endif /* _LINUX_SLAB_H */ -diff -urNp linux-3.0.9/include/linux/slub_def.h linux-3.0.9/include/linux/slub_def.h ---- linux-3.0.9/include/linux/slub_def.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/slub_def.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/slab_def.h b/include/linux/slab_def.h +index 83203ae..855726b 100644 +--- a/include/linux/slab_def.h ++++ b/include/linux/slab_def.h +@@ -96,10 +96,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; + + /* + * 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 c8668d1..39dd7c2 100644 +--- a/include/linux/slub_def.h ++++ b/include/linux/slub_def.h @@ -82,7 +82,7 @@ struct kmem_cache { struct kmem_cache_order_objects max; struct kmem_cache_order_objects min; @@ -60716,7 +62054,7 @@ diff -urNp linux-3.0.9/include/linux/slub_def.h linux-3.0.9/include/linux/slub_d void (*ctor)(void *); int inuse; /* Offset to metadata */ int align; /* Alignment */ -@@ -218,7 +218,7 @@ static __always_inline struct kmem_cache +@@ -218,7 +218,7 @@ static __always_inline struct kmem_cache *kmalloc_slab(size_t size) } void *kmem_cache_alloc(struct kmem_cache *, gfp_t); @@ -60725,9 +62063,10 @@ diff -urNp linux-3.0.9/include/linux/slub_def.h linux-3.0.9/include/linux/slub_d static __always_inline void * kmalloc_order(size_t size, gfp_t flags, unsigned int order) -diff -urNp linux-3.0.9/include/linux/sonet.h linux-3.0.9/include/linux/sonet.h ---- linux-3.0.9/include/linux/sonet.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/sonet.h 2011-11-12 12:47:14.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 <asm/atomic.h> @@ -60737,10 +62076,11 @@ diff -urNp linux-3.0.9/include/linux/sonet.h linux-3.0.9/include/linux/sonet.h __SONET_ITEMS #undef __HANDLE_ITEM }; -diff -urNp linux-3.0.9/include/linux/sunrpc/clnt.h linux-3.0.9/include/linux/sunrpc/clnt.h ---- linux-3.0.9/include/linux/sunrpc/clnt.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/sunrpc/clnt.h 2011-11-12 12:47:14.000000000 -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 struct sockaddr *sap) { switch (sap->sa_family) { case AF_INET: @@ -60752,7 +62092,7 @@ diff -urNp linux-3.0.9/include/linux/sunrpc/clnt.h linux-3.0.9/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 sockaddr *sap1, static inline bool __rpc_copy_addr4(struct sockaddr *dst, const struct sockaddr *src) { @@ -60761,7 +62101,7 @@ diff -urNp linux-3.0.9/include/linux/sunrpc/clnt.h linux-3.0.9/include/linux/sun struct sockaddr_in *dsin = (struct sockaddr_in *) dst; dsin->sin_family = 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 sockaddr *sa) if (sa->sa_family != AF_INET6) return 0; @@ -60770,9 +62110,10 @@ diff -urNp linux-3.0.9/include/linux/sunrpc/clnt.h linux-3.0.9/include/linux/sun } #endif /* __KERNEL__ */ -diff -urNp linux-3.0.9/include/linux/sunrpc/svc_rdma.h linux-3.0.9/include/linux/sunrpc/svc_rdma.h ---- linux-3.0.9/include/linux/sunrpc/svc_rdma.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/sunrpc/svc_rdma.h 2011-11-12 12:47:14.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; @@ -60798,9 +62139,10 @@ diff -urNp linux-3.0.9/include/linux/sunrpc/svc_rdma.h linux-3.0.9/include/linux #define RPCRDMA_VERSION 1 -diff -urNp linux-3.0.9/include/linux/sysctl.h linux-3.0.9/include/linux/sysctl.h ---- linux-3.0.9/include/linux/sysctl.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/sysctl.h 2011-11-12 12:47:14.000000000 -0500 +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=76, /* int: whether we will panic on an unrecovered */ }; @@ -60814,7 +62156,7 @@ diff -urNp linux-3.0.9/include/linux/sysctl.h linux-3.0.9/include/linux/sysctl.h /* 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, extern int proc_dostring(struct ctl_table *, int, void __user *, size_t *, loff_t *); @@ -60823,9 +62165,10 @@ diff -urNp linux-3.0.9/include/linux/sysctl.h linux-3.0.9/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.0.9/include/linux/tty_ldisc.h linux-3.0.9/include/linux/tty_ldisc.h ---- linux-3.0.9/include/linux/tty_ldisc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/tty_ldisc.h 2011-11-12 12:47:14.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 { struct module *owner; @@ -60835,9 +62178,10 @@ diff -urNp linux-3.0.9/include/linux/tty_ldisc.h linux-3.0.9/include/linux/tty_l }; struct tty_ldisc { -diff -urNp linux-3.0.9/include/linux/types.h linux-3.0.9/include/linux/types.h ---- linux-3.0.9/include/linux/types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/types.h 2011-11-12 12:47:14.000000000 -0500 +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; @@ -60865,10 +62209,11 @@ diff -urNp linux-3.0.9/include/linux/types.h linux-3.0.9/include/linux/types.h #endif struct list_head { -diff -urNp linux-3.0.9/include/linux/uaccess.h linux-3.0.9/include/linux/uaccess.h ---- linux-3.0.9/include/linux/uaccess.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/uaccess.h 2011-11-12 12:47:14.000000000 -0500 -@@ -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 = get_fs(); \ \ @@ -60883,9 +62228,10 @@ diff -urNp linux-3.0.9/include/linux/uaccess.h linux-3.0.9/include/linux/uaccess ret; \ }) -diff -urNp linux-3.0.9/include/linux/unaligned/access_ok.h linux-3.0.9/include/linux/unaligned/access_ok.h ---- linux-3.0.9/include/linux/unaligned/access_ok.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/unaligned/access_ok.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/unaligned/access_ok.h b/include/linux/unaligned/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 @@ static inline u16 get_unaligned_le16(const void *p) @@ -60925,9 +62271,10 @@ diff -urNp linux-3.0.9/include/linux/unaligned/access_ok.h linux-3.0.9/include/l } static inline void put_unaligned_le16(u16 val, void *p) -diff -urNp linux-3.0.9/include/linux/vermagic.h linux-3.0.9/include/linux/vermagic.h ---- linux-3.0.9/include/linux/vermagic.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/vermagic.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/linux/vermagic.h b/include/linux/vermagic.h +index cf97b5b..64d2a0a 100644 +--- a/include/linux/vermagic.h ++++ b/include/linux/vermagic.h @@ -26,9 +26,28 @@ #define MODULE_ARCH_VERMAGIC "" #endif @@ -60958,10 +62305,11 @@ diff -urNp linux-3.0.9/include/linux/vermagic.h linux-3.0.9/include/linux/vermag + MODULE_ARCH_VERMAGIC \ + MODULE_PAX_REFCOUNT MODULE_CONSTIFY_PLUGIN MODULE_GRSEC -diff -urNp linux-3.0.9/include/linux/vmalloc.h linux-3.0.9/include/linux/vmalloc.h ---- linux-3.0.9/include/linux/vmalloc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/vmalloc.h 2011-11-12 13:08:20.000000000 -0500 -@@ -14,6 +14,11 @@ struct vm_area_struct; /* vma defining +diff --git a/include/linux/vmalloc.h b/include/linux/vmalloc.h +index 687fb11..546e710 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 */ @@ -60973,7 +62321,7 @@ diff -urNp linux-3.0.9/include/linux/vmalloc.h linux-3.0.9/include/linux/vmalloc /* bits [20..32] reserved for arch specific ioremap internals */ /* -@@ -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 @@ -61077,10 +62425,11 @@ diff -urNp linux-3.0.9/include/linux/vmalloc.h linux-3.0.9/include/linux/vmalloc +}) + #endif /* _LINUX_VMALLOC_H */ -diff -urNp linux-3.0.9/include/linux/vmstat.h linux-3.0.9/include/linux/vmstat.h ---- linux-3.0.9/include/linux/vmstat.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/linux/vmstat.h 2011-11-12 12:47:14.000000000 -0500 -@@ -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 bcd942f..729957b 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. */ @@ -61103,7 +62452,7 @@ diff -urNp linux-3.0.9/include/linux/vmstat.h linux-3.0.9/include/linux/vmstat.h #ifdef CONFIG_SMP if (x < 0) x = 0; -@@ -109,7 +109,7 @@ static inline unsigned long global_page_ +@@ -109,7 +109,7 @@ static inline unsigned long global_page_state(enum zone_stat_item item) static inline unsigned long zone_page_state(struct zone *zone, enum zone_stat_item item) { @@ -61112,7 +62461,7 @@ diff -urNp linux-3.0.9/include/linux/vmstat.h linux-3.0.9/include/linux/vmstat.h #ifdef CONFIG_SMP if (x < 0) x = 0; -@@ -126,7 +126,7 @@ static inline unsigned long zone_page_st +@@ -126,7 +126,7 @@ static inline unsigned long zone_page_state(struct zone *zone, static inline unsigned long zone_page_state_snapshot(struct zone *zone, enum zone_stat_item item) { @@ -61121,7 +62470,7 @@ diff -urNp linux-3.0.9/include/linux/vmstat.h linux-3.0.9/include/linux/vmstat.h #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, static inline void __inc_zone_state(struct zone *zone, enum zone_stat_item item) { @@ -61132,7 +62481,7 @@ diff -urNp linux-3.0.9/include/linux/vmstat.h linux-3.0.9/include/linux/vmstat.h } 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, static inline void __dec_zone_state(struct zone *zone, enum zone_stat_item item) { @@ -61143,9 +62492,10 @@ diff -urNp linux-3.0.9/include/linux/vmstat.h linux-3.0.9/include/linux/vmstat.h } static inline void __dec_zone_page_state(struct page *page, -diff -urNp linux-3.0.9/include/media/saa7146_vv.h linux-3.0.9/include/media/saa7146_vv.h ---- linux-3.0.9/include/media/saa7146_vv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/media/saa7146_vv.h 2011-11-12 12:47:14.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 *); @@ -61155,10 +62505,11 @@ diff -urNp linux-3.0.9/include/media/saa7146_vv.h linux-3.0.9/include/media/saa7 /* pointer to the saa7146 core ops */ const struct v4l2_ioctl_ops *core_ops; -diff -urNp linux-3.0.9/include/media/v4l2-dev.h linux-3.0.9/include/media/v4l2-dev.h ---- linux-3.0.9/include/media/v4l2-dev.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/media/v4l2-dev.h 2011-11-12 12:47:14.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, enum v4l2_priority local); struct v4l2_file_operations { @@ -61175,9 +62526,10 @@ diff -urNp linux-3.0.9/include/media/v4l2-dev.h linux-3.0.9/include/media/v4l2-d /* * Newer version of video_device, handled by videodev2.c -diff -urNp linux-3.0.9/include/media/v4l2-ioctl.h linux-3.0.9/include/media/v4l2-ioctl.h ---- linux-3.0.9/include/media/v4l2-ioctl.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/media/v4l2-ioctl.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/media/v4l2-ioctl.h b/include/media/v4l2-ioctl.h +index dd9f1e7..6376334 100644 +--- a/include/media/v4l2-ioctl.h ++++ b/include/media/v4l2-ioctl.h @@ -272,6 +272,7 @@ struct v4l2_ioctl_ops { long (*vidioc_default) (struct file *file, void *fh, bool valid_prio, int cmd, void *arg); @@ -61186,9 +62538,10 @@ diff -urNp linux-3.0.9/include/media/v4l2-ioctl.h linux-3.0.9/include/media/v4l2 /* v4l debugging and diagnostics */ -diff -urNp linux-3.0.9/include/net/caif/cfctrl.h linux-3.0.9/include/net/caif/cfctrl.h ---- linux-3.0.9/include/net/caif/cfctrl.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/caif/cfctrl.h 2011-11-12 12:47:14.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, @@ -61209,10 +62562,11 @@ diff -urNp linux-3.0.9/include/net/caif/cfctrl.h linux-3.0.9/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.0.9/include/net/flow.h linux-3.0.9/include/net/flow.h ---- linux-3.0.9/include/net/flow.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/flow.h 2011-11-12 12:47:14.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 32359fd..684c65f 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); extern void flow_cache_flush(void); @@ -61220,9 +62574,10 @@ diff -urNp linux-3.0.9/include/net/flow.h linux-3.0.9/include/net/flow.h +extern atomic_unchecked_t flow_cache_genid; #endif -diff -urNp linux-3.0.9/include/net/inetpeer.h linux-3.0.9/include/net/inetpeer.h ---- linux-3.0.9/include/net/inetpeer.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/inetpeer.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/net/inetpeer.h b/include/net/inetpeer.h +index 8a159cc..0defcc9 100644 +--- a/include/net/inetpeer.h ++++ b/include/net/inetpeer.h @@ -43,8 +43,8 @@ struct inet_peer { */ union { @@ -61234,7 +62589,7 @@ diff -urNp linux-3.0.9/include/net/inetpeer.h linux-3.0.9/include/net/inetpeer.h __u32 tcp_ts; __u32 tcp_ts_stamp; u32 metrics[RTAX_MAX]; -@@ -108,7 +108,7 @@ static inline __u16 inet_getid(struct in +@@ -108,7 +108,7 @@ static inline __u16 inet_getid(struct inet_peer *p, int more) { more++; inet_peer_refcheck(p); @@ -61243,10 +62598,11 @@ diff -urNp linux-3.0.9/include/net/inetpeer.h linux-3.0.9/include/net/inetpeer.h } #endif /* _NET_INETPEER_H */ -diff -urNp linux-3.0.9/include/net/ip_fib.h linux-3.0.9/include/net/ip_fib.h ---- linux-3.0.9/include/net/ip_fib.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/ip_fib.h 2011-11-12 12:47:14.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 *net, struct fib_nh *nh); #define FIB_RES_SADDR(net, res) \ ((FIB_RES_NH(res).nh_saddr_genid == \ @@ -61255,9 +62611,10 @@ diff -urNp linux-3.0.9/include/net/ip_fib.h linux-3.0.9/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.0.9/include/net/ip_vs.h linux-3.0.9/include/net/ip_vs.h ---- linux-3.0.9/include/net/ip_vs.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/ip_vs.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h +index 481f856..1cc73c4 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 */ @@ -61276,9 +62633,10 @@ diff -urNp linux-3.0.9/include/net/ip_vs.h linux-3.0.9/include/net/ip_vs.h atomic_t weight; /* server weight */ atomic_t refcnt; /* reference counter */ -diff -urNp linux-3.0.9/include/net/irda/ircomm_core.h linux-3.0.9/include/net/irda/ircomm_core.h ---- linux-3.0.9/include/net/irda/ircomm_core.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/irda/ircomm_core.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/net/irda/ircomm_core.h b/include/net/irda/ircomm_core.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 *, @@ -61288,9 +62646,10 @@ diff -urNp linux-3.0.9/include/net/irda/ircomm_core.h linux-3.0.9/include/net/ir struct ircomm_cb { irda_queue_t queue; -diff -urNp linux-3.0.9/include/net/irda/ircomm_tty.h linux-3.0.9/include/net/irda/ircomm_tty.h ---- linux-3.0.9/include/net/irda/ircomm_tty.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/irda/ircomm_tty.h 2011-11-12 12:47:14.000000000 -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 <linux/termios.h> #include <linux/timer.h> @@ -61310,9 +62669,10 @@ diff -urNp linux-3.0.9/include/net/irda/ircomm_tty.h linux-3.0.9/include/net/ird /* Protect concurent access to : * o self->open_count -diff -urNp linux-3.0.9/include/net/iucv/af_iucv.h linux-3.0.9/include/net/iucv/af_iucv.h ---- linux-3.0.9/include/net/iucv/af_iucv.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/iucv/af_iucv.h 2011-11-12 12:47:14.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; @@ -61322,9 +62682,10 @@ diff -urNp linux-3.0.9/include/net/iucv/af_iucv.h linux-3.0.9/include/net/iucv/a }; unsigned int iucv_sock_poll(struct file *file, struct socket *sock, -diff -urNp linux-3.0.9/include/net/lapb.h linux-3.0.9/include/net/lapb.h ---- linux-3.0.9/include/net/lapb.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/lapb.h 2011-11-12 12:47:14.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; @@ -61334,9 +62695,10 @@ diff -urNp linux-3.0.9/include/net/lapb.h linux-3.0.9/include/net/lapb.h /* FRMR control information */ struct lapb_frame frmr_data; -diff -urNp linux-3.0.9/include/net/neighbour.h linux-3.0.9/include/net/neighbour.h ---- linux-3.0.9/include/net/neighbour.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/neighbour.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/net/neighbour.h b/include/net/neighbour.h +index 4014b62..b68661b 100644 +--- a/include/net/neighbour.h ++++ b/include/net/neighbour.h @@ -124,7 +124,7 @@ struct neigh_ops { int (*connected_output)(struct sk_buff*); int (*hh_output)(struct sk_buff*); @@ -61346,10 +62708,11 @@ diff -urNp linux-3.0.9/include/net/neighbour.h linux-3.0.9/include/net/neighbour struct pneigh_entry { struct pneigh_entry *next; -diff -urNp linux-3.0.9/include/net/netlink.h linux-3.0.9/include/net/netlink.h ---- linux-3.0.9/include/net/netlink.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/netlink.h 2011-11-12 12:47:14.000000000 -0500 -@@ -562,7 +562,7 @@ static inline void *nlmsg_get_pos(struct +diff --git a/include/net/netlink.h b/include/net/netlink.h +index 02740a9..7aff1af 100644 +--- a/include/net/netlink.h ++++ b/include/net/netlink.h +@@ -562,7 +562,7 @@ static inline void *nlmsg_get_pos(struct sk_buff *skb) static inline void nlmsg_trim(struct sk_buff *skb, const void *mark) { if (mark) @@ -61358,9 +62721,10 @@ diff -urNp linux-3.0.9/include/net/netlink.h linux-3.0.9/include/net/netlink.h } /** -diff -urNp linux-3.0.9/include/net/netns/ipv4.h linux-3.0.9/include/net/netns/ipv4.h ---- linux-3.0.9/include/net/netns/ipv4.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/netns/ipv4.h 2011-11-12 12:47:14.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 { unsigned int sysctl_ping_group_range[2]; @@ -61372,9 +62736,10 @@ diff -urNp linux-3.0.9/include/net/netns/ipv4.h linux-3.0.9/include/net/netns/ip #ifdef CONFIG_IP_MROUTE #ifndef CONFIG_IP_MROUTE_MULTIPLE_TABLES -diff -urNp linux-3.0.9/include/net/sctp/sctp.h linux-3.0.9/include/net/sctp/sctp.h ---- linux-3.0.9/include/net/sctp/sctp.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/sctp/sctp.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h +index b2c2366..10a2a1d 100644 +--- a/include/net/sctp/sctp.h ++++ b/include/net/sctp/sctp.h @@ -315,9 +315,9 @@ do { \ #else /* SCTP_DEBUG */ @@ -61388,9 +62753,10 @@ diff -urNp linux-3.0.9/include/net/sctp/sctp.h linux-3.0.9/include/net/sctp/sctp #define SCTP_ENABLE_DEBUG #define SCTP_DISABLE_DEBUG #define SCTP_ASSERT(expr, str, func) -diff -urNp linux-3.0.9/include/net/sock.h linux-3.0.9/include/net/sock.h ---- linux-3.0.9/include/net/sock.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/sock.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/net/sock.h b/include/net/sock.h +index c0b938c..13ef493 100644 +--- a/include/net/sock.h ++++ b/include/net/sock.h @@ -277,7 +277,7 @@ struct sock { #ifdef CONFIG_RPS __u32 sk_rxhash; @@ -61400,7 +62766,7 @@ diff -urNp linux-3.0.9/include/net/sock.h linux-3.0.9/include/net/sock.h int sk_rcvbuf; struct sk_filter __rcu *sk_filter; -@@ -1390,7 +1390,7 @@ static inline void sk_nocaps_add(struct +@@ -1390,7 +1390,7 @@ static inline void sk_nocaps_add(struct sock *sk, int flags) } static inline int skb_do_copy_data_nocache(struct sock *sk, struct sk_buff *skb, @@ -61409,9 +62775,10 @@ diff -urNp linux-3.0.9/include/net/sock.h linux-3.0.9/include/net/sock.h int copy, int offset) { if (skb->ip_summed == CHECKSUM_NONE) { -diff -urNp linux-3.0.9/include/net/tcp.h linux-3.0.9/include/net/tcp.h ---- linux-3.0.9/include/net/tcp.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/tcp.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/net/tcp.h b/include/net/tcp.h +index cda30ea..7b6e226 100644 +--- a/include/net/tcp.h ++++ b/include/net/tcp.h @@ -1374,8 +1374,8 @@ enum tcp_seq_states { struct tcp_seq_afinfo { char *name; @@ -61423,9 +62790,10 @@ diff -urNp linux-3.0.9/include/net/tcp.h linux-3.0.9/include/net/tcp.h }; struct tcp_iter_state { -diff -urNp linux-3.0.9/include/net/udp.h linux-3.0.9/include/net/udp.h ---- linux-3.0.9/include/net/udp.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/udp.h 2011-11-12 12:47:14.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; @@ -61437,9 +62805,10 @@ diff -urNp linux-3.0.9/include/net/udp.h linux-3.0.9/include/net/udp.h }; struct udp_iter_state { -diff -urNp linux-3.0.9/include/net/xfrm.h linux-3.0.9/include/net/xfrm.h ---- linux-3.0.9/include/net/xfrm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/net/xfrm.h 2011-11-12 12:47:14.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; @@ -61449,9 +62818,10 @@ diff -urNp linux-3.0.9/include/net/xfrm.h linux-3.0.9/include/net/xfrm.h u32 priority; u32 index; struct xfrm_mark mark; -diff -urNp linux-3.0.9/include/rdma/iw_cm.h linux-3.0.9/include/rdma/iw_cm.h ---- linux-3.0.9/include/rdma/iw_cm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/rdma/iw_cm.h 2011-11-12 12:47:14.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); @@ -61461,9 +62831,10 @@ diff -urNp linux-3.0.9/include/rdma/iw_cm.h linux-3.0.9/include/rdma/iw_cm.h /** * iw_create_cm_id - Create an IW CM identifier. -diff -urNp linux-3.0.9/include/scsi/libfc.h linux-3.0.9/include/scsi/libfc.h ---- linux-3.0.9/include/scsi/libfc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/scsi/libfc.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/scsi/libfc.h b/include/scsi/libfc.h +index a3cbda4..9dd465d 100644 +--- a/include/scsi/libfc.h ++++ b/include/scsi/libfc.h @@ -750,6 +750,7 @@ struct libfc_function_template { */ void (*disc_stop_final) (struct fc_lport *); @@ -61481,9 +62852,10 @@ diff -urNp linux-3.0.9/include/scsi/libfc.h linux-3.0.9/include/scsi/libfc.h u8 link_up; u8 qfull; enum fc_lport_state state; -diff -urNp linux-3.0.9/include/scsi/scsi_device.h linux-3.0.9/include/scsi/scsi_device.h ---- linux-3.0.9/include/scsi/scsi_device.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/scsi/scsi_device.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h +index dd82e02..3c94df0 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 from */ #define SCSI_DEFAULT_DEVICE_BLOCKED 3 @@ -61497,9 +62869,10 @@ diff -urNp linux-3.0.9/include/scsi/scsi_device.h linux-3.0.9/include/scsi/scsi_ struct device sdev_gendev, sdev_dev; -diff -urNp linux-3.0.9/include/scsi/scsi_transport_fc.h linux-3.0.9/include/scsi/scsi_transport_fc.h ---- linux-3.0.9/include/scsi/scsi_transport_fc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/scsi/scsi_transport_fc.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/scsi/scsi_transport_fc.h b/include/scsi/scsi_transport_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; @@ -61509,9 +62882,10 @@ diff -urNp linux-3.0.9/include/scsi/scsi_transport_fc.h linux-3.0.9/include/scsi /** -diff -urNp linux-3.0.9/include/sound/ak4xxx-adda.h linux-3.0.9/include/sound/ak4xxx-adda.h ---- linux-3.0.9/include/sound/ak4xxx-adda.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/sound/ak4xxx-adda.h 2011-11-12 12:47:14.000000000 -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); @@ -61521,9 +62895,10 @@ diff -urNp linux-3.0.9/include/sound/ak4xxx-adda.h linux-3.0.9/include/sound/ak4 #define AK4XXX_IMAGE_SIZE (AK4XXX_MAX_CHIPS * 16) /* 64 bytes */ -diff -urNp linux-3.0.9/include/sound/hwdep.h linux-3.0.9/include/sound/hwdep.h ---- linux-3.0.9/include/sound/hwdep.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/sound/hwdep.h 2011-11-12 12:47:14.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, @@ -61533,9 +62908,10 @@ diff -urNp linux-3.0.9/include/sound/hwdep.h linux-3.0.9/include/sound/hwdep.h struct snd_hwdep { struct snd_card *card; -diff -urNp linux-3.0.9/include/sound/info.h linux-3.0.9/include/sound/info.h ---- linux-3.0.9/include/sound/info.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/sound/info.h 2011-11-12 12:47:14.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, @@ -61545,9 +62921,10 @@ diff -urNp linux-3.0.9/include/sound/info.h linux-3.0.9/include/sound/info.h struct snd_info_entry_ops { int (*open)(struct snd_info_entry *entry, -diff -urNp linux-3.0.9/include/sound/pcm.h linux-3.0.9/include/sound/pcm.h ---- linux-3.0.9/include/sound/pcm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/sound/pcm.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/sound/pcm.h b/include/sound/pcm.h +index e1bad11..692830c 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); @@ -61556,9 +62933,10 @@ diff -urNp linux-3.0.9/include/sound/pcm.h linux-3.0.9/include/sound/pcm.h /* * -diff -urNp linux-3.0.9/include/sound/sb16_csp.h linux-3.0.9/include/sound/sb16_csp.h ---- linux-3.0.9/include/sound/sb16_csp.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/sound/sb16_csp.h 2011-11-12 12:47:14.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 channels); int (*csp_stop) (struct snd_sb_csp * p); @@ -61568,9 +62946,10 @@ diff -urNp linux-3.0.9/include/sound/sb16_csp.h linux-3.0.9/include/sound/sb16_c /* * CSP private data -diff -urNp linux-3.0.9/include/sound/soc.h linux-3.0.9/include/sound/soc.h ---- linux-3.0.9/include/sound/soc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/sound/soc.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/sound/soc.h b/include/sound/soc.h +index 3a4bd3a..63bde9b 100644 +--- a/include/sound/soc.h ++++ b/include/sound/soc.h @@ -636,7 +636,7 @@ struct snd_soc_platform_driver { /* platform stream ops */ @@ -61580,9 +62959,10 @@ diff -urNp linux-3.0.9/include/sound/soc.h linux-3.0.9/include/sound/soc.h struct snd_soc_platform { const char *name; -diff -urNp linux-3.0.9/include/sound/ymfpci.h linux-3.0.9/include/sound/ymfpci.h ---- linux-3.0.9/include/sound/ymfpci.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/sound/ymfpci.h 2011-11-12 12:47:14.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; @@ -61592,9 +62972,10 @@ diff -urNp linux-3.0.9/include/sound/ymfpci.h linux-3.0.9/include/sound/ymfpci.h struct snd_info_entry *proc_entry; const struct firmware *dsp_microcode; const struct firmware *controller_microcode; -diff -urNp linux-3.0.9/include/target/target_core_base.h linux-3.0.9/include/target/target_core_base.h ---- linux-3.0.9/include/target/target_core_base.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/target/target_core_base.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/include/target/target_core_base.h b/include/target/target_core_base.h +index 561ac99..948a9c8 100644 +--- a/include/target/target_core_base.h ++++ b/include/target/target_core_base.h @@ -364,7 +364,7 @@ struct t10_reservation_ops { int (*t10_seq_non_holder)(struct se_cmd *, unsigned char *, u32); int (*t10_pr_register)(struct se_cmd *); @@ -61624,9 +63005,10 @@ diff -urNp linux-3.0.9/include/target/target_core_base.h linux-3.0.9/include/tar atomic_t dev_tur_active; atomic_t execute_tasks; atomic_t dev_status_thr_count; -diff -urNp linux-3.0.9/include/trace/events/irq.h linux-3.0.9/include/trace/events/irq.h ---- linux-3.0.9/include/trace/events/irq.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/trace/events/irq.h 2011-11-12 12:47:14.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, @@ -61645,9 +63027,10 @@ diff -urNp linux-3.0.9/include/trace/events/irq.h linux-3.0.9/include/trace/even TP_ARGS(irq, action, ret), -diff -urNp linux-3.0.9/include/video/udlfb.h linux-3.0.9/include/video/udlfb.h ---- linux-3.0.9/include/video/udlfb.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/video/udlfb.h 2011-11-12 12:47:14.000000000 -0500 +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]; @@ -61663,9 +63046,10 @@ diff -urNp linux-3.0.9/include/video/udlfb.h linux-3.0.9/include/video/udlfb.h }; #define NR_USB_REQUEST_I2C_SUB_IO 0x02 -diff -urNp linux-3.0.9/include/video/uvesafb.h linux-3.0.9/include/video/uvesafb.h ---- linux-3.0.9/include/video/uvesafb.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/include/video/uvesafb.h 2011-11-12 12:47:14.000000000 -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 */ @@ -61674,10 +63058,24 @@ diff -urNp linux-3.0.9/include/video/uvesafb.h linux-3.0.9/include/video/uvesafb void *pmi_start; void *pmi_pal; u8 *vbe_state_orig; /* -diff -urNp linux-3.0.9/init/do_mounts.c linux-3.0.9/init/do_mounts.c ---- linux-3.0.9/init/do_mounts.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/init/do_mounts.c 2011-11-12 12:47:14.000000000 -0500 -@@ -287,11 +287,11 @@ static void __init get_fs_names(char *pa +diff --git a/init/Kconfig b/init/Kconfig +index 412c21b..13e4618 100644 +--- a/init/Kconfig ++++ b/init/Kconfig +@@ -1195,7 +1195,7 @@ config SLUB_DEBUG + + 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) static int __init do_mount_root(char *name, char *fs, int flags, void *data) { @@ -61691,7 +63089,7 @@ diff -urNp linux-3.0.9/init/do_mounts.c linux-3.0.9/init/do_mounts.c ROOT_DEV = 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); @@ -61722,9 +63120,10 @@ diff -urNp linux-3.0.9/init/do_mounts.c linux-3.0.9/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.0.9/init/do_mounts.h linux-3.0.9/init/do_mounts.h ---- linux-3.0.9/init/do_mounts.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/init/do_mounts.h 2011-11-12 12:47:14.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; static inline int create_dev(char *name, dev_t dev) @@ -61753,9 +63152,10 @@ diff -urNp linux-3.0.9/init/do_mounts.h linux-3.0.9/init/do_mounts.h return 0; if (!S_ISBLK(stat.st_mode)) return 0; -diff -urNp linux-3.0.9/init/do_mounts_initrd.c linux-3.0.9/init/do_mounts_initrd.c ---- linux-3.0.9/init/do_mounts_initrd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/init/do_mounts_initrd.c 2011-11-12 12:47:14.000000000 -0500 +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 */ @@ -61830,9 +63230,10 @@ diff -urNp linux-3.0.9/init/do_mounts_initrd.c linux-3.0.9/init/do_mounts_initrd + sys_unlink((const char __force_user *)"/initrd.image"); return 0; } -diff -urNp linux-3.0.9/init/do_mounts_md.c linux-3.0.9/init/do_mounts_md.c ---- linux-3.0.9/init/do_mounts_md.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/init/do_mounts_md.c 2011-11-12 12:47:14.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); @@ -61860,9 +63261,10 @@ diff -urNp linux-3.0.9/init/do_mounts_md.c linux-3.0.9/init/do_mounts_md.c if (fd >= 0) { sys_ioctl(fd, RAID_AUTORUN, raid_autopart); sys_close(fd); -diff -urNp linux-3.0.9/init/initramfs.c linux-3.0.9/init/initramfs.c ---- linux-3.0.9/init/initramfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/init/initramfs.c 2011-11-12 12:47:14.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) } } @@ -61890,7 +63292,7 @@ diff -urNp linux-3.0.9/init/initramfs.c linux-3.0.9/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 mode) { struct stat st; @@ -61971,22 +63373,11 @@ diff -urNp linux-3.0.9/init/initramfs.c linux-3.0.9/init/initramfs.c state = SkipIt; next_state = Reset; return 0; -diff -urNp linux-3.0.9/init/Kconfig linux-3.0.9/init/Kconfig ---- linux-3.0.9/init/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/init/Kconfig 2011-11-12 12:47:14.000000000 -0500 -@@ -1195,7 +1195,7 @@ config SLUB_DEBUG - - 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.0.9/init/main.c linux-3.0.9/init/main.c ---- linux-3.0.9/init/main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/init/main.c 2011-11-12 12:47:14.000000000 -0500 -@@ -96,6 +96,8 @@ static inline void mark_rodata_ro(void) +diff --git a/init/main.c b/init/main.c +index d7211fa..4ba6d60 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 @@ -61995,7 +63386,7 @@ diff -urNp linux-3.0.9/init/main.c linux-3.0.9/init/main.c /* * Debug helper: via this flag we know that we are in 'early bootup code' * where only the boot processor is running with IRQ disabled. This means -@@ -149,6 +151,49 @@ static int __init set_reset_devices(char +@@ -149,6 +151,49 @@ static int __init set_reset_devices(char *str) __setup("reset_devices", set_reset_devices); @@ -62045,7 +63436,7 @@ diff -urNp linux-3.0.9/init/main.c linux-3.0.9/init/main.c static const char * argv_init[MAX_INIT_ARGS+2] = { "init", NULL, }; const char * envp_init[MAX_INIT_ENVS+2] = { "HOME=/", "TERM=linux", NULL, }; static const char *panic_later, *panic_param; -@@ -667,6 +712,7 @@ int __init_or_module do_one_initcall(ini +@@ -667,6 +712,7 @@ int __init_or_module do_one_initcall(initcall_t fn) { int count = preempt_count(); int ret; @@ -62053,7 +63444,7 @@ diff -urNp linux-3.0.9/init/main.c linux-3.0.9/init/main.c if (initcall_debug) ret = do_one_initcall_debug(fn); -@@ -679,15 +725,15 @@ int __init_or_module do_one_initcall(ini +@@ -679,15 +725,15 @@ int __init_or_module do_one_initcall(initcall_t fn) sprintf(msgbuf, "error code %d ", ret); if (preempt_count() != count) { @@ -62073,7 +63464,7 @@ diff -urNp linux-3.0.9/init/main.c linux-3.0.9/init/main.c } return ret; -@@ -805,7 +851,7 @@ static int __init kernel_init(void * unu +@@ -805,7 +851,7 @@ static int __init kernel_init(void * unused) do_basic_setup(); /* Open the /dev/console on the rootfs, this should never fail */ @@ -62082,7 +63473,7 @@ diff -urNp linux-3.0.9/init/main.c linux-3.0.9/init/main.c printk(KERN_WARNING "Warning: unable to open an initial console.\n"); (void) sys_dup(0); -@@ -818,11 +864,13 @@ static int __init kernel_init(void * unu +@@ -818,11 +864,13 @@ static int __init kernel_init(void * unused) if (!ramdisk_execute_command) ramdisk_execute_command = "/init"; @@ -62097,10 +63488,11 @@ diff -urNp linux-3.0.9/init/main.c linux-3.0.9/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.0.9/ipc/mqueue.c linux-3.0.9/ipc/mqueue.c ---- linux-3.0.9/ipc/mqueue.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/ipc/mqueue.c 2011-11-12 12:47:14.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_block *sb, mq_bytes = (mq_msg_tblsz + (info->attr.mq_maxmsg * info->attr.mq_msgsize)); @@ -62108,10 +63500,11 @@ diff -urNp linux-3.0.9/ipc/mqueue.c linux-3.0.9/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.0.9/ipc/msg.c linux-3.0.9/ipc/msg.c ---- linux-3.0.9/ipc/msg.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/ipc/msg.c 2011-11-12 12:47:14.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_perm *ipcp, int msgflg) return security_msg_queue_associate(msq, msgflg); } @@ -62136,10 +63529,11 @@ diff -urNp linux-3.0.9/ipc/msg.c linux-3.0.9/ipc/msg.c msg_params.key = key; msg_params.flg = msgflg; -diff -urNp linux-3.0.9/ipc/sem.c linux-3.0.9/ipc/sem.c ---- linux-3.0.9/ipc/sem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/ipc/sem.c 2011-11-12 12:47:14.000000000 -0500 -@@ -318,10 +318,15 @@ static inline int sem_more_checks(struct +diff --git a/ipc/sem.c b/ipc/sem.c +index e68a8f5..798131e 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; } @@ -62156,7 +63550,7 @@ diff -urNp linux-3.0.9/ipc/sem.c linux-3.0.9/ipc/sem.c struct ipc_params sem_params; ns = 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; @@ -62167,7 +63561,7 @@ diff -urNp linux-3.0.9/ipc/sem.c linux-3.0.9/ipc/sem.c sem_params.key = key; sem_params.flg = semflg; sem_params.u.nsems = nsems; -@@ -854,6 +855,8 @@ static int semctl_main(struct ipc_namesp +@@ -854,6 +855,8 @@ static int semctl_main(struct ipc_namespace *ns, int semid, int semnum, int nsems; struct list_head tasks; @@ -62176,7 +63570,7 @@ diff -urNp linux-3.0.9/ipc/sem.c linux-3.0.9/ipc/sem.c sma = sem_lock_check(ns, semid); if (IS_ERR(sma)) return PTR_ERR(sma); -@@ -1301,6 +1304,8 @@ SYSCALL_DEFINE4(semtimedop, int, semid, +@@ -1301,6 +1304,8 @@ SYSCALL_DEFINE4(semtimedop, int, semid, struct sembuf __user *, tsops, struct ipc_namespace *ns; struct list_head tasks; @@ -62185,10 +63579,11 @@ diff -urNp linux-3.0.9/ipc/sem.c linux-3.0.9/ipc/sem.c ns = current->nsproxy->ipc_ns; if (nsops < 1 || semid < 0) -diff -urNp linux-3.0.9/ipc/shm.c linux-3.0.9/ipc/shm.c ---- linux-3.0.9/ipc/shm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/ipc/shm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -69,6 +69,14 @@ static void shm_destroy (struct ipc_name +diff --git a/ipc/shm.c b/ipc/shm.c +index ab3385a..ce64482 100644 +--- a/ipc/shm.c ++++ b/ipc/shm.c +@@ -69,6 +69,14 @@ static void shm_destroy (struct ipc_namespace *ns, struct shmid_kernel *shp); static int sysvipc_shm_proc_show(struct seq_file *s, void *it); #endif @@ -62203,7 +63598,7 @@ diff -urNp linux-3.0.9/ipc/shm.c linux-3.0.9/ipc/shm.c void shm_init_ns(struct ipc_namespace *ns) { ns->shm_ctlmax = SHMMAX; -@@ -401,6 +409,14 @@ static int newseg(struct ipc_namespace * +@@ -401,6 +409,14 @@ static int newseg(struct ipc_namespace *ns, struct ipc_params *params) shp->shm_lprid = 0; shp->shm_atim = shp->shm_dtim = 0; shp->shm_ctim = get_seconds(); @@ -62218,7 +63613,7 @@ diff -urNp linux-3.0.9/ipc/shm.c linux-3.0.9/ipc/shm.c shp->shm_segsz = size; shp->shm_nattch = 0; shp->shm_file = file; -@@ -451,18 +467,19 @@ static inline int shm_more_checks(struct +@@ -451,18 +467,19 @@ static inline int shm_more_checks(struct kern_ipc_perm *ipcp, return 0; } @@ -62243,7 +63638,7 @@ diff -urNp linux-3.0.9/ipc/shm.c linux-3.0.9/ipc/shm.c shm_params.key = key; shm_params.flg = shmflg; shm_params.u.size = size; -@@ -762,8 +779,6 @@ SYSCALL_DEFINE3(shmctl, int, shmid, int, +@@ -762,8 +779,6 @@ SYSCALL_DEFINE3(shmctl, int, shmid, int, cmd, struct shmid_ds __user *, buf) case SHM_LOCK: case SHM_UNLOCK: { @@ -62252,7 +63647,7 @@ diff -urNp linux-3.0.9/ipc/shm.c linux-3.0.9/ipc/shm.c lru_add_drain_all(); /* drain pagevecs to lru lists */ shp = shm_lock_check(ns, shmid); -@@ -896,9 +911,21 @@ long do_shmat(int shmid, char __user *sh +@@ -896,9 +911,21 @@ long do_shmat(int shmid, char __user *shmaddr, int shmflg, ulong *raddr) if (err) goto out_unlock; @@ -62274,10 +63669,11 @@ diff -urNp linux-3.0.9/ipc/shm.c linux-3.0.9/ipc/shm.c size = i_size_read(path.dentry->d_inode); shm_unlock(shp); -diff -urNp linux-3.0.9/kernel/acct.c linux-3.0.9/kernel/acct.c ---- linux-3.0.9/kernel/acct.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/acct.c 2011-11-12 12:47:14.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 = current->signal->rlim[RLIMIT_FSIZE].rlim_cur; current->signal->rlim[RLIMIT_FSIZE].rlim_cur = RLIM_INFINITY; @@ -62286,9 +63682,10 @@ diff -urNp linux-3.0.9/kernel/acct.c linux-3.0.9/kernel/acct.c sizeof(acct_t), &file->f_pos); current->signal->rlim[RLIMIT_FSIZE].rlim_cur = flim; set_fs(fs); -diff -urNp linux-3.0.9/kernel/audit.c linux-3.0.9/kernel/audit.c ---- linux-3.0.9/kernel/audit.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/audit.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/audit.c b/kernel/audit.c +index 9395003..7b0479e 100644 +--- a/kernel/audit.c ++++ b/kernel/audit.c @@ -112,7 +112,7 @@ u32 audit_sig_sid = 0; 3) suppressed due to audit_rate_limit 4) suppressed due to audit_backlog_limit @@ -62316,7 +63713,7 @@ diff -urNp linux-3.0.9/kernel/audit.c linux-3.0.9/kernel/audit.c audit_rate_limit, audit_backlog_limit); audit_panic(message); -@@ -686,7 +686,7 @@ static int audit_receive_msg(struct sk_b +@@ -686,7 +686,7 @@ static int audit_receive_msg(struct sk_buff *skb, struct nlmsghdr *nlh) status_set.pid = audit_pid; status_set.rate_limit = audit_rate_limit; status_set.backlog_limit = audit_backlog_limit; @@ -62325,10 +63722,11 @@ diff -urNp linux-3.0.9/kernel/audit.c linux-3.0.9/kernel/audit.c status_set.backlog = 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.0.9/kernel/auditsc.c linux-3.0.9/kernel/auditsc.c ---- linux-3.0.9/kernel/auditsc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/auditsc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2118,7 +2118,7 @@ int auditsc_get_stamp(struct audit_conte +diff --git a/kernel/auditsc.c b/kernel/auditsc.c +index 00d79df..e67a996 100644 +--- a/kernel/auditsc.c ++++ b/kernel/auditsc.c +@@ -2118,7 +2118,7 @@ int auditsc_get_stamp(struct audit_context *ctx, } /* global counter which is incremented every time something logs in */ @@ -62337,7 +63735,7 @@ diff -urNp linux-3.0.9/kernel/auditsc.c linux-3.0.9/kernel/auditsc.c /** * audit_set_loginuid - set a task's audit_context loginuid -@@ -2131,7 +2131,7 @@ static atomic_t session_id = ATOMIC_INIT +@@ -2131,7 +2131,7 @@ static atomic_t session_id = ATOMIC_INIT(0); */ int audit_set_loginuid(struct task_struct *task, uid_t loginuid) { @@ -62346,10 +63744,11 @@ diff -urNp linux-3.0.9/kernel/auditsc.c linux-3.0.9/kernel/auditsc.c struct audit_context *context = task->audit_context; if (context && context->in_syscall) { -diff -urNp linux-3.0.9/kernel/capability.c linux-3.0.9/kernel/capability.c ---- linux-3.0.9/kernel/capability.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/capability.c 2011-11-12 12:47:14.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, cap_user_data_t, dataptr) * before modification is attempted and the application * fails. */ @@ -62359,7 +63758,7 @@ diff -urNp linux-3.0.9/kernel/capability.c linux-3.0.9/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(); } @@ -62368,7 +63767,7 @@ diff -urNp linux-3.0.9/kernel/capability.c linux-3.0.9/kernel/capability.c current->flags |= 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); @@ -62396,7 +63795,7 @@ diff -urNp linux-3.0.9/kernel/capability.c linux-3.0.9/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 +@@ -396,6 +420,12 @@ bool task_ns_capable(struct task_struct *t, int cap) } EXPORT_SYMBOL(task_ns_capable); @@ -62409,9 +63808,10 @@ diff -urNp linux-3.0.9/kernel/capability.c linux-3.0.9/kernel/capability.c /** * nsown_capable - Check superior capability to one's own user_ns * @cap: The capability in question -diff -urNp linux-3.0.9/kernel/cgroup.c linux-3.0.9/kernel/cgroup.c ---- linux-3.0.9/kernel/cgroup.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/cgroup.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/cgroup.c b/kernel/cgroup.c +index 2731d11..467225f 100644 +--- a/kernel/cgroup.c ++++ b/kernel/cgroup.c @@ -593,6 +593,8 @@ static struct css_set *find_css_set( struct hlist_head *hhead; struct cg_cgroup_link *link; @@ -62421,9 +63821,10 @@ diff -urNp linux-3.0.9/kernel/cgroup.c linux-3.0.9/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.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c ---- linux-3.0.9/kernel/compat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/compat.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/compat.c b/kernel/compat.c +index fc9eb093..bce8e4b 100644 +--- a/kernel/compat.c ++++ b/kernel/compat.c @@ -13,6 +13,7 @@ #include <linux/linkage.h> @@ -62432,7 +63833,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c #include <linux/errno.h> #include <linux/time.h> #include <linux/signal.h> -@@ -166,7 +167,7 @@ static long compat_nanosleep_restart(str +@@ -166,7 +167,7 @@ static long compat_nanosleep_restart(struct restart_block *restart) mm_segment_t oldfs; long ret; @@ -62441,7 +63842,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c oldfs = get_fs(); set_fs(KERNEL_DS); ret = hrtimer_nanosleep_restart(restart); -@@ -198,7 +199,7 @@ asmlinkage long compat_sys_nanosleep(str +@@ -198,7 +199,7 @@ asmlinkage long compat_sys_nanosleep(struct compat_timespec __user *rqtp, oldfs = get_fs(); set_fs(KERNEL_DS); ret = hrtimer_nanosleep(&tu, @@ -62450,7 +63851,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c HRTIMER_MODE_REL, CLOCK_MONOTONIC); set_fs(oldfs); -@@ -307,7 +308,7 @@ asmlinkage long compat_sys_sigpending(co +@@ -307,7 +308,7 @@ asmlinkage long compat_sys_sigpending(compat_old_sigset_t __user *set) mm_segment_t old_fs = get_fs(); set_fs(KERNEL_DS); @@ -62459,7 +63860,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(old_fs); if (ret == 0) ret = put_user(s, set); -@@ -330,8 +331,8 @@ asmlinkage long compat_sys_sigprocmask(i +@@ -330,8 +331,8 @@ asmlinkage long compat_sys_sigprocmask(int how, compat_old_sigset_t __user *set, old_fs = get_fs(); set_fs(KERNEL_DS); ret = sys_sigprocmask(how, @@ -62470,7 +63871,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(old_fs); if (ret == 0) if (oset) -@@ -368,7 +369,7 @@ asmlinkage long compat_sys_old_getrlimit +@@ -368,7 +369,7 @@ asmlinkage long compat_sys_old_getrlimit(unsigned int resource, mm_segment_t old_fs = get_fs(); set_fs(KERNEL_DS); @@ -62479,7 +63880,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(old_fs); if (!ret) { -@@ -440,7 +441,7 @@ asmlinkage long compat_sys_getrusage(int +@@ -440,7 +441,7 @@ asmlinkage long compat_sys_getrusage(int who, struct compat_rusage __user *ru) mm_segment_t old_fs = get_fs(); set_fs(KERNEL_DS); @@ -62488,7 +63889,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(old_fs); if (ret) -@@ -467,8 +468,8 @@ compat_sys_wait4(compat_pid_t pid, compa +@@ -467,8 +468,8 @@ compat_sys_wait4(compat_pid_t pid, compat_uint_t __user *stat_addr, int options, set_fs (KERNEL_DS); ret = sys_wait4(pid, (stat_addr ? @@ -62499,7 +63900,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs (old_fs); if (ret > 0) { -@@ -493,8 +494,8 @@ asmlinkage long compat_sys_waitid(int wh +@@ -493,8 +494,8 @@ asmlinkage long compat_sys_waitid(int which, compat_pid_t pid, memset(&info, 0, sizeof(info)); set_fs(KERNEL_DS); @@ -62510,7 +63911,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(old_fs); if ((ret < 0) || (info.si_signo == 0)) -@@ -624,8 +625,8 @@ long compat_sys_timer_settime(timer_t ti +@@ -624,8 +625,8 @@ long compat_sys_timer_settime(timer_t timer_id, int flags, oldfs = get_fs(); set_fs(KERNEL_DS); err = sys_timer_settime(timer_id, flags, @@ -62521,7 +63922,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(oldfs); if (!err && old && put_compat_itimerspec(old, &oldts)) return -EFAULT; -@@ -642,7 +643,7 @@ long compat_sys_timer_gettime(timer_t ti +@@ -642,7 +643,7 @@ long compat_sys_timer_gettime(timer_t timer_id, oldfs = get_fs(); set_fs(KERNEL_DS); err = sys_timer_gettime(timer_id, @@ -62530,7 +63931,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(oldfs); if (!err && put_compat_itimerspec(setting, &ts)) return -EFAULT; -@@ -661,7 +662,7 @@ long compat_sys_clock_settime(clockid_t +@@ -661,7 +662,7 @@ long compat_sys_clock_settime(clockid_t which_clock, oldfs = get_fs(); set_fs(KERNEL_DS); err = sys_clock_settime(which_clock, @@ -62539,7 +63940,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(oldfs); return err; } -@@ -676,7 +677,7 @@ long compat_sys_clock_gettime(clockid_t +@@ -676,7 +677,7 @@ long compat_sys_clock_gettime(clockid_t which_clock, oldfs = get_fs(); set_fs(KERNEL_DS); err = sys_clock_gettime(which_clock, @@ -62548,7 +63949,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(oldfs); if (!err && put_compat_timespec(&ts, tp)) return -EFAULT; -@@ -696,7 +697,7 @@ long compat_sys_clock_adjtime(clockid_t +@@ -696,7 +697,7 @@ long compat_sys_clock_adjtime(clockid_t which_clock, oldfs = get_fs(); set_fs(KERNEL_DS); @@ -62557,7 +63958,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(oldfs); err = compat_put_timex(utp, &txc); -@@ -716,7 +717,7 @@ long compat_sys_clock_getres(clockid_t w +@@ -716,7 +717,7 @@ long compat_sys_clock_getres(clockid_t which_clock, oldfs = get_fs(); set_fs(KERNEL_DS); err = sys_clock_getres(which_clock, @@ -62566,7 +63967,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(oldfs); if (!err && tp && put_compat_timespec(&ts, tp)) return -EFAULT; -@@ -728,9 +729,9 @@ static long compat_clock_nanosleep_resta +@@ -728,9 +729,9 @@ static long compat_clock_nanosleep_restart(struct restart_block *restart) long err; mm_segment_t oldfs; struct timespec tu; @@ -62578,7 +63979,7 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c oldfs = get_fs(); set_fs(KERNEL_DS); err = clock_nanosleep_restart(restart); -@@ -762,8 +763,8 @@ long compat_sys_clock_nanosleep(clockid_ +@@ -762,8 +763,8 @@ long compat_sys_clock_nanosleep(clockid_t which_clock, int flags, oldfs = get_fs(); set_fs(KERNEL_DS); err = sys_clock_nanosleep(which_clock, flags, @@ -62589,9 +63990,10 @@ diff -urNp linux-3.0.9/kernel/compat.c linux-3.0.9/kernel/compat.c set_fs(oldfs); if ((err == -ERESTART_RESTARTBLOCK) && rmtp && -diff -urNp linux-3.0.9/kernel/configs.c linux-3.0.9/kernel/configs.c ---- linux-3.0.9/kernel/configs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/configs.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/configs.c b/kernel/configs.c +index b4066b4..c2e76b1 100644 +--- a/kernel/configs.c ++++ b/kernel/configs.c @@ -74,8 +74,19 @@ static int __init ikconfig_init(void) struct proc_dir_entry *entry; @@ -62612,10 +64014,11 @@ diff -urNp linux-3.0.9/kernel/configs.c linux-3.0.9/kernel/configs.c if (!entry) return -ENOMEM; -diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/kernel/cred.c ---- linux-3.0.9/kernel/cred.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/cred.c 2011-11-12 12:47:14.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 174fa84..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) { @@ -62633,7 +64036,7 @@ diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/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 +@@ -220,6 +224,8 @@ const struct cred *get_task_cred(struct task_struct *task) { const struct cred *cred; @@ -62669,7 +64072,7 @@ diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/kernel/cred.c #ifdef CONFIG_KEYS tgcred = 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; @@ -62718,7 +64121,7 @@ diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/kernel/cred.c kdebug("abort_creds(%p{%d,%d})", new, atomic_read(&new->usage), read_cred_subscribers(new)); -@@ -574,6 +592,8 @@ const struct cred *override_creds(const +@@ -574,6 +592,8 @@ const struct cred *override_creds(const struct cred *new) { const struct cred *old = current->cred; @@ -62727,7 +64130,7 @@ diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/kernel/cred.c kdebug("override_creds(%p{%d,%d})", new, atomic_read(&new->usage), read_cred_subscribers(new)); -@@ -603,6 +623,8 @@ void revert_creds(const struct cred *old +@@ -603,6 +623,8 @@ void revert_creds(const struct cred *old) { const struct cred *override = current->cred; @@ -62736,7 +64139,7 @@ diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/kernel/cred.c kdebug("revert_creds(%p{%d,%d})", old, atomic_read(&old->usage), read_cred_subscribers(old)); -@@ -649,6 +671,8 @@ struct cred *prepare_kernel_cred(struct +@@ -649,6 +671,8 @@ struct cred *prepare_kernel_cred(struct task_struct *daemon) const struct cred *old; struct cred *new; @@ -62754,7 +64157,7 @@ diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/kernel/cred.c return security_kernel_act_as(new, secid); } EXPORT_SYMBOL(set_security_override); -@@ -722,6 +748,8 @@ int set_security_override_from_ctx(struc +@@ -722,6 +748,8 @@ int set_security_override_from_ctx(struct cred *new, const char *secctx) u32 secid; int ret; @@ -62763,10 +64166,11 @@ diff -urNp linux-3.0.9/kernel/cred.c linux-3.0.9/kernel/cred.c ret = security_secctx_to_secid(secctx, strlen(secctx), &secid); if (ret < 0) return ret; -diff -urNp linux-3.0.9/kernel/debug/debug_core.c linux-3.0.9/kernel/debug/debug_core.c ---- linux-3.0.9/kernel/debug/debug_core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/debug/debug_core.c 2011-11-12 12:47:14.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 bad6786..3d85c2a 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; @@ -62804,7 +64208,7 @@ diff -urNp linux-3.0.9/kernel/debug/debug_core.c linux-3.0.9/kernel/debug/debug_ if (kgdb_info[sstep_cpu].task) kgdb_sstep_pid = 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(); @@ -62826,10 +64230,11 @@ diff -urNp linux-3.0.9/kernel/debug/debug_core.c linux-3.0.9/kernel/debug/debug_ tasklet_schedule(&kgdb_tasklet_breakpoint); } EXPORT_SYMBOL_GPL(kgdb_schedule_breakpoint); -diff -urNp linux-3.0.9/kernel/debug/kdb/kdb_main.c linux-3.0.9/kernel/debug/kdb/kdb_main.c ---- linux-3.0.9/kernel/debug/kdb/kdb_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/debug/kdb/kdb_main.c 2011-11-12 12:47:14.000000000 -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 be14779..27edaaa 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) { kdb_printf("%-20s%8u 0x%p ", mod->name, @@ -62838,7 +64243,7 @@ diff -urNp linux-3.0.9/kernel/debug/kdb/kdb_main.c linux-3.0.9/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)"); @@ -62847,10 +64252,11 @@ diff -urNp linux-3.0.9/kernel/debug/kdb/kdb_main.c linux-3.0.9/kernel/debug/kdb/ #ifdef CONFIG_MODULE_UNLOAD { -diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c ---- linux-3.0.9/kernel/events/core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/events/core.c 2011-11-12 12:47:14.000000000 -0500 -@@ -170,7 +170,7 @@ int perf_proc_update_handler(struct ctl_ +diff --git a/kernel/events/core.c b/kernel/events/core.c +index 32a6151..54b12b2 100644 +--- a/kernel/events/core.c ++++ b/kernel/events/core.c +@@ -170,7 +170,7 @@ int perf_proc_update_handler(struct ctl_table *table, int write, return 0; } @@ -62859,7 +64265,7 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c static void cpu_ctx_sched_out(struct perf_cpu_context *cpuctx, enum event_type_t event_type); -@@ -2488,7 +2488,7 @@ static void __perf_event_read(void *info +@@ -2488,7 +2488,7 @@ static void __perf_event_read(void *info) static inline u64 perf_event_count(struct perf_event *event) { @@ -62868,7 +64274,7 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c } static u64 perf_event_read(struct perf_event *event) -@@ -3023,9 +3023,9 @@ u64 perf_event_read_value(struct perf_ev +@@ -3023,9 +3023,9 @@ u64 perf_event_read_value(struct perf_event *event, u64 *enabled, u64 *running) mutex_lock(&event->child_mutex); total += perf_event_read(event); *enabled += event->total_time_enabled + @@ -62880,7 +64286,7 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c list_for_each_entry(child, &event->child_list, child_list) { total += perf_event_read(child); -@@ -3388,10 +3388,10 @@ void perf_event_update_userpage(struct p +@@ -3388,10 +3388,10 @@ void perf_event_update_userpage(struct perf_event *event) userpg->offset -= local64_read(&event->hw.prev_count); userpg->time_enabled = event->total_time_enabled + @@ -62893,7 +64299,7 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c barrier(); ++userpg->lock; -@@ -4188,11 +4188,11 @@ static void perf_output_read_one(struct +@@ -4188,11 +4188,11 @@ static void perf_output_read_one(struct perf_output_handle *handle, values[n++] = perf_event_count(event); if (read_format & PERF_FORMAT_TOTAL_TIME_ENABLED) { values[n++] = enabled + @@ -62907,7 +64313,7 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c } if (read_format & PERF_FORMAT_ID) values[n++] = primary_event_id(event); -@@ -4833,12 +4833,12 @@ static void perf_event_mmap_event(struct +@@ -4833,12 +4833,12 @@ static void perf_event_mmap_event(struct perf_mmap_event *mmap_event) * need to add enough zero bytes after the string to handle * the 64bit alignment we do later. */ @@ -62922,7 +64328,7 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c if (IS_ERR(name)) { name = strncpy(tmp, "//toolong", sizeof(tmp)); goto got_name; -@@ -6190,7 +6190,7 @@ perf_event_alloc(struct perf_event_attr +@@ -6190,7 +6190,7 @@ perf_event_alloc(struct perf_event_attr *attr, int cpu, event->parent = parent_event; event->ns = get_pid_ns(current->nsproxy->pid_ns); @@ -62931,7 +64337,7 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c event->state = PERF_EVENT_STATE_INACTIVE; -@@ -6713,10 +6713,10 @@ static void sync_child_event(struct perf +@@ -6713,10 +6713,10 @@ static void sync_child_event(struct perf_event *child_event, /* * Add back the child's count to the parent's count: */ @@ -62945,9 +64351,10 @@ diff -urNp linux-3.0.9/kernel/events/core.c linux-3.0.9/kernel/events/core.c &parent_event->child_total_time_running); /* -diff -urNp linux-3.0.9/kernel/exit.c linux-3.0.9/kernel/exit.c ---- linux-3.0.9/kernel/exit.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/exit.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/exit.c b/kernel/exit.c +index f2b321b..4935c0d 100644 +--- a/kernel/exit.c ++++ b/kernel/exit.c @@ -57,6 +57,10 @@ #include <asm/pgtable.h> #include <asm/mmu_context.h> @@ -62959,7 +64366,7 @@ diff -urNp linux-3.0.9/kernel/exit.c linux-3.0.9/kernel/exit.c static void exit_mm(struct task_struct * tsk); static void __unhash_process(struct task_struct *p, bool group_dead) -@@ -169,6 +173,10 @@ void release_task(struct task_struct * p +@@ -169,6 +173,10 @@ void release_task(struct task_struct * p) struct task_struct *leader; int zap_leader; repeat: @@ -63061,10 +64468,11 @@ diff -urNp linux-3.0.9/kernel/exit.c linux-3.0.9/kernel/exit.c exit_mm(tsk); if (group_dead) -diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c ---- linux-3.0.9/kernel/fork.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/fork.c 2011-11-12 12:47:14.000000000 -0500 -@@ -286,7 +286,7 @@ static struct task_struct *dup_task_stru +diff --git a/kernel/fork.c b/kernel/fork.c +index 0276c30..5a97262 100644 +--- a/kernel/fork.c ++++ b/kernel/fork.c +@@ -286,7 +286,7 @@ static struct task_struct *dup_task_struct(struct task_struct *orig) *stackend = STACK_END_MAGIC; /* for overflow detection */ #ifdef CONFIG_CC_STACKPROTECTOR @@ -63153,7 +64561,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c down_write(&oldmm->mmap_sem); flush_cache_dup_mm(oldmm); -@@ -326,8 +390,8 @@ static int dup_mmap(struct mm_struct *mm +@@ -326,8 +390,8 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) mm->locked_vm = 0; mm->mmap = NULL; mm->mmap_cache = NULL; @@ -63164,7 +64572,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c mm->map_count = 0; cpumask_clear(mm_cpumask(mm)); mm->mm_rb = RB_ROOT; -@@ -343,8 +407,6 @@ static int dup_mmap(struct mm_struct *mm +@@ -343,8 +407,6 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) prev = NULL; for (mpnt = oldmm->mmap; mpnt; mpnt = mpnt->vm_next) { @@ -63173,7 +64581,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c if (mpnt->vm_flags & VM_DONTCOPY) { long pages = vma_pages(mpnt); mm->total_vm -= pages; -@@ -352,55 +414,13 @@ static int dup_mmap(struct mm_struct *mm +@@ -352,55 +414,13 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) -pages); continue; } @@ -63233,7 +64641,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c * Link in the new vma and copy the page table entries. */ *pprev = tmp; -@@ -421,6 +441,31 @@ static int dup_mmap(struct mm_struct *mm +@@ -421,6 +441,31 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) if (retval) goto out; } @@ -63280,7 +64688,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c } static inline int mm_alloc_pgd(struct mm_struct * mm) -@@ -836,13 +873,14 @@ static int copy_fs(unsigned long clone_f +@@ -836,13 +873,14 @@ static int copy_fs(unsigned long clone_flags, struct task_struct *tsk) spin_unlock(&fs->lock); return -EAGAIN; } @@ -63296,7 +64704,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c return 0; } -@@ -1104,12 +1142,16 @@ static struct task_struct *copy_process( +@@ -1104,12 +1142,16 @@ static struct task_struct *copy_process(unsigned long clone_flags, DEBUG_LOCKS_WARN_ON(!p->softirqs_enabled); #endif retval = -EAGAIN; @@ -63315,7 +64723,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c retval = copy_creds(p, clone_flags); if (retval < 0) -@@ -1250,6 +1292,8 @@ static struct task_struct *copy_process( +@@ -1250,6 +1292,8 @@ static struct task_struct *copy_process(unsigned long clone_flags, if (clone_flags & CLONE_THREAD) p->tgid = current->tgid; @@ -63342,7 +64750,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c if (clone_flags & CLONE_VFORK) { p->vfork_done = &vfork; init_completion(&vfork); -@@ -1610,7 +1658,7 @@ static int unshare_fs(unsigned long unsh +@@ -1610,7 +1658,7 @@ static int unshare_fs(unsigned long unshare_flags, struct fs_struct **new_fsp) return 0; /* don't need lock here; in the worst case we'll do useless copy */ @@ -63351,7 +64759,7 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c return 0; *new_fsp = copy_fs_struct(fs); -@@ -1697,7 +1745,8 @@ SYSCALL_DEFINE1(unshare, unsigned long, +@@ -1697,7 +1745,8 @@ SYSCALL_DEFINE1(unshare, unsigned long, unshare_flags) fs = current->fs; spin_lock(&fs->lock); current->fs = new_fs; @@ -63361,9 +64769,10 @@ diff -urNp linux-3.0.9/kernel/fork.c linux-3.0.9/kernel/fork.c new_fs = NULL; else new_fs = fs; -diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/kernel/futex.c ---- linux-3.0.9/kernel/futex.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/futex.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/futex.c b/kernel/futex.c +index 8b6da25..eddb90e 100644 +--- a/kernel/futex.c ++++ b/kernel/futex.c @@ -54,6 +54,7 @@ #include <linux/mount.h> #include <linux/pagemap.h> @@ -63372,7 +64781,7 @@ diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/kernel/futex.c #include <linux/signal.h> #include <linux/module.h> #include <linux/magic.h> -@@ -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 = 0; @@ -63384,7 +64793,7 @@ diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/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 = futex_q_init; int ret; @@ -63393,7 +64802,7 @@ diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/kernel/futex.c if (!bitset) return -EINVAL; q.bitset = 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 = futex_q_init; int res, ret; @@ -63402,7 +64811,7 @@ diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/kernel/futex.c if (!bitset) return -EINVAL; -@@ -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; @@ -63412,7 +64821,7 @@ diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/kernel/futex.c 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 = -EPERM; @@ -63423,7 +64832,7 @@ diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/kernel/futex.c pcred = __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: @@ -63451,9 +64860,10 @@ diff -urNp linux-3.0.9/kernel/futex.c linux-3.0.9/kernel/futex.c for (i = 0; i < ARRAY_SIZE(futex_queues); i++) { plist_head_init(&futex_queues[i].chain, &futex_queues[i].lock); -diff -urNp linux-3.0.9/kernel/futex_compat.c linux-3.0.9/kernel/futex_compat.c ---- linux-3.0.9/kernel/futex_compat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/futex_compat.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/compat.h> #include <linux/nsproxy.h> @@ -63462,7 +64872,7 @@ diff -urNp linux-3.0.9/kernel/futex_compat.c linux-3.0.9/kernel/futex_compat.c #include <asm/uaccess.h> -@@ -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; @@ -63474,7 +64884,7 @@ diff -urNp linux-3.0.9/kernel/futex_compat.c linux-3.0.9/kernel/futex_compat.c 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 = -EPERM; @@ -63485,7 +64895,7 @@ diff -urNp linux-3.0.9/kernel/futex_compat.c linux-3.0.9/kernel/futex_compat.c pcred = __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: @@ -63493,9 +64903,10 @@ diff -urNp linux-3.0.9/kernel/futex_compat.c linux-3.0.9/kernel/futex_compat.c head = p->compat_robust_list; rcu_read_unlock(); } -diff -urNp linux-3.0.9/kernel/gcov/base.c linux-3.0.9/kernel/gcov/base.c ---- linux-3.0.9/kernel/gcov/base.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/gcov/base.c 2011-11-12 12:47:14.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) } @@ -63508,7 +64919,7 @@ diff -urNp linux-3.0.9/kernel/gcov/base.c linux-3.0.9/kernel/gcov/base.c /* Update list and generate events when modules are unloaded. */ static int gcov_module_notifier(struct notifier_block *nb, unsigned long 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_block *nb, unsigned long event, prev = NULL; /* Remove entries located in module from linked list. */ for (info = gcov_info_head; info; info = info->next) { @@ -63517,9 +64928,10 @@ diff -urNp linux-3.0.9/kernel/gcov/base.c linux-3.0.9/kernel/gcov/base.c if (prev) prev->next = info->next; else -diff -urNp linux-3.0.9/kernel/hrtimer.c linux-3.0.9/kernel/hrtimer.c ---- linux-3.0.9/kernel/hrtimer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/hrtimer.c 2011-11-12 12:47:14.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); } @@ -63529,10 +64941,11 @@ diff -urNp linux-3.0.9/kernel/hrtimer.c linux-3.0.9/kernel/hrtimer.c { hrtimer_peek_ahead_timers(); } -diff -urNp linux-3.0.9/kernel/jump_label.c linux-3.0.9/kernel/jump_label.c ---- linux-3.0.9/kernel/jump_label.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/jump_label.c 2011-11-12 12:47:14.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, struct jump_entry *stop) size = (((unsigned long)stop - (unsigned long)start) / sizeof(struct jump_entry)); @@ -63542,7 +64955,7 @@ diff -urNp linux-3.0.9/kernel/jump_label.c linux-3.0.9/kernel/jump_label.c } 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(struct module *mod) struct jump_entry *iter_stop = iter_start + mod->num_jump_entries; struct jump_entry *iter; @@ -63555,9 +64968,10 @@ diff -urNp linux-3.0.9/kernel/jump_label.c linux-3.0.9/kernel/jump_label.c } static int -diff -urNp linux-3.0.9/kernel/kallsyms.c linux-3.0.9/kernel/kallsyms.c ---- linux-3.0.9/kernel/kallsyms.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/kallsyms.c 2011-11-12 12:47:14.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 description) @@ -63568,7 +64982,7 @@ diff -urNp linux-3.0.9/kernel/kallsyms.c linux-3.0.9/kernel/kallsyms.c #include <linux/kallsyms.h> #include <linux/module.h> #include <linux/init.h> -@@ -53,12 +56,33 @@ extern const unsigned long kallsyms_mark +@@ -53,12 +56,33 @@ extern const unsigned long kallsyms_markers[] __attribute__((weak)); static inline int is_kernel_inittext(unsigned long addr) { @@ -63602,7 +65016,7 @@ diff -urNp linux-3.0.9/kernel/kallsyms.c linux-3.0.9/kernel/kallsyms.c static inline int is_kernel_text(unsigned long addr) { if ((addr >= (unsigned long)_stext && addr <= (unsigned long)_etext) || -@@ -69,13 +93,28 @@ static inline int is_kernel_text(unsigne +@@ -69,13 +93,28 @@ static inline int is_kernel_text(unsigned long addr) static inline int is_kernel(unsigned long addr) { @@ -63631,7 +65045,7 @@ diff -urNp linux-3.0.9/kernel/kallsyms.c linux-3.0.9/kernel/kallsyms.c if (all_var) return is_kernel(addr); -@@ -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) static void reset_iter(struct kallsym_iter *iter, loff_t new_pos) { @@ -63639,7 +65053,7 @@ diff -urNp linux-3.0.9/kernel/kallsyms.c linux-3.0.9/kernel/kallsyms.c iter->nameoff = get_symbol_offset(new_pos); iter->pos = 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 = m->private; @@ -63651,7 +65065,7 @@ diff -urNp linux-3.0.9/kernel/kallsyms.c linux-3.0.9/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; @@ -63660,10 +65074,11 @@ diff -urNp linux-3.0.9/kernel/kallsyms.c linux-3.0.9/kernel/kallsyms.c if (!iter) return -ENOMEM; reset_iter(iter, 0); -diff -urNp linux-3.0.9/kernel/kexec.c linux-3.0.9/kernel/kexec.c ---- linux-3.0.9/kernel/kexec.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/kexec.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1033,7 +1033,8 @@ asmlinkage long compat_sys_kexec_load(un +diff --git a/kernel/kexec.c b/kernel/kexec.c +index 8d814cb..20e6552 100644 +--- a/kernel/kexec.c ++++ b/kernel/kexec.c +@@ -1033,7 +1033,8 @@ asmlinkage long compat_sys_kexec_load(unsigned long entry, unsigned long flags) { struct compat_kexec_segment in; @@ -63673,10 +65088,11 @@ diff -urNp linux-3.0.9/kernel/kexec.c linux-3.0.9/kernel/kexec.c unsigned long i, result; /* Don't allow clients that don't understand the native -diff -urNp linux-3.0.9/kernel/kmod.c linux-3.0.9/kernel/kmod.c ---- linux-3.0.9/kernel/kmod.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/kmod.c 2011-11-12 12:47:14.000000000 -0500 -@@ -73,13 +73,12 @@ char modprobe_path[KMOD_PATH_LEN] = "/sb +diff --git a/kernel/kmod.c b/kernel/kmod.c +index fabfe54..eac5a21 100644 +--- a/kernel/kmod.c ++++ b/kernel/kmod.c +@@ -73,13 +73,12 @@ char modprobe_path[KMOD_PATH_LEN] = "/sbin/modprobe"; * If module auto-loading support is disabled then this function * becomes a no-operation. */ @@ -63692,7 +65108,7 @@ diff -urNp linux-3.0.9/kernel/kmod.c linux-3.0.9/kernel/kmod.c static char *envp[] = { "HOME=/", "TERM=linux", "PATH=/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; @@ -63703,7 +65119,7 @@ diff -urNp linux-3.0.9/kernel/kmod.c linux-3.0.9/kernel/kmod.c if (ret >= MODULE_NAME_LEN) return -ENAMETOOLONG; -@@ -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; @@ -63724,7 +65140,7 @@ diff -urNp linux-3.0.9/kernel/kmod.c linux-3.0.9/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; } @@ -63781,10 +65197,11 @@ diff -urNp linux-3.0.9/kernel/kmod.c linux-3.0.9/kernel/kmod.c /* * If ret is 0, either ____call_usermodehelper failed and the -diff -urNp linux-3.0.9/kernel/kprobes.c linux-3.0.9/kernel/kprobes.c ---- linux-3.0.9/kernel/kprobes.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/kprobes.c 2011-11-12 12:47:14.000000000 -0500 -@@ -185,7 +185,7 @@ static kprobe_opcode_t __kprobes *__get_ +diff --git a/kernel/kprobes.c b/kernel/kprobes.c +index 7798181..2fcc39d 100644 +--- a/kernel/kprobes.c ++++ b/kernel/kprobes.c +@@ -185,7 +185,7 @@ static kprobe_opcode_t __kprobes *__get_insn_slot(struct kprobe_insn_cache *c) * kernel image and loaded module images reside. This is required * so x86_64 can correctly handle the %rip-relative fixups. */ @@ -63793,7 +65210,7 @@ diff -urNp linux-3.0.9/kernel/kprobes.c linux-3.0.9/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); @@ -63811,7 +65228,7 @@ diff -urNp linux-3.0.9/kernel/kprobes.c linux-3.0.9/kernel/kprobes.c const char *symbol_name; void *addr; struct kprobe_blackpoint *kb; -@@ -2062,7 +2062,7 @@ static int __kprobes show_kprobe_addr(st +@@ -2062,7 +2062,7 @@ static int __kprobes show_kprobe_addr(struct seq_file *pi, void *v) const char *sym = NULL; unsigned int i = *(loff_t *) v; unsigned long offset = 0; @@ -63820,9 +65237,10 @@ diff -urNp linux-3.0.9/kernel/kprobes.c linux-3.0.9/kernel/kprobes.c head = &kprobe_table[i]; preempt_disable(); -diff -urNp linux-3.0.9/kernel/lockdep.c linux-3.0.9/kernel/lockdep.c ---- linux-3.0.9/kernel/lockdep.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/lockdep.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/lockdep.c b/kernel/lockdep.c +index 298c927..0a5cd2a 100644 +--- a/kernel/lockdep.c ++++ b/kernel/lockdep.c @@ -583,6 +583,10 @@ static int static_obj(void *obj) end = (unsigned long) &_end, addr = (unsigned long) obj; @@ -63834,7 +65252,7 @@ diff -urNp linux-3.0.9/kernel/lockdep.c linux-3.0.9/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, unsigned int subclass, int force) if (!static_obj(lock->key)) { debug_locks_off(); printk("INFO: trying to register non-static key.\n"); @@ -63842,7 +65260,7 @@ diff -urNp linux-3.0.9/kernel/lockdep.c linux-3.0.9/kernel/lockdep.c printk("the code is fine but needs lockdep annotation.\n"); printk("turning off the locking correctness validator.\n"); dump_stack(); -@@ -2936,7 +2941,7 @@ static int __lock_acquire(struct lockdep +@@ -2936,7 +2941,7 @@ static int __lock_acquire(struct lockdep_map *lock, unsigned int subclass, if (!class) return 0; } @@ -63851,10 +65269,11 @@ diff -urNp linux-3.0.9/kernel/lockdep.c linux-3.0.9/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.0.9/kernel/lockdep_proc.c linux-3.0.9/kernel/lockdep_proc.c ---- linux-3.0.9/kernel/lockdep_proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/lockdep_proc.c 2011-11-12 12:47:14.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 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) static void print_name(struct seq_file *m, struct lock_class *class) { @@ -63863,9 +65282,10 @@ diff -urNp linux-3.0.9/kernel/lockdep_proc.c linux-3.0.9/kernel/lockdep_proc.c const char *name = class->name; if (!name) { -diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c ---- linux-3.0.9/kernel/module.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/module.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/module.c b/kernel/module.c +index 795bdc7..485cd3a 100644 +--- a/kernel/module.c ++++ b/kernel/module.c @@ -58,6 +58,7 @@ #include <linux/jump_label.h> #include <linux/pfn.h> @@ -63874,7 +65294,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c #define CREATE_TRACE_POINTS #include <trace/events/module.h> -@@ -119,7 +120,8 @@ static BLOCKING_NOTIFIER_HEAD(module_not +@@ -119,7 +120,8 @@ static BLOCKING_NOTIFIER_HEAD(module_notify_list); /* Bounds of module allocation, for speeding __module_address. * Protected by module_mutex. */ @@ -63884,7 +65304,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c 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 symsearch *arr, return true; list_for_each_entry_rcu(mod, &modules, list) { @@ -63893,7 +65313,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/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 symsearch *arr, #endif }; @@ -63902,7 +65322,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/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 module *mod) static int percpu_modalloc(struct module *mod, unsigned long size, unsigned long align) { @@ -63920,7 +65340,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c static inline bool sect_empty(const Elf_Shdr *sect) { return !(sect->sh_flags & SHF_ALLOC) || sect->sh_size == 0; -@@ -1632,21 +1634,21 @@ static void set_section_ro_nx(void *base +@@ -1632,21 +1634,21 @@ static void set_section_ro_nx(void *base, static void unset_module_core_ro_nx(struct module *mod) { @@ -63992,7 +65412,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c set_memory_ro); } } -@@ -1722,16 +1724,19 @@ static void free_module(struct module *m +@@ -1722,16 +1724,19 @@ static void free_module(struct module *mod) /* This may be NULL, but that's OK */ unset_module_init_ro_nx(mod); @@ -64015,7 +65435,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c #ifdef CONFIG_MPU update_protections(current->mm); -@@ -1800,10 +1805,31 @@ static int simplify_symbols(struct modul +@@ -1800,10 +1805,31 @@ static int simplify_symbols(struct module *mod, const struct load_info *info) unsigned int i; int ret = 0; const struct kernel_symbol *ksym; @@ -64047,7 +65467,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c switch (sym[i].st_shndx) { case SHN_COMMON: /* We compiled with -fno-common. These are not -@@ -1824,7 +1850,9 @@ static int simplify_symbols(struct modul +@@ -1824,7 +1850,9 @@ static int simplify_symbols(struct module *mod, const struct load_info *info) ksym = resolve_symbol_wait(mod, info, name); /* Ok if resolved. */ if (ksym && !IS_ERR(ksym)) { @@ -64057,7 +65477,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c break; } -@@ -1843,11 +1871,20 @@ static int simplify_symbols(struct modul +@@ -1843,11 +1871,20 @@ static int simplify_symbols(struct module *mod, const struct load_info *info) secbase = (unsigned long)mod_percpu(mod); else secbase = info->sechdrs[sym[i].st_shndx].sh_addr; @@ -64078,7 +65498,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c return ret; } -@@ -1931,22 +1968,12 @@ static void layout_sections(struct modul +@@ -1931,22 +1968,12 @@ static void layout_sections(struct module *mod, struct load_info *info) || s->sh_entsize != ~0UL || strstarts(sname, ".init")) continue; @@ -64105,7 +65525,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c } DEBUGP("Init section allocation order:\n"); -@@ -1960,23 +1987,13 @@ static void layout_sections(struct modul +@@ -1960,23 +1987,13 @@ static void layout_sections(struct module *mod, struct load_info *info) || s->sh_entsize != ~0UL || !strstarts(sname, ".init")) continue; @@ -64134,7 +65554,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c } } -@@ -2141,7 +2158,7 @@ static void layout_symtab(struct module +@@ -2141,7 +2158,7 @@ static void layout_symtab(struct module *mod, struct load_info *info) /* Put symbol section at end of init part of module. */ symsect->sh_flags |= SHF_ALLOC; @@ -64143,7 +65563,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c info->index.sym) | INIT_OFFSET_MASK; DEBUGP("\t%s\n", info->secstrings + symsect->sh_name); -@@ -2158,19 +2175,19 @@ static void layout_symtab(struct module +@@ -2158,19 +2175,19 @@ static void layout_symtab(struct module *mod, struct load_info *info) } /* Append room for core symbols at end of core part. */ @@ -64168,7 +65588,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c } static void add_kallsyms(struct module *mod, const struct load_info *info) -@@ -2186,11 +2203,13 @@ static void add_kallsyms(struct module * +@@ -2186,11 +2203,13 @@ static void add_kallsyms(struct module *mod, const struct load_info *info) /* Make sure we get permanent strtab: don't use info->strtab. */ mod->strtab = (void *)info->sechdrs[info->index.str].sh_addr; @@ -64183,7 +65603,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c src = mod->symtab; *dst = *src; for (ndst = i = 1; i < mod->num_symtab; ++i, ++src) { -@@ -2203,10 +2222,12 @@ static void add_kallsyms(struct module * +@@ -2203,10 +2222,12 @@ static void add_kallsyms(struct module *mod, const struct load_info *info) } mod->core_num_syms = ndst; @@ -64197,7 +65617,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c } #else static inline void layout_symtab(struct module *mod, struct load_info *info) -@@ -2235,17 +2256,33 @@ static void dynamic_debug_remove(struct +@@ -2235,17 +2256,33 @@ static void dynamic_debug_remove(struct _ddebug *debug) ddebug_remove_module(debug->modname); } @@ -64236,7 +65656,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c mutex_unlock(&module_mutex); } return ret; -@@ -2538,7 +2575,7 @@ static int move_module(struct module *mo +@@ -2538,7 +2575,7 @@ static int move_module(struct module *mod, struct load_info *info) void *ptr; /* Do the allocs. */ @@ -64245,7 +65665,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/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 -@@ -2548,23 +2585,50 @@ static int move_module(struct module *mo +@@ -2548,23 +2585,50 @@ static int move_module(struct module *mod, struct load_info *info) if (!ptr) return -ENOMEM; @@ -64304,7 +65724,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c /* Transfer each section which specifies SHF_ALLOC */ DEBUGP("final section addresses:\n"); -@@ -2575,16 +2639,45 @@ static int move_module(struct module *mo +@@ -2575,16 +2639,45 @@ static int move_module(struct module *mod, struct load_info *info) if (!(shdr->sh_flags & SHF_ALLOC)) continue; @@ -64357,7 +65777,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c DEBUGP("\t0x%lx %s\n", shdr->sh_addr, info->secstrings + shdr->sh_name); } -@@ -2635,12 +2728,12 @@ static void flush_module_icache(const st +@@ -2635,12 +2728,12 @@ static void flush_module_icache(const struct module *mod) * Do it before processing of module parameters, so the module * can provide parameter accessor functions of its own. */ @@ -64376,7 +65796,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c set_fs(old_fs); } -@@ -2712,8 +2805,10 @@ static void module_deallocate(struct mod +@@ -2712,8 +2805,10 @@ static void module_deallocate(struct module *mod, struct load_info *info) { kfree(info->strmap); percpu_modfree(mod); @@ -64389,7 +65809,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c } static int post_relocation(struct module *mod, const struct load_info *info) -@@ -2770,9 +2865,38 @@ static struct module *load_module(void _ +@@ -2770,9 +2865,38 @@ static struct module *load_module(void __user *umod, if (err) goto free_unload; @@ -64428,7 +65848,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c /* Fix up syms, so that st_value is a pointer to location. */ err = simplify_symbols(mod, &info); if (err < 0) -@@ -2788,13 +2912,6 @@ static struct module *load_module(void _ +@@ -2788,13 +2912,6 @@ static struct module *load_module(void __user *umod, flush_module_icache(mod); @@ -64442,7 +65862,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c /* Mark state as coming so strong_try_module_get() ignores us. */ mod->state = MODULE_STATE_COMING; -@@ -2854,11 +2971,10 @@ static struct module *load_module(void _ +@@ -2854,11 +2971,10 @@ static struct module *load_module(void __user *umod, unlock: mutex_unlock(&module_mutex); synchronize_sched(); @@ -64455,7 +65875,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c free_unload: module_unload_free(mod); free_module: -@@ -2899,16 +3015,16 @@ SYSCALL_DEFINE3(init_module, void __user +@@ -2899,16 +3015,16 @@ SYSCALL_DEFINE3(init_module, void __user *, umod, MODULE_STATE_COMING, mod); /* Set RO and NX regions for core */ @@ -64480,7 +65900,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c do_mod_ctors(mod); /* Start the module */ -@@ -2954,11 +3070,12 @@ SYSCALL_DEFINE3(init_module, void __user +@@ -2954,11 +3070,12 @@ SYSCALL_DEFINE3(init_module, void __user *, umod, mod->strtab = mod->core_strtab; #endif unset_module_init_ro_nx(mod); @@ -64498,7 +65918,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c mutex_unlock(&module_mutex); return 0; -@@ -2989,10 +3106,16 @@ static const char *get_ksymbol(struct mo +@@ -2989,10 +3106,16 @@ static const char *get_ksymbol(struct module *mod, unsigned long nextval; /* At worse, next value is at end of module */ @@ -64518,7 +65938,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c /* Scan for closest preceding symbol, and next symbol. (ELF starts real symbols at 1). */ -@@ -3238,7 +3361,7 @@ static int m_show(struct seq_file *m, vo +@@ -3238,7 +3361,7 @@ static int m_show(struct seq_file *m, void *p) char buf[8]; seq_printf(m, "%s %u", @@ -64527,7 +65947,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c print_unload_info(m, mod); /* Informative for users. */ -@@ -3247,7 +3370,7 @@ static int m_show(struct seq_file *m, vo +@@ -3247,7 +3370,7 @@ static int m_show(struct seq_file *m, void *p) mod->state == MODULE_STATE_COMING ? "Loading": "Live"); /* Used by oprofile and other similar tools. */ @@ -64536,7 +65956,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c /* Taints info */ if (mod->taints) -@@ -3283,7 +3406,17 @@ static const struct file_operations proc +@@ -3283,7 +3406,17 @@ static const struct file_operations proc_modules_operations = { static int __init proc_modules_init(void) { @@ -64554,7 +65974,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c return 0; } module_init(proc_modules_init); -@@ -3342,12 +3475,12 @@ struct module *__module_address(unsigned +@@ -3342,12 +3475,12 @@ struct module *__module_address(unsigned long addr) { struct module *mod; @@ -64570,7 +65990,7 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c return mod; return NULL; } -@@ -3381,11 +3514,20 @@ bool is_module_text_address(unsigned lon +@@ -3381,11 +3514,20 @@ bool is_module_text_address(unsigned long addr) */ struct module *__module_text_address(unsigned long addr) { @@ -64594,41 +66014,11 @@ diff -urNp linux-3.0.9/kernel/module.c linux-3.0.9/kernel/module.c mod = NULL; } return mod; -diff -urNp linux-3.0.9/kernel/mutex.c linux-3.0.9/kernel/mutex.c ---- linux-3.0.9/kernel/mutex.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/mutex.c 2011-11-12 12:47:14.000000000 -0500 -@@ -198,7 +198,7 @@ __mutex_lock_common(struct mutex *lock, - spin_lock_mutex(&lock->wait_lock, flags); - - debug_mutex_lock_common(lock, &waiter); -- debug_mutex_add_waiter(lock, &waiter, task_thread_info(task)); -+ debug_mutex_add_waiter(lock, &waiter, task); - - /* 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, - * 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); - -@@ -249,7 +248,7 @@ __mutex_lock_common(struct mutex *lock, - 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); - - /* set it to 0 if there are no waiters left: */ -diff -urNp linux-3.0.9/kernel/mutex-debug.c linux-3.0.9/kernel/mutex-debug.c ---- linux-3.0.9/kernel/mutex-debug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/mutex-debug.c 2011-11-12 12:47:14.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 *waiter) } void debug_mutex_add_waiter(struct mutex *lock, struct mutex_waiter *waiter, @@ -64656,10 +66046,11 @@ diff -urNp linux-3.0.9/kernel/mutex-debug.c linux-3.0.9/kernel/mutex-debug.c list_del_init(&waiter->list); waiter->task = NULL; -diff -urNp linux-3.0.9/kernel/mutex-debug.h linux-3.0.9/kernel/mutex-debug.h ---- linux-3.0.9/kernel/mutex-debug.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/mutex-debug.h 2011-11-12 12:47:14.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, @@ -64671,10 +66062,43 @@ diff -urNp linux-3.0.9/kernel/mutex-debug.h linux-3.0.9/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.0.9/kernel/padata.c linux-3.0.9/kernel/padata.c ---- linux-3.0.9/kernel/padata.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/padata.c 2011-11-12 12:47:14.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); + + debug_mutex_lock_common(lock, &waiter); +- debug_mutex_add_waiter(lock, &waiter, task_thread_info(task)); ++ debug_mutex_add_waiter(lock, &waiter, task); + + /* 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); + +@@ -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); + + /* 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 *pinst, padata->pd = pd; padata->cb_cpu = cb_cpu; @@ -64688,7 +66112,7 @@ diff -urNp linux-3.0.9/kernel/padata.c linux-3.0.9/kernel/padata.c target_cpu = padata_cpu_hash(padata); queue = 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); @@ -64697,10 +66121,11 @@ diff -urNp linux-3.0.9/kernel/padata.c linux-3.0.9/kernel/padata.c atomic_set(&pd->reorder_objects, 0); atomic_set(&pd->refcnt, 0); pd->pinst = pinst; -diff -urNp linux-3.0.9/kernel/panic.c linux-3.0.9/kernel/panic.c ---- linux-3.0.9/kernel/panic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/panic.c 2011-11-12 12:47:14.000000000 -0500 -@@ -369,7 +369,7 @@ static void warn_slowpath_common(const c +diff --git a/kernel/panic.c b/kernel/panic.c +index 6923167..40233c5 100644 +--- a/kernel/panic.c ++++ b/kernel/panic.c +@@ -369,7 +369,7 @@ static void warn_slowpath_common(const char *file, int line, void *caller, const char *board; printk(KERN_WARNING "------------[ cut here ]------------\n"); @@ -64719,9 +66144,10 @@ diff -urNp linux-3.0.9/kernel/panic.c linux-3.0.9/kernel/panic.c __builtin_return_address(0)); } EXPORT_SYMBOL(__stack_chk_fail); -diff -urNp linux-3.0.9/kernel/pid.c linux-3.0.9/kernel/pid.c ---- linux-3.0.9/kernel/pid.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/pid.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/pid.c b/kernel/pid.c +index 57a8346..bf76ba3 100644 +--- a/kernel/pid.c ++++ b/kernel/pid.c @@ -33,6 +33,7 @@ #include <linux/rculist.h> #include <linux/bootmem.h> @@ -64730,7 +66156,7 @@ diff -urNp linux-3.0.9/kernel/pid.c linux-3.0.9/kernel/pid.c #include <linux/pid_namespace.h> #include <linux/init_task.h> #include <linux/syscalls.h> -@@ -45,7 +46,7 @@ struct pid init_struct_pid = INIT_STRUCT +@@ -45,7 +46,7 @@ struct pid init_struct_pid = INIT_STRUCT_PID; int pid_max = PID_MAX_DEFAULT; @@ -64756,7 +66182,7 @@ diff -urNp linux-3.0.9/kernel/pid.c linux-3.0.9/kernel/pid.c } struct task_struct *find_task_by_vpid(pid_t vnr) -@@ -428,6 +436,12 @@ struct task_struct *find_task_by_vpid(pi +@@ -428,6 +436,12 @@ struct task_struct *find_task_by_vpid(pid_t vnr) return find_task_by_pid_ns(vnr, current->nsproxy->pid_ns); } @@ -64769,9 +66195,10 @@ diff -urNp linux-3.0.9/kernel/pid.c linux-3.0.9/kernel/pid.c struct pid *get_task_pid(struct task_struct *task, enum pid_type type) { struct pid *pid; -diff -urNp linux-3.0.9/kernel/posix-cpu-timers.c linux-3.0.9/kernel/posix-cpu-timers.c ---- linux-3.0.9/kernel/posix-cpu-timers.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/posix-cpu-timers.c 2011-11-12 12:47:14.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 <linux/posix-timers.h> #include <linux/errno.h> @@ -64797,9 +66224,10 @@ diff -urNp linux-3.0.9/kernel/posix-cpu-timers.c linux-3.0.9/kernel/posix-cpu-ti .clock_getres = thread_cpu_clock_getres, .clock_get = thread_cpu_clock_get, .timer_create = thread_cpu_timer_create, -diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c ---- linux-3.0.9/kernel/posix-timers.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/posix-timers.c 2011-11-12 12:47:14.000000000 -0500 +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 <linux/idr.h> #include <linux/posix-clock.h> @@ -64817,7 +66245,7 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c /* * 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) { @@ -64826,7 +66254,7 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c .clock_getres = hrtimer_get_res, .clock_get = posix_clock_realtime_get, .clock_set = 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 = common_timer_get, .timer_del = common_timer_del, }; @@ -64835,7 +66263,7 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c .clock_getres = hrtimer_get_res, .clock_get = posix_ktime_get_ts, .nsleep = 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 = common_timer_get, .timer_del = common_timer_del, }; @@ -64859,7 +66287,7 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c .clock_getres = hrtimer_get_res, .clock_get = posix_get_boottime, .nsleep = 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 = common_timer_del, }; @@ -64868,7 +66296,7 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/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 clock_id, return; } @@ -64877,7 +66305,7 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c } EXPORT_SYMBOL_GPL(posix_timers_register_clock); -@@ -519,9 +522,9 @@ static struct k_clock *clockid_to_kclock +@@ -519,9 +522,9 @@ static struct k_clock *clockid_to_kclock(const clockid_t id) return (id & CLOCKFD_MASK) == CLOCKFD ? &clock_posix_dynamic : &clock_posix_cpu; @@ -64889,7 +66317,7 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c } 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, which_clock, if (copy_from_user(&new_tp, tp, sizeof (*tp))) return -EFAULT; @@ -64903,10 +66331,11 @@ diff -urNp linux-3.0.9/kernel/posix-timers.c linux-3.0.9/kernel/posix-timers.c return kc->clock_set(which_clock, &new_tp); } -diff -urNp linux-3.0.9/kernel/power/poweroff.c linux-3.0.9/kernel/power/poweroff.c ---- linux-3.0.9/kernel/power/poweroff.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/power/poweroff.c 2011-11-12 12:47:14.000000000 -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 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 = { .enable_mask = SYSRQ_ENABLE_BOOT, }; @@ -64915,10 +66344,11 @@ diff -urNp linux-3.0.9/kernel/power/poweroff.c linux-3.0.9/kernel/power/poweroff { register_sysrq_key('o', &sysrq_poweroff_op); return 0; -diff -urNp linux-3.0.9/kernel/power/process.c linux-3.0.9/kernel/power/process.c ---- linux-3.0.9/kernel/power/process.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/power/process.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 = false; @@ -64926,7 +66356,7 @@ diff -urNp linux-3.0.9/kernel/power/process.c linux-3.0.9/kernel/power/process.c do_gettimeofday(&start); -@@ -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) while (true) { todo = 0; @@ -64935,7 +66365,7 @@ diff -urNp linux-3.0.9/kernel/power/process.c linux-3.0.9/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. */ @@ -64951,7 +66381,7 @@ diff -urNp linux-3.0.9/kernel/power/process.c linux-3.0.9/kernel/power/process.c } while_each_thread(g, p); read_unlock(&tasklist_lock); -@@ -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 += wq_busy; } @@ -64960,10 +66390,11 @@ diff -urNp linux-3.0.9/kernel/power/process.c linux-3.0.9/kernel/power/process.c break; if (pm_wakeup_pending()) { -diff -urNp linux-3.0.9/kernel/printk.c linux-3.0.9/kernel/printk.c ---- linux-3.0.9/kernel/printk.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/printk.c 2011-11-12 12:47:14.000000000 -0500 -@@ -313,12 +313,17 @@ static int check_syslog_permissions(int +diff --git a/kernel/printk.c b/kernel/printk.c +index 084982f..1b753ad 100644 +--- a/kernel/printk.c ++++ b/kernel/printk.c +@@ -313,12 +313,17 @@ static int check_syslog_permissions(int type, bool from_file) if (from_file && type != SYSLOG_ACTION_OPEN) return 0; @@ -64982,9 +66413,10 @@ diff -urNp linux-3.0.9/kernel/printk.c linux-3.0.9/kernel/printk.c "but no CAP_SYSLOG (deprecated).\n"); return 0; } -diff -urNp linux-3.0.9/kernel/profile.c linux-3.0.9/kernel/profile.c ---- linux-3.0.9/kernel/profile.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/profile.c 2011-11-12 12:47:14.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; @@ -65003,7 +66435,7 @@ diff -urNp linux-3.0.9/kernel/profile.c linux-3.0.9/kernel/profile.c hits[i].hits = hits[i].pc = 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, unsigned int nr_hits) * Add the current hit(s) and flush the write-queue out * to the global buffer: */ @@ -65015,7 +66447,7 @@ diff -urNp linux-3.0.9/kernel/profile.c linux-3.0.9/kernel/profile.c hits[i].pc = hits[i].hits = 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, unsigned int nr_hits) { unsigned long pc; pc = ((unsigned long)__pc - (unsigned long)_stext) >> prof_shift; @@ -65024,7 +66456,7 @@ diff -urNp linux-3.0.9/kernel/profile.c linux-3.0.9/kernel/profile.c } #endif /* !CONFIG_SMP */ -@@ -517,7 +517,7 @@ read_profile(struct file *file, char __u +@@ -517,7 +517,7 @@ read_profile(struct file *file, char __user *buf, size_t count, loff_t *ppos) return -EFAULT; buf++; p++; count--; read++; } @@ -65033,7 +66465,7 @@ diff -urNp linux-3.0.9/kernel/profile.c linux-3.0.9/kernel/profile.c if (copy_to_user(buf, (void *)pnt, count)) return -EFAULT; read += count; -@@ -548,7 +548,7 @@ static ssize_t write_profile(struct file +@@ -548,7 +548,7 @@ static ssize_t write_profile(struct file *file, const char __user *buf, } #endif profile_discard_flip_buffers(); @@ -65042,10 +66474,11 @@ diff -urNp linux-3.0.9/kernel/profile.c linux-3.0.9/kernel/profile.c return count; } -diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c ---- linux-3.0.9/kernel/ptrace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/ptrace.c 2011-11-12 12:47:14.000000000 -0500 -@@ -132,7 +132,8 @@ int ptrace_check_attach(struct task_stru +diff --git a/kernel/ptrace.c b/kernel/ptrace.c +index 2df1157..34df1b0 100644 +--- a/kernel/ptrace.c ++++ b/kernel/ptrace.c +@@ -132,7 +132,8 @@ int ptrace_check_attach(struct task_struct *child, int kill) return ret; } @@ -65055,7 +66488,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c { const struct cred *cred = current_cred(), *tcred; -@@ -158,7 +159,8 @@ int __ptrace_may_access(struct task_stru +@@ -158,7 +159,8 @@ int __ptrace_may_access(struct task_struct *task, unsigned int mode) cred->gid == tcred->sgid && cred->gid == tcred->gid)) goto ok; @@ -65076,7 +66509,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c return -EPERM; return security_ptrace_access_check(task, mode); -@@ -177,7 +181,16 @@ bool ptrace_may_access(struct task_struc +@@ -177,7 +181,16 @@ bool ptrace_may_access(struct task_struct *task, unsigned int mode) { int err; task_lock(task); @@ -65094,7 +66527,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c task_unlock(task); return !err; } -@@ -205,7 +218,7 @@ static int ptrace_attach(struct task_str +@@ -205,7 +218,7 @@ static int ptrace_attach(struct task_struct *task) goto out; task_lock(task); @@ -65103,7 +66536,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c task_unlock(task); if (retval) goto unlock_creds; -@@ -218,7 +231,7 @@ static int ptrace_attach(struct task_str +@@ -218,7 +231,7 @@ static int ptrace_attach(struct task_struct *task) goto unlock_tasklist; task->ptrace = PT_PTRACED; @@ -65112,7 +66545,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c task->ptrace |= PT_PTRACE_CAP; __ptrace_link(task, current); -@@ -406,6 +419,8 @@ int ptrace_readdata(struct task_struct * +@@ -406,6 +419,8 @@ int ptrace_readdata(struct task_struct *tsk, unsigned long src, char __user *dst { int copied = 0; @@ -65121,7 +66554,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c while (len > 0) { char buf[128]; int this_len, retval; -@@ -417,7 +432,7 @@ int ptrace_readdata(struct task_struct * +@@ -417,7 +432,7 @@ int ptrace_readdata(struct task_struct *tsk, unsigned long src, char __user *dst break; return -EIO; } @@ -65130,7 +66563,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c return -EFAULT; copied += retval; src += retval; -@@ -431,6 +446,8 @@ int ptrace_writedata(struct task_struct +@@ -431,6 +446,8 @@ int ptrace_writedata(struct task_struct *tsk, char __user *src, unsigned long ds { int copied = 0; @@ -65139,7 +66572,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c while (len > 0) { char buf[128]; int this_len, retval; -@@ -613,9 +630,11 @@ int ptrace_request(struct task_struct *c +@@ -613,9 +630,11 @@ int ptrace_request(struct task_struct *child, long request, { int ret = -EIO; siginfo_t siginfo; @@ -65152,7 +66585,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c switch (request) { case PTRACE_PEEKTEXT: case PTRACE_PEEKDATA: -@@ -761,14 +780,21 @@ SYSCALL_DEFINE4(ptrace, long, request, l +@@ -761,14 +780,21 @@ SYSCALL_DEFINE4(ptrace, long, request, long, pid, unsigned long, addr, goto out; } @@ -65175,7 +66608,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c goto out_put_task_struct; } -@@ -793,7 +819,7 @@ int generic_ptrace_peekdata(struct task_ +@@ -793,7 +819,7 @@ int generic_ptrace_peekdata(struct task_struct *tsk, unsigned long addr, copied = access_process_vm(tsk, addr, &tmp, sizeof(tmp), 0); if (copied != sizeof(tmp)) return -EIO; @@ -65184,7 +66617,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c } int generic_ptrace_pokedata(struct task_struct *tsk, unsigned long addr, -@@ -816,6 +842,8 @@ int compat_ptrace_request(struct task_st +@@ -816,6 +842,8 @@ int compat_ptrace_request(struct task_struct *child, compat_long_t request, siginfo_t siginfo; int ret; @@ -65193,7 +66626,7 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c switch (request) { case PTRACE_PEEKTEXT: case PTRACE_PEEKDATA: -@@ -903,14 +931,21 @@ asmlinkage long compat_sys_ptrace(compat +@@ -903,14 +931,21 @@ asmlinkage long compat_sys_ptrace(compat_long_t request, compat_long_t pid, goto out; } @@ -65216,10 +66649,11 @@ diff -urNp linux-3.0.9/kernel/ptrace.c linux-3.0.9/kernel/ptrace.c goto out_put_task_struct; } -diff -urNp linux-3.0.9/kernel/rcutorture.c linux-3.0.9/kernel/rcutorture.c ---- linux-3.0.9/kernel/rcutorture.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/rcutorture.c 2011-11-12 12:47:14.000000000 -0500 -@@ -138,12 +138,12 @@ static DEFINE_PER_CPU(long [RCU_TORTURE_ +diff --git a/kernel/rcutorture.c b/kernel/rcutorture.c +index 2e138db..781b267 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) = { 0 }; static DEFINE_PER_CPU(long [RCU_TORTURE_PIPE_LEN + 1], rcu_torture_batch) = { 0 }; @@ -65270,7 +66704,7 @@ diff -urNp linux-3.0.9/kernel/rcutorture.c linux-3.0.9/kernel/rcutorture.c if (++rp->rtort_pipe_count >= RCU_TORTURE_PIPE_LEN) { rp->rtort_mbtest = 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 rcu_torture *p) i = rp->rtort_pipe_count; if (i > RCU_TORTURE_PIPE_LEN) i = RCU_TORTURE_PIPE_LEN; @@ -65288,7 +66722,7 @@ diff -urNp linux-3.0.9/kernel/rcutorture.c linux-3.0.9/kernel/rcutorture.c old_rp->rtort_pipe_count++; cur_ops->deferred_free(old_rp); } -@@ -951,7 +951,7 @@ static void rcu_torture_timer(unsigned l +@@ -951,7 +951,7 @@ static void rcu_torture_timer(unsigned long unused) return; } if (p->rtort_mbtest == 0) @@ -65379,9 +66813,10 @@ diff -urNp linux-3.0.9/kernel/rcutorture.c linux-3.0.9/kernel/rcutorture.c for_each_possible_cpu(cpu) { for (i = 0; i < RCU_TORTURE_PIPE_LEN + 1; i++) { per_cpu(rcu_torture_count, cpu)[i] = 0; -diff -urNp linux-3.0.9/kernel/rcutree.c linux-3.0.9/kernel/rcutree.c ---- linux-3.0.9/kernel/rcutree.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/rcutree.c 2011-11-12 12:47:14.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 */ @@ -65446,7 +66881,7 @@ diff -urNp linux-3.0.9/kernel/rcutree.c linux-3.0.9/kernel/rcutree.c return 0; } -@@ -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; @@ -65455,7 +66890,7 @@ diff -urNp linux-3.0.9/kernel/rcutree.c linux-3.0.9/kernel/rcutree.c snap = (unsigned long)rdp->dynticks_snap; /* -@@ -1470,7 +1470,7 @@ __rcu_process_callbacks(struct rcu_state +@@ -1470,7 +1470,7 @@ __rcu_process_callbacks(struct rcu_state *rsp, struct rcu_data *rdp) /* * Do softirq processing for the current CPU. */ @@ -65464,9 +66899,10 @@ diff -urNp linux-3.0.9/kernel/rcutree.c linux-3.0.9/kernel/rcutree.c { __rcu_process_callbacks(&rcu_sched_state, &__get_cpu_var(rcu_sched_data)); -diff -urNp linux-3.0.9/kernel/rcutree.h linux-3.0.9/kernel/rcutree.h ---- linux-3.0.9/kernel/rcutree.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/rcutree.h 2011-11-12 12:47:14.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. */ @@ -65476,9 +66912,10 @@ diff -urNp linux-3.0.9/kernel/rcutree.h linux-3.0.9/kernel/rcutree.h }; /* RCU's kthread states for tracing. */ -diff -urNp linux-3.0.9/kernel/rcutree_plugin.h linux-3.0.9/kernel/rcutree_plugin.h ---- linux-3.0.9/kernel/rcutree_plugin.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/rcutree_plugin.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/rcutree_plugin.h b/kernel/rcutree_plugin.h +index 8aafbb8..754d4ad 100644 +--- a/kernel/rcutree_plugin.h ++++ b/kernel/rcutree_plugin.h @@ -822,7 +822,7 @@ void synchronize_rcu_expedited(void) /* Clean up and exit. */ @@ -65488,7 +66925,7 @@ diff -urNp linux-3.0.9/kernel/rcutree_plugin.h linux-3.0.9/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); #else /* #ifndef CONFIG_SMP */ @@ -65541,10 +66978,11 @@ diff -urNp linux-3.0.9/kernel/rcutree_plugin.h linux-3.0.9/kernel/rcutree_plugin put_online_cpus(); } -diff -urNp linux-3.0.9/kernel/relay.c linux-3.0.9/kernel/relay.c ---- linux-3.0.9/kernel/relay.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/relay.c 2011-11-12 12:47:14.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; @@ -65553,10 +66991,11 @@ diff -urNp linux-3.0.9/kernel/relay.c linux-3.0.9/kernel/relay.c if (rbuf->subbufs_produced == rbuf->subbufs_consumed) return 0; if (splice_grow_spd(pipe, &spd)) -diff -urNp linux-3.0.9/kernel/resource.c linux-3.0.9/kernel/resource.c ---- linux-3.0.9/kernel/resource.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/resource.c 2011-11-12 12:47:14.000000000 -0500 -@@ -141,8 +141,18 @@ static const struct file_operations proc +diff --git a/kernel/resource.c b/kernel/resource.c +index 3ff4017..72d77ae 100644 +--- a/kernel/resource.c ++++ b/kernel/resource.c +@@ -141,8 +141,18 @@ static const struct file_operations proc_iomem_operations = { static int __init ioresources_init(void) { @@ -65575,9 +67014,10 @@ diff -urNp linux-3.0.9/kernel/resource.c linux-3.0.9/kernel/resource.c return 0; } __initcall(ioresources_init); -diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester.c ---- linux-3.0.9/kernel/rtmutex-tester.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/rtmutex-tester.c 2011-11-12 12:47:14.000000000 -0500 +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 @@ -65587,7 +67027,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester 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) case RTTEST_LOCKCONT: td->mutexes[td->opdata] = 1; @@ -65596,7 +67036,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester return 0; 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; case RTTEST_RESETEVENT: @@ -65605,7 +67045,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester return 0; 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; td->mutexes[id] = 1; @@ -65617,7 +67057,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester td->mutexes[id] = 4; return 0; -@@ -104,9 +104,9 @@ static int handle_op(struct test_thread_ +@@ -104,9 +104,9 @@ static int handle_op(struct test_thread_data *td, int lockwakeup) return ret; td->mutexes[id] = 1; @@ -65629,7 +67069,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester td->mutexes[id] = ret ? 0 : 4; return ret ? -EINTR : 0; -@@ -115,9 +115,9 @@ static int handle_op(struct test_thread_ +@@ -115,9 +115,9 @@ static int handle_op(struct test_thread_data *td, int lockwakeup) if (id < 0 || id >= MAX_RT_TEST_MUTEXES || td->mutexes[id] != 4) return ret; @@ -65641,7 +67081,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester td->mutexes[id] = 0; return 0; -@@ -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; td->mutexes[dat] = 2; @@ -65650,7 +67090,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester break; 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; td->mutexes[dat] = 3; @@ -65659,7 +67099,7 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester break; 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; td->mutexes[dat] = 1; @@ -65668,30 +67108,10 @@ diff -urNp linux-3.0.9/kernel/rtmutex-tester.c linux-3.0.9/kernel/rtmutex-tester return; default: -diff -urNp linux-3.0.9/kernel/sched_autogroup.c linux-3.0.9/kernel/sched_autogroup.c ---- linux-3.0.9/kernel/sched_autogroup.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/sched_autogroup.c 2011-11-12 12:47:14.000000000 -0500 -@@ -7,7 +7,7 @@ - - unsigned int __read_mostly sysctl_sched_autogroup_enabled = 1; - static struct autogroup autogroup_default; --static atomic_t autogroup_seq_nr; -+static atomic_unchecked_t autogroup_seq_nr; - - static void __init autogroup_init(struct task_struct *init_task) - { -@@ -78,7 +78,7 @@ static inline struct autogroup *autogrou - - kref_init(&ag->kref); - init_rwsem(&ag->lock); -- ag->id = atomic_inc_return(&autogroup_seq_nr); -+ ag->id = atomic_inc_return_unchecked(&autogroup_seq_nr); - ag->tg = tg; - #ifdef CONFIG_RT_GROUP_SCHED - /* -diff -urNp linux-3.0.9/kernel/sched.c linux-3.0.9/kernel/sched.c ---- linux-3.0.9/kernel/sched.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/sched.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/sched.c b/kernel/sched.c +index 063d7a4..cee15b0 100644 +--- a/kernel/sched.c ++++ b/kernel/sched.c @@ -4227,6 +4227,8 @@ static void __sched __schedule(void) struct rq *rq; int cpu; @@ -65701,7 +67121,7 @@ diff -urNp linux-3.0.9/kernel/sched.c linux-3.0.9/kernel/sched.c need_resched: preempt_disable(); cpu = smp_processor_id(); -@@ -4920,6 +4922,8 @@ int can_nice(const struct task_struct *p +@@ -4920,6 +4922,8 @@ int can_nice(const struct task_struct *p, const int nice) /* convert nice value [19,-20] to rlimit style value [1,40] */ int nice_rlim = 20 - nice; @@ -65728,10 +67148,33 @@ diff -urNp linux-3.0.9/kernel/sched.c linux-3.0.9/kernel/sched.c /* can't set/change the rt policy */ if (policy != p->policy && !rlim_rtprio) return -EPERM; -diff -urNp linux-3.0.9/kernel/sched_fair.c linux-3.0.9/kernel/sched_fair.c ---- linux-3.0.9/kernel/sched_fair.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/sched_fair.c 2011-11-12 12:47:14.000000000 -0500 -@@ -4050,7 +4050,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 @@ + + unsigned int __read_mostly sysctl_sched_autogroup_enabled = 1; + static struct autogroup autogroup_default; +-static atomic_t autogroup_seq_nr; ++static atomic_unchecked_t autogroup_seq_nr; + + static void __init autogroup_init(struct task_struct *init_task) + { +@@ -78,7 +78,7 @@ static inline struct autogroup *autogroup_create(void) + + kref_init(&ag->kref); + init_rwsem(&ag->lock); +- ag->id = atomic_inc_return(&autogroup_seq_nr); ++ ag->id = atomic_inc_return_unchecked(&autogroup_seq_nr); + ag->tg = tg; + #ifdef CONFIG_RT_GROUP_SCHED + /* +diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c +index c768588..f6c5ce6 100644 +--- a/kernel/sched_fair.c ++++ b/kernel/sched_fair.c +@@ -4050,7 +4050,7 @@ static void nohz_idle_balance(int this_cpu, enum cpu_idle_type idle) { } * run_rebalance_domains is triggered when needed from the scheduler tick. * Also triggered for nohz idle balancing (with nohz_balancing_kick set). */ @@ -65740,10 +67183,11 @@ diff -urNp linux-3.0.9/kernel/sched_fair.c linux-3.0.9/kernel/sched_fair.c { int this_cpu = smp_processor_id(); struct rq *this_rq = cpu_rq(this_cpu); -diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c ---- linux-3.0.9/kernel/signal.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/signal.c 2011-11-12 12:47:14.000000000 -0500 -@@ -45,12 +45,12 @@ static struct kmem_cache *sigqueue_cache +diff --git a/kernel/signal.c b/kernel/signal.c +index 43fee1c..03a4485 100644 +--- a/kernel/signal.c ++++ b/kernel/signal.c +@@ -45,12 +45,12 @@ static struct kmem_cache *sigqueue_cachep; int print_fatal_signals __read_mostly; @@ -65758,7 +67202,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c { /* Is it explicitly or implicitly ignored? */ return handler == 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, int sig) static int sig_task_ignored(struct task_struct *t, int sig, int from_ancestor_ns) { @@ -65767,7 +67211,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c handler = sig_handler(t, sig); -@@ -320,6 +320,9 @@ __sigqueue_alloc(int sig, struct task_st +@@ -320,6 +320,9 @@ __sigqueue_alloc(int sig, struct task_struct *t, gfp_t flags, int override_rlimi atomic_inc(&user->sigpending); rcu_read_unlock(); @@ -65777,7 +67221,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c if (override_rlimit || atomic_read(&user->sigpending) <= task_rlimit(t, RLIMIT_SIGPENDING)) { -@@ -444,7 +447,7 @@ flush_signal_handlers(struct task_struct +@@ -444,7 +447,7 @@ flush_signal_handlers(struct task_struct *t, int force_default) int unhandled_signal(struct task_struct *tsk, int sig) { @@ -65786,7 +67230,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c if (is_global_init(tsk)) return 1; if (handler != SIG_IGN && handler != SIG_DFL) -@@ -770,6 +773,13 @@ static int check_kill_permission(int sig +@@ -770,6 +773,13 @@ static int check_kill_permission(int sig, struct siginfo *info, } } @@ -65800,7 +67244,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c return security_task_kill(t, info, sig, 0); } -@@ -1092,7 +1102,7 @@ __group_send_sig_info(int sig, struct si +@@ -1092,7 +1102,7 @@ __group_send_sig_info(int sig, struct siginfo *info, struct task_struct *p) return send_signal(sig, info, p, 1); } @@ -65809,7 +67253,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c specific_send_sig_info(int sig, struct siginfo *info, struct task_struct *t) { return send_signal(sig, info, t, 0); -@@ -1129,6 +1139,7 @@ force_sig_info(int sig, struct siginfo * +@@ -1129,6 +1139,7 @@ force_sig_info(int sig, struct siginfo *info, struct task_struct *t) unsigned long int flags; int ret, blocked, ignored; struct k_sigaction *action; @@ -65817,7 +67261,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c spin_lock_irqsave(&t->sighand->siglock, flags); action = &t->sighand->action[sig-1]; -@@ -1143,9 +1154,18 @@ force_sig_info(int sig, struct siginfo * +@@ -1143,9 +1154,18 @@ force_sig_info(int sig, struct siginfo *info, struct task_struct *t) } if (action->sa.sa_handler == SIG_DFL) t->signal->flags &= ~SIGNAL_UNKILLABLE; @@ -65836,7 +67280,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c return ret; } -@@ -1212,8 +1232,11 @@ int group_send_sig_info(int sig, struct +@@ -1212,8 +1232,11 @@ int group_send_sig_info(int sig, struct siginfo *info, struct task_struct *p) ret = check_kill_permission(sig, info, p); rcu_read_unlock(); @@ -65858,7 +67302,7 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c BUG_ON((exit_code & (0x7f | ~0xffff)) != SIGTRAP); memset(&info, 0, sizeof info); -@@ -2637,7 +2662,15 @@ do_send_specific(pid_t tgid, pid_t pid, +@@ -2637,7 +2662,15 @@ do_send_specific(pid_t tgid, pid_t pid, int sig, struct siginfo *info) int error = -ESRCH; rcu_read_lock(); @@ -65875,10 +67319,11 @@ diff -urNp linux-3.0.9/kernel/signal.c linux-3.0.9/kernel/signal.c if (p && (tgid <= 0 || task_tgid_vnr(p) == tgid)) { error = check_kill_permission(sig, info, p); /* -diff -urNp linux-3.0.9/kernel/smp.c linux-3.0.9/kernel/smp.c ---- linux-3.0.9/kernel/smp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/smp.c 2011-11-12 12:47:14.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); @@ -65905,10 +67350,11 @@ diff -urNp linux-3.0.9/kernel/smp.c linux-3.0.9/kernel/smp.c { raw_spin_unlock_irq(&call_function.lock); } -diff -urNp linux-3.0.9/kernel/softirq.c linux-3.0.9/kernel/softirq.c ---- linux-3.0.9/kernel/softirq.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/softirq.c 2011-11-12 12:47:14.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 DEFINE_PER_CPU(struct task_struct *, ksoftirqd); @@ -65940,7 +67386,7 @@ diff -urNp linux-3.0.9/kernel/softirq.c linux-3.0.9/kernel/softirq.c } /* -@@ -441,7 +443,7 @@ void __tasklet_hi_schedule_first(struct +@@ -441,7 +443,7 @@ void __tasklet_hi_schedule_first(struct tasklet_struct *t) EXPORT_SYMBOL(__tasklet_hi_schedule_first); @@ -65949,7 +67395,7 @@ diff -urNp linux-3.0.9/kernel/softirq.c linux-3.0.9/kernel/softirq.c { struct tasklet_struct *list; -@@ -476,7 +478,7 @@ static void tasklet_action(struct softir +@@ -476,7 +478,7 @@ static void tasklet_action(struct softirq_action *a) } } @@ -65958,10 +67404,11 @@ diff -urNp linux-3.0.9/kernel/softirq.c linux-3.0.9/kernel/softirq.c { struct tasklet_struct *list; -diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c ---- linux-3.0.9/kernel/sys.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/sys.c 2011-11-12 12:47:14.000000000 -0500 -@@ -158,6 +158,12 @@ static int set_one_prio(struct task_stru +diff --git a/kernel/sys.c b/kernel/sys.c +index f88dadc..9061ebd 100644 +--- a/kernel/sys.c ++++ b/kernel/sys.c +@@ -158,6 +158,12 @@ static int set_one_prio(struct task_struct *p, int niceval, int error) error = -EACCES; goto out; } @@ -65974,7 +67421,7 @@ diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c no_nice = security_task_setnice(p, niceval); if (no_nice) { error = no_nice; -@@ -541,6 +547,9 @@ SYSCALL_DEFINE2(setregid, gid_t, rgid, g +@@ -541,6 +547,9 @@ SYSCALL_DEFINE2(setregid, gid_t, rgid, gid_t, egid) goto error; } @@ -66018,7 +67465,7 @@ diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c free_uid(new->user); new->user = new_user; -@@ -650,6 +670,9 @@ SYSCALL_DEFINE2(setreuid, uid_t, ruid, u +@@ -650,6 +670,9 @@ SYSCALL_DEFINE2(setreuid, uid_t, ruid, uid_t, euid) goto error; } @@ -66041,7 +67488,7 @@ diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c if (nsown_capable(CAP_SETUID)) { new->suid = new->uid = uid; if (uid != old->uid) { -@@ -748,6 +777,9 @@ SYSCALL_DEFINE3(setresuid, uid_t, ruid, +@@ -748,6 +777,9 @@ SYSCALL_DEFINE3(setresuid, uid_t, ruid, uid_t, euid, uid_t, suid) goto error; } @@ -66051,7 +67498,7 @@ diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c if (ruid != (uid_t) -1) { new->uid = ruid; if (ruid != old->uid) { -@@ -812,6 +844,9 @@ SYSCALL_DEFINE3(setresgid, gid_t, rgid, +@@ -812,6 +844,9 @@ SYSCALL_DEFINE3(setresgid, gid_t, rgid, gid_t, egid, gid_t, sgid) goto error; } @@ -66096,7 +67543,7 @@ diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c abort_creds(new); return old_fsgid; -@@ -1205,19 +1248,19 @@ SYSCALL_DEFINE1(olduname, struct oldold_ +@@ -1205,19 +1248,19 @@ SYSCALL_DEFINE1(olduname, struct oldold_utsname __user *, name) return -EFAULT; down_read(&uts_sem); @@ -66121,7 +67568,7 @@ diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c __OLD_UTS_LEN); error |= __put_user(0, name->machine + __OLD_UTS_LEN); up_read(&uts_sem); -@@ -1680,7 +1723,7 @@ SYSCALL_DEFINE5(prctl, int, option, unsi +@@ -1680,7 +1723,7 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long, arg2, unsigned long, arg3, error = get_dumpable(me->mm); break; case PR_SET_DUMPABLE: @@ -66130,75 +67577,10 @@ diff -urNp linux-3.0.9/kernel/sys.c linux-3.0.9/kernel/sys.c error = -EINVAL; break; } -diff -urNp linux-3.0.9/kernel/sysctl_binary.c linux-3.0.9/kernel/sysctl_binary.c ---- linux-3.0.9/kernel/sysctl_binary.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/sysctl_binary.c 2011-11-12 12:47:14.000000000 -0500 -@@ -989,7 +989,7 @@ static ssize_t bin_intvec(struct file *f - int i; - - set_fs(KERNEL_DS); -- result = vfs_read(file, buffer, BUFSZ - 1, &pos); -+ result = vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &pos); - set_fs(old_fs); - if (result < 0) - goto out_kfree; -@@ -1034,7 +1034,7 @@ static ssize_t bin_intvec(struct file *f - } - - set_fs(KERNEL_DS); -- result = vfs_write(file, buffer, str - buffer, &pos); -+ result = vfs_write(file, (const char __force_user *)buffer, str - buffer, &pos); - set_fs(old_fs); - if (result < 0) - goto out_kfree; -@@ -1067,7 +1067,7 @@ static ssize_t bin_ulongvec(struct file - int i; - - set_fs(KERNEL_DS); -- result = vfs_read(file, buffer, BUFSZ - 1, &pos); -+ result = vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &pos); - set_fs(old_fs); - if (result < 0) - goto out_kfree; -@@ -1112,7 +1112,7 @@ static ssize_t bin_ulongvec(struct file - } - - set_fs(KERNEL_DS); -- result = vfs_write(file, buffer, str - buffer, &pos); -+ result = vfs_write(file, (const char __force_user *)buffer, str - buffer, &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; - - set_fs(KERNEL_DS); -- result = vfs_read(file, buf, sizeof(buf) - 1, &pos); -+ result = 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; - - set_fs(KERNEL_DS); -- result = vfs_read(file, buf, sizeof(buf) - 1, &pos); -+ result = 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); - - set_fs(KERNEL_DS); -- result = vfs_write(file, buf, len, &pos); -+ result = vfs_write(file, (const char __force_user *)buf, len, &pos); - set_fs(old_fs); - if (result < 0) - goto out; -diff -urNp linux-3.0.9/kernel/sysctl.c linux-3.0.9/kernel/sysctl.c ---- linux-3.0.9/kernel/sysctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/sysctl.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/sysctl.c b/kernel/sysctl.c +index f175d98..87202ca 100644 +--- a/kernel/sysctl.c ++++ b/kernel/sysctl.c @@ -85,6 +85,13 @@ @@ -66213,7 +67595,7 @@ diff -urNp linux-3.0.9/kernel/sysctl.c linux-3.0.9/kernel/sysctl.c /* 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, int write, } #endif @@ -66328,7 +67710,7 @@ diff -urNp linux-3.0.9/kernel/sysctl.c linux-3.0.9/kernel/sysctl.c if (root->permissions) mode = root->permissions(root, current->nsproxy, table); -@@ -2118,6 +2178,16 @@ int proc_dostring(struct ctl_table *tabl +@@ -2118,6 +2178,16 @@ int proc_dostring(struct ctl_table *table, int write, buffer, lenp, ppos); } @@ -66345,7 +67727,7 @@ diff -urNp linux-3.0.9/kernel/sysctl.c linux-3.0.9/kernel/sysctl.c static size_t proc_skip_spaces(char **buf) { size_t ret; -@@ -2223,6 +2293,8 @@ static int proc_put_long(void __user **b +@@ -2223,6 +2293,8 @@ static int proc_put_long(void __user **buf, size_t *size, unsigned long val, len = strlen(tmp); if (len > *size) len = *size; @@ -66354,7 +67736,7 @@ diff -urNp linux-3.0.9/kernel/sysctl.c linux-3.0.9/kernel/sysctl.c if (copy_to_user(*buf, tmp, len)) return -EFAULT; *size -= len; -@@ -2539,8 +2611,11 @@ static int __do_proc_doulongvec_minmax(v +@@ -2539,8 +2611,11 @@ static int __do_proc_doulongvec_minmax(void *data, struct ctl_table *table, int *i = val; } else { val = convdiv * (*i) / convmul; @@ -66367,7 +67749,7 @@ diff -urNp linux-3.0.9/kernel/sysctl.c linux-3.0.9/kernel/sysctl.c err = proc_put_long(&buffer, &left, val, false); if (err) break; -@@ -2935,6 +3010,12 @@ int proc_dostring(struct ctl_table *tabl +@@ -2935,6 +3010,12 @@ int proc_dostring(struct ctl_table *table, int write, return -ENOSYS; } @@ -66388,10 +67770,78 @@ diff -urNp linux-3.0.9/kernel/sysctl.c linux-3.0.9/kernel/sysctl.c EXPORT_SYMBOL(proc_doulongvec_minmax); EXPORT_SYMBOL(proc_doulongvec_ms_jiffies_minmax); EXPORT_SYMBOL(register_sysctl_table); -diff -urNp linux-3.0.9/kernel/sysctl_check.c linux-3.0.9/kernel/sysctl_check.c ---- linux-3.0.9/kernel/sysctl_check.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/sysctl_check.c 2011-11-12 12:47:14.000000000 -0500 -@@ -129,6 +129,7 @@ int sysctl_check_table(struct nsproxy *n +diff --git a/kernel/sysctl_binary.c b/kernel/sysctl_binary.c +index 3b8e028..ec43594 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; + + set_fs(KERNEL_DS); +- result = vfs_read(file, buffer, BUFSZ - 1, &pos); ++ result = vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &pos); + set_fs(old_fs); + if (result < 0) + goto out_kfree; +@@ -1034,7 +1034,7 @@ static ssize_t bin_intvec(struct file *file, + } + + set_fs(KERNEL_DS); +- result = vfs_write(file, buffer, str - buffer, &pos); ++ result = vfs_write(file, (const char __force_user *)buffer, str - buffer, &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; + + set_fs(KERNEL_DS); +- result = vfs_read(file, buffer, BUFSZ - 1, &pos); ++ result = vfs_read(file, (char __force_user *)buffer, BUFSZ - 1, &pos); + set_fs(old_fs); + if (result < 0) + goto out_kfree; +@@ -1112,7 +1112,7 @@ static ssize_t bin_ulongvec(struct file *file, + } + + set_fs(KERNEL_DS); +- result = vfs_write(file, buffer, str - buffer, &pos); ++ result = vfs_write(file, (const char __force_user *)buffer, str - buffer, &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; + + set_fs(KERNEL_DS); +- result = vfs_read(file, buf, sizeof(buf) - 1, &pos); ++ result = 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 *file, + __le16 dnaddr; + + set_fs(KERNEL_DS); +- result = vfs_read(file, buf, sizeof(buf) - 1, &pos); ++ result = 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 *file, + le16_to_cpu(dnaddr) & 0x3ff); + + set_fs(KERNEL_DS); +- result = vfs_write(file, buf, len, &pos); ++ result = 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 4e4932a..be244da 100644 +--- a/kernel/sysctl_check.c ++++ b/kernel/sysctl_check.c +@@ -129,6 +129,7 @@ int sysctl_check_table(struct nsproxy *namespaces, struct ctl_table *table) set_fail(&fail, table, "Directory with extra2"); } else { if ((table->proc_handler == proc_dostring) || @@ -66399,9 +67849,10 @@ diff -urNp linux-3.0.9/kernel/sysctl_check.c linux-3.0.9/kernel/sysctl_check.c (table->proc_handler == proc_dointvec) || (table->proc_handler == proc_dointvec_minmax) || (table->proc_handler == proc_dointvec_jiffies) || -diff -urNp linux-3.0.9/kernel/taskstats.c linux-3.0.9/kernel/taskstats.c ---- linux-3.0.9/kernel/taskstats.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/taskstats.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/taskstats.c b/kernel/taskstats.c +index fc0f220..c3b11a1 100644 +--- a/kernel/taskstats.c ++++ b/kernel/taskstats.c @@ -27,9 +27,12 @@ #include <linux/cgroup.h> #include <linux/fs.h> @@ -66425,9 +67876,26 @@ diff -urNp linux-3.0.9/kernel/taskstats.c linux-3.0.9/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.0.9/kernel/time/alarmtimer.c linux-3.0.9/kernel/time/alarmtimer.c ---- linux-3.0.9/kernel/time/alarmtimer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/time/alarmtimer.c 2011-11-12 12:47:14.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; + + 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 = *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 = 0; @@ -66437,10 +67905,11 @@ diff -urNp linux-3.0.9/kernel/time/alarmtimer.c linux-3.0.9/kernel/time/alarmtim .clock_getres = alarm_clock_getres, .clock_get = alarm_clock_get, .timer_create = alarm_timer_create, -diff -urNp linux-3.0.9/kernel/time/tick-broadcast.c linux-3.0.9/kernel/time/tick-broadcast.c ---- linux-3.0.9/kernel/time/tick-broadcast.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/time/tick-broadcast.c 2011-11-12 12:47:14.000000000 -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_device *dev, int cpu) * then clear the broadcast bit. */ if (!(dev->features & CLOCK_EVT_FEAT_C3STOP)) { @@ -66449,9 +67918,10 @@ diff -urNp linux-3.0.9/kernel/time/tick-broadcast.c linux-3.0.9/kernel/time/tick cpumask_clear_cpu(cpu, tick_get_broadcast_mask()); tick_broadcast_clear_oneshot(cpu); -diff -urNp linux-3.0.9/kernel/time/timekeeping.c linux-3.0.9/kernel/time/timekeeping.c ---- linux-3.0.9/kernel/time/timekeeping.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/time/timekeeping.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c +index 342408c..18c3098 100644 +--- a/kernel/time/timekeeping.c ++++ b/kernel/time/timekeeping.c @@ -14,6 +14,7 @@ #include <linux/init.h> #include <linux/mm.h> @@ -66460,7 +67930,7 @@ diff -urNp linux-3.0.9/kernel/time/timekeeping.c linux-3.0.9/kernel/time/timekee #include <linux/syscore_ops.h> #include <linux/clocksource.h> #include <linux/jiffies.h> -@@ -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 >= NSEC_PER_SEC) return -EINVAL; @@ -66469,10 +67939,11 @@ diff -urNp linux-3.0.9/kernel/time/timekeeping.c linux-3.0.9/kernel/time/timekee write_seqlock_irqsave(&xtime_lock, flags); timekeeping_forward_now(); -diff -urNp linux-3.0.9/kernel/time/timer_list.c linux-3.0.9/kernel/time/timer_list.c ---- linux-3.0.9/kernel/time/timer_list.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/time/timer_list.c 2011-11-12 12:47:14.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_bases); static void print_name_offset(struct seq_file *m, void *sym) { @@ -66501,7 +67972,7 @@ diff -urNp linux-3.0.9/kernel/time/timer_list.c linux-3.0.9/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; @@ -66513,9 +67984,10 @@ diff -urNp linux-3.0.9/kernel/time/timer_list.c linux-3.0.9/kernel/time/timer_li if (!pe) return -ENOMEM; return 0; -diff -urNp linux-3.0.9/kernel/time/timer_stats.c linux-3.0.9/kernel/time/timer_stats.c ---- linux-3.0.9/kernel/time/timer_stats.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/time/timer_stats.c 2011-11-12 12:47:14.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]; @@ -66534,7 +68006,7 @@ diff -urNp linux-3.0.9/kernel/time/timer_stats.c linux-3.0.9/kernel/time/timer_s } 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 @@ -66543,7 +68015,7 @@ diff -urNp linux-3.0.9/kernel/time/timer_stats.c linux-3.0.9/kernel/time/timer_s 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 pid, void *startf, static void print_name_offset(struct seq_file *m, unsigned long addr) { @@ -66560,7 +68032,7 @@ diff -urNp linux-3.0.9/kernel/time/timer_stats.c linux-3.0.9/kernel/time/timer_s } 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) seq_puts(m, "Timer Stats Version: v0.2\n"); seq_printf(m, "Sample period: %ld.%03ld s\n", period.tv_sec, ms); @@ -66572,7 +68044,7 @@ diff -urNp linux-3.0.9/kernel/time/timer_stats.c linux-3.0.9/kernel/time/timer_s for (i = 0; i < nr_entries; i++) { entry = 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; @@ -66584,24 +68056,10 @@ diff -urNp linux-3.0.9/kernel/time/timer_stats.c linux-3.0.9/kernel/time/timer_s if (!pe) return -ENOMEM; return 0; -diff -urNp linux-3.0.9/kernel/time.c linux-3.0.9/kernel/time.c ---- linux-3.0.9/kernel/time.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/time.c 2011-11-12 12:47:14.000000000 -0500 -@@ -163,6 +163,11 @@ int do_sys_settimeofday(const struct tim - return error; - - 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 = *tz; - update_vsyscall_tz(); -diff -urNp linux-3.0.9/kernel/timer.c linux-3.0.9/kernel/timer.c ---- linux-3.0.9/kernel/timer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/timer.c 2011-11-12 12:47:14.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. @@ -66611,10 +68069,11 @@ diff -urNp linux-3.0.9/kernel/timer.c linux-3.0.9/kernel/timer.c { struct tvec_base *base = __this_cpu_read(tvec_bases); -diff -urNp linux-3.0.9/kernel/trace/blktrace.c linux-3.0.9/kernel/trace/blktrace.c ---- linux-3.0.9/kernel/trace/blktrace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/blktrace.c 2011-11-12 12:47:14.000000000 -0500 -@@ -321,7 +321,7 @@ static ssize_t blk_dropped_read(struct f +diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c +index 6957aa2..915e96e 100644 +--- a/kernel/trace/blktrace.c ++++ b/kernel/trace/blktrace.c +@@ -321,7 +321,7 @@ static ssize_t blk_dropped_read(struct file *filp, char __user *buffer, struct blk_trace *bt = filp->private_data; char buf[16]; @@ -66623,7 +68082,7 @@ diff -urNp linux-3.0.9/kernel/trace/blktrace.c linux-3.0.9/kernel/trace/blktrace return simple_read_from_buffer(buffer, count, ppos, buf, strlen(buf)); } -@@ -386,7 +386,7 @@ static int blk_subbuf_start_callback(str +@@ -386,7 +386,7 @@ static int blk_subbuf_start_callback(struct rchan_buf *buf, void *subbuf, return 1; bt = buf->chan->private_data; @@ -66632,7 +68091,7 @@ diff -urNp linux-3.0.9/kernel/trace/blktrace.c linux-3.0.9/kernel/trace/blktrace return 0; } -@@ -487,7 +487,7 @@ int do_blk_trace_setup(struct request_qu +@@ -487,7 +487,7 @@ int do_blk_trace_setup(struct request_queue *q, char *name, dev_t dev, bt->dir = dir; bt->dev = dev; @@ -66641,10 +68100,11 @@ diff -urNp linux-3.0.9/kernel/trace/blktrace.c linux-3.0.9/kernel/trace/blktrace ret = -EIO; bt->dropped_file = debugfs_create_file("dropped", 0444, dir, bt, -diff -urNp linux-3.0.9/kernel/trace/ftrace.c linux-3.0.9/kernel/trace/ftrace.c ---- linux-3.0.9/kernel/trace/ftrace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/ftrace.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1566,12 +1566,17 @@ ftrace_code_disable(struct module *mod, +diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c +index ef9271b..e4e7c1c 100644 +--- a/kernel/trace/ftrace.c ++++ b/kernel/trace/ftrace.c +@@ -1566,12 +1566,17 @@ ftrace_code_disable(struct module *mod, struct dyn_ftrace *rec) if (unlikely(ftrace_disabled)) return 0; @@ -66664,7 +68124,7 @@ diff -urNp linux-3.0.9/kernel/trace/ftrace.c linux-3.0.9/kernel/trace/ftrace.c } /* -@@ -2570,7 +2575,7 @@ static void ftrace_free_entry_rcu(struct +@@ -2570,7 +2575,7 @@ static void ftrace_free_entry_rcu(struct rcu_head *rhp) int register_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops, @@ -66673,10 +68133,11 @@ diff -urNp linux-3.0.9/kernel/trace/ftrace.c linux-3.0.9/kernel/trace/ftrace.c { struct ftrace_func_probe *entry; struct ftrace_page *pg; -diff -urNp linux-3.0.9/kernel/trace/trace.c linux-3.0.9/kernel/trace/trace.c ---- linux-3.0.9/kernel/trace/trace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/trace.c 2011-11-12 12:47:14.000000000 -0500 -@@ -3339,6 +3339,8 @@ static ssize_t tracing_splice_read_pipe( +diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c +index 0731e81a..91f8a79 100644 +--- a/kernel/trace/trace.c ++++ b/kernel/trace/trace.c +@@ -3339,6 +3339,8 @@ static ssize_t tracing_splice_read_pipe(struct file *filp, size_t rem; unsigned int i; @@ -66685,7 +68146,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace.c linux-3.0.9/kernel/trace/trace.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; -@@ -3822,6 +3824,8 @@ tracing_buffers_splice_read(struct file +@@ -3822,6 +3824,8 @@ tracing_buffers_splice_read(struct file *file, loff_t *ppos, int entries, size, i; size_t ret; @@ -66694,7 +68155,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace.c linux-3.0.9/kernel/trace/trace.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; -@@ -3990,10 +3994,9 @@ static const struct file_operations trac +@@ -3990,10 +3994,9 @@ static const struct file_operations tracing_dyn_info_fops = { }; #endif @@ -66718,10 +68179,11 @@ diff -urNp linux-3.0.9/kernel/trace/trace.c linux-3.0.9/kernel/trace/trace.c static int once; struct dentry *d_tracer; -diff -urNp linux-3.0.9/kernel/trace/trace_events.c linux-3.0.9/kernel/trace/trace_events.c ---- linux-3.0.9/kernel/trace/trace_events.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/trace_events.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1318,10 +1318,6 @@ static LIST_HEAD(ftrace_module_file_list +diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c +index 3e2a7c9..665bb9a 100644 +--- a/kernel/trace/trace_events.c ++++ b/kernel/trace/trace_events.c +@@ -1318,10 +1318,6 @@ static LIST_HEAD(ftrace_module_file_list); struct ftrace_module_file_ops { struct list_head list; struct module *mod; @@ -66732,7 +68194,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_events.c linux-3.0.9/kernel/trace/trac }; static struct ftrace_module_file_ops * -@@ -1342,17 +1338,12 @@ trace_create_file_ops(struct module *mod +@@ -1342,17 +1338,12 @@ trace_create_file_ops(struct module *mod) file_ops->mod = mod; @@ -66756,7 +68218,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_events.c linux-3.0.9/kernel/trace/trac list_add(&file_ops->list, &ftrace_module_file_list); -@@ -1376,8 +1367,8 @@ static void trace_module_add_events(stru +@@ -1376,8 +1367,8 @@ static void trace_module_add_events(struct module *mod) for_each_event(call, start, end) { __trace_add_event_call(*call, mod, @@ -66767,10 +68229,11 @@ diff -urNp linux-3.0.9/kernel/trace/trace_events.c linux-3.0.9/kernel/trace/trac } } -diff -urNp linux-3.0.9/kernel/trace/trace_kprobe.c linux-3.0.9/kernel/trace/trace_kprobe.c ---- linux-3.0.9/kernel/trace/trace_kprobe.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/trace_kprobe.c 2011-11-12 12:47:14.000000000 -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 27d13b3..4f310a9 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 = get_rloc_len(*(u32 *)dest); u8 *dst = get_rloc_data(dest); @@ -66779,7 +68242,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_kprobe.c linux-3.0.9/kernel/trace/trac mm_segment_t old_fs = 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 = __copy_from_user_inatomic(dst++, src++, 1); @@ -66788,7 +68251,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_kprobe.c linux-3.0.9/kernel/trace/trac dst[-1] = '\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] = '\0'; *(u32 *)dest = make_data_rloc(0, get_rloc_offs(*(u32 *)dest)); } else @@ -66797,7 +68260,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_kprobe.c linux-3.0.9/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 { @@ -66806,9 +68269,10 @@ diff -urNp linux-3.0.9/kernel/trace/trace_kprobe.c linux-3.0.9/kernel/trace/trac len++; } while (c && ret == 0 && len < MAX_STRING_SIZE); pagefault_enable(); -diff -urNp linux-3.0.9/kernel/trace/trace_mmiotrace.c linux-3.0.9/kernel/trace/trace_mmiotrace.c ---- linux-3.0.9/kernel/trace/trace_mmiotrace.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/trace_mmiotrace.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/trace/trace_mmiotrace.c b/kernel/trace/trace_mmiotrace.c +index 017fa37..39f50bc 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; @@ -66818,7 +68282,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_mmiotrace.c linux-3.0.9/kernel/trace/t 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) static unsigned long count_overruns(struct trace_iterator *iter) { @@ -66827,7 +68291,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_mmiotrace.c linux-3.0.9/kernel/trace/t unsigned long over = ring_buffer_overruns(iter->tr->buffer); if (over > prev_overruns) -@@ -317,7 +317,7 @@ static void __trace_mmiotrace_rw(struct +@@ -317,7 +317,7 @@ static void __trace_mmiotrace_rw(struct trace_array *tr, event = trace_buffer_lock_reserve(buffer, TRACE_MMIO_RW, sizeof(*entry), 0, pc); if (!event) { @@ -66836,7 +68300,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_mmiotrace.c linux-3.0.9/kernel/trace/t return; } entry = 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 = trace_buffer_lock_reserve(buffer, TRACE_MMIO_MAP, sizeof(*entry), 0, pc); if (!event) { @@ -66845,10 +68309,11 @@ diff -urNp linux-3.0.9/kernel/trace/trace_mmiotrace.c linux-3.0.9/kernel/trace/t return; } entry = ring_buffer_event_data(event); -diff -urNp linux-3.0.9/kernel/trace/trace_output.c linux-3.0.9/kernel/trace/trace_output.c ---- linux-3.0.9/kernel/trace/trace_output.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/trace_output.c 2011-11-12 12:47:14.000000000 -0500 -@@ -278,7 +278,7 @@ int trace_seq_path(struct trace_seq *s, +diff --git a/kernel/trace/trace_output.c b/kernel/trace/trace_output.c +index e37de49..981a7c2 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) p = d_path(path, s->buffer + s->len, PAGE_SIZE - s->len); if (!IS_ERR(p)) { @@ -66857,9 +68322,10 @@ diff -urNp linux-3.0.9/kernel/trace/trace_output.c linux-3.0.9/kernel/trace/trac if (p) { s->len = p - s->buffer; return 1; -diff -urNp linux-3.0.9/kernel/trace/trace_stack.c linux-3.0.9/kernel/trace/trace_stack.c ---- linux-3.0.9/kernel/trace/trace_stack.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/trace_stack.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/trace/trace_stack.c b/kernel/trace/trace_stack.c +index b0b53b8..fbfd580 100644 +--- a/kernel/trace/trace_stack.c ++++ b/kernel/trace/trace_stack.c @@ -50,7 +50,7 @@ static inline void check_stack(void) return; @@ -66869,9 +68335,10 @@ diff -urNp linux-3.0.9/kernel/trace/trace_stack.c linux-3.0.9/kernel/trace/trace return; local_irq_save(flags); -diff -urNp linux-3.0.9/kernel/trace/trace_workqueue.c linux-3.0.9/kernel/trace/trace_workqueue.c ---- linux-3.0.9/kernel/trace/trace_workqueue.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/kernel/trace/trace_workqueue.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/kernel/trace/trace_workqueue.c b/kernel/trace/trace_workqueue.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; @@ -66890,7 +68357,7 @@ diff -urNp linux-3.0.9/kernel/trace/trace_workqueue.c linux-3.0.9/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, void *p) tsk = get_pid_task(pid, PIDTYPE_PID); if (tsk) { seq_printf(s, "%3d %6d %6u %s\n", cws->cpu, @@ -66899,10 +68366,23 @@ diff -urNp linux-3.0.9/kernel/trace/trace_workqueue.c linux-3.0.9/kernel/trace/t tsk->comm); put_task_struct(tsk); } -diff -urNp linux-3.0.9/lib/bitmap.c linux-3.0.9/lib/bitmap.c ---- linux-3.0.9/lib/bitmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/bitmap.c 2011-11-12 12:47:14.000000000 -0500 -@@ -421,7 +421,7 @@ int __bitmap_parse(const char *buf, unsi +diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug +index dd373c8..111fdb1 100644 +--- a/lib/Kconfig.debug ++++ b/lib/Kconfig.debug +@@ -1088,6 +1088,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 3f3b681..6c5ef68 100644 +--- a/lib/bitmap.c ++++ b/lib/bitmap.c +@@ -421,7 +421,7 @@ int __bitmap_parse(const char *buf, unsigned int buflen, { int c, old_c, totaldigits, ndigits, nchunks, nbits; u32 chunk; @@ -66911,7 +68391,7 @@ diff -urNp linux-3.0.9/lib/bitmap.c linux-3.0.9/lib/bitmap.c bitmap_zero(maskp, nmaskbits); -@@ -506,7 +506,7 @@ int bitmap_parse_user(const char __user +@@ -506,7 +506,7 @@ int bitmap_parse_user(const char __user *ubuf, { if (!access_ok(VERIFY_READ, ubuf, ulen)) return -EFAULT; @@ -66920,7 +68400,7 @@ diff -urNp linux-3.0.9/lib/bitmap.c linux-3.0.9/lib/bitmap.c } EXPORT_SYMBOL(bitmap_parse_user); -@@ -596,7 +596,7 @@ static int __bitmap_parselist(const char +@@ -596,7 +596,7 @@ static int __bitmap_parselist(const char *buf, unsigned int buflen, { unsigned a, b; int c, old_c, totaldigits; @@ -66929,7 +68409,7 @@ diff -urNp linux-3.0.9/lib/bitmap.c linux-3.0.9/lib/bitmap.c int exp_digit, in_range; totaldigits = c = 0; -@@ -696,7 +696,7 @@ int bitmap_parselist_user(const char __u +@@ -696,7 +696,7 @@ int bitmap_parselist_user(const char __user *ubuf, { if (!access_ok(VERIFY_READ, ubuf, ulen)) return -EFAULT; @@ -66938,10 +68418,11 @@ diff -urNp linux-3.0.9/lib/bitmap.c linux-3.0.9/lib/bitmap.c ulen, 1, maskp, nmaskbits); } EXPORT_SYMBOL(bitmap_parselist_user); -diff -urNp linux-3.0.9/lib/bug.c linux-3.0.9/lib/bug.c ---- linux-3.0.9/lib/bug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/bug.c 2011-11-12 12:47:14.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; bug = find_bug(bugaddr); @@ -66950,10 +68431,11 @@ diff -urNp linux-3.0.9/lib/bug.c linux-3.0.9/lib/bug.c file = NULL; line = 0; -diff -urNp linux-3.0.9/lib/debugobjects.c linux-3.0.9/lib/debugobjects.c ---- linux-3.0.9/lib/debugobjects.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/debugobjects.c 2011-11-12 12:47:14.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; @@ -66962,10 +68444,11 @@ diff -urNp linux-3.0.9/lib/debugobjects.c linux-3.0.9/lib/debugobjects.c if (is_on_stack == onstack) return; -diff -urNp linux-3.0.9/lib/devres.c linux-3.0.9/lib/devres.c ---- linux-3.0.9/lib/devres.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/devres.c 2011-11-12 12:47:14.000000000 -0500 -@@ -81,7 +81,7 @@ void devm_iounmap(struct device *dev, vo +diff --git a/lib/devres.c b/lib/devres.c +index 6efddf5..89df310 100644 +--- a/lib/devres.c ++++ b/lib/devres.c +@@ -81,7 +81,7 @@ void devm_iounmap(struct device *dev, void __iomem *addr) { iounmap(addr); WARN_ON(devres_destroy(dev, devm_ioremap_release, devm_ioremap_match, @@ -66974,7 +68457,7 @@ diff -urNp linux-3.0.9/lib/devres.c linux-3.0.9/lib/devres.c } 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 __iomem *addr) { ioport_unmap(addr); WARN_ON(devres_destroy(dev, devm_ioport_map_release, @@ -66983,9 +68466,10 @@ diff -urNp linux-3.0.9/lib/devres.c linux-3.0.9/lib/devres.c } EXPORT_SYMBOL(devm_ioport_unmap); -diff -urNp linux-3.0.9/lib/dma-debug.c linux-3.0.9/lib/dma-debug.c ---- linux-3.0.9/lib/dma-debug.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/dma-debug.c 2011-11-12 12:47:14.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: static void check_for_stack(struct device *dev, void *addr) @@ -66995,9 +68479,10 @@ diff -urNp linux-3.0.9/lib/dma-debug.c linux-3.0.9/lib/dma-debug.c err_printk(dev, NULL, "DMA-API: device driver maps memory from" "stack [addr=%p]\n", addr); } -diff -urNp linux-3.0.9/lib/extable.c linux-3.0.9/lib/extable.c ---- linux-3.0.9/lib/extable.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/extable.c 2011-11-12 12:47:14.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 <linux/init.h> #include <linux/sort.h> @@ -67006,7 +68491,7 @@ diff -urNp linux-3.0.9/lib/extable.c linux-3.0.9/lib/extable.c #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) { @@ -67017,9 +68502,10 @@ diff -urNp linux-3.0.9/lib/extable.c linux-3.0.9/lib/extable.c } #ifdef CONFIG_MODULES -diff -urNp linux-3.0.9/lib/inflate.c linux-3.0.9/lib/inflate.c ---- linux-3.0.9/lib/inflate.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/inflate.c 2011-11-12 12:47:14.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 = free_mem_ptr; } @@ -67029,20 +68515,10 @@ diff -urNp linux-3.0.9/lib/inflate.c linux-3.0.9/lib/inflate.c #define free(a) kfree(a) #endif -diff -urNp linux-3.0.9/lib/Kconfig.debug linux-3.0.9/lib/Kconfig.debug ---- linux-3.0.9/lib/Kconfig.debug 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/Kconfig.debug 2011-11-12 12:47:14.000000000 -0500 -@@ -1088,6 +1088,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.0.9/lib/kref.c linux-3.0.9/lib/kref.c ---- linux-3.0.9/lib/kref.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/kref.c 2011-11-12 12:47:14.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)) @@ -67052,9 +68528,10 @@ diff -urNp linux-3.0.9/lib/kref.c linux-3.0.9/lib/kref.c WARN_ON(release == (void (*)(struct kref *))kfree); if (atomic_dec_and_test(&kref->refcount)) { -diff -urNp linux-3.0.9/lib/radix-tree.c linux-3.0.9/lib/radix-tree.c ---- linux-3.0.9/lib/radix-tree.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/radix-tree.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/lib/radix-tree.c b/lib/radix-tree.c +index 7ea2e03..cabda0f 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]; @@ -67064,9 +68541,10 @@ diff -urNp linux-3.0.9/lib/radix-tree.c linux-3.0.9/lib/radix-tree.c static inline void *ptr_to_indirect(void *ptr) { -diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/lib/vsprintf.c ---- linux-3.0.9/lib/vsprintf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/lib/vsprintf.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/lib/vsprintf.c b/lib/vsprintf.c +index 4365df3..c8c7105 100644 +--- a/lib/vsprintf.c ++++ b/lib/vsprintf.c @@ -16,6 +16,9 @@ * - scnprintf and vscnprintf */ @@ -67077,7 +68555,7 @@ diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/lib/vsprintf.c #include <stdarg.h> #include <linux/module.h> #include <linux/types.h> -@@ -435,7 +438,7 @@ char *symbol_string(char *buf, char *end +@@ -435,7 +438,7 @@ char *symbol_string(char *buf, char *end, void *ptr, char sym[KSYM_SYMBOL_LEN]; if (ext == 'B') sprint_backtrace(sym, value); @@ -67086,7 +68564,7 @@ diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/lib/vsprintf.c sprint_symbol(sym, value); else kallsyms_lookup(value, NULL, NULL, NULL, sym); -@@ -799,7 +802,11 @@ char *uuid_string(char *buf, char *end, +@@ -799,7 +802,11 @@ char *uuid_string(char *buf, char *end, const u8 *addr, return string(buf, end, uuid, spec); } @@ -67107,7 +68585,7 @@ diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/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 -@@ -857,12 +866,12 @@ char *pointer(const char *fmt, char *buf +@@ -857,12 +866,12 @@ char *pointer(const char *fmt, char *buf, char *end, void *ptr, { if (!ptr && *fmt != 'K') { /* @@ -67122,7 +68600,7 @@ diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/lib/vsprintf.c } switch (*fmt) { -@@ -872,6 +881,13 @@ char *pointer(const char *fmt, char *buf +@@ -872,6 +881,13 @@ char *pointer(const char *fmt, char *buf, char *end, void *ptr, /* Fallthrough */ case 'S': case 's': @@ -67136,7 +68614,7 @@ diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/lib/vsprintf.c case 'B': return symbol_string(buf, end, ptr, spec, *fmt); case 'R': -@@ -1631,11 +1647,11 @@ int bstr_printf(char *buf, size_t size, +@@ -1631,11 +1647,11 @@ int bstr_printf(char *buf, size_t size, const char *fmt, const u32 *bin_buf) typeof(type) value; \ if (sizeof(type) == 8) { \ args = PTR_ALIGN(args, sizeof(u32)); \ @@ -67151,7 +68629,7 @@ diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/lib/vsprintf.c } \ args += sizeof(type); \ value; \ -@@ -1698,7 +1714,7 @@ int bstr_printf(char *buf, size_t size, +@@ -1698,7 +1714,7 @@ int bstr_printf(char *buf, size_t size, const char *fmt, const u32 *bin_buf) case FORMAT_TYPE_STR: { const char *str_arg = args; args += strlen(str_arg) + 1; @@ -67160,199 +68638,31 @@ diff -urNp linux-3.0.9/lib/vsprintf.c linux-3.0.9/lib/vsprintf.c break; } -diff -urNp linux-3.0.9/localversion-grsec linux-3.0.9/localversion-grsec ---- linux-3.0.9/localversion-grsec 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/localversion-grsec 2011-11-12 12:47:14.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.0.9/Makefile linux-3.0.9/Makefile ---- linux-3.0.9/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/Makefile 2011-11-12 12:47:14.000000000 -0500 -@@ -245,8 +245,9 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" - - HOSTCC = gcc - HOSTCXX = g++ --HOSTCFLAGS = -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer --HOSTCXXFLAGS = -O2 -+HOSTCFLAGS = -Wall -W -Wmissing-prototypes -Wstrict-prototypes -Wno-unused-parameter -Wno-missing-field-initializers -O2 -fomit-frame-pointer -fno-delete-null-pointer-checks -+HOSTCFLAGS += $(call cc-option, -Wno-empty-body) -+HOSTCXXFLAGS = -O2 -fno-delete-null-pointer-checks - - # Decide whether to build built-in, modular, or both. - # Normally, just do built-in. -@@ -365,10 +366,12 @@ LINUXINCLUDE := -I$(srctree)/arch/$(h - KBUILD_CPPFLAGS := -D__KERNEL__ - - KBUILD_CFLAGS := -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs \ -+ -W -Wno-unused-parameter -Wno-missing-field-initializers \ - -fno-strict-aliasing -fno-common \ - -Werror-implicit-function-declaration \ - -Wno-format-security \ - -fno-delete-null-pointer-checks -+KBUILD_CFLAGS += $(call cc-option, -Wno-empty-body) - KBUILD_AFLAGS_KERNEL := - KBUILD_CFLAGS_KERNEL := - KBUILD_AFLAGS := -D__ASSEMBLY__ -@@ -407,8 +410,8 @@ export RCS_TAR_IGNORE := --exclude SCCS - # Rules shared between *config targets and build targets - - # Basic helpers built in scripts/ --PHONY += scripts_basic --scripts_basic: -+PHONY += scripts_basic gcc-plugins -+scripts_basic: gcc-plugins - $(Q)$(MAKE) $(build)=scripts/basic - $(Q)rm -f .tmp_quiet_recordmcount - -@@ -564,6 +567,36 @@ else - KBUILD_CFLAGS += -O2 - endif - -+ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-plugin.sh "$(HOSTCC)" "$(CC)"), y) -+CONSTIFY_PLUGIN := -fplugin=$(objtree)/tools/gcc/constify_plugin.so -DCONSTIFY_PLUGIN -+ifdef CONFIG_PAX_MEMORY_STACKLEAK -+STACKLEAK_PLUGIN := -fplugin=$(objtree)/tools/gcc/stackleak_plugin.so -fplugin-arg-stackleak_plugin-track-lowest-sp=100 -+endif -+ifdef CONFIG_KALLOCSTAT_PLUGIN -+KALLOCSTAT_PLUGIN := -fplugin=$(objtree)/tools/gcc/kallocstat_plugin.so -+endif -+ifdef CONFIG_PAX_KERNEXEC_PLUGIN -+KERNEXEC_PLUGIN := -fplugin=$(objtree)/tools/gcc/kernexec_plugin.so -+endif -+ifdef CONFIG_CHECKER_PLUGIN -+ifeq ($(call cc-ifversion, -ge, 0406, y), y) -+CHECKER_PLUGIN := -fplugin=$(objtree)/tools/gcc/checker_plugin.so -DCHECKER_PLUGIN -+endif -+endif -+GCC_PLUGINS := $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN) $(KALLOCSTAT_PLUGIN) $(KERNEXEC_PLUGIN) $(CHECKER_PLUGIN) -+export CONSTIFY_PLUGIN STACKLEAK_PLUGIN KERNEXEC_PLUGIN CHECKER_PLUGIN -+gcc-plugins: -+ $(Q)$(MAKE) $(build)=tools/gcc -+else -+gcc-plugins: -+ifeq ($(call cc-ifversion, -ge, 0405, y), y) -+ $(error Your gcc installation does not support plugins. If the necessary headers for plugin support are missing, they should be installed. On Debian, apt-get install gcc-<ver>-plugin-dev.)) -+else -+ $(Q)echo "warning, your gcc version does not support plugins, you should upgrade it to gcc 4.5 at least" -+endif -+ $(Q)echo "PAX_MEMORY_STACKLEAK and constification will be less secure" -+endif -+ - include $(srctree)/arch/$(SRCARCH)/Makefile - - ifneq ($(CONFIG_FRAME_WARN),0) -@@ -708,7 +741,7 @@ export mod_strip_cmd - - - ifeq ($(KBUILD_EXTMOD),) --core-y += kernel/ mm/ fs/ ipc/ security/ crypto/ block/ -+core-y += kernel/ mm/ fs/ ipc/ security/ crypto/ block/ grsecurity/ - - vmlinux-dirs := $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ - $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ -@@ -932,6 +965,7 @@ vmlinux.o: $(modpost-init) $(vmlinux-mai - - # The actual objects are generated when descending, - # make sure no implicit rule kicks in -+$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): KBUILD_CFLAGS += $(GCC_PLUGINS) - $(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): $(vmlinux-dirs) ; - - # Handle descending into subdirectories listed in $(vmlinux-dirs) -@@ -941,7 +975,7 @@ $(sort $(vmlinux-init) $(vmlinux-main)) - # Error messages still appears in the original language - - PHONY += $(vmlinux-dirs) --$(vmlinux-dirs): prepare scripts -+$(vmlinux-dirs): gcc-plugins prepare scripts - $(Q)$(MAKE) $(build)=$@ - - # Store (new) KERNELRELASE string in include/config/kernel.release -@@ -986,6 +1020,7 @@ prepare0: archprepare FORCE - $(Q)$(MAKE) $(build)=. missing-syscalls - - # All the preparing.. -+prepare: KBUILD_CFLAGS := $(filter-out $(GCC_PLUGINS),$(KBUILD_CFLAGS)) - prepare: prepare0 - - # Generate some files -@@ -1087,6 +1122,7 @@ all: modules - # using awk while concatenating to the final file. - - PHONY += modules -+modules: KBUILD_CFLAGS += $(GCC_PLUGINS) - modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin - $(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=$(objtree)/%/modules.order) > $(objtree)/modules.order - @$(kecho) ' Building modules, stage 2.'; -@@ -1102,7 +1138,7 @@ modules.builtin: $(vmlinux-dirs:%=%/modu - - # Target to prepare building external modules - PHONY += modules_prepare --modules_prepare: prepare scripts -+modules_prepare: gcc-plugins prepare scripts - - # Target to install modules - PHONY += modules_install -@@ -1198,7 +1234,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 - -@@ -1359,6 +1395,7 @@ PHONY += $(module-dirs) modules - $(module-dirs): crmodverdir $(objtree)/Module.symvers - $(Q)$(MAKE) $(build)=$(patsubst _module_%,%,$@) - -+modules: KBUILD_CFLAGS += $(GCC_PLUGINS) - modules: $(module-dirs) - @$(kecho) ' Building modules, stage 2.'; - $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost -@@ -1485,17 +1522,19 @@ else - target-dir = $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@)) - endif - --%.s: %.c prepare scripts FORCE -+%.s: KBUILD_CFLAGS += $(GCC_PLUGINS) -+%.s: %.c gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) - %.i: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) --%.o: %.c prepare scripts FORCE -+%.o: KBUILD_CFLAGS += $(GCC_PLUGINS) -+%.o: %.c gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) - %.lst: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) --%.s: %.S prepare scripts FORCE -+%.s: %.S gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) --%.o: %.S prepare scripts FORCE -+%.o: %.S gcc-plugins prepare scripts FORCE - $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) - %.symtypes: %.c prepare scripts FORCE - $(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@) -@@ -1505,11 +1544,13 @@ endif - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \ - $(build)=$(build-dir) --%/: prepare scripts FORCE -+%/: KBUILD_CFLAGS += $(GCC_PLUGINS) -+%/: gcc-plugins prepare scripts FORCE - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \ - $(build)=$(build-dir) --%.ko: prepare scripts FORCE -+%.ko: KBUILD_CFLAGS += $(GCC_PLUGINS) -+%.ko: gcc-plugins prepare scripts FORCE - $(cmd_crmodverdir) - $(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \ - $(build)=$(build-dir) $(@:.ko=.o) -diff -urNp linux-3.0.9/mm/filemap.c linux-3.0.9/mm/filemap.c ---- linux-3.0.9/mm/filemap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/filemap.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1763,7 +1763,7 @@ int generic_file_mmap(struct file * file +diff --git a/mm/Kconfig b/mm/Kconfig +index 8ca47a5..77ebfaa 100644 +--- a/mm/Kconfig ++++ b/mm/Kconfig +@@ -240,7 +240,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/filemap.c b/mm/filemap.c +index a8251a8..33d52b0 100644 +--- a/mm/filemap.c ++++ b/mm/filemap.c +@@ -1763,7 +1763,7 @@ int generic_file_mmap(struct file * file, struct vm_area_struct * vma) struct address_space *mapping = file->f_mapping; if (!mapping->a_ops->readpage) @@ -67361,7 +68671,7 @@ diff -urNp linux-3.0.9/mm/filemap.c linux-3.0.9/mm/filemap.c file_accessed(file); vma->vm_ops = &generic_file_vm_ops; vma->vm_flags |= VM_CAN_NONLINEAR; -@@ -2169,6 +2169,7 @@ inline int generic_write_checks(struct f +@@ -2169,6 +2169,7 @@ inline int generic_write_checks(struct file *file, loff_t *pos, size_t *count, i *pos = i_size_read(inode); if (limit != RLIM_INFINITY) { @@ -67369,10 +68679,11 @@ diff -urNp linux-3.0.9/mm/filemap.c linux-3.0.9/mm/filemap.c if (*pos >= limit) { send_sig(SIGXFSZ, current, 0); return -EFBIG; -diff -urNp linux-3.0.9/mm/fremap.c linux-3.0.9/mm/fremap.c ---- linux-3.0.9/mm/fremap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/fremap.c 2011-11-12 12:47:14.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, start, unsigned long, size, retry: vma = find_vma(mm, start); @@ -67384,9 +68695,10 @@ diff -urNp linux-3.0.9/mm/fremap.c linux-3.0.9/mm/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.0.9/mm/highmem.c linux-3.0.9/mm/highmem.c ---- linux-3.0.9/mm/highmem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/highmem.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/highmem.c b/mm/highmem.c +index 693394d..fc807e2 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. */ @@ -67412,9 +68724,10 @@ diff -urNp linux-3.0.9/mm/highmem.c linux-3.0.9/mm/highmem.c pkmap_count[last_pkmap_nr] = 1; set_page_address(page, (void *)vaddr); -diff -urNp linux-3.0.9/mm/huge_memory.c linux-3.0.9/mm/huge_memory.c ---- linux-3.0.9/mm/huge_memory.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/huge_memory.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/huge_memory.c b/mm/huge_memory.c +index cc5acf9..fd56cc0 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. @@ -67424,10 +68737,11 @@ diff -urNp linux-3.0.9/mm/huge_memory.c linux-3.0.9/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))) -diff -urNp linux-3.0.9/mm/hugetlb.c linux-3.0.9/mm/hugetlb.c ---- linux-3.0.9/mm/hugetlb.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/hugetlb.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2339,6 +2339,27 @@ static int unmap_ref_private(struct mm_s +diff --git a/mm/hugetlb.c b/mm/hugetlb.c +index bfcf153..1eff489 100644 +--- a/mm/hugetlb.c ++++ b/mm/hugetlb.c +@@ -2339,6 +2339,27 @@ static int unmap_ref_private(struct mm_struct *mm, struct vm_area_struct *vma, return 1; } @@ -67478,7 +68792,7 @@ diff -urNp linux-3.0.9/mm/hugetlb.c linux-3.0.9/mm/hugetlb.c if ((flags & FAULT_FLAG_WRITE) && !(vma->vm_flags & VM_SHARED)) { /* Optimization, do the COW without a second fault */ ret = hugetlb_cow(mm, vma, address, ptep, new_pte, page); -@@ -2620,6 +2650,10 @@ int hugetlb_fault(struct mm_struct *mm, +@@ -2620,6 +2650,10 @@ int hugetlb_fault(struct mm_struct *mm, struct vm_area_struct *vma, static DEFINE_MUTEX(hugetlb_instantiation_mutex); struct hstate *h = hstate_vma(vma); @@ -67489,7 +68803,7 @@ diff -urNp linux-3.0.9/mm/hugetlb.c linux-3.0.9/mm/hugetlb.c ptep = huge_pte_offset(mm, address); if (ptep) { entry = huge_ptep_get(ptep); -@@ -2631,6 +2665,26 @@ int hugetlb_fault(struct mm_struct *mm, +@@ -2631,6 +2665,26 @@ int hugetlb_fault(struct mm_struct *mm, struct vm_area_struct *vma, VM_FAULT_SET_HINDEX(h - hstates); } @@ -67516,10 +68830,11 @@ diff -urNp linux-3.0.9/mm/hugetlb.c linux-3.0.9/mm/hugetlb.c ptep = huge_pte_alloc(mm, address, huge_page_size(h)); if (!ptep) return VM_FAULT_OOM; -diff -urNp linux-3.0.9/mm/internal.h linux-3.0.9/mm/internal.h ---- linux-3.0.9/mm/internal.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/internal.h 2011-11-12 12:47:14.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); @@ -67527,22 +68842,11 @@ diff -urNp linux-3.0.9/mm/internal.h linux-3.0.9/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.0.9/mm/Kconfig linux-3.0.9/mm/Kconfig ---- linux-3.0.9/mm/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/Kconfig 2011-11-12 12:47:14.000000000 -0500 -@@ -240,7 +240,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-3.0.9/mm/kmemleak.c linux-3.0.9/mm/kmemleak.c ---- linux-3.0.9/mm/kmemleak.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/kmemleak.c 2011-11-12 12:47:14.000000000 -0500 -@@ -357,7 +357,7 @@ static void print_unreferenced(struct se +diff --git a/mm/kmemleak.c b/mm/kmemleak.c +index aacee45..ece1c1e 100644 +--- a/mm/kmemleak.c ++++ b/mm/kmemleak.c +@@ -357,7 +357,7 @@ static void print_unreferenced(struct seq_file *seq, for (i = 0; i < object->trace_len; i++) { void *ptr = (void *)object->trace[i]; @@ -67551,10 +68855,11 @@ diff -urNp linux-3.0.9/mm/kmemleak.c linux-3.0.9/mm/kmemleak.c } } -diff -urNp linux-3.0.9/mm/maccess.c linux-3.0.9/mm/maccess.c ---- linux-3.0.9/mm/maccess.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/maccess.c 2011-11-12 12:47:14.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, size_t size) set_fs(KERNEL_DS); pagefault_disable(); ret = __copy_from_user_inatomic(dst, @@ -67563,7 +68868,7 @@ diff -urNp linux-3.0.9/mm/maccess.c linux-3.0.9/mm/maccess.c pagefault_enable(); set_fs(old_fs); -@@ -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) set_fs(KERNEL_DS); pagefault_disable(); @@ -67572,10 +68877,11 @@ diff -urNp linux-3.0.9/mm/maccess.c linux-3.0.9/mm/maccess.c pagefault_enable(); set_fs(old_fs); -diff -urNp linux-3.0.9/mm/madvise.c linux-3.0.9/mm/madvise.c ---- linux-3.0.9/mm/madvise.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/madvise.c 2011-11-12 12:47:14.000000000 -0500 -@@ -45,6 +45,10 @@ static long madvise_behavior(struct vm_a +diff --git a/mm/madvise.c b/mm/madvise.c +index 2221491..b8ee2d8 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 = vma->vm_flags; @@ -67600,7 +68906,7 @@ diff -urNp linux-3.0.9/mm/madvise.c linux-3.0.9/mm/madvise.c vma->vm_flags = new_flags; 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) { @@ -67612,7 +68918,7 @@ diff -urNp linux-3.0.9/mm/madvise.c linux-3.0.9/mm/madvise.c *prev = 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); @@ -67634,7 +68940,7 @@ diff -urNp linux-3.0.9/mm/madvise.c linux-3.0.9/mm/madvise.c return 0; } -@@ -376,6 +407,16 @@ SYSCALL_DEFINE3(madvise, unsigned long, +@@ -376,6 +407,16 @@ SYSCALL_DEFINE3(madvise, unsigned long, start, size_t, len_in, int, behavior) if (end < start) goto out; @@ -67651,10 +68957,96 @@ diff -urNp linux-3.0.9/mm/madvise.c linux-3.0.9/mm/madvise.c error = 0; if (end == start) goto out; -diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c ---- linux-3.0.9/mm/memory.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/memory.c 2011-11-12 12:47:14.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 740c4f5..eb38047 100644 +--- a/mm/memory-failure.c ++++ b/mm/memory-failure.c +@@ -59,7 +59,7 @@ int sysctl_memory_failure_early_kill __read_mostly = 0; + + int sysctl_memory_failure_recovery __read_mostly = 1; + +-atomic_long_t mce_bad_pages __read_mostly = ATOMIC_LONG_INIT(0); ++atomic_long_unchecked_t mce_bad_pages __read_mostly = ATOMIC_LONG_INIT(0); + + #if defined(CONFIG_HWPOISON_INJECT) || defined(CONFIG_HWPOISON_INJECT_MODULE) + +@@ -200,7 +200,7 @@ static int kill_proc_ao(struct task_struct *t, unsigned long addr, int trapno, + si.si_signo = SIGBUS; + si.si_errno = 0; + si.si_code = BUS_MCEERR_AO; +- si.si_addr = (void *)addr; ++ si.si_addr = (void __user *)addr; + #ifdef __ARCH_SI_TRAPNO + si.si_trapno = trapno; + #endif +@@ -1008,7 +1008,7 @@ int __memory_failure(unsigned long pfn, int trapno, int flags) + } + + nr_pages = 1 << compound_trans_order(hpage); +- atomic_long_add(nr_pages, &mce_bad_pages); ++ atomic_long_add_unchecked(nr_pages, &mce_bad_pages); + + /* + * We need/can do nothing about count=0 pages. +@@ -1038,7 +1038,7 @@ int __memory_failure(unsigned long pfn, int trapno, int flags) + if (!PageHWPoison(hpage) + || (hwpoison_filter(p) && TestClearPageHWPoison(p)) + || (p != 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); +@@ -1096,7 +1096,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; +@@ -1222,7 +1222,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; + } +@@ -1236,7 +1236,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 = 1; + if (PageHuge(page)) + clear_page_hwpoison_huge_page(page); +@@ -1349,7 +1349,7 @@ static int soft_offline_huge_page(struct page *page, 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 */ +@@ -1480,7 +1480,7 @@ int soft_offline_page(struct page *page, int flags) + return ret; + + 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 95a7799..4b036fe 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; pmd = pmd_offset(pud, start); @@ -67667,7 +69059,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c } 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; @@ -67693,7 +69085,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c /** * __get_user_pages() - pin user pages in memory * @tsk: task_struct of target task -@@ -1655,10 +1656,10 @@ int __get_user_pages(struct task_struct +@@ -1655,10 +1656,10 @@ int __get_user_pages(struct task_struct *tsk, struct mm_struct *mm, (VM_MAYREAD | VM_MAYWRITE) : (VM_READ | VM_WRITE); i = 0; @@ -67706,7 +69098,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c if (!vma && in_gate_area(mm, start)) { unsigned long pg = start & PAGE_MASK; pgd_t *pgd; -@@ -1706,7 +1707,7 @@ int __get_user_pages(struct task_struct +@@ -1706,7 +1707,7 @@ int __get_user_pages(struct task_struct *tsk, struct mm_struct *mm, goto next_page; } @@ -67715,7 +69107,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c (vma->vm_flags & (VM_IO | VM_PFNMAP)) || !(vm_flags & vma->vm_flags)) return i ? : -EFAULT; -@@ -1733,11 +1734,6 @@ int __get_user_pages(struct task_struct +@@ -1733,11 +1734,6 @@ int __get_user_pages(struct task_struct *tsk, struct mm_struct *mm, int ret; unsigned int fault_flags = 0; @@ -67736,7 +69128,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c return i; } EXPORT_SYMBOL(__get_user_pages); -@@ -2018,6 +2014,10 @@ static int insert_page(struct vm_area_st +@@ -2018,6 +2014,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)); @@ -67770,7 +69162,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c vma->vm_flags |= VM_INSERTPAGE; return insert_page(vma, addr, page, vma->vm_page_prot); } -@@ -2141,6 +2153,7 @@ int vm_insert_mixed(struct vm_area_struc +@@ -2141,6 +2153,7 @@ int vm_insert_mixed(struct vm_area_struct *vma, unsigned long addr, unsigned long pfn) { BUG_ON(!(vma->vm_flags & VM_MIXEDMAP)); @@ -67778,7 +69170,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c if (addr < vma->vm_start || addr >= vma->vm_end) return -EFAULT; -@@ -2456,6 +2469,186 @@ static inline void cow_user_page(struct +@@ -2456,6 +2469,186 @@ static inline void cow_user_page(struct page *dst, struct page *src, unsigned lo copy_user_highpage(dst, src, va, vma); } @@ -67989,7 +69381,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c /* Free the old page.. */ new_page = old_page; ret |= VM_FAULT_WRITE; -@@ -2997,6 +3200,11 @@ static int do_swap_page(struct mm_struct +@@ -2997,6 +3200,11 @@ static int do_swap_page(struct mm_struct *mm, struct vm_area_struct *vma, swap_free(entry); if (vm_swap_full() || (vma->vm_flags & VM_LOCKED) || PageMlocked(page)) try_to_free_swap(page); @@ -68001,7 +69393,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c unlock_page(page); if (swapcache) { /* -@@ -3020,6 +3228,11 @@ static int do_swap_page(struct mm_struct +@@ -3020,6 +3228,11 @@ static int do_swap_page(struct mm_struct *mm, struct vm_area_struct *vma, /* No need to invalidate - it was non-present before */ update_mmu_cache(vma, address, page_table); @@ -68054,7 +69446,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/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. -@@ -3081,27 +3260,23 @@ static int do_anonymous_page(struct mm_s +@@ -3081,27 +3260,23 @@ static int do_anonymous_page(struct mm_struct *mm, struct vm_area_struct *vma, unsigned long address, pte_t *page_table, pmd_t *pmd, unsigned int flags) { @@ -68087,7 +69479,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c if (unlikely(anon_vma_prepare(vma))) goto oom; page = alloc_zeroed_user_highpage_movable(vma, address); -@@ -3120,6 +3295,11 @@ static int do_anonymous_page(struct mm_s +@@ -3120,6 +3295,11 @@ static int do_anonymous_page(struct mm_struct *mm, struct vm_area_struct *vma, if (!pte_none(*page_table)) goto release; @@ -68112,7 +69504,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c unlock: pte_unmap_unlock(page_table, ptl); return 0; -@@ -3264,6 +3450,12 @@ static int __do_fault(struct mm_struct * +@@ -3264,6 +3450,12 @@ static int __do_fault(struct mm_struct *mm, struct vm_area_struct *vma, */ /* Only go through if we didn't race with anybody else... */ if (likely(pte_same(*page_table, orig_pte))) { @@ -68125,7 +69517,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c flush_icache_page(vma, page); entry = mk_pte(page, vma->vm_page_prot); if (flags & FAULT_FLAG_WRITE) -@@ -3283,6 +3475,14 @@ static int __do_fault(struct mm_struct * +@@ -3283,6 +3475,14 @@ static int __do_fault(struct mm_struct *mm, struct vm_area_struct *vma, /* no need to invalidate: a not-present page won't be cached */ update_mmu_cache(vma, address, page_table); @@ -68140,7 +69532,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c } else { if (charged) mem_cgroup_uncharge_page(page); -@@ -3430,6 +3630,12 @@ int handle_pte_fault(struct mm_struct *m +@@ -3430,6 +3630,12 @@ int handle_pte_fault(struct mm_struct *mm, if (flags & FAULT_FLAG_WRITE) flush_tlb_fix_spurious_fault(vma, address); } @@ -68153,7 +69545,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c unlock: pte_unmap_unlock(pte, ptl); return 0; -@@ -3446,6 +3652,10 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3446,6 +3652,10 @@ int handle_mm_fault(struct mm_struct *mm, struct vm_area_struct *vma, pmd_t *pmd; pte_t *pte; @@ -68164,7 +69556,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c __set_current_state(TASK_RUNNING); count_vm_event(PGFAULT); -@@ -3457,6 +3667,34 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3457,6 +3667,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); @@ -68199,7 +69591,7 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/mm/memory.c pgd = pgd_offset(mm, address); pud = pud_alloc(mm, pgd, address); if (!pud) -@@ -3486,7 +3724,7 @@ int handle_mm_fault(struct mm_struct *mm +@@ -3486,7 +3724,7 @@ int handle_mm_fault(struct mm_struct *mm, struct vm_area_struct *vma, * run pte_offset_map on the pmd, if an huge pmd could * materialize from under us from a different thread. */ @@ -68217,94 +69609,11 @@ diff -urNp linux-3.0.9/mm/memory.c linux-3.0.9/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.0.9/mm/memory-failure.c linux-3.0.9/mm/memory-failure.c ---- linux-3.0.9/mm/memory-failure.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/memory-failure.c 2011-11-12 12:47:14.000000000 -0500 -@@ -59,7 +59,7 @@ int sysctl_memory_failure_early_kill __r - - int sysctl_memory_failure_recovery __read_mostly = 1; - --atomic_long_t mce_bad_pages __read_mostly = ATOMIC_LONG_INIT(0); -+atomic_long_unchecked_t mce_bad_pages __read_mostly = ATOMIC_LONG_INIT(0); - - #if defined(CONFIG_HWPOISON_INJECT) || defined(CONFIG_HWPOISON_INJECT_MODULE) - -@@ -200,7 +200,7 @@ static int kill_proc_ao(struct task_stru - si.si_signo = SIGBUS; - si.si_errno = 0; - si.si_code = BUS_MCEERR_AO; -- si.si_addr = (void *)addr; -+ si.si_addr = (void __user *)addr; - #ifdef __ARCH_SI_TRAPNO - si.si_trapno = trapno; - #endif -@@ -1008,7 +1008,7 @@ int __memory_failure(unsigned long pfn, - } - - nr_pages = 1 << compound_trans_order(hpage); -- atomic_long_add(nr_pages, &mce_bad_pages); -+ atomic_long_add_unchecked(nr_pages, &mce_bad_pages); - - /* - * We need/can do nothing about count=0 pages. -@@ -1038,7 +1038,7 @@ int __memory_failure(unsigned long pfn, - if (!PageHWPoison(hpage) - || (hwpoison_filter(p) && TestClearPageHWPoison(p)) - || (p != 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); -@@ -1096,7 +1096,7 @@ int __memory_failure(unsigned long pfn, - } - 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; -@@ -1222,7 +1222,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; - } -@@ -1236,7 +1236,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 = 1; - if (PageHuge(page)) - clear_page_hwpoison_huge_page(page); -@@ -1349,7 +1349,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 */ -@@ -1480,7 +1480,7 @@ int soft_offline_page(struct page *page, - return ret; - - 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.0.9/mm/mempolicy.c linux-3.0.9/mm/mempolicy.c ---- linux-3.0.9/mm/mempolicy.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/mempolicy.c 2011-11-12 12:47:14.000000000 -0500 -@@ -639,6 +639,10 @@ static int mbind_range(struct mm_struct +diff --git a/mm/mempolicy.c b/mm/mempolicy.c +index e7fb9d2..fb233ed 100644 +--- a/mm/mempolicy.c ++++ b/mm/mempolicy.c +@@ -639,6 +639,10 @@ static int mbind_range(struct mm_struct *mm, unsigned long start, unsigned long vmstart; unsigned long vmend; @@ -68315,7 +69624,7 @@ diff -urNp linux-3.0.9/mm/mempolicy.c linux-3.0.9/mm/mempolicy.c vma = 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 +@@ -669,6 +673,16 @@ static int mbind_range(struct mm_struct *mm, unsigned long start, err = policy_vma(vma, new_pol); if (err) goto out; @@ -68332,7 +69641,7 @@ diff -urNp linux-3.0.9/mm/mempolicy.c linux-3.0.9/mm/mempolicy.c } out: -@@ -1102,6 +1116,17 @@ static long do_mbind(unsigned long start +@@ -1102,6 +1116,17 @@ static long do_mbind(unsigned long start, unsigned long len, if (end < start) return -EINVAL; @@ -68350,7 +69659,7 @@ diff -urNp linux-3.0.9/mm/mempolicy.c linux-3.0.9/mm/mempolicy.c if (end == start) return 0; -@@ -1320,6 +1345,14 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pi +@@ -1320,6 +1345,14 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pid, unsigned long, maxnode, if (!mm) goto out; @@ -68365,7 +69674,7 @@ diff -urNp linux-3.0.9/mm/mempolicy.c linux-3.0.9/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, unsigned long, maxnode, rcu_read_lock(); tcred = __task_cred(task); if (cred->euid != tcred->suid && cred->euid != tcred->uid && @@ -68375,10 +69684,11 @@ diff -urNp linux-3.0.9/mm/mempolicy.c linux-3.0.9/mm/mempolicy.c rcu_read_unlock(); err = -EPERM; goto out; -diff -urNp linux-3.0.9/mm/migrate.c linux-3.0.9/mm/migrate.c ---- linux-3.0.9/mm/migrate.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/migrate.c 2011-11-12 12:47:14.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, struct task_struct *task, unsigned long chunk_start; int err; @@ -68387,7 +69697,7 @@ diff -urNp linux-3.0.9/mm/migrate.c linux-3.0.9/mm/migrate.c task_nodes = cpuset_mems_allowed(task); err = -ENOMEM; -@@ -1308,6 +1310,14 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, +@@ -1308,6 +1310,14 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, unsigned long, nr_pages, if (!mm) return -EINVAL; @@ -68402,7 +69712,7 @@ diff -urNp linux-3.0.9/mm/migrate.c linux-3.0.9/mm/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, +@@ -1317,8 +1327,7 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, unsigned long, nr_pages, rcu_read_lock(); tcred = __task_cred(task); if (cred->euid != tcred->suid && cred->euid != tcred->uid && @@ -68412,9 +69722,10 @@ diff -urNp linux-3.0.9/mm/migrate.c linux-3.0.9/mm/migrate.c rcu_read_unlock(); err = -EPERM; goto out; -diff -urNp linux-3.0.9/mm/mlock.c linux-3.0.9/mm/mlock.c ---- linux-3.0.9/mm/mlock.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/mlock.c 2011-11-12 12:47:14.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 <linux/pagemap.h> #include <linux/mempolicy.h> @@ -68423,7 +69734,7 @@ diff -urNp linux-3.0.9/mm/mlock.c linux-3.0.9/mm/mlock.c #include <linux/sched.h> #include <linux/module.h> #include <linux/rmap.h> -@@ -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 == start) return 0; @@ -68433,7 +69744,7 @@ diff -urNp linux-3.0.9/mm/mlock.c linux-3.0.9/mm/mlock.c vma = 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 = start ; ; ) { vm_flags_t newflags; @@ -68445,7 +69756,7 @@ diff -urNp linux-3.0.9/mm/mlock.c linux-3.0.9/mm/mlock.c /* Here we know that vma->vm_start <= nstart < vma->vm_end. */ newflags = 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 >>= PAGE_SHIFT; /* check against resource limits */ @@ -68453,7 +69764,7 @@ diff -urNp linux-3.0.9/mm/mlock.c linux-3.0.9/mm/mlock.c if ((locked <= lock_limit) || capable(CAP_IPC_LOCK)) error = do_mlock(start, len, 1); up_write(¤t->mm->mmap_sem); -@@ -515,17 +525,23 @@ SYSCALL_DEFINE2(munlock, unsigned long, +@@ -515,17 +525,23 @@ SYSCALL_DEFINE2(munlock, unsigned long, start, size_t, len) static int do_mlockall(int flags) { struct vm_area_struct * vma, * prev = NULL; @@ -68488,9 +69799,10 @@ diff -urNp linux-3.0.9/mm/mlock.c linux-3.0.9/mm/mlock.c if (!(flags & MCL_CURRENT) || (current->mm->total_vm <= lock_limit) || capable(CAP_IPC_LOCK)) ret = do_mlockall(flags); -diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c ---- linux-3.0.9/mm/mmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/mmap.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/mmap.c b/mm/mmap.c +index d49736f..b7db41b 100644 +--- a/mm/mmap.c ++++ b/mm/mmap.c @@ -46,6 +46,16 @@ #define arch_rebalance_pgtables(addr, len) (addr) #endif @@ -68508,7 +69820,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/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); -@@ -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 * */ @@ -68544,7 +69856,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * Make sure vm_committed_as in one cacheline and not cacheline shared with * other variables. It can be updated by several CPUs frequently. -@@ -236,6 +256,7 @@ static struct vm_area_struct *remove_vma +@@ -236,6 +256,7 @@ static struct vm_area_struct *remove_vma(struct vm_area_struct *vma) struct vm_area_struct *next = vma->vm_next; might_sleep(); @@ -68586,7 +69898,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (is_mergeable_vma(vma, file, vm_flags) && is_mergeable_anon_vma(anon_vma, vma->anon_vma, vma)) { pgoff_t vm_pglen; -@@ -758,13 +792,20 @@ can_vma_merge_after(struct vm_area_struc +@@ -758,13 +792,20 @@ can_vma_merge_after(struct vm_area_struct *vma, unsigned 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, @@ -68608,7 +69920,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * We later require that vma->vm_flags == vm_flags, * so this tests vma->vm_flags & VM_SPECIAL, too. -@@ -780,6 +821,15 @@ struct vm_area_struct *vma_merge(struct +@@ -780,6 +821,15 @@ struct vm_area_struct *vma_merge(struct mm_struct *mm, if (next && next->vm_end == end) /* cases 6, 7, 8 */ next = next->vm_next; @@ -68624,7 +69936,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * Can it merge with the predecessor? */ -@@ -799,9 +849,24 @@ struct vm_area_struct *vma_merge(struct +@@ -799,9 +849,24 @@ struct vm_area_struct *vma_merge(struct mm_struct *mm, /* cases 1, 6 */ err = vma_adjust(prev, prev->vm_start, next->vm_end, prev->vm_pgoff, NULL); @@ -68650,7 +69962,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (err) return NULL; khugepaged_enter_vma_merge(prev); -@@ -815,12 +880,27 @@ struct vm_area_struct *vma_merge(struct +@@ -815,12 +880,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)) { @@ -68696,7 +70008,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c mm->stack_vm += pages; if (flags & (VM_RESERVED|VM_IO)) mm->reserved_vm += pages; -@@ -963,7 +1040,7 @@ unsigned long do_mmap_pgoff(struct file +@@ -963,7 +1040,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsigned long addr, * (the exception is when the underlying filesystem is noexec * mounted, in which case we dont add PROT_EXEC.) */ @@ -68705,7 +70017,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (!(file && (file->f_path.mnt->mnt_flags & MNT_NOEXEC))) prot |= PROT_EXEC; -@@ -989,7 +1066,7 @@ unsigned long do_mmap_pgoff(struct file +@@ -989,7 +1066,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsigned 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. */ @@ -68714,7 +70026,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (addr & ~PAGE_MASK) return addr; -@@ -1000,6 +1077,36 @@ unsigned long do_mmap_pgoff(struct file +@@ -1000,6 +1077,36 @@ unsigned long do_mmap_pgoff(struct file *file, unsigned long addr, vm_flags = calc_vm_prot_bits(prot) | calc_vm_flag_bits(flags) | mm->def_flags | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC; @@ -68751,7 +70063,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (flags & MAP_LOCKED) if (!can_do_mlock()) return -EPERM; -@@ -1011,6 +1118,7 @@ unsigned long do_mmap_pgoff(struct file +@@ -1011,6 +1118,7 @@ unsigned long do_mmap_pgoff(struct file *file, unsigned long addr, locked += mm->locked_vm; lock_limit = rlimit(RLIMIT_MEMLOCK); lock_limit >>= PAGE_SHIFT; @@ -68759,7 +70071,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (locked > lock_limit && !capable(CAP_IPC_LOCK)) return -EAGAIN; } -@@ -1081,6 +1189,9 @@ unsigned long do_mmap_pgoff(struct file +@@ -1081,6 +1189,9 @@ unsigned long do_mmap_pgoff(struct file *file, unsigned long addr, if (error) return error; @@ -68769,7 +70081,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c return mmap_region(file, addr, len, flags, vm_flags, pgoff); } EXPORT_SYMBOL(do_mmap_pgoff); -@@ -1161,7 +1272,7 @@ int vma_wants_writenotify(struct vm_area +@@ -1161,7 +1272,7 @@ int vma_wants_writenotify(struct vm_area_struct *vma) vm_flags_t vm_flags = vma->vm_flags; /* If it was private or non-writable, the write bit is already clear */ @@ -68778,7 +70090,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c return 0; /* The backer wishes to know when pages are first written to? */ -@@ -1210,14 +1321,24 @@ unsigned long mmap_region(struct file *f +@@ -1210,14 +1321,24 @@ unsigned long mmap_region(struct file *file, unsigned long addr, unsigned long charged = 0; struct inode *inode = file ? file->f_path.dentry->d_inode : NULL; @@ -68920,7 +70232,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* Get an address range which is currently unmapped. * For shmat() with addr=0. * -@@ -1382,18 +1576,23 @@ arch_get_unmapped_area(struct file *filp +@@ -1382,18 +1576,23 @@ arch_get_unmapped_area(struct file *filp, unsigned long addr, if (flags & MAP_FIXED) return addr; @@ -69003,7 +70315,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c mm->free_area_cache = addr; mm->cached_hole_size = ~0UL; } -@@ -1449,7 +1654,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1449,7 +1654,7 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, { struct vm_area_struct *vma; struct mm_struct *mm = current->mm; @@ -69012,7 +70324,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* requested length too big for entire address space */ if (len > TASK_SIZE) -@@ -1458,13 +1663,18 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1458,13 +1663,18 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, if (flags & MAP_FIXED) return addr; @@ -69035,7 +70347,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c } /* check if free_area_cache is useful for us */ -@@ -1479,7 +1689,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1479,7 +1689,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 = find_vma(mm, addr-len); @@ -69044,7 +70356,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache = addr-len); } -@@ -1496,7 +1706,7 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1496,7 +1706,7 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, * return with success: */ vma = find_vma(mm, addr); @@ -69053,7 +70365,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* remember the address as a hint for next time */ return (mm->free_area_cache = addr); -@@ -1505,8 +1715,8 @@ arch_get_unmapped_area_topdown(struct fi +@@ -1505,8 +1715,8 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0, mm->cached_hole_size = vma->vm_start - addr; /* try just below the current vma->vm_start */ @@ -69101,7 +70413,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * Is this a new hole at the highest possible address? */ -@@ -1537,8 +1761,10 @@ void arch_unmap_area_topdown(struct mm_s +@@ -1537,8 +1761,10 @@ void arch_unmap_area_topdown(struct mm_struct *mm, unsigned long addr) mm->free_area_cache = addr; /* dont allow allocations above current base */ @@ -69142,7 +70454,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * Verify that the stack growth is acceptable and * update accounting. This is shared with both the -@@ -1662,6 +1910,7 @@ static int acct_stack_growth(struct vm_a +@@ -1662,6 +1910,7 @@ static int acct_stack_growth(struct vm_area_struct *vma, unsigned long size, uns return -ENOMEM; /* Stack limit test */ @@ -69150,7 +70462,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (size > ACCESS_ONCE(rlim[RLIMIT_STACK].rlim_cur)) return -ENOMEM; -@@ -1672,6 +1921,7 @@ static int acct_stack_growth(struct vm_a +@@ -1672,6 +1921,7 @@ static int acct_stack_growth(struct vm_area_struct *vma, unsigned long size, uns locked = mm->locked_vm + grow; limit = ACCESS_ONCE(rlim[RLIMIT_MEMLOCK].rlim_cur); limit >>= PAGE_SHIFT; @@ -69158,7 +70470,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (locked > limit && !capable(CAP_IPC_LOCK)) return -ENOMEM; } -@@ -1702,37 +1952,48 @@ static int acct_stack_growth(struct vm_a +@@ -1702,37 +1952,48 @@ static int acct_stack_growth(struct vm_area_struct *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. */ @@ -69216,7 +70528,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c unsigned long size, grow; size = address - vma->vm_start; -@@ -1747,6 +2008,8 @@ int expand_upwards(struct vm_area_struct +@@ -1747,6 +2008,8 @@ int expand_upwards(struct vm_area_struct *vma, unsigned long address) } } } @@ -69225,7 +70537,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c vma_unlock_anon_vma(vma); khugepaged_enter_vma_merge(vma); return error; -@@ -1760,6 +2023,8 @@ int expand_downwards(struct vm_area_stru +@@ -1760,6 +2023,8 @@ int expand_downwards(struct vm_area_struct *vma, unsigned long address) { int error; @@ -69234,7 +70546,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * We must make sure the anon_vma is allocated -@@ -1773,6 +2038,15 @@ int expand_downwards(struct vm_area_stru +@@ -1773,6 +2038,15 @@ int expand_downwards(struct vm_area_struct *vma, if (error) return error; @@ -69250,7 +70562,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c vma_lock_anon_vma(vma); /* -@@ -1782,9 +2056,17 @@ int expand_downwards(struct vm_area_stru +@@ -1782,9 +2056,17 @@ int expand_downwards(struct vm_area_struct *vma, */ /* Somebody else might have raced and expanded it already */ @@ -69269,7 +70581,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c size = vma->vm_end - address; grow = (vma->vm_start - address) >> PAGE_SHIFT; -@@ -1794,11 +2076,22 @@ int expand_downwards(struct vm_area_stru +@@ -1794,11 +2076,22 @@ int expand_downwards(struct vm_area_struct *vma, if (!error) { vma->vm_start = address; vma->vm_pgoff -= grow; @@ -69292,7 +70604,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c khugepaged_enter_vma_merge(vma); return error; } -@@ -1868,6 +2161,13 @@ static void remove_vma_list(struct mm_st +@@ -1868,6 +2161,13 @@ static void remove_vma_list(struct mm_struct *mm, struct vm_area_struct *vma) do { long nrpages = vma_pages(vma); @@ -69306,7 +70618,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c mm->total_vm -= nrpages; vm_stat_account(mm, vma->vm_flags, vma->vm_file, -nrpages); vma = remove_vma(vma); -@@ -1913,6 +2213,16 @@ detach_vmas_to_be_unmapped(struct mm_str +@@ -1913,6 +2213,16 @@ detach_vmas_to_be_unmapped(struct mm_struct *mm, struct vm_area_struct *vma, insertion_point = (prev ? &prev->vm_next : &mm->mmap); vma->vm_prev = NULL; do { @@ -69323,7 +70635,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c rb_erase(&vma->vm_rb, &mm->mm_rb); mm->map_count--; tail_vma = vma; -@@ -1941,14 +2251,33 @@ static int __split_vma(struct mm_struct +@@ -1941,14 +2251,33 @@ static int __split_vma(struct mm_struct * mm, struct vm_area_struct * vma, struct vm_area_struct *new; int err = -ENOMEM; @@ -69357,7 +70669,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* most fields are the same, copy all, and then fixup */ *new = *vma; -@@ -1961,6 +2290,22 @@ static int __split_vma(struct mm_struct +@@ -1961,6 +2290,22 @@ static int __split_vma(struct mm_struct * mm, struct vm_area_struct * vma, new->vm_pgoff += ((addr - vma->vm_start) >> PAGE_SHIFT); } @@ -69380,7 +70692,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c pol = mpol_dup(vma_policy(vma)); if (IS_ERR(pol)) { err = PTR_ERR(pol); -@@ -1986,6 +2331,42 @@ static int __split_vma(struct mm_struct +@@ -1986,6 +2331,42 @@ static int __split_vma(struct mm_struct * mm, struct vm_area_struct * vma, else err = vma_adjust(vma, vma->vm_start, addr, vma->vm_pgoff, new); @@ -69423,7 +70735,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* Success. */ if (!err) return 0; -@@ -1998,10 +2379,18 @@ static int __split_vma(struct mm_struct +@@ -1998,10 +2379,18 @@ static int __split_vma(struct mm_struct * mm, struct vm_area_struct * vma, removed_exe_file_vma(mm); fput(new->vm_file); } @@ -69443,7 +70755,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c kmem_cache_free(vm_area_cachep, new); out_err: return err; -@@ -2014,6 +2403,15 @@ static int __split_vma(struct mm_struct +@@ -2014,6 +2403,15 @@ static int __split_vma(struct mm_struct * mm, struct vm_area_struct * vma, int split_vma(struct mm_struct *mm, struct vm_area_struct *vma, unsigned long addr, int new_below) { @@ -69459,7 +70771,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (mm->map_count >= sysctl_max_map_count) return -ENOMEM; -@@ -2025,11 +2423,30 @@ int split_vma(struct mm_struct *mm, stru +@@ -2025,11 +2423,30 @@ int split_vma(struct mm_struct *mm, struct vm_area_struct *vma, * work. This now handles partial unmappings. * Jeremy Fitzhardinge <jeremy@goop.org> */ @@ -69490,7 +70802,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if ((start & ~PAGE_MASK) || start > TASK_SIZE || len > TASK_SIZE-start) return -EINVAL; -@@ -2104,6 +2521,8 @@ int do_munmap(struct mm_struct *mm, unsi +@@ -2104,6 +2521,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); @@ -69499,7 +70811,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c return 0; } -@@ -2116,22 +2535,18 @@ SYSCALL_DEFINE2(munmap, unsigned long, a +@@ -2116,22 +2535,18 @@ SYSCALL_DEFINE2(munmap, unsigned long, addr, size_t, len) profile_munmap(addr); @@ -69528,7 +70840,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * this is really a simplified "do_mmap". it only handles * anonymous maps. eventually we may be able to do some -@@ -2145,6 +2560,7 @@ unsigned long do_brk(unsigned long addr, +@@ -2145,6 +2560,7 @@ unsigned long do_brk(unsigned long addr, unsigned long len) struct rb_node ** rb_link, * rb_parent; pgoff_t pgoff = addr >> PAGE_SHIFT; int error; @@ -69536,7 +70848,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c len = PAGE_ALIGN(len); if (!len) -@@ -2156,16 +2572,30 @@ unsigned long do_brk(unsigned long addr, +@@ -2156,16 +2572,30 @@ unsigned long do_brk(unsigned long addr, unsigned long len) flags = VM_DATA_DEFAULT_FLAGS | VM_ACCOUNT | mm->def_flags; @@ -69568,7 +70880,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c locked += mm->locked_vm; lock_limit = rlimit(RLIMIT_MEMLOCK); lock_limit >>= PAGE_SHIFT; -@@ -2182,22 +2612,22 @@ unsigned long do_brk(unsigned long addr, +@@ -2182,22 +2612,22 @@ unsigned long do_brk(unsigned long addr, unsigned long len) /* * Clear old maps. this also does some error checking for us */ @@ -69595,7 +70907,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c return -ENOMEM; /* Can we just expand an old private anonymous mapping? */ -@@ -2211,7 +2641,7 @@ unsigned long do_brk(unsigned long addr, +@@ -2211,7 +2641,7 @@ unsigned long do_brk(unsigned long addr, unsigned long len) */ vma = kmem_cache_zalloc(vm_area_cachep, GFP_KERNEL); if (!vma) { @@ -69604,7 +70916,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c return -ENOMEM; } -@@ -2225,11 +2655,12 @@ unsigned long do_brk(unsigned long addr, +@@ -2225,11 +2655,12 @@ unsigned long do_brk(unsigned long addr, unsigned long len) vma_link(mm, vma, prev, rb_link, rb_parent); out: perf_event_mmap(vma); @@ -69631,7 +70943,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c BUG_ON(mm->nr_ptes > (FIRST_USER_ADDRESS+PMD_SIZE-1)>>PMD_SHIFT); } -@@ -2291,6 +2724,13 @@ int insert_vm_struct(struct mm_struct * +@@ -2291,6 +2724,13 @@ int insert_vm_struct(struct mm_struct * mm, struct vm_area_struct * vma) struct vm_area_struct * __vma, * prev; struct rb_node ** rb_link, * rb_parent; @@ -69645,7 +70957,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/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 -@@ -2313,7 +2753,22 @@ int insert_vm_struct(struct mm_struct * +@@ -2313,7 +2753,22 @@ int insert_vm_struct(struct mm_struct * mm, struct vm_area_struct * vma) if ((vma->vm_flags & VM_ACCOUNT) && security_vm_enough_memory_mm(mm, vma_pages(vma))) return -ENOMEM; @@ -69668,7 +70980,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c return 0; } -@@ -2331,6 +2786,8 @@ struct vm_area_struct *copy_vma(struct v +@@ -2331,6 +2786,8 @@ struct vm_area_struct *copy_vma(struct vm_area_struct **vmap, struct rb_node **rb_link, *rb_parent; struct mempolicy *pol; @@ -69677,7 +70989,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * If anonymous vma has not yet been faulted, update new pgoff * to match new location, to increase its chance of merging. -@@ -2381,6 +2838,39 @@ struct vm_area_struct *copy_vma(struct v +@@ -2381,6 +2838,39 @@ struct vm_area_struct *copy_vma(struct vm_area_struct **vmap, return NULL; } @@ -69717,7 +71029,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c /* * Return true if the calling process may expand its vm space by the passed * number of pages -@@ -2391,7 +2881,7 @@ int may_expand_vm(struct mm_struct *mm, +@@ -2391,7 +2881,7 @@ int may_expand_vm(struct mm_struct *mm, unsigned long npages) unsigned long lim; lim = rlimit(RLIMIT_AS) >> PAGE_SHIFT; @@ -69726,7 +71038,7 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c if (cur + npages > lim) return 0; return 1; -@@ -2462,6 +2952,22 @@ int install_special_mapping(struct mm_st +@@ -2462,6 +2952,22 @@ int install_special_mapping(struct mm_struct *mm, vma->vm_start = addr; vma->vm_end = addr + len; @@ -69749,9 +71061,10 @@ diff -urNp linux-3.0.9/mm/mmap.c linux-3.0.9/mm/mmap.c vma->vm_flags = vm_flags | mm->def_flags | VM_DONTEXPAND; vma->vm_page_prot = vm_get_page_prot(vma->vm_flags); -diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c ---- linux-3.0.9/mm/mprotect.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/mprotect.c 2011-11-12 12:47:14.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 <linux/mmu_notifier.h> #include <linux/migrate.h> @@ -69769,7 +71082,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c #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); } @@ -69818,7 +71131,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c int mprotect_fixup(struct vm_area_struct *vma, struct vm_area_struct **pprev, 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 = 0; @@ -69848,7 +71161,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/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 vm_area_struct **pprev, } } @@ -69914,7 +71227,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c if (vma_wants_writenotify(vma)) { vma->vm_page_prot = 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, size_t, len, end = start + len; if (end <= start) return -ENOMEM; @@ -69932,7 +71245,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c if (!arch_validate_prot(prot)) return -EINVAL; -@@ -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: */ @@ -69941,7 +71254,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c prot |= PROT_EXEC; vm_flags = calc_vm_prot_bits(prot); -@@ -287,6 +412,11 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -287,6 +412,11 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, size_t, len, if (start > vma->vm_start) prev = vma; @@ -69953,7 +71266,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c for (nstart = start ; ; ) { unsigned long newflags; -@@ -296,6 +426,14 @@ SYSCALL_DEFINE3(mprotect, unsigned long, +@@ -296,6 +426,14 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, size_t, len, /* newflags >> 4 shift VM_MAY% in place of VM_% */ if ((newflags & ~(newflags >> 4)) & (VM_READ | VM_WRITE | VM_EXEC)) { @@ -69968,7 +71281,7 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c error = -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 = mprotect_fixup(vma, &prev, nstart, tmp, newflags); if (error) goto out; @@ -69978,10 +71291,11 @@ diff -urNp linux-3.0.9/mm/mprotect.c linux-3.0.9/mm/mprotect.c nstart = tmp; if (nstart < prev->vm_end) -diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/mm/mremap.c ---- linux-3.0.9/mm/mremap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/mremap.c 2011-11-12 12:47:14.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, pmd_t *old_pmd, continue; pte = ptep_clear_flush(vma, old_addr, old_pte); pte = move_pte(pte, new_vma->vm_page_prot, old_addr, new_addr); @@ -69994,7 +71308,7 @@ diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/mm/mremap.c set_pte_at(mm, new_addr, new_pte, pte); } -@@ -272,6 +278,11 @@ static struct vm_area_struct *vma_to_res +@@ -272,6 +278,11 @@ static struct vm_area_struct *vma_to_resize(unsigned long addr, if (is_vm_hugetlb_page(vma)) goto Einval; @@ -70006,7 +71320,7 @@ diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/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 +@@ -328,20 +339,25 @@ static unsigned long mremap_to(unsigned long addr, unsigned long ret = -EINVAL; unsigned long charged = 0; unsigned long map_flags; @@ -70037,7 +71351,7 @@ diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/mm/mremap.c goto out; ret = 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 = -EINVAL; unsigned long charged = 0; @@ -70045,7 +71359,7 @@ diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/mm/mremap.c 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; @@ -70063,7 +71377,7 @@ diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/mm/mremap.c if (flags & MREMAP_FIXED) { if (flags & MREMAP_MAYMOVE) ret = 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 = addr; @@ -70071,7 +71385,7 @@ diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/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 = security_file_mmap(NULL, 0, 0, 0, new_addr, 1); if (ret) goto out; @@ -70085,10 +71399,11 @@ diff -urNp linux-3.0.9/mm/mremap.c linux-3.0.9/mm/mremap.c } out: if (ret & ~PAGE_MASK) -diff -urNp linux-3.0.9/mm/nobootmem.c linux-3.0.9/mm/nobootmem.c ---- linux-3.0.9/mm/nobootmem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/nobootmem.c 2011-11-12 12:47:14.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 long start, unsigned long end) unsigned long __init free_all_memory_core_early(int nodeid) { int i; @@ -70121,10 +71436,11 @@ diff -urNp linux-3.0.9/mm/nobootmem.c linux-3.0.9/mm/nobootmem.c return count; } -diff -urNp linux-3.0.9/mm/nommu.c linux-3.0.9/mm/nommu.c ---- linux-3.0.9/mm/nommu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/nommu.c 2011-11-12 12:47:14.000000000 -0500 -@@ -63,7 +63,6 @@ int sysctl_overcommit_memory = OVERCOMMI +diff --git a/mm/nommu.c b/mm/nommu.c +index 9edc897..955be3d 100644 +--- a/mm/nommu.c ++++ b/mm/nommu.c +@@ -63,7 +63,6 @@ int sysctl_overcommit_memory = OVERCOMMIT_GUESS; /* heuristic overcommit */ int sysctl_overcommit_ratio = 50; /* default is 50% */ int sysctl_max_map_count = DEFAULT_MAX_MAP_COUNT; int sysctl_nr_trim_pages = CONFIG_NOMMU_INITIAL_TRIM_EXCESS; @@ -70132,7 +71448,7 @@ diff -urNp linux-3.0.9/mm/nommu.c linux-3.0.9/mm/nommu.c atomic_long_t mmap_pages_allocated; -@@ -826,15 +825,6 @@ struct vm_area_struct *find_vma(struct m +@@ -826,15 +825,6 @@ struct vm_area_struct *find_vma(struct mm_struct *mm, unsigned long addr) EXPORT_SYMBOL(find_vma); /* @@ -70148,7 +71464,7 @@ diff -urNp linux-3.0.9/mm/nommu.c linux-3.0.9/mm/nommu.c * expand a stack to a given address * - not supported under NOMMU conditions */ -@@ -1554,6 +1544,7 @@ int split_vma(struct mm_struct *mm, stru +@@ -1554,6 +1544,7 @@ int split_vma(struct mm_struct *mm, struct vm_area_struct *vma, /* most fields are the same, copy all, and then fixup */ *new = *vma; @@ -70156,9 +71472,10 @@ diff -urNp linux-3.0.9/mm/nommu.c linux-3.0.9/mm/nommu.c *region = *vma->vm_region; new->vm_region = region; -diff -urNp linux-3.0.9/mm/page_alloc.c linux-3.0.9/mm/page_alloc.c ---- linux-3.0.9/mm/page_alloc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/page_alloc.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/page_alloc.c b/mm/page_alloc.c +index 0f50cdb..df4b678 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. */ @@ -70168,7 +71485,7 @@ diff -urNp linux-3.0.9/mm/page_alloc.c linux-3.0.9/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, unsigned int order) int i; int bad = 0; @@ -70179,7 +71496,7 @@ diff -urNp linux-3.0.9/mm/page_alloc.c linux-3.0.9/mm/page_alloc.c trace_mm_page_free_direct(page, order); kmemcheck_free_shadow(page, order); -@@ -668,6 +672,12 @@ static bool free_pages_prepare(struct pa +@@ -668,6 +672,12 @@ static bool free_pages_prepare(struct page *page, unsigned int order) debug_check_no_obj_freed(page_address(page), PAGE_SIZE << order); } @@ -70192,7 +71509,7 @@ diff -urNp linux-3.0.9/mm/page_alloc.c linux-3.0.9/mm/page_alloc.c arch_free_page(page, order); kernel_map_pages(page, 1 << order, 0); -@@ -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 order, gfp_t gfp_flags) arch_alloc_page(page, order); kernel_map_pages(page, 1 << order, 1); @@ -70203,7 +71520,7 @@ diff -urNp linux-3.0.9/mm/page_alloc.c linux-3.0.9/mm/page_alloc.c if (order && (gfp_flags & __GFP_COMP)) prep_compound_page(page, order); -@@ -2557,6 +2569,8 @@ void show_free_areas(unsigned int filter +@@ -2557,6 +2569,8 @@ void show_free_areas(unsigned int filter) int cpu; struct zone *zone; @@ -70212,7 +71529,7 @@ diff -urNp linux-3.0.9/mm/page_alloc.c linux-3.0.9/mm/page_alloc.c for_each_populated_zone(zone) { if (skip_free_areas_node(filter, zone_to_nid(zone))) continue; -@@ -3368,7 +3382,13 @@ static int pageblock_is_reserved(unsigne +@@ -3368,7 +3382,13 @@ static int pageblock_is_reserved(unsigned long start_pfn, unsigned long end_pfn) unsigned long pfn; for (pfn = start_pfn; pfn < end_pfn; pfn++) { @@ -70226,10 +71543,11 @@ diff -urNp linux-3.0.9/mm/page_alloc.c linux-3.0.9/mm/page_alloc.c return 1; } return 0; -diff -urNp linux-3.0.9/mm/percpu.c linux-3.0.9/mm/percpu.c ---- linux-3.0.9/mm/percpu.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/percpu.c 2011-11-12 12:47:14.000000000 -0500 -@@ -121,7 +121,7 @@ static unsigned int pcpu_first_unit_cpu +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_mostly; static unsigned int pcpu_last_unit_cpu __read_mostly; /* the address of the first chunk which starts with the kernel static area */ @@ -70238,10 +71556,11 @@ diff -urNp linux-3.0.9/mm/percpu.c linux-3.0.9/mm/percpu.c EXPORT_SYMBOL_GPL(pcpu_base_addr); static const int *pcpu_unit_map __read_mostly; /* cpu -> unit */ -diff -urNp linux-3.0.9/mm/rmap.c linux-3.0.9/mm/rmap.c ---- linux-3.0.9/mm/rmap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/rmap.c 2011-11-12 12:47:14.000000000 -0500 -@@ -153,6 +153,10 @@ int anon_vma_prepare(struct vm_area_stru +diff --git a/mm/rmap.c b/mm/rmap.c +index 23295f6..1a390d5 100644 +--- a/mm/rmap.c ++++ b/mm/rmap.c +@@ -153,6 +153,10 @@ int anon_vma_prepare(struct vm_area_struct *vma) struct anon_vma *anon_vma = vma->anon_vma; struct anon_vma_chain *avc; @@ -70252,7 +71571,7 @@ diff -urNp linux-3.0.9/mm/rmap.c linux-3.0.9/mm/rmap.c might_sleep(); if (unlikely(!anon_vma)) { struct mm_struct *mm = vma->vm_mm; -@@ -162,6 +166,12 @@ int anon_vma_prepare(struct vm_area_stru +@@ -162,6 +166,12 @@ int anon_vma_prepare(struct vm_area_struct *vma) if (!avc) goto out_enomem; @@ -70265,7 +71584,7 @@ diff -urNp linux-3.0.9/mm/rmap.c linux-3.0.9/mm/rmap.c anon_vma = find_mergeable_anon_vma(vma); allocated = NULL; if (!anon_vma) { -@@ -175,6 +185,21 @@ int anon_vma_prepare(struct vm_area_stru +@@ -175,6 +185,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)) { @@ -70287,7 +71606,7 @@ diff -urNp linux-3.0.9/mm/rmap.c linux-3.0.9/mm/rmap.c vma->anon_vma = anon_vma; avc->anon_vma = anon_vma; avc->vma = vma; -@@ -188,12 +213,24 @@ int anon_vma_prepare(struct vm_area_stru +@@ -188,12 +213,24 @@ int anon_vma_prepare(struct vm_area_struct *vma) if (unlikely(allocated)) put_anon_vma(allocated); @@ -70312,7 +71631,7 @@ diff -urNp linux-3.0.9/mm/rmap.c linux-3.0.9/mm/rmap.c anon_vma_chain_free(avc); out_enomem: return -ENOMEM; -@@ -244,7 +281,7 @@ static void anon_vma_chain_link(struct v +@@ -244,7 +281,7 @@ static void anon_vma_chain_link(struct vm_area_struct *vma, * Attach the anon_vmas from src to dst. * Returns 0 on success, -ENOMEM on failure. */ @@ -70321,7 +71640,7 @@ diff -urNp linux-3.0.9/mm/rmap.c linux-3.0.9/mm/rmap.c { struct anon_vma_chain *avc, *pavc; struct anon_vma *root = NULL; -@@ -277,7 +314,7 @@ int anon_vma_clone(struct vm_area_struct +@@ -277,7 +314,7 @@ int anon_vma_clone(struct vm_area_struct *dst, struct vm_area_struct *src) * the corresponding VMA in the parent process is attached to. * Returns 0 on success, non-zero on failure. */ @@ -70330,9 +71649,10 @@ diff -urNp linux-3.0.9/mm/rmap.c linux-3.0.9/mm/rmap.c { struct anon_vma_chain *avc; struct anon_vma *anon_vma; -diff -urNp linux-3.0.9/mm/shmem.c linux-3.0.9/mm/shmem.c ---- linux-3.0.9/mm/shmem.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/shmem.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/shmem.c b/mm/shmem.c +index fcedf54..af577ae 100644 +--- a/mm/shmem.c ++++ b/mm/shmem.c @@ -31,7 +31,7 @@ #include <linux/percpu_counter.h> #include <linux/swap.h> @@ -70342,7 +71662,7 @@ diff -urNp linux-3.0.9/mm/shmem.c linux-3.0.9/mm/shmem.c #ifdef CONFIG_SHMEM /* -@@ -1101,6 +1101,8 @@ static int shmem_writepage(struct page * +@@ -1101,6 +1101,8 @@ static int shmem_writepage(struct page *page, struct writeback_control *wbc) goto unlock; } entry = shmem_swp_entry(info, index, NULL); @@ -70351,7 +71671,7 @@ diff -urNp linux-3.0.9/mm/shmem.c linux-3.0.9/mm/shmem.c if (entry->val) { /* * The more uptodate page coming down from a stacked -@@ -1172,6 +1174,8 @@ static struct page *shmem_swapin(swp_ent +@@ -1172,6 +1174,8 @@ static struct page *shmem_swapin(swp_entry_t entry, gfp_t gfp, struct vm_area_struct pvma; struct page *page; @@ -70360,7 +71680,7 @@ diff -urNp linux-3.0.9/mm/shmem.c linux-3.0.9/mm/shmem.c spol = mpol_cond_copy(&mpol, mpol_shared_policy_lookup(&info->policy, idx)); -@@ -2568,8 +2572,7 @@ int shmem_fill_super(struct super_block +@@ -2568,8 +2572,7 @@ int shmem_fill_super(struct super_block *sb, void *data, int silent) int err = -ENOMEM; /* Round up to L1_CACHE_BYTES to resist false sharing */ @@ -70370,9 +71690,10 @@ diff -urNp linux-3.0.9/mm/shmem.c linux-3.0.9/mm/shmem.c if (!sbinfo) return -ENOMEM; -diff -urNp linux-3.0.9/mm/slab.c linux-3.0.9/mm/slab.c ---- linux-3.0.9/mm/slab.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/slab.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/slab.c b/mm/slab.c +index d96e223..9a48434 100644 +--- a/mm/slab.c ++++ b/mm/slab.c @@ -151,7 +151,7 @@ /* Legal flag mask for kmem_cache_create(). */ @@ -70400,7 +71721,7 @@ diff -urNp linux-3.0.9/mm/slab.c linux-3.0.9/mm/slab.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 *parent) if ((x)->max_freeable < i) \ (x)->max_freeable = i; \ } while (0) @@ -70415,7 +71736,7 @@ diff -urNp linux-3.0.9/mm/slab.c linux-3.0.9/mm/slab.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 +@@ -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, @@ -70460,7 +71781,7 @@ diff -urNp linux-3.0.9/mm/slab.c linux-3.0.9/mm/slab.c NULL); } #ifdef CONFIG_ZONE_DMA -@@ -4272,10 +4272,10 @@ static int s_show(struct seq_file *m, vo +@@ -4272,10 +4272,10 @@ static int s_show(struct seq_file *m, void *p) } /* cpu stats */ { @@ -70475,7 +71796,7 @@ diff -urNp linux-3.0.9/mm/slab.c linux-3.0.9/mm/slab.c seq_printf(m, " : cpustat %6lu %6lu %6lu %6lu", allochit, allocmiss, freehit, freemiss); -@@ -4532,15 +4532,66 @@ static const struct file_operations proc +@@ -4532,15 +4532,66 @@ static const struct file_operations proc_slabstats_operations = { static int __init slab_proc_init(void) { @@ -70544,9 +71865,10 @@ diff -urNp linux-3.0.9/mm/slab.c linux-3.0.9/mm/slab.c /** * ksize - get the actual amount of memory allocated for a given object * @objp: Pointer to the object -diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c ---- linux-3.0.9/mm/slob.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/slob.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/slob.c b/mm/slob.c +index 46e0aee..8539ef7 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 @@ -70583,7 +71905,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c } 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) static inline struct slob_page *slob_page(const void *addr) { @@ -70592,7 +71914,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c } /* -@@ -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. */ @@ -70619,7 +71941,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.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, int node) if (!page) return NULL; @@ -70627,7 +71949,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c return page_address(page); } -@@ -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, int align, int node) if (!b) return NULL; sp = slob_page(b); @@ -70653,7 +71975,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c void *ret; lockdep_trace_alloc(gfp); -@@ -492,7 +494,10 @@ void *__kmalloc_node(size_t size, gfp_t +@@ -492,7 +494,10 @@ void *__kmalloc_node(size_t size, gfp_t gfp, int node) if (!m) return NULL; @@ -70665,7 +71987,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c ret = (void *)m + align; trace_kmalloc_node(_RET_IP_, ret, -@@ -504,16 +509,25 @@ void *__kmalloc_node(size_t size, gfp_t +@@ -504,16 +509,25 @@ void *__kmalloc_node(size_t size, gfp_t gfp, int node) gfp |= __GFP_COMP; ret = slob_new_pages(gfp, order, node); if (ret) { @@ -70801,7 +72123,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c } EXPORT_SYMBOL(ksize); -@@ -569,8 +658,13 @@ struct kmem_cache *kmem_cache_create(con +@@ -569,8 +658,13 @@ struct kmem_cache *kmem_cache_create(const char *name, size_t size, { struct kmem_cache *c; @@ -70815,7 +72137,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c if (c) { c->name = name; -@@ -608,17 +702,25 @@ void *kmem_cache_alloc_node(struct kmem_ +@@ -608,17 +702,25 @@ void *kmem_cache_alloc_node(struct kmem_cache *c, gfp_t flags, int node) { void *b; @@ -70860,7 +72182,7 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c } static void kmem_rcu_free(struct rcu_head *head) -@@ -646,17 +754,31 @@ static void kmem_rcu_free(struct rcu_hea +@@ -646,17 +754,31 @@ static void kmem_rcu_free(struct rcu_head *head) void kmem_cache_free(struct kmem_cache *c, void *b) { @@ -70895,9 +72217,10 @@ diff -urNp linux-3.0.9/mm/slob.c linux-3.0.9/mm/slob.c } EXPORT_SYMBOL(kmem_cache_free); -diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c ---- linux-3.0.9/mm/slub.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/slub.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/slub.c b/mm/slub.c +index 35f351f..2b60d47 100644 +--- a/mm/slub.c ++++ b/mm/slub.c @@ -200,7 +200,7 @@ struct track { enum track_item { TRACK_ALLOC, TRACK_FREE }; @@ -70907,7 +72230,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/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 *); -@@ -442,7 +442,7 @@ static void print_track(const char *s, s +@@ -442,7 +442,7 @@ static void print_track(const char *s, struct track *t) if (!t->addr) return; @@ -70916,7 +72239,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c s, (void *)t->addr, jiffies - t->when, t->cpu, t->pid); } -@@ -2137,6 +2137,8 @@ void kmem_cache_free(struct kmem_cache * +@@ -2137,6 +2137,8 @@ void kmem_cache_free(struct kmem_cache *s, void *x) page = virt_to_head_page(x); @@ -70934,7 +72257,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c /* * Calculate the order of allocation given an slab object size. -@@ -2594,7 +2596,7 @@ static int kmem_cache_open(struct kmem_c +@@ -2594,7 +2596,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)); @@ -70943,7 +72266,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c #ifdef CONFIG_NUMA s->remote_node_defrag_ratio = 1000; #endif -@@ -2699,8 +2701,7 @@ static inline int kmem_cache_close(struc +@@ -2699,8 +2701,7 @@ static inline int kmem_cache_close(struct kmem_cache *s) void kmem_cache_destroy(struct kmem_cache *s) { down_write(&slub_lock); @@ -70953,7 +72276,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c list_del(&s->list); if (kmem_cache_close(s)) { printk(KERN_ERR "SLUB %s: %s called for cache that " -@@ -2910,6 +2911,46 @@ void *__kmalloc_node(size_t size, gfp_t +@@ -2910,6 +2911,46 @@ void *__kmalloc_node(size_t size, gfp_t flags, int node) EXPORT_SYMBOL(__kmalloc_node); #endif @@ -71000,7 +72323,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c size_t ksize(const void *object) { struct page *page; -@@ -3154,7 +3195,7 @@ static void __init kmem_cache_bootstrap_ +@@ -3154,7 +3195,7 @@ static void __init kmem_cache_bootstrap_fixup(struct kmem_cache *s) int node; list_add(&s->list, &slab_caches); @@ -71030,7 +72353,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c caches++; } -@@ -3349,7 +3390,7 @@ static int slab_unmergeable(struct kmem_ +@@ -3349,7 +3390,7 @@ static int slab_unmergeable(struct kmem_cache *s) /* * We may have set a slab to be unmergeable during bootstrap. */ @@ -71039,7 +72362,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c return 1; return 0; -@@ -3408,7 +3449,7 @@ struct kmem_cache *kmem_cache_create(con +@@ -3408,7 +3449,7 @@ struct kmem_cache *kmem_cache_create(const char *name, size_t size, down_write(&slub_lock); s = find_mergeable(size, align, flags, name, ctor); if (s) { @@ -71048,7 +72371,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c /* * Adjust the object sizes so that we clear * the complete object on kzalloc. -@@ -3417,7 +3458,7 @@ struct kmem_cache *kmem_cache_create(con +@@ -3417,7 +3458,7 @@ struct kmem_cache *kmem_cache_create(const char *name, size_t size, s->inuse = max_t(int, s->inuse, ALIGN(size, sizeof(void *))); if (sysfs_slab_alias(s, name)) { @@ -71057,7 +72380,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c goto err; } up_write(&slub_lock); -@@ -3545,7 +3586,7 @@ void *__kmalloc_node_track_caller(size_t +@@ -3545,7 +3586,7 @@ void *__kmalloc_node_track_caller(size_t size, gfp_t gfpflags, } #endif @@ -71090,7 +72413,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c } SLAB_ATTR_RO(aliases); -@@ -4662,6 +4703,7 @@ static char *create_unique_id(struct kme +@@ -4662,6 +4703,7 @@ static char *create_unique_id(struct kmem_cache *s) return name; } @@ -71098,7 +72421,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c static int sysfs_slab_add(struct kmem_cache *s) { int err; -@@ -4724,6 +4766,7 @@ static void sysfs_slab_remove(struct kme +@@ -4724,6 +4766,7 @@ static void sysfs_slab_remove(struct kmem_cache *s) kobject_del(&s->kobj); kobject_put(&s->kobj); } @@ -71114,7 +72437,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c static int sysfs_slab_alias(struct kmem_cache *s, const char *name) { struct saved_alias *al; -@@ -4759,6 +4803,7 @@ static int sysfs_slab_alias(struct kmem_ +@@ -4759,6 +4803,7 @@ static int sysfs_slab_alias(struct kmem_cache *s, const char *name) alias_list = al; return 0; } @@ -71122,7 +72445,7 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c static int __init slab_sysfs_init(void) { -@@ -4894,7 +4939,13 @@ static const struct file_operations proc +@@ -4894,7 +4939,13 @@ static const struct file_operations proc_slabinfo_operations = { static int __init slab_proc_init(void) { @@ -71137,9 +72460,10 @@ diff -urNp linux-3.0.9/mm/slub.c linux-3.0.9/mm/slub.c return 0; } module_init(slab_proc_init); -diff -urNp linux-3.0.9/mm/swap.c linux-3.0.9/mm/swap.c ---- linux-3.0.9/mm/swap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/swap.c 2011-11-12 12:47:14.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 <linux/backing-dev.h> #include <linux/memcontrol.h> @@ -71148,7 +72472,7 @@ diff -urNp linux-3.0.9/mm/swap.c linux-3.0.9/mm/swap.c #include "internal.h" -@@ -71,6 +72,8 @@ static void __put_compound_page(struct p +@@ -71,6 +72,8 @@ static void __put_compound_page(struct page *page) __page_cache_release(page); dtor = get_compound_page_dtor(page); @@ -71157,9 +72481,10 @@ diff -urNp linux-3.0.9/mm/swap.c linux-3.0.9/mm/swap.c (*dtor)(page); } -diff -urNp linux-3.0.9/mm/swapfile.c linux-3.0.9/mm/swapfile.c ---- linux-3.0.9/mm/swapfile.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/swapfile.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/swapfile.c b/mm/swapfile.c +index ff8dc1a..fdc301a 100644 +--- a/mm/swapfile.c ++++ b/mm/swapfile.c @@ -62,7 +62,7 @@ static DEFINE_MUTEX(swapon_mutex); static DECLARE_WAIT_QUEUE_HEAD(proc_poll_wait); @@ -71169,7 +72494,7 @@ diff -urNp linux-3.0.9/mm/swapfile.c linux-3.0.9/mm/swapfile.c 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 *, specialfile) } filp_close(swap_file, NULL); err = 0; @@ -71178,7 +72503,7 @@ diff -urNp linux-3.0.9/mm/swapfile.c linux-3.0.9/mm/swapfile.c wake_up_interruptible(&proc_poll_wait); out_dput: -@@ -1692,8 +1692,8 @@ static unsigned swaps_poll(struct file * +@@ -1692,8 +1692,8 @@ static unsigned swaps_poll(struct file *file, poll_table *wait) poll_wait(file, &proc_poll_wait, wait); @@ -71189,7 +72514,7 @@ diff -urNp linux-3.0.9/mm/swapfile.c linux-3.0.9/mm/swapfile.c return POLLIN | POLLRDNORM | POLLERR | POLLPRI; } -@@ -1799,7 +1799,7 @@ static int swaps_open(struct inode *inod +@@ -1799,7 +1799,7 @@ static int swaps_open(struct inode *inode, struct file *file) } s->seq.private = s; @@ -71198,7 +72523,7 @@ diff -urNp linux-3.0.9/mm/swapfile.c linux-3.0.9/mm/swapfile.c return ret; } -@@ -2133,7 +2133,7 @@ SYSCALL_DEFINE2(swapon, const char __use +@@ -2133,7 +2133,7 @@ SYSCALL_DEFINE2(swapon, const char __user *, specialfile, int, swap_flags) (p->flags & SWP_DISCARDABLE) ? "D" : ""); mutex_unlock(&swapon_mutex); @@ -71207,9 +72532,10 @@ diff -urNp linux-3.0.9/mm/swapfile.c linux-3.0.9/mm/swapfile.c wake_up_interruptible(&proc_poll_wait); if (S_ISREG(inode->i_mode)) -diff -urNp linux-3.0.9/mm/util.c linux-3.0.9/mm/util.c ---- linux-3.0.9/mm/util.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/util.c 2011-11-12 12:47:14.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 immediately * like, for example, with RCU. @@ -71226,7 +72552,7 @@ diff -urNp linux-3.0.9/mm/util.c linux-3.0.9/mm/util.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 vm_area_struct *vma, void arch_pick_mmap_layout(struct mm_struct *mm) { mm->mmap_base = TASK_UNMAPPED_BASE; @@ -71239,10 +72565,11 @@ diff -urNp linux-3.0.9/mm/util.c linux-3.0.9/mm/util.c mm->get_unmapped_area = arch_get_unmapped_area; mm->unmap_area = arch_unmap_area; } -diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c ---- linux-3.0.9/mm/vmalloc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/vmalloc.c 2011-11-12 13:03:49.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 65d5fd2..4f14696 100644 +--- a/mm/vmalloc.c ++++ b/mm/vmalloc.c +@@ -39,8 +39,19 @@ static void vunmap_pte_range(pmd_t *pmd, unsigned long addr, unsigned long end) pte = pte_offset_kernel(pmd, addr); do { @@ -71264,7 +72591,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c } while (pte++, addr += PAGE_SIZE, addr != end); } -@@ -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 addr, unsigned long end, pgprot_t prot, struct page **pages, int *nr) { pte_t *pte; @@ -71272,7 +72599,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c /* * 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 long addr, pte = pte_alloc_kernel(pmd, addr); if (!pte) return -ENOMEM; @@ -71308,7 +72635,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c } 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. */ @@ -71330,7 +72657,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c return is_vmalloc_addr(x); } -@@ -216,8 +250,14 @@ struct page *vmalloc_to_page(const void +@@ -216,8 +250,14 @@ struct page *vmalloc_to_page(const void *vmalloc_addr) if (!pgd_none(*pgd)) { pud_t *pud = pud_offset(pgd, addr); @@ -71345,7 +72672,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c if (!pmd_none(*pmd)) { pte_t *ptep, pte; -@@ -1308,6 +1348,16 @@ static struct vm_struct *__get_vm_area_n +@@ -1308,6 +1348,16 @@ static struct vm_struct *__get_vm_area_node(unsigned long size, struct vm_struct *area; BUG_ON(in_interrupt()); @@ -71362,7 +72689,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c if (flags & VM_IOREMAP) { int bit = fls(size); -@@ -1540,6 +1590,11 @@ void *vmap(struct page **pages, unsigned +@@ -1540,6 +1590,11 @@ void *vmap(struct page **pages, unsigned int count, if (count > totalram_pages) return NULL; @@ -71374,13 +72701,13 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c area = get_vm_area_caller((count << PAGE_SHIFT), flags, __builtin_return_address(0)); if (!area) -@@ -1641,6 +1696,13 @@ void *__vmalloc_node_range(unsigned long +@@ -1641,6 +1696,13 @@ void *__vmalloc_node_range(unsigned long size, unsigned long align, if (!size || (size >> PAGE_SHIFT) > totalram_pages) return NULL; +#if defined(CONFIG_MODULES) && defined(CONFIG_X86) && defined(CONFIG_PAX_KERNEXEC) + if (!(pgprot_val(prot) & _PAGE_NX)) -+ area = __get_vm_area_node(size, align, VM_ALLOC | VM_KERNEXEC, VMALLOC_START, VMALLOC_END, ++ area = __get_vm_area_node(size, align, VM_ALLOC | VM_UNLIST | VM_KERNEXEC, VMALLOC_START, VMALLOC_END, + node, gfp_mask, caller); + else +#endif @@ -71388,7 +72715,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c area = __get_vm_area_node(size, align, VM_ALLOC | VM_UNLIST, start, end, node, gfp_mask, caller); -@@ -1686,6 +1748,7 @@ static void *__vmalloc_node(unsigned lon +@@ -1686,6 +1748,7 @@ static void *__vmalloc_node(unsigned long size, unsigned long align, gfp_mask, prot, node, caller); } @@ -71396,7 +72723,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c void *__vmalloc(unsigned long size, gfp_t gfp_mask, pgprot_t prot) { return __vmalloc_node(size, 1, gfp_mask, prot, -1, -@@ -1709,6 +1772,7 @@ static inline void *__vmalloc_node_flags +@@ -1709,6 +1772,7 @@ static inline void *__vmalloc_node_flags(unsigned long size, * For tight control over page level allocator and protection flags * use __vmalloc() instead. */ @@ -71465,7 +72792,7 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c void *vmalloc_32_user(unsigned long size) { struct vm_struct *area; -@@ -2105,6 +2175,8 @@ int remap_vmalloc_range(struct vm_area_s +@@ -2105,6 +2175,8 @@ int remap_vmalloc_range(struct vm_area_struct *vma, void *addr, unsigned long uaddr = vma->vm_start; unsigned long usize = vma->vm_end - vma->vm_start; @@ -71474,9 +72801,10 @@ diff -urNp linux-3.0.9/mm/vmalloc.c linux-3.0.9/mm/vmalloc.c if ((PAGE_SIZE-1) & (unsigned long)addr) return -EINVAL; -diff -urNp linux-3.0.9/mm/vmstat.c linux-3.0.9/mm/vmstat.c ---- linux-3.0.9/mm/vmstat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/mm/vmstat.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/mm/vmstat.c b/mm/vmstat.c +index 20c18b7..f6eb92a 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 @@ -71529,10 +72857,11 @@ diff -urNp linux-3.0.9/mm/vmstat.c linux-3.0.9/mm/vmstat.c #endif return 0; } -diff -urNp linux-3.0.9/net/8021q/vlan.c linux-3.0.9/net/8021q/vlan.c ---- linux-3.0.9/net/8021q/vlan.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/8021q/vlan.c 2011-11-12 12:47:14.000000000 -0500 -@@ -591,8 +591,7 @@ static int vlan_ioctl_handler(struct net +diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c +index 917ecb9..b0eeef8 100644 +--- a/net/8021q/vlan.c ++++ b/net/8021q/vlan.c +@@ -591,8 +591,7 @@ static int vlan_ioctl_handler(struct net *net, void __user *arg) err = -EPERM; if (!capable(CAP_NET_ADMIN)) break; @@ -71542,10 +72871,11 @@ diff -urNp linux-3.0.9/net/8021q/vlan.c linux-3.0.9/net/8021q/vlan.c struct vlan_net *vn; vn = net_generic(net, vlan_net_id); -diff -urNp linux-3.0.9/net/9p/trans_fd.c linux-3.0.9/net/9p/trans_fd.c ---- linux-3.0.9/net/9p/trans_fd.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/9p/trans_fd.c 2011-11-12 12:47:14.000000000 -0500 -@@ -423,7 +423,7 @@ static int p9_fd_write(struct p9_client +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, void *v, int len) oldfs = get_fs(); set_fs(get_ds()); /* The cast to a user pointer is valid due to the set_fs() */ @@ -71554,9 +72884,10 @@ diff -urNp linux-3.0.9/net/9p/trans_fd.c linux-3.0.9/net/9p/trans_fd.c set_fs(oldfs); if (ret <= 0 && ret != -ERESTARTSYS && ret != -EAGAIN) -diff -urNp linux-3.0.9/net/9p/trans_virtio.c linux-3.0.9/net/9p/trans_virtio.c ---- linux-3.0.9/net/9p/trans_virtio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/9p/trans_virtio.c 2011-11-12 12:47:14.000000000 -0500 +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; @@ -71575,10 +72906,11 @@ diff -urNp linux-3.0.9/net/9p/trans_virtio.c linux-3.0.9/net/9p/trans_virtio.c else pbuf = req->tc->pkbuf; -diff -urNp linux-3.0.9/net/atm/atm_misc.c linux-3.0.9/net/atm/atm_misc.c ---- linux-3.0.9/net/atm/atm_misc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/atm/atm_misc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -17,7 +17,7 @@ int atm_charge(struct atm_vcc *vcc, int +diff --git a/net/atm/atm_misc.c b/net/atm/atm_misc.c +index fc63526..7777a58 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) <= sk_atm(vcc)->sk_rcvbuf) return 1; atm_return(vcc, truesize); @@ -71587,7 +72919,7 @@ diff -urNp linux-3.0.9/net/atm/atm_misc.c linux-3.0.9/net/atm/atm_misc.c return 0; } EXPORT_SYMBOL(atm_charge); -@@ -39,7 +39,7 @@ struct sk_buff *atm_alloc_charge(struct +@@ -39,7 +39,7 @@ struct sk_buff *atm_alloc_charge(struct atm_vcc *vcc, int pdu_size, } } atm_return(vcc, guess); @@ -71614,9 +72946,10 @@ diff -urNp linux-3.0.9/net/atm/atm_misc.c linux-3.0.9/net/atm/atm_misc.c __SONET_ITEMS #undef __HANDLE_ITEM } -diff -urNp linux-3.0.9/net/atm/lec.h linux-3.0.9/net/atm/lec.h ---- linux-3.0.9/net/atm/lec.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/atm/lec.h 2011-11-12 12:47:14.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_addr, @@ -71626,9 +72959,10 @@ diff -urNp linux-3.0.9/net/atm/lec.h linux-3.0.9/net/atm/lec.h /* * ATM LAN Emulation supports both LLC & Dix Ethernet EtherType -diff -urNp linux-3.0.9/net/atm/mpc.h linux-3.0.9/net/atm/mpc.h ---- linux-3.0.9/net/atm/mpc.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/atm/mpc.h 2011-11-12 12:47:14.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 */ @@ -71638,10 +72972,11 @@ diff -urNp linux-3.0.9/net/atm/mpc.h linux-3.0.9/net/atm/mpc.h }; -diff -urNp linux-3.0.9/net/atm/mpoa_caches.c linux-3.0.9/net/atm/mpoa_caches.c ---- linux-3.0.9/net/atm/mpoa_caches.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/atm/mpoa_caches.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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_client *client) struct timeval now; struct k_message msg; @@ -71650,10 +72985,11 @@ diff -urNp linux-3.0.9/net/atm/mpoa_caches.c linux-3.0.9/net/atm/mpoa_caches.c do_gettimeofday(&now); read_lock_bh(&client->ingress_lock); -diff -urNp linux-3.0.9/net/atm/proc.c linux-3.0.9/net/atm/proc.c ---- linux-3.0.9/net/atm/proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/atm/proc.c 2011-11-12 12:47:14.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 be3afde..ec5e87e 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, @@ -71666,9 +73002,10 @@ diff -urNp linux-3.0.9/net/atm/proc.c linux-3.0.9/net/atm/proc.c } static void atm_dev_info(struct seq_file *seq, const struct atm_dev *dev) -diff -urNp linux-3.0.9/net/atm/resources.c linux-3.0.9/net/atm/resources.c ---- linux-3.0.9/net/atm/resources.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/atm/resources.c 2011-11-12 12:47:14.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) @@ -71678,7 +73015,7 @@ diff -urNp linux-3.0.9/net/atm/resources.c linux-3.0.9/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 *from, static void subtract_aal_stats(struct k_atm_aal_stats *from, struct atm_aal_stats *to) { @@ -71687,10 +73024,11 @@ diff -urNp linux-3.0.9/net/atm/resources.c linux-3.0.9/net/atm/resources.c __AAL_STAT_ITEMS #undef __HANDLE_ITEM } -diff -urNp linux-3.0.9/net/batman-adv/hard-interface.c linux-3.0.9/net/batman-adv/hard-interface.c ---- linux-3.0.9/net/batman-adv/hard-interface.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/batman-adv/hard-interface.c 2011-11-12 12:47:14.000000000 -0500 -@@ -351,8 +351,8 @@ int hardif_enable_interface(struct hard_ +diff --git a/net/batman-adv/hard-interface.c b/net/batman-adv/hard-interface.c +index dfbfccc..9588715 100644 +--- a/net/batman-adv/hard-interface.c ++++ b/net/batman-adv/hard-interface.c +@@ -351,8 +351,8 @@ int hardif_enable_interface(struct hard_iface *hard_iface, char *iface_name) hard_iface->batman_adv_ptype.dev = hard_iface->net_dev; dev_add_pack(&hard_iface->batman_adv_ptype); @@ -71701,10 +73039,11 @@ diff -urNp linux-3.0.9/net/batman-adv/hard-interface.c linux-3.0.9/net/batman-ad bat_info(hard_iface->soft_iface, "Adding interface: %s\n", hard_iface->net_dev->name); -diff -urNp linux-3.0.9/net/batman-adv/routing.c linux-3.0.9/net/batman-adv/routing.c ---- linux-3.0.9/net/batman-adv/routing.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/batman-adv/routing.c 2011-11-12 12:47:14.000000000 -0500 -@@ -627,7 +627,7 @@ void receive_bat_packet(struct ethhdr *e +diff --git a/net/batman-adv/routing.c b/net/batman-adv/routing.c +index bb1c3ec..e279654 100644 +--- a/net/batman-adv/routing.c ++++ b/net/batman-adv/routing.c +@@ -627,7 +627,7 @@ void receive_bat_packet(struct ethhdr *ethhdr, return; /* could be changed by schedule_own_packet() */ @@ -71713,10 +73052,11 @@ diff -urNp linux-3.0.9/net/batman-adv/routing.c linux-3.0.9/net/batman-adv/routi has_directlink_flag = (batman_packet->flags & DIRECTLINK ? 1 : 0); -diff -urNp linux-3.0.9/net/batman-adv/send.c linux-3.0.9/net/batman-adv/send.c ---- linux-3.0.9/net/batman-adv/send.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/batman-adv/send.c 2011-11-12 12:47:14.000000000 -0500 -@@ -279,7 +279,7 @@ void schedule_own_packet(struct hard_ifa +diff --git a/net/batman-adv/send.c b/net/batman-adv/send.c +index 3377927..96f64f1 100644 +--- a/net/batman-adv/send.c ++++ b/net/batman-adv/send.c +@@ -279,7 +279,7 @@ void schedule_own_packet(struct hard_iface *hard_iface) /* change sequence number to network order */ batman_packet->seqno = @@ -71725,7 +73065,7 @@ diff -urNp linux-3.0.9/net/batman-adv/send.c linux-3.0.9/net/batman-adv/send.c if (vis_server == VIS_TYPE_SERVER_SYNC) batman_packet->flags |= VIS_SERVER; -@@ -293,7 +293,7 @@ void schedule_own_packet(struct hard_ifa +@@ -293,7 +293,7 @@ void schedule_own_packet(struct hard_iface *hard_iface) else batman_packet->gw_flags = 0; @@ -71734,10 +73074,11 @@ diff -urNp linux-3.0.9/net/batman-adv/send.c linux-3.0.9/net/batman-adv/send.c slide_own_bcast_window(hard_iface); send_time = own_send_time(bat_priv); -diff -urNp linux-3.0.9/net/batman-adv/soft-interface.c linux-3.0.9/net/batman-adv/soft-interface.c ---- linux-3.0.9/net/batman-adv/soft-interface.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/batman-adv/soft-interface.c 2011-11-12 12:47:14.000000000 -0500 -@@ -628,7 +628,7 @@ int interface_tx(struct sk_buff *skb, st +diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-interface.c +index d5aa609..8b4df33 100644 +--- a/net/batman-adv/soft-interface.c ++++ b/net/batman-adv/soft-interface.c +@@ -628,7 +628,7 @@ int interface_tx(struct sk_buff *skb, struct net_device *soft_iface) /* set broadcast sequence number */ bcast_packet->seqno = @@ -71746,7 +73087,7 @@ diff -urNp linux-3.0.9/net/batman-adv/soft-interface.c linux-3.0.9/net/batman-ad add_bcast_packet_to_list(bat_priv, skb); -@@ -830,7 +830,7 @@ struct net_device *softif_create(char *n +@@ -830,7 +830,7 @@ struct net_device *softif_create(char *name) atomic_set(&bat_priv->batman_queue_left, BATMAN_QUEUE_LEN); atomic_set(&bat_priv->mesh_state, MESH_INACTIVE); @@ -71755,9 +73096,10 @@ diff -urNp linux-3.0.9/net/batman-adv/soft-interface.c linux-3.0.9/net/batman-ad atomic_set(&bat_priv->tt_local_changed, 0); bat_priv->primary_if = NULL; -diff -urNp linux-3.0.9/net/batman-adv/types.h linux-3.0.9/net/batman-adv/types.h ---- linux-3.0.9/net/batman-adv/types.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/batman-adv/types.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/batman-adv/types.h b/net/batman-adv/types.h +index fab70e8..f8c9be3 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; @@ -71778,10 +73120,11 @@ diff -urNp linux-3.0.9/net/batman-adv/types.h linux-3.0.9/net/batman-adv/types.h atomic_t bcast_queue_left; atomic_t batman_queue_left; char num_ifaces; -diff -urNp linux-3.0.9/net/batman-adv/unicast.c linux-3.0.9/net/batman-adv/unicast.c ---- linux-3.0.9/net/batman-adv/unicast.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/batman-adv/unicast.c 2011-11-12 12:47:14.000000000 -0500 -@@ -265,7 +265,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 19c3daf..254d326 100644 +--- a/net/batman-adv/unicast.c ++++ b/net/batman-adv/unicast.c +@@ -265,7 +265,7 @@ int frag_send_skb(struct sk_buff *skb, struct bat_priv *bat_priv, frag1->flags = UNI_FRAG_HEAD | large_tail; frag2->flags = large_tail; @@ -71790,10 +73133,11 @@ diff -urNp linux-3.0.9/net/batman-adv/unicast.c linux-3.0.9/net/batman-adv/unica frag1->seqno = htons(seqno - 1); frag2->seqno = htons(seqno); -diff -urNp linux-3.0.9/net/bridge/br_multicast.c linux-3.0.9/net/bridge/br_multicast.c ---- linux-3.0.9/net/bridge/br_multicast.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/bridge/br_multicast.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1485,7 +1485,7 @@ static int br_multicast_ipv6_rcv(struct +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 = ip6h->nexthdr; offset = ipv6_skip_exthdr(skb, sizeof(*ip6h), &nexthdr); @@ -71802,10 +73146,11 @@ diff -urNp linux-3.0.9/net/bridge/br_multicast.c linux-3.0.9/net/bridge/br_multi return 0; /* Okay, we found ICMPv6 header */ -diff -urNp linux-3.0.9/net/bridge/netfilter/ebtables.c linux-3.0.9/net/bridge/netfilter/ebtables.c ---- linux-3.0.9/net/bridge/netfilter/ebtables.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/bridge/netfilter/ebtables.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1512,7 +1512,7 @@ static int do_ebt_get_ctl(struct sock *s +diff --git a/net/bridge/netfilter/ebtables.c b/net/bridge/netfilter/ebtables.c +index 2b5ca1a..fab7122 100644 +--- a/net/bridge/netfilter/ebtables.c ++++ b/net/bridge/netfilter/ebtables.c +@@ -1512,7 +1512,7 @@ static int do_ebt_get_ctl(struct sock *sk, int cmd, void __user *user, int *len) tmp.valid_hooks = t->table->valid_hooks; } mutex_unlock(&ebt_mutex); @@ -71814,7 +73159,7 @@ diff -urNp linux-3.0.9/net/bridge/netfilter/ebtables.c linux-3.0.9/net/bridge/ne BUGPRINT("c2u Didn't work\n"); ret = -EFAULT; break; -@@ -1780,6 +1780,8 @@ static int compat_copy_everything_to_use +@@ -1780,6 +1780,8 @@ static int compat_copy_everything_to_user(struct ebt_table *t, int ret; void __user *pos; @@ -71823,9 +73168,10 @@ diff -urNp linux-3.0.9/net/bridge/netfilter/ebtables.c linux-3.0.9/net/bridge/ne memset(&tinfo, 0, sizeof(tinfo)); if (cmd == EBT_SO_GET_ENTRIES) { -diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c ---- linux-3.0.9/net/caif/caif_socket.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/caif/caif_socket.c 2011-11-12 12:47:14.000000000 -0500 +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 { @@ -71857,7 +73203,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/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, struct sk_buff *skb) atomic_read(&cf_sk->sk.sk_rmem_alloc), sk_rcvbuf_lowwater(cf_sk)); set_rx_flow_off(cf_sk); @@ -71866,7 +73212,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c caif_flow_ctrl(sk, CAIF_MODEMCMD_FLOW_OFF_REQ); } -@@ -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, struct sk_buff *skb) set_rx_flow_off(cf_sk); if (net_ratelimit()) pr_debug("sending flow OFF due to rmem_schedule\n"); @@ -71875,7 +73221,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c caif_flow_ctrl(sk, CAIF_MODEMCMD_FLOW_OFF_REQ); } skb->dev = NULL; -@@ -233,14 +234,14 @@ static void caif_ctrl_cb(struct cflayer +@@ -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 */ @@ -71892,7 +73238,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/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 +@@ -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); @@ -71901,7 +73247,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c cf_sk->sk.sk_state = 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 +@@ -263,7 +264,7 @@ static void caif_ctrl_cb(struct cflayer *layr, case CAIF_CTRLCMD_INIT_FAIL_RSP: /* Connect request failed */ @@ -71910,7 +73256,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c cf_sk->sk.sk_err = ECONNREFUSED; cf_sk->sk.sk_state = CAIF_DISCONNECTED; cf_sk->sk.sk_shutdown = SHUTDOWN_MASK; -@@ -277,7 +278,7 @@ static void caif_ctrl_cb(struct cflayer +@@ -277,7 +278,7 @@ static void caif_ctrl_cb(struct cflayer *layr, case CAIF_CTRLCMD_REMOTE_SHUTDOWN_IND: /* Modem has closed this connection, or device is down. */ @@ -71919,7 +73265,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c cf_sk->sk.sk_shutdown = SHUTDOWN_MASK; cf_sk->sk.sk_err = 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; if (atomic_read(&sk->sk_rmem_alloc) <= sk_rcvbuf_lowwater(cf_sk)) { @@ -71928,7 +73274,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/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 = id of the interface.*/ cf_sk->conn_req.ifindex = cf_sk->sk.sk_bound_dev_if; @@ -71937,7 +73283,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c cf_sk->layer.receive = caif_sktrecv_cb; err = 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 = NULL; @@ -71946,7 +73292,7 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c WARN_ON(IS_ERR(cf_sk->debugfs_socket_dir)); if (cf_sk->debugfs_socket_dir != NULL) -@@ -1122,7 +1123,7 @@ static int caif_create(struct net *net, +@@ -1122,7 +1123,7 @@ static int caif_create(struct net *net, struct socket *sock, int protocol, cf_sk->conn_req.protocol = protocol; /* Increase the number of sockets created. */ dbfs_atomic_inc(&cnt.caif_nr_socks); @@ -71955,9 +73301,10 @@ diff -urNp linux-3.0.9/net/caif/caif_socket.c linux-3.0.9/net/caif/caif_socket.c #ifdef CONFIG_DEBUG_FS if (!IS_ERR(debugfsdir)) { -diff -urNp linux-3.0.9/net/caif/cfctrl.c linux-3.0.9/net/caif/cfctrl.c ---- linux-3.0.9/net/caif/cfctrl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/caif/cfctrl.c 2011-11-12 12:47:14.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 <linux/stddef.h> #include <linux/spinlock.h> @@ -71977,7 +73324,7 @@ diff -urNp linux-3.0.9/net/caif/cfctrl.c linux-3.0.9/net/caif/cfctrl.c this->serv.layer.receive = cfctrl_recv; sprintf(this->serv.layer.name, "ctrl"); this->serv.layer.ctrlcmd = 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); @@ -71988,7 +73335,7 @@ diff -urNp linux-3.0.9/net/caif/cfctrl.c linux-3.0.9/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 != first) pr_warn("Requests are not received in order\n"); @@ -71997,7 +73344,7 @@ diff -urNp linux-3.0.9/net/caif/cfctrl.c linux-3.0.9/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 = container_obj(layer); struct cfctrl_request_info rsp, *req; @@ -72005,10 +73352,11 @@ diff -urNp linux-3.0.9/net/caif/cfctrl.c linux-3.0.9/net/caif/cfctrl.c cfpkt_extr_head(pkt, &cmdrsp, 1); cmd = cmdrsp & CFCTRL_CMD_MASK; -diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c ---- linux-3.0.9/net/compat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/compat.c 2011-11-12 12:47:14.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 compat_msghdr __user *umsg) __get_user(kmsg->msg_controllen, &umsg->msg_controllen) || __get_user(kmsg->msg_flags, &umsg->msg_flags)) return -EFAULT; @@ -72021,7 +73369,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c return 0; } -@@ -84,7 +84,7 @@ int verify_compat_iovec(struct msghdr *k +@@ -84,7 +84,7 @@ int verify_compat_iovec(struct msghdr *kern_msg, struct iovec *kern_iov, if (kern_msg->msg_namelen) { if (mode == VERIFY_READ) { @@ -72030,7 +73378,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/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, struct iovec *kern_iov, kern_msg->msg_name = NULL; tot_len = iov_from_user_compat_to_kern(kern_iov, @@ -72039,7 +73387,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c kern_msg->msg_iovlen); if (tot_len >= 0) kern_msg->msg_iov = 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, struct iovec *kern_iov, #define CMSG_COMPAT_FIRSTHDR(msg) \ (((msg)->msg_controllen) >= sizeof(struct compat_cmsghdr) ? \ @@ -72063,7 +73411,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/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]; @@ -72072,7 +73420,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c struct compat_cmsghdr cmhdr; int cmlen; -@@ -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 void scm_detach_fds_compat(struct msghdr *kmsg, struct scm_cookie *scm) { @@ -72081,7 +73429,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c int fdmax = (kmsg->msg_controllen - sizeof(struct compat_cmsghdr)) / sizeof(int); int fdnum = scm->fp->count; struct file **fp = 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 = get_fs(); set_fs(KERNEL_DS); @@ -72090,7 +73438,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c set_fs(old_fs); 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 = sizeof(ktime); old_fs = get_fs(); set_fs(KERNEL_DS); @@ -72099,7 +73447,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c set_fs(old_fs); 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 level, int optname, case MCAST_JOIN_GROUP: case MCAST_LEAVE_GROUP: { @@ -72108,7 +73456,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c struct group_req __user *kgr = 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 level, int optname, case MCAST_BLOCK_SOURCE: case MCAST_UNBLOCK_SOURCE: { @@ -72117,7 +73465,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c struct group_source_req __user *kgsr = 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 level, int optname, } case MCAST_MSFILTER: { @@ -72126,7 +73474,7 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c struct group_filter __user *kgf; u32 interface, fmode, numsrc; -@@ -645,7 +645,7 @@ int compat_mc_getsockopt(struct sock *so +@@ -645,7 +645,7 @@ int compat_mc_getsockopt(struct sock *sock, int level, int optname, char __user *optval, int __user *optlen, int (*getsockopt)(struct sock *, int, int, char __user *, int __user *)) { @@ -72135,10 +73483,11 @@ diff -urNp linux-3.0.9/net/compat.c linux-3.0.9/net/compat.c struct group_filter __user *kgf; int __user *koptlen; u32 interface, fmode, numsrc; -diff -urNp linux-3.0.9/net/core/datagram.c linux-3.0.9/net/core/datagram.c ---- linux-3.0.9/net/core/datagram.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/datagram.c 2011-11-12 12:47:14.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_buff *skb, unsigned int flags) } kfree_skb(skb); @@ -72147,10 +73496,11 @@ diff -urNp linux-3.0.9/net/core/datagram.c linux-3.0.9/net/core/datagram.c sk_mem_reclaim_partial(sk); return err; -diff -urNp linux-3.0.9/net/core/dev.c linux-3.0.9/net/core/dev.c ---- linux-3.0.9/net/core/dev.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/dev.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1125,10 +1125,14 @@ void dev_load(struct net *net, const cha +diff --git a/net/core/dev.c b/net/core/dev.c +index f14f601..4641d8b 100644 +--- a/net/core/dev.c ++++ b/net/core/dev.c +@@ -1125,10 +1125,14 @@ void dev_load(struct net *net, const char *name) if (no_module && capable(CAP_NET_ADMIN)) no_module = request_module("netdev-%s", name); if (no_module && capable(CAP_SYS_MODULE)) { @@ -72165,7 +73515,7 @@ diff -urNp linux-3.0.9/net/core/dev.c linux-3.0.9/net/core/dev.c } } EXPORT_SYMBOL(dev_load); -@@ -1959,7 +1963,7 @@ static int illegal_highdma(struct net_de +@@ -1959,7 +1963,7 @@ static int illegal_highdma(struct net_device *dev, struct sk_buff *skb) struct dev_gso_cb { void (*destructor)(struct sk_buff *skb); @@ -72183,7 +73533,7 @@ diff -urNp linux-3.0.9/net/core/dev.c linux-3.0.9/net/core/dev.c { struct softnet_data *sd = &__get_cpu_var(softnet_data); -@@ -3761,7 +3765,7 @@ void netif_napi_del(struct napi_struct * +@@ -3761,7 +3765,7 @@ void netif_napi_del(struct napi_struct *napi) } EXPORT_SYMBOL(netif_napi_del); @@ -72192,9 +73542,10 @@ diff -urNp linux-3.0.9/net/core/dev.c linux-3.0.9/net/core/dev.c { struct softnet_data *sd = &__get_cpu_var(softnet_data); unsigned long time_limit = jiffies + 2; -diff -urNp linux-3.0.9/net/core/flow.c linux-3.0.9/net/core/flow.c ---- linux-3.0.9/net/core/flow.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/flow.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/core/flow.c b/net/core/flow.c +index a6bda2a..0829c68 100644 +--- a/net/core/flow.c ++++ b/net/core/flow.c @@ -60,7 +60,7 @@ struct flow_cache { struct timer_list rnd_timer; }; @@ -72204,7 +73555,7 @@ diff -urNp linux-3.0.9/net/core/flow.c linux-3.0.9/net/core/flow.c EXPORT_SYMBOL(flow_cache_genid); static struct flow_cache flow_cache_global; static struct kmem_cache *flow_cachep __read_mostly; -@@ -85,7 +85,7 @@ static void flow_cache_new_hashrnd(unsig +@@ -85,7 +85,7 @@ static void flow_cache_new_hashrnd(unsigned long arg) static int flow_entry_valid(struct flow_cache_entry *fle) { @@ -72213,7 +73564,7 @@ diff -urNp linux-3.0.9/net/core/flow.c linux-3.0.9/net/core/flow.c return 0; if (fle->object && !fle->object->ops->check(fle->object)) return 0; -@@ -256,7 +256,7 @@ flow_cache_lookup(struct net *net, const +@@ -256,7 +256,7 @@ flow_cache_lookup(struct net *net, const struct flowi *key, u16 family, u8 dir, hlist_add_head(&fle->u.hlist, &fcp->hash_table[hash]); fcp->hash_count++; } @@ -72231,10 +73582,11 @@ diff -urNp linux-3.0.9/net/core/flow.c linux-3.0.9/net/core/flow.c if (!IS_ERR(flo)) fle->object = flo; else -diff -urNp linux-3.0.9/net/core/iovec.c linux-3.0.9/net/core/iovec.c ---- linux-3.0.9/net/core/iovec.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/iovec.c 2011-11-12 12:47:14.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 == VERIFY_READ) { void __user *namep; @@ -72243,7 +73595,7 @@ diff -urNp linux-3.0.9/net/core/iovec.c linux-3.0.9/net/core/iovec.c err = 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, } size = m->msg_iovlen * sizeof(struct iovec); @@ -72252,9 +73604,10 @@ diff -urNp linux-3.0.9/net/core/iovec.c linux-3.0.9/net/core/iovec.c return -EFAULT; m->msg_iov = iov; -diff -urNp linux-3.0.9/net/core/rtnetlink.c linux-3.0.9/net/core/rtnetlink.c ---- linux-3.0.9/net/core/rtnetlink.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/rtnetlink.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c +index abd936d..c31a426 100644 +--- a/net/core/rtnetlink.c ++++ b/net/core/rtnetlink.c @@ -56,7 +56,7 @@ struct rtnl_link { rtnl_doit_func doit; @@ -72264,9 +73617,10 @@ diff -urNp linux-3.0.9/net/core/rtnetlink.c linux-3.0.9/net/core/rtnetlink.c static DEFINE_MUTEX(rtnl_mutex); -diff -urNp linux-3.0.9/net/core/scm.c linux-3.0.9/net/core/scm.c ---- linux-3.0.9/net/core/scm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/scm.c 2011-11-12 12:47:14.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 *data) { @@ -72276,7 +73630,7 @@ diff -urNp linux-3.0.9/net/core/scm.c linux-3.0.9/net/core/scm.c struct cmsghdr cmhdr; int cmlen = 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 type, int len, void *data) err = -EFAULT; if (copy_to_user(cm, &cmhdr, sizeof cmhdr)) goto out; @@ -72294,7 +73648,7 @@ diff -urNp linux-3.0.9/net/core/scm.c linux-3.0.9/net/core/scm.c int fdmax = 0; int fdnum = scm->fp->count; -@@ -277,7 +277,7 @@ void scm_detach_fds(struct msghdr *msg, +@@ -277,7 +277,7 @@ void scm_detach_fds(struct msghdr *msg, struct scm_cookie *scm) if (fdnum < fdmax) fdmax = fdnum; @@ -72303,10 +73657,11 @@ diff -urNp linux-3.0.9/net/core/scm.c linux-3.0.9/net/core/scm.c i++, cmfptr++) { int new_fd; -diff -urNp linux-3.0.9/net/core/skbuff.c linux-3.0.9/net/core/skbuff.c ---- linux-3.0.9/net/core/skbuff.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/skbuff.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1543,6 +1543,8 @@ int skb_splice_bits(struct sk_buff *skb, +diff --git a/net/core/skbuff.c b/net/core/skbuff.c +index 46cbd28..f5ce81a 100644 +--- a/net/core/skbuff.c ++++ b/net/core/skbuff.c +@@ -1543,6 +1543,8 @@ int skb_splice_bits(struct sk_buff *skb, unsigned int offset, struct sock *sk = skb->sk; int ret = 0; @@ -72315,10 +73670,11 @@ diff -urNp linux-3.0.9/net/core/skbuff.c linux-3.0.9/net/core/skbuff.c if (splice_grow_spd(pipe, &spd)) return -ENOMEM; -diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c ---- linux-3.0.9/net/core/sock.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/core/sock.c 2011-11-12 12:47:14.000000000 -0500 -@@ -291,7 +291,7 @@ int sock_queue_rcv_skb(struct sock *sk, +diff --git a/net/core/sock.c b/net/core/sock.c +index aebb419..be941ff 100644 +--- a/net/core/sock.c ++++ b/net/core/sock.c +@@ -291,7 +291,7 @@ int sock_queue_rcv_skb(struct sock *sk, struct sk_buff *skb) */ if (atomic_read(&sk->sk_rmem_alloc) + skb->truesize >= (unsigned)sk->sk_rcvbuf) { @@ -72327,7 +73683,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c return -ENOMEM; } -@@ -300,7 +300,7 @@ int sock_queue_rcv_skb(struct sock *sk, +@@ -300,7 +300,7 @@ int sock_queue_rcv_skb(struct sock *sk, struct sk_buff *skb) return err; if (!sk_rmem_schedule(sk, skb->truesize)) { @@ -72336,7 +73692,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c return -ENOBUFS; } -@@ -320,7 +320,7 @@ int sock_queue_rcv_skb(struct sock *sk, +@@ -320,7 +320,7 @@ int sock_queue_rcv_skb(struct sock *sk, struct sk_buff *skb) skb_dst_force(skb); spin_lock_irqsave(&list->lock, flags); @@ -72345,7 +73701,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c __skb_queue_tail(list, skb); spin_unlock_irqrestore(&list->lock, flags); -@@ -340,7 +340,7 @@ int sk_receive_skb(struct sock *sk, stru +@@ -340,7 +340,7 @@ int sk_receive_skb(struct sock *sk, struct sk_buff *skb, const int nested) skb->dev = NULL; if (sk_rcvqueues_full(sk, skb)) { @@ -72354,7 +73710,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c goto discard_and_relse; } if (nested) -@@ -358,7 +358,7 @@ int sk_receive_skb(struct sock *sk, stru +@@ -358,7 +358,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); @@ -72363,7 +73719,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c goto discard_and_relse; } -@@ -921,7 +921,7 @@ int sock_getsockopt(struct socket *sock, +@@ -921,7 +921,7 @@ int sock_getsockopt(struct socket *sock, int level, int optname, if (len > sizeof(peercred)) len = sizeof(peercred); cred_to_ucred(sk->sk_peer_pid, sk->sk_peer_cred, &peercred); @@ -72372,7 +73728,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c return -EFAULT; goto lenout; } -@@ -934,7 +934,7 @@ int sock_getsockopt(struct socket *sock, +@@ -934,7 +934,7 @@ int sock_getsockopt(struct socket *sock, int level, int optname, return -ENOTCONN; if (lv < len) return -EINVAL; @@ -72381,7 +73737,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c return -EFAULT; goto lenout; } -@@ -967,7 +967,7 @@ int sock_getsockopt(struct socket *sock, +@@ -967,7 +967,7 @@ int sock_getsockopt(struct socket *sock, int level, int optname, if (len > lv) len = lv; @@ -72390,7 +73746,7 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c return -EFAULT; lenout: if (put_user(len, optlen)) -@@ -2024,7 +2024,7 @@ void sock_init_data(struct socket *sock, +@@ -2024,7 +2024,7 @@ void sock_init_data(struct socket *sock, struct sock *sk) */ smp_wmb(); atomic_set(&sk->sk_refcnt, 1); @@ -72399,10 +73755,11 @@ diff -urNp linux-3.0.9/net/core/sock.c linux-3.0.9/net/core/sock.c } EXPORT_SYMBOL(sock_init_data); -diff -urNp linux-3.0.9/net/decnet/sysctl_net_decnet.c linux-3.0.9/net/decnet/sysctl_net_decnet.c ---- linux-3.0.9/net/decnet/sysctl_net_decnet.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/decnet/sysctl_net_decnet.c 2011-11-12 12:47:14.000000000 -0500 -@@ -173,7 +173,7 @@ static int dn_node_address_handler(ctl_t +diff --git a/net/decnet/sysctl_net_decnet.c b/net/decnet/sysctl_net_decnet.c +index 28f8b5e..2e2c4f4 100644 +--- a/net/decnet/sysctl_net_decnet.c ++++ b/net/decnet/sysctl_net_decnet.c +@@ -173,7 +173,7 @@ static int dn_node_address_handler(ctl_table *table, int write, if (len > *lenp) len = *lenp; @@ -72411,7 +73768,7 @@ diff -urNp linux-3.0.9/net/decnet/sysctl_net_decnet.c linux-3.0.9/net/decnet/sys return -EFAULT; *lenp = len; -@@ -236,7 +236,7 @@ static int dn_def_dev_handler(ctl_table +@@ -236,7 +236,7 @@ static int dn_def_dev_handler(ctl_table *table, int write, if (len > *lenp) len = *lenp; @@ -72420,9 +73777,10 @@ diff -urNp linux-3.0.9/net/decnet/sysctl_net_decnet.c linux-3.0.9/net/decnet/sys return -EFAULT; *lenp = len; -diff -urNp linux-3.0.9/net/econet/Kconfig linux-3.0.9/net/econet/Kconfig ---- linux-3.0.9/net/econet/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/econet/Kconfig 2011-11-12 12:47:14.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 @@ config ECONET @@ -72432,10 +73790,11 @@ diff -urNp linux-3.0.9/net/econet/Kconfig linux-3.0.9/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.0.9/net/ipv4/fib_frontend.c linux-3.0.9/net/ipv4/fib_frontend.c ---- linux-3.0.9/net/ipv4/fib_frontend.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/fib_frontend.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 2252471..c176a83 100644 +--- a/net/ipv4/fib_frontend.c ++++ b/net/ipv4/fib_frontend.c +@@ -970,12 +970,12 @@ static int fib_inetaddr_event(struct notifier_block *this, unsigned long event, #ifdef CONFIG_IP_ROUTE_MULTIPATH fib_sync_up(dev); #endif @@ -72450,7 +73809,7 @@ diff -urNp linux-3.0.9/net/ipv4/fib_frontend.c linux-3.0.9/net/ipv4/fib_frontend if (ifa->ifa_dev->ifa_list == 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 @@ -72459,10 +73818,11 @@ diff -urNp linux-3.0.9/net/ipv4/fib_frontend.c linux-3.0.9/net/ipv4/fib_frontend rt_cache_flush(dev_net(dev), -1); break; case NETDEV_DOWN: -diff -urNp linux-3.0.9/net/ipv4/fib_semantics.c linux-3.0.9/net/ipv4/fib_semantics.c ---- linux-3.0.9/net/ipv4/fib_semantics.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/fib_semantics.c 2011-11-12 12:47:14.000000000 -0500 -@@ -691,7 +691,7 @@ __be32 fib_info_update_nh_saddr(struct n +diff --git a/net/ipv4/fib_semantics.c b/net/ipv4/fib_semantics.c +index 33e2c35..6b07352 100644 +--- a/net/ipv4/fib_semantics.c ++++ b/net/ipv4/fib_semantics.c +@@ -691,7 +691,7 @@ __be32 fib_info_update_nh_saddr(struct net *net, struct fib_nh *nh) nh->nh_saddr = inet_select_addr(nh->nh_dev, nh->nh_gw, nh->nh_parent->fib_scope); @@ -72471,10 +73831,11 @@ diff -urNp linux-3.0.9/net/ipv4/fib_semantics.c linux-3.0.9/net/ipv4/fib_semanti return nh->nh_saddr; } -diff -urNp linux-3.0.9/net/ipv4/inet_diag.c linux-3.0.9/net/ipv4/inet_diag.c ---- linux-3.0.9/net/ipv4/inet_diag.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/inet_diag.c 2011-11-12 12:47:14.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 3267d38..76443f1 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 = 0; r->id.idiag_if = sk->sk_bound_dev_if; @@ -72489,7 +73850,7 @@ diff -urNp linux-3.0.9/net/ipv4/inet_diag.c linux-3.0.9/net/ipv4/inet_diag.c r->id.idiag_sport = inet->inet_sport; r->id.idiag_dport = 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 = tw->tw_family; r->idiag_retrans = 0; r->id.idiag_if = tw->tw_bound_dev_if; @@ -72505,7 +73866,7 @@ diff -urNp linux-3.0.9/net/ipv4/inet_diag.c linux-3.0.9/net/ipv4/inet_diag.c r->id.idiag_sport = tw->tw_sport; r->id.idiag_dport = tw->tw_dport; r->id.idiag_src[0] = 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 == NULL) goto unlock; @@ -72520,7 +73881,7 @@ diff -urNp linux-3.0.9/net/ipv4/inet_diag.c linux-3.0.9/net/ipv4/inet_diag.c err = -ENOMEM; rep = 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 = req->retrans; r->id.idiag_if = sk->sk_bound_dev_if; @@ -72535,9 +73896,10 @@ diff -urNp linux-3.0.9/net/ipv4/inet_diag.c linux-3.0.9/net/ipv4/inet_diag.c tmo = req->expires - jiffies; if (tmo < 0) -diff -urNp linux-3.0.9/net/ipv4/inet_hashtables.c linux-3.0.9/net/ipv4/inet_hashtables.c ---- linux-3.0.9/net/ipv4/inet_hashtables.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/inet_hashtables.c 2011-11-12 12:47:14.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 <linux/sched.h> #include <linux/slab.h> @@ -72563,10 +73925,11 @@ diff -urNp linux-3.0.9/net/ipv4/inet_hashtables.c linux-3.0.9/net/ipv4/inet_hash if (tw) { inet_twsk_deschedule(tw, death_row); while (twrefcnt) { -diff -urNp linux-3.0.9/net/ipv4/inetpeer.c linux-3.0.9/net/ipv4/inetpeer.c ---- linux-3.0.9/net/ipv4/inetpeer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/inetpeer.c 2011-11-12 12:47:14.000000000 -0500 -@@ -481,6 +481,8 @@ struct inet_peer *inet_getpeer(struct in +diff --git a/net/ipv4/inetpeer.c b/net/ipv4/inetpeer.c +index 6877645..d97d6de 100644 +--- a/net/ipv4/inetpeer.c ++++ b/net/ipv4/inetpeer.c +@@ -481,6 +481,8 @@ struct inet_peer *inet_getpeer(struct inetpeer_addr *daddr, int create) unsigned int sequence; int invalidated, newrefcnt = 0; @@ -72575,7 +73938,7 @@ diff -urNp linux-3.0.9/net/ipv4/inetpeer.c linux-3.0.9/net/ipv4/inetpeer.c /* Look up for the address quickly, lockless. * Because of a concurrent writer, we might not find an existing entry. */ -@@ -517,8 +519,8 @@ found: /* The existing node has been fo +@@ -517,8 +519,8 @@ found: /* The existing node has been found. if (p) { p->daddr = *daddr; atomic_set(&p->refcnt, 1); @@ -72586,40 +73949,11 @@ diff -urNp linux-3.0.9/net/ipv4/inetpeer.c linux-3.0.9/net/ipv4/inetpeer.c p->tcp_ts_stamp = 0; p->metrics[RTAX_LOCK-1] = INETPEER_METRICS_NEW; p->rate_tokens = 0; -diff -urNp linux-3.0.9/net/ipv4/ipconfig.c linux-3.0.9/net/ipv4/ipconfig.c ---- linux-3.0.9/net/ipv4/ipconfig.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/ipconfig.c 2011-11-12 12:47:14.000000000 -0500 -@@ -313,7 +313,7 @@ static int __init ic_devinet_ioctl(unsig - - mm_segment_t oldfs = get_fs(); - set_fs(get_ds()); -- res = devinet_ioctl(&init_net, cmd, (struct ifreq __user *) arg); -+ res = devinet_ioctl(&init_net, cmd, (struct ifreq __force_user *) arg); - set_fs(oldfs); - return res; - } -@@ -324,7 +324,7 @@ static int __init ic_dev_ioctl(unsigned - - mm_segment_t oldfs = get_fs(); - set_fs(get_ds()); -- res = dev_ioctl(&init_net, cmd, (struct ifreq __user *) arg); -+ res = 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 - - mm_segment_t oldfs = get_fs(); - set_fs(get_ds()); -- res = ip_rt_ioctl(&init_net, cmd, (void __user *) arg); -+ res = ip_rt_ioctl(&init_net, cmd, (void __force_user *) arg); - set_fs(oldfs); - return res; - } -diff -urNp linux-3.0.9/net/ipv4/ip_fragment.c linux-3.0.9/net/ipv4/ip_fragment.c ---- linux-3.0.9/net/ipv4/ip_fragment.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/ip_fragment.c 2011-11-12 12:47:14.000000000 -0500 -@@ -315,7 +315,7 @@ static inline int ip_frag_too_far(struct +diff --git a/net/ipv4/ip_fragment.c b/net/ipv4/ip_fragment.c +index 0ad6035..8bc7467 100644 +--- a/net/ipv4/ip_fragment.c ++++ b/net/ipv4/ip_fragment.c +@@ -315,7 +315,7 @@ static inline int ip_frag_too_far(struct ipq *qp) return 0; start = qp->rid; @@ -72628,10 +73962,11 @@ diff -urNp linux-3.0.9/net/ipv4/ip_fragment.c linux-3.0.9/net/ipv4/ip_fragment.c qp->rid = end; rc = qp->q.fragments && (end - start) > max; -diff -urNp linux-3.0.9/net/ipv4/ip_sockglue.c linux-3.0.9/net/ipv4/ip_sockglue.c ---- linux-3.0.9/net/ipv4/ip_sockglue.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/ip_sockglue.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1073,6 +1073,8 @@ static int do_ip_getsockopt(struct sock +diff --git a/net/ipv4/ip_sockglue.c b/net/ipv4/ip_sockglue.c +index ab0c9ef..e321f44 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 level, int optname, int val; int len; @@ -72640,7 +73975,7 @@ diff -urNp linux-3.0.9/net/ipv4/ip_sockglue.c linux-3.0.9/net/ipv4/ip_sockglue.c if (level != SOL_IP) return -EOPNOTSUPP; -@@ -1110,7 +1112,8 @@ static int do_ip_getsockopt(struct sock +@@ -1110,7 +1112,8 @@ static int do_ip_getsockopt(struct sock *sk, int level, int optname, len = min_t(unsigned int, len, opt->optlen); if (put_user(len, optlen)) return -EFAULT; @@ -72650,7 +73985,7 @@ diff -urNp linux-3.0.9/net/ipv4/ip_sockglue.c linux-3.0.9/net/ipv4/ip_sockglue.c return -EFAULT; return 0; } -@@ -1238,7 +1241,7 @@ static int do_ip_getsockopt(struct sock +@@ -1238,7 +1241,7 @@ static int do_ip_getsockopt(struct sock *sk, int level, int optname, if (sk->sk_type != SOCK_STREAM) return -ENOPROTOOPT; @@ -72659,10 +73994,42 @@ diff -urNp linux-3.0.9/net/ipv4/ip_sockglue.c linux-3.0.9/net/ipv4/ip_sockglue.c msg.msg_controllen = len; msg.msg_flags = 0; -diff -urNp linux-3.0.9/net/ipv4/netfilter/nf_nat_snmp_basic.c linux-3.0.9/net/ipv4/netfilter/nf_nat_snmp_basic.c ---- linux-3.0.9/net/ipv4/netfilter/nf_nat_snmp_basic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/netfilter/nf_nat_snmp_basic.c 2011-11-12 12:47:14.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 ab7e554..d9b5ae6 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) + + mm_segment_t oldfs = get_fs(); + set_fs(get_ds()); +- res = devinet_ioctl(&init_net, cmd, (struct ifreq __user *) arg); ++ res = devinet_ioctl(&init_net, cmd, (struct ifreq __force_user *) arg); + set_fs(oldfs); + return res; + } +@@ -324,7 +324,7 @@ static int __init ic_dev_ioctl(unsigned int cmd, struct ifreq *arg) + + mm_segment_t oldfs = get_fs(); + set_fs(get_ds()); +- res = dev_ioctl(&init_net, cmd, (struct ifreq __user *) arg); ++ res = 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, struct rtentry *arg) + + mm_segment_t oldfs = get_fs(); + set_fs(get_ds()); +- res = ip_rt_ioctl(&init_net, cmd, (void __user *) arg); ++ res = 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 8812a02..c4cdb5a 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, *len = 0; @@ -72671,10 +74038,11 @@ diff -urNp linux-3.0.9/net/ipv4/netfilter/nf_nat_snmp_basic.c linux-3.0.9/net/ip if (*octets == NULL) { if (net_ratelimit()) pr_notice("OOM in bsalg (%d)\n", __LINE__); -diff -urNp linux-3.0.9/net/ipv4/ping.c linux-3.0.9/net/ipv4/ping.c ---- linux-3.0.9/net/ipv4/ping.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/ping.c 2011-11-12 12:47:14.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, @@ -72683,10 +74051,11 @@ diff -urNp linux-3.0.9/net/ipv4/ping.c linux-3.0.9/net/ipv4/ping.c } static int ping_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.0.9/net/ipv4/raw.c linux-3.0.9/net/ipv4/raw.c ---- linux-3.0.9/net/ipv4/raw.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/raw.c 2011-11-12 12:47:14.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 c9893d4..5513bcb 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_buff * skb) int raw_rcv(struct sock *sk, struct sk_buff *skb) { if (!xfrm4_policy_check(sk, XFRM_POLICY_IN, skb)) { @@ -72717,7 +74086,7 @@ diff -urNp linux-3.0.9/net/ipv4/raw.c linux-3.0.9/net/ipv4/raw.c if (get_user(len, optlen)) goto out; -@@ -755,8 +759,9 @@ static int raw_geticmpfilter(struct sock +@@ -755,8 +759,9 @@ static int raw_geticmpfilter(struct sock *sk, char __user *optval, int __user *o if (len > sizeof(struct icmp_filter)) len = sizeof(struct icmp_filter); ret = -EFAULT; @@ -72729,7 +74098,7 @@ diff -urNp linux-3.0.9/net/ipv4/raw.c linux-3.0.9/net/ipv4/raw.c goto out; ret = 0; out: return ret; -@@ -984,7 +989,13 @@ static void raw_sock_seq_show(struct seq +@@ -984,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), @@ -72744,10 +74113,11 @@ diff -urNp linux-3.0.9/net/ipv4/raw.c linux-3.0.9/net/ipv4/raw.c } static int raw_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.0.9/net/ipv4/route.c linux-3.0.9/net/ipv4/route.c ---- linux-3.0.9/net/ipv4/route.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/route.c 2011-11-12 12:47:14.000000000 -0500 -@@ -304,7 +304,7 @@ static inline unsigned int rt_hash(__be3 +diff --git a/net/ipv4/route.c b/net/ipv4/route.c +index 75ef66f..458c43f 100644 +--- a/net/ipv4/route.c ++++ b/net/ipv4/route.c +@@ -304,7 +304,7 @@ static inline unsigned int rt_hash(__be32 daddr, __be32 saddr, int idx, static inline int rt_genid(struct net *net) { @@ -72756,7 +74126,7 @@ diff -urNp linux-3.0.9/net/ipv4/route.c linux-3.0.9/net/ipv4/route.c } #ifdef CONFIG_PROC_FS -@@ -832,7 +832,7 @@ static void rt_cache_invalidate(struct n +@@ -832,7 +832,7 @@ static void rt_cache_invalidate(struct net *net) unsigned char shuffle; get_random_bytes(&shuffle, sizeof(shuffle)); @@ -72774,10 +74144,11 @@ diff -urNp linux-3.0.9/net/ipv4/route.c linux-3.0.9/net/ipv4/route.c if (peer->tcp_ts_stamp) { ts = peer->tcp_ts; tsage = get_seconds() - peer->tcp_ts_stamp; -diff -urNp linux-3.0.9/net/ipv4/tcp.c linux-3.0.9/net/ipv4/tcp.c ---- linux-3.0.9/net/ipv4/tcp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/tcp.c 2011-11-12 12:47:14.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 = 0; @@ -72786,7 +74157,7 @@ diff -urNp linux-3.0.9/net/ipv4/tcp.c linux-3.0.9/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 = tcp_sk(sk); int val, len; @@ -72795,9 +74166,10 @@ diff -urNp linux-3.0.9/net/ipv4/tcp.c linux-3.0.9/net/ipv4/tcp.c if (get_user(len, optlen)) return -EFAULT; -diff -urNp linux-3.0.9/net/ipv4/tcp_ipv4.c linux-3.0.9/net/ipv4/tcp_ipv4.c ---- linux-3.0.9/net/ipv4/tcp_ipv4.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/tcp_ipv4.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c +index 69790aa..e6cabd4 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); @@ -72808,7 +74180,7 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_ipv4.c linux-3.0.9/net/ipv4/tcp_ipv4.c #ifdef CONFIG_TCP_MD5SIG static struct tcp_md5sig_key *tcp_v4_md5_do_lookup(struct sock *sk, -@@ -1610,6 +1613,9 @@ int tcp_v4_do_rcv(struct sock *sk, struc +@@ -1610,6 +1613,9 @@ int tcp_v4_do_rcv(struct sock *sk, struct sk_buff *skb) return 0; reset: @@ -72852,7 +74224,7 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_ipv4.c linux-3.0.9/net/ipv4/tcp_ipv4.c tcp_v4_send_reset(NULL, skb); } -@@ -2391,7 +2408,11 @@ static void get_openreq4(struct sock *sk +@@ -2391,7 +2408,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), @@ -72864,7 +74236,7 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_ipv4.c linux-3.0.9/net/ipv4/tcp_ipv4.c len); } -@@ -2441,7 +2462,12 @@ static void get_tcp4_sock(struct sock *s +@@ -2441,7 +2462,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), @@ -72878,7 +74250,7 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_ipv4.c linux-3.0.9/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, -@@ -2469,7 +2495,13 @@ static void get_timewait4_sock(struct in +@@ -2469,7 +2495,13 @@ static void get_timewait4_sock(struct inet_timewait_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, @@ -72893,9 +74265,10 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_ipv4.c linux-3.0.9/net/ipv4/tcp_ipv4.c } #define TMPSZ 150 -diff -urNp linux-3.0.9/net/ipv4/tcp_minisocks.c linux-3.0.9/net/ipv4/tcp_minisocks.c ---- linux-3.0.9/net/ipv4/tcp_minisocks.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/tcp_minisocks.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/ipv4/tcp_minisocks.c b/net/ipv4/tcp_minisocks.c +index 80b1f80..9501f25 100644 +--- a/net/ipv4/tcp_minisocks.c ++++ b/net/ipv4/tcp_minisocks.c @@ -27,6 +27,10 @@ #include <net/inet_common.h> #include <net/xfrm.h> @@ -72918,10 +74291,11 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_minisocks.c linux-3.0.9/net/ipv4/tcp_minisoc if (!(flg & TCP_FLAG_RST)) req->rsk_ops->send_reset(sk, skb); -diff -urNp linux-3.0.9/net/ipv4/tcp_output.c linux-3.0.9/net/ipv4/tcp_output.c ---- linux-3.0.9/net/ipv4/tcp_output.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/tcp_output.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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, struct dst_entry *dst, int mss; int s_data_desired = 0; @@ -72930,10 +74304,11 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_output.c linux-3.0.9/net/ipv4/tcp_output.c if (cvp != NULL && cvp->s_data_constant && cvp->s_data_desired) s_data_desired = cvp->s_data_desired; skb = sock_wmalloc(sk, MAX_TCP_HEADER + 15 + s_data_desired, 1, GFP_ATOMIC); -diff -urNp linux-3.0.9/net/ipv4/tcp_probe.c linux-3.0.9/net/ipv4/tcp_probe.c ---- linux-3.0.9/net/ipv4/tcp_probe.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/tcp_probe.c 2011-11-12 12:47:14.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 >= len) break; @@ -72942,9 +74317,10 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_probe.c linux-3.0.9/net/ipv4/tcp_probe.c return -EFAULT; cnt += width; } -diff -urNp linux-3.0.9/net/ipv4/tcp_timer.c linux-3.0.9/net/ipv4/tcp_timer.c ---- linux-3.0.9/net/ipv4/tcp_timer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/tcp_timer.c 2011-11-12 12:47:14.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 <linux/gfp.h> #include <net/tcp.h> @@ -72956,7 +74332,7 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_timer.c linux-3.0.9/net/ipv4/tcp_timer.c int sysctl_tcp_syn_retries __read_mostly = TCP_SYN_RETRIES; int sysctl_tcp_synack_retries __read_mostly = TCP_SYNACK_RETRIES; int sysctl_tcp_keepalive_time __read_mostly = 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) } } @@ -72970,9 +74346,10 @@ diff -urNp linux-3.0.9/net/ipv4/tcp_timer.c linux-3.0.9/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.0.9/net/ipv4/udp.c linux-3.0.9/net/ipv4/udp.c ---- linux-3.0.9/net/ipv4/udp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv4/udp.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c +index 198f75b..91d9905 100644 +--- a/net/ipv4/udp.c ++++ b/net/ipv4/udp.c @@ -86,6 +86,7 @@ #include <linux/types.h> #include <linux/fcntl.h> @@ -73002,7 +74379,7 @@ diff -urNp linux-3.0.9/net/ipv4/udp.c linux-3.0.9/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 -@@ -855,9 +863,18 @@ int udp_sendmsg(struct kiocb *iocb, stru +@@ -855,9 +863,18 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg, dport = usin->sin_port; if (dport == 0) return -EINVAL; @@ -73021,7 +74398,7 @@ diff -urNp linux-3.0.9/net/ipv4/udp.c linux-3.0.9/net/ipv4/udp.c daddr = inet->inet_daddr; dport = inet->inet_dport; /* Open fast path for connected socket. -@@ -1098,7 +1115,7 @@ static unsigned int first_packet_length( +@@ -1098,7 +1115,7 @@ static unsigned int first_packet_length(struct sock *sk) udp_lib_checksum_complete(skb)) { UDP_INC_STATS_BH(sock_net(sk), UDP_MIB_INERRORS, IS_UDPLITE(sk)); @@ -73041,7 +74418,7 @@ diff -urNp linux-3.0.9/net/ipv4/udp.c linux-3.0.9/net/ipv4/udp.c ulen = skb->len - sizeof(struct udphdr); if (len > ulen) len = ulen; -@@ -1483,7 +1504,7 @@ int udp_queue_rcv_skb(struct sock *sk, s +@@ -1483,7 +1504,7 @@ int udp_queue_rcv_skb(struct sock *sk, struct sk_buff *skb) drop: UDP_INC_STATS_BH(sock_net(sk), UDP_MIB_INERRORS, is_udplite); @@ -73050,7 +74427,7 @@ diff -urNp linux-3.0.9/net/ipv4/udp.c linux-3.0.9/net/ipv4/udp.c kfree_skb(skb); return -1; } -@@ -1502,7 +1523,7 @@ static void flush_stack(struct sock **st +@@ -1502,7 +1523,7 @@ static void flush_stack(struct sock **stack, unsigned int count, skb1 = (i == final) ? skb : skb_clone(skb, GFP_ATOMIC); if (!skb1) { @@ -73059,7 +74436,7 @@ diff -urNp linux-3.0.9/net/ipv4/udp.c linux-3.0.9/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, -@@ -1671,6 +1692,9 @@ int __udp4_lib_rcv(struct sk_buff *skb, +@@ -1671,6 +1692,9 @@ int __udp4_lib_rcv(struct sk_buff *skb, struct udp_table *udptable, goto csum_error; UDP_INC_STATS_BH(net, UDP_MIB_NOPORTS, proto == IPPROTO_UDPLITE); @@ -73069,7 +74446,7 @@ diff -urNp linux-3.0.9/net/ipv4/udp.c linux-3.0.9/net/ipv4/udp.c icmp_send(skb, ICMP_DEST_UNREACH, ICMP_PORT_UNREACH, 0); /* -@@ -2098,8 +2122,13 @@ static void udp4_format_sock(struct sock +@@ -2098,8 +2122,13 @@ static void udp4_format_sock(struct sock *sp, struct 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), @@ -73085,10 +74462,11 @@ diff -urNp linux-3.0.9/net/ipv4/udp.c linux-3.0.9/net/ipv4/udp.c } int udp4_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.0.9/net/ipv6/addrconf.c linux-3.0.9/net/ipv6/addrconf.c ---- linux-3.0.9/net/ipv6/addrconf.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv6/addrconf.c 2011-11-12 12:47:14.000000000 -0500 -@@ -2072,7 +2072,7 @@ int addrconf_set_dstaddr(struct net *net +diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c +index 498b927..79ba352 100644 +--- a/net/ipv6/addrconf.c ++++ b/net/ipv6/addrconf.c +@@ -2072,7 +2072,7 @@ int addrconf_set_dstaddr(struct net *net, void __user *arg) p.iph.ihl = 5; p.iph.protocol = IPPROTO_IPV6; p.iph.ttl = 64; @@ -73097,10 +74475,11 @@ diff -urNp linux-3.0.9/net/ipv6/addrconf.c linux-3.0.9/net/ipv6/addrconf.c if (ops->ndo_do_ioctl) { mm_segment_t oldfs = get_fs(); -diff -urNp linux-3.0.9/net/ipv6/inet6_connection_sock.c linux-3.0.9/net/ipv6/inet6_connection_sock.c ---- linux-3.0.9/net/ipv6/inet6_connection_sock.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv6/inet6_connection_sock.c 2011-11-12 12:47:14.000000000 -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_connection_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 dst_entry *dst, #ifdef CONFIG_XFRM { struct rt6_info *rt = (struct rt6_info *)dst; @@ -73109,7 +74488,7 @@ diff -urNp linux-3.0.9/net/ipv6/inet6_connection_sock.c linux-3.0.9/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 = (struct rt6_info *)dst; @@ -73118,10 +74497,11 @@ diff -urNp linux-3.0.9/net/ipv6/inet6_connection_sock.c linux-3.0.9/net/ipv6/ine __sk_dst_reset(sk); dst = NULL; } -diff -urNp linux-3.0.9/net/ipv6/ipv6_sockglue.c linux-3.0.9/net/ipv6/ipv6_sockglue.c ---- linux-3.0.9/net/ipv6/ipv6_sockglue.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv6/ipv6_sockglue.c 2011-11-12 12:47:14.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 147ede38..fb01709 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 level, int optname, int val, valbool; int retv = -ENOPROTOOPT; @@ -73130,7 +74510,7 @@ diff -urNp linux-3.0.9/net/ipv6/ipv6_sockglue.c linux-3.0.9/net/ipv6/ipv6_sockgl if (optval == NULL) val=0; 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 level, int optname, int len; int val; @@ -73139,7 +74519,7 @@ diff -urNp linux-3.0.9/net/ipv6/ipv6_sockglue.c linux-3.0.9/net/ipv6/ipv6_sockgl if (ip6_mroute_opt(optname)) return ip6_mroute_getsockopt(sk, optname, optval, optlen); -@@ -960,7 +964,7 @@ static int do_ipv6_getsockopt(struct soc +@@ -960,7 +964,7 @@ static int do_ipv6_getsockopt(struct sock *sk, int level, int optname, if (sk->sk_type != SOCK_STREAM) return -ENOPROTOOPT; @@ -73148,10 +74528,11 @@ diff -urNp linux-3.0.9/net/ipv6/ipv6_sockglue.c linux-3.0.9/net/ipv6/ipv6_sockgl msg.msg_controllen = len; msg.msg_flags = flags; -diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/net/ipv6/raw.c ---- linux-3.0.9/net/ipv6/raw.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv6/raw.c 2011-11-12 12:47:14.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 cc7313b..e91945a 100644 +--- a/net/ipv6/raw.c ++++ b/net/ipv6/raw.c +@@ -376,7 +376,7 @@ static inline int rawv6_rcv_skb(struct sock * sk, struct sk_buff * skb) { if ((raw6_sk(sk)->checksum || rcu_dereference_raw(sk->sk_filter)) && skb_checksum_complete(skb)) { @@ -73160,7 +74541,7 @@ diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/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 = raw6_sk(sk); if (!xfrm6_policy_check(sk, XFRM_POLICY_IN, skb)) { @@ -73169,7 +74550,7 @@ diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/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) if (inet->hdrincl) { if (skb_checksum_complete(skb)) { @@ -73187,7 +74568,7 @@ diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/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; @@ -73213,7 +74594,7 @@ diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/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; @@ -73221,7 +74602,7 @@ diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/net/ipv6/raw.c 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 = sizeof(struct icmp6_filter); if (put_user(len, optlen)) return -EFAULT; @@ -73231,7 +74612,7 @@ diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/net/ipv6/raw.c return -EFAULT; return 0; default: -@@ -1252,7 +1259,13 @@ static void raw6_sock_seq_show(struct se +@@ -1252,7 +1259,13 @@ static void raw6_sock_seq_show(struct seq_file *seq, struct sock *sp, int i) 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -73246,10 +74627,11 @@ diff -urNp linux-3.0.9/net/ipv6/raw.c linux-3.0.9/net/ipv6/raw.c } static int raw6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.0.9/net/ipv6/tcp_ipv6.c linux-3.0.9/net/ipv6/tcp_ipv6.c ---- linux-3.0.9/net/ipv6/tcp_ipv6.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv6/tcp_ipv6.c 2011-11-12 12:47:14.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 296510a..1866589 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(struct sock *sk, } #endif @@ -73260,7 +74642,7 @@ diff -urNp linux-3.0.9/net/ipv6/tcp_ipv6.c linux-3.0.9/net/ipv6/tcp_ipv6.c static void tcp_v6_hash(struct sock *sk) { if (sk->sk_state != TCP_CLOSE) { -@@ -1667,6 +1671,9 @@ static int tcp_v6_do_rcv(struct sock *sk +@@ -1667,6 +1671,9 @@ static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) return 0; reset: @@ -73270,7 +74652,7 @@ diff -urNp linux-3.0.9/net/ipv6/tcp_ipv6.c linux-3.0.9/net/ipv6/tcp_ipv6.c tcp_v6_send_reset(sk, skb); discard: if (opt_skb) -@@ -1746,12 +1753,20 @@ static int tcp_v6_rcv(struct sk_buff *sk +@@ -1746,12 +1753,20 @@ static int tcp_v6_rcv(struct sk_buff *skb) TCP_SKB_CB(skb)->sacked = 0; sk = __inet6_lookup_skb(&tcp_hashinfo, skb, th->source, th->dest); @@ -73304,7 +74686,7 @@ diff -urNp linux-3.0.9/net/ipv6/tcp_ipv6.c linux-3.0.9/net/ipv6/tcp_ipv6.c tcp_v6_send_reset(NULL, skb); } -@@ -2059,7 +2078,13 @@ static void get_openreq6(struct seq_file +@@ -2059,7 +2078,13 @@ static void get_openreq6(struct seq_file *seq, uid, 0, /* non standard timer */ 0, /* open_requests have no inode */ @@ -73319,7 +74701,7 @@ diff -urNp linux-3.0.9/net/ipv6/tcp_ipv6.c linux-3.0.9/net/ipv6/tcp_ipv6.c } static void get_tcp6_sock(struct seq_file *seq, struct sock *sp, int i) -@@ -2109,7 +2134,12 @@ static void get_tcp6_sock(struct seq_fil +@@ -2109,7 +2134,12 @@ static void get_tcp6_sock(struct seq_file *seq, struct sock *sp, int i) sock_i_uid(sp), icsk->icsk_probes_out, sock_i_ino(sp), @@ -73333,7 +74715,7 @@ diff -urNp linux-3.0.9/net/ipv6/tcp_ipv6.c linux-3.0.9/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, -@@ -2144,7 +2174,13 @@ static void get_timewait6_sock(struct se +@@ -2144,7 +2174,13 @@ static void get_timewait6_sock(struct seq_file *seq, dest->s6_addr32[2], dest->s6_addr32[3], destp, tw->tw_substate, 0, 0, 3, jiffies_to_clock_t(ttd), 0, 0, 0, 0, @@ -73348,9 +74730,10 @@ diff -urNp linux-3.0.9/net/ipv6/tcp_ipv6.c linux-3.0.9/net/ipv6/tcp_ipv6.c } static int tcp6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.0.9/net/ipv6/udp.c linux-3.0.9/net/ipv6/udp.c ---- linux-3.0.9/net/ipv6/udp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/ipv6/udp.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c +index 0d920c5..72a51d9 100644 +--- a/net/ipv6/udp.c ++++ b/net/ipv6/udp.c @@ -50,6 +50,10 @@ #include <linux/seq_file.h> #include "udp_impl.h" @@ -73362,7 +74745,7 @@ diff -urNp linux-3.0.9/net/ipv6/udp.c linux-3.0.9/net/ipv6/udp.c int ipv6_rcv_saddr_equal(const struct sock *sk, const struct sock *sk2) { const struct in6_addr *sk_rcv_saddr6 = &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) return 0; drop: @@ -73371,7 +74754,7 @@ diff -urNp linux-3.0.9/net/ipv6/udp.c linux-3.0.9/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, unsigned int count, continue; } drop: @@ -73380,7 +74763,7 @@ diff -urNp linux-3.0.9/net/ipv6/udp.c linux-3.0.9/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, +@@ -779,6 +783,9 @@ int __udp6_lib_rcv(struct sk_buff *skb, struct udp_table *udptable, UDP6_INC_STATS_BH(net, UDP_MIB_NOPORTS, proto == IPPROTO_UDPLITE); @@ -73390,7 +74773,7 @@ diff -urNp linux-3.0.9/net/ipv6/udp.c linux-3.0.9/net/ipv6/udp.c icmpv6_send(skb, ICMPV6_DEST_UNREACH, ICMPV6_PORT_UNREACH, 0); kfree_skb(skb); -@@ -795,7 +802,7 @@ int __udp6_lib_rcv(struct sk_buff *skb, +@@ -795,7 +802,7 @@ int __udp6_lib_rcv(struct sk_buff *skb, struct udp_table *udptable, if (!sock_owned_by_user(sk)) udpv6_queue_rcv_skb(sk, skb); else if (sk_add_backlog(sk, skb)) { @@ -73399,7 +74782,7 @@ diff -urNp linux-3.0.9/net/ipv6/udp.c linux-3.0.9/net/ipv6/udp.c bh_unlock_sock(sk); sock_put(sk); goto discard; -@@ -1408,8 +1415,13 @@ static void udp6_sock_seq_show(struct se +@@ -1408,8 +1415,13 @@ static void udp6_sock_seq_show(struct seq_file *seq, struct sock *sp, int bucket 0, 0L, 0, sock_i_uid(sp), 0, sock_i_ino(sp), @@ -73415,10 +74798,11 @@ diff -urNp linux-3.0.9/net/ipv6/udp.c linux-3.0.9/net/ipv6/udp.c } int udp6_seq_show(struct seq_file *seq, void *v) -diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/net/irda/ircomm/ircomm_tty.c ---- linux-3.0.9/net/irda/ircomm/ircomm_tty.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/irda/ircomm/ircomm_tty.c 2011-11-12 12:47:14.000000000 -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 ircomm_tty_cb *self, add_wait_queue(&self->open_wait, &wait); IRDA_DEBUG(2, "%s(%d):block_til_ready before block on %s open_count=%d\n", @@ -73438,7 +74822,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/net/irda/ircomm/ 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, } IRDA_DEBUG(1, "%s(%d):block_til_ready blocking on %s open_count=%d\n", @@ -73447,7 +74831,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/net/irda/ircomm/ 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 ircomm_tty_cb *self, if (extra_count) { /* ++ is not atomic, so this should be protected - Jean II */ spin_lock_irqsave(&self->spinlock, flags); @@ -73464,7 +74848,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/net/irda/ircomm/ if (!retval) self->flags |= 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); @@ -73481,7 +74865,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/net/irda/ircomm/ /* Not really used by us, but lets do it anyway */ self->tty->low_latency = (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; } @@ -73490,7 +74874,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/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 *tty, struct file *filp) */ IRDA_DEBUG(0, "%s(), bad serial port count; " "tty->count is 1, state->count is %d\n", __func__ , @@ -73513,7 +74897,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/net/irda/ircomm/ spin_unlock_irqrestore(&self->spinlock, flags); 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 = 0; self->tty = NULL; @@ -73522,7 +74906,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/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 *tty) spin_lock_irqsave(&self->spinlock, flags); self->flags &= ~ASYNC_NORMAL_ACTIVE; self->tty = NULL; @@ -73531,7 +74915,7 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/net/irda/ircomm/ spin_unlock_irqrestore(&self->spinlock, flags); wake_up_interruptible(&self->open_wait); -@@ -1360,7 +1360,7 @@ static void ircomm_tty_line_info(struct +@@ -1360,7 +1360,7 @@ static void ircomm_tty_line_info(struct ircomm_tty_cb *self, struct seq_file *m) seq_putc(m, '\n'); seq_printf(m, "Role: %s\n", self->client ? "client" : "server"); @@ -73540,10 +74924,11 @@ diff -urNp linux-3.0.9/net/irda/ircomm/ircomm_tty.c linux-3.0.9/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); -diff -urNp linux-3.0.9/net/iucv/af_iucv.c linux-3.0.9/net/iucv/af_iucv.c ---- linux-3.0.9/net/iucv/af_iucv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/iucv/af_iucv.c 2011-11-12 12:47:14.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) write_lock_bh(&iucv_sk_list.lock); @@ -73556,10 +74941,11 @@ diff -urNp linux-3.0.9/net/iucv/af_iucv.c linux-3.0.9/net/iucv/af_iucv.c } write_unlock_bh(&iucv_sk_list.lock); -diff -urNp linux-3.0.9/net/key/af_key.c linux-3.0.9/net/key/af_key.c ---- linux-3.0.9/net/key/af_key.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/key/af_key.c 2011-11-12 12:47:14.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 8f92cf8..7f40167 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 sk_buff *skb, struct xfrm_migrate m[XFRM_MAX_DEPTH]; struct xfrm_kmaddress k; @@ -73568,7 +74954,7 @@ diff -urNp linux-3.0.9/net/key/af_key.c linux-3.0.9/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; @@ -73581,10 +74967,11 @@ diff -urNp linux-3.0.9/net/key/af_key.c linux-3.0.9/net/key/af_key.c } while (!res); return res; } -diff -urNp linux-3.0.9/net/lapb/lapb_iface.c linux-3.0.9/net/lapb/lapb_iface.c ---- linux-3.0.9/net/lapb/lapb_iface.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/lapb/lapb_iface.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 d5d8d55..f50d18f 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 lapb_register_struct *callbacks goto out; lapb->dev = dev; @@ -73593,7 +74980,7 @@ diff -urNp linux-3.0.9/net/lapb/lapb_iface.c linux-3.0.9/net/lapb/lapb_iface.c __lapb_insert_cb(lapb); -@@ -380,32 +380,32 @@ int lapb_data_received(struct net_device +@@ -380,32 +380,32 @@ int lapb_data_received(struct net_device *dev, struct sk_buff *skb) void lapb_connect_confirmation(struct lapb_cb *lapb, int reason) { @@ -73636,7 +75023,7 @@ diff -urNp linux-3.0.9/net/lapb/lapb_iface.c linux-3.0.9/net/lapb/lapb_iface.c kfree_skb(skb); return NET_RX_SUCCESS; /* For now; must be != 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 = 0; @@ -73647,10 +75034,11 @@ diff -urNp linux-3.0.9/net/lapb/lapb_iface.c linux-3.0.9/net/lapb/lapb_iface.c used = 1; } -diff -urNp linux-3.0.9/net/mac80211/debugfs_sta.c linux-3.0.9/net/mac80211/debugfs_sta.c ---- linux-3.0.9/net/mac80211/debugfs_sta.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/debugfs_sta.c 2011-11-12 12:47:14.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; @@ -73659,7 +75047,7 @@ diff -urNp linux-3.0.9/net/mac80211/debugfs_sta.c linux-3.0.9/net/mac80211/debug rcu_read_lock(); p += 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, char __user *userbuf, struct sta_info *sta = file->private_data; struct ieee80211_sta_ht_cap *htc = &sta->sta.ht_cap; @@ -73668,9 +75056,10 @@ diff -urNp linux-3.0.9/net/mac80211/debugfs_sta.c linux-3.0.9/net/mac80211/debug p += scnprintf(p, sizeof(buf) + buf - p, "ht %ssupported\n", htc->ht_supported ? "" : "not "); if (htc->ht_supported) { -diff -urNp linux-3.0.9/net/mac80211/ieee80211_i.h linux-3.0.9/net/mac80211/ieee80211_i.h ---- linux-3.0.9/net/mac80211/ieee80211_i.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/ieee80211_i.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h +index 3fdac77..9b3e137 100644 +--- a/net/mac80211/ieee80211_i.h ++++ b/net/mac80211/ieee80211_i.h @@ -27,6 +27,7 @@ #include <net/ieee80211_radiotap.h> #include <net/cfg80211.h> @@ -73688,10 +75077,11 @@ diff -urNp linux-3.0.9/net/mac80211/ieee80211_i.h linux-3.0.9/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.0.9/net/mac80211/iface.c linux-3.0.9/net/mac80211/iface.c ---- linux-3.0.9/net/mac80211/iface.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/iface.c 2011-11-12 12:47:14.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 895eec1..00beb81 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; } @@ -73700,7 +75090,7 @@ diff -urNp linux-3.0.9/net/mac80211/iface.c linux-3.0.9/net/mac80211/iface.c res = 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); if (!is_valid_ether_addr(dev->dev_addr)) { @@ -73709,7 +75099,7 @@ diff -urNp linux-3.0.9/net/mac80211/iface.c linux-3.0.9/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); if (coming_up) @@ -73718,7 +75108,7 @@ diff -urNp linux-3.0.9/net/mac80211/iface.c linux-3.0.9/net/mac80211/iface.c 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: @@ -73727,7 +75117,7 @@ diff -urNp linux-3.0.9/net/mac80211/iface.c linux-3.0.9/net/mac80211/iface.c drv_stop(local); err_del_bss: sdata->bss = NULL; -@@ -475,7 +475,7 @@ static void ieee80211_do_stop(struct iee +@@ -475,7 +475,7 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata, } if (going_down) @@ -73736,7 +75126,7 @@ diff -urNp linux-3.0.9/net/mac80211/iface.c linux-3.0.9/net/mac80211/iface.c switch (sdata->vif.type) { case NL80211_IFTYPE_AP_VLAN: -@@ -534,7 +534,7 @@ static void ieee80211_do_stop(struct iee +@@ -534,7 +534,7 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata, ieee80211_recalc_ps(local, -1); @@ -73745,10 +75135,11 @@ diff -urNp linux-3.0.9/net/mac80211/iface.c linux-3.0.9/net/mac80211/iface.c if (local->ops->napi_poll) napi_disable(&local->napi); ieee80211_clear_tx_pending(local); -diff -urNp linux-3.0.9/net/mac80211/main.c linux-3.0.9/net/mac80211/main.c ---- linux-3.0.9/net/mac80211/main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/main.c 2011-11-12 12:47:14.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 866f269..3cf46ed 100644 +--- a/net/mac80211/main.c ++++ b/net/mac80211/main.c +@@ -209,7 +209,7 @@ int ieee80211_hw_config(struct ieee80211_local *local, u32 changed) local->hw.conf.power_level = power; } @@ -73757,10 +75148,11 @@ diff -urNp linux-3.0.9/net/mac80211/main.c linux-3.0.9/net/mac80211/main.c ret = drv_config(local, changed); /* * Goal: -diff -urNp linux-3.0.9/net/mac80211/mlme.c linux-3.0.9/net/mac80211/mlme.c ---- linux-3.0.9/net/mac80211/mlme.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/mlme.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1447,6 +1447,8 @@ static bool ieee80211_assoc_success(stru +diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c +index 1563250..d5d448e 100644 +--- a/net/mac80211/mlme.c ++++ b/net/mac80211/mlme.c +@@ -1447,6 +1447,8 @@ static bool ieee80211_assoc_success(struct ieee80211_work *wk, bool have_higher_than_11mbit = false; u16 ap_ht_cap_flags; @@ -73769,10 +75161,11 @@ diff -urNp linux-3.0.9/net/mac80211/mlme.c linux-3.0.9/net/mac80211/mlme.c /* AssocResp and ReassocResp have identical structure */ aid = le16_to_cpu(mgmt->u.assoc_resp.aid); -diff -urNp linux-3.0.9/net/mac80211/pm.c linux-3.0.9/net/mac80211/pm.c ---- linux-3.0.9/net/mac80211/pm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/pm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -47,7 +47,7 @@ int __ieee80211_suspend(struct ieee80211 +diff --git a/net/mac80211/pm.c b/net/mac80211/pm.c +index 730778a..be868e2 100644 +--- a/net/mac80211/pm.c ++++ b/net/mac80211/pm.c +@@ -47,7 +47,7 @@ int __ieee80211_suspend(struct ieee80211_hw *hw, struct cfg80211_wowlan *wowlan) cancel_work_sync(&local->dynamic_ps_enable_work); del_timer_sync(&local->dynamic_ps_timer); @@ -73781,7 +75174,7 @@ diff -urNp linux-3.0.9/net/mac80211/pm.c linux-3.0.9/net/mac80211/pm.c if (local->wowlan) { int err = drv_suspend(local, wowlan); if (err) { -@@ -111,7 +111,7 @@ int __ieee80211_suspend(struct ieee80211 +@@ -111,7 +111,7 @@ int __ieee80211_suspend(struct ieee80211_hw *hw, struct cfg80211_wowlan *wowlan) } /* stop hardware - this must stop RX */ @@ -73790,10 +75183,11 @@ diff -urNp linux-3.0.9/net/mac80211/pm.c linux-3.0.9/net/mac80211/pm.c ieee80211_stop_device(local); suspend: -diff -urNp linux-3.0.9/net/mac80211/rate.c linux-3.0.9/net/mac80211/rate.c ---- linux-3.0.9/net/mac80211/rate.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/rate.c 2011-11-12 12:47:14.000000000 -0500 -@@ -371,7 +371,7 @@ int ieee80211_init_rate_ctrl_alg(struct +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_local *local, ASSERT_RTNL(); @@ -73802,10 +75196,11 @@ diff -urNp linux-3.0.9/net/mac80211/rate.c linux-3.0.9/net/mac80211/rate.c return -EBUSY; if (local->hw.flags & IEEE80211_HW_HAS_RATE_CONTROL) { -diff -urNp linux-3.0.9/net/mac80211/rc80211_pid_debugfs.c linux-3.0.9/net/mac80211/rc80211_pid_debugfs.c ---- linux-3.0.9/net/mac80211/rc80211_pid_debugfs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/rc80211_pid_debugfs.c 2011-11-12 12:47:14.000000000 -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_pid_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 file *file, char __user *buf, spin_unlock_irqrestore(&events->lock, status); @@ -73814,10 +75209,11 @@ diff -urNp linux-3.0.9/net/mac80211/rc80211_pid_debugfs.c linux-3.0.9/net/mac802 return -EFAULT; return p; -diff -urNp linux-3.0.9/net/mac80211/util.c linux-3.0.9/net/mac80211/util.c ---- linux-3.0.9/net/mac80211/util.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/mac80211/util.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1147,7 +1147,7 @@ int ieee80211_reconfig(struct ieee80211_ +diff --git a/net/mac80211/util.c b/net/mac80211/util.c +index d3fe2d2..0affe0d 100644 +--- a/net/mac80211/util.c ++++ b/net/mac80211/util.c +@@ -1147,7 +1147,7 @@ int ieee80211_reconfig(struct ieee80211_local *local) #endif /* restart hardware */ @@ -73826,10 +75222,44 @@ diff -urNp linux-3.0.9/net/mac80211/util.c linux-3.0.9/net/mac80211/util.c /* * Upon resume hardware can sometimes be goofy due to * various platform / driver / bus issues, so restarting -diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_conn.c linux-3.0.9/net/netfilter/ipvs/ip_vs_conn.c ---- linux-3.0.9/net/netfilter/ipvs/ip_vs_conn.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/ipvs/ip_vs_conn.c 2011-11-12 12:47:14.000000000 -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 + + To compile it as a module, choose M here. If unsure, say N. + ++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=n) +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) += xt_dccp.o + obj-$(CONFIG_NETFILTER_XT_MATCH_DEVGROUP) += xt_devgroup.o + obj-$(CONFIG_NETFILTER_XT_MATCH_DSCP) += xt_dscp.o + obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) += xt_esp.o ++obj-$(CONFIG_NETFILTER_XT_MATCH_GRADM) += xt_gradm.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HASHLIMIT) += xt_hashlimit.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HELPER) += xt_helper.o + obj-$(CONFIG_NETFILTER_XT_MATCH_HL) += xt_hl.o +diff --git a/net/netfilter/ipvs/ip_vs_conn.c b/net/netfilter/ipvs/ip_vs_conn.c +index 782db27..d1d9882 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); @@ -73838,7 +75268,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_conn.c linux-3.0.9/net/netfilter if (cp->protocol != IPPROTO_UDP) conn_flags &= ~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); atomic_set(&cp->n_control, 0); @@ -73847,7 +75277,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_conn.c linux-3.0.9/net/netfilter 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) /* Don't drop the entry if its number of incoming packets is not located in [0, 8] */ @@ -73856,10 +75286,11 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_conn.c linux-3.0.9/net/netfilter if (i > 8 || i < 0) return 0; if (!todrop_rate[i]) return 0; -diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_core.c linux-3.0.9/net/netfilter/ipvs/ip_vs_core.c ---- linux-3.0.9/net/netfilter/ipvs/ip_vs_core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/ipvs/ip_vs_core.c 2011-11-12 12:47:14.000000000 -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 24c28d2..800b45a 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 = cp->packet_xmit(skb, cp, pd->pp); /* do not touch skb anymore */ @@ -73868,7 +75299,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_core.c linux-3.0.9/net/netfilter ip_vs_conn_put(cp); return ret; } -@@ -1613,7 +1613,7 @@ ip_vs_in(unsigned int hooknum, struct sk +@@ -1613,7 +1613,7 @@ ip_vs_in(unsigned int hooknum, struct sk_buff *skb, int af) if (cp->flags & IP_VS_CONN_F_ONE_PACKET) pkts = sysctl_sync_threshold(ipvs); else @@ -73877,10 +75308,11 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_core.c linux-3.0.9/net/netfilter if ((ipvs->sync_state & IP_VS_STATE_MASTER) && cp->protocol == IPPROTO_SCTP) { -diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c ---- linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c 2011-11-12 12:47:14.000000000 -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_ctl.c +index a178cb3..9b0e607 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, struct ip_vs_dest *dest, ip_vs_rs_hash(ipvs, dest); write_unlock_bh(&ipvs->rs_lock); } @@ -73889,7 +75321,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c linux-3.0.9/net/netfilter/ /* 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 *seq, void *v) " %-7s %-6d %-10d %-10d\n", &dest->addr.in6, ntohs(dest->port), @@ -73898,7 +75330,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c linux-3.0.9/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 *seq, void *v) "%-7s %-6d %-10d %-10d\n", ntohl(dest->addr.ip), ntohs(dest->port), @@ -73907,7 +75339,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c linux-3.0.9/net/netfilter/ atomic_read(&dest->weight), atomic_read(&dest->activeconns), atomic_read(&dest->inactconns)); -@@ -2284,6 +2284,8 @@ do_ip_vs_set_ctl(struct sock *sk, int cm +@@ -2284,6 +2284,8 @@ do_ip_vs_set_ctl(struct sock *sk, int cmd, void __user *user, unsigned int len) struct ip_vs_dest_user *udest_compat; struct ip_vs_dest_user_kern udest; @@ -73916,7 +75348,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c linux-3.0.9/net/netfilter/ if (!capable(CAP_NET_ADMIN)) return -EPERM; -@@ -2498,7 +2500,7 @@ __ip_vs_get_dest_entries(struct net *net +@@ -2498,7 +2500,7 @@ __ip_vs_get_dest_entries(struct net *net, const struct ip_vs_get_dests *get, entry.addr = dest->addr.ip; entry.port = dest->port; @@ -73925,7 +75357,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c linux-3.0.9/net/netfilter/ entry.weight = atomic_read(&dest->weight); entry.u_threshold = dest->u_threshold; entry.l_threshold = dest->l_threshold; -@@ -3026,7 +3028,7 @@ static int ip_vs_genl_fill_dest(struct s +@@ -3026,7 +3028,7 @@ static int ip_vs_genl_fill_dest(struct sk_buff *skb, struct ip_vs_dest *dest) NLA_PUT_U16(skb, IPVS_DEST_ATTR_PORT, dest->port); NLA_PUT_U32(skb, IPVS_DEST_ATTR_FWD_METHOD, @@ -73934,9 +75366,10 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_ctl.c linux-3.0.9/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.0.9/net/netfilter/ipvs/ip_vs_sync.c linux-3.0.9/net/netfilter/ipvs/ip_vs_sync.c ---- linux-3.0.9/net/netfilter/ipvs/ip_vs_sync.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/ipvs/ip_vs_sync.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/netfilter/ipvs/ip_vs_sync.c b/net/netfilter/ipvs/ip_vs_sync.c +index e292e5b..be111b3 100644 +--- a/net/netfilter/ipvs/ip_vs_sync.c ++++ b/net/netfilter/ipvs/ip_vs_sync.c @@ -648,7 +648,7 @@ control: * i.e only increment in_pkts for Templates. */ @@ -73946,7 +75379,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_sync.c linux-3.0.9/net/netfilter if (pkts % sysctl_sync_period(ipvs) != 1) return; -@@ -794,7 +794,7 @@ static void ip_vs_proc_conn(struct net * +@@ -794,7 +794,7 @@ static void ip_vs_proc_conn(struct net *net, struct ip_vs_conn_param *param, if (opt) memcpy(&cp->in_seq, opt, sizeof(*opt)); @@ -73955,10 +75388,11 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_sync.c linux-3.0.9/net/netfilter cp->state = state; cp->old_state = cp->state; /* -diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_xmit.c linux-3.0.9/net/netfilter/ipvs/ip_vs_xmit.c ---- linux-3.0.9/net/netfilter/ipvs/ip_vs_xmit.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/ipvs/ip_vs_xmit.c 2011-11-12 12:47:14.000000000 -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 = NF_ACCEPT; /* do not touch skb anymore */ @@ -73967,7 +75401,7 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_xmit.c linux-3.0.9/net/netfilter goto out; } -@@ -1272,7 +1272,7 @@ ip_vs_icmp_xmit_v6(struct sk_buff *skb, +@@ -1272,7 +1272,7 @@ ip_vs_icmp_xmit_v6(struct sk_buff *skb, struct ip_vs_conn *cp, else rc = NF_ACCEPT; /* do not touch skb anymore */ @@ -73976,40 +75410,10 @@ diff -urNp linux-3.0.9/net/netfilter/ipvs/ip_vs_xmit.c linux-3.0.9/net/netfilter goto out; } -diff -urNp linux-3.0.9/net/netfilter/Kconfig linux-3.0.9/net/netfilter/Kconfig ---- linux-3.0.9/net/netfilter/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/Kconfig 2011-11-12 12:47:14.000000000 -0500 -@@ -781,6 +781,16 @@ config NETFILTER_XT_MATCH_ESP - - To compile it as a module, choose M here. If unsure, say N. - -+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=n) -diff -urNp linux-3.0.9/net/netfilter/Makefile linux-3.0.9/net/netfilter/Makefile ---- linux-3.0.9/net/netfilter/Makefile 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/Makefile 2011-11-12 12:47:14.000000000 -0500 -@@ -81,6 +81,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_DCCP) += - obj-$(CONFIG_NETFILTER_XT_MATCH_DEVGROUP) += xt_devgroup.o - obj-$(CONFIG_NETFILTER_XT_MATCH_DSCP) += xt_dscp.o - obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) += xt_esp.o -+obj-$(CONFIG_NETFILTER_XT_MATCH_GRADM) += xt_gradm.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HASHLIMIT) += xt_hashlimit.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HELPER) += xt_helper.o - obj-$(CONFIG_NETFILTER_XT_MATCH_HL) += xt_hl.o -diff -urNp linux-3.0.9/net/netfilter/nfnetlink_log.c linux-3.0.9/net/netfilter/nfnetlink_log.c ---- linux-3.0.9/net/netfilter/nfnetlink_log.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/nfnetlink_log.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/netfilter/nfnetlink_log.c b/net/netfilter/nfnetlink_log.c +index 2e7ccbb..3aa1aa7 100644 +--- a/net/netfilter/nfnetlink_log.c ++++ b/net/netfilter/nfnetlink_log.c @@ -70,7 +70,7 @@ struct nfulnl_instance { }; @@ -74019,7 +75423,7 @@ diff -urNp linux-3.0.9/net/netfilter/nfnetlink_log.c linux-3.0.9/net/netfilter/n #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, @@ -74028,9 +75432,10 @@ diff -urNp linux-3.0.9/net/netfilter/nfnetlink_log.c linux-3.0.9/net/netfilter/n if (data_len) { struct nlattr *nla; -diff -urNp linux-3.0.9/net/netfilter/nfnetlink_queue.c linux-3.0.9/net/netfilter/nfnetlink_queue.c ---- linux-3.0.9/net/netfilter/nfnetlink_queue.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/nfnetlink_queue.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/netfilter/nfnetlink_queue.c b/net/netfilter/nfnetlink_queue.c +index fdd2faf..384c533 100644 +--- a/net/netfilter/nfnetlink_queue.c ++++ b/net/netfilter/nfnetlink_queue.c @@ -58,7 +58,7 @@ struct nfqnl_instance { */ spinlock_t lock; @@ -74040,7 +75445,7 @@ diff -urNp linux-3.0.9/net/netfilter/nfnetlink_queue.c linux-3.0.9/net/netfilter struct list_head queue_list; /* packets in queue */ }; -@@ -272,7 +272,7 @@ nfqnl_build_packet_message(struct nfqnl_ +@@ -272,7 +272,7 @@ nfqnl_build_packet_message(struct nfqnl_instance *queue, nfmsg->version = NFNETLINK_V0; nfmsg->res_id = htons(queue->queue_num); @@ -74049,7 +75454,7 @@ diff -urNp linux-3.0.9/net/netfilter/nfnetlink_queue.c linux-3.0.9/net/netfilter pmsg.packet_id = htonl(entry->id); pmsg.hw_protocol = entskb->protocol; pmsg.hook = entry->hook; -@@ -870,7 +870,7 @@ static int seq_show(struct seq_file *s, +@@ -870,7 +870,7 @@ static int seq_show(struct seq_file *s, void *v) inst->peer_pid, inst->queue_total, inst->copy_mode, inst->copy_range, inst->queue_dropped, inst->queue_user_dropped, @@ -74058,9 +75463,11 @@ diff -urNp linux-3.0.9/net/netfilter/nfnetlink_queue.c linux-3.0.9/net/netfilter } static const struct seq_operations nfqnl_seq_ops = { -diff -urNp linux-3.0.9/net/netfilter/xt_gradm.c linux-3.0.9/net/netfilter/xt_gradm.c ---- linux-3.0.9/net/netfilter/xt_gradm.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/net/netfilter/xt_gradm.c 2011-11-12 12:47:14.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 @@ -74113,9 +75520,10 @@ diff -urNp linux-3.0.9/net/netfilter/xt_gradm.c linux-3.0.9/net/netfilter/xt_gra +MODULE_LICENSE("GPL"); +MODULE_ALIAS("ipt_gradm"); +MODULE_ALIAS("ip6t_gradm"); -diff -urNp linux-3.0.9/net/netfilter/xt_statistic.c linux-3.0.9/net/netfilter/xt_statistic.c ---- linux-3.0.9/net/netfilter/xt_statistic.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netfilter/xt_statistic.c 2011-11-12 12:47:14.000000000 -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 <linux/netfilter/x_tables.h> @@ -74125,7 +75533,7 @@ diff -urNp linux-3.0.9/net/netfilter/xt_statistic.c linux-3.0.9/net/netfilter/xt } ____cacheline_aligned_in_smp; MODULE_LICENSE("GPL"); -@@ -41,9 +41,9 @@ statistic_mt(const struct sk_buff *skb, +@@ -41,9 +41,9 @@ statistic_mt(const struct sk_buff *skb, struct xt_action_param *par) break; case XT_STATISTIC_MODE_NTH: do { @@ -74137,7 +75545,7 @@ diff -urNp linux-3.0.9/net/netfilter/xt_statistic.c linux-3.0.9/net/netfilter/xt if (nval == 0) ret = !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_param *par) info->master = kzalloc(sizeof(*info->master), GFP_KERNEL); if (info->master == NULL) return -ENOMEM; @@ -74146,10 +75554,11 @@ diff -urNp linux-3.0.9/net/netfilter/xt_statistic.c linux-3.0.9/net/netfilter/xt return 0; } -diff -urNp linux-3.0.9/net/netlink/af_netlink.c linux-3.0.9/net/netlink/af_netlink.c ---- linux-3.0.9/net/netlink/af_netlink.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netlink/af_netlink.c 2011-11-12 12:47:14.000000000 -0500 -@@ -742,7 +742,7 @@ static void netlink_overrun(struct sock +diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c +index 6ef64ad..a3fc29d 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); } } @@ -74158,7 +75567,7 @@ diff -urNp linux-3.0.9/net/netlink/af_netlink.c linux-3.0.9/net/netlink/af_netli } static struct sock *netlink_getsockbypid(struct sock *ssk, u32 pid) -@@ -1994,7 +1994,7 @@ static int netlink_seq_show(struct seq_f +@@ -1994,7 +1994,7 @@ static int netlink_seq_show(struct seq_file *seq, void *v) sk_wmem_alloc_get(s), nlk->cb, atomic_read(&s->sk_refcnt), @@ -74167,10 +75576,11 @@ diff -urNp linux-3.0.9/net/netlink/af_netlink.c linux-3.0.9/net/netlink/af_netli sock_i_ino(s) ); -diff -urNp linux-3.0.9/net/netrom/af_netrom.c linux-3.0.9/net/netrom/af_netrom.c ---- linux-3.0.9/net/netrom/af_netrom.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/netrom/af_netrom.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 sockaddr *uaddr, struct sock *sk = sock->sk; struct nr_sock *nr = nr_sk(sk); @@ -74178,7 +75588,7 @@ diff -urNp linux-3.0.9/net/netrom/af_netrom.c linux-3.0.9/net/netrom/af_netrom.c lock_sock(sk); if (peer != 0) { if (sk->sk_state != 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 sockaddr *uaddr, *uaddr_len = sizeof(struct full_sockaddr_ax25); } else { sax->fsa_ax25.sax25_family = AF_NETROM; @@ -74186,10 +75596,11 @@ diff -urNp linux-3.0.9/net/netrom/af_netrom.c linux-3.0.9/net/netrom/af_netrom.c sax->fsa_ax25.sax25_call = nr->source_addr; *uaddr_len = sizeof(struct sockaddr_ax25); } -diff -urNp linux-3.0.9/net/packet/af_packet.c linux-3.0.9/net/packet/af_packet.c ---- linux-3.0.9/net/packet/af_packet.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/packet/af_packet.c 2011-11-12 13:05:59.000000000 -0500 -@@ -647,7 +647,7 @@ static int packet_rcv(struct sk_buff *sk +diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c +index fafb968..effffa1 100644 +--- a/net/packet/af_packet.c ++++ b/net/packet/af_packet.c +@@ -647,7 +647,7 @@ static int packet_rcv(struct sk_buff *skb, struct net_device *dev, spin_lock(&sk->sk_receive_queue.lock); po->stats.tp_packets++; @@ -74198,7 +75609,7 @@ diff -urNp linux-3.0.9/net/packet/af_packet.c linux-3.0.9/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); -@@ -656,7 +656,7 @@ static int packet_rcv(struct sk_buff *sk +@@ -656,7 +656,7 @@ static int packet_rcv(struct sk_buff *skb, struct net_device *dev, drop_n_acct: spin_lock(&sk->sk_receive_queue.lock); po->stats.tp_drops++; @@ -74207,7 +75618,7 @@ diff -urNp linux-3.0.9/net/packet/af_packet.c linux-3.0.9/net/packet/af_packet.c spin_unlock(&sk->sk_receive_queue.lock); drop_n_restore: -@@ -2171,7 +2171,7 @@ static int packet_getsockopt(struct sock +@@ -2171,7 +2171,7 @@ static int packet_getsockopt(struct socket *sock, int level, int optname, case PACKET_HDRLEN: if (len > sizeof(int)) len = sizeof(int); @@ -74216,7 +75627,7 @@ diff -urNp linux-3.0.9/net/packet/af_packet.c linux-3.0.9/net/packet/af_packet.c return -EFAULT; switch (val) { case TPACKET_V1: -@@ -2209,7 +2209,7 @@ static int packet_getsockopt(struct sock +@@ -2209,7 +2209,7 @@ static int packet_getsockopt(struct socket *sock, int level, int optname, if (put_user(len, optlen)) return -EFAULT; @@ -74225,10 +75636,11 @@ diff -urNp linux-3.0.9/net/packet/af_packet.c linux-3.0.9/net/packet/af_packet.c return -EFAULT; return 0; } -diff -urNp linux-3.0.9/net/phonet/af_phonet.c linux-3.0.9/net/phonet/af_phonet.c ---- linux-3.0.9/net/phonet/af_phonet.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/phonet/af_phonet.c 2011-11-12 12:47:14.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 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(unsigned int protocol) { struct phonet_protocol *pp; @@ -74237,7 +75649,7 @@ diff -urNp linux-3.0.9/net/phonet/af_phonet.c linux-3.0.9/net/phonet/af_phonet.c return NULL; 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 = 0; @@ -74246,10 +75658,11 @@ diff -urNp linux-3.0.9/net/phonet/af_phonet.c linux-3.0.9/net/phonet/af_phonet.c return -EINVAL; err = proto_register(pp->prot, 1); -diff -urNp linux-3.0.9/net/phonet/pep.c linux-3.0.9/net/phonet/pep.c ---- linux-3.0.9/net/phonet/pep.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/phonet/pep.c 2011-11-12 12:47:14.000000000 -0500 -@@ -387,7 +387,7 @@ static int pipe_do_rcv(struct sock *sk, +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_buff *skb) case PNS_PEP_CTRL_REQ: if (skb_queue_len(&pn->ctrlreq_queue) >= PNPIPE_CTRLREQ_MAX) { @@ -74258,7 +75671,7 @@ diff -urNp linux-3.0.9/net/phonet/pep.c linux-3.0.9/net/phonet/pep.c break; } __skb_pull(skb, 4); -@@ -408,7 +408,7 @@ static int pipe_do_rcv(struct sock *sk, +@@ -408,7 +408,7 @@ static int pipe_do_rcv(struct sock *sk, struct sk_buff *skb) } if (pn->rx_credits == 0) { @@ -74267,7 +75680,7 @@ diff -urNp linux-3.0.9/net/phonet/pep.c linux-3.0.9/net/phonet/pep.c err = -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, struct sk_buff *skb) } if (pn->rx_credits == 0) { @@ -74276,10 +75689,11 @@ diff -urNp linux-3.0.9/net/phonet/pep.c linux-3.0.9/net/phonet/pep.c err = NET_RX_DROP; break; } -diff -urNp linux-3.0.9/net/phonet/socket.c linux-3.0.9/net/phonet/socket.c ---- linux-3.0.9/net/phonet/socket.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/phonet/socket.c 2011-11-12 12:47:14.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, void *v) pn->resource, sk->sk_state, sk_wmem_alloc_get(sk), sk_rmem_alloc_get(sk), sock_i_uid(sk), sock_i_ino(sk), @@ -74295,9 +75709,10 @@ diff -urNp linux-3.0.9/net/phonet/socket.c linux-3.0.9/net/phonet/socket.c } seq_printf(seq, "%*s\n", 127 - len, ""); return 0; -diff -urNp linux-3.0.9/net/rds/cong.c linux-3.0.9/net/rds/cong.c ---- linux-3.0.9/net/rds/cong.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/cong.c 2011-11-12 12:47:14.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 generation * number, it wakes up the process. @@ -74307,7 +75722,7 @@ diff -urNp linux-3.0.9/net/rds/cong.c linux-3.0.9/net/rds/cong.c /* * 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); @@ -74325,21 +75740,10 @@ diff -urNp linux-3.0.9/net/rds/cong.c linux-3.0.9/net/rds/cong.c if (likely(*recent == gen)) return 0; -diff -urNp linux-3.0.9/net/rds/ib_cm.c linux-3.0.9/net/rds/ib_cm.c ---- linux-3.0.9/net/rds/ib_cm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/ib_cm.c 2011-11-12 12:47:14.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 = 0; - #endif -diff -urNp linux-3.0.9/net/rds/ib.h linux-3.0.9/net/rds/ib.h ---- linux-3.0.9/net/rds/ib.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/ib.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/rds/ib.h b/net/rds/ib.h +index 4297d92..fec3cd4 100644 +--- a/net/rds/ib.h ++++ b/net/rds/ib.h @@ -127,7 +127,7 @@ struct rds_ib_connection { /* sending acks */ unsigned long i_ack_flags; @@ -74349,10 +75753,24 @@ diff -urNp linux-3.0.9/net/rds/ib.h linux-3.0.9/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.0.9/net/rds/ib_recv.c linux-3.0.9/net/rds/ib_recv.c ---- linux-3.0.9/net/rds/ib_recv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/ib_recv.c 2011-11-12 12:47:14.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 fd453dd..6c9f095 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 *conn) + /* 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 = 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) { @@ -74361,7 +75779,7 @@ diff -urNp linux-3.0.9/net/rds/ib_recv.c linux-3.0.9/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(); @@ -74370,21 +75788,10 @@ diff -urNp linux-3.0.9/net/rds/ib_recv.c linux-3.0.9/net/rds/ib_recv.c } #endif -diff -urNp linux-3.0.9/net/rds/iw_cm.c linux-3.0.9/net/rds/iw_cm.c ---- linux-3.0.9/net/rds/iw_cm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/iw_cm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -664,7 +664,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 = 0; - #endif -diff -urNp linux-3.0.9/net/rds/iw.h linux-3.0.9/net/rds/iw.h ---- linux-3.0.9/net/rds/iw.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/iw.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/rds/iw.h b/net/rds/iw.h +index 9015192..39f60c0 100644 +--- a/net/rds/iw.h ++++ b/net/rds/iw.h @@ -133,7 +133,7 @@ struct rds_iw_connection { /* sending acks */ unsigned long i_ack_flags; @@ -74394,10 +75801,24 @@ diff -urNp linux-3.0.9/net/rds/iw.h linux-3.0.9/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.0.9/net/rds/iw_rdma.c linux-3.0.9/net/rds/iw_rdma.c ---- linux-3.0.9/net/rds/iw_rdma.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/iw_rdma.c 2011-11-12 12:47:14.000000000 -0500 -@@ -182,6 +182,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 c12db66..3c24d8a 100644 +--- a/net/rds/iw_cm.c ++++ b/net/rds/iw_cm.c +@@ -664,7 +664,7 @@ void rds_iw_conn_shutdown(struct rds_connection *conn) + /* 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 = 0; + #endif +diff --git a/net/rds/iw_rdma.c b/net/rds/iw_rdma.c +index 6deaa77..df475d9 100644 +--- a/net/rds/iw_rdma.c ++++ b/net/rds/iw_rdma.c +@@ -182,6 +182,8 @@ int rds_iw_update_cm_id(struct rds_iw_device *rds_iwdev, struct rdma_cm_id *cm_i struct rdma_cm_id *pcm_id; int rc; @@ -74406,10 +75827,11 @@ diff -urNp linux-3.0.9/net/rds/iw_rdma.c linux-3.0.9/net/rds/iw_rdma.c src_addr = (struct sockaddr_in *)&cm_id->route.addr.src_addr; dst_addr = (struct sockaddr_in *)&cm_id->route.addr.dst_addr; -diff -urNp linux-3.0.9/net/rds/iw_recv.c linux-3.0.9/net/rds/iw_recv.c ---- linux-3.0.9/net/rds/iw_recv.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/iw_recv.c 2011-11-12 12:47:14.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) { @@ -74418,7 +75840,7 @@ diff -urNp linux-3.0.9/net/rds/iw_recv.c linux-3.0.9/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(); @@ -74427,10 +75849,11 @@ diff -urNp linux-3.0.9/net/rds/iw_recv.c linux-3.0.9/net/rds/iw_recv.c } #endif -diff -urNp linux-3.0.9/net/rds/tcp.c linux-3.0.9/net/rds/tcp.c ---- linux-3.0.9/net/rds/tcp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/tcp.c 2011-11-12 12:47:14.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 = 1; set_fs(KERNEL_DS); @@ -74439,10 +75862,11 @@ diff -urNp linux-3.0.9/net/rds/tcp.c linux-3.0.9/net/rds/tcp.c sizeof(val)); set_fs(oldfs); } -diff -urNp linux-3.0.9/net/rds/tcp_send.c linux-3.0.9/net/rds/tcp_send.c ---- linux-3.0.9/net/rds/tcp_send.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rds/tcp_send.c 2011-11-12 12:47:14.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) oldfs = get_fs(); set_fs(KERNEL_DS); @@ -74451,10 +75875,11 @@ diff -urNp linux-3.0.9/net/rds/tcp_send.c linux-3.0.9/net/rds/tcp_send.c sizeof(val)); set_fs(oldfs); } -diff -urNp linux-3.0.9/net/rxrpc/af_rxrpc.c linux-3.0.9/net/rxrpc/af_rxrpc.c ---- linux-3.0.9/net/rxrpc/af_rxrpc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/af_rxrpc.c 2011-11-12 12:47:14.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; /* current debugging ID */ @@ -74463,10 +75888,11 @@ diff -urNp linux-3.0.9/net/rxrpc/af_rxrpc.c linux-3.0.9/net/rxrpc/af_rxrpc.c /* count of skbs currently in use */ atomic_t rxrpc_n_skbs; -diff -urNp linux-3.0.9/net/rxrpc/ar-ack.c linux-3.0.9/net/rxrpc/ar-ack.c ---- linux-3.0.9/net/rxrpc/ar-ack.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-ack.c 2011-11-12 12:47:14.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) _enter("{%d,%d,%d,%d},", call->acks_hard, call->acks_unacked, @@ -74475,7 +75901,7 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-ack.c linux-3.0.9/net/rxrpc/ar-ack.c CIRC_CNT(call->acks_head, call->acks_tail, call->acks_winsz)); stop = 0; -@@ -199,7 +199,7 @@ static void rxrpc_resend(struct rxrpc_ca +@@ -199,7 +199,7 @@ static void rxrpc_resend(struct rxrpc_call *call) /* each Tx packet has a new serial number */ sp->hdr.serial = @@ -74484,7 +75910,7 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-ack.c linux-3.0.9/net/rxrpc/ar-ack.c hdr = (struct rxrpc_header *) txb->head; hdr->serial = 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) { @@ -74502,7 +75928,7 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-ack.c linux-3.0.9/net/rxrpc/ar-ack.c _proto("Rx ACK %%%u { m=%hu f=#%u p=#%u s=%%%u r=%s n=%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 = RX_PROTOCOL_ERROR; u8 *acks = NULL; @@ -74511,7 +75937,7 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-ack.c linux-3.0.9/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; send_ACK_with_skew: @@ -74538,10 +75964,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-ack.c linux-3.0.9/net/rxrpc/ar-ack.c _proto("Tx %s %%%u", rxrpc_pkts[hdr.type], ntohl(hdr.serial)); send_message_2: -diff -urNp linux-3.0.9/net/rxrpc/ar-call.c linux-3.0.9/net/rxrpc/ar-call.c ---- linux-3.0.9/net/rxrpc/ar-call.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-call.c 2011-11-12 12:47:14.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); @@ -74550,10 +75977,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-call.c linux-3.0.9/net/rxrpc/ar-call.c call->state = RXRPC_CALL_CLIENT_SEND_REQUEST; memset(&call->sock_node, 0xed, sizeof(call->sock_node)); -diff -urNp linux-3.0.9/net/rxrpc/ar-connection.c linux-3.0.9/net/rxrpc/ar-connection.c ---- linux-3.0.9/net/rxrpc/ar-connection.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-connection.c 2011-11-12 12:47:14.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_connection(gfp_t gfp) rwlock_init(&conn->lock); spin_lock_init(&conn->state_lock); atomic_set(&conn->usage, 1); @@ -74562,10 +75990,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-connection.c linux-3.0.9/net/rxrpc/ar-connec conn->avail_calls = RXRPC_MAXCALLS; conn->size_align = 4; conn->header_size = sizeof(struct rxrpc_header); -diff -urNp linux-3.0.9/net/rxrpc/ar-connevent.c linux-3.0.9/net/rxrpc/ar-connevent.c ---- linux-3.0.9/net/rxrpc/ar-connevent.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-connevent.c 2011-11-12 12:47:14.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_connection *conn, len = iov[0].iov_len + iov[1].iov_len; @@ -74574,10 +76003,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-connevent.c linux-3.0.9/net/rxrpc/ar-conneve _proto("Tx CONN ABORT %%%u { %d }", ntohl(hdr.serial), abort_code); ret = kernel_sendmsg(conn->trans->local->socket, &msg, iov, 2, len); -diff -urNp linux-3.0.9/net/rxrpc/ar-input.c linux-3.0.9/net/rxrpc/ar-input.c ---- linux-3.0.9/net/rxrpc/ar-input.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-input.c 2011-11-12 12:47:14.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 *call, struct sk_buff *skb) /* track the latest serial number on this connection for ACK packet * information */ serial = ntohl(sp->hdr.serial); @@ -74589,9 +76019,10 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-input.c linux-3.0.9/net/rxrpc/ar-input.c serial); /* request ACK generation for any ACK or DATA packet that requests -diff -urNp linux-3.0.9/net/rxrpc/ar-internal.h linux-3.0.9/net/rxrpc/ar-internal.h ---- linux-3.0.9/net/rxrpc/ar-internal.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-internal.h 2011-11-12 12:47:14.000000000 -0500 +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 */ @@ -74612,7 +76043,7 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-internal.h linux-3.0.9/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_call *call, u32 abort_code) */ extern atomic_t rxrpc_n_skbs; extern __be32 rxrpc_epoch; @@ -74621,10 +76052,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-internal.h linux-3.0.9/net/rxrpc/ar-internal extern struct workqueue_struct *rxrpc_workqueue; /* -diff -urNp linux-3.0.9/net/rxrpc/ar-local.c linux-3.0.9/net/rxrpc/ar-local.c ---- linux-3.0.9/net/rxrpc/ar-local.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-local.c 2011-11-12 12:47:14.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); @@ -74633,10 +76065,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-local.c linux-3.0.9/net/rxrpc/ar-local.c memcpy(&local->srx, srx, sizeof(*srx)); } -diff -urNp linux-3.0.9/net/rxrpc/ar-output.c linux-3.0.9/net/rxrpc/ar-output.c ---- linux-3.0.9/net/rxrpc/ar-output.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-output.c 2011-11-12 12:47:14.000000000 -0500 -@@ -681,9 +681,9 @@ static int rxrpc_send_data(struct kiocb +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 = call->cid; sp->hdr.callNumber = call->call_id; sp->hdr.seq = @@ -74648,10 +76081,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-output.c linux-3.0.9/net/rxrpc/ar-output.c sp->hdr.type = RXRPC_PACKET_TYPE_DATA; sp->hdr.userStatus = 0; sp->hdr.securityIndex = conn->security_ix; -diff -urNp linux-3.0.9/net/rxrpc/ar-peer.c linux-3.0.9/net/rxrpc/ar-peer.c ---- linux-3.0.9/net/rxrpc/ar-peer.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-peer.c 2011-11-12 12:47:14.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 sockaddr_rxrpc *srx, INIT_LIST_HEAD(&peer->error_targets); spin_lock_init(&peer->lock); atomic_set(&peer->usage, 1); @@ -74660,10 +76094,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-peer.c linux-3.0.9/net/rxrpc/ar-peer.c memcpy(&peer->srx, srx, sizeof(*srx)); rxrpc_assess_MTU_size(peer); -diff -urNp linux-3.0.9/net/rxrpc/ar-proc.c linux-3.0.9/net/rxrpc/ar-proc.c ---- linux-3.0.9/net/rxrpc/ar-proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-proc.c 2011-11-12 12:47:14.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), @@ -74674,10 +76109,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-proc.c linux-3.0.9/net/rxrpc/ar-proc.c return 0; } -diff -urNp linux-3.0.9/net/rxrpc/ar-transport.c linux-3.0.9/net/rxrpc/ar-transport.c ---- linux-3.0.9/net/rxrpc/ar-transport.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/ar-transport.c 2011-11-12 12:47:14.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(struct rxrpc_local *local, spin_lock_init(&trans->client_lock); rwlock_init(&trans->conn_lock); atomic_set(&trans->usage, 1); @@ -74686,10 +76122,11 @@ diff -urNp linux-3.0.9/net/rxrpc/ar-transport.c linux-3.0.9/net/rxrpc/ar-transpo if (peer->srx.transport.family == AF_INET) { switch (peer->srx.transport_type) { -diff -urNp linux-3.0.9/net/rxrpc/rxkad.c linux-3.0.9/net/rxrpc/rxkad.c ---- linux-3.0.9/net/rxrpc/rxkad.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/rxrpc/rxkad.c 2011-11-12 12:47:14.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; @@ -74698,7 +76135,7 @@ diff -urNp linux-3.0.9/net/rxrpc/rxkad.c linux-3.0.9/net/rxrpc/rxkad.c sp = rxrpc_skb(skb); _enter(""); -@@ -338,6 +340,8 @@ static int rxkad_verify_packet_auth(cons +@@ -338,6 +340,8 @@ static int rxkad_verify_packet_auth(const struct rxrpc_call *call, u16 check; int nsg; @@ -74707,7 +76144,7 @@ diff -urNp linux-3.0.9/net/rxrpc/rxkad.c linux-3.0.9/net/rxrpc/rxkad.c _enter(""); sp = rxrpc_skb(skb); -@@ -610,7 +614,7 @@ static int rxkad_issue_challenge(struct +@@ -610,7 +614,7 @@ static int rxkad_issue_challenge(struct rxrpc_connection *conn) len = iov[0].iov_len + iov[1].iov_len; @@ -74716,7 +76153,7 @@ diff -urNp linux-3.0.9/net/rxrpc/rxkad.c linux-3.0.9/net/rxrpc/rxkad.c _proto("Tx CHALLENGE %%%u", ntohl(hdr.serial)); ret = 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_connection *conn, len = iov[0].iov_len + iov[1].iov_len + iov[2].iov_len; @@ -74725,10 +76162,11 @@ diff -urNp linux-3.0.9/net/rxrpc/rxkad.c linux-3.0.9/net/rxrpc/rxkad.c _proto("Tx RESPONSE %%%u", ntohl(hdr->serial)); ret = kernel_sendmsg(conn->trans->local->socket, &msg, iov, 3, len); -diff -urNp linux-3.0.9/net/sctp/proc.c linux-3.0.9/net/sctp/proc.c ---- linux-3.0.9/net/sctp/proc.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sctp/proc.c 2011-11-12 12:47:14.000000000 -0500 -@@ -318,7 +318,8 @@ static int sctp_assocs_seq_show(struct s +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 ", @@ -74738,10 +76176,11 @@ diff -urNp linux-3.0.9/net/sctp/proc.c linux-3.0.9/net/sctp/proc.c assoc->state, hash, assoc->assoc_id, assoc->sndbuf_used, -diff -urNp linux-3.0.9/net/sctp/socket.c linux-3.0.9/net/sctp/socket.c ---- linux-3.0.9/net/sctp/socket.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sctp/socket.c 2011-11-12 12:47:14.000000000 -0500 -@@ -4452,7 +4452,7 @@ static int sctp_getsockopt_peer_addrs(st +diff --git a/net/sctp/socket.c b/net/sctp/socket.c +index d3ccf79..e7f4687 100644 +--- a/net/sctp/socket.c ++++ b/net/sctp/socket.c +@@ -4452,7 +4452,7 @@ static int sctp_getsockopt_peer_addrs(struct sock *sk, int len, addrlen = sctp_get_af_specific(temp.sa.sa_family)->sockaddr_len; if (space_left < addrlen) return -ENOMEM; @@ -74750,9 +76189,10 @@ diff -urNp linux-3.0.9/net/sctp/socket.c linux-3.0.9/net/sctp/socket.c return -EFAULT; to += addrlen; cnt++; -diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c ---- linux-3.0.9/net/socket.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/socket.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/socket.c b/net/socket.c +index 1ad42d3..df6cb46 100644 +--- a/net/socket.c ++++ b/net/socket.c @@ -88,6 +88,7 @@ #include <linux/nsproxy.h> #include <linux/magic.h> @@ -74770,7 +76210,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/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 *iov, 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_system_type *fs_type, &sockfs_dentry_operations, SOCKFS_MAGIC); } @@ -74779,7 +76219,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c static struct file_system_type sock_fs_type = { .name = "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 >= SOCK_MAX) return -EINVAL; @@ -74788,7 +76228,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c /* Compatibility. -@@ -1319,6 +1324,16 @@ SYSCALL_DEFINE3(socket, int, family, int +@@ -1319,6 +1324,16 @@ SYSCALL_DEFINE3(socket, int, family, int, type, int, protocol) if (SOCK_NONBLOCK != O_NONBLOCK && (flags & SOCK_NONBLOCK)) flags = (flags & ~SOCK_NONBLOCK) | O_NONBLOCK; @@ -74805,7 +76245,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c retval = 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 = move_addr_to_kernel(umyaddr, addrlen, (struct sockaddr *)&address); if (err >= 0) { @@ -74820,7 +76260,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c err = 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 __user *, umyaddr, int, addrlen) (struct sockaddr *) &address, addrlen); } @@ -74828,7 +76268,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/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 = somaxconn; @@ -74849,7 +76289,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/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 = sock->type; newsock->ops = sock->ops; @@ -74868,7 +76308,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/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 = newfd; @@ -74877,7 +76317,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/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; @@ -74885,7 +76325,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c struct sockaddr_storage address; int err, fput_needed; -@@ -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; @@ -74903,7 +76343,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c err = 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, struct msghdr __user *msg, unsigned char *ctl_buf = ctl; int err, ctl_len, iov_size, total_len; @@ -74912,7 +76352,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c err = -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, struct msghdr __user *msg, * checking falls down on this. */ if (copy_from_user(ctl_buf, @@ -74921,7 +76361,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c ctl_len)) goto out_freectl; msg_sys->msg_control = ctl_buf; -@@ -2120,7 +2182,7 @@ static int __sys_recvmsg(struct socket * +@@ -2120,7 +2182,7 @@ static int __sys_recvmsg(struct socket *sock, struct msghdr __user *msg, * kernel msghdr to use the kernel address space) */ @@ -74930,7 +76370,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c uaddr_len = COMPAT_NAMELEN(msg); if (MSG_CMSG_COMPAT & flags) { err = 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 compat_ifreq __user *ifr32) } ifr = compat_alloc_user_space(buf_size); @@ -74939,7 +76379,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c 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)); if (copy_in_user(rxnfc, compat_rxnfc, @@ -74956,7 +76396,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/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) if (convert_out) { if (copy_in_user(compat_rxnfc, rxnfc, @@ -74973,7 +76413,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/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 int cmd, old_fs = get_fs(); set_fs(KERNEL_DS); err = dev_ioctl(net, cmd, @@ -74982,7 +76422,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c set_fs(old_fs); return err; -@@ -2973,7 +3035,7 @@ static int compat_sioc_ifmap(struct net +@@ -2973,7 +3035,7 @@ static int compat_sioc_ifmap(struct net *net, unsigned int cmd, old_fs = get_fs(); set_fs(KERNEL_DS); @@ -74991,7 +76431,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c set_fs(old_fs); if (cmd == 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 socket *sock, ret |= __get_user(rtdev, &(ur4->rt_dev)); if (rtdev) { ret |= copy_from_user(devname, compat_ptr(rtdev), 15); @@ -75000,7 +76440,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c devname[15] = 0; } else r4.rt_dev = NULL; -@@ -3318,8 +3380,8 @@ int kernel_getsockopt(struct socket *soc +@@ -3318,8 +3380,8 @@ int kernel_getsockopt(struct socket *sock, int level, int optname, int __user *uoptlen; int err; @@ -75011,7 +76451,7 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c set_fs(KERNEL_DS); if (level == SOL_SOCKET) -@@ -3339,7 +3401,7 @@ int kernel_setsockopt(struct socket *soc +@@ -3339,7 +3401,7 @@ int kernel_setsockopt(struct socket *sock, int level, int optname, char __user *uoptval; int err; @@ -75020,10 +76460,11 @@ diff -urNp linux-3.0.9/net/socket.c linux-3.0.9/net/socket.c set_fs(KERNEL_DS); if (level == SOL_SOCKET) -diff -urNp linux-3.0.9/net/sunrpc/sched.c linux-3.0.9/net/sunrpc/sched.c ---- linux-3.0.9/net/sunrpc/sched.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sunrpc/sched.c 2011-11-12 12:47:14.000000000 -0500 -@@ -234,9 +234,9 @@ static int rpc_wait_bit_killable(void *w +diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c +index 4814e24..be718fe 100644 +--- a/net/sunrpc/sched.c ++++ b/net/sunrpc/sched.c +@@ -234,9 +234,9 @@ static int rpc_wait_bit_killable(void *word) #ifdef RPC_DEBUG static void rpc_task_set_debuginfo(struct rpc_task *task) { @@ -75035,10 +76476,11 @@ diff -urNp linux-3.0.9/net/sunrpc/sched.c linux-3.0.9/net/sunrpc/sched.c } #else static inline void rpc_task_set_debuginfo(struct rpc_task *task) -diff -urNp linux-3.0.9/net/sunrpc/svcsock.c linux-3.0.9/net/sunrpc/svcsock.c ---- linux-3.0.9/net/sunrpc/svcsock.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sunrpc/svcsock.c 2011-11-12 12:47:14.000000000 -0500 -@@ -392,7 +392,7 @@ static int svc_partial_recvfrom(struct s +diff --git a/net/sunrpc/svcsock.c b/net/sunrpc/svcsock.c +index af04f77..964044e 100644 +--- a/net/sunrpc/svcsock.c ++++ b/net/sunrpc/svcsock.c +@@ -392,7 +392,7 @@ static int svc_partial_recvfrom(struct svc_rqst *rqstp, int buflen, unsigned int base) { size_t save_iovlen; @@ -75047,10 +76489,11 @@ diff -urNp linux-3.0.9/net/sunrpc/svcsock.c linux-3.0.9/net/sunrpc/svcsock.c unsigned int i; int ret; -diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma.c linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma.c ---- linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma.c 2011-11-12 12:47:14.000000000 -0500 -@@ -61,15 +61,15 @@ unsigned int svcrdma_max_req_size = RPCR +diff --git a/net/sunrpc/xprtrdma/svc_rdma.c b/net/sunrpc/xprtrdma/svc_rdma.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 = RPCRDMA_MAX_REQ_SIZE; static unsigned int min_max_inline = 4096; static unsigned int max_max_inline = 65536; @@ -75075,7 +76518,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma.c linux-3.0.9/net/sunrpc/xpr /* 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 write, len -= *ppos; if (len > *lenp) len = *lenp; @@ -75084,7 +76527,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma.c linux-3.0.9/net/sunrpc/xpr return -EFAULT; *lenp = len; *ppos += len; -@@ -150,63 +150,63 @@ static ctl_table svcrdma_parm_table[] = +@@ -150,63 +150,63 @@ static ctl_table svcrdma_parm_table[] = { { .procname = "rdma_stat_read", .data = &rdma_stat_read, @@ -75157,9 +76600,10 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma.c linux-3.0.9/net/sunrpc/xpr .mode = 0644, .proc_handler = read_reset_stat, }, -diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c ---- linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c b/net/sunrpc/xprtrdma/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; @@ -75169,7 +76613,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c linux-3.0.9/net/s if (read_wr.num_sge < chl_map->ch[ch_no].count) { chl_map->ch[ch_no].count -= 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 { @@ -75178,7 +76622,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c linux-3.0.9/net/s clear_bit(XPT_DATA, &xprt->xpt_flags); ctxt = 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=%p on xprt=%p, rqstp=%p, status=%d\n", ctxt, rdma_xprt, rqstp, ctxt->wc_status); BUG_ON(ctxt->wc_status != IB_WC_SUCCESS); @@ -75187,10 +76631,11 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c linux-3.0.9/net/s /* Build up the XDR from the receive buffers. */ rdma_build_arg_xdr(rqstp, ctxt, ctxt->byte_len); -diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_sendto.c linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_sendto.c ---- linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_sendto.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_sendto.c 2011-11-12 12:47:14.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, struct svc_rqst *rqstp, write_wr.wr.rdma.remote_addr = to; /* Post It */ @@ -75199,10 +76644,11 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_sendto.c linux-3.0.9/net/sun if (svc_rdma_send(xprt, &write_wr)) goto err; return 0; -diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c ---- linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c 2011-11-12 12:47:14.000000000 -0500 -@@ -298,7 +298,7 @@ static void rq_cq_reap(struct svcxprt_rd +diff --git a/net/sunrpc/xprtrdma/svc_rdma_transport.c b/net/sunrpc/xprtrdma/svc_rdma_transport.c +index c3c232a..298b1b8 100644 +--- a/net/sunrpc/xprtrdma/svc_rdma_transport.c ++++ b/net/sunrpc/xprtrdma/svc_rdma_transport.c +@@ -298,7 +298,7 @@ static void rq_cq_reap(struct svcxprt_rdma *xprt) return; ib_req_notify_cq(xprt->sc_rq_cq, IB_CQ_NEXT_COMP); @@ -75211,7 +76657,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c linux-3.0.9/net/ while ((ret = ib_poll_cq(xprt->sc_rq_cq, 1, &wc)) > 0) { ctxt = (struct svc_rdma_op_ctxt *)(unsigned long)wc.wr_id; -@@ -320,7 +320,7 @@ static void rq_cq_reap(struct svcxprt_rd +@@ -320,7 +320,7 @@ static void rq_cq_reap(struct svcxprt_rdma *xprt) } if (ctxt) @@ -75220,7 +76666,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c linux-3.0.9/net/ set_bit(XPT_DATA, &xprt->sc_xprt.xpt_flags); /* -@@ -392,7 +392,7 @@ static void sq_cq_reap(struct svcxprt_rd +@@ -392,7 +392,7 @@ static void sq_cq_reap(struct svcxprt_rdma *xprt) return; ib_req_notify_cq(xprt->sc_sq_cq, IB_CQ_NEXT_COMP); @@ -75229,7 +76675,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c linux-3.0.9/net/ while ((ret = ib_poll_cq(cq, 1, &wc)) > 0) { if (wc.status != IB_WC_SUCCESS) /* Close the transport */ -@@ -410,7 +410,7 @@ static void sq_cq_reap(struct svcxprt_rd +@@ -410,7 +410,7 @@ static void sq_cq_reap(struct svcxprt_rdma *xprt) } if (ctxt) @@ -75238,7 +76684,7 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c linux-3.0.9/net/ } static void sq_comp_handler(struct ib_cq *cq, void *cq_context) -@@ -1272,7 +1272,7 @@ int svc_rdma_send(struct svcxprt_rdma *x +@@ -1272,7 +1272,7 @@ int svc_rdma_send(struct svcxprt_rdma *xprt, struct 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); @@ -75247,10 +76693,11 @@ diff -urNp linux-3.0.9/net/sunrpc/xprtrdma/svc_rdma_transport.c linux-3.0.9/net/ /* See if we can opportunistically reap SQ WR to make room */ sq_cq_reap(xprt); -diff -urNp linux-3.0.9/net/sysctl_net.c linux-3.0.9/net/sysctl_net.c ---- linux-3.0.9/net/sysctl_net.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/sysctl_net.c 2011-11-12 12:47:14.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. */ @@ -75259,10 +76706,11 @@ diff -urNp linux-3.0.9/net/sysctl_net.c linux-3.0.9/net/sysctl_net.c int mode = (table->mode >> 6) & 7; return (mode << 6) | (mode << 3) | mode; } -diff -urNp linux-3.0.9/net/tipc/link.c linux-3.0.9/net/tipc/link.c ---- linux-3.0.9/net/tipc/link.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/tipc/link.c 2011-11-12 12:47:14.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 5ed4b4f..40edcb7 100644 +--- a/net/tipc/link.c ++++ b/net/tipc/link.c +@@ -1170,7 +1170,7 @@ static int link_send_sections_long(struct tipc_port *sender, struct tipc_msg fragm_hdr; struct sk_buff *buf, *buf_chain, *prev; u32 fragm_crs, fragm_rest, hsz, sect_rest; @@ -75289,10 +76737,11 @@ diff -urNp linux-3.0.9/net/tipc/link.c linux-3.0.9/net/tipc/link.c sect_crs += sz; sect_rest -= sz; fragm_crs += sz; -diff -urNp linux-3.0.9/net/tipc/msg.c linux-3.0.9/net/tipc/msg.c ---- linux-3.0.9/net/tipc/msg.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/tipc/msg.c 2011-11-12 12:47:14.000000000 -0500 -@@ -101,7 +101,7 @@ int tipc_msg_build(struct tipc_msg *hdr, +diff --git a/net/tipc/msg.c b/net/tipc/msg.c +index 03e57bf..62331b6 100644 +--- a/net/tipc/msg.c ++++ b/net/tipc/msg.c +@@ -101,7 +101,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, @@ -75301,10 +76750,11 @@ diff -urNp linux-3.0.9/net/tipc/msg.c linux-3.0.9/net/tipc/msg.c msg_sect[cnt].iov_len); pos += msg_sect[cnt].iov_len; } -diff -urNp linux-3.0.9/net/tipc/subscr.c linux-3.0.9/net/tipc/subscr.c ---- linux-3.0.9/net/tipc/subscr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/tipc/subscr.c 2011-11-12 12:47:14.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 *sub, { struct iovec msg_sect; @@ -75313,10 +76763,11 @@ diff -urNp linux-3.0.9/net/tipc/subscr.c linux-3.0.9/net/tipc/subscr.c msg_sect.iov_len = sizeof(struct tipc_event); sub->evt.event = htohl(event, sub->swap); -diff -urNp linux-3.0.9/net/unix/af_unix.c linux-3.0.9/net/unix/af_unix.c ---- linux-3.0.9/net/unix/af_unix.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/unix/af_unix.c 2011-11-12 12:47:14.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 0722a25..ded9e9b 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 = -ECONNREFUSED; if (!S_ISSOCK(inode->i_mode)) goto put_fail; @@ -75329,7 +76780,7 @@ diff -urNp linux-3.0.9/net/unix/af_unix.c linux-3.0.9/net/unix/af_unix.c u = 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 = unix_sk(u)->dentry; @@ -75343,7 +76794,7 @@ diff -urNp linux-3.0.9/net/unix/af_unix.c linux-3.0.9/net/unix/af_unix.c if (dentry) touch_atime(unix_sk(u)->mnt, dentry); } else -@@ -872,11 +885,18 @@ static int unix_bind(struct socket *sock +@@ -872,11 +885,18 @@ static int unix_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len) err = security_path_mknod(&nd.path, dentry, mode, 0); if (err) goto out_mknod_drop_write; @@ -75362,9 +76813,10 @@ diff -urNp linux-3.0.9/net/unix/af_unix.c linux-3.0.9/net/unix/af_unix.c mutex_unlock(&nd.path.dentry->d_inode->i_mutex); dput(nd.path.dentry); nd.path.dentry = dentry; -diff -urNp linux-3.0.9/net/wireless/core.h linux-3.0.9/net/wireless/core.h ---- linux-3.0.9/net/wireless/core.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/wireless/core.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/net/wireless/core.h b/net/wireless/core.h +index a570ff9..d209909 100644 +--- a/net/wireless/core.h ++++ b/net/wireless/core.h @@ -27,7 +27,7 @@ struct cfg80211_registered_device { struct mutex mtx; @@ -75374,10 +76826,11 @@ diff -urNp linux-3.0.9/net/wireless/core.h linux-3.0.9/net/wireless/core.h struct rfkill *rfkill; struct work_struct rfkill_sync; -diff -urNp linux-3.0.9/net/wireless/wext-core.c linux-3.0.9/net/wireless/wext-core.c ---- linux-3.0.9/net/wireless/wext-core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/wireless/wext-core.c 2011-11-12 12:47:14.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, */ /* Support for very large requests */ @@ -75387,7 +76840,7 @@ diff -urNp linux-3.0.9/net/wireless/wext-core.c linux-3.0.9/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, } } @@ -75410,10 +76863,11 @@ diff -urNp linux-3.0.9/net/wireless/wext-core.c linux-3.0.9/net/wireless/wext-co err = handler(dev, info, (union iwreq_data *) iwp, extra); iwp->length += essid_compat; -diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c ---- linux-3.0.9/net/xfrm/xfrm_policy.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/xfrm/xfrm_policy.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 5ce74a3..670e6b2 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 *policy) { policy->walk.dead = 1; @@ -75422,7 +76876,7 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c 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]++; @@ -75440,7 +76894,7 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c xfrm_dst_alloc_copy(void **target, const void *src, int size) { if (!*target) { -@@ -1540,7 +1540,7 @@ xfrm_dst_alloc_copy(void **target, const +@@ -1540,7 +1540,7 @@ xfrm_dst_alloc_copy(void **target, const void *src, int size) return 0; } @@ -75449,7 +76903,7 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c xfrm_dst_update_parent(struct dst_entry *dst, const struct xfrm_selector *sel) { #ifdef CONFIG_XFRM_SUB_POLICY -@@ -1552,7 +1552,7 @@ xfrm_dst_update_parent(struct dst_entry +@@ -1552,7 +1552,7 @@ xfrm_dst_update_parent(struct dst_entry *dst, const struct xfrm_selector *sel) #endif } @@ -75458,7 +76912,7 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c xfrm_dst_update_origin(struct dst_entry *dst, const struct flowi *fl) { #ifdef CONFIG_XFRM_SUB_POLICY -@@ -1646,7 +1646,7 @@ xfrm_resolve_and_create_bundle(struct xf +@@ -1646,7 +1646,7 @@ xfrm_resolve_and_create_bundle(struct xfrm_policy **pols, int num_pols, xdst->num_pols = num_pols; memcpy(xdst->pols, pols, sizeof(struct xfrm_policy*) * num_pols); @@ -75467,7 +76921,7 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c return xdst; } -@@ -2333,7 +2333,7 @@ static int xfrm_bundle_ok(struct xfrm_ds +@@ -2333,7 +2333,7 @@ static int xfrm_bundle_ok(struct xfrm_dst *first) if (xdst->xfrm_genid != dst->xfrm->genid) return 0; if (xdst->num_pols > 0 && @@ -75476,7 +76930,7 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c return 0; mtu = dst_mtu(dst->child); -@@ -2861,7 +2861,7 @@ static int xfrm_policy_migrate(struct xf +@@ -2861,7 +2861,7 @@ static int xfrm_policy_migrate(struct xfrm_policy *pol, sizeof(pol->xfrm_vec[i].saddr)); pol->xfrm_vec[i].encap_family = mp->new_family; /* flush bundles */ @@ -75485,10 +76939,11 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_policy.c linux-3.0.9/net/xfrm/xfrm_policy.c } } -diff -urNp linux-3.0.9/net/xfrm/xfrm_user.c linux-3.0.9/net/xfrm/xfrm_user.c ---- linux-3.0.9/net/xfrm/xfrm_user.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/net/xfrm/xfrm_user.c 2011-11-12 12:47:14.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 c658cb3..96c6847 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 *xp, struct sk_buff *skb) struct xfrm_user_tmpl vec[XFRM_MAX_DEPTH]; int i; @@ -75497,7 +76952,7 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_user.c linux-3.0.9/net/xfrm/xfrm_user.c if (xp->xfrm_nr == 0) return 0; -@@ -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, struct nlmsghdr *nlh, int err; int n = 0; @@ -75506,10 +76961,58 @@ diff -urNp linux-3.0.9/net/xfrm/xfrm_user.c linux-3.0.9/net/xfrm/xfrm_user.c if (attrs[XFRMA_MIGRATE] == NULL) return -EINVAL; -diff -urNp linux-3.0.9/scripts/basic/fixdep.c linux-3.0.9/scripts/basic/fixdep.c ---- linux-3.0.9/scripts/basic/fixdep.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/basic/fixdep.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 + + # 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 + +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 := $(addprefix $(obj)/,$(subdir-ymn)) + __clean-files := $(extra-y) $(always) \ + $(targets) $(clean-files) \ + $(host-progs) \ +- $(hostprogs-y) $(hostprogs-m) $(hostprogs-) ++ $(hostprogs-y) $(hostprogs-m) $(hostprogs-) \ ++ $(hostlibs-y) $(hostlibs-m) $(hostlibs-) + + __clean-files := $(filter-out $(no-clean-files), $(__clean-files)) + +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 + + __hostprogs := $(sort $(hostprogs-y) $(hostprogs-m)) ++__hostlibs := $(sort $(hostlibs-y) $(hostlibs-m)) + + # C code + # Executables compiled from a single .c file +@@ -54,6 +55,7 @@ host-cxxobjs := $(sort $(foreach m,$(host-cxxmulti),$($(m)-cxxobjs))) + # Shared libaries (only .c supported) + # Shared libraries (.so) - all .so files referenced in "xxx-objs" + host-cshlib := $(sort $(filter %.so, $(host-cobjs))) ++host-cshlib += $(sort $(filter %.so, $(__hostlibs))) + # Remove .so files from "xxx-objs" + host-cobjs := $(filter-out %.so,$(host-cobjs)) + +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, unsigned int sz) /* * Lookup a value in the configuration string. */ @@ -75531,7 +77034,7 @@ diff -urNp linux-3.0.9/scripts/basic/fixdep.c linux-3.0.9/scripts/basic/fixdep.c 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) static void parse_config_file(const char *map, size_t len) { @@ -75552,60 +77055,19 @@ diff -urNp linux-3.0.9/scripts/basic/fixdep.c linux-3.0.9/scripts/basic/fixdep.c if (*p != INT_CONF) { fprintf(stderr, "fixdep: sizeof(int) != 4 or wrong endianess? %#x\n", -diff -urNp linux-3.0.9/scripts/gcc-plugin.sh linux-3.0.9/scripts/gcc-plugin.sh ---- linux-3.0.9/scripts/gcc-plugin.sh 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/scripts/gcc-plugin.sh 2011-11-12 12:47:14.000000000 -0500 +diff --git a/scripts/gcc-plugin.sh b/scripts/gcc-plugin.sh +new file mode 100644 +index 0000000..a0ef3e4 +--- /dev/null ++++ b/scripts/gcc-plugin.sh @@ -0,0 +1,2 @@ +#!/bin/sh +echo "#include \"gcc-plugin.h\"\n#include \"rtl.h\"" | $1 -x c -shared - -o /dev/null -I`$2 -print-file-name=plugin`/include >/dev/null 2>&1 && echo "y" -diff -urNp linux-3.0.9/scripts/Makefile.build linux-3.0.9/scripts/Makefile.build ---- linux-3.0.9/scripts/Makefile.build 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/Makefile.build 2011-11-12 12:47:14.000000000 -0500 -@@ -109,7 +109,7 @@ endif - endif - - # 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 - -diff -urNp linux-3.0.9/scripts/Makefile.clean linux-3.0.9/scripts/Makefile.clean ---- linux-3.0.9/scripts/Makefile.clean 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/Makefile.clean 2011-11-12 12:47:14.000000000 -0500 -@@ -43,7 +43,8 @@ subdir-ymn := $(addprefix $(obj)/,$(subd - __clean-files := $(extra-y) $(always) \ - $(targets) $(clean-files) \ - $(host-progs) \ -- $(hostprogs-y) $(hostprogs-m) $(hostprogs-) -+ $(hostprogs-y) $(hostprogs-m) $(hostprogs-) \ -+ $(hostlibs-y) $(hostlibs-m) $(hostlibs-) - - __clean-files := $(filter-out $(no-clean-files), $(__clean-files)) - -diff -urNp linux-3.0.9/scripts/Makefile.host linux-3.0.9/scripts/Makefile.host ---- linux-3.0.9/scripts/Makefile.host 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/Makefile.host 2011-11-12 12:47:14.000000000 -0500 -@@ -31,6 +31,7 @@ - # Note: Shared libraries consisting of C++ files are not supported - - __hostprogs := $(sort $(hostprogs-y) $(hostprogs-m)) -+__hostlibs := $(sort $(hostlibs-y) $(hostlibs-m)) - - # C code - # Executables compiled from a single .c file -@@ -54,6 +55,7 @@ host-cxxobjs := $(sort $(foreach m,$(hos - # Shared libaries (only .c supported) - # Shared libraries (.so) - all .so files referenced in "xxx-objs" - host-cshlib := $(sort $(filter %.so, $(host-cobjs))) -+host-cshlib += $(sort $(filter %.so, $(__hostlibs))) - # Remove .so files from "xxx-objs" - host-cobjs := $(filter-out %.so,$(host-cobjs)) - -diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/scripts/mod/file2alias.c ---- linux-3.0.9/scripts/mod/file2alias.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/mod/file2alias.c 2011-11-12 12:47:14.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) { @@ -75614,7 +77076,7 @@ diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/scripts/mod/file2ali if (size % id_size || size < id_size) { if (cross_build != 0) -@@ -102,7 +102,7 @@ static void device_id_check(const char * +@@ -102,7 +102,7 @@ static void device_id_check(const char *modname, const char *device_id, /* USB is special because the bcdDevice can be matched against a numeric range */ /* Looks like "usb:vNpNdNdcNdscNdpNicNiscNipN" */ static void do_usb_entry(struct usb_device_id *id, @@ -75623,7 +77085,7 @@ diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/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; @@ -75632,7 +77094,7 @@ diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/scripts/mod/file2ali id->match_flags = TO_NATIVE(id->match_flags); id->idVendor = 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, unsigned long size, for (i = 0; i < count; i++) { const char *id = (char *)devs[i].id; char acpi_id[sizeof(devs[0].id)]; @@ -75641,7 +77103,7 @@ diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/scripts/mod/file2ali 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, unsigned long size, for (j = 0; j < PNP_MAX_DEVICES; j++) { const char *id = (char *)card->devs[j].id; @@ -75650,7 +77112,7 @@ diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/scripts/mod/file2ali int dup = 0; 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, unsigned long size, /* add an individual alias for every device entry */ if (!dup) { char acpi_id[sizeof(card->devs[0].id)]; @@ -75659,7 +77121,7 @@ diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/scripts/mod/file2ali 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) { @@ -75668,9 +77130,10 @@ diff -urNp linux-3.0.9/scripts/mod/file2alias.c linux-3.0.9/scripts/mod/file2ali sprintf(alias, "dmi*"); -diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c ---- linux-3.0.9/scripts/mod/modpost.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/mod/modpost.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c +index 413c536..db536ed 100644 +--- a/scripts/mod/modpost.c ++++ b/scripts/mod/modpost.c @@ -892,6 +892,7 @@ enum mismatch { ANY_INIT_TO_ANY_EXIT, ANY_EXIT_TO_ANY_INIT, @@ -75679,7 +77142,7 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c }; struct sectioncheck { -@@ -1000,6 +1001,12 @@ const struct sectioncheck sectioncheck[] +@@ -1000,6 +1001,12 @@ const struct sectioncheck sectioncheck[] = { .tosec = { INIT_SECTIONS, EXIT_SECTIONS, NULL }, .mismatch = EXPORT_TO_INIT_EXIT, .symbol_white_list = { DEFAULT_SYMBOL_WHITE_LIST, NULL }, @@ -75692,7 +77155,7 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c } }; -@@ -1122,10 +1129,10 @@ static Elf_Sym *find_elf_symbol(struct e +@@ -1122,10 +1129,10 @@ static Elf_Sym *find_elf_symbol(struct elf_info *elf, Elf64_Sword addr, continue; if (ELF_ST_TYPE(sym->st_info) == STT_SECTION) continue; @@ -75705,7 +77168,7 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c if (d < 0) d = addr - sym->st_value; if (d < distance) { -@@ -1404,6 +1411,14 @@ static void report_sec_mismatch(const ch +@@ -1404,6 +1411,14 @@ static void report_sec_mismatch(const char *modname, tosym, prl_to, prl_to, tosym); free(prl_to); break; @@ -75720,7 +77183,7 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c } fprintf(stderr, "\n"); } -@@ -1629,7 +1644,7 @@ static void section_rel(const char *modn +@@ -1629,7 +1644,7 @@ static void section_rel(const char *modname, struct elf_info *elf, static void check_sec_ref(struct module *mod, const char *modname, struct elf_info *elf) { @@ -75729,7 +77192,7 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c Elf_Shdr *sechdrs = elf->sechdrs; /* Walk through all sections */ -@@ -1727,7 +1742,7 @@ void __attribute__((format(printf, 2, 3) +@@ -1727,7 +1742,7 @@ void __attribute__((format(printf, 2, 3))) buf_printf(struct buffer *buf, va_end(ap); } @@ -75738,7 +77201,7 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c { if (buf->size - buf->pos < len) { buf->size += len + SZ; -@@ -1939,7 +1954,7 @@ static void write_if_changed(struct buff +@@ -1939,7 +1954,7 @@ static void write_if_changed(struct buffer *b, const char *fname) if (fstat(fileno(file), &st) < 0) goto close_write; @@ -75747,10 +77210,11 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.c linux-3.0.9/scripts/mod/modpost.c goto close_write; tmp = NOFAIL(malloc(b->pos)); -diff -urNp linux-3.0.9/scripts/mod/modpost.h linux-3.0.9/scripts/mod/modpost.h ---- linux-3.0.9/scripts/mod/modpost.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/mod/modpost.h 2011-11-12 12:47:14.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 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); struct buffer { char *p; @@ -75769,10 +77233,11 @@ diff -urNp linux-3.0.9/scripts/mod/modpost.h linux-3.0.9/scripts/mod/modpost.h struct module { struct module *next; -diff -urNp linux-3.0.9/scripts/mod/sumversion.c linux-3.0.9/scripts/mod/sumversion.c ---- linux-3.0.9/scripts/mod/sumversion.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/mod/sumversion.c 2011-11-12 12:47:14.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, const char *sum, goto out; } @@ -75781,9 +77246,10 @@ diff -urNp linux-3.0.9/scripts/mod/sumversion.c linux-3.0.9/scripts/mod/sumversi warn("writing sum in %s failed: %s\n", filename, strerror(errno)); goto out; -diff -urNp linux-3.0.9/scripts/pnmtologo.c linux-3.0.9/scripts/pnmtologo.c ---- linux-3.0.9/scripts/pnmtologo.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/scripts/pnmtologo.c 2011-11-12 12:47:14.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); @@ -75810,107 +77276,10 @@ diff -urNp linux-3.0.9/scripts/pnmtologo.c linux-3.0.9/scripts/pnmtologo.c logoname); write_hex_cnt = 0; for (i = 0; i < logo_clutsize; i++) { -diff -urNp linux-3.0.9/security/apparmor/lsm.c linux-3.0.9/security/apparmor/lsm.c ---- linux-3.0.9/security/apparmor/lsm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/apparmor/lsm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -621,7 +621,7 @@ static int apparmor_task_setrlimit(struc - return error; - } - --static struct security_operations apparmor_ops = { -+static struct security_operations apparmor_ops __read_only = { - .name = "apparmor", - - .ptrace_access_check = apparmor_ptrace_access_check, -diff -urNp linux-3.0.9/security/commoncap.c linux-3.0.9/security/commoncap.c ---- linux-3.0.9/security/commoncap.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/commoncap.c 2011-11-12 12:47:14.000000000 -0500 -@@ -28,6 +28,7 @@ - #include <linux/prctl.h> - #include <linux/securebits.h> - #include <linux/user_namespace.h> -+#include <net/sock.h> - - /* - * If a non-root user executes a setuid-root binary in -@@ -58,7 +59,7 @@ int cap_netlink_send(struct sock *sk, st - - 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 = current_cred(); - -+ if (gr_acl_enable_at_secure()) -+ return 1; -+ - if (cred->uid != 0) { - if (bprm->cap_effective) - return 1; -diff -urNp linux-3.0.9/security/integrity/ima/ima_api.c linux-3.0.9/security/integrity/ima/ima_api.c ---- linux-3.0.9/security/integrity/ima/ima_api.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/integrity/ima/ima_api.c 2011-11-12 12:47:14.000000000 -0500 -@@ -75,7 +75,7 @@ void ima_add_violation(struct inode *ino - int result; - - /* can overflow, only indicator */ -- atomic_long_inc(&ima_htable.violations); -+ atomic_long_inc_unchecked(&ima_htable.violations); - - entry = kmalloc(sizeof(*entry), GFP_KERNEL); - if (!entry) { -diff -urNp linux-3.0.9/security/integrity/ima/ima_fs.c linux-3.0.9/security/integrity/ima/ima_fs.c ---- linux-3.0.9/security/integrity/ima/ima_fs.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/integrity/ima/ima_fs.c 2011-11-12 12:47:14.000000000 -0500 -@@ -28,12 +28,12 @@ - static int valid_policy = 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; - -- len = scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read(val)); -+ len = scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read_unchecked(val)); - return simple_read_from_buffer(buf, count, ppos, tmpbuf, len); - } - -diff -urNp linux-3.0.9/security/integrity/ima/ima.h linux-3.0.9/security/integrity/ima/ima.h ---- linux-3.0.9/security/integrity/ima/ima.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/integrity/ima/ima.h 2011-11-12 12:47:14.000000000 -0500 -@@ -85,8 +85,8 @@ void ima_add_violation(struct inode *ino - extern spinlock_t ima_queue_lock; - - 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 list */ -+ atomic_long_unchecked_t violations; - struct hlist_head queue[IMA_MEASURE_HTABLE_SIZE]; - }; - extern struct ima_h_table ima_htable; -diff -urNp linux-3.0.9/security/integrity/ima/ima_queue.c linux-3.0.9/security/integrity/ima/ima_queue.c ---- linux-3.0.9/security/integrity/ima/ima_queue.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/integrity/ima/ima_queue.c 2011-11-12 12:47:14.000000000 -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); - -- atomic_long_inc(&ima_htable.len); -+ atomic_long_inc_unchecked(&ima_htable.len); - key = ima_hash_key(entry->digest); - hlist_add_head_rcu(&qe->hnext, &ima_htable.queue[key]); - return 0; -diff -urNp linux-3.0.9/security/Kconfig linux-3.0.9/security/Kconfig ---- linux-3.0.9/security/Kconfig 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/Kconfig 2011-11-12 12:47:14.000000000 -0500 +diff --git a/security/Kconfig b/security/Kconfig +index e0f08b5..9ace91e 100644 +--- a/security/Kconfig ++++ b/security/Kconfig @@ -4,6 +4,558 @@ menu "Security options" @@ -76479,9 +77848,114 @@ diff -urNp linux-3.0.9/security/Kconfig linux-3.0.9/security/Kconfig default 65536 help This is the portion of low virtual memory which should be protected -diff -urNp linux-3.0.9/security/keys/compat.c linux-3.0.9/security/keys/compat.c ---- linux-3.0.9/security/keys/compat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/keys/compat.c 2011-11-12 12:47:14.000000000 -0500 +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_struct *task, + return error; + } + +-static struct security_operations apparmor_ops = { ++static struct security_operations apparmor_ops __read_only = { + .name = "apparmor", + + .ptrace_access_check = 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 <linux/prctl.h> + #include <linux/securebits.h> + #include <linux/user_namespace.h> ++#include <net/sock.h> + + /* + * 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) + + 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 = current_cred(); + ++ if (gr_acl_enable_at_secure()) ++ return 1; ++ + if (cred->uid != 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 unsigned char *filename, + extern spinlock_t ima_queue_lock; + + 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 list */ ++ 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/ima_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 unsigned char *filename, + int result; + + /* can overflow, only indicator */ +- atomic_long_inc(&ima_htable.violations); ++ atomic_long_inc_unchecked(&ima_htable.violations); + + entry = kmalloc(sizeof(*entry), GFP_KERNEL); + if (!entry) { +diff --git a/security/integrity/ima/ima_fs.c b/security/integrity/ima/ima_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 = 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; + +- len = scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read(val)); ++ len = scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read_unchecked(val)); + return simple_read_from_buffer(buf, count, ppos, tmpbuf, len); + } + +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_entry *entry) + INIT_LIST_HEAD(&qe->later); + list_add_tail_rcu(&qe->later, &ima_measurements); + +- atomic_long_inc(&ima_htable.len); ++ atomic_long_inc_unchecked(&ima_htable.len); + key = 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 == 0) goto no_payload_free; @@ -76491,10 +77965,11 @@ diff -urNp linux-3.0.9/security/keys/compat.c linux-3.0.9/security/keys/compat.c if (iov != iovstack) kfree(iov); -diff -urNp linux-3.0.9/security/keys/keyctl.c linux-3.0.9/security/keys/keyctl.c ---- linux-3.0.9/security/keys/keyctl.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/keys/keyctl.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 */ @@ -76503,7 +77978,7 @@ diff -urNp linux-3.0.9/security/keys/keyctl.c linux-3.0.9/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, @@ -76512,7 +77987,7 @@ diff -urNp linux-3.0.9/security/keys/keyctl.c linux-3.0.9/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 = plen }; @@ -76521,7 +77996,7 @@ diff -urNp linux-3.0.9/security/keys/keyctl.c linux-3.0.9/security/keys/keyctl.c } 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 == 0) goto no_payload_free; @@ -76530,10 +78005,11 @@ diff -urNp linux-3.0.9/security/keys/keyctl.c linux-3.0.9/security/keys/keyctl.c if (iov != iovstack) kfree(iov); -diff -urNp linux-3.0.9/security/keys/keyring.c linux-3.0.9/security/keys/keyring.c ---- linux-3.0.9/security/keys/keyring.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/keys/keyring.c 2011-11-12 12:47:14.000000000 -0500 -@@ -215,15 +215,15 @@ static long keyring_read(const struct ke +diff --git a/security/keys/keyring.c b/security/keys/keyring.c +index a06ffab..beb11e8 100644 +--- a/security/keys/keyring.c ++++ b/security/keys/keyring.c +@@ -215,15 +215,15 @@ static long keyring_read(const struct key *keyring, ret = -EFAULT; for (loop = 0; loop < klist->nkeys; loop++) { @@ -76552,10 +78028,11 @@ diff -urNp linux-3.0.9/security/keys/keyring.c linux-3.0.9/security/keys/keyring goto error; buflen -= tmp; -diff -urNp linux-3.0.9/security/min_addr.c linux-3.0.9/security/min_addr.c ---- linux-3.0.9/security/min_addr.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/min_addr.c 2011-11-12 12:47:14.000000000 -0500 -@@ -14,6 +14,7 @@ unsigned long dac_mmap_min_addr = 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 = CONFIG_DEFAULT_MMAP_MIN_ADDR; */ static void update_mmap_min_addr(void) { @@ -76571,10 +78048,11 @@ diff -urNp linux-3.0.9/security/min_addr.c linux-3.0.9/security/min_addr.c } /* -diff -urNp linux-3.0.9/security/security.c linux-3.0.9/security/security.c ---- linux-3.0.9/security/security.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/security.c 2011-11-12 12:47:14.000000000 -0500 -@@ -25,8 +25,8 @@ static __initdata char chosen_lsm[SECURI +diff --git a/security/security.c b/security/security.c +index 4ba6d4c..74efea7 100644 +--- a/security/security.c ++++ b/security/security.c +@@ -25,8 +25,8 @@ static __initdata char chosen_lsm[SECURITY_NAME_MAX + 1] = /* things that live in capability.c */ extern void __init security_fixup_ops(struct security_operations *ops); @@ -76595,9 +78073,10 @@ diff -urNp linux-3.0.9/security/security.c linux-3.0.9/security/security.c } /* Save user chosen LSM */ -diff -urNp linux-3.0.9/security/selinux/hooks.c linux-3.0.9/security/selinux/hooks.c ---- linux-3.0.9/security/selinux/hooks.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/selinux/hooks.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c +index 20219ef..0bff933 100644 +--- a/security/selinux/hooks.c ++++ b/security/selinux/hooks.c @@ -93,7 +93,6 @@ #define NUM_SEL_MNT_OPTS 5 @@ -76606,7 +78085,7 @@ diff -urNp linux-3.0.9/security/selinux/hooks.c linux-3.0.9/security/selinux/hoo /* SECMARK reference count */ atomic_t selinux_secmark_refcount = ATOMIC_INIT(0); -@@ -5454,7 +5453,7 @@ static int selinux_key_getsecurity(struc +@@ -5454,7 +5453,7 @@ static int selinux_key_getsecurity(struct key *key, char **_buffer) #endif @@ -76615,10 +78094,11 @@ diff -urNp linux-3.0.9/security/selinux/hooks.c linux-3.0.9/security/selinux/hoo .name = "selinux", .ptrace_access_check = selinux_ptrace_access_check, -diff -urNp linux-3.0.9/security/selinux/include/xfrm.h linux-3.0.9/security/selinux/include/xfrm.h ---- linux-3.0.9/security/selinux/include/xfrm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/selinux/include/xfrm.h 2011-11-12 12:47:14.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 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, u32 *sid, int ckall); static inline void selinux_xfrm_notify_policyload(void) { @@ -76627,10 +78107,11 @@ diff -urNp linux-3.0.9/security/selinux/include/xfrm.h linux-3.0.9/security/seli } #else static inline int selinux_xfrm_enabled(void) -diff -urNp linux-3.0.9/security/selinux/ss/services.c linux-3.0.9/security/selinux/ss/services.c ---- linux-3.0.9/security/selinux/ss/services.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/selinux/ss/services.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1814,6 +1814,8 @@ int security_load_policy(void *data, siz +diff --git a/security/selinux/ss/services.c b/security/selinux/ss/services.c +index 973e00e..3f979e9 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 = 0; struct policy_file file = { data, len }, *fp = &file; @@ -76639,10 +78120,11 @@ diff -urNp linux-3.0.9/security/selinux/ss/services.c linux-3.0.9/security/selin if (!ss_initialized) { avtab_cache_init(); rc = policydb_read(&policydb, fp); -diff -urNp linux-3.0.9/security/smack/smack_lsm.c linux-3.0.9/security/smack/smack_lsm.c ---- linux-3.0.9/security/smack/smack_lsm.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/smack/smack_lsm.c 2011-11-12 12:47:14.000000000 -0500 -@@ -3392,7 +3392,7 @@ static int smack_inode_getsecctx(struct +diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c +index 9831a39..351e82a 100644 +--- a/security/smack/smack_lsm.c ++++ b/security/smack/smack_lsm.c +@@ -3392,7 +3392,7 @@ static int smack_inode_getsecctx(struct inode *inode, void **ctx, u32 *ctxlen) return 0; } @@ -76651,10 +78133,11 @@ diff -urNp linux-3.0.9/security/smack/smack_lsm.c linux-3.0.9/security/smack/sma .name = "smack", .ptrace_access_check = smack_ptrace_access_check, -diff -urNp linux-3.0.9/security/tomoyo/tomoyo.c linux-3.0.9/security/tomoyo/tomoyo.c ---- linux-3.0.9/security/tomoyo/tomoyo.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/security/tomoyo/tomoyo.c 2011-11-12 12:47:14.000000000 -0500 -@@ -240,7 +240,7 @@ static int tomoyo_sb_pivotroot(struct pa +diff --git a/security/tomoyo/tomoyo.c b/security/tomoyo/tomoyo.c +index 95d3f95..1786602 100644 +--- a/security/tomoyo/tomoyo.c ++++ b/security/tomoyo/tomoyo.c +@@ -240,7 +240,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. */ @@ -76663,9 +78146,10 @@ diff -urNp linux-3.0.9/security/tomoyo/tomoyo.c linux-3.0.9/security/tomoyo/tomo .name = "tomoyo", .cred_alloc_blank = tomoyo_cred_alloc_blank, .cred_prepare = tomoyo_cred_prepare, -diff -urNp linux-3.0.9/sound/aoa/codecs/onyx.c linux-3.0.9/sound/aoa/codecs/onyx.c ---- linux-3.0.9/sound/aoa/codecs/onyx.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/aoa/codecs/onyx.c 2011-11-12 12:47:14.000000000 -0500 +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, @@ -76675,7 +78159,7 @@ diff -urNp linux-3.0.9/sound/aoa/codecs/onyx.c linux-3.0.9/sound/aoa/codecs/onyx struct codec_info *codec_info; /* 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 = cii->codec_data; mutex_lock(&onyx->mutex); @@ -76684,7 +78168,7 @@ diff -urNp linux-3.0.9/sound/aoa/codecs/onyx.c linux-3.0.9/sound/aoa/codecs/onyx mutex_unlock(&onyx->mutex); 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 = cii->codec_data; mutex_lock(&onyx->mutex); @@ -76694,9 +78178,10 @@ diff -urNp linux-3.0.9/sound/aoa/codecs/onyx.c linux-3.0.9/sound/aoa/codecs/onyx onyx->spdif_locked = onyx->analog_locked = 0; mutex_unlock(&onyx->mutex); -diff -urNp linux-3.0.9/sound/aoa/codecs/onyx.h linux-3.0.9/sound/aoa/codecs/onyx.h ---- linux-3.0.9/sound/aoa/codecs/onyx.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/aoa/codecs/onyx.h 2011-11-12 12:47:14.000000000 -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 <linux/i2c.h> #include <asm/pmac_low_i2c.h> @@ -76705,10 +78190,11 @@ diff -urNp linux-3.0.9/sound/aoa/codecs/onyx.h linux-3.0.9/sound/aoa/codecs/onyx /* PCM3052 register definitions */ -diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_oss.c ---- linux-3.0.9/sound/core/oss/pcm_oss.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/core/oss/pcm_oss.c 2011-11-12 12:47:14.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 = snd_enter_user(); @@ -76721,7 +78207,7 @@ diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_o } if (ret != -EPIPE && ret != -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_pcm_substream *substream, char *p if (in_kernel) { mm_segment_t fs; fs = snd_enter_user(); @@ -76734,7 +78220,7 @@ diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_o } if (ret == -EPIPE) { if (runtime->status->state == 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_substream *substream, const cha struct snd_pcm_plugin_channel *channels; size_t oss_frame_bytes = (runtime->oss.plugin_first->src_width * runtime->oss.plugin_first->src_format.channels) / 8; if (!in_kernel) { @@ -76743,7 +78229,7 @@ diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_o return -EFAULT; buf = 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_substream *substream, const cha } } else { tmp = snd_pcm_oss_write2(substream, @@ -76752,7 +78238,7 @@ diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_o runtime->oss.period_bytes, 0); if (tmp <= 0) goto err; -@@ -1433,7 +1433,7 @@ static ssize_t snd_pcm_oss_read2(struct +@@ -1433,7 +1433,7 @@ static ssize_t snd_pcm_oss_read2(struct snd_pcm_substream *substream, char *buf, struct snd_pcm_runtime *runtime = substream->runtime; snd_pcm_sframes_t frames, frames1; #ifdef CONFIG_SND_PCM_OSS_PLUGINS @@ -76761,7 +78247,7 @@ diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_o if (runtime->oss.plugin_first) { struct snd_pcm_plugin_channel *channels; size_t oss_frame_bytes = (runtime->oss.plugin_last->dst_width * runtime->oss.plugin_last->dst_format.channels) / 8; -@@ -1495,7 +1495,7 @@ static ssize_t snd_pcm_oss_read1(struct +@@ -1495,7 +1495,7 @@ static ssize_t snd_pcm_oss_read1(struct snd_pcm_substream *substream, char __use xfer += tmp; runtime->oss.buffer_used -= tmp; } else { @@ -76770,7 +78256,7 @@ diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_o runtime->oss.period_bytes, 0); if (tmp <= 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_file *pcm_oss_file) size1); size1 /= runtime->channels; /* frames */ fs = snd_enter_user(); @@ -76779,10 +78265,11 @@ diff -urNp linux-3.0.9/sound/core/oss/pcm_oss.c linux-3.0.9/sound/core/oss/pcm_o snd_leave_user(fs); } } else if (runtime->access == SNDRV_PCM_ACCESS_RW_NONINTERLEAVED) { -diff -urNp linux-3.0.9/sound/core/pcm_compat.c linux-3.0.9/sound/core/pcm_compat.c ---- linux-3.0.9/sound/core/pcm_compat.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/core/pcm_compat.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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_substream *substream, int err; fs = snd_enter_user(); @@ -76791,10 +78278,11 @@ diff -urNp linux-3.0.9/sound/core/pcm_compat.c linux-3.0.9/sound/core/pcm_compat snd_leave_user(fs); if (err < 0) return err; -diff -urNp linux-3.0.9/sound/core/pcm_native.c linux-3.0.9/sound/core/pcm_native.c ---- linux-3.0.9/sound/core/pcm_native.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/core/pcm_native.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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_substream *substream, switch (substream->stream) { case SNDRV_PCM_STREAM_PLAYBACK: result = snd_pcm_playback_ioctl1(NULL, substream, cmd, @@ -76808,9 +78296,10 @@ diff -urNp linux-3.0.9/sound/core/pcm_native.c linux-3.0.9/sound/core/pcm_native break; default: result = -EINVAL; -diff -urNp linux-3.0.9/sound/core/seq/seq_device.c linux-3.0.9/sound/core/seq/seq_device.c ---- linux-3.0.9/sound/core/seq/seq_device.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/core/seq/seq_device.c 2011-11-12 12:47:14.000000000 -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 */ @@ -76820,7 +78309,7 @@ diff -urNp linux-3.0.9/sound/core/seq/seq_device.c linux-3.0.9/sound/core/seq/se /* registred devices */ struct list_head dev_list; /* list of devices */ -@@ -332,7 +332,7 @@ int snd_seq_device_register_driver(char +@@ -332,7 +332,7 @@ int snd_seq_device_register_driver(char *id, struct snd_seq_dev_ops *entry, mutex_lock(&ops->reg_mutex); /* copy driver operators */ @@ -76829,7 +78318,7 @@ diff -urNp linux-3.0.9/sound/core/seq/seq_device.c linux-3.0.9/sound/core/seq/se ops->driver |= DRIVER_LOADED; ops->argsize = argsize; -@@ -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, struct ops_list *ops) dev->name, ops->id, ops->argsize, dev->argsize); return -EINVAL; } @@ -76838,7 +78327,7 @@ diff -urNp linux-3.0.9/sound/core/seq/seq_device.c linux-3.0.9/sound/core/seq/se dev->status = 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, struct ops_list *ops) dev->name, ops->id, ops->argsize, dev->argsize); return -EINVAL; } @@ -76847,9 +78336,10 @@ diff -urNp linux-3.0.9/sound/core/seq/seq_device.c linux-3.0.9/sound/core/seq/se dev->status = SNDRV_SEQ_DEVICE_FREE; dev->driver_data = NULL; ops->num_init_devices--; -diff -urNp linux-3.0.9/sound/drivers/mts64.c linux-3.0.9/sound/drivers/mts64.c ---- linux-3.0.9/sound/drivers/mts64.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/drivers/mts64.c 2011-11-12 12:47:14.000000000 -0500 +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 <sound/initval.h> #include <sound/rawmidi.h> @@ -76867,7 +78357,7 @@ diff -urNp linux-3.0.9/sound/drivers/mts64.c linux-3.0.9/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 = substream->rmidi->private_data; @@ -76876,7 +78366,7 @@ diff -urNp linux-3.0.9/sound/drivers/mts64.c linux-3.0.9/sound/drivers/mts64.c /* We don't need a spinlock here, because this is just called if the device has not been opened before. 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) msleep(50); } @@ -76885,7 +78375,7 @@ diff -urNp linux-3.0.9/sound/drivers/mts64.c linux-3.0.9/sound/drivers/mts64.c 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_rawmidi_substream *substream) struct mts64 *mts = substream->rmidi->private_data; unsigned long flags; @@ -76895,7 +78385,7 @@ diff -urNp linux-3.0.9/sound/drivers/mts64.c linux-3.0.9/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_rawmidi_substream *substream) msleep(500); @@ -76906,10 +78396,11 @@ diff -urNp linux-3.0.9/sound/drivers/mts64.c linux-3.0.9/sound/drivers/mts64.c return 0; } -diff -urNp linux-3.0.9/sound/drivers/opl4/opl4_lib.c linux-3.0.9/sound/drivers/opl4/opl4_lib.c ---- linux-3.0.9/sound/drivers/opl4/opl4_lib.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/drivers/opl4/opl4_lib.c 2011-11-12 12:47:14.000000000 -0500 -@@ -28,7 +28,7 @@ MODULE_AUTHOR("Clemens Ladisch <clemens@ +diff --git a/sound/drivers/opl4/opl4_lib.c b/sound/drivers/opl4/opl4_lib.c +index f07e38d..7aae69a 100644 +--- a/sound/drivers/opl4/opl4_lib.c ++++ b/sound/drivers/opl4/opl4_lib.c +@@ -28,7 +28,7 @@ MODULE_AUTHOR("Clemens Ladisch <clemens@ladisch.de>"); MODULE_DESCRIPTION("OPL4 driver"); MODULE_LICENSE("GPL"); @@ -76918,9 +78409,10 @@ diff -urNp linux-3.0.9/sound/drivers/opl4/opl4_lib.c linux-3.0.9/sound/drivers/o { int timeout = 10; while ((inb(opl4->fm_port) & OPL4_STATUS_BUSY) && --timeout > 0) -diff -urNp linux-3.0.9/sound/drivers/portman2x4.c linux-3.0.9/sound/drivers/portman2x4.c ---- linux-3.0.9/sound/drivers/portman2x4.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/drivers/portman2x4.c 2011-11-12 12:47:14.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 <sound/initval.h> #include <sound/rawmidi.h> @@ -76938,10 +78430,11 @@ diff -urNp linux-3.0.9/sound/drivers/portman2x4.c linux-3.0.9/sound/drivers/port int mode[PORTMAN_NUM_INPUT_PORTS]; struct snd_rawmidi_substream *midi_input[PORTMAN_NUM_INPUT_PORTS]; }; -diff -urNp linux-3.0.9/sound/firewire/amdtp.c linux-3.0.9/sound/firewire/amdtp.c ---- linux-3.0.9/sound/firewire/amdtp.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/firewire/amdtp.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 = s->pcm_buffer_pointer + data_blocks; if (ptr >= pcm->runtime->buffer_size) ptr -= pcm->runtime->buffer_size; @@ -76959,10 +78452,11 @@ diff -urNp linux-3.0.9/sound/firewire/amdtp.c linux-3.0.9/sound/firewire/amdtp.c (fw_parent_device(s->unit)->card->node_id & 0x3f) << 24; } EXPORT_SYMBOL(amdtp_out_stream_update); -diff -urNp linux-3.0.9/sound/firewire/amdtp.h linux-3.0.9/sound/firewire/amdtp.h ---- linux-3.0.9/sound/firewire/amdtp.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/firewire/amdtp.h 2011-11-12 12:47:14.000000000 -0500 -@@ -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(struct amdtp_out_stream *s) static inline void amdtp_out_stream_pcm_trigger(struct amdtp_out_stream *s, struct snd_pcm_substream *pcm) { @@ -76971,10 +78465,11 @@ diff -urNp linux-3.0.9/sound/firewire/amdtp.h linux-3.0.9/sound/firewire/amdtp.h } /** -diff -urNp linux-3.0.9/sound/firewire/isight.c linux-3.0.9/sound/firewire/isight.c ---- linux-3.0.9/sound/firewire/isight.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/firewire/isight.c 2011-11-12 12:47:14.000000000 -0500 -@@ -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 *isight, unsigned int count) ptr += count; if (ptr >= runtime->buffer_size) ptr -= runtime->buffer_size; @@ -76983,7 +78478,7 @@ diff -urNp linux-3.0.9/sound/firewire/isight.c linux-3.0.9/sound/firewire/isight isight->period_counter += count; if (isight->period_counter >= 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; @@ -76992,7 +78487,7 @@ diff -urNp linux-3.0.9/sound/firewire/isight.c linux-3.0.9/sound/firewire/isight 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 = substream->private_data; @@ -77001,7 +78496,7 @@ diff -urNp linux-3.0.9/sound/firewire/isight.c linux-3.0.9/sound/firewire/isight 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) switch (cmd) { case SNDRV_PCM_TRIGGER_START: @@ -77014,9 +78509,10 @@ diff -urNp linux-3.0.9/sound/firewire/isight.c linux-3.0.9/sound/firewire/isight break; default: return -EINVAL; -diff -urNp linux-3.0.9/sound/isa/cmi8330.c linux-3.0.9/sound/isa/cmi8330.c ---- linux-3.0.9/sound/isa/cmi8330.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/isa/cmi8330.c 2011-11-12 12:47:14.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 { struct snd_pcm *pcm; @@ -77026,9 +78522,10 @@ diff -urNp linux-3.0.9/sound/isa/cmi8330.c linux-3.0.9/sound/isa/cmi8330.c snd_pcm_open_callback_t open; void *private_data; /* sb or wss */ } streams[2]; -diff -urNp linux-3.0.9/sound/oss/sb_audio.c linux-3.0.9/sound/oss/sb_audio.c ---- linux-3.0.9/sound/oss/sb_audio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/oss/sb_audio.c 2011-11-12 12:47:14.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 = (signed short *)(localbuf + localoffs); while (c) @@ -77038,9 +78535,10 @@ diff -urNp linux-3.0.9/sound/oss/sb_audio.c linux-3.0.9/sound/oss/sb_audio.c if (copy_from_user(lbuf8, userbuf+useroffs + p, locallen)) -diff -urNp linux-3.0.9/sound/oss/swarm_cs4297a.c linux-3.0.9/sound/oss/swarm_cs4297a.c ---- linux-3.0.9/sound/oss/swarm_cs4297a.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/oss/swarm_cs4297a.c 2011-11-12 12:47:14.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; @@ -77075,9 +78573,10 @@ diff -urNp linux-3.0.9/sound/oss/swarm_cs4297a.c linux-3.0.9/sound/oss/swarm_cs4 list_add(&s->list, &cs4297a_devs); -diff -urNp linux-3.0.9/sound/pci/hda/hda_codec.h linux-3.0.9/sound/pci/hda/hda_codec.h ---- linux-3.0.9/sound/pci/hda/hda_codec.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/pci/hda/hda_codec.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h +index 59c9730..91ef96e 100644 +--- a/sound/pci/hda/hda_codec.h ++++ b/sound/pci/hda/hda_codec.h @@ -615,7 +615,7 @@ struct hda_bus_ops { /* notify power-up/down from codec to controller */ void (*pm_notify)(struct hda_bus *bus); @@ -77113,9 +78612,10 @@ diff -urNp linux-3.0.9/sound/pci/hda/hda_codec.h linux-3.0.9/sound/pci/hda/hda_c /* PCM to create, set by patch_ops.build_pcms callback */ unsigned int num_pcms; -diff -urNp linux-3.0.9/sound/pci/ice1712/ice1712.h linux-3.0.9/sound/pci/ice1712/ice1712.h ---- linux-3.0.9/sound/pci/ice1712/ice1712.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/pci/ice1712/ice1712.h 2011-11-12 12:47:14.000000000 -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 { @@ -77134,10 +78634,11 @@ diff -urNp linux-3.0.9/sound/pci/ice1712/ice1712.h linux-3.0.9/sound/pci/ice1712 }; -diff -urNp linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c ---- linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c 2011-11-12 12:47:14.000000000 -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_main.c +index c94c051..be0abd1 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 *chip) if ((snd_ymfpci_readl(chip, YDSXGR_STATUS) & 2) == 0) break; } @@ -77148,7 +78649,7 @@ diff -urNp linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c linux-3.0.9/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 *chip) continue; init_waitqueue_entry(&wait, current); add_wait_queue(&chip->interrupt_sleep, &wait); @@ -77157,7 +78658,7 @@ diff -urNp linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c linux-3.0.9/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, void *dev_id) snd_ymfpci_writel(chip, YDSXGR_MODE, mode); spin_unlock(&chip->reg_lock); @@ -77168,7 +78669,7 @@ diff -urNp linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c linux-3.0.9/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 *card, spin_lock_init(&chip->reg_lock); spin_lock_init(&chip->voice_lock); init_waitqueue_head(&chip->interrupt_sleep); @@ -77177,10 +78678,11 @@ diff -urNp linux-3.0.9/sound/pci/ymfpci/ymfpci_main.c linux-3.0.9/sound/pci/ymfp chip->card = card; chip->pci = pci; chip->irq = -1; -diff -urNp linux-3.0.9/sound/soc/soc-core.c linux-3.0.9/sound/soc/soc-core.c ---- linux-3.0.9/sound/soc/soc-core.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/soc/soc-core.c 2011-11-12 12:47:14.000000000 -0500 -@@ -1021,7 +1021,7 @@ static snd_pcm_uframes_t soc_pcm_pointer +diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c +index 59abd84..74a3744 100644 +--- a/sound/soc/soc-core.c ++++ b/sound/soc/soc-core.c +@@ -1021,7 +1021,7 @@ static snd_pcm_uframes_t soc_pcm_pointer(struct snd_pcm_substream *substream) } /* ASoC PCM operations */ @@ -77189,7 +78691,7 @@ diff -urNp linux-3.0.9/sound/soc/soc-core.c linux-3.0.9/sound/soc/soc-core.c .open = soc_pcm_open, .close = soc_codec_close, .hw_params = soc_pcm_hw_params, -@@ -2128,6 +2128,7 @@ static int soc_new_pcm(struct snd_soc_pc +@@ -2128,6 +2128,7 @@ static int soc_new_pcm(struct snd_soc_pcm_runtime *rtd, int num) rtd->pcm = pcm; pcm->private_data = rtd; if (platform->driver->ops) { @@ -77197,9 +78699,10 @@ diff -urNp linux-3.0.9/sound/soc/soc-core.c linux-3.0.9/sound/soc/soc-core.c soc_pcm_ops.mmap = platform->driver->ops->mmap; soc_pcm_ops.pointer = platform->driver->ops->pointer; soc_pcm_ops.ioctl = platform->driver->ops->ioctl; -diff -urNp linux-3.0.9/sound/usb/card.h linux-3.0.9/sound/usb/card.h ---- linux-3.0.9/sound/usb/card.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/sound/usb/card.h 2011-11-12 12:47:14.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_runtime *runtime, struct urb *u); int (*retire_sync)(struct snd_usb_substream *subs, struct snd_pcm_runtime *runtime, struct urb *u); @@ -77217,9 +78720,38 @@ diff -urNp linux-3.0.9/sound/usb/card.h linux-3.0.9/sound/usb/card.h }; struct snd_usb_stream { -diff -urNp linux-3.0.9/tools/gcc/checker_plugin.c linux-3.0.9/tools/gcc/checker_plugin.c ---- linux-3.0.9/tools/gcc/checker_plugin.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/tools/gcc/checker_plugin.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/tools/gcc/Makefile b/tools/gcc/Makefile +new file mode 100644 +index 0000000..1e75733 +--- /dev/null ++++ b/tools/gcc/Makefile +@@ -0,0 +1,21 @@ ++#CC := gcc ++#PLUGIN_SOURCE_FILES := pax_plugin.c ++#PLUGIN_OBJECT_FILES := $(patsubst %.c,%.o,$(PLUGIN_SOURCE_FILES)) ++GCCPLUGINS_DIR := $(shell $(HOSTCC) -print-file-name=plugin) ++#CFLAGS += -I$(GCCPLUGINS_DIR)/include -fPIC -O2 -Wall -W ++ ++HOST_EXTRACFLAGS += -I$(GCCPLUGINS_DIR)/include ++ ++hostlibs-y := constify_plugin.so ++hostlibs-$(CONFIG_PAX_MEMORY_STACKLEAK) += stackleak_plugin.so ++hostlibs-$(CONFIG_KALLOCSTAT_PLUGIN) += kallocstat_plugin.so ++hostlibs-$(CONFIG_PAX_KERNEXEC_PLUGIN) += kernexec_plugin.so ++hostlibs-$(CONFIG_CHECKER_PLUGIN) += checker_plugin.so ++ ++always := $(hostlibs-y) ++ ++stackleak_plugin-objs := stackleak_plugin.o ++constify_plugin-objs := constify_plugin.o ++kallocstat_plugin-objs := kallocstat_plugin.o ++kernexec_plugin-objs := kernexec_plugin.o ++checker_plugin-objs := checker_plugin.o +diff --git a/tools/gcc/checker_plugin.c b/tools/gcc/checker_plugin.c +new file mode 100644 +index 0000000..2fd48e0 +--- /dev/null ++++ b/tools/gcc/checker_plugin.c @@ -0,0 +1,169 @@ +/* + * Copyright 2011 by the PaX Team <pageexec@freemail.hu> @@ -77390,9 +78922,11 @@ diff -urNp linux-3.0.9/tools/gcc/checker_plugin.c linux-3.0.9/tools/gcc/checker_ + + return 0; +} -diff -urNp linux-3.0.9/tools/gcc/constify_plugin.c linux-3.0.9/tools/gcc/constify_plugin.c ---- linux-3.0.9/tools/gcc/constify_plugin.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/tools/gcc/constify_plugin.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/tools/gcc/constify_plugin.c b/tools/gcc/constify_plugin.c +new file mode 100644 +index 0000000..e565ec3 +--- /dev/null ++++ b/tools/gcc/constify_plugin.c @@ -0,0 +1,293 @@ +/* + * Copyright 2011 by Emese Revfy <re.emese@gmail.com> @@ -77687,9 +79221,11 @@ diff -urNp linux-3.0.9/tools/gcc/constify_plugin.c linux-3.0.9/tools/gcc/constif + + return 0; +} -diff -urNp linux-3.0.9/tools/gcc/kallocstat_plugin.c linux-3.0.9/tools/gcc/kallocstat_plugin.c ---- linux-3.0.9/tools/gcc/kallocstat_plugin.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/tools/gcc/kallocstat_plugin.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/tools/gcc/kallocstat_plugin.c b/tools/gcc/kallocstat_plugin.c +new file mode 100644 +index 0000000..9fc9bbd +--- /dev/null ++++ b/tools/gcc/kallocstat_plugin.c @@ -0,0 +1,165 @@ +/* + * Copyright 2011 by the PaX Team <pageexec@freemail.hu> @@ -77856,9 +79392,11 @@ diff -urNp linux-3.0.9/tools/gcc/kallocstat_plugin.c linux-3.0.9/tools/gcc/kallo + + return 0; +} -diff -urNp linux-3.0.9/tools/gcc/kernexec_plugin.c linux-3.0.9/tools/gcc/kernexec_plugin.c ---- linux-3.0.9/tools/gcc/kernexec_plugin.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/tools/gcc/kernexec_plugin.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/tools/gcc/kernexec_plugin.c b/tools/gcc/kernexec_plugin.c +new file mode 100644 +index 0000000..4c69034 +--- /dev/null ++++ b/tools/gcc/kernexec_plugin.c @@ -0,0 +1,273 @@ +/* + * Copyright 2011 by the PaX Team <pageexec@freemail.hu> @@ -78133,34 +79671,11 @@ diff -urNp linux-3.0.9/tools/gcc/kernexec_plugin.c linux-3.0.9/tools/gcc/kernexe + + return 0; +} -diff -urNp linux-3.0.9/tools/gcc/Makefile linux-3.0.9/tools/gcc/Makefile ---- linux-3.0.9/tools/gcc/Makefile 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/tools/gcc/Makefile 2011-11-12 12:47:14.000000000 -0500 -@@ -0,0 +1,21 @@ -+#CC := gcc -+#PLUGIN_SOURCE_FILES := pax_plugin.c -+#PLUGIN_OBJECT_FILES := $(patsubst %.c,%.o,$(PLUGIN_SOURCE_FILES)) -+GCCPLUGINS_DIR := $(shell $(HOSTCC) -print-file-name=plugin) -+#CFLAGS += -I$(GCCPLUGINS_DIR)/include -fPIC -O2 -Wall -W -+ -+HOST_EXTRACFLAGS += -I$(GCCPLUGINS_DIR)/include -+ -+hostlibs-y := constify_plugin.so -+hostlibs-$(CONFIG_PAX_MEMORY_STACKLEAK) += stackleak_plugin.so -+hostlibs-$(CONFIG_KALLOCSTAT_PLUGIN) += kallocstat_plugin.so -+hostlibs-$(CONFIG_PAX_KERNEXEC_PLUGIN) += kernexec_plugin.so -+hostlibs-$(CONFIG_CHECKER_PLUGIN) += checker_plugin.so -+ -+always := $(hostlibs-y) -+ -+stackleak_plugin-objs := stackleak_plugin.o -+constify_plugin-objs := constify_plugin.o -+kallocstat_plugin-objs := kallocstat_plugin.o -+kernexec_plugin-objs := kernexec_plugin.o -+checker_plugin-objs := checker_plugin.o -diff -urNp linux-3.0.9/tools/gcc/stackleak_plugin.c linux-3.0.9/tools/gcc/stackleak_plugin.c ---- linux-3.0.9/tools/gcc/stackleak_plugin.c 1969-12-31 19:00:00.000000000 -0500 -+++ linux-3.0.9/tools/gcc/stackleak_plugin.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/tools/gcc/stackleak_plugin.c b/tools/gcc/stackleak_plugin.c +new file mode 100644 +index 0000000..8bd7ab4 +--- /dev/null ++++ b/tools/gcc/stackleak_plugin.c @@ -0,0 +1,251 @@ +/* + * Copyright 2011 by the PaX Team <pageexec@freemail.hu> @@ -78413,9 +79928,10 @@ diff -urNp linux-3.0.9/tools/gcc/stackleak_plugin.c linux-3.0.9/tools/gcc/stackl + + return 0; +} -diff -urNp linux-3.0.9/tools/perf/util/include/asm/alternative-asm.h linux-3.0.9/tools/perf/util/include/asm/alternative-asm.h ---- linux-3.0.9/tools/perf/util/include/asm/alternative-asm.h 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/tools/perf/util/include/asm/alternative-asm.h 2011-11-12 12:47:14.000000000 -0500 +diff --git a/tools/perf/util/include/asm/alternative-asm.h b/tools/perf/util/include/asm/alternative-asm.h +index 6789d78..4b653fc 100644 +--- a/tools/perf/util/include/asm/alternative-asm.h ++++ b/tools/perf/util/include/asm/alternative-asm.h @@ -5,4 +5,7 @@ #define altinstruction_entry # @@ -78424,10 +79940,11 @@ diff -urNp linux-3.0.9/tools/perf/util/include/asm/alternative-asm.h linux-3.0.9 + .endm + #endif -diff -urNp linux-3.0.9/usr/gen_init_cpio.c linux-3.0.9/usr/gen_init_cpio.c ---- linux-3.0.9/usr/gen_init_cpio.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/usr/gen_init_cpio.c 2011-11-12 12:47:14.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 = -1; int namesize; @@ -78436,7 +79953,7 @@ diff -urNp linux-3.0.9/usr/gen_init_cpio.c linux-3.0.9/usr/gen_init_cpio.c mode |= S_IFREG; -@@ -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 = *expanded = '\0'; strncat(env_var, start + 2, end - start - 2); strncat(expanded, new_location, start - new_location); @@ -78449,9 +79966,10 @@ diff -urNp linux-3.0.9/usr/gen_init_cpio.c linux-3.0.9/usr/gen_init_cpio.c } else break; } -diff -urNp linux-3.0.9/virt/kvm/kvm_main.c linux-3.0.9/virt/kvm/kvm_main.c ---- linux-3.0.9/virt/kvm/kvm_main.c 2011-11-11 13:12:24.000000000 -0500 -+++ linux-3.0.9/virt/kvm/kvm_main.c 2011-11-12 12:47:14.000000000 -0500 +diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c +index 96ebc06..b6f830e 100644 +--- a/virt/kvm/kvm_main.c ++++ b/virt/kvm/kvm_main.c @@ -73,7 +73,7 @@ LIST_HEAD(vm_list); static cpumask_var_t cpus_hardware_enabled; @@ -78461,7 +79979,7 @@ diff -urNp linux-3.0.9/virt/kvm/kvm_main.c linux-3.0.9/virt/kvm/kvm_main.c struct kmem_cache *kvm_vcpu_cache; EXPORT_SYMBOL_GPL(kvm_vcpu_cache); -@@ -2176,7 +2176,7 @@ static void hardware_enable_nolock(void +@@ -2176,7 +2176,7 @@ static void hardware_enable_nolock(void *junk) if (r) { cpumask_clear_cpu(cpu, cpus_hardware_enabled); @@ -78483,7 +80001,7 @@ diff -urNp linux-3.0.9/virt/kvm/kvm_main.c linux-3.0.9/virt/kvm/kvm_main.c hardware_disable_all_nolock(); r = -EBUSY; } -@@ -2498,7 +2498,7 @@ static void kvm_sched_out(struct preempt +@@ -2498,7 +2498,7 @@ static void kvm_sched_out(struct preempt_notifier *pn, kvm_arch_vcpu_put(vcpu); } @@ -78492,7 +80010,7 @@ diff -urNp linux-3.0.9/virt/kvm/kvm_main.c linux-3.0.9/virt/kvm/kvm_main.c struct module *module) { int r; -@@ -2561,7 +2561,7 @@ int kvm_init(void *opaque, unsigned vcpu +@@ -2561,7 +2561,7 @@ int kvm_init(void *opaque, unsigned vcpu_size, unsigned vcpu_align, if (!vcpu_align) vcpu_align = __alignof__(struct kvm_vcpu); kvm_vcpu_cache = kmem_cache_create("kvm_vcpu", vcpu_size, vcpu_align, @@ -78501,7 +80019,7 @@ diff -urNp linux-3.0.9/virt/kvm/kvm_main.c linux-3.0.9/virt/kvm/kvm_main.c if (!kvm_vcpu_cache) { r = -ENOMEM; goto out_free_3; -@@ -2571,9 +2571,11 @@ int kvm_init(void *opaque, unsigned vcpu +@@ -2571,9 +2571,11 @@ int kvm_init(void *opaque, unsigned vcpu_size, unsigned vcpu_align, if (r) goto out_free; diff --git a/main/open-iscsi-grsec/APKBUILD b/main/open-iscsi-grsec/APKBUILD index fa87e68342..d42618a0eb 100644 --- a/main/open-iscsi-grsec/APKBUILD +++ b/main/open-iscsi-grsec/APKBUILD @@ -3,8 +3,8 @@ _flavor=grsec _realname=open-iscsi _realver=2.0-872 -_kver=3.0.9 -_kpkgrel=2 +_kver=3.0.10 +_kpkgrel=0 # verify the kernel version before entering chroot if [ -f ../linux-${_flavor}/APKBUILD ]; then @@ -56,4 +56,4 @@ package() { } md5sums="b4df94f08c241352bb964043b3e44779 open-iscsi-2.0-872.tar.gz -e6c2588a1b1e9ed6a946e87c153b60dd Makefile-Alpine-kernels-support.patch" +c28dfb108cec0399634d348132cee79a Makefile-Alpine-kernels-support.patch" diff --git a/main/open-iscsi-grsec/Makefile-Alpine-kernels-support.patch b/main/open-iscsi-grsec/Makefile-Alpine-kernels-support.patch index 1944820de6..95e9c95733 100644 --- a/main/open-iscsi-grsec/Makefile-Alpine-kernels-support.patch +++ b/main/open-iscsi-grsec/Makefile-Alpine-kernels-support.patch @@ -26,7 +26,7 @@ linux_2_6_35: $(unpatch_code) + -+linux_3_0_9: $(unpatch_code) ++linux_3_0_10: $(unpatch_code) do_unpatch_code: echo "Un-patching source code for use with linux-2.6.14 and up ..." diff --git a/main/open-vm-tools-grsec/APKBUILD b/main/open-vm-tools-grsec/APKBUILD index cb8cf8ae45..133b3b7837 100644 --- a/main/open-vm-tools-grsec/APKBUILD +++ b/main/open-vm-tools-grsec/APKBUILD @@ -6,8 +6,8 @@ _mypkgrel=0 _realver=2011.09.23 _realsubver=491607 -_kver=3.0.9 -_kpkgrel=2 +_kver=3.0.10 +_kpkgrel=0 # source open-vm-tools version if [ -f ../main/$_realname/APKBUILD ]; then diff --git a/main/xtables-addons-grsec/APKBUILD b/main/xtables-addons-grsec/APKBUILD index d4e37faa58..20738ab030 100644 --- a/main/xtables-addons-grsec/APKBUILD +++ b/main/xtables-addons-grsec/APKBUILD @@ -3,8 +3,8 @@ _flavor=${FLAVOR:-grsec} _realname=xtables-addons _name=$_realname-$_flavor -_kver=3.0.9 -_kpkgrel=2 +_kver=3.0.10 +_kpkgrel=0 # source the kernel version if [ -f ../linux-$_flavor/APKBUILD ]; then |