Commit Graph

26275 Commits

Author SHA1 Message Date
martin
cabe7be741 Remove sparc specific code, rely on device properties instead 2010-01-21 16:14:39 +00:00
martin
65cc18f336 fix a ref counting leak 2010-01-21 15:56:08 +00:00
jruoho
791571cbd1 In preparation for upcoming changes:
* Provide proper definitions and use these.
  * Clarify the evaluation of _STA.
  * Mark the state of a sensor according to the return value from _STA.
  * Share the basic object evaluation in _BIF and _BST.
  * Verify the object types before using the objects.
  * Be aware of bogus values from _BIF and _BST, as noted in the
    specification.

Despite of the list, functional change should be minimal. Ok pgoyette@.
2010-01-21 08:57:17 +00:00
msaitoh
8ececd13c6 Remove an extra debug printf(). KNF.
No functional change.
2010-01-21 08:52:20 +00:00
macallan
8953b23350 make RI_CENTER and RI_FULLCLEAR work with a shadow framebuffer 2010-01-21 05:32:18 +00:00
dyoung
17096c0d86 Cosmetic: join some lines. Get out early on errors, change
switch (...) {
                ...
                error = ...;
                break;
        }
        return error;

to

        switch (...) {
                ...
                return ...;
        }
2010-01-21 02:53:51 +00:00
dyoung
4cb8eac3b5 All that the activation hook radioactivate() did was to change
sc_dying, and nothing in the driver examines sc_dying, so get rid of
radioactivate() and sc_dying.
2010-01-21 02:19:55 +00:00
dyoung
975667d3ea Take care not to dereference a NULL softc. 2010-01-21 02:14:42 +00:00
martin
6d8f3b9e7c Remove sparc specific code and HME_USE_LOCAL_MAC_ADDRESS hack, instead
use the "mac-address" device property if present.
2010-01-20 22:58:37 +00:00
dyoung
146411a622 Cosmetic: get out of cgdioctl() early. Instead of
int ret;

        switch (...) {
        case ...:
                ret = ...;
                break;
        }
        return ret;

write:

        switch (...) {
        case ...:
                return ...;
        }
2010-01-20 19:00:47 +00:00
dyoung
c95d6a20b9 Get out of cgd_detach() early on error. Do not call disk_destroy(9)
on error, that leaves the cgd_softc in an inconsistent state.

Fixes a crash during shutdown reported by Patrick Welche.  Thanks
to Patrick for reporting and for testing the fix.
2010-01-20 18:55:17 +00:00
tonnerre
9956b4e182 Signedness bug/crash in azalia and hdaudio. Fixes PR 42604.
By Pierre Pronchery.
2010-01-20 09:05:12 +00:00
pooka
654415b2b7 Get rid of last "easy" kernel symbols starting with __:
__assert -> kern_assert
__sigtimedwait1 -> sigtimedwait1
__wdstart -> wdstart1

The rest are MD and/or shared with userspace, so they will require
a little more involvement than what is available for this quick
"ride the 5.99.24 bump" action.
2010-01-19 22:28:30 +00:00
pooka
10fe49d72c Redefine bpf linkage through an always present op vector, i.e.
#if NBPFILTER is no longer required in the client.  This change
doesn't yet add support for loading bpf as a module, since drivers
can register before bpf is attached.  However, callers of bpf can
now be modularized.

Dynamically loadable bpf could probably be done fairly easily with
coordination from the stub driver and the real driver by registering
attachments in the stub before the real driver is loaded and doing
a handoff.  ... and I'm not going to ponder the depths of unload
here.

Tested with i386/MONOLITHIC, modified MONOLITHIC without bpf and rump.
2010-01-19 22:06:18 +00:00
bouyer
3ccd2d9884 bio(4) is MP-safe but mfi(4) is not. So get the kernel_lock at
mfi_ioctl() entry and release it on exit.
2010-01-19 20:54:32 +00:00
pooka
58247e10a2 hp@isa was marked non-compiling and broken 14 years ago. I'm sure
the tens of well-tested changes since then have been necessary,
but now i'll just spoil the fun for everyone by sending the driver
to the attic.
2010-01-19 12:41:41 +00:00
mbalmer
73f895a875 Add the IBM 481033H SCC 2010-01-19 12:11:21 +00:00
mbalmer
0592b54dfc regenerate 2010-01-19 12:00:51 +00:00
mbalmer
ee9ebce313 Add two IBM RSS devices. 2010-01-19 11:43:33 +00:00
dyoung
c217bc3b1d If the device does not exist, return ENXIO, as is customary, instead of
ENODEV.  Ok jmcneill@.
2010-01-18 23:57:14 +00:00
pgoyette
299ee01345 If no limits are exceeded, make sure we set state to SVALID 2010-01-18 21:48:15 +00:00
martin
9e839480f0 Add two CTI rs485 dongles 2010-01-18 20:57:13 +00:00
martin
86b7d7433b regen 2010-01-18 20:55:37 +00:00
martin
f0b282446a Add two CTI usb-rs485 adapters 2010-01-18 20:54:22 +00:00
pooka
63ee3d24ed Remove unused macro definition (the NetBSD version would just not go
through a compiler).
2010-01-18 20:45:12 +00:00
pooka
d305920d2d nuke unused bpf inclusions 2010-01-18 19:00:58 +00:00
pooka
8052f8db95 Remove conditional inclusion of unused bpf.h 2010-01-18 18:52:35 +00:00
jruoho
f4cdb6678e Fix and improve several comments. 2010-01-18 18:49:27 +00:00
jruoho
e5a9d901c0 Use acpi_eval_reference_handle() to simplify code. No functional change.
ok jmcneill@, pgoyette@
2010-01-18 18:36:49 +00:00
jdc
8427f80fba Add definitions for CAS_INTR_REG and CAS_INTR_PCI. 2010-01-18 18:09:22 +00:00
jruoho
81e1657ee2 Introduce acpi_eval_reference_handle() --
an utility function to evaluate reference handles from package elements.

ok jmcneill@, pgoyette@
2010-01-18 18:06:31 +00:00
jruoho
8391833e8a Ensure that the return string is NUL-terminated in acpi_eval_string().
ok jmcneill@, pgoyette@
2010-01-18 17:34:37 +00:00
jruoho
91262361ae Add definitions for volume keys.
ok jmcneill@
2010-01-18 17:11:00 +00:00
jruoho
517e16fb9b Fix a minor bug where a reference handle is used for error reporting even
though it may not be present. While here, convert few lines to aprint_*().

ok pgoyette@
2010-01-18 17:09:17 +00:00
jruoho
25608cae55 regen. 2010-01-18 16:50:08 +00:00
jruoho
71c4a74b58 Add some ACPI 4.0 devices.
ok jmcneill@, pgoyette@
2010-01-18 16:34:47 +00:00
pooka
b99665a360 Nuke "ummmm" quality macro. It's outside __NetBSD__, so not
functional change, but some C parsers that don't know which cpp
macros are defined fall and hurt themselves quite badly with it.
2010-01-18 01:51:25 +00:00
pooka
64da563d90 Forward declare struct bpf_if and use that as the type for bpf_if
instead of "void *".  Buys us oo times the type-safety for 0 times
the price.
(no functional change)
2010-01-17 19:45:06 +00:00
jdc
614dee5907 Mask out (disable) cas interrupts on detach and suspend.
(Re-)enable interrupts on resume.
2010-01-17 11:57:29 +00:00
dyoung
af2b13bf18 Delete some dead (#ifdef notyet) code. 2010-01-16 18:43:34 +00:00
bouyer
8189b574e4 Fix leak of a usbd_xfer_handle when a interrupt pipe is aborted then
closed:
usbd_open_pipe_intr() allocates a usbd_xfer_handle for pipe->intrxfer.
Most usb device drivers using interrupt pipes call usbd_abort_pipe()
then usbd_close_pipe(), usbd_close_pipe() is supposed to free pipe->intrxfer.
But usbd_abort_pipe() calls [uoe]hci_device_intr_abort() which,
if the xfer aborted is pipe's intrxfer, sets pipe->intrxfer to NULL.
So usbd_close_pipe() can't free it and the usbd_xfer_handle is lost.

To fix this, in usbd_abort_pipe() remember the pipe->intrxfer's value
on entrie, and if it's different after usbd_ar_pipe(), call
usbd_free_xfer with the original value.
Confirmed to fix the memory leak on close() with umodem(4) and
uplcom(4).
2010-01-16 17:03:03 +00:00
bouyer
3c5e160011 Add apc(4), a driver for the Aurora Personality Chip (APC) found
on SPARCstation-4/5, and emulated by qemu to idle the simulator
when the CPU is idle. Infos about the registers from the linux driver.
Not enabled by default because it can cause some Sparc systems to
hang (so says the linux driver).
Only the CPU idle part implemented at this time; fan speed and
Convenience power outlet management to be added.
Tested on qemu.
2010-01-15 20:57:12 +00:00
mjacob
1f74793503 Amazingly, we've been freeing a handle and then using that which it referred
to for years. Bad.
2010-01-15 20:09:09 +00:00
msaitoh
86ff2cac75 Fixes the rx stall problem on 82578 by MANY workaround code.
We need more work for 82577.
2010-01-14 18:56:01 +00:00
sborrill
f5b7520428 Regen 2010-01-14 11:27:52 +00:00
sborrill
5b8adc00bc Fix typo in (unused) vendor name 2010-01-14 11:27:23 +00:00
matthias
1bb1b66ea8 Make ums.c work with a "Microsoft Natural Ergonomic Desktop 7000" mouse.
XXX The tilt function still doesn't work for me.
2010-01-14 09:30:39 +00:00
macallan
089ff6369d set a delta value on the master channel and move it to the outputs class so
volume control via PMF works
2010-01-14 02:21:19 +00:00
macallan
351d4f5ebb set a delta value for the master channel so volume control via PMF works 2010-01-14 02:20:07 +00:00
macallan
8eb1405f38 actually assign audio control command codes to the audio control keys 2010-01-14 02:18:59 +00:00