ACPI: APEI: EINJ: Fix trigger actions
authorTony Luck <tony.luck@intel.com>
Thu, 3 Jul 2025 20:04:21 +0000 (13:04 -0700)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 7 Jul 2025 16:23:17 +0000 (18:23 +0200)
commitc8aea83c735ec5a853db495592a1b6b5e6db859b
tree11c276d003f35dd363b23aa34fe5a088893b3f5c
parent4734c8b46b901cff2feda8b82abc710b65dc31c1
ACPI: APEI: EINJ: Fix trigger actions

The trigger events are in BIOS memory immediately following the
acpi_einj_trigger structure. These were not copied to regular
kernel memory for use by apei_exec_ctx_init() so injections in
"notrigger=0" mode failed with a message like this:

  APEI: Invalid action table, unknown instruction type: 123

Fix by allocating a "table_size" block of memory and copying the whole
table for use in the rest of the trigger flow.

Fixes: 1a35c88302a3 ("ACPI: APEI: EINJ: Fix kernel test sparse warnings")
Reported-by: Yi1 Lai <yi1.lai@intel.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Link: https://patch.msgid.link/20250703200421.28012-1-tony.luck@intel.com
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/apei/einj-core.c