Re: [Xen-devel] [PATCH 04/10] acpi: Power and Sleep ACPI buttons are not emulated

2016-11-07 Thread annie li



On 11/7/2016 10:38 AM, Konrad Rzeszutek Wilk wrote:

On Sun, Nov 06, 2016 at 04:42:37PM -0500, Boris Ostrovsky wrote:

.. for PVH guests. However, since emulating them for HVM guests
also doesn't seem useful we can have FADT disable those buttons
for both types of guests.

Wait, we need S3 suspend for HVM guests (think Windows without PV drivers)!
And I this is how we "inject" the event to the guest.

CC-ing Annie and Adnan who I believe had to do something like this
in old version of OVS, maybe they can recall more details.
Our winpv supports S4(hibernation) which will be tested by WHQL, and 
S3(Sleep) is optional(no real process for it yet).


Thanks
Annie

Signed-off-by: Boris Ostrovsky 
---
  tools/libacpi/static_tables.c | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/libacpi/static_tables.c b/tools/libacpi/static_tables.c
index 413abcc..ebe8ffe 100644
--- a/tools/libacpi/static_tables.c
+++ b/tools/libacpi/static_tables.c
@@ -61,7 +61,8 @@ struct acpi_20_fadt Fadt = {
  .flags = (ACPI_PROC_C1 |
ACPI_WBINVD |
ACPI_FIX_RTC | ACPI_TMR_VAL_EXT |
-  ACPI_USE_PLATFORM_CLOCK),
+  ACPI_USE_PLATFORM_CLOCK |
+  ACPI_PWR_BUTTON | ACPI_SLP_BUTTON),
  
  .reset_reg = {

  .address_space_id= ACPI_SYSTEM_IO,
--
2.7.4


___
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

___
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel



___
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel


Re: [Xen-devel] [PATCH 04/10] acpi: Power and Sleep ACPI buttons are not emulated

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 10:38 AM, Konrad Rzeszutek Wilk wrote:
> On Sun, Nov 06, 2016 at 04:42:37PM -0500, Boris Ostrovsky wrote:
>> .. for PVH guests. However, since emulating them for HVM guests
>> also doesn't seem useful we can have FADT disable those buttons
>> for both types of guests.
> Wait, we need S3 suspend for HVM guests (think Windows without PV drivers)!
> And I this is how we "inject" the event to the guest.
>
> CC-ing Annie and Adnan who I believe had to do something like this
> in old version of OVS, maybe they can recall more details.

Andrew has already requested that HVM guests keep their buttons so this
change will only be implemented for PVH guests.

-boris


___
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel


Re: [Xen-devel] [PATCH 04/10] acpi: Power and Sleep ACPI buttons are not emulated

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:37PM -0500, Boris Ostrovsky wrote:
> .. for PVH guests. However, since emulating them for HVM guests
> also doesn't seem useful we can have FADT disable those buttons
> for both types of guests.

Wait, we need S3 suspend for HVM guests (think Windows without PV drivers)!
And I this is how we "inject" the event to the guest.

CC-ing Annie and Adnan who I believe had to do something like this
in old version of OVS, maybe they can recall more details.
> 
> Signed-off-by: Boris Ostrovsky 
> ---
>  tools/libacpi/static_tables.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/libacpi/static_tables.c b/tools/libacpi/static_tables.c
> index 413abcc..ebe8ffe 100644
> --- a/tools/libacpi/static_tables.c
> +++ b/tools/libacpi/static_tables.c
> @@ -61,7 +61,8 @@ struct acpi_20_fadt Fadt = {
>  .flags = (ACPI_PROC_C1 |
>ACPI_WBINVD |
>ACPI_FIX_RTC | ACPI_TMR_VAL_EXT |
> -  ACPI_USE_PLATFORM_CLOCK),
> +  ACPI_USE_PLATFORM_CLOCK |
> +  ACPI_PWR_BUTTON | ACPI_SLP_BUTTON),
>  
>  .reset_reg = {
>  .address_space_id= ACPI_SYSTEM_IO,
> -- 
> 2.7.4
> 
> 
> ___
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> https://lists.xen.org/xen-devel

___
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel


[Xen-devel] [PATCH 04/10] acpi: Power and Sleep ACPI buttons are not emulated

2016-11-06 Thread Boris Ostrovsky
.. for PVH guests. However, since emulating them for HVM guests
also doesn't seem useful we can have FADT disable those buttons
for both types of guests.

Signed-off-by: Boris Ostrovsky 
---
 tools/libacpi/static_tables.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/libacpi/static_tables.c b/tools/libacpi/static_tables.c
index 413abcc..ebe8ffe 100644
--- a/tools/libacpi/static_tables.c
+++ b/tools/libacpi/static_tables.c
@@ -61,7 +61,8 @@ struct acpi_20_fadt Fadt = {
 .flags = (ACPI_PROC_C1 |
   ACPI_WBINVD |
   ACPI_FIX_RTC | ACPI_TMR_VAL_EXT |
-  ACPI_USE_PLATFORM_CLOCK),
+  ACPI_USE_PLATFORM_CLOCK |
+  ACPI_PWR_BUTTON | ACPI_SLP_BUTTON),
 
 .reset_reg = {
 .address_space_id= ACPI_SYSTEM_IO,
-- 
2.7.4


___
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel