sepolicy: add rules for vendor_qti_init_shell
Add rules for vendor_qti_init_shell.
Change-Id: Idfd4d2134459448d5a00000d70ea66d730db57f7
diff --git a/qva/vendor/trinket/file.te b/qva/vendor/trinket/file.te
index 4e2b1fd..e253644 100644
--- a/qva/vendor/trinket/file.te
+++ b/qva/vendor/trinket/file.te
@@ -25,4 +25,9 @@
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# Changes from Qualcomm Innovation Center are provided under the following license:
+# Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
+# SPDX-License-Identifier: BSD-3-Clause-Clear
+
type vendor_sysfs_fps_attr, fs_type, sysfs_type;
+type vendor_sysfs_uevent, fs_type, sysfs_type;
diff --git a/qva/vendor/trinket/genfs_contexts b/qva/vendor/trinket/genfs_contexts
index 6d5f6e5..19e9203 100644
--- a/qva/vendor/trinket/genfs_contexts
+++ b/qva/vendor/trinket/genfs_contexts
@@ -26,6 +26,10 @@
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
###################################
+# Changes from Qualcomm Innovation Center are provided under the following license:
+# Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
+# SPDX-License-Identifier: BSD-3-Clause-Clear
+
#pmic sysfs_nodes
genfscon sysfs /devices/platform/soc/1c40000.qcom,spmi/spmi-0/spmi0-00/1c40000.qcom,spmi:qcom,pm6125@0:qcom,pm6125_rtc/rtc u:object_r:sysfs_rtc:s0
genfscon sysfs /devices/platform/soc/1c40000.qcom,spmi/spmi-0/spmi0-02/1c40000.qcom,spmi:qcom,pmi632@2:qcom,qpnp-smb5/power_supply/battery u:object_r:vendor_sysfs_battery_supply:s0
@@ -89,3 +93,7 @@
genfscon sysfs /devices/platform/soc/5c0c000.qcom,cci/5c0c000.qcom,cci:qcom,camera@0/video4linux/video2/name u:object_r:vendor_sysfs_graphics:s0
genfscon sysfs /devices/platform/soc/5c0c000.qcom,cci/5c0c000.qcom,cci:qcom,camera@1/video4linux/video3/name u:object_r:vendor_sysfs_graphics:s0
genfscon sysfs /devices/platform/soc/5c0c000.qcom,cci/5c0c000.qcom,cci:qcom,camera@2/video4linux/video4/name u:object_r:vendor_sysfs_graphics:s0
+
+#uevent sysfs
+genfscon sysfs /devices/platform/soc/1c40000.qcom,spmi/spmi-0/0-02/1c40000.qcom,spmi:qcom,pmi632@2:qcom,qpnp-smb5/power_supply/battery/uevent u:object_r:vendor_sysfs_uevent:s0
+genfscon sysfs /devices/platform/soc/1c40000.qcom,spmi/spmi-0/0-02/1c40000.qcom,spmi:qcom,pmi632@2:qpnp,qg/power_supply/bms/uevent u:object_r:vendor_sysfs_uevent:s0
diff --git a/qva/vendor/trinket/init_shell.te b/qva/vendor/trinket/init_shell.te
new file mode 100644
index 0000000..5d9dd87
--- /dev/null
+++ b/qva/vendor/trinket/init_shell.te
@@ -0,0 +1,5 @@
+# Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
+# SPDX-License-Identifier: BSD-3-Clause-Clear
+
+#init_shell
+allow vendor_qti_init_shell vendor_sysfs_uevent:file { setattr };