Skip to content

Commit 3905fb8

Browse files
bvanasscheKAGA-KOKO
authored andcommitted
serial: amba-pl010: Switch to irq_get_nr_irqs()
Use the irq_get_nr_irqs() function instead of the global variable 'nr_irqs'. Prepare for changing 'nr_irqs' from an exported global variable into a variable with file scope. Signed-off-by: Bart Van Assche <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Link: https://lore.kernel.org/all/[email protected]
1 parent 4846c4c commit 3905fb8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/tty/serial/amba-pl010.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -499,7 +499,7 @@ static int pl010_verify_port(struct uart_port *port, struct serial_struct *ser)
499499
int ret = 0;
500500
if (ser->type != PORT_UNKNOWN && ser->type != PORT_AMBA)
501501
ret = -EINVAL;
502-
if (ser->irq < 0 || ser->irq >= nr_irqs)
502+
if (ser->irq < 0 || ser->irq >= irq_get_nr_irqs())
503503
ret = -EINVAL;
504504
if (ser->baud_base < 9600)
505505
ret = -EINVAL;

0 commit comments

Comments
 (0)