diff options
author | Flora Fu <flora.fu@mediatek.com> | 2021-11-15 14:29:55 +0800 |
---|---|---|
committer | Hung-Te Lin <hungte@chromium.org> | 2021-11-16 08:00:47 +0000 |
commit | f3b2c157f561d8311f47474444166859df08d282 (patch) | |
tree | 80f1298af1b94c9cf08d6305aee4b2fb25b2eeee /src/soc | |
parent | 2ec91a37bcced48b5cbd7bf349dec38df0c3a58b (diff) |
soc/mediatek/mt8195: Add message string when using _Static_assert
The _Static_assert without message string is only available
since C++17. Add the message to avoid build fail in the macro.
BUG=b:203145462
BRANCH=cherry
TEST=build pass and boot pass
Signed-off-by: Flora Fu <flora.fu@mediatek.com>
Change-Id: Ib146ffafc21b9dbb9d383c9343a9ec1d7c478faf
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59298
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc')
-rw-r--r-- | src/soc/mediatek/mt8195/apusys_devapc.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/soc/mediatek/mt8195/apusys_devapc.c b/src/soc/mediatek/mt8195/apusys_devapc.c index cecbe47d4f..3e86289c28 100644 --- a/src/soc/mediatek/mt8195/apusys_devapc.c +++ b/src/soc/mediatek/mt8195/apusys_devapc.c @@ -43,7 +43,8 @@ static const struct apc_apu_dom_16 apusys_noc_dapc[] = { DAPC_APU_NOC_AO_SYS0_ATTR("slv04_05_06_07-2", NO_PROTECTION, FORBIDDEN15), DAPC_APU_NOC_AO_SYS0_ATTR("slv04_05_06_07-3", NO_PROTECTION, FORBIDDEN15), }; -_Static_assert(ARRAY_SIZE(apusys_noc_dapc) == APUSYS_NOC_DAPC_AO_SLAVE_NUM); +_Static_assert(ARRAY_SIZE(apusys_noc_dapc) == APUSYS_NOC_DAPC_AO_SLAVE_NUM, + "Wrong size on apusys_noc_dapc"); /* AO DAPC */ static const struct apc_apu_dom_16 apusys_ao_apc[] = { @@ -141,7 +142,8 @@ static const struct apc_apu_dom_16 apusys_ao_apc[] = { /* 70 */ DAPC_APU_AO_SYS0_ATTR("apb_infra_dbg_ctl", NO_PROTECTION, FORBIDDEN15), }; -_Static_assert(ARRAY_SIZE(apusys_ao_apc) == APUSYS_APC_SYS0_AO_SLAVE_NUM); +_Static_assert(ARRAY_SIZE(apusys_ao_apc) == APUSYS_APC_SYS0_AO_SLAVE_NUM, + "Wrong size on apusys_ao_apc"); static int set_slave_noc_dapc(u32 slave, enum domain_id domain_id, enum devapc_perm_type perm) { |