From 47ce1c8e1df6382f6aa400d2bc55038adc63dfa0 Mon Sep 17 00:00:00 2001 From: Kyle McClammy Date: Mon, 3 Aug 2026 17:08:40 -0400 Subject: interfaces: T9158: add rx offload option Add support for receive checksum offload on ethernet interfaces. --- src/activation-scripts/20-ethernet-offload.py | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src') diff --git a/src/activation-scripts/20-ethernet-offload.py b/src/activation-scripts/20-ethernet-offload.py index 9f61f6d8f..b0dab5605 100644 --- a/src/activation-scripts/20-ethernet-offload.py +++ b/src/activation-scripts/20-ethernet-offload.py @@ -63,6 +63,15 @@ def activate(config: ConfigTree): elif enabled and not fixed: config.set(base + [ifname, 'offload', 'lro']) + # If RX is enabled by the Kernel - we reflect this on the CLI. If RX is + # enabled via CLI but not supported by the NIC - we remove it from the CLI + configured = config.exists(base + [ifname, 'offload', 'rx']) + enabled, fixed = eth.get_rx_checksumming() + if configured and fixed: + config.delete(base + [ifname, 'offload', 'rx']) + elif enabled and not fixed: + config.set(base + [ifname, 'offload', 'rx']) + # If SG is enabled by the Kernel - we reflect this on the CLI. If SG is # enabled via CLI but not supported by the NIC - we remove it from the CLI configured = config.exists(base + [ifname, 'offload', 'sg']) -- cgit v1.2.3