cec: add otp in str mode
authorYong Qin <yong.qin@amlogic.com>
Tue, 17 Jul 2018 10:00:34 +0000 (18:00 +0800)
committerYixun Lan <yixun.lan@amlogic.com>
Fri, 20 Jul 2018 06:33:05 +0000 (23:33 -0700)
PD#170099: cec: add otp in str mode

1.add otp function in str mode

Change-Id: I49cee530f63246bc080ec4a6eb9538a0bb6c6bae
Signed-off-by: Yong Qin <yong.qin@amlogic.com>
drivers/amlogic/cec/hdmi_ao_cec.c
drivers/amlogic/cec/hdmi_ao_cec.h

index 8689dff37f766685dcc74655d24bdf7833c6bb12..96df6d32608072dc12c01c3ad535d43d415961d7 100644 (file)
@@ -1651,8 +1651,20 @@ static void cec_rx_process(void)
                        cec_menu_status_smp(initiator, DEVICE_MENU_ACTIVE);
                break;
 
+       case CEC_OC_IMAGE_VIEW_ON:
+       case CEC_OC_TEXT_VIEW_ON:
+               /* request active source needed */
+               dest_phy_addr = 0xffff;
+               dest_phy_addr = (dest_phy_addr << 0) | (initiator << 16);
+               writel(dest_phy_addr, cec_dev->cec_reg + AO_RTI_STATUS_REG1);
+               CEC_INFO("weak up by otp\n");
+               cec_key_report(0);
+               break;
+
        default:
                CEC_ERR("unsupported command:%x\n", opcode);
+               CEC_ERR("wake_ok=%d,hal_flag=0x%x\n",
+                       wake_ok, cec_dev->hal_flag);
                break;
        }
        new_msg = 0;
index 9f8dbc8ccb6099b62b3386e1962b6ba4e9450b60..f54c1b1131149954bc53a16e5680f9a9afd87367 100644 (file)
@@ -18,7 +18,7 @@
 #ifndef __AO_CEC_H__
 #define __AO_CEC_H__
 
-#define CEC_DRIVER_VERSION     "Ver**2018/07/16**\n"
+#define CEC_DRIVER_VERSION     "Ver**2018/07/18**\n"
 
 #define CEC_FRAME_DELAY                msecs_to_jiffies(400)
 #define CEC_DEV_NAME           "cec"