sta_info.c (860dbce3d8dd90cb9e909c58fa79808766243651) | sta_info.c (bd718fc11d5b184701e7fd8302033e31a3a03ba8) |
---|---|
1/* 2 * Copyright 2002-2005, Instant802 Networks, Inc. 3 * Copyright 2006-2007 Jiri Benc <jbenc@suse.cz> 4 * Copyright 2013-2014 Intel Mobile Communications GmbH 5 * Copyright (C) 2015 - 2017 Intel Deutschland GmbH | 1/* 2 * Copyright 2002-2005, Instant802 Networks, Inc. 3 * Copyright 2006-2007 Jiri Benc <jbenc@suse.cz> 4 * Copyright 2013-2014 Intel Mobile Communications GmbH 5 * Copyright (C) 2015 - 2017 Intel Deutschland GmbH |
6 * Copyright (C) 2018 Intel Corporation | 6 * Copyright (C) 2018-2019 Intel Corporation |
7 * 8 * This program is free software; you can redistribute it and/or modify 9 * it under the terms of the GNU General Public License version 2 as 10 * published by the Free Software Foundation. 11 */ 12 13#include <linux/module.h> 14#include <linux/init.h> --- 384 unchanged lines hidden (view full) --- 399 skb_queue_head_init(&sta->ps_tx_buf[i]); 400 skb_queue_head_init(&sta->tx_filtered[i]); 401 sta->airtime[i].deficit = sta->airtime_weight; 402 } 403 404 for (i = 0; i < IEEE80211_NUM_TIDS; i++) 405 sta->last_seq_ctrl[i] = cpu_to_le16(USHRT_MAX); 406 | 7 * 8 * This program is free software; you can redistribute it and/or modify 9 * it under the terms of the GNU General Public License version 2 as 10 * published by the Free Software Foundation. 11 */ 12 13#include <linux/module.h> 14#include <linux/init.h> --- 384 unchanged lines hidden (view full) --- 399 skb_queue_head_init(&sta->ps_tx_buf[i]); 400 skb_queue_head_init(&sta->tx_filtered[i]); 401 sta->airtime[i].deficit = sta->airtime_weight; 402 } 403 404 for (i = 0; i < IEEE80211_NUM_TIDS; i++) 405 sta->last_seq_ctrl[i] = cpu_to_le16(USHRT_MAX); 406 |
407 for (i = 0; i < NUM_NL80211_BANDS; i++) { 408 u32 mandatory = 0; 409 int r; 410 411 if (!hw->wiphy->bands[i]) 412 continue; 413 414 switch (i) { 415 case NL80211_BAND_2GHZ: 416 /* 417 * We use both here, even if we cannot really know for 418 * sure the station will support both, but the only use 419 * for this is when we don't know anything yet and send 420 * management frames, and then we'll pick the lowest 421 * possible rate anyway. 422 * If we don't include _G here, we cannot find a rate 423 * in P2P, and thus trigger the WARN_ONCE() in rate.c 424 */ 425 mandatory = IEEE80211_RATE_MANDATORY_B | 426 IEEE80211_RATE_MANDATORY_G; 427 break; 428 case NL80211_BAND_5GHZ: 429 mandatory = IEEE80211_RATE_MANDATORY_A; 430 break; 431 case NL80211_BAND_60GHZ: 432 WARN_ON(1); 433 mandatory = 0; 434 break; 435 } 436 437 for (r = 0; r < hw->wiphy->bands[i]->n_bitrates; r++) { 438 struct ieee80211_rate *rate; 439 440 rate = &hw->wiphy->bands[i]->bitrates[r]; 441 442 if (!(rate->flags & mandatory)) 443 continue; 444 sta->sta.supp_rates[i] |= BIT(r); 445 } 446 } 447 |
|
407 sta->sta.smps_mode = IEEE80211_SMPS_OFF; 408 if (sdata->vif.type == NL80211_IFTYPE_AP || 409 sdata->vif.type == NL80211_IFTYPE_AP_VLAN) { 410 struct ieee80211_supported_band *sband; 411 u8 smps; 412 413 sband = ieee80211_get_sband(sdata); 414 if (!sband) --- 2029 unchanged lines hidden --- | 448 sta->sta.smps_mode = IEEE80211_SMPS_OFF; 449 if (sdata->vif.type == NL80211_IFTYPE_AP || 450 sdata->vif.type == NL80211_IFTYPE_AP_VLAN) { 451 struct ieee80211_supported_band *sband; 452 u8 smps; 453 454 sband = ieee80211_get_sband(sdata); 455 if (!sband) --- 2029 unchanged lines hidden --- |