Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: Drop empty platform remove functions

Merge series from Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:

Hello,

this patch series removes all platform remove functions that only return
zero below sound/soc. There is no reason to have these, as the only
caller is platform core code doing:

if (drv->remove) {
int ret = drv->remove(dev);

...
}

(in platform_remove()) and so having no remove function is both
equivalent and simpler.

-86
-8
sound/soc/amd/raven/acp3x-i2s.c
··· 315 315 return 0; 316 316 } 317 317 318 - static int acp3x_dai_remove(struct platform_device *pdev) 319 - { 320 - /* As we use devm_ memory alloc there is nothing TBD here */ 321 - 322 - return 0; 323 - } 324 - 325 318 static struct platform_driver acp3x_dai_driver = { 326 319 .probe = acp3x_dai_probe, 327 - .remove = acp3x_dai_remove, 328 320 .driver = { 329 321 .name = "acp3x_i2s_playcap", 330 322 },
-6
sound/soc/atmel/atmel-classd.c
··· 616 616 return ret; 617 617 } 618 618 619 - static int atmel_classd_remove(struct platform_device *pdev) 620 - { 621 - return 0; 622 - } 623 - 624 619 static struct platform_driver atmel_classd_driver = { 625 620 .driver = { 626 621 .name = "atmel-classd", ··· 623 628 .pm = &snd_soc_pm_ops, 624 629 }, 625 630 .probe = atmel_classd_probe, 626 - .remove = atmel_classd_remove, 627 631 }; 628 632 module_platform_driver(atmel_classd_driver); 629 633
-6
sound/soc/atmel/atmel-pdmic.c
··· 692 692 return ret; 693 693 } 694 694 695 - static int atmel_pdmic_remove(struct platform_device *pdev) 696 - { 697 - return 0; 698 - } 699 - 700 695 static struct platform_driver atmel_pdmic_driver = { 701 696 .driver = { 702 697 .name = "atmel-pdmic", ··· 699 704 .pm = &snd_soc_pm_ops, 700 705 }, 701 706 .probe = atmel_pdmic_probe, 702 - .remove = atmel_pdmic_remove, 703 707 }; 704 708 module_platform_driver(atmel_pdmic_driver); 705 709
-6
sound/soc/codecs/88pm860x-codec.c
··· 1386 1386 return ret; 1387 1387 } 1388 1388 1389 - static int pm860x_codec_remove(struct platform_device *pdev) 1390 - { 1391 - return 0; 1392 - } 1393 - 1394 1389 static struct platform_driver pm860x_codec_driver = { 1395 1390 .driver = { 1396 1391 .name = "88pm860x-codec", 1397 1392 }, 1398 1393 .probe = pm860x_codec_probe, 1399 - .remove = pm860x_codec_remove, 1400 1394 }; 1401 1395 1402 1396 module_platform_driver(pm860x_codec_driver);
-6
sound/soc/codecs/ac97.c
··· 127 127 &soc_component_dev_ac97, &ac97_dai, 1); 128 128 } 129 129 130 - static int ac97_remove(struct platform_device *pdev) 131 - { 132 - return 0; 133 - } 134 - 135 130 static struct platform_driver ac97_codec_driver = { 136 131 .driver = { 137 132 .name = "ac97-codec", 138 133 }, 139 134 140 135 .probe = ac97_probe, 141 - .remove = ac97_remove, 142 136 }; 143 137 144 138 module_platform_driver(ac97_codec_driver);
-6
sound/soc/codecs/adau7002.c
··· 100 100 &adau7002_dai, 1); 101 101 } 102 102 103 - static int adau7002_remove(struct platform_device *pdev) 104 - { 105 - return 0; 106 - } 107 - 108 103 #ifdef CONFIG_OF 109 104 static const struct of_device_id adau7002_dt_ids[] = { 110 105 { .compatible = "adi,adau7002", }, ··· 123 128 .acpi_match_table = ACPI_PTR(adau7002_acpi_match), 124 129 }, 125 130 .probe = adau7002_probe, 126 - .remove = adau7002_remove, 127 131 }; 128 132 module_platform_driver(adau7002_driver); 129 133
-6
sound/soc/codecs/bt-sco.c
··· 78 78 bt_sco_dai, ARRAY_SIZE(bt_sco_dai)); 79 79 } 80 80 81 - static int bt_sco_remove(struct platform_device *pdev) 82 - { 83 - return 0; 84 - } 85 - 86 81 static const struct platform_device_id bt_sco_driver_ids[] = { 87 82 { 88 83 .name = "dfbmcs320", ··· 104 109 .of_match_table = of_match_ptr(bt_sco_codec_of_match), 105 110 }, 106 111 .probe = bt_sco_probe, 107 - .remove = bt_sco_remove, 108 112 .id_table = bt_sco_driver_ids, 109 113 }; 110 114
-6
sound/soc/codecs/cq93vc.c
··· 134 134 &soc_component_dev_cq93vc, &cq93vc_dai, 1); 135 135 } 136 136 137 - static int cq93vc_platform_remove(struct platform_device *pdev) 138 - { 139 - return 0; 140 - } 141 - 142 137 static struct platform_driver cq93vc_codec_driver = { 143 138 .driver = { 144 139 .name = "cq93vc-codec", 145 140 }, 146 141 147 142 .probe = cq93vc_platform_probe, 148 - .remove = cq93vc_platform_remove, 149 143 }; 150 144 151 145 module_platform_driver(cq93vc_codec_driver);
-6
sound/soc/codecs/mc13783.c
··· 776 776 return ret; 777 777 } 778 778 779 - static int mc13783_codec_remove(struct platform_device *pdev) 780 - { 781 - return 0; 782 - } 783 - 784 779 static struct platform_driver mc13783_codec_driver = { 785 780 .driver = { 786 781 .name = "mc13783-codec", 787 782 }, 788 - .remove = mc13783_codec_remove, 789 783 }; 790 784 module_platform_driver_probe(mc13783_codec_driver, mc13783_codec_probe); 791 785
-6
sound/soc/codecs/wl1273.c
··· 484 484 &wl1273_dai, 1); 485 485 } 486 486 487 - static int wl1273_platform_remove(struct platform_device *pdev) 488 - { 489 - return 0; 490 - } 491 - 492 487 MODULE_ALIAS("platform:wl1273-codec"); 493 488 494 489 static struct platform_driver wl1273_platform_driver = { ··· 491 496 .name = "wl1273-codec", 492 497 }, 493 498 .probe = wl1273_platform_probe, 494 - .remove = wl1273_platform_remove, 495 499 }; 496 500 497 501 module_platform_driver(wl1273_platform_driver);
-6
sound/soc/pxa/e740_wm9705.c
··· 145 145 return ret; 146 146 } 147 147 148 - static int e740_remove(struct platform_device *pdev) 149 - { 150 - return 0; 151 - } 152 - 153 148 static struct platform_driver e740_driver = { 154 149 .driver = { 155 150 .name = "e740-audio", 156 151 .pm = &snd_soc_pm_ops, 157 152 }, 158 153 .probe = e740_probe, 159 - .remove = e740_remove, 160 154 }; 161 155 162 156 module_platform_driver(e740_driver);
-6
sound/soc/pxa/e750_wm9705.c
··· 124 124 return ret; 125 125 } 126 126 127 - static int e750_remove(struct platform_device *pdev) 128 - { 129 - return 0; 130 - } 131 - 132 127 static struct platform_driver e750_driver = { 133 128 .driver = { 134 129 .name = "e750-audio", 135 130 .pm = &snd_soc_pm_ops, 136 131 }, 137 132 .probe = e750_probe, 138 - .remove = e750_remove, 139 133 }; 140 134 141 135 module_platform_driver(e750_driver);
-6
sound/soc/pxa/e800_wm9712.c
··· 124 124 return ret; 125 125 } 126 126 127 - static int e800_remove(struct platform_device *pdev) 128 - { 129 - return 0; 130 - } 131 - 132 127 static struct platform_driver e800_driver = { 133 128 .driver = { 134 129 .name = "e800-audio", 135 130 .pm = &snd_soc_pm_ops, 136 131 }, 137 132 .probe = e800_probe, 138 - .remove = e800_remove, 139 133 }; 140 134 141 135 module_platform_driver(e800_driver);
-6
sound/soc/sof/nocodec.c
··· 103 103 return devm_snd_soc_register_card(&pdev->dev, card); 104 104 } 105 105 106 - static int sof_nocodec_remove(struct platform_device *pdev) 107 - { 108 - return 0; 109 - } 110 - 111 106 static struct platform_driver sof_nocodec_audio = { 112 107 .probe = sof_nocodec_probe, 113 - .remove = sof_nocodec_remove, 114 108 .driver = { 115 109 .name = "sof-nocodec", 116 110 .pm = &snd_soc_pm_ops,