Loading fs_mgr/fs_mgr.cpp +20 −1 Original line number Diff line number Diff line Loading @@ -1588,6 +1588,25 @@ bool fs_mgr_update_verity_state(std::function<fs_mgr_verity_state_callback> call return true; } std::string fs_mgr_get_super_partition_name(int /* slot */) { std::string fs_mgr_get_super_partition_name(int slot) { // Devices upgrading to dynamic partitions are allowed to specify a super // partition name, assumed to be A/B (non-A/B retrofit is not supported). // For devices launching with dynamic partition support, the partition // name must be "super". std::string super_partition; if (fs_mgr_get_boot_config_from_kernel_cmdline("super_partition", &super_partition)) { std::string suffix; if (slot == 0) { suffix = "_a"; } else if (slot == 1) { suffix = "_b"; } else if (slot == -1) { suffix = fs_mgr_get_slot_suffix(); } if (suffix.empty()) { LFATAL << "Super partition name can only be overridden on A/B devices."; } return super_partition + suffix; } return LP_METADATA_DEFAULT_PARTITION_NAME; } fs_mgr/fs_mgr_priv.h +2 −0 Original line number Diff line number Diff line Loading @@ -39,11 +39,13 @@ #define LINFO LOG(INFO) << FS_MGR_TAG #define LWARNING LOG(WARNING) << FS_MGR_TAG #define LERROR LOG(ERROR) << FS_MGR_TAG #define LFATAL LOG(FATAL) << FS_MGR_TAG // Logs a message with strerror(errno) at the end #define PINFO PLOG(INFO) << FS_MGR_TAG #define PWARNING PLOG(WARNING) << FS_MGR_TAG #define PERROR PLOG(ERROR) << FS_MGR_TAG #define PFATAL PLOG(FATAL) << FS_MGR_TAG #define CRYPTO_TMPFS_OPTIONS "size=512m,mode=0771,uid=1000,gid=1000" Loading Loading
fs_mgr/fs_mgr.cpp +20 −1 Original line number Diff line number Diff line Loading @@ -1588,6 +1588,25 @@ bool fs_mgr_update_verity_state(std::function<fs_mgr_verity_state_callback> call return true; } std::string fs_mgr_get_super_partition_name(int /* slot */) { std::string fs_mgr_get_super_partition_name(int slot) { // Devices upgrading to dynamic partitions are allowed to specify a super // partition name, assumed to be A/B (non-A/B retrofit is not supported). // For devices launching with dynamic partition support, the partition // name must be "super". std::string super_partition; if (fs_mgr_get_boot_config_from_kernel_cmdline("super_partition", &super_partition)) { std::string suffix; if (slot == 0) { suffix = "_a"; } else if (slot == 1) { suffix = "_b"; } else if (slot == -1) { suffix = fs_mgr_get_slot_suffix(); } if (suffix.empty()) { LFATAL << "Super partition name can only be overridden on A/B devices."; } return super_partition + suffix; } return LP_METADATA_DEFAULT_PARTITION_NAME; }
fs_mgr/fs_mgr_priv.h +2 −0 Original line number Diff line number Diff line Loading @@ -39,11 +39,13 @@ #define LINFO LOG(INFO) << FS_MGR_TAG #define LWARNING LOG(WARNING) << FS_MGR_TAG #define LERROR LOG(ERROR) << FS_MGR_TAG #define LFATAL LOG(FATAL) << FS_MGR_TAG // Logs a message with strerror(errno) at the end #define PINFO PLOG(INFO) << FS_MGR_TAG #define PWARNING PLOG(WARNING) << FS_MGR_TAG #define PERROR PLOG(ERROR) << FS_MGR_TAG #define PFATAL PLOG(FATAL) << FS_MGR_TAG #define CRYPTO_TMPFS_OPTIONS "size=512m,mode=0771,uid=1000,gid=1000" Loading