I've recently discovered (to my surprise) that my jail on Honeycomb LX2 sends UDP and TCP packets with incorrect checksums over epair(4). Bisecting led me to 39d4094173f9 ("epair: add support for checksum offloading"). There's a "dpaa2_ni_setup_if_caps" function in dpaa2_ni.c which configures L3/L4 checksums HW offloading, but it wasn't called in my case during the boot process at all. However, toggling capabilities on the working dpni0 interface helped. I call "dpaa2_ni_setup_if_caps" as a part of the dpaa2_ni attach here.
Details
Details
- Reviewers
bz dch tuexen - Commits
- rGa731cb93a662: dpaa2: Setup interface caps on attach
- Run the latest CURRENT (e.g. 6fa18fe74461);
- $ drill freebsd.org;
- Observe proper address resolved;
- $ jexec <JAIL_ID> /bin/sh;
- $ drill freebsd.org;
- Observe a delay and a network error.
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Comment Actions
Beware that this (L4), if I read it correctly, will also enable RX/TX checksum validation/generation for upper layer protocols for IPv6 packets even if that is not not advertised or enabled.
Comment Actions
IFCAP_HWCSUM was set and enabled for the DPAA2 network interface in the past, but wasn't actually enabled in the hardware, i.e. it was broken before. If TCP/UDP checksums were calculated by whoever was sending frames before, they are re-calculated by the DPAA2 hardware for the whole frame by default. No changes here are expected.
Comment Actions
@bz you meant IFCAP_HWCSUM_IPV6, didn't you? Hmm, I haven't tested it yet. Probably a good idea before committing changes.