diff options
author | osm0sis <osm0sis@outlook.com> | 2020-05-12 18:10:48 -0300 |
---|---|---|
committer | osm0sis <osm0sis@outlook.com> | 2020-05-12 18:10:48 -0300 |
commit | 53ce3e40731390dbd9636df39f08d5ff54bd703a (patch) | |
tree | 693973206dc45844411c31f47e0471b12f43f18b | |
parent | b3767d19782c63de16b542fb4738690702ea7d85 (diff) |
Backend: add logical partition block mapper rw support
Thanks LuK1337 & erfanoabdi @ Lineage
-rwxr-xr-x | META-INF/com/google/android/update-binary | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/META-INF/com/google/android/update-binary b/META-INF/com/google/android/update-binary index b30ed1b..b0b62c1 100755 --- a/META-INF/com/google/android/update-binary +++ b/META-INF/com/google/android/update-binary @@ -308,7 +308,7 @@ EOF } do_modules() { test "$(file_getprop anykernel.sh do.modules)" == 1 || return 1; - local modcon moddir modtarget module umask; + local block modcon moddir modtarget module slot umask; if [ "$(file_getprop anykernel.sh do.systemless)" == 1 ]; then cd $AKHOME/modules; ui_print " " "Creating kernel helper Magisk module..."; @@ -331,6 +331,13 @@ do_modules() { else cd $AKHOME/modules; ui_print " " "Pushing modules..."; + if [ -d /dev/block/mapper ]; then + for block in system vendor; do + for slot in "" _a _b; do + $BB blockdev --setrw /dev/block/mapper/$block$slot 2>/dev/null; + done; + done; + fi; if [ ! -d /postinstall/tmp ]; then $BB mount -o rw,remount -t auto /system; $BB mount -o rw,remount -t auto /vendor 2>/dev/null; |