From 86371d071bc38a181984b01d323b6172a4b7bb1f Mon Sep 17 00:00:00 2001 From: Sascha Hauer Date: Mon, 10 Oct 2005 10:17:42 +0100 Subject: [ARM] 2957/1: imx UART Error handling Patch from Sascha Hauer Fix error path in imx_startup. Signed-off-by: Giancarlo Formicuccia Signed-off-by: Sascha Hauer Signed-off-by: Russell King --- drivers/serial/imx.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'drivers') diff --git a/drivers/serial/imx.c b/drivers/serial/imx.c index 4e1e80adaf11..53e0323d4b83 100644 --- a/drivers/serial/imx.c +++ b/drivers/serial/imx.c @@ -383,11 +383,11 @@ static int imx_startup(struct uart_port *port) */ retval = request_irq(sport->rxirq, imx_rxint, 0, DRIVER_NAME, sport); - if (retval) goto error_out2; + if (retval) goto error_out1; retval = request_irq(sport->txirq, imx_txint, 0, "imx-uart", sport); - if (retval) goto error_out1; + if (retval) goto error_out2; /* * Finally, clear and enable interrupts @@ -406,10 +406,9 @@ static int imx_startup(struct uart_port *port) return 0; -error_out1: - free_irq(sport->rxirq, sport); error_out2: - free_irq(sport->txirq, sport); + free_irq(sport->rxirq, sport); +error_out1: return retval; } -- cgit v1.2.3 From cdfc8f5079fdd18f6cb8097aa4235704d1155ec5 Mon Sep 17 00:00:00 2001 From: Ben Dooks Date: Mon, 10 Oct 2005 10:20:06 +0100 Subject: [ARM] 2963/1: S3C2410 - add .owner field to device_driver Patch from Ben Dooks Add initialisation of .owner field so that the device driver can be referenced to the module that owns it. Signed-off-by: Ben Dooks Signed-off-by: Russell King --- drivers/char/s3c2410-rtc.c | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers') diff --git a/drivers/char/s3c2410-rtc.c b/drivers/char/s3c2410-rtc.c index ed867db550a9..e1a90d9a8756 100644 --- a/drivers/char/s3c2410-rtc.c +++ b/drivers/char/s3c2410-rtc.c @@ -564,6 +564,7 @@ static int s3c2410_rtc_resume(struct device *dev, u32 level) static struct device_driver s3c2410_rtcdrv = { .name = "s3c2410-rtc", + .owner = THIS_MODULE, .bus = &platform_bus_type, .probe = s3c2410_rtc_probe, .remove = s3c2410_rtc_remove, -- cgit v1.2.3 From 7dead80cbee3259e3a9f25bfc65c8dc769a19e0e Mon Sep 17 00:00:00 2001 From: Ben Dooks Date: Mon, 10 Oct 2005 10:20:07 +0100 Subject: [ARM] 2964/1: S3C2410 - serial: add .owner to driver Patch from Ben Dooks Initialise the driver's .owner field so that the device driver can be referenced to the module that owns it Signed-off-by: Ben Dooks Signed-off-by: Russell King --- drivers/serial/s3c2410.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers') diff --git a/drivers/serial/s3c2410.c b/drivers/serial/s3c2410.c index 50d7870d92bb..eff2158024c8 100644 --- a/drivers/serial/s3c2410.c +++ b/drivers/serial/s3c2410.c @@ -1235,6 +1235,7 @@ static int s3c2400_serial_probe(struct device *dev) static struct device_driver s3c2400_serial_drv = { .name = "s3c2400-uart", + .owner = THIS_MODULE, .bus = &platform_bus_type, .probe = s3c2400_serial_probe, .remove = s3c24xx_serial_remove, @@ -1338,6 +1339,7 @@ static int s3c2410_serial_probe(struct device *dev) static struct device_driver s3c2410_serial_drv = { .name = "s3c2410-uart", + .owner = THIS_MODULE, .bus = &platform_bus_type, .probe = s3c2410_serial_probe, .remove = s3c24xx_serial_remove, @@ -1499,6 +1501,7 @@ static int s3c2440_serial_probe(struct device *dev) static struct device_driver s3c2440_serial_drv = { .name = "s3c2440-uart", + .owner = THIS_MODULE, .bus = &platform_bus_type, .probe = s3c2440_serial_probe, .remove = s3c24xx_serial_remove, -- cgit v1.2.3