xref: /OK3568_Linux_fs/kernel/drivers/net/wireless/quantenna/qtnfmac/commands.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun /* SPDX-License-Identifier: GPL-2.0+ */
2*4882a593Smuzhiyun /* Copyright (c) 2016 Quantenna Communications. All rights reserved. */
3*4882a593Smuzhiyun 
4*4882a593Smuzhiyun #ifndef QLINK_COMMANDS_H_
5*4882a593Smuzhiyun #define QLINK_COMMANDS_H_
6*4882a593Smuzhiyun 
7*4882a593Smuzhiyun #include <linux/nl80211.h>
8*4882a593Smuzhiyun 
9*4882a593Smuzhiyun #include "core.h"
10*4882a593Smuzhiyun #include "bus.h"
11*4882a593Smuzhiyun 
12*4882a593Smuzhiyun int qtnf_cmd_send_init_fw(struct qtnf_bus *bus);
13*4882a593Smuzhiyun void qtnf_cmd_send_deinit_fw(struct qtnf_bus *bus);
14*4882a593Smuzhiyun int qtnf_cmd_get_hw_info(struct qtnf_bus *bus);
15*4882a593Smuzhiyun int qtnf_cmd_get_mac_info(struct qtnf_wmac *mac);
16*4882a593Smuzhiyun int qtnf_cmd_send_add_intf(struct qtnf_vif *vif, enum nl80211_iftype iftype,
17*4882a593Smuzhiyun 			   int use4addr, u8 *mac_addr);
18*4882a593Smuzhiyun int qtnf_cmd_send_change_intf_type(struct qtnf_vif *vif,
19*4882a593Smuzhiyun 				   enum nl80211_iftype iftype,
20*4882a593Smuzhiyun 				   int use4addr,
21*4882a593Smuzhiyun 				   u8 *mac_addr);
22*4882a593Smuzhiyun int qtnf_cmd_send_del_intf(struct qtnf_vif *vif);
23*4882a593Smuzhiyun int qtnf_cmd_band_info_get(struct qtnf_wmac *mac,
24*4882a593Smuzhiyun 			   struct ieee80211_supported_band *band);
25*4882a593Smuzhiyun int qtnf_cmd_send_regulatory_config(struct qtnf_wmac *mac, const char *alpha2);
26*4882a593Smuzhiyun int qtnf_cmd_send_start_ap(struct qtnf_vif *vif,
27*4882a593Smuzhiyun 			   const struct cfg80211_ap_settings *s);
28*4882a593Smuzhiyun int qtnf_cmd_send_stop_ap(struct qtnf_vif *vif);
29*4882a593Smuzhiyun int qtnf_cmd_send_register_mgmt(struct qtnf_vif *vif, u16 frame_type, bool reg);
30*4882a593Smuzhiyun int qtnf_cmd_send_frame(struct qtnf_vif *vif, u32 cookie, u16 flags,
31*4882a593Smuzhiyun 			u16 freq, const u8 *buf, size_t len);
32*4882a593Smuzhiyun int qtnf_cmd_send_mgmt_set_appie(struct qtnf_vif *vif, u8 frame_type,
33*4882a593Smuzhiyun 				 const u8 *buf, size_t len);
34*4882a593Smuzhiyun int qtnf_cmd_get_sta_info(struct qtnf_vif *vif, const u8 *sta_mac,
35*4882a593Smuzhiyun 			  struct station_info *sinfo);
36*4882a593Smuzhiyun int qtnf_cmd_send_phy_params(struct qtnf_wmac *mac, u16 cmd_action,
37*4882a593Smuzhiyun 			     void *data_buf);
38*4882a593Smuzhiyun int qtnf_cmd_send_add_key(struct qtnf_vif *vif, u8 key_index, bool pairwise,
39*4882a593Smuzhiyun 			  const u8 *mac_addr, struct key_params *params);
40*4882a593Smuzhiyun int qtnf_cmd_send_del_key(struct qtnf_vif *vif, u8 key_index, bool pairwise,
41*4882a593Smuzhiyun 			  const u8 *mac_addr);
42*4882a593Smuzhiyun int qtnf_cmd_send_set_default_key(struct qtnf_vif *vif, u8 key_index,
43*4882a593Smuzhiyun 				  bool unicast, bool multicast);
44*4882a593Smuzhiyun int qtnf_cmd_send_set_default_mgmt_key(struct qtnf_vif *vif, u8 key_index);
45*4882a593Smuzhiyun int qtnf_cmd_send_add_sta(struct qtnf_vif *vif, const u8 *mac,
46*4882a593Smuzhiyun 			  struct station_parameters *params);
47*4882a593Smuzhiyun int qtnf_cmd_send_change_sta(struct qtnf_vif *vif, const u8 *mac,
48*4882a593Smuzhiyun 			     struct station_parameters *params);
49*4882a593Smuzhiyun int qtnf_cmd_send_del_sta(struct qtnf_vif *vif,
50*4882a593Smuzhiyun 			  struct station_del_parameters *params);
51*4882a593Smuzhiyun int qtnf_cmd_send_scan(struct qtnf_wmac *mac);
52*4882a593Smuzhiyun int qtnf_cmd_send_connect(struct qtnf_vif *vif,
53*4882a593Smuzhiyun 			  struct cfg80211_connect_params *sme);
54*4882a593Smuzhiyun int qtnf_cmd_send_external_auth(struct qtnf_vif *vif,
55*4882a593Smuzhiyun 				struct cfg80211_external_auth_params *auth);
56*4882a593Smuzhiyun int qtnf_cmd_send_disconnect(struct qtnf_vif *vif,
57*4882a593Smuzhiyun 			     u16 reason_code);
58*4882a593Smuzhiyun int qtnf_cmd_send_updown_intf(struct qtnf_vif *vif,
59*4882a593Smuzhiyun 			      bool up);
60*4882a593Smuzhiyun int qtnf_cmd_reg_notify(struct qtnf_wmac *mac, struct regulatory_request *req,
61*4882a593Smuzhiyun 			bool slave_radar, bool dfs_offload);
62*4882a593Smuzhiyun int qtnf_cmd_get_chan_stats(struct qtnf_wmac *mac, u32 chan_freq,
63*4882a593Smuzhiyun 			    struct survey_info *survey);
64*4882a593Smuzhiyun int qtnf_cmd_send_chan_switch(struct qtnf_vif *vif,
65*4882a593Smuzhiyun 			      struct cfg80211_csa_settings *params);
66*4882a593Smuzhiyun int qtnf_cmd_get_channel(struct qtnf_vif *vif, struct cfg80211_chan_def *chdef);
67*4882a593Smuzhiyun int qtnf_cmd_start_cac(const struct qtnf_vif *vif,
68*4882a593Smuzhiyun 		       const struct cfg80211_chan_def *chdef,
69*4882a593Smuzhiyun 		       u32 cac_time_ms);
70*4882a593Smuzhiyun int qtnf_cmd_set_mac_acl(const struct qtnf_vif *vif,
71*4882a593Smuzhiyun 			 const struct cfg80211_acl_data *params);
72*4882a593Smuzhiyun int qtnf_cmd_send_pm_set(const struct qtnf_vif *vif, u8 pm_mode, int timeout);
73*4882a593Smuzhiyun int qtnf_cmd_get_tx_power(const struct qtnf_vif *vif, int *dbm);
74*4882a593Smuzhiyun int qtnf_cmd_set_tx_power(const struct qtnf_vif *vif,
75*4882a593Smuzhiyun 			  enum nl80211_tx_power_setting type, int mbm);
76*4882a593Smuzhiyun int qtnf_cmd_send_wowlan_set(const struct qtnf_vif *vif,
77*4882a593Smuzhiyun 			     const struct cfg80211_wowlan *wowl);
78*4882a593Smuzhiyun int qtnf_cmd_netdev_changeupper(const struct qtnf_vif *vif, int br_domain);
79*4882a593Smuzhiyun int qtnf_cmd_send_update_owe(struct qtnf_vif *vif,
80*4882a593Smuzhiyun 			     struct cfg80211_update_owe_info *owe);
81*4882a593Smuzhiyun 
82*4882a593Smuzhiyun #endif /* QLINK_COMMANDS_H_ */
83