Booting from SD card

Hi,

I want to build my own SPL and uboot for BBB and want to boot them via SD card. What I expect to do is, I want to reserve 1MB for SPL, 1MB for Uboot, 5MB for Kernel rest rootfs in SD card. How can I do this? can anyone guide to a link where I can partition my SD card according this need?

And what are the changes to be made in SPL to point Uboot from other 1MB partition, similar what are the necessary change to be done in Uboot to load the kernel from other partition of SD card to RAM(DDR3)?

If it was a NAND Flash, I would’ve directly given the physical address. similarly can I give the physical address of SD to load from onto RAM?

Regards,
Bharath

Hi,

I want to build my own SPL and uboot for BBB and want to boot them via SD
card. What I expect to do is, I want to reserve 1MB for SPL, 1MB for Uboot,

Considering SPL is usually less then 109Kb to boot and U-boot is less
then 512Kb, save a 1MB by having both spl/uboot in the first 1MB

5MB for Kernel rest rootfs in SD card. How can I do this? can anyone guide
to a link where I can partition my SD card according this need?

And what are the changes to be made in SPL to point Uboot from other 1MB
partition, similar what are the necessary change to be done in Uboot to load
the kernel from other partition of SD card to RAM(DDR3)?

If it was a NAND Flash, I would've directly given the physical address.
similarly can I give the physical address of SD to load from onto RAM?

Considering your treating the SD like "nand" by placing this objects
at specific location, just use the raw offsets on the mmc card and
make sure your partition is out of the way for the rootfs..

Regards,

Bharath,

I’ve been following the instructions at
http://wiki.beyondlogic.org/index.php?title=BeagleBoneBlack_Upgrading_uBoot

As Robert mentions you can use raw mode and place MLO/SPL and u-boot at specific locations:
dd if=MLO of=/dev/mmcblk0 bs=512 seek=256 count=256 conv=notrunc

dd if=u-boot.img of=/dev/mmcblk0 bs=512 seek=768 count=1024 conv=notrunc

I’ve got this successfully working on internal MMC, but when I use SD Card to get the following with u-boot:

U-Boot 2015.10 (Nov 21 2015 - 01:06:45 -0800)

Watchdog enabled

I2C: ready

DRAM: 512 MiB

initcall sequence 9ffa2468 failed at call 610a2c4f (err=-12)

### ERROR ### Please RESET the board ###

As a work around, I’ve placed u-boot.img in a FAT32 partition on the SDCard and it works.

Pete.

Thanks a lot Robert and Pete.

Regards,
Bharath