Stub out CMA alloc when running TVM

CMA alloc will not work on TVM. Stubbing out fastrpc_alloc_cma_memory
in fastrpc_init to prevent errors during loading.

Change-Id: I5774f1f0333da86582b9aca8b9cdeae725eaf64f
Signed-off-by: Anirudh Raghavendra <quic_araghave@quicinc.com>
This commit is contained in:
Anirudh Raghavendra
2023-02-28 11:46:41 -08:00
committed by Gerrit - the friendly Code Review server
parent 548f0d11ee
commit b6137ddc63

View File

@@ -8415,10 +8415,12 @@ static int __init fastrpc_device_init(void)
&me->channel[i].nb); &me->channel[i].nb);
if (i == CDSP_DOMAIN_ID) { if (i == CDSP_DOMAIN_ID) {
me->channel[i].dev = me->non_secure_dev; me->channel[i].dev = me->non_secure_dev;
#if !IS_ENABLED(CONFIG_MSM_ADSPRPC_TRUSTED)
err = fastrpc_alloc_cma_memory(&region_phys, err = fastrpc_alloc_cma_memory(&region_phys,
&region_vaddr, &region_vaddr,
MINI_DUMP_DBG_SIZE, MINI_DUMP_DBG_SIZE,
(unsigned long)attr); (unsigned long)attr);
#endif
if (err) if (err)
ADSPRPC_WARN("%s: CMA alloc failed err 0x%x\n", ADSPRPC_WARN("%s: CMA alloc failed err 0x%x\n",
__func__, err); __func__, err);