Lines Matching refs:macaddr

144 char *qemu_mac_strdup_printf(const uint8_t *macaddr)  in qemu_mac_strdup_printf()  argument
147 macaddr[0], macaddr[1], macaddr[2], in qemu_mac_strdup_printf()
148 macaddr[3], macaddr[4], macaddr[5]); in qemu_mac_strdup_printf()
160 void qemu_format_nic_info_str(NetClientState *nc, uint8_t macaddr[6]) in qemu_format_nic_info_str()
163 nc->model, macaddr[0], macaddr[1], macaddr[2], in qemu_format_nic_info_str()
164 macaddr[3], macaddr[4], macaddr[5]); in qemu_format_nic_info_str()
169 static void qemu_macaddr_set_used(MACAddr *macaddr) in qemu_macaddr_set_used() argument
174 if (macaddr->a[5] == index) { in qemu_macaddr_set_used()
180 static void qemu_macaddr_set_free(MACAddr *macaddr) in qemu_macaddr_set_free() argument
185 if (memcmp(macaddr->a, &base.a, (sizeof(base.a) - 1)) != 0) { in qemu_macaddr_set_free()
189 if (macaddr->a[5] == index) { in qemu_macaddr_set_free()
208 void qemu_macaddr_default_if_unset(MACAddr *macaddr) in qemu_macaddr_default_if_unset() argument
213 if (memcmp(macaddr, &zero, sizeof(zero)) != 0) { in qemu_macaddr_default_if_unset()
214 if (memcmp(macaddr->a, &base.a, (sizeof(base.a) - 1)) != 0) { in qemu_macaddr_default_if_unset()
217 qemu_macaddr_set_used(macaddr); in qemu_macaddr_default_if_unset()
222 macaddr->a[0] = 0x52; in qemu_macaddr_default_if_unset()
223 macaddr->a[1] = 0x54; in qemu_macaddr_default_if_unset()
224 macaddr->a[2] = 0x00; in qemu_macaddr_default_if_unset()
225 macaddr->a[3] = 0x12; in qemu_macaddr_default_if_unset()
226 macaddr->a[4] = 0x34; in qemu_macaddr_default_if_unset()
227 macaddr->a[5] = qemu_macaddr_get_free(); in qemu_macaddr_default_if_unset()
228 qemu_macaddr_set_used(macaddr); in qemu_macaddr_default_if_unset()
467 qemu_macaddr_set_free(&nic->conf->macaddr); in qemu_del_nic()
1015 if (nic->macaddr && in net_init_nic()
1016 net_parse_macaddr(nd->macaddr.a, nic->macaddr) < 0) { in net_init_nic()
1020 if (nic->macaddr && in net_init_nic()
1021 is_multicast_ether_addr(nd->macaddr.a)) { in net_init_nic()
1026 qemu_macaddr_default_if_unset(&nd->macaddr); in net_init_nic()
1835 ret = net_parse_macaddr(ni->macaddr.a, mac); in net_param_nic()
1841 if (is_multicast_ether_addr(ni->macaddr.a)) { in net_param_nic()
1847 qemu_macaddr_default_if_unset(&ni->macaddr); in net_param_nic()