Commit 1c780482 authored by Jérôme Pouiller's avatar Jérôme Pouiller Committed by Greg Kroah-Hartman

staging: wfx: prefix functions from hif_*.h with wfx_

All the functions related to a driver should use the same prefix.
Signed-off-by: default avatarJérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20220113085524.1110708-15-Jerome.Pouiller@silabs.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent eec453df
......@@ -173,7 +173,7 @@ static int wfx_tx_policy_upload(struct wfx_vif *wvif)
policies[i].uploaded = true;
memcpy(tmp_rates, policies[i].rates, sizeof(tmp_rates));
spin_unlock_bh(&wvif->tx_policy_cache.lock);
hif_set_tx_rate_retry_policy(wvif, i, tmp_rates);
wfx_hif_set_tx_rate_retry_policy(wvif, i, tmp_rates);
} else {
spin_unlock_bh(&wvif->tx_policy_cache.lock);
}
......
......@@ -66,7 +66,7 @@ static int wfx_counters_show(struct seq_file *seq, void *v)
struct hif_mib_extended_count_table counters[3];
for (i = 0; i < ARRAY_SIZE(counters); i++) {
ret = hif_get_counters_table(wdev, i, counters + i);
ret = wfx_hif_get_counters_table(wdev, i, counters + i);
if (ret < 0)
return ret;
if (ret > 0)
......
......@@ -16,8 +16,8 @@
#include "data_rx.h"
#include "hif_api_cmd.h"
static int hif_generic_confirm(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_generic_confirm(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
{
/* All confirm messages start with status */
int status = le32_to_cpup((__le32 *)buf);
......@@ -50,8 +50,8 @@ static int hif_generic_confirm(struct wfx_dev *wdev,
return status;
}
static int hif_tx_confirm(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_tx_confirm(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
{
const struct hif_cnf_tx *body = buf;
......@@ -59,8 +59,8 @@ static int hif_tx_confirm(struct wfx_dev *wdev,
return 0;
}
static int hif_multi_tx_confirm(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_multi_tx_confirm(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
{
const struct hif_cnf_multi_transmit *body = buf;
int i;
......@@ -71,8 +71,9 @@ static int hif_multi_tx_confirm(struct wfx_dev *wdev,
return 0;
}
static int hif_startup_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_startup_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
{
const struct hif_ind_startup *body = buf;
......@@ -85,8 +86,8 @@ static int hif_startup_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_wakeup_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_wakeup_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
{
if (!wdev->pdata.gpio_wakeup ||
gpiod_get_value(wdev->pdata.gpio_wakeup) == 0) {
......@@ -96,9 +97,9 @@ static int hif_wakeup_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_receive_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf, struct sk_buff *skb)
static int wfx_hif_receive_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf, struct sk_buff *skb)
{
struct wfx_vif *wvif = wdev_to_wvif(wdev, hif->interface);
const struct hif_ind_rx *body = buf;
......@@ -114,8 +115,8 @@ static int hif_receive_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_event_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_event_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
{
struct wfx_vif *wvif = wdev_to_wvif(wdev, hif->interface);
const struct hif_ind_event *body = buf;
......@@ -149,9 +150,9 @@ static int hif_event_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_pm_mode_complete_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
static int wfx_hif_pm_mode_complete_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
{
struct wfx_vif *wvif = wdev_to_wvif(wdev, hif->interface);
......@@ -164,9 +165,9 @@ static int hif_pm_mode_complete_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_scan_complete_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
static int wfx_hif_scan_complete_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
{
struct wfx_vif *wvif = wdev_to_wvif(wdev, hif->interface);
const struct hif_ind_scan_cmpl *body = buf;
......@@ -181,9 +182,9 @@ static int hif_scan_complete_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_join_complete_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
static int wfx_hif_join_complete_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
{
struct wfx_vif *wvif = wdev_to_wvif(wdev, hif->interface);
......@@ -196,9 +197,9 @@ static int hif_join_complete_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_suspend_resume_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
static int wfx_hif_suspend_resume_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
{
const struct hif_ind_suspend_resume_tx *body = buf;
struct wfx_vif *wvif;
......@@ -225,8 +226,9 @@ static int hif_suspend_resume_indication(struct wfx_dev *wdev,
return 0;
}
static int hif_generic_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_generic_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
{
const struct hif_ind_generic *body = buf;
int type = le32_to_cpu(body->type);
......@@ -305,8 +307,8 @@ static const struct {
"secure link params (nonce or tag) mismatch" },
};
static int hif_error_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_error_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
{
const struct hif_ind_error *body = buf;
int type = le32_to_cpu(body->type);
......@@ -332,8 +334,9 @@ static int hif_error_indication(struct wfx_dev *wdev,
return 0;
};
static int hif_exception_indication(struct wfx_dev *wdev,
const struct hif_msg *hif, const void *buf)
static int wfx_hif_exception_indication(struct wfx_dev *wdev,
const struct hif_msg *hif,
const void *buf)
{
const struct hif_ind_exception *body = buf;
int type = le32_to_cpu(body->type);
......@@ -356,21 +359,21 @@ static const struct {
const struct hif_msg *hif, const void *buf);
} hif_handlers[] = {
/* Confirmations */
{ HIF_CNF_ID_TX, hif_tx_confirm },
{ HIF_CNF_ID_MULTI_TRANSMIT, hif_multi_tx_confirm },
{ HIF_CNF_ID_TX, wfx_hif_tx_confirm },
{ HIF_CNF_ID_MULTI_TRANSMIT, wfx_hif_multi_tx_confirm },
/* Indications */
{ HIF_IND_ID_STARTUP, hif_startup_indication },
{ HIF_IND_ID_WAKEUP, hif_wakeup_indication },
{ HIF_IND_ID_JOIN_COMPLETE, hif_join_complete_indication },
{ HIF_IND_ID_SET_PM_MODE_CMPL, hif_pm_mode_complete_indication },
{ HIF_IND_ID_SCAN_CMPL, hif_scan_complete_indication },
{ HIF_IND_ID_SUSPEND_RESUME_TX, hif_suspend_resume_indication },
{ HIF_IND_ID_EVENT, hif_event_indication },
{ HIF_IND_ID_GENERIC, hif_generic_indication },
{ HIF_IND_ID_ERROR, hif_error_indication },
{ HIF_IND_ID_EXCEPTION, hif_exception_indication },
/* FIXME: allocate skb_p from hif_receive_indication and make it generic */
//{ HIF_IND_ID_RX, hif_receive_indication },
{ HIF_IND_ID_STARTUP, wfx_hif_startup_indication },
{ HIF_IND_ID_WAKEUP, wfx_hif_wakeup_indication },
{ HIF_IND_ID_JOIN_COMPLETE, wfx_hif_join_complete_indication },
{ HIF_IND_ID_SET_PM_MODE_CMPL, wfx_hif_pm_mode_complete_indication },
{ HIF_IND_ID_SCAN_CMPL, wfx_hif_scan_complete_indication },
{ HIF_IND_ID_SUSPEND_RESUME_TX, wfx_hif_suspend_resume_indication },
{ HIF_IND_ID_EVENT, wfx_hif_event_indication },
{ HIF_IND_ID_GENERIC, wfx_hif_generic_indication },
{ HIF_IND_ID_ERROR, wfx_hif_error_indication },
{ HIF_IND_ID_EXCEPTION, wfx_hif_exception_indication },
/* FIXME: allocate skb_p from wfx_hif_receive_indication and make it generic */
//{ HIF_IND_ID_RX, wfx_hif_receive_indication },
};
void wfx_handle_rx(struct wfx_dev *wdev, struct sk_buff *skb)
......@@ -380,8 +383,8 @@ void wfx_handle_rx(struct wfx_dev *wdev, struct sk_buff *skb)
int hif_id = hif->id;
if (hif_id == HIF_IND_ID_RX) {
/* hif_receive_indication take care of skb lifetime */
hif_receive_indication(wdev, hif, hif->body, skb);
/* wfx_hif_receive_indication take care of skb lifetime */
wfx_hif_receive_indication(wdev, hif, hif->body, skb);
return;
}
/* Note: mutex_is_lock cause an implicit memory barrier that protect
......@@ -390,7 +393,7 @@ void wfx_handle_rx(struct wfx_dev *wdev, struct sk_buff *skb)
if (mutex_is_locked(&wdev->hif_cmd.lock) &&
wdev->hif_cmd.buf_send &&
wdev->hif_cmd.buf_send->id == hif_id) {
hif_generic_confirm(wdev, hif, hif->body);
wfx_hif_generic_confirm(wdev, hif, hif->body);
goto free;
}
for (i = 0; i < ARRAY_SIZE(hif_handlers); i++) {
......
......@@ -122,7 +122,7 @@ int wfx_cmd_send(struct wfx_dev *wdev, struct hif_msg *request,
/* This function is special. After HIF_REQ_ID_SHUT_DOWN, chip won't reply to any
* request anymore. Obviously, only call this function during device unregister.
*/
int hif_shutdown(struct wfx_dev *wdev)
int wfx_hif_shutdown(struct wfx_dev *wdev)
{
int ret;
struct hif_msg *hif;
......@@ -140,7 +140,7 @@ int hif_shutdown(struct wfx_dev *wdev)
return ret;
}
int hif_configuration(struct wfx_dev *wdev, const u8 *conf, size_t len)
int wfx_hif_configuration(struct wfx_dev *wdev, const u8 *conf, size_t len)
{
int ret;
size_t buf_len = sizeof(struct hif_req_configuration) + len;
......@@ -157,7 +157,7 @@ int hif_configuration(struct wfx_dev *wdev, const u8 *conf, size_t len)
return ret;
}
int hif_reset(struct wfx_vif *wvif, bool reset_stat)
int wfx_hif_reset(struct wfx_vif *wvif, bool reset_stat)
{
int ret;
struct hif_msg *hif;
......@@ -172,8 +172,8 @@ int hif_reset(struct wfx_vif *wvif, bool reset_stat)
return ret;
}
int hif_read_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *val, size_t val_len)
int wfx_hif_read_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *val, size_t val_len)
{
int ret;
struct hif_msg *hif;
......@@ -208,8 +208,8 @@ int hif_read_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
return ret;
}
int hif_write_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *val, size_t val_len)
int wfx_hif_write_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *val, size_t val_len)
{
int ret;
struct hif_msg *hif;
......@@ -227,8 +227,8 @@ int hif_write_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
return ret;
}
int hif_scan(struct wfx_vif *wvif, struct cfg80211_scan_request *req,
int chan_start_idx, int chan_num)
int wfx_hif_scan(struct wfx_vif *wvif, struct cfg80211_scan_request *req,
int chan_start_idx, int chan_num)
{
int ret, i;
struct hif_msg *hif;
......@@ -276,7 +276,7 @@ int hif_scan(struct wfx_vif *wvif, struct cfg80211_scan_request *req,
return ret;
}
int hif_stop_scan(struct wfx_vif *wvif)
int wfx_hif_stop_scan(struct wfx_vif *wvif)
{
int ret;
struct hif_msg *hif;
......@@ -291,8 +291,8 @@ int hif_stop_scan(struct wfx_vif *wvif)
return ret;
}
int hif_join(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
struct ieee80211_channel *channel, const u8 *ssid, int ssidlen)
int wfx_hif_join(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
struct ieee80211_channel *channel, const u8 *ssid, int ssidlen)
{
int ret;
struct hif_msg *hif;
......@@ -322,7 +322,7 @@ int hif_join(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
return ret;
}
int hif_set_bss_params(struct wfx_vif *wvif, int aid, int beacon_lost_count)
int wfx_hif_set_bss_params(struct wfx_vif *wvif, int aid, int beacon_lost_count)
{
int ret;
struct hif_msg *hif;
......@@ -340,7 +340,7 @@ int hif_set_bss_params(struct wfx_vif *wvif, int aid, int beacon_lost_count)
return ret;
}
int hif_add_key(struct wfx_dev *wdev, const struct hif_req_add_key *arg)
int wfx_hif_add_key(struct wfx_dev *wdev, const struct hif_req_add_key *arg)
{
int ret;
struct hif_msg *hif;
......@@ -364,7 +364,7 @@ int hif_add_key(struct wfx_dev *wdev, const struct hif_req_add_key *arg)
return ret;
}
int hif_remove_key(struct wfx_dev *wdev, int idx)
int wfx_hif_remove_key(struct wfx_dev *wdev, int idx)
{
int ret;
struct hif_msg *hif;
......@@ -379,8 +379,8 @@ int hif_remove_key(struct wfx_dev *wdev, int idx)
return ret;
}
int hif_set_edca_queue_params(struct wfx_vif *wvif, u16 queue,
const struct ieee80211_tx_queue_params *arg)
int wfx_hif_set_edca_queue_params(struct wfx_vif *wvif, u16 queue,
const struct ieee80211_tx_queue_params *arg)
{
int ret;
struct hif_msg *hif;
......@@ -410,7 +410,7 @@ int hif_set_edca_queue_params(struct wfx_vif *wvif, u16 queue,
return ret;
}
int hif_set_pm(struct wfx_vif *wvif, bool ps, int dynamic_ps_timeout)
int wfx_hif_set_pm(struct wfx_vif *wvif, bool ps, int dynamic_ps_timeout)
{
int ret;
struct hif_msg *hif;
......@@ -434,8 +434,8 @@ int hif_set_pm(struct wfx_vif *wvif, bool ps, int dynamic_ps_timeout)
return ret;
}
int hif_start(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
const struct ieee80211_channel *channel)
int wfx_hif_start(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
const struct ieee80211_channel *channel)
{
int ret;
struct hif_msg *hif;
......@@ -458,7 +458,7 @@ int hif_start(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
return ret;
}
int hif_beacon_transmit(struct wfx_vif *wvif, bool enable)
int wfx_hif_beacon_transmit(struct wfx_vif *wvif, bool enable)
{
int ret;
struct hif_msg *hif;
......@@ -475,7 +475,8 @@ int hif_beacon_transmit(struct wfx_vif *wvif, bool enable)
return ret;
}
int hif_map_link(struct wfx_vif *wvif, bool unmap, u8 *mac_addr, int sta_id, bool mfp)
int wfx_hif_map_link(struct wfx_vif *wvif, bool unmap, u8 *mac_addr, int sta_id,
bool mfp)
{
int ret;
struct hif_msg *hif;
......@@ -494,7 +495,8 @@ int hif_map_link(struct wfx_vif *wvif, bool unmap, u8 *mac_addr, int sta_id, boo
return ret;
}
int hif_update_ie_beacon(struct wfx_vif *wvif, const u8 *ies, size_t ies_len)
int wfx_hif_update_ie_beacon(struct wfx_vif *wvif,
const u8 *ies, size_t ies_len)
{
int ret;
struct hif_msg *hif;
......
......@@ -36,29 +36,29 @@ void wfx_init_hif_cmd(struct wfx_hif_cmd *wfx_hif_cmd);
int wfx_cmd_send(struct wfx_dev *wdev, struct hif_msg *request,
void *reply, size_t reply_len, bool async);
int hif_shutdown(struct wfx_dev *wdev);
int hif_configuration(struct wfx_dev *wdev, const u8 *conf, size_t len);
int hif_reset(struct wfx_vif *wvif, bool reset_stat);
int hif_read_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *buf, size_t buf_size);
int hif_write_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *buf, size_t buf_size);
int hif_scan(struct wfx_vif *wvif, struct cfg80211_scan_request *req80211,
int chan_start, int chan_num);
int hif_stop_scan(struct wfx_vif *wvif);
int hif_join(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
struct ieee80211_channel *channel, const u8 *ssid, int ssidlen);
int hif_set_pm(struct wfx_vif *wvif, bool ps, int dynamic_ps_timeout);
int hif_set_bss_params(struct wfx_vif *wvif, int aid, int beacon_lost_count);
int hif_add_key(struct wfx_dev *wdev, const struct hif_req_add_key *arg);
int hif_remove_key(struct wfx_dev *wdev, int idx);
int hif_set_edca_queue_params(struct wfx_vif *wvif, u16 queue,
const struct ieee80211_tx_queue_params *arg);
int hif_start(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
const struct ieee80211_channel *channel);
int hif_beacon_transmit(struct wfx_vif *wvif, bool enable);
int hif_map_link(struct wfx_vif *wvif,
bool unmap, u8 *mac_addr, int sta_id, bool mfp);
int hif_update_ie_beacon(struct wfx_vif *wvif, const u8 *ies, size_t ies_len);
int wfx_hif_read_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *buf, size_t buf_size);
int wfx_hif_write_mib(struct wfx_dev *wdev, int vif_id, u16 mib_id,
void *buf, size_t buf_size);
int wfx_hif_start(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
const struct ieee80211_channel *channel);
int wfx_hif_reset(struct wfx_vif *wvif, bool reset_stat);
int wfx_hif_join(struct wfx_vif *wvif, const struct ieee80211_bss_conf *conf,
struct ieee80211_channel *channel, const u8 *ssid, int ssidlen);
int wfx_hif_map_link(struct wfx_vif *wvif,
bool unmap, u8 *mac_addr, int sta_id, bool mfp);
int wfx_hif_add_key(struct wfx_dev *wdev, const struct hif_req_add_key *arg);
int wfx_hif_remove_key(struct wfx_dev *wdev, int idx);
int wfx_hif_set_pm(struct wfx_vif *wvif, bool ps, int dynamic_ps_timeout);
int wfx_hif_set_bss_params(struct wfx_vif *wvif, int aid, int beacon_lost_count);
int wfx_hif_set_edca_queue_params(struct wfx_vif *wvif, u16 queue,
const struct ieee80211_tx_queue_params *arg);
int wfx_hif_beacon_transmit(struct wfx_vif *wvif, bool enable);
int wfx_hif_update_ie_beacon(struct wfx_vif *wvif, const u8 *ies, size_t ies_len);
int wfx_hif_scan(struct wfx_vif *wvif, struct cfg80211_scan_request *req80211,
int chan_start, int chan_num);
int wfx_hif_stop_scan(struct wfx_vif *wvif);
int wfx_hif_configuration(struct wfx_dev *wdev, const u8 *conf, size_t len);
int wfx_hif_shutdown(struct wfx_dev *wdev);
#endif
This diff is collapsed.
......@@ -17,38 +17,39 @@ struct wfx_dev;
struct hif_ie_table_entry;
struct hif_mib_extended_count_table;
int hif_set_output_power(struct wfx_vif *wvif, int val);
int hif_set_beacon_wakeup_period(struct wfx_vif *wvif,
unsigned int dtim_interval,
unsigned int listen_interval);
int hif_set_rcpi_rssi_threshold(struct wfx_vif *wvif,
int rssi_thold, int rssi_hyst);
int hif_get_counters_table(struct wfx_dev *wdev, int vif_id,
struct hif_mib_extended_count_table *arg);
int hif_set_macaddr(struct wfx_vif *wvif, u8 *mac);
int hif_set_rx_filter(struct wfx_vif *wvif,
bool filter_bssid, bool fwd_probe_req);
int hif_set_beacon_filter_table(struct wfx_vif *wvif, int tbl_len,
const struct hif_ie_table_entry *tbl);
int hif_beacon_filter_control(struct wfx_vif *wvif,
int enable, int beacon_count);
int hif_set_operational_mode(struct wfx_dev *wdev, enum hif_op_power_mode mode);
int hif_set_template_frame(struct wfx_vif *wvif, struct sk_buff *skb,
u8 frame_type, int init_rate);
int hif_set_mfp(struct wfx_vif *wvif, bool capable, bool required);
int hif_set_block_ack_policy(struct wfx_vif *wvif,
u8 tx_tid_policy, u8 rx_tid_policy);
int hif_set_association_mode(struct wfx_vif *wvif, int ampdu_density,
bool greenfield, bool short_preamble);
int hif_set_tx_rate_retry_policy(struct wfx_vif *wvif,
int policy_index, u8 *rates);
int hif_keep_alive_period(struct wfx_vif *wvif, int period);
int hif_set_arp_ipv4_filter(struct wfx_vif *wvif, int idx, __be32 *addr);
int hif_use_multi_tx_conf(struct wfx_dev *wdev, bool enable);
int hif_set_uapsd_info(struct wfx_vif *wvif, unsigned long val);
int hif_erp_use_protection(struct wfx_vif *wvif, bool enable);
int hif_slot_time(struct wfx_vif *wvif, int val);
int hif_wep_default_key_id(struct wfx_vif *wvif, int val);
int hif_rts_threshold(struct wfx_vif *wvif, int val);
int wfx_hif_set_output_power(struct wfx_vif *wvif, int val);
int wfx_hif_set_beacon_wakeup_period(struct wfx_vif *wvif,
unsigned int dtim_interval,
unsigned int listen_interval);
int wfx_hif_set_rcpi_rssi_threshold(struct wfx_vif *wvif,
int rssi_thold, int rssi_hyst);
int wfx_hif_get_counters_table(struct wfx_dev *wdev, int vif_id,
struct hif_mib_extended_count_table *arg);
int wfx_hif_set_macaddr(struct wfx_vif *wvif, u8 *mac);
int wfx_hif_set_rx_filter(struct wfx_vif *wvif,
bool filter_bssid, bool fwd_probe_req);
int wfx_hif_set_beacon_filter_table(struct wfx_vif *wvif, int tbl_len,
const struct hif_ie_table_entry *tbl);
int wfx_hif_beacon_filter_control(struct wfx_vif *wvif,
int enable, int beacon_count);
int wfx_hif_set_operational_mode(struct wfx_dev *wdev,
enum hif_op_power_mode mode);
int wfx_hif_set_template_frame(struct wfx_vif *wvif, struct sk_buff *skb,
u8 frame_type, int init_rate);
int wfx_hif_set_mfp(struct wfx_vif *wvif, bool capable, bool required);
int wfx_hif_set_block_ack_policy(struct wfx_vif *wvif,
u8 tx_tid_policy, u8 rx_tid_policy);
int wfx_hif_set_association_mode(struct wfx_vif *wvif, int ampdu_density,
bool greenfield, bool short_preamble);
int wfx_hif_set_tx_rate_retry_policy(struct wfx_vif *wvif,
int policy_index, u8 *rates);
int wfx_hif_keep_alive_period(struct wfx_vif *wvif, int period);
int wfx_hif_set_arp_ipv4_filter(struct wfx_vif *wvif, int idx, __be32 *addr);
int wfx_hif_use_multi_tx_conf(struct wfx_dev *wdev, bool enable);
int wfx_hif_set_uapsd_info(struct wfx_vif *wvif, unsigned long val);
int wfx_hif_erp_use_protection(struct wfx_vif *wvif, bool enable);
int wfx_hif_slot_time(struct wfx_vif *wvif, int val);
int wfx_hif_wep_default_key_id(struct wfx_vif *wvif, int val);
int wfx_hif_rts_threshold(struct wfx_vif *wvif, int val);
#endif
......@@ -205,7 +205,7 @@ static int wfx_add_key(struct wfx_vif *wvif, struct ieee80211_sta *sta,
wfx_free_key(wdev, idx);
return -EOPNOTSUPP;
}
ret = hif_add_key(wdev, &k);
ret = wfx_hif_add_key(wdev, &k);
if (ret) {
wfx_free_key(wdev, idx);
return -EOPNOTSUPP;
......@@ -220,7 +220,7 @@ static int wfx_remove_key(struct wfx_vif *wvif, struct ieee80211_key_conf *key)
{
WARN(key->hw_key_idx >= MAX_KEY_ENTRIES, "corrupted hw_key_idx");
wfx_free_key(wvif->wdev, key->hw_key_idx);
return hif_remove_key(wvif->wdev, key->hw_key_idx);
return wfx_hif_remove_key(wvif->wdev, key->hw_key_idx);
}
int wfx_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
......
......@@ -201,8 +201,8 @@ int wfx_send_pds(struct wfx_dev *wdev, u8 *buf, size_t len)
buf[i] = 0;
dev_dbg(wdev->dev, "send PDS '%s}'\n", buf + start);
buf[i] = '}';
ret = hif_configuration(wdev, buf + start,
i - start + 1);
ret = wfx_hif_configuration(wdev, buf + start,
i - start + 1);
if (ret > 0) {
dev_err(wdev->dev, "PDS bytes %d to %d: invalid data (unsupported options?)\n",
start, i);
......@@ -418,7 +418,7 @@ int wfx_probe(struct wfx_dev *wdev)
if (err)
goto err0;
err = hif_use_multi_tx_conf(wdev, true);
err = wfx_hif_use_multi_tx_conf(wdev, true);
if (err)
dev_err(wdev->dev, "misconfigured IRQ?\n");
......@@ -429,9 +429,9 @@ int wfx_probe(struct wfx_dev *wdev)
wdev->pdata.file_pds);
gpiod_set_value_cansleep(wdev->pdata.gpio_wakeup, 1);
control_reg_write(wdev, 0);
hif_set_operational_mode(wdev, HIF_OP_POWER_MODE_QUIESCENT);
wfx_hif_set_operational_mode(wdev, HIF_OP_POWER_MODE_QUIESCENT);
} else {
hif_set_operational_mode(wdev, HIF_OP_POWER_MODE_DOZE);
wfx_hif_set_operational_mode(wdev, HIF_OP_POWER_MODE_DOZE);
}
for (i = 0; i < ARRAY_SIZE(wdev->addresses); i++) {
......@@ -478,7 +478,7 @@ int wfx_probe(struct wfx_dev *wdev)
void wfx_release(struct wfx_dev *wdev)
{
ieee80211_unregister_hw(wdev->hw);
hif_shutdown(wdev);
wfx_hif_shutdown(wdev);
wdev->hwbus_ops->irq_unsubscribe(wdev->hwbus_priv);
wfx_bh_unregister(wdev);
}
......
......@@ -33,7 +33,7 @@ static int update_probe_tmpl(struct wfx_vif *wvif,
return -ENOMEM;
skb_put_data(skb, req->ie, req->ie_len);
hif_set_template_frame(wvif, skb, HIF_TMPLT_PRBREQ, 0);
wfx_hif_set_template_frame(wvif, skb, HIF_TMPLT_PRBREQ, 0);
dev_kfree_skb(skb);
return 0;
}
......@@ -56,14 +56,14 @@ static int send_scan_req(struct wfx_vif *wvif,
wfx_tx_lock_flush(wvif->wdev);
wvif->scan_abort = false;
reinit_completion(&wvif->scan_complete);
ret = hif_scan(wvif, req, start_idx, i - start_idx);
ret = wfx_hif_scan(wvif, req, start_idx, i - start_idx);
if (ret) {
wfx_tx_unlock(wvif->wdev);
return -EIO;
}
ret = wait_for_completion_timeout(&wvif->scan_complete, 1 * HZ);
if (!ret) {
hif_stop_scan(wvif);
wfx_hif_stop_scan(wvif);
ret = wait_for_completion_timeout(&wvif->scan_complete, 1 * HZ);
dev_dbg(wvif->wdev->dev, "scan timeout (%d channels done)\n",
wvif->scan_nb_chan_done);
......@@ -80,7 +80,7 @@ static int send_scan_req(struct wfx_vif *wvif,
ret = wvif->scan_nb_chan_done;
}
if (req->channels[start_idx]->max_power != wvif->vif->bss_conf.txpower)
hif_set_output_power(wvif, wvif->vif->bss_conf.txpower);
wfx_hif_set_output_power(wvif, wvif->vif->bss_conf.txpower);
wfx_tx_unlock(wvif->wdev);
return ret;
}
......@@ -139,7 +139,7 @@ void wfx_cancel_hw_scan(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
struct wfx_vif *wvif = (struct wfx_vif *)vif->drv_priv;
wvif->scan_abort = true;
hif_stop_scan(wvif);
wfx_hif_stop_scan(wvif);
}
void wfx_scan_complete(struct wfx_vif *wvif, int nb_chan_done)
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment