All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCHv2] linux-omap-psp: fix alignment issue of 2.6.37 kernel with gcc-4.7
@ 2013-02-26  4:42 Denys Dmytriyenko
  2013-02-26  6:18 ` Khem Raj
  0 siblings, 1 reply; 5+ messages in thread
From: Denys Dmytriyenko @ 2013-02-26  4:42 UTC (permalink / raw)
  To: meta-ti

From: Denys Dmytriyenko <denys@ti.com>

Patch by Steve Sakoman

Signed-off-by: Denys Dmytriyenko <denys@ti.com>
---
v2 - move patch to a common location

 .../files/0001-arm-fix-builds-with-gcc-4.7.patch   | 26 ++++++++++++++++++++++
 recipes-kernel/linux/linux-omap-psp_2.6.37.bb      |  9 ++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch

diff --git a/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch b/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
new file mode 100644
index 0000000..db701e2
--- /dev/null
+++ b/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
@@ -0,0 +1,26 @@
+From 0d12debe917269a013f8eddd42da8d3de5e3174e Mon Sep 17 00:00:00 2001
+From: Steve Sakoman <steve@sakoman.com>
+Date: Thu, 24 Jan 2013 15:42:01 -0800
+Subject: [PATCH] arm: fix builds with gcc 4.7
+
+new unaligned access support in GCC was triggering an alignment fault at boot
+---
+ arch/arm/kernel/head.S | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/arch/arm/kernel/head.S b/arch/arm/kernel/head.S
+index 6bd82d2..56b02cd 100644
+--- a/arch/arm/kernel/head.S
++++ b/arch/arm/kernel/head.S
+@@ -336,7 +336,7 @@ __secondary_data:
+  *  r13 = *virtual* address to jump to upon completion
+  */
+ __enable_mmu:
+-#ifdef CONFIG_ALIGNMENT_TRAP
++#if defined(CONFIG_ALIGNMENT_TRAP) && __LINUX_ARM_ARCH__ < 6
+ 	orr	r0, r0, #CR_A
+ #else
+ 	bic	r0, r0, #CR_A
+-- 
+1.8.1.2
+
diff --git a/recipes-kernel/linux/linux-omap-psp_2.6.37.bb b/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
index bafeba5..9eacfc9 100644
--- a/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
+++ b/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
@@ -6,6 +6,10 @@ COMPATIBLE_MACHINE = "omap3"
 
 SRCREV= "20c003f2f024d9f50f59edf9f1b8f5f035fb15b8"
 
+# The main PR is now using MACHINE_KERNEL_PR, for omap3 devices
+# see conf/machine/include/omap3.inc
+MACHINE_KERNEL_PR_append = "a"
+
 SRC_URI = "git://arago-project.org/git/projects/linux-omap3.git;protocol=git \
            file://defconfig"
 
@@ -83,6 +87,11 @@ SRC_URI += " \
     file://0002-usb-musb-am35x-fix-role-switching-issue.patch \
 "
 
+# Fix alignment issue with gcc-4.7
+SRC_URI += " \
+    file://0001-arm-fix-builds-with-gcc-4.7.patch \
+"
+
 # Updated PIO mode for MUSB help description
 SRC_URI_append_am3517-evm = " file://0001-musb-update-PIO-mode-help-information-in-Kconfig.patch"
 
-- 
1.8.1.4



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCHv2] linux-omap-psp: fix alignment issue of 2.6.37 kernel with gcc-4.7
  2013-02-26  4:42 [PATCHv2] linux-omap-psp: fix alignment issue of 2.6.37 kernel with gcc-4.7 Denys Dmytriyenko
@ 2013-02-26  6:18 ` Khem Raj
  2013-02-26  6:28   ` Denys Dmytriyenko
  0 siblings, 1 reply; 5+ messages in thread
From: Khem Raj @ 2013-02-26  6:18 UTC (permalink / raw)
  To: Denys Dmytriyenko; +Cc: meta-ti

On Mon, Feb 25, 2013 at 8:42 PM, Denys Dmytriyenko <denis@denix.org> wrote:
> From: Denys Dmytriyenko <denys@ti.com>
>
> Patch by Steve Sakoman
>
> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
> ---
> v2 - move patch to a common location

btw. this wont be needed in kernels released after
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commit;h=8428e84d42179c2a00f5f6450866e70d802d1d05

so probably its better stay in specific kernel dirs which need it.

>
>  .../files/0001-arm-fix-builds-with-gcc-4.7.patch   | 26 ++++++++++++++++++++++
>  recipes-kernel/linux/linux-omap-psp_2.6.37.bb      |  9 ++++++++
>  2 files changed, 35 insertions(+)
>  create mode 100644 recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
>
> diff --git a/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch b/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
> new file mode 100644
> index 0000000..db701e2
> --- /dev/null
> +++ b/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
> @@ -0,0 +1,26 @@
> +From 0d12debe917269a013f8eddd42da8d3de5e3174e Mon Sep 17 00:00:00 2001
> +From: Steve Sakoman <steve@sakoman.com>
> +Date: Thu, 24 Jan 2013 15:42:01 -0800
> +Subject: [PATCH] arm: fix builds with gcc 4.7
> +
> +new unaligned access support in GCC was triggering an alignment fault at boot
> +---
> + arch/arm/kernel/head.S | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/arch/arm/kernel/head.S b/arch/arm/kernel/head.S
> +index 6bd82d2..56b02cd 100644
> +--- a/arch/arm/kernel/head.S
> ++++ b/arch/arm/kernel/head.S
> +@@ -336,7 +336,7 @@ __secondary_data:
> +  *  r13 = *virtual* address to jump to upon completion
> +  */
> + __enable_mmu:
> +-#ifdef CONFIG_ALIGNMENT_TRAP
> ++#if defined(CONFIG_ALIGNMENT_TRAP) && __LINUX_ARM_ARCH__ < 6
> +       orr     r0, r0, #CR_A
> + #else
> +       bic     r0, r0, #CR_A
> +--
> +1.8.1.2
> +
> diff --git a/recipes-kernel/linux/linux-omap-psp_2.6.37.bb b/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
> index bafeba5..9eacfc9 100644
> --- a/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
> +++ b/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
> @@ -6,6 +6,10 @@ COMPATIBLE_MACHINE = "omap3"
>
>  SRCREV= "20c003f2f024d9f50f59edf9f1b8f5f035fb15b8"
>
> +# The main PR is now using MACHINE_KERNEL_PR, for omap3 devices
> +# see conf/machine/include/omap3.inc
> +MACHINE_KERNEL_PR_append = "a"
> +
>  SRC_URI = "git://arago-project.org/git/projects/linux-omap3.git;protocol=git \
>             file://defconfig"
>
> @@ -83,6 +87,11 @@ SRC_URI += " \
>      file://0002-usb-musb-am35x-fix-role-switching-issue.patch \
>  "
>
> +# Fix alignment issue with gcc-4.7
> +SRC_URI += " \
> +    file://0001-arm-fix-builds-with-gcc-4.7.patch \
> +"
> +
>  # Updated PIO mode for MUSB help description
>  SRC_URI_append_am3517-evm = " file://0001-musb-update-PIO-mode-help-information-in-Kconfig.patch"
>
> --
> 1.8.1.4
>
> _______________________________________________
> meta-ti mailing list
> meta-ti@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/meta-ti


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCHv2] linux-omap-psp: fix alignment issue of 2.6.37 kernel with gcc-4.7
  2013-02-26  6:18 ` Khem Raj
@ 2013-02-26  6:28   ` Denys Dmytriyenko
  2013-02-26  6:52     ` Khem Raj
  0 siblings, 1 reply; 5+ messages in thread
From: Denys Dmytriyenko @ 2013-02-26  6:28 UTC (permalink / raw)
  To: Khem Raj; +Cc: meta-ti

On Mon, Feb 25, 2013 at 10:18:15PM -0800, Khem Raj wrote:
> On Mon, Feb 25, 2013 at 8:42 PM, Denys Dmytriyenko <denis@denix.org> wrote:
> > From: Denys Dmytriyenko <denys@ti.com>
> >
> > Patch by Steve Sakoman
> >
> > Signed-off-by: Denys Dmytriyenko <denys@ti.com>
> > ---
> > v2 - move patch to a common location
> 
> btw. this wont be needed in kernels released after
> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commit;h=8428e84d42179c2a00f5f6450866e70d802d1d05

Yes, I know. That's why I was clear to mention the specific version in the 
commit.

> so probably its better stay in specific kernel dirs which need it.

We have at least 3 kernel recipes of 2.6.37 version, hence the common location 
for this patch. I don't plan on updating older kernels to work with gcc-4.7.

-- 
Denys

> >  .../files/0001-arm-fix-builds-with-gcc-4.7.patch   | 26 ++++++++++++++++++++++
> >  recipes-kernel/linux/linux-omap-psp_2.6.37.bb      |  9 ++++++++
> >  2 files changed, 35 insertions(+)
> >  create mode 100644 recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
> >
> > diff --git a/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch b/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
> > new file mode 100644
> > index 0000000..db701e2
> > --- /dev/null
> > +++ b/recipes-kernel/linux/files/0001-arm-fix-builds-with-gcc-4.7.patch
> > @@ -0,0 +1,26 @@
> > +From 0d12debe917269a013f8eddd42da8d3de5e3174e Mon Sep 17 00:00:00 2001
> > +From: Steve Sakoman <steve@sakoman.com>
> > +Date: Thu, 24 Jan 2013 15:42:01 -0800
> > +Subject: [PATCH] arm: fix builds with gcc 4.7
> > +
> > +new unaligned access support in GCC was triggering an alignment fault at boot
> > +---
> > + arch/arm/kernel/head.S | 2 +-
> > + 1 file changed, 1 insertion(+), 1 deletion(-)
> > +
> > +diff --git a/arch/arm/kernel/head.S b/arch/arm/kernel/head.S
> > +index 6bd82d2..56b02cd 100644
> > +--- a/arch/arm/kernel/head.S
> > ++++ b/arch/arm/kernel/head.S
> > +@@ -336,7 +336,7 @@ __secondary_data:
> > +  *  r13 = *virtual* address to jump to upon completion
> > +  */
> > + __enable_mmu:
> > +-#ifdef CONFIG_ALIGNMENT_TRAP
> > ++#if defined(CONFIG_ALIGNMENT_TRAP) && __LINUX_ARM_ARCH__ < 6
> > +       orr     r0, r0, #CR_A
> > + #else
> > +       bic     r0, r0, #CR_A
> > +--
> > +1.8.1.2
> > +
> > diff --git a/recipes-kernel/linux/linux-omap-psp_2.6.37.bb b/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
> > index bafeba5..9eacfc9 100644
> > --- a/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
> > +++ b/recipes-kernel/linux/linux-omap-psp_2.6.37.bb
> > @@ -6,6 +6,10 @@ COMPATIBLE_MACHINE = "omap3"
> >
> >  SRCREV= "20c003f2f024d9f50f59edf9f1b8f5f035fb15b8"
> >
> > +# The main PR is now using MACHINE_KERNEL_PR, for omap3 devices
> > +# see conf/machine/include/omap3.inc
> > +MACHINE_KERNEL_PR_append = "a"
> > +
> >  SRC_URI = "git://arago-project.org/git/projects/linux-omap3.git;protocol=git \
> >             file://defconfig"
> >
> > @@ -83,6 +87,11 @@ SRC_URI += " \
> >      file://0002-usb-musb-am35x-fix-role-switching-issue.patch \
> >  "
> >
> > +# Fix alignment issue with gcc-4.7
> > +SRC_URI += " \
> > +    file://0001-arm-fix-builds-with-gcc-4.7.patch \
> > +"
> > +
> >  # Updated PIO mode for MUSB help description
> >  SRC_URI_append_am3517-evm = " file://0001-musb-update-PIO-mode-help-information-in-Kconfig.patch"
> >
> > --
> > 1.8.1.4
> >
> > _______________________________________________
> > meta-ti mailing list
> > meta-ti@yoctoproject.org
> > https://lists.yoctoproject.org/listinfo/meta-ti
> 


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCHv2] linux-omap-psp: fix alignment issue of 2.6.37 kernel with gcc-4.7
  2013-02-26  6:28   ` Denys Dmytriyenko
@ 2013-02-26  6:52     ` Khem Raj
  2013-02-26 18:08       ` Denys Dmytriyenko
  0 siblings, 1 reply; 5+ messages in thread
From: Khem Raj @ 2013-02-26  6:52 UTC (permalink / raw)
  To: Denys Dmytriyenko; +Cc: meta-ti

On Mon, Feb 25, 2013 at 10:28 PM, Denys Dmytriyenko <denys@ti.com> wrote:
>
>
> We have at least 3 kernel recipes of 2.6.37 version, hence the common location
> for this patch. I don't plan on updating older kernels to work with gcc-4.7.

it depends on how its all organised. In my view something in files/
applies to all recipes under that dir
and then you have ${PN} and ${PN}-${PV} and so on to make it more and
more specific. On another extreme you can also have a flat
structure if you dont have conflicting patches. As it seems you have
something in the middle


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCHv2] linux-omap-psp: fix alignment issue of 2.6.37 kernel with gcc-4.7
  2013-02-26  6:52     ` Khem Raj
@ 2013-02-26 18:08       ` Denys Dmytriyenko
  0 siblings, 0 replies; 5+ messages in thread
From: Denys Dmytriyenko @ 2013-02-26 18:08 UTC (permalink / raw)
  To: Khem Raj; +Cc: meta-ti

On Mon, Feb 25, 2013 at 10:52:42PM -0800, Khem Raj wrote:
> On Mon, Feb 25, 2013 at 10:28 PM, Denys Dmytriyenko <denys@ti.com> wrote:
> >
> >
> > We have at least 3 kernel recipes of 2.6.37 version, hence the common location
> > for this patch. I don't plan on updating older kernels to work with gcc-4.7.
> 
> it depends on how its all organised. In my view something in files/
> applies to all recipes under that dir
> and then you have ${PN} and ${PN}-${PV} and so on to make it more and
> more specific. On another extreme you can also have a flat
> structure if you dont have conflicting patches. As it seems you have
> something in the middle

Yes, correct, the same patch applies to multiple different kernel recipes. 
Unfortunately, they all have different ${PN}, thus cannot share the same ${PN} 
or ${PN}-${PV} directories. And having patches residing in the common files/ 
directory when used by multiple recipes (but not all of them) is allowed and 
there are existing instances out there already...

-- 
Denys


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-02-26 18:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-26  4:42 [PATCHv2] linux-omap-psp: fix alignment issue of 2.6.37 kernel with gcc-4.7 Denys Dmytriyenko
2013-02-26  6:18 ` Khem Raj
2013-02-26  6:28   ` Denys Dmytriyenko
2013-02-26  6:52     ` Khem Raj
2013-02-26 18:08       ` Denys Dmytriyenko

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.