Re: [PATCH] mmc: convert drivers/mmc/host/* to use module_platform_driver()

From: viresh kumar
Date: Sun Nov 27 2011 - 08:42:57 EST


On Sat, Nov 26, 2011 at 10:25 AM, Axel Lin <axel.lin@xxxxxxxxx> wrote:
> This patch converts the drivers in drivers/mmc/host/* to use the
> module_platform_driver() macro which makes the code smaller and a bit
> simpler.
>
> Cc: "MichaÅ MirosÅaw" <mirq-linux@xxxxxxxxxxxx>
> Cc: David Brown <davidb@xxxxxxxxxxxxxx>
> Cc: Ben Dooks <ben-linux@xxxxxxxxx>
> Cc: Viresh Kumar <viresh.kumar@xxxxxx>
> Cc: Guennadi Liakhovetski <g.liakhovetski@xxxxxx>
> Cc: Ian Molton <ian@xxxxxxxxxxxxxx>
> Cc: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
> Cc: Wolfram Sang <w.sang@xxxxxxxxxxxxxx>
> Cc: Grant Likely <grant.likely@xxxxxxxxxxxx>
> Cc: Anton Vorontsov <cbouatmailru@xxxxxxxxx>
> Cc: Linus Walleij <linus.walleij@xxxxxxxxxx>
> Signed-off-by: Axel Lin <axel.lin@xxxxxxxxx>
> ---
> Âdrivers/mmc/host/bfin_sdh.c    Â|  12 +-----------
> Âdrivers/mmc/host/cb710-mmc.c    |  13 +------------
> Âdrivers/mmc/host/jz4740_mmc.c   Â|  12 +-----------
> Âdrivers/mmc/host/msm_sdcc.c    Â|  13 +------------
> Âdrivers/mmc/host/mxcmmc.c     Â|  13 +------------
> Âdrivers/mmc/host/mxs-mmc.c     |  13 +------------
> Âdrivers/mmc/host/pxamci.c     Â|  13 +------------
> Âdrivers/mmc/host/s3cmci.c     Â|  13 +------------
> Âdrivers/mmc/host/sdhci-cns3xxx.c  |  12 +-----------
> Âdrivers/mmc/host/sdhci-dove.c   Â|  12 +-----------
> Âdrivers/mmc/host/sdhci-esdhc-imx.c | Â 12 +-----------
> Âdrivers/mmc/host/sdhci-of-esdhc.c Â| Â 12 +-----------
> Âdrivers/mmc/host/sdhci-of-hlwd.c  |  12 +-----------
> Âdrivers/mmc/host/sdhci-pxav2.c   |  12 +-----------
> Âdrivers/mmc/host/sdhci-pxav3.c   |  12 +-----------
> Âdrivers/mmc/host/sdhci-s3c.c    |  13 +------------
> Âdrivers/mmc/host/sdhci-spear.c   |  12 +-----------
> Âdrivers/mmc/host/sdhci-tegra.c   |  12 +-----------
> Âdrivers/mmc/host/sh_mmcif.c    Â|  14 +-------------
> Âdrivers/mmc/host/sh_mobile_sdhi.c Â| Â 13 +------------
> Âdrivers/mmc/host/tmio_mmc.c    Â|  14 +-------------
> Â21 files changed, 21 insertions(+), 243 deletions(-)
>

> diff --git a/drivers/mmc/host/sdhci-spear.c b/drivers/mmc/host/sdhci-spear.c
> index dee70b6..883548e 100644
> --- a/drivers/mmc/host/sdhci-spear.c
> +++ b/drivers/mmc/host/sdhci-spear.c
> @@ -320,17 +320,7 @@ static struct platform_driver sdhci_driver = {
>    Â.remove     = __devexit_p(sdhci_remove),
> Â};
>
> -static int __init sdhci_init(void)
> -{
> - Â Â Â return platform_driver_register(&sdhci_driver);
> -}
> -module_init(sdhci_init);
> -
> -static void __exit sdhci_exit(void)
> -{
> - Â Â Â platform_driver_unregister(&sdhci_driver);
> -}
> -module_exit(sdhci_exit);
> +module_platform_driver(sdhci_driver);
>
> ÂMODULE_DESCRIPTION("SPEAr Secure Digital Host Controller Interface driver");
> ÂMODULE_AUTHOR("Viresh Kumar <viresh.kumar@xxxxxx>");

For SPEAr:

Acked-by: Viresh Kumar <viresh.linux@xxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/