Home
last modified time | relevance | path

Searched refs:hwaddr (Results 1 – 1 of 1) sorted by relevance

/kernel/tests/net/test/
Dnet_test.py198 def SetInterfaceHWAddr(ifname, hwaddr): argument
200 hwaddr = hwaddr.replace(":", "")
201 hwaddr = hwaddr.decode("hex")
202 if len(hwaddr) != 6:
203 raise ValueError("Unknown hardware address length %d" % len(hwaddr))
204 ifr = struct.pack("%dsH6s" % IFNAMSIZ, ifname, scapy.ARPHDR_ETHER, hwaddr)