]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.0-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Oct 2012 15:57:35 +0000 (08:57 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Oct 2012 15:57:35 +0000 (08:57 -0700)
added patches:
kbuild-make-fix-if_changed-when-command-contains-backslashes.patch
mn10300-only-add-mmem-funcs-to-kbuild_cflags-if-gcc-supports-it.patch

queue-3.0/kbuild-make-fix-if_changed-when-command-contains-backslashes.patch [new file with mode: 0644]
queue-3.0/mn10300-only-add-mmem-funcs-to-kbuild_cflags-if-gcc-supports-it.patch [new file with mode: 0644]
queue-3.0/series [new file with mode: 0644]

diff --git a/queue-3.0/kbuild-make-fix-if_changed-when-command-contains-backslashes.patch b/queue-3.0/kbuild-make-fix-if_changed-when-command-contains-backslashes.patch
new file mode 100644 (file)
index 0000000..65d99bc
--- /dev/null
@@ -0,0 +1,43 @@
+From c353acba28fb3fa1fd05fd6b85a9fc7938330f9c Mon Sep 17 00:00:00 2001
+From: Sascha Hauer <s.hauer@pengutronix.de>
+Date: Thu, 4 Oct 2012 17:11:17 -0700
+Subject: kbuild: make: fix if_changed when command contains backslashes
+
+From: Sascha Hauer <s.hauer@pengutronix.de>
+
+commit c353acba28fb3fa1fd05fd6b85a9fc7938330f9c upstream.
+
+The call if_changed mechanism does not work when the command contains
+backslashes.  This basically is an issue with lzo and bzip2 compressed
+kernels.  The compressed binaries do not contain the uncompressed image
+size, so these use size_append to append the size.  This results in
+backslashes in the executed command.  With this if_changed always
+detects a change in the command and rebuilds the compressed image even
+if nothing has changed.
+
+Fix this by escaping backslashes in make-cmd
+
+Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
+Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
+Cc: Sam Ravnborg <sam@ravnborg.org>
+Cc: Bernhard Walle <bernhard@bwalle.de>
+Cc: Michal Marek <mmarek@suse.cz>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ scripts/Kbuild.include |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/scripts/Kbuild.include
++++ b/scripts/Kbuild.include
+@@ -205,7 +205,7 @@ endif
+ # >$< substitution to preserve $ when reloading .cmd file
+ # note: when using inline perl scripts [perl -e '...$$t=1;...']
+ # in $(cmd_xxx) double $$ your perl vars
+-make-cmd = $(subst \#,\\\#,$(subst $$,$$$$,$(call escsq,$(cmd_$(1)))))
++make-cmd = $(subst \\,\\\\,$(subst \#,\\\#,$(subst $$,$$$$,$(call escsq,$(cmd_$(1))))))
+ # Find any prerequisites that is newer than target or that does not exist.
+ # PHONY targets skipped in both cases.
diff --git a/queue-3.0/mn10300-only-add-mmem-funcs-to-kbuild_cflags-if-gcc-supports-it.patch b/queue-3.0/mn10300-only-add-mmem-funcs-to-kbuild_cflags-if-gcc-supports-it.patch
new file mode 100644 (file)
index 0000000..805fc67
--- /dev/null
@@ -0,0 +1,38 @@
+From 9957423f035c2071f6d1c5d2f095cdafbeb25ad7 Mon Sep 17 00:00:00 2001
+From: Geert Uytterhoeven <geert@linux-m68k.org>
+Date: Thu, 4 Oct 2012 17:11:13 -0700
+Subject: mn10300: only add -mmem-funcs to KBUILD_CFLAGS if gcc supports it
+
+From: Geert Uytterhoeven <geert@linux-m68k.org>
+
+commit 9957423f035c2071f6d1c5d2f095cdafbeb25ad7 upstream.
+
+It seems the current (gcc 4.6.3) no longer provides this so make it
+conditional.
+
+As reported by Tony before, the mn10300 architecture cross-compiles with
+gcc-4.6.3 if -mmem-funcs is not added to KBUILD_CFLAGS.
+
+Reported-by: Tony Breeds <tony@bakeyournoodle.com>
+Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
+Cc: David Howells <dhowells@redhat.com>
+Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/mn10300/Makefile |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/mn10300/Makefile
++++ b/arch/mn10300/Makefile
+@@ -26,7 +26,7 @@ CHECKFLAGS   +=
+ PROCESSOR     := unset
+ UNIT          := unset
+-KBUILD_CFLAGS += -mam33 -mmem-funcs -DCPU=AM33
++KBUILD_CFLAGS += -mam33 -DCPU=AM33 $(call cc-option,-mmem-funcs,)
+ KBUILD_AFLAGS += -mam33 -DCPU=AM33
+ ifeq ($(CONFIG_MN10300_CURRENT_IN_E2),y)
diff --git a/queue-3.0/series b/queue-3.0/series
new file mode 100644 (file)
index 0000000..30ebb2e
--- /dev/null
@@ -0,0 +1,2 @@
+mn10300-only-add-mmem-funcs-to-kbuild_cflags-if-gcc-supports-it.patch
+kbuild-make-fix-if_changed-when-command-contains-backslashes.patch