Merge "Add ro.fuse.bpf.is_running" am: 1edb6550ab
Original change: https://android-review.googlesource.com/c/platform/system/vold/+/2346803 Change-Id: I384c0f605a2cf69430d4d6e1a9cde1358e715ae6 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
commit
f0dec736c2
1 changed files with 6 additions and 4 deletions
10
Utils.cpp
10
Utils.cpp
|
@ -1772,13 +1772,15 @@ std::pair<android::base::unique_fd, std::string> OpenDirInProcfs(std::string_vie
|
||||||
}
|
}
|
||||||
|
|
||||||
bool IsFuseBpfEnabled() {
|
bool IsFuseBpfEnabled() {
|
||||||
std::string bpf_override = android::base::GetProperty("persist.sys.fuse.bpf.override", "");
|
// TODO Once kernel supports flag, trigger off kernel flag unless
|
||||||
if (bpf_override == "true") {
|
// ro.fuse.bpf.enabled is explicitly set to false
|
||||||
|
if (base::GetBoolProperty("ro.fuse.bpf.enabled", false)) {
|
||||||
|
base::SetProperty("ro.fuse.bpf.is_running", "true");
|
||||||
return true;
|
return true;
|
||||||
} else if (bpf_override == "false") {
|
} else {
|
||||||
|
base::SetProperty("ro.fuse.bpf.is_running", "false");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return base::GetBoolProperty("ro.fuse.bpf.enabled", false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace vold
|
} // namespace vold
|
||||||
|
|
Loading…
Reference in a new issue