]> xenbits.xensource.com Git - qemu-xen-4.3-testing.git/commitdiff
Change tap device mac address to prevent change of bridge's mac xen-4.0.2 xen-4.0.2-rc1 xen-4.0.2-rc2 xen-4.0.2-rc3 xen-4.0.2-rc4 xen-4.0.2-rc5 xen-4.0.3 xen-4.0.3-rc1 xen-4.0.3-rc2 xen-4.0.3-rc3
authorMiroslav Rezanina <mrezanin@redhat.com>
Wed, 5 Jan 2011 23:42:03 +0000 (23:42 +0000)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Wed, 5 Jan 2011 23:42:03 +0000 (23:42 +0000)
Qemu tap device is created with random mac address and then add to
bridge. Due to linux kernel handlig, bridge change its mac address to
tap mac in case tap m ac is lower than bridge one. This can lead to
short network breakage for dom0 a nd guests.

This patch set tap device mac adress to FE:FF:FF:FF:FF:FF to ensure
tap device mac is always higher then bridge one.

(In xen-unstable this is handled by the hotplug scripts, not
qemu-ifup, so the change there is to xen-unstable.hg.)

Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
Cc: Ian Campbell <Ian.Campbell@citrix.com>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
i386-dm/qemu-ifup-Linux

index bcbee92d6523e6f76eaa975b2ed014fd0cb956b7..c706a10f4e1bfecd909407e600ab321e5a20ca4d 100644 (file)
@@ -33,5 +33,8 @@ then
    fi
 fi
 
+# We have to change mac address of tap device to not change bridge mac
+ip link set $1 addr fe:ff:ff:ff:ff:ff
+
 ifconfig $1 0.0.0.0 up
 brctl addif $bridge $1 || true