diff options
| author | Lorenzo Bianconi <lorenzo@kernel.org> | 2026-06-09 00:24:15 +0300 |
|---|---|---|
| committer | Jakub Kicinski <kuba@kernel.org> | 2026-06-12 01:35:20 +0300 |
| commit | aeb62be4d3b18b76551bf7806e30d72e5c3bbade (patch) | |
| tree | 44d29e234346b15edf47e98d1321c0ac6aa89b32 /include/uapi/linux | |
| parent | 3fbbb5a6280494d4e65d3acdb9a465d7d977f530 (diff) | |
| download | linux-aeb62be4d3b18b76551bf7806e30d72e5c3bbade.tar.xz | |
net: airoha: move get_sport() callback at the beginning of airoha_enable_gdm2_loopback()
Move the get_sport() callback invocation at the beginning of
airoha_enable_gdm2_loopback() routine in order to avoid leaving the
hardware in a partially configured state if get_sport() fails.
Previously, get_sport() was called after GDM2 forwarding, loopback,
channel, length, VIP and IFC registers had already been programmed.
A failure at that point would return an error leaving GDM2 with
loopback enabled but WAN port, PPE CPU port and flow control mappings
not configured.
Performing the get_sport() lookup before any register write guarantees
the routine either completes the full configuration sequence or exits
with no side effects on the hardware.
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20260608-airoha_enable_gdm2_loopback-minor-change-v1-1-1787a0f42b31@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include/uapi/linux')
0 files changed, 0 insertions, 0 deletions
