wifi: ath10k: Drop cleaning of driver data from probe error path and remove
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thu, 1 Jun 2023 08:25:53 +0000 (10:25 +0200)
committerKalle Valo <quic_kvalo@quicinc.com>
Fri, 9 Jun 2023 12:27:57 +0000 (15:27 +0300)
The driver core cares for resetting driver data if probe fails and after
remove. So drop the explicit and duplicate cleanup in the driver's
functions.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://lore.kernel.org/r/20230601082556.2738446-2-u.kleine-koenig@pengutronix.de
drivers/net/wireless/ath/ath10k/ahb.c

index f0c615fa561433106b71338efe4deb9b229269f3..7bb45c66cff7e6a1cee723cf19b0cdcb4638ceef 100644 (file)
@@ -816,7 +816,6 @@ err_resource_deinit:
 
 err_core_destroy:
        ath10k_core_destroy(ar);
-       platform_set_drvdata(pdev, NULL);
 
        return ret;
 }
@@ -845,8 +844,6 @@ static int ath10k_ahb_remove(struct platform_device *pdev)
        ath10k_ahb_resource_deinit(ar);
        ath10k_core_destroy(ar);
 
-       platform_set_drvdata(pdev, NULL);
-
        return 0;
 }