hdmitx: eliminate the unreasonable mutex

PD#157189: hdmitx: eliminate the unreasonable mutex

Change-Id: I0ce4ebb1440c8a346602f892cae7afafa38cbfe7
Signed-off-by: Yi Zhou <yi.zhou@amlogic.com>
This commit is contained in:
Yi Zhou
2018-01-24 15:22:15 +08:00
committed by Jianxin Pan
parent 1c617c9407
commit 5ec43f40ae
2 changed files with 3 additions and 22 deletions

View File

@@ -20,28 +20,8 @@
#include <linux/amlogic/media/vout/hdmi_tx/hdmi_tx_ddc.h>
#include "hw/common.h"
static struct timer_list scdc_tmds_cfg_timer;
static void tmds_config(unsigned long arg)
void scdc_config(struct hdmitx_dev *hdev)
{
struct hdmitx_dev *hdev = (struct hdmitx_dev *)arg;
/* TMDS 1/40 & Scramble */
scdc_wr_sink(TMDS_CFG, hdev->para->tmds_clk_div40 ? 0x3 : 0);
}
void scdc_config(void *hdev)
{
static int init_flag;
if (!init_flag) {
init_flag = 1;
init_timer(&scdc_tmds_cfg_timer);
scdc_tmds_cfg_timer.data = (ulong)hdev;
scdc_tmds_cfg_timer.function = tmds_config;
scdc_tmds_cfg_timer.expires = jiffies;
add_timer(&scdc_tmds_cfg_timer);
return;
}
mod_timer(&scdc_tmds_cfg_timer, jiffies);
}

View File

@@ -19,6 +19,7 @@
#define __HDMI_TX_DDC_H__
#include <linux/types.h>
#include <linux/amlogic/media/vout/hdmi_tx/hdmi_tx_module.h>
#define EDID_SLAVE 0x50
#define EDIDSEG_ADR 0x30
@@ -88,7 +89,7 @@ void scdc_rd_sink(uint8_t adr, uint8_t *val);
void scdc_wr_sink(uint8_t adr, uint8_t val);
uint32_t hdcp_rd_hdcp14_ver(void);
uint32_t hdcp_rd_hdcp22_ver(void);
void scdc_config(void *hdev);
void scdc_config(struct hdmitx_dev *hdev);
void edid_read_head_8bytes(void);
#endif /* __HDMI_TX_SCDC_H__ */