18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 28c2ecf20Sopenharmony_ci/* 38c2ecf20Sopenharmony_ci * Copyright (c) 2012 - 2018 Microchip Technology Inc., and its subsidiaries. 48c2ecf20Sopenharmony_ci * All rights reserved. 58c2ecf20Sopenharmony_ci */ 68c2ecf20Sopenharmony_ci 78c2ecf20Sopenharmony_ci#ifndef WILC_WLAN_CFG_H 88c2ecf20Sopenharmony_ci#define WILC_WLAN_CFG_H 98c2ecf20Sopenharmony_ci 108c2ecf20Sopenharmony_cistruct wilc_cfg_byte { 118c2ecf20Sopenharmony_ci u16 id; 128c2ecf20Sopenharmony_ci u8 val; 138c2ecf20Sopenharmony_ci}; 148c2ecf20Sopenharmony_ci 158c2ecf20Sopenharmony_cistruct wilc_cfg_hword { 168c2ecf20Sopenharmony_ci u16 id; 178c2ecf20Sopenharmony_ci u16 val; 188c2ecf20Sopenharmony_ci}; 198c2ecf20Sopenharmony_ci 208c2ecf20Sopenharmony_cistruct wilc_cfg_word { 218c2ecf20Sopenharmony_ci u16 id; 228c2ecf20Sopenharmony_ci u32 val; 238c2ecf20Sopenharmony_ci}; 248c2ecf20Sopenharmony_ci 258c2ecf20Sopenharmony_cistruct wilc_cfg_str { 268c2ecf20Sopenharmony_ci u16 id; 278c2ecf20Sopenharmony_ci u8 *str; 288c2ecf20Sopenharmony_ci}; 298c2ecf20Sopenharmony_ci 308c2ecf20Sopenharmony_cistruct wilc_cfg_str_vals { 318c2ecf20Sopenharmony_ci u8 mac_address[7]; 328c2ecf20Sopenharmony_ci u8 firmware_version[129]; 338c2ecf20Sopenharmony_ci u8 assoc_rsp[256]; 348c2ecf20Sopenharmony_ci}; 358c2ecf20Sopenharmony_ci 368c2ecf20Sopenharmony_cistruct wilc_cfg { 378c2ecf20Sopenharmony_ci struct wilc_cfg_byte *b; 388c2ecf20Sopenharmony_ci struct wilc_cfg_hword *hw; 398c2ecf20Sopenharmony_ci struct wilc_cfg_word *w; 408c2ecf20Sopenharmony_ci struct wilc_cfg_str *s; 418c2ecf20Sopenharmony_ci struct wilc_cfg_str_vals *str_vals; 428c2ecf20Sopenharmony_ci}; 438c2ecf20Sopenharmony_ci 448c2ecf20Sopenharmony_cistruct wilc; 458c2ecf20Sopenharmony_ciint wilc_wlan_cfg_set_wid(u8 *frame, u32 offset, u16 id, u8 *buf, int size); 468c2ecf20Sopenharmony_ciint wilc_wlan_cfg_get_wid(u8 *frame, u32 offset, u16 id); 478c2ecf20Sopenharmony_ciint wilc_wlan_cfg_get_val(struct wilc *wl, u16 wid, u8 *buffer, 488c2ecf20Sopenharmony_ci u32 buffer_size); 498c2ecf20Sopenharmony_civoid wilc_wlan_cfg_indicate_rx(struct wilc *wilc, u8 *frame, int size, 508c2ecf20Sopenharmony_ci struct wilc_cfg_rsp *rsp); 518c2ecf20Sopenharmony_ciint wilc_wlan_cfg_init(struct wilc *wl); 528c2ecf20Sopenharmony_civoid wilc_wlan_cfg_deinit(struct wilc *wl); 538c2ecf20Sopenharmony_ci 548c2ecf20Sopenharmony_ci#endif 55