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

[Xen-devel] [PATCH] xen-blkfront: prefer xenbus_write() over xenbus_printf() where possible



... as being the simpler variant.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
---
 drivers/block/xen-blkfront.c |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

--- 4.7-rc6-prefer-xenbus_write.orig/drivers/block/xen-blkfront.c
+++ 4.7-rc6-prefer-xenbus_write/drivers/block/xen-blkfront.c
@@ -1825,14 +1825,13 @@ again:
                }
                kfree(path);
        }
-       err = xenbus_printf(xbt, dev->nodename, "protocol", "%s",
-                           XEN_IO_PROTO_ABI_NATIVE);
+       err = xenbus_write(xbt, dev->nodename, "protocol",
+                          XEN_IO_PROTO_ABI_NATIVE);
        if (err) {
                message = "writing protocol";
                goto abort_transaction;
        }
-       err = xenbus_printf(xbt, dev->nodename,
-                           "feature-persistent", "%u", 1);
+       err = xenbus_printf(xbt, dev->nodename, "feature-persistent", "1");
        if (err)
                dev_warn(&dev->dev,
                         "writing persistent grants feature to xenbus");




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

 


Rackspace

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