From: Laurent Pinchart Date: Fri, 6 Dec 2013 09:59:13 +0000 (+0100) Subject: serial: sh-sci: Remove duplicate interrupt check in verify port op X-Git-Tag: accepted/tizen/common/20141203.182822~739^2~2^2~7 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b5e17b71c6b2ff284b4018e272e18876ccfa9b2c;p=platform%2Fkernel%2Flinux-arm64.git serial: sh-sci: Remove duplicate interrupt check in verify port op The driver checks if the interrupt number is greater than nr_irqs and returns an error in that case. The same check is already performed by the caller, remove it. Signed-off-by: Laurent Pinchart Acked-by: Greg Kroah-Hartman Signed-off-by: Simon Horman --- diff --git a/drivers/tty/serial/sh-sci.c b/drivers/tty/serial/sh-sci.c index f2fad4d..8c17d55 100644 --- a/drivers/tty/serial/sh-sci.c +++ b/drivers/tty/serial/sh-sci.c @@ -2120,7 +2120,7 @@ static int sci_verify_port(struct uart_port *port, struct serial_struct *ser) { struct sci_port *s = to_sci_port(port); - if (ser->irq != s->cfg->irqs[SCIx_TXI_IRQ] || ser->irq > nr_irqs) + if (ser->irq != s->cfg->irqs[SCIx_TXI_IRQ]) return -EINVAL; if (ser->baud_base < 2400) /* No paper tape reader for Mitch.. */