Back to home page

LXR

 
 

    


File indexing completed on 2025-05-11 08:24:51

0001 /* SPDX-License-Identifier: BSD-2-Clause */
0002 
0003 /**
0004  * @file
0005  *
0006  * @ingroup RtemsMessageReqConstruct
0007  */
0008 
0009 /*
0010  * Copyright (C) 2020, 2021 embedded brains GmbH & Co. KG
0011  *
0012  * Redistribution and use in source and binary forms, with or without
0013  * modification, are permitted provided that the following conditions
0014  * are met:
0015  * 1. Redistributions of source code must retain the above copyright
0016  *    notice, this list of conditions and the following disclaimer.
0017  * 2. Redistributions in binary form must reproduce the above copyright
0018  *    notice, this list of conditions and the following disclaimer in the
0019  *    documentation and/or other materials provided with the distribution.
0020  *
0021  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
0022  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
0023  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
0024  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
0025  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
0026  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
0027  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
0028  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
0029  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
0030  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
0031  * POSSIBILITY OF SUCH DAMAGE.
0032  */
0033 
0034 /*
0035  * This file is part of the RTEMS quality process and was automatically
0036  * generated.  If you find something that needs to be fixed or
0037  * worded better please post a report or patch to an RTEMS mailing list
0038  * or raise a bug report:
0039  *
0040  * https://www.rtems.org/bugs.html
0041  *
0042  * For information on updating and regenerating please refer to the How-To
0043  * section in the Software Requirements Engineering chapter of the
0044  * RTEMS Software Engineering manual.  The manual is provided as a part of
0045  * a release.  For development sources please refer to the online
0046  * documentation at:
0047  *
0048  * https://docs.rtems.org
0049  */
0050 
0051 #ifdef HAVE_CONFIG_H
0052 #include "config.h"
0053 #endif
0054 
0055 #include <rtems.h>
0056 #include <string.h>
0057 
0058 #include "tx-support.h"
0059 
0060 #include <rtems/test.h>
0061 
0062 /**
0063  * @defgroup RtemsMessageReqConstruct spec:/rtems/message/req/construct
0064  *
0065  * @ingroup TestsuitesValidationNoClock0
0066  *
0067  * @{
0068  */
0069 
0070 typedef enum {
0071   RtemsMessageReqConstruct_Pre_Config_Valid,
0072   RtemsMessageReqConstruct_Pre_Config_Null,
0073   RtemsMessageReqConstruct_Pre_Config_NA
0074 } RtemsMessageReqConstruct_Pre_Config;
0075 
0076 typedef enum {
0077   RtemsMessageReqConstruct_Pre_Name_Valid,
0078   RtemsMessageReqConstruct_Pre_Name_Invalid,
0079   RtemsMessageReqConstruct_Pre_Name_NA
0080 } RtemsMessageReqConstruct_Pre_Name;
0081 
0082 typedef enum {
0083   RtemsMessageReqConstruct_Pre_Id_Id,
0084   RtemsMessageReqConstruct_Pre_Id_Null,
0085   RtemsMessageReqConstruct_Pre_Id_NA
0086 } RtemsMessageReqConstruct_Pre_Id;
0087 
0088 typedef enum {
0089   RtemsMessageReqConstruct_Pre_MaxPending_Valid,
0090   RtemsMessageReqConstruct_Pre_MaxPending_Zero,
0091   RtemsMessageReqConstruct_Pre_MaxPending_Big,
0092   RtemsMessageReqConstruct_Pre_MaxPending_NA
0093 } RtemsMessageReqConstruct_Pre_MaxPending;
0094 
0095 typedef enum {
0096   RtemsMessageReqConstruct_Pre_MaxSize_Valid,
0097   RtemsMessageReqConstruct_Pre_MaxSize_Zero,
0098   RtemsMessageReqConstruct_Pre_MaxSize_Big,
0099   RtemsMessageReqConstruct_Pre_MaxSize_NA
0100 } RtemsMessageReqConstruct_Pre_MaxSize;
0101 
0102 typedef enum {
0103   RtemsMessageReqConstruct_Pre_Free_Yes,
0104   RtemsMessageReqConstruct_Pre_Free_No,
0105   RtemsMessageReqConstruct_Pre_Free_NA
0106 } RtemsMessageReqConstruct_Pre_Free;
0107 
0108 typedef enum {
0109   RtemsMessageReqConstruct_Pre_Area_Valid,
0110   RtemsMessageReqConstruct_Pre_Area_Null,
0111   RtemsMessageReqConstruct_Pre_Area_NA
0112 } RtemsMessageReqConstruct_Pre_Area;
0113 
0114 typedef enum {
0115   RtemsMessageReqConstruct_Pre_AreaSize_Valid,
0116   RtemsMessageReqConstruct_Pre_AreaSize_Invalid,
0117   RtemsMessageReqConstruct_Pre_AreaSize_NA
0118 } RtemsMessageReqConstruct_Pre_AreaSize;
0119 
0120 typedef enum {
0121   RtemsMessageReqConstruct_Pre_StorageFree_Null,
0122   RtemsMessageReqConstruct_Pre_StorageFree_Handler,
0123   RtemsMessageReqConstruct_Pre_StorageFree_NA
0124 } RtemsMessageReqConstruct_Pre_StorageFree;
0125 
0126 typedef enum {
0127   RtemsMessageReqConstruct_Post_Status_Ok,
0128   RtemsMessageReqConstruct_Post_Status_InvAddr,
0129   RtemsMessageReqConstruct_Post_Status_InvName,
0130   RtemsMessageReqConstruct_Post_Status_InvNum,
0131   RtemsMessageReqConstruct_Post_Status_InvSize,
0132   RtemsMessageReqConstruct_Post_Status_TooMany,
0133   RtemsMessageReqConstruct_Post_Status_Unsat,
0134   RtemsMessageReqConstruct_Post_Status_NA
0135 } RtemsMessageReqConstruct_Post_Status;
0136 
0137 typedef enum {
0138   RtemsMessageReqConstruct_Post_Name_Valid,
0139   RtemsMessageReqConstruct_Post_Name_Invalid,
0140   RtemsMessageReqConstruct_Post_Name_NA
0141 } RtemsMessageReqConstruct_Post_Name;
0142 
0143 typedef enum {
0144   RtemsMessageReqConstruct_Post_IdObj_Set,
0145   RtemsMessageReqConstruct_Post_IdObj_Nop,
0146   RtemsMessageReqConstruct_Post_IdObj_NA
0147 } RtemsMessageReqConstruct_Post_IdObj;
0148 
0149 typedef enum {
0150   RtemsMessageReqConstruct_Post_StorageFree_Free,
0151   RtemsMessageReqConstruct_Post_StorageFree_Nop,
0152   RtemsMessageReqConstruct_Post_StorageFree_NA
0153 } RtemsMessageReqConstruct_Post_StorageFree;
0154 
0155 typedef struct {
0156   uint32_t Skip : 1;
0157   uint32_t Pre_Config_NA : 1;
0158   uint32_t Pre_Name_NA : 1;
0159   uint32_t Pre_Id_NA : 1;
0160   uint32_t Pre_MaxPending_NA : 1;
0161   uint32_t Pre_MaxSize_NA : 1;
0162   uint32_t Pre_Free_NA : 1;
0163   uint32_t Pre_Area_NA : 1;
0164   uint32_t Pre_AreaSize_NA : 1;
0165   uint32_t Pre_StorageFree_NA : 1;
0166   uint32_t Post_Status : 3;
0167   uint32_t Post_Name : 2;
0168   uint32_t Post_IdObj : 2;
0169   uint32_t Post_StorageFree : 2;
0170 } RtemsMessageReqConstruct_Entry;
0171 
0172 /**
0173  * @brief Test context for spec:/rtems/message/req/construct test case.
0174  */
0175 typedef struct {
0176   rtems_status_code status;
0177 
0178   const rtems_message_queue_config *config;
0179 
0180   rtems_message_queue_config config_obj;
0181 
0182   rtems_id *id;
0183 
0184   rtems_id id_obj;
0185 
0186   void *seized_objects;
0187 
0188   uint32_t storage_free_counter;
0189 
0190   uint32_t expected_storage_free_counter;
0191 
0192   struct {
0193     /**
0194      * @brief This member defines the pre-condition states for the next action.
0195      */
0196     size_t pcs[ 9 ];
0197 
0198     /**
0199      * @brief If this member is true, then the test action loop is executed.
0200      */
0201     bool in_action_loop;
0202 
0203     /**
0204      * @brief This member contains the next transition map index.
0205      */
0206     size_t index;
0207 
0208     /**
0209      * @brief This member contains the current transition map entry.
0210      */
0211     RtemsMessageReqConstruct_Entry entry;
0212 
0213     /**
0214      * @brief If this member is true, then the current transition variant
0215      *   should be skipped.
0216      */
0217     bool skip;
0218   } Map;
0219 } RtemsMessageReqConstruct_Context;
0220 
0221 static RtemsMessageReqConstruct_Context
0222   RtemsMessageReqConstruct_Instance;
0223 
0224 static const char * const RtemsMessageReqConstruct_PreDesc_Config[] = {
0225   "Valid",
0226   "Null",
0227   "NA"
0228 };
0229 
0230 static const char * const RtemsMessageReqConstruct_PreDesc_Name[] = {
0231   "Valid",
0232   "Invalid",
0233   "NA"
0234 };
0235 
0236 static const char * const RtemsMessageReqConstruct_PreDesc_Id[] = {
0237   "Id",
0238   "Null",
0239   "NA"
0240 };
0241 
0242 static const char * const RtemsMessageReqConstruct_PreDesc_MaxPending[] = {
0243   "Valid",
0244   "Zero",
0245   "Big",
0246   "NA"
0247 };
0248 
0249 static const char * const RtemsMessageReqConstruct_PreDesc_MaxSize[] = {
0250   "Valid",
0251   "Zero",
0252   "Big",
0253   "NA"
0254 };
0255 
0256 static const char * const RtemsMessageReqConstruct_PreDesc_Free[] = {
0257   "Yes",
0258   "No",
0259   "NA"
0260 };
0261 
0262 static const char * const RtemsMessageReqConstruct_PreDesc_Area[] = {
0263   "Valid",
0264   "Null",
0265   "NA"
0266 };
0267 
0268 static const char * const RtemsMessageReqConstruct_PreDesc_AreaSize[] = {
0269   "Valid",
0270   "Invalid",
0271   "NA"
0272 };
0273 
0274 static const char * const RtemsMessageReqConstruct_PreDesc_StorageFree[] = {
0275   "Null",
0276   "Handler",
0277   "NA"
0278 };
0279 
0280 static const char * const * const RtemsMessageReqConstruct_PreDesc[] = {
0281   RtemsMessageReqConstruct_PreDesc_Config,
0282   RtemsMessageReqConstruct_PreDesc_Name,
0283   RtemsMessageReqConstruct_PreDesc_Id,
0284   RtemsMessageReqConstruct_PreDesc_MaxPending,
0285   RtemsMessageReqConstruct_PreDesc_MaxSize,
0286   RtemsMessageReqConstruct_PreDesc_Free,
0287   RtemsMessageReqConstruct_PreDesc_Area,
0288   RtemsMessageReqConstruct_PreDesc_AreaSize,
0289   RtemsMessageReqConstruct_PreDesc_StorageFree,
0290   NULL
0291 };
0292 
0293 #define NAME rtems_build_name( 'T', 'E', 'S', 'T' )
0294 
0295 #define MAX_MESSAGE_QUEUES 4
0296 
0297 #define MAX_PENDING_MESSAGES 1
0298 
0299 #define MAX_MESSAGE_SIZE 1
0300 
0301 typedef RtemsMessageReqConstruct_Context Context;
0302 
0303 static RTEMS_MESSAGE_QUEUE_BUFFER( MAX_MESSAGE_SIZE )
0304   buffers_to_seize[ MAX_MESSAGE_QUEUES ][ MAX_PENDING_MESSAGES ];
0305 
0306 static RTEMS_MESSAGE_QUEUE_BUFFER( MAX_MESSAGE_SIZE )
0307   buffers[ MAX_PENDING_MESSAGES ];
0308 
0309 static rtems_status_code Create( void *arg, uint32_t *id )
0310 {
0311   rtems_message_queue_config config;
0312   size_t                    *i;
0313 
0314   i = arg;
0315   T_quiet_lt_sz( *i, MAX_MESSAGE_QUEUES );
0316 
0317   memset( &config, 0, sizeof( config ) );
0318   config.name = rtems_build_name( 'S', 'I', 'Z', 'E' );
0319   config.maximum_pending_messages = MAX_PENDING_MESSAGES;
0320   config.maximum_message_size = MAX_MESSAGE_SIZE;
0321   config.storage_size = sizeof( buffers_to_seize[ *i ] );
0322   config.storage_area = buffers_to_seize[ *i ];
0323   config.attributes = RTEMS_DEFAULT_ATTRIBUTES;
0324 
0325   ++(*i);
0326 
0327   return rtems_message_queue_construct( &config, id );
0328 }
0329 
0330 static void StorageFree( void *ptr )
0331 {
0332   Context *ctx;
0333 
0334   ctx = T_fixture_context();
0335   T_eq_ptr( ptr, buffers );
0336   ++ctx->storage_free_counter;
0337 }
0338 
0339 static void RtemsMessageReqConstruct_Pre_Config_Prepare(
0340   RtemsMessageReqConstruct_Context   *ctx,
0341   RtemsMessageReqConstruct_Pre_Config state
0342 )
0343 {
0344   switch ( state ) {
0345     case RtemsMessageReqConstruct_Pre_Config_Valid: {
0346       /*
0347        * While the ``config`` parameter references an object of type
0348        * rtems_message_queue_config.
0349        */
0350       ctx->config = &ctx->config_obj;
0351       break;
0352     }
0353 
0354     case RtemsMessageReqConstruct_Pre_Config_Null: {
0355       /*
0356        * While the ``config`` parameter is NULL.
0357        */
0358       ctx->config = NULL;
0359       break;
0360     }
0361 
0362     case RtemsMessageReqConstruct_Pre_Config_NA:
0363       break;
0364   }
0365 }
0366 
0367 static void RtemsMessageReqConstruct_Pre_Name_Prepare(
0368   RtemsMessageReqConstruct_Context *ctx,
0369   RtemsMessageReqConstruct_Pre_Name state
0370 )
0371 {
0372   switch ( state ) {
0373     case RtemsMessageReqConstruct_Pre_Name_Valid: {
0374       /*
0375        * While the name of the message queue configuration is valid.
0376        */
0377       ctx->config_obj.name = NAME;
0378       break;
0379     }
0380 
0381     case RtemsMessageReqConstruct_Pre_Name_Invalid: {
0382       /*
0383        * While the name of the message queue configuration is invalid.
0384        */
0385       ctx->config_obj.name = 0;
0386       break;
0387     }
0388 
0389     case RtemsMessageReqConstruct_Pre_Name_NA:
0390       break;
0391   }
0392 }
0393 
0394 static void RtemsMessageReqConstruct_Pre_Id_Prepare(
0395   RtemsMessageReqConstruct_Context *ctx,
0396   RtemsMessageReqConstruct_Pre_Id   state
0397 )
0398 {
0399   switch ( state ) {
0400     case RtemsMessageReqConstruct_Pre_Id_Id: {
0401       /*
0402        * While the ``id`` parameter references an object of type rtems_id.
0403        */
0404       ctx->id = &ctx->id_obj;
0405       break;
0406     }
0407 
0408     case RtemsMessageReqConstruct_Pre_Id_Null: {
0409       /*
0410        * While the ``id`` parameter is NULL.
0411        */
0412       ctx->id = NULL;
0413       break;
0414     }
0415 
0416     case RtemsMessageReqConstruct_Pre_Id_NA:
0417       break;
0418   }
0419 }
0420 
0421 static void RtemsMessageReqConstruct_Pre_MaxPending_Prepare(
0422   RtemsMessageReqConstruct_Context       *ctx,
0423   RtemsMessageReqConstruct_Pre_MaxPending state
0424 )
0425 {
0426   switch ( state ) {
0427     case RtemsMessageReqConstruct_Pre_MaxPending_Valid: {
0428       /*
0429        * While the maximum number of pending messages of the message queue
0430        * configuration is valid.
0431        */
0432       ctx->config_obj.maximum_pending_messages = MAX_PENDING_MESSAGES;
0433       break;
0434     }
0435 
0436     case RtemsMessageReqConstruct_Pre_MaxPending_Zero: {
0437       /*
0438        * While the maximum number of pending messages of the message queue
0439        * configuration is zero.
0440        */
0441       ctx->config_obj.maximum_pending_messages = 0;
0442       break;
0443     }
0444 
0445     case RtemsMessageReqConstruct_Pre_MaxPending_Big: {
0446       /*
0447        * While the maximum number of pending messages of the message queue
0448        * configuration is big enough so that a calculation to get the message
0449        * buffer storage area size overflows.
0450        */
0451       ctx->config_obj.maximum_pending_messages = UINT32_MAX;
0452       break;
0453     }
0454 
0455     case RtemsMessageReqConstruct_Pre_MaxPending_NA:
0456       break;
0457   }
0458 }
0459 
0460 static void RtemsMessageReqConstruct_Pre_MaxSize_Prepare(
0461   RtemsMessageReqConstruct_Context    *ctx,
0462   RtemsMessageReqConstruct_Pre_MaxSize state
0463 )
0464 {
0465   switch ( state ) {
0466     case RtemsMessageReqConstruct_Pre_MaxSize_Valid: {
0467       /*
0468        * While the maximum message size of the message queue configuration is
0469        * valid.
0470        */
0471       if ( ctx->config_obj.maximum_pending_messages == UINT32_MAX ) {
0472         /*
0473          * At least on 64-bit systems we need a bit of help to ensure that we
0474          * meet the Big state of the MaxPending pre-condition.  The following
0475          * message size is valid with respect to calculations involving only
0476          * the message size.
0477          */
0478         ctx->config_obj.maximum_message_size = SIZE_MAX - sizeof( uintptr_t ) +
0479           1 - sizeof( CORE_message_queue_Buffer );
0480       } else {
0481         ctx->config_obj.maximum_message_size = MAX_MESSAGE_SIZE;
0482       }
0483       break;
0484     }
0485 
0486     case RtemsMessageReqConstruct_Pre_MaxSize_Zero: {
0487       /*
0488        * While the maximum message size of the message queue configuration is
0489        * zero.
0490        */
0491       ctx->config_obj.maximum_message_size = 0;
0492       break;
0493     }
0494 
0495     case RtemsMessageReqConstruct_Pre_MaxSize_Big: {
0496       /*
0497        * While the maximum message size of the message queue configuration is
0498        * big enough so that a calculation to get the message buffer storage
0499        * area size overflows.
0500        */
0501       ctx->config_obj.maximum_message_size = SIZE_MAX;
0502       break;
0503     }
0504 
0505     case RtemsMessageReqConstruct_Pre_MaxSize_NA:
0506       break;
0507   }
0508 }
0509 
0510 static void RtemsMessageReqConstruct_Pre_Free_Prepare(
0511   RtemsMessageReqConstruct_Context *ctx,
0512   RtemsMessageReqConstruct_Pre_Free state
0513 )
0514 {
0515   size_t i;
0516 
0517   switch ( state ) {
0518     case RtemsMessageReqConstruct_Pre_Free_Yes: {
0519       /*
0520        * While the system has at least one inactive message queue object
0521        * available.
0522        */
0523       /* Nothing to do */
0524       break;
0525     }
0526 
0527     case RtemsMessageReqConstruct_Pre_Free_No: {
0528       /*
0529        * While the system has no inactive message queue object available.
0530        */
0531       i = 0;
0532       ctx->seized_objects = T_seize_objects( Create, &i );
0533       break;
0534     }
0535 
0536     case RtemsMessageReqConstruct_Pre_Free_NA:
0537       break;
0538   }
0539 }
0540 
0541 static void RtemsMessageReqConstruct_Pre_Area_Prepare(
0542   RtemsMessageReqConstruct_Context *ctx,
0543   RtemsMessageReqConstruct_Pre_Area state
0544 )
0545 {
0546   switch ( state ) {
0547     case RtemsMessageReqConstruct_Pre_Area_Valid: {
0548       /*
0549        * While the message buffer storage area begin pointer of the message
0550        * queue configuration is valid.
0551        */
0552       ctx->config_obj.storage_area = buffers;
0553       break;
0554     }
0555 
0556     case RtemsMessageReqConstruct_Pre_Area_Null: {
0557       /*
0558        * While the message buffer storage area begin pointer of the message
0559        * queue configuration is NULL.
0560        */
0561       ctx->config_obj.storage_area = NULL;
0562       break;
0563     }
0564 
0565     case RtemsMessageReqConstruct_Pre_Area_NA:
0566       break;
0567   }
0568 }
0569 
0570 static void RtemsMessageReqConstruct_Pre_AreaSize_Prepare(
0571   RtemsMessageReqConstruct_Context     *ctx,
0572   RtemsMessageReqConstruct_Pre_AreaSize state
0573 )
0574 {
0575   switch ( state ) {
0576     case RtemsMessageReqConstruct_Pre_AreaSize_Valid: {
0577       /*
0578        * While the message buffer storage area size of the message queue
0579        * configuration is valid.
0580        */
0581       ctx->config_obj.storage_size = sizeof( buffers );
0582       break;
0583     }
0584 
0585     case RtemsMessageReqConstruct_Pre_AreaSize_Invalid: {
0586       /*
0587        * While the message buffer storage area size of the message queue
0588        * configuration is invalid.
0589        */
0590       ctx->config_obj.storage_size = SIZE_MAX;
0591       break;
0592     }
0593 
0594     case RtemsMessageReqConstruct_Pre_AreaSize_NA:
0595       break;
0596   }
0597 }
0598 
0599 static void RtemsMessageReqConstruct_Pre_StorageFree_Prepare(
0600   RtemsMessageReqConstruct_Context        *ctx,
0601   RtemsMessageReqConstruct_Pre_StorageFree state
0602 )
0603 {
0604   switch ( state ) {
0605     case RtemsMessageReqConstruct_Pre_StorageFree_Null: {
0606       /*
0607        * While the storage free member of the message queue configuration is
0608        * equal to NULL.
0609        */
0610       ctx->config_obj.storage_free = NULL;
0611       break;
0612     }
0613 
0614     case RtemsMessageReqConstruct_Pre_StorageFree_Handler: {
0615       /*
0616        * While the storage free member of the message queue configuration
0617        * references a storage free handler.
0618        */
0619       ctx->config_obj.storage_free = StorageFree;
0620       break;
0621     }
0622 
0623     case RtemsMessageReqConstruct_Pre_StorageFree_NA:
0624       break;
0625   }
0626 }
0627 
0628 static void RtemsMessageReqConstruct_Post_Status_Check(
0629   RtemsMessageReqConstruct_Context    *ctx,
0630   RtemsMessageReqConstruct_Post_Status state
0631 )
0632 {
0633   switch ( state ) {
0634     case RtemsMessageReqConstruct_Post_Status_Ok: {
0635       /*
0636        * The return status of rtems_message_queue_construct() shall be
0637        * RTEMS_SUCCESSFUL.
0638        */
0639       T_rsc_success( ctx->status );
0640       break;
0641     }
0642 
0643     case RtemsMessageReqConstruct_Post_Status_InvAddr: {
0644       /*
0645        * The return status of rtems_message_queue_construct() shall be
0646        * RTEMS_INVALID_ADDRESS.
0647        */
0648       T_rsc( ctx->status, RTEMS_INVALID_ADDRESS );
0649       break;
0650     }
0651 
0652     case RtemsMessageReqConstruct_Post_Status_InvName: {
0653       /*
0654        * The return status of rtems_message_queue_construct() shall be
0655        * RTEMS_INVALID_NAME.
0656        */
0657       T_rsc( ctx->status, RTEMS_INVALID_NAME );
0658       break;
0659     }
0660 
0661     case RtemsMessageReqConstruct_Post_Status_InvNum: {
0662       /*
0663        * The return status of rtems_message_queue_construct() shall be
0664        * RTEMS_INVALID_NUMBER.
0665        */
0666       T_rsc( ctx->status, RTEMS_INVALID_NUMBER );
0667       break;
0668     }
0669 
0670     case RtemsMessageReqConstruct_Post_Status_InvSize: {
0671       /*
0672        * The return status of rtems_message_queue_construct() shall be
0673        * RTEMS_INVALID_SIZE.
0674        */
0675       T_rsc( ctx->status, RTEMS_INVALID_SIZE );
0676       break;
0677     }
0678 
0679     case RtemsMessageReqConstruct_Post_Status_TooMany: {
0680       /*
0681        * The return status of rtems_message_queue_construct() shall be
0682        * RTEMS_TOO_MANY.
0683        */
0684       T_rsc( ctx->status, RTEMS_TOO_MANY );
0685       break;
0686     }
0687 
0688     case RtemsMessageReqConstruct_Post_Status_Unsat: {
0689       /*
0690        * The return status of rtems_message_queue_construct() shall be
0691        * RTEMS_UNSATISFIED.
0692        */
0693       T_rsc( ctx->status, RTEMS_UNSATISFIED  );
0694       break;
0695     }
0696 
0697     case RtemsMessageReqConstruct_Post_Status_NA:
0698       break;
0699   }
0700 }
0701 
0702 static void RtemsMessageReqConstruct_Post_Name_Check(
0703   RtemsMessageReqConstruct_Context  *ctx,
0704   RtemsMessageReqConstruct_Post_Name state
0705 )
0706 {
0707   rtems_status_code sc;
0708   rtems_id          id;
0709 
0710   switch ( state ) {
0711     case RtemsMessageReqConstruct_Post_Name_Valid: {
0712       /*
0713        * The unique object name shall identify the message queue constructed by
0714        * the rtems_message_queue_construct() call.
0715        */
0716       id = 0;
0717       sc = rtems_message_queue_ident( NAME, RTEMS_SEARCH_LOCAL_NODE, &id );
0718       T_rsc_success( sc );
0719       T_eq_u32( id, ctx->id_obj );
0720       break;
0721     }
0722 
0723     case RtemsMessageReqConstruct_Post_Name_Invalid: {
0724       /*
0725        * The unique object name shall not identify a message queue.
0726        */
0727       sc = rtems_message_queue_ident( NAME, RTEMS_SEARCH_LOCAL_NODE, &id );
0728       T_rsc( sc, RTEMS_INVALID_NAME );
0729       break;
0730     }
0731 
0732     case RtemsMessageReqConstruct_Post_Name_NA:
0733       break;
0734   }
0735 }
0736 
0737 static void RtemsMessageReqConstruct_Post_IdObj_Check(
0738   RtemsMessageReqConstruct_Context   *ctx,
0739   RtemsMessageReqConstruct_Post_IdObj state
0740 )
0741 {
0742   switch ( state ) {
0743     case RtemsMessageReqConstruct_Post_IdObj_Set: {
0744       /*
0745        * The value of the object referenced by the ``id`` parameter shall be
0746        * set to the object identifier of the constructed message queue after
0747        * the return of the rtems_message_queue_construct() call.
0748        */
0749       T_eq_ptr( ctx->id, &ctx->id_obj );
0750       T_ne_u32( ctx->id_obj, INVALID_ID );
0751       break;
0752     }
0753 
0754     case RtemsMessageReqConstruct_Post_IdObj_Nop: {
0755       /*
0756        * Objects referenced by the ``id`` parameter in past calls to
0757        * rtems_message_queue_construct() shall not be accessed by the
0758        * rtems_message_queue_construct() call.
0759        */
0760       T_eq_u32( ctx->id_obj, INVALID_ID );
0761       break;
0762     }
0763 
0764     case RtemsMessageReqConstruct_Post_IdObj_NA:
0765       break;
0766   }
0767 }
0768 
0769 static void RtemsMessageReqConstruct_Post_StorageFree_Check(
0770   RtemsMessageReqConstruct_Context         *ctx,
0771   RtemsMessageReqConstruct_Post_StorageFree state
0772 )
0773 {
0774   switch ( state ) {
0775     case RtemsMessageReqConstruct_Post_StorageFree_Free: {
0776       /*
0777        * The storage free handler of the message queue configuration specified
0778        * by the ``config`` parameter shall be used to free the message queue
0779        * storage area.
0780        */
0781       ctx->expected_storage_free_counter = 1;
0782       break;
0783     }
0784 
0785     case RtemsMessageReqConstruct_Post_StorageFree_Nop: {
0786       /*
0787        * No operation shall be performed to free the message queue storage
0788        * area.
0789        */
0790       ctx->expected_storage_free_counter = 0;
0791       break;
0792     }
0793 
0794     case RtemsMessageReqConstruct_Post_StorageFree_NA:
0795       break;
0796   }
0797 }
0798 
0799 static void RtemsMessageReqConstruct_Prepare(
0800   RtemsMessageReqConstruct_Context *ctx
0801 )
0802 {
0803   ctx->id_obj = INVALID_ID;
0804   ctx->storage_free_counter = 0;
0805   ctx->expected_storage_free_counter = UINT32_MAX;
0806   memset( &ctx->config_obj, 0, sizeof( ctx->config_obj ) );
0807 }
0808 
0809 static void RtemsMessageReqConstruct_Action(
0810   RtemsMessageReqConstruct_Context *ctx
0811 )
0812 {
0813   ctx->status = rtems_message_queue_construct( ctx->config, ctx->id );
0814 }
0815 
0816 static void RtemsMessageReqConstruct_Cleanup(
0817   RtemsMessageReqConstruct_Context *ctx
0818 )
0819 {
0820   if ( ctx->id_obj != INVALID_ID ) {
0821     rtems_status_code sc;
0822 
0823     sc = rtems_message_queue_delete( ctx->id_obj );
0824     T_rsc_success( sc );
0825 
0826     T_eq_u32( ctx->storage_free_counter, ctx->expected_storage_free_counter );
0827   } else {
0828     T_eq_u32( ctx->storage_free_counter, 0 );
0829   }
0830 
0831   T_surrender_objects( &ctx->seized_objects, rtems_message_queue_delete );
0832 }
0833 
0834 static const RtemsMessageReqConstruct_Entry
0835 RtemsMessageReqConstruct_Entries[] = {
0836   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_InvAddr,
0837     RtemsMessageReqConstruct_Post_Name_Invalid,
0838     RtemsMessageReqConstruct_Post_IdObj_Nop,
0839     RtemsMessageReqConstruct_Post_StorageFree_NA },
0840   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_InvName,
0841     RtemsMessageReqConstruct_Post_Name_Invalid,
0842     RtemsMessageReqConstruct_Post_IdObj_Nop,
0843     RtemsMessageReqConstruct_Post_StorageFree_NA },
0844   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_InvNum,
0845     RtemsMessageReqConstruct_Post_Name_Invalid,
0846     RtemsMessageReqConstruct_Post_IdObj_Nop,
0847     RtemsMessageReqConstruct_Post_StorageFree_NA },
0848   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_InvSize,
0849     RtemsMessageReqConstruct_Post_Name_Invalid,
0850     RtemsMessageReqConstruct_Post_IdObj_Nop,
0851     RtemsMessageReqConstruct_Post_StorageFree_NA },
0852   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_TooMany,
0853     RtemsMessageReqConstruct_Post_Name_Invalid,
0854     RtemsMessageReqConstruct_Post_IdObj_Nop,
0855     RtemsMessageReqConstruct_Post_StorageFree_NA },
0856   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_Unsat,
0857     RtemsMessageReqConstruct_Post_Name_Invalid,
0858     RtemsMessageReqConstruct_Post_IdObj_Nop,
0859     RtemsMessageReqConstruct_Post_StorageFree_NA },
0860   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_Ok,
0861     RtemsMessageReqConstruct_Post_Name_Valid,
0862     RtemsMessageReqConstruct_Post_IdObj_Set,
0863     RtemsMessageReqConstruct_Post_StorageFree_Nop },
0864   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, RtemsMessageReqConstruct_Post_Status_Ok,
0865     RtemsMessageReqConstruct_Post_Name_Valid,
0866     RtemsMessageReqConstruct_Post_IdObj_Set,
0867     RtemsMessageReqConstruct_Post_StorageFree_Free }
0868 };
0869 
0870 static const uint8_t
0871 RtemsMessageReqConstruct_Map[] = {
0872   6, 7, 5, 5, 5, 5, 5, 5, 4, 4, 4, 4, 4, 4, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
0873   3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 2, 2, 2, 2,
0874   2, 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0912   0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0913   0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0914   0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0915   0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0916   0, 0, 0, 0, 0, 0, 0, 0
0917 };
0918 
0919 static size_t RtemsMessageReqConstruct_Scope( void *arg, char *buf, size_t n )
0920 {
0921   RtemsMessageReqConstruct_Context *ctx;
0922 
0923   ctx = arg;
0924 
0925   if ( ctx->Map.in_action_loop ) {
0926     return T_get_scope(
0927       RtemsMessageReqConstruct_PreDesc,
0928       buf,
0929       n,
0930       ctx->Map.pcs
0931     );
0932   }
0933 
0934   return 0;
0935 }
0936 
0937 static T_fixture RtemsMessageReqConstruct_Fixture = {
0938   .setup = NULL,
0939   .stop = NULL,
0940   .teardown = NULL,
0941   .scope = RtemsMessageReqConstruct_Scope,
0942   .initial_context = &RtemsMessageReqConstruct_Instance
0943 };
0944 
0945 static inline RtemsMessageReqConstruct_Entry RtemsMessageReqConstruct_PopEntry(
0946   RtemsMessageReqConstruct_Context *ctx
0947 )
0948 {
0949   size_t index;
0950 
0951   index = ctx->Map.index;
0952   ctx->Map.index = index + 1;
0953   return RtemsMessageReqConstruct_Entries[
0954     RtemsMessageReqConstruct_Map[ index ]
0955   ];
0956 }
0957 
0958 static void RtemsMessageReqConstruct_TestVariant(
0959   RtemsMessageReqConstruct_Context *ctx
0960 )
0961 {
0962   RtemsMessageReqConstruct_Pre_Config_Prepare( ctx, ctx->Map.pcs[ 0 ] );
0963   RtemsMessageReqConstruct_Pre_Name_Prepare( ctx, ctx->Map.pcs[ 1 ] );
0964   RtemsMessageReqConstruct_Pre_Id_Prepare( ctx, ctx->Map.pcs[ 2 ] );
0965   RtemsMessageReqConstruct_Pre_MaxPending_Prepare( ctx, ctx->Map.pcs[ 3 ] );
0966   RtemsMessageReqConstruct_Pre_MaxSize_Prepare( ctx, ctx->Map.pcs[ 4 ] );
0967   RtemsMessageReqConstruct_Pre_Free_Prepare( ctx, ctx->Map.pcs[ 5 ] );
0968   RtemsMessageReqConstruct_Pre_Area_Prepare( ctx, ctx->Map.pcs[ 6 ] );
0969   RtemsMessageReqConstruct_Pre_AreaSize_Prepare( ctx, ctx->Map.pcs[ 7 ] );
0970   RtemsMessageReqConstruct_Pre_StorageFree_Prepare( ctx, ctx->Map.pcs[ 8 ] );
0971   RtemsMessageReqConstruct_Action( ctx );
0972   RtemsMessageReqConstruct_Post_Status_Check(
0973     ctx,
0974     ctx->Map.entry.Post_Status
0975   );
0976   RtemsMessageReqConstruct_Post_Name_Check( ctx, ctx->Map.entry.Post_Name );
0977   RtemsMessageReqConstruct_Post_IdObj_Check( ctx, ctx->Map.entry.Post_IdObj );
0978   RtemsMessageReqConstruct_Post_StorageFree_Check(
0979     ctx,
0980     ctx->Map.entry.Post_StorageFree
0981   );
0982 }
0983 
0984 /**
0985  * @fn void T_case_body_RtemsMessageReqConstruct( void )
0986  */
0987 T_TEST_CASE_FIXTURE(
0988   RtemsMessageReqConstruct,
0989   &RtemsMessageReqConstruct_Fixture
0990 )
0991 {
0992   RtemsMessageReqConstruct_Context *ctx;
0993 
0994   ctx = T_fixture_context();
0995   ctx->Map.in_action_loop = true;
0996   ctx->Map.index = 0;
0997 
0998   for (
0999     ctx->Map.pcs[ 0 ] = RtemsMessageReqConstruct_Pre_Config_Valid;
1000     ctx->Map.pcs[ 0 ] < RtemsMessageReqConstruct_Pre_Config_NA;
1001     ++ctx->Map.pcs[ 0 ]
1002   ) {
1003     for (
1004       ctx->Map.pcs[ 1 ] = RtemsMessageReqConstruct_Pre_Name_Valid;
1005       ctx->Map.pcs[ 1 ] < RtemsMessageReqConstruct_Pre_Name_NA;
1006       ++ctx->Map.pcs[ 1 ]
1007     ) {
1008       for (
1009         ctx->Map.pcs[ 2 ] = RtemsMessageReqConstruct_Pre_Id_Id;
1010         ctx->Map.pcs[ 2 ] < RtemsMessageReqConstruct_Pre_Id_NA;
1011         ++ctx->Map.pcs[ 2 ]
1012       ) {
1013         for (
1014           ctx->Map.pcs[ 3 ] = RtemsMessageReqConstruct_Pre_MaxPending_Valid;
1015           ctx->Map.pcs[ 3 ] < RtemsMessageReqConstruct_Pre_MaxPending_NA;
1016           ++ctx->Map.pcs[ 3 ]
1017         ) {
1018           for (
1019             ctx->Map.pcs[ 4 ] = RtemsMessageReqConstruct_Pre_MaxSize_Valid;
1020             ctx->Map.pcs[ 4 ] < RtemsMessageReqConstruct_Pre_MaxSize_NA;
1021             ++ctx->Map.pcs[ 4 ]
1022           ) {
1023             for (
1024               ctx->Map.pcs[ 5 ] = RtemsMessageReqConstruct_Pre_Free_Yes;
1025               ctx->Map.pcs[ 5 ] < RtemsMessageReqConstruct_Pre_Free_NA;
1026               ++ctx->Map.pcs[ 5 ]
1027             ) {
1028               for (
1029                 ctx->Map.pcs[ 6 ] = RtemsMessageReqConstruct_Pre_Area_Valid;
1030                 ctx->Map.pcs[ 6 ] < RtemsMessageReqConstruct_Pre_Area_NA;
1031                 ++ctx->Map.pcs[ 6 ]
1032               ) {
1033                 for (
1034                   ctx->Map.pcs[ 7 ] = RtemsMessageReqConstruct_Pre_AreaSize_Valid;
1035                   ctx->Map.pcs[ 7 ] < RtemsMessageReqConstruct_Pre_AreaSize_NA;
1036                   ++ctx->Map.pcs[ 7 ]
1037                 ) {
1038                   for (
1039                     ctx->Map.pcs[ 8 ] = RtemsMessageReqConstruct_Pre_StorageFree_Null;
1040                     ctx->Map.pcs[ 8 ] < RtemsMessageReqConstruct_Pre_StorageFree_NA;
1041                     ++ctx->Map.pcs[ 8 ]
1042                   ) {
1043                     ctx->Map.entry = RtemsMessageReqConstruct_PopEntry( ctx );
1044                     RtemsMessageReqConstruct_Prepare( ctx );
1045                     RtemsMessageReqConstruct_TestVariant( ctx );
1046                     RtemsMessageReqConstruct_Cleanup( ctx );
1047                   }
1048                 }
1049               }
1050             }
1051           }
1052         }
1053       }
1054     }
1055   }
1056 }
1057 
1058 /** @} */