From: David Brownell <[email protected]>
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 <[email protected]>
--- a/kernel/irq/manage.c
+++ b/kernel/irq/manage.c
@@ -326,8 +326,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",
- irq, chip->set_type);
+ pr_err("setting trigger type %d for irq %u failed (%pF)\n",
+ flags & IRQF_TRIGGER_MASK, irq, chip->set_type);
return ret;
}
David Brownell wrote:
> From: David Brownell <[email protected]>
>
> 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 <[email protected]>
Acked-by: Uwe Kleine-K?nig <[email protected]>
Best regards and thanks
Uwe
--
Uwe Kleine-K?nig, Software Engineer
Digi International GmbH Branch Breisach, K?ferstrasse 8, 79206 Breisach, Germany
Tax: 315/5781/0242 / VAT: DE153662976 / Reg. Amtsgericht Dortmund HRB 13962
From: David Brownell <[email protected]>
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 <[email protected]>
Acked-by: Uwe Kleine-K?nig <[email protected]>
---
Minor change: cast trigger mode to int, one compiler warned.
kernel/irq/manage.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- a/kernel/irq/manage.c 2008-07-25 02:07:05.000000000 -0700
+++ b/kernel/irq/manage.c 2008-07-25 02:08:13.000000000 -0700
@@ -326,7 +326,8 @@ static int __irq_set_trigger(struct 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;