diff options
author | Dan Carpenter <dan.carpenter@linaro.org> | 2024-09-28 13:04:01 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-10-02 17:25:32 -0700 |
commit | 3c97fe4f9fbc2bbc555b51268a9556e61cd3ca4e (patch) | |
tree | ad0cf1c7fc56fae0c8bf766a0c35ecbd2cdb3dfa /drivers | |
parent | c283782fc5d60c4d8169137c6f955aa3553d3b3d (diff) | |
download | lwn-3c97fe4f9fbc2bbc555b51268a9556e61cd3ca4e.tar.gz lwn-3c97fe4f9fbc2bbc555b51268a9556e61cd3ca4e.zip |
net: ethernet: ti: am65-cpsw: Fix forever loop in cleanup code
This error handling has a typo. It should i++ instead of i--. In the
original code the error handling will loop until it crashes.
Fixes: da70d184a8c3 ("net: ethernet: ti: am65-cpsw: Introduce multi queue Rx")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>
Reviewed-by: Roger Quadros <rogerq@kernel.org>
Link: https://patch.msgid.link/8e7960cc-415d-48d7-99ce-f623022ec7b5@stanley.mountain
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/ti/am65-cpsw-nuss.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/ti/am65-cpsw-nuss.c b/drivers/net/ethernet/ti/am65-cpsw-nuss.c index cbe99017cbfa..d253727b160f 100644 --- a/drivers/net/ethernet/ti/am65-cpsw-nuss.c +++ b/drivers/net/ethernet/ti/am65-cpsw-nuss.c @@ -763,7 +763,7 @@ fail_tx: k3_udma_glue_disable_rx_chn(rx_chn->rx_chn); fail_rx: - for (i = 0; i < common->rx_ch_num_flows; i--) + for (i = 0; i < common->rx_ch_num_flows; i++) k3_udma_glue_reset_rx_chn(rx_chn->rx_chn, i, &rx_chn->flows[i], am65_cpsw_nuss_rx_cleanup, 0); |