diff options
author | James Christopher Adduono <jc@adduono.com> | 2016-05-25 01:23:03 +0200 |
---|---|---|
committer | Dees Troy <dees_troy@teamw.in> | 2017-01-18 20:01:29 +0100 |
commit | 9eb27698410a3a2852df166bdb1bb1f71e95ab5e (patch) | |
tree | e6d2cb605a1ac2e1a03ad34a6fe0c7038f0543a7 /flashutils | |
parent | gui: Actions: Toggle backlight on power key (diff) | |
download | android_bootable_recovery-9eb27698410a3a2852df166bdb1bb1f71e95ab5e.tar android_bootable_recovery-9eb27698410a3a2852df166bdb1bb1f71e95ab5e.tar.gz android_bootable_recovery-9eb27698410a3a2852df166bdb1bb1f71e95ab5e.tar.bz2 android_bootable_recovery-9eb27698410a3a2852df166bdb1bb1f71e95ab5e.tar.lz android_bootable_recovery-9eb27698410a3a2852df166bdb1bb1f71e95ab5e.tar.xz android_bootable_recovery-9eb27698410a3a2852df166bdb1bb1f71e95ab5e.tar.zst android_bootable_recovery-9eb27698410a3a2852df166bdb1bb1f71e95ab5e.zip |
Diffstat (limited to 'flashutils')
-rw-r--r-- | flashutils/flashutils.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/flashutils/flashutils.c b/flashutils/flashutils.c index 5a5e0094f..640193969 100644 --- a/flashutils/flashutils.c +++ b/flashutils/flashutils.c @@ -22,10 +22,12 @@ int device_flash_type() if (the_flash_type == UNKNOWN) { if (access(BOARD_BML_BOOT, F_OK) == 0) { the_flash_type = BML; - } else if (access("/proc/emmc", F_OK) == 0) { - the_flash_type = MMC; } else if (access("/proc/mtd", F_OK) == 0) { the_flash_type = MTD; + } else if (access("/proc/emmc", F_OK) == 0 || + access("/dev/block/mmcblk0", F_OK) == 0 || + access("/dev/block/sda", F_OK) == 0) { + the_flash_type = MMC; } else { the_flash_type = UNSUPPORTED; } |