summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJeff Sharkey <jsharkey@android.com>2012-09-24 18:34:07 -0700
committerJeff Sharkey <jsharkey@android.com>2012-09-25 17:34:48 -0700
commit4fbbda4cecb078bd3867f416b02cc75f5455284f (patch)
treee4d988ec4be9e86e7fa5a2cfb1e20ecb1342ce72 /include
parent5e21bf934b2a71b595deb9856a2044eea4dbce86 (diff)
downloadframeworks_base-4fbbda4cecb078bd3867f416b02cc75f5455284f.zip
frameworks_base-4fbbda4cecb078bd3867f416b02cc75f5455284f.tar.gz
frameworks_base-4fbbda4cecb078bd3867f416b02cc75f5455284f.tar.bz2
Handle multi-user mountObb() requests.
Since emulated external storage paths differ based on execution context, carefully fix up paths for various use-cases: 1. When sending paths to DefaultContainerService, always scope OBB paths as belonging to USER_OWNER. 2. When sending paths to vold, always build emulated storage paths visible to root. 3. Always use the original untouched path when talking with apps. Mount OBB containers using shared app GID, so that an app can read the mount point across users. Handle legacy paths like "/sdcard" by resolving the canonical path before sending to MountService. Move tests to servicestests, and add tests for new path generation logic. Bug: 7212801 Change-Id: I078c52879cd08d9c8a52cc8c83ac7ced1e8035e7
Diffstat (limited to 'include')
-rw-r--r--include/storage/IMountService.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/storage/IMountService.h b/include/storage/IMountService.h
index 43df7f0..c3d34d8 100644
--- a/include/storage/IMountService.h
+++ b/include/storage/IMountService.h
@@ -21,6 +21,8 @@
#include <storage/IMountShutdownObserver.h>
#include <storage/IObbActionListener.h>
+#include <utils/String8.h>
+
#include <binder/IInterface.h>
#include <binder/Parcel.h>
@@ -60,8 +62,9 @@ public:
String16*& containers) = 0;
virtual void shutdown(const sp<IMountShutdownObserver>& observer) = 0;
virtual void finishMediaUpdate() = 0;
- virtual void mountObb(const String16& filename, const String16& key,
- const sp<IObbActionListener>& token, const int32_t nonce) = 0;
+ virtual void mountObb(const String16& rawPath, const String16& canonicalPath,
+ const String16& key, const sp<IObbActionListener>& token,
+ const int32_t nonce) = 0;
virtual void unmountObb(const String16& filename, const bool force,
const sp<IObbActionListener>& token, const int32_t nonce) = 0;
virtual bool isObbMounted(const String16& filename) = 0;