Skip to content
Snippets Groups Projects
Commit a93a1e38 authored by Tri Vo's avatar Tri Vo
Browse files

Re-add access to /sys/class/android_usb.

Access to /sys/class/android_usb/ was lost when that dir received a new
label sysfs_android_usb.

Bug: 65643247
Test: can enter recovery mode and sideload through usb  without denials to /sys
Change-Id: I22821bab9833b832f13e0c45ff8da4dae115fa4d
parent 975efbe5
Branches
Tags
No related merge requests found
...@@ -55,10 +55,11 @@ recovery_only(` ...@@ -55,10 +55,11 @@ recovery_only(`
# Read kernel config through libvintf for OTA matching # Read kernel config through libvintf for OTA matching
allow recovery config_gz:file { open read getattr }; allow recovery config_gz:file { open read getattr };
# Write to /sys/class/android_usb/android0/enable.
# TODO: create more specific label?
r_dir_file(recovery, sysfs) r_dir_file(recovery, sysfs)
allow recovery sysfs:file w_file_perms;
# Write to /sys/class/android_usb/android0/enable.
r_dir_file(recovery, sysfs_android_usb)
allow recovery sysfs_android_usb:file w_file_perms;
# Write to /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq. # Write to /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq.
allow recovery sysfs_devices_system_cpu:file w_file_perms; allow recovery sysfs_devices_system_cpu:file w_file_perms;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment