2015-05-18 19:47:29

by raghu MG

[permalink] [raw]
Subject: ARMADAXP MV78260 CPU-1:failed to come online

Hi,
This mail is regarding Linux smp boot on ARMADA-XP MV2860
.

CPU-1 doesnt boot/go through the boot sequence & it fails to come
online & dumps this message

CPU1:failed to come online .

The CPU-1 boot register is programmed with physical address of
-->armada_xp_secondary_startup function & then cpu-0 deasserts the CPU-1.

I am using armada-xp-gp.dts ,I included armada-xp-mv78260.dts in it.

Any help would be appreciated.
Regards


2015-05-18 20:25:39

by Andrew Lunn

[permalink] [raw]
Subject: Re: ARMADAXP MV78260 CPU-1:failed to come online

Hi Thomas, Gregory

On Tue, May 19, 2015 at 01:17:26AM +0530, raghu MG wrote:
> Hi,
> This mail is regarding Linux smp boot on ARMADA-XP MV2860
> .
>
> CPU-1 doesnt boot/go through the boot sequence & it fails to come
> online & dumps this message
>
> CPU1:failed to come online .
>
> The CPU-1 boot register is programmed with physical address of
> -->armada_xp_secondary_startup function & then cpu-0 deasserts the CPU-1.
>
> I am using armada-xp-gp.dts ,I included armada-xp-mv78260.dts in it.

Does this ring any bells? I have vague recollections of a u-boot
issue?

Andrew

2015-05-18 20:30:27

by Thomas Petazzoni

[permalink] [raw]
Subject: Re: ARMADAXP MV78260 CPU-1:failed to come online

Hello,

On Mon, 18 May 2015 22:20:33 +0200, Andrew Lunn wrote:

> On Tue, May 19, 2015 at 01:17:26AM +0530, raghu MG wrote:
> > Hi,
> > This mail is regarding Linux smp boot on ARMADA-XP MV2860
> > .
> >
> > CPU-1 doesnt boot/go through the boot sequence & it fails to come
> > online & dumps this message
> >
> > CPU1:failed to come online .
> >
> > The CPU-1 boot register is programmed with physical address of
> > -->armada_xp_secondary_startup function & then cpu-0 deasserts the CPU-1.
> >
> > I am using armada-xp-gp.dts ,I included armada-xp-mv78260.dts in it.
>
> Does this ring any bells? I have vague recollections of a u-boot
> issue?

On Armada 375/38x yes. On Armada XP, I don't remember.

Raghu, can you make a more specific bug report, that includes:

* The kernel version you tested
* The U-Boot version you're using
* The kernel configuration you're using
* The complete boot log

Best regards,

Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

2015-05-19 08:45:58

by raghu MG

[permalink] [raw]
Subject: Re: ARMADAXP MV78260 CPU-1:failed to come online

Hi Thomas & Andrew,

Thanks for quick response.


Kernel Release

I am trying latest stable release from kernel.org -->linux-4.0.3.

I have seen this issue in linux-3.10.39 & linux-3.10.32 for which
Marvell has provided lsp.

This issue doesnt crop up in older version like linux-3.2.40 &
linux-3.2.52 with uImage

Not sure but I think this is something do with zImage & device tree combination.



U-Boot Release

U-Boot version is u-boot-2011.12 with Marvell provided bin-header &
board support packages (2014_T2.0)

I found one issue with u-boot, L2C init was failing because bootz
command was deleting entries of l2-cache dtb entry while it resizes
FDT in memory before actual booting.

I corrected this error by by-passing the L2C FDT resize section. Now
kernel correctly initializes Aurora cache controller with L2 1MB 16
ways.



Kernel Configuartion

I am using mvebu_v7_defconfig & enabling necessary options. I have
attached .config file which I am using along with this mail.

I have tried to use armada-xp-gp.dts file along with
armada-xp-mv78260.dtsi included in it.

Please find them attached to mail.



The complete boot log

Boot log is attached to mail. I have enabled enaFDTdebug.




Note:

*In function armada_xp_boot_secondary which setsup bootaddr of
remaining cpus I have printed the values of CPU-1 PM registers.

Physical address of CPU PM Registers : 0xF1022100 -->iormapped->f002a000

CPU-1 PM Registers:0xF102a200(v)

0xF102a224 contains physical address of armada_xp_secondary_startup (0x21bb54)


Physical address of CPU-1 S/W Reset Register: 0xF1020808
-->ioremapped->0xF1028808

value after bringing CPU-1 out of reset in 0xF1028808 is 0x100



Kindly ignore my enthusiasm if I have tried to give you information
which you already know(CPU PM & Software Reset Registers).


Also I have tried your SCU patch for arch/arm/kernel/head.S but has no effect.

On Tue, May 19, 2015 at 2:00 AM, Thomas Petazzoni
<[email protected]> wrote:
> Hello,
>
> On Mon, 18 May 2015 22:20:33 +0200, Andrew Lunn wrote:
>
>> On Tue, May 19, 2015 at 01:17:26AM +0530, raghu MG wrote:
>> > Hi,
>> > This mail is regarding Linux smp boot on ARMADA-XP MV2860
>> > .
>> >
>> > CPU-1 doesnt boot/go through the boot sequence & it fails to come
>> > online & dumps this message
>> >
>> > CPU1:failed to come online .
>> >
>> > The CPU-1 boot register is programmed with physical address of
>> > -->armada_xp_secondary_startup function & then cpu-0 deasserts the CPU-1.
>> >
>> > I am using armada-xp-gp.dts ,I included armada-xp-mv78260.dts in it.
>>
>> Does this ring any bells? I have vague recollections of a u-boot
>> issue?
>
> On Armada 375/38x yes. On Armada XP, I don't remember.
>
> Raghu, can you make a more specific bug report, that includes:
>
> * The kernel version you tested
> * The U-Boot version you're using
> * The kernel configuration you're using
> * The complete boot log
>
> Best regards,
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com


Attachments:
config-file (65.17 kB)
19515-02.cap (11.71 kB)
armada-370-xp.dtsi (8.26 kB)
armada-xp.dtsi (7.37 kB)
armada-xp-mv78260.dtsi (10.48 kB)
armada-xp-gp.dts (6.34 kB)
Download all attachments

2015-05-19 08:49:43

by Thomas Petazzoni

[permalink] [raw]
Subject: Re: ARMADAXP MV78260 CPU-1:failed to come online

Raghu,

On Tue, 19 May 2015 14:15:49 +0530, raghu MG wrote:

> I am trying latest stable release from kernel.org -->linux-4.0.3.
>
> I have seen this issue in linux-3.10.39 & linux-3.10.32 for which
> Marvell has provided lsp.
>
> This issue doesnt crop up in older version like linux-3.2.40 &
> linux-3.2.52 with uImage
>
> Not sure but I think this is something do with zImage & device tree combination.

Can you please try to boot with appended DTB? Some versions of the
Marvell bootloader tend to do horrible modifications to the FDT, making
assumptions that might be true with their Linux LSP, but not with the
mainline kernel. Using appended DTB is a way of making sure that their
bootloader will not touch the kernel DTB.

Thanks,

Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

2015-05-19 10:20:43

by raghu MG

[permalink] [raw]
Subject: Re: ARMADAXP MV78260 CPU-1:failed to come online

Hi Thomas
That was quick.....Yes the append works fine..
I have to port drivers for the board now.

Thanks for the help..Will post queries if I get into trouble on
ARMADAXP platform.

Anyways thanks a ton :)

On Tue, May 19, 2015 at 2:19 PM, Thomas Petazzoni
<[email protected]> wrote:
> Raghu,
>
> On Tue, 19 May 2015 14:15:49 +0530, raghu MG wrote:
>
>> I am trying latest stable release from kernel.org -->linux-4.0.3.
>>
>> I have seen this issue in linux-3.10.39 & linux-3.10.32 for which
>> Marvell has provided lsp.
>>
>> This issue doesnt crop up in older version like linux-3.2.40 &
>> linux-3.2.52 with uImage
>>
>> Not sure but I think this is something do with zImage & device tree combination.
>
> Can you please try to boot with appended DTB? Some versions of the
> Marvell bootloader tend to do horrible modifications to the FDT, making
> assumptions that might be true with their Linux LSP, but not with the
> mainline kernel. Using appended DTB is a way of making sure that their
> bootloader will not touch the kernel DTB.
>
> Thanks,
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com