aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/sunzilog.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty/serial/sunzilog.c')
-rw-r--r--drivers/tty/serial/sunzilog.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/tty/serial/sunzilog.c b/drivers/tty/serial/sunzilog.c
index 8e916e76b7b5..da4415842a43 100644
--- a/drivers/tty/serial/sunzilog.c
+++ b/drivers/tty/serial/sunzilog.c
@@ -43,8 +43,8 @@
43#endif 43#endif
44 44
45#include <linux/serial_core.h> 45#include <linux/serial_core.h>
46#include <linux/sunserialcore.h>
46 47
47#include "suncore.h"
48#include "sunzilog.h" 48#include "sunzilog.h"
49 49
50/* On 32-bit sparcs we need to delay after register accesses 50/* On 32-bit sparcs we need to delay after register accesses
@@ -1397,7 +1397,7 @@ static void __devinit sunzilog_init_hw(struct uart_sunzilog_port *up)
1397#endif 1397#endif
1398} 1398}
1399 1399
1400static int zilog_irq = -1; 1400static int zilog_irq;
1401 1401
1402static int __devinit zs_probe(struct platform_device *op) 1402static int __devinit zs_probe(struct platform_device *op)
1403{ 1403{
@@ -1425,7 +1425,7 @@ static int __devinit zs_probe(struct platform_device *op)
1425 1425
1426 rp = sunzilog_chip_regs[inst]; 1426 rp = sunzilog_chip_regs[inst];
1427 1427
1428 if (zilog_irq == -1) 1428 if (!zilog_irq)
1429 zilog_irq = op->archdata.irqs[0]; 1429 zilog_irq = op->archdata.irqs[0];
1430 1430
1431 up = &sunzilog_port_table[inst * 2]; 1431 up = &sunzilog_port_table[inst * 2];
@@ -1580,7 +1580,7 @@ static int __init sunzilog_init(void)
1580 if (err) 1580 if (err)
1581 goto out_unregister_uart; 1581 goto out_unregister_uart;
1582 1582
1583 if (zilog_irq != -1) { 1583 if (!zilog_irq) {
1584 struct uart_sunzilog_port *up = sunzilog_irq_chain; 1584 struct uart_sunzilog_port *up = sunzilog_irq_chain;
1585 err = request_irq(zilog_irq, sunzilog_interrupt, IRQF_SHARED, 1585 err = request_irq(zilog_irq, sunzilog_interrupt, IRQF_SHARED,
1586 "zs", sunzilog_irq_chain); 1586 "zs", sunzilog_irq_chain);
@@ -1621,7 +1621,7 @@ static void __exit sunzilog_exit(void)
1621{ 1621{
1622 platform_driver_unregister(&zs_driver); 1622 platform_driver_unregister(&zs_driver);
1623 1623
1624 if (zilog_irq != -1) { 1624 if (!zilog_irq) {
1625 struct uart_sunzilog_port *up = sunzilog_irq_chain; 1625 struct uart_sunzilog_port *up = sunzilog_irq_chain;
1626 1626
1627 /* Disable Interrupts */ 1627 /* Disable Interrupts */
@@ -1637,7 +1637,7 @@ static void __exit sunzilog_exit(void)
1637 } 1637 }
1638 1638
1639 free_irq(zilog_irq, sunzilog_irq_chain); 1639 free_irq(zilog_irq, sunzilog_irq_chain);
1640 zilog_irq = -1; 1640 zilog_irq = 0;
1641 } 1641 }
1642 1642
1643 if (sunzilog_reg.nr) { 1643 if (sunzilog_reg.nr) {