Commit 2132c69c authored by Vasanthakumar Thiagarajan's avatar Vasanthakumar Thiagarajan Committed by Kalle Valo

ath6kl: Move aggregation information to vif structure

Signed-off-by: default avatarVasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: default avatarKalle Valo <kvalo@qca.qualcomm.com>
parent 6f2a73f9
......@@ -2064,8 +2064,8 @@ static int ath6kl_init_if_data(struct ath6kl_vif *vif)
{
struct ath6kl *ar = vif->ar;
ar->aggr_cntxt = aggr_init(vif->ndev);
if (!ar->aggr_cntxt) {
vif->aggr_cntxt = aggr_init(vif->ndev);
if (!vif->aggr_cntxt) {
ath6kl_err("failed to initialize aggr\n");
return -ENOMEM;
}
......@@ -2078,11 +2078,9 @@ static int ath6kl_init_if_data(struct ath6kl_vif *vif)
void ath6kl_deinit_if_data(struct ath6kl_vif *vif)
{
struct ath6kl *ar = vif->ar;
aggr_module_destroy(ar->aggr_cntxt);
aggr_module_destroy(vif->aggr_cntxt);
ar->aggr_cntxt = NULL;
vif->aggr_cntxt = NULL;
if (test_bit(NETDEV_REGISTERED, &vif->flags)) {
unregister_netdev(vif->ndev);
......
......@@ -415,6 +415,7 @@ struct ath6kl_vif {
u16 bss_ch;
struct ath6kl_wep_key wep_key_list[WMI_MAX_KEY_INDEX + 1];
struct ath6kl_key keys[WMI_MAX_KEY_INDEX + 1];
struct aggr_info *aggr_cntxt;
};
/* Flag info */
......@@ -473,7 +474,6 @@ struct ath6kl {
struct sk_buff_head mcastpsq;
spinlock_t mcastpsq_lock;
u8 intra_bss;
struct aggr_info *aggr_cntxt;
struct wmi_ap_mode_stat ap_stats;
u8 ap_country_code[3];
struct list_head amsdu_rx_buffer_queue;
......
......@@ -1073,7 +1073,7 @@ void ath6kl_connect_event(struct ath6kl *ar, u16 channel, u8 *bssid,
netif_carrier_on(ar->net_dev);
spin_unlock_bh(&ar->lock);
aggr_reset_state(ar->aggr_cntxt);
aggr_reset_state(vif->aggr_cntxt);
ar->reconnect_flag = 0;
if ((vif->nw_type == ADHOC_NETWORK) && ar->ibss_ps_enable) {
......@@ -1394,7 +1394,7 @@ void ath6kl_disconnect_event(struct ath6kl *ar, u8 reason, u8 *bssid,
assoc_resp_len, assoc_info,
prot_reason_status);
aggr_reset_state(ar->aggr_cntxt);
aggr_reset_state(vif->aggr_cntxt);
del_timer(&ar->disconnect_timer);
......
......@@ -1268,7 +1268,7 @@ void ath6kl_rx(struct htc_target *target, struct htc_packet *packet)
datap = (struct ethhdr *) skb->data;
if (is_unicast_ether_addr(datap->h_dest) &&
aggr_process_recv_frm(ar->aggr_cntxt, tid, seq_no,
aggr_process_recv_frm(vif->aggr_cntxt, tid, seq_no,
is_amsdu, skb))
/* aggregation code will handle the skb */
return;
......@@ -1353,7 +1353,9 @@ static void aggr_delete_tid_state(struct aggr_info *p_aggr, u8 tid)
void aggr_recv_addba_req_evt(struct ath6kl *ar, u8 tid, u16 seq_no, u8 win_sz)
{
struct aggr_info *p_aggr = ar->aggr_cntxt;
/* TODO: Findout vif */
struct ath6kl_vif *vif = ar->vif;
struct aggr_info *p_aggr = vif->aggr_cntxt;
struct rxtid *rxtid;
struct rxtid_stats *stats;
u16 hold_q_size;
......@@ -1422,7 +1424,9 @@ struct aggr_info *aggr_init(struct net_device *dev)
void aggr_recv_delba_req_evt(struct ath6kl *ar, u8 tid)
{
struct aggr_info *p_aggr = ar->aggr_cntxt;
/* TODO: Findout vif */
struct ath6kl_vif *vif = ar->vif;
struct aggr_info *p_aggr = vif->aggr_cntxt;
struct rxtid *rxtid;
if (!p_aggr)
......
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