Merge "Replace "sys.fuse_snapshot" with "persist.sys.fuse""

This commit is contained in:
Abhijeet Kaur 2019-12-13 14:03:29 +00:00 committed by Android (Google) Code Review
commit a70feb449e
4 changed files with 6 additions and 6 deletions

View file

@ -34,7 +34,7 @@ struct DIR;
namespace android {
namespace vold {
static const char* kPropFuseSnapshot = "sys.fuse_snapshot";
static const char* kPropFuse = "persist.sys.fuse";
/* SELinux contexts used depending on the block device type */
extern security_context_t sBlkidContext;

View file

@ -374,7 +374,7 @@ int VolumeManager::forgetPartition(const std::string& partGuid, const std::strin
}
int VolumeManager::linkPrimary(userid_t userId) {
if (!GetBoolProperty(android::vold::kPropFuseSnapshot, false)) {
if (!GetBoolProperty(android::vold::kPropFuse, false)) {
std::string source(mPrimary->getPath());
if (mPrimary->isEmulated()) {
source = StringPrintf("%s/%d", source.c_str(), userId);
@ -468,7 +468,7 @@ int VolumeManager::onUserStarted(userid_t userId) {
createEmulatedVolumesForUser(userId);
}
if (!GetBoolProperty(android::vold::kPropFuseSnapshot, false)) {
if (!GetBoolProperty(android::vold::kPropFuse, false)) {
// Note that sometimes the system will spin up processes from Zygote
// before actually starting the user, so we're okay if Zygote
// already created this directory.
@ -563,7 +563,7 @@ static bool childProcess(const char* storageSource, const char* userSource, int
}
int VolumeManager::remountUid(uid_t uid, int32_t mountMode) {
if (GetBoolProperty(android::vold::kPropFuseSnapshot, false)) {
if (GetBoolProperty(android::vold::kPropFuse, false)) {
// TODO(135341433): Implement fuse specific logic.
return 0;
}

View file

@ -133,7 +133,7 @@ status_t EmulatedVolume::doMount() {
dev_t before = GetDevice(mSdcardFsFull);
bool isFuse = base::GetBoolProperty(kPropFuseSnapshot, false);
bool isFuse = base::GetBoolProperty(kPropFuse, false);
// Mount sdcardfs regardless of FUSE, since we need it to bind-mount on top of the
// FUSE volume for various reasons.

View file

@ -223,7 +223,7 @@ status_t PublicVolume::doMount() {
/* sdcardfs will have exited already. The filesystem will still be running */
TEMP_FAILURE_RETRY(waitpid(sdcardFsPid, nullptr, 0));
bool isFuse = base::GetBoolProperty(kPropFuseSnapshot, false);
bool isFuse = base::GetBoolProperty(kPropFuse, false);
if (isFuse) {
// We need to mount FUSE *after* sdcardfs, since the FUSE daemon may depend
// on sdcardfs being up.