Allow init to mount on /bionic in recovery mode

The mount points under /bionic are rootfs in recovery mode. Init should
be able to bind-mount the bootstrap Bionic to the mount points.

Bug: 120266448
Test: adb reboot recovery; phone enters into the recovery mode
Change-Id: I57aed268eac08a5fb3609750bf10cd8d6e97347a
This commit is contained in:
Jiyong Park 2019-01-24 17:57:12 +09:00
parent 9d9333ac86
commit cd6a6a0933

View File

@ -87,8 +87,14 @@ allow init device:dir mounton;
# Mount tmpfs on /apex
allow init apex_mnt_dir:dir mounton;
# Mount Bionic libraries and dynamic linkers
allow init system_lib_file:file mounton;
allow init system_linker_exec:file mounton;
# The mount points under /bionic are rootfs in recovery mode. Init should
# be able to bind-mount the bootstrap Bionic to the mount points.
recovery_only(`
allow init rootfs:file mounton;
')
# Create and remove symlinks in /.
allow init rootfs:lnk_file { create unlink };