Commit 7505599e authored by 残页's avatar 残页 Committed by John Wu

Skip invalid slot_suffix argument

Many Amlogic devices (e.g. FireTV 2nd gen Cube, Vero 4k+, MI Smart Speaker, etc.) are A-only with androidboot.slot_suffix=normal argument. I think "normal" actually means A-only in this case so just ignore it.

Fix topjohnwu#5806
parent 575c4174
......@@ -163,6 +163,11 @@ void setup_klog() {
void BootConfig::set(const kv_pairs &kv) {
for (const auto &[key, value] : kv) {
if (key == "androidboot.slot_suffix") {
// Many Amlogic devices are A-only but have slot_suffix...
if (value == "normal") {
LOGW("Skip invalid androidboot.slot_suffix=[normal]\n");
continue;
}
strlcpy(slot, value.data(), sizeof(slot));
} else if (key == "androidboot.slot") {
slot[0] = '_';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment