All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] libxl: stat the path for all non-qdisk backends (including unknown)
@ 2013-04-26 14:12 Ian Campbell
  2013-04-26 14:17 ` Sylvain Munaut
  2013-04-26 14:29 ` Roger Pau Monné
  0 siblings, 2 replies; 22+ messages in thread
From: Ian Campbell @ 2013-04-26 14:12 UTC (permalink / raw)
  To: xen-devel; +Cc: ian.jackson, dave.scott, roger.pau, Ian Campbell, george.dunlap

The commit a8a1f236a296 "libxl: Only call stat() when adding a disk if we
expect a device to exist." changed things to only stat the file when the phy
backend was explicitly requested. This broke the case where we are probing and
would normally be able to decide on the phy option.

Since the intention of that commit was to allow for qdisk backends with no
explicit file in dom0 (i.e. network remote backend such as ceph) the lowest
impact fix appears to be to make that explicit. This should probably be
revisited to rationalize the probing.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Cc: dave.scott@citrix.com
Cc: george.dunlap@citrix.com
Cc: roger.pau@citrix.com
Cc: ian.jackson@citrix.com
---
 tools/libxl/libxl_device.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/libxl/libxl_device.c b/tools/libxl/libxl_device.c
index eb60fd5..b01d109 100644
--- a/tools/libxl/libxl_device.c
+++ b/tools/libxl/libxl_device.c
@@ -236,7 +236,7 @@ int libxl__device_disk_set_backend(libxl__gc *gc, libxl_device_disk *disk) {
             return ERROR_INVAL;
         }
         memset(&a.stab, 0, sizeof(a.stab));
-    } else if (disk->backend == LIBXL_DISK_BACKEND_PHY &&
+    } else if (disk->backend != LIBXL_DISK_BACKEND_QDISK &&
                disk->backend_domid == LIBXL_TOOLSTACK_DOMID &&
                !disk->script) {
         if (stat(disk->pdev_path, &a.stab)) {
-- 
1.7.2.5

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

end of thread, other threads:[~2013-05-10 15:09 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-26 14:12 [PATCH] libxl: stat the path for all non-qdisk backends (including unknown) Ian Campbell
2013-04-26 14:17 ` Sylvain Munaut
2013-04-26 14:29   ` Ian Campbell
2013-04-26 14:39     ` Roger Pau Monné
2013-04-26 14:42       ` George Dunlap
2013-04-26 14:47         ` Ian Campbell
2013-04-26 15:33         ` Ian Campbell
2013-04-26 15:48           ` David Scott
2013-05-10 13:46     ` George Dunlap
2013-05-10 13:49       ` Ian Campbell
2013-05-10 13:55         ` George Dunlap
2013-05-10 14:09           ` Ian Campbell
2013-05-10 14:21             ` David Scott
2013-05-10 14:09       ` David Scott
2013-05-10 14:19         ` George Dunlap
2013-05-10 14:31           ` David Scott
2013-05-10 14:42             ` George Dunlap
2013-05-10 15:03               ` David Scott
2013-05-10 15:07                 ` George Dunlap
2013-05-10 15:09                 ` Ian Campbell
2013-04-26 14:29 ` Roger Pau Monné
2013-04-26 14:34   ` Ian Campbell

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.