The network driver (pseries llan) isn't reading the MAC address set by QEMU correctly.
In the example bellow, user defines MAC address to 52:54:00:fa:de:56 and driver assumes 00:fa:de:56:00:00.
The issue was seen on both "12.0-RELEASE r341666" and "13.0-CURRENT r346544"
QEMU 4.0rc0 start command:
-name guest=freebsd -cpu POWER8 -m 2048 \
-drive file=vdisks/freebsd-vm-disk1.qcow2,if=scsi,index=0,format=qcow2 \
-net nic,macaddr=52:54:00:fa:de:56 -net tap \
-nographic -vga none -enable-kvm \
-smp 16 \
-machine pseries,accel=kvm,cap-cfpc=broken,cap-sbbc=broken,cap-ibs=broken,cap-hpt-max-page-size=16M \
-mem-prealloc -mem-path /dev/hugepages \
root@base-test:~ # ifconfig llan0
llan0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
inet 10.10.71.70 netmask 0xffffff00 broadcast 10.10.71.255
media: Ethernet autoselect
root@base-test:~ # uname -a
FreeBSD base-test 12.0-RELEASE FreeBSD 12.0-RELEASE r341666 GENERIC powerpc
There's a fix on the way: https://reviews.freebsd.org/D20843
A commit references this bug:
Date: Thu Jul 4 12:31:25 UTC 2019
New revision: 349723
[PPC64] pseries llan: fix MAC address
There was an issue in pseries llan driver, that resulted in the first 2 bytes
of the MAC address getting stripped, and the last 2 being always 0.
In most cases the network interface still worked, despite the MAC being
different of what was specified to QEMU, but when some other host or DHCP
server expected a specific MAC, this would fail.
This change fixes this by shifting right by 2 the local-mac-address read from
device tree, if its length is 6 instead of 8, as observed in QEMU DT, that
always presents a 6 bytes value for this property.
Reported by: Alfredo Dal'Ava Junior
Reviewed by: jhibbits
Differential Revision: https://reviews.freebsd.org/D20843
Confirmed fixed in 13-CURRENT