PINE64
Launching OS in the SD card from p-boot in MMC - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: PinePhone (https://forum.pine64.org/forumdisplay.php?fid=120)
+--- Forum: PinePhone Software (https://forum.pine64.org/forumdisplay.php?fid=121)
+--- Thread: Launching OS in the SD card from p-boot in MMC (/showthread.php?tid=15003)



Launching OS in the SD card from p-boot in MMC - chuso - 10-01-2021

Hi,

I'm using p-boot as the boot loader and it's awesome. Much more convenient and easy than UBoot.

I thought I could have an SD card inserted with an OS but without a boot sector and install p-boot to the MMC card and have two boot entries, one to boot the MMC OS and the other for the SD one, so I can easily switch between both OSs without having to remove and insert the SD card.

I almost got it working. So although the SD card is inserted, since it doesn't have a boot sector, the boot sequence fails back to MMC and loads p-boot with the boot entries for MMC and SD. The MMC one works and boots the MMC OS, but the SD one just leads to a black screen.

This is my boot.conf file:

Code:
no          = 0
  name      = MMC card
  atf       = ../../usr/share/p-boot/fw.bin
  dtb       = ../../boot/dtbs/5.12.19-MANJARO-ARM/allwinner/sun50i-a64-pinephone-1.2.dtb
  linux     = ../../boot/vmlinux-5.12.19-MANJARO-ARM
  bootargs  = loglevel=4 console=tty0 console=ttyS0,115200 earlycon=uart,mmio32,0x01c28000 consoleblank=0 root=PARTUUID=dffd8215-02 rw rootwait quiet bootsplash.bootfile=bootsplash-themes/manjaro/bootsplash
  splash    = ../../usr/share/p-boot/pboot2.argb

no          = 1
  name      = SD card
  atf       = ../../usr/share/p-boot/fw.bin
  dtb       = ../../boot/dtbs/5.12.19-MANJARO-ARM/allwinner/sun50i-a64-pinephone-1.2.dtb
  linux     = ../../boot/vmlinux-5.12.19-MANJARO-ARM
  bootargs  = loglevel=4 console=tty0 console=ttyS0,115200 earlycon=uart,mmio32,0x01c28000 consoleblank=0 root=PARTUUID=42516a04-02 rw rootwait quiet bootsplash.bootfile=bootsplash-themes/manjaro/bootsplash
  splash    = ../../usr/share/p-boot/pboot2.argb

I tried using either the PARTUUID as the root parameter as shown above or also /dev/mmcblk0p2, but none of them worked.

What am I doing wrong? Or am I trying something impossible?