diff --git a/BoardConfig.mk b/BoardConfig.mk
index 910b694..a0bda48 100644
--- a/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -120,7 +120,7 @@ TARGET_RECOVERY_UI_MARGIN_STATUSBAR := 50
TARGET_USERIMAGES_USE_EXT4 := true
# RIL
-TARGET_USES_OLD_MNC_FORMAT := true
+ENABLE_VENDOR_RIL_SERVICE := true
# Security patch level
VENDOR_SECURITY_PATCH := 2019-09-01
diff --git a/configs/qmi_fw.conf b/configs/qmi_fw.conf
new file mode 100644
index 0000000..9246aa8
--- /dev/null
+++ b/configs/qmi_fw.conf
@@ -0,0 +1,3 @@
+# Debug messages with priority >= ANDROID_LOG_WARN
+QMI_CCI_DEBUG_LEVEL=5
+QMI_CSI_DEBUG_LEVEL=5
diff --git a/configs/system_ext-privapp-permissions-qti.xml b/configs/system_ext-privapp-permissions-qti.xml
index 0525641..78e7d68 100644
--- a/configs/system_ext-privapp-permissions-qti.xml
+++ b/configs/system_ext-privapp-permissions-qti.xml
@@ -28,13 +28,21 @@ It allows additional grants on top of privapp-permissions-platform.xml
-->
+
+
+
+
+
-
+
-
-
-
+
+
+
+
+
+
diff --git a/device.mk b/device.mk
index 68fcdca..ce0bd9e 100644
--- a/device.mk
+++ b/device.mk
@@ -161,8 +161,7 @@ PRODUCT_PACKAGES += IFAAService
PRODUCT_PACKAGES += \
ims_ext_common.xml \
ims-ext-common \
- libgui_shim \
- libui_shim:64
+ libgui_shim
# IRQ
PRODUCT_COPY_FILES += $(LOCAL_PATH)/configs/msm_irqbalance.conf:$(TARGET_COPY_OUT_VENDOR)/etc/msm_irqbalance.conf
@@ -312,10 +311,11 @@ PRODUCT_COPY_FILES += \
# RIL
PRODUCT_PACKAGES += \
- android.hardware.radio.config@1.0.vendor \
- android.hardware.radio@1.0.vendor \
- android.hardware.secure_element@1.0.vendor \
- libril-wrapper \
+ android.hardware.radio.config@1.2.vendor \
+ android.hardware.radio.deprecated@1.0.vendor \
+ android.hardware.radio@1.5.vendor \
+ android.hardware.secure_element@1.2.vendor \
+ libavservices_minijail.vendor \
librmnetctl
# Seccomp policy
@@ -339,6 +339,8 @@ PRODUCT_SOONG_NAMESPACES += \
# Telephony
PRODUCT_BOOT_JARS += telephony-ext
+PRODUCT_COPY_FILES += $(LOCAL_PATH)/configs/qmi_fw.conf:$(TARGET_COPY_OUT_VENDOR)/etc/qmi_fw.conf
+
PRODUCT_PACKAGES += \
qti_telephony_hidl_wrapper.xml \
qti_telephony_utils.xml \
@@ -353,10 +355,6 @@ PRODUCT_PACKAGES += android.hardware.usb@1.3-service.dual_role_usb
PRODUCT_PACKAGES += vendor.qti.hardware.vibrator.service
# VNDK
-PRODUCT_COPY_FILES += \
- prebuilts/vndk/v32/arm64/arch-arm64-armv8-a/shared/vndk-sp/libhidlbase.so:$(TARGET_COPY_OUT_SYSTEM_EXT)/lib64/libhidlbase-v32.so \
- prebuilts/vndk/v32/arm64/arch-arm64-armv8-a/shared/vndk-sp/libhidlbase.so:$(TARGET_COPY_OUT_VENDOR)/lib64/libhidlbase-v32.so
-
PRODUCT_PACKAGES += \
libdng_sdk.vendor_32 \
libstdc++_vendor
diff --git a/manifest.xml b/manifest.xml
index e846932..4cbac47 100644
--- a/manifest.xml
+++ b/manifest.xml
@@ -79,19 +79,15 @@
android.hardware.radio
hwbinder
- @1.1::IRadio/slot1
- @1.1::IRadio/slot2
+ @1.2::ISap/slot1
+ @1.2::ISap/slot2
+ @1.4::IRadio/slot1
+ @1.4::IRadio/slot2
android.hardware.radio.config
hwbinder
- @1.0::IRadioConfig/default
-
-
- android.hardware.radio.deprecated
- hwbinder
- @1.0::IOemHook/slot1
- @1.0::IOemHook/slot2
+ @1.1::IRadioConfig/default
android.hardware.sensors
@@ -163,7 +159,7 @@
vendor.qti.data.factory
hwbinder
- @2.0::IFactory/default
+ @2.3::IFactory/default
vendor.qti.hardware.alarm
@@ -185,6 +181,18 @@
hwbinder
@1.0::ILinkLatency/default
+
+ vendor.qti.hardware.data.connection
+ hwbinder
+ @1.1::IDataConnection/slot1
+ @1.1::IDataConnection/slot2
+
+
+ vendor.qti.hardware.data.iwlan
+ hwbinder
+ @1.0::IIWlan/slot1
+ @1.0::IIWlan/slot2
+
vendor.qti.hardware.radio.am
hwbinder
@@ -199,13 +207,14 @@
vendor.qti.hardware.radio.ims
hwbinder
- @1.0::IImsRadio/imsradio0
- @1.0::IImsRadio/imsradio1
+ @1.6::IImsRadio/imsradio0
+ @1.6::IImsRadio/imsradio1
vendor.qti.hardware.radio.lpa
hwbinder
- @1.0::IUimLpa/UimLpa0
+ @1.1::IUimLpa/UimLpa0
+ @1.1::IUimLpa/UimLpa1
vendor.qti.hardware.radio.qcrilhook
@@ -216,14 +225,14 @@
vendor.qti.hardware.radio.qtiradio
hwbinder
- @1.0::IQtiRadio/slot1
- @1.0::IQtiRadio/slot2
+ @2.4::IQtiRadio/slot1
+ @2.4::IQtiRadio/slot2
vendor.qti.hardware.radio.uim
hwbinder
- @1.1::IUim/Uim0
- @1.1::IUim/Uim1
+ @1.2::IUim/Uim0
+ @1.2::IUim/Uim1
vendor.qti.hardware.radio.uim_remote_client
@@ -247,15 +256,10 @@
hwbinder
@1.0::ITuiComm/default
-
- vendor.qti.ims.callinfo
- hwbinder
- @1.0::IService/default
-
vendor.qti.imsrtpservice
hwbinder
- @1.0::IRTPService/imsrtpservice
+ @3.0::IRTPService/imsrtpservice
vendor.xiaomi.hardware.mlipay
diff --git a/overlay/frameworks/base/core/res/res/values/config.xml b/overlay/frameworks/base/core/res/res/values/config.xml
index 8b518f1..a960b66 100644
--- a/overlay/frameworks/base/core/res/res/values/config.xml
+++ b/overlay/frameworks/base/core/res/res/values/config.xml
@@ -165,6 +165,12 @@
true
true
+
+ vendor.qti.iwlan
+
+ vendor.qti.iwlan
+
+ vendor.qti.iwlan
false
diff --git a/ril-wrapper/Android.mk b/ril-wrapper/Android.mk
deleted file mode 100644
index 5eb05a8..0000000
--- a/ril-wrapper/Android.mk
+++ /dev/null
@@ -1,10 +0,0 @@
-LOCAL_PATH := $(call my-dir)
-
-include $(CLEAR_VARS)
-LOCAL_MODULE := libril-wrapper
-LOCAL_MULTILIB := 64
-LOCAL_VENDOR_MODULE := true
-LOCAL_SRC_FILES := ril-wrapper.c
-LOCAL_SHARED_LIBRARIES := android.hardware.radio.config@1.0 libdl liblog libril libcutils
-LOCAL_CFLAGS := -Wall -Werror
-include $(BUILD_SHARED_LIBRARY)
diff --git a/ril-wrapper/ril-wrapper.c b/ril-wrapper/ril-wrapper.c
deleted file mode 100644
index d1aacff..0000000
--- a/ril-wrapper/ril-wrapper.c
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * Copyright (C) 2018 The LineageOS Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "ril-wrapper"
-
-/*
- * We're using RIL_Env, which is only exposed if this is defined.
- */
-#define RIL_SHLIB
-
-#include
-#include
-#include
-
-#define RIL_LIB_NAME "libril-qc-qmi-1.so"
-#define RADIO_TECH_DC_HSPAP 20
-
-/*
- * These structs are only avaiable in ril_internal.h
- * which is not exposed.
- */
-typedef struct
-{
- int requestNumber;
- void (*dispatchFunction)(void *p, void *pRI);
- int (*responseFunction)(void *p, void *response, size_t responselen);
-} CommandInfo;
-
-typedef struct RequestInfo
-{
- int32_t token;
- CommandInfo *pCI;
- struct RequestInfo *p_next;
- char cancelled;
- char local;
-} RequestInfo;
-
-static const RIL_RadioFunctions *qmiRilFunctions;
-static const struct RIL_Env *ossRilEnv;
-
-static void onRequestCompleteShim(RIL_Token t, RIL_Errno e, void *response, size_t responselen)
-{
- if (!response)
- {
- ALOGV("%s: response is NULL", __func__);
- goto do_not_handle;
- }
-
- RequestInfo *requestInfo = (RequestInfo *)t;
- if (!requestInfo)
- {
- ALOGE("%s: request info is NULL", __func__);
- goto do_not_handle;
- }
-
- int request = requestInfo->pCI->requestNumber;
- switch (request)
- {
- /*
- * RIL can report a DC-HSPAP rat which is not supported by AOSP,
- * resulting in missing mobile data icon.
- * Remap DC-HSPAP (20) to HSPAP (15) to get a H+ mobile data icon.
- */
- case RIL_REQUEST_DATA_REGISTRATION_STATE:
- if (responselen != sizeof(RIL_DataRegistrationStateResponse))
- {
- ALOGE("%s: invalid response length", __func__);
- goto do_not_handle;
- }
-
- RIL_DataRegistrationStateResponse *dataRegState =
- (RIL_DataRegistrationStateResponse *)response;
-
- if (dataRegState->rat == RADIO_TECH_DC_HSPAP)
- {
- dataRegState->rat = RADIO_TECH_HSPAP;
- ALOGI("%s: remapping DC-HSPAP to HSPAP", __func__);
- }
- break;
- }
-
-do_not_handle:
- ossRilEnv->OnRequestComplete(t, e, response, responselen);
-}
-
-const RIL_RadioFunctions *RIL_Init(const struct RIL_Env *env, int argc, char **argv)
-{
- RIL_RadioFunctions const *(*qmiRilInit)(const struct RIL_Env *env, int argc, char **argv);
- static struct RIL_Env shimmedRilEnv;
- void *qmiRil;
-
- /*
- * Save the RilEnv passed from rild.
- */
- ossRilEnv = env;
-
- /*
- * Copy the RilEnv and shim the OnRequestComplete function.
- */
- shimmedRilEnv = *env;
- shimmedRilEnv.OnRequestComplete = onRequestCompleteShim;
-
- /*
- * Open the qmi RIL.
- */
- qmiRil = dlopen(RIL_LIB_NAME, RTLD_LOCAL);
- if (!qmiRil)
- {
- ALOGE("%s: failed to load %s: %s\n", __func__, RIL_LIB_NAME, dlerror());
- return NULL;
- }
-
- /*
- * Get a reference to the qmi RIL_Init.
- */
- qmiRilInit = dlsym(qmiRil, "RIL_Init");
- if (!qmiRilInit)
- {
- ALOGE("%s: failed to find RIL_Init\n", __func__);
- goto fail_after_dlopen;
- }
-
- /*
- * Init the qmi RIL add pass it the shimmed RilEnv.
- */
- qmiRilFunctions = qmiRilInit(&shimmedRilEnv, argc, argv);
- if (!qmiRilFunctions)
- {
- ALOGE("%s: failed to get functions from RIL_Init\n", __func__);
- goto fail_after_dlopen;
- }
-
- return qmiRilFunctions;
-
-fail_after_dlopen:
- dlclose(qmiRil);
-
- return NULL;
-}
diff --git a/rootdir/etc/init.qcom.rc b/rootdir/etc/init.qcom.rc
index 82b3c9e..7fb5e90 100644
--- a/rootdir/etc/init.qcom.rc
+++ b/rootdir/etc/init.qcom.rc
@@ -135,20 +135,12 @@ on boot
mkdir /dev/socket/qmux_gps 2770 gps gps
mkdir /dev/socket/qmux_radio 2770 radio radio
- # Create NETMGR daemon socket area
- mkdir /dev/socket/netmgr 0750 radio radio
-
# Touchscreen
chmod 0660 /proc/touchpanel/double_tap_enable
chmod 0660 /proc/touchpanel/reversed_keys_enable
chown system system /proc/touchpanel/double_tap_enable
chown system system /proc/touchpanel/reversed_keys_enable
- # Assign TCP buffer thresholds to be ceiling value of technology maximums
- # Increased technology maximums should be reflected here.
- write /proc/sys/net/core/rmem_max 16777216
- write /proc/sys/net/core/wmem_max 8388608
-
# To prevent out of order acknowledgements from making
# connection tracking to treat them as not belonging to
# the connection they belong to.
@@ -184,6 +176,10 @@ on boot
write /sys/class/devfreq/soc\:qcom,memlat-cpu4/polling_interval 10
write /sys/class/devfreq/soc\:qcom,mincpubw/governor "cpufreq"
+ # Start qcrild services
+ start vendor.qcrild
+ start vendor.qcrild2
+
service vendor.atfwd /vendor/bin/ATFWD-daemon
class late_start
user system
@@ -217,12 +213,6 @@ service vendor.custom-post-boot /vendor/bin/init.custom.post_boot.sh
oneshot
task_profiles ServiceCapacityLow
-service vendor.dataqti /vendor/bin/qti
- class main
- user radio
- group radio oem_2901 diag usb net_admin
- task_profiles ServiceCapacityLow
-
service vendor.irsc_util /vendor/bin/irsc_util "/vendor/etc/sec_config"
class core
user root
@@ -241,10 +231,6 @@ service vendor.msm_irqbalance /vendor/bin/msm_irqbalance -f /vendor/etc/msm_irqb
group root
task_profiles ServiceCapacityLow
-service vendor.netmgrd /vendor/bin/netmgrd
- class main
- task_profiles ServiceCapacityLow
-
service vendor.power_off_alarm /vendor/bin/power_off_alarm
class core
group system
@@ -259,14 +245,11 @@ service vendor.qcom-sh /vendor/bin/init.qcom.sh
oneshot
task_profiles ServiceCapacityLow
-service vendor.ril-daemon2 /vendor/bin/hw/rild -c 2
- class main
- socket rild2 stream 660 root radio
- socket rild-debug2 stream 660 radio system
- user radio
- group radio cache inet misc audio sdcard_r sdcard_rw diag log
- capabilities BLOCK_SUSPEND NET_ADMIN NET_RAW
- task_profiles ServiceCapacityLow
+service vendor.qrtr-ns /vendor/bin/qrtr-ns -f
+ class core
+ user vendor_qrtr
+ group vendor_qrtr
+ capabilities NET_BIND_SERVICE
service vendor.rmt_storage /vendor/bin/rmt_storage
class core
diff --git a/sepolicy/vendor/ipacm.te b/sepolicy/vendor/ipacm.te
new file mode 100644
index 0000000..63faf72
--- /dev/null
+++ b/sepolicy/vendor/ipacm.te
@@ -0,0 +1,2 @@
+allow ipacm ipacm_socket:sock_file write;
+allow ipacm ipacm-diag:unix_dgram_socket sendto;
diff --git a/vendor.prop b/vendor.prop
index 72983fe..6fd531f 100644
--- a/vendor.prop
+++ b/vendor.prop
@@ -160,6 +160,9 @@ persist.dbg.wfc_avail_ovr=1
debug.stagefright.omx_default_rank.sw-audio=1
debug.stagefright.omx_default_rank=0
+# Network manager
+persist.vendor.data.iwlan.enable=true
+
# Perf
ro.vendor.extension_library=libqti-perfd-client.so
ro.vendor.qti.am.reschedule_service=true
@@ -169,6 +172,7 @@ persist.radio.multisim.config=dsds
persist.vendor.data.mode=concurrent
persist.vendor.radio.apm_sim_not_pwdn=1
persist.vendor.radio.custom_ecc=1
+persist.vendor.radio.enableadvancedscan=false
persist.vendor.radio.force_on_dc=true
persist.vendor.radio.mt_sms_ack=30
persist.vendor.radio.rat_on=combine
@@ -179,9 +183,11 @@ ro.telephony.default_cdma_sub=0
ro.telephony.default_network=22,22
ro.vendor.use_data_netmgrd=true
telephony.lteOnCdmaDevice=1
-vendor.rild.libpath=/vendor/lib64/libril-wrapper.so
vendor.voice.path.for.pcm.voip=true
+# RCS
+persist.rcs.supported=1
+
# Sensors
ro.vendor.sdk.sensors.gestures=false
ro.vendor.sensors.cfos=false