public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Anthony G. Basile" <blueness@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/hardened-patchset:master commit in: 2.6.32/, 3.0.4/
Date: Sun,  4 Sep 2011 12:34:13 +0000 (UTC)	[thread overview]
Message-ID: <4cf4ce297dfb5c629f33cfa08fbd7205b23bb3a7.blueness@gentoo> (raw)

commit:     4cf4ce297dfb5c629f33cfa08fbd7205b23bb3a7
Author:     Anthony G. Basile <blueness <AT> gentoo <DOT> org>
AuthorDate: Sun Sep  4 12:33:08 2011 +0000
Commit:     Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Sun Sep  4 12:33:08 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/hardened-patchset.git;a=commit;h=4cf4ce29

Grsec/PaX: grsecurity-2.2.2-2.6.32.46-201109021814 + grsecurity-2.2.2-3.0.4-201109011725

---
 2.6.32/0000_README                                 |    2 +-
 ..._grsecurity-2.2.2-2.6.32.46-201109021814.patch} |  117 ++++++++++++++------
 3.0.4/0000_README                                  |    2 +-
 ...4420_grsecurity-2.2.2-3.0.4-201109011725.patch} |  108 +++++++++---------
 4 files changed, 138 insertions(+), 91 deletions(-)

diff --git a/2.6.32/0000_README b/2.6.32/0000_README
index 81874c9..ca3d4a1 100644
--- a/2.6.32/0000_README
+++ b/2.6.32/0000_README
@@ -11,7 +11,7 @@ Patch:	1044_linux-2.6.32.45.patch
 From:	http://www.kernel.org
 Desc:	Linux 2.6.39.45
 
-Patch:	4420_grsecurity-2.2.2-2.6.32.46-201108301903.patch
+Patch:	4420_grsecurity-2.2.2-2.6.32.46-201109021814.patch
 From:	http://www.grsecurity.net
 Desc:	hardened-sources base patch from upstream grsecurity
 

diff --git a/2.6.32/4420_grsecurity-2.2.2-2.6.32.46-201108301903.patch b/2.6.32/4420_grsecurity-2.2.2-2.6.32.46-201109021814.patch
similarity index 99%
rename from 2.6.32/4420_grsecurity-2.2.2-2.6.32.46-201108301903.patch
rename to 2.6.32/4420_grsecurity-2.2.2-2.6.32.46-201109021814.patch
index abe67d0..505eaa4 100644
--- a/2.6.32/4420_grsecurity-2.2.2-2.6.32.46-201108301903.patch
+++ b/2.6.32/4420_grsecurity-2.2.2-2.6.32.46-201109021814.patch
@@ -37669,6 +37669,30 @@ diff -urNp linux-2.6.32.46/drivers/staging/vme/devices/vme_user.c linux-2.6.32.4
          .open = vme_user_open,
          .release = vme_user_release,
          .read = vme_user_read,
+diff -urNp linux-2.6.32.46/drivers/staging/vt6655/hostap.c linux-2.6.32.46/drivers/staging/vt6655/hostap.c
+--- linux-2.6.32.46/drivers/staging/vt6655/hostap.c	2011-03-27 14:31:47.000000000 -0400
++++ linux-2.6.32.46/drivers/staging/vt6655/hostap.c	2011-09-02 18:13:56.000000000 -0400
+@@ -84,7 +84,7 @@ static int hostap_enable_hostapd(PSDevic
+     PSDevice apdev_priv;
+ 	struct net_device *dev = pDevice->dev;
+ 	int ret;
+-	const struct net_device_ops apdev_netdev_ops = {
++	static net_device_ops_no_const apdev_netdev_ops = {
+ 		.ndo_start_xmit         = pDevice->tx_80211,
+ 	};
+ 
+diff -urNp linux-2.6.32.46/drivers/staging/vt6656/hostap.c linux-2.6.32.46/drivers/staging/vt6656/hostap.c
+--- linux-2.6.32.46/drivers/staging/vt6656/hostap.c	2011-03-27 14:31:47.000000000 -0400
++++ linux-2.6.32.46/drivers/staging/vt6656/hostap.c	2011-09-02 18:13:35.000000000 -0400
+@@ -86,7 +86,7 @@ static int hostap_enable_hostapd(PSDevic
+     PSDevice apdev_priv;
+ 	struct net_device *dev = pDevice->dev;
+ 	int ret;
+-	const struct net_device_ops apdev_netdev_ops = {
++	static net_device_ops_no_const apdev_netdev_ops = {
+ 		.ndo_start_xmit         = pDevice->tx_80211,
+ 	};
+ 
 diff -urNp linux-2.6.32.46/drivers/staging/wlan-ng/hfa384x_usb.c linux-2.6.32.46/drivers/staging/wlan-ng/hfa384x_usb.c
 --- linux-2.6.32.46/drivers/staging/wlan-ng/hfa384x_usb.c	2011-03-27 14:31:47.000000000 -0400
 +++ linux-2.6.32.46/drivers/staging/wlan-ng/hfa384x_usb.c	2011-08-23 20:24:26.000000000 -0400
@@ -69459,7 +69483,7 @@ diff -urNp linux-2.6.32.46/localversion-grsec linux-2.6.32.46/localversion-grsec
 +-grsec
 diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
 --- linux-2.6.32.46/Makefile	2011-08-29 22:24:44.000000000 -0400
-+++ linux-2.6.32.46/Makefile	2011-08-30 18:21:35.000000000 -0400
++++ linux-2.6.32.46/Makefile	2011-09-01 17:24:34.000000000 -0400
 @@ -221,8 +221,9 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH"
  
  HOSTCC       = gcc
@@ -69485,7 +69509,15 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  KBUILD_AFLAGS   := -D__ASSEMBLY__
  
  # Read KERNELRELEASE from include/config/kernel.release (if it exists)
-@@ -403,7 +406,7 @@ endif
+@@ -377,6 +380,7 @@ export RCS_TAR_IGNORE := --exclude SCCS 
+ 
+ # Basic helpers built in scripts/
+ PHONY += scripts_basic
++scripts_basic: KBUILD_CFLAGS := $(filter-out $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN),$(KBUILD_CFLAGS))
+ scripts_basic:
+ 	$(Q)$(MAKE) $(build)=scripts/basic
+ 
+@@ -403,7 +407,7 @@ endif
  # of make so .config is not included in this case either (for *config).
  
  no-dot-config-targets := clean mrproper distclean \
@@ -69494,7 +69526,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  			 include/linux/version.h headers_% \
  			 kernelrelease kernelversion
  
-@@ -526,6 +529,24 @@ else
+@@ -526,6 +530,24 @@ else
  KBUILD_CFLAGS	+= -O2
  endif
  
@@ -69504,7 +69536,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
 +STACKLEAK_PLUGIN := -fplugin=$(objtree)/tools/gcc/stackleak_plugin.so -fplugin-arg-stackleak_plugin-track-lowest-sp=100
 +endif
 +export CONSTIFY_PLUGIN STACKLEAK_PLUGIN
-+gcc-plugins: prepare
++gcc-plugins:
 +	$(Q)$(MAKE) $(build)=tools/gcc
 +else
 +gcc-plugins:
@@ -69519,7 +69551,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  include $(srctree)/arch/$(SRCARCH)/Makefile
  
  ifneq ($(CONFIG_FRAME_WARN),0)
-@@ -644,7 +665,7 @@ export mod_strip_cmd
+@@ -644,7 +666,7 @@ export mod_strip_cmd
  
  
  ifeq ($(KBUILD_EXTMOD),)
@@ -69528,7 +69560,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  
  vmlinux-dirs	:= $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \
  		     $(core-y) $(core-m) $(drivers-y) $(drivers-m) \
-@@ -840,6 +861,8 @@ define rule_vmlinux-modpost
+@@ -840,6 +862,8 @@ define rule_vmlinux-modpost
  endef
  
  # vmlinux image - including updated kernel symbols
@@ -69537,35 +69569,25 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  vmlinux: $(vmlinux-lds) $(vmlinux-init) $(vmlinux-main) vmlinux.o $(kallsyms.o) FORCE
  ifdef CONFIG_HEADERS_CHECK
  	$(Q)$(MAKE) -f $(srctree)/Makefile headers_check
-@@ -865,7 +888,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): $(vmlinux-dirs) ;
-+$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): prepare scripts $(vmlinux-dirs) ;
- 
- # Handle descending into subdirectories listed in $(vmlinux-dirs)
- # Preset locale variables to speed up the build process. Limit locale
-@@ -874,7 +897,7 @@ $(sort $(vmlinux-init) $(vmlinux-main)) 
+@@ -874,7 +898,8 @@ $(sort $(vmlinux-init) $(vmlinux-main)) 
  # Error messages still appears in the original language
  
  PHONY += $(vmlinux-dirs)
 -$(vmlinux-dirs): prepare scripts
-+$(vmlinux-dirs): gcc-plugins
++$(vmlinux-dirs): KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++$(vmlinux-dirs): gcc-plugins prepare scripts
  	$(Q)$(MAKE) $(build)=$@
  
  # Build the kernel release string
-@@ -1124,7 +1147,8 @@ all: modules
- #	using awk while concatenating to the final file.
+@@ -983,6 +1008,7 @@ prepare0: archprepare FORCE
+ 	$(Q)$(MAKE) $(build)=. missing-syscalls
  
- PHONY += modules
--modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux)
-+$(vmlinux-dirs): KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
-+modules: prepare scripts $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux)
- 	$(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=$(objtree)/%/modules.order) > $(objtree)/modules.order
- 	@$(kecho) '  Building modules, stage 2.';
- 	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
-@@ -1133,7 +1157,7 @@ modules: $(vmlinux-dirs) $(if $(KBUILD_B
+ # All the preparing..
++prepare: KBUILD_CFLAGS := $(filter-out $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN),$(KBUILD_CFLAGS))
+ prepare: prepare0
+ 
+ # The asm symlink changes when $(ARCH) changes.
+@@ -1133,7 +1159,7 @@ modules: $(vmlinux-dirs) $(if $(KBUILD_B
  
  # Target to prepare building external modules
  PHONY += modules_prepare
@@ -69574,7 +69596,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  
  # Target to install modules
  PHONY += modules_install
-@@ -1198,7 +1222,7 @@ MRPROPER_FILES += .config .config.old in
+@@ -1198,7 +1224,7 @@ MRPROPER_FILES += .config .config.old in
                    include/linux/autoconf.h include/linux/version.h      \
                    include/linux/utsrelease.h                            \
                    include/linux/bounds.h include/asm*/asm-offsets.h     \
@@ -69583,7 +69605,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  
  # clean - Delete most, but leave enough to build external modules
  #
-@@ -1242,7 +1266,7 @@ distclean: mrproper
+@@ -1242,7 +1268,7 @@ distclean: mrproper
  	@find $(srctree) $(RCS_FIND_IGNORE) \
  		\( -name '*.orig' -o -name '*.rej' -o -name '*~' \
  		-o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \
@@ -69592,7 +69614,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  		-o -name '*%' -o -name '.*.cmd' -o -name 'core' \) \
  		-type f -print | xargs rm -f
  
-@@ -1289,6 +1313,7 @@ help:
+@@ -1289,6 +1315,7 @@ help:
  	@echo  '  modules_prepare - Set up for building external modules'
  	@echo  '  tags/TAGS	  - Generate tags file for editors'
  	@echo  '  cscope	  - Generate cscope index'
@@ -69600,7 +69622,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  	@echo  '  kernelrelease	  - Output the release version string'
  	@echo  '  kernelversion	  - Output the version stored in Makefile'
  	@echo  '  headers_install - Install sanitised kernel headers to INSTALL_HDR_PATH'; \
-@@ -1390,6 +1415,7 @@ PHONY += $(module-dirs) modules
+@@ -1390,6 +1417,7 @@ PHONY += $(module-dirs) modules
  $(module-dirs): crmodverdir $(objtree)/Module.symvers
  	$(Q)$(MAKE) $(build)=$(patsubst _module_%,%,$@)
  
@@ -69608,7 +69630,7 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  modules: $(module-dirs)
  	@$(kecho) '  Building modules, stage 2.';
  	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
-@@ -1445,7 +1471,7 @@ endif # KBUILD_EXTMOD
+@@ -1445,7 +1473,7 @@ endif # KBUILD_EXTMOD
  quiet_cmd_tags = GEN     $@
        cmd_tags = $(CONFIG_SHELL) $(srctree)/scripts/tags.sh $@
  
@@ -69617,7 +69639,13 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  	$(call cmd,tags)
  
  # Scripts to check various things for consistency
-@@ -1514,13 +1540,14 @@ endif
+@@ -1510,17 +1538,19 @@ else
+         target-dir = $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@))
+ endif
+ 
+-%.s: %.c prepare scripts FORCE
++%.s: KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++%.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 $@)
@@ -69627,13 +69655,30 @@ diff -urNp linux-2.6.32.46/Makefile linux-2.6.32.46/Makefile
  	$(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 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 $@)
+@@ -1530,11 +1560,13 @@ endif
+ 	$(cmd_crmodverdir)
+ 	$(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \
+ 	$(build)=$(build-dir)
+-%/: prepare scripts FORCE
++%/: KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++%/: 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 += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++%.ko: gcc-plugins prepare scripts FORCE
+ 	$(cmd_crmodverdir)
+ 	$(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1)   \
+ 	$(build)=$(build-dir) $(@:.ko=.o)
 diff -urNp linux-2.6.32.46/mm/backing-dev.c linux-2.6.32.46/mm/backing-dev.c
 --- linux-2.6.32.46/mm/backing-dev.c	2011-03-27 14:31:47.000000000 -0400
 +++ linux-2.6.32.46/mm/backing-dev.c	2011-08-11 19:48:17.000000000 -0400
@@ -76938,10 +76983,10 @@ diff -urNp linux-2.6.32.46/scripts/basic/fixdep.c linux-2.6.32.46/scripts/basic/
  		fprintf(stderr, "fixdep: sizeof(int) != 4 or wrong endianess? %#x\n",
 diff -urNp linux-2.6.32.46/scripts/gcc-plugin.sh linux-2.6.32.46/scripts/gcc-plugin.sh
 --- linux-2.6.32.46/scripts/gcc-plugin.sh	1969-12-31 19:00:00.000000000 -0500
-+++ linux-2.6.32.46/scripts/gcc-plugin.sh	2011-08-23 20:24:19.000000000 -0400
++++ linux-2.6.32.46/scripts/gcc-plugin.sh	2011-08-31 18:38:41.000000000 -0400
 @@ -0,0 +1,2 @@
 +#!/bin/sh
-+echo "#include \"gcc-plugin.h\"" | $* -x c -shared - -o /dev/null -I`$* -print-file-name=plugin`/include >/dev/null 2>&1 && echo "y"
++echo "#include \"gcc-plugin.h\"\n#include \"rtl.h\"" | $* -x c -shared - -o /dev/null -I`$* -print-file-name=plugin`/include >/dev/null 2>&1 && echo "y"
 diff -urNp linux-2.6.32.46/scripts/Makefile.build linux-2.6.32.46/scripts/Makefile.build
 --- linux-2.6.32.46/scripts/Makefile.build	2011-03-27 14:31:47.000000000 -0400
 +++ linux-2.6.32.46/scripts/Makefile.build	2011-08-23 20:45:11.000000000 -0400

diff --git a/3.0.4/0000_README b/3.0.4/0000_README
index b6f610b..af75e4e 100644
--- a/3.0.4/0000_README
+++ b/3.0.4/0000_README
@@ -3,7 +3,7 @@ README
 
 Individual Patch Descriptions:
 -----------------------------------------------------------------------------
-Patch:	4420_grsecurity-2.2.2-3.0.4-201108301903.patch
+Patch:	4420_grsecurity-2.2.2-3.0.4-201109011725.patch
 From:	http://www.grsecurity.net
 Desc:	hardened-sources base patch from upstream grsecurity
 

diff --git a/3.0.4/4420_grsecurity-2.2.2-3.0.4-201108301903.patch b/3.0.4/4420_grsecurity-2.2.2-3.0.4-201109011725.patch
similarity index 99%
rename from 3.0.4/4420_grsecurity-2.2.2-3.0.4-201108301903.patch
rename to 3.0.4/4420_grsecurity-2.2.2-3.0.4-201109011725.patch
index 8d93a7b..1e39265 100644
--- a/3.0.4/4420_grsecurity-2.2.2-3.0.4-201108301903.patch
+++ b/3.0.4/4420_grsecurity-2.2.2-3.0.4-201109011725.patch
@@ -9898,17 +9898,6 @@ diff -urNp linux-3.0.4/arch/x86/include/asm/uaccess.h linux-3.0.4/arch/x86/inclu
  } while (0)
  
  #ifdef CONFIG_X86_WP_WORKS_OK
-diff -urNp linux-3.0.4/arch/x86/include/asm/vgtod.h linux-3.0.4/arch/x86/include/asm/vgtod.h
---- linux-3.0.4/arch/x86/include/asm/vgtod.h	2011-07-21 22:17:23.000000000 -0400
-+++ linux-3.0.4/arch/x86/include/asm/vgtod.h	2011-08-23 21:47:55.000000000 -0400
-@@ -14,6 +14,7 @@ struct vsyscall_gtod_data {
- 	int		sysctl_enabled;
- 	struct timezone sys_tz;
- 	struct { /* extract of a clocksource struct */
-+		char	name[8];
- 		cycle_t (*vread)(void);
- 		cycle_t	cycle_last;
- 		cycle_t	mask;
 diff -urNp linux-3.0.4/arch/x86/include/asm/x86_init.h linux-3.0.4/arch/x86/include/asm/x86_init.h
 --- linux-3.0.4/arch/x86/include/asm/x86_init.h	2011-07-21 22:17:23.000000000 -0400
 +++ linux-3.0.4/arch/x86/include/asm/x86_init.h	2011-08-23 21:47:55.000000000 -0400
@@ -57814,16 +57803,8 @@ diff -urNp linux-3.0.4/include/net/lapb.h linux-3.0.4/include/net/lapb.h
  	struct lapb_frame	frmr_data;
 diff -urNp linux-3.0.4/include/net/neighbour.h linux-3.0.4/include/net/neighbour.h
 --- linux-3.0.4/include/net/neighbour.h	2011-07-21 22:17:23.000000000 -0400
-+++ linux-3.0.4/include/net/neighbour.h	2011-08-26 19:49:56.000000000 -0400
-@@ -117,14 +117,14 @@ struct neighbour {
- };
- 
- struct neigh_ops {
--	int			family;
-+	const int		family;
- 	void			(*solicit)(struct neighbour *, struct sk_buff*);
- 	void			(*error_report)(struct neighbour *, struct sk_buff*);
- 	int			(*output)(struct sk_buff*);
++++ linux-3.0.4/include/net/neighbour.h	2011-08-31 18:39:25.000000000 -0400
+@@ -124,7 +124,7 @@ struct neigh_ops {
  	int			(*connected_output)(struct sk_buff*);
  	int			(*hh_output)(struct sk_buff*);
  	int			(*queue_xmit)(struct sk_buff*);
@@ -63160,7 +63141,7 @@ diff -urNp linux-3.0.4/localversion-grsec linux-3.0.4/localversion-grsec
 +-grsec
 diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
 --- linux-3.0.4/Makefile	2011-08-29 23:26:13.000000000 -0400
-+++ linux-3.0.4/Makefile	2011-08-30 18:24:49.000000000 -0400
++++ linux-3.0.4/Makefile	2011-09-01 17:26:49.000000000 -0400
 @@ -245,8 +245,9 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH"
  
  HOSTCC       = gcc
@@ -63186,7 +63167,15 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  KBUILD_AFLAGS_KERNEL :=
  KBUILD_CFLAGS_KERNEL :=
  KBUILD_AFLAGS   := -D__ASSEMBLY__
-@@ -564,6 +567,24 @@ else
+@@ -408,6 +411,7 @@ export RCS_TAR_IGNORE := --exclude SCCS 
+ 
+ # Basic helpers built in scripts/
+ PHONY += scripts_basic
++scripts_basic: KBUILD_CFLAGS := $(filter-out $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN),$(KBUILD_CFLAGS))
+ scripts_basic:
+ 	$(Q)$(MAKE) $(build)=scripts/basic
+ 	$(Q)rm -f .tmp_quiet_recordmcount
+@@ -564,6 +568,24 @@ else
  KBUILD_CFLAGS	+= -O2
  endif
  
@@ -63196,7 +63185,7 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
 +STACKLEAK_PLUGIN := -fplugin=$(objtree)/tools/gcc/stackleak_plugin.so -fplugin-arg-stackleak_plugin-track-lowest-sp=100
 +endif
 +export CONSTIFY_PLUGIN STACKLEAK_PLUGIN
-+gcc-plugins: prepare
++gcc-plugins:
 +	$(Q)$(MAKE) $(build)=tools/gcc
 +else
 +gcc-plugins:
@@ -63211,7 +63200,7 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  include $(srctree)/arch/$(SRCARCH)/Makefile
  
  ifneq ($(CONFIG_FRAME_WARN),0)
-@@ -708,7 +729,7 @@ export mod_strip_cmd
+@@ -708,7 +730,7 @@ export mod_strip_cmd
  
  
  ifeq ($(KBUILD_EXTMOD),)
@@ -63220,7 +63209,7 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  
  vmlinux-dirs	:= $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \
  		     $(core-y) $(core-m) $(drivers-y) $(drivers-m) \
-@@ -907,6 +928,8 @@ define rule_vmlinux-modpost
+@@ -907,6 +929,8 @@ define rule_vmlinux-modpost
  endef
  
  # vmlinux image - including updated kernel symbols
@@ -63229,35 +63218,25 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  vmlinux: $(vmlinux-lds) $(vmlinux-init) $(vmlinux-main) vmlinux.o $(kallsyms.o) FORCE
  ifdef CONFIG_HEADERS_CHECK
  	$(Q)$(MAKE) -f $(srctree)/Makefile headers_check
-@@ -932,7 +955,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): $(vmlinux-dirs) ;
-+$(sort $(vmlinux-init) $(vmlinux-main)) $(vmlinux-lds): prepare scripts $(vmlinux-dirs) ;
- 
- # Handle descending into subdirectories listed in $(vmlinux-dirs)
- # Preset locale variables to speed up the build process. Limit locale
-@@ -941,7 +964,7 @@ $(sort $(vmlinux-init) $(vmlinux-main)) 
+@@ -941,7 +965,8 @@ $(sort $(vmlinux-init) $(vmlinux-main)) 
  # Error messages still appears in the original language
  
  PHONY += $(vmlinux-dirs)
 -$(vmlinux-dirs): prepare scripts
-+$(vmlinux-dirs): gcc-plugins
++$(vmlinux-dirs): KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++$(vmlinux-dirs): gcc-plugins prepare scripts
  	$(Q)$(MAKE) $(build)=$@
  
  # Store (new) KERNELRELASE string in include/config/kernel.release
-@@ -1087,7 +1110,8 @@ all: modules
- #	using awk while concatenating to the final file.
+@@ -986,6 +1011,7 @@ prepare0: archprepare FORCE
+ 	$(Q)$(MAKE) $(build)=. missing-syscalls
  
- PHONY += modules
--modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin
-+$(vmlinux-dirs): KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
-+modules: prepare scripts $(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.';
- 	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
-@@ -1102,7 +1126,7 @@ modules.builtin: $(vmlinux-dirs:%=%/modu
+ # All the preparing..
++prepare: KBUILD_CFLAGS := $(filter-out $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN),$(KBUILD_CFLAGS))
+ prepare: prepare0
+ 
+ # Generate some files
+@@ -1102,7 +1128,7 @@ modules.builtin: $(vmlinux-dirs:%=%/modu
  
  # Target to prepare building external modules
  PHONY += modules_prepare
@@ -63266,7 +63245,7 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  
  # Target to install modules
  PHONY += modules_install
-@@ -1198,7 +1222,7 @@ distclean: mrproper
+@@ -1198,7 +1224,7 @@ distclean: mrproper
  	@find $(srctree) $(RCS_FIND_IGNORE) \
  		\( -name '*.orig' -o -name '*.rej' -o -name '*~' \
  		-o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \
@@ -63275,7 +63254,7 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  		-o -name '*%' -o -name '.*.cmd' -o -name 'core' \) \
  		-type f -print | xargs rm -f
  
-@@ -1359,6 +1383,7 @@ PHONY += $(module-dirs) modules
+@@ -1359,6 +1385,7 @@ PHONY += $(module-dirs) modules
  $(module-dirs): crmodverdir $(objtree)/Module.symvers
  	$(Q)$(MAKE) $(build)=$(patsubst _module_%,%,$@)
  
@@ -63283,7 +63262,13 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  modules: $(module-dirs)
  	@$(kecho) '  Building modules, stage 2.';
  	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
-@@ -1489,13 +1514,14 @@ endif
+@@ -1485,17 +1512,19 @@ else
+         target-dir = $(if $(KBUILD_EXTMOD),$(dir $<),$(dir $@))
+ endif
+ 
+-%.s: %.c prepare scripts FORCE
++%.s: KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++%.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 $@)
@@ -63293,13 +63278,30 @@ diff -urNp linux-3.0.4/Makefile linux-3.0.4/Makefile
  	$(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 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 +1534,13 @@ endif
+ 	$(cmd_crmodverdir)
+ 	$(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \
+ 	$(build)=$(build-dir)
+-%/: prepare scripts FORCE
++%/: KBUILD_CFLAGS += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++%/: 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 += $(CONSTIFY_PLUGIN) $(STACKLEAK_PLUGIN)
++%.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.4/mm/filemap.c linux-3.0.4/mm/filemap.c
 --- linux-3.0.4/mm/filemap.c	2011-07-21 22:17:23.000000000 -0400
 +++ linux-3.0.4/mm/filemap.c	2011-08-23 21:48:14.000000000 -0400
@@ -70892,10 +70894,10 @@ diff -urNp linux-3.0.4/scripts/basic/fixdep.c linux-3.0.4/scripts/basic/fixdep.c
  		fprintf(stderr, "fixdep: sizeof(int) != 4 or wrong endianess? %#x\n",
 diff -urNp linux-3.0.4/scripts/gcc-plugin.sh linux-3.0.4/scripts/gcc-plugin.sh
 --- linux-3.0.4/scripts/gcc-plugin.sh	1969-12-31 19:00:00.000000000 -0500
-+++ linux-3.0.4/scripts/gcc-plugin.sh	2011-08-23 21:47:56.000000000 -0400
++++ linux-3.0.4/scripts/gcc-plugin.sh	2011-08-31 18:39:25.000000000 -0400
 @@ -0,0 +1,2 @@
 +#!/bin/sh
-+echo "#include \"gcc-plugin.h\"" | $* -x c -shared - -o /dev/null -I`$* -print-file-name=plugin`/include >/dev/null 2>&1 && echo "y"
++echo "#include \"gcc-plugin.h\"\n#include \"rtl.h\"" | $* -x c -shared - -o /dev/null -I`$* -print-file-name=plugin`/include >/dev/null 2>&1 && echo "y"
 diff -urNp linux-3.0.4/scripts/Makefile.build linux-3.0.4/scripts/Makefile.build
 --- linux-3.0.4/scripts/Makefile.build	2011-07-21 22:17:23.000000000 -0400
 +++ linux-3.0.4/scripts/Makefile.build	2011-08-23 21:47:56.000000000 -0400



             reply	other threads:[~2011-09-04 12:34 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-04 12:34 Anthony G. Basile [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-09-15 17:57 [gentoo-commits] proj/hardened-patchset:master commit in: 2.6.32/, 3.0.4/ Anthony G. Basile
2011-09-21 11:31 Anthony G. Basile
2011-09-25 13:29 Anthony G. Basile
2011-09-25 13:32 Anthony G. Basile
2011-09-26 20:04 Anthony G. Basile
2011-10-08 13:57 Anthony G. Basile
2011-10-08 17:34 Anthony G. Basile

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4cf4ce297dfb5c629f33cfa08fbd7205b23bb3a7.blueness@gentoo \
    --to=blueness@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox