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

Re: [win-pv-devel] [PATCH] Recreate watch on resume from suspend



> -----Original Message-----
> From: win-pv-devel [mailto:win-pv-devel-bounces@xxxxxxxxxxxxxxxxxxxx] On
> Behalf Of Owen Smith
> Sent: 18 July 2016 12:51
> To: win-pv-devel@xxxxxxxxxxxxxxxxxxxx
> Cc: Owen Smith
> Subject: [win-pv-devel] [PATCH] Recreate watch on resume from suspend
> 
> Watches are flagged as inactive on the resume from suspend,
> and will only recieve the initial watch fire after a suspend.
> 
> Signed-off-by: Owen Smith <owen.smith@xxxxxxxxxx>

Acked-by: Paul Durrant <paul.durrant@xxxxxxxxxx>

> ---
>  src/xenagent/service.cpp | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/src/xenagent/service.cpp b/src/xenagent/service.cpp
> index 2633809..55dc8ca 100644
> --- a/src/xenagent/service.cpp
> +++ b/src/xenagent/service.cpp
> @@ -495,6 +495,12 @@ void CXenAgent::OnSuspend()
>      CXenAgent::Log("OnSuspend(%ws)\n", m_device->Path());
>      EventLog(EVENT_XENUSER_UNSUSPENDED);
> 
> +    // recreate shutdown watch, as suspending deactivated the watch
> +    if (m_ctxt_shutdown)
> +        m_device->StoreRemoveWatch(m_ctxt_shutdown);
> +    m_ctxt_shutdown = NULL;
> +
> +    m_device->StoreAddWatch("control/shutdown", m_evt_shutdown,
> &m_ctxt_shutdown);
>      m_device->StoreWrite("control/feature-shutdown", "1");
> 
>      SetXenTime();
> --
> 1.9.4.msysgit.1
> 
> 
> _______________________________________________
> win-pv-devel mailing list
> win-pv-devel@xxxxxxxxxxxxxxxxxxxx
> https://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel
_______________________________________________
win-pv-devel mailing list
win-pv-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.