xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] libxl: use preferred syntax for network device creation with upstream qemu
@ 2011-05-25  8:20 Ian Campbell
  2011-05-25 14:59 ` Markus Armbruster
  0 siblings, 1 reply; 8+ messages in thread
From: Ian Campbell @ 2011-05-25  8:20 UTC (permalink / raw)
  To: xen-devel; +Cc: Markus Armbruster

# HG changeset patch
# User Ian Campbell <ian.campbell@citrix.com>
# Date 1306311631 -3600
# Node ID 6b1fe0cba8a2f0bcc1274c8e777da5b6c198b45d
# Parent  8258c5a0ba35de937597e2c516bc88f8ebe1be35
libxl: use preferred syntax for network device creation with upstream qemu

Markus Armbruster points out in <m3r582pzc1.fsf@blackfin.pond.sub.org>
on qemu-devel that this is the prefered syntax going forward. Using it avoid
needlessly instantiating a qemu "vlan" and instead creates a simply host end
point and device.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Cc: Markus Armbruster <armbru@redhat.com>

diff -r 8258c5a0ba35 -r 6b1fe0cba8a2 tools/libxl/libxl_dm.c
--- a/tools/libxl/libxl_dm.c	Tue May 24 16:28:07 2011 +0100
+++ b/tools/libxl/libxl_dm.c	Wed May 25 09:20:31 2011 +0100
@@ -336,11 +336,11 @@ static char ** libxl__build_device_model
                 } else {
                     ifname = vifs[i].ifname;
                 }
-                flexarray_append(dm_args, "-net");
-                flexarray_append(dm_args, libxl__sprintf(gc, "nic,vlan=%d,macaddr=%s,model=%s",
-                            vifs[i].devid, smac, vifs[i].model));
-                flexarray_append(dm_args, "-net");
-                flexarray_append(dm_args, libxl__sprintf(gc, "tap,vlan=%d,ifname=%s,script=%s",
+                flexarray_append(dm_args, "-device");
+                flexarray_append(dm_args, libxl__sprintf(gc, "%s,netdev=net%d,mac=%s",
+                                                         vifs[i].model, vifs[i].devid, smac));
+                flexarray_append(dm_args, "-netdev");
+                flexarray_append(dm_args, libxl__sprintf(gc, "type=tap,id=net%d,ifname=%s,script=%s",
                             vifs[i].devid, ifname, libxl_tapif_script(gc)));
                 ioemu_vifs++;
             }

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

end of thread, other threads:[~2011-05-26 16:17 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-25  8:20 [PATCH] libxl: use preferred syntax for network device creation with upstream qemu Ian Campbell
2011-05-25 14:59 ` Markus Armbruster
2011-05-26  8:00   ` Ian Campbell
2011-05-26  8:22     ` Markus Armbruster
2011-05-26  8:53       ` Ian Campbell
2011-05-26 16:17         ` Ian Jackson
2011-05-26 14:38   ` [PATCH] libxl: use preferred syntax for network device creation with upstream qemu [and 1 more messages] Ian Jackson
2011-05-26 14:40     ` Ian Campbell

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