00001 00044 #if !defined (MSGQDEFS_H) 00045 #define MSGQDEFS_H 00046 00047 00048 /* ----------------------------------- DSP/BIOS Link */ 00049 #include <gpptypes.h> 00050 #include <errbase.h> 00051 00052 00053 #if defined (__cplusplus) 00054 extern "C" { 00055 #endif 00056 00057 00064 typedef Int16 MSGQ_MqtError ; 00065 00073 typedef Uint16 MSGQ_Id ; 00074 00081 typedef Uint32 MSGQ_Queue ; 00082 00083 00090 #define MSGQ_INVALIDMSGQ (Uint16) 0xFFFFu 00091 00098 #define MSGQ_INVALIDPROCID (Uint16) 0xFFFFu 00099 00106 #define MSGQ_INTERNALIDSSTART (Uint16) 0xFF00u 00107 00114 #define MSGQ_ASYNCLOCATEMSGID (Uint16) 0xFF00u 00115 00122 #define MSGQ_ASYNCERRORMSGID (Uint16) 0xFF01u 00123 00130 #define MSGQ_INTERNALIDSEND (Uint16) 0xFF7fu 00131 00138 #define MSGQ_MQTMSGIDSSTART (Uint16) 0xFF80u 00139 00146 #define MSGQ_MQTMSGIDSEND (Uint16) 0xFFFEu 00147 00154 #define MSGQ_INVALIDMSGID (Uint16) 0xFFFFu 00155 00163 #define MSGQ_MQTERROREXIT (MSGQ_MqtError) -1l 00164 00173 #define MSGQ_MQTFAILEDPUT (MSGQ_MqtError) -2l 00174 00181 #define MSG_HEADER_RESERVED_SIZE 2u 00182 00189 #define IS_VALID_MSGQ(msgq) (msgq != MSGQ_INVALIDMSGQ) 00190 00191 00212 typedef DSP_STATUS (*MsgqPend) (Pvoid notifyHandle, Uint32 timeout) ; 00213 00214 00233 typedef DSP_STATUS (*MsgqPost) (Pvoid notifyHandle) ; 00234 00235 00250 typedef struct MSGQ_Attrs_tag { 00251 Pvoid notifyHandle ; 00252 MsgqPend pend ; 00253 MsgqPost post ; 00254 } MSGQ_Attrs ; 00255 00268 typedef struct PCPYMQT_Attrs_tag { 00269 PoolId poolId ; 00270 } PCPYMQT_Attrs ; 00271 00282 typedef struct ZCPYMQT_Attrs_tag { 00283 PoolId poolId ; 00284 } ZCPYMQT_Attrs ; 00285 00296 typedef struct DCPYMQT_Attrs_tag { 00297 PoolId poolId ; 00298 } DCPYMQT_Attrs ; 00299 00310 typedef struct MSGQ_LocateAttrs_tag { 00311 Uint32 timeout ; 00312 } MSGQ_LocateAttrs ; 00313 00326 typedef struct MSGQ_LocateAsyncAttrs_tag { 00327 PoolId poolId ; 00328 Pvoid arg ; 00329 } MSGQ_LocateAsyncAttrs ; 00330 00354 typedef struct MSGQ_MsgHeader_tag { 00355 Uint32 reserved [MSG_HEADER_RESERVED_SIZE] ; 00356 Uint16 srcProcId ; 00357 Uint16 poolId ; 00358 Uint16 size ; 00359 Uint16 dstId ; 00360 Uint16 srcId ; 00361 Uint16 msgId ; 00362 } MSGQ_MsgHeader ; 00363 00378 typedef struct MSGQ_AsyncLocateMsg_tag { 00379 MSGQ_MsgHeader header ; 00380 MSGQ_Queue msgqQueue ; 00381 Pvoid arg ; 00382 } MSGQ_AsyncLocateMsg ; 00383 00404 typedef struct MSGQ_AsyncErrorMsg_tag { 00405 MSGQ_MsgHeader header ; 00406 MSGQ_MqtError errorType ; 00407 Pvoid arg1 ; 00408 Pvoid arg2 ; 00409 } MSGQ_AsyncErrorMsg ; 00410 00417 typedef MSGQ_MsgHeader * MSGQ_Msg ; 00418 00425 typedef struct MQT_Interface_tag MQT_Interface ; 00426 00427 00434 #define MsgqMqtError MSGQ_MqtError 00435 00442 #define MsgqId MSGQ_Id 00443 00450 #define MsgqQueue MSGQ_Queue 00451 00458 #define MsgqAttrs MSGQ_Attrs 00459 00466 #define PcpyMqtAttrs PCPYMQT_Attrs 00467 00474 #define ZcpyMqtAttrs ZCPYMQT_Attrs 00475 00482 #define DcpyMqtAttrs DCPYMQT_Attrs 00483 00490 #define MsgqLocateAttrs MSGQ_LocateAttrs 00491 00498 #define MsgqLocateAsyncAttrs MSGQ_LocateAsyncAttrs 00499 00506 #define MsgqMsgHeader MSGQ_MsgHeader 00507 00514 #define MsgqAsyncLocateMsg MSGQ_AsyncLocateMsg 00515 00522 #define MsgqAsyncErrorMsg MSGQ_AsyncErrorMsg 00523 00530 #define MsgqMsg MSGQ_Msg 00531 00538 #define MqtInterface MQT_Interface 00539 00540 00541 #if defined (__cplusplus) 00542 } 00543 #endif 00544 00545 00546 #endif /* !defined (MSGQDEFS_H) */