Commit Graph

28018 Commits

Author SHA1 Message Date
yamt 04a6913f3d tprof_start: don't forget to restore refcount when failed to start backend. 2011-02-25 22:35:38 +00:00
jruoho 0db13a33ab Comment the coordination types. 2011-02-25 20:59:37 +00:00
jruoho a080ec141b Start to derive the percpu(9) (or per-domain) state coordination
mechanisms by parsing the _CSD, _PSD, and _TSD objects by default.
2011-02-25 19:55:06 +00:00
jruoho eb43e911ff Rename couple of badly named functions for consistency. No functional change. 2011-02-25 12:08:35 +00:00
jruoho 97b3ad9cac Add preliminary support for the IA32_APERF and IA32_MPERF frequency counters.
These are not yet used for anything and only Intel is supported at the moment.
2011-02-25 09:16:00 +00:00
jruoho 86bc152d93 Store a pointer to cpu_info rather than cpu_info::ci_acpiid alone. 2011-02-25 06:18:02 +00:00
jruoho c601745de5 Clarify a comment. 2011-02-25 05:07:43 +00:00
jmcneill be74080bef regen 2011-02-25 01:36:37 +00:00
jmcneill 8a76752a98 add AMD (ATI) Radeon HD 6310 Graphics ID 2011-02-25 01:36:18 +00:00
jmcneill 351de62b93 regen 2011-02-25 01:33:59 +00:00
jmcneill f45045c099 add AMD Family14h host bridge IDs 2011-02-25 01:33:34 +00:00
matt 95ad459439 Add Intel Pineview support 2011-02-24 20:01:53 +00:00
matt 274ce75f7e Regen. 2011-02-24 20:01:26 +00:00
matt 44e4746a62 Update desc for RT3090. Add Intel NM10_LPC 2011-02-24 20:00:59 +00:00
hannken 05e91bfee8 fss(4): Allow FSSIOCSET to set the initial flags. Add a new flag
"FSS_UNLINK_ON_CREATE" to unlink the backing store before
        the snapshot gets created.

With this change dump(8) no longer dumps the zero-sized, but named
snapshot it is working on.  Same applies to fsck_ffs(8).
2011-02-24 09:38:57 +00:00
macallan d78d6ba2bb add a hack to allow mapping the video memory portions of a mach64's aperture
with BUS_SPACE_MAP_PREFETCHABLE
This probably needs to go in its own function to avoid more clutter when adding
more hacks.
tested on macppc
2011-02-24 03:37:02 +00:00
matt 4d029fbb4d Regen. 2011-02-24 00:33:44 +00:00
matt e6d2f48082 Add RT3090 2011-02-24 00:33:17 +00:00
dyoung b9ac9d0f72 Correct device_t/softc split and, while I am here, delete commented-out
code.  Patrick Welche says that this patch fixes the problem that he
reported on current-users@.

BTW, sc_dev is initialized in radioattach(), but I do not see where it
is used.
2011-02-23 16:20:30 +00:00
jmcneill e6634feab8 regen 2011-02-23 12:22:42 +00:00
jmcneill d56620e500 add Realtek RTL8188CE Wireless LAN 802.11n PCI-E NIC 2011-02-23 12:22:20 +00:00
jruoho bf04997f97 Lower the worst-case latency in P- and T-state transitions to 1 usec.
The previous 10 usec was based on the Intel's Core family. It may have been
improved since that. Also provide an arbitrary upper bound for BIOS bugs.
2011-02-23 06:17:55 +00:00
jruoho 05fb6a1824 Adjust the previous and add a comment for it. 2011-02-23 06:02:00 +00:00
jmcneill c2a7a21fae match on MII_MODEL_ATTANSIC_L2
alc0 at pci3 dev 0 function 0: Atheros AR8152 v2.0 PCIe Fast Ethernet
alc0: ioapic0 pin 17
alc0: Ethernet address 00:26:6c:9e:d4:c1
atphy0 at alc0 phy 0: L2 10/100 PHY, rev. 5
atphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT-FDX, auto
2011-02-23 03:22:44 +00:00
jmcneill 1bd6ec13d5 catch up with FreeBSD driver, adds support for AR815x chips 2011-02-23 02:25:04 +00:00
jmcneill c316b0ab0f add network driver for Atheros AR813x/AR815x ethernet controllers, based
on a patch from fire crow on tech-net with additional bpf & detach fixes,
module support, and a match for 8152 v2.0 devices.

alc0 at pci3 dev 0 function 0: Attansic/Atheros L1C/L2C Ethernet
alc0: ioapic0 pin 17
alc0: Ethernet address 00:26:6c:9e:d4:c1
ukphy0 at alc0 phy 0: L2 10/100 PHY (OUI 0x00c82e, model 0x0002), rev. 5
ukphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT-FDX, auto
2011-02-23 00:35:29 +00:00
jmcneill 1af493e243 regen 2011-02-22 23:20:52 +00:00
jmcneill 992862540a Add Atheros AR8132, AR8151, AR8151 v2.0, AR8152 v1.1, and AR8152 v2.0 2011-02-22 23:20:15 +00:00
dyoung 97a68946b9 Use /*FALLTHROUGH*/. 2011-02-22 21:19:30 +00:00
jruoho 53139a574d Fix previous. Not my day. 2011-02-22 17:19:58 +00:00
jruoho f7e44b18e5 Yet another small fix to the C-state parsing. As can be seen from the _CST
object noted in the revision 1.40, there is only one C-state on the machine,
yet the BIOS define its type as C2. Thus, instead of relying on the BIOS
data, sequentially count the parsed C-states.
2011-02-22 17:16:04 +00:00
jmcneill b5c82123a3 make this build again 2011-02-22 16:39:05 +00:00
jruoho 5dc29dcc76 After a closer examination, remove entirely the check that was considered in
the revision 1.38. As noted in the specification (ACPI 4.0, p. 314):

  The platform must expose a _CST object for either all or none of its
  processors. If the _CST object exists, OSPM uses the C state information
  specified in the _CST object in lieu of P_LVL2 and P_LVL3 registers
  defined in P_BLK and the P_LVLx_LAT values defined in the FADT.

The _CST is seemingly valid on the system under consideration:

        Name (_CST, Package (0x02)
        {
            0x01,
            Package (0x04)
            {
                ResourceTemplate ()
                {
                    Register (SystemIO,
                        0x08,               // Bit Width
                        0x00,               // Bit Offset
                        0x000000000000F800, // Address
                        0x01,               // Access Size
                        )
                },

                0x02,
                0x0064,
                0x00000000
            }
        })

The check was also unnecessary in the sense that ACPI doesn't use bus_space(9).
2011-02-22 16:05:30 +00:00
jruoho 9e252589bd Always declare HALT as available. If ACPI_FADT_C1_SUPPORTED is not
set in the FADT, print a warning, as it is obviously a BIOS bug.
2011-02-22 09:39:48 +00:00
jruoho 9a2a620992 Only check if the register address in _CST is valid if the ACPI processor
object address is valid. Some systems define the Processor() as:

    Scope (_PR)
    {
        Processor (C000, 0x00, 0x00000410, 0x06) {}
        Processor (C001, 0x01, 0x00000000, 0x00) {}
        Processor (C002, 0x02, 0x00000000, 0x00) {}
        Processor (C003, 0x03, 0x00000000, 0x00) {}
    }

This may be typical to AMD systems that do not seem to use _CST, but instead
operate with HLT (and C1E for the C3-state). The same check is already done
in acpicpu_cstate_fadt(). Note that it is unclear whether this violates the
specification, given:

   "PBlockAddress provides the system I/O address for the processors
    register block. Each processor can supply a different such address.
    PBlockLength is the length of the processor register block, in bytes and
    is either 0 (for no P_BLK) or 6.  With one exception, all processors are
    required to have the same PBlockLength.  The exception is that the boot
    processor can have a non-zero PBlockLength when all other processors
    have a zero PBlockLength.  It is valid for every processor to have a
    PBlockLength of 0. (ACPI 4.0, p. 626)"
2011-02-22 09:34:13 +00:00
jmcneill e6a9aa35b1 genfb_enable/disable_polling only matters if genfb is the console screen,
so make it a noop if it's not
2011-02-22 01:26:14 +00:00
jmcneill 60ff45242c make ural_ioctl look like other wireless drivers, should make dhcpcd and
mdnsd work again
2011-02-22 01:11:30 +00:00
jmcneill 9f8d6eb8fa make rum_ioctl look like other wireless drivers, now dhcpcd works and
mdnsd doesn't hang my laptop
2011-02-22 00:58:08 +00:00
jmcneill 8793159934 sync driver with openbsd 2011-02-21 23:50:42 +00:00
jmcneill aa8968aa00 print the device name at attach, like so:
ath0 at pci4 dev 0 function 0: Atheros 9280
2011-02-21 14:43:58 +00:00
njoly 1c1483eecb Regen: Add two more Intel 82Q45 devices. 2011-02-21 13:38:55 +00:00
njoly 9243552578 Add two more Intel 82Q45 devices. 2011-02-21 13:38:18 +00:00
he b062cb6f94 Since hilkbd_rawrepeat() is only defined under WSDISPLAY_COMPAT_RAWKBD,
protect the declaration similarly to avoid build failure of the INSTALL
kernel.
2011-02-21 12:33:05 +00:00
itohy ed461fc193 Cleanup my copyright notice. 2011-02-21 02:31:57 +00:00
msaitoh 134bad206f - Add support for Moschip NM9904 and NM9922. These devices use PCI multi
function, so only one PUC_PORT_TYPE_COM entry is used in these devices.
- Use macro.
2011-02-20 22:22:02 +00:00
msaitoh c6e0f21ce4 regen. 2011-02-20 22:16:50 +00:00
msaitoh 2166be50af Add MosChip(Netmos) 9904 and 9922.
Add MosChip(Netmos) 9865 (already supported by puc(4))
2011-02-20 22:16:18 +00:00
jruoho 6f104f5638 Use kmem(9). Also retire ACPI_PCI_FIXUP and PCI_INTR_FIXUP_DISABLED #ifdefs. 2011-02-20 16:24:54 +00:00
jmcneill 6a0ee33bc0 add VirtualBox DRM driver 2011-02-20 15:40:21 +00:00
jruoho 0aef142598 Split fujbp(4) and fujhk(4) to separate instances from fujitsu(4). Allows
modularization and takes care of tsutsui@'s justified concern over the too
generic name "fujitsu". Ok gsutre@.
2011-02-20 08:31:46 +00:00
matt 045e8178c9 Add some missing includes of <sys/device.h> 2011-02-20 08:03:22 +00:00
matt e0c47ee162 (XXX this should be a library like libsa).
Deal with the need to save/restore T8 (CURLWP) across arcbios calls.
Call arcbios with O32 ABI conventions even if kernel/bootloader is N32/N64.
2011-02-20 08:02:46 +00:00
jruoho 8bd40def25 Always explicitly enable the wake GPE for acpibut(4). This follows FreeBSD
and Linux, although it is somewhat unclear why this is necessary. But better
safe than sorry.
2011-02-20 06:59:53 +00:00
jruoho 762d68ff2c Add quirk support for _OSI strings introduced in ACPICA 20110211. While
here, clean up acpi_probe() and the quirk code. Remove #ifdef ACPI_DEBUGGER.
2011-02-20 06:45:32 +00:00
jmcneill b2dc0777b6 support building as a module 2011-02-20 03:56:45 +00:00
jmcneill 80da431343 support building as a module 2011-02-20 03:55:18 +00:00
riz 6725bff41a Use PRId64 instead of lld, and PRIx64 instead of llx when compiling
with MVSATA_DEBUG.
2011-02-20 01:26:22 +00:00
jmcneill 1d08408fe8 more AGP v3 fixes from FreeBSD:
- fix a typo when enabling the aperture (read wrong register)
 - get_aperture/set_aperture: handle AGP v3 APSIZE register layout
2011-02-19 20:07:02 +00:00
jruoho c9d84242af After the GPE handler has finished, inform ACPICA that the interrupt has
been handled and it is safe to re-enable the GPE. Should fix all problems
introduced during the merge of ACPICA 20110211.
2011-02-19 19:39:28 +00:00
jruoho 3af8b2cb19 Revisit the wake-device code once more.
1. Remove the AcpiEnableGpe() call. This was wrong.

  2. Only call _PSW or _DSW for devices that are scheduled for wake.
     This was an old bug.

  3. Only enable wake GPEs during suspend. Disabling these for
     devices not setup for wake was causing problems.

  4. No wake GPEs should be enabled at runtime.
     Unconditionally disable these during resume.

This should make the wake-device code work again. Note that waking via
pckbd(4) has always been unreliable; the _PRW object is not typically located
under the PC keyboard object, but in the parent of it (e.g. the LPC bridge).
2011-02-19 09:52:32 +00:00
enami ec02ea412c Define accessors for number of blocks and partition size in the
component label and use them where appropriate.  Disscussed on tech-kern.
2011-02-19 07:11:09 +00:00
jmcneill 56e0e00bb2 add Adaptec RAID 3405 2011-02-18 22:54:27 +00:00
jmcneill 9213e5d254 regen 2011-02-18 22:53:38 +00:00
jmcneill 3d4802dd04 add Adaptec RAID 3405 2011-02-18 22:52:53 +00:00
phx e786622161 Include <sys/gpio.h> for GPIOMAXNAME to make it compile again when a gpio(4)
device is attached.
2011-02-18 21:38:17 +00:00
jmcneill 3836fe16df call vcons_hard_switch to switch to the console screen when entering polling
mode, makes ddb-from-X work with genfb on x86
2011-02-18 13:56:58 +00:00
jmcneill a1001814e2 add vcons_hard_switch, for switching w/o callouts (eg. entering ddb) 2011-02-18 13:56:11 +00:00
jruoho 53d29cc6c2 A small cleanup for the previous; use kmem(9), add assertions, etc. 2011-02-18 13:56:03 +00:00
jruoho 1ce01ed2f8 Remove the (debug) check that evaluated whether the first T-state (i.e. the
100 % duty cycle) had control value of zero, as in the IA32 clock modulation
MSR. As the access may be based on I/O, it is unclear if a strict validation
like this was correct. Should fix the problem reported by Hisashi T Fujinaka
on current users.
2011-02-18 07:00:05 +00:00
jruoho 80a2b0455e As explained in the new ACPICA documentation, as of ACPICA 20101207, the
_PRW methods are no longer automatically executed as part of the ACPICA
initialization. Refactor and rewrite the wake-device code to account this.
2011-02-17 19:36:49 +00:00
jruoho 41e8c1fe85 Include acdebug.h for the ACPICA debugger. 2011-02-17 12:08:46 +00:00
jruoho 9a25770d19 ACPICA 20101209:
Completed the major overhaul of the GPE support code that was begun in July
2010. Major features include: removal of _PRW execution in ACPICA (host
executes _PRWs anyway), cleanup of "wake" GPE interfaces and processing,
changes to existing interfaces, simplification of GPE handler operation, and
a handful of new interfaces:

    AcpiUpdateAllGpes
    AcpiFinishGpe
    AcpiSetupGpeForWake
    AcpiSetGpeWakeMask

ACPICA 20100702:

Implemented several updates to the recently added GPE reference count
support. The model for "wake" GPEs is changing to give the host OS complete
control of these GPEs. Eventually, the ACPICA core will not execute any _PRW
methods, since the host already must execute them. Also, additional changes
were made to help ensure that the reference counts are kept in proper
synchronization with reality. Rafael J. Wysocki.

1) Ensure that GPEs are not enabled twice during initialization.
2) Ensure that GPE enable masks stay in sync with the reference count.
3) Do not inadvertently enable GPEs when writing GPE registers.
4) Remove the internal wake reference counter and add new AcpiGpeWakeup
interface. This interface will set or clear individual GPEs for wakeup.
5) Remove GpeType argument from AcpiEnable and AcpiDisable. These interfaces
are now used for "runtime" GPEs only.
2011-02-17 10:49:29 +00:00
jmcneill 2bf4673f17 cast curlwp to uintptr_t before casting to ACPI_THREAD_ID, fixes i386 build 2011-02-17 10:35:50 +00:00
jruoho 99109677b7 ACPICA 20100806:
Fixed a problem with the prototype for AcpiOsReadPciConfiguration.
The prototype in acpiosxf.h had the output value pointer as a (void *).
It should be a (UINT64 *). This may affect some host OSL code.
2011-02-17 10:23:43 +00:00
jruoho 01d77446c4 ACPICA 20100806:
Obsolete Functions: AcpiOsValidateInterface - no longer used.
2011-02-17 10:21:43 +00:00
jruoho 303587c62f ACPICA 20100915:
Removed the AcpiOsDerivePciId OSL interface. The various host
implementations of this function were not OS-dependent and are now obsolete
and can be removed from all host OSLs.  This function has been replaced by
AcpiHwDerivePciId, which is now part of the ACPICA core code.
AcpiHwDerivePciId has been implemented without recursion.  Adds one new
module, hwpci.c.  ACPICA BZ 857.
2011-02-17 10:20:32 +00:00
jruoho 3b274ab6bf Switch acpi(4) to use the new location of ACPICA. 2011-02-17 07:34:42 +00:00
jruoho 3993e0d154 Make the WMI modules depend on the parent mapper. 2011-02-16 13:15:49 +00:00
jruoho ea9b26744b As suggested by Sverre Froyen in a follow-up to PR # 41698, change the
sensor names to real words (e.g. "temperature 1" instead of "TEMP_1").
No functional change; only consistent envstat(8) output with other sensors.
2011-02-16 10:08:05 +00:00
jruoho 5f852a8424 Change the preprocessor defines around the module(9)'s modcmd() calls such
that the modules show in modstat(8) even though these are "builtin".
2011-02-16 09:05:12 +00:00
jruoho 2b0b13f21f Use ioconf for the module declarations. 2011-02-16 08:35:51 +00:00
jruoho b9f301d5a2 Convert the homegrown module declarations to use ioconf. 2011-02-16 08:19:56 +00:00
jruoho 7e0b5b7921 Add a skeleton driver for Asus EeePC acpiwmi(4) mappings. 2011-02-16 07:30:26 +00:00
jruoho 2e742e4a77 Reset the firmware waking vector on resume. Adapted from FreeBSD and Linux.
No functional change intended.
2011-02-15 20:24:11 +00:00
tsutsui b10df2f5e4 - make local functions static
- use aprint_normal(9) and variants
- misc KNF
2011-02-15 11:05:51 +00:00
jmcneill 1c1a1efa3c add AGP v3 support to agp_generic_enable from FreeBSD 2011-02-15 08:57:01 +00:00
jmcneill 64b8c01373 print AGP mode (v3/v2compat/v2) with aprint_debug instead of aprint_normal 2011-02-15 08:56:11 +00:00
macallan 30bc81416e don't muck with the LVDS_BLON bit 2011-02-15 04:06:43 +00:00
jruoho 23501c315c Fix small negligence mistake. 2011-02-14 18:51:44 +00:00
hannken 4005d75059 ibmhawk_set: No need to set states ENVSYS_SWARNxxx, sysmon will do it. 2011-02-14 14:15:25 +00:00
hannken 48c7d44313 Initial implementation of ibmhawk(4) driver for sensors behind the IBM Hawk
on-board Integrated Systems Management Processor found on some eServers.

Tested on an IBM eServer x335.
2011-02-14 08:50:38 +00:00
jmcneill 6943f257c7 switch back to polling rirb, this will have to be revisited 2011-02-13 17:49:12 +00:00
jakllsch 4038145d43 Turn on detachment for ixpide(4). 2011-02-13 16:21:05 +00:00
hannken a1f833f3ae The ServerWorks CSB5 smbus controller often times out and hangs until reboot.
Increase the delay between setting the command register and reading the
status register.  Reset the smbus controller if it has timed out.

Tested on an IBM eServer x335.
2011-02-13 11:20:12 +00:00
phx ecc6abab99 Determine BAR type with pci_mapreg_probe() instead of pci_mapreg_type(),
to skip unimplemented BARs.
Do not probe non-BAR registers (like subsystem id). This fixes potential
panics in pci_mem_find().
2011-02-13 11:00:58 +00:00
nonaka 367cc7689b use MMC_CSD_CSDVER_EXT_CSD. 2011-02-13 07:25:56 +00:00
nonaka 833f453410 - Don't switch MMC high-speed timing, if host controller isn't supported.
- Only check EXT_CSD STRUCTURE version when CSD version is 3.
- initialize width at sdmmc_function_alloc().
2011-02-13 06:43:51 +00:00
enami 3e0d3a901e Remove one of trailing whitespace which adds unnecessary difference
against netbsd-5 branch.
2011-02-13 06:17:35 +00:00
dholland 74af1ccafe fix typo (clean up the rx list on failure setting it up, not the tx list)
from openbsd -r1.75, mentioned by Alexander Nasonov in PR 42667
2011-02-13 05:51:24 +00:00
jakllsch ce3e66261a Treat unexpected command completions a little more like regular completions.
Slight chance this might prevent some occasional log spew trouble at shutdown
time.
2011-02-13 01:21:52 +00:00