xen/blktapctrl-default-to-ioemu.patch

56 lines
1.3 KiB
Diff

Index: xen-3.3.0-testing/tools/blktap/drivers/blktapctrl.c
===================================================================
--- xen-3.3.0-testing.orig/tools/blktap/drivers/blktapctrl.c
+++ xen-3.3.0-testing/tools/blktap/drivers/blktapctrl.c
@@ -474,6 +474,7 @@ static int launch_tapdisk_provider(char
return child;
}
+#if 0
static int launch_tapdisk(char *wrctldev, char *rdctldev)
{
char *argv[] = { "tapdisk", wrctldev, rdctldev, NULL };
@@ -483,6 +484,7 @@ static int launch_tapdisk(char *wrctldev
return 0;
}
+#endif
static int launch_tapdisk_ioemu(void)
{
@@ -554,6 +556,7 @@ static int connect_qemu(blkif_t *blkif,
return 0;
}
+#if 0
/* Launch tapdisk instance */
static int connect_tapdisk(blkif_t *blkif, int minor)
{
@@ -597,6 +600,7 @@ fail:
return ret;
}
+#endif
static int blktapctrl_new_blkif(blkif_t *blkif)
{
@@ -621,6 +625,7 @@ static int blktapctrl_new_blkif(blkif_t
blkif->cookie = next_cookie++;
if (!exist) {
+#if 0
if (type == DISK_TYPE_IOEMU) {
if (connect_qemu(blkif, blkif->domid))
goto fail;
@@ -628,6 +633,10 @@ static int blktapctrl_new_blkif(blkif_t
if (connect_tapdisk(blkif, minor))
goto fail;
}
+#else
+ if (connect_qemu(blkif, blkif->domid))
+ goto fail;
+#endif
} else {
DPRINTF("Process exists!\n");