HomeFreeBSD

mana: add ioctl to support toggling offloading features

Description

mana: add ioctl to support toggling offloading features

With this support, users can enable or disable offloading features
such as txcsum, rxcsum, tso and software lro through ifconfig.

To enable or disable tx features, do it on mana interface first,
then hn/netvsc to sync it up with mana. For example:

ifconfig mana0 -txcsum
ifconfig hn0 -tscsum

To enable or disable rx features, just applying on mana interface
would be sufficient.

Disabling txcsum imples disabling tso. Enabling tso when txcsum
is disabled will result in an error message in dmesg requesting
to enable txcsum first.

Above applies to ipv6 offloading features as well.

Approved by: re (gjb)
Tested by: whu
Sponsored by: Microsoft

(cherry picked from commit ab7dc1ceb6d36fd804bedb818086ae3ff6692bf7)
(cherry picked from commit 4edfbe719bf6a15dee388e65b39a116e9307be7f)

Details

Provenance
whuAuthored on Sep 13 2023, 10:48 AM
Parents
rG8d60ede293eb: mana: fix tso parameters and set hwassist bits
Branches
Unknown
Tags
Unknown