Jump to content
  • 0

Possible to run Linux on MicroBlaze using SD Pmod?


gautier

Question

Hello all, I have a question pertaining to my ZedBoard. I'm running Linux on the PS using the built in SD card slot. I'm simultaneously building an isolated system in the PL, currently consisting of a Microblaze running a baremetal application. Now I'd like to run Python in the PL without touching the PS setup. Could I use the SD card Pmod to persist Linux to run on the Microblaze? I know I can't touch the existing SPI since it belongs to the PS, and I'd also like plenty of storage.

Thank you for your time

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

What you are suggesting seems like it should be possible, but I will caution that this is outside of the realm of what I have done and I may be missing a "gotch-ya" somewhere. I'm going to assume you will be using petalinux to design the microblaze linux system.

Xilinx provides an SPI Linux driver for its quad SPI soft IP, and Linux should have an SD card driver out there that operates directly with an SPI device (check me on this), in which case you will just need to add the proper device tree nodes to connect the two drivers and get the pmodSD to show up as a proper block device. You could then use petalinux-config to indicate you will be using an SD card for the rootfs (you might need to manually modify the automatically generated bootargs to point to the correct partition on your SD card). 

I'm not entirely sure the best way to do this, but one thing you will need to be careful of is that the microblaze and PS Linux systems aren't trying to use any of the same memory. You might be able to handle this in Vivado by modifying the address spaces or alternatively by using reserved-memory nodes in the device trees (or maybe a combo of both). It will be important that both u-boot's and kernel's don't try to use memory that is allocated to the other system.

You would also need to modify the microblaze FSBL (which is typically loaded into the Block RAM by the bitstream) to read the u-boot.elf and image.ub out of the Pmod SD card instead of Quad SPI flash (which I believe is the typical behavior for a microblaze petalinux system). You could possibly get around this extra work by also using a Pmod SF3 to hold the u-boot.elf and image.ub. 

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...