Commit Graph

4298 Commits

Author SHA1 Message Date
skrll eb4039be03 KNF some comments and whitespace. 2006-07-08 16:24:08 +00:00
skrll e5a112d805 Spelling in comments. No functional change. 2006-07-08 16:07:47 +00:00
rpaulo 81cc271bc5 Add missing semicolon. 2006-07-04 23:05:11 +00:00
rpaulo 32404d58a1 Coverity CID 3805: Close the firmware_handle on error and avoid leaks. 2006-07-04 18:26:29 +00:00
chap 710af63468 Ankh-Morpork, we have a MIDI driver....
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@
2006-06-30 13:56:25 +00:00
drochner eff818776d add some common code to support the ACPI power management timer
independly of ACPI
2006-06-26 16:13:21 +00:00
jmcneill 507a433a4e Make sure that a powerhook was successfully established before trying to
disestablish it on detach.
2006-06-25 14:49:49 +00:00
perry 9c74364e5b Add a power hook for the com device. 2006-06-25 00:39:21 +00:00
jmcneill 52f7cdcc1f Hook the lid switch, sleep button, and hibernate button into sysmon. This
enables special Fn keys on Sony Vaio laptops.
2006-06-20 15:35:11 +00:00
christos 8b28dc1494 PR/33761: dieter roelants: NetBSD doesn't recognize a RealTek 8168B nic 2006-06-18 21:32:24 +00:00
christos fcad4273ae PR/33763: dieter roelants: Realtek 8168B doesn't function. Don't align
for i386/x86_64. From FreeBSD.
2006-06-18 21:29:48 +00:00
rpaulo 656f536d09 Use IFQ_IS_EMPTY(). 2006-06-18 16:14:10 +00:00
rpaulo 7a69791e70 Remove IF_PREPEND() to comply with altq. I think the logic is safe to just
remove the macro call.
2006-06-18 15:44:49 +00:00
rpaulo c545be67e3 When calling IF_DEQUEUE() check if the dequeued mbuf is NULL to comply
with altq.
2006-06-18 15:37:27 +00:00
christos 7b128daa3b stack police: Introduce an opl_match function that uses malloc instead of
allocating ~2K of softc on the stack.
2006-06-09 21:55:33 +00:00
drochner c87a7b61b9 fix obvious botch in radiotap header alignment (untested) 2006-06-09 19:17:46 +00:00
rpaulo f5a468f537 Revert previous. Wrong way of doing things... 2006-06-09 19:13:17 +00:00
gdamore ef3b8c3cc3 Print bus_addr_t using PRIx64 (casting to uint64_t), which fixes builds
on 32-bit sparc (which have 64-bit bus_addr_t, but only 32-bit pointers.)
2006-06-08 22:42:24 +00:00
simonb dfeb2fa259 Unwrap a not-too-long line. 2006-06-08 21:04:16 +00:00
rpaulo 69ae4b1781 Bring the following change from OpenBSD:
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.
2006-06-08 20:56:41 +00:00
rpaulo 24ba5ad5fd Rename sta variable. Pointed out by Havard Eidnes and Juergen Hannken-Illjes. 2006-06-08 13:00:35 +00:00
hannken cbaa71d5f4 Add missing brace to make it compile again. 2006-06-08 10:56:49 +00:00
kardel de4337ab21 merge FreeBSD timecounters from branch simonb-timecounters
- 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
2006-06-07 22:33:33 +00:00
nakayama dc8650e97c Add void cast to functions whose return values are ignored. 2006-06-07 15:34:47 +00:00
rpaulo 431dc1da44 Attachment framework for the rt2561.c and rt2661.c drivers.
From OpenBSD.
2006-06-06 21:00:41 +00:00
rpaulo 9fc70013c7 struct ifnet must be inside sc_ec. Fixes panics on detachment. 2006-06-06 20:48:27 +00:00
rpaulo 355b4c7b38 Oops, missing arg to firmware_free. 2006-06-06 01:18:25 +00:00
rpaulo c54cf300da Don't leak memory on error. 2006-06-05 17:00:50 +00:00
rpaulo 7a35a95fe6 Add missing firmware_close(). 2006-06-05 16:59:41 +00:00
gdamore b38b3d39ad Import new HAL 0.9.17.2. Approved by sam@
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@.
2006-06-05 05:14:37 +00:00
rpaulo 76c6161871 Driver for Ralink chipsets RT2460A, RT2560, RT2561S, RT2561 and RT2661
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.
2006-06-04 20:38:06 +00:00
rpaulo 8420a4bdc7 Sean Boudreau: The eeprom bits are shifted out in host order.
Also present in the upcoming rt2560.c driver.
2006-06-03 12:02:51 +00:00
drochner 305932c524 Remove passing of an uninitialized variable found by gcc4.
(The variable was not used by the called function, so remove the
argument completely.)
2006-05-29 15:17:29 +00:00
he 732bd1213b Remove setting of xs_status to XS_STS_DONE before calling scspi_done().
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.
2006-05-27 17:56:39 +00:00
blymn a88dd3436a Clean up bogus whitespace 2006-05-26 12:52:45 +00:00
blymn 6b8a344329 Clean up bogus whitespace 2006-05-26 12:39:31 +00:00
blymn 44278a4fa1 Clean up bogus whitespace 2006-05-26 11:52:08 +00:00
christos fe6055587f void casts to functions whose return values are ignored. 2006-05-21 23:56:09 +00:00
mrg afda9ed915 initialise pos.x and pos.y to appease GCC4. 2006-05-20 07:09:08 +00:00
pavel dbbc553deb Disable hw VLAN tagging, in a similar way that it was done in OpenBSD
(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@.
2006-05-16 22:39:24 +00:00
elad 2867b68bc3 integrate kauth. 2006-05-14 21:42:26 +00:00
christos c0fdc5190f XXX: GCC uninitialized 2006-05-14 05:42:43 +00:00
dyoung 7153b68a4a Make rtwvar.h, rtw.c agree whether rtw_host_rfio and rtw_debug are
static or extern.  Problem noted by Tom Spindler.
2006-05-14 04:08:09 +00:00
xtraeme 3b291301d4 Remove code for the IT87xxF chipsets, it was included on its own
driver (it(4)).
2006-05-13 09:03:21 +00:00
tsutsui 337a4c703f According to the i8259 manual, EOI, R, and SL bits belong to OCW2 register
so rename them OCW3_* -> OCW2_*.
2006-05-12 10:58:12 +00:00
mrg ce51c72be5 quell GCC 4.1 uninitialised variable warnings. 2006-05-11 23:54:39 +00:00
mrg b18db50b21 cast the return value of several macros that evaluate to "(func() == FOO)"
to (void) to avoid "computed value not used" warnings.
2006-05-11 22:26:54 +00:00
mrg ea9579cbb2 don't declare ahc_pci_ident_table[] and ahc_num_pci_devs extern, they aren't. 2006-05-11 01:02:15 +00:00
mrg 084c052803 quell GCC 4.1 uninitialised variable warnings.
XXX: we should audit the tree for which old ones are no longer needed
after getting the older compilers out of the tree..
2006-05-10 21:53:14 +00:00
drochner f4f8d2a3de remove spl and locking stuff from interrupt handler 2006-05-10 10:27:49 +00:00