linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] pvpanic: handle missing _STA correctly
@ 2015-05-29 20:18 Radim Krčmář
  2015-06-01  7:33 ` Igor Mammedov
  0 siblings, 1 reply; 3+ messages in thread
From: Radim Krčmář @ 2015-05-29 20:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: Darren Hart, platform-driver-x86, Igor Mammedov

pvpanic was not properly detected when _STA was missing.

ACPI 6.0 April 2015, 6.3.7 _STA (Status)
  If a device object (including the processor object) does not have an
  _STA object, then OSPM assumes that all of the above bits are set
  (i.e., the device is present, enabled, shown in the UI, and
  functioning).

Not adhering to the specification made pvpanic dormant under QEMU 2.3.

Suggested-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
---
 drivers/platform/x86/pvpanic.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/platform/x86/pvpanic.c b/drivers/platform/x86/pvpanic.c
index 073a90a63dbc..7b6860333267 100644
--- a/drivers/platform/x86/pvpanic.c
+++ b/drivers/platform/x86/pvpanic.c
@@ -95,8 +95,7 @@ static int pvpanic_add(struct acpi_device *device)
 	acpi_status status;
 	u64 ret;
 
-	status = acpi_evaluate_integer(device->handle, "_STA", NULL,
-				       &ret);
+	status = acpi_bus_get_status_handle(device->handle, &ret);
 
 	if (ACPI_FAILURE(status) || (ret & 0x0B) != 0x0B)
 		return -ENODEV;
-- 
2.4.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] pvpanic: handle missing _STA correctly
  2015-05-29 20:18 [PATCH] pvpanic: handle missing _STA correctly Radim Krčmář
@ 2015-06-01  7:33 ` Igor Mammedov
  2015-06-01 17:38   ` [PATCH] pvpanic: handle missing _STA correctly' Darren Hart
  0 siblings, 1 reply; 3+ messages in thread
From: Igor Mammedov @ 2015-06-01  7:33 UTC (permalink / raw)
  To: Radim Krčmář
  Cc: linux-kernel, Darren Hart, platform-driver-x86

On Fri, 29 May 2015 22:18:52 +0200
Radim Krčmář <rkrcmar@redhat.com> wrote:

> pvpanic was not properly detected when _STA was missing.
> 
> ACPI 6.0 April 2015, 6.3.7 _STA (Status)
>   If a device object (including the processor object) does not have an
>   _STA object, then OSPM assumes that all of the above bits are set
>   (i.e., the device is present, enabled, shown in the UI, and
>   functioning).
> 
> Not adhering to the specification made pvpanic dormant under QEMU 2.3.
> 
> Suggested-by: Igor Mammedov <imammedo@redhat.com>
> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>

> ---
>  drivers/platform/x86/pvpanic.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/platform/x86/pvpanic.c b/drivers/platform/x86/pvpanic.c
> index 073a90a63dbc..7b6860333267 100644
> --- a/drivers/platform/x86/pvpanic.c
> +++ b/drivers/platform/x86/pvpanic.c
> @@ -95,8 +95,7 @@ static int pvpanic_add(struct acpi_device *device)
>  	acpi_status status;
>  	u64 ret;
>  
> -	status = acpi_evaluate_integer(device->handle, "_STA", NULL,
> -				       &ret);
> +	status = acpi_bus_get_status_handle(device->handle, &ret);
>  
>  	if (ACPI_FAILURE(status) || (ret & 0x0B) != 0x0B)
>  		return -ENODEV;


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] pvpanic: handle missing _STA correctly'
  2015-06-01  7:33 ` Igor Mammedov
@ 2015-06-01 17:38   ` Darren Hart
  0 siblings, 0 replies; 3+ messages in thread
From: Darren Hart @ 2015-06-01 17:38 UTC (permalink / raw)
  To: Igor Mammedov
  Cc: Radim Krčmář, linux-kernel, platform-driver-x86

On Mon, Jun 01, 2015 at 09:33:22AM +0200, Igor Mammedov wrote:
> On Fri, 29 May 2015 22:18:52 +0200
> Radim Krčmář <rkrcmar@redhat.com> wrote:
> 
> > pvpanic was not properly detected when _STA was missing.
> > 
> > ACPI 6.0 April 2015, 6.3.7 _STA (Status)
> >   If a device object (including the processor object) does not have an
> >   _STA object, then OSPM assumes that all of the above bits are set
> >   (i.e., the device is present, enabled, shown in the UI, and
> >   functioning).
> > 
> > Not adhering to the specification made pvpanic dormant under QEMU 2.3.
> > 
> > Suggested-by: Igor Mammedov <imammedo@redhat.com>
> > Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
> Reviewed-by: Igor Mammedov <imammedo@redhat.com>

Queued, thanks.

-- 
Darren Hart
Intel Open Source Technology Center

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-06-01 17:38 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-29 20:18 [PATCH] pvpanic: handle missing _STA correctly Radim Krčmář
2015-06-01  7:33 ` Igor Mammedov
2015-06-01 17:38   ` [PATCH] pvpanic: handle missing _STA correctly' Darren Hart

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).