kboot: Fix ISP remap on t8103/t8112

Signed-off-by: Asahi Lina <lina@asahilina.net>
This commit is contained in:
Asahi Lina 2023-09-30 15:23:24 +09:00 committed by Hector Martin
parent 0e471529cc
commit 182fddd31e
3 changed files with 12 additions and 1 deletions

View file

@ -34,6 +34,16 @@ int isp_get_heap(u64 *phys, u64 *iova, u64 *size)
return 0;
}
bool isp_uses_remap(void)
{
switch (chip_id) {
case 0x6020 ... 0x6fff:
return true;
default:
return false;
}
}
int isp_init(void)
{
int err = 0;

View file

@ -7,5 +7,6 @@
int isp_init(void);
int isp_get_heap(u64 *phys, u64 *iova, u64 *size);
bool isp_uses_remap(void);
#endif

View file

@ -2223,7 +2223,7 @@ int kboot_prepare_dt(void *fdt)
return -1;
if (dt_set_sio_fwdata())
return -1;
if (dt_reserve_asc_firmware("/arm-io/isp", "/arm-io/isp0", "isp", chip_id > 0x6020))
if (dt_reserve_asc_firmware("/arm-io/isp", "/arm-io/isp0", "isp", isp_uses_remap()))
return -1;
if (dt_set_isp_fwdata())
return -1;