From: Jan Altensen Date: Mon, 10 Aug 2020 22:34:51 +0000 (+0200) Subject: differenciate between one action and one vision X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;ds=sidebyside;p=GitHub%2Fmoto-9609%2Ftwrp_device_motorola_troika.git differenciate between one action and one vision Change-Id: I55b16a8efa4e5dd338defee8815fe33cc2d56305 --- diff --git a/init/init_troika.cpp b/init/init_troika.cpp index 6cbeaf2..242a215 100644 --- a/init/init_troika.cpp +++ b/init/init_troika.cpp @@ -40,27 +40,25 @@ namespace android { namespace init { void vendor_load_properties() { -// std::string boot_device = android::base::GetProperty("ro.boot.device", ""); + std::string boot_device = android::base::GetProperty("ro.boot.device", ""); -// switch (boot_device) { -// case troika: + if (!boot_device.compare("troika")) { /* Moto One Action */ property_set("ro.product.model", "Motorola_One_Action"); property_set("ro.build.product", "one_action"); property_set("ro.product.device", "one_action"); property_set("ro.vendor.product.device", "one_action"); -// break; -// case kane: -// /* Moto One Vision */ -// property_set("ro.product.model", "Motorola_One_Vision"); -// property_set("ro.build.product", "one_vision"); -// property_set("ro.product.device", "one_vision"); -// property_set("ro.vendor.product.device", "one_vision"); -// break; -// default: -// LOG(ERROR) << __func__ << ": unexcepted boot device!"; + } else if (!boot_device.compare("kane")) { + /* Moto One Vision */ + property_set("ro.product.model", "Motorola_One_Vision"); + property_set("ro.build.product", "one_vision"); + property_set("ro.product.device", "one_vision"); + property_set("ro.vendor.product.device", "one_vision"); + } else { + LOG(ERROR) << __func__ << ": unexcepted boot device!"; } + } } // namespace init -//} // namespace android \ No newline at end of file +} // namespace android