summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/ad1836.c
diff options
context:
space:
mode:
authorSachin Kamat <sachin.kamat@linaro.org>2012-08-27 17:00:28 +0530
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-08-27 09:55:28 -0700
commit2a9a9c876fd6486978a24cd8bc72bd1aeb228b7b (patch)
treeb55e6a9d833e906532f9705625b7f0737d4c4a56 /sound/soc/codecs/ad1836.c
parenta5c8878017dd3b51f6f97a36d90c405f8061fe83 (diff)
ASoC: ad1836: Use module_spi_driver
module_spi_driver makes the code simpler by eliminating module_init and module_exit calls. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/codecs/ad1836.c')
-rw-r--r--sound/soc/codecs/ad1836.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/sound/soc/codecs/ad1836.c b/sound/soc/codecs/ad1836.c
index c67b50d8b317..ae1eb51bc9da 100644
--- a/sound/soc/codecs/ad1836.c
+++ b/sound/soc/codecs/ad1836.c
@@ -379,17 +379,7 @@ static struct spi_driver ad1836_spi_driver = {
.id_table = ad1836_ids,
};
-static int __init ad1836_init(void)
-{
- return spi_register_driver(&ad1836_spi_driver);
-}
-module_init(ad1836_init);
-
-static void __exit ad1836_exit(void)
-{
- spi_unregister_driver(&ad1836_spi_driver);
-}
-module_exit(ad1836_exit);
+module_spi_driver(ad1836_spi_driver);
MODULE_DESCRIPTION("ASoC ad1836 driver");
MODULE_AUTHOR("Barry Song <21cnbao@gmail.com>");