[libvirt] [PATCH v2] vepa: parsing for 802.1Qb{g|h} XML

Stefan Berger stefanb at us.ibm.com
Wed May 12 17:21:54 UTC 2010


Gerhard Stenzel <gstenzel at linux.vnet.ibm.com> wrote on 05/12/2010 12:34:09 
PM:

> 
> On Wed, 2010-05-12 at 12:13 -0400, Stefan Berger wrote:
> > I'd suggest to use this patch as a base for triggering the setup
> > protocol with the 802.1Qb{g|h} switch.
> 
> Here is a RFC patch, which demonstrates how libvirt could communicate
> with lldpad via the lldptool for the 802.1Qbg case. Please note, that
> there is currently no public available version of lldptool which accepts
> this command line. This is also work in progress. 
> 

[...]

> +    virFormatMacAddr(mac, macaddr);
> +
> +     rc = ifaceGetRootIface(-1, linkdev, rootifname);
> +     if (rc != 0) {
> +        macvtapError(VIR_ERR_INTERNAL_ERROR,
> +                     _("cannot get root interface for %s"),
> +                     linkdev);
> +         return rc;
> +     }
> +    VIR_DEBUG("root iface of %s is %s\n", linkdev, rootifname);
> +
> +    ifaceGetVlanID(linkdev, &vlanid);
> +    VIR_DEBUG("vlan id of %s is %d\n", linkdev, vlanid);

I am wondering whether it would not be 'more general' to have lldpad 
determine
the root interface and handling bonding interfaces on the way rather 
than libvirt trying to determine that here. So we would just pass the
linkdev or the even the macvtap to lldptool. The same would be true
for finding the VLAN ID. For both the code I posted here on libvirt
mailing list could be used in lldpad. For now I won't check it in.

    Stefan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20100512/bf80e675/attachment-0001.htm>


More information about the libvir-list mailing list