A modern Music Player Daemon based on Rockbox open source high quality audio player
libadwaita audio rust zig deno mpris rockbox mpd

[BugFix] root redirect failed to match the peoper drive when internal drive is missing

HAVE_MULTIVOLUME is a subset of HAVE_MULTIDRIVE
in normal circumstances they are interchangable
but when the internal drive is not found the assumption falls apart

at the moment most of the bootloader are less selective about what drives/volumes
they will mount therefore the volume might not match between what the bootloader
returns for multiboot and what the firmware sees

updating bootloaders will fix this but it should probably be made more robust
at the same time

Change-Id: I93acd4a539894f093211b74b030df3b2c6a0aa11

authored by

William Wilgus and committed by
William Wilgus
f37ebe5e 992455dc

+6
+6
firmware/include/dircache_redirect.h
··· 150 150 /* we need to mount the drive before we can access it */ 151 151 root_mount_path(path, 0); /* root could be different folder don't hide */ 152 152 153 + /*BUGFIX bootloader is less selective about which drives it will mount -- revisit */ 154 + #if defined(HAVE_MULTIDRIVE) && (NUM_VOLUMES_PER_DRIVE == 1) 155 + if (volume_drive(volume) == boot_data.boot_volume 156 + || volume == boot_data.boot_volume) 157 + #else 153 158 if (volume == boot_data.boot_volume) /* boot volume contained in uint8_t payload */ 159 + #endif 154 160 { 155 161 int rtlen = get_redirect_dir(rtpath, sizeof(rtpath), volume, "", ""); 156 162 while (rtlen > 0 && rtpath[--rtlen] == PATH_SEPCH)