Re: [PATCHv6 16/16] x86/acpi: Add support for CPU offlining for ACPI MADT wakeup method

From: Kirill A. Shutemov
Date: Sat Jan 27 2024 - 14:35:55 EST


On Fri, Jan 26, 2024 at 12:03:14PM -0800, Kuppuswamy Sathyanarayanan wrote:
> > + /* Don't wait longer than a second. */
> > + timeout = USEC_PER_SEC;
> > + while (READ_ONCE(acpi_mp_wake_mailbox->command) && --timeout)
> > + udelay(1);
> > +
> > + if (!timeout)
> Nit: IMO, since you are dumping failure error message (not timeout
> message), you can use non zero acpi_mp_wake_mailbox->command
> check. But it is up to you.

I think my version is pretty idiomatic. The same pattern used in other
places. For instance, test_nmi_ipi().
--
Kiryl Shutsemau / Kirill A. Shutemov