From 5849d2daafabd656ec59334bc54d54cc9e289f9a Mon Sep 17 00:00:00 2001 From: Ahung Cheng Date: Thu, 12 Jul 2018 16:24:07 +0800 Subject: tegra: hdcp: pass SOR instance to upstream upstream library needs to get the active SOR instance bug 2219364 Change-Id: I79b5fb9ae690037ac98f7e46b053da14d4322c63 Signed-off-by: Ahung Cheng Reviewed-on: https://git-master.nvidia.com/r/1776730 (cherry picked from commit 206d44dcbd84f933e9d2bb7f0f7c532b5b3ed632) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2313884 Reviewed-by: automaticguardword Reviewed-by: Bibek Basu Reviewed-by: mobile promotions Tested-by: mobile promotions GVS: Gerrit_Virtual_Submit --- drivers/video/tegra/dc/hdcp/dphdcp.c | 3 ++- drivers/video/tegra/dc/hdcp/hdmihdcp.c | 3 ++- include/uapi/video/nvhdcp.h | 2 ++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/video/tegra/dc/hdcp/dphdcp.c b/drivers/video/tegra/dc/hdcp/dphdcp.c index 9d55f3f9a..e364f7f6f 100644 --- a/drivers/video/tegra/dc/hdcp/dphdcp.c +++ b/drivers/video/tegra/dc/hdcp/dphdcp.c @@ -1,7 +1,7 @@ /* * dphdcp.c: dp hdcp driver. * - * Copyright (c) 2015-2019, NVIDIA CORPORATION, All rights reserved. + * Copyright (c) 2015-2020, NVIDIA CORPORATION, All rights reserved. * * This software is licensed under the terms of the GNU General Public * License version 2, as published by the Free Software Foundation, and @@ -2076,6 +2076,7 @@ static int get_dphdcp_state(struct tegra_dphdcp *dphdcp, pkt->hdcp22 = dphdcp->hdcp22; pkt->port = TEGRA_NVHDCP_PORT_DP; } + pkt->sor = dphdcp->dp->sor->ctrl_num; mutex_unlock(&dphdcp->lock); return 0; } diff --git a/drivers/video/tegra/dc/hdcp/hdmihdcp.c b/drivers/video/tegra/dc/hdcp/hdmihdcp.c index f9a5949e0..0f415d944 100644 --- a/drivers/video/tegra/dc/hdcp/hdmihdcp.c +++ b/drivers/video/tegra/dc/hdcp/hdmihdcp.c @@ -1,7 +1,7 @@ /* * hdmihdcp.c: hdmi hdcp functions. * - * Copyright (c) 2014-2019, NVIDIA CORPORATION, All rights reserved. + * Copyright (c) 2014-2020, NVIDIA CORPORATION, All rights reserved. * * This software is licensed under the terms of the GNU General Public * License version 2, as published by the Free Software Foundation, and @@ -553,6 +553,7 @@ static int get_nvhdcp_state(struct tegra_nvhdcp *nvhdcp, pkt->hdcp22 = nvhdcp->hdcp22; pkt->port = TEGRA_NVHDCP_PORT_HDMI; } + pkt->sor = nvhdcp->hdmi->sor->ctrl_num; mutex_unlock(&nvhdcp->lock); return 0; } diff --git a/include/uapi/video/nvhdcp.h b/include/uapi/video/nvhdcp.h index 7f759f56e..e07c9def1 100644 --- a/include/uapi/video/nvhdcp.h +++ b/include/uapi/video/nvhdcp.h @@ -82,6 +82,8 @@ struct tegra_nvhdcp_packet { __u32 port; /* (OUT) DP or HDMI */ __u32 binfo; /* (OUT) link/repeater status for DP */ + + __u32 sor; /* (OUT) SOR or SOR1 */ }; /* parameters to TEGRAIO_NVHDCP_SET_POLICY */ -- cgit v1.2.2