Add APIs for pushing package info to vold.
Bug: 111890351
Test: n/a
Change-Id: I3194a88a9ce612a2e4f2c7ea9e3392e0f8020fc1
diff --git a/VoldNativeService.cpp b/VoldNativeService.cpp
index 81523c6..6e3317b 100644
--- a/VoldNativeService.cpp
+++ b/VoldNativeService.cpp
@@ -247,6 +247,7 @@
return translate(VolumeManager::Instance()->shutdown());
}
+// TODO: sanity-check these string arguments
binder::Status VoldNativeService::onUserAdded(int32_t userId, int32_t userSerial) {
ENFORCE_UID(AID_SYSTEM);
ACQUIRE_LOCK;
@@ -275,6 +276,24 @@
return translate(VolumeManager::Instance()->onUserStopped(userId));
}
+// TODO: sanity-check these string arguments
+binder::Status VoldNativeService::addAppIds(const std::vector<std::string>& packageNames,
+ const std::vector<int32_t>& appIds) {
+ ENFORCE_UID(AID_SYSTEM);
+ ACQUIRE_LOCK;
+
+ return translate(VolumeManager::Instance()->addAppIds(packageNames, appIds));
+}
+
+// TODO: sanity-check these string arguments
+binder::Status VoldNativeService::addSandboxIds(const std::vector<int32_t>& appIds,
+ const std::vector<std::string>& sandboxIds) {
+ ENFORCE_UID(AID_SYSTEM);
+ ACQUIRE_LOCK;
+
+ return translate(VolumeManager::Instance()->addSandboxIds(appIds, sandboxIds));
+}
+
binder::Status VoldNativeService::onSecureKeyguardStateChanged(bool isShowing) {
ENFORCE_UID(AID_SYSTEM);
ACQUIRE_LOCK;