Skip to contentSkip to conversation

udelay/udelay_masked problems

U-Boot E Robertson 3 participants 3 messages Apr 7, 2009 – Apr 13, 2009

lore
Share & tools
lore
#0 lore raw

Hi all,
Is their a problem using udelay in board_init functions?
When I do this on my at91, arm926ejs board, it seems to be in an endless loop. I thought this was a timer issue but I only have this problem with board init and not in the drivers.
Does anyone have any ideas?
Is timer_init a arch specific call or should it be board specific for arm?

#1 lore raw

Hi E Robertson,

2009/4/8 E Robertson <[email protected]>:

Quoted 6 lines

Hi all,
Is their a problem using udelay in board_init functions?
When I do this on my at91, arm926ejs board, it seems to be in an endless loop. I thought this was a timer issue but I only have this problem with board init and not in the drivers.
Does anyone have any ideas?

I guess the reason is:

start_armboot() in lib_arm/board.c
invokes board_init() in board/atmel/<your at91 baord>/<your at92 board>.c before interrupt_init() in cpu/arm926ejs/interrupts.c
which invokes timer_init() in cpu/arm926ejs/at91/timer.c.

That means timer_init() is called later than your board_init()

Quoted 1 line

Is timer_init a arch specific call or should it be board specific for arm?

I have no idea either.

regards,
Po-Yu chuang

#2 lore raw
In reply to E Robertson
Quoted 2 lines · E Robertson

Hi all,
Is their a problem using udelay in board_init functions?

actually yes
I'll send some patch to cleanuo the timer/interrupt init this week

Quoted 5 lines

When I do this on my at91, arm926ejs board, it seems to be in an endless loop. I thought this was a timer issue but I only have this problem with board init and not in the drivers.
Does anyone have any ideas?
Is timer_init a arch specific call or should it be board specific for arm?

no timer_init call is arm specific not board or even sub-arch

Best Regards,
J.