Skip to content

Commit f9066da

Browse files
Jiri Slaby (SUSE)gregkh
authored andcommitted
serial: 8250: make share_irqs local to 8250_platform
share_irqs is used solely in 8250_platform. Make it local to that file. Signed-off-by: Jiri Slaby (SUSE) <jirislaby@kernel.org> Link: https://patch.msgid.link/20251119092457.826789-6-jirislaby@kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 9b22596 commit f9066da

2 files changed

Lines changed: 2 additions & 10 deletions

File tree

drivers/tty/serial/8250/8250.h

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -98,14 +98,6 @@ struct serial8250_config {
9898

9999
extern unsigned int nr_uarts;
100100

101-
#ifdef CONFIG_SERIAL_8250_SHARE_IRQ
102-
#define SERIAL8250_SHARE_IRQS 1
103-
#else
104-
#define SERIAL8250_SHARE_IRQS 0
105-
#endif
106-
107-
extern unsigned int share_irqs;
108-
109101
#define SERIAL8250_PORT_FLAGS(_base, _irq, _flags) \
110102
{ \
111103
.iobase = _base, \

drivers/tty/serial/8250/8250_platform.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
* share_irqs: Whether we pass IRQF_SHARED to request_irq().
3131
* This option is unsafe when used on edge-triggered interrupts.
3232
*/
33-
unsigned int share_irqs = SERIAL8250_SHARE_IRQS;
33+
static bool share_irqs = IS_ENABLED(CONFIG_SERIAL_8250_SHARE_IRQ);
3434

3535
unsigned int nr_uarts = CONFIG_SERIAL_8250_RUNTIME_UARTS;
3636

@@ -378,7 +378,7 @@ module_exit(serial8250_exit);
378378
MODULE_LICENSE("GPL");
379379
MODULE_DESCRIPTION("Generic 8250/16x50 serial platform driver");
380380

381-
module_param_hw(share_irqs, uint, other, 0644);
381+
module_param_hw(share_irqs, bool, other, 0644);
382382
MODULE_PARM_DESC(share_irqs, "Share IRQs with other non-8250/16x50 devices (unsafe)");
383383

384384
module_param(nr_uarts, uint, 0644);

0 commit comments

Comments
 (0)