Commit Graph

26497 Commits

Author SHA1 Message Date
dyoung
355cdbdce9 Simplify interrupt (dis)establishment by two source transformations:
-       cardbus_intr_disestablish(cc, cf, ih);
+       Cardbus_intr_disestablish(ct, ih);

-       ih = cardbus_intr_establish(cc, cf, ...);
+       ih = Cardbus_intr_establish(ct, ...);

Tested with ath & atw units on a Soekris net4521.
2010-03-02 20:31:14 +00:00
jruoho
4fcde464a0 Format string cosmetics (mainly from %d to %u). 2010-03-02 18:44:46 +00:00
martin
9e8ef1a77b Before destroying a autonegotiation callout, make sure it is quiet 2010-03-02 08:30:40 +00:00
jld
b95d388b8c When setting up a non-autoconfigured RAID set, fail a component if the
attempt to read its label fails.  OKed by oster@.
2010-03-01 21:10:26 +00:00
njoly
3fab0f4f60 Do initialise i2c_attach_args new members, for indirect configuration
too.
2010-03-01 17:35:21 +00:00
oster
e0010cd0df Don't merge a good parity map with random stuff in the event that the
first component is missing.  (Since the merging just OR's the maps,
this isn't that big of a deal, as it will just over-estimate the
amount of checking that needs to be done.)
2010-03-01 14:51:58 +00:00
jruoho
da6a111dbe Destroy the callout(9) when detaching. Also evaluate the removal of the
notify handler before going to demolishing business.
2010-03-01 13:16:21 +00:00
macallan
3bc5d8b535 make latching optional.
The SPARCbook docs claim it's necessary but my 3GX happily works without.
2010-03-01 05:42:08 +00:00
jruoho
5bc6f3c06a Semantics:
* Use ACPI_ADR_PCI_DEV(x) and ACPI_ADR_PCI_FUNC(x).
  * !ACPI_FAILURE -> ACPI_SUCCESS, UINT32 -> uint32_t
  * Remove whitespace.
2010-03-01 05:37:37 +00:00
macallan
539b768657 fix ancient typo, noticed by mouse@ 2010-03-01 05:26:53 +00:00
pgoyette
7e73c12204 Now that sysmon_envsys(8) has learned how to retrieve and update sensor
limit values from the device driver, remove the high_limit and low_limit
entries from the hw.dbcool<#>.<sensor> sysctl(8) tree.  These limits are
now directly accessible via envstat(8).  Simplify the remaining code
somewhat.

No objections raised on either tech-kern@ or current-users@

XXX The fan controllers's parameters (including those that are tied to
XXX temperature sensors) are still in sysctl, since there isn't any clean
XXX way to implement the fan controllers in sysmon_envsys yet.  It is on
XXX my To-Do list...
2010-03-01 03:14:49 +00:00
pgoyette
06d81b8ad2 Move definitions of internal data structures and flag bits to avoid
exposing them to user-land.
2010-02-28 20:04:04 +00:00
jruoho
86c3014958 Introduce support for ACPI kernel modules.
Tested on couple of laptops.
2010-02-28 17:22:41 +00:00
snj
ccaf1e96be Fight the ever-increasing size of src checkouts by spelling "useful"
without an extra l.
2010-02-28 15:52:16 +00:00
snj
77db2769ee Spelling police. 2010-02-28 15:33:21 +00:00
martin
3c21532a2a Interpret the "reg" property of i2c nodes more liberal, and depending
on the cell size in use.
I have been unable to find any documents about the i2c bindings for OF,
so this is all pretty much voodoo.
2010-02-28 13:59:05 +00:00
jruoho
0f58ad7ae9 Use native functions instead of polluting the namespace with ACPICA-macros. 2010-02-28 13:56:49 +00:00
martin
046723f091 Update pcf8584 driver from OpenBSD 2010-02-28 11:47:28 +00:00
martin
a56e529332 Add direct config support for a few devices 2010-02-28 11:36:27 +00:00
martin
5aa9335e67 Supporting cast for i2c direct configuration on OF machines 2010-02-28 11:35:40 +00:00
martin
9d9a688916 Generic (device property based) framework for optional direct configuration
of i2c devices, as discussed on tech-kern.
2010-02-28 11:34:42 +00:00
jruoho
5d978521d4 Cleanup:
* Semantics.
  * Remove ACPI_LID_DEBUG.
  * Reduce the amount of error reporting.
  * As the status of the lid (open/closed) is known upon suspend, move the
    state variable to the softc, and avoid one object evaluation this way.
2010-02-28 09:23:30 +00:00
tsutsui
1609b8d6f6 KNF, misc cosmetics. 2010-02-27 05:41:22 +00:00
tsutsui
d2be1889f9 Always call device dependent functions via pointers rather than
using conditionals to switch inline functions for modern processors.
2010-02-27 04:40:11 +00:00
tsutsui
4f3417c562 Also fix a wrong mem_ring calculation in dp8390_ipkdb_attach(). 2010-02-27 04:36:56 +00:00
jakllsch
dd483616f8 Use RUN_ONCE(9) again. (Everyone happy now?) 2010-02-27 00:31:57 +00:00
jakllsch
7d0469d4c4 Use correct prototype for dmattach(). 2010-02-26 23:52:43 +00:00
pgoyette
933c70b5e1 Disable DBCOOL_DEBUG by default, and make it compile that way. 2010-02-26 18:16:18 +00:00
dyoung
edec44fc69 Cosmetic: re-wrap some line. 2010-02-26 01:16:09 +00:00
dyoung
53a8345822 Cosmetic: join a line. 2010-02-26 01:15:08 +00:00
dyoung
ad812b20b2 Introduce Cardbus_intr_establish(cardbus_devfunc_t, ...) and
Cardbus_intr_disestablish(cardbus_devfunc_t, ...) and start using them.
2010-02-26 01:12:56 +00:00
dyoung
508883c164 Use PCI_ constants and macros instead of CARDBUS_. Use
Cardbus_conf_{read,write}() instead of cardbus_conf_{read,write}().
Delete all of the CARDBUS_ constants and macros that replicate PCI_.

Compile-tested, only.
2010-02-26 00:57:01 +00:00
dyoung
eb0836d9ae Move the definitions for PCI_BAR0, PCI_BAR1, PCI_BAR2, PCI_BAR3,
PCI_BAR4, and PCI_BAR5 to pcireg.h for re-use.
2010-02-26 00:38:14 +00:00
dyoung
51d6f75dc3 sc_csr is read & written from the PCI Command & Status Register,
so make its type pcireg_t.
2010-02-26 00:01:27 +00:00
dyoung
fde907f497 Make fxp at cardbus detach during shutdown.
Stop calling (*cardbus_ctrl) to enable bus mastering, I/O and memory
spaces on the CardBus bridge.  cbb(4) always enables that stuff,
anyway.  In the process, avoid remembering what BAR we mapped by
writing CARDBUS_{IO,MEM}_ENABLE to sc_cben or sc_cbenable, and
record the BAR in use sc_bar, instead.

Replace more CARDBUS_ constants with PCI_ constants.

Compile-tested, only.
2010-02-25 23:40:39 +00:00
haad
58c910bce8 Fix device-mapper to work in builtin case. This commit fixes
PR: 42799

REwork fix commited by jak@ to be more readable and remove unneeded ifdef _MODULE.
2010-02-25 23:37:39 +00:00
matt
7b012669b8 Adapt to <powerpc/spr.h> breakup. 2010-02-25 23:34:54 +00:00
dyoung
fb7f881ea9 Use PCI_ constants instead of CARDBUS_ constants. Use Cardbus_conf_*()
functions instead of cardbus_conf_*() functions to simplify some
code.
2010-02-25 23:01:48 +00:00
dyoung
96d11f3066 Copy values from the cardbus_attach_args and use them instead of values
from the cardbus_softc.
2010-02-25 22:40:16 +00:00
dyoung
ae121f118d Don't use the cardbus_softc. Compile-tested, only. 2010-02-25 22:31:51 +00:00
dyoung
74013c932b Phase out some CardBus constants and types. Use the equivalent PCI
constants and types, instead:

        CARDBUS_CLASS_REG -> PCI_CLASS_REG
        CARDBUS_ID_REG -> PCI_ID_REG
        cardbus_product_id_t -> pci_product_id_t
        cardbus_vendor_id_t -> pci_vendor_id_t
2010-02-25 21:18:35 +00:00
macallan
8ffcf0035e add a comment on PCI_MAGIC_IO_RANGE 2010-02-25 21:09:00 +00:00
macallan
54b08bae4c some cleanup 2010-02-25 20:56:20 +00:00
jakllsch
6fc9836341 Be sure to config_cfattach_attach() in dmattach().
Loosely based on patch from Brian Brombacher,
with other inspriation from vnd(4).

This should fix PR kern/42799.

While here, a few prototype, style and namespace pollution-related changes.
2010-02-25 20:48:58 +00:00
dyoung
878053a897 Don't create the device's PCI tag with Cardbus_make_tag(9), but save and
use the tag found in the cardbus_attach_args.  Compile-tested, only.
2010-02-25 20:36:31 +00:00
msaitoh
b32bc8f5ec Merge if_wm.c rev. 1.162.4.13 and if_wmvar.h rev. 1.2.46.3 into maintrunk.
Increase the timeout value to prevent timeout on 80003. The values are taken
from Intel's e1000 driver. Tested by spz and me.
2010-02-25 15:07:06 +00:00
drochner
4faa4ba521 retire our private definitions for the scan1/3/5/7/9 DEC graphics
symbols, use the unicode definitions instead (which apparently didn't
exist when I wrote that)
2010-02-25 11:20:09 +00:00
macallan
0320314aca a very preliminary driver for Wildcat 5110 / Sun XVR-500 graphics boards
Since we don't have any documentationthis driver is unaccelerated and thanks
to the insane state we get the hardware in it's also slow and scrolling
looks weird.
Some hardware info came from OpenBSD's ifb driver.
2010-02-25 03:33:09 +00:00
macallan
df530d6bed regen 2010-02-25 03:20:02 +00:00
macallan
0c6f3037b6 add 3Dlabs Wildcat 5110, also known as Sun XVR-500 2010-02-25 03:18:44 +00:00