Mauro Carvalho Chehab
4cc103081b
scripts/ghes_inject: add a script to generate GHES error inject
Using the QMP GHESv2 API requires preparing a raw data array
containing a CPER record.
Add a helper script with subcommands to prepare such data.
Currently, only ARM Processor error CPER record is supported, by
using:
$ ghes_inject.py arm
which produces those warnings on Linux:
[ 705.032426] [Firmware Warn]: GHES: Unhandled processor error type 0x02: cache error
[ 774.866308] {4}[Hardware Error]: Hardware error from APEI Generic Hardware Error Source: 1
[ 774.866583] {4}[Hardware Error]: event severity: recoverable
[ 774.866738] {4}[Hardware Error]: Error 0, type: recoverable
[ 774.866889] {4}[Hardware Error]: section_type: ARM processor error
[ 774.867048] {4}[Hardware Error]: MIDR: 0x00000000000f0510
[ 774.867189] {4}[Hardware Error]: running state: 0x0
[ 774.867321] {4}[Hardware Error]: Power State Coordination Interface state: 0
[ 774.867511] {4}[Hardware Error]: Error info structure 0:
[ 774.867679] {4}[Hardware Error]: num errors: 2
[ 774.867801] {4}[Hardware Error]: error_type: 0x02: cache error
[ 774.867962] {4}[Hardware Error]: error_info: 0x000000000091000f
[ 774.868124] {4}[Hardware Error]: transaction type: Data Access
[ 774.868280] {4}[Hardware Error]: cache error, operation type: Data write
[ 774.868465] {4}[Hardware Error]: cache level: 2
[ 774.868592] {4}[Hardware Error]: processor context not corrupted
[ 774.868774] [Firmware Warn]: GHES: Unhandled processor error type 0x02: cache error
Such script allows customizing the error data, allowing to change
all fields at the record. Please use:
$ ghes_inject.py arm -h
For more details about its usage.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Message-ID: <5ea174638e33d23635332fa6d4ae9d751355f127.1758610789.git.mchehab+huawei@kernel.org>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2025-10-05 08:17:08 -04:00
..
2025-09-30 19:33:25 +04:00
2025-04-25 17:00:41 +02:00
2025-09-02 17:57:05 +02:00
2025-08-30 16:37:23 +01:00
2025-10-01 11:22:07 -04:00
2025-10-01 11:22:07 -04:00
2025-10-01 11:22:07 -04:00
2025-06-03 22:42:18 +02:00
2025-10-01 11:22:07 -04:00
2025-10-01 11:22:07 -04:00
2025-04-23 14:08:21 -07:00
2025-09-30 19:33:25 +04:00
2025-10-05 08:17:08 -04:00
2025-09-26 09:55:19 +01:00
2025-07-25 10:31:45 +01:00
2025-06-26 00:42:37 +02:00
2025-07-25 14:51:05 +02:00
2025-10-05 08:17:08 -04:00
2025-08-30 16:37:23 +01:00
2025-09-22 17:17:18 +02:00
2025-08-05 16:27:25 -03:00
2025-08-20 22:47:54 +02:00
2025-10-01 11:22:07 -04:00
2025-10-01 11:22:07 -04:00
2025-04-13 13:45:41 +03:00
2025-10-01 11:22:07 -04:00
2025-10-01 11:22:07 -04:00
2025-10-05 08:17:08 -04:00
2025-05-20 11:26:32 -04:00
2025-10-01 11:22:07 -04:00
2025-09-30 19:33:25 +04:00
2025-09-30 19:33:25 +04:00
2025-10-01 11:22:07 -04:00
2025-10-04 10:50:37 -04:00
2025-09-16 17:31:53 +01:00
2025-05-20 11:26:32 -04:00