1ff233cb5SSergey Matyukevich /* SPDX-License-Identifier: GPL-2.0+ */ 2ff233cb5SSergey Matyukevich /* Copyright (c) 2016 Quantenna Communications. All rights reserved. */ 398f44cb0SIgor Mitsyanko 498f44cb0SIgor Mitsyanko #ifndef QLINK_COMMANDS_H_ 598f44cb0SIgor Mitsyanko #define QLINK_COMMANDS_H_ 698f44cb0SIgor Mitsyanko 798f44cb0SIgor Mitsyanko #include <linux/nl80211.h> 898f44cb0SIgor Mitsyanko 998f44cb0SIgor Mitsyanko #include "core.h" 1098f44cb0SIgor Mitsyanko #include "bus.h" 1198f44cb0SIgor Mitsyanko 1298f44cb0SIgor Mitsyanko int qtnf_cmd_send_init_fw(struct qtnf_bus *bus); 1398f44cb0SIgor Mitsyanko void qtnf_cmd_send_deinit_fw(struct qtnf_bus *bus); 1498f44cb0SIgor Mitsyanko int qtnf_cmd_get_hw_info(struct qtnf_bus *bus); 1598f44cb0SIgor Mitsyanko int qtnf_cmd_get_mac_info(struct qtnf_wmac *mac); 1698f44cb0SIgor Mitsyanko int qtnf_cmd_send_add_intf(struct qtnf_vif *vif, enum nl80211_iftype iftype, 17de624a35SSergey Matyukevich int use4addr, u8 *mac_addr); 1898f44cb0SIgor Mitsyanko int qtnf_cmd_send_change_intf_type(struct qtnf_vif *vif, 19de624a35SSergey Matyukevich enum nl80211_iftype iftype, 20de624a35SSergey Matyukevich int use4addr, 21de624a35SSergey Matyukevich u8 *mac_addr); 2298f44cb0SIgor Mitsyanko int qtnf_cmd_send_del_intf(struct qtnf_vif *vif); 23e294cbfdSIgor Mitsyanko int qtnf_cmd_band_info_get(struct qtnf_wmac *mac, 2498f44cb0SIgor Mitsyanko struct ieee80211_supported_band *band); 2598f44cb0SIgor Mitsyanko int qtnf_cmd_send_regulatory_config(struct qtnf_wmac *mac, const char *alpha2); 2617011da0SIgor Mitsyanko int qtnf_cmd_send_start_ap(struct qtnf_vif *vif, 279b692df1SIgor Mitsyanko const struct cfg80211_ap_settings *s); 2898f44cb0SIgor Mitsyanko int qtnf_cmd_send_stop_ap(struct qtnf_vif *vif); 2998f44cb0SIgor Mitsyanko int qtnf_cmd_send_register_mgmt(struct qtnf_vif *vif, u16 frame_type, bool reg); 30bc70732fSIgor Mitsyanko int qtnf_cmd_send_frame(struct qtnf_vif *vif, u32 cookie, u16 flags, 3198f44cb0SIgor Mitsyanko u16 freq, const u8 *buf, size_t len); 3298f44cb0SIgor Mitsyanko int qtnf_cmd_send_mgmt_set_appie(struct qtnf_vif *vif, u8 frame_type, 3398f44cb0SIgor Mitsyanko const u8 *buf, size_t len); 3498f44cb0SIgor Mitsyanko int qtnf_cmd_get_sta_info(struct qtnf_vif *vif, const u8 *sta_mac, 3598f44cb0SIgor Mitsyanko struct station_info *sinfo); 3698f44cb0SIgor Mitsyanko int qtnf_cmd_send_phy_params(struct qtnf_wmac *mac, u16 cmd_action, 3798f44cb0SIgor Mitsyanko void *data_buf); 3898f44cb0SIgor Mitsyanko int qtnf_cmd_send_add_key(struct qtnf_vif *vif, u8 key_index, bool pairwise, 3998f44cb0SIgor Mitsyanko const u8 *mac_addr, struct key_params *params); 4098f44cb0SIgor Mitsyanko int qtnf_cmd_send_del_key(struct qtnf_vif *vif, u8 key_index, bool pairwise, 4198f44cb0SIgor Mitsyanko const u8 *mac_addr); 4298f44cb0SIgor Mitsyanko int qtnf_cmd_send_set_default_key(struct qtnf_vif *vif, u8 key_index, 4398f44cb0SIgor Mitsyanko bool unicast, bool multicast); 4498f44cb0SIgor Mitsyanko int qtnf_cmd_send_set_default_mgmt_key(struct qtnf_vif *vif, u8 key_index); 4598f44cb0SIgor Mitsyanko int qtnf_cmd_send_add_sta(struct qtnf_vif *vif, const u8 *mac, 4698f44cb0SIgor Mitsyanko struct station_parameters *params); 4798f44cb0SIgor Mitsyanko int qtnf_cmd_send_change_sta(struct qtnf_vif *vif, const u8 *mac, 4898f44cb0SIgor Mitsyanko struct station_parameters *params); 4998f44cb0SIgor Mitsyanko int qtnf_cmd_send_del_sta(struct qtnf_vif *vif, 5098f44cb0SIgor Mitsyanko struct station_del_parameters *params); 5198f44cb0SIgor Mitsyanko int qtnf_cmd_send_scan(struct qtnf_wmac *mac); 5298f44cb0SIgor Mitsyanko int qtnf_cmd_send_connect(struct qtnf_vif *vif, 5398f44cb0SIgor Mitsyanko struct cfg80211_connect_params *sme); 5447b08e75SSergey Matyukevich int qtnf_cmd_send_external_auth(struct qtnf_vif *vif, 5547b08e75SSergey Matyukevich struct cfg80211_external_auth_params *auth); 5698f44cb0SIgor Mitsyanko int qtnf_cmd_send_disconnect(struct qtnf_vif *vif, 5798f44cb0SIgor Mitsyanko u16 reason_code); 5898f44cb0SIgor Mitsyanko int qtnf_cmd_send_updown_intf(struct qtnf_vif *vif, 5998f44cb0SIgor Mitsyanko bool up); 60888f1564SIgor Mitsyanko int qtnf_cmd_reg_notify(struct qtnf_wmac *mac, struct regulatory_request *req, 61155b424cSSergey Matyukevich bool slave_radar, bool dfs_offload); 62601ce21fSIgor Mitsyanko int qtnf_cmd_get_chan_stats(struct qtnf_wmac *mac, u32 chan_freq, 63601ce21fSIgor Mitsyanko struct survey_info *survey); 648c015b90SIgor Mitsyanko int qtnf_cmd_send_chan_switch(struct qtnf_vif *vif, 6597883695SSergey Matyukevich struct cfg80211_csa_settings *params); 669e5478b6SIgor Mitsyanko int qtnf_cmd_get_channel(struct qtnf_vif *vif, struct cfg80211_chan_def *chdef); 67b05ee456SIgor Mitsyanko int qtnf_cmd_start_cac(const struct qtnf_vif *vif, 68b05ee456SIgor Mitsyanko const struct cfg80211_chan_def *chdef, 69b05ee456SIgor Mitsyanko u32 cac_time_ms); 70f1398fd2SVasily Ulyanov int qtnf_cmd_set_mac_acl(const struct qtnf_vif *vif, 71f1398fd2SVasily Ulyanov const struct cfg80211_acl_data *params); 724775ad06SSergei Maksimenko int qtnf_cmd_send_pm_set(const struct qtnf_vif *vif, u8 pm_mode, int timeout); 730756e913SMikhail Karpenko int qtnf_cmd_get_tx_power(const struct qtnf_vif *vif, int *dbm); 740756e913SMikhail Karpenko int qtnf_cmd_set_tx_power(const struct qtnf_vif *vif, 750756e913SMikhail Karpenko enum nl80211_tx_power_setting type, int mbm); 7628b91884SSergey Matyukevich int qtnf_cmd_send_wowlan_set(const struct qtnf_vif *vif, 7728b91884SSergey Matyukevich const struct cfg80211_wowlan *wowl); 78decfc5c7SIgor Mitsyanko int qtnf_cmd_netdev_changeupper(const struct qtnf_vif *vif, int br_domain); 79*44d09764SSergey Matyukevich int qtnf_cmd_send_update_owe(struct qtnf_vif *vif, 80*44d09764SSergey Matyukevich struct cfg80211_update_owe_info *owe); 8198f44cb0SIgor Mitsyanko 8298f44cb0SIgor Mitsyanko #endif /* QLINK_COMMANDS_H_ */ 83