4102f7b0b5c3b4f2036f9620d8f3b438d0a7c28a
[platform/kernel/linux-rpi.git] / drivers / net / wireless / ath / ath10k / qmi_wlfw_v01.c
1 /*
2  * Copyright (c) 2018 The Linux Foundation. All rights reserved.
3  *
4  * Permission to use, copy, modify, and/or distribute this software for any
5  * purpose with or without fee is hereby granted, provided that the above
6  * copyright notice and this permission notice appear in all copies.
7  *
8  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15  */
16
17 #include <linux/soc/qcom/qmi.h>
18 #include <linux/types.h>
19 #include "qmi_wlfw_v01.h"
20
21 static struct qmi_elem_info wlfw_ce_tgt_pipe_cfg_s_v01_ei[] = {
22         {
23                 .data_type      = QMI_UNSIGNED_4_BYTE,
24                 .elem_len       = 1,
25                 .elem_size      = sizeof(u32),
26                 .array_type     = NO_ARRAY,
27                 .tlv_type       = 0,
28                 .offset         = offsetof(struct wlfw_ce_tgt_pipe_cfg_s_v01,
29                                            pipe_num),
30         },
31         {
32                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
33                 .elem_len       = 1,
34                 .elem_size      = sizeof(enum wlfw_pipedir_enum_v01),
35                 .array_type     = NO_ARRAY,
36                 .tlv_type       = 0,
37                 .offset         = offsetof(struct wlfw_ce_tgt_pipe_cfg_s_v01,
38                                            pipe_dir),
39         },
40         {
41                 .data_type      = QMI_UNSIGNED_4_BYTE,
42                 .elem_len       = 1,
43                 .elem_size      = sizeof(u32),
44                 .array_type     = NO_ARRAY,
45                 .tlv_type       = 0,
46                 .offset         = offsetof(struct wlfw_ce_tgt_pipe_cfg_s_v01,
47                                            nentries),
48         },
49         {
50                 .data_type      = QMI_UNSIGNED_4_BYTE,
51                 .elem_len       = 1,
52                 .elem_size      = sizeof(u32),
53                 .array_type     = NO_ARRAY,
54                 .tlv_type       = 0,
55                 .offset         = offsetof(struct wlfw_ce_tgt_pipe_cfg_s_v01,
56                                            nbytes_max),
57         },
58         {
59                 .data_type      = QMI_UNSIGNED_4_BYTE,
60                 .elem_len       = 1,
61                 .elem_size      = sizeof(u32),
62                 .array_type     = NO_ARRAY,
63                 .tlv_type       = 0,
64                 .offset         = offsetof(struct wlfw_ce_tgt_pipe_cfg_s_v01,
65                                            flags),
66         },
67         {}
68 };
69
70 static struct qmi_elem_info wlfw_ce_svc_pipe_cfg_s_v01_ei[] = {
71         {
72                 .data_type      = QMI_UNSIGNED_4_BYTE,
73                 .elem_len       = 1,
74                 .elem_size      = sizeof(u32),
75                 .array_type     = NO_ARRAY,
76                 .tlv_type       = 0,
77                 .offset         = offsetof(struct wlfw_ce_svc_pipe_cfg_s_v01,
78                                            service_id),
79         },
80         {
81                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
82                 .elem_len       = 1,
83                 .elem_size      = sizeof(enum wlfw_pipedir_enum_v01),
84                 .array_type     = NO_ARRAY,
85                 .tlv_type       = 0,
86                 .offset         = offsetof(struct wlfw_ce_svc_pipe_cfg_s_v01,
87                                            pipe_dir),
88         },
89         {
90                 .data_type      = QMI_UNSIGNED_4_BYTE,
91                 .elem_len       = 1,
92                 .elem_size      = sizeof(u32),
93                 .array_type     = NO_ARRAY,
94                 .tlv_type       = 0,
95                 .offset         = offsetof(struct wlfw_ce_svc_pipe_cfg_s_v01,
96                                            pipe_num),
97         },
98         {}
99 };
100
101 static struct qmi_elem_info wlfw_shadow_reg_cfg_s_v01_ei[] = {
102         {
103                 .data_type      = QMI_UNSIGNED_2_BYTE,
104                 .elem_len       = 1,
105                 .elem_size      = sizeof(u16),
106                 .array_type     = NO_ARRAY,
107                 .tlv_type       = 0,
108                 .offset         = offsetof(struct wlfw_shadow_reg_cfg_s_v01,
109                                            id),
110         },
111         {
112                 .data_type      = QMI_UNSIGNED_2_BYTE,
113                 .elem_len       = 1,
114                 .elem_size      = sizeof(u16),
115                 .array_type     = NO_ARRAY,
116                 .tlv_type       = 0,
117                 .offset         = offsetof(struct wlfw_shadow_reg_cfg_s_v01,
118                                            offset),
119         },
120         {}
121 };
122
123 static struct qmi_elem_info wlfw_shadow_reg_v2_cfg_s_v01_ei[] = {
124         {
125                 .data_type      = QMI_UNSIGNED_4_BYTE,
126                 .elem_len       = 1,
127                 .elem_size      = sizeof(u32),
128                 .array_type     = NO_ARRAY,
129                 .tlv_type       = 0,
130                 .offset         = offsetof(struct wlfw_shadow_reg_v2_cfg_s_v01,
131                                            addr),
132         },
133         {}
134 };
135
136 static struct qmi_elem_info wlfw_memory_region_info_s_v01_ei[] = {
137         {
138                 .data_type      = QMI_UNSIGNED_8_BYTE,
139                 .elem_len       = 1,
140                 .elem_size      = sizeof(u64),
141                 .array_type     = NO_ARRAY,
142                 .tlv_type       = 0,
143                 .offset         = offsetof(struct wlfw_memory_region_info_s_v01,
144                                            region_addr),
145         },
146         {
147                 .data_type      = QMI_UNSIGNED_4_BYTE,
148                 .elem_len       = 1,
149                 .elem_size      = sizeof(u32),
150                 .array_type     = NO_ARRAY,
151                 .tlv_type       = 0,
152                 .offset         = offsetof(struct wlfw_memory_region_info_s_v01,
153                                            size),
154         },
155         {
156                 .data_type      = QMI_UNSIGNED_1_BYTE,
157                 .elem_len       = 1,
158                 .elem_size      = sizeof(u8),
159                 .array_type     = NO_ARRAY,
160                 .tlv_type       = 0,
161                 .offset         = offsetof(struct wlfw_memory_region_info_s_v01,
162                                            secure_flag),
163         },
164         {}
165 };
166
167 static struct qmi_elem_info wlfw_mem_cfg_s_v01_ei[] = {
168         {
169                 .data_type      = QMI_UNSIGNED_8_BYTE,
170                 .elem_len       = 1,
171                 .elem_size      = sizeof(u64),
172                 .array_type     = NO_ARRAY,
173                 .tlv_type       = 0,
174                 .offset         = offsetof(struct wlfw_mem_cfg_s_v01,
175                                            offset),
176         },
177         {
178                 .data_type      = QMI_UNSIGNED_4_BYTE,
179                 .elem_len       = 1,
180                 .elem_size      = sizeof(u32),
181                 .array_type     = NO_ARRAY,
182                 .tlv_type       = 0,
183                 .offset         = offsetof(struct wlfw_mem_cfg_s_v01,
184                                            size),
185         },
186         {
187                 .data_type      = QMI_UNSIGNED_1_BYTE,
188                 .elem_len       = 1,
189                 .elem_size      = sizeof(u8),
190                 .array_type     = NO_ARRAY,
191                 .tlv_type       = 0,
192                 .offset         = offsetof(struct wlfw_mem_cfg_s_v01,
193                                            secure_flag),
194         },
195         {}
196 };
197
198 static struct qmi_elem_info wlfw_mem_seg_s_v01_ei[] = {
199         {
200                 .data_type      = QMI_UNSIGNED_4_BYTE,
201                 .elem_len       = 1,
202                 .elem_size      = sizeof(u32),
203                 .array_type     = NO_ARRAY,
204                 .tlv_type       = 0,
205                 .offset         = offsetof(struct wlfw_mem_seg_s_v01,
206                                            size),
207         },
208         {
209                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
210                 .elem_len       = 1,
211                 .elem_size      = sizeof(enum wlfw_mem_type_enum_v01),
212                 .array_type     = NO_ARRAY,
213                 .tlv_type       = 0,
214                 .offset         = offsetof(struct wlfw_mem_seg_s_v01,
215                                            type),
216         },
217         {
218                 .data_type      = QMI_DATA_LEN,
219                 .elem_len       = 1,
220                 .elem_size      = sizeof(u8),
221                 .array_type     = NO_ARRAY,
222                 .tlv_type       = 0,
223                 .offset         = offsetof(struct wlfw_mem_seg_s_v01,
224                                            mem_cfg_len),
225         },
226         {
227                 .data_type      = QMI_STRUCT,
228                 .elem_len       = QMI_WLFW_MAX_NUM_MEM_CFG_V01,
229                 .elem_size      = sizeof(struct wlfw_mem_cfg_s_v01),
230                 .array_type       = VAR_LEN_ARRAY,
231                 .tlv_type       = 0,
232                 .offset         = offsetof(struct wlfw_mem_seg_s_v01,
233                                            mem_cfg),
234                 .ei_array      = wlfw_mem_cfg_s_v01_ei,
235         },
236         {}
237 };
238
239 static struct qmi_elem_info wlfw_mem_seg_resp_s_v01_ei[] = {
240         {
241                 .data_type      = QMI_UNSIGNED_8_BYTE,
242                 .elem_len       = 1,
243                 .elem_size      = sizeof(u64),
244                 .array_type     = NO_ARRAY,
245                 .tlv_type       = 0,
246                 .offset         = offsetof(struct wlfw_mem_seg_resp_s_v01,
247                                            addr),
248         },
249         {
250                 .data_type      = QMI_UNSIGNED_4_BYTE,
251                 .elem_len       = 1,
252                 .elem_size      = sizeof(u32),
253                 .array_type     = NO_ARRAY,
254                 .tlv_type       = 0,
255                 .offset         = offsetof(struct wlfw_mem_seg_resp_s_v01,
256                                            size),
257         },
258         {
259                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
260                 .elem_len       = 1,
261                 .elem_size      = sizeof(enum wlfw_mem_type_enum_v01),
262                 .array_type     = NO_ARRAY,
263                 .tlv_type       = 0,
264                 .offset         = offsetof(struct wlfw_mem_seg_resp_s_v01,
265                                            type),
266         },
267         {}
268 };
269
270 static struct qmi_elem_info wlfw_rf_chip_info_s_v01_ei[] = {
271         {
272                 .data_type      = QMI_UNSIGNED_4_BYTE,
273                 .elem_len       = 1,
274                 .elem_size      = sizeof(u32),
275                 .array_type     = NO_ARRAY,
276                 .tlv_type       = 0,
277                 .offset         = offsetof(struct wlfw_rf_chip_info_s_v01,
278                                            chip_id),
279         },
280         {
281                 .data_type      = QMI_UNSIGNED_4_BYTE,
282                 .elem_len       = 1,
283                 .elem_size      = sizeof(u32),
284                 .array_type     = NO_ARRAY,
285                 .tlv_type       = 0,
286                 .offset         = offsetof(struct wlfw_rf_chip_info_s_v01,
287                                            chip_family),
288         },
289         {}
290 };
291
292 static struct qmi_elem_info wlfw_rf_board_info_s_v01_ei[] = {
293         {
294                 .data_type      = QMI_UNSIGNED_4_BYTE,
295                 .elem_len       = 1,
296                 .elem_size      = sizeof(u32),
297                 .array_type     = NO_ARRAY,
298                 .tlv_type       = 0,
299                 .offset         = offsetof(struct wlfw_rf_board_info_s_v01,
300                                            board_id),
301         },
302         {}
303 };
304
305 static struct qmi_elem_info wlfw_soc_info_s_v01_ei[] = {
306         {
307                 .data_type      = QMI_UNSIGNED_4_BYTE,
308                 .elem_len       = 1,
309                 .elem_size      = sizeof(u32),
310                 .array_type     = NO_ARRAY,
311                 .tlv_type       = 0,
312                 .offset         = offsetof(struct wlfw_soc_info_s_v01,
313                                            soc_id),
314         },
315         {}
316 };
317
318 static struct qmi_elem_info wlfw_fw_version_info_s_v01_ei[] = {
319         {
320                 .data_type      = QMI_UNSIGNED_4_BYTE,
321                 .elem_len       = 1,
322                 .elem_size      = sizeof(u32),
323                 .array_type     = NO_ARRAY,
324                 .tlv_type       = 0,
325                 .offset         = offsetof(struct wlfw_fw_version_info_s_v01,
326                                            fw_version),
327         },
328         {
329                 .data_type      = QMI_STRING,
330                 .elem_len       = QMI_WLFW_MAX_TIMESTAMP_LEN_V01 + 1,
331                 .elem_size      = sizeof(char),
332                 .array_type     = NO_ARRAY,
333                 .tlv_type       = 0,
334                 .offset         = offsetof(struct wlfw_fw_version_info_s_v01,
335                                            fw_build_timestamp),
336         },
337         {}
338 };
339
340 struct qmi_elem_info wlfw_ind_register_req_msg_v01_ei[] = {
341         {
342                 .data_type      = QMI_OPT_FLAG,
343                 .elem_len       = 1,
344                 .elem_size      = sizeof(u8),
345                 .array_type     = NO_ARRAY,
346                 .tlv_type       = 0x10,
347                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
348                                            fw_ready_enable_valid),
349         },
350         {
351                 .data_type      = QMI_UNSIGNED_1_BYTE,
352                 .elem_len       = 1,
353                 .elem_size      = sizeof(u8),
354                 .array_type     = NO_ARRAY,
355                 .tlv_type       = 0x10,
356                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
357                                            fw_ready_enable),
358         },
359         {
360                 .data_type      = QMI_OPT_FLAG,
361                 .elem_len       = 1,
362                 .elem_size      = sizeof(u8),
363                 .array_type     = NO_ARRAY,
364                 .tlv_type       = 0x11,
365                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
366                                            initiate_cal_download_enable_valid),
367         },
368         {
369                 .data_type      = QMI_UNSIGNED_1_BYTE,
370                 .elem_len       = 1,
371                 .elem_size      = sizeof(u8),
372                 .array_type     = NO_ARRAY,
373                 .tlv_type       = 0x11,
374                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
375                                            initiate_cal_download_enable),
376         },
377         {
378                 .data_type      = QMI_OPT_FLAG,
379                 .elem_len       = 1,
380                 .elem_size      = sizeof(u8),
381                 .array_type     = NO_ARRAY,
382                 .tlv_type       = 0x12,
383                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
384                                            initiate_cal_update_enable_valid),
385         },
386         {
387                 .data_type      = QMI_UNSIGNED_1_BYTE,
388                 .elem_len       = 1,
389                 .elem_size      = sizeof(u8),
390                 .array_type     = NO_ARRAY,
391                 .tlv_type       = 0x12,
392                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
393                                            initiate_cal_update_enable),
394         },
395         {
396                 .data_type      = QMI_OPT_FLAG,
397                 .elem_len       = 1,
398                 .elem_size      = sizeof(u8),
399                 .array_type     = NO_ARRAY,
400                 .tlv_type       = 0x13,
401                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
402                                            msa_ready_enable_valid),
403         },
404         {
405                 .data_type      = QMI_UNSIGNED_1_BYTE,
406                 .elem_len       = 1,
407                 .elem_size      = sizeof(u8),
408                 .array_type     = NO_ARRAY,
409                 .tlv_type       = 0x13,
410                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
411                                            msa_ready_enable),
412         },
413         {
414                 .data_type      = QMI_OPT_FLAG,
415                 .elem_len       = 1,
416                 .elem_size      = sizeof(u8),
417                 .array_type     = NO_ARRAY,
418                 .tlv_type       = 0x14,
419                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
420                                            pin_connect_result_enable_valid),
421         },
422         {
423                 .data_type      = QMI_UNSIGNED_1_BYTE,
424                 .elem_len       = 1,
425                 .elem_size      = sizeof(u8),
426                 .array_type     = NO_ARRAY,
427                 .tlv_type       = 0x14,
428                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
429                                            pin_connect_result_enable),
430         },
431         {
432                 .data_type      = QMI_OPT_FLAG,
433                 .elem_len       = 1,
434                 .elem_size      = sizeof(u8),
435                 .array_type     = NO_ARRAY,
436                 .tlv_type       = 0x15,
437                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
438                                            client_id_valid),
439         },
440         {
441                 .data_type      = QMI_UNSIGNED_4_BYTE,
442                 .elem_len       = 1,
443                 .elem_size      = sizeof(u32),
444                 .array_type     = NO_ARRAY,
445                 .tlv_type       = 0x15,
446                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
447                                            client_id),
448         },
449         {
450                 .data_type      = QMI_OPT_FLAG,
451                 .elem_len       = 1,
452                 .elem_size      = sizeof(u8),
453                 .array_type     = NO_ARRAY,
454                 .tlv_type       = 0x16,
455                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
456                                            request_mem_enable_valid),
457         },
458         {
459                 .data_type      = QMI_UNSIGNED_1_BYTE,
460                 .elem_len       = 1,
461                 .elem_size      = sizeof(u8),
462                 .array_type     = NO_ARRAY,
463                 .tlv_type       = 0x16,
464                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
465                                            request_mem_enable),
466         },
467         {
468                 .data_type      = QMI_OPT_FLAG,
469                 .elem_len       = 1,
470                 .elem_size      = sizeof(u8),
471                 .array_type     = NO_ARRAY,
472                 .tlv_type       = 0x17,
473                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
474                                            mem_ready_enable_valid),
475         },
476         {
477                 .data_type      = QMI_UNSIGNED_1_BYTE,
478                 .elem_len       = 1,
479                 .elem_size      = sizeof(u8),
480                 .array_type     = NO_ARRAY,
481                 .tlv_type       = 0x17,
482                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
483                                            mem_ready_enable),
484         },
485         {
486                 .data_type      = QMI_OPT_FLAG,
487                 .elem_len       = 1,
488                 .elem_size      = sizeof(u8),
489                 .array_type     = NO_ARRAY,
490                 .tlv_type       = 0x18,
491                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
492                                            fw_init_done_enable_valid),
493         },
494         {
495                 .data_type      = QMI_UNSIGNED_1_BYTE,
496                 .elem_len       = 1,
497                 .elem_size      = sizeof(u8),
498                 .array_type     = NO_ARRAY,
499                 .tlv_type       = 0x18,
500                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
501                                            fw_init_done_enable),
502         },
503         {
504                 .data_type      = QMI_OPT_FLAG,
505                 .elem_len       = 1,
506                 .elem_size      = sizeof(u8),
507                 .array_type     = NO_ARRAY,
508                 .tlv_type       = 0x19,
509                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
510                                            rejuvenate_enable_valid),
511         },
512         {
513                 .data_type      = QMI_UNSIGNED_4_BYTE,
514                 .elem_len       = 1,
515                 .elem_size      = sizeof(u32),
516                 .array_type     = NO_ARRAY,
517                 .tlv_type       = 0x19,
518                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
519                                            rejuvenate_enable),
520         },
521         {
522                 .data_type      = QMI_OPT_FLAG,
523                 .elem_len       = 1,
524                 .elem_size      = sizeof(u8),
525                 .array_type     = NO_ARRAY,
526                 .tlv_type       = 0x1A,
527                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
528                                            xo_cal_enable_valid),
529         },
530         {
531                 .data_type      = QMI_UNSIGNED_1_BYTE,
532                 .elem_len       = 1,
533                 .elem_size      = sizeof(u8),
534                 .array_type     = NO_ARRAY,
535                 .tlv_type       = 0x1A,
536                 .offset         = offsetof(struct wlfw_ind_register_req_msg_v01,
537                                            xo_cal_enable),
538         },
539         {}
540 };
541
542 struct qmi_elem_info wlfw_ind_register_resp_msg_v01_ei[] = {
543         {
544                 .data_type      = QMI_STRUCT,
545                 .elem_len       = 1,
546                 .elem_size      = sizeof(struct qmi_response_type_v01),
547                 .array_type     = NO_ARRAY,
548                 .tlv_type       = 0x02,
549                 .offset         = offsetof(struct wlfw_ind_register_resp_msg_v01,
550                                            resp),
551                 .ei_array      = qmi_response_type_v01_ei,
552         },
553         {
554                 .data_type      = QMI_OPT_FLAG,
555                 .elem_len       = 1,
556                 .elem_size      = sizeof(u8),
557                 .array_type     = NO_ARRAY,
558                 .tlv_type       = 0x10,
559                 .offset         = offsetof(struct wlfw_ind_register_resp_msg_v01,
560                                            fw_status_valid),
561         },
562         {
563                 .data_type      = QMI_UNSIGNED_8_BYTE,
564                 .elem_len       = 1,
565                 .elem_size      = sizeof(u64),
566                 .array_type     = NO_ARRAY,
567                 .tlv_type       = 0x10,
568                 .offset         = offsetof(struct wlfw_ind_register_resp_msg_v01,
569                                            fw_status),
570         },
571         {}
572 };
573
574 struct qmi_elem_info wlfw_fw_ready_ind_msg_v01_ei[] = {
575         {}
576 };
577
578 struct qmi_elem_info wlfw_msa_ready_ind_msg_v01_ei[] = {
579         {}
580 };
581
582 struct qmi_elem_info wlfw_pin_connect_result_ind_msg_v01_ei[] = {
583         {
584                 .data_type      = QMI_OPT_FLAG,
585                 .elem_len       = 1,
586                 .elem_size      = sizeof(u8),
587                 .array_type     = NO_ARRAY,
588                 .tlv_type       = 0x10,
589                 .offset         = offsetof(struct wlfw_pin_connect_result_ind_msg_v01,
590                                            pwr_pin_result_valid),
591         },
592         {
593                 .data_type      = QMI_UNSIGNED_4_BYTE,
594                 .elem_len       = 1,
595                 .elem_size      = sizeof(u32),
596                 .array_type     = NO_ARRAY,
597                 .tlv_type       = 0x10,
598                 .offset         = offsetof(struct wlfw_pin_connect_result_ind_msg_v01,
599                                            pwr_pin_result),
600         },
601         {
602                 .data_type      = QMI_OPT_FLAG,
603                 .elem_len       = 1,
604                 .elem_size      = sizeof(u8),
605                 .array_type     = NO_ARRAY,
606                 .tlv_type       = 0x11,
607                 .offset         = offsetof(struct wlfw_pin_connect_result_ind_msg_v01,
608                                            phy_io_pin_result_valid),
609         },
610         {
611                 .data_type      = QMI_UNSIGNED_4_BYTE,
612                 .elem_len       = 1,
613                 .elem_size      = sizeof(u32),
614                 .array_type     = NO_ARRAY,
615                 .tlv_type       = 0x11,
616                 .offset         = offsetof(struct wlfw_pin_connect_result_ind_msg_v01,
617                                            phy_io_pin_result),
618         },
619         {
620                 .data_type      = QMI_OPT_FLAG,
621                 .elem_len       = 1,
622                 .elem_size      = sizeof(u8),
623                 .array_type     = NO_ARRAY,
624                 .tlv_type       = 0x12,
625                 .offset         = offsetof(struct wlfw_pin_connect_result_ind_msg_v01,
626                                            rf_pin_result_valid),
627         },
628         {
629                 .data_type      = QMI_UNSIGNED_4_BYTE,
630                 .elem_len       = 1,
631                 .elem_size      = sizeof(u32),
632                 .array_type     = NO_ARRAY,
633                 .tlv_type       = 0x12,
634                 .offset         = offsetof(struct wlfw_pin_connect_result_ind_msg_v01,
635                                            rf_pin_result),
636         },
637         {}
638 };
639
640 struct qmi_elem_info wlfw_wlan_mode_req_msg_v01_ei[] = {
641         {
642                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
643                 .elem_len       = 1,
644                 .elem_size      = sizeof(enum wlfw_driver_mode_enum_v01),
645                 .array_type     = NO_ARRAY,
646                 .tlv_type       = 0x01,
647                 .offset         = offsetof(struct wlfw_wlan_mode_req_msg_v01,
648                                            mode),
649         },
650         {
651                 .data_type      = QMI_OPT_FLAG,
652                 .elem_len       = 1,
653                 .elem_size      = sizeof(u8),
654                 .array_type     = NO_ARRAY,
655                 .tlv_type       = 0x10,
656                 .offset         = offsetof(struct wlfw_wlan_mode_req_msg_v01,
657                                            hw_debug_valid),
658         },
659         {
660                 .data_type      = QMI_UNSIGNED_1_BYTE,
661                 .elem_len       = 1,
662                 .elem_size      = sizeof(u8),
663                 .array_type     = NO_ARRAY,
664                 .tlv_type       = 0x10,
665                 .offset         = offsetof(struct wlfw_wlan_mode_req_msg_v01,
666                                            hw_debug),
667         },
668         {}
669 };
670
671 struct qmi_elem_info wlfw_wlan_mode_resp_msg_v01_ei[] = {
672         {
673                 .data_type      = QMI_STRUCT,
674                 .elem_len       = 1,
675                 .elem_size      = sizeof(struct qmi_response_type_v01),
676                 .array_type     = NO_ARRAY,
677                 .tlv_type       = 0x02,
678                 .offset         = offsetof(struct wlfw_wlan_mode_resp_msg_v01,
679                                            resp),
680                 .ei_array      = qmi_response_type_v01_ei,
681         },
682         {}
683 };
684
685 struct qmi_elem_info wlfw_wlan_cfg_req_msg_v01_ei[] = {
686         {
687                 .data_type      = QMI_OPT_FLAG,
688                 .elem_len       = 1,
689                 .elem_size      = sizeof(u8),
690                 .array_type     = NO_ARRAY,
691                 .tlv_type       = 0x10,
692                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
693                                            host_version_valid),
694         },
695         {
696                 .data_type      = QMI_STRING,
697                 .elem_len       = QMI_WLFW_MAX_STR_LEN_V01 + 1,
698                 .elem_size      = sizeof(char),
699                 .array_type     = NO_ARRAY,
700                 .tlv_type       = 0x10,
701                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
702                                            host_version),
703         },
704         {
705                 .data_type      = QMI_OPT_FLAG,
706                 .elem_len       = 1,
707                 .elem_size      = sizeof(u8),
708                 .array_type     = NO_ARRAY,
709                 .tlv_type       = 0x11,
710                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
711                                            tgt_cfg_valid),
712         },
713         {
714                 .data_type      = QMI_DATA_LEN,
715                 .elem_len       = 1,
716                 .elem_size      = sizeof(u8),
717                 .array_type     = NO_ARRAY,
718                 .tlv_type       = 0x11,
719                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
720                                            tgt_cfg_len),
721         },
722         {
723                 .data_type      = QMI_STRUCT,
724                 .elem_len       = QMI_WLFW_MAX_NUM_CE_V01,
725                 .elem_size      = sizeof(struct wlfw_ce_tgt_pipe_cfg_s_v01),
726                 .array_type       = VAR_LEN_ARRAY,
727                 .tlv_type       = 0x11,
728                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
729                                            tgt_cfg),
730                 .ei_array      = wlfw_ce_tgt_pipe_cfg_s_v01_ei,
731         },
732         {
733                 .data_type      = QMI_OPT_FLAG,
734                 .elem_len       = 1,
735                 .elem_size      = sizeof(u8),
736                 .array_type     = NO_ARRAY,
737                 .tlv_type       = 0x12,
738                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
739                                            svc_cfg_valid),
740         },
741         {
742                 .data_type      = QMI_DATA_LEN,
743                 .elem_len       = 1,
744                 .elem_size      = sizeof(u8),
745                 .array_type     = NO_ARRAY,
746                 .tlv_type       = 0x12,
747                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
748                                            svc_cfg_len),
749         },
750         {
751                 .data_type      = QMI_STRUCT,
752                 .elem_len       = QMI_WLFW_MAX_NUM_SVC_V01,
753                 .elem_size      = sizeof(struct wlfw_ce_svc_pipe_cfg_s_v01),
754                 .array_type       = VAR_LEN_ARRAY,
755                 .tlv_type       = 0x12,
756                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
757                                            svc_cfg),
758                 .ei_array      = wlfw_ce_svc_pipe_cfg_s_v01_ei,
759         },
760         {
761                 .data_type      = QMI_OPT_FLAG,
762                 .elem_len       = 1,
763                 .elem_size      = sizeof(u8),
764                 .array_type     = NO_ARRAY,
765                 .tlv_type       = 0x13,
766                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
767                                            shadow_reg_valid),
768         },
769         {
770                 .data_type      = QMI_DATA_LEN,
771                 .elem_len       = 1,
772                 .elem_size      = sizeof(u8),
773                 .array_type     = NO_ARRAY,
774                 .tlv_type       = 0x13,
775                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
776                                            shadow_reg_len),
777         },
778         {
779                 .data_type      = QMI_STRUCT,
780                 .elem_len       = QMI_WLFW_MAX_NUM_SHADOW_REG_V01,
781                 .elem_size      = sizeof(struct wlfw_shadow_reg_cfg_s_v01),
782                 .array_type       = VAR_LEN_ARRAY,
783                 .tlv_type       = 0x13,
784                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
785                                            shadow_reg),
786                 .ei_array      = wlfw_shadow_reg_cfg_s_v01_ei,
787         },
788         {
789                 .data_type      = QMI_OPT_FLAG,
790                 .elem_len       = 1,
791                 .elem_size      = sizeof(u8),
792                 .array_type     = NO_ARRAY,
793                 .tlv_type       = 0x14,
794                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
795                                            shadow_reg_v2_valid),
796         },
797         {
798                 .data_type      = QMI_DATA_LEN,
799                 .elem_len       = 1,
800                 .elem_size      = sizeof(u8),
801                 .array_type     = NO_ARRAY,
802                 .tlv_type       = 0x14,
803                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
804                                            shadow_reg_v2_len),
805         },
806         {
807                 .data_type      = QMI_STRUCT,
808                 .elem_len       = QMI_WLFW_MAX_SHADOW_REG_V2,
809                 .elem_size      = sizeof(struct wlfw_shadow_reg_v2_cfg_s_v01),
810                 .array_type       = VAR_LEN_ARRAY,
811                 .tlv_type       = 0x14,
812                 .offset         = offsetof(struct wlfw_wlan_cfg_req_msg_v01,
813                                            shadow_reg_v2),
814                 .ei_array      = wlfw_shadow_reg_v2_cfg_s_v01_ei,
815         },
816         {}
817 };
818
819 struct qmi_elem_info wlfw_wlan_cfg_resp_msg_v01_ei[] = {
820         {
821                 .data_type      = QMI_STRUCT,
822                 .elem_len       = 1,
823                 .elem_size      = sizeof(struct qmi_response_type_v01),
824                 .array_type     = NO_ARRAY,
825                 .tlv_type       = 0x02,
826                 .offset         = offsetof(struct wlfw_wlan_cfg_resp_msg_v01,
827                                            resp),
828                 .ei_array      = qmi_response_type_v01_ei,
829         },
830         {}
831 };
832
833 struct qmi_elem_info wlfw_cap_req_msg_v01_ei[] = {
834         {}
835 };
836
837 struct qmi_elem_info wlfw_cap_resp_msg_v01_ei[] = {
838         {
839                 .data_type      = QMI_STRUCT,
840                 .elem_len       = 1,
841                 .elem_size      = sizeof(struct qmi_response_type_v01),
842                 .array_type     = NO_ARRAY,
843                 .tlv_type       = 0x02,
844                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
845                                            resp),
846                 .ei_array      = qmi_response_type_v01_ei,
847         },
848         {
849                 .data_type      = QMI_OPT_FLAG,
850                 .elem_len       = 1,
851                 .elem_size      = sizeof(u8),
852                 .array_type     = NO_ARRAY,
853                 .tlv_type       = 0x10,
854                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
855                                            chip_info_valid),
856         },
857         {
858                 .data_type      = QMI_STRUCT,
859                 .elem_len       = 1,
860                 .elem_size      = sizeof(struct wlfw_rf_chip_info_s_v01),
861                 .array_type     = NO_ARRAY,
862                 .tlv_type       = 0x10,
863                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
864                                            chip_info),
865                 .ei_array      = wlfw_rf_chip_info_s_v01_ei,
866         },
867         {
868                 .data_type      = QMI_OPT_FLAG,
869                 .elem_len       = 1,
870                 .elem_size      = sizeof(u8),
871                 .array_type     = NO_ARRAY,
872                 .tlv_type       = 0x11,
873                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
874                                            board_info_valid),
875         },
876         {
877                 .data_type      = QMI_STRUCT,
878                 .elem_len       = 1,
879                 .elem_size      = sizeof(struct wlfw_rf_board_info_s_v01),
880                 .array_type     = NO_ARRAY,
881                 .tlv_type       = 0x11,
882                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
883                                            board_info),
884                 .ei_array      = wlfw_rf_board_info_s_v01_ei,
885         },
886         {
887                 .data_type      = QMI_OPT_FLAG,
888                 .elem_len       = 1,
889                 .elem_size      = sizeof(u8),
890                 .array_type     = NO_ARRAY,
891                 .tlv_type       = 0x12,
892                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
893                                            soc_info_valid),
894         },
895         {
896                 .data_type      = QMI_STRUCT,
897                 .elem_len       = 1,
898                 .elem_size      = sizeof(struct wlfw_soc_info_s_v01),
899                 .array_type     = NO_ARRAY,
900                 .tlv_type       = 0x12,
901                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
902                                            soc_info),
903                 .ei_array      = wlfw_soc_info_s_v01_ei,
904         },
905         {
906                 .data_type      = QMI_OPT_FLAG,
907                 .elem_len       = 1,
908                 .elem_size      = sizeof(u8),
909                 .array_type     = NO_ARRAY,
910                 .tlv_type       = 0x13,
911                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
912                                            fw_version_info_valid),
913         },
914         {
915                 .data_type      = QMI_STRUCT,
916                 .elem_len       = 1,
917                 .elem_size      = sizeof(struct wlfw_fw_version_info_s_v01),
918                 .array_type     = NO_ARRAY,
919                 .tlv_type       = 0x13,
920                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
921                                            fw_version_info),
922                 .ei_array      = wlfw_fw_version_info_s_v01_ei,
923         },
924         {
925                 .data_type      = QMI_OPT_FLAG,
926                 .elem_len       = 1,
927                 .elem_size      = sizeof(u8),
928                 .array_type     = NO_ARRAY,
929                 .tlv_type       = 0x14,
930                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
931                                            fw_build_id_valid),
932         },
933         {
934                 .data_type      = QMI_STRING,
935                 .elem_len       = QMI_WLFW_MAX_BUILD_ID_LEN_V01 + 1,
936                 .elem_size      = sizeof(char),
937                 .array_type     = NO_ARRAY,
938                 .tlv_type       = 0x14,
939                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
940                                            fw_build_id),
941         },
942         {
943                 .data_type      = QMI_OPT_FLAG,
944                 .elem_len       = 1,
945                 .elem_size      = sizeof(u8),
946                 .array_type     = NO_ARRAY,
947                 .tlv_type       = 0x15,
948                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
949                                            num_macs_valid),
950         },
951         {
952                 .data_type      = QMI_UNSIGNED_1_BYTE,
953                 .elem_len       = 1,
954                 .elem_size      = sizeof(u8),
955                 .array_type     = NO_ARRAY,
956                 .tlv_type       = 0x15,
957                 .offset         = offsetof(struct wlfw_cap_resp_msg_v01,
958                                            num_macs),
959         },
960         {}
961 };
962
963 struct qmi_elem_info wlfw_bdf_download_req_msg_v01_ei[] = {
964         {
965                 .data_type      = QMI_UNSIGNED_1_BYTE,
966                 .elem_len       = 1,
967                 .elem_size      = sizeof(u8),
968                 .array_type     = NO_ARRAY,
969                 .tlv_type       = 0x01,
970                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
971                                            valid),
972         },
973         {
974                 .data_type      = QMI_OPT_FLAG,
975                 .elem_len       = 1,
976                 .elem_size      = sizeof(u8),
977                 .array_type     = NO_ARRAY,
978                 .tlv_type       = 0x10,
979                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
980                                            file_id_valid),
981         },
982         {
983                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
984                 .elem_len       = 1,
985                 .elem_size      = sizeof(enum wlfw_cal_temp_id_enum_v01),
986                 .array_type     = NO_ARRAY,
987                 .tlv_type       = 0x10,
988                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
989                                            file_id),
990         },
991         {
992                 .data_type      = QMI_OPT_FLAG,
993                 .elem_len       = 1,
994                 .elem_size      = sizeof(u8),
995                 .array_type     = NO_ARRAY,
996                 .tlv_type       = 0x11,
997                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
998                                            total_size_valid),
999         },
1000         {
1001                 .data_type      = QMI_UNSIGNED_4_BYTE,
1002                 .elem_len       = 1,
1003                 .elem_size      = sizeof(u32),
1004                 .array_type     = NO_ARRAY,
1005                 .tlv_type       = 0x11,
1006                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1007                                            total_size),
1008         },
1009         {
1010                 .data_type      = QMI_OPT_FLAG,
1011                 .elem_len       = 1,
1012                 .elem_size      = sizeof(u8),
1013                 .array_type     = NO_ARRAY,
1014                 .tlv_type       = 0x12,
1015                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1016                                            seg_id_valid),
1017         },
1018         {
1019                 .data_type      = QMI_UNSIGNED_4_BYTE,
1020                 .elem_len       = 1,
1021                 .elem_size      = sizeof(u32),
1022                 .array_type     = NO_ARRAY,
1023                 .tlv_type       = 0x12,
1024                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1025                                            seg_id),
1026         },
1027         {
1028                 .data_type      = QMI_OPT_FLAG,
1029                 .elem_len       = 1,
1030                 .elem_size      = sizeof(u8),
1031                 .array_type     = NO_ARRAY,
1032                 .tlv_type       = 0x13,
1033                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1034                                            data_valid),
1035         },
1036         {
1037                 .data_type      = QMI_DATA_LEN,
1038                 .elem_len       = 1,
1039                 .elem_size      = sizeof(u16),
1040                 .array_type     = NO_ARRAY,
1041                 .tlv_type       = 0x13,
1042                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1043                                            data_len),
1044         },
1045         {
1046                 .data_type      = QMI_UNSIGNED_1_BYTE,
1047                 .elem_len       = QMI_WLFW_MAX_DATA_SIZE_V01,
1048                 .elem_size      = sizeof(u8),
1049                 .array_type       = VAR_LEN_ARRAY,
1050                 .tlv_type       = 0x13,
1051                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1052                                            data),
1053         },
1054         {
1055                 .data_type      = QMI_OPT_FLAG,
1056                 .elem_len       = 1,
1057                 .elem_size      = sizeof(u8),
1058                 .array_type     = NO_ARRAY,
1059                 .tlv_type       = 0x14,
1060                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1061                                            end_valid),
1062         },
1063         {
1064                 .data_type      = QMI_UNSIGNED_1_BYTE,
1065                 .elem_len       = 1,
1066                 .elem_size      = sizeof(u8),
1067                 .array_type     = NO_ARRAY,
1068                 .tlv_type       = 0x14,
1069                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1070                                            end),
1071         },
1072         {
1073                 .data_type      = QMI_OPT_FLAG,
1074                 .elem_len       = 1,
1075                 .elem_size      = sizeof(u8),
1076                 .array_type     = NO_ARRAY,
1077                 .tlv_type       = 0x15,
1078                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1079                                            bdf_type_valid),
1080         },
1081         {
1082                 .data_type      = QMI_UNSIGNED_1_BYTE,
1083                 .elem_len       = 1,
1084                 .elem_size      = sizeof(u8),
1085                 .array_type     = NO_ARRAY,
1086                 .tlv_type       = 0x15,
1087                 .offset         = offsetof(struct wlfw_bdf_download_req_msg_v01,
1088                                            bdf_type),
1089         },
1090         {}
1091 };
1092
1093 struct qmi_elem_info wlfw_bdf_download_resp_msg_v01_ei[] = {
1094         {
1095                 .data_type      = QMI_STRUCT,
1096                 .elem_len       = 1,
1097                 .elem_size      = sizeof(struct qmi_response_type_v01),
1098                 .array_type     = NO_ARRAY,
1099                 .tlv_type       = 0x02,
1100                 .offset         = offsetof(struct wlfw_bdf_download_resp_msg_v01,
1101                                            resp),
1102                 .ei_array      = qmi_response_type_v01_ei,
1103         },
1104         {}
1105 };
1106
1107 struct qmi_elem_info wlfw_cal_report_req_msg_v01_ei[] = {
1108         {
1109                 .data_type      = QMI_DATA_LEN,
1110                 .elem_len       = 1,
1111                 .elem_size      = sizeof(u8),
1112                 .array_type     = NO_ARRAY,
1113                 .tlv_type       = 0x01,
1114                 .offset         = offsetof(struct wlfw_cal_report_req_msg_v01,
1115                                            meta_data_len),
1116         },
1117         {
1118                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
1119                 .elem_len       = QMI_WLFW_MAX_NUM_CAL_V01,
1120                 .elem_size      = sizeof(enum wlfw_cal_temp_id_enum_v01),
1121                 .array_type       = VAR_LEN_ARRAY,
1122                 .tlv_type       = 0x01,
1123                 .offset         = offsetof(struct wlfw_cal_report_req_msg_v01,
1124                                            meta_data),
1125         },
1126         {
1127                 .data_type      = QMI_OPT_FLAG,
1128                 .elem_len       = 1,
1129                 .elem_size      = sizeof(u8),
1130                 .array_type     = NO_ARRAY,
1131                 .tlv_type       = 0x10,
1132                 .offset         = offsetof(struct wlfw_cal_report_req_msg_v01,
1133                                            xo_cal_data_valid),
1134         },
1135         {
1136                 .data_type      = QMI_UNSIGNED_1_BYTE,
1137                 .elem_len       = 1,
1138                 .elem_size      = sizeof(u8),
1139                 .array_type     = NO_ARRAY,
1140                 .tlv_type       = 0x10,
1141                 .offset         = offsetof(struct wlfw_cal_report_req_msg_v01,
1142                                            xo_cal_data),
1143         },
1144         {}
1145 };
1146
1147 struct qmi_elem_info wlfw_cal_report_resp_msg_v01_ei[] = {
1148         {
1149                 .data_type      = QMI_STRUCT,
1150                 .elem_len       = 1,
1151                 .elem_size      = sizeof(struct qmi_response_type_v01),
1152                 .array_type     = NO_ARRAY,
1153                 .tlv_type       = 0x02,
1154                 .offset         = offsetof(struct wlfw_cal_report_resp_msg_v01,
1155                                            resp),
1156                 .ei_array      = qmi_response_type_v01_ei,
1157         },
1158         {}
1159 };
1160
1161 struct qmi_elem_info wlfw_initiate_cal_download_ind_msg_v01_ei[] = {
1162         {
1163                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
1164                 .elem_len       = 1,
1165                 .elem_size      = sizeof(enum wlfw_cal_temp_id_enum_v01),
1166                 .array_type     = NO_ARRAY,
1167                 .tlv_type       = 0x01,
1168                 .offset         = offsetof(struct wlfw_initiate_cal_download_ind_msg_v01,
1169                                            cal_id),
1170         },
1171         {}
1172 };
1173
1174 struct qmi_elem_info wlfw_cal_download_req_msg_v01_ei[] = {
1175         {
1176                 .data_type      = QMI_UNSIGNED_1_BYTE,
1177                 .elem_len       = 1,
1178                 .elem_size      = sizeof(u8),
1179                 .array_type     = NO_ARRAY,
1180                 .tlv_type       = 0x01,
1181                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1182                                            valid),
1183         },
1184         {
1185                 .data_type      = QMI_OPT_FLAG,
1186                 .elem_len       = 1,
1187                 .elem_size      = sizeof(u8),
1188                 .array_type     = NO_ARRAY,
1189                 .tlv_type       = 0x10,
1190                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1191                                            file_id_valid),
1192         },
1193         {
1194                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
1195                 .elem_len       = 1,
1196                 .elem_size      = sizeof(enum wlfw_cal_temp_id_enum_v01),
1197                 .array_type     = NO_ARRAY,
1198                 .tlv_type       = 0x10,
1199                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1200                                            file_id),
1201         },
1202         {
1203                 .data_type      = QMI_OPT_FLAG,
1204                 .elem_len       = 1,
1205                 .elem_size      = sizeof(u8),
1206                 .array_type     = NO_ARRAY,
1207                 .tlv_type       = 0x11,
1208                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1209                                            total_size_valid),
1210         },
1211         {
1212                 .data_type      = QMI_UNSIGNED_4_BYTE,
1213                 .elem_len       = 1,
1214                 .elem_size      = sizeof(u32),
1215                 .array_type     = NO_ARRAY,
1216                 .tlv_type       = 0x11,
1217                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1218                                            total_size),
1219         },
1220         {
1221                 .data_type      = QMI_OPT_FLAG,
1222                 .elem_len       = 1,
1223                 .elem_size      = sizeof(u8),
1224                 .array_type     = NO_ARRAY,
1225                 .tlv_type       = 0x12,
1226                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1227                                            seg_id_valid),
1228         },
1229         {
1230                 .data_type      = QMI_UNSIGNED_4_BYTE,
1231                 .elem_len       = 1,
1232                 .elem_size      = sizeof(u32),
1233                 .array_type     = NO_ARRAY,
1234                 .tlv_type       = 0x12,
1235                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1236                                            seg_id),
1237         },
1238         {
1239                 .data_type      = QMI_OPT_FLAG,
1240                 .elem_len       = 1,
1241                 .elem_size      = sizeof(u8),
1242                 .array_type     = NO_ARRAY,
1243                 .tlv_type       = 0x13,
1244                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1245                                            data_valid),
1246         },
1247         {
1248                 .data_type      = QMI_DATA_LEN,
1249                 .elem_len       = 1,
1250                 .elem_size      = sizeof(u16),
1251                 .array_type     = NO_ARRAY,
1252                 .tlv_type       = 0x13,
1253                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1254                                            data_len),
1255         },
1256         {
1257                 .data_type      = QMI_UNSIGNED_1_BYTE,
1258                 .elem_len       = QMI_WLFW_MAX_DATA_SIZE_V01,
1259                 .elem_size      = sizeof(u8),
1260                 .array_type       = VAR_LEN_ARRAY,
1261                 .tlv_type       = 0x13,
1262                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1263                                            data),
1264         },
1265         {
1266                 .data_type      = QMI_OPT_FLAG,
1267                 .elem_len       = 1,
1268                 .elem_size      = sizeof(u8),
1269                 .array_type     = NO_ARRAY,
1270                 .tlv_type       = 0x14,
1271                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1272                                            end_valid),
1273         },
1274         {
1275                 .data_type      = QMI_UNSIGNED_1_BYTE,
1276                 .elem_len       = 1,
1277                 .elem_size      = sizeof(u8),
1278                 .array_type     = NO_ARRAY,
1279                 .tlv_type       = 0x14,
1280                 .offset         = offsetof(struct wlfw_cal_download_req_msg_v01,
1281                                            end),
1282         },
1283         {}
1284 };
1285
1286 struct qmi_elem_info wlfw_cal_download_resp_msg_v01_ei[] = {
1287         {
1288                 .data_type      = QMI_STRUCT,
1289                 .elem_len       = 1,
1290                 .elem_size      = sizeof(struct qmi_response_type_v01),
1291                 .array_type     = NO_ARRAY,
1292                 .tlv_type       = 0x02,
1293                 .offset         = offsetof(struct wlfw_cal_download_resp_msg_v01,
1294                                            resp),
1295                 .ei_array      = qmi_response_type_v01_ei,
1296         },
1297         {}
1298 };
1299
1300 struct qmi_elem_info wlfw_initiate_cal_update_ind_msg_v01_ei[] = {
1301         {
1302                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
1303                 .elem_len       = 1,
1304                 .elem_size      = sizeof(enum wlfw_cal_temp_id_enum_v01),
1305                 .array_type     = NO_ARRAY,
1306                 .tlv_type       = 0x01,
1307                 .offset         = offsetof(struct wlfw_initiate_cal_update_ind_msg_v01,
1308                                            cal_id),
1309         },
1310         {
1311                 .data_type      = QMI_UNSIGNED_4_BYTE,
1312                 .elem_len       = 1,
1313                 .elem_size      = sizeof(u32),
1314                 .array_type     = NO_ARRAY,
1315                 .tlv_type       = 0x02,
1316                 .offset         = offsetof(struct wlfw_initiate_cal_update_ind_msg_v01,
1317                                            total_size),
1318         },
1319         {}
1320 };
1321
1322 struct qmi_elem_info wlfw_cal_update_req_msg_v01_ei[] = {
1323         {
1324                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
1325                 .elem_len       = 1,
1326                 .elem_size      = sizeof(enum wlfw_cal_temp_id_enum_v01),
1327                 .array_type     = NO_ARRAY,
1328                 .tlv_type       = 0x01,
1329                 .offset         = offsetof(struct wlfw_cal_update_req_msg_v01,
1330                                            cal_id),
1331         },
1332         {
1333                 .data_type      = QMI_UNSIGNED_4_BYTE,
1334                 .elem_len       = 1,
1335                 .elem_size      = sizeof(u32),
1336                 .array_type     = NO_ARRAY,
1337                 .tlv_type       = 0x02,
1338                 .offset         = offsetof(struct wlfw_cal_update_req_msg_v01,
1339                                            seg_id),
1340         },
1341         {}
1342 };
1343
1344 struct qmi_elem_info wlfw_cal_update_resp_msg_v01_ei[] = {
1345         {
1346                 .data_type      = QMI_STRUCT,
1347                 .elem_len       = 1,
1348                 .elem_size      = sizeof(struct qmi_response_type_v01),
1349                 .array_type     = NO_ARRAY,
1350                 .tlv_type       = 0x02,
1351                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1352                                            resp),
1353                 .ei_array      = qmi_response_type_v01_ei,
1354         },
1355         {
1356                 .data_type      = QMI_OPT_FLAG,
1357                 .elem_len       = 1,
1358                 .elem_size      = sizeof(u8),
1359                 .array_type     = NO_ARRAY,
1360                 .tlv_type       = 0x10,
1361                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1362                                            file_id_valid),
1363         },
1364         {
1365                 .data_type      = QMI_SIGNED_4_BYTE_ENUM,
1366                 .elem_len       = 1,
1367                 .elem_size      = sizeof(enum wlfw_cal_temp_id_enum_v01),
1368                 .array_type     = NO_ARRAY,
1369                 .tlv_type       = 0x10,
1370                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1371                                            file_id),
1372         },
1373         {
1374                 .data_type      = QMI_OPT_FLAG,
1375                 .elem_len       = 1,
1376                 .elem_size      = sizeof(u8),
1377                 .array_type     = NO_ARRAY,
1378                 .tlv_type       = 0x11,
1379                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1380                                            total_size_valid),
1381         },
1382         {
1383                 .data_type      = QMI_UNSIGNED_4_BYTE,
1384                 .elem_len       = 1,
1385                 .elem_size      = sizeof(u32),
1386                 .array_type     = NO_ARRAY,
1387                 .tlv_type       = 0x11,
1388                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1389                                            total_size),
1390         },
1391         {
1392                 .data_type      = QMI_OPT_FLAG,
1393                 .elem_len       = 1,
1394                 .elem_size      = sizeof(u8),
1395                 .array_type     = NO_ARRAY,
1396                 .tlv_type       = 0x12,
1397                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1398                                            seg_id_valid),
1399         },
1400         {
1401                 .data_type      = QMI_UNSIGNED_4_BYTE,
1402                 .elem_len       = 1,
1403                 .elem_size      = sizeof(u32),
1404                 .array_type     = NO_ARRAY,
1405                 .tlv_type       = 0x12,
1406                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1407                                            seg_id),
1408         },
1409         {
1410                 .data_type      = QMI_OPT_FLAG,
1411                 .elem_len       = 1,
1412                 .elem_size      = sizeof(u8),
1413                 .array_type     = NO_ARRAY,
1414                 .tlv_type       = 0x13,
1415                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1416                                            data_valid),
1417         },
1418         {
1419                 .data_type      = QMI_DATA_LEN,
1420                 .elem_len       = 1,
1421                 .elem_size      = sizeof(u16),
1422                 .array_type     = NO_ARRAY,
1423                 .tlv_type       = 0x13,
1424                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1425                                            data_len),
1426         },
1427         {
1428                 .data_type      = QMI_UNSIGNED_1_BYTE,
1429                 .elem_len       = QMI_WLFW_MAX_DATA_SIZE_V01,
1430                 .elem_size      = sizeof(u8),
1431                 .array_type       = VAR_LEN_ARRAY,
1432                 .tlv_type       = 0x13,
1433                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1434                                            data),
1435         },
1436         {
1437                 .data_type      = QMI_OPT_FLAG,
1438                 .elem_len       = 1,
1439                 .elem_size      = sizeof(u8),
1440                 .array_type     = NO_ARRAY,
1441                 .tlv_type       = 0x14,
1442                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1443                                            end_valid),
1444         },
1445         {
1446                 .data_type      = QMI_UNSIGNED_1_BYTE,
1447                 .elem_len       = 1,
1448                 .elem_size      = sizeof(u8),
1449                 .array_type     = NO_ARRAY,
1450                 .tlv_type       = 0x14,
1451                 .offset         = offsetof(struct wlfw_cal_update_resp_msg_v01,
1452                                            end),
1453         },
1454         {}
1455 };
1456
1457 struct qmi_elem_info wlfw_msa_info_req_msg_v01_ei[] = {
1458         {
1459                 .data_type      = QMI_UNSIGNED_8_BYTE,
1460                 .elem_len       = 1,
1461                 .elem_size      = sizeof(u64),
1462                 .array_type     = NO_ARRAY,
1463                 .tlv_type       = 0x01,
1464                 .offset         = offsetof(struct wlfw_msa_info_req_msg_v01,
1465                                            msa_addr),
1466         },
1467         {
1468                 .data_type      = QMI_UNSIGNED_4_BYTE,
1469                 .elem_len       = 1,
1470                 .elem_size      = sizeof(u32),
1471                 .array_type     = NO_ARRAY,
1472                 .tlv_type       = 0x02,
1473                 .offset         = offsetof(struct wlfw_msa_info_req_msg_v01,
1474                                            size),
1475         },
1476         {}
1477 };
1478
1479 struct qmi_elem_info wlfw_msa_info_resp_msg_v01_ei[] = {
1480         {
1481                 .data_type      = QMI_STRUCT,
1482                 .elem_len       = 1,
1483                 .elem_size      = sizeof(struct qmi_response_type_v01),
1484                 .array_type     = NO_ARRAY,
1485                 .tlv_type       = 0x02,
1486                 .offset         = offsetof(struct wlfw_msa_info_resp_msg_v01,
1487                                            resp),
1488                 .ei_array      = qmi_response_type_v01_ei,
1489         },
1490         {
1491                 .data_type      = QMI_DATA_LEN,
1492                 .elem_len       = 1,
1493                 .elem_size      = sizeof(u8),
1494                 .array_type     = NO_ARRAY,
1495                 .tlv_type       = 0x03,
1496                 .offset         = offsetof(struct wlfw_msa_info_resp_msg_v01,
1497                                            mem_region_info_len),
1498         },
1499         {
1500                 .data_type      = QMI_STRUCT,
1501                 .elem_len       = QMI_WLFW_MAX_MEM_REG_V01,
1502                 .elem_size      = sizeof(struct wlfw_memory_region_info_s_v01),
1503                 .array_type       = VAR_LEN_ARRAY,
1504                 .tlv_type       = 0x03,
1505                 .offset         = offsetof(struct wlfw_msa_info_resp_msg_v01,
1506                                            mem_region_info),
1507                 .ei_array      = wlfw_memory_region_info_s_v01_ei,
1508         },
1509         {}
1510 };
1511
1512 struct qmi_elem_info wlfw_msa_ready_req_msg_v01_ei[] = {
1513         {}
1514 };
1515
1516 struct qmi_elem_info wlfw_msa_ready_resp_msg_v01_ei[] = {
1517         {
1518                 .data_type      = QMI_STRUCT,
1519                 .elem_len       = 1,
1520                 .elem_size      = sizeof(struct qmi_response_type_v01),
1521                 .array_type     = NO_ARRAY,
1522                 .tlv_type       = 0x02,
1523                 .offset         = offsetof(struct wlfw_msa_ready_resp_msg_v01,
1524                                            resp),
1525                 .ei_array      = qmi_response_type_v01_ei,
1526         },
1527         {}
1528 };
1529
1530 struct qmi_elem_info wlfw_ini_req_msg_v01_ei[] = {
1531         {
1532                 .data_type      = QMI_OPT_FLAG,
1533                 .elem_len       = 1,
1534                 .elem_size      = sizeof(u8),
1535                 .array_type     = NO_ARRAY,
1536                 .tlv_type       = 0x10,
1537                 .offset         = offsetof(struct wlfw_ini_req_msg_v01,
1538                                            enablefwlog_valid),
1539         },
1540         {
1541                 .data_type      = QMI_UNSIGNED_1_BYTE,
1542                 .elem_len       = 1,
1543                 .elem_size      = sizeof(u8),
1544                 .array_type     = NO_ARRAY,
1545                 .tlv_type       = 0x10,
1546                 .offset         = offsetof(struct wlfw_ini_req_msg_v01,
1547                                            enablefwlog),
1548         },
1549         {}
1550 };
1551
1552 struct qmi_elem_info wlfw_ini_resp_msg_v01_ei[] = {
1553         {
1554                 .data_type      = QMI_STRUCT,
1555                 .elem_len       = 1,
1556                 .elem_size      = sizeof(struct qmi_response_type_v01),
1557                 .array_type     = NO_ARRAY,
1558                 .tlv_type       = 0x02,
1559                 .offset         = offsetof(struct wlfw_ini_resp_msg_v01,
1560                                            resp),
1561                 .ei_array      = qmi_response_type_v01_ei,
1562         },
1563         {}
1564 };
1565
1566 struct qmi_elem_info wlfw_athdiag_read_req_msg_v01_ei[] = {
1567         {
1568                 .data_type      = QMI_UNSIGNED_4_BYTE,
1569                 .elem_len       = 1,
1570                 .elem_size      = sizeof(u32),
1571                 .array_type     = NO_ARRAY,
1572                 .tlv_type       = 0x01,
1573                 .offset         = offsetof(struct wlfw_athdiag_read_req_msg_v01,
1574                                            offset),
1575         },
1576         {
1577                 .data_type      = QMI_UNSIGNED_4_BYTE,
1578                 .elem_len       = 1,
1579                 .elem_size      = sizeof(u32),
1580                 .array_type     = NO_ARRAY,
1581                 .tlv_type       = 0x02,
1582                 .offset         = offsetof(struct wlfw_athdiag_read_req_msg_v01,
1583                                            mem_type),
1584         },
1585         {
1586                 .data_type      = QMI_UNSIGNED_4_BYTE,
1587                 .elem_len       = 1,
1588                 .elem_size      = sizeof(u32),
1589                 .array_type     = NO_ARRAY,
1590                 .tlv_type       = 0x03,
1591                 .offset         = offsetof(struct wlfw_athdiag_read_req_msg_v01,
1592                                            data_len),
1593         },
1594         {}
1595 };
1596
1597 struct qmi_elem_info wlfw_athdiag_read_resp_msg_v01_ei[] = {
1598         {
1599                 .data_type      = QMI_STRUCT,
1600                 .elem_len       = 1,
1601                 .elem_size      = sizeof(struct qmi_response_type_v01),
1602                 .array_type     = NO_ARRAY,
1603                 .tlv_type       = 0x02,
1604                 .offset         = offsetof(struct wlfw_athdiag_read_resp_msg_v01,
1605                                            resp),
1606                 .ei_array      = qmi_response_type_v01_ei,
1607         },
1608         {
1609                 .data_type      = QMI_OPT_FLAG,
1610                 .elem_len       = 1,
1611                 .elem_size      = sizeof(u8),
1612                 .array_type     = NO_ARRAY,
1613                 .tlv_type       = 0x10,
1614                 .offset         = offsetof(struct wlfw_athdiag_read_resp_msg_v01,
1615                                            data_valid),
1616         },
1617         {
1618                 .data_type      = QMI_DATA_LEN,
1619                 .elem_len       = 1,
1620                 .elem_size      = sizeof(u16),
1621                 .array_type     = NO_ARRAY,
1622                 .tlv_type       = 0x10,
1623                 .offset         = offsetof(struct wlfw_athdiag_read_resp_msg_v01,
1624                                            data_len),
1625         },
1626         {
1627                 .data_type      = QMI_UNSIGNED_1_BYTE,
1628                 .elem_len       = QMI_WLFW_MAX_ATHDIAG_DATA_SIZE_V01,
1629                 .elem_size      = sizeof(u8),
1630                 .array_type       = VAR_LEN_ARRAY,
1631                 .tlv_type       = 0x10,
1632                 .offset         = offsetof(struct wlfw_athdiag_read_resp_msg_v01,
1633                                            data),
1634         },
1635         {}
1636 };
1637
1638 struct qmi_elem_info wlfw_athdiag_write_req_msg_v01_ei[] = {
1639         {
1640                 .data_type      = QMI_UNSIGNED_4_BYTE,
1641                 .elem_len       = 1,
1642                 .elem_size      = sizeof(u32),
1643                 .array_type     = NO_ARRAY,
1644                 .tlv_type       = 0x01,
1645                 .offset         = offsetof(struct wlfw_athdiag_write_req_msg_v01,
1646                                            offset),
1647         },
1648         {
1649                 .data_type      = QMI_UNSIGNED_4_BYTE,
1650                 .elem_len       = 1,
1651                 .elem_size      = sizeof(u32),
1652                 .array_type     = NO_ARRAY,
1653                 .tlv_type       = 0x02,
1654                 .offset         = offsetof(struct wlfw_athdiag_write_req_msg_v01,
1655                                            mem_type),
1656         },
1657         {
1658                 .data_type      = QMI_DATA_LEN,
1659                 .elem_len       = 1,
1660                 .elem_size      = sizeof(u16),
1661                 .array_type     = NO_ARRAY,
1662                 .tlv_type       = 0x03,
1663                 .offset         = offsetof(struct wlfw_athdiag_write_req_msg_v01,
1664                                            data_len),
1665         },
1666         {
1667                 .data_type      = QMI_UNSIGNED_1_BYTE,
1668                 .elem_len       = QMI_WLFW_MAX_ATHDIAG_DATA_SIZE_V01,
1669                 .elem_size      = sizeof(u8),
1670                 .array_type       = VAR_LEN_ARRAY,
1671                 .tlv_type       = 0x03,
1672                 .offset         = offsetof(struct wlfw_athdiag_write_req_msg_v01,
1673                                            data),
1674         },
1675         {}
1676 };
1677
1678 struct qmi_elem_info wlfw_athdiag_write_resp_msg_v01_ei[] = {
1679         {
1680                 .data_type      = QMI_STRUCT,
1681                 .elem_len       = 1,
1682                 .elem_size      = sizeof(struct qmi_response_type_v01),
1683                 .array_type     = NO_ARRAY,
1684                 .tlv_type       = 0x02,
1685                 .offset         = offsetof(struct wlfw_athdiag_write_resp_msg_v01,
1686                                            resp),
1687                 .ei_array      = qmi_response_type_v01_ei,
1688         },
1689         {}
1690 };
1691
1692 struct qmi_elem_info wlfw_vbatt_req_msg_v01_ei[] = {
1693         {
1694                 .data_type      = QMI_UNSIGNED_8_BYTE,
1695                 .elem_len       = 1,
1696                 .elem_size      = sizeof(u64),
1697                 .array_type     = NO_ARRAY,
1698                 .tlv_type       = 0x01,
1699                 .offset         = offsetof(struct wlfw_vbatt_req_msg_v01,
1700                                            voltage_uv),
1701         },
1702         {}
1703 };
1704
1705 struct qmi_elem_info wlfw_vbatt_resp_msg_v01_ei[] = {
1706         {
1707                 .data_type      = QMI_STRUCT,
1708                 .elem_len       = 1,
1709                 .elem_size      = sizeof(struct qmi_response_type_v01),
1710                 .array_type     = NO_ARRAY,
1711                 .tlv_type       = 0x02,
1712                 .offset         = offsetof(struct wlfw_vbatt_resp_msg_v01,
1713                                            resp),
1714                 .ei_array      = qmi_response_type_v01_ei,
1715         },
1716         {}
1717 };
1718
1719 struct qmi_elem_info wlfw_mac_addr_req_msg_v01_ei[] = {
1720         {
1721                 .data_type      = QMI_OPT_FLAG,
1722                 .elem_len       = 1,
1723                 .elem_size      = sizeof(u8),
1724                 .array_type     = NO_ARRAY,
1725                 .tlv_type       = 0x10,
1726                 .offset         = offsetof(struct wlfw_mac_addr_req_msg_v01,
1727                                            mac_addr_valid),
1728         },
1729         {
1730                 .data_type      = QMI_UNSIGNED_1_BYTE,
1731                 .elem_len       = QMI_WLFW_MAC_ADDR_SIZE_V01,
1732                 .elem_size      = sizeof(u8),
1733                 .array_type       = STATIC_ARRAY,
1734                 .tlv_type       = 0x10,
1735                 .offset         = offsetof(struct wlfw_mac_addr_req_msg_v01,
1736                                            mac_addr),
1737         },
1738         {}
1739 };
1740
1741 struct qmi_elem_info wlfw_mac_addr_resp_msg_v01_ei[] = {
1742         {
1743                 .data_type      = QMI_STRUCT,
1744                 .elem_len       = 1,
1745                 .elem_size      = sizeof(struct qmi_response_type_v01),
1746                 .array_type     = NO_ARRAY,
1747                 .tlv_type       = 0x02,
1748                 .offset         = offsetof(struct wlfw_mac_addr_resp_msg_v01,
1749                                            resp),
1750                 .ei_array      = qmi_response_type_v01_ei,
1751         },
1752         {}
1753 };
1754
1755 struct qmi_elem_info wlfw_host_cap_req_msg_v01_ei[] = {
1756         {
1757                 .data_type      = QMI_OPT_FLAG,
1758                 .elem_len       = 1,
1759                 .elem_size      = sizeof(u8),
1760                 .array_type     = NO_ARRAY,
1761                 .tlv_type       = 0x10,
1762                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1763                                            daemon_support_valid),
1764         },
1765         {
1766                 .data_type      = QMI_UNSIGNED_4_BYTE,
1767                 .elem_len       = 1,
1768                 .elem_size      = sizeof(u32),
1769                 .array_type     = NO_ARRAY,
1770                 .tlv_type       = 0x10,
1771                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1772                                            daemon_support),
1773         },
1774         {
1775                 .data_type      = QMI_OPT_FLAG,
1776                 .elem_len       = 1,
1777                 .elem_size      = sizeof(u8),
1778                 .array_type     = NO_ARRAY,
1779                 .tlv_type       = 0x11,
1780                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1781                                            wake_msi_valid),
1782         },
1783         {
1784                 .data_type      = QMI_UNSIGNED_4_BYTE,
1785                 .elem_len       = 1,
1786                 .elem_size      = sizeof(u32),
1787                 .array_type     = NO_ARRAY,
1788                 .tlv_type       = 0x11,
1789                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1790                                            wake_msi),
1791         },
1792         {
1793                 .data_type      = QMI_OPT_FLAG,
1794                 .elem_len       = 1,
1795                 .elem_size      = sizeof(u8),
1796                 .array_type     = NO_ARRAY,
1797                 .tlv_type       = 0x12,
1798                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1799                                            gpios_valid),
1800         },
1801         {
1802                 .data_type      = QMI_DATA_LEN,
1803                 .elem_len       = 1,
1804                 .elem_size      = sizeof(u32),
1805                 .array_type     = NO_ARRAY,
1806                 .tlv_type       = 0x12,
1807                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1808                                            gpios_len),
1809         },
1810         {
1811                 .data_type      = QMI_UNSIGNED_4_BYTE,
1812                 .elem_len       = QMI_WLFW_MAX_NUM_GPIO_V01,
1813                 .elem_size      = sizeof(u32),
1814                 .array_type     = VAR_LEN_ARRAY,
1815                 .tlv_type       = 0x12,
1816                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1817                                            gpios),
1818         },
1819         {
1820                 .data_type      = QMI_OPT_FLAG,
1821                 .elem_len       = 1,
1822                 .elem_size      = sizeof(u8),
1823                 .array_type     = NO_ARRAY,
1824                 .tlv_type       = 0x13,
1825                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1826                                            nm_modem_valid),
1827         },
1828         {
1829                 .data_type      = QMI_UNSIGNED_1_BYTE,
1830                 .elem_len       = 1,
1831                 .elem_size      = sizeof(u8),
1832                 .array_type     = NO_ARRAY,
1833                 .tlv_type       = 0x13,
1834                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1835                                            nm_modem),
1836         },
1837         {
1838                 .data_type      = QMI_OPT_FLAG,
1839                 .elem_len       = 1,
1840                 .elem_size      = sizeof(u8),
1841                 .array_type     = NO_ARRAY,
1842                 .tlv_type       = 0x14,
1843                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1844                                            bdf_support_valid),
1845         },
1846         {
1847                 .data_type      = QMI_UNSIGNED_1_BYTE,
1848                 .elem_len       = 1,
1849                 .elem_size      = sizeof(u8),
1850                 .array_type     = NO_ARRAY,
1851                 .tlv_type       = 0x14,
1852                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1853                                            bdf_support),
1854         },
1855         {
1856                 .data_type      = QMI_OPT_FLAG,
1857                 .elem_len       = 1,
1858                 .elem_size      = sizeof(u8),
1859                 .array_type     = NO_ARRAY,
1860                 .tlv_type       = 0x15,
1861                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1862                                            bdf_cache_support_valid),
1863         },
1864         {
1865                 .data_type      = QMI_UNSIGNED_1_BYTE,
1866                 .elem_len       = 1,
1867                 .elem_size      = sizeof(u8),
1868                 .array_type     = NO_ARRAY,
1869                 .tlv_type       = 0x15,
1870                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1871                                            bdf_cache_support),
1872         },
1873         {
1874                 .data_type      = QMI_OPT_FLAG,
1875                 .elem_len       = 1,
1876                 .elem_size      = sizeof(u8),
1877                 .array_type     = NO_ARRAY,
1878                 .tlv_type       = 0x16,
1879                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1880                                            m3_support_valid),
1881         },
1882         {
1883                 .data_type      = QMI_UNSIGNED_1_BYTE,
1884                 .elem_len       = 1,
1885                 .elem_size      = sizeof(u8),
1886                 .array_type     = NO_ARRAY,
1887                 .tlv_type       = 0x16,
1888                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1889                                            m3_support),
1890         },
1891         {
1892                 .data_type      = QMI_OPT_FLAG,
1893                 .elem_len       = 1,
1894                 .elem_size      = sizeof(u8),
1895                 .array_type     = NO_ARRAY,
1896                 .tlv_type       = 0x17,
1897                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1898                                            m3_cache_support_valid),
1899         },
1900         {
1901                 .data_type      = QMI_UNSIGNED_1_BYTE,
1902                 .elem_len       = 1,
1903                 .elem_size      = sizeof(u8),
1904                 .array_type     = NO_ARRAY,
1905                 .tlv_type       = 0x17,
1906                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1907                                            m3_cache_support),
1908         },
1909         {
1910                 .data_type      = QMI_OPT_FLAG,
1911                 .elem_len       = 1,
1912                 .elem_size      = sizeof(u8),
1913                 .array_type     = NO_ARRAY,
1914                 .tlv_type       = 0x18,
1915                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1916                                            cal_filesys_support_valid),
1917         },
1918         {
1919                 .data_type      = QMI_UNSIGNED_1_BYTE,
1920                 .elem_len       = 1,
1921                 .elem_size      = sizeof(u8),
1922                 .array_type     = NO_ARRAY,
1923                 .tlv_type       = 0x18,
1924                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1925                                            cal_filesys_support),
1926         },
1927         {
1928                 .data_type      = QMI_OPT_FLAG,
1929                 .elem_len       = 1,
1930                 .elem_size      = sizeof(u8),
1931                 .array_type     = NO_ARRAY,
1932                 .tlv_type       = 0x19,
1933                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1934                                            cal_cache_support_valid),
1935         },
1936         {
1937                 .data_type      = QMI_UNSIGNED_1_BYTE,
1938                 .elem_len       = 1,
1939                 .elem_size      = sizeof(u8),
1940                 .array_type     = NO_ARRAY,
1941                 .tlv_type       = 0x19,
1942                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1943                                            cal_cache_support),
1944         },
1945         {
1946                 .data_type      = QMI_OPT_FLAG,
1947                 .elem_len       = 1,
1948                 .elem_size      = sizeof(u8),
1949                 .array_type     = NO_ARRAY,
1950                 .tlv_type       = 0x1A,
1951                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1952                                            cal_done_valid),
1953         },
1954         {
1955                 .data_type      = QMI_UNSIGNED_1_BYTE,
1956                 .elem_len       = 1,
1957                 .elem_size      = sizeof(u8),
1958                 .array_type     = NO_ARRAY,
1959                 .tlv_type       = 0x1A,
1960                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1961                                            cal_done),
1962         },
1963         {
1964                 .data_type      = QMI_OPT_FLAG,
1965                 .elem_len       = 1,
1966                 .elem_size      = sizeof(u8),
1967                 .array_type     = NO_ARRAY,
1968                 .tlv_type       = 0x1B,
1969                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1970                                            mem_bucket_valid),
1971         },
1972         {
1973                 .data_type      = QMI_UNSIGNED_4_BYTE,
1974                 .elem_len       = 1,
1975                 .elem_size      = sizeof(u32),
1976                 .array_type     = NO_ARRAY,
1977                 .tlv_type       = 0x1B,
1978                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1979                                            mem_bucket),
1980         },
1981         {
1982                 .data_type      = QMI_OPT_FLAG,
1983                 .elem_len       = 1,
1984                 .elem_size      = sizeof(u8),
1985                 .array_type     = NO_ARRAY,
1986                 .tlv_type       = 0x1C,
1987                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1988                                            mem_cfg_mode_valid),
1989         },
1990         {
1991                 .data_type      = QMI_UNSIGNED_1_BYTE,
1992                 .elem_len       = 1,
1993                 .elem_size      = sizeof(u8),
1994                 .array_type     = NO_ARRAY,
1995                 .tlv_type       = 0x1C,
1996                 .offset         = offsetof(struct wlfw_host_cap_req_msg_v01,
1997                                            mem_cfg_mode),
1998         },
1999         {}
2000 };
2001
2002 struct qmi_elem_info wlfw_host_cap_resp_msg_v01_ei[] = {
2003         {
2004                 .data_type      = QMI_STRUCT,
2005                 .elem_len       = 1,
2006                 .elem_size      = sizeof(struct qmi_response_type_v01),
2007                 .array_type     = NO_ARRAY,
2008                 .tlv_type       = 0x02,
2009                 .offset         = offsetof(struct wlfw_host_cap_resp_msg_v01,
2010                                            resp),
2011                 .ei_array      = qmi_response_type_v01_ei,
2012         },
2013         {}
2014 };
2015
2016 struct qmi_elem_info wlfw_request_mem_ind_msg_v01_ei[] = {
2017         {
2018                 .data_type      = QMI_DATA_LEN,
2019                 .elem_len       = 1,
2020                 .elem_size      = sizeof(u8),
2021                 .array_type     = NO_ARRAY,
2022                 .tlv_type       = 0x01,
2023                 .offset         = offsetof(struct wlfw_request_mem_ind_msg_v01,
2024                                            mem_seg_len),
2025         },
2026         {
2027                 .data_type      = QMI_STRUCT,
2028                 .elem_len       = QMI_WLFW_MAX_NUM_MEM_SEG_V01,
2029                 .elem_size      = sizeof(struct wlfw_mem_seg_s_v01),
2030                 .array_type       = VAR_LEN_ARRAY,
2031                 .tlv_type       = 0x01,
2032                 .offset         = offsetof(struct wlfw_request_mem_ind_msg_v01,
2033                                            mem_seg),
2034                 .ei_array      = wlfw_mem_seg_s_v01_ei,
2035         },
2036         {}
2037 };
2038
2039 struct qmi_elem_info wlfw_respond_mem_req_msg_v01_ei[] = {
2040         {
2041                 .data_type      = QMI_DATA_LEN,
2042                 .elem_len       = 1,
2043                 .elem_size      = sizeof(u8),
2044                 .array_type     = NO_ARRAY,
2045                 .tlv_type       = 0x01,
2046                 .offset         = offsetof(struct wlfw_respond_mem_req_msg_v01,
2047                                            mem_seg_len),
2048         },
2049         {
2050                 .data_type      = QMI_STRUCT,
2051                 .elem_len       = QMI_WLFW_MAX_NUM_MEM_SEG_V01,
2052                 .elem_size      = sizeof(struct wlfw_mem_seg_resp_s_v01),
2053                 .array_type       = VAR_LEN_ARRAY,
2054                 .tlv_type       = 0x01,
2055                 .offset         = offsetof(struct wlfw_respond_mem_req_msg_v01,
2056                                            mem_seg),
2057                 .ei_array      = wlfw_mem_seg_resp_s_v01_ei,
2058         },
2059         {}
2060 };
2061
2062 struct qmi_elem_info wlfw_respond_mem_resp_msg_v01_ei[] = {
2063         {
2064                 .data_type      = QMI_STRUCT,
2065                 .elem_len       = 1,
2066                 .elem_size      = sizeof(struct qmi_response_type_v01),
2067                 .array_type     = NO_ARRAY,
2068                 .tlv_type       = 0x02,
2069                 .offset         = offsetof(struct wlfw_respond_mem_resp_msg_v01,
2070                                            resp),
2071                 .ei_array      = qmi_response_type_v01_ei,
2072         },
2073         {}
2074 };
2075
2076 struct qmi_elem_info wlfw_mem_ready_ind_msg_v01_ei[] = {
2077         {}
2078 };
2079
2080 struct qmi_elem_info wlfw_fw_init_done_ind_msg_v01_ei[] = {
2081         {}
2082 };
2083
2084 struct qmi_elem_info wlfw_rejuvenate_ind_msg_v01_ei[] = {
2085         {
2086                 .data_type      = QMI_OPT_FLAG,
2087                 .elem_len       = 1,
2088                 .elem_size      = sizeof(u8),
2089                 .array_type     = NO_ARRAY,
2090                 .tlv_type       = 0x10,
2091                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2092                                            cause_for_rejuvenation_valid),
2093         },
2094         {
2095                 .data_type      = QMI_UNSIGNED_1_BYTE,
2096                 .elem_len       = 1,
2097                 .elem_size      = sizeof(u8),
2098                 .array_type     = NO_ARRAY,
2099                 .tlv_type       = 0x10,
2100                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2101                                            cause_for_rejuvenation),
2102         },
2103         {
2104                 .data_type      = QMI_OPT_FLAG,
2105                 .elem_len       = 1,
2106                 .elem_size      = sizeof(u8),
2107                 .array_type     = NO_ARRAY,
2108                 .tlv_type       = 0x11,
2109                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2110                                            requesting_sub_system_valid),
2111         },
2112         {
2113                 .data_type      = QMI_UNSIGNED_1_BYTE,
2114                 .elem_len       = 1,
2115                 .elem_size      = sizeof(u8),
2116                 .array_type     = NO_ARRAY,
2117                 .tlv_type       = 0x11,
2118                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2119                                            requesting_sub_system),
2120         },
2121         {
2122                 .data_type      = QMI_OPT_FLAG,
2123                 .elem_len       = 1,
2124                 .elem_size      = sizeof(u8),
2125                 .array_type     = NO_ARRAY,
2126                 .tlv_type       = 0x12,
2127                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2128                                            line_number_valid),
2129         },
2130         {
2131                 .data_type      = QMI_UNSIGNED_2_BYTE,
2132                 .elem_len       = 1,
2133                 .elem_size      = sizeof(u16),
2134                 .array_type     = NO_ARRAY,
2135                 .tlv_type       = 0x12,
2136                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2137                                            line_number),
2138         },
2139         {
2140                 .data_type      = QMI_OPT_FLAG,
2141                 .elem_len       = 1,
2142                 .elem_size      = sizeof(u8),
2143                 .array_type     = NO_ARRAY,
2144                 .tlv_type       = 0x13,
2145                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2146                                            function_name_valid),
2147         },
2148         {
2149                 .data_type      = QMI_STRING,
2150                 .elem_len       = QMI_WLFW_FUNCTION_NAME_LEN_V01 + 1,
2151                 .elem_size      = sizeof(char),
2152                 .array_type     = NO_ARRAY,
2153                 .tlv_type       = 0x13,
2154                 .offset         = offsetof(struct wlfw_rejuvenate_ind_msg_v01,
2155                                            function_name),
2156         },
2157         {}
2158 };
2159
2160 struct qmi_elem_info wlfw_rejuvenate_ack_req_msg_v01_ei[] = {
2161         {}
2162 };
2163
2164 struct qmi_elem_info wlfw_rejuvenate_ack_resp_msg_v01_ei[] = {
2165         {
2166                 .data_type      = QMI_STRUCT,
2167                 .elem_len       = 1,
2168                 .elem_size      = sizeof(struct qmi_response_type_v01),
2169                 .array_type     = NO_ARRAY,
2170                 .tlv_type       = 0x02,
2171                 .offset         = offsetof(struct wlfw_rejuvenate_ack_resp_msg_v01,
2172                                            resp),
2173                 .ei_array      = qmi_response_type_v01_ei,
2174         },
2175         {}
2176 };
2177
2178 struct qmi_elem_info wlfw_dynamic_feature_mask_req_msg_v01_ei[] = {
2179         {
2180                 .data_type      = QMI_OPT_FLAG,
2181                 .elem_len       = 1,
2182                 .elem_size      = sizeof(u8),
2183                 .array_type     = NO_ARRAY,
2184                 .tlv_type       = 0x10,
2185                 .offset         = offsetof(struct wlfw_dynamic_feature_mask_req_msg_v01,
2186                                            mask_valid),
2187         },
2188         {
2189                 .data_type      = QMI_UNSIGNED_8_BYTE,
2190                 .elem_len       = 1,
2191                 .elem_size      = sizeof(u64),
2192                 .array_type     = NO_ARRAY,
2193                 .tlv_type       = 0x10,
2194                 .offset         = offsetof(struct wlfw_dynamic_feature_mask_req_msg_v01,
2195                                            mask),
2196         },
2197         {}
2198 };
2199
2200 struct qmi_elem_info wlfw_dynamic_feature_mask_resp_msg_v01_ei[] = {
2201         {
2202                 .data_type      = QMI_STRUCT,
2203                 .elem_len       = 1,
2204                 .elem_size      = sizeof(struct qmi_response_type_v01),
2205                 .array_type     = NO_ARRAY,
2206                 .tlv_type       = 0x02,
2207                 .offset         = offsetof(struct wlfw_dynamic_feature_mask_resp_msg_v01,
2208                                            resp),
2209                 .ei_array      = qmi_response_type_v01_ei,
2210         },
2211         {
2212                 .data_type      = QMI_OPT_FLAG,
2213                 .elem_len       = 1,
2214                 .elem_size      = sizeof(u8),
2215                 .array_type     = NO_ARRAY,
2216                 .tlv_type       = 0x10,
2217                 .offset         = offsetof(struct wlfw_dynamic_feature_mask_resp_msg_v01,
2218                                            prev_mask_valid),
2219         },
2220         {
2221                 .data_type      = QMI_UNSIGNED_8_BYTE,
2222                 .elem_len       = 1,
2223                 .elem_size      = sizeof(u64),
2224                 .array_type     = NO_ARRAY,
2225                 .tlv_type       = 0x10,
2226                 .offset         = offsetof(struct wlfw_dynamic_feature_mask_resp_msg_v01,
2227                                            prev_mask),
2228         },
2229         {
2230                 .data_type      = QMI_OPT_FLAG,
2231                 .elem_len       = 1,
2232                 .elem_size      = sizeof(u8),
2233                 .array_type     = NO_ARRAY,
2234                 .tlv_type       = 0x11,
2235                 .offset         = offsetof(struct wlfw_dynamic_feature_mask_resp_msg_v01,
2236                                            curr_mask_valid),
2237         },
2238         {
2239                 .data_type      = QMI_UNSIGNED_8_BYTE,
2240                 .elem_len       = 1,
2241                 .elem_size      = sizeof(u64),
2242                 .array_type     = NO_ARRAY,
2243                 .tlv_type       = 0x11,
2244                 .offset         = offsetof(struct wlfw_dynamic_feature_mask_resp_msg_v01,
2245                                            curr_mask),
2246         },
2247         {}
2248 };
2249
2250 struct qmi_elem_info wlfw_m3_info_req_msg_v01_ei[] = {
2251         {
2252                 .data_type      = QMI_UNSIGNED_8_BYTE,
2253                 .elem_len       = 1,
2254                 .elem_size      = sizeof(u64),
2255                 .array_type     = NO_ARRAY,
2256                 .tlv_type       = 0x01,
2257                 .offset         = offsetof(struct wlfw_m3_info_req_msg_v01,
2258                                            addr),
2259         },
2260         {
2261                 .data_type      = QMI_UNSIGNED_4_BYTE,
2262                 .elem_len       = 1,
2263                 .elem_size      = sizeof(u32),
2264                 .array_type     = NO_ARRAY,
2265                 .tlv_type       = 0x02,
2266                 .offset         = offsetof(struct wlfw_m3_info_req_msg_v01,
2267                                            size),
2268         },
2269         {}
2270 };
2271
2272 struct qmi_elem_info wlfw_m3_info_resp_msg_v01_ei[] = {
2273         {
2274                 .data_type      = QMI_STRUCT,
2275                 .elem_len       = 1,
2276                 .elem_size      = sizeof(struct qmi_response_type_v01),
2277                 .array_type     = NO_ARRAY,
2278                 .tlv_type       = 0x02,
2279                 .offset         = offsetof(struct wlfw_m3_info_resp_msg_v01,
2280                                            resp),
2281                 .ei_array      = qmi_response_type_v01_ei,
2282         },
2283         {}
2284 };
2285
2286 struct qmi_elem_info wlfw_xo_cal_ind_msg_v01_ei[] = {
2287         {
2288                 .data_type      = QMI_UNSIGNED_1_BYTE,
2289                 .elem_len       = 1,
2290                 .elem_size      = sizeof(u8),
2291                 .array_type     = NO_ARRAY,
2292                 .tlv_type       = 0x01,
2293                 .offset         = offsetof(struct wlfw_xo_cal_ind_msg_v01,
2294                                            xo_cal_data),
2295         },
2296         {}
2297 };