Merge from chap-midi branch, after
~month for review
Comments by thorpej@ drochner@ and Alexandre Ratchov
Incorporated: points by thorpej@ drochner@; preliminary support for
a stats-collecting ioctl suggested by martin@ from comments by A.R.
PR kern/32441 kern/32442 kern/32567 kern/32588 kern/32694 kern/33590
kern/33614 and one instance of kern/32651
ok martin@
Keep track of the average RSSI using an Exponential Moving Average (EMA).
Use it to dynamically tune radio receive sensitivity.
The idea is simple:
- increase sensitivity when the RSSI is bad to optimize throughput on
long distance to the AP, and
- decrease sensitivity when the RSSI is good to reduce noise level and
optimize throughput on short distance to the AP
The EMA allows to smooth RSSI variations so we don't end up changing the
sensitivity too frequently. We check if it would be worth updating the
sensitivity every one second.
RSSI thresholds were taken from the Ralink Tech. Linux driver.
- struct timeval time is gone
time.tv_sec -> time_second
- struct timeval mono_time is gone
mono_time.tv_sec -> time_uptime
- access to time via
{get,}{micro,nano,bin}time()
get* versions are fast but less precise
- support NTP nanokernel implementation (NTP API 4)
- further reading:
Timecounter Paper: http://phk.freebsd.dk/pubs/timecounter.pdf
NTP Nanokernel: http://www.eecis.udel.edu/~mills/ntp/html/kern.html
New HAL includes some driver changes to register accesses.
Adds support for WLAN devices on AR5312 family devices.
Adds support 32-bit SPARC ath devices (untested).
ath enabled in SPARC64 GENERIC builds.
This HAL is tested and known to work for i386 PCI devices, SPARC64 PCI devices,
and AR5312 WiSoC devices. MIPS PCI devices appear to be busted (possibly only
on Alchemy hardware, unconfirmed), and cardbus support is untested due to
lack of test hardware.
Please report any new problems with this import to garrett@.
from FreeBSD/OpenBSD that supersedes ral*.[ch].
Not yet enabled because I don't have a CardBus controller to test and it
will most likely crash during detach.
I tried to include our modifications, but if something is missing please
tell me or add it.
Special thanks to minipci.biz for the donation of one PCI RT2661 and
one CardBus RT2661.
After revision 1.135 of scsipi_base.c, it's a big no-no to set
XS_STS_DONE before calling scsipi_done(). Besides, scsipi_done()
sets XS_STS_DONE itself after checking that it's not already set.
This puts this driver back in working order; before this change
the probe of the logical drives would cause a hang.
(src/sys/dev/ic/re.c rev. 1.15). The disabled VLAN stripping is mine.
(The OpenBSD driver forgot to do this.)
The reason is that untagged packets get sometimes tagged incorrectly.
PR 32643.
Approved by martin@.