diff options
author | Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> | 2019-03-08 23:16:58 +0100 |
---|---|---|
committer | Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> | 2019-03-09 00:27:36 +0100 |
commit | 2aa6c54b8369d6c28f7fe0bb3b496dbbbe78f8e0 (patch) | |
tree | f11c5e798ac4fd46d4a0edb3d4c23a111f6f84b4 /libre/uboot4extlinux-am335x/uboot4extlinux-am335x.install | |
parent | f35b39d0db1287cc76471ccd6076a30487f0c6a5 (diff) | |
download | abslibre-2aa6c54b8369d6c28f7fe0bb3b496dbbbe78f8e0.tar.gz abslibre-2aa6c54b8369d6c28f7fe0bb3b496dbbbe78f8e0.tar.bz2 abslibre-2aa6c54b8369d6c28f7fe0bb3b496dbbbe78f8e0.zip |
libre: uboot4extlinux-am335x: fix filesystem corruption
Before that u-boot.img was to be located at 384k on the microSD,
as CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR defaults to 0x300.
CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR states:
Address on the MMC to load U-Boot from, when the MMC is being used
in raw mode. Units: MMC sectors (1 sector = 512 bytes).
However since once built, u-boot.img size was 692k, it went over
the 1MB empty space that is usually created when parititoning
block devices, effectively corrupting the first partition.
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
Diffstat (limited to 'libre/uboot4extlinux-am335x/uboot4extlinux-am335x.install')
-rw-r--r-- | libre/uboot4extlinux-am335x/uboot4extlinux-am335x.install | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libre/uboot4extlinux-am335x/uboot4extlinux-am335x.install b/libre/uboot4extlinux-am335x/uboot4extlinux-am335x.install index 53ab65fba..d4f12e789 100644 --- a/libre/uboot4extlinux-am335x/uboot4extlinux-am335x.install +++ b/libre/uboot4extlinux-am335x/uboot4extlinux-am335x.install @@ -1,6 +1,6 @@ flash_instructions() { echo "# dd if=/boot/u-boot/images/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc bs=128k" - echo "# dd if=/boot/u-boot/images/u-boot.img of=/dev/mmcblk0 count=2 seek=1 conv=notrunc bs=384k" + echo "# dd if=/boot/u-boot/images/u-boot.img of=/dev/mmcblk0 count=6 seek=2 conv=notrunc bs=128k" } extlinux_warning() { @@ -17,6 +17,7 @@ flash_uboot() { if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then dd if=/boot/u-boot/images/MLO of=$root bs=128k seek=1 count=1 conv=notrunc dd if=/boot/u-boot/images/u-boot.img of=$root bs=384k seek=1 count=2 conv=notrunc + dd if=/boot/u-boot/images/u-boot.img of=$root bs=128k seek=2 count=6 conv=notrunc else echo "You can do this later by running:" flash_instructions |