• L
    network: store network macTableManager setting in NetDef actual object · 33f4a8bc
    Laine Stump 提交于
    At the time that the network driver allocates a connection to a
    network, the tap device that will be used hasn't yet been created -
    that will be done later by qemu (or lxc or whoever) - but if the
    network has macTableManager='libvirt', then when we do get around to
    creating the tap device, we will need to add an entry for it to the
    network bridge's fdb (forwarding database) *and* turn off learning and
    unicast_flood for that tap device in the bridge's sysfs settings. This
    means that qemu needs to know both the bridge name as well as the
    setting of macTableManager, so we either need to create a new API to
    retrieve that info, or just pass it back in the ActualNetDef that is
    created during networkAllocateActualDevice. We choose the latter
    method, since it's already done for the bridge device, and it has the
    side effect of making the information available in domain status.
    
    (NB: in the future, I think that the tap device should actually be
    created by networkAllocateActualDevice(), as that will solve several
    other problems, but that is a battle for another day, and this
    information will still be useful outside the network driver)
    33f4a8bc
domain_conf.c 695.8 KB