* Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel
@ 2005-02-26 22:28 Niklaus Giger
2005-02-27 15:10 ` Niklaus Giger
2005-02-27 15:59 ` Matt Porter
0 siblings, 2 replies; 6+ messages in thread
From: Niklaus Giger @ 2005-02-26 22:28 UTC (permalink / raw)
To: linuxppc-embedded
Hi
I would like to port Linux to a custom PPC405GPr board. Its hardware runs=20
vxWorks fine for more than a year.=20
Within a few days I had a working U-boot image, which allows me to download=
=20
via TFTP Linux-kernels.
I started with a vanilla 2.6.10 kernel, added the entries in the=20
arch/ppc/platforms/4xx/Makefile and Kconfig, two file hcu3.c and hcu3.h whi=
ch=20
are very minimal. The board has no PCI and I do not want to add support for=
=20
the CFI-Flashs or the onboard CAN-Chips.=20
Enabling the SERIAL_TEXT_DEBUG I got the following output
## Transferring control to Linux (at address 00000000) ...
id mach(): done
MMU:enter
MMU:hw init
MMU:mapin
MMU:setio
hcu3_map_io
MMU:exit
setup_arch: enter ngng
setup_arch: bootmem
ocp: exit
arch: exit
If I attach a BDI, I get a lot of "- TARGET: target has entered debug mode"=
=20
lines and then
DI>i
Target state : debug mode
Debug entry cause : unconditional debug event
Current PC : 0xfffffffc
Current CR : 0x00000000
Current MSR : 0x00000000
Current LR : 0xc019a15c
BDI> =20
The corresponding line from my System.map are
c0199e20 t free_bootmem_core
c0199ecc t __alloc_bootmem_core
c019a278 t free_all_bootmem_core
c019a4c8 T init_bootmem_node
My board has no RTC. Is this a problem?=20
Should I start with another kernel? Can anybody point me to a known good=20
kernel version for a specific PPC405 board?
Any hint would be greatly appreciated.
Best regards
=2D-=20
Niklaus Giger
Wieshoschet 6
CH-8753 Mollis
Tel. ++41 55 612 20 54 (privat)
Tel. ++41 55 618 64 68 (Gesch=E4ft)
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel 2005-02-26 22:28 Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel Niklaus Giger @ 2005-02-27 15:10 ` Niklaus Giger 2005-02-27 16:08 ` Matt Porter 2005-02-27 15:59 ` Matt Porter 1 sibling, 1 reply; 6+ messages in thread From: Niklaus Giger @ 2005-02-27 15:10 UTC (permalink / raw) To: linuxppc-embedded Am Samstag, 26. Februar 2005 23.28 schrieb Niklaus Giger: > Hi > > I would like to port Linux to a custom PPC405GPr board. Its hardware runs > vxWorks fine for more than a year. > I made some more progress. After adding 3 lines for MMU support with the BDI I can debug the startup up to kernel_start using BDI.=20 Afterwards my console changes the baudrate for still unknown reasons. Analysing the __log_buf I get the following output (gdb) x/s &__log_buf 0xc01accfc <ratelimit_lock.9>: "<4>Linux version 2.6.10=20 (niklaus@ng•ngiger.dyndns.org) (gcc-Version 3.3.5 (Debian 1:3.3.5-8)) #15 S= un=20 =46eb 27 14:44:27 CET 2005\n<7>On node 0 totalpages: 8240\n<7> DMA zone: 8= 240=20 pages, LIFO batch:2\n<7>"... (gdb) x 0xc01acdc4 <ratelimit_lock.9+200>: " Normal zone: 0 pages, LIFO=20 batch:1\n<7> HighMem zone: 0 pages, LIFO batch:1\n<4>Built 1=20 zonelists\n<4>Kernel command line: ip=3D172.25.1.6\n<4>PID hash table entri= es:=20 256 (order:8, 4096 bytes)\n" (gdb) x 0xc01ace84 <ratelimit_lock.9+392>: "" >My board has no RTC. Is this a problem?=20 > >Should I start with another kernel? Can anybody point me to a known good=20 >kernel version for a specific PPC405 board? Any hint would be greatly appreciated. Best regards =2D-=20 Niklaus Giger Wieshoschet 6 CH-8753 Mollis Tel. ++41 55 612 20 54 (privat) Tel. ++41 55 618 64 68 (Gesch=E4ft) ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel 2005-02-27 15:10 ` Niklaus Giger @ 2005-02-27 16:08 ` Matt Porter 2005-02-27 17:20 ` Niklaus Giger 0 siblings, 1 reply; 6+ messages in thread From: Matt Porter @ 2005-02-27 16:08 UTC (permalink / raw) To: Niklaus Giger; +Cc: linuxppc-embedded On Sun, Feb 27, 2005 at 04:10:30PM +0100, Niklaus Giger wrote: > Am Samstag, 26. Februar 2005 23.28 schrieb Niklaus Giger: > > Hi > > > > I would like to port Linux to a custom PPC405GPr board. Its hardware runs > > vxWorks fine for more than a year. > > > I made some more progress. After adding 3 lines for MMU support with the BDI > I can debug the startup up to kernel_start using BDI. > > Afterwards my console changes the baudrate for still unknown reasons. How do you know this? Console isn't initialized until after the kernel command line printk and a few other facilities are initialized. > Analysing the __log_buf I get the following output > (gdb) x/s &__log_buf > 0xc01accfc <ratelimit_lock.9>: "<4>Linux version 2.6.10 > (niklaus@ng•ngiger.dyndns.org) (gcc-Version 3.3.5 (Debian 1:3.3.5-8)) #15 Sun > Feb 27 14:44:27 CET 2005\n<7>On node 0 totalpages: 8240\n<7> DMA zone: 8240 > pages, LIFO batch:2\n<7>"... > (gdb) x > 0xc01acdc4 <ratelimit_lock.9+200>: " Normal zone: 0 pages, LIFO > batch:1\n<7> HighMem zone: 0 pages, LIFO batch:1\n<4>Built 1 > zonelists\n<4>Kernel command line: ip=172.25.1.6\n<4>PID hash table entries: > 256 (order:8, 4096 bytes)\n" > (gdb) x > 0xc01ace84 <ratelimit_lock.9+392>: "" Is this all of the log_buf output? Try setting your kernel cmdline with "console=ttyS0,115200" where 115200 is you console baudrate you are using in U-Boot. Otherwise, the kernel 8250 driver has no idea which baudrate to set for the 8250/console. -Matt ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel 2005-02-27 16:08 ` Matt Porter @ 2005-02-27 17:20 ` Niklaus Giger 2005-04-17 20:13 ` Niklaus Giger 0 siblings, 1 reply; 6+ messages in thread From: Niklaus Giger @ 2005-02-27 17:20 UTC (permalink / raw) To: Matt Porter; +Cc: linuxppc-embedded Am Sonntag, 27. Februar 2005 17.08 schrieb Matt Porter: > On Sun, Feb 27, 2005 at 04:10:30PM +0100, Niklaus Giger wrote: > > Am Samstag, 26. Februar 2005 23.28 schrieb Niklaus Giger: > > > Hi > > > > > > I would like to port Linux to a custom PPC405GPr board. Its hardware > > > runs vxWorks fine for more than a year. > > > > I made some more progress. After adding 3 lines for MMU support with the > > BDI I can debug the startup up to kernel_start using BDI. > > > > Afterwards my console changes the baudrate for still unknown reasons. > How do you know this? Console isn't initialized until after the kernel > command line printk and a few other facilities are initialized. Because I see the following output arch: exit *=CB=AB=E3=BE=B5=BA=B3=B9=BF=BE=B6=B9=B3=BC=B1=B5=B3=A0=B6=B7=BE=B7=B9=B7= =B5=B2=B4=B9=B6=B4=BE=B3=BF=BA=B7=B7=B3=B3=A6=B5=B2=BB=B9=BF=BE=A4=B5=B2=B9= =B1=BE=A3=B5=BE=A6=B5=B2=A3=A5=A4=A2=BD=B9=BC =B4=BA=B7=BE=B5=BC=B9=B3=BC=B3=A3=B5=B2=BE=B5=BC=B3=B7=BD=BD=B1=BE=B4=BC=B1= =BE=B5=B3=B7=BE=BB=BF=BC=B5=B4=BC=B9=AB=B1=B0=A0=A1=A4=B8=B1=B3=B8=BC=B1=B2= =BC=B5=B5=BE=BC=B2=B1=B5=BB=B7=B2=B4=B5=B2=B2=B9=B4=B5=B3 =20 which for me is typical for a wrong baudrate.=20 Okay, I do not know this. Specially it may not be the "console" device but= =20 whatever is going out at this moment via the PPC405GPr internal UART0 devic= e. > > Analysing the __log_buf I get the following output > > (gdb) x/s &__log_buf > > 0xc01accfc <ratelimit_lock.9>: "<4>Linux version 2.6.10 > > (niklaus@ng•ngiger.dyndns.org) (gcc-Version 3.3.5 (Debian 1:3.3.5-8)) #= 15 > > Sun Feb 27 14:44:27 CET 2005\n<7>On node 0 totalpages: 8240\n<7> DMA > > zone: 8240 pages, LIFO batch:2\n<7>"... > > (gdb) x > > 0xc01acdc4 <ratelimit_lock.9+200>: " Normal zone: 0 pages, LIFO > > batch:1\n<7> HighMem zone: 0 pages, LIFO batch:1\n<4>Built 1 > > zonelists\n<4>Kernel command line: ip=3D172.25.1.6\n<4>PID hash table > > entries: 256 (order:8, 4096 bytes)\n" > > (gdb) x > > 0xc01ace84 <ratelimit_lock.9+392>: "" > > Is this all of the log_buf output? Try setting your kernel cmdline > with "console=3DttyS0,115200" where 115200 is you console baudrate > you are using in U-Boot. Otherwise, the kernel 8250 driver has no > idea which baudrate to set for the 8250/console. Yes, this is all. I tried you suggestion, but I got no other result. The=20 paramter "console=3DttyS0,9600" now is found in the log buffer. Or is ttyS0= the=20 wrong device name for the internal PPC405Gpr UART0? I am using 9600 8 bit no parity which should be anyway the default baudrate= =20 for the console. Thanks for your help =2D-=20 Niklaus Giger Wieshoschet 6 CH-8753 Mollis Tel. ++41 55 612 20 54 (privat) Tel. ++41 55 618 64 68 (Gesch=E4ft) ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel 2005-02-27 17:20 ` Niklaus Giger @ 2005-04-17 20:13 ` Niklaus Giger 0 siblings, 0 replies; 6+ messages in thread From: Niklaus Giger @ 2005-04-17 20:13 UTC (permalink / raw) To: Matt Porter; +Cc: linuxppc-embedded Hi Just to document my error I respond to my previous posting. After having dropped my work on this problem for a few weeks I figured my problem. I was merging code from the walnut board which was ba= sed=20 on the IBM boot eprom which has a different layout to pass the information = to the Linux kernel. After switching to the U-Boot memory the kernel booted okay.=20 After disabling the following two lines in drivers/serial/8250.c serial_outp(up, UART_DLL, quot & 0xff); /* LS of divisor */ serial_outp(up, UART_DLM, quot >> 8); /* MS of divisor */ my console stays at 9600 baud.=20 Best regards Am Sonntag, 27. Februar 2005 18.20 schrieb Niklaus Giger: > Am Sonntag, 27. Februar 2005 17.08 schrieb Matt Porter: > > On Sun, Feb 27, 2005 at 04:10:30PM +0100, Niklaus Giger wrote: > > > Am Samstag, 26. Februar 2005 23.28 schrieb Niklaus Giger: > > > > Hi > > > > > > > > I would like to port Linux to a custom PPC405GPr board. Its hardware > > > > runs vxWorks fine for more than a year. > > > > > > I made some more progress. After adding 3 lines for MMU support with > > > the BDI I can debug the startup up to kernel_start using BDI. > > > > > > Afterwards my console changes the baudrate for still unknown reasons. > > > > How do you know this? Console isn't initialized until after the kernel > > command line printk and a few other facilities are initialized. > > Because I see the following output > arch: exit > *=CB=AB=E3=BE=B5=BA=B3=B9=BF=BE=B6=B9=B3=BC=B1=B5=B3=A0=B6=B7=BE=B7=B9=B7= =B5=B2=B4=B9=B6=B4=BE=B3=BF=BA=B7=B7=B3=B3=A6=B5=B2=BB=B9=BF=BE=A4=B5=B2=B9= =B1=BE=A3=B5=BE=A6=B5=B2=A3=A5=A4=A2=BD=B9=BC > =B4=BA=B7=BE=B5=BC=B9=B3=BC=B3=A3=B5=B2=BE=B5=BC=B3=B7=BD=BD=B1=BE=B4=BC= =B1=BE=B5=B3=B7=BE=BB=BF=BC=B5=B4=BC=B9=AB=B1=B0=A0=A1=A4=B8=B1=B3=B8=BC=B1= =B2=BC=B5=B5=BE=BC=B2=B1=B5=BB=B7=B2=B4=B5=B2=B2=B9=B4=B5=B3 > which for me is typical for a wrong baudrate. > Okay, I do not know this. Specially it may not be the "console" device but > whatever is going out at this moment via the PPC405GPr internal UART0 > device. > > > > Analysing the __log_buf I get the following output > > > (gdb) x/s &__log_buf > > > 0xc01accfc <ratelimit_lock.9>: "<4>Linux version 2.6.10 > > > (niklaus@ng•ngiger.dyndns.org) (gcc-Version 3.3.5 (Debian 1:3.3.5-8)) > > > #15 Sun Feb 27 14:44:27 CET 2005\n<7>On node 0 totalpages: 8240\n<7>= =20 > > > DMA zone: 8240 pages, LIFO batch:2\n<7>"... > > > (gdb) x > > > 0xc01acdc4 <ratelimit_lock.9+200>: " Normal zone: 0 pages, LIFO > > > batch:1\n<7> HighMem zone: 0 pages, LIFO batch:1\n<4>Built 1 > > > zonelists\n<4>Kernel command line: ip=3D172.25.1.6\n<4>PID hash table > > > entries: 256 (order:8, 4096 bytes)\n" > > > (gdb) x > > > 0xc01ace84 <ratelimit_lock.9+392>: "" > > > > Is this all of the log_buf output? Try setting your kernel cmdline > > with "console=3DttyS0,115200" where 115200 is you console baudrate > > you are using in U-Boot. Otherwise, the kernel 8250 driver has no > > idea which baudrate to set for the 8250/console. > > Yes, this is all. I tried you suggestion, but I got no other result. The > paramter "console=3DttyS0,9600" now is found in the log buffer. Or is tty= S0 > the wrong device name for the internal PPC405Gpr UART0? > I am using 9600 8 bit no parity which should be anyway the default baudra= te > for the console. > > Thanks for your help =2D-=20 Niklaus Giger Wieshoschet 6 CH-8753 Mollis Tel. ++41 55 612 20 54 (privat) Tel. ++41 55 618 64 68 (Gesch=E4ft) ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel 2005-02-26 22:28 Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel Niklaus Giger 2005-02-27 15:10 ` Niklaus Giger @ 2005-02-27 15:59 ` Matt Porter 1 sibling, 0 replies; 6+ messages in thread From: Matt Porter @ 2005-02-27 15:59 UTC (permalink / raw) To: Niklaus Giger; +Cc: linuxppc-embedded On Sat, Feb 26, 2005 at 11:28:23PM +0100, Niklaus Giger wrote: > Hi > > I would like to port Linux to a custom PPC405GPr board. Its hardware runs > vxWorks fine for more than a year. Good, gives a good feeling about the hardware. > My board has no RTC. Is this a problem? No, not at all. > Should I start with another kernel? Can anybody point me to a known good > kernel version for a specific PPC405 board? The stock kernel.org 2.6.10 that you seem to be using is fine. > Any hint would be greatly appreciated. Working out your BDI issues will be very helpful to debugging. It's only clear that it passes beyond setup_arch() at this point. That's good, though. -Matt ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2005-04-17 20:54 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2005-02-26 22:28 Problems porting to a custom PPC405GPr board using a vanilla 2.6.10 kernel Niklaus Giger 2005-02-27 15:10 ` Niklaus Giger 2005-02-27 16:08 ` Matt Porter 2005-02-27 17:20 ` Niklaus Giger 2005-04-17 20:13 ` Niklaus Giger 2005-02-27 15:59 ` Matt Porter
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox