We have done more research and found out that the same problem as we have is 
faced by virtualization software running under Linux. I have found a discussion 
about a feature called "secondary unicast address" that would allow registering 
multiple MAC addresses with a NIC. Here is a discussion that explains why this 
is useful for virtualization:
http://thread.gmane.org/gmane.linux.network/64719/focus=64775
I have been looking at the l2 qeth driver and found out that the code seems to 
support secondary unicast MAC addresses. Adding a secondary unicast address to 
a NIC can actually be done from user mode, here is a code snippet that 
registers a secondary MAC via a raw packet interface:

s = socket(AF_PACKET, SOCK_RAW, htons(ETH_P_ALL));

...

struct packet_mreq mreq;
memset(&mreq, 0, sizeof(mreq));
mreq.mr_ifindex=ifr.ifr_ifindex;
mreq.mr_type=PACKET_MR_UNICAST;
mreq.mr_alen=ETHER_ADDR_LEN;
memcpy(mreq.mr_address,mac,ETHER_ADDR_LEN);
ret = setsockopt(s, SOL_PACKET, PACKET_ADD_MEMBERSHIP, &mreq, sizeof(mreq));

The dbf trace shows that the l2 qeth driver code gets exercised and leads to a 
command called IPA_CMD_SETVMAC. The user mode call succeeds but I have found 
this error message in /sys/kernel/debug/s390dbf/qeth_msg/sprintf

00 01393420032:989799 2 - 00 000003c00092471e  IPA: setvmac(x21) for 
0.0.a100/eth7 returned x200C "L2 mac not authorized by hypervisor"

This is where we are stuck again. Is the secondary unicast address what I think 
it is? Are there any restrictions on in what situations secondary MAC addresses 
can be added to a virtual NIC?

Tomas

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to lists...@vm.marist.edu with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390
----------------------------------------------------------------------
For more information on Linux on System z, visit
http://wiki.linuxvm.org/

Reply via email to