Fix sepolicy
BUG: 76044656
Test: Local build
Change-Id: I3734360d5220c3ba3f6575eee7a43a44d084a2a9
diff --git a/shared/sepolicy/file.te b/shared/sepolicy/file.te
index 28f7454..fa8ea02 100644
--- a/shared/sepolicy/file.te
+++ b/shared/sepolicy/file.te
@@ -1,7 +1,5 @@
# File types
type initial_metadata_file, file_type;
type sensors_hal_socket, file_type;
-# USB related portion of sysfs requiring privileged access, as opposed to sysfs_usb which is
-type sysfs_usb_priv, sysfs_type, file_type;
type tombstone_snapshot_file, file_type;
type var_run_system_file, file_type;
diff --git a/shared/sepolicy/file_contexts b/shared/sepolicy/file_contexts
index 06ca2b8..cfae09a 100644
--- a/shared/sepolicy/file_contexts
+++ b/shared/sepolicy/file_contexts
@@ -18,12 +18,6 @@
/var/run/system(/.*)? u:object_r:var_run_system_file:s0
#############################
-# sysfs files
-#
-/sys/bus/usb(/.*)? u:object_r:sysfs_usb_priv:s0
-/sys/devices/platform/dummy_hcd\.[0-9](/.*)? u:object_r:sysfs_usb_priv:s0
-
-#############################
# Vendor files
#
/vendor/bin/gce_fs_monitor u:object_r:gce_fs_monitor_exec:s0
diff --git a/shared/sepolicy/usbforward.te b/shared/sepolicy/usbforward.te
index 55a925d..6d0833e 100644
--- a/shared/sepolicy/usbforward.te
+++ b/shared/sepolicy/usbforward.te
@@ -10,10 +10,7 @@
allow usbforward usb_device:dir r_dir_perms;
allow usbforward usb_device:chr_file rw_file_perms;
-# /sys/bus/usb/devices, /sys/devices/platform/dummy_hcd.0/usb1/1-1/busnum
-r_dir_file(usbforward, sysfs_usb_priv)
# Read /sys/devices/platform/dummy_hcd.0/usb1/1-1/speed. Although this file is labelled
-# sysfs_usb_priv, during adb root and adb unroot usbforward sees the file as sysfs.
# It is acceptable to give usbforward this wide access because usbforward is not a stock Android
# domain and it does not run Android apps. Thus, the laxer access restrictions of this domain
# do not impact how compatible the resulting Android emulator appears to system services and apps.