[DO NOT MERGE] Add vibrator hal sepolicy rules
Bug: 143743511
Bug: 143744015
Test: manual check logs
Change-Id: Ia8ba9efb53683c68c4e789ef595ed049aaab9b54
Signed-off-by: chasewu <chasewu@google.com>
diff --git a/vendor/google/genfs_contexts b/vendor/google/genfs_contexts
index 0ae8239..9f78b85 100644
--- a/vendor/google/genfs_contexts
+++ b/vendor/google/genfs_contexts
@@ -73,10 +73,7 @@
genfscon debugfs /regmap/spmi0-05/data u:object_r:debugfs_pmic:s0
# Vibrator
-# EVT 1.0 and older
-genfscon sysfs /devices/platform/soc/c94000.i2c/i2c-3/3-0043 u:object_r:sysfs_vibrator:s0
-# EVT 1.1 and newer
-genfscon sysfs /devices/platform/soc/c94000.i2c/i2c-4/4-0043 u:object_r:sysfs_vibrator:s0
+genfscon sysfs /devices/platform/soc/98c000.i2c/i2c-2/2-005a u:object_r:sysfs_vibrator:s0
# Camera
genfscon sysfs /devices/platform/soc/ac4a000.qcom,cci u:object_r:sysfs_camera:s0
diff --git a/vendor/google/property.te b/vendor/google/property.te
index 12f70f6..1c238fe 100644
--- a/vendor/google/property.te
+++ b/vendor/google/property.te
@@ -9,3 +9,4 @@
type vendor_ramoops_prop, property_type;
type ecoservice_prop, property_type;
type vendor_shutdown_prop, property_type;
+type vendor_vibrator_prop, property_type;
diff --git a/vendor/google/property_contexts b/vendor/google/property_contexts
index 5455348..fb048ce 100644
--- a/vendor/google/property_contexts
+++ b/vendor/google/property_contexts
@@ -73,3 +73,15 @@
# FP HAL kpi
vendor.fpc_kpi u:object_r:vendor_default_prop:s0
+
+# Haptics HAL
+ro.vibrator.hal.closeloop.threshold u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.config.dynamic u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.click.duration u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.tick.duration u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.heavyclick.duration u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.short.voltage u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.long.voltage u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.long.frequency.shift u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.effect.shape u:object_r:vendor_vibrator_prop:s0
+ro.vibrator.hal.steady.shape u:object_r:vendor_vibrator_prop:s0