diff options
-rw-r--r-- | drivers/tty/serial/jsm/jsm_cls.c | 2 | ||||
-rw-r--r-- | drivers/tty/serial/jsm/jsm_neo.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/drivers/tty/serial/jsm/jsm_cls.c b/drivers/tty/serial/jsm/jsm_cls.c index bfb0681195b6..4eb12a9cae76 100644 --- a/drivers/tty/serial/jsm/jsm_cls.c +++ b/drivers/tty/serial/jsm/jsm_cls.c | |||
@@ -570,7 +570,7 @@ static inline void cls_parse_isr(struct jsm_board *brd, uint port) | |||
570 | * verified in the interrupt routine. | 570 | * verified in the interrupt routine. |
571 | */ | 571 | */ |
572 | 572 | ||
573 | if (port > brd->nasync) | 573 | if (port >= brd->nasync) |
574 | return; | 574 | return; |
575 | 575 | ||
576 | ch = brd->channels[port]; | 576 | ch = brd->channels[port]; |
diff --git a/drivers/tty/serial/jsm/jsm_neo.c b/drivers/tty/serial/jsm/jsm_neo.c index 7291c2117daa..932b2accd06f 100644 --- a/drivers/tty/serial/jsm/jsm_neo.c +++ b/drivers/tty/serial/jsm/jsm_neo.c | |||
@@ -724,7 +724,7 @@ static inline void neo_parse_isr(struct jsm_board *brd, u32 port) | |||
724 | if (!brd) | 724 | if (!brd) |
725 | return; | 725 | return; |
726 | 726 | ||
727 | if (port > brd->maxports) | 727 | if (port >= brd->maxports) |
728 | return; | 728 | return; |
729 | 729 | ||
730 | ch = brd->channels[port]; | 730 | ch = brd->channels[port]; |
@@ -840,7 +840,7 @@ static inline void neo_parse_lsr(struct jsm_board *brd, u32 port) | |||
840 | if (!brd) | 840 | if (!brd) |
841 | return; | 841 | return; |
842 | 842 | ||
843 | if (port > brd->maxports) | 843 | if (port >= brd->maxports) |
844 | return; | 844 | return; |
845 | 845 | ||
846 | ch = brd->channels[port]; | 846 | ch = brd->channels[port]; |
@@ -1180,7 +1180,7 @@ static irqreturn_t neo_intr(int irq, void *voidbrd) | |||
1180 | */ | 1180 | */ |
1181 | 1181 | ||
1182 | /* Verify the port is in range. */ | 1182 | /* Verify the port is in range. */ |
1183 | if (port > brd->nasync) | 1183 | if (port >= brd->nasync) |
1184 | continue; | 1184 | continue; |
1185 | 1185 | ||
1186 | ch = brd->channels[port]; | 1186 | ch = brd->channels[port]; |