containernetworking / plugins

Some reference and example networking plugins, maintained by the CNI team.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Why not expose netlin.LinkAttrs in parameter to config queue number of veth pair?

victory460 opened this issue · comments

func makeVethPair(name, peer string, mtu int, mac string, hostNS ns.NetNS) (netlink.Link, error) {
veth := &netlink.Veth{
LinkAttrs: netlink.LinkAttrs{
Name: name,
MTU: mtu,
},

Why not expose netlin.LinkAttrs in parameter to config queue number of veth pair?
like this code:

func makeVethPair(linkAttr netlink.LinkAttrs, peer string, mac string, hostNS ns.NetNS) (netlink.Link, error) {
	veth := &netlink.Veth{
		LinkAttrs:     linkAttr,
		PeerName:      peer,
		PeerNamespace: netlink.NsFd(int(hostNS.Fd())),
	}

we want to config rx queue number of veth pair.

@victory460 what are the benifits of using multiple queue numbers for a veth device?