linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* Trouble "Transferring control to Linux (at address 00000000)"
@ 2009-06-26 16:13 Mikhail Zaturenskiy
  2009-06-26 16:55 ` Scott Wood
  0 siblings, 1 reply; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-26 16:13 UTC (permalink / raw)
  To: linuxppc-dev

Hello,

I'm trying to load Linux from U-Boot. I am using ELDK 4.2 with U-Boot
2009.03 on an EP88xC rev1.1 board (MPC885 cpu, 64MB RAM, 32MB FLASH).
The linux kernel sources were obtained from instructions at
"http://www.denx.de/wiki/view/DULG/LinuxConfiguration#Section_6.1."
and the FDT blob (dtb) was generated from
"linux-2.6-denx/arch/powerpc/boot/dts/ep88xc.dts". Below is my output
from boot to hang:

U-Boot 2009.03-svn8591 (Jun 25 2009 - 11:08:09)

CPU:   MPC885ZPnn at 100 MHz [40.0...133.0 MHz]
       8 kB I-Cache 8 kB D-Cache FEC present
clock 100000000Hz != 300000Hz
Board: EP88xC 1.1  CPLD revision 2
DRAM:  64 MB
Top of RAM usable for U-Boot at: 04000000
Reserving 208k for U-Boot at: 03fcb000
Reserving 384k for malloc() at: 03f6b000
Reserving 60 Bytes for Board Info at: 03f6afc4
Reserving 56 Bytes for Global Data at: 03f6af8c
Stack Pointer at: 03f6af68
New Stack Pointer is: 03f6af68
Now running in RAM - U-Boot at: 03fcb000
FLASH: flash detect cfi
fwc addr fc000000 cmd f0 f0 8bit x 8 bit
...
... <some output skipped> ...
...
is= cmd 59(Y) addr fc000048 is= 00590059 00590059
device interface is 2
found port 4 chip 2 port 32 bits chip 16 bits
00 : 51 52 59 02 00 40 00 00 00 00 00 27 36 00 00 07  QRY..@.....'6...
...
... <some output skipped> ...
...
fwc addr fc000154 cmd 98 00980098 32bit x 16 bit
manufacturer is 2
manufacturer id is 0x1
device id is 0x227e
device id2 is 0x0
cfi version is 0x3133
size_ratio 2 port 32 bits chip 16 bits
found 1 erase regions
erase region 0: 0x0200007f
erase_region_count = 128 erase_region_size = 131072
fwc addr fc000000 cmd f0 00f000f0 32bit x 16 bit
flash_protect ON: from 0xFC000000 to 0xFC02DFFF
protect on 0
flash_protect ON: from 0xFC040000 to 0xFC07FFFF
protect on 1
32 MB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
U-Boot relocated to 03fcb000
Net:   FEC ETHERNET, FEC2 ETHERNET
### main_loop entered: bootdelay=2

### main_loop: bootcmd="bootm fc080000"
Hit any key to stop autoboot:  0
## Current stack ends at 0x03f6ad50
*  kernel: cmdline image address = 0xfc080000
Wrong Image Format for bootm command
ERROR: can't get kernel image!
=> setenv ipaddr 10.0.54.150
=> setenv serverip 10.0.54.129
=> setenv bootargs root=/dev/ram0 rw
=> setenv ethaddr 00-e0-86-0c-84-fd
eth_set_enetaddr(num=0, addr=00-e0-86-0c-84-fd)
Setting new HW address on FEC ETHERNET
New Address is             00:E0:86:0C:84:FD
eth_set_enetaddr(num=0, addr=00-e0-86-0c-84-fd)
Setting new HW address on FEC ETHERNET
New Address is             00:E0:86:0C:84:FD
=> tftp 400000 ep88x_uimage2
Trying FEC ETHERNET
Using FEC ETHERNET device
TFTP from server 10.0.54.129; our IP address is 10.0.54.150
Filename 'ep88x_uimage2'.
Load address: 0x400000
Loading: #################################################################
         ########
done
Bytes transferred = 1061544 (1032a8 hex)
=> tftp 550000 ep88x_ramdisk3
Trying FEC ETHERNET
Using FEC ETHERNET device
TFTP from server 10.0.54.129; our IP address is 10.0.54.150
Filename 'ep88x_ramdisk3'.
Load address: 0x550000
Loading: #################################################################
         #############################################################
done
Bytes transferred = 1846099 (1c2b53 hex)
=> tftp 750000 ep88x_dtb
Trying FEC ETHERNET
Using FEC ETHERNET device
TFTP from server 10.0.54.129; our IP address is 10.0.54.150
Filename 'ep88x_dtb'.
Load address: 0x750000
Loading: #
done
Bytes transferred = 12288 (3000 hex)
=> bootm 400000 550000 750000
## Current stack ends at 0x03f6ad60
*  kernel: cmdline image address = 0x00400000
## Booting kernel from Legacy Image at 00400000 ...
   Image Name:   Linux-2.6.30-rc2-01402-gd4e2f68-
   Image Type:   PowerPC Linux Kernel Image (gzip compressed)
   Data Size:    1061480 Bytes =  1 MB
   Load Address: 00000000
   Entry Point:  00000000
   Entry Point:  00000000
   kernel data at 0x00400040, len = 0x00103268 (1061480)
*  ramdisk: cmdline image address = 0x00550000
## Loading init Ramdisk from Legacy Image at 00550000 ...
   Image Name:   Simple Embedded Linux Framework
   Image Type:   PowerPC Linux RAMDisk Image (gzip compressed)
   Data Size:    1846035 Bytes =  1.8 MB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   ramdisk start = 0x00550040, ramdisk end = 0x00712b53
*  fdt: cmdline image address = 0x00750000
## Checking for 'FDT'/'FDT Image' at 00750000
*  fdt: raw FDT blob
## Flattened Device Tree blob at 00750000
   Booting using the fdt blob at 0x750000
   of_flat_tree at 0x00750000 size 0x00003000
   Uncompressing Kernel Image ... OK
   kernel loaded at 0x00000000, end = 0x00226224
## initrd_high = 0xffffffff, copy_to_ram = 1
   Loading Ramdisk to 03da7000, end 03f69b13 ... OK
   ramdisk load start = 0x03da7000, ramdisk load end = 0x03f69b13
## Transferring control to Linux (at address 00000000) ...
   Booting using OF flat tree...

I did a post-mortem analysis
(http://www.denx.de/wiki/view/DULG/LinuxPostMortemAnalysis) and came
up with the following message:
<6>Using Embedded Planet EP88xC machine description.
<0>Kernel panic - not syncing: Error: Failed to allocate 0x1
................0x800000..
<0>.
<4>Call Trace:.
<4>................69e0]
show_stack...............................21f00] [c001bcb4]
panic+0x8c/0x1................ [c01fac70] lmb_alloc+0x0/0xc.
<4>[c0221f70] [c01................_page+0x60/0x74.
<4>[c0221f80] [c01a4484] pte_alloc_one_kernel+0x

I'm not quite sure where to go from here to get linux working. Anybody
have any suggestions?

Thank you,
Mikhail Zaturenskiy

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-26 16:13 Trouble "Transferring control to Linux (at address 00000000)" Mikhail Zaturenskiy
@ 2009-06-26 16:55 ` Scott Wood
  2009-06-26 17:12   ` Mikhail Zaturenskiy
  0 siblings, 1 reply; 18+ messages in thread
From: Scott Wood @ 2009-06-26 16:55 UTC (permalink / raw)
  To: Mikhail Zaturenskiy; +Cc: linuxppc-dev

Mikhail Zaturenskiy wrote:
> Hello,
> 
> I'm trying to load Linux from U-Boot. I am using ELDK 4.2 with U-Boot
> 2009.03 on an EP88xC rev1.1 board (MPC885 cpu, 64MB RAM, 32MB FLASH).
> The linux kernel sources were obtained from instructions at
> "http://www.denx.de/wiki/view/DULG/LinuxConfiguration#Section_6.1."
> and the FDT blob (dtb) was generated from
> "linux-2.6-denx/arch/powerpc/boot/dts/ep88xc.dts". Below is my output
> from boot to hang:

This isn't the denx list; what kernel version is that, and with what 
modifications from mainline?

Note that ep88xc.dts in mainline is intended for use with PlanetCore, which is 
what ships on that board.  You may need to make modifications for it to work 
with u-boot (at the least, the IMMR base is probably different).  This is why 
u-boot should be maintaining its own repository of trees that it passes...

Also, make sure u-boot is properly updating the memory size in the device tree. 
  Can you dump the post-fixup device tree in u-boot?

-Scott

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-26 16:55 ` Scott Wood
@ 2009-06-26 17:12   ` Mikhail Zaturenskiy
  2009-06-27 21:01     ` Frank Svendsbøe
  0 siblings, 1 reply; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-26 17:12 UTC (permalink / raw)
  To: Scott Wood; +Cc: linuxppc-dev

Hi Scott,

> This isn't the denx list;
I've noticed :) but I'm still learning about this whole process so I
though I could get some general suggestions.

> what kernel version is that, and with what
> modifications from mainline?
Kernel is v2.6.30, I'm not yet familiar enough with it to know what's
been modified from mainline, just following instructions.

> Note that ep88xc.dts in mainline is intended for use with PlanetCore, whi=
ch
> is what ships on that board. =A0You may need to make modifications for it=
 to
> work with u-boot (at the least, the IMMR base is probably different).
Hmm, this hasn't occurred to me, thank you for pointing it out.

> Also, make sure u-boot is properly updating the memory size in the device
> tree. =A0Can you dump the post-fixup device tree in u-boot?
Not sure, but I'll try to find out if that's possible. It'd certainly
answer a lot of questions...

Thanks,
Mikhail Zaturenskiy

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-26 17:12   ` Mikhail Zaturenskiy
@ 2009-06-27 21:01     ` Frank Svendsbøe
  2009-06-29 17:53       ` Mikhail Zaturenskiy
  0 siblings, 1 reply; 18+ messages in thread
From: Frank Svendsbøe @ 2009-06-27 21:01 UTC (permalink / raw)
  To: Mikhail Zaturenskiy; +Cc: Scott Wood, linuxppc-dev

On Fri, Jun 26, 2009 at 7:12 PM, Mikhail
Zaturenskiy<mzaturenskiy.st@gmail.com> wrote:
> Hi Scott,
>
>> This isn't the denx list;
> I've noticed :) but I'm still learning about this whole process so I
> though I could get some general suggestions.
>
>> what kernel version is that, and with what
>> modifications from mainline?
> Kernel is v2.6.30, I'm not yet familiar enough with it to know what's
> been modified from mainline, just following instructions.
>
>> Note that ep88xc.dts in mainline is intended for use with PlanetCore, wh=
ich
>> is what ships on that board. =A0You may need to make modifications for i=
t to
>> work with u-boot (at the least, the IMMR base is probably different).
> Hmm, this hasn't occurred to me, thank you for pointing it out.
>

I don't have access to this board, but have experience with a similar
one (Adder 875), and
I might be able to help out. Scott's right. According to U-Boots
include/configs/EP88x.h,
CONFIG_SYS_IMMR is 0xf0000000, but the Linux the ep88xc.dts is
referring to an IMMR set
to 0xfa200000. Replace every instance of 0xfa20 with 0xf000, and it may wor=
k.

>> Also, make sure u-boot is properly updating the memory size in the devic=
e
>> tree. =A0Can you dump the post-fixup device tree in u-boot?
> Not sure, but I'll try to find out if that's possible. It'd certainly
> answer a lot of questions...
>
> Thanks,
> Mikhail Zaturenskiy
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
>

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-27 21:01     ` Frank Svendsbøe
@ 2009-06-29 17:53       ` Mikhail Zaturenskiy
  2009-06-29 18:02         ` Gary Thomas
  0 siblings, 1 reply; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-29 17:53 UTC (permalink / raw)
  To: Frank Svendsbøe, Scott Wood; +Cc: linuxppc-dev

[-- Attachment #1: Type: text/plain, Size: 8010 bytes --]

Hi guys, I've been working off your suggestions and here's my update
on where I'm at now.

For reference, attached are my current
"linux-2.6-denx/arch/powerpc/boot/dts/ep88xc.dts" and
"u-boot-2009.03/include/configs/EP88x.h".

> I might be able to help out. Scott's right. According to U-Boots
> include/configs/EP88x.h,
> CONFIG_SYS_IMMR is 0xf0000000, but the Linux the ep88xc.dts is
> referring to an IMMR set
> to 0xfa200000. Replace every instance of 0xfa20 with 0xf000, and it may work.
I did notice the IMMR discrepancy and as Frank suggested adjusted the
0xfa20xxxx values to 0xf000xxxx in my DTS, though I'm wondering if it
would be better to have just set my CONFIG_SYS_IMMR to 0xfa200000? Not
sure if that would break more than it would fix. Anyways, I have not
noticed any difference in output after changing this in the DTS, but
I'll leave it this way as it seems more correct.

>>> Also, make sure u-boot is properly updating the memory size in the device
>>> tree.  Can you dump the post-fixup device tree in u-boot?
>> Not sure, but I'll try to find out if that's possible. It'd certainly
>> answer a lot of questions...
While I have not yet figured out how to dump the post-fixup tree... I
can see that U-Boot doesn't seem to be doing proper fixup because
after manually setting all the DTS fields that U-Boot was supposed to
fill in (clock frequency, RAM start/end, etc.), the kernel seems to be
going through a fairly normal boot sequence. Without me manually
setting those fields, they remain initialized to 0. The only issue is
that no output goes to the console.

Here is my current output.
>From U-Boot:

U-Boot 2009.03-svn8591 (Jun 29 2009 - 11:25:23)

CPU:   MPC885ZPnn at 100 MHz [40.0...133.0 MHz]
       8 kB I-Cache 8 kB D-Cache FEC present
Board: EP88xC 1.1  CPLD revision 2
DRAM:  64 MB
FLASH: 32 MB
In:    serial
Out:   serial
Err:   serial
Net:   FEC ETHERNET, FEC2 ETHERNET
Hit any key to stop autoboot:  0
=> tftp ep88x_uimage2
Using FEC ETHERNET device
TFTP from server 10.0.54.129; our IP address is 10.0.54.150
Filename 'ep88x_uimage2'.
Load address: 0x400000
Loading: #################################################################
         ########
done
Bytes transferred = 1057419 (10228b hex)
=> tftp 750000 ep88x_dtb2
Using FEC ETHERNET device
TFTP from server 10.0.54.129; our IP address is 10.0.54.150
Filename 'ep88x_dtb2'.
Load address: 0x750000
Loading: #
done
Bytes transferred = 7725 (1e2d hex)
=> bootm 400000 - 750000
## Booting kernel from Legacy Image at 00400000 ...
   Image Name:   Linux-2.6.30-rc2-01402-gd4e2f68-
   Image Type:   PowerPC Linux Kernel Image (gzip compressed)
   Data Size:    1057355 Bytes =  1 MB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 00750000
   Booting using the fdt blob at 0x750000
   Uncompressing Kernel Image ... OK


>From Kernel via postmortem analysis - sorry it's a little messy, my
debugger ICDPPCZ is not that great at producing memory dumps so I had
to do some cleanup/conversion to make the results at least somewhat
legible:

<6>Using Embedded Planet EP88xC machine description?
<5>Linux version 2.6.30-rc2-??1402-gd4e2f68-dirty
(devone@localhost.localdomain) (gcc version 4.2.2) #1 Mon J??n 29
11:35:28 CDT 2009?
<7>Top of RAM: 0x4000000' Total RAM: 0x4000000?
<7>Memory??hole size: 0MB?
<4>Zone PFN ranges:?
<4>  DMA      0x00000000 -> 0x00004000?
<4>  ??ormal   0x00004000 -> 0x00004000?
<4>Movable zone start PFN for each node?
<4>ear??y_node_map[1] active PFN ranges?
<4>    0: 0x00000000 -> 0x00004000?
<7>On node 0??totalpages: 16384?
<7>free_area_init_node: node 0' pgdat c021bf7c' node_mem_map ??023f000?
<7>  DMA zone: 128 pages used for memmap?
<7>  DMA zone: 0 pages reserve???
<7>  DMA zone: 16256 pages' LIFO batch:3?
<6>MMU: Allocated 72 bytes of context??maps for 16 contexts?
<4>Built 1 zonelists in Zone order' mobility grouping on. ??Total pages: 16256?
<5>Kernel command line: console=ttyS0'9600n8 loglevel=7?
<6>N??_IRQS:512?
<7>irq: irq 5 on host /soc@f0000000/interrupt-controller@0 mapped to
??irtual irq 16?
<7>irq: irq 0 on host /soc@f0000000/cpm@9c0/interrupt-controller@??30
mapped to virtual irq 17?
<4>PID hash table entries: 256 (order: 8' 1024 byte??)?
<4>Decrementer Frequency = 0x7bfa48?
<7>irq: irq 15 on host /soc@f0000000/inte??rupt-controller@0 mapped to
virtual irq 18?
<7>time_init: decrementer frequency ?? 8.125000 MHz?
<7>time_init: processor frequency   = 130.000000 MHz?
<6>clocksour??e: timebase mult[1ec4ec4f] shift[22] registered?
<7>clockevent: decrementer mult??214] shift[16] cpu[0]?
<6>Dentry cache hash table entries: 8192 (order: 3' 32768??bytes)?
<6>Inode-cache hash table entries: 4096 (order: 2' 16384 bytes)?
<6>Memor??: 62532k/65536k available (2064k kernel code' 2940k
reserved' 100k data' 99k bs??' 96k init)?
<6>SLUB: Genslabs=12' HWalign=16' Order=0-3' MinObjects=0' CPUs=1' ??odes=1?
<6>Calibrating delay loop... 16.12 BogoMIPS (lpj=80640)?
<4>Mount-cache h??sh table entries: 512?
<6>net_namespace: 296 bytes?
<6>NET: Registered protocol f??mily 16?
<4>bio: create slab <bio-0> at 0?
<7>Switched to high resolution mode on??CPU 0?
<6>NET: Registered protocol family 2?
<6>IP route cache hash table entries?? 1024 (order: 0' 4096 bytes)?
<6>TCP established hash table entries: 2048 (order?? 2' 16384 bytes)?
<6>TCP bind hash table entries: 2048 (order: 1' 8192 bytes)?
<6??TCP: Hash tables configured (established 2048 bind 2048)?
<6>TCP reno registered??
<6>NET: Registered protocol family 1?
<6>msgmni has been set to 122?
<6>io schedu??er noop registered?
<6>io scheduler deadline registered (default)?
<6>Generic RTC??Driver v1.07?
<7>irq: irq 4 on host /soc@f0000000/cpm@9c0/interrupt-controller@9??0
mapped to virtual irq 19?
<6>f0000a80.serial: ttyCPM0 at MMIO 0xc500ea80 (irq ?? 19) is a CPM UART?
<7>irq: irq 29 on host /soc@f0000000/cpm@9c0/interrupt-contr??ller@930
mapped to virtual irq 29?
<6>f0000a20.serial: ttyCPM1 at MMIO 0xc501aa2?? (irq = 29) is a CPM UART?
<7>irq: irq 3 on host /soc@f0000000/interrupt-control??er@0 mapped to
virtual irq 20?
<6>eth0: fs_enet: 00:00:00:00:00:00?
<7>irq: irq 7??on host /soc@f0000000/interrupt-controller@0 mapped to
virtual irq 21?
<6>eth1: ??s_enet: 00:00:00:00:00:00?
<6>FEC MII Bus: probed?
<6>fe000000.flash: Found 2 x16??devices at 0x0 in 32-bit bank?
<4> Amd/Fujitsu Extended Query Table at 0x0040?
<4??fe000000.flash: CFI does not contain boot bank location. Assuming top.?
<5>numbe?? of CFI chips: 1?
<5>cfi_cmdset_0002: Disabling erase-suspend-program due to cod?? brokenness.?
<6>TCP cubic registered?
<6>NET: Registered protocol family 17?
<6>R??C: Registered udp transport module.?
<6>RPC: Registered tcp transport module.?
<3??Root-NFS: No NFS server available' giving up.?
<3>VFS: Unable to mount root fs v??a NFS' trying floppy.?
<4>VFS: Cannot open root device "<NULL>" or unknown-block??2'0)?
<4>Please append a correct "root=" boot option; here are the available
par??itions:?
<4>1f00           32768 mtdblock0 driver: of-flash?
<0>Kernel panic - no?? syncing: VFS: Unable to mount root fs on
unknown-block(2'0)?
<4>Call Trace:?
<4>??c381fed0] [c00069e0] show_stack+0x44/0x16c (unreliable)?
<4>[c381ff10] [c001bc6c?? panic+0x8c/0x168?
<4>[c381ff60] [c01ecb80] mount_block_root+0x12c/0x244?
<4>[c38??ffb0] [c01ecdf4] prepare_namespace+0x4c/0x1c4?
<4>[c381ffd0] [c01ec1b0] kernel_i??it+0xd0/0xfc?
<4>[c381fff0] [c000da60] kernel_thread+0x4c/0x68?
<0>Rebooting in 1??0 seconds..?????????????????????????????????

At this point, my primary goal is to get console output working before
I do anything else. I've tried different "console=x" boot arguments
and I've added the "chosen" section to my DTS, but still no output.
Anyone have suggestions about this? Is something else messed up in my
DTS?

Thanks,
Mikhail Zaturenskiy

[-- Attachment #2: ep88xc.dts --]
[-- Type: application/octet-stream, Size: 5101 bytes --]

/*
 * EP88xC Device Tree Source
 *
 * Copyright 2006 MontaVista Software, Inc.
 * Copyright 2007,2008 Freescale Semiconductor, Inc.
 *
 * This program is free software; you can redistribute  it and/or modify it
 * under  the terms of  the GNU General  Public License as published by the
 * Free Software Foundation;  either version 2 of the  License, or (at your
 * option) any later version.
 */

/dts-v1/;

/ {
	model = "EP88xC";
	compatible = "fsl,ep88xc";
	#address-cells = <1>;
	#size-cells = <1>;

	cpus {
		#address-cells = <1>;
		#size-cells = <0>;

		PowerPC,885@0 {
			device_type = "cpu";
			reg = <0x0>;
			d-cache-line-size = <16>;
			i-cache-line-size = <16>;
			d-cache-size = <8192>;
			i-cache-size = <8192>;
			timebase-frequency = <8000000>; // MZ - was 0
			bus-frequency = <50000000>; // MZ - was 0
			clock-frequency = <130000000>; // MZ - was 0,
			interrupts = <15 2>;	// decrementer interrupt
			interrupt-parent = <&PIC>;
		};
	};

	memory {
		device_type = "memory";
		reg = <0x0 0x04000000>; // MZ - was <0x0 0x0>
	};

	localbus@f0000100 { // MZ - was fa20xxxx
		compatible = "fsl,mpc885-localbus", "fsl,pq1-localbus";
		#address-cells = <2>;
		#size-cells = <1>;
		reg = <0xf0000100 0x40>; // MZ - was fa20xxxx

		ranges = <
			0x0 0x0 0xfc000000 0x4000000
			0x3 0x0 0xfa000000 0x1000000
		>;

		flash@0,2000000 {
			compatible = "cfi-flash";
			reg = <0x0 0x2000000 0x2000000>;
			bank-width = <4>;
			device-width = <2>;
		};

		board-control@3,400000 {
			reg = <0x3 0x400000 0x10>;
			compatible = "fsl,ep88xc-bcsr";
		};
	};

	soc@f0000000 { // MZ - was fa20xxxx
		compatible = "fsl,mpc885", "fsl,pq1-soc";
		#address-cells = <1>;
		#size-cells = <1>;
		device_type = "soc";
		ranges = <0x0 0xf0000000 0x4000>; // MZ - was fa20xxxx
		bus-frequency = <0>;

		// Temporary -- will go away once kernel uses ranges for get_immrbase().
		reg = <0xf0000000 0x4000>; // MZ - was fa20xxxx

		mdio@e00 {
			compatible = "fsl,mpc885-fec-mdio", "fsl,pq1-fec-mdio";
			reg = <0xe00 0x188>;
			#address-cells = <1>;
			#size-cells = <0>;

			PHY0: ethernet-phy@0 {
				reg = <0x0>;
				device_type = "ethernet-phy";
			};

			PHY1: ethernet-phy@1 {
				reg = <0x1>;
				device_type = "ethernet-phy";
			};
		};

		ethernet@e00 {
			device_type = "network";
			compatible = "fsl,mpc885-fec-enet",
			             "fsl,pq1-fec-enet";
			reg = <0xe00 0x188>;
			local-mac-address = [ 00 00 00 00 00 00 ];
			interrupts = <3 1>;
			interrupt-parent = <&PIC>;
			phy-handle = <&PHY0>;
			linux,network-index = <0>;
		};

		ethernet@1e00 {
			device_type = "network";
			compatible = "fsl,mpc885-fec-enet",
			             "fsl,pq1-fec-enet";
			reg = <0x1e00 0x188>;
			local-mac-address = [ 00 00 00 00 00 00 ];
			interrupts = <7 1>;
			interrupt-parent = <&PIC>;
			phy-handle = <&PHY1>;
			linux,network-index = <1>;
		};

		PIC: interrupt-controller@0 {
			interrupt-controller;
			#interrupt-cells = <2>;
			reg = <0x0 0x24>;
			compatible = "fsl,mpc885-pic", "fsl,pq1-pic";
		};

		pcmcia@80 {
			#address-cells = <3>;
			#interrupt-cells = <1>;
			#size-cells = <2>;
			compatible = "fsl,pq-pcmcia";
			device_type = "pcmcia";
			reg = <0x80 0x80>;
			interrupt-parent = <&PIC>;
			interrupts = <13 1>;
		};

		cpm@9c0 {
			#address-cells = <1>;
			#size-cells = <1>;
			compatible = "fsl,mpc885-cpm", "fsl,cpm1";
			command-proc = <0x9c0>;
			interrupts = <0>;	// cpm error interrupt
			interrupt-parent = <&CPM_PIC>;
			reg = <0x9c0 0x40>;
			ranges;

			muram@2000 {
				#address-cells = <1>;
				#size-cells = <1>;
				ranges = <0x0 0x2000 0x2000>;

				data@0 {
					compatible = "fsl,cpm-muram-data";
					reg = <0x0 0x1c00>;
				};
			};

			brg@9f0 {
				compatible = "fsl,mpc885-brg",
				             "fsl,cpm1-brg",
				             "fsl,cpm-brg";
				reg = <0x9f0 0x10>;
			};

			CPM_PIC: interrupt-controller@930 {
				interrupt-controller;
				#interrupt-cells = <1>;
				interrupts = <5 2 0 2>;
				interrupt-parent = <&PIC>;
				reg = <0x930 0x20>;
				compatible = "fsl,mpc885-cpm-pic",
				             "fsl,cpm1-pic";
			};

			// MON-1
			serial@a80 {
				device_type = "serial";
				compatible = "fsl,mpc885-smc-uart",
				             "fsl,cpm1-smc-uart";
				reg = <0xa80 0x10 0x3e80 0x40>;
				interrupts = <4>;
				interrupt-parent = <&CPM_PIC>;
				fsl,cpm-brg = <1>;
				fsl,cpm-command = <0x90>;
				linux,planetcore-label = "SMC1";
			};

			// SER-1
			serial@a20 {
				device_type = "serial";
				compatible = "fsl,mpc885-scc-uart",
				             "fsl,cpm1-scc-uart";
				reg = <0xa20 0x20 0x3d00 0x80>;
				interrupts = <29>;
				interrupt-parent = <&CPM_PIC>;
				fsl,cpm-brg = <2>;
				fsl,cpm-command = <0x40>;
				linux,planetcore-label = "SCC2";
			};

			usb@a00 {
				#address-cells = <1>;
				#size-cells = <0>;
				compatible = "fsl,mpc885-usb",
				             "fsl,cpm1-usb";
				reg = <0xa00 0x18 0x1c00 0x80>;
				interrupt-parent = <&CPM_PIC>;
				interrupts = <30>;
				fsl,cpm-command = <0000>;
			};
		};
	};

	chosen {
		linux,stdout-path = "/soc@f0000000/cpm@9c0/serial@a80"; // MZ - added this 'chosen' section
	};

};

[-- Attachment #3: EP88x.h --]
[-- Type: application/octet-stream, Size: 8237 bytes --]

/*
 * Copyright (C) 2005 Arabella Software Ltd.
 * Yuli Barcohen <yuli@arabellasw.com>
 *
 * Support for Embedded Planet EP88x boards.
 * Tested on EP88xC with MPC885 CPU, 64MB SDRAM and 16MB flash.
 *
 * See file CREDITS for list of people who contributed to this
 * project.
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License as
 * published by the Free Software Foundation; either version 2 of
 * the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
 * MA 02111-1307 USA
 */
#ifndef __CONFIG_H
#define __CONFIG_H

//#define DEBUG // MZ

#define CONFIG_OF_LIBFDT 	// MZ - added to support FDT, suggested by Detlev

#define CONFIG_MPC885

#define CONFIG_EP88X				/* Embedded Planet EP88x board	*/

#define CONFIG_BOARD_EARLY_INIT_F		/* Call board_early_init_f	*/

/* Allow serial number (serial#) and MAC address (ethaddr) to be overwritten */
#define CONFIG_ENV_OVERWRITE

#define	CONFIG_8xx_CONS_SMC1	1		/* Console is on SMC1		*/
#define CONFIG_BAUDRATE		9600

#define	CONFIG_ETHER_ON_FEC1			/* Enable Ethernet on FEC1	*/
#define	CONFIG_ETHER_ON_FEC2			/* Enable Ethernet on FEC2	*/
#if defined(CONFIG_ETHER_ON_FEC1) || defined(CONFIG_ETHER_ON_FEC2)
#define CONFIG_SYS_DISCOVER_PHY
#define CONFIG_MII_INIT		1
#define FEC_ENET
#endif /* CONFIG_FEC_ENET */

#define CONFIG_8xx_OSCLK		10000000 /* 10 MHz oscillator on EXTCLK */
#define CONFIG_8xx_CPUCLK_DEFAULT	100000000
#define CONFIG_SYS_8xx_CPUCLK_MIN	40000000
#define CONFIG_SYS_8xx_CPUCLK_MAX	133000000

/*
 * BOOTP options
 */
#define CONFIG_BOOTP_BOOTFILESIZE
#define CONFIG_BOOTP_BOOTPATH
#define CONFIG_BOOTP_GATEWAY
#define CONFIG_BOOTP_HOSTNAME


/*
 * Command line configuration.
 */
#include <config_cmd_default.h>

#define CONFIG_CMD_DHCP
#define CONFIG_CMD_IMMAP
#define CONFIG_CMD_MII
#define CONFIG_CMD_PING


//#define CONFIG_BOOTDELAY	5		/* Autoboot after 5 seconds	*/
#define CONFIG_BOOTDELAY	15		/* MZ - Autoboot after 15 seconds	*/
//#define CONFIG_BOOTCOMMAND	"bootm fe060000"	/* Autoboot command	*/
#define CONFIG_BOOTCOMMAND	"bootm fc080000"	/* MZ - Autoboot command	*/
//#define CONFIG_BOOTARGS		"root=/dev/mtdblock1 rw mtdparts=phys:2M(ROM)ro,-(root)"
#define CONFIG_BOOTARGS		"console=ttyS0,9600n8 loglevel=7"	// MZ

#define CONFIG_BZIP2		/* Include support for bzip2 compressed images  */
#undef	CONFIG_WATCHDOG		/* Disable platform specific watchdog		*/

/*-----------------------------------------------------------------------
 * Miscellaneous configurable options
 */
#define CONFIG_SYS_PROMPT		"=> "		/* Monitor Command Prompt	*/
#define CONFIG_SYS_HUSH_PARSER
#define CONFIG_SYS_PROMPT_HUSH_PS2	"> "
#define CONFIG_SYS_LONGHELP				/* #undef to save memory	*/
#define CONFIG_SYS_CBSIZE		256		/* Console I/O Buffer Size	*/
#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16)  /* Print Buffer Size */
#define CONFIG_SYS_MAXARGS		16		/* Max number of command args	*/
#define CONFIG_SYS_BARGSIZE		CONFIG_SYS_CBSIZE	/* Boot Argument Buffer Size	*/

#define CONFIG_SYS_LOAD_ADDR		0x400000	/* Default load address		*/

#define CONFIG_SYS_HZ			1000		/* Decrementer freq: 1 ms ticks	*/

#define CONFIG_SYS_BAUDRATE_TABLE	{ 9600, 19200, 38400, 57600, 115200 }

/*-----------------------------------------------------------------------
 * RAM configuration (note that CONFIG_SYS_SDRAM_BASE must be zero)
 */
#define CONFIG_SYS_SDRAM_BASE		0x00000000
//#define CONFIG_SYS_SDRAM_MAX_SIZE	0x08000000	/* Up to 128 Mbyte		*/
#define CONFIG_SYS_SDRAM_MAX_SIZE	0x04000000	/* MZ - Up to 64 Mbyte		*/

#define CONFIG_SYS_MAMR		0x00805000

/*
 * 4096	Up to 4096 SDRAM rows
 * 1000	factor s -> ms
 * 32	PTP (pre-divider from MPTPR)
 * 4	Number of refresh cycles per period
 * 64	Refresh cycle in ms per number of rows
 */
#define CONFIG_SYS_PTA_PER_CLK		((4096 * 32 * 1000) / (4 * 64))

#define CONFIG_SYS_MEMTEST_START	0x00100000	/* memtest works on		*/
#define CONFIG_SYS_MEMTEST_END		0x00500000	/* 1 ... 5 MB in SDRAM		*/

#define CONFIG_SYS_RESET_ADDRESS	0x09900000

/*-----------------------------------------------------------------------
 * For booting Linux, the board info and command line data
 * have to be in the first 8 MB of memory, since this is
 * the maximum mapped by the Linux kernel during initialization.
 */
#define CONFIG_SYS_BOOTMAPSZ		(8 << 20)	/* Initial Memory map for Linux */

#define CONFIG_SYS_MONITOR_BASE	TEXT_BASE
#define CONFIG_SYS_MONITOR_LEN		(256 << 10)	/* Reserve 256 KB for Monitor   */
#undef CONFIG_BZIP2	// MZ
#ifdef CONFIG_BZIP2
#define CONFIG_SYS_MALLOC_LEN		(4096 << 10)	/* Reserve ~4 MB for malloc()   */
#else
#define CONFIG_SYS_MALLOC_LEN		(128 << 10)	/* Reserve 128 KB for malloc()  */
#endif /* CONFIG_BZIP2 */

/*-----------------------------------------------------------------------
 * Flash organisation
 */
#define CONFIG_SYS_FLASH_BASE		0xFC000000
#define CONFIG_SYS_FLASH_CFI				/* The flash is CFI compatible  */
#define CONFIG_FLASH_CFI_DRIVER			/* Use common CFI driver        */
#define CONFIG_SYS_MAX_FLASH_BANKS	1		/* Max number of flash banks	*/
//#define CONFIG_SYS_MAX_FLASH_SECT	512		/* Max num of sects on one chip */
#define CONFIG_SYS_MAX_FLASH_SECT	128		/* MZ - Max num of sects on one chip */

/* Environment is in flash */
#define CONFIG_ENV_IS_IN_FLASH
//#define CONFIG_ENV_SECT_SIZE	0x20000		/* We use one complete sector	*/
#define CONFIG_ENV_SECT_SIZE	0x40000		/* MZ - We use one complete sector	*/ 
#define CONFIG_ENV_ADDR		(CONFIG_SYS_MONITOR_BASE + CONFIG_SYS_MONITOR_LEN)

#define CONFIG_SYS_OR0_PRELIM		0xFC000160
#define CONFIG_SYS_BR0_PRELIM		(CONFIG_SYS_FLASH_BASE | BR_PS_32 | BR_MS_GPCM | BR_V)

#define	CONFIG_SYS_DIRECT_FLASH_TFTP

/*-----------------------------------------------------------------------
 * BCSR
 */
#define CONFIG_SYS_OR3_PRELIM		0xFF0005B0
#define CONFIG_SYS_BR3_PRELIM		(0xFA000000 |BR_PS_16 | BR_MS_GPCM | BR_V)

#define CONFIG_SYS_BCSR		0xFA400000

/*-----------------------------------------------------------------------
 * Internal Memory Map Register
 */
#define CONFIG_SYS_IMMR		0xF0000000

/*-----------------------------------------------------------------------
 * Definitions for initial stack pointer and data area (in DPRAM)
 */
#define CONFIG_SYS_INIT_RAM_ADDR	CONFIG_SYS_IMMR
#define CONFIG_SYS_INIT_RAM_END	0x2F00		/* End of used area in DPRAM	*/
#define CONFIG_SYS_GBL_DATA_SIZE	128  /* Size in bytes reserved for initial data */
#define CONFIG_SYS_GBL_DATA_OFFSET	(CONFIG_SYS_INIT_RAM_END - CONFIG_SYS_GBL_DATA_SIZE)
#define CONFIG_SYS_INIT_SP_OFFSET	CONFIG_SYS_GBL_DATA_OFFSET

/*-----------------------------------------------------------------------
 * Configuration registers
 */
#ifdef CONFIG_WATCHDOG
#define CONFIG_SYS_SYPCR		(SYPCR_SWTC | SYPCR_BMT | SYPCR_BME  | \
				 SYPCR_SWF  | SYPCR_SWE | SYPCR_SWRI | \
				 SYPCR_SWP)
#else
#define CONFIG_SYS_SYPCR		(SYPCR_SWTC | SYPCR_BMT | SYPCR_BME  | \
				 SYPCR_SWF  | SYPCR_SWP)
#endif /* CONFIG_WATCHDOG */

#define CONFIG_SYS_SIUMCR		(SIUMCR_MLRC01 | SIUMCR_DBGC11)

/* TBSCR - Time Base Status and Control Register */
#define CONFIG_SYS_TBSCR		(TBSCR_TBF | TBSCR_TBE)

/* PISCR - Periodic Interrupt Status and Control */
#define CONFIG_SYS_PISCR		PISCR_PS

/* SCCR - System Clock and reset Control Register */
#define SCCR_MASK		SCCR_EBDF11
#define CONFIG_SYS_SCCR		SCCR_RTSEL

#define CONFIG_SYS_DER			0

/*-----------------------------------------------------------------------
 * Cache Configuration
 */
#define CONFIG_SYS_CACHELINE_SIZE	16	/* For all MPC8xx chips			*/

/*-----------------------------------------------------------------------
 * Internal Definitions
 *
 * Boot Flags
 */
#define BOOTFLAG_COLD		0x01	/* Normal Power-On: Boot from flash	*/
#define BOOTFLAG_WARM		0x02	/* Software reboot			*/

#endif /* __CONFIG_H */

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 17:53       ` Mikhail Zaturenskiy
@ 2009-06-29 18:02         ` Gary Thomas
  2009-06-29 18:13           ` Mikhail Zaturenskiy
  0 siblings, 1 reply; 18+ messages in thread
From: Gary Thomas @ 2009-06-29 18:02 UTC (permalink / raw)
  To: Mikhail Zaturenskiy; +Cc: Scott Wood, Frank Svendsbøe, linuxppc-dev

Mikhail Zaturenskiy wrote:
> Hi guys, I've been working off your suggestions and here's my update
> on where I'm at now.
> 
> For reference, attached are my current
> "linux-2.6-denx/arch/powerpc/boot/dts/ep88xc.dts" and
> "u-boot-2009.03/include/configs/EP88x.h".
> 
>> I might be able to help out. Scott's right. According to U-Boots
>> include/configs/EP88x.h,
>> CONFIG_SYS_IMMR is 0xf0000000, but the Linux the ep88xc.dts is
>> referring to an IMMR set
>> to 0xfa200000. Replace every instance of 0xfa20 with 0xf000, and it may work.
> I did notice the IMMR discrepancy and as Frank suggested adjusted the
> 0xfa20xxxx values to 0xf000xxxx in my DTS, though I'm wondering if it
> would be better to have just set my CONFIG_SYS_IMMR to 0xfa200000? Not
> sure if that would break more than it would fix. Anyways, I have not
> noticed any difference in output after changing this in the DTS, but
> I'll leave it this way as it seems more correct.
> 
>>>> Also, make sure u-boot is properly updating the memory size in the device
>>>> tree.  Can you dump the post-fixup device tree in u-boot?
>>> Not sure, but I'll try to find out if that's possible. It'd certainly
>>> answer a lot of questions...
> While I have not yet figured out how to dump the post-fixup tree... I
> can see that U-Boot doesn't seem to be doing proper fixup because
> after manually setting all the DTS fields that U-Boot was supposed to
> fill in (clock frequency, RAM start/end, etc.), the kernel seems to be
> going through a fairly normal boot sequence. Without me manually
> setting those fields, they remain initialized to 0. The only issue is
> that no output goes to the console.
> 
> Here is my current output.
>>From U-Boot:
> 
> U-Boot 2009.03-svn8591 (Jun 29 2009 - 11:25:23)
> 
> CPU:   MPC885ZPnn at 100 MHz [40.0...133.0 MHz]
>        8 kB I-Cache 8 kB D-Cache FEC present
> Board: EP88xC 1.1  CPLD revision 2
> DRAM:  64 MB
> FLASH: 32 MB
> In:    serial
> Out:   serial
> Err:   serial
> Net:   FEC ETHERNET, FEC2 ETHERNET
> Hit any key to stop autoboot:  0
> => tftp ep88x_uimage2
> Using FEC ETHERNET device
> TFTP from server 10.0.54.129; our IP address is 10.0.54.150
> Filename 'ep88x_uimage2'.
> Load address: 0x400000
> Loading: #################################################################
>          ########
> done
> Bytes transferred = 1057419 (10228b hex)
> => tftp 750000 ep88x_dtb2
> Using FEC ETHERNET device
> TFTP from server 10.0.54.129; our IP address is 10.0.54.150
> Filename 'ep88x_dtb2'.
> Load address: 0x750000
> Loading: #
> done
> Bytes transferred = 7725 (1e2d hex)
> => bootm 400000 - 750000
> ## Booting kernel from Legacy Image at 00400000 ...
>    Image Name:   Linux-2.6.30-rc2-01402-gd4e2f68-
>    Image Type:   PowerPC Linux Kernel Image (gzip compressed)
>    Data Size:    1057355 Bytes =  1 MB
>    Load Address: 00000000
>    Entry Point:  00000000
>    Verifying Checksum ... OK
> ## Flattened Device Tree blob at 00750000
>    Booting using the fdt blob at 0x750000
>    Uncompressing Kernel Image ... OK
> 
> 
>>From Kernel via postmortem analysis - sorry it's a little messy, my
> debugger ICDPPCZ is not that great at producing memory dumps so I had
> to do some cleanup/conversion to make the results at least somewhat
> legible:
> 
> <6>Using Embedded Planet EP88xC machine description?
> <5>Linux version 2.6.30-rc2-??1402-gd4e2f68-dirty
> (devone@localhost.localdomain) (gcc version 4.2.2) #1 Mon J??n 29
> 11:35:28 CDT 2009?
> <7>Top of RAM: 0x4000000' Total RAM: 0x4000000?
> <7>Memory??hole size: 0MB?
> <4>Zone PFN ranges:?
> <4>  DMA      0x00000000 -> 0x00004000?
> <4>  ??ormal   0x00004000 -> 0x00004000?
> <4>Movable zone start PFN for each node?
> <4>ear??y_node_map[1] active PFN ranges?
> <4>    0: 0x00000000 -> 0x00004000?
> <7>On node 0??totalpages: 16384?
> <7>free_area_init_node: node 0' pgdat c021bf7c' node_mem_map ??023f000?
> <7>  DMA zone: 128 pages used for memmap?
> <7>  DMA zone: 0 pages reserve???
> <7>  DMA zone: 16256 pages' LIFO batch:3?
> <6>MMU: Allocated 72 bytes of context??maps for 16 contexts?
> <4>Built 1 zonelists in Zone order' mobility grouping on. ??Total pages: 16256?
> <5>Kernel command line: console=ttyS0'9600n8 loglevel=7?
> <6>N??_IRQS:512?
> <7>irq: irq 5 on host /soc@f0000000/interrupt-controller@0 mapped to
> ??irtual irq 16?
> <7>irq: irq 0 on host /soc@f0000000/cpm@9c0/interrupt-controller@??30
> mapped to virtual irq 17?
> <4>PID hash table entries: 256 (order: 8' 1024 byte??)?
> <4>Decrementer Frequency = 0x7bfa48?
> <7>irq: irq 15 on host /soc@f0000000/inte??rupt-controller@0 mapped to
> virtual irq 18?
> <7>time_init: decrementer frequency ?? 8.125000 MHz?
> <7>time_init: processor frequency   = 130.000000 MHz?
> <6>clocksour??e: timebase mult[1ec4ec4f] shift[22] registered?
> <7>clockevent: decrementer mult??214] shift[16] cpu[0]?
> <6>Dentry cache hash table entries: 8192 (order: 3' 32768??bytes)?
> <6>Inode-cache hash table entries: 4096 (order: 2' 16384 bytes)?
> <6>Memor??: 62532k/65536k available (2064k kernel code' 2940k
> reserved' 100k data' 99k bs??' 96k init)?
> <6>SLUB: Genslabs=12' HWalign=16' Order=0-3' MinObjects=0' CPUs=1' ??odes=1?
> <6>Calibrating delay loop... 16.12 BogoMIPS (lpj=80640)?
> <4>Mount-cache h??sh table entries: 512?
> <6>net_namespace: 296 bytes?
> <6>NET: Registered protocol f??mily 16?
> <4>bio: create slab <bio-0> at 0?
> <7>Switched to high resolution mode on??CPU 0?
> <6>NET: Registered protocol family 2?
> <6>IP route cache hash table entries?? 1024 (order: 0' 4096 bytes)?
> <6>TCP established hash table entries: 2048 (order?? 2' 16384 bytes)?
> <6>TCP bind hash table entries: 2048 (order: 1' 8192 bytes)?
> <6??TCP: Hash tables configured (established 2048 bind 2048)?
> <6>TCP reno registered??
> <6>NET: Registered protocol family 1?
> <6>msgmni has been set to 122?
> <6>io schedu??er noop registered?
> <6>io scheduler deadline registered (default)?
> <6>Generic RTC??Driver v1.07?
> <7>irq: irq 4 on host /soc@f0000000/cpm@9c0/interrupt-controller@9??0
> mapped to virtual irq 19?
> <6>f0000a80.serial: ttyCPM0 at MMIO 0xc500ea80 (irq ?? 19) is a CPM UART?
> <7>irq: irq 29 on host /soc@f0000000/cpm@9c0/interrupt-contr??ller@930
> mapped to virtual irq 29?
> <6>f0000a20.serial: ttyCPM1 at MMIO 0xc501aa2?? (irq = 29) is a CPM UART?
> <7>irq: irq 3 on host /soc@f0000000/interrupt-control??er@0 mapped to
> virtual irq 20?
> <6>eth0: fs_enet: 00:00:00:00:00:00?
> <7>irq: irq 7??on host /soc@f0000000/interrupt-controller@0 mapped to
> virtual irq 21?
> <6>eth1: ??s_enet: 00:00:00:00:00:00?
> <6>FEC MII Bus: probed?
> <6>fe000000.flash: Found 2 x16??devices at 0x0 in 32-bit bank?
> <4> Amd/Fujitsu Extended Query Table at 0x0040?
> <4??fe000000.flash: CFI does not contain boot bank location. Assuming top.?
> <5>numbe?? of CFI chips: 1?
> <5>cfi_cmdset_0002: Disabling erase-suspend-program due to cod?? brokenness.?
> <6>TCP cubic registered?
> <6>NET: Registered protocol family 17?
> <6>R??C: Registered udp transport module.?
> <6>RPC: Registered tcp transport module.?
> <3??Root-NFS: No NFS server available' giving up.?
> <3>VFS: Unable to mount root fs v??a NFS' trying floppy.?
> <4>VFS: Cannot open root device "<NULL>" or unknown-block??2'0)?
> <4>Please append a correct "root=" boot option; here are the available
> par??itions:?
> <4>1f00           32768 mtdblock0 driver: of-flash?
> <0>Kernel panic - no?? syncing: VFS: Unable to mount root fs on
> unknown-block(2'0)?
> <4>Call Trace:?
> <4>??c381fed0] [c00069e0] show_stack+0x44/0x16c (unreliable)?
> <4>[c381ff10] [c001bc6c?? panic+0x8c/0x168?
> <4>[c381ff60] [c01ecb80] mount_block_root+0x12c/0x244?
> <4>[c38??ffb0] [c01ecdf4] prepare_namespace+0x4c/0x1c4?
> <4>[c381ffd0] [c01ec1b0] kernel_i??it+0xd0/0xfc?
> <4>[c381fff0] [c000da60] kernel_thread+0x4c/0x68?
> <0>Rebooting in 1??0 seconds..?????????????????????????????????
> 
> At this point, my primary goal is to get console output working before
> I do anything else. I've tried different "console=x" boot arguments
> and I've added the "chosen" section to my DTS, but still no output.
> Anyone have suggestions about this? Is something else messed up in my
> DTS?

Did you try 'root=ttyCPM0,9600'?


-- 
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 18:02         ` Gary Thomas
@ 2009-06-29 18:13           ` Mikhail Zaturenskiy
  2009-06-29 18:41             ` Scott Wood
  0 siblings, 1 reply; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-29 18:13 UTC (permalink / raw)
  To: Gary Thomas; +Cc: Scott Wood, Frank Svendsbøe, linuxppc-dev

Hi Gary

> Did you try 'root=ttyCPM0,9600'?

Gave that a shot just now, doesn't seem to have changed anything other
than that it now says "VFS: Cannot open root device ttyCMP0,9600" or
unknown-block(2,0)." But thanks for the suggestion though.

What exactly was this supposed to do? I thought that the "root=" boot
argument did not play a role in console output of the boot
information.

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 18:13           ` Mikhail Zaturenskiy
@ 2009-06-29 18:41             ` Scott Wood
  2009-06-29 20:24               ` Mikhail Zaturenskiy
  0 siblings, 1 reply; 18+ messages in thread
From: Scott Wood @ 2009-06-29 18:41 UTC (permalink / raw)
  To: Mikhail Zaturenskiy; +Cc: Frank Svendsbøe, linuxppc-dev, Gary Thomas

Mikhail Zaturenskiy wrote:
> Hi Gary
> 
>> Did you try 'root=ttyCPM0,9600'?
> 
> Gave that a shot just now, doesn't seem to have changed anything other
> than that it now says "VFS: Cannot open root device ttyCMP0,9600" or
> unknown-block(2,0)." But thanks for the suggestion though.
> 
> What exactly was this supposed to do? I thought that the "root=" boot
> argument did not play a role in console output of the boot
> information.

s/root=/console=/

Alternatively, you can set /chosen/linux,stdout-path to poin to the 
serial node you want to use for the console.

-Scott

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 18:41             ` Scott Wood
@ 2009-06-29 20:24               ` Mikhail Zaturenskiy
  2009-06-29 20:31                 ` Scott Wood
  0 siblings, 1 reply; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-29 20:24 UTC (permalink / raw)
  To: Scott Wood; +Cc: Frank Svendsbøe, linuxppc-dev, Gary Thomas

Hi Scott,

> s/root=/console=/
I'm not quite sure what you mean by this.

> Alternatively, you can set /chosen/linux,stdout-path to poin to the serial
> node you want to use for the console.
If you look at the bottom of ep88xc.dts that I attached with my
previous post, I added the following:
chosen {
		linux,stdout-path = "/soc@f0000000/cpm@9c0/serial@a80"; // MZ -
added this 'chosen' section
};

However it did not seem to help, unless I did this wrong... still no
console output.

Thanks,
Mikhail

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 20:24               ` Mikhail Zaturenskiy
@ 2009-06-29 20:31                 ` Scott Wood
  2009-06-29 20:46                   ` Mikhail Zaturenskiy
  0 siblings, 1 reply; 18+ messages in thread
From: Scott Wood @ 2009-06-29 20:31 UTC (permalink / raw)
  To: Mikhail Zaturenskiy; +Cc: Frank Svendsbøe, linuxppc-dev, Gary Thomas

Mikhail Zaturenskiy wrote:
> Hi Scott,
> 
>> s/root=/console=/
> I'm not quite sure what you mean by this.

Change "root=" to "console=".

-Scott

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 20:31                 ` Scott Wood
@ 2009-06-29 20:46                   ` Mikhail Zaturenskiy
  2009-06-29 21:03                     ` Scott Wood
  0 siblings, 1 reply; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-29 20:46 UTC (permalink / raw)
  To: Scott Wood; +Cc: Frank Svendsbøe, linuxppc-dev, Gary Thomas

> Change "root=" to "console=".
Thank you for clarifying.

I tried this but I get the following in my memory dump:

<6>Using Embedded Planet EP88xC ??achine description?
<5>Linux ver??ion 2.6.30-rc2-01402-gd4e2f68-d??rty
(devone@localhost.localdoma??n) (gcc version 4.2.2) #1 Mon J??n 29
11:35:28 CDT 2009?
<7>Top o?? RAM: 0x4000000' Total RAM: 0x4??00000?
<7>Memory hole size: 0MB???
>4>Zone PFN ranges:?
<4>  DMA    ?? 0x00000000 -> 0x00004000?
<4>  ??ormal   0x00004000 -> 0x0000400???
<4>Movable zone start PFN for ??ach node?
<4>early_node_map[1] a??tive PFN ranges?
<4>    0: 0x000??0000 -> 0x00004000?
<7>On node 0??totalpages: 16384?
<7>free_area_??nit_node: node 0' pgdat c021bf7??' node_mem_map c023f000?
<7>  DM?? zone: 128 pages used for memma???
<7>  DMA zone: 0 pages reserve???
<7>  DMA zone: 16256 pages' LI??O batch:3?
<6>MMU: Allocated 72 ??ytes of context maps for 16 con??exts?
<4>Built 1 zonelists in Zo??e order' mobility grouping on. ??Total pages: 16256?
<5>Kernel co??mand line: console=ttyCPM0'9600??8 loglevel=7?
<6>NR_IRQS:512?
<7>??rq: irq 5 on host /soc@f0000000??interrupt-controller@0 mapped
t?? virtual irq 16?
<7>irq: irq 0 o?? host /soc@f0000000/cpm@9c0/int??rrupt-controller@930
mapped to ??irtual irq 17?
<4>PID hash table??entries: 256 (order: 8' 1024 by??es)?
<4>Decrementer Frequency = ??x7bfa48?
<7>irq: irq 15 on host ??soc@f0000000/interrupt-controll??r@0 mapped
to virtual irq 18?
<7??time_init: decrementer frequenc?? = 8.125000 MHz?
<7>time_init: p??ocessor frequency   = 130.00000?? MHz?
<6>clocksource: timebase m??lt[1ec4ec4f] shift[22] register??d?
<7>clockevent: decrementer mu??t[214] shift[16] cpu[0]?
<7>irq:??irq 4 on host /soc@f0000000/cpm??9c0/interrupt-controller@930
ma??ped to virtual irq 19?
<6>consol?? [ttyCPM0] enabled

Seems like at that point it begins to redirect output to ttyCPM0 but
still nothing showing on the console...

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 20:46                   ` Mikhail Zaturenskiy
@ 2009-06-29 21:03                     ` Scott Wood
  2009-06-30 16:11                       ` Mikhail Zaturenskiy
  0 siblings, 1 reply; 18+ messages in thread
From: Scott Wood @ 2009-06-29 21:03 UTC (permalink / raw)
  To: Mikhail Zaturenskiy; +Cc: Frank Svendsbøe, linuxppc-dev, Gary Thomas

Mikhail Zaturenskiy wrote:
> 
> Seems like at that point it begins to redirect output to ttyCPM0 but
> still nothing showing on the console...

Check the clock-frequency of the CPM BRG node.  If u-boot isn't setting 
the memory, it's probably not setting this either.

If you're not up to the task of fixing u-boot to fill in the device 
tree, you may want to try cuImage.

-Scott

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-29 21:03                     ` Scott Wood
@ 2009-06-30 16:11                       ` Mikhail Zaturenskiy
  2009-06-30 17:48                         ` Mikhail Zaturenskiy
  0 siblings, 1 reply; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-30 16:11 UTC (permalink / raw)
  To: Scott Wood; +Cc: Frank Svendsbøe, linuxppc-dev, Gary Thomas

> Check the clock-frequency of the CPM BRG node. =A0If u-boot isn't setting=
 the
> memory, it's probably not setting this either.

I set the CPM BRG "clock-frequency =3D <153609>" (value obtained from
u-boot's 'brginfo' command), set my CPU "clock-frequency =3D
<100000000>" (down from 130000000) to match what u-boot is using, and
used the "console=3DttyCPM0,9600n8" boot arg and I've finally got
console output! Thanks everyone!

I'll still try to figure out how to get u-boot to fill all this in.

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-30 16:11                       ` Mikhail Zaturenskiy
@ 2009-06-30 17:48                         ` Mikhail Zaturenskiy
  2009-07-01 12:13                           ` Detlev Zundel
  2009-07-01 17:40                           ` Mikhail Zaturenskiy
  0 siblings, 2 replies; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-06-30 17:48 UTC (permalink / raw)
  To: Scott Wood; +Cc: Frank Svendsbøe, linuxppc-dev, Gary Thomas

> I'll still try to figure out how to get u-boot to fill all this in.
Got it... thanks to
"http://www.mail-archive.com/u-boot-users@lists.sourceforge.net/msg05111.html"

I made sure that CONFIG_OF_LIBFDT and CONFIG_OF_BOARD_SETUP were both
present in "u-boot-2009.03/include/configs/EP88x.h". Then added the
following to the very end of "u-boot-2009.03/board/ep88x/ep88x.c":

#if defined(CONFIG_OF_LIBFDT) && defined(CONFIG_OF_BOARD_SETUP)
void ft_board_setup(void *blob, bd_t *bd)
{
         ft_cpu_setup(blob, bd);
}
#endif /* defined(CONFIG_OF_LIBFDT) && defined(CONFIG_OF_BOARD_SETUP) */

I suppose I could have put this code in w/o the "#if defined..." and
forget about the "CONFIG_OF_BOARD_SETUP" flag since I'm not really
using the "fdt boardsetup" command, but whatever.

As for my device tree, I reverted back to the original version with
nothing filled in and just replaced 0xfa20xxxx with 0xf000xxxx as Gary
suggested earlier.

Once again, thanks to all those who offered suggestions!

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-30 17:48                         ` Mikhail Zaturenskiy
@ 2009-07-01 12:13                           ` Detlev Zundel
  2009-07-01 17:04                             ` Scott Wood
  2009-07-01 17:40                           ` Mikhail Zaturenskiy
  1 sibling, 1 reply; 18+ messages in thread
From: Detlev Zundel @ 2009-07-01 12:13 UTC (permalink / raw)
  To: linuxppc-dev

Hi,

> As for my device tree, I reverted back to the original version with
> nothing filled in and just replaced 0xfa20xxxx with 0xf000xxxx as Gary
> suggested earlier.

Would it be a problem to also dynamically fixup IMMR in the device tree
from U-Boot?

Cheers
  Detlev

--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu@denx.de

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-07-01 12:13                           ` Detlev Zundel
@ 2009-07-01 17:04                             ` Scott Wood
  2009-07-02 13:23                               ` Detlev Zundel
  0 siblings, 1 reply; 18+ messages in thread
From: Scott Wood @ 2009-07-01 17:04 UTC (permalink / raw)
  To: Detlev Zundel; +Cc: linuxppc-dev

On Wed, Jul 01, 2009 at 02:13:29PM +0200, Detlev Zundel wrote:
> Hi,
> 
> > As for my device tree, I reverted back to the original version with
> > nothing filled in and just replaced 0xfa20xxxx with 0xf000xxxx as Gary
> > suggested earlier.
> 
> Would it be a problem to also dynamically fixup IMMR in the device tree
> from U-Boot?

Yes.  It can appear in multiple places in the device tree (for exmaple,
in things like the localbus and pci nodes where we have some IMMR
registers but need ranges to point outside IMMR); this introduces more
dependencies between u-boot and the input dtb than just getting the
address right in the first place.

-Scott

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-06-30 17:48                         ` Mikhail Zaturenskiy
  2009-07-01 12:13                           ` Detlev Zundel
@ 2009-07-01 17:40                           ` Mikhail Zaturenskiy
  1 sibling, 0 replies; 18+ messages in thread
From: Mikhail Zaturenskiy @ 2009-07-01 17:40 UTC (permalink / raw)
  To: Detlev Zundel; +Cc: linuxppc-dev

>> As for my device tree, I reverted back to the original version with
>> nothing filled in and just replaced 0xfa20xxxx with 0xf000xxxx as Gary
>> suggested earlier.
>
>Would it be a problem to also dynamically fixup IMMR in the device tree
>from U-Boot?
>
>Cheers
> Detlev

Hi Detlev, it would be nice but how do I do this?

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

* Re: Trouble "Transferring control to Linux (at address 00000000)"
  2009-07-01 17:04                             ` Scott Wood
@ 2009-07-02 13:23                               ` Detlev Zundel
  0 siblings, 0 replies; 18+ messages in thread
From: Detlev Zundel @ 2009-07-02 13:23 UTC (permalink / raw)
  To: linuxppc-dev

Hi Scott,

> On Wed, Jul 01, 2009 at 02:13:29PM +0200, Detlev Zundel wrote:
>> Hi,
>> 
>> > As for my device tree, I reverted back to the original version with
>> > nothing filled in and just replaced 0xfa20xxxx with 0xf000xxxx as Gary
>> > suggested earlier.
>> 
>> Would it be a problem to also dynamically fixup IMMR in the device tree
>> from U-Boot?
>
> Yes.  It can appear in multiple places in the device tree (for exmaple,
> in things like the localbus and pci nodes where we have some IMMR
> registers but need ranges to point outside IMMR); this introduces more
> dependencies between u-boot and the input dtb than just getting the
> address right in the first place.

Ah, I see - the IMMR address is duplicated because the nodes you mention
are not children of "soc", so they cannot reference that parent address
space.

I guess re-arranging the hierarchy is not viable, but maybe we can
include this orthogonal parent-child relation.  For example, could a
"reg-parent" phandle solve this duplication?

Cheers
  Detlev

--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu@denx.de

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

end of thread, other threads:[~2009-07-02 13:23 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-26 16:13 Trouble "Transferring control to Linux (at address 00000000)" Mikhail Zaturenskiy
2009-06-26 16:55 ` Scott Wood
2009-06-26 17:12   ` Mikhail Zaturenskiy
2009-06-27 21:01     ` Frank Svendsbøe
2009-06-29 17:53       ` Mikhail Zaturenskiy
2009-06-29 18:02         ` Gary Thomas
2009-06-29 18:13           ` Mikhail Zaturenskiy
2009-06-29 18:41             ` Scott Wood
2009-06-29 20:24               ` Mikhail Zaturenskiy
2009-06-29 20:31                 ` Scott Wood
2009-06-29 20:46                   ` Mikhail Zaturenskiy
2009-06-29 21:03                     ` Scott Wood
2009-06-30 16:11                       ` Mikhail Zaturenskiy
2009-06-30 17:48                         ` Mikhail Zaturenskiy
2009-07-01 12:13                           ` Detlev Zundel
2009-07-01 17:04                             ` Scott Wood
2009-07-02 13:23                               ` Detlev Zundel
2009-07-01 17:40                           ` Mikhail Zaturenskiy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).