Switch to idmap2

Switch from idmap to idmap2.

This CL is the safety pin for idmap2. If idmap2 causes issues during
dogfooding it is easy go back to idmap by reverting this CL.

Once idmap2 has proven itself during a suitable period of time, the
FEATURE_FLAG_IDMAP2 flag and the obsolete idmap code will be removed.

Also add an .rc file to tell init to launch idmap2d.

Bug: 78815803
Test: atest OverlayDeviceTests OverlayHostTests
Change-Id: I5ca1388ac2f8a9379fed0c257247d351a5c7a3c4
This commit is contained in:
Mårten Kongstad
2018-09-21 09:58:10 +02:00
committed by Todd Kennedy
parent 67d97b4bf3
commit b87b507248
4 changed files with 7 additions and 2 deletions

View File

@@ -181,6 +181,7 @@ cc_binary {
"libutils",
"libziparchive",
],
init_rc: ["idmap2d/idmap2d.rc"],
}
filegroup {

View File

@@ -0,0 +1,4 @@
service idmap2d /system/bin/idmap2d
class main
user system
group system

View File

@@ -58,7 +58,7 @@ import java.util.HashMap;
public final class AssetManager implements AutoCloseable {
private static final String TAG = "AssetManager";
private static final boolean DEBUG_REFS = false;
private static final boolean FEATURE_FLAG_IDMAP2 = false;
private static final boolean FEATURE_FLAG_IDMAP2 = true;
private static final String FRAMEWORK_APK_PATH = "/system/framework/framework-res.apk";

View File

@@ -46,7 +46,7 @@ import java.io.File;
* Note: this class is subclassed in the OMS unit tests, and hence not marked as final.
*/
class IdmapManager {
private static final boolean FEATURE_FLAG_IDMAP2 = false;
private static final boolean FEATURE_FLAG_IDMAP2 = true;
private final Installer mInstaller;
private IIdmap2 mIdmap2Service;