blob: 4eae9ff1b6296e48b34b89e38d68e03916eff163 [file] [log] [blame]
b.liue9582032025-04-17 19:18:16 +08001/******************************************************************************
2*(C) Copyright 2014 Marvell International Ltd.
3* All Rights Reserved
4******************************************************************************/
5/* -------------------------------------------------------------------------------------------------------------------
6 *
7 * Filename: mbim_blob.h
8 *
9 * Authors: Boaz Sommer
10 *
11 * Description: blob message wrapper class
12 *
13 * HISTORY:
14 * Dec 17, 2014 - Initial Version
15 *
16 * Requirements:
17 * 1. Use typedef to define MessageContainerT type
18 * 2. Declare MessageInterfaceS structure
19 *
20 * Notes:
21 *
22 *
23 ******************************************************************************/
24#ifndef MBIM_BLOB_H
25#define MBIM_BLOB_H
26
27#include "linux_types.h"
28
29#if 0
30//Must typedef MessageContainerT
31typedef struct blob_buf MessageContainerT;
32
33struct MessageInterfaceS
34{
35 //private
36// MessageContainerT MsgContainer;
37
38 //public - these APIs are used by outside module
39 void (*Init) (struct MessageInterfaceS *msg);
40
41 void (*AddInt8) (struct MessageInterfaceS *msg, char *name, Int8 data);
42 void (*AddInt16) (struct MessageInterfaceS *msg, char *name, Int16 data);
43 void (*AddInt32) (struct MessageInterfaceS *msg, char *name, Int32 data);
44 void (*AddString) (struct MessageInterfaceS *msg, char *name, char *data);
45 void (*AddData) (struct MessageInterfaceS *msg, int id, void *data, int datalen);
46
47 Int8 (*GetInt8) (struct MessageInterfaceS *msg, char *name);
48 Int16 (*GetInt16) (struct MessageInterfaceS *msg, char *name);
49 Int32 (*GetInt32) (struct MessageInterfaceS *msg, char *name);
50 char * (*GetString) (struct MessageInterfaceS *msg, char *name);
51
52};
53#endif
54/*
55 * Global API
56 * - initialize struct MessageInterfaceS
57 * - initialize message container
58 *
59 */
60int InitMessageInterface (struct MessageInterfaceS *msg);
61
62
63#endif //MBIM_BLOB_H
64