diff options
author | Philipp Zabel <philipp.zabel@gmail.com> | 2008-06-21 00:51:38 +0200 |
---|---|---|
committer | Samuel Ortiz <samuel@sortiz.org> | 2008-07-20 19:55:30 +0200 |
commit | 065032f61bd9acdb843766da3149de12eaf87c0b (patch) | |
tree | 759d3edd6e98cca410ed42774d34945c6d04a0b7 /drivers/mfd/asic3.c | |
parent | 3b8139f8b1457af7b5295d97050b3f9a2545a17a (diff) | |
download | talos-op-linux-065032f61bd9acdb843766da3149de12eaf87c0b.tar.gz talos-op-linux-065032f61bd9acdb843766da3149de12eaf87c0b.zip |
mfd: move asic3 probe functions into __init section
Potentially free some memory by moving the _probe functions into __init.
Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@openedhand.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'drivers/mfd/asic3.c')
-rw-r--r-- | drivers/mfd/asic3.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/mfd/asic3.c b/drivers/mfd/asic3.c index 9931581b08a1..80dc3334e82f 100644 --- a/drivers/mfd/asic3.c +++ b/drivers/mfd/asic3.c @@ -308,7 +308,7 @@ static struct irq_chip asic3_irq_chip = { .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); unsigned long clksel = 0; @@ -464,8 +464,8 @@ static void asic3_gpio_set(struct gpio_chip *chip, return; } -static int asic3_gpio_probe(struct platform_device *pdev, - u16 *gpio_config, int num) +static __init int asic3_gpio_probe(struct platform_device *pdev, + u16 *gpio_config, int num) { struct asic3 *asic = platform_get_drvdata(pdev); u16 alt_reg[ASIC3_NUM_GPIO_BANKS]; @@ -526,7 +526,7 @@ static int asic3_gpio_remove(struct platform_device *pdev) /* 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 *asic; @@ -633,7 +633,6 @@ static struct platform_driver asic3_device_driver = { .driver = { .name = "asic3", }, - .probe = asic3_probe, .remove = __devexit_p(asic3_remove), .shutdown = asic3_shutdown, }; @@ -641,7 +640,7 @@ static struct platform_driver asic3_device_driver = { static int __init asic3_init(void) { int retval = 0; - retval = platform_driver_register(&asic3_device_driver); + retval = platform_driver_probe(&asic3_device_driver, asic3_probe); return retval; } |