summaryrefslogtreecommitdiffstats
path: root/firmware/target/hosted/ibasso/vold-ibasso.c
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2021-04-11 09:10:55 -0400
committerSolomon Peachy <pizza@shaftnet.org>2021-04-12 18:19:06 +0000
commitb6fce99046a3677f27373f8c701e6f200e290236 (patch)
tree9ea27b619af5962e415a52ceffaffc35aabd3c47 /firmware/target/hosted/ibasso/vold-ibasso.c
parente4345f2db8771fb773e07daf1a9f7bfac961c6bd (diff)
downloadrockbox-b6fce99046a3677f27373f8c701e6f200e290236.tar.gz
rockbox-b6fce99046a3677f27373f8c701e6f200e290236.zip
ibasso: Implement proper PIVOT_ROOT filesystem access
Including direct use of the external SD card mount Known issue: If SD card is inserted at startup, it must be ejected and reinserted to be registered. Change-Id: I5f420160bda32135cbb088c1e8b04b6e3a73018e
Diffstat (limited to 'firmware/target/hosted/ibasso/vold-ibasso.c')
-rw-r--r--firmware/target/hosted/ibasso/vold-ibasso.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/firmware/target/hosted/ibasso/vold-ibasso.c b/firmware/target/hosted/ibasso/vold-ibasso.c
index c92b86d364..f56bd683d3 100644
--- a/firmware/target/hosted/ibasso/vold-ibasso.c
+++ b/firmware/target/hosted/ibasso/vold-ibasso.c
@@ -45,7 +45,6 @@
static const char VOLD_MONITOR_SOCKET_NAME[] = "UNIX_domain";
static int _vold_monitor_socket_fd = -1;
-
static void vold_monitor_open_socket(void)
{
TRACE;
@@ -82,6 +81,8 @@ static void vold_monitor_open_socket(void)
}
}
+/* Track state of external SD */
+bool extsd_present = false;
/*
bionic does not have pthread_cancel.
@@ -161,10 +162,12 @@ static void* vold_monitor_run(void* nothing)
else if(strcmp(msg, "Volume sdcard /mnt/external_sd state changed from 4 (Mounted) to 5 (Unmounting)") == 0)
{
/* We are loosing the external sdcard, inform Rockbox. */
+ extsd_present = false;
}
else if(strcmp(msg, "Volume sdcard /mnt/external_sd state changed from 3 (Checking) to 4 (Mounted)") == 0)
{
/* The external sdcard is back, inform Rockbox. */
+ extsd_present = true;
}
}
}