linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code.
@ 2012-07-09 12:58 Varun Sethi
  2012-08-03 16:34 ` Kumar Gala
  0 siblings, 1 reply; 5+ messages in thread
From: Varun Sethi @ 2012-07-09 12:58 UTC (permalink / raw)
  To: agraf, galak, benh, linuxppc-dev, kvm-ppc; +Cc: Varun Sethi

Merge the 32 bit cpu setup code for e500mc/e5500 and define the "cpu_restore"
routine (for e5500/e6500) only for the 64 bit case. The cpu_restore routine
is used in the 64 bit case for setting up the secondary cores.

Signed-off-by: Varun Sethi <Varun.Sethi@freescale.com>
---
 arch/powerpc/kernel/cpu_setup_fsl_booke.S |    1 +
 arch/powerpc/kernel/cputable.c            |    4 ++++
 2 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
index a55d028..5e87737 100644
--- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
+++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
@@ -75,6 +75,7 @@ _GLOBAL(__setup_cpu_e500v2)
 	mtlr	r4
 	blr
 _GLOBAL(__setup_cpu_e500mc)
+_GLOBAL(__setup_cpu_e5500)
 	mflr	r5
 	bl	__e500_icache_setup
 	bl	__e500_dcache_setup
diff --git a/arch/powerpc/kernel/cputable.c b/arch/powerpc/kernel/cputable.c
index 455faa3..0514c21 100644
--- a/arch/powerpc/kernel/cputable.c
+++ b/arch/powerpc/kernel/cputable.c
@@ -2016,7 +2016,9 @@ static struct cpu_spec __initdata cpu_specs[] = {
 		.oprofile_cpu_type	= "ppc/e500mc",
 		.oprofile_type		= PPC_OPROFILE_FSL_EMB,
 		.cpu_setup		= __setup_cpu_e5500,
+#ifndef CONFIG_PPC32
 		.cpu_restore		= __restore_cpu_e5500,
+#endif
 		.machine_check		= machine_check_e500mc,
 		.platform		= "ppce5500",
 	},
@@ -2034,7 +2036,9 @@ static struct cpu_spec __initdata cpu_specs[] = {
 		.oprofile_cpu_type	= "ppc/e6500",
 		.oprofile_type		= PPC_OPROFILE_FSL_EMB,
 		.cpu_setup		= __setup_cpu_e5500,
+#ifndef CONFIG_PPC32
 		.cpu_restore		= __restore_cpu_e5500,
+#endif
 		.machine_check		= machine_check_e500mc,
 		.platform		= "ppce6500",
 	},
-- 
1.7.4.1

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

* Re: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code.
  2012-07-09 12:58 [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code Varun Sethi
@ 2012-08-03 16:34 ` Kumar Gala
  2012-08-04 18:31   ` Sethi Varun-B16395
  0 siblings, 1 reply; 5+ messages in thread
From: Kumar Gala @ 2012-08-03 16:34 UTC (permalink / raw)
  To: Varun Sethi; +Cc: linuxppc-dev, agraf, kvm-ppc


On Jul 9, 2012, at 7:58 AM, Varun Sethi wrote:

> Merge the 32 bit cpu setup code for e500mc/e5500 and define the =
"cpu_restore"
> routine (for e5500/e6500) only for the 64 bit case. The cpu_restore =
routine
> is used in the 64 bit case for setting up the secondary cores.
>=20
> Signed-off-by: Varun Sethi <Varun.Sethi@freescale.com>
> ---
> arch/powerpc/kernel/cpu_setup_fsl_booke.S |    1 +
> arch/powerpc/kernel/cputable.c            |    4 ++++
> 2 files changed, 5 insertions(+), 0 deletions(-)
>=20
> diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S =
b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> index a55d028..5e87737 100644
> --- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> +++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> @@ -75,6 +75,7 @@ _GLOBAL(__setup_cpu_e500v2)
> 	mtlr	r4
> 	blr
> _GLOBAL(__setup_cpu_e500mc)
> +_GLOBAL(__setup_cpu_e5500)

This is a bit confusing, as we now have duplicated __setup_cpu_e5500() =
between the ppc32 and ppc64 cases.

If you build this patch for corenet32_smp_defconfig it fails.

I'll fixup and add the proper #ifdef's to handle this.
---

applied to next

- k=

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

* RE: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code.
  2012-08-03 16:34 ` Kumar Gala
@ 2012-08-04 18:31   ` Sethi Varun-B16395
  2012-08-06 15:58     ` Kumar Gala
  0 siblings, 1 reply; 5+ messages in thread
From: Sethi Varun-B16395 @ 2012-08-04 18:31 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev, agraf, kvm-ppc



> -----Original Message-----
> From: Kumar Gala [mailto:galak@kernel.crashing.org]
> Sent: Friday, August 03, 2012 10:04 PM
> To: Sethi Varun-B16395
> Cc: agraf@suse.de; benh@kernel.crashing.org; linuxppc-
> dev@lists.ozlabs.org; kvm-ppc@vger.kernel.org
> Subject: Re: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu
> setup code.
>=20
>=20
> On Jul 9, 2012, at 7:58 AM, Varun Sethi wrote:
>=20
> > Merge the 32 bit cpu setup code for e500mc/e5500 and define the
> "cpu_restore"
> > routine (for e5500/e6500) only for the 64 bit case. The cpu_restore
> > routine is used in the 64 bit case for setting up the secondary cores.
> >
> > Signed-off-by: Varun Sethi <Varun.Sethi@freescale.com>
> > ---
> > arch/powerpc/kernel/cpu_setup_fsl_booke.S |    1 +
> > arch/powerpc/kernel/cputable.c            |    4 ++++
> > 2 files changed, 5 insertions(+), 0 deletions(-)
> >
> > diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> > b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> > index a55d028..5e87737 100644
> > --- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> > +++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> > @@ -75,6 +75,7 @@ _GLOBAL(__setup_cpu_e500v2)
> > 	mtlr	r4
> > 	blr
> > _GLOBAL(__setup_cpu_e500mc)
> > +_GLOBAL(__setup_cpu_e5500)
>=20
> This is a bit confusing, as we now have duplicated __setup_cpu_e5500()
> between the ppc32 and ppc64 cases.
>=20
> If you build this patch for corenet32_smp_defconfig it fails.
[Sethi Varun-B16395] I am able to build without any issue with the same con=
fig.

-Varun

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

* Re: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code.
  2012-08-04 18:31   ` Sethi Varun-B16395
@ 2012-08-06 15:58     ` Kumar Gala
  2012-08-06 16:24       ` Sethi Varun-B16395
  0 siblings, 1 reply; 5+ messages in thread
From: Kumar Gala @ 2012-08-06 15:58 UTC (permalink / raw)
  To: Sethi Varun-B16395; +Cc: linuxppc-dev, agraf, kvm-ppc


On Aug 4, 2012, at 1:31 PM, Sethi Varun-B16395 wrote:

>=20
>=20
>> -----Original Message-----
>> From: Kumar Gala [mailto:galak@kernel.crashing.org]
>> Sent: Friday, August 03, 2012 10:04 PM
>> To: Sethi Varun-B16395
>> Cc: agraf@suse.de; benh@kernel.crashing.org; linuxppc-
>> dev@lists.ozlabs.org; kvm-ppc@vger.kernel.org
>> Subject: Re: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc =
cpu
>> setup code.
>>=20
>>=20
>> On Jul 9, 2012, at 7:58 AM, Varun Sethi wrote:
>>=20
>>> Merge the 32 bit cpu setup code for e500mc/e5500 and define the
>> "cpu_restore"
>>> routine (for e5500/e6500) only for the 64 bit case. The cpu_restore
>>> routine is used in the 64 bit case for setting up the secondary =
cores.
>>>=20
>>> Signed-off-by: Varun Sethi <Varun.Sethi@freescale.com>
>>> ---
>>> arch/powerpc/kernel/cpu_setup_fsl_booke.S |    1 +
>>> arch/powerpc/kernel/cputable.c            |    4 ++++
>>> 2 files changed, 5 insertions(+), 0 deletions(-)
>>>=20
>>> diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
>>> b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
>>> index a55d028..5e87737 100644
>>> --- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
>>> +++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
>>> @@ -75,6 +75,7 @@ _GLOBAL(__setup_cpu_e500v2)
>>> 	mtlr	r4
>>> 	blr
>>> _GLOBAL(__setup_cpu_e500mc)
>>> +_GLOBAL(__setup_cpu_e5500)
>>=20
>> This is a bit confusing, as we now have duplicated =
__setup_cpu_e5500()
>> between the ppc32 and ppc64 cases.
>>=20
>> If you build this patch for corenet32_smp_defconfig it fails.
> [Sethi Varun-B16395] I am able to build without any issue with the =
same config.
>=20
> -Varun

If you build corenet32_smp_defconfig at commit:

commit c5537ef2d672d2cf48d4e4ac754781c8db112843
Author: Varun Sethi <Varun.Sethi@freescale.com>
Date:   Mon Jul 9 18:28:21 2012 +0530

    powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code.
   =20
You get the following build error:

arch/powerpc/kernel/cpu_setup_fsl_booke.S: Assembler messages:
arch/powerpc/kernel/cpu_setup_fsl_booke.S:110: Error: symbol =
`__setup_cpu_e5500' is already defined

- k=

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

* RE: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code.
  2012-08-06 15:58     ` Kumar Gala
@ 2012-08-06 16:24       ` Sethi Varun-B16395
  0 siblings, 0 replies; 5+ messages in thread
From: Sethi Varun-B16395 @ 2012-08-06 16:24 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev, agraf, kvm-ppc



> -----Original Message-----
> From: Kumar Gala [mailto:galak@kernel.crashing.org]
> Sent: Monday, August 06, 2012 9:28 PM
> To: Sethi Varun-B16395
> Cc: agraf@suse.de; benh@kernel.crashing.org; linuxppc-
> dev@lists.ozlabs.org; kvm-ppc@vger.kernel.org
> Subject: Re: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu
> setup code.
>=20
>=20
> On Aug 4, 2012, at 1:31 PM, Sethi Varun-B16395 wrote:
>=20
> >
> >
> >> -----Original Message-----
> >> From: Kumar Gala [mailto:galak@kernel.crashing.org]
> >> Sent: Friday, August 03, 2012 10:04 PM
> >> To: Sethi Varun-B16395
> >> Cc: agraf@suse.de; benh@kernel.crashing.org; linuxppc-
> >> dev@lists.ozlabs.org; kvm-ppc@vger.kernel.org
> >> Subject: Re: [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc
> >> cpu setup code.
> >>
> >>
> >> On Jul 9, 2012, at 7:58 AM, Varun Sethi wrote:
> >>
> >>> Merge the 32 bit cpu setup code for e500mc/e5500 and define the
> >> "cpu_restore"
> >>> routine (for e5500/e6500) only for the 64 bit case. The cpu_restore
> >>> routine is used in the 64 bit case for setting up the secondary
> cores.
> >>>
> >>> Signed-off-by: Varun Sethi <Varun.Sethi@freescale.com>
> >>> ---
> >>> arch/powerpc/kernel/cpu_setup_fsl_booke.S |    1 +
> >>> arch/powerpc/kernel/cputable.c            |    4 ++++
> >>> 2 files changed, 5 insertions(+), 0 deletions(-)
> >>>
> >>> diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> >>> b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> >>> index a55d028..5e87737 100644
> >>> --- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> >>> +++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
> >>> @@ -75,6 +75,7 @@ _GLOBAL(__setup_cpu_e500v2)
> >>> 	mtlr	r4
> >>> 	blr
> >>> _GLOBAL(__setup_cpu_e500mc)
> >>> +_GLOBAL(__setup_cpu_e5500)
> >>
> >> This is a bit confusing, as we now have duplicated
> >> __setup_cpu_e5500() between the ppc32 and ppc64 cases.
> >>
> >> If you build this patch for corenet32_smp_defconfig it fails.
> > [Sethi Varun-B16395] I am able to build without any issue with the same
> config.
> >
> > -Varun
>=20
> If you build corenet32_smp_defconfig at commit:
>=20
> commit c5537ef2d672d2cf48d4e4ac754781c8db112843
> Author: Varun Sethi <Varun.Sethi@freescale.com>
> Date:   Mon Jul 9 18:28:21 2012 +0530
>=20
>     powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code.
>=20
> You get the following build error:
>=20
> arch/powerpc/kernel/cpu_setup_fsl_booke.S: Assembler messages:
> arch/powerpc/kernel/cpu_setup_fsl_booke.S:110: Error: symbol
> `__setup_cpu_e5500' is already defined
>=20
Oh.., didn't realize that. Thanks for fixing this.

-Varun

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

end of thread, other threads:[~2012-08-06 16:24 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-09 12:58 [PATCH 2/4] powerpc/booke: Merge the 32 bit e5500/e500mc cpu setup code Varun Sethi
2012-08-03 16:34 ` Kumar Gala
2012-08-04 18:31   ` Sethi Varun-B16395
2012-08-06 15:58     ` Kumar Gala
2012-08-06 16:24       ` Sethi Varun-B16395

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).