wifi: ath12k: Omit a variable reassignment in ath12k_ahb_configure_rproc()
PATCH 1/1 wifi: ath12k: Omit a variable reassignment in ath12k_ahb_configure_rproc()
From: Markus Elfring <[email protected]>
Date: Mon, 20 Oct 2025 16:16:34 +0200
An error code was assigned to a variable and checked accordingly. This value was passed to a dev_err_probe() call in an if branch. This function is documented in the way that the same value is returned. Thus delete a redundant variable reassignment.
The source code was transformed by using the Coccinelle software.
Signed-off-by Markus Elfring <[email protected]>
--- drivers/net/wireless/ath/ath12k/ahb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/net/wireless/ath/ath12k/ahb.c +1 -2
@@ -876,8 +876,7 @@ static int ath12k_ahb_configure_rproc(struct ath12k_base *ab) ret =ath12k_ahb_register_rproc_notifier (ab);if (ret <0 ) { - ret =dev_err_probe (&ab->pdev->dev, ret, -"failed to register rproc notifier\n" ); +dev_err_probe (&ab->pdev->dev, ret,"failed to register rproc notifier\n" ); goto err_put_rproc; }
Signature · 1 line
2.51.1