Re: [PATCH v2 1/5] watchdog: Return early in watchdog_hardlockup_check()
From: Petr Mladek
Date: Mon Mar 23 2026 - 12:22:41 EST
On Thu 2026-03-12 16:22:02, Mayank Rungta via B4 Relay wrote:
> From: Mayank Rungta <mrungta@xxxxxxxxxx>
>
> Invert the `is_hardlockup(cpu)` check in `watchdog_hardlockup_check()`
> to return early when a hardlockup is not detected. This flattens the
> main logic block, reducing the indentation level and making the code
> easier to read and maintain.
>
> This refactoring serves as a preparation patch for future hardlockup
> changes.
>
> Signed-off-by: Mayank Rungta <mrungta@xxxxxxxxxx>
LGTM:
Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>
Best Regards,
Petr