Re: Why does callback irq_startup in struct irq_chip return _unsigned_ int ?
From: Thomas Gleixner
Date: Fri May 26 2017 - 03:13:12 EST
Heiner,
On Thu, 25 May 2017, Heiner Kallweit wrote:
> just by chance I noticed that callback irq_startup in struct irq_chip
> returns an unsigned int.
> This doesn't seem to make sense as the result is a normal retval which
> is casted to a signed int in function irq_startup() anyway.
>
> Is there any specific reason for this or is it simply a bug?
/me scratches head.
IIRC then it was made unsigned int because that function cannot fail, but
can return that an interrupt was pending.
So if at all the thing should be 'bool'.
Thanks,
tglx