Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-only */
0002 /*
0003  * Implementation of mac80211 API.
0004  *
0005  * Copyright (c) 2017-2020, Silicon Laboratories, Inc.
0006  * Copyright (c) 2010, ST-Ericsson
0007  */
0008 #ifndef WFX_STA_H
0009 #define WFX_STA_H
0010 
0011 #include <net/mac80211.h>
0012 
0013 struct wfx_dev;
0014 struct wfx_vif;
0015 
0016 struct wfx_sta_priv {
0017     int link_id;
0018     int vif_id;
0019 };
0020 
0021 /* mac80211 interface */
0022 int wfx_start(struct ieee80211_hw *hw);
0023 void wfx_stop(struct ieee80211_hw *hw);
0024 int wfx_config(struct ieee80211_hw *hw, u32 changed);
0025 int wfx_set_rts_threshold(struct ieee80211_hw *hw, u32 value);
0026 void wfx_set_default_unicast_key(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int idx);
0027 void wfx_configure_filter(struct ieee80211_hw *hw, unsigned int changed_flags,
0028               unsigned int *total_flags, u64 unused);
0029 
0030 int wfx_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
0031 void wfx_remove_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
0032 int wfx_start_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0033          struct ieee80211_bss_conf *link_conf);
0034 void wfx_stop_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0035          struct ieee80211_bss_conf *link_conf);
0036 int wfx_join_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
0037 void wfx_leave_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
0038 int wfx_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0039         unsigned int link_id, u16 queue,
0040         const struct ieee80211_tx_queue_params *params);
0041 void wfx_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0042               struct ieee80211_bss_conf *info, u64 changed);
0043 int wfx_sta_add(struct ieee80211_hw *hw, struct ieee80211_vif *vif, struct ieee80211_sta *sta);
0044 int wfx_sta_remove(struct ieee80211_hw *hw, struct ieee80211_vif *vif, struct ieee80211_sta *sta);
0045 void wfx_sta_notify(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0046             enum sta_notify_cmd cmd, struct ieee80211_sta *sta);
0047 int wfx_set_tim(struct ieee80211_hw *hw, struct ieee80211_sta *sta, bool set);
0048 int wfx_ampdu_action(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0049              struct ieee80211_ampdu_params *params);
0050 int wfx_add_chanctx(struct ieee80211_hw *hw, struct ieee80211_chanctx_conf *conf);
0051 void wfx_remove_chanctx(struct ieee80211_hw *hw, struct ieee80211_chanctx_conf *conf);
0052 void wfx_change_chanctx(struct ieee80211_hw *hw, struct ieee80211_chanctx_conf *conf, u32 changed);
0053 int wfx_assign_vif_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0054                struct ieee80211_bss_conf *link_conf,
0055                struct ieee80211_chanctx_conf *conf);
0056 void wfx_unassign_vif_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
0057                   struct ieee80211_bss_conf *link_conf,
0058                   struct ieee80211_chanctx_conf *conf);
0059 
0060 /* Hardware API Callbacks */
0061 void wfx_cooling_timeout_work(struct work_struct *work);
0062 void wfx_suspend_hot_dev(struct wfx_dev *wdev, enum sta_notify_cmd cmd);
0063 void wfx_suspend_resume_mc(struct wfx_vif *wvif, enum sta_notify_cmd cmd);
0064 void wfx_event_report_rssi(struct wfx_vif *wvif, u8 raw_rcpi_rssi);
0065 int wfx_update_pm(struct wfx_vif *wvif);
0066 
0067 /* Other Helpers */
0068 void wfx_reset(struct wfx_vif *wvif);
0069 u32 wfx_rate_mask_to_hw(struct wfx_dev *wdev, u32 rates);
0070 
0071 #endif