[Xiaomi Mi 9 ROMs, Kernels, Recoveries, & Other Dev] Cave_diver:
There's an issue when AOD is turned off, the panel doesn't come back after an idle session. Sometimes it does back mostly it doesn't. Basically the phone keeps running but the display stays dark, a reboot brings the display back.

This is what logcat says:

08-13 19:23:07.534 724 724 I SDM_EventThread: type=1400 audit(0.0:2416): avc: denied { read } for name="dump" dev="debugfs" ino=3797 scontext=u:r:hal_graphics_composer_default:s0 tcontext=u:object_r:debugfs:s0 tclass=file permissive=1

08-13 19:23:07.534 724 724 I SDM_EventThread: type=1400 audit(0.0:2417): avc: denied { open } for path="/sys/kernel/debug/dri/0/debug/dump" dev="debugfs" ino=3797 scontext=u:r:hal_graphics_composer_default:s0 tcontext=u:object_r:debugfs:s0 tclass=file permissive=1

08-13 19:23:07.534 724 724 I SDM_EventThread: type=1400 audit(0.0:2418): avc: denied { getattr } for path="/sys/kernel/debug/dri/0/debug/dump" dev="debugfs" ino=3797 scontext=u:r:hal_graphics_composer_default:s0 tcontext=u:object_r:debugfs:s0 tclass=file permissive=1

08-13 19:23:07.540 710 710 I light@2.0-servi: type=1400 audit(0.0:2419): avc: denied { write } for name="brightness" dev="sysfs" ino=72550 scontext=u:r:init:s0 tcontext=u:object_r:sysfs_graphics:s0 tclass=file permissive=1

08-13 19:23:07.540 710 710 I light@2.0-servi: type=1400 audit(0.0:2420): avc: denied { open } for path="/sys/devices/platform/soc/ae00000.qcom,mdss_mdp/backlight/panel0-backlight/brightness" dev="sysfs" ino=72550 scontext=u:r:init:s0 tcontext=u:object_r:sysfs_graphics:s0 tclass=file permissive=1

08-13 19:23:07.531 724 1705 I SDM : DisplayBuiltIn::ControlPartialUpdate: partial update is not applicable for display id = 28

08-13 19:23:07.531 724 876 I SDM : DisplayBase::HwRecovery: Handling event = 0

08-13 19:23:07.532 724 876 I SDM : DisplayBase::HwRecovery: Handling event = 1

08-13 19:23:07.533 791 791 D SurfaceFlinger: Finished set power mode=2, type=0

08-13 19:23:07.535 1373 2074 D SurfaceControl: Excessive delay in setPowerMode()

08-13 19:23:07.538 724 27266 I ServiceManagement: getService: Trying again for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default...

08-13 19:23:07.540 724 26795 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:07.540 724 24716 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:07.540 724 25518 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:07.540 724 24800 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:07.541 724 876 I SDM : HWDeviceDRM::DumpDebugData: Wrote hw_recovery file /data/vendor/display/hw_recovery/Peripheral_HWR_421

08-13 19:23:07.541 724 876 I SDM : DisplayBase::HwRecovery: Captured debugfs data for display = 0

08-13 19:23:07.541 724 876 I SDM : DisplayBase::HwRecovery: Handling event = 0

08-13 19:23:07.541 724 876 I SDM : DisplayBase::HwRecovery: Handling event = 0

08-13 19:23:07.542 724 876 I SDM : HWEventsDRM::HandlePanelDead: Received panel dead event

08-13 19:27:35.115 724 876 I SDM : HWEventsDRM::HandlePanelDead: Received panel dead event

08-13 19:27:35.118 724 876 I SDM : HWCSession::DisplayPowerReset: Powering off display = 0

08-13 19:27:35.118 724 876 I SDM : DisplayBase::SetDisplayState: Set state = 0, display 28-0, teardown = 1

08-13 19:27:35.118 758 834 D DisplayFeatureHal: HandleDisplayState enter state 1, last state 0

08-13 19:27:35.119 758 834 D DisplayFeatureHal: onResume enter, mFodScreenOn=0

Also the logfile is full of fingerprint events, these appear every couple of milliseconds:

08-13 19:23:08.046 724 25882 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.048 724 24908 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.048 724 24502 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.049 724 18060 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.049 724 1228 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.049 724 25845 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.052 724 26144 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.052 724 26342 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...

08-13 19:23:08.053 724 24872 W ServiceManagement: Waited one second for vendor.xiaomi.hardware.citsensorservice@1.1::ICitSensorService/default. Waiting another...