From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Bader Subject: Re: [libvirt] Setting devid for emulated NICs (Xen 4.3.1 / libvirt 1.2.0) using libxl driver Date: Wed, 18 Dec 2013 14:12:46 +0100 Message-ID: <52B19F4E.8010601__13151.0776853704$1387372497$gmane$org@canonical.com> References: <52B07D09.5060008@canonical.com> <1387299534.1025.19.camel@dagon.hellion.org.uk> <52B08AA9.8010809@canonical.com> <1387369646.27441.129.camel@kazak.uk.xensource.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5529363154072585191==" Return-path: In-Reply-To: <1387369646.27441.129.camel@kazak.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Campbell Cc: libvir-list@redhat.com, Xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --===============5529363154072585191== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="om9pkP6LSXDSpjkKsaAM3PVIOWloG0TK2" This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --om9pkP6LSXDSpjkKsaAM3PVIOWloG0TK2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 18.12.2013 13:27, Ian Campbell wrote: > On Tue, 2013-12-17 at 18:32 +0100, Stefan Bader wrote: >>> >>> Might this libxl fix be relevant: >>> commit 5420f26507fc5c9853eb1076401a8658d72669da >>> Author: Jim Fehlig >>> Date: Fri Jan 11 12:22:26 2013 +0000 >>> =20 >>> libxl: Set vfb and vkb devid if not done so by the caller= >>> =20 >>> Other devices set a sensible devid if the caller has not = done so. >>> Do the same for vfb and vkb. While at it, factor out the= common code >>> used to determine a sensible devid, so it can be used by = other >>> libxl__device_*_add functions. >>> =20 >>> Signed-off-by: Jim Fehlig >>> Acked-by: Ian Campbell >>> Committed-by: Ian Campbell >>> =20 >>> and a follow up in dfeccbeaa. Although the comment implies that nic's= >>> were already correctly assigning a devid if the caller specified -1, = so >>> I don't know why it doesn't work for you :-( >> >> Ok, yes, the commit above indeed changes libxl__device_nic_add to call= >> libxl__device_nextid for the devid... Just how is this actually called= =2E >> Maybe not sufficient but "git grep libxl__device_nic_add" in the xen c= ode only >> shows the definition and a declaration in libxl_internal.h to me... >=20 > I have a feeling a macro might be involved... >=20 > Here we go, look for DEFINE_DEVICE_REMOVE in libxl.c. We should really > add the eventual function names in comments to provide grep fodder.... Oh duh, yeah. So in DEFINE_DEVICE_ADD a libxl_device_nic_add is created w= hich calls to libxl__device_nic_add. When I look for the single _ version I fi= nd a call from xl_cmdimpl.c and its public declaration in libxl.h. So I guess the bug is that libvirt in the libxl driver never seems to do = so. Ok, thanks a lot for digging the out the DEFINE. As nice those are to create = similar functions from template, grep and tags fail to be helpful with them. -Stefan >=20 > Ian. >=20 > -- > libvir-list mailing list > libvir-list@redhat.com > https://www.redhat.com/mailman/listinfo/libvir-list >=20 --om9pkP6LSXDSpjkKsaAM3PVIOWloG0TK2 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQIcBAEBCgAGBQJSsZ9OAAoJEOhnXe7L7s6j9FIP/Ah3y1KYaAJpZVWNJG0E35WZ k8+MNIBicNgEfAG17xWdEveDr/WR2OwDqU1ZTQ7mzFj6rqvJNFC8ke5n4mIKhBPu cbbPsn+h26mXZAMtYk5BFbXQyWhzs0qgImdfbLXWXblbz+lalBaIcc3bArYuSR0i lcCu6idrPWaU1BxDMh5BTC+SrgRNXoI+5R0Zu1nWv8yllqSnfatI46tkt3faLhLj Hbm8YKoK7n7xr3PJCKHsxPPp7OEltyZpzLaOoAcQKAlXUvVkOqoI1PiDMy0NPTec LVK6sygi7pyCkkmIdyx9mHXCAKqQ2BTOLHW2sx1GGclY+r4cnUhm1+DMDB9T1g7j nbxSxpFmkVh87SXj6KW2njy8vevwc4MUffv2cr+ciEzNT1Cog2hA0HtFKxjaEaqk uOKHwvTiGYPCyDN8lqStxJf0CFe80EYIsVMsNkLq7t2jco5xqtnIDX4KBCS25kJL 2p7MRCYFkdejHhhXjX2fT88WvzUDF5DoSYPoFBgx0NFGUh0xgBimcTfOb/ywPnNS QVcTbDWA4kSvDoBoRkzDkm24cVoturKtRH1dHSQyEZjZbztMhmH6m6heVUISuV+G j8BzUqIHqT9XjA9rIasivDsfkeLVZ3ghIvs0FzeYiNAn7Q4t3BRAaiFF3zvy7xxt 8ixczFFNyhKrxQrk46xA =wx7Y -----END PGP SIGNATURE----- --om9pkP6LSXDSpjkKsaAM3PVIOWloG0TK2-- --===============5529363154072585191== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============5529363154072585191==--