Re: [PATCH] acpi: fix regression on D3hot detection

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tuesday, May 15, 2012, Lekensteyn wrote:
> Commit 1cc0c998fdf2cb665d625fb565a0d6db5c81c639 tried clear up some confusion
> around D3hot and D3cold but accidentally changed behaviour on validating device
> power states. It added an extra condition: i < ACPI_STATE_D3_HOT which means
> that only states D0, D1 and D2 are accepted if there are no power resources but
> the _PSx method exist. D3(hot) is missing here.

Which is intentional (that follows from the ACPI spec.).

> This fixes https://bugzilla.kernel.org/show_bug.cgi?id=43228

I'll have a look at the bug later.

Thanks,
Rafael


> Reported-by: rockorequin@xxxxxxxxxxx
> Signed-off-by: Peter Lekensteyn <lekensteyn@xxxxxxxxx>
> Tested-by: rockorequin@xxxxxxxxxxx
> ---
>  drivers/acpi/scan.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/acpi/scan.c b/drivers/acpi/scan.c
> index 7417267..932c427 100644
> --- a/drivers/acpi/scan.c
> +++ b/drivers/acpi/scan.c
> @@ -895,7 +895,7 @@ static int acpi_bus_get_power_flags(struct acpi_device *device)
>  		 * D3hot is only valid if _PR3 present.
>  		 */
>  		if (ps->resources.count ||
> -		    (ps->flags.explicit_set && i < ACPI_STATE_D3_HOT))
> +		    (ps->flags.explicit_set && i <= ACPI_STATE_D3_HOT))
>  			ps->flags.valid = 1;
>  
>  		ps->power = -1;	/* Unknown - driver assigned */
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux