From c7766073eca48e86baf1bd99f98a2ca956b9a081 Mon Sep 17 00:00:00 2001 From: Kamil Trzcinski Date: Sat, 3 Sep 2016 22:55:14 +0200 Subject: [PATCH] Add disclaimer about fastboot --- tulip-chiphd/vendorsetup.sh | 15 +++++++++------ tulip-common/sunxi-nand-part/nand-part.c | 6 ++++++ 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/tulip-chiphd/vendorsetup.sh b/tulip-chiphd/vendorsetup.sh index 97b6f92..566941a 100755 --- a/tulip-chiphd/vendorsetup.sh +++ b/tulip-chiphd/vendorsetup.sh @@ -114,12 +114,15 @@ $(((part_position+boot_size)*mbs+system_size/512)),$((cache_size*mbs)),L $(((part_position+boot_size)*mbs+system_size/512)),$((data_size*mbs)),L EOF - echo "Updating fastboot table..." - sunxi-nand-part -f a64 "$out" $(((part_position-20)*mbs)) \ - "boot $((boot_size*mbs)) 32768" \ - "system $((system_size/512)) 32768" \ - "cache $((cache_size*mbs)) 32768" \ - "data 0 33024" + # TODO: this is broken, because https://github.com/longsleep/u-boot-pine64 + # doesn't execute sunxi_partition_init + # + # echo "Updating fastboot table..." + # sunxi-nand-part -f a64 "$out" $(((part_position-20)*mbs)) \ + # "boot $((boot_size*mbs)) 32768" \ + # "system $((system_size/512)) 32768" \ + # "cache $((cache_size*mbs)) 32768" \ + # "data 0 33024" size=$(stat -c%s "$out") diff --git a/tulip-common/sunxi-nand-part/nand-part.c b/tulip-common/sunxi-nand-part/nand-part.c index ecfbe82..b4285dd 100644 --- a/tulip-common/sunxi-nand-part/nand-part.c +++ b/tulip-common/sunxi-nand-part/nand-part.c @@ -277,6 +277,12 @@ int nand_part (int argc, char **argv, const char *cmd, int fd, int force) printf("\nverifying new partition tables:\n"); } + if(!force && argc == 0) { + // checkmbrs were before + close(fd); + return 0; + } + if(checkmbrs(fd)) { close(fd); return 0;