Commit c36a4e40 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven

m68k: vme_scc - Kill warn_unused_result warnings

warning: ignoring return value of 'request_irq', declared with attribute
warn_unused_result
Signed-off-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Acked-by: default avatarAlan Cox <alan@lxorguk.ukuu.org.uk>
parent 07e449b5
...@@ -198,6 +198,7 @@ static void scc_init_portstructs(void) ...@@ -198,6 +198,7 @@ static void scc_init_portstructs(void)
static int mvme147_scc_init(void) static int mvme147_scc_init(void)
{ {
struct scc_port *port; struct scc_port *port;
int error;
printk(KERN_INFO "SCC: MVME147 Serial Driver\n"); printk(KERN_INFO "SCC: MVME147 Serial Driver\n");
/* Init channel A */ /* Init channel A */
...@@ -207,14 +208,23 @@ static int mvme147_scc_init(void) ...@@ -207,14 +208,23 @@ static int mvme147_scc_init(void)
port->datap = port->ctrlp + 1; port->datap = port->ctrlp + 1;
port->port_a = &scc_ports[0]; port->port_a = &scc_ports[0];
port->port_b = &scc_ports[1]; port->port_b = &scc_ports[1];
request_irq(MVME147_IRQ_SCCA_TX, scc_tx_int, IRQF_DISABLED, error = request_irq(MVME147_IRQ_SCCA_TX, scc_tx_int, IRQF_DISABLED,
"SCC-A TX", port); "SCC-A TX", port);
request_irq(MVME147_IRQ_SCCA_STAT, scc_stat_int, IRQF_DISABLED, if (error)
goto fail;
error = request_irq(MVME147_IRQ_SCCA_STAT, scc_stat_int, IRQF_DISABLED,
"SCC-A status", port); "SCC-A status", port);
request_irq(MVME147_IRQ_SCCA_RX, scc_rx_int, IRQF_DISABLED, if (error)
goto fail_free_a_tx;
error = request_irq(MVME147_IRQ_SCCA_RX, scc_rx_int, IRQF_DISABLED,
"SCC-A RX", port); "SCC-A RX", port);
request_irq(MVME147_IRQ_SCCA_SPCOND, scc_spcond_int, IRQF_DISABLED, if (error)
"SCC-A special cond", port); goto fail_free_a_stat;
error = request_irq(MVME147_IRQ_SCCA_SPCOND, scc_spcond_int,
IRQF_DISABLED, "SCC-A special cond", port);
if (error)
goto fail_free_a_rx;
{ {
SCC_ACCESS_INIT(port); SCC_ACCESS_INIT(port);
...@@ -234,14 +244,23 @@ static int mvme147_scc_init(void) ...@@ -234,14 +244,23 @@ static int mvme147_scc_init(void)
port->datap = port->ctrlp + 1; port->datap = port->ctrlp + 1;
port->port_a = &scc_ports[0]; port->port_a = &scc_ports[0];
port->port_b = &scc_ports[1]; port->port_b = &scc_ports[1];
request_irq(MVME147_IRQ_SCCB_TX, scc_tx_int, IRQF_DISABLED, error = request_irq(MVME147_IRQ_SCCB_TX, scc_tx_int, IRQF_DISABLED,
"SCC-B TX", port); "SCC-B TX", port);
request_irq(MVME147_IRQ_SCCB_STAT, scc_stat_int, IRQF_DISABLED, if (error)
goto fail_free_a_spcond;
error = request_irq(MVME147_IRQ_SCCB_STAT, scc_stat_int, IRQF_DISABLED,
"SCC-B status", port); "SCC-B status", port);
request_irq(MVME147_IRQ_SCCB_RX, scc_rx_int, IRQF_DISABLED, if (error)
goto fail_free_b_tx;
error = request_irq(MVME147_IRQ_SCCB_RX, scc_rx_int, IRQF_DISABLED,
"SCC-B RX", port); "SCC-B RX", port);
request_irq(MVME147_IRQ_SCCB_SPCOND, scc_spcond_int, IRQF_DISABLED, if (error)
"SCC-B special cond", port); goto fail_free_b_stat;
error = request_irq(MVME147_IRQ_SCCB_SPCOND, scc_spcond_int,
IRQF_DISABLED, "SCC-B special cond", port);
if (error)
goto fail_free_b_rx;
{ {
SCC_ACCESS_INIT(port); SCC_ACCESS_INIT(port);
...@@ -257,6 +276,23 @@ static int mvme147_scc_init(void) ...@@ -257,6 +276,23 @@ static int mvme147_scc_init(void)
scc_init_drivers(); scc_init_drivers();
return 0; return 0;
fail_free_b_rx:
free_irq(MVME147_IRQ_SCCB_RX, port);
fail_free_b_stat:
free_irq(MVME147_IRQ_SCCB_STAT, port);
fail_free_b_tx:
free_irq(MVME147_IRQ_SCCB_TX, port);
fail_free_a_spcond:
free_irq(MVME147_IRQ_SCCA_SPCOND, port);
fail_free_a_rx:
free_irq(MVME147_IRQ_SCCA_RX, port);
fail_free_a_stat:
free_irq(MVME147_IRQ_SCCA_STAT, port);
fail_free_a_tx:
free_irq(MVME147_IRQ_SCCA_TX, port);
fail:
return error;
} }
#endif #endif
...@@ -265,6 +301,7 @@ static int mvme147_scc_init(void) ...@@ -265,6 +301,7 @@ static int mvme147_scc_init(void)
static int mvme162_scc_init(void) static int mvme162_scc_init(void)
{ {
struct scc_port *port; struct scc_port *port;
int error;
if (!(mvme16x_config & MVME16x_CONFIG_GOT_SCCA)) if (!(mvme16x_config & MVME16x_CONFIG_GOT_SCCA))
return (-ENODEV); return (-ENODEV);
...@@ -277,14 +314,23 @@ static int mvme162_scc_init(void) ...@@ -277,14 +314,23 @@ static int mvme162_scc_init(void)
port->datap = port->ctrlp + 2; port->datap = port->ctrlp + 2;
port->port_a = &scc_ports[0]; port->port_a = &scc_ports[0];
port->port_b = &scc_ports[1]; port->port_b = &scc_ports[1];
request_irq(MVME162_IRQ_SCCA_TX, scc_tx_int, IRQF_DISABLED, error = request_irq(MVME162_IRQ_SCCA_TX, scc_tx_int, IRQF_DISABLED,
"SCC-A TX", port); "SCC-A TX", port);
request_irq(MVME162_IRQ_SCCA_STAT, scc_stat_int, IRQF_DISABLED, if (error)
goto fail;
error = request_irq(MVME162_IRQ_SCCA_STAT, scc_stat_int, IRQF_DISABLED,
"SCC-A status", port); "SCC-A status", port);
request_irq(MVME162_IRQ_SCCA_RX, scc_rx_int, IRQF_DISABLED, if (error)
goto fail_free_a_tx;
error = request_irq(MVME162_IRQ_SCCA_RX, scc_rx_int, IRQF_DISABLED,
"SCC-A RX", port); "SCC-A RX", port);
request_irq(MVME162_IRQ_SCCA_SPCOND, scc_spcond_int, IRQF_DISABLED, if (error)
"SCC-A special cond", port); goto fail_free_a_stat;
error = request_irq(MVME162_IRQ_SCCA_SPCOND, scc_spcond_int,
IRQF_DISABLED, "SCC-A special cond", port);
if (error)
goto fail_free_a_rx;
{ {
SCC_ACCESS_INIT(port); SCC_ACCESS_INIT(port);
...@@ -304,14 +350,22 @@ static int mvme162_scc_init(void) ...@@ -304,14 +350,22 @@ static int mvme162_scc_init(void)
port->datap = port->ctrlp + 2; port->datap = port->ctrlp + 2;
port->port_a = &scc_ports[0]; port->port_a = &scc_ports[0];
port->port_b = &scc_ports[1]; port->port_b = &scc_ports[1];
request_irq(MVME162_IRQ_SCCB_TX, scc_tx_int, IRQF_DISABLED, error = request_irq(MVME162_IRQ_SCCB_TX, scc_tx_int, IRQF_DISABLED,
"SCC-B TX", port); "SCC-B TX", port);
request_irq(MVME162_IRQ_SCCB_STAT, scc_stat_int, IRQF_DISABLED, if (error)
goto fail_free_a_spcond;
error = request_irq(MVME162_IRQ_SCCB_STAT, scc_stat_int, IRQF_DISABLED,
"SCC-B status", port); "SCC-B status", port);
request_irq(MVME162_IRQ_SCCB_RX, scc_rx_int, IRQF_DISABLED, if (error)
goto fail_free_b_tx;
error = request_irq(MVME162_IRQ_SCCB_RX, scc_rx_int, IRQF_DISABLED,
"SCC-B RX", port); "SCC-B RX", port);
request_irq(MVME162_IRQ_SCCB_SPCOND, scc_spcond_int, IRQF_DISABLED, if (error)
"SCC-B special cond", port); goto fail_free_b_stat;
error = request_irq(MVME162_IRQ_SCCB_SPCOND, scc_spcond_int,
IRQF_DISABLED, "SCC-B special cond", port);
if (error)
goto fail_free_b_rx;
{ {
SCC_ACCESS_INIT(port); /* Either channel will do */ SCC_ACCESS_INIT(port); /* Either channel will do */
...@@ -328,6 +382,23 @@ static int mvme162_scc_init(void) ...@@ -328,6 +382,23 @@ static int mvme162_scc_init(void)
scc_init_drivers(); scc_init_drivers();
return 0; return 0;
fail_free_b_rx:
free_irq(MVME162_IRQ_SCCB_RX, port);
fail_free_b_stat:
free_irq(MVME162_IRQ_SCCB_STAT, port);
fail_free_b_tx:
free_irq(MVME162_IRQ_SCCB_TX, port);
fail_free_a_spcond:
free_irq(MVME162_IRQ_SCCA_SPCOND, port);
fail_free_a_rx:
free_irq(MVME162_IRQ_SCCA_RX, port);
fail_free_a_stat:
free_irq(MVME162_IRQ_SCCA_STAT, port);
fail_free_a_tx:
free_irq(MVME162_IRQ_SCCA_TX, port);
fail:
return error;
} }
#endif #endif
...@@ -336,6 +407,7 @@ static int mvme162_scc_init(void) ...@@ -336,6 +407,7 @@ static int mvme162_scc_init(void)
static int bvme6000_scc_init(void) static int bvme6000_scc_init(void)
{ {
struct scc_port *port; struct scc_port *port;
int error;
printk(KERN_INFO "SCC: BVME6000 Serial Driver\n"); printk(KERN_INFO "SCC: BVME6000 Serial Driver\n");
/* Init channel A */ /* Init channel A */
...@@ -345,14 +417,23 @@ static int bvme6000_scc_init(void) ...@@ -345,14 +417,23 @@ static int bvme6000_scc_init(void)
port->datap = port->ctrlp + 4; port->datap = port->ctrlp + 4;
port->port_a = &scc_ports[0]; port->port_a = &scc_ports[0];
port->port_b = &scc_ports[1]; port->port_b = &scc_ports[1];
request_irq(BVME_IRQ_SCCA_TX, scc_tx_int, IRQF_DISABLED, error = request_irq(BVME_IRQ_SCCA_TX, scc_tx_int, IRQF_DISABLED,
"SCC-A TX", port); "SCC-A TX", port);
request_irq(BVME_IRQ_SCCA_STAT, scc_stat_int, IRQF_DISABLED, if (error)
goto fail;
error = request_irq(BVME_IRQ_SCCA_STAT, scc_stat_int, IRQF_DISABLED,
"SCC-A status", port); "SCC-A status", port);
request_irq(BVME_IRQ_SCCA_RX, scc_rx_int, IRQF_DISABLED, if (error)
goto fail_free_a_tx;
error = request_irq(BVME_IRQ_SCCA_RX, scc_rx_int, IRQF_DISABLED,
"SCC-A RX", port); "SCC-A RX", port);
request_irq(BVME_IRQ_SCCA_SPCOND, scc_spcond_int, IRQF_DISABLED, if (error)
"SCC-A special cond", port); goto fail_free_a_stat;
error = request_irq(BVME_IRQ_SCCA_SPCOND, scc_spcond_int,
IRQF_DISABLED, "SCC-A special cond", port);
if (error)
goto fail_free_a_rx;
{ {
SCC_ACCESS_INIT(port); SCC_ACCESS_INIT(port);
...@@ -372,14 +453,22 @@ static int bvme6000_scc_init(void) ...@@ -372,14 +453,22 @@ static int bvme6000_scc_init(void)
port->datap = port->ctrlp + 4; port->datap = port->ctrlp + 4;
port->port_a = &scc_ports[0]; port->port_a = &scc_ports[0];
port->port_b = &scc_ports[1]; port->port_b = &scc_ports[1];
request_irq(BVME_IRQ_SCCB_TX, scc_tx_int, IRQF_DISABLED, error = request_irq(BVME_IRQ_SCCB_TX, scc_tx_int, IRQF_DISABLED,
"SCC-B TX", port); "SCC-B TX", port);
request_irq(BVME_IRQ_SCCB_STAT, scc_stat_int, IRQF_DISABLED, if (error)
goto fail_free_a_spcond;
error = request_irq(BVME_IRQ_SCCB_STAT, scc_stat_int, IRQF_DISABLED,
"SCC-B status", port); "SCC-B status", port);
request_irq(BVME_IRQ_SCCB_RX, scc_rx_int, IRQF_DISABLED, if (error)
goto fail_free_b_tx;
error = request_irq(BVME_IRQ_SCCB_RX, scc_rx_int, IRQF_DISABLED,
"SCC-B RX", port); "SCC-B RX", port);
request_irq(BVME_IRQ_SCCB_SPCOND, scc_spcond_int, IRQF_DISABLED, if (error)
"SCC-B special cond", port); goto fail_free_b_stat;
error = request_irq(BVME_IRQ_SCCB_SPCOND, scc_spcond_int,
IRQF_DISABLED, "SCC-B special cond", port);
if (error)
goto fail_free_b_rx;
{ {
SCC_ACCESS_INIT(port); /* Either channel will do */ SCC_ACCESS_INIT(port); /* Either channel will do */
...@@ -393,6 +482,23 @@ static int bvme6000_scc_init(void) ...@@ -393,6 +482,23 @@ static int bvme6000_scc_init(void)
scc_init_drivers(); scc_init_drivers();
return 0; return 0;
fail:
free_irq(BVME_IRQ_SCCA_STAT, port);
fail_free_a_tx:
free_irq(BVME_IRQ_SCCA_RX, port);
fail_free_a_stat:
free_irq(BVME_IRQ_SCCA_SPCOND, port);
fail_free_a_rx:
free_irq(BVME_IRQ_SCCB_TX, port);
fail_free_a_spcond:
free_irq(BVME_IRQ_SCCB_STAT, port);
fail_free_b_tx:
free_irq(BVME_IRQ_SCCB_RX, port);
fail_free_b_stat:
free_irq(BVME_IRQ_SCCB_SPCOND, port);
fail_free_b_rx:
return error;
} }
#endif #endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment