Commit Graph

1314 Commits

Author SHA1 Message Date
msaitoh
287fff2eb1 If _ENABLED flag of ACPI_SRAT_TYPE_CPU_AFFINITY, ACPI_SRAT_TYPE_MEMORY_AFFINITY
or ACPI_SRAT_TYPE_X2APIC_CPU_AFFINITY isn't set, don't use the table.
2017-08-31 08:45:03 +00:00
chs
fd34ea77eb remove checks for failure after memory allocation calls that cannot fail:
kmem_alloc() with KM_SLEEP
  kmem_zalloc() with KM_SLEEP
  percpu_alloc()
  pserialize_create()
  psref_class_create()

all of these paths include an assertion that the allocation has not failed,
so callers should not assert that again.
2017-06-01 02:45:05 +00:00
riastradh
1cd9855036 Reassign my copyright to TNF. 2017-05-22 14:07:00 +00:00
jdolecek
6578d521a1 provide intr xname 2017-03-29 20:08:40 +00:00
tsutsui
5e4462d20d Remove extra newline during attach.
> acpiec0 at acpi0 (EC, PNP0C09)
> : io 0x62,0x66
> acpiec0: using global ACPI lock

acpi_resource_parse() with &acpi_resource_parse_ops_default prints
resouce info and newline.  Found and tested on ThinkPad X21.
2017-03-11 08:26:23 +00:00
nonaka
7003a76595 sdhc(4): hardware reset support for Intel eMMC controller 2017-02-17 10:51:48 +00:00
christos
2525631db5 implement new interfaces 2017-01-25 13:38:40 +00:00
jdolecek
9879797546 provide intr xname 2016-10-18 22:08:30 +00:00
nonaka
7a9bb565aa Dump more FADT fields from ACPI 6.1. 2016-10-14 11:11:01 +00:00
nonaka
21c1cf7d79 Enable DMA transfer. 2016-08-11 01:54:30 +00:00
msaitoh
b331f99208 KNF. No functional change. 2016-07-14 04:19:26 +00:00
hannken
2c5676121a According to "PCI Express Base Specification Revision 3.0" from
November 10, 2010, section 7.9.1 an Extended Capability header
with value 0:0:0 represents the absence of Extended Capabilities.
2016-07-12 09:45:34 +00:00
hannken
f0929e69c9 On an Intel E7520 temporarily disable Enhanced Config Access error
detection and reporting during bus scan.

Fixes PR kern/51251: ACPI device probe raises NMI
2016-07-12 09:29:32 +00:00
msaitoh
71fbb921c3 KNF. No functional change. 2016-07-11 11:31:49 +00:00
msaitoh
8bc54e5be6 KNF. Remove extra spaces. No functional change. 2016-07-07 06:55:38 +00:00
nonaka
110bebd9f8 remove unused variable. 2016-06-22 05:39:49 +00:00
nonaka
038e2d2d24 Add sdhc(4) at acpi support 2016-06-21 11:35:47 +00:00
nonaka
6af4cd3352 Pass bus_dma(9) tag to allow for porting sdhc(4) at acpi. 2016-06-21 11:33:32 +00:00
mlelstv
b956532246 Split toggles for bluetooth and wwan and use specific ACPI objects
where present.
Also make driver detach on shutdown.
2016-04-03 10:36:00 +00:00
mlelstv
a37e4625b5 Add comments. 2016-04-03 10:32:47 +00:00
riastradh
f2a2263adb Avoid reading one byte past end of array.
Fixes

   acpiout0: brightness levels: [20,25,30,35,40,45,50,55,60,65,70,75,80,85,90,uvm_fault(0xffffffff8133d200, 0xffff80000c1d8000, 1) -> e
   fatal page fault in supervisor mode
   trap type 6 code 0 rip ffffffff803b63d7 cs 8 rflags 10212 cr2 ffff80000c1d8000 ilevel 8 rsp ffffffff816a1b00
2016-02-18 15:42:44 +00:00
christos
7481a22a73 The new acpi code tries to read the pci configuration registers in the
acpi_probe() phase, before acpi_softc is allocated. Detect this and use
a NULL chipset handle instead of crashing.
2016-01-26 22:52:14 +00:00
joerg
7ed988494f Don't skip entries in the table, one increment per iteration is enough. 2016-01-15 15:42:57 +00:00
christos
81bd9c9c95 merge new acpica 2016-01-09 21:14:12 +00:00
christos
e453ad6414 PR/50626: Vicente Chaves de Melo: acpi_display.c erroneously sends character
to console during boot
2016-01-06 01:37:17 +00:00
christos
25babac1be add missing debugging attributes 2015-10-11 21:49:22 +00:00
christos
2a1508e4be Previous code was mis-indented but correct; simplify to make the intent clear. 2015-10-05 15:57:50 +00:00
msaitoh
605f564f52 PCI Extended Configuration stuff written by nonaka@:
- Add PCI Extended Configuration Space support into x86.
- Check register offset of pci_conf_read() in MD part. It returns (pcireg_t)-1
  if it isn't accessible.
- Decode Extended Capability in PCI Extended Configuration Space.
  Currently the following extended capabilities are decoded:
   - Advanced Error Reporting
   - Virtual Channel
   - Device Serial Number
   - Power Budgeting
   - Root Complex Link Declaration
   - Root Complex Event Collector Association
   - Access Control Services
   - Alternative Routing-ID Interpretation
   - Address Translation Services
   - Single Root IO Virtualization
   - Page Request
   - TPH Requester
   - Latency Tolerance Reporting
   - Secondary PCI Express
   - Process Address Space ID
   - LN Requester
   - L1 PM Substates
  The following extended capabilities are not decoded yet:
   - Root Complex Internal Link Control
   - Multi-Function Virtual Channel
   - RCRB Header
   - Vendor Unique
   - Configuration Access Correction
   - Multiple Root IO Virtualization
   - Multicast
   - Resizable BAR
   - Dynamic Power Allocation
   - Protocol Multiplexing
   - Downstream Port Containment
   - Precision Time Management
   - M-PCIe
   - Function Reading Status Queueing
   - Readiness Time Reporting
   - Designated Vendor-Specific
2015-10-02 05:22:49 +00:00
christos
fae14d9262 CID 1324963: Remove bogus NULL test
CID 1324962: This is not python, one needs braces too.
2015-09-26 13:04:10 +00:00
nonaka
ac3789be33 PR/50261: Added newer Toshiba hotkeys support. 2015-09-21 12:32:06 +00:00
christos
f8d654da70 add extra argument to method. 2015-08-18 10:41:28 +00:00
msaitoh
53b3110f9e Add ACPI_RESOURCE_TYPE_END_TAG and ACPI_RESOURCE_TYPE_ADDRESS64. 2015-07-27 04:50:50 +00:00
pgoyette
76a2f91a0e Update module dependencies for all the existing modules that depend on sysmon components. 2015-04-23 23:23:00 +00:00
christos
6252065cbb sync with new acpica struct shuffling. 2015-04-13 18:32:50 +00:00
riastradh
233f556c2e Convert sys/dev to use <sys/rndsource.h>. 2015-04-13 16:33:23 +00:00
mlelstv
bbcc69a643 handle unknown values. Also BIF_UNIT is an enum, not a bitmask. 2014-12-31 22:01:01 +00:00
msaitoh
c61278b1af Add missing newlines... 2014-12-08 16:16:45 +00:00
christos
ddfebefe71 adjust for newer acpica 2014-10-25 21:00:20 +00:00
christos
99e45faf20 summarize levels instead of printing dozens of them. 2014-10-14 19:50:57 +00:00
riastradh
68275ddbde Don't kdassert about crap provided by the firmware. 2014-10-02 12:42:12 +00:00
mrg
a4412a693b introduce a new option: ACPI__DIS_IS_BROKEN. this is a hack to
avoid calling the "_DIS" method during acpi interrupt link setup,
which hangs various nforce4 based motherboards.

when the problem is properly fixed, remove this hack.  for now,
it allows someone (me) to have a valid kernel config that doesn't
require a source hack every new tree.

ok chs@
2014-09-14 19:54:05 +00:00
riastradh
12a0c4d516 Register a null power handler if acpiec fails to attach.
On one of my machines, there's no _GPE method, so
acpiec_parse_gpe_package fails, and the only function acpiec(4)
serves is to inhibit suspend/resume.

XXX We should really put the power handlers in the cfattach so that
it's not necessary to register a null power handler in every error
branch of every device's attach routine...
2014-07-06 15:35:42 +00:00
jakllsch
89097d7fef don't run off the end of the source resource buffer 2014-04-14 01:56:18 +00:00
riastradh
f58fb90d2f Fix unused variable warning in non-modular apple_smc build. 2014-04-01 17:49:40 +00:00
riastradh
9456e37730 Rework Apple SMC attachment goo and split into multiple modules.
The four modules are apple_smc for the core functions, apple_smc_acpi
for attachment at acpi, and apple_smc_fan & apple_smc_temp for stuff
on the SMC.

Seems like there's a lot more bookkeeping necessary to maintain
children of an applesmc device implemented by loadable modules.
Maybe there's a better way I just haven't figured out yet.
2014-04-01 17:48:39 +00:00
riastradh
0396c57641 First draft of drivers for the Apple System Management Controller.
Device interface derived by reading the Linux driver source code and
<http:///www.parhelia.ch/blog/statics/k3_keys.html> as of 2012-12-05.

Includes support for attaching fan and temperature sensors to sysmon.
No accelerometer yet.

Compile-tested only, based on some run-testing of experiments from
userland.  Module attachment is not quite finished, so it won't work
yet.
2014-04-01 17:47:36 +00:00
maxv
38b6f18cc1 Some {} are missing. The behavior is thus wrong: the code always jumps to
out1.

Spotted by my code scanner.

ok christos@
2014-03-01 16:59:41 +00:00
pooka
4f6fb3bf35 Ensure that the top level sysctl nodes (kern, vfs, net, ...) exist before
the sysctl link sets are processed, and remove redundancy.

Shaves >13kB off of an amd64 GENERIC, not to mention >1k duplicate
lines of code.
2014-02-25 18:30:08 +00:00
christos
f5fe8e85e2 fix unused 2014-01-25 21:11:20 +00:00
apb
b29660a1ad + Please also update ACPI_DATE in include/acapps.h. 2014-01-18 09:51:08 +00:00