fs_mgr reads default fstab via ro.hardware property before Android 8.0.
However, Android 8.0 changed it to use ro.boot.hardware. This is an
incompatible change which is bad.
Android-x86 doesn't set ro.boot.hardware anymore. Let's check ro.*
properties as before.
bool fs_mgr_get_boot_config(const std::string& key, std::string* out_val) {
FS_MGR_CHECK(out_val != nullptr);
- // first check if we have "ro.boot" property already
+ // first check if we have "ro.*" property already
+ *out_val = android::base::GetProperty("ro." + key, "");
+ if (!out_val->empty()) {
+ return true;
+ }
+
+ // second check if we have "ro.boot.*" property
*out_val = android::base::GetProperty("ro.boot." + key, "");
if (!out_val->empty()) {
return true;