Commit 065032f6 authored by Philipp Zabel's avatar Philipp Zabel Committed by Samuel Ortiz

mfd: move asic3 probe functions into __init section

Potentially free some memory by moving the _probe functions into __init.
Signed-off-by: default avatarPhilipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: default avatarSamuel Ortiz <sameo@openedhand.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 3b8139f8
...@@ -308,7 +308,7 @@ static struct irq_chip asic3_irq_chip = { ...@@ -308,7 +308,7 @@ static struct irq_chip asic3_irq_chip = {
.unmask = asic3_unmask_irq, .unmask = asic3_unmask_irq,
}; };
static int asic3_irq_probe(struct platform_device *pdev) static int __init asic3_irq_probe(struct platform_device *pdev)
{ {
struct asic3 *asic = platform_get_drvdata(pdev); struct asic3 *asic = platform_get_drvdata(pdev);
unsigned long clksel = 0; unsigned long clksel = 0;
...@@ -464,7 +464,7 @@ static void asic3_gpio_set(struct gpio_chip *chip, ...@@ -464,7 +464,7 @@ static void asic3_gpio_set(struct gpio_chip *chip,
return; return;
} }
static int asic3_gpio_probe(struct platform_device *pdev, static __init int asic3_gpio_probe(struct platform_device *pdev,
u16 *gpio_config, int num) u16 *gpio_config, int num)
{ {
struct asic3 *asic = platform_get_drvdata(pdev); struct asic3 *asic = platform_get_drvdata(pdev);
...@@ -526,7 +526,7 @@ static int asic3_gpio_remove(struct platform_device *pdev) ...@@ -526,7 +526,7 @@ static int asic3_gpio_remove(struct platform_device *pdev)
/* Core */ /* Core */
static int asic3_probe(struct platform_device *pdev) static int __init asic3_probe(struct platform_device *pdev)
{ {
struct asic3_platform_data *pdata = pdev->dev.platform_data; struct asic3_platform_data *pdata = pdev->dev.platform_data;
struct asic3 *asic; struct asic3 *asic;
...@@ -633,7 +633,6 @@ static struct platform_driver asic3_device_driver = { ...@@ -633,7 +633,6 @@ static struct platform_driver asic3_device_driver = {
.driver = { .driver = {
.name = "asic3", .name = "asic3",
}, },
.probe = asic3_probe,
.remove = __devexit_p(asic3_remove), .remove = __devexit_p(asic3_remove),
.shutdown = asic3_shutdown, .shutdown = asic3_shutdown,
}; };
...@@ -641,7 +640,7 @@ static struct platform_driver asic3_device_driver = { ...@@ -641,7 +640,7 @@ static struct platform_driver asic3_device_driver = {
static int __init asic3_init(void) static int __init asic3_init(void)
{ {
int retval = 0; int retval = 0;
retval = platform_driver_register(&asic3_device_driver); retval = platform_driver_probe(&asic3_device_driver, asic3_probe);
return retval; return retval;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment