Home | History | Annotate | Download | only in hdr
      1 /*
      2  * Copyright (C) 2014 The Android Open Source Project
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License");
      5  * you may not use this file except in compliance with the License.
      6  * You may obtain a copy of the License at
      7  *
      8  *      http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS,
     12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13  * See the License for the specific language governing permissions and
     14  * limitations under the License.
     15  */
     16 
     17 #ifndef XPL_MESSAGE_H
     18 #define XPL_MESSAGE_H
     19 
     20 #include "xpl_Port.h"
     21 
     22 #ifdef __cplusplus
     23 extern "C" {
     24 #endif
     25 
     26 /************** CONSTANTS ****************************************************/
     27 
     28 #define XPL_DM_TASK_MESSAGE_CATEGORY 0
     29 
     30 /************** STRUCTURES, ENUMS, AND TYPEDEFS ******************************/
     31 
     32 enum
     33 {
     34      XPL_MSG_RET_SUCCESS  = 0,     /* operation successfully completed */
     35      XPL_MSG_RET_FAIL = 1,         /* operation failed */
     36      XPL_MSG_RET_BADARGUMENT = 2,  /* bad argument */
     37 };
     38 typedef UINT8  XPL_MSG_RET_STATUS_T;
     39 
     40 
     41 /*=================================================================================
     42                                      FUNCTION PROTOTYPES
     43 ==================================================================================*/
     44 
     45 /* Sends asyncronyous message/event. Callback may be incorporated into message body if required */
     46 XPL_MSG_RET_STATUS_T XPL_MSG_Send(XPL_PORT_T port,
     47                                 UINT32 msgtype,
     48                                 void *data,
     49                                 UINT32 size);
     50 
     51 
     52 
     53 #ifdef __cplusplus
     54 }
     55 #endif
     56 
     57 #endif /* XPL_MESSAGE_H */
     58