From: David Brownell Date: Tue, 5 Aug 2008 20:01:14 +0000 (-0700) Subject: genirq: better warning on irqchip->set_type() failure X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c69ad71bcdecbaab82cfacb1dc967bd7fd967a3b;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git genirq: better warning on irqchip->set_type() failure While I'm glad to finally see the hole fixed whereby passing an invalid IRQ trigger type to request_irq() would be ignored, the current diagnostic isn't quite useful. Fixed by also listing the trigger type which was rejected. Signed-off-by: David Brownell Acked-by: Uwe Kleine-König Cc: Ingo Molnar Cc: Thomas Gleixner Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c index 152abfd3589..0314074fa23 100644 --- a/kernel/irq/manage.c +++ b/kernel/irq/manage.c @@ -323,7 +323,8 @@ static int __irq_set_trigger(struct irq_chip *chip, unsigned int irq, ret = chip->set_type(irq, flags & IRQF_TRIGGER_MASK); if (ret) - pr_err("setting flow type for irq %u failed (%pF)\n", + pr_err("setting trigger mode %d for irq %u failed (%pF)\n", + (int)(flags & IRQF_TRIGGER_MASK), irq, chip->set_type); return ret;