Commit Graph

127 Commits

Author SHA1 Message Date
Alexander Motin
ebc22d0495 Decode APEI tables (BERT, EINJ, ERST, HEST).
MFC after:	2 weeks
2020-06-30 21:40:34 +00:00
Andrew Turner
bc71118183 Allow the FACS and XFACS to be zero in acpidump.
These are allowed to be zero when the hardware reduced APCI flag is set

Sponsored by:	Innovate UK
Differential Revision:	https://reviews.freebsd.org/D23207
2020-05-18 15:05:59 +00:00
Jung-uk Kim
278f0de60d Merge ACPICA 20190329. 2019-03-29 20:21:28 +00:00
Cy Schubert
7aef71382b Fix 32-bit buildworld broken by r343438. 2019-01-25 20:53:29 +00:00
Takanori Watanabe
877fc2e350 Use ACPI TPM2 table to probe tpmtis and tpmcrb device.
Differential Revision: https://reviews.freebsd.org/D18937
2019-01-25 16:16:10 +00:00
Ben Widawsky
5857fba5fd acpidump(8): Add ACPI LPIT (Low Power Idle Table)
The LPIT is the part of the "standardized" way that one can enumerate
various power state information on Intel platforms.

The documentation for this change can be found here:
http://www.uefi.org/sites/default/files/resources/Intel_ACPI_Low_Power_S0_Idle.pdf

Reviewed By: jhb
Approved By: jhb
Differential Revision: https://reviews.freebsd.org/D15931
2018-07-11 01:37:01 +00:00
Ed Maste
75e6ea22c5 acpidump.8: include NFIT in the man page list of tables
Was missed in r321298.

Reported by:	Ben Widawsky (in review D15931)
MFC after:	1 week
2018-06-20 19:40:54 +00:00
Pedro F. Giffuni
1de7b4b805 various: general adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.

No functional change intended.
2017-11-27 15:37:16 +00:00
Bryan Drewery
ea825d0274 DIRDEPS_BUILD: Update dependencies.
Sponsored by:	Dell EMC Isilon
2017-10-31 00:07:04 +00:00
Scott Long
ed26c389bf Add support for parsing the Watchdog Descriptor Table (WDDT)
Sponsored by:	Netflix
2017-09-15 15:41:07 +00:00
Alexander Motin
d4c2de2e0b Fix flags field decoding in ACPI_NFIT_CONTROL_REGION.
It looked like incomplete copy/paste, printing absolute garbage.

While there, print ValidFields field ax hex, since it is a bitmask.

MFC after:	3 days
2017-08-31 09:08:06 +00:00
Alexander Motin
fb1cf2a9e5 Add two NFIT fields missed in r321298.
MFC after:	2 weeks
2017-08-10 10:59:05 +00:00
Ed Maste
cebb7b191c acpidump: add GIC ITS srat type
From ACPI 6.2, 5.2.16.5

MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
2017-07-20 17:36:17 +00:00
Ed Maste
340c00225f acpidump: add ACPI NFIT (NVDIMM Firmware Interface Table)
Submitted by:	Guangyuan Yang <yzgyyang@outlook.com>
MFC after:	3 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D11479
2017-07-20 17:31:27 +00:00
Ed Maste
27941afae6 acpidump: use C99 designated initializers
Submitted by:	Guangyuan Yang <yzgyyang@outlook.com>
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D11659
2017-07-20 15:52:36 +00:00
Ed Maste
f5d0a8f7c7 acpidump: warn and exit loop on invalid subtable length
Submitted by:	Guangyuan Yang <yzgyyang@outlook.com>
Sponsored by:	The FreeBSD Foundation
2017-07-06 14:35:47 +00:00
Marcelo Araujo
c86932b61b Use nitems() from sys/param.h.
Reviewed by:	ngie
MFC after:	3 weeks.
Differential Revision:	https://reviews.freebsd.org/D9940
2017-03-10 06:25:54 +00:00
Andrew Turner
2b2b1f42b9 Teach acpidump how to parse ACPI 5.1 tables found on the development
ThunderX units in the netperf cluster.

Approved by:	jkim
Obtained from:	ABT Systems Ltd
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D7252
2016-09-06 10:13:49 +00:00
Maxim Konovalov
30bebccae0 o Move tmpstr varibale initialization out of assert(3) call.
This fixes acpidump(8) compiled with "WITHOUT_ASSERT_DEBUG=yes" that
removes assert(3)'s from the code.

Submitted by:	Alexander Nedotsukov
2016-08-12 08:16:35 +00:00
Andrew Turner
f6469ce13a Add missing flags from acpidump. These are defined in the header, but not
printed. The HW_REDUCED flag is useful as it should be set on arm64 to
comply with the ARM Server Base Boot Requirements.

Obtained from:	ABT Systems Ltd
MFC after:	1 month
Sponsored by:	The FreeBSD Foundation
2016-07-19 16:02:07 +00:00
Andrew Turner
5ff4e2400d Fix the type used to hold the value returned from getopt. On arm64 char is
unsigned so will never be -1.

Obtained from:	ABT Systems Ltd
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
2016-07-13 22:53:30 +00:00
Don Lewis
7e2cc014bd Fix acpidump CID 1011278 (Buffer not null terminated) and other issues
Coverity reports that a buffer used for temporary file generation
might not be NUL terminated by strncpy().  This is probably not
true because the input gets passed through realpath(), but if the
path name is sufficiently long the name could be truncated and cause
other problems.  The code for generating the temp file names is
also overly complex.  Instead of a bunch of calls to strncpy() and
and strncat(), simplify the code by using snprintf() and add checks
for unexpected truncation.

The output file created by iasl -d is predictable.  Fix this by
using  mkdtemp() to create a directory to hold the iasl input and
output files.

Check the return values of more syscalls.

Reported by:	Coverity
CID:		1011278
Reviewed by:	jkim
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D6360
2016-05-24 23:36:43 +00:00
Simon J. Gerraty
ccfb965433 Add META_MODE support.
Off by default, build behaves normally.
WITH_META_MODE we get auto objdir creation, the ability to
start build from anywhere in the tree.

Still need to add real targets under targets/ to build packages.

Differential Revision:       D2796
Reviewed by: brooks imp
2015-06-13 19:20:56 +00:00
Simon J. Gerraty
44d314f704 dirdeps.mk now sets DEP_RELDIR 2015-06-08 23:35:17 +00:00
Simon J. Gerraty
98e0ffaefb Merge sync of head 2015-05-27 01:19:58 +00:00
Jung-uk Kim
7d369c6e2f Print 64-bit addresses cleary with leading zeros to avoid confusions.
MFC after:	1 week
2015-04-09 21:32:40 +00:00
Jung-uk Kim
fe1d0c2dae Do not crash when RSDT/XSDT contains an empty entry.
Reported by:	Slawa Olhovchenkov <slw@zxy.spb.ru>
MFC after:	3 days
2015-04-09 21:26:23 +00:00
Simon J. Gerraty
9268022b74 Merge from head@274682 2014-11-19 01:07:58 +00:00
Jung-uk Kim
313a0c13ef Merge ACPICA 20140926. 2014-10-02 19:11:18 +00:00
Simon J. Gerraty
ee7b0571c2 Merge head from 7/28 2014-08-19 06:50:54 +00:00
Baptiste Daroussin
01c2b8ac0d use .Mt to mark up email addresses consistently (part2)
PR:		191174
Submitted by:	Franco Fichtner  <franco@lastsummer.de>
2014-06-20 09:57:27 +00:00
Simon J. Gerraty
fae50821ae Updated dependencies 2014-05-16 14:09:51 +00:00
Simon J. Gerraty
76b28ad6ab Updated dependencies 2014-05-10 05:16:28 +00:00
Simon J. Gerraty
3b8f084595 Merge head 2014-04-28 07:50:45 +00:00
Neel Natu
9785e97901 Teach acpidump(8) to display the 'Flags' field in the HPET Description Table.
Reviewed by:	jhb@
2013-11-22 18:53:54 +00:00
Simon J. Gerraty
d1d0158641 Merge from head 2013-09-05 20:18:59 +00:00
Jung-uk Kim
0c10b85a19 Consistently cast ACPICA 64-bit integer types when we print them. 2013-06-26 23:52:10 +00:00
Jung-uk Kim
a9c007f1f2 Fix a long standing logic bug introduced in r167814. The code was added to
get RSDP from loader(8) hint via kenv(2) but the bug nullified the new code
and we always fell back to the previous method, i. e., sysctlbyname(3).

MFC after:	3 days
2013-05-31 17:23:38 +00:00
Simon J. Gerraty
7cf3a1c6b2 Updated dependencies 2013-03-11 17:21:52 +00:00
Simon J. Gerraty
f5f7c05209 Updated dependencies 2013-02-16 01:23:54 +00:00
David E. O'Brien
d9a447559b Sync with HEAD. 2013-02-08 16:10:16 +00:00
Neel Natu
ec6509897a Teach acpidump to dump the DMA Remapping Reporting table (aka DMAR).
The DMAR table is documented in chapter 8 of the Intel VT-d specification.

Reviewed by:	jhb
Obtained from:	NetApp
2012-12-21 01:19:48 +00:00
Simon J. Gerraty
23090366f7 Sync from head 2012-11-04 02:52:03 +00:00
Ed Schouten
bf70becee6 More -Wmissing-variable-declarations fixes.
In addition to adding `static' where possible:

- bin/date: Move `retval' into extern.h to make it visible to date.c.
- bin/ed: Move globally used variables into ed.h.
- sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings.
- usr.bin/calendar: Remove unneeded variables.
- usr.bin/chat: Make `line' local instead of global.
- usr.bin/elfdump: Comment out unneeded function.
- usr.bin/rlogin: Use _Noreturn instead of __dead2.
- usr.bin/tset: Pull `Ospeed' into extern.h.
- usr.sbin/mfiutil: Put global variables in mfiutil.h.
- usr.sbin/pkg: Remove unused `os_corres'.
- usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.
2012-10-19 14:49:42 +00:00
John Baldwin
338666582f Display the matrix of inter-domain distances in the SLIT table. This is
used to complement the SRAT table on NUMA machines.

MFC after:	1 week
2012-10-04 20:00:32 +00:00
Marcel Moolenaar
7750ad47a9 Sync FreeBSD's bmake branch with Juniper's internal bmake branch.
Requested by: Simon Gerraty <sjg@juniper.net>
2012-08-22 19:25:57 +00:00
Takanori Watanabe
2ef23c6d3b Add range and table revision checking to avoid abend.
PR:bin/169707
Submitted by:Dan Lukes <dan@obluda.cz>
MFC after:3 days.
2012-07-09 09:38:53 +00:00
Jung-uk Kim
d6a6e5902f Catch up with realpath(3) changes (r235266) and unbreak acpidump(8). 2012-05-25 00:18:19 +00:00
Takanori Watanabe
977fd9da57 use uintmax_t instead of uint64_t.
Pointed out by: des.
2010-08-13 09:58:17 +00:00
Takanori Watanabe
0e1982f4df Fix build on amd64 and ia64. 2010-08-13 00:45:30 +00:00