msm8974-common: Adapt libinit to Android 11

Change-Id: Ia6b6f753891b639dad4e380bdba6b594faf2a550
This commit is contained in:
Lucchetto 2020-09-16 18:48:36 +02:00 committed by Kevin F. Haggerty
parent 72fb75e332
commit a968e9600c
No known key found for this signature in database
GPG Key ID: 6D95512933112729
2 changed files with 11 additions and 10 deletions

View File

@ -21,5 +21,8 @@ cc_library_static {
include_dirs: [ include_dirs: [
"system/core/base/include", "system/core/base/include",
"system/core/init" "system/core/init"
],
shared_libs: [
"libbase",
] ]
} }

View File

@ -37,8 +37,6 @@
#include "init_msm8974.h" #include "init_msm8974.h"
using android::init::property_set;
// copied from build/tools/releasetools/ota_from_target_files.py // copied from build/tools/releasetools/ota_from_target_files.py
// but with "." at the end and empty entry // but with "." at the end and empty entry
std::vector<std::string> ro_product_props_default_source_order = { std::vector<std::string> ro_product_props_default_source_order = {
@ -66,15 +64,15 @@ void cdma_properties(char const operator_alpha[],
char const rild_lib_variant[]) char const rild_lib_variant[])
{ {
// Dynamic CDMA Properties // Dynamic CDMA Properties
property_set("ro.cdma.home.operator.alpha", operator_alpha); property_override("ro.cdma.home.operator.alpha", operator_alpha);
property_set("ro.cdma.home.operator.numeric", operator_numeric); property_override("ro.cdma.home.operator.numeric", operator_numeric);
property_set("ro.telephony.default_cdma_sub", default_cdma_sub); property_override("ro.telephony.default_cdma_sub", default_cdma_sub);
property_set("ro.telephony.default_network", default_network); property_override("ro.telephony.default_network", default_network);
set_rild_libpath(rild_lib_variant); set_rild_libpath(rild_lib_variant);
// Static CDMA Properties // Static CDMA Properties
property_set("ril.subscription.types", "NV,RUIM"); property_override("ril.subscription.types", "NV,RUIM");
property_set("telephony.lteOnCdmaDevice", "1"); property_override("telephony.lteOnCdmaDevice", "1");
} }
void gsm_properties(const char default_network[], void gsm_properties(const char default_network[],
@ -83,10 +81,10 @@ void gsm_properties(const char default_network[],
set_rild_libpath(rild_lib_variant); set_rild_libpath(rild_lib_variant);
// Dynamic GSM Properties // Dynamic GSM Properties
property_set("ro.telephony.default_network", default_network); property_override("ro.telephony.default_network", default_network);
// Static GSM Properties // Static GSM Properties
property_set("telephony.lteOnGsmDevice", "1"); property_override("telephony.lteOnGsmDevice", "1");
} }
void property_override(char const prop[], char const value[], bool add) void property_override(char const prop[], char const value[], bool add)