Skip to content

Commit

Permalink
hlte: libinit: Set rild.libpath to variant-specific blob
Browse files Browse the repository at this point in the history
Change-Id: Iad07db7ba4555934db7c3aca082681a3ef71bb8a
  • Loading branch information
haggertk authored and javelinanddart committed Nov 2, 2017
1 parent c00e2e0 commit a8d83d6
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 7 deletions.
23 changes: 18 additions & 5 deletions init/init_hlte.cpp
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -39,24 +39,37 @@

#include "init_msm8974.h"

void set_rild_libpath(char const *variant)
{
std::string libpath("/system/vendor/lib/libsec-ril.");
libpath += variant;
libpath += ".so";

property_override("rild.libpath", libpath.c_str());
}

void cdma_properties(char const *operator_alpha,
char const *operator_numeric,
char const *default_network,
char const *cdma_sub)
char const *cdma_sub,
char const *rild_lib_variant)
{
/* Dynamic CDMA Properties */
property_set("ro.cdma.home.operator.alpha", operator_alpha);
property_set("ro.cdma.home.operator.numeric", operator_numeric);
property_set("ro.telephony.default_network", default_network);
property_set("ro.telephony.default_cdma_sub", cdma_sub);
set_rild_libpath(rild_lib_variant);

/* Static CDMA Properties */
property_set("ril.subscription.types", "NV,RUIM");
property_set("telephony.lteOnCdmaDevice", "1");
}

void gsm_properties()
void gsm_properties(char const *rild_lib_variant)
{
set_rild_libpath(rild_lib_variant);

property_set("ro.telephony.default_network", "9");
property_set("telephony.lteOnGsmDevice", "1");
}
Expand All @@ -83,16 +96,16 @@ void init_target_properties()
property_override("ro.build.description", "hltexx-user 5.0 LRX21V N9005XXSGBQD5 release-keys");
property_override("ro.product.model", "SM-N9005");
property_override("ro.product.device", "hlte");
gsm_properties();
gsm_properties("gsm");
} else if (strstr(bootloader, "N900P")) {
/* hltespr - Sprint */
property_override("ro.build.fingerprint", "samsung/hltespr/hltespr:5.0/LRX21V/N900PVPSEPL1:user/release-keys");
property_override("ro.build.description", "hltespr-user 5.0 LRX21V N900PVPSEPL1 release-keys");
property_override("ro.product.model", "SM-N900P");
property_override("ro.product.device", "hltespr");
cdma_properties("Sprint", "310120", "8", "1");
cdma_properties("Sprint", "310120", "8", "1", "spr");
} else {
gsm_properties();
gsm_properties("gsm");
}

property_get("ro.product.device", device, NULL);
Expand Down
2 changes: 0 additions & 2 deletions system.prop

This file was deleted.

0 comments on commit a8d83d6

Please sign in to comment.