Re: [PATCH] mmc: cavium-octeon: Convert to use module_platform_driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 19 August 2017 at 15:06, Axel Lin <axel.lin@xxxxxxxxxx> wrote:
> Get rid of boilerplate code by using module_platform_driver macro.
>
> Signed-off-by: Axel Lin <axel.lin@xxxxxxxxxx>

Thanks, applied for next!

Kind regards
Uffe

> ---
>  drivers/mmc/host/cavium-octeon.c | 13 +------------
>  1 file changed, 1 insertion(+), 12 deletions(-)
>
> diff --git a/drivers/mmc/host/cavium-octeon.c b/drivers/mmc/host/cavium-octeon.c
> index 951d2cd..22aded1 100644
> --- a/drivers/mmc/host/cavium-octeon.c
> +++ b/drivers/mmc/host/cavium-octeon.c
> @@ -342,18 +342,7 @@ static struct platform_driver octeon_mmc_driver = {
>         },
>  };
>
> -static int __init octeon_mmc_init(void)
> -{
> -       return platform_driver_register(&octeon_mmc_driver);
> -}
> -
> -static void __exit octeon_mmc_cleanup(void)
> -{
> -       platform_driver_unregister(&octeon_mmc_driver);
> -}
> -
> -module_init(octeon_mmc_init);
> -module_exit(octeon_mmc_cleanup);
> +module_platform_driver(octeon_mmc_driver);
>
>  MODULE_AUTHOR("Cavium Inc. <support@xxxxxxxxxx>");
>  MODULE_DESCRIPTION("Low-level driver for Cavium OCTEON MMC/SSD card");
> --
> 2.9.3
>
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux