-
Notifications
You must be signed in to change notification settings - Fork 15
/
servreg_loc.c
169 lines (162 loc) · 4.09 KB
/
servreg_loc.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
#include <errno.h>
#include <string.h>
#include "servreg_loc.h"
struct qmi_elem_info servreg_loc_qmi_result_ei[] = {
{
.data_type = QMI_UNSIGNED_2_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint16_t),
.offset = offsetof(struct servreg_loc_qmi_result, result),
},
{
.data_type = QMI_UNSIGNED_2_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint16_t),
.offset = offsetof(struct servreg_loc_qmi_result, error),
},
{}
};
struct qmi_elem_info servreg_loc_domain_list_entry_ei[] = {
{
.data_type = QMI_STRING,
.elem_len = 256,
.elem_size = sizeof(char),
.offset = offsetof(struct servreg_loc_domain_list_entry, name)
},
{
.data_type = QMI_UNSIGNED_4_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint32_t),
.offset = offsetof(struct servreg_loc_domain_list_entry, instance_id),
},
{
.data_type = QMI_UNSIGNED_1_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint8_t),
.offset = offsetof(struct servreg_loc_domain_list_entry, service_data_valid),
},
{
.data_type = QMI_UNSIGNED_4_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint32_t),
.offset = offsetof(struct servreg_loc_domain_list_entry, service_data),
},
{}
};
struct qmi_elem_info servreg_loc_get_domain_list_req_ei[] = {
{
.data_type = QMI_STRING,
.elem_len = 256,
.elem_size = sizeof(char),
.array_type = VAR_LEN_ARRAY,
.tlv_type = 1,
.offset = offsetof(struct servreg_loc_get_domain_list_req, name)
},
{
.data_type = QMI_OPT_FLAG,
.elem_len = 1,
.elem_size = sizeof(bool),
.tlv_type = 16,
.offset = offsetof(struct servreg_loc_get_domain_list_req, offset_valid),
},
{
.data_type = QMI_UNSIGNED_4_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint32_t),
.tlv_type = 16,
.offset = offsetof(struct servreg_loc_get_domain_list_req, offset),
},
{}
};
struct qmi_elem_info servreg_loc_get_domain_list_resp_ei[] = {
{
.data_type = QMI_STRUCT,
.elem_len = 1,
.elem_size = sizeof(struct servreg_loc_qmi_result),
.tlv_type = 2,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, result),
.ei_array = servreg_loc_qmi_result_ei,
},
{
.data_type = QMI_OPT_FLAG,
.elem_len = 1,
.elem_size = sizeof(bool),
.tlv_type = 16,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, total_domains_valid),
},
{
.data_type = QMI_UNSIGNED_2_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint16_t),
.tlv_type = 16,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, total_domains),
},
{
.data_type = QMI_OPT_FLAG,
.elem_len = 1,
.elem_size = sizeof(bool),
.tlv_type = 17,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, db_revision_valid),
},
{
.data_type = QMI_UNSIGNED_2_BYTE,
.elem_len = 1,
.elem_size = sizeof(uint16_t),
.tlv_type = 17,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, db_revision),
},
{
.data_type = QMI_OPT_FLAG,
.elem_len = 1,
.elem_size = sizeof(bool),
.tlv_type = 18,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, domain_list_valid),
},
{
.data_type = QMI_DATA_LEN,
.elem_len = 1,
.elem_size = sizeof(uint8_t),
.tlv_type = 18,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, domain_list_len),
},
{
.data_type = QMI_STRUCT,
.elem_len = 255,
.elem_size = sizeof(struct servreg_loc_domain_list_entry),
.array_type = VAR_LEN_ARRAY,
.tlv_type = 18,
.offset = offsetof(struct servreg_loc_get_domain_list_resp, domain_list),
.ei_array = servreg_loc_domain_list_entry_ei,
},
{}
};
struct qmi_elem_info servreg_loc_pfr_req_ei[] = {
{
.data_type = QMI_STRING,
.elem_len = 256,
.elem_size = sizeof(char),
.array_type = VAR_LEN_ARRAY,
.tlv_type = 1,
.offset = offsetof(struct servreg_loc_pfr_req, service)
},
{
.data_type = QMI_STRING,
.elem_len = 256,
.elem_size = sizeof(char),
.array_type = VAR_LEN_ARRAY,
.tlv_type = 2,
.offset = offsetof(struct servreg_loc_pfr_req, reason)
},
{}
};
struct qmi_elem_info servreg_loc_pfr_resp_ei[] = {
{
.data_type = QMI_STRUCT,
.elem_len = 1,
.elem_size = sizeof(struct servreg_loc_qmi_result),
.tlv_type = 2,
.offset = offsetof(struct servreg_loc_pfr_resp, result),
.ei_array = servreg_loc_qmi_result_ei,
},
{}
};