Skip to content

RFC ACPICA: Tables: Add deferred verification support

Lv Zheng acpica-devel linux-acpi 3 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 RFC Latest5 patches 0 repliesNew
  2. v2 RFC5 patches 3 repliesSuperseded
  3. v1 RFC7 patches 5 repliesSuperseded

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5ACPICA: Tables: Cleanup table handler invokersdrivers/acpi/acpica/actables.h drivers/acpi/acpica/tbdata.c drivers/acpi/acpica/tbinstal.c+33 -200 replies
2/5ACPICA: Tables: Do not validate signature for dynamic table loaddrivers/acpi/acpica/tbinstal.c drivers/acpi/acpica/tbxfload.c+1 -290 replies
3/5ACPICA: Tables: Change table duplication check to be related to acpi_gbl_verify_table_checksumdrivers/acpi/acpica/tbdata.c drivers/acpi/acpica/tbinstal.c drivers/acpi/acpica/tbxface.c +3 more+21 -150 replies
4/5ACPICA: Tables: Combine checksum/duplication verification togetherdrivers/acpi/acpica/actables.h drivers/acpi/acpica/tbdata.c drivers/acpi/acpica/tbinstal.c+169 -1100 replies
5/5ACPICA: Tables: Add deferred table verification supportdrivers/acpi/acpica/tbdata.c drivers/acpi/acpica/tbxface.c include/acpi/actbl.h+48 -100 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.

Read the v3 thread

Cover letter [Devel] [RFC PATCH v3 0/5] ACPICA: Tables: Add deferred verification support

On linux, we can not verify ACPI tables before installing them into the global table list in early stage due to the number of slot limitations for early ioremap. This leaves a problem that we cannot detect duplicated tables in early stage, causing unwanted error messages seen when the duplicated tables are failed to be loaded [link #1].

This patchset as ACPICA PR [link #2] adds support to verify tables in acpi_reallocate_root_tables() which is invoked after installing tables in early stage, being ready for late ioremap and beofre loading table in late stage. If duplicated tables are detected, acpi_reallocate_root_tables() stops installing them to the final reallocated global table list.

In v1 patchset [link #3], problems can be seen for dynamic loading tables which are allocated as virtuall allocated tables. Such tables are incremented in the global table list as the sanity check done in install step only compares the table addresses while the virtual allocated addresses are not stable.
In v2 patchset, we follow original design discussion made in ACPICA devel mailing list, implements deferred table verification so that duplicate tables are still can be detected in install step rather than in load step. Also we removed table signature check according to verified windows behavior [link #4] and reported issues [link #5].
In v3 patchset, one serious problem is detected around returning AE_CTRL_TERMINATE for duplicate tables. The problem is detected by ASLTS. Also it contains small improvements. ACPICA pull request [link #2] is also updated.

      https://bugzilla.kernel.org/show_bug.cgi?id=118601    [#5]

Lv Zheng (5):
ACPICA: Tables: Cleanup table handler invokers
ACPICA: Tables: Do not validate signature for dynamic table load
ACPICA: Tables: Change table duplication check to be related to
acpi_gbl_verify_table_checksum
ACPICA: Tables: Combine checksum/duplication verification together
ACPICA: Tables: Add deferred table verification support

 drivers/acpi/acpica/actables.h |   5 +-
 drivers/acpi/acpica/tbdata.c   | 228 ++++++++++++++++++++++++++++++++++++-----
 drivers/acpi/acpica/tbinstal.c | 161 ++++-------------------------
 drivers/acpi/acpica/tbxface.c  |  33 +++++-
 drivers/acpi/acpica/tbxfload.c |   2 +-
 drivers/acpi/bus.c             |   3 -
 drivers/acpi/tables.c          |   4 +-
 include/acpi/acpixf.h          |  15 +--
 include/acpi/actbl.h           |   1 +
 9 files changed, 270 insertions(+), 182 deletions(-)
Signature · 1 line
2.7.4