Skip to content

Commit 5f1c036

Browse files
Zheng Yangrkhuangtao
authored andcommitted
drm/bridge: synopsys: dw-hdmi: fix kernel logo flash when output YCbCr422 mode
On rockchip platform, hdmi input format is YCbCr444 when output mode is YCbCr422. Then the value of HDMI_TX_INVID0 on YCbCr422 is same as the value of YCbCr444, both is 0x09/0x0b. This make enc_out_bus_format stroed in struct hdmi_data is wrong, which is MEDIA_BUS_FMT_YUV8_1X24 or MEDIA_BUS_FMT_YUV10_1X30. When android set enc_out_bus_format to YCbCr422, dw_hdmi_setup will be called and logo will flash. This patch use colorspace restored in HDMI_FC_AVICONF0 to distinguish them. Change-Id: I6b913951b58fb47628617c11d6059bc1be4e370a Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
1 parent 80f0ef4 commit 5f1c036

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

drivers/gpu/drm/bridge/synopsys/dw-hdmi.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3024,12 +3024,16 @@ static void dw_hdmi_attatch_properties(struct dw_hdmi *hdmi)
30243024
case 0x09:
30253025
if (colorspace == HDMI_COLORSPACE_YUV420)
30263026
color = MEDIA_BUS_FMT_UYYVYY8_0_5X24;
3027+
else if (colorspace == HDMI_COLORSPACE_YUV422)
3028+
color = MEDIA_BUS_FMT_UYVY8_1X16;
30273029
else
30283030
color = MEDIA_BUS_FMT_YUV8_1X24;
30293031
break;
30303032
case 0x0b:
30313033
if (colorspace == HDMI_COLORSPACE_YUV420)
30323034
color = MEDIA_BUS_FMT_UYYVYY10_0_5X30;
3035+
else if (colorspace == HDMI_COLORSPACE_YUV422)
3036+
color = MEDIA_BUS_FMT_UYVY10_1X20;
30333037
else
30343038
color = MEDIA_BUS_FMT_YUV10_1X30;
30353039
break;

0 commit comments

Comments
 (0)