02-10-2011 01:06 PM
I'm encountering problems trying to get Linux to boot on a Virtex 6 Evaluation Kit (ML605) using Microblaze. I'm using Xilinx EDK 12.4 and have followed the instructions on xilinx.wikidot.com.
When I try to boot linux using XMD (connect mb mdm -> dow ... -> run), the console outputs the following statements and then freezes:
early_printk_console is enabled at 0x40401000
Ramdisk addr 0x00000003, Compiled-in FDT at 0xc021b1f0
I'm not sure whether my problem is due to my Microblaze configuration or due to a wrong setting in the Linux kernel configuration. I've attached my .config and .dts files.
In my hardware design, the DDR3 SDRAM is located at 0xE0000000 and I set the Kernal start address to 0xE1000000, since this is within the SDRAM range. I used sp605_le_defconfig as the starting point for my .config, since that appeared to be the closest to my design (although I'm not using the sp605). I've tried using xilinx_mmu_defconfig as a starting point for my .config, however that failed at the same point. I haven't done any significant changes after using menuconfig to set the kernel start address, so I think there must be something mismatching between my design and this config file.
Is there anything that appears wrong between the .dts and .config files?
02-10-2011 01:37 PM
Did u run it with our reference system before you made your own system?
Getting a baseline is the best 1st. Then move in small deltas.
I also would set the kernel configuration memory address to the start of memory 1st unless you know what you're doing.
02-10-2011 01:41 PM
02-10-2011 02:03 PM
Which reference design should I be using test Linux?
Which cache addresses don't match? I needed to make the BRAM size 256 kb (for a reason unrelated to booting linux), so I changed the size by increasing the size in the Addresses tab in XPS. Aside from running the "Base System Builder" and "Configure IP" on Microblaze, I didn't do any changes to the HW design. If there's a problem in the dts, then I must not have properly configured the HW design.
When I initially tested booting linux, I was using 0xE0000000 as the base address. I tried testing kernel start addresses, and right now am using 0xE1000000. I can switch back to 0xE0000000.
Thanks for your help!
02-10-2011 02:07 PM
The device tree is based on the h/w system, so you must have changed things.
d-cache-baseaddr = <0xc0000000>;
d-cache-highaddr = <0xffffffff>;
d-cache-line-size = <0x10>;
d-cache-size = <0x2000>;
device_type = "cpu";
i-cache-baseaddr = <0xc0000000>;
i-cache-highaddr = <0xffffffff>;
i-cache-line-size = <0x20>;
i-cache-size = <0x2000>;
There's a link to a system on the wiki page.
The ML605 is not the primary test platform, but was tested briefly. A reference design is provided by Xilinx at the following location.
02-10-2011 02:16 PM
So in my case I would look at the "AXI4 interconnect-based Reference Designs" for EDK 12.4, right? I got the impression that these designs were purely for tutorials, since it includes a SW and HW tutorial. Should I just pick the completed SW design and start from there?
02-10-2011 04:27 PM
Yes, they are to help get you going quicker.
You can just add the device tree generator, gen a device tree, configure the kernel and it should boot.
02-11-2011 09:05 AM
Yes, the reference design worked correctly.
Since my Linux kernel configuration was the same (except for the different kernel start address), the reason my design failed must be related to the hw implementation. Is there anything in particular my design had that appeared wrong compared with the reference design (aside from the cache issue)?
02-11-2011 09:08 AM
You need to compare your MHS files and device tree files with the one that works. At this point you have a baseline established, make small steps from there if you have to so that you can isolate the problem.
I wish it was easier, but your building a complex system pretty easily.
02-23-2011 06:54 AM
03-15-2011 11:43 PM
I got almost same problem in porting linux2.6.28 to virtex-II pro on powerpc. It seems relate to address map. since if I use default SDRAM Base address 0x0, then It can boot right. If I change SDRAM base address as 0xE0000000, then it has no output in console.
I use make simpleImage.*....And I saw wrapper .txt in doucment in linux tree. It said simpleImage have RAM address map to 0 or has MMU off.
have you solve this problem? Email me: firstname.lastname@example.org
06-10-2011 03:12 AM
The kernel boot procedure is sort of wonky and probably destroys your bootup:
The kernel starts to allocate pages up to the kernel head + 32MB - we found that setting the kernel at 16 MB from the end of the DDR results in memory access outside the DDR.
The memory will be cleared by the kernel starting from DDR start + 32MB. In our case the memory was at 0x40000000, the kernel was at 0x4f000000. At first it will not start because it writes into the 0x50000000 section, moving the kernel to 0x4e000000 solves that. However the clear will commence from 0x42000000 and erase the kernel - again resulting in a hangup.
Make sure you specify a memory address range in your DTS at which point your kernel will start as well. Make sure its 32MB in size or larger. Make sure the internal kernel address offset is set to that address as well.
If you deviate, you will have to modify the linux kernel in order to boot. You most definitely do not want to do that...