1/* 2 * Copyright (c) 2020-2021, Arm Limited. All rights reserved. 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 */ 6 7#ifndef _TFM_MAILBOX_CONFIG_ 8#define _TFM_MAILBOX_CONFIG_ 9 10/* 11 * \note Don't modify this file. Change the build configuration value 12 * and re-build TF-M SPE side to update the value. 13 */ 14 15/* Get number of mailbox queue slots from build configuration */ 16#cmakedefine NUM_MAILBOX_QUEUE_SLOT @NUM_MAILBOX_QUEUE_SLOT@ 17 18#ifndef NUM_MAILBOX_QUEUE_SLOT 19#define NUM_MAILBOX_QUEUE_SLOT 1 20#endif 21 22#if (NUM_MAILBOX_QUEUE_SLOT < 1) 23#error "Error: Invalid NUM_MAILBOX_QUEUE_SLOT. The value should be >= 1" 24#endif 25 26/* 27 * The number of slots should be no more than the number of bits in 28 * mailbox_queue_status_t. 29 * Here the value is hardcoded. A better way is to define a sizeof() to 30 * calculate the bits in mailbox_queue_status_t and dump it with pragma message. 31 */ 32#if (NUM_MAILBOX_QUEUE_SLOT > 32) 33#error "Error: Invalid NUM_MAILBOX_QUEUE_SLOT. The value should be <= 32" 34#endif 35 36#endif /* _TFM_MAILBOX_CONFIG_ */ 37