06-15-2010 07:38 AM
I am using Linux kernel source code from xilinx git tree and I comes up successfully on my platform.
However I have problem with the root file system and I want to know if there is any ready to use initramfs image so that I can insert it into my kernel?
the xilinx open source wiki says that you can download such a file there in the "files" section however, when you look inside files section there is nothing special to download.
I want to know if you can provide us with the image or i should make it myself?
Mohammad Sadegh Sadri
06-15-2010 07:45 AM
Can you provide the exact page where you don't see what you're looking for as I don't see a problem when I look, but maybe I'm overlooking something.
06-15-2010 10:46 PM
06-21-2010 07:58 AM
It's MMU only as we don't support no MMU
From the wiki page at http://xilinx.wikidot.com/microblaze-linux:
Everything on this site assumes building a Linux Kernel with MMU only as Xilinx is not supporting the non-MMU kernel.
06-21-2010 10:40 PM
then I go back to my very very old question that I never found a reasonable answer for,
if we have a for example MMU kernel, what is the outcome of this dommand in XMD:
simply it generates errors because, XMD (as EDK 11.2) does not support virtual memory address.
Am i correct?
on the other hand, you may like to use "dow -data" and then "con" and this again does not work for me.
so the only solution is to use u-boot, which i'm working on right now.
Mohammad Sadegh Sadri.
06-22-2010 06:33 AM
No that's not true. If you follow the instructions on the wiki about how to build and download the kernel u-boot is not required. XMD will download the kernel without the MMU on as it gets downloaded into physical memory.
Please following the directions on the following page.
06-22-2010 11:14 PM
The above link , does not talk about enabling support for MMU in Linux at all.
So, if one configure the kernel using what mentioned in the above link, the kernel does not support MMU.
In this case XMD is able to load the kernel using dow command simply.
Now , if one person enable support for MMU in kernel configuration:
Kernel Configuration ---> Processor type and Features ---> MMU Support
if you enable MMU Support in kernel configuration, then XMD will no more be able to load the kernel executable. the Dow commadn generates errors.
It reports that it does not know the memory addresses specified in the executable. this is correct, because now the kernel is using MMU and all of the address values are now virtual addresses instead of physical one.
My question is : How do you execute and MMU kernel using XMD?
Mohammad Sadegh Sadri.
06-23-2010 01:23 AM
I agree with linnj, this works perfectly.:
xmd> connect mb mdm
xmd> dow arch/microblaze/boot/simpleImage.ml507_mb_v1
But the base address of the system RAM must be the same in the hardware (bitstream) and in the kernel configuration.
I had the same problem the first time I try to build my own system (kernel + bitstream).
As I say in an other post, my advise :
- Try to use first the hardware (bitstream) already generated by Xilinx, and also the Xilinx kernel. This validate the board
- Then keep the Xilinx hardware, but put your own kernel. This validate your kernel
- Then try to generate your own hardware. This will requires to modify the kernel (mainly the address of the RAM).
I think this step by step approach is the best.
06-29-2010 06:10 AM
I have solved all of my problems, my main line linux kernel now comes up without any problems and mounts the initial ram disk and then the rootfs and finally i have the shell.
my problem was : I had not disabled the intel keyboard driver which is only available in x86.
I have not used xilinx_mmu_defconfig and mmu_defconfig, I have performed the Linux kernel configuration process myself. And as I said every thing is now Ok.
My procedure for loading the linux kernel is as follows :
1- using XMD I load U-boot ( dow u-boot )
2- i run u-boot
3- i load the linux kernel (simpleImage.xilinx.ub) , the complied device tree and the initramfs using u-boot
4- i boot the system using bootm
every thing is working Ok, and i have no more problem. however, just suppose i want to load and execute the linux kernel directly :
As you claim, I should be able to do this using the dow command in u-boot
but it does not work. because, MMU is enabled and XMD does not understand virtual memory addresses.
Here is the outcome of trying to load the kernel using XMD directly:
XMD% dow /home/sadri/hdl/downloads/linux_microblaze/simpleImage.xilinx
System Reset .... DONE
Downloading Program -- /home/sadri/hdl/downloads/linux_microblaze/simpleImage.xilinx
section, .text: 0xc0000000-0xc019529f
section, .ref.text: 0xc01952a0-0xc019572b
section, .devinit.text: 0xc019572c-0xc0195b2f
section, .devexit.text: 0xc0195b30-0xc0195bdf
section, .init.text: 0xc01fa000-0xc02102b7
section, .init.ivt: 0xc0210e04-0xc0210e6b
ERROR: Failed to download ELF file
I-Side Memory Access Check Failed
Section, 0xc0000000-0xc019529f Not Accessible from Processor I-Side Interface
So , what is the magic here, that you can load your kernel easily using XMD and support for MMU is active for you, but I can not do it?
Mohammad Sadegh Sadri
06-29-2010 06:30 AM
It seems like you either not using the correct image of the kernel, or your h/w design is not correct.
I guess you could be using some old tool set that I haven't used but I doubt that.
If you using objdump to dump the headers of the elf file that your loading, (-h for objdump options), you'll see that the load address is not virtual and should match your physical address space. If that's not the case you are using wrong image (like vmlinux) or using the wrong procedure to build it.