gta4xl-common: Blank screen on recovery and charger init

* Otherwise we end up with a blackscreen

Change-Id: Ib6ef4f1fce87b5f74089b2caab230b0343c05d87
diff --git a/configs/init/init.exynos9611.rc b/configs/init/init.exynos9611.rc
index a13933b..12589ac 100644
--- a/configs/init/init.exynos9611.rc
+++ b/configs/init/init.exynos9611.rc
@@ -862,6 +862,10 @@
      oneshot
      seclabel u:r:watchdogd:s0
 
+on init && property:ro.bootmode=charger
+    write /sys/class/graphics/fb0/blank 1
+    write /sys/class/graphics/fb0/blank 0
+
 # sensorhub fw
 on post-fs
     chmod 0770 /spu/sensorhub
diff --git a/configs/init/init.recovery.exynos9611.rc b/configs/init/init.recovery.exynos9611.rc
index 5dbd1f7..199a529 100644
--- a/configs/init/init.recovery.exynos9611.rc
+++ b/configs/init/init.recovery.exynos9611.rc
@@ -2,3 +2,6 @@
     write /proc/sys/kernel/hung_task_timeout_secs 0
 
     setprop sys.usb.configfs 1
+
+    write /sys/class/graphics/fb0/blank 1
+    write /sys/class/graphics/fb0/blank 0
diff --git a/sepolicy/vendor/file.te b/sepolicy/vendor/file.te
index 48862d5..6e65561 100644
--- a/sepolicy/vendor/file.te
+++ b/sepolicy/vendor/file.te
@@ -25,5 +25,6 @@
 type sysfs_decon, sysfs_type, r_fs_type, fs_type;
 type sysfs_decon_writable, sysfs_type, rw_fs_type, fs_type;
 type sysfs_gpu_memory, sysfs_type, r_fs_type, fs_type;
+type sysfs_graphics_writable, sysfs_type, rw_fs_type, fs_type;
 type sysfs_net_mtu_writable, sysfs_type, rw_fs_type, fs_type;
 type sysfs_v4l, sysfs_type, r_fs_type, fs_type;
diff --git a/sepolicy/vendor/file_contexts b/sepolicy/vendor/file_contexts
index 027c85e..1f349f9 100644
--- a/sepolicy/vendor/file_contexts
+++ b/sepolicy/vendor/file_contexts
@@ -50,6 +50,9 @@
 /sys/devices/virtual/camera/rear/ssrm_camera_info             u:object_r:sysfs_camera_writable:s0
 /sys/devices/virtual/camera(/.*)                              u:object_r:sysfs_camera:s0
 
+# Graphics
+/sys/devices/platform/148b0000.decon_f/graphics/fb0/blank     u:object_r:sysfs_graphics_writable:s0
+
 # Net
 /sys/devices/platform/119c0000.scsc_wifibt/net(/.*)/mtu       u:object_r:sysfs_net_mtu_writable:s0
 /sys/devices/virtual/net(/.*)/mtu                             u:object_r:sysfs_net_mtu_writable:s0
diff --git a/sepolicy/vendor/init.te b/sepolicy/vendor/init.te
index 997f2ce..4fa194b 100644
--- a/sepolicy/vendor/init.te
+++ b/sepolicy/vendor/init.te
@@ -6,3 +6,5 @@
 allow init kernel:system module_request;
 
 allow init socket_device:sock_file { create setattr unlink };
+
+allow init sysfs_graphics_writable:file rw_file_perms;
diff --git a/sepolicy/vendor/vendor_init.te b/sepolicy/vendor/vendor_init.te
index 73fa554..82b6ce3 100644
--- a/sepolicy/vendor/vendor_init.te
+++ b/sepolicy/vendor/vendor_init.te
@@ -10,4 +10,6 @@
 allow vendor_init cpdebug_efs_file:lnk_file { getattr setattr };
 allow vendor_init pdp_efs_file:file getattr;
 
+allow vendor_init sysfs_graphics_writable:file rw_file_perms;
+
 dontaudit vendor_init system_prop:file read;