summaryrefslogtreecommitdiffhomepage
path: root/runsc/boot/network.go
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-06-16 16:33:12 -0700
committergVisor bot <gvisor-bot@google.com>2020-06-16 16:34:26 -0700
commitdbf786c6b33d7ee58477b1ade35f39910fb2c654 (patch)
treee78f17166b9b7594324e25407b3f4577272d584a /runsc/boot/network.go
parente61acfb5eaec4450587116573f708284a0fe7849 (diff)
Add runsc options to set checksum offloading status
--tx-checksum-offload=<true|false> enable TX checksum offload (default: false) --rx-checksum-offload=<true|false> enable RX checksum offload (default: true) Fixes #2989 PiperOrigin-RevId: 316781309
Diffstat (limited to 'runsc/boot/network.go')
-rw-r--r--runsc/boot/network.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/runsc/boot/network.go b/runsc/boot/network.go
index 0af30456e..14d2f56a5 100644
--- a/runsc/boot/network.go
+++ b/runsc/boot/network.go
@@ -123,6 +123,8 @@ type FDBasedLink struct {
Routes []Route
GSOMaxSize uint32
SoftwareGSOEnabled bool
+ TXChecksumOffload bool
+ RXChecksumOffload bool
LinkAddress net.HardwareAddr
QDisc QueueingDiscipline
@@ -236,7 +238,8 @@ func (n *Network) CreateLinksAndRoutes(args *CreateLinksAndRoutesArgs, _ *struct
PacketDispatchMode: fdbased.RecvMMsg,
GSOMaxSize: link.GSOMaxSize,
SoftwareGSOEnabled: link.SoftwareGSOEnabled,
- RXChecksumOffload: true,
+ TXChecksumOffload: link.TXChecksumOffload,
+ RXChecksumOffload: link.RXChecksumOffload,
})
if err != nil {
return err