summaryrefslogtreecommitdiffstats
path: root/sepolicy
diff options
context:
space:
mode:
Diffstat (limited to 'sepolicy')
-rw-r--r--sepolicy/file.te2
-rw-r--r--sepolicy/file_contexts10
-rw-r--r--sepolicy/init.te2
-rw-r--r--sepolicy/pvrsrvinit.te8
-rw-r--r--sepolicy/system_server.te2
5 files changed, 24 insertions, 0 deletions
diff --git a/sepolicy/file.te b/sepolicy/file.te
new file mode 100644
index 0000000..c29f1df
--- /dev/null
+++ b/sepolicy/file.te
@@ -0,0 +1,2 @@
+# Hardware tunables
+type sysfs_hardware, fs_type, sysfs_type;
diff --git a/sepolicy/file_contexts b/sepolicy/file_contexts
new file mode 100644
index 0000000..08d1b38
--- /dev/null
+++ b/sepolicy/file_contexts
@@ -0,0 +1,10 @@
+# Device nodes
+/dev/tiler u:object_r:video_device:s0
+/dev/dsscomp u:object_r:graphics_device:s0
+
+# System binaries
+/system/bin/pvrsrvinit u:object_r:pvrsrvinit_exec:s0
+
+# Hardware tunables
+/sys/devices/platform/omapdss/manager0/cpr_coef -- u:object_r:sysfs_hardware:s0
+/sys/devices/platform/omapdss/manager0/cpr_enable -- u:object_r:sysfs_hardware:s0
diff --git a/sepolicy/init.te b/sepolicy/init.te
new file mode 100644
index 0000000..d269ef2
--- /dev/null
+++ b/sepolicy/init.te
@@ -0,0 +1,2 @@
+# Hardware tunables
+allow init sysfs_hardware:file rw_file_perms;
diff --git a/sepolicy/pvrsrvinit.te b/sepolicy/pvrsrvinit.te
new file mode 100644
index 0000000..0a2a98e
--- /dev/null
+++ b/sepolicy/pvrsrvinit.te
@@ -0,0 +1,8 @@
+type pvrsrvinit, domain;
+type pvrsrvinit_exec, exec_type, file_type;
+
+init_daemon_domain(pvrsrvinit)
+
+allow pvrsrvinit gpu_device:chr_file rw_file_perms;
+allow pvrsrvinit kernel:system module_request;
+allow pvrsrvinit self:capability sys_module;
diff --git a/sepolicy/system_server.te b/sepolicy/system_server.te
new file mode 100644
index 0000000..24ff30f
--- /dev/null
+++ b/sepolicy/system_server.te
@@ -0,0 +1,2 @@
+# Hardware tunables
+allow system_server sysfs_hardware:file rw_file_perms;