Page MenuHomeFreeBSD

Remove non-functional SCTP checksum offload support for virtio
ClosedPublic

Authored by tuexen on May 3 2019, 1:45 PM.

Details

Summary

Checksum offloading for SCTP is not currently specified for virtio. If the hypervisor announces checksum offloading support, it means TCP and UDP checksum offload. If an SCTP packet is sent and the host announced checksum offload support, the hypervisor inserts the IP checksum (16-bit) at the correct offset, but this is not the right checksum, which is a CRC32c. This results in all outgoing packets having the wrong checksum and therefore breaking SCTP based communications.

This patch removes SCTP checksum offloading support from the virtio network interface.

Thanks to Felix Weinrank for making me aware of the issue.

Test Plan

It can be tested with running

ncat --sctp bsd14.fh-muenster.de

Diff Detail

Repository
rS FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

tuexen created this revision.May 3 2019, 1:45 PM
bryanv accepted this revision.May 7 2019, 3:06 PM

This is fine. I made a similar change in my VirtIO V1 branch (https://github.com/bryanv/freebsd/commit/a2903365a44b710929e52bf00b85a501856a7510) but I have not had the time to commit it yet.

This revision is now accepted and ready to land.May 7 2019, 3:06 PM
bryanv added inline comments.May 7 2019, 3:07 PM
sys/dev/virtio/network/if_vtnetvar.h
271 ↗(On Diff #57003)

Nit: this comment could probably be removed since it is kind of implied.

This revision was automatically updated to reflect the committed changes.
tuexen marked an inline comment as done.
tuexen added inline comments.May 7 2019, 8:29 PM
sys/dev/virtio/network/if_vtnetvar.h
271 ↗(On Diff #57003)

OK. I removed the comment. Just wanted to make sure SCTP doesn't get added again by accident. But we now have the an entry in the svn log making it clear.