diff --git a/module/smt/src/mod_smt.c b/module/smt/src/mod_smt.c index 5505a84a8aab3417a28aba57270de5cd8380ed0a..a1682b7c08c3d21f488651d70fddbd689f0aa21a 100644 --- a/module/smt/src/mod_smt.c +++ b/module/smt/src/mod_smt.c @@ -282,8 +282,14 @@ static int smt_slave_handler(struct smt_channel_ctx *channel_ctx) out = channel_ctx->out; /* Check we have ownership of the mailbox */ - if (memory->status & MOD_SMT_MAILBOX_STATUS_FREE_MASK) + if (memory->status & MOD_SMT_MAILBOX_STATUS_FREE_MASK) { + smt_ctx.log_api->log( + MOD_LOG_GROUP_ERROR, + "[SMT] Mailbox ownership error on channel %u\n", + fwk_id_get_element_idx(channel_ctx->id)); + return FWK_E_STATE; + } /* Commit to sending a response */ channel_ctx->locked = true; diff --git a/module/system_power/include/mod_system_power.h b/module/system_power/include/mod_system_power.h index 8d114b680f2a204c7134a7e3cb2eaef2eb4b75ba..95c7382757f46b375635d2529a273bb132933599 100644 --- a/module/system_power/include/mod_system_power.h +++ b/module/system_power/include/mod_system_power.h @@ -95,16 +95,19 @@ struct mod_system_power_driver_api { * \brief API indices. */ enum mod_system_power_api_idx { +#if BUILD_HAS_MOD_SYSTEM_POWER /*! API index for the power domain driver API */ MOD_SYSTEM_POWER_API_IDX_PD_DRIVER, /*! API index for the power domain driver input API */ MOD_SYSTEM_POWER_API_IDX_PD_DRIVER_INPUT, +#endif /*! Number of exposed APIs */ MOD_SYSTEM_POWER_API_COUNT }; +#if BUILD_HAS_MOD_SYSTEM_POWER /*! Identifier of the power domain driver API */ static const fwk_id_t mod_system_power_api_id_pd_driver = FWK_ID_API_INIT(FWK_MODULE_IDX_SYSTEM_POWER, @@ -114,6 +117,7 @@ static const fwk_id_t mod_system_power_api_id_pd_driver = static const fwk_id_t mod_system_power_api_id_pd_driver_input = FWK_ID_API_INIT(FWK_MODULE_IDX_SYSTEM_POWER, MOD_SYSTEM_POWER_API_IDX_PD_DRIVER_INPUT); +#endif /*! * \}