diff --git a/include/drivers/arm/css/css_mhu_doorbell.h b/include/drivers/arm/css/css_mhu_doorbell.h index 88302fd7b..d6c1a2a81 100644 --- a/include/drivers/arm/css/css_mhu_doorbell.h +++ b/include/drivers/arm/css/css_mhu_doorbell.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014-2020, ARM Limited and Contributors. All rights reserved. + * Copyright (c) 2014-2024, Arm Limited and Contributors. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -22,6 +22,10 @@ #define SENDER_REG_STAT(_channel) (0x20 * (_channel)) #define SENDER_REG_SET(_channel) ((0x20 * (_channel)) + 0xC) +#define MHU_V3_PBX_PDBCW_PAGE_OFFSET UL(0x1000) +#define MHU_V3_SENDER_REG_SET(_channel) (MHU_V3_PBX_PDBCW_PAGE_OFFSET + \ + SENDER_REG_SET(_channel)) + /* Helper macro to ring doorbell */ #define MHU_RING_DOORBELL(addr, modify_mask, preserve_mask) do { \ uint32_t db = mmio_read_32(addr) & (preserve_mask); \ diff --git a/plat/arm/board/tc/tc_bl31_setup.c b/plat/arm/board/tc/tc_bl31_setup.c index 909a8b56a..d6b0311db 100644 --- a/plat/arm/board/tc/tc_bl31_setup.c +++ b/plat/arm/board/tc/tc_bl31_setup.c @@ -50,6 +50,7 @@ psa_status_t mbedtls_psa_external_get_random( } #endif /* PLATFORM_TEST_TFM_TESTSUITE */ +#if TARGET_PLATFORM <= 2 static scmi_channel_plat_info_t tc_scmi_plat_info = { .scmi_mbx_mem = CSS_SCMI_PAYLOAD_BASE, .db_reg_addr = PLAT_CSS_MHU_BASE + SENDER_REG_SET(0), @@ -57,6 +58,15 @@ static scmi_channel_plat_info_t tc_scmi_plat_info = { .db_modify_mask = 0x1, .ring_doorbell = &mhuv2_ring_doorbell, }; +#elif TARGET_PLATFORM == 3 +static scmi_channel_plat_info_t tc_scmi_plat_info = { + .scmi_mbx_mem = CSS_SCMI_PAYLOAD_BASE, + .db_reg_addr = PLAT_CSS_MHU_BASE + MHU_V3_SENDER_REG_SET(0), + .db_preserve_mask = 0xfffffffe, + .db_modify_mask = 0x1, + .ring_doorbell = &mhu_ring_doorbell, +}; +#endif void bl31_platform_setup(void) {