X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=kernel%2Firq%2Fspurious.c;h=088dabbf2d6a6cbca786ec80fe0ce6851175fef9;hb=f6c427663a158056cd8ca71c01f30653e4b313f7;hp=bd9e272d55e9f007984b06e0999f6a37bb7208e1;hpb=0b662c64840fb281e5948ab6f9d60f84817277d0;p=mirror_ubuntu-bionic-kernel.git diff --git a/kernel/irq/spurious.c b/kernel/irq/spurious.c index bd9e272d55e9..088dabbf2d6a 100644 --- a/kernel/irq/spurious.c +++ b/kernel/irq/spurious.c @@ -6,10 +6,12 @@ * This file contains spurious interrupt handling. */ +#include #include #include #include #include +#include static int irqfixup __read_mostly; @@ -172,7 +174,17 @@ void note_interrupt(unsigned int irq, struct irq_desc *desc, irqreturn_t action_ret) { if (unlikely(action_ret != IRQ_HANDLED)) { - desc->irqs_unhandled++; + /* + * If we are seeing only the odd spurious IRQ caused by + * bus asynchronicity then don't eventually trigger an error, + * otherwise the couter becomes a doomsday timer for otherwise + * working systems + */ + if (time_after(jiffies, desc->last_unhandled + HZ/10)) + desc->irqs_unhandled = 1; + else + desc->irqs_unhandled++; + desc->last_unhandled = jiffies; if (unlikely(action_ret != IRQ_NONE)) report_bad_irq(irq, desc, action_ret); } @@ -215,6 +227,8 @@ int noirqdebug_setup(char *str) } __setup("noirqdebug", noirqdebug_setup); +module_param(noirqdebug, bool, 0644); +MODULE_PARM_DESC(noirqdebug, "Disable irq lockup detection when true"); static int __init irqfixup_setup(char *str) { @@ -226,6 +240,8 @@ static int __init irqfixup_setup(char *str) } __setup("irqfixup", irqfixup_setup); +module_param(irqfixup, int, 0644); +MODULE_PARM_DESC("irqfixup", "0: No fixup, 1: irqfixup mode 2: irqpoll mode"); static int __init irqpoll_setup(char *str) {