Re: [PATCH v2] ACPI: scan: Avoid enumerating devices with clearly invalid _STA values

From: Sudeep Holla
Date: Tue Apr 30 2024 - 12:16:26 EST


On Tue, Apr 30, 2024 at 06:02:20PM +0200, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@xxxxxxxxx>
>
> The return value of _STA with the "present" bit unset and the "enabled"
> bit set is clearly invalid as per the ACPI specification, Section 6.3.7
> "_STA (Device Status)", so make the ACPI device enumeration code
> disregard devices with such _STA return values.
>
> Also, because this implies that status.enabled will only be set if
> status.present is set too, acpi_device_is_enabled() can be modified
> to simply return the value of the former.
>

Nice!

FWIW,

Reviewed-by: Sudeep Holla <sudeep.holla@xxxxxxx>

--
Regards,
Sudeep