Backend: more partition mount fixes
- attempt to mount other partitions whether determined as /system or /system_root - /system_root by that point if mounted will actually be /system_root so no need for further checks - add missing /system_ext entries to custom getprop and cleanup functions
This commit is contained in:
2 files changed
+14
-15
No files matched your search
@@ -144,20 +144,19 @@ mount_all() {
|
||||
fi;
|
||||
;;
|
||||
esac;
|
||||
for mount in /vendor /product /system_ext; do
|
||||
if ! is_mounted $mount && [ -L /system$mount -o -L /system_root$mount ]; then
|
||||
setup_mountpoint $mount;
|
||||
$BB mount -o ro -t auto /dev/block/$byname$mount$slot $mount;
|
||||
fi;
|
||||
done;
|
||||
if is_mounted /system_root; then
|
||||
mount_apex;
|
||||
[ -f /system_root/system/build.prop ] && system=/system;
|
||||
for mount in /vendor /product /system_ext; do
|
||||
if ! is_mounted $mount && [ -L /system_root$system$mount ]; then
|
||||
setup_mountpoint $mount;
|
||||
$BB mount -o ro -t auto /dev/block/$byname$mount$slot $mount;
|
||||
fi;
|
||||
done;
|
||||
if ! is_mounted /persist && [ -e /dev/block/bootdevice/by-name/persist ]; then
|
||||
setup_mountpoint /persist;
|
||||
$BB mount -o ro -t auto /dev/block/bootdevice/by-name/persist;
|
||||
fi;
|
||||
$BB mount -o bind /system_root$system /system;
|
||||
$BB mount -o bind /system_root /system;
|
||||
fi;
|
||||
if ! is_mounted /persist && [ -e /dev/block/bootdevice/by-name/persist ]; then
|
||||
setup_mountpoint /persist;
|
||||
$BB mount -o ro -t auto /dev/block/bootdevice/by-name/persist;
|
||||
fi;
|
||||
}
|
||||
umount_all() {
|
||||
@@ -203,7 +202,7 @@ setup_env() {
|
||||
if [ ! "$(getprop 2>/dev/null)" ]; then
|
||||
getprop() {
|
||||
local propdir propfile propval;
|
||||
for propdir in / /system_root /system /vendor /odm /product; do
|
||||
for propdir in / /system_root /system /vendor /product /system_ext /odm; do
|
||||
for propfile in default.prop build.prop; do
|
||||
if [ "$propval" ]; then
|
||||
break 2;
|
||||
@@ -234,7 +233,7 @@ restore_env() {
|
||||
unset OLD_LD_PATH OLD_LD_PRE OLD_LD_CFG;
|
||||
umount_all;
|
||||
[ -L /etc_link ] && $BB rm -rf /etc/*;
|
||||
(for dir in /apex /system /system_root /etc; do
|
||||
(for dir in /etc /apex /system_root /system /vendor /product /system_ext /persist; do
|
||||
if [ -L "${dir}_link" ]; then
|
||||
rmdir $dir;
|
||||
$BB mv -f ${dir}_link $dir;
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# Dummy file; update-binary is a shell script (DO NOT CHANGE)
|
||||
#
|
||||
#
|
||||
# AK_BASE_VERSION=20210911
|
||||
# AK_BASE_VERSION=20210914
|
||||
Reference in new issue
Block a user