From ab78d95fb89859d23fa7302d608321986309d9d4 Mon Sep 17 00:00:00 2001 From: Megha Patil Date: Thu, 18 Jan 2024 07:09:17 +0000 Subject: [PATCH] Add System Property to Specify NTN Demo Mode Enabled "telephony.ril.ntn_demo_mode" Property is added which specifies RIL about NTN Demo Mode. BUG: b/321178074 Test: Set the property in the service. Change-Id: I8baca9ceaf364b579293679cabe26c33e0a4ec1e --- radio/radio.te | 1 + radio/rild.te | 1 + system_ext/private/pixelntnservice_app.te | 1 + system_ext/private/property_contexts | 1 + system_ext/public/property.te | 1 + 5 files changed, 5 insertions(+) diff --git a/radio/radio.te b/radio/radio.te index 49b2248..721e018 100644 --- a/radio/radio.te +++ b/radio/radio.te @@ -1,5 +1,6 @@ set_prop(radio, telephony_ril_prop) set_prop(radio, telephony_modemtype_prop) +get_prop(radio, telephony_ntn_demo_mode_prop) allow radio radio_vendor_data_file:dir rw_dir_perms; allow radio radio_vendor_data_file:file create_file_perms; diff --git a/radio/rild.te b/radio/rild.te index c8a826f..d2c526d 100644 --- a/radio/rild.te +++ b/radio/rild.te @@ -8,6 +8,7 @@ get_prop(rild, system_boot_reason_prop) set_prop(rild, telephony_ril_prop) set_prop(rild, telephony_modemtype_prop) +get_prop(rild, telephony_ntn_demo_mode_prop) allow rild proc_net:file rw_file_perms; allow rild radio_vendor_data_file:dir create_dir_perms; diff --git a/system_ext/private/pixelntnservice_app.te b/system_ext/private/pixelntnservice_app.te index 194d6c3..d3d7bb7 100644 --- a/system_ext/private/pixelntnservice_app.te +++ b/system_ext/private/pixelntnservice_app.te @@ -5,3 +5,4 @@ allow pixelntnservice_app app_api_service:service_manager find; allow pixelntnservice_app radio_service:service_manager find; set_prop(pixelntnservice_app, telephony_modem_prop) get_prop(pixelntnservice_app, telephony_modemtype_prop) +set_prop(pixelntnservice_app, telephony_ntn_demo_mode_prop) diff --git a/system_ext/private/property_contexts b/system_ext/private/property_contexts index b88ac5a..56360e3 100644 --- a/system_ext/private/property_contexts +++ b/system_ext/private/property_contexts @@ -2,3 +2,4 @@ telephony.TnNtn.image_switch u:object_r:telephony_modem_prop:s0 exact enum ntn tn telephony.ril.modem_bin_status u:object_r:telephony_modemtype_prop:s0 exact uint telephony.ril.silent_reset u:object_r:telephony_ril_prop:s0 exact bool +telephony.ril.ntn_demo_mode u:object_r:telephony_ntn_demo_mode_prop:s0 exact bool diff --git a/system_ext/public/property.te b/system_ext/public/property.te index 8e5eb71..e492369 100644 --- a/system_ext/public/property.te +++ b/system_ext/public/property.te @@ -2,6 +2,7 @@ system_public_prop(telephony_ril_prop) system_restricted_prop(telephony_modem_prop) system_public_prop(telephony_modemtype_prop) +system_restricted_prop(telephony_ntn_demo_mode_prop) userdebug_or_eng(` set_prop(shell, telephony_ril_prop)