mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* Re: Regression: not booting anymore on OMAP35xx
@ 2010-06-24 12:32 Luca Ceresoli
  2010-06-24 15:41 ` Sascha Hauer
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Ceresoli @ 2010-06-24 12:32 UTC (permalink / raw)
  To: barebox

Sascha Hauer wrote:
> On Tue, Jun 22, 2010 at 04:04:52PM +0200, Luca Ceresoli wrote:
> > Sascha Hauer wrote:
> > > Hi Luca,
> > > 
> > > On Tue, Jun 22, 2010 at 02:26:11PM +0200, Luca Ceresoli wrote:
> > > > Hi,
> > > > 
> > > 
> > > Seems that I lost the call to arch_init_lowlevel. Does the following
> > > patch help?
> > 
> > I'm afraid it doesn't seem to.
> > It fails with the same symptoms.
> > 
> > Luca
> > 
> > > 
> > > 
> > > diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c
> > > index eea7dcf..91d2ccd 100644
> > > --- a/arch/arm/cpu/start.c
> > > +++ b/arch/arm/cpu/start.c
> > > @@ -50,6 +50,8 @@ void __naked __bare_init reset(void)
> > >  {
> > >  	uint32_t r;
> > >  
> > > +	arch_init_lowlevel();
> > > +
> 
> Ok, this has to be done *after* switching the cpu to SVC32 mode.
> 
> I tested this on my beagle board and now it works again. I pushed
> a patch to the master repository.

Sascha, thank you for the prompt response.
Unfortunately the new version works only partially with my Beagle
Board (rev. C4).

I tested commit:
 46976f7 OMAP: fix compilation

- Test 1: the board is always powered.
  Press RESET with the USER key pressed.
  10 tests, 10 passed.

- Test 2: the board is not powered.
  Turn turn it on with the USER key pressed.
  Turn turn it off again at the end of the test.
  10 tests, 5 passed, 5 failed.

During all of the 20 tests, barebox.bin was always the same.
I didn't recompile it.

OTOH the commit before the "reimplement in C" passes also test 2.

I hope this gives enough hints to solve the problem.

Luca



_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

* Re: Regression: not booting anymore on OMAP35xx
  2010-06-24 12:32 Regression: not booting anymore on OMAP35xx Luca Ceresoli
@ 2010-06-24 15:41 ` Sascha Hauer
  0 siblings, 0 replies; 6+ messages in thread
From: Sascha Hauer @ 2010-06-24 15:41 UTC (permalink / raw)
  To: Luca Ceresoli; +Cc: barebox

On Thu, Jun 24, 2010 at 02:32:25PM +0200, Luca Ceresoli wrote:
> Sascha Hauer wrote:
> > On Tue, Jun 22, 2010 at 04:04:52PM +0200, Luca Ceresoli wrote:
> > > Sascha Hauer wrote:
> > > > Hi Luca,
> > > > 
> > > > On Tue, Jun 22, 2010 at 02:26:11PM +0200, Luca Ceresoli wrote:
> > > > > Hi,
> > > > > 
> > > > 
> > > > Seems that I lost the call to arch_init_lowlevel. Does the following
> > > > patch help?
> > > 
> > > I'm afraid it doesn't seem to.
> > > It fails with the same symptoms.
> > > 
> > > Luca
> > > 
> > > > 
> > > > 
> > > > diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c
> > > > index eea7dcf..91d2ccd 100644
> > > > --- a/arch/arm/cpu/start.c
> > > > +++ b/arch/arm/cpu/start.c
> > > > @@ -50,6 +50,8 @@ void __naked __bare_init reset(void)
> > > >  {
> > > >  	uint32_t r;
> > > >  
> > > > +	arch_init_lowlevel();
> > > > +
> > 
> > Ok, this has to be done *after* switching the cpu to SVC32 mode.
> > 
> > I tested this on my beagle board and now it works again. I pushed
> > a patch to the master repository.
> 
> Sascha, thank you for the prompt response.
> Unfortunately the new version works only partially with my Beagle
> Board (rev. C4).
> 
> I tested commit:
>  46976f7 OMAP: fix compilation
> 
> - Test 1: the board is always powered.
>   Press RESET with the USER key pressed.
>   10 tests, 10 passed.
> 
> - Test 2: the board is not powered.
>   Turn turn it on with the USER key pressed.
>   Turn turn it off again at the end of the test.
>   10 tests, 5 passed, 5 failed.
> 
> During all of the 20 tests, barebox.bin was always the same.
> I didn't recompile it.
> 
> OTOH the commit before the "reimplement in C" passes also test 2.
> 
> I hope this gives enough hints to solve the problem.

Ok, I'll try to reproduce this.

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

* Re: Regression: not booting anymore on OMAP35xx
  2010-06-22 14:04 Luca Ceresoli
@ 2010-06-23  6:42 ` Sascha Hauer
  0 siblings, 0 replies; 6+ messages in thread
From: Sascha Hauer @ 2010-06-23  6:42 UTC (permalink / raw)
  To: Luca Ceresoli; +Cc: barebox

On Tue, Jun 22, 2010 at 04:04:52PM +0200, Luca Ceresoli wrote:
> Sascha Hauer wrote:
> > Hi Luca,
> > 
> > On Tue, Jun 22, 2010 at 02:26:11PM +0200, Luca Ceresoli wrote:
> > > Hi,
> > > 
> > 
> > Seems that I lost the call to arch_init_lowlevel. Does the following
> > patch help?
> 
> I'm afraid it doesn't seem to.
> It fails with the same symptoms.
> 
> Luca
> 
> > 
> > 
> > diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c
> > index eea7dcf..91d2ccd 100644
> > --- a/arch/arm/cpu/start.c
> > +++ b/arch/arm/cpu/start.c
> > @@ -50,6 +50,8 @@ void __naked __bare_init reset(void)
> >  {
> >  	uint32_t r;
> >  
> > +	arch_init_lowlevel();
> > +

Ok, this has to be done *after* switching the cpu to SVC32 mode.

I tested this on my beagle board and now it works again. I pushed
a patch to the master repository.

Sorry for the inconvenience and thanks for reporting.

Sascha


-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

* Re: Regression: not booting anymore on OMAP35xx
@ 2010-06-22 14:04 Luca Ceresoli
  2010-06-23  6:42 ` Sascha Hauer
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Ceresoli @ 2010-06-22 14:04 UTC (permalink / raw)
  To: s.hauer; +Cc: barebox

Sascha Hauer wrote:
> Hi Luca,
> 
> On Tue, Jun 22, 2010 at 02:26:11PM +0200, Luca Ceresoli wrote:
> > Hi,
> > 
> > recent versions of barebox do not boot anymore on OMAP3530 (Cortex-A8).
> > 
> > I build barebox with omap3530_beagle_per_uart_defconfig, and load it
> > using pserial from Nishanth Menon's omap-u-boot-utils
> > (http://github.com/nmenon/omap-u-boot-utils).
> > 
> > Symptoms:
> > pserial detects the OMAP ID, then starts sending via UART.
> > The transfer apparently gets completed (obvious as there is no control),
> > but after that the UART line to the target is totally mute.
> > 
> > This happens since commit:
> >  78104ae arm: reimplement startup code in C
> > 
> > And is still happening on current master:
> >  ea5230c i2c: fix adapter_list manipulation
> 
> Seems that I lost the call to arch_init_lowlevel. Does the following
> patch help?

I'm afraid it doesn't seem to.
It fails with the same symptoms.

Luca

> 
> 
> diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c
> index eea7dcf..91d2ccd 100644
> --- a/arch/arm/cpu/start.c
> +++ b/arch/arm/cpu/start.c
> @@ -50,6 +50,8 @@ void __naked __bare_init reset(void)
>  {
>  	uint32_t r;
>  
> +	arch_init_lowlevel();
> +
>  	/* set the cpu to SVC32 mode */
>  	__asm__ __volatile__("mrs %0, cpsr":"=r"(r));
>  	r &= ~0x1f;
> diff --git a/arch/arm/mach-omap/omap3_core.S b/arch/arm/mach-omap/omap3_core.S
> index 7337d4c..d904231 100644
> --- a/arch/arm/mach-omap/omap3_core.S
> +++ b/arch/arm/mach-omap/omap3_core.S
> @@ -92,7 +92,7 @@ next:
>  arch_start:
>  	.word	arch_init_lowlevel
>  barebox_start:
> -	.word	_start
> +	.word	exception_vectors
>  SRAM_INTVECT:
>  	.word	OMAP_SRAM_INTVECT
> 
> -- 
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
> 


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

* Re: Regression: not booting anymore on OMAP35xx
  2010-06-22 12:26 Luca Ceresoli
@ 2010-06-22 13:11 ` Sascha Hauer
  0 siblings, 0 replies; 6+ messages in thread
From: Sascha Hauer @ 2010-06-22 13:11 UTC (permalink / raw)
  To: Luca Ceresoli; +Cc: barebox

Hi Luca,

On Tue, Jun 22, 2010 at 02:26:11PM +0200, Luca Ceresoli wrote:
> Hi,
> 
> recent versions of barebox do not boot anymore on OMAP3530 (Cortex-A8).
> 
> I build barebox with omap3530_beagle_per_uart_defconfig, and load it
> using pserial from Nishanth Menon's omap-u-boot-utils
> (http://github.com/nmenon/omap-u-boot-utils).
> 
> Symptoms:
> pserial detects the OMAP ID, then starts sending via UART.
> The transfer apparently gets completed (obvious as there is no control),
> but after that the UART line to the target is totally mute.
> 
> This happens since commit:
>  78104ae arm: reimplement startup code in C
> 
> And is still happening on current master:
>  ea5230c i2c: fix adapter_list manipulation

Seems that I lost the call to arch_init_lowlevel. Does the following
patch help?


diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c
index eea7dcf..91d2ccd 100644
--- a/arch/arm/cpu/start.c
+++ b/arch/arm/cpu/start.c
@@ -50,6 +50,8 @@ void __naked __bare_init reset(void)
 {
 	uint32_t r;
 
+	arch_init_lowlevel();
+
 	/* set the cpu to SVC32 mode */
 	__asm__ __volatile__("mrs %0, cpsr":"=r"(r));
 	r &= ~0x1f;
diff --git a/arch/arm/mach-omap/omap3_core.S b/arch/arm/mach-omap/omap3_core.S
index 7337d4c..d904231 100644
--- a/arch/arm/mach-omap/omap3_core.S
+++ b/arch/arm/mach-omap/omap3_core.S
@@ -92,7 +92,7 @@ next:
 arch_start:
 	.word	arch_init_lowlevel
 barebox_start:
-	.word	_start
+	.word	exception_vectors
 SRAM_INTVECT:
 	.word	OMAP_SRAM_INTVECT

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

* Regression: not booting anymore on OMAP35xx
@ 2010-06-22 12:26 Luca Ceresoli
  2010-06-22 13:11 ` Sascha Hauer
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Ceresoli @ 2010-06-22 12:26 UTC (permalink / raw)
  To: barebox

Hi,

recent versions of barebox do not boot anymore on OMAP3530 (Cortex-A8).

I build barebox with omap3530_beagle_per_uart_defconfig, and load it
using pserial from Nishanth Menon's omap-u-boot-utils
(http://github.com/nmenon/omap-u-boot-utils).

Symptoms:
pserial detects the OMAP ID, then starts sending via UART.
The transfer apparently gets completed (obvious as there is no control),
but after that the UART line to the target is totally mute.

This happens since commit:
 78104ae arm: reimplement startup code in C

And is still happening on current master:
 ea5230c i2c: fix adapter_list manipulation

This issue seems independent on another one recently discussed in ml
('OMAP 3530 arch_shutdown "undefined instruction"',
http://lists.infradead.org/pipermail/barebox/2010-May/000919.html),
for which a patch has recently been committed in:
 ce971c2 arm: use processor specififc functions to turn off MMU

Thanks,
Luca



_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

end of thread, other threads:[~2010-06-24 15:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-24 12:32 Regression: not booting anymore on OMAP35xx Luca Ceresoli
2010-06-24 15:41 ` Sascha Hauer
  -- strict thread matches above, loose matches on Subject: below --
2010-06-22 14:04 Luca Ceresoli
2010-06-23  6:42 ` Sascha Hauer
2010-06-22 12:26 Luca Ceresoli
2010-06-22 13:11 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox