From d6ed30131a678393fc0a9df6e5f2de5762be5051 Mon Sep 17 00:00:00 2001 From: Isaac Chen Date: Sun, 5 Aug 2018 01:59:32 +0200 Subject: wayne: sepolicy: Address IR denials Signed-off-by: Isaac Chen --- sepolicy/device.te | 1 + sepolicy/file_contexts | 3 +++ sepolicy/hal_ir_default.te | 1 + 3 files changed, 5 insertions(+) create mode 100644 sepolicy/hal_ir_default.te (limited to 'sepolicy') diff --git a/sepolicy/device.te b/sepolicy/device.te index 8ec31c9..b84e726 100644 --- a/sepolicy/device.te +++ b/sepolicy/device.te @@ -1 +1,2 @@ type fingerprint_device, dev_type; +type spidev_device, dev_type; diff --git a/sepolicy/file_contexts b/sepolicy/file_contexts index 19a8402..6959397 100644 --- a/sepolicy/file_contexts +++ b/sepolicy/file_contexts @@ -14,6 +14,9 @@ # HVDCP /sys/devices(/platform)?/soc/[a-z0-9]+\.i2c/i2c-[0-9]+/[0-9]+-[a-z0-9]+/[a-z0-9]+\.i2c:qcom,[a-z0-9]+@[a-z0-9]:qcom,smb[a-z0-9]+-parallel-slave@[0-9]+/power_supply/parallel(/.*)? u:object_r:sysfs_usb_supply:s0 +# IR +/dev/spidev7.1 u:object_r:spidev_device:s0 + # Light HAL /(vendor|system/vendor)/bin/hw/android\.hardware\.light@2\.0-service\.xiaomi_wayne u:object_r:hal_light_default_exec:s0 diff --git a/sepolicy/hal_ir_default.te b/sepolicy/hal_ir_default.te new file mode 100644 index 0000000..2f9f2b6 --- /dev/null +++ b/sepolicy/hal_ir_default.te @@ -0,0 +1 @@ +allow hal_ir_default spidev_device:chr_file rw_file_perms; -- cgit v1.2.3