# hal_power_default.te

# /dev/cpu_dma_latency
allow hal_power_default cpu_dma_device:chr_file rw_file_perms;

# /dev/stune/top-app/schedtune.boost
allow hal_power_default cgroup:file rw_file_perms;

# /sys/class/input/
allow hal_power_default sysfs_input:dir r_dir_perms;

# /sys/class/power/
allow hal_power_default sysfs_power:dir r_dir_perms;
allow hal_power_default sysfs_power:file r_file_perms;
allow hal_power_default sysfs_power_writable:file rw_file_perms;

# /sys/class/sec/tsp/input/
allow hal_power_default sysfs_sec_touchscreen:dir r_dir_perms;
allow hal_power_default sysfs_sec_touchscreen:lnk_file r_file_perms;

# /sys/class/sec/tsp/input/{cmd,enabled}
allow hal_power_default sysfs_touchscreen_writable:file rw_file_perms;

# /sys/devices/system/cpu/cpu[0-9]/cpufreq/scaling_max_freq
allow hal_power_default sysfs_devices_system_cpu:file rw_file_perms;
allow hal_power_default sysfs_graphics:dir search;
allow hal_power_default sysfs_graphics:file r_file_perms;
allow hal_power_default sysfs_input:file r_file_perms;
allow hal_power_default sysfs_virtual:dir r_dir_perms;
allow hal_power_default sysfs_virtual:file r_file_perms;
allow hal_power_default sysfs_touchscreen_writable:dir r_dir_perms;
allow hal_power_default sysfs_sec_touchscreen:dir { read open };
allow hal_power_default sysfs_sec_touchscreen:file r_file_perms;
type hal_lineage_power_hwservice, hwservice_manager_type; 
add_hwservice(hal_power_default, hal_power_hwservice)
allow hal_power_default sysfs_decon:dir search;
allow hal_power_default property_socket:sock_file write;
allow hal_power_default init:unix_stream_socket connectto;
