Merge "Respect that status property when parsing fstab from device tree"
am: ea043a1d43
Change-Id: Id23c5509001726781778721e7adb5b20a71fd407
This commit is contained in:
commit
faad4c62f8
1 changed files with 9 additions and 0 deletions
|
@ -352,6 +352,15 @@ static std::string read_fstab_from_dt() {
|
|||
std::vector<std::string> fstab_entry;
|
||||
std::string file_name;
|
||||
std::string value;
|
||||
// skip a partition entry if the status property is present and not set to ok
|
||||
file_name = android::base::StringPrintf("%s/%s/status", fstabdir_name.c_str(), dp->d_name);
|
||||
if (read_dt_file(file_name, &value)) {
|
||||
if (value != "okay" && value != "ok") {
|
||||
LINFO << "dt_fstab: Skip disabled entry for partition " << dp->d_name;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
file_name = android::base::StringPrintf("%s/%s/dev", fstabdir_name.c_str(), dp->d_name);
|
||||
if (!read_dt_file(file_name, &value)) {
|
||||
LERROR << "dt_fstab: Failed to find device for partition " << dp->d_name;
|
||||
|
|
Loading…
Reference in a new issue