]> www.infradead.org Git - users/jedix/linux-maple.git/commit
net: ti: icssg-prueth: Fix HSR and switch offload Enablement during firwmare reload.
authorMD Danish Anwar <danishanwar@ti.com>
Thu, 14 Aug 2025 10:51:06 +0000 (16:21 +0530)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 19 Aug 2025 10:26:18 +0000 (12:26 +0200)
commit01792bc3e5bdafa171dd83c7073f00e7de93a653
tree9b047d9622df137c38993a61caa0c719bed02fa5
parent0417adf367a0af11adf7ace849af4638cfb573f7
net: ti: icssg-prueth: Fix HSR and switch offload Enablement during firwmare reload.

To enable HSR / Switch offload, certain configurations are needed.
Currently they are done inside icssg_change_mode(). This function only
gets called if we move from one mode to another without bringing the
links up / down.

Once in HSR / Switch mode, if we bring the links down and bring it back
up again. The callback sequence is,

- emac_ndo_stop()
Firmwares are stopped
- emac_ndo_open()
Firmwares are loaded

In this path icssg_change_mode() doesn't get called and as a result the
configurations needed for HSR / Switch is not done.

To fix this, put all these configurations in a separate function
icssg_enable_fw_offload() and call this from both icssg_change_mode()
and emac_ndo_open()

Fixes: 56375086d093 ("net: ti: icssg-prueth: Enable HSR Tx duplication, Tx Tag and Rx Tag offload")
Signed-off-by: MD Danish Anwar <danishanwar@ti.com>
Link: https://patch.msgid.link/20250814105106.1491871-1-danishanwar@ti.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/ethernet/ti/icssg/icssg_prueth.c