xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Wait the state Connect of the frontend before connect the backend.
@ 2010-05-17 17:18 anthony.perard
  2010-05-17 17:56 ` Jeremy Fitzhardinge
  2010-05-20 21:24 ` Jeremy Fitzhardinge
  0 siblings, 2 replies; 4+ messages in thread
From: anthony.perard @ 2010-05-17 17:18 UTC (permalink / raw)
  To: xen-devel; +Cc: Anthony PERARD

From: Anthony PERARD <anthony.perard@citrix.com>

The frontend of the framebuffer set a value (request-abs-pointer) and go
to the state Connected.  The backend must read this value only when the
frontend has the state Connected.
---
 hw/xen_backend.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/hw/xen_backend.c b/hw/xen_backend.c
index 76d07ec..31ed7b0 100644
--- a/hw/xen_backend.c
+++ b/hw/xen_backend.c
@@ -411,8 +411,7 @@ static int xen_be_try_connect(struct XenDevice *xendev)
 {
     int rc = 0;
 
-    if (xendev->fe_state != XenbusStateInitialised  &&
-	xendev->fe_state != XenbusStateConnected) {
+    if (xendev->fe_state != XenbusStateConnected) {
 	if (xendev->ops->flags & DEVOPS_FLAG_IGNORE_STATE) {
 	    xen_be_printf(xendev, 2, "frontend not ready, ignoring\n");
 	} else {

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

* Re: [PATCH] Wait the state Connect of the frontend before connect the backend.
  2010-05-17 17:18 [PATCH] Wait the state Connect of the frontend before connect the backend anthony.perard
@ 2010-05-17 17:56 ` Jeremy Fitzhardinge
  2010-05-20 21:24 ` Jeremy Fitzhardinge
  1 sibling, 0 replies; 4+ messages in thread
From: Jeremy Fitzhardinge @ 2010-05-17 17:56 UTC (permalink / raw)
  To: anthony.perard; +Cc: xen-devel

On 05/17/2010 10:18 AM, anthony.perard@citrix.com wrote:
> From: Anthony PERARD <anthony.perard@citrix.com>
>
> The frontend of the framebuffer set a value (request-abs-pointer) and go
> to the state Connected.  The backend must read this value only when the
> frontend has the state Connected.
>   

Thanks for looking at this, I'll try it out.

    J

> ---
>  hw/xen_backend.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
>
> diff --git a/hw/xen_backend.c b/hw/xen_backend.c
> index 76d07ec..31ed7b0 100644
> --- a/hw/xen_backend.c
> +++ b/hw/xen_backend.c
> @@ -411,8 +411,7 @@ static int xen_be_try_connect(struct XenDevice *xendev)
>  {
>      int rc = 0;
>  
> -    if (xendev->fe_state != XenbusStateInitialised  &&
> -	xendev->fe_state != XenbusStateConnected) {
> +    if (xendev->fe_state != XenbusStateConnected) {
>  	if (xendev->ops->flags & DEVOPS_FLAG_IGNORE_STATE) {
>  	    xen_be_printf(xendev, 2, "frontend not ready, ignoring\n");
>  	} else {
>
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel
>
>   

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

* Re: [PATCH] Wait the state Connect of the frontend before connect the backend.
  2010-05-17 17:18 [PATCH] Wait the state Connect of the frontend before connect the backend anthony.perard
  2010-05-17 17:56 ` Jeremy Fitzhardinge
@ 2010-05-20 21:24 ` Jeremy Fitzhardinge
  2010-05-21 15:23   ` [PATCH] Wait the state Connect of the frontend before connect the backend. [and 1 more messages] Ian Jackson
  1 sibling, 1 reply; 4+ messages in thread
From: Jeremy Fitzhardinge @ 2010-05-20 21:24 UTC (permalink / raw)
  To: anthony.perard; +Cc: xen-devel, Ian Jackson

On 05/17/2010 10:18 AM, anthony.perard@citrix.com wrote:
> From: Anthony PERARD <anthony.perard@citrix.com>
>
> The frontend of the framebuffer set a value (request-abs-pointer) and go
> to the state Connected.  The backend must read this value only when the
> frontend has the state Connected.
>   

This works well.  It should go into git.

(Anthony: you'll need to append a "Signed-off-by:" line to be strictly
complete.)

Tested-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>

    J

> ---
>  hw/xen_backend.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
>
> diff --git a/hw/xen_backend.c b/hw/xen_backend.c
> index 76d07ec..31ed7b0 100644
> --- a/hw/xen_backend.c
> +++ b/hw/xen_backend.c
> @@ -411,8 +411,7 @@ static int xen_be_try_connect(struct XenDevice *xendev)
>  {
>      int rc = 0;
>  
> -    if (xendev->fe_state != XenbusStateInitialised  &&
> -	xendev->fe_state != XenbusStateConnected) {
> +    if (xendev->fe_state != XenbusStateConnected) {
>  	if (xendev->ops->flags & DEVOPS_FLAG_IGNORE_STATE) {
>  	    xen_be_printf(xendev, 2, "frontend not ready, ignoring\n");
>  	} else {
>
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel
>
>   

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

* Re: [PATCH] Wait the state Connect of the frontend before connect the backend. [and 1 more messages]
  2010-05-20 21:24 ` Jeremy Fitzhardinge
@ 2010-05-21 15:23   ` Ian Jackson
  0 siblings, 0 replies; 4+ messages in thread
From: Ian Jackson @ 2010-05-21 15:23 UTC (permalink / raw)
  To: anthony.perard, Jeremy Fitzhardinge; +Cc: xen-devel@lists.xensource.com

anthony.perard@citrix.com writes ("[Xen-devel] [PATCH] Wait the state Connect of the frontend before connect the backend."):
> The frontend of the framebuffer set a value (request-abs-pointer) and go
> to the state Connected.  The backend must read this value only when the
> frontend has the state Connected.

Thanks for this patch.  I've applied it to xen-unstable and will
backport it to 4.0.  Thanks also to Jeremy for testing.

In general you should include a Signed-Off-By line like this
    Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
except with your name and email address.  This indicates that you are
certifying the code as suitable (copyright-wise and so on) for
inclusion in Xen.  You can find the precise meaning in the Linux
upstream kernel tree (Documentation/SubmittingPatches, copy below).

In this case, and since your patch was so small, I took your message
to grant the relevant permissions.

Thanks,
Ian.

>From Documentation/SubmittingPatches:

        Developer's Certificate of Origin 1.1

        By making a contribution to this project, I certify that:

        (a) The contribution was created in whole or in part by me and I
            have the right to submit it under the open source license
            indicated in the file; or

        (b) The contribution is based upon previous work that, to the best
            of my knowledge, is covered under an appropriate open source
            license and I have the right under that license to submit that
            work with modifications, whether created in whole or in part
            by me, under the same open source license (unless I am
            permitted to submit under a different license), as indicated
            in the file; or

        (c) The contribution was provided directly to me by some other
            person who certified (a), (b) or (c) and I have not modified
            it.

        (d) I understand and agree that this project and the contribution
            are public and that a record of the contribution (including all
            personal information I submit with it, including my sign-off) is
            maintained indefinitely and may be redistributed consistent with
            this project or the open source license(s) involved.

-- 

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

end of thread, other threads:[~2010-05-21 15:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-17 17:18 [PATCH] Wait the state Connect of the frontend before connect the backend anthony.perard
2010-05-17 17:56 ` Jeremy Fitzhardinge
2010-05-20 21:24 ` Jeremy Fitzhardinge
2010-05-21 15:23   ` [PATCH] Wait the state Connect of the frontend before connect the backend. [and 1 more messages] Ian Jackson

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).