Revision tags: release/12.0.0, release/11.2.0 |
|
#
d1b67106 |
| 09-Mar-2018 |
Andriy Voskoboinyk <avos@FreeBSD.org> |
net80211: wrap protection frame allocation into ieee80211_alloc_prot()
Move copy-pasted code for RTS/CTS frame allocation into net80211. While here, add stat / debug message for allocation failures
net80211: wrap protection frame allocation into ieee80211_alloc_prot()
Move copy-pasted code for RTS/CTS frame allocation into net80211. While here, add stat / debug message for allocation failures (copied from run(4)) + return error here in bwn(4).
Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D14628
show more ...
|
#
0f18e6f6 |
| 13-Feb-2018 |
Landon J. Fuller <landonf@FreeBSD.org> |
bwn(4): Conditionalize "RX decryption attempted" message on a new BWN_DEBUG_HWCRYPTO debug flag.
The MAC will attempt decryption (and set BWN_RX_MAC_DEC) even if a key has not been supplied to the h
bwn(4): Conditionalize "RX decryption attempted" message on a new BWN_DEBUG_HWCRYPTO debug flag.
The MAC will attempt decryption (and set BWN_RX_MAC_DEC) even if a key has not been supplied to the hardware; this is expected behavior, and there's no need to spam users' console with this debugging printf.
show more ...
|
#
d177c199 |
| 06-Feb-2018 |
Landon J. Fuller <landonf@FreeBSD.org> |
bwn(4): migrate bwn(4) to the native bhnd(9) interface, and drop siba_bwn.
- Remove the shim interface that allowed bwn(4) to use either siba_bwn or bhnd(4), replacing all siba_bwn calls with thei
bwn(4): migrate bwn(4) to the native bhnd(9) interface, and drop siba_bwn.
- Remove the shim interface that allowed bwn(4) to use either siba_bwn or bhnd(4), replacing all siba_bwn calls with their bhnd(4) bus equivalents. - Drop the legay, now-unused siba_bwn bus driver. - Clean up bhnd(4) board flag defines referenced by bwn(4).
Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D13518
show more ...
|
#
ac2fffa4 |
| 21-Jan-2018 |
Pedro F. Giffuni <pfg@FreeBSD.org> |
Revert r327828, r327949, r327953, r328016-r328026, r328041: Uses of mallocarray(9).
The use of mallocarray(9) has rocketed the required swap to build FreeBSD. This is likely caused by the allocation
Revert r327828, r327949, r327953, r328016-r328026, r328041: Uses of mallocarray(9).
The use of mallocarray(9) has rocketed the required swap to build FreeBSD. This is likely caused by the allocation size attributes which put extra pressure on the compiler.
Given that most of these checks are superfluous we have to choose better where to use mallocarray(9). We still have more uses of mallocarray(9) but hopefully this is enough to bring swap usage to a reasonable level.
Reported by: wosch PR: 225197
show more ...
|
#
19a63eb5 |
| 17-Jan-2018 |
Landon J. Fuller <landonf@FreeBSD.org> |
bwn(4): Enable, by default, the opt-in support for bhnd(4) introduced in r326454.
bwn(4)/bhnd(4) has been tested with most chipsets currently supported by bwn(4), and this change should be transpare
bwn(4): Enable, by default, the opt-in support for bhnd(4) introduced in r326454.
bwn(4)/bhnd(4) has been tested with most chipsets currently supported by bwn(4), and this change should be transparent to existing bwn(4) users; please report any regressions that you do encounter.
To revert to using siba_bwn(4) instead of bhnd(4), place the following lines in loader.conf(5):
hw.bwn_pci.preferred="0"
Once we're satisfied that the switch to bhnd(4) has seen sufficient broader testing, bwn(4) will be migrated to use the native bhnd(9) interface directly, and support for siba_bwn(4) will be dropped (see D13518).
Sponsored by: The FreeBSD Foundation
show more ...
|
#
26c1d774 |
| 13-Jan-2018 |
Pedro F. Giffuni <pfg@FreeBSD.org> |
dev: make some use of mallocarray(9).
Focus on code where we are doing multiplications within malloc(9). None of these is likely to overflow, however the change is still useful as some static checke
dev: make some use of mallocarray(9).
Focus on code where we are doing multiplications within malloc(9). None of these is likely to overflow, however the change is still useful as some static checkers can benefit from the allocation attributes we use for mallocarray.
This initial sweep only covers malloc(9) calls with M_NOWAIT. No good reason but I started doing the changes before r327796 and at that time it was convenient to make sure the sorrounding code could handle NULL values.
show more ...
|
#
4b49587c |
| 06-Jan-2018 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r327341 through r327623.
|
#
9fbe631a |
| 02-Jan-2018 |
Adrian Chadd <adrian@FreeBSD.org> |
[net80211] convert all of the WME use over to a temporary copy of WME info.
This removes the direct WME info access in the ieee80211com struct and instead provides a method of fetching the data. Ri
[net80211] convert all of the WME use over to a temporary copy of WME info.
This removes the direct WME info access in the ieee80211com struct and instead provides a method of fetching the data. Right now it's a no-op but eventually it'll turn into a per-VAP method for drivers that support it (eg iwn, iwm, upcoming ath10k work) as things like p2p support require this kind of behaviour.
Tested:
* ath(4), STA and AP mode
TODO:
* yes, this is slightly stack size-y, but it is an important first step to get drivers migrated over to a sensible WME API. A lot of per-phy things need to be converted to per-VAP before P2P, 11ac firmware, etc stuff shows up.
show more ...
|
#
0bffd217 |
| 14-Dec-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
Add basic bwn(4) support for the (BCMA-based) BCM43224 and BCM43225.
- Add the BCM4322X D11 core revision and missing BCM43224 PCI device ID to our device tables. - Disable the DMA engine parity c
Add basic bwn(4) support for the (BCMA-based) BCM43224 and BCM43225.
- Add the BCM4322X D11 core revision and missing BCM43224 PCI device ID to our device tables. - Disable the DMA engine parity check (rather than adding parity support to the to-be-replaced bwn(4) DMA implementation).
Currently, N-PHY support in bwn(4) is GPL licensed, and is not included by default. Until this is replaced with Broadcom's ISC-licensed N-PHY implementation, bwn(4) must be rebuilt to enable N-PHY support.
To build bwn(4) with N-PHY support, add the following lines to your kernel configuration file and rebuild the kernel (and modules):
options BWN_GPL_PHY
To test bwn(4) with a BCM43224/BCM43225 device, install the firmware from the net/bwn-firmware-kmod port, and place the following lines in loader.conf(5):
hw.bwn_pci.preferred="1"
if_bwn_pci_load="YES bwn_v4_ucode_load="YES" bwn_v4_n_ucode_load="YES" bwn_v4_lp_ucode_load="YES"
Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation
show more ...
|
#
8d14ca9c |
| 02-Dec-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
Introduce bwn(4) support for the bhnd(4) bus.
Currently, bwn(4) relies on the siba_bwn(4) bus driver to provide support for the on-chip SSB interconnect found in Broadcom's older PCI(e) Wi-Fi adapte
Introduce bwn(4) support for the bhnd(4) bus.
Currently, bwn(4) relies on the siba_bwn(4) bus driver to provide support for the on-chip SSB interconnect found in Broadcom's older PCI(e) Wi-Fi adapters. Non-PCI Wi-Fi adapters, as well as the newer BCMA interconnect found in post-2009 Broadcom Wi-Fi hardware, are not supported by siba_bwn(4).
The bhnd(4) bus driver (also used by the FreeBSD/MIPS Broadcom port) provides a unified kernel interface to a superset of the hardware supported by siba_bwn; by attaching bwn(4) via bhnd(4), we can support both modern PCI(e) Wi-Fi devices based on the BCMA backplane interconnect, as well as Broadcom MIPS WiSoCs that include a D11 MAC core directly attached to their SSB or BCMA backplane.
This diff introduces opt-in bwn(4) support for bhnd(4) by providing:
- A small bwn(4) driver subclass, if_bwn_bhnd, that attaches via bhnd(4) instead of siba_bwn(4). - A bhndb(4)-based PCI host bridge driver, if_bwn_pci, that optionally probes at a higher priority than the siba_bwn(4) PCI driver. - A set of compatibility shims that perform translation of bwn(4)'s siba_bwn function calls into their bhnd(9) API equivalents when bwn(4) is attached via a bhnd(4) bus parent. When bwn(4) is attached via siba_bwn(4), all siba_bwn function calls are simply passed through to their original implementations.
To test bwn(4) with bhnd(4), place the following lines in loader.conf(5):
hw.bwn_pci.preferred="1"
if_bwn_pci_load="YES bwn_v4_ucode_load="YES" bwn_v4_lp_ucode_load="YES"
To verify that bwn(4) is using bhnd(4), you can check dmesg:
bwn0: <Broadcom 802.11 MAC/PHY/Radio, rev 15> ... on bhnd0
... or devinfo(8):
pcib2 pci2 bwn_pci0 bhndb0 bhnd0 bwn0 ...
bwn(4)/bhnd(4) has been tested for regressions with most chipsets currently supported by bwn(4), including:
- BCM4312 - BCM4318 - BCM4321
With minimal changes to the DMA code (not included in this commit), I was also able to test support for newer BCMA devices by bringing up basic working Wi-Fi on two previously unsupported, BCMA-based N-PHY chipsets:
- BCM43224 - BCM43225
Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation & Plausible Labs Differential Revision: https://reviews.freebsd.org/D13041
show more ...
|
#
718cf2cc |
| 27-Nov-2017 |
Pedro F. Giffuni <pfg@FreeBSD.org> |
sys/dev: further adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error
sys/dev: further adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task.
The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts.
show more ...
|
Revision tags: release/10.4.0, release/11.1.0 |
|
#
7013b24d |
| 06-Apr-2017 |
Conrad Meyer <cem@FreeBSD.org> |
bwn(4): Fix trivial null dereference
Reported by: PVS-Studio Sponsored by: Dell EMC Isilon
|
#
be649680 |
| 28-Feb-2017 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r314270 through r314419.
|
#
f6313575 |
| 26-Feb-2017 |
Andriy Voskoboinyk <avos@FreeBSD.org> |
net80211 drivers: fix rate setup for EAPOL frames, obtain Tx parameters directly from the node.
- Use ni_txparms directly instead of calculating them manually every time - Move M_EAPOL flag check up
net80211 drivers: fix rate setup for EAPOL frames, obtain Tx parameters directly from the node.
- Use ni_txparms directly instead of calculating them manually every time - Move M_EAPOL flag check upper; otherwise it may be skipped due to 'ucastrate' / 'mcastrate' check - Use 'mgtrate' for control frames too (see ifconfig(8), mgtrate parameter) - Add few more M_EAPOL checks where it was missing (zyd(4), ural(4), urtw(4)) - Few unrelated cleanups
Tested with: - Intel 6205 (iwn(4)), STA mode; - WUSB54GC (rum(4)), HOSTAP mode + RTL8188EU (rtwn(4)), STA mode.
Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D9811
show more ...
|
#
242b2482 |
| 09-Oct-2016 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r306412 through r306905.
|
#
f6930bec |
| 02-Oct-2016 |
Andriy Voskoboinyk <avos@FreeBSD.org> |
net80211: ieee80211_ratectl*: switch to reusable KPI
Replace various void * / int argument combinations with common structures: - ieee80211_ratectl_tx_status for *_tx_complete(); - ieee80211_ratectl
net80211: ieee80211_ratectl*: switch to reusable KPI
Replace various void * / int argument combinations with common structures: - ieee80211_ratectl_tx_status for *_tx_complete(); - ieee80211_ratectl_tx_stats for *_tx_update();
While here, improve amrr_tx_update() for a bit: 1. In case, if receiver is not known (typical for Ralink USB drivers), refresh Tx rate for all nodes on the interface. 2. There was a misuse: - otus(4) sends non-decreasing counters (as originally intended); - but ural(4), rum(4) and run(4) are using 'read & clear' registers to obtain statistics for some period of time (and those 'last period' values are used as arguments for tx_update()). If arguments are not big enough, they are just discarded after the next call.
Fix: move counting into *_tx_update() (now otus(4) will zero out all node counters after every tx_update() call)
Tested with: - Intel 3945BG (wpi(4)), STA mode. - WUSB54GC (rum(4)), STA / HOSTAP mode. - RTL8188EU (urtwn(4)), STA mode.
Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D8037
show more ...
|
Revision tags: release/11.0.1, release/11.0.0 |
|
#
4594925d |
| 06-Jun-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] don't use a 1MB CCK RTS frame for 11a OFDM transmissions.
|
#
14b258b8 |
| 05-Jun-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] Add missing firmware release calls.
This trips me up whenever I'm fooling around with partially supported NICs that fail to fully attach or initialise - the firmware gets loaded and references
[bwn] Add missing firmware release calls.
This trips me up whenever I'm fooling around with partially supported NICs that fail to fully attach or initialise - the firmware gets loaded and references, but something fails - and the firmware references aren't cleaned up.
show more ...
|
#
4bfbed72 |
| 05-Jun-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] Enable PHY-LP 5GHz support for the one NIC I have tested it on so far.
After perusing the PHY-LP code (don't ask why; honest) I discovered that it /has/ 5GHz support - but it's not ever used.
[bwn] Enable PHY-LP 5GHz support for the one NIC I have tested it on so far.
After perusing the PHY-LP code (don't ask why; honest) I discovered that it /has/ 5GHz support - but it's not ever used. I found one NIC - a BCM4312 w/ pci id 0x4315 - which advertised dual-band PHY-LP support.
Turns out it works.
Whilst here, move up the support bit logging code so I can use it to debug this.
Tested:
* BCM4312 (pci id 0x4315); 5GHz STA operation
show more ...
|
#
40dcddfc |
| 24-May-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] begin separating out the attach path from the SIBA specific bits.
* convert phy_getinfo() to take a "gmode" flag, rather than the siba TGSHIGH flags and then check for 2GHz. This should ens
[bwn] begin separating out the attach path from the SIBA specific bits.
* convert phy_getinfo() to take a "gmode" flag, rather than the siba TGSHIGH flags and then check for 2GHz. This should ensure that gmode is set correctly even on DUALPHY NICs. * move the siba_powerup() call and the TGSHIGH decoding into a call to bwn_is_bus_siba(), and return an error if it's called on anything else. We don't yet do anything else, but when we do..
Tested:
* BCM4322, 11a STA
show more ...
|
#
a7978cf3 |
| 24-May-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] add extra debugging for non-SIBA devices.
This is a no-op at the present moment, but will eventually remind me where the SIBA specific demons lie.
Tested:
* BCM4322, STA mode
|
#
4328ca5a |
| 20-May-2016 |
Andriy Voskoboinyk <avos@FreeBSD.org> |
wi: fix a typo.
The max size of bitmask is IEEE80211_MODE_BYTES, not IEEE80211_MODE_MAX.
Reuse it in bwn(4) while I'm here.
Noticed by: kevlo
|
#
0550ee24 |
| 19-May-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] quieten the "invalid firmware state".
That pops up in the rev 5xx / 6xx microcode on the later cores (4312, 4322.) I'm not sure why this is happening yet and I'll dig into it, but Linux b43 do
[bwn] quieten the "invalid firmware state".
That pops up in the rev 5xx / 6xx microcode on the later cores (4312, 4322.) I'm not sure why this is happening yet and I'll dig into it, but Linux b43 does the same thing.
show more ...
|
#
4afc7f78 |
| 19-May-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] program in the MAC capabilities somewhere where later microcode expects it.
Obtained from: Linux b43
|
#
a5d89c93 |
| 19-May-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bwn] add extra debugging.
|