Re: [PATCH v1 09/19] ACPI: extlog: Report errors independently of RAS consumers

From: Jonathan Cameron

Date: Wed Nov 18 2026 - 14:45:28 EST


On Tue, 17 Nov 2026 12:10:19 +0100
Pierre Gondois <pierre.gondois@xxxxxxx> wrote:

> The RAS consumer check removes:
> - trace events when no daemon is registered
> - CPER console report when one is registered
> This ties tracing, PCIe recovery and CXL protocol delivery to daemon
> registration, and can hide a fatal record when userspace cannot process
> its trace event before a reset.
>
> Remove the RAS consumer registration condition and:
> - always emit trace events
> - print the CPER record only for CPER_SEV_FATAL
>
> [1] additionally suggested to have a cmdline parameter to dynamically
> update the above policy. Keep a simple hard coded policy for now.
>
> [1]
> https://lore.kernel.org/lkml/20240521183913.GGZkzqUSN1hdE-_OEY@fat_crate.local/

Use a link tag probably.

Link: https://lore.kernel.org/lkml/20240521183913.GGZkzqUSN1hdE-_OEY@fat_crate.local/ #1

I'm not entirely convinced this is a good idea without the policy aspect.
Still let us see what others think.

>
> Signed-off-by: Pierre Gondois <pierre.gondois@xxxxxxx>
> ---
> drivers/acpi/acpi_extlog.c | 6 ++----
> 1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/acpi/acpi_extlog.c b/drivers/acpi/acpi_extlog.c
> index e09ea571c32f5..16a16b12d8ccf 100644
> --- a/drivers/acpi/acpi_extlog.c
> +++ b/drivers/acpi/acpi_extlog.c
> @@ -208,10 +208,9 @@ static int extlog_print(struct notifier_block *nb, unsigned long val,
> if (cper_estatus_len(tmp) > ELOG_ENTRY_LEN || cper_estatus_check(tmp))
> return NOTIFY_DONE;
>
> - if (!ras_userspace_consumers()) {
> + /* Print fatal records regardless of RAS consumer registration. */
> + if (tmp->error_severity == CPER_SEV_FATAL)
> print_extlog_rcd(NULL, tmp, cpu);
> - goto out;
> - }
>
> /* log event via trace */
> err_seq++;
> @@ -255,7 +254,6 @@ static int extlog_print(struct notifier_block *nb, unsigned long val,
> }
> }
>
> -out:
> mce->kflags |= MCE_HANDLED_EXTLOG;
> return NOTIFY_OK;
> }