From: Hang Cheng Date: Wed, 20 Nov 2019 10:04:26 +0000 (+0800) Subject: hdmitx: optimize for power up flow [1/1] X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=536c587727d32caca2b80d56f4bd434db014cc7a;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git hdmitx: optimize for power up flow [1/1] PD#SWPL-17155 Problem: box set env to 2160p30hz 422,12bit, connect to Hisense LED50EC660US 4K TV which only support maximum 3G mode, then power on box, the hpd is low when run hdmitx hpd command, so hdmi is not set. after enter kernel, vout set 2160p30hz before edid is read, and the color space is forcely changed to rgb, but the color depth is still 12bit, so TV can't detect normally. Solution: keep hpd state low until edid read finishes, so that the mode vout set is filtered by edid Verify: S905X3 Change-Id: I11d126c4a2165ffaf3892534b1602bad3d78618d Signed-off-by: Hang Cheng (cherry picked from commit f0a8ac5dcd74b92919e9ae55dd88de781c567c91) --- diff --git a/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c b/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c index a612a27acf86..966cbd9712fe 100644 --- a/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c +++ b/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c @@ -4441,10 +4441,11 @@ static int hdmi_task_handle(void *data) struct vinfo_s *info = NULL; struct hdmitx_dev *hdmitx_device = (struct hdmitx_dev *)data; - hdmitx_extcon_hdmi->state = !!(hdmitx_device->hwop.cntlmisc( - hdmitx_device, MISC_HPD_GPI_ST, 0)); - hdmitx_device->hpd_state = hdmitx_extcon_hdmi->state; - hdmitx_notify_hpd(hdmitx_device->hpd_state); + /* hdmitx_extcon_hdmi->state = !!(hdmitx_device->hwop.cntlmisc( + * hdmitx_device, MISC_HPD_GPI_ST, 0)); + * hdmitx_device->hpd_state = hdmitx_extcon_hdmi->state; + * hdmitx_notify_hpd(hdmitx_device->hpd_state); + */ extcon_set_state_sync(hdmitx_extcon_power, EXTCON_DISP_HDMI, hdmitx_device->hpd_state); INIT_WORK(&hdmitx_device->work_hdr, hdr_work_func);