Patchwork [meta-fsl-ppc,01/26] linux-qoriq-sdk(-headers): upgrade to the version of sdk-1.4

login
register
mail settings
Submitter Ting Liu
Date June 27, 2013, 9:19 a.m.
Message ID <1372324802-4306-2-git-send-email-b28495@freescale.com>
Download mbox | patch
Permalink /patch/52399/
State Superseded
Headers show

Comments

Ting Liu - June 27, 2013, 9:19 a.m.
From: Zhenhua Luo <b19537@freescale.com>

1.Update kernel version to 3.8.

2.add DEPENDS libgcc and append TOOLCHAIN_OPTIONS to KERNEL_{CC,LD}.
kernel in sdk 1.4 need run-time support libraries 'libgcc.a', added
in file arch/powerpc/Makefile:
LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name)
Without passing the TOOLCHAIN_OPTIONS (define --sysroot parameter),
it will fail to find the libgcc.a.

3.Also remove the patches which were already merged on git tree.

Signed-off-by: Zhenhua Luo <zhenhua.luo@freescale.com>
Signed-off-by: Ting Liu <b28495@freescale.com>
---
 ...option-Automount-devtmpfs-at-dev-in-kerne.patch |   78 --------------------
 ...Undef-before-redefining-__attribute_const.patch |   28 -------
 ...-build-dependencies-for-c-files-requiring.patch |   44 -----------
 .../linux/files/fix_getrusage_for_perf.patch       |   33 --------
 ...efile.headersinst-install-headers-from-sc.patch |   46 ++++++++++++
 recipes-kernel/linux/linux-qoriq-sdk-headers.bb    |    4 +
 recipes-kernel/linux/linux-qoriq-sdk.bb            |    8 +-
 recipes-kernel/linux/linux-qoriq-sdk.inc           |    7 +-
 8 files changed, 57 insertions(+), 191 deletions(-)
 delete mode 100644 recipes-kernel/linux/files/0001-Enable-the-option-Automount-devtmpfs-at-dev-in-kerne.patch
 delete mode 100644 recipes-kernel/linux/files/0001-compiler.h-Undef-before-redefining-__attribute_const.patch
 delete mode 100644 recipes-kernel/linux/files/0001-powerpc-Fix-build-dependencies-for-c-files-requiring.patch
 delete mode 100644 recipes-kernel/linux/files/fix_getrusage_for_perf.patch
 create mode 100644 recipes-kernel/linux/files/scripts-Makefile.headersinst-install-headers-from-sc.patch

Patch

diff --git a/recipes-kernel/linux/files/0001-Enable-the-option-Automount-devtmpfs-at-dev-in-kerne.patch b/recipes-kernel/linux/files/0001-Enable-the-option-Automount-devtmpfs-at-dev-in-kerne.patch
deleted file mode 100644
index 39783ef..0000000
--- a/recipes-kernel/linux/files/0001-Enable-the-option-Automount-devtmpfs-at-dev-in-kerne.patch
+++ /dev/null
@@ -1,78 +0,0 @@ 
-From 3179602e581b6fe8797a5677d5ac4ecfab065cc6 Mon Sep 17 00:00:00 2001
-From: Chunrong Guo <B40290@freescale.com>
-Date: Thu, 11 Apr 2013 01:52:48 -0500
-Subject: [PATCH] Enable "the option Automount devtmpfs at /dev" in kernel
-
-Upstream-Status:Pending
-Signed-off-by: Chunrong Guo <b40290@freescale.com>
----
- arch/powerpc/configs/85xx/e6500rev1_defconfig |    1 +
- arch/powerpc/configs/corenet32_smp_defconfig  |    1 +
- arch/powerpc/configs/corenet64_smp_defconfig  |    1 +
- arch/powerpc/configs/mpc85xx_defconfig        |    1 +
- arch/powerpc/configs/mpc85xx_smp_defconfig    |    1 +
- 5 files changed, 5 insertions(+)
-
-diff --git a/arch/powerpc/configs/85xx/e6500rev1_defconfig b/arch/powerpc/configs/85xx/e6500rev1_defconfig
-index 4b5866d..32ebb50 100644
---- a/arch/powerpc/configs/85xx/e6500rev1_defconfig
-+++ b/arch/powerpc/configs/85xx/e6500rev1_defconfig
-@@ -72,6 +72,7 @@ CONFIG_IPV6=y
- CONFIG_IP_SCTP=m
- CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
- CONFIG_DEVTMPFS=y
-+CONFIG_DEVTMPFS_MOUNT=y
- CONFIG_MTD=y
- CONFIG_MTD_CMDLINE_PARTS=y
- CONFIG_MTD_CHAR=y
-diff --git a/arch/powerpc/configs/corenet32_smp_defconfig b/arch/powerpc/configs/corenet32_smp_defconfig
-index b43d4b6..3fe10e5 100644
---- a/arch/powerpc/configs/corenet32_smp_defconfig
-+++ b/arch/powerpc/configs/corenet32_smp_defconfig
-@@ -71,6 +71,7 @@ CONFIG_IPV6=y
- CONFIG_IP_SCTP=m
- CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
- CONFIG_DEVTMPFS=y
-+CONFIG_DEVTMPFS_MOUNT=y
- CONFIG_MTD=y
- CONFIG_MTD_CMDLINE_PARTS=y
- CONFIG_MTD_CHAR=y
-diff --git a/arch/powerpc/configs/corenet64_smp_defconfig b/arch/powerpc/configs/corenet64_smp_defconfig
-index 13b032b..74cc46a 100644
---- a/arch/powerpc/configs/corenet64_smp_defconfig
-+++ b/arch/powerpc/configs/corenet64_smp_defconfig
-@@ -66,6 +66,7 @@ CONFIG_IPV6=y
- CONFIG_IP_SCTP=m
- CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
- CONFIG_DEVTMPFS=y
-+CONFIG_DEVTMPFS_MOUNT=y
- CONFIG_MTD=y
- CONFIG_MTD_CMDLINE_PARTS=y
- CONFIG_MTD_CHAR=y
-diff --git a/arch/powerpc/configs/mpc85xx_defconfig b/arch/powerpc/configs/mpc85xx_defconfig
-index 8fb742d..f353a6e 100644
---- a/arch/powerpc/configs/mpc85xx_defconfig
-+++ b/arch/powerpc/configs/mpc85xx_defconfig
-@@ -75,6 +75,7 @@ CONFIG_IPV6=y
- CONFIG_IP_SCTP=m
- CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
- CONFIG_DEVTMPFS=y
-+CONFIG_DEVTMPFS_MOUNT=y
- CONFIG_MTD=y
- CONFIG_MTD_CHAR=y
- CONFIG_MTD_BLOCK=y
-diff --git a/arch/powerpc/configs/mpc85xx_smp_defconfig b/arch/powerpc/configs/mpc85xx_smp_defconfig
-index b31c8ac..cdc2c87 100644
---- a/arch/powerpc/configs/mpc85xx_smp_defconfig
-+++ b/arch/powerpc/configs/mpc85xx_smp_defconfig
-@@ -77,6 +77,7 @@ CONFIG_IPV6=y
- CONFIG_IP_SCTP=m
- CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
- CONFIG_DEVTMPFS=y
-+CONFIG_DEVTMPFS_MOUNT=y
- CONFIG_MTD=y
- CONFIG_MTD_CHAR=y
- CONFIG_MTD_BLOCK=y
--- 
-1.7.9.7
-
diff --git a/recipes-kernel/linux/files/0001-compiler.h-Undef-before-redefining-__attribute_const.patch b/recipes-kernel/linux/files/0001-compiler.h-Undef-before-redefining-__attribute_const.patch
deleted file mode 100644
index 597fd3b..0000000
--- a/recipes-kernel/linux/files/0001-compiler.h-Undef-before-redefining-__attribute_const.patch
+++ /dev/null
@@ -1,28 +0,0 @@ 
-From 6f92ab6de9d8daeb575949bbbcbc7bcdcebc60af Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem at gmail.com>
-Date: Thu, 5 Jan 2012 11:42:35 -0800
-Subject: [PATCH] compiler.h: Undef before redefining __attribute_const__
-
-This is required to avoid warnings like
-util/include/linux/compiler.h:8:0: error: "__attribute_const__" redefined [-Werror]
-
-Signed-off-by: Khem Raj <raj.khem at gmail.com>
----
- tools/perf/util/include/linux/compiler.h |    4 +++-
- 1 files changed, 3 insertions(+), 1 deletions(-)
-
---- a/tools/perf/util/include/linux/compiler.h
-+++ b/tools/perf/util/include/linux/compiler.h
-@@ -4,9 +4,11 @@
- #ifndef __always_inline
- #define __always_inline	inline
- #endif
-+#undef __user
- #define __user
-+#undef __attribute_const__
- #define __attribute_const__
--
-+#undef __used
- #define __used		__attribute__((__unused__))
- 
- #endif
diff --git a/recipes-kernel/linux/files/0001-powerpc-Fix-build-dependencies-for-c-files-requiring.patch b/recipes-kernel/linux/files/0001-powerpc-Fix-build-dependencies-for-c-files-requiring.patch
deleted file mode 100644
index d3464fb..0000000
--- a/recipes-kernel/linux/files/0001-powerpc-Fix-build-dependencies-for-c-files-requiring.patch
+++ /dev/null
@@ -1,44 +0,0 @@ 
-Upstream-Status: Pending
-
-From 2e7ffea0c0c09c6d9219d604e0351423f43844f4 Mon Sep 17 00:00:00 2001
-From: Matthew McClintock <msm@freescale.com>
-Date: Thu, 6 Sep 2012 13:45:21 -0500
-Subject: powerpc: Fix build dependencies for c files requiring libfdt.h
-
-Several files in obj-plat depend on libfdt header file. Sometimes
-when building one can see the following issue. This patch adds
-libfdt as dependency to those object files
-
-| In file included from arch/powerpc/boot/treeboot-iss4xx.c:33:0:
-| arch/powerpc/boot/libfdt.h:854:1: error: unterminated comment
-| In file included from arch/powerpc/boot/treeboot-iss4xx.c:33:0:
-| arch/powerpc/boot/libfdt.h:1:0: error: unterminated #ifndef
-|   BOOTCC  arch/powerpc/boot/inffast.o
-| make[1]: *** [arch/powerpc/boot/treeboot-iss4xx.o] Error 1
-| make[1]: *** Waiting for unfinished jobs....
-|   BOOTCC  arch/powerpc/boot/inflate.o
-| make: *** [uImage] Error 2
-| ERROR: oe_runmake failed
-| ERROR: Function failed: do_compile (see /srv/home/pokybuild/yocto-autobuilder/yocto-slave/p1022ds/build/build/tmp/work/p1022ds-poky-linux-gnuspe/linux-qoriq-sdk-3.0.34-r5/temp/log.do_compile.2167 for further information)
-NOTE: recipe linux-qoriq-sdk-3.0.34-r5: task do_compile: Failed
-
-Signed-off-by: Matthew McClintock <msm@freescale.com>
----
- arch/powerpc/boot/Makefile |    1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/arch/powerpc/boot/Makefile b/arch/powerpc/boot/Makefile
-index b7d8333..6a15c96 100644
---- a/arch/powerpc/boot/Makefile
-+++ b/arch/powerpc/boot/Makefile
-@@ -107,6 +107,7 @@ src-boot := $(addprefix $(obj)/, $(src-boot))
- obj-boot := $(addsuffix .o, $(basename $(src-boot)))
- obj-wlib := $(addsuffix .o, $(basename $(addprefix $(obj)/, $(src-wlib))))
- obj-plat := $(addsuffix .o, $(basename $(addprefix $(obj)/, $(src-plat))))
-+obj-plat: $(libfdt)
- 
- quiet_cmd_copy_zlib = COPY    $@
-       cmd_copy_zlib = sed "s@__used@@;s@<linux/\([^>]*\).*@\"\1\"@" $< > $@
--- 
-1.7.9.7
-
diff --git a/recipes-kernel/linux/files/fix_getrusage_for_perf.patch b/recipes-kernel/linux/files/fix_getrusage_for_perf.patch
deleted file mode 100644
index 0029fdc..0000000
--- a/recipes-kernel/linux/files/fix_getrusage_for_perf.patch
+++ /dev/null
@@ -1,33 +0,0 @@ 
-commit 7b78f13603c6fcb64e020a0bbe31a651ea2b657b
-Author: Markus Trippelsdorf <markus@trippelsdorf.de>
-Date: Wed Apr 4 10:45:27 2012 +0200
-
-    perf tools: Fix getrusage() related build failure on glibc trunk
-    
-    On a system running glibc trunk perf doesn't build:
-    
-        CC builtin-sched.o
-    builtin-sched.c: In function ‘get_cpu_usage_nsec_parent’: builtin-sched.c:399:16: error: storage size of ‘ru’ isn’t known builtin-sched.c:403:2: error: implicit declaration of function ‘getrusage’ [-Werror=implicit-function-declaration]
-        [...]
-    
-    Fix it by including sys/resource.h.
-    
-    Signed-off-by: Markus Trippelsdorf <markus@trippelsdorf.de>
-    Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
-    Link: http://lkml.kernel.org/r/20120404084527.GA294@x4
-    Signed-off-by: Ingo Molnar <mingo@kernel.org>
-
-Upstream-Status: Backport [3.4]
-
-diff --git a/tools/perf/builtin-sched.c b/tools/perf/builtin-sched.c
-index fb8b5f8..1cad3af 100644
---- a/tools/perf/builtin-sched.c
-+++ b/tools/perf/builtin-sched.c
-@@ -17,6 +17,7 @@
- #include "util/debug.h"
- 
- #include <sys/prctl.h>
-+#include <sys/resource.h>
- 
- #include <semaphore.h>
- #include <pthread.h>
diff --git a/recipes-kernel/linux/files/scripts-Makefile.headersinst-install-headers-from-sc.patch b/recipes-kernel/linux/files/scripts-Makefile.headersinst-install-headers-from-sc.patch
new file mode 100644
index 0000000..0f28d3d
--- /dev/null
+++ b/recipes-kernel/linux/files/scripts-Makefile.headersinst-install-headers-from-sc.patch
@@ -0,0 +1,46 @@ 
+From e60cc1b011bf0f1acdb7e5168b7bed4ebb78c91f Mon Sep 17 00:00:00 2001
+From: Bruce Ashfield <bruce.ashfield@windriver.com>
+Date: Wed, 9 Jan 2013 16:24:39 -0500
+Subject: [PATCH] scripts/Makefile.headersinst: install headers from scratch file
+
+If headers_install is executed from a deep/long directory structure, the
+shell's maximum argument length can be execeeded, which breaks the operation
+with:
+
+| make[2]: execvp: /bin/sh: Argument list too long
+| make[2]: ***
+
+By dumping the input files to a scratch file and using xargs to read the
+input list from the scratch file, we can avoid blowing out the maximum
+argument size and install headers in a long path name environment.
+
+Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
+---
+ scripts/Makefile.headersinst |    4 +++-
+ 1 files changed, 3 insertions(+), 1 deletions(-)
+
+diff --git a/scripts/Makefile.headersinst b/scripts/Makefile.headersinst
+index 06ba4a7..536d722 100644
+--- a/scripts/Makefile.headersinst
++++ b/scripts/Makefile.headersinst
+@@ -71,7 +71,7 @@ printdir = $(patsubst $(INSTALL_HDR_PATH)/%/,%,$(dir $@))
+ quiet_cmd_install = INSTALL $(printdir) ($(words $(all-files))\
+                             file$(if $(word 2, $(all-files)),s))
+       cmd_install = \
+-        $(PERL) $< $(installdir) $(SRCARCH) $(input-files); \
++        xargs $(PERL) $< $(installdir) $(SRCARCH) < $(INSTALL_HDR_PATH)/.input-files; \
+         for F in $(wrapper-files); do                                   \
+                 echo "\#include <asm-generic/$$F>" > $(installdir)/$$F;    \
+         done;                                                           \
+@@ -100,7 +100,9 @@ targets += $(install-file)
+ $(install-file): scripts/headers_install.pl $(input-files) FORCE
+ 	$(if $(unwanted),$(call cmd,remove),)
+ 	$(if $(wildcard $(dir $@)),,$(shell mkdir -p $(dir $@)))
++	@echo $(input-files) > $(INSTALL_HDR_PATH)/.input-files
+ 	$(call if_changed,install)
++	@rm $(INSTALL_HDR_PATH)/.input-files
+ 
+ else
+ __headerscheck: $(subdirs) $(check-file)
+-- 
+1.7.0.4
diff --git a/recipes-kernel/linux/linux-qoriq-sdk-headers.bb b/recipes-kernel/linux/linux-qoriq-sdk-headers.bb
index b1cbb8d..0ee4fc1 100644
--- a/recipes-kernel/linux/linux-qoriq-sdk-headers.bb
+++ b/recipes-kernel/linux/linux-qoriq-sdk-headers.bb
@@ -2,6 +2,8 @@  DESCRIPTION = "Linux kernel headers for Freescale platforms"
 SECTION = "devel"
 LICENSE = "GPLv2"
 
+PR = "${INC_PR}.1"
+
 INHIBIT_DEFAULT_DEPS = "1"
 PROVIDES = "linux-libc-headers ${PN}"
 RPROVIDES_${PN}-dev += "linux-libc-headers-dev"
@@ -11,6 +13,8 @@  RRECOMMENDS_${PN}-dbg = "linux-libc-headers-dev (= ${EXTENDPKGV})"
 
 require recipes-kernel/linux/linux-qoriq-sdk.inc
 
+SRC_URI_append += " file://scripts-Makefile.headersinst-install-headers-from-sc.patch"
+
 inherit kernel-arch
 
 do_configure() {
diff --git a/recipes-kernel/linux/linux-qoriq-sdk.bb b/recipes-kernel/linux/linux-qoriq-sdk.bb
index a015e49..502132f 100644
--- a/recipes-kernel/linux/linux-qoriq-sdk.bb
+++ b/recipes-kernel/linux/linux-qoriq-sdk.bb
@@ -7,11 +7,11 @@  LICENSE = "GPLv2"
 
 require recipes-kernel/linux/linux-qoriq-sdk.inc
 
-PR = "r11"
+PR = "${INC_PR}.1"
 
-SRC_URI += "file://fix_getrusage_for_perf.patch \
-            file://0001-Enable-the-option-Automount-devtmpfs-at-dev-in-kerne.patch \
-           "
+DEPENDS_append = " libgcc"
+KERNEL_CC_append = " ${TOOLCHAIN_OPTIONS}"
+KERNEL_LD_append = " ${TOOLCHAIN_OPTIONS}"
 
 do_configure_prepend() {
 	# copy desired defconfig so we pick it up for the real kernel_do_configure
diff --git a/recipes-kernel/linux/linux-qoriq-sdk.inc b/recipes-kernel/linux/linux-qoriq-sdk.inc
index f77543e..3047ba5 100644
--- a/recipes-kernel/linux/linux-qoriq-sdk.inc
+++ b/recipes-kernel/linux/linux-qoriq-sdk.inc
@@ -1,11 +1,10 @@ 
 LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
 
-PV = "3.0.51"
-PR = "r11"
+PV = "3.8"
+INC_PR = "r12"
 
-SRCREV = "faac5211f398f25e2be44ac996895335d5218516"
+SRCREV = "4b66366af2d77de68f4bd6548d07421e13d3df05"
 SRC_URI = "git://git.freescale.com/ppc/sdk/linux.git \
-           file://0001-compiler.h-Undef-before-redefining-__attribute_const.patch \
 	  "
 
 KSRC ?= ""