- use_random_mac=0 if mac else 1,
- mac_address=L2Util.mac_to_bin(mac) if mac else 6 * b'\x00',
- host_namespace=64 * b'\x00',
- host_mac_addr=6 * b'\x00',
- host_if_name_set=1,
- host_if_name=tap_name + (64 - len(tap_name)) * b'\x00',
- host_bridge=64 * b'\x00',
- host_ip4_addr=4 * b'\x00',
- host_ip6_addr=16 * b'\x00',
- host_ip4_gw=4 * b'\x00',
- host_ip6_gw=16 * b'\x00'
+ use_random_mac=bool(mac is None),
+ mac_address=L2Util.mac_to_bin(mac) if mac else None,
+ num_rx_queues=int(num_rx_queues),
+ host_mtu_set=False,
+ host_mac_addr_set=False,
+ host_ip4_prefix_set=False,
+ host_ip6_prefix_set=False,
+ host_ip4_gw_set=False,
+ host_ip6_gw_set=False,
+ host_namespace_set=False,
+ host_if_name_set=True,
+ host_if_name=tap_name,
+ host_bridge_set=False