diff options
Diffstat (limited to 'product/rdn1e1/scp_ramfw/config_ppu_v1.c')
-rw-r--r-- | product/rdn1e1/scp_ramfw/config_ppu_v1.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/product/rdn1e1/scp_ramfw/config_ppu_v1.c b/product/rdn1e1/scp_ramfw/config_ppu_v1.c index a6e791a0..ba30cddc 100644 --- a/product/rdn1e1/scp_ramfw/config_ppu_v1.c +++ b/product/rdn1e1/scp_ramfw/config_ppu_v1.c @@ -65,6 +65,7 @@ static const struct fwk_element *ppu_v1_get_element_table(fwk_id_t module_id) unsigned int core_count; unsigned int cluster_count; unsigned int core_element_count = 0; + unsigned int idx = 0; core_count = rdn1e1_core_get_core_count(); cluster_count = rdn1e1_core_get_cluster_count(); @@ -90,6 +91,7 @@ static const struct fwk_element *ppu_v1_get_element_table(fwk_id_t module_id) return NULL; for (cluster_idx = 0; cluster_idx < cluster_count; cluster_idx++) { + idx = 0; for (core_idx = 0; core_idx < rdn1e1_core_get_core_per_cluster_count(cluster_idx); core_idx++) { @@ -105,8 +107,18 @@ static const struct fwk_element *ppu_v1_get_element_table(fwk_id_t module_id) element->data = pd_config; + if (core_count == 32) { + // Increment PPU REG BASE for even core_idx + if ((core_idx != 0) && (core_idx % 2 == 0)) { + idx = core_idx; + idx = idx - (idx/2); + } + pd_config->ppu.reg_base = SCP_PPU_CORE_BASE(cluster_idx, idx); + } else { + pd_config->ppu.reg_base = SCP_PPU_CORE_BASE(cluster_idx, core_idx); + } + pd_config->pd_type = MOD_PD_TYPE_CORE; - pd_config->ppu.reg_base = SCP_PPU_CORE_BASE(cluster_idx, core_idx); pd_config->ppu.irq = FWK_INTERRUPT_NONE; pd_config->cluster_id = FWK_ID_ELEMENT(FWK_MODULE_IDX_PPU_V1, |