From 38ada214fad79ff5ebbed58932c5f0c9969d9c91 Mon Sep 17 00:00:00 2001 From: Yong Zhang Date: Sat, 22 Oct 2011 17:56:55 +0800 Subject: spi: irq: Remove IRQF_DISABLED Since commit [e58aa3d2: genirq: Run irq handlers with interrupts disabled], We run all interrupt handlers with interrupts disabled and we even check and yell when an interrupt handler returns with interrupts enabled (see commit [b738a50a: genirq: Warn when handler enables interrupts]). So now this flag is a NOOP and can be removed. Signed-off-by: Yong Zhang Signed-off-by: Grant Likely --- drivers/spi/spi-sh-msiof.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/spi/spi-sh-msiof.c') diff --git a/drivers/spi/spi-sh-msiof.c b/drivers/spi/spi-sh-msiof.c index e00d94b22250..e38554f89256 100644 --- a/drivers/spi/spi-sh-msiof.c +++ b/drivers/spi/spi-sh-msiof.c @@ -635,7 +635,7 @@ static int sh_msiof_spi_probe(struct platform_device *pdev) goto err2; } - ret = request_irq(i, sh_msiof_spi_irq, IRQF_DISABLED, + ret = request_irq(i, sh_msiof_spi_irq, 0, dev_name(&pdev->dev), p); if (ret) { dev_err(&pdev->dev, "unable to request irq\n"); -- cgit From 940ab88962bc1aff3273a8356d64577a6e386736 Mon Sep 17 00:00:00 2001 From: Grant Likely Date: Wed, 5 Oct 2011 11:29:49 -0600 Subject: drivercore: Add helper macro for platform_driver boilerplate For simple modules that contain a single platform_driver without any additional setup code then ends up being a block of duplicated boilerplate. This patch adds a new macro, module_platform_driver(), which replaces the module_init()/module_exit() registrations with template functions. Signed-off-by: Grant Likely Acked-by: Greg Kroah-Hartman Reviewed-by: Magnus Damm Reviewed-by: Mark Brown Reviewed-by: Stephen Boyd --- drivers/spi/spi-sh-msiof.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'drivers/spi/spi-sh-msiof.c') diff --git a/drivers/spi/spi-sh-msiof.c b/drivers/spi/spi-sh-msiof.c index e38554f89256..0f4834ae28cd 100644 --- a/drivers/spi/spi-sh-msiof.c +++ b/drivers/spi/spi-sh-msiof.c @@ -730,18 +730,7 @@ static struct platform_driver sh_msiof_spi_drv = { .pm = &sh_msiof_spi_dev_pm_ops, }, }; - -static int __init sh_msiof_spi_init(void) -{ - return platform_driver_register(&sh_msiof_spi_drv); -} -module_init(sh_msiof_spi_init); - -static void __exit sh_msiof_spi_exit(void) -{ - platform_driver_unregister(&sh_msiof_spi_drv); -} -module_exit(sh_msiof_spi_exit); +module_platform_driver(sh_msiof_spi_drv); MODULE_DESCRIPTION("SuperH MSIOF SPI Master Interface Driver"); MODULE_AUTHOR("Magnus Damm"); -- cgit