sdm845-common: Add and build trust HAL

Change-Id: I6ffdcd0cae2afb1b1e872152f7997da704ad74dc
This commit is contained in:
Luca Stefani
2019-02-04 19:37:06 +01:00
parent 4ad2b3e4fa
commit 53fecbf169
11 changed files with 255 additions and 6 deletions

View File

@@ -1,12 +1,20 @@
# rootfs
type adsprpcd_file, file_type;
type bt_firmware_file, file_type;
type display_data_file, file_type, data_file_type, core_data_file_type;
type firmware_file, file_type;
type op1_file, file_type;
type op2_file, file_type;
type persist_file, file_type;
# proc
type proc_touchpanel, fs_type, proc_type;
type sysfs_fpc_proximity, sysfs_type, fs_type;
type sysfs_oem, sysfs_type, fs_type;
type sysfs_graphics, sysfs_type, fs_type;
# sysfs
type sysfs_battery_supply, sysfs_type, fs_type;
type sysfs_fpc_proximity, sysfs_type, fs_type;
type sysfs_graphics, sysfs_type, fs_type;
type sysfs_oem, sysfs_type, fs_type;
type sysfs_usb_supply, sysfs_type, fs_type;
# data
type display_data_file, file_type, data_file_type, core_data_file_type;

View File

@@ -16,9 +16,10 @@
/system/etc/audio_policy_configuration.xml u:object_r:vendor_configs_file:s0
# HALs
/system/bin/hw/android\.hardware\.light@2\.0-service\.oneplus_sdm845 u:object_r:hal_light_sdm845_exec:s0
/system/bin/hw/android\.hardware\.light@2\.0-service\.oneplus_sdm845 u:object_r:hal_light_sdm845_exec:s0
/system/bin/hw/lineage\.livedisplay@2\.0-service\.oneplus_sdm845 u:object_r:hal_livedisplay_sdm845_exec:s0
/system/bin/hw/lineage\.touch@1\.0-service\.oneplus_sdm845 u:object_r:hal_touch_sdm845_exec:s0
/system/bin/hw/lineage\.touch@1\.0-service\.oneplus_sdm845 u:object_r:hal_touch_sdm845_exec:s0
/system/bin/hw/lineage\.trust@1\.0-service\.oneplus_sdm845 u:object_r:hal_trust_sdm845_exec:s0
# Modules
/system/lib/modules/wlan\.ko u:object_r:vendor_file:s0

View File

@@ -0,0 +1,12 @@
type hal_trust_sdm845, coredomain, domain;
hal_server_domain(hal_trust_sdm845, hal_lineage_trust)
type hal_trust_sdm845_exec, exec_type, file_type;
init_daemon_domain(hal_trust_sdm845)
# Talk to the binder device node
allow hal_trust_sdm845 binder_device:chr_file rw_file_perms;
# Allow access to otg toggle node
allow hal_trust_sdm845 sysfs_usb_supply:dir search;
allow hal_trust_sdm845 sysfs_usb_supply:file rw_file_perms;