mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
Skip IFLA_TXQLEN and IFA_BROADCAST in gVisor.
The attributes are expected by Dockerd to start. In gVisor, skipping the attributes is good enough to run the Docker workloads. PiperOrigin-RevId: 650362257
This commit is contained in:
@@ -515,6 +515,10 @@ func (p *Protocol) newAddr(ctx context.Context, s *netlink.Socket, msg *nlmsg.Me
|
||||
return syserr.ErrInvalidArgument
|
||||
}
|
||||
case linux.IFA_ADDRESS:
|
||||
case linux.IFA_BROADCAST:
|
||||
// TODO(b/340929168): support IFA_BROADCAST. The standard
|
||||
// broadcast address (the last IP address of the subnet) is
|
||||
// used by default.
|
||||
default:
|
||||
ctx.Warningf("Unknown attribute: %v", ahdr.Type)
|
||||
return syserr.ErrNotSupported
|
||||
|
||||
@@ -137,6 +137,7 @@ func (s *Stack) SetInterface(ctx context.Context, msg *nlmsg.Message) *syserr.Er
|
||||
case linux.IFLA_ADDRESS:
|
||||
case linux.IFLA_MTU:
|
||||
case linux.IFLA_NET_NS_FD:
|
||||
case linux.IFLA_TXQLEN:
|
||||
default:
|
||||
ctx.Warningf("unexpected attribute: %x", attr)
|
||||
return syserr.ErrNotSupported
|
||||
@@ -225,6 +226,8 @@ func (s *Stack) setLink(ctx context.Context, id tcpip.NICID, linkAttrs map[uint1
|
||||
if err := s.Stack.SetNICMTU(id, mtu); err != nil {
|
||||
return syserr.TranslateNetstackError(err)
|
||||
}
|
||||
case linux.IFLA_TXQLEN:
|
||||
// TODO(b/340388892): support IFLA_TXQLEN.
|
||||
}
|
||||
}
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user