From 87bcb75be7eed7460fdb0ee8a4e1f5fca7772861 Mon Sep 17 00:00:00 2001 From: Zongdong Jiao Date: Tue, 3 Jul 2018 14:09:10 +0800 Subject: [PATCH] hdmitx: forward hdr block data to rprx [1/1] PD#168875: hdmitx: forward hdr block data to rprx Under repeater mode, need forward hdr block data to rprx. Change-Id: Ib57dc4071f621e620a88cdf24340194cca1f8b24 Signed-off-by: Zongdong Jiao --- drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_edid.c | 5 +++++ include/linux/amlogic/media/vout/hdmi_tx/hdmi_tx_module.h | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_edid.c b/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_edid.c index e3789810fef3..1a9b18cd33a8 100644 --- a/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_edid.c +++ b/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_edid.c @@ -1454,6 +1454,8 @@ static int hdmitx_edid_block_parse(struct hdmitx_dev *hdmitx_device, case EXTENSION_DRM_TAG: Edid_ParsingDRMBlock(pRXCap, &BlockBuf[offset]); + rx_set_hdr_lumi(&BlockBuf[offset], + (BlockBuf[offset] & 0x1f) + 1); break; case EXTENSION_VFPDB_TAG: /* Just record VFPDB offset address, call Edid_ParsingVFPDB() after DTD @@ -2330,6 +2332,7 @@ void hdmitx_edid_ram_buffer_clear(struct hdmitx_dev *hdmitx_device) /* Clear the Parse result of HDMI Sink's EDID. */ void hdmitx_edid_clear(struct hdmitx_dev *hdmitx_device) { + char tmp[2] = {0}; struct rx_cap *pRXCap = &(hdmitx_device->RXCap); memset(pRXCap, 0, sizeof(struct rx_cap)); @@ -2350,6 +2353,8 @@ void hdmitx_edid_clear(struct hdmitx_dev *hdmitx_device) sizeof(hdmitx_device->EDID_hash)); hdmitx_device->edid_parsing = 0; hdmitx_edid_set_default_aud(hdmitx_device); + rx_set_hdr_lumi(&tmp[0], 2); + rx_set_receiver_edid(&tmp[0], 2); } /* diff --git a/include/linux/amlogic/media/vout/hdmi_tx/hdmi_tx_module.h b/include/linux/amlogic/media/vout/hdmi_tx/hdmi_tx_module.h index b397411a0a47..2a82aa8c7073 100644 --- a/include/linux/amlogic/media/vout/hdmi_tx/hdmi_tx_module.h +++ b/include/linux/amlogic/media/vout/hdmi_tx/hdmi_tx_module.h @@ -549,6 +549,12 @@ void __attribute__((weak))rx_edid_physical_addr(unsigned char a, { } +extern int rx_set_hdr_lumi(unsigned char *data, int len); +int __attribute__((weak))rx_set_hdr_lumi(unsigned char *data, int len) +{ + return 0; +} + extern void rx_set_repeater_support(bool enable); void __attribute__((weak))rx_set_repeater_support(bool enable) {