#include "hdmi_rx_edid.h"
-#define RX_VER0 "ver.2019-05-01"
+#define RX_VER0 "ver.2019-05-07"
/*
*
*
}
EXPORT_SYMBOL(rx_set_hdr_lumi);
+void rx_edid_physical_addr(int a, int b, int c, int d)
+{
+ tx_hpd_event = E_RCV;
+ up_phy_addr = ((d & 0xf) << 12) |
+ ((c & 0xf) << 8) |
+ ((b & 0xf) << 4) |
+ ((a & 0xf) << 0);
+
+ /* if (log_level & EDID_LOG) */
+ rx_pr("\nup_phy_addr = %x\n", up_phy_addr);
+}
+EXPORT_SYMBOL(rx_edid_physical_addr);
+
unsigned int checksum;
};
+enum tx_hpd_event_e {
+ E_IDLE = 0,
+ E_EXE = 1,
+ E_RCV = 2,
+};
+
enum hdmi_vic_e {
/* Refer to CEA 861-D */
HDMI_UNKNOWN = 0,
int receive_edid_len = MAX_RECEIVE_EDID;
MODULE_PARM_DESC(receive_edid, "\n receive_edid\n");
module_param_array(receive_edid, byte, &receive_edid_len, 0664);
+int tx_hpd_event;
int edid_len;
MODULE_PARM_DESC(edid_len, "\n edid_len\n");
module_param(edid_len, int, 0664);
}
EXPORT_SYMBOL(rx_repeat_hpd_state);
-void rx_edid_physical_addr(int a, int b, int c, int d)
-{
-}
-EXPORT_SYMBOL(rx_edid_physical_addr);
-
-
};
extern int receive_edid_len;
+extern int tx_hpd_event;
extern bool new_edid;
extern int hdcp_array_len;
extern int hdcp_len;
} else if (rx.err_rec_mode == ERR_REC_HPD_RST) {
rx_set_cur_hpd(0);
rx.phy.cable_clk = 0;
- rx.state = FSM_HPD_HIGH;
+ rx.state = FSM_INIT;
rx.err_rec_mode = ERR_REC_EQ_RETRY;
}
rx_set_eq_run_state(E_EQ_START);
} else if (rx.err_rec_mode == ERR_REC_HPD_RST) {
rx_set_cur_hpd(0);
rx.phy.cable_clk = 0;
- rx.state = FSM_HPD_HIGH;
+ rx.state = FSM_INIT;
rx.err_rec_mode = ERR_REC_EQ_RETRY;
}
}
return 0;
}
+void rx_dw_edid_monitor(void)
+{
+ if (!hdmi_cec_en)
+ return;
+ if (tx_hpd_event == E_RCV) {
+ if (rx.open_fg)
+ fsm_restart();
+ rx_set_port_hpd(ALL_PORTS, 0);
+ hdmi_rx_top_edid_update();
+ hpd_wait_cnt = 0;
+ tx_hpd_event = E_EXE;
+ } else if (tx_hpd_event == E_EXE) {
+ if (!rx.open_fg)
+ hpd_wait_cnt++;
+ if (!rx_hpd_keep_low()) {
+ rx_set_port_hpd(ALL_PORTS, 1);
+ tx_hpd_event = E_IDLE;
+ }
+ }
+}
+
void hdmirx_timer_handler(unsigned long arg)
{
struct hdmirx_dev_s *devp = (struct hdmirx_dev_s *)arg;
rx_5v_monitor();
rx_check_repeat();
+ rx_dw_edid_monitor();
if (rx.open_fg) {
rx_nosig_monitor();
if (!hdmirx_repeat_support() || !rx.firm_change) {
}
set_vsdb_phy_addr(hdev, &info->vsdb_phy_addr, &buff[BlockAddr]);
- if (hdev->repeater_tx) {
- if ((check_fbc_special(&hdev->EDID_buf[0])) ||
- (check_fbc_special(&hdev->EDID_buf1[0])))
- rx_edid_physical_addr(0, 0, 0, 0);
- else
- rx_edid_physical_addr(info->vsdb_phy_addr.a,
- info->vsdb_phy_addr.b,
- info->vsdb_phy_addr.c,
- info->vsdb_phy_addr.d);
- }
+ if ((check_fbc_special(&hdev->EDID_buf[0])) ||
+ (check_fbc_special(&hdev->EDID_buf1[0])))
+ rx_edid_physical_addr(0, 0, 0, 0);
+ else
+ rx_edid_physical_addr(info->vsdb_phy_addr.a,
+ info->vsdb_phy_addr.b,
+ info->vsdb_phy_addr.c,
+ info->vsdb_phy_addr.d);
if (temp_addr >= VSpecificBoundary)
ret = -1;