]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
wifi: Switch back to struct platform_driver::remove()
authorUwe Kleine-König <u.kleine-koenig@baylibre.com>
Wed, 6 Nov 2024 17:07:06 +0000 (18:07 +0100)
committerKalle Valo <kvalo@kernel.org>
Mon, 11 Nov 2024 12:10:45 +0000 (14:10 +0200)
After commit 0edb555a65d1 ("platform: Make platform_driver::remove()
return void") .remove() is (again) the right callback to implement for
platform drivers.

Convert all platform drivers below drivers/net/wireless to use
.remove(), with the eventual goal to drop struct
platform_driver::remove_new(). As .remove() and .remove_new() have the
same prototypes, conversion is done by just changing the structure
member name in the driver initializer.

En passant several whitespace changes are done to make indentation
consistent in the struct initializers.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
Acked-by: Toke Høiland-Jørgensen <toke@toke.dk>
Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com>
Acked-by: Jiri Slaby <jirislaby@kernel.org>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://patch.msgid.link/20241106170706.38922-2-u.kleine-koenig@baylibre.com
12 files changed:
drivers/net/wireless/ath/ath10k/ahb.c
drivers/net/wireless/ath/ath10k/snoc.c
drivers/net/wireless/ath/ath11k/ahb.c
drivers/net/wireless/ath/ath5k/ahb.c
drivers/net/wireless/ath/ath9k/ahb.c
drivers/net/wireless/ath/wcn36xx/main.c
drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c
drivers/net/wireless/mediatek/mt76/mt7603/soc.c
drivers/net/wireless/mediatek/mt76/mt7615/soc.c
drivers/net/wireless/mediatek/mt76/mt7915/soc.c
drivers/net/wireless/ti/wl12xx/main.c
drivers/net/wireless/ti/wl18xx/main.c

index f0441b3d7dcb4039a75486768d3ae35af0bc0518..db9f9ebcb62d20e5cdcf9e7b08f5ea23e0dc3d22 100644 (file)
@@ -837,12 +837,12 @@ static void ath10k_ahb_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver ath10k_ahb_driver = {
-       .driver         = {
-               .name   = "ath10k_ahb",
+       .driver = {
+               .name = "ath10k_ahb",
                .of_match_table = ath10k_ahb_of_match,
        },
-       .probe  = ath10k_ahb_probe,
-       .remove_new = ath10k_ahb_remove,
+       .probe = ath10k_ahb_probe,
+       .remove = ath10k_ahb_remove,
 };
 
 int ath10k_ahb_init(void)
index 0fe47d51013c7cb296a6e6b5483cde867929768b..d436a874cd5af40462e64083d5b5259cc45b2dc0 100644 (file)
@@ -1885,11 +1885,11 @@ static void ath10k_snoc_shutdown(struct platform_device *pdev)
 }
 
 static struct platform_driver ath10k_snoc_driver = {
-       .probe  = ath10k_snoc_probe,
-       .remove_new = ath10k_snoc_remove,
+       .probe = ath10k_snoc_probe,
+       .remove = ath10k_snoc_remove,
        .shutdown = ath10k_snoc_shutdown,
        .driver = {
-               .name   = "ath10k_snoc",
+               .name = "ath10k_snoc",
                .of_match_table = ath10k_snoc_dt_match,
        },
 };
index 916402ad06b8efbe478bc4353e03c778d2ee6940..f2fc04596d48173867849cfcc4b9f2f8d39d064e 100644 (file)
@@ -1313,12 +1313,12 @@ free_resources:
 }
 
 static struct platform_driver ath11k_ahb_driver = {
-       .driver         = {
-               .name   = "ath11k",
+       .driver = {
+               .name = "ath11k",
                .of_match_table = ath11k_ahb_of_match,
        },
-       .probe  = ath11k_ahb_probe,
-       .remove_new = ath11k_ahb_remove,
+       .probe = ath11k_ahb_probe,
+       .remove = ath11k_ahb_remove,
        .shutdown = ath11k_ahb_shutdown,
 };
 
index f27308ccb2f15e75c76449dffe39cb2d56b5b8e5..cb3e891ee1bd127a5fa047c1f590d2a85015de3b 100644 (file)
@@ -218,10 +218,10 @@ static void ath_ahb_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver ath_ahb_driver = {
-       .probe      = ath_ahb_probe,
-       .remove_new = ath_ahb_remove,
-       .driver         = {
-               .name   = "ar231x-wmac",
+       .probe = ath_ahb_probe,
+       .remove = ath_ahb_remove,
+       .driver = {
+               .name = "ar231x-wmac",
        },
 };
 
index 1a6697b6e3b41fd6de77cd09a875986733787cc1..d4805e02b92704d4a7e1c697db25b47486c2236a 100644 (file)
@@ -158,12 +158,12 @@ static void ath_ahb_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver ath_ahb_driver = {
-       .probe      = ath_ahb_probe,
-       .remove_new = ath_ahb_remove,
-       .driver         = {
-               .name   = "ath9k",
+       .probe = ath_ahb_probe,
+       .remove = ath_ahb_remove,
+       .driver = {
+               .name = "ath9k",
        },
-       .id_table    = ath9k_platform_id_table,
+       .id_table = ath9k_platform_id_table,
 };
 
 MODULE_DEVICE_TABLE(platform, ath9k_platform_id_table);
index 408776562a7e56da3017aa074396bcd241d62f8c..8557d4826a46e4de7ae11d4805a48f282c818fab 100644 (file)
@@ -1679,10 +1679,10 @@ static const struct of_device_id wcn36xx_of_match[] = {
 MODULE_DEVICE_TABLE(of, wcn36xx_of_match);
 
 static struct platform_driver wcn36xx_driver = {
-       .probe      = wcn36xx_probe,
-       .remove_new = wcn36xx_remove,
-       .driver         = {
-               .name   = "wcn36xx",
+       .probe = wcn36xx_probe,
+       .remove = wcn36xx_remove,
+       .driver = {
+               .name = "wcn36xx",
                .of_match_table = wcn36xx_of_match,
        },
 };
index 58d50918dd177dec6641ead123135657234137f2..cfcf01eb0daa54677a289bbe2b0e9d24ef40a512 100644 (file)
@@ -594,7 +594,7 @@ static void brcmf_common_pd_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver brcmf_pd = {
-       .remove_new     = brcmf_common_pd_remove,
+       .remove         = brcmf_common_pd_remove,
        .driver         = {
                .name   = BRCMFMAC_PDATA_NAME,
        }
index ec02148a7f1f74857b455e683103a607cfeeb2f4..08590aa68356f7b7dc10e4d2059f3f8759593e40 100644 (file)
@@ -71,7 +71,7 @@ MODULE_FIRMWARE(MT7628_FIRMWARE_E2);
 
 struct platform_driver mt76_wmac_driver = {
        .probe          = mt76_wmac_probe,
-       .remove_new     = mt76_wmac_remove,
+       .remove         = mt76_wmac_remove,
        .driver = {
                .name = "mt76_wmac",
                .of_match_table = of_wmac_match,
index 12e3e4a91d2748e9fbf267bf82801fce834e792c..06a0f2a141e8c7c293fef458c0257c4d800865b7 100644 (file)
@@ -63,7 +63,7 @@ struct platform_driver mt7622_wmac_driver = {
                .of_match_table = mt7622_wmac_of_match,
        },
        .probe = mt7622_wmac_probe,
-       .remove_new = mt7622_wmac_remove,
+       .remove = mt7622_wmac_remove,
 };
 
 MODULE_FIRMWARE(MT7622_FIRMWARE_N9);
index 90a6f61d10892be166aa6edcff7978a6497dcd55..c823a7554a3ac617058fb7b3f41ffbb477785adf 100644 (file)
@@ -1303,7 +1303,7 @@ struct platform_driver mt798x_wmac_driver = {
                .of_match_table = mt798x_wmac_of_match,
        },
        .probe = mt798x_wmac_probe,
-       .remove_new = mt798x_wmac_remove,
+       .remove = mt798x_wmac_remove,
 };
 
 MODULE_FIRMWARE(MT7986_FIRMWARE_WA);
index b26d42b4e3cc0fbdc21e55b4b9682b0a81e1ec8e..ffbf5477633022e169f0c9bc9be45e1ec8c9ac49 100644 (file)
@@ -1939,7 +1939,7 @@ MODULE_DEVICE_TABLE(platform, wl12xx_id_table);
 
 static struct platform_driver wl12xx_driver = {
        .probe          = wl12xx_probe,
-       .remove_new     = wl12xx_remove,
+       .remove         = wl12xx_remove,
        .id_table       = wl12xx_id_table,
        .driver = {
                .name   = "wl12xx_driver",
index 39d8eebb9b6e9e1fe1dd82aea2a68000db754b51..4be1110bac8888c2570c4b26faa3edd42d92651b 100644 (file)
@@ -2097,9 +2097,9 @@ MODULE_DEVICE_TABLE(platform, wl18xx_id_table);
 
 static struct platform_driver wl18xx_driver = {
        .probe          = wl18xx_probe,
-       .remove_new     = wlcore_remove,
+       .remove         = wlcore_remove,
        .id_table       = wl18xx_id_table,
-       .driver = {
+       .driver         = {
                .name   = "wl18xx_driver",
        }
 };