Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multirom: Support mounting booted external EXT4/F2FS #12

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AdrianDC
Copy link
Member

@AdrianDC AdrianDC commented Jun 8, 2017

  • When booting from an EXT4 or F2FS MicroSD / USB Drive,
    the external partition itself is not mountable and
    accessible from the Android userspace for media or data

  • External booted partition is mounted early for /system,
    /data and /cache, therefore e2fsck fails to check,
    and vold avoids mounting the 'corrupted' partition

  • Furthermore on CM/LineageOS based ROMs, external drives
    using EXT4 or F2FS are mounted with an sdcard context,
    which fails due to the superblock mounts mismatching
    the early MultiROM mount of the same partition

  • Work around this limitation from vold and external boots
    by flagging such a boot as an external_mount path,
    remove the fstab entry matching the external MicroSD
    or external USB, and finally mount the partition
    to a new 'external_multirom' folder inside the internal
    media storage under /data/media or /data/media/0

  • Stores external mount paths and filesystem globally
    for later use upon Android mounts preparation

Change-Id: Ifab658ac03a481b40b517a978621f25e09f8622b
Signed-off-by: Adrian DC radian.dc@gmail.com

 * When booting from an EXT4 or F2FS MicroSD / USB Drive,
    the external partition itself is not mountable and
    accessible from the Android userspace for media or data

 * External booted partition is mounted early for /system,
    /data and /cache, therefore e2fsck fails to check,
    and vold avoids mounting the 'corrupted' partition

 * Furthermore on CM/LineageOS based ROMs, external drives
    using EXT4 or F2FS are mounted with an sdcard context,
    which fails due to the superblock mounts mismatching
    the early MultiROM mount of the same partition

 * Work around this limitation from vold and external boots
    by flagging such a boot as an external_mount path,
    remove the fstab entry matching the external MicroSD
    or external USB, and finally mount the partition
    to a new 'external_multirom' folder inside the internal
    media storage under /data/media or /data/media/0

 * Stores external mount paths and filesystem globally
    for later use upon Android mounts preparation

Change-Id: Ifab658ac03a481b40b517a978621f25e09f8622b
Signed-off-by: Adrian DC <radian.dc@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant