Implement SD card autodetection, automount, and GUI/dmenu mounter
- Enable GPIO 38 active-low card detect (cd-gpios) with bias-pull-up on sdhci@7864000 across all MSM8905/MSM8909 device trees and DTBs - Add sxmo_sdcard.sh and 88-bananarchy-sdcard.rules udev rules for automatic mounting at /media/sdcard on insertion and cleanup on removal - Integrate SD card mount, unmount/eject, and navigation into the GUI File Manager (files.so) and built-in dmenu SD Card menu (@menu:sdcard)
This commit is contained in:
1 parent
370f8b085c
commit
32d5d2f2b4
26 files changed
+530
-24
No files matched your search
@@ -35,6 +35,8 @@ permit nopass :wheel as root cmd tee args /sys/module/leds_msm8905_torch/paramet
|
||||
permit nopass :wheel as root cmd /usr/bin/tee args /sys/module/leds_msm8905_torch/parameters/next_reboot_mode
|
||||
permit nopass :wheel as root cmd /usr/bin/sxmo_power.sh
|
||||
permit nopass :wheel as root cmd sxmo_power.sh
|
||||
permit nopass :wheel as root cmd /usr/bin/sxmo_sdcard.sh
|
||||
permit nopass :wheel as root cmd sxmo_sdcard.sh
|
||||
permit nopass :wheel as root cmd /usr/bin/plymouth args quit
|
||||
permit nopass :wheel as root cmd plymouth args quit
|
||||
permit nopass :wheel as root cmd rc-service args hexagonrpcd-adsp-sensorspd stop
|
||||
|
||||
@@ -12,3 +12,8 @@ fi
|
||||
{ echo 3000 > /proc/sys/vm/dirty_expire_centisecs; } 2>/dev/null || true
|
||||
{ echo "1 4 1 4" > /proc/sys/kernel/printk; } 2>/dev/null || true
|
||||
|
||||
# Automount microSD card if present at boot
|
||||
if [ -x /usr/bin/sxmo_sdcard.sh ]; then
|
||||
/usr/bin/sxmo_sdcard.sh automount boot >/dev/null 2>&1 &
|
||||
fi
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
# Automatically mount and unmount removable microSD cards (mmcblk1) at /media/sdcard
|
||||
SUBSYSTEM=="block", KERNEL=="mmcblk1p[1-9]*", ACTION=="add", RUN+="/usr/bin/sxmo_sdcard.sh automount add %k"
|
||||
SUBSYSTEM=="block", KERNEL=="mmcblk1", ATTR{partition}!="1", ENV{ID_FS_USAGE}=="filesystem", ACTION=="add", RUN+="/usr/bin/sxmo_sdcard.sh automount add %k"
|
||||
SUBSYSTEM=="block", KERNEL=="mmcblk1*", ACTION=="remove", RUN+="/usr/bin/sxmo_sdcard.sh automount remove %k"
|
||||
Reference in new issue
Block a user