[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACxGe6sAFUwQc5Nk=gGLC+si-_C32AWu=E14vBkSm7YCFhazFg@mail.gmail.com>
Date: Fri, 4 Nov 2011 12:57:09 -0400
From: Grant Likely <grant.likely@...retlab.ca>
To: Rob Herring <robherring2@...il.com>
Cc: netdev@...r.kernel.org, devicetree-discuss@...ts.ozlabs.org,
Rob Herring <rob.herring@...xeda.com>
Subject: Re: [PATCH] net: add calxeda xgmac ethernet driver
On Wed, Oct 26, 2011 at 10:56 PM, Rob Herring <robherring2@...il.com> wrote:
> From: Rob Herring <rob.herring@...xeda.com>
>
> Add support for the XGMAC 10Gb ethernet device in the Calxeda Highbank
> SOC.
>
> Signed-off-by: Rob Herring <rob.herring@...xeda.com>
Sinker question: is this a driver for an entirely new GMAC device
(designed from scratch) or is it based on an existing IP block?
> +/**
> + * xgmac_init - Entry point for the driver
> + * Description: This function is the entry point for the driver.
> + */
> +static int __init xgmac_init(void)
> +{
> + return platform_driver_register(&xgmac_driver);
> +}
> +module_init(xgmac_init);
> +
> +/**
> + * xgmac_cleanup_module - Cleanup routine for the driver
> + * Description: This function is the cleanup routine for the driver.
> + */
> +static void __exit xgmac_exit(void)
> +{
> + platform_driver_unregister(&xgmac_driver);
> +}
> +module_exit(xgmac_exit);
You can drop some boilerplate with module_platform_driver() now.
g.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists