From 7554a49309fe31e69747c64caa28b4303270481b Mon Sep 17 00:00:00 2001 From: Aidan MacDonald Date: Sat, 5 Mar 2022 09:38:13 +0000 Subject: x1000: bootloader: refactor init_disk Add check_disk() to query the disk insertion status and prompt the user if necessary. Use this in place of init_disk(). Perform an unconditional disk_mount_all() from the main function. Change-Id: I9a8cc42266edf99cd15ece3aee8fa25835df04ae --- bootloader/x1000/boot.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'bootloader/x1000/boot.c') diff --git a/bootloader/x1000/boot.c b/bootloader/x1000/boot.c index f9e04d1223..bb9528ba3c 100644 --- a/bootloader/x1000/boot.c +++ b/bootloader/x1000/boot.c @@ -28,11 +28,9 @@ #include "power.h" #include "boot-x1000.h" -extern int init_disk(void); - void boot_rockbox(void) { - if(init_disk() != 0) + if(check_disk(true) != DISK_PRESENT) return; size_t max_size = 0; -- cgit v1.2.3