I have a custom hardware based on SaberLite. I have following hardware on the board
SD Card on SD3 <-- Device 0 in U-Boot
eMMC on SD4 <-- Device 1 in U-Boot
Now ofcourse I always want to boot from eMMC which is on SD4. My kernel + root filesystem reside on eMMC. I can fix Device 1 in U-Boot and I can load my kernel always from eMMC but the problem comes when accessing root filesystem. My boot arguments are
With this root device where I do not have any SD Card inserted (at boot time), I can get the good device pointing to rootfs. But when booting with SD Card inserted, /dev/mmcblk0p1 points to the SD Card first partition and /dev/mmcblk1p1 points to eMMC first partition, so that is not a good rootfs for the system hence the system is unable to boot when booted with SD Card inserted. My device users can not change the boot parameters, neither I can make sure my users does not boot the system with SD Card inserted and also that is not a good solution.
I want to fix the device node for the eMMC at the kernel boot time. Anyone can suggest how can I do it or is there any other solution to this problem