WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-api

[Xen-API] [PATCH 1 of 9] CA-31528: Remove the Xal DevNew event since it

To: xen-api@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-API] [PATCH 1 of 9] CA-31528: Remove the Xal DevNew event since it is unused
From: David Scott <dave.scott@xxxxxxxxxxxxx>
Date: Mon, 30 Nov 2009 15:45:48 +0000
Delivery-date: Mon, 30 Nov 2009 07:42:44 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <patchbomb.1259595947@xxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-api-request@lists.xensource.com?subject=help>
List-id: Discussion of API issues surrounding Xen <xen-api.lists.xensource.com>
List-post: <mailto:xen-api@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-api-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User David Scott <dave.scott@xxxxxxxxxxxxx>
# Date 1259595833 0
# Node ID 3ecb328d9cdc2e9c86b9715bc649cfd02d7aa11d
# Parent  e24ebc4eae4bc1f411a0391ece4509733f296cf9
CA-31528: Remove the Xal DevNew event since it is unused.

Signed-off-by: David Scott <dave.scott@xxxxxxxxxxxxx>

diff -r e24ebc4eae4b -r 3ecb328d9cdc ocaml/xenops/xal.ml
--- a/ocaml/xenops/xal.ml       Mon Nov 30 15:37:08 2009 +0000
+++ b/ocaml/xenops/xal.ml       Mon Nov 30 15:43:53 2009 +0000
@@ -28,7 +28,6 @@
 
 type dev_event =
        (* devices : backend / type / devid *)
-       | DevNew of bool * string * string
        | DevWorking of bool * string * string
        | DevClosing of bool * string * string
        | DevClosed of bool * string * string
@@ -74,8 +73,6 @@
        let string_of_string_opt = function None -> "\"\"" | Some s -> s in
        let string_of_b b = if b then "B" else "F" in
        match ev with
-       | DevNew (b, s, i) ->
-               sprintf "device new {%s,%s,%s}" (string_of_b b) s i
        | DevWorking (b, s, i) ->
                sprintf "device working {%s,%s,%s}" (string_of_b b) s i
        | DevClosing (b, s, i) ->
@@ -580,8 +577,7 @@
 let diff_device_state backend ty devid oldstate newstate =
        let working () = DevWorking (backend, ty, devid)
        and closing () = DevClosing (backend, ty, devid)
-       and closed () = DevClosed (backend, ty, devid)
-       and _new () = DevNew (backend, ty, devid) in
+       and closed () = DevClosed (backend, ty, devid) in
        if oldstate <> newstate then
                match oldstate, newstate with
                | Connecting, Connected  -> [ working () ]
@@ -590,9 +586,8 @@
                | Connected,  Closing    -> [ closed () ]
                | Connected,  Closed     -> [ closing (); closed () ]
                | Closing,    Closed     -> [ closed () ]
-               | Closed,     Connecting -> [ _new () ]
-               | Closed,     Connected  -> [ _new (); working () ]
-               | Closed,     Closing    -> [ _new (); closing () ]
+               | Closed,     Connected  -> [ working () ]
+               | Closed,     Closing    -> [ closing () ]
                (* those should not happen *)
                | Closing,    Connecting -> []
                | Closing,    Connected  -> []
diff -r e24ebc4eae4b -r 3ecb328d9cdc ocaml/xenops/xal.mli
--- a/ocaml/xenops/xal.mli      Mon Nov 30 15:37:08 2009 +0000
+++ b/ocaml/xenops/xal.mli      Mon Nov 30 15:43:53 2009 +0000
@@ -37,7 +37,6 @@
 exception Timeout
 
 type dev_event =
-       | DevNew of bool * string * string
        | DevWorking of bool * string * string
        | DevClosing of bool * string * string
        | DevClosed of bool * string * string
2 files changed, 3 insertions(+), 9 deletions(-)
ocaml/xenops/xal.ml  |   11 +++--------
ocaml/xenops/xal.mli |    1 -


Attachment: xen-api.hg-9.patch
Description: Text Data

_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api