[U-Boot-Users] (no subject)

zhaodong
2003-12-04T07:40:29Z

Dear All,

I am porting U-Boot on a customize board with a IBM PPC405GP embedded processor on it.
At first I encountered a problem that the wait_ticks() function called by udelay() can't work,
and I replaced the assembly wait_ticks()function by a finite c loop(just count a number down). After that every thing seems ok,
until when I boot a linux kernel the kernel hang at "Calibrating delay loop... ".

The time base is configured to use internel CPU clock,

Before the init_timebase() funciton, I did:

configure the cntr0 and cntr1(CPC0_CR0 and CPC0CR1) with 0x007010c0 and 0x00004000;
configure the EBC
configure the SDRAM controller
configure OCM at 0xf8000000, and define CFG_TEMP_STACK_OCM
define CONFIG_BOARD_PRE_INIT and configure UIC

init_timebase(use the function in lib_ppc/time.c)
define CONFIG_BOARD_POSTCLK_INIT and init 405 on chip I2C interface,

here needs the udelay()function, How can I init the time base correctly?

below is the information when I tftpboot a linux kernel image :
...
memsize = 0x02000000
flashstart = 0xFE000000
flashsize = 0x02000000
flashoffset = 0x00000000
sramstart = 0x00000000
sramsize = 0x00000000
bootflags = 0x001E8480
procfreq = 198.512 MHz
plb_busfreq = 66.512 MHz
pci_busfreq = 33.512 MHz
ethaddr = 08:00:3E:26:15:59
IP addr = 192.168.0.199
baudrate = 38400 bps
No initrd
## Transferring control to Linux (at address 00000000) ...
Linux version 2.4.18_mvl30-walnut (root at RedHat28.accu.com)
board info structure size 116
RAM start 0x00000000 size 32MByte
FLASH start 0xfe000000 size 32MByte
Baudrate 38400
405GP on 198000000Hz
PLB BUS on 66000000Hz
PCI BUS on 33000000Hz
On node 0 totalpages: 8192
zone(0): 8192 pages.
zone(1): 0 pages.
zone(2): 0 pages.
Kernel command line: console=ttyS0,38400 root=/dev/nfs rw
Console: colour dummy device 80x25
Calibrating delay loop...

Is this problem related with the macro CONFIG_CLOCKS_IN_MHZ? or just because the time base is not correctly inititalized ?

Thand you,

Zhaodong