hdmirx: fix hdcp2.2 error after resume [1/1]

PD#SWPL-15872

Problem:
ESM init failed after boot-up twice

Solution:
Use the correct HPI address when request_mem_region called.

Verify:
TL1 4g ddr

Change-Id: I5fd30166b3a36e5f4a12b8b6b893df9c9f20ddaf
Signed-off-by: yicheng shen <yicheng.shen@amlogic.com>
This commit is contained in:
yicheng shen
2019-10-16 16:46:59 +08:00
committed by Luke Go
parent 75848e4daf
commit 185e20ea60
2 changed files with 12 additions and 5 deletions

View File

@@ -211,9 +211,15 @@ static struct esm_device *alloc_esm_slot(
/* Check if we have a matching device (same HPI base) */
for (i = 0; i < MAX_ESM_DEVICES; i++) {
struct esm_device *slot = &esm_devices[i];
if ((slot->allocated) && (info->hpi_base) ==
(slot->hpi_resource->start))
/* Modified for SWPL-15872:
* when esm reboot,hpi_base will be the value defined
* in driver dts,not be hpi_resource->start,and it will
* not enter if(), and esm will use a new slot,
* and cause esm init fail.
*/
/* if ((slot->allocated) && (info->hpi_base) == */
/* (slot->hpi_resource->start)) */
if (slot->allocated)
return slot;
}
@@ -325,7 +331,8 @@ static long init(struct file *f, void __user *arg)
rc = alloc_dma_areas(esm, &info);
if (rc < 0)
goto err_free;
info.hpi_base =
reg_maps[MAP_ADDR_MODULE_HDMIRX_CAPB3].phy_addr;
hpi_mem = request_mem_region(info.hpi_base, 128, "esm-hpi");
if (!hpi_mem) {
rc = -EADDRNOTAVAIL;

View File

@@ -47,7 +47,7 @@
*
*
*/
#define RX_VER2 "ver.2019/11/01"
#define RX_VER2 "ver.2019/11/05"
/*print type*/
#define LOG_EN 0x01