summaryrefslogtreecommitdiff
path: root/drivers/gpu
diff options
context:
space:
mode:
authorAbhinav Kumar <abhinavk@codeaurora.org>2017-09-11 22:27:27 -0700
committerGerrit - the friendly Code Review server <code-review@localhost>2017-09-25 09:42:36 -0700
commit2ee560a95542196a2358ad38a284d7dca93681f8 (patch)
treef871f8d2d6e93747e48e066d5b3af91a920e788c /drivers/gpu
parentfa33f6bd9a2f2c62703ae7b6d3056edb03537ba6 (diff)
drm/msm: fix zero device count HDCP repeater test cases
Fix the handling of HDCP repeaters to mark part II of the authentication as failure if they do not have any devices connected to them. Change-Id: I6b21ed2ce9a280f7e200404b05d111508a6d3dd8 Signed-off-by: Abhinav Kumar <abhinavk@codeaurora.org>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/msm/sde_hdcp_1x.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/gpu/drm/msm/sde_hdcp_1x.c b/drivers/gpu/drm/msm/sde_hdcp_1x.c
index d08cf13c448d..c2d29a084c7f 100644
--- a/drivers/gpu/drm/msm/sde_hdcp_1x.c
+++ b/drivers/gpu/drm/msm/sde_hdcp_1x.c
@@ -1201,9 +1201,16 @@ static int sde_hdcp_1x_authentication_part2(struct sde_hdcp_1x *hdcp)
if (rc)
goto error;
- /* do not proceed further if no device connected */
- if (!hdcp->current_tp.dev_count)
+ /*
+ * Do not proceed further if no device connected
+ * If no downstream devices are attached to the repeater
+ * then part II fails.
+ */
+
+ if (!hdcp->current_tp.dev_count) {
+ rc = -EINVAL;
goto error;
+ }
rc = sde_hdcp_1x_write_ksv_fifo(hdcp);
} while (--v_retry && rc);