Re: [PATCH 4/9] x86/mce: Move machine_check_poll() status checks to helper functions

Borislav Petkov
2024-08-01T13:04:38Z

On Fri, Jul 26, 2024 at 10:00:30AM -0400, Yazen Ghannam wrote:
> @@ -797,9 +797,11 @@ void machine_check_poll(enum mcp_flags flags, mce_banks_t *b)
> if (!mca_cfg.cmci_disabled)
> mce_track_storm(&m);
>
> - if (!log_poll_error(flags, &m, &status_reg))
> + /* Verify that the error should be logged based on hardware conditions. */
> + if (!loggable_poll_error(flags, &m, &status_reg))

Right, or do

if (!should_log_poll_error(...)

as it becomes maximally readable then - like a plain English sentence.

> continue;
>
> + /* Clear a loggable error, e.g., one leftover from boot time. */
> if (flags & MCP_DONTLOG)
> goto clear_it;

So yeah, I guess.

--
Regards/Gruss,
Boris.