init: allow read of /sys/devices/virtual/block/zram
Commit erroneously 55039509 removed init's read access to
/sys/devices/virtual/block/zram*. Restore access.
Test: cat /proc/meminfo
...
SwapTotal: 524284 kB
SwapFree: 524284 kB
...
Bug: 71510938
Change-Id: I20268168caa541a7dafa1e32339641095e1e524b
diff --git a/public/init.te b/public/init.te
index 80e9e77..ad3ef49 100644
--- a/public/init.te
+++ b/public/init.te
@@ -305,13 +305,16 @@
sysfs_android_usb
sysfs_leds
sysfs_power
- sysfs_zram
}:file w_file_perms;
allow init {
sysfs_dt_firmware_android
}:file r_file_perms;
+allow init {
+ sysfs_zram
+}:file rw_file_perms;
+
# init chmod/chown access to /sys files.
allow init {
sysfs_android_usb