init: support 2SI devices with skip_initramfs

This commit is contained in:
vvb2060
2024-08-24 02:23:28 +08:00
committed by John Wu
parent 8e82113bce
commit b38fd1ca5f
3 changed files with 12 additions and 9 deletions
+1 -2
View File
@@ -200,8 +200,7 @@ mount_root:
xmount("tmpfs", "/dev", "tmpfs", 0, "mode=755");
mount_list.emplace_back("/dev");
// Use the apex folder to determine whether 2SI (Android 10+)
bool is_two_stage = access("/apex", F_OK) == 0;
bool is_two_stage = access("/system/bin/init", F_OK) == 0;
LOGD("is_two_stage: [%d]\n", is_two_stage);
// For API 28 AVD, it uses legacy SAR setup that requires