diff options
author | Jooyung Han <jooyung@google.com> | 2020-06-09 13:44:17 +0900 |
---|---|---|
committer | Jooyung Han <jooyung@google.com> | 2020-06-11 15:10:40 +0900 |
commit | 4f23d5a236e08ed2d9413cf2681f8ed967d01deb (patch) | |
tree | 7bfcca78b214cafaf6d024269d07d0cc4a49831b /init/service_utils.h | |
parent | 3447cdc741214db36f47dd1138b12215a070efa6 (diff) |
init: start ueventd in the default mount namespace
Init starts ueventd in the default mount namespace to support loading
firmware from APEXes.
Bug: 155023652
Test: devices boots
adb$ nsenter -t (pid of ueventd) -m ls /apex
=> shows all APEXes
Change-Id: Ibb8b33a07eb014752275e3bca4541b8b694dc64b
Diffstat (limited to 'init/service_utils.h')
-rw-r--r-- | init/service_utils.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/init/service_utils.h b/init/service_utils.h index 3f1071e5b..e74f8c17e 100644 --- a/init/service_utils.h +++ b/init/service_utils.h @@ -19,12 +19,14 @@ #include <sys/resource.h> #include <sys/types.h> +#include <optional> #include <string> #include <vector> #include <android-base/unique_fd.h> #include <cutils/iosched_policy.h> +#include "mount_namespace.h" #include "result.h" namespace android { @@ -66,7 +68,8 @@ struct NamespaceInfo { // Pair of namespace type, path to name. std::vector<std::pair<int, std::string>> namespaces_to_enter; }; -Result<void> EnterNamespaces(const NamespaceInfo& info, const std::string& name, bool pre_apexd); +Result<void> EnterNamespaces(const NamespaceInfo& info, const std::string& name, + std::optional<MountNamespace> override_mount_namespace); struct ProcessAttributes { std::string console; |