summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorPeter Zu <pzu@nvidia.com>2011-04-06 21:42:33 -0700
committerErik Gilling <konkers@android.com>2011-04-19 13:05:57 -0700
commit780073d7c4c001f78a5b3cd2d464ddd2f15c44e0 (patch)
treeb48bcb003f490b648ac42128703bab23eacb5b81 /drivers
parent9da0efab32e17025d50abc2913fa878358303b57 (diff)
video: tegra: dc: hdcp: handle the case of DEVICE_COUNT = 0 properly
When HDCP repeater has no device attached, DEVICE_COUNT reports back as 0. HDCP driver should handle this case as a good case and continue downstream authentication, other than fail it. Change-Id: Ied2e46428c0247f14fbd96016cd4fdbf358f6587
Diffstat (limited to 'drivers')
-rw-r--r--drivers/video/tegra/dc/nvhdcp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/video/tegra/dc/nvhdcp.c b/drivers/video/tegra/dc/nvhdcp.c
index 7c8869a563f5..5c2d9050a14b 100644
--- a/drivers/video/tegra/dc/nvhdcp.c
+++ b/drivers/video/tegra/dc/nvhdcp.c
@@ -354,6 +354,9 @@ static int get_ksvfifo(struct tegra_nvhdcp *nvhdcp,
if (!ksv_list || num_bksv_list > TEGRA_NVHDCP_MAX_DEVS)
return -EINVAL;
+ if (num_bksv_list == 0)
+ return 0;
+
buf = kmalloc(buf_len, GFP_KERNEL);
if (IS_ERR_OR_NULL(buf))
return -ENOMEM;