summaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/lantiq.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty/serial/lantiq.c')
-rw-r--r--drivers/tty/serial/lantiq.c24
1 files changed, 14 insertions, 10 deletions
diff --git a/drivers/tty/serial/lantiq.c b/drivers/tty/serial/lantiq.c
index bb059418cb82..3e324d3f0a6d 100644
--- a/drivers/tty/serial/lantiq.c
+++ b/drivers/tty/serial/lantiq.c
@@ -727,16 +727,20 @@ static int fetch_irq_lantiq(struct device *dev, struct ltq_uart_port *ltq_port)
{
struct uart_port *port = &ltq_port->port;
struct platform_device *pdev = to_platform_device(dev);
-
- ltq_port->tx_irq = platform_get_irq(pdev, 0);
- if (ltq_port->tx_irq < 0)
- return ltq_port->tx_irq;
- ltq_port->rx_irq = platform_get_irq(pdev, 1);
- if (ltq_port->rx_irq < 0)
- return ltq_port->rx_irq;
- ltq_port->err_irq = platform_get_irq(pdev, 2);
- if (ltq_port->err_irq < 0)
- return ltq_port->err_irq;
+ int irq;
+
+ irq = platform_get_irq(pdev, 0);
+ if (irq < 0)
+ return irq;
+ ltq_port->tx_irq = irq;
+ irq = platform_get_irq(pdev, 1);
+ if (irq < 0)
+ return irq;
+ ltq_port->rx_irq = irq;
+ irq = platform_get_irq(pdev, 2);
+ if (irq < 0)
+ return irq;
+ ltq_port->err_irq = irq;
port->irq = ltq_port->tx_irq;